/* ohmybar — светлая тема «графит» и тёмная «вечеринка».
   Тема: <html data-theme="light|dark"> или без атрибута (как в системе). */

/* ---------- светлая тема: «графит» — швейцарский минимализм, Inter Tight + Inter ---------- */
:root {
  --font-display: "Inter Tight", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --font-body: "Inter", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, Menlo, monospace;
  --display-weight: 800;
  --display-tracking: -0.025em;
  --label-font: var(--font-body);
  --label-tracking: 0.08em;
  --radius: 10px;
  --radius-s: 8px;
  --radius-pill: 999px;
  --border-w: 1px;
  --tabbar-blur: none;

  --bg: #f3f3f0;
  --surface: #ffffff;
  --surface-2: #e9e9e5;
  --line: #deded8;
  --line-strong: #111418;
  --text: #111418;
  --text-2: #4a4f57;
  --text-3: #686d75;
  --accent: #d38a00;
  --accent-soft: #f6e7c4;
  --btn-bg: #111418;
  --btn-ink: #ffffff;
  --tab-active: #111418;
  --ok: #1c6b3c; --ok-soft: #dcefe2;
  --warn: #9a6a00; --warn-soft: #f6ebcd;
  --bad: #b3261e; --bad-soft: #f7dedb;
  --sub: #5446b0; --sub-soft: #e5e2f7;
  --shadow: none;
  --art-stroke: #111418;
  --summary-bg: #111418; --summary-ink: #f3f3f0;
  --chip-on-bg: #111418; --chip-on-ink: #f3f3f0; --btn-glow: none;
  color-scheme: light;
}
/* ---------- тёмная тема: «вечеринка» — глубокий синий и неон ---------- */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
  --bg: #090b12; --surface: #11141d; --surface-2: #191d29; --line: #242a3a; --line-strong: #eef0f7;
  --text: #eef0f7; --text-2: #a5abc0; --text-3: #838aa6;
  --accent: #ff5c8a; --accent-soft: #3d1728; --btn-bg: #ff5c8a; --btn-ink: #0b0c14; --tab-active: #ff5c8a;
  --ok: #4fe0b0; --ok-soft: #10302a; --warn: #ffc05c; --warn-soft: #3a2c12; --bad: #ff6b7a; --bad-soft: #3e1820; --sub: #8fa0ff; --sub-soft: #1d2346;
  --shadow: 0 0 0 1px rgba(255, 255, 255, .02), 0 10px 30px rgba(0, 0, 0, .35);
  --art-stroke: #eef0f7;
  --summary-bg: linear-gradient(120deg, #c92a62, #8a3fc0); --summary-ink: #ffffff;
  --chip-on-bg: #ff5c8a; --chip-on-ink: #0b0c14; --btn-glow: 0 6px 22px rgba(255, 92, 138, .35);
  --tabbar-blur: saturate(1.6) blur(20px);
  color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #090b12; --surface: #11141d; --surface-2: #191d29; --line: #242a3a; --line-strong: #eef0f7;
  --text: #eef0f7; --text-2: #a5abc0; --text-3: #838aa6;
  --accent: #ff5c8a; --accent-soft: #3d1728; --btn-bg: #ff5c8a; --btn-ink: #0b0c14; --tab-active: #ff5c8a;
  --ok: #4fe0b0; --ok-soft: #10302a; --warn: #ffc05c; --warn-soft: #3a2c12; --bad: #ff6b7a; --bad-soft: #3e1820; --sub: #8fa0ff; --sub-soft: #1d2346;
  --shadow: 0 0 0 1px rgba(255, 255, 255, .02), 0 10px 30px rgba(0, 0, 0, .35);
  --art-stroke: #eef0f7;
  --summary-bg: linear-gradient(120deg, #c92a62, #8a3fc0); --summary-ink: #ffffff;
  --chip-on-bg: #ff5c8a; --chip-on-ink: #0b0c14; --btn-glow: 0 6px 22px rgba(255, 92, 138, .35);
  --tabbar-blur: saturate(1.6) blur(20px);
  color-scheme: dark;
}

/* ---------- база ---------- */
:root { --tabbar-h: 60px; }
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--text); font: 16px/1.45 var(--font-body);
  -webkit-font-smoothing: antialiased; overscroll-behavior-y: none; font-feature-settings: "cv11", "ss01";
}
button, input, select, textarea { font: inherit; color: inherit; }
a { color: var(--text); text-decoration: none; }
img { max-width: 100%; display: block; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
h1, h2, h3 { font-family: var(--font-display); font-weight: var(--display-weight); letter-spacing: var(--display-tracking); margin: 0; text-wrap: balance; }
h1 { font-size: 34px; line-height: 1.02; }
h2 { font-size: 20px; line-height: 1.15; }
h3 { font-size: 16px; line-height: 1.2; }
.muted { color: var(--text-2); }
.small { font-size: 13px; }
.tiny { font-size: 12px; color: var(--text-3); }
.hidden { display: none !important; }
.num { font-variant-numeric: tabular-nums; }
.eyebrow, .cat-title, .fact .k, .lbl {
  font-family: var(--label-font); font-size: 11px; font-weight: 600; letter-spacing: var(--label-tracking); text-transform: uppercase; color: var(--text-3);
}

/* ---------- каркас ---------- */
.app { min-height: 100dvh; }
.boot { min-height: 100dvh; display: grid; place-items: center; }
.boot-logo { font-family: var(--font-display); font-weight: var(--display-weight); font-size: 30px; letter-spacing: var(--display-tracking); }
.main {
  padding: calc(env(safe-area-inset-top) + 14px) 16px calc(var(--tabbar-h) + env(safe-area-inset-bottom) + 28px);
  max-width: 1120px; margin: 0 auto;
}
.page-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; margin: 10px 0 18px; }
.page-head .sub { color: var(--text-2); font-size: 14px; margin-top: 6px; }
.back { display: inline-flex; align-items: center; gap: 2px; color: var(--text-2); background: none; border: 0; padding: 6px 0; margin: 0 0 2px -4px; cursor: pointer; font-size: 15px; }
.back svg { width: 20px; height: 20px; }
.section { margin: 26px 0; }
.section > h2, .section > h3 { margin-bottom: 12px; }
.row { display: flex; gap: 8px; align-items: center; }
.row.wrap { flex-wrap: wrap; }
.spacer { flex: 1; }
.stack > * + * { margin-top: 10px; }

.tabbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; display: grid; grid-template-columns: repeat(5, 1fr);
  background: color-mix(in srgb, var(--surface) 92%, transparent); backdrop-filter: var(--tabbar-blur); -webkit-backdrop-filter: var(--tabbar-blur);
  border-top: var(--border-w) solid var(--line); padding-bottom: env(safe-area-inset-bottom);
}
.tabbar a { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; height: var(--tabbar-h); color: var(--text-3); font-size: 10.5px; font-weight: 600; letter-spacing: .01em; }
.tabbar a.active { color: var(--tab-active); }
.tabbar svg { width: 24px; height: 24px; }
.tabbar .brand { display: none; }
@media (min-width: 900px) {
  .tabbar { top: 0; right: auto; width: 224px; grid-template-columns: 1fr; align-content: start; border-top: 0; border-right: var(--border-w) solid var(--line); padding: 26px 12px; gap: 2px; }
  .tabbar .brand { display: block; text-decoration: none; font-family: var(--font-display); font-weight: var(--display-weight); letter-spacing: var(--display-tracking); font-size: 22px; padding: 0 12px 22px; color: var(--text); }
  .tabbar a { flex-direction: row; justify-content: flex-start; gap: 12px; height: 42px; padding: 0 12px; border-radius: var(--radius-s); font-size: 14.5px; }
  .tabbar a.active { background: var(--surface-2); color: var(--text); }
  .tabbar svg { width: 20px; height: 20px; }
  .main { padding: 30px 36px 56px; margin-left: 224px; max-width: 1180px; }
}

