/* ══════════════════════════════════════════════════════════════════════════
   MosconiStats — site layer.

   Everything here is built from the Modernist tokens in modernist.css. No
   colour, font or spacing value is hard-coded when a token carries it. The
   three exceptions are the team colours below, which the design system has
   no slot for.

   Geometry rules that hold everywhere: radius 0, no shadows, section rules
   are 2px solid var(--color-text), cell rules are 1px solid
   var(--color-divider), everything is flush left.
   ══════════════════════════════════════════════════════════════════════ */

:root {
  /* Matchroom stages Europe in blue and USA in red. Modernist is a mono-red
     system, so the blue takes the second-accent slot.

     The split between --team-us and --team-us-ink is a contrast requirement,
     not a stylistic one: #ec3013 measures 3.76:1 on the ground — fine for
     fills and display type ≥40px, below AA for body text — while #ae1800
     measures 6.41:1. Fills use --team-us; text under ~18px uses
     --team-us-ink. Keep them distinct. */
  --team-eu: #1a3fc4;
  --team-us: #ec3013;
  --team-us-ink: #ae1800;

  /* The handoff calls for white panels, one step brighter than the system's
     default surface. */
  --color-surface: #ffffff;

  --shell-max: 1440px;
  --shell-pad: 24px;
  --row-pad: 13px; /* comfortable; the design's compact alternate is 8px */
}

/* ── base ──────────────────────────────────────────────────────────────── */

html, body { margin: 0; padding: 0; background: var(--color-bg); }
body {
  color: var(--color-text);
  font-family: var(--font-body);
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
*, *::before, *::after { box-sizing: border-box; }

a { color: var(--color-accent-700); text-decoration: none; }
a:hover { color: var(--color-accent); text-decoration: underline; }
::selection { background: var(--color-accent-200); }

:focus { outline: none; }
:focus-visible { outline: 2px solid var(--color-accent); outline-offset: 2px; }

@keyframes msPulse { 0%, 100% { opacity: 1 } 50% { opacity: 0.25 } }
@media (prefers-reduced-motion: reduce) {
  * { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; }
}

.skip-link {
  position: absolute; left: -9999px; top: 0; z-index: 100;
  background: var(--color-text); color: var(--color-bg);
  padding: 10px 16px; font-size: 12px; font-weight: 600;
  letter-spacing: 0.12em; text-transform: uppercase;
}
.skip-link:focus { left: 0; }

.tnum { font-variant-numeric: tabular-nums; }
.pretty { text-wrap: pretty; }
.spacer { height: 64px; }
.eu-ink { color: var(--team-eu); }
.us-ink { color: var(--team-us-ink); }
.us-fill { color: var(--team-us); }
.accent-ink { color: var(--color-accent); }
.neutral-ink { color: var(--color-neutral-600); }

/* ── layout ────────────────────────────────────────────────────────────── */

.shell { max-width: var(--shell-max); margin: 0 auto; padding: 0 var(--shell-pad); width: 100%; }
main { flex: 1 0 auto; }
.band { border-bottom: 2px solid var(--color-text); }
.band-accent {
  border-bottom: 2px solid var(--color-text);
  background: var(--color-accent);
  color: var(--color-bg);
}
.section { padding: 48px var(--shell-pad) 0; max-width: var(--shell-max); margin: 0 auto; width: 100%; }
.page { padding: 40px var(--shell-pad) 64px; max-width: var(--shell-max); margin: 0 auto; width: 100%; }

/* ── header ────────────────────────────────────────────────────────────── */

.site-header {
  position: sticky; top: 0; z-index: 30;
  background: var(--color-bg);
  border-bottom: 2px solid var(--color-text);
}
.site-header__inner {
  max-width: var(--shell-max); margin: 0 auto; padding: 0 var(--shell-pad);
  display: flex; align-items: stretch; gap: 32px; flex-wrap: wrap;
}
.wordmark {
  display: flex; flex-direction: column; justify-content: center; gap: 2px;
  padding: 14px 0; text-decoration: none; color: var(--color-text);
}
.wordmark:hover { opacity: 0.7; text-decoration: none; color: var(--color-text); }
.wordmark__name {
  font-family: var(--font-heading); font-weight: 800; font-size: 21px;
  line-height: 1; letter-spacing: -0.025em; text-transform: uppercase;
}
.wordmark__name span { color: var(--color-accent); }
.wordmark__sub {
  font-size: 9px; letter-spacing: 0.22em; text-transform: uppercase;
  color: var(--color-neutral-600);
}
.site-nav { display: flex; align-items: stretch; gap: 4px; flex-wrap: wrap; margin-left: auto; }
.site-nav a {
  display: flex; align-items: center;
  border-bottom: 3px solid transparent;
  padding: 18px 10px 15px;
  font-family: var(--font-body); font-size: 11px; font-weight: 600;
  letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--color-text); white-space: nowrap;
}
.site-nav a:hover { color: var(--color-accent); text-decoration: none; }
.site-nav a[aria-current="page"] { border-bottom-color: var(--color-accent); color: var(--color-accent); }

