/* Reindeer Derby "Gala Night" theme, layered over race.css. */
@import url("https://fonts.googleapis.com/css2?family=Fredoka:wght@400;500;600;700&family=Oswald:wght@500;600;700&family=Playfair+Display:ital,wght@0,800;0,900;1,800;1,900&display=swap");

/* ================================================================
   Reindeer Derby — "Gala Night" theme
   ================================================================ */
:root {
  --display: "Playfair Display", "Didot", "Bodoni 72", Georgia, serif;
  --label: "Oswald", "Avenir Next Condensed", "Arial Narrow", Impact, sans-serif;
  --gold: #f6c343;
  --gold-2: #ffd977;
  --gold-deep: #a8731c;
  --foil: linear-gradient(180deg, #fffbe9 0%, #ffe9a6 22%, #f6c343 46%, #9c6a17 50%, #e7ae35 60%, #ffe08a 82%, #fff4c9 100%);
  --night: #040817;
  --glass-top: rgba(22, 36, 76, .78);
  --glass-bottom: rgba(7, 12, 32, .9);
  --line: rgba(255, 255, 255, .09);
  --gold-line: rgba(255, 217, 119, .28);
  --dim: rgba(222, 232, 252, .7);
}

body {
  background: var(--night);
  font-family: "Fredoka", system-ui, sans-serif;
}
h1, h2, h3, .festive { font-family: var(--display); }

/* ---------- Night sky: aurora, stars, mountains ---------- */
.sky { position: fixed; inset: 0; z-index: 0; pointer-events: none; overflow: hidden;
  background: linear-gradient(180deg, #02050f 0%, #071232 34%, #13184a 66%, #2a1744 100%); }
.aurora { position: absolute; left: -25%; width: 150%; height: 55vh; filter: blur(46px); mix-blend-mode: screen; will-change: transform; }
.aurora.a1 { top: -14vh; opacity: .75;
  background:
    radial-gradient(ellipse 34% 42% at 26% 62%, rgba(26, 245, 165, .85), transparent 70%),
    radial-gradient(ellipse 30% 30% at 58% 48%, rgba(40, 200, 255, .6), transparent 70%),
    radial-gradient(ellipse 24% 36% at 84% 66%, rgba(30, 230, 150, .55), transparent 70%);
  animation: aurora-a 24s ease-in-out infinite alternate; }
.aurora.a2 { top: -4vh; opacity: .55;
  background:
    radial-gradient(ellipse 30% 30% at 70% 40%, rgba(176, 82, 255, .75), transparent 70%),
    radial-gradient(ellipse 26% 28% at 14% 36%, rgba(255, 70, 160, .4), transparent 70%);
  animation: aurora-b 31s ease-in-out infinite alternate; }
.aurora.a3 { top: 6vh; height: 30vh; opacity: .5;
  background: repeating-linear-gradient(90deg, rgba(60, 255, 190, .0) 0 3%, rgba(60, 255, 190, .35) 4% 5%, rgba(60, 255, 190, 0) 7% 9%);
  -webkit-mask: radial-gradient(ellipse 50% 60% at 45% 30%, #000, transparent 75%);
  mask: radial-gradient(ellipse 50% 60% at 45% 30%, #000, transparent 75%);
  filter: blur(14px);
  animation: aurora-c 18s ease-in-out infinite alternate; }
@keyframes aurora-a { to { transform: translate3d(6%, 4vh, 0) skewY(-5deg) scaleY(1.15); } }
@keyframes aurora-b { from { transform: translate3d(4%, 0, 0) skewY(4deg); } to { transform: translate3d(-8%, 3vh, 0) skewY(-3deg) scaleY(.85); } }
@keyframes aurora-c { to { transform: translate3d(-10%, 2vh, 0) skewX(-12deg); } }

.stars { position: absolute; inset: 0; will-change: opacity;
  background:
    radial-gradient(1.4px 1.4px at 20px 30px, #fff, transparent 60%),
    radial-gradient(1px 1px at 120px 80px, #fff, transparent 60%),
    radial-gradient(1.6px 1.6px at 200px 150px, #fff7d6, transparent 60%),
    radial-gradient(1px 1px at 60px 190px, #cfe3ff, transparent 60%),
    radial-gradient(1.2px 1.2px at 250px 40px, #fff, transparent 60%);
  background-size: 280px 220px;
  -webkit-mask: linear-gradient(180deg, #000 40%, transparent 85%);
  mask: linear-gradient(180deg, #000 40%, transparent 85%);
  animation: stars 3.4s ease-in-out infinite alternate; }
.stars.s2 { background-size: 410px 330px; background-position: 140px 90px; animation-delay: -1.7s; animation-duration: 4.6s; }
@keyframes stars { from { opacity: .35; } to { opacity: 1; } }
.ridge { position: absolute; left: 0; right: 0; bottom: 0; width: 100%; height: 34vh; min-height: 200px; }

/* ---------- Fairy lights ---------- */
.lights { height: 40px; border-top: 2px solid #18261b; filter: saturate(1.15); }
.lights span {
  position: relative; width: 11px; height: 17px; margin-top: 7px;
  border-radius: 50% 50% 50% 50% / 42% 42% 58% 58%;
  background: radial-gradient(circle at 36% 30%, #fff 0 1.6px, var(--b) 4.5px);
  box-shadow: 0 3px 16px 2px var(--b), 0 0 4px var(--b);
}
.lights span::before { content: ""; position: absolute; top: -6px; left: 2.5px; width: 6px; height: 6px; border-radius: 1.5px; background: linear-gradient(#3d4a40, #1b231d); }
.lights span:nth-child(4n+1) { --b: #ff3b47; background: radial-gradient(circle at 36% 30%, #fff 0 1.6px, var(--b) 4.5px); box-shadow: 0 3px 16px 2px var(--b); }
.lights span:nth-child(4n+2) { --b: #ffcf3b; background: radial-gradient(circle at 36% 30%, #fff 0 1.6px, var(--b) 4.5px); box-shadow: 0 3px 16px 2px var(--b); }
.lights span:nth-child(4n+3) { --b: #3bff8a; background: radial-gradient(circle at 36% 30%, #fff 0 1.6px, var(--b) 4.5px); box-shadow: 0 3px 16px 2px var(--b); }
.lights span:nth-child(4n)   { --b: #3bb7ff; background: radial-gradient(circle at 36% 30%, #fff 0 1.6px, var(--b) 4.5px); box-shadow: 0 3px 16px 2px var(--b); }

#snow { z-index: 2; }

/* ---------- Hero ---------- */
html, body { overflow-x: clip; }
.derby-head { padding: 84px 16px 10px; isolation: isolate; overflow-x: clip; }
.derby-head::before {
  content: ""; position: absolute; left: 50%; top: 52%; width: min(1300px, 180vw); aspect-ratio: 1; z-index: -2;
  transform: translate(-50%, -50%);
  background: repeating-conic-gradient(from 0deg, rgba(255, 214, 120, .13) 0 5deg, transparent 5deg 14deg);
  -webkit-mask: radial-gradient(circle, #000 0 12%, transparent 52%);
  mask: radial-gradient(circle, #000 0 12%, transparent 52%);
  animation: rays 120s linear infinite;
}
.derby-head::after {
  content: ""; position: absolute; left: 50%; top: 50%; width: min(900px, 120vw); height: 340px; z-index: -1;
  transform: translate(-50%, -50%);
  background: radial-gradient(ellipse at center, rgba(255, 190, 80, .28), rgba(212, 42, 42, .12) 45%, transparent 70%);
}
@keyframes rays { to { transform: translate(-50%, -50%) rotate(360deg); } }

.kicker { font-family: var(--label); font-weight: 600; letter-spacing: .32em; color: var(--gold-2); }
.derby-head .kicker { display: inline-flex; align-items: center; gap: 14px; font-size: .9rem; }
.derby-head .kicker::before, .derby-head .kicker::after {
  content: ""; width: 64px; height: 10px;
  background:
    radial-gradient(circle, var(--gold-2) 0 2.5px, transparent 3px) center / 10px 10px no-repeat,
    linear-gradient(90deg, transparent, var(--gold-2)) left center / 50px 1.5px no-repeat;
}
.derby-head .kicker::after { transform: scaleX(-1); }

.derby-head h1 {
  position: relative; display: inline-block; isolation: isolate;
  font-family: var(--display); font-style: italic; font-weight: 900;
  font-size: clamp(3.4rem, 10vw, 8.2rem); line-height: .92; letter-spacing: -.01em;
  margin: 12px 0 0; padding: 0 .12em .08em; color: transparent;
  filter: drop-shadow(0 0 28px rgba(255, 196, 80, .35));
}
.derby-head h1::before, .derby-head h1::after {
  content: attr(data-text); position: absolute; inset: 0; padding: inherit; pointer-events: none;
}
.derby-head h1::before {
  color: #6a0d0d;
  text-shadow: 0 1px 0 #8f1515, 0 2px 0 #861313, 0 3px 0 #7c1111, 0 4px 0 #721010, 0 5px 0 #680e0e, 0 6px 0 #5e0c0c,
    0 7px 0 #530a0a, 0 8px 0 #480808, 0 14px 22px rgba(0, 0, 0, .65), 0 24px 50px rgba(0, 0, 0, .5);
}
.derby-head h1::after {
  background:
    linear-gradient(105deg, transparent 42%, rgba(255, 255, 255, .95) 50%, transparent 58%) -150% 0 / 250% 100% no-repeat,
    var(--foil);
  -webkit-background-clip: text; background-clip: text; color: transparent;
  animation: sheen 6s ease-in-out infinite;
}
@keyframes sheen { 0%, 55% { background-position: -150% 0, 0 0; } 100% { background-position: 250% 0, 0 0; } }

.ribbon {
  position: relative; display: inline-block; margin: 6px auto 0; padding: 9px 38px 8px; isolation: isolate;
  font-family: var(--label); font-weight: 600; font-size: clamp(.8rem, 1.6vw, 1rem); letter-spacing: .34em; text-transform: uppercase;
  color: #fff7e0; background: linear-gradient(180deg, #e8403f, #a51b1b);
  box-shadow: inset 0 2px 0 rgba(255, 217, 119, .65), inset 0 -2px 0 rgba(255, 217, 119, .65), 0 10px 24px rgba(0, 0, 0, .45);
  text-shadow: 0 1px 0 rgba(0, 0, 0, .35);
}
.ribbon::before, .ribbon::after {
  content: ""; position: absolute; top: 9px; width: 40px; height: 100%; z-index: -1; background: linear-gradient(180deg, #8f1515, #5e0b0b);
}
.ribbon::before { left: -26px; clip-path: polygon(0 0, 100% 0, 100% 100%, 0 100%, 32% 50%); }
.ribbon::after { right: -26px; clip-path: polygon(0 0, 100% 0, 68% 50%, 100% 100%, 0 100%); }

.derby-head .meta { gap: 12px; margin-top: 22px; }
.derby-head .meta span {
  display: inline-flex; align-items: baseline; gap: 9px; padding: 8px 18px 9px; border-radius: 14px;
  font-family: var(--label); font-weight: 500; font-size: .78rem; letter-spacing: .16em; text-transform: uppercase; color: var(--dim);
  background: linear-gradient(180deg, rgba(20, 32, 70, .75), rgba(6, 12, 30, .8));
  border: 1px solid var(--gold-line); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .08), 0 8px 20px rgba(0, 0, 0, .35);
}
.derby-head .meta b {
  font-family: var(--display); font-style: italic; font-weight: 900; font-size: 1.6rem; letter-spacing: 0; line-height: 1;
  background: var(--foil); -webkit-background-clip: text; background-clip: text; color: transparent;
}

.mute {
  top: 50px; display: grid; place-items: center; font-size: 1.15rem; color: #fff;
  background: linear-gradient(180deg, rgba(30, 46, 90, .85), rgba(8, 14, 34, .9));
  border: 1px solid var(--gold-line); box-shadow: 0 8px 20px rgba(0, 0, 0, .4);
}

/* ---------- Buttons ---------- */
.btn {
  font-family: "Fredoka", sans-serif; border: 1px solid rgba(255, 217, 119, .55);
  background: linear-gradient(180deg, #f25454 0%, #d42a2a 45%, #a71a1a 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .45), inset 0 -3px 0 rgba(0, 0, 0, .18), 0 5px 0 #6e0e0e, 0 14px 30px rgba(0, 0, 0, .45);
  text-shadow: 0 1px 0 rgba(0, 0, 0, .3);
}
.btn.ghost {
  border-color: rgba(255, 255, 255, .2);
  background: linear-gradient(180deg, rgba(255, 255, 255, .1), rgba(255, 255, 255, .03));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .12), 0 6px 16px rgba(0, 0, 0, .3);
}
.btn.big {
  font-family: var(--label); font-weight: 600; text-transform: uppercase; letter-spacing: .14em; font-size: 1.4rem;
  padding: .85em 1.4em; border: 1px solid #ffe08a;
  animation: halo 2.2s ease-out infinite;
}
.btn.big:disabled { animation: none; }
@keyframes halo {
  0% { box-shadow: inset 0 1px 0 rgba(255, 255, 255, .45), inset 0 -3px 0 rgba(0, 0, 0, .18), 0 5px 0 #6e0e0e, 0 14px 30px rgba(0, 0, 0, .45), 0 0 0 0 rgba(255, 90, 90, .55), 0 0 30px rgba(255, 80, 80, .35); }
  70%, 100% { box-shadow: inset 0 1px 0 rgba(255, 255, 255, .45), inset 0 -3px 0 rgba(0, 0, 0, .18), 0 5px 0 #6e0e0e, 0 14px 30px rgba(0, 0, 0, .45), 0 0 0 16px rgba(255, 90, 90, 0), 0 0 30px rgba(255, 80, 80, .35); }
}

/* ---------- Panels ---------- */
.lobby, .broadcast { z-index: 45; }
.lobby { gap: 24px; margin-top: 34px; }
.panel {
  position: relative; overflow: hidden; padding: 30px 22px 22px; border-radius: 24px;
  background: linear-gradient(180deg, var(--glass-top), var(--glass-bottom));
  border: 1px solid var(--gold-line);
  box-shadow: 0 34px 80px rgba(0, 0, 0, .5), inset 0 1px 0 rgba(255, 255, 255, .1), inset 0 0 60px rgba(80, 120, 255, .05);
  backdrop-filter: blur(12px) saturate(1.2);
}
.panel::before {
  content: ""; position: absolute; top: 0; left: 0; right: 0; height: 7px;
  background: repeating-linear-gradient(-45deg, #d42a2a 0 9px, #fff4ec 9px 18px);
  box-shadow: 0 2px 10px rgba(212, 42, 42, .5);
}
.panel::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(ellipse 70% 40% at 50% 0, rgba(255, 210, 110, .12), transparent 70%);
}
.panel > * { position: relative; z-index: 1; }
.panel-head { margin-bottom: 18px; }
.panel-head h2 { font-family: var(--display); font-style: italic; font-weight: 900; font-size: 1.85rem; letter-spacing: 0; gap: 12px; color: #fff8e6; }
.panel-head h2::before { content: none; }
.panel-head p { margin: 6px 0 0 48px; }
.race-info { margin-left: 48px; }
.stepno {
  flex: none; display: grid; place-items: center; width: 36px; height: 36px; border-radius: 50%;
  font-family: var(--label); font-style: normal; font-weight: 700; font-size: 1.05rem; color: #3a2300;
  background: radial-gradient(circle at 35% 30%, #fff3c4, #f6c343 55%, #b8862b);
  box-shadow: 0 0 0 3px rgba(255, 217, 119, .2), 0 4px 12px rgba(0, 0, 0, .4);
}

/* ---------- Race card ---------- */
.runner-grid { gap: 12px; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
.runner-tile {
  position: relative; overflow: hidden; isolation: isolate;
  grid-template-columns: 28px 56px minmax(0, 1fr) auto; gap: 3px 10px; padding: 10px 12px 10px 10px;
  border: 1px solid rgba(255, 255, 255, .08); border-radius: 16px;
  background:
    linear-gradient(105deg, color-mix(in srgb, var(--c) 42%, transparent) 0%, color-mix(in srgb, var(--c) 12%, transparent) 34%, transparent 62%),
    linear-gradient(180deg, rgba(255, 255, 255, .06), rgba(255, 255, 255, .015));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .08), 0 6px 16px rgba(0, 0, 0, .25);
  transition: transform .2s cubic-bezier(.3, 1.4, .5, 1), box-shadow .2s, border-color .2s;
}
.runner-tile::before {
  content: ""; position: absolute; z-index: -1; top: -20%; bottom: -20%; right: -14px; width: 46px; transform: skewX(-18deg);
  background: repeating-linear-gradient(90deg, color-mix(in srgb, var(--c) 30%, transparent) 0 6px, transparent 6px 12px);
  opacity: .6;
}
.runner-tile:hover {
  transform: translateY(-3px) scale(1.01); background-color: transparent;
  border-color: color-mix(in srgb, var(--c) 70%, white 10%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .12), 0 16px 34px rgba(0, 0, 0, .4), 0 0 26px color-mix(in srgb, var(--c) 40%, transparent);
}
.runner-tile.backed {
  border-color: var(--gold);
  box-shadow: inset 0 0 0 1px rgba(255, 217, 119, .5), 0 0 0 1px rgba(246, 195, 67, .6), 0 10px 30px rgba(246, 195, 67, .22);
}
.tile-num {
  width: 28px; height: 34px; border-radius: 7px;
  font-family: var(--label); font-weight: 700; font-size: 1rem;
  background: linear-gradient(180deg, color-mix(in srgb, var(--c) 80%, white 25%), var(--c) 60%, color-mix(in srgb, var(--c) 75%, black));
  border: 1.5px solid rgba(255, 255, 255, .75);
  box-shadow: 0 3px 8px rgba(0, 0, 0, .4), inset 0 1px 0 rgba(255, 255, 255, .4);
  text-shadow: 0 1px 1px rgba(0, 0, 0, .45);
}
.tile-av {
  width: 58px; height: 58px; border: 3px solid var(--c);
  box-shadow: 0 0 0 2px rgba(255, 255, 255, .18), 0 0 18px color-mix(in srgb, var(--c) 55%, transparent);
}
.tile-info b { font-size: 1rem; font-weight: 600; line-height: 1.12; white-space: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.tile-info small { font-size: .76rem; }
.tile-odds {
  font-family: var(--label); font-weight: 700; font-size: .95rem; letter-spacing: .04em; color: #3a2300;
  background: linear-gradient(180deg, #fff1b8, #f6c343 55%, #d8a02c);
  border: 1px solid #fff0b0; padding: 3px 10px; border-radius: 8px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .7), 0 2px 0 #7a520f, 0 6px 12px rgba(0, 0, 0, .35);
}
.tile-backers i {
  font-family: var(--label); font-weight: 600; letter-spacing: .05em; font-size: .7rem;
  background: linear-gradient(180deg, #ec4747, #a51b1b); border: 1px solid rgba(255, 217, 119, .6);
}

/* ---------- Bet slip ---------- */
#players { gap: 10px; }
.player {
  padding: 9px; border-radius: 14px; border: 1px solid rgba(255, 255, 255, .08);
  background:
    linear-gradient(100deg, color-mix(in srgb, var(--c) 34%, transparent), transparent 45%),
    rgba(255, 255, 255, .04);
}
.player.active { border-color: rgba(246, 195, 67, .75); box-shadow: 0 0 0 1px rgba(246, 195, 67, .4), 0 0 24px rgba(246, 195, 67, .15); }
.player input, .player select {
  color: #fff; background: rgba(4, 8, 24, .55); border: 1px solid rgba(255, 255, 255, .16);
  font-weight: 500;
}
.player select option { color: #111; background: #fff; }
.player .bank {
  font-family: var(--label); font-weight: 600; font-size: 1.02rem; letter-spacing: .02em;
}
.bet-actions { margin-top: 14px; }
#startBtn { margin-top: 22px; }

/* ---------- Broadcast ---------- */
.broadcast { margin-top: 40px; }
.onair-bar {
  display: flex; align-items: stretch; gap: 0; margin: 0 auto 14px; overflow: hidden; border-radius: 12px;
  font-family: var(--label); text-transform: uppercase; letter-spacing: .14em; font-size: .82rem;
  background: linear-gradient(180deg, #13214a, #0a1430); border: 1px solid var(--gold-line);
  box-shadow: 0 12px 30px rgba(0, 0, 0, .4);
}
.onair-bar > span { display: flex; align-items: center; gap: 10px; padding: 10px 16px; white-space: nowrap; }
.onair-bar .net { background: linear-gradient(135deg, #d42a2a, #8f1515); clip-path: polygon(0 0, 100% 0, calc(100% - 14px) 100%, 0 100%); padding-right: 30px; font-weight: 500; }
.onair-bar .net small { font-size: inherit; }
.onair-bar .net b { font-family: var(--display); font-style: italic; font-weight: 900; font-size: 1.25rem; letter-spacing: .02em; text-transform: none; color: #ffe08a; }
.onair-bar .prog { flex: 1; min-width: 0; overflow: hidden; color: var(--dim); font-weight: 500; }
.onair-bar .prog b { color: #fff; font-weight: 600; }
.onair-bar .status { font-weight: 700; color: var(--gold-2); padding-right: 72px !important; }
.onair-bar .status i { width: 9px; height: 9px; border-radius: 50%; background: var(--gold-2); box-shadow: 0 0 10px var(--gold-2); }
.onair-bar .status .live { display: none; font-style: normal; }
.onair-bar .status .pre { font-style: normal; }
.broadcast:has(.screen.racing-on) .status { color: #fff; background: #d42a2a; }
.broadcast:has(.screen.racing-on) .status i { background: #fff; box-shadow: 0 0 10px #fff; animation: twinkle .6s infinite alternate; }
.broadcast:has(.screen.racing-on) .status .live { display: inline; }
.broadcast:has(.screen.racing-on) .status .pre { display: none; }

.jumbotron {
  position: relative; padding: 16px; border-radius: 28px;
  background: linear-gradient(180deg, #2b3142 0%, #151925 40%, #0b0e16 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .14), 0 0 0 1px #05070c, 0 0 0 4px rgba(246, 195, 67, .55),
    0 40px 100px rgba(0, 0, 0, .65), 0 0 140px rgba(90, 160, 255, .18);
}
.jumbotron::before {
  content: ""; position: absolute; inset: 4px; border-radius: 25px; pointer-events: none;
  border: 4px dotted #ffe9a8; filter: drop-shadow(0 0 3px #ffc94d) drop-shadow(0 0 7px rgba(255, 190, 60, .7));
  animation: marquee 1.1s steps(2) infinite;
}
@keyframes marquee { 50% { border-color: #fff7d6; filter: drop-shadow(0 0 2px #ffc94d) drop-shadow(0 0 4px rgba(255, 190, 60, .4)); } }
.screen {
  border-radius: 14px; background: #0a1428;
  box-shadow: 0 0 0 2px #04060b, 0 0 0 3px rgba(255, 255, 255, .08), inset 0 0 0 1px rgba(255, 255, 255, .06);
}
.screen::after {
  content: ""; position: absolute; inset: 0; z-index: 2; pointer-events: none;
  background: radial-gradient(ellipse 70% 75% at 40% 50%, transparent 60%, rgba(4, 10, 30, .42) 100%);
}

.infield-logo {
  font-family: var(--display); font-style: italic; font-weight: 900; font-size: 64px;
  fill: url(#goldText); stroke: #5e0b0b; stroke-width: 8px;
}
.infield-sub { font: 600 13px var(--label); letter-spacing: 5px; fill: rgba(255, 246, 214, .92); }

.live-bug {
  font-family: var(--label); font-weight: 700; letter-spacing: .18em; font-size: .85rem;
  background: linear-gradient(180deg, #ec3b3b, #b31d1d); border: 1px solid rgba(255, 255, 255, .35);
  box-shadow: 0 0 20px rgba(255, 60, 60, .55), 0 4px 12px rgba(0, 0, 0, .4);
}

/* ---------- Intro ---------- */
.intro-title h2 { font-family: var(--display); font-style: italic; font-weight: 900; background: var(--foil); -webkit-background-clip: text; background-clip: text; color: transparent; }
.intro-title .kicker { font-size: .85rem; }
.intro-card { border-radius: 20px; border-top: 4px solid var(--c); box-shadow: 0 24px 60px rgba(0, 0, 0, .6), 0 0 40px color-mix(in srgb, var(--c) 30%, transparent); }
.ic-kicker { font-family: var(--label); font-weight: 600; }
.ic-name { font-family: var(--display); font-style: italic; font-weight: 900; }
.ic-odds { font-family: var(--label); }

/* ---------- Commentary booth ---------- */
.booth {
  background:
    repeating-linear-gradient(90deg, rgba(0, 0, 0, .22) 0 4%, rgba(255, 255, 255, .03) 6%, rgba(0, 0, 0, .22) 9%),
    linear-gradient(180deg, #6a1a14 0%, #3d0c08 55%, #1f0503 100%);
  box-shadow: inset 5px 0 0 var(--gold), inset 16px 0 30px rgba(0, 0, 0, .55);
}
.booth::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 30%;
  background: linear-gradient(180deg, transparent, rgba(255, 190, 80, .14)); pointer-events: none;
}
.booth-logo b {
  font-family: var(--display); font-style: italic; font-weight: 900; font-size: 11cqw; letter-spacing: 0;
  background: var(--foil); -webkit-background-clip: text; background-clip: text; color: transparent;
}
.booth-logo span { font-family: var(--label); letter-spacing: .2em; text-transform: uppercase; font-size: 3.6cqw; }
.monitor-caption { font-family: var(--label); font-weight: 600; letter-spacing: .03em; }
.speech { border: 2px solid #ffe08a; box-shadow: 0 8px 20px rgba(0, 0, 0, .5), 0 0 0 4px rgba(0, 0, 0, .15); }

/* ---------- Positions ticker ---------- */
.ticker {
  height: 54px; margin-top: 16px; border-radius: 14px;
  background: linear-gradient(180deg, #172a5a, #0a1430); border: 1px solid var(--gold-line); border-top: 2px solid var(--gold);
  box-shadow: 0 16px 36px rgba(0, 0, 0, .45);
}
.ticker-label {
  font-family: var(--label); font-weight: 700; font-size: .85rem; letter-spacing: .22em; padding: 0 30px 0 20px;
  clip-path: polygon(0 0, 100% 0, calc(100% - 14px) 100%, 0 100%);
}
.chip {
  border-left: 0; border-radius: 9px; font-size: .76rem;
  background: linear-gradient(180deg, rgba(255, 255, 255, .09), rgba(255, 255, 255, .03));
  box-shadow: inset 3px 0 0 var(--c), inset 0 1px 0 rgba(255, 255, 255, .08);
}
.chip.first {
  background: linear-gradient(180deg, rgba(255, 224, 138, .35), rgba(246, 195, 67, .12));
  box-shadow: inset 3px 0 0 var(--gold), inset 0 0 0 1px rgba(255, 217, 119, .55), 0 0 16px rgba(246, 195, 67, .3);
}
.chip .pos { font-family: var(--label); font-size: .95rem; }

/* ---------- Countdown ---------- */
.countdown { font-family: var(--display); font-style: italic; font-weight: 900; }
.countdown span { position: relative; background: var(--foil); -webkit-background-clip: text; background-clip: text; }
.countdown span::before {
  content: ""; position: absolute; left: 50%; top: 52%; width: 1.1em; height: 1.1em; border-radius: 50%;
  border: .05em solid rgba(255, 217, 119, .9); transform: translate(-50%, -50%) scale(.3);
  box-shadow: 0 0 40px rgba(255, 200, 80, .6), inset 0 0 40px rgba(255, 200, 80, .4);
  animation: burst .9s ease-out forwards;
}
@keyframes burst { to { transform: translate(-50%, -50%) scale(1.6); opacity: 0; } }

/* ---------- Results ---------- */
.results { background: radial-gradient(circle at 50% 40%, rgba(40, 24, 70, .7), rgba(2, 5, 16, .88)); overflow: hidden; }
.results::before {
  content: ""; position: absolute; left: 50%; top: 45%; width: 200vmax; height: 200vmax; transform: translate(-50%, -50%);
  background: repeating-conic-gradient(rgba(255, 214, 120, .12) 0 6deg, transparent 6deg 16deg);
  -webkit-mask: radial-gradient(circle, #000 0 8%, transparent 40%); mask: radial-gradient(circle, #000 0 8%, transparent 40%);
  animation: rays 80s linear infinite; pointer-events: none;
}
.results-card {
  position: relative; border-radius: 28px; border: 1px solid rgba(255, 217, 119, .45); border-top: 6px solid var(--gold);
  background: linear-gradient(180deg, rgba(28, 48, 98, .96), rgba(8, 16, 40, .97));
  box-shadow: 0 40px 100px rgba(0, 0, 0, .7), 0 0 80px rgba(255, 196, 80, .2);
}
.results-card h2 { font-family: var(--display); font-style: italic; font-weight: 900; font-size: 3rem; background: var(--foil); -webkit-background-clip: text; background-clip: text; color: transparent; }
.step .who b { font-family: var(--display); font-style: italic; font-weight: 800; font-size: 1.05rem; }
.step .block { border-radius: 14px 14px 0 0; font-family: var(--display); }
.step.p1 .block { background: linear-gradient(180deg, #fff1b8, #f6c343 40%, #b8862b); border-color: #ffe08a; box-shadow: 0 0 30px rgba(246, 195, 67, .45); }
.step.p2 .block { background: linear-gradient(180deg, #ffffff, #c9d3e0 45%, #7f8ea3); border-color: #e9eef5; }
.step.p3 .block { background: linear-gradient(180deg, #ffd6b0, #cd7f32 45%, #7a4615); border-color: #f0b07a; }

@media (max-width: 700px) {
  .derby-head { padding-top: 92px; }
  .panel-head p { margin-left: 0; }
  .race-info { margin-left: 0; }
  .onair-bar .prog { display: none; }
  .onair-bar .net { flex: 1; }
  .onair-bar .net small { display: none; }
  .onair-bar .status { padding-right: 16px !important; }
  .jumbotron { padding: 8px; border-radius: 18px; }
  .jumbotron::before { inset: 2px; border-width: 3px; border-radius: 16px; }
  .derby-head .kicker::before, .derby-head .kicker::after { width: 28px; }
}
@media (prefers-reduced-motion: reduce) {
  .aurora, .stars, .derby-head::before, .derby-head h1::after, .btn.big, .jumbotron::before, .results::before { animation: none !important; }
}
