/* v64resultat.se — graphite & electric orange sports design.
   Tokens from the design pack; mobile-first; no framework. */

/* ---------- font: Noto Sans variable (OFL, self-hosted, latin subset) ----------
   One file covers weight 100–900 and width 62.5–100 %. Body text uses the
   normal width; headlines use a condensed width via --heading-stretch. */
@font-face { font-family: 'Noto Sans'; font-style: normal; font-weight: 100 900; font-stretch: 62.5% 100%; font-display: swap; src: url('../fonts/noto-sans-variable-latin.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }

/* ---------- tokens ---------- */
:root {
  color-scheme: light;
  --graphite: #181c22;
  --graphite-2: #232830;
  --orange: #ff6a24;
  --orange-deep: #9a3a0c;
  --orange-tint: #ffe9de;
  --paper: #fff;
  --tint: #f3f5f7;
  --ink: #181c22;
  --muted: #56616f;
  --line: #d9dfe5;
  --correct: #176443;
  --correct-tint: #e3f4ea;
  --incorrect: #b42318;
  --incorrect-tint: #fce8e6;
  --info-tint: #eaf2fb;
  --radius: 4px;
  --page-max: 1200px;
  --gutter: clamp(16px, 4vw, 48px);
  --space-1: 4px; --space-2: 8px; --space-3: 12px; --space-4: 16px; --space-5: 24px; --space-6: 32px; --space-7: 48px; --space-8: 64px; --space-9: 96px;
  --body-font: 'Noto Sans', ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --heading-font: 'Noto Sans', 'Arial Narrow', 'Roboto Condensed', system-ui, sans-serif;
  --heading-stretch: 72%;
  --shadow-1: 0 1px 2px rgba(24, 28, 34, .06);
  --dur-fast: 120ms; --dur: 180ms; --ease: cubic-bezier(.2, .7, .2, 1);
}

/* ---------- base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 16px/1.55 var(--body-font); overflow-x: clip; }
img, svg { display: block; max-width: 100%; }
img { height: auto; }
h1, h2, h3, h4 { font-family: var(--heading-font); font-stretch: var(--heading-stretch); line-height: 1; font-weight: 800; text-transform: uppercase; letter-spacing: -.01em; margin: 0 0 var(--space-3); text-wrap: balance; }
h1 { font-size: clamp(44px, 6.6vw, 94px); letter-spacing: -.02em; }
h2 { font-size: clamp(28px, 3vw, 42px); }
h3 { font-size: clamp(22px, 2vw, 26px); }
p { margin: 0 0 var(--space-4); }
ul, ol { margin: 0 0 var(--space-4); padding-left: 1.2em; }
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: .15em; }
a:hover { color: var(--orange-deep); }
button, input, select { font: inherit; min-height: 44px; color: inherit; }
button { cursor: pointer; }
table { border-collapse: collapse; width: 100%; }
.numeric, .horse-number, .payout, .winning-chip strong { font-variant-numeric: tabular-nums; }
.container { width: min(calc(100% - 2 * var(--gutter)), var(--page-max)); margin-inline: auto; }
:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; }
.hero :focus-visible, .site-header :focus-visible, .site-footer :focus-visible, .page-band :focus-visible, .cta-band :focus-visible, .guide-card--image :focus-visible { outline-color: #fff; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
[hidden] { display: none !important; }
.skip-link { position: absolute; left: var(--space-4); top: -100px; z-index: 1000; background: var(--orange); color: var(--ink); padding: 10px 16px; border-radius: var(--radius); font-weight: 700; text-decoration: none; }
.skip-link:focus { top: var(--space-4); }
main:focus { outline: none; }

/* ---------- decorative speed stripes ---------- */
.speed-stripes { position: absolute; inset: auto 0 0 auto; width: 260px; height: 100%; pointer-events: none; overflow: hidden; }
.speed-stripes::before, .speed-stripes::after { content: ""; position: absolute; top: -20%; height: 140%; width: 36px; background: var(--orange); transform: skewX(-24deg); opacity: .92; }
.speed-stripes::before { right: 40px; }
.speed-stripes::after { right: 96px; width: 18px; opacity: .55; }
.speed-stripes--hero { width: 200px; }
.speed-stripes--hero::before { right: 24px; width: 28px; top: 55%; height: 60%; }
.speed-stripes--hero::after { right: 70px; width: 14px; top: 62%; height: 60%; }

/* ---------- buttons & links ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: var(--space-2); min-height: 48px; padding: 12px 22px; border-radius: var(--radius); font-weight: 700; text-decoration: none; border: 1px solid transparent; transition: background-color var(--dur) var(--ease), color var(--dur) var(--ease), border-color var(--dur) var(--ease), transform var(--dur-fast) var(--ease); touch-action: manipulation; }
.btn .icon { width: 20px; height: 20px; flex: none; }
.btn:active { transform: translateY(1px); }
.btn--primary { background: var(--orange); color: var(--ink); border-color: var(--orange); }
.btn--primary:hover { background: #ff7f47; color: var(--ink); }
.btn--secondary { background: transparent; color: inherit; border-color: currentColor; }
.btn--secondary:hover { background: rgba(24, 28, 34, .06); color: inherit; }
.hero .btn--secondary, .page-band .btn--secondary, .site-footer .btn--secondary { border-color: #fff; }
.hero .btn--secondary:hover { background: rgba(255, 255, 255, .1); }
.btn--link { background: none; border: 0; padding: 12px 8px; text-decoration: underline; text-underline-offset: .2em; font-weight: 600; color: var(--muted); }
.btn--link:hover { color: var(--ink); }
.btn--large { min-height: 56px; padding: 14px 28px; font-size: 18px; }
.btn:disabled, .btn[aria-disabled="true"] { background: var(--line); color: var(--muted); border-color: var(--line); cursor: default; transform: none; }
.text-link { display: inline-flex; align-items: center; gap: var(--space-2); font-weight: 600; text-decoration: underline; text-underline-offset: .2em; min-height: 44px; }
.text-link .icon { width: 18px; height: 18px; }
.text-link--light { color: #fff; }
.text-link--light:hover { color: var(--orange); }
.actions { display: flex; flex-wrap: wrap; gap: var(--space-3); margin: var(--space-5) 0 var(--space-4); }
.actions--inline { margin-top: var(--space-5); }
.actions--three .btn { flex: 1 1 220px; }
.kicker { font-family: var(--heading-font); font-stretch: var(--heading-stretch); font-weight: 700; text-transform: uppercase; letter-spacing: .12em; font-size: 16px; color: var(--orange-deep); margin: 0 0 var(--space-2); }
/* Brand orange only reaches 2.6:1 on light surfaces, so light backgrounds use
   the deeper shade and the dark panels keep the bright accent. */
.hero .kicker, .page-band .kicker, .cta-band .kicker, .site-footer .kicker, .guide-card--image .kicker { color: var(--orange); }
.kicker--line { display: inline-flex; align-items: center; gap: var(--space-3); }
.kicker--line::after { content: ""; width: 48px; height: 2px; background: var(--orange); }
/* Keyboard users must be able to scroll an overflowing table. */
.table-scroll:focus-visible { outline: 3px solid var(--ink); outline-offset: 2px; }

/* ---------- header ---------- */
.site-header { background: var(--graphite); color: #fff; position: relative; z-index: 50; }
.site-header__inner { display: flex; align-items: center; justify-content: space-between; min-height: 64px; gap: var(--space-4); }
.brand { display: inline-flex; align-items: center; gap: var(--space-3); text-decoration: none; color: #fff; min-height: 44px; }
.brand:hover { color: #fff; }
.brand-mark { width: 40px; height: 40px; flex: none; }
.brand__word { font-family: var(--heading-font); font-stretch: var(--heading-stretch); font-weight: 800; font-size: 28px; letter-spacing: -.01em; line-height: 1; }
.brand__tld { color: var(--orange); }
.nav-toggle { display: inline-flex; align-items: center; justify-content: center; width: 48px; height: 48px; background: none; border: 0; color: #fff; border-radius: var(--radius); }
.nav-toggle .icon { width: 28px; height: 28px; }
.nav-toggle__close { display: none; }
.nav-toggle[aria-expanded="true"] .nav-toggle__open { display: none; }
.nav-toggle[aria-expanded="true"] .nav-toggle__close { display: block; }
.site-nav { display: none; position: absolute; top: 100%; left: 0; right: 0; background: var(--graphite); border-top: 1px solid rgba(255, 255, 255, .12); box-shadow: 0 12px 24px rgba(0, 0, 0, .25); }
.site-nav.is-open { display: block; }
.site-nav__list { list-style: none; margin: 0; padding: var(--space-2) var(--gutter) var(--space-4); }
.site-nav__list a { display: block; padding: 14px 8px; font-weight: 600; text-decoration: none; border-bottom: 1px solid rgba(255, 255, 255, .08); }
.site-nav__list a[aria-current="page"] { color: var(--orange); }
.site-nav__list a:hover { color: var(--orange); }

/* ---------- hero ---------- */
.hero { position: relative; background: var(--graphite); color: #fff; overflow: hidden; }
.hero__grid { display: grid; grid-template-columns: 1fr; gap: var(--space-5); align-items: center; padding-top: var(--space-6); }
.hero__copy { position: relative; z-index: 2; }
.hero__title { color: #fff; font-size: clamp(52px, 13vw, 94px); margin-bottom: var(--space-4); }
.hero__title--medium { font-size: clamp(38px, 8vw, 72px); }
.hero__lede { font-size: 18px; max-width: 32ch; margin-bottom: var(--space-4); }
.hero .actions { margin-top: var(--space-4); }
.hero .actions .btn { flex: 1 1 100%; min-height: 52px; }
.hero__art { position: relative; margin-inline: calc(-1 * var(--gutter)); }
.hero__img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; object-position: 68% center; }
.hero--page .hero__grid { padding-top: var(--space-5); }
.hero--page .breadcrumbs { margin-bottom: var(--space-3); }
.hero--compact .hero__img { aspect-ratio: 16 / 9; }

/* ---------- page band (inner titles) ---------- */
.page-band { position: relative; background: var(--graphite); color: #fff; padding: var(--space-6) 0 var(--space-6); overflow: hidden; }
.page-band .container { position: relative; z-index: 2; }
.page-band__title { color: #fff; font-size: clamp(40px, 9vw, 72px); margin-bottom: var(--space-2); }
.page-band__lede { font-size: 18px; max-width: 48ch; margin: 0; }
.page-band .speed-stripes { opacity: .9; }

/* ---------- breadcrumbs ---------- */
.breadcrumbs ol { list-style: none; margin: 0 0 var(--space-3); padding: 0; display: flex; flex-wrap: wrap; gap: var(--space-2); font-size: 14px; }
.breadcrumbs li + li::before { content: "›"; margin-right: var(--space-2); opacity: .6; }
.breadcrumbs a { text-decoration: none; opacity: .85; }
.breadcrumbs a:hover { text-decoration: underline; opacity: 1; color: inherit; }
.breadcrumbs [aria-current] { font-weight: 600; }
.page-band .breadcrumbs, .hero .breadcrumbs { color: #fff; }

/* ---------- sections ---------- */
.section { padding: var(--space-7) 0; }
.section--tight { padding-top: var(--space-4); }
.section--tint { background: var(--tint); }
.section__head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: var(--space-3); margin-bottom: var(--space-4); }
.section__title { margin-bottom: var(--space-2); }
.section__title--sentence { text-transform: none; letter-spacing: 0; }
.section__lede { color: var(--muted); margin-bottom: var(--space-5); }
.round-meta { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-3); color: var(--muted); font-size: 18px; margin: 0; }
.round-meta--dark { color: #fff; margin-top: var(--space-2); }
.badge { display: inline-block; padding: 4px 10px; border-radius: var(--radius); background: var(--orange-tint); color: var(--orange-deep); font-size: 14px; font-weight: 600; }
.badge--outline { background: transparent; color: #fff; border: 1px solid rgba(255, 255, 255, .6); }
.count-line { color: var(--muted); font-weight: 600; margin: var(--space-4) 0 var(--space-3); }

/* ---------- cards ---------- */
.card { background: var(--paper); padding: var(--space-4); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-1); }
.card + .card, .card + .result-layout, .result-layout + .actions { margin-top: var(--space-5); }
.card__title { margin-bottom: var(--space-4); }
.result-layout { display: grid; grid-template-columns: 1fr; gap: var(--space-5); align-items: start; margin-top: var(--space-5); }

/* ---------- winning strip ---------- */
.winning-strip { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--space-2); }
.winning-chip { padding: var(--space-2); text-align: center; background: var(--tint); border: 1px solid var(--line); border-radius: var(--radius); }
.winning-chip small { display: block; font-size: 14px; font-weight: 600; color: var(--ink); }
.winning-chip strong { display: block; font-size: 32px; font-family: var(--heading-font); font-stretch: var(--heading-stretch); font-weight: 800; line-height: 1.1; }
.winning-strip--small .winning-chip strong { font-size: 26px; }

/* ---------- winners table ---------- */
.result-table { display: none; }
.result-table th, .result-table td { text-align: left; padding: 14px 12px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.result-table thead th { background: var(--tint); font-size: 14px; font-weight: 600; }
.result-table__leg { font-weight: 700; white-space: nowrap; }
.horse-number { display: inline-grid; place-items: center; min-width: 40px; height: 40px; padding: 0 6px; background: var(--graphite); color: #fff; border-radius: var(--radius); font-weight: 700; }
.horse-number--orange { background: var(--orange); color: var(--ink); }
.horse-number--wrong { background: var(--incorrect-tint); color: var(--incorrect); border: 1px solid var(--incorrect); }
.horse-name { font-weight: 700; }
.driver { color: var(--muted); }
.result-cards-mobile { list-style: none; margin: 0; padding: 0; }
.result-mobile-row { display: grid; grid-template-columns: auto 44px minmax(0, 1fr); align-items: center; gap: var(--space-3); padding: 12px 0; border-bottom: 1px solid var(--line); }
.result-mobile-row__leg { display: inline-grid; place-items: center; min-width: 64px; height: 40px; background: var(--graphite); color: #fff; border-radius: var(--radius); font-family: var(--heading-font); font-stretch: var(--heading-stretch); font-weight: 700; font-size: 18px; }
.result-mobile-row .horse-number { width: 44px; height: 44px; font-size: 18px; }
.result-mobile-row__text { display: grid; line-height: 1.3; min-width: 0; }
.result-mobile-row__text .horse-name, .result-mobile-row__text .driver { overflow-wrap: anywhere; }

/* ---------- payouts ---------- */
.payout-table th, .payout-table td { padding: 14px 12px; border-bottom: 1px solid var(--line); text-align: left; }
.payout-table thead th { background: var(--tint); font-size: 14px; font-weight: 600; }
.payout-table__value { text-align: right !important; }
.payout-table tbody .payout { font-family: var(--heading-font); font-stretch: var(--heading-stretch); font-weight: 800; font-size: 28px; }
.source-note { color: var(--muted); font-size: 14px; margin: var(--space-3) 0 0; }
.note { display: flex; gap: var(--space-3); align-items: flex-start; background: var(--info-tint); border-radius: var(--radius); padding: var(--space-3) var(--space-4); color: var(--ink); margin-top: var(--space-4); }
.note .icon { flex: none; width: 20px; height: 20px; margin-top: 2px; }
.note--plain { background: none; padding: 0; color: var(--muted); font-size: 15px; }

/* ---------- round cards (archive / results index) ---------- */
.round-list { display: grid; gap: var(--space-4); }
.round-card { display: grid; grid-template-columns: 1fr; gap: var(--space-4); padding: var(--space-4); border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper); box-shadow: var(--shadow-1); }
.round-card__date { font-family: var(--heading-font); font-stretch: var(--heading-stretch); font-weight: 700; text-transform: uppercase; color: var(--muted); letter-spacing: .04em; margin: 0 0 4px; }
.round-card__track { font-size: clamp(34px, 8vw, 44px); margin-bottom: 4px; }
.round-card__payout { font-family: var(--heading-font); font-stretch: var(--heading-stretch); font-weight: 800; font-size: clamp(26px, 6vw, 34px); color: var(--orange-deep); margin: 0; }
.round-card__body { display: grid; gap: var(--space-3); }
.round-card__body .btn { width: 100%; }

/* ---------- guides ---------- */
.editorial-grid { display: grid; grid-template-columns: 1fr; gap: var(--space-5); }
.guide-card--image { display: grid; grid-template-columns: 1fr; background: var(--graphite); color: #fff; border-radius: var(--radius); overflow: hidden; }
.guide-card__media { position: relative; }
.guide-card__media img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.guide-card--image .guide-card__body { padding: var(--space-5); }
.guide-card--image .guide-card__title { color: #fff; }
.guide-card--number { border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: var(--paper); display: grid; grid-template-rows: auto 1fr; }
.guide-card__number { position: relative; background: var(--graphite); color: var(--orange); font-family: var(--heading-font); font-stretch: var(--heading-stretch); font-weight: 800; font-style: italic; font-size: 64px; line-height: 1; padding: var(--space-4) var(--space-4) var(--space-3); overflow: hidden; }
.guide-card__number::after { content: ""; position: absolute; right: 24px; top: -20%; width: 22px; height: 140%; background: var(--orange); transform: skewX(-24deg); opacity: .8; }
.guide-card--number .guide-card__body { padding: var(--space-4); }
.guide-card--number .guide-card__title { font-family: var(--body-font); font-stretch: 100%; text-transform: none; font-weight: 700; font-size: 20px; letter-spacing: 0; }
.guide-card--number p { color: var(--muted); }
.guide-grid { display: grid; grid-template-columns: 1fr; gap: var(--space-4); }
.featured-guide { display: grid; grid-template-columns: 1fr; background: var(--tint); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; }
.featured-guide__body { padding: var(--space-5); order: 1; }
.featured-guide__title { font-size: clamp(36px, 8vw, 64px); }
.featured-guide__media { position: relative; order: 2; }
.featured-guide__media img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.featured-guide__num { position: absolute; right: 24px; bottom: 16px; font-family: var(--heading-font); font-stretch: var(--heading-stretch); font-weight: 800; font-style: italic; font-size: 72px; color: var(--ink); background: var(--orange); padding: 0 12px; line-height: 1.1; transform: skewX(-8deg); }
.quick-links { background: var(--tint); border-bottom: 1px solid var(--line); padding: var(--space-5) 0; }
.quick-links__grid { display: grid; gap: var(--space-4); }
.quick-links__title { font-size: 26px; margin-bottom: 4px; }
.quick-links__intro p { color: var(--muted); margin: 0; }
.quick-links__list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: var(--space-3); }
.quick-link { display: flex; align-items: center; gap: var(--space-3); background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: var(--space-3); text-decoration: none; min-height: 64px; transition: border-color var(--dur) var(--ease); }
.quick-link:hover { border-color: var(--orange); color: inherit; }
.quick-link .icon { color: var(--orange); flex: none; }
.quick-link span { display: grid; line-height: 1.25; }
.quick-link strong { font-family: var(--heading-font); font-stretch: var(--heading-stretch); text-transform: uppercase; font-size: 18px; }
.quick-link small { color: var(--muted); font-size: 13px; }
.cta-band { position: relative; background: var(--graphite); color: #fff; padding: var(--space-7) 0; overflow: hidden; }
.cta-band__grid { position: relative; z-index: 2; display: grid; gap: var(--space-4); align-items: center; }
.cta-band__title { color: #fff; font-size: clamp(36px, 8vw, 56px); }
.cta-band .btn { width: 100%; }

/* ---------- article ---------- */
.article__body { max-width: 720px; }
.article__body p, .article__body li { max-width: 68ch; }
.article__body h2 { margin-top: var(--space-6); font-size: clamp(26px, 3vw, 34px); }
.article__body h2:first-child { margin-top: 0; }
.article-nav { margin-top: var(--space-7); padding-top: var(--space-5); border-top: 1px solid var(--line); }
.article-nav__title { font-size: 26px; }
.article-nav ul { list-style: none; padding: 0; margin: 0; display: grid; gap: var(--space-2); }
.article-nav a { display: inline-flex; align-items: center; gap: var(--space-2); min-height: 44px; font-weight: 600; text-decoration: none; }
.article-nav a:hover { color: var(--orange-deep); text-decoration: underline; }
.article-nav .icon { width: 18px; height: 18px; }

/* ---------- steps ---------- */
.steps { list-style: none; margin: var(--space-5) 0 0; padding: 0; display: grid; gap: var(--space-4); }
.step { display: grid; grid-template-columns: 48px 1fr; column-gap: var(--space-3); align-items: start; background: var(--paper); border-radius: var(--radius); padding: var(--space-4); }
.section--tint .step { border: 1px solid var(--line); }
.step__num { grid-row: 1 / span 3; display: grid; place-items: center; width: 48px; height: 48px; border-radius: 50%; background: var(--orange); color: var(--ink); font-family: var(--heading-font); font-stretch: var(--heading-stretch); font-weight: 800; font-size: 24px; }
.step__title { font-size: 22px; margin-bottom: 4px; }
.step p { margin: 0; color: var(--muted); }
.step p + p { margin-top: var(--space-2); }
.steps--guide .step { padding: var(--space-4) 0; border-bottom: 1px solid var(--line); border-radius: 0; }
.steps--guide .step__title { font-size: 26px; }
.steps--guide .step__lead { color: var(--ink); font-weight: 500; }
.steps--guide .step__icon { display: none; }

/* ---------- example table (guide) ---------- */
.example { margin-top: var(--space-6); background: var(--tint); }
.example__meta { color: var(--muted); margin-top: calc(-1 * var(--space-3)); }
.table-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.example-table th, .example-table td { padding: 12px 10px; border: 1px solid var(--line); background: var(--paper); text-align: center; white-space: nowrap; }
.example-table thead th, .example-table tbody th { background: var(--tint); font-weight: 700; }
.example-table tbody th { text-align: left; }
.example-table--left td { text-align: left; }
.example-table td.numeric { font-family: var(--heading-font); font-stretch: var(--heading-stretch); font-weight: 800; font-size: 24px; }
.summary-band { display: grid; gap: var(--space-4); align-items: center; background: var(--tint); border: 1px solid var(--line); border-radius: var(--radius); padding: var(--space-5); margin-top: var(--space-5); }
.summary-band__score { font-family: var(--heading-font); font-stretch: var(--heading-stretch); font-weight: 800; font-size: clamp(40px, 9vw, 56px); text-transform: uppercase; margin: 0; line-height: 1; }
.summary-band__note { color: var(--muted); font-style: italic; margin: 0; }
.summary-band .btn { justify-self: start; }

/* ---------- status pills ---------- */
.status { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; border-radius: var(--radius); font-weight: 700; }
.status .icon { width: 18px; height: 18px; }
.status--correct { background: var(--correct-tint); color: var(--correct); }
.status--incorrect { background: var(--incorrect-tint); color: var(--incorrect); }
.correct { color: var(--correct); } .incorrect { color: var(--incorrect); }

/* ---------- FAQ ---------- */
.faq { margin-top: var(--space-7); }
.faq__item { border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper); margin-bottom: var(--space-3); }
.faq__q { display: flex; align-items: center; justify-content: space-between; gap: var(--space-3); padding: 14px var(--space-4); font-weight: 700; cursor: pointer; list-style: none; min-height: 52px; }
.faq__q::-webkit-details-marker { display: none; }
.faq__q .icon { flex: none; transition: transform var(--dur) var(--ease); }
.faq__item[open] .faq__q .icon { transform: rotate(180deg); }
.faq__a { padding: 0 var(--space-4) var(--space-4); color: var(--muted); }
.faq__a p { margin: 0; }

/* ---------- checker ---------- */
.checker { max-width: 900px; }
.round-panel { display: grid; grid-template-columns: auto 1fr; align-items: center; gap: var(--space-3); background: var(--tint); border: 1px solid var(--line); border-radius: var(--radius); padding: var(--space-3) var(--space-4); margin-bottom: var(--space-5); }
.round-panel .icon { color: var(--ink); }
.round-panel__label { font-weight: 700; }
.round-panel__select { grid-column: 1 / -1; width: 100%; min-height: 48px; padding: 8px 12px; border: 1px solid var(--muted); border-radius: var(--radius); background: var(--paper); }
.round-panel .badge { grid-column: 1 / -1; justify-self: start; }
.checker-fields { border: 0; padding: 0; margin: 0 0 var(--space-4); display: grid; grid-template-columns: 1fr; gap: var(--space-3); }
.checker-field { border: 1px solid var(--line); border-radius: var(--radius); padding: var(--space-3) var(--space-4); background: var(--paper); }
.checker-field label { display: block; margin-bottom: 6px; font-weight: 700; }
.checker-field input { width: 100%; min-height: 48px; padding: 10px 12px; border: 1px solid var(--muted); border-radius: var(--radius); color: var(--ink); background: var(--paper); }
.checker-field input::placeholder { color: #6b7684; }
.checker-field--error { border-color: var(--incorrect); }
.checker-field--error input, .checker-field input[aria-invalid="true"] { border-color: var(--incorrect); border-width: 2px; }
.field-error { color: var(--incorrect); font-size: 14px; font-weight: 600; margin: 6px 0 0; }
.checker-bar { display: grid; gap: var(--space-3); align-items: center; margin-top: var(--space-4); }
.checker-bar__count { font-weight: 600; margin: 0; }
.checker-bar__actions { display: grid; grid-template-columns: 1fr; gap: var(--space-2); }
.error-summary { border: 2px solid var(--incorrect); border-radius: var(--radius); padding: var(--space-4); margin-bottom: var(--space-4); background: var(--incorrect-tint); }
.error-summary__title { display: flex; align-items: center; gap: var(--space-2); font-size: 22px; color: var(--incorrect); margin-bottom: var(--space-2); }
.error-summary ul { margin: 0; padding-left: 1.2em; }
.error-summary .link-btn { background: none; border: 0; padding: 4px 0; min-height: 32px; text-decoration: underline; color: var(--incorrect); font-weight: 600; text-align: left; }
.checker-result { margin-top: var(--space-5); }
.checker-result__summary { display: grid; gap: var(--space-3); padding-bottom: var(--space-4); margin-bottom: var(--space-4); border-bottom: 1px solid var(--line); }
.checker-result__score { font-size: clamp(40px, 9vw, 56px); margin-bottom: 4px; }
.checker-result__round { color: var(--muted); margin: 0; }
.checker-result__note { font-style: italic; color: var(--muted); margin: 0; }
.checker-result__footnote { color: var(--muted); font-size: 14px; margin: var(--space-3) 0 0; }
.compare-table th, .compare-table td { padding: 12px 8px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: middle; }
.compare-table thead th { background: var(--tint); font-size: 14px; font-weight: 600; }
.compare-table tbody th { font-weight: 700; white-space: nowrap; }
.compare-table__horse { display: none; }
.compare-table td.numeric { font-weight: 700; }
.checker__aside { display: flex; flex-wrap: wrap; gap: var(--space-4); margin-top: var(--space-5); }

/* ---------- archive filters ---------- */
.filter-form { margin-bottom: var(--space-4); }
.filter-fields { display: grid; grid-template-columns: 1fr; gap: var(--space-3); }
.filter-field label { display: block; font-weight: 700; margin-bottom: 6px; }
.filter-field select { width: 100%; min-height: 48px; padding: 8px 12px; border: 1px solid var(--muted); border-radius: var(--radius); background: var(--paper); }
.filter-field--submit { align-self: end; }
.filter-field--submit .btn { width: 100%; }
.teaser { display: grid; gap: var(--space-3); margin-top: var(--space-6); background: var(--tint); }
.teaser__icon { width: 48px; height: 48px; color: var(--orange); }
.teaser__title { font-size: 26px; margin-bottom: 4px; }
.teaser p { margin: 0; color: var(--muted); }
.teaser .btn { justify-self: start; }

/* ---------- misc blocks ---------- */
.empty-state { text-align: center; padding: var(--space-6) var(--space-4); }
.empty-state__icon { width: 48px; height: 48px; margin: 0 auto var(--space-3); color: var(--muted); }
.empty-state__title { font-weight: 700; margin-bottom: 4px; }
.empty-state__text { color: var(--muted); margin: 0 auto var(--space-4); max-width: 44ch; }
.feature-band { background: var(--tint); border-top: 1px solid var(--line); padding: var(--space-6) 0; }
.feature-band__grid { display: grid; gap: var(--space-4); }
.feature { display: grid; grid-template-columns: 48px 1fr; column-gap: var(--space-3); text-decoration: none; padding: var(--space-3); border-radius: var(--radius); transition: background-color var(--dur) var(--ease); }
.feature:hover { background: var(--paper); color: inherit; }
.feature__icon { grid-row: 1 / span 2; width: 40px; height: 40px; }
.feature__title { font-family: var(--heading-font); font-stretch: var(--heading-stretch); font-weight: 800; font-size: 24px; text-transform: uppercase; }
.feature__text { color: var(--muted); }

/* ---------- footer ---------- */
.site-footer { position: relative; background: var(--graphite); color: #fff; padding: var(--space-7) 0 var(--space-6); overflow: hidden; margin-top: var(--space-4); }
.site-footer__grid { display: grid; gap: var(--space-5); position: relative; }
.site-footer__tagline { margin: var(--space-3) 0 var(--space-2); }
.site-footer__legal { display: flex; flex-wrap: wrap; gap: var(--space-2); align-items: center; margin: 0; }
.site-footer__legal a { min-height: 44px; display: inline-flex; align-items: center; }
.site-footer__heading { font-family: var(--body-font); font-stretch: 100%; text-transform: none; font-size: 16px; font-weight: 700; letter-spacing: 0; margin-bottom: var(--space-2); }
.site-footer__col ul { list-style: none; margin: 0; padding: 0; }
.site-footer__col a { display: inline-flex; align-items: center; min-height: 40px; text-decoration: none; opacity: .9; }
.site-footer__col a:hover { color: var(--orange); opacity: 1; text-decoration: underline; }
.site-footer__stripe { display: none; }

/* ============ tablet ≥ 761px ============ */
@media (min-width: 761px) {
  .hero__grid { grid-template-columns: 1fr 1.1fr; gap: var(--space-6); padding-top: 0; min-height: 460px; }
  .hero__art { margin-inline: 0; height: 100%; }
  .hero__img { height: 100%; min-height: 460px; aspect-ratio: auto; clip-path: polygon(14% 0, 100% 0, 100% 100%, 0 100%); }
  .hero--compact .hero__img { min-height: 380px; }
  .hero .actions .btn { flex: 0 1 auto; }
  .hero--page .hero__grid { min-height: 380px; }
  .card { padding: var(--space-5); }
  .result-layout { grid-template-columns: minmax(0, 2fr) minmax(280px, 1fr); }
  .winning-strip { grid-template-columns: repeat(6, minmax(0, 1fr)); }
  .result-table { display: table; }
  .result-cards-mobile { display: none; }
  .round-card { grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); }
  .round-card__head { border-right: 1px solid var(--line); padding-right: var(--space-4); }
  .round-card__body .btn { width: auto; justify-self: start; }
  .editorial-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .guide-card--image { grid-template-columns: 42% 1fr; }
  .guide-card__media img { aspect-ratio: auto; height: 100%; clip-path: polygon(0 0, 100% 0, 84% 100%, 0 100%); }
  .guide-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .featured-guide { grid-template-columns: 1fr 1.4fr; }
  .featured-guide__media { order: 2; }
  .featured-guide__media img { height: 100%; aspect-ratio: auto; min-height: 340px; clip-path: polygon(6% 0, 100% 0, 100% 100%, 0 100%); }
  .quick-links__grid { grid-template-columns: 1fr 2fr; align-items: center; }
  .quick-links__list { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .cta-band__grid { grid-template-columns: 1fr auto; }
  .cta-band .btn { width: auto; }
  .steps { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--space-5); }
  .step { grid-template-columns: 1fr; row-gap: var(--space-2); padding: 0; background: transparent; border: 0 !important; }
  .step__num { grid-row: auto; }
  .steps--guide .step { border-bottom: 0; padding: 0 var(--space-4) 0 0; border-right: 1px solid var(--line); }
  .steps--guide .step:last-child { border-right: 0; }
  .steps--guide .step__icon { display: block; width: 40px; height: 40px; color: var(--ink); padding: 0; margin: var(--space-2) 0; }
  .summary-band { grid-template-columns: auto 1fr auto; }
  .checker-fields { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--space-4); }
  .checker-field { display: grid; grid-template-columns: 72px 1fr; align-items: center; column-gap: var(--space-3); }
  .checker-field label { margin: 0; font-size: 18px; }
  .checker-field .field-error { grid-column: 1 / -1; }
  .checker-bar { grid-template-columns: 1fr auto; }
  .checker-bar__actions { grid-template-columns: auto auto auto; align-items: center; }
  .checker-result__summary { grid-template-columns: 1fr auto; align-items: end; }
  .compare-table__horse { display: table-cell; }
  .round-panel { grid-template-columns: auto auto 1fr auto; }
  .round-panel__select { grid-column: auto; width: auto; min-width: 280px; }
  .round-panel .badge { grid-column: auto; }
  .filter-fields { grid-template-columns: 1fr 1fr auto; align-items: end; }
  .filter-field--submit .btn { width: auto; min-width: 200px; }
  .teaser { grid-template-columns: auto 1fr auto; align-items: center; }
  .feature-band__grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .feature + .feature { border-left: 1px solid var(--line); padding-left: var(--space-5); }
  .site-footer__grid { grid-template-columns: 1.2fr 1fr 1fr; }
  .site-footer__stripe { display: block; position: absolute; right: 0; top: -20%; width: 140px; height: 140%; pointer-events: none; }
  .site-footer__stripe::before { content: ""; position: absolute; right: 30px; top: 0; width: 24px; height: 100%; background: var(--orange); transform: skewX(-24deg); }
  .site-footer__stripe::after { content: ""; position: absolute; right: 70px; top: 0; width: 12px; height: 100%; background: var(--orange); opacity: .5; transform: skewX(-24deg); }
}

/* ============ desktop ≥ 1024px ============ */
@media (min-width: 1024px) {
  .nav-toggle { display: none; }
  .site-nav { display: block; position: static; background: none; border: 0; box-shadow: none; flex: 1; }
  .site-nav__list { display: flex; gap: var(--space-2); padding: 0; margin-left: var(--space-5); }
  .site-nav__list a { padding: 20px 14px; border-bottom: 4px solid transparent; }
  .site-nav__list a[aria-current="page"] { color: #fff; border-bottom-color: var(--orange); }
  .hero__title { font-size: clamp(64px, 6.6vw, 94px); }
  .hero__lede { font-size: 20px; }
  .section { padding: var(--space-8) 0; }
  .section--tight { padding-top: var(--space-4); }
  .round-card { grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr); padding: var(--space-5); }
  .guide-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .site-footer__grid { grid-template-columns: 1.4fr 1fr 1fr 140px; }
  .site-footer__stripe { position: static; }
}

/* ---------- reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

/* ---------- narrow screens: keep title bands clean (mobile mock-ups 02/03) ---------- */
@media (max-width: 760px) {
  .page-band .speed-stripes { display: none; }
  .round-card__track { font-size: clamp(30px, 8vw, 40px); }
}

/* ---------- legal + editorial pages ---------- */
.legal-updated { color: var(--muted); font-size: 14px; margin-bottom: var(--space-5); }
.placeholder { background: #fff3c4; color: #5c4400; border: 1px dashed #b8860b; border-radius: var(--radius); padding: 0 6px; font-weight: 700; }
.cookie-table th, .cookie-table td { white-space: normal; }
code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: .95em; background: var(--tint); padding: 1px 5px; border-radius: 3px; }

/* ---------- generic forms (contact) ---------- */
.contact-layout { display: grid; grid-template-columns: 1fr; gap: var(--space-5); align-items: start; }
.contact-form { display: grid; gap: var(--space-4); }
.form-field label { display: block; font-weight: 700; margin-bottom: 6px; }
.form-field input:not([type="checkbox"]), .form-field select, .form-field textarea { width: 100%; min-height: 48px; padding: 10px 12px; border: 1px solid var(--muted); border-radius: var(--radius); background: var(--paper); color: var(--ink); }
.form-field textarea { min-height: 160px; resize: vertical; line-height: 1.5; }
.form-field input[aria-invalid="true"], .form-field select[aria-invalid="true"], .form-field textarea[aria-invalid="true"] { border-color: var(--incorrect); border-width: 2px; }
.form-field--check { display: grid; grid-template-columns: 24px 1fr; column-gap: var(--space-3); align-items: start; }
.form-field--check input { width: 24px; height: 24px; margin: 2px 0 0; min-height: 0; accent-color: var(--orange); }
.form-field--check label { font-weight: 500; margin: 0; }
.form-field--check .field-error { grid-column: 1 / -1; }
.field-help { color: var(--muted); font-size: 14px; margin: 6px 0 0; }
.req { color: var(--incorrect); font-weight: 700; }
.hp { position: absolute; left: -9999px; top: auto; width: 1px; height: 1px; overflow: hidden; }
.success { padding: var(--space-6) var(--space-5); }
.success__icon { width: 48px; height: 48px; color: var(--correct); margin-bottom: var(--space-3); }
.success__title { margin-bottom: var(--space-3); }
.success:focus { outline: none; }

/* ---------- 404 link tiles ---------- */
.link-grid { list-style: none; margin: 0 0 var(--space-5); padding: 0; display: grid; grid-template-columns: 1fr; gap: var(--space-3); }
.link-tile { display: flex; align-items: center; gap: var(--space-3); background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: var(--space-3) var(--space-4); text-decoration: none; min-height: 64px; transition: border-color var(--dur) var(--ease); }
.link-tile:hover { border-color: var(--orange); color: inherit; }
.link-tile .icon { color: var(--orange); flex: none; }
.link-tile span { display: grid; line-height: 1.3; }
.link-tile strong { font-family: var(--heading-font); font-stretch: var(--heading-stretch); text-transform: uppercase; font-size: 20px; }
.link-tile small { color: var(--muted); font-size: 14px; }

/* ---------- cookie consent ---------- */
.consent-banner { position: fixed; left: 0; right: 0; bottom: 0; z-index: 900; background: var(--graphite); color: #fff; border-top: 4px solid var(--orange); box-shadow: 0 -8px 24px rgba(0, 0, 0, .25); padding: var(--space-4) 0; }
.consent-banner__inner { display: grid; gap: var(--space-3); }
.consent-banner__title { font-family: var(--heading-font); font-stretch: var(--heading-stretch); text-transform: uppercase; font-weight: 800; font-size: 22px; margin: 0 0 4px; }
.consent-banner__text p { margin: 0; font-size: 15px; }
.consent-banner__text a { color: #fff; }
.consent-banner__actions { display: grid; grid-template-columns: 1fr; gap: var(--space-2); }
.consent-banner .btn--secondary { border-color: #fff; }
.consent-banner .btn--link { color: #fff; }
.consent-banner :focus-visible { outline-color: #fff; }
.consent-dialog { border: 0; border-radius: var(--radius); padding: 0; width: min(calc(100% - 32px), 560px); max-height: calc(100dvh - 32px); box-shadow: 0 24px 64px rgba(0, 0, 0, .35); color: var(--ink); }
.consent-dialog::backdrop { background: rgba(24, 28, 34, .6); }
.consent-dialog__form { padding: var(--space-5); display: grid; gap: var(--space-4); }
.consent-dialog__head { display: flex; align-items: flex-start; justify-content: space-between; gap: var(--space-3); }
.consent-dialog__head h2 { font-size: 30px; margin: 0; }
.consent-dialog__close { background: none; border: 1px solid var(--line); border-radius: var(--radius); width: 44px; height: 44px; display: grid; place-items: center; }
.consent-dialog__form > p { margin: 0; }
.consent-cats { border: 0; padding: 0; margin: 0; display: grid; gap: var(--space-2); }
.consent-cat { display: grid; grid-template-columns: 24px 1fr; column-gap: var(--space-3); align-items: start; padding: var(--space-3); border: 1px solid var(--line); border-radius: var(--radius); }
.consent-cat input { width: 24px; height: 24px; min-height: 0; margin: 2px 0 0; accent-color: var(--orange); }
.consent-cat label { display: grid; gap: 2px; }
.consent-cat label span { color: var(--muted); font-size: 14px; }
.consent-dialog__actions { display: grid; grid-template-columns: 1fr; gap: var(--space-2); }
body.has-consent-banner { padding-bottom: 0; }

@media (min-width: 761px) {
  .contact-layout { grid-template-columns: minmax(0, 3fr) minmax(280px, 2fr); }
  .link-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .consent-banner__inner { grid-template-columns: 1fr auto; align-items: center; }
  .consent-banner__actions { grid-template-columns: auto auto auto; align-items: center; }
  .consent-dialog__actions { grid-template-columns: auto auto auto; justify-content: start; }
  .site-footer__grid { grid-template-columns: 1.2fr 1fr 1fr 1fr; }
}
@media (min-width: 1024px) {
  .link-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .site-footer__grid { grid-template-columns: 1.4fr 1fr 1fr 1fr 120px; }
}

/* ---------- scroll-to-top ---------- */
:root { --banner-h: 0px; }
.to-top { position: fixed; right: var(--space-4); bottom: calc(var(--space-4) + var(--banner-h)); z-index: 800; display: inline-flex; align-items: center; gap: 6px; min-height: 48px; padding: 0 14px 0 10px; background: var(--graphite); color: #fff; border: 2px solid var(--orange); border-radius: var(--radius); font-weight: 700; box-shadow: 0 8px 20px rgba(0, 0, 0, .25); transition: opacity var(--dur) var(--ease), transform var(--dur) var(--ease), bottom var(--dur) var(--ease); }
.to-top .icon { width: 22px; height: 22px; }
.to-top:hover { background: var(--orange); color: var(--ink); }
.to-top:focus-visible { outline-color: var(--orange); }
.to-top[hidden] { display: none; }

/* ---------- synchronised status ---------- */
.badge--live { background: var(--incorrect-tint); color: var(--incorrect); }
.badge--soon { background: var(--info-tint); color: #17456f; }
.badge--warn { background: #fff3c4; color: #5c4400; }
.badge--outline.badge--live, .badge--outline.badge--soon, .badge--outline.badge--warn { background: transparent; color: #fff; border: 1px solid rgba(255, 255, 255, .6); }
.winning-chip--pending strong { color: var(--muted); }
.note--pending { background: var(--info-tint); }
.note--warn { background: #fff3c4; }
.empty-inline { display: flex; gap: var(--space-2); align-items: center; color: var(--muted); margin: 0 0 var(--space-3); }
.empty-inline .icon { width: 20px; height: 20px; flex: none; }
.site-footer__updated { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-size: 14px; color: rgba(255, 255, 255, .85); margin: var(--space-2) 0; }
.site-footer__stale { color: #ffd27a; }
.dot { width: 9px; height: 9px; border-radius: 50%; display: inline-block; flex: none; }
.dot--ok { background: #3fb27f; }
.dot--warn { background: #ffb020; }

/* ---------- admin status page ---------- */
.status-grid { display: grid; grid-template-columns: 1fr; gap: var(--space-4); margin-bottom: var(--space-6); }
.status-card__value { font-family: var(--heading-font); font-stretch: var(--heading-stretch); font-weight: 800; font-size: 26px; margin: 0 0 4px; overflow-wrap: anywhere; }
.status-card__meta { color: var(--muted); font-size: 14px; margin: 0; }
.status-card--ok { border-left: 4px solid var(--correct); }
.status-card--warn { border-left: 4px solid #ffb020; }
.status-card--error { border-left: 4px solid var(--incorrect); }
.admin-table { font-size: 14px; }
.admin-table th, .admin-table td { padding: 8px 10px; border-bottom: 1px solid var(--line); text-align: left; white-space: nowrap; }
.admin-table thead th { background: var(--tint); }
.admin-table .is-removed, .admin-table tr.is-removed td { opacity: .55; }
.admin-table__error { white-space: normal; max-width: 320px; color: var(--incorrect); }
@media (min-width: 761px) { .status-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

/* ---------- answer box: the direct answer, above the fold ---------- */
.answer-box { background: var(--tint); border-left: 4px solid var(--orange); border-radius: var(--radius); padding: var(--space-4) var(--space-5); margin-bottom: var(--space-6); }
.answer-box__lead { font-size: 19px; line-height: 1.5; margin-bottom: var(--space-3); }
.answer-box p:last-child { margin-bottom: 0; }
.answer-box .round-meta { margin-top: var(--space-3); }

/* ---------- track / weekday tables and blocks ---------- */
.track-table { font-size: 15px; }
.track-table th, .track-table td { padding: 12px 14px; border-bottom: 1px solid var(--line); text-align: left; white-space: nowrap; }
.track-table thead th { background: var(--tint); font-size: 14px; font-weight: 700; }
.track-table tbody th { font-weight: 700; }
.track-block { margin-top: var(--space-7); }
.track-block .section__title { font-size: clamp(24px, 3vw, 32px); }

/* Inline links inside the consent copy sit in a sentence, so their tap area is
   set by the line box. A slightly looser line-height gives them a comfortable
   target without pulling the text apart. */
.consent-banner__text p { line-height: 1.7; }
.consent-banner__text a { padding-block: 2px; }
