/* =============================================================
   ACCENT COACHING — LANDING PAGE STYLES
   Dark, typography-led, mobile-first. No images, no frameworks.
   ============================================================= */

/* ---------- Design tokens ---------- */
:root {
  /* Colour palette — warm near-black with an off-white text for a premium feel */
  --bg:            #0a0b0f;   /* page background (slight blue-black) */
  --bg-elevated:   #14161c;   /* cards / raised surfaces     */
  --text:          #f4f1ea;   /* primary warm white          */
  --text-soft:     #d7d4cb;   /* higher-contrast body over glow */
  --text-muted:    #9a988f;   /* secondary / muted copy      */
  --text-dim:      #6c6a64;   /* eyebrows, footnotes         */
  --hairline:      rgba(244, 241, 234, 0.10); /* subtle borders */

  /* Brand accent BLUE (buttons, numbers, kickers, glow) — blue converts well */
  --accent:        #3b82f6;   /* primary blue                */
  --accent-lite:   #8ec5ff;   /* lighter blue for gradients   */
  --accent-dark:   #2563eb;   /* pressed / hover state       */
  --accent-rgb:    59, 130, 246;   /* for rgba() glows        */

  /* Type families */
  --font-serif: "Fraunces", Georgia, "Times New Roman", serif;
  --font-sans:  "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;

  /* Fluid spacing — scales smoothly between mobile and desktop */
  --section-pad: clamp(4.5rem, 12vw, 9rem);
  --container:   680px;
}

/* ---------- Reset / base ---------- */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  overflow-x: hidden;   /* belt-and-suspenders against the fixed orb */
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 1.0625rem;          /* 17px base for comfortable mobile reading */
  line-height: 1.65;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  /* Room at the bottom so the sticky mobile button never covers content */
  padding-bottom: env(safe-area-inset-bottom);
  overflow-x: hidden;
}

/* =============================================================
   LIVELY 3D "VOICE ORB" BACKGROUND
   Fixed behind all content. Outer element = scroll-driven drift + grow
   (via --sp, the page scroll progress 0→1). Inner element = slow spin +
   breathe. Splitting them avoids fighting over the transform property.
   ============================================================= */
.orb {
  position: fixed;
  inset: 0;
  margin: auto;                 /* centres the fixed box in the viewport */
  width: min(80vmin, 620px);
  height: min(80vmin, 620px);
  z-index: 0;
  pointer-events: none;
  /* Drift from upper area (hero) to centred-low (final CTA), growing as it goes */
  transform:
    translate(
      calc(10vw * (1 - var(--sp, 0))),
      calc(-20vh * (1 - var(--sp, 0)) + 5vh * var(--sp, 0))
    )
    scale(calc(0.8 + 0.45 * var(--sp, 0)));
  opacity: calc(0.38 + 0.4 * var(--sp, 0));
  transition: transform 0.2s linear, opacity 0.3s linear;
  will-change: transform, opacity;
}

.orb__inner {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  /* Off-centre highlight fakes a lit 3D sphere; blur turns it into a glow */
  background: radial-gradient(
    circle at 35% 32%,
    rgba(160, 200, 255, 0.9) 0%,
    rgba(70, 130, 250, 0.55) 38%,
    rgba(30, 70, 180, 0.28) 62%,
    rgba(10, 30, 90, 0) 74%
  );
  filter: blur(18px);
  animation: orb-spin 30s linear infinite, orb-breathe 9s ease-in-out infinite;
}

@keyframes orb-spin {
  to { transform: rotate(360deg); }
}
@keyframes orb-breathe {
  0%, 100% { opacity: 0.85; }
  50%      { opacity: 1; }
}

/* ---------- Layout helpers ---------- */
.section {
  position: relative;
  z-index: 1;                   /* sit above the orb */
  padding-top: var(--section-pad);
  padding-bottom: var(--section-pad);
}

.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: clamp(1.4rem, 6vw, 2.5rem);
}

.container--narrow {
  max-width: 620px;
}

/* Hairline separators between major sections */
.section + .section {
  border-top: 1px solid var(--hairline);
}

/* Small blue kicker label used above several sections */
.kicker {
  font-family: var(--font-sans);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 1.25rem;
}

