/* Home-specific styles */

/* ── Hero (stacked: photo → headline → lead → CTAs) ─────── */
.hero {
  padding: 3rem 0 4rem;
  background: var(--grad-hero);
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: "";
  position: absolute;
  top: 0; left: 50%;
  transform: translateX(-50%);
  width: 900px; height: 1px;
  background: linear-gradient(90deg, transparent, rgba(212,175,55,.3), transparent);
}
.hero-stack {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 2rem;
  max-width: 960px;
}
.hero-stack > .eyebrow { margin-top: 0.5rem; }
.hero-photo { position: relative; width: 100%; }
.hero-photo .photo-frame {
  width: 100%;
  position: relative;
  z-index: 1;
  border: none;
  background: none;
}
/* Purple backlight glow behind the hero photo */
.hero-photo::before {
  content: "";
  position: absolute;
  inset: -12%;
  border-radius: 32px;
  background: radial-gradient(closest-side, rgba(123,63,173,.7), transparent 72%);
  filter: blur(60px);
  pointer-events: none;
}

.hero-headline {
  margin: 0.5rem 0 0;
  max-width: 18ch;
  text-wrap: balance;
}
.hero-headline .beam-wrap {
  display: inline-block;
  position: relative;
  cursor: pointer;
}
.hero-headline .beam-wrap:focus { outline: none; }
.hero-headline .beam {
  display: inline-block;
  font-family: var(--font-display);
  font-weight: 800;
  letter-spacing: -0.01em;
}
.hero-headline .beam-canvas {
  position: absolute;
  inset: -30px -40px auto auto;
  width: 380px; height: 100px;
  pointer-events: none;
}
.hero-lead {
  max-width: 56ch;
  margin: 0;
}
.hero-ctas {
  justify-content: center;
  gap: 0.75rem;
}

@media (max-width: 720px) {
  .hero { padding: 2rem 0 3rem; }
  .hero-stack { gap: 1.5rem; }
  .hero-headline .beam-canvas { width: 280px; height: 80px; inset: -20px -20px auto auto; }
}

/* ── Score band ─────────────────────────────────────────── */
.score-band {
  border-top: 1px solid var(--border-faint);
  border-bottom: 1px solid var(--border-faint);
  background: rgba(255,255,255,.015);
}
.score-band-inner {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 2rem;
  padding: 1.5rem 1.25rem;
}
.score-team-name {
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.score-team-record { color: var(--fg-3); font-size: 0.85rem; }
.score-band-game { text-align: center; display: flex; flex-direction: column; align-items: center; gap: 0.35rem; }
.score-status {
  font-size: 0.75rem;
  color: var(--fg-3);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
}
.score-status .dot-live {
  display: inline-block;
  width: 6px; height: 6px;
  background: var(--status-success);
  border-radius: 999px;
  animation: pulseDot 1.6s ease-in-out infinite;
}
.score-numbers {
  display: inline-flex;
  align-items: baseline;
  gap: 0.85rem;
  margin: 0.25rem 0;
}
.score-team {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1rem;
  color: var(--fg-3);
  letter-spacing: 0.05em;
}
.score-num {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 2.5rem;
  color: var(--off-white);
  line-height: 1;
}
.score-sep { color: var(--fg-4); font-size: 1.5rem; }
.score-band-state { display: flex; justify-content: flex-end; }
.led-state {
  display: flex; align-items: center; gap: 0.85rem;
  padding: 0.6rem 1rem;
  border: 1px solid var(--border-soft);
  border-radius: 999px;
  background: rgba(212,175,55,.04);
}
.led-bulb {
  width: 12px; height: 12px;
  border-radius: 999px;
  background: rgba(212,175,55,.2);
  border: 1px solid var(--border-soft);
}
.led-bulb-on {
  background: var(--sac-gold);
  box-shadow: var(--glow-gold);
  animation: pulseDot 2s ease-in-out infinite;
}
.led-state-label { font-size: 0.7rem; color: var(--fg-3); text-transform: uppercase; letter-spacing: 0.1em; }
.led-state-value { font-size: 0.9rem; font-weight: 600; color: var(--fg-1); }

@media (max-width: 900px) {
  .score-band-inner { grid-template-columns: 1fr; text-align: center; }
  .score-band-state { justify-content: center; }
}

/* ── About ──────────────────────────────────────────────── */
.about-grid {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 4rem;
  align-items: center;
}
@media (max-width: 900px) {
  .about-grid { grid-template-columns: 1fr; gap: 2rem; }
}

/* ── How it works ──────────────────────────────────────── */
.how-track {
  position: relative;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
  margin-top: 1rem;
}
.how-line {
  position: absolute;
  top: 1.5rem; left: 5%; right: 5%;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--border-strong), transparent);
}
.how-line::after {
  content: "";
  position: absolute; left: 0; top: -1px;
  width: 100%; height: 3px;
  background: linear-gradient(90deg, var(--sac-gold), var(--kings-purple));
  border-radius: 999px;
  transform-origin: left;
  animation: howLine 4s ease-in-out infinite;
  filter: blur(2px);
  opacity: 0.7;
}
@keyframes howLine {
  0% { transform: scaleX(0); }
  50% { transform: scaleX(1); }
  100% { transform: scaleX(0); transform-origin: right; }
}
.how-step {
  position: relative;
  text-align: center;
  padding-top: 4rem;
}
.how-num {
  position: absolute;
  top: 0; left: 50%;
  transform: translateX(-50%);
  width: 3rem; height: 3rem;
  border-radius: 999px;
  background: var(--bg-page);
  border: 1px solid var(--border-strong);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 0.9rem;
  color: var(--sac-gold);
  letter-spacing: 0.05em;
  z-index: 2;
}
.how-step[data-step="4"] .how-num {
  border-color: var(--kings-purple);
  color: var(--kings-purple);
  box-shadow: var(--glow-purple);
}
.how-step h3 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.15rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin: 0 0 0.5rem;
}
.how-step p { font-size: 0.9rem; margin: 0; }

