/* Mini App «Замая Выручай × Меню от Замаи» — эталон владельца 2026-11-04 (content/brand/design): молочный фон, глубокий зелёный, золото листа только в логотипе, Manrope. */
:root {
  color-scheme: light;
  --ground: #F7F2E9; --card: #FFFDF8; --line: #EDE5D6; --ink: #1E2B22; --muted: #6B7268; --soft: #4B564D;
  --sage: #2F5D3A; --sage-dark: #244A2E; --sage-soft: #EEF3E6; --sage-mid: #4E7A57; --sage-ink: #D8E6CF; --leaf: #A9CF8E;
  --sand: #E9D3B5; --peach: #F6D9C9; --gold: #D2A64A;
  --warm: #2F5D3A; --warm-soft: #FBF1EA; --warm-line: #F0D2BF; --warm-ink: #8A4B22; --placeholder: #EFE7D8;
  --accent-text: #2F5D3A; --on-accent: #FFFFFF; --field: #FFFFFF; --nav: #FFFDF8; --label: #34403A; --strike: #8A8F86; --knob: #FFFFFF;
  --photo-shade: rgba(20, 40, 28, 0.78); --hero-glow: rgba(169, 207, 142, 0.35); --bar-track: rgba(255, 255, 255, 0.22); --overlay: rgba(30, 43, 34, 0.35);
  --shadow: 0 6px 20px rgba(47, 61, 42, 0.08); --shadow-btn: 0 6px 16px rgba(47, 93, 58, 0.25); --shadow-hero: 0 10px 26px rgba(36, 74, 46, 0.25);
  --shadow-nav: 0 -4px 18px rgba(47, 61, 42, 0.06); --shadow-plus: 0 6px 16px rgba(47, 93, 58, 0.35);
  /* «Замая Выручай» (Obsidian 27): тёмно-зелёная шапка, жёлтые главные кнопки и сердце логотипа */
  --head: #1C4A2A; --head-2: #2B6539; --on-head: #FFFFFF; --on-head-soft: rgba(255, 255, 255, 0.78); --head-chip: rgba(255, 255, 255, 0.16);
  --cta: #F6C532; --cta-dark: #E4AF19; --cta-ink: #1F2A1C; --heart: #F6C532; --shadow-cta: 0 6px 16px rgba(196, 146, 18, 0.35);
  /* Цветные значки строк, как в макете IMG_8285: питание, вода, активность, сладкое, вес */
  --t-food: #E4F2DA; --t-food-ink: #3E8A3A; --t-water: #E0EFFA; --t-water-ink: #2B7BC0; --t-move: #FDE9DA; --t-move-ink: #E0661B;
  --t-sweet: #FBE3E3; --t-sweet-ink: #D04848; --t-weight: #FFF3D1; --t-weight-ink: #B7860B;
}
/* Тёмная тема: глубокий изумруд вместо молока; зелёный текст светлеет, чтобы читаться на тёмном. */
:root[data-theme="dark"] {
  color-scheme: dark;
  --ground: #0E1F17; --card: #15291F; --line: #24402F; --ink: #EEF0E6; --muted: #A3B1A5; --soft: #C9D3C9;
  --sage: #3F7A4F; --sage-dark: #2F6140; --sage-soft: #1D3528; --sage-mid: #4F8C5F; --sage-ink: #CFE3C6; --leaf: #A9CF8E;
  --sand: #3A3122; --peach: #3B2A24; --gold: #D9B25A;
  --warm: #3F7A4F; --warm-soft: #33261C; --warm-line: #5A4030; --warm-ink: #F0B88E; --placeholder: #1C3327;
  --accent-text: #A9CF8E; --on-accent: #FFFFFF; --field: #10241A; --nav: #12261C; --label: #D5DDD3; --strike: #8F9A90; --knob: #EEF0E6;
  --photo-shade: rgba(6, 18, 12, 0.85); --hero-glow: rgba(169, 207, 142, 0.18); --bar-track: rgba(255, 255, 255, 0.18); --overlay: rgba(0, 0, 0, 0.55);
  --shadow: 0 6px 20px rgba(0, 0, 0, 0.35); --shadow-btn: 0 6px 16px rgba(0, 0, 0, 0.35); --shadow-hero: 0 10px 26px rgba(0, 0, 0, 0.4);
  --shadow-nav: 0 -4px 18px rgba(0, 0, 0, 0.35); --shadow-plus: 0 6px 16px rgba(0, 0, 0, 0.45);
  --head: #0F2F1D; --head-2: #1A4A2C; --on-head: #FFFFFF; --on-head-soft: rgba(255, 255, 255, 0.72); --head-chip: rgba(255, 255, 255, 0.12);
  --cta: #E8BB34; --cta-dark: #D1A220; --cta-ink: #1A1D12; --heart: #E8BB34; --shadow-cta: 0 6px 16px rgba(0, 0, 0, 0.4);
  --t-food: #1F3A24; --t-food-ink: #8FD07F; --t-water: #17324A; --t-water-ink: #7FC0F2; --t-move: #3E2718; --t-move-ink: #F6A06A;
  --t-sweet: #3D1F22; --t-sweet-ink: #F08A8A; --t-weight: #3A3115; --t-weight-ink: #E8BB34;
}
* { box-sizing: border-box; }
html, body { margin: 0; background: var(--ground); color: var(--ink); font-family: Manrope, system-ui, sans-serif; }
body { min-height: 100vh; }
.screen { display: none; flex-direction: column; gap: 16px; padding: 20px 16px 110px; max-width: 480px; margin: 0 auto; }
.screen.on { display: flex; }
h1 { margin: 0; font-size: 26px; font-weight: 800; line-height: 1.2; letter-spacing: -0.3px; }
p { margin: 0; line-height: 1.45; }
.muted { color: var(--muted); font-size: 13px; }
.lead { color: var(--soft); font-size: 15px; }

