/* ═══════════════════════════════════════════════════════
   Jordan AcaDec design system
   Jordan black and gold · warm study workspace
   ═══════════════════════════════════════════════════════ */
:root {
  --bg: #f3f0e8;
  --surface: #fffdf8;
  --surface-2: #f8f5ed;
  --ink: #211d16;
  --muted: #665c4b;
  --line: #e7deca;
  --primary: #76571b;
  --primary-ink: #fffdf8;
  --gold: #d6b772;
  --gold-ink: #20170a;
  --primary-tint: #f1e6cd;
  --accent: #b88c39;
  --accent-tint: #f3e5c8;
  --good: #1b8f5a;
  --good-tint: #e2f5eb;
  --bad: #d14343;
  --bad-tint: #fbe7e7;
  --warn: #b7791f;
  --warn-tint: #fdf1dc;
  --shadow: 0 1px 2px rgba(43, 30, 12, .04), 0 4px 14px rgba(43, 30, 12, .05);
  --shadow-lg: 0 10px 40px rgba(43, 30, 12, .14);
  --radius: 16px;
  --radius-sm: 10px;
  --font: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --display: "Nunito", "Inter", system-ui, sans-serif;
  --sb-w: 236px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #15130f; --surface: #211e17; --surface-2: #191711; --ink: #fbf3e3; --muted: #c3b69b; --line: #393122;
    --primary: #d9ba77; --primary-ink: #16130d; --primary-tint: #362a15; --accent: #dbb966; --accent-tint: #372b17;
    --good: #4fc38a; --good-tint: #14291f; --bad: #f07b7b; --bad-tint: #321a1c; --warn: #e5b04f; --warn-tint: #31260f;
    --shadow: 0 1px 2px rgba(0,0,0,.3), 0 4px 14px rgba(0,0,0,.2); --shadow-lg: 0 10px 40px rgba(0,0,0,.5);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #15130f; --surface: #211e17; --surface-2: #191711; --ink: #fbf3e3; --muted: #c3b69b; --line: #393122;
  --primary: #d9ba77; --primary-ink: #16130d; --primary-tint: #362a15; --accent: #dbb966; --accent-tint: #372b17;
  --good: #4fc38a; --good-tint: #14291f; --bad: #f07b7b; --bad-tint: #321a1c; --warn: #e5b04f; --warn-tint: #31260f;
  --shadow: 0 1px 2px rgba(0,0,0,.3), 0 4px 14px rgba(0,0,0,.2); --shadow-lg: 0 10px 40px rgba(0,0,0,.5);
  color-scheme: dark;
}

/* ── Base ───────────────────────────────────────────── */
* { box-sizing: border-box; }
html, body { margin: 0; }
body { background: var(--bg); color: var(--ink); font: 16px/1.5 var(--font); -webkit-font-smoothing: antialiased; }
a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3 { font-family: var(--display); font-weight: 800; margin: 0; line-height: 1.2; letter-spacing: -0.01em; }
h1 { font: 800 clamp(2rem, 4vw, 2.8rem)/1.02 "Barlow Condensed", var(--display); letter-spacing: -.015em; }
h2 { font-size: 18px; }
h3 { font-size: 15px; }
p { margin: 0; }
button, select, input, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 2.5px solid var(--primary); outline-offset: 2px; border-radius: 6px; }
.i { flex-shrink: 0; vertical-align: middle; }
.num, .timer, .big-num, .score-big, .ring-label b { font-variant-numeric: tabular-nums; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ── Shell ──────────────────────────────────────────── */
.shell { display: grid; grid-template-columns: var(--sb-w) 1fr; min-height: 100vh; transition: grid-template-columns .2s ease; }
body.sb-collapsed { --sb-w: 76px; }
.sidebar {
  position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column; gap: 6px;
  --surface: #1d1a14;
  --surface-2: #282218;
  --ink: #fcf3dd;
  --muted: #c7b99b;
  --line: #423725;
  --primary: #e6ca89;
  --primary-tint: #3a2e18;
  background: #17150f; color: var(--ink); color-scheme: dark;
  border-right: 1px solid var(--line); padding: 16px 12px; z-index: 20;
}
.sb-top { display: flex; align-items: center; justify-content: space-between; gap: 6px; padding: 2px 4px 10px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--ink); min-width: 0; }
.brand:hover { text-decoration: none; }
.brand-mark {
  width: 39px; height: 43px; border-radius: 9px; display: grid; place-items: center; flex-shrink: 0;
  background: #f5e8c8; overflow: hidden;
}
.brand-mark img { width: 36px; height: 36px; object-fit: contain; mix-blend-mode: multiply; }
.brand-name { font: 800 18px/1 "Barlow Condensed", var(--display); white-space: nowrap; }
.brand-name small { display: block; margin-top: 4px; font: 600 9px var(--font); color: var(--gold); letter-spacing: .045em; text-transform: uppercase; }
.sb-collapse { color: var(--muted); }
body.sb-collapsed .sb-collapse svg { transform: rotate(180deg); }
.nav { display: flex; flex-direction: column; gap: 2px; flex: 1; overflow-y: auto; overflow-x: hidden; margin: 0 -4px; padding: 0 4px; }
.nav a { display: flex; align-items: center; gap: 11px; padding: 8px 10px; border-radius: 10px; color: var(--muted); font-weight: 600; font-size: 14px; white-space: nowrap; position: relative; }
.nav a:hover { background: var(--surface-2); color: var(--ink); text-decoration: none; }
.nav a.active { background: var(--primary-tint); color: var(--primary); }
.nav a.active::before { content: ""; position: absolute; left: -4px; top: 8px; bottom: 8px; width: 3px; border-radius: 3px; background: var(--primary); }
.nav-count { margin-left: auto; font-size: 11px; font-weight: 700; border-radius: 99px; padding: 1px 7px; background: var(--bad); color: #fff; }
.nav-count.accent { background: var(--accent); color: #241703; }
.nav-count:empty { display: none; }
.sidebar-foot { border-top: 1px solid var(--line); padding-top: 10px; display: flex; flex-direction: column; gap: 8px; }
.season-pick { display: flex; flex-direction: column; gap: 4px; font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); padding: 0 4px; }
.season-pick select { text-transform: none; letter-spacing: 0; font-size: 13px; font-weight: 600; }
.profile { display: flex; align-items: center; gap: 10px; width: 100%; background: none; border: 0; padding: 6px; border-radius: 10px; cursor: pointer; text-align: left; }
.profile:hover { background: var(--surface-2); }
.avatar { width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center; background: var(--accent-tint); color: var(--warn); font: 800 14px var(--display); flex-shrink: 0; }
.profile-text { display: flex; flex-direction: column; min-width: 0; font-weight: 600; font-size: 14px; white-space: nowrap; }
.profile-text small { color: var(--muted); font-weight: 500; font-size: 12px; }
body.sb-collapsed .brand-name, body.sb-collapsed .nav-text, body.sb-collapsed .profile-text,
body.sb-collapsed .season-pick { display: none; }
body.sb-collapsed .nav a { justify-content: center; padding: 10px; }
body.sb-collapsed .nav-count { position: absolute; top: 2px; right: 2px; padding: 0 5px; }
body.sb-collapsed .sb-top { flex-direction: column; }
body.sb-collapsed .profile { justify-content: center; }

.main { min-width: 0; display: flex; flex-direction: column; }
.topbar { display: flex; align-items: center; gap: 14px; padding: 12px 28px; background: color-mix(in srgb, var(--bg) 88%, transparent); backdrop-filter: blur(8px); position: sticky; top: 0; z-index: 15; border-bottom: 1px solid var(--line); }
.topbar .menu-btn { display: none; }
.crumbs { flex: 1; color: var(--muted); font-size: 14px; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.crumbs a { color: var(--muted); }
.crumbs b { color: var(--ink); font-weight: 700; }
.search { position: relative; width: min(380px, 42vw); }
.search > .i { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--muted); pointer-events: none; }
.search input { width: 100%; background: var(--surface); border: 1px solid var(--line); border-radius: 99px; padding: 8px 40px 8px 36px; font-size: 14px; }
.search kbd { position: absolute; right: 10px; top: 50%; transform: translateY(-50%); font: 600 11px var(--font); color: var(--muted); border: 1px solid var(--line); border-radius: 6px; padding: 0 6px; background: var(--surface-2); }
.search-results { position: absolute; top: calc(100% + 6px); left: 0; right: 0; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow-lg); padding: 6px; display: none; max-height: 60vh; overflow-y: auto; z-index: 30; }
.search-results.on { display: block; }
.sr-item { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 9px; color: var(--ink); cursor: pointer; width: 100%; border: 0; background: none; text-align: left; font-size: 14px; }
.sr-item:hover, .sr-item.hi { background: var(--surface-2); text-decoration: none; }
.sr-item .t { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sr-type { font-size: 11px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; flex-shrink: 0; }
.sr-empty { padding: 12px; color: var(--muted); font-size: 14px; text-align: center; }
.select, .input, textarea.input { background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 8px 11px; color: var(--ink); }
.input { width: 100%; }
#view { padding: 26px 28px 40px; max-width: 1280px; width: 100%; outline: none; }
.scrim { display: none; }
.bottombar { display: none; }

/* ── Building blocks ────────────────────────────────── */
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 20px; flex-wrap: wrap; }
.page-head p { color: var(--muted); margin-top: 4px; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 20px; min-width: 0; }
.card-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 14px; }
.card-head h2, .card-head h3 { display: flex; align-items: center; gap: 8px; min-width: 0; }
.card-head .sub { color: var(--muted); font-size: 13px; }
.grid { display: grid; gap: 18px; }
.home-grid { grid-template-columns: minmax(0, 2fr) minmax(300px, 1fr); align-items: start; }
.stack { display: flex; flex-direction: column; gap: 18px; min-width: 0; }
.row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.between { justify-content: space-between; }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.empty { color: var(--muted); text-align: center; padding: 22px 14px; border: 1.5px dashed var(--line); border-radius: 12px; font-size: 14px; background: var(--surface-2); }
.empty .i { display: block; margin: 0 auto 8px; color: var(--muted); opacity: .7; }
.empty b { display: block; color: var(--ink); margin-bottom: 2px; }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 7px; border: 1px solid var(--line); background: var(--surface); color: var(--ink);
  padding: 9px 15px; border-radius: 11px; font-weight: 700; font-size: 14px; cursor: pointer; white-space: nowrap; transition: background-color .15s, border-color .15s, filter .15s; min-height: 38px; }