@media (max-width: 720px) {
  .how-track { grid-template-columns: 1fr 1fr; }
  .how-line { display: none; }
}

/* ── LED simulator ──────────────────────────────────────── */
.sim-card {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 2.5rem;
  align-items: center;
  border: 1px solid var(--border-default);
  border-radius: 16px;
  padding: 2.5rem;
  background: rgba(255,255,255,.02);
}
.sim-stage {
  position: relative;
  aspect-ratio: 1.2 / 1;
  background:
    radial-gradient(circle at 50% 45%, rgba(212,175,55,.05), transparent 70%);
  border-radius: 12px;
}
.sim-pcb { width: 100%; height: 100%; position: relative; }
.sim-pcb-svg { width: 100%; height: 100%; display: block; }
.sim-burst {
  position: absolute;
  inset: 0;
  width: 100%; height: 100%;
  pointer-events: none;
}
.sim-controls { display: flex; flex-direction: column; gap: 1.25rem; }
.sim-readout {
  border: 1px solid var(--border-faint);
  border-radius: 10px;
  padding: 0.75rem 1rem;
  background: rgba(0,0,0,.3);
  font-family: var(--font-mono);
  font-size: 0.85rem;
}
.sim-readout-row {
  display: flex;
  justify-content: space-between;
  padding: 0.25rem 0;
}
.sim-readout-row + .sim-readout-row {
  border-top: 1px dashed var(--border-row);
}
.sim-buttons { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.sim-fine { font-size: 0.8rem; margin: 0; }

#sim-led { transition: fill 200ms var(--ease-out); }
#sim-led-glow { transition: fill 400ms var(--ease-out); }
.sim-card.celebrating #sim-led { fill: var(--kings-purple); }
.sim-card.celebrating #sim-led-glow {
  fill: rgba(123,63,173,.3);
  animation: simGlow 1.2s ease-out infinite;
}
.sim-card.lossed #sim-led { fill: var(--status-error); }
@keyframes simGlow {
  0%,100% { r: 8; opacity: 0.4; }
  50%     { r: 26; opacity: 0; }
}

@media (max-width: 900px) {
  .sim-card { grid-template-columns: 1fr; padding: 1.5rem; }
}

/* ── Why cards ──────────────────────────────────────────── */
.why-card {
  border: 1px solid var(--border-default);
  border-radius: 12px;
  padding: 1.75rem;
  background: var(--bg-card);
  transition: border-color 200ms, transform 200ms;
  position: relative;
  overflow: hidden;
}
.why-card:hover { border-color: var(--border-emphasis); transform: translateY(-2px); }
.why-num {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1rem;
  color: var(--sac-gold);
  letter-spacing: 0.1em;
  margin-bottom: 1.5rem;
  opacity: 0.6;
}
.why-card h3 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.25rem;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  margin: 0 0 0.5rem;
}
.why-card p { margin: 0; font-size: 0.95rem; }
.why-card-cta {
  background: linear-gradient(135deg, rgba(212,175,55,.08), rgba(123,63,173,.08));
  border-color: var(--border-strong);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 1rem;
}
.why-card-cta .btn { align-self: flex-start; margin-top: 0.5rem; }

/* ── Why list (vertical, icon + heading + body) ──────────── */
.why-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}
.why-row {
  display: grid;
  grid-template-columns: 56px 1fr;
  gap: 1.25rem;
  align-items: start;
  padding: 1.25rem 0;
  border-bottom: 1px solid var(--border-faint);
}
.why-row:last-child { border-bottom: none; }
.why-icon {
  width: 48px; height: 48px;
  border-radius: 10px;
  border: 1px solid var(--border-default);
  background: rgba(212,175,55,.06);
  color: var(--sac-gold);
  display: inline-flex; align-items: center; justify-content: center;
}
.why-icon svg { width: 24px; height: 24px; display: block; }
.why-row h3 {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.15rem;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  margin: 0 0 0.35rem;
  color: var(--off-white);
}
.why-row p { margin: 0; font-size: 0.95rem; }
