/* derbyevent.com splash: a night at the derby. Dark asphalt, stadium light, gold from the Gold Rush mark. */

@font-face {
  font-family: "Anton";
  src: url("/splash/fonts/anton-latin-400-normal.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Noto Sans";
  src: url("/splash/fonts/NotoSans-Regular-latin.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Noto Sans";
  src: url("/splash/fonts/NotoSans-Bold-latin.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

:root {
  --asphalt: #0b0b0c;
  --asphalt-2: #111113;
  --panel: #17171a;
  --panel-2: #1e1e22;
  --line: rgba(255, 255, 255, 0.08);
  --line-strong: rgba(255, 255, 255, 0.16);
  --text: #f6f3ec;
  --muted: #b7b1a5;
  --faint: #827d72;
  --gold: #ffd21a;
  --gold-2: #ffb800;
  --gold-deep: #d18b00;
  --gold-soft: rgba(255, 210, 26, 0.12);
  --steel: #c9ccd1;
  --live: #ff4d3d;
  --radius: 18px;
  --radius-sm: 12px;
  --wrap: 1160px;
  --display: "Anton", "Impact", "Haettenschweiler", "Arial Narrow Bold", sans-serif;
  --body: "Noto Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 84px;
  -webkit-text-size-adjust: 100%;
  background: var(--asphalt);
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--asphalt);
  color: var(--text);
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

/* The tilted tape reaches past the edges; clip it without making the page a scroll box. */
html,
body {
  overflow-x: clip;
}

/* A fine grain over everything, like a night photo. */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 100;
  pointer-events: none;
  opacity: 0.07;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0.9 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
}

img,
svg {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
}

h1,
h2,
h3 {
  margin: 0;
  font-weight: 400;
}

p {
  margin: 0;
}

:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 3px;
  border-radius: 6px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.skip {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 200;
  padding: 10px 16px;
  border-radius: 999px;
  background: var(--gold);
  color: #111;
  font-weight: 700;
  text-decoration: none;
  transform: translateY(-200%);
}

.skip:focus {
  transform: none;
}

.wrap {
  width: min(var(--wrap), calc(100% - 40px));
  margin-inline: auto;
}

/* ── Buttons ── */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 48px;
  padding: 12px 22px;
  border: 0;
  border-radius: 999px;
  font: inherit;
  font-weight: 700;
  font-size: 1rem;
  letter-spacing: 0.01em;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: transform 0.18s var(--ease), box-shadow 0.18s var(--ease), background 0.18s var(--ease), color 0.18s var(--ease);
}

.btn svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.4;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: transform 0.18s var(--ease);
}

.btn:hover svg {
  transform: translateX(3px);
}

.btn-gold {
  background: linear-gradient(180deg, #ffe066 0%, var(--gold) 45%, var(--gold-2) 100%);
  color: #141108;
  box-shadow: 0 10px 30px -10px rgba(255, 196, 0, 0.65), inset 0 1px 0 rgba(255, 255, 255, 0.6);
}

.btn-gold:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 36px -12px rgba(255, 196, 0, 0.8), inset 0 1px 0 rgba(255, 255, 255, 0.6);
}

.btn-steel {
  background: linear-gradient(180deg, #ffffff 0%, #dfe2e6 100%);
  color: #15161a;
  box-shadow: 0 10px 30px -14px rgba(255, 255, 255, 0.45), inset 0 1px 0 #fff;
}

.btn-steel:hover {
  transform: translateY(-2px);
}

.btn-ghost {
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  box-shadow: inset 0 0 0 1.5px var(--line-strong);
}

.btn-ghost:hover {
  background: rgba(255, 255, 255, 0.08);
  box-shadow: inset 0 0 0 1.5px rgba(255, 210, 26, 0.6);
}

.btn-lg {
  min-height: 58px;
  padding: 16px 30px;
  font-size: 1.08rem;
}

.btn-sm {
  min-height: 40px;
  padding: 8px 16px;
  font-size: 0.92rem;
}

/* ── Top bar ── */

.topbar {
  position: fixed;
  inset: 0 0 auto;
  z-index: 50;
  padding-top: env(safe-area-inset-top);
  transition: background 0.25s var(--ease), box-shadow 0.25s var(--ease), backdrop-filter 0.25s;
}

.topbar.is-solid {
  background: rgba(11, 11, 12, 0.82);
  box-shadow: 0 1px 0 var(--line);
  -webkit-backdrop-filter: blur(14px) saturate(1.4);
  backdrop-filter: blur(14px) saturate(1.4);
}

.topbar-in {
  display: flex;
  align-items: center;
  gap: 24px;
  width: min(var(--wrap), calc(100% - 32px));
  height: 68px;
  margin-inline: auto;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
}

.brand img {
  width: 40px;
  height: 40px;
  object-fit: contain;
  filter: drop-shadow(0 2px 6px rgba(0, 0, 0, 0.6));
}

.brand span {
  font-family: var(--display);
  font-size: 1.15rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.topnav {
  display: flex;
  gap: 4px;
  margin-left: auto;
}

.topnav a {
  padding: 8px 12px;
  border-radius: 999px;
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 700;
  text-decoration: none;
  transition: color 0.15s, background 0.15s;
}

.topnav a:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.06);
}

/* ── Hero ── */

.hero {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 100svh;
  padding: calc(96px + env(safe-area-inset-top)) 20px 96px;
  overflow: hidden;
  isolation: isolate;
  text-align: center;
  background:
    radial-gradient(120% 70% at 50% 108%, rgba(255, 184, 0, 0.16), transparent 60%),
    linear-gradient(180deg, #050506 0%, #0b0b0c 55%, #0f0e0b 100%);
}

/* Stadium light: a soft gold cone from above, and two light towers off to the sides. */
.hero-light {
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    radial-gradient(42% 36% at 50% 34%, rgba(255, 214, 70, 0.28), transparent 70%),
    conic-gradient(from 180deg at 50% -12%, transparent 0deg 158deg, rgba(255, 233, 160, 0.10) 172deg, rgba(255, 233, 160, 0.16) 180deg, rgba(255, 233, 160, 0.10) 188deg, transparent 202deg 360deg),
    radial-gradient(18% 14% at 4% 4%, rgba(255, 244, 214, 0.18), transparent 70%),
    radial-gradient(18% 14% at 96% 4%, rgba(255, 244, 214, 0.18), transparent 70%);
  animation: breathe 7s ease-in-out infinite;
}

/* The dirt floor at the bottom of the hero. */
.hero::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 32%;
  z-index: -1;
  pointer-events: none;
  background:
    repeating-linear-gradient(100deg, rgba(255, 255, 255, 0.018) 0 2px, transparent 2px 9px),
    linear-gradient(180deg, transparent, rgba(46, 31, 10, 0.45));
  -webkit-mask-image: linear-gradient(180deg, transparent, #000 60%);
  mask-image: linear-gradient(180deg, transparent, #000 60%);
}

.embers {
  position: absolute;
  inset: 0;
  z-index: -1;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.hero-in {
  display: grid;
  justify-items: center;
  gap: 22px;
  width: min(880px, 100%);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  color: var(--gold);
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  animation: rise 0.9s var(--ease) both;
}

.eyebrow-line {
  width: 34px;
  height: 1.5px;
  background: linear-gradient(90deg, transparent, var(--gold));
}

.eyebrow-line:last-child {
  background: linear-gradient(90deg, var(--gold), transparent);
}

.hero-logo {
  width: min(560px, 88vw);
  animation: drop 1.1s var(--ease) 0.1s both;
}

.hero-logo img {
  width: 100%;
  height: auto;
  filter: drop-shadow(0 26px 40px rgba(0, 0, 0, 0.7)) drop-shadow(0 0 60px rgba(255, 200, 0, 0.22));
}

.hero-when {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 8px 16px;
  font-family: var(--display);
  font-size: clamp(1.25rem, 3.6vw, 1.9rem);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  animation: rise 0.9s var(--ease) 0.35s both;
}

.sep {
  width: 7px;
  height: 7px;
  border-radius: 2px;
  background: var(--gold);
  transform: rotate(45deg);
}

/* Countdown */
.countdown {
  display: grid;
  justify-items: center;
  gap: 12px;
  animation: rise 0.9s var(--ease) 0.5s both;
}

.countdown-label {
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  text-wrap: balance;
}

.countdown-clock {
  display: grid;
  grid-template-columns: repeat(4, minmax(64px, 1fr));
  gap: 10px;
}

.countdown-clock > div {
  display: grid;
  justify-items: center;
  padding: 12px 10px 10px;
  border-radius: var(--radius-sm);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.07), rgba(255, 255, 255, 0.02));
  box-shadow: inset 0 0 0 1px var(--line), 0 18px 30px -22px rgba(0, 0, 0, 0.9);
}

.countdown-clock b {
  font-family: var(--display);
  font-weight: 400;
  font-size: clamp(2rem, 7vw, 3.1rem);
  line-height: 1;
  color: var(--gold);
  font-variant-numeric: tabular-nums;
  text-shadow: 0 0 24px rgba(255, 200, 0, 0.35);
}

.countdown-clock span {
  margin-top: 6px;
  color: var(--faint);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.countdown.is-live .countdown-clock {
  display: none;
}

.countdown.is-live .countdown-label {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 18px;
  border-radius: 999px;
  background: rgba(255, 77, 61, 0.12);
  color: #ffd9d4;
  box-shadow: inset 0 0 0 1px rgba(255, 77, 61, 0.35);
}

.countdown.is-live .countdown-label::before {
  content: "";
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--live);
  box-shadow: 0 0 0 0 rgba(255, 77, 61, 0.7);
  animation: pulse 1.6s infinite;
}

.countdown.is-over .countdown-clock {
  display: none;
}

.hero-cta {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-top: 4px;
  animation: rise 0.9s var(--ease) 0.65s both;
}

.hero-note {
  max-width: 520px;
  color: var(--muted);
  font-size: 0.98rem;
  animation: rise 0.9s var(--ease) 0.8s both;
}

.status {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 7px 14px;
  border-radius: 999px;
  background: rgba(52, 211, 132, 0.1);
  color: #b9f3d3;
  font-size: 0.88rem;
  font-weight: 700;
  box-shadow: inset 0 0 0 1px rgba(52, 211, 132, 0.3);
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #34d384;
  box-shadow: 0 0 10px #34d384;
}

.status.is-closed {
  background: rgba(255, 255, 255, 0.06);
  color: var(--muted);
  box-shadow: inset 0 0 0 1px var(--line-strong);
}

.status.is-closed .status-dot {
  background: var(--faint);
  box-shadow: none;
}

.scroll-cue {
  position: absolute;
  bottom: 44px;
  left: 50%;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  margin-left: -22px;
  border-radius: 50%;
  color: var(--muted);
  box-shadow: inset 0 0 0 1.5px var(--line-strong);
  animation: bob 2.4s ease-in-out infinite;
}

.scroll-cue svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ── Caution tape ── */

.tape {
  position: relative;
  z-index: 2;
  overflow: hidden;
  padding: 12px 0;
  background: repeating-linear-gradient(-45deg, var(--gold) 0 22px, #15130c 22px 44px);
  box-shadow: 0 -10px 30px -12px rgba(0, 0, 0, 0.9), 0 10px 30px -12px rgba(0, 0, 0, 0.9);
  transform: rotate(-1.4deg) scale(1.03);
  margin-block: -18px;
}

.tape-track {
  display: flex;
  align-items: center;
  gap: 26px;
  width: max-content;
  padding: 8px 26px;
  background: var(--asphalt);
  font-family: var(--display);
  font-size: 1.15rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  white-space: nowrap;
  animation: marquee 38s linear infinite;
}

.tape-track i {
  color: var(--gold);
  font-style: normal;
}

/* ── Sections ── */

.section {
  position: relative;
  padding: 104px 0;
}

.section-dark {
  background:
    radial-gradient(60% 80% at 100% 0%, rgba(255, 196, 0, 0.06), transparent 60%),
    var(--asphalt-2);
  border-block: 1px solid var(--line);
}

.section-head {
  display: grid;
  gap: 12px;
  max-width: 720px;
  margin-bottom: 44px;
}

.kicker {
  color: var(--gold);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.28em;
  text-transform: uppercase;
}

.section-head h2,
.venue h2,
.final h2,
.lost h1 {
  font-family: var(--display);
  font-size: clamp(2.4rem, 6vw, 4rem);
  line-height: 0.98;
  letter-spacing: 0.01em;
  text-transform: uppercase;
}

.lede {
  color: var(--muted);
  font-size: 1.08rem;
}

/* Reveal on scroll (only when the script runs; without it everything shows). */
.js .reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
}

.js .reveal.is-in {
  opacity: 1;
  transform: none;
}

/* ── Waivers ── */

.waiver-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 340px), 1fr));
  gap: 22px;
}

