/* Self-hosted fonts (CSP: font-src 'self'). Latin subsets, variable. */
@font-face {
  font-family: 'Source Serif 4';
  font-style: normal;
  font-weight: 200 900;
  font-display: swap;
  src: url('/marketing/assets/fonts/source-serif-4-latin.woff2') format('woff2');
}
@font-face {
  font-family: 'Source Serif 4';
  font-style: italic;
  font-weight: 200 900;
  font-display: swap;
  src: url('/marketing/assets/fonts/source-serif-4-italic-latin.woff2') format('woff2');
}
@font-face {
  font-family: 'Figtree';
  font-style: normal;
  font-weight: 300 900;
  font-display: swap;
  src: url('/marketing/assets/fonts/figtree-latin.woff2') format('woff2');
}

/* ================================
         Direction A = "Calm clinic"
         Function-Health-led mechanics on a white, cool canvas:
         serif-light display + quiet humanist body, pill CTAs,
         one Committed teal moment (final band). Teal/mint stays.
         ================================ */
:root {
  --ink: #10201e;
  --ink-body: #334945;
  --ink-soft: #4d625d;
  --sea: #0f6c73;
  --sea-deep: #0b4a51;
  --sea-ink: #072e33;
  --mint: #43d39f;
  --mint-wash: #e5f8f0;
  --paper: #ffffff;
  --tint: #f3f8f7;
  --line: #dbe6e4;
  --radius-pill: 999px;
  --radius-card: 14px;
  --shadow-frame: 0 30px 80px rgba(11, 74, 81, 0.16), 0 4px 18px rgba(11, 74, 81, 0.08);
  --shadow-soft: 0 10px 30px rgba(11, 74, 81, 0.08);
  --container: 1160px;
  --gutter: clamp(20px, 5vw, 56px);
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Figtree', system-ui, sans-serif;
  font-size: 17px;
  line-height: 1.65;
  color: var(--ink-body);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

.container {
  width: min(100% - calc(var(--gutter) * 2), var(--container));
  margin-inline: auto;
}

h1,
h2,
h3 {
  font-family: 'Source Serif 4', Georgia, serif;
  font-weight: 340;
  color: var(--ink);
  letter-spacing: -0.01em;
  text-wrap: balance;
}

p {
  text-wrap: pretty;
}

a {
  color: var(--sea);
  text-decoration: none;
}
a:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

::selection {
  background: var(--mint-wash);
  color: var(--sea-ink);
}

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

.skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 100;
  padding: 10px 14px;
  border-radius: 8px;
  background: var(--sea-deep);
  color: #fff;
  font-weight: 700;
  transform: translateY(-180%);
}
.skip-link:focus {
  color: #fff;
  text-decoration: none;
  transform: none;
}

/* === Buttons === */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: 'Figtree', system-ui, sans-serif;
  font-size: 16px;
  font-weight: 600;
  line-height: 1;
  padding: 17px 30px;
  border-radius: var(--radius-pill);
  border: 1px solid transparent;
  cursor: pointer;
  transition:
    transform 220ms var(--ease-out),
    box-shadow 220ms var(--ease-out),
    background-color 220ms var(--ease-out);
}
.btn-primary {
  background: var(--sea);
  color: #fff;
}
.btn-primary:hover {
  background: var(--sea-deep);
  transform: translateY(-2px);
  box-shadow: 0 12px 28px rgba(11, 74, 81, 0.24);
  text-decoration: none;
}
.btn-quiet {
  background: transparent;
  color: var(--sea-ink);
  border-color: var(--line);
}
.btn-quiet:hover {
  border-color: var(--sea);
  text-decoration: none;
  transform: translateY(-2px);
}

/* === Nav === */
.nav {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 50;
  transition:
    background-color 300ms var(--ease-out),
    box-shadow 300ms var(--ease-out);
}
.nav.is-scrolled {
  background: rgba(255, 255, 255, 0.86);
  -webkit-backdrop-filter: blur(14px);
  backdrop-filter: blur(14px);
  box-shadow: 0 1px 0 var(--line);
}
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 0;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 19px;
  color: var(--ink);
}
.brand img {
  width: 30px;
  height: 30px;
}
.brand:hover {
  text-decoration: none;
}
.nav-links {
  display: flex;
  align-items: center;
  gap: 30px;
  font-size: 15.5px;
  font-weight: 500;
}
.nav-links a {
  color: var(--ink-body);
}
.nav-links a:hover {
  color: var(--sea-ink);
  text-decoration: none;
}
.nav-cta {
  font-size: 15px;
  padding: 12px 22px;
  flex: 0 0 auto;
}

