/* ==========================================================================
   4BREWERS — демо-витрина. Направление: «тап-лист» — тёмная стойка бара,
   белые «подставки» под фото, фирменный жёлтый как маркер действия.
   Mobile-first. Шрифты: Alumni Sans (дисплей) + Golos Text (текст).
   ========================================================================== */

:root {
  --bg: #151311;
  --bg-2: #1d1a17;
  --bg-3: #272320;
  --bg-4: #332e29;
  --line: rgba(255, 255, 255, .08);
  --line-2: rgba(255, 255, 255, .16);
  --fg: #f5f0e7;
  --fg-2: #b6ada1;
  --fg-3: #7f776d;
  --brand: #FEC12B;
  --brand-2: #ffd45e;
  --brand-ink: #1b1500;
  --sale: #ff5c6c;
  --warm: #ff8a3a;
  --low: #ffb454;
  --white: #ffffff;
  --r: 16px;
  --r-s: 10px;
  --f-display: "Alumni Sans", "Arial Narrow", "Helvetica Neue", sans-serif;
  --f-body: "Golos Text", system-ui, -apple-system, "Segoe UI", sans-serif;
  --ease: cubic-bezier(.2, .8, .2, 1);
  --shadow: 0 18px 50px rgba(0, 0, 0, .55);
  --bar-h: 88px;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100dvh;
  background: var(--bg);
  color: var(--fg);
  font: 400 14px/1.4 var(--f-body);
  font-feature-settings: "tnum" 1;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  padding-bottom: env(safe-area-inset-bottom);
  transition: padding-bottom .3s;
}
body.has-order { padding-bottom: calc(var(--bar-h) + env(safe-area-inset-bottom)); }
body.no-scroll { overflow: hidden; }

/* атмосфера: тёплый свет над стойкой + зерно */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background:
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 .07 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E"),
    radial-gradient(70% 45% at 15% -5%, rgba(254, 193, 43, .18), transparent 65%),
    radial-gradient(50% 35% at 100% 0%, rgba(255, 138, 58, .08), transparent 60%),
    var(--bg);
}

img { max-width: 100%; }
button { font: inherit; color: inherit; cursor: pointer; }
button, input { -webkit-tap-highlight-color: transparent; }
a { color: inherit; }
b, strong { font-weight: 700; }
svg { display: block; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }
::selection { background: var(--brand); color: var(--brand-ink); }

.wrap {
  width: 100%;
  max-width: 1480px;
  margin-inline: auto;
  padding-inline: max(14px, env(safe-area-inset-left)) max(14px, env(safe-area-inset-right));
}

/* расширяем область касания у мелких элементов до 44px */
.hit { position: relative; }
.hit::before { content: ""; position: absolute; inset: -6px; }

/* --------------------------------------------------------------------------
   Шапка
   -------------------------------------------------------------------------- */
.hdr {
  position: relative;
  z-index: 30;
  border-bottom: 1px solid var(--line);
  background: color-mix(in srgb, var(--bg) 86%, transparent);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}
