/* ============================================================
   FLOODLIGHT — IPL live dashboard
   Aesthetic: deep ink-black stadium, saffron floodlights,
   cyan chase indicators, stenciled scoreboard, literary commentary.
   ============================================================ */

:root {
  --ink-0: #07090a;
  --ink-1: #0c1112;
  --ink-2: #131a1c;
  --ink-3: #1a2326;
  --ink-4: #243033;
  --line:  #2b373b;
  --line-soft: #1d272a;

  --bone: #efe7d6;
  --bone-2: #c8c0ae;
  --bone-3: #877f6e;
  --bone-4: #4f4a40;

  --saffron: #ff8a1f;
  --saffron-2: #ffc07a;
  --saffron-glow: #ffaa55;

  --cyan: #4dd0e1;
  --cyan-2: #80e3ee;

  --blood: #e8344c;
  --blood-2: #ff5470;

  --green: #6fbf3e;
  --gold: #d4a838;

  --rad: 2px;
  --rad-lg: 4px;

  --t-fast: 140ms;
  --t-mid:  280ms;
  --t-slow: 600ms;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--ink-0);
  color: var(--bone);
  font-family: "Archivo", system-ui, sans-serif;
  font-size: 14px;
  line-height: 1.4;
  letter-spacing: 0.005em;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body {
  background:
    radial-gradient(120% 70% at 50% -10%, rgba(255, 138, 31, 0.10) 0%, rgba(255, 138, 31, 0.04) 25%, transparent 55%),
    radial-gradient(80% 60% at 50% 110%, rgba(77, 208, 225, 0.05) 0%, transparent 60%),
    repeating-linear-gradient(0deg, transparent 0 47px, rgba(239, 231, 214, 0.014) 47px 48px),
    var(--ink-0);
  overflow-x: hidden;
}

/* film grain layer */
body::before {
  content: "";
  position: fixed; inset: 0;
  pointer-events: none;
  z-index: 1;
  opacity: 0.04;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='220' height='220'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.95' numOctaves='2' stitchTiles='stitch'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
}

/* selection */
::selection { background: var(--saffron); color: var(--ink-0); }

/* ============================================================
   TOP BROADCAST BAR
   ============================================================ */
.bar {
  position: sticky;
  top: 0;
  z-index: 30;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 12px 22px 12px 18px;
  background: linear-gradient(180deg, rgba(7,9,10,0.96) 0%, rgba(7,9,10,0.92) 100%);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.bar-left, .bar-right {
  display: flex; align-items: center; gap: 14px;
  flex-wrap: nowrap;
  min-width: 0;
}
.bar-left { min-width: 0; flex: 1 1 auto; }
.bar-right { flex: 0 0 auto; }

.live {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 5px 10px 5px 9px;
  background: var(--blood);
  color: #fff;
  font-family: "Archivo", sans-serif;
  font-weight: 800;
  font-size: 11px;
  letter-spacing: 0.18em;
  border-radius: var(--rad);
  box-shadow: 0 0 0 1px rgba(232,52,76,0.4), 0 0 20px rgba(232,52,76,0.35);
}
.live.is-off {
  background: var(--ink-3);
  color: var(--bone-3);
  box-shadow: 0 0 0 1px var(--line);
}
.live-dot {
  width: 7px; height: 7px;
  background: #fff;
  border-radius: 50%;
  animation: pulse 1.1s ease-in-out infinite;
}
.live.is-off .live-dot { animation: none; background: var(--bone-3); }

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50%      { opacity: 0.35; transform: scale(0.7); }
}

.bar-rule {
  width: 1px; height: 18px;
  background: var(--line);
}

.bar-meta {
  font-family: "Archivo", sans-serif;
  display: inline-flex; align-items: baseline; gap: 9px;
  min-width: 0;
  overflow: hidden;
}
.bar-series {
  font-weight: 800;
  font-size: 11px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--saffron);
}
.bar-dot { color: var(--bone-4); }
.bar-fixture {
  font-family: "Big Shoulders Display", "Archivo", sans-serif;
  font-weight: 700;
  font-size: 22px;
  letter-spacing: 0.04em;
  color: var(--bone);
  text-transform: uppercase;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.chip {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 10px 6px 9px;
  background: var(--ink-2);
  border: 1px solid var(--line);
  border-radius: var(--rad);
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 11px;
  font-style: normal;
}
.chip-key {
  font-style: normal;
  font-weight: 700;
  letter-spacing: 0.18em;
  color: var(--bone-3);
  font-size: 10px;
}
.chip-val {
  font-style: normal;
  font-weight: 600;
  color: var(--bone);
  font-variant-numeric: tabular-nums;
}

.clock .chip-val { color: var(--saffron-2); }

.bar-stripe {
  position: absolute;
  bottom: -1px;
  right: 0;
  width: 200px;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--saffron) 60%, var(--blood));
}

/* ============================================================
   HERO SCORELINE
   ============================================================ */
