/* The live game page. Colour tokens from the Reborn launcher (crates/reborn-ui/ui/finish.css). */
/* The live card's fonts (the bot's PNG card draws with the same two). webRouter.js names both files by content hash. */
@font-face { font-family: "Inter NSR"; src: url("/live-assets/InterVariable.woff2?v=693b77d4f32e") format("woff2"); font-weight: 100 900; font-display: swap; }
@font-face { font-family: "Anton NSR"; src: url("/live-assets/Anton-Regular.ttf?v=a4ba3a92350e") format("truetype"); font-weight: 400; font-display: swap; }
:root {
  color-scheme: dark;
  --bg: #212220; --panel: #292a27; --fg: #f0f0eb; --muted: #a5a69e; --line: #ffffff12;
  --control-bg: #30322c; --control-border: #484a41; --panel-border: #424638;
  --selected-bg: #412b2d; --focus: #ef969b; --accent: #ce414a; --accent-border: #82454b;
  /* The accent as TEXT: the same red, lifted to 4.9:1 on --panel and 5.4:1 on --bg (WCAG AA). */
  --accent-text: #ec7078;
  --gold: #e6b84c;
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  background: var(--bg); color: var(--fg);
  font: 15px/1.45 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  max-width: 820px; margin: 0 auto; padding: 16px;
}
button { font: inherit; color: inherit; }
button:focus-visible, .panel:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }

