/* fanapult.com home. The first screen is built from the app's own pieces (the lock-screen alert
   and the live pick card from onboarding) at a real moment of a real slip; the sections below
   use the same slip's real alerts and picks. Colors are the app's (Utilities/Theme.swift);
   site.css holds the tokens. */

body.home {
  background:
    radial-gradient(60% 40% at 50% 0%, rgba(26, 140, 255, 0.10), transparent 70%),
    var(--page);
}

/* ---------- First screen ---------- */
.hero-home {
  position: relative;
  height: 100svh; min-height: 640px; max-height: 1100px;
  display: grid;
  grid-template-rows: auto auto minmax(0, 1fr);
  overflow: hidden;
  background: radial-gradient(70% 55% at 50% 100%, rgba(26, 140, 255, 0.22), transparent 70%);
}
.topbar { display: flex; align-items: center; justify-content: space-between; padding: 18px 28px 0; }
.topbar .brand img { height: 30px; width: auto; }
.topbar nav { display: flex; gap: 22px; font-size: 14px; font-weight: 600; }
.topbar nav a { color: var(--muted); }
.topbar nav a:hover { color: var(--text); text-decoration: none; }

/* The words: the app's Welcome screen. */
.pitch { text-align: center; padding: clamp(14px, 3.2vh, 40px) 20px 0; }
.pitch h1 {
  margin: 0;
  font-size: clamp(34px, min(6.4vw, 7.4vh), 76px);
  line-height: 0.98; font-weight: 800; letter-spacing: -0.02em;
  text-wrap: balance;
}
.pitch h1 span { color: var(--blue); }
.pitch p.lead { margin: clamp(10px, 1.8vh, 18px) auto 0; max-width: 34em; color: var(--muted); font-size: clamp(15px, 2vh, 19px); font-weight: 500; line-height: 1.45; }
.cta { display: flex; justify-content: center; margin-top: clamp(12px, 2.2vh, 24px); }
.works { margin: clamp(10px, 1.6vh, 16px) 0 0; font-size: 10px; font-weight: 800; letter-spacing: 0.14em; color: var(--tertiary); }

/* The stage: a phone in the middle, the app's pick cards on each side. The phone runs off the
   bottom of the first screen on purpose, fading into the page. */
.stage {
  position: relative;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: clamp(20px, 3vw, 48px);
  padding: clamp(16px, 3vh, 34px) 24px 0;
  overflow: hidden;
  min-height: 0;
}
.stage::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 90px;
  background: linear-gradient(180deg, transparent, var(--page));
  pointer-events: none;
}
.side { display: flex; flex-direction: column; gap: 12px; padding-top: clamp(24px, 6vh, 90px); min-width: 0; }
.side.left { align-items: flex-end; }
.side.right { align-items: flex-start; padding-top: clamp(40px, 9vh, 130px); }