/* шапка: логотип платформы + продукт */
.brand { display: flex; align-items: center; gap: 10px; }
.brand svg { width: 34px; height: 34px; flex-shrink: 0; }
.brand b { display: block; font-size: 17px; font-weight: 800; color: var(--accent-text); line-height: 1.1; }
.brand span { display: block; font-size: 11px; color: var(--muted); }
.brand-hero { display: flex; flex-direction: column; align-items: center; text-align: center; gap: 6px; padding: 8px 0 4px; }
.brand-hero svg { width: 56px; height: 56px; }
.brand-hero b { font-size: 28px; font-weight: 800; color: var(--ink); line-height: 1.05; }
.brand-hero .tagline { color: var(--accent-text); font-weight: 600; font-size: 13px; letter-spacing: 0.4px; }

.card { background: var(--card); border: 1px solid var(--line); border-radius: 22px; padding: 18px; display: flex; flex-direction: column; gap: 6px; box-shadow: var(--shadow); }
.soft { background: var(--sage-soft); border-radius: 18px; padding: 14px; display: flex; flex-direction: column; gap: 4px; }
.warn { background: var(--warm-soft); border: 1px solid var(--warm-line); border-radius: 16px; padding: 12px 14px; display: flex; flex-direction: column; gap: 10px; }
.grid2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.grid3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.big { font-size: 52px; font-weight: 800; color: var(--accent-text); letter-spacing: -1px; }
.hero { position: relative; overflow: hidden; background: linear-gradient(135deg, var(--sage-mid), var(--sage-dark)); color: var(--on-accent);
  border-radius: 24px; padding: 20px; display: flex; flex-direction: column; gap: 10px; box-shadow: var(--shadow-hero); }
.hero::after { content: ""; position: absolute; right: -40px; top: -40px; width: 160px; height: 160px; border-radius: 50%;
  background: radial-gradient(circle, var(--hero-glow), transparent 70%); }
.hero .muted { color: var(--sage-ink); }
.hero .num { font-size: 42px; font-weight: 800; letter-spacing: -1px; }
.bar { height: 8px; border-radius: 4px; background: var(--bar-track); overflow: hidden; }
.bar > div { height: 8px; background: var(--leaf); border-radius: 4px; }
.row { display: flex; justify-content: space-between; align-items: center; gap: 10px; }

.btn { display: block; width: 100%; text-align: center; background: var(--sage); color: var(--on-accent); border: 0; font: inherit; font-weight: 700;
  font-size: 16px; padding: 16px; border-radius: 18px; min-height: 54px; cursor: pointer; text-decoration: none; box-shadow: var(--shadow-btn); }
