/* Layout: app shell. Desktop = fixed sidebar + scrolling main column; phone = top bar + bottom tab bar.
   Match rows are the core unit: time · teams · H/D/A probability bar · likeliest score. */
:root {
  --bg: #eef1f5;
  --surface: #ffffff;
  --surface-2: #f5f7fa;
  --ink: #0d1b2a;
  --ink-2: #33475c;
  --muted: #5d6e81;
  --line: #dde4ec;
  --brand: #0f7f63;
  --brand-ink: #ffffff;
  --gold: #e2a400;
  --gold-soft: #fff4d1;
  --home: #0f8b6c;
  --draw: #a2adbb;
  --away: #e0603a;
  --good: #11865f;
  --bad: #cf3f2a;
  --night: #0b1c2c;
  --night-2: #12304a;
  --shadow: 0 1px 2px rgb(13 27 42 / .06), 0 6px 18px -8px rgb(13 27 42 / .14);
  --display: "Big Shoulders Display", "Arial Narrow", system-ui, sans-serif;
  --body: "Figtree", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, Menlo, Consolas, monospace;
  --r: 14px;
  --sidebar: 260px;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #07121b; --surface: #0e1d2a; --surface-2: #132637; --ink: #e7eef5; --ink-2: #c3d0dc;
    --muted: #8ea2b5; --line: #1d3345; --brand: #27b88f; --brand-ink: #04140e; --gold: #ffc83d;
    --gold-soft: #3a2f0c; --home: #2bbf94; --draw: #6c7d8f; --away: #ff7a52; --good: #3fd19c; --bad: #ff6b55;
    --night: #040b11; --night-2: #0d2233; --shadow: 0 1px 2px rgb(0 0 0 / .4), 0 10px 24px -12px rgb(0 0 0 / .6);
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #07121b; --surface: #0e1d2a; --surface-2: #132637; --ink: #e7eef5; --ink-2: #c3d0dc;
  --muted: #8ea2b5; --line: #1d3345; --brand: #27b88f; --brand-ink: #04140e; --gold: #ffc83d;
  --gold-soft: #3a2f0c; --home: #2bbf94; --draw: #6c7d8f; --away: #ff7a52; --good: #3fd19c; --bad: #ff6b55;
  --night: #040b11; --night-2: #0d2233; --shadow: 0 1px 2px rgb(0 0 0 / .4), 0 10px 24px -12px rgb(0 0 0 / .6);
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 80px; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 15px/1.5 var(--body); font-variant-numeric: tabular-nums; }
a { color: inherit; }
button { font: inherit; color: inherit; }
img { max-width: 100%; display: block; }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; border-radius: 6px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- shell ---------- */
.shell { min-height: 100vh; }
.sidebar {
  position: fixed; inset: 0 auto 0 0; width: var(--sidebar); background: var(--night); color: #e8f0f7;
  display: flex; flex-direction: column; gap: 18px; padding: 22px 16px max(18px, env(safe-area-inset-bottom)) max(16px, env(safe-area-inset-left));
  overflow-y: auto; z-index: 30;
}
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; padding: 0 8px; }
.brand-mark { width: 34px; height: 34px; flex: none; }
.brand-name { font: 800 23px/1 var(--display); letter-spacing: .02em; text-transform: uppercase; }
.brand-name small { display: block; font: 500 11px/1.4 var(--body); letter-spacing: .04em; text-transform: none; color: #8ea8bf; }
.nav { display: grid; gap: 2px; }
.nav-label { font: 600 11px/1 var(--body); letter-spacing: .12em; text-transform: uppercase; color: #6f8aa3; padding: 14px 10px 6px; }
.nav a {
  display: flex; align-items: center; gap: 10px; padding: 9px 10px; border-radius: 10px; text-decoration: none;
  color: #c4d3e0; font-weight: 600; font-size: 14px;
}
.nav a:hover { background: rgb(255 255 255 / .06); color: #fff; }
.nav a[aria-current="page"] { background: rgb(255 255 255 / .1); color: #fff; box-shadow: inset 3px 0 0 #27b88f; }
.nav svg { width: 18px; height: 18px; flex: none; opacity: .9; }
.tag { font: 700 10px/1 var(--mono); letter-spacing: .04em; padding: 4px 5px; border-radius: 5px; background: rgb(255 255 255 / .08); color: #9fb6ca; min-width: 34px; text-align: center; }
.nav a[aria-current="page"] .tag { background: #27b88f; color: #04140e; }
.sidebar-foot { margin-top: auto; font-size: 12px; color: #7f97ad; padding: 0 10px; display: grid; gap: 10px; }
.theme-btn { display: inline-flex; align-items: center; gap: 8px; background: rgb(255 255 255 / .07); border: 1px solid rgb(255 255 255 / .1); border-radius: 999px; padding: 6px 12px; cursor: pointer; color: #d6e2ec; font-size: 13px; width: max-content; }

.main { margin-left: var(--sidebar); min-width: 0; }
.topbar { display: none; }
.content { max-width: 1120px; margin: 0 auto; padding-block: 24px 64px; padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); display: grid; gap: 22px; }
.tabbar { display: none; }

@media (max-width: 960px) {
  .sidebar { display: none; }
  .main { margin-left: 0; }
  body::before { content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px); z-index: 41; background: var(--night); }
  .topbar {
    display: flex; position: sticky; top: env(safe-area-inset-top, 0px); z-index: 40; align-items: center; justify-content: space-between; gap: 12px;
    background: color-mix(in srgb, var(--night) 92%, transparent); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); color: #e8f0f7;
    padding-block: 10px; padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px));
  }
  .topbar .brand { padding: 0; }
  .topbar .brand-mark { width: 28px; height: 28px; }
  .topbar .brand-name { font-size: 20px; }
  .content { padding-bottom: calc(96px + env(safe-area-inset-bottom, 0px)); }
  .tabbar {
    display: grid; grid-template-columns: repeat(5, 1fr); position: fixed; left: 0; right: 0; bottom: 0; z-index: 40;
    background: color-mix(in srgb, var(--surface) 90%, transparent); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
    border-top: 1px solid var(--line);
    padding: 6px max(6px, env(safe-area-inset-right, 0px)) calc(6px + env(safe-area-inset-bottom, 0px)) max(6px, env(safe-area-inset-left, 0px));
  }
  .tabbar a { display: grid; justify-items: center; gap: 3px; text-decoration: none; font-size: 11px; font-weight: 600; color: var(--muted); padding: 6px 2px; border-radius: 10px; }
  .tabbar a[aria-current="page"] { color: var(--brand); }
  .tabbar svg { width: 22px; height: 22px; }
}

/* ---------- league sheet (phone) ---------- */
.sheet-backdrop { position: fixed; inset: 0; background: rgb(4 11 17 / .5); z-index: 50; opacity: 0; transition: opacity .2s; }
.sheet { position: fixed; left: 0; right: 0; bottom: 0; z-index: 51; background: var(--surface); border-radius: 20px 20px 0 0; max-height: 80vh; overflow-y: auto;
  padding: 10px max(16px, env(safe-area-inset-right, 0px)) calc(20px + env(safe-area-inset-bottom, 0px)) max(16px, env(safe-area-inset-left, 0px));
  transform: translateY(100%); transition: transform .28s cubic-bezier(.2, .8, .2, 1); }
.sheet.open { transform: none; }
.sheet-backdrop.open { opacity: 1; }
.sheet-grip { width: 40px; height: 5px; border-radius: 3px; background: var(--line); margin: 4px auto 12px; }
.sheet h2 { margin: 0 0 8px; }
.sheet-list { display: grid; gap: 4px; }
.sheet-list a { display: flex; align-items: center; gap: 12px; padding: 12px; border-radius: 12px; text-decoration: none; font-weight: 600; }
.sheet-list a:hover, .sheet-list a:focus-visible { background: var(--surface-2); }
.sheet-list .tag { background: var(--surface-2); color: var(--ink-2); border: 1px solid var(--line); }
.sheet-list small { margin-left: auto; color: var(--muted); font-weight: 500; }

/* ---------- type ---------- */
h1, h2, h3 { margin: 0; text-wrap: balance; }
.h-display { font: 800 clamp(34px, 6vw, 54px)/.95 var(--display); text-transform: uppercase; letter-spacing: .005em; }
h2.section { font: 800 24px/1.05 var(--display); text-transform: uppercase; letter-spacing: .02em; }
h3 { font-size: 16px; font-weight: 700; }
.eyebrow { font: 600 11px/1.2 var(--body); letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.mono { font-family: var(--mono); font-size: 12px; }
p { margin: 0; }
.prose { max-width: 66ch; display: grid; gap: 10px; color: var(--ink-2); }

/* ---------- hero ---------- */
.hero {
  position: relative; overflow: hidden; border-radius: 22px; color: #fff; background: var(--night);
  min-height: 240px; display: grid; align-content: end; isolation: isolate;
}
.hero-img { position: absolute; inset: -40px 0 0 0; width: 100%; height: calc(100% + 40px); object-fit: cover; z-index: -2; will-change: transform; opacity: .85; }
.hero::after { content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(105deg, rgb(7 18 27 / .95) 15%, rgb(7 18 27 / .65) 55%, rgb(7 18 27 / .2)), radial-gradient(60% 80% at 85% 0%, rgb(39 184 143 / .35), transparent 70%); }
.hero-body { padding: 26px clamp(18px, 4vw, 34px) 24px; display: grid; gap: 14px; max-width: 760px; }
.hero .eyebrow { color: #9fd9c4; }
.hero p { color: #c9d8e4; max-width: 56ch; }
.hero-stats { display: flex; flex-wrap: wrap; gap: 10px 26px; }
.hero-stat b { display: block; font: 800 34px/1 var(--display); }
.hero-stat span { font-size: 12px; color: #a9bccb; }
.hero.compact { min-height: 0; }
.hero.compact .hero-body { padding-block: 22px; }

/* ---------- chips / tabs ---------- */
.chips { display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; padding: 2px; margin: -2px; }
.chips::-webkit-scrollbar { display: none; }
.chip {
  flex: none; display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--line); background: var(--surface); color: var(--ink-2);
  border-radius: 999px; padding: 7px 13px; font-size: 13px; font-weight: 600; cursor: pointer; text-decoration: none; white-space: nowrap;
}
.chip:hover { border-color: color-mix(in srgb, var(--brand) 50%, var(--line)); }
.chip[aria-pressed="true"], .chip[aria-current="page"] { background: var(--ink); color: var(--bg); border-color: var(--ink); }
.chip .n { font: 600 11px/1 var(--mono); opacity: .7; }
.tabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); overflow-x: auto; scrollbar-width: none; }
.tabs::-webkit-scrollbar { display: none; }
.tabs a { flex: none; padding: 10px 14px; text-decoration: none; font-weight: 700; font-size: 14px; color: var(--muted); border-bottom: 2px solid transparent; margin-bottom: -1px; }
.tabs a[aria-current="page"] { color: var(--ink); border-color: var(--brand); }

/* ---------- cards / panels ---------- */
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow); }
.panel-pad { padding: 18px; }
.panel-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; flex-wrap: wrap; padding: 16px 18px 10px; }
.grid-2.top { align-items: start; }
.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
@media (max-width: 860px) { .grid-2, .grid-3 { grid-template-columns: minmax(0, 1fr); } }
.stack { display: grid; gap: 14px; }
.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.spread { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; flex-wrap: wrap; }

/* ---------- match rows ---------- */
.day-head { display: flex; align-items: baseline; gap: 10px; padding: 14px 18px 6px; }
.day-head h3 { font: 800 17px/1 var(--display); text-transform: uppercase; letter-spacing: .04em; }
.league-head { display: flex; align-items: center; gap: 8px; padding: 12px 18px 4px; font-weight: 700; font-size: 13px; color: var(--ink-2); text-decoration: none; }
.league-head .tag { background: var(--surface-2); color: var(--ink-2); border: 1px solid var(--line); }
.mrow {
  display: grid; grid-template-columns: 54px minmax(0, 1fr) minmax(150px, 220px) 52px; gap: 14px; align-items: center;
  padding: 11px 18px; text-decoration: none; border-top: 1px solid var(--line); position: relative; transition: background .15s;
}
.mrow:hover { background: var(--surface-2); }
.mrow .ko { font: 600 12px/1.25 var(--mono); color: var(--muted); }
.mrow .ko b { display: block; color: var(--ink); font-size: 13px; }
.teams { display: grid; gap: 3px; min-width: 0; }
.team-line { display: flex; align-items: center; gap: 8px; min-width: 0; font-weight: 600; }
.team-line span.nm { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.team-line.fav span.nm { font-weight: 800; }
.team-line .sc { margin-left: auto; font: 800 17px/1 var(--display); }
.crest { width: 20px; height: 20px; border-radius: 6px; flex: none; display: inline-grid; vertical-align: middle; margin-right: 2px; place-items: center; font: 800 10px/1 var(--display); color: #fff; letter-spacing: .02em; }
.badges { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 3px; }
.badge { font: 700 10px/1 var(--body); letter-spacing: .06em; text-transform: uppercase; padding: 4px 7px; border-radius: 6px; }
.badge.strong { background: color-mix(in srgb, var(--brand) 14%, transparent); color: var(--brand); }
.badge.value { background: var(--gold-soft); color: color-mix(in srgb, var(--gold) 75%, var(--ink)); }
.badge.live { background: color-mix(in srgb, var(--away) 15%, transparent); color: var(--away); }
.badge.hit { background: color-mix(in srgb, var(--good) 15%, transparent); color: var(--good); }
.badge.miss { background: color-mix(in srgb, var(--bad) 13%, transparent); color: var(--bad); }
.likely { text-align: center; font: 800 20px/1 var(--display); }
.likely small { display: block; font: 500 10px/1.3 var(--body); color: var(--muted); letter-spacing: .04em; text-transform: uppercase; margin-top: 3px; }
@media (max-width: 640px) {
  .mrow { grid-template-columns: 44px minmax(0, 1fr) 44px; row-gap: 8px; padding: 12px 14px; }
  .mrow .tri { grid-column: 1 / -1; }
  .likely { grid-row: 1; grid-column: 3; }
}

/* probability tri-bar */
.tri { display: grid; gap: 4px; }
.tri-bar { display: flex; height: 10px; border-radius: 99px; overflow: hidden; background: var(--surface-2); gap: 2px; }
.tri-bar i { display: block; height: 100%; transition: flex-grow .7s cubic-bezier(.2, .8, .2, 1); }
.tri-bar .h { background: var(--home); } .tri-bar .d { background: var(--draw); } .tri-bar .a { background: var(--away); }
.tri-nums { display: flex; justify-content: space-between; font: 600 11px/1 var(--mono); color: var(--muted); }
.tri-nums b { color: var(--ink); font-weight: 700; }
.tri.big .tri-bar { height: 16px; }

/* ---------- top picks carousel ---------- */
.rail { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(250px, 300px); gap: 14px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 4px 2px 10px; scrollbar-width: thin; }
.pick { scroll-snap-align: start; display: grid; gap: 12px; padding: 16px; text-decoration: none; transition: transform .2s, box-shadow .2s; }
.pick:hover { transform: translateY(-3px); }
.pick .big { font: 800 44px/.9 var(--display); }
.pick-who { font-weight: 700; font-size: 14px; margin-top: 4px; }

/* ---------- tables ---------- */
.tbl-wrap { overflow-x: auto; max-width: 100%; }
.content > *, .panel, .stack > *, .grid-2 > *, .grid-3 > * { min-width: 0; }
table { width: 100%; border-collapse: collapse; font-size: 13.5px; }
th { text-align: left; font: 600 11px/1.2 var(--body); letter-spacing: .06em; text-transform: uppercase; color: var(--muted); padding: 10px 10px; border-bottom: 1px solid var(--line); white-space: nowrap; background: var(--surface); position: sticky; top: 0; }
th.sortable { cursor: pointer; user-select: none; }
th.sortable:hover { color: var(--ink); }
th[aria-sort] { color: var(--ink); }
td { padding: 9px 10px; border-bottom: 1px solid var(--line); white-space: nowrap; }
tbody tr:last-child td { border-bottom: 0; }
tbody tr:hover td { background: var(--surface-2); }
td.n, th.n { text-align: right; font-family: var(--mono); font-size: 12.5px; }
td.team { font-weight: 600; }
td.team a { text-decoration: none; }
td.pos { width: 36px; color: var(--muted); font-family: var(--mono); font-size: 12px; }
.form { display: inline-flex; gap: 3px; }
.form i { width: 18px; height: 18px; border-radius: 5px; display: grid; place-items: center; font: 700 10px/1 var(--mono); font-style: normal; color: #fff; }
.form .W { background: var(--good); } .form .D { background: var(--draw); } .form .L { background: var(--bad); }

/* ---------- stat tiles ---------- */
.tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 1px; background: var(--line); border-radius: var(--r); overflow: hidden; border: 1px solid var(--line); }
.tile { background: var(--surface); padding: 14px 16px; display: grid; gap: 4px; }
.tile b { font: 800 30px/1 var(--display); }
.tile span { font-size: 12.5px; color: var(--muted); line-height: 1.3; }

/* ---------- match page ---------- */
.mhero { background: linear-gradient(160deg, var(--night-2), var(--night)); color: #fff; border-radius: 22px; padding: 22px clamp(16px, 4vw, 30px) 24px; display: grid; gap: 18px; position: relative; overflow: hidden; }
.mhero::before { content: ""; position: absolute; inset: 0; background: radial-gradient(50% 70% at 50% -10%, rgb(39 184 143 / .28), transparent 70%); pointer-events: none; }
.mhero > * { position: relative; }
.mhero .meta { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 14px; font-size: 13px; color: #a9bccb; }
.versus { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); align-items: center; gap: 14px; }
.side { display: grid; justify-items: center; gap: 8px; text-align: center; min-width: 0; }
.side .crest { width: 54px; height: 54px; border-radius: 16px; font-size: 20px; }
.side .nm { font: 800 clamp(17px, 3.5vw, 30px)/1.05 var(--display); text-transform: uppercase; overflow-wrap: break-word; hyphens: auto; max-width: 100%; }
.side .nm a, .mhero a { text-decoration: none; }
.side .nm a:hover { text-decoration: underline; }
.side .pct { font: 800 clamp(30px, 6vw, 46px)/1 var(--display); }
.side .lbl { font-size: 12px; color: #a9bccb; }
.centre { display: grid; justify-items: center; gap: 4px; text-align: center; }
.centre .score { font: 800 clamp(38px, 8vw, 64px)/.9 var(--display); }
.centre .lbl { font-size: 11px; letter-spacing: .1em; text-transform: uppercase; color: #a9bccb; }
.centre .draw b { font: 800 22px/1 var(--display); }
.mhero .tri-nums { color: #a9bccb; } .mhero .tri-nums b { color: #fff; }
.mhero .tri-bar { background: rgb(255 255 255 / .1); }

.kv { display: grid; gap: 0; }
.kv > div { display: flex; justify-content: space-between; gap: 12px; padding: 9px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.kv > div:last-child { border-bottom: 0; }
.kv b { font-family: var(--mono); font-size: 13px; }

.meter { display: grid; grid-template-columns: minmax(70px, 120px) minmax(0, 1fr) 48px; gap: 10px; align-items: center; font-size: 13.5px; }
.meter .bar { height: 8px; border-radius: 99px; background: var(--surface-2); overflow: hidden; }
.meter .bar i { display: block; height: 100%; background: var(--brand); border-radius: 99px; transition: width .7s cubic-bezier(.2, .8, .2, 1); }
.meter b { text-align: right; font-family: var(--mono); font-size: 12.5px; }

.heat { display: grid; grid-template-columns: 30px repeat(6, minmax(0, 1fr)); gap: 3px; font: 600 11px/1 var(--mono); }
.heat .ax { display: grid; place-items: center; color: var(--muted); padding: 6px 0; }
.heat .cell { aspect-ratio: 1.4; border-radius: 6px; display: grid; place-items: center; color: var(--ink); position: relative; cursor: default; transition: transform .15s; max-width: 100%; }
.heat .cell:hover { transform: scale(1.08); z-index: 1; box-shadow: var(--shadow); }
.heat .cell.top { outline: 2px solid var(--gold); }
.heat-cap { display: flex; justify-content: space-between; font-size: 12px; color: var(--muted); margin-top: 6px; }

.duel { display: grid; gap: 10px; }
.duel-row { display: grid; grid-template-columns: 52px minmax(0, 1fr) minmax(90px, auto) minmax(0, 1fr) 52px; align-items: center; gap: 8px; font-size: 13px; }
.duel-row .l { text-align: center; color: var(--muted); font-size: 12px; }
.duel-row .v { font-family: var(--mono); font-size: 12.5px; font-weight: 600; }
.duel-row .v.r { text-align: right; }
.duel-bar { height: 8px; border-radius: 99px; background: var(--surface-2); display: flex; overflow: hidden; }
.duel-bar.left { justify-content: flex-end; }
.duel-bar i { display: block; height: 100%; border-radius: 99px; }
.duel-bar.left i { background: var(--home); } .duel-bar.right i { background: var(--away); }
.duel-bar i.win { filter: saturate(1.2); } .duel-bar i.lose { opacity: .45; }

.odds td.best { color: var(--good); font-weight: 700; }
.edge-pos { color: var(--good); font-weight: 700; }
.edge-neg { color: var(--muted); }

/* ---------- charts ---------- */
.chart svg { width: 100%; height: auto; display: block; }
.chart text { fill: var(--muted); font: 11px var(--mono); }
.chart .lab { fill: var(--ink-2); font: 600 11px var(--body); }

/* ---------- glossary ---------- */
.gloss { display: grid; gap: 22px; }
.gloss-group { display: grid; gap: 4px; }
.gloss-group h2 { margin-bottom: 6px; }
.term { display: grid; grid-template-columns: minmax(150px, 230px) minmax(0, 1fr); gap: 6px 22px; padding: 12px 0; border-top: 1px solid var(--line); }
.term dt { font-weight: 700; }
.term dt code { display: block; font: 500 11px/1.4 var(--mono); color: var(--muted); margin-top: 2px; }
.term dd { margin: 0; color: var(--ink-2); max-width: 70ch; }
.term dd .ex { display: block; margin-top: 4px; font-size: 13px; color: var(--muted); }
@media (max-width: 640px) { .term { grid-template-columns: minmax(0, 1fr); } }
.search { width: 100%; max-width: 420px; border: 1px solid var(--line); background: var(--surface); border-radius: 12px; padding: 11px 14px; font: inherit; color: var(--ink); }

/* ---------- misc ---------- */
.empty { padding: 28px 18px; text-align: center; color: var(--muted); }
.note { font-size: 13px; color: var(--muted); padding: 12px 16px; background: var(--surface-2); border-radius: 12px; }
.callout { display: flex; gap: 12px; padding: 14px 16px; border-radius: 12px; background: var(--gold-soft); color: var(--ink); font-size: 14px; }
.footer { font-size: 12.5px; color: var(--muted); display: grid; gap: 6px; padding-top: 10px; border-top: 1px solid var(--line); }
.skel { border-radius: var(--r); background: linear-gradient(90deg, var(--surface) 0%, var(--surface-2) 50%, var(--surface) 100%); background-size: 200% 100%; animation: shimmer 1.2s infinite linear; height: 120px; border: 1px solid var(--line); }
@keyframes shimmer { to { background-position: -200% 0; } }
.fade-in { animation: rise .45s cubic-bezier(.2, .8, .2, 1) both; }
@keyframes rise { from { opacity: .001; transform: translateY(8px); } }
.linkish { color: var(--brand); font-weight: 700; text-decoration: none; font-size: 13.5px; }
.linkish:hover { text-decoration: underline; }
.btn { display: inline-flex; align-items: center; gap: 8px; border-radius: 10px; padding: 8px 14px; border: 1px solid var(--line); background: var(--surface); font-weight: 700; font-size: 13px; cursor: pointer; text-decoration: none; }
.btn:hover { border-color: var(--brand); }

::view-transition-old(main), ::view-transition-new(main) { animation-duration: .22s; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; transition-duration: .001ms !important; }
  .hero-img { transform: none !important; }
}

/* ---------- pre-rendered pages (v3) ---------- */
@view-transition { navigation: auto; }
.skip { position: absolute; left: -999px; top: 8px; z-index: 100; background: var(--gold); color: #000; padding: 8px 12px; border-radius: 8px; font-weight: 700; }
.skip:focus { left: 8px; }
.crumbs ol { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 4px 6px; font-size: 13px; color: var(--muted); }
.crumbs li:not(:last-child)::after { content: "›"; margin-left: 6px; opacity: .6; }
.crumbs a { color: var(--brand); text-decoration: none; font-weight: 600; }
.crumbs a:hover { text-decoration: underline; }
.writeup { display: grid; gap: 10px; max-width: 72ch; color: var(--ink-2); font-size: 15.5px; line-height: 1.6; }
.writeup h2 { margin-top: 10px; }
.writeup.about { max-width: 70ch; }
.lead { font-size: 17px; color: var(--ink-2); max-width: 64ch; }
.h-page { color: var(--ink); }
.card-title { font: 800 24px/1 var(--display); text-transform: uppercase; }
.ink { color: var(--ink); }
.grid-3 .tag, .panel .tag { background: var(--surface-2); color: var(--ink-2); border: 1px solid var(--line); }
.filters { padding: 0 18px 12px; display: grid; gap: 10px; }
.mrow.simple { grid-template-columns: minmax(0, 1fr) auto; }
.row-line { padding: 6px 0; border-bottom: 1px solid var(--line); }
.crest.xl { width: 54px; height: 54px; border-radius: 16px; font-size: 20px; }
.crest.xxl { width: 68px; height: 68px; border-radius: 18px; font-size: 26px; }
.match-h1 { font: 800 clamp(20px, 3.4vw, 30px)/1.05 var(--display); text-transform: uppercase; text-align: center; letter-spacing: .01em; color: #fff; }
.match-h1.left { text-align: left; font-size: clamp(30px, 5vw, 46px); }
.mhero a { color: inherit; text-decoration: none; }
.mhero .meta a:hover, .side .nm a:hover { text-decoration: underline; }
.meta.left { justify-content: flex-start; margin-top: 8px; }
.team-head { display: flex; align-items: center; gap: 18px; }
.eyebrow.on-dark, .eyebrow.on-dark a { color: #9fd9c4; }
a.on-dark { color: #9fd9c4; }
.side-link { color: #9fb6ca; text-decoration: none; }
.side-link:hover { color: #fff; }
.grid-2.tight { gap: 14px; }
.kv.two-col { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 28px; }
@media (max-width: 640px) { .kv.two-col { grid-template-columns: minmax(0, 1fr); } }
.faq .qa { border-top: 1px solid var(--line); padding-top: 12px; display: grid; gap: 4px; }
.faq .qa h3 { font-size: 15.5px; }
.faq .qa p { color: var(--ink-2); max-width: 72ch; }
.toc { display: flex; flex-wrap: wrap; gap: 6px 14px; font-weight: 600; font-size: 14px; }
.toc a { color: var(--brand); text-decoration: none; }
.term.flash { background: var(--gold-soft); border-radius: 10px; padding-inline: 8px; }
.term:target { scroll-margin-top: 90px; }
.heat .cell.hw { background: color-mix(in srgb, var(--home) var(--a), var(--surface)); }
.heat .cell.aw { background: color-mix(in srgb, var(--away) var(--a), var(--surface)); }
.heat .cell.dr { background: color-mix(in srgb, var(--draw) var(--a), var(--surface)); }
.posgrid { font-size: 11px; }
.posgrid th.n { padding: 6px 2px; text-align: center; }
.posgrid td { padding: 2px; text-align: center; }
.posgrid td.team { text-align: left; font-size: 12.5px; padding-right: 8px; }
.pg { height: 20px; min-width: 20px; border-radius: 4px; display: grid; place-items: center; font: 600 10px var(--mono); color: var(--muted);
  background: color-mix(in srgb, var(--brand) var(--a), var(--surface-2)); }
.tri-bar i, .meter .bar i, .duel-bar i { animation: grow .8s cubic-bezier(.2, .8, .2, 1) both; transform-origin: left center; }
.duel-bar.left i { transform-origin: right center; }
@keyframes grow { from { transform: scaleX(0); } }
.mhero .tri-bar i { animation-delay: .1s; }
.hero p a { font-weight: 700; }

.stack { align-content: start; }
@media (max-width: 520px) {
  .versus { gap: 8px; }
  .side .nm { font-size: 15px; hyphens: none; overflow-wrap: normal; }
  .crest.xl { width: 44px; height: 44px; font-size: 16px; }
}

/* ---------- mascot ---------- */
.brand-mark { object-fit: contain; border-radius: 10px; }
.hero.has-mascot .hero-body { padding-right: clamp(18px, 30vw, 300px); }
.hero-mascot { position: absolute; right: clamp(8px, 3vw, 36px); bottom: 0; height: 92%; max-height: 330px; width: auto; max-width: 100%; z-index: 0;
  filter: drop-shadow(0 12px 24px rgb(0 0 0 / .45)); animation: perch .9s cubic-bezier(.2, .8, .2, 1) both; }
@keyframes perch { from { transform: translateY(14px); opacity: .001; } }
@media (max-width: 700px) {
  .hero.has-mascot .hero-body { padding-right: clamp(18px, 4vw, 34px); padding-top: 12px; }
  .hero-mascot { position: relative; right: auto; bottom: auto; height: auto; width: 116px; margin: 18px 0 0 18px; }
}
.says { display: flex; align-items: center; gap: 12px; }
.says-bird { width: 56px; height: 56px; flex: none; border-radius: 16px; background: color-mix(in srgb, var(--brand) 12%, var(--surface-2)); padding: 4px; }
.lost { display: flex; flex-wrap: wrap; align-items: center; gap: 24px; }
.lost img { width: min(200px, 50%); height: auto; }
.lost .stack { flex: 1 1 280px; }
.writeup.legal { max-width: 74ch; }
.writeup.legal ul { margin: 0; padding-left: 20px; display: grid; gap: 6px; }
.writeup.legal h2 { scroll-margin-top: 90px; }
.lead-in { font-size: 16.5px; color: var(--ink); background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px; }

/* ---------- readable text for crawlers and screen readers (v5) ---------- */
.crest::before { content: attr(data-i); }
.tri-nums > span[data-l]::after { content: " " attr(data-l); }
h4.league-head { margin: 0; font: inherit; }
h4.league-head a { display: flex; align-items: center; gap: 8px; text-decoration: none; color: inherit; font-weight: 700; font-size: 13px; color: var(--ink-2); }
h4.league-head a:hover { color: var(--brand); }
.likely small[data-t]::after { content: attr(data-t); }
.day-leagues { font: 600 13px/1.3 var(--body); text-transform: none; letter-spacing: 0; color: var(--muted); }

/* ---------- advertising spaces (only appear when switched on in ads.json) ---------- */
.ad { display: grid; justify-items: center; gap: 4px; margin: 4px 0; }
.ad-label { font: 600 10px/1 var(--body); letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.ad img { max-width: 100%; height: auto; border-radius: 8px; display: block; }
.sidebar .ad { margin: 0 6px; } .sidebar .ad-label { color: #7f97ad; }
.tri, .tri-nums, .likely, .pick, .ko { position: relative; }
