/* Ethara Screening: Ethara Portal design system (PortalTokens v1.0), light and dark.
   Every page loads this one file; the candidate call screen is always dark (.call). */
@font-face { font-family: "Plus Jakarta Sans"; src: url("/static/fonts/plus-jakarta-sans.woff2") format("woff2"); font-weight: 200 800; font-display: swap; }
@font-face { font-family: "DM Mono"; src: url("/static/fonts/dm-mono-400.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "DM Mono"; src: url("/static/fonts/dm-mono-500.woff2") format("woff2"); font-weight: 500; font-display: swap; }

:root {
  --primary: #B800B8; --primary-hover: #A000A0; --primary-text: #A800A8; --primary-subtle: #FBDAF7; --on-primary: #fff;
  --accent2: #6060C8;
  --ground: #F2F4F7; --sunken: #E7EAEF; --surface: #FFFFFF; --control: #F7F8FA; --control-hi: #E9EBEF; --field: #FFFFFF;
  --hairline: #DFE1E6; --border-strong: #8F8B8F; --zebra: #FCFCFD;
  --text-1: #030213; --text-2: #575764; --text-3: #6E6E7A;
  --ok-t: #047857; --ok-bg: #ECFDF5; --ok-dot: #059669;
  --info-t: #1D4ED8; --info-bg: #EFF6FF; --info-dot: #60A5FA;
  --warn-t: #B45309; --warn-bg: #FFF7ED; --warn-dot: #F59E0B;
  --bad-t: #B91C1C; --bad-bg: #FEF2F2; --bad-dot: #EF4444;
  --violet-t: #7C3AED; --violet-bg: #F3E8FF;
  --s1: 0 1px 2px rgba(16,18,38,.05), 0 1px 3px rgba(16,18,38,.09);
  --s2: 0 2px 4px -2px rgba(16,18,38,.07), 0 4px 10px -2px rgba(16,18,38,.11);
  --s4: 0 8px 10px -6px rgba(16,18,38,.06), 0 20px 32px -8px rgba(16,18,38,.16);
  --brand-bg: #eef0f6; --brand-accent: #6461a0;
  --mesh: radial-gradient(ellipse at 20% 20%, rgba(168,0,168,.055) 0%, transparent 56%), radial-gradient(ellipse at 82% 76%, rgba(14,165,233,.055) 0%, transparent 58%), radial-gradient(ellipse at 58% 34%, rgba(96,96,200,.045) 0%, transparent 50%), #eef0f6;
  --grid-1: rgba(100,97,160,.10); --grid-2: rgba(100,97,160,.08);
  --sp-primary: rgba(168,0,168,.10); --sp-muted: rgba(100,97,160,.10); --sp-sheen: rgba(24,23,42,.05); --sp-blend: multiply;
  --mark-filter: brightness(0) saturate(100%) invert(8%) sepia(18%) saturate(1650%) hue-rotate(210deg) brightness(80%) contrast(108%);
  --mark-shadow: drop-shadow(0 14px 30px rgba(25,24,46,.20)) drop-shadow(0 0 16px rgba(168,0,168,.12));
  --glass-bg: rgba(255,255,255,.95); --glass-border: rgba(132,132,150,.36);
  --glass-shadow: 0 14px 36px rgba(25,24,46,.10), inset 0 1px 0 rgba(255,255,255,.85);
  --neon: linear-gradient(135deg, #a800a8 0%, #6060c8 100%);
  --call-bg: #0E0E12; --call-tile: #1A1A20; --call-text: #ECECF0; --call-text-2: #A0A0AC;
  --f-ui: "Plus Jakarta Sans", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --f-mono: "DM Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  --r-s: 6px; --r-m: 8px; --r-l: 12px;
  --list-bg: #fff;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) {
  --primary: #C552BC; --primary-hover: #D66ECD; --primary-text: #D66ECD; --primary-subtle: #3A1736; --on-primary: #fff; --accent2: #A0A0AC;
  --ground: #0A0A0D; --sunken: #141418; --surface: #18181C; --control: #1F1F24; --control-hi: #2A2A31; --field: #222228;
  --hairline: #2F2F35; --border-strong: #676467; --zebra: #1B1B20;
  --text-1: #ECECF0; --text-2: #A0A0AC; --text-3: #8A8A96;
  --ok-t: #4ADE80; --ok-bg: #0F2A1C; --info-t: #84AEF9; --info-bg: #142036; --warn-t: #FBBF24; --warn-bg: #2E2210; --bad-t: #F87171; --bad-bg: #2E1414;
  --violet-t: #C4B5FD; --violet-bg: #2A1F3D;
  --brand-bg: #0A0A0D; --brand-accent: #A0A0AC;
  --mesh: radial-gradient(ellipse at 20% 20%, rgba(238,0,238,.045) 0%, transparent 56%), radial-gradient(ellipse at 82% 76%, rgba(56,189,248,.04) 0%, transparent 58%), radial-gradient(ellipse at 58% 34%, rgba(160,160,172,.035) 0%, transparent 50%), #0A0A0D;
  --grid-1: rgba(160,160,172,.08); --grid-2: rgba(160,160,172,.07);
  --sp-primary: rgba(238,0,238,.18); --sp-muted: rgba(160,160,172,.15); --sp-sheen: rgba(236,236,240,.09); --sp-blend: screen;
  --mark-filter: brightness(1) saturate(1); --mark-shadow: drop-shadow(0 14px 30px rgba(0,0,0,.42)) drop-shadow(0 0 16px rgba(238,0,238,.12));
  --glass-bg: rgba(24,24,28,.86); --glass-border: rgba(160,160,172,.16); --glass-shadow: 0 14px 36px rgba(0,0,0,.28), inset 0 1px 0 rgba(255,255,255,.035);
  --neon: linear-gradient(135deg, #EE00EE 0%, #A0A0AC 100%);
  --list-bg: #1F1F24;
  color-scheme: dark;
} }
:root[data-theme="dark"] {
  --primary: #C552BC; --primary-hover: #D66ECD; --primary-text: #D66ECD; --primary-subtle: #3A1736; --on-primary: #fff; --accent2: #A0A0AC;
  --ground: #0A0A0D; --sunken: #141418; --surface: #18181C; --control: #1F1F24; --control-hi: #2A2A31; --field: #222228;
  --hairline: #2F2F35; --border-strong: #676467; --zebra: #1B1B20;
  --text-1: #ECECF0; --text-2: #A0A0AC; --text-3: #8A8A96;
  --ok-t: #4ADE80; --ok-bg: #0F2A1C; --info-t: #84AEF9; --info-bg: #142036; --warn-t: #FBBF24; --warn-bg: #2E2210; --bad-t: #F87171; --bad-bg: #2E1414;
  --violet-t: #C4B5FD; --violet-bg: #2A1F3D;
  --brand-bg: #0A0A0D; --brand-accent: #A0A0AC;
  --mesh: radial-gradient(ellipse at 20% 20%, rgba(238,0,238,.045) 0%, transparent 56%), radial-gradient(ellipse at 82% 76%, rgba(56,189,248,.04) 0%, transparent 58%), radial-gradient(ellipse at 58% 34%, rgba(160,160,172,.035) 0%, transparent 50%), #0A0A0D;
  --grid-1: rgba(160,160,172,.08); --grid-2: rgba(160,160,172,.07);
  --sp-primary: rgba(238,0,238,.18); --sp-muted: rgba(160,160,172,.15); --sp-sheen: rgba(236,236,240,.09); --sp-blend: screen;
  --mark-filter: brightness(1) saturate(1); --mark-shadow: drop-shadow(0 14px 30px rgba(0,0,0,.42)) drop-shadow(0 0 16px rgba(238,0,238,.12));
  --glass-bg: rgba(24,24,28,.86); --glass-border: rgba(160,160,172,.16); --glass-shadow: 0 14px 36px rgba(0,0,0,.28), inset 0 1px 0 rgba(255,255,255,.035);
  --neon: linear-gradient(135deg, #EE00EE 0%, #A0A0AC 100%);
  --list-bg: #1F1F24;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--ground); color: var(--text-1); font-family: var(--f-ui); font-size: 14px; line-height: 1.45; -webkit-font-smoothing: antialiased; }
h1, h2, h3, h4 { margin: 0; text-wrap: balance; }
p { margin: 0; }
button, input, select, textarea { font: inherit; color: inherit; }
a { color: var(--primary-text); }
[hidden] { display: none !important; }
.mono, .num { font-family: var(--f-mono); font-variant-numeric: tabular-nums; }
:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.muted { color: var(--text-2); }
.faint { color: var(--text-3); }
.small { font-size: 12.5px; }
.err, .error { color: var(--bad-t); }
.okc { color: var(--ok-t); }

/* ── atoms ── */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; height: 36px; padding: 0 14px; border-radius: 8px; border: 1px solid var(--hairline); background: var(--surface); color: var(--text-1); font-weight: 600; font-size: 13px; cursor: pointer; white-space: nowrap; text-decoration: none; }
.btn:hover:not(:disabled) { background: var(--control-hi); }
.btn:disabled { opacity: .55; cursor: default; }
.btn.sm { height: 28px; padding: 0 10px; border-radius: 7px; font-size: 12px; }
.btn.primary { background: var(--primary); border-color: var(--primary); color: var(--on-primary); }
.btn.primary:hover:not(:disabled) { background: var(--primary-hover); }
.btn.ghost { background: transparent; border-color: transparent; }
.btn.ghost:hover:not(:disabled) { background: var(--control-hi); }
.btn.dest { background: var(--bad-bg); color: var(--bad-t); border-color: transparent; }
.btn.dest:hover:not(:disabled) { background: color-mix(in srgb, var(--bad-bg) 70%, var(--bad-dot)); }
.btn svg { width: 15px; height: 15px; flex: none; }
.tag { display: inline-flex; align-items: center; gap: 5px; height: 20px; padding: 0 8px; border-radius: 999px; font-size: 11.5px; font-weight: 600; border: 1px solid var(--hairline); color: var(--text-2); white-space: nowrap; }
.tag.ok { background: var(--ok-bg); color: var(--ok-t); border-color: transparent; }
.tag.warn { background: var(--warn-bg); color: var(--warn-t); border-color: transparent; }
.tag.bad { background: var(--bad-bg); color: var(--bad-t); border-color: transparent; }
.tag.info { background: var(--info-bg); color: var(--info-t); border-color: transparent; }
.tag.pri { background: var(--primary-subtle); color: var(--primary-text); border-color: transparent; }
.tag.vio { background: var(--violet-bg); color: var(--violet-t); border-color: transparent; }
.dot { width: 7px; height: 7px; border-radius: 50%; background: currentColor; display: inline-block; flex: none; }
.card { background: var(--surface); border: 1px solid var(--hairline); border-radius: var(--r-l); box-shadow: var(--s1); min-width: 0; }
.card-h { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; padding: 14px 16px; border-bottom: 1px solid var(--hairline); flex-wrap: wrap; }
.card-h h3 { font-size: 14.5px; font-weight: 700; }
.card-h p { font-size: 12.5px; color: var(--text-2); margin-top: 2px; }
.card-h .acts { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.card-b { padding: 16px; }
.eyebrow { font-size: 11px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--text-3); }
.field { display: grid; gap: 6px; min-width: 0; }
.field > label, .field > .lbl { font-size: 12.5px; font-weight: 600; color: var(--text-2); }
.field .hint, .hint { font-size: 12px; color: var(--text-3); }
.input, .field input:not([type=checkbox]):not([type=file]), .field textarea, textarea.input { height: 36px; border-radius: 8px; border: 1px solid var(--border-strong); background: var(--field); padding: 0 11px; font-size: 13px; width: 100%; min-width: 0; }
textarea.input, .field textarea { height: auto; min-height: 76px; padding: 8px 11px; resize: vertical; line-height: 1.45; }
.input.num { width: 64px; text-align: center; font-family: var(--f-mono); padding: 0 6px; }
.input:focus, .field input:focus, .field textarea:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 18%, transparent); }
.input[aria-invalid="true"] { border-color: var(--bad-dot); }
.seg { display: inline-flex; padding: 3px; border-radius: 9px; background: var(--sunken); gap: 2px; flex-wrap: wrap; }
.seg button { border: 0; background: transparent; height: 28px; padding: 0 11px; border-radius: 7px; font-size: 12.5px; font-weight: 600; color: var(--text-2); cursor: pointer; }
.seg button:hover { color: var(--text-1); }
.seg button[aria-pressed="true"], .seg button.on { background: var(--surface); color: var(--text-1); box-shadow: var(--s2); }
.sw { position: relative; width: 34px; height: 20px; border-radius: 999px; background: var(--control-hi); border: 1px solid var(--hairline); cursor: pointer; flex: none; padding: 0; }
.sw::after { content: ""; position: absolute; top: 2px; left: 2px; width: 14px; height: 14px; border-radius: 50%; background: var(--surface); box-shadow: var(--s1); transition: left .15s cubic-bezier(.2, 0, 0, 1); }
.sw[aria-checked="true"] { background: var(--primary); border-color: var(--primary); }
.sw[aria-checked="true"]::after { left: 16px; }
.sw:disabled { opacity: .5; cursor: default; }
.swl { display: inline-flex; gap: 8px; align-items: center; font-size: 12.5px; font-weight: 600; color: var(--text-2); }
table.t { width: 100%; border-collapse: collapse; font-size: 13px; }
table.t th { height: 36px; text-align: left; font-size: 11px; letter-spacing: .05em; text-transform: uppercase; color: var(--text-3); font-weight: 600; background: var(--control); padding: 0 12px; border-bottom: 1px solid var(--hairline); white-space: nowrap; }
table.t td { padding: 9px 12px; border-bottom: 1px solid var(--hairline); vertical-align: middle; }
table.t tr:last-child td { border-bottom: 0; }
table.t tbody tr:hover td { background: var(--control); }
table.t tr.link { cursor: pointer; }
table.t td.empty { text-align: center; color: var(--text-2); padding: 26px 12px; }
table.t .who b { display: block; font-weight: 600; }
table.t .who small { color: var(--text-3); font-size: 12px; }
.tw { overflow-x: auto; }
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(152px, 1fr)); gap: 10px; }
.kpi { padding: 14px 16px; }
.kpi .v { font-family: var(--f-mono); font-size: 26px; font-weight: 500; letter-spacing: -.02em; margin-top: 6px; }
.kpi .s { font-size: 12px; color: var(--text-2); margin-top: 2px; }
.bar { height: 6px; border-radius: 999px; background: var(--control-hi); overflow: hidden; }
.bar > i { display: block; height: 100%; background: var(--primary); border-radius: 999px; }
.note { font-size: 12.5px; color: var(--text-2); display: flex; gap: 8px; align-items: flex-start; padding: 10px 12px; border-radius: 8px; background: var(--control); border: 1px solid var(--hairline); }
.note.warn { background: var(--warn-bg); color: var(--warn-t); border-color: transparent; }
.note.ok { background: var(--ok-bg); color: var(--ok-t); border-color: transparent; }
.note.bad { background: var(--bad-bg); color: var(--bad-t); border-color: transparent; }
.note.info { background: var(--info-bg); color: var(--info-t); border-color: transparent; }
.note ul { margin: 4px 0 0; padding-left: 18px; }
.row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.grow { flex: 1; }
.stack { display: grid; gap: 12px; }
.spinner { width: 14px; height: 14px; border-radius: 50%; border: 2px solid color-mix(in srgb, currentColor 25%, transparent); border-top-color: currentColor; display: inline-block; vertical-align: -2px; margin-right: 8px; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.codebox { font-family: var(--f-mono); font-weight: 500; letter-spacing: .04em; }

/* custom selects (ui.js turns every <select> into .csel) */
select { height: 36px; border-radius: 8px; border: 1px solid var(--border-strong); background: var(--field); padding: 0 10px; }
.csel { position: relative; display: block; width: 100%; min-width: 0; }
.csel-native { position: absolute !important; opacity: 0; pointer-events: none; width: 1px !important; height: 1px !important; padding: 0 !important; border: 0 !important; left: 0; bottom: 0; }
.csel-btn { width: 100%; height: 36px; display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 0 11px; border-radius: 8px; border: 1px solid var(--border-strong); background: var(--field); color: var(--text-1); font-size: 13px; text-align: left; cursor: pointer; }
.csel-btn:disabled { opacity: .55; cursor: default; }
.csel.open .csel-btn, .csel-btn:focus-visible { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 18%, transparent); }
.csel.placeholder .csel-text { color: var(--text-3); }
.csel-text { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.csel-chev { width: 15px; height: 15px; flex: none; fill: none; stroke: var(--text-2); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; transition: transform .15s; }
.csel.open .csel-chev { transform: rotate(180deg); }
.csel-list { position: fixed; z-index: 1000; max-height: 300px; overflow: auto; padding: 5px; background: var(--list-bg); border: 1px solid var(--hairline); border-radius: 10px; box-shadow: var(--s4); font-size: 13px; color: var(--text-1); font-family: var(--f-ui); }
.csel-opt { padding: 8px 30px 8px 10px; border-radius: 7px; cursor: pointer; position: relative; white-space: nowrap; }
.csel-opt.active { background: var(--control-hi); }
.csel-opt.selected { font-weight: 600; color: var(--primary-text); }
.csel-opt.selected::after { content: ""; position: absolute; right: 11px; top: 50%; width: 5px; height: 9px; margin-top: -6px; border: solid currentColor; border-width: 0 2px 2px 0; transform: rotate(45deg); }
.csel-opt.disabled { color: var(--text-3); cursor: default; }

/* modal (native <dialog>) */
dialog.modal { border: 1px solid var(--hairline); border-radius: 12px; padding: 0; background: var(--surface); color: var(--text-1); box-shadow: var(--s4); width: min(480px, calc(100vw - 32px)); }
/* No background scrolling while any popup is open (app modals and the room screen's overlay). */
html:has(dialog[open]), html:has(body > .confirm) { overflow: hidden; }
dialog.modal { max-height: calc(100dvh - 32px); overflow-y: auto; overscroll-behavior: contain; }
.confirm { overscroll-behavior: contain; }
dialog.modal::backdrop { background: rgba(8, 8, 14, .55); }
dialog.modal .card-b { display: grid; gap: 12px; }
dialog.modal h3 { font-size: 16px; }
dialog.modal .acts { display: flex; gap: 8px; justify-content: flex-end; flex-wrap: wrap; }

/* ── SIGN IN (HRMS scene) ── */
.auth { display: grid; min-height: 100vh; min-height: 100dvh; grid-template-columns: .95fr 1.05fr; }
.auth-brand { position: relative; overflow: hidden; display: flex; align-items: center; justify-content: center; background: var(--brand-bg); border-right: 1px solid var(--hairline); }
.auth-brand .glow { position: absolute; inset: 0; background: var(--mesh); animation: glowDrift 18s ease-in-out infinite; }
.auth-brand .grid { position: absolute; inset: 0; opacity: .034; background-image: linear-gradient(var(--grid-1) 1px, transparent 1px), linear-gradient(90deg, var(--grid-2) 1px, transparent 1px); background-size: 72px 72px; animation: gridPan 34s linear infinite; }
.signal { position: absolute; inset: 0; pointer-events: none; opacity: .34;
  background-image: repeating-linear-gradient(112deg, transparent 0 198px, var(--sp-primary) 199px, transparent 202px), repeating-linear-gradient(68deg, transparent 0 238px, var(--sp-muted) 239px, transparent 242px), linear-gradient(90deg, transparent, var(--sp-sheen), transparent);
  background-size: 640px 640px, 760px 760px, 100% 1px; mix-blend-mode: var(--sp-blend); animation: signalDrift 28s linear infinite, signalBreathe 9s ease-in-out infinite; }
.sweep { position: absolute; left: 0; top: 50%; height: 1px; width: 80%; background: linear-gradient(90deg, transparent, color-mix(in srgb, var(--primary) 24%, transparent), color-mix(in srgb, var(--brand-accent) 22%, transparent), transparent); animation: lineSweep 16s ease-in-out infinite; }
.stage { position: relative; z-index: 2; display: flex; align-items: center; justify-content: center; gap: 24px; padding: 48px; width: 100%; max-width: 560px; animation: brandSettle .7s ease-out both; }
.stage .mark { width: 28%; max-width: 150px; height: auto; flex: none; filter: var(--mark-filter) var(--mark-shadow); transform-origin: 50% 50%; animation: logoSpin 8s linear 2.7s infinite; }
.wordmark { font-size: clamp(38px, 4.6vw, 58px); font-weight: 600; letter-spacing: -.02em; clip-path: inset(0 100% 0 0); animation: wordWrite .85s cubic-bezier(.5, 0, .2, 1) 1.55s forwards; white-space: nowrap; }
.wordmark span { color: var(--primary); }
.brand-sub { position: absolute; bottom: 32px; left: 0; right: 0; text-align: center; font-size: 12.5px; color: var(--text-2); z-index: 2; opacity: 0; animation: fadeUp .6s ease 2.6s forwards; }
.auth-form { position: relative; display: flex; align-items: center; justify-content: center; padding: 40px 24px; background: var(--mesh); overflow: hidden; }
.glass { position: relative; z-index: 2; width: 100%; max-width: 420px; border-radius: 10px; padding: 30px; background: var(--glass-bg); border: 1px solid var(--glass-border); box-shadow: var(--glass-shadow); backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px); }
.glass h1 { font-size: 24px; font-weight: 600; }
.glass .lead { color: var(--text-2); font-size: 13px; margin-top: 4px; }
.glass form { display: grid; gap: 16px; margin-top: 22px; }
.glass .input { height: 44px; border-radius: 8px; border-color: var(--glass-border); padding: 0 14px; font-size: 14px; }
.pwwrap { position: relative; }
.pwwrap .input { padding-right: 64px; }
.pwtoggle { position: absolute; right: 6px; top: 50%; transform: translateY(-50%); height: 30px; padding: 0 10px; border: 0; border-radius: 6px; background: transparent; color: var(--text-2); font-size: 12px; font-weight: 600; cursor: pointer; }
.pwtoggle:hover { background: var(--control-hi); color: var(--text-1); }
.neon-btn { height: 44px; border: 0; border-radius: 8px; color: #fff; font-weight: 700; font-size: 14px; cursor: pointer; background: var(--neon); background-size: 160% 160%; animation: gradMove 9s ease infinite; box-shadow: 0 10px 22px rgba(25,24,46,.12); display: flex; align-items: center; justify-content: center; gap: 8px; width: 100%; }
.neon-btn:disabled { opacity: .7; cursor: default; }
.neon-btn svg { width: 16px; height: 16px; }
.role-hint { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 18px; padding-top: 16px; border-top: 1px solid var(--hairline); }
.role-hint div { font-size: 12px; color: var(--text-2); padding: 10px; border-radius: 8px; background: color-mix(in srgb, var(--surface) 60%, transparent); border: 1px solid var(--hairline); }
.role-hint b { display: block; color: var(--text-1); font-size: 12.5px; margin-bottom: 2px; }
.signin-err { min-height: 0; font-size: 13px; }
.signin-err:empty { display: none; }
@keyframes glowDrift { 0%, 100% { opacity: .55; transform: translate3d(-1%, 0, 0) scale(1); } 50% { opacity: .85; transform: translate3d(1.5%, -1%, 0) scale(1.04); } }
@keyframes gridPan { to { background-position: 72px 72px; } }
@keyframes signalDrift { 0% { background-position: 0 0, 0 0, 0 0; opacity: .30; } 50% { background-position: 44px 24px, -32px 34px, 18px -18px; opacity: .48; } 100% { background-position: 88px 48px, -64px 68px, 36px -36px; opacity: .30; } }
@keyframes signalBreathe { 0%, 100% { transform: translate3d(-1%, 0, 0); } 50% { transform: translate3d(1%, 0, 0); } }
@keyframes lineSweep { 0% { transform: translateX(-35%); opacity: 0; } 18% { opacity: .75; } 55% { opacity: .45; } 100% { transform: translateX(70%); opacity: 0; } }
@keyframes brandSettle { from { opacity: 0; transform: translate3d(0, 10px, 0) scale(.985); } to { opacity: 1; transform: none; } }
@keyframes logoSpin { from { transform: perspective(1100px) rotateY(0); } to { transform: perspective(1100px) rotateY(360deg); } }
@keyframes wordWrite { from { clip-path: inset(0 100% 0 0); } to { clip-path: inset(0 0 0 0); } }
@keyframes gradMove { 0%, 100% { background-position: 0% 50%; } 50% { background-position: 100% 50%; } }
@keyframes fadeUp { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

/* ── ADMIN SHELL ── */
.shell { display: grid; grid-template-columns: 232px minmax(0, 1fr); min-height: 100vh; min-height: 100dvh; }
.side { background: var(--surface); border-right: 1px solid var(--hairline); padding: 14px 10px; display: flex; flex-direction: column; gap: 2px; position: sticky; top: 0; height: 100vh; height: 100dvh; overflow-y: auto; }
.side .brand { display: flex; align-items: center; gap: 9px; padding: 4px 8px 16px; font-weight: 700; font-size: 15px; text-decoration: none; color: var(--text-1); }
.side .brand img { width: 26px; height: 26px; display: block; flex: none; filter: var(--mark-filter); }
.side .brand small { display: block; font-size: 11px; font-weight: 500; color: var(--text-3); }
.side .grp { font-size: 10.5px; font-weight: 600; letter-spacing: .07em; text-transform: uppercase; color: var(--text-3); padding: 14px 10px 6px; }
.side a.nav { display: flex; align-items: center; gap: 10px; height: 34px; padding: 0 10px; border-radius: 7px; text-decoration: none; color: var(--text-2); font-weight: 600; font-size: 13px; flex: none; }
.side a.nav:hover { background: var(--control-hi); color: var(--text-1); }
.side a.nav.on { background: var(--primary-subtle); color: var(--primary-text); }
.side a.nav .n { margin-left: auto; font-family: var(--f-mono); font-size: 11px; font-weight: 500; }
.side svg { width: 16px; height: 16px; flex: none; }
.side .me { margin-top: auto; display: flex; gap: 10px; align-items: center; padding: 10px; border-top: 1px solid var(--hairline); }
.side .me b { font-size: 12.5px; display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.side .me span { font-size: 11.5px; color: var(--text-3); }
.avatar { width: 30px; height: 30px; border-radius: 50%; background: var(--primary); color: var(--on-primary); display: grid; place-items: center; font-size: 11px; font-weight: 700; flex: none; }
.main { min-width: 0; display: flex; flex-direction: column; }
.top { height: 56px; display: flex; align-items: center; gap: 12px; padding: 0 24px; border-bottom: 1px solid var(--hairline); background: var(--surface); position: sticky; top: 0; z-index: 20; }
.top .crumb { font-size: 13px; color: var(--text-2); min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.top .crumb a { color: var(--text-2); text-decoration: none; }
.top .crumb a:hover { color: var(--text-1); text-decoration: underline; }
.top .crumb b { color: var(--text-1); }
.content { padding: 24px; display: grid; gap: 18px; align-content: start; max-width: 1320px; width: 100%; }
.ph { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.ph h1 { font-size: 22px; font-weight: 700; letter-spacing: -.01em; }
.ph p { color: var(--text-2); font-size: 13px; margin-top: 3px; max-width: 72ch; }
.ph .acts { display: flex; gap: 8px; flex-wrap: wrap; }
.utabs { display: flex; gap: 2px; border-bottom: 1px solid var(--hairline); overflow-x: auto; }
.utabs button { border: 0; background: none; padding: 10px 12px; font-weight: 600; font-size: 13px; color: var(--text-2); cursor: pointer; border-bottom: 2px solid transparent; margin-bottom: -1px; white-space: nowrap; display: flex; gap: 6px; align-items: center; }
.utabs button:hover { color: var(--text-1); }
.utabs button[aria-selected="true"] { color: var(--text-1); border-bottom-color: var(--primary); }
.utabs .c { font-family: var(--f-mono); font-size: 11px; color: var(--text-3); }
.g2 { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 18px; align-items: start; }
.g3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.formgrid { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 12px 14px; align-items: end; }
.loading { padding: 40px 24px; color: var(--text-2); }

/* batch steps */
.steps { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); counter-reset: s; }
.step { position: relative; padding: 12px 14px 12px 44px; border-right: 1px solid var(--hairline); min-width: 0; }
.step:last-child { border-right: 0; }
.step::before { counter-increment: s; content: counter(s); position: absolute; left: 14px; top: 13px; width: 20px; height: 20px; border-radius: 50%; display: grid; place-items: center; font-size: 11px; font-weight: 700; background: var(--control-hi); color: var(--text-2); }
.step.done::before { content: "✓"; background: var(--ok-bg); color: var(--ok-t); }
.step.now::before { background: var(--primary); color: var(--on-primary); }
.step.bad::before { content: "!"; background: var(--bad-bg); color: var(--bad-t); }
.step b { display: block; font-size: 13px; }
.step span { font-size: 12px; color: var(--text-2); display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* question set editor */
.sec-row { display: grid; grid-template-columns: minmax(150px, 1.4fr) 92px repeat(3, 74px) 96px 64px 76px; gap: 10px; align-items: center; padding: 10px 16px; border-bottom: 1px solid var(--hairline); min-width: 780px; }
.sec-row.h { font-size: 10.5px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--text-3); background: var(--control); padding-block: 8px; }
.sec-row .nm { min-width: 0; display: grid; gap: 2px; }
.sec-row .nm input { height: 30px; font-weight: 700; font-size: 13.5px; border-color: transparent; background: transparent; padding: 0 6px; margin-left: -6px; }
.sec-row .nm input:hover { border-color: var(--hairline); }
.sec-row .nm span { font-size: 11.5px; color: var(--text-3); }
.sec-row .acts { display: flex; gap: 2px; justify-content: flex-end; }
.sec-extra { padding: 10px 16px 14px; border-bottom: 1px solid var(--hairline); background: var(--zebra); display: grid; gap: 8px; min-width: 780px; }
.pool { font-family: var(--f-mono); font-size: 12px; color: var(--text-2); }
.diff { display: grid; gap: 3px; justify-items: center; }
.diff small { font-family: var(--f-mono); font-size: 10.5px; color: var(--text-3); }
.diff small.short { color: var(--bad-t); font-weight: 600; }
.diff .input.short { border-color: var(--bad-dot); }
.sumline { display: flex; gap: 18px; flex-wrap: wrap; padding: 14px 16px; align-items: center; background: var(--control); border-top: 1px solid var(--hairline); border-radius: 0 0 var(--r-l) var(--r-l); }
.sumline > div { font-size: 12.5px; color: var(--text-2); }
.sumline b { font-family: var(--f-mono); font-size: 15px; color: var(--text-1); font-weight: 500; margin-right: 4px; }
.sumline .tag { margin-left: auto; }
.draw { margin: 0; padding-left: 20px; display: grid; gap: 7px; font-size: 13px; }
.draw li span { color: var(--text-3); }
.qlist { display: grid; }
.qitem { display: grid; grid-template-columns: 34px minmax(0, 1fr) auto; gap: 10px; padding: 10px 16px; border-bottom: 1px solid var(--hairline); align-items: start; }
.qitem:last-child { border-bottom: 0; }
.qitem .qn { font-family: var(--f-mono); font-size: 12px; color: var(--text-3); padding-top: 2px; }
.qitem .qt { font-size: 13.5px; }
.qitem .qm { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 5px; align-items: center; }
.qitem .qa { display: flex; gap: 4px; }
.qedit { grid-column: 1 / -1; display: grid; gap: 10px; padding: 12px; border: 1px solid var(--hairline); border-radius: 10px; background: var(--control); }

/* live grid */
.livegrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(122px, 1fr)); gap: 8px; }
.lt { border: 1px solid var(--hairline); border-radius: 9px; padding: 8px 9px; background: var(--surface); display: grid; gap: 5px; min-width: 0; text-decoration: none; color: inherit; }
.lt:hover { border-color: var(--border-strong); }
.lt b { font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-weight: 600; }
.lt .st { font-size: 11px; display: flex; align-items: center; gap: 5px; color: var(--text-2); white-space: nowrap; overflow: hidden; }
.lt .mini { height: 4px; border-radius: 999px; background: var(--control-hi); overflow: hidden; }
.lt .mini i { display: block; height: 100%; }
.lt.flag { border-color: color-mix(in srgb, var(--bad-dot) 55%, transparent); background: color-mix(in srgb, var(--bad-bg) 60%, var(--surface)); }
.legend { display: flex; gap: 14px; flex-wrap: wrap; font-size: 12px; color: var(--text-2); }
.legend span { display: flex; gap: 6px; align-items: center; }

/* interviewer options */
.opt { padding: 16px; display: grid; gap: 10px; align-content: start; position: relative; }
.opt.rec { border-color: color-mix(in srgb, var(--primary) 55%, transparent); box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 12%, transparent); }
.opt h4 { font-size: 14.5px; }
.opt ul { margin: 0; padding-left: 18px; font-size: 12.5px; color: var(--text-2); display: grid; gap: 4px; }
.vprev { aspect-ratio: 16/10; border-radius: 10px; background: var(--call-tile); position: relative; overflow: hidden; display: grid; place-items: center; color: var(--call-text-2); font-size: 12px; text-align: center; }
.vprev video { width: 100%; height: 100%; object-fit: cover; }

/* review */
.player { width: 100%; aspect-ratio: 16/9; background: #000; border-radius: 12px 12px 0 0; display: block; }
.timeline { position: relative; height: 22px; border-radius: 6px; background: var(--control-hi); cursor: pointer; overflow: hidden; }
.timeline .ans { position: absolute; top: 0; bottom: 0; background: color-mix(in srgb, var(--primary) 45%, transparent); }
.timeline .flag { position: absolute; top: 0; bottom: 0; background: var(--warn-dot); min-width: 2px; }
.timeline .head { position: absolute; top: 0; bottom: 0; width: 2px; background: var(--text-1); }
.flaglist { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; font-size: 12.5px; }
.flaglist li { display: flex; gap: 10px; align-items: baseline; }
.flaglist button { border: 0; background: var(--control-hi); border-radius: 6px; padding: 2px 7px; font-family: var(--f-mono); font-size: 11.5px; cursor: pointer; }
.answer { padding: 14px 16px; border-bottom: 1px solid var(--hairline); display: grid; gap: 9px; }
.answer:last-child { border-bottom: 0; }
.answer .meta { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; font-size: 12px; color: var(--text-3); }
.answer .q { font-weight: 600; font-size: 13.5px; }
.answer .tx { font-size: 13.5px; line-height: 1.6; white-space: pre-wrap; }
.answer details summary { cursor: pointer; font-size: 12.5px; color: var(--text-2); }
.answer details ul { margin: 6px 0; padding-left: 18px; font-size: 12.5px; color: var(--text-2); }

/* ── CANDIDATE HOME ── */
.cand-top { display: flex; align-items: center; gap: 12px; padding: 12px max(16px, env(safe-area-inset-right, 0px)) 12px max(16px, env(safe-area-inset-left, 0px)); background: var(--surface); border-bottom: 1px solid var(--hairline); }
.logo-t { font-weight: 700; font-size: 15px; letter-spacing: -.01em; }
.logo-t span { color: var(--primary); }
.cand { max-width: 980px; margin: 0 auto; padding: 28px max(16px, env(safe-area-inset-right, 0px)) 40px max(16px, env(safe-area-inset-left, 0px)); display: grid; gap: 18px; }
.checks { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 10px; }
.check { display: flex; gap: 10px; align-items: center; padding: 12px; border-radius: 10px; border: 1px solid var(--hairline); background: var(--surface); font-size: 13px; font-weight: 600; min-width: 0; }
.check i { width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; font-style: normal; font-size: 12px; background: var(--control-hi); color: var(--text-2); flex: none; }
.check.ok i { background: var(--ok-bg); color: var(--ok-t); }
.check.w i { background: var(--warn-bg); color: var(--warn-t); }
.check.bad i { background: var(--bad-bg); color: var(--bad-t); }
.check small { display: block; font-weight: 500; color: var(--text-3); font-size: 11.5px; }
.ivcard .card-h h2 { font-size: 16px; font-weight: 700; }
.qa { border-top: 1px solid var(--hairline); padding: 12px 16px; display: grid; gap: 4px; }
.qa .q { font-weight: 600; }
.qa .a { color: var(--text-2); white-space: pre-wrap; }
.seb-guide { display: grid; gap: 12px; padding: 14px; border-radius: 10px; background: var(--control); border: 1px solid var(--hairline); }
.seb-step { display: grid; grid-template-columns: 26px minmax(0, 1fr); gap: 10px; }
.seb-n { width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; background: var(--primary-subtle); color: var(--primary-text); font-weight: 700; font-size: 12px; }

/* ── ROOM SCREEN ── */
.room { max-width: 1100px; margin: 0 auto; padding: 32px max(16px, env(safe-area-inset-right, 0px)) 60px max(16px, env(safe-area-inset-left, 0px)); display: grid; gap: 20px; }
.room header { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.room h1 { font-size: 28px; font-weight: 700; letter-spacing: -.01em; }
.room .sub { color: var(--text-2); font-size: 15px; margin-top: 4px; }
.room .search { height: 56px; font-size: 19px; padding: 0 18px; border-radius: 12px; border: 1px solid var(--border-strong); background: var(--field); width: 100%; }
.room .search:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px color-mix(in srgb, var(--primary) 18%, transparent); }
.names { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 12px; }
.name { text-align: left; font-size: 17px; padding: 16px 18px; border-radius: 12px; background: var(--surface); color: var(--text-1); border: 1px solid var(--hairline); font-weight: 600; display: grid; gap: 4px; cursor: pointer; box-shadow: var(--s1); }
.name:hover:not(:disabled) { border-color: var(--primary); background: color-mix(in srgb, var(--primary-subtle) 50%, var(--surface)); }
.name small { font-size: 13px; font-weight: 500; color: var(--text-2); }
.name:disabled { opacity: .5; cursor: default; }
.count { font-family: var(--f-mono); font-size: 13px; color: var(--text-2); margin-left: auto; }
.confirm { position: fixed; inset: 0; background: rgba(8, 8, 14, .6); display: grid; place-items: center; z-index: 50; padding: 16px; }
.confirm .box { background: var(--surface); border: 1px solid var(--hairline); border-radius: 14px; padding: 28px; width: min(480px, 100%); display: grid; gap: 14px; text-align: center; box-shadow: var(--s4); }
.confirm .box h2 { font-size: 26px; }
.confirm .acts { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }
.confirm .btn { height: 44px; font-size: 15px; padding: 0 20px; }

/* ── CALL (candidate) ── */
.call { --surface: #18181C; --hairline: #2F2F35; --text-1: #ECECF0; --text-2: #A0A0AC; --text-3: #8A8A96; --control-hi: #2A2A31; --field: #222228; --border-strong: #676467; --primary: #C552BC; --primary-text: #E27BDA;
  background: var(--call-bg); color: var(--call-text); min-height: 100vh; min-height: 100dvh; color-scheme: dark; }
.call.screen { display: grid; grid-template-rows: auto minmax(0, 1fr) auto; height: 100vh; height: 100dvh; }
.call-top { display: flex; align-items: center; gap: 14px; padding: 14px max(16px, env(safe-area-inset-right, 0px)) 14px max(16px, env(safe-area-inset-left, 0px)); flex-wrap: wrap; }
.call-top .logo-t span, .call .logo-t span { color: #EE00EE; }
.call-top .title { color: var(--call-text-2); font-size: 13px; max-width: 32ch; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.secprog { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.secprog .sg { display: flex; gap: 3px; align-items: center; font-size: 11.5px; color: var(--call-text-2); }
.secprog .sg em { font-style: normal; margin-right: 3px; }
.secprog .sg i { width: 18px; height: 5px; border-radius: 3px; background: #2E2E36; }
.secprog .sg i.d { background: #8A6A88; }
.secprog .sg i.c { background: #EE00EE; }
.recb { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; color: #FCA5A5; background: rgba(239,68,68,.12); padding: 4px 10px; border-radius: 999px; }
.recb .dot { animation: blink 1.4s ease-in-out infinite; }
@keyframes blink { 50% { opacity: .25; } }
.call-stage { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 14px; padding: 0 max(16px, env(safe-area-inset-right, 0px)) 0 max(16px, env(safe-area-inset-left, 0px)); min-height: 0; }
.itile { position: relative; border-radius: 16px; background: var(--call-tile); overflow: hidden; min-height: 300px; display: grid; place-items: center; transition: box-shadow .2s; }
.itile.speaking { box-shadow: 0 0 0 2px rgba(238,0,238,.55); }
.itile video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; background: var(--call-tile); }
.itile video.talk { opacity: 0; transition: opacity .25s; }
.itile video.talk.on { opacity: 1; }
.speaking-bar { position: absolute; inset: auto 16px 16px 16px; display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap; z-index: 2; }
.nameplate { background: rgba(0,0,0,.55); backdrop-filter: blur(6px); padding: 6px 12px; border-radius: 8px; font-size: 12.5px; font-weight: 600; display: inline-flex; gap: 8px; align-items: center; }
.nameplate small { font-weight: 400; color: var(--call-text-2); }
.caption { position: absolute; left: 50%; transform: translateX(-50%); bottom: 64px; max-width: min(680px, 90%); width: max-content; background: rgba(0,0,0,.62); padding: 8px 14px; border-radius: 8px; font-size: 14px; text-align: center; z-index: 2; }
.ipane { display: grid; gap: 14px; align-content: start; min-height: 0; overflow-y: auto; }
.selfv { aspect-ratio: 4/3; border-radius: 14px; background: linear-gradient(160deg, #23232B, #15151A); position: relative; overflow: hidden; }
.selfv video { width: 100%; height: 100%; object-fit: cover; transform: scaleX(-1); display: block; }
.selfv .nameplate { position: absolute; left: 10px; bottom: 10px; }
.selfv.speaking { box-shadow: 0 0 0 2px rgba(238,0,238,.55); }
.level { display: inline-flex; gap: 2px; align-items: center; height: 14px; }
.level b { width: 3px; height: 4px; border-radius: 2px; background: #EE00EE; transition: height .08s; }
.qcard { border-radius: 14px; background: #17171D; border: 1px solid #2A2A31; padding: 16px; display: grid; gap: 10px; }
.qcard .qs { font-size: 11px; letter-spacing: .06em; text-transform: uppercase; color: var(--call-text-2); display: flex; justify-content: space-between; gap: 8px; }
.qcard p.qtext { font-size: 15.5px; line-height: 1.5; font-weight: 500; }
.qcard .qhint { font-size: 12.5px; color: var(--call-text-2); border-top: 1px solid #2A2A31; padding-top: 10px; }
.timer { display: flex; align-items: center; gap: 12px; }
.ring { width: 54px; height: 54px; flex: none; }
.ring circle { fill: none; stroke-width: 5; }
.ring .track { stroke: #2A2A31; }
.ring .left { stroke: #EE00EE; stroke-linecap: round; transition: stroke-dashoffset .25s linear; }
.ring.read .left { stroke: #84AEF9; }
.ring.low .left { stroke: #F87171; }
.timer .t { font-family: var(--f-mono); font-size: 22px; }
.timer .t.low { color: #F87171; }
.timer small { display: block; color: var(--call-text-2); font-size: 11.5px; }
.callbar { display: flex; justify-content: center; gap: 10px; padding: 14px 16px 18px; flex-wrap: wrap; }
.cbtn { height: 42px; padding: 0 18px; border-radius: 999px; border: 1px solid #2E2E36; background: #1F1F26; color: var(--call-text); font-weight: 600; font-size: 13px; cursor: pointer; display: inline-flex; align-items: center; gap: 8px; text-decoration: none; }
.cbtn:hover:not(:disabled) { background: #2A2A33; }
.cbtn:disabled { opacity: .45; cursor: default; }
.cbtn.pri { background: #B800B8; border-color: #B800B8; color: #fff; }
.cbtn.pri:hover:not(:disabled) { background: #A000A0; }
.cbtn.end { background: #3A1414; border-color: #5A1F1F; color: #FCA5A5; }
.cbtn svg { width: 16px; height: 16px; }
.phase-line { text-align: center; font-size: 12.5px; color: var(--call-text-2); padding-top: 10px; min-height: 28px; }
.persona { display: grid; justify-items: center; gap: 14px; text-align: center; position: relative; z-index: 1; }
.persona .ph0 { width: 132px; height: 132px; border-radius: 50%; position: relative; display: grid; place-items: center; font-size: 40px; font-weight: 700; color: #fff; background: radial-gradient(circle at 35% 30%, #7d6a8a, #3c2f48); }
.itile.speaking .persona .ph0::before, .itile.speaking .persona .ph0::after { content: ""; position: absolute; inset: -8px; border-radius: 50%; border: 2px solid rgba(238,0,238,.55); animation: talk 1.6s ease-out infinite; }
.itile.speaking .persona .ph0::after { animation-delay: .8s; }
@keyframes talk { from { transform: scale(1); opacity: .9; } to { transform: scale(1.28); opacity: 0; } }
/* pre-join + messages */
.center-page { min-height: 100vh; min-height: 100dvh; display: grid; place-items: center; padding: 24px 16px; }
.msg { width: min(560px, 100%); display: grid; gap: 12px; background: #17171D; border: 1px solid #2A2A31; border-radius: 16px; padding: 28px; }
.msg h1 { font-size: 22px; font-weight: 700; }
.msg p { color: var(--call-text-2); }
.msg .row .btn, .msg a.btn { background: #1F1F26; border-color: #2E2E36; color: var(--call-text); }
.msg a.btn.primary { background: #B800B8; border-color: #B800B8; color: #fff; }
.prejoin { max-width: 1120px; margin: 0 auto; padding: 18px max(16px, env(safe-area-inset-right, 0px)) 32px max(16px, env(safe-area-inset-left, 0px)); display: grid; gap: 18px; }
.prejoin .pj-top { display: flex; align-items: center; gap: 12px; }
.prejoin .cols { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 22px; align-items: start; }
.prejoin .preview { aspect-ratio: 4/3; border-radius: 16px; background: linear-gradient(160deg, #23232B, #15151A); position: relative; overflow: hidden; display: grid; place-items: center; }
.prejoin .preview video { width: 100%; height: 100%; object-fit: cover; transform: scaleX(-1); position: absolute; inset: 0; }
.prejoin .preview .hint { position: relative; color: var(--call-text-2); padding: 20px; text-align: center; max-width: 36ch; }
.prejoin .preview .nameplate { position: absolute; left: 12px; bottom: 12px; }
.prejoin .join { display: grid; gap: 14px; }
.prejoin h1 { font-size: 26px; font-weight: 700; letter-spacing: -.01em; }
.prejoin .lead { color: var(--call-text-2); }
.prejoin ol { margin: 0; padding-left: 20px; display: grid; gap: 8px; font-size: 13.5px; color: #D4D4DC; }
.prejoin ul { margin: 0; padding-left: 20px; display: grid; gap: 6px; font-size: 12.5px; color: var(--call-text-2); }
.prejoin .secs { width: 100%; border-collapse: collapse; font-size: 13px; }
.prejoin .secs td, .prejoin .secs th { padding: 7px 10px; border-bottom: 1px solid #2A2A31; text-align: left; }
.prejoin .secs th { font-size: 11px; letter-spacing: .05em; text-transform: uppercase; color: var(--call-text-2); font-weight: 600; }
.consent { display: flex; gap: 10px; align-items: flex-start; font-size: 13px; color: #D4D4DC; padding: 12px; border-radius: 10px; border: 1px solid #2A2A31; background: #17171D; cursor: pointer; }
.consent input { width: 18px; height: 18px; margin: 1px 0 0; accent-color: #B800B8; flex: none; }
.join .btn.go { height: 44px; background: #B800B8; border-color: #B800B8; color: #fff; font-size: 14px; }
.join .btn.go:disabled { opacity: .45; }
.results { width: min(820px, 100%); }
.results .qa { border-color: #2A2A31; }

/* ── responsive ── */
@media (max-width: 1080px) {
  .g2 { grid-template-columns: minmax(0, 1fr); }
  .call-stage { grid-template-columns: minmax(0, 1fr); overflow-y: auto; }
  .call.screen { height: auto; min-height: 100dvh; }
  .itile { min-height: 260px; aspect-ratio: 16/10; }
  .selfv { max-width: 320px; }
  .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .step { border-bottom: 1px solid var(--hairline); }
  .prejoin .cols { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 860px) {
  .auth { grid-template-columns: minmax(0, 1fr); }
  .auth-brand { min-height: 260px; border-right: 0; border-bottom: 1px solid var(--hairline); }
  .shell { grid-template-columns: minmax(0, 1fr); }
  .side { flex-direction: row; overflow-x: auto; padding: 8px; border-right: 0; border-bottom: 1px solid var(--hairline); height: auto; position: static; }
  .side .brand, .side .grp, .side .me { display: none; }
  .content { padding: 16px; }
  .top { padding: 0 16px; }
  .g3 { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 520px) {
  .steps { grid-template-columns: minmax(0, 1fr); }
  .role-hint { grid-template-columns: minmax(0, 1fr); }
  .glass { padding: 22px; }
  .stage { gap: 14px; padding: 24px; }
  .ph h1 { font-size: 20px; }
  .kpi .v { font-size: 22px; }
  .call-top .title { display: none; }
  .cbtn { padding: 0 14px; }
}
@media (prefers-reduced-motion: reduce) {
  .auth-brand .glow, .auth-brand .grid, .signal, .sweep, .stage, .stage .mark, .neon-btn, .persona .ph0::before, .persona .ph0::after, .recb .dot, .spinner { animation: none !important; }
  .wordmark { clip-path: none; animation: none; }
  .brand-sub { opacity: 1; animation: none; }
  .sw::after, .ring .left, .itile video.talk { transition: none; }
}

/* call: interviewer status chip and connection bars */
.livechip { position: absolute; top: 14px; left: 14px; z-index: 2; display: flex; gap: 7px; align-items: center; font-size: 12px; font-weight: 600; background: rgba(0,0,0,.5); padding: 5px 11px; border-radius: 999px; color: #E9D5FF; }
.livechip .dot { color: #4ADE80; animation: blink 2s ease-in-out infinite; }
.sig { display: flex; gap: 2px; align-items: flex-end; height: 14px; }
.sig i { width: 3px; background: #4ADE80; border-radius: 1px; transition: opacity .3s; }
.sig i:nth-child(1) { height: 4px; } .sig i:nth-child(2) { height: 7px; } .sig i:nth-child(3) { height: 10px; } .sig i:nth-child(4) { height: 14px; }
.call .grow { flex: 1; }
.call dialog.modal { background: #18181C; color: #ECECF0; border-color: #2F2F35; }
.call dialog.modal .muted { color: #A0A0AC; }
.call dialog.modal .btn { background: #1F1F26; border-color: #2E2E36; color: #ECECF0; }
.call dialog.modal .btn.dest { background: #3A1414; border-color: #5A1F1F; color: #FCA5A5; }
@media (prefers-reduced-motion: reduce) { .livechip .dot { animation: none; } }
.side .me .avatar { color: var(--on-primary); font-size: 11px; }
.card-h > .row { flex: 1; }
/* grid children default to min-width:auto, which lets a wide table inside a card push the page wider */
.content, .stack, .cand, .room, .prejoin { grid-template-columns: minmax(0, 1fr); }