.waiver-card {
  position: relative;
  display: grid;
  align-content: start;
  gap: 16px;
  padding: 34px 30px 30px;
  border-radius: var(--radius);
  background: linear-gradient(180deg, var(--panel-2), var(--panel));
  box-shadow: inset 0 0 0 1px var(--line), 0 30px 60px -40px rgba(0, 0, 0, 0.9);
  overflow: hidden;
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease);
}

.waiver-card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 4px;
  background: linear-gradient(90deg, var(--gold), var(--gold-2));
}

.waiver-card.is-pit::before {
  background: linear-gradient(90deg, #ffffff, #9aa0a8);
}

.waiver-card::after {
  content: "";
  position: absolute;
  right: -60px;
  top: -60px;
  width: 220px;
  height: 220px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 210, 26, 0.14), transparent 70%);
  pointer-events: none;
}

.waiver-card.is-pit::after {
  background: radial-gradient(circle, rgba(255, 255, 255, 0.09), transparent 70%);
}

.waiver-card:hover {
  transform: translateY(-4px);
  box-shadow: inset 0 0 0 1px rgba(255, 210, 26, 0.32), 0 40px 70px -40px rgba(0, 0, 0, 0.95);
}

.waiver-icon {
  display: grid;
  place-items: center;
  width: 62px;
  height: 62px;
  border-radius: 16px;
  background: var(--gold-soft);
  color: var(--gold);
  box-shadow: inset 0 0 0 1px rgba(255, 210, 26, 0.25);
}