.btn:hover { background: var(--surface-2); text-decoration: none; border-color: color-mix(in srgb, var(--line) 50%, var(--muted)); }
.btn.primary { background: var(--gold); border-color: var(--gold); color: var(--gold-ink); }
.btn.primary:hover { filter: brightness(1.07); }
.btn.ghost { border-color: transparent; background: transparent; color: var(--muted); }
.btn.ghost:hover { color: var(--ink); background: var(--surface-2); }
.btn.sm { padding: 6px 11px; font-size: 13px; min-height: 32px; border-radius: 9px; }
.btn.lg { padding: 12px 20px; font-size: 15px; min-height: 46px; }
.btn.dashed { border-style: dashed; color: var(--muted); }
.btn.on { background: var(--primary-tint); border-color: var(--primary); color: var(--primary); }
.btn[disabled], .btn.disabled { opacity: .45; cursor: not-allowed; filter: none; pointer-events: none; }
.icon-btn { background: none; border: 0; color: var(--muted); cursor: pointer; padding: 6px; border-radius: 8px; display: inline-grid; place-items: center; }
.icon-btn:hover { background: var(--surface-2); color: var(--ink); }

.chip { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 600; padding: 2px 9px; border-radius: 99px; background: var(--surface-2); color: var(--muted); border: 1px solid var(--line); white-space: nowrap; }
.chip .dot { width: 8px; height: 8px; border-radius: 50%; }
.chip.easy, .chip.good { background: var(--good-tint); color: var(--good); border-color: transparent; }
.chip.medium, .chip.warn { background: var(--warn-tint); color: var(--warn); border-color: transparent; }
.chip.hard, .chip.bad { background: var(--bad-tint); color: var(--bad); border-color: transparent; }
.chip.blue { background: var(--primary-tint); color: var(--primary); border-color: transparent; }

.pill { display: inline-flex; align-items: center; gap: 6px; padding: 6px 13px; border-radius: 99px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); font-weight: 600; font-size: 13px; cursor: pointer; white-space: nowrap; }
.pill:hover { border-color: var(--primary); text-decoration: none; }
.pill.on { background: var(--primary); border-color: var(--primary); color: var(--primary-ink); }
.pill .dot { width: 8px; height: 8px; border-radius: 50%; }
.pills { display: flex; gap: 8px; flex-wrap: wrap; }
.tabs-row { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 4px; margin-bottom: 18px; scrollbar-width: thin; }

.bar { height: 8px; background: var(--surface-2); border: 1px solid var(--line); border-radius: 99px; overflow: hidden; }
.bar > i { display: block; height: 100%; background: var(--primary); border-radius: 99px; }
.meter { display: grid; grid-template-columns: 74px minmax(0, 1fr) auto; align-items: center; gap: 10px; font-size: 12px; color: var(--muted); }
.meter b { color: var(--ink); font-weight: 700; font-variant-numeric: tabular-nums; }

