/* =========================================================
   GRAFT home page styles (index.html only)
   Module-specific styling extracted verbatim from
   draft-v4-hybrid.html: hero, proof, sports carousel, pillars,
   about mini, founder mini. Plus .mod base and the sports
   pagination dots. Depends on tokens.css + base.css +
   components.css. Pricing card CSS lives in components.css
   (shared). Do not redefine shared classes here.

   NOTE for PART 3/4: .mod base and .founder-card here may want
   extracting to a shared stylesheet if /about reuses them.
   ========================================================= */

/* Anchored sections clear the sticky header on jump */
[id] { scroll-margin-top: 88px; }

/* ============ AI-SEO DEFINITION BLOCK (quiet prose, not a box) ============ */
.def-section { padding: 8px 0 40px; position: relative; z-index: 1; }
.def-block {
  font-size: 19px;
  line-height: 1.6;
  color: var(--dim);
  text-align: center;
  max-width: 760px;
  margin: 0 auto;
}
.def-block strong { color: var(--lime); font-weight: 700; }

/* ============ MODULE BASE ============ */
.mod { padding: 120px 0; position: relative; z-index: 1; }
.mod h2 {
  font-size: clamp(40px, 5vw, 64px);
  line-height: 1.05;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 24px;
}
.mod h2 .dot { color: var(--lime); }
.mod-sub {
  font-size: 18px;
  color: var(--dim);
  max-width: 560px;
  line-height: 1.55;
}

/* ============ MODULE 01 - HERO ============ */
.hero { padding: 80px 0 100px; position: relative; }
.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 1fr;
  gap: 64px;
  align-items: center;
}
.hero h1 {
  font-size: clamp(48px, 6.5vw, 88px);
  line-height: 0.98;
  font-weight: 700;
  letter-spacing: -0.025em;
  margin-bottom: 28px;
}
.hero h1 .dot { color: var(--lime); display: inline-block; }
.hero h1 .word {
  display: inline-block;
  opacity: 0;
  transform: translateY(40px);
  animation: heroWordIn 0.8s var(--ease-out) forwards;
}
.hero h1 .word:nth-child(1) { animation-delay: 0.1s; }
.hero h1 .word:nth-child(2) { animation-delay: 0.2s; }
.hero h1 .word:nth-child(3) { animation-delay: 0.4s; }
.hero h1 .word:nth-child(4) { animation-delay: 0.5s; }
@keyframes heroWordIn {
  to { opacity: 1; transform: translateY(0); }
}
.hero-sub {
  font-size: 20px;
  color: var(--dim);
  max-width: 480px;
  margin-bottom: 40px;
  line-height: 1.5;
  opacity: 0;
  animation: fadeIn 0.6s ease-out 0.7s forwards;
}
.hero-cta-row {
  display: flex; align-items: center; gap: 16px;
  flex-wrap: wrap; /* CTAs wrap instead of clipping on narrow screens */
  margin-bottom: 24px;
  opacity: 0;
  animation: fadeIn 0.6s ease-out 0.9s forwards;
}
@keyframes fadeIn { to { opacity: 1; } }

.hero-micro {
  font-size: 13px; color: var(--dim);
  display: flex; align-items: center; gap: 8px;
  opacity: 0;
  animation: fadeIn 0.6s ease-out 1.1s forwards;
}
.hero-micro::before {
  content: ""; width: 6px; height: 6px;
  background: var(--lime); border-radius: 50%;
  box-shadow: 0 0 0 4px var(--lime-soft);
  animation: glow 2.5s ease-in-out infinite;
  flex: 0 0 auto;
}
@keyframes glow { 0%, 100% { opacity: 1; } 50% { opacity: 0.5; } }