/* ── footer ────────────────────────────────────────────────────────────── */

.site-footer {
  border-top: 2px solid var(--color-text);
  background: var(--color-accent);
  color: var(--color-bg);
  flex: none;
}
.site-footer__inner {
  max-width: var(--shell-max); margin: 0 auto; padding: 40px var(--shell-pad);
  display: flex; flex-wrap: wrap; gap: 32px;
  justify-content: space-between; align-items: flex-end;
}
.site-footer__statement {
  font-family: var(--font-heading); font-weight: 800;
  font-size: clamp(30px, 5vw, 52px); line-height: 0.95; letter-spacing: -0.035em;
  text-transform: uppercase; max-width: 620px; text-wrap: pretty; margin: 0;
}
.site-footer__meta { font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; opacity: 0.85; }

/* ── shared type ───────────────────────────────────────────────────────── */

.page-title {
  margin: 0 0 6px; font-family: var(--font-heading); font-weight: 800;
  font-size: clamp(38px, 6vw, 68px); line-height: 0.95;
  letter-spacing: -0.035em; text-transform: uppercase;
}
.page-lede { font-size: 14px; color: var(--color-neutral-700); margin-bottom: 28px; }
.kicker {
  font-size: 11px; font-weight: 600; letter-spacing: 0.2em;
  text-transform: uppercase; color: var(--color-accent-700);
}
.section-head {
  display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 4px 16px;
  border-bottom: 2px solid var(--color-text); padding-bottom: 8px;
}
.section-head h2 {
  margin: 0; font-family: var(--font-body); font-size: 13px; font-weight: 600;
  letter-spacing: 0.14em; text-transform: uppercase; line-height: 1.4;
}
.section-note {
  font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--color-neutral-600); white-space: nowrap;
}
.footnote {
  font-size: 12px; color: var(--color-neutral-600);
  padding-top: 20px; max-width: 720px; text-wrap: pretty;
}
.link-ghost {
  font-family: var(--font-heading); font-weight: 800;
  font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--color-accent);
}

/* ── dashboard: hero ───────────────────────────────────────────────────── */

.hero { padding: 56px var(--shell-pad) 40px; max-width: var(--shell-max); margin: 0 auto; }
.hero .kicker { display: block; margin-bottom: 28px; }
.hero-score {
  display: grid; grid-template-columns: 1fr auto 1fr;
  align-items: end; gap: 24px; max-width: 900px;
}
.hero-score__label {
  font-size: 13px; font-weight: 600; letter-spacing: 0.16em;
  text-transform: uppercase; margin-bottom: 4px;
}
.hero-score__num {
  font-family: var(--font-heading); font-weight: 800;
  font-size: clamp(88px, 15vw, 190px); line-height: 0.82; letter-spacing: -0.05em;
}
.hero-score__dash {
  font-family: var(--font-heading); font-weight: 800;
  font-size: clamp(40px, 6vw, 80px); line-height: 1;
  color: var(--color-neutral-400); padding-bottom: 14px;
}
.hero-bar { display: flex; height: 10px; margin: 36px 0 10px; max-width: 900px; }
.hero-bar__captions {
  display: flex; justify-content: space-between; gap: 12px; max-width: 900px;
  font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--color-neutral-700);
}

/* ── dashboard: current-run band ───────────────────────────────────────── */