.hero {
  position: relative;
  padding: 28px 28px 18px;
  border-bottom: 1px solid var(--line);
  overflow: hidden;
}
.hero-bg {
  position: absolute; inset: 0;
  pointer-events: none;
  z-index: 0;
}
.hero-bg-rays {
  position: absolute;
  inset: -10% -20%;
  background:
    conic-gradient(from 220deg at 80% 0%,
      transparent 0deg,
      rgba(255, 138, 31, 0.08) 8deg,
      transparent 18deg,
      rgba(255, 138, 31, 0.06) 30deg,
      transparent 50deg);
  filter: blur(20px);
  opacity: 0.7;
}
.hero-bg-grain {
  position: absolute; inset: 0;
  background:
    repeating-linear-gradient(90deg, transparent 0 1px, rgba(239, 231, 214, 0.018) 1px 2px, transparent 2px 80px);
}

.hero > * { position: relative; z-index: 1; }

.state-line {
  display: flex; align-items: baseline; gap: 14px;
  margin-bottom: 18px;
}
.state-label {
  font-family: "Archivo", sans-serif;
  font-weight: 800;
  font-size: 10px;
  letter-spacing: 0.32em;
  color: var(--bone-3);
  padding: 4px 8px;
  border: 1px solid var(--line);
  border-radius: 1px;
}
.state-text {
  margin: 0;
  font-family: "Big Shoulders Display", sans-serif;
  font-weight: 700;
  font-size: clamp(20px, 2.4vw, 32px);
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: var(--bone);
}
.state-text em {
  font-style: normal;
  color: var(--saffron);
}

/* scoreline grid */
.scoreline {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 28px;
  align-items: stretch;
  padding: 8px 0 24px;
}

.team {
  position: relative;
  padding: 14px 18px;
  background: linear-gradient(180deg, rgba(19,26,28,0.6) 0%, rgba(7,9,10,0.6) 100%);
  border: 1px solid var(--line);
  border-radius: var(--rad-lg);
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
  transition: border-color var(--t-mid), box-shadow var(--t-mid);
}
.team-l { text-align: left;  border-left: 3px solid var(--saffron); }
.team-r { text-align: right; border-right: 3px solid var(--cyan); }

.team.is-batting {
  border-color: var(--saffron);
  box-shadow:
    0 0 0 1px rgba(255,138,31,0.25),
    0 0 40px rgba(255,138,31,0.15) inset,
    0 0 60px rgba(255,138,31,0.08);
}
.team.is-batting::before {
  content: "BATTING";
  position: absolute;
  top: -1px; right: 14px;
  transform: translateY(-50%);
  font-family: "Archivo", sans-serif;
  font-weight: 800;
  font-size: 9px;
  letter-spacing: 0.3em;
  color: var(--ink-0);
  background: var(--saffron);
  padding: 3px 8px;
  border-radius: 1px;
}
.team-r.is-batting::before { right: auto; left: 14px; }

.team-strap {
  display: flex;
  align-items: baseline;
  gap: 12px;
  font-family: "Big Shoulders Display", sans-serif;
  text-transform: uppercase;
}
.team-r .team-strap { justify-content: flex-end; }

.team-abbr {
  font-weight: 900;
  font-size: 38px;
  letter-spacing: 0.02em;
  color: var(--saffron);
  line-height: 1;
}
.team-r .team-abbr { color: var(--cyan); }

.team-name {
  font-weight: 600;
  font-size: 14px;
  letter-spacing: 0.18em;
  color: var(--bone-2);
}

.team-score {
  display: inline-flex;
  align-items: baseline;
  gap: 6px;
  font-family: "Big Shoulders Display", sans-serif;
  font-weight: 800;
  line-height: 0.9;
  letter-spacing: -0.01em;
  font-variant-numeric: tabular-nums;
}
.team-r .team-score { justify-content: flex-end; }
.team-score .runs {
  font-size: clamp(72px, 10vw, 128px);
  color: var(--bone);
}
.team-score .slash { font-size: clamp(36px, 5vw, 56px); color: var(--bone-3); transform: translateY(-12px); }
.team-score .wkts { font-size: clamp(40px, 5.4vw, 64px); color: var(--bone-2); }

.team-overs {
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-weight: 700;
  font-size: 18px;
  letter-spacing: 0.04em;
  color: var(--bone-2);
  font-variant-numeric: tabular-nums;
}
.team-r .team-overs { text-align: right; }
.ov-unit {
  margin-left: 6px;
  font-family: "Archivo", sans-serif;
  font-weight: 800;
  font-size: 10px;
  letter-spacing: 0.25em;
  color: var(--bone-3);
}

.team-extras {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  gap: 14px;
  font-family: "JetBrains Mono", ui-monospace, monospace;
  font-size: 12px;
  margin-top: auto;
}
.team-r .team-extras { justify-content: flex-end; }
.team-extras li {
  display: inline-flex;
  align-items: baseline;
  gap: 4px;
}
.team-extras i {
  font-style: normal;
  font-weight: 700;
  font-size: 9px;
  letter-spacing: 0.2em;
  color: var(--bone-3);
}
.team-extras b {
  font-weight: 700;
  color: var(--bone);
  font-variant-numeric: tabular-nums;
}

/* center versus column */
.versus {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  min-width: 80px;
  padding: 0 4px;
}
.versus-mark {
  font-family: "Big Shoulders Display", sans-serif;
  font-weight: 900;
  font-size: 56px;
  color: var(--ink-3);
  letter-spacing: 0.04em;
  line-height: 1;
  -webkit-text-stroke: 1px var(--line);
  color: transparent;
}
.innings-pill {
  font-family: "Archivo", sans-serif;
  font-weight: 800;
  font-size: 10px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--saffron);
  background: rgba(255,138,31,0.08);
  border: 1px solid rgba(255,138,31,0.35);
  padding: 6px 10px;
  border-radius: 1px;
  text-align: center;
  white-space: nowrap;
}