.is-pit .waiver-icon {
  background: rgba(255, 255, 255, 0.06);
  color: var(--steel);
  box-shadow: inset 0 0 0 1px var(--line-strong);
}

.waiver-icon svg {
  width: 34px;
  height: 34px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.4;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.waiver-card h3 {
  font-family: var(--display);
  font-size: 2.1rem;
  line-height: 1;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.waiver-lead {
  color: var(--muted);
  font-size: 1.02rem;
}

.ticks {
  display: grid;
  gap: 10px;
  margin: 4px 0 10px;
  padding: 0;
  list-style: none;
}

.ticks li {
  position: relative;
  padding-left: 30px;
  font-size: 0.98rem;
}

.ticks li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.28em;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--gold-soft) url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ffd21a' stroke-width='3.2' stroke-linecap='round' stroke-linejoin='round'><path d='M6 12.5l4 4 8-9'/></svg>") center / 12px no-repeat;
  box-shadow: inset 0 0 0 1px rgba(255, 210, 26, 0.3);
}

.is-pit .ticks li::before {
  background-color: rgba(255, 255, 255, 0.06);
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23e5e7eb' stroke-width='3.2' stroke-linecap='round' stroke-linejoin='round'><path d='M6 12.5l4 4 8-9'/></svg>");
  box-shadow: inset 0 0 0 1px var(--line-strong);
}

