/* AI Apex page styles. Phone first (390), then 700, 1000, 1400.
   Sits on scrollcraft.css (engine, never edited) and tokens.css (brand).
   Rules of the house: no gradients, no glow, no pure black, one accent. */

:root {
  --pad: clamp(3.5rem, 2.4rem + 5.5vw, 8.5rem);          /* fluid section padding */
  --gutter: clamp(1.25rem, 0.6rem + 3.2vw, 4rem);
  --maxw: 65rem;                                          /* 1040px content column */
  --r: 6px;
  --sc-gutter: var(--gutter);
  --sc-maxw: var(--maxw);
  --sc-section: var(--pad);
  --sc-measure: 64ch;
  --sc-leading-body: 1.68;                                /* light-on-dark: a touch more leading */
  --sc-track-normal: 0.003em;                             /* and a touch more tracking */
}

body { font-size: 1.0625rem; }

/* Fine grain over the ground. Same texture as the engine's .sc-grain, set on the
   element itself: the engine's version uses an oversized pseudo-element that
   browsers count as a full-screen layout shift when the page mounts. */
.grain {
  position: fixed; inset: 0; z-index: 3; pointer-events: none; opacity: 0.045; contain: strict;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='140' height='140'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3'/></filter><rect width='140' height='140' filter='url(%23n)'/></svg>");
}
p, h1, h2, h3, ul, ol, figure, blockquote { margin: 0; }
ul, ol { padding: 0; list-style: none; }
strong { font-weight: 600; color: var(--text); }
em { font-style: normal; color: var(--gray-3); }

/* ------------------------------------------------------------- type ---- */
.h1, .h2, .h3 {
  font-family: var(--sc-font-display);
  color: var(--text);
  text-wrap: balance;
}
.h1 {
  font-weight: 650;
  font-size: clamp(2rem, 1.05rem + 3.9vw, 4.5rem);
  line-height: 1.04;
  letter-spacing: clamp(-0.045em, -0.018em - 0.035vw, -0.022em);
}
.h2 {
  font-weight: 620;
  font-size: clamp(1.55rem, 1.05rem + 2.05vw, 2.75rem);
  line-height: 1.1;
  letter-spacing: clamp(-0.036em, -0.014em - 0.03vw, -0.018em);
  max-width: 22ch;
}
.h3 {
  font-weight: 600;
  font-size: clamp(1.2rem, 1.05rem + 0.6vw, 1.5rem);
  line-height: 1.2;
  letter-spacing: -0.015em;
}
.pre {
  font-size: 0.8125rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-soft);
}
.sub {
  font-size: clamp(1.0625rem, 0.98rem + 0.45vw, 1.3125rem);
  line-height: 1.5;
  color: var(--text-soft);
  max-width: 44ch;
  text-wrap: pretty;
}
.body {
  color: var(--text-soft);
  max-width: var(--sc-measure);
  text-wrap: pretty;
}
.body--lead { color: var(--text); font-size: clamp(1.125rem, 1.02rem + 0.5vw, 1.375rem); line-height: 1.5; max-width: 46ch; }
.note { font-size: 0.9375rem; line-height: 1.5; color: var(--text-soft); max-width: 44ch; }

.textlink {
  color: var(--text);
  font-size: 0.875rem;
  text-decoration: underline;
  text-decoration-color: var(--gray-3);
  text-underline-offset: 0.25em;
  padding-block: 0.5rem;                 /* grown tap target */
  transition: text-decoration-color 140ms var(--sc-ease-out);
}
@media (hover: hover) and (pointer: fine) { .textlink:hover { text-decoration-color: var(--text); } }

/* ------------------------------------------------------------ rules ---- */
.rule, .redrule { border: 0; height: 1px; margin: 0; width: 100%; }
.rule { background: var(--gray-1); }
.redrule { background: var(--accent); width: 3rem; height: 2px; }

