/* =============================================================
   1. Tokens
   ============================================================= */
:root {
  --bg:            #f8f9fb;
  --bg-cream:      #f4efe6;
  --surface:       #ffffff;
  --ink:           #191c1e;
  --ink-soft:      #3f484b;
  --ink-mute:      #70797c;

  --primary:       #0d5d6e;
  --primary-dark:  #004452;
  --primary-tint:  #e5f1f3;

  --walk:          #3f9142;
  --sleep:         #5b68b5;
  --play:          #c98a10;
  --train:         #e07a1e;

  --border-light:  #e5e7eb;
  --shadow-soft:   0 4px 20px rgba(13, 93, 110, 0.08);
  --shadow-lift:   0 20px 50px rgba(13, 93, 110, 0.16);

  --radius-sm:     0.5rem;
  --radius-md:     1rem;
  --radius-lg:     1.5rem;
  --radius-full:   9999px;

  --ease-out:      cubic-bezier(0.16, 1, 0.3, 1);
  --ease-bounce:   cubic-bezier(0.34, 1.56, 0.64, 1);

  --sans: "Quicksand", "Trebuchet MS", sans-serif;
}

/* =============================================================
   2. Reset & base
   ============================================================= */
*, *::before, *::after { box-sizing: border-box; margin: 0; }
html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  overflow-x: clip;
}
body {
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  color: var(--ink-soft);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: clip;
  overscroll-behavior-y: none;
}
img, svg, video { display: block; max-width: 100%; }
img { height: auto; }
button { font: inherit; color: inherit; cursor: pointer; border: 0; background: none; }
a { color: inherit; text-decoration: none; }
p { text-wrap: pretty; }
h1, h2, h3, h4 {
  font-family: var(--sans);
  font-weight: 700;
  color: var(--ink);
  text-wrap: balance;
  line-height: 1.08;
  letter-spacing: -0.01em;
}
input { font: inherit; }
::selection { background: var(--primary); color: #fff; }

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

/* =============================================================
   3. Utilities
   ============================================================= */
.container {
  width: 100%;
  max-width: 1200px;
  margin-inline: auto;
  padding-inline: 1.25rem;
}
.sr-only {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}
.skip-link {
  position: fixed; top: -100px; left: 1rem;
  padding: .6rem 1rem; background: var(--ink); color: #fff;
  z-index: 9999; border-radius: var(--radius-sm); font-weight: 600;
}
.skip-link:focus { top: 1rem; }

/* =============================================================
   4. Typography
   ============================================================= */
.eyebrow {
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--primary);
  margin-bottom: 0.6rem;
}
.section-title {
  font-size: clamp(1.7rem, 3.6vw, 2.6rem);
  max-width: 22ch;
}
.section-sub {
  margin-top: 0.75rem;
  font-size: 1.05rem;
  color: var(--ink-mute);
  max-width: 52ch;
}

/* =============================================================
   5. Components
   ============================================================= */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.9rem 1.6rem;
  border-radius: var(--radius-full);
  font-weight: 700;
  font-size: 1rem;
  white-space: nowrap;
  transition: transform 0.35s var(--ease-out), box-shadow 0.35s var(--ease-out), background 0.25s var(--ease-out);
}
.btn-primary {
  background: var(--primary);
  color: #fff;
  box-shadow: 0 10px 30px rgba(13, 93, 110, 0.28);
}
.btn-primary:hover {
  background: var(--primary-dark);
  transform: translateY(-2px);
  box-shadow: 0 16px 36px rgba(13, 93, 110, 0.34);
}
.btn-sm { padding: 0.6rem 1.2rem; font-size: 0.9rem; }

.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.45rem 0.9rem;
  border-radius: var(--radius-full);
  background: var(--primary-tint);
  color: var(--primary-dark);
  font-weight: 700;
  font-size: 0.85rem;
  margin-bottom: 1.4rem;
}

.waitlist-form {
  display: flex;
  gap: 0.6rem;
  max-width: 460px;
  margin-top: 1.8rem;
}
.waitlist-form input {
  flex: 1;
  min-width: 0;
  padding: 0.9rem 1.2rem;
  border-radius: var(--radius-full);
  border: 1.5px solid var(--border-light);
  background: var(--surface);
  color: var(--ink);
  font-weight: 500;
  transition: border-color 0.25s var(--ease-out);
}
.waitlist-form input:focus { border-color: var(--primary); outline: none; }
.waitlist-form input::placeholder { color: var(--ink-mute); }
.waitlist-form--center { margin-inline: auto; }