/* Phone */
.phone {
  --w: clamp(250px, min(34vh, 30vw), 360px);
  width: var(--w);
  height: calc(var(--w) * 2.13);
  border-radius: calc(var(--w) * 0.155);
  padding: calc(var(--w) * 0.035);
  background: #1b1b1f;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.14), 0 0 0 calc(var(--w) * 0.012) #2c2c31, 0 40px 90px rgba(0, 0, 0, 0.6);
}
.screen {
  position: relative; height: 100%;
  border-radius: calc(var(--w) * 0.12);
  overflow: hidden;
  background:
    radial-gradient(90% 60% at 80% 10%, rgba(200, 56, 3, 0.30), transparent 60%),
    radial-gradient(120% 70% at 10% 90%, rgba(26, 140, 255, 0.35), transparent 65%),
    linear-gradient(180deg, #0b1c3a 0%, #0e0e10 75%);
  display: flex; flex-direction: column; align-items: stretch;
  padding: calc(var(--w) * 0.05) calc(var(--w) * 0.04) 0;
}
.island { align-self: center; width: 34%; height: calc(var(--w) * 0.1); border-radius: 999px; background: #000; }
.clock { text-align: center; color: rgba(255, 255, 255, 0.92); margin-top: calc(var(--w) * 0.05); }
.clock .date { font-size: calc(var(--w) * 0.05); font-weight: 600; }
.clock .time { font-size: calc(var(--w) * 0.25); line-height: 1; font-weight: 700; letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.phone .alerts { display: flex; flex-direction: column; gap: calc(var(--w) * 0.022); margin-top: calc(var(--w) * 0.07); }

/* LockScreenAlert (Views/Auth/HowItWorksView.swift). Sized from --w inside the phone, and from
   a fixed width in the timeline below. */
.alert {
  --w: 330px;
  display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: start;
  gap: calc(var(--w) * 0.03);
  padding: calc(var(--w) * 0.034) calc(var(--w) * 0.037); border-radius: calc(var(--w) * 0.056);
  background: rgba(40, 40, 46, 0.62);
  -webkit-backdrop-filter: blur(22px) saturate(160%); backdrop-filter: blur(22px) saturate(160%);
  box-shadow: 0 6px 14px rgba(0, 0, 0, 0.35);
  color: #fff; text-align: left;
  font-size: calc(var(--w) * 0.041); line-height: 1.3;
}
.phone .alert { --w: inherit; animation: drop 0.55s cubic-bezier(0.2, 0.8, 0.2, 1) both; }
.alert .icon { width: calc(var(--w) * 0.11); height: calc(var(--w) * 0.11); border-radius: 22%; background: var(--page); padding: calc(var(--w) * 0.016); }
.alert .head { display: flex; justify-content: space-between; gap: 8px; font-size: 0.8em; color: rgba(255, 255, 255, 0.62); }
.alert .head b { font-weight: 600; letter-spacing: 0.02em; color: rgba(255, 255, 255, 0.72); }
.alert .title { font-weight: 600; font-size: 1.04em; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.alert .msg { color: rgba(255, 255, 255, 0.85); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.phone .alert:nth-child(1) { animation-delay: 0.9s; }
.phone .alert:nth-child(2) { animation-delay: 0.55s; }
.phone .alert:nth-child(3) { animation-delay: 0.25s; }
@keyframes drop { from { opacity: 0; transform: translateY(-14px) scale(0.98); } to { opacity: 1; transform: none; } }

/* LivePickVisual + TeamBackdrop (Views/Designs/DesignKit.swift): team color fading to the page,
   the team logo at 14% in the top corner, the player's photo, the count and the sweat bar. */
.pick {
  --team: #0b1c3a;
  position: relative; overflow: hidden;
  width: clamp(210px, min(19vw, 30vh), 280px); aspect-ratio: 5 / 6;
  border-radius: 20px;
  background: linear-gradient(135deg, var(--team) 0%, rgba(11, 28, 58, 0.55) 55%, var(--page) 100%);
  border: 1px solid var(--border);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.55);
  animation: rise 0.7s cubic-bezier(0.2, 0.8, 0.2, 1) 0.15s both;
}
.side.right .pick { animation-delay: 0.3s; }
.pick .logo { position: absolute; width: 78%; top: -12%; right: -16%; opacity: 0.14; }
/* The photo fades out at the bottom, the way the app's cutout sits in its gradient. */
.pick .photo {
  position: absolute; right: -4%; bottom: 40%; width: 86%;
  -webkit-mask-image: linear-gradient(180deg, #000 70%, transparent 100%);
  mask-image: linear-gradient(180deg, #000 70%, transparent 100%);
}
.pick .shade { position: absolute; inset: 0; background: linear-gradient(180deg, transparent 50%, rgba(0, 0, 0, 0.6) 64%, rgba(0, 0, 0, 0.9) 80%); }
.pick .info { position: absolute; left: 16px; right: 16px; bottom: 16px; display: grid; gap: 4px; color: #fff; }
.pick .when { font-size: 10.5px; font-weight: 700; letter-spacing: 0.1em; color: rgba(255, 255, 255, 0.82); display: flex; align-items: center; gap: 6px; }
.dot { width: 6px; height: 6px; border-radius: 50%; background: var(--live); box-shadow: 0 0 0 0 rgba(255, 75, 66, 0.6); animation: pulse 1.6s ease-out infinite; }
.pick .name { font-size: 21px; font-weight: 700; line-height: 1.15; }
.pick .market { font-size: 13px; font-weight: 600; color: rgba(255, 255, 255, 0.85); }
.pick .row { display: flex; align-items: baseline; justify-content: space-between; margin-top: 2px; }
.pick .count { font-size: 28px; font-weight: 700; font-stretch: condensed; font-variant-numeric: tabular-nums; letter-spacing: -0.01em; }
.pick .count small { font-size: 16px; color: rgba(255, 255, 255, 0.6); font-weight: 600; }
.pick .state { font-size: 12px; font-weight: 700; letter-spacing: 0.06em; }
.pick .state.hit { color: var(--mint); }
.pick .state.live { color: var(--live); }
.pick .bar { height: 5px; border-radius: 3px; background: #36363b; overflow: hidden; }
.pick .bar i { display: block; height: 100%; border-radius: 3px; transform-origin: left; animation: fill 0.9s cubic-bezier(0.2, 0.8, 0.2, 1) 0.6s both; }
.pick .bar i.hit { width: 100%; background: var(--mint); }
.pick .bar i.live { width: 75%; background: var(--blue); }
@keyframes rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
@keyframes fill { from { transform: scaleX(0.35); } to { transform: none; } }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(255, 75, 66, 0.55); } 100% { box-shadow: 0 0 0 7px rgba(255, 75, 66, 0); } }

/* The play that moved it (Play.subline in Models/Game.swift). */
.lastplay {
  width: clamp(210px, min(19vw, 30vh), 280px);
  background: var(--card); border: 1px solid var(--border); border-radius: 14px;
  padding: 10px 12px; font-size: 12.5px; line-height: 1.35; color: var(--text);
  animation: rise 0.7s cubic-bezier(0.2, 0.8, 0.2, 1) 0.5s both;
}
.lastplay b { display: block; font-size: 10px; letter-spacing: 0.1em; color: var(--tertiary); margin-bottom: 3px; }

/* The line right under the phone that says where all this came from. */
.proof { text-align: center; font-size: 12.5px; color: var(--tertiary); margin: 0; padding: 14px 20px 0; }

/* ---------- Sections below ---------- */
.sec { max-width: 1080px; margin: 0 auto; padding: clamp(64px, 10vh, 110px) 24px 0; }
.sec .eyebrow { margin-bottom: 12px; }
.sec h2 { font-size: clamp(30px, 4.4vw, 48px); line-height: 1.05; letter-spacing: -0.015em; margin: 0 0 14px; text-wrap: balance; }
.sec h2 span { color: var(--blue); }
.sec p.sub { color: var(--muted); font-size: 18px; line-height: 1.55; max-width: 36em; margin: 0; }
.center { text-align: center; }
.center p.sub { margin: 0 auto; }

/* 166 plays, 6 buzzes: the slip's alerts in order, on a line through the game. */
.timeline { list-style: none; margin: 40px 0 0; padding: 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 28px 18px; position: relative; }
.timeline li { display: grid; gap: 10px; min-width: 0; }
.timeline .when { font-size: 12px; font-weight: 700; letter-spacing: 0.08em; color: var(--muted); display: flex; align-items: center; gap: 8px; }
.timeline .when::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--blue); }
.timeline li.final .when::before { background: var(--mint); }
.timeline .alert { --w: 320px; }
.quiet { margin: 26px 0 0; font-size: 14px; color: var(--tertiary); text-align: center; }

/* Any slip, any book: a plain slip turns into Fanapult's picks (AddSlipVisual). */
.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); gap: clamp(28px, 5vw, 64px); align-items: center; }
.read { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1.15fr); gap: 16px; align-items: center; }
.slip {
  background: #fff; color: #111; border-radius: 12px; padding: 14px; transform: rotate(-2deg);
  font-size: 12px; box-shadow: 0 18px 40px rgba(0, 0, 0, 0.45); display: grid; gap: 8px;
}
.slip .top { display: flex; justify-content: space-between; font-weight: 700; font-size: 13px; }
.slip .top span { color: #777; font-weight: 600; font-size: 12px; }
.slip .leg { border-bottom: 1px solid rgba(0, 0, 0, 0.08); padding-bottom: 7px; }
.slip .leg b { display: block; font-weight: 600; }
.slip .leg span { color: #777; font-size: 11px; }
.slip .game { color: #777; font-size: 10.5px; }
.arrow { color: var(--blue); font-size: 26px; font-weight: 800; }
.picks { background: var(--card); border: 1px solid var(--border-strong); border-radius: var(--radius); box-shadow: 0 18px 40px rgba(0, 0, 0, 0.4); overflow: hidden; }
.picks .p { display: grid; grid-template-columns: 44px minmax(0, 1fr) auto; gap: 12px; align-items: center; padding: 10px 14px; }
.picks .p + .p { border-top: 1px solid var(--border); }
.picks .face { width: 44px; height: 44px; border-radius: 50%; overflow: hidden; position: relative; background: linear-gradient(135deg, #0b1c3a, rgba(11, 28, 58, 0.55)); }
.picks .face img { position: absolute; width: 210%; max-width: none; left: -55%; top: 3px; }
.picks .n { font-weight: 600; font-size: 15px; line-height: 1.25; }
.picks .m { font-size: 13px; color: var(--muted); }
.picks .ok { width: 20px; height: 20px; border-radius: 50%; background: var(--mint); display: grid; place-items: center; }
.picks .ok::after { content: ""; width: 8px; height: 4px; border: solid #0e0e10; border-width: 0 0 2px 2px; transform: rotate(-45deg) translate(1px, -1px); }

/* Three plain cards: crew, record, privacy. */
.trio { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; margin-top: 36px; }
.trio .card h3 { font-size: 19px; }
.trio .chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.trio .chips span { font-size: 12px; font-weight: 700; padding: 6px 10px; border-radius: 999px; background: var(--elevated); color: var(--text); }
.trio .chips span.on { background: rgba(26, 140, 255, 0.18); color: var(--blue); }

/* The last call. */
.closer { text-align: center; padding: clamp(80px, 12vh, 130px) 24px clamp(70px, 10vh, 110px); }
.closer h2 span { color: var(--blue); }
.closer .facts { margin: 16px 0 0; color: var(--tertiary); font-size: 13px; }

/* Phones: the two pick cards and the play sit right under the phone instead of beside it. */
.mpicks { display: none; }

/* ---------- Narrow screens ---------- */
@media (max-width: 860px) {
  .stage { grid-template-columns: 1fr; justify-items: center; }
  .side { display: none; }
  .topbar { padding: 14px 16px 0; }
  .topbar nav { gap: 14px; }
  .topbar nav .hide-sm { display: none; }
  .works { display: none; }
  .phone { --w: clamp(250px, min(78vw, 40vh), 340px); }
  .timeline { grid-template-columns: 1fr; }
  .split, .trio { grid-template-columns: 1fr; }
  .read { grid-template-columns: 1fr; justify-items: center; }
  .read .arrow { transform: rotate(90deg); }
  .slip, .picks { width: min(100%, 340px); }
  .mpicks { display: grid; gap: 12px; padding: 18px 16px 0; max-width: 460px; margin: 0 auto; }
  .mscore { margin: 0; display: flex; align-items: center; justify-content: center; gap: 8px; font-size: 11px; font-weight: 700; letter-spacing: 0.1em; color: var(--muted); }
  .mrow { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
  .mpicks .pick { width: 100%; border-radius: 16px; }
  .mpicks .pick .info { left: 12px; right: 12px; bottom: 12px; gap: 3px; }
  .mpicks .pick .when { font-size: 9.5px; }
  .mpicks .pick .score { display: none; }
  .mpicks .pick .name { font-size: 16px; }
  .mpicks .pick .market { font-size: 11.5px; }
  .mpicks .pick .count { font-size: 22px; }
  .mpicks .pick .count small { font-size: 13px; }
  .mpicks .pick .state { font-size: 10.5px; }
  .mpicks .lastplay { width: 100%; }
  .timeline { gap: 10px; }
  .timeline .when { display: none; }
}
@media (max-width: 860px) and (max-height: 760px) {
  .pitch p.lead { display: none; }
}
@media (max-width: 1100px) and (min-width: 861px) {
  .timeline { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (prefers-reduced-motion: reduce) {
  .alert, .pick, .pick .bar i, .lastplay, .dot { animation: none; }
}