/* ============================================================
   GAUGE
   ============================================================ */
.gauge {
  margin-top: 6px;
  padding: 14px 18px;
  background: var(--ink-1);
  border: 1px solid var(--line);
  border-radius: var(--rad-lg);
}
.gauge-head {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 20px;
  margin-bottom: 12px;
  align-items: end;
}
.gauge-cell { display: flex; flex-direction: column; gap: 4px; }
.gauge-cell--center { align-items: center; text-align: center; }
.gauge-cell:last-child { align-items: flex-end; text-align: right; }
.gauge-key {
  font-style: normal;
  font-family: "Archivo", sans-serif;
  font-weight: 800;
  font-size: 10px;
  letter-spacing: 0.28em;
  color: var(--bone-3);
}
.gauge-val {
  font-family: "Big Shoulders Display", sans-serif;
  font-weight: 800;
  font-size: 32px;
  font-variant-numeric: tabular-nums;
  color: var(--bone);
  line-height: 1;
}
.gauge-val--saffron { color: var(--saffron); }
.gauge-val--cyan { color: var(--cyan); }

.gauge-track {
  position: relative;
  height: 14px;
  background: var(--ink-3);
  border: 1px solid var(--line);
  border-radius: 1px;
  overflow: visible;
}
.gauge-fill {
  position: absolute;
  top: 0; bottom: 0; left: 0;
  width: 0%;
  background: linear-gradient(90deg, rgba(255,138,31,0.15) 0%, rgba(255,138,31,0.55) 100%);
  transition: width var(--t-slow) cubic-bezier(.5,0,.2,1);
}
.gauge-rules {
  position: absolute; inset: 0;
  background-image: repeating-linear-gradient(90deg, transparent 0 9.99%, rgba(239,231,214,0.07) 10% 10.05%);
  pointer-events: none;
}
.gauge-tick {
  position: absolute;
  top: -8px; bottom: -8px;
  width: 2px;
  transition: left var(--t-slow) cubic-bezier(.5,0,.2,1);
}
.gauge-tick span {
  position: absolute;
  inset: 0;
  display: block;
}
.gauge-tick--crr { background: var(--saffron); box-shadow: 0 0 12px rgba(255,138,31,0.7); }
.gauge-tick--rrr { background: var(--cyan);    box-shadow: 0 0 12px rgba(77,208,225,0.7); }
.gauge-tick::after {
  content: attr(data-label);
  position: absolute;
  top: -16px;
  left: 50%;
  transform: translateX(-50%);
  font-family: "JetBrains Mono", monospace;
  font-size: 9px;
  font-weight: 700;
  color: var(--bone-3);
  letter-spacing: 0.1em;
  white-space: nowrap;
}

.gauge-foot {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  margin-top: 14px;
  font-family: "JetBrains Mono", monospace;
  font-size: 11px;
}
.gauge-foot span { display: inline-flex; align-items: baseline; gap: 6px; }
.gauge-foot i {
  font-style: normal;
  font-weight: 700;
  font-size: 10px;
  letter-spacing: 0.18em;
  color: var(--bone-3);
}
.gauge-foot b { color: var(--bone); font-weight: 600; font-variant-numeric: tabular-nums; }

/* ============================================================
   GRID OF CARDS
   ============================================================ */
.grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr 1fr;
  grid-template-areas:
    "over    crease  leaders"
    "comm    comm    comm";
  gap: 16px;
  padding: 18px 22px 36px;
}

.card {
  background: linear-gradient(180deg, var(--ink-2) 0%, var(--ink-1) 100%);
  border: 1px solid var(--line);
  border-radius: var(--rad-lg);
  padding: 16px;
  position: relative;
  min-width: 0;
}
.card::before {
  content: "";
  position: absolute;
  top: -1px; left: 14px;
  width: 38px; height: 3px;
  background: var(--saffron);
}

.card--over    { grid-area: over; }
.card--crease  { grid-area: crease; }
.card--leaders { grid-area: leaders; }
.card--comm    { grid-area: comm; min-height: 360px; }

.card-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 14px;
}
.card-title {
  margin: 0;
  font-family: "Big Shoulders Display", sans-serif;
  font-weight: 800;
  font-size: 19px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--bone);
}
.card-meta {
  font-family: "JetBrains Mono", monospace;
  font-size: 11px;
  color: var(--bone-3);
  letter-spacing: 0.06em;
  font-variant-numeric: tabular-nums;
}

/* ============================================================
   THIS OVER — balls strip
   ============================================================ */
.balls {
  list-style: none;
  margin: 0; padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}
