/* =====================================================================
   ЧАЙНАЯ — минимализм · светлая/тёмная тема · каталог на одной странице
   ===================================================================== */

:root {
  /* Светлая тема — тонированная слоновая кость, приглушённая и тёплая */
  --bg:        #E8E1CF;
  --bg-soft:   #DFD7C2;
  --card:      #EFE8D7;
  --text:      #2A2720;
  --text-soft: #5A554A;
  --muted:     #948C7A;
  --line:      #D5CBB5;
  --accent:    #3E5544;   /* нефрит */
  --accent-2:  #2E4133;
  --on-accent: #F1EAD8;
  --clay:      #A8663E;
  --shadow:    28px 40px 80px -46px rgba(40,34,22,0.45);
  --motif:     #23211A;   /* цвет фоновых мазков */
  --motif-op:  0.09;

  --serif: 'Cormorant Garamond', Georgia, 'Times New Roman', serif;
  --sans:  'Inter', -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
  --maxw: 1200px;
  --gutter: clamp(18px, 4.5vw, 56px);
  --radius: 14px;
  --ease: cubic-bezier(0.4, 0, 0.1, 1);

  /* [v2-22] шкала радиусов вместо зоопарка значений */
  --radius-s: 12px;
  --radius-m: 20px;
  --radius-pill: 999px;
  /* [v2-6] тени цвета среды, единое направление света сверху */
  --shadow-soft: 0 10px 26px -18px rgba(62, 54, 36, 0.55);
  --shadow-float: 0 18px 44px -24px rgba(62, 54, 36, 0.5);
}

:root[data-theme='dark'] {
  /* Тёмная тема (тёплый графит; акцент — чайное золото, не зелень) */
  --bg:        #17150F;
  --bg-soft:   #1F1C15;
  --card:      #201D16;
  --text:      #E9E3D5;
  --text-soft: #ADA694;
  --muted:     #7E7768;
  --line:      #322D22;
  --accent:    #C7A97B;
  --accent-2:  #D8BE94;
  --on-accent: #171410;
  --clay:      #C98F63;
  --shadow:    28px 46px 90px -46px rgba(0,0,0,0.7);
  --motif:     #EDE7D9;   /* белые мазки в тёмной теме */
  --motif-op:  0.08;
  --shadow-soft: 0 10px 26px -18px rgba(0, 0, 0, 0.6);
  --shadow-float: 0 18px 44px -24px rgba(0, 0, 0, 0.55);
}

* , *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; background: var(--bg); transition: background 0.5s var(--ease); }
body {
  font-family: var(--sans);
  background: transparent;
  color: var(--text);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
  transition: background 0.5s var(--ease), color 0.5s var(--ease);
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; color: inherit; }
ul { list-style: none; }

h1, h2, h3 { font-family: var(--serif); font-weight: 500; line-height: 1.1; letter-spacing: -0.01em; text-wrap: balance; }

/* [v2-19] состояния: аккуратный фокус с клавиатуры, честные disabled */
:where(a, button, input, select, textarea):focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
button:disabled { opacity: 0.55; cursor: default; pointer-events: none; }
.wrap { max-width: var(--maxw); margin: 0 auto; padding-inline: var(--gutter); }

/* [v2-1] зерно рисовой бумаги: фон перестаёт быть заливкой */
body::after {
  content: ''; position: fixed; inset: 0; z-index: 99; pointer-events: none;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='220' height='220'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/><feColorMatrix type='saturate' values='0'/></filter><rect width='100%25' height='100%25' filter='url(%23n)'/></svg>");
  background-size: 220px 220px;
  opacity: 0.028; mix-blend-mode: multiply;
}
:root[data-theme='dark'] body::after { opacity: 0.045; mix-blend-mode: screen; }

