.daywave__mark.is-on {
  opacity: 1; scale: 1;
  box-shadow: 0 0 0 8px color-mix(in srgb, var(--c, var(--steady-teal)) 22%, transparent), 0 2px 8px rgba(33,68,77,0.16);
}
.daywave__mark.is-on.is-settled {
  box-shadow: 0 2px 8px rgba(33,68,77,0.16);
  transition: opacity .35s var(--ease), scale .45s var(--ease), box-shadow .8s ease;
}
.daywave .pin {
  opacity: 0; transform: translateX(-50%) translateY(10px) scale(0.92);
  transition: opacity .45s var(--ease), transform .5s var(--ease), box-shadow .35s var(--ease);
  pointer-events: none;
}
.daywave .pin.is-on {
  opacity: 1; transform: translateX(-50%) translateY(0) scale(1);
  pointer-events: auto;
}
.daywave .pin:hover { transform: translateX(-50%) translateY(-3px); box-shadow: 0 16px 32px rgba(33,68,77,0.18); }
.daywave__now {
  position: absolute; left: 0; top: 0; z-index: 3;
  width: 14px; height: 14px; margin: -7px 0 0 -7px;
  border-radius: 50%; pointer-events: none;
  background: var(--paper);
  border: 3px solid var(--steady-teal);
  box-shadow: 0 0 0 8px rgba(62,110,121,0.14), 0 4px 12px rgba(33,68,77,0.18);
  opacity: 0;
  will-change: transform;
}
.daywave.is-live .daywave__now { opacity: 1; transition: opacity .5s ease; }
.daywave__axis span {
  opacity: 0.28; transition: opacity .5s var(--ease), color .5s ease, transform .5s var(--ease);
  transform: translateY(4px);
}
.daywave__axis span.is-on {
  opacity: 1; transform: translateY(0); color: var(--steady-teal);
}

/* Hover lifts (declared before .stagger so the stagger transition list wins and still animates these) */
.fact, .stat, .tcard, .xcard, .hcard, .cpillar, .wp, .step { transition: transform .4s var(--ease), box-shadow .4s var(--ease), background .3s ease, border-color .3s ease; }
.fact:hover, .stat:hover, .tcard:hover, .xcard:hover, .hcard:hover, .cpillar:hover { transform: translateY(-3px); box-shadow: 0 16px 34px rgba(33,68,77,0.10); }
.wp:hover, .step:hover { transform: translateY(-3px); background: rgba(251,250,247,0.11); border-color: rgba(251,250,247,0.22); }
.stat--ink:hover { box-shadow: 0 16px 34px rgba(33,68,77,0.28); }
.loc { transition: transform .3s var(--ease), border-color .3s ease, box-shadow .3s var(--ease); }
.loc:hover { transform: translateY(-2px); border-color: rgba(62,110,121,0.35); box-shadow: 0 8px 18px rgba(33,68,77,0.08); }
.delta { transition: transform .3s var(--ease); }
.changes li:hover .delta { transform: scale(1.06); }