.ball {
  width: 44px; height: 44px;
  border-radius: 50%;
  border: 1.5px solid var(--line);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: "Big Shoulders Display", sans-serif;
  font-weight: 800;
  font-size: 16px;
  color: var(--bone-2);
  background: var(--ink-2);
  position: relative;
  transition: transform var(--t-fast) ease, opacity var(--t-fast) ease;
}
.ball.is-new { animation: ball-pop 360ms ease-out; }
@keyframes ball-pop {
  0%   { transform: scale(0.4); opacity: 0; }
  60%  { transform: scale(1.15); opacity: 1; }
  100% { transform: scale(1); opacity: 1; }
}
.ball--dot { color: var(--bone-4); }
.ball--dot::before {
  content: "";
  width: 5px; height: 5px;
  background: var(--bone-4);
  border-radius: 50%;
  display: block;
}
.ball--run { color: var(--bone); }
.ball--four {
  background: var(--saffron-2);
  color: var(--ink-0);
  border-color: var(--saffron-2);
  font-weight: 900;
}
.ball--six {
  background: var(--saffron);
  color: var(--ink-0);
  border-color: var(--saffron);
  font-weight: 900;
  box-shadow: 0 0 0 3px rgba(255,138,31,0.15), 0 0 24px rgba(255,138,31,0.6);
}
.ball--wicket {
  background: var(--blood);
  color: #fff;
  border-color: var(--blood);
  font-weight: 900;
  box-shadow: 0 0 0 3px rgba(232,52,76,0.18), 0 0 22px rgba(232,52,76,0.5);
}
.ball--extra {
  border-style: dashed;
  border-color: var(--cyan);
  color: var(--cyan);
  font-size: 10px;
  letter-spacing: 0.08em;
}
.ball--placeholder {
  border-style: dashed;
  border-color: var(--line-soft);
  background: transparent;
}

.over-summary {
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px dashed var(--line);
  font-family: "Fraunces", serif;
  font-style: italic;
  font-size: 13px;
  color: var(--bone-2);
  line-height: 1.5;
}

/* ============================================================
   AT THE CREASE
   ============================================================ */
.crease {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.batter, .bowler {
  position: relative;
  padding: 12px 14px;
  background: var(--ink-1);
  border: 1px solid var(--line);
  border-radius: var(--rad-lg);
  display: grid;
  grid-template-columns: auto 1fr;
  grid-template-rows: auto auto auto;
  gap: 4px 14px;
  align-items: baseline;
}
.batter-role {
  grid-column: 1; grid-row: 1;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.role-tag {
  font-family: "Archivo", sans-serif;
  font-weight: 800;
  font-size: 9px;
  letter-spacing: 0.28em;
  padding: 2px 6px;
  background: rgba(255,138,31,0.1);
  color: var(--saffron);
  border: 1px solid rgba(255,138,31,0.3);
  border-radius: 1px;
}
.role-tag--cyan {
  background: rgba(77,208,225,0.08);
  color: var(--cyan);
  border-color: rgba(77,208,225,0.3);
}
.batter--ns .role-tag {
  background: rgba(239,231,214,0.04);
  color: var(--bone-2);
  border-color: var(--line);
}
.strike-asterisk {
  font-family: "Big Shoulders Display", sans-serif;
  font-weight: 900;
  color: var(--saffron);
  font-size: 22px;
  line-height: 0.6;
  margin-left: 2px;
  animation: blink 1.4s ease-in-out infinite;
}
@keyframes blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.25; }
}

#striker {
  border-color: rgba(255,138,31,0.4);
  box-shadow: 0 0 0 1px rgba(255,138,31,0.18), inset 0 0 24px rgba(255,138,31,0.06);
}

.batter-name {
  grid-column: 1 / -1; grid-row: 2;
  font-family: "Big Shoulders Display", sans-serif;
  font-weight: 800;
  font-size: 22px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--bone);
}
.batter-figure {
  grid-column: 2; grid-row: 1;
  text-align: right;
  font-family: "Big Shoulders Display", sans-serif;
  font-variant-numeric: tabular-nums;
}
.batter-figure .bf-runs {
  font-weight: 800;
  font-size: 28px;
  color: var(--bone);
  line-height: 1;
}
.batter-figure .bf-balls {
  font-family: "JetBrains Mono", monospace;
  font-size: 12px;
  color: var(--bone-3);
  font-weight: 600;
  margin-left: 4px;
}
.batter-figure--bowl .bf-runs {
  font-size: 22px;
  letter-spacing: 0.04em;
  color: var(--cyan);
}

.batter-stats {
  list-style: none;
  margin: 0; padding: 0;
  grid-column: 1 / -1; grid-row: 3;
  display: flex;
  gap: 16px;
  font-family: "JetBrains Mono", monospace;
  font-size: 11px;
  font-variant-numeric: tabular-nums;
  margin-top: 4px;
}
.batter-stats li { display: inline-flex; align-items: baseline; gap: 4px; }
.batter-stats i {
  font-style: normal;
  font-weight: 700;
  font-size: 9px;
  letter-spacing: 0.2em;
  color: var(--bone-3);
}
.batter-stats b { color: var(--bone); font-weight: 600; }

#bowler {
  border-color: rgba(77,208,225,0.3);
  border-style: dashed;
}

/* ============================================================
   LEADERS
   ============================================================ */
.tabs {
  display: inline-flex;
  background: var(--ink-1);
  border: 1px solid var(--line);
  border-radius: 1px;
  overflow: hidden;
}
.tab {
  appearance: none;
  background: none;
  border: none;
  padding: 6px 10px;
  font-family: "Archivo", sans-serif;
  font-weight: 800;
  font-size: 10px;
  letter-spacing: 0.2em;
  color: var(--bone-3);
  cursor: pointer;
  text-transform: uppercase;
}
.tab.active {
  background: var(--saffron);
  color: var(--ink-0);
}
.tab + .tab { border-left: 1px solid var(--line); }