.waiver-card .btn {
  justify-self: start;
}

/* ── Steps ── */

.steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr));
  gap: 18px;
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: none;
}

.steps li {
  position: relative;
  display: grid;
  gap: 10px;
  padding: 28px 26px;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.025);
  box-shadow: inset 0 0 0 1px var(--line);
}

.step-num {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: var(--gold);
  color: #111;
  font-family: var(--display);
  font-size: 1.45rem;
  box-shadow: 0 0 0 6px rgba(255, 210, 26, 0.12);
}

.steps h3 {
  margin-top: 6px;
  font-family: var(--display);
  font-size: 1.55rem;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.steps p {
  color: var(--muted);
}

.aside {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 26px;
  color: var(--muted);
  font-weight: 700;
}

.aside svg {
  width: 22px;
  height: 22px;
  flex: none;
  fill: none;
  stroke: var(--gold);
  stroke-width: 2;
  stroke-linecap: round;
}

/* ── Schedule ── */

/* Five nights side by side need more room than the other sections. */
#schedule .wrap {
  width: min(1320px, calc(100% - 40px));
}

.days {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 14px;
}

.day {
  position: relative;
  display: grid;
  align-content: start;
  gap: 16px;
  padding: 22px 20px 24px;
  border-radius: var(--radius);
  background: linear-gradient(180deg, var(--panel-2), var(--panel));
  box-shadow: inset 0 0 0 1px var(--line);
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease);
}

