/* Stranger Dare - Electric Night, mirrored from the app's Theme.swift */

@font-face {
  font-family: "Darumadrop One";
  src: url("fonts/DarumadropOne-Regular.ttf") format("truetype");
  font-weight: 400;
  font-display: swap;
}
@font-face {
  font-family: "Baloo 2";
  src: url("fonts/Baloo2.ttf") format("truetype");
  font-weight: 400 800;
  font-display: swap;
}
@font-face {
  font-family: "Nunito";
  src: url("fonts/Nunito.ttf") format("truetype");
  font-weight: 400 800;
  font-display: swap;
}

:root {
  --base: #0F1223;
  --alt: #131730;
  --surface: #1A2038;
  --raised: #242B4F;
  --blue: #4D8DFF;
  --gold: #FFC53D;
  --gold-deep: #FF9D0A;
  --on-gold: #2B1A00;
  --green: #35E07A;
  --coral: #FF6B5B;
  --pink: #FF8FB5;
  --sky: #7FAFFF;
  --text: #FFFFFF;
  --text2: #A9B3D9;
  --muted: #6C77A3;
  --string: #FF8A7A;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

[hidden] { display: none !important; }

html { scroll-behavior: smooth; }

body {
  background: var(--base);
  color: var(--text);
  font-family: "Nunito", system-ui, sans-serif;
  font-size: 18px;
  line-height: 1.5;
  overflow-x: hidden;
}

h1, h2, .wordmark { font-family: "Darumadrop One", "Baloo 2", system-ui, sans-serif; font-weight: 400; line-height: 1.06; }

img { display: block; max-width: 100%; }

/* ---------- buttons ---------- */

.btn {
  display: inline-block;
  font-family: "Baloo 2", system-ui, sans-serif;
  font-weight: 800;
  color: var(--on-gold);
  text-decoration: none;
  border: 2px solid rgb(255 255 255 / 0.3);
  border-radius: 999px;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  position: relative;
  overflow: hidden;
}
.btn-gold {
  background: linear-gradient(180deg, var(--gold), var(--gold-deep));
  box-shadow: 0 8px 22px rgb(26 16 0 / 0.45);
}
.btn-gold::after {
  /* the app's sheen: light catch on the top half */
  content: "";
  position: absolute;
  inset: 0 0 55% 0;
  background: linear-gradient(180deg, rgb(255 255 255 / 0.26), rgb(255 255 255 / 0));
  pointer-events: none;
}
.btn:hover { transform: translateY(-2px); box-shadow: 0 12px 28px rgb(26 16 0 / 0.5); }
.btn:active { transform: translateY(1px) scale(0.98); }
.btn-small { padding: 11px 22px; font-size: 16px; }
.btn-big { padding: 20px 44px; font-size: 22px; }
.waitlist-form .btn { padding: 14px 28px; font-size: 18px; }

/* ---------- nav ---------- */

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 6.5vw;
  position: relative;
  z-index: 320;
}
.wordmark { font-size: 26px; }
.nav-btn-short { display: none; }

/* ---------- hero: the park ---------- */

.hero {
  position: relative;
  min-height: 100dvh;
  margin-top: -76px;   /* the field runs behind the nav */
  padding-top: 76px;
  background: url("img/field.png") center / cover no-repeat;
  image-rendering: pixelated;
  overflow: hidden;
}
.nav { background: linear-gradient(180deg, rgb(15 18 35 / 0.85), rgb(15 18 35 / 0)); }
.hero-inner {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 40px;
  max-width: 1400px;
  margin: 0 auto;
  padding: 60px 6.5vw 0;
  position: relative;
  z-index: 300;   /* UI floats far above the world layer (props and frogs use 0-140) */
}

