/* Playable Apps. Static, no build step. Tokens first, then layout, then components. */

:root {
  --red: #FB0201;          /* logo red */
  --red-field: #E00000;    /* hero field, white text passes AA */
  --red-press: #B80000;
  --ink: #000;
  --paper: #fff;
  --mist: #F2F2F2;
  --graphite: #5A5A5A;
  --line: rgba(0, 0, 0, .12);
  --nav-bg: rgba(255, 255, 255, .86);

  --display: "Outfit", "Arial Black", system-ui, sans-serif;
  --text: "Geist", system-ui, -apple-system, "Segoe UI", sans-serif;

  --wrap: 1180px;
  --gutter: clamp(16px, 4vw, 40px);
  --nav-h: 68px;
  --spring: cubic-bezier(.34, 1.56, .64, 1);
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --ink: #fff;
    --paper: #000;
    --mist: #141414;
    --graphite: #A6A6A6;
    --line: rgba(255, 255, 255, .14);
    --nav-bg: rgba(0, 0, 0, .8);
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--nav-h) + 12px); }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 400 1.125rem/1.55 var(--text);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
h1, h2, h3 { font-family: var(--display); margin: 0; text-wrap: balance; }
p { margin: 0 0 1em; text-wrap: pretty; }
p:last-child { margin-bottom: 0; }

:focus-visible { outline: 3px solid var(--red); outline-offset: 3px; border-radius: 6px; }
.hero :focus-visible { outline-color: #fff; }

.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 12px; top: -60px; z-index: 50; padding: 10px 16px; background: var(--ink); color: var(--paper); border-radius: 999px; text-decoration: none; }
.skip:focus { top: 12px; }

.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }

