/* ---------- Tokens ---------- */
:root {
  --bg: #f7f7f6; --panel: #ffffff; --panel-2: #fafaf9; --ink: #0b0b0c; --ink-2: #3a3a3f; --muted: #76767e;
  --line: #e8e8e6; --line-2: #f0f0ee; --hover: #f3f3f1;
  --accent: #2f54ff; --accent-soft: #eef1ff; --accent-ink: #ffffff;
  --btn: #0b0b0c; --btn-ink: #ffffff;
  --good: #12804f; --ok: #b26a00; --bad: #d02f2f;
  --good-bg: #e8f5ee; --ok-bg: #fdf3e2; --bad-bg: #fcebeb;
  --radius: 14px; --radius-sm: 10px;
  --shadow: 0 1px 2px rgba(0,0,0,.04);
  --shadow-lg: 0 12px 32px -12px rgba(0,0,0,.18);
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #09090a; --panel: #111113; --panel-2: #151517; --ink: #f4f4f5; --ink-2: #c9c9ce; --muted: #8b8b93;
    --line: #232327; --line-2: #1b1b1e; --hover: #19191c;
    --accent: #6f8bff; --accent-soft: #1a2040; --accent-ink: #0b0b0c;
    --btn: #f4f4f5; --btn-ink: #0b0b0c;
    --good: #3fcf8e; --ok: #f2b347; --bad: #ff6767;
    --good-bg: #10261c; --ok-bg: #2c220f; --bad-bg: #2e1414;
    --shadow: none; --shadow-lg: 0 12px 32px -12px rgba(0,0,0,.6);
  }
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body { background: var(--bg); color: var(--ink); font: 14.5px/1.55 Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; -webkit-font-smoothing: antialiased; font-feature-settings: "cv11", "ss01"; }
h1, h2, h3 { font-family: "Inter Tight", Inter, sans-serif; letter-spacing: -.02em; color: var(--ink); }
h1 { font-size: 30px; font-weight: 600; margin: 2px 0 6px; line-height: 1.15; }
h3 { font-size: 15px; font-weight: 600; margin: 0; letter-spacing: -.01em; }
.hidden { display: none !important; }
.muted { color: var(--muted); }
.small { font-size: 12.5px; }
.mono { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-variant-numeric: tabular-nums; }
.grow { flex: 1; }
.mt { margin-top: 14px; }
.row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.row.tight { gap: 6px; }
.eyebrow { font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
i[data-icon] { display: inline-flex; width: 18px; height: 18px; flex: none; }
i[data-icon] svg { width: 100%; height: 100%; }

/* ---------- Layout ---------- */
.shell { display: grid; grid-template-columns: 236px 1fr; min-height: 100vh; }
.shell > * { min-width: 0; }
.side { background: var(--panel); border-right: 1px solid var(--line); padding: 18px 12px; position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column; gap: 18px; }
.brand { display: flex; gap: 10px; align-items: center; padding: 4px 8px 6px; }
.mark { width: 28px; height: 28px; flex: none; }
.mark-bg { fill: var(--ink); } .mark-fg { fill: none; stroke: var(--panel); stroke-width: 7; } .mark-fg .mark-cut { stroke: var(--ink); stroke-width: 11.4; } .mark-dot { fill: var(--accent); }
.brand-name { font: 700 17px "Inter Tight", sans-serif; letter-spacing: -.02em; line-height: 1.1; }
.brand-name span { font-weight: 500; color: var(--muted); }
.brand-tag { font-size: 11.5px; color: var(--muted); margin-top: 2px; }
.mark { width: 32px !important; height: 32px !important; }
.nav { display: flex; flex-direction: column; gap: 1px; }
.nav-group { font-size: 11px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); padding: 14px 10px 6px; }
.nav-item { display: flex; align-items: center; gap: 10px; width: 100%; text-align: left; border: 0; background: none; color: var(--ink-2); font: 500 14px Inter, sans-serif; padding: 8px 10px; border-radius: 8px; cursor: pointer; }
.nav-item i[data-icon] { width: 17px; height: 17px; color: var(--muted); }
.nav-item:hover { background: var(--hover); color: var(--ink); }
.nav-item.active { background: var(--hover); color: var(--ink); font-weight: 600; }
.nav-item.active i[data-icon] { color: var(--accent); }
.side-bottom { margin-top: auto; display: flex; flex-direction: column; gap: 8px; }
.side-foot { font-size: 12px; color: var(--muted); padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; line-height: 1.6; }
.side-foot b { color: var(--ink); font-weight: 600; }