/* props are placed by script.js using the exact crop the background gets */
.prop {
  position: absolute;
  pointer-events: none;
  image-rendering: pixelated;
}
.prop img { width: 100%; display: block; image-rendering: pixelated; }
.prop::before {
  /* the game's soft foot shadow (frogs carry their own in the pixel art) */
  content: "";
  position: absolute;
  left: 8%;
  right: 8%;
  bottom: 4%;
  height: 15%;
  background: radial-gradient(ellipse at center, rgb(0 10 0 / 0.35), transparent 68%);
  z-index: -1;
}
.hero-copy { padding-top: 40px; }
.hero h1 {
  font-size: clamp(44px, 5.4vw, 78px);
  text-shadow: 0 4px 14px rgb(0 0 0 / 0.55);
}
.hero-loop {
  margin-top: 26px;
  font-size: 19px;
  font-weight: 700;
  color: #FFFFFF;
  white-space: nowrap;
  text-shadow: 0 2px 8px rgb(0 0 0 / 0.6);
}
.phone {
  background: #05070F;
  border: 2px solid rgb(255 255 255 / 0.2);
  border-radius: 34px;
  padding: 10px;
  box-shadow: 0 26px 50px rgb(0 0 0 / 0.55);
}
.phone img { border-radius: 26px; }
.hero-phone {
  width: min(300px, 34vw);
  transform: rotate(-3deg);
  flex-shrink: 0;
  animation: floaty 3.2s ease-in-out infinite alternate;
}
@keyframes floaty {
  from { transform: rotate(-3deg) translateY(0); }
  to { transform: rotate(-3deg) translateY(-10px); }
}

.frog {
  position: absolute;
  bottom: 16%;
  left: 40%;
  width: 64px;
  image-rendering: pixelated;
  opacity: 0;   /* script places, then reveals: no pile-up flash at the default spot */
  transition: left 4s linear, bottom 4s linear;
}
.frog.ready { opacity: 1; }
.frog img { width: 100%; image-rendering: pixelated; }
.frog.flip img { transform: scaleX(-1); }

.waitlist {
  position: relative;
  z-index: 310;
  text-align: center;
}
.hero .waitlist { margin-top: -40px; padding-bottom: 90px; }
.waitlist-form {
  display: inline-flex;
  gap: 10px;
  background: rgb(15 18 35 / 0.85);
  border: 1.5px solid rgb(255 255 255 / 0.18);
  border-radius: 999px;
  padding: 8px;
  backdrop-filter: blur(8px);
}
.waitlist-form input {
  background: transparent;
  border: none;
  outline: none;
  color: var(--text);
  font-family: "Nunito", system-ui, sans-serif;
  font-size: 17px;
  padding: 0 14px;
  min-width: 240px;
}
.waitlist-form input::placeholder { color: var(--muted); }
.waitlist-done {
  display: inline-block;
  font-family: "Baloo 2", system-ui, sans-serif;
  font-weight: 800;
  font-size: 20px;
  color: var(--on-gold);
  background: linear-gradient(180deg, var(--gold), var(--gold-deep));
  border-radius: 999px;
  padding: 16px 34px;
}
.waitlist-error { color: var(--coral); font-size: 15px; margin-top: 10px; }

/* ---------- pennant transition strips (canvas, ported from the app) ---------- */

.pennant-strip {
  position: relative;
  height: 240px;
  background: var(--alt);
  overflow: hidden;
}
.pennant-strip.strip-base { background: var(--base); }
.pennant-strip canvas { display: block; width: 100%; height: 100%; }

/* ---------- steps ---------- */

.steps { background: var(--alt); padding: 96px 6.5vw; }
.section-inner { max-width: 1400px; margin: 0 auto; }
.steps-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
}
.steps h2 { font-size: clamp(34px, 3.4vw, 46px); margin-bottom: 36px; }
.step-list { list-style: none; }
.step-list li { display: flex; align-items: center; gap: 22px; margin-bottom: 26px; }
.step-num {
  font-family: "Darumadrop One", system-ui, sans-serif;
  font-size: 52px;
  line-height: 1;
  width: 44px;
}
.n1 { color: var(--coral); }
.n2 { color: var(--blue); }
.n3 { color: var(--gold); }
.step-name { font-family: "Baloo 2", system-ui, sans-serif; font-weight: 800; font-size: 24px; }
.screen-fan { position: relative; height: 560px; }
.fan-a { position: absolute; left: 0; top: 60px; width: 46%; transform: rotate(-6deg); }
.fan-b { position: absolute; right: 0; top: 0; width: 46%; transform: rotate(5deg); }

