/* ============================================================
   Match Center — atletiek.nl results & data portal
   Built on the Atletiekunie design system
   ============================================================ */

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; height: 100%; }
body {
  background: var(--bg-app, var(--au-surface-2));
  color: var(--fg-app, var(--au-ink));
  font-family: var(--font-sans);
  font-size: 15px;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
button { font-family: inherit; cursor: pointer; }
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }

/* ============================================================
   Theme tokens — light + dark + accent intensity
   ============================================================ */
:root {
  /* surfaces */
  --bg-app:      var(--au-surface-2);
  --bg-panel:    var(--au-paper);
  --bg-panel-2:  var(--au-surface);
  --bg-inset:    var(--au-surface-3);
  --bg-deep:     var(--au-ink-deep);

  /* text */
  --fg-app:      var(--au-ink);
  --fg-mute:     var(--au-mute);
  --fg-inv:      #ffffff;

  /* line */
  --line-app:    var(--au-line);
  --line-strong: #c4c4c8;

  /* brand accent — scales by intensity */
  --accent:      var(--au-orange);
  --accent-h:    var(--au-orange-hover);
  --accent-soft: var(--au-orange-tint);
  --accent-on:   #ffffff;
  --accent-flood: 1; /* 0–1 scaling on tinted surfaces */

  /* sidebar */
  --sb-w: 252px;
  --topbar-h: 40px;
  --header-h: 64px;
}

body.theme-dark {
  --bg-app:      #0d0e13;
  --bg-panel:    #161821;
  --bg-panel-2: #1d1f2a;
  --bg-inset:    #11131a;
  --bg-deep:     #05060a;

  --fg-app:      #f0f1f5;
  --fg-mute:     #8b8d99;
  --fg-inv:      #ffffff;

  --line-app:    #262833;
  --line-strong: #353846;

  --accent:      #f06320;
  --accent-h:    #ff7733;
  --accent-soft: #2a1610;
}

/* Accent intensity controls how much orange "floods" non-CTA chrome.
   low = chrome stays neutral; high = orange leaks into surfaces, sidebar, more headers. */
body.intensity-low  { --accent-flood: 0; }
body.intensity-med  { --accent-flood: 1; }
body.intensity-high { --accent-flood: 1.6; }

/* ============================================================
   App shell
   ============================================================ */
.app {
  display: grid;
  grid-template-columns: var(--sb-w) 1fr;
  min-height: 100vh;
}

/* ---------- Sidebar ---------- */
.sb {
  background: var(--bg-panel);
  border-right: 1px solid var(--line-app);
  position: sticky;
  top: 0;
  height: 100vh;
  display: flex;
  flex-direction: column;
  min-width: 0;
}
.sb__nav { display: flex; flex-direction: column; gap: 2px; padding: 0 8px; min-width: 0; }
body.intensity-high .sb {
  background: linear-gradient(180deg, var(--accent) 0%, var(--accent) 88px, var(--bg-panel) 88px);
}
.sb__brand {
  padding: 18px 20px 22px;
  display: flex;
  align-items: center;
  gap: 12px;
  border-bottom: 1px solid var(--line-app);
  position: relative;
}
.sb__logo {
  width: 36px; height: 36px;
  background: var(--accent);
  display: grid; place-items: center;
  color: #fff; font-weight: 800; font-style: italic;
  font-size: 18px; letter-spacing: -0.04em;
  border-radius: 4px;
  flex: none;
}
body.intensity-high .sb__logo {
  background: #fff; color: var(--accent);
}
.sb__name {
  font-weight: 800; font-style: italic;
  text-transform: uppercase;
  font-size: 14px;
  letter-spacing: -0.005em;
  line-height: 1.05;
  white-space: nowrap;
}
.sb__sub {
  font-size: 10.5px; font-weight: 600;
  color: var(--fg-mute);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-top: 4px;
}
body.intensity-high .sb__name,
body.intensity-high .sb__sub { color: #fff; }

.sb__section {
  padding: 16px 12px 4px;
  font-size: 10.5px; font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--fg-mute);
}
.sb__item {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 12px;
  font-weight: 600; font-size: 14px;
  color: var(--fg-app);
  border-radius: 4px;
  cursor: pointer;
  border: 0; background: transparent; text-align: left;
  position: relative;
  transition: background var(--dur-fast) var(--ease), color var(--dur-fast) var(--ease);
  white-space: nowrap;
  min-width: 0;
}
.sb__item > span:nth-child(2) {
  flex: 1; min-width: 0;
  overflow: hidden; text-overflow: ellipsis;
}
.sb__item:hover {
  background: var(--bg-panel-2);
  color: var(--accent);
}
.sb__item.is-active {
  background: var(--bg-panel-2);
  color: var(--accent);
}
.sb__item.is-active::before {
  content: "";
  position: absolute; left: 0; top: 8px; bottom: 8px; width: 3px;
  background: var(--accent);
  border-radius: 0 2px 2px 0;
}
/* Not-yet-built modules (and the deferred login) render as inert <span>s carrying the
   "binnenkort" hint - dim them and kill the hover affordance so they don't read as clickable. */
.sb__item.is-disabled,
.sb__login.is-disabled { opacity: 0.5; cursor: default; pointer-events: none; }
.sb__item .ic { width: 18px; height: 18px; flex: none; }
.sb__badge {
  margin-left: auto;
  background: var(--au-red);
  color: #fff;
  font-size: 9.5px; font-weight: 800;
  padding: 2px 5px;
  border-radius: 999px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  display: inline-flex; align-items: center; gap: 4px;
  flex: none;
}
.sb__badge--live::before {
  content: "";
  width: 5px; height: 5px;
  background: #fff; border-radius: 50%;
  animation: pulse 1.4s infinite;
}
.sb__foot {
  margin-top: auto;
  padding: 16px;
  border-top: 1px solid var(--line-app);
  display: flex; flex-direction: column; gap: 10px;
}
.sb__login {
  background: var(--accent); color: var(--accent-on);
  padding: 11px 14px; border: 0; border-radius: 4px;
  font-weight: 700; font-size: 13.5px;
  display: flex; align-items: center; justify-content: space-between;
  transition: background var(--dur-fast) var(--ease);
}
.sb__login:hover { background: var(--accent-h); }
/* --- polish: the login/logout chevron was a bare <svg> in a flex row with nothing to size
   it, so it rendered invisible (0x0). Design uses IcChevR size={14} here. --- */
.sb__login .ic { width: 14px; height: 14px; flex: none; }
.sb__locale {
  font-size: 12px; color: var(--fg-mute);
  display: flex; gap: 8px; align-items: center;
}
.sb__locale b { color: var(--fg-app); font-weight: 700; }

/* ---------- Main ---------- */
.main { min-width: 0; display: flex; flex-direction: column; }

/* Top utility bar */
.topbar {
  height: var(--topbar-h);
  background: var(--accent) url("/assets/triangle-pattern.svg") center / 60px 52px repeat;
  color: #fff;
  display: flex; align-items: center;
  padding: 0 28px;
  font-size: 11.5px; font-weight: 700;
  letter-spacing: 0.1em; text-transform: uppercase;
  gap: 24px;
  position: sticky; top: 0; z-index: 30;
  white-space: nowrap;
  overflow: hidden;
}
.topbar__sep { width: 1px; height: 14px; background: rgba(255,255,255,0.3); }
.topbar__crumb { opacity: 0.92; }
.topbar__crumb b { font-weight: 800; }
.topbar__right { margin-left: auto; display: flex; align-items: center; gap: 20px; }
.topbar__sponsors { display: flex; align-items: center; gap: 22px; }
.topbar__sponsor {
  font-weight: 800; font-style: italic; font-size: 13px;
  letter-spacing: 0.02em;
}
.topbar__sponsor--block {
  font-style: normal; font-size: 9px; line-height: 1.05;
  padding: 4px 8px; border: 1px solid #fff; border-radius: 999px;
  letter-spacing: 0.08em;
}
.topbar__theme {
  display: inline-flex; align-items: center; justify-content: center;
  width: 30px; height: 30px;
  background: rgba(255,255,255,0.14);
  border: 0; border-radius: 50%;
  color: #fff; cursor: pointer;
  transition: background var(--dur-fast) var(--ease);
  flex: none;
}
.topbar__theme:hover { background: rgba(255,255,255,0.26); }
.topbar__theme .ic { width: 16px; height: 16px; }
.topbar__theme-icon--moon { display: none; }
body.theme-dark .topbar__theme-icon--sun { display: none; }
body.theme-dark .topbar__theme-icon--moon { display: inline-flex; }

/* Page header */
.ph {
  padding: 28px 36px 22px;
  background: var(--bg-panel);
  border-bottom: 1px solid var(--line-app);
}
.ph__eye {
  font-size: 11px; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.14em;
  color: var(--accent);
  margin-bottom: 8px;
}
.ph__title {
  /* Explicit color needed: tokens.css's `h1, .au-h1 { color: var(--fg-1) }`
     directly targets this <h1> and, being a direct (not inherited) match,
     would otherwise always win over body's dark-mode --fg-app regardless of
     stylesheet order - leaving every page's title invisible in dark mode. */
  color: var(--fg-app);
  font-weight: 800; font-style: italic; text-transform: uppercase;
  font-size: 38px; letter-spacing: -0.02em; line-height: 0.98;
  margin: 0;
}
.ph__sub {
  margin-top: 10px;
  color: var(--fg-mute);
  font-size: 14.5px; max-width: 58ch;
}
.ph__row {
  display: flex; align-items: flex-end; justify-content: space-between;
  gap: 24px;
}
.ph__tools { display: flex; align-items: center; gap: 10px; flex-shrink: 0; flex-wrap: nowrap; }
.ph__tools .btn { white-space: nowrap; }

/* Page body */
.pg { padding: 28px 36px 56px; }

/* ============================================================
   Generic atoms
   ============================================================ */
.card {
  background: var(--bg-panel);
  border: 1px solid var(--line-app);
  border-radius: 4px;
}
.card--inset { background: var(--bg-inset); }
.card__head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px 18px; gap: 12px;
  border-bottom: 1px solid var(--line-app);
}
.card__title {
  font-size: 14px; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.1em;
  display: flex; align-items: center; gap: 10px;
  margin: 0;
}
.card__title small {
  color: var(--fg-mute);
  font-size: 11.5px; font-weight: 600;
  letter-spacing: 0.06em;
}
.card__action {
  font-size: 12.5px; font-weight: 700;
  color: var(--accent);
  display: inline-flex; align-items: center; gap: 2px;
}
.card__body { padding: 16px 18px; }
.card__body--flush { padding: 0; }

.eye {
  font-size: 10.5px; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.12em;
  color: var(--accent);
}

