/* Easewell landing. Tokens mirror ios/Easewell/DesignSystem/DSColor.swift (see docs/design/tokens.json). */
:root {
  --bg: #f5f5f7; --surface: #fff; --surface2: #f2f2f5; --track: #e8e8ed; --sep: #ededf0;
  --ink: #0a0a0a; --ink2: #6e6e73; --ink3: #aeaeb2; --action: #0a0a0a; --on-action: #fff;
  --protein: #e8604c; --fiber: #f0a43a; --water: #3e8bf5; --activity: #34c759; --dose: #e2558f; --coach: #5b7cfa;
  --protein-soft: #fdebe7; --fiber-soft: #fef2df; --water-soft: #e6f0fe; --activity-soft: #e3f6e8; --dose-soft: #fce7f0; --coach-soft: #e9edff;
  --shadow: 0 1px 2px rgba(0,0,0,.04), 0 12px 32px rgba(0,0,0,.06);
  --phone: #0a0a0a;
  --max: 1120px;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #000; --surface: #1c1c1e; --surface2: #2c2c2e; --track: #3a3a3c; --sep: #38383a;
    --ink: #f5f5f7; --ink2: #98989d; --ink3: #636366; --action: #fff; --on-action: #0a0a0a;
    --protein: #ff7a66; --fiber: #ffb547; --water: #5aa0ff; --activity: #30d158; --dose: #ff7fb0; --coach: #8ea3ff;
    --protein-soft: #3d211c; --fiber-soft: #3a2c14; --water-soft: #172a44; --activity-soft: #16331f; --dose-soft: #3d1b2b; --coach-soft: #1d2242;
    --shadow: 0 1px 2px rgba(0,0,0,.4), 0 12px 32px rgba(0,0,0,.5);
    --phone: #2c2c2e;
  }
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } *, *::before, *::after { animation: none !important; transition: none !important; } }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 17px/1.5 -apple-system, BlinkMacSystemFont, "SF Pro Text", "Inter", "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
a { color: inherit; }
img, svg { display: block; }
.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 20px; }
.ic { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

/* Nav */
.nav { position: sticky; top: 0; z-index: 10; background: color-mix(in srgb, var(--bg) 82%, transparent); backdrop-filter: saturate(180%) blur(20px); -webkit-backdrop-filter: saturate(180%) blur(20px); }
.nav .wrap { display: flex; align-items: center; gap: 24px; height: 64px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 700; font-size: 19px; letter-spacing: -.3px; text-decoration: none; }
.mark { width: 30px; height: 30px; border-radius: 9px; background: var(--action); color: var(--on-action); display: grid; place-items: center; }
.mark svg { width: 17px; height: 17px; }
.nav nav { display: flex; gap: 22px; margin-left: auto; }
.nav nav a { text-decoration: none; color: var(--ink2); font-size: 15px; font-weight: 500; }
.nav nav a:hover { color: var(--ink); }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 52px; padding: 0 26px; border-radius: 26px; font-weight: 700; font-size: 17px; text-decoration: none; transition: transform .15s ease, opacity .15s ease; }
.btn:active { transform: scale(.98); }
.btn-primary { background: var(--action); color: var(--on-action); }
.btn-primary:hover { opacity: .88; }
.btn-ghost { background: var(--surface); color: var(--ink); box-shadow: var(--shadow); }
.btn-sm { height: 40px; padding: 0 18px; font-size: 15px; border-radius: 20px; }
@media (max-width: 760px) { .nav nav { display: none; } .nav .btn-sm { margin-left: auto; } }

/* Hero */
.hero { padding: 56px 0 40px; }
.hero .wrap { display: grid; grid-template-columns: 1.05fr .95fr; align-items: center; gap: 48px; }
.eyebrow { display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px; border-radius: 999px; background: var(--surface); box-shadow: var(--shadow); font-size: 14px; font-weight: 600; color: var(--ink2); }
.eyebrow i { width: 8px; height: 8px; border-radius: 4px; background: var(--dose); }
h1 { font-size: clamp(40px, 6.2vw, 68px); line-height: 1.03; letter-spacing: -2px; margin: 20px 0 18px; font-weight: 800; }
.lead { font-size: clamp(18px, 2vw, 21px); color: var(--ink2); margin: 0 0 30px; max-width: 30em; }
.ctas { display: flex; flex-wrap: wrap; gap: 12px; }
.fine { margin-top: 16px; color: var(--ink2); font-size: 14px; }