/* Scoreboard */
.board { background: var(--panel); border: 1px solid var(--panel-border); border-radius: 10px; padding: 14px 16px; }
.loading, .empty { color: var(--muted); margin: 8px 0; }
.teams { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
/* A seat: [ident, points]. `ident` is the team (logo + name) with the seat's avatar + name beneath, or just the seat when no
   team is known. Team colours come from /live-assets/teams.css (.tg-<tgid> sets --team / --team-ink); the defaults
   below stand in when a team has none. A team colour is only ever a BACKGROUND, and text on it is always its ink. */
.team {
  --team: var(--control-bg); --team-ink: var(--fg); --team2: var(--control-border); --team2-ink: var(--fg);
  position: relative; display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 10px; min-width: 0;
}
.team.has-team { padding-top: 10px; }
/* The bar: the primary colour with a stripe of the secondary (two navy teams, e.g. Giants and Colts, still differ). */
.team-bar { position: absolute; left: 0; right: 0; top: 0; height: 5px; border-radius: 2px; background: linear-gradient(90deg, var(--team) 0 72%, var(--team2) 72% 100%); }
.team.seat1 .team-bar { background: linear-gradient(90deg, var(--team2) 0 28%, var(--team) 28% 100%); }
.ident { display: grid; gap: 6px; min-width: 0; }
.team-id, .seat-id { display: flex; align-items: center; gap: 10px; min-width: 0; }
.logo { width: 56px; height: 56px; object-fit: contain; flex: none; }
.teambadge {
  display: inline-flex; align-items: center; justify-content: center; flex: none; width: 56px; height: 56px; border-radius: 8px;
  font-weight: 800; letter-spacing: .04em; background: var(--team); color: var(--team-ink);
}
.team-name { font-size: 20px; font-weight: 800; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.has-team .seat-id .avatar { width: 28px; height: 28px; font-size: 12px; }
.has-team .seat-id .name { font-weight: 500; color: var(--muted); }
/* Seat 1 mirrors seat 0 (score, then who), so the two scores meet in the middle. */
.team.seat1 .points { order: -1; }
.team.seat1 .team-id, .team.seat1 .seat-id { flex-direction: row-reverse; }
.team.seat1 .name, .team.seat1 .team-name { text-align: right; }
.avatar { width: 48px; height: 48px; border-radius: 50%; background: var(--control-bg); object-fit: cover; flex: none; }
.avatar.blank { display: inline-flex; align-items: center; justify-content: center; font-weight: 700; color: var(--muted); border: 1px solid var(--control-border); }
.name { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.points { font-size: 34px; font-weight: 800; font-variant-numeric: tabular-nums; }
.meta { display: flex; flex-wrap: wrap; gap: 6px 14px; margin-top: 10px; color: var(--muted); font-size: 13px; }
.status { font-weight: 700; text-transform: uppercase; letter-spacing: .06em; }
.status.live { color: var(--accent-text); }
.status.live::before { content: ""; display: inline-block; width: 8px; height: 8px; margin-right: 6px; border-radius: 50%; background: var(--accent); vertical-align: 1px; }
.status.done { color: var(--fg); }
.situation { margin-top: 8px; font-weight: 600; }
.side-score { margin-top: 8px; font-size: 20px; font-weight: 800; font-variant-numeric: tabular-nums; }
/* Neither side's seat is known: the seats show by position, not claiming a side. */
.sides-note { margin-top: 6px; font-size: 12px; color: var(--muted); }
/* The polite live region: read out by screen readers (the newest play only), not shown; the play list shows it. */
.latest { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }

/* Game picker and tabs */
.games, .tabs { display: flex; gap: 6px; margin-top: 12px; overflow-x: auto; }
.games[hidden] { display: none; }
.games button, .tabs button {
  background: var(--control-bg); border: 1px solid var(--control-border); border-radius: 6px;
  padding: 7px 12px; cursor: pointer; white-space: nowrap;
}
.games button[aria-pressed="true"], .tabs button[aria-selected="true"] { background: var(--selected-bg); border-color: var(--accent-border); }
.panel { margin-top: 12px; }
.panel[hidden] { display: none; }
.label { color: var(--muted); font-size: 12px; text-transform: uppercase; letter-spacing: .06em; margin: 4px 0 8px; }

/* Plays */
.plays { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.play { background: var(--panel); border: 1px solid var(--line); border-left: 3px solid var(--control-border); border-radius: 8px; padding: 9px 12px; }
.play.score { border-left-color: var(--gold); }
.play.turnover { border-left-color: var(--accent); }
.play.disputed { border-style: dashed; }
.play-top { display: flex; gap: 10px; color: var(--muted); font-size: 12px; }
.play-top .after { margin-left: auto; font-variant-numeric: tabular-nums; color: var(--fg); }
.play .text { margin-top: 3px; overflow-wrap: anywhere; }
/* A big play's portrait: the player beside the card's text. */
.play.has-portrait { display: grid; grid-template-columns: 48px minmax(0, 1fr); column-gap: 12px; align-items: start; }
.play.has-portrait > :not(.portrait) { grid-column: 2; }
.play .portrait { grid-column: 1; grid-row: 1 / span 3; width: 48px; height: 48px; border-radius: 50%; object-fit: cover; background: var(--control-bg); }
.play.has-portrait .badge { justify-self: start; }
.play.score .text { font-weight: 700; }
.badge { display: inline-block; margin-top: 6px; padding: 1px 7px; border-radius: 999px; font-size: 11px; text-transform: uppercase; letter-spacing: .05em; }
.badge.disputed { color: var(--focus); border: 1px solid var(--accent-border); }

/* Tables */
.box { display: grid; gap: 14px; overflow-x: auto; }
.stat { width: 100%; border-collapse: collapse; background: var(--panel); border-radius: 8px; overflow: hidden; font-variant-numeric: tabular-nums; }
.stat caption { text-align: left; font-weight: 700; padding: 0 0 6px; }
.stat th, .stat td { padding: 6px 8px; text-align: right; border-bottom: 1px solid var(--line); }
.stat th { color: var(--muted); font-size: 12px; font-weight: 600; }
.stat .who, .stat .side-col { text-align: left; }
.stat td.side-col { color: var(--muted); white-space: nowrap; }
.stat td.who { overflow-wrap: break-word; }
.stat .face { width: 28px; height: 28px; border-radius: 50%; object-fit: cover; background: var(--control-bg); vertical-align: middle; margin-right: 8px; }
.stat tr.t1 td.who { color: var(--muted); }
.stat tr.score td:last-child { color: var(--gold); }
.stat tr.turnover td:last-child { color: var(--accent-text); }

footer { display: flex; justify-content: space-between; gap: 12px; margin-top: 18px; color: var(--muted); font-size: 12px; }
/* /games/:id's footer link ("Live now"): no link anywhere else in this page is styled, so without this an <a> falls
   back to the browser's default link colour instead of the footer's muted grey. */
footer a.note { color: inherit; }

/* The "No such match" page */
body.missing main { padding: 40px 0; }
body.missing h1 { font-size: 22px; }

@media (max-width: 480px) {
  body { padding: 12px; font-size: 14px; }
  .teams { gap: 8px; }
  .team { gap: 6px; }
  .avatar { width: 32px; height: 32px; }
  .logo, .teambadge { width: 36px; height: 36px; }
  .teambadge { font-size: 12px; }
  .team-name { font-size: 15px; }
  .team-id, .seat-id { gap: 6px; }
  .has-team .seat-id .avatar { width: 20px; height: 20px; font-size: 10px; }
  .has-team .seat-id .name { font-size: 12px; }
  .stat .face { width: 20px; height: 20px; margin-right: 5px; }
  .points { font-size: 26px; }
  .stat { font-size: 13px; }
  .stat td.side-col { max-width: 6.5em; overflow: hidden; text-overflow: ellipsis; }
  .stat th, .stat td { padding: 5px 4px; }
}

/* /live: the index of running matches */
.index-title { margin: 0; font-size: 1.4rem; }
.index-list { list-style: none; margin: 0; padding: 0; }
.index-list .empty { padding: 1rem; opacity: .8; }
.index-row { border-bottom: 1px solid rgba(255,255,255,.12); }
.index-link { display: flex; align-items: center; gap: .75rem; padding: .75rem 1rem; color: inherit; text-decoration: none; }
.index-link:hover, .index-link:focus-visible { background: rgba(255,255,255,.06); }
.index-team { display: flex; align-items: center; gap: .5rem; min-width: 8rem; }
.index-abbrev { display: inline-block; min-width: 2.6rem; text-align: center; padding: .15rem .35rem; border-radius: .3rem; font-weight: 700; background: #333; color: #fff; }
.index-logo { width: 32px; height: 32px; object-fit: contain; flex: none; }
.index-avatar { width: 32px; height: 32px; border-radius: 50%; object-fit: cover; flex: none; }
.index-initial { display: inline-flex; align-items: center; justify-content: center; width: 32px; height: 32px; border-radius: 50%; flex: none; font-weight: 700; color: var(--muted); border: 1px solid var(--control-border); }
.index-score { font-weight: 700; font-variant-numeric: tabular-nums; min-width: 4.5rem; text-align: center; }
.index-meta { margin-left: auto; opacity: .8; font-size: .9rem; }

/* ---- The live card and the final card: the bot's approved 640x360 PNG cards as DOM + CSS (live-render.js). ----
   Every design size is N x --u, where --u is 1px at 640 wide and shrinks with the card (it is never bigger: on a wide
   page the card's bands stretch, its contents stay at design size). --u is declared on the card's children, so 100cqw
   is the card's own width (.lc is the size container). Font sizes have floors, so text stays readable at 340 px;
   band heights are min-heights, so text that grows never clips. The ruler's vertical sizes are plain px (its labels
   are 12 px at every width). Positions (--x, --w) and colours (--bg0.., --a0.., --cap-a/b, --row, ...) are set by
   live-render.js through CSSOM only; the values below are fallbacks. */
.lc {
  container-type: inline-size; aspect-ratio: auto; border-radius: 18px; overflow: hidden; position: relative;
  color: #ffffff; font-family: "Inter NSR", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; line-height: 1.2;
  -webkit-font-smoothing: antialiased;
  --bg0: #2a2b2f; --bg1: #1a1b1e; --bg2: #0f1012; --a0: #3a3c42; --a1: #2c2d32; --a2: #2c2d32; --a3: #3a3c42;
  --face0: #45474e; --face1: #27282c; --badge: #1a1b1e; --soft: #d9dadf; --muted: #a2a5ac; --label: #c8c9ce; --line: #e4e5e8;
  background: linear-gradient(160deg, var(--bg0) 0%, var(--bg1) 45%, var(--bg2) 100%);
}
.lc > * { --u: min(1px, calc(100cqw / 640)); }
.lc b { font-weight: 600; }
/* M1: Anton ships one weight; `.lc b` (0,1,1) must not make the browser fake a bold on the <b> score numbers. */
.lc .lc-pts, .lc .fc-s { font-weight: 400; font-synthesis: none; }

/* Band 1: the score */
.lc-score {
  display: flex; align-items: center; justify-content: space-between; gap: calc(12 * var(--u));
  min-height: calc(84 * var(--u)); padding: calc(8 * var(--u)) calc(30 * var(--u));
  background: linear-gradient(90deg, var(--a0) 0%, var(--a1) 45%, var(--a2) 55%, var(--a3) 100%);
}
.lc-side { display: flex; align-items: center; gap: calc(14 * var(--u)); flex: 1 1 0; min-width: 0; }
.lc-side.b { justify-content: flex-end; }
.lc-side .logo, .lc-side .teambadge { width: max(28px, calc(46 * var(--u))); height: max(28px, calc(46 * var(--u))); flex: none; }
.lc .logo { object-fit: contain; }
/* A team with no usable logo: the abbrev in a circle of its card colour (the bot's fallback). */
.lc .teambadge { border-radius: 50%; background: var(--tb, #3a3c42); color: #ffffff; font-size: max(10px, calc(14 * var(--u))); font-weight: 800; letter-spacing: 0; }
.lc-pts { font-family: "Anton NSR", Impact, sans-serif; font-weight: 400; font-size: max(30px, calc(56 * var(--u))); line-height: 1; font-variant-numeric: tabular-nums; }
.lc-side.trailing .lc-pts { color: rgba(255, 255, 255, .5); }
.lc-mid { display: flex; flex-direction: column; align-items: center; text-align: center; flex: none; }
.lc-live, .lc-final { display: inline-flex; align-items: center; gap: calc(6 * var(--u)); font-weight: 700; font-size: max(12px, calc(13 * var(--u))); letter-spacing: .04em; }
.lc-live { color: #ff453a; }
.lc-live::before { content: ""; width: max(6px, calc(7 * var(--u))); height: max(6px, calc(7 * var(--u))); border-radius: 50%; background: currentColor; }
.lc-final { color: #ffffff; }
.lc-sub { margin-top: calc(4 * var(--u)); font-weight: 500; font-size: max(12px, calc(14 * var(--u))); color: var(--muted); white-space: nowrap; }
/* An unofficial close (live or "Between games"): a small grey tag under the sub line, like the bot's card. */
.lc-uo { margin-top: calc(2 * var(--u)); font-weight: 700; font-size: max(9px, calc(10 * var(--u))); letter-spacing: .12em; color: var(--muted); white-space: nowrap; }

/* Band 2: the play */
.lc-play {
  display: flex; align-items: center; gap: calc(22 * var(--u)); min-height: calc(148 * var(--u)); padding: calc(14 * var(--u)) calc(30 * var(--u));
  border-top: 1px solid rgba(255, 255, 255, .08); border-bottom: 1px solid rgba(255, 255, 255, .08);
}
.lc-av { position: relative; flex: none; width: max(56px, calc(104 * var(--u))); height: max(56px, calc(104 * var(--u))); }
.lc-face {
  width: 100%; height: 100%; border-radius: 50%; overflow: hidden; display: flex; align-items: center; justify-content: center;
  background: radial-gradient(circle at 50% 40%, var(--face0) 0%, var(--face1) 72%); box-shadow: 0 0 0 max(2px, calc(3 * var(--u))) rgba(255, 255, 255, .12);
}
.lc-portrait { width: 100%; height: 100%; object-fit: cover; display: block; }
.lc-face .lc-facelogo { width: 61.5%; height: 61.5%; }
.lc-badge { position: absolute; right: -1.9%; bottom: 0; width: 32.7%; height: 32.7%; border-radius: 50%; background: var(--badge); display: flex; align-items: center; justify-content: center; }
.lc-badge .logo { width: 73.5%; height: 73.5%; }
.lc-txt { display: flex; flex-direction: column; min-width: 0; }
.lc-res { font-weight: 700; font-size: max(12px, calc(12 * var(--u))); letter-spacing: .1em; color: #7dffb0; margin-bottom: calc(8 * var(--u)); }
.lc-res.muted { color: var(--muted); }
.lc-hl { font-weight: 800; font-size: max(18px, calc(34 * var(--u))); letter-spacing: -.03em; line-height: 1.05; overflow-wrap: anywhere; }
.lc-l1 { margin-top: calc(10 * var(--u)); display: flex; flex-wrap: wrap; align-items: baseline; font-weight: 500; font-size: max(13px, calc(16 * var(--u))); color: var(--soft); }
.lc-name { color: #ffffff; font-weight: 600; margin-right: calc(10 * var(--u)); }
.lc-seg b { color: #ffffff; }
.lc-seg span { margin-left: .28em; }
.lc-seg + .lc-seg::before { content: "·"; color: #4a4d54; margin: 0 calc(7 * var(--u)); }
.lc-l2 { margin-top: calc(5 * var(--u)); font-weight: 500; font-size: max(13px, calc(14 * var(--u))); color: var(--muted); max-width: calc(440 * var(--u) + 30%); overflow-wrap: anywhere; }
.lc-l2 b { color: #c9cbd0; }
.lc-wait { justify-content: center; }
.lc-wait .lc-hl { font-size: max(18px, calc(26 * var(--u))); color: var(--soft); }

/* Band 3: the situation and the yard ruler (offense on the left) */
.lc-sit { padding: calc(16 * var(--u)) calc(30 * var(--u)) calc(12 * var(--u)); min-height: calc(128 * var(--u)); }
.lc-sh { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 4px calc(12 * var(--u)); }
.lc-dn { font-weight: 700; font-size: max(13px, calc(17 * var(--u))); }
.lc-spot { margin-left: .28em; font-weight: 500; color: var(--soft); }
.lc-dr { font-weight: 500; font-size: max(12px, calc(14 * var(--u))); color: var(--muted); }
.lc-dr b { color: #ffffff; }
.lc-rul { position: relative; height: 62px; margin-top: calc(6 * var(--u)); }
.lc-rul > * { position: absolute; }
.lc-trk { left: 0; right: 0; top: 26px; height: 8px; border-radius: 4px; background: rgba(255, 255, 255, .12); }
.lc-cap { top: 26px; height: 8px; width: 6%; }
.lc-cap.a { left: 0; border-radius: 4px 0 0 4px; background: var(--cap-a, #3a3c42); }
.lc-cap.b { right: 0; border-radius: 0 4px 4px 0; background: var(--cap-b, #3a3c42); }
.lc-drv { top: 26px; height: 8px; left: var(--x); width: var(--w); border-radius: 4px; background: rgba(255, 255, 255, .35); }
.lc-tick { top: 22px; width: 1px; height: 16px; left: var(--x); transform: translateX(-50%); background: rgba(255, 255, 255, .18); }
.lc-tick.mid { top: 20px; height: 20px; background: #5a5d64; }
.lc-st { top: 25px; left: var(--x); width: 10px; height: 10px; border-radius: 50%; transform: translateX(-50%); background: var(--badge); box-shadow: inset 0 0 0 2px rgba(255, 255, 255, .5); }
.lc-fd { top: 16px; left: var(--x); width: 3px; height: 28px; border-radius: 2px; transform: translateX(-50%); background: #ffd60a; }
.lc-fl { top: 0; left: var(--x); font-weight: 700; font-size: 12px; line-height: 1.2; color: #ffd60a; white-space: nowrap; }
.lc-ball { top: 20px; left: var(--x); width: 20px; height: 20px; border-radius: 50%; transform: translateX(-50%); background: #ffffff; box-shadow: 0 0 0 4px rgba(255, 255, 255, .12); }
.lc-lb { top: 44px; left: var(--x); font-weight: 600; font-size: 12px; line-height: 1.2; color: var(--muted); white-space: nowrap; }
.lc-lb.strong { color: #ffffff; font-weight: 700; }
.lc-fl.center, .lc-lb.center { transform: translateX(-50%); }
.lc-fl.left { transform: translateX(-2px); }
.lc-fl.right { transform: translateX(calc(-100% + 2px)); }
.lc-lb.right { transform: translateX(-100%); }
/* The core spaced the labels for a 580 px track at 12 px text; on a narrower card the text stays 12 px, so only the
   end labels and the ball's spot are kept (nothing may overlap). */
@container (max-width: 560px) {
  .lc-lb:not(.strong):not(.end), .lc-lb.end.near { display: none; }
}

/* The final card: the scorebug, then the winner's leaders beside the team bars */
.lc[data-kind="final"] { background: linear-gradient(160deg, var(--bg0) 0%, var(--bg1) 50%, var(--bg2) 100%); }
.fc-head, .fc-row { display: grid; grid-template-columns: minmax(0, 1fr) repeat(var(--n, 3), calc(66 * var(--u))) calc(96 * var(--u)); align-items: center; }
.fc-head {
  margin: calc(18 * var(--u)) calc(20 * var(--u)) 0; padding: 0 calc(18 * var(--u)) calc(8 * var(--u));
  font-weight: 700; font-size: max(12px, calc(11 * var(--u))); letter-spacing: .12em; color: var(--label);
}
.fc-hl { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.fc-gh, .fc-sh { justify-self: center; white-space: nowrap; }
.fc-row {
  margin: 0 calc(20 * var(--u)) calc(6 * var(--u)); min-height: calc(64 * var(--u)); padding: calc(4 * var(--u)) calc(18 * var(--u));
  border-radius: max(8px, calc(14 * var(--u))); color: rgba(255, 255, 255, .72);
  background: color-mix(in srgb, var(--row, #3a3c42) 60%, transparent);
}
.fc-row.win { color: #ffffff; background: var(--row, #3a3c42); }
.fc-team { display: flex; align-items: center; gap: calc(14 * var(--u)); min-width: 0; }
.fc-team .logo, .fc-team .teambadge { width: max(24px, calc(44 * var(--u))); height: max(24px, calc(44 * var(--u))); flex: none; }
.fc-name { font-weight: 800; font-size: max(13px, calc(25 * var(--u))); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.fc-g { justify-self: center; font-weight: 700; font-size: max(13px, calc(24 * var(--u))); font-variant-numeric: tabular-nums; }
.fc-g.na { opacity: .45; }
.fc-s { justify-self: center; font-family: "Anton NSR", Impact, sans-serif; font-weight: 400; font-size: max(30px, calc(52 * var(--u))); line-height: 1; font-variant-numeric: tabular-nums; }
/* The forfeit note ("<name> left the series"): a fixed neutral grey (--note, set from the NEUTRAL palette), never
   the winner's team-tinted label, so it reads the same regardless of which side won. */
.fc-note { margin-top: calc(2 * var(--u)); padding: 0 calc(38 * var(--u)); font-weight: 500; font-size: max(12px, calc(13 * var(--u))); color: var(--note, var(--muted)); }
.fc-bot { display: flex; align-items: stretch; margin: calc(12 * var(--u)) calc(20 * var(--u)) calc(18 * var(--u)); padding: 0 calc(2 * var(--u)); }
.fc-pls { display: flex; flex-direction: column; justify-content: space-around; flex: 0 1 auto; min-width: 0; }
.fc-p { display: flex; align-items: center; gap: calc(10 * var(--u)); min-height: calc(30 * var(--u)); min-width: 0; }
.fc-hs {
  width: max(22px, calc(26 * var(--u))); height: max(22px, calc(26 * var(--u))); border-radius: 50%; overflow: hidden; flex: none;
  display: flex; align-items: center; justify-content: center; background: radial-gradient(circle at 50% 40%, var(--face0) 0%, var(--face1) 100%);
}
.fc-hs .portrait { width: 100%; height: 100%; object-fit: cover; }
.fc-hs .logo { width: 69%; height: 69%; }
.fc-ln { font-weight: 500; font-size: max(13px, calc(14 * var(--u))); color: var(--line); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.fc-ln b { color: #ffffff; }
.fc-div { flex: none; width: 1px; margin: 0 calc(24 * var(--u)); background: rgba(255, 255, 255, .1); }
.fc-bars {
  flex: 1 1 auto; display: grid; grid-template-columns: max-content max-content 1fr max-content;
  column-gap: calc(12 * var(--u)); row-gap: calc(8 * var(--u)); align-content: space-around; align-items: center;
}
.fc-bl { font-weight: 500; font-size: max(12px, calc(13 * var(--u))); color: var(--label); }
.fc-bx, .fc-by { font-weight: 600; font-size: max(13px, calc(14 * var(--u))); font-variant-numeric: tabular-nums; }
.fc-bx { text-align: right; }
.fc-by { color: var(--line); }
.fc-tr { display: flex; height: 6px; border-radius: 3px; overflow: hidden; min-width: max(40px, calc(60 * var(--u))); }
.fc-tr i { display: block; flex-grow: var(--f, 1); flex-basis: 0; }
.fc-tr .a { background: var(--bar-a, #a2a5ac); }
.fc-tr .b { background: var(--bar-b, #5a5d64); }

/* Phone width: band 2 stacks (headshot above the text) and the final card's leaders sit above its bars. */
@media (max-width: 480px) {
  .lc-play { flex-direction: column; align-items: flex-start; gap: 12px; }
  .fc-bot { flex-direction: column; gap: 12px; }
  .fc-div { width: auto; height: 1px; margin: 0; }
  .fc-head { letter-spacing: .06em; }
}

/* ---- The live page around the card (plan task 18, R18/R25): the names line, the card, then the play feed. ---- */
.card-names { margin: 0 0 8px; font-weight: 600; color: var(--muted); overflow-wrap: anywhere; }
.card-names:empty { display: none; }
.card-slot { display: block; }
.card-slot > .lc { margin: 0; }
/* The feed: every play of the picked game, newest first, as small copies of the card's play band. On a desktop it
   scrolls inside itself so the picker and the tabs stay near the card, and while rows remain below it fades out at
   the bottom (live card M8), so the cut row reads as intended. On a phone (below) it is part of the page instead. */
.feed-slot { position: relative; margin-top: 12px; max-height: min(72vh, 640px); overflow-y: auto; border-radius: 12px; }
.feed-slot.more-below {
  -webkit-mask-image: linear-gradient(to bottom, #000 calc(100% - 64px), transparent);
  mask-image: linear-gradient(to bottom, #000 calc(100% - 64px), transparent);
}
.feed-more { display: none; }
.feed-slot:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
.feed { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; font-family: "Inter NSR", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; }
.fr {
  display: grid; grid-template-columns: 40px minmax(0, 1fr); column-gap: 12px; align-items: start;
  background: var(--panel); border: 1px solid var(--line); border-left: 3px solid var(--control-border); border-radius: 10px; padding: 10px 12px;
}
.fr.score { border-left-color: var(--gold); }
.fr.turnover { border-left-color: var(--accent); }
.fr.disputed { border-style: dashed; }
.fr-av {
  width: 40px; height: 40px; border-radius: 50%; overflow: hidden; display: flex; align-items: center; justify-content: center;
  background: radial-gradient(circle at 50% 40%, #45474e 0%, #27282c 72%);
}
.fr-av .portrait { width: 40px; height: 40px; object-fit: cover; display: block; }
.fr-av .logo { width: 28px; height: 28px; object-fit: contain; }
.fr-av .teambadge { width: 40px; height: 40px; border-radius: 50%; font-size: 11px; }
.fr-txt { display: flex; flex-direction: column; min-width: 0; line-height: 1.3; }
.fr-res { font-weight: 700; font-size: 11px; letter-spacing: .1em; color: #7dffb0; margin-bottom: 2px; }
.fr-res.muted { color: var(--muted); }
.fr-hl { font-weight: 800; font-size: 17px; letter-spacing: -.01em; overflow-wrap: anywhere; }
.fr-l1 { margin-top: 3px; display: flex; flex-wrap: wrap; align-items: baseline; font-weight: 500; font-size: 14px; color: #d9dadf; }
.fr-name { color: #ffffff; font-weight: 600; margin-right: 8px; }
.fr-seg b { color: #ffffff; font-weight: 600; }
.fr-seg span { margin-left: .28em; }
.fr-seg + .fr-seg::before { content: "·"; color: #6a6d74; margin: 0 6px; }
.fr-l2 { margin-top: 2px; font-weight: 500; font-size: 13px; color: var(--muted); overflow-wrap: anywhere; }
.fr-l2 b { color: #c9cbd0; font-weight: 600; }
.fr .badge { justify-self: start; align-self: flex-start; }
/* Phone width: the player's name takes its own line and each stat keeps its words together, so a wrapped stat
   never starts a line with its "·" separator. */
@media (max-width: 480px) {
  /* Live card M8: no scroll box inside the page. The newest 8 rows, then "Show all N plays" expands in place. */
  .feed-slot { max-height: none; overflow: visible; -webkit-mask-image: none; mask-image: none; }
  .feed-slot:not(.all) .fr:nth-child(n + 9) { display: none; }
  .feed-more:not([hidden]) {
    display: block; width: 100%; margin-top: 6px; padding: 10px 12px; border-radius: 10px; font: inherit; font-weight: 600;
    color: inherit; background: var(--control-bg); border: 1px solid var(--control-border); cursor: pointer;
  }
  .feed-more:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
  .fr-name { flex-basis: 100%; margin-right: 0; }
  .fr-seg { white-space: nowrap; }
  .fr-l1 .fr-name + .fr-seg::before { content: none; }
}

/* ---- The restyled site (spec 2026-10-02, mockups docs/design/site-restyle): "scorebug" style 2. Flat dark panels,
   small grey capital column heads, Anton for big numbers, Inter for the rest. Colour lives only in the strip, the
   latest-play panel, the series pill, the Team Stats bars, the Live now cards and the W/L/Split badges: never in a
   table row, a total row or a picker. Team colours arrive as #rrggbb custom properties set through CSSOM (--ta, --tb, --tc, --pill). ---- */
body.site {
  --pg: #0e0f11; --panel: #17181b; --panel-2: #141518; --bar: #121316; --hair: #1d1e22; --hair-2: #26272b; --hair-3: #34353a;
  --ink: #ffffff; --ink-2: #c9ccd2; --ink-3: #9a9ea7; --ink-4: #8d919a; --ink-5: #7d818a; --sub: #a2a5ac;
  --live: #ff453a; --tab-on: #c8102e; --neutral: #3a3c42;
  max-width: 1104px; margin: 0 auto; padding: 24px 22px;
  background: #0b0c0e; color: var(--ink);
  font: 500 14px/1.45 "Inter NSR", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
body.site * { min-width: 0; }
body.site .num, body.site table { font-variant-numeric: tabular-nums; }
.pg { background: var(--pg); border-radius: 14px; overflow: hidden; }

/* The strip: [team a] [status, line score, pill] [team b]; the leader's side washes more of its colour (R5). */
.strip {
  --wa: 40%; --wb: 40%;
  display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); align-items: center; gap: 12px; padding: 18px 26px;
  background: linear-gradient(90deg, color-mix(in srgb, var(--ta, #3a3c42) var(--wa), transparent) 0%, color-mix(in srgb, var(--ta, #3a3c42) 8%, transparent) 28%,
    var(--panel-2) 40%, var(--panel-2) 60%, color-mix(in srgb, var(--tb, #3a3c42) 12%, transparent) 72%, color-mix(in srgb, var(--tb, #3a3c42) var(--wb), transparent) 100%), var(--panel-2);
}
.strip.lead-a { --wa: 55%; --wb: 28%; }
.strip.lead-b { --wa: 28%; --wb: 55%; }
.st-team { display: flex; align-items: center; gap: 16px; }
.st-team.b { justify-content: flex-end; text-align: right; }
.st-team .logo, .st-team .teambadge, .st-team .avatar { width: 66px; height: 66px; flex: none; object-fit: contain; filter: drop-shadow(0 4px 10px rgba(0, 0, 0, .5)); }
.st-team .teambadge { border-radius: 50%; background: var(--tc, #3a3c42); color: #ffffff; font-weight: 800; }
.st-team .avatar { border-radius: 50%; object-fit: cover; }
.st-nm { display: flex; flex-direction: column; }
.st-name { font: 700 17px "Inter NSR", system-ui, sans-serif; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.st-player { margin-top: 2px; font: 500 13px "Inter NSR", system-ui, sans-serif; color: var(--sub); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.st-pts { margin: 0 10px; font: 400 46px/1 "Anton NSR", Impact, sans-serif; font-synthesis: none; font-variant-numeric: tabular-nums; }
.st-team.trailing .st-pts { color: rgba(255, 255, 255, .45); }
.st-mid { display: flex; flex-direction: column; align-items: center; padding: 0 14px; text-align: center; }
.st-status { margin-bottom: 6px; font: 700 13px "Inter NSR", system-ui, sans-serif; letter-spacing: .04em; }
.st-status.live { color: var(--live); }
.st-status .st-unoff { font-weight: 600; color: var(--sub); }
.st-status.live::before { content: "● "; }
.ls { margin: 0 auto; border-collapse: collapse; font: 600 12px "Inter NSR", system-ui, sans-serif; }
.ls th { padding: 0 8px 3px; text-align: center; font-weight: 600; color: var(--ink-4); }
.ls td { padding: 2px 8px; text-align: center; }
.ls .ls-team { padding: 2px 8px; text-align: left; color: var(--ink-2); }
.ls .cur { color: #ffffff; font-weight: 800; }
.ls .na { color: var(--ink-5); }
.pill { display: inline-block; margin-top: 8px; padding: 5px 12px; border-radius: 999px; font: 700 13px "Inter NSR", system-ui, sans-serif; color: #ffffff; background: rgba(255, 255, 255, .1); white-space: nowrap; }
.pill.win { background: var(--pill, #3a3c42); }

/* Tabs: grey words, the picked one white over a red underline. */
body.site .tabs { display: flex; gap: 22px; margin: 0; padding: 0 26px; overflow-x: auto; border-bottom: 1px solid #1f2024; background: var(--bar); }
body.site .tabs button { all: unset; padding: 12px 0; font: 600 13px "Inter NSR", system-ui, sans-serif; color: var(--ink-3); white-space: nowrap; cursor: pointer; }
body.site .tabs button[aria-selected="true"] { color: #ffffff; box-shadow: inset 0 -3px var(--tab-on); }
body.site .tabs button:focus-visible, .picker button:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
body.site .panel { margin: 0; padding: 0 0 20px; }
body.site .panel[hidden] { display: none; }

/* The game picker: plain text, an underline on the picked one, never a filled pill. */
.picker { display: flex; flex-wrap: wrap; gap: 18px; margin: 16px 22px 0; }
.picker button { all: unset; padding: 6px 0; font: 600 13px "Inter NSR", system-ui, sans-serif; color: var(--ink-3); cursor: pointer; }
.picker button[aria-pressed="true"] { color: #ffffff; box-shadow: inset 0 -2px #ffffff; }

body.site footer { display: flex; justify-content: space-between; gap: 12px; margin-top: 18px; color: var(--ink-3); font-size: 12px; }
body.site footer a { color: inherit; }

/* Phone: the two seats stack as rows (logo, name, score), the status, line score and pill under them. */
@media (max-width: 600px) {
  body.site { padding: 16px; }
  .strip { grid-template-columns: minmax(0, 1fr); gap: 10px; padding: 14px 16px; }
  .st-team, .st-team.b { justify-content: flex-start; text-align: left; gap: 12px; }
  .st-team.b { flex-direction: row-reverse; }
  .st-nm { flex: 1 1 auto; }
  .st-team.b .st-nm { text-align: left; }
  .st-team .logo, .st-team .teambadge, .st-team .avatar { width: 40px; height: 40px; }
  .st-pts { margin: 0; font-size: 34px; }
  .st-mid { order: 3; padding: 0; }
  body.site .tabs { gap: 18px; padding: 0 16px; }
  .picker { margin: 14px 16px 0; }
}

/* Live Feed: the latest-play panel (live-feed-7.html) over All plays. */
.feed-col { display: grid; gap: 22px; padding: 20px 22px; }
.cap { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin: 0 0 8px; font: 700 11px "Inter NSR", system-ui, sans-serif; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-3); }
.cap-note { font-weight: 500; letter-spacing: 0; text-transform: none; }
.pp-nav { display: flex; padding: 3px; border-radius: 8px; background: var(--panel); }
.pp-step { all: unset; display: grid; place-items: center; width: 30px; height: 24px; border-radius: 6px; font: 600 11px "Inter NSR", system-ui, sans-serif; letter-spacing: 0; color: var(--ink-2); cursor: pointer; }
.pp-step:disabled { opacity: .35; cursor: default; }
.pp-step:focus-visible { outline: 2px solid var(--focus); outline-offset: 1px; }
.pp-step.lv { width: auto; margin-left: 3px; padding: 0 9px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: #ffffff; background: #2a2c31; }
.pp-step.lv[aria-pressed="true"] { background: color-mix(in srgb, var(--tc, #3a3c42) 85%, #000000); }
.pp { position: relative; overflow: hidden; container-type: inline-size; border-radius: 14px; background: var(--panel); }
.pp-main {
  position: relative; overflow: hidden; display: flex; align-items: center; gap: 22px; padding: 26px 24px;
  background: linear-gradient(100deg, color-mix(in srgb, var(--tc, #3a3c42) 38%, transparent), color-mix(in srgb, var(--tc, #3a3c42) 8%, transparent) 50%, transparent 80%);
}
.pp-wm { position: absolute; right: 30px; top: -40px; width: 260px; height: 260px; object-fit: contain; opacity: .06; pointer-events: none; }
.pp-av { position: relative; flex: none; width: 112px; height: 112px; }
.pp-face {
  display: flex; align-items: center; justify-content: center; width: 100%; height: 100%; overflow: hidden; border-radius: 50%;
  background: radial-gradient(circle at 50% 40%, var(--face0, #45474e), var(--face1, #27282c) 72%); box-shadow: 0 0 0 3px rgba(255, 255, 255, .08);
}
.pp-face .portrait { display: block; width: 100%; height: 100%; object-fit: cover; object-position: 50% 18%; }
.pp-face .pp-facelogo { width: 62%; height: 62%; object-fit: contain; }
.pp-badge { position: absolute; right: -2px; bottom: 0; display: grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; background: var(--panel); }
.pp-badge .logo { width: 22px; height: 22px; object-fit: contain; }
.pp-txt { position: relative; display: flex; flex-direction: column; }
.pp-res { font: 700 11px "Inter NSR", system-ui, sans-serif; letter-spacing: .1em; color: #30d158; }
.pp-res.muted { color: var(--ink-3); }
.pp-hl { margin: 4px 0 6px; font: 800 34px/1.05 "Inter NSR", system-ui, sans-serif; letter-spacing: -.02em; overflow-wrap: anywhere; }
.pp-l1 { display: flex; flex-wrap: wrap; align-items: baseline; font: 600 15px "Inter NSR", system-ui, sans-serif; color: var(--ink-3); }
.pp-name { margin-right: 8px; color: #ffffff; }
.pp-seg b { font-weight: 600; color: #ffffff; }
.pp-seg span { margin-left: .28em; font-weight: 500; }
.pp-seg + .pp-seg::before { content: "·"; margin: 0 6px; color: #4a4d54; }
.pp-l2 { margin-top: 3px; font: 500 13px "Inter NSR", system-ui, sans-serif; color: var(--ink-3); overflow-wrap: anywhere; }
.pp-l2 b { font-weight: 600; color: var(--ink-2); }
.pp-wait { justify-content: center; min-height: 160px; }
.pp-wait .pp-hl { font-size: 22px; color: var(--ink-2); }
.pp-sit { padding: 16px 24px 20px; border-top: 1px solid rgba(255, 255, 255, .06); background: var(--panel-2); }
.pp-sit .lc-sh { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 4px 12px; margin-bottom: 14px; }
.pp-sit .lc-dn { font: 600 14px "Inter NSR", system-ui, sans-serif; }
.pp-sit .lc-spot { margin-left: .28em; font-weight: 500; color: var(--ink-3); }
.pp-sit .lc-dr { font: 500 13px "Inter NSR", system-ui, sans-serif; color: var(--ink-3); }
.pp-sit .lc-dr b { font-weight: 600; color: #ffffff; }
.pp-sit .lc-rul { margin-top: 6px; }

/* All plays (game page v2, game-v2.html sections 1 and 1b): the toggle, then drive rows; an open drive shows its chart
   and its play cards. Cards are cards, never shaded table rows; team colour lives only in the chart (spec §2). */
.ap-seg { display: flex; margin-bottom: 14px; padding: 3px; border-radius: 999px; background: var(--panel); }
.ap-seg button { all: unset; flex: 1; padding: 7px 0; border-radius: 999px; font: 600 12.5px "Inter NSR", system-ui, sans-serif; text-align: center; color: var(--ink-3); cursor: pointer; }
.ap-seg button[aria-pressed="true"] { color: #ffffff; background: #2a2c31; }
.ap-seg button:focus-visible { outline: 2px solid var(--focus); outline-offset: 1px; }
.ap { list-style: none; margin: 0; padding: 0; overflow: hidden; border: 1px solid #1f2024; border-radius: 12px; background: var(--panel-2); }
.ap-qh { padding: 12px 16px 6px; font: 700 11px "Inter NSR", system-ui, sans-serif; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-3); }
.dv { border-top: 1px solid #1f2024; }
.ap > .dv:first-child { border-top: 0; }
.dv-hd { all: unset; box-sizing: border-box; display: grid; grid-template-columns: 34px minmax(0, 1fr) auto 18px; gap: 12px; align-items: center; width: 100%; padding: 11px 16px; cursor: pointer; }
.dv-hd:focus-visible { outline: 2px solid var(--focus); outline-offset: -2px; }
.dv-logo { display: grid; place-items: center; }
.dv-logo .logo { width: 28px; height: 28px; object-fit: contain; }
.dv-logo .teambadge { width: 28px; height: 28px; border-radius: 50%; font-size: 9px; color: #ffffff; background: var(--neutral); }
.dv-txt { display: flex; flex-direction: column; }
.dv-res { font: 700 14px "Inter NSR", system-ui, sans-serif; }
.dv-m { margin-top: 2px; overflow: hidden; font: 500 12px "Inter NSR", system-ui, sans-serif; color: var(--ink-4); text-overflow: ellipsis; white-space: nowrap; }
.dv-sc { display: grid; grid-template-columns: 28px 28px; font: 700 14px "Inter NSR", system-ui, sans-serif; text-align: center; font-variant-numeric: tabular-nums; }
.dv-sc span { font: 600 10px "Inter NSR", system-ui, sans-serif; letter-spacing: .04em; color: var(--ink-5); }
.dv-sc .hi { color: #ffffff; }
.dv-sc .lo { color: var(--ink-3); }
.dv-tag { padding: 3px 7px; border: 1px solid var(--hair-3); border-radius: 5px; font: 700 10px "Inter NSR", system-ui, sans-serif; letter-spacing: .05em; color: var(--ink-2); white-space: nowrap; }
.dv-ch { font-size: 12px; text-align: right; color: var(--ink-5); }
.dv-body { display: grid; gap: 8px; padding: 4px 14px 14px; border-top: 1px solid #1f2024; background: var(--bar); }
.dv-plays { display: grid; gap: 8px; margin: 0; padding: 0; list-style: none; }
.dc { display: grid; grid-template-columns: minmax(0, 1fr) minmax(230px, 300px); gap: 16px; align-items: center; padding: 10px 2px 4px; }
.dc-field { position: relative; height: 30px; overflow: hidden; border-radius: 6px; background: #1c3a2a; }
.dc-ez { position: absolute; top: 0; bottom: 0; width: 7%; }
.dc-ez.a { left: 0; background: var(--ez-a, #3a3c42); }
.dc-ez.b { right: 0; background: var(--ez-b, #3a3c42); }
.dc-yl { position: absolute; top: 0; bottom: 0; width: 1px; background: rgba(255, 255, 255, .12); }
.dc-yl.y1 { left: 25%; }
.dc-yl.y2 { left: 50%; }
.dc-yl.y3 { left: 75%; }
.dc-run { position: absolute; top: 11px; left: var(--x); width: var(--w); height: 8px; border-radius: 4px; background: var(--tc, #a2a5ac); }
.dc-st { position: absolute; top: 9px; left: var(--x); width: 12px; height: 12px; border: 2px solid #ffffff; border-radius: 50%; background: #1c3a2a; transform: translateX(-50%); }
.dc-en { position: absolute; top: 7px; left: var(--x); width: 16px; height: 16px; border-radius: 50%; background: #ffffff; transform: translateX(-50%); }
.dc-txt { display: flex; flex-direction: column; text-align: right; }
.dc-txt b { font: 700 13px "Inter NSR", system-ui, sans-serif; }
.dc-sc, .dc-m { font: 600 12px "Inter NSR", system-ui, sans-serif; color: var(--ink-4); font-variant-numeric: tabular-nums; }
.ap-btn { all: unset; box-sizing: border-box; display: grid; grid-template-columns: 40px minmax(0, 1fr) auto; gap: 12px; align-items: center; width: 100%; padding: 10px 12px; border: 1px solid #222327; border-radius: 10px; background: var(--panel); cursor: pointer; }
.ap-btn:focus-visible { outline: 2px solid var(--focus); outline-offset: 1px; }
.ap-av { display: grid; place-items: center; width: 40px; height: 40px; overflow: hidden; border-radius: 50%; background: radial-gradient(circle at 50% 40%, #45474e, #27282c 72%); }
.ap-av .portrait { width: 100%; height: 100%; object-fit: cover; object-position: 50% 18%; }
.ap-av .logo { width: 26px; height: 26px; object-fit: contain; }
.ap-av .teambadge { width: 40px; height: 40px; border-radius: 50%; font-size: 10px; color: #ffffff; background: var(--neutral); }
.ap-txt { display: flex; flex-direction: column; }
.ap-hl { font: 700 13.5px "Inter NSR", system-ui, sans-serif; overflow-wrap: anywhere; }
.ap-res { margin-left: 8px; white-space: nowrap; font: 700 9.5px "Inter NSR", system-ui, sans-serif; letter-spacing: .08em; color: var(--ink-3); }
.ap-l { margin-top: 2px; font: 500 12px "Inter NSR", system-ui, sans-serif; color: var(--ink-2); overflow-wrap: anywhere; }
.ap-l b { font-weight: 600; color: #ffffff; }
.ap-sit { margin-top: 2px; font: 500 11.5px "Inter NSR", system-ui, sans-serif; color: var(--ink-4); }
.ap-sc { font: 400 18px "Anton NSR", Impact, sans-serif; font-synthesis: none; text-align: right; }
body.site .empty { margin: 0; padding: 14px 16px; color: var(--ink-3); }

@media (max-width: 600px) {
  .feed-col { padding: 16px; gap: 18px; }
  .pp-main { flex-direction: column; align-items: flex-start; gap: 14px; padding: 18px 16px; }
  .pp-av { width: 80px; height: 80px; }
  .pp-hl { font-size: 26px; }
  .pp-wm { right: -20px; width: 180px; height: 180px; }
  .pp-sit { padding: 14px 16px 16px; }
  .dv-hd { grid-template-columns: 28px minmax(0, 1fr) auto 14px; gap: 10px; padding: 10px 12px; }
  .dv-body { padding: 4px 10px 12px; }
  .dc { grid-template-columns: minmax(0, 1fr); gap: 8px; }
  .dc-txt { text-align: left; }
  .ap-btn { grid-template-columns: 36px minmax(0, 1fr) auto; gap: 10px; }
  .ap-av { width: 36px; height: 36px; }
}

/* Box Score (boxscore-9.html): two team columns, small grey capital heads, bold TEAM row with a thin line above.
   .tbl is the Box Score's. No zebra rows, no shaded total: table cells are never shaded. */
.bx-cols { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 22px; padding: 16px 22px 20px; }
.bx-sec { margin-bottom: 14px; }
.bx-sh { display: flex; align-items: center; gap: 8px; margin: 0 0 6px; font: 700 13px "Inter NSR", system-ui, sans-serif; }
.bx-sh .logo { width: 20px; height: 20px; object-fit: contain; flex: none; }
.tbl { width: 100%; table-layout: fixed; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.tbl th { padding: 5px 6px; border-bottom: 1px solid var(--hair-2); font: 600 10.5px "Inter NSR", system-ui, sans-serif; letter-spacing: .05em; text-transform: uppercase; text-align: right; color: var(--ink-5); }
.tbl td { padding: 6px; border-bottom: 1px solid var(--hair); font: 500 12.5px "Inter NSR", system-ui, sans-serif; text-align: right; }
.tbl .who { width: 42%; text-align: left; }
.tbl td.who { overflow: hidden; font-weight: 600; text-overflow: ellipsis; white-space: nowrap; border-right: 1px solid var(--hair-2); }
.tbl tr.tot td { font-weight: 700; color: #ffffff; border-top: 1px solid var(--hair-3); }
.bx-none { margin: 0; padding: 10px 6px; border-bottom: 1px solid var(--hair); font: 500 12.5px "Inter NSR", system-ui, sans-serif; color: var(--ink-4); }
body.site .sr { position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
@media (max-width: 900px) { .bx-cols { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 600px) { .ap-res { display: block; margin-left: 0; } }
@media (max-width: 600px) {
  .bx-cols { padding: 14px 16px 16px; }
  .tbl th, .tbl td { padding: 5px 4px; }
  .tbl .who { width: 36%; }
}

/* Team Stats (drives-stats-3.html option A): the ESPN table. Stat name, then one column per seat headed by its logo
   and abbrev; the better value white, the other grey (R8). No bars, no shaded rows or cells. */
.ts { padding: 16px 22px 20px; }
.ts-box { max-width: 760px; margin: 0 auto; overflow: hidden; border: 1px solid #1f2024; border-radius: 12px; background: var(--panel-2); }
.ts-t { width: 100%; table-layout: fixed; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.ts-t th, .ts-t td { padding: 10px 14px; border-bottom: 1px solid var(--hair); font: 500 13px "Inter NSR", system-ui, sans-serif; text-align: left; }
.ts-t tbody tr:last-child td { border-bottom: 0; }
.ts-t thead th { font: 600 11px "Inter NSR", system-ui, sans-serif; letter-spacing: .06em; text-transform: uppercase; color: var(--ink-5); }
.ts-t .th-team { width: 120px; text-align: right; white-space: nowrap; }
.ts-t .th-team .logo { width: 24px; height: 24px; margin-right: 6px; object-fit: contain; vertical-align: middle; }
.ts-t td.who { overflow-wrap: anywhere; }
.ts-t td.v { text-align: right; font-weight: 700; }
.ts-t td.v.hi { color: #ffffff; }
.ts-t td.v.lo { font-weight: 500; color: var(--ink-3); }
@media (max-width: 600px) {
  .ts { padding: 14px 16px 16px; }
  .ts-t th, .ts-t td { padding: 9px 10px; }
  .ts-t .th-team { width: 74px; }
  .ts-t .th-team .logo { width: 20px; height: 20px; margin-right: 4px; }
}

/* /live: mini scorebugs, three across (live-now-list.html, lower half). The leader's row is solid team colour. */
.ln-title { margin: 0; padding: 22px 22px 0; font: 700 11px "Inter NSR", system-ui, sans-serif; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-3); }
.ln-list { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin: 0; padding: 14px 22px 22px; list-style: none; }
.ln-list > .empty { grid-column: 1 / -1; }
.ln-card { display: block; overflow: hidden; border-radius: 14px; background: var(--panel); color: inherit; text-decoration: none; }
.ln-card:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
.ln-row { display: grid; grid-template-columns: 30px minmax(0, 1fr) auto; align-items: center; gap: 10px; margin: 8px 8px 0; padding: 9px 14px; border-radius: 10px; background: var(--tc, var(--neutral)); }
.ln-row.dim { background: color-mix(in srgb, var(--tc, #3a3c42) 22%, transparent); }
.ln-row .index-logo, .ln-row .index-avatar, .ln-row .index-initial, .ln-row .index-abbrev { width: 26px; height: 26px; min-width: 0; padding: 0; }
.ln-row .index-abbrev { display: inline-grid; place-items: center; border-radius: 50%; font-size: 9px; }
.ln-nm { display: flex; flex-direction: column; }
.ln-row .index-name { overflow: hidden; font: 700 15px "Inter NSR", system-ui, sans-serif; text-overflow: ellipsis; white-space: nowrap; }
.ln-player { overflow: hidden; font: 500 12px "Inter NSR", system-ui, sans-serif; color: var(--ink-2); text-overflow: ellipsis; white-space: nowrap; }
.ln-sc { font: 400 26px/1 "Anton NSR", Impact, sans-serif; font-synthesis: none; }
.ln-ft { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 10px 14px 12px; font: 500 12px "Inter NSR", system-ui, sans-serif; color: var(--ink-3); }
.ln-rest { margin-left: .3em; }
.ln-live { font-weight: 700; color: var(--live); }
.ln-live::before { content: "● "; }
.ln-final { font-weight: 700; color: #ffffff; }
.ln-watch { flex: none; padding: 5px 12px; border-radius: 999px; font: 700 12px "Inter NSR", system-ui, sans-serif; color: #ffffff; background: #2a2c31; white-space: nowrap; }
@media (max-width: 900px) { .ln-list { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) { .ln-list { grid-template-columns: minmax(0, 1fr); padding: 14px 16px 16px; } .ln-title { padding: 16px 16px 0; } }
.ln-row .index-abbrev { background: rgba(255, 255, 255, .18) !important; color: #ffffff !important; }
.ln-row.lt { color: #101114; }
.ln-row.lt .ln-player { color: #2b2d33; }
.ln-row.lt .index-abbrev { background: rgba(16, 17, 20, .16) !important; color: #101114 !important; }

/* The plain site footer (game-v2.html section 4) on /live/:id, /games/:id and /u/:id: the brand left, the links right.
   Literal colours, because /u/:id is not body.site. `body footer.site-ft` outranks `body.site footer` (same weight,
   later). The live page's connection note sits above it, empty while all is well (R12). */
body footer.site-ft { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 8px 18px; margin-top: 18px; padding: 16px 4px 0; border-top: 1px solid #1f2024; font: 500 12.5px "Inter NSR", system-ui, sans-serif; color: #8d919a; }
body footer.site-ft .brand { font-weight: 700; color: #ffffff; }
body footer.site-ft .ft-links { display: flex; flex-wrap: wrap; gap: 4px 18px; }
body footer.site-ft a { color: #c9ccd2; text-decoration: none; }
body footer.site-ft a:hover { color: #ffffff; }
body footer.site-ft a:focus-visible { outline: 2px solid var(--focus, #ffffff); outline-offset: 2px; }
body.site .conn { margin: 0; padding: 0 22px 14px; font: 500 12px "Inter NSR", system-ui, sans-serif; color: var(--ink-4); }
body.site .conn:empty { display: none; }

/* ---- /leaderboard (Adam 10-04): the ranked ladder, top 50. The site's flat dark panel; a thin bar in each row's
   plays-as team colour (--tc, set through CSSOM) is the only colour in a row, plus green/red for the week's change. ---- */
.lb-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 6px 16px; padding: 22px 22px 6px; }
.lb-title { margin: 0; font: 400 34px/1 "Anton NSR", Impact, sans-serif; font-synthesis: none; letter-spacing: .01em; text-transform: uppercase; }
.lb-sub { margin: 0; font: 600 12px "Inter NSR", system-ui, sans-serif; color: var(--ink-3); }
.lb-board { padding: 8px 22px 22px; }
.lb-empty { margin: 0; padding: 40px 16px; border-radius: 12px; background: var(--panel); text-align: center; font: 600 15px "Inter NSR", system-ui, sans-serif; color: var(--ink-2); }
.lb-table { width: 100%; border-collapse: separate; border-spacing: 0 6px; font: 500 14px "Inter NSR", system-ui, sans-serif; }
.lb-table th { padding: 4px 12px; font: 700 11px "Inter NSR", system-ui, sans-serif; letter-spacing: .08em; text-transform: uppercase; color: var(--ink-4); text-align: left; }
.lb-table th.lb-rec, .lb-table th.lb-elo, .lb-table th.lb-week, .lb-table td.lb-rec, .lb-table td.lb-elo, .lb-table td.lb-week { text-align: right; }
.lb-row td { padding: 10px 12px; background: var(--panel); white-space: nowrap; }
.lb-row td:first-child { border-radius: 10px 0 0 10px; box-shadow: inset 4px 0 var(--tc, var(--neutral)); }
.lb-row td:last-child { border-radius: 0 10px 10px 0; }
.lb-row.you td { background: color-mix(in srgb, var(--tc, #3a3c42) 18%, var(--panel)); }
.lb-rank { width: 3.2em; padding-left: 18px !important; font: 400 22px/1 "Anton NSR", Impact, sans-serif; font-synthesis: none; color: var(--ink-2); }
.lb-row.top .lb-rank { color: #e6b84c; }
td.lb-who > * { vertical-align: middle; }
.lb-avatar, .lb-initial { width: 36px; height: 36px; border-radius: 50%; flex: none; margin-right: 12px; }
.lb-avatar { object-fit: cover; background: var(--hair-2); }
.lb-initial { display: inline-flex; align-items: center; justify-content: center; font-weight: 700; color: var(--ink-3); border: 1px solid var(--hair-3); }
.lb-name { display: inline-block; max-width: 22ch; overflow: hidden; text-overflow: ellipsis; font-weight: 700; color: #ffffff; text-decoration: none; }
a.lb-name:hover { text-decoration: underline; }
a.lb-name:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
td.lb-team > * { vertical-align: middle; }
.lb-logo { width: 28px; height: 28px; object-fit: contain; margin-right: 8px; }
.lb-badge { display: inline-grid; place-items: center; width: 28px; height: 28px; margin-right: 8px; border-radius: 50%; font-size: 9px; font-weight: 800; color: #ffffff; background: var(--tc, var(--neutral)); }
.lb-abbrev { font-weight: 700; color: var(--ink-2); letter-spacing: .03em; }
.lb-noteam { color: var(--ink-5); }
.lb-rec { color: var(--ink-2); }
.lb-elo { font: 400 20px/1 "Anton NSR", Impact, sans-serif; font-synthesis: none; }
.lb-week { font-weight: 700; }
.lb-week.up { color: #5ad17a; }
.lb-week.down { color: #ff6b61; }
.lb-week.flat { color: var(--ink-4); }
@media (max-width: 600px) {
  .lb-head { padding: 16px 16px 4px; }
  .lb-title { font-size: 28px; }
  .lb-board { padding: 6px 10px 16px; }
  .lb-row td, .lb-table th { padding-left: 6px; padding-right: 6px; }
  .lb-rank { width: 2.2em; padding-left: 12px !important; font-size: 18px; }
  .lb-avatar, .lb-initial { width: 28px; height: 28px; margin-right: 8px; }
  .lb-name { max-width: 12ch; }
  .lb-table th { white-space: nowrap; font-size: 10px; letter-spacing: .04em; }
  /* A phone keeps rank, player, record, Elo and the week; the team is the row's colour bar. */
  .lb-table th.lb-team, .lb-table td.lb-team { display: none; }
  .lb-elo { font-size: 17px; }
}
@media (max-width: 340px) { .lb-table th.lb-week, .lb-table td.lb-week { display: none; } }