/* ----------------------------------------------------------- button ---- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 3.25rem;
  padding: 0.875rem 1.75rem;
  border: 1px solid var(--accent);
  border-radius: var(--r);
  background: var(--accent);
  color: var(--accent-ink);
  font-family: var(--sc-font-display);
  font-weight: 600; font-size: 1.0625rem; letter-spacing: -0.005em;
  line-height: 1; white-space: nowrap; text-decoration: none;
  cursor: pointer;
  box-shadow: 0 1px 0 rgb(255 255 255 / 0.14) inset, 0 6px 14px -6px hsl(var(--sc-shadow-color) / 0.7);
  transition: background-color 140ms var(--sc-ease-out), border-color 140ms var(--sc-ease-out), transform 120ms var(--sc-ease-out);
}
.btn:active { transform: translateY(1px); }
.btn:focus-visible { outline: 2px solid var(--text); outline-offset: 3px; }
.btn[disabled] { opacity: 0.6; cursor: default; }
@media (hover: hover) and (pointer: fine) { .btn:hover { background: #B80000; border-color: #B80000; } }

.btn--ghost {
  background: transparent; color: var(--text);
  border-color: var(--gray-2); box-shadow: none;
}
@media (hover: hover) and (pointer: fine) { .btn--ghost:hover { background: var(--raised); border-color: var(--gray-3); } }

/* -------------------------------------------------------------- bar ---- */
.bar {
  position: absolute; inset: 0 0 auto 0; z-index: 30;
  padding: 1rem var(--gutter) 0;
  max-width: calc(var(--maxw) + 2 * var(--gutter)); margin-inline: auto;
}
.bar__mark { width: 3.25rem; height: auto; }
.bar__home { display: block; line-height: 0; border-radius: 4px; }
.bar__home:focus-visible { outline: 2px solid var(--text); outline-offset: 4px; }
@media (min-width: 700px) { .bar { padding-top: 1.5rem; } .bar__mark { width: 3.75rem; } }

/* ------------------------------------------------------------- hero ---- */
.hero { padding-top: 5.25rem; padding-bottom: clamp(2.5rem, 2rem + 3vw, 5rem); }
.hero__head > * + * { margin-top: 0.875rem; }
.hero__head .h1 { margin-top: 0.75rem; max-width: 15ch; }
.hero__media { margin-top: 1.5rem; }
.hero__act { margin-top: 1.25rem; display: grid; gap: 0.75rem; justify-items: start; }
.hero__act .btn { width: 100%; }

.player { position: relative; }
.player__frame { position: relative; aspect-ratio: 16 / 9; background: var(--raised); overflow: clip; }
.player__poster, .player__video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.player__video { opacity: 0; transition: opacity 400ms var(--sc-ease-out); }
.player__video.is-playing { opacity: 1; }
/* The one control on the player: starts the video from the top with sound.
   It is the ghost button on a solid ground so it reads over any frame. */
.player__sound {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%);
  background: rgb(11 11 12 / 0.88); border-color: var(--gray-3);
}
.player__sound:active { transform: translate(-50%, calc(-50% + 1px)); }
.player__sound[hidden] { display: none; }
.player__plate {
  display: grid; gap: 0.125rem;
  padding: 0.75rem var(--gutter) 0;
}
.player__name { font-family: var(--sc-font-display); font-weight: 600; font-size: 0.9375rem; color: var(--text); }
.player__stats { font-size: 0.8125rem; color: var(--text-soft); font-variant-numeric: tabular-nums; }
.player__plate .textlink { justify-self: start; font-size: 0.8125rem; }

/* Proof: four stat cards. The number carries it; the label explains it. */
.proof {
  margin-top: 2rem;
  display: grid; grid-template-columns: 1fr 1fr; gap: 0.625rem;
}
.proof li {
  display: flex; flex-direction: column; gap: 0.25rem;
  padding: 1rem 1rem 1.125rem;
  background: var(--raised);
  border: 1px solid var(--gray-1); border-radius: var(--r);
  box-shadow: var(--sc-edge);
}
.proof__n {
  font-family: var(--sc-font-display); font-weight: 650; color: var(--text);
  font-size: clamp(1.625rem, 1.3rem + 1.5vw, 2.375rem); line-height: 1.05; letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
}
.proof__l { font-size: 0.9375rem; line-height: 1.35; color: var(--text-soft); text-wrap: balance; }