.btn:active { background: var(--sage-dark); }
.btn.pay { background: var(--sage); font-weight: 800; font-size: 17px; }
.btn.ghost { background: var(--card); color: var(--accent-text); border: 1px solid var(--line); box-shadow: none; }
.btn.danger { background: none; color: var(--warm-ink); box-shadow: none; font-weight: 600; }
.meal { cursor: pointer; font: inherit; color: inherit; text-align: left; width: 100%; }
.btn.small { width: auto; font-size: 14px; padding: 0 16px; min-height: 44px; border-radius: 12px; box-shadow: none; }
.chip { font: inherit; font-size: 13px; color: var(--accent-text); background: var(--sage-soft); border: 0; border-radius: 12px; padding: 10px 12px; min-height: 44px; cursor: pointer; }
label { font-size: 14px; color: var(--label); }
input, select { font: inherit; font-size: 16px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 12px; min-height: 46px; width: 100%; background: var(--field); color: var(--ink); }
input:focus, select:focus { outline: 2px solid var(--leaf); outline-offset: 1px; }
.field { display: flex; flex-direction: column; gap: 6px; }
.inline { display: flex; gap: 8px; }
.inline input { flex-grow: 1; }
.error { color: var(--warm-ink); font-size: 14px; }

/* приём пищи: иконка в плашке + название + ккал */
.meal { flex-direction: row; align-items: center; gap: 12px; padding: 12px 14px; }
.meal .ico { width: 44px; height: 44px; border-radius: 14px; background: var(--peach); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.meal .ico svg { width: 22px; height: 22px; stroke: var(--sage); }
.meal .txt { flex-grow: 1; min-width: 0; }
.meal > b { white-space: nowrap; }
.meal .txt b { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.msgs { display: flex; flex-direction: column; gap: 10px; }
.me, .her { max-width: 86%; border-radius: 18px; padding: 10px 14px; font-size: 15px; line-height: 1.45; }
.me { align-self: flex-end; background: var(--sage); color: var(--on-accent); border-bottom-right-radius: 6px; }
.her { align-self: flex-start; background: var(--card); border: 1px solid var(--line); border-bottom-left-radius: 6px; }
.her.safe { background: var(--warm-soft); border-color: var(--warm-line); }
.price { display: flex; align-items: baseline; gap: 10px; }
.price b { font-size: 36px; font-weight: 800; letter-spacing: -1px; color: var(--accent-text); }
.price s { color: var(--strike); }
.check { display: flex; gap: 12px; align-items: center; font-size: 15px; }
.check i { width: 28px; height: 28px; border-radius: 50%; background: var(--sage); color: var(--on-accent); font-style: normal; font-size: 14px; font-weight: 800;
  display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.photo-box { height: 220px; border-radius: 24px; background: linear-gradient(135deg, var(--sand), var(--peach)); display: flex; align-items: center; justify-content: center;
  color: var(--soft); font-size: 14px; overflow: hidden; }
.photo-box img { width: 100%; height: 100%; object-fit: cover; }

/* нижняя панель «Замая Выручай»: 6 разделов как в макете (IMG_8285), без камеры — фото крупной кнопкой на Главной */
nav.tabs { position: fixed; left: 0; right: 0; bottom: 0; display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); align-items: end;
  background: var(--nav); border-top: 1px solid var(--line); padding: 6px 2px calc(8px + env(safe-area-inset-bottom)); box-shadow: var(--shadow-nav); }
nav.tabs button { font: inherit; font-size: 10.5px; color: var(--muted); background: none; border: 0; min-height: 52px; cursor: pointer; border-radius: 14px;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; padding: 4px 0; }
nav.tabs svg { width: 23px; height: 23px; stroke: currentColor; }
nav.tabs button[aria-current="page"] { color: var(--accent-text); font-weight: 800; background: var(--sage-soft); }
/* приветствие Замаи, кольцо нормы, помощник, профиль, переключатели */
.hero-photo { position: relative; min-height: 340px; border-radius: 28px; overflow: hidden; background: linear-gradient(160deg, var(--sage-mid), var(--sage-dark));
  display: flex; align-items: flex-end; box-shadow: var(--shadow-hero); }
.hero-photo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center 18%; }
.hero-photo::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 45%, var(--photo-shade) 100%); }
.hero-photo-text { position: relative; z-index: 1; padding: 22px; display: flex; flex-direction: column; gap: 6px; color: var(--on-accent); }
.hero-photo-text b { font-size: 34px; font-weight: 800; line-height: 1.05; letter-spacing: -0.5px; }
.avatar { width: 52px; height: 52px; border-radius: 50%; object-fit: cover; flex-shrink: 0; background: var(--sage-soft); }
.avatar.logo { display: flex; align-items: center; justify-content: center; }
.avatar.logo svg { width: 30px; height: 30px; }
.avatar.letter { display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 22px; color: var(--accent-text); }
.vera-says { flex-direction: row; gap: 12px; align-items: flex-start; }
.vera-says p { font-size: 14px; color: var(--soft); margin: 4px 0; }
.day { flex-direction: row; align-items: center; gap: 16px; }
.ring-box { position: relative; width: 124px; height: 124px; flex-shrink: 0; }
.ring-box svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.ring-track, .ring-fill { fill: none; stroke-width: 11; }
.ring-track { stroke: var(--sage-soft); }
.ring-fill { stroke: var(--sage); stroke-linecap: round; transition: stroke-dashoffset 0.6s ease; }
.ring-text { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; }
.ring-text b { font-size: 28px; font-weight: 800; color: var(--accent-text); line-height: 1; }
.ring-text span { font-size: 11px; color: var(--muted); }
.day-macros { display: flex; flex-direction: column; gap: 6px; flex-grow: 1; min-width: 0; }
.day-macros div { display: flex; justify-content: space-between; gap: 8px; font-size: 14px; }
.btn-ico { width: 20px; height: 20px; stroke: var(--on-accent); vertical-align: -4px; margin-right: 8px; }
.helper { flex-direction: row; align-items: center; gap: 12px; font: inherit; color: inherit; text-align: left; cursor: pointer; width: 100%; }
.helper > span { display: flex; flex-direction: column; gap: 2px; }
.profile-head { flex-direction: row; align-items: center; gap: 14px; }
.profile-head > div { display: flex; flex-direction: column; gap: 2px; }
.seg { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; gap: 4px; background: var(--sage-soft); border-radius: 14px; padding: 4px; }
.seg button { font: inherit; font-size: 13px; border: 0; background: none; color: var(--soft); border-radius: 10px; min-height: 40px; cursor: pointer; }
.seg button[aria-checked="true"], .seg button[aria-selected="true"] { background: var(--card); color: var(--accent-text); font-weight: 700; box-shadow: var(--shadow); }
@media (prefers-reduced-motion: reduce) { .ring-fill { transition: none; } }

