/* Parley panel. Built to the owner's design: docs/voice/design/parley (DESIGN.md). Dark by default; a light theme too. */
@font-face { font-family: "Bricolage"; src: url(/panel/f-bricolage.woff2) format("woff2"); font-weight: 200 800; font-stretch: 75% 100%; font-display: swap; }
@font-face { font-family: "JB Mono"; src: url(/panel/f-mono.woff2) format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Hind Siliguri"; src: url(/panel/f-hind-400.woff2) format("woff2"); font-weight: 400; font-display: swap; unicode-range: U+0964-0965, U+0980-09FE, U+200C-200D, U+25CC; }
@font-face { font-family: "Hind Siliguri"; src: url(/panel/f-hind-600.woff2) format("woff2"); font-weight: 500 600; font-display: swap; unicode-range: U+0964-0965, U+0980-09FE, U+200C-200D, U+25CC; }
@font-face { font-family: "Hind Siliguri"; src: url(/panel/f-hind-700.woff2) format("woff2"); font-weight: 700 800; font-display: swap; unicode-range: U+0964-0965, U+0980-09FE, U+200C-200D, U+25CC; }

/* Design tokens (dark, the default). Old names kept so every screen follows: --amber is the primary action (lime). */
:root {
  --ink: #0F0C29; --lime: #C6F159; --lime-2: #D6F77F; --lav: #A99BFE; --coral: #FE794C; --peach: #FEE3D2; --violet: #29226F;
  --bg: #0F0C29; --surface: #15133B; --surface-2: #1C1A49; --text: #ECEAFE; --muted: #A9A6D0; --faint: #7D79AE;
  --border: #2A2766; --border-strong: #3A3870; --link: #C6F159;
  --navy: #1A1745; --deep: #29226F; --royal: #8A7FF0; --glow: #A99BFE; --amber: #C6F159; --amber-warm: #C6F159; --cream: #ECEAFE;
  --amber-text: #FF9D78; --amber-bg: #3A1D2A; --blue-bg: #29226F; --blue-text: #D4CFFF;
  --ok: #C6F159; --ok-bg: #26331F; --bad: #FF8A80; --bad-bg: #3A1525;
  --side: #0F0C29; --side-active: #29226F; --side-text: #ECEAFE; --side-muted: #A9A6D0; --hero: #29226F;
  --on-primary: #0F0C29;
  --radius: 10px; --shadow-focus: 0 0 0 3px rgba(198, 241, 89, .35);
  --font: "Bricolage", "Hind Siliguri", "Segoe UI", "Nirmala UI", system-ui, sans-serif;
  --mono: "JB Mono", "Cascadia Code", Consolas, monospace;
  color-scheme: dark;
}
:root[data-theme="light"] {
  --bg: #F6F4FF; --surface: #FFFFFF; --surface-2: #EFECFC; --text: #0F0C29; --muted: #4E4A72; --faint: #6E6A92;
  --border: #E1DDF5; --border-strong: #CBC5EC; --link: #4B3FC4;
  --navy: #0F0C29; --deep: #E1DDF5; --royal: #5B4BD6; --glow: #5B4BD6; --cream: #ECEAFE;
  --amber-text: #B7431E; --amber-bg: #FFE9DE; --blue-bg: #ECEAFE; --blue-text: #3A2FA0;
  --ok: #3D6B0A; --ok-bg: #EAF6D3; --bad: #A12A22; --bad-bg: #FBE9E7;
  --side: #0F0C29; --side-active: #29226F; --side-text: #ECEAFE; --side-muted: #A9A6D0; --hero: #29226F;
  --shadow-focus: 0 0 0 3px rgba(91, 75, 214, .3);
  color-scheme: light;
}

* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body { background: var(--bg); color: var(--text); font: 14.5px/1.5 var(--font); -webkit-font-smoothing: antialiased; }
a { color: var(--link); text-decoration: none; }
a:hover { text-decoration: underline; }
h1 { font-size: 30px; font-weight: 800; margin: 0; letter-spacing: -.03em; line-height: 1.1; }
h2 { font-size: 16px; font-weight: 700; margin: 0 0 12px; letter-spacing: -.01em; }
h3 { font-size: 13px; font-weight: 600; margin: 0 0 8px; color: var(--muted); }
code, pre, .mono { font-family: var(--mono); font-size: 12.5px; }
:focus-visible { outline: none; box-shadow: var(--shadow-focus); border-radius: 6px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Layout: sidebar, a thin top bar with the page and what is live, then the page */
.app { display: grid; grid-template-columns: 240px minmax(0, 1fr); min-height: 100vh; }
.side { background: var(--side); color: var(--side-text); padding: 18px 12px; display: flex; flex-direction: column; gap: 2px; position: sticky; top: 0; height: 100vh; overflow-y: auto; border-right: 1px solid #1F1C4A; }
.brand { display: flex; align-items: center; gap: 10px; padding: 2px 8px 16px; color: var(--side-text); }
.brand:hover { text-decoration: none; }
.brand b { font-size: 21px; font-weight: 800; letter-spacing: -.03em; }
.account { display: grid; gap: 1px; margin: 0 0 14px; padding: 9px 12px; border-radius: 10px; background: #1A1745; border: 1px solid #2A2766; color: var(--side-text); position: relative; }
.account:hover { text-decoration: none; border-color: #3A3870; }
.account b { font-size: 14px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; padding-right: 14px; }
.account span { font-size: 12px; color: var(--side-muted); }
.account::after { content: "▾"; position: absolute; right: 12px; top: 50%; transform: translateY(-50%); font-size: 11px; color: var(--side-muted); }
.nav { display: flex; align-items: center; gap: 11px; padding: 8px 12px; border-radius: 9px; color: var(--side-text); font-size: 15px; border-left: 3px solid transparent; }
.nav:hover { background: rgba(255, 255, 255, .05); text-decoration: none; }
.nav.on { background: var(--side-active); border-left-color: var(--lime); font-weight: 700; }
.nav svg { width: 18px; height: 18px; flex: none; stroke: currentColor; fill: none; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; opacity: .9; }
.nav .soon { margin-left: auto; font-size: 10.5px; color: var(--side-muted); border: 1px solid rgba(174, 184, 200, .35); border-radius: 9px; padding: 0 6px; }
.nav.dim { color: var(--side-muted); }
.nav-group { font-size: 12px; color: var(--side-muted); padding: 14px 12px 4px; }
.side-foot { margin-top: auto; padding: 12px 4px 0; font-size: 12px; color: var(--side-muted); display: grid; gap: 10px; }
.side-foot .mode { color: var(--lime); padding: 0 6px; }
.side-foot button { color: var(--side-text); border-color: #2A2766; background: transparent; }
.livebox { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 10px 12px; border-radius: 10px; background: #1A1745; border: 1px solid #2A2766; color: var(--side-text); }
.livebox:hover { text-decoration: none; border-color: #3A3870; }
.livebox > span { display: grid; }
.livebox b { font-size: 13.5px; }
.livebox span span { font-size: 12px; color: var(--side-muted); }
.livebox svg { width: 22px; height: 22px; stroke: var(--lime); stroke-width: 2.4; stroke-linecap: round; fill: none; }
.content { min-width: 0; display: flex; flex-direction: column; }
.topbar { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 60px; padding: 0 32px; border-bottom: 1px solid var(--border); color: var(--muted); font-size: 15px; }
.livepill { display: inline-flex; align-items: center; gap: 6px; background: var(--ok-bg); color: var(--ok); font-weight: 700; font-size: 13px; border-radius: 999px; padding: 4px 11px; }
.livepill::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.main { padding: 30px 32px 56px; min-width: 0; max-width: 1360px; width: 100%; }
.top { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; margin-bottom: 22px; flex-wrap: wrap; }
.top .sub { color: var(--muted); font-size: 15px; margin-top: 4px; }
.crumb { font-size: 14px; color: var(--muted); margin-bottom: 6px; }
.row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.grow { flex: 1; }
.grid { display: grid; gap: 12px; align-items: start; }
.g4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.g21 { grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); }
.stack { display: grid; gap: 16px; align-content: start; }

/* Surfaces */
.card { background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 18px 20px; min-width: 0; }
.card.flush { padding: 0; overflow: hidden; }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 12px; }
.card-head h2 { margin: 0; }
.stat .label { color: var(--muted); font-size: 14px; }
.stat .value { font-size: 32px; font-weight: 800; letter-spacing: -.03em; margin-top: 4px; font-variant-numeric: tabular-nums; line-height: 1.15; }
.stat .hint { color: var(--faint); font-size: 13px; margin-top: 2px; }
.stat .hint.up { color: var(--ok); }
.stat.hero { background: var(--hero, var(--navy)); border-color: var(--hero, var(--navy)); color: var(--cream); }
.stat.hero .label { color: var(--lime); }
.stat.hero .hint { color: #AEB8C8; }
.meter { height: 5px; background: var(--deep); border-radius: 3px; margin-top: 8px; overflow: hidden; }
.meter i { display: block; height: 100%; background: var(--amber); border-radius: 3px; }
.empty { color: var(--muted); padding: 28px 16px; text-align: center; }
.empty b { display: block; color: var(--text); font-size: 15px; margin-bottom: 4px; }
.note { background: var(--surface-2); border-radius: var(--radius); padding: 10px 12px; color: var(--muted); font-size: 13px; }
.note.warn { background: var(--amber-bg); color: var(--amber-text); }
.note.bad { background: var(--bad-bg); color: var(--bad); }
.note.ok { background: var(--ok-bg); color: var(--ok); }

/* Controls */
button, .btn { font: inherit; font-size: 14px; font-weight: 600; height: 38px; padding: 0 16px; border-radius: var(--radius); border: 1px solid var(--border-strong); background: var(--surface); color: var(--text); cursor: pointer; display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; }
button:hover, .btn:hover { background: var(--surface-2); text-decoration: none; }
button:active { transform: translateY(1px); }
button.primary, .btn.primary { background: var(--lime); border-color: var(--lime); color: var(--on-primary); font-weight: 700; }
button.primary:hover, .btn.primary:hover { background: var(--lime-2); }
button.ghost { border-color: transparent; background: transparent; color: var(--link); padding: 0 8px; }
button.ghost:hover { background: var(--surface-2); }
button.danger { color: var(--bad); }
button.small { height: 30px; padding: 0 12px; font-size: 13px; }
button[aria-busy="true"] { opacity: .6; cursor: progress; }
input, select, textarea { font: inherit; font-size: 13.5px; color: var(--text); background: var(--surface); border: 1px solid var(--border-strong); border-radius: var(--radius); padding: 7px 10px; width: 100%; }
input, select { height: 34px; }
textarea { min-height: 90px; resize: vertical; line-height: 1.45; }
textarea.code { font-family: var(--mono); font-size: 12.5px; min-height: 420px; tab-size: 2; white-space: pre; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--glow); box-shadow: var(--shadow-focus); }
label.f { display: grid; gap: 4px; font-size: 12.5px; color: var(--muted); }
label.f > span b { color: var(--text); font-weight: 600; }
.seg { display: inline-flex; border: 1px solid var(--border-strong); border-radius: var(--radius); overflow: hidden; }
.seg button { border: 0; border-radius: 0; height: 32px; background: var(--surface); }
.seg button + button { border-left: 1px solid var(--border-strong); }
.seg button.on { background: var(--blue-bg); color: var(--blue-text); font-weight: 600; }

/* Tables */
.table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
.table th { text-align: left; font-weight: 500; color: var(--muted); font-size: 12px; padding: 10px 14px; border-bottom: 1px solid var(--border); white-space: nowrap; }
.table td { padding: 10px 14px; border-bottom: 1px solid var(--border); vertical-align: top; }
.table tr:last-child td { border-bottom: 0; }
.table tr.link { cursor: pointer; }
.table tr.link:hover td { background: var(--surface-2); }
.table .num { text-align: right; font-variant-numeric: tabular-nums; }
.table .clip { max-width: 320px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--muted); }
.scroll { overflow-x: auto; }

/* Badges */
.badge { display: inline-flex; align-items: center; gap: 4px; font-size: 12.5px; line-height: 1; padding: 5px 9px; border-radius: 8px; font-weight: 600; background: var(--surface-2); color: var(--muted); white-space: nowrap; font-weight: 500; }
.badge.ok { background: var(--ok-bg); color: var(--ok); }
.badge.bad { background: var(--bad-bg); color: var(--bad); }
.badge.warn { background: var(--amber-bg); color: var(--amber-text); }
.badge.blue { background: var(--blue-bg); color: var(--blue-text); }
.badge.live::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; animation: pulse 1.4s infinite; }
@keyframes pulse { 50% { opacity: .3; } }
.dir { font-size: 12px; color: var(--muted); }

/* Charts */
.bars { display: flex; align-items: flex-end; gap: 4px; height: 160px; padding-top: 8px; border-bottom: 1px solid var(--border); }
.bars .col { flex: 1; display: flex; align-items: flex-end; justify-content: center; gap: 2px; height: 100%; position: relative; min-width: 0; }
.bars .b { width: 100%; max-width: 18px; border-radius: 3px 3px 0 0; min-height: 2px; }
.bars .b.a { background: var(--royal); }
.bars .b.c { background: var(--amber); }
.axis { display: flex; justify-content: space-between; font-size: 11.5px; color: var(--faint); margin-top: 6px; }
.legend { display: flex; gap: 14px; font-size: 12px; color: var(--muted); }
.legend i { display: inline-block; width: 9px; height: 9px; border-radius: 2px; margin-right: 5px; vertical-align: -1px; }
.hbar { display: grid; grid-template-columns: 110px minmax(0, 1fr) 44px; gap: 10px; align-items: center; font-size: 13px; padding: 4px 0; }
.hbar .t { height: 8px; background: var(--surface-2); border-radius: 4px; overflow: hidden; }
.hbar .t i { display: block; height: 100%; background: var(--royal); border-radius: 4px; }
.hbar .n { text-align: right; color: var(--muted); font-variant-numeric: tabular-nums; }

/* Call detail */
.kv { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 6px 16px; font-size: 13.5px; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; overflow-wrap: anywhere; }
.turns { display: grid; gap: 10px; }
.turn { display: grid; grid-template-columns: 52px minmax(0, 1fr); gap: 10px; }
.turn .at { font-size: 12px; color: var(--faint); padding-top: 8px; font-variant-numeric: tabular-nums; }
.turn .bubble { padding: 8px 12px; border-radius: 10px; background: var(--surface-2); max-width: 680px; }
.turn .who { font-size: 11.5px; color: var(--muted); margin-bottom: 2px; font-weight: 600; }
.turn.agent .bubble { background: var(--blue-bg); color: var(--blue-text); }
.turn.agent .who { color: var(--blue-text); }
.turn.tool .bubble { background: transparent; border: 1px dashed var(--border-strong); font-family: var(--mono); font-size: 12px; color: var(--muted); }
.turn.desk .bubble { background: var(--amber-bg); color: var(--amber-text); }
.wave { display: flex; align-items: center; gap: 12px; padding: 10px 0; }
.wave + .wave { border-top: 1px solid var(--border); }
.wave .play { width: 40px; height: 40px; border-radius: 50%; justify-content: center; padding: 0; background: var(--lime); border-color: var(--lime); color: var(--on-primary); flex: none; }
.wave svg.w { flex: 1; height: 40px; min-width: 0; cursor: pointer; }
.wave svg.w rect { fill: var(--border-strong); }
.wave svg.w rect.p { fill: var(--royal); }
.wave .meta { font-size: 12px; color: var(--muted); min-width: 92px; text-align: right; font-variant-numeric: tabular-nums; }
.timeline { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; font-size: 13px; }
.timeline li { display: grid; grid-template-columns: 70px minmax(0, 1fr); gap: 10px; }
.timeline .at { color: var(--faint); font-variant-numeric: tabular-nums; }
.summary { font-size: 15px; line-height: 1.6; }
pre.json { background: var(--surface-2); padding: 10px 12px; border-radius: var(--radius); overflow: auto; max-height: 320px; margin: 0; white-space: pre-wrap; }

/* Dialog */
dialog { border: 1px solid var(--border); border-radius: 14px; padding: 0; background: var(--surface); color: var(--text); width: min(560px, calc(100vw - 32px)); max-height: calc(100vh - 48px); }
dialog::backdrop { background: rgba(8, 6, 26, .7); }
dialog form, dialog .body { padding: 20px 22px; display: grid; gap: 14px; }
dialog .foot { display: flex; justify-content: flex-end; gap: 8px; margin-top: 4px; }
dialog.wide { width: min(860px, calc(100vw - 32px)); }

/* Toast */
.toasts { position: fixed; right: 20px; bottom: 20px; display: grid; gap: 8px; z-index: 50; }
.toast { background: #1A1745; color: #ECEAFE; padding: 11px 15px; border-radius: 10px; font-size: 14px; max-width: 420px; border-left: 3px solid var(--lime); box-shadow: 0 10px 30px rgba(0,0,0,.35); }
.toast.bad { border-left-color: #E26A5E; }

.skel { background: linear-gradient(90deg, var(--surface-2), var(--border), var(--surface-2)); background-size: 200% 100%; animation: sk 1.2s infinite; border-radius: 6px; height: 14px; }
@keyframes sk { to { background-position: -200% 0; } }

@media (max-width: 1100px) { .g4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .g21, .g3 { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 760px) {
  .app { grid-template-columns: minmax(0, 1fr); }
  .side { position: static; height: auto; flex-direction: row; overflow-x: auto; padding: 10px 12px; gap: 4px; }
  .brand { padding: 0 8px 0 0; }
  .side .brand b, .account, .side-foot, .nav .soon, .nav-group, .topbar { display: none; }
  .nav { flex: none; }
  .nav.on { border-left: 0; border-bottom: 2px solid var(--amber); border-radius: 6px 6px 0 0; }
  .main { padding: 16px 16px 40px; }
  .g4, .g2 { grid-template-columns: minmax(0, 1fr); }
}

/* VA8.2 onboarding */
.onboard fieldset { border: 0; padding: 0; margin: 0; display: grid; gap: 10px; }
.onboard legend { font-size: 14px; margin-bottom: 8px; display: flex; gap: 8px; align-items: center; }
.onboard legend > b { display: inline-grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; background: var(--surface-2); font-size: 12px; }
.picks { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 8px; }
.pick { display: flex; gap: 8px; align-items: flex-start; border: 1px solid var(--border); border-radius: 10px; padding: 8px 10px; font-size: 13px; cursor: pointer; }
.pick input { width: auto; height: auto; margin-top: 2px; }
.pick.big > span { display: grid; gap: 2px; }
.pick:has(input:checked) { border-color: var(--amber); background: var(--surface-2); }

/* VA8.3 test chat and translations */
.chat #chat-log { max-height: 46vh; overflow: auto; }
.bubble .tl { margin-top: 6px; padding-top: 6px; border-top: 1px dashed var(--border); color: var(--muted); }
.webcall { min-width: min(420px, 80vw); }
.webcall .meter { margin: 14px 0 6px; }

/* D3a overview (design page 15) */
.g5 { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.bars.tall { height: 210px; gap: 14px; border-bottom: 0; }
.bars .stackbar { width: 100%; display: flex; flex-direction: column; border-radius: 6px 6px 0 0; overflow: hidden; min-height: 3px; }
.stackbar .miss { background: var(--violet); min-height: 0; }
.stackbar .hit { background: var(--lime); min-height: 0; }
.axis.days { gap: 14px; } .axis.days span { flex: 1; text-align: center; }
.livelist { display: grid; }
.liveitem { display: grid; grid-template-columns: minmax(0, 1fr) 22px 54px; gap: 12px; align-items: center; padding: 11px 0; border-bottom: 1px solid var(--border); color: var(--text); }
.liveitem:hover { text-decoration: none; background: var(--surface-2); }
.liveitem > span:first-child { display: grid; }
.liveitem svg { width: 20px; height: 20px; stroke: var(--lime); stroke-width: 2.4; stroke-linecap: round; fill: none; }
.liveitem .mono { text-align: right; font-size: 13.5px; }
.attn { display: grid; gap: 10px; }
.attn a { display: flex; gap: 10px; align-items: center; color: var(--text); font-size: 14.5px; }
.topagent { margin-bottom: 12px; } .topagent b { font-size: 14.5px; }
.topagent .meter { height: 6px; background: var(--violet); margin-top: 6px; } .topagent .meter i { background: var(--lime); }
.camps { display: grid; gap: 10px; }
.camps a { display: flex; justify-content: space-between; gap: 10px; color: var(--text); font-size: 14.5px; }
.camps .dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--faint); margin-right: 8px; vertical-align: 2px; }
.camps .dot.on { background: var(--lime); } .camps .dot.warn { background: var(--coral); }
@media (max-width: 1250px) { .g5 { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 760px) { .g5 { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); } }

/* D3a sign-in and sign-up (design page 5) */
body.signed-out .app { grid-template-columns: minmax(0, 1fr); }
body.signed-out .side, body.signed-out .topbar { display: none; }
body.signed-out .main { padding: 0; max-width: none; }
.authpage { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); min-height: 100vh; }
.authside { position: relative; display: flex; flex-direction: column; padding: 36px 56px 30px; background: radial-gradient(60% 45% at 18% 38%, #2A2275 0%, rgba(42, 34, 117, .25) 55%, transparent 80%), #0F0C29; color: #ECEAFE; overflow: hidden; }
.authside .brand { padding: 0; }
.authside .by { font-size: 12px; color: #A9A6D0; margin-left: 2px; }
.authpitch { margin: auto 0; max-width: 560px; }
.authpitch .mascot { width: 150px; height: auto; display: block; margin-bottom: 28px; filter: drop-shadow(0 12px 16px rgba(0, 0, 0, .35)); }
.authpitch h2 { font-size: clamp(34px, 3.6vw, 52px); font-weight: 800; letter-spacing: -.035em; line-height: 1.04; margin: 0; }
.checks { list-style: none; margin: 26px 0 0; padding: 0; display: grid; gap: 12px; font-size: 17px; color: #CFCCF0; }
.checks li::before { content: "✓ "; color: #ECEAFE; }
.copy { font-size: 13px; color: #7D79AE; }
.authform { display: grid; place-items: center; padding: 40px 32px; background: #0F0C29; }
:root[data-theme="light"] .authform { background: var(--bg); }
.authbox { width: min(420px, 100%); }
.authbox h1 { font-size: 32px; }
.authbox > .sub { color: var(--muted); font-size: 16px; margin: 6px 0 18px; }
.authbox .card { background: transparent; border: 0; padding: 0; }
.authbox input, .authbox select { height: 46px; font-size: 15px; background: #15133B; border-color: #2A2766; border-radius: 10px; }
:root[data-theme="light"] .authbox input, :root[data-theme="light"] .authbox select { background: #fff; border-color: var(--border-strong); }
.authbox label.f { font-size: 14px; color: var(--text); font-weight: 600; }
button.wide { width: 100%; height: 48px; font-size: 16px; justify-content: center; }
.or { display: flex; align-items: center; gap: 12px; color: var(--faint); font-size: 13px; }
.or::before, .or::after { content: ""; flex: 1; height: 1px; background: var(--border); }
#google-slot:empty, #google-slot:empty + .or { display: none; }
@media (max-width: 900px) { .authpage { grid-template-columns: 1fr; } .authside { padding: 24px; } .authpitch { margin: 28px 0; } .authpitch .mascot { width: 100px; } .copy { display: none; } }

/* D3a describe the job (design page 10) */
.describe { max-width: 1160px; margin: 0 auto; }
.steps-mini { list-style: none; display: flex; gap: 10px; justify-content: flex-end; margin: 0 0 18px; padding: 0; font-size: 14.5px; color: var(--faint); }
.steps-mini li + li::before { content: "— "; color: var(--faint); }
.steps-mini .done { color: var(--lime); }
.steps-mini .now { color: var(--text); font-weight: 700; }
h1.huge { font-size: clamp(34px, 4vw, 52px); letter-spacing: -.04em; }
.describe > .sub { color: var(--muted); font-size: 18px; margin: 8px 0 22px; }
textarea.brief { min-height: 136px; font-size: 18px; line-height: 1.55; padding: 18px 20px; border: 2px solid var(--lime); border-radius: 14px; background: var(--surface); box-shadow: 0 0 0 5px rgba(198, 241, 89, .08); }
.choices { display: grid; grid-template-columns: auto minmax(160px, 220px) minmax(180px, 260px) 1fr; gap: 16px; align-items: end; }
.choices .create { justify-self: end; height: 50px; padding: 0 26px; font-size: 17px; border-radius: 12px; }
.describe .f { display: grid; gap: 6px; }
.lbl { font-size: 14px; font-weight: 600; color: var(--text); }
.seg.big { border-radius: 10px; padding: 3px; gap: 3px; background: var(--surface); border-color: var(--border); }
.seg.big label { position: relative; }
.seg.big input { position: absolute; opacity: 0; }
.seg.big span { display: block; padding: 7px 16px; border-radius: 8px; font-weight: 600; cursor: pointer; color: var(--muted); }
.seg.big input:checked + span { background: var(--lime); color: var(--on-primary); }
.seg.big input:focus-visible + span { box-shadow: var(--shadow-focus); }
.chip { display: inline-flex; position: relative; }
.chip input { position: absolute; opacity: 0; }
.chip span { padding: 6px 13px; border-radius: 999px; border: 1px solid var(--border-strong); font-size: 14px; cursor: pointer; }
.chip input:checked + span { background: var(--violet); border-color: var(--lav); color: #ECEAFE; }
.chip input:focus-visible + span { box-shadow: var(--shadow-focus); }
details.about summary { cursor: pointer; font-weight: 600; font-size: 14px; }
details.about textarea { margin-top: 8px; }
.willbuild { border: 1px solid var(--border); border-radius: 14px; padding: 16px 18px; background: var(--surface); display: grid; gap: 12px; }
.willbuild .badge { font-size: 13.5px; padding: 8px 11px; }
.tpls { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin-top: 14px; }
.tpl { height: auto; display: grid; gap: 6px; text-align: left; align-content: start; padding: 16px 18px; border-radius: 14px; background: var(--surface); border-color: var(--border); white-space: normal; font-weight: 400; }
.tpl b { font-size: 16px; font-weight: 700; }
.tpl span { color: var(--muted); font-size: 14px; }
.tpl:hover { border-color: var(--lav); }
@media (max-width: 1000px) { .choices { grid-template-columns: 1fr 1fr; } .choices .create { grid-column: 1 / -1; justify-self: stretch; } .tpls { grid-template-columns: 1fr 1fr; } }
@media (max-width: 600px) { .choices, .tpls { grid-template-columns: 1fr; } }
.main:focus, .main:focus-visible { outline: none; box-shadow: none; }
.authbox label.row { flex-wrap: nowrap; align-items: flex-start; gap: 10px; font-size: 13.5px; color: var(--muted); }
.authbox label.row input { margin-top: 3px; flex: none; }

/* D3b agents (design page 6) */
.agentgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); gap: 16px; }
.agentcard { background: var(--surface); border: 1px solid var(--border); border-radius: 16px; padding: 18px 20px; display: grid; gap: 14px; align-content: start; }
.ac-head { display: grid; grid-template-columns: 46px minmax(0, 1fr) auto; gap: 12px; align-items: center; }
.tile { width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center; font-weight: 800; font-size: 17px; }
.tile.lime { background: var(--lime); color: var(--ink); } .tile.lav { background: var(--lav); color: var(--ink); }
.tile.coral { background: var(--coral); color: var(--ink); } .tile.ink { background: var(--violet); color: #ECEAFE; }
.ac-name { display: grid; min-width: 0; } .ac-name b { font-size: 18px; color: var(--text); } .ac-name a:hover { text-decoration: none; }
.ac-name span { color: var(--muted); font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.chipx { background: var(--surface-2); border: 1px solid var(--border); border-radius: 8px; padding: 3px 9px; font-size: 13px; font-weight: 600; }
.chipx:empty { display: none; }
.ac-stats { display: flex; gap: 26px; border-top: 1px solid var(--border); padding-top: 12px; }
.ac-stats div { display: grid; } .ac-stats span { font-size: 13px; color: var(--muted); } .ac-stats b { font-size: 16px; }
.ac-stats b.hi { color: var(--lime); }
:root[data-theme="light"] .ac-stats b.hi { color: var(--ok); }
.ac-actions { gap: 6px; }

/* D3b calls (design pages 7 and 16) */
.filters { margin-bottom: 14px; gap: 8px; }
.filters input { max-width: 360px; height: 40px; border-radius: 10px; }
button.pill { height: 34px; border-radius: 999px; padding: 0 14px; background: var(--surface); border-color: var(--border-strong); font-size: 14px; }
button.pill.on { border-color: var(--lime); color: var(--lime); background: rgba(198, 241, 89, .08); }
:root[data-theme="light"] button.pill.on { color: var(--ok); border-color: var(--ok); }
.table.calls td { padding: 13px 16px; vertical-align: middle; font-size: 14.5px; }
.table.calls th { padding: 12px 16px; font-size: 13px; }
.callhead { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.player .wave { gap: 14px; }
.player .wave .t { font-size: 14px; color: var(--muted); min-width: 52px; }
.player .wave svg.w { height: 48px; }
.player .wave.ai svg.w rect.p { fill: var(--lime); }
.player .wave.desk svg.w rect, .player .wave.transfer svg.w rect { fill: #6B3A3A; }
.player .wave.desk svg.w rect.p, .player .wave.transfer svg.w rect.p { fill: var(--coral); }
.turns { gap: 12px; }
.turn { display: flex; grid-template-columns: none; }
.turn .bubble { max-width: 78%; border-radius: 12px; padding: 9px 13px 11px; font-size: 14.5px; }
.turn .who { font-size: 12px; margin-bottom: 3px; }
.turn.agent .bubble { background: var(--violet); color: #ECEAFE; } .turn.agent .who { color: #D4CFFF; }
.turn.caller { justify-content: flex-end; } .turn.caller .bubble { background: var(--peach); color: #231A15; } .turn.caller .who { color: #6B5249; }
.turn.desk .bubble { background: #3A1D2A; color: #FFE3D6; border: 1px solid var(--coral); } .turn.desk .who { color: var(--coral); }
.turn.tool { justify-content: center; } .turn.tool .bubble { background: transparent; border: 1px dashed #3A3870; color: var(--lime); font-family: var(--mono); font-size: 13px; max-width: 90%; }
:root[data-theme="light"] .turn.tool .bubble { color: var(--ok); }
.timeline li { grid-template-columns: 84px minmax(0, 1fr); }

/* D3b agent flow (design page 11) */
.flow { display: grid; justify-items: center; padding: 18px; border-radius: 12px; background-color: var(--bg); background-image: radial-gradient(var(--border) 1px, transparent 1px); background-size: 18px 18px; min-height: 420px; align-content: start; }
.flowrow { display: flex; gap: 16px; flex-wrap: wrap; justify-content: center; width: 100%; }
.fbox { display: grid; gap: 2px; min-width: 220px; max-width: 340px; padding: 12px 14px; border-radius: 12px; background: var(--surface); border: 1px solid var(--border-strong); text-align: left; }
.fbox .kind { font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: var(--lime); }
.fbox b { font-size: 15.5px; } .fbox > span:last-child { color: var(--muted); font-size: 13.5px; }
.fbox.persona { border-color: var(--lav); } .fbox.persona .kind { color: var(--lav); }
.fbox.on { border: 2px solid var(--lime); box-shadow: 0 0 0 4px rgba(198, 241, 89, .08); }
.fbox.hand { border-color: var(--coral); min-width: 360px; } .fbox.hand .kind { color: var(--coral); }
.fbox.end { border-color: #E85A6A; } .fbox.end .kind { color: #FF8A95; }
:root[data-theme="light"] .fbox .kind { color: var(--ok); }
.fline { width: 2px; height: 22px; background: var(--border-strong); }

/* D3c campaigns (design page 12) */
.g6 { grid-template-columns: repeat(6, minmax(0, 1fr)); }
.stat .value.hi { color: var(--lime); } .stat .value.warm { color: var(--coral); } .stat .value.lav { color: var(--lav); }
:root[data-theme="light"] .stat .value.hi { color: var(--ok); }
.card.progress { padding: 14px 18px; }
.pbar { display: flex; height: 10px; border-radius: 6px; overflow: hidden; background: var(--violet); }
.pbar i { display: block; height: 100%; } .pbar .hit { background: var(--lime); } .pbar .no { background: #F05A5A; } .pbar .cb { background: var(--lav); } .pbar .oth { background: #4B4692; }
.kv.rules { grid-template-columns: auto 1fr; } .kv.rules dd { text-align: right; }
.okline { margin-top: 12px; padding: 9px 12px; border-radius: 9px; background: var(--ok-bg); color: var(--ok); font-size: 13.5px; font-weight: 600; }
@media (max-width: 1250px) { .g6 { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

/* D3c live desk (design page 8) */
.deskgrid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr) minmax(220px, .75fr); gap: 16px; margin-bottom: 16px; align-items: start; }
.handover { background: #2A1A22; border-color: var(--coral); display: grid; gap: 10px; min-height: 300px; align-content: start; }
.handover.calm { background: var(--surface); border-color: var(--border); }
.handover .who { font-size: 28px; font-weight: 800; letter-spacing: -.03em; margin: 6px 0 0; color: var(--text); }
.knows { background: rgba(254, 121, 76, .1); border-radius: 10px; padding: 12px 14px; display: grid; gap: 4px; }
.knows b { color: var(--coral); font-size: 13px; } .knows p { margin: 0 0 6px; }
.knows:empty { display: none; }
a.btn.answer { background: var(--coral); border-color: var(--coral); color: var(--ink); font-weight: 700; height: 46px; padding: 0 22px; }
:root[data-theme="light"] .handover { background: #FFF1EA; }
.facts { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.facts div { background: var(--surface-2); border-radius: 10px; padding: 9px 12px; display: grid; }
.facts span { font-size: 12.5px; color: var(--muted); text-transform: capitalize; } .facts b { font-size: 15px; }
.mini { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 5px 0; font-size: 14.5px; }
.mini .ring { display: inline-block; width: 3px; height: 12px; background: var(--coral); margin-right: 8px; border-radius: 2px; vertical-align: -1px; }
@media (max-width: 1150px) { .deskgrid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 760px) { .deskgrid { grid-template-columns: 1fr; } }

/* D3c billing (design page 9) */
.stat .of { font-size: 17px; color: var(--muted); font-weight: 600; }
.meter.lime { height: 8px; background: var(--violet); margin: 10px 0 4px; } .meter.lime i { background: var(--lime); }
.addmoney form { gap: 12px; }
.addmoney .picks { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.addmoney .pick { padding: 12px 14px; font-size: 14.5px; font-weight: 600; border-color: var(--border-strong); }
.pick:has(input:checked) { border-color: var(--lime); box-shadow: inset 0 0 0 1px var(--lime); }

/* D3c phone numbers and providers (design pages 17 and 18) */
.table.nums tr.sel td { background: var(--surface-2); }
.table.nums td { padding: 13px 16px; }
.numpanel { display: grid; gap: 10px; align-content: start; }
.numpanel b.big { font-size: 17px; }
.chipx.big { font-size: 14.5px; padding: 7px 12px; }
.day { font-size: 12.5px; font-weight: 600; padding: 3px 9px; border-radius: 999px; background: var(--surface-2); color: var(--faint); }
.day.on { background: rgba(198, 241, 89, .14); color: var(--lime); }
:root[data-theme="light"] .day.on { color: var(--ok); }
.afters { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.after { border: 1px solid var(--border-strong); border-radius: 10px; padding: 9px 11px; display: grid; }
.after b { font-size: 14px; } .after span { font-size: 12.5px; color: var(--muted); }
.after.on { border: 2px solid var(--lime); }
h2.section { font-size: 17px; margin: 0 0 12px; }
.carriers { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; }
.carrier { display: grid; gap: 10px; align-content: start; }
.cr-head { display: grid; grid-template-columns: 40px minmax(0, 1fr); gap: 10px; align-items: center; }
.cr-head b { font-size: 16px; }
.ctile { width: 40px; height: 40px; border-radius: 10px; display: grid; place-items: center; font-weight: 800; font-size: 13px; background: var(--violet); color: #ECEAFE; }
.ctile.twilio { background: #4A1D2A; color: #FF8A95; } .ctile.telnyx { background: #183A2A; color: #6EE7A7; } .ctile.whatsapp { background: #17402A; color: #7CE3A1; } .ctile.sip { background: #2B2B55; color: #D4CFFF; }
.cr-foot { display: flex; gap: 10px; align-items: center; border-top: 1px solid var(--border); padding-top: 10px; }
.carrier.connect { border-style: dashed; }
.ctile { text-transform: capitalize; } .ctile.sip, .ctile.whatsapp { text-transform: uppercase; }
.handover > .badge { justify-self: start; }

/* D3d developers, integrations, analytics (design pages 14, 19, 13) */
.hook { padding: 10px 0 14px; border-bottom: 1px solid var(--border); }
.code-block { margin: 0; background: var(--bg); border: 1px solid var(--border); border-radius: 12px; padding: 14px 16px; font-size: 12.8px; line-height: 1.65; white-space: pre; overflow-x: auto; color: #E3E0FF; }
:root[data-theme="light"] .code-block { color: var(--text); }
.widgetpreview { margin-top: 12px; position: relative; min-height: 130px; border-radius: 12px; background: var(--surface-2); padding: 10px 12px; }
.talkchip { position: absolute; right: 14px; bottom: 14px; display: flex; gap: 10px; align-items: center; background: #fff; color: #0F0C29; border-radius: 12px; padding: 9px 14px; box-shadow: 0 8px 20px rgba(0,0,0,.3); }
.talkchip > span:last-child { display: grid; } .talkchip b { font-size: 14px; } .talkchip .dir { color: #6E6A92; font-size: 12px; }
.talkchip .mic { width: 30px; height: 30px; border-radius: 50%; background: var(--lime); display: grid; place-items: center; font-size: 14px; }
.movebanner { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; background: #2A1A22; border-color: var(--coral); margin-bottom: 16px; }
.movebanner h2 { margin-bottom: 4px; } :root[data-theme="light"] .movebanner { background: #FFF1EA; }
.igrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 14px; }
.igcard { display: grid; gap: 14px; align-content: space-between; }
.linechart { width: 100%; height: 190px; display: block; }
.linechart .grid { stroke: var(--border); stroke-width: 1; }
.linechart .rate { fill: none; stroke: var(--lime); stroke-width: 2.6; vector-effect: non-scaling-stroke; stroke-linejoin: round; }
.linechart .calls { fill: none; stroke: var(--coral); stroke-width: 2; stroke-dasharray: 6 5; vector-effect: non-scaling-stroke; }
.linechart + .axis { display: flex; justify-content: space-between; }
.qa-ghost { margin-top: 12px; font-size: 14px; color: var(--faint); } .qa-ghost .meter { height: 6px; background: var(--surface-2); margin-top: 5px; }
.pbar.ghost { background: var(--surface-2); }
.qa-ghost .meter i { width: 0; }
a.btn.small { height: 30px; padding: 0 12px; font-size: 13px; }