.main { padding: 36px 44px 90px; max-width: 1220px; width: 100%; }
.page-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; flex-wrap: wrap; margin-bottom: 24px; }
.sub { margin: 0; color: var(--muted); max-width: 640px; }

.card { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px 22px; margin-bottom: 16px; box-shadow: var(--shadow); }
.card-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }

.banner { display: flex; align-items: center; justify-content: space-between; gap: 12px; background: var(--ink); color: var(--panel); padding: 12px 16px; border-radius: 12px; margin-bottom: 22px; font-weight: 500; }

/* ---------- Controls ---------- */
textarea, input[type=text], input[type=password], input[type=email], select {
  width: 100%; font: inherit; color: var(--ink); background: var(--panel);
  border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 10px 12px; transition: border-color .15s, box-shadow .15s; }
textarea { resize: vertical; line-height: 1.5; }
select { cursor: pointer; }
textarea:focus, input:focus, select:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.brief-card .notes { margin-top: 10px; }
.brief-card select { width: auto; padding: 6px 10px; font-size: 13px; max-width: 230px; }
.brief-meta { margin-top: 8px; }
.row input { flex: 1; width: auto; }

.form-row { display: flex; gap: 12px; align-items: flex-end; flex-wrap: wrap; }
.field { display: flex; flex-direction: column; gap: 6px; flex: 1; min-width: 200px; }
.field.narrow { flex: none; min-width: 0; }
.field > span { font-size: 12.5px; font-weight: 500; color: var(--muted); }
.field-inline { display: flex; align-items: center; gap: 8px; }
.field-inline select { width: auto; max-width: 320px; padding: 7px 10px; font-size: 13.5px; }
.check-inline { display: inline-flex; align-items: center; gap: 8px; margin-top: 12px; font-size: 13.5px; color: var(--ink-2); cursor: pointer; }