.hdr__in { display: flex; align-items: center; gap: 10px; min-height: 58px; }
.hdr__logo { display: block; flex: 0 0 auto; }
.hdr__logo img { display: block; height: 22px; width: auto; }
.hdr__nav { display: none; }
.hdr__who {
  margin-left: auto;
  min-width: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  line-height: 1.15;
  text-align: right;
}
.hdr__company { font-weight: 600; font-size: 12px; max-width: 100%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hdr__dept { font-size: 11px; color: var(--fg-2); max-width: 100%; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hdr__burger, .iconbtn {
  width: 44px; height: 44px;
  display: inline-flex; align-items: center; justify-content: center;
  border: 0; border-radius: 12px;
  background: var(--bg-3); color: var(--fg);
  flex: 0 0 auto;
}
.hdr__burger svg, .iconbtn svg { width: 22px; height: 22px; }
.hdr__burger:hover, .iconbtn:hover { background: var(--bg-4); }

.demo-mark { position: relative; }
.demo-mark__btn {
  font: 800 10px/1 var(--f-body);
  letter-spacing: .14em;
  padding: 6px 7px 5px;
  border: 1.5px solid var(--brand);
  color: var(--brand);
  background: transparent;
  border-radius: 6px;
  transform: rotate(-4deg);
}
.demo-mark__btn[aria-expanded="true"] { background: var(--brand); color: var(--brand-ink); }
.demo-mark__pop {
  position: absolute; top: calc(100% + 10px); left: -8px;
  width: min(320px, calc(100vw - 32px));
  padding: 14px 16px;
  background: var(--white); color: var(--bg);
  border-radius: 14px;
  box-shadow: var(--shadow);
  font-size: 13px; line-height: 1.45;
  z-index: 60;
  animation: pop .25s var(--ease) both;
}
.demo-mark__pop::before {
  content: ""; position: absolute; top: -6px; left: 18px;
  width: 12px; height: 12px; background: var(--white); transform: rotate(45deg);
}
.demo-mark__pop p { margin: 0 0 10px; }
.demo-mark__pop a { display: inline-flex; align-items: center; gap: 6px; font-weight: 700; text-decoration: none; }
.demo-mark__pop a svg { width: 16px; height: 16px; }

/* выдвижное меню (мобильное) */
.drawer { position: fixed; inset: 0; z-index: 80; }
.drawer__veil { position: absolute; inset: 0; background: rgba(8, 6, 4, .66); opacity: 0; transition: opacity .3s; }
.drawer__panel {
  position: absolute; top: 0; right: 0; bottom: 0;
  width: min(340px, 86vw);
  background: var(--bg-2);
  border-left: 1px solid var(--line);
  padding: 14px 18px calc(18px + env(safe-area-inset-bottom));
  display: flex; flex-direction: column; gap: 18px;
  transform: translateX(100%);
  transition: transform .38s var(--ease);
  overflow-y: auto;
}
.drawer.is-in .drawer__veil { opacity: 1; }
.drawer.is-in .drawer__panel { transform: none; }
.drawer__top { display: flex; align-items: center; justify-content: space-between; }
.drawer__w { width: 27px; height: 36px; }
.drawer__who { display: flex; flex-direction: column; gap: 2px; font-size: 13px; color: var(--fg-2); }
.drawer__who b { color: var(--fg); font-size: 15px; }
.drawer__hi { color: var(--brand); font-weight: 600; }
.drawer__nav { display: flex; flex-direction: column; }
.drawer__nav a {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
  font: 700 27px/1 var(--f-display);
  text-transform: uppercase; letter-spacing: .03em;
  text-decoration: none;
  color: var(--fg);
}
.drawer__nav a svg { width: 20px; height: 20px; color: var(--fg-3); }
.drawer__nav a.is-current { color: var(--brand); }
.drawer__foot { margin-top: auto; display: flex; flex-direction: column; gap: 10px; font-size: 13px; }
.drawer__foot a { color: var(--fg-2); }

/* --------------------------------------------------------------------------
   Баннеры, резерв
   -------------------------------------------------------------------------- */
.main { padding-top: 14px; }

.banners { position: relative; margin-bottom: 14px; }
.banners__track {
  display: flex; gap: 10px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  border-radius: var(--r);
  -webkit-overflow-scrolling: touch;
}
.banners__track::-webkit-scrollbar { display: none; }
.banner {
  flex: 0 0 100%;
  scroll-snap-align: start;
  aspect-ratio: 8 / 5;
  max-height: 230px;
  border-radius: var(--r);
  overflow: hidden;
  background: var(--bg-2);
  display: block;
}
.banner picture, .banner img { display: block; width: 100%; height: 100%; object-fit: cover; }
.banners__ctl { display: flex; align-items: center; justify-content: center; gap: 6px; margin-top: 8px; }
.banners__arrow { display: none; }
.banners__dots { display: flex; gap: 4px; }
.banners__dot {
  position: relative;
  width: 24px; height: 24px;
  border: 0; background: transparent; padding: 0;
}
.banners__dot::before { content: ""; position: absolute; inset: -10px; } /* цель касания 44px */
.banners__dot::after {
  content: ""; position: absolute; left: 50%; top: 50%;
  width: 7px; height: 7px; border-radius: 4px;
  background: var(--fg-3);
  transform: translate(-50%, -50%);
  transition: width .25s var(--ease), background .25s;
}
.banners__dot.is-on::after { width: 20px; background: var(--brand); }

.reserve {
  display: flex; align-items: center; gap: 10px;
  padding: 12px 14px;
  margin-bottom: 14px;
  border-radius: 14px;
  background: rgba(254, 193, 43, .1);
  border: 1px solid rgba(254, 193, 43, .35);
  font-size: 13px;
}
.reserve p { margin: 0; }
.reserve__ico { width: 34px; height: 34px; flex: 0 0 auto; display: grid; place-items: center; border-radius: 10px; background: var(--brand); color: var(--brand-ink); }
.reserve__ico svg { width: 18px; height: 18px; }

/* --------------------------------------------------------------------------
   Витрина: заголовок, вкладки, инструменты
   -------------------------------------------------------------------------- */
.board__head { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; margin: 6px 0 12px; }
.board__title {
  margin: 0;
  font: 700 46px/.9 var(--f-display);
  text-transform: uppercase;
  letter-spacing: .02em;
  position: relative;
  padding-right: 14px;
}
.board__title::after {
  content: ""; position: absolute; right: 0; top: 4px;
  width: 8px; height: 8px; border-radius: 50%; background: var(--brand);
}
.board__sub { margin: 0; font-size: 12px; color: var(--fg-2); }

.tabs {
  position: relative;
  display: grid; grid-template-columns: 1fr 1fr;
  padding: 4px;
  border-radius: 14px;
  background: var(--bg-3);
  margin-bottom: 10px;
}
.tabs__ind {
  position: absolute; top: 4px; left: 4px;
  width: calc(50% - 4px); height: calc(100% - 8px);
  border-radius: 10px;
  background: var(--brand);
  box-shadow: 0 4px 14px rgba(254, 193, 43, .35);
  transition: transform .4s var(--ease);
}
.tabs[data-active="keg"] .tabs__ind { transform: translateX(100%); }
.tabs__tab {
  position: relative; z-index: 1;
  height: 48px;
  border: 0; background: transparent;
  font: 700 25px/1 var(--f-display);
  text-transform: uppercase; letter-spacing: .05em;
  color: var(--fg-2);
  display: inline-flex; align-items: center; justify-content: center; gap: 5px;
  transition: color .25s;
  border-radius: 10px;
}
.tabs__tab small { font: 700 11px/1 var(--f-body); letter-spacing: 0; opacity: .6; align-self: flex-start; margin-top: 8px; }
.tabs__tab[aria-selected="true"] { color: var(--brand-ink); }

.tools { display: flex; gap: 8px; margin-bottom: 8px; }
.search {
  flex: 1 1 auto; min-width: 0;
  position: relative;
  display: flex; align-items: center;
  height: 46px;
  border-radius: 12px;
  background: var(--bg-3);
  border: 1px solid transparent;
  transition: border-color .2s, background .2s;
}
.search:focus-within { border-color: var(--brand); background: var(--bg-4); }
.search__ico { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: var(--fg-3); pointer-events: none; }
.search__ico svg { width: 20px; height: 20px; }
.search input {
  flex: 1; min-width: 0; height: 100%;
  padding: 0 40px 0 40px;
  border: 0; background: transparent; color: var(--fg);
  font: 500 15px var(--f-body);
  outline: none;
  appearance: none; -webkit-appearance: none;
}
.search input::placeholder { color: var(--fg-3); }
.search input::-webkit-search-cancel-button { display: none; }
.search__clear { position: absolute; right: 0; top: 0; width: 44px; height: 44px; border: 0; background: transparent; color: var(--fg-2); border-radius: 10px; display: grid; place-items: center; }
.search__clear svg { width: 18px; height: 18px; }

.chip {
  display: inline-flex; align-items: center; gap: 6px;
  height: 36px; padding: 0 12px;
  border-radius: 999px;
  border: 1px solid transparent;
  background: var(--bg-3); color: var(--fg-2);
  font: 600 12.5px/1 var(--f-body);
  white-space: nowrap; flex: 0 0 auto;
  position: relative;
  transition: background .2s, color .2s, transform .15s;
}
.chip::before { content: ""; position: absolute; inset: -5px 0; } /* цель касания ≥ 44 */
.chip:active { transform: scale(.96); }
.chip svg { width: 16px; height: 16px; }
.chip--fav { height: 46px; padding: 0 14px; border-radius: 12px; }
.chip--fav svg { fill: none; stroke: currentColor; stroke-width: 2; }
.chip--fav[aria-pressed="true"] { background: var(--brand); color: var(--brand-ink); }
.chip--fav[aria-pressed="true"] svg { fill: currentColor; }
.chip--fav span { display: none; }

.chip--tag { --tag: var(--fg-3); padding-left: 10px; }
.chip__dot { display: none; width: 8px; height: 8px; border-radius: 50%; background: var(--tag); box-shadow: 0 0 0 2px rgba(255, 255, 255, .08); }
.chip--tag[style] .chip__dot { display: block; }
.chip__n { font-style: normal; font-size: 10.5px; opacity: .55; }
.chip__n:empty { display: none; }
.chip--tag[aria-pressed="true"] { background: var(--brand); color: var(--brand-ink); }
.chip--tag[aria-pressed="true"] .chip__dot { box-shadow: 0 0 0 2px rgba(0, 0, 0, .18); }
.chip--tag[aria-pressed="true"] .chip__n { opacity: .7; }
.chip--clear { color: var(--fg); background: var(--bg-4); }
.chip--clear svg { width: 14px; height: 14px; }

.tagbar { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; }
.tagbar__scroll {
  flex: 1 1 auto; min-width: 0;
  display: flex; gap: 6px;
  overflow-x: auto;
  padding: 5px 0;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
  mask-image: linear-gradient(90deg, #000 calc(100% - 28px), transparent);
  -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 28px), transparent);
}
.tagbar__scroll::-webkit-scrollbar { display: none; }

.board__count { margin: 0 0 10px; font-size: 12px; color: var(--fg-3); min-height: 1.4em; }

/* --------------------------------------------------------------------------
   Сетка карточек
   -------------------------------------------------------------------------- */
.grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  align-items: stretch;
}