/* Gradient-accent inline text (e.g. "2–3x") */
.hl {
  background: linear-gradient(120deg, var(--accent), var(--accent-lite));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* =============================================================
   HERO
   ============================================================= */
.hero {
  /* A touch more breathing room up top for the first impression */
  padding-top: clamp(5rem, 16vw, 10rem);
  text-align: center;
}

/* Eyebrow is a pill badge with a pulsing "live" dot */
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-sans);
  font-size: clamp(0.62rem, 2.7vw, 0.72rem);
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
  background: rgba(244, 241, 234, 0.04);
  border: 1px solid var(--hairline);
  padding: 0.5rem 0.95rem;
  border-radius: 999px;
  margin-bottom: 1.9rem;
  white-space: nowrap;   /* keep the pill on a single tidy line */
}

.eyebrow__dot {
  flex-shrink: 0;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 0 rgba(var(--accent-rgb), 0.6);
  animation: pulse-dot 2s ease-out infinite;
}

@keyframes pulse-dot {
  0%   { box-shadow: 0 0 0 0 rgba(var(--accent-rgb), 0.55); }
  70%  { box-shadow: 0 0 0 8px rgba(var(--accent-rgb), 0); }
  100% { box-shadow: 0 0 0 0 rgba(var(--accent-rgb), 0); }
}

/* Rotating market word inside the eyebrow */
.rotator {
  display: inline-block;
  color: var(--accent);
}
.rotator__word {
  display: inline-block;
  transition: opacity 0.3s ease, transform 0.3s ease;
}
.rotator__word.is-swapping {
  opacity: 0;
  transform: translateY(-4px);
}

.hero__headline {
  font-family: var(--font-serif);
  font-weight: 700;
  /* Huge and fluid — the single loudest element on the page */
  font-size: clamp(3rem, 12vw, 5.25rem);
  line-height: 1.0;
  letter-spacing: -0.025em;
  margin-bottom: 1.75rem;
  text-wrap: balance;   /* keeps line breaks tidy on supporting browsers */
}

/* Thick accent underline for the key promise word(s) in headlines */
.uline {
  text-decoration: underline;
  text-decoration-color: var(--accent);
  text-decoration-thickness: 0.09em;
  text-underline-offset: 0.09em;
}

.hero__subhead {
  font-size: clamp(1.05rem, 3.6vw, 1.3rem);
  line-height: 1.6;
  color: var(--text-muted);
  max-width: 34ch;
  margin: 0 auto 2.75rem;
}

/* Bold emphasis inside muted copy pops back to full-contrast white */
.hero__subhead strong,
.cost__text strong,
.about__bio strong,
.why__line strong,
.stakes__text strong {
  color: var(--text);
}
.why__line strong,
.statement strong {
  font-weight: 600;   /* serif bold sits at 600 to stay elegant */
}

/* The "sorry, could you repeat that?" quote gets a subtle emphasis */
.quote {
  color: var(--text);
  font-style: italic;
}

/* =============================================================
   3D "ON THE CALL" SCROLL SCENE
   ============================================================= */
.scene-section {
  text-align: center;
}

.scene3d {
  /* The perspective that makes child transforms read as real 3D depth */
  perspective: 1200px;
  perspective-origin: 50% 35%;
  margin-top: 1.5rem;
}

.scene3d__stack {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  max-width: 460px;
  margin-inline: auto;
  transform-style: preserve-3d;
  /* --p (0→1) is set by JS as you scroll; the stack tilts, then straightens */
  transform:
    rotateX(calc((1 - var(--p, 1)) * 24deg))
    rotateY(calc((1 - var(--p, 1)) * -9deg))
    translateZ(calc((1 - var(--p, 1)) * -90px));
  transition: transform 0.12s linear;
  will-change: transform;
}

.bubble {
  position: relative;
  max-width: 80%;
  padding: 0.85rem 1.15rem;
  border-radius: 18px;
  font-family: var(--font-sans);
  font-size: 1.02rem;
  line-height: 1.4;
  text-align: left;
  /* Each bubble sits at its own depth (--i) so the tilt separates them */
  transform: translateZ(calc(var(--i, 0) * 16px));
  box-shadow: 0 22px 45px -22px rgba(0, 0, 0, 0.8);

  /* Entrance: start blurred + invisible, then fade + sharpen in, staggered.
     Only opacity + filter animate here, so the translateZ depth is untouched. */
  opacity: 0;
  filter: blur(14px);
  transition: opacity 0.6s ease, filter 0.6s ease;
  transition-delay: calc(var(--i, 0) * 0.12s);
}