.run-grid {
  max-width: var(--shell-max); margin: 0 auto; padding: 32px var(--shell-pad);
  display: grid; grid-template-columns: repeat(auto-fit, minmax(min(240px, 100%), 1fr)); gap: 32px;
}
.run-label {
  font-size: 10px; font-weight: 600; letter-spacing: 0.2em;
  text-transform: uppercase; opacity: 0.75; margin-bottom: 8px;
}
.run-value {
  font-family: var(--font-heading); font-weight: 800; font-size: 34px;
  line-height: 1.05; letter-spacing: -0.02em;
}
.run-note { font-size: 13px; opacity: 0.85; margin-top: 4px; }

/* ── dashboard: cup-by-cup timeline ────────────────────────────────────── */

.timeline { display: flex; align-items: stretch; gap: 3px; overflow-x: auto; padding: 28px 0 0; }
.timeline__col {
  flex: 1 0 26px; min-width: 22px;
  display: flex; flex-direction: column; align-items: stretch;
  text-decoration: none; color: inherit;
}
.timeline__col:hover { opacity: 0.6; text-decoration: none; }
.timeline__up { height: 118px; display: flex; align-items: flex-end; }
.timeline__up span { display: block; width: 100%; background: var(--team-eu); }
.timeline__rule { height: 2px; background: var(--color-text); }
.timeline__down { height: 118px; }
.timeline__down span { display: block; width: 100%; background: var(--team-us); }
.timeline__label {
  font-size: 9px; letter-spacing: 0.02em; color: var(--color-neutral-600);
  padding-top: 6px; text-align: left; height: 16px;
}

/* ── rule-drawn grids ──────────────────────────────────────────────────── */

/* The container draws its left edge; each cell draws its right and bottom.
   The grid ends up ruled on all four sides without a wrapper border. */
.grid-rules {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(min(200px, 100%), 1fr));
  border-left: 1px solid var(--color-divider);
}
.grid-rules > * {
  border-right: 1px solid var(--color-divider);
  border-bottom: 1px solid var(--color-divider);
}
.grid-rules--wide { grid-template-columns: repeat(auto-fit, minmax(min(260px, 100%), 1fr)); }
.grid-rules--tight { grid-template-columns: repeat(auto-fit, minmax(min(170px, 100%), 1fr)); }
.grid-rules--panels { grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr)); }

.stat-cell { padding: 24px 20px 22px; }
.stat-cell__num {
  font-family: var(--font-heading); font-weight: 800; font-size: 52px;
  line-height: 0.9; letter-spacing: -0.04em;
}
.stat-cell__label {
  font-size: 12px; font-weight: 600; letter-spacing: 0.1em;
  text-transform: uppercase; margin-top: 10px;
}
.stat-cell__note { font-size: 12px; color: var(--color-neutral-700); margin-top: 4px; text-wrap: pretty; }

.profile-stat { padding: 22px 18px; }
.profile-stat__num {
  font-family: var(--font-heading); font-weight: 800; font-size: 44px;
  line-height: 0.9; letter-spacing: -0.04em;
}
.profile-stat__label {
  font-size: 11px; font-weight: 600; letter-spacing: 0.12em;
  text-transform: uppercase; margin-top: 10px; color: var(--color-neutral-800);
}

.fact-cell { padding: 22px 18px; }
.fact-cell__label {
  font-size: 10px; font-weight: 600; letter-spacing: 0.16em;
  text-transform: uppercase; color: var(--color-neutral-600);
}
.fact-cell__value {
  font-family: var(--font-heading); font-weight: 800; font-size: 26px;
  line-height: 1.1; letter-spacing: -0.02em; margin-top: 10px;
}

.record-cell { padding: 24px 20px; }
.record-cell__kicker {
  font-size: 10px; font-weight: 600; letter-spacing: 0.18em;
  text-transform: uppercase; color: var(--color-accent-700);
}
.record-cell__value {
  font-family: var(--font-heading); font-weight: 800; font-size: 40px;
  line-height: 1; letter-spacing: -0.03em; margin: 14px 0 8px;
}
.record-cell__name {
  display: inline-block; font-size: 17px; font-weight: 600;
  color: var(--color-text); border-bottom: 2px solid var(--color-accent);
}
.record-cell__name:hover { color: var(--color-accent); text-decoration: none; }
.record-cell__note { font-size: 12px; color: var(--color-neutral-700); margin-top: 10px; text-wrap: pretty; }