/* === Hero === */
.hero {
  padding: clamp(130px, 18vh, 190px) 0 0;
  text-align: center;
}
.hero h1 {
  font-size: clamp(2.5rem, 5.6vw, 4.4rem);
  line-height: 1.08;
  max-width: 21ch;
  margin-inline: auto;
}
.hero h1 em {
  font-style: italic;
  color: var(--sea);
}
.hero-lede {
  max-width: 56ch;
  margin: 26px auto 0;
  font-size: clamp(17px, 1.5vw, 19px);
  color: var(--ink-body);
}
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 14px;
  margin-top: 38px;
}
.hero-note {
  margin-top: 18px;
  font-size: 14.5px;
  color: var(--ink-soft);
}
.hero-frame {
  margin: clamp(48px, 7vw, 84px) auto 0;
  width: min(100% - calc(var(--gutter) * 2), 1080px);
  border-radius: var(--radius-card);
  overflow: hidden;
  border: 1px solid var(--line);
  box-shadow: var(--shadow-frame);
  background: #fff;
}
.hero-frame img {
  display: block;
  width: 100%;
  height: auto;
}

/* === Channels band === */
.channels {
  padding: clamp(72px, 10vw, 120px) 0 clamp(60px, 8vw, 96px);
}
.channels-head {
  max-width: 46ch;
  margin: 0 auto 44px;
  text-align: center;
}
.channels-head h2 {
  font-size: clamp(1.7rem, 3vw, 2.4rem);
  line-height: 1.2;
}
.channels-head p {
  margin-top: 14px;
  color: var(--ink-soft);
  font-size: 16.5px;
}
.channel-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: clamp(14px, 2.4vw, 26px);
}
.channel {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 13px 22px;
  border: 1px solid var(--line);
  border-radius: var(--radius-pill);
  font-weight: 600;
  font-size: 15.5px;
  color: var(--ink);
  background: #fff;
  transition:
    transform 220ms var(--ease-out),
    box-shadow 220ms var(--ease-out),
    border-color 220ms var(--ease-out);
}
.channel:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-soft);
  border-color: var(--mint);
}
.channel img {
  width: 19px;
  height: 19px;
}
.channel small {
  font-weight: 500;
  color: var(--ink-soft);
}

/* === Workflow rows === */
.workflow {
  background: var(--tint);
  padding: clamp(76px, 10vw, 128px) 0;
}
.workflow-head {
  max-width: 52ch;
  margin-bottom: clamp(52px, 7vw, 84px);
}
.workflow-head h2 {
  font-size: clamp(1.9rem, 3.4vw, 2.7rem);
  line-height: 1.16;
}
.workflow-head p {
  margin-top: 16px;
  font-size: 17px;
  color: var(--ink-soft);
  max-width: 52ch;
}
.moment {
  display: grid;
  grid-template-columns: minmax(280px, 5fr) minmax(320px, 7fr);
  gap: clamp(30px, 5vw, 70px);
  align-items: center;
}
.moment + .moment {
  margin-top: clamp(64px, 9vw, 110px);
}
.moment:nth-child(odd) .moment-copy {
  order: 2;
}
.moment:nth-child(odd) .moment-media {
  order: 1;
}
.moment-kicker {
  font-size: 14px;
  font-weight: 700;
  color: var(--sea);
  margin-bottom: 12px;
}
.moment h3 {
  font-size: clamp(1.45rem, 2.4vw, 1.9rem);
  line-height: 1.22;
}
.moment p {
  margin-top: 14px;
  font-size: 16.5px;
}
.moment-media {
  border-radius: var(--radius-card);
  overflow: hidden;
  border: 1px solid var(--line);
  box-shadow: var(--shadow-soft);
  background: #fff;
}
.moment-media img {
  display: block;
  width: 100%;
  height: auto;
}