.bubble.is-in {
  opacity: 1;
  filter: blur(0);
}

.bubble--them {
  align-self: flex-start;
  background: var(--bg-elevated);
  border: 1px solid var(--hairline);
  color: var(--text);
  border-bottom-left-radius: 5px;
}

.bubble--you {
  align-self: flex-end;
  background: linear-gradient(135deg, var(--accent-dark), var(--accent));
  color: #ffffff;
  font-weight: 500;
  border-bottom-right-radius: 5px;
}

.bubble--close {
  font-weight: 700;
}

/* =============================================================
   THE REFRAME — one big centered statement
   ============================================================= */
.reframe {
  text-align: center;
}

.statement {
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: clamp(1.5rem, 5.5vw, 2.4rem);
  line-height: 1.3;
  letter-spacing: -0.01em;
  text-wrap: balance;
}

/* =============================================================
   THE FORMULA
   ============================================================= */
.section__heading {
  font-family: var(--font-serif);
  font-weight: 700;
  font-size: clamp(1.75rem, 6.5vw, 2.6rem);
  line-height: 1.12;
  letter-spacing: -0.015em;
  margin-bottom: 2.75rem;
  text-align: center;          /* centered framing reads more direct-response */
  text-wrap: balance;
}

.formula__list {
  list-style: none;
  display: grid;
  gap: 1.25rem;
}

.formula__item {
  display: flex;
  gap: 1.25rem;
  align-items: flex-start;
  background: var(--bg-elevated);
  border: 1px solid var(--hairline);
  border-radius: 16px;
  padding: clamp(1.5rem, 5vw, 2rem);
}

.formula__num {
  font-family: var(--font-serif);
  font-size: 1.6rem;
  font-weight: 600;
  color: var(--accent);
  line-height: 1;
  flex-shrink: 0;
}

.formula__title {
  font-family: var(--font-serif);
  font-size: 1.35rem;
  font-weight: 600;
  line-height: 1.2;
  margin-bottom: 0.5rem;
}

.formula__text {
  color: var(--text-muted);
  font-size: 1rem;
}

.formula__closing {
  font-family: var(--font-serif);
  font-weight: 600;
  font-size: clamp(1.25rem, 4.5vw, 1.6rem);
  line-height: 1.35;
  margin-top: 2.5rem;
  text-align: center;
  text-wrap: balance;
}

/* =============================================================
   THE REAL COST — stereotype + money upside
   ============================================================= */
.cost {
  text-align: center;          /* centered framing reads more direct-response */
}

.cost__beat + .cost__beat {
  margin-top: clamp(2.5rem, 8vw, 4rem);
  padding-top: clamp(2.5rem, 8vw, 4rem);
  border-top: 1px solid var(--hairline);
}

.cost__heading {
  font-family: var(--font-serif);
  font-weight: 700;
  font-size: clamp(1.75rem, 6.5vw, 2.5rem);
  line-height: 1.12;
  letter-spacing: -0.015em;
  margin-bottom: 1.25rem;
  text-wrap: balance;
}

.cost__text {
  font-size: clamp(1.05rem, 3.6vw, 1.2rem);
  line-height: 1.65;
  color: var(--text-muted);
}

.cost__text em {
  color: var(--text);
  font-style: italic;
}

/* =============================================================
   WHY ME
   ============================================================= */
.why__line {
  font-family: var(--font-serif);
  font-weight: 400;
  font-size: clamp(1.25rem, 4.5vw, 1.7rem);
  line-height: 1.4;
  letter-spacing: -0.01em;
}

.why__line + .why__line {
  margin-top: 1.75rem;
  padding-top: 1.75rem;
  border-top: 1px solid var(--hairline);
}

/* =============================================================
   ABOUT MEET — authority + animated stats
   ============================================================= */
.about {
  text-align: center;
}

.about__name {
  font-family: var(--font-serif);
  font-weight: 600;
  font-size: clamp(2rem, 7vw, 3rem);
  line-height: 1.05;
  letter-spacing: -0.02em;
  margin-bottom: 2.5rem;
}

.stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1px;                       /* the gap shows the hairline behind = grid lines */
  background: var(--hairline);
  border: 1px solid var(--hairline);
  border-radius: 16px;
  overflow: hidden;
  margin-bottom: 2.5rem;
  /* A hair of elevation so the stats read clearly over the orb glow */
  backdrop-filter: blur(2px);
}