/* меню, рецепт, «Готовим вместе» */
.row-link { flex-direction: row; align-items: center; justify-content: space-between; gap: 10px; font: inherit; color: inherit; text-align: left; cursor: pointer; width: 100%; }
.row-link > span:first-child { display: flex; flex-direction: column; gap: 2px; }
.chip.back { align-self: flex-start; background: var(--head); color: var(--on-head); font-weight: 700; border-radius: 14px; padding: 10px 14px; }
h2 { margin: 6px 0 0; font-size: 19px; font-weight: 800; }
.days { display: flex; gap: 6px; overflow-x: auto; padding-bottom: 4px; scrollbar-width: none; }
.days::-webkit-scrollbar { display: none; }
.days .chip { flex-shrink: 0; min-width: 58px; text-transform: capitalize; }
.days .chip.today { box-shadow: inset 0 0 0 1.5px var(--accent-text); }
.slot { flex-direction: row; align-items: center; gap: 10px; padding: 10px; }
.dish { display: flex; align-items: center; gap: 12px; flex-grow: 1; min-width: 0; font: inherit; color: inherit; text-align: left; background: none; border: 0; padding: 0; cursor: pointer; }
.dish img { width: 64px; height: 64px; border-radius: 14px; object-fit: cover; flex-shrink: 0; background: var(--placeholder); }
.dish-text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.recipe-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.recipe-card { display: flex; flex-direction: column; gap: 4px; text-align: left; font: inherit; color: inherit; cursor: pointer; background: var(--card);
  border: 1px solid var(--line); border-radius: 20px; padding: 8px 8px 12px; box-shadow: var(--shadow); }