/* === Week one === */
.weekone {
  padding: clamp(76px, 10vw, 128px) 0;
}
.weekone h2 {
  font-size: clamp(1.9rem, 3.4vw, 2.7rem);
  max-width: 24ch;
  line-height: 1.16;
}
.weekone-grid {
  margin-top: clamp(40px, 5vw, 60px);
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: clamp(28px, 4vw, 56px);
}
.weekone-item {
  border-top: 1px solid var(--line);
  padding-top: 22px;
}
.weekone-item strong {
  display: block;
  font-family: 'Source Serif 4', Georgia, serif;
  font-weight: 420;
  font-size: 22px;
  color: var(--ink);
  line-height: 1.3;
}
.weekone-item p {
  margin-top: 10px;
  font-size: 15.5px;
  color: var(--ink-soft);
}

/* === Pricing === */
.plans {
  background: var(--tint);
  padding: clamp(76px, 10vw, 128px) 0;
}
.plans-head {
  text-align: center;
  max-width: 50ch;
  margin: 0 auto clamp(44px, 6vw, 64px);
}
.plans-head h2 {
  font-size: clamp(1.9rem, 3.4vw, 2.7rem);
  line-height: 1.16;
}
.plans-head p {
  margin-top: 14px;
  color: var(--ink-soft);
}
.plan-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 22px;
  align-items: stretch;
}
.plan {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius-card);
  padding: 34px 30px;
  display: flex;
  flex-direction: column;
  transition:
    transform 240ms var(--ease-out),
    box-shadow 240ms var(--ease-out);
}
.plan:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-soft);
}
.plan.is-featured {
  border-color: var(--sea);
  box-shadow: 0 18px 48px rgba(11, 74, 81, 0.14);
  position: relative;
}
.plan-flag {
  position: absolute;
  top: -13px;
  left: 30px;
  background: var(--sea);
  color: #fff;
  font-size: 12.5px;
  font-weight: 700;
  padding: 5px 14px;
  border-radius: var(--radius-pill);
}
.plan h3 {
  font-family: 'Figtree', system-ui, sans-serif;
  font-weight: 700;
  font-size: 17px;
  color: var(--ink);
}
.plan-price {
  margin-top: 14px;
  font-family: 'Source Serif 4', Georgia, serif;
  font-weight: 300;
  font-size: 44px;
  color: var(--ink);
  line-height: 1;
}
.plan-price small {
  font-family: 'Figtree', system-ui, sans-serif;
  font-size: 15px;
  color: var(--ink-soft);
  font-weight: 500;
}
.plan-annual {
  margin-top: 6px;
  font-size: 13.5px;
  color: var(--ink-soft);
}
.plan ul {
  list-style: none;
  margin: 24px 0 28px;
  display: grid;
  gap: 11px;
  font-size: 15.5px;
}
.plan li {
  display: flex;
  gap: 10px;
  align-items: baseline;
}
.plan li::before {
  content: '';
  flex: none;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--mint);
  transform: translateY(-2px);
}
.plan .btn {
  margin-top: auto;
  justify-content: center;
}

/* === FAQ === */
.faq {
  padding: clamp(76px, 10vw, 120px) 0;
}
.faq-grid {
  display: grid;
  grid-template-columns: minmax(260px, 4fr) minmax(320px, 7fr);
  gap: clamp(32px, 5vw, 72px);
  align-items: start;
}
.faq h2 {
  font-size: clamp(1.9rem, 3.4vw, 2.6rem);
  line-height: 1.16;
  max-width: 14ch;
}
.faq-side p {
  margin-top: 16px;
  color: var(--ink-soft);
  font-size: 16px;
  max-width: 36ch;
}
.faq-side a {
  color: var(--sea-deep);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.faq details {
  border-bottom: 1px solid var(--line);
  padding: 20px 0;
}
.faq details:first-child {
  border-top: 1px solid var(--line);
}
.faq summary {
  cursor: pointer;
  font-weight: 600;
  font-size: 17px;
  color: var(--ink);
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}
.faq summary::-webkit-details-marker {
  display: none;
}
.faq summary::after {
  content: '+';
  font-family: 'Source Serif 4', Georgia, serif;
  font-size: 24px;
  font-weight: 300;
  color: var(--sea);
  transition: transform 240ms var(--ease-out);
}
.faq details[open] summary::after {
  transform: rotate(45deg);
}
.faq details p {
  margin-top: 12px;
  font-size: 15.5px;
  max-width: 62ch;
}

/* === Final CTA (the Committed teal moment) === */
.cta {
  background: var(--sea-deep);
  color: #d9efe9;
  padding: clamp(84px, 12vw, 150px) 0;
  text-align: center;
}
.cta h2 {
  color: #fff;
  font-size: clamp(2.1rem, 4.4vw, 3.4rem);
  line-height: 1.12;
  max-width: 22ch;
  margin-inline: auto;
}
.cta h2 em {
  font-style: italic;
  color: var(--mint);
}
.cta p {
  margin: 20px auto 0;
  max-width: 52ch;
  color: #b8dcd4;
  font-size: 17px;
}
.cta .btn-primary {
  margin-top: 38px;
  background: #fff;
  color: var(--sea-ink);
}
.cta .btn-primary:hover {
  background: var(--mint-wash);
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.28);
}
.cta-note {
  margin-top: 16px;
  font-size: 14px;
  color: #9ccfc4;
}