/* ── Home ───────────────────────────────────────────── */
.home-top { display: grid; grid-template-columns: minmax(0, 1.7fr) minmax(0, 1fr) minmax(0, 1fr); gap: 18px; margin-bottom: 18px; }
.dashboard-head .dashboard-kicker { color: var(--primary); font-size: .75rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; margin: 0 0 .45rem; }
.resume { position: relative; isolation: isolate; overflow: hidden; display: flex; align-items: stretch; padding: 24px;
  background: radial-gradient(ellipse at 100% 0%, #45361d, #19160f 58%); color: #fff7e6; border: 1px solid #5d4829; }
.resume-body { display: flex; flex-direction: column; justify-content: space-between; gap: 12px; position: relative; z-index: 1; }
.resume h2 { font-family: "Barlow Condensed", var(--display); font-size: 30px; }
.resume p { color: #e1d4bb; font-size: 14px; }
.resume .eyebrow { font-size: 12px; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--gold); }
.resume .btn { background: var(--gold); color: var(--gold-ink); border-color: var(--gold); }
.resume .btn:hover { filter: brightness(1.1); }
.resume .btn.ghost-light { background: #302616; color: #f9e5b3; border-color: #7d6436; }
.resume-art { position: absolute; right: -19px; bottom: -32px; width: 153px; height: auto; opacity: .27; transform: rotate(-8deg); pointer-events: none; }
.goal { display: flex; align-items: center; gap: 16px; }
.ring { position: relative; width: 88px; height: 88px; flex-shrink: 0; }
.ring svg { transform: rotate(-90deg); }
.ring .ring-label { position: absolute; inset: 0; display: grid; place-content: center; text-align: center; }
.ring .ring-label b { font: 900 24px var(--display); line-height: 1; }
.ring .ring-label small { color: var(--muted); font-size: 12px; }
.big-num { font: 900 34px/1.1 var(--display); }
.list { display: flex; flex-direction: column; gap: 8px; }
.list-item { display: flex; align-items: center; gap: 12px; padding: 11px 13px; border-radius: 12px; background: var(--surface-2); border: 1px solid var(--line); min-width: 0; color: var(--ink); }
a.list-item:hover { text-decoration: none; border-color: var(--primary); }
.list-item .grow { flex: 1; min-width: 0; }
.list-item .title { font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.list-item .meta { color: var(--muted); font-size: 13px; }
.swatch { width: 6px; align-self: stretch; border-radius: 99px; flex-shrink: 0; }
.subj-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 12px; }
.subj { display: flex; flex-direction: column; gap: 8px; padding: 14px; border-radius: 13px; border: 1px solid var(--line); background: var(--surface-2); color: var(--ink); }
a.subj:hover { border-color: var(--primary); text-decoration: none; }
.subj-name { display: flex; align-items: center; gap: 8px; font: 800 15px var(--display); }
.subj-name .dot { width: 10px; height: 10px; border-radius: 50%; }
.subj .muted { font-size: 12.5px; }

.week { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 8px; }
.day { background: var(--surface-2); border: 1px solid var(--line); border-radius: 12px; padding: 10px; min-height: 140px; display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.day.today { border-color: var(--primary); box-shadow: inset 0 3px 0 var(--primary); }
.day-name { font-size: 12px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.task { display: flex; align-items: flex-start; gap: 6px; font-size: 13px; line-height: 1.35; word-break: break-word; }
.task input { margin-top: 2px; accent-color: var(--primary); }
.task.done span { text-decoration: line-through; color: var(--muted); }
.task .icon-btn { margin-left: auto; padding: 0 3px; opacity: 0; }
.task:hover .icon-btn, .task .icon-btn:focus-visible { opacity: 1; }
.day form { margin-top: auto; }
.day .input { padding: 5px 7px; font-size: 12px; border-radius: 8px; }

/* ── Subjects ───────────────────────────────────────── */
.event-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 16px; }
.event-card { display: flex; flex-direction: column; gap: 12px; color: var(--ink); position: relative; overflow: hidden; }
a.event-card:hover { text-decoration: none; border-color: var(--primary); }
.event-card::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 4px; background: var(--c); }
.event-card .kind { font-size: 12px; color: var(--muted); font-weight: 700; text-transform: uppercase; letter-spacing: .08em; }
.event-card .nums { display: flex; justify-content: space-between; font-size: 13px; color: var(--muted); }
.event-card > .btn:last-child { margin-top: auto; }
.sec-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 14px; }
.sec-card { display: flex; flex-direction: column; gap: 12px; }
.sec-card h3 { font-size: 16px; }
.sec-card .btn { margin-top: auto; align-self: flex-start; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; margin: 6px 0 12px; }

/* ── Question bank ──────────────────────────────────── */
.fgroup { display: grid; grid-template-columns: 110px minmax(0, 1fr); gap: 10px; align-items: start; padding: 12px 0; border-top: 1px solid var(--line); }
.fgroup:first-of-type { border-top: 0; padding-top: 0; }
.fgroup > span { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .07em; color: var(--muted); padding-top: 7px; }
.qb-foot { display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; margin-top: 8px; padding: 14px 16px; border-radius: 12px; background: var(--surface-2); border: 1px solid var(--line); }
.qb-foot .big { font: 900 22px var(--display); font-variant-numeric: tabular-nums; }
.note { display: flex; gap: 8px; align-items: flex-start; font-size: 13px; color: var(--warn); background: var(--warn-tint); padding: 8px 11px; border-radius: 10px; margin-top: 10px; }

/* ── Practice player ────────────────────────────────── */
.player { display: grid; grid-template-columns: minmax(0, 1fr) 250px; gap: 18px; align-items: start; }
.pl-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px 16px; margin-bottom: 14px; flex-wrap: wrap; }
.pl-head .where { display: flex; align-items: center; gap: 10px; min-width: 0; flex-wrap: wrap; font-size: 14px; }
.pl-head .where b { font-variant-numeric: tabular-nums; }
.saved { font-size: 12px; color: var(--good); display: inline-flex; align-items: center; gap: 4px; font-weight: 600; }
.timer { font: 700 14px var(--font); background: var(--surface-2); border: 1px solid var(--line); padding: 6px 11px; border-radius: 9px; display: inline-flex; align-items: center; gap: 6px; }
.q-prompt { font-size: 18.5px; line-height: 1.55; margin: 6px 0 18px; font-weight: 500; }
.choices { display: flex; flex-direction: column; gap: 10px; }
.choice { display: flex; align-items: center; gap: 8px; }
.choice-btn { flex: 1; display: flex; align-items: center; gap: 12px; text-align: left; padding: 14px 15px; border-radius: 13px; border: 1.5px solid var(--line); background: var(--surface); cursor: pointer; min-height: 54px; font-size: 15px; }
.choice-btn:hover:not([disabled]) { border-color: var(--primary); }
.choice-btn .letter { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; border: 1.5px solid var(--line); font-weight: 800; font-size: 13px; flex-shrink: 0; }
.choice-btn .mark { margin-left: auto; display: inline-flex; align-items: center; gap: 4px; font-size: 12px; font-weight: 700; }
.choice-btn.selected { border-color: var(--primary); background: var(--primary-tint); }
.choice-btn.selected .letter { background: var(--primary); color: var(--primary-ink); border-color: var(--primary); }
.choice-btn.correct { border-color: var(--good); background: var(--good-tint); }
.choice-btn.correct .letter { background: var(--good); color: #fff; border-color: var(--good); }
.choice-btn.correct .mark { color: var(--good); }
.choice-btn.wrong { border-color: var(--bad); background: var(--bad-tint); }
.choice-btn.wrong .letter { background: var(--bad); color: #fff; border-color: var(--bad); }
.choice-btn.wrong .mark { color: var(--bad); }
.choice-btn.struck .text { text-decoration: line-through; color: var(--muted); }
.choice-btn[disabled] { cursor: default; }
.feedback { margin-top: 18px; padding: 14px 16px; border-radius: 12px; background: var(--good-tint); }
.feedback b { color: var(--good); }
.player-actions { display: flex; justify-content: space-between; gap: 10px; margin-top: 22px; flex-wrap: wrap; }
.navigator { display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px; }
.nav-q { aspect-ratio: 1; border-radius: 9px; border: 1px solid var(--line); background: var(--surface-2); cursor: pointer; font-weight: 700; font-size: 13px; position: relative; font-variant-numeric: tabular-nums; }
.nav-q.answered { background: var(--primary-tint); border-color: var(--primary); color: var(--primary); }
.nav-q.is-correct { background: var(--good-tint); border-color: var(--good); color: var(--good); }
.nav-q.is-wrong { background: var(--bad-tint); border-color: var(--bad); color: var(--bad); }
.nav-q.current { outline: 2px solid var(--ink); outline-offset: 1px; }
.nav-q.flag::after { content: ""; position: absolute; top: 3px; right: 3px; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); }
.legend { display: flex; flex-direction: column; gap: 5px; font-size: 12px; color: var(--muted); margin-top: 14px; }
.legend span { display: flex; align-items: center; gap: 6px; }
.score-big { font: 900 54px var(--display); line-height: 1; }

/* ── Guide evidence ─────────────────────────────────── */
.evidence { margin-top: 18px; display: flex; flex-direction: column; gap: 12px; }
.ev-answers { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.ev-ans { display: flex; gap: 8px; align-items: flex-start; padding: 10px 12px; border-radius: 11px; font-size: 14px; }
.ev-ans.bad { background: var(--bad-tint); color: var(--bad); }
.ev-ans.good { background: var(--good-tint); color: var(--good); }
.ev-ans b { color: var(--ink); font-weight: 600; }
.ev-ans small { display: block; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; }
.ev-why { font-size: 14.5px; line-height: 1.6; }
.ev-why .why-not { display: block; margin-top: 6px; color: var(--muted); }
.ev-box { border: 1.5px solid var(--primary); background: var(--primary-tint); border-radius: 13px; padding: 13px 15px; display: flex; flex-direction: column; gap: 8px; }
.ev-title { display: flex; align-items: center; gap: 8px; font: 800 14px var(--display); color: var(--primary); text-transform: uppercase; letter-spacing: .05em; }
.ev-cite { display: flex; flex-direction: column; gap: 2px; font-size: 13.5px; }
.ev-cite + .ev-cite { border-top: 1px dashed color-mix(in srgb, var(--primary) 35%, transparent); padding-top: 8px; }
.ev-cite .unverified { color: var(--warn); font-weight: 600; display: inline-flex; align-items: center; gap: 4px; }
.ev-actions { display: flex; gap: 8px; flex-wrap: wrap; }

/* ── Review / tables ────────────────────────────────── */
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin-bottom: 16px; overflow-x: auto; }
.tab { background: none; border: 0; padding: 10px 14px; font-weight: 700; color: var(--muted); cursor: pointer; border-bottom: 2.5px solid transparent; margin-bottom: -1px; white-space: nowrap; }
.tab.active { color: var(--primary); border-color: var(--primary); }
.tab .count { font-size: 12px; background: var(--surface-2); border: 1px solid var(--line); border-radius: 99px; padding: 0 7px; margin-left: 5px; font-variant-numeric: tabular-nums; }
.filters { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 14px; align-items: center; }
.q-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 12px; padding: 14px 0; border-top: 1px solid var(--line); align-items: start; }
.q-row:first-child { border-top: 0; }
.q-row .excerpt { font-weight: 600; overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.q-row .tags { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 6px; }
.q-row .evidence { grid-column: 1 / -1; margin-top: 4px; }
.table { width: 100%; border-collapse: collapse; font-size: 14px; }
.table th { text-align: left; font-size: 12px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); font-weight: 700; padding: 8px 10px; border-bottom: 1px solid var(--line); }
.table td { padding: 10px; border-bottom: 1px solid var(--line); vertical-align: middle; font-variant-numeric: tabular-nums; }
.table-wrap { overflow-x: auto; }
.prog-row { display: grid; grid-template-columns: 150px minmax(0, 1fr) 70px 70px; gap: 14px; align-items: center; padding: 10px 0; border-top: 1px solid var(--line); font-size: 14px; font-variant-numeric: tabular-nums; }
.prog-row:first-of-type { border-top: 0; }
.heat { display: grid; grid-template-rows: repeat(7, 1fr); grid-auto-flow: column; grid-auto-columns: 1fr; gap: 3px; }
.heat i { aspect-ratio: 1; border-radius: 3px; background: var(--surface-2); border: 1px solid var(--line); }
.heat i.l1 { background: color-mix(in srgb, var(--primary) 25%, var(--surface)); border-color: transparent; }
.heat i.l2 { background: color-mix(in srgb, var(--primary) 50%, var(--surface)); border-color: transparent; }
.heat i.l3 { background: color-mix(in srgb, var(--primary) 75%, var(--surface)); border-color: transparent; }
.heat i.l4 { background: var(--primary); border-color: transparent; }
.heat-legend { display: flex; align-items: center; gap: 4px; font-size: 12px; color: var(--muted); justify-content: flex-end; margin-top: 8px; }
.heat-legend i { width: 11px; height: 11px; border-radius: 3px; display: inline-block; }

/* ── Mock meets ─────────────────────────────────────── */
.mock-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 16px; align-items: stretch; }
.mock-card { display: flex; flex-direction: column; gap: 14px; }
.mock-card > .row:last-child { margin-top: auto; }
.mock-meta { display: flex; gap: 14px; flex-wrap: wrap; font-size: 13px; color: var(--muted); font-weight: 600; font-variant-numeric: tabular-nums; }
.mock-meta span { display: inline-flex; align-items: center; gap: 5px; }
.mock-status { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; padding: 12px; border-radius: 12px; background: var(--surface-2); border: 1px solid var(--line); min-height: 76px; }
.mock-rules { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; font-size: 14px; }
.mock-rules li { display: flex; gap: 10px; align-items: flex-start; }
.mock-rules .i { color: var(--primary); margin-top: 3px; }
.submit-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.submit-stats > div { display: flex; flex-direction: column; align-items: center; padding: 12px 6px; border-radius: 12px; background: var(--surface-2); border: 1px solid var(--line); }
.submit-stats b { font: 900 26px var(--display); font-variant-numeric: tabular-nums; color: var(--ink); }
.submit-stats span { font-size: 12px; color: var(--muted); font-weight: 600; }
.submit-stats .bad { background: var(--bad-tint); border-color: transparent; } .submit-stats .bad b { color: var(--bad); }
.submit-stats .warn { background: var(--warn-tint); border-color: transparent; } .submit-stats .warn b { color: var(--warn); }
dialog .pill { padding: 3px 10px; margin: 2px 0; }
.timer.warn { color: var(--bad); border-color: var(--bad); background: var(--bad-tint); }

