:root{--text:#3b3a40;--text-muted:#6d6a75;--text-h:#16151a;--bg:#f6f4f0;--card:#fff;--border:#e6e2dc;--accent:#1f6f8b;--accent-soft:#e3f0f4;--accent-text:#fff;--caution:#a8620a;--caution-soft:#fbf0e0;--good:#2c7a3f;--good-soft:#e5f3e8;--danger:#b3261e;--shadow:0 1px 2px #16151a0a, 0 4px 16px #16151a0f;--sans:system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;font:16px/1.5 var(--sans);--lightningcss-light:initial;--lightningcss-dark: ;color-scheme:light dark;color:var(--text);background:var(--bg);-webkit-font-smoothing:antialiased;-webkit-text-size-adjust:100%}@media (prefers-color-scheme:dark){:root{--lightningcss-light: ;--lightningcss-dark:initial;--text:#d8d5de;--text-muted:#a09ca8;--text-h:#f4f3f6;--bg:#121317;--card:#1c1d23;--border:#2c2e37;--accent:#5fb3d0;--accent-soft:#17313b;--accent-text:#081a21;--caution:#f0b35a;--caution-soft:#33260f;--good:#7fd18f;--good-soft:#15301c;--danger:#f28b82;--shadow:none}}body{background:var(--bg);margin:0}h1,h2,h3{color:var(--text-h);margin:0;line-height:1.2}h1{letter-spacing:-.01em;font-size:1.75rem}h2{font-size:1.15rem}h3{font-size:1rem}p{margin:0}.app{max-width:560px;padding:max(20px, env(safe-area-inset-top)) 16px calc(24px + env(safe-area-inset-bottom));flex-direction:column;gap:16px;margin:0 auto;display:flex}.app.with-tabs{padding-bottom:calc(96px + env(safe-area-inset-bottom))}.stack{flex-direction:column;gap:12px;display:flex}.stack.tight{gap:6px}.row{flex-wrap:wrap;align-items:end;gap:12px;display:flex}.row>label{flex:140px}.card{background:var(--card);border:1px solid var(--border);box-shadow:var(--shadow);border-radius:16px;flex-direction:column;gap:10px;padding:16px;display:flex}label{color:var(--text-h);flex-direction:column;gap:4px;font-weight:600;display:flex}label small,.hint{color:var(--text-muted);font-size:.9rem;font-weight:400}input,select,textarea{font:inherit;color:var(--text-h);background:var(--card);border:1px solid var(--border);box-sizing:border-box;border-radius:10px;width:100%;min-height:44px;padding:10px 12px;font-weight:400}input:focus-visible,select:focus-visible,button:focus-visible,summary:focus-visible{outline:2px solid var(--accent);outline-offset:2px}fieldset{border:1px solid var(--border);border-radius:12px;flex-direction:column;gap:8px;margin:0;padding:12px;display:flex}fieldset.analyte{grid-template-columns:1fr 1fr 1fr;gap:8px;display:grid}fieldset.analyte label{font-size:.85rem;font-weight:400}legend{color:var(--text-h);padding:0 4px;font-weight:700}button{font:inherit;cursor:pointer;border:1px solid var(--border);background:var(--card);min-height:44px;color:var(--text-h);border-radius:12px;padding:8px 14px}button:disabled{opacity:.5;cursor:default}button.primary{background:var(--accent);color:var(--accent-text);border-color:#0000;font-weight:700}button.big-button{min-height:52px;font-size:1.05rem}button.ghost{color:var(--accent);background:0 0;border-color:#0000;font-weight:600}button.link{color:var(--accent);background:0 0;border:none;align-self:flex-start;min-height:0;padding:0;text-decoration:underline}details>summary{cursor:pointer;color:var(--accent);align-items:center;min-height:32px;font-weight:600;display:flex}details[open]>summary{margin-bottom:8px}.hero{text-align:center;flex-direction:column;align-items:center;gap:10px;padding:24px 0 8px;display:flex}.hero img{border-radius:16px}.lead{color:var(--text-h);font-size:1.1rem}.bullets{flex-direction:column;gap:6px;margin:0;padding-left:20px;display:flex}.step-count{color:var(--text-muted);text-transform:uppercase;letter-spacing:.04em;font-size:.85rem;font-weight:600}.choices{border:none;padding:0}.choices legend{padding:0 0 8px}label.choice{border:1px solid var(--border);background:var(--card);cursor:pointer;border-radius:12px;flex-direction:row;align-items:center;gap:12px;padding:12px 14px;font-weight:600}label.choice.selected{border-color:var(--accent);background:var(--accent-soft)}label.choice input{width:20px;height:20px;min-height:0;accent-color:var(--accent);flex:none}label.choice small{color:var(--text-muted);font-size:.85rem;font-weight:400;display:block}.segmented{grid-template-columns:repeat(3,1fr);gap:8px;display:grid}.segmented label.choice{justify-content:center;padding:10px}.nav-row{justify-content:space-between}.target-card{background:var(--card);border:1px solid var(--border);border-radius:14px;flex-direction:column;gap:6px;padding:14px;display:flex}.target-label{color:var(--text-muted);font-size:.85rem;font-weight:600}.target-value{color:var(--text-h);font-size:1.6rem;font-weight:800}.target-value.small{font-size:1.1rem}.greeting h1{font-size:1.6rem}.ring-row{align-items:center;gap:16px;display:flex}.ring-wrap{flex:none;width:116px;height:116px;position:relative}.ring{width:100%;height:100%}.ring circle{fill:none;stroke-width:12px}.ring-track{stroke:var(--accent-soft)}.ring-fill{stroke:var(--accent);stroke-linecap:round;transition:stroke-dashoffset .4s}.ring-center{flex-direction:column;justify-content:center;align-items:center;display:flex;position:absolute;inset:0}.ring-center strong{color:var(--text-h);font-size:1.4rem}.ring-center span{color:var(--text-muted);font-size:.8rem}.summary{color:var(--text-h);font-size:1.1rem;font-weight:700}.status{font-size:.95rem}.status.near-cutoff,.status.after-cutoff,.status.behind{color:var(--caution)}.status.done{color:var(--good)}.chips{scrollbar-width:none;gap:8px;padding-bottom:2px;display:flex;overflow-x:auto}.chip{border-radius:999px;flex:none;min-height:36px;padding:4px 14px;font-size:.9rem}.chip[aria-pressed=true]{background:var(--accent-soft);border-color:var(--accent);color:var(--text-h);font-weight:700}.drink-buttons{grid-template-columns:repeat(3,1fr);gap:8px;display:grid}.plan{flex-direction:column;gap:14px;margin:0;padding-left:22px;display:flex}.plan li{flex-direction:column;align-items:flex-start;gap:4px;display:flex}.plan li::marker{color:var(--accent);font-weight:800}.plan-title{color:var(--text-h);font-weight:700}.checks{grid-template-columns:1fr 1fr;gap:8px;display:grid}label.check{flex-direction:row;align-items:center;gap:8px;min-height:40px;font-weight:500}label.check input{width:22px;height:22px;min-height:0;accent-color:var(--accent);flex:none}.preview{background:var(--accent-soft);border-radius:12px;flex-direction:column;gap:8px;padding:12px;display:flex}.meal{border-top:1px solid var(--border);flex-direction:column;gap:6px;padding-top:12px;display:flex}.notes{flex-direction:column;gap:6px;margin:0;padding:0;list-style:none;display:flex}.note{border-left:3px solid var(--border);padding-left:10px}.note.caution{border-color:var(--caution)}.note.good{border-color:var(--good)}.tag{border:1px solid var(--border);color:var(--text-muted);white-space:nowrap;border-radius:999px;align-self:flex-start;padding:0 8px;font-size:.72rem;display:inline-block}.factor-head{justify-content:space-between;align-items:center;gap:8px;display:flex}.badge{background:var(--caution-soft);color:var(--caution);border-radius:999px;padding:2px 10px;font-size:.75rem;font-weight:700}.trends{flex-direction:column;gap:8px;margin:0;padding:0;list-style:none;display:flex}.trends li{grid-template-columns:1fr auto auto;align-items:center;gap:10px;font-size:.95rem;display:grid}.trend-name{color:var(--text-h);font-weight:600}.trend-dir{font-size:.85rem;font-weight:700}.trends li.better .trend-dir{color:var(--good)}.trends li.worse .trend-dir{color:var(--caution)}.trends li.same .trend-dir{color:var(--text-muted)}.errors{border:1px solid var(--danger);color:var(--danger);border-radius:10px;padding:8px 12px}.list{flex-direction:column;gap:8px;margin:0;padding:0;list-style:none;display:flex}.list li{border-bottom:1px solid var(--border);justify-content:space-between;align-items:center;gap:12px;padding-bottom:8px;display:flex}.tabbar{z-index:10;padding:6px 12px calc(6px + env(safe-area-inset-bottom));background:color-mix(in srgb, var(--card) 92%, transparent);-webkit-backdrop-filter:blur(12px);border-top:1px solid var(--border);justify-content:center;gap:4px;display:flex;position:fixed;bottom:0;left:0;right:0}.tabbar button{max-width:160px;color:var(--text-muted);background:0 0;border:none;flex-direction:column;flex:1;align-items:center;gap:2px;padding:6px 0;font-size:.75rem;font-weight:600;display:flex}.tabbar svg{fill:none;stroke:currentColor;stroke-width:1.8px;stroke-linecap:round;stroke-linejoin:round;width:24px;height:24px}.tabbar button[aria-current=page]{color:var(--accent)}
