/* ── Sales Whisperer ─────────────────────────────────────────────────────────
   Cool paper, ink transcript, coaching set as quiet marginalia.
   Two accents, one job each: --live is the recording dot and nothing else,
   --coach is the coaching voice and nothing else.
   ────────────────────────────────────────────────────────────────────────── */

:root {
  --paper:  #F3F5F8;
  --card:   #FFFFFF;
  --ink:    #121821;
  --slate:  #626E80;
  --rule:   #DDE2E9;
  --live:   #D2483F;
  --coach:  #1F6F6B;

  --display: 'Bricolage Grotesque', system-ui, sans-serif;
  --body:    'Instrument Sans', system-ui, sans-serif;
  --mono:    'IBM Plex Mono', ui-monospace, monospace;

  --measure: 62rem;
  --pad: clamp(1.25rem, 5vw, 3rem);
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--body);
  font-size: clamp(1rem, 0.96rem + 0.2vw, 1.0625rem);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

.sr, .skip:not(:focus) {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.skip:focus {
  position: fixed; top: 0.75rem; left: 0.75rem; z-index: 50;
  background: var(--ink); color: var(--paper);
  padding: 0.6rem 1rem; border-radius: 6px;
  font-family: var(--body); font-size: 0.9rem;
}

:focus-visible {
  outline: 2px solid var(--coach);
  outline-offset: 3px;
  border-radius: 3px;
}

/* ── top bar ─────────────────────────────────────────────────────────────── */

.bar {
  max-width: var(--measure);
  margin: 0 auto;
  padding: 1.75rem var(--pad) 0;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
}

.wordmark {
  font-family: var(--display);
  font-weight: 600;
  font-size: 1.0625rem;
  letter-spacing: -0.01em;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.wordmark .dot {
  width: 8px; height: 8px; border-radius: 50%;
  background: var(--live);
  flex: none;
}

.bar-note {
  font-family: var(--mono);
  font-size: 0.75rem;
  color: var(--slate);
  letter-spacing: 0.02em;
}

/* ── hero ────────────────────────────────────────────────────────────────── */

main { max-width: var(--measure); margin: 0 auto; padding: 0 var(--pad); }

.hero { padding: clamp(3.5rem, 9vw, 6.5rem) 0 clamp(2.5rem, 5vw, 3.5rem); }

h1 {
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(2.6rem, 1.4rem + 5.4vw, 5.25rem);
  line-height: 0.98;
  letter-spacing: -0.035em;
  margin: 0 0 1.5rem;
  text-wrap: balance;
}

.lede {
  max-width: 44ch;
  margin: 0;
  font-size: clamp(1.05rem, 1rem + 0.35vw, 1.25rem);
  line-height: 1.55;
  color: var(--slate);
}

/* ── the demo: transcript + marginalia ───────────────────────────────────── */

.demo {
  background: var(--card);
  border: 1px solid var(--rule);
  border-radius: 14px;
  padding: clamp(1.25rem, 3.5vw, 2rem);
  box-shadow: 0 1px 2px rgb(18 24 33 / 0.04), 0 12px 32px -18px rgb(18 24 33 / 0.28);
}

.demo-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-bottom: 1.125rem;
  border-bottom: 1px solid var(--rule);
  font-family: var(--mono);
  font-size: 0.75rem;
  letter-spacing: 0.02em;
}

.live { display: inline-flex; align-items: center; gap: 0.5rem; color: var(--live); }

.live-dot {
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--live); flex: none;
  animation: pulse 2.4s ease-in-out infinite;
}

@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.28; } }

.demo-meta { color: var(--slate); }

.transcript { list-style: none; margin: 0; padding: 0; }

.turn {
  display: grid;
  grid-template-columns: 4.5rem 1fr 15rem;
  gap: 0 1.5rem;
  padding: 1.375rem 0;
  border-bottom: 1px solid var(--rule);
}

.turn:last-child { border-bottom: 0; padding-bottom: 0.25rem; }

.t {
  font-family: var(--mono);
  font-size: 0.75rem;
  color: var(--slate);
  padding-top: 0.3rem;
}

.who {
  grid-column: 2;
  font-family: var(--mono);
  font-size: 0.6875rem;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  color: var(--slate);
}

/* the loud thing */
.said {
  grid-column: 2;
  margin: 0.2rem 0 0;
  font-family: var(--mono);
  font-size: clamp(0.95rem, 0.9rem + 0.2vw, 1.0625rem);
  line-height: 1.5;
  color: var(--ink);
}