/* Buttons: solid pills, no gradients */
.btn {
  display: inline-flex; align-items: center; gap: .5em;
  min-height: 52px; padding: 0 26px;
  border-radius: 999px; border: 0;
  font: 600 1.0625rem/1 var(--text);
  text-decoration: none; cursor: pointer;
  transition: transform .18s var(--spring), background-color .18s ease;
}
.btn:active { transform: scale(.97); }
.btn--small { min-height: 40px; padding: 0 18px; font-size: .9375rem; }
.btn--red { background: var(--red-field); color: #fff; }
.btn--red:hover { background: var(--red-press); }
.btn--white { background: #fff; color: var(--red-field); }
.btn--white:hover { background: #FFE5E5; }
.btn--ink { background: var(--ink); color: var(--paper); }
.btn--ink:hover { opacity: .85; }
.ext { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

/* Nav */
.nav {
  position: sticky; top: 0; z-index: 40;
  background: var(--nav-bg);
  -webkit-backdrop-filter: saturate(180%) blur(16px);
  backdrop-filter: saturate(180%) blur(16px);
  border-bottom: 1px solid var(--line);
}
.nav__inner {
  max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter);
  height: var(--nav-h); display: flex; align-items: center; gap: 28px;
}
.nav__brand { margin-right: auto; display: block; }
.nav__brand img { height: 34px; width: auto; }
.nav__links { display: flex; gap: 26px; }
.nav__links a { font-size: .9688rem; font-weight: 500; text-decoration: none; color: var(--graphite); }
.nav__links a:hover { color: var(--ink); }
@media (max-width: 760px) { .nav__links { display: none; } .nav__brand img { height: 28px; } }

/* Hero: the red field, centered copy, and a fan of the games rising out of the bottom edge */
.hero { background: var(--red-field); color: #fff; overflow: hidden; }
.hero__inner {
  max-width: var(--wrap); margin: 0 auto; padding: clamp(36px, 4.5vw, 60px) var(--gutter) 0;
  display: flex; flex-direction: column; align-items: center; text-align: center;
}
.hero h1 {
  font-weight: 900;
  font-size: clamp(3.25rem, 7.5vw, 6.25rem);
  line-height: .9; letter-spacing: -.045em;
  margin-bottom: 16px;
}
.hero__copy p { font-size: clamp(1.0625rem, 1.4vw, 1.25rem); max-width: 36em; margin: 0 auto 24px; color: #fff; }

.fan {
  --w: clamp(104px, 16vw, 236px);      /* phone width */
  --step: clamp(58px, 15.4vw, 220px);  /* horizontal spacing between phones */
  position: relative; width: 100%; height: calc(var(--w) * 1.7); /* about 80% of each phone shows */
  margin-top: clamp(28px, 3.5vw, 44px);
}
.fan__phone {
  --d: max(var(--i), calc(var(--i) * -1)); /* distance from center: 0, 1, 2 */
  position: absolute; left: 50%; top: 0; width: var(--w); aspect-ratio: 460 / 997;
  margin-left: calc(var(--w) / -2);
  padding: calc(var(--w) * .042); border-radius: calc(var(--w) * .17);
  background: #0A0A0B; box-shadow: 0 0 0 1px rgba(255, 255, 255, .16), 0 24px 50px rgba(70, 0, 0, .45);
  transform: translateX(calc(var(--i) * var(--step))) translateY(calc(var(--d) * var(--w) * .13 + var(--lift, 0px))) rotate(calc(var(--i) * 6deg));
  transform-origin: 50% 100%;
  z-index: calc(10 - var(--d));
  transition: transform .28s var(--spring);
  animation: rise .8s var(--spring) both; animation-delay: calc(.12s + var(--d) * .1s);
}
.fan__phone img { width: 100%; height: 100%; object-fit: cover; object-position: top; border-radius: calc(var(--w) * .13); }
.fan__phone:hover, .fan__phone:focus-visible { --lift: calc(var(--w) * -.08); z-index: 20; }
.fan__phone:focus-visible { outline: 3px solid #fff; outline-offset: 4px; }
@keyframes rise { from { translate: 0 45%; opacity: 0; } to { translate: 0 0; opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .fan__phone { animation: none; transition: none; } .btn { transition: none; } }

/* Sections */
.section { padding: clamp(72px, 10vw, 128px) 0; }
.section h2 { font-weight: 800; font-size: clamp(2.25rem, 5vw, 3.5rem); line-height: 1; letter-spacing: -.035em; margin-bottom: 20px; }
.section__head { max-width: 40em; margin-bottom: clamp(40px, 6vw, 72px); }
.section__head p { color: var(--graphite); font-size: 1.25rem; }

/* Games */
.game {
  display: grid; grid-template-columns: 1.05fr 1fr; align-items: center;
  gap: clamp(32px, 6vw, 88px);
}
.game + .game { margin-top: clamp(72px, 10vw, 128px); }
.game:nth-of-type(even) .game__stage { order: 2; }

.game__stage {
  --stage-a: #333; --stage-b: #111; --glow: rgba(255, 255, 255, .2);
  position: relative; overflow: hidden;
  border-radius: 32px;
  aspect-ratio: 1 / 1.02;
  background:
    radial-gradient(70% 55% at 50% 30%, var(--glow), transparent 70%),
    linear-gradient(160deg, var(--stage-a), var(--stage-b));
}
.game--baseball .game__stage { --stage-a: #A24A21; --stage-b: #4A1C08; --glow: rgba(255, 196, 140, .35); }
.game--soccer   .game__stage { --stage-a: #1C8A4B; --stage-b: #063A1E; --glow: rgba(170, 255, 190, .28); }
.game--oracle   .game__stage { --stage-a: #1A2156; --stage-b: #05071A; --glow: rgba(245, 197, 66, .32); }
.game--signal   .game__stage { --stage-a: #0B1C13; --stage-b: #010302; --glow: rgba(74, 158, 107, .38); }
.game--hiss     .game__stage { --stage-a: #11406A; --stage-b: #061420; --glow: rgba(92, 188, 247, .38); }

.phone {
  position: absolute; left: 50%; top: 11%;
  width: min(54%, 300px); transform: translateX(-50%);
  padding: 9px; border-radius: 44px;
  background: #000;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, .14), 0 30px 60px rgba(0, 0, 0, .45);
}
.phone img { border-radius: 35px; width: 100%; }

.game__copy h3 { font-weight: 800; font-size: clamp(2.5rem, 5.4vw, 4.25rem); line-height: .95; letter-spacing: -.035em; margin-bottom: 14px; }
.game__hook { font-family: var(--display); font-weight: 700; font-size: clamp(1.25rem, 2vw, 1.5rem); line-height: 1.2; letter-spacing: -.01em; }
.game__copy > p:not(.game__hook) { color: var(--graphite); max-width: 32em; }

.facts {
  display: grid; grid-template-columns: repeat(3, auto); justify-content: start;
  gap: 8px 32px; margin: 28px 0 32px; padding-top: 20px;
  border-top: 1px solid var(--line);
}
.facts dt { font-size: .875rem; color: var(--graphite); }
.facts dd { margin: 2px 0 0; font-weight: 600; font-size: 1rem; }
.facts a { text-underline-offset: 3px; }

@media (max-width: 860px) {
  .game { grid-template-columns: 1fr; }
  .game:nth-of-type(even) .game__stage { order: 0; }
  .game__stage { aspect-ratio: 4 / 3.4; }
  .phone { width: min(46%, 240px); top: 9%; }
  .facts { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 480px) {
  .phone { width: 58%; border-radius: 34px; padding: 7px; }
  .phone img { border-radius: 27px; }
  .facts { gap: 12px 20px; }
  .btn { width: 100%; justify-content: center; }
  .btn--small { width: auto; }
}

/* YouTube Playables */
.playables { background: var(--mist); }
.playables__inner { display: grid; grid-template-columns: auto 1fr; gap: clamp(32px, 6vw, 80px); align-items: center; }
.playables__mark { width: clamp(140px, 22vw, 260px); }
.playables p { max-width: 34em; color: var(--graphite); }
@media (max-width: 700px) { .playables__inner { grid-template-columns: 1fr; } }

/* About + contact */
.about__inner { display: grid; grid-template-columns: 1.3fr 1fr; gap: clamp(40px, 7vw, 96px); align-items: start; }
.about p { max-width: 32em; color: var(--graphite); }
.about__contact { padding: 36px; border-radius: 28px; background: var(--mist); }
.about__contact h2 { font-size: clamp(1.75rem, 3vw, 2.25rem); margin-bottom: 12px; }
.about__contact p { margin-bottom: 24px; }
@media (max-width: 860px) { .about__inner { grid-template-columns: 1fr; } .about__contact { padding: 28px; } }

/* Footer */
.footer { border-top: 1px solid var(--line); padding: 48px 0 56px; font-size: .9375rem; }
.footer__inner { display: grid; grid-template-columns: auto 1fr; gap: 24px 48px; align-items: center; }
.footer__brand { display: flex; align-items: center; gap: 12px; font-family: var(--display); font-weight: 800; font-size: 1.25rem; letter-spacing: -.02em; }
.footer__brand img { width: 44px; }
.footer__games { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px 24px; justify-content: end; }
.footer__games a { text-decoration: none; color: var(--graphite); }
.footer__games a:hover { color: var(--ink); }
.footer__legal { grid-column: 1 / -1; color: var(--graphite); font-size: .8125rem; max-width: 60em; }
@media (max-width: 700px) { .footer__inner { grid-template-columns: 1fr; } .footer__games { justify-content: start; } }