/* ── ranked bar lists ──────────────────────────────────────────────────── */

.regions {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(min(320px, 100%), 1fr));
  gap: 48px; padding-top: 28px;
}
.regions__head {
  font-size: 12px; font-weight: 600; letter-spacing: 0.14em;
  text-transform: uppercase; margin-bottom: 16px;
}
.region-row {
  display: grid; grid-template-columns: 130px 1fr 32px;
  align-items: center; gap: 12px; padding: 7px 0;
  border-bottom: 1px solid var(--color-divider);
}
.region-row__name { font-size: 14px; }
.region-row__n { font-size: 13px; font-weight: 600; text-align: right; }
.bar { height: 8px; background: var(--color-neutral-300); }
.bar > span { display: block; height: 100%; }

/* ── tables ────────────────────────────────────────────────────────────── */

.table-wrap { overflow-x: auto; }
.dtable { width: 100%; border-collapse: collapse; }
.dtable--players { min-width: 900px; }
.dtable--matches { min-width: 860px; }
.dtable--events { min-width: 820px; }
.dtable th {
  text-align: left; padding: 14px 10px;
  border-bottom: 2px solid var(--color-text);
  font-size: 10px; font-weight: 600; letter-spacing: 0.12em;
  text-transform: uppercase; white-space: nowrap;
}
.dtable--matches th { padding: 12px 10px; }
.dtable td {
  padding: var(--row-pad) 10px;
  border-bottom: 1px solid var(--color-divider);
  font-size: 14px;
}
.dtable tbody tr:hover { background: var(--color-neutral-200); }
/* Links inside a table body carry the cell's ink, not the global link red —
   a line-up is a list of names, not a list of links. */
.dtable td a { color: inherit; }
.dtable td a:hover { color: var(--color-accent); text-decoration: none; }
.dtable .num { text-align: right; font-variant-numeric: tabular-nums; }
.dtable .mid { text-align: center; }
.dtable th.mid, .dtable th.num { text-align: center; }
.dtable th.num { text-align: right; }

/* sortable headers */
.dtable th a { color: var(--color-text); display: inline-block; }
.dtable th a:hover { color: var(--color-accent); text-decoration: none; }
.dtable th[aria-sort] a { color: var(--color-accent); }

.cell-name { font-size: 15px; font-weight: 600; white-space: nowrap; }
.cell-name a { color: var(--color-text); }
.cell-name a:hover { color: var(--color-accent); text-decoration: none; }
.cell-team {
  font-size: 12px; font-weight: 600; letter-spacing: 0.08em;
  text-transform: uppercase; white-space: nowrap;
}
.cell-region { color: var(--color-neutral-800); white-space: nowrap; }
.cell-soft { color: var(--color-neutral-700); }
.cell-strong { font-weight: 600; }

.pct-cell { display: inline-flex; align-items: center; gap: 8px; }
.pct-cell .bar { width: 56px; height: 6px; }
.pct-cell__label {
  font-size: 14px; font-variant-numeric: tabular-nums;
  min-width: 46px; display: inline-block; text-align: right;
}

.cell-year a {
  font-family: var(--font-heading); font-weight: 800; font-size: 22px;
  letter-spacing: -0.02em; color: var(--color-text);
}
.cell-year a:hover { color: var(--color-accent); text-decoration: none; }
.cell-home { font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--color-neutral-700); }
.cell-score { font-size: 16px; font-weight: 600; font-variant-numeric: tabular-nums; white-space: nowrap; }
.cell-winner { font-size: 12px; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; }

.m-game { font-size: 13px; color: var(--color-neutral-600); font-variant-numeric: tabular-nums; }
.m-format {
  font-size: 11px; font-weight: 600; letter-spacing: 0.1em;
  text-transform: uppercase; color: var(--color-neutral-700); white-space: nowrap;
}
/* The video link is an affordance sitting next to a label, not a second label.
   Dropping the tracked uppercase for sentence case at a smaller size — and
   taking the accent, which the rest of the table's links deliberately do not —
   separates the two without adding a column or a second line. */
