/* Paddock: the clubhouse website of an Assetto Corsa league.
   The site is painted like a race car: the league's livery (three colours, see /theme.css) gives the header
   plate, the stripes and the accent. Data uses broadcast grammar: position plates, condensed tabular figures,
   purple for the fastest lap of a session, green for a personal best, red for "live". */

/* ------------------------------------------------------------------ type: Archivo, one family, three widths */
@font-face { font-family: "Archivo"; font-style: normal; font-display: swap; font-weight: 100 900; font-stretch: 62% 125%;
  src: url("../fonts/archivo-latin-standard-normal.woff2") format("woff2-variations");
  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; }
@font-face { font-family: "Archivo"; font-style: normal; font-display: swap; font-weight: 100 900; font-stretch: 62% 125%;
  src: url("../fonts/archivo-latin-ext-standard-normal.woff2") format("woff2-variations");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Archivo"; font-style: italic; font-display: swap; font-weight: 100 900; font-stretch: 62% 125%;
  src: url("../fonts/archivo-latin-standard-italic.woff2") format("woff2-variations");
  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; }
@font-face { font-family: "Archivo"; font-style: italic; font-display: swap; font-weight: 100 900; font-stretch: 62% 125%;
  src: url("../fonts/archivo-latin-ext-standard-italic.woff2") format("woff2-variations");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }

/* ------------------------------------------------------------------ tokens (theme.css overrides the livery ones) */
:root {
  --l1: #8EC8E6; --l2: #F27A1A; --l3: #10263A; --on-l1: #0B0D10; --on-l2: #0B0D10; --on-l3: #FFFFFF;
  --r1: 2px; --r2: 4px; --r3: 6px;
  --paper: #F1F5F9; --surface: #FCFEFF; --surface-2: #E9EEF3; --surface-3: #DCE3EA;
  --ink: #111B25; --ink-2: #44515E; --ink-3: #5E6B78; --rule: #D9E0E7; --rule-strong: #BCC6D0;
  --header: #131D27; --header-ink: #F4F6F8; --header-ink-2: #B9C3CC;
  --accent: #F27A1A; --on-accent: #0B0D10; --accent-text: #AE5300; --accent-mark: #D36A10;
  --accent-wash: #FCEDE2; --accent-wash-2: #F8DCC7; --focus: #D36A10;

  /* status: fixed, never themed. Live is the TV red; purple and green follow timing screens */
  --live: #E5242C; --soon: #E3A008; --off: #8A96A3; --done: #3E8E5E;
  --fastest: #8F44F5; --fastest-text: #7A2FE0; --pb: #13A456; --pb-text: #0E7F42; --danger: #D0312D;
  /* chart series (validated categorical order) */
  --s1: #2a78d6; --s2: #eb6834; --s3: #1baf7a; --s4: #eda100; --s5: #e87ba4; --s6: #008300; --s7: #6250d6; --s8: #e34948;
  --s-other: #A3ADB8;
  --scrim: rgba(6, 10, 16, .72);

  --font: "Archivo", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --wide: 125%; --normal: 100%; --narrow: 74%;
  --t-xs: .8125rem; --t-s: .875rem; --t-m: 1rem; --t-l: 1.25rem; --t-xl: 1.5625rem; --t-2xl: 1.9375rem;
  --t-3xl: 2.4375rem; --t-4xl: 3.0625rem; --t-5xl: 3.8125rem;
  --gap: 24px; --gap-s: 12px; --gap-l: 40px; --pad: 18px;
  --row-h: 44px;
  --max: 1240px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:where(:not([data-theme="light"])) {
    color-scheme: dark;
    --paper: #091017; --surface: #10181F; --surface-2: #19222B; --surface-3: #232C36;
    --ink: #EDF1F4; --ink-2: #BAC4CD; --ink-3: #96A2AE; --rule: #222C36; --rule-strong: #33404C;
    --header: #070C12; --accent-text: #F27A1A; --accent-mark: #F27A1A; --accent-wash: #2A1F18; --accent-wash-2: #3D2A1C;
    --fastest: #A66BFF; --fastest-text: #B98AFF; --pb: #22C26A; --pb-text: #3DD47F;
    --s1: #3987e5; --s2: #d95926; --s3: #199e70; --s4: #c98500; --s5: #d55181; --s6: #008300; --s7: #9085e9; --s8: #e66767;
    --s-other: #4C5966;
  }
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --paper: #091017; --surface: #10181F; --surface-2: #19222B; --surface-3: #232C36;
  --ink: #EDF1F4; --ink-2: #BAC4CD; --ink-3: #96A2AE; --rule: #222C36; --rule-strong: #33404C;
  --header: #070C12; --accent-text: #F27A1A; --accent-mark: #F27A1A; --accent-wash: #2A1F18; --accent-wash-2: #3D2A1C;
  --fastest: #A66BFF; --fastest-text: #B98AFF; --pb: #22C26A; --pb-text: #3DD47F;
  --s1: #3987e5; --s2: #d95926; --s3: #199e70; --s4: #c98500; --s5: #d55181; --s6: #008300; --s7: #9085e9; --s8: #e66767;
  --s-other: #4C5966;
}
:root[data-density="compact"] { --gap: 16px; --gap-s: 8px; --gap-l: 28px; --pad: 12px; --row-h: 36px; }

/* ------------------------------------------------------------------ base */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-padding-top: 80px; }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font: 400 var(--t-m)/1.55 var(--font); font-stretch: var(--normal);
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}
img, svg { display: block; max-width: 100%; }
img { height: auto; }
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 3px; text-decoration-color: color-mix(in oklab, currentColor 40%, transparent); }
a:hover { text-decoration-color: currentColor; }
::selection { background: var(--accent); color: var(--on-accent); }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: var(--r1); }
.sr-only { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
/* the skip link: hidden until someone tabs to it */
a.sr-only:focus, a.sr-only:focus-visible { position: fixed !important; top: 8px; left: 8px; z-index: 1000; width: auto; height: auto; overflow: visible; clip: auto; white-space: normal; padding: 10px 16px; background: var(--surface); color: var(--ink); border: 1px solid var(--rule-strong); border-radius: var(--r2); font-weight: 700; text-decoration: none; }
[hidden] { display: none !important; }
hr { border: 0; border-top: 1px solid var(--rule); margin: var(--gap) 0; }
code, kbd { font: 500 .92em/1 ui-monospace, "SF Mono", Menlo, Consolas, monospace; background: var(--surface-2); padding: 2px 5px; border-radius: var(--r1); }
pre.code { font: 400 .8125rem/1.5 ui-monospace, Menlo, Consolas, monospace; background: var(--surface-2); padding: 14px; border-radius: var(--r2); overflow: auto; max-height: 520px; border: 1px solid var(--rule); }

h1, h2, h3, h4 { margin: 0; line-height: 1.12; font-weight: 750; letter-spacing: -.005em; }
h1 { font-size: var(--t-3xl); font-stretch: 112%; font-weight: 800; letter-spacing: -.012em; }
h2 { font-size: var(--t-xl); font-stretch: 106%; }
h3 { font-size: var(--t-l); font-stretch: 100%; font-weight: 700; }
h4 { font-size: var(--t-m); font-weight: 700; }
p { margin: 0 0 .9em; max-width: 72ch; }
p:last-child { margin-bottom: 0; }
small, .small { font-size: var(--t-s); }
.muted { color: var(--ink-2); }
.faint { color: var(--ink-3); }
.lede { font-size: var(--t-l); color: var(--ink-2); max-width: 62ch; line-height: 1.45; }
.num, .data { font-stretch: var(--narrow); font-weight: 600; font-variant-numeric: tabular-nums; letter-spacing: .005em; }
.big-num { font-stretch: 88%; font-weight: 800; font-variant-numeric: proportional-nums; letter-spacing: -.01em; line-height: 1; }
.display { font-stretch: var(--wide); font-style: italic; font-weight: 850; letter-spacing: -.02em; line-height: .98; }
.nowrap { white-space: nowrap; }
.r { text-align: right; }
.center { text-align: center; }

/* ------------------------------------------------------------------ layout */
.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding-left: 20px; padding-right: 20px; }
main { display: block; padding-bottom: 72px; }
.page { padding-top: 32px; }
.stack > * + * { margin-top: var(--gap-s); }
.stack-l > * + * { margin-top: var(--gap); }
.cluster { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.spread { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.grid { display: grid; gap: var(--gap); }
.cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.cols-7-5 { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); }
.cols-5-7 { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); }
.cols-8-4 { grid-template-columns: minmax(0, 8fr) minmax(0, 4fr); }
.span-all { grid-column: 1 / -1; }
@media (max-width: 960px) {
  .cols-2, .cols-3, .cols-7-5, .cols-5-7, .cols-8-4 { grid-template-columns: minmax(0, 1fr); }
  .cols-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 560px) { .wrap { padding-left: 16px; padding-right: 16px; } h1 { font-size: var(--t-2xl); } }

.section { margin-top: var(--gap-l); }
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }
.section-head h2 { display: flex; align-items: center; gap: 10px; }
.section-head .more { font-weight: 600; font-size: var(--t-s); color: var(--accent-text); text-decoration: none; white-space: nowrap; }
.section-head .more:hover { text-decoration: underline; }

.page-head { display: grid; gap: 8px; margin-bottom: 26px; }
.page-head .crumbs { font-size: var(--t-s); color: var(--ink-2); display: flex; gap: 8px; flex-wrap: wrap; }
.page-head .crumbs a { text-decoration: none; font-weight: 600; }
.page-head .crumbs a:hover { color: var(--accent-text); }
.page-head .crumbs span + span::before { content: "/"; margin-right: 8px; color: var(--ink-3); }
.page-head.with-aside { grid-template-columns: minmax(0, 1fr) auto; align-items: end; column-gap: 24px; }
@media (max-width: 720px) { .page-head.with-aside { grid-template-columns: 1fr; } }

/* ------------------------------------------------------------------ masthead */
.masthead { background: var(--header); color: var(--header-ink); position: sticky; top: 0; z-index: 40; }
.masthead-row { display: flex; align-items: center; gap: 22px; min-height: 64px; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--header-ink); min-width: 0; }
.brand-name { font-weight: 800; font-stretch: 108%; font-size: 1.125rem; letter-spacing: -.01em; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.brand-logo { height: 36px; width: auto; max-width: 140px; object-fit: contain; }
.brand-mark { position: relative; display: inline-flex; align-items: center; height: 34px; padding: 0 12px 0 20px; transform: skewX(-14deg); background: var(--accent); color: var(--on-accent); border-radius: var(--r1); flex: none; }
.brand-mark::before, .brand-mark::after { content: ""; position: absolute; top: 0; bottom: 0; width: 5px; }
.brand-mark::before { left: 3px; background: var(--stripe-a, var(--l1)); }
.brand-mark::after { left: 10px; background: var(--stripe-b, var(--l3)); width: 3px; }
.brand-mark b { display: block; transform: skewX(14deg); font-style: italic; font-weight: 900; font-stretch: 112%; font-size: 1.0625rem; letter-spacing: .02em; }

.nav { display: flex; gap: 2px; margin-left: auto; align-items: stretch; align-self: stretch; }
.nav a { display: flex; align-items: center; padding: 0 12px; text-decoration: none; color: var(--header-ink-2); font-weight: 600; font-size: .9375rem; position: relative; white-space: nowrap; }
.nav a:hover { color: var(--header-ink); }
.nav a[aria-current="page"] { color: var(--header-ink); }
.nav a[aria-current="page"]::after { content: ""; position: absolute; left: 12px; right: 12px; bottom: 0; height: 3px; background: var(--accent); border-radius: 2px 2px 0 0; }
.nav .nav-rc { color: var(--header-ink); }
.masthead-tools { display: flex; align-items: center; gap: 8px; }
.icon-btn { display: inline-grid; place-items: center; width: 38px; height: 38px; border-radius: var(--r2); border: 1px solid transparent; background: transparent; color: inherit; cursor: pointer; padding: 0; }
.icon-btn:hover { background: color-mix(in oklab, currentColor 12%, transparent); }
.icon-btn svg { width: 20px; height: 20px; }
.menu-btn { display: none; }
.live-pill { display: inline-flex; align-items: center; gap: 8px; height: 30px; padding: 0 12px; border-radius: 999px; background: color-mix(in oklab, var(--live) 22%, transparent); color: #fff; text-decoration: none; font-weight: 700; font-size: var(--t-s); white-space: nowrap; }
.live-pill:hover { background: color-mix(in oklab, var(--live) 34%, transparent); }
.live-pill .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--live); box-shadow: 0 0 0 0 var(--live); animation: pulse 1.8s ease-out infinite; }
.next-pill { display: inline-flex; align-items: center; gap: 8px; height: 30px; padding: 0 12px; border-radius: 999px; border: 1px solid color-mix(in oklab, var(--header-ink) 22%, transparent); color: var(--header-ink-2); text-decoration: none; font-size: var(--t-s); font-weight: 600; white-space: nowrap; }
.next-pill:hover { color: var(--header-ink); }
.next-pill svg { width: 15px; height: 15px; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 color-mix(in oklab, var(--live) 70%, transparent); } 70% { box-shadow: 0 0 0 8px transparent; } 100% { box-shadow: 0 0 0 0 transparent; } }

.livery-band { display: grid; grid-template-rows: 5px 3px 2px; position: sticky; top: 64px; z-index: 39; }
.livery-band span:nth-child(1) { background: var(--stripe-a, var(--l1)); }
.livery-band span:nth-child(2) { background: var(--accent); }
.livery-band span:nth-child(3) { background: var(--stripe-b, var(--l3)); }

.subnav { background: var(--surface); border-bottom: 1px solid var(--rule); }
.subnav .wrap { display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none; }
.subnav a { padding: 12px 12px 10px; text-decoration: none; color: var(--ink-2); font-weight: 600; font-size: var(--t-s); white-space: nowrap; border-bottom: 3px solid transparent; }
.subnav a:hover { color: var(--ink); }
.subnav a[aria-current="page"] { color: var(--ink); border-bottom-color: var(--accent); }

@media (max-width: 1060px) {
  .menu-btn { display: inline-grid; }
  .nav { display: none; position: absolute; left: 0; right: 0; top: 100%; flex-direction: column; background: var(--header); padding: 8px 12px 16px; border-top: 1px solid color-mix(in oklab, var(--header-ink) 12%, transparent); gap: 0; }
  .nav.open { display: flex; }
  .nav a { padding: 12px 8px; font-size: 1.0625rem; }
  .nav a[aria-current="page"]::after { left: 0; right: auto; top: 10px; bottom: 10px; width: 3px; height: auto; border-radius: 0 2px 2px 0; }
  .masthead-tools { margin-left: auto; }
}
@media (max-width: 560px) { .brand-name { font-size: 1rem; max-width: 46vw; } .next-pill { display: none; } }

/* preferences popover */
.prefs { position: relative; }
.prefs-panel { position: absolute; right: 0; top: calc(100% + 10px); width: min(340px, calc(100vw - 32px)); background: var(--surface); color: var(--ink); border: 1px solid var(--rule); border-radius: var(--r3); box-shadow: 0 18px 50px rgba(0, 0, 0, .28); padding: 16px; z-index: 60; }
.prefs-panel h2 { font-size: var(--t-m); margin-bottom: 12px; }
.prefs-panel .pref { display: grid; gap: 6px; margin-bottom: 14px; }
.prefs-panel .pref > span { font-size: var(--t-s); font-weight: 600; color: var(--ink-2); }
.prefs-panel select { width: 100%; }

/* ------------------------------------------------------------------ buttons & chips */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 42px; padding: 0 18px; border-radius: var(--r2); border: 1px solid transparent; background: var(--accent); color: var(--on-accent); font: inherit; font-weight: 700; font-size: .9375rem; text-decoration: none; cursor: pointer; white-space: nowrap; transition: filter .12s, background-color .12s; }
.btn:hover { filter: brightness(1.06) saturate(1.05); }
.btn:active { filter: brightness(.95); }
.btn svg { width: 18px; height: 18px; flex: none; }
.btn.ghost { background: transparent; color: var(--ink); border-color: var(--rule-strong); }
.btn.ghost:hover { background: var(--surface-2); filter: none; }
.btn.quiet { background: var(--surface-2); color: var(--ink); }
.btn.quiet:hover { background: var(--surface-3); filter: none; }
.btn.danger { background: transparent; color: var(--danger); border-color: color-mix(in oklab, var(--danger) 45%, transparent); }
.btn.danger:hover { background: color-mix(in oklab, var(--danger) 10%, transparent); filter: none; }
.btn.on-dark { background: rgba(255, 255, 255, .12); color: #fff; border-color: rgba(255, 255, 255, .28); backdrop-filter: blur(6px); }
.btn.on-dark:hover { background: rgba(255, 255, 255, .2); filter: none; }
.btn.big { min-height: 52px; padding: 0 24px; font-size: 1.0625rem; }
.btn.small { min-height: 32px; padding: 0 12px; font-size: var(--t-s); }
.btn[disabled], .btn[aria-disabled="true"] { opacity: .45; pointer-events: none; }
.btn-row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }

