/* ==========================================================================
   Pick Up — landing page
   Design tokens mirror client/tailwind.config.js ("Turf" system) so this
   page carries the same aura as the app itself.
   ========================================================================== */

:root {
  --bg: #f4f6f3;
  --surface: #ffffff;
  --ink: #1b241f;
  --muted: #6d7a71;
  --faint: #98a49b;
  --line: #e4eae4;
  /* Not one of the app's shared tokens — --muted (#6d7a71) matches the app's
     real value for brand fidelity but only clears ~4.1:1 on --bg, short of
     WCAG AA's 4.5:1 for body text. This darker step is for any copy here
     that isn't decorative (placeholder helper text, form notes, footer). */
  --muted-text: #5f6b63;

  --green: #1f7a4d;
  --green-deep: #186640;
  --green-soft: #e7f3ec;

  --amber: #d9822b;
  --amber-soft: #fbeede;

  /* logo bar colors, reused as sport accents */
  --blue: #1d4ed8;
  --red: #d92d3a;
  --mark-amber: #f5a623;
  --mark-green: #17a34a;

  --radius-card: 18px;
  --radius-field: 12px;
  --radius-pill: 9999px;

  --shadow-card: 0 1px 2px rgba(20, 40, 30, 0.05);
  --shadow-lift: 0 8px 24px -12px rgba(20, 40, 30, 0.25);
  --shadow-flower: 0 16px 40px -16px rgba(20, 40, 30, 0.28);

  --font: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;

  --max: 560px;
  --edge: 24px;
}

* { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  overflow-x: hidden;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; }
}

body {
  margin: 0;
  font-family: var(--font);
  background: var(--bg);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

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

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

/* wider inner wrap for sections that want more breathing room on desktop */
@media (min-width: 720px) {
  :root { --max: 620px; }
}
@media (min-width: 1080px) {
  :root { --max: 680px; }
}

/* ---------- reveal-on-scroll ---------- */
.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1), transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}
.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* ==========================================================================
   Hero
   ========================================================================== */

.hero {
  position: relative;
  padding: 56px 0 40px;
  text-align: center;
  overflow: hidden;
}

.hero-glow {
  position: absolute;
  top: -180px;
  left: 50%;
  width: 640px;
  height: 640px;
  transform: translateX(-50%);
  background: radial-gradient(closest-side, var(--green-soft), rgba(231, 243, 236, 0));
  pointer-events: none;
  z-index: 0;
}

/* ---------- flower of screenshots ---------- */

.flower {
  position: relative;
  /* fluid (not stepped) scaling: radius/shot-w/width all grow together with
     viewport width, so the ratio between petal extent and container size
     stays constant instead of jumping out of sync at a breakpoint — that
     mismatch previously let petals collide with .hero-title in the
     480-719px range. Verified clear of overlap from 320px up through the
     1080px+ cap. Tune all three clamp()s together if you resize petals. */
  width: clamp(280px, 80vw, 460px);
  aspect-ratio: 1;
  margin: 0 auto 8px;
  z-index: 1;
  --radius: clamp(104px, 24vw, 172px);
  --shot-w: clamp(80px, 18vw, 128px);
}

.flower-shot {
  position: absolute;
  top: 50%;
  left: 50%;
  width: var(--shot-w);
  border-radius: 14px;
  overflow: hidden;
  box-shadow: var(--shadow-flower);
  border: 3px solid var(--surface);
  background: var(--surface);
  --angle: calc(var(--i) * 72deg);
  animation-name: bloomShot, float;
  animation-duration: 0.9s, 6s;
  animation-timing-function: cubic-bezier(0.16, 1, 0.3, 1), ease-in-out;
  animation-delay: calc(var(--i) * 90ms + 120ms), calc(var(--i) * 0.4s + 1s);
  animation-fill-mode: both, none;
  animation-iteration-count: 1, infinite;
}

.flower-shot img { width: 100%; height: auto; }

@keyframes bloomShot {
  from {
    opacity: 0;
    transform: translate(-50%, -50%) rotate(var(--angle)) translateY(0) rotate(calc(var(--angle) * -1)) scale(0.5);
  }
  to {
    opacity: 1;
    transform: translate(-50%, -50%) rotate(var(--angle)) translateY(var(--radius)) rotate(calc(var(--angle) * -1)) scale(1);
  }
}

@keyframes float {
  /* the standalone `translate` property (not the `transform` shorthand,
     which bloomShot already animates) — composes with `transform`
     automatically with no animation-stacking conflict, and unlike
     margin-top this is compositor-only: no layout, just a GPU-cheap bob. */
  0%, 100% { translate: 0 0; }
  50% { translate: 0 -6px; }
}

