/* FalaPro landing site. Tokens first (light, then dark by system preference; no toggle), then base styles.
   --fp-brand and --fp-accent are non-text colors: never use them for color or background. */
:root {
  --fp-canvas: #F8FAFC;
  --fp-surface: #FFFFFF;
  --fp-border: #E2E8F0;
  --fp-text: #1E293B;
  --fp-text-muted: #475569;
  --fp-link: #0369A1;
  --fp-brand: #0284C7;
  --fp-accent: #FB923C;
  --fp-fill: #0284C7;
  --fp-fill-hover: #0369A1;
  --fp-on-fill: #FFFFFF;
  --fp-ai-bubble: #E0F2FE;
  --fp-on-ai-bubble: #1E293B;
  --fp-highlight: #FED7AA;
  --fp-on-highlight: #1E293B;
  --fp-band: #1E293B;
  --fp-on-band: #FFFFFF;
  --fp-on-band-muted: #CBD5E1;
  --fp-on-band-error: #FCA5A5;
  --fp-on-band-success: #86EFAC;
  --fp-chip-tint: #E0F2FE;
  --fp-on-chip-tint: #0369A1;
  --fp-chip-warm: #FFF7ED;
  --fp-on-chip-warm: #C2410C;
  --fp-chip-green: #ECFDF5;
  --fp-on-chip-green: #047857;
  --fp-chip-neutral: #F1F5F9;
  --fp-on-chip-neutral: #475569;
  --fp-input-bg: #FFFFFF;
  --fp-input-text: #1E293B;
  --fp-placeholder: #64748B;
  --fp-control-height: 48px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --fp-canvas: #0F172A;
    --fp-surface: #1E293B;
    --fp-border: #334155;
    --fp-text: #F8FAFC;
    --fp-text-muted: #94A3B8;
    --fp-link: #38BDF8;
    --fp-brand: #0284C7;
    --fp-accent: #FB923C;
    --fp-fill: #0284C7;
    --fp-fill-hover: #0369A1;
    --fp-on-fill: #FFFFFF;
    --fp-ai-bubble: #0C4A6E;
    --fp-on-ai-bubble: #E0F2FE;
    --fp-highlight: #FED7AA;
    --fp-on-highlight: #1E293B;
    --fp-band: #0C4A6E;
    --fp-on-band: #F8FAFC;
    --fp-on-band-muted: #CBD5E1;
    --fp-on-band-error: #FEE2E2;
    --fp-on-band-success: #86EFAC;
    --fp-chip-tint: #0C4A6E;
    --fp-on-chip-tint: #E0F2FE;
    --fp-chip-warm: #431407;
    --fp-on-chip-warm: #FED7AA;
    --fp-chip-green: #064E3B;
    --fp-on-chip-green: #A7F3D0;
    --fp-chip-neutral: #334155;
    --fp-on-chip-neutral: #CBD5E1;
    --fp-input-bg: #0F172A;
    --fp-input-text: #F8FAFC;
    --fp-placeholder: #94A3B8;
    --fp-control-height: 48px;
  }
}

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

html {
  color-scheme: light dark;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--fp-canvas);
  color: var(--fp-text);
  font-family: Inter, system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 1rem;
  line-height: 1.6;
}

h1,
h2,
h3 {
  font-family: "Plus Jakarta Sans", Inter, system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.2;
  margin: 0 0 0.5em;
}

p {
  margin: 0 0 1em;
}

a {
  color: var(--fp-link);
  text-underline-offset: 0.15em;
}

a:hover {
  text-decoration-thickness: 2px;
}

img,
svg {
  max-width: 100%;
  height: auto;
}

:focus-visible {
  outline: 3px solid var(--fp-brand);
  outline-offset: 2px;
}

input,
select,
button {
  font: inherit;
  min-height: var(--fp-control-height);
}

input,
select {
  background: var(--fp-input-bg);
  color: var(--fp-input-text);
  border: 1px solid var(--fp-border);
  border-radius: 8px;
  padding: 0 0.75rem;
}

input::placeholder {
  color: var(--fp-placeholder);
}