.btn { font: 700 13.5px/1 var(--font-sans); border: 0; cursor: pointer; border-radius: 4px; white-space: nowrap; display: inline-flex; align-items: center; justify-content: center; transition: background var(--dur-fast) var(--ease), color var(--dur-fast) var(--ease); }
.btn--p { background: var(--accent); color: var(--accent-on); padding: 11px 18px; }
.btn--p:hover { background: var(--accent-h); }
.btn--g { background: transparent; color: var(--fg-app); border: 1px solid var(--line-strong); padding: 10px 16px; }
.btn--g:hover { border-color: var(--accent); color: var(--accent); }
.btn--d { background: var(--au-ink); color: #fff; padding: 11px 18px; }
.btn--icon { background: transparent; border: 1px solid var(--line-strong); width: 38px; height: 38px; border-radius: 4px; display: grid; place-items: center; color: var(--fg-app); }
.btn--icon:hover { border-color: var(--accent); color: var(--accent); }
/* --- polish: "Meer resultaten laden" trailing chevron was a bare <svg> mixed into the
   button's text run with no width/height, so it rendered invisible - size it. --- */
.btn .ic { width: 12px; height: 12px; margin-left: 2px; flex: none; }

.icon { width: 18px; height: 18px; stroke: currentColor; fill: none; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; }

.chip {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 6px 11px;
  background: var(--bg-panel-2);
  border: 1px solid var(--line-app);
  font-size: 12px; font-weight: 700;
  letter-spacing: 0.04em; text-transform: uppercase;
  border-radius: 999px;
  color: var(--fg-app);
  cursor: pointer;
}
.chip:hover { border-color: var(--accent); color: var(--accent); }
.chip.is-active {
  background: var(--accent); color: var(--accent-on); border-color: var(--accent);
}

.tag {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 3px 7px;
  font-size: 10px; font-weight: 800;
  letter-spacing: 0.08em; text-transform: uppercase;
  border-radius: 2px;
}
.tag--nr { background: var(--au-red); color: #fff; }
.tag--cr { background: var(--au-navy); color: #fff; }
.tag--pr { background: var(--au-orange); color: #fff; }
.tag--sb { background: var(--bg-panel-2); color: var(--fg-app); border: 1px solid var(--line-app); }
.tag--live {
  background: var(--au-red); color: #fff;
  padding-left: 14px; position: relative;
}
.tag--live::before {
  content: ""; position: absolute; left: 6px; top: 50%;
  width: 5px; height: 5px; background: #fff; border-radius: 50%;
  transform: translateY(-50%);
  animation: pulse 1.4s infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; transform: translateY(-50%) scale(1); }
  50% { opacity: 0.35; transform: translateY(-50%) scale(1.5); }
}

/* Generic pulse for non-tag dots */
.pulse-dot {
  display: inline-block;
  width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--au-red);
  margin-right: 6px;
  animation: pulseDot 1.4s infinite;
  vertical-align: middle;
}
@keyframes pulseDot {
  0%, 100% { opacity: 1; box-shadow: 0 0 0 0 rgba(218,56,61,0.55); }
  70% { opacity: 0.7; box-shadow: 0 0 0 8px rgba(218,56,61,0); }
}

/* Numeric (tabular, italic option) */
.num {
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum";
  letter-spacing: -0.01em;
}
.num--big {
  font-weight: 800; font-style: italic;
  font-size: 32px; line-height: 0.95;
  letter-spacing: -0.025em;
}
.num--xl {
  font-weight: 800; font-style: italic;
  font-size: 56px; line-height: 0.9;
  letter-spacing: -0.03em;
}
.num--xxl {
  font-weight: 800; font-style: italic;
  font-size: 96px; line-height: 0.85;
  letter-spacing: -0.04em;
}

/* ============================================================
   Avatar — initial chip with flag
   ============================================================ */
.av {
  width: 36px; height: 36px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-h) 100%);
  color: #fff;
  display: grid; place-items: center;
  font-weight: 800; font-size: 13px;
  letter-spacing: -0.01em;
  flex: none;
  position: relative;
  overflow: hidden;
}
.av--lg { width: 56px; height: 56px; font-size: 18px; }
.av--xl { width: 96px; height: 96px; font-size: 30px; }
.av__flag {
  position: absolute; bottom: -2px; right: -2px;
  width: 16px; height: 12px;
  display: grid; grid-template-columns: 1fr; border-radius: 2px;
  overflow: hidden;
  border: 1.5px solid var(--bg-panel);
}
.av__flag b {
  display: block; height: 4px;
}
.flag-nl b:nth-child(1) { background: #ae1c28; }
.flag-nl b:nth-child(2) { background: #fff; }
.flag-nl b:nth-child(3) { background: #21468b; }

/* ============================================================
   Live ticker
   ============================================================ */
.ticker {
  background: var(--au-ink-deep);
  color: #fff;
  display: flex; align-items: center;
  font-size: 13px;
  border-radius: 4px;
  overflow: hidden;
}
.ticker__label {
  background: var(--au-red);
  padding: 0 14px;
  height: 38px; display: flex; align-items: center; gap: 7px;
  font-weight: 800; letter-spacing: 0.1em; text-transform: uppercase;
  font-size: 11px;
  flex: none;
}
.ticker__rail {
  flex: 1;
  display: flex; align-items: center; gap: 28px;
  padding: 0 18px;
  overflow: hidden;
  white-space: nowrap;
  min-width: 0;
}
.ticker__item {
  display: inline-flex; align-items: center; gap: 10px;
  font-weight: 600;
  flex: none;
}
.ticker__item b { font-weight: 800; }
.ticker__item .num { color: var(--accent); font-style: italic; font-weight: 800; }

/* ============================================================
   Dashboard layout
   ============================================================ */
.dash {
  display: grid;
  grid-template-columns: 1.6fr 1fr;
  gap: 22px;
}
.dash__col { display: flex; flex-direction: column; gap: 22px; min-width: 0; }

/* Hero: featured competition */
.hero {
  position: relative;
  border-radius: 4px;
  overflow: hidden;
  background: var(--au-orange) url("/assets/triangle-pattern.svg") center / 60px 52px repeat;
  color: #fff;
  min-height: 380px;
  display: flex; flex-direction: column;
  isolation: isolate;
}
.hero::before {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(135deg, rgba(0,0,0,0.65) 0%, rgba(0,0,0,0.25) 45%, rgba(0,0,0,0.05) 70%),
              linear-gradient(180deg, rgba(0,0,0,0) 35%, rgba(0,0,0,0.7) 100%);
  z-index: 1;
}
.hero__img {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover;
  z-index: 0;
  opacity: 0.95;
}
.hero__top {
  position: relative; z-index: 2;
  padding: 22px 26px;
  display: flex; align-items: center; gap: 12px;
}
.hero__live {
  display: inline-flex; align-items: center; gap: 8px;
  background: rgba(0,0,0,0.45);
  padding: 6px 12px 6px 28px;
  font-weight: 800; font-size: 11.5px;
  letter-spacing: 0.12em; text-transform: uppercase;
  border-radius: 2px;
  position: relative;
}
.hero__live::before {
  content: ""; position: absolute; left: 10px; top: 50%;
  width: 7px; height: 7px; background: #fff; border-radius: 50%;
  transform: translateY(-50%); animation: pulse 1.2s infinite;
}
.hero__where { font-size: 12.5px; font-weight: 600; letter-spacing: 0.04em; opacity: 0.9; }
.hero__body {
  position: relative; z-index: 2;
  padding: 0 26px 22px;
  margin-top: auto;
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 24px;
  align-items: end;
}
.hero__title {
  font-weight: 800; font-style: italic; text-transform: uppercase;
  font-size: clamp(34px, 3.4vw, 52px); line-height: 0.96;
  letter-spacing: -0.025em;
  margin: 0;
}
.hero__sub { margin-top: 8px; font-size: 14.5px; opacity: 0.9; }
.hero__feature {
  background: rgba(0,0,0,0.42);
  backdrop-filter: blur(2px);
  padding: 16px 18px;
  display: grid; grid-template-columns: auto 1fr; gap: 14px; align-items: center;
  border-left: 3px solid var(--accent-on);
}
.hero__feature .num--big { color: #fff; }
.hero__feature .lbl { font-size: 10.5px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.1em; opacity: 0.85; }
.hero__feature .nm { font-size: 14px; font-weight: 700; }
.hero__feature .sub-line { font-size: 11px; opacity: 0.85; }

.hero__cta {
  position: absolute; right: 26px; bottom: 22px;
  z-index: 3;
  background: #fff; color: var(--au-ink);
  padding: 11px 18px;
  font-weight: 800; font-size: 13px;
  letter-spacing: 0.05em; text-transform: uppercase;
  border: 0;
  display: inline-flex; align-items: center; gap: 6px;
  white-space: nowrap;
}

/* Top performances */
.tp {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
}
.tp__col {
  padding: 22px 20px;
  border-right: 1px solid var(--line-app);
  display: flex; flex-direction: column; gap: 8px;
  position: relative;
}
.tp__col:last-child { border-right: 0; }
.tp__rank {
  position: absolute; right: 16px; top: 14px;
  font-weight: 800; font-style: italic;
  font-size: 56px; line-height: 0.85;
  color: var(--line-app);
  letter-spacing: -0.04em;
}
.tp__col:nth-child(1) .tp__rank { color: var(--accent); opacity: 0.95; }
.tp__col:nth-child(2) .tp__rank { color: var(--au-navy); opacity: 0.6; }
.tp__col:nth-child(3) .tp__rank { color: var(--fg-mute); opacity: 0.5; }
body.theme-dark .tp__col:nth-child(3) .tp__rank { color: #3a3d4a; opacity: 1; }
body.theme-dark .tp__col:nth-child(2) .tp__rank { color: var(--au-navy-deep); opacity: 1; }

.tp__name { font-weight: 700; font-size: 16px; max-width: 12ch; }
.tp__time { font-weight: 800; font-style: italic; font-size: 26px; letter-spacing: -0.02em; margin-top: 2px; }
.tp__meta { color: var(--fg-mute); font-size: 12px; }

/* Records broken */
.recs { display: flex; flex-direction: column; }
.rec {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 14px; align-items: center;
  padding: 14px 18px;
  border-bottom: 1px solid var(--line-app);
}
.rec:last-child { border-bottom: 0; }
.rec__when {
  font-weight: 800; font-style: italic; font-size: 13px;
  letter-spacing: -0.005em;
  color: var(--au-red);
  width: 64px; flex: none;
  text-align: left;
}
.rec__body { min-width: 0; }
.rec__head {
  font-size: 12px; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.08em;
  color: var(--fg-mute);
}
.rec__head b { color: var(--au-red); }
.rec__name {
  font-weight: 700; font-size: 15px;
  margin-top: 2px;
}
.rec__time {
  font-weight: 800; font-style: italic;
  font-size: 22px; letter-spacing: -0.02em;
  text-align: right;
}
.rec__delta {
  font-size: 11px; color: var(--au-red); font-weight: 700;
  display: block; margin-top: 2px;
}

/* Calendar / upcoming */
.cal { display: flex; flex-direction: column; }
.cal__row {
  display: grid;
  grid-template-columns: 56px 1fr auto;
  gap: 14px; align-items: center;
  padding: 14px 18px;
  border-bottom: 1px solid var(--line-app);
  cursor: pointer;
  transition: background var(--dur-fast) var(--ease);
}
.cal__row:last-child { border-bottom: 0; }
.cal__row:hover { background: var(--bg-panel-2); }
.cal__date {
  text-align: center;
  border-right: 1px solid var(--line-app);
  padding-right: 12px;
}
.cal__date .d {
  font-weight: 800; font-style: italic; font-size: 22px;
  letter-spacing: -0.02em; line-height: 1;
  color: var(--accent);
}
.cal__date .m {
  font-size: 10px; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.1em;
  color: var(--fg-mute);
  margin-top: 3px;
}
.cal__title { font-weight: 700; font-size: 14.5px; }
.cal__where { color: var(--fg-mute); font-size: 12px; margin-top: 2px; }
.cal__loc { font-weight: 700; font-size: 12px; color: var(--fg-mute); text-align: right; }

/* News strip */
.news-strip { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.news-card {
  border-radius: 4px; overflow: hidden;
  position: relative;
  min-height: 200px;
  background: linear-gradient(135deg, #2a3340 0%, #1a2230 100%);
  color: #fff;
  cursor: pointer;
}
.news-card__img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform 0.4s var(--ease); }
.news-card:hover .news-card__img { transform: scale(1.04); }
.news-card::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 30%, rgba(0,0,0,0.85) 100%);
}
.news-card__body { position: absolute; left: 16px; right: 16px; bottom: 14px; z-index: 2; }
.news-card__eye {
  font-size: 10px; font-weight: 800;
  letter-spacing: 0.14em; text-transform: uppercase;
  color: #fff; opacity: 0.95;
  margin-bottom: 6px;
}
.news-card__title { font-weight: 800; font-size: 16px; line-height: 1.15; }

/* ============================================================
   Bestlists
   ============================================================ */
.bl {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 22px;
}
.bl__filters { align-self: start; position: sticky; top: calc(var(--topbar-h) + 16px); }
.bl__fieldgroup { padding: 14px 18px; border-bottom: 1px solid var(--line-app); }
.bl__fieldgroup:last-child { border-bottom: 0; }
.bl__lab {
  font-size: 10.5px; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.12em;
  color: var(--fg-mute);
  margin-bottom: 8px;
}
.bl__chips { display: flex; flex-wrap: wrap; gap: 6px; }
.bl__chips .chip { padding: 5px 10px; font-size: 11px; }

.sel, .inp {
  width: 100%;
  font: 500 13.5px/1 var(--font-sans);
  padding: 10px 12px;
  border: 1px solid var(--line-app);
  background: var(--bg-panel);
  color: var(--fg-app);
  border-radius: 4px;
}
.sel:focus, .inp:focus { outline: 2px solid var(--accent); outline-offset: 1px; border-color: var(--accent); }

/* Podium */
.podium {
  display: grid;
  grid-template-columns: 1fr 1.2fr 1fr;
  gap: 14px;
  margin-bottom: 22px;
}
.pod {
  background: var(--bg-panel);
  border: 1px solid var(--line-app);
  padding: 22px 18px;
  position: relative;
  display: flex; flex-direction: column; gap: 6px;
}
.pod--1 {
  background: var(--accent) url("/assets/triangle-pattern.svg") right top / 60px 52px repeat;
  border-color: var(--accent);
  color: #fff;
}
.pod--1 .pod__rank { color: #fff; }
.pod--1 .pod__time { color: #fff; }
.pod--1 .pod__meta { color: rgba(255,255,255,0.85); }
.pod--2 { background: var(--au-navy); color: #fff; border-color: var(--au-navy); }
.pod--2 .pod__rank { color: #fff; }
.pod--2 .pod__time { color: #fff; }
.pod--2 .pod__meta { color: rgba(255,255,255,0.85); }

.pod__rank {
  font-weight: 800; font-style: italic;
  font-size: 64px; line-height: 0.85;
  letter-spacing: -0.04em;
  color: var(--accent);
}
.pod__name {
  font-weight: 800; font-size: 18px;
  margin-top: 4px;
  letter-spacing: -0.005em;
}
.pod--1 .pod__name, .pod--2 .pod__name { color: #fff; }
.pod__club {
  font-size: 12px;
  color: var(--fg-mute);
}
.pod__time {
  font-weight: 800; font-style: italic;
  font-size: 38px;
  letter-spacing: -0.025em;
  margin-top: 8px;
}
.pod__meta {
  font-size: 11.5px; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.08em;
  color: var(--fg-mute);
  display: flex; gap: 10px; align-items: center;
}

/* Bestlist table */
.table { width: 100%; }
.table__head {
  display: grid;
  grid-template-columns: 56px 1fr 110px 110px 70px 80px;
  gap: 16px; align-items: center;
  padding: 12px 18px;
  font-size: 11px; font-weight: 800;
  text-transform: uppercase; letter-spacing: 0.1em;
  color: var(--fg-mute);
  border-bottom: 2px solid var(--fg-app);
}
.table__row {
  display: grid;
  grid-template-columns: 56px 1fr 110px 110px 70px 80px;
  gap: 16px; align-items: center;
  padding: 14px 18px;
  border-bottom: 1px solid var(--line-app);
  transition: background var(--dur-fast) var(--ease);
}
.table__row:hover { background: var(--bg-panel-2); }
.table__row:last-child { border-bottom: 0; }
.table__rank {
  font-weight: 800; font-style: italic;
  font-size: 22px;
  color: var(--accent);
  letter-spacing: -0.02em;
}
.table__athlete { min-width: 0; display: flex; align-items: center; gap: 12px; }
.table__nm { font-weight: 700; font-size: 14.5px; }
.table__cl { font-size: 12px; color: var(--fg-mute); margin-top: 2px; }
.table__t { font-weight: 800; font-style: italic; font-size: 17px; letter-spacing: -0.015em; }
.table__d { font-size: 13px; color: var(--fg-mute); }
.table__w { font-size: 12.5px; color: var(--fg-mute); font-variant-numeric: tabular-nums; }
.table__tags { display: flex; gap: 4px; justify-content: flex-end; }

/* NoWindTecBlock (throws / vertical jumps) drops the Wind column: 5 cols instead of 6. */
.table--nowind .table__head,
.table--nowind .table__row { grid-template-columns: 56px 1fr 110px 110px 80px; }

/* RelayBlock: the athlete cell also stacks the ordered team members under the club. */
.table__relay { font-size: 11.5px; color: var(--fg-mute); margin-top: 4px; line-height: 1.5; }

/* MultiBlock (DEC etc.): 3 fixed columns + one per sub-event, count set via --sub-cols on the
   .table element. width:max-content + min-width:100% makes the row shrink-to-fit its content
   (rather than stretching to the card's width), so this block's own overflow-x:auto wrapper
   scrolls once the sub-event columns exceed available width - the page itself never does. */
.table--multi .table__head,
.table--multi .table__row {
  width: max-content;
  min-width: 100%;
  grid-template-columns: 56px 220px 110px repeat(var(--sub-cols, 10), 84px);
}
.table__sub { text-align: center; font-variant-numeric: tabular-nums; }
.table__sub-mk { font-weight: 700; font-size: 13px; }
.table__sub-pt { font-size: 11px; color: var(--fg-mute); margin-top: 1px; }

/* ============================================================
   Live results
   ============================================================ */
.live-grid {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 22px;
}
.live-grid__col { display: flex; flex-direction: column; gap: 22px; min-width: 0; }

.session {
  background: var(--bg-panel);
  border: 1px solid var(--line-app);
  border-radius: 4px;
  overflow: hidden;
}
.session__head {
  padding: 14px 18px;
  border-bottom: 1px solid var(--line-app);
  display: grid; grid-template-columns: 1fr auto auto; gap: 18px; align-items: center;
}
.session__title {
  display: flex; flex-direction: column; gap: 3px;
}
.session__name { font-weight: 800; font-size: 16px; }
.session__where { font-size: 12px; color: var(--fg-mute); }
.session__meta { display: flex; gap: 14px; align-items: center; color: var(--fg-mute); font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em; }

.heat {
  padding: 14px 18px;
  border-top: 1px solid var(--line-app);
}
.heat__title {
  display: flex; align-items: center; gap: 10px;
  margin-bottom: 12px;
  font-size: 13px; font-weight: 800;
  text-transform: uppercase; letter-spacing: 0.08em;
}
.heat__title .pulse { color: var(--au-red); display: flex; align-items: center; gap: 6px; font-size: 11px; }
.heat__sub { color: var(--fg-mute); font-weight: 600; }
.heat__bars {
  display: flex; flex-direction: column; gap: 6px;
}
.lane {
  display: grid;
  grid-template-columns: 32px 32px 1fr 88px;
  gap: 12px;
  align-items: center;
  padding: 6px 0;
}
.lane__no {
  width: 28px; height: 28px; border-radius: 50%;
  background: var(--bg-panel-2);
  border: 1px solid var(--line-app);
  display: grid; place-items: center;
  font-size: 11px; font-weight: 800;
  font-variant-numeric: tabular-nums;
}
.lane__pos {
  font-weight: 800; font-style: italic;
  font-size: 18px; color: var(--accent);
  letter-spacing: -0.02em;
}
.lane__nm { font-weight: 700; font-size: 14px; }
.lane__cl { font-size: 11.5px; color: var(--fg-mute); margin-top: 1px; }
.lane__bar {
  position: relative;
  height: 6px;
  background: var(--bg-inset);
  border-radius: 999px;
  overflow: hidden;
}
.lane__bar b {
  position: absolute; left: 0; top: 0; bottom: 0;
  background: var(--accent);
  border-radius: 999px;
  transition: width 0.4s var(--ease);
}
.lane__t {
  font-weight: 800; font-style: italic;
  font-size: 17px; text-align: right;
  letter-spacing: -0.015em;
}
.lane.is-leader .lane__no { background: var(--accent); color: #fff; border-color: var(--accent); }

/* Field event ladder */
.ladder { display: flex; flex-direction: column; gap: 8px; padding: 14px 18px; }
.ladder__row {
  display: grid;
  grid-template-columns: 32px 1fr 88px;
  gap: 12px; align-items: center;
  padding: 8px 10px;
  border-radius: 4px;
}
.ladder__row.is-leader { background: var(--accent-soft); }
body.theme-dark .ladder__row.is-leader { background: rgba(240,99,32,0.15); }
.ladder__row .lane__pos { font-size: 16px; }
.ladder__attempts { display: flex; gap: 4px; align-items: center; justify-content: flex-end; }
.attempt {
  width: 20px; height: 20px; border-radius: 4px;
  display: grid; place-items: center;
  font-size: 11px; font-weight: 800;
  font-variant-numeric: tabular-nums;
  background: var(--bg-inset);
  color: var(--fg-mute);
}
.attempt.ok { background: var(--accent); color: #fff; }
.attempt.x { background: var(--au-red); color: #fff; }

/* Schedule rail */
.sched {
  background: var(--bg-panel);
  border: 1px solid var(--line-app);
  border-radius: 4px;
  align-self: start;
  position: sticky; top: calc(var(--topbar-h) + 16px);
}
.sched__row {
  padding: 12px 16px;
  border-bottom: 1px solid var(--line-app);
  display: grid; grid-template-columns: 56px 1fr auto; gap: 12px; align-items: center;
}
.sched__row:last-child { border-bottom: 0; }
.sched__row.is-now { background: var(--accent-soft); }
body.theme-dark .sched__row.is-now { background: rgba(240,99,32,0.12); }
.sched__t {
  font-weight: 800; font-style: italic;
  font-size: 16px;
  letter-spacing: -0.015em;
  font-variant-numeric: tabular-nums;
}
.sched__name { font-size: 13px; font-weight: 700; }
.sched__cat { font-size: 11px; color: var(--fg-mute); margin-top: 1px; }
.sched__status { font-size: 10.5px; font-weight: 800; text-transform: uppercase; letter-spacing: 0.08em; }
.sched__status.is-done { color: var(--fg-mute); }
.sched__status.is-now { color: var(--au-red); }
.sched__status.is-next { color: var(--accent); }

/* ============================================================
   Athlete profile
   ============================================================ */
.ath-hero {
  background: var(--au-ink-deep) url("/assets/triangle-pattern.svg") right -30px center / 120px 104px repeat-y;
  color: #fff;
  border-radius: 4px;
  overflow: hidden;
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
}
body.intensity-high .ath-hero {
  background: var(--accent) url("/assets/triangle-pattern.svg") right -30px center / 120px 104px repeat-y;
}
.ath-hero__photo {
  position: relative;
  min-height: 320px;
  background: linear-gradient(135deg, #4a5568 0%, #2d3748 100%);
  overflow: hidden;
}
.ath-hero__photo::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(0,0,0,0.55) 0%, rgba(0,0,0,0.2) 50%, rgba(0,0,0,0) 100%),
              linear-gradient(180deg, rgba(0,0,0,0.4) 0%, rgba(0,0,0,0) 50%);
}
.ath-hero__photo img { width: 100%; height: 100%; object-fit: cover; }
.ath-hero__copy {
  position: absolute; left: 28px; bottom: 24px; right: 28px;
  z-index: 2;
  color: #fff;
}
.ath-hero__eye { font-size: 11px; font-weight: 800; letter-spacing: 0.14em; text-transform: uppercase; opacity: 0.9; }
.ath-hero__name {
  font-weight: 800; font-style: italic; text-transform: uppercase;
  font-size: clamp(38px, 4vw, 64px); line-height: 0.92;
  letter-spacing: -0.025em;
  margin: 8px 0 6px;
}
.ath-hero__meta { font-size: 14px; opacity: 0.9; display: flex; gap: 18px; }
.ath-hero__meta b { font-weight: 800; }

.ath-hero__side {
  padding: 26px 28px;
  display: flex; flex-direction: column;
  gap: 16px;
  background: rgba(0,0,0,0.25);
  border-left: 1px solid rgba(255,255,255,0.1);
}
.ath-hero__rank {
  display: flex; flex-direction: column; gap: 6px;
}
.ath-hero__rank .num--xxl {
  color: #fff; font-size: 84px; line-height: 0.85;
}
.ath-hero__rank .lbl {
  font-size: 11px; font-weight: 800;
  text-transform: uppercase; letter-spacing: 0.12em;
  opacity: 0.9;
}
.ath-hero__btns { display: flex; gap: 8px; margin-top: auto; }
.ath-hero__btns .btn--p {
  flex: 1;
  background: var(--accent);
  color: var(--accent-on);
}
.ath-hero__btns .btn--g {
  background: rgba(255,255,255,0.08);
  border-color: rgba(255,255,255,0.25);
  color: #fff;
}
.ath-hero__btns .btn--g:hover {
  border-color: #fff; color: #fff;
}

/* Stat-card grid */
.stat-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin-top: 22px;
}

/* 3-up stat card row (Records page recent/oldest/top-holder cards). Was an inline
   grid-template-columns:1fr 1fr 1fr style on the page - moved to a class so the mobile
   media query below can stack it to a single column (inline styles can't be overridden). */
.stat-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  margin-bottom: 22px;
}
.stat {
  background: var(--bg-panel);
  border: 1px solid var(--line-app);
  border-radius: 4px;
  padding: 18px 18px 16px;
  position: relative;
  overflow: hidden;
  min-height: 132px;
  display: flex; flex-direction: column;
  justify-content: space-between;
}
.stat__lbl {
  font-size: 10.5px; font-weight: 800;
  text-transform: uppercase; letter-spacing: 0.12em;
  color: var(--fg-mute);
}
.stat__lbl .em { color: var(--accent); }
.stat__big {
  font-weight: 800; font-style: italic;
  font-size: 42px; line-height: 0.92;
  letter-spacing: -0.025em;
  font-variant-numeric: tabular-nums;
}
.stat__sub {
  font-size: 11.5px; color: var(--fg-mute);
  margin-top: 4px;
  display: flex; align-items: center; gap: 6px;
}
.stat__sub .tag { padding: 2px 5px; font-size: 9px; }
.stat--accent { background: var(--accent); color: #fff; border-color: var(--accent); }
.stat--accent .stat__lbl,
.stat--accent .stat__sub { color: rgba(255,255,255,0.85); }
.stat--accent .stat__lbl .em { color: #fff; }
.stat--ink { background: var(--au-ink-deep); color: #fff; border-color: var(--au-ink-deep); }
.stat--ink .stat__lbl,
.stat--ink .stat__sub { color: rgba(255,255,255,0.7); }
.stat--ink .stat__lbl .em { color: var(--accent); }

/* Profile row */
.profile-row {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 22px;
  margin-top: 22px;
}

/* season progress chart placeholder */
.chart {
  height: 220px;
  position: relative;
  padding: 16px 18px 24px;
}
.chart__grid { position: absolute; inset: 16px 18px 24px; display: flex; flex-direction: column; justify-content: space-between; pointer-events: none; }
.chart__grid b { display: block; height: 1px; background: var(--line-app); }
.chart svg { width: 100%; height: 100%; overflow: visible; }
.chart__axis {
  display: grid; grid-template-columns: repeat(8, 1fr);
  font-size: 10.5px; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.08em;
  color: var(--fg-mute);
  padding: 0 0 0 4px;
}

/* ============================================================
   Records
   ============================================================ */
.rec-cat {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  margin-bottom: 22px;
}
.rec-cat .chip { padding: 9px 14px; font-size: 12px; justify-content: center; text-align: center; }

.rec-tbl {
  background: var(--bg-panel);
  border: 1px solid var(--line-app);
  border-radius: 4px;
  overflow: hidden;
}
.rec-tbl__head {
  display: grid;
  grid-template-columns: 1fr 120px 1.2fr 120px 110px 80px;
  gap: 14px; align-items: center;
  padding: 12px 18px;
  font-size: 11px; font-weight: 800;
  text-transform: uppercase; letter-spacing: 0.1em;
  color: var(--fg-mute);
  border-bottom: 2px solid var(--fg-app);
}
.rec-tbl__row {
  display: grid;
  grid-template-columns: 1fr 120px 1.2fr 120px 110px 80px;
  gap: 14px; align-items: center;
  padding: 14px 18px;
  border-bottom: 1px solid var(--line-app);
}
.rec-tbl__row:last-child { border-bottom: 0; }
.rec-tbl__row:hover { background: var(--bg-panel-2); }
.rec-tbl__row.is-new {
  background: linear-gradient(90deg, rgba(218,56,61,0.08) 0%, transparent 60%);
  border-left: 3px solid var(--au-red);
  padding-left: 15px;
}
.rec-tbl__event { font-weight: 800; font-size: 15px; }
.rec-tbl__event .sub { font-size: 11.5px; color: var(--fg-mute); font-weight: 600; text-transform: uppercase; letter-spacing: 0.06em; margin-top: 2px; }
.rec-tbl__perf { font-weight: 800; font-style: italic; font-size: 22px; letter-spacing: -0.02em; }
.rec-tbl__ath { font-weight: 700; font-size: 14px; }
.rec-tbl__when { font-size: 12.5px; color: var(--fg-mute); }
.rec-tbl__where { font-size: 12.5px; color: var(--fg-mute); }

/* ============================================================
   TAF series / Club competition standings
   ============================================================ */
.series-hero {
  background: var(--au-ink-deep) url("/assets/triangle-pattern.svg") right top / 90px 78px repeat;
  color: #fff;
  border-radius: 4px;
  padding: 28px 30px;
  display: grid; grid-template-columns: 1fr auto; gap: 24px; align-items: center;
  margin-bottom: 22px;
  position: relative;
  overflow: hidden;
}
.series-hero::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(90deg, rgba(0,0,0,0.6), rgba(0,0,0,0));
  z-index: 0;
}
.series-hero > * { position: relative; z-index: 1; }
.series-hero__title {
  font-weight: 800; font-style: italic; text-transform: uppercase;
  font-size: 44px; letter-spacing: -0.025em; line-height: 0.95;
  margin: 0;
}
.series-hero__sub { margin-top: 8px; font-size: 14px; opacity: 0.85; }
.series-hero__progress {
  display: flex; flex-direction: column; align-items: flex-end; gap: 12px;
}
.series-hero__steps { display: flex; gap: 6px; }
.series-step {
  display: flex; flex-direction: column; align-items: center; gap: 6px;
  min-width: 76px;
}
.series-step .dot {
  width: 22px; height: 22px; border-radius: 50%;
  background: rgba(255,255,255,0.15);
  border: 2px solid rgba(255,255,255,0.3);
  display: grid; place-items: center;
  font-size: 11px; font-weight: 800;
  font-variant-numeric: tabular-nums;
}
.series-step.is-done .dot { background: var(--accent); border-color: var(--accent); }
.series-step.is-now .dot { background: #fff; color: var(--accent); border-color: #fff; }
.series-step .lbl { font-size: 10px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; opacity: 0.8; }

.stand {
  background: var(--bg-panel);
  border: 1px solid var(--line-app);
  border-radius: 4px;
  overflow: hidden;
}
.stand__head {
  display: grid;
  grid-template-columns: 56px 1fr repeat(6, 80px);
  gap: 12px; align-items: center;
  padding: 12px 18px;
  font-size: 11px; font-weight: 800;
  text-transform: uppercase; letter-spacing: 0.1em;
  color: var(--fg-mute);
  border-bottom: 2px solid var(--fg-app);
}
.stand__row {
  display: grid;
  grid-template-columns: 56px 1fr repeat(6, 80px);
  gap: 12px; align-items: center;
  padding: 14px 18px;
  border-bottom: 1px solid var(--line-app);
}
.stand__row:last-child { border-bottom: 0; }
.stand__row:hover { background: var(--bg-panel-2); }
.stand__rank {
  font-weight: 800; font-style: italic;
  font-size: 22px;
  letter-spacing: -0.02em;
  color: var(--accent);
  font-variant-numeric: tabular-nums;
}
.stand__row.is-promo .stand__rank { color: var(--accent); }
.stand__row.is-releg .stand__rank { color: var(--au-red); }
.stand__team {
  display: flex; align-items: center; gap: 12px; min-width: 0;
}
.stand__team .av { background: var(--au-navy); }
.stand__nm { font-weight: 800; font-size: 15px; }
.stand__city { font-size: 12px; color: var(--fg-mute); margin-top: 1px; }
.stand__num {
  font-weight: 700; font-size: 14px;
  font-variant-numeric: tabular-nums;
  text-align: right;
}
.stand__num--big {
  font-weight: 800; font-style: italic; font-size: 18px;
  color: var(--accent);
  letter-spacing: -0.015em;
}

/* Form badges (W/L/D-style) — for series: P/Q/F */
.form { display: inline-flex; gap: 3px; }
.form-badge {
  width: 22px; height: 22px;
  display: grid; place-items: center;
  font-size: 10px; font-weight: 800;
  border-radius: 3px;
  background: var(--bg-inset);
  color: var(--fg-mute);
}
.form-badge.w { background: var(--accent); color: #fff; }
.form-badge.p { background: var(--au-navy); color: #fff; }
.form-badge.l { background: var(--bg-inset); color: var(--fg-mute); border: 1px solid var(--line-app); }

/* ============================================================
   Footer
   ============================================================ */
.foot {
  padding: 30px 36px 50px;
  border-top: 1px solid var(--line-app);
  display: flex; align-items: center; justify-content: space-between;
  font-size: 12.5px; color: var(--fg-mute);
}
.foot__links { display: flex; gap: 22px; }
.foot__links a:hover { color: var(--accent); }

/* ============================================================
   Mini KPI strip
   ============================================================ */
.kpi-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0;
  background: var(--bg-panel);
  border: 1px solid var(--line-app);
  border-radius: 4px;
  margin-bottom: 22px;
  overflow: hidden;
}
.kpi {
  padding: 18px 22px;
  border-right: 1px solid var(--line-app);
  display: flex; flex-direction: column; gap: 4px;
}
.kpi:last-child { border-right: 0; }
.kpi__lbl {
  font-size: 10.5px; font-weight: 800;
  text-transform: uppercase; letter-spacing: 0.12em;
  color: var(--fg-mute);
}
.kpi__big {
  font-weight: 800; font-style: italic;
  font-size: 32px; line-height: 1;
  letter-spacing: -0.025em;
  font-variant-numeric: tabular-nums;
}
.kpi__sub { font-size: 12px; color: var(--fg-mute); }
.kpi__sub .em { color: var(--accent); font-weight: 700; }

/* ============================================================
   Bestlists — Stat Console pill bar & pickers
   ============================================================ */
.console-bar {
  position: relative;
  display: flex; align-items: center; gap: 12px;
  margin-bottom: 22px;
  padding: 10px;
  background: var(--bg-panel);
  border: 1px solid var(--line-app);
  border-radius: 6px;
  flex-wrap: wrap;
}
.console-bar__pills { display: flex; gap: 6px; flex-wrap: wrap; flex: 1; min-width: 0; }
.console-bar__tools { display: flex; gap: 6px; align-items: center; }
.console-bar__tools .btn--g { padding: 9px 14px; font-size: 12.5px; }

/* Advanced-filter panel (PerfDB-backed search + toggles + variant) below the console bar. */
.adv-filters { margin: -10px 0 22px; }
.adv-filters__toggle {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 7px 12px; font-size: 12.5px; font-weight: 600;
  color: var(--fg-mute); background: transparent;
  border: 1px solid var(--line-app); border-radius: 6px; cursor: pointer;
}
.adv-filters__toggle:hover { color: var(--fg); }
.adv-filters__toggle .ic, .adv-filters__chev { display: inline-flex; }
.adv-filters__body {
  display: flex; flex-direction: column; gap: 14px;
  margin-top: 10px; padding: 16px;
  background: var(--bg-panel); border: 1px solid var(--line-app); border-radius: 6px;
}
.adv-filters__row { display: flex; flex-wrap: wrap; gap: 18px 24px; align-items: center; }
.adv-filters__row--toggles { row-gap: 6px; }
.adv-filters__search, .adv-filters__variant { min-width: 240px; max-width: 360px; }

/* Results-area loading state while PerfDB is fetching. */
.rank-loading {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 14px; padding: 60px 0; color: var(--fg-mute); font-size: 13px;
}

.cpill-wrap { position: relative; }
.cpill {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 8px 12px 8px 12px;
  border: 1px solid var(--line-app);
  background: var(--bg-app);
  border-radius: 4px;
  font: inherit; color: inherit; cursor: pointer;
  transition: border-color var(--dur-fast) var(--ease), background var(--dur-fast) var(--ease);
}
.cpill:hover { border-color: var(--accent); }
.cpill.is-open { border-color: var(--accent); background: var(--bg-panel-2); }
.cpill__icon {
  width: 28px; height: 28px; border-radius: 4px;
  background: var(--accent-soft);
  color: var(--accent);
  display: grid; place-items: center;
  flex: none;
}
body.theme-dark .cpill__icon { background: rgba(240,99,32,0.15); }
.cpill__txt {
  display: flex; flex-direction: column; gap: 1px;
  text-align: left;
  min-width: 0;
}
.cpill__lab {
  font-size: 9.5px; font-weight: 800;
  text-transform: uppercase; letter-spacing: 0.12em;
  color: var(--fg-mute);
  line-height: 1;
}
.cpill__val {
  font-weight: 800; font-size: 14px;
  letter-spacing: -0.005em;
  margin-top: 4px;
  white-space: nowrap;
}
.cpill__sub {
  font-size: 11px; color: var(--fg-mute);
  margin-top: 1px;
  font-weight: 600;
  white-space: nowrap;
}
.cpill--narrow .cpill__val { font-size: 14px; }
.cpill--narrow .cpill__icon { width: 24px; height: 24px; }

/* --- polish: the trailing chevron is a bare inline <svg> with no width/height, so with no
   box around it it filled the remaining flex space in .cpill (~70px). Ported design uses
   IcChevD size={12} (docs/design/screen-bestlists.jsx) - constrain it here. --- */
.cpill__chev { display: flex; align-items: center; flex: none; color: var(--fg-mute); }
.cpill__chev svg { width: 12px; height: 12px; }
.cpill:hover .cpill__chev { color: var(--accent); }

/* --- polish: Ranglijsten empty/info state used MudBlazor's default blue Alert, which reads
   off-brand next to the app's flat card/border look. Restyle to match .card. --- */
.pg .mud-alert {
  background: var(--bg-panel);
  border: 1px solid var(--line-app);
  border-radius: 4px;
  padding: 14px 16px;
}
.pg .mud-alert .mud-alert-message { color: var(--fg-app); font-size: 13px; }
.pg .mud-alert .mud-alert-icon svg { color: var(--accent); }

/* Popovers */
.pop {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  z-index: 50;
  background: var(--bg-panel);
  border: 1px solid var(--line-strong);
  border-radius: 6px;
  box-shadow: var(--shadow-overlay);
  max-height: 540px;
  display: flex; flex-direction: column;
  overflow: hidden;
}
.pop__head {
  padding: 14px 16px;
  border-bottom: 1px solid var(--line-app);
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px;
}
.pop__title {
  font-size: 11px; font-weight: 800;
  text-transform: uppercase; letter-spacing: 0.12em;
  color: var(--fg-mute);
}
.pop__hint { font-size: 12px; color: var(--fg-mute); }
.pop__search {
  display: flex; align-items: center; gap: 8px;
  border: 1px solid var(--line-app);
  background: var(--bg-app);
  padding: 6px 10px;
  border-radius: 4px;
  color: var(--fg-mute);
  width: 220px;
}
.pop__search input {
  border: 0; background: transparent; outline: none;
  font: 500 13px/1 var(--font-sans); color: var(--fg-app);
  flex: 1; min-width: 0;
}
.pop__body { padding: 12px 16px 16px; overflow-y: auto; }

.dp-group { margin-bottom: 14px; }
.dp-group:last-child { margin-bottom: 0; }
.dp-grp-title {
  font-size: 10.5px; font-weight: 800;
  text-transform: uppercase; letter-spacing: 0.12em;
  color: var(--fg-mute);
  margin-bottom: 8px;
  display: flex; align-items: baseline; gap: 8px;
}
.dp-grp-sub {
  font-size: 10.5px; color: var(--fg-mute);
  font-weight: 600; letter-spacing: 0.04em;
  text-transform: none;
}
.dp-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 6px;
}
.dp-tile {
  display: flex; flex-direction: column; gap: 4px;
  padding: 10px 8px;
  border: 1px solid var(--line-app);
  background: var(--bg-panel);
  border-radius: 4px;
  cursor: pointer;
  text-align: left;
  position: relative;
  transition: all var(--dur-fast) var(--ease);
  min-height: 56px;
}
.dp-tile:hover { border-color: var(--accent); background: var(--bg-panel-2); }
.dp-tile.is-active {
  border-color: var(--accent);
  background: var(--accent);
  color: #fff;
}
.dp-tile__lab {
  font-weight: 800; font-size: 13.5px;
  letter-spacing: -0.005em;
  line-height: 1.1;
}
.dp-tile__pill {
  font-size: 9px; font-weight: 800;
  text-transform: uppercase; letter-spacing: 0.08em;
  color: var(--fg-mute);
}
.dp-tile.is-active .dp-tile__pill { color: rgba(255,255,255,0.85); }

/* Category grid (Senior + Junior + Masters per-row) */
.cat-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 6px;
}
.cat-grid--masters { grid-template-columns: repeat(7, 1fr); }
.cat-tile {
  padding: 10px 8px;
  border: 1px solid var(--line-app);
  background: var(--bg-panel);
  border-radius: 4px;
  cursor: pointer;
  text-align: left;
  transition: all var(--dur-fast) var(--ease);
  display: flex; flex-direction: column; gap: 2px;
  min-height: 54px;
}
.cat-tile:hover { border-color: var(--accent); background: var(--bg-panel-2); }
.cat-tile.is-active {
  border-color: var(--accent);
  background: var(--accent);
  color: #fff;
}
.cat-tile__lab { font-weight: 800; font-size: 13.5px; letter-spacing: -0.005em; }
.cat-tile__age { font-size: 10.5px; color: var(--fg-mute); font-weight: 600; }
.cat-tile.is-active .cat-tile__age { color: rgba(255,255,255,0.85); }

.gender-row { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.gender-tile {
  padding: 16px;
  border: 1px solid var(--line-app);
  background: var(--bg-panel);
  border-radius: 4px;
  cursor: pointer;
  text-align: center;
  font-weight: 800; font-size: 16px;
  font-style: italic;
  text-transform: uppercase;
  letter-spacing: -0.01em;
}
.gender-tile:hover { border-color: var(--accent); }
.gender-tile.is-active {
  background: var(--accent); color: #fff; border-color: var(--accent);
}

/* View toggle (List | Matrix) */
.view-toggle {
  display: inline-flex;
  border: 1px solid var(--line-strong);
  border-radius: 4px;
  overflow: hidden;
  background: var(--bg-panel);
}
.view-toggle__btn {
  background: transparent;
  border: 0;
  padding: 10px 14px;
  font: 700 12.5px/1 var(--font-sans);
  letter-spacing: 0.04em;
  color: var(--fg-mute);
  cursor: pointer;
  display: inline-flex; align-items: center; gap: 6px;
  text-transform: uppercase;
}
.view-toggle__btn.is-active {
  background: var(--accent); color: #fff;
}
/* --- polish: view-toggle icons (@AppIcons.List/.Dashboard) were bare <svg> with no
   width/height, which as a direct flex child renders 0x0 (invisible) - size per design
   (IcList/IcDashboard size={14}). Disabled Matrix button also had no visual affordance
   beyond the native "disabled" attribute, so give it a clear muted/no-pointer state. --- */
.view-toggle__btn .ic { width: 14px; height: 14px; }
.view-toggle__btn:disabled { color: var(--line-strong); cursor: not-allowed; }
.view-toggle__btn:disabled:hover { background: transparent; }

/* ---- Matrix view ---- */
.matrix {
  background: var(--bg-panel);
  border: 1px solid var(--line-app);
  border-radius: 4px;
  overflow: hidden;
}
.matrix__head {
  padding: 16px 18px;
  border-bottom: 1px solid var(--line-app);
  display: flex; align-items: center; justify-content: space-between;
  gap: 18px;
  flex-wrap: wrap;
}
.matrix__title .eye {
  font-size: 10.5px; font-weight: 800;
  text-transform: uppercase; letter-spacing: 0.12em;
  color: var(--accent);
}
.matrix__controls { display: flex; gap: 10px; flex-wrap: wrap; }

.seg {
  display: inline-flex;
  border: 1px solid var(--line-app);
  border-radius: 4px;
  overflow: hidden;
  background: var(--bg-app);
}
.seg--alt { background: var(--bg-panel-2); }
.seg__btn {
  background: transparent; border: 0;
  padding: 7px 10px;
  font: 700 11.5px/1 var(--font-sans);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--fg-mute);
  cursor: pointer;
}
.seg__btn:hover { color: var(--fg-app); }
.seg__btn.is-active { background: var(--accent); color: #fff; }

.matrix__wrap {
  overflow: auto;
  max-height: 70vh;
}
.matrix__tbl {
  border-collapse: separate;
  border-spacing: 0;
  width: 100%;
  font-size: 12.5px;
}
.matrix__tbl thead th {
  position: sticky; top: 0;
  background: var(--bg-panel);
  z-index: 2;
  border-bottom: 2px solid var(--fg-app);
}
.matrix__tbl tbody th.matrix__rowh {
  position: sticky; left: 0;
  background: var(--bg-panel);
  z-index: 1;
  text-align: left;
  border-right: 2px solid var(--fg-app);
}
.matrix__tbl thead th.matrix__rowh {
  position: sticky; left: 0; top: 0; z-index: 3;
}
.matrix__colh {
  padding: 10px 8px;
  min-width: 88px;
  text-align: center;
}
.matrix__colh-lab {
  font-weight: 800; font-size: 12.5px;
  letter-spacing: -0.005em;
}
.matrix__colh-age {
  font-size: 10px; color: var(--fg-mute);
  font-weight: 600;
  margin-top: 2px;
}
.matrix__rowh {
  padding: 10px 14px;
  min-width: 140px;
  text-align: left;
}
.matrix__rowh-lab { font-weight: 800; font-size: 13.5px; }
.matrix__rowh-id  { font-size: 10.5px; color: var(--fg-mute); font-weight: 600; margin-top: 1px; }

.matrix__cell {
  padding: 10px 8px;
  border-bottom: 1px solid var(--line-app);
  border-right: 1px solid var(--line-app);
  cursor: pointer;
  text-align: center;
  transition: background var(--dur-fast) var(--ease);
  vertical-align: top;
}
.matrix__cell:hover { background: var(--bg-panel-2); }
.matrix__cell.is-current {
  background: var(--accent);
  color: #fff;
}
.matrix__perf {
  font-weight: 800; font-style: italic;
  font-size: 14.5px;
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.015em;
}
.matrix__cell.is-current .matrix__perf { color: #fff; }
.matrix__nm {
  font-size: 10.5px;
  color: var(--fg-mute);
  font-weight: 600;
  margin-top: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.matrix__cell.is-current .matrix__nm { color: rgba(255,255,255,0.85); }

.matrix__legend {
  padding: 12px 18px;
  border-top: 1px solid var(--line-app);
  display: flex; align-items: center; justify-content: space-between;
  font-size: 12px;
  color: var(--fg-mute);
}
.matrix__legend-dot {
  display: inline-block;
  width: 10px; height: 10px;
  background: var(--accent);
  border-radius: 2px;
}
.tabs {
  display: flex; gap: 0;
  border-bottom: 1px solid var(--line-app);
  margin-bottom: 22px;
}
.tab {
  background: transparent; border: 0;
  padding: 12px 18px;
  font-weight: 700; font-size: 13px;
  letter-spacing: 0.04em; text-transform: uppercase;
  color: var(--fg-mute);
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  cursor: pointer;
}
.tab:hover { color: var(--fg-app); }
.tab.is-active { color: var(--accent); border-bottom-color: var(--accent); }

/* ============================================================
   Dashboard v2 — "Data sources" box grid
   The customer's tidy box layout, with modern polish.
   ============================================================ */

/* Sticky filter / context bar */
.dash-bar {
  position: sticky;
  top: var(--topbar-h);
  z-index: 20;
  display: flex; align-items: center; gap: 10px;
  flex-wrap: wrap;
  padding: 14px 0 16px;
  margin-bottom: 6px;
  background: var(--bg-app);
  border-bottom: 1px solid var(--line-app);
}
.dash-bar::before {
  /* bleed the sticky background over the page gutter so cards don't peek through */
  content: "";
  position: absolute; left: -36px; right: -36px; top: 0; bottom: -1px;
  background: var(--bg-app);
  border-bottom: 1px solid var(--line-app);
  z-index: -1;
}
.dash-bar__title {
  font-size: 12px; font-weight: 800;
  text-transform: uppercase; letter-spacing: 0.12em;
  color: var(--fg-mute);
  margin-right: 4px;
}
.dash-bar__spacer { flex: 1; }
.dash-pill {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 8px 12px;
  border: 1px solid var(--line-app);
  background: var(--bg-panel);
  border-radius: 999px;
  font: 700 12.5px/1 var(--font-sans);
  color: var(--fg-app);
  cursor: pointer;
  transition: border-color var(--dur-fast) var(--ease), color var(--dur-fast) var(--ease);
  white-space: nowrap;
}
.dash-pill:hover { border-color: var(--accent); color: var(--accent); }
.dash-pill .ic { width: 15px; height: 15px; color: var(--fg-mute); }
.dash-pill:hover .ic { color: var(--accent); }
.dash-pill__lab { color: var(--fg-mute); font-weight: 700; }
.dash-pill__sep { width: 1px; height: 14px; background: var(--line-app); }
.dash-live {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 8px 14px 8px 12px;
  border-radius: 999px;
  background: rgba(218,56,61,0.10);
  color: var(--au-red);
  font: 800 11.5px/1 var(--font-sans);
  letter-spacing: 0.06em; text-transform: uppercase;
}
body.theme-dark .dash-live { background: rgba(218,56,61,0.18); }

.dash-search {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 8px 12px;
  border: 1px solid var(--line-app);
  background: var(--bg-panel);
  border-radius: 999px;
  color: var(--fg-mute);
  min-width: 200px;
}
.dash-search input {
  border: 0; background: transparent; outline: none;
  font: 500 13px/1 var(--font-sans); color: var(--fg-app);
  flex: 1; min-width: 0;
}
.dash-search:focus-within { border-color: var(--accent); }

/* Source grid */
.srcgrid {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  gap: 18px;
  align-items: start;
}
.col-4 { grid-column: span 4; }
.col-8 { grid-column: span 8; }
.col-12 { grid-column: span 12; }
@media (max-width: 1180px) {
  .col-4 { grid-column: span 6; }
  .col-8 { grid-column: span 12; }
}
@media (max-width: 760px) {
  .col-4, .col-8 { grid-column: span 12; }
}

/* Source card */
.src {
  background: var(--bg-panel);
  border: 1px solid var(--line-app);
  border-radius: 12px;
  box-shadow: var(--shadow-1);
  display: flex; flex-direction: column;
  overflow: hidden;
  min-width: 0;
  transition: box-shadow var(--dur-base) var(--ease), border-color var(--dur-base) var(--ease);
}
.src:hover { box-shadow: var(--shadow-2); }
.src__head {
  display: flex; align-items: center; gap: 11px;
  padding: 14px 16px;
}
.src__ic {
  width: 32px; height: 32px; border-radius: 9px;
  background: var(--accent-soft); color: var(--accent);
  display: grid; place-items: center; flex: none;
}
body.theme-dark .src__ic { background: rgba(240,99,32,0.16); }
.src__ic .icon, .src__ic svg { width: 17px; height: 17px; }
.src__title {
  font-size: 12.5px; font-weight: 800;
  text-transform: uppercase; letter-spacing: 0.09em;
  flex: 1; min-width: 0;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.src__badge {
  font-size: 9.5px; font-weight: 800;
  letter-spacing: 0.08em; text-transform: uppercase;
  padding: 4px 9px; border-radius: 999px;
  background: var(--bg-panel-2); color: var(--fg-mute);
  border: 1px solid var(--line-app);
  flex: none;
}
.src__badge--live {
  background: rgba(218,56,61,0.10); color: var(--au-red);
  border-color: transparent; padding-left: 18px; position: relative;
}
.src__badge--live::before {
  content: ""; position: absolute; left: 8px; top: 50%;
  width: 6px; height: 6px; background: var(--au-red); border-radius: 50%;
  transform: translateY(-50%); animation: pulseDot 1.4s infinite;
}
.src__badge--accent { background: var(--accent-soft); color: var(--accent); border-color: transparent; }
body.theme-dark .src__badge--accent { background: rgba(240,99,32,0.16); }
.src__body { flex: 1; }
.src__foot {
  display: flex; align-items: center; justify-content: space-between;
  gap: 10px;
  padding: 13px 16px;
  border-top: 1px solid var(--line-app);
  font-size: 12.5px; font-weight: 700;
  color: var(--accent);
  cursor: pointer;
  transition: background var(--dur-fast) var(--ease);
}
.src__foot:hover { background: var(--accent-soft); }
body.theme-dark .src__foot:hover { background: rgba(240,99,32,0.10); }
.src__foot .ic { width: 14px; height: 14px; transition: transform var(--dur-fast) var(--ease); }
.src__foot:hover .ic { transform: translateX(3px); }
.src__foot > span:first-child { white-space: nowrap; display: inline-flex; align-items: center; gap: 3px; }
.src__foot small { color: var(--fg-mute); font-weight: 600; }

/* Pill tabs inside a card */
.src-tabs {
  display: flex; gap: 6px;
  padding: 0 14px 12px;
  overflow-x: auto;
  scrollbar-width: none;
}
.src-tabs::-webkit-scrollbar { display: none; }
.src-tab {
  padding: 6px 12px; border-radius: 999px;
  font: 700 11.5px/1 var(--font-sans);
  border: 1px solid var(--line-app);
  background: var(--bg-panel); color: var(--fg-mute);
  white-space: nowrap; cursor: pointer;
  transition: all var(--dur-fast) var(--ease);
}
.src-tab:hover { border-color: var(--accent); color: var(--accent); }
.src-tab.is-active { background: var(--accent); color: #fff; border-color: var(--accent); }

/* Inline selects on a card (Ranglijsten) */
.src-selects {
  display: flex; gap: 8px;
  padding: 0 14px 12px;
}
.src-sel {
  flex: 1; min-width: 0;
  font: 600 12.5px/1 var(--font-sans);
  padding: 9px 11px;
  border: 1px solid var(--line-app);
  background: var(--bg-panel); color: var(--fg-app);
  border-radius: 8px; cursor: pointer;
}
.src-sel:focus { outline: 2px solid var(--accent); outline-offset: 1px; border-color: var(--accent); }

/* Compact list row — used by TAF / Ranglijst / Clubs */
.minilist { display: flex; flex-direction: column; }
.minilist__head {
  display: flex; align-items: center; gap: 12px;
  padding: 8px 16px;
  font-size: 10px; font-weight: 800;
  text-transform: uppercase; letter-spacing: 0.1em;
  color: var(--fg-mute);
  border-bottom: 1px solid var(--line-app);
}
.minirow {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 16px;
  border-bottom: 1px solid var(--line-app);
  transition: background var(--dur-fast) var(--ease);
}
.minirow:last-child { border-bottom: 0; }
.minirow:hover { background: var(--bg-panel-2); }
.minirow__rank {
  font-weight: 800; font-style: italic; font-size: 16px;
  color: var(--accent); width: 20px; flex: none;
  font-variant-numeric: tabular-nums; letter-spacing: -0.02em;
}
.minirow__main { flex: 1; min-width: 0; }
.minirow__nm {
  font-weight: 700; font-size: 13.5px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.minirow__sub { font-size: 11px; color: var(--fg-mute); margin-top: 1px; }
.minirow__val {
  font-weight: 800; font-style: italic; font-size: 15px;
  letter-spacing: -0.01em; font-variant-numeric: tabular-nums;
  flex: none; text-align: right;
}
.minirow__date { font-size: 11px; color: var(--fg-mute); width: 58px; flex: none; text-align: right; font-variant-numeric: tabular-nums; }
.minirow .av { width: 28px; height: 28px; font-size: 11px; }
.minirow .av__flag { width: 13px; height: 10px; border-width: 1px; }
.minirow .av__flag b { height: 3.33px; }

/* fade-in when tab/category content swaps.
   Transform-only so the resting state is always visible — even when the
   browser freezes the animation at frame 0 (hidden tab / print / capture). */
@media (prefers-reduced-motion: no-preference) {
  .swap-in { animation: swapIn var(--dur-base) var(--ease); }
}
@keyframes swapIn {
  from { transform: translateY(6px); }
  to   { transform: translateY(0); }
}

/* Result rows (Wedstrijdresultaten) */
.reslist { display: flex; flex-direction: column; }
.resrow {
  display: grid;
  grid-template-columns: 52px 1fr auto auto;
  gap: 14px; align-items: center;
  padding: 13px 16px;
  border-bottom: 1px solid var(--line-app);
  cursor: pointer;
  transition: background var(--dur-fast) var(--ease);
}
.resrow:last-child { border-bottom: 0; }
.resrow:hover { background: var(--bg-panel-2); }
.resrow__date { text-align: center; }
.resrow__date .d {
  font-weight: 800; font-style: italic; font-size: 20px; line-height: 1;
  color: var(--accent); letter-spacing: -0.02em; font-variant-numeric: tabular-nums;
}
.resrow__date .m {
  font-size: 9.5px; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.08em; color: var(--fg-mute); margin-top: 2px;
}
.resrow__nm { font-weight: 700; font-size: 14.5px; }
.resrow__where { font-size: 12px; color: var(--fg-mute); margin-top: 2px; }
.resrow__link {
  font-size: 12.5px; font-weight: 700; color: var(--accent);
  display: inline-flex; align-items: center; gap: 3px; white-space: nowrap;
}
.resrow__link .ic { width: 13px; height: 13px; transition: transform var(--dur-fast) var(--ease); }
.resrow:hover .resrow__link .ic { transform: translateX(3px); }

/* Result type tags */
.rtag {
  font-size: 9.5px; font-weight: 800;
  letter-spacing: 0.06em; text-transform: uppercase;
  padding: 4px 8px; border-radius: 999px; white-space: nowrap;
}
.rtag--nk     { background: var(--au-red); color: #fff; }
.rtag--intl   { background: var(--au-navy); color: #fff; }
.rtag--series { background: #0f8f5e; color: #fff; }
.rtag--comp   { background: var(--accent-soft); color: var(--accent); }
body.theme-dark .rtag--comp { background: rgba(240,99,32,0.18); color: var(--accent); }

/* Records-broken compact (reuse .rec styling, just inside .src) */
.src .rec { padding: 12px 16px; }

/* Recordlijst link rows */
.rllist { display: flex; flex-direction: column; }
.rlrow {
  display: flex; align-items: center; gap: 12px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--line-app);
  cursor: pointer;
  transition: background var(--dur-fast) var(--ease);
}
.rlrow:last-child { border-bottom: 0; }
.rlrow:hover { background: var(--bg-panel-2); }
.rlrow__ic {
  width: 30px; height: 30px; border-radius: 7px; flex: none;
  background: var(--accent); color: #fff;
  display: grid; place-items: center;
  font-weight: 800; font-size: 11px; font-style: italic;
}
.rlrow__main { flex: 1; min-width: 0; }
.rlrow__nm { font-weight: 700; font-size: 13.5px; }
.rlrow__sub { font-size: 11.5px; color: var(--fg-mute); margin-top: 1px; }
.rlrow__chev { color: var(--fg-mute); display: flex; }
.rlrow:hover .rlrow__chev { color: var(--accent); }

/* Section heading for news */
.dash-h {
  display: flex; align-items: baseline; justify-content: space-between;
  margin: 30px 0 14px;
}
.dash-h h3 { margin: 0; font-size: 18px; font-weight: 800; letter-spacing: -0.005em; }
.dash-h a { color: var(--accent); font-weight: 700; font-size: 13px; }

/* ============================================================
   Filter pill dropdown (shared simple popover list)
   ============================================================ */
.filter-opts { display: flex; flex-direction: column; gap: 2px; }
.filter-opt {
  text-align: left;
  padding: 9px 11px;
  border: 0; background: transparent;
  border-radius: 6px;
  font: 600 13.5px/1.2 var(--font-sans);
  color: var(--fg-app);
  cursor: pointer;
  transition: background var(--dur-fast) var(--ease);
}
.filter-opt:hover { background: var(--bg-panel-2); }
.filter-opt.is-active { background: var(--accent); color: #fff; }

/* ============================================================
   Clubcompetitie — poule standings table (laportal-style band)
   ============================================================ */
.clubtbl {
  --club-cols: 70px minmax(0, 1fr) 120px 120px 120px 120px;
  background: var(--bg-panel);
  border: 1px solid var(--line-app);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: var(--shadow-1);
}
.clubtbl__band {
  background: var(--accent); color: #fff;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 13px 18px;
  font-weight: 800; font-style: italic; text-transform: uppercase;
  letter-spacing: 0.01em; font-size: 16px;
  white-space: nowrap;
}
.clubtbl__band .yr { font-variant-numeric: tabular-nums; opacity: 0.92; }
.clubtbl__head {
  display: grid; grid-template-columns: var(--club-cols); gap: 14px;
  padding: 12px 18px 10px;
  border-bottom: 2px solid var(--fg-app);
  font-size: 10px; font-weight: 800;
  text-transform: uppercase; letter-spacing: 0.08em;
  color: var(--accent);
}
.clubtbl__hcell .sub {
  color: var(--fg-mute); font-weight: 700; margin-top: 3px;
  display: block;
}
.clubtbl__num { text-align: right; }
.clubtbl__body { display: flex; flex-direction: column; }
.clubtbl__row {
  display: grid; grid-template-columns: var(--club-cols); gap: 14px;
  align-items: center;
  padding: 12px 18px;
  border-bottom: 1px solid var(--line-app);
  transition: background var(--dur-fast) var(--ease);
  cursor: pointer;
}
.clubtbl__row:last-child { border-bottom: 0; }
.clubtbl__row:nth-child(even) { background: var(--au-orange-tint); }
body.theme-dark .clubtbl__row:nth-child(even) { background: rgba(240,99,32,0.06); }
.clubtbl__row:hover { background: var(--bg-panel-2); }
.clubtbl__rank { line-height: 1; }
.clubtbl__rank b {
  font-weight: 800; font-style: italic; font-size: 20px;
  letter-spacing: -0.02em; font-variant-numeric: tabular-nums;
}
.clubtbl__rank small {
  display: block; margin-top: 3px;
  font-size: 11px; color: var(--fg-mute); font-weight: 600;
  font-variant-numeric: tabular-nums;
}
.clubtbl__team { min-width: 0; }
.clubtbl__team .nm {
  font-weight: 800; font-size: 15px; letter-spacing: -0.005em;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.clubtbl__team .poule {
  font-size: 11px; color: var(--au-navy); font-weight: 700;
  margin-top: 2px; font-variant-numeric: tabular-nums;
}
body.theme-dark .clubtbl__team .poule { color: var(--au-orange-soft); }
.clubtbl__v {
  text-align: right; font-weight: 700; font-size: 14.5px;
  font-variant-numeric: tabular-nums;
}
.clubtbl__v.is-empty { color: var(--fg-mute); opacity: 0.5; }
.clubtbl__total {
  text-align: right;
  font-weight: 800; font-style: italic; font-size: 16px;
  letter-spacing: -0.015em; font-variant-numeric: tabular-nums;
  color: var(--accent);
}
@media (max-width: 720px) {
  .clubtbl { --club-cols: 52px minmax(0,1fr) 96px; }
  .clubtbl__v, .clubtbl__hcell--v { display: none; }
}

/* ============================================================
   Atletenprofiel — index (search + featured + list)
   ============================================================ */
.ath-search {
  display: flex; align-items: center; gap: 12px;
  padding: 14px 18px;
  background: var(--bg-panel);
  border: 1px solid var(--line-app);
  border-radius: 12px;
  box-shadow: var(--shadow-1);
  margin-bottom: 26px;
  transition: border-color var(--dur-fast) var(--ease), box-shadow var(--dur-fast) var(--ease);
}
.ath-search:focus-within { border-color: var(--accent); box-shadow: var(--shadow-2); }
.ath-search .ic { width: 22px; height: 22px; color: var(--accent); flex: none; }
.ath-search input {
  flex: 1; min-width: 0; border: 0; background: transparent; outline: none;
  font: 500 16px/1.2 var(--font-sans); color: var(--fg-app);
}
.ath-search kbd {
  font: 700 11px/1 var(--font-sans);
  color: var(--fg-mute);
  border: 1px solid var(--line-app);
  border-radius: 4px; padding: 5px 7px;
  background: var(--bg-panel-2); flex: none;
}

.afgrid {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px;
  margin-bottom: 8px;
}
@media (max-width: 1080px) { .afgrid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 720px)  { .afgrid { grid-template-columns: 1fr; } }

.afcard {
  text-align: left; border: 1px solid var(--line-app); background: var(--bg-panel);
  border-radius: 12px; overflow: hidden; cursor: pointer; padding: 0;
  box-shadow: var(--shadow-1);
  transition: box-shadow var(--dur-base) var(--ease), transform var(--dur-base) var(--ease);
  display: flex; flex-direction: column;
}
.afcard:hover { box-shadow: var(--shadow-3); transform: translateY(-3px); }
.afcard__photo {
  position: relative; height: 210px; overflow: hidden;
  background: linear-gradient(135deg, #4a5568, #232a36);
}
.afcard__photo img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform 0.5s var(--ease);
}
.afcard:hover .afcard__photo img { transform: scale(1.05); }
.afcard__photo::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,0.05) 30%, rgba(0,0,0,0.82) 100%);
}
.afcard__rank {
  position: absolute; top: 12px; right: 12px; z-index: 2;
  background: var(--accent); color: #fff;
  font-weight: 800; font-style: italic; font-size: 15px;
  padding: 5px 10px; border-radius: 999px;
  display: inline-flex; align-items: baseline; gap: 4px;
}
.afcard__rank small { font-size: 9px; font-style: normal; font-weight: 800; letter-spacing: 0.06em; opacity: 0.85; }
.afcard__copy { position: absolute; left: 16px; right: 16px; bottom: 14px; z-index: 2; color: #fff; }
.afcard__eye { font-size: 10px; font-weight: 800; letter-spacing: 0.12em; text-transform: uppercase; opacity: 0.9; }
.afcard__name {
  font-weight: 800; font-style: italic; text-transform: uppercase;
  font-size: 24px; line-height: 1; letter-spacing: -0.02em; margin: 7px 0 4px;
}
.afcard__disc { font-size: 12.5px; opacity: 0.92; font-weight: 600; }
.afcard__foot {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 16px;
}
.afcard__lbl { font-size: 10px; font-weight: 800; text-transform: uppercase; letter-spacing: 0.1em; color: var(--fg-mute); }
.afcard__val { font-weight: 800; font-style: italic; font-size: 22px; letter-spacing: -0.02em; margin-top: 3px; }
.afcard__club { font-size: 12.5px; color: var(--fg-mute); font-weight: 600; text-align: right; }

.afrows { display: flex; flex-direction: column; }
.afrow {
  display: grid; grid-template-columns: 44px 1fr auto auto; gap: 14px; align-items: center;
  padding: 12px 18px; border-bottom: 1px solid var(--line-app);
  cursor: pointer; transition: background var(--dur-fast) var(--ease);
  width: 100%; text-align: left; border-left: 0; border-right: 0; border-top: 0; background: transparent;
}
.afrow:last-child { border-bottom: 0; }
.afrow:hover { background: var(--bg-panel-2); }
.afrow__nm { font-weight: 700; font-size: 14.5px; }
.afrow__sub { font-size: 12px; color: var(--fg-mute); margin-top: 1px; }
.afrow__rank {
  font-size: 12px; font-weight: 700; color: var(--fg-mute);
  text-align: right; white-space: nowrap;
}
.afrow__rank b { color: var(--accent); font-style: italic; font-size: 16px; }
.afrow__chev { color: var(--fg-mute); display: flex; }
.afrow:hover .afrow__chev { color: var(--accent); }

.afempty { padding: 40px; text-align: center; color: var(--fg-mute); font-size: 14px; }

/* Weltranglijst card table inside profile */
.wr-tbl { display: flex; flex-direction: column; }
.wr-tbl__head, .wr-row {
  display: grid; grid-template-columns: 1fr 80px 90px; gap: 14px; align-items: center;
  padding: 11px 18px;
}
.wr-tbl__head {
  font-size: 10.5px; font-weight: 800; text-transform: uppercase; letter-spacing: 0.08em;
  color: var(--fg-mute); border-bottom: 2px solid var(--fg-app);
}
.wr-row { border-bottom: 1px solid var(--line-app); }
.wr-row:last-child { border-bottom: 0; }
.wr-row:hover { background: var(--bg-panel-2); }
.wr-row__disc { font-weight: 700; font-size: 14px; }
.wr-row__rank { font-weight: 800; font-style: italic; font-size: 17px; text-align: right; letter-spacing: -0.02em; }
.wr-row__rank.is-top { color: var(--accent); }
.wr-row__pts { text-align: right; font-weight: 700; font-variant-numeric: tabular-nums; }
.wr-num-head { text-align: right; }

/* ============================================================
   Resultaten — competitions calendar (Afgerond / Actueel / Aankomende)
   ============================================================ */
.calcols {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px;
  align-items: start;
}
@media (max-width: 1080px) { .calcols { grid-template-columns: 1fr 1fr; } }
@media (max-width: 720px)  { .calcols { grid-template-columns: 1fr; } }

.calcol {
  background: var(--bg-panel);
  border: 1px solid var(--line-app);
  border-radius: 12px; overflow: hidden;
  box-shadow: var(--shadow-1);
}
.calcol__band {
  padding: 13px 16px; color: #fff;
  font-weight: 800; font-style: italic; text-transform: uppercase;
  letter-spacing: 0.02em; font-size: 15px;
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
}
.calcol__band--done { background: var(--accent); }
.calcol__band--live { background: var(--au-ink-deep); }
.calcol__band--up   { background: var(--au-navy); }
.calcol__count {
  font-size: 11px; font-weight: 800; font-style: normal;
  letter-spacing: 0.04em; opacity: 0.9;
  background: rgba(255,255,255,0.16); padding: 3px 9px; border-radius: 999px;
}
.calcol__band--live .calcol__count {
  background: var(--au-red); padding-left: 16px; position: relative;
}
.calcol__band--live .calcol__count::before {
  content: ""; position: absolute; left: 7px; top: 50%;
  width: 6px; height: 6px; border-radius: 50%; background: #fff;
  transform: translateY(-50%); animation: pulseDot 1.4s infinite;
}
.calrow {
  display: grid; grid-template-columns: 88px 1fr auto; gap: 12px; align-items: center;
  padding: 12px 16px;
  border-bottom: 1px solid var(--line-app);
  cursor: pointer; transition: background var(--dur-fast) var(--ease);
}
.calrow:last-child { border-bottom: 0; }
.calrow:hover { background: var(--bg-panel-2); }
.calrow__date {
  font-size: 11.5px; color: var(--fg-mute); font-weight: 700;
  font-variant-numeric: tabular-nums; line-height: 1.3;
}
.calrow__live {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 10.5px; font-weight: 800; text-transform: uppercase;
  letter-spacing: 0.06em; color: var(--au-red);
}
.calrow__main { min-width: 0; }
.calrow__name {
  font-weight: 700; font-size: 13.5px;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.calrow__city { font-size: 11.5px; color: var(--fg-mute); margin-top: 2px; }
.calrow__sub { font-size: 11.5px; color: var(--fg-mute); margin-top: 2px; }
.calrow__sub b { color: var(--accent); font-weight: 800; font-style: italic; }
.calrow__chev { color: var(--fg-mute); display: flex; }
.calrow:hover .calrow__chev { color: var(--accent); }
.calcol__empty { padding: 26px 16px; text-align: center; color: var(--fg-mute); font-size: 13px; }

/* Competition results — embedded in main content area */
.comp-frame-wrap {
  border: 1px solid var(--line-app);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: var(--shadow-1);
  background: var(--bg-panel);
  height: calc(100vh - 210px);
  min-height: 560px;
}
.comp-frame { width: 100%; height: 100%; border: 0; display: block; background: var(--bg-app); }

/* ============================================================
   TAF Series — age-group overview cards + per-meeting table
   ============================================================ */
.taf-band {
  background: var(--accent); color: #fff;
  border-radius: 12px; padding: 16px 22px; text-align: center;
  font-weight: 800; font-style: italic; text-transform: uppercase;
  font-size: 20px; letter-spacing: -0.01em; margin-bottom: 18px;
}
.taf-cards {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; align-items: start;
}
@media (max-width: 1180px) { .taf-cards { grid-template-columns: 1fr 1fr; } }
@media (max-width: 620px)  { .taf-cards { grid-template-columns: 1fr; } }
.taf-card {
  background: var(--bg-panel); border: 1px solid var(--line-app);
  border-radius: 12px; overflow: hidden; box-shadow: var(--shadow-1);
  cursor: pointer; display: flex; flex-direction: column;
  transition: box-shadow var(--dur-base) var(--ease), transform var(--dur-base) var(--ease);
}
.taf-card:hover { box-shadow: var(--shadow-3); transform: translateY(-3px); }
.taf-card__head {
  background: linear-gradient(180deg, var(--au-orange-soft), var(--accent));
  color: #fff; padding: 16px; text-align: center;
  font-weight: 800; font-size: 15.5px;
}
.taf-card__list { padding: 4px 0; flex: 1; }
.taf-row {
  display: grid; grid-template-columns: 28px 1fr auto; gap: 10px; align-items: center;
  padding: 11px 18px; border-bottom: 1px solid var(--line-app);
}
.taf-row:last-child { border-bottom: 0; }
.taf-row__r { font-weight: 800; color: var(--accent); font-variant-numeric: tabular-nums; }
.taf-row__nm {
  font-weight: 600; font-size: 14px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.taf-row__pts { font-weight: 800; font-variant-numeric: tabular-nums; font-size: 15px; }
.taf-card__foot {
  padding: 14px; text-align: center; border-top: 1px solid var(--line-app);
  color: var(--accent); font-weight: 700; font-size: 13.5px;
  transition: background var(--dur-fast) var(--ease);
}
.taf-card:hover .taf-card__foot { background: var(--accent-soft); }
body.theme-dark .taf-card:hover .taf-card__foot { background: rgba(240,99,32,0.1); }

.taf-back {
  display: inline-flex; align-items: center; gap: 5px;
  color: var(--accent); font-weight: 700; font-size: 13px;
  margin-bottom: 14px; cursor: pointer;
  background: transparent; border: 0;
}
.taf-back:hover { color: var(--accent-h); }
.taf-detail-band {
  background: var(--accent); color: #fff;
  border-radius: 12px 12px 0 0; padding: 14px 18px;
  font-weight: 800; font-style: italic; text-transform: uppercase;
  font-size: 16px; letter-spacing: -0.005em;
}
.taf-tblwrap {
  border: 1px solid var(--line-app); border-top: 0;
  border-radius: 0 0 12px 12px; overflow-x: auto;
  background: var(--bg-panel); box-shadow: var(--shadow-1);
}
.taf-tbl { border-collapse: collapse; width: 100%; min-width: 1180px; font-size: 13px; }
.taf-tbl thead th {
  background: var(--accent); color: #fff;
  padding: 12px 14px; text-align: left;
  font-size: 11px; font-weight: 800; letter-spacing: 0.03em;
  vertical-align: top; white-space: normal;
}
.taf-tbl thead th .dt { display: block; font-weight: 600; opacity: 0.85; margin-top: 4px; font-size: 11px; }
.taf-tbl thead th.taf-th-num { text-align: left; min-width: 150px; }
.taf-tbl tbody td { padding: 13px 14px; border-bottom: 1px solid var(--line-app); vertical-align: top; }
.taf-tbl tbody tr:last-child td { border-bottom: 0; }
.taf-tbl tbody tr:hover { background: var(--bg-panel-2); }
.taf-ath { display: flex; align-items: center; gap: 11px; min-width: 190px; }
.taf-medal {
  width: 24px; height: 24px; border-radius: 50%;
  display: grid; place-items: center; font-weight: 800; font-size: 11px; flex: none; color: #fff;
}
.taf-medal--1 { background: #e3a008; }
.taf-medal--2 { background: #9aa0a6; }
.taf-medal--3 { background: #b06a2c; }
.taf-medal--n { background: var(--bg-panel-2); color: var(--fg-mute); border: 1px solid var(--line-app); }
.taf-ath__nm { font-weight: 700; white-space: nowrap; }
.taf-ath__yob { font-size: 11px; color: var(--fg-mute); margin-top: 1px; }
.taf-total { font-weight: 800; font-size: 16px; font-variant-numeric: tabular-nums; white-space: nowrap; }
.taf-total small { display: block; color: var(--accent); font-weight: 700; font-size: 11px; margin-top: 2px; }
.taf-cell { min-width: 140px; }
.taf-cell__pts { font-weight: 800; color: var(--accent); font-variant-numeric: tabular-nums; font-size: 14px; }
.taf-cell__ev { font-size: 11.5px; color: var(--fg-mute); margin-top: 3px; }
.taf-cell__perf { font-size: 12px; color: var(--fg-app); font-weight: 600; margin-top: 2px; font-variant-numeric: tabular-nums; }
.taf-cell--empty { color: var(--fg-mute); opacity: 0.45; font-weight: 700; }

/* ============================================================
   Responsive shell (added for mobile horizontal-overflow fix)
   ------------------------------------------------------------
   Below ~820px the fixed 252px sidebar column leaves too little
   room for `.main` (grid `1fr` track), so page content (kpi
   rows, cards, nowrap labels, etc.) overflows and the whole body
   scrolls horizontally. Collapse `.app` to a single column and
   turn the sidebar into a compact horizontally-scrollable top
   strip instead, so `.main` always gets the full viewport width.
   No JS/interactivity added - this shell stays static SSR.
   Desktop layout (> 820px) is completely unchanged.
   ============================================================ */
@media (max-width: 820px) {
  .app {
    grid-template-columns: 1fr;
  }

  .sb {
    position: static;
    height: auto;
    width: 100%;
    flex-direction: row;
    align-items: center;
    overflow-x: auto;
    border-right: 0;
    border-bottom: 1px solid var(--line-app);
  }

  .sb__brand {
    flex: none;
    padding: 10px 14px;
    border-bottom: 0;
    border-right: 1px solid var(--line-app);
  }

  /* Section labels and the login/locale foot don't fit a compact
     top strip - hide them; the nav items themselves stay reachable. */
  .sb__section,
  .sb__foot {
    display: none;
  }

  .sb__nav {
    flex-direction: row;
    flex: none;
    padding: 0 6px;
  }

  .sb__item {
    white-space: nowrap;
  }

  .sb__item .sb__hint {
    display: none;
  }

  .main {
    min-width: 0;
  }

  /* Let the page title wrap instead of forcing width, and allow the
     header's tool row to wrap onto a second line when it doesn't fit. */
  .ph__title {
    overflow-wrap: break-word;
  }

  .ph__row {
    flex-wrap: wrap;
  }

  /* ----------------------------------------------------------------------
     Wide data tables: contain the scroll inside the table's own box instead
     of letting it push out `.pg`/`.main`/`body`. `.table` (Ranglijsten
     bestlists) lives directly inside `.card`; `.rec-tbl` (Records) and
     `.stand` (club standings) are their own bordered boxes - give all three
     `overflow-x:auto` and pin each grid's row width to the sum of its own
     fixed-px columns (+gaps+padding) plus a workable minimum for its
     flexible 1fr column(s), so columns keep their size and scroll within
     the container rather than overflowing. `.table--multi` (DEC) already
     has its own dedicated overflow-x:auto wrapper with an all-fixed-column
     grid (no 1fr) - untouched here, it already never overflows the page.
     ---------------------------------------------------------------------- */
  .card,
  .rec-tbl,
  .stand {
    overflow-x: auto;
  }

  /* Bestlist table (RunBlock/WindTecBlock): 56px 1fr 110px 110px 70px 80px + 5*16px gap
     + 2*18px padding = 682px; round to 680px so the name column stays legible. */
  .table__head,
  .table__row {
    min-width: 680px;
  }

  /* NoWindTecBlock drops the 70px Wind column (and one 16px gap): 680 - 70 - 16 = 594px. */
  .table--nowind .table__head,
  .table--nowind .table__row {
    min-width: 594px;
  }

  /* Records table: 1fr 120px 1.2fr 120px 110px 80px + 5*14px gap + 2*18px padding, plus
     workable minimums for the Onderdeel/Atleet flexible columns. */
  .rec-tbl__head,
  .rec-tbl__row {
    min-width: 780px;
  }

  /* Club standings: 56px 1fr repeat(6,80px) + 7*12px gap + 2*18px padding, plus a
     workable minimum for the team-name flexible column. */
  .stand__head,
  .stand__row {
    min-width: 820px;
  }

  /* ----------------------------------------------------------------------
     Multi-column card grids: stack to a single column so cards keep their
     readable width instead of being squeezed to a sliver (or overflowing).
     ---------------------------------------------------------------------- */
  .stat-cards,
  .podium {
    grid-template-columns: 1fr;
  }
}