.day:hover {
  transform: translateY(-3px);
  box-shadow: inset 0 0 0 1px var(--line-strong);
}

.day header {
  display: grid;
  gap: 6px;
  padding-bottom: 14px;
  border-bottom: 1px dashed var(--line-strong);
}

.day-name {
  font-family: var(--display);
  font-size: 1.7rem;
  line-height: 1;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.day-name span {
  display: block;
  margin-top: 4px;
  color: var(--faint);
  font-family: var(--body);
  font-size: 0.86rem;
  font-weight: 700;
  letter-spacing: 0.12em;
}

.day-time {
  justify-self: start;
  padding: 3px 10px;
  border-radius: 999px;
  background: var(--gold-soft);
  color: var(--gold);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  box-shadow: inset 0 0 0 1px rgba(255, 210, 26, 0.25);
}

.day-theme {
  color: var(--steel);
  font-size: 0.86rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.day ul {
  display: grid;
  gap: 9px;
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 0.93rem;
  line-height: 1.4;
}

.day li {
  position: relative;
  padding-left: 14px;
  color: var(--muted);
}

.day li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.55em;
  width: 5px;
  height: 5px;
  border-radius: 1px;
  background: var(--gold);
  transform: rotate(45deg);
}

.day li b {
  color: var(--text);
}

.nw {
  white-space: nowrap;
}

/* Phones only: Tue–Sat buttons over the sideways schedule (built by splash.js). */
.day-tabs {
  display: none;
}

.day li.day-sub {
  padding-left: 14px;
  color: var(--faint);
  font-size: 0.84rem;
}

.day li.day-sub::before {
  display: none;
}

.day.is-finals {
  background:
    radial-gradient(120% 60% at 50% 0%, rgba(255, 210, 26, 0.16), transparent 70%),
    linear-gradient(180deg, #24210f, var(--panel));
  box-shadow: inset 0 0 0 1px rgba(255, 210, 26, 0.38), 0 30px 60px -40px rgba(255, 190, 0, 0.45);
}

.day.is-finals .day-theme {
  color: var(--gold);
}

.day-tonight {
  display: none;
  position: absolute;
  top: -11px;
  right: 16px;
  padding: 3px 11px;
  border-radius: 999px;
  background: var(--live);
  color: #fff;
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  box-shadow: 0 6px 16px -6px rgba(255, 77, 61, 0.8);
}

.day.is-today {
  box-shadow: inset 0 0 0 2px var(--live), 0 30px 60px -40px rgba(255, 77, 61, 0.5);
}

.day.is-today .day-tonight {
  display: block;
}

.day.is-past {
  opacity: 0.55;
}

.fineprint {
  margin-top: 18px;
  color: var(--faint);
  font-size: 0.88rem;
}

/* ── Format ── */

.format-steps {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 0;
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: stage;
}

.format-steps li {
  position: relative;
  display: grid;
  align-content: start;
  gap: 10px;
  padding: 26px 22px 6px 0;
  counter-increment: stage;
}

.format-steps li::before {
  content: counter(stage, decimal-leading-zero);
  color: var(--gold);
  font-family: var(--display);
  font-size: 1rem;
  letter-spacing: 0.12em;
}

/* The road between stages. */
.format-steps li::after {
  content: "";
  position: absolute;
  top: 8px;
  left: 34px;
  right: 10px;
  height: 2px;
  background: repeating-linear-gradient(90deg, rgba(255, 210, 26, 0.5) 0 10px, transparent 10px 18px);
}

.format-steps li:last-child::after {
  display: none;
}

.format-steps b {
  font-family: var(--display);
  font-weight: 400;
  font-size: 1.45rem;
  line-height: 1.05;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.format-steps span {
  color: var(--muted);
  font-size: 0.95rem;
  line-height: 1.5;
}

/* ── Classes ── */

.classes {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 250px), 1fr));
  gap: 12px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.classes li {
  display: grid;
  gap: 4px;
  padding: 20px 22px;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.025);
  box-shadow: inset 0 0 0 1px var(--line);
  transition: box-shadow 0.2s, background 0.2s;
}