/* the quiet thing — coaching as a note in the margin */
.cue {
  grid-column: 3;
  grid-row: 1 / span 2;
  align-self: start;
  padding-left: 1.125rem;
  border-left: 2px solid var(--coach);
  font-size: 0.875rem;
  line-height: 1.45;
  color: var(--coach);
  text-wrap: pretty;
}

.cue-good { font-style: italic; }

.demo-foot {
  margin: 1.5rem 0 0;
  padding-top: 1.125rem;
  border-top: 1px solid var(--rule);
  font-family: var(--mono);
  font-size: 0.75rem;
  color: var(--slate);
}

/* ── what changed ────────────────────────────────────────────────────────── */

.change { padding: clamp(4rem, 9vw, 6.5rem) 0 0; }

.change-title {
  font-family: var(--mono);
  font-size: 0.75rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--slate);
  margin: 0 0 2rem;
  padding-bottom: 0.875rem;
  border-bottom: 1px solid var(--rule);
}

.change-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
  gap: clamp(1.75rem, 4vw, 3rem);
}

.change-item h3 {
  font-family: var(--display);
  font-weight: 600;
  font-size: 1.1875rem;
  letter-spacing: -0.015em;
  line-height: 1.25;
  margin: 0 0 0.5rem;
}

.change-item p { margin: 0; color: var(--slate); font-size: 0.9375rem; line-height: 1.55; }

/* ── signup ──────────────────────────────────────────────────────────────── */

.signup { padding: clamp(4rem, 9vw, 6.5rem) 0 clamp(3rem, 6vw, 4rem); }

.signup h2 {
  font-family: var(--display);
  font-weight: 800;
  font-size: clamp(1.75rem, 1.2rem + 2.2vw, 2.75rem);
  letter-spacing: -0.03em;
  line-height: 1.05;
  margin: 0 0 0.625rem;
}

.signup-note { margin: 0 0 1.75rem; color: var(--slate); max-width: 42ch; }

#notify-form {
  display: flex;
  flex-wrap: wrap;
  gap: 0.625rem;
  max-width: 34rem;
}

#email {
  flex: 1 1 15rem;
  min-width: 0;
  font: inherit;
  font-size: 1rem;
  padding: 0.8125rem 1rem;
  color: var(--ink);
  background: var(--card);
  border: 1px solid var(--rule);
  border-radius: 9px;
}

#email::placeholder { color: #9AA5B4; }
#email:focus-visible { border-color: var(--coach); outline-offset: 1px; }

#notify-btn {
  font: inherit;
  font-weight: 600;
  font-size: 0.9375rem;
  padding: 0.8125rem 1.375rem;
  color: var(--paper);
  background: var(--ink);
  border: 1px solid var(--ink);
  border-radius: 9px;
  cursor: pointer;
  transition: background 140ms ease, transform 140ms ease;
}

#notify-btn:hover:not(:disabled) { background: #232C39; }
#notify-btn:active:not(:disabled) { transform: translateY(1px); }
#notify-btn:disabled { opacity: 0.55; cursor: default; }

.form-msg {
  margin: 0.875rem 0 0;
  min-height: 1.4rem;
  font-size: 0.9rem;
  color: var(--coach);
}

.form-msg[data-state="error"] { color: var(--live); }

/* ── footer ──────────────────────────────────────────────────────────────── */

footer {
  max-width: var(--measure);
  margin: 0 auto;
  padding: 1.75rem var(--pad) 3rem;
  border-top: 1px solid var(--rule);
  display: flex;
  gap: 0.625rem;
  font-family: var(--mono);
  font-size: 0.75rem;
  color: var(--slate);
}

/* ── motion: the transcript arrives, coaching follows a beat later ───────── */

/* Content is visible by default. Only once JS confirms it's running does it
   hide anything — so a failed script leaves a readable page, not an empty box. */
.js-anim .turn {
  opacity: 0;
  transform: translateY(6px);
  transition: opacity 520ms ease, transform 520ms ease;
}

.js-anim .cue {
  opacity: 0;
  transform: translateX(-5px);
  transition: opacity 520ms ease, transform 520ms ease;
}

.js-anim .turn.in, .js-anim .cue.in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  .js-anim .turn, .js-anim .cue {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
  .live-dot { animation: none; }
  #notify-btn { transition: none; }
}

/* ── narrow screens: marginalia moves under the line it belongs to ───────── */

@media (max-width: 46rem) {
  .turn {
    grid-template-columns: 4rem 1fr;
    gap: 0 1rem;
  }
  .cue {
    grid-column: 2;
    grid-row: auto;
    margin-top: 0.75rem;
  }
  .demo-head { font-size: 0.6875rem; }
}