.stat {
  background: var(--bg-elevated);
  padding: clamp(1.4rem, 5vw, 2rem) 1rem;
}

.stat__num {
  display: block;
  font-family: var(--font-serif);
  font-weight: 600;
  font-size: clamp(1.9rem, 8vw, 2.9rem);
  line-height: 1;
  letter-spacing: -0.02em;
  /* Gradient-blue numbers to sell the authority */
  background: linear-gradient(120deg, var(--accent), var(--accent-lite));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.stat__label {
  display: block;
  margin-top: 0.65rem;
  font-size: 0.85rem;
  line-height: 1.35;
  color: var(--text-muted);
}

.about__bio {
  font-size: clamp(1.05rem, 3.6vw, 1.2rem);
  line-height: 1.65;
  font-weight: 500;
  color: var(--text-soft);
  max-width: 40ch;
  margin-inline: auto;
  text-wrap: pretty;
}

/* Video sales letter container (for when a video is dropped in later) */
.vsl {
  position: relative;
  aspect-ratio: 16 / 9;
  margin-top: 2.5rem;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid var(--hairline);
  background: var(--bg-elevated);
}
.vsl iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

/* =============================================================
   THE STAKES
   ============================================================= */
.stakes {
  text-align: center;
}

.stakes__text {
  font-size: clamp(1.15rem, 4vw, 1.5rem);
  line-height: 1.55;
  font-weight: 500;
  color: var(--text-soft);
  text-wrap: pretty;
}

.stakes__text strong {
  display: block;
  margin-top: 1.25rem;
  color: var(--text);
  font-family: var(--font-serif);
  font-weight: 600;
  font-size: 1.15em;
}

/* =============================================================
   FINAL CTA — where the orb blooms behind the button
   ============================================================= */
.final-cta {
  text-align: center;
}

.final-cta__headline {
  font-family: var(--font-serif);
  font-weight: 700;
  font-size: clamp(2.25rem, 9vw, 3.75rem);
  line-height: 1.05;
  letter-spacing: -0.02em;
  margin-bottom: 1.25rem;
  text-wrap: balance;
}

.final-cta__subline {
  font-size: clamp(1.05rem, 3.6vw, 1.25rem);
  font-weight: 500;
  color: var(--text);           /* full white — it sits on the bright orb bloom */
  margin-bottom: 2.75rem;
}

/* =============================================================
   PRIMARY CTA BUTTONS
   ============================================================= */
.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;               /* clip the shine sweep to the pill shape */
  font-family: var(--font-sans);
  font-size: 1.1rem;
  font-weight: 700;
  line-height: 1;
  text-decoration: none;
  padding: 1.2rem 2.1rem;
  border-radius: 999px;
  cursor: pointer;
  transition: transform 0.15s ease, background-color 0.15s ease,
    box-shadow 0.15s ease;
}

.btn--primary {
  background: var(--accent);
  color: #ffffff;   /* white on blue = high contrast */
  box-shadow: 0 10px 30px -8px rgba(var(--accent-rgb), 0.55);
}

.btn--primary:hover,
.btn--primary:focus-visible {
  background: var(--accent-dark);
  transform: translateY(-2px);
  box-shadow: 0 14px 36px -8px rgba(var(--accent-rgb), 0.7);
  outline: none;
}

.btn--primary:active {
  transform: translateY(0);
}

.btn--large {
  font-size: 1.15rem;
  padding: 1.25rem 1.9rem;
}

@media (min-width: 400px) {
  /* A little more presence for the large CTA once there's room */
  .btn--large {
    font-size: 1.25rem;
    padding: 1.35rem 2.6rem;
  }
}

/* Keep the label above the animated shine sweep */
.btn__label {
  position: relative;
  z-index: 1;
}

/* Friction-reducer microcopy directly under a CTA button */
.cta-note {
  margin-top: 0.9rem;
  font-size: 0.85rem;
  color: var(--text-dim);
}

/* The final CTA sits on the bright orb bloom, so its note needs more contrast */
.final-cta .cta-note {
  color: rgba(244, 241, 234, 0.85);
}

/* Mid-page CTA in the About section needs breathing room above */
.about__cta {
  margin-top: 2.25rem;
}

