/* The static pages (/about/, /setup/, /privacy/, /terms/, /contact/, /teams/ and the team pages, built by
   scripts/build-pages.mjs). Same tokens as the app (src/index.css): a night-game indigo, warm bulb amber
   for the main actions, and the spectrum of every team's colors. */
@font-face { font-family: "Big Shoulders Display"; src: url("/fonts/big-shoulders-display-latin-800-normal.woff2") format("woff2"); font-weight: 800; font-display: swap; }
@font-face { font-family: "Big Shoulders Display"; src: url("/fonts/big-shoulders-display-latin-900-normal.woff2") format("woff2"); font-weight: 900; font-display: swap; }
:root {
  --amber: #ffb627; --pink: #ff3d8b; --cyan: #34e0ff; --lime: #b4f05a; --violet: #9b7bff; --on-bright: #170f00;
  --bg-a: #120e2a;
  --bg-b: #170f33;
  --ink: #f3f0ff;
  --muted: #b3abd6;
  --surface: #1b1638;
  --rule: #352d63;
  --line: #4b4283;
  --blue: var(--amber); /* older name: the main action color */
  --link: #7fe9ff;
  --orange: var(--pink); /* older name: the highlight color */
  --danger: #ff6b5e;
  --display: "Big Shoulders Display", "Arial Narrow", Impact, sans-serif;
  --ribbon: linear-gradient(90deg,
    #ff3d8b 0 6%, #ffb627 6% 12%, #1f4fd6 12% 18%, #f4f4f4 18% 24%, #7a1f2b 24% 30%, #ffc72c 30% 36%,
    #00a0a8 36% 42%, #3a3550 42% 48%, #5b2a9a 48% 54%, #b4f05a 54% 60%, #e0243a 60% 66%, #34e0ff 66% 72%,
    #1f8a4c 72% 78%, #fff 78% 84%, #ff7a1a 84% 90%, #9b7bff 90% 100%);
  --pixels: repeating-linear-gradient(90deg, transparent 0 5px, rgba(10, 6, 30, 0.55) 5px 6px);
  color-scheme: dark;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  line-height: 1.6;
  color: var(--ink);
  background: var(--bg-a);
  -webkit-font-smoothing: antialiased;
}
* { box-sizing: border-box; }
body { margin: 0; min-width: 320px; min-height: 100vh; display: flex; flex-direction: column; background: var(--bg-a); }
body::before {
  content: ""; position: fixed; inset: 0; z-index: -1;
  background: radial-gradient(900px 520px at 8% -8%, rgba(255, 61, 139, 0.16), transparent 62%), radial-gradient(900px 520px at 96% 4%, rgba(52, 224, 255, 0.12), transparent 62%), var(--bg-a);
  animation: glow 6s ease-in-out infinite alternate;
}
@keyframes glow { from { background-color: var(--bg-a); } to { background-color: var(--bg-b); } }
@media (prefers-reduced-motion: reduce) { body::before, .top::after { animation: none !important; } }
a { color: var(--link); font-weight: 600; }
:focus-visible { outline: 2px solid var(--cyan); outline-offset: 2px; }
h1, .prose h2.big { font-family: var(--display); font-weight: 800; line-height: 1; letter-spacing: 0.005em; }
.top {
  position: sticky; top: 0; z-index: 10;
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 20px;
  padding: 10px max(16px, calc((100vw - 1160px) / 2)) 14px;
  background: rgba(16, 12, 38, 0.86);
  backdrop-filter: blur(10px);
}
/* The ribbon board (see src/index.css): flashes three times as the page opens, then holds. A team page
   has its own two-color band right under it, so the ribbon steps aside there. */
.top::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 4px;
  background: var(--pixels), var(--ribbon); background-size: auto, 720px 100%;
  animation: ribbon-flash 0.42s ease-in-out 0.5s 3 alternate both;
}
body:has(.tp-hero) .top::after { display: none; }
body:has(.tp-hero) .top { padding-bottom: 10px; }
@keyframes ribbon-flash {
  from { filter: brightness(1) saturate(1); box-shadow: none; }
  to { filter: brightness(1.5) saturate(1.4); box-shadow: 0 0 18px 2px rgba(255, 255, 255, 0.35); }
}
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; }
.brand img { width: 34px; height: 34px; border-radius: 9px; box-shadow: 0 0 14px rgba(255, 61, 139, 0.25), 0 0 14px rgba(52, 224, 255, 0.2); }
.brand span { font-family: var(--display); font-size: 1.75rem; font-weight: 900; line-height: 1; letter-spacing: 0.01em; }
.top nav { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 18px; font-size: 0.9375rem; }
.top nav a { color: var(--ink); text-decoration: none; }
.top nav a:hover { color: var(--link); }
.top nav a.button { color: var(--on-bright); }
@media (max-width: 640px) { .top nav .opt { display: none; } }
main { flex: 1; }
.prose {
  width: calc(100% - 32px); max-width: 760px; margin: 28px auto 48px; padding: 28px 28px 36px;
  border: 1px solid var(--rule); border-radius: 16px; background: rgba(27, 22, 56, 0.94);
  box-shadow: 0 6px 28px rgba(155, 123, 255, 0.16);
}
@media (max-width: 560px) { .prose { width: calc(100% - 24px); padding: 20px 16px 28px; margin-top: 16px; } }
.prose h1 { margin: 0 0 14px; font-size: clamp(2.3rem, 7vw, 3.1rem); }
.prose h2 { margin: 28px 0 8px; font-size: 1.2rem; }
.prose li { margin-bottom: 6px; }
.lede { font-size: 1.125rem; color: #ddd7f5; }
.muted { color: var(--muted); }
.note { margin-top: 32px; padding-top: 16px; border-top: 1px solid var(--rule); font-size: 0.875rem; color: var(--muted); }
.warning { padding: 12px 14px; border-left: 4px solid var(--amber); border-radius: 8px; background: rgba(255, 182, 39, 0.1); }
.steps { counter-reset: step; padding: 0; list-style: none; }
.steps > li { position: relative; margin: 0 0 18px; padding-left: 48px; }
/* Numbered steps: each number a bulb in the next color of the spectrum. */
.steps > li { --bulb: var(--pink); }
.steps > li:nth-child(4n + 2) { --bulb: var(--cyan); }
.steps > li:nth-child(4n + 3) { --bulb: var(--lime); }
.steps > li:nth-child(4n + 4) { --bulb: var(--amber); }
.steps > li::before {
  counter-increment: step; content: counter(step);
  position: absolute; left: 0; top: 0; display: grid; place-items: center; width: 34px; height: 34px;
  border-radius: 50%; background: var(--bulb); box-shadow: 0 0 14px color-mix(in srgb, var(--bulb) 55%, transparent);
  color: var(--on-bright); font-family: var(--display); font-size: 1.3rem; font-weight: 900; line-height: 1;
}
.steps h2 { margin: 4px 0 4px; font-size: 1.0625rem; }
.steps p { margin: 0; }
.button {
  display: inline-block; padding: 9px 18px; border: 0; border-radius: 10px; background: var(--amber); color: var(--on-bright);
  font: inherit; font-weight: 700; text-decoration: none; cursor: pointer; transition: background-color 0.2s ease, box-shadow 0.2s ease;
}
.button:hover { background: #ffc54f; box-shadow: 0 0 0 3px rgba(255, 182, 39, 0.22), 0 0 22px rgba(255, 182, 39, 0.45); }
.button:disabled { opacity: 0.5; cursor: progress; }
.cta { display: flex; flex-wrap: wrap; gap: 10px; margin: 24px 0 0; }
.bottom { padding: 28px 16px 36px; border-top: 1px solid rgba(255, 255, 255, 0.08); background: #0a0719; text-align: center; }
.footer-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 4px 22px; margin: 0; padding: 0; list-style: none; }
.footer-links a { display: inline-block; padding: 6px 0; color: var(--ink); font-weight: 500; text-decoration: none; }
.footer-links a:hover { color: var(--link); text-decoration: underline; }
.footer-legal { margin: 14px 0 0; color: var(--muted); font-size: 0.8125rem; }
/* Contact page (public/contact.js) */
.contact-form { margin: 20px 0 8px; }
.contact-reasons { margin: 0 0 18px; padding: 0; border: 0; }
.contact-reasons legend { margin-bottom: 8px; padding: 0; font-weight: 700; }
.contact-reason { display: flex; align-items: flex-start; gap: 10px; margin: 0 0 8px; padding: 10px 12px; border: 1px solid var(--rule); border-radius: 10px; background: #140f2e; cursor: pointer; }
.contact-reason:has(input:checked) { border-color: var(--orange); background: rgba(255, 61, 139, 0.08); }
.contact-reason input { flex: none; width: 18px; height: 18px; margin: 3px 0 0; accent-color: var(--orange); }
.contact-reason strong { display: block; }
.contact-reason small { display: block; color: var(--muted); font-size: 0.875rem; }
.contact-field { display: grid; gap: 6px; margin: 0 0 14px; }
.contact-field label { font-weight: 700; }
.contact-field small { color: var(--muted); font-size: 0.8125rem; }
.contact-field input, .contact-field textarea {
  width: 100%; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; background: #0d0a20; color: var(--ink); font: inherit;
}
.contact-field [aria-invalid="true"] { border-color: var(--danger); }
.contact-trap { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.contact-status { min-height: 1.2em; margin: 0 0 10px; }
.contact-error { color: #ffc9c3; }
.contact-done:focus { outline: none; }
.prerender { max-width: 760px; margin: 0 auto; padding: 32px 16px; }
.steps h3 { margin: 4px 0 4px; font-size: 1.0625rem; }
.button-big { padding: 13px 24px; font-size: 1.0625rem; }
.hint { margin: 10px 0 0; color: var(--muted); font-size: 0.9375rem; }
.eyebrow { display: flex; align-items: center; gap: 8px; margin: 0 0 12px; color: var(--muted); font-size: 0.9375rem; font-weight: 700; }
.eyebrow::before { content: ""; flex: none; width: 12px; height: 12px; border-radius: 50%; background: linear-gradient(135deg, var(--c1, var(--pink)) 50%, var(--c2, var(--cyan)) 50%); box-shadow: 0 0 10px color-mix(in srgb, var(--c1, var(--pink)) 60%, transparent); }
.crumbs { margin: 0 0 14px; color: var(--muted); font-size: 0.875rem; }
.crumbs a { color: var(--muted); font-weight: 500; }
.crumbs a:hover { color: var(--link); }
.prose.wide { max-width: 1100px; }

/* Teams (/teams/ and the team pages). A team's colors arrive as --c1 and --c2 on the element. */
.league-jump { display: flex; flex-wrap: wrap; gap: 8px; margin: 18px 0 8px; }
.league-jump a {
  padding: 5px 14px; border: 1px solid var(--line); border-radius: 999px; background: rgba(10, 6, 30, 0.45);
  color: var(--ink); font-weight: 800; letter-spacing: 0.06em; text-decoration: none;
}
.league-jump a:hover { border-color: var(--cyan); color: var(--link); box-shadow: 0 0 14px rgba(52, 224, 255, 0.35); }
.league { scroll-margin-top: 72px; }
.league h2 { display: flex; align-items: baseline; gap: 10px; margin-top: 32px; padding-bottom: 6px; border-bottom: 1px solid var(--rule); font-family: var(--display); font-size: 1.9rem; font-weight: 800; line-height: 1.05; }
.league h2 small { font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif; }
.league h2 small { color: var(--muted); font-size: 0.875rem; font-weight: 500; }
.team-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 8px; margin: 12px 0 0; padding: 0; list-style: none; }
.team-grid li { margin: 0; }
.team-chip {
  display: flex; align-items: center; gap: 10px; min-height: 44px; padding: 8px 12px;
  border: 1px solid var(--rule); border-radius: 10px; background: #140f2e; color: var(--ink); font-weight: 600; text-decoration: none;
}
.team-chip:hover { border-color: var(--c1); background: color-mix(in srgb, var(--c1) 14%, #140f2e); }
.team-dot {
  position: relative; flex: none; width: 20px; height: 20px; border-radius: 50%;
  background: linear-gradient(135deg, var(--c1) 50%, var(--c2) 50%); box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.35), 0 0 10px color-mix(in srgb, var(--c1) 55%, transparent);
}
@media (max-width: 560px) { .team-grid { grid-template-columns: 1fr 1fr; } .team-chip { padding: 8px 10px; font-size: 0.9375rem; } }
@media (max-width: 360px) { .team-grid { grid-template-columns: 1fr; } }

.tp { --c1: #ff2d4b; --c2: #ffffff; }
.tp-hero {
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  background:
    radial-gradient(700px 420px at 85% 40%, color-mix(in srgb, var(--c1) 30%, transparent), transparent 70%),
    radial-gradient(600px 400px at 10% 110%, color-mix(in srgb, var(--c2) 20%, transparent), transparent 70%),
    #0d0a20;
}
.tp-hero::before { content: ""; display: block; height: 6px; background: linear-gradient(90deg, var(--c1) 0 50%, var(--c2) 50% 100%); }
.tp-hero-in {
  display: grid; grid-template-columns: 1.2fr 0.8fr; align-items: center; gap: 32px;
  max-width: 1160px; margin: 0 auto; padding: 40px 16px 48px;
}
.tp-hero h1 { margin: 0 0 16px; font-size: clamp(2.6rem, 7vw, 4.4rem); line-height: 0.98; }
.tp-hero .lede { max-width: 34em; }
.tp-hero .cta { margin-top: 20px; }
.tp-show {
  display: grid; justify-items: center; gap: 16px; padding: 24px 16px;
  border: 2px solid var(--line); border-radius: 18px; background: radial-gradient(circle at 50% 70%, rgba(255, 255, 255, 0.04), transparent 70%), #0d0a20;
  box-shadow: -28px 0 70px -18px color-mix(in srgb, var(--c1) 55%, transparent), 28px 0 70px -18px color-mix(in srgb, var(--c2) 40%, transparent); overflow: hidden;
}
.tp-scorebug { display: flex; align-items: center; gap: 12px; padding: 8px 14px; border: 1px solid #2c2552; border-radius: 10px; background: #07051a; font-weight: 800; font-variant-numeric: tabular-nums; }
.tp-score-team { padding: 2px 8px; border-radius: 6px; background: var(--c1); box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.25); }
.tp-score-pts { position: relative; display: inline-block; width: 3ch; height: 1.5em; font-size: 1.3rem; }
.tp-score-pts span { position: absolute; inset: 0; }
.tp-score-old { animation: tp-old 8s infinite; }
.tp-score-new, .tp-score-flag { opacity: 0; animation: tp-new 8s infinite; }
.tp-score-flag { color: var(--orange); font-size: 0.8125rem; letter-spacing: 0.1em; }
.tp-lamp { position: relative; display: grid; justify-items: center; width: 180px; height: 220px; }
.tp-glow {
  position: absolute; top: -20px; width: 260px; height: 260px; border-radius: 50%;
  background: radial-gradient(circle, var(--glow, rgba(255, 240, 210, 0.35)), transparent 65%);
  --glow: rgba(255, 240, 210, 0.35);
  animation: tp-glow 8s infinite;
}
.tp-bulb {
  position: relative; width: 120px; height: 120px; margin-top: 30px; border-radius: 50% 50% 46% 46%;
  background: #fff3dc; box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.18), 0 0 30px rgba(255, 243, 220, 0.6);
  animation: tp-bulb 8s infinite;
}
.tp-base { width: 60px; height: 46px; margin-top: -6px; border-radius: 6px 6px 14px 14px; background: repeating-linear-gradient(#777 0 6px, #555 6px 10px); }
/* Idle warm white, the score flips, then the two colors alternate (0.8 s a cycle, as the real pulse:
   under 3 flashes a second) and it settles back. */
@keyframes tp-old { 0%, 30% { opacity: 1; } 32%, 100% { opacity: 0; } }
@keyframes tp-new { 0%, 30% { opacity: 0; } 32%, 94% { opacity: 1; } 100% { opacity: 0; } }
@keyframes tp-bulb {
  0%, 32%, 92%, 100% { background: #fff3dc; box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.18), 0 0 30px rgba(255, 243, 220, 0.6); }
  33%, 42%, 52%, 62%, 72%, 82% { background: var(--c1); box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.18), 0 0 60px 18px color-mix(in srgb, var(--c1) 75%, transparent); }
  37%, 47%, 57%, 67%, 77%, 87% { background: var(--c2); box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.18), 0 0 60px 18px color-mix(in srgb, var(--c2) 75%, transparent); }
}
@keyframes tp-glow {
  0%, 32%, 92%, 100% { opacity: 1; filter: none; }
  33%, 42%, 52%, 62%, 72%, 82% { opacity: 0.9; background: radial-gradient(circle, color-mix(in srgb, var(--c1) 60%, transparent), transparent 65%); }
  37%, 47%, 57%, 67%, 77%, 87% { opacity: 0.9; background: radial-gradient(circle, color-mix(in srgb, var(--c2) 45%, transparent), transparent 65%); }
}
@media (prefers-reduced-motion: reduce) {
  .tp-score-old, .tp-score-new, .tp-score-flag, .tp-bulb, .tp-glow { animation: none; }
  .tp-score-old { opacity: 0; }
  .tp-score-new, .tp-score-flag { opacity: 1; }
  .tp-bulb { background: linear-gradient(90deg, var(--c1) 50%, var(--c2) 50%); }
}
@media (max-width: 760px) {
  .tp-hero-in { grid-template-columns: 1fr; gap: 20px; padding: 24px 16px 32px; }
  .tp-show { grid-template-columns: auto auto; align-items: center; justify-content: center; padding: 14px; }
  .tp-lamp { width: 120px; height: 150px; }
  .tp-glow { width: 170px; height: 170px; top: -10px; }
  .tp-bulb { width: 84px; height: 84px; margin-top: 18px; }
  .tp-base { width: 42px; height: 32px; }
  .tp-scorebug { flex-direction: column; gap: 6px; }
}
.tp-body { margin-top: 32px; }
.tp-body h2:first-child { margin-top: 0; }
.swatches { display: flex; flex-wrap: wrap; gap: 10px 22px; margin: 14px 0; padding: 0; list-style: none; }
.swatches li { display: flex; align-items: center; gap: 10px; margin: 0; }
.swatch { width: 40px; height: 40px; border-radius: 10px; box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.35); }
.swatches code { color: var(--muted); font-size: 0.9375rem; }
.faq { margin: 12px 0 0; }
.faq div { padding: 12px 0; border-top: 1px solid var(--rule); }
.faq dt { font-weight: 700; }
.faq dd { margin: 4px 0 0; color: #ddd7f5; }
.team-grid-few { grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }

/* /goal-light/: the "what you get" list and the demo video (public/media/goal-light.mp4, when present) */
.gl-list { padding-left: 1.2em; }
.gl-list li { margin-bottom: 10px; }
.gl-video-wrap { padding: 0; }
.gl-video { display: block; width: 100%; max-height: 420px; aspect-ratio: 9 / 16; object-fit: cover; background: #000; }
@media (min-width: 761px) { .gl-video-wrap { max-width: 320px; justify-self: center; } }
@media (max-width: 760px) { .gl-video-wrap { grid-template-columns: 1fr; max-width: 280px; justify-self: center; } }

/* /lights/: starter lights */
.shop-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; margin: 14px 0 0; padding: 0; list-style: none; }
.shop-card { display: flex; flex-direction: column; gap: 6px; margin: 0; padding: 16px; border: 1px solid var(--rule); border-radius: 12px; background: #140f2e; }
.shop-card h3 { margin: 0; font-size: 1.0625rem; }
.shop-brand { color: var(--amber); font-size: 0.8125rem; font-weight: 800; }
.shop-card p { margin: 0; }
.shop-card .shop-model { color: var(--muted); font-size: 0.875rem; }
.shop-links { display: flex; flex-wrap: wrap; gap: 6px 14px; margin-top: auto !important; padding-top: 8px; }
.yes-no { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.yes-no > div { padding: 12px 14px; border: 1px solid var(--rule); border-radius: 10px; }
.yes-no h3 { margin: 0 0 6px; font-size: 1rem; }
.yes-no ul { margin: 0; padding-left: 1.1em; }
@media (max-width: 560px) { .yes-no { grid-template-columns: 1fr; } }

/* The search box on /teams/ (public/teams-search.js). */
.league-jump[hidden], .league[hidden], .team-grid li[hidden] { display: none; }
.team-search { display: grid; gap: 6px; margin: 18px 0 4px; max-width: 520px; }
.team-search label { color: var(--muted); font-size: 0.875rem; font-weight: 700; letter-spacing: 0.04em; }
.team-search input {
  width: 100%; box-sizing: border-box; min-height: 44px; padding: 10px 14px; border: 1px solid var(--line); border-radius: 10px;
  background: #140f2e; color: var(--ink); font: inherit;
}
.team-search input:focus-visible { outline: 2px solid var(--cyan); outline-offset: 2px; }
.team-search-status { margin: 0; color: var(--muted); font-size: 0.9375rem; min-height: 1.4em; }
