/* ============================================================================
   SellFalcon Support (redesign, September 2026).
   What is running right now, the four quick fixes, a composer that knows the
   store and the screen, the seller's own conversations, and the direct lines.
   Tokens and primitives come from app.css.
   ============================================================================ */

.sup { display: grid; grid-template-columns: minmax(0, 1fr) 312px; gap: 14px; align-items: start; min-width: 0; animation: sfRise .26s var(--ez) both; }
.sup-skel { grid-template-columns: minmax(0, 1fr) 312px; }
.sup-main, .sup-side { min-width: 0; display: grid; gap: 12px; }
.sup-main > .card, .sup-side > .card { animation: sfRise .3s var(--ez) both; }
.sup-faq { animation-delay: .08s; }
.sup-ask { animation-delay: .14s; }
.sup-hist { animation-delay: .05s; }
.sup-direct { animation-delay: .11s; }
.sup-facts { animation-delay: .17s; }

/* ---- what is running ---- */
.sup-band { display: flex; align-items: center; gap: 12px; padding: 12px 16px; border-left: 3px solid var(--pos); border-radius: 13px; flex-wrap: wrap; animation-delay: .02s; }
.sup-band.warn { border-left-color: var(--warn); }
.sup-band.bad { border-left-color: var(--neg); }
.sup-band .dot { width: 9px; height: 9px; flex: none; border-radius: 50%; background: var(--pos); animation: sfPulse 2.6s var(--ez) infinite; }
.sup-band.warn .dot { background: var(--warn); }
.sup-band.bad .dot { background: var(--neg); }
.sup-band > b { font-size: 13px; font-weight: 780; letter-spacing: -.015em; white-space: nowrap; }
.sup-band .chips { display: inline-flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.sup-band .chips .chip { cursor: help; }
.sup-band .end { margin-left: auto; }
.sup-band .btn.xs { height: 30px; font-size: 12px; }

/* ---- quick fixes ---- */
.sup-faq { overflow: hidden; border-radius: 13px; }
.sup-faqh { display: flex; align-items: center; gap: 10px; padding: 14px 18px; border-bottom: 1px solid var(--ln); flex-wrap: wrap; }
.sup-faqh h2 { display: flex; align-items: center; gap: 8px; margin: 0; font-size: 13.5px; font-weight: 780; letter-spacing: -.015em; flex: 1; min-width: 160px; }
.sup-faqh .search { flex: none; }
.sup-faqh .search .in { width: 190px; height: 30px; min-height: 30px; padding-left: 26px; border-radius: 999px; background: var(--pn2); font-size: 12px; }
.sup-q { border-bottom: 1px solid var(--ln); animation: sfPop .22s var(--ez) both; }
.sup-qh { display: flex; align-items: center; gap: 11px; width: 100%; padding: 12px 18px; border: 0; background: transparent; cursor: pointer; text-align: left; font: inherit; color: inherit; transition: background .14s var(--ez); }
.sup-qh:hover, .sup-qh[aria-expanded="true"] { background: var(--pn2); }
.sup-qh .ip { margin: 0; width: 28px; height: 28px; }
.sup-qh b { flex: 1; min-width: 0; font-size: 13px; font-weight: 750; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sup-qh .chev { flex: none; color: var(--faint); transition: transform .25s var(--ez); }
.sup-qh[aria-expanded="true"] .chev { transform: rotate(180deg); }
.sup-qb { display: grid; grid-template-rows: 0fr; transition: grid-template-rows .3s var(--ez); }
.sup-qb.open { grid-template-rows: 1fr; }
.sup-qb > div { overflow: hidden; min-height: 0; }
.sup-qb .in-pad { display: flex; align-items: flex-start; gap: 12px; padding: 0 18px 13px 57px; opacity: 0; transition: opacity .25s var(--ez); flex-wrap: wrap; }
.sup-qb.open .in-pad { opacity: 1; }
.sup-qb p { flex: 1; min-width: 220px; margin: 0; font-size: 12.5px; color: var(--ink2); line-height: 1.55; }
.sup-qb .btn.xs { height: 30px; padding: 0 12px; font-size: 12px; border-color: var(--acc); background: var(--accw); color: var(--acci); }
.sup-qb .btn.xs:hover { background: var(--acc); color: #fff; }
.sup-none { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 26px 18px; text-align: center; animation: sfPop .3s var(--ez) both; }
.sup-none b { font-size: 13px; font-weight: 750; }
.sup-none small { font-size: 12.5px; color: var(--dim); }

/* ---- ask a person ---- */
.sup-ask { overflow: hidden; border-radius: 13px; }
.sup-askh { display: flex; align-items: center; gap: 10px; padding: 14px 18px 10px; }
.sup-askh .tx { flex: 1; min-width: 0; }
.sup-askh h2 { margin: 0; font-size: 14px; font-weight: 780; letter-spacing: -.018em; }
.sup-askh p { margin: 3px 0 0; font-size: 12px; color: var(--dim); }
.sup-eta { flex: none; display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 999px; background: var(--pn2); border: 1px solid var(--ln); font-size: 12px; font-weight: 700; color: var(--dim); white-space: nowrap; }
.sup-eta.on { color: var(--posi); border-color: color-mix(in srgb, var(--pos) 40%, transparent); background: var(--posw); }
.sup-topics { display: flex; flex-wrap: wrap; gap: 7px; padding: 0 18px 12px; }
.sup-topic { display: inline-flex; align-items: center; gap: 6px; height: 32px; padding: 0 12px 0 9px; border: 1px solid var(--ln2); border-radius: 999px; background: var(--pn2); color: var(--ink2); font: inherit; font-size: 12.5px; font-weight: 700; cursor: pointer; transition: transform .15s var(--ez), background .15s var(--ez), border-color .15s var(--ez); }
.sup-topic:hover { transform: translateY(-1px); border-color: var(--acc); }
.sup-topic[aria-pressed="true"] { border-color: var(--acc); background: var(--accw); color: var(--acci); }
.sup-topic .ic { width: 14px; height: 14px; display: grid; place-items: center; }
.sup-compose { padding: 0 18px 10px; }
.sup-compose textarea.in { width: 100%; min-height: 132px; padding: 12px 13px; border-radius: 10px; background: var(--pn2); font-size: 13.5px; line-height: 1.55; resize: vertical; }
.sup-tools { display: flex; align-items: center; gap: 8px; margin-top: 8px; flex-wrap: wrap; }
.sup-tools .grow { flex: 1; }
.sup-att { display: inline-flex; align-items: center; gap: 7px; height: 32px; padding: 0 6px 0 10px; border: 1px solid var(--ln); border-radius: 8px; background: var(--pn2); font-size: 12px; font-weight: 650; color: var(--ink2); max-width: 220px; animation: sfPop .2s var(--ez) both; }
.sup-att span { min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sup-att small { color: var(--faint); flex: none; }
.sup-att .xbtn.sm:hover { background: var(--negw); color: var(--negi); }
.sup-urg { display: inline-flex; align-items: center; gap: 8px; font-size: 12px; font-weight: 700; color: var(--dim); cursor: pointer; white-space: nowrap; transition: color .2s var(--ez); }
.sup-urg.on { color: var(--negi); }
.sup-urg .switch { width: 36px; height: 21px; }
.sup-urg .switch::after { top: 2px; left: 2px; width: 17px; height: 17px; }
.sup-urg .switch[aria-checked="true"] { background: var(--neg); }
.sup-urg .switch[aria-checked="true"]::after { transform: translateX(15px); background-image: none; }
.sup-count { font-size: 12px; color: var(--faint); font-variant-numeric: tabular-nums; white-space: nowrap; }
.sup-count.warn { color: var(--warni); }
.sup-foot { display: flex; align-items: center; gap: 10px; padding: 12px 18px; border-top: 1px solid var(--ln); background: var(--pn2); flex-wrap: wrap; }
.sup-foot .tx { display: inline-flex; align-items: center; gap: 7px; flex: 1; min-width: 200px; font-size: 12px; color: var(--dim); font-weight: 600; }
.sup-foot .tx svg { flex: none; }
.sup-foot small { font-size: 12px; color: var(--faint); white-space: nowrap; }
.sup-foot .btn.primary { height: 38px; padding: 0 18px; border-radius: 10px; }
.sup-foot .btn.primary.urgent { background: var(--neg); }
.sup-foot .btn.primary.urgent:hover { background: #d92b41; }
.sup-sent { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 34px 18px; text-align: center; animation: sfPop .3s var(--ez) both; }
.sup-sent .ip { width: 46px; height: 46px; border-radius: 14px; animation: sfTick .5s var(--ez) both; }
.sup-sent b { font-size: 14px; font-weight: 780; letter-spacing: -.015em; }
.sup-sent small { font-size: 12.5px; color: var(--dim); line-height: 1.5; max-width: 44ch; }
.sup-sent .acts { display: flex; gap: 8px; margin-top: 6px; flex-wrap: wrap; justify-content: center; }

/* ---- your messages ---- */
.sup-hist { overflow: hidden; }
.sup-sideh { display: flex; align-items: center; gap: 8px; padding: 14px 16px 10px; }
.sup-sideh h2 { margin: 0; font-size: 13.5px; font-weight: 750; }
.sup-th { display: flex; align-items: flex-start; gap: 10px; width: 100%; padding: 10px 16px; border: 0; border-top: 1px solid var(--ln); background: transparent; text-align: left; font: inherit; color: inherit; cursor: pointer; transition: background .14s var(--ez); animation: sfPop .22s var(--ez) both; }
.sup-th:hover { background: var(--pn2); }
.sup-th .dot { width: 8px; height: 8px; flex: none; margin-top: 5px; border-radius: 50%; background: var(--pos); }
.sup-th .dot.open { background: var(--acc); animation: sfPulse 2.4s var(--ez) infinite; }
.sup-th .dot.new { background: var(--neg); animation: sfPulse 1.6s var(--ez) infinite; }
.sup-th .dot.warn { background: var(--warn); }
.sup-th .tx { flex: 1; min-width: 0; }
.sup-th .tx b { display: block; font-size: 12.5px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sup-th .tx small { display: block; font-size: 12px; color: var(--faint); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sup-th .tag { padding: 2px 8px; font-size: 12px; }
.sup-histempty { padding: 6px 16px 16px; font-size: 12.5px; color: var(--dim); line-height: 1.5; }

/* ---- direct ---- */
.sup-direct { padding: 14px 16px; }
.sup-direct h2, .sup-facts h2 { margin: 0 0 10px; font-size: 13.5px; font-weight: 750; }
.sup-wa { display: flex; align-items: center; gap: 11px; padding: 11px 12px; border: 1px solid var(--ln2); border-radius: 11px; background: var(--pn2); color: var(--ink); text-decoration: none; transition: transform .16s var(--ez), border-color .16s var(--ez), box-shadow .16s var(--ez); }
.sup-wa:hover { transform: translateY(-2px); border-color: #25D366; box-shadow: var(--sh); text-decoration: none; color: var(--ink); }
.sup-wa .ip { width: 36px; height: 36px; background: #25D366; color: #fff; box-shadow: 0 4px 10px rgba(37, 211, 102, .3); }
.sup-wa .tx { flex: 1; min-width: 0; }
.sup-wa .tx b { display: block; font-size: 13px; font-weight: 800; letter-spacing: -.01em; }
.sup-wa .tx small { display: flex; align-items: center; gap: 5px; font-size: 12px; color: var(--dim); }
.sup-wa .tx small i { width: 6px; height: 6px; flex: none; border-radius: 50%; background: var(--faint); }
.sup-wa .tx small i.on { background: #25D366; animation: sfPulse 2.4s var(--ez) infinite; }
.sup-wa > svg { flex: none; color: var(--faint); }
.sup-mail { display: flex; align-items: center; gap: 9px; margin-top: 8px; padding: 9px 11px; border-radius: 9px; background: var(--pn2); border: 1px solid var(--ln); }
.sup-mail > svg { flex: none; color: var(--faint); }
.sup-mail a { flex: 1; min-width: 0; font-size: 12px; font-weight: 650; overflow: hidden; text-overflow: ellipsis; color: var(--acci); text-decoration: none; }
.sup-mail a:hover { text-decoration: underline; }
.sup-mail .btn.xs.copied { border-color: var(--pos); background: var(--posw); color: var(--posi); }

/* ---- worth knowing ---- */
.sup-facts { padding: 14px 16px; }
.sup-facts .rows { display: grid; gap: 9px; }
.sup-facts .rows span { display: flex; align-items: flex-start; gap: 9px; font-size: 12.5px; color: var(--dim); line-height: 1.5; }
.sup-facts .rows .ip { margin-top: -1px; }

/* ---- one conversation, in a dialog ---- */
.sup-log { display: grid; gap: 10px; max-height: 46vh; overflow-y: auto; padding: 2px 2px 6px; }
.sup-msg { max-width: 86%; padding: 9px 12px; border-radius: 12px; font-size: 13px; line-height: 1.5; }
.sup-msg.mine { justify-self: end; background: var(--acc); color: #fff; border-bottom-right-radius: 4px; }
.sup-msg.team { justify-self: start; background: var(--pn2); border: 1px solid var(--ln); border-bottom-left-radius: 4px; }
.sup-msg p { margin: 0; white-space: pre-wrap; word-break: break-word; }
.sup-msg small { display: block; margin-top: 4px; font-size: 12px; opacity: .72; }
.sup-msg .att { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.sup-msg .att img { max-width: 220px; max-height: 160px; border-radius: 8px; cursor: zoom-in; }
.sup-msg .att audio { max-width: 240px; }
.sup-msg .att a { color: inherit; font-weight: 700; }
.sup-reply { display: flex; align-items: flex-end; gap: 8px; margin-top: 12px; }
.sup-reply textarea.in { flex: 1; min-height: 0; padding: 9px 11px; line-height: 1.5; resize: none; background: var(--pn2); }
.sup-replyq { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.sup-closed { margin: 10px 0 0; font-size: 12.5px; color: var(--dim); }

@media (max-width: 960px) {
  .sup, .sup-skel { grid-template-columns: 1fr; }
}