/* HERO PHONE PREVIEW */
.hero-product {
  position: relative;
  padding: 24px;
  opacity: 0;
  animation: fadeIn 0.8s ease-out 0.5s forwards;
}
.hero-phone {
  width: 100%; max-width: 360px;
  aspect-ratio: 9/19;
  background: linear-gradient(135deg, #1a1a1a 0%, #0a0a0a 100%);
  border: 1px solid var(--border-2);
  border-radius: 36px;
  padding: 16px 12px;
  position: relative;
  box-shadow:
    0 40px 80px rgba(0, 0, 0, 0.5),
    0 0 0 1px rgba(255, 255, 255, 0.05),
    0 0 80px var(--lime-soft);
  margin: 0 auto;
  animation: phoneFloat 6s ease-in-out infinite;
}
.hero-phone-screen {
  width: 100%; height: 100%;
  border-radius: 22px;
  background: var(--bg);
  overflow: hidden;
}
/* Real app screenshots fill the hero + proof phone screens full-bleed (no inner chrome,
   the screenshots include the app's own header). */
.hero-phone-screen img,
.proof-phone-screen img {
  width: 100%; height: 100%;
  object-fit: cover; object-position: top center;
  border-radius: 22px; display: block;
}

/* ===== HERO AMBIENT LAYERS (decorative, zero JS; ported from the approved proto) ===== */
/* Organic lime glow: 3 soft asymmetric blooms drifting independently. On the home page
   these replace the global body::before single centred glow (reconciled just below) so the
   hero reads as one coherent organic glow, not a doubled centred blob. */
.hero-glow {
  position: absolute; inset: 0; z-index: 0;
  pointer-events: none; overflow: hidden;
}
.hero-glow span {
  position: absolute; border-radius: 50%;
  background: radial-gradient(circle, var(--lime-soft) 0%, transparent 66%);
  will-change: transform, opacity;
}
.hg1 { top: -18%; left: 1%;  width: 46vw; height: 46vw; opacity: 0.55; animation: gdrift1 15s ease-in-out infinite alternate; }
.hg2 { top: 22%;  left: 63%; width: 38vw; height: 38vw; opacity: 0.42; animation: gdrift2 19s ease-in-out infinite alternate; }
.hg3 { bottom: -24%; left: 33%; width: 44vw; height: 44vw; opacity: 0.32; animation: gdrift3 17s ease-in-out infinite alternate; }
@keyframes gdrift1 { from { transform: translate(0,0) scale(1); }    to { transform: translate(7%,5%) scale(1.14); } }
@keyframes gdrift2 { from { transform: translate(0,0) scale(1.06); } to { transform: translate(-6%,7%) scale(0.94); } }
@keyframes gdrift3 { from { transform: translate(0,0) scale(1); }    to { transform: translate(5%,-6%) scale(1.12); } }

/* Floating sport icons: ambient texture layer behind the hero content. */
.hero-float {
  position: absolute; inset: 0; z-index: 1;
  pointer-events: none; overflow: hidden;
}
.hf-ico {
  position: absolute; color: var(--lime); display: block; will-change: transform;
  animation-timing-function: ease-in-out; animation-iteration-count: infinite; animation-direction: alternate;
  filter: drop-shadow(0 0 14px rgba(200, 245, 66, 0.15));
}
.hf-ico svg { width: 100%; height: 100%; display: block; }
@keyframes drift1 { from { transform: translateY(0) rotate(-3deg); }   to { transform: translateY(-22px) rotate(3deg); } }
@keyframes drift2 { from { transform: translate(0,0) rotate(2deg); }   to { transform: translate(16px,-16px) rotate(-4deg); } }
@keyframes drift3 { from { transform: translateY(-6px) rotate(4deg); } to { transform: translateY(14px) rotate(-2deg); } }
.hf-a1 { animation-name: drift1; }
.hf-a2 { animation-name: drift2; }
.hf-a3 { animation-name: drift3; }

/* Hero content sits above both ambient layers and stays fully clickable (.c base is z-index 1). */
.hero > .c { z-index: 2; }

/* Reconcile with base.css: the global centred body::before glow would double with the blooms.
   home.css loads on the home page only, so /about /pricing /privacy /terms keep their glow. */
body::before { display: none; }

/* Mobile: drop the floating icons so the copy dominates; the glow blooms stay. */
@media (max-width: 640px) {
  .hero-float { display: none; }
}

/* ============ MODULE 02 - PROOF ============ */
.proof { padding: 120px 0; }
.proof-grid {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 80px;
  align-items: center;
}
.proof-captions { display: grid; gap: 12px; margin-top: 40px; }
.proof-cap {
  padding: 18px 20px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: var(--bg-1);
  display: grid;
  grid-template-columns: 36px 1fr 20px;
  gap: 16px; align-items: center;
  transition: all 0.3s var(--ease);
  cursor: pointer;
  position: relative; overflow: hidden;
}
.proof-cap::before {
  content: ""; position: absolute;
  left: 0; top: 0; bottom: 0; width: 0;
  background: var(--lime); opacity: 0.06;
  transition: width 0.4s var(--ease-out);
}
.proof-cap:hover::before { width: 100%; }
.proof-cap:hover {
  border-color: var(--lime);
  transform: translateX(8px);
}
.proof-cap-num {
  font-size: 18px; color: var(--lime); font-weight: 700;
  letter-spacing: 0.1em; position: relative;
}
.proof-cap-text { font-size: 16px; line-height: 1.4; position: relative; }
.proof-cap-arrow {
  font-size: 18px; color: var(--lime);
  opacity: 0; transform: translateX(-8px);
  transition: all 0.3s var(--ease-out);
  position: relative;
}
.proof-cap:hover .proof-cap-arrow { opacity: 1; transform: translateX(0); }

.proof-phone {
  width: 100%; max-width: 400px;
  aspect-ratio: 9/19;
  background: linear-gradient(135deg, #1a1a1a 0%, #0a0a0a 100%);
  border: 1px solid var(--border-2);
  border-radius: 40px;
  padding: 20px 14px;
  margin: 0 auto;
  box-shadow: 0 60px 120px rgba(0,0,0,0.6), 0 0 100px var(--lime-soft);
  animation: phoneFloat 7s ease-in-out infinite;
  animation-delay: 1s;
}
.proof-phone-screen {
  width: 100%; height: 100%;
  border-radius: 22px;
  background: var(--bg);
  overflow: hidden;
}

/* ============ MODULE 03 - SPORTS ============ */
.sports { padding: 120px 0; }
.sports-header {
  display: flex; justify-content: space-between; align-items: end;
  margin-bottom: 56px;
  gap: 32px;
}
.sports-header-left h2 { margin-bottom: 16px; }
.sports-scroll-hint {
  font-size: 13px; color: var(--dim);
  display: flex; align-items: center; gap: 8px;
  white-space: nowrap;
}
.sports-scroll-hint .arrow {
  display: inline-block;
  animation: hintBounce 1.5s ease-in-out infinite;
}
@keyframes hintBounce {
  0%, 100% { transform: translateX(0); }
  50% { transform: translateX(6px); }
}
.sports-track {
  display: flex; gap: 16px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  padding: 8px 0 24px;
  scrollbar-width: thin;
  scrollbar-color: var(--dimmer) transparent;
  -webkit-overflow-scrolling: touch;
  cursor: grab;
}
.sports-track.dragging { cursor: grabbing; scroll-snap-type: none; }
.sports-track.dragging .sport-card { pointer-events: none; }
.sports-track::-webkit-scrollbar { height: 6px; }
.sports-track::-webkit-scrollbar-track { background: transparent; }
.sports-track::-webkit-scrollbar-thumb { background: var(--dimmer); border-radius: 4px; }
.sport-card {
  flex: 0 0 280px;
  scroll-snap-align: start;
  background: var(--bg-1);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 24px;
  transition: transform 0.35s var(--ease), border-color 0.3s, background 0.3s, box-shadow 0.4s;
  position: relative; overflow: hidden;
}
/* Editorial-style hover: lime line draws across the top */
.sport-card::before {
  content: ""; position: absolute;
  top: 0; left: 0; height: 2px; width: 0;
  background: var(--lime);
  transition: width 0.5s var(--ease-out);
}
.sport-card:hover::before { width: 100%; }
.sport-card:hover {
  background: var(--bg-2);
  border-color: var(--lime);
  transform: translateY(-8px);
  box-shadow: 0 24px 60px rgba(0,0,0,0.4), 0 0 40px var(--lime-soft);
}
.sport-card-icon-wrap {
  width: 48px; height: 48px;
  background: var(--lime-soft);
  border: 1px solid var(--lime-glow);
  border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 20px;
  color: var(--lime);
  transition: transform 0.4s var(--ease-spring), background 0.3s;
  position: relative;
}
.sport-card-icon-wrap::after {
  content: ""; position: absolute; inset: -4px;
  border-radius: 14px;
  border: 1px solid var(--lime);
  opacity: 0;
  transition: opacity 0.3s;
}
.sport-card:hover .sport-card-icon-wrap {
  transform: rotate(-8deg) scale(1.08);
  background: rgba(200, 245, 66, 0.18);
}
.sport-card:hover .sport-card-icon-wrap::after { opacity: 0.4; animation: iconPulse 1.5s ease-out infinite; }
@keyframes iconPulse {
  0% { opacity: 0.4; transform: scale(1); }
  100% { opacity: 0; transform: scale(1.3); }
}
/* App tab icons (pure currentColor) inherit the box's color: var(--lime). */
.sport-card-icon-wrap svg { width: 40px; height: 40px; }
.sport-card-num {
  font-size: 11px; color: var(--dim);
  font-weight: 700; letter-spacing: 0.2em;
  margin-bottom: 6px;
  transition: color 0.3s;
}
.sport-card:hover .sport-card-num { color: var(--lime); }
.sport-card-name {
  font-size: 22px; font-weight: 700;
  letter-spacing: 0.02em;
  margin-bottom: 12px;
}
.sport-card-desc {
  font-size: 14px; color: var(--dim);
  line-height: 1.5;
  margin-bottom: 20px;
}
.sport-card-arrow {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 13px; color: var(--lime);
  font-weight: 700;
  min-height: 44px; /* touch target */
  transition: gap 0.3s var(--ease);
}
/* Whole-card click: stretch the arrow's hit area over the entire card so the panel
   (not just the link) navigates. .sport-card is position:relative; the arrow keeps its
   visible affordance AND the sport_card_click analytics (a click anywhere on the card
   resolves to this anchor). The carousel already sets pointer-events:none while dragging,
   so a drag never fires the link. */
.sport-card-arrow::after {
  content: ""; position: absolute; inset: 0; z-index: 1;
}
.sport-card:hover .sport-card-arrow { gap: 12px; }

/* Pagination dots (built by home.js) */
.sports-dots {
  display: flex; justify-content: center; gap: 6px;
  margin-top: 8px;
}
.sports-dot {
  width: 24px; height: 24px;
  display: inline-flex; align-items: center; justify-content: center;
  background: none; border: none; padding: 0; cursor: pointer;
}
.sports-dot::before {
  content: ""; width: 8px; height: 8px;
  border-radius: 50%;
  background: var(--dimmer);
  transition: background 0.3s, transform 0.3s var(--ease);
}
.sports-dot[aria-current="true"]::before {
  background: var(--lime);
  transform: scale(1.35);
}

/* ============ MODULE 04 - PILLARS ============ */
.pillars { padding: 120px 0; }
.pillars-intro {
  text-align: center;
  margin-bottom: 80px;
  max-width: 720px;
  margin-left: auto; margin-right: auto;
}
.pillars-intro h2 { margin-bottom: 20px; }
.pillars-intro .mod-sub { margin: 0 auto; }

.pillar {
  padding: 80px 0;
  border-top: 1px solid var(--border);
  position: relative;
}
.pillar:first-of-type { border-top: none; }
.pillar-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: center;
}
.pillar:nth-of-type(even) .pillar-row { direction: rtl; }
.pillar:nth-of-type(even) .pillar-text { direction: ltr; }
.pillar-text .eb { margin-bottom: 20px; }
.pillar-text h3 {
  font-size: clamp(32px, 4vw, 48px);
  line-height: 1.05;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 20px;
}
.pillar-text h3 .dot { color: var(--lime); }
.pillar-text p {
  font-size: 18px; color: var(--dim);
  max-width: 460px;
  line-height: 1.55;
}
.pillar-visual {
  border-radius: 20px;
  padding: 24px;
  min-height: 320px;
  display: flex; align-items: center; justify-content: center;
  position: relative;
  overflow: hidden;
  transition: transform 0.4s var(--ease-out);
}
.pillar-visual:hover { transform: translateY(-6px); }
.pillar-visual::before {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(circle at 50% 50%, var(--lime-soft) 0%, transparent 70%);
  opacity: 0.5;
  pointer-events: none;
  transition: opacity 0.4s;
}
.pillar-visual:hover::before { opacity: 0.9; }
/* Real app card clips, presented directly (no card-in-card wrapper): subtle frame + shadow.
   The clips vary in height; max-width/max-height keep them in a consistent visual envelope. */
.pillar-shot {
  display: block;
  width: 100%; max-width: 340px; max-height: 560px; height: auto;
  border-radius: 16px;
  border: 1px solid var(--border-2);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.45);
  position: relative; z-index: 1;
  transition: transform 0.4s var(--ease-out);
}
.pillar-visual:hover .pillar-shot { transform: translateY(-4px) scale(1.02); }
/* Body-map clip is a tall full figure (390x1088); show it whole, head-to-feet, undistorted. */
.pillar-shot--tall { max-width: 258px; max-height: 760px; }