@media (min-width: 700px) {
  .hero { padding-top: 7rem; }
  .hero__media { margin-top: 2.5rem; padding-inline: var(--gutter); max-width: calc(var(--maxw) + 2 * var(--gutter)); margin-inline: auto; }
  .player__frame { border-radius: var(--r); box-shadow: var(--sc-e3); }
  .hero__act { margin-top: 2rem; grid-template-columns: auto 1fr; align-items: center; gap: 1.5rem; }
  .hero__act .btn { width: auto; }
  .proof { margin-top: 2.5rem; gap: 1rem; }
  .proof li { padding: 1.25rem 1.375rem 1.375rem; }
}
@media (min-width: 1000px) {
  .proof { grid-template-columns: repeat(4, 1fr); }
}

/* ------------------------------------------------------------- acts ---- */
.act { padding-block: var(--pad); }
.act--plain { padding-block: calc(var(--pad) * 0.8); }
.frame { position: relative; background: var(--raised); }
.frame img { width: 100%; height: auto; }
.copy { margin-top: 2rem; }
.act--plain .copy, .act--peak > .copy:first-child { margin-top: 0; }
.copy > .body { margin-top: 1.125rem; }
.copy > .body + .body { margin-top: 1rem; }

@media (min-width: 700px) {
  .frame { margin-inline: auto; max-width: var(--maxw); width: calc(100% - 2 * var(--gutter)); border-radius: var(--r); overflow: clip; box-shadow: var(--sc-e2); }
  .copy { margin-top: 3rem; }
}
/* Act 3: the office, full bleed, copy on the dark side */
.frame--bleed { max-width: none; width: 100%; border-radius: 0; box-shadow: none; }
@media (min-width: 1000px) {
  .act--office { position: relative; padding-block: 0; }
  .act--office .frame--bleed { height: min(92svh, 56.25vw); }
  .act--office .frame--bleed img { height: 100%; object-fit: cover; }
  .act--office .copy--plate {
    position: absolute; inset: 0 auto 0 0; margin: 0;
    width: min(34rem, 42vw); max-width: none;
    padding: clamp(2rem, 4vw, 4rem) clamp(2rem, 3.2vw, 3.5rem);
    display: flex; flex-direction: column; justify-content: center;
    background: rgb(11 11 12 / 0.9);
    border-right: 1px solid var(--gray-1);
  }
  .act--office .copy--plate .body { font-size: 1rem; }
}

/* The line alone, then silence before the peak */
/* About half a screen: a breath, not a void. The line is set large and centred
   so it fills the space the way a pull quote does. */
.alone { min-height: 52svh; display: grid; align-items: center; padding-block: clamp(3rem, 2rem + 4vw, 6rem); }
.alone__line {
  font-family: var(--sc-font-display); font-weight: 650; color: var(--text);
  font-size: clamp(2rem, 1.05rem + 4.4vw, 5.25rem); line-height: 1.04;
  letter-spacing: clamp(-0.045em, -0.02em - 0.03vw, -0.025em);
  max-width: 15ch; margin-inline: auto; text-align: center; text-wrap: balance;
}

/* Block 6b */
.redrule--lead { margin-top: 1.25rem; }
.redrule--lead + .body { margin-top: 1.5rem; }

/* Block 8: proof */
.quotes { margin-top: 2.5rem; display: grid; }
.quote { border-top: 1px solid var(--gray-1); padding-block: 1.5rem; }
.quote:last-child { border-bottom: 1px solid var(--gray-1); }
.quote blockquote { color: var(--text-soft); font-size: 1rem; line-height: 1.6; max-width: 64ch; text-wrap: pretty; }
.quote figcaption { margin-top: 0.75rem; font-size: 0.875rem; font-weight: 500; color: var(--text); }

/* Block 9: for you / not for you */
.fit { display: grid; gap: 3rem; }
.fit .redrule, .fit .rule { margin-top: 1rem; }
.fit .rule { width: 3rem; height: 2px; background: var(--gray-2); }
.list { margin-top: 1.25rem; display: grid; gap: 0.75rem; }
.list li { color: var(--text-soft); max-width: 40ch; text-wrap: pretty; }
.fit__col--yes .list li { color: var(--text); }
@media (min-width: 700px) { .fit { grid-template-columns: 1fr 1fr; gap: 4rem; } }