.card {
  display: flex; flex-direction: column;
  min-width: 0;
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: var(--r);
  overflow: hidden;
  position: relative;
  animation: rise .6s var(--ease) both;
  animation-delay: calc(var(--i, 0) * 45ms);
  transition: border-color .25s, box-shadow .25s, transform .25s var(--ease);
  cursor: pointer;
}
.loaded .card { animation: pop .28s var(--ease) both; animation-delay: 0s; }
.card.in-cart { border-color: rgba(254, 193, 43, .55); box-shadow: 0 0 0 1px rgba(254, 193, 43, .25), 0 10px 30px -18px rgba(254, 193, 43, .5); }
.card.is-out .card__plate img { filter: grayscale(1); opacity: .55; }

.card__plate {
  position: relative;
  aspect-ratio: 1;
  background: var(--white);
  padding: 8px;
  box-shadow: inset 0 -18px 30px -24px rgba(0, 0, 0, .5);
}
.card__plate img { width: 100%; height: 100%; object-fit: contain; display: block; }
.card__plate::after { /* тень «подставки» под банкой */
  content: ""; position: absolute; left: 22%; right: 22%; bottom: 8px; height: 10px;
  border-radius: 50%; background: radial-gradient(closest-side, rgba(0, 0, 0, .14), transparent);
  pointer-events: none;
}