.dtable td a.m-watch {
  font-size: 10px; font-weight: 600; letter-spacing: 0.01em;
  text-transform: none; color: var(--color-accent);
  margin-left: 9px; white-space: nowrap;
}
.dtable td a.m-watch::before { content: '\25B8'; margin-right: 3px; font-size: 9px; }
.dtable td a.m-watch:hover { color: var(--color-accent); text-decoration: underline; }
.m-lineup--dim { color: var(--color-neutral-600); }
.m-running { font-size: 14px; font-variant-numeric: tabular-nums; color: var(--color-neutral-700); white-space: nowrap; }

/* ── filters ───────────────────────────────────────────────────────────── */

.filters {
  display: flex; flex-wrap: wrap; gap: 12px; align-items: flex-end;
  border-bottom: 2px solid var(--color-text); padding-bottom: 16px;
}
.filters .field { flex: 1 1 260px; margin: 0; }
.filters .input { background: var(--color-surface); border-radius: 0; }
.seg-group { display: flex; gap: 0; }
.seg-btn {
  display: inline-flex; align-items: center; text-decoration: none;
  border: 1px solid var(--color-text); border-left-width: 0;
  padding: 9px 16px; cursor: pointer; background: transparent;
  font-family: var(--font-body); font-size: 12px; font-weight: 600;
  letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--color-neutral-700);
}
.seg-group > *:first-child { border-left-width: 1px; }
.seg-btn:hover { text-decoration: none; color: var(--color-text); }
.seg-btn[aria-pressed="true"], .seg-btn[aria-current="true"] { background: var(--color-text); color: var(--color-bg); }
.seg-btn--soft {
  border-color: var(--color-divider); padding: 9px 14px;
  font-weight: 400; letter-spacing: 0.06em;
}
.seg-btn--soft[aria-pressed="true"], .seg-btn--soft[aria-current="true"] { background: var(--color-neutral-200); color: var(--color-text); }
.filters__submit { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.filters__submit:focus { position: static; width: auto; height: auto; clip: auto; }

.empty-note { padding: 40px 0; font-size: 15px; color: var(--color-neutral-700); }

/* ── player profile ────────────────────────────────────────────────────── */

.profile-head { padding: 32px var(--shell-pad) 36px; max-width: var(--shell-max); margin: 0 auto; }
.profile-head__row {
  display: flex; flex-wrap: wrap; align-items: flex-end;
  gap: 24px; justify-content: space-between;
}
.profile-team {
  font-size: 12px; font-weight: 600; letter-spacing: 0.18em;
  text-transform: uppercase; margin-bottom: 10px;
}
.profile-name {
  margin: 0; font-family: var(--font-heading); font-weight: 800;
  font-size: clamp(40px, 7vw, 84px); line-height: 0.92;
  letter-spacing: -0.04em; text-transform: uppercase;
}
.tags { display: flex; gap: 10px; flex-wrap: wrap; }
.tags .tag { font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase; }
.back-link { display: inline-block; margin-bottom: 20px; }

.two-col {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(min(320px, 100%), 1fr));
  gap: 48px; padding: 44px 0 0;
}
.col-head {
  font-size: 13px; font-weight: 600; letter-spacing: 0.14em;
  text-transform: uppercase; border-bottom: 2px solid var(--color-text);
  padding-bottom: 8px; margin-bottom: 20px;
}
.format-row { padding: 14px 0; border-bottom: 1px solid var(--color-divider); }
.format-row__top { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; margin-bottom: 8px; }
.format-row__label { font-size: 14px; font-weight: 600; }
.format-row__detail { font-size: 14px; font-variant-numeric: tabular-nums; color: var(--color-neutral-800); }
.format-row .bar { height: 10px; }
.format-row .bar > span { background: var(--color-accent); }

.mvp-row {
  display: flex; justify-content: space-between; align-items: baseline; gap: 16px;
  border-bottom: 1px solid var(--color-divider); padding: 16px 0;
  color: var(--color-text);
}
.mvp-row:hover { background: var(--color-neutral-200); text-decoration: none; color: var(--color-text); }
.mvp-row__year {
  font-family: var(--font-heading); font-weight: 800; font-size: 30px;
  letter-spacing: -0.02em; color: var(--color-accent);
}
.mvp-row__venue { font-size: 13px; color: var(--color-neutral-800); text-align: right; }