.classes li:hover {
  background: rgba(255, 210, 26, 0.05);
  box-shadow: inset 0 0 0 1px rgba(255, 210, 26, 0.32);
}

.classes b {
  font-family: var(--display);
  font-weight: 400;
  font-size: 1.35rem;
  letter-spacing: 0.02em;
  text-transform: uppercase;
}

.classes span {
  color: var(--faint);
  font-size: 0.9rem;
  font-weight: 700;
}

/* ── Venue ── */

.venue {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 40px;
}

.venue > div:first-child {
  display: grid;
  justify-items: start;
  gap: 14px;
}

.venue address {
  color: var(--muted);
  font-size: 1.2rem;
  font-style: normal;
  line-height: 1.5;
}

.venue .btn {
  margin-top: 8px;
}

.venue-dates {
  display: flex;
  gap: 10px;
}

.venue-dates div {
  display: grid;
  justify-items: center;
  width: 82px;
  padding: 12px 0 14px;
  border-radius: var(--radius-sm);
  background: linear-gradient(180deg, var(--panel-2), var(--panel));
  box-shadow: inset 0 0 0 1px var(--line);
}

.venue-dates b {
  color: var(--faint);
  font-size: 0.72rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.venue-dates span {
  font-family: var(--display);
  font-size: 2.6rem;
  line-height: 1.05;
}

.venue-dates i {
  color: var(--muted);
  font-size: 0.8rem;
  font-style: normal;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.venue-dates .is-finals {
  background: linear-gradient(180deg, #2a250f, var(--panel));
  box-shadow: inset 0 0 0 1px rgba(255, 210, 26, 0.45);
}

.venue-dates .is-finals span {
  color: var(--gold);
}

.venue-dates .is-today {
  box-shadow: inset 0 0 0 2px var(--live), 0 14px 30px -16px rgba(255, 77, 61, 0.7);
}

.venue-dates .is-today i {
  color: var(--live);
}

.venue-dates .is-past {
  opacity: 0.45;
}

/* ── FAQ ── */

.faq-list {
  display: grid;
  gap: 10px;
  max-width: 860px;
}

.faq-list details {
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.025);
  box-shadow: inset 0 0 0 1px var(--line);
  transition: background 0.2s, box-shadow 0.2s;
}

.faq-list details[open] {
  background: rgba(255, 255, 255, 0.04);
  box-shadow: inset 0 0 0 1px rgba(255, 210, 26, 0.28);
}

.faq-list summary {
  position: relative;
  padding: 20px 58px 20px 22px;
  font-weight: 700;
  font-size: 1.06rem;
  list-style: none;
  cursor: pointer;
}

.faq-list summary::-webkit-details-marker {
  display: none;
}

.faq-list summary::after {
  content: "";
  position: absolute;
  right: 22px;
  top: 50%;
  width: 22px;
  height: 22px;
  margin-top: -11px;
  border-radius: 50%;
  background: var(--gold-soft) url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ffd21a' stroke-width='3' stroke-linecap='round'><path d='M12 6v12M6 12h12'/></svg>") center / 12px no-repeat;
  transition: transform 0.25s var(--ease);
}

.faq-list details[open] summary::after {
  transform: rotate(45deg);
}

.faq-list details p {
  padding: 0 22px 22px;
  color: var(--muted);
}

.faq-list a {
  color: var(--gold);
  text-underline-offset: 3px;
}

/* ── Final call ── */

.final {
  position: relative;
  padding: 120px 0 130px;
  overflow: hidden;
  text-align: center;
  background:
    radial-gradient(50% 70% at 50% 100%, rgba(255, 196, 0, 0.22), transparent 70%),
    var(--asphalt);
}

.final::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 14px;
  background: repeating-linear-gradient(90deg, #fff 0 14px, #111 14px 28px), repeating-linear-gradient(90deg, #111 0 14px, #fff 14px 28px);
  background-size: 28px 7px;
  background-position: 0 0, 0 7px;
  background-repeat: repeat-x;
  opacity: 0.85;
}

.final-in {
  display: grid;
  justify-items: center;
  gap: 18px;
}

.final p {
  color: var(--muted);
  font-size: 1.12rem;
}

.final .btn {
  margin-top: 10px;
}

/* 404.html, only on the pages.dev address. */
.lost {
  display: grid;
  align-content: center;
  min-height: 100vh;
  min-height: 100dvh;
}

.lost h1 {
  margin: 0;
  font-weight: 400;
}

/* ── Footer ── */

.footer {
  padding: 46px 0 calc(46px + env(safe-area-inset-bottom));
  border-top: 1px solid var(--line);
  background: #070708;
}

.footer-in {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 28px;
}

.footer-brand img {
  width: 72px;
  height: 72px;
  object-fit: contain;
  opacity: 0.9;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 24px;
}

.footer-links a {
  color: var(--muted);
  font-size: 0.94rem;
  font-weight: 700;
  text-decoration: none;
}

.footer-links a:hover {
  color: var(--gold);
}

.footer-copy {
  color: var(--faint);
  font-size: 0.88rem;
}

/* ── Phone dock: a Sign button that stays in reach once the hero is gone ── */

.dock {
  position: fixed;
  inset: auto 0 0;
  z-index: 40;
  display: none;
  padding: 12px 16px calc(12px + env(safe-area-inset-bottom));
  background: linear-gradient(180deg, transparent, rgba(11, 11, 12, 0.92) 38%);
  transform: translateY(110%);
  transition: transform 0.3s var(--ease);
}

.dock .btn {
  width: 100%;
  min-height: 54px;
}

.dock.is-on {
  transform: none;
}

/* ── Motion ── */

@keyframes rise {
  from { opacity: 0; transform: translateY(18px); }
  to { opacity: 1; transform: none; }
}

@keyframes drop {
  from { opacity: 0; transform: translateY(-22px) scale(0.96); }
  to { opacity: 1; transform: none; }
}

@keyframes breathe {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.82; }
}

@keyframes marquee {
  to { transform: translateX(-50%); }
}

@keyframes bob {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(6px); }
}