.recipe-card img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 14px; background: var(--placeholder); }
.recipe-card b { font-size: 14px; line-height: 1.25; }
.recipe-cover img, .cook-media img, img.wide { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 24px; display: block; background: var(--placeholder); }
video.reel { width: 100%; aspect-ratio: 9 / 16; max-height: 70vh; object-fit: cover; border-radius: 24px; background: var(--placeholder); }
.grid4 { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.grid4 .soft { padding: 10px 8px; align-items: center; text-align: center; }
.cook-step { display: flex; flex-direction: column; gap: 14px; }
#cook-h { font-size: 22px; line-height: 1.3; }
.timer { flex-direction: row; align-items: center; justify-content: space-between; }
.timer b { font-size: 34px; font-weight: 800; font-variant-numeric: tabular-nums; color: var(--accent-text); }
.btn[disabled].ghost { opacity: 0.4; }

/* анкета: шаги, карточки-варианты, −/+, переключатели, чипы, «Считаем…» */
.wz, .wz-welcome { display: flex; flex-direction: column; gap: 16px; }
.dots { display: flex; gap: 6px; }
.dots i { flex: 1; height: 6px; border-radius: 3px; background: var(--line); }
.dots i.on { background: var(--sage); }
.opts { display: flex; flex-direction: column; gap: 10px; }
.opts.two { display: grid; grid-template-columns: 1fr 1fr; }
.opt { position: relative; display: flex; flex-direction: column; gap: 2px; text-align: left; font: inherit; color: inherit; cursor: pointer;
  background: var(--card); border: 1.5px solid var(--line); border-radius: 18px; padding: 16px 48px 16px 16px; min-height: 64px;
  box-shadow: var(--shadow); transition: border-color 0.2s, background 0.2s, transform 0.2s; }
.opt b { font-size: 16px; }
.opt[aria-pressed="true"] { border-color: var(--accent-text); background: var(--sage-soft); }
.opt[aria-pressed="true"]::after { content: "✓"; position: absolute; right: 14px; top: 50%; transform: translateY(-50%); width: 26px; height: 26px;
  border-radius: 50%; background: var(--sage); color: var(--on-accent); font-weight: 800; display: flex; align-items: center; justify-content: center; }
.opt:active { transform: scale(0.98); }
.stepper { display: flex; align-items: center; justify-content: center; gap: 14px; padding: 18px 0; }
.round { width: 52px; height: 52px; border-radius: 50%; border: 0; background: var(--sage-soft); color: var(--accent-text); font: inherit; font-size: 26px; font-weight: 700; cursor: pointer; }
.num-box { display: flex; align-items: baseline; gap: 6px; background: var(--card); border: 1px solid var(--line); border-radius: 20px; padding: 8px 16px; box-shadow: var(--shadow); }
.num-box input { width: 110px; border: 0; padding: 0; min-height: 0; text-align: center; font-size: 40px; font-weight: 800; background: transparent; }
.num-box span { color: var(--muted); font-size: 16px; }
.switch { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); font-size: 15px; }
.switch:last-child { border-bottom: 0; }
.switch input { appearance: none; -webkit-appearance: none; width: 48px; height: 28px; min-height: 0; padding: 0; border-radius: 14px; border: 0;
  background: var(--line); position: relative; flex-shrink: 0; cursor: pointer; transition: background 0.2s; }