.btn-wide {
  display: flex; align-items: center; justify-content: flex-start;
  width: 100%; margin-top: 28px; padding: 12px 14px;
  border: 1px solid var(--color-divider); background: transparent;
  font-family: var(--font-heading); font-weight: 800;
  font-size: 12px; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--color-text); text-align: left;
}
.btn-wide:hover { background: var(--color-neutral-200); text-decoration: none; color: var(--color-text); }

/* ── event card ────────────────────────────────────────────────────────── */

.year-tabs { display: flex; gap: 6px; overflow-x: auto; padding-bottom: 22px; }
.year-tab {
  border: 1px solid var(--color-text); padding: 7px 12px;
  font-family: var(--font-body); font-size: 13px; font-weight: 600;
  font-variant-numeric: tabular-nums; color: var(--color-text);
  background: transparent; white-space: nowrap;
}
.year-tab:hover { background: var(--color-neutral-200); text-decoration: none; color: var(--color-text); }
.year-tab[aria-current="page"] { background: var(--color-text); color: var(--color-bg); }

.event-head { padding: 36px var(--shell-pad) 32px; max-width: var(--shell-max); margin: 0 auto; }
.event-head__row {
  display: flex; flex-wrap: wrap; gap: 40px;
  align-items: flex-end; justify-content: space-between;
}
.event-title {
  margin: 0; font-family: var(--font-heading); font-weight: 800;
  font-size: clamp(44px, 8vw, 96px); line-height: 0.9; letter-spacing: -0.045em;
}
.event-head .kicker { display: block; margin-bottom: 12px; }
.event-score { display: grid; grid-template-columns: auto auto auto; align-items: end; gap: 18px; }
.event-score__label { font-size: 11px; font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase; }
.event-score__num {
  font-family: var(--font-heading); font-weight: 800; font-size: 72px;
  line-height: 0.85; letter-spacing: -0.05em;
}
.event-score__dash {
  font-family: var(--font-heading); font-weight: 800; font-size: 34px;
  color: var(--color-neutral-400); padding-bottom: 8px;
}
.section-head--matches { padding-top: 44px; margin-bottom: 24px; }

.panel {
  border: 1px solid var(--color-divider); background: var(--color-surface);
  padding: 32px 24px; display: flex; flex-wrap: wrap; gap: 24px;
  align-items: center; justify-content: space-between;
}
.panel__title {
  font-family: var(--font-heading); font-weight: 800; font-size: 22px;
  letter-spacing: -0.02em; margin-bottom: 8px;
}
.panel__body { font-size: 14px; color: var(--color-neutral-800); text-wrap: pretty; }
.panel--flat { display: block; padding: 20px 22px; font-size: 14px; color: var(--color-neutral-800); }

/* ── leaderboards ──────────────────────────────────────────────────────── */

.boards { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(380px, 100%), 1fr)); gap: 48px; }
.board-head {
  display: flex; align-items: baseline; justify-content: space-between; gap: 12px;
  border-bottom: 2px solid var(--color-text); padding-bottom: 8px;
}
.board-head h2 {
  margin: 0; font-family: var(--font-body); font-size: 14px; font-weight: 600;
  letter-spacing: 0.12em; text-transform: uppercase;
}
.board-head span { font-size: 11px; color: var(--color-neutral-600); text-align: right; }
.board-row {
  display: grid; grid-template-columns: 28px 1fr auto; align-items: center; gap: 14px;
  border-bottom: 1px solid var(--color-divider); padding: 15px 0;
  color: var(--color-text);
}
.board-row:hover { background: var(--color-neutral-200); text-decoration: none; color: var(--color-text); }
.board-row__rank { font-size: 13px; font-variant-numeric: tabular-nums; color: var(--color-neutral-600); }
.board-row__name { display: block; font-size: 17px; font-weight: 600; }
.board-row__sub { display: block; font-size: 12px; color: var(--color-neutral-700); margin-top: 2px; }
.board-row__value {
  font-family: var(--font-heading); font-weight: 800; font-size: 26px;
  letter-spacing: -0.02em; font-variant-numeric: tabular-nums;
}

/* ── head-to-head ──────────────────────────────────────────────────────── */