.badges { position: absolute; top: 8px; left: 8px; display: flex; flex-direction: column; align-items: flex-start; gap: 4px; pointer-events: none; }
.badge {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 5px 7px 4px;
  border-radius: 6px;
  font: 800 9.5px/1 var(--f-body);
  letter-spacing: .1em; text-transform: uppercase;
  color: var(--white);
  background: var(--bg);
}
.badge svg { width: 10px; height: 10px; }
.badge--new { background: var(--brand); color: var(--brand-ink); }
.badge--best { background: var(--bg); }
.badge--sale { background: var(--sale); }
.badge--warm { background: var(--warm); text-transform: none; letter-spacing: .02em; font-weight: 700; font-size: 10px; }

.fav {
  position: absolute; top: 6px; right: 6px;
  width: 44px; height: 44px;
  border: 0; border-radius: 50%;
  background: rgba(255, 255, 255, .92);
  color: #c9c1b5;
  display: grid; place-items: center;
  transition: color .2s, transform .2s;
  box-shadow: 0 2px 8px rgba(0, 0, 0, .12);
}
.fav svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linejoin: round; }
.fav[aria-pressed="true"] { color: var(--sale); }
.fav[aria-pressed="true"] svg { fill: currentColor; }
.fav.pop { animation: heart .45s var(--ease); }