.flower-center {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 2;
  animation: bloomCenter 0.7s cubic-bezier(0.16, 1, 0.3, 1) both;
  animation-delay: 0.5s;
}

@keyframes bloomCenter {
  from { opacity: 0; transform: translate(-50%, -50%) scale(0.7); }
  to { opacity: 1; transform: translate(-50%, -50%) scale(1); }
}

/* ---------- PU mark ---------- */

.mark {
  --size: 88px;
  width: var(--size);
  height: var(--size);
  border-radius: calc(var(--size) * 0.22);
  background: #14181c;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: calc(var(--size) * 0.13);
  box-shadow: var(--shadow-flower);
}
.mark-letters {
  color: #fff;
  font-weight: 800;
  font-style: italic;
  font-size: calc(var(--size) * 0.42);
  line-height: 1;
  letter-spacing: -0.04em;
  flex: 1;
  display: flex;
  align-items: center;
}
.mark-bar { display: flex; gap: calc(var(--size) * 0.03); width: 100%; }
.mark-bar span { flex: 1; height: max(2px, calc(var(--size) * 0.045)); border-radius: 999px; }
.mark-bar span:nth-child(1) { background: var(--blue); }
.mark-bar span:nth-child(2) { background: var(--red); }
.mark-bar span:nth-child(3) { background: var(--mark-amber); }
.mark-bar span:nth-child(4) { background: var(--mark-green); }

@media (min-width: 720px) { .mark { --size: 108px; } }

/* ---------- hero copy ---------- */

.hero-title {
  position: relative;
  z-index: 1;
  margin: 64px 0 0;
  font-size: clamp(2.4rem, 9vw, 3.6rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.02;
}
.hero-title .accent {
  display: block;
  color: var(--green);
  font-style: italic;
}

.hero-sub {
  position: relative;
  z-index: 1;
  margin: 14px auto 0;
  max-width: 380px;
  font-size: 1.05rem;
  color: var(--muted-text);
  line-height: 1.5;
}

/* ==========================================================================
   Placeholder text helper
   ========================================================================== */

.placeholder-text {
  /* --muted-text, not --muted or --faint: this text needs to clear 4.5:1
     contrast even though it reads as secondary/italic — --faint measured
     ~2.4:1 and --muted itself only ~4.1:1 on --bg, both fail WCAG AA. Set
     here (not just inherited) so it wins regardless of which same-
     specificity rule the cascade applies last on a given element. */
  color: var(--muted-text);
  font-style: italic;
}
.placeholder-text::before { content: "✎ "; font-style: normal; opacity: 0.7; }

/* ==========================================================================
   Signup form
   ========================================================================== */

.signup {
  position: relative;
  z-index: 1;
  margin: 28px auto 0;
  /* Matches --max's own widest tier (680px) — .wrap never actually gives
     this more room than that regardless of viewport, so anything past 680
     here would be dead weight. */
  max-width: 680px;
}

.signup-fields {
  display: flex;
  flex-direction: column;
  flex-wrap: wrap;
  gap: 10px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-card);
  padding: 10px;
  box-shadow: var(--shadow-card);
}

@media (min-width: 620px) {
  .signup-fields {
    flex-direction: row;
    align-items: center;
    border-radius: var(--radius-pill);
    padding: 6px 6px 6px 14px;
    gap: 6px;
  }
  /* The button wrapping to its own full-width line under the fields pill
     is the permanent, expected appearance here, not a fallback — .wrap's
     own width cap (--max, 680px at its widest) never leaves enough room
     for email + phone + button on one line, at any viewport size. It's
     designed to look intentional at this size: shared pill container, no
     visual seam between the fields row and the button below. */
  .signup-fields .btn-primary { flex: 1 1 auto; min-width: 150px; padding-left: 18px; padding-right: 18px; }
}

.signup-field {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius-field);
  background: var(--bg);
}
@media (min-width: 620px) {
  .signup-field { border: none; background: none; padding: 8px 10px; }
  .signup-field + .signup-field { border-left: 1px solid var(--line); border-radius: 0; }
}

.signup-field svg { flex: none; color: var(--faint); }

.signup-field input {
  flex: 1;
  min-width: 0;
  border: none;
  background: none;
  outline: none;
  font: inherit;
  /* 16px, not 0.98rem (15.68px) — iOS Safari auto-zooms the page on focus
     for any input under 16px, which on the primary mobile platform means
     tapping either field on the two signup forms would zoom the viewport. */
  font-size: 16px;
  color: var(--ink);
}
/* --muted-text, not --faint: these placeholders are each field's only
   visible label for sighted users (the real label is screen-reader-only
   via aria-label) — --faint measured ~2.4:1 and failed WCAG AA. */