/* ── Listen ─────────────────────────────────────────── */
.ls-play { width: 46px; height: 46px; border-radius: 50%; border: 0; background: var(--primary); color: var(--primary-ink); display: grid; place-items: center; cursor: pointer; flex-shrink: 0; }
.ls-play:hover { filter: brightness(1.08); }
.ls-play.sm { width: 36px; height: 36px; }
.icon-btn small { font-size: 9px; font-weight: 800; margin-left: -4px; align-self: end; }
.ls-continue { display: flex; align-items: center; gap: 16px; margin-bottom: 18px; flex-wrap: wrap; }
.ls-continue .grow { flex: 1; min-width: 200px; }
.eyebrow-dark { font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); }
.ra-bar { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; padding-bottom: 12px; border-bottom: 1px solid var(--line); }
.ra-ctrls { display: flex; align-items: center; gap: 6px; margin-right: auto; }
.ra-ctrls .icon-btn { width: 40px; height: 40px; display: inline-flex; align-items: center; justify-content: center; }
.paras { display: flex; flex-direction: column; gap: 6px; }
.para { margin: 0; padding: 12px 14px; border-radius: 12px; font-size: 16.5px; line-height: 1.7; cursor: pointer; border: 1.5px solid transparent; position: relative; transition: background-color .2s; }
.para:hover { background: var(--surface-2); }
.para.done { color: var(--muted); }
.para.current { background: var(--primary-tint); border-color: var(--primary); color: var(--ink); }
.para-bm { color: var(--accent); margin-right: 6px; }
.excerpt { display: flex; flex-direction: column; gap: 8px; padding: 12px 14px; border-radius: 12px; border: 1.5px dashed var(--warn); background: var(--warn-tint); margin: 4px 0; }
.excerpt audio { width: 100%; }
.mini { position: fixed; z-index: 28; right: 20px; bottom: 20px; width: min(430px, calc(100vw - 32px)); background: var(--surface); border: 1px solid var(--line);
  border-radius: 16px; box-shadow: var(--shadow-lg); overflow: hidden; }