/* ---------- Layout ---------- */
.container {
  max-width: 1120px;
  margin: 0 auto;
  padding-inline: 24px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  left: 16px;
  top: -80px;
  z-index: 100;
  padding: 10px 16px;
  border-radius: 8px;
  background: var(--fp-fill);
  color: var(--fp-on-fill);
  font-weight: 700;
  font-size: 19px;
  line-height: 1.2;
  text-decoration: none;
}

.skip-link:focus {
  top: 12px;
}

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--fp-canvas) 92%, transparent);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--fp-border);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  height: 72px;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--fp-text);
  text-decoration: none;
}

.logo img {
  display: block;
  width: 34px;
  height: 34px;
  flex: none;
  border-radius: 9px;
}

.wordmark {
  font-family: "Plus Jakarta Sans", Inter, system-ui, sans-serif;
  font-weight: 800;
  font-size: 1.4rem;
  line-height: 1;
  letter-spacing: -0.02em;
}

.nav-links {
  display: flex;
  gap: 28px;
  font-size: 0.95rem;
  font-weight: 500;
}

.nav-links a {
  color: var(--fp-text-muted);
  text-decoration: none;
}

.nav-links a:hover {
  color: var(--fp-link);
  text-decoration: underline;
  text-decoration-color: var(--fp-brand);
  text-decoration-thickness: 2px;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: var(--fp-control-height);
  padding: 0 22px;
  border: 1px solid transparent;
  border-radius: 10px;
  font-weight: 700;
  font-size: 19px;
  line-height: 1.2;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color 0.15s ease, border-color 0.15s ease, transform 0.15s ease;
}

.btn-primary {
  background: var(--fp-fill);
  color: var(--fp-on-fill);
}

.btn-primary:hover {
  background: var(--fp-fill-hover);
  text-decoration: none;
}

.btn-outline {
  background: var(--fp-surface);
  color: var(--fp-text);
  border-color: var(--fp-border);
}

.btn-outline:hover {
  border-color: var(--fp-brand);
  text-decoration: none;
}

/* ---------- Hero ---------- */
.hero-wrap {
  border-bottom: 1px solid var(--fp-border);
}

.hero {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 48px;
  align-items: center;
  padding-top: 72px;
  padding-bottom: 80px;
}

.hero-copy,
.phone-card {
  min-width: 0;
}

.eyebrow {
  display: inline-block;
  margin-bottom: 20px;
  padding: 6px 14px;
  border: 1px solid var(--fp-brand);
  border-radius: 999px;
  background: var(--fp-chip-tint);
  color: var(--fp-on-chip-tint);
  font-weight: 700;
  font-size: 0.78rem;
  line-height: 1.4;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.hero h1 {
  margin-bottom: 20px;
  font-size: 3.4rem;
  font-weight: 800;
  line-height: 1.08;
  letter-spacing: -0.03em;
  text-wrap: balance;
}

.h1-accent {
  color: var(--fp-link);
  text-decoration: underline;
  text-decoration-color: var(--fp-accent);
  text-decoration-thickness: 0.09em;
  text-underline-offset: 0.12em;
}

.hero-copy > p {
  max-width: 540px;
  margin-bottom: 32px;
  color: var(--fp-text-muted);
  font-size: 1.15rem;
}

.hero-ctas {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

/* ---------- Phone card ---------- */
.phone-card {
  padding: 24px;
  border: 1px solid var(--fp-border);
  border-top: 4px solid var(--fp-brand);
  border-radius: 24px;
  background: var(--fp-surface);
  box-shadow: 0 20px 40px -15px color-mix(in srgb, var(--fp-text) 18%, transparent);
}

.phone-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 18px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--fp-border);
}

.streak-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex: none;
  padding: 4px 10px;
  border: 1px solid var(--fp-accent);
  border-radius: 999px;
  background: var(--fp-chip-warm);
  color: var(--fp-on-chip-warm);
  font-weight: 700;
  font-size: 0.8rem;
  line-height: 1.4;
}

.flame {
  display: block;
  flex: none;
  fill: var(--fp-accent);
}