.chip { display: inline-flex; align-items: center; gap: 6px; min-height: 34px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--rule-strong); background: var(--surface); color: var(--ink-2); font: inherit; font-size: var(--t-s); font-weight: 600; text-decoration: none; cursor: pointer; white-space: nowrap; }
.chip:hover { color: var(--ink); border-color: var(--ink-3); }
.chip[aria-pressed="true"], .chip[aria-current="page"], .chip.on { background: var(--ink); border-color: var(--ink); color: var(--paper); }
.chip .count { font-stretch: var(--narrow); font-variant-numeric: tabular-nums; opacity: .7; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.segmented { display: inline-flex; padding: 3px; gap: 2px; background: var(--surface-2); border-radius: var(--r2); }
.segmented button { border: 0; background: transparent; color: var(--ink-2); font: inherit; font-size: var(--t-s); font-weight: 600; padding: 6px 12px; border-radius: var(--r1); cursor: pointer; }
.segmented button[aria-pressed="true"] { background: var(--surface); color: var(--ink); box-shadow: 0 1px 2px rgba(0, 0, 0, .12); }

/* ------------------------------------------------------------------ status, tags, plates */
.status { display: inline-flex; align-items: center; gap: 7px; font-weight: 700; font-size: var(--t-s); white-space: nowrap; }
.status::before { content: ""; width: 9px; height: 9px; border-radius: 50%; background: var(--off); flex: none; }
.status.live { color: var(--live); }
.status.live::before { background: var(--live); animation: pulse 1.8s ease-out infinite; }
.status.soon::before { background: var(--soon); }
.status.done::before { background: var(--done); }
.status.off { color: var(--ink-2); }
.badge-live { display: inline-flex; align-items: center; gap: 7px; height: 26px; padding: 0 10px; border-radius: var(--r1); background: var(--live); color: #fff; font-weight: 800; font-size: var(--t-xs); letter-spacing: .04em; }
.badge-live::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: #fff; animation: blink 1.4s steps(2, start) infinite; }
@keyframes blink { to { visibility: hidden; } }
.badge-next, .badge-last { display: inline-flex; align-items: center; height: 26px; padding: 0 10px; border-radius: var(--r1); background: rgba(255, 255, 255, .16); color: #fff; font-weight: 700; font-size: var(--t-xs); letter-spacing: .02em; backdrop-filter: blur(4px); }
.tag { display: inline-flex; align-items: center; gap: 5px; height: 22px; padding: 0 8px; border-radius: var(--r1); background: var(--surface-2); color: var(--ink-2); font-size: .75rem; font-weight: 650; white-space: nowrap; vertical-align: middle; }
.tag.mod { background: var(--accent-wash); color: var(--accent-text); }
.tag.green { background: color-mix(in oklab, var(--pb) 16%, var(--surface)); color: var(--pb-text); }
.tag.red { background: color-mix(in oklab, var(--danger) 14%, var(--surface)); color: var(--danger); }
.tag.purple { background: color-mix(in oklab, var(--fastest) 16%, var(--surface)); color: var(--fastest-text); }
.tag.traffic { background: color-mix(in oklab, var(--s3) 18%, var(--surface)); color: var(--ink); }

.plate { display: inline-grid; place-items: center; min-width: 30px; height: 26px; padding: 0 6px; border-radius: var(--r1); background: var(--surface-3); color: var(--ink); font-weight: 800; font-stretch: var(--narrow); font-size: .9375rem; font-variant-numeric: tabular-nums; line-height: 1; }
.plate.p1 { background: var(--accent); color: var(--on-accent); }
.plate.p2, .plate.p3 { background: var(--ink); color: var(--paper); }
.plate.out { background: transparent; color: var(--ink-3); border: 1px dashed var(--rule-strong); }
.num-board { display: inline-grid; place-items: center; min-width: 58px; height: 46px; padding: 0 10px; border-radius: var(--r2); background: var(--surface); color: var(--ink); border: 2px solid var(--ink); font-weight: 900; font-style: italic; font-stretch: 112%; font-size: 1.5rem; line-height: 1; }
.livery { width: 18px; height: 18px; border-radius: 50%; object-fit: cover; flex: none; background: var(--surface-3); box-shadow: 0 0 0 1px var(--rule-strong); }
.livery.lg { width: 28px; height: 28px; }
.driver-cell { display: flex; align-items: center; gap: 10px; min-width: 0; }
.driver-cell .name { font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.driver-cell a.name { text-decoration: none; }
.driver-cell a.name:hover { text-decoration: underline; }
.driver-cell .team { display: block; font-size: var(--t-xs); color: var(--ink-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.nation { font-size: .6875rem; font-weight: 800; letter-spacing: .04em; color: var(--ink-3); border: 1px solid var(--rule-strong); border-radius: var(--r1); padding: 1px 4px; }

/* the outline of a track, painted in the accent (the png is used as a mask) */
.outline { display: block; width: 56px; aspect-ratio: 36 / 26; background: var(--accent-mark); -webkit-mask: var(--mask) center / contain no-repeat; mask: var(--mask) center / contain no-repeat; flex: none; }
.outline.ink { background: var(--ink); }
.outline.light { background: #fff; }
.outline-img { width: 56px; height: 40px; object-fit: contain; flex: none; }

/* ------------------------------------------------------------------ surfaces */
.panel { background: var(--surface); border: 1px solid var(--rule); border-radius: var(--r3); padding: var(--pad); }
.panel.flush { padding: 0; overflow: hidden; }
.panel > h3:first-child, .panel > h2:first-child { margin-bottom: 12px; }
.well { background: var(--surface-2); border-radius: var(--r3); padding: var(--pad); }
.empty { border: 1px dashed var(--rule-strong); border-radius: var(--r3); padding: 22px; color: var(--ink-2); background: color-mix(in oklab, var(--surface) 60%, transparent); }
.empty strong { color: var(--ink); }
.callout { border-left: 4px solid var(--accent); background: var(--surface); padding: 14px 16px; border-radius: 0 var(--r2) var(--r2) 0; }

.flash { list-style: none; padding: 0; margin: 20px 0 0; display: grid; gap: 8px; }
.flash li { background: var(--surface); border: 1px solid var(--rule); border-left: 5px solid var(--done); padding: 12px 16px; border-radius: var(--r2); font-weight: 500; }
.flash li.warn { border-left-color: var(--soon); }
.flash li.error { border-left-color: var(--danger); }
.errors { border: 1px solid color-mix(in oklab, var(--danger) 40%, var(--rule)); background: color-mix(in oklab, var(--danger) 7%, var(--surface)); border-radius: var(--r2); padding: 12px 16px; margin: 12px 0; }
.errors ul { margin: 6px 0 0; padding-left: 20px; }

/* ------------------------------------------------------------------ hero (home, event pages) */
.hero { position: relative; margin-top: 24px; border-radius: var(--r3); overflow: hidden; background: var(--l3); color: #fff; isolation: isolate; min-height: 440px; display: flex; }
.hero-media { position: absolute; inset: 0; margin: 0; z-index: -2; }
.hero-media img { width: 100%; height: 100%; object-fit: cover; }
.hero-media .outline { position: absolute; right: 6%; top: 10%; width: 46%; height: 80%; aspect-ratio: auto; background: color-mix(in oklab, var(--accent) 70%, #fff); opacity: .9; }
.hero::before { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, rgba(5, 8, 12, .86) 0%, rgba(5, 8, 12, .62) 42%, rgba(5, 8, 12, .22) 100%), linear-gradient(0deg, rgba(5, 8, 12, .7) 0%, rgba(5, 8, 12, 0) 45%); }
.hero-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(280px, 360px); gap: 28px; padding: 36px 36px 32px; width: 100%; align-items: end; }
.hero-body { display: grid; gap: 12px; align-content: end; min-width: 0; animation: lower-third .5s cubic-bezier(.2, .7, .2, 1) both; }
.hero-kicker { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; font-weight: 600; color: rgba(255, 255, 255, .86); font-size: var(--t-s); margin: 0; }
.hero-title { font-size: clamp(2.4rem, 6.2vw, 4.6rem); font-stretch: var(--wide); font-style: italic; font-weight: 850; letter-spacing: -.025em; line-height: .95; text-wrap: balance; text-shadow: 0 2px 24px rgba(0, 0, 0, .35); }
.hero-title a { text-decoration: none; }
.hero-sub { font-size: var(--t-l); color: rgba(255, 255, 255, .88); margin: 0; max-width: 56ch; }
.hero-facts { display: flex; flex-wrap: wrap; gap: 8px 18px; color: rgba(255, 255, 255, .8); font-size: var(--t-s); }
.hero-facts b { color: #fff; font-stretch: var(--narrow); font-variant-numeric: tabular-nums; font-size: 1rem; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 6px; }
.hero-side { align-self: stretch; display: flex; flex-direction: column; justify-content: flex-end; min-width: 0; }
.hero-stripes { position: absolute; right: -40px; bottom: 26px; width: 280px; height: 26px; transform: skewX(-24deg); display: grid; grid-template-rows: 12px 8px 6px; z-index: -1; opacity: .95; }
.hero-stripes span:nth-child(1) { background: var(--stripe-a, var(--l1)); }
.hero-stripes span:nth-child(2) { background: var(--accent); }
.hero-stripes span:nth-child(3) { background: var(--stripe-b, var(--l3)); }
@keyframes lower-third { from { opacity: 0; transform: translateX(-24px); } to { opacity: 1; transform: none; } }
@media (max-width: 860px) {
  .hero { border-radius: 0; margin-left: -20px; margin-right: -20px; min-height: 0; }
  .hero-grid { grid-template-columns: 1fr; padding: 120px 20px 24px; }
  .hero::before { background: linear-gradient(0deg, rgba(5, 8, 12, .92) 0%, rgba(5, 8, 12, .7) 55%, rgba(5, 8, 12, .25) 100%); }
  .hero-stripes { display: none; }
}
@media (max-width: 560px) { .hero { margin-left: -16px; margin-right: -16px; } .hero-grid { padding: 96px 16px 20px; } }

/* timing tower (hero side, live page) */
.tower { background: rgba(6, 10, 16, .74); backdrop-filter: blur(10px); border: 1px solid rgba(255, 255, 255, .12); border-radius: var(--r3); overflow: hidden; color: #fff; }
.tower-head { display: flex; justify-content: space-between; align-items: center; padding: 10px 12px; font-size: var(--t-xs); font-weight: 700; color: rgba(255, 255, 255, .78); border-bottom: 1px solid rgba(255, 255, 255, .12); gap: 10px; }
.tower-head .clock { font-stretch: var(--narrow); font-size: 1.0625rem; color: #fff; font-variant-numeric: tabular-nums; }
.tower ol { list-style: none; margin: 0; padding: 4px 0; }
.tower li { display: grid; grid-template-columns: 30px 18px minmax(0, 1fr) auto; gap: 8px; align-items: center; padding: 5px 12px; font-size: .9375rem; }
.tower li .p { font-weight: 800; font-stretch: var(--narrow); text-align: center; font-variant-numeric: tabular-nums; }
.tower li:first-child .p { color: var(--accent); }
.tower li .n { font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tower li .g { font-stretch: var(--narrow); font-variant-numeric: tabular-nums; color: rgba(255, 255, 255, .8); font-weight: 600; }
.tower li.me { background: rgba(255, 255, 255, .1); box-shadow: inset 3px 0 0 var(--accent); }
.tower-foot { padding: 8px 12px 12px; }

/* countdown block (hero side) */
.countdown { background: rgba(6, 10, 16, .66); backdrop-filter: blur(10px); border: 1px solid rgba(255, 255, 255, .12); border-radius: var(--r3); padding: 16px; display: grid; gap: 12px; }
.countdown .units { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
.countdown .unit { background: rgba(255, 255, 255, .08); border-radius: var(--r2); padding: 10px 4px 8px; text-align: center; }
.countdown .unit b { display: block; font-size: 2rem; font-weight: 800; font-stretch: var(--narrow); font-variant-numeric: tabular-nums; line-height: 1; }
.countdown .unit span { font-size: .75rem; color: rgba(255, 255, 255, .72); font-weight: 600; }
.countdown .when { font-weight: 700; }
.countdown .when small { display: block; font-weight: 500; color: rgba(255, 255, 255, .72); }

/* podium (hero side, result page) */
.podium { display: grid; grid-template-columns: 1fr 1.15fr 1fr; gap: 8px; align-items: end; }
.podium .step { background: rgba(6, 10, 16, .66); backdrop-filter: blur(10px); border: 1px solid rgba(255, 255, 255, .12); border-radius: var(--r3); overflow: hidden; color: #fff; display: grid; }
.podium .step img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; }
.podium .step .who { padding: 8px 10px 10px; display: grid; gap: 2px; min-width: 0; }
.podium .step .who b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.podium .step .who small { color: rgba(255, 255, 255, .72); font-stretch: var(--narrow); font-variant-numeric: tabular-nums; font-weight: 600; }
.podium .step .pos { font-weight: 900; font-style: italic; font-stretch: 112%; font-size: 1.25rem; line-height: 1; }
.podium .step.first .pos { color: var(--accent); }
.podium .step.first { padding-bottom: 18px; }
.podium.on-paper .step { background: var(--surface); color: var(--ink); border-color: var(--rule); backdrop-filter: none; }
.podium.on-paper .step .who small { color: var(--ink-3); }
.podium.on-paper .step.first .pos { color: var(--accent-text); }

/* second server strip under the hero */
.pitwall { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr)); gap: 12px; margin-top: 12px; }
.pw-tile { position: relative; display: grid; grid-template-columns: 128px minmax(0, 1fr) auto; gap: 14px; align-items: center; background: var(--surface); border: 1px solid var(--rule); border-radius: var(--r3); padding: 8px 12px 8px 8px; overflow: hidden; }
.pw-tile.pw-live { border-color: color-mix(in oklab, var(--live) 45%, var(--rule)); }
.pw-tile.pw-live::before { content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 4px; background: var(--live); }
.pw-pic { width: 128px; height: 72px; border-radius: var(--r2); overflow: hidden; background: var(--l3); display: grid; place-items: center; }
.pw-pic img { width: 100%; height: 100%; object-fit: cover; display: block; }
.pw-pic .outline { width: 80%; height: 80%; background: #fff; }
.pw-tile:not(.pw-live) .pw-pic img { filter: saturate(.55) brightness(.92); }
.pw-body { min-width: 0; display: grid; gap: 2px; }
.pw-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 10px; }
.pw-state { font-size: var(--t-xs); color: var(--ink-3); font-weight: 600; }
.pw-live .pw-state { color: var(--live-text, var(--live)); }
.pw-title { font-size: 1.0625rem; font-weight: 750; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pw-body small { color: var(--ink-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pw-act { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
@media (max-width: 560px) { .pw-tile { grid-template-columns: 88px minmax(0, 1fr); } .pw-pic { width: 88px; height: 56px; } .pw-act { grid-column: 1 / -1; justify-content: flex-start; } .pw-act:empty { display: none; } }

/* ------------------------------------------------------------------ tables (timing sheets) */
.sheet-wrap { position: relative; overflow-x: auto; border: 1px solid var(--rule); border-radius: var(--r3); background: var(--surface); -webkit-overflow-scrolling: touch; }
table.sheet { width: 100%; border-collapse: collapse; font-size: .9375rem; }
.sheet th { text-align: left; font-size: var(--t-xs); font-weight: 650; color: var(--ink-2); padding: 10px 12px; border-bottom: 1px solid var(--rule-strong); white-space: nowrap; background: var(--surface); position: sticky; top: 0; }
.sheet td { padding: 0 12px; height: var(--row-h); border-bottom: 1px solid var(--rule); vertical-align: middle; }
.sheet tr:last-child td { border-bottom: 0; }
.sheet tbody tr:hover td { background: color-mix(in oklab, var(--surface-2) 60%, var(--surface)); }
.sheet .r, .sheet th.r { text-align: right; }
.sheet td.time, .sheet td.pts { font-stretch: var(--narrow); font-weight: 600; font-variant-numeric: tabular-nums; text-align: right; white-space: nowrap; }
.sheet td.pts { font-weight: 800; font-size: 1.0625rem; }
.sheet td.pos { width: 48px; }
@media (max-width: 480px) { .sheet th { padding: 9px 7px; } .sheet td { padding: 0 7px; } .sheet td.pos { width: 38px; } .sheet .driver-cell { max-width: 170px; } }
.sheet td.fastest, .sheet td .fastest, .fastest { color: var(--fastest-text); font-weight: 800; }
.sheet td.pb, .pb { color: var(--pb-text); font-weight: 700; }
.sheet tr.me td { background: var(--accent-wash) !important; }
.sheet tr.me td:first-child { box-shadow: inset 4px 0 0 var(--accent); }
.sheet tr.dsq td { color: var(--ink-3); }
.sheet tr.unclassified td { color: var(--ink-3); }
.sheet .sub { display: block; font-size: var(--t-xs); color: var(--ink-3); font-weight: 500; }
.sheet .car-cell { display: flex; align-items: center; gap: 10px; min-width: 0; }
.sheet .car-cell img { width: 56px; height: 32px; object-fit: cover; border-radius: var(--r1); flex: none; background: var(--surface-2); }
.sheet .car-cell span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sheet .bar { display: block; height: 6px; border-radius: 0 3px 3px 0; background: var(--accent-mark); margin-top: 4px; min-width: 2px; }
.sheet td.heat { text-align: center; font-stretch: var(--narrow); font-variant-numeric: tabular-nums; font-weight: 600; width: 44px; padding: 0 4px; }
.sheet td.heat[data-heat="3"] { background: var(--accent-wash-2); }
.sheet td.heat[data-heat="2"] { background: var(--accent-wash); }
.sheet td.heat s { color: var(--ink-3); }
.sheet .small-input { width: 76px; }
@media (max-width: 720px) {
  table.sheet { font-size: .875rem; }
  .sheet td, .sheet th { padding-left: 8px; padding-right: 8px; }
  .sheet .hide-s { display: none; }
  .sheet .car-cell img { display: none; }
}

/* ------------------------------------------------------------------ lists & cards */
.race-list { display: grid; gap: 10px; }
.race-card { display: grid; grid-template-columns: 64px minmax(0, 1fr) auto; gap: 14px; align-items: center; padding: 12px 14px; background: var(--surface); border: 1px solid var(--rule); border-radius: var(--r3); text-decoration: none; color: inherit; transition: border-color .12s; }
.race-card:hover { border-color: var(--rule-strong); }
.race-card .outline { width: 64px; }
.race-card .what { min-width: 0; display: grid; gap: 3px; }
.race-card .what b { font-size: 1.0625rem; font-stretch: 104%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.race-card .what small { color: var(--ink-3); }
.race-card .podium-line { display: flex; gap: 6px 14px; flex-wrap: wrap; font-size: var(--t-s); }
.race-card .podium-line span { display: inline-flex; align-items: center; gap: 6px; }
.race-card .podium-line .plate { min-width: 24px; height: 20px; font-size: .8125rem; }
.race-card .side { text-align: right; display: grid; gap: 2px; justify-items: end; }
.race-card .side small { color: var(--ink-3); font-size: var(--t-xs); }
@media (max-width: 560px) { .race-card { grid-template-columns: 44px minmax(0, 1fr); } .race-card .outline { width: 44px; } .race-card .side { grid-column: 2; justify-items: start; text-align: left; } }

.day-head { display: flex; align-items: baseline; gap: 12px; margin: 26px 0 10px; }
.day-head h3 { font-size: var(--t-l); }
.day-head .muted { font-size: var(--t-s); }

/* showroom grid: cars and tracks */
.showroom { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 16px; }
.car-card, .track-card { position: relative; display: grid; grid-template-rows: auto 1fr; background: var(--surface); border: 1px solid var(--rule); border-radius: var(--r3); overflow: hidden; text-decoration: none; color: inherit; transition: border-color .15s, transform .15s; }
.car-card:hover, .track-card:hover { border-color: var(--rule-strong); transform: translateY(-2px); }
.car-card .shot, .track-card .shot { position: relative; aspect-ratio: 16 / 9; background: var(--surface-3); overflow: hidden; }
.car-card .shot img, .track-card .shot img { width: 100%; height: 100%; object-fit: cover; transition: transform .35s ease; }
.car-card:hover .shot img, .track-card:hover .shot img { transform: scale(1.03); }
.car-card .shot img.badge { position: absolute; left: 10px; top: 10px; width: 34px; height: 34px; object-fit: contain; border-radius: 50%; background: rgba(255, 255, 255, .92); padding: 3px; box-shadow: 0 2px 8px rgba(0, 0, 0, .25); transform: none; }
.car-card .flags, .track-card .flags { position: absolute; right: 8px; top: 8px; display: flex; gap: 6px; }
.car-card .flags .tag, .track-card .flags .tag { background: rgba(6, 10, 16, .72); color: #fff; backdrop-filter: blur(4px); }
.car-card .body, .track-card .body { padding: 12px 14px 14px; display: grid; gap: 6px; align-content: start; }
.car-card .brand-line { font-size: var(--t-xs); font-weight: 650; color: var(--ink-3); }
.car-card h3, .track-card h3 { font-size: 1.0625rem; font-stretch: 102%; line-height: 1.2; }
.car-card .specs { display: flex; gap: 14px; font-size: var(--t-s); color: var(--ink-2); flex-wrap: wrap; }
.car-card .specs b { color: var(--ink); font-stretch: var(--narrow); font-weight: 700; font-variant-numeric: tabular-nums; }
.car-card .swatches { display: flex; gap: 4px; margin-top: 2px; }
.car-card .swatches img { width: 16px; height: 16px; border-radius: 50%; box-shadow: 0 0 0 1px var(--rule-strong); }
.car-card .swatches .more { font-size: var(--t-xs); color: var(--ink-3); font-weight: 600; margin-left: 2px; line-height: 16px; }
.track-card .shot .outline { position: absolute; right: 10px; bottom: 10px; width: 92px; height: 66px; aspect-ratio: auto; background: #fff; filter: drop-shadow(0 1px 4px rgba(0, 0, 0, .6)); }
.track-card .facts { display: flex; gap: 12px; flex-wrap: wrap; font-size: var(--t-s); color: var(--ink-2); }
.track-card .facts b { color: var(--ink); font-stretch: var(--narrow); font-weight: 700; font-variant-numeric: tabular-nums; }
.shot .fallback { position: absolute; inset: 0; display: grid; place-items: center; background: linear-gradient(135deg, var(--l3), color-mix(in oklab, var(--l3) 60%, #000)); color: #fff; }
.shot .fallback .outline { position: static; width: 60%; height: 70%; aspect-ratio: auto; background: color-mix(in oklab, var(--accent) 70%, #fff); }
.shot .fallback b { font-stretch: var(--wide); font-style: italic; font-weight: 900; font-size: 1.6rem; opacity: .9; }

.filters { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-bottom: 18px; position: sticky; top: 74px; z-index: 20; background: color-mix(in oklab, var(--paper) 92%, transparent); backdrop-filter: blur(8px); padding: 10px 0; }
.filters input[type="search"] { flex: 1 1 220px; max-width: 320px; }
.filters select { width: auto; }
.filters .result-count { margin-left: auto; font-size: var(--t-s); color: var(--ink-3); }

/* drivers */
.driver-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 14px; }
.driver-card { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 4px 14px; align-items: center; padding: 14px; background: var(--surface); border: 1px solid var(--rule); border-radius: var(--r3); text-decoration: none; color: inherit; position: relative; overflow: hidden; }
.driver-card:hover { border-color: var(--rule-strong); }
.driver-card .num-board { grid-row: span 2; }
.driver-card b { font-size: 1.0625rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.driver-card small { color: var(--ink-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.driver-card .stats-line { grid-column: 1 / -1; display: flex; gap: 14px; font-size: var(--t-s); color: var(--ink-2); margin-top: 8px; padding-top: 10px; border-top: 1px solid var(--rule); }
.driver-card .stats-line b { font-size: 1rem; color: var(--ink); font-stretch: var(--narrow); font-variant-numeric: tabular-nums; }
.driver-card.me { border-color: var(--accent-mark); box-shadow: inset 0 0 0 1px var(--accent-mark); }
.driver-rail { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(230px, 1fr); gap: 14px; overflow-x: auto; padding-bottom: 6px; scroll-snap-type: x proximity; }
.driver-rail > * { scroll-snap-align: start; }

/* stat tiles */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 1px; background: var(--rule); border: 1px solid var(--rule); border-radius: var(--r3); overflow: hidden; }
.stats > div { background: var(--surface); padding: 14px 16px; display: grid; gap: 4px; }
.stats b { font-size: 2rem; font-weight: 800; font-stretch: 88%; line-height: 1; }
.stats span { font-size: var(--t-s); color: var(--ink-2); font-weight: 500; }
.stats.on-dark { background: rgba(255, 255, 255, .14); border-color: rgba(255, 255, 255, .14); }
.stats.on-dark > div { background: rgba(6, 10, 16, .6); }
.stats.on-dark span { color: rgba(255, 255, 255, .74); }

/* form guide: last results as plates */
.form-guide { display: flex; gap: 4px; flex-wrap: wrap; }
.form-guide a { text-decoration: none; }
.form-guide .plate { min-width: 32px; height: 30px; }

/* records list */
.record-list { display: grid; gap: 1px; background: var(--rule); border: 1px solid var(--rule); border-radius: var(--r3); overflow: hidden; }
.record-row { display: grid; grid-template-columns: 52px minmax(0, 1.4fr) minmax(0, 1fr) auto; gap: 14px; align-items: center; padding: 10px 14px; background: var(--surface); text-decoration: none; color: inherit; }
.record-row:hover { background: color-mix(in oklab, var(--surface-2) 60%, var(--surface)); }
.record-row .outline { width: 52px; }
.record-row .what { min-width: 0; display: grid; }
.record-row .what b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.record-row .what small { color: var(--ink-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.record-row .time { font-stretch: var(--narrow); font-weight: 800; font-variant-numeric: tabular-nums; font-size: 1.125rem; color: var(--fastest-text); }
@media (max-width: 640px) { .record-row { grid-template-columns: 40px minmax(0, 1fr) auto; } .record-row .holder { display: none; } .record-row .outline { width: 40px; } }

/* garage spotlight */
.spotlight { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); background: var(--surface); border: 1px solid var(--rule); border-radius: var(--r3); overflow: hidden; text-decoration: none; color: inherit; }
.spotlight img { width: 100%; height: 100%; object-fit: cover; aspect-ratio: 16 / 10; }
.spotlight .body { padding: 18px; display: grid; gap: 10px; align-content: center; }
.spotlight .body small { color: var(--ink-3); font-weight: 600; }
.spotlight h3 { font-size: var(--t-xl); font-stretch: 108%; }
@media (max-width: 640px) { .spotlight { grid-template-columns: 1fr; } }

/* ------------------------------------------------------------------ detail heroes (car, track, driver) */
.detail-hero { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); gap: 0; background: var(--surface); border: 1px solid var(--rule); border-radius: var(--r3); overflow: hidden; margin-top: 18px; }
.detail-hero .stage { position: relative; background: #0d1116; color: #fff; display: flex; flex-direction: column; justify-content: center; min-width: 0; }
.detail-hero .stage-img { position: relative; aspect-ratio: 16 / 9; overflow: hidden; }
.detail-hero .stage-img img.main { width: 100%; height: 100%; object-fit: cover; display: block; }
.detail-hero .stage-img .fallback { position: absolute; inset: 0; display: grid; place-items: center; font-size: 4rem; font-weight: 900; font-style: italic; color: rgba(255, 255, 255, .2); }
.detail-hero .stage-img .fallback .outline { width: 70%; height: 70%; background: #fff; }
.detail-hero .stage .outline { position: absolute; right: 14px; bottom: 14px; width: 120px; height: 86px; aspect-ratio: auto; background: #fff; filter: drop-shadow(0 1px 6px rgba(0, 0, 0, .6)); }
.detail-hero .stage-foot { display: grid; gap: 10px; padding: 14px 18px 18px; border-top: 1px solid rgba(255, 255, 255, .08); }
.detail-hero .stage-foot .label { color: rgba(255, 255, 255, .7); margin: 0; flex: none; }
.detail-hero .stage-foot .skin-caption { color: #fff; font-weight: 600; text-align: right; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.detail-hero .stage-foot .skins button { box-shadow: 0 0 0 1px rgba(255, 255, 255, .28); background: rgba(255, 255, 255, .08); }
.detail-hero .stage-foot .skins button[aria-pressed="true"] { box-shadow: 0 0 0 2px #0d1116, 0 0 0 4px var(--accent); }
.detail-hero .info { padding: 22px; display: grid; gap: 14px; align-content: start; }
.detail-hero .info h1 { font-size: clamp(1.9rem, 3.4vw, 2.75rem); font-stretch: 112%; font-style: italic; font-weight: 850; letter-spacing: -.02em; }
.detail-hero .brand-row { display: flex; align-items: center; gap: 10px; color: var(--ink-2); font-weight: 600; }
.detail-hero .brand-row img { width: 34px; height: 34px; object-fit: contain; }
@media (max-width: 900px) { .detail-hero { grid-template-columns: 1fr; } }
.skins { display: flex; flex-wrap: wrap; gap: 8px; }
.skins button { position: relative; width: 40px; height: 40px; border-radius: 50%; border: 0; padding: 0; background: var(--surface-3); cursor: pointer; box-shadow: 0 0 0 1px var(--rule-strong); }
.skins button img { width: 100%; height: 100%; border-radius: 50%; object-fit: cover; }
.skins button[aria-pressed="true"] { box-shadow: 0 0 0 2px var(--surface), 0 0 0 4px var(--accent-mark); }
.skin-picker { display: grid; gap: 10px; }
.skin-caption { font-size: var(--t-s); color: var(--ink-2); min-height: 1.4em; margin: 0; }
.spec-board { display: flex; flex-wrap: wrap; gap: 1px; background: var(--rule); border: 1px solid var(--rule); border-radius: var(--r2); overflow: hidden; }
.spec-board > div { flex: 1 1 96px; background: var(--surface); padding: 10px 12px; }
.spec-board b { display: block; font-size: 1.5rem; font-weight: 800; font-stretch: 88%; line-height: 1.1; }
.spec-board span { font-size: var(--t-xs); color: var(--ink-3); font-weight: 600; }
.layout-tabs { display: flex; flex-wrap: wrap; gap: 8px; margin: 20px 0 4px; }
.layout-card { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 22px; padding: 18px; background: var(--surface); border: 1px solid var(--rule); border-radius: var(--r3); }
.layout-card .outline { width: 100%; height: 160px; aspect-ratio: auto; }
@media (max-width: 720px) { .layout-card { grid-template-columns: 1fr; } .layout-card .outline { height: 120px; } }
.facts-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 10px 18px; }
.facts-grid div { display: grid; }
.facts-grid b { font-stretch: var(--narrow); font-size: 1.25rem; font-weight: 800; font-variant-numeric: tabular-nums; }
.facts-grid span { font-size: var(--t-xs); color: var(--ink-3); font-weight: 600; }

.driver-hero { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); background: var(--header); color: #fff; border-radius: var(--r3); overflow: hidden; margin-top: 18px; isolation: isolate; }
.driver-hero .who { padding: 28px; display: grid; gap: 14px; align-content: end; }
.driver-hero .bignum { font-size: clamp(4rem, 9vw, 7rem); font-weight: 900; font-style: italic; font-stretch: var(--wide); line-height: .85; color: var(--accent); letter-spacing: -.04em; }
.driver-hero h1 { font-size: clamp(2rem, 4vw, 3.2rem); font-stretch: 112%; font-style: italic; font-weight: 850; }
.driver-hero .meta { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; color: rgba(255, 255, 255, .8); }
.driver-hero .meta .nation { color: #fff; border-color: rgba(255, 255, 255, .4); }
.driver-hero .car { position: relative; min-height: 260px; }
.driver-hero .car img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.driver-hero .car::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, var(--header) 0%, transparent 40%); }
.driver-hero .car small { position: absolute; right: 14px; bottom: 12px; z-index: 1; color: rgba(255, 255, 255, .8); font-weight: 600; text-shadow: 0 1px 6px rgba(0, 0, 0, .6); }
@media (max-width: 760px) { .driver-hero { grid-template-columns: 1fr; } .driver-hero .car { min-height: 200px; order: -1; } .driver-hero .car::after { background: linear-gradient(0deg, var(--header) 0%, transparent 50%); } }

/* ------------------------------------------------------------------ charts */
.chart { position: relative; }
.chart svg { width: 100%; height: auto; overflow: visible; font-family: var(--font); }
.chart-svg.narrow { display: none; }
@media (max-width: 640px) { .chart-svg.wide { display: none; } .chart-svg.narrow { display: block; } }
.chart .grid line { stroke: var(--rule); stroke-width: 1; }
.chart .axis text, .chart .tick { fill: var(--ink-3); font-size: calc(12px * var(--k, 1)); font-stretch: var(--narrow); font-variant-numeric: tabular-nums; }
.chart .axis-label { fill: var(--ink-2); font-size: calc(12px * var(--k, 1)); font-weight: 600; }
.chart svg.tight .axis-label { display: none; }
.chart .series { fill: none; stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
.chart .series.dim { stroke: var(--s-other); stroke-width: 1.5; opacity: .7; }
.chart .series.me { stroke-width: 3; }
.chart .dot { stroke: var(--surface); stroke-width: 2; }
.chart .crosshair { stroke: var(--ink-3); stroke-width: 1; }
.chart .hit { fill: transparent; }
.chart .area { opacity: .1; }
.chart-tip { position: absolute; pointer-events: none; z-index: 5; background: var(--surface); color: var(--ink); border: 1px solid var(--rule-strong); border-radius: var(--r2); box-shadow: 0 10px 30px rgba(0, 0, 0, .18); padding: 8px 10px; font-size: var(--t-s); min-width: 150px; }
.chart-tip .t { font-weight: 700; margin-bottom: 4px; }
.chart-tip .row { display: grid; grid-template-columns: 14px minmax(0, 1fr) auto; gap: 8px; align-items: center; }
.chart-tip .row i { display: block; height: 3px; border-radius: 2px; }
.chart-tip .row b { font-stretch: var(--narrow); font-variant-numeric: tabular-nums; }
.legend { display: flex; flex-wrap: wrap; gap: 6px 14px; margin: 10px 0 0; padding: 0; list-style: none; font-size: var(--t-s); }
.legend li { display: inline-flex; align-items: center; gap: 7px; }
.legend li i { display: block; width: 16px; height: 3px; border-radius: 2px; }
.legend button { border: 0; background: none; padding: 2px 0; font: inherit; color: var(--ink-2); cursor: pointer; display: inline-flex; align-items: center; gap: 7px; }
.legend button[aria-pressed="false"] { opacity: .45; }
.legend button[aria-pressed="false"] i { background: var(--s-other) !important; }
.c1 { stroke: var(--s1); background: var(--s1); fill: var(--s1); } .c2 { stroke: var(--s2); background: var(--s2); fill: var(--s2); }
.c3 { stroke: var(--s3); background: var(--s3); fill: var(--s3); } .c4 { stroke: var(--s4); background: var(--s4); fill: var(--s4); }
.c5 { stroke: var(--s5); background: var(--s5); fill: var(--s5); } .c6 { stroke: var(--s6); background: var(--s6); fill: var(--s6); }
.c7 { stroke: var(--s7); background: var(--s7); fill: var(--s7); } .c8 { stroke: var(--s8); background: var(--s8); fill: var(--s8); }
.c-acc { stroke: var(--accent-mark); background: var(--accent-mark); fill: var(--accent-mark); }
.chart .series.c1, .chart .series.c2, .chart .series.c3, .chart .series.c4, .chart .series.c5, .chart .series.c6, .chart .series.c7, .chart .series.c8, .chart .series.c-acc { fill: none; }

/* ------------------------------------------------------------------ live timing */
.live-head { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 20px; align-items: end; margin: 24px 0 18px; }
.live-head h1 { font-stretch: var(--wide); font-style: italic; font-weight: 850; font-size: clamp(2rem, 4.6vw, 3.2rem); }
.live-head .clock { font-size: 2.6rem; font-weight: 800; font-stretch: var(--narrow); font-variant-numeric: tabular-nums; line-height: 1; text-align: right; }
.live-grid { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(300px, 1fr); gap: var(--gap); }
@media (max-width: 960px) { .live-grid { grid-template-columns: 1fr; } .live-head { grid-template-columns: 1fr; } .live-head .clock { text-align: left; } }
.map { position: relative; background: var(--header); border-radius: var(--r3); padding: 14px; }
.map img { width: 100%; height: auto; opacity: .75; filter: drop-shadow(0 0 1px rgba(255, 255, 255, .3)); }
.map .dot { position: absolute; transform: translate(-50%, -50%); min-width: 22px; height: 22px; padding: 0 4px; border-radius: 11px; background: #fff; color: #0b0d10; font-weight: 800; font-size: 12px; font-stretch: var(--narrow); display: grid; place-items: center; box-shadow: 0 0 0 2px var(--header); transition: left .9s linear, top .9s linear; }
.map .dot.lead { background: var(--accent); color: var(--on-accent); }
.map .dot.me { background: var(--live); color: #fff; }
.feed { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; font-size: var(--t-s); max-height: 280px; overflow: auto; }
.feed li { display: grid; grid-template-columns: 46px minmax(0, 1fr); gap: 8px; }
.feed time { color: var(--ink-3); font-stretch: var(--narrow); font-variant-numeric: tabular-nums; }
.feed li.muted { display: block; }
.live-grid > * { min-width: 0; }
@media (max-width: 480px) { .hide-xs { display: none; } }
.live-head .clock-box { display: grid; justify-items: end; gap: 4px; }
.live-head .clock-box .label { margin: 0; color: var(--ink-3); font-size: var(--t-xs); }
.live-head .clock-box .btn { margin-top: 10px; }
@media (max-width: 960px) { .live-head .clock-box { justify-items: start; } }

/* ------------------------------------------------------------------ forms */
label, .label { display: block; font-weight: 650; font-size: var(--t-s); margin-bottom: 6px; color: var(--ink); }
input[type="text"], input[type="password"], input[type="number"], input[type="url"], input[type="search"], input[type="email"],
input[type="datetime-local"], input[type="time"], input[type="date"], select, textarea {
  width: 100%; min-height: 42px; padding: 8px 12px; border: 1px solid var(--rule-strong); border-radius: var(--r2); background: var(--surface); color: var(--ink); font: inherit; font-size: .9375rem;
}
textarea { min-height: 96px; line-height: 1.45; resize: vertical; }
input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 3px solid color-mix(in oklab, var(--focus) 55%, transparent); outline-offset: 0; border-color: var(--focus); }
input[type="file"] { font: inherit; font-size: var(--t-s); max-width: 100%; }
input[type="color"] { width: 52px; height: 42px; padding: 3px; border: 1px solid var(--rule-strong); border-radius: var(--r2); background: var(--surface); cursor: pointer; }
input[type="checkbox"], input[type="radio"] { width: 18px; height: 18px; accent-color: var(--accent-mark); margin: 2px 0 0; flex: none; }
.hint { display: block; font-size: var(--t-xs); color: var(--ink-3); margin-top: 6px; font-weight: 500; line-height: 1.4; }
.check { display: flex; gap: 10px; align-items: flex-start; font-weight: 500; font-size: .9375rem; margin: 0; cursor: pointer; }
.check > span { display: block; }
fieldset { border: 1px solid var(--rule); border-radius: var(--r3); padding: 18px 20px 20px; margin: 0 0 18px; background: var(--surface); min-width: 0; }
legend { font-weight: 800; font-stretch: 104%; font-size: 1.0625rem; padding: 0 8px; margin-left: -8px; }
.fields { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 16px 18px; }
.fields > div { min-width: 0; }
.form-actions { display: flex; flex-wrap: wrap; gap: 10px; position: sticky; bottom: 0; padding: 14px 0; background: linear-gradient(0deg, var(--paper) 70%, transparent); z-index: 10; }
.inline { display: inline; }
form.row { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
form.row input[type="text"], form.row select { width: auto; flex: 1 1 160px; }
.narrow { max-width: 460px; }

/* visual pickers (race control) */
.picker { border: 1px solid var(--rule); border-radius: var(--r3); background: var(--surface); }
.picker-tools { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; padding: 12px; border-bottom: 1px solid var(--rule); position: sticky; top: 74px; background: var(--surface); z-index: 5; border-radius: var(--r3) var(--r3) 0 0; }
.picker-tools input[type="search"] { flex: 1 1 200px; max-width: 280px; }
.picker-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); grid-auto-rows: max-content; align-content: start; gap: 10px; padding: 12px; max-height: 560px; overflow: auto; }
.pick { position: relative; display: grid; border: 2px solid transparent; border-radius: var(--r2); background: var(--surface-2); cursor: pointer; overflow: hidden; }
.pick input { position: absolute; top: 8px; left: 8px; z-index: 2; }
.pick img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; background: var(--surface-3); }
.pick .t { padding: 6px 8px 8px; font-size: var(--t-s); font-weight: 650; line-height: 1.25; }
.pick .t small { display: block; color: var(--ink-3); font-weight: 500; }
.pick:has(input:checked) { border-color: var(--accent-mark); background: var(--accent-wash); }
.pick:has(input:focus-visible) { outline: 3px solid var(--focus); outline-offset: 1px; }
.picker-count { padding: 10px 12px; font-size: var(--t-s); color: var(--ink-2); border-top: 1px solid var(--rule); font-weight: 600; }
.track-picker { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); grid-auto-rows: max-content; align-content: start; gap: 10px; max-height: 520px; overflow: auto; padding: 4px; }
.track-pick { position: relative; display: grid; border: 2px solid var(--rule); border-radius: var(--r2); background: var(--surface); cursor: pointer; overflow: hidden; }
.track-pick input { position: absolute; opacity: 0; pointer-events: none; }
.track-pick .shot { position: relative; aspect-ratio: 16 / 9; background: var(--surface-3); }
.track-pick .shot img { width: 100%; height: 100%; object-fit: cover; }
.track-pick .shot .outline { position: absolute; right: 6px; bottom: 6px; width: 60px; height: 44px; aspect-ratio: auto; background: #fff; filter: drop-shadow(0 1px 3px rgba(0, 0, 0, .7)); }
.track-pick .t { padding: 6px 8px 8px; font-size: var(--t-s); font-weight: 650; }
.track-pick .t small { display: block; color: var(--ink-3); font-weight: 500; }
.track-pick:has(input:checked) { border-color: var(--accent-mark); box-shadow: inset 0 0 0 1px var(--accent-mark); }
.track-pick:has(input:focus-visible) { outline: 3px solid var(--focus); outline-offset: 1px; }
.layout-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.layout-chips label { margin: 0; }
.layout-chips input { position: absolute; opacity: 0; pointer-events: none; }
.layout-chips span { display: inline-flex; align-items: center; gap: 6px; min-height: 34px; padding: 0 12px; border-radius: 999px; border: 1px solid var(--rule-strong); font-weight: 600; font-size: var(--t-s); cursor: pointer; background: var(--surface); }
.layout-chips input:checked + span { background: var(--ink); border-color: var(--ink); color: var(--paper); }
.layout-chips input:focus-visible + span { outline: 3px solid var(--focus); outline-offset: 2px; }

/* ------------------------------------------------------------------ race control */
.rc .page-head { margin-bottom: 22px; }
.page-head.split { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px 24px; flex-wrap: wrap; }
.page-head.split > div:first-child { display: grid; gap: 8px; max-width: 760px; }
.count { display: inline-grid; place-items: center; min-width: 26px; height: 22px; padding: 0 7px; border-radius: 999px; background: var(--surface-2); color: var(--ink-2); font-size: .75rem; font-weight: 750; font-stretch: var(--narrow); font-variant-numeric: tabular-nums; font-style: normal; vertical-align: middle; }
.chip-row { display: flex; flex-wrap: wrap; gap: 6px; }
.chip-row .chip { min-height: 30px; padding: 0 12px; }
.chip svg { width: 15px; height: 15px; }
.pad { padding: 14px; }
.status.fail { color: var(--danger); }
.status.fail::before { background: var(--danger); }
.status.live-ish::before { background: var(--done); }
.sheet td.time.l, .sheet th.l { text-align: left; }
.admin-link { display: inline-flex; align-items: center; gap: 6px; font-weight: 650; color: var(--accent-text); }
.admin-link svg { width: 16px; height: 16px; }
.danger-link { border: 0; background: none; padding: 0; font: inherit; color: var(--danger); font-weight: 650; cursor: pointer; text-align: left; }
.danger-link:hover { text-decoration: underline; }
.mono { font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace; font-size: .85rem; }

/* checklist */
.checklist { list-style: none; margin: 0 0 var(--gap); padding: 0; display: grid; gap: 8px; }
.checklist li { background: var(--surface); border: 1px solid var(--rule); border-left: 4px solid var(--s1); padding: 10px 14px; border-radius: var(--r2); display: flex; gap: 10px; justify-content: space-between; align-items: center; flex-wrap: wrap; }
.checklist li.warn { border-left-color: var(--soon); }
.checklist li.todo { border-left-color: var(--accent-mark); }
.checklist li a { font-weight: 700; color: var(--accent-text); white-space: nowrap; }
.checklist.slim { margin: 0; }
.checklist.slim li { padding: 6px 10px; font-size: var(--t-s); }

/* server cards */
.rc-servers { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 440px), 1fr)); gap: var(--gap); }
.server-card { background: var(--surface); border: 1px solid var(--rule); border-radius: var(--r3); overflow: hidden; display: flex; flex-direction: column; }
.server-card.is-live { border-color: color-mix(in oklab, var(--live) 45%, var(--rule)); }
.server-card .banner { position: relative; min-height: 190px; background: var(--header); color: #fff; isolation: isolate; display: flex; align-items: flex-end; }
.server-card .banner img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; }
.server-card .banner::before { content: ""; position: absolute; inset: 0; background: linear-gradient(0deg, rgba(5, 8, 12, .9) 8%, rgba(5, 8, 12, .25) 70%, rgba(5, 8, 12, .45)); z-index: -1; }
.server-card .banner::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 4px; background: linear-gradient(90deg, var(--stripe-a, var(--l1)) 0 33%, var(--accent) 33% 66%, var(--stripe-b, var(--l3)) 66%); }
.server-card.is-live .banner::after { background: var(--live); }
.server-card .banner .in { padding: 16px 18px 18px; display: grid; gap: 6px; width: 100%; }
.server-card .banner h2 { font-stretch: 112%; font-style: italic; font-size: 1.75rem; font-weight: 850; color: #fff; line-height: 1.05; }
.server-card .banner .status { color: #fff; }
.server-card .banner .status.off::before { background: rgba(255, 255, 255, .55); }
.server-card .engine { font-size: var(--t-xs); font-weight: 700; color: rgba(255, 255, 255, .75); background: rgba(255, 255, 255, .12); padding: 3px 8px; border-radius: var(--r1); }
.server-card .banner-track { margin: 0; color: rgba(255, 255, 255, .86); font-weight: 600; font-size: var(--t-s); }
.server-card .body { padding: 16px 18px 18px; display: grid; gap: 14px; }
.start-row { display: flex; gap: 8px; align-items: stretch; }
.start-row select { flex: 1 1 auto; min-width: 0; }
.server-card .ports { font-size: var(--t-xs); color: var(--ink-3); }
.server-card .ports b { color: var(--ink-2); font-stretch: var(--narrow); }
.log-details { border-top: 1px solid var(--rule); padding-top: 6px; }
.logbox { background: #0b0f14; color: #d6e2ec; font: 400 .78rem/1.5 ui-monospace, Menlo, Consolas, monospace; padding: 12px; border-radius: var(--r2); height: 300px; overflow: auto; white-space: pre-wrap; margin-top: 10px; }
.kv { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 6px 16px; margin: 0; font-size: .9375rem; }
.kv dt { color: var(--ink-2); font-weight: 600; }
.kv dd { margin: 0; min-width: 0; overflow-wrap: anywhere; }
.secret { font-stretch: var(--narrow); font-weight: 700; background: var(--surface-2); padding: 2px 8px; border-radius: var(--r1); letter-spacing: .02em; user-select: all; }
details > summary { cursor: pointer; font-weight: 650; padding: 6px 0; list-style-position: inside; }
details > summary::-webkit-details-marker { color: var(--ink-3); }

/* event rows (schedule, dashboard) */
.event-list { display: grid; gap: 10px; }
.event-row { display: grid; grid-template-columns: 112px minmax(0, 1fr) auto; gap: 14px; align-items: center; background: var(--surface); border: 1px solid var(--rule); border-radius: var(--r3); padding: 8px 12px 8px 8px; color: inherit; text-decoration: none; }
.event-row .thumb, .event-row img, .event-row .thumb-fallback { width: 112px; height: 63px; object-fit: cover; border-radius: var(--r2); background: var(--l3); display: grid; place-items: center; overflow: hidden; }
.thumb-fallback .outline { width: 70%; height: 70%; background: rgba(255, 255, 255, .9); }
.event-row .what { min-width: 0; display: grid; gap: 2px; }
.event-row .what b, .event-row .what a { font-weight: 750; font-size: 1.0625rem; text-decoration: none; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.event-row .what a:hover { text-decoration: underline; }
.event-row .what small { color: var(--ink-3); }
.event-row .btn-row { justify-content: flex-end; }
a.link-row:hover { border-color: var(--rule-strong); background: var(--surface-2); }
.when-chip { display: inline-flex; align-items: center; height: 28px; padding: 0 10px; border-radius: var(--r1); background: var(--surface-2); font-weight: 750; font-stretch: var(--narrow); font-variant-numeric: tabular-nums; white-space: nowrap; }
.progress { display: flex; gap: 3px; margin-top: 6px; }
.progress i { display: block; width: 18px; height: 5px; border-radius: 2px; background: var(--surface-3); }
.progress i.on { background: var(--accent-mark); }
@media (max-width: 720px) { .event-row { grid-template-columns: 72px minmax(0, 1fr); } .event-row .thumb, .event-row img, .event-row .thumb-fallback { width: 72px; height: 48px; } .event-row > .btn-row, .event-row > .status, .event-row > .when-chip { grid-column: 1 / -1; justify-content: flex-start; justify-self: start; } }

/* numbers and activity */
.stat-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1px; background: var(--rule); border: 1px solid var(--rule); border-radius: var(--r3); overflow: hidden; }
.stat-grid a { background: var(--surface); padding: 12px 14px; text-decoration: none; color: inherit; display: grid; gap: 2px; }
.stat-grid a:hover { background: var(--surface-2); }
.stat-grid b { font-size: 1.75rem; font-weight: 850; font-stretch: var(--narrow); font-variant-numeric: tabular-nums; line-height: 1.05; }
.stat-grid span { font-size: var(--t-xs); color: var(--ink-3); font-weight: 650; }
.activity { list-style: none; margin: 0; padding: 0; display: grid; }
.activity li { display: grid; grid-template-columns: 92px minmax(0, 1fr); gap: 10px; padding: 7px 0; border-top: 1px solid var(--rule); font-size: var(--t-s); }
.activity li:first-child { border-top: 0; }
.activity .when { color: var(--ink-3); font-stretch: var(--narrow); font-variant-numeric: tabular-nums; }

/* event cards (events list) */
.event-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); gap: 14px; }
.event-card { display: flex; flex-direction: column; background: var(--surface); border: 1px solid var(--rule); border-radius: var(--r3); overflow: visible; min-width: 0; }
.event-card.is-running { border-color: color-mix(in oklab, var(--live) 50%, var(--rule)); }
.event-card .pic { position: relative; display: block; aspect-ratio: 16 / 7; background: var(--l3); overflow: hidden; border-radius: var(--r3) var(--r3) 0 0; }
.event-card .pic .cover { width: 100%; height: 100%; object-fit: cover; display: grid; place-items: center; }
.event-card .pic .badge-live { position: absolute; left: 10px; top: 10px; }
.event-card .body { display: flex; flex-direction: column; gap: 8px; padding: 12px 14px 14px; flex: 1; }
.event-card h3 { font-size: 1.0625rem; line-height: 1.25; }
.event-card h3 a { color: inherit; text-decoration: none; }
.event-card h3 a:hover { text-decoration: underline; }
.event-card .meta { margin: -4px 0 0; color: var(--ink-2); font-size: var(--t-s); }
.event-card .tag svg { width: 12px; height: 12px; }
.event-card .actions { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-top: auto; padding-top: 4px; }
.car-strip { display: flex; flex-wrap: wrap; gap: 4px; align-items: center; }
.car-strip img { width: 48px; height: 27px; object-fit: cover; border-radius: var(--r1); background: var(--surface-3); }
.car-strip .more { font-size: var(--t-xs); font-weight: 700; color: var(--ink-3); padding: 0 4px; }
.more-menu { position: relative; }
.more-menu > summary { list-style: none; }
.more-menu > summary::-webkit-details-marker { display: none; }
.more-menu .menu { position: absolute; right: 0; top: calc(100% + 6px); z-index: 20; min-width: 180px; background: var(--surface); border: 1px solid var(--rule-strong); border-radius: var(--r2); box-shadow: 0 12px 32px rgba(0, 0, 0, .18); padding: 6px; display: grid; }
.more-menu .menu a, .more-menu .menu button { display: block; padding: 8px 10px; border-radius: var(--r1); text-decoration: none; font-size: var(--t-s); font-weight: 600; width: 100%; }
.more-menu .menu a:hover, .more-menu .menu button:hover { background: var(--surface-2); text-decoration: none; }
.starter-panel { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 16px 28px; align-items: center; padding: 22px 24px; border-radius: var(--r3); background: var(--header); color: #fff; position: relative; overflow: hidden; isolation: isolate; }
.starter-panel::after { content: ""; position: absolute; right: -40px; top: 0; bottom: 0; width: 180px; transform: skewX(-20deg); background: linear-gradient(90deg, var(--stripe-a, var(--l1)) 0 40%, var(--accent) 40% 75%, var(--stripe-b, var(--l3)) 75%); opacity: .85; z-index: -1; }
.starter-panel h2 { color: #fff; font-style: italic; font-stretch: 110%; }
.starter-panel p { color: rgba(255, 255, 255, .82); margin: 6px 0 0; max-width: 70ch; }
.starter-panel.slim { background: var(--surface); color: var(--ink); border: 1px solid var(--rule); }
.starter-panel.slim::after { opacity: .35; width: 110px; }
.starter-panel.slim h2 { color: var(--ink); font-size: var(--t-l); font-style: normal; }
.starter-panel.slim p { color: var(--ink-2); }
@media (max-width: 720px) { .starter-panel { grid-template-columns: 1fr; } .starter-panel::after { display: none; } }

/* event editor */
.editor { display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: var(--gap); align-items: start; }
.editor-main { min-width: 0; }
.editor-main fieldset { scroll-margin-top: 90px; }
.editor-side { position: sticky; top: 84px; display: grid; gap: 14px; }
.summary-card { background: var(--surface); border: 1px solid var(--rule); border-radius: var(--r3); overflow: hidden; }
.sum-pic { position: relative; aspect-ratio: 16 / 9; background: var(--header); display: grid; place-items: center; overflow: hidden; }
.sum-pic img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.sum-pic::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 4px; background: linear-gradient(90deg, var(--stripe-a, var(--l1)) 0 33%, var(--accent) 33% 66%, var(--stripe-b, var(--l3)) 66%); }
.sum-fallback { color: rgba(255, 255, 255, .7); font-weight: 700; padding: 12px; text-align: center; }
.sum-body { padding: 14px 16px; display: grid; gap: 6px; }
.sum-name { font-size: 1.25rem; font-weight: 850; font-style: italic; font-stretch: 108%; line-height: 1.15; overflow-wrap: anywhere; }
.sum-track { color: var(--ink-2); font-weight: 600; font-size: var(--t-s); }
.sum-facts { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 4px 14px; margin: 6px 0 4px; font-size: var(--t-s); }
.sum-facts dt { color: var(--ink-3); font-weight: 650; }
.sum-facts dd { margin: 0; font-weight: 650; font-stretch: var(--narrow); font-variant-numeric: tabular-nums; }
.sum-facts dd.over { color: var(--danger); }
.sum-actions { display: grid; gap: 8px; padding: 0 16px 16px; }
.editor-side > .sum-actions { padding: 0; }
.jump { display: grid; background: var(--surface); border: 1px solid var(--rule); border-radius: var(--r3); padding: 6px; }
.jump a { padding: 7px 10px; border-radius: var(--r1); text-decoration: none; font-weight: 600; font-size: var(--t-s); color: var(--ink-2); }
.jump a:hover { background: var(--surface-2); color: var(--ink); }
.mobile-only { display: none; }
@media (max-width: 1000px) {
  .editor { grid-template-columns: minmax(0, 1fr); }
  .editor-side { position: static; order: -1; }
  .editor-side .jump, .editor-side .sum-actions { display: none; }
  .summary-card { display: grid; grid-template-columns: 200px minmax(0, 1fr); }
  .mobile-only { display: flex; }
}
@media (max-width: 560px) { .summary-card { grid-template-columns: 1fr; } }
.field { display: grid; align-content: start; min-width: 0; }
.field + .field { margin-top: 14px; }
.fields .field + .field { margin-top: 0; }
.fields.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.fields .wide { grid-column: span 2; }
@media (max-width: 560px) { .fields .wide { grid-column: auto; } .fields.two { grid-template-columns: 1fr; } }
.with-unit { display: flex; align-items: stretch; }
.with-unit input { min-width: 0; flex: 1 1 auto; border-top-right-radius: 0; border-bottom-right-radius: 0; }
.with-unit .unit { display: grid; place-items: center; padding: 0 10px; border: 1px solid var(--rule-strong); border-left: 0; border-radius: 0 var(--r2) var(--r2) 0; background: var(--surface-2); color: var(--ink-2); font-size: var(--t-s); font-weight: 650; white-space: nowrap; }
.with-unit input:only-child { border-radius: var(--r2); }
.checks { display: grid; gap: 12px; }
.checks.cols { grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); gap: 14px 22px; }
.toggle { display: inline-flex; align-items: flex-start; gap: 12px; cursor: pointer; font-weight: 650; }
.toggle input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.toggle .knob { position: relative; flex: none; width: 42px; height: 24px; border-radius: 999px; background: var(--surface-3); border: 1px solid var(--rule-strong); transition: background-color .15s; margin-top: 1px; }
.toggle .knob::after { content: ""; position: absolute; top: 2px; left: 2px; width: 18px; height: 18px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, .3); transition: transform .15s; }
.toggle input:checked + .knob { background: var(--accent-mark); border-color: var(--accent-mark); }
.toggle input:checked + .knob::after { transform: translateX(18px); }
.toggle input:focus-visible + .knob { outline: 3px solid var(--focus); outline-offset: 2px; }
.toggle .txt { display: block; }
.segmented-radio { display: inline-flex; flex-wrap: wrap; padding: 3px; gap: 2px; background: var(--surface-2); border-radius: var(--r2); }
.segmented-radio label { margin: 0; position: relative; }
.segmented-radio input { position: absolute; opacity: 0; pointer-events: none; }
.segmented-radio span { display: block; padding: 7px 14px; border-radius: var(--r1); font-size: var(--t-s); font-weight: 650; color: var(--ink-2); cursor: pointer; }
.segmented-radio input:checked + span { background: var(--surface); color: var(--ink); box-shadow: 0 1px 2px rgba(0, 0, 0, .14); }
.segmented-radio input:focus-visible + span { outline: 3px solid var(--focus); outline-offset: 1px; }
.session-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 210px), 1fr)); gap: 12px; }
.session-card { display: grid; gap: 12px; align-content: start; padding: 14px; border-radius: var(--r2); background: var(--surface-2); }
.session-card:has(.toggle input:not(:checked)) > :not(.toggle) { opacity: .5; }
.sub-details { border: 1px solid var(--rule); border-radius: var(--r2); padding: 6px 14px 14px; }
.sub-details > summary { padding: 8px 0; }
.sub-details:not([open]) { padding-bottom: 0; }
.sub-block { margin-top: 16px; display: grid; gap: 8px; }

/* pickers */
.picker-tools.flat { position: static; padding: 0 0 10px; border: 0; background: none; }
.pick-fallback { display: grid; place-items: center; aspect-ratio: 16 / 9; background: var(--surface-3); font-weight: 900; font-style: italic; font-size: 1.4rem; color: var(--ink-3); }
.track-field { display: grid; gap: 10px; }
.layout-row { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 12px; }
.layout-row .label { margin: 10px 0 0; }
.track-pick .shot .tag { position: absolute; left: 6px; top: 6px; }

/* schedule */
.schedule-form h2 { margin-bottom: 12px; }

/* championship rounds */
.round-list { display: grid; gap: 8px; }
.round-row { display: grid; grid-template-columns: 54px 112px minmax(0, 1fr) auto auto; gap: 14px; align-items: center; background: var(--surface); border: 1px solid var(--rule); border-radius: var(--r3); padding: 8px 12px 8px 8px; }
.round-no { display: grid; place-items: center; height: 44px; border-radius: var(--r2); background: var(--ink); color: var(--paper); font-weight: 900; font-style: italic; font-stretch: 112%; font-size: 1.15rem; }
.round-row .thumb, .round-row .thumb-fallback { width: 112px; height: 63px; object-fit: cover; border-radius: var(--r2); background: var(--l3); display: grid; place-items: center; overflow: hidden; }
.round-edit { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr) auto; gap: 8px; align-items: end; }
.round-edit label { font-size: var(--t-xs); color: var(--ink-3); margin-bottom: 3px; }
.round-state { min-width: 120px; }
.add-round { display: grid; grid-template-columns: 54px minmax(0, 1fr) minmax(0, 1fr) auto; gap: 12px; align-items: center; margin-top: 10px; padding: 8px 12px 8px 8px; border: 1px dashed var(--rule-strong); border-radius: var(--r3); }
.add-round .round-no { background: var(--surface-3); color: var(--ink-3); }
@media (max-width: 900px) {
  .round-row { grid-template-columns: 44px minmax(0, 1fr) auto; }
  .round-row .thumb, .round-row .thumb-fallback { display: none; }
  .round-edit { grid-column: 2 / -1; grid-row: 2; grid-template-columns: 1fr; }
  .round-state { min-width: 0; }
  .add-round { grid-template-columns: 44px minmax(0, 1fr); }
  .add-round > :nth-child(n+4) { grid-column: 2; }
}
.plain-rows { list-style: none; margin: 0; padding: 0; display: grid; background: var(--surface); border: 1px solid var(--rule); border-radius: var(--r3); }
.plain-rows li { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 10px 14px; border-top: 1px solid var(--rule); }
.plain-rows li:first-child { border-top: 0; }
.plain-rows .when { color: var(--ink-3); font-stretch: var(--narrow); font-variant-numeric: tabular-nums; font-weight: 650; }

/* content library */
.pack-status { display: grid; gap: 2px; padding: 12px 16px; border-radius: var(--r3); background: var(--surface); border: 1px solid var(--rule); border-left: 5px solid var(--accent-mark); text-decoration: none; color: inherit; min-width: 220px; }
.pack-status:hover { border-color: var(--rule-strong); }
.pack-status .label { margin: 0; color: var(--ink-3); font-size: var(--t-xs); }
.pack-status b { font-size: 1.15rem; font-stretch: var(--narrow); }
.pack-status small { color: var(--ink-2); }
.dropzone { display: grid; justify-items: center; gap: 6px; text-align: center; padding: 22px 18px; border: 2px dashed var(--rule-strong); border-radius: var(--r3); background: var(--surface-2); cursor: pointer; margin: var(--gap-s) 0 0; font-weight: 500; }
.dropzone:hover, .dropzone:focus-within { border-color: var(--accent-mark); background: var(--accent-wash); }
.dropzone.has-file { border-style: solid; border-color: var(--accent-mark); }
.dropzone svg { width: 28px; height: 28px; color: var(--accent-text); }
.dropzone b { font-size: 1.0625rem; }
.dropzone span { color: var(--ink-3); font-size: var(--t-s); max-width: 44ch; }
.dropzone input[type="file"] { max-width: 100%; margin-top: 6px; }
.empty.slim { padding: 12px 14px; }
.filter-bar { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-bottom: 14px; }
.filter-bar input[type="search"] { flex: 1 1 240px; width: auto; }
.filter-bar select { width: auto; }
.seg-links { display: inline-flex; padding: 3px; gap: 2px; background: var(--surface-2); border-radius: var(--r2); }
.seg-links a { display: inline-flex; align-items: center; gap: 6px; padding: 7px 14px; border-radius: var(--r1); text-decoration: none; font-weight: 650; font-size: var(--t-s); color: var(--ink-2); }
.seg-links a[aria-current="page"] { background: var(--surface); color: var(--ink); box-shadow: 0 1px 2px rgba(0, 0, 0, .14); }
.lib-list { display: grid; gap: 8px; }
.lib-row { display: grid; grid-template-columns: 128px minmax(0, 1fr) auto; grid-template-areas: "pic main share" "pic tools tools"; gap: 6px 16px; align-items: start; background: var(--surface); border: 1px solid var(--rule); border-radius: var(--r3); padding: 10px 14px 10px 10px; scroll-margin-top: 90px; }
.lib-row:target { border-color: var(--accent-mark); box-shadow: 0 0 0 3px var(--accent-wash); }
.lib-row .pic { grid-area: pic; display: grid; place-items: center; width: 128px; height: 72px; border-radius: var(--r2); overflow: hidden; background: var(--l3); }
.lib-row .pic img { width: 100%; height: 100%; object-fit: cover; }
.lib-row .main { grid-area: main; min-width: 0; display: grid; gap: 4px; }
.lib-row .title-line { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; }
.lib-row .title-line a { color: inherit; text-decoration: none; font-size: 1.0625rem; }
.lib-row .title-line a:hover { text-decoration: underline; }
.lib-row .meta { color: var(--ink-3); }
.lib-row .meta code { background: none; padding: 0; font-size: .82rem; }
.lib-row .cluster { gap: 6px; }
.lib-row .share { grid-area: share; }
.lib-row .tools { grid-area: tools; display: flex; flex-wrap: wrap; gap: 6px 18px; }
.lib-row .tools:empty { display: none; }
.tool > summary { display: inline-flex; align-items: center; gap: 6px; font-size: var(--t-s); color: var(--accent-text); list-style: none; }
.tool > summary::-webkit-details-marker { display: none; }
.tool > summary svg { width: 16px; height: 16px; }
.tool .btn { white-space: normal; text-align: left; }
.tool[open] { flex-basis: 100%; background: var(--surface-2); border-radius: var(--r2); padding: 4px 14px 14px; }
.share-chip { display: inline-flex; align-items: center; gap: 6px; height: 26px; padding: 0 10px; border-radius: 999px; font-size: var(--t-xs); font-weight: 750; white-space: nowrap; }
.share-chip svg { width: 14px; height: 14px; }
.share-chip.official { background: var(--surface-2); color: var(--ink-3); }
.share-chip.shared { background: color-mix(in oklab, var(--pb) 16%, var(--surface)); color: var(--pb-text); }
.share-chip.linked { background: var(--accent-wash); color: var(--accent-text); }
.share-chip.none { background: color-mix(in oklab, var(--soon) 22%, var(--surface)); color: var(--ink); }
@media (max-width: 640px) { .lib-row { grid-template-columns: 84px minmax(0, 1fr); grid-template-areas: "pic main" "share share" "tools tools"; } .lib-row .pic { width: 84px; height: 48px; } }

/* add a mod: link, upload, import folder */
#add { scroll-margin-top: 90px; }
.add-grid { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr) minmax(0, 1fr); gap: var(--gap); align-items: start; }
@media (max-width: 1100px) { .add-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .add-grid .add-link { grid-column: 1 / -1; } }
@media (max-width: 700px) { .add-grid { grid-template-columns: minmax(0, 1fr); } }
.add-grid h3 { display: flex; align-items: center; gap: 8px; }
.add-grid h3 svg { width: 20px; height: 20px; color: var(--accent-text); flex: none; }
.add-link { border-color: var(--accent-mark); box-shadow: 0 0 0 3px var(--accent-wash); }
.hint-list { margin: 6px 0 0; padding-left: 18px; display: grid; gap: 6px; font-size: var(--t-s); color: var(--ink-2); }
.fetch-jobs { margin-top: 16px; background: var(--surface); border: 1px solid var(--rule); border-radius: var(--r3); padding: 14px 16px; }
.fetch-jobs h3 { margin-bottom: 10px; }
.fetch-jobs ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.fetch-job { display: grid; gap: 6px; }
.fj-top { display: flex; justify-content: space-between; gap: 12px; align-items: baseline; }
.fj-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.fj-state { font-size: var(--t-xs); font-weight: 750; color: var(--ink-3); white-space: nowrap; }
.is-done .fj-state { color: var(--pb-text); }
.is-failed .fj-state { color: var(--danger); }
.fetch-bar { height: 8px; border-radius: 999px; background: var(--surface-3); overflow: hidden; }
.fetch-bar i { display: block; height: 100%; width: var(--p, 0%); background: var(--accent-mark); border-radius: inherit; transition: width .4s ease; }
.is-done .fetch-bar i { background: var(--done); }
.is-failed .fetch-bar i, .is-cancelled .fetch-bar i { background: var(--danger); opacity: .35; }
.fetch-bar.indeterminate i { width: 30%; animation: fetch-slide 1.2s ease-in-out infinite; }
@keyframes fetch-slide { from { transform: translateX(-100%); } to { transform: translateX(340%); } }
@media (prefers-reduced-motion: reduce) { .fetch-bar.indeterminate i { animation: none; width: 100%; opacity: .5; } }
.fj-meta { display: flex; justify-content: space-between; gap: 12px; align-items: center; font-size: var(--t-s); color: var(--ink-2); }
.fj-meta .fj-msg { min-width: 0; overflow-wrap: anywhere; }
.fj-meta a { font-weight: 700; color: var(--accent-text); white-space: nowrap; }

/* drivers */
.add-driver h2 { margin-bottom: 12px; }
.driver-admin { display: grid; gap: 8px; }
.driver-edit { display: grid; grid-template-columns: minmax(240px, 1fr) minmax(0, 1.6fr); gap: 10px 18px; align-items: center; background: var(--surface); border: 1px solid var(--rule); border-radius: var(--r3); padding: 10px 14px; }
.driver-edit .who { display: flex; gap: 12px; align-items: center; min-width: 0; }
.driver-edit .name { font-weight: 750; text-decoration: none; }
.driver-edit .name:hover { text-decoration: underline; }
.driver-edit .meta { display: flex; align-items: center; gap: 6px; color: var(--ink-3); flex-wrap: wrap; }
.driver-edit .meta code { background: none; padding: 0; font-size: .8rem; }
.driver-edit .inputs { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.driver-edit .inputs input[type="text"] { flex: 1 1 130px; width: auto; }
.small-input { width: 80px !important; flex: none; }
.num-board.small { min-width: 44px; height: 36px; font-size: 1.1rem; border-width: 2px; padding: 0 6px; }
.section-head input[type="search"] { width: auto; flex: 0 1 300px; }
@media (max-width: 900px) { .driver-edit { grid-template-columns: 1fr; } }

/* config files */
.code-file { margin-top: 18px; }
.code-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 8px 12px; background: var(--surface-2); border: 1px solid var(--rule); border-bottom: 0; border-radius: var(--r2) var(--r2) 0 0; }
pre.code { margin: 0; background: #0b0f14; color: #d6e2ec; font: 400 .8rem/1.55 ui-monospace, Menlo, Consolas, monospace; padding: 14px; border-radius: 0 0 var(--r2) var(--r2); overflow: auto; max-height: 520px; }

/* appearance editor */
.look-editor .editor-side { top: 84px; }
.livery-options { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.livery-option { position: relative; display: grid; gap: 10px; padding: 12px; border: 2px solid var(--rule); border-radius: var(--r2); cursor: pointer; background: var(--surface); margin: 0; font-weight: 650; font-size: var(--t-s); }
.livery-option input { position: absolute; opacity: 0; pointer-events: none; }
.livery-option .sw { display: grid; grid-template-columns: 1fr 1fr 1fr; height: 34px; border-radius: var(--r1); overflow: hidden; transform: skewX(-14deg); box-shadow: 0 0 0 1px rgba(0, 0, 0, .12); }
.livery-option .sw i { display: block; }
.livery-option .sw i:nth-child(1) { background: var(--s1, #ccc); }
.livery-option .sw i:nth-child(2) { background: var(--s2, #999); }
.livery-option .sw i:nth-child(3) { background: var(--s3, #333); }
.livery-option .sw[data-accent="0"] i:nth-child(1), .livery-option .sw[data-accent="1"] i:nth-child(2), .livery-option .sw[data-accent="2"] i:nth-child(3) { box-shadow: inset 0 -6px 0 rgba(255, 255, 255, .55); }
.livery-option:has(input:checked) { border-color: var(--accent-mark); background: var(--accent-wash); }
.livery-option:has(input:focus-visible) { outline: 3px solid var(--focus); outline-offset: 2px; }
.paint-row { display: flex; flex-wrap: wrap; gap: 14px 22px; align-items: flex-start; }
.paint { display: grid; gap: 6px; justify-items: start; }
.paint label { margin: 0; }
.paint input[type="color"] { width: 76px; height: 48px; }
.paint-row .hint { flex: 1 1 240px; margin: 0; align-self: center; }
.radio-mini { display: inline-flex; gap: 6px; align-items: center; font-size: var(--t-xs); font-weight: 650; color: var(--ink-2); cursor: pointer; }
.radio-mini input { width: 15px; height: 15px; margin: 0; }
.row-fields { display: flex; flex-wrap: wrap; gap: 8px; }
.row-fields select { width: auto; flex: 1 1 180px; }
.upload-row { display: flex; flex-wrap: wrap; gap: 14px 20px; align-items: center; }
.upload-row .current { display: grid; place-items: center; min-width: 120px; height: 64px; padding: 8px 12px; border-radius: var(--r2); background: var(--header); }
.upload-row .current img { max-height: 48px; max-width: 220px; }
.upload-row .current.wide { width: 260px; height: auto; padding: 0; overflow: hidden; }
.upload-row .current.wide img { max-height: none; max-width: 100%; width: 100%; aspect-ratio: 16 / 7; object-fit: cover; }
.hero-choices { display: grid; gap: 10px; margin-top: 4px; }
.hero-choice { display: grid; gap: 8px; padding: 12px 14px; border: 1px solid var(--rule); border-radius: var(--r2); }
.hero-choice:has(input[type="radio"]:checked) { border-color: var(--accent-mark); background: var(--accent-wash); }
.hero-choice select, .hero-choice input[type="file"] { margin-left: 28px; max-width: calc(100% - 28px); }
.hero-choice > .hint { margin: 0 0 0 28px; }
.section-order { list-style: none; margin: 6px 0 0; padding: 0; display: grid; gap: 6px; counter-reset: sec; }
.section-order li { counter-increment: sec; display: grid; grid-template-columns: 26px minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 8px 10px; border: 1px solid var(--rule); border-radius: var(--r2); background: var(--surface); }
.section-order li::before { content: counter(sec); font-weight: 850; font-style: italic; color: var(--ink-3); text-align: center; }
.section-order li:has(input[type="checkbox"]:not(:checked)) .check span { color: var(--ink-3); text-decoration: line-through; }
.order-btns { display: flex; gap: 4px; }
.icon-btn.small { width: 30px; height: 30px; border: 1px solid var(--rule-strong); font-weight: 800; }
.look-preview { border: 1px solid var(--rule); border-radius: var(--r3); overflow: hidden; background: var(--paper); font-size: 12px; }
.lp-head { display: flex; align-items: center; gap: 8px; padding: 10px 12px; background: var(--header); color: #fff; }
.lp-mark { display: inline-flex; align-items: center; height: 22px; padding: 0 8px 0 12px; transform: skewX(-14deg); background: var(--accent); color: var(--on-accent); border-radius: var(--r1); box-shadow: -5px 0 0 0 var(--stripe-a, var(--l1)); }
.lp-mark b { transform: skewX(14deg); font-style: italic; font-weight: 900; font-size: 12px; }
.lp-name { font-weight: 800; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lp-nav { margin-left: auto; display: flex; gap: 6px; }
.lp-nav i { display: block; width: 22px; height: 5px; border-radius: 3px; background: rgba(255, 255, 255, .35); }
.lp-band { display: grid; grid-template-columns: 1fr 1fr 1fr; height: 5px; }
.lp-band span:nth-child(1) { background: var(--stripe-a, var(--l1)); }
.lp-band span:nth-child(2) { background: var(--accent); }
.lp-band span:nth-child(3) { background: var(--stripe-b, var(--l3)); }
.lp-hero { position: relative; display: grid; gap: 6px; justify-items: start; margin: 10px; padding: 14px; border-radius: var(--r3); background: linear-gradient(120deg, #0e141b, #1d2a36); color: #fff; overflow: hidden; isolation: isolate; }
.lp-kicker { font-weight: 800; font-size: 10px; background: rgba(255, 255, 255, .16); padding: 2px 6px; border-radius: var(--r1); }
.lp-title { font-size: 26px; font-weight: 900; font-style: italic; font-stretch: 115%; line-height: 1; }
.lp-btns { display: flex; gap: 6px; }
.lp-btn { display: inline-flex; align-items: center; height: 24px; padding: 0 10px; border-radius: var(--r2); background: var(--accent); color: var(--on-accent); font-weight: 800; }
.lp-btn.ghost { background: rgba(255, 255, 255, .12); color: #fff; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .3); }
.lp-stripes { position: absolute; right: -14px; top: 0; bottom: 0; width: 70px; display: grid; grid-template-columns: 1fr 1fr 1fr; transform: skewX(-18deg); z-index: -1; }
.lp-stripes i:nth-child(1) { background: var(--stripe-a, var(--l1)); }
.lp-stripes i:nth-child(2) { background: var(--accent); }
.lp-stripes i:nth-child(3) { background: var(--stripe-b, var(--l3)); }
.lp-rows { margin: 0 10px 10px; display: grid; gap: 4px; }
.lp-row { display: grid; grid-template-columns: 24px minmax(0, 1fr) auto; gap: 8px; align-items: center; padding: 6px 8px; background: var(--surface); border-radius: var(--r2); border: 1px solid var(--rule); }
.lp-plate { display: grid; place-items: center; height: 18px; border-radius: var(--r1); background: var(--surface-3); font-weight: 900; }
.lp-plate.p1 { background: var(--accent); color: var(--on-accent); }
.lp-line { height: 6px; border-radius: 3px; background: var(--surface-3); width: 80%; }
.lp-line.short { width: 55%; }
.lp-time { font-weight: 800; font-stretch: var(--narrow); font-variant-numeric: tabular-nums; }
.lp-row:first-child .lp-time { color: var(--fastest-text); }

/* ------------------------------------------------------------------ steps (join page) */
.steps { list-style: none; counter-reset: step; margin: 0; padding: 0; display: grid; gap: 14px; }
.steps > li { counter-increment: step; display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 14px; align-items: start; }
.steps > li::before { content: counter(step); display: grid; place-items: center; width: 44px; height: 44px; border-radius: var(--r2); background: var(--ink); color: var(--paper); font-weight: 900; font-style: italic; font-stretch: 112%; font-size: 1.25rem; }
.steps > li > div { padding-top: 2px; }
.steps > li b { display: block; font-size: 1.0625rem; margin-bottom: 2px; }
.download-all { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 18px 28px; align-items: center; padding: 24px 26px; border-radius: var(--r3); background: var(--header); color: #fff; position: relative; overflow: hidden; isolation: isolate; }
.download-all::after { content: ""; position: absolute; right: -40px; top: 0; bottom: 0; width: 220px; transform: skewX(-20deg); background: linear-gradient(90deg, var(--stripe-a, var(--l1)) 0 40%, var(--accent) 40% 75%, var(--stripe-b, var(--l3)) 75%); opacity: .9; z-index: -1; }
.download-all h2 { font-size: var(--t-2xl); font-stretch: 112%; font-style: italic; font-weight: 850; color: #fff; }
.download-all p { color: rgba(255, 255, 255, .82); margin: 6px 0 0; max-width: 62ch; }
.download-all .pack-action { position: relative; }
.download-all.locked { background: var(--surface-2); color: var(--ink); border: 1px solid var(--rule); }
.download-all.locked h2 { color: var(--ink); font-size: var(--t-xl); }
.download-all.locked p { color: var(--ink-2); }
.download-all.locked::after { opacity: .5; }
.pack-strip { list-style: none; margin: 16px 0 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.pack-strip li { width: 76px; height: 44px; border-radius: var(--r1); overflow: hidden; background: rgba(255, 255, 255, .1); box-shadow: 0 0 0 1px rgba(255, 255, 255, .16); display: grid; place-items: center; font-size: var(--t-xs); font-weight: 700; color: rgba(255, 255, 255, .8); }
.pack-strip img { width: 100%; height: 100%; object-fit: cover; display: block; }
@media (max-width: 760px) { .download-all { grid-template-columns: 1fr; padding: 20px; } .download-all::after { display: none; } .download-all .btn.big { width: 100%; justify-content: center; } }
.next-starts { list-style: none; margin: 8px 0 0; padding: 0; display: grid; gap: 2px; }
.next-starts li { display: grid; grid-template-columns: 150px minmax(0, 1fr) auto; gap: 12px; align-items: baseline; padding: 8px 0; border-top: 1px solid var(--rule); }
.next-starts li:first-child { border-top: 0; }
.next-starts .when { font-weight: 700; font-stretch: var(--narrow); font-variant-numeric: tabular-nums; }
.next-starts a { display: inline-flex; gap: 6px; align-items: center; white-space: nowrap; }
.next-starts a svg { width: 16px; height: 16px; }
@media (max-width: 520px) { .next-starts li { grid-template-columns: 1fr auto; } .next-starts .what { grid-column: 1 / -1; grid-row: 2; } }
.mod-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 14px; }
.mod-card { display: flex; flex-direction: column; background: var(--surface); border: 1px solid var(--rule); border-radius: var(--r3); overflow: hidden; min-width: 0; }
.mod-card .pic { position: relative; display: block; aspect-ratio: 16 / 9; background: var(--l3); overflow: hidden; }
.mod-card .pic img, .mod-card .pic .thumb-fallback { width: 100%; height: 100%; object-fit: cover; display: block; }
.mod-card .in-pack { position: absolute; left: 8px; top: 8px; background: var(--accent); color: var(--on-accent); font-size: var(--t-xs); font-weight: 750; padding: 3px 8px; border-radius: var(--r1); }
.mod-card .body { display: flex; flex-direction: column; gap: 4px; padding: 12px 14px 14px; flex: 1; min-width: 0; }
.mod-card .kind { font-size: var(--t-xs); font-weight: 650; color: var(--ink-3); }
.mod-card h3 { font-size: var(--t-m); line-height: 1.25; }
.mod-card h3 a { text-decoration: none; color: inherit; }
.mod-card h3 a:hover { text-decoration: underline; }
.mod-card .notes { font-size: var(--t-xs); color: var(--ink-3); margin: 2px 0 0; }
.mod-card .btn-row { margin-top: auto; padding-top: 10px; }
.copy-field { display: flex; gap: 6px; align-items: center; }
.copy-field .secret { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; padding: 8px 10px; }

/* ------------------------------------------------------------------ footer */
.foot { border-top: 1px solid var(--rule); padding: 28px 0 44px; color: var(--ink-2); font-size: var(--t-s); }
.foot .spread { align-items: flex-start; }
.foot nav { display: flex; gap: 16px; flex-wrap: wrap; }
.foot a { color: var(--ink-2); text-decoration: none; font-weight: 600; }
.foot a:hover { color: var(--ink); }

/* ------------------------------------------------------------------ accessibility & media */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; scroll-behavior: auto !important; }
}
@media (forced-colors: active) {
  .outline { background: CanvasText; }
  .plate, .btn, .chip { border: 1px solid CanvasText; }
}
@media print {
  .masthead, .livery-band, .foot, .btn, .filters, .prefs { display: none !important; }
  body { background: #fff; color: #000; }
  .hero { color: #000; background: none; min-height: 0; }
  .hero::before, .hero-media { display: none; }
}

/* home: season box */
.season-rounds { margin-top: 12px; }
.next-round { margin-top: 14px; }
.team-list { list-style: none; margin: 10px 0 0; padding: 0; display: grid; gap: 1px; background: var(--rule); border: 1px solid var(--rule); border-radius: var(--r2); overflow: hidden; }
.team-list li { display: flex; justify-content: space-between; align-items: center; gap: 10px; background: var(--surface); padding: 8px 12px; }
.team-list li > span:first-child { display: flex; align-items: center; gap: 10px; }
.min0 { min-width: 0; }

/* ------------------------------------------------------------------ page pieces */
.section-tight { margin-top: 18px; }
.section-note { margin-top: 10px; }
.h-small { font-size: var(--t-l); margin-bottom: 10px; }
.page-crumbs { display: flex; gap: 8px; font-size: var(--t-s); color: var(--ink-2); }
.page-crumbs a { font-weight: 600; text-decoration: none; }
.page-crumbs a:hover { color: var(--accent-text); }
.page-crumbs span + span::before { content: "/"; margin-right: 8px; color: var(--ink-3); }
.pre-line { white-space: pre-line; }
.narrow-text { max-width: 760px; }
.plain-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.plain-list li { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.label-s { display: block; font-size: var(--t-xs); font-weight: 650; color: var(--ink-3); margin-bottom: 6px; }
.thumb-fallback { display: block; background: linear-gradient(135deg, var(--l3), color-mix(in oklab, var(--l3) 55%, #000)); }
.more-link { font-weight: 650; font-size: var(--t-s); color: var(--accent-text); text-decoration: none; }
.more-link:hover { text-decoration: underline; }
.show-s, .driver-cell .team.show-s { display: none; }
@media (max-width: 720px) { .show-s, .driver-cell .team.show-s { display: block; } }

/* result page */
.result-outline { width: 150px; height: 108px; aspect-ratio: auto; }
.result-podium { max-width: 760px; margin-bottom: 8px; }
.result-podium .step img { aspect-ratio: 16 / 8; }
.lap-panel { padding: 0; }
.lap-panel > summary { padding: 12px 16px; list-style: none; }
.lap-panel > summary::-webkit-details-marker { display: none; }
.lap-panel[open] > summary { border-bottom: 1px solid var(--rule); }
.lap-panel .sheet-wrap { border: 0; border-radius: 0 0 var(--r3) var(--r3); }
.lap-sum { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.lap-panel.me { box-shadow: inset 4px 0 0 var(--accent); }
.legend i.series-other { background: var(--s-other); }
@media (max-width: 720px) { .result-outline { display: none; } }

/* standings */
.rules-line { display: flex; flex-wrap: wrap; gap: 8px; }
.champ-block { margin-bottom: var(--gap-l); }
.champ-block.archived { opacity: .85; }
.round-strip { display: grid; gap: 6px; align-content: start; }
.round-chip { display: grid; grid-template-columns: 52px minmax(0, 1fr); gap: 12px; align-items: center; background: var(--surface); border: 1px solid var(--rule); border-radius: var(--r2); padding: 8px 12px; font-size: var(--t-s); }
.round-chip .outline { width: 52px; background: var(--ink-3); }
.round-chip.done .outline { background: var(--accent-mark); }
.round-chip b { font-stretch: var(--narrow); margin-right: 6px; }
.calendar { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 14px; }
.round-card { background: var(--surface); border: 1px solid var(--rule); border-radius: var(--r3); overflow: hidden; display: grid; grid-template-rows: auto 1fr; }
.round-card .shot { position: relative; aspect-ratio: 16 / 8; background: var(--surface-3); overflow: hidden; }
.round-card .shot img { width: 100%; height: 100%; object-fit: cover; }
.round-card:not(.done) .shot img { filter: grayscale(.4) brightness(.9); }
.round-card .round-no { position: absolute; left: 10px; top: 10px; background: var(--ink); color: var(--paper); font-weight: 900; font-style: italic; font-stretch: 112%; padding: 2px 10px; border-radius: var(--r1); }
.round-card.done .round-no { background: var(--accent); color: var(--on-accent); }
.round-card .body { padding: 12px 14px 14px; display: grid; gap: 8px; align-content: start; }
.round-card h3 { font-size: 1.0625rem; }
.round-card .winner { display: flex; align-items: center; gap: 8px; margin: 0; }
.sheet.standings td.pts .sub { font-size: .75rem; font-weight: 600; color: var(--ink-3); }

/* records */
.records-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); gap: 16px; }
.record-track { background: var(--surface); border: 1px solid var(--rule); border-radius: var(--r3); overflow: hidden; }
.record-track .head { display: grid; grid-template-columns: 64px minmax(0, 1fr) auto; gap: 14px; align-items: center; padding: 14px; text-decoration: none; color: inherit; border-bottom: 1px solid var(--rule); }
.record-track .head:hover { background: color-mix(in oklab, var(--surface-2) 50%, var(--surface)); }
.record-track .head .outline { width: 64px; }
.record-track .head .what { display: grid; min-width: 0; }
.record-track .head b { font-size: 1.0625rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.record-track .head small { color: var(--ink-3); }
.record-track .head .time { font-stretch: var(--narrow); font-weight: 800; font-size: 1.25rem; color: var(--fastest-text); font-variant-numeric: tabular-nums; }
.combo-list { list-style: none; margin: 0; padding: 4px 0; }
.combo-list a { display: grid; grid-template-columns: 56px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 6px 14px; text-decoration: none; color: inherit; }
.combo-list a:hover { background: color-mix(in oklab, var(--surface-2) 50%, var(--surface)); }
.combo-list img { width: 56px; height: 32px; object-fit: cover; border-radius: var(--r1); }
.combo-list .what { display: grid; min-width: 0; font-size: var(--t-s); }
.combo-list .what b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.combo-list .what small { color: var(--ink-3); }
.combo-list .more-row a { display: block; font-size: var(--t-s); color: var(--accent-text); font-weight: 650; padding: 8px 14px; }
.board-hero { position: relative; border-radius: var(--r3); overflow: hidden; background: var(--header); color: #fff; min-height: 220px; display: flex; align-items: flex-end; isolation: isolate; }
.board-hero > img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; }
.board-hero::before { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, rgba(5, 8, 12, .86), rgba(5, 8, 12, .35)); }
.board-hero .in { padding: 26px; display: grid; gap: 8px; max-width: 70%; }
.board-hero h1 { font-stretch: var(--wide); font-style: italic; font-weight: 850; font-size: clamp(2rem, 4.4vw, 3.2rem); }
.board-hero p { color: rgba(255, 255, 255, .84); margin: 0; }
.board-hero .crumbs { display: flex; gap: 8px; font-size: var(--t-s); }
.board-hero .crumbs a { color: rgba(255, 255, 255, .86); text-decoration: none; font-weight: 600; }
.board-hero .crumbs span + span::before { content: "/"; margin-right: 8px; opacity: .6; }
.board-hero > .outline { position: absolute; right: 24px; bottom: 20px; width: 170px; height: 120px; aspect-ratio: auto; opacity: .95; }
@media (max-width: 720px) { .board-hero .in { max-width: none; } .board-hero > .outline { width: 90px; height: 64px; top: 16px; bottom: auto; } }
.car-filter { display: grid; gap: 1px; background: var(--rule); border: 1px solid var(--rule); border-radius: var(--r3); overflow: hidden; }
.car-filter-row { display: grid; grid-template-columns: 56px minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 8px 12px; background: var(--surface); text-decoration: none; color: inherit; font-size: var(--t-s); }
.car-filter-row:first-child { grid-template-columns: minmax(0, 1fr); }
.car-filter-row:hover { background: color-mix(in oklab, var(--surface-2) 60%, var(--surface)); }
.car-filter-row.on { background: var(--accent-wash); box-shadow: inset 4px 0 0 var(--accent); }
.car-filter-row img { width: 56px; height: 32px; object-fit: cover; border-radius: var(--r1); }
.car-filter-row .what { display: grid; min-width: 0; }
.car-filter-row .what b { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.car-filter-row .what small { color: var(--ink-3); }

/* drivers */
.driver-car { grid-column: 1 / -1; display: flex; align-items: center; gap: 8px; font-size: var(--t-xs); color: var(--ink-3); margin-top: 2px; }
.driver-facts .panel { display: grid; gap: 2px; }
.driver-facts .big-num { font-size: 1.75rem; }

/* garage detail */
.curve { margin: 0; }
.curve figcaption { margin-bottom: 8px; }
.mini-board { display: grid; gap: 1px; background: var(--rule); border: 1px solid var(--rule); border-radius: var(--r2); overflow: hidden; }
.mini-row { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 6px 12px; background: var(--surface); }
.mini-row .who { display: grid; min-width: 0; }
.mini-row .who a, .mini-row .who span.name { font-weight: 700; text-decoration: none; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mini-row .who small { color: var(--ink-3); font-size: var(--t-xs); }
.mini-row.me { background: var(--accent-wash); }
.layout-card > div:first-child img { width: 100%; border-radius: var(--r2); }
.detail-hero .shot { position: relative; aspect-ratio: 16 / 9; }
.detail-hero.track .stage .outline { background: #fff; }

/* sign in, errors */
.auth-card { max-width: 440px; margin: 40px auto 0; background: var(--surface); border: 1px solid var(--rule); border-radius: var(--r3); padding: 28px; display: grid; gap: 14px; position: relative; overflow: hidden; }
.auth-card::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 6px; background: linear-gradient(90deg, var(--stripe-a, var(--l1)) 0 50%, var(--accent) 50% 80%, var(--stripe-b, var(--l3)) 80%); }
.auth-card h1 { font-size: var(--t-2xl); font-style: italic; font-stretch: 112%; }
.error-card { max-width: 560px; }
.error-code { font-size: 4.5rem; font-weight: 900; font-style: italic; font-stretch: var(--wide); line-height: .9; color: var(--accent-text); }

/* ------------------------------------------------------------------ event style, class filter, balance (1.3) */
.style-choice { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
@media (max-width: 640px) { .style-choice { grid-template-columns: minmax(0, 1fr); } }
.style-card { position: relative; display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 14px; align-items: start; margin: 0; padding: 16px; border: 2px solid var(--rule); border-radius: var(--r3); background: var(--surface); cursor: pointer; font-weight: 500; }
.style-card input { position: absolute; opacity: 0; pointer-events: none; }
.style-card .style-ico { display: grid; place-items: center; width: 44px; height: 44px; border-radius: var(--r2); background: var(--surface-2); color: var(--ink-2); }
.style-card .style-ico svg { width: 24px; height: 24px; }
.style-card .style-txt { display: grid; gap: 4px; font-size: var(--t-s); color: var(--ink-2); line-height: 1.4; }
.style-card .style-txt b { font-size: 1.125rem; font-weight: 850; font-style: italic; font-stretch: 108%; color: var(--ink); }
.style-card:has(input:checked) { border-color: var(--accent-mark); background: var(--accent-wash); }
.style-card:has(input:checked) .style-ico { background: var(--accent); color: var(--on-accent); }
.style-card:has(input:focus-visible) { outline: 3px solid var(--focus); outline-offset: 2px; }
.rules-hint { margin-top: 12px; display: grid; gap: 6px; }
.rules-hint p { display: flex; flex-wrap: wrap; gap: 8px 14px; align-items: center; margin: 0; max-width: none; font-size: var(--t-s); color: var(--ink-2); }
.rules-hint p > span { flex: 1 1 320px; }
.rules-hint .hint:empty { display: none; }
.class-bar { display: grid; gap: 4px; margin-bottom: 12px; }
.class-pick { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 12px; }
.class-pick .label { margin: 0; }
.class-bar .hint { margin-top: 2px; }
.pick .pw { display: block; margin-top: 3px; font-size: .75rem; font-weight: 650; color: var(--ink-3); font-stretch: var(--narrow); font-variant-numeric: tabular-nums; }
.pick.out-of-class { cursor: not-allowed; border-color: transparent; background: var(--surface-2); }
.pick.out-of-class img, .pick.out-of-class .pick-fallback { filter: grayscale(1) opacity(.45); }
.pick.out-of-class .t { color: var(--ink-3); }
.pick .why { position: absolute; left: 6px; right: 6px; top: 34px; z-index: 2; justify-self: start; padding: 2px 7px; border-radius: var(--r1); background: rgba(6, 10, 16, .78); color: #fff; font-size: .72rem; font-weight: 700; pointer-events: none; }
.balance { border-top: 1px solid var(--rule); padding-top: 16px; display: grid; gap: 10px; }
.balance-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 10px 16px; }
.balance-head h3 { display: flex; align-items: center; gap: 8px; font-size: var(--t-l); }
.balance-head h3 svg { width: 22px; height: 22px; color: var(--accent-text); }
.balance-info { margin: 0; font-size: var(--t-s); color: var(--ink-2); }
.balance-opts { display: flex; flex-wrap: wrap; gap: 14px 24px; align-items: end; }
.balance-opts .field { width: 210px; }
.balance-opts .check { max-width: 420px; padding-bottom: 6px; }
.balance-table .car-cell img { width: 56px; height: 32px; }
.balance-table td { height: auto; padding-top: 6px; padding-bottom: 6px; }
.balance-table .num-in { width: 78px; min-height: 34px; padding: 4px 8px; text-align: right; }
.balance-table .hc-inputs { display: inline-flex; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.balance-table .with-unit.compact { display: inline-flex; }
.balance-table .with-unit.compact .num-in { width: 64px; border-top-right-radius: 0; border-bottom-right-radius: 0; }
.balance-table .with-unit.compact .unit { padding: 0 7px; font-size: var(--t-xs); }
.balance-table td.handicap { color: var(--ink-2); }
.balance-table td[data-c="result"] { white-space: nowrap; }
.balance-table td[data-c="result"] .tag { margin-left: 6px; }
.balance-table tr.unknown td { background: color-mix(in oklab, var(--soon) 8%, var(--surface)); }
@media (max-width: 720px) { .balance-table .num-in { width: 64px; } .balance-table .car-cell img { display: none; } }
@media (max-width: 600px) {
  .balance-wrap { border: 0; background: none; overflow: visible; border-radius: 0; }
  .balance-table, .balance-table tbody { display: block; }
  .balance-table thead { display: none; }
  .balance-table tr { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 8px 12px; padding: 10px 12px 12px; margin-bottom: 8px; border: 1px solid var(--rule); border-radius: var(--r2); background: var(--surface); }
  .balance-table td, .balance-table td.time, .balance-table td.r { display: grid; gap: 3px; align-content: start; justify-items: start; height: auto; padding: 0 !important; border: 0; text-align: left; background: none !important; }
  .balance-table td[data-l]::before { content: attr(data-l); font-size: var(--t-xs); font-weight: 650; color: var(--ink-3); font-stretch: var(--normal); }
  .balance-table td:first-child { grid-column: 1 / -1; font-weight: 750; }
  .balance-table .num-in { width: 100%; }
  .balance-table .hc-inputs { justify-content: flex-start; }
  .balance-table .with-unit.compact .num-in { width: 70px; }
  .balance-table tr.unknown { border-color: color-mix(in oklab, var(--soon) 55%, var(--rule)); }
}
.tag.style-serious { background: var(--ink); color: var(--paper); }
.tag.style-fun { background: var(--accent-wash); color: var(--accent-text); }
.tag svg { width: 12px; height: 12px; }

/* ------------------------------------------------------------------ incidents: stewarding (1.3) */
.inc-filters { display: flex; flex-wrap: wrap; gap: 8px 10px; align-items: center; }
.inc-filters .chip svg { width: 15px; height: 15px; }
.inc-minor { display: flex; flex-wrap: wrap; gap: 8px 16px; align-items: center; justify-content: space-between; padding: 10px 14px; border-radius: var(--r2); background: var(--surface); border: 1px solid var(--rule); border-left: 4px solid var(--soon); font-size: var(--t-s); color: var(--ink-2); }
.inc-group { background: var(--surface); border: 1px solid var(--rule); border-radius: var(--r3); padding: 14px 16px 16px; scroll-margin-top: 90px; }
.inc-group-head { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 4px 14px; align-items: center; margin-bottom: 12px; }
.inc-group-head .outline { width: 52px; }
.inc-group-head h2 { font-size: var(--t-l); }
.inc-group-head p { margin: 2px 0 0; display: flex; flex-wrap: wrap; gap: 6px 10px; align-items: center; }
.inc-group-side { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; justify-content: flex-end; }
@media (max-width: 600px) { .inc-group-head { grid-template-columns: auto minmax(0, 1fr); } .inc-group-side { grid-column: 1 / -1; justify-content: flex-start; } }
.inc-layout { display: grid; grid-template-columns: minmax(220px, 340px) minmax(0, 1fr); gap: 16px; align-items: start; }
.inc-layout.no-map { grid-template-columns: minmax(0, 1fr); }
@media (max-width: 900px) { .inc-layout { grid-template-columns: minmax(0, 1fr); } }
.inc-map { position: relative; background: var(--header); border-radius: var(--r2); padding: 10px; position: sticky; top: 90px; }
@media (max-width: 900px) { .inc-map { position: relative; top: auto; max-width: 420px; } }
.inc-map img { width: 100%; height: auto; opacity: .7; }
.inc-map-inner { position: relative; }
.inc-dot { position: absolute; transform: translate(-50%, -50%); display: grid; place-items: center; min-width: 22px; height: 22px; padding: 0 5px; border-radius: 11px; background: var(--live); color: #fff; font-size: 12px; font-weight: 800; font-stretch: var(--narrow); text-decoration: none; box-shadow: 0 0 0 2px var(--header); z-index: 1; }
.inc-dot:hover, .inc-dot:focus-visible { z-index: 2; transform: translate(-50%, -50%) scale(1.15); }
.inc-dot.status-no_action { background: #8A96A3; }
.inc-dot.status-warning { background: var(--soon); color: #111; }
.inc-dot.status-penalty { background: #fff; color: #111; }
.inc-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.inc-card { display: grid; grid-template-columns: 30px minmax(0, 1fr); gap: 12px; padding: 12px 14px; border: 1px solid var(--rule); border-radius: var(--r2); background: var(--surface); scroll-margin-top: 100px; }
.inc-card:target { border-color: var(--accent-mark); box-shadow: 0 0 0 3px var(--accent-wash); }
.inc-card.status-open { border-left: 4px solid var(--live); }
.inc-card.status-open.minor { border-left-color: var(--soon); }
.inc-card:not(.status-open) { background: var(--surface-2); }
.inc-num { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; background: var(--ink); color: var(--paper); font-weight: 850; font-stretch: var(--narrow); font-size: .875rem; }
.inc-card:not(.status-open) .inc-num { background: var(--surface-3); color: var(--ink-2); }
.inc-body { display: grid; gap: 6px; min-width: 0; }
.inc-top { display: flex; flex-wrap: wrap; gap: 4px 12px; align-items: baseline; justify-content: space-between; }
.inc-top b { font-size: 1.0625rem; }
.inc-speed { font-weight: 800; font-stretch: var(--narrow); font-variant-numeric: tabular-nums; color: var(--ink-2); white-space: nowrap; }
.inc-meta { margin: 0; font-size: var(--t-s); color: var(--ink-3); }
.decide { display: flex; flex-wrap: wrap; gap: 8px 10px; align-items: center; margin-top: 2px; }
.decide-who { display: inline-flex; flex-wrap: wrap; gap: 6px; align-items: center; padding: 3px 4px 3px 10px; border-radius: 999px; background: var(--surface-2); }
.decide-who .who { font-weight: 700; font-size: var(--t-s); max-width: 16ch; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.decide-who.likely { box-shadow: inset 0 0 0 1px var(--accent-mark); }
.decide-who .btn.small { min-height: 28px; padding: 0 10px; border-radius: 999px; }
.decide-secs { display: inline-flex; align-items: center; gap: 6px; margin: 0; font-size: var(--t-xs); color: var(--ink-3); font-weight: 650; }
.decide-secs select { width: auto; min-height: 32px; padding: 2px 8px; }
.decided { display: flex; flex-wrap: wrap; gap: 6px 12px; align-items: center; }
.verdict { display: inline-flex; align-items: center; gap: 6px; font-weight: 750; font-size: var(--t-s); }
.verdict svg { width: 16px; height: 16px; }
.verdict.penalty { color: var(--danger); }
.verdict.warning { color: color-mix(in oklab, var(--soon) 70%, var(--ink)); }
.verdict.no_action { color: var(--ink-2); }
.subnav .count { margin-left: 4px; background: var(--live); color: #fff; }
/* public: stewards' decisions on a results page */
.stewards { list-style: none; margin: 0; padding: 0; display: grid; gap: 1px; background: var(--rule); border: 1px solid var(--rule); border-radius: var(--r3); overflow: hidden; }
.stewards li { display: grid; grid-template-columns: 30px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 10px 14px; background: var(--surface); }
.stewards li .what { display: grid; gap: 2px; min-width: 0; }
.stewards li .what small { color: var(--ink-3); }
.stewards li .verdict { justify-self: end; text-align: right; }
@media (max-width: 560px) { .stewards li { grid-template-columns: 30px minmax(0, 1fr); } .stewards li .verdict { grid-column: 2; justify-self: start; } }
.tag.warn-tag { background: color-mix(in oklab, var(--soon) 24%, var(--surface)); color: var(--ink); }
.mode-line { display: flex; flex-wrap: wrap; gap: 6px 10px; align-items: center; margin: 2px 0 0; }
.sheet .driver-cell .tag.warn-tag { height: 18px; padding: 0 6px; font-size: .6875rem; margin-left: 4px; }

/* ------------------------------------------------------------------ ratings and licences (1.3) */
.lic { display: inline-grid; place-items: center; min-width: 30px; height: 22px; padding: 0 6px; border-radius: var(--r1); font-weight: 900; font-style: italic; font-stretch: 112%; font-size: .75rem; letter-spacing: .02em; line-height: 1; color: #0B0D10; background: var(--lic, #A3ADB8); box-shadow: inset 0 -2px 0 rgba(0, 0, 0, .18); vertical-align: middle; white-space: nowrap; }
.lic-R { --lic: #B4BDC6; }
.lic-D { --lic: #F08A3C; }
.lic-C { --lic: #F2C230; }
.lic-B { --lic: #2FAE62; color: #fff; }
.lic-A { --lic: #2F72DC; color: #fff; }
.lic-P { --lic: #111317; color: #F2C230; box-shadow: inset 0 0 0 1px #F2C230; }
.lic-none { --lic: transparent; color: var(--ink-3); box-shadow: inset 0 0 0 1px var(--rule-strong); }
.lic.big { min-width: 64px; height: 50px; font-size: 1.5rem; border-radius: var(--r2); }
.lic.corner { position: absolute; top: 12px; right: 12px; }
.driver-card .lic.corner ~ b, .driver-card b { padding-right: 0; }
.delta { font-size: .75rem; font-weight: 750; font-stretch: var(--narrow); font-variant-numeric: tabular-nums; color: var(--ink-3); white-space: nowrap; }
.delta.up { color: var(--pb-text); }
.delta.down { color: var(--danger); }
.driver-card .stats-line { flex-wrap: wrap; gap: 4px 14px; }
.driver-card > b { padding-right: 44px; }
.rating-board { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr) minmax(0, 1fr); gap: var(--gap-s); }
@media (max-width: 860px) { .rating-board { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); } .rating-board .lic-panel { grid-column: 1 / -1; } }
@media (max-width: 480px) { .rating-board { grid-template-columns: minmax(0, 1fr); } }
.rating-board .panel { display: grid; gap: 4px; align-content: start; }
.lic-panel { grid-template-columns: auto minmax(0, 1fr) !important; gap: 14px !important; align-items: center; }
.lic-name { display: block; font-size: 1.25rem; font-weight: 850; font-style: italic; font-stretch: 108%; }
.lic-steps { display: flex; gap: 3px; margin: 6px 0; }
.lic-steps i { display: block; width: 22px; height: 5px; border-radius: 2px; background: var(--surface-3); }
.lic-steps i.on { background: var(--accent-mark); }
.rating-num { display: flex; align-items: baseline; gap: 8px; }
.rating-num .big-num { font-size: 2.4rem; }
.rating-num .delta { font-size: .9375rem; }
.meter { height: 8px; border-radius: 999px; overflow: hidden; margin: 4px 0 2px; background: linear-gradient(90deg, var(--danger), var(--soon) 45%, var(--pb) 85%); }
.meter i { display: block; height: 100%; margin-left: var(--p, 0%); background: var(--surface-3); }
.how-ratings h3 { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.how-ratings h3 svg { width: 20px; height: 20px; color: var(--accent-text); }
.lic-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.lic-list li { display: grid; grid-template-columns: 40px minmax(0, 1fr); gap: 10px; align-items: center; }
.lic-list li > span:last-child { display: grid; }
.ratings-table td .lic { margin-right: 6px; }

/* ------------------------------------------------------------------ troll roulette (1.3) */
.roulette { position: relative; margin-top: 8px; border-radius: var(--r3); background: radial-gradient(120% 140% at 10% 0%, #1D2A36 0%, var(--header) 55%, #05080C 100%); color: #fff; padding: 28px 28px 30px; overflow: hidden; isolation: isolate; }
.roulette::after { content: ""; position: absolute; right: -60px; top: 0; bottom: 0; width: 230px; transform: skewX(-20deg); background: linear-gradient(90deg, var(--stripe-a, var(--l1)) 0 38%, var(--accent) 38% 74%, var(--stripe-b, var(--l3)) 74%); opacity: .9; z-index: -1; }
.roulette-head { display: grid; gap: 8px; max-width: 760px; }
.roulette-kicker { display: inline-flex; align-items: center; gap: 8px; margin: 0; font-weight: 800; font-size: var(--t-s); letter-spacing: .04em; text-transform: uppercase; color: var(--accent); }
.roulette-kicker svg { width: 18px; height: 18px; }
.roulette-head h1 { font-size: clamp(2.2rem, 6vw, 4rem); font-stretch: var(--wide); font-style: italic; font-weight: 850; letter-spacing: -.025em; line-height: .95; color: #fff; }
.roulette-head p { color: rgba(255, 255, 255, .82); margin: 0; }
.roulette-opts { display: flex; flex-wrap: wrap; gap: 12px 22px; align-items: center; margin: 22px 0 16px; }
.segmented-radio.on-dark { background: rgba(255, 255, 255, .1); }
.segmented-radio.on-dark span { color: rgba(255, 255, 255, .78); }
.segmented-radio.on-dark input:checked + span { background: #fff; color: #0B0D10; }
.toggle.on-dark { color: #fff; }
.toggle.on-dark .knob { background: rgba(255, 255, 255, .18); border-color: rgba(255, 255, 255, .3); }
.reels { display: grid; grid-template-columns: 1.15fr 1.15fr 1fr; gap: 14px; }
.reel { display: grid; gap: 6px; min-width: 0; }
.reel-label { font-size: var(--t-xs); font-weight: 750; letter-spacing: .05em; text-transform: uppercase; color: rgba(255, 255, 255, .62); }
.reel-window { --rh: 210px; position: relative; height: var(--rh); overflow: hidden; border-radius: var(--r2); background: rgba(255, 255, 255, .06); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .14), 0 10px 30px rgba(0, 0, 0, .35); }
.reel-window::before, .reel-window::after { content: ""; position: absolute; left: 0; right: 0; height: 26px; z-index: 2; pointer-events: none; }
.reel-window::before { top: 0; background: linear-gradient(180deg, rgba(5, 8, 12, .55), transparent); }
.reel-window::after { bottom: 0; background: linear-gradient(0deg, rgba(5, 8, 12, .55), transparent); }
.reel-window.dim { opacity: .45; }
.reel-strip { display: flex; flex-direction: column; will-change: transform; }
.reel-item { position: relative; flex: none; height: var(--rh); display: grid; align-items: end; overflow: hidden; background: #0E141B; }
.reel-item img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.reel-item .cap { position: relative; z-index: 1; display: grid; gap: 2px; padding: 30px 14px 12px; background: linear-gradient(0deg, rgba(5, 8, 12, .92), rgba(5, 8, 12, 0)); }
.reel-item .cap b { font-size: 1.125rem; font-weight: 850; font-style: italic; font-stretch: 106%; line-height: 1.15; overflow-wrap: anywhere; }
.reel-item .cap small { justify-self: start; font-size: .6875rem; font-weight: 750; padding: 1px 6px; border-radius: var(--r1); background: rgba(255, 255, 255, .18); }
.reel-fallback { position: absolute; inset: 0; display: grid; place-items: center; font-size: 3rem; font-weight: 900; font-style: italic; color: rgba(255, 255, 255, .25); }
.reel-item.twist { align-content: center; justify-items: start; gap: 8px; padding: 18px; background: linear-gradient(135deg, var(--accent) 0%, color-mix(in oklab, var(--accent) 70%, #000) 100%); color: var(--on-accent); }
.reel-item.twist b { font-size: 1.5rem; font-weight: 900; font-style: italic; font-stretch: 110%; line-height: 1.05; }
.reel-item.twist span { font-size: var(--t-s); font-weight: 600; line-height: 1.35; opacity: .9; }
.reel-item.twist.none { background: rgba(255, 255, 255, .08); color: rgba(255, 255, 255, .8); }
.roulette-go { display: flex; justify-content: center; margin-top: 22px; }
.spin-btn { min-width: 220px; font-size: 1.25rem; min-height: 58px; font-style: italic; font-weight: 900; letter-spacing: .01em; box-shadow: 0 10px 30px color-mix(in oklab, var(--accent) 40%, transparent); }
.spin-btn svg { width: 24px; height: 24px; }
.spin-btn[disabled] { opacity: 1; pointer-events: none; }
.spin-btn[disabled] svg { animation: spin-icon .7s linear infinite; }
@keyframes spin-icon { to { transform: rotate(360deg); } }
@media (max-width: 760px) {
  .roulette { padding: 22px 16px 24px; border-radius: 0; margin-left: -16px; margin-right: -16px; }
  .roulette::after { display: none; }
  .reels { grid-template-columns: minmax(0, 1fr); gap: 10px; }
  .reel-window { --rh: 132px; }
  .reel-item.twist b { font-size: 1.2rem; }
  .spin-btn { width: 100%; }
}
.roulette-result { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: var(--gap); margin-top: 18px; padding: 20px; background: var(--surface); border: 1px solid var(--rule); border-radius: var(--r3); border-top: 5px solid var(--accent); scroll-margin-top: 90px; }
@media (max-width: 860px) { .roulette-result { grid-template-columns: minmax(0, 1fr); } }
.rr-main { display: grid; gap: 10px; align-content: start; min-width: 0; }
.rr-kicker { margin: 0; font-size: var(--t-xs); font-weight: 750; letter-spacing: .05em; text-transform: uppercase; color: var(--accent-text); }
.rr-main h2 { font-size: clamp(1.6rem, 3.4vw, 2.3rem); font-style: italic; font-weight: 850; font-stretch: 110%; letter-spacing: -.015em; line-height: 1.05; }
.rr-twist { margin: 0; font-weight: 650; color: var(--ink-2); }
.rr-cars { display: flex; flex-wrap: wrap; gap: 8px; }
.rr-car { display: inline-flex; align-items: center; gap: 8px; padding: 4px 10px 4px 4px; border-radius: 999px; background: var(--surface-2); font-size: var(--t-s); font-weight: 650; }
.rr-car img { width: 46px; height: 26px; object-fit: cover; border-radius: 999px; }
.rr-start { display: grid; gap: 10px; align-content: start; padding: 16px; border-radius: var(--r2); background: var(--surface-2); }
.rr-start h3 { font-size: var(--t-l); }
.rr-start .hint { margin: 0; }
.checklist li > span { min-width: 0; overflow-wrap: anywhere; }
.verdict.open { color: var(--ink-3); font-weight: 600; }

/* ===================================================================== 1.4: speed cameras and the Wall of shame */
.cam-pick { display: grid; gap: 4px; min-width: min(320px, 100%); }
.cam-pick label { font-size: var(--t-xs); font-weight: 650; color: var(--ink-3); }
.cam-pick select { width: 100%; }
.callout.warn { border-left-color: var(--soon); display: flex; gap: 8px; align-items: center; margin-bottom: var(--gap); }
.cam-layout { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: var(--gap); align-items: start; }
.cam-layout.no-map { grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr); }
@media (max-width: 900px) { .cam-layout, .cam-layout.no-map { grid-template-columns: minmax(0, 1fr); } }
.cam-map-col { min-width: 0; }
.cam-map-col .hint { margin-top: 8px; }
.cam-map { position: relative; top: auto; max-width: none; }
.cam-map img { cursor: crosshair; opacity: .78; user-select: none; -webkit-user-select: none; }
.cam-dot { --reach: 4%; position: absolute; transform: translate(-50%, -50%); width: var(--reach); aspect-ratio: 1; min-width: 14px; border-radius: 50%;
  background: color-mix(in oklab, var(--live) 22%, transparent); border: 2px solid var(--live); text-decoration: none; z-index: 1; pointer-events: none; }
.cam-dot > span { pointer-events: auto; position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); display: grid; place-items: center; min-width: 22px; height: 22px; padding: 0 5px; border-radius: 11px;
  background: var(--live); color: #fff; font-size: 12px; font-weight: 800; font-stretch: var(--narrow); box-shadow: 0 0 0 2px var(--header); }
.cam-dot:hover > span, .cam-dot:focus-visible > span { transform: translate(-50%, -50%) scale(1.15); }
.cam-dot.off { border-style: dashed; border-color: #8A96A3; background: rgba(138, 150, 163, .15); }
.cam-dot.off > span { background: #8A96A3; }
.cam-dot.new { border-color: var(--soon); background: color-mix(in oklab, var(--soon) 25%, transparent); z-index: 3; animation: cam-pulse 1.4s ease-in-out infinite; }
.cam-dot.new > span { background: var(--soon); color: #111; pointer-events: none; }
@keyframes cam-pulse { 50% { box-shadow: 0 0 0 6px color-mix(in oklab, var(--soon) 30%, transparent); } }
@media (prefers-reduced-motion: reduce) { .cam-dot.new { animation: none; } }
.cam-fields { grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); }
.cam-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.cam-card { display: grid; grid-template-columns: 30px minmax(0, 1fr); gap: 12px; padding: 14px; border: 1px solid var(--rule); border-left: 4px solid var(--live); border-radius: var(--r2); background: var(--surface); scroll-margin-top: 100px; }
.cam-card:target { box-shadow: 0 0 0 3px var(--accent-wash); }
.cam-card.off { border-left-color: #8A96A3; background: var(--surface-2); }
.cam-card.off .inc-num { background: var(--surface-3); color: var(--ink-2); }
.cam-pos summary { cursor: pointer; font-size: var(--t-s); color: var(--ink-3); }
.cam-pos .fields { margin-top: 10px; max-width: 360px; }
.cam-foot { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; justify-content: space-between; }
.cam-foot .muted svg { width: 15px; height: 15px; vertical-align: -2px; margin-right: 4px; }
.sheet.fines td { padding-top: 7px; padding-bottom: 7px; }
.panel h3 svg, .section-head h2 svg, .cam-foot .muted svg { display: inline-block; width: 1em; height: 1em; vertical-align: -.12em; margin-right: 6px; }

/* wanted stars */
.wanted { display: inline-flex; gap: 1px; color: var(--soon); vertical-align: -2px; }
.wanted svg { width: 14px; height: 14px; }
.wanted-live { color: var(--soon); letter-spacing: 1px; font-size: .85em; white-space: nowrap; }

/* Wall of shame */
.shame-facts .big-num { font-size: 1.75rem; }
.wanted-board { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 8px; }
.wanted-board li { display: grid; grid-template-columns: 34px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 12px 14px; background: var(--surface); border: 1px solid var(--rule); border-radius: var(--r2); }
.wanted-board li .name { display: block; font-weight: 750; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.wanted-board li .tag { vertical-align: 1px; }
.wanted-rank { display: grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; background: var(--surface-3); font-weight: 850; font-stretch: var(--narrow); }
.wanted-fine { font-weight: 800; font-variant-numeric: tabular-nums; white-space: nowrap; }
.wanted-board li.top { grid-column: 1 / -1; background: var(--header); color: #fff; border-color: transparent; padding: 18px; position: relative; overflow: hidden; }
.wanted-board li.top::after { content: "WANTED"; position: absolute; right: 16px; top: 50%; transform: translateY(-50%) rotate(-8deg); font-size: clamp(1.8rem, 6vw, 3.4rem); font-weight: 900; font-style: italic; letter-spacing: .04em; color: rgba(255, 255, 255, .07); pointer-events: none; }
.wanted-board li.top .muted { color: rgba(255, 255, 255, .72); }
.wanted-board li.top a { color: #fff; }
.wanted-board li.top .name { font-size: var(--t-l); }
.wanted-board li.top .wanted-rank { background: var(--live); color: #fff; width: 40px; height: 40px; }
.wanted-board li.top .wanted-fine { font-size: 1.35rem; position: relative; z-index: 1; }
.flash-feed { list-style: none; margin: 0; padding: 0; display: grid; }
.flash-feed li { display: grid; grid-template-columns: 92px minmax(0, 1fr) auto; gap: 12px; align-items: baseline; padding: 9px 0; border-bottom: 1px solid var(--rule); }
.flash-feed.compact li { grid-template-columns: 56px minmax(0, 1fr) auto; }
.flash-feed time { font-size: var(--t-xs); color: var(--ink-3); font-variant-numeric: tabular-nums; }
.flash-feed .sub { display: block; font-size: var(--t-xs); color: var(--ink-3); }
.flash-feed .fine { font-variant-numeric: tabular-nums; white-space: nowrap; }
@media (max-width: 520px) { .flash-feed li { grid-template-columns: minmax(0, 1fr) auto; } .flash-feed time { grid-column: 1 / -1; } }
.cam-stats .panel { display: grid; gap: 4px; }
.cam-stat { margin-top: 6px; font-size: var(--t-s); }
.rap-sheet { padding: 16px; border: 1px solid var(--rule); border-left: 4px solid var(--soon); border-radius: var(--r2); background: var(--surface); }
.rap-head { display: flex; gap: 12px; align-items: flex-start; margin-bottom: 6px; }
.rap-head h2 { font-size: var(--t-l); }
.rap-head p { margin: 2px 0 0; }
.rap-icon { display: grid; place-items: center; width: 38px; height: 38px; flex: none; border-radius: 50%; background: color-mix(in oklab, var(--soon) 24%, var(--surface)); }
.rap-sheet .flash-feed li:last-child { border-bottom: 0; }
