/* ============================================================
   styles.css — FrostBalance v2. Две сцены (§9):
   • СВЕТЛАЯ морозная оболочка — везде.
   • ТЁМНЫЙ таймер — только экран фокуса (#screen-workout).
   Сцены фиксированы, НЕ инвертируются под системный режим.
   Жёсткие НЕТ: декоративные градиенты, glassmorphism на карточках в покое,
   свечение/неон, эмодзи, #007AFF, Inter, вращающиеся снежинки/спиннеры.
   Стекло — ТОЛЬКО на хроме (таб-бар, шторки).
   ============================================================ */
@import url('https://fonts.googleapis.com/css2?family=Golos+Text:wght@400;500&display=swap');

:root {
  /* светлая оболочка (§9) */
  --bg: #ECF2F5; --surface: #FFFFFF; --surface-2: #F4F8FA;
  --border: #DBE6EB; --border-soft: #E3EBEF; --border-strong: #C9D9E1;
  --text: #17252F; --text-2: #5E7480; --text-3: #9AADB7;
  --cold: #2F7EA3; --cold-press: #276A8A; --cold-soft: #E7F1F6; --cold-border: #D3E5EE;
  --warm: #CF8741; --warm-soft: #F8EFE2; --warm-border: #F0E0CC;
  --danger: #B5524A;
  --glass: rgba(236,242,245,.72); --glass-line: rgba(23,37,47,.08);
  --shadow: 0 1px 2px rgba(23,37,47,.04), 0 10px 28px rgba(23,37,47,.07);
  --shadow-sm: 0 1px 2px rgba(23,37,47,.05);

  --radius: 20px; --radius-sm: 14px; --radius-pill: 999px;
  --font: 'Golos Text', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --ease: cubic-bezier(.4, 0, .2, 1); --dur: 240ms; --maxw: 440px;
}

/* тёмная сцена — таймер и настрой дыхания (§9) */
#screen-workout, #screen-breath {
  --t-bg: #0E1A22; --t-bg-deep: #070F15; --t-surface: #182832; --t-line: rgba(255,255,255,.08);
  --t-text: #EAF1F5; --t-text-2: #93A7B3; --t-text-3: #5E727E;
  --t-cold: #6FA6C6; --t-warm: #E0A35C; --t-track: rgba(255,255,255,.10);
}
#screen-breath { background: var(--t-bg-deep); color: var(--t-text); }
.breath-label { font-size: 30px; font-weight: 500; letter-spacing: .04em; color: var(--t-text); }
/* §A v6 — счётчик отсчёта дыхания + кольцо-таймер (вдох расширяет, выдох сужает) */
.breath-count { font-size: 34px; font-weight: 500; line-height: 1.15; color: var(--t-text-2); margin-top: 4px; }
#screen-breath .ring { transform: scale(var(--breath-scale, 0.6)); transform-origin: 50% 50%; transition: transform 80ms linear; }
#screen-breath .wk-top .icon-btn { color: var(--t-text-2); }

* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }

/* §11.1 каркас без overscroll: статичная оболочка, ОДНА зона скролла */
html, body {
  height: 100%; margin: 0; padding: 0; overflow: hidden;
  position: fixed; width: 100%; overscroll-behavior: none; -webkit-overflow-scrolling: touch;
}
body {
  font-family: var(--font); font-weight: 400; color: var(--text); background: var(--bg);
  line-height: 1.5; -webkit-font-smoothing: antialiased;
}
.tnum { font-variant-numeric: tabular-nums; font-feature-settings: 'tnum' 1; }

#app {
  max-width: var(--maxw); margin: 0 auto; height: 100dvh; background: var(--bg);
  position: relative; display: flex; flex-direction: column; overflow: hidden;
}

/* экраны */
.screen { display: none; flex-direction: column; flex: 1 1 auto; min-height: 0; }
.screen.active { display: flex; animation: screen-in var(--dur) var(--ease); }
@keyframes screen-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

/* единственная зона скролла; шапка живёт внутри, таб-бар поверх (стекло) */
.scroll {
  flex: 1 1 auto; overflow-y: auto; overscroll-behavior: contain; -webkit-overflow-scrolling: touch;
  padding: calc(env(safe-area-inset-top, 0px) + 22px) 20px calc(96px + env(safe-area-inset-bottom, 0px));
}
.scroll.no-nav { padding-bottom: calc(28px + env(safe-area-inset-bottom, 0px)); }

/* типографика */
h1, h2, h3 { font-weight: 500; margin: 0; letter-spacing: -.01em; }
.eyebrow { font-size: 12px; letter-spacing: .12em; text-transform: uppercase; color: var(--text-3); font-weight: 500; }
.muted { color: var(--text-2); }
.muted-3 { color: var(--text-3); }