/* === Footer === */
.footer {
  padding: 44px 0 54px;
  font-size: 14.5px;
  color: var(--ink-soft);
}
.footer-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  align-items: center;
  justify-content: space-between;
}
.footer a {
  color: var(--ink-soft);
}
.footer a:hover {
  color: var(--sea-ink);
}
.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 22px;
}

/* === Motion: pure CSS, never gates content on JS.
         Hero plays a timed entrance on load; everything below the fold is
         scroll-driven via animation-timeline: view(), so headless renders,
         hidden tabs, and no-JS all settle fully visible. === */
@media (prefers-reduced-motion: no-preference) {
  @keyframes rise-in {
    from {
      transform: translateY(26px);
    }
    to {
      transform: none;
    }
  }
  @keyframes frame-in {
    from {
      transform: translateY(34px) scale(0.985);
    }
    to {
      transform: none;
    }
  }
  .hero .reveal {
    animation: rise-in 680ms var(--ease-out) both;
    animation-delay: var(--d, 0ms);
  }
  .hero .reveal-frame {
    animation: frame-in 860ms var(--ease-out) both;
    animation-delay: var(--d, 0ms);
  }
  @keyframes glide-in {
    from {
      transform: translateY(28px);
    }
    to {
      transform: none;
    }
  }
  @keyframes glide-settle {
    from {
      transform: translateY(30px) scale(0.99);
    }
    to {
      transform: none;
    }
  }
  /* Below the fold: transform-only glides (opacity never animates on
           scroll, so any renderer that skips timelines still shows content). */
  @supports (animation-timeline: view()) {
    main section .reveal {
      animation: glide-in linear both;
      animation-delay: 0s;
      animation-timeline: view();
      animation-range: entry 5% entry 45%;
    }
    main section .reveal-frame {
      animation: glide-settle linear both;
      animation-delay: 0s;
      animation-timeline: view();
      animation-range: entry 5% entry 50%;
    }
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  .btn,
  .channel,
  .plan {
    transition: none;
  }
}

/* === Responsive === */
@media (max-width: 860px) {
  .nav-inner {
    flex-wrap: wrap;
    gap: 12px 16px;
  }
  .nav-links {
    order: 3;
    flex: 1 0 100%;
    min-width: 0;
    overflow-x: auto;
    overscroll-behavior-inline: contain;
    scrollbar-width: none;
    scroll-snap-type: inline proximity;
  }
  .nav-links::-webkit-scrollbar {
    display: none;
  }
  .nav-links a {
    flex: 0 0 auto;
    scroll-snap-align: start;
  }
  .moment {
    grid-template-columns: 1fr;
  }
  .moment:nth-child(odd) .moment-copy {
    order: 1;
  }
  .moment:nth-child(odd) .moment-media {
    order: 2;
  }
  .faq-grid {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 480px) {
  body {
    font-size: 16px;
  }
  .nav-cta {
    font-size: 14px;
    padding: 10px 14px;
  }
  .hero {
    padding-top: 132px;
  }
  .hero-actions .btn {
    width: 100%;
    justify-content: center;
  }
}

/* Reveal stagger delays (no inline styles per discovery contract) */
.d0 {
  --d: 0ms;
}
.d70 {
  --d: 70ms;
}
.d90 {
  --d: 90ms;
}
.d140 {
  --d: 140ms;
}
.d170 {
  --d: 170ms;
}
.d180 {
  --d: 180ms;
}
.d210 {
  --d: 210ms;
}
.d230 {
  --d: 230ms;
}
.d260 {
  --d: 260ms;
}
.d280 {
  --d: 280ms;
}
.d300 {
  --d: 300ms;
}