.waitlist-form.is-sent input,
.waitlist-form.is-sent button { opacity: 0.55; pointer-events: none; }

.hero-note {
  margin-top: 0.9rem;
  font-size: 0.85rem;
  color: var(--ink-mute);
}
.hero-note a { color: var(--primary); font-weight: 600; text-decoration: underline; text-underline-offset: 2px; }

.form-feedback {
  margin-top: 0.9rem;
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--walk);
  display: none;
}
.form-feedback.is-visible { display: block; }

/* Phone mockup */
.phone-frame {
  position: relative;
  width: 240px;
  border-radius: 2.2rem;
  overflow: hidden;
  background: var(--surface);
  box-shadow: var(--shadow-lift);
  border: 6px solid var(--ink);
}
.phone-frame img { width: 100%; display: block; }
.phone-frame--lg { width: 280px; }

/* =============================================================
   6. Nav
   ============================================================= */
.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(248, 249, 251, 0.85);
  backdrop-filter: blur(14px) saturate(160%);
  -webkit-backdrop-filter: blur(14px) saturate(160%);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s var(--ease-out), background 0.3s var(--ease-out);
}
@supports not (backdrop-filter: blur(14px)) {
  .nav { background: rgba(248, 249, 251, 0.98); }
}
.nav.is-scrolled { border-bottom-color: var(--border-light); }
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-block: 0.9rem;
}
.nav-brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--ink);
}
.nav-logo {
  width: 40px; height: 40px;
  border-radius: 50%;
  background: var(--bg-cream);
  padding: 3px;
}
.nav-links {
  display: flex;
  align-items: center;
  gap: 1.8rem;
  font-weight: 600;
  font-size: 0.95rem;
}
.nav-links a:not(.btn) { color: var(--ink-soft); transition: color 0.25s var(--ease-out); }
.nav-links a:not(.btn):hover { color: var(--primary); }
.nav-links a:not(.btn) { display: none; }
@media (min-width: 720px) {
  .nav-links a:not(.btn) { display: inline-block; }
}

/* =============================================================
   7. Hero
   ============================================================= */
.hero {
  position: relative;
  padding-block: clamp(3rem, 8vw, 6rem) clamp(3rem, 6vw, 5rem);
  overflow: hidden;
}
.hero-mesh {
  position: absolute;
  inset: -20% -10% -30% -10%;
  z-index: -1;
  background:
    radial-gradient(at 15% 20%, rgba(13, 93, 110, 0.14) 0%, transparent 55%),
    radial-gradient(at 85% 10%, rgba(224, 122, 30, 0.12) 0%, transparent 50%),
    radial-gradient(at 60% 80%, rgba(63, 145, 66, 0.10) 0%, transparent 55%);
  filter: blur(50px);
  animation: meshDrift 28s ease-in-out infinite;
}
@keyframes meshDrift {
  0%, 100% { transform: scale(1) rotate(0deg); }
  50%      { transform: scale(1.15) rotate(8deg); }
}
.hero-inner {
  display: grid;
  gap: 3rem;
  align-items: center;
}
@media (min-width: 960px) {
  .hero-inner { grid-template-columns: 1.05fr 0.95fr; gap: 2rem; }
}
.hero-title {
  font-size: clamp(2.1rem, 5.4vw, 3.4rem);
  max-width: 16ch;
}
.hero-title em {
  font-style: normal;
  color: var(--primary);
}
.hero-sub {
  margin-top: 1.2rem;
  font-size: 1.1rem;
  color: var(--ink-mute);
  max-width: 44ch;
}
.hero-visual {
  position: relative;
  display: flex;
  justify-content: center;
}
@media (min-width: 960px) {
  .hero-visual { justify-content: flex-end; }
}
.float-chip {
  position: absolute;
  padding: 0.6rem 1rem;
  border-radius: var(--radius-full);
  background: var(--surface);
  box-shadow: var(--shadow-soft);
  font-weight: 700;
  font-size: 0.82rem;
  color: var(--ink);
  border: 1px solid var(--border-light);
  animation: floatY 5s ease-in-out infinite;
}
.float-chip--a { top: 10%; left: -6%; animation-delay: 0s; }
.float-chip--b { bottom: 12%; right: -4%; animation-delay: 1.4s; }
@media (max-width: 539px) {
  .float-chip--a { left: -2%; }
  .float-chip--b { right: -2%; }
}
@keyframes floatY {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-10px); }
}