/* кнопки */
.btn {
  appearance: none; border: 0; cursor: pointer; font-family: inherit; font-weight: 500;
  font-size: 16px; border-radius: var(--radius-pill); padding: 16px 22px; width: 100%;
  transition: transform var(--dur) var(--ease), background var(--dur) var(--ease), opacity var(--dur) var(--ease);
}
.btn:active { transform: scale(.985); }
.btn-primary { background: var(--cold); color: #fff; }
.btn-primary:active { background: var(--cold-press); }
.btn-ghost { background: var(--surface); color: var(--text); border: 1px solid var(--border); }
.btn-warm { background: var(--warm); color: #fff; }
.btn[disabled] { opacity: .45; cursor: default; }

.icon-btn {
  appearance: none; border: 0; background: transparent; color: var(--text-2);
  width: 40px; height: 40px; border-radius: var(--radius-pill); cursor: pointer;
  display: inline-flex; align-items: center; justify-content: center;
  transition: background var(--dur) var(--ease), color var(--dur) var(--ease);
}
.icon-btn:active { background: var(--surface-2); color: var(--text); }
.ico { width: 22px; height: 22px; stroke: currentColor; stroke-width: 1.7; fill: none;
  stroke-linecap: round; stroke-linejoin: round; display: block; }

/* карточки */
.card { background: var(--surface); border: 1px solid var(--border-soft); border-radius: var(--radius); padding: 20px; }
.card + .card { margin-top: 14px; }

/* ============================================================
   СЕГОДНЯ
   ============================================================ */
.home-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 22px; }
.home-date { font-size: 13px; color: var(--text-3); }
.home-greet { font-size: 23px; font-weight: 500; margin-top: 2px; }

.recipe { box-shadow: var(--shadow); }
.recipe .stage-line { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.stage-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--cold); flex: 0 0 auto;
  animation: breathe-dot 5.5s var(--ease) infinite; }
.recipe .stage-name { font-size: 18px; font-weight: 500; }
.recipe .stage-no { color: var(--text-3); font-size: 13px; margin-left: auto; }
.recipe .how-line { color: var(--text-2); font-size: 14px; line-height: 1.45; margin-bottom: 16px; }

.phases { display: flex; gap: 10px; margin-bottom: 20px; }
.phase { flex: 1; background: var(--surface-2); border: 1px solid var(--border-soft);
  border-radius: var(--radius-sm); padding: 14px 12px; text-align: center; }
.phase .p-label { font-size: 12px; color: var(--text-3); letter-spacing: .04em; text-transform: uppercase; }
.phase .p-val { font-size: 26px; font-weight: 500; margin-top: 4px; }
.phase .p-unit { font-size: 13px; color: var(--text-2); }
.phase.warm .p-val { color: var(--warm); }
.phase.cold .p-val { color: var(--cold); }
.phase.cycles .p-val { color: var(--text); }

/* полоса «На этой неделе» */
.week { margin-top: 16px; }
.week-head { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 10px; }
.week-head .wk-title { font-size: 13px; color: var(--text-3); letter-spacing: .04em; text-transform: uppercase; }
.week-head .wk-count { font-size: 13px; color: var(--text-2); font-weight: 500; }
.week-row { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; }
.wk-cell { aspect-ratio: 1; border-radius: 12px; display: flex; flex-direction: column; align-items: center;
  justify-content: center; gap: 3px; background: var(--surface-2); }