/* Journal steps feel like a sequence */
.journal-step { transition: background .35s ease; }
.journal-step:hover { background: rgba(255,255,255,0.03); }
.journal-step__n { display: inline-flex; align-items: center; gap: 10px; }
.journal-step__n::after { content: ''; height: 1px; width: 0; background: #C97F5F; transition: width .6s var(--ease) calc(var(--i, 0) * 120ms + .5s); }
.is-in .journal-step__n::after { width: 28px; }

/* Staggered children: JS adds .stagger and sets --i on each child */
.stagger > * {
  --d: calc(var(--i, 0) * var(--stagger-step, 70ms) + var(--stagger-base, 120ms));
  opacity: 0; translate: 0 16px;
  transition:
    opacity .65s var(--ease) var(--d),
    translate .65s var(--ease) var(--d),
    transform .4s var(--ease),
    box-shadow .4s var(--ease),
    border-color .3s ease,
    background .2s ease,
    color .2s ease;
}
.stagger.is-in > *, .is-in .stagger > * { opacity: 1; translate: 0 0; }
.heatmap.stagger { --stagger-step: 11ms; --stagger-base: 60ms; }
.heatmap.stagger > * { translate: 0 0; scale: .55; transition: opacity .55s var(--ease) var(--d), scale .55s var(--ease) var(--d); }
.heatmap.stagger.is-in > *, .is-in .heatmap.stagger > * { scale: 1; }
.metrics.stagger { --stagger-step: 45ms; }
.locales.stagger { --stagger-step: 35ms; }
.ticks.stagger { --stagger-step: 90ms; --stagger-base: 200ms; }
.dash__rows.stagger, .changes.stagger, .plist.stagger, .card--settings.stagger { --stagger-step: 90ms; --stagger-base: 200ms; }

/* ═══════════ Sleep — from moonrise to sunrise ═══════════ */
.sleep-sec {
  --t: .5; --night: .5; --dawn: .25;
  --mx: 36%; --my: 17%; --sx: 88%; --sy: 80%;
  --moon-o: 1; --sun-o: .6; --mpin-o: 1; --spin-o: .7;
  overflow: hidden;
}
.sleep-sec > .wrap { position: relative; z-index: 1; padding-top: 148px; }
.sky { position: absolute; inset: 0; pointer-events: none; overflow: hidden; z-index: 0; }
/* Sky wash: mist → soft indigo night → back to mist */
.sky__wash {
  position: absolute; inset: 0;
  background: linear-gradient(180deg,
    color-mix(in oklab, var(--mist), #5B5AC8 calc(var(--night) * 30%)) 0%,
    color-mix(in oklab, var(--mist), #A9A6E3 calc(var(--night) * 22%)) 48%,
    var(--mist) 100%);
}
/* Dawn: warm light spilling from where the sun rises */
.sky__dawn {
  position: absolute; inset: -10%;
  background:
    radial-gradient(42% 36% at var(--sx) var(--sy), rgba(232,203,164,0.85), rgba(201,127,95,0.28) 42%, transparent 72%),
    linear-gradient(0deg, rgba(232,203,164,0.28), transparent 45%);
  opacity: var(--dawn);
  filter: blur(6px);
}
.sky__stars { position: absolute; inset: 0; opacity: calc(var(--night) * 0.95); }
.sky__stars i {
  position: absolute; display: block; border-radius: 99px; background: #fff;
  box-shadow: 0 0 6px 1px rgba(255,255,255,0.7);
  animation: twinkle var(--tw, 3s) ease-in-out var(--td, 0s) infinite;
}
@keyframes twinkle { 0%, 100% { opacity: .25; scale: .8; } 50% { opacity: 1; scale: 1.15; } }
.sky__arc { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.sky__arc path, .sky__arc line { fill: none; vector-effect: non-scaling-stroke; stroke-linecap: round; }
.sky__arc .sky__path { stroke: rgba(62,110,121,0.28); stroke-width: 1.5; stroke-dasharray: 2 7; }
.sky__arc .sky__horizon { stroke: rgba(62,110,121,0.22); stroke-width: 1.5; stroke-dasharray: 2 8; }
.sky__moon, .sky__sun { position: absolute; border-radius: 50%; translate: -50% -50%; will-change: left, top; }
.sky__moon {
  left: var(--mx); top: var(--my); width: 62px; height: 62px;
  background: radial-gradient(circle at 36% 34%, #FFFFFF, #EFEDFA 58%, #D8D6EF 100%);
  box-shadow:
    inset -9px -7px 0 0 rgba(88,86,214,0.10),
    0 0 0 14px rgba(255,255,255,0.20),
    0 0 70px 22px rgba(120,118,230, calc(0.38 * var(--night)));
  opacity: var(--moon-o);
}
.sky__moon::before, .sky__moon::after {
  content: ''; position: absolute; border-radius: 50%; background: rgba(88,86,214,0.08);
}
.sky__moon::before { width: 12px; height: 12px; left: 22%; top: 30%; }
.sky__moon::after { width: 8px; height: 8px; left: 56%; top: 58%; }
.sky__sun {
  left: var(--sx); top: var(--sy); width: 74px; height: 74px;
  background: radial-gradient(circle at 40% 38%, #FFF6DF, #F3CE93 52%, #E2A469 100%);
  box-shadow:
    0 0 0 18px rgba(232,203,164,0.22),
    0 0 0 40px rgba(232,203,164,0.08),
    0 0 110px 44px rgba(232,203,164,0.55);
  opacity: var(--sun-o);
}
.sky__pin {
  animation: none; opacity: 1; transform: none;
  position: absolute; z-index: 2;
  background: rgba(251,250,247,0.92); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px);
}
.sky__pin--moon { left: var(--mx); top: var(--my); translate: 46px -50%; opacity: var(--mpin-o); }
.sky__pin--sun { left: var(--sx); top: var(--sy); translate: -50% 54px; opacity: var(--spin-o); }
.sky__pin--sun .dot { background: var(--clay); }
.sky__pin--moon .dot { background: var(--c-sleep); }
.sleep-sec .card--sleep { background: rgba(255,255,255,0.96); }
.sleep-sec .bell { transition: transform .4s var(--ease); }
.sleep-sec .card--sleep:hover .bell { transform: rotate(-8deg); }

/* ── Sticky mobile CTA (appears after the hero on narrow screens) ── */
.sticky-cta {
  position: fixed; left: 12px; right: 12px; bottom: 12px; z-index: 60;
  display: none; translate: 0 130%; opacity: 0;
  transition: translate .55s var(--ease), opacity .4s ease;
}
.sticky-cta__inner {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 10px 10px 14px; border-radius: 22px;
  background: rgba(251,250,247,0.92); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border); box-shadow: 0 18px 44px rgba(33,68,77,0.22);
}
.sticky-cta__inner img { width: 34px; height: 34px; border-radius: 10px; }
.sticky-cta__t { flex: 1; display: flex; flex-direction: column; line-height: 1.25; min-width: 0; }
.sticky-cta__t b { font-size: 14px; font-weight: 700; }
.sticky-cta__t span { font-size: 12px; color: var(--text-2); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sticky-cta .btn { white-space: nowrap; }

/* ── Reduced motion: everything above settles into its final state ── */
@media (prefers-reduced-motion: reduce) {
  .hero__copy > *, .hero-devices img, .hero-devices .hero-devices__watch,
  .daywave .pin, .daywave__axis span, .daywave > .daywave__mark, .daywave__now,
  .daywave__line, .daywave__fill { animation: none !important; opacity: 1 !important; translate: none !important; scale: none !important; transform: none !important; stroke-dashoffset: 0 !important; transition: none !important; }
  .daywave .pin { transform: translateX(-50%) !important; }
  .daywave__now, .sched__arc-dot { display: none; }
  .daywave__line { stroke-dasharray: none !important; }
  .section--orbs::before, .section--deep::after, .section--footer::before, .sky__stars i, .sched__arc-rays { animation: none !important; }
  .stagger > *, .heatmap.stagger > * { opacity: 1 !important; translate: none !important; scale: none !important; transition: none !important; }
  .journal-step__n::after { transition: none; }
  .card.is-tilt { transform: none !important; transition: none !important; }
  .card.is-tilt::after { display: none; }
  .sky__moon, .sky__sun, .sky__pin, .sky__wash, .sky__dawn, .sky__stars { transition: none !important; }
  .sticky-cta { transition: none; }
}

/* ── Responsive ── */
@media (max-width: 1000px) {
  .fast__grid { grid-template-columns: 1fr 1fr; }
  .fast__side { grid-column: 1 / -1; display: grid; grid-template-columns: 1fr 1fr; align-items: start; }
}
@media (max-width: 900px) {
  .journal-ink__title,
  .journal-flow__head { flex-direction: column; align-items: flex-start; }
  .journal-flow__grid { grid-template-columns: repeat(2, 1fr); }
  .journal-steps { grid-template-columns: repeat(2, 1fr); }
  .feature { grid-template-columns: 1fr; gap: 40px; }
  .feature--flip .feature__copy { order: 0; }
  .steps { grid-template-columns: 1fr; }
  .statgrid { grid-template-columns: 1fr 1fr; }
  .stressx, .trio { grid-template-columns: 1fr; }
  .privacy { grid-template-columns: 1fr; gap: 32px; }
  .glance .wrap { grid-template-columns: 1fr; gap: 28px; }
  .nav__links { gap: 16px; }
  .nav__links a:not(.btn) { display: none; }
  .hero__title { font-size: 52px; }
  .hero__row { grid-template-columns: 1fr; padding: 56px 24px 0; gap: 12px; }
  .hero__copy { align-items: center; text-align: center; max-width: none; }
  .hero__cta { justify-content: center; }
  .hero-devices { max-width: 540px; margin: 8px auto 0; justify-content: center; }
  .hero-devices__ipad,
  .hero-devices__iphone,
  .hero-devices__watch,
  .daywave,
  .ws img {
    --py: 0px !important;
    will-change: auto;
  }
  .hero-devices__iphone { width: 26%; max-width: 160px; margin-right: -12%; }
  .hero-devices__ipad { width: 54%; max-width: 300px; margin-right: -10%; }
  .hero-devices__watch { width: 18%; max-width: 108px; }
  .h2 { font-size: 36px; }
  .chat-pillars { grid-template-columns: 1fr; }
  .card--history { padding: 24px; width: 100%; max-width: 100%; }
  /* Start-align so overflow scrolls rightward; JS pins to recent weeks */
  .heatmap { justify-content: start; }
  .h2--fast { font-size: 36px; }
  .watch-points { grid-template-columns: 1fr 1fr; }
  .watch-scatter {
    display: flex; flex-wrap: wrap; justify-content: center; align-items: flex-end;
    gap: 8px 4px; min-height: 0; padding: 0;
  }
  .ws { width: 42%; max-width: 200px; }
  .ws--health, .ws--stress, .ws--breath, .ws--sleep, .ws--weight, .ws--vo2 {
    grid-column: auto; grid-row: auto; transform: none; max-width: none; justify-self: auto;
  }
  .ws--health { transform: rotate(3deg); }
  .ws--stress { transform: rotate(-5deg); }
  .ws--breath { transform: rotate(4deg) translateY(18px); width: 46%; }
  .ws--sleep  { transform: rotate(-3deg); }
  .ws--weight { transform: rotate(6deg); width: 36%; }
  .ws--vo2    { transform: rotate(-6deg) translateY(-8px); width: 36%; }
  .ws--health:hover, .ws--stress:hover, .ws--breath:hover, .ws--sleep:hover, .ws--weight:hover, .ws--vo2:hover {
    transform: translateY(-6px);
  }
  .watch-peek--sleep,
  .watch-peek--stress { position: static; width: 120px; margin: 12px auto 0; transform: rotate(4deg); display: block; }
  .demo-with-watch { display: flex; flex-direction: column; align-items: center; max-width: 400px; }
  .watch-peek--mini { display: none; }
  .watch-points { grid-template-columns: 1fr; }
  .sticky-cta { display: block; }
  body.show-sticky-cta .sticky-cta { translate: 0 0; opacity: 1; }
  .sleep-sec > .wrap { padding-top: 132px; }
  .sky__moon { width: 50px; height: 50px; opacity: calc(var(--moon-o) * .75); }
  .sky__sun { width: 60px; height: 60px; }
  .sky__pin { display: none; }
  .card.is-tilt { transform: none; }
}
@media (max-width: 640px) {
  .fast__grid { grid-template-columns: 1fr; }
  .fast__side { grid-template-columns: 1fr; }
  .habits { grid-template-columns: 1fr; }
  .wm { grid-template-columns: 1fr; gap: 8px; }
  .wm-lock { border-radius: 20px; padding: 20px 16px 22px; }
  .wm-lock__circs img { width: 56px; height: 56px; }
  .wm-lock__rects img { width: 132px; }
  .card--cycle { grid-template-columns: 1fr; justify-items: center; }
  .card--water { grid-template-columns: 1fr; justify-items: center; }
  .water__side { width: 100%; }
}
@media (max-width: 560px) {
  .journal-flow__grid,
  .journal-steps { grid-template-columns: 1fr; }
  .journal-flow__shot { padding: 8px 36px 4px; }
  .wrap { padding: 64px 20px; }
  .glance .wrap { padding: 36px 20px; }
  .hero__row { padding: 48px 20px 0; }
  .hero-devices { max-width: 100%; }
  .hero-devices__iphone { width: 28%; max-width: 128px; margin-right: -12%; }
  .hero-devices__ipad { width: 52%; max-width: 220px; margin-right: -10%; }
  .hero-devices__watch { width: 20%; max-width: 88px; }
  .statgrid { grid-template-columns: 1fr; }
  .hero__title { font-size: 46px; }
  .facts { grid-template-columns: 1fr 1fr; }
  .fast__ring { width: 260px; height: 260px; }
  .ring__time { font-size: 34px; }
  .meal__top { grid-template-columns: 1fr; }
  .photo { width: 100%; height: auto; aspect-ratio: 4 / 3; }
  .ws { width: 46%; }
  .ws--breath { width: 52%; }
  .sleep-sec > .wrap { padding-top: 112px; }
  .sched { grid-template-columns: 1fr auto 1fr; gap: 8px; }
  .sched__arc { width: 90px; height: 30px; }
  .sticky-cta__t span { display: none; }
}