/* =============================================================
   8. Sections
   ============================================================= */
.section { padding-block: clamp(3.5rem, 7vw, 6rem); }

.section-features .section-title { margin-bottom: 0; }
.eyebrow, .section-title, .section-sub { text-align: left; }

.features-grid {
  margin-top: 2.6rem;
  display: grid;
  gap: 1.2rem;
  grid-template-columns: 1fr;
}
@media (min-width: 720px) {
  .features-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 1280px) {
  .features-grid { grid-template-columns: repeat(4, 1fr); }
}

.feature-card {
  background: var(--surface);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  padding: 1.8rem 1.6rem;
  box-shadow: var(--shadow-soft);
  transition: transform 0.4s var(--ease-out), box-shadow 0.4s var(--ease-out), border-color 0.4s var(--ease-out);
}
.feature-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lift);
  border-color: transparent;
}
.feature-icon {
  width: 52px; height: 52px;
  border-radius: var(--radius-md);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 1.2rem;
  color: #fff;
}
.feature-icon svg { width: 26px; height: 26px; }
.feature-icon.is-walk  { background: var(--walk); }
.feature-icon.is-sleep { background: var(--sleep); }
.feature-icon.is-play  { background: var(--play); }
.feature-icon.is-train { background: var(--train); }
.feature-card h3 { font-size: 1.15rem; margin-bottom: 0.55rem; }
.feature-card p { font-size: 0.95rem; color: var(--ink-mute); }

/* Screens strip */
.section-screens { overflow: visible; }
.screens-track {
  margin-top: 2.6rem;
  display: flex;
  gap: 1.5rem;
  overflow-x: auto;
  overflow-y: visible;
  scroll-snap-type: x proximity;
  padding: 0.5rem 1.25rem 2.5rem;
  scrollbar-width: thin;
}
.screens-track::-webkit-scrollbar { height: 8px; }
.screens-track::-webkit-scrollbar-thumb { background: var(--border-light); border-radius: var(--radius-full); }
.screen-item {
  flex: 0 0 auto;
  scroll-snap-align: center;
  text-align: center;
}
.screen-item .phone-frame { width: 220px; }
.screen-item p {
  margin-top: 1rem;
  font-weight: 700;
  color: var(--ink);
  font-size: 0.9rem;
}

/* Story */
.section-story {
  background: var(--bg-cream);
}
.story-inner {
  max-width: 62ch;
  margin-inline: auto;
  text-align: center;
}
.story-mark { display: flex; justify-content: center; margin-bottom: 1.2rem; }
.story-mark img { width: 100px; opacity: 0.9; }
.story-text {
  font-size: 1.2rem;
  color: var(--ink-soft);
  line-height: 1.65;
}
.section-story .eyebrow { text-align: center; }

/* CTA */
.cta-inner {
  max-width: 640px;
  margin-inline: auto;
  text-align: center;
}
.section-cta .section-title,
.section-cta .section-sub { text-align: center; margin-inline: auto; }

/* =============================================================
   9. Footer
   ============================================================= */
.footer {
  padding-block: 2.5rem;
  border-top: 1px solid var(--border-light);
  text-align: center;
}
.footer-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
}
.footer .nav-brand { justify-content: center; }
.footer-tagline { color: var(--ink-mute); font-size: 0.9rem; }
.footer-copy { color: var(--ink-mute); font-size: 0.82rem; }
.footer-copy a { color: var(--primary); font-weight: 600; }

/* =============================================================
   10. Reveal effects (functional, not gated by reduced-motion)
   ============================================================= */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.7s var(--ease-out), transform 0.7s var(--ease-out);
}
.reveal.is-visible {
  opacity: 1;
  transform: none;
}

/* =============================================================
   11. Responsive
   ============================================================= */
@media (max-width: 539px) {
  .waitlist-form { flex-direction: column; }
  .waitlist-form--center { max-width: 100%; }
}

/* =============================================================
   12. Reduced motion — only intrusive
   ============================================================= */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .hero-mesh { animation: none; }
  .float-chip { animation: none; }
}