@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(255, 77, 61, 0.7); }
  70% { box-shadow: 0 0 0 10px rgba(255, 77, 61, 0); }
  100% { box-shadow: 0 0 0 0 rgba(255, 77, 61, 0); }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
  .js .reveal {
    opacity: 1;
    transform: none;
  }
  .embers {
    display: none;
  }
}

/* ── Smaller screens ── */

@media (max-width: 1080px) {
  .days {
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  }
  .format-steps {
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr));
    gap: 8px 22px;
  }
  .format-steps li::after {
    display: none;
  }
}

@media (max-width: 860px) {
  .topnav {
    display: none;
  }
  .topbar-in {
    justify-content: space-between;
  }
  .venue {
    grid-template-columns: 1fr;
  }
  .venue-dates {
    flex-wrap: wrap;
  }
  .footer-in {
    grid-template-columns: 1fr;
    justify-items: start;
  }
}

@media (max-width: 640px) {
  body {
    font-size: 16px;
  }
  .section {
    padding: 76px 0;
  }
  .section-head {
    margin-bottom: 30px;
  }
  .brand img {
    width: 44px;
    height: 44px;
  }
  .brand span {
    font-size: 1rem;
  }
  .hero {
    padding-bottom: 96px;
  }
  .hero-in {
    gap: 18px;
  }
  /* One line each: "Ultimate Derby presents", the date, then the place. */
  .eyebrow {
    gap: 10px;
    font-size: 0.74rem;
    letter-spacing: 0.24em;
  }
  .eyebrow-line {
    width: 18px;
  }
  .hero-when {
    gap: 4px 12px;
  }
  .hero-when > span:first-child {
    flex-basis: 100%;
  }
  .hero-when > .sep:nth-child(2) {
    display: none;
  }
  .countdown-label {
    font-size: 0.8rem;
    letter-spacing: 0.12em;
  }
  .hero-cta {
    width: 100%;
  }
  .hero-cta .btn {
    width: 100%;
  }
  .countdown-clock {
    gap: 8px;
  }
  .countdown-clock > div {
    padding: 10px 6px 8px;
  }
  /* The schedule slides sideways, one night at a time. */
  .days {
    display: flex;
    gap: 12px;
    margin-inline: -20px;
    padding: 12px 20px 8px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
  }
  .days::-webkit-scrollbar {
    display: none;
  }
  .day {
    flex: 0 0 82%;
    scroll-snap-align: center;
  }
  .day-tabs {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 6px;
    margin-bottom: 4px;
    padding: 5px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.03);
    box-shadow: inset 0 0 0 1px var(--line);
  }
  .day-tabs button {
    position: relative;
    min-height: 44px;
    padding: 0;
    border: 0;
    border-radius: 10px;
    background: transparent;
    color: var(--muted);
    font: inherit;
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    cursor: pointer;
    transition: background 0.2s, color 0.2s;
  }
  .day-tabs button[aria-current="true"] {
    background: linear-gradient(180deg, #ffe066, var(--gold) 45%, #ffb800);
    color: #141108;
  }
  .day-tabs button.is-today::after {
    content: "";
    position: absolute;
    top: 6px;
    right: 7px;
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--live);
    box-shadow: 0 0 0 2px var(--asphalt);
  }
  .day-tabs button:focus-visible {
    outline: 2px solid var(--gold);
    outline-offset: 2px;
  }
  /* The bracket's stages run down the page, joined by the same dashed road. */
  .format-steps {
    grid-template-columns: 1fr;
  }
  .format-steps li {
    grid-template-columns: 40px minmax(0, 1fr);
    gap: 4px 16px;
    padding: 0 0 24px;
  }
  .format-steps li::before {
    grid-row: 1 / span 2;
    display: grid;
    place-items: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--gold-soft);
    box-shadow: inset 0 0 0 1px rgba(255, 210, 26, 0.45);
    font-size: 0.95rem;
    letter-spacing: 0.04em;
  }
  .format-steps li::after {
    display: block;
    top: 48px;
    bottom: 6px;
    left: 19px;
    right: auto;
    width: 2px;
    height: auto;
    background: repeating-linear-gradient(180deg, rgba(255, 210, 26, 0.5) 0 8px, transparent 8px 14px);
  }
  .format-steps b {
    padding-top: 9px;
    font-size: 1.3rem;
  }
  .classes {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }
  .classes li {
    padding: 16px 16px 15px;
  }
  .classes li.is-wide {
    grid-column: 1 / -1;
  }
  .classes b {
    font-size: 1.12rem;
    line-height: 1.12;
  }
  .classes span {
    font-size: 0.82rem;
  }
  .waiver-card {
    padding: 28px 22px 24px;
  }
  .waiver-card .btn {
    justify-self: stretch;
  }
  .venue-dates div {
    width: calc((100% - 40px) / 5);
    min-width: 58px;
  }
  .venue-dates span {
    font-size: 2.1rem;
  }
  .dock {
    display: block;
  }
  .final {
    padding: 90px 0 120px;
  }
}

@media (max-width: 360px) {
  .countdown-clock {
    grid-template-columns: repeat(4, minmax(52px, 1fr));
  }
  .hero-when {
    font-size: 1.1rem;
  }
}