.stage { position: relative; display: flex; justify-content: center; padding: 20px 0; }
.blob { position: absolute; border-radius: 50%; filter: blur(2px); opacity: .9; z-index: 0; }
@media (prefers-color-scheme: dark) { .blob { opacity: .55; } }
.blob.b1 { width: 220px; height: 220px; background: var(--dose-soft); left: 0; top: 40px; }
.blob.b2 { width: 200px; height: 200px; background: var(--water-soft); right: 0; top: 0; }
.blob.b3 { width: 180px; height: 180px; background: var(--fiber-soft); right: 10px; bottom: 30px; }
.blob.b4 { width: 160px; height: 160px; background: var(--activity-soft); left: 20px; bottom: 10px; }

.phone { position: relative; z-index: 1; width: 300px; border-radius: 48px; padding: 10px; background: var(--phone); box-shadow: 0 30px 60px rgba(0,0,0,.18); }
.screen { border-radius: 39px; background: var(--bg); overflow: hidden; padding: 14px 14px 18px; height: 600px; position: relative; }
.island { width: 92px; height: 26px; border-radius: 13px; background: #000; margin: 0 auto 12px; }
.scr-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; }
.scr-head b { font-size: 26px; letter-spacing: -.6px; }
.pill { font-size: 11px; font-weight: 600; padding: 4px 9px; border-radius: 999px; background: var(--surface); }
.card { background: var(--surface); border-radius: 18px; padding: 14px; }
.card + .card, .card + .tiles, .tiles + .card { margin-top: 10px; }
.k { font-size: 10px; font-weight: 700; letter-spacing: .6px; text-transform: uppercase; color: var(--ink2); }
.shot { background: var(--dose-soft); }
.shot .row { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.shot .k { color: var(--dose); }
.shot .t { font-weight: 600; font-size: 13px; }
.shot .when { text-align: right; } .shot .when b { display: block; font-size: 18px; } .shot .when span { font-size: 11px; color: var(--ink2); }
.mini-btn { display: inline-block; margin-top: 10px; background: var(--action); color: var(--on-action); border-radius: 999px; font-size: 12px; font-weight: 700; padding: 7px 14px; }
.tiles { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.tile { background: var(--surface); border-radius: 16px; padding: 10px 6px; text-align: center; font-size: 11px; font-weight: 600; }
.tile small { display: block; color: var(--ink2); font-weight: 500; font-size: 10px; }
.weight .top { display: flex; justify-content: space-between; font-size: 13px; font-weight: 600; } .weight .top b { font-size: 16px; }
.weight svg { width: 100%; height: 80px; margin-top: 8px; }
.tabbar { position: absolute; left: 14px; right: 14px; bottom: 16px; display: flex; gap: 8px; align-items: center; }
.tabbar .tabs { flex: 1; height: 48px; border-radius: 24px; background: var(--surface); display: flex; justify-content: space-around; align-items: center; color: var(--ink2); box-shadow: var(--shadow); }
.tabbar .tabs svg { width: 18px; height: 18px; }
.tabbar .plus { width: 48px; height: 48px; border-radius: 24px; background: var(--action); color: var(--on-action); display: grid; place-items: center; }

.float { position: absolute; z-index: 2; display: flex; align-items: center; gap: 8px; background: var(--surface); border-radius: 999px; padding: 10px 16px 10px 10px; font-weight: 600; font-size: 15px; box-shadow: var(--shadow); white-space: nowrap; animation: bob 6s ease-in-out infinite; }
.float .d { width: 26px; height: 26px; border-radius: 13px; display: grid; place-items: center; }
.float .d svg { width: 15px; height: 15px; }
.f1 { left: -8px; top: 120px; } .f1 .d { background: var(--dose); color: #fff; }
.f2 { right: -16px; top: 330px; animation-delay: -2s; } .f2 .d { background: var(--protein-soft); color: var(--protein); }
.f3 { left: -20px; bottom: 120px; animation-delay: -4s; } .f3 .d { background: var(--water-soft); color: var(--water); }
@keyframes bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }

@media (max-width: 900px) {
  .hero { padding-top: 32px; }
  .hero .wrap { grid-template-columns: 1fr; gap: 24px; text-align: center; }
  .lead { margin-left: auto; margin-right: auto; }
  .ctas { justify-content: center; }
  .f1 { left: 0; } .f2 { right: 0; } .f3 { left: 0; }
}
@media (max-width: 420px) {
  .phone { width: 270px; } .screen { height: 540px; }
  .float { font-size: 13px; padding: 8px 12px 8px 8px; }
  .f2 { top: 300px; }
}

/* Strip */
.strip { padding: 8px 0 24px; }
.strip ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }
.strip li { display: flex; align-items: center; gap: 8px; background: var(--surface); border-radius: 999px; padding: 10px 16px; font-weight: 600; font-size: 15px; }
.strip li span { width: 26px; height: 26px; border-radius: 13px; display: grid; place-items: center; }
.strip li svg { width: 15px; height: 15px; }

/* Sections */
section { padding: 72px 0; }
.sec-head { text-align: center; max-width: 680px; margin: 0 auto 44px; }
h2 { font-size: clamp(32px, 4.4vw, 48px); line-height: 1.08; letter-spacing: -1.4px; margin: 0 0 14px; font-weight: 800; }
.sec-head p { color: var(--ink2); font-size: 19px; margin: 0; }

.feature { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; }
.feature + .feature { margin-top: 88px; }
.feature.flip .copy { order: 2; }
.tag { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 700; margin-bottom: 14px; }
.tag span { width: 30px; height: 30px; border-radius: 15px; display: grid; place-items: center; }
.tag svg { width: 16px; height: 16px; }
.feature h3 { font-size: clamp(28px, 3.4vw, 38px); line-height: 1.1; letter-spacing: -1px; margin: 0 0 14px; font-weight: 800; }
.feature p { color: var(--ink2); font-size: 18px; margin: 0 0 18px; }
.checks { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.checks li { display: flex; gap: 10px; align-items: flex-start; font-weight: 500; }
.checks li::before { content: ""; flex: none; margin-top: 3px; width: 20px; height: 20px; border-radius: 10px; background: var(--ink) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E") center/12px no-repeat; }
@media (prefers-color-scheme: dark) { .checks li::before { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E"); } }

.panel { background: var(--surface2); border-radius: 32px; padding: 28px; display: flex; flex-direction: column; gap: 12px; }
.panel .card { box-shadow: var(--shadow); padding: 18px; border-radius: 22px; }
.panel .card + .card { margin-top: 0; }


.goal { display: grid; grid-template-columns: 38px 1fr auto; gap: 12px; align-items: center; }
.goal + .goal { margin-top: 16px; padding-top: 16px; border-top: 1px solid var(--sep); }
.goal .d { width: 38px; height: 38px; border-radius: 19px; display: grid; place-items: center; }
.goal .d svg { width: 18px; height: 18px; }
.goal .n { display: flex; justify-content: space-between; font-weight: 600; font-size: 15px; margin-bottom: 6px; }
.goal .n span { color: var(--ink2); font-weight: 500; } .goal .n span b { color: var(--ink); }
.bar { height: 6px; border-radius: 3px; background: var(--track); overflow: hidden; }
.bar i { display: block; height: 100%; border-radius: 3px; }
.add { font-size: 13px; font-weight: 700; padding: 7px 12px; border-radius: 999px; }

.chat { display: flex; flex-direction: column; gap: 8px; }
.bub { max-width: 82%; padding: 12px 16px; border-radius: 20px; background: var(--surface); font-size: 16px; box-shadow: var(--shadow); }
.bub.me { align-self: flex-end; background: var(--action); color: var(--on-action); }
.chips { display: flex; gap: 8px; flex-wrap: wrap; }
.chip { display: inline-flex; align-items: center; gap: 6px; background: var(--surface); border-radius: 999px; padding: 9px 14px; font-weight: 600; font-size: 14px; box-shadow: var(--shadow); }
.disc { font-size: 12px; color: var(--ink3); text-align: center; margin-top: 4px; }
.inputbar { display: flex; align-items: center; gap: 10px; background: var(--surface); border-radius: 999px; padding: 12px 18px; color: var(--ink3); box-shadow: var(--shadow); font-size: 15px; }


@media (max-width: 860px) {
  section { padding: 56px 0; }
  .feature, .feature.flip { grid-template-columns: 1fr; gap: 28px; }
  .feature.flip .copy { order: 0; }
  .feature + .feature { margin-top: 64px; }
  .panel { padding: 18px; border-radius: 26px; }
}

/* Steps */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; counter-reset: s; }
.step { background: var(--surface); border-radius: 26px; padding: 26px; }
.step::before { counter-increment: s; content: counter(s); display: grid; place-items: center; width: 40px; height: 40px; border-radius: 20px; background: var(--action); color: var(--on-action); font-weight: 800; margin-bottom: 18px; }
.step h3 { margin: 0 0 8px; font-size: 21px; letter-spacing: -.4px; }
.step p { margin: 0; color: var(--ink2); }
@media (max-width: 760px) { .steps { grid-template-columns: 1fr; } }

/* Trust */
.trust { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.trust div { background: var(--surface); border-radius: 26px; padding: 26px; }
.trust h3 { margin: 14px 0 8px; font-size: 19px; letter-spacing: -.3px; }
.trust p { margin: 0; color: var(--ink2); font-size: 16px; }
.trust span { width: 40px; height: 40px; border-radius: 20px; display: grid; place-items: center; background: var(--surface2); }
@media (max-width: 760px) { .trust { grid-template-columns: 1fr; } }

/* FAQ */
.faq { max-width: 760px; margin: 0 auto; display: grid; gap: 10px; }
.faq details { background: var(--surface); border-radius: 20px; padding: 0 22px; }
.faq summary { list-style: none; cursor: pointer; padding: 20px 0; font-weight: 600; font-size: 18px; display: flex; justify-content: space-between; gap: 16px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-weight: 400; font-size: 24px; line-height: 1; color: var(--ink2); transition: transform .2s ease; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { margin: 0 0 20px; color: var(--ink2); }

/* Final CTA */
.final { padding: 40px 0 88px; }
.final .box { background: var(--action); color: var(--on-action); border-radius: 36px; padding: 64px 28px; text-align: center; }
.final h2 { margin-bottom: 12px; }
.final p { opacity: .7; font-size: 19px; margin: 0 0 28px; }
.final .btn-primary { background: var(--on-action); color: var(--action); }

/* Footer */
footer { border-top: 1px solid var(--sep); padding: 36px 0 48px; color: var(--ink2); font-size: 14px; }
footer .wrap { display: flex; flex-wrap: wrap; gap: 20px 32px; align-items: flex-start; justify-content: space-between; }
footer .links { display: flex; flex-wrap: wrap; gap: 20px; }
footer a { text-decoration: none; } footer a:hover { color: var(--ink); }
footer .disclaimer { flex-basis: 100%; font-size: 13px; color: var(--ink3); max-width: 760px; margin: 0; }

/* Legal pages */
.legal { max-width: 760px; margin: 0 auto; padding: 48px 20px 80px; }
.legal h1 { font-size: clamp(36px, 5vw, 48px); letter-spacing: -1.2px; margin: 0 0 8px; }
.legal .updated { color: var(--ink2); margin: 0 0 36px; }
.legal h2 { font-size: 24px; letter-spacing: -.4px; margin: 36px 0 10px; }
.legal p, .legal li { color: var(--ink2); }
.legal strong { color: var(--ink); }
.legal ul { padding-left: 22px; }
.legal li + li { margin-top: 6px; }
.legal .box { background: var(--surface); border-radius: 20px; padding: 20px 22px; }

/* ---------- v2: live demos and motion ---------- */
/* Base rules describe the finished state. `.js .reveal:not(.in)` holds the starting state, so the
   page is complete without JS, and with reduced motion things simply appear. */
.reveal { transition: opacity .7s ease, transform .7s cubic-bezier(.2,.7,.2,1); transition-delay: var(--rd, 0s); }
.js .reveal:not(.in) { opacity: 0; transform: translateY(26px); }
.draw { stroke-dasharray: 1; stroke-dashoffset: 0; transition: stroke-dashoffset 2s cubic-bezier(.4,0,.2,1) .25s; }
.js .reveal:not(.in) .draw { stroke-dashoffset: 1; }
.area { transition: opacity 1s ease 1.3s; }
.js .reveal:not(.in) .area { opacity: 0; }
.popin { transform-box: fill-box; transform-origin: center; transition: opacity .35s ease, transform .5s cubic-bezier(.3,1.6,.5,1); transition-delay: var(--d, 0s); }
.js .reveal:not(.in) .popin { opacity: 0; transform: scale(.4); }
.bar i { transition: width 1.2s cubic-bezier(.2,.7,.2,1) .3s; }

/* Hero phone */
.ring { width: 44px; height: 44px; margin: 0 auto 6px; }
.ring circle { fill: none; stroke-width: 6; }
.ring .rt { stroke: var(--track); }
.ring .rv { stroke-linecap: round; stroke-dasharray: 100; stroke-dashoffset: calc(100 - var(--p)); transform: rotate(-90deg); transform-origin: center; transition: stroke-dashoffset 1.4s cubic-bezier(.2,.7,.2,1) .5s; }
.js .reveal:not(.in) .ring .rv { stroke-dashoffset: 100; }
.stage.reveal { transition-duration: .9s; }
.js .stage.reveal:not(.in) .float { opacity: 0; scale: .8; }
.float { transition: opacity .5s ease, scale .6s cubic-bezier(.3,1.6,.5,1); }
.f1 { transition-delay: .9s; } .f2 { transition-delay: 1.3s; } .f3 { transition-delay: 1.7s; }
.mini-btn { animation: nudge 5s ease-in-out 2.5s infinite; }
@keyframes nudge { 0%, 88%, 100% { transform: scale(1); } 92% { transform: scale(.93); } 96% { transform: scale(1.04); } }
.hero-copy > * { animation: rise .8s cubic-bezier(.2,.7,.2,1) both; }
.hero-copy > :nth-child(2) { animation-delay: .08s; } .hero-copy > :nth-child(3) { animation-delay: .16s; }
.hero-copy > :nth-child(4) { animation-delay: .24s; } .hero-copy > :nth-child(5) { animation-delay: .32s; }
@keyframes rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }

/* Shared card bits */
.chead { display: flex; align-items: center; gap: 10px; margin-bottom: 12px; }
.chead .d, .chat-head .d { width: 32px; height: 32px; border-radius: 16px; display: grid; place-items: center; flex: none; }
.chead .d svg, .chat-head .d svg { width: 16px; height: 16px; }
.chead b { font-size: 17px; letter-spacing: -.2px; }
.chead small { margin-left: auto; color: var(--ink2); font-size: 13px; }
.badge { display: inline-block; font-size: 13px; font-weight: 600; padding: 5px 12px; border-radius: 999px; background: var(--dose-soft); color: var(--dose); white-space: nowrap; }
.badge.green { background: var(--activity-soft); color: var(--activity); }
.ax { font-size: 10px; fill: var(--ink2); font-family: inherit; }
.ax.strong { font-size: 12px; font-weight: 700; fill: var(--ink); }
svg.med, svg.wchart { width: 100%; height: auto; overflow: visible; color: var(--ink); }

/* Shots */
.stages { display: flex; gap: 4px; margin-top: 4px; padding-right: 9%; }
.stages i { height: 6px; border-radius: 3px; background: var(--dose); }
.stage-l { display: flex; gap: 4px; padding-right: 9%; margin-top: 6px; font-size: 12px; font-weight: 600; }
.est { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; }
.est b { font-size: 19px; letter-spacing: -.3px; }
.todo { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.todo li { display: flex; align-items: center; gap: 12px; font-size: 16px; }
.todo li span { margin-left: auto; color: var(--ink2); font-size: 14px; }
.todo i { flex: none; width: 24px; height: 24px; border-radius: 12px; border: 2px solid var(--ink3); display: grid; place-items: center; }
.todo .done i { background: var(--activity); border-color: var(--activity); color: #fff; }
.todo .done i svg { width: 13px; height: 13px; stroke-width: 3; }
.todo em { font-style: normal; }
.todo .done em { color: var(--ink2); text-decoration: line-through; text-decoration-color: var(--ink3); }

/* Food: meal scan */
.plate { position: relative; height: 170px; border-radius: 16px; background: var(--surface2); overflow: hidden; display: grid; place-items: center; }
.plate svg { height: 150px; filter: drop-shadow(0 8px 14px rgba(0,0,0,.12)); }
.corner { position: absolute; width: 22px; height: 22px; border: 3px solid var(--ink); opacity: .85; }
.corner.tl { left: 14px; top: 14px; border-right: 0; border-bottom: 0; border-radius: 8px 0 0 0; }
.corner.tr { right: 14px; top: 14px; border-left: 0; border-bottom: 0; border-radius: 0 8px 0 0; }
.corner.bl { left: 14px; bottom: 14px; border-right: 0; border-top: 0; border-radius: 0 0 0 8px; }
.corner.br { right: 14px; bottom: 14px; border-left: 0; border-top: 0; border-radius: 0 0 8px 0; }
.scanline { position: absolute; left: 0; right: 0; top: 0; height: 46px; opacity: 0; background: linear-gradient(to bottom, transparent, color-mix(in srgb, var(--coach) 35%, transparent)); border-bottom: 2px solid var(--coach); }
.play .scanline { animation: sweep 1.9s ease-in-out 1 both; }
@keyframes sweep { 0% { transform: translateY(-46px); opacity: 0; } 12% { opacity: 1; } 88% { opacity: 1; } 100% { transform: translateY(170px); opacity: 0; } }
.found { margin: 12px 0; min-height: 38px; }
.found .chip { box-shadow: none; background: var(--surface2); }
.js .sq { opacity: 0; transform: translateY(8px) scale(.97); }
.js .play .sq { opacity: 1; transform: none; transition: opacity .4s ease, transform .5s cubic-bezier(.3,1.4,.5,1); transition-delay: var(--d, 0s); }
.total .trow { display: flex; justify-content: space-between; align-items: baseline; font-weight: 600; }
.total .trow b { font-size: 26px; letter-spacing: -.6px; font-variant-numeric: tabular-nums; } .total .trow small { font-size: 14px; color: var(--ink2); font-weight: 500; }
.macros { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-top: 10px; }
.macros b { display: block; font-size: 17px; } .macros span { display: flex; align-items: center; gap: 5px; font-size: 12px; color: var(--ink2); }
.macros i { width: 7px; height: 7px; border-radius: 4px; }
.logbtn { display: block; margin-top: 16px; text-align: center; background: var(--action); color: var(--on-action); border-radius: 999px; padding: 13px; font-weight: 700; }
.js .play .logbtn { animation: press .6s ease 3.9s 1; }
@keyframes press { 40% { transform: scale(.95); opacity: .8; } 100% { transform: none; } }
.pbar { width: 81%; }
.js [data-scan] .pbar { width: 35%; transition: none; }
.js [data-scan].play .pbar { width: 81%; transition: width 1s cubic-bezier(.2,.7,.2,1) 4.3s; }
.goal .n b { font-variant-numeric: tabular-nums; }

/* Coach */
.chatwin { display: flex; flex-direction: column; gap: 12px; }
.chat-head { display: flex; align-items: center; gap: 10px; }
.chat-head b { font-size: 20px; letter-spacing: -.4px; }
.beta { font-size: 12px; font-weight: 600; padding: 3px 9px; border-radius: 999px; background: var(--coach-soft); color: var(--coach); }
.chat { height: 350px; justify-content: flex-end; overflow: hidden; transition: opacity .4s ease; -webkit-mask-image: linear-gradient(to bottom, transparent, #000 36px); mask-image: linear-gradient(to bottom, transparent, #000 36px); padding: 0 2px 4px; }
.chat.fade { opacity: 0; }
.chat > * { flex: none; }
.bub { border-bottom-left-radius: 6px; }
.bub.me { border-bottom-left-radius: 20px; border-bottom-right-radius: 6px; }
.pop { animation: pop .45s cubic-bezier(.3,1.4,.5,1) both; transform-origin: left bottom; }
.bub.me.pop { transform-origin: right bottom; }
@keyframes pop { from { opacity: 0; transform: translateY(10px) scale(.92); } to { opacity: 1; transform: none; } }
.typing { display: inline-flex; gap: 5px; align-self: flex-start; padding: 16px; }
.typing i { width: 7px; height: 7px; border-radius: 4px; background: var(--ink3); animation: blink 1.2s ease-in-out infinite; }
.typing i:nth-child(2) { animation-delay: .15s; } .typing i:nth-child(3) { animation-delay: .3s; }
@keyframes blink { 0%, 60%, 100% { transform: none; opacity: .5; } 30% { transform: translateY(-4px); opacity: 1; } }
@media (max-width: 480px) { .chat { height: 400px; } .bub { font-size: 15px; } }

/* Progress */
.wrow { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin-bottom: 10px; }
.wbig { font-size: 40px; font-weight: 800; letter-spacing: -1.4px; font-variant-numeric: tabular-nums; line-height: 1; }
.wbig small { font-size: 18px; font-weight: 600; letter-spacing: 0; }
.legend { display: flex; align-items: center; gap: 7px; font-size: 13px; color: var(--ink2); margin-top: 6px; }
.legend i { width: 8px; height: 8px; border-radius: 4px; background: var(--dose); }
.duo { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.stat .metric { font-size: 30px; font-weight: 800; letter-spacing: -1px; margin: 6px 0 2px; font-variant-numeric: tabular-nums; }
.stat small { color: var(--ink2); font-size: 13px; }

/* Bento */
.bento { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.bento > div { background: var(--surface); border-radius: 26px; padding: 26px; transition: opacity .7s ease, transform .7s cubic-bezier(.2,.7,.2,1), box-shadow .25s ease; transition-delay: var(--rd, 0s), var(--rd, 0s), 0s; }
.bento > div.in:hover { transform: translateY(-4px); box-shadow: var(--shadow); transition-delay: 0s; }
.bento span { width: 44px; height: 44px; border-radius: 22px; display: grid; place-items: center; }
.bento h3 { margin: 16px 0 6px; font-size: 19px; letter-spacing: -.3px; }
.bento p { margin: 0; color: var(--ink2); font-size: 16px; }
@media (max-width: 860px) { .bento { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .bento { grid-template-columns: 1fr; } .bento > div { padding: 22px; } }

/* Sticky mobile CTA */
.sticky-cta { display: none; }
@media (max-width: 760px) {
  .sticky-cta { display: block; position: fixed; left: 0; right: 0; bottom: 0; z-index: 9; padding: 12px 16px calc(12px + env(safe-area-inset-bottom)); background: color-mix(in srgb, var(--bg) 85%, transparent); backdrop-filter: blur(18px); -webkit-backdrop-filter: blur(18px); transform: translateY(110%); transition: transform .35s cubic-bezier(.2,.7,.2,1); }
  .sticky-cta.show { transform: none; }
  .sticky-cta .btn { width: 100%; }
}