.switch input::after { content: ""; position: absolute; top: 3px; left: 3px; width: 22px; height: 22px; border-radius: 50%; background: var(--knob); transition: left 0.2s; }
.switch input:checked { background: var(--sage); }
.switch input:checked::after { left: 23px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip[aria-pressed="true"] { background: var(--sage); color: var(--on-accent); }
.wz-body { display: flex; flex-direction: column; gap: 12px; }
.wz-body.enter { animation: wz-in 0.25s ease-out; }
@keyframes wz-in { from { opacity: 0; transform: translateX(16px); } to { opacity: 1; transform: none; } }
.wz-calc { display: flex; flex-direction: column; align-items: center; gap: 18px; padding-top: 40px; text-align: center; }
.ring { width: 120px; height: 120px; border-radius: 50%; border: 8px solid var(--sage-soft); border-top-color: var(--sage); display: flex;
  align-items: center; justify-content: center; animation: spin 1.1s linear infinite; }
.ring svg { width: 48px; height: 48px; animation: spin 1.1s linear infinite reverse; }
@keyframes spin { to { transform: rotate(360deg); } }
.calc-list { display: flex; flex-direction: column; gap: 10px; }
.calc-list .check { opacity: 0; animation: fade 0.3s forwards; }
.calc-list .check:nth-child(2) { animation-delay: 0.4s; }
.calc-list .check:nth-child(3) { animation-delay: 0.8s; }
@keyframes fade { to { opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .wz-body.enter, .ring, .ring svg { animation: none; } .calc-list .check { animation: none; opacity: 1; } .opt { transition: none; } }

/* состояния: скелет загрузки, «печатает», плашка «нет связи», занятая кнопка */
.skel { height: 68px; box-shadow: none; background: linear-gradient(90deg, var(--card) 0%, var(--placeholder) 50%, var(--card) 100%);
  background-size: 200% 100%; animation: skel 1.2s ease-in-out infinite; }
@keyframes skel { from { background-position: 100% 0; } to { background-position: -100% 0; } }
@media (prefers-reduced-motion: reduce) { .skel { animation: none; } }
.typing { color: var(--muted); font-style: italic; }
.netbar { position: fixed; top: 0; left: 0; right: 0; z-index: 20; display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: calc(8px + env(safe-area-inset-top)) 16px 8px; background: var(--warm-soft); border-bottom: 1px solid var(--warm-line); color: var(--warm-ink); font-size: 14px; }
.btn[disabled], .chip[disabled] { opacity: 0.6; cursor: progress; }
.hidden { display: none !important; }

/* Согласие на обработку данных — на приветствии анкеты */
.consent { display: flex; gap: 12px; align-items: flex-start; font-size: 14px; line-height: 1.4; margin: 4px 2px 12px; }
.consent input { width: 22px; height: 22px; flex: none; margin-top: 1px; accent-color: var(--accent-text); }
.consent a { color: var(--accent-text); text-decoration: underline; }
#wz-start[disabled] { opacity: 0.45; cursor: not-allowed; }

/* ---------- «Замая Выручай» (Obsidian 27, эталон IMG_8285): логотип, шапки, жёлтые кнопки, заставка, Главная, Клуб */
.zlogo { display: inline-flex; flex-direction: column; align-items: flex-start; font-family: Caveat, cursive; font-weight: 700;
  line-height: 0.82; color: var(--accent-text); transform: rotate(-6deg); position: relative; padding-top: 20px; }
.zlogo .hat { position: absolute; top: -2px; left: 22%; width: 34px; height: 26px; fill: none; stroke: currentColor; stroke-width: 1.8; }
.zlogo .w1 { font-size: 48px; }
.zlogo .w2 { font-size: 40px; margin-left: 28px; display: inline-flex; align-items: center; gap: 2px; }
.zlogo .heart { width: 26px; height: 24px; fill: none; stroke: var(--heart); stroke-width: 2.6; }
.zlogo::after { content: ""; display: block; width: 72%; height: 4px; margin: 6px 0 0 30px; border-radius: 4px; background: var(--heart); transform: rotate(-2deg); }
.zlogo.light { color: var(--on-head); }
.zlogo.small { padding-top: 13px; }
.zlogo.small .hat { width: 22px; height: 17px; top: 0; }
.zlogo.small .w1 { font-size: 29px; }
.zlogo.small .w2 { font-size: 24px; margin-left: 16px; }
.zlogo.small .heart { width: 16px; height: 15px; }
.zlogo.small::after { height: 3px; margin: 3px 0 0 18px; }
.tagline { font-weight: 700; letter-spacing: 0.2px; }

.topbar { margin: -20px -16px 2px; padding: calc(14px + env(safe-area-inset-top)) 16px 16px; display: flex; align-items: center; gap: 10px;
  background: linear-gradient(180deg, var(--head-2), var(--head)); color: var(--on-head); border-radius: 0 0 24px 24px; box-shadow: var(--shadow-hero); }
.topbar h1 { flex: 1; min-width: 0; color: var(--on-head); font-size: 20px; font-weight: 800; letter-spacing: -0.2px; }
.topbar .tb-btn { width: 42px; height: 42px; flex: none; border: 0; border-radius: 14px; background: var(--head-chip); color: var(--on-head);
  font: inherit; font-size: 20px; font-weight: 700; display: flex; align-items: center; justify-content: center; cursor: pointer; }
.topbar .tb-btn svg { width: 22px; height: 22px; stroke: currentColor; }
.topbar .tb-ico { width: 24px; height: 24px; flex: none; stroke: var(--on-head); }
.topbar.home { justify-content: space-between; padding-bottom: 18px; }

.btn.cta { background: var(--cta); color: var(--cta-ink); box-shadow: var(--shadow-cta); font-weight: 800; }
.btn.cta:active { background: var(--cta-dark); }
.btn.cta .btn-ico { stroke: var(--cta-ink); }

/* заставка и знакомство */
.splash { margin: -20px -16px 0; min-height: 100vh; padding: calc(40px + env(safe-area-inset-top)) 24px 32px; display: flex; flex-direction: column;
  align-items: center; justify-content: space-between; gap: 22px; text-align: center; color: var(--on-head);
  background: radial-gradient(120% 70% at 50% 0%, var(--head-2), var(--head) 70%); }
.splash .dish { width: 100%; max-width: 360px; aspect-ratio: 785 / 495; object-fit: cover; border-radius: 28px; box-shadow: var(--shadow-hero); }
.splash .tagline { font-size: 21px; color: var(--on-head); }
.splash .note { color: var(--on-head-soft); font-size: 13px; }
.splash .btn { max-width: 360px; }
.hello { position: relative; border-radius: 28px; overflow: hidden; background: var(--card); box-shadow: var(--shadow); border: 1px solid var(--line); }
.hello img { display: block; width: 100%; aspect-ratio: 555 / 520; object-fit: cover; object-position: center 0%; }
.hello .bubble { position: relative; display: block; margin: -46px 16px 16px; text-align: center; background: var(--card); color: var(--accent-text); border-radius: 22px;
  padding: 10px 14px; font-family: Caveat, cursive; font-weight: 700; font-size: 31px; line-height: 0.95; box-shadow: var(--shadow); transform: rotate(-3deg); }
.hello .bubble svg { width: 20px; height: 18px; fill: none; stroke: var(--heart); stroke-width: 2.6; vertical-align: -2px; }
.helps { display: flex; flex-direction: column; gap: 8px; }
.helps > b { font-size: 18px; }

/* Главная */
.greet { flex-direction: row; align-items: center; gap: 14px; }
.greet img { width: 70px; height: 70px; border-radius: 50%; object-fit: cover; flex: none; border: 3px solid var(--sage-soft); }
.greet .hi { display: block; font-family: Caveat, cursive; font-weight: 700; font-size: 30px; line-height: 0.95; color: var(--accent-text); }
.greet .hi svg { width: 18px; height: 16px; fill: none; stroke: var(--heart); stroke-width: 2.6; vertical-align: 0; display: inline-block; }
/* три плитки как в макете (экран 5): значок сверху, подпись и цифра под ним */
.stat-tiles { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.stat { flex-direction: column; align-items: center; gap: 6px; padding: 12px 6px; font: inherit; color: inherit; text-align: center; cursor: pointer; }
.stat .mini-ring { width: 44px; height: 44px; flex: none; }
.stat .mini-ring svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.stat .mini-ring circle { fill: none; stroke-width: 6; }
.stat .ico-drop, .stat .ico-weight, .stat .ico-target, .stat .ico-left { width: 44px; height: 44px; flex: none; border-radius: 50%; display: flex; align-items: center; justify-content: center; }
.stat .ico-drop { background: var(--t-water); } .stat .ico-drop svg { stroke: var(--t-water-ink); }
.stat .ico-weight { background: var(--t-weight); } .stat .ico-weight svg { stroke: var(--t-weight-ink); }
.stat .ico-target { background: var(--t-sweet); } .stat .ico-target svg { stroke: var(--t-sweet-ink); }
.stat .ico-left { background: var(--t-food); } .stat .ico-left svg { stroke: var(--t-food-ink); }
.stat-tiles.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.stat-tiles.two .stat { flex-direction: row; justify-content: center; text-align: left; gap: 10px; }
.stat svg { width: 24px; height: 24px; }
.stat .txt { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.stat .txt b { font-size: 14px; }
.stat .txt span { font-size: 12px; color: var(--muted); line-height: 1.25; }
.sections { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.sec { font: inherit; color: var(--ink); background: var(--card); border: 1px solid var(--line); border-radius: 18px; padding: 12px 2px 10px; cursor: pointer;
  display: flex; flex-direction: column; align-items: center; gap: 6px; text-align: center; font-size: 11.5px; font-weight: 700; line-height: 1.15; box-shadow: var(--shadow); }
.sec i { width: 44px; height: 44px; border-radius: 14px; background: var(--sage-soft); display: flex; align-items: center; justify-content: center; }
.sec svg { width: 24px; height: 24px; stroke: var(--accent-text); }
.plan-card { flex-direction: row; align-items: center; gap: 12px; padding: 10px; font: inherit; color: inherit; text-align: left; cursor: pointer; width: 100%; }
.plan-card img { width: 88px; height: 72px; border-radius: 14px; object-fit: cover; flex: none; background: var(--placeholder); }
.plan-card .txt { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.plan-card .go { width: 36px; height: 36px; flex: none; border-radius: 50%; background: var(--sage); color: var(--on-accent); display: flex; align-items: center;
  justify-content: center; font-weight: 800; }

/* Клуб */
.club-hero { position: relative; border-radius: 26px; overflow: hidden; min-height: 220px; display: flex; align-items: flex-end; box-shadow: var(--shadow-hero); }
.club-hero img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.club-hero::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 30%, var(--photo-shade)); }
.club-hero .zlogo { position: relative; z-index: 1; margin: 0 0 16px 22px; }
.club-hero .crown { position: absolute; z-index: 1; top: 14px; left: 16px; width: 42px; height: 42px; border-radius: 12px; background: var(--cta);
  display: flex; align-items: center; justify-content: center; }
.club-hero .crown svg { width: 24px; height: 24px; stroke: var(--cta-ink); }
.nowrap { white-space: nowrap; }
/* Раздел под замком (макет: экраны 6 и 10) — пример, как выглядит раздел в клубе */
.locked { position: relative; }
.lock-badge { position: absolute; top: 12px; right: 12px; display: inline-flex; align-items: center; gap: 4px; padding: 4px 10px; border-radius: 999px;
  background: var(--cta); color: var(--cta-ink); font-size: 12px; font-weight: 800; }
.lock-badge svg { width: 14px; height: 14px; stroke: var(--cta-ink); }
.lock-rows { display: flex; flex-direction: column; opacity: 0.72; }
.lock-dim { opacity: 0.55; }
.lock-kcal { font-size: 13px; white-space: nowrap; }

/* ---------- Анимация первого экрана, вариант Б «Рукописный» (docs/superpowers/specs/2026-11-05-splash-animation-design.md)
   Всем, один раз за запуск (club/web/motion.js). Двигаются только opacity, transform и clip-path — без перерасчёта вёрстки.
   .play — идёт анимация; .done — касание: сразу финальный кадр. */
.play .zlogo .hat { animation: z-fade 0.4s both; }
.play .zlogo .w1 { animation: z-write 0.8s 0.2s steps(14) both; }
.play .zlogo .w2 { animation: z-write 0.9s 0.9s steps(16) both; }
.play .zlogo .heart { animation: z-pop 0.5s 1.8s cubic-bezier(0.3, 1.8, 0.5, 1) both; }
.play .zlogo::after { animation: z-write 0.5s 1.5s ease-out both; }
.splash.play .dish { animation: z-spin 0.9s 0.4s cubic-bezier(0.2, 0.9, 0.3, 1) both; }
.splash.play .tagline, .splash.play .note { animation: z-fade 0.4s 1.9s both; }
.splash.play .btn { animation: z-up 0.45s 2.1s ease-out both; }
.splash.leave { animation: z-out 0.22s ease-in both; }
#boot.play #boot-text { animation: z-fade 0.3s 0.8s both; }
#wz-hello.play .hello { animation: z-fade 0.35s both; }
#wz-hello.play .bubble { animation: z-pop 0.35s 0.2s cubic-bezier(0.3, 1.6, 0.5, 1) both; }
#wz-hello.play .helps > * { animation: z-up 0.35s both; }
#wz-hello.play .helps > :nth-child(2) { animation-delay: 0.35s; }
#wz-hello.play .helps > :nth-child(3) { animation-delay: 0.47s; }
#wz-hello.play .helps > :nth-child(4) { animation-delay: 0.59s; }
#wz-hello.play .helps > :nth-child(5) { animation-delay: 0.71s; }
#wz-hello.play .helps > :nth-child(6) { animation-delay: 0.83s; }
.play.done, .play.done *, .play.done ::after { animation: none !important; }
@keyframes z-fade { from { opacity: 0; } }
@keyframes z-write { from { clip-path: inset(0 100% 0 0); } to { clip-path: inset(0 0 0 0); } }
@keyframes z-pop { from { opacity: 0; transform: scale(0); } }
@keyframes z-spin { from { opacity: 0; transform: rotate(-120deg) scale(0.6); } }
@keyframes z-up { from { opacity: 0; transform: translateY(14px); } }
@keyframes z-out { to { opacity: 0; transform: scale(0.98); } }
@media (prefers-reduced-motion: reduce) { .play, .play *, .play ::after, .splash.leave { animation: none !important; } }
/* Экран загрузки — как заставка: тёмно-зелёный во весь экран, светлый логотип по центру (вариант Б пишется на нём) */
#boot.on { position: fixed; inset: 0; z-index: 5; max-width: none; margin: 0; justify-content: center; align-items: center; background: var(--head); padding: 24px 24px 18vh; }
#boot .zlogo .w1 { font-size: 60px; }
#boot .zlogo .w2 { font-size: 50px; margin-left: 34px; }
#boot .zlogo .hat { width: 42px; height: 32px; }
#boot #boot-text { color: var(--on-head-soft); }
/* ИИ-нутрициолог Замая: у каждого ответа метка «Ответ ИИ», предложения — карточкой с «Применить» */
.ai-tag { display: block; font-size: 11px; font-weight: 700; letter-spacing: 0.3px; color: var(--accent-text); margin-bottom: 2px; }
.ai-proposal, .ai-consent { align-self: stretch; gap: 8px; }
#chat-prefs:empty { display: none; }
