/* Order assistant */
.sp { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 2rem; align-items: start; }
.sp-phonecol { display: grid; gap: .75rem; justify-items: center; }
.sp-phonenote { max-width: 375px; text-align: center; margin: 0; }
.sp .phone-bar { gap: .7rem; }
.sp-avatar { width: 38px; height: 38px; border-radius: 50%; background: var(--magenta); color: #fff; display: grid; place-items: center; font-family: var(--f-display); font-weight: 800; flex: none; }
.sp-bartext { display: grid; line-height: 1.25; }
.sp .phone-body { background: #fff; }
.sp .chat { padding: .9rem .9rem 1.2rem; }
.sp .bubble.bot b { font-weight: 700; }
.sp-cardwrap { align-self: flex-start; width: 92%; animation: pop .35s var(--ease-spring) both; }
.sp-card { background: var(--paper); border-radius: var(--r-m); box-shadow: 0 0 0 1.5px var(--line); padding: .8rem; display: grid; gap: .6rem; font-size: var(--t-s); }
.sp-cardtitle { display: flex; justify-content: space-between; gap: .5rem; font-weight: 700; font-size: var(--t-s); }
.sp-fields { display: grid; grid-template-columns: 1.7fr 1fr; gap: .5rem; }
.sp-fields .field span { font-weight: 600; color: var(--ink-2); font-size: var(--t-xs); }
.sp-orderform .btn { justify-content: center; }
.sp-orderform.is-sent, .sp-greetform.is-sent { opacity: .55; }
.sp-formlabel { margin: 0; }
.sp-demochips .chip { font-size: var(--t-xs); padding: .35em .7em; text-align: left; }
.sp-formerr { color: var(--red); margin: 0; }
.sp-quick { padding: .1rem 0 .3rem; animation: rise .4s var(--ease-out) both; }
.sp-quick .chip { text-align: left; }
.sp-quote { margin: .45rem 0; padding: .45rem .65rem; background: var(--paper); border-left: 3px solid var(--yellow); border-radius: 6px; font-style: italic; }
.sp-ok { display: inline-block; font-weight: 700; color: #11776d; background: var(--mint-soft); padding: .1em .55em; border-radius: var(--r-pill); }

/* timeline */
.sp-tl { list-style: none; margin: 0; padding: 0; display: grid; gap: .1rem; position: relative; }
.sp-step { display: flex; gap: .65rem; align-items: flex-start; position: relative; padding-bottom: .55rem; opacity: .45; transition: opacity .3s; }
.sp-step:last-child { padding-bottom: 0; }
.sp-step::before { content: ""; position: absolute; left: 10px; top: 22px; bottom: -2px; width: 2px; background: var(--paper-3); }
.sp-step:last-child::before { display: none; }
.sp-step.is-done, .sp-step.is-open { opacity: 1; }
.sp-step.is-done::before { background: var(--mint); }
.sp-tick { width: 22px; height: 22px; border-radius: 50%; border: 2px solid var(--line); background: var(--paper); display: grid; place-items: center; flex: none; color: transparent; transition: background .25s, border-color .25s, transform .3s var(--ease-spring); }
.sp-step.is-done .sp-tick { background: var(--mint); border-color: var(--mint); color: #fff; transform: scale(1.1); }
.sp-step.is-now .sp-tick { box-shadow: 0 0 0 4px var(--mint-soft); }
.sp-step.is-open .sp-tick { border-style: dashed; border-color: var(--ink-3); }
.sp-steptext { display: grid; line-height: 1.25; }
.sp-steptext small { color: var(--ink-3); font-size: var(--t-xs); }
.sp-step.is-now .sp-steptext b { color: #11776d; }

/* input */
.sp-input { display: flex; gap: .5rem; padding: .6rem .7rem .8rem; border-top: 1px solid var(--line); background: var(--paper); flex: none; }
.sp-input .input { border-radius: var(--r-pill); padding-left: 1rem; }
.sp-send { width: 40px; height: 40px; flex: none; border-radius: 50%; border: 0; background: var(--magenta); color: #fff; display: grid; place-items: center; cursor: pointer; transition: transform .15s var(--ease-out), background .15s; }
.sp-send:hover { background: var(--magenta-2); } .sp-send:active { transform: scale(.92); }

/* right side */
.sp-side { display: grid; gap: 1rem; min-width: 0; }
.sp-panel { background: var(--paper); border-radius: var(--r-l); box-shadow: 0 0 0 1px var(--line); padding: 1.1rem 1.25rem; }
.sp-panelhead { display: flex; justify-content: space-between; gap: 1rem; align-items: flex-start; margin-bottom: .8rem; }
.sp-panelhead h3 { font-size: var(--t-l); margin-bottom: .15rem; }
.sp-panelhead p { margin: 0; }
.sp-log { list-style: none; margin: 0; padding: .3rem 0 0; display: grid; gap: .1rem; min-height: 200px; max-height: 330px; overflow-y: auto; font-size: var(--t-s); }
.sp-log-empty { padding: 1.2rem 0; }
.sp-line { display: grid; grid-template-columns: 14px 1fr auto; gap: .6rem; align-items: baseline; padding: .32rem 0; border-bottom: 1px dashed var(--line); animation: rise .35s var(--ease-out) both; }
.sp-line time { color: var(--ink-3); font-size: var(--t-xs); font-variant-numeric: tabular-nums; }
.sp-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--mint); align-self: center; }
.sp-line.is-warn .sp-dot { background: var(--yellow); box-shadow: 0 0 0 2px var(--yellow-soft); }
.sp-ltext { min-width: 0; overflow-wrap: anywhere; }
.sp-sep { margin: .6rem 0 .1rem; font-size: var(--t-xs); font-weight: 700; color: var(--ink-2); background: var(--paper-2); padding: .3rem .6rem; border-radius: var(--r-s); animation: rise .3s var(--ease-out) both; }
.sp-sep:first-child { margin-top: 0; }

.sp-tickets { display: grid; gap: 1rem; }
.sp-ticket { background: var(--yellow-soft); border-radius: var(--r-l); padding: 1rem 1.25rem; box-shadow: 0 0 0 1.5px var(--yellow); display: grid; gap: .7rem; animation: rise .5s var(--ease-out) both; }
.sp-ticket.is-hot { background: var(--red-soft); box-shadow: 0 0 0 1.5px var(--red); }
.sp-ticket.is-done { background: var(--paper-2); box-shadow: 0 0 0 1px var(--line); }
.sp-ticket header { display: flex; gap: .6rem; align-items: center; }
.sp-ticket dl { margin: 0; display: grid; grid-template-columns: 9.5rem 1fr; gap: .35rem .9rem; font-size: var(--t-s); }
.sp-ticket dt { color: var(--ink-2); font-weight: 600; }
.sp-ticket dd { margin: 0; }
.sp-reply { background: var(--paper); border-radius: var(--r-s); padding: .5rem .7rem; font-style: italic; }

.sp-counter h4 { font-size: var(--t-m); margin-bottom: .6rem; }
.sp-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.sp-stats div { display: grid; }
.sp-stats b { font-family: var(--f-display); font-size: var(--t-2xl); font-variant-numeric: tabular-nums; line-height: 1.1; }
.sp-stats b.mint { color: var(--mint); } .sp-stats b.yel { color: #b58900; }
.sp-stats b.flash { animation: spflash .6s var(--ease-out); }
.sp-stats span { font-size: var(--t-xs); color: var(--ink-3); }
.sp-meter { display: flex; height: 10px; border-radius: var(--r-pill); background: var(--paper-3); overflow: hidden; margin: .8rem 0 .5rem; }
.sp-meter i { display: block; height: 100%; transition: width .6s var(--ease-out); }
.sp-meter i:first-child { background: var(--mint); }
.sp-meter i:last-child { background: var(--yellow); }
@keyframes spflash { 0% { transform: scale(1.25); } 100% { transform: none; } }

@media (max-width: 980px) {
  .sp { grid-template-columns: 1fr; }
  .sp-phonecol { order: 1; }
}
@media (max-width: 520px) {
  .sp-ticket dl { grid-template-columns: 1fr; gap: .1rem; }
  .sp-ticket dt { margin-top: .4rem; }
  .sp .phone { height: 680px; }
  .sp-stats b { font-size: var(--t-xl); }
}

.sp-panelhead .btn { white-space: nowrap; flex: none; }