.sides {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr));
  border-top: 2px solid var(--color-text); border-bottom: 2px solid var(--color-text);
  margin-bottom: 44px;
}
.side { padding: 22px 22px 24px; border-right: 1px solid var(--color-divider); border-top: 6px solid; }
.side--eu { border-top-color: var(--team-eu); }
.side--us { border-top-color: var(--team-us); }
.side__label { font-size: 10px; font-weight: 600; letter-spacing: 0.18em; text-transform: uppercase; }
.side__name {
  font-family: var(--font-heading); font-weight: 800;
  font-size: clamp(26px, 3vw, 38px); line-height: 1.05; letter-spacing: -0.03em;
  margin: 12px 0 4px; min-height: 42px;
}
.side__region { font-size: 13px; color: var(--color-neutral-700); min-height: 18px; }
.side__stats { font-size: 13px; color: var(--color-neutral-800); margin-top: 6px; font-variant-numeric: tabular-nums; min-height: 18px; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 18px 0 14px; }
.chip {
  border: 1px solid; padding: 6px 11px; background: transparent;
  font-family: var(--font-body); font-size: 12px; font-weight: 600;
  letter-spacing: 0.06em; text-transform: uppercase;
  color: var(--color-neutral-800);
}
.chip:hover { opacity: 0.75; text-decoration: none; }
.chip--eu { border-color: var(--team-eu); }
.chip--us { border-color: var(--team-us); }
.chip--eu[aria-current="true"] { background: var(--team-eu); color: var(--color-bg); }
.chip--us[aria-current="true"] { background: var(--team-us); color: var(--color-bg); }
.side .field { margin: 0; }
.side select.input { border-radius: 0; background: var(--color-surface); }

.h2h-panel { border: 2px solid var(--color-text); margin-bottom: 44px; }
.h2h-panel__head {
  display: flex; flex-wrap: wrap; gap: 24px; align-items: center;
  justify-content: space-between; padding: 22px 22px 20px;
  border-bottom: 2px solid var(--color-text);
}
.h2h-panel__count { font-size: 10px; font-weight: 600; letter-spacing: 0.18em; text-transform: uppercase; color: var(--color-neutral-600); }
.h2h-panel__scores { display: flex; align-items: baseline; gap: 14px; margin-top: 10px; }
.h2h-panel__num {
  font-family: var(--font-heading); font-weight: 800; font-size: 46px;
  line-height: 1; letter-spacing: -0.03em;
}
.h2h-panel__dash { font-family: var(--font-heading); font-weight: 800; font-size: 24px; color: var(--color-neutral-400); }
.h2h-panel__vs { font-size: 14px; color: var(--color-neutral-800); text-align: right; }
.h2h-row {
  display: grid; grid-template-columns: 70px 110px 1fr auto;
  align-items: center; gap: 16px; padding: 14px 22px;
  border-bottom: 1px solid var(--color-divider);
}
.h2h-row__year { font-family: var(--font-heading); font-weight: 800; font-size: 18px; }
.h2h-row__type { font-size: 11px; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; color: var(--color-neutral-700); }
/* A meeting is between two sides of a table, so the row names both of them and
   which way it went. The winning side carries its team's colour; "beat" and the
   losing side sit back, so the sentence reads before the detail does. */