.card__body { display: flex; flex-direction: column; gap: 6px; padding: 10px 10px 10px; flex: 1; }
.card__meta { display: flex; justify-content: space-between; align-items: center; gap: 6px; font-size: 11px; color: var(--fg-2); min-height: 16px; }
.card__style { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.card__abv { flex: 0 0 auto; font-weight: 700; font-size: 10.5px; letter-spacing: .04em; color: var(--fg); padding: 2px 5px; border-radius: 5px; background: var(--bg-4); }
.card__name {
  margin: 0;
  font: 700 22px/.92 var(--f-display);
  text-transform: uppercase; letter-spacing: .015em;
  overflow-wrap: break-word;
  display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}

.vars { display: flex; flex-wrap: wrap; gap: 5px; }
.var {
  position: relative;
  display: inline-flex; align-items: center;
  height: 32px; padding: 0 10px;
  border: 1px solid transparent; border-radius: 8px;
  background: var(--bg-3); color: var(--fg-2);
  font: 600 12px/1 var(--f-body);
  white-space: nowrap;
  transition: background .2s, color .2s;
}
.var::before { content: ""; position: absolute; inset: -6px -2px; }
.var.is-on { background: var(--fg); color: var(--bg); }
.var.is-out { opacity: .45; text-decoration: line-through; }
.var.has-qty::after { content: ""; position: absolute; top: -3px; right: -3px; width: 9px; height: 9px; border-radius: 50%; background: var(--brand); box-shadow: 0 0 0 2px var(--bg-2); }
.var--single { background: transparent; border-color: var(--line-2); color: var(--fg-2); cursor: default; }

.price { display: flex; align-items: baseline; gap: 7px; flex-wrap: wrap; line-height: 1; margin-top: 2px; }
.price__now { display: inline-flex; align-items: baseline; color: var(--brand); }
.price__now b { font: 700 30px/1 var(--f-display); letter-spacing: .01em; }
.price__cur { font: 700 18px/1 var(--f-display); }
.price__per { font: 600 11.5px var(--f-body); color: var(--fg-2); margin-left: 2px; }
.price__old { font-size: 12px; color: var(--fg-3); text-decoration: line-through; text-decoration-color: var(--sale); }

.card__pack { display: flex; justify-content: space-between; align-items: baseline; gap: 6px; font-size: 12px; color: var(--fg-2); }
.card__pack b { color: var(--fg); font-weight: 600; white-space: nowrap; }
.card__exp { display: inline-flex; align-items: center; gap: 3px; font-size: 11px; color: var(--fg-3); white-space: nowrap; }
.card__exp svg { width: 12px; height: 12px; }

.stock { font-size: 12px; color: var(--low); display: flex; align-items: center; gap: 6px; }
.stock b { font-weight: 700; }
.stock.is-low { color: var(--sale); }
.stock.is-low::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; animation: blink 1.6s infinite; flex: 0 0 auto; }
.stock--out { color: var(--fg-3); }

/* степпер: qty=0 → одна широкая жёлтая кнопка «+ короб»; qty>0 → [−] qty [+] */
.stepper {
  margin-top: auto;
  padding-top: 4px;
  display: flex; align-items: center; gap: 4px;
  height: 48px;
}
.stepper__btn {
  height: 44px; min-width: 44px;
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  border: 0; border-radius: 12px;
  font: 700 13px var(--f-body);
  flex: 0 0 auto;
  transition: background .2s, transform .15s var(--ease), color .2s;
}
.stepper__btn svg { width: 18px; height: 18px; flex: 0 0 auto; }
.stepper__btn:active { transform: scale(.92); }
.stepper__btn--minus { background: var(--bg-3); color: var(--fg); border: 1px solid var(--line-2); }
.stepper__btn--minus:hover { background: var(--bg-4); }
.stepper__btn--plus { background: var(--brand); color: var(--brand-ink); box-shadow: 0 6px 16px -8px rgba(254, 193, 43, .8); }
.stepper__btn--plus:hover { background: var(--brand-2); }
.stepper__btn--plus:disabled { background: var(--bg-3); color: var(--fg-3); box-shadow: none; cursor: not-allowed; transform: none; }
.stepper__btn--plus:disabled .stepper__word::before { content: "Нет · "; }
.stepper__word { text-transform: lowercase; }
.stepper__qty { flex: 1; min-width: 0; text-align: center; line-height: 1; white-space: nowrap; }
.stepper__qty b { font: 700 24px/1 var(--f-display); display: inline-block; }
.stepper__qty span { font-size: 11px; color: var(--fg-2); }
.stepper[data-qty="0"] .stepper__btn--minus, .stepper[data-qty="0"] .stepper__qty { display: none; }
.stepper[data-qty="0"] .stepper__btn--plus { flex: 1 1 auto; }
.stepper:not([data-qty="0"]) .stepper__word { display: none; }
.stepper.bump .stepper__qty b { animation: bump .4s var(--ease); }

.promo-tile {
  position: relative;
  display: block;
  width: 100%;
  min-height: 280px; /* если плитка одна в ряду; иначе растягивается по высоте ряда */
  border-radius: var(--r);
  overflow: hidden;
  background: var(--bg-2);
  border: 1px solid var(--line);
  animation: rise .6s var(--ease) both;
  transition: transform .25s var(--ease);
}
.promo-tile::before { /* размытая копия картинки заполняет плитку, сама картинка не обрезается */
  content: ""; position: absolute; inset: -24px;
  background: var(--img) center / cover no-repeat;
  filter: blur(22px) saturate(1.15);
  opacity: .9;
}
.promo-tile img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; display: block; }
.promo-tile:hover { transform: translateY(-2px); }

.empty { text-align: center; padding: 56px 16px 64px; color: var(--fg-2); }
.empty__art { width: 64px; height: 64px; margin: 0 auto 14px; border-radius: 50%; background: var(--bg-3); display: grid; place-items: center; color: var(--brand); }
.empty__art svg { width: 28px; height: 28px; }
.empty h2 { margin: 0 0 4px; font: 700 34px/1 var(--f-display); text-transform: uppercase; color: var(--fg); letter-spacing: .02em; }
.empty p { margin: 0 0 18px; font-size: 14px; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 44px; padding: 0 18px;
  border: 0; border-radius: 12px;
  background: var(--brand); color: var(--brand-ink);
  font: 700 14px var(--f-body);
  text-decoration: none;
}
.btn--ghost { background: var(--bg-3); color: var(--fg); border: 1px solid var(--line-2); }