/* ---------- элементы ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 16px;
  border-radius: var(--radius-s); border: var(--border-w) solid var(--line); background: var(--surface); color: var(--text);
  font-weight: 600; font-size: 15px; cursor: pointer; transition: transform .06s ease, background .15s, border-color .15s; white-space: nowrap;
}
.btn:hover { border-color: var(--text-3); }
.btn:active { transform: scale(.97); }
.btn svg { width: 18px; height: 18px; flex: none; }
.btn.primary { background: var(--btn-bg); color: var(--btn-ink); border-color: var(--btn-bg); box-shadow: var(--btn-glow); }
.btn.ghost { background: transparent; border-color: transparent; color: var(--text); padding: 0 8px; text-decoration: underline; text-underline-offset: 3px; text-decoration-color: var(--line); }
.btn.danger { color: var(--bad); }
.btn.small { min-height: 36px; padding: 0 12px; font-size: 14px; }
.btn.block { width: 100%; }
.btn[disabled] { opacity: .45; pointer-events: none; }
.icon-btn { width: 42px; height: 42px; border-radius: var(--radius-s); border: var(--border-w) solid var(--line); background: var(--surface); display: inline-grid; place-items: center; cursor: pointer; color: var(--text); flex: none; }
.icon-btn svg { width: 19px; height: 19px; }
.icon-btn.on { color: var(--accent); border-color: var(--accent); }

.card { background: var(--surface); border: var(--border-w) solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); }
.card.pad { padding: 16px; }
.list { background: var(--surface); border: var(--border-w) solid var(--line); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.list-item { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-bottom: 1px solid var(--line); min-height: 56px; }
.list-item:last-child { border-bottom: 0; }
.list-item .grow { flex: 1; min-width: 0; }
.list-item .title { font-weight: 600; overflow-wrap: anywhere; }
.list-item .meta { color: var(--text-2); font-size: 13px; }
a.list-item, button.list-item { color: inherit; width: 100%; text-align: left; background: none; border-left: 0; border-right: 0; border-top: 0; cursor: pointer; }
a.list-item:hover, button.list-item:hover { background: var(--surface-2); }
.chev { color: var(--text-3); width: 18px; height: 18px; flex: none; }

input.field, select.field, textarea.field {
  width: 100%; min-height: 46px; padding: 10px 14px; border-radius: var(--radius-s); border: var(--border-w) solid var(--line);
  background: var(--surface); outline: none; font-size: 16px;
}
textarea.field { min-height: 90px; resize: vertical; }
.field:focus { border-color: var(--text); }
label.lbl { display: block; margin: 16px 0 6px; }
.search { position: relative; }
.search svg { position: absolute; left: 13px; top: 50%; transform: translateY(-50%); width: 18px; height: 18px; color: var(--text-3); }
.search input { padding-left: 40px; }

.chips { display: flex; gap: 6px; overflow-x: auto; padding: 2px 16px 4px; margin: 0 -16px; scrollbar-width: none; }
.chips::-webkit-scrollbar { display: none; }
.chips.wrap { flex-wrap: wrap; overflow: visible; margin: 0; padding: 0; }
.chip {
  flex: none; display: inline-flex; align-items: center; gap: 6px; height: 34px; padding: 0 13px; border-radius: var(--radius-pill);
  border: var(--border-w) solid var(--line); background: var(--surface); color: var(--text-2); font-size: 14px; font-weight: 500; cursor: pointer; white-space: nowrap;
}
.chip.on { background: var(--chip-on-bg); color: var(--chip-on-ink); border-color: var(--chip-on-bg); }
select.chip { appearance: none; padding-right: 30px; background-image: linear-gradient(45deg, transparent 50%, currentColor 50%), linear-gradient(135deg, currentColor 50%, transparent 50%); background-position: calc(100% - 16px) 15px, calc(100% - 11px) 15px; background-size: 5px 5px; background-repeat: no-repeat; }
@media (min-width: 900px) { .chips { margin: 0; padding: 2px 0 4px; flex-wrap: wrap; } }

.seg { display: flex; gap: 2px; background: var(--surface-2); padding: 3px; border-radius: calc(var(--radius-s) + 3px); overflow-x: auto; scrollbar-width: none; }
.seg::-webkit-scrollbar { display: none; }
.seg button { flex: 1 0 auto; border: 0; background: transparent; padding: 8px 12px; border-radius: var(--radius-s); font-size: 14px; font-weight: 600; color: var(--text-2); cursor: pointer; white-space: nowrap; }
.seg button.on { background: var(--surface); color: var(--text); box-shadow: 0 1px 3px rgba(0, 0, 0, .08); }
.seg .n { font-weight: 500; opacity: 1; margin-left: 5px; font-variant-numeric: tabular-nums; }

.badge { display: inline-flex; align-items: center; gap: 4px; padding: 2px 7px; border-radius: var(--radius-pill); font-size: 11.5px; font-weight: 600; background: var(--surface-2); color: var(--text-2); white-space: nowrap; }
.badge.ok { background: var(--ok-soft); color: var(--ok); }
.badge.warn { background: var(--warn-soft); color: var(--warn); }
.badge.bad { background: var(--bad-soft); color: var(--bad); }
.badge.sub { background: var(--sub-soft); color: var(--sub); }
.badge.accent { background: var(--accent-soft); color: var(--text); }

/* ---------- иллюстрации ---------- */
.art { flex: none; display: grid; place-items: center; border-radius: var(--radius-s); background: color-mix(in srgb, var(--tint, #e8c77a) 7%, var(--surface-2)); color: var(--art-stroke); }
.art svg { width: 82%; height: 82%; }

/* ---------- коктейли ---------- */
.grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px; }
.grid > * { min-width: 0; }
@media (min-width: 620px) { .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; } }
@media (min-width: 1100px) { .grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.ccard { display: flex; gap: 14px; align-items: center; padding: 10px 14px 10px 10px; color: inherit; transition: border-color .15s; }
.ccard:hover { border-color: var(--text-3); }
.ccard .art { width: 64px; height: 64px; }
.ccard .name { font-weight: 700; font-size: 16px; line-height: 1.2; }
.ccard .en { color: var(--text-3); font-size: 12px; margin-top: 1px; }
.ccard .info { margin-top: 6px; display: flex; flex-wrap: wrap; gap: 4px; align-items: center; }
.ccard .miss { font-size: 12.5px; color: var(--bad); margin-top: 5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ccard .star { color: var(--accent); width: 15px; height: 15px; flex: none; }
.dot { width: 8px; height: 8px; border-radius: 50%; flex: none; display: inline-block; }
.dot.ok { background: var(--ok); } .dot.warn { background: var(--warn); } .dot.sub { background: var(--sub); } .dot.bad { background: var(--bad); }

.hero { display: grid; grid-template-columns: 124px 1fr; gap: 18px; align-items: center; margin: 6px 0 16px; }
.hero .art { width: 124px; height: 124px; border-radius: var(--radius); }
.hero h1 { font-size: 32px; }
.hero .en { color: var(--text-3); margin-top: 4px; }
.facts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; margin: 16px 0; border-top: var(--border-w) solid var(--line-strong); border-bottom: 1px solid var(--line); }
.fact { padding: 10px 0 10px; }
.fact + .fact { padding-left: 12px; border-left: 1px solid var(--line); }
.fact .v { font-weight: 700; font-size: 15px; margin-top: 3px; font-variant-numeric: tabular-nums; }

.ing { display: flex; align-items: center; gap: 12px; padding: 11px 14px; border-bottom: 1px solid var(--line); }
.ing:last-child { border-bottom: 0; }
.ing .amt { width: 78px; flex: none; font-weight: 700; font-variant-numeric: tabular-nums; font-family: var(--font-display); }
.ing .nm { flex: 1; min-width: 0; }
.ing .via { font-size: 12px; color: var(--text-2); }
.ing .st { width: 20px; height: 20px; flex: none; }
.st.ok { color: var(--ok); } .st.bad { color: var(--bad); } .st.warn { color: var(--warn); } .st.sub { color: var(--sub); } .st.dim { color: var(--text-3); }
.steps { counter-reset: s; padding: 0; margin: 0; list-style: none; }
.steps li { counter-increment: s; position: relative; padding: 0 0 12px 34px; }
.steps li::before { content: counter(s); position: absolute; left: 0; top: 0; width: 22px; height: 22px; border-radius: var(--radius-pill); border: var(--border-w) solid var(--line-strong); font: 700 11px/20px var(--font-mono); text-align: center; color: var(--text); }
.prose p { margin: 0 0 10px; }
.stepper { display: inline-flex; align-items: center; border: var(--border-w) solid var(--line); border-radius: var(--radius-s); overflow: hidden; background: var(--surface); }
.stepper button { width: 44px; height: 44px; border: 0; background: none; font-size: 19px; cursor: pointer; color: var(--text); }
.stepper span { min-width: 64px; text-align: center; font-weight: 600; font-size: 14px; font-variant-numeric: tabular-nums; }
.stepper.sm button { width: 30px; }
.stepper.sm span { min-width: 30px; }

/* ---------- бар ---------- */
.bar-summary { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 16px; padding: 16px 18px; background: var(--summary-bg); color: var(--summary-ink); border-radius: var(--radius); margin: 2px 0 20px; }
.bar-summary .big { font-family: var(--font-display); font-weight: var(--display-weight); letter-spacing: var(--display-tracking); font-size: 44px; line-height: 1; font-variant-numeric: tabular-nums; }
.bar-summary .t { font-weight: 700; }
.bar-summary .s { opacity: .75; font-size: 13px; margin-top: 2px; }
.bar-summary svg { width: 20px; height: 20px; }
.level { display: inline-flex; gap: 3px; align-items: flex-end; height: 16px; }
.level i { width: 4px; border-radius: 1px; background: var(--line); }
.level i:nth-child(1) { height: 6px; } .level i:nth-child(2) { height: 11px; } .level i:nth-child(3) { height: 16px; }
.level.full i { background: var(--text); }
.level.half i:nth-child(-n+2) { background: var(--warn); }
.level.low i:nth-child(1) { background: var(--bad); }
.thumb { width: 44px; height: 44px; border-radius: var(--radius-s); object-fit: cover; background: var(--surface-2); flex: none; display: grid; place-items: center; color: var(--text-3); }
.thumb svg { width: 21px; height: 21px; }
.cat-title { margin: 24px 2px 8px; }
.levels { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
.levels button { height: 40px; border-radius: var(--radius-s); border: var(--border-w) solid var(--line); background: var(--surface); font-size: 13px; font-weight: 600; cursor: pointer; color: var(--text-2); }
.levels button.on { background: var(--text); color: var(--bg); border-color: var(--text); }

/* ---------- шторка ---------- */
.sheet-backdrop { position: fixed; inset: 0; background: rgba(5, 6, 8, .5); z-index: 50; animation: fade .18s ease; }
.sheet {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 51; max-height: 92dvh; display: flex; flex-direction: column;
  background: var(--bg); border-radius: calc(var(--radius) + 8px) calc(var(--radius) + 8px) 0 0; box-shadow: 0 -10px 40px rgba(0, 0, 0, .25);
  animation: up .24s cubic-bezier(.2, .9, .3, 1); padding-bottom: env(safe-area-inset-bottom);
}
.sheet-head { display: flex; align-items: center; gap: 10px; padding: 12px 16px 10px; position: relative; }
.sheet-head::before { content: ""; position: absolute; left: 50%; top: 6px; width: 36px; height: 4px; border-radius: 2px; background: var(--line); transform: translateX(-50%); }
.sheet-head h2 { flex: 1; padding-top: 10px; }
.sheet-body { overflow-y: auto; padding: 4px 16px 20px; -webkit-overflow-scrolling: touch; }
.sheet-foot { padding: 10px 16px 14px; border-top: 1px solid var(--line); display: flex; gap: 10px; }
@media (min-width: 700px) {
  .sheet { left: 50%; right: auto; bottom: auto; top: 50%; width: 560px; transform: translate(-50%, -50%); border-radius: var(--radius); max-height: 86dvh; animation: fade .18s ease; border: var(--border-w) solid var(--line); }
  .sheet-head::before { display: none; }
}
@keyframes up { from { transform: translateY(100%); } }
@keyframes fade { from { opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .sheet, .sheet-backdrop { animation: none; } }

.toast {
  position: fixed; left: 50%; bottom: calc(var(--tabbar-h) + env(safe-area-inset-bottom) + 14px); transform: translate(-50%, 20px);
  background: var(--text); color: var(--bg); padding: 11px 18px; border-radius: var(--radius-s); font-weight: 600; font-size: 14px;
  opacity: 0; pointer-events: none; transition: all .22s ease; z-index: 60; max-width: calc(100vw - 32px); text-align: center;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

.empty { text-align: center; padding: 36px 16px; color: var(--text-2); }
.empty svg { width: 48px; height: 48px; color: var(--text-3); margin: 0 auto 10px; }
.empty h3 { color: var(--text); margin-bottom: 6px; }
.spinner { width: 26px; height: 26px; border: 2.5px solid var(--line); border-top-color: var(--text); border-radius: 50%; animation: spin .8s linear infinite; margin: 28px auto; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ---------- вход ---------- */
.auth { min-height: 100dvh; display: grid; place-items: center; padding: 24px 16px; }
.auth .box { width: 100%; max-width: 380px; }
.auth .logo { font-family: var(--font-display); font-weight: var(--display-weight); letter-spacing: var(--display-tracking); font-size: 40px; text-align: center; }
.auth .tag { text-align: center; color: var(--text-2); margin: 6px 0 26px; }
.err { color: var(--bad); font-size: 14px; margin-top: 10px; min-height: 20px; }

/* ---------- покупки / вечеринка / журнал ---------- */
.rec { padding: 14px 16px; }
.rec .top { display: flex; align-items: flex-start; gap: 12px; }
.rec .plus { font-family: var(--font-display); font-weight: var(--display-weight); font-size: 28px; line-height: 1; min-width: 48px; letter-spacing: var(--display-tracking); font-variant-numeric: tabular-nums; }
.rec .names { font-size: 13px; color: var(--text-2); margin-top: 4px; }
.check { width: 24px; height: 24px; border-radius: calc(var(--radius-s) / 1.5); border: var(--border-w) solid var(--text-3); display: grid; place-items: center; flex: none; background: var(--surface); cursor: pointer; }
.check.on { background: var(--text); border-color: var(--text); color: var(--bg); }
.check svg { width: 16px; height: 16px; }
.done .title { text-decoration: line-through; color: var(--text-3); }
.plan-line { display: flex; gap: 10px; align-items: baseline; padding: 10px 14px; border-bottom: 1px solid var(--line); }
.plan-line:last-child { border-bottom: 0; }
.plan-line .grow { flex: 1; min-width: 0; }
.plan-line .q { font-weight: 700; min-width: 86px; text-align: right; font-variant-numeric: tabular-nums; }
.stars { display: flex; gap: 6px; }
.stars button { border: 0; background: none; padding: 2px; cursor: pointer; color: var(--line); }
.stars button.on { color: var(--accent); }
.stars svg { width: 30px; height: 30px; }
.journal-item img { width: 100%; max-height: 320px; object-fit: cover; border-radius: var(--radius-s); margin-top: 10px; }
.kv { display: grid; grid-template-columns: auto 1fr; gap: 6px 14px; font-size: 14px; }
.kv dt { color: var(--text-3); }
.kv dd { margin: 0; }
.ing-row { display: grid; grid-template-columns: 1fr 70px 88px 36px; gap: 6px; align-items: center; margin-bottom: 8px; }
.ing-row .pick { text-align: left; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.install-tip { background: var(--surface-2); border-radius: var(--radius); padding: 14px 16px; font-size: 14px; }
.install-tip svg { width: 16px; height: 16px; vertical-align: -3px; }
.pill-note { font-size: 13.5px; background: var(--surface-2); border-radius: var(--radius-s); padding: 11px 13px; color: var(--text-2); margin: 0; }
.activity .when { color: var(--text-3); font-size: 12px; white-space: nowrap; }
code.code { font-family: var(--font-mono); background: var(--surface-2); padding: 8px 10px; border-radius: var(--radius-s); display: block; word-break: break-all; font-size: 13px; }
.list-item > .art { width: 38px; height: 38px; }

/* ---------- демо-панель ---------- */
.demo-bar { position: fixed; right: 12px; top: calc(env(safe-area-inset-top, 0px) + 10px); z-index: 40; display: flex; gap: 6px; align-items: center; background: var(--surface); border: var(--border-w) solid var(--line); border-radius: 999px; padding: 4px; box-shadow: 0 6px 24px rgba(0, 0, 0, .12); }
.demo-bar button { border: 0; background: none; height: 30px; padding: 0 10px; border-radius: 999px; font-size: 12.5px; font-weight: 600; color: var(--text-2); cursor: pointer; }
.demo-bar button.on { background: var(--text); color: var(--bg); }
.demo-bar .sep { width: 1px; height: 18px; background: var(--line); }
@media (max-width: 899px) { .demo-bar { top: auto; bottom: calc(var(--tabbar-h) + env(safe-area-inset-bottom, 0px) + 10px); right: 50%; transform: translateX(50%); } }
.row > .art { width: 38px; height: 38px; }
body.demo .main { padding-bottom: calc(var(--tabbar-h) + env(safe-area-inset-bottom) + 80px); }

/* ---------- бар: действия, квиз, карточка ингредиента ---------- */
.art.sm { width: 44px; height: 44px; }
.art.lg { width: 84px; height: 84px; border-radius: var(--radius); }
.thumb.big { width: 84px; height: 84px; border-radius: var(--radius); }
.actions2 { display: grid; grid-template-columns: 1.25fr 1fr; gap: 10px; margin: 2px 0 18px; }
.action-card { display: flex; flex-direction: column; gap: 2px; padding: 16px; border-radius: var(--radius); background: var(--surface); border: var(--border-w) solid var(--line); color: var(--text); min-width: 0; }
.action-card.main { background: var(--summary-bg); color: var(--summary-ink); border-color: transparent; }
.action-card .big { font-family: var(--font-display); font-weight: var(--display-weight); letter-spacing: var(--display-tracking); font-size: 40px; line-height: 1; margin-bottom: 8px; }
.action-card .t { font-weight: 700; font-size: 16px; }
.action-card .s { font-size: 12.5px; opacity: .9; }
.hero-cta h2 { margin-bottom: 6px; }
.hero-cta .btn.block { margin-top: 12px; }
.quiz { max-width: 560px; margin: 0 auto; }
.quiz-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.dots { display: flex; gap: 6px; }
.dots i { width: 22px; height: 4px; border-radius: 2px; background: var(--line); }
.dots i.on { background: var(--text); }
.quiz h1 { margin: 4px 0 6px; }
.tiles { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin: 16px 0; }
@media (min-width: 520px) { .tiles { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.tile { position: relative; display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 12px 6px 10px; border-radius: var(--radius); border: var(--border-w) solid var(--line); background: var(--surface); cursor: pointer; font-size: 13px; font-weight: 600; color: var(--text); text-align: center; line-height: 1.2; transition: border-color .12s, transform .06s; }
.tile:active { transform: scale(.97); }
.tile .art { width: 54px; height: 54px; background: none; }
.tile .tick { position: absolute; top: 6px; right: 6px; width: 20px; height: 20px; border-radius: 50%; background: var(--text); color: var(--bg); display: none; place-items: center; }
.tile .tick svg { width: 13px; height: 13px; }
.tile.on { border-color: var(--text); box-shadow: 0 0 0 1px var(--text); }
.tile.on .tick { display: grid; }
.quiz-foot { position: sticky; bottom: calc(var(--tabbar-h) + env(safe-area-inset-bottom) + 8px); background: var(--bg); padding: 10px 0 4px; display: grid; gap: 6px; }
@media (min-width: 900px) { .quiz-foot { bottom: 0; } }
.qcount { text-align: center; font-size: 14px; color: var(--text-2); min-height: 20px; }
.qcount b { color: var(--text); font-size: 18px; }
.ing-head { display: flex; gap: 14px; align-items: center; margin-bottom: 10px; }
.ing-link { background: none; border: 0; padding: 0; font: inherit; color: inherit; text-align: left; cursor: pointer; text-decoration: underline; text-decoration-color: var(--line); text-underline-offset: 3px; }
.toast:not(.show) { pointer-events: none !important; }
.toast.has-act { pointer-events: auto; display: flex; gap: 12px; align-items: center; }
.toast-act { background: none; border: 0; color: var(--accent); font-weight: 700; cursor: pointer; padding: 0; }
.rec .top .art { margin-top: -2px; }
.sheet-body div.lbl { display: block; margin: 18px 0 8px; }
.quick2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin: -8px 0 4px; }
.quick2 .btn { width: 100%; white-space: normal; line-height: 1.2; padding: 6px 10px; text-align: center; min-height: 40px; }

/* ---------- формулы, ИИ, режим готовки ---------- */
.suggest h2 { margin-bottom: 6px; }
.suggest .grid { margin-top: 12px; }
.ai-card { display: flex; gap: 14px; align-items: center; justify-content: space-between; margin-top: 14px; padding: 14px 16px; border-radius: var(--radius); border: var(--border-w) dashed var(--text-3); background: var(--surface); }
.ai-card .btn { flex: none; }
ul.why { margin: 0; padding-left: 20px; }
ul.why li { margin-bottom: 8px; }
.seg.units { flex: none; padding: 2px; }
.seg.units button { padding: 6px 10px; font-size: 13px; }
.cook-btn { margin: 4px 0 6px; min-height: 52px; font-size: 16px; }
.cook { position: fixed; inset: 0; z-index: 70; background: var(--bg); overflow-y: auto; }
.cook-in { max-width: 560px; margin: 0 auto; min-height: 100%; display: flex; flex-direction: column; padding: calc(env(safe-area-inset-top) + 14px) 16px calc(env(safe-area-inset-bottom) + 16px); }
.cook-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 18px; }
.cook-body { flex: 1; }
.cook-step { font-family: var(--font-display); font-weight: 700; font-size: 28px; line-height: 1.2; letter-spacing: -.01em; margin: 10px 0 24px; text-wrap: balance; }
.cook-foot { display: flex; gap: 10px; padding-top: 16px; position: sticky; bottom: 0; background: var(--bg); }
.timer { width: 180px; height: 180px; border-radius: 50%; border: 3px solid var(--text); background: var(--surface); display: grid; place-content: center; text-align: center; margin: 10px auto; cursor: pointer; color: var(--text); }
.timer span { font-family: var(--font-display); font-weight: 800; font-size: 56px; line-height: 1; }
.timer small { font-size: 12px; color: var(--text-2); max-width: 130px; margin-top: 6px; }
.timer.run { border-color: var(--accent); animation: pulse 1s ease-in-out infinite; }
.timer.ok { border-color: var(--ok); }
@keyframes pulse { 50% { transform: scale(1.03); } }
@media (prefers-reduced-motion: reduce) { .timer.run { animation: none; } }
.rate3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 16px; }
.rate3 button { padding: 18px 8px; border-radius: var(--radius); border: var(--border-w) solid var(--line); background: var(--surface); font: 700 17px/1.2 var(--font-body); color: var(--text); cursor: pointer; display: flex; flex-direction: column; gap: 4px; align-items: center; }
.rate3 button small { font-weight: 500; font-size: 12px; color: var(--text-3); }
.rate3 button:hover { border-color: var(--text); }
.cook-ing .check { pointer-events: none; }

/* ---------- гость, 18+, Telegram ---------- */
.age { text-align: center; }
.age-num { font-family: var(--font-display); font-weight: var(--display-weight); font-size: 56px; letter-spacing: var(--display-tracking); line-height: 1; margin-bottom: 10px; color: var(--accent); }
.age h2 { margin-bottom: 6px; }
.age .muted { margin-bottom: 20px; }
.or { display: flex; align-items: center; gap: 10px; color: var(--text-3); font-size: 13px; margin: 14px 0; }
.or::before, .or::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.consent { display: flex; gap: 10px; align-items: flex-start; font-size: 13px; color: var(--text-2); line-height: 1.4; }
.consent input { margin-top: 2px; width: 18px; height: 18px; accent-color: var(--text); flex: none; }
.save-banner { display: flex; align-items: center; gap: 12px; padding: 12px 14px; border-radius: var(--radius); background: var(--accent-soft); color: var(--text); font-size: 14px; line-height: 1.35; margin: 14px 0; }
.save-banner > svg { width: 20px; height: 20px; flex: none; color: var(--accent); }
.tg-card { display: flex; align-items: center; gap: 12px; padding: 14px 16px; border-radius: var(--radius); border: var(--border-w) solid var(--line); background: var(--surface); color: var(--text); text-decoration: none; }
.tg-card > svg:first-child { width: 22px; height: 22px; color: #2aa3de; flex: none; }
.tg-card .chev { width: 16px; height: 16px; color: var(--text-3); }
.steps-mini { margin: 0 0 16px; padding-left: 20px; color: var(--text-2); line-height: 1.7; }
.btn svg { vertical-align: -3px; }
.doc { max-width: 680px; }
.doc h1 { font-size: 28px; margin: 10px 0 6px; }
.doc h3 { margin: 20px 0 6px; }
.doc p { color: var(--text-2); line-height: 1.55; margin: 0; }
.stats { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 10px; margin-bottom: 8px; }
.stat { background: var(--surface); border: var(--border-w) solid var(--line); border-radius: var(--radius); padding: 12px 14px; }
.stat b { display: block; font-family: var(--font-display); font-size: 28px; font-weight: var(--display-weight); letter-spacing: var(--display-tracking); }
.stat span { font-size: 12px; color: var(--text-2); }

/* ---------- лендинг (десктоп) ---------- */
.landing { max-width: 1180px; margin: 0 auto; padding: 0 40px; }
.l-nav { display: flex; align-items: center; gap: 28px; padding: 22px 0; position: sticky; top: 0; z-index: 5; background: var(--bg); }
.l-nav .brand { font-family: var(--font-display); font-weight: var(--display-weight); letter-spacing: var(--display-tracking); font-size: 24px; }
.l-nav nav { display: flex; gap: 6px; margin-left: auto; }
.l-nav nav button { background: none; border: 0; color: var(--text-2); font: 500 15px var(--font-body); padding: 8px 12px; border-radius: var(--radius-s); cursor: pointer; }
.l-nav nav button:hover { color: var(--text); background: var(--surface-2); }
.l-hero { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: 56px; align-items: center; padding: 48px 0 72px; }
.l-hero h1 { font-size: clamp(44px, 5.2vw, 68px); line-height: 1.02; margin: 12px 0 20px; }
.l-lead { font-size: 19px; line-height: 1.5; color: var(--text-2); max-width: 560px; margin: 0 0 32px; }
.l-qr { display: flex; gap: 20px; align-items: center; padding: 18px; border: var(--border-w) solid var(--line); border-radius: var(--radius); background: var(--surface); max-width: 520px; }
.l-qr .qr { width: 132px; height: 132px; flex: none; padding: 10px; background: #fff; border-radius: var(--radius-s); color: #111; }
.l-qr .qr svg { width: 100%; height: 100%; display: block; }
.l-qr p { margin: 6px 0 10px; font-size: 14px; line-height: 1.45; }
.l-phone { display: flex; justify-content: center; }
.phone { width: 340px; border-radius: 44px; padding: 12px; background: var(--text); box-shadow: 0 30px 80px rgba(0, 0, 0, .18), var(--btn-glow); }
.phone-screen { border-radius: 34px; background: var(--bg); padding: 30px 16px 18px; min-height: 620px; display: flex; flex-direction: column; }
.ph-title { font-family: var(--font-display); font-weight: var(--display-weight); letter-spacing: var(--display-tracking); font-size: 26px; }
.ph-sub { color: var(--text-2); font-size: 13px; margin: 2px 0 14px; }
.ph-tiles { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; }
.ph-tile { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 6px 2px; border-radius: var(--radius-s); border: var(--border-w) solid var(--line); background: var(--surface); color: var(--text); font: 600 10.5px var(--font-body); cursor: pointer; line-height: 1.15; min-width: 0; }
.ph-tile span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 100%; }
.ph-tile .art { width: 38px; height: 38px; background: none; }
.ph-tile:hover { border-color: var(--text-3); }
.ph-tile.on { border-color: var(--text); box-shadow: 0 0 0 1px var(--text); }
.ph-count { margin: 14px 0 8px; font-size: 14px; color: var(--text-2); min-height: 20px; }
.ph-count b { font-family: var(--font-display); font-size: 22px; color: var(--text); }
.ph-list { display: flex; flex-direction: column; gap: 6px; flex: 1; }
.ph-c { display: flex; align-items: center; gap: 10px; font-weight: 600; font-size: 14px; animation: phin .25s ease; }
.ph-c .art { width: 36px; height: 36px; }
@keyframes phin { from { opacity: 0; transform: translateY(4px); } }
.phone-screen .btn { margin-top: 12px; }
.l-sec { padding: 56px 0; border-top: var(--border-w) solid var(--line); }
.l-sec > h2 { font-size: 34px; margin: 0 0 28px; }
.l-steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.l-steps .num { font-family: var(--font-display); font-weight: var(--display-weight); font-size: 44px; color: var(--accent); line-height: 1; }
.l-steps h3, .l-feat h3 { margin: 12px 0 6px; font-size: 19px; }
.l-steps p, .l-feat p { color: var(--text-2); line-height: 1.5; margin: 0; }
.l-feats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.l-feat { padding: 22px; border: var(--border-w) solid var(--line); border-radius: var(--radius); background: var(--surface); }
.l-feat > svg { width: 26px; height: 26px; color: var(--accent); }
.l-cocktails { display: grid; grid-template-columns: repeat(6, 1fr); gap: 14px; }
.l-c { display: flex; flex-direction: column; gap: 4px; }
.l-c .art { width: 100%; aspect-ratio: 1; height: auto; border-radius: var(--radius); margin-bottom: 6px; }
.l-c span { font-size: 13px; color: var(--text-3); }
.l-band { display: flex; align-items: center; justify-content: space-between; gap: 32px; padding: 40px 44px; margin: 24px 0 56px; border-radius: calc(var(--radius) * 1.6); background: var(--summary-bg); color: var(--summary-ink); }
.l-band h2 { font-size: 30px; margin: 0 0 8px; color: inherit; }
.l-band p { margin: 0; max-width: 560px; opacity: 1; line-height: 1.5; }
.l-band .btn.primary { background: var(--summary-ink); color: #111418; box-shadow: none; flex: none; }
.l-foot { display: flex; flex-wrap: wrap; gap: 8px 28px; padding: 24px 0 40px; border-top: var(--border-w) solid var(--line); color: var(--text-3); font-size: 13px; }
.l-foot a { color: var(--text-3); margin-left: auto; }
@media (max-width: 1023px) {
  .landing { padding: 0 16px; }
  .l-nav nav { display: none; }
  .l-nav .btn { margin-left: auto; }
  .l-hero { grid-template-columns: 1fr; gap: 32px; }
  .l-steps, .l-feats { grid-template-columns: 1fr; }
  .l-cocktails { grid-template-columns: repeat(3, 1fr); }
  .l-band { flex-direction: column; align-items: flex-start; padding: 28px 22px; }
  .phone { width: min(340px, 100%); }
}
.tg-card + .tg-card { margin-top: 10px; }
.tg-card.max > svg:first-child { color: #7a5cff; }
.l-band-btns { display: flex; gap: 10px; flex-wrap: wrap; flex: none; }
.l-qr { transition: box-shadow .2s; }
.l-qr.pulse { animation: qrpulse 1.4s ease 2; }
@keyframes qrpulse { 0%, 100% { box-shadow: 0 0 0 0 transparent; } 40% { box-shadow: 0 0 0 6px var(--accent); } }
.lnk-open { background: none; border: 0; padding: 0; margin-top: 2px; color: var(--text-2); font: 500 14px var(--font-body); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; display: inline-flex; align-items: center; gap: 2px; }
.lnk-open svg { width: 14px; height: 14px; }
.lnk-open:hover { color: var(--text); }
.lnk-open.center { display: block; margin: 10px auto 0; font-size: 13px; }
.demo .l-nav { padding-top: 64px; }

/* подборки под повод */
.occ-row { display: flex; gap: 8px; overflow-x: auto; margin: 0 -16px 14px; padding: 2px 16px 6px; scrollbar-width: none; }
.occ-row::-webkit-scrollbar { display: none; }
.occ { flex: none; width: 150px; display: flex; flex-direction: column; gap: 3px; padding: 12px 14px; border-radius: var(--radius); border: var(--border-w) solid var(--line); background: var(--surface); color: var(--text); text-decoration: none; text-align: left; font: inherit; cursor: pointer; }
.occ b { font-family: var(--font-display); font-size: 16px; display: flex; align-items: center; gap: 6px; }
.occ b svg { width: 16px; height: 16px; color: var(--accent); }
.occ span { font-size: 12px; color: var(--text-2); line-height: 1.3; }
.occ-act { border-style: dashed; }
@media (min-width: 900px) { .occ-row { flex-wrap: wrap; margin: 0 0 14px; padding: 0; overflow: visible; } }
/* свайп «Кончилась» */
.swipe { position: relative; overflow: hidden; }
.swipe + .swipe { border-top: var(--border-w) solid var(--line); }
.swipe .list-item { position: relative; z-index: 1; background: var(--surface); touch-action: pan-y; width: 100%; }
.swipe-bg { position: absolute; inset: 0; display: flex; align-items: center; justify-content: flex-end; padding-right: 18px; background: var(--bad-soft); color: var(--bad); font-weight: 600; font-size: 14px; }
.swipe.armed .swipe-bg { background: var(--bad); color: #fff; }
.swipe-hint { margin: 4px 0 -4px; }
@media (hover: hover) and (pointer: fine) { .swipe-hint { display: none; } }
/* внутри Telegram */
.tgapp .tabbar .brand { display: none; }

/* UX-проверка: цели касания и мелочи */
.back { min-height: 44px; }
.lnk-open { padding: 8px 0; }
.ing-link { padding: 6px 0; display: inline-block; }
.consent input { width: 22px; height: 22px; }
.chip { min-height: 40px; }
@media (max-width: 899px) { .tabbar a { font-size: 11.5px; } }
.page-head h1.brand-h { font-size: clamp(28px, 8vw, 36px); white-space: nowrap; }
.cmeta p, .hist p, .ctips p { max-width: 68ch; }

/* плашки-подсказки: метод, бокал, лёд */
button.fact.tap { font: inherit; color: inherit; text-align: left; cursor: pointer; background: none; border: 0; border-radius: 0; }
.fact + button.fact.tap, button.fact.tap + .fact { border-left: 1px solid var(--line); }
button.fact.tap .v { text-decoration: underline dotted; text-underline-offset: 4px; }
button.fact.tap:hover .v { color: var(--accent); }
.fact.tap .k { white-space: nowrap; }
.lnk-fact { background: none; border: 0; padding: 4px 0; font: inherit; color: inherit; text-decoration: underline dotted; text-underline-offset: 3px; cursor: pointer; }
.glass-hero { display: flex; gap: 14px; align-items: center; margin-bottom: 14px; }
.glass-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; margin-top: 6px; }
.glass-tile { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 6px 2px; border-radius: var(--radius-s); border: var(--border-w) solid var(--line); background: var(--surface); color: var(--text); font: 600 11.5px var(--font-body); cursor: pointer; min-width: 0; }
.glass-tile span:last-child { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 100%; }
.glass-tile .art { background: none; }
.glass-tile.on { border-color: var(--text); box-shadow: 0 0 0 1px var(--text); }
.l-nav [data-themetoggle] { font-size: 20px; width: 44px; height: 44px; }
