/* Linguino — colours from the logo: sky blue, deep blue, penguin orange. Every colour is a token. */

:root {
  --bg: #0b1a2e;
  --bg-2: #10243f;
  --bg-rgb: 11 26 46;
  --fg: 255 255 255;
  --panel: rgba(255, 255, 255, 0.04);
  --panel-solid: #112a48;
  --panel-hi: rgba(255, 255, 255, 0.07);
  --panel-glass: rgba(16, 36, 63, 0.94);
  --ink: #eef5fc;
  --ink-2: #c2d5e9;
  --muted: #89a3bf;
  --line: rgba(255, 255, 255, 0.08);
  --line-hi: rgba(255, 255, 255, 0.16);
  --paper: #f5f7fa;
  --paper-ink: #0f172a;
  --well: rgba(0, 0, 0, 0.22);
  --well-soft: rgba(255, 255, 255, 0.03);
  --placeholder: #5f7c9c;
  --es-ink: #fcd34d;
  --zh-ink: #fca5a5;
  --it-ink: #c4b5fd;
  --en-ink: #93b4ff;
  --ru-ink: #6ee7b7;
  --ai-ink: #67e8f9;
  --violet-ink: #9cc8f2;
  --silver: #cbd5e1;
  --aura: 0.6;
  --brand: #ef6c12;
  --brand-rgb: 239 108 18;
  --brand-2: #3e83c4;
  --violet-rgb: 62 131 196;
  --brand-3: #f99a5a;
  --grad: linear-gradient(120deg, #ef6c12 0%, #f99a5a 100%);
  --grad-cool: linear-gradient(135deg, #3e83c4 0%, #275587 100%);
  --navy: #275587;
  --navy-ink: #f8fafc;
  --ok: #10b981;
  --bad: #f43f5e;
  --warn: #f59e0b;
  --es: #f59e0b;
  --zh: #ef4444;
  --it: #8b5cf6;
  --en: #3b82f6;
  --ru: #10b981;
  --side-a: #3e83c4;
  --side-b: #ef6c12;
  --radius: 18px;
  --radius-sm: 12px;
  --shadow: 0 1px 0 rgba(255, 255, 255, 0.04) inset, 0 18px 40px -22px rgba(0, 0, 0, 0.7);
  --glow: 0 0 0 1px rgb(var(--brand-rgb) / 0.5), 0 10px 36px -8px rgb(var(--brand-rgb) / 0.5);
  --font: 'Plus Jakarta Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --display: 'Nunito', 'Plus Jakarta Sans', system-ui, sans-serif;
  font-family: var(--font);
  color: var(--ink);
  color-scheme: dark;
  --hero-a: #1b4677;
  --hero-b: #0f2d52;
}

/* Day theme: chosen explicitly, or followed from the OS when nothing is chosen. */
:root[data-theme="light"] {
  --bg: #f2f7fc;
  --bg-2: #e6f0fa;
  --bg-rgb: 242 247 252;
  --fg: 22 48 77;
  --panel: #ffffff;
  --panel-solid: #ffffff;
  --panel-hi: rgba(22, 48, 77, 0.045);
  --panel-glass: rgba(255, 255, 255, 0.96);
  --ink: #15304d;
  --ink-2: #42607f;
  --muted: #6a829d;
  --line: rgba(22, 48, 77, 0.09);
  --line-hi: rgba(22, 48, 77, 0.16);
  --well: #ffffff;
  --well-soft: rgba(22, 48, 77, 0.03);
  --placeholder: #90a4ba;
  --es-ink: #b45309;
  --zh-ink: #b91c1c;
  --it-ink: #6d28d9;
  --en-ink: #1d4ed8;
  --ru-ink: #047857;
  --ai-ink: #0e7490;
  --violet-ink: #2b67a6;
  --silver: #94a3b8;
  --aura: 0.35;
  --shadow: 0 1px 2px rgba(15, 23, 42, 0.04), 0 12px 32px -16px rgba(15, 23, 42, 0.16);
  color-scheme: light;
    --hero-a: #4a90d0;
    --hero-b: #336fb0;
}
@media (prefers-color-scheme: light) {
  :root:not([data-theme="dark"]) {
    --bg: #f2f7fc;
    --bg-2: #e6f0fa;
    --bg-rgb: 242 247 252;
    --fg: 22 48 77;
    --panel: #ffffff;
    --panel-solid: #ffffff;
    --panel-hi: rgba(22, 48, 77, 0.045);
    --panel-glass: rgba(255, 255, 255, 0.96);
    --ink: #15304d;
    --ink-2: #42607f;
    --muted: #6a829d;
    --line: rgba(22, 48, 77, 0.09);
    --line-hi: rgba(22, 48, 77, 0.16);
    --well: #ffffff;
    --well-soft: rgba(22, 48, 77, 0.03);
    --placeholder: #90a4ba;
    --es-ink: #b45309;
  --zh-ink: #b91c1c;
  --it-ink: #6d28d9;
    --en-ink: #1d4ed8;
    --ru-ink: #047857;
    --ai-ink: #0e7490;
    --violet-ink: #2b67a6;
    --silver: #94a3b8;
    --aura: 0.35;
    --shadow: 0 1px 2px rgba(15, 23, 42, 0.04), 0 12px 32px -16px rgba(15, 23, 42, 0.16);
    color-scheme: light;
      --hero-a: #4a90d0;
    --hero-b: #336fb0;
}
}

* { box-sizing: border-box; }
html { background: var(--bg); }
body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(900px 520px at 100% -10%, rgb(var(--brand-rgb) / calc(0.10 * var(--aura))), transparent 60%),
    radial-gradient(800px 500px at -10% 0%, rgb(var(--violet-rgb) / calc(0.12 * var(--aura))), transparent 60%),
    var(--bg);
  transition: background-color 0.3s, color 0.3s;
  background-attachment: fixed;
  -webkit-font-smoothing: antialiased;
  display: flex;
  flex-direction: column;
}
#app { flex: 1; }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3, h4 { margin: 0; line-height: 1.12; font-family: var(--display); font-weight: 800; letter-spacing: -0.03em; }
::selection { background: rgb(var(--violet-rgb) / 0.45); }
.hidden { display: none !important; }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-thumb { background: rgb(var(--fg) / 0.14); border-radius: 99px; border: 2px solid transparent; background-clip: padding-box; }
::-webkit-scrollbar-track { background: transparent; }

/* ---------- primitives ---------- */

.btn {
  border: 0;
  border-radius: var(--radius-sm);
  padding: 10px 16px;
  font-weight: 700;
  cursor: pointer;
  background: var(--panel-hi);
  color: var(--ink);
  box-shadow: inset 0 0 0 1px var(--line-hi);
  transition: transform 0.12s ease, filter 0.15s, box-shadow 0.2s, background 0.2s;
  white-space: nowrap;
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
}
.btn:hover { filter: brightness(1.12); transform: translateY(-1px); }
.btn:active { transform: translateY(1px) scale(0.98); }
.btn:focus-visible { outline: 2px solid var(--brand-2); outline-offset: 2px; }
.btn:disabled { opacity: 0.4; cursor: not-allowed; transform: none; filter: none; }
.btn.brand { background: var(--brand); color: #fff; box-shadow: 0 10px 24px -10px rgb(var(--brand-rgb) / 0.7); }
.btn.brand:hover { filter: none; background: #d95c08; }
.btn.violet { background: var(--brand-2); color: #fff; box-shadow: 0 8px 24px -10px rgb(var(--violet-rgb) / 0.8); }
.btn.ok { background: var(--ok); color: #fff; box-shadow: 0 8px 22px -10px rgb(16 185 129 / 0.7); }
.btn.bad { background: var(--bad); color: #fff; box-shadow: 0 8px 22px -10px rgba(255, 84, 104, 0.7); }
.btn.ghost { background: transparent; color: var(--ink-2); box-shadow: inset 0 0 0 1px var(--line-hi); }
.btn.ghost:hover { background: var(--panel-hi); color: var(--ink); }
.btn.small { padding: 7px 11px; font-size: 13px; border-radius: 10px; }
.btn.big { padding: 14px 22px; font-size: 17px; border-radius: 14px; }
.btn.icon { padding: 7px; width: 34px; height: 34px; }

.input, select.input, textarea.input {
  width: 100%;
  border: 1px solid var(--line-hi);
  border-radius: var(--radius-sm);
  padding: 11px 13px;
  background: var(--well);
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.input::placeholder { color: var(--placeholder); }
.input:focus { border-color: var(--brand-2); box-shadow: 0 0 0 4px rgb(var(--violet-rgb) / 0.18); }
select.input option { background: var(--panel-solid); }
textarea.input { resize: vertical; min-height: 64px; }
.field, label.field { display: grid; gap: 7px; font-weight: 600; font-size: 13px; color: var(--ink-2); }

.card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 18px;
}
.card h3 { font-size: 15px; font-weight: 700; }
.muted { color: var(--muted); }
.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.stack { display: grid; gap: 14px; }
.center { text-align: center; }
.pill {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 4px 11px; border-radius: 999px; font-size: 12.5px; font-weight: 700;
  background: var(--panel-hi); border: 1px solid var(--line);
}
.pill.glass { background: rgba(255, 255, 255, 0.18); border-color: rgba(255, 255, 255, 0.25); color: #fff; }
.pill.es { background: rgb(245 158 11 / 0.14); color: var(--es-ink); border-color: rgb(245 158 11 / 0.3); }
.pill.zh { background: rgb(239 68 68 / 0.12); color: var(--zh-ink); border-color: rgb(239 68 68 / 0.3); }
.pill.it { background: rgb(139 92 246 / 0.12); color: var(--it-ink); border-color: rgb(139 92 246 / 0.3); }
.pill.en { background: rgba(59, 130, 246, 0.14); color: var(--en-ink); border-color: rgba(59, 130, 246, 0.3); }
.pill.ru { background: rgb(16 185 129 / 0.14); color: var(--ru-ink); border-color: rgb(16 185 129 / 0.3); }
.pill.ai { background: rgba(52, 212, 200, 0.12); color: var(--ai-ink); border-color: rgba(52, 212, 200, 0.3); }
.timer { font-variant-numeric: tabular-nums; font-weight: 800; }
.timer.low { color: var(--bad); }
.big-emoji { font-size: 56px; line-height: 1; }
.kbd { font-family: ui-monospace, monospace; background: var(--panel-hi); padding: 2px 8px; border-radius: 8px; }
.grad-text { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }

/* ---------- brand ---------- */

.logo {
  font-family: var(--display); font-size: 46px; font-weight: 800; letter-spacing: -0.045em;
  display: inline-flex; align-items: center; gap: 10px;
}
.logo span:not(.logo-mark) { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.logo-mark {
  width: 1.1em; height: 1.1em; border-radius: 30%; background: var(--grad);
  display: inline-grid; place-items: center; font-size: 0.6em; color: #fff;
  box-shadow: 0 10px 30px -8px rgb(var(--brand-rgb) / 0.7);
}

.credit {
  text-align: center; padding: 22px 16px 26px; font-size: 13px; color: var(--muted);
  letter-spacing: 0.02em;
}
.credit b {
  font-family: var(--display); font-weight: 700; letter-spacing: 0.01em;
  background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent;
}
.credit .heart { color: var(--brand); }

/* ---------- home ---------- */

.home { max-width: 540px; margin: 0 auto; padding: 56px 16px 24px; }
.home-hero { display: grid; gap: 12px; justify-items: center; text-align: center; }
.home-hero .eyebrow {
  font-size: 12px; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase;
  padding: 6px 12px; border-radius: 999px; background: rgb(var(--violet-rgb) / 0.12);
  color: var(--violet-ink); border: 1px solid rgb(var(--violet-rgb) / 0.3);
}
.tagline { font-size: 17px; margin-top: 2px; color: var(--ink-2); }
.home-features { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; }
.home .card { padding: 22px; }
.lang-pair { display: grid; grid-template-columns: 1fr auto 1fr; gap: 10px; align-items: end; }
.lang-pair .arrow {
  padding-bottom: 10px; font-size: 18px; width: 34px; height: 34px; margin-bottom: 4px;
  display: grid; place-items: center; border-radius: 50%; background: var(--panel-hi); padding: 0;
}
.join-row { display: grid; grid-template-columns: 1fr auto; gap: 8px; }
.code-input { text-transform: uppercase; letter-spacing: 8px; font-weight: 800; text-align: center; font-family: var(--display); }
.divider { display: flex; align-items: center; gap: 12px; color: var(--muted); font-size: 13px; }
.divider::before, .divider::after { content: ''; flex: 1; height: 1px; background: var(--line); }

/* ---------- room shell ---------- */

.topbar {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  padding: 10px 20px;
  background: rgb(var(--bg-rgb) / 0.72);
  backdrop-filter: blur(18px) saturate(1.4);
  -webkit-backdrop-filter: blur(18px) saturate(1.4);
  border-bottom: 1px solid var(--line);
  position: sticky; top: 0; z-index: 20;
}
.topbar .logo { font-size: 22px; margin-right: auto; gap: 8px; }
.topbar .logo-mark { width: 1.35em; height: 1.35em; font-size: 0.75em; border-radius: 10px; }
.room-code { cursor: pointer; font-family: var(--display); letter-spacing: 0.08em; }
.room-code:hover { border-color: var(--brand-2); }
.layout {
  display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 18px;
  padding: 18px 20px; max-width: 1360px; margin: 0 auto;
}
@media (max-width: 900px) {
  .layout { grid-template-columns: minmax(0, 1fr); padding: 14px 16px; }
  .topbar { padding: 10px 16px; }
}
.stage { display: grid; gap: 18px; align-content: start; min-width: 0; }
.sidebar { display: grid; gap: 16px; align-content: start; min-width: 0; }

.mode-bar { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; padding: 14px 18px; }
.mode-bar h2 { font-size: 22px; }
.mode-bar .spacer { flex: 1; }
.mode-bar .big-emoji {
  width: 46px; height: 46px; display: grid; place-items: center; border-radius: 14px;
  background: var(--panel-hi); border: 1px solid var(--line);
}

.players { display: grid; gap: 4px; }
.player {
  display: grid; grid-template-columns: auto 1fr auto; gap: 10px; align-items: center;
  padding: 7px 9px; border-radius: 14px; transition: background 0.2s;
}
.player.me { background: rgb(var(--violet-rgb) / 0.12); box-shadow: inset 0 0 0 1px rgb(var(--violet-rgb) / 0.25); }
.player.off { opacity: 0.4; }
.player .avatar {
  width: 36px; height: 36px; border-radius: 12px; display: grid; place-items: center;
  font-weight: 800; color: #fff; box-shadow: inset 0 -8px 16px rgba(0, 0, 0, 0.2);
}
.player .name { font-weight: 700; display: flex; gap: 6px; align-items: center; }
.player .langs { font-size: 12px; color: var(--muted); }
.player .score { font-weight: 800; font-size: 18px; font-family: var(--display); }

.clock-bars { display: grid; gap: 10px; }
.clock-bar { display: grid; grid-template-columns: 78px 1fr 44px; gap: 10px; align-items: center; font-size: 13px; font-weight: 600; }
.clock-bar .track { height: 8px; background: rgb(var(--fg) / 0.08); border-radius: 99px; overflow: hidden; }
.clock-bar .fill { height: 100%; border-radius: 99px; transition: width 0.5s ease; }
.clock-bar.active .track { box-shadow: 0 0 0 2px var(--warn), 0 0 16px rgba(255, 181, 71, 0.4); }

.tabs { display: flex; gap: 4px; margin-bottom: 12px; padding: 4px; background: var(--well-soft); border-radius: 12px; border: 1px solid var(--line); }
.tabs button { flex: 1; border: 0; background: transparent; font-weight: 700; padding: 7px 10px; border-radius: 9px; cursor: pointer; color: var(--muted); transition: background 0.2s, color 0.2s; }
.tabs button.on { background: var(--panel-hi); color: var(--ink); box-shadow: inset 0 0 0 1px var(--line-hi); }
.feed { display: grid; gap: 6px; max-height: 280px; overflow-y: auto; font-size: 14px; align-content: start; }
.feed .plus { color: var(--ok); font-weight: 800; }
.feed .minus { color: var(--bad); font-weight: 800; }
.chat-form { display: grid; grid-template-columns: 1fr auto auto; gap: 6px; margin-top: 10px; }
.chat-form .input { min-width: 0; }
.chat-msg { line-height: 1.45; overflow-wrap: anywhere; }
.chat-msg .chat-tr { background: none; border: 0; cursor: pointer; opacity: 0.35; padding: 0 2px; font-size: 12px; }
.chat-msg:hover .chat-tr { opacity: 1; }
.chat-msg .tr-out { margin-top: 3px; font-size: 13px; color: var(--ai-ink); padding-left: 10px; border-left: 2px solid rgba(52, 212, 200, 0.4); }

.correction { border: 1px solid var(--line-hi); border-radius: 14px; padding: 12px; display: grid; gap: 6px; font-size: 14px; background: var(--well-soft); }
.correction del { color: var(--bad); }
.correction ins { color: var(--ok); text-decoration: none; font-weight: 700; }

/* ---------- lobby ---------- */

.modes-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 14px; }
.mode-card {
  position: relative; overflow: hidden;
  display: grid; gap: 8px; align-content: start; text-align: left; cursor: pointer;
  border: 1px solid var(--line); background: var(--panel); border-radius: var(--radius); padding: 18px;
  color: var(--ink);
  transition: transform 0.2s ease, border-color 0.2s, box-shadow 0.25s, background 0.2s;
}
.mode-card::before {
  content: ''; position: absolute; inset: 0; opacity: 0; transition: opacity 0.25s;
  background: radial-gradient(400px 160px at 0% 0%, rgb(var(--violet-rgb) / 0.22), transparent 70%);
  pointer-events: none;
}
.mode-card:hover { transform: translateY(-3px); border-color: rgb(var(--violet-rgb) / 0.5); box-shadow: var(--glow); }
.mode-card:hover::before { opacity: 1; }
.mode-card:disabled { cursor: default; transform: none; border-color: var(--line); box-shadow: none; opacity: 0.55; }
.mode-card:disabled::before { opacity: 0; }
.mode-card .icon {
  font-size: 30px; color: var(--violet-ink); width: 54px; height: 54px; display: grid; place-items: center;
  border-radius: 16px; background: var(--panel-hi); border: 1px solid var(--line);
}
.mode-card h3 { font-size: 18px; }
.mode-card p { margin: 0; font-size: 14px; color: var(--muted); line-height: 1.45; }
.mode-card .pill { justify-self: start; }

/* ---------- common game bits ---------- */

.banner {
  border-radius: var(--radius); padding: 16px 20px; background: var(--grad);
  color: #fff; font-weight: 700; font-size: 18px;
  box-shadow: 0 14px 40px -16px rgb(var(--brand-rgb) / 0.6);
}
.banner.soft { background: var(--panel); color: var(--ink); border: 1px solid var(--line); box-shadow: none; }
.list { display: grid; gap: 8px; }
.list-item { display: flex; gap: 10px; align-items: center; justify-content: space-between; border: 1px solid var(--line); background: var(--well-soft); border-radius: 14px; padding: 11px 13px; flex-wrap: wrap; }

/* taboo */
.taboo-card {
  background: linear-gradient(180deg, rgb(var(--violet-rgb) / 0.16), rgb(var(--brand-rgb) / 0.08));
  border: 1px solid rgb(var(--violet-rgb) / 0.45); border-radius: 24px; padding: 24px;
  max-width: 380px; margin: 0 auto; text-align: center; box-shadow: var(--glow);
}
.taboo-card .word { font-size: 36px; font-weight: 700; font-family: var(--display); }
.taboo-card .forbidden { display: grid; gap: 4px; margin-top: 14px; padding-top: 14px; border-top: 1px dashed var(--line-hi); }
.taboo-card .forbidden span { color: var(--bad); font-weight: 700; font-size: 18px; }

/* pictionary — the drawing surface stays paper-white */
.canvas-wrap { position: relative; background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; aspect-ratio: 4 / 3; max-width: 100%; touch-action: none; border: 1px solid var(--line); }
.canvas-wrap canvas { width: 100%; height: 100%; display: block; }
.tools { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.swatch { width: 28px; height: 28px; border-radius: 50%; border: 2px solid var(--bg); box-shadow: 0 0 0 1px var(--line-hi); cursor: pointer; transition: transform 0.12s; }
.swatch:hover { transform: scale(1.1); }
.swatch.on { box-shadow: 0 0 0 2px var(--ink); }
.hint { font-family: ui-monospace, monospace; font-size: 26px; letter-spacing: 3px; font-weight: 700; }
.pic-grid { display: grid; grid-template-columns: minmax(0, 1fr) 260px; gap: 14px; }
@media (max-width: 700px) { .pic-grid { grid-template-columns: minmax(0, 1fr); } }
.guess-log { max-height: 320px; overflow-y: auto; display: grid; gap: 4px; font-size: 14px; }

/* differences — scene cells use paper so the shape colours read true */
.diff-layout { display: grid; grid-template-columns: minmax(0, 1fr) 240px; gap: 14px; }
@media (max-width: 760px) { .diff-layout { grid-template-columns: minmax(0, 1fr); } }
.scene { display: grid; gap: 4px; }
.scene-grid { display: grid; gap: 6px; }
.scene-label { display: grid; place-items: center; font-weight: 800; color: var(--muted); font-size: 13px; }
.cell {
  aspect-ratio: 1; background: var(--paper); color: var(--paper-ink); border-radius: 12px; border: 3px solid transparent; cursor: pointer;
  display: grid; place-items: center; position: relative; padding: 4px; overflow: hidden; transition: transform 0.12s;
}
.cell:hover { transform: scale(1.03); }
.cell .items { font-size: clamp(14px, 3.2vw, 30px); line-height: 1; text-align: center; }
.cell svg { width: 70%; height: 70%; }
.cell svg.small { width: 40%; height: 40%; }
.cell.mine { border-color: var(--side-a); box-shadow: 0 0 18px rgb(var(--violet-rgb) / 0.6); }
.cell.theirs::after { content: '👀'; position: absolute; top: 2px; right: 4px; font-size: 14px; }
.cell.side-b.mine { border-color: var(--side-b); box-shadow: 0 0 18px rgba(255, 148, 71, 0.6); }
.cell.found { border-color: var(--ok); background: #dcf7ea; }
.cell.found::before { content: '✓'; position: absolute; top: 0; left: 6px; color: #129a5e; font-weight: 900; }
.cell.diff { border-color: var(--warn); background: #fff1d6; }
.cell.shake { animation: shake 0.4s; border-color: var(--bad); }
@keyframes shake { 20%, 60% { transform: translateX(-4px); } 40%, 80% { transform: translateX(4px); } }
.vocab { font-size: 14px; display: grid; gap: 10px; }
.vocab h4 { margin: 0 0 4px; font-size: 11px; text-transform: uppercase; color: var(--muted); letter-spacing: 0.12em; font-family: var(--font); }
.vocab .chips { display: flex; flex-wrap: wrap; gap: 4px; }
.vocab .chips span { background: var(--panel-hi); border: 1px solid var(--line); padding: 2px 8px; border-radius: 8px; }
.scenes-end { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 700px) { .scenes-end { grid-template-columns: 1fr; } }

/* escape */
.locks { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 14px; }
.lock { display: grid; gap: 10px; align-content: start; }
.lock.solved { border-color: rgb(16 185 129 / 0.6); background: rgb(16 185 129 / 0.08); }
.lock.shake { animation: shake 0.4s; border-color: var(--bad); }
.lock h3 { display: flex; gap: 8px; align-items: center; }
.clue { background: rgba(255, 181, 71, 0.08); border: 1px dashed rgba(255, 181, 71, 0.6); border-radius: 14px; padding: 11px 13px; font-size: 17px; font-weight: 600; display: grid; gap: 6px; }
.clue.native { background: rgb(var(--fg) / 0.04); border-color: var(--line-hi); font-weight: 500; font-size: 14px; }
.shelf { background: linear-gradient(180deg, #7b5a3a, #5c4028); border-radius: 12px; padding: 8px; display: flex; flex-wrap: wrap; gap: 2px; font-size: 26px; box-shadow: inset 0 -6px 0 #3f2b19; }
.digits { display: grid; grid-template-columns: repeat(3, 1fr) auto; gap: 6px; }
.digits input { text-align: center; font-size: 22px; font-weight: 800; font-family: var(--display); }
.wires { display: grid; gap: 8px; }
.wire { height: 22px; border-radius: 99px; border: 2px solid rgba(0, 0, 0, 0.35); cursor: pointer; position: relative; transition: transform 0.12s; }
.wire:hover { transform: scaleY(1.15); }
.wire.cut { background-image: linear-gradient(90deg, transparent 46%, var(--bg) 46%, var(--bg) 54%, transparent 54%) !important; opacity: 0.5; cursor: default; }
.clock-ctl { display: grid; grid-template-columns: 120px 1fr; gap: 12px; align-items: center; }
.clock-face { width: 120px; height: 120px; }

/* truth or lie / telephone */
.statement { display: grid; grid-template-columns: auto 1fr auto; gap: 12px; align-items: start; border: 1px solid var(--line); border-radius: 16px; padding: 14px; background: var(--panel); }
.statement .num { font-size: 22px; font-weight: 700; font-family: var(--display); color: var(--brand-2); }
.statement.lie { border-color: rgba(255, 84, 104, 0.6); background: rgba(255, 84, 104, 0.08); }
.statement.truth { border-color: rgb(16 185 129 / 0.6); }
.statement .text { font-size: 18px; font-weight: 600; }
.vote-btn { text-align: left; width: 100%; justify-content: flex-start; }
.chain { display: grid; gap: 8px; }
.chain-step { display: grid; grid-template-columns: auto 1fr auto; gap: 10px; align-items: center; background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 11px 13px; animation: pop 0.3s; }
.chain-step .who { font-size: 12px; color: var(--muted); font-weight: 700; }
.chain-step .txt { font-size: 17px; font-weight: 600; }
@keyframes pop { from { transform: translateY(4px) scale(0.97); opacity: 0; } }

/* pronunciation */
.phrase { font-size: 30px; font-weight: 700; font-family: var(--display); text-align: center; padding: 22px; line-height: 1.3; }
.stars { display: flex; gap: 6px; justify-content: center; }
.stars button { background: none; border: 0; cursor: pointer; opacity: 0.5; transition: transform 0.12s, opacity 0.12s; }
.stars button.on, .stars button:hover { opacity: 1; transform: scale(1.12); }
.rec-dot { display: inline-block; width: 12px; height: 12px; border-radius: 50%; background: var(--bad); animation: blink 1s infinite; box-shadow: 0 0 12px var(--bad); }
@keyframes blink { 50% { opacity: 0.2; } }
.meter { height: 12px; background: rgb(var(--fg) / 0.08); border-radius: 99px; overflow: hidden; }
.meter div { height: 100%; background: linear-gradient(90deg, var(--bad), var(--warn), var(--ok)); }
audio { border-radius: 99px; }
:root[data-theme="dark"] audio { filter: invert(0.9) hue-rotate(180deg); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) audio { filter: invert(0.9) hue-rotate(180deg); } }

/* ---------- modal & toasts ---------- */

.modal-backdrop { position: fixed; inset: 0; background: rgba(5, 4, 12, 0.65); backdrop-filter: blur(6px); display: grid; place-items: center; padding: 16px; z-index: 50; animation: fade 0.15s; }
.modal { background: var(--panel-solid); border: 1px solid var(--line-hi); border-radius: 24px; padding: 22px; width: min(520px, 100%); max-height: 90vh; overflow-y: auto; display: grid; gap: 14px; box-shadow: 0 40px 80px -20px rgba(0, 0, 0, 0.8); animation: pop 0.2s; }
.modal-head { display: flex; align-items: center; justify-content: space-between; }
.flashcard { border: 1px solid var(--line-hi); background: var(--well-soft); border-radius: 18px; padding: 22px; text-align: center; display: grid; gap: 10px; }
.flashcard .front { font-size: 22px; font-weight: 700; }
.flashcard .back { font-size: 24px; font-weight: 800; color: var(--ok); }
#toasts { position: fixed; bottom: 20px; left: 50%; transform: translateX(-50%); display: grid; gap: 8px; z-index: 70; width: max-content; max-width: calc(100vw - 32px); }
.toast { background: var(--panel-solid); border: 1px solid var(--line-hi); color: var(--ink); padding: 11px 16px; border-radius: 14px; font-weight: 600; animation: pop 0.2s; box-shadow: 0 20px 40px -12px rgba(0, 0, 0, 0.7); }
.toast.bad { border-color: rgba(255, 84, 104, 0.6); box-shadow: 0 0 0 1px rgba(255, 84, 104, 0.3), 0 20px 40px -12px rgba(0, 0, 0, 0.7); }
.toast.ok { border-color: rgb(16 185 129 / 0.6); box-shadow: 0 0 0 1px rgb(16 185 129 / 0.3), 0 20px 40px -12px rgba(0, 0, 0, 0.7); }
@keyframes fade { from { opacity: 0; } }

/* ---------- translated call ---------- */

.call-tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 12px; }
.call-tile { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px 12px; display: grid; justify-items: center; gap: 8px; box-shadow: var(--shadow); transition: box-shadow 0.2s, opacity 0.2s, border-color 0.2s; }
.call-tile.away { opacity: 0.5; }
.call-tile.talking { border-color: var(--ok); box-shadow: 0 0 0 3px rgb(16 185 129 / 0.35), 0 0 40px -6px rgb(16 185 129 / 0.5); }
.call-avatar { width: 64px; height: 64px; border-radius: 22px; display: grid; place-items: center; font-size: 26px; font-weight: 800; color: #fff; }
.call-name { font-weight: 700; text-align: center; overflow-wrap: anywhere; }
.call-live { min-height: 64px; display: grid; gap: 4px; align-content: center; font-size: 18px; }
.call-live-line { display: flex; gap: 8px; align-items: baseline; flex-wrap: wrap; }
.call-dot { width: 10px; height: 10px; border-radius: 50%; display: inline-block; flex: none; }
.call-bar { gap: 8px; }
.call-hint { flex-basis: 100%; font-size: 13px; }
.call-log { max-height: 420px; overflow-y: auto; display: grid; gap: 12px; align-content: start; }
.call-line { border-left: 3px solid var(--line-hi); padding: 2px 0 2px 12px; }
.call-line.own { border-left-color: var(--brand-2); }
.call-line-head { font-size: 13px; }
.call-line-main { font-size: 18px; font-weight: 600; }
.call-line-sub { font-size: 14px; }

/* ---------- local AI translator ---------- */

.ai-fab {
  position: fixed; right: 20px; bottom: 20px; z-index: 40;
  display: inline-flex; align-items: center; gap: 8px;
  padding: 13px 18px 13px 14px; border-radius: 999px; border: 0; cursor: pointer;
  background: var(--grad-cool); color: #fff; font-weight: 700; font-size: 15px;
  box-shadow: 0 16px 40px -10px rgba(52, 212, 200, 0.55), 0 0 0 1px rgba(255, 255, 255, 0.15) inset;
  transition: transform 0.2s ease, box-shadow 0.2s;
}
.ai-fab:hover { transform: translateY(-2px) scale(1.02); }
.ai-fab .spark { width: 26px; height: 26px; border-radius: 50%; background: rgba(255, 255, 255, 0.2); display: grid; place-items: center; }
.ai-fab.open { opacity: 0; pointer-events: none; transform: scale(0.9); }
@media (max-width: 600px) { .ai-fab .lbl { display: none; } .ai-fab { padding: 13px; } }

.ai-panel {
  position: fixed; right: 20px; bottom: 20px; z-index: 45;
  width: min(420px, calc(100vw - 32px)); max-height: min(720px, calc(100vh - 40px));
  display: grid; grid-template-rows: auto 1fr; overflow: hidden;
  background: var(--panel-glass); border: 1px solid var(--line-hi); border-radius: 26px;
  backdrop-filter: blur(24px) saturate(1.3); -webkit-backdrop-filter: blur(24px) saturate(1.3);
  box-shadow: 0 40px 90px -20px rgba(0, 0, 0, 0.85), 0 0 0 1px rgba(52, 212, 200, 0.12);
  transform-origin: bottom right; animation: panel-in 0.22s cubic-bezier(0.2, 0.9, 0.3, 1.2);
}
@keyframes panel-in { from { opacity: 0; transform: translateY(12px) scale(0.96); } }
@media (max-width: 600px) { .ai-panel { right: 16px; left: 16px; bottom: 16px; width: auto; } }
.ai-head {
  display: flex; align-items: center; gap: 10px; padding: 16px 16px 14px 18px;
  border-bottom: 1px solid var(--line);
  background: linear-gradient(135deg, rgba(52, 212, 200, 0.12), rgb(var(--violet-rgb) / 0.12));
}
.ai-head .ai-orb {
  width: 38px; height: 38px; border-radius: 13px; background: var(--grad-cool); display: grid; place-items: center;
  font-size: 18px; box-shadow: 0 8px 20px -6px rgba(52, 212, 200, 0.6);
}
.ai-head .ai-title { display: grid; gap: 1px; margin-right: auto; }
.ai-head .ai-title b { font-family: var(--display); font-size: 16px; }
.ai-head .ai-title small { color: var(--muted); font-size: 12px; }
.ai-body { padding: 16px 18px 18px; overflow-y: auto; display: grid; gap: 12px; align-content: start; }
.ai-langs { display: grid; grid-template-columns: 1fr auto 1fr; gap: 8px; align-items: center; }
.ai-langs select { padding: 9px 10px; font-size: 14px; }
.ai-swap { width: 36px; height: 36px; padding: 0; border-radius: 50%; }
.ai-input-wrap { position: relative; }
.ai-input-wrap textarea { min-height: 96px; padding-bottom: 40px; font-size: 16px; resize: none; }
.ai-input-tools { position: absolute; left: 8px; right: 8px; bottom: 8px; display: flex; gap: 6px; align-items: center; }
.ai-input-tools .count { margin-left: auto; font-size: 11px; color: var(--muted); padding-right: 4px; }
.ai-out {
  border-radius: 18px; padding: 14px 16px; min-height: 88px; display: grid; gap: 10px; align-content: start;
  background: linear-gradient(180deg, rgba(52, 212, 200, 0.10), rgb(var(--violet-rgb) / 0.08));
  border: 1px solid rgba(52, 212, 200, 0.28);
}
.ai-out .ai-text { font-size: 20px; font-weight: 600; line-height: 1.35; overflow-wrap: anywhere; font-family: var(--display); }
.ai-out .ai-text.placeholder { color: var(--muted); font-weight: 500; font-size: 15px; font-family: var(--font); }
.ai-out .ai-actions { display: flex; gap: 6px; flex-wrap: wrap; }
.ai-status { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--muted); }
.ai-status .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--muted); flex: none; }
.ai-status .dot.ready { background: var(--ok); box-shadow: 0 0 10px var(--ok); }
.ai-status .dot.busy { background: var(--warn); animation: blink 1s infinite; }
.ai-status .dot.bad { background: var(--bad); }
.ai-progress { height: 6px; border-radius: 99px; background: rgb(var(--fg) / 0.08); overflow: hidden; }
.ai-progress div { height: 100%; background: var(--grad-cool); transition: width 0.3s; }
.ai-thinking { display: inline-flex; gap: 4px; }
.ai-thinking i { width: 7px; height: 7px; border-radius: 50%; background: var(--brand-3); animation: bounce 1s infinite; }
.ai-thinking i:nth-child(2) { animation-delay: 0.15s; }
.ai-thinking i:nth-child(3) { animation-delay: 0.3s; }
@keyframes bounce { 0%, 80%, 100% { transform: translateY(0); opacity: 0.4; } 40% { transform: translateY(-5px); opacity: 1; } }
.ai-history { display: grid; gap: 6px; }
.ai-history h4 { font-size: 11px; text-transform: uppercase; letter-spacing: 0.12em; color: var(--muted); font-family: var(--font); }
.ai-hist-item {
  text-align: left; border: 1px solid var(--line); background: var(--well-soft); border-radius: 12px;
  padding: 8px 10px; cursor: pointer; display: grid; gap: 2px; font-size: 13px; color: var(--ink);
}
.ai-hist-item:hover { border-color: var(--line-hi); background: var(--panel-hi); }
.ai-hist-item .src { color: var(--muted); }
.ai-note { font-size: 11.5px; color: var(--muted); line-height: 1.45; }
.rec-on { background: linear-gradient(135deg, #ff5468, #e03352) !important; color: #fff !important; box-shadow: 0 0 0 3px rgba(255, 84, 104, 0.3) !important; }

/* ---------- icons & language tags ---------- */

.i { width: 1.15em; height: 1.15em; flex: none; vertical-align: -0.2em; stroke-width: 1.9; }
.btn .i { width: 16px; height: 16px; vertical-align: middle; }
.btn.big .i { width: 19px; height: 19px; }
.btn.small .i { width: 15px; height: 15px; }
.i.dim { opacity: 0.55; }
.i.ok { color: var(--ok); }
.i.bad { color: var(--bad); }
.i.gold { color: var(--warn); }
h2 .i, h3 .i { vertical-align: -0.15em; color: var(--ink-2); }
.banner .i { width: 20px; height: 20px; vertical-align: -4px; margin-right: 4px; }
.pill .i { width: 14px; height: 14px; }
.muted .i { opacity: 0.8; }

.lt {
  display: inline-grid; place-items: center; min-width: 26px; height: 18px; padding: 0 5px;
  border-radius: 6px; font-size: 10px; font-weight: 800; letter-spacing: 0.06em; line-height: 1;
  font-family: var(--display); vertical-align: 1px;
  background: rgb(var(--fg) / 0.06); color: var(--ink-2); border: 1px solid var(--line-hi);
}
.lt.es { color: var(--es-ink); border-color: rgb(245 158 11 / 0.35); background: rgb(245 158 11 / 0.1); }
.lt.zh { color: var(--zh-ink); border-color: rgb(239 68 68 / 0.35); background: rgb(239 68 68 / 0.1); }
.lt.it { color: var(--it-ink); border-color: rgb(139 92 246 / 0.35); background: rgb(139 92 246 / 0.1); }
.lt.en { color: var(--en-ink); border-color: rgba(59, 130, 246, 0.35); background: rgba(59, 130, 246, 0.1); }
.lt.ru { color: var(--ru-ink); border-color: rgb(16 185 129 / 0.35); background: rgb(16 185 129 / 0.1); }
.pill .lt { background: transparent; border: 0; padding: 0; min-width: 0; color: inherit; }

.mode-icon {
  width: 42px; height: 42px; display: grid; place-items: center; border-radius: 12px; flex: none;
  background: rgb(var(--violet-rgb) / 0.12); border: 1px solid rgb(var(--violet-rgb) / 0.28); color: var(--violet-ink);
}
.mode-icon .i { width: 21px; height: 21px; }
.mode-card .icon .i { width: 24px; height: 24px; color: var(--violet-ink); }
.mode-card:hover .icon { background: rgb(var(--violet-rgb) / 0.16); border-color: rgb(var(--violet-rgb) / 0.4); }
.hero-icon {
  width: 64px; height: 64px; margin: 0 auto 6px; display: grid; place-items: center; border-radius: 20px;
  background: var(--panel-hi); border: 1px solid var(--line-hi); color: var(--ink-2);
}
.hero-icon .i { width: 30px; height: 30px; stroke-width: 1.6; }
.hero-icon.ok { color: var(--ok); border-color: rgb(16 185 129 / 0.4); background: rgb(16 185 129 / 0.08); }
.logo-mark .i { width: 58%; height: 58%; stroke-width: 2.2; color: #fff; }
.home-hero .logo-mark { font-size: 1em; width: 1.05em; height: 1.05em; border-radius: 28%; }
.ai-orb .i { width: 20px; height: 20px; color: #fff; }
.ai-fab .spark .i { width: 15px; height: 15px; }
.ai-head small .i { width: 12px; height: 12px; vertical-align: -1px; }
.player .name .i { width: 14px; height: 14px; }
.player .langs { display: flex; align-items: center; gap: 4px; }
.player .langs .i { width: 12px; height: 12px; }
.clock-bar > span:first-child { display: flex; align-items: center; gap: 6px; }
.lang-pair .arrow .i { width: 16px; height: 16px; color: var(--muted); }
.room-code .i { width: 13px; height: 13px; }
.tabs button .i { width: 15px; height: 15px; vertical-align: -3px; margin-right: 2px; }
.chat-msg .chat-tr .i { width: 13px; height: 13px; color: var(--ai-ink); }
.call-tile .muted { display: flex; align-items: center; gap: 6px; }
.dot-size { display: inline-block; border-radius: 50%; background: currentColor; }
.star-row { display: inline-flex; gap: 2px; vertical-align: middle; }
.star-row .i, .i.on { color: var(--warn); }
.star-row .i.on, .stars button.on .i, .i.on { fill: var(--warn); }
.star-row .i:not(.on) { opacity: 0.35; }
.stars button { color: var(--warn); filter: none; }
.stars button .i { width: 34px; height: 34px; stroke-width: 1.6; }
.stars button.on .i, .stars button:hover .i { fill: var(--warn); }
.rank { width: 28px; height: 28px; display: inline-grid; place-items: center; border-radius: 50%; font-weight: 800; background: var(--panel-hi); }
.rank .i { width: 16px; height: 16px; }
.rank-1 { color: #ffc94d; background: rgba(255, 201, 77, 0.12); }
.rank-2 { color: var(--silver); background: rgba(207, 214, 228, 0.12); }
.rank-3 { color: #e0a070; background: rgba(224, 160, 112, 0.12); }
.pill .i + .i { margin-left: -4px; }
.spin .i { animation: spin 0.9s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
.feed > div .i { width: 14px; height: 14px; vertical-align: -2px; }

/* ---------- flags & theme switch ---------- */

.flag { width: 18px; height: 12px; border-radius: 3px; flex: none; display: inline-block; vertical-align: -1px; box-shadow: 0 0 0 1px rgb(var(--fg) / 0.12); overflow: hidden; }
.lt { gap: 5px; grid-auto-flow: column; }
.lt .flag { width: 15px; height: 10px; border-radius: 2px; }
.pill .lt { gap: 5px; }
.flag-select { position: relative; }
.flag-select .flag { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); pointer-events: none; width: 20px; height: 14px; }
.flag-select select.input { padding-left: 42px; }
.theme-toggle { width: 36px; height: 36px; padding: 0; border-radius: 50%; }
.theme-toggle .i { width: 17px; height: 17px; }
.home-tools { position: fixed; top: 14px; right: 16px; z-index: 30; }

/* ---------- lessons ---------- */

.ls-intro, .ls-head { display: flex; gap: 16px; align-items: center; flex-wrap: wrap; }
.ls-head-text { flex: 1; min-width: 220px; display: grid; gap: 4px; }
.ls-head h2, .ls-intro h2 { font-size: 22px; }
.ls-head-icon, .ls-card-icon {
  width: 52px; height: 52px; border-radius: 16px; display: grid; place-items: center; flex: none;
  background: linear-gradient(135deg, rgb(var(--violet-rgb) / 0.18), rgb(var(--brand-rgb) / 0.14));
  border: 1px solid rgb(var(--violet-rgb) / 0.3); color: var(--violet-ink);
}
.ls-head-icon .i, .ls-card-icon .i { width: 24px; height: 24px; }
.ls-card-icon { width: 44px; height: 44px; border-radius: 13px; }
.ls-card-icon .i { width: 21px; height: 21px; }

.ls-library { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 14px; }
.ls-card {
  position: relative; text-align: left; display: grid; gap: 6px; align-content: start; cursor: pointer; color: var(--ink);
  background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; overflow: hidden;
  transition: transform 0.2s, border-color 0.2s, box-shadow 0.25s;
}
.ls-card:hover:not(:disabled) { transform: translateY(-3px); border-color: rgb(var(--violet-rgb) / 0.5); box-shadow: var(--glow); }
.ls-card:disabled { cursor: default; }
.ls-card h3 { font-size: 18px; margin-top: 2px; }
.ls-card p { margin: 4px 0 0; font-size: 13.5px; color: var(--muted); line-height: 1.45; }
.ls-card-en { font-size: 12.5px; }
.ls-card-num { position: absolute; right: 16px; bottom: 6px; font-family: var(--display); font-size: 52px; font-weight: 700; color: rgb(var(--fg) / 0.05); pointer-events: none; }
.ok-pill { color: var(--ok); border-color: rgb(16 185 129 / 0.35); background: rgb(16 185 129 / 0.1); }

.ls-stepper { display: flex; align-items: center; gap: 6px; padding: 4px 2px; overflow-x: auto; }
.ls-step { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: 13px; font-weight: 600; white-space: nowrap; }
.ls-step-dot { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: var(--panel-hi); border: 1px solid var(--line-hi); flex: none; }
.ls-step-dot .i { width: 15px; height: 15px; }
.ls-step.on { color: var(--ink); }
.ls-step.on .ls-step-dot { background: var(--grad); color: #fff; border-color: transparent; box-shadow: 0 6px 18px -6px rgb(var(--brand-rgb) / 0.6); }
.ls-step.done .ls-step-dot { background: rgb(16 185 129 / 0.14); color: var(--ok); border-color: rgb(16 185 129 / 0.4); }
.ls-step-line { flex: 1; min-width: 14px; height: 2px; border-radius: 2px; background: var(--line-hi); }
@media (max-width: 760px) { .ls-step:not(.on) .ls-step-label { display: none; } }

.ls-ready { gap: 10px; padding: 12px 16px; }
.ls-ready-people { display: flex; gap: 6px; flex-wrap: wrap; }
.ls-person { display: inline-flex; align-items: center; gap: 5px; padding: 5px 11px; border-radius: 99px; font-size: 13px; font-weight: 600; background: var(--panel-hi); border: 1px solid var(--line); color: var(--muted); }
.ls-person.ok { color: var(--ok); border-color: rgb(16 185 129 / 0.4); background: rgb(16 185 129 / 0.1); }
.ls-person .i { width: 13px; height: 13px; }

.ls-vocab { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 10px; }
.ls-word {
  border: 1px solid var(--line); background: var(--well-soft); border-radius: 16px; padding: 14px; cursor: pointer;
  display: grid; gap: 6px; transition: border-color 0.2s, background 0.2s;
}
.ls-word:hover { border-color: var(--line-hi); }
.ls-word.open { border-color: rgb(var(--violet-rgb) / 0.4); background: rgb(var(--violet-rgb) / 0.06); }
.ls-word-en { font-family: var(--display); font-size: 19px; font-weight: 700; }
.ls-word-tr { font-size: 14px; min-height: 20px; }
.ls-word-tools { display: flex; gap: 4px; justify-content: flex-end; }
.ls-say { flex: none; }

.ls-points { margin: 0; padding-left: 22px; display: grid; gap: 10px; line-height: 1.55; }
.ls-points li::marker { color: var(--brand-2); font-weight: 800; font-family: var(--display); }
.ls-point-en { font-size: 13px; margin-top: 2px; }
.ls-sub { font-size: 11px; text-transform: uppercase; letter-spacing: 0.12em; color: var(--muted); font-family: var(--font); margin-top: 4px; }
.ls-examples { display: grid; gap: 8px; }
.ls-example { display: flex; gap: 10px; align-items: center; padding: 10px 12px; border-radius: 14px; background: var(--well-soft); border: 1px solid var(--line); }
.ls-example-en { font-weight: 700; font-size: 16px; }

.ls-ex { gap: 16px; }
.ls-progress { height: 5px; border-radius: 99px; background: rgb(var(--fg) / 0.08); overflow: hidden; }
.ls-progress div { height: 100%; background: var(--grad); transition: width 0.4s; }
.ls-prompt-label { font-size: 12px; text-transform: uppercase; letter-spacing: 0.1em; font-weight: 700; }
.ls-prompt { font-family: var(--display); font-size: 26px; font-weight: 600; line-height: 1.35; margin-top: -8px; }
.ls-blank { display: inline-block; min-width: 70px; border-bottom: 3px solid var(--brand-2); color: transparent; margin: 0 4px; }
.ls-answer-form { align-items: stretch; }
.ls-options { display: grid; gap: 8px; }
.ls-option { justify-content: flex-start; padding: 13px 14px; font-size: 16px; white-space: normal; text-align: left; }
.ls-letter { width: 26px; height: 26px; border-radius: 8px; display: grid; place-items: center; background: var(--panel-hi); font-size: 13px; flex: none; margin-right: 4px; }
.ls-order-built { min-height: 58px; display: flex; flex-wrap: wrap; gap: 8px; align-items: center; padding: 10px; border-radius: 14px; border: 1px dashed var(--line-hi); background: var(--well-soft); }
.ls-order-pool { display: flex; flex-wrap: wrap; gap: 8px; }
.ls-chip {
  border: 1px solid var(--line-hi); background: var(--panel-hi); color: var(--ink); border-radius: 11px; padding: 9px 13px;
  font-weight: 600; font-size: 15px; cursor: pointer; transition: transform 0.12s, opacity 0.2s;
}
.ls-chip:hover:not(:disabled) { transform: translateY(-1px); border-color: var(--brand-2); }
.ls-chip:disabled { opacity: 0.25; cursor: default; }
.ls-chip.on { background: rgb(var(--violet-rgb) / 0.14); border-color: rgb(var(--violet-rgb) / 0.45); }
.ls-waiting { display: flex; gap: 8px; align-items: center; color: var(--muted); padding: 12px; border-radius: 12px; background: var(--well-soft); }
.ls-hint { padding: 10px 12px; border-radius: 12px; background: rgba(255, 181, 71, 0.1); border: 1px solid rgba(255, 181, 71, 0.35); font-size: 14px; }
.ls-result { display: grid; gap: 6px; padding: 14px 16px; border-radius: 16px; border: 1px solid; }
.ls-result.ok { background: rgb(16 185 129 / 0.09); border-color: rgb(16 185 129 / 0.4); }
.ls-result.close { background: rgba(255, 181, 71, 0.09); border-color: rgba(255, 181, 71, 0.45); }
.ls-result.wrong { background: rgba(255, 84, 104, 0.08); border-color: rgba(255, 84, 104, 0.4); }
.ls-result-head { font-family: var(--display); font-weight: 700; font-size: 18px; display: flex; gap: 8px; align-items: center; }
.ls-result.ok .ls-result-head { color: var(--ok); }
.ls-result.close .ls-result-head { color: var(--warn); }
.ls-result.wrong .ls-result-head { color: var(--bad); }
.ls-given { font-weight: 600; }
.ls-solution { display: flex; gap: 8px; align-items: center; font-family: var(--display); font-size: 18px; font-weight: 600; }

.ls-lines { display: grid; gap: 8px; }
.ls-line { display: grid; grid-template-columns: auto 1fr auto; gap: 12px; align-items: start; padding: 12px; border-radius: 16px; border: 1px solid var(--line); background: var(--well-soft); opacity: 0.55; transition: opacity 0.2s, border-color 0.2s; }
.ls-line.read { opacity: 0.8; }
.ls-line.current { opacity: 1; border-color: rgb(var(--violet-rgb) / 0.5); background: rgb(var(--violet-rgb) / 0.07); box-shadow: var(--glow); }
.ls-line-en { font-size: 17px; font-weight: 600; }
.ls-role { width: 28px; height: 28px; border-radius: 9px; display: inline-grid; place-items: center; font-weight: 800; font-size: 13px; font-family: var(--display); color: #fff; flex: none; }
.ls-role-A { background: var(--brand-2); }
.ls-role-B { background: linear-gradient(135deg, #ff9447, #ff5c8a); }
.ls-heard { font-size: 13px; color: var(--muted); margin-top: 4px; }
.ls-heard b.good { color: var(--ok); }
.ls-heard b.mid { color: var(--warn); }
.ls-heard b.low { color: var(--bad); }

.ls-speak-prompt { font-family: var(--display); font-size: 22px; font-weight: 600; line-height: 1.4; }
.ls-tips { display: grid; gap: 8px; }
.ls-tips > div { display: flex; gap: 10px; align-items: center; padding: 10px 12px; border-radius: 12px; background: var(--well-soft); border: 1px solid var(--line); font-size: 14px; }
.ls-tips .i { color: var(--violet-ink); }

.ls-summary { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 10px; }
.ls-sum-card { display: grid; gap: 8px; padding: 14px; border-radius: 16px; border: 1px solid var(--line); background: var(--well-soft); }
.ls-sum-name { font-weight: 700; }
.ls-sum-row { display: flex; justify-content: space-between; align-items: center; font-size: 14px; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
}

/* ---------- live subtitles bar (visible in every mode) ---------- */

#live-root[hidden] { display: none; }
.live-bar {
  position: fixed; left: 16px; right: 16px; bottom: 16px; z-index: 35;
  display: grid; gap: 8px; padding: 10px 12px;
  background: var(--panel-glass); border: 1px solid var(--line-hi); border-radius: 20px;
  backdrop-filter: blur(20px) saturate(1.3); -webkit-backdrop-filter: blur(20px) saturate(1.3);
  box-shadow: 0 30px 70px -24px rgba(0, 0, 0, 0.8);
}
@media (min-width: 900px) { .live-bar { right: 116px; } }
.live-bar-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.live-badge { display: inline-flex; align-items: center; gap: 6px; font-weight: 700; font-size: 13px; }
.live-bar-log { display: grid; gap: 8px; max-height: 30vh; overflow-y: auto; }
.live-bar-log .call-line-main { font-size: 16px; }
.live-bar-interim { font-size: 15px; min-height: 0; }
.live-bar-interim:empty { display: none; }
.live-bar.mini { gap: 0; }
body.with-live-bar { padding-bottom: 34vh; }

/* A word in a language you are learning: click it to keep it in the deck. */
.vocab-word {
  background: none; border: 0; padding: 0; margin: 0; font: inherit; color: inherit;
  cursor: pointer; border-bottom: 1px dashed transparent; border-radius: 3px;
}
.vocab-word:hover { border-bottom-color: currentColor; background: rgba(124, 92, 255, 0.18); }
.vocab-word.saving { opacity: 0.5; }
.btn.tiny { padding: 2px 6px; border-radius: 8px; font-size: 12px; line-height: 1; }

/* ---------- tandem: segmented choices ---------- */
.seg { display: inline-flex; gap: 4px; padding: 4px; background: var(--well-soft); border: 1px solid var(--line); border-radius: 12px; }
.seg button, .seg-opt {
  border: 0; background: transparent; color: var(--muted); font: inherit; font-weight: 700; font-size: 13px;
  padding: 6px 10px; border-radius: 9px; cursor: pointer; display: inline-flex; align-items: center; gap: 8px;
  transition: background 0.2s, color 0.2s;
}
.seg button.on, .seg-opt.on { background: var(--panel-hi); color: var(--ink); box-shadow: inset 0 0 0 1px var(--line-hi); }
.seg-opt input { position: absolute; opacity: 0; pointer-events: none; }
.seg-opt:has(input:focus-visible) { outline: 2px solid var(--brand-2); outline-offset: 1px; }
.learn-seg { display: grid; grid-template-columns: 1fr 1fr; width: 100%; }
.learn-seg .seg-opt { justify-content: center; padding: 11px 12px; font-size: 15px; }
.learn-seg .flag { width: 22px; height: 15px; }
.lobby-me .learn-seg, .card .row .learn-seg { width: auto; }
.home-tools { display: flex; gap: 8px; align-items: center; }
.ui-seg button { padding: 5px 8px; font-size: 12px; letter-spacing: 0.04em; }

/* ---------- home: play form + how it works ---------- */
.home { max-width: 1080px; padding: 64px 16px 24px; }
.home-top { display: grid; gap: 28px; align-items: center; }
.home-side { width: 100%; max-width: 460px; margin: 0 auto; }
.home-hero .eyebrow .flag { vertical-align: -1px; }
.home-scroll { color: var(--muted); font-size: 14px; font-weight: 600; text-decoration: none; display: inline-flex; gap: 6px; align-items: center; }
.home-scroll:hover { color: var(--ink); }
.invite-banner { padding: 10px 12px; border-radius: var(--radius-sm); background: rgb(var(--violet-rgb) / 0.12); color: var(--violet-ink); font-weight: 600; display: flex; gap: 8px; align-items: center; }
.have-code summary { cursor: pointer; color: var(--muted); font-size: 14px; font-weight: 600; text-align: center; list-style: none; }
.have-code summary::-webkit-details-marker { display: none; }
.have-code[open] summary { margin-bottom: 10px; }
@media (min-width: 900px) {
  .home-top { grid-template-columns: 1.15fr 1fr; gap: 48px; min-height: calc(100vh - 140px); }
  .home-top .home-hero { justify-items: start; text-align: left; }
  .home-top .home-features { justify-content: flex-start; }
  .home-top .tagline { font-size: 19px; max-width: 34ch; }
}

.how { display: grid; gap: 56px; padding: 72px 0 24px; }
.how-title { text-align: center; font-family: var(--display); font-size: clamp(26px, 4vw, 36px); }
.how-step { display: grid; gap: 20px; align-items: center; }
.how-num { display: inline-flex; align-items: center; gap: 6px; font-family: var(--display); font-weight: 700; color: var(--violet-ink); background: rgb(var(--violet-rgb) / 0.12); padding: 4px 10px; border-radius: 99px; font-size: 14px; }
.how-num .i { width: 15px; height: 15px; }
.how-text h3 { font-size: clamp(20px, 2.6vw, 26px); margin: 12px 0 8px; font-family: var(--display); }
.how-text p { font-size: 16px; line-height: 1.55; margin: 0; max-width: 42ch; }
.how-shot { margin: 0; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line-hi); box-shadow: var(--shadow), 0 30px 60px -30px rgb(var(--violet-rgb) / 0.35); background: var(--panel-solid); aspect-ratio: 16 / 10; }
.how-shot img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: top left; }
.how-shot.missing { display: none; }
@media (min-width: 900px) {
  .how-step { grid-template-columns: 1fr 1.6fr; gap: 48px; }
  .how-step.flip .how-text { order: 2; }
}

/* ---------- team card ---------- */
.team-card { display: grid; gap: 14px; }
.team-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.team-score { font-family: var(--display); font-size: 34px; font-weight: 800; line-height: 1; background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.team-head .muted { font-size: 12px; }
.streak { display: flex; gap: 8px; align-items: center; font-size: 13px; color: var(--muted); text-align: right; }
.streak .i { width: 26px; height: 26px; }
.streak.on { color: var(--warn); }
.streak.on b { color: var(--ink); }
.streak.met .i { filter: drop-shadow(0 0 8px rgba(255, 181, 71, 0.7)); }
.player .score.small { font-size: 13px; color: var(--muted); }
.goal { display: grid; gap: 10px; padding-top: 12px; border-top: 1px solid var(--line); }
.goal-head { justify-content: space-between; }
.goal-head h3 { display: flex; gap: 6px; align-items: center; }
.goal-head h3 .i { width: 16px; height: 16px; }
.goal-seg button { padding: 3px 8px; font-size: 12px; }
.goal-help { font-size: 12px; margin-top: -6px; }
.goal .clock-bar { grid-template-columns: 108px 1fr auto; }
.goal .clock-bar .timer { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.goal-note { font-size: 13px; color: var(--ink-2); display: flex; gap: 6px; align-items: center; }
.goal-note .i { width: 15px; height: 15px; flex: none; }
.goal-note.ok { color: var(--ok); font-weight: 700; }
.room-clock { font-size: 12px; display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }

/* ---------- lessons: tracks and coach ---------- */
.ls-tracks { margin-bottom: 0; }
.ls-tracks button { display: inline-flex; gap: 6px; align-items: center; justify-content: center; }
.ls-tracks .muted { font-weight: 500; }
.ls-word-lat { font-size: 12px; letter-spacing: 0.02em; }
.pill.coach-pill { background: rgba(255, 181, 71, 0.12); color: var(--warn); border-color: rgba(255, 181, 71, 0.3); }
.banner.coach-banner { background: rgba(255, 181, 71, 0.12); color: var(--ink); border: 1px solid rgba(255, 181, 71, 0.3); box-shadow: none; }
.how-shot.card-shot { aspect-ratio: auto; max-width: 400px; width: 100%; justify-self: center; background: transparent; }
.how-shot.card-shot img { height: auto; object-fit: contain; }
@media (min-width: 900px) { .how-step.flip { grid-template-columns: 1.6fr 1fr; } }
.how .btn { text-decoration: none; }

/* =================== home, sigment-style =================== */
html { scroll-behavior: smooth; scroll-padding-top: 76px; }
.site-nav {
  position: sticky; top: 0; z-index: 40; display: flex; align-items: center; gap: 12px;
  padding: 12px max(16px, calc((100vw - 1200px) / 2)); background: rgb(var(--bg-rgb) / 0.78);
  backdrop-filter: saturate(1.4) blur(14px); -webkit-backdrop-filter: saturate(1.4) blur(14px);
  border-bottom: 1px solid var(--line);
}
.site-nav .spacer { flex: 1; }
.logo.small { font-size: 22px; text-decoration: none; color: var(--ink); gap: 8px; }
.logo.small span:not(.logo-mark) { background: none; color: var(--brand); -webkit-text-fill-color: currentColor; }
.logo-mark { background: var(--brand); box-shadow: 0 8px 20px -8px rgb(var(--brand-rgb) / 0.7); }
.site-links { display: flex; gap: 22px; margin-left: 18px; }
.site-links a { color: var(--ink-2); text-decoration: none; font-weight: 600; font-size: 14px; }
.site-links a:hover { color: var(--ink); }
@media (max-width: 760px) { .site-links, .nav-cta { display: none; } .site-nav { gap: 8px; } }

.hero { position: relative; overflow: hidden; min-height: calc(100vh - 62px); display: grid; align-items: center; }
.hero-graph { position: absolute; inset: 0; width: 100%; height: 100%; }
.hero::after { content: ''; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(90deg, rgb(var(--bg-rgb) / 0.92) 0%, rgb(var(--bg-rgb) / 0.55) 38%, transparent 62%); }
.hero-inner { position: relative; z-index: 1; width: 100%; max-width: 1200px; margin: 0 auto; padding: 56px 16px 64px; }
.hero-copy { max-width: 640px; display: grid; gap: 20px; justify-items: start; }
.hero .eyebrow {
  font-size: 12px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; display: inline-flex; gap: 8px; align-items: center;
  padding: 6px 12px; border-radius: 999px; background: rgb(var(--brand-rgb) / 0.08); color: var(--brand); border: 1px solid rgb(var(--brand-rgb) / 0.25);
}
.hero-title { font-size: clamp(40px, 6.6vw, 80px); line-height: 1.02; letter-spacing: -0.045em; font-weight: 800; }
.hero-title .hl { color: var(--brand); }
.hero-sub { font-size: clamp(16px, 1.6vw, 19px); line-height: 1.55; color: var(--ink-2); margin: 0; max-width: 52ch; }
.home-form { width: 100%; max-width: 560px; display: grid; gap: 14px; padding: 20px; box-shadow: 0 30px 60px -30px rgb(var(--fg) / 0.25), var(--shadow); }
.home-form-row { display: grid; grid-template-columns: 1fr 1.2fr; gap: 12px; align-items: end; }
.home-form-actions { display: grid; gap: 10px; }
@media (max-width: 560px) { .home-form-row { grid-template-columns: 1fr; } .hero::after { background: rgb(var(--bg-rgb) / 0.6); } }
.hero-links { gap: 8px; }

.band { background: var(--navy); color: var(--navy-ink); position: relative; overflow: hidden; }
.band::before { content: ''; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(600px 240px at 15% 0%, rgb(var(--brand-rgb) / 0.22), transparent 70%), radial-gradient(600px 260px at 90% 100%, rgb(16 185 129 / 0.16), transparent 70%); }
.band-inner { position: relative; max-width: 1200px; margin: 0 auto; padding: 44px 16px; }
.stats-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; text-align: center; }
.stat-n { font-size: clamp(34px, 4.6vw, 52px); font-weight: 800; letter-spacing: -0.04em; font-variant-numeric: tabular-nums; }
.stat:nth-child(1) .stat-n { color: #ff4fa3; }
.stat:nth-child(2) .stat-n { color: #6ee7b7; }
.stat:nth-child(3) .stat-n { color: #93b4ff; }
.stat:nth-child(4) .stat-n { color: #fcd34d; }
.stat-l { color: #94a3b8; font-weight: 600; font-size: 14px; }
@media (max-width: 700px) { .stats-grid { grid-template-columns: repeat(2, 1fr); row-gap: 28px; } }

.home { max-width: 1200px; padding: 24px 16px 40px; }
.section-title { text-align: center; font-size: clamp(28px, 4vw, 44px); letter-spacing: -0.04em; }
.section-sub { text-align: center; max-width: 60ch; margin: 12px auto 0; font-size: 16px; line-height: 1.55; }
.how { padding-top: 64px; }
.how-shot { transition: transform 0.5s cubic-bezier(.2,.7,.2,1), box-shadow 0.5s; box-shadow: 0 40px 80px -40px rgb(var(--fg) / 0.35), var(--shadow); }
.how-step:hover .how-shot { transform: translateY(-6px) rotate(-0.4deg); }
.how-num { background: rgb(var(--brand-rgb) / 0.08); color: var(--brand); }

.vocab-teaser { display: grid; gap: 22px; padding: 90px 0 30px; }
.vt-grid { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; max-width: 900px; margin: 10px auto 0; }
.vt-chip {
  display: inline-flex; align-items: center; gap: 8px; padding: 10px 14px; border-radius: 999px; cursor: pointer;
  background: var(--panel); border: 1px solid var(--line); color: var(--ink); font-weight: 600; box-shadow: var(--shadow);
  transition: transform 0.2s, border-color 0.2s;
}
.vt-chip:hover { transform: translateY(-2px); border-color: rgb(var(--brand-rgb) / 0.5); }
.vt-icon { color: var(--brand); display: inline-flex; }
.vt-icon .i { width: 16px; height: 16px; }

.cta-band .band-inner { padding: 80px 16px; }
.cta-band h2 { font-size: clamp(30px, 4.4vw, 50px); letter-spacing: -0.045em; color: #fff; }
.cta-band p { color: #cbd5e1; font-size: 17px; margin: 0; }

/* scroll reveal */
[data-reveal].watch { opacity: 0; transform: translateY(22px); transition: opacity 0.7s ease, transform 0.7s cubic-bezier(.2,.7,.2,1); }
[data-reveal].watch.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) { [data-reveal].watch { opacity: 1; transform: none; transition: none; } .how-shot { transition: none; } }

/* =================== vocabulary book =================== */
.vb-modal { width: min(880px, calc(100vw - 32px)); max-height: calc(100vh - 48px); display: grid; grid-template-rows: auto auto 1fr; gap: 14px; }
.vb-scroll { overflow: auto; display: grid; gap: 14px; align-content: start; padding: 2px; }
.vb-bar { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.vb-search { position: relative; flex: 1; min-width: 220px; }
.vb-search > .i { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--muted); width: 16px; height: 16px; }
.vb-search .input { padding-left: 36px; }
.vb-dir button { gap: 6px; }
.vb-overall { display: grid; gap: 8px; }
.vb-meter { height: 6px; border-radius: 99px; background: rgb(var(--fg) / 0.08); overflow: hidden; display: block; }
.vb-meter > * { display: block; height: 100%; background: linear-gradient(90deg, var(--brand), #ff4fa3); border-radius: 99px; transition: width 0.4s; }
.vb-topics { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 10px; }
.vb-topic {
  display: grid; gap: 6px; text-align: left; padding: 14px; border-radius: 14px; cursor: pointer; color: var(--ink);
  background: var(--panel); border: 1px solid var(--line); transition: transform 0.2s, border-color 0.2s, box-shadow 0.2s;
}
.vb-topic:hover { transform: translateY(-2px); border-color: rgb(var(--brand-rgb) / 0.45); box-shadow: var(--shadow); }
.vb-topic-icon { width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; background: rgb(var(--brand-rgb) / 0.1); color: var(--brand); flex: none; }
.vb-topic-icon .i { width: 18px; height: 18px; }
.vb-topic-name { font-weight: 800; letter-spacing: -0.02em; }
.vb-topic-sub { font-size: 12.5px; }
.vb-topic-head { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; justify-content: space-between; }
.vb-topic-title { display: flex; gap: 10px; align-items: center; flex: 1; min-width: 200px; }
.vb-list { display: grid; gap: 8px; }
.vb-word {
  display: grid; grid-template-columns: 44px 1fr auto; gap: 12px; align-items: center; padding: 12px 14px;
  border-radius: 14px; background: var(--panel); border: 1px solid var(--line); transition: border-color 0.2s, background 0.2s;
}
.vb-word.known { border-color: rgb(16 185 129 / 0.4); background: rgb(16 185 129 / 0.05); }
.vb-emoji { font-size: 28px; text-align: center; line-height: 1; color: var(--brand); }
.vb-emoji.big { font-size: 54px; }
.vb-main { font-weight: 800; font-size: 18px; letter-spacing: -0.01em; }
.vb-pf { font-weight: 600; font-size: 15px; }
.vb-lat { font-size: 12px; color: var(--muted); letter-spacing: 0.03em; }
.vb-tr { font-size: 14px; color: var(--ink-2); display: flex; gap: 6px; align-items: center; flex-wrap: wrap; margin-top: 2px; }
.vb-gloss { color: var(--muted); display: inline-flex; gap: 5px; align-items: center; }
.vb-ex { font-size: 13px; margin-top: 4px; font-style: italic; color: var(--ink-2); }
.vb-tools { display: flex; gap: 4px; }
.vb-flash { cursor: pointer; min-height: 260px; }
.vb-hidden { font-size: 20px; font-weight: 700; }
.vb-done { gap: 12px; }
@media (max-width: 560px) { .vb-word { grid-template-columns: 34px 1fr; } .vb-tools { grid-column: 1 / -1; justify-content: flex-end; } }
.vb-modal { overflow: hidden; }

/* five languages: the learn picker wraps into a grid of flags */
.learn-seg { grid-template-columns: repeat(5, 1fr); }
.learn-seg .seg-opt { flex-direction: column; gap: 4px; padding: 9px 4px; font-size: 12.5px; }
.card .row .learn-seg { width: auto; }
.card .row .learn-seg .seg-opt { flex-direction: row; padding: 6px 10px; }
@media (max-width: 560px) { .card .row .learn-seg { grid-template-columns: repeat(5, auto); } .card .row .learn-seg .seg-opt span { display: none; } }

/* ---------- five languages: vocabulary switch, practice, "coming soon" ---------- */
.vb-dir button { padding: 5px 8px; gap: 5px; font-size: 12px; }
@media (max-width: 560px) { .vb-dir button span { display: none; } }
.sp-card { gap: 14px; }
.sp-sentence { font-size: clamp(19px, 2.4vw, 24px); font-weight: 700; line-height: 1.4; letter-spacing: -0.01em; }
.sp-blank { display: inline-block; color: var(--brand); border-bottom: 2px solid var(--brand); letter-spacing: 0.08em; padding: 0 2px; }
.sp-hint { font-size: 13.5px; color: var(--ink-2); display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.sp-hint .i { width: 15px; height: 15px; color: var(--warn); }
.sp-options { display: grid; gap: 8px; }
.sp-option { justify-content: flex-start; text-align: left; white-space: normal; padding: 12px 14px; gap: 8px; }
.sp-option.right { box-shadow: inset 0 0 0 2px var(--ok); color: var(--ink); opacity: 1; }
.sp-option.wrong { box-shadow: inset 0 0 0 2px var(--bad); opacity: 1; }
.sp-listen { display: flex; gap: 8px; }
.sp-credit { font-size: 12px; text-align: right; display: flex; gap: 6px; align-items: center; justify-content: flex-end; }
.sp-credit .i { width: 13px; height: 13px; }
.mode-card.soon { opacity: 0.7; }
.soon-pill { background: rgb(245 158 11 / 0.1); color: var(--warn); border-color: rgb(245 158 11 / 0.3); }
.soon-pill .flag { width: 14px; height: 10px; }
.ls-tracks { flex-wrap: wrap; }
.ls-tracks button.empty { opacity: 0.6; }
@media (max-width: 700px) { .ls-tracks .ls-track-name { display: none; } }
.ls-soon { display: flex; gap: 8px; align-items: center; }
.credit-data { margin-top: 6px; font-size: 12px; }
.credit-data a { color: var(--muted); text-decoration: none; }
.credit-data a:hover { color: var(--ink); text-decoration: underline; }
.hero .eyebrow .flags { display: inline-flex; gap: 3px; }

/* =================== Linguino brand =================== */
h1, h2, h3, .section-title, .hero-title, .stat-n { font-family: var(--display); }
.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: inherit; font-family: var(--display); font-weight: 900; letter-spacing: -0.01em; }
.brand-mark { width: 38px; height: 38px; border-radius: 50%; display: block; box-shadow: 0 4px 14px -4px rgb(var(--violet-rgb) / 0.6); flex: none; }
.brand-name { font-size: 24px; line-height: 1; }
.brand-name small { display: block; font: 600 11px/1.2 var(--font); letter-spacing: 0.02em; opacity: 0.7; margin-top: 2px; }
.topbar .brand-mark { width: 34px; height: 34px; }
.topbar .brand-name { font-size: 21px; }

/* ---------- opening screen ---------- */
#splash { position: fixed; inset: 0; z-index: 1000; display: grid; place-items: center; overflow: hidden; cursor: pointer; }
.sp-bg { position: absolute; inset: 0; background: radial-gradient(120% 90% at 50% 45%, #5a9ddb 0%, #3e83c4 45%, #2f6aa8 100%); }
.sp-center { position: relative; width: min(64vmin, 440px); aspect-ratio: 1; display: grid; place-items: center; }
.sp-logo { position: relative; width: 100%; height: 100%; border-radius: 50%; will-change: transform;
  animation: sp-pop 1s cubic-bezier(.34, 1.56, .64, 1) .2s both, sp-float 3.2s ease-in-out 1.3s infinite; }
.sp-ring { position: absolute; inset: -5%; width: 110%; height: 110%; transform: rotate(-90deg); overflow: visible; }
.sp-ring circle { fill: none; stroke: rgba(255, 255, 255, .85); stroke-width: 1.4; stroke-linecap: round; stroke-dasharray: 610; stroke-dashoffset: 610;
  filter: drop-shadow(0 0 6px rgba(255, 255, 255, .8)); animation: sp-draw 1.1s cubic-bezier(.65, 0, .35, 1) .05s forwards, sp-ring-pulse 2.4s ease-in-out 1.2s infinite; }
.sp-glow { position: absolute; inset: -18%; border-radius: 50%; background: radial-gradient(circle, rgba(255, 255, 255, .35), transparent 62%);
  animation: sp-glow 1.4s ease-out .3s both; }
.sp-by { position: absolute; bottom: max(7vh, 40px); left: 0; right: 0; text-align: center; color: rgba(255, 255, 255, .88);
  font: 600 14px/1 var(--font); letter-spacing: .18em; text-transform: uppercase; animation: sp-rise .8s cubic-bezier(.2, .7, .2, 1) 1.05s both; }
.sp-by b { font-family: var(--display); font-weight: 900; letter-spacing: .06em; color: #fff; text-transform: none; font-size: 18px; margin-left: 4px; }
.sp-bubbles span {
  position: absolute; left: var(--x); bottom: -60px; padding: 8px 14px; border-radius: 16px 16px 16px 4px;
  background: rgba(255, 255, 255, .18); color: #fff; font: 800 15px/1 var(--display); backdrop-filter: blur(4px);
  border: 1px solid rgba(255, 255, 255, .28); animation: sp-bubble 3.6s cubic-bezier(.3, .6, .4, 1) calc(.4s + var(--d)) both;
}
#splash.quick .sp-logo { animation: sp-pop .55s cubic-bezier(.34, 1.56, .64, 1) both; }
#splash.quick .sp-ring circle { animation-duration: .5s; }
#splash.quick .sp-by { animation-delay: .2s; }
#splash.quick .sp-bubbles { display: none; }
body.splash-on { overflow: hidden; }
body.splash-leaving #app { animation: app-in .7s cubic-bezier(.2, .7, .2, 1) both; }

@keyframes sp-pop { from { opacity: 0; transform: scale(.35) rotate(-14deg); filter: blur(10px); } 60% { opacity: 1; filter: blur(0); } to { opacity: 1; transform: scale(1) rotate(0); } }
@keyframes sp-float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }
@keyframes sp-draw { to { stroke-dashoffset: 0; } }
@keyframes sp-ring-pulse { 0%, 100% { opacity: .85; } 50% { opacity: .45; } }
@keyframes sp-glow { from { opacity: 0; transform: scale(.6); } to { opacity: 1; transform: scale(1); } }
@keyframes sp-rise { from { opacity: 0; transform: translateY(14px); letter-spacing: .5em; } to { opacity: 1; transform: none; } }
@keyframes sp-bubble { 0% { opacity: 0; transform: translateY(0) scale(.7); } 15% { opacity: 1; transform: translateY(-12vh) scale(1); } 100% { opacity: 0; transform: translateY(-78vh) scale(.95); } }
@keyframes app-in { from { opacity: 0; transform: translateY(10px) scale(.99); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) {
  .sp-logo, .sp-ring circle, .sp-glow, .sp-by, .sp-bubbles span { animation: none !important; }
  .sp-ring circle { stroke-dashoffset: 0; }
  .sp-bubbles { display: none; }
}

/* ---------- hero in the logo's blue ---------- */
.hero { background: radial-gradient(90% 120% at 72% 45%, color-mix(in srgb, var(--hero-a) 80%, #fff 20%) 0%, var(--hero-a) 40%, var(--hero-b) 100%);
  --ink: #ffffff; --muted: rgba(255, 255, 255, .72); --fg: 255 255 255; color: #fff; }
.hero::after { background: radial-gradient(60% 80% at 20% 50%, rgb(0 0 0 / .10), transparent 70%); }
.hero-inner { display: grid; gap: 40px; align-items: center; }
@media (min-width: 980px) { .hero-inner { grid-template-columns: 1.1fr 0.9fr; } }
.hero .eyebrow { background: rgba(255, 255, 255, .16); color: #fff; border-color: rgba(255, 255, 255, .3); }
.hero-title { color: #fff; text-shadow: 0 2px 0 rgb(0 0 0 / .06); font-weight: 900; letter-spacing: -0.03em; }
.hero-title .hl { color: #fff; background: linear-gradient(transparent 58%, rgb(var(--brand-rgb) / .95) 58%, rgb(var(--brand-rgb) / .95) 92%, transparent 92%); padding: 0 .06em; }
.hero-sub { color: rgba(255, 255, 255, .88); }
.hero .home-form { color: var(--paper-ink); background: #fff; border: 0; box-shadow: 0 30px 60px -24px rgb(8 30 60 / .45);
  --ink: #15304d; --ink-2: #42607f; --muted: #6a829d; --line: rgba(22, 48, 77, .09); --line-hi: rgba(22, 48, 77, .16); --panel-hi: rgba(22, 48, 77, .05); --well: #fff; --well-soft: rgba(22, 48, 77, .03); --placeholder: #90a4ba; }
.hero .hero-links .btn.ghost { color: #fff; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .45); }
.hero .hero-links .btn.ghost:hover { background: rgba(255, 255, 255, .14); }
.hero-art { position: relative; display: grid; place-items: center; }
.hero-logo { width: min(440px, 80vw); aspect-ratio: 1; border-radius: 50%; animation: sp-float 4s ease-in-out infinite; filter: drop-shadow(0 30px 40px rgb(8 30 60 / .35)); }
.hero-credit { position: absolute; bottom: -8px; left: 50%; transform: translateX(-50%); white-space: nowrap; padding: 7px 14px; border-radius: 999px;
  background: rgba(255, 255, 255, .95); color: #15304d; font: 700 13px/1 var(--font); box-shadow: 0 10px 24px -10px rgb(8 30 60 / .5); }
.hero-credit b { font-family: var(--display); font-weight: 900; color: var(--brand); }
@media (max-width: 979px) { .hero-art { order: -1; } .hero-logo { width: min(260px, 62vw); } }
.site-nav .brand-name { color: var(--ink); }
.band { background: linear-gradient(135deg, #275587, #3e83c4); }
.band::before { background: radial-gradient(600px 240px at 15% 0%, rgb(255 255 255 / .12), transparent 70%), radial-gradient(600px 260px at 90% 100%, rgb(var(--brand-rgb) / .22), transparent 70%); }
.stat:nth-child(1) .stat-n { color: #fff; }
.stat:nth-child(2) .stat-n { color: #ffd0a8; }
.stat:nth-child(3) .stat-n { color: #cfe6ff; }
.stat:nth-child(4) .stat-n { color: #ffe08a; }
.stat-l { color: rgba(255, 255, 255, .78); }
.cta-band p { color: rgba(255, 255, 255, .85); }
.how-num, .vt-icon, .vb-topic-icon { color: var(--brand-2); }
.how-num { background: rgb(var(--violet-rgb) / .1); }
.vb-topic-icon { background: rgb(var(--violet-rgb) / .1); }
.credit b { background: none; -webkit-text-fill-color: currentColor; color: var(--brand); font-family: var(--display); font-weight: 900; }
.hero-logo { height: auto; object-fit: contain; }
.hero-title .hl { background: linear-gradient(transparent 70%, rgb(var(--brand-rgb) / .9) 70%, rgb(var(--brand-rgb) / .9) 88%, transparent 88%); }
.hero-title { font-size: clamp(38px, 5.6vw, 72px); }
/* Words drift on the right, around the logo, never under the headline. */
@media (min-width: 980px) { .hero-graph { -webkit-mask-image: linear-gradient(90deg, transparent 0 42%, #000 62%); mask-image: linear-gradient(90deg, transparent 0 42%, #000 62%); } }
@media (max-width: 979px) { .hero-graph { opacity: .45; } }
@media (max-width: 700px) { .hero-graph { display: none; } }
@media (max-width: 520px) {
  .site-nav .brand-name { display: none; }
  .site-nav .ui-seg button { padding: 4px 6px; font-size: 11px; }
  .site-nav .theme-toggle { width: 32px; height: 32px; }
}
.sp-bubbles { position: absolute; inset: 0; pointer-events: none; }

/* "I speak" and "I want to learn", one row of flags each */
.lang-pick { display: grid; gap: 12px; }
.seg-opt.off { opacity: .35; cursor: not-allowed; }
.lobby-langs { display: grid; gap: 8px; }
.lobby-langs .row > .muted { min-width: 84px; }

/* home form: what I learn is the main choice; my own language is secondary */
.field-small { font-size: 12px; }
.field-small .learn-seg .seg-opt { padding: 6px 4px; font-size: 11.5px; }
.field-small .learn-seg .seg-opt .flag { width: 18px; height: 12px; }
.field-main { font-size: 14px; color: var(--ink); font-weight: 800; }
/* lobby: learn first, then play */
.lobby-h { font-size: 20px; display: flex; gap: 8px; align-items: center; margin-top: 6px; }
.lobby-h .i { width: 20px; height: 20px; color: var(--brand-2); }
.learn-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 12px; }
.learn-card { display: grid; grid-template-columns: auto 1fr auto; gap: 14px; align-items: center; text-align: left; padding: 18px; border-radius: var(--radius);
  background: linear-gradient(135deg, rgb(var(--violet-rgb) / .12), rgb(var(--brand-rgb) / .08)); border: 1px solid rgb(var(--violet-rgb) / .3); color: var(--ink); cursor: pointer;
  transition: transform .2s, box-shadow .2s, border-color .2s; }
.learn-card:hover { transform: translateY(-2px); border-color: rgb(var(--violet-rgb) / .6); box-shadow: var(--shadow); }
.learn-card b { display: block; font-family: var(--display); font-size: 18px; font-weight: 900; }
.learn-card .muted { font-size: 13.5px; }
.learn-card > .i { width: 20px; height: 20px; color: var(--brand); }
.learn-icon { width: 48px; height: 48px; border-radius: 14px; display: grid; place-items: center; background: var(--brand-2); color: #fff; }
.learn-icon .i { width: 24px; height: 24px; }
.lobby-lang-label { min-width: 130px; font-weight: 700; }
.small-row .learn-seg .seg-opt { padding: 4px 8px; font-size: 12px; }

/* ---------- how to play ---------- */
.card-wrap { position: relative; display: grid; }
.card-wrap > .mode-card, .card-wrap > .learn-card { height: 100%; }
.card-wrap > .mode-card { padding-bottom: 54px; }
.how-btn { position: absolute; right: 12px; bottom: 12px; display: inline-flex; align-items: center; gap: 5px; padding: 6px 10px; border-radius: 999px;
  font: 700 12.5px/1 var(--font); color: var(--brand-2); background: rgb(var(--violet-rgb) / .1); border: 1px solid rgb(var(--violet-rgb) / .3); cursor: pointer; transition: background .2s, transform .2s; }
.how-btn:hover { background: rgb(var(--violet-rgb) / .2); transform: translateY(-1px); }
.how-btn .i { width: 14px; height: 14px; }
.card-wrap > .learn-card { padding-bottom: 50px; }
.tut-modal { width: min(620px, calc(100vw - 32px)); }
.tut-icon { display: inline-grid; place-items: center; width: 36px; height: 36px; border-radius: 10px; background: var(--brand-2); color: #fff; vertical-align: -8px; margin-right: 4px; }
.tut-icon .i { width: 20px; height: 20px; }
.tut-meta { gap: 8px; }
.tut-score { background: rgb(var(--brand-rgb) / .1); color: var(--brand); border-color: rgb(var(--brand-rgb) / .3); }
.tut-steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.tut-steps li { display: grid; grid-template-columns: 28px 36px 1fr; gap: 10px; align-items: center; padding: 12px; border-radius: 14px; background: var(--well-soft); border: 1px solid var(--line);
  line-height: 1.45; animation: tut-in .45s cubic-bezier(.2,.7,.2,1) calc(var(--i) * 70ms) both; }
.tut-num { width: 26px; height: 26px; border-radius: 50%; display: grid; place-items: center; background: var(--brand); color: #fff; font: 900 13px/1 var(--display); }
.tut-step-icon { width: 36px; height: 36px; border-radius: 10px; display: grid; place-items: center; background: rgb(var(--violet-rgb) / .1); color: var(--brand-2); }
.tut-step-icon .i { width: 18px; height: 18px; }
@keyframes tut-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .tut-steps li { animation: none; } }

/* the AI steps lead the "how it works" section */
.how-step.ai-step .how-num { background: rgb(var(--brand-rgb) / .12); color: var(--brand); }

/* ---------- someone is in the call ---------- */
#call-invite { position: fixed; top: 76px; left: 50%; transform: translateX(-50%); z-index: 60; display: flex; align-items: center; gap: 12px;
  padding: 12px 14px; border-radius: 18px; background: var(--panel-glass); border: 1px solid rgb(16 185 129 / .5); box-shadow: 0 20px 50px -20px rgb(0 0 0 / .5), 0 0 0 4px rgb(16 185 129 / .12);
  max-width: calc(100vw - 24px); animation: ci-in .45s cubic-bezier(.34,1.56,.64,1) both; backdrop-filter: blur(10px); }
.ci-ring { width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; background: var(--ok); color: #fff; flex: none; animation: ci-ring 1.6s ease-in-out infinite; }
.ci-ring .i { width: 20px; height: 20px; }
.ci-text { display: grid; gap: 2px; min-width: 0; }
.ci-text b { font-family: var(--display); font-size: 16px; }
.ci-text .muted { font-size: 12.5px; }
@keyframes ci-in { from { opacity: 0; transform: translate(-50%, -16px) scale(.96); } to { opacity: 1; transform: translate(-50%, 0); } }
@keyframes ci-ring { 0%, 100% { box-shadow: 0 0 0 0 rgb(16 185 129 / .55); transform: rotate(0); } 10% { transform: rotate(-12deg); } 20% { transform: rotate(12deg); } 30% { transform: rotate(0); } 60% { box-shadow: 0 0 0 12px rgb(16 185 129 / 0); } }
@media (max-width: 600px) { #call-invite { flex-wrap: wrap; top: 64px; width: calc(100vw - 24px); } .ci-text { flex: 1; } }
.btn.pulse { animation: btn-pulse 1.4s ease-in-out infinite; }
@keyframes btn-pulse { 0%, 100% { box-shadow: 0 0 0 0 rgb(var(--brand-rgb) / .6); } 50% { box-shadow: 0 0 0 8px rgb(var(--brand-rgb) / 0); } }
/* ---------- microphone help ---------- */
#mic-hint { position: fixed; top: 12px; left: 16px; z-index: 70; display: flex; gap: 8px; align-items: center; max-width: 360px; padding: 12px 14px; border-radius: 14px;
  background: var(--brand-2); color: #fff; font-weight: 700; box-shadow: 0 16px 40px -16px rgb(0 0 0 / .5); animation: ci-in-l .35s ease both; }
#mic-hint .i { width: 18px; height: 18px; flex: none; }
#mic-hint .i:first-child { animation: hint-bob 1s ease-in-out infinite; }
@keyframes ci-in-l { from { opacity: 0; transform: translateY(-10px); } to { opacity: 1; transform: none; } }
@keyframes hint-bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-4px); } }
.mic-icon { background: var(--bad); }
.mic-os { font-size: 13px; line-height: 1.5; padding: 10px 12px; border-radius: 12px; background: var(--well-soft); border: 1px dashed var(--line-hi); }
.mic-actions { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.mic-listen-help { font-size: 12.5px; flex-basis: 100%; }
@media (prefers-reduced-motion: reduce) { #call-invite, .ci-ring, .btn.pulse, #mic-hint, #mic-hint .i { animation: none !important; } }

/* ---------- microphone check on entering a room ---------- */
.gate-modal { width: min(460px, calc(100vw - 32px)); text-align: center; justify-items: center; padding: 30px 26px 22px; }
.gate-modal h2 { font-size: 24px; }
.gate-modal p { margin: 0; line-height: 1.55; }
.gate-modal .btn.big { width: 100%; }
.gate-mic { width: 84px; height: 84px; border-radius: 50%; display: grid; place-items: center; background: var(--brand); color: #fff;
  box-shadow: 0 0 0 10px rgb(var(--brand-rgb) / .15), 0 0 0 22px rgb(var(--brand-rgb) / .07); animation: gate-pulse 1.8s ease-in-out infinite; }
.gate-mic .i { width: 38px; height: 38px; }
.gate-later { font-size: 12.5px; }
@keyframes gate-pulse { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.06); } }
@media (prefers-reduced-motion: reduce) { .gate-mic { animation: none; } }
.gate-mic { background: var(--ok); box-shadow: 0 0 0 10px rgb(16 185 129 / .15), 0 0 0 22px rgb(16 185 129 / .07); }
.gate-here { background: rgb(16 185 129 / .12); color: var(--ok); border-color: rgb(16 185 129 / .3); }

/* what my captions are doing */
.stt-pill { font-size: 12px; }
.stt-listening { background: rgb(16 185 129 / .12); color: var(--ok); border-color: rgb(16 185 129 / .35); }
.stt-listening .i { animation: stt-live 1.4s ease-in-out infinite; }
.stt-paused, .stt-listenOnly { background: rgb(var(--violet-rgb) / .12); color: var(--brand-2); }
.stt-muted, .stt-blocked, .stt-audio { background: rgb(244 63 94 / .12); color: var(--bad); border-color: rgb(244 63 94 / .35); }
.stt-network { background: rgb(245 158 11 / .12); color: var(--warn); }
@keyframes stt-live { 0%, 100% { opacity: 1; } 50% { opacity: .35; } }
@media (prefers-reduced-motion: reduce) { .stt-listening .i { animation: none; } }

/* ---------- my call: mini panel, big sheet, floating window ---------- */
.call-mini { position: fixed; top: 70px; right: 16px; z-index: 55; animation: ci-in-l .35s ease both; }
.cm { display: grid; gap: 10px; padding: 12px; border-radius: 18px; background: var(--panel-glass); border: 1px solid rgb(16 185 129 / .45);
  box-shadow: 0 20px 50px -24px rgb(0 0 0 / .6); backdrop-filter: blur(10px); min-width: 220px; }
.cm-head { display: flex; align-items: center; gap: 8px; font-size: 14px; }
.cm-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--ok); box-shadow: 0 0 0 0 rgb(16 185 129 / .6); animation: cm-dot 1.6s ease-in-out infinite; }
.cm-time { font-variant-numeric: tabular-nums; font-size: 12.5px; margin-left: auto; }
.cm-people { display: flex; gap: 6px; flex-wrap: wrap; }
.cm-avatar { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; color: #fff; font: 900 14px/1 var(--display); box-shadow: 0 0 0 2px var(--panel-solid); transition: box-shadow .2s; }
.cm-avatar.talking { box-shadow: 0 0 0 2px var(--panel-solid), 0 0 0 5px var(--ok); }
.cm-actions { display: flex; gap: 6px; justify-content: flex-end; }
.cm .stt-pill { justify-self: start; }
.cm-lines { display: grid; gap: 6px; max-height: 190px; overflow: auto; font-size: 13px; }
.cm-lines .call-line-main { font-size: 14px; }
.cm-pip { border-radius: 0; min-height: 100vh; border: 0; }
@keyframes cm-dot { 0%, 100% { box-shadow: 0 0 0 0 rgb(16 185 129 / .6); } 60% { box-shadow: 0 0 0 7px rgb(16 185 129 / 0); } }
.call-sheet-backdrop { position: fixed; inset: 0; background: rgb(5 12 24 / .5); backdrop-filter: blur(4px); z-index: 56; animation: fade .2s; }
.call-sheet { position: fixed; z-index: 57; inset: 64px max(16px, calc((100vw - 1000px) / 2)) 16px; overflow: auto; display: grid; gap: 14px; align-content: start;
  padding: 18px; border-radius: 24px; background: var(--bg); border: 1px solid var(--line-hi); box-shadow: 0 40px 80px -30px rgb(0 0 0 / .7); animation: sheet-in .35s cubic-bezier(.2,.7,.2,1) both; }
.call-sheet-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.call-sheet-head h2 { font-size: 22px; }
@keyframes sheet-in { from { opacity: 0; transform: translateY(24px) scale(.98); } to { opacity: 1; transform: none; } }
@media (max-width: 600px) { .call-mini { top: auto; bottom: 90px; right: 12px; left: 12px; } .call-sheet { inset: 56px 8px 8px; padding: 12px; } }
@media (prefers-reduced-motion: reduce) { .cm-dot, .call-sheet, .call-mini { animation: none; } }
/* the mini call sits in the empty right side of the top bar, as one compact row */
@media (min-width: 901px) {
  .call-mini { top: 9px; right: 16px; }
  .call-mini .cm { display: flex; align-items: center; gap: 10px; padding: 5px 6px 5px 12px; border-radius: 999px; min-width: 0; }
  .call-mini .cm-head { gap: 6px; font-size: 13px; }
  .call-mini .cm-time { margin-left: 2px; }
  .call-mini .cm-avatar { width: 26px; height: 26px; font-size: 12px; }
  .call-mini .cm-people { flex-wrap: nowrap; }
  .call-mini .stt-pill { display: none; }
  .call-mini .cm-actions .btn { width: 30px; height: 30px; padding: 5px; border-radius: 50%; }
}

/* the call bar is one horizontal row everywhere; on phones it sits above the captions */
.call-mini .cm { display: flex; align-items: center; gap: 10px; padding: 5px 6px 5px 12px; border-radius: 999px; min-width: 0; }
.call-mini .cm-head { gap: 6px; font-size: 13px; white-space: nowrap; }
.call-mini .cm-time { margin-left: 2px; }
.call-mini .cm-avatar { width: 26px; height: 26px; font-size: 12px; }
.call-mini .cm-people { flex-wrap: nowrap; }
.call-mini .cm-actions .btn { width: 30px; height: 30px; padding: 5px; border-radius: 50%; }
@media (max-width: 900px) { .call-mini { top: auto; bottom: 12px; left: 50%; right: auto; transform: translateX(-50%); } body.with-live-bar .call-mini { bottom: 150px; } }
.mode-bar .cm-dot { display: inline-block; vertical-align: 1px; }