.h2h-row__mid { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.h2h-row__winner { font-size: 14px; font-weight: 600; }
.h2h-row__beat { font-size: 12px; color: var(--color-neutral-600); }
.h2h-row__loser { color: var(--color-neutral-800); }

/* "optional" beside a field label, without shouting like the label does. */
.field__hint {
  font-weight: 400; letter-spacing: 0; text-transform: none;
  color: var(--color-neutral-600); margin-left: 5px;
}
.h2h-row__score { font-size: 15px; font-variant-numeric: tabular-nums; }

.compare-row {
  display: grid; grid-template-columns: 1fr 150px 1fr;
  align-items: center; gap: 14px; padding: 9px 0;
  border-bottom: 1px solid var(--color-divider);
}
.compare-row__a { display: flex; align-items: center; gap: 12px; justify-content: flex-end; }
.compare-row__b { display: flex; align-items: center; gap: 12px; }
.compare-row__label {
  font-size: 11px; font-weight: 600; letter-spacing: 0.1em;
  text-transform: uppercase; text-align: center; color: var(--color-neutral-700);
}
.compare-track { flex: 1; height: 20px; background: var(--color-neutral-200); }
.compare-track > span { display: block; height: 100%; }
.compare-track--a { display: flex; justify-content: flex-end; }
.compare-track--a > span { background: var(--team-eu); }
.compare-track--b > span { background: var(--team-us); }
.compare-val { font-family: var(--font-heading); font-size: 20px; font-variant-numeric: tabular-nums; font-weight: 400; }
.compare-val.is-lead { font-weight: 800; }

/* ── live ──────────────────────────────────────────────────────────────── */

.live-status { background: var(--color-text); color: var(--color-bg); border-bottom: 2px solid var(--color-text); }
.live-status__inner {
  max-width: var(--shell-max); margin: 0 auto; padding: 14px var(--shell-pad);
  display: flex; flex-wrap: wrap; gap: 16px; align-items: center; justify-content: space-between;
}
.live-status__left { display: flex; align-items: center; gap: 10px; }
.live-dot { width: 10px; height: 10px; background: var(--color-accent-500); animation: msPulse 1.4s infinite; }
.live-badge { font-size: 11px; font-weight: 600; letter-spacing: 0.2em; text-transform: uppercase; }
.live-clock { font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; opacity: 0.7; }

.live-head { padding: 44px var(--shell-pad) 40px; max-width: var(--shell-max); margin: 0 auto; }
.live-board {
  display: grid; grid-template-columns: 1fr auto 1fr;
  align-items: center; gap: 20px; max-width: 1000px;
}
.live-board__label { font-size: 13px; font-weight: 600; letter-spacing: 0.18em; text-transform: uppercase; }
.live-board__num {
  font-family: var(--font-heading); font-weight: 800;
  font-size: clamp(80px, 13vw, 160px); line-height: 0.85; letter-spacing: -0.05em;
}
.live-board__raceto { text-align: center; }
.live-board__raceto span { font-size: 11px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--color-neutral-600); }
.live-board__raceto strong { display: block; font-family: var(--font-heading); font-weight: 800; font-size: 34px; line-height: 1; }
.live-progress { max-width: 1000px; margin-top: 28px; }
.live-progress__track { display: flex; height: 12px; background: var(--color-neutral-300); }
.live-progress__eu { background: var(--team-eu); }
.live-progress__us { margin-left: auto; background: var(--team-us); }
.live-progress__note {
  font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--color-neutral-700); margin-top: 10px;
}
.live-panel { padding: 26px 20px; }
.live-panel__kicker {
  font-size: 10px; font-weight: 600; letter-spacing: 0.18em;
  text-transform: uppercase; color: var(--color-accent-700); margin-bottom: 14px;
}
.live-panel__title { font-family: var(--font-heading); font-weight: 800; font-size: 28px; line-height: 1.1; letter-spacing: -0.02em; }
.live-panel__body { font-size: 14px; color: var(--color-neutral-800); margin-top: 10px; text-wrap: pretty; }

/* ── error pages ───────────────────────────────────────────────────────── */

.error-page { padding: 96px var(--shell-pad); max-width: var(--shell-max); margin: 0 auto; }
.error-code {
  font-family: var(--font-heading); font-weight: 800;
  font-size: clamp(88px, 15vw, 190px); line-height: 0.82;
  letter-spacing: -0.05em; color: var(--color-accent);
}
.error-body { font-size: 15px; color: var(--color-neutral-800); max-width: 560px; margin-top: 16px; text-wrap: pretty; }

/* ── narrow viewports ──────────────────────────────────────────────────── */

@media (max-width: 720px) {
  :root { --shell-pad: 16px; }
  .section-note { white-space: normal; }
  .board-head { flex-wrap: wrap; gap: 2px 12px; }
  .site-nav { margin-left: 0; padding-bottom: 4px; }
  .site-nav a { padding: 10px 8px 8px; }
  .h2h-row { grid-template-columns: 56px 1fr; row-gap: 4px; }
  .h2h-row__score { grid-column: 2; text-align: right; }
  .compare-row { grid-template-columns: 1fr; gap: 6px; }
  .compare-row__label { text-align: left; order: -1; }
  .region-row { grid-template-columns: 96px 1fr 28px; }
}

/* An edition on the calendar but not yet played: venue and captains are known,
   the score is not. */
.cell-pending { color: var(--color-neutral-600); }