.mini[hidden] { display: none; }
.mini-progress { height: 3px; background: var(--surface-2); }
.mini-progress i { display: block; height: 100%; background: var(--primary); transition: width .3s; }
.mini-body { display: flex; align-items: center; gap: 8px; padding: 10px 10px 10px 8px; }
.mini-ctrls { display: flex; align-items: center; gap: 2px; }
.mini-ctrls .ls-play { width: 38px; height: 38px; }
.mini-info { flex: 1; min-width: 0; display: flex; flex-direction: column; color: var(--ink); line-height: 1.25; }
.mini-info:hover { text-decoration: none; }
.mini-info b { font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mini-info small, .mini-kind { font-size: 11.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mini-kind { font-weight: 700; text-transform: uppercase; letter-spacing: .05em; font-size: 10.5px; }
body.has-mini #view { padding-bottom: 110px; }
@media (max-width: 860px) {
  .mini { left: 8px; right: 8px; width: auto; bottom: calc(68px + env(safe-area-inset-bottom)); border-radius: 14px; }
  body.has-mini #view { padding-bottom: 170px; }
  .para { font-size: 16px; padding: 10px 12px; }
}

/* ── Watch ──────────────────────────────────────────── */
.vgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 16px; }
.vcard { padding: 0; overflow: hidden; color: var(--ink); display: flex; flex-direction: column; }
.vcard:hover { text-decoration: none; border-color: var(--primary); }
.vthumb { position: relative; aspect-ratio: 16 / 9; display: grid; place-items: center; color: #fff;
  background: radial-gradient(120% 120% at 20% 10%, color-mix(in srgb, var(--c) 70%, #fff), var(--c) 55%, color-mix(in srgb, var(--c) 60%, #000)); }
.vthumb-ico { position: absolute; left: 14px; bottom: 10px; opacity: .55; }
.vthumb-play { position: absolute; width: 52px; height: 52px; border-radius: 50%; background: rgba(255,255,255,.92); color: #211d16; display: grid; place-items: center; box-shadow: 0 6px 20px rgba(0,0,0,.25); transition: transform .15s; }
.vcard:hover .vthumb-play { transform: scale(1.08); }
.vdur, .vdone, .vdraft { position: absolute; font-size: 12px; font-weight: 700; border-radius: 7px; padding: 2px 7px; font-variant-numeric: tabular-nums; display: inline-flex; align-items: center; gap: 4px; }
.vdur { right: 10px; bottom: 10px; background: rgba(0,0,0,.65); }
.vdone { left: 10px; top: 10px; background: var(--good); }
.vdraft { right: 10px; top: 10px; background: var(--warn); color: #fff; }
.vprog { position: absolute; left: 0; right: 0; bottom: 0; height: 4px; background: rgba(255,255,255,.35); }
.vprog i { display: block; height: 100%; background: #fff; }
.vmeta { padding: 12px 14px 14px; display: flex; flex-direction: column; gap: 3px; }
.vmeta b { font: 800 16px var(--display); }
.vmeta span { font-size: 13px; color: var(--muted); }

.vplayer { background: #16130d; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.vscreen { position: relative; aspect-ratio: 16 / 9; background: #fcf8ee; color: #211d16; container-type: inline-size; }
.vscreen video { width: 100%; height: 100%; display: block; background: #000; }
.vstage { position: absolute; inset: 0; display: grid; }
.vbig { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); width: 72px; height: 72px; border-radius: 50%; border: 0;
  background: var(--gold); color: var(--gold-ink); display: grid; place-items: center; cursor: pointer; box-shadow: 0 8px 30px rgba(88,64,20,.45); }
.vbig[hidden] { display: none; }
/* Captions sit in a strip under the picture so they never cover the lesson content */
.vcap { background: #16130d; color: #fff; font-size: clamp(13px, 1.6vw, 16px); line-height: 1.45; padding: 10px 16px 2px; text-align: center; min-height: calc(2.9em + 12px); }
.vcap[hidden] { display: block; visibility: hidden; }
.vbar { display: flex; align-items: center; gap: 10px; padding: 10px 12px; color: #f6ead2; }
.vbtn { background: none; border: 0; color: inherit; cursor: pointer; padding: 6px; border-radius: 8px; font: 800 12px var(--font); display: grid; place-items: center; min-width: 32px; min-height: 32px; opacity: .65; }
.vbtn:hover { background: rgba(255,255,255,.08); opacity: 1; }
.vbtn.on, #wl-play { opacity: 1; }
.vbtn.on { color: #e6c689; }
.vtrack { flex: 1; height: 6px; border-radius: 99px; background: rgba(255,255,255,.18); position: relative; cursor: pointer; touch-action: none; }
.vtrack::after { content: ""; position: absolute; inset: -8px 0; }
.vfill { position: absolute; left: 0; top: 0; bottom: 0; background: #d9ba77; border-radius: 99px; }
.vmark { position: absolute; top: -2px; width: 2px; height: 10px; background: rgba(255,255,255,.5); }
.vtime { font: 600 12px var(--font); font-variant-numeric: tabular-nums; white-space: nowrap; }
.vrate { background: transparent; color: inherit; border: 1px solid rgba(255,255,255,.2); border-radius: 7px; font-size: 12px; padding: 3px 4px; }
.vrate option { color: #211d16; }

.sc { padding: 5cqw 6cqw; display: flex; flex-direction: column; justify-content: center; gap: 2cqw; animation: fc-in .3s ease; min-height: 0; }
.sc h2 { font: 900 5.2cqw/1.15 var(--display); }
.sc-title { align-items: flex-start; background: linear-gradient(135deg, #f1e6cd, #fff); }
.sc-title h2 { font-size: 7cqw; }
.sc-title p { font-size: 2.6cqw; color: #665c4b; }
.sc-eyebrow { font: 800 1.9cqw var(--font); letter-spacing: .1em; text-transform: uppercase; color: #76571b; }
.sc-text ul { margin: 0; padding: 0; list-style: none; display: grid; gap: 1.6cqw; }
.sc-text li { font-size: 3cqw; padding: 1.4cqw 2cqw; border-radius: 1.4cqw; background: #fff; border: 1px solid #e7deca; opacity: 0; transform: translateY(6px); transition: opacity .4s, transform .4s; }
.sc-text li.in { opacity: 1; transform: none; }
.sc-compare { flex-direction: row; align-items: stretch; gap: 3cqw; }
.sc-side { flex: 1; display: flex; flex-direction: column; gap: 1.2cqw; min-width: 0; }
.sc-img { flex: 1; min-height: 0; border-radius: 1.4cqw; overflow: hidden; background: #eee7d8; transition: transform .6s; }
.sc-img img { width: 100%; height: 100%; object-fit: cover; }
.sc-compare.zoom .sc-img { transform: scale(1.04); box-shadow: 0 0 0 .4cqw #76571b; }
.sc-ph { height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 1cqw; color: #6e624e; font-size: 1.8cqw; text-align: center; border: 2px dashed #d8c9af; border-radius: 1.4cqw; }
.sc-side-lbl b { font: 900 3cqw var(--display); display: block; }
.sc-side-lbl span { font-size: 1.9cqw; color: #665c4b; }
.sc-side ul { margin: 0; padding-left: 2.4cqw; font-size: 1.9cqw; line-height: 1.45; }
.sc-graph-wrap { align-items: center; }
.sc-graph { height: 100%; max-height: 100%; width: auto; overflow: visible; }
.g-axis { stroke: #211d16; stroke-width: 2; }
.g-supply { stroke: #1b8f5a; stroke-width: 3.5; stroke-linecap: round; }
.g-demand { stroke: #76571b; stroke-width: 3.5; stroke-linecap: round; }
.g-guide { stroke: #8b97a8; stroke-width: 1.4; stroke-dasharray: 4 4; }
.g-eq { fill: #b88c39; stroke: #fff; stroke-width: 2; }
.g-lbl, .g-tick { font: 600 10px var(--font); fill: #665c4b; }
.g-name { font: 900 14px var(--display); } .g-name.s { fill: #1b8f5a; } .g-name.d { fill: #76571b; }
.g-arrow { stroke: #d14343; stroke-width: 2.5; } .g-arrowhead { fill: #d14343; }
.faded { opacity: .3; }
.sc-steps { gap: 1.4cqw; align-items: flex-start; }
.sc-step { font: 700 3.6cqw/1.2 "SF Mono", ui-monospace, Menlo, monospace; padding: 1cqw 2cqw; border-radius: 1.2cqw; opacity: 0; transform: translateX(-8px); transition: opacity .35s, transform .35s; }
.sc-step.in { opacity: .55; transform: none; }
.sc-step.cur { opacity: 1; background: #f1e6cd; color: #76571b; }
.sc-step:last-child.cur { background: #e2f5eb; color: #1b8f5a; }
.sc-timeline { gap: 3cqw; }
.sc-clip { display: flex; align-items: center; gap: 1cqw; font-size: 2.1cqw; color: #6e624e; border: 2px dashed #d8c9af; border-radius: 1.4cqw; padding: 2cqw; }
.sc-tl { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2cqw; position: relative; }
.sc-tl-item { display: flex; flex-direction: column; gap: .8cqw; font-size: 2.2cqw; opacity: .35; transition: opacity .4s; }
.sc-tl-item.in { opacity: 1; }
.sc-tl-t { font: 800 2.4cqw var(--font); color: #76571b; font-variant-numeric: tabular-nums; }
.sc-tl-dot { width: 2cqw; height: 2cqw; border-radius: 50%; background: #d8c9af; }
.sc-tl-item.cur .sc-tl-dot { background: #8b5cc7; box-shadow: 0 0 0 .8cqw rgba(139,92,199,.2); }
.cues { display: flex; flex-direction: column; gap: 2px; max-height: 340px; overflow-y: auto; }
.cue { display: grid; grid-template-columns: 40px 1fr; gap: 8px; text-align: left; background: none; border: 0; padding: 7px 8px; border-radius: 9px; font-size: 13.5px; line-height: 1.45; cursor: pointer; color: var(--ink); }
.cue .num { color: var(--muted); font-size: 12px; padding-top: 1px; }
.cue:hover { background: var(--surface-2); }
.cue.current { background: var(--primary-tint); }
.cue.current .num { color: var(--primary); font-weight: 700; }
.script { margin: 0; padding-left: 20px; display: grid; gap: 8px; font-size: 13.5px; }
@media (max-width: 560px) {
  .vbar { display: grid; grid-template-columns: repeat(3, max-content) 1fr auto; gap: 4px; }
  .vtrack { grid-area: 1 / 1 / 2 / -2; margin: 5px 8px 5px 6px; }
  .vtime { grid-area: 1 / -2 / 2 / -1; font-size: 11px; }
  #wl-play { grid-row: 2; }
  .vrate { grid-area: 2 / -2 / 3 / -1; }
}

/* ── Planned pages ──────────────────────────────────── */
.planned { max-width: 760px; }
.planned-hero { display: flex; gap: 18px; align-items: flex-start; }
.planned-ico { width: 56px; height: 56px; border-radius: 16px; display: grid; place-items: center; background: var(--primary-tint); color: var(--primary); flex-shrink: 0; }
.planned ul { margin: 14px 0 0; padding: 0; list-style: none; display: grid; gap: 8px; }
.planned li { display: flex; gap: 10px; align-items: flex-start; font-size: 14.5px; }
.planned li .i { color: var(--good); margin-top: 3px; }
.badge-soon { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 700; color: var(--warn); background: var(--warn-tint); border-radius: 99px; padding: 3px 10px; }

/* ── Workspace ──────────────────────────────────────── */
.ws-timer { font: 900 64px var(--display); font-variant-numeric: tabular-nums; text-align: center; padding: 10px 0; }
.ws-timer.over { color: var(--bad); }
textarea.input { width: 100%; min-height: 220px; resize: vertical; line-height: 1.55; }

/* ── Flashcards ─────────────────────────────────────── */
.fc-sections { display: flex; flex-direction: column; gap: 2px; font-size: 13px; }
.fc-sections a { display: flex; justify-content: space-between; gap: 8px; color: var(--muted); padding: 3px 0; }
.fc-sections a span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fc-sections a:hover { color: var(--primary); text-decoration: none; }
.fc-card {
  max-width: 720px; margin: 0 auto; min-height: 280px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px;
  background: var(--surface); border: 1px solid var(--line); border-radius: 20px; box-shadow: var(--shadow); padding: 28px 24px 32px;
  text-align: center; cursor: pointer; position: relative; user-select: none;
}
.fc-card:hover { border-color: var(--primary); }
.fc-tags { position: absolute; top: 14px; left: 16px; right: 16px; justify-content: flex-start; }
.fc-front { font: 800 26px/1.35 var(--display); white-space: pre-wrap; margin-top: 24px; max-width: 100%; overflow-wrap: anywhere; }
.fc-back { border-top: 1px dashed var(--line); padding-top: 16px; width: 100%; font-size: 17px; line-height: 1.55; white-space: pre-wrap; overflow-wrap: anywhere; animation: fc-in .18s ease; }
.fc-hint { margin-top: 4px; }
@keyframes fc-in { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }
.fc-actions { display: flex; justify-content: center; gap: 10px; margin-top: 18px; flex-wrap: wrap; }
.fc-rate { flex-direction: column; gap: 0; min-width: 104px; padding: 8px 14px; }
.fc-rate small { color: var(--muted); font-weight: 500; font-size: 12px; }
.fc-again { border-color: var(--bad); } .fc-again b { color: var(--bad); }
.fc-hard b { color: var(--warn); }
.fc-good { border-color: var(--good); } .fc-good b { color: var(--good); }
.fc-easy b { color: var(--primary); }
.fc-done { max-width: 560px; margin: 0 auto; text-align: center; padding: 32px 24px; }
.player-top { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 16px; flex-wrap: wrap; }

/* ── Dialog + toast ─────────────────────────────────── */
dialog { border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); color: var(--ink); padding: 22px; width: min(460px, calc(100vw - 32px)); box-shadow: var(--shadow-lg); }
dialog::backdrop { background: rgba(10, 16, 28, .45); }
dialog form { display: flex; flex-direction: column; gap: 12px; }
dialog label { display: flex; flex-direction: column; gap: 5px; font-size: 13px; font-weight: 700; color: var(--muted); }
.checks { display: flex; flex-wrap: wrap; gap: 6px 14px; }
.checks label { flex-direction: row; align-items: center; gap: 6px; font-weight: 500; color: var(--ink); font-size: 14px; }
.toast { position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 20px); opacity: 0; pointer-events: none; z-index: 50;
  background: var(--ink); color: var(--bg); padding: 10px 16px; border-radius: 12px; font-size: 14px; font-weight: 600; box-shadow: var(--shadow-lg);
  transition: opacity .2s, transform .2s; max-width: calc(100vw - 32px); }
.toast.on { opacity: 1; transform: translate(-50%, 0); }

/* ── Responsive ─────────────────────────────────────── */
@media (max-width: 1180px) {
  .home-top { grid-template-columns: 1fr 1fr; }
  .home-top .resume { grid-column: 1 / -1; }
}
@media (max-width: 1080px) {
  .home-grid { grid-template-columns: 1fr; }
  .week { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (max-width: 860px) {
  .shell { grid-template-columns: 1fr; }
  body.sb-collapsed { --sb-w: 236px; }
  .sidebar { position: fixed; left: 0; top: 0; width: 272px; transform: translateX(-100%); transition: transform .2s ease; z-index: 40; }
  body.nav-open .sidebar { transform: none; box-shadow: var(--shadow-lg); }
  body.nav-open .scrim { display: block; position: fixed; inset: 0; background: rgba(10,16,28,.4); z-index: 35; }
  .sb-collapse { display: none; }
  body.sb-collapsed .brand-name, body.sb-collapsed .nav-text, body.sb-collapsed .profile-text, body.sb-collapsed .season-pick { display: revert; }
  body.sb-collapsed .nav a { justify-content: flex-start; padding: 8px 10px; }
  .topbar .menu-btn { display: inline-grid; }
  .topbar { padding: 10px 16px; gap: 10px; }
  .crumbs { display: none; }
  .search { flex: 1; width: auto; }
  .search kbd { display: none; }
  #view { padding: 18px 16px 96px; }
  .bottombar { display: flex; position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; background: var(--surface); border-top: 1px solid var(--line);
    padding: 6px 6px calc(6px + env(safe-area-inset-bottom)); justify-content: space-around; }
  .bottombar a, .bottombar button { flex: 1; display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 6px 2px; border-radius: 10px; color: var(--muted);
    font-size: 11px; font-weight: 700; background: none; border: 0; cursor: pointer; position: relative; min-height: 48px; justify-content: center; }
  .bottombar a.active { color: var(--primary); }
  .bottombar a:hover { text-decoration: none; }
  .bottombar .nav-count { position: absolute; top: 2px; left: calc(50% + 6px); margin: 0; padding: 0 5px; }
  .toast { bottom: 84px; }
  .player { grid-template-columns: 1fr; }
  .navigator { grid-template-columns: repeat(10, 1fr); }
  .two, .ev-answers { grid-template-columns: 1fr; }
  .home-top { grid-template-columns: 1fr; }
  .fgroup { grid-template-columns: 1fr; gap: 6px; }
  .fgroup > span { padding-top: 0; }
  .prog-row { grid-template-columns: 100px minmax(0, 1fr) 52px; }
  .prog-row > :last-child { display: none; }
}
@media (max-width: 560px) {
  h1 { font-size: 2rem; }
  .week { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .navigator { grid-template-columns: repeat(6, 1fr); }
  .q-row { grid-template-columns: 1fr; }
  .list-item:has(.btn) { flex-wrap: wrap; }
  .list-item:has(.btn) .grow { flex-basis: calc(100% - 30px); }
  .fc-front { font-size: 21px; }
  .fc-rate { min-width: 0; flex: 1 1 40%; }
  .table.stack-sm thead { display: none; }
  .table.stack-sm tr { display: grid; grid-template-columns: 1fr auto; gap: 2px 10px; padding: 10px 0; border-bottom: 1px solid var(--line); }
  .table.stack-sm td { border: 0; padding: 0; }
  .table.stack-sm td:first-child { grid-column: 1 / -1; font-weight: 700; }
}
@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; animation: none !important; }
}

/* Study guide catalog */
.guide-grid, .resource-grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); }
.guide-grid { margin-bottom: 26px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr)); }
.guide-tabs { position: relative; flex-wrap: wrap; }
.guide-card { display: grid; grid-template-rows: auto 1fr auto auto; gap: 12px; border-top: 3px solid var(--gold); }
.guide-card h2 { font-family: "Barlow Condensed", var(--display); font-size: 26px; }
.guide-card .row { margin-top: 4px; }
.guide-card .meta { color: var(--muted); font-size: 13px; }
.guide-index { margin-bottom: 24px; }
.guide-index .list-item .title { white-space: normal; }
.guide-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.resource-grid .list-item .meta { overflow-wrap: anywhere; }
.resource-count { margin-bottom: 10px; }
@media (max-width: 560px) {
  .guide-index .card-head { align-items: flex-start; flex-direction: column; }
  .guide-tabs { flex-wrap: nowrap; }
}

/* Season schedule and standings */
.meet-banner { display: flex; align-items: center; flex-wrap: wrap; padding: 12px 16px; gap: 14px; margin-bottom: 18px; border-inline-start: 4px solid var(--gold); }
.meet-banner .grow { flex: 1 1 150px; }
.meet-count { background: var(--gold); color: var(--gold-ink); border-radius: 9px; padding: 6px 11px; font-weight: 800; white-space: nowrap; }
.season-events { grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); }
.season-event { scroll-margin-top: 80px; overflow-wrap: anywhere; }
.season-event p, .season-event details { margin-block: 8px; }
.season-event > .btn { margin: 6px 0 -4px; }
.meet-meta { color: var(--muted); font-size: .875rem; }
.season-past { margin-top: 26px; }
.standings-summary { display: flex; justify-content: space-between; flex-wrap: wrap; align-items: center; gap: 10px; margin-bottom: 16px; border-inline-start: 4px solid var(--gold); }
.standings-table tbody th { text-align: left; padding: 8px 10px; border-bottom: 1px solid var(--line); font-size: 0.875rem; color: var(--ink); text-transform: none; letter-spacing: 0; }
.standings-table small { display: block; font-weight: 500; }
.standings-score { font-weight: 800; }
.rank-place { display: inline-grid; place-items: center; min-width: 28px; border-radius: 50%; aspect-ratio: 1; background: var(--surface-2); }
.rank-first { background: var(--gold); color: var(--gold-ink); font-weight: 800; }
.mobile-score-label { display: none; }
@media (max-width: 620px) {
  .standings-table thead { position: absolute; height: 1px; width: 1px; clip-path: inset(50%); overflow: hidden; }
  .standings-table tbody, .standings-table tr { display: block; }
  .standings-table tbody tr { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); padding: 6px 0; border-bottom: 1px solid var(--line); }
  .standings-table tbody td, .standings-table tbody th { padding: 4px; border-bottom: 0; }
  .standings-table tbody th { grid-column: span 2; }
  .mobile-score-label { display: block; color: var(--muted); font-size: .75rem; font-weight: 600; }
}

.voice-controls { display: flex; flex-wrap: wrap; align-items: end; gap: 8px 12px; }
.voice-controls label { display: grid; gap: 4px; min-width: 0; flex: 1 1 140px; max-width: 290px; font-weight: 700; }
.voice-controls select { width: 100%; min-width: 0; }
.voice-controls .btn { min-height: 39px; }
.voice-controls [data-narration-status] { flex-basis: 100%; }
.narration-panel { margin-bottom: 18px; }

/* Original guide PDF and narrated text */
.guide-reader-toolbar { display: flex; align-items: center; flex-wrap: wrap; justify-content: space-between; gap: 12px; padding: 12px 16px; margin-bottom: 16px; }
.guide-reader-toolbar input { width: 4.8rem; }
.guide-reader-grid { grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); align-items: start; }
.guide-frame { width: 100%; min-height: 4rem; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface-2); overflow: hidden; }
.guide-frame p { padding: 18px; }
.guide-frame canvas { width: 100%; height: auto; vertical-align: top; }
.guide-narration-help { margin-block: 12px; }
.guide-paragraphs { position: relative; max-height: 52vh; min-height: 4rem; overflow-y: auto; padding: 4px; }
.guide-paragraphs .guide-paragraph { display: block; width: 100%; text-align: left; padding: 9px 11px; border: 1px solid transparent; border-radius: 8px; background: transparent; cursor: pointer; overflow-wrap: anywhere; }
.guide-paragraph:hover, .guide-paragraph.current { background: var(--primary-tint); border-color: var(--line); }
@media (max-width: 1050px) {
  .guide-reader-grid { grid-template-columns: 1fr; }
}

.prep-intro { max-width: 62ch; margin-bottom: 18px; }
.prep-grid { grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr)); }
.prep-card { display: grid; grid-template-rows: auto auto 1fr auto auto; align-content: start; gap: 10px; border-top: 3px solid var(--gold); }
.prep-card h2 { font: 800 1.55rem/1.1 "Barlow Condensed", var(--display); }
.prep-subject { display: flex; align-items: center; gap: 8px; font-weight: 700; font-size: .875rem; }
.prep-subject .dot { width: 9px; height: 9px; border-radius: 50%; background: var(--c); }
.prep-file { padding: 8px 10px; font-size: .875rem; }
.prep-file span:not(.chip) { flex: 1; min-width: 0; }
.prep-plan-link { display: inline-block; margin-top: 10px; }

.vcap-word.spoken { background: var(--gold); color: var(--gold-ink); border-radius: .2em; box-decoration-break: clone; }
.transcript-follow { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); font-size: .8125rem; cursor: pointer; }
.transcript-follow input { accent-color: var(--primary); }
.cue.current { box-shadow: inset 3px 0 var(--accent); }
.watch-narration > label { display: grid; gap: 6px; font-weight: 700; }
.watch-narration .voice-controls { margin-top: 12px; }
.sc-figure { margin: 0; height: 100%; animation: none; justify-content: space-between; gap: 1cqw; align-items: center; padding: 3cqw 4cqw; text-align: center; }
.sc-figure img { width: 100%; min-height: 0; flex: 1; object-fit: contain; }
.sc-figure figcaption { font-size: 1.75cqw; color: #665c4b; }

/* Answer review on the cited PDF page. */
.guide-correction { margin-bottom: 16px; border-inline-start: 4px solid var(--gold); }
.correction-prompt { font-weight: 700; margin: 0 0 12px; }
.guide-correction-source { justify-content: space-between; border-top: 1px solid var(--line); padding-top: 10px; }
.guide-frame-review { max-height: min(70vh, 780px); overflow: auto; scroll-margin-block-start: 70px; }
.guide-page-visual { position: relative; }
.guide-page-visual canvas { display: block; }
.guide-page-visual canvas[hidden] { display: none; }
.guide-pdf-markers { position: absolute; inset: 0; pointer-events: none; }
.guide-pdf-marker { position: absolute; background: #ffcf41aa; box-shadow: 0 0 0 1px #9a69064a; mix-blend-mode: multiply; }
.material-note { margin-bottom: 12px; }
.material-scan img { display: block; width: 100%; height: auto; }
#material-pager[hidden] { display: none; }

.material-videos { margin-top: 12px; font-size: .875rem; }

/* Original packets are answerable in the study hub. */
.packet-layout { grid-template-columns: minmax(0, 2.3fr) minmax(250px, 1fr); align-items: start; }
.packet-prompt { margin-bottom: 16px; font-weight: 600; }
.packet-index .navigator { margin-bottom: 12px; }
.packet-index .nav-q { display: grid; place-items: center; text-decoration: none; }
.packet-letter-list { gap: 12px; }
.packet-letter-list .choice-btn { width: auto; justify-content: center; min-width: 60px; }
.packet-check, .packet-next { margin-top: 14px; }
.packet-feedback { margin-top: 14px; padding: 12px; border-radius: 10px; background: var(--surface-2); }
.packet-feedback p { margin: 4px 0 8px; }
.packet-good { background: var(--good-tint); }
.packet-miss { background: var(--bad-tint); }
.packet-pager { margin-bottom: 10px; }
.packet-crop, .packet-full-scan { display: block; width: 100%; margin-bottom: 12px; background: #fff; }
.packet-source .guide-frame { max-height: 72vh; overflow: auto; }
#packet-response { min-height: 105px; }
@media (max-width: 840px) { .packet-layout { grid-template-columns: 1fr; } }

.read-word.spoken { color: #211706; background: #f0cf72; border-radius: 3px; box-shadow: 1px 0 #f0cf72, -1px 0 #f0cf72; }
.material-form { width: 100%; min-height: 68vh; border: 1px solid var(--line); border-radius: var(--radius); background: white; }
@media (max-width: 720px) {
  .guide-narration { grid-row: 1; }
}
.packet-source-inline { margin-bottom: 16px; }
.packet-source-inline > .card-head { margin-bottom: 8px; }
.music-reader { min-width: 0; }
.music-reader select { max-width: min(100%, 310px); text-overflow: ellipsis; }
.music-reader input[type="range"] { width: min(100%, 17rem); accent-color: var(--primary); }
#music-book { display: block; width: 100%; height: max(52vh, 350px); margin-top: 14px; border: 1px solid var(--line); border-radius: 8px; background: #fff; }
#music-book[hidden] { display: none; }
.meet-exam { flex-wrap: wrap; }
.mock-passage { border: 1px solid var(--line); border-radius: 10px; padding: 12px; margin: 12px 0; background: var(--surface-2); }
.mock-passage summary { font-weight: 600; cursor: pointer; }
.mock-passage img, .mock-question-image { display: block; width: 100%; height: auto; background: white; border-radius: 6px; margin: 8px 0 14px; }
.mock-letter-choices { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.sc-guide { background: #fcf8ee; color: #221e16; justify-content: center; }
.sc-guide-label { font-weight: 750; font-size: clamp(10px, 2.5cqw, 17px); color: #725413; }
.guide-scene-reading { overflow-wrap: anywhere; font-size: clamp(14px, 4.6cqw, 30px); line-height: 1.37; font-family: Georgia, serif; }
.watch-guide summary { cursor: pointer; font-weight: 750; }
.watch-guide-controls, .watch-guide-links { margin-block: 12px; }
.watch-guide .guide-frame { max-height: 74vh; overflow: auto; }

/* ── Team sign-in (auth.js) ─────────────────────────── */
body.auth-locked .shell, body.auth-locked .bottombar, body.auth-locked .mini { display: none !important; }
#auth-screen { position: fixed; inset: 0; z-index: 200; display: grid; place-items: center; padding: 24px 16px; overflow-y: auto;
  background: radial-gradient(120% 90% at 50% 0%, #2b2213 0%, #120f0a 55%, #0b0906 100%); color: #fff5df; }
.auth-card { width: min(420px, 100%); background: rgba(30, 24, 15, .86); border: 1px solid rgba(214, 183, 114, .3); border-radius: 20px;
  padding: 30px 28px 24px; box-shadow: 0 30px 80px -30px rgba(0, 0, 0, .8); text-align: center; }
.auth-crest { margin: 0 auto 10px; height: 69px; width: auto; filter: drop-shadow(0 8px 16px rgba(0, 0, 0, .6)); }
.auth-kicker { color: var(--gold); font-size: 11px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; margin-bottom: 8px; }
.auth-card h1 { font-size: 30px; color: #fff5df; margin-bottom: 6px; }
.auth-sub { color: #cdbf9f; font-size: 14px; margin-bottom: 4px; }
.auth-card form { display: flex; flex-direction: column; gap: 12px; margin-top: 18px; text-align: left; }
.auth-card label { display: flex; flex-direction: column; gap: 6px; font-size: 13px; font-weight: 700; color: #e4d3ad; }
.auth-card label small { font-weight: 500; color: #a8987a; }
.auth-card input { background: #120f0a; border: 1px solid #4a3c24; color: #fff5df; border-radius: 11px; padding: 12px 13px; font-size: 16px; }
.auth-card input:focus { outline: 2px solid var(--gold); outline-offset: 1px; border-color: var(--gold); }
.auth-card .btn.lg { width: 100%; margin-top: 4px; }
.auth-card .btn.ghost { color: #cdbf9f; }
.auth-error { min-height: 1.2em; color: #f2a39b; font-size: 13.5px; font-weight: 600; margin: 0; }
.auth-help { color: #a8987a; font-size: 13px; margin-top: 16px; }
.auth-back { display: inline-block; margin-top: 10px; color: var(--gold); font-size: 13px; font-weight: 600; }
.acct-row { display: flex; align-items: center; gap: 2px; padding: 0 4px; flex-wrap: wrap; }
.acct-who { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 700; color: var(--muted); margin-right: auto; }
.acct-row .btn.sm { min-height: 28px; padding: 4px 8px; font-size: 12px; }
body.sb-collapsed .acct-row { display: none; }
.presence-dot { width: 8px; height: 8px; border-radius: 50%; background: #3fbf6f; box-shadow: 0 0 0 3px rgba(63, 191, 111, .2); flex-shrink: 0; }
body.is-idle .acct-who .presence-dot { background: #9a8f7c; box-shadow: none; }
.presence-dot.off { background: #9a8f7c; box-shadow: none; }
.temp-pass code { display: block; font-size: 22px; padding: 12px; border-radius: 10px; background: var(--surface-2); border: 1px solid var(--line); text-align: center; user-select: all; }

/* ── Team activity leaderboard ──────────────────────── */
.lb-online { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.lb-online .chip { gap: 6px; }
.lb-table td.num, .lb-table th.num { text-align: right; }
.lb-table tr.me { background: var(--primary-tint); }
.lb-table tr.me th { color: var(--primary); }
.lb-bar { height: 6px; border-radius: 99px; background: var(--surface-2); margin-top: 6px; overflow: hidden; min-width: 80px; }
.lb-bar i { display: block; height: 100%; background: var(--gold); border-radius: 99px; }
.lb-name { display: flex; align-items: center; gap: 8px; }
.lb-podium { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin-bottom: 18px; }
.lb-podium .card { text-align: center; padding: 16px; }
.lb-podium .place { font: 900 30px var(--display); color: var(--gold); }
.lb-podium b { display: block; margin: 4px 0 2px; }
.lb-podium .big-num { font-size: 26px; }
@media (max-width: 560px) { .lb-podium { grid-template-columns: 1fr; } }

/* ── Question source line ───────────────────────────── */
.q-source { display: flex; align-items: flex-start; gap: 6px; margin: -8px 0 16px; font-size: 13px; color: var(--muted); }
.q-source .i { margin-top: 2px; color: var(--gold); }
.q-source b { color: var(--ink); font-weight: 650; }
.q-source a { font-weight: 600; }
.src-line { margin-top: 4px; font-size: 12.5px; color: var(--muted); }
.src-line b { color: var(--ink); font-weight: 600; }

/* Watch: lessons with a cover image */
.vthumb.has-poster { background: #111; overflow: hidden; }
.vthumb-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }

.pdf-reader { min-width: 0; }
.pdf-reader-toolbar { display: grid; gap: 10px; margin-bottom: 12px; }
.pdf-reader-navigation { gap: 8px 14px; }
.pdf-reader-navigation label { min-width: 0; max-width: 100%; }
.pdf-reader-navigation #pdf-chapter { max-width: min(65vw, 350px); text-overflow: ellipsis; }
.pdf-reader-navigation input { width: 3.6rem; }
.pdf-reader-settings > summary { display: none; }
.pdf-reader-settings:not([open]) > summary { display: flex; justify-content: space-between; gap: 8px; cursor: pointer; font-size: 13px; font-weight: 700; }
.pdf-reader-voice { margin-top: 8px; }
.pdf-reader-voice summary { cursor: pointer; width: fit-content; font-size: 13px; font-weight: 700; }
.pdf-reader-voice .voice-controls { margin-top: 8px; }
#pdf-reader-frame { max-height: min(73vh, 880px); overflow: auto; background: #e9e4d9; }
#pdf-reader-frame .guide-page-visual { margin-inline: auto; background: #fff; }
.pdf-line-layer { position: absolute; inset: 0; }
.pdf-read-line { position: absolute; border: 0; padding: 0; background: transparent; cursor: pointer; border-radius: 2px; }
.pdf-read-line:hover { background: rgba(235, 185, 52, .21); }
.pdf-read-line.current { background: rgba(250, 199, 59, .42); box-shadow: inset 3px 0 #a06b0c; }
.pdf-read-line:focus-visible { outline: 2px solid #78520a; outline-offset: 1px; }
@media (max-width: 680px) {
  .pdf-reader-settings > summary { display: flex; justify-content: space-between; gap: 8px; cursor: pointer; font-size: 13px; font-weight: 700; padding-block: 8px; }
  .pdf-reader-settings > summary span:first-child::before { content: "+ "; }
  .pdf-reader-settings[open] > summary span:first-child::before { content: "− "; }
  #pdf-reader-frame { max-height: 64vh; }
}
.question-bank-grid > .stack { min-width: 0; }
.qb-section-select { width: 100%; min-width: 0; max-width: 100%; text-overflow: ellipsis; }
.fc-printed-card { display: block; width: min(100%, 650px); height: auto; margin: 0 auto; border-radius: 6px; background: white; }
.fc-printed-source { justify-content: center; margin-top: 12px; }

.season-pick[hidden] { display: none !important; }
#more-nav summary {
  display: flex; align-items: center; gap: 11px; padding: 8px 10px; color: var(--muted);
  border-radius: 10px; font-weight: 600; font-size: 14px; white-space: nowrap; cursor: pointer; list-style: none;
}
#more-nav summary::-webkit-details-marker { display: none; }
#more-nav summary:hover, #more-nav[open] summary { background: var(--surface-2); color: var(--ink); }
#more-nav summary .nav-text::after { content: " ▾"; }
#more-nav[open] summary .nav-text::after { content: " ▴"; }
#more-nav a { padding-left: 22px; }
.study-plan { margin-top: 16px; }
.study-plan summary { font-weight: 700; cursor: pointer; }
.study-plan .week { margin-top: 14px; }
@media (min-width: 841px) {
  body.sb-collapsed #more-nav summary, body.sb-collapsed #more-nav a { padding-inline: 0; justify-content: center; }
}
.qb-filters { margin-block: 14px; }
.qb-filters summary { color: var(--muted); font-weight: 600; cursor: pointer; }

/* Study planner */
.planner { margin-bottom: 18px; }
.plan-settings { flex-wrap: wrap; gap: 8px 14px; margin: 10px 0 12px; }
.plan-days { display: grid; grid-template-columns: repeat(auto-fit, minmax(84px, 1fr)); gap: 8px; margin-bottom: 14px; }
.plan-day { display: grid; gap: 2px; justify-items: center; padding: 9px 6px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface-2); color: inherit; cursor: pointer; font: inherit; }
.plan-day b { font-size: 13px; } .plan-day span { font-size: 12px; opacity: .75; } .plan-day i { font-size: 11px; font-style: normal; color: var(--primary); min-height: 1em; }
.plan-day.on { border-color: var(--primary); background: var(--primary-tint); }
.plan-day.off { opacity: .55; }
.plan-body h3 { margin: 0 0 10px; font-size: 16px; }
.plan-tasks { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.plan-task { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface-2); }
.plan-task.done { opacity: .6; } .plan-task.done .title { text-decoration: line-through; }
.plan-task .title { font-weight: 700; } .plan-task .meta { font-size: 12.5px; color: var(--muted); margin-top: 2px; }
.plan-ico { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 10px; background: var(--primary-tint); color: var(--primary); flex: none; }
.plan-check input { width: 18px; height: 18px; accent-color: var(--primary); }
.plan-tasks.compact .plan-task { padding: 8px 10px; }
.plan-focus { margin-top: 14px; } .plan-focus summary { cursor: pointer; font-weight: 700; font-size: 13px; }
@media (max-width: 680px) { .plan-task { flex-wrap: wrap; } .plan-task .btn { margin-left: auto; } }

/* Guide excerpt after an answer */
.ev-excerpt { margin: 12px 0; padding: 12px 14px; border: 1px solid var(--line); border-left: 4px solid var(--primary); border-radius: 12px; background: var(--surface-2); }
.ev-excerpt blockquote { margin: 8px 0 10px; font-size: 14.5px; line-height: 1.55; }
.ev-excerpt mark { background: rgba(250, 199, 59, .45); color: inherit; padding: 0 2px; border-radius: 3px; }

/* Ask the guides */
.ask-top { flex-wrap: wrap; gap: 10px 14px; margin-bottom: 12px; }
.ask-log { display: grid; gap: 12px; min-height: 160px; max-height: 58vh; overflow-y: auto; padding: 4px 2px 12px; }
.ask-msg { display: flex; gap: 10px; align-items: flex-start; } .ask-msg.me { justify-content: flex-end; }
.ask-ico { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; background: var(--primary-tint); color: var(--primary); flex: none; }
.ask-bubble { max-width: min(680px, 100%); padding: 10px 14px; border-radius: 14px; background: var(--surface-2); border: 1px solid var(--line); line-height: 1.55; }
.ask-msg.me .ask-bubble { background: var(--primary-tint); }
.ask-cite { font-weight: 700; white-space: nowrap; }
.ask-chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 10px 0 14px; }
.ask-sources { margin-top: 10px; font-size: 13px; } .ask-sources summary { cursor: pointer; font-weight: 700; }
.ask-source { margin-top: 8px; padding-left: 10px; border-left: 3px solid var(--line); } .ask-source p { margin: 4px 0 0; color: var(--muted); }

/* Test blueprint, meet results, focus subjects */
.bp-row { display: grid; grid-template-columns: 150px 1fr; gap: 10px; align-items: center; margin: 8px 0; }
.bp-name { font-weight: 700; font-size: 13.5px; } .bp-name .dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; margin-right: 6px; }
.bp-bar { display: flex; gap: 3px; height: 32px; }
.bp-seg { display: grid; place-items: center; min-width: 6px; border-radius: 6px; color: #1b1608; font-size: 12px; font-weight: 800; text-decoration: none; }
.bp-seg:hover { filter: brightness(1.12); }
.rs-in { width: 86px; padding: 6px 8px; } .rs-cell { min-width: 170px; }
.rs-bar { display: inline-block; width: 110px; height: 9px; border-radius: 6px; background: var(--line); overflow: hidden; vertical-align: middle; margin-right: 8px; }
.rs-bar i { display: block; height: 100%; } .rs-bar i.good { background: #3fae6a; } .rs-bar i.warn { background: #e0a92b; } .rs-bar i.bad { background: #d9534f; }
.prep-focus { grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.focus-card { padding: 14px; border: 1px solid var(--line); border-top: 4px solid var(--c, var(--primary)); border-radius: 14px; background: var(--surface-2); }
.focus-card h3 { margin: 0 0 6px; font-size: 16px; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.focus-sec { margin: 10px 0; } .focus-sec .row { flex-wrap: wrap; gap: 6px; margin-top: 6px; }
@media (max-width: 680px) { .bp-row { grid-template-columns: 1fr; gap: 4px; } }

/* Explainer videos */
.xgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 16px; }
.xcard { display: block; color: inherit; text-decoration: none; border: 1px solid var(--line); border-radius: 14px; overflow: hidden; background: var(--surface); transition: transform .12s, box-shadow .12s; }
.xcard:hover { transform: translateY(-2px); box-shadow: 0 8px 22px rgba(0,0,0,.25); }
.xthumb { position: relative; aspect-ratio: 16 / 9; background: #111; } .xthumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.xplay { position: absolute; inset: 0; display: grid; place-items: center; color: #fff; opacity: 0; transition: opacity .15s; filter: drop-shadow(0 2px 8px rgba(0,0,0,.5)); }
.xcard:hover .xplay, .xcard:focus-visible .xplay { opacity: .95; }
.xlen { position: absolute; right: 8px; bottom: 8px; background: rgba(0,0,0,.78); color: #fff; font-size: 12px; font-weight: 700; padding: 2px 7px; border-radius: 6px; }
.xmeta { padding: 10px 12px 12px; } .xmeta .title { font-weight: 700; line-height: 1.3; } .xmeta .meta { font-size: 12.5px; color: var(--muted); margin-top: 4px; }
.xframe { position: relative; aspect-ratio: 16 / 9; background: #111 center / cover no-repeat; border-radius: 12px; overflow: hidden; }
.xframe iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.xbig { position: absolute; inset: 0; display: grid; place-items: center; width: 100%; border: 0; background: rgba(0,0,0,.28); color: #fff; cursor: pointer; }

.guide-video { margin-bottom: 14px; }
.guide-video video { width: 100%; max-height: 420px; background: #000; border-radius: 12px; }
.piece-embed { margin: 4px 0 10px; }
.piece-embed iframe { width: 100%; aspect-ratio: 16 / 9; border: 0; border-radius: 12px; background: #000; }
.piece-work { font-weight: 600; margin: 6px 0; }
.piece-details { margin: 6px 0 10px 18px; padding: 0; color: var(--muted, #6b6558); font-size: 13px; }