/* ---------- Фоновая «живопись» кистью ---------- */
.bg-art { position: fixed; inset: 0; z-index: -1; overflow: hidden; pointer-events: none; }
.bg-motif { position: absolute; color: var(--motif); }
.bg-motif svg {
  width: 100%; height: auto;
  fill: none; stroke: currentColor; stroke-width: 2;
  stroke-linecap: round; stroke-linejoin: round;
  opacity: var(--motif-op); transition: opacity 0.5s var(--ease), color 0.5s var(--ease);
}
.bg-flow {
  position: absolute; inset: 0; width: 100%; height: 100%;
  color: var(--motif); fill: none; stroke: currentColor;
  stroke-width: 1.4; stroke-linecap: round; stroke-linejoin: round;
  opacity: var(--motif-op); transition: opacity 0.5s var(--ease), color 0.5s var(--ease);
}
.bg-sumi {
  position: absolute; inset: 0; width: 100%; height: 100%;
  color: var(--motif);
  opacity: calc(var(--motif-op) * 1.25);
  transition: opacity 0.5s var(--ease), color 0.5s var(--ease);
  font-family: 'Cormorant Garamond', 'Noto Serif SC', 'SimSun', serif;
}
/* Вариант E — те же мазки, но пастельный хаки (плотнее, мягкий цвет) */
.bg-sumi--khaki { color: var(--khaki); opacity: var(--khaki-op); }
:root { --khaki: #A0AC7B; --khaki-op: 0.38; }
:root[data-theme='dark'] { --khaki: #8F8266; --khaki-op: 0.3; }
@media (max-width: 560px) { .bg-motif { --motif-op: 0.075; } .bg-flow { stroke-width: 1.1; } }

/* ---------- Кнопки ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.55em;
  font-size: 0.8rem; font-weight: 500; letter-spacing: 0.05em; text-transform: uppercase;
  padding: 0.95em 1.8em; border-radius: var(--radius-pill);
  transition: all 0.35s var(--ease);
}
.btn--solid { background: var(--accent); color: var(--on-accent); }
.btn--solid:hover { background: var(--accent-2); transform: translateY(-2px); }
.btn--ghost { border: 1px solid var(--line); color: var(--text); }
.btn--ghost:hover { border-color: var(--text); }
.btn--block { width: 100%; }

/* =====================================================================
   Хедер
   ===================================================================== */
.header {
  position: sticky; top: 0; z-index: 40;
  background: color-mix(in srgb, var(--bg) 84%, transparent);
  backdrop-filter: saturate(150%) blur(16px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.4s var(--ease);
}
.header.is-scrolled { border-bottom-color: var(--line); }
.header__inner {
  max-width: var(--maxw); margin: 0 auto; padding-inline: var(--gutter);
  height: 66px; display: flex; align-items: center; justify-content: space-between; gap: 20px;
}
.brand { display: flex; align-items: center; gap: 11px; }
.brand__mark {
  display: block; color: var(--accent);
  font-family: var(--serif); font-size: 1.9rem; line-height: 1;
}
.brand__text { display: flex; flex-direction: column; line-height: 1; }
.brand__name { font-family: var(--serif); font-size: 1.35rem; font-weight: 600; letter-spacing: 0.13em; line-height: 1; }
.brand__tag { font-family: var(--sans); font-size: 0.55rem; font-weight: 500; letter-spacing: 0.15em; text-transform: uppercase; color: var(--muted); margin-top: 5px; white-space: nowrap; }
.header__actions { display: flex; align-items: center; gap: 10px; }

.icon-btn {
  width: 42px; height: 42px; border-radius: 50%;
  display: grid; place-items: center; position: relative;
  border: 1px solid var(--line);
  transition: border-color 0.3s var(--ease), background 0.3s var(--ease);
}
.icon-btn:hover { border-color: var(--text); background: var(--bg-soft); }   /* [v2-19] */
.icon-btn svg { width: 19px; height: 19px; }
.cart-count {
  position: absolute; top: -5px; right: -5px;
  min-width: 18px; height: 18px; padding-inline: 4px;
  display: grid; place-items: center; border-radius: 20px;
  background: var(--clay); color: #fff; font-size: 0.62rem; font-weight: 600;
}
.cart-count[data-count='0'] { display: none; }

/* Переключатель темы: солнце/луна */
.theme-toggle .sun { display: none; }
.theme-toggle .moon { display: block; }
:root[data-theme='dark'] .theme-toggle .sun { display: block; }
:root[data-theme='dark'] .theme-toggle .moon { display: none; }

/* =====================================================================
   Цитата вместо громкого героя
   ===================================================================== */
/* [v2-2] больше воздуха вокруг цитаты; [v2-24] две строки крупно вместо nowrap-мельчения */
.quote { padding-block: clamp(64px, 11vw, 150px) clamp(40px, 6vw, 80px); }
.quote__inner { max-width: 780px; }
.quote blockquote {
  font-family: var(--serif); font-weight: 500;
  font-size: clamp(1.35rem, 4.2vw, 2.3rem); line-height: 1.25; letter-spacing: -0.01em;
  text-wrap: balance; text-indent: -0.45ch;   /* висячая кавычка */
}
.quote blockquote .q { color: var(--muted); }
.quote blockquote em { font-style: italic; color: var(--accent); }
.quote__author { margin-top: 20px; font-size: 0.82rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); }

/* =====================================================================
   Полоса доверия — медленно плывущая лента
   ===================================================================== */
/* [v2-fix] лента на матовом стекле, как шапка — фон под ней мягко размыт */
.trust {
  border-top: 1px solid var(--line);
  overflow: hidden;
  padding-block: 13px;
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: saturate(140%) blur(14px);
}
.trust__track {
  display: flex; align-items: center; gap: 28px; width: max-content;
  animation: trust-drift 38s linear infinite;
}
.trust:hover .trust__track { animation-play-state: paused; }
.trust__track span {
  font-family: var(--serif); font-size: 0.98rem; color: var(--text-soft);
  white-space: nowrap; letter-spacing: 0.02em;
}
.trust__track i { font-style: normal; font-size: 0.85rem; color: var(--accent); opacity: 0.75; }
.trust__track a {
  font-family: var(--serif); font-size: 0.98rem; white-space: nowrap; letter-spacing: 0.02em;
  color: var(--accent);
  border-bottom: 1px solid color-mix(in srgb, var(--accent) 45%, transparent);
  transition: border-color 0.3s var(--ease);
}
.trust__track a:hover { border-color: var(--accent); }
@keyframes trust-drift { to { transform: translateX(calc(-100% / var(--trust-sets, 1))); } }
@media (prefers-reduced-motion: reduce) {
  .trust__track { animation: none; }
}

/* ---------- Полёт чая в корзину ---------- */
.fly-disc {
  position: fixed; z-index: 90; border-radius: 50%;
  pointer-events: none; overflow: hidden;
  display: grid; place-items: center;
}
@keyframes cart-pop {
  0% { transform: scale(1); }
  40% { transform: scale(1.25); }
  100% { transform: scale(1); }
}
.cart-pop { animation: cart-pop 0.45s var(--ease); }

/* =====================================================================
   Категории — кисточные иконки-фильтры
   ===================================================================== */
.cats {
  position: sticky; top: 66px; z-index: 30;
  background: color-mix(in srgb, var(--bg) 90%, transparent);
  backdrop-filter: saturate(150%) blur(14px);
  border-block: 1px solid var(--line);
}
.cats__track {
  max-width: var(--maxw); margin: 0 auto; padding: 14px var(--gutter);
  display: flex; gap: clamp(4px, 1vw, 14px);
  overflow-x: auto; scrollbar-width: none;
}
.cats__track::-webkit-scrollbar { display: none; }
/* по центру, пока есть место; при переполнении — обычный скролл слева */
.cats__track .cat:first-child { margin-left: auto; }
.cats__track .cat:last-child { margin-right: auto; }
.cat {
  flex: 0 0 auto; display: flex; flex-direction: column; align-items: center; gap: 7px;
  padding: 10px 10px 8px; border-radius: var(--radius-s); min-width: 72px;
  color: var(--muted); position: relative;
  transition: color 0.3s var(--ease), background 0.3s var(--ease);
}
.cat:hover { color: var(--text-soft); background: var(--bg-soft); }
.cat.is-active { color: var(--text); }
.cat__ink { width: 52px; height: 38px; display: grid; place-items: center; }
.cat__ink svg { width: 100%; height: 100%; overflow: visible; }
.cat__ink .stroke { fill: currentColor; opacity: 0.4; transition: opacity 0.4s var(--ease), fill 0.4s var(--ease); }
.cat:hover .cat__ink .stroke { opacity: 0.7; }
.cat.is-active .cat__ink .stroke { opacity: 1; fill: var(--accent); }
.cat__label { font-family: var(--sans); font-size: 0.78rem; font-weight: 500; letter-spacing: 0.02em; white-space: nowrap; }
/* [v2-9] кистевой мазок прорисовывается под активной категорией */
.cat__stroke {
  position: absolute; bottom: 1px; left: 50%; transform: translateX(-50%);
  width: 46px; height: 9px; overflow: visible;
}
.cat__stroke path {
  fill: none; stroke: var(--accent); stroke-width: 2.6; stroke-linecap: round;
  stroke-dasharray: 60; stroke-dashoffset: 60; opacity: 0;
  transition: stroke-dashoffset 0.45s var(--ease), opacity 0.15s var(--ease);
}
.cat.is-active .cat__stroke path { stroke-dashoffset: 0; opacity: 0.9; }

/* Подтипы (шу/шэн, ферментация улунов) — вторая строка под категориями */
.subcats { display: flex; gap: 8px; flex-wrap: wrap; padding-top: 2px; padding-bottom: 13px; }
.subcat {
  font-size: 0.78rem; font-weight: 500; padding: 6px 15px; border-radius: 20px;
  border: 1px solid var(--line); color: var(--text-soft);
  transition: all 0.3s var(--ease);
}
.subcat:hover { border-color: var(--text); color: var(--text); }
.subcat.is-active { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }

/* =====================================================================
   Каталог
   ===================================================================== */
/* [v2-2] воздух бутика: реже сетка, больше пауз */
.catalog { padding-block: clamp(40px, 6vw, 84px) clamp(80px, 10vw, 150px); }
.catalog__head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; margin-bottom: clamp(18px, 2.5vw, 30px); }
.catalog__title { font-size: clamp(1.9rem, 4vw, 2.8rem); }
.catalog__count { font-size: 0.85rem; color: var(--muted); }
/* [v2-11] тихий надзаголовок */
.eyebrow {
  display: flex; align-items: center; gap: 14px;
  font-size: 0.64rem; font-weight: 500; letter-spacing: 0.26em; text-transform: uppercase;
  color: var(--muted); margin-bottom: 8px;
}
.eyebrow::after { content: ''; width: 44px; height: 1px; background: var(--line); }
/* [v2-2] волосяная линия с иероглифом между шапкой каталога и сеткой */
.divider { display: flex; align-items: center; gap: 18px; margin-bottom: clamp(26px, 4vw, 46px); }
.divider::before, .divider::after { content: ''; flex: 1; height: 1px; background: var(--line); }
.divider span { font-family: var(--serif); color: var(--muted); font-size: 0.95rem; }

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(268px, 1fr));
  gap: clamp(20px, 3vw, 44px);
}

.tea {
  display: flex; flex-direction: column; align-items: center;
  padding: 26px 20px 22px; border-radius: var(--radius);
  background: var(--card); border: 1px solid var(--line);
  text-align: center; position: relative;
  transition: transform 0.5s var(--ease), box-shadow 0.5s var(--ease), border-color 0.5s var(--ease);
}
.tea:hover { transform: translateY(-5px); box-shadow: var(--shadow); border-color: transparent; }