/* A slow light sweep across the CTA to draw the eye (mostly idle, quick pass) */
.btn--primary::after,
.sticky-cta::after {
  content: "";
  position: absolute;
  top: 0;
  left: -75%;
  width: 55%;
  height: 100%;
  z-index: 0;
  background: linear-gradient(
    100deg,
    transparent,
    rgba(255, 255, 255, 0.35),
    transparent
  );
  transform: skewX(-18deg);
  animation: shine 5s ease-in-out infinite;
}

@keyframes shine {
  0%, 65% { left: -75%; }
  100%    { left: 135%; }
}

/* =============================================================
   STICKY MOBILE CTA BUTTON
   Fixed to the bottom, full width, mobile only.
   ============================================================= */
.sticky-cta {
  position: fixed;
  left: 1rem;
  right: 1rem;
  /* Sits above the iOS home-bar safe area */
  bottom: calc(1rem + env(safe-area-inset-bottom));
  z-index: 50;

  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;

  background: var(--accent);
  color: #ffffff;
  font-family: var(--font-sans);
  font-size: 1.05rem;
  font-weight: 600;
  text-decoration: none;
  padding: 1rem 1.25rem;
  border-radius: 999px;
  box-shadow: 0 12px 30px -6px rgba(0, 0, 0, 0.6),
    0 0 0 1px rgba(var(--accent-rgb), 0.35);

  /* Small entrance animation */
  animation: sticky-in 0.4s ease 0.6s both;
}

.sticky-cta:active {
  background: var(--accent-dark);
}

@keyframes sticky-in {
  from { transform: translateY(120%); opacity: 0; }
  to   { transform: translateY(0);    opacity: 1; }
}

/* Hide the sticky button on larger screens — the inline CTAs are enough there */
@media (min-width: 768px) {
  .sticky-cta {
    display: none;
  }

  /* Show all four authority stats in a single row on desktop */
  .stats {
    grid-template-columns: repeat(4, 1fr);
  }

  /* Smaller numbers + tighter padding so four fit cleanly without clipping */
  .stat {
    padding-inline: 0.75rem;
  }
  .stat__num {
    font-size: clamp(1.6rem, 3.2vw, 2.1rem);
  }
}

/* =============================================================
   FOOTER
   ============================================================= */
.footer {
  position: relative;
  z-index: 1;
  border-top: 1px solid var(--hairline);
  padding: 3rem 0 4rem;
  text-align: center;
  /* Extra clearance on mobile so the sticky button doesn't overlap it */
  padding-bottom: calc(6rem + env(safe-area-inset-bottom));
}

.footer__note {
  font-family: var(--font-serif);
  font-size: 0.95rem;
  color: var(--text-dim);
  letter-spacing: 0.02em;
}

@media (min-width: 768px) {
  /* No sticky button on desktop, so the footer needs no extra clearance */
  .footer {
    padding-bottom: 4rem;
  }
}

/* =============================================================
   SCROLL-REVEAL ANIMATION
   Elements start slightly down, blurred + transparent, then settle.
   The .is-visible class is toggled by script.js via IntersectionObserver.
   ============================================================= */
.reveal {
  opacity: 0;
  transform: translateY(26px);
  filter: blur(8px);
  transition: opacity 0.75s ease, transform 0.75s cubic-bezier(0.2, 0.6, 0.2, 1),
    filter 0.75s ease;
  /* will-change hints the browser to promote these to their own layer */
  will-change: opacity, transform, filter;
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
  filter: blur(0);
}

/* Stagger stacked reveals inside a section for a gentle cascade */
.reveal:nth-child(2) { transition-delay: 0.08s; }
.reveal:nth-child(3) { transition-delay: 0.16s; }
.reveal:nth-child(4) { transition-delay: 0.24s; }

/* =============================================================
   ACCESSIBILITY — respect users who prefer reduced motion
   ============================================================= */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }

  /* Show everything immediately, no movement or blur */
  .reveal,
  .bubble {
    opacity: 1;
    transform: none;
    filter: none;
    transition: none;
  }

  /* Freeze the orb in place (no drift, spin or breathe) */
  .orb {
    transform: none;
    transition: none;
  }
  .orb__inner,
  .sticky-cta,
  .eyebrow__dot { animation: none; }

  /* Turn off the CTA shine sweep */
  .btn--primary::after,
  .sticky-cta::after { display: none; }

  /* Flatten the 3D scene so it reads as a plain chat */
  .scene3d__stack { transform: none; }
  .bubble { transform: none; }

  .btn { transition: none; }

  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
}