.btn { display: inline-flex; align-items: center; gap: 8px; border: 1px solid var(--line); background: var(--panel); color: var(--ink); font: 600 14px Inter, sans-serif; padding: 9px 16px; border-radius: var(--radius-sm); cursor: pointer; transition: background .15s, transform .08s, opacity .15s; white-space: nowrap; }
.btn:hover { background: var(--hover); }
.btn:active { transform: translateY(1px); }
.btn.primary { background: var(--btn); color: var(--btn-ink); border-color: var(--btn); }
.btn.primary:hover { opacity: .88; background: var(--btn); }
.btn.accent { background: var(--accent); color: #fff; border-color: var(--accent); }
.btn.light { background: var(--panel); color: var(--ink); border-color: transparent; }
.btn.small { padding: 6px 11px; font-size: 13px; }
.btn.ghost { background: transparent; }
.btn i[data-icon] { width: 15px; height: 15px; }
.btn:disabled { opacity: .35; cursor: not-allowed; transform: none; }
.link { border: 0; background: none; color: var(--accent); font: inherit; font-weight: 600; cursor: pointer; padding: 0; }
.link:hover { text-decoration: underline; }
.link.danger { color: var(--muted); font-weight: 500; }
.link.danger:hover { color: var(--bad); }
.err { color: var(--bad); margin: 10px 0 0; font-weight: 500; }
.err:empty { display: none; }

.seg { display: inline-flex; background: var(--panel-2); border: 1px solid var(--line); border-radius: 9px; padding: 3px; }
.seg button { border: 0; background: none; font: 600 13px Inter, sans-serif; color: var(--muted); padding: 5px 12px; border-radius: 6px; cursor: pointer; }
.seg button.on { background: var(--panel); color: var(--ink); box-shadow: 0 1px 2px rgba(0,0,0,.08), 0 0 0 1px var(--line); }

/* ---------- Dashboard ---------- */
.tiles { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin-bottom: 16px; }
.tile { display: flex; align-items: center; gap: 12px; text-align: left; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; cursor: pointer; font: inherit; color: var(--ink); transition: border-color .15s, transform .15s, box-shadow .15s; }
.tile:hover { border-color: var(--ink); box-shadow: var(--shadow-lg); transform: translateY(-1px); }
.tile > i[data-icon]:first-child { width: 36px; height: 36px; padding: 9px; border-radius: 10px; background: var(--hover); color: var(--ink); }
.tile strong { display: block; font-weight: 600; font-size: 14px; }
.tile span { font-size: 12.5px; color: var(--muted); }
.tile > div { flex: 1; min-width: 0; }
.tile-arrow { color: var(--muted); width: 15px !important; height: 15px !important; }

.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; margin-bottom: 16px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.stat { padding: 18px 22px; border-left: 1px solid var(--line); }
.stat:first-child { border-left: 0; }
.stat-label { font-size: 12.5px; color: var(--muted); font-weight: 500; }
.stat-value { font: 600 32px/1.2 "Inter Tight", sans-serif; letter-spacing: -.03em; margin-top: 6px; font-variant-numeric: tabular-nums; }
.stat-value small { font-size: 15px; color: var(--muted); font-weight: 500; letter-spacing: 0; }
.stat-note { font-size: 12px; color: var(--muted); margin-top: 2px; }

.cat-row { display: grid; grid-template-columns: 140px 1fr 36px; gap: 14px; align-items: center; padding: 7px 0; }
.cat-row .name { font-size: 13.5px; color: var(--ink-2); }
.cat-row .val { text-align: right; font-weight: 600; font-size: 13.5px; font-variant-numeric: tabular-nums; }
.bar { height: 6px; border-radius: 99px; background: var(--line-2); overflow: hidden; }
.bar i { display: block; height: 100%; border-radius: 99px; background: currentColor; transition: width .7s cubic-bezier(.2,.8,.2,1); }
.focus { margin-top: 14px; padding: 12px 14px; border-radius: 10px; background: var(--accent-soft); font-size: 13.5px; color: var(--ink-2); }
.focus strong { color: var(--ink); }
.spark { width: 100%; height: 150px; display: block; color: var(--ink); }
.empty { text-align: center; padding: 30px 10px; color: var(--muted); }
.empty i[data-icon] { width: 26px; height: 26px; margin-bottom: 8px; color: var(--muted); }

.list-row { display: flex; gap: 14px; align-items: center; padding: 11px 8px; border-top: 1px solid var(--line-2); cursor: pointer; border-radius: 10px; }
.list-row:first-child { border-top: 0; }
.list-row:hover { background: var(--hover); }
.list-main { flex: 1; min-width: 0; }
.list-title { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.minis { display: flex; gap: 3px; }
.mini { font-size: 11px; font-weight: 600; width: 22px; text-align: center; padding: 2px 0; border-radius: 5px; font-variant-numeric: tabular-nums; }
.vtag { display: inline-block; font-size: 11px; font-weight: 600; padding: 1px 6px; border-radius: 5px; background: var(--hover); color: var(--ink-2); border: 1px solid var(--line); margin-left: 6px; vertical-align: 1px; }

.pill { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; font-size: 12.5px; padding: 3px 9px; border-radius: 99px; white-space: nowrap; font-variant-numeric: tabular-nums; }
.score-badge { width: 42px; height: 42px; border-radius: 10px; display: grid; place-items: center; font: 600 16px "Inter Tight", sans-serif; flex: none; font-variant-numeric: tabular-nums; }
.good { color: var(--good); } .ok { color: var(--ok); } .bad { color: var(--bad); }
.pill.good, .mini.good, .score-badge.good { background: var(--good-bg); }
.pill.ok, .mini.ok, .score-badge.ok { background: var(--ok-bg); }
.pill.bad, .mini.bad, .score-badge.bad { background: var(--bad-bg); }
.pill.neutral { background: var(--hover); color: var(--ink-2); }

/* ---------- Home ---------- */
.home { max-width: 680px; margin: 28px auto 0; }
.home-title { font-size: 36px; margin-bottom: 4px; }
.home .sub { margin-bottom: 28px; }
.home-cta { display: flex; align-items: center; gap: 16px; width: 100%; text-align: left; background: var(--btn); color: var(--btn-ink); border: 0; border-radius: 16px; padding: 22px 24px; cursor: pointer; font: inherit; transition: transform .15s, box-shadow .15s; }
.home-cta:hover { transform: translateY(-1px); box-shadow: var(--shadow-lg); }
.home-cta > i[data-icon]:first-child { width: 44px; height: 44px; padding: 11px; border-radius: 12px; background: rgba(127,127,127,.18); }
.home-cta strong { display: block; font: 600 18px "Inter Tight", sans-serif; letter-spacing: -.01em; }
.home-cta span { font-size: 13.5px; opacity: .7; }
.home-cta > div { flex: 1; }
.home-cta .tile-arrow { color: inherit; opacity: .6; }
.home-links { display: flex; gap: 8px; margin-top: 12px; flex-wrap: wrap; }
.home-links button { flex: 1; min-width: 150px; display: inline-flex; align-items: center; justify-content: center; gap: 8px; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; font: 500 14px Inter, sans-serif; color: var(--ink); cursor: pointer; transition: border-color .15s; }
.home-links button:hover { border-color: var(--ink); }
.home-links i[data-icon] { width: 16px; height: 16px; color: var(--muted); }
.home-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin: 40px 0 36px; }
.home-stat .stat-label { font-size: 12.5px; color: var(--muted); }
.home-stat .stat-value { font-size: 28px; margin-top: 2px; }
.home-stat .stat-value.text { font-size: 17px; font-weight: 600; margin-top: 8px; letter-spacing: -.01em; }
.home-section .list-row { padding: 12px 4px; }

/* ---------- Upload ---------- */
.drop { border: 1.5px dashed var(--line); border-radius: 12px; padding: 30px 20px; text-align: center; transition: .15s; background: var(--panel-2); }
.drop.over { border-color: var(--accent); background: var(--accent-soft); }
.drop-ic { width: 40px !important; height: 40px !important; padding: 10px; border-radius: 10px; background: var(--panel); border: 1px solid var(--line); margin: 0 auto 10px; display: flex !important; }
.upload-foot { display: flex; align-items: center; gap: 12px; margin-top: 14px; flex-wrap: wrap; }
.file-chip, .chip { display: inline-flex; gap: 10px; align-items: center; background: var(--panel); border: 1px solid var(--line); padding: 7px 12px; border-radius: 9px; font-size: 13.5px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.chips:empty { display: none; }
.chip button { border: 0; background: none; color: var(--muted); cursor: pointer; font-size: 15px; padding: 0 0 0 4px; line-height: 1; }
.chip button:hover { color: var(--bad); }

.progress { margin-top: 16px; }
.progress-top { display: flex; justify-content: space-between; font-weight: 500; margin-bottom: 8px; font-size: 13.5px; }
.progress-bar { height: 4px; border-radius: 99px; background: var(--line-2); overflow: hidden; margin-bottom: 8px; }
.progress-bar i { display: block; height: 100%; width: 0; background: var(--ink); border-radius: 99px; transition: width .8s ease; }
.progress-bar.indet i { width: 30%; animation: slide 1.3s ease-in-out infinite; }
@keyframes slide { 0% { transform: translateX(-100%); } 100% { transform: translateX(340%); } }
.spinner { width: 14px; height: 14px; border: 2px solid var(--line); border-top-color: var(--ink); border-radius: 50%; animation: spin .8s linear infinite; display: inline-block; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- Report ---------- */
.report-layout { display: grid; grid-template-columns: 330px 1fr; gap: 20px; align-items: start; }
.player-col { position: sticky; top: 24px; }
.player { padding: 10px; }
.player video { width: 100%; max-height: 540px; border-radius: 10px; background: #000; display: block; }
.no-video { padding: 40px 10px; text-align: center; color: var(--muted); background: var(--panel-2); border-radius: 10px; }
.timeline { position: relative; height: 28px; margin: 12px 6px 4px; cursor: pointer; }
.tl-track { position: absolute; left: 0; right: 0; top: 12px; height: 4px; background: var(--line); border-radius: 99px; }
.tl-head { position: absolute; top: 5px; width: 2px; height: 18px; background: var(--ink); border-radius: 2px; left: 0; pointer-events: none; z-index: 3; }
.tl-mark { position: absolute; top: 7px; width: 14px; height: 14px; margin-left: -7px; border-radius: 50%; border: 2px solid var(--panel); cursor: pointer; padding: 0; transition: transform .12s; }
.tl-mark:hover { transform: scale(1.35); z-index: 4; }
.tl-mark.fix { background: var(--accent); width: 18px; height: 18px; margin-left: -9px; top: 5px; color: #fff; font: 700 10px Inter; display: grid; place-items: center; z-index: 2; }
.tl-mark.bad { background: var(--bad); } .tl-mark.good { background: var(--good); } .tl-mark.ok { background: var(--ok); }
.legend { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; padding-bottom: 4px; }
.dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; margin-right: 5px; }
.dot.fix { background: var(--accent); } .dot.bad { background: var(--bad); } .dot.good { background: var(--good); } .dot.ok { background: var(--ok); }

.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin-bottom: 16px; }
.tab { border: 0; background: none; font: 600 13.5px Inter, sans-serif; color: var(--muted); padding: 10px 12px; cursor: pointer; border-bottom: 2px solid transparent; margin-bottom: -1px; display: inline-flex; gap: 6px; align-items: center; }
.tab:hover { color: var(--ink); }
.tab.on { color: var(--ink); border-bottom-color: var(--ink); }
.tab-badge { font-size: 11px; padding: 1px 6px; border-radius: 99px; }
.tab-badge:empty { display: none; }

.hero { display: flex; gap: 24px; align-items: center; }
.ring-svg { width: 118px; height: 118px; flex: none; }
.ring-svg .trk { stroke: var(--line-2); }
.ring-num { font: 600 34px "Inter Tight", sans-serif; letter-spacing: -.03em; fill: var(--ink); }
.ring-sub { font: 500 11px Inter; fill: var(--muted); }
.verdict-tag { margin-bottom: 8px; }
.meta { font-size: 12px; color: var(--muted); margin-top: 10px; }
.report-actions { display: flex; gap: 8px; margin-top: 14px; flex-wrap: wrap; }

.compare { display: grid; grid-template-columns: auto 1fr; gap: 22px; align-items: start; }
.compare-big { display: flex; align-items: baseline; gap: 10px; font-family: "Inter Tight", sans-serif; }
.compare-big .from { font-size: 22px; color: var(--muted); font-weight: 600; }
.compare-big .to { font-size: 34px; font-weight: 600; letter-spacing: -.03em; }
.delta { font: 600 13px Inter; padding: 2px 8px; border-radius: 99px; }
.delta.up { color: var(--good); background: var(--good-bg); }
.delta.down { color: var(--bad); background: var(--bad-bg); }
.delta.same { color: var(--muted); background: var(--hover); }
.cmp-table td { padding: 6px 8px; }
.cmp-table td:not(:first-child) { text-align: right; font-variant-numeric: tabular-nums; }

.fixes { margin: 0; padding: 0; list-style: none; }
.fixes li { display: grid; grid-template-columns: 26px 1fr; gap: 12px; padding: 12px 0; border-top: 1px solid var(--line-2); }
.fixes li:first-child { border-top: 0; padding-top: 0; }
.num { width: 24px; height: 24px; border-radius: 7px; background: var(--ink); color: var(--panel); font-weight: 600; font-size: 12px; display: grid; place-items: center; font-variant-numeric: tabular-nums; }
.why { color: var(--muted); font-size: 13.5px; margin-top: 2px; }
.ts { display: inline-block; font: 600 11.5px/1.7 ui-monospace, SFMono-Regular, Menlo, monospace; background: var(--accent-soft); color: var(--accent); padding: 0 6px; border-radius: 5px; margin-right: 7px; cursor: pointer; border: 0; vertical-align: 1px; }
.ts:hover { background: var(--accent); color: #fff; }

.cats { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-bottom: 16px; }
.cat { margin: 0; }
.cat-head { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.cat .bar { margin: 12px 0 12px; height: 4px; }
.label { font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: .07em; color: var(--muted); margin: 14px 0 6px; }
.cat ul, .plain { margin: 0; padding-left: 0; list-style: none; }
.cat li, .plain li { margin: 7px 0; font-size: 13.5px; padding-left: 14px; position: relative; color: var(--ink-2); }
.cat li::before, .plain li::before { content: ""; position: absolute; left: 2px; top: 9px; width: 4px; height: 4px; border-radius: 50%; background: var(--muted); }
.cat li.fix-li::before { background: var(--accent); }
.vs { font-size: 12px; font-weight: 600; margin-left: 6px; }

table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
td, th { text-align: left; padding: 10px 8px; border-top: 1px solid var(--line-2); vertical-align: top; }
th { color: var(--muted); font-weight: 600; border-top: 0; font-size: 11px; text-transform: uppercase; letter-spacing: .06em; }
.status { font-weight: 600; white-space: nowrap; }

details summary { cursor: pointer; font-weight: 600; list-style: none; }
details summary::-webkit-details-marker { display: none; }
details summary::before { content: "+ "; color: var(--muted); }
details[open] summary::before { content: "– "; }
.transcript p { margin: 8px 0; }

/* Checklist */
.check-group { margin-bottom: 18px; }
.check-row { display: grid; grid-template-columns: 22px 1fr auto; gap: 12px; align-items: start; padding: 10px 0; border-top: 1px solid var(--line-2); }
.check-row:first-of-type { border-top: 0; }
.check-ic { width: 20px; height: 20px; border-radius: 50%; display: grid; place-items: center; font-size: 12px; font-weight: 700; margin-top: 1px; }
.check-ic.pass { background: var(--good-bg); color: var(--good); }
.check-ic.warn { background: var(--ok-bg); color: var(--ok); }
.check-ic.fail { background: var(--bad-bg); color: var(--bad); }
.check-row .note { color: var(--muted); font-size: 13px; margin-top: 2px; }
.manual { display: flex; gap: 12px; align-items: flex-start; padding: 9px 0; border-top: 1px solid var(--line-2); cursor: pointer; }
.manual:first-of-type { border-top: 0; }
.manual input { width: 18px; height: 18px; margin: 1px 0 0; accent-color: var(--ink); flex: none; cursor: pointer; }
.manual.done span { color: var(--muted); text-decoration: line-through; }
.readiness { display: flex; align-items: center; gap: 16px; }
.readiness .bar { flex: 1; height: 8px; }

/* Hook Lab */
.hook-card { display: grid; grid-template-columns: 180px 1fr; gap: 20px; }
.hook-video { position: relative; }
.hook-video video { width: 100%; border-radius: 10px; background: #000; display: block; aspect-ratio: 9 / 16; object-fit: cover; }
.rank { position: absolute; top: 8px; left: 8px; background: var(--ink); color: var(--panel); font: 600 12px Inter; padding: 3px 8px; border-radius: 6px; }
.rank.first { background: var(--accent); color: #fff; }
.hook-top { display: flex; justify-content: space-between; gap: 14px; align-items: flex-start; }
.hook-score { font: 600 40px/1 "Inter Tight", sans-serif; letter-spacing: -.03em; font-variant-numeric: tabular-nums; }
.hook-score small { font-size: 14px; color: var(--muted); font-weight: 500; }
.dims { display: grid; grid-template-columns: 1fr 1fr; gap: 6px 22px; margin-top: 12px; }
.dims .cat-row { grid-template-columns: 1fr 70px 22px; padding: 3px 0; }
.alt { display: grid; grid-template-columns: 1fr auto; gap: 10px; align-items: start; padding: 11px 0; border-top: 1px solid var(--line-2); }
.alt:first-of-type { border-top: 0; }
.alt-type { font-size: 11px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--accent); }
.alt-line { font-weight: 600; font-size: 14.5px; margin: 2px 0; }

/* Research */
.res-hero { display: flex; justify-content: space-between; gap: 16px; align-items: flex-start; flex-wrap: wrap; }
.res-hero h2 { font-size: 24px; margin: 0 0 4px; font-weight: 600; }
.kv { display: grid; grid-template-columns: 130px 1fr; gap: 10px 16px; font-size: 13.5px; }
.kv dt { color: var(--muted); font-weight: 500; }
.kv dd { margin: 0; color: var(--ink-2); }
.tags { display: flex; flex-wrap: wrap; gap: 6px; }
.tag { font-size: 12.5px; padding: 3px 9px; border-radius: 99px; background: var(--hover); border: 1px solid var(--line); color: var(--ink-2); }
.sources { display: flex; flex-wrap: wrap; gap: 6px; }
.sources a { display: inline-flex; align-items: center; gap: 5px; font-size: 12.5px; color: var(--ink-2); text-decoration: none; padding: 3px 9px; border: 1px solid var(--line); border-radius: 99px; }
.sources a:hover { border-color: var(--ink); color: var(--ink); }
.sources i[data-icon] { width: 11px; height: 11px; }

/* Scripts */
.brief-sum dl { display: grid; grid-template-columns: 120px 1fr; gap: 8px 16px; margin: 0; font-size: 13.5px; }
.brief-sum dt { color: var(--muted); font-weight: 500; }
.brief-sum dd { margin: 0; }
.brief-sum ul { margin: 0; padding-left: 16px; }
.script { padding: 0; overflow: hidden; }
.script-top { padding: 16px 22px; display: flex; justify-content: space-between; gap: 12px; align-items: center; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.script-top h3 { font-size: 17px; margin-top: 3px; }
.style-tag { font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: .07em; color: var(--accent); }
.script-body { padding: 16px 22px 20px; }
.hooks { margin: 4px 0 0; padding-left: 20px; }
.hooks li { margin: 5px 0; }
.scene { display: grid; grid-template-columns: 58px 1fr; gap: 14px; padding: 12px 0; border-top: 1px solid var(--line-2); }
.scene:first-child { border-top: 0; }
.scene-time { font: 600 12px ui-monospace, Menlo, monospace; color: var(--muted); padding-top: 3px; }
.scene-visual { font-size: 12.5px; color: var(--muted); }
.scene-line { font-weight: 500; font-size: 15.5px; margin: 3px 0; color: var(--ink); }
.ost { display: inline-block; font-size: 12px; background: var(--accent-soft); color: var(--accent); padding: 1px 8px; border-radius: 5px; font-weight: 600; }
.two { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }

/* Brief library */
.brief-item { display: flex; gap: 16px; align-items: flex-start; }
.brief-item .grow { min-width: 0; }
.brief-preview { color: var(--muted); font-size: 13px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; margin-top: 6px; }

/* Teleprompter */
.prompter { position: fixed; inset: 0; z-index: 50; background: #000; color: #fff; display: flex; flex-direction: column; }
.prompter-bar { display: flex; gap: 14px; align-items: center; padding: 12px 18px; background: #0d0d0d; border-bottom: 1px solid #222; flex-wrap: wrap; font-size: 13.5px; }
.prompter-bar label { display: flex; gap: 8px; align-items: center; color: #aaa; }
.pbtn { border: 1px solid #333; background: #161616; color: #fff; font: 600 13px Inter; padding: 7px 14px; border-radius: 8px; cursor: pointer; }
.pbtn.on { background: #fff; color: #000; }
.prompter-scroll { flex: 1; overflow-y: auto; scrollbar-width: none; }
.prompter-scroll::-webkit-scrollbar { display: none; }
.prompter-text { max-width: 900px; margin: 0 auto; padding: 42vh 40px 80vh; font: 600 48px/1.35 "Inter Tight", sans-serif; letter-spacing: -.01em; }
.prompter-text p { margin: 0 0 .9em; }
.prompter-text .pt-time { display: block; font: 600 13px ui-monospace, monospace; color: #6f8bff; margin-bottom: 4px; letter-spacing: 0; }
.prompter-text.mirror { transform: scaleX(-1); }
.prompter-guide { position: fixed; left: 0; right: 0; top: 42vh; height: 1px; background: rgba(111,139,255,.6); pointer-events: none; }

.toast { position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%) translateY(16px); background: var(--ink); color: var(--panel); padding: 9px 16px; border-radius: 9px; font-weight: 500; font-size: 13.5px; opacity: 0; transition: .2s; pointer-events: none; z-index: 60; }
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ---------- Responsive ---------- */
@media (max-width: 1150px) {
  .report-layout { grid-template-columns: 1fr; }
  .player-col { position: static; }
  .player video { max-height: 420px; }
  .tiles { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 820px) {
  .shell { grid-template-columns: 1fr; }
  .side { position: sticky; z-index: 10; height: auto; padding: 8px 12px; flex-direction: row; align-items: center; gap: 8px; overflow-x: auto; border-right: 0; border-bottom: 1px solid var(--line); }
  .brand-name, .brand-tag, .nav-group, .side-foot { display: none; }
  .nav { flex-direction: row; }
  .side-bottom { margin: 0; }
  .nav-item { white-space: nowrap; padding: 7px 10px; font-size: 13px; }
  .main { padding: 22px 16px 60px; }
  h1 { font-size: 24px; }
  .grid-2, .cats, .two, .dims { grid-template-columns: 1fr; }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .stat:nth-child(3) { border-left: 0; }
  .stat:nth-child(n+3) { border-top: 1px solid var(--line); }
  .hero, .compare { flex-direction: column; align-items: flex-start; grid-template-columns: 1fr; }
  .hook-card { grid-template-columns: 1fr; }
  .hook-video video { max-height: 360px; width: auto; margin: 0 auto; }
  .brief-sum dl, .kv { grid-template-columns: 1fr; }
  .cat-row { grid-template-columns: 110px 1fr 30px; }
  .tiles { grid-template-columns: 1fr; }
  .home { margin-top: 8px; }
  .home-title { font-size: 28px; }
  .home-stats { grid-template-columns: 1fr 1fr; }
  .brief-card .card-head { flex-direction: column; align-items: flex-start; }
  .brief-card select { max-width: 100%; }
  .card { padding: 16px; }
  .field { min-width: 0; flex-basis: 100%; }
  .field-inline select { max-width: 220px; }
  table { display: block; overflow-x: auto; }
}
@media print {
  .side, .page-head, .brief-slot, #uploadCard, .player-col, .report-actions, .banner, .tabs { display: none !important; }
  .shell, .report-layout { display: block; }
  #repChecklist, #repTranscript { display: block !important; }
  .card { box-shadow: none; break-inside: avoid; }
}

/* No-brief mode */
.brief-card .seg.brief-mode button { padding: 6px 14px; }
.nobrief-pane .form-row { margin-top: 2px; }
.nb-hint { margin: 10px 0 0; }
.nb-hint strong { color: var(--ink-2); }
.brand-note { display: flex; gap: 12px; align-items: flex-start; }
.brand-note i[data-icon] { width: 18px; height: 18px; color: var(--accent); margin-top: 2px; }

/* ---------- Accounts ---------- */
.auth { position: fixed; inset: 0; z-index: 50; background: var(--bg); display: grid; place-items: center; padding: 24px 16px; overflow-y: auto; }
.auth-card { width: 100%; max-width: 400px; background: var(--panel); border: 1px solid var(--line); border-radius: 18px; padding: 30px 28px 24px; box-shadow: var(--shadow-lg); }
.auth-brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); margin-bottom: 22px; }
.auth-card h1 { font-size: 26px; }
.auth-card .sub { margin-bottom: 18px; }
.auth-tabs { width: 100%; margin-bottom: 18px; }
.auth-tabs button { flex: 1; padding: 7px 12px; }
#authForm { display: flex; flex-direction: column; gap: 14px; }
#authForm .field { min-width: 0; }
.field em { font-style: normal; font-weight: 400; }
.btn.wide { width: 100%; justify-content: center; padding: 11px 16px; }
.auth-ok { margin: 0; padding: 10px 12px; border-radius: 10px; background: var(--good-bg); color: var(--good); font-weight: 500; font-size: 13.5px; }
.auth-links { display: flex; justify-content: space-between; gap: 10px; }
.auth-links .link { padding: 0; font-size: 13px; }

.acct { font-size: 12.5px; padding: 12px; border: 1px solid var(--line); border-radius: 10px; display: flex; flex-direction: column; gap: 9px; }
.acct-top { display: flex; flex-direction: column; gap: 5px; }
.acct-email { font-weight: 600; color: var(--ink); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.acct .pill { align-self: flex-start; font-size: 11.5px; padding: 2px 8px; }
.meter { display: grid; gap: 4px; }
.meter-top { display: flex; justify-content: space-between; color: var(--muted); }
.meter-top b { color: var(--ink); font-weight: 600; font-variant-numeric: tabular-nums; }
.meter-bar { height: 4px; border-radius: 99px; background: var(--line); overflow: hidden; }
.meter-bar span { display: block; height: 100%; background: var(--accent); border-radius: 99px; }
.meter-bar span.full { background: var(--bad); }
.acct .link { align-self: flex-start; padding: 0; font-size: 12.5px; color: var(--muted); }

.admin-search { max-width: 260px; padding: 7px 11px; font-size: 13.5px; }
#adminTable { overflow-x: auto; }
.admin-table th, .admin-table td { vertical-align: middle; white-space: nowrap; }
.admin-table td.email { max-width: 260px; overflow: hidden; text-overflow: ellipsis; font-weight: 500; }
.admin-table select { width: auto; padding: 5px 8px; font-size: 13px; }
.admin-table .n { text-align: right; font-variant-numeric: tabular-nums; }
.admin-table th.n { text-align: right; }

@media (max-width: 820px) {
  .acct { display: none; }
  .auth-card { padding: 24px 20px 20px; }
  .admin-search { max-width: none; }
}
.meters-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 24px; margin-top: 10px; }
@media (max-width: 820px) { .meters-grid { grid-template-columns: 1fr; } }