/* Block 11: the form. Nothing else on screen. */
.talk { min-height: 100svh; display: grid; align-items: center; padding-block: var(--pad); background: var(--ground); border-top: 1px solid var(--gray-1); }
.talk__wrap { max-width: calc(40rem + 2 * var(--gutter)); }
.form { margin-top: 2rem; display: grid; gap: 1rem; }
.form__row { display: grid; gap: 1rem; }
@media (min-width: 560px) { .form__row { grid-template-columns: 1fr 1fr; } }
.field { display: grid; gap: 0.375rem; }
.field > span { font-size: 0.8125rem; color: var(--text-soft); }
.field input, .field select, .field textarea {
  width: 100%; min-height: 3rem;
  padding: 0.75rem 0.875rem;
  background: var(--raised); color: var(--text);
  border: 1px solid var(--gray-2); border-radius: var(--r);
  font-size: 1rem; line-height: 1.4;               /* 16px: no iOS zoom on focus */
  transition: border-color 140ms var(--sc-ease-out), background-color 140ms var(--sc-ease-out);
}
.field textarea { resize: vertical; min-height: 5.5rem; }
.field select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5 6 6.5l5-5' fill='none' stroke='%23A8A8AD' stroke-width='1.5'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 0.875rem center; padding-right: 2.5rem; }
.field select option { background: var(--raised); color: var(--text); }
.field input:focus-visible, .field select:focus-visible, .field textarea:focus-visible { outline: 2px solid var(--text); outline-offset: 1px; border-color: var(--gray-3); background: var(--card); }
@media (hover: hover) and (pointer: fine) { .field input:hover, .field select:hover, .field textarea:hover { border-color: var(--gray-3); } }
.check { display: flex; align-items: center; gap: 0.75rem; min-height: 2.75rem; color: var(--text); cursor: pointer; }
.check input { width: 1.25rem; height: 1.25rem; margin: 0; accent-color: var(--text); }
.hp { position: absolute; left: -200vw; width: 1px; height: 1px; overflow: hidden; }
.form .btn { margin-top: 0.5rem; width: 100%; }
.form__error { color: var(--text); font-size: 0.9375rem; padding: 0.75rem 0.875rem; border: 1px solid var(--gray-3); border-radius: var(--r); background: var(--raised); }
@media (min-width: 560px) { .form .btn { width: auto; justify-self: start; } }
.thanks { margin-top: 2rem; display: grid; gap: 1.25rem; justify-items: start; }
.thanks:focus { outline: none; }
.thanks__line { font-family: var(--sc-font-display); font-weight: 600; font-size: clamp(1.25rem, 1.1rem + 0.7vw, 1.625rem); line-height: 1.25; letter-spacing: -0.015em; max-width: 24ch; text-wrap: balance; }
[hidden] { display: none !important; }

/* ----------------------------------------------------------- footer ---- */
.foot { border-top: 1px solid var(--gray-1); padding-block: 2rem 2.5rem; }
.foot__wrap { display: grid; gap: 1.25rem; }
.foot__line { font-size: 0.8125rem; line-height: 1.6; color: var(--gray-3); max-width: 70ch; }
.foot__mark { width: 6rem; height: auto; }
@media (min-width: 1000px) { .foot__wrap { grid-template-columns: 1fr auto; align-items: center; } }

/* -------------------------------------------------- /invitation page ---- */
.inv { padding-top: 6rem; padding-bottom: var(--pad); }
.inv__head > * + * { margin-top: 1rem; }
.inv .h1 { max-width: 16ch; }
.inv .sub { max-width: 52ch; }
.inv__blocks { margin-top: 3rem; display: grid; gap: 2rem; }
.inv__blocks .body { padding-top: 2rem; border-top: 1px solid var(--gray-1); }
.inv__act { margin-top: 3rem; display: grid; gap: 0.75rem; justify-items: start; }
.inv__book { margin-top: 3rem; min-height: 4rem; }
.inv__book .calendly-inline-widget { min-width: 280px; height: 760px; border-radius: var(--r); overflow: clip; border: 1px solid var(--gray-1); }
@media (max-width: 559px) { .inv__act .btn { width: 100%; white-space: normal; line-height: 1.2; } }

/* --------------------------------------------------- reduced motion ---- */
@media (prefers-reduced-motion: reduce) {
  .player__video:not(.is-on) { display: none; }
  .player__video { transition: none; }
  .btn, .textlink, .field input, .field select, .field textarea { transition: none; }
}