/* ---------- world trio ---------- */

.world { padding: 96px 6.5vw; }
.world-inner { text-align: center; }
.world h2 { font-size: clamp(34px, 3.4vw, 46px); margin-bottom: 52px; }
.trio {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 38px;
}
.trio .phone { width: 24%; }
.trio-a { transform: rotate(-4deg); }
.trio-b { width: 29% !important; }
.trio-c { transform: rotate(4deg); }

/* ---------- on-site forms (daily dares + feedback) ---------- */

.form-body { background: var(--base); }
.form-page {
  max-width: 640px;
  margin: 0 auto;
  padding: 40px 24px 90px;
}
.form-page h1 { font-size: clamp(34px, 4vw, 46px); margin-bottom: 12px; }
.form-intro { color: var(--text2); margin-bottom: 30px; }
.form-page label {
  display: block;
  font-family: "Baloo 2", system-ui, sans-serif;
  font-weight: 800;
  font-size: 15px;
  margin: 20px 0 8px;
}
.form-page input,
.form-page textarea {
  width: 100%;
  background: var(--surface);
  border: 1.5px solid rgb(255 255 255 / 0.12);
  border-radius: 14px;
  color: var(--text);
  font-family: "Nunito", system-ui, sans-serif;
  font-size: 17px;
  padding: 13px 15px;
  resize: vertical;
}
.form-page input:focus,
.form-page textarea:focus {
  outline: none;
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgb(255 197 61 / 0.25);
}
.form-page .btn { margin-top: 28px; }
.form-done {
  font-family: "Baloo 2", system-ui, sans-serif;
  font-weight: 800;
  font-size: 21px;
  color: var(--green);
  margin-top: 26px;
}

/* ---------- finale + footer ---------- */

.finale { background: var(--alt); text-align: center; padding: 120px 6.5vw; }
.finale-title { font-size: clamp(40px, 4.6vw, 64px); margin-bottom: 34px; }

.footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 30px 6.5vw;
  font-size: 14px;
  color: var(--muted);
}
.footer-links { display: flex; gap: 26px; }
.footer-links a { color: var(--text2); text-decoration: none; }
.footer-links a:hover { color: var(--text); }

/* ---------- mobile ---------- */

@media (max-width: 767px) {
  .nav { padding: 14px 20px; }
  .wordmark { font-size: 21px; }
  .nav-btn-long { display: none; }
  .nav-btn-short { display: inline; }
  .btn-small { padding: 10px 16px; font-size: 15px; }

  .hero-inner {
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding-top: 28px;
  }
  .hero-copy { padding-top: 0; }
  .hero h1 { font-size: 40px; }
  .hero-loop { font-size: 15px; white-space: normal; margin-left: auto; margin-right: auto; }
  .hero-phone { width: min(210px, 56vw); }
  .hero .waitlist { margin-top: 26px; padding-bottom: 70px; }
  .waitlist-form input { min-width: 150px; }
  .frog { width: 48px; bottom: 8%; }

  .pennant-strip { height: 130px; }

  .steps, .world { padding: 64px 24px; }
  .steps-grid { grid-template-columns: 1fr; gap: 44px; }
  .screen-fan { height: 400px; width: min(360px, 100%); max-width: 360px; margin: 0 auto; }
  .step-num { font-size: 40px; width: 34px; }
  .step-name { font-size: 20px; }

  .trio { flex-wrap: wrap; }
  .trio .phone { width: 44%; }
  .trio-b { width: 58% !important; order: -1; }

  .finale { padding: 80px 24px; }
  .footer { flex-direction: column; gap: 12px; }
}

/* ---------- reduced motion ---------- */

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hero-phone { animation: none; }
  .frog { transition: none; }
}