/* ============ MODULE 05 - ABOUT (editorial lime block) ============ */
.about {
  padding: 140px 0;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.about::before {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(ellipse at center, var(--lime-soft) 0%, transparent 50%);
  pointer-events: none;
  animation: aboutBreathe 6s ease-in-out infinite;
}
@keyframes aboutBreathe {
  0%, 100% { transform: scale(1); opacity: 0.7; }
  50% { transform: scale(1.1); opacity: 1; }
}
.about .c-narrow { position: relative; }
.about h2 { margin-bottom: 40px; }
.about h2 .dot, .about-body .dot, .about-body-2 .dot { color: var(--lime); }
.about-body {
  font-size: 22px; line-height: 1.55;
  color: var(--text);
  margin-bottom: 28px;
}
.about-body-2 {
  font-size: 18px;
  color: var(--dim);
  margin-bottom: 40px;
}
.about-link {
  display: inline-flex; align-items: center; gap: 8px;
  color: var(--lime);
  font-size: 15px; font-weight: 700;
  padding: 12px 20px;
  min-height: 44px; /* touch target */
  border: 1px solid var(--lime-glow);
  border-radius: 100px;
  background: var(--lime-soft);
  transition: all 0.3s var(--ease);
}
.about-link .arrow { transition: transform 0.3s var(--ease-out); }
.about-link:hover {
  background: var(--lime); color: var(--bg);
  box-shadow: 0 8px 24px var(--lime-glow);
  transform: translateY(-2px);
}
.about-link:hover .arrow { transform: translateX(4px); }

/* ============ MODULE 06 - FOUNDER ============ */
.founder { padding: 120px 0; }
.founder-card {
  background: var(--bg-1);
  border: 1px solid var(--border);
  border-radius: 24px;
  padding: 56px;
  display: grid;
  grid-template-columns: 240px 1fr;
  gap: 56px;
  align-items: center;
  position: relative; overflow: hidden;
  transition: border-color 0.3s, box-shadow 0.4s;
}
.founder-card::before {
  content: ""; position: absolute;
  top: 0; left: 0; height: 2px; width: 0;
  background: linear-gradient(90deg, var(--lime), transparent);
  transition: width 0.7s var(--ease-out);
}
.founder-card:hover::before { width: 100%; }
.founder-card:hover {
  border-color: var(--lime-glow);
  box-shadow: 0 30px 80px rgba(0,0,0,0.3), 0 0 60px var(--lime-soft);
}
.founder-photo {
  aspect-ratio: 1;              /* ~square crop, reserves space, CLS 0 */
  background: linear-gradient(135deg, #2a2a2a 0%, #1a1a1a 100%);
  border-radius: 16px;
  border: 1px solid var(--border-2);
  overflow: hidden;
  transition: transform 0.4s var(--ease-out);
}
.founder-photo img {
  width: 100%; height: 100%;
  object-fit: cover;
  display: block;
}
/* Owner can switch to B&W: .founder-photo img { filter: grayscale(1); } */
.founder-card:hover .founder-photo { transform: scale(1.03); }
.founder h3 {
  font-size: clamp(28px, 3.5vw, 40px);
  line-height: 1.1;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 20px;
}
.founder h3 .dot { color: var(--lime); }
.founder p {
  font-size: 17px; color: var(--dim);
  line-height: 1.55; margin-bottom: 14px;
}
.founder p strong { color: var(--lime); font-weight: 700; }
.founder-link {
  display: inline-flex; align-items: center; gap: 6px;
  color: var(--lime); font-size: 14px; font-weight: 700;
  margin-top: 16px;
  min-height: 44px; /* touch target */
  transition: gap 0.3s;
}
.founder-link:hover { gap: 12px; }

/* ============ RESPONSIVE (home modules) ============ */
@media (max-width: 900px) {
  .mod { padding: 80px 0; }
  .hero-grid, .proof-grid, .pillar-row { grid-template-columns: 1fr; gap: 48px; }
  .pillar:nth-of-type(even) .pillar-row { direction: ltr; }
  .sports-header { flex-direction: column; align-items: flex-start; gap: 16px; }
  .sport-card { flex: 0 0 240px; }
  .founder-card { grid-template-columns: 1fr; gap: 32px; padding: 36px; }
  .founder-photo { max-width: 200px; margin: 0 auto; }
  .hero-phone { animation: none; } /* save battery on mobile */
  /* Single-column float field (STEP 3.3, supersedes the 3.1/3.2 banding): the phone stacks
     below the copy, so re-scatter the icons around it as an integrated field (beside, above,
     below, peeking up to ~50% behind its edges) while keeping clear of the eyebrow/text and
     the readable cards. !important beats the per-icon inline style; desktop base is untouched. */
  .hero-float .hf-ico:nth-child(1)  { top: 3%  !important; left: 42% !important; }  /* Gym -> above headline, clear of eyebrow */
  .hero-float .hf-ico:nth-child(2)  { top: 3%  !important; left: 66% !important; }  /* Football -> above the eyebrow */
  .hero-float .hf-ico:nth-child(3)  { top: 46% !important; left: 5%  !important; }  /* Hyrox -> left of phone */
  .hero-float .hf-ico:nth-child(4)  { top: 70% !important; left: 4%  !important; }  /* Padel -> left of phone, lower */
  .hero-float .hf-ico:nth-child(5)  { top: 95% !important; left: 35% !important; }  /* Running -> peek behind phone bottom */
  .hero-float .hf-ico:nth-child(6)  { top: 46% !important; left: 88% !important; }  /* Basketball -> right of phone */
  .hero-float .hf-ico:nth-child(7)  { top: 95% !important; left: 55% !important; }  /* Tennis -> peek behind phone bottom */
  .hero-float .hf-ico:nth-child(8)  { top: 74% !important; left: 90% !important; }  /* Swimming -> right of phone, lower */
  .hero-float .hf-ico:nth-child(9)  { top: 88% !important; left: 14% !important; }  /* Boxing -> left of phone, low */
  .hero-float .hf-ico:nth-child(10) { top: 86% !important; left: 84% !important; }  /* Pilates -> right of phone, low */
  .hero-float .hf-ico:nth-child(11) { top: 60% !important; left: 86% !important; }  /* Netball -> right of phone, mid */
}