.leaders {
  list-style: none;
  margin: 0; padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.leader {
  display: grid;
  grid-template-columns: 22px 1fr auto;
  gap: 10px;
  align-items: baseline;
  padding: 8px 10px;
  background: var(--ink-1);
  border: 1px solid var(--line);
  border-left: 2px solid var(--saffron);
  border-radius: 1px;
}
.leader[data-cat="bowl"] { border-left-color: var(--cyan); }
.leader-rank {
  font-family: "Big Shoulders Display", sans-serif;
  font-weight: 900;
  font-size: 18px;
  color: var(--bone-3);
  font-variant-numeric: tabular-nums;
  line-height: 1;
}
.leader-body {
  display: flex; flex-direction: column; gap: 2px;
  min-width: 0;
}
.leader-name {
  font-family: "Big Shoulders Display", sans-serif;
  font-weight: 700;
  font-size: 16px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--bone);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.leader-team {
  font-family: "Archivo", sans-serif;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.18em;
  color: var(--bone-3);
}
.leader-stat {
  font-family: "Big Shoulders Display", sans-serif;
  font-weight: 800;
  font-size: 22px;
  color: var(--saffron);
  font-variant-numeric: tabular-nums;
  line-height: 1;
}
.leader[data-cat="bowl"] .leader-stat { color: var(--cyan); }
.leader-stat-sub {
  display: block;
  font-family: "JetBrains Mono", monospace;
  font-weight: 600;
  font-size: 10px;
  color: var(--bone-3);
  letter-spacing: 0.06em;
  text-align: right;
}

/* ============================================================
   COMMENTARY STREAM
   ============================================================ */
.comm {
  list-style: none;
  margin: 0; padding: 0;
  max-height: 580px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 0;
  scrollbar-width: thin;
  scrollbar-color: var(--line) transparent;
}
.comm::-webkit-scrollbar { width: 6px; }
.comm::-webkit-scrollbar-thumb { background: var(--line); border-radius: 3px; }

.comm-item {
  display: grid;
  grid-template-columns: 78px 56px 1fr auto;
  gap: 12px;
  padding: 12px 6px;
  border-bottom: 1px solid var(--line-soft);
  align-items: start;
  transition: background var(--t-mid);
}
.comm-item.is-new {
  animation: comm-flash 1.6s ease-out;
}
@keyframes comm-flash {
  0%   { background: rgba(255,138,31,0.18); transform: translateY(-6px); opacity: 0; }
  20%  { transform: translateY(0); opacity: 1; }
  100% { background: transparent; }
}

.comm-over {
  font-family: "JetBrains Mono", monospace;
  font-size: 11px;
  font-weight: 700;
  color: var(--bone-3);
  letter-spacing: 0.05em;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.comm-marker {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 44px;
  height: 28px;
  padding: 0 6px;
  border-radius: 1px;
  font-family: "Big Shoulders Display", sans-serif;
  font-weight: 900;
  font-size: 14px;
  letter-spacing: 0.04em;
  background: var(--ink-3);
  color: var(--bone-2);
  border: 1px solid var(--line);
  text-transform: uppercase;
}
.comm-marker--four {
  background: var(--saffron-2);
  color: var(--ink-0);
  border-color: var(--saffron-2);
}
.comm-marker--six {
  background: var(--saffron);
  color: var(--ink-0);
  border-color: var(--saffron);
}
.comm-marker--wkt {
  background: var(--blood);
  color: #fff;
  border-color: var(--blood);
}
.comm-marker--extra {
  background: transparent;
  border-style: dashed;
  border-color: var(--cyan);
  color: var(--cyan);
  font-size: 10px;
}
.comm-marker--dot {
  color: var(--bone-4);
}

.comm-body {
  min-width: 0;
}
.comm-short {
  font-family: "Archivo", sans-serif;
  font-weight: 700;
  font-size: 13px;
  color: var(--bone);
  letter-spacing: 0.005em;
  margin-bottom: 2px;
}
.comm-text {
  font-family: "Fraunces", "Newsreader", Georgia, serif;
  font-style: italic;
  font-size: 13.5px;
  color: var(--bone-2);
  line-height: 1.5;
  font-weight: 400;
}
.comm-dismissal {
  display: inline-block;
  margin-top: 4px;
  font-family: "Big Shoulders Display", sans-serif;
  font-weight: 800;
  font-size: 13px;
  color: var(--blood-2);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.comm-score {
  font-family: "JetBrains Mono", monospace;
  font-size: 11px;
  font-weight: 700;
  color: var(--bone-3);
  text-align: right;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

/* ============================================================
   TICKER (lower third)
   ============================================================ */
.ticker {
  position: sticky;
  bottom: 0;
  z-index: 20;
  background: var(--ink-0);
  border-top: 1px solid var(--saffron);
  overflow: hidden;
  height: 36px;
  display: flex;
  align-items: center;
}
.ticker::before {
  content: "FLOODLIGHT FEED";
  flex: 0 0 auto;
  background: var(--saffron);
  color: var(--ink-0);
  font-family: "Archivo", sans-serif;
  font-weight: 800;
  font-size: 10px;
  letter-spacing: 0.3em;
  padding: 10px 14px;
  height: 100%;
  display: flex;
  align-items: center;
}
.ticker-track {
  display: inline-flex;
  gap: 36px;
  padding-left: 24px;
  white-space: nowrap;
  animation: ticker 60s linear infinite;
  font-family: "Fraunces", serif;
  font-style: italic;
  font-size: 13px;
  color: var(--bone-2);
}
.ticker-track > span { display: inline-flex; align-items: center; gap: 12px; }
.ticker-track > span::after {
  content: "•";
  color: var(--saffron);
  margin-left: 24px;
}
.ticker-track > span:last-child::after { content: ""; }
@keyframes ticker {
  0%   { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}

/* ============================================================
   FLASH OVERLAY (boundary / wicket)
   ============================================================ */
.flash {
  position: fixed; inset: 0;
  pointer-events: none;
  z-index: 50;
  opacity: 0;
}
.flash.is-four {
  animation: flash-saffron 700ms ease-out;
}
.flash.is-six {
  animation: flash-saffron-strong 1100ms ease-out;
}
.flash.is-wkt {
  animation: flash-blood 900ms ease-out;
}
@keyframes flash-saffron {
  0%   { opacity: 0; box-shadow: inset 0 0 0 0 rgba(255,138,31,0); }
  20%  { opacity: 1; box-shadow: inset 0 0 180px 30px rgba(255,138,31,0.55); }
  100% { opacity: 0; box-shadow: inset 0 0 0 0 rgba(255,138,31,0); }
}
@keyframes flash-saffron-strong {
  0%   { opacity: 0; box-shadow: inset 0 0 0 0 rgba(255,138,31,0); }
  15%  { opacity: 1; box-shadow: inset 0 0 240px 60px rgba(255,138,31,0.7); }
  60%  { opacity: 0.6; box-shadow: inset 0 0 200px 40px rgba(255,138,31,0.4); }
  100% { opacity: 0; box-shadow: inset 0 0 0 0 rgba(255,138,31,0); }
}
@keyframes flash-blood {
  0%   { opacity: 0; box-shadow: inset 0 0 0 0 rgba(232,52,76,0); }
  15%  { opacity: 1; box-shadow: inset 0 0 220px 50px rgba(232,52,76,0.6); }
  100% { opacity: 0; box-shadow: inset 0 0 0 0 rgba(232,52,76,0); }
}

/* ============================================================
   CONNECTION INDICATOR
   ============================================================ */
.conn {
  position: fixed;
  right: 16px;
  bottom: 50px;
  z-index: 40;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 10px;
  background: var(--ink-2);
  border: 1px solid var(--line);
  border-radius: 1px;
  font-family: "JetBrains Mono", monospace;
  font-size: 10px;
  letter-spacing: 0.08em;
  color: var(--bone-3);
  text-transform: uppercase;
  opacity: 0.85;
}
.conn-dot {
  width: 6px; height: 6px;
  background: var(--bone-3);
  border-radius: 50%;
}
.conn.is-ok .conn-dot {
  background: var(--green);
  box-shadow: 0 0 6px var(--green);
}
.conn.is-err .conn-dot {
  background: var(--blood);
  box-shadow: 0 0 6px var(--blood);
}
.conn.is-fetching .conn-dot {
  background: var(--saffron);
  animation: pulse 1s ease-in-out infinite;
}

/* ============================================================
   LOADER — full-page broadcast intro
   ============================================================ */
.loader {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  background:
    radial-gradient(60% 50% at 50% 38%, #1d0e05 0%, #0c0706 55%, #000 100%);
  overflow: hidden;
  transition: opacity 750ms cubic-bezier(.5,.05,.2,1),
              transform 750ms cubic-bezier(.5,.05,.2,1),
              filter 750ms ease;
}
.loader.is-out {
  opacity: 0;
  transform: scale(1.08);
  filter: blur(6px);
  pointer-events: none;
}

/* sweeping floodlight cones from top corners */
.loader-rays {
  position: absolute;
  inset: 0;
  background:
    conic-gradient(from 200deg at 92% -8%,
      transparent 0deg,
      rgba(255,138,31,0.22) 10deg,
      transparent 26deg,
      rgba(255,170,90,0.14) 38deg,
      transparent 56deg),
    conic-gradient(from 280deg at 8% -8%,
      transparent 0deg,
      rgba(255,200,140,0.16) 14deg,
      transparent 30deg,
      rgba(255,138,31,0.12) 42deg,
      transparent 58deg);
  filter: blur(38px);
  opacity: 0;
  animation: rays-warm 1400ms ease 200ms forwards, rays-pulse 4s ease-in-out 1.5s infinite;
}
@keyframes rays-warm {
  0%   { opacity: 0; }
  100% { opacity: 0.95; }
}
@keyframes rays-pulse {
  0%, 100% { opacity: 0.7; }
  50%      { opacity: 1; }
}

/* faint stadium grid */
.loader-grid {
  position: absolute;
  inset: 0;
  background:
    repeating-linear-gradient(0deg,  transparent 0 39px, rgba(239,231,214,0.022) 39px 40px),
    repeating-linear-gradient(90deg, transparent 0 79px, rgba(239,231,214,0.018) 79px 80px);
  -webkit-mask-image: radial-gradient(70% 60% at 50% 55%, #000 20%, transparent 95%);
          mask-image: radial-gradient(70% 60% at 50% 55%, #000 20%, transparent 95%);
}

.loader-grain {
  position: absolute; inset: 0;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='220' height='220'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.95' numOctaves='2' stitchTiles='stitch'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
  opacity: 0.05;
  mix-blend-mode: overlay;
  pointer-events: none;
}

/* floodlight pylons (light points at top corners) */
.loader-pylons {
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 140px;
  pointer-events: none;
}
.pylon {
  position: absolute;
  top: 24px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--saffron);
  box-shadow:
    0 0 0 3px rgba(255,138,31,0.25),
    0 0 30px rgba(255,138,31,0.85),
    0 0 90px rgba(255,138,31,0.5);
  opacity: 0;
  animation: pylon-on 700ms ease 350ms forwards;
}
.pylon--l { left: 7%; }
.pylon--r { right: 7%; animation-delay: 500ms; }
@keyframes pylon-on {
  0%   { opacity: 0; transform: scale(0.4); }
  60%  { opacity: 1; transform: scale(1.4); }
  100% { opacity: 1; transform: scale(1); }
}

.loader-stage {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 30px;
  padding: 0 24px;
  text-align: center;
}

/* CRICKET BALL — bowls in from the right, then idles spinning */
.loader-ball-wrap {
  position: relative;
  width: 130px; height: 130px;
}
.loader-ball {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  filter: drop-shadow(0 0 30px rgba(255,138,31,0.55)) drop-shadow(0 0 80px rgba(255,138,31,0.35));
  animation:
    ball-bowl 1100ms cubic-bezier(.18,.85,.4,1.05) 100ms 1 both,
    ball-spin 4.5s linear 1200ms infinite;
}
.ball-glow { animation: glow-pulse 2.4s ease-in-out 1300ms infinite; transform-origin: 100px 100px; }
@keyframes glow-pulse {
  0%, 100% { opacity: 0.3; transform: scale(0.95); }
  50%      { opacity: 0.55; transform: scale(1.1); }
}

@keyframes ball-bowl {
  0%   { transform: translate(95vw, -180px) rotate(-820deg) scale(0.55); opacity: 0; }
  35%  { opacity: 1; }
  60%  { transform: translate(-30px, -50px) rotate(-160deg) scale(1.08); opacity: 1; }
  82%  { transform: translate(10px, 14px) rotate(60deg) scale(0.94); }
  100% { transform: translate(0,0) rotate(0deg) scale(1); }
}
@keyframes ball-spin {
  from { transform: translate(0,0) rotate(0deg); }
  to   { transform: translate(0,0) rotate(360deg); }
}

/* motion trail: a streak that flies in WITH the ball, then fades */
.loader-ball-trail {
  position: absolute;
  top: 50%; left: 50%;
  width: 800px;
  height: 6px;
  margin-top: -3px;
  background: linear-gradient(90deg,
    transparent 0%,
    rgba(255,138,31,0) 30%,
    rgba(255,138,31,0.6) 80%,
    rgba(255,255,255,0.85) 100%);
  filter: blur(3px);
  transform-origin: 100% 50%;
  transform: translateX(-100%) rotate(-12deg) scaleX(0);
  opacity: 0;
  animation: trail-streak 900ms cubic-bezier(.18,.85,.4,1) 150ms 1 both;
}
@keyframes trail-streak {
  0%   { transform: translate(120vw, -150px) rotate(-12deg) scaleX(0); opacity: 0; }
  20%  { opacity: 1; transform: translate(60vw, -60px) rotate(-12deg) scaleX(1); }
  70%  { opacity: 0.7; transform: translate(0, 0) rotate(-12deg) scaleX(0.6); }
  100% { opacity: 0; transform: translate(-40px, 8px) rotate(0deg) scaleX(0); }
}

/* TITLE */
.loader-title {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}
.loader-eyebrow {
  font-family: "Archivo", sans-serif;
  font-weight: 800;
  font-size: 11px;
  letter-spacing: 0.34em;
  color: var(--saffron);
  display: inline-flex;
  align-items: center;
  gap: 12px;
  opacity: 0;
  animation: fade-up 600ms ease 600ms forwards;
}
.loader-pulse {
  width: 7px; height: 7px;
  background: var(--blood);
  border-radius: 50%;
  box-shadow: 0 0 12px var(--blood);
  animation: pulse 1.1s ease-in-out infinite;
}
.loader-name {
  margin: 0;
  font-family: "Big Shoulders Display", sans-serif;
  font-weight: 900;
  font-size: clamp(46px, 8vw, 96px);
  letter-spacing: 0.06em;
  line-height: 0.95;
  color: var(--bone);
  display: flex;
  gap: 0.02em;
  text-transform: uppercase;
}
.loader-name span {
  display: inline-block;
  opacity: 0;
  transform: translateY(64px) scale(1.18);
  animation: title-stamp 700ms cubic-bezier(.2,.6,.2,1.05) forwards;
  animation-delay: calc(700ms + var(--i) * 75ms);
}
.loader-name span:nth-child(2n) {
  -webkit-text-stroke: 1.5px var(--saffron);
  color: transparent;
}
@keyframes title-stamp {
  0%   { opacity: 0; transform: translateY(64px) scale(1.2); filter: blur(4px); }
  60%  { opacity: 1; transform: translateY(-6px) scale(1.05); filter: blur(0); }
  100% { opacity: 1; transform: translateY(0) scale(1); filter: blur(0); }
}
.loader-sub {
  font-family: "Fraunces", serif;
  font-style: italic;
  font-size: 13px;
  color: var(--bone-3);
  letter-spacing: 0.18em;
  text-transform: uppercase;
  opacity: 0;
  animation: fade-up 600ms ease 1500ms forwards;
}
@keyframes fade-up {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* PROGRESS */
.loader-progress {
  width: min(560px, 88vw);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  opacity: 0;
  animation: fade-up 600ms ease 1700ms forwards;
}
.loader-phases {
  list-style: none;
  margin: 0; padding: 0;
  display: flex;
  gap: 22px;
  font-family: "Archivo", sans-serif;
  font-weight: 800;
  font-size: 10px;
  letter-spacing: 0.28em;
  color: var(--bone-3);
}
.phase {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  transition: color 320ms ease;
}
.phase i {
  font-style: normal;
  font-family: "JetBrains Mono", monospace;
  font-size: 9px;
  font-weight: 700;
  color: var(--bone-4);
  border: 1px solid var(--line);
  padding: 1px 5px;
  border-radius: 1px;
  transition: all 320ms ease;
}
.phase.is-active { color: var(--saffron); }
.phase.is-active i {
  color: var(--ink-0);
  background: var(--saffron);
  border-color: var(--saffron);
  box-shadow: 0 0 18px rgba(255,138,31,0.6);
}
.phase.is-done    { color: var(--bone); }
.phase.is-done i  {
  color: var(--ink-0);
  background: var(--bone);
  border-color: var(--bone);
}

.loader-bar {
  width: 100%;
  height: 2px;
  background: var(--ink-3);
  position: relative;
  overflow: hidden;
}
.loader-bar-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, rgba(255,138,31,0.35), var(--saffron) 60%, #fff);
  box-shadow: 0 0 14px var(--saffron);
  transition: width 700ms cubic-bezier(.4,.05,.2,1);
}
.loader-bar::after {
  content: "";
  position: absolute;
  top: 0; left: 0; bottom: 0;
  width: 28%;
  background: linear-gradient(90deg, transparent, rgba(255,138,31,0.6), transparent);
  animation: bar-scan 1.6s ease-in-out infinite;
}
@keyframes bar-scan {
  0%   { transform: translateX(-100%); }
  100% { transform: translateX(450%); }
}

.loader-status {
  font-family: "JetBrains Mono", monospace;
  font-size: 11px;
  letter-spacing: 0.1em;
  color: var(--bone-2);
  font-variant-numeric: tabular-nums;
  min-height: 1.4em;
  transition: color 240ms;
}
.loader-status.is-error { color: var(--blood-2); }

@media (max-width: 600px) {
  .loader-phases { gap: 14px; font-size: 9px; letter-spacing: 0.22em; }
  .loader-name { font-size: clamp(40px, 14vw, 64px); }
}

/* ============================================================
   BOOT FADE
   ============================================================ */
.boot main, .boot .grid, .boot .ticker { opacity: 0; transform: translateY(8px); }
.ready main, .ready .grid, .ready .ticker {
  opacity: 1; transform: none;
  transition: opacity 600ms ease, transform 600ms cubic-bezier(.2,.7,.3,1);
}
.ready main { transition-delay: 80ms; }
.ready .grid { transition-delay: 220ms; }
.ready .ticker { transition-delay: 360ms; }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1100px) {
  .grid {
    grid-template-columns: 1fr 1fr;
    grid-template-areas:
      "over    crease"
      "leaders leaders"
      "comm    comm";
  }
}
@media (max-width: 760px) {
  .bar-right { display: none; }
  .hero { padding: 18px 16px; }
  .scoreline {
    grid-template-columns: 1fr;
    grid-template-areas: "a" "v" "b";
  }
  .team-l { grid-area: a; border-left: none; border-top: 3px solid var(--saffron); }
  .team-r { grid-area: b; border-right: none; border-top: 3px solid var(--cyan); }
  .versus { grid-area: v; flex-direction: row; }
  .versus-mark { font-size: 32px; }
  .team-r .team-strap, .team-r .team-extras, .team-r .team-overs, .team-r .team-score { justify-content: flex-start; text-align: left; }
  .team-r .team-strap { flex-direction: row-reverse; justify-content: flex-end; }
  .team-r .team-extras { justify-content: flex-start; }
  .team-r .team-overs { text-align: left; }

  .gauge-head { grid-template-columns: 1fr 1fr; }
  .gauge-cell--center { grid-column: 1 / -1; align-items: flex-start; text-align: left; }
  .grid {
    grid-template-columns: 1fr;
    grid-template-areas:
      "over"
      "crease"
      "leaders"
      "comm";
    padding: 14px;
  }
  .comm-item {
    grid-template-columns: 56px 44px 1fr;
    grid-template-rows: auto auto;
  }
  .comm-score { grid-column: 1 / -1; text-align: left; }
}