/* Круглая заглушка под будущее видео «чай крутится по кругу» */
.disc { position: relative; width: 168px; max-width: 62vw; aspect-ratio: 1; margin-bottom: 20px; }
.disc__ring {
  position: absolute; inset: -3px; border-radius: 50%;
  background: conic-gradient(from 0deg, transparent 0 62%, color-mix(in srgb, var(--accent) 55%, transparent) 78%, transparent 92%);
  animation: spin 7s linear infinite; opacity: 0.55;
}
.disc__face {
  position: absolute; inset: 0; border-radius: 50%; overflow: hidden;
  background:
    radial-gradient(120% 120% at 32% 26%, rgba(255,255,255,0.22), transparent 52%),
    radial-gradient(130% 130% at 72% 88%, rgba(0,0,0,0.34), transparent 60%),
    linear-gradient(150deg, var(--brew-a, #5a3a24), var(--brew-b, #8a5a34));
  display: grid; place-items: center;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,0.06);
}
/* Фото товара (нейро/реальное): круглое, тонированное под палитру, поверх заглушки */
.disc__photo {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; border-radius: 50%;
}
.disc__hanzi { font-family: var(--serif); font-size: 2.8rem; color: rgba(255,255,255,0.22); user-select: none; }
/* [v2-6] свет: блик глазурованной пиалы + свеча за диском в тёмной теме */
.disc__face::after {
  content: ''; position: absolute; inset: 0; border-radius: 50%; pointer-events: none;
  background: radial-gradient(88% 55% at 50% 6%, rgba(255,255,255,0.15), transparent 56%);
}
:root[data-theme='dark'] .disc::before {
  content: ''; position: absolute; inset: -16%; border-radius: 50%; pointer-events: none;
  background: radial-gradient(50% 50% at 50% 50%, rgba(199,169,123,0.14), transparent 70%);
}
.tea:hover .disc__ring { animation-duration: 2.4s; opacity: 0.9; }
@keyframes spin { to { transform: rotate(360deg); } }

.tea__name { font-size: 1.4rem; line-height: 1.12; }
/* [v2-3] тип чая — курсивом Cormorant, ниже происхождение и ноты из базы */
.tea__sub { font-family: var(--serif); font-style: italic; font-size: 0.95rem; color: var(--text-soft); margin-top: 5px; letter-spacing: 0.01em; }
.tea__origin { font-size: 0.66rem; font-weight: 500; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); margin-top: 8px; }
.tea__notes { font-size: 0.76rem; color: var(--muted); margin-top: 4px; }
.tea__gram { display: inline-flex; margin-top: 14px; }
.tea__gram select {
  font-family: var(--sans); font-size: 0.82rem; font-weight: 500; color: var(--text);
  background-color: var(--bg-soft); border: 1px solid var(--line); border-radius: var(--radius-pill);
  padding: 7px 32px 7px 16px; cursor: pointer; appearance: none; -webkit-appearance: none;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6' fill='none' stroke='%23948C7A' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'><path d='M1 1l4 4 4-4'/></svg>");
  background-repeat: no-repeat; background-position: right 13px center;
  transition: border-color 0.3s var(--ease);
}
.tea__gram select:hover { border-color: var(--text); }
.tea__gram select:focus-visible { outline: none; border-color: var(--accent); }
/* [v2-13] граммовка чипами — выбор одним касанием, без системного колеса iOS */
.gram-chips { display: inline-flex; gap: 6px; margin-top: 14px; }
.gram-chip {
  font-size: 0.78rem; font-weight: 500; padding: 6px 12px; border-radius: var(--radius-pill);
  border: 1px solid var(--line); color: var(--text-soft);
  transition: all 0.25s var(--ease);
}
.gram-chip:hover { border-color: var(--text); color: var(--text); }
.gram-chip.is-on { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.tea__foot { margin-top: 16px; display: flex; align-items: center; gap: 14px; }
/* [v2-4] цена шёпотом: табличные цифры, тихий знак валюты */
.tea__price { font-family: var(--serif); font-size: 1.35rem; font-variant-numeric: tabular-nums; }
.cur { font-size: 0.68em; color: var(--muted); margin-right: 1px; }
.tea__add {
  width: 40px; height: 40px; border-radius: 50%;
  display: grid; place-items: center; background: var(--accent); color: var(--on-accent);
  transition: transform 0.3s var(--ease), background 0.3s var(--ease);
}
.tea__add svg { width: 18px; height: 18px; }
.tea__add:hover { background: var(--accent-2); transform: scale(1.08); }
.tea__add.is-added { background: var(--clay); }

/* Скидка на товар: бейдж на кружке + зачёркнутая старая цена */
.disc { position: relative; }
/* [v2-4] спокойный бейдж: стеклянный чип с терракотовой обводкой, без наклона и тени */
.sale-badge {
  position: absolute; top: 4%; left: 2%; z-index: 2;
  padding: 4px 10px; border-radius: var(--radius-pill);
  background: color-mix(in srgb, var(--card) 82%, transparent);
  backdrop-filter: blur(5px);
  border: 1px solid var(--clay); color: var(--clay);
  font-size: 0.72rem; font-weight: 600; letter-spacing: 0.04em;
}
.price-old {
  margin-right: 8px; color: var(--muted); font-size: 0.78em; font-weight: 400;
  text-decoration-color: var(--clay); text-decoration-thickness: 1.5px;
}

/* [№9] остатки на витрине */
.stock-badge {
  position: absolute; bottom: 6%; left: 50%; transform: translateX(-50%); z-index: 2;
  padding: 4px 11px; border-radius: var(--radius-pill); white-space: nowrap;
  background: color-mix(in srgb, var(--card) 85%, transparent); backdrop-filter: blur(5px);
  border: 1px solid var(--line); color: var(--muted);
  font-size: 0.68rem; font-weight: 500; letter-spacing: 0.05em;
}
.stock-badge--out { border-color: var(--clay); color: var(--clay); }
.tea.is-out .disc { opacity: 0.55; filter: grayscale(0.5); }
.tea.is-out .tea__add { opacity: 0.4; cursor: default; }
.tea.is-out .tea__add:hover { transform: none; background: var(--accent); }

/* имя товара — ссылка /tea/<id> (SEO), выглядит как обычный текст */
.tea__name a { color: inherit; }

/* Стрелка «в начало» — слева внизу, матовое стекло как у шапки */
.to-top {
  position: fixed; left: clamp(14px, 3vw, 30px); bottom: clamp(14px, 3vw, 30px);
  width: 46px; height: 46px; border-radius: 50%; z-index: 38;
  display: grid; place-items: center; cursor: pointer;
  background: color-mix(in srgb, var(--card) 88%, transparent);
  backdrop-filter: saturate(140%) blur(10px);
  border: 1px solid var(--line); color: var(--text-soft);
  opacity: 0; transform: translateY(8px); pointer-events: none;
  transition: opacity 0.35s var(--ease), transform 0.35s var(--ease),
    color 0.3s var(--ease), border-color 0.3s var(--ease);
}
.to-top.is-on { opacity: 1; transform: none; pointer-events: auto; }
.to-top:hover { color: var(--accent); border-color: var(--accent); }
.to-top svg { width: 18px; height: 18px; }
@media (max-width: 560px) {
  .to-top { width: 42px; height: 42px; bottom: calc(76px + env(safe-area-inset-bottom, 0px)); }
}

/* [v2-28] о доме + вопросы — тихий финальный аккорд перед футером */
.about {
  padding-block: clamp(48px, 8vw, 90px);
  border-top: 1px solid var(--line);
  margin-top: clamp(40px, 7vw, 80px);
}
.about__title {
  font-family: var(--serif); font-weight: 500;
  font-size: clamp(1.6rem, 3.5vw, 2.2rem);
  margin: 10px 0 18px; text-wrap: balance;
}
.about__grid { display: grid; gap: 38px; }
.about__text { max-width: 62ch; color: var(--text-soft); line-height: 1.7; display: grid; gap: 12px; }
.about__addr { font-size: 0.92rem; color: var(--muted); }
.about__addr a { color: var(--accent); border-bottom: 1px solid color-mix(in srgb, var(--accent) 45%, transparent); }
.about__addr a:hover { border-color: var(--accent); }
.faq { max-width: 720px; border-top: 1px solid var(--line); }
/* на широком — журнальная вёрстка: рассказ слева, вопросы справа */
@media (min-width: 920px) {
  .about__grid { grid-template-columns: 5fr 6fr; gap: 72px; align-items: start; }
  .about__text { font-size: 1.02rem; }
}
.faq__item { border-bottom: 1px solid var(--line); }
.faq__item summary {
  cursor: pointer; list-style: none;
  display: flex; justify-content: space-between; align-items: baseline; gap: 16px;
  padding: 16px 0; font-family: var(--serif); font-size: 1.05rem;
  transition: color 0.25s var(--ease);
}
.faq__item summary:hover { color: var(--accent); }
.faq__item summary::-webkit-details-marker { display: none; }
.faq__item summary::after {
  content: '+'; color: var(--accent); font-size: 1.15rem; flex-shrink: 0;
  transition: transform 0.3s var(--ease);
}
.faq__item[open] summary::after { transform: rotate(45deg); }
.faq__item p { color: var(--text-soft); line-height: 1.6; font-size: 0.92rem; padding: 0 0 16px; max-width: 60ch; }

/* категории в футере — тихая перелинковка */
.footer__cats { display: flex; gap: 4px 16px; flex-wrap: wrap; max-width: 480px; }
.footer__cats a {
  font-size: 0.78rem; color: var(--muted);
  border-bottom: 1px solid transparent; padding-bottom: 1px;
  transition: color 0.3s var(--ease), border-color 0.3s var(--ease);
}
.footer__cats a:hover { color: var(--accent); border-color: color-mix(in srgb, var(--accent) 45%, transparent); }

/* «Сообщить о поступлении»: контурный колокольчик на месте корзинки */
.tea__notify {
  width: 40px; height: 40px; border-radius: 50%;
  display: grid; place-items: center;
  border: 1px solid color-mix(in srgb, var(--accent) 55%, transparent);
  color: var(--accent); background: transparent; cursor: pointer;
  transition: background 0.3s var(--ease), color 0.3s var(--ease),
    border-color 0.3s var(--ease), transform 0.3s var(--ease);
}
.tea__notify svg { width: 18px; height: 18px; }
.tea__notify:hover { background: var(--accent); color: var(--on-accent); border-color: var(--accent); transform: scale(1.08); }
.tea__notify:disabled { opacity: 0.55; cursor: default; transform: none; }
.tea__notify.is-on { background: var(--accent); color: var(--on-accent); border-color: var(--accent); }
.tea__notify.is-on:hover { background: var(--accent-2); border-color: var(--accent-2); }
.psheet__notify { display: inline-flex; align-items: center; gap: 8px; }
.psheet__notify svg { width: 16px; height: 16px; flex-shrink: 0; }
.psheet__notify.is-on { background: transparent; color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }

/* =====================================================================
   Плавающие контакты
   ===================================================================== */
.floating {
  position: fixed; right: clamp(14px, 3vw, 30px);
  bottom: calc(clamp(16px, 3vw, 32px) + env(safe-area-inset-bottom, 0px));
  z-index: 45; display: flex; flex-direction: column; gap: 12px; align-items: flex-end;
}
.fc {
  display: flex; flex-direction: row-reverse; align-items: center;
  height: 50px; border-radius: var(--radius-pill); overflow: hidden;
  background: color-mix(in srgb, var(--card) 88%, transparent);
  backdrop-filter: blur(10px);
  border: 1px solid var(--line); box-shadow: var(--shadow-float);   /* [v2-6] */
  transition: border-color 0.35s var(--ease), transform 0.35s var(--ease);
}
.fc:hover { transform: translateY(-2px); }
.fc__icon { width: 50px; height: 50px; display: grid; place-items: center; flex-shrink: 0; }
.fc__icon svg { width: 22px; height: 22px; fill: currentColor; }
.fc__label {
  max-width: 0; opacity: 0; white-space: nowrap; overflow: hidden;
  font-size: 0.82rem; font-weight: 500; letter-spacing: 0.03em;
  transition: max-width 0.4s var(--ease), opacity 0.35s var(--ease), padding 0.4s var(--ease);
}
.fc:hover .fc__label { max-width: 140px; opacity: 1; padding-left: 16px; }
.fc--tg:hover    { border-color: #2AABEE; color: #2AABEE; }
.fc--wa:hover    { border-color: #25D366; color: #25D366; }
.fc--ig:hover    { border-color: #E1306C; color: #E1306C; }
/* [v2-fan-hint] кнопка веера не сливается: фирменный синий самолётик,
   заметная обводка и три точки-намёк «внутри меню» */
.fc--tg[data-fan] { border-color: color-mix(in srgb, #2AABEE 45%, var(--line)); }
.fc--tg[data-fan] .fc__icon { color: #2AABEE; }
/* брендовые цвета в веере и на кнопках: WA зелёный, IG в градиенте (зашит в svg) */
.fc--wa .fc__icon { color: #25D366; }
.tg-fan__icon.tg-fan__icon--wa { color: #25D366; }
.tg-fan__item--wa:hover { border-color: #25D366; }
.tg-fan__item--ig:hover { border-color: #E1306C; }
/* [v2-fix] тач: ховер не залипает после нажатия */
@media (hover: none) {
  .fc:hover { transform: none; }
  .fc:hover .fc__label { max-width: 0; opacity: 0; padding-left: 0; }
  .fc--tg:hover { color: inherit; }
  .fc--tg:hover, .fc--tg[data-fan]:hover { border-color: color-mix(in srgb, #2AABEE 45%, var(--line)); }
  .fc--wa:hover, .fc--ig:hover { border-color: var(--line); color: inherit; }
  .tg-fan__item:hover { border-color: var(--line); transform: none; }
}

/* Веер Telegram: канал / бот / поддержка */
.tg-fan { display: flex; flex-direction: column; gap: 10px; align-items: flex-end; }
.tg-fan__item {
  display: flex; align-items: center;
  height: 46px; border-radius: var(--radius-pill); padding-left: 18px;
  background: color-mix(in srgb, var(--card) 92%, transparent);
  backdrop-filter: blur(10px);
  border: 1px solid var(--line); box-shadow: var(--shadow-float);   /* [v2-6] */
  opacity: 0; transform: translateY(14px) scale(0.95); pointer-events: none;
  transition: opacity 0.28s var(--ease), transform 0.34s var(--ease), border-color 0.3s var(--ease);
}
.tg-fan.is-open .tg-fan__item { opacity: 1; transform: none; pointer-events: auto; }
/* раскрытие от кнопки вверх: нижний пункт первым */
.tg-fan.is-open .tg-fan__item:nth-last-child(2) { transition-delay: 0.05s; }
.tg-fan.is-open .tg-fan__item:nth-last-child(3) { transition-delay: 0.1s; }
.tg-fan__item:hover { border-color: #2AABEE; transform: translateY(-1px); }
.tg-fan__txt { display: flex; flex-direction: column; line-height: 1.3; padding-right: 2px; text-align: right; }
.tg-fan__txt b { font-size: 0.84rem; font-weight: 600; letter-spacing: 0.02em; }
.tg-fan__txt small { font-size: 0.68rem; color: var(--muted); }
.tg-fan__icon { width: 46px; height: 46px; display: grid; place-items: center; color: #2AABEE; flex-shrink: 0; }
.tg-fan__icon svg { width: 20px; height: 20px; }
/* самолётик ⇄ крестик на главной кнопке */
.fc__icon { position: relative; }
.fc__icon svg, .fc__x { transition: opacity 0.28s var(--ease), transform 0.34s var(--ease); }
.fc__x {
  position: absolute; inset: 0; display: grid; place-items: center;
  font-size: 16px; line-height: 1; opacity: 0; transform: rotate(-90deg) scale(0.55);
}
.fc--tg.is-open { border-color: #2AABEE; color: #2AABEE; }
.fc--tg.is-open .fc__icon svg { opacity: 0; transform: rotate(90deg) scale(0.5); }
.fc--tg.is-open .fc__x { opacity: 1; transform: none; }
.fc--tg.is-open .fc__label,
.fc--tg.is-open:hover .fc__label { max-width: 0; opacity: 0; padding-left: 0; }

/* =====================================================================
   Корзина
   ===================================================================== */
.cart-page { padding-block: clamp(30px, 5vw, 60px) clamp(60px, 9vw, 120px); min-height: 62vh; }
.cart-page h1 { font-size: clamp(1.9rem, 4vw, 2.8rem); margin-bottom: clamp(24px, 4vw, 44px); }   /* [v2-11] в одну шкалу с каталогом */
.cart-layout { display: grid; grid-template-columns: 1.6fr 0.9fr; gap: clamp(24px, 4vw, 54px); align-items: start; }
.cart-item { display: grid; grid-template-columns: 78px 1fr auto; gap: 18px; padding: 20px 0; border-bottom: 1px solid var(--line); align-items: center; }
.cart-item:first-child { border-top: 1px solid var(--line); }
.cart-item__media { width: 78px; height: 78px; border-radius: 50%; overflow: hidden; position: relative; }
.cart-item__media .disc__face { position: absolute; inset: 0; }
.cart-item__name { font-family: var(--serif); font-size: 1.3rem; }
.cart-item__sub { font-size: 0.78rem; color: var(--muted); margin-top: 2px; }
.cart-item__ctrls { display: flex; align-items: center; gap: 16px; margin-top: 10px; }
.cart-item__remove { font-size: 0.76rem; color: var(--muted); text-transform: uppercase; letter-spacing: 0.04em; transition: color 0.3s; }
.cart-item__remove:hover { color: var(--clay); }
.cart-item__price { font-family: var(--serif); font-size: 1.3rem; white-space: nowrap; font-variant-numeric: tabular-nums; }   /* [v2-4] */

.qty { display: inline-flex; align-items: center; border: 1px solid var(--line); border-radius: var(--radius-pill); }
.qty button { width: 34px; height: 36px; font-size: 1.1rem; color: var(--text); position: relative; transition: color 0.25s var(--ease); }
.qty button:hover { color: var(--accent); }   /* [v2-19] */
.qty span { min-width: 26px; text-align: center; font-family: var(--serif); font-size: 1.05rem; }

.summary { background: var(--bg-soft); border: 1px solid var(--line); border-radius: var(--radius); padding: clamp(22px, 3vw, 32px); position: sticky; top: 90px; }
.summary h3 { font-size: 1.5rem; margin-bottom: 18px; }
.summary__row { display: flex; justify-content: space-between; padding: 10px 0; color: var(--text-soft); font-size: 0.92rem; font-variant-numeric: tabular-nums; }   /* [v2-4] */
.summary__row--total { border-top: 1px solid var(--line); margin-top: 6px; padding-top: 18px; color: var(--text); }
.summary__row--total .v { font-family: var(--serif); font-size: 1.7rem; font-variant-numeric: tabular-nums; }
.summary .btn { margin-top: 20px; }
/* Прогресс до бесплатной доставки */
.ship-progress { margin: 12px 0 4px; }
.ship-progress__track { height: 5px; border-radius: 5px; background: var(--line); overflow: hidden; }
.ship-progress__fill { height: 100%; border-radius: 5px; background: var(--accent); transition: width 0.5s var(--ease); }
.ship-progress__label { font-size: 0.78rem; color: var(--text-soft); margin-top: 7px; }
.ship-progress.is-done .ship-progress__label { color: var(--accent); font-weight: 500; }

/* Пробники в подарок */
.samples { margin: 12px 0 4px; padding: 13px 14px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-s); }
.samples__title { font-size: 0.85rem; font-weight: 500; }
.samples__title span { font-weight: 400; font-size: 0.74rem; color: var(--muted); margin-left: 4px; }
.samples__chips { display: flex; flex-wrap: wrap; gap: 7px; margin-top: 10px; }
.sample-chip {
  font-size: 0.78rem; padding: 6px 13px; border-radius: 20px;
  border: 1px solid var(--line); color: var(--text-soft);
  transition: all 0.25s var(--ease);
}
.sample-chip:hover { border-color: var(--text); color: var(--text); }
.sample-chip.is-on { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }

/* Мои заказы в кабинете */
.acc-orders { margin-top: 18px; }
.acc-orders__title { font-family: var(--serif); font-size: 1.15rem; margin-bottom: 10px; }
.acc-orders__list { display: flex; flex-direction: column; gap: 9px; max-height: 240px; overflow-y: auto; }
.acc-orders__empty { font-size: 0.84rem; color: var(--muted); }
.acc-order { border: 1px solid var(--line); border-radius: var(--radius-s); padding: 11px 13px; }
.acc-order__top { font-size: 0.84rem; display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.acc-status { font-size: 0.68rem; font-weight: 500; padding: 2px 9px; border-radius: var(--radius-s); background: var(--bg-soft); color: var(--text-soft); margin-left: auto; }
.acc-status--paid, .acc-status--done { background: color-mix(in srgb, var(--accent) 18%, transparent); color: var(--accent); }
.acc-status--cancelled { opacity: 0.6; text-decoration: line-through; }
.acc-order__items { font-size: 0.76rem; color: var(--muted); margin-top: 4px; line-height: 1.4; }
.acc-order__more {
  background: none; border: 0; padding: 2px 4px; font: inherit; font-size: inherit;
  color: var(--accent); white-space: nowrap; cursor: pointer;
  text-decoration: underline dotted; text-underline-offset: 3px;
}
.acc-order__more:hover { color: var(--accent-2); }
.acc-order__bottom { display: flex; align-items: center; justify-content: space-between; margin-top: 8px; }
.acc-order__bottom > span { font-family: var(--serif); font-size: 1.05rem; }
.acc-order__repeat {
  font-size: 0.74rem; font-weight: 500; padding: 5px 13px; border-radius: var(--radius-pill);
  border: 1px solid var(--line); color: var(--text-soft); transition: all 0.25s var(--ease);
}
.acc-order__repeat:hover { border-color: var(--accent); color: var(--accent); }

.summary__balance {
  display: flex; align-items: flex-start; gap: 10px; cursor: pointer;
  padding: 12px 14px; margin: 10px 0 4px;
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-s);
  font-size: 0.85rem; line-height: 1.4; color: var(--text-soft);
  transition: border-color 0.3s var(--ease);
}
.summary__balance:hover { border-color: var(--accent); }
.summary__balance input { accent-color: var(--accent); width: 16px; height: 16px; margin-top: 2px; flex-shrink: 0; cursor: pointer; }
.summary__balance b { font-weight: 500; color: var(--text); }
.summary__row--discount { color: var(--clay); }

.empty { text-align: center; padding: clamp(50px, 9vw, 100px) 0; }
.success-actions { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; margin-top: 6px; }
.empty .promo__later { display: inline-block; width: auto; margin-top: 18px; }
.empty__mark { font-family: var(--serif); font-size: 3.4rem; color: var(--line); }
.empty h2 { font-size: 1.7rem; margin: 14px 0 10px; }
.empty p { color: var(--text-soft); margin-bottom: 24px; }

/* =====================================================================
   Футер (минимальный)
   ===================================================================== */
.footer { border-top: 1px solid var(--line); padding-block: clamp(30px, 4vw, 48px); }
.footer__inner { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 16px; }
.footer__note { font-size: 0.82rem; color: var(--muted); }

/* ---------- Избранное на карточке ---------- */
.tea__fav {
  position: absolute; top: 10px; right: 10px; z-index: 2;
  width: 38px; height: 38px; border-radius: 50%;
  display: grid; place-items: center; color: var(--muted);
  transition: color 0.3s var(--ease), transform 0.3s var(--ease);
}
.tea__fav:hover { color: var(--clay); transform: scale(1.12); }
.tea__fav.is-active { color: var(--clay); }
.tea__fav svg { width: 19px; height: 19px; }
.fav-btn.is-active { border-color: var(--clay); color: var(--clay); }

/* ---------- Инструменты каталога ---------- */
.catalog__head { flex-wrap: wrap; row-gap: 12px; }
.catalog__tools { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.tool-input {
  font-family: var(--sans); font-size: 1rem; color: var(--text);   /* [v2-21] */
  background-color: var(--card); border: 1px solid var(--line); border-radius: var(--radius-pill);
  padding: 8px 16px; transition: border-color 0.3s var(--ease);
}
.tool-input:focus-visible { outline: none; border-color: var(--accent); }
.tool-input::placeholder { color: var(--muted); }
.tool-input--search { width: 170px; }
select.tool-input {
  appearance: none; -webkit-appearance: none; cursor: pointer; padding-right: 34px;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6' fill='none' stroke='%23948C7A' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'><path d='M1 1l4 4 4-4'/></svg>");
  background-repeat: no-repeat; background-position: right 14px center;
}
.grid-empty { grid-column: 1 / -1; text-align: center; color: var(--muted); padding: 60px 0; font-size: 0.95rem; }
.grid-empty .btn { margin-top: 20px; }

/* Выход из «Избранного» */
.catalog__titlerow { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.fav-exit {
  font-size: 0.78rem; font-weight: 500; padding: 7px 15px; border-radius: 20px;
  border: 1px solid var(--line); color: var(--text-soft);
  transition: all 0.3s var(--ease);
}
.fav-exit:hover { border-color: var(--text); color: var(--text); }

/* ---------- Форма заказа ---------- */
.summary form { display: flex; flex-direction: column; gap: 10px; margin-top: 20px; }
.field {
  font-family: var(--sans); font-size: 1rem; color: var(--text);   /* [v2-21] 16px всегда — iOS не зумит */
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-s);
  padding: 11px 14px; resize: none; transition: border-color 0.3s var(--ease);
}
.field:focus-visible { outline: none; border-color: var(--accent); }
.field::placeholder { color: var(--muted); }
.field.is-error { border-color: #B4533A; }
.summary form .btn { margin-top: 6px; }
.summary__note { font-size: 0.78rem; color: var(--muted); margin-top: 14px; text-align: center; }

/* ---------- Валюта ---------- */
.currency-toggle [data-currency-symbol] { font-family: var(--serif); font-size: 1.1rem; line-height: 1; }

/* ---------- Модальные окна ---------- */
.modal-backdrop {
  position: fixed; inset: 0; z-index: 80;
  background: rgba(22, 18, 12, 0.45); backdrop-filter: blur(7px);
  display: grid; place-items: center; padding: 20px;
  opacity: 0; transition: opacity 0.35s var(--ease);
}
.modal-backdrop.is-open { opacity: 1; }
.modal {
  position: relative; width: 100%; max-width: 420px;
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-m);
  padding: 50px 28px 26px;   /* сверху место под крестик — он не наезжает на контент */
  box-shadow: var(--shadow);
  /* [v2-21] dvh — не выползает за клавиатуру/бары iOS */
  max-height: min(88vh, 88dvh); overflow: auto; overscroll-behavior: contain;
  transform: translateY(16px) scale(0.985);
  transition: transform 0.4s var(--ease);
}
.modal-backdrop.is-open .modal { transform: none; }
.modal__close {
  position: absolute; top: 12px; right: 14px;
  width: 36px; height: 36px; border-radius: 50%;
  font-family: var(--serif); font-size: 1.15rem; color: var(--muted);
  transition: color 0.3s var(--ease);
}
.modal__close:hover { color: var(--text); }

/* Промо рефералки */
.promo__hanzi { font-family: var(--serif); font-size: 2.6rem; color: var(--accent); line-height: 1; margin-bottom: 14px; }
.promo__eyebrow { font-size: 0.66rem; letter-spacing: 0.24em; text-transform: uppercase; color: var(--muted); margin-bottom: 10px; }
.promo__title { font-size: 1.65rem; line-height: 1.15; margin-bottom: 8px; }
.promo__title em { font-style: italic; color: var(--accent); }
.promo__steps { display: flex; flex-direction: column; gap: 12px; margin: 20px 0 24px; }
.promo__step { display: flex; gap: 14px; align-items: baseline; font-size: 0.9rem; color: var(--text-soft); line-height: 1.45; }
.promo__step b { font-family: var(--serif); font-weight: 600; color: var(--clay); flex-shrink: 0; }
.promo__later { width: 100%; margin-top: 12px; padding: 8px; font-size: 0.8rem; color: var(--muted); transition: color 0.3s var(--ease); }
.promo__later:hover { color: var(--text); }

/* Вход / регистрация */
.auth__tabs { display: flex; gap: 8px; margin-bottom: 18px; }
.auth__tab { flex: 1; font-size: 0.85rem; font-weight: 500; padding: 9px; border-radius: var(--radius-pill); border: 1px solid var(--line); color: var(--text-soft); transition: all 0.3s var(--ease); }
.auth__tab.is-active { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.auth form { display: flex; flex-direction: column; gap: 10px; }
.auth__note { font-size: 0.76rem; color: var(--muted); margin-top: 16px; text-align: center; line-height: 1.5; }
.auth__google { display: flex; justify-content: center; min-height: 44px; margin-bottom: 10px; }

/* Своя соц-кнопка в стиле сайта */
.social-btn {
  width: 100%; height: 46px; margin-bottom: 10px;
  display: flex; align-items: center; justify-content: center; gap: 10px;
  font-size: 0.88rem; font-weight: 500; color: var(--text);
  border: 1px solid var(--line); border-radius: var(--radius-pill); background: var(--bg-soft);
  transition: border-color 0.3s var(--ease), transform 0.3s var(--ease);
}
.social-btn:hover { border-color: var(--accent); transform: translateY(-1px); }
.social-btn__icon { display: grid; place-items: center; }
.social-btn--tg .social-btn__icon { color: #2AABEE; }
.social-btn__icon svg { width: 19px; height: 19px; fill: currentColor; }
.auth__divider { display: flex; align-items: center; gap: 12px; margin: 12px 0; color: var(--muted); font-size: 0.74rem; letter-spacing: 0.1em; text-transform: uppercase; }
.auth__divider::before, .auth__divider::after { content: ''; flex: 1; height: 1px; background: var(--line); }

/* Профиль */
.account__balance { display: flex; gap: 10px; margin: 18px 0 14px; }
.acc-metric { flex: 1; background: var(--bg-soft); border: 1px solid var(--line); border-radius: var(--radius-s); padding: 12px 8px; text-align: center; }
.acc-metric .v { font-family: var(--serif); font-size: 1.35rem; line-height: 1.1; }
.acc-metric .l { font-size: 0.64rem; color: var(--muted); letter-spacing: 0.06em; text-transform: uppercase; margin-top: 4px; }
.account__how {
  display: flex; flex-direction: column; gap: 7px;
  font-size: 0.85rem; color: var(--text-soft); line-height: 1.45; margin-bottom: 14px;
}
.account__how span { display: flex; align-items: baseline; gap: 10px; }
.account__how b { font-weight: 600; color: var(--text); white-space: nowrap; min-width: 92px; }
/* Промокод в корзине */
.promo-form { display: flex; gap: 8px; margin-top: 12px; }
.promo-form .field { flex: 1; min-width: 0; }
.promo-form button {
  flex-shrink: 0; padding: 0 16px; border: 1px solid var(--line); border-radius: var(--radius-pill);   /* [v2-22] в форму чипов */
  font-size: 0.8rem; color: var(--text-soft);
  transition: border-color 0.3s var(--ease), color 0.3s var(--ease);
}
.promo-form button:hover { border-color: var(--accent); color: var(--text); }
.promo-line__x { margin-left: 8px; color: var(--muted); font-size: 0.78rem; vertical-align: 1px; }
.promo-line__x:hover { color: var(--clay); }
.promo-line--warn {
  display: flex; justify-content: space-between; align-items: center;
  margin-top: 10px; font-size: 0.8rem; color: var(--clay);
}

.ref-box { display: flex; gap: 8px; align-items: stretch; }
.ref-box .field { flex: 1; font-size: 0.82rem; color: var(--text-soft); }
.ref-box .icon-btn { width: 46px; height: auto; border-radius: var(--radius-s); flex-shrink: 0; }
.user-btn.is-auth { border-color: var(--accent); color: var(--accent); }

/* ---------- [v2-26] Лента листьев для гостей — статичная, сразу под шапкой ---------- */
.leaf-ribbon {
  border-bottom: 1px solid var(--line);
  background: color-mix(in srgb, var(--accent) 7%, var(--bg));
  transition: opacity 0.45s var(--ease);
}
.leaf-ribbon.is-gone { opacity: 0; }
.leaf-ribbon__inner { display: flex; align-items: center; gap: 16px; padding-block: 12px; }
.leaf-ribbon__hanzi { font-family: var(--serif); font-size: 1.6rem; color: var(--accent); line-height: 1; flex-shrink: 0; }
.leaf-ribbon__text { flex: 1; font-size: 0.88rem; line-height: 1.45; min-width: 0; }
.leaf-ribbon__text b { font-family: var(--serif); font-weight: 500; letter-spacing: 0.01em; }
.leaf-ribbon__text span { display: block; color: var(--text-soft); font-size: 0.8rem; }
.leaf-ribbon__cta {
  display: inline-flex; align-items: center; gap: 8px; flex-shrink: 0;
  padding: 0.62em 1.3em; border-radius: var(--radius-pill);
  border: 1px solid color-mix(in srgb, var(--accent) 55%, transparent);
  color: var(--accent); background: transparent;
  font-size: 0.78rem; letter-spacing: 0.06em; text-transform: uppercase;
  cursor: pointer;
  transition: background 0.3s var(--ease), color 0.3s var(--ease), border-color 0.3s var(--ease);
}
.leaf-ribbon__cta:hover { background: var(--accent); color: var(--bg); border-color: var(--accent); }
.leaf-ribbon__cta:disabled { opacity: 0.6; cursor: default; }
.leaf-ribbon__cta .social-btn__icon { display: inline-flex; width: 16px; height: 16px; flex-shrink: 0; }
.leaf-ribbon__cta .social-btn__icon svg { width: 100%; height: 100%; }
@media (max-width: 560px) {
  /* двухэтажная раскладка: текст целиком, ниже — кнопка во всю ширину */
  .leaf-ribbon__inner { flex-wrap: wrap; gap: 8px 12px; padding-block: 12px; }
  .leaf-ribbon__hanzi { display: none; }
  .leaf-ribbon__text { flex: 1 1 100%; font-size: 0.84rem; }
  .leaf-ribbon__text span { font-size: 0.76rem; margin-top: 2px; }
  .leaf-ribbon__cta { flex: 1 1 100%; justify-content: center; padding-block: 0.8em; }
}

/* ---------- Тост ---------- */
.toast {
  position: fixed; left: 50%; bottom: 28px; transform: translateX(-50%) translateY(24px);
  background: var(--text); color: var(--bg); padding: 13px 24px; border-radius: var(--radius-pill);
  font-size: 0.88rem; z-index: 100; opacity: 0; pointer-events: none;
  display: flex; align-items: center; gap: 10px; box-shadow: 0 18px 36px -18px rgba(0,0,0,0.55);
  transition: opacity 0.4s var(--ease), transform 0.4s var(--ease);
}
.toast.is-show { opacity: 1; transform: translateX(-50%) translateY(0); }
.toast__dot { width: 7px; height: 7px; border-radius: 50%; background: var(--accent); }

/* ---------- Reveal ---------- */
.reveal { opacity: 0; transform: translateY(14px); transition: opacity 0.7s var(--ease), transform 0.7s var(--ease); }   /* [v2-12] */
.reveal.is-in { opacity: 1; transform: none; }

/* [v2-5] мягкий кроссфейд между страницами (прогрессивное улучшение) */
@view-transition { navigation: auto; }
::view-transition-old(root), ::view-transition-new(root) { animation-duration: 0.24s; }
.header { view-transition-name: site-header; }

/* ТГ-вебвью: без овер-скролла — резинка у краёв дёргает шторку браузера;
   страница всегда чуть длиннее экрана, чтобы был запас для скролла с 1px */
html.tg-webview, html.tg-webview body { overscroll-behavior-y: none; }
html.tg-webview body { min-height: calc(100vh + 2px); }
/* и ничего прилипшего: в тг-вебвью верх лейаут-вьюпорта гуляет вместе с
   плашкой телеграма — любой sticky-элемент оставляет над собой «пустоту».
   Шапка и категории просто скроллятся со страницей как обычный контент. */
html.tg-webview .header { position: static; }
html.tg-webview .cats { position: static; top: auto; transition: none; }

/* [v2-8] смена темы — капля туши из кнопки */
html.theme-vt .header { view-transition-name: none; }
html.theme-vt::view-transition-old(root) { animation: none; }
html.theme-vt::view-transition-new(root) { animation: ink-in 0.55s var(--ease) forwards; }
@keyframes ink-in {
  from { clip-path: circle(0 at var(--ink-x, 50%) var(--ink-y, 50%)); }
  to { clip-path: circle(142vmax at var(--ink-x, 50%) var(--ink-y, 50%)); }
}

/* [v2-12] фон едва дрейфует при скролле */
@supports (animation-timeline: scroll()) {
  .bg-art { animation: bg-drift linear both; animation-timeline: scroll(); }
}
@keyframes bg-drift { from { transform: translateY(0); } to { transform: translateY(-3.5%); } }

/* [v2-23] иероглифы и кистевой лист вместо системных эмодзи */
.hanzi-mark { font-family: var(--serif); color: var(--accent); margin-right: 2px; }
.leaf-ic { display: inline-block; vertical-align: -2px; color: var(--accent); }
.leaf-ic svg { display: inline-block; width: 13px; height: 13px; }

/* [v2-27] чип кешбэка листьями возле цены */
.leaf-back {
  display: inline-flex; align-items: center; gap: 3px; vertical-align: middle;
  margin-left: 8px; padding: 2px 9px; border-radius: var(--radius-pill);
  border: 1px dashed color-mix(in srgb, var(--accent) 45%, transparent);
  color: var(--accent); background: transparent;
  font-size: 0.72rem; letter-spacing: 0.03em; cursor: pointer;
  transition: background 0.3s var(--ease), border-color 0.3s var(--ease);
}
.leaf-back:hover { background: color-mix(in srgb, var(--accent) 12%, transparent); border-color: var(--accent); }
.leaf-back .leaf-ic svg { width: 11px; height: 11px; }

/* [v2-25] футер: средний столбец тихих ссылок */
.footer__links { display: flex; gap: clamp(14px, 3vw, 26px); flex-wrap: wrap; }
.footer__links a {
  font-size: 0.82rem; color: var(--muted);
  border-bottom: 1px solid transparent; padding-bottom: 1px;
  transition: color 0.3s var(--ease), border-color 0.3s var(--ease);
}
.footer__links a:hover { color: var(--text); border-color: var(--line); }

/* [v2-10] церемония: печать-иньчжан на экране «заказ принят» */
.seal {
  width: 76px; height: 76px; margin: 16px auto 6px;
  display: grid; place-items: center;
  border: 2.5px solid #A3402F; border-radius: 10px;
  color: #A3402F; font-family: var(--serif); font-weight: 600; font-size: 1.2rem;
  transform: rotate(-3deg);
  box-shadow: inset 0 0 0 1.5px color-mix(in srgb, #A3402F 30%, transparent);
  font-variant-numeric: tabular-nums;
}
:root[data-theme='dark'] .seal { border-color: #C25844; color: #C25844; box-shadow: inset 0 0 0 1.5px color-mix(in srgb, #C25844 30%, transparent); }
.ceremony__tip {
  max-width: 420px; margin: 16px auto 0;
  font-family: var(--serif); font-style: italic; font-size: 0.98rem; line-height: 1.5;
  color: var(--muted);
}

/* [v2-15] тихая страница чая — «лист» поверх каталога */
.psheet {
  position: fixed; inset: 0; z-index: 70; overflow-y: auto; overscroll-behavior: contain;
  background: color-mix(in srgb, var(--bg) 96%, transparent);
  backdrop-filter: saturate(140%) blur(18px);
  opacity: 0; transition: opacity 0.35s var(--ease);
}
.psheet.is-open { opacity: 1; }
.psheet__close {
  position: fixed; top: 16px; right: 18px; z-index: 2;
  width: 44px; height: 44px; border-radius: 50%;
  border: 1px solid var(--line); background: color-mix(in srgb, var(--card) 80%, transparent);
  font-family: var(--serif); font-size: 1.2rem; color: var(--muted);
  transition: color 0.3s var(--ease), border-color 0.3s var(--ease);
}
.psheet__close:hover { color: var(--text); border-color: var(--text); }
.psheet__inner {
  display: grid; grid-template-columns: minmax(280px, 1fr) 1.15fr;
  gap: clamp(28px, 6vw, 84px); align-items: center;
  min-height: 100%; padding-block: clamp(60px, 9vh, 100px);
}
.psheet__media .disc { width: min(380px, 68vw); margin: 0 auto; }
.psheet__media .disc__hanzi { font-size: clamp(3.4rem, 8vw, 5.6rem); }
.psheet__info { position: relative; isolation: isolate; max-width: 560px; }
.psheet__hanzi {
  position: absolute; top: -0.55em; right: -0.1em; z-index: -1;
  font-family: var(--serif); font-size: clamp(6rem, 14vw, 11rem); line-height: 1;
  color: var(--motif); opacity: 0.07; user-select: none; pointer-events: none;
}
.psheet__eyebrow { font-size: 0.64rem; font-weight: 500; letter-spacing: 0.26em; text-transform: uppercase; color: var(--muted); margin-bottom: 12px; }
.psheet__name { font-size: clamp(2.1rem, 4.5vw, 3.2rem); }
.psheet__subtitle { font-family: var(--serif); font-style: italic; font-size: 1.05rem; color: var(--text-soft); margin-top: 8px; }
.psheet__story { font-family: var(--serif); font-size: 1.06rem; line-height: 1.6; color: var(--text-soft); margin-top: 18px; }
.psheet__facts { margin-top: 24px; border-top: 1px solid var(--line); }
.psheet__facts > div {
  display: flex; justify-content: space-between; gap: 24px;
  padding: 10px 2px; border-bottom: 1px solid var(--line); font-size: 0.85rem;
}
.psheet__facts dt { color: var(--muted); }
.psheet__facts dd { text-align: right; color: var(--text-soft); }
/* [v2-16] живой диск: видео поверх заглушки, тонированное под палитру */
.disc__video {
  position: absolute; inset: 0; width: 100%; height: 100%;
  object-fit: cover; border-radius: 50%;
  opacity: 0; transition: opacity 0.6s var(--ease);
}
.disc__face.is-live .disc__video { opacity: 1; }
.media-toned { filter: sepia(0.18) saturate(0.82) contrast(0.98) brightness(0.97); }

/* [v2-17] карта происхождения: контур Китая кистью + пульс золотой точки */
.psheet__map { position: relative; display: inline-block; margin-top: 26px; }
.psheet__map svg { width: min(320px, 76vw); color: var(--khaki); opacity: 0.6; }
:root[data-theme='dark'] .psheet__map svg { opacity: 0.45; }
.psheet__map-dot {
  position: absolute; width: 8px; height: 8px; border-radius: 50%;
  background: var(--accent); transform: translate(-50%, -50%);
  box-shadow: 0 0 10px color-mix(in srgb, var(--accent) 55%, transparent);
}
.psheet__map-dot::after {
  content: ''; position: absolute; inset: -6px; border-radius: 50%;
  border: 1px solid var(--accent);
  animation: map-pulse 2.4s var(--ease) infinite;
}
@keyframes map-pulse {
  0% { transform: scale(0.45); opacity: 0.9; }
  100% { transform: scale(1.7); opacity: 0; }
}
.psheet__map-note {
  position: absolute; left: 4px; bottom: 2px;
  font-size: 0.7rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted);
}

.psheet__buy { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; margin-top: 26px; }
.psheet__buy .gram-chips { margin-top: 0; }
.psheet__price { font-family: var(--serif); font-size: 1.7rem; font-variant-numeric: tabular-nums; margin-left: auto; }
@media (max-width: 860px) {
  .psheet__inner { grid-template-columns: 1fr; align-items: start; gap: 30px; padding-top: 76px; }
  .psheet__price { margin-left: 0; }
}

/* [v2-14] нижняя таб-панель на мобиле */
.tabbar { display: none; }

/* [v2-20] шапка прячется при скролле вниз — экрану возвращается контент */
.header { transition: border-color 0.4s var(--ease), transform 0.45s var(--ease); }
.cats { transition: top 0.45s var(--ease); }
html.hdr-hide .header { transform: translateY(-100%); }
html.hdr-hide .cats { top: 0; }

/* [v2-18] тач-цели: невидимое расширение зоны нажатия */
@media (pointer: coarse) {
  .qty button::after { content: ''; position: absolute; inset: -8px -2px; }
  .cart-item__remove { position: relative; }
  .cart-item__remove::after,
  .modal__close::after,
  .promo-line__x::after,
  .leaf-back::after,
  .acc-order__more::after { content: ''; position: absolute; inset: -8px; }
  .modal__close, .promo-line__x, .leaf-back, .acc-order__more { position: relative; }
  .tea__add, .tea__notify { width: 44px; height: 44px; }
}

/* =====================================================================
   Адаптив
   ===================================================================== */
@media (max-width: 860px) {
  .cart-layout { grid-template-columns: 1fr; }
  .summary { position: relative; top: 0; }
}
/* [v2-20] WA и IG уезжают в веер TG-кнопки — остаётся одна плавающая */
@media (max-width: 700px) {
  .fc--wa, .fc--ig { display: none; }
  /* сплит-иконке чуть больше места, чтобы оба логотипа читались */
  .fc--tg[data-fan] .fc__icon svg { width: 24px; height: 24px; }
}
@media (max-width: 560px) {
  /* крупное имя + микро-тэглайн одной строкой под ним
     (absolute — не распирает шапку по ширине) */
  .brand__mark { font-size: clamp(1.3rem, 5.5vw, 1.9rem); }
  .brand__name { font-size: clamp(0.98rem, 4.6vw, 1.35rem); letter-spacing: 0.08em; }
  .brand__text { position: relative; }
  .brand__tag {
    position: absolute; top: 100%; left: 1px; margin-top: 8px;
    font-size: 0.5rem; letter-spacing: 0.06em; white-space: nowrap;
  }
  .header__actions { gap: 5px; }
  .icon-btn { width: 37px; height: 37px; }
  .tool-input--search { width: 100%; }
  /* 16px в полях — iOS не зумит страницу при фокусе */
  .tool-input, .field, .tea__gram select { font-size: 16px; }
  /* иероглифы не упираются в края маленького кружка */
  .disc__hanzi { font-size: 2.1rem; }
  /* подпись цитаты мельче самой цитаты */
  .quote__author { font-size: 0.66rem; letter-spacing: 0.1em; margin-top: 12px; }
  /* плавающие контакты компактнее и деликатнее */
  .fc { height: 40px; opacity: 0.88; }
  .fc__icon { width: 40px; height: 40px; }
  .fc__icon svg { width: 19px; height: 19px; }
  .floating { gap: 9px; }
  .tg-fan { gap: 8px; }
  .tg-fan__item { height: 42px; padding-left: 15px; }
  .tg-fan__icon { width: 42px; height: 42px; }
  .tg-fan__icon svg { width: 18px; height: 18px; }
  .grid { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .tea { padding: 18px 12px 16px; }
  .disc { width: 130px; }
  .tea__name { font-size: 1.2rem; }
  .cart-item { grid-template-columns: 60px 1fr; }
  .cart-item__price { grid-column: 2; text-align: left; }
  .cart-item__media { width: 60px; height: 60px; }

  /* [v2-14] нижняя таб-панель: главные действия в зоне большого пальца */
  .tabbar {
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 46;
    display: grid; grid-template-columns: repeat(3, 1fr);
    padding-bottom: env(safe-area-inset-bottom, 0px);
    background: color-mix(in srgb, var(--bg) 88%, transparent);
    backdrop-filter: saturate(150%) blur(16px);
    border-top: 1px solid var(--line);
  }
  .tabbar__item {
    position: relative; display: flex; flex-direction: column; align-items: center; gap: 3px;
    padding: 9px 4px 10px; font-size: 0.62rem; letter-spacing: 0.04em; color: var(--muted);
  }
  .tabbar__item.is-active { color: var(--accent); }
  .tabbar__item.is-active::after {
    content: ''; position: absolute; top: 0; left: 50%; transform: translateX(-50%);
    width: 22px; height: 2px; border-radius: 2px; background: var(--accent);
  }
  .tabbar__item svg { width: 20px; height: 20px; }
  .tabbar__hanzi { font-family: var(--serif); font-size: 1.2rem; line-height: 1; padding-top: 1px; }
  .tabbar__item .cart-count { position: absolute; top: 4px; left: calc(50% + 7px); }
  body { padding-bottom: calc(64px + env(safe-area-inset-bottom, 0px)); }
  .floating { bottom: calc(76px + env(safe-area-inset-bottom, 0px)); }
  .toast { bottom: calc(76px + env(safe-area-inset-bottom, 0px)); }
  /* дубли избранного и корзины из шапки — теперь в таб-баре */
  .header .fav-btn, .header a.icon-btn[href='cart.html'] { display: none; }

}
@media (max-width: 480px) {
  /* [v2-18] кнопки не мельче 40px и не слипаются — дубли ушли в таб-бар */
  .brand { gap: 8px; }
  .header__actions { gap: 6px; }
  .icon-btn { width: 40px; height: 40px; }
  .icon-btn svg { width: 18px; height: 18px; }
  .currency-toggle [data-currency-symbol] { font-size: 0.95rem; }
}
@media (max-width: 350px) {
  /* только на совсем крошечных экранах жертвуем названием */
  .brand__name { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
  .reveal { opacity: 1; transform: none; }
  .disc__ring { display: none; }
}
