:root {
  --ink: #1e2140;
  --stage: #272b4a;
  --stage-2: #333862;
  --paper: #eef0f6;
  --line: #d5d9e6;
  --muted: #6a7092;
  --marigold: #ffb400;
  --marigold-ink: #3a2a00;
  --radius: 14px;
  --display: "Bricolage Grotesque", "Trebuchet MS", system-ui, sans-serif;
  --body: "Instrument Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font: 16px/1.5 var(--body);
  color: var(--ink);
  background: var(--paper);
}
a { color: inherit; }
:focus-visible { outline: 3px solid var(--marigold); outline-offset: 3px; border-radius: 6px; }

/* ---------- top bar ---------- */
.bar {
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px; padding: 14px 24px;
}
.brand { font: 800 22px/1 var(--display); letter-spacing: -0.02em; text-decoration: none; }
.brand b { color: var(--marigold); font-weight: 800; }
.nav { display: flex; gap: 4px; }
.nav a {
  text-decoration: none; padding: 8px 14px; border-radius: 999px; font-weight: 600; font-size: 15px;
}
.nav a[aria-current="page"] { background: rgba(255, 255, 255, 0.14); }
.light .nav a[aria-current="page"] { background: var(--ink); color: #fff; }

/* ---------- duel (dark stage) ---------- */
body.stage { background: var(--stage); color: #fff; min-height: 100vh; display: flex; flex-direction: column; }
.duel { flex: 1; display: flex; flex-direction: column; padding: 4px 24px 24px; max-width: 1400px; width: 100%; margin: 0 auto; }
.question { font: 700 clamp(26px, 4vw, 44px)/1.1 var(--display); letter-spacing: -0.02em; margin: 8px 0 20px; }
.arena { flex: 1; display: grid; grid-template-columns: 1fr 1fr; gap: 20px; align-items: start; }
.side { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.pick {
  position: relative; display: grid; place-items: center; padding: 10px;
  background: var(--stage-2); border: 3px solid transparent; border-radius: var(--radius);
  cursor: pointer; color: inherit; font: inherit; width: 100%; min-height: 260px;
  transition: transform 0.18s ease, opacity 0.25s ease, border-color 0.18s ease, background 0.18s ease;
}
.pick:hover { transform: translateY(-3px); background: #3b4070; }
.pick img { width: auto; height: auto; max-width: 100%; max-height: min(64vh, 720px); border-radius: 8px; display: block; background: #000; }
.pick.won { border-color: var(--marigold); transform: scale(1.015); }
.pick.won::after {
  content: "Your pick"; position: absolute; top: 14px; left: 14px;
  background: var(--marigold); color: var(--marigold-ink); font-weight: 700; font-size: 14px;
  padding: 5px 12px; border-radius: 999px;
}
.pick.lost { opacity: 0.35; transform: scale(0.98); }
.arena.locked .pick { pointer-events: none; }
.caption { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding: 0 4px; }
.caption .who { font-weight: 700; }
.caption .what { color: #b9bedc; font-size: 14px; }
.caption .links { display: flex; gap: 14px; font-size: 13px; color: #b9bedc; white-space: nowrap; }
.caption .links a, .caption .links button {
  color: inherit; background: none; border: 0; padding: 0; font: inherit; cursor: pointer; text-decoration: underline;
}
.foot { display: flex; justify-content: space-between; gap: 12px; color: #b9bedc; font-size: 14px; padding-top: 18px; }
.msg { text-align: center; margin: 12vh auto; max-width: 420px; }
.msg h2 { font: 700 28px/1.15 var(--display); margin: 0 0 8px; }
.msg p { color: #b9bedc; margin: 0 0 18px; }
.btn {
  background: var(--marigold); color: var(--marigold-ink); border: 0; border-radius: 999px;
  padding: 11px 22px; font: 700 15px var(--body); cursor: pointer;
}
.btn.ghost { background: transparent; color: inherit; border: 2px solid currentColor; }

/* ---------- report dialog ---------- */
dialog { border: 0; border-radius: var(--radius); padding: 22px; max-width: 420px; width: calc(100% - 32px); color: var(--ink); }
dialog::backdrop { background: rgba(20, 22, 48, 0.6); }
dialog h3 { margin: 0 0 6px; font: 700 20px var(--display); }
dialog p { margin: 0 0 12px; color: var(--muted); font-size: 14px; }
dialog label { display: block; font-weight: 600; font-size: 14px; margin: 10px 0 4px; }
dialog textarea, dialog input { width: 100%; padding: 9px 10px; border: 1px solid var(--line); border-radius: 8px; font: inherit; }
dialog .row { display: flex; gap: 10px; justify-content: flex-end; margin-top: 16px; }
dialog .btn.ghost { color: var(--ink); }

/* ---------- ranking (light page) ---------- */
.wrap { max-width: 980px; margin: 0 auto; padding: 8px 24px 64px; }
.wrap h1 { font: 800 clamp(30px, 5vw, 52px)/1.05 var(--display); letter-spacing: -0.03em; margin: 12px 0 6px; }
.asof { color: var(--muted); margin: 0 0 18px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 22px; }
.chip {
  border: 1px solid var(--line); background: #fff; color: var(--ink); border-radius: 999px;
  padding: 6px 13px; font: 600 14px var(--body); cursor: pointer;
}
.chip[aria-pressed="true"] { background: var(--ink); color: #fff; border-color: var(--ink); }
.list { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.item {
  display: grid; grid-template-columns: 56px 168px 1fr auto; gap: 18px; align-items: center;
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 18px 12px 12px;
}
.item:nth-child(-n + 3) { border-color: var(--marigold); box-shadow: inset 4px 0 0 var(--marigold); }
.rank { font: 800 34px/1 var(--display); text-align: center; letter-spacing: -0.03em; }
.thumb { width: 168px; height: 108px; border-radius: 8px; object-fit: cover; background: #dfe2ee; display: block; }
.info { min-width: 0; }
.info .t { font-weight: 700; overflow-wrap: anywhere; }
.info .s { color: var(--muted); font-size: 14px; }
.info .s a { color: inherit; }
.stats { text-align: right; }
.stats .score { font: 800 26px/1 var(--display); }
.stats .sub { color: var(--muted); font-size: 13px; }
.empty { background: #fff; border: 1px dashed var(--line); border-radius: var(--radius); padding: 36px; text-align: center; color: var(--muted); }

@media (max-width: 760px) {
  .bar { padding: 12px 16px; }
  .duel { padding: 0 16px 20px; }
  .arena { grid-template-columns: 1fr; gap: 14px; }
  .pick { min-height: 0; }
  .pick img { max-height: 38vh; }
  .item { grid-template-columns: 40px 1fr auto; gap: 12px; }
  .thumb { grid-column: 2 / 4; width: 100%; height: auto; aspect-ratio: 16 / 10; grid-row: 1; }
  .rank { grid-row: 1; grid-column: 1; align-self: start; font-size: 26px; }
  .info { grid-column: 1 / 3; }
  .stats { grid-column: 3; }
}
@media (prefers-reduced-motion: reduce) {
  .pick, .pick:hover, .pick.won, .pick.lost { transition: none; transform: none; }
}

/* ---------- v2: caption (title + kredit only on the duel page) ---------- */
.caption { display: block; }
.caption .t { display: block; font: 700 clamp(18px, 2.2vw, 24px)/1.2 var(--display); letter-spacing: -0.01em; color: #fff; text-decoration: none; }
.caption .t:hover { text-decoration: underline; text-underline-offset: 4px; }
.caption .k { color: #c9cdea; font-size: clamp(15px, 1.6vw, 18px); margin-top: 2px; }
body.stage, body.light { padding-bottom: 76px; } /* room for the upload button */

/* ---------- upload button + dialog (on every page) ---------- */
.upload-fab {
  position: fixed; right: 18px; bottom: 18px; z-index: 50;
  background: var(--marigold); color: var(--marigold-ink); border: 0; border-radius: 999px;
  padding: 13px 20px; font: 700 15px var(--body); cursor: pointer; box-shadow: 0 6px 20px rgba(0, 0, 0, 0.35);
}
.upload-fab:hover { background: #ffc233; }
#uploadDialog { max-width: 520px; max-height: 92vh; overflow: auto; }
#uploadDialog .field { margin: 0 0 12px; }
#uploadDialog label { margin: 0 0 4px; }
#uploadDialog .opt { font-weight: 400; color: var(--muted); }
#uploadDialog .hint { color: var(--muted); font-size: 13px; margin: 3px 0 0; }
#uploadDialog textarea { resize: vertical; }
#uploadDialog .check { display: flex; gap: 10px; align-items: flex-start; font-weight: 400; margin: 14px 0 0; }
#uploadDialog .check input { width: auto; margin-top: 4px; }
#uploadDialog .status { min-height: 20px; margin-top: 12px; font-size: 14px; }
#uploadDialog .status.err { color: #b3261e; }
#uploadDialog .status.ok { color: #1b6e3c; }
#uploadDialog .trap { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
#uploadDialog .btn[disabled] { opacity: 0.6; cursor: progress; }

/* ---------- individual ad page ---------- */
.adpage { max-width: 1400px; margin: 0 auto; padding: 4px 24px 24px; }
.adlayout { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 28px; align-items: start; }
.adhead { margin: 8px 0 20px; }
.adhead h1 { font: 800 clamp(34px, 5.4vw, 64px)/1.04 var(--display); letter-spacing: -0.03em; margin: 0; overflow-wrap: anywhere; }
.adhead .kredit { font: 600 clamp(22px, 3vw, 34px)/1.2 var(--display); color: #c9cdea; margin: 8px 0 0; }
.adimg { background: var(--stage-2); border-radius: var(--radius); padding: 10px; display: grid; place-items: center; }
.adimg img { width: auto; height: auto; max-width: 100%; max-height: 78vh; border-radius: 8px; display: block; background: #000; }
.credits { background: var(--stage-2); border-radius: var(--radius); padding: 16px 18px; font-size: 13px; line-height: 1.65; color: #d7daf0; }
.credits p { margin: 0 0 10px; }
.credits p:last-child { margin-bottom: 0; }
.credits b { color: #fff; font-weight: 600; }
.credits .empty-note { color: #9aa0c8; }
.adlinks { display: flex; flex-wrap: wrap; gap: 18px; margin-top: 16px; font-size: 14px; color: #b9bedc; }
.adlinks a, .adlinks button { color: inherit; background: none; border: 0; padding: 0; font: inherit; cursor: pointer; text-decoration: underline; }
@media (max-width: 860px) {
  .adpage { padding: 0 16px 20px; }
  .adlayout { grid-template-columns: 1fr; gap: 16px; }
  .adimg img { max-height: 60vh; }
}

/* ---------- ranking rows: title + kredit ---------- */
.info .t { font-size: 18px; }
.info .t a { text-decoration: none; }
.info .t a:hover { text-decoration: underline; text-underline-offset: 3px; }
.info .kr { color: var(--muted); font-size: 15px; }

/* ---------- admin page ---------- */
.adm { display: grid; gap: 14px; margin: 18px 0; }
.adm .card { display: grid; grid-template-columns: 220px 1fr; gap: 16px; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; }
.adm .card img { width: 100%; border-radius: 8px; display: block; background: #dfe2ee; }
.adm .card h3 { margin: 0; font: 700 20px var(--display); }
.adm .card p { margin: 4px 0; font-size: 14px; color: var(--muted); }
.adm .actions { display: flex; gap: 10px; margin-top: 10px; }
.adm .btn.no { background: #fff; color: #b3261e; border: 2px solid #b3261e; }
.keybox { display: flex; gap: 10px; flex-wrap: wrap; margin: 12px 0; }
.keybox input { flex: 1; min-width: 220px; padding: 10px; border: 1px solid var(--line); border-radius: 8px; font: inherit; }
.keybox .btn { color: var(--marigold-ink); }
@media (max-width: 600px) { .adm .card { grid-template-columns: 1fr; } }

/* ---------- v2 fixes ---------- */
.adpage { width: 100%; }
.foot { padding-right: 170px; }
@media (max-width: 760px) { .foot { padding-right: 0; flex-direction: column; } }

/* ---------- judges: register + CJIQ ---------- */
.nav a.nav-join { background: var(--marigold); color: var(--marigold-ink); }
.nav a.nav-join:hover { filter: brightness(1.05); }
.cj { max-width: 640px; }
.cj .lede { font-size: 18px; color: var(--muted); margin: 4px 0 22px; }
.cj .panel { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; margin-bottom: 18px; }
.cj .panel h2 { font: 700 22px/1.2 var(--display); margin: 0 0 10px; letter-spacing: -0.01em; }
.cj label { display: block; font-weight: 600; font-size: 14px; margin: 12px 0 4px; }
.cj input[type=text], .cj input[type=email] { width: 100%; padding: 11px 12px; border: 1px solid var(--line); border-radius: 8px; font: inherit; background: #fff; }
.cj .check { display: flex; gap: 10px; align-items: flex-start; font-weight: 400; font-size: 14px; margin: 16px 0; }
.cj .check input { margin-top: 4px; width: 18px; height: 18px; flex: none; }
.cj .msg { min-height: 1.4em; margin: 10px 0 0; font-size: 14px; color: #b3261e; }
.cj .msg.ok { color: #1f6b3a; }
.cj .small { font-size: 14px; color: var(--muted); }
.cj .code { display: block; font: 600 18px/1.4 ui-monospace, Menlo, Consolas, monospace; background: var(--paper); border: 1px dashed var(--muted); border-radius: 8px; padding: 12px; overflow-wrap: anywhere; user-select: all; margin: 10px 0; }
.cj .btn { margin-top: 6px; }
.cj .btn.plain { background: transparent; color: var(--ink); border: 2px solid var(--ink); }
.cj .btn.danger { background: #fff; color: #b3261e; border: 2px solid #b3261e; }
.score { text-align: center; background: var(--stage); color: #fff; border-radius: var(--radius); padding: 28px 18px 24px; margin-bottom: 18px; }
.score .num { font: 800 clamp(72px, 22vw, 128px)/1 var(--display); letter-spacing: -0.04em; color: var(--marigold); }
.score .cap { font: 700 18px var(--display); letter-spacing: .08em; text-transform: uppercase; opacity: .9; }
.score .tag { display: inline-block; margin-top: 10px; font-size: 13px; background: rgba(255,255,255,.14); padding: 4px 12px; border-radius: 999px; }
.score .wait { font-size: 18px; max-width: 30em; margin: 10px auto 0; }
.meter { margin: 14px 0; }
.meter .row { display: flex; justify-content: space-between; font-weight: 600; font-size: 15px; }
.meter .track { height: 12px; background: var(--paper); border-radius: 999px; overflow: hidden; margin-top: 6px; border: 1px solid var(--line); }
.meter .fill { height: 100%; background: var(--marigold); border-radius: 999px; }
.meter .fill.alt { background: var(--stage-2); }
.meter p { margin: 4px 0 0; font-size: 13px; color: var(--muted); }
.cj ul.plainlist { padding-left: 20px; margin: 8px 0; }
.cj .actions { display: flex; flex-wrap: wrap; gap: 10px; }
@media (prefers-reduced-motion: no-preference) { .meter .fill { transition: width .6s ease; } }

.jt { width: 100%; border-collapse: collapse; font-size: 14px; background: #fff; border: 1px solid var(--line); }
.jt th, .jt td { text-align: left; padding: 8px 10px; border-bottom: 1px solid var(--line); overflow-wrap: anywhere; }
.jt th { background: var(--paper); }
.cj a.btn { text-decoration: none; display: inline-block; }


/* ---------- newer pages, in the original style ---------- */
:root {
  --cocoa: var(--ink); --white: #fff; --soft: #fff4d6; --yellow: var(--marigold); --yellow-deep: var(--marigold);
  --red: #b3261e; --blue: var(--stage); --blue-deep: var(--stage-2);
  --edge: 1px solid var(--line); --pop: 0 1px 2px rgba(30,33,64,.08);
}
/* Misc.: its own small-print box that grows to hold all the text, scrolls only if it is enormous */
.miscbox { margin-top: 18px; background: #fff; color: var(--ink); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 16px 16px; }
.miscbox h2 { font: 700 15px/1.2 var(--display); margin: 0 0 8px; color: var(--ink); }
.miscbox .misc-text { font-size: 13px; line-height: 1.55; white-space: pre-line; overflow-wrap: anywhere; max-height: 68vh; overflow-y: auto; padding-right: 6px; color: var(--muted); }
.miscbox[data-size="long"] .misc-text { font-size: 12px; line-height: 1.5; }
.miscbox[data-size="huge"] .misc-text { font-size: 11.5px; line-height: 1.45; }
.miscbox .misc-text p { margin: 0 0 0.8em; }
.adlayout { grid-template-columns: minmax(0, 1fr) minmax(300px, 380px); }
@media (max-width: 860px) { .adlayout { grid-template-columns: 1fr; } }
.jt th { background: var(--paper); }
.music .mhead { background: var(--stage); color: #fff; }
.music .mhead b { font-weight: 700; }
.clock-num, .why-seq { font-family: var(--body); }
.clock-num { background: var(--marigold); color: var(--marigold-ink); font-weight: 700; }
.clock.late .clock-num { background: var(--red); color: #fff; }

/* ---------- ranking pages (BIQ, NIQ, ...) and judges board ---------- */
.blurb { max-width: 60ch; font-size: 18px; color: var(--cocoa); background: var(--white); border: 1px solid var(--line); border-radius: 14px; padding: 10px 14px; margin: 0 0 16px; }
.rkrow { grid-template-columns: 64px 1fr auto; }
.rkrow .info .t { font: 700 24px/1.15 var(--display); letter-spacing: .01em; }
.rkrow .now { font-size: 14px; margin: 4px 0; padding: 2px 10px; border: 1px solid var(--line); border-radius: 999px; display: inline-block; background: var(--white); }
.rkrow .now.up { background: #b9f6ca; } .rkrow .now.down { background: #ffc2c9; } .rkrow .now.steady { background: var(--soft); }
.iqbadge { display: grid; justify-items: center; background: var(--blue); color: var(--white); border: 1px solid var(--line); border-radius: 16px; padding: 6px 16px 8px; box-shadow: none; min-width: 92px; }
.iqnum { font: 700 40px/1 var(--display); color: var(--yellow);   }
.iqbadge .sub { color: var(--white); font-weight: 600; font-size: 13px; }
.lockedbox { background: var(--white); border: 1px solid var(--line); border-radius: 22px; box-shadow: none; padding: 22px; max-width: 560px; }
.lockedbox h2 { font: 700 30px/1.1 var(--display); margin: 0 0 8px; }
.lockedbox .meter { margin: 16px 0 18px; }
@media (max-width: 760px) { .rkrow { grid-template-columns: 44px 1fr; } .rkrow .iqbadge { grid-column: 1 / 3; justify-self: start; } }

/* ---------- music dock ---------- */
.music-btn { position: fixed; left: 18px; bottom: 20px; z-index: 50; background: var(--white); color: var(--cocoa); border: 1px solid var(--line); border-radius: 999px; box-shadow: none; font: 600 15px var(--body); padding: 11px 18px; cursor: pointer; }
.music-btn:hover { background: var(--soft); }
.music-btn[aria-expanded="true"] { background: var(--yellow); }
.music { position: fixed; left: 18px; bottom: 78px; z-index: 60; width: min(360px, calc(100vw - 36px)); background: var(--white); color: var(--cocoa); border: 1px solid var(--line); border-radius: 20px; box-shadow: none; overflow: hidden; }
.music[hidden] { display: none; }
.music .mhead { display: flex; justify-content: space-between; align-items: center; gap: 8px; background: var(--red); color: var(--white); padding: 8px 12px; cursor: grab; border-bottom: 1px solid var(--line); touch-action: none; }
.music .mhead b { font: 700 20px var(--display);  }
.music .mhead button { background: var(--white); border: 1px solid var(--line); border-radius: 8px; font: 700 14px var(--body); cursor: pointer; padding: 1px 9px; }
.music .mbody { padding: 12px; display: grid; gap: 10px; }
.music label { font-weight: 600; font-size: 14px; }
.music input { width: 100%; border: 1px solid var(--line); border-radius: 10px; padding: 8px 10px; font: 500 14px var(--body); }
.music .mrow { display: flex; flex-wrap: wrap; gap: 8px; }
.music .btn { padding: 6px 12px; font-size: 14px; box-shadow: none; }
.music .mnote { font-size: 12.5px; color: var(--muted); margin: 0; }
.music .merr { font-size: 13px; color: var(--red); font-weight: 600; margin: 0; min-height: 1em; }
.music iframe { width: 100%; border: 0; border-radius: 12px; display: block; background: var(--white); }

.cj .mrow { display: flex; flex-wrap: wrap; gap: 10px; margin: 4px 0 6px; }
.cj .btn.plain.social, .cj #socialBtns .btn { display: inline-block; }
.cj .panel + .panel { margin-top: 18px; }
.cj .msg:empty { display: none; }
#captcha { margin: 14px 0 0; }

/* ---------- "Tell us why": arrows, own-words box, commentary recorder ---------- */
#why { margin-top: 26px; }
.why { background: var(--white); color: var(--cocoa); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: none; padding: 16px 18px 18px; }
.why-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 14px; margin-bottom: 14px; }
.why-head b { font: 700 22px/1 var(--display); letter-spacing: .01em; }
.why-seq { background: var(--red); color: #fff; font: 600 13px var(--body); padding: 3px 12px; border-radius: 999px; border: 1px solid var(--line); }
.why-hint { color: var(--muted); font-size: 14px; }
.why-saved { margin-left: auto; font-weight: 600; color: #146c2e; font-size: 14px; }

.why-arrows { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr); gap: 0; margin: 4px 0 14px;
  filter: drop-shadow(1px 0 0 var(--ink)) drop-shadow(-1px 0 0 var(--ink)) drop-shadow(0 1px 0 var(--ink)) drop-shadow(0 -1px 0 var(--ink)); }
.why-arrow { display: flex; align-items: center; gap: 8px; padding: 14px 16px; min-width: 0; }
.why-arrow.left { background: var(--yellow); padding-left: 52px; clip-path: polygon(38px 0, 100% 0, 100% 100%, 38px 100%, 0 50%); }
.why-arrow.right { background: var(--soft); padding-right: 52px; justify-content: flex-start; clip-path: polygon(0 0, calc(100% - 38px) 0, 100% 50%, calc(100% - 38px) 100%, 0 100%); margin-left: -3px; }
.why-lbl { font: 700 18px/1.1 var(--display); letter-spacing: .02em; white-space: nowrap; }
.why-lbl .narrow { display: none; }
.why-arrow input { flex: 1 1 0; min-width: 0; width: 100%; padding: 10px 12px; font: 500 15px var(--body); color: var(--cocoa); background: #fff; border: 1px solid var(--line); border-radius: 10px; }
.why-arrow input::placeholder, .why textarea::placeholder { color: #8a817a; }
.why textarea { width: 100%; resize: vertical; min-height: 84px; padding: 12px; font: 500 15px/1.45 var(--body); color: var(--cocoa); background: #fff; border: 1px solid var(--line); border-radius: 12px; }
.why-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin-top: 12px; }
.rec-btn { display: inline-flex; align-items: center; gap: 10px; background: var(--red); color: #fff; border: 1px solid var(--line); border-radius: 999px; box-shadow: none; font: 600 16px var(--body); padding: 10px 20px; cursor: pointer; }
.rec-btn:hover { transform: translateY(-2px); box-shadow: none; }
.rec-btn.on { background: var(--cocoa); animation: recpulse 1.2s ease-in-out infinite; }
@keyframes recpulse { 50% { box-shadow: 0 0 0 6px rgba(179,38,30,.3); } }
@media (prefers-reduced-motion: reduce) { .rec-btn.on { animation: none; } }
.rec-state { font-weight: 600; color: var(--red); }
.rec-box:empty { display: none; }
.rec-box { margin-top: 12px; padding: 14px; background: var(--soft); border: 1px solid var(--line); border-radius: 12px; }
.rec-note { margin: 6px 0; font-size: 14px; } .rec-note.err { color: #b3261e; font-weight: 600; }
.rec-consent .check { display: flex; gap: 10px; align-items: flex-start; font-size: 14px; margin: 10px 0; }
.rec-consent input[type=checkbox] { width: 20px; height: 20px; margin-top: 3px; flex: none; }
.rec-review audio { width: 100%; margin: 6px 0; }
.rec-review input[type=text] { width: 100%; padding: 9px 12px; border: 1px solid var(--line); border-radius: 10px; font: 500 15px var(--body); margin: 4px 0 10px; }
.rec-row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }

@media (max-width: 820px) {
  .why-arrows { grid-template-columns: 1fr; filter: none; gap: 10px; }
  .why-arrow.left, .why-arrow.right { clip-path: none; padding: 12px 14px; border: 1px solid var(--line); border-radius: 14px; margin: 0; flex-wrap: wrap; }
  .why-arrow.left::before { content: "▲"; } .why-arrow.right::before { content: "▼"; }
  .why-lbl .wide { display: none; } .why-lbl .narrow { display: inline; }
  .why-lbl { white-space: normal; }
  .why-arrow input { flex: 1 1 100%; }
}

/* ---------- commentary replay ---------- */
.rp { max-width: 1100px; margin: 0 auto; padding: 8px 24px 48px; width: 100%; }
.rp .question { margin: 8px 0 4px; }
.rp-by { margin: 0 0 14px; opacity: .9; }
.rp-banner { background: var(--soft); color: var(--cocoa); border: 1px solid var(--line); border-radius: 12px; padding: 10px 14px; font-weight: 600; }
.rp-stage { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; align-items: start; margin: 12px 0 16px; }
.rp-side { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: none; padding: 12px; color: var(--cocoa); min-width: 0; }
.rp-side.won { outline: 5px solid var(--yellow); }
.rp-img { position: relative; display: block; width: fit-content; max-width: 100%; margin: 0 auto; line-height: 0; }
.rp-img img { display: block; max-width: 100%; max-height: 56vh; width: auto; height: auto; border-radius: 8px; background: #000; }
.rp-canvas { position: absolute; left: 0; top: 0; width: 100%; height: 100%; pointer-events: none; }
.rp-pick { position: absolute; top: 8px; right: 8px; background: var(--yellow); color: var(--cocoa); border: 1px solid var(--line); border-radius: 999px; padding: 2px 12px; font: 600 13px var(--body); line-height: 1.4; }
.rp-pick[hidden] { display: none; }
.rp-cap { margin-top: 10px; line-height: 1.25; } .rp-cap .t { font: 700 20px var(--display); color: var(--cocoa); } .rp-cap .k { font-weight: 600; color: var(--blue-deep); }
.rp-controls { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; background: var(--white); color: var(--cocoa); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: none; padding: 12px 16px; }
.rp-controls[hidden] { display: none; }
.rp-controls input[type=range] { flex: 1 1 200px; accent-color: var(--red); }
.rp-clock { font-variant-numeric: tabular-nums; font-weight: 600; min-width: 5.5em; }
.rp-speed { font-weight: 600; font-size: 14px; } .rp-speed select { margin-left: 6px; padding: 4px 6px; border: 1px solid var(--line); border-radius: 8px; }
.rp-notes, .rp-words { margin-top: 20px; background: var(--white); color: var(--cocoa); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px 18px; }
.rp-notes[hidden], .rp-words[hidden] { display: none; }
.rp-notes h2, .rp-words h2 { font: 700 22px var(--display); margin: 0 0 8px; }
.rp-words ol { padding-left: 22px; margin: 0; } .rp-words li { margin: 4px 0; }
.rp-line { background: none; border: 0; padding: 4px 6px; font: 500 15px/1.4 var(--body); text-align: left; cursor: pointer; border-radius: 8px; color: inherit; }
.rp-line:hover { background: var(--soft); } li.now .rp-line { background: var(--yellow); }
.chip-s { display: inline-block; margin: 2px 6px 2px 0; padding: 1px 10px; border: 1px solid var(--line); border-radius: 999px; background: var(--soft); font-weight: 600; font-size: 13px; }
.rp-foot { margin-top: 14px; font-size: 14px; opacity: .85; }
@media (max-width: 700px) { .rp-stage { grid-template-columns: 1fr; } .rp { padding: 8px 14px 40px; } }

/* ---------- the 3-second counter ---------- */
.clock { display: inline-flex; align-items: center; gap: 12px; margin: 0 0 14px; padding: 6px 16px 6px 8px; background: var(--white); color: var(--cocoa); border: 1px solid var(--line); border-radius: 999px; box-shadow: none; font-weight: 600; font-size: 14px; }
.clock-num { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; background: var(--yellow); border: 1px solid var(--line); font: 700 24px/1 var(--display); }
.clock.late .clock-num { background: var(--red); color: #fff; }
.clock.late { background: var(--soft); }
.slow-note { background: var(--soft); color: var(--cocoa); border: 1px solid var(--line); border-radius: 12px; padding: 10px 14px; font-weight: 600; margin: 10px 0; }

.clock { align-self: flex-start; }

/* ---------- faint words from other judges ---------- */
.side { position: relative; }
.wc, .wc-pair { color: #bbb; opacity: 0.3; font-size: 0.85rem; line-height: 1.6; pointer-events: none; user-select: none; }
.wc { display: flex; flex-wrap: wrap; gap: 2px 10px; margin-top: 6px; }
.wc-pair { text-align: center; margin-top: 10px; }
@media (min-width: 1100px) {
  .arena { margin: 0 150px; }
  .wc { position: absolute; top: 40%; width: 140px; flex-direction: column; flex-wrap: nowrap; gap: 0; margin: 0; }
  .wc-l { right: 100%; margin-right: 18px; text-align: right; align-items: flex-end; }
  .wc-r { left: 100%; margin-left: 18px; text-align: left; align-items: flex-start; }
}