.wk-cell .wd { font-size: 10px; color: var(--text-3); }
.wk-cell.done { background: var(--cold); color: #fff; }
.wk-cell.done .wd { color: #fff; }
.wk-cell.rest { background: var(--warm-soft); }
.wk-cell.rest .wd { color: var(--warm); }
.wk-cell.today { background: var(--surface); border: 2px solid var(--cold); }
.wk-cell.today .wd { color: var(--cold); font-weight: 500; }
.wk-cell.ahead { background: var(--surface-2); }
.wk-cell.ahead .wd { color: var(--text-3); }

/* статы */
.home-foot { display: flex; gap: 12px; margin-top: 16px; }
.stat { flex: 1; background: var(--surface); border: 1px solid var(--border-soft); border-radius: var(--radius); padding: 16px; }
.stat.clickable { cursor: pointer; transition: border-color var(--dur) var(--ease); }
.stat.clickable:active { border-color: var(--border-strong); }
.stat .s-top { display: flex; align-items: center; gap: 7px; }
.stat .s-label { font-size: 12px; color: var(--text-3); letter-spacing: .04em; }
.stat .s-val { font-size: 30px; font-weight: 500; margin-top: 4px; }
.stat .s-sub { font-size: 12px; color: var(--text-3); }

/* ориентир до следующего этапа */
.horizon { margin-top: 16px; background: var(--cold-soft); border: 1px solid var(--cold-border);
  border-radius: var(--radius); padding: 14px 16px; }
.horizon .hz-text { font-size: 13px; color: var(--cold-press); margin-bottom: 9px; }
.horizon .hz-bar { height: 6px; border-radius: 3px; background: #fff; overflow: hidden; }
.horizon .hz-bar > span { display: block; height: 100%; background: var(--cold); transition: width 500ms var(--ease); }

/* сигнатура: дышащая точка */
.breath-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--cold); flex: 0 0 auto;
  animation: breathe-dot 5.5s var(--ease) infinite; }
@keyframes breathe-dot { 0%,100% { transform: scale(.7); opacity: .5; } 50% { transform: scale(1); opacity: 1; } }

/* «сделано» / «восстановление» */
.today-note { text-align: center; padding: 28px 8px; }
.today-note .tn-mark { width: 56px; height: 56px; margin: 0 auto 16px; border-radius: 50%;
  border: 1.5px solid var(--cold); display: flex; align-items: center; justify-content: center; color: var(--cold); }
.today-note .tn-mark.done { border-color: var(--cold); color: var(--cold); }
.today-note .tn-mark.rest { border-color: var(--warm-border); color: var(--warm); }
.today-note h3 { font-size: 20px; margin-bottom: 8px; }
.today-note p { color: var(--text-2); margin: 0 auto; max-width: 300px; }

.soft-badge { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; color: var(--cold-press);
  background: var(--cold-soft); border: 1px solid var(--cold-border); border-radius: var(--radius-pill); padding: 6px 12px; margin-bottom: 14px; }

/* баннер «незавершённая практика» */
.resume-banner { display: flex; align-items: center; gap: 12px; background: var(--cold-soft); border: 1px solid var(--cold-border);
  border-radius: var(--radius); padding: 14px 14px 14px 16px; margin-bottom: 16px; }
.resume-banner .rb-text { flex: 1; min-width: 0; }
.resume-banner .rb-title { font-size: 14px; font-weight: 500; color: var(--text); }
.resume-banner .rb-sub { font-size: 12px; color: var(--text-2); margin-top: 1px; }
.resume-banner .rb-go { appearance: none; border: 0; cursor: pointer; font-family: inherit; font-weight: 500; font-size: 14px;
  background: var(--cold); color: #fff; border-radius: var(--radius-pill); padding: 9px 16px; flex: 0 0 auto; }
.resume-banner .rb-x { appearance: none; border: 0; background: transparent; color: var(--text-3); cursor: pointer;
  width: 34px; height: 34px; display: flex; align-items: center; justify-content: center; flex: 0 0 auto; border-radius: 50%; }
.resume-banner .rb-x .ico { width: 18px; height: 18px; }

/* ============================================================
   ТАЙМЕР — тёмная сцена фокуса
   ============================================================ */
#screen-workout { background: var(--t-bg-deep); color: var(--t-text); }
.wk-top { display: flex; align-items: center; justify-content: space-between;
  padding: calc(env(safe-area-inset-top, 0px) + 14px) 18px 8px; }
.wk-top .icon-btn { color: var(--t-text-2); }
.wk-top .icon-btn:active { background: var(--t-surface); color: var(--t-text); }
.wk-cycle { font-size: 13px; color: var(--t-text-2); letter-spacing: .04em; }
.wk-stage { font-size: 13px; color: var(--t-text-3); }

.wk-body { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 10px 20px; min-height: 0; }

.ring-wrap { position: relative; width: 280px; height: 280px; max-width: 72vw; max-height: 72vw; display: flex; align-items: center; justify-content: center; }
.ring { position: absolute; inset: 0; }
.ring circle { fill: none; stroke-width: 2; }
.ring .track { stroke: var(--t-track); }
.ring .breath { stroke: var(--t-cold); transform-origin: center; animation: breathe 5.5s var(--ease) infinite; }
.wk-phase-warm .ring .breath { stroke: var(--t-warm); }
.wk-phase-cold .ring .breath { stroke: var(--t-cold); }
@keyframes breathe { 0%,100% { transform: scale(.9); opacity: .55; } 50% { transform: scale(1); opacity: 1; } }

.timer-num { font-size: 76px; font-weight: 500; line-height: 1; letter-spacing: -.02em; color: var(--t-text); }
.timer-phase { font-size: 15px; letter-spacing: .08em; text-transform: uppercase; margin-top: 10px; color: var(--t-text-2); }
.wk-phase-warm .timer-phase { color: var(--t-warm); }
.wk-phase-cold .timer-phase { color: var(--t-cold); }

/* подсказка-проводник (§8.1) */
.wk-hint { min-height: 40px; max-width: 320px; margin: 18px auto 0; text-align: center;
  font-size: 15px; line-height: 1.4; color: var(--t-text-2); transition: opacity var(--dur) var(--ease); }

/* температурная ось */
.temp-axis { width: 100%; max-width: 300px; margin: 24px auto 0; }
.temp-track { position: relative; height: 4px; border-radius: 2px; overflow: hidden; display: flex; }
.temp-track .tz-warm { flex: 1; background: rgba(224,163,92,.28); }
.temp-track .tz-cold { flex: 1; background: rgba(111,166,198,.28); }
.temp-marker { position: absolute; top: 50%; width: 14px; height: 14px; border-radius: 50%;
  background: var(--t-text); transform: translate(-50%, -50%); transition: left 600ms var(--ease), background var(--dur) var(--ease); }
.wk-phase-warm .temp-marker { left: 25%; background: var(--t-warm); }
.wk-phase-cold .temp-marker { left: 75%; background: var(--t-cold); }
.temp-labels { display: flex; justify-content: space-between; margin-top: 10px; font-size: 12px; color: var(--t-text-3); }

.wk-foot { display: flex; gap: 12px; padding: 18px 20px calc(22px + env(safe-area-inset-bottom, 0px)); }
.wk-foot .btn { flex: 1; background: var(--t-surface); color: var(--t-text); border: 1px solid var(--t-line); }
.wk-foot .btn:active { background: #1f3340; }

/* ============================================================
   Матовый нижний таб-бар (§10) — стекло на хроме, контент уезжает под него
   ============================================================ */
.nav {
  position: absolute; left: 0; right: 0; bottom: 0; display: flex;
  background: var(--glass); backdrop-filter: blur(20px) saturate(1.1); -webkit-backdrop-filter: blur(20px) saturate(1.1);
  border-top: 1px solid var(--glass-line); padding-bottom: env(safe-area-inset-bottom, 0px);
}
.nav button {
  flex: 1; appearance: none; border: 0; background: transparent; cursor: pointer; font-family: inherit;
  color: var(--text-3); padding: 11px 0 12px; display: flex; flex-direction: column; align-items: center; gap: 4px;
  font-size: 11px; letter-spacing: .02em; transition: color var(--dur) var(--ease);
}
.nav button.active { color: var(--cold); }
.nav button .ico { width: 22px; height: 22px; }
.nav-hidden .nav { display: none; }

/* ============================================================
   Шторки (§10) — затемнённый размытый бэкдроп, скруглённый верх, хваталка
   ============================================================ */
.sheet-back { position: fixed; inset: 0; background: rgba(23,37,47,.32); backdrop-filter: blur(2px);
  display: none; align-items: flex-end; justify-content: center; z-index: 1500; }
.sheet-back.open { display: flex; animation: fade var(--dur) var(--ease); }
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
.sheet {
  width: 100%; max-width: var(--maxw); background: var(--surface);
  border-radius: 22px 22px 0 0; border-top: 1px solid var(--border-soft);
  padding: 12px 20px calc(24px + env(safe-area-inset-bottom, 0px)); box-shadow: 0 -16px 50px rgba(23,37,47,.14);
  animation: sheet-up var(--dur) var(--ease);
}
.sheet::before { content: ''; display: block; width: 38px; height: 4px; border-radius: 2px;
  background: var(--border-strong); margin: 0 auto 16px; }
@keyframes sheet-up { from { transform: translateY(20px); } to { transform: none; } }
.sheet h3 { font-size: 19px; margin-bottom: 4px; }
.sheet .sheet-sub { color: var(--text-2); font-size: 14px; margin-bottom: 18px; }

.brk-row { margin-bottom: 14px; }
.brk-row .brk-head { display: flex; justify-content: space-between; font-size: 14px; margin-bottom: 7px; }
.brk-row .brk-head .brk-name { color: var(--text-2); }
.brk-row .brk-head .brk-val { color: var(--text); font-weight: 500; }
.brk-bar { height: 6px; border-radius: 3px; background: var(--surface-2); overflow: hidden; }
.brk-bar > span { display: block; height: 100%; background: var(--cold-press); border-radius: 3px; transition: width 500ms var(--ease); }
.brk-bar.route > span { background: var(--cold); }
.brk-note { color: var(--text-3); font-size: 13px; margin-top: 12px; line-height: 1.5; }

/* ============================================================
   САМОЧУВСТВИЕ
   ============================================================ */
.feel-head h2 { font-size: 23px; }
.feel-head p { color: var(--text-2); margin: 7px 0 0; font-size: 14px; }
.feel-group { margin-top: 22px; }
.feel-q { font-size: 13px; color: var(--text-3); letter-spacing: .04em; margin-bottom: 10px; }
.feel-options { display: flex; gap: 10px; }
.feel-btn {
  flex: 1; appearance: none; cursor: pointer; font-family: inherit; font-weight: 500;
  background: var(--surface); color: var(--text-2); border: 1px solid var(--border); border-radius: var(--radius-sm);
  padding: 18px 8px; font-size: 15px; line-height: 1.2;
  transition: border-color var(--dur) var(--ease), color var(--dur) var(--ease), background var(--dur) var(--ease), transform var(--dur) var(--ease);
}
.feel-btn:active { transform: scale(.98); }
.feel-btn.sel { border-color: var(--cold); color: var(--cold-press); background: var(--cold-soft); }
.feel-save { margin-top: 30px; }

.correction { text-align: center; padding: 26px 6px 0; }
.corr-mark { width: 60px; height: 60px; margin: 0 auto 18px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center; border: 1.5px solid var(--cold); color: var(--cold); }
.corr-mark.warn { border-color: var(--warm-border); color: var(--warm); }
.corr-mark.neutral { border-color: var(--border-strong); color: var(--text-2); }
.correction h2 { font-size: 23px; margin-bottom: 9px; }
.corr-note { color: var(--text-2); max-width: 320px; margin: 0 auto 22px; line-height: 1.5; }
.corr-plan { background: var(--surface); border: 1px solid var(--border-soft); border-radius: var(--radius);
  padding: 16px 18px; display: flex; align-items: center; justify-content: center; gap: 10px; max-width: 320px; margin: 0 auto; }
.corr-plan .cp-label { color: var(--text-3); font-size: 13px; }
.corr-plan .cp-val { font-size: 21px; font-weight: 500; }
.corr-plan .cp-val.cold { color: var(--cold); }
.corr-plan .cp-val.warm { color: var(--warm); }
.warming { max-width: 340px; margin: 22px auto 0; background: var(--warm-soft); border: 1px solid var(--warm-border);
  border-radius: var(--radius); padding: 16px 18px; text-align: left; }
.warming-title { font-size: 14px; font-weight: 500; color: var(--warm); margin-bottom: 6px; }
.warming-text { font-size: 13px; color: var(--text-2); line-height: 1.5; }

/* ============================================================
   МАРШРУТ — вертикальная тропа (§7.7)
   ============================================================ */
.screen-title { margin-bottom: 20px; }
.screen-title h1 { font-size: 24px; }
.screen-title p { margin: 6px 0 0; font-size: 14px; }

.trail { position: relative; padding-left: 4px; }
.trail::before { content: ''; position: absolute; left: 20px; top: 18px; bottom: 18px; width: 2px;
  background: var(--border); border-radius: 1px; }
.node { position: relative; display: flex; gap: 16px; padding: 6px 0 18px; }
.node:last-child { padding-bottom: 0; }
.node-dot { position: relative; z-index: 1; flex: 0 0 auto; width: 38px; height: 38px; border-radius: 50%;
  background: var(--bg); border: 2px solid var(--border-strong); display: flex; align-items: center; justify-content: center;
  font-weight: 500; font-size: 15px; color: var(--text-3); font-variant-numeric: tabular-nums; }
.node.done .node-dot { background: var(--cold); border-color: var(--cold); color: #fff; }
.node.current .node-dot { background: var(--surface); border-color: var(--cold); color: var(--cold); box-shadow: 0 0 0 5px var(--cold-soft); }
.node-body { flex: 1; min-width: 0; background: var(--surface); border: 1px solid var(--border-soft);
  border-radius: var(--radius); padding: 16px; margin-top: -2px; }
.node.current .node-body { border-color: var(--cold-border); box-shadow: var(--shadow-sm); }
.node.locked { opacity: .82; }
.nb-name { font-size: 16px; font-weight: 500; display: flex; align-items: center; gap: 8px; }
.nb-season { font-size: 11px; font-weight: 500; color: var(--cold-press); background: var(--cold-soft);
  border-radius: var(--radius-pill); padding: 3px 9px; }
.nb-meta { font-size: 12px; color: var(--text-3); margin-top: 3px; }
.nb-essence { font-size: 12px; color: var(--text-3); margin-top: 4px; line-height: 1.4; }
.nb-status { font-size: 13px; margin-top: 9px; color: var(--text-2); line-height: 1.45; }
.nb-status.warn { color: var(--cold-press); }
.nb-status.ready { color: var(--warm); }
.nb-gates { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 11px; }
.gate { font-size: 12px; padding: 4px 10px 4px 8px; border-radius: var(--radius-pill); border: 1px solid var(--border);
  color: var(--text-3); display: inline-flex; align-items: center; gap: 5px; }
.gate.ok { color: var(--cold-press); border-color: var(--cold-border); background: var(--cold-soft); }
.gate .ico { width: 13px; height: 13px; }
.nb-progress { height: 6px; border-radius: 3px; background: var(--surface-2); overflow: hidden; margin-top: 11px; }
.nb-progress > span { display: block; height: 100%; background: var(--cold); transition: width 500ms var(--ease); }
.nb-rules { margin-top: 11px; font-size: 12px; color: var(--text-3); line-height: 1.5; }
.nb-rules b { color: var(--text-2); font-weight: 500; }
.nb-cta { margin-top: 13px; }
.nb-cta .btn { padding: 12px 18px; font-size: 15px; }

/* §C v5 — Путь: фраза поддержки + карточка превращения А→Я + контраст «День 1 → сейчас» */
.path-support { background: var(--warm-soft); border: 1px solid var(--warm-border); color: var(--text, #17252F);
  border-radius: var(--radius); padding: 12px 14px; font-size: 13px; line-height: 1.45; margin-bottom: 16px; }
.transform-card { display: flex; align-items: stretch; gap: 10px; background: var(--surface); border: 1px solid var(--border-soft);
  border-radius: 16px; padding: 16px 12px; margin-bottom: 12px; box-shadow: var(--shadow-sm); }
.transform-card .tc-side { flex: 1; min-width: 0; text-align: center; display: flex; flex-direction: column; justify-content: center; gap: 6px; }
.transform-card .tc-num { font-size: 18px; font-weight: 500; color: var(--text, #17252F); line-height: 1.15; }
.transform-card .tc-num .tc-unit { font-size: 13px; color: var(--text-2); font-weight: 400; }
.transform-card .tc-side.start .tc-num { color: var(--text-2); }
.transform-card .tc-side.goal .tc-num { color: var(--cold-press); }
.transform-card .tc-cap { font-size: 11px; color: var(--text-3); line-height: 1.35; }
.transform-card .tc-arrow { flex: 0 0 auto; display: flex; align-items: center; color: var(--cold); }
.transform-card .tc-arrow .ico { width: 22px; height: 22px; }
.contrast-line { font-size: 13px; color: var(--text-2); line-height: 1.5; text-align: center; margin: 2px 4px 18px; }
.contrast-line b { color: var(--cold-press); font-weight: 500; }
/* §B2 v7 — ориентир по температуре воды в рецепте */
.recipe-temp { display: flex; align-items: center; gap: 7px; font-size: 13px; color: var(--cold-press); margin-top: 8px; line-height: 1.4; }
.recipe-temp .ico { width: 15px; height: 15px; flex: 0 0 auto; color: var(--cold); }
/* §B3 v7 — мягкая заметка возврата после перерыва */
.resume-soft { background: var(--cold-soft); border: 1px solid var(--cold-border); color: var(--cold-press); border-radius: var(--radius); padding: 12px 14px; font-size: 13px; line-height: 1.45; margin-bottom: 14px; }

/* §review — видимая прогрессия: ступени этапа + стаж к проруби */
.stage-prog { margin-top: 18px; }
.stage-prog .sp-head { display: flex; justify-content: space-between; align-items: baseline; gap: 10px; font-size: 13px; margin-bottom: 8px; }
.stage-prog .sp-name { color: var(--text-2); font-weight: 500; flex: 0 0 auto; }
.stage-prog .sp-tier { color: var(--cold-press); text-align: right; }
.stage-prog .sp-bar { height: 8px; border-radius: 4px; background: var(--surface-2); overflow: hidden; }
.stage-prog .sp-bar > span { display: block; height: 100%; background: var(--cold); transition: width 500ms var(--ease); }
.nb-progress.exp > span { background: var(--warm); }
/* §D v6 — крючок «что завтра» */
.tomorrow-hook { display: flex; align-items: center; gap: 9px; width: 100%; text-align: left; margin: 18px auto 0; max-width: 360px; box-sizing: border-box;
  background: var(--cold-soft); border: 1px solid var(--cold-border); border-radius: var(--radius); padding: 12px 14px; font-family: inherit; }
button.tomorrow-hook { cursor: pointer; }
button.tomorrow-hook:active { background: var(--surface-2); }
.tomorrow-hook .th-label { flex: 0 0 auto; font-size: 10px; font-weight: 600; color: var(--cold-press); text-transform: uppercase; letter-spacing: .05em; }
.tomorrow-hook .th-text { flex: 1; font-size: 14px; color: var(--text-2); line-height: 1.4; }
.tomorrow-hook .ico { flex: 0 0 auto; width: 16px; height: 16px; color: var(--cold); }
/* §E2 v6 — узел 6 как вершина пути */
.node.summit { opacity: 1; }
.node.summit .node-dot { background: var(--warm); border-color: var(--warm); color: #fff; box-shadow: 0 0 0 5px var(--warm-soft); }
.node.summit .node-body { border-color: var(--warm-border); background: var(--warm-soft); }
.nb-summit { font-size: 12px; font-weight: 600; color: var(--warm); margin-top: 4px; }
/* текущий узел дышит (спокойный пульс, без геймификации) */
@keyframes nodePulse { 0%, 100% { box-shadow: 0 0 0 4px var(--cold-soft); } 50% { box-shadow: 0 0 0 8px var(--cold-soft); } }
.node.current .node-dot { animation: nodePulse 2.6s var(--ease) infinite; }

/* §D v5 — Гид: список тем + читалка (светлая тема) */
.guide-list { display: flex; flex-direction: column; gap: 10px; }
.guide-row { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; background: var(--surface);
  border: 1px solid var(--border-soft); border-radius: 14px; padding: 16px; cursor: pointer; font-family: inherit; }
.guide-row:active { background: var(--surface-2); }
.guide-row .gr-text { flex: 1; min-width: 0; display: block; }
.guide-row .gr-title { font-size: 16px; font-weight: 500; color: var(--text, #17252F); display: block; }
.guide-row .gr-teaser { font-size: 13px; color: var(--text-3); margin-top: 3px; line-height: 1.4; display: block; }
.guide-row .ico { flex: 0 0 auto; width: 20px; height: 20px; color: var(--text-3); }
.guide-foot { font-size: 12px; color: var(--text-3); line-height: 1.5; margin-top: 18px; text-align: center; }
.art-back { display: inline-flex; align-items: center; gap: 4px; background: none; border: 0; cursor: pointer; font-family: inherit;
  color: var(--cold-press); font-size: 14px; padding: 4px 0; margin-bottom: 10px; }
.art-back .ico { width: 18px; height: 18px; }
.guide-article h2 { font-size: 23px; font-weight: 500; line-height: 1.22; margin-bottom: 14px; }
.guide-article h3 { font-size: 16px; font-weight: 500; margin: 22px 0 8px; color: var(--text, #17252F); }
.guide-article p { font-size: 15px; line-height: 1.6; color: var(--text-2); margin-bottom: 12px; }
.guide-article ul { margin: 2px 0 14px; padding-left: 20px; }
.guide-article li { font-size: 15px; line-height: 1.55; color: var(--text-2); margin-bottom: 6px; }
.art-warn { background: var(--warm-soft); border: 1px solid var(--warm-border); border-radius: 12px; padding: 12px 14px;
  font-size: 14px; line-height: 1.5; color: var(--text, #17252F); margin: 8px 0 16px; font-weight: 500; }
.art-sources { margin-top: 24px; padding-top: 14px; border-top: 1px solid var(--border-soft); }
.art-sources .as-title { font-size: 12px; color: var(--text-3); letter-spacing: .03em; margin-bottom: 7px; text-transform: uppercase; }
.art-sources .as-item { font-size: 13px; color: var(--text-3); line-height: 1.55; }
.art-disc { margin-top: 18px; font-size: 12px; color: var(--text-3); line-height: 1.5; font-style: italic; }
.nb-guide { display: inline-flex; align-items: center; gap: 2px; background: none; border: 0; cursor: pointer; font-family: inherit;
  color: var(--cold-press); font-size: 13px; padding: 0; margin-top: 11px; font-weight: 500; }
.nb-guide .ico { width: 15px; height: 15px; }

/* §E/§F/§G v5 — дневник-заметка, рекап календаря, фразы поддержки */
.feel-note { margin: 8px 0 6px; }
.feel-note label { display: block; font-size: 14px; color: var(--text-2); margin-bottom: 8px; }
.feel-note .fn-opt { color: var(--text-3); font-size: 12px; }
.feel-note textarea { width: 100%; box-sizing: border-box; resize: none; font-family: inherit; font-size: 15px; line-height: 1.5;
  color: var(--text, #17252F); background: var(--surface); border: 1px solid var(--border-soft); border-radius: 12px; padding: 12px 14px; }
.feel-note textarea::placeholder { color: var(--text-3); }
.feel-note textarea:focus { outline: none; border-color: var(--cold-border); }
.corr-support { font-size: 14px; color: var(--cold-press); line-height: 1.5; margin: 6px auto 2px; max-width: 320px; }
.day-note { margin-top: 12px; font-size: 14px; line-height: 1.5; color: var(--text-2); font-style: italic; }
.day1-note { font-size: 13px; color: var(--text-2); font-style: italic; line-height: 1.5; text-align: center; margin: 0 4px 18px; }
.cal-recap { margin-top: 18px; display: flex; flex-direction: column; gap: 8px; }
.cal-recap .cr-month { font-size: 14px; font-weight: 500; color: var(--text, #17252F); text-align: center; }
.cal-recap .cr-contrast { font-size: 13px; color: var(--text-2); line-height: 1.5; text-align: center; background: var(--cold-soft);
  border: 1px solid var(--cold-border); border-radius: 12px; padding: 11px 14px; }

/* ============================================================
   КАЛЕНДАРЬ
   ============================================================ */
.cal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 18px; }
.cal-title { font-size: 18px; font-weight: 500; text-transform: capitalize; }
.cal-weekdays { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; margin-bottom: 8px; }
.cal-weekdays span { text-align: center; font-size: 11px; color: var(--text-3); letter-spacing: .02em; }
.cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; }
.cal-cell { aspect-ratio: 1; border-radius: 10px; display: flex; align-items: center; justify-content: center;
  position: relative; font-size: 14px; color: var(--text-3); font-variant-numeric: tabular-nums; background: var(--surface-2); }
.cal-cell.blank { visibility: hidden; background: transparent; }
.cal-cell.today { outline: 2px solid var(--cold); outline-offset: -2px; color: var(--cold); font-weight: 500; }
.cal-cell.has { cursor: pointer; background: transparent; }
.cal-cell .cal-fill { position: absolute; inset: 3px; border-radius: 8px; background: var(--cold); z-index: 0; }
.cal-cell .cal-d { position: relative; z-index: 1; }
.cal-cell.has .cal-d { color: #fff; font-weight: 500; }
.cal-stats { display: flex; justify-content: space-around; margin-top: 24px; padding-top: 18px; border-top: 1px solid var(--border-soft); }
.cal-stat { text-align: center; }
.cal-stat .cs-val { font-size: 22px; font-weight: 500; }
.cal-stat .cs-label { font-size: 11px; color: var(--text-3); margin-top: 3px; letter-spacing: .03em; }

/* ============================================================
   ОНБОРДИНГ
   ============================================================ */
.onb-top { margin-bottom: 8px; }
.onb-progress { display: flex; gap: 7px; margin-bottom: 30px; }
.onb-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--border); transition: background var(--dur) var(--ease); }
.onb-dot.done { background: var(--cold-border); }
.onb-dot.on { background: var(--cold); }
.onb-step { position: relative; }
.onb-back { margin: 0 0 10px -8px; }
.onb-step h2 { font-size: 25px; margin-bottom: 6px; }
.onb-sub { color: var(--text-2); font-size: 14px; margin-bottom: 24px; }

.choice-list { display: flex; flex-direction: column; gap: 10px; }
.choice {
  appearance: none; cursor: pointer; font-family: inherit; text-align: left; width: 100%;
  background: var(--surface); color: var(--text); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 18px; font-size: 16px; font-weight: 500;
  transition: border-color var(--dur) var(--ease), background var(--dur) var(--ease), transform var(--dur) var(--ease);
}
.choice:active { transform: scale(.99); }
.choice.sel { border-color: var(--cold); background: var(--cold-soft); }
.choice .ch-sub { display: block; font-weight: 400; font-size: 13px; color: var(--text-3); margin-top: 3px; }

.health-item {
  display: flex; align-items: center; justify-content: space-between; gap: 12px; width: 100%;
  appearance: none; cursor: pointer; font-family: inherit; text-align: left;
  background: var(--surface); color: var(--text); border: 1px solid var(--border); border-radius: var(--radius-sm);
  padding: 16px; font-size: 15px; margin-bottom: 8px;
  transition: border-color var(--dur) var(--ease), background var(--dur) var(--ease);
}
.hi-check { width: 24px; height: 24px; border-radius: 7px; border: 1px solid var(--border-strong);
  display: flex; align-items: center; justify-content: center; color: transparent; flex: 0 0 auto;
  transition: background var(--dur) var(--ease), border-color var(--dur) var(--ease), color var(--dur) var(--ease); }
.hi-check .ico { width: 15px; height: 15px; }
.health-item.on { border-color: var(--cold-border); background: var(--cold-soft); }
.health-item.on .hi-check { background: var(--cold); border-color: var(--cold); color: #fff; }

.disc-body { color: var(--text-2); font-size: 15px; line-height: 1.6; }
.disc-body ul { list-style: none; padding: 0; margin: 0 0 8px; }
.disc-body li { position: relative; padding-left: 20px; margin-bottom: 15px; }
.disc-body li::before { content: ''; position: absolute; left: 2px; top: 9px; width: 6px; height: 6px; border-radius: 50%; background: var(--cold); }
.disc-body b { color: var(--text); font-weight: 500; }
.disc-body li.flag::before { background: var(--danger); }
.disc-body li.flag b { color: var(--danger); }

/* мини-инструкция «Как это работает» (§7.2) */
.howto { text-align: center; padding: 12px 6px 0; }
.howto .ht-art { width: 76px; height: 76px; margin: 0 auto 22px; border-radius: 50%;
  background: var(--cold-soft); border: 1px solid var(--cold-border); display: flex; align-items: center; justify-content: center; color: var(--cold); }
.howto .ht-art .breath-dot { width: 16px; height: 16px; }
.howto h2 { font-size: 24px; margin-bottom: 10px; }
.howto p { color: var(--text-2); max-width: 320px; margin: 0 auto; line-height: 1.5; }
.howto-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 30px; }
.btn-skip { appearance: none; border: 0; background: transparent; color: var(--text-3); font-family: inherit; font-size: 14px; cursor: pointer; padding: 6px 4px; }
.ht-art .ht-axis { position: relative; width: 46px; height: 4px; border-radius: 2px; display: flex; overflow: visible; }
.ht-art .ht-axis .tzw { flex: 1; background: var(--warm); opacity: .5; border-radius: 2px 0 0 2px; }
.ht-art .ht-axis .tzc { flex: 1; background: var(--cold); opacity: .5; border-radius: 0 2px 2px 0; }
.ht-art .ht-axis .ht-marker { position: absolute; top: 50%; left: 50%; width: 9px; height: 9px; border-radius: 50%; background: var(--cold); transform: translate(-50%, -50%); }
.ht-art .ht-week { display: flex; gap: 3px; align-items: flex-end; }
.ht-art .ht-week span { width: 7px; height: 15px; border-radius: 3px; background: var(--border-strong); }
.ht-art .ht-week span.on { background: var(--cold); }

/* ============================================================
   НАСТРОЙКИ
   ============================================================ */
.set-section { margin-top: 26px; }
.set-title { font-size: 12px; letter-spacing: .1em; text-transform: uppercase; color: var(--text-3); margin: 0 4px 10px; }
.set-list { background: var(--surface); border: 1px solid var(--border-soft); border-radius: var(--radius); overflow: hidden; }
.set-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 15px 16px; min-height: 56px; width: 100%; }
.set-row + .set-row { border-top: 1px solid var(--border-soft); }
.sr-label { font-size: 15px; }
.sr-sub { font-size: 12px; color: var(--text-3); margin-top: 2px; }
button.set-link { appearance: none; background: transparent; border: 0; font-family: inherit; color: var(--text); text-align: left; cursor: pointer; transition: background var(--dur) var(--ease); }
button.set-link:active { background: var(--surface-2); }
.set-link .ico { width: 20px; height: 20px; color: var(--text-3); flex: 0 0 auto; }
.set-row.danger .sr-label { color: var(--danger); }
.set-time { font-family: inherit; font-size: 15px; color: var(--text); background: var(--surface-2); border: 1px solid var(--border); border-radius: 10px; padding: 8px 10px; }
.set-foot { text-align: center; color: var(--text-3); font-size: 12px; margin-top: 28px; }

.switch { position: relative; width: 46px; height: 28px; flex: 0 0 auto; appearance: none; border: 0; background: transparent; cursor: pointer; padding: 0; }
.switch .track { position: absolute; inset: 0; background: var(--border); border-radius: var(--radius-pill); transition: background var(--dur) var(--ease); }
.switch .knob { position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: #fff;
  box-shadow: var(--shadow-sm); transition: transform var(--dur) var(--ease); }
.switch.on .track { background: var(--cold); }
.switch.on .knob { transform: translateX(18px); }

.toast { position: fixed; left: 50%; bottom: calc(96px + env(safe-area-inset-bottom, 0px)); transform: translateX(-50%) translateY(10px);
  background: var(--text); color: #fff; border-radius: var(--radius-pill); padding: 11px 18px; font-size: 14px;
  opacity: 0; pointer-events: none; transition: opacity var(--dur) var(--ease), transform var(--dur) var(--ease); z-index: 2500; max-width: 88%; text-align: center; }
.toast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ============================================================
   SPLASH (§7.1)
   ============================================================ */
#splash { position: fixed; inset: 0; z-index: 3000; background: var(--bg); display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 22px; transition: opacity 400ms var(--ease); }
#splash.hide { opacity: 0; pointer-events: none; }
#splash .splash-mark { width: 96px; height: 96px; border-radius: 22%; animation: crystal-grow 900ms var(--ease) both; }
@keyframes crystal-grow { from { transform: scale(.45); opacity: 0; } to { transform: scale(1); opacity: 1; } }
#splash .splash-word { width: 248px; max-width: 64vw; height: auto; }
#splash .splash-tag { color: var(--warm); font-size: 14px; letter-spacing: .01em; }

/* карточка достижения (§8.2) — превью в шторке */
.ach-preview { margin: 0 0 18px; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--border-soft); max-width: 280px; margin-left: auto; margin-right: auto; }
.ach-preview img { display: block; width: 100%; height: auto; }

/* сезонный баннер (§8.4) на «Сегодня» */
.season-banner { display: flex; align-items: center; gap: 12px; background: var(--warm-soft); border: 1px solid var(--warm-border);
  border-radius: var(--radius); padding: 14px 14px 14px 16px; margin-bottom: 16px; }
.season-banner .sb-text { flex: 1; min-width: 0; }
.season-banner .sb-title { font-size: 14px; font-weight: 500; color: var(--text); }
.season-banner .sb-sub { font-size: 12px; color: var(--text-2); margin-top: 1px; }
.season-banner .sb-go { appearance: none; border: 0; cursor: pointer; font-family: inherit; font-weight: 500; font-size: 14px;
  background: var(--warm); color: #fff; border-radius: var(--radius-pill); padding: 9px 16px; flex: 0 0 auto; }

/* гейт доступа (оплата) */
.gate-wrap { max-width: 360px; margin: 0 auto; text-align: center; padding: 44px 8px 0; }
.gate-mark { width: 72px; height: 72px; border-radius: 22%; margin: 0 auto 22px; display: block; }
.gate-wrap h2 { font-size: 24px; margin-bottom: 10px; }
.gate-wrap p { color: var(--text-2); line-height: 1.5; margin: 0 0 26px; }
.gate-wrap .btn { margin-bottom: 10px; }
.gate-wrap a.btn { display: block; text-decoration: none; }

/* оверлей оплаты */
.pay-overlay { position: fixed; inset: 0; background: rgba(23,37,47,.5); backdrop-filter: blur(4px);
  display: none; align-items: center; justify-content: center; padding: 20px; z-index: 2200; }
.pay-overlay.open { display: flex; }
.pay-card { background: var(--surface); border-radius: 22px; padding: 30px 26px; max-width: 380px; width: 100%; text-align: center; box-shadow: 0 30px 80px rgba(13,27,42,.25); }
.pay-card h3 { font-size: 20px; margin: 14px 0 8px; }
.pay-card p { color: var(--text-2); line-height: 1.5; margin: 0 0 16px; font-size: 14px; }
.pay-spinner { width: 44px; height: 44px; margin: 0 auto; border: 3px solid var(--border); border-top-color: var(--cold); border-radius: 50%; animation: paySpin .9s linear infinite; }
@keyframes paySpin { to { transform: rotate(360deg); } }
.pay-actions { display: flex; gap: 10px; justify-content: center; }
.pay-actions .btn { flex: 1; }

.placeholder { padding: 60px 24px; text-align: center; color: var(--text-3); }
.placeholder h2 { color: var(--text-2); font-weight: 500; margin-bottom: 8px; }