.chat-stack {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.bubble {
  max-width: 88%;
  padding: 12px 16px;
  border-radius: 16px;
  font-size: 0.92rem;
}

.bubble-ai {
  align-self: flex-start;
  border-bottom-left-radius: 4px;
  background: var(--fp-ai-bubble);
  color: var(--fp-on-ai-bubble);
}

.bubble-user {
  align-self: flex-end;
  border-bottom-right-radius: 4px;
  background: var(--fp-fill);
  color: var(--fp-on-fill);
}

.highlight-word {
  padding: 1px 6px;
  border-radius: 5px;
  background-color: var(--fp-highlight);
  color: var(--fp-on-highlight);
  font-weight: 600;
}

.coach-note {
  margin-top: 18px;
  padding: 12px 14px;
  border-left: 3px solid var(--fp-accent);
  border-radius: 0 8px 8px 0;
  background: var(--fp-canvas);
  color: var(--fp-text-muted);
  font-size: 0.85rem;
}

.coach-note strong {
  color: var(--fp-text);
}

/* ---------- Motion ---------- */
@keyframes bubble-in {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes highlight-reveal {
  from {
    background-color: transparent;
    color: var(--fp-on-fill);
  }
  to {
    background-color: var(--fp-highlight);
    color: var(--fp-on-highlight);
  }
}

.bubble {
  animation: bubble-in 240ms ease-out both;
  animation-delay: calc(var(--i, 0) * 120ms);
}

.highlight-word {
  animation: highlight-reveal 400ms ease-out both;
  animation-delay: 360ms;
}

/* ---------- Sections ---------- */
.section {
  padding: 80px 0;
  scroll-margin-top: 72px;
}

.section-surface {
  background: var(--fp-surface);
  border-top: 1px solid var(--fp-border);
  border-bottom: 1px solid var(--fp-border);
}

.section-head {
  max-width: 680px;
  margin: 0 auto 48px;
  text-align: center;
}

.section-head h2,
.section-head p {
  text-wrap: balance;
}

.section-head h2 {
  margin-bottom: 14px;
  font-size: 2.2rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.section-head p {
  margin: 0;
  color: var(--fp-text-muted);
  font-size: 1.05rem;
}

.grid {
  display: grid;
  gap: 24px;
}

.grid-3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.grid-4 {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.card {
  min-width: 0;
  padding: 28px;
  border: 1px solid var(--fp-border);
  border-radius: 18px;
  background: var(--fp-surface);
  overflow-wrap: break-word;
}

.section-surface .card {
  background: var(--fp-canvas);
}

.card-band {
  border-top: 4px solid var(--fp-brand);
}

.card-band-accent {
  border-top: 4px solid var(--fp-accent);
}

.card h3 {
  margin-bottom: 10px;
  font-size: 1.2rem;
  font-weight: 800;
}

.card p {
  margin: 0;
  color: var(--fp-text-muted);
  font-size: 0.95rem;
}

.card-top {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 16px;
}

.chip {
  display: inline-block;
  padding: 4px 10px;
  border: 1px solid transparent;
  border-radius: 6px;
  font-size: 0.78rem;
  font-weight: 700;
  line-height: 1.4;
}

.chip-tint {
  background: var(--fp-chip-tint);
  color: var(--fp-on-chip-tint);
}

.chip-warm {
  background: var(--fp-chip-warm);
  color: var(--fp-on-chip-warm);
}

.chip-green {
  background: var(--fp-chip-green);
  color: var(--fp-on-chip-green);
}

.chip-neutral {
  background: var(--fp-chip-neutral);
  color: var(--fp-on-chip-neutral);
}

.chip-status {
  border-radius: 999px;
}

.chip-status.chip-tint {
  border-color: var(--fp-brand);
}

.chip-status.chip-neutral {
  border-color: var(--fp-border);
}

.sample-phrase {
  margin-top: 18px;
  padding: 12px 14px;
  border: 1px solid var(--fp-border);
  border-radius: 8px;
  background: var(--fp-canvas);
  color: var(--fp-text);
  font-size: 0.85rem;
}

/* ---------- Waitlist band ---------- */
#early-access {
  padding-top: 0;
}

.cta-box {
  padding: 56px 40px;
  border-top: 4px solid var(--fp-brand);
  border-radius: 24px;
  background: var(--fp-band);
  color: var(--fp-on-band);
  text-align: center;
}

.cta-box h2 {
  margin-bottom: 14px;
  font-size: 2.2rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.cta-box > p {
  max-width: 560px;
  margin: 0 auto 32px;
  color: var(--fp-on-band-muted);
}

.waitlist-form {
  display: flex;
  align-items: stretch;
  gap: 12px;
  max-width: 760px;
  margin: 0 auto;
  text-align: left;
}

.waitlist-form[hidden] {
  display: none;
}

.waitlist-form input,
.waitlist-form select {
  min-width: 0;
  height: var(--fp-control-height);
}

#wl-email {
  flex: 1.4 1 0;
}

#wl-interest {
  flex: 1 1 0;
}

.waitlist-form .btn {
  flex: none;
  height: var(--fp-control-height);
  background: var(--fp-on-band);
  color: var(--fp-band);
}

.waitlist-form .btn:hover {
  background: var(--fp-on-band-muted);
}

.waitlist-form :focus-visible,
.cta-box :focus-visible {
  outline-color: var(--fp-on-band);
}

.hp-field {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

.wl-status {
  min-height: 1.6em;
  margin: 18px 0 0;
  color: var(--fp-on-band-muted);
  font-size: 0.95rem;
}

.wl-status:empty {
  min-height: 0;
  margin: 0;
}

.wl-status.is-error {
  color: var(--fp-on-band-error);
}

.wl-status.is-success {
  color: var(--fp-on-band-success);
}

/* ---------- Legal pages ---------- */
.legal {
  max-width: 760px;
}

.legal h1 {
  margin-bottom: 8px;
  font-size: 2.4rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.legal h2 {
  margin: 32px 0 10px;
  font-size: 1.3rem;
  font-weight: 800;
}

.legal-updated {
  color: var(--fp-text-muted);
  font-size: 0.95rem;
}

.legal ul {
  margin: 0 0 1em;
  padding-left: 1.25em;
}

.legal li {
  margin-bottom: 0.4em;
}

/* ---------- Footer ---------- */
.site-footer {
  padding: 40px 0 48px;
  border-top: 1px solid var(--fp-border);
  color: var(--fp-text-muted);
  font-size: 0.9rem;
  text-align: center;
}

.site-footer p {
  margin: 0;
}

.footer-line {
  color: var(--fp-text);
  font-weight: 600;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 8px 24px;
  margin: 12px 0 16px;
}

.footer-links a {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
}

/* ---------- Responsive ---------- */
@media (max-width: 860px) {
  .hero {
    grid-template-columns: 1fr;
    gap: 40px;
    padding-top: 48px;
    padding-bottom: 56px;
  }

  .hero h1 {
    font-size: 2.6rem;
  }

  .grid-3,
  .grid-4 {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .nav-links {
    display: none;
  }

  .section {
    padding: 64px 0;
  }
}

/* The three-control row needs about 700px of form width to show the placeholder and select prompt untruncated. */
@media (max-width: 800px) {
  .waitlist-form {
    flex-direction: column;
  }

  .waitlist-form input,
  .waitlist-form select,
  .waitlist-form .btn {
    flex: none;
    width: 100%;
  }
}

@media (max-width: 560px) {
  .hero-ctas .btn {
    width: 100%;
  }
}

@media (max-width: 479px) {
  .container {
    padding-inline: 16px;
  }

  .hero h1 {
    font-size: 2.25rem;
  }

  .section {
    padding: 48px 0;
  }

  .section-head {
    margin-bottom: 32px;
  }

  .section-head h2,
  .cta-box h2 {
    font-size: 1.75rem;
  }

  .card {
    padding: 22px;
  }

  .phone-card {
    padding: 18px;
  }

  .cta-box {
    padding: 40px 20px;
  }

  .wordmark {
    font-size: 1.25rem;
  }

  .nav .btn {
    padding: 0 16px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }

  .bubble,
  .highlight-word {
    animation: none;
  }
}