.signup-field input::placeholder { color: var(--muted-text); }
.signup-field input:focus-visible {
  outline: 2px solid var(--green);
  outline-offset: 2px;
  border-radius: 4px;
}

.btn-primary {
  appearance: none;
  border: none;
  cursor: pointer;
  background: var(--green);
  color: #fff;
  font: inherit;
  font-weight: 700;
  font-size: 0.98rem;
  padding: 14px 22px;
  border-radius: var(--radius-pill);
  white-space: nowrap;
  transition: background 0.2s ease, transform 0.15s ease;
}
.btn-primary:hover { background: var(--green-deep); }
.btn-primary:active { transform: scale(0.97); }
.btn-primary:disabled { opacity: 0.6; cursor: default; transform: none; }

.signup-note {
  margin: 10px 0 0;
  font-size: 0.8rem;
  color: var(--muted-text);
  text-align: center;
}

.signup-error {
  display: none;
  margin: 10px 2px 0;
  font-size: 0.85rem;
  color: var(--red);
  text-align: center;
}
.signup-error.is-visible { display: block; }

.signup-success {
  display: none;
  align-items: center;
  gap: 10px;
  justify-content: center;
  padding: 18px;
  border-radius: var(--radius-card);
  background: var(--green-soft);
  color: var(--green-deep);
  font-weight: 600;
}
.signup-success.is-visible { display: flex; }
.signup.is-submitted .signup-fields,
.signup.is-submitted .signup-note { display: none; }

/* ==========================================================================
   Sections
   ========================================================================== */

.section {
  padding: 64px 0;
}

.section-eyebrow {
  display: inline-block;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--green);
  background: var(--green-soft);
  padding: 5px 12px;
  border-radius: var(--radius-pill);
  margin-bottom: 14px;
}

.section-title {
  font-size: clamp(1.6rem, 5vw, 2.1rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.15;
  margin: 0 0 12px;
}

.section-lede {
  color: var(--muted-text);
  font-size: 1.02rem;
  line-height: 1.55;
  margin: 0 0 36px;
  max-width: 440px;
}

/* ---------- how it works ---------- */

.steps {
  display: grid;
  gap: 16px;
}
@media (min-width: 640px) {
  .steps { grid-template-columns: repeat(3, 1fr); }
}

.step {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-card);
  padding: 22px;
  box-shadow: var(--shadow-card);
}

.step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 999px;
  background: var(--green-soft);
  color: var(--green-deep);
  font-weight: 800;
  font-size: 0.95rem;
  margin-bottom: 14px;
}

.step p { margin: 0; font-size: 0.98rem; line-height: 1.5; }

/* ---------- sports showcase ---------- */

.sports-grid {
  display: grid;
  gap: 16px;
  align-items: start;
}
@media (min-width: 640px) {
  .sports-grid { grid-template-columns: 1fr 1fr; }
}

.sport-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-card);
  overflow: hidden;
  box-shadow: var(--shadow-card);
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.4s ease;
}
.sport-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lift); }

.sport-art {
  width: 100%;
  aspect-ratio: 4 / 3;
  display: block;
}

.sport-card-body { padding: 18px 20px 22px; }

.sport-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.78rem;
  font-weight: 700;
  margin-bottom: 8px;
}
/* Neither --amber (2.93:1) nor --mark-amber (2.03:1) clear 4.5:1 at this
   tag's actual rendered size (~12.5px/700) — this is a one-off darker step
   used only here, not a shared token, computed to ~5.9:1 on white. */
.sport-tag--basketball { color: #96530f; }
.sport-tag--baseball { color: var(--blue); }
.sport-tag .dot { width: 7px; height: 7px; border-radius: 999px; background: currentColor; }

.sport-card h3 { margin: 0; font-size: 1.05rem; font-weight: 700; }

/* ---------- bottom cta ---------- */

.cta-bottom {
  text-align: center;
  background: var(--surface);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.cta-bottom .section-lede { margin-left: auto; margin-right: auto; }

/* ==========================================================================
   Footer
   ========================================================================== */

footer {
  padding: 40px 0 56px;
  text-align: center;
}

.footer-mark {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-bottom: 10px;
}
.footer-wordmark { font-weight: 800; letter-spacing: -0.02em; font-size: 1.05rem; }

footer p {
  margin: 0;
  color: var(--muted-text);
  font-size: 0.85rem;
}