/* --------------------------------------------------------------------------
   Подвал
   -------------------------------------------------------------------------- */
.foot {
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
  padding-top: 28px; padding-bottom: 28px;
  margin-top: 24px;
  border-top: 1px solid var(--line);
  font-size: 12px; color: var(--fg-3);
}
.foot__w { width: 18px; height: 24px; opacity: .5; }
.foot a { color: var(--fg-2); }
.foot a:last-child { margin-left: auto; }

/* --------------------------------------------------------------------------
   Плавающий итог заказа
   -------------------------------------------------------------------------- */
.orderbar {
  position: fixed; left: 0; right: 0; bottom: 0;
  z-index: 50;
  padding: 0 10px calc(10px + env(safe-area-inset-bottom));
  pointer-events: none;
  transform: translateY(calc(100% + 24px));
  transition: transform .45s var(--ease), visibility 0s linear .45s;
  visibility: hidden;
}
.orderbar.is-in { transform: none; visibility: visible; transition: transform .45s var(--ease); }
.orderbar__in {
  pointer-events: auto;
  max-width: 720px; margin: 0 auto;
  min-height: 68px;
  display: flex; align-items: center; gap: 10px;
  padding: 10px 10px 10px 16px;
  border-radius: 18px;
  background: var(--brand);
  color: var(--brand-ink);
  box-shadow: 0 18px 50px rgba(0, 0, 0, .6), 0 0 0 1px rgba(0, 0, 0, .25), inset 0 1px 0 rgba(255, 255, 255, .35);
}
.orderbar__in.bump { animation: barbump .45s var(--ease); }
.orderbar__sum { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; gap: 2px; line-height: 1; }
.orderbar__n { font: 700 10.5px/1 var(--f-body); letter-spacing: .08em; text-transform: uppercase; opacity: .7; }
.orderbar__total { font: 700 30px/1 var(--f-display); letter-spacing: .01em; white-space: nowrap; }
.orderbar__act, .orderbar__confirm { display: flex; align-items: center; gap: 8px; flex: 0 0 auto; }
.orderbar__clear { width: 44px; height: 44px; border: 0; border-radius: 12px; background: rgba(0, 0, 0, .1); color: var(--brand-ink); display: grid; place-items: center; }
.orderbar__clear svg { width: 20px; height: 20px; }
.orderbar__clear:hover { background: rgba(0, 0, 0, .18); }
.orderbar__go {
  height: 44px; padding: 0 16px;
  display: inline-flex; align-items: center; gap: 8px;
  border-radius: 12px;
  background: var(--bg); color: var(--white);
  font: 700 14px var(--f-body);
  text-decoration: none;
  transition: transform .15s var(--ease), background .2s;
}
.orderbar__go svg { width: 18px; height: 18px; }
.orderbar__go:hover { background: #000; }
.orderbar__go:active { transform: scale(.96); }
.orderbar__confirm { flex: 1; justify-content: flex-end; font-weight: 700; font-size: 13px; }
.orderbar__confirm span { margin-right: auto; }
.orderbar__yes, .orderbar__no { height: 44px; padding: 0 14px; border: 0; border-radius: 12px; font: 700 13px var(--f-body); }
.orderbar__yes { background: var(--bg); color: var(--white); }
.orderbar__no { background: rgba(0, 0, 0, .1); color: var(--brand-ink); }

.toast {
  position: fixed; left: 50%; bottom: calc(var(--bar-h) + 10px + env(safe-area-inset-bottom));
  z-index: 55;
  transform: translate(-50%, 12px);
  opacity: 0;
  padding: 11px 16px;
  border-radius: 12px;
  background: var(--white); color: var(--bg);
  font: 600 13px var(--f-body);
  box-shadow: var(--shadow);
  pointer-events: none;
  transition: opacity .25s, transform .3s var(--ease);
  max-width: calc(100vw - 32px);
  text-align: center;
}
.toast.is-in { opacity: 1; transform: translate(-50%, 0); }
body:not(.has-order) .toast { bottom: calc(20px + env(safe-area-inset-bottom)); }

/* --------------------------------------------------------------------------
   Детали сорта: шторка снизу (мобильный) / модалка (десктоп)
   -------------------------------------------------------------------------- */
.sheet {
  position: fixed; inset: 0;
  width: 100%; height: 100%; max-width: none; max-height: none;
  margin: 0; padding: 0; border: 0;
  background: transparent;
  color: var(--fg);
  overflow: visible;
}
.sheet::backdrop { background: rgba(8, 6, 4, .7); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }
.sheet__panel {
  position: absolute; left: 0; right: 0; bottom: 0;
  max-height: calc(100dvh - 20px);
  display: flex; flex-direction: column;
  background: var(--bg-2);
  border-radius: 22px 22px 0 0;
  box-shadow: var(--shadow);
  transform: translateY(100%);
  transition: transform .42s var(--ease);
  padding-bottom: env(safe-area-inset-bottom);
}
.sheet.is-in .sheet__panel { transform: none; }
.sheet__grip { width: 40px; height: 4px; border-radius: 2px; background: var(--line-2); margin: 8px auto 6px; flex: 0 0 auto; }
.sheet__close { position: absolute; top: 18px; right: 12px; z-index: 3; background: rgba(21, 19, 17, .85); color: var(--white); }
.sheet__scroll { overflow-y: auto; overscroll-behavior: contain; padding: 0 14px 22px; min-height: 0; }
.sheet__hero { position: relative; }
.sheet__plate {
  position: relative;
  background: var(--white);
  border-radius: 16px;
  height: 250px;
  padding: 10px;
  box-shadow: inset 0 -18px 30px -24px rgba(0, 0, 0, .5);
}
.sheet__plate img { width: 100%; height: 100%; object-fit: contain; display: block; }
.sheet__plate .badges { top: 10px; left: 10px; }
.sheet__title { display: flex; align-items: flex-start; gap: 10px; }
.sheet__title .fav { position: static; flex: 0 0 auto; background: var(--bg-3); color: var(--fg-3); box-shadow: none; margin-top: -2px; }
.sheet__title .fav[aria-pressed="true"] { color: var(--sale); }
.sheet__info { display: flex; flex-direction: column; gap: 10px; padding-top: 14px; }
.sheet__meta { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; font-size: 13px; color: var(--fg-2); }
.sheet__meta .pill { display: inline-block; padding: 3px 7px; border-radius: 6px; background: var(--bg-4); color: var(--fg); font-weight: 700; font-size: 11px; letter-spacing: .04em; }
.sheet__name { margin: 0; flex: 1 1 auto; min-width: 0; font: 700 38px/.92 var(--f-display); text-transform: uppercase; letter-spacing: .015em; overflow-wrap: break-word; }
.sheet__descr { margin: 0; font-size: 14px; line-height: 1.5; color: var(--fg-2); }
.sheet__facts { display: flex; flex-wrap: wrap; gap: 6px 14px; margin: 0; font-size: 12px; color: var(--fg-2); }
.sheet__facts div { display: flex; gap: 5px; align-items: center; }
.sheet__facts dt { margin: 0; color: var(--fg-3); }
.sheet__facts dd { margin: 0; color: var(--fg); font-weight: 600; }
.sheet__vars .var { height: 40px; padding: 0 14px; font-size: 13px; }
.sheet__buy {
  display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap;
  margin-top: 4px; padding: 14px;
  border-radius: 14px;
  background: var(--bg-3);
}
.sheet__price { display: flex; flex-direction: column; gap: 4px; flex: 1 1 auto; min-width: 140px; }
.sheet__price .price__now b { font-size: 36px; }
.sheet__price .price__cur { font-size: 22px; }
.stepper--big { margin: 0; height: 52px; flex: 1 1 200px; padding: 0; }
.stepper--big .stepper__btn { height: 50px; min-width: 50px; font-size: 14px; }
.stepper--big .stepper__btn svg { width: 20px; height: 20px; }
.stepper--big .stepper__qty b { font-size: 28px; }
.sheet__links { display: flex; gap: 8px; }
.linkbtn {
  flex: 1 1 0; min-width: 0;
  display: grid; grid-template-columns: 18px minmax(0, 1fr); column-gap: 10px; align-items: center;
  min-height: 48px; padding: 8px 12px;
  border: 1px solid var(--line-2); border-radius: 12px;
  background: transparent; color: var(--fg);
  font: 600 13px/1.2 var(--f-body);
  text-align: left;
  text-decoration: none;
  transition: background .2s;
}
.linkbtn:hover { background: var(--bg-3); }
.linkbtn svg { width: 18px; height: 18px; color: var(--brand); grid-row: 1 / span 2; }
.linkbtn span { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.linkbtn small { font-size: 10.5px; font-weight: 500; color: var(--fg-3); white-space: nowrap; }
.linkbtn small:empty { display: none; }
.linkbtn[aria-disabled="true"] { opacity: .55; cursor: not-allowed; pointer-events: none; }
.linkbtn[aria-disabled="true"] svg { color: var(--fg-3); }
.linkbtn.is-on { background: var(--bg-3); border-color: var(--brand); }
.sheet__video video { width: 100%; max-height: 60vh; border-radius: 12px; background: #000; display: block; }

/* --------------------------------------------------------------------------
   Анимации
   -------------------------------------------------------------------------- */
@keyframes rise { from { opacity: 0; transform: translateY(16px); } }
@keyframes pop { from { opacity: 0; transform: scale(.97); } }
@keyframes bump { 0% { transform: scale(1); } 35% { transform: scale(1.35); color: var(--brand); } 100% { transform: scale(1); } }
@keyframes barbump { 0% { transform: scale(1); } 40% { transform: scale(1.03) translateY(-3px); } 100% { transform: scale(1); } }
@keyframes heart { 0% { transform: scale(1); } 40% { transform: scale(1.35); } 70% { transform: scale(.9); } 100% { transform: scale(1); } }
@keyframes blink { 0%, 100% { opacity: 1; } 50% { opacity: .25; } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
}

/* --------------------------------------------------------------------------
   Адаптив
   -------------------------------------------------------------------------- */
@media (min-width: 430px) {
  .chip--fav span { display: inline; }
}

@media (min-width: 560px) {
  .grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
  .hdr__logo img { height: 26px; }
  .main { padding-top: 18px; }
}

@media (min-width: 720px) {
  .banner { aspect-ratio: 4 / 1; max-height: none; }
  .banners__arrow {
    display: grid; place-items: center;
    width: 36px; height: 36px;
    border: 0; border-radius: 50%;
    background: var(--bg-3); color: var(--fg);
  }
  .banners__arrow svg { width: 18px; height: 18px; }
  .banners__arrow[data-banner-nav="-1"] svg { transform: rotate(180deg); }
  .banners__arrow:hover { background: var(--bg-4); }
  .board__title { font-size: 54px; }
  .tabs { width: 360px; }
  .tools { align-items: center; }
  .search { max-width: 420px; }
  .tagbar__scroll { flex-wrap: wrap; overflow: visible; mask-image: none; -webkit-mask-image: none; }

  /* модалка вместо шторки */
  .sheet__panel {
    left: 50%; top: 50%; right: auto; bottom: auto;
    width: min(920px, calc(100vw - 48px));
    max-height: calc(100vh - 48px);
    border-radius: 22px;
    transform: translate(-50%, -50%) scale(.96);
    opacity: 0;
    transition: transform .35s var(--ease), opacity .3s;
    padding-bottom: 0;
  }
  .sheet.is-in .sheet__panel { transform: translate(-50%, -50%); opacity: 1; }
  .sheet__grip { display: none; }
  .sheet__close { top: 14px; right: 14px; }
  .sheet__scroll { padding: 22px 22px 26px; display: grid; grid-template-columns: 330px minmax(0, 1fr); gap: 24px; align-items: start; }
  .sheet__hero { position: sticky; top: 0; }
  .sheet__plate { height: 360px; padding: 20px; }
  .sheet__info { padding-top: 6px; }
  .sheet__name { font-size: 46px; }
  .sheet__title { padding-right: 44px; }
  .tagbar { flex-wrap: wrap; }
  .tagbar__scroll { flex: 0 1 auto; }
}

@media (min-width: 960px) {
  .grid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
  .hdr__in { min-height: 64px; gap: 16px; }
  .hdr__nav { display: flex; gap: 2px; margin-left: 8px; }
  .hdr__nav a {
    padding: 9px 12px;
    border-radius: 10px;
    font-size: 13px; font-weight: 600;
    color: var(--fg-2);
    text-decoration: none;
    transition: color .2s, background .2s;
  }
  .hdr__nav a:hover { color: var(--fg); background: var(--bg-3); }
  .hdr__nav a.is-current { color: var(--brand-ink); background: var(--brand); }
  .hdr__burger { display: none; }
  .hdr__company, .hdr__dept { max-width: 260px; }
  .card:hover { transform: translateY(-2px); border-color: var(--line-2); }
  .card.in-cart:hover { border-color: var(--brand); }
  .board__head { margin-top: 14px; }
  .board__title { font-size: 64px; }
  .board__sub { font-size: 13px; }
  .card__body { padding: 12px; gap: 7px; }
  .card__name { font-size: 24px; }
  .empty { padding: 90px 16px; }
  .orderbar { padding-bottom: 20px; }
}

@media (min-width: 1200px) {
  .grid { grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 16px; }
  .wrap { padding-inline: 28px; }
}
