/* Усами — фирменный стиль: чёрный, красный, тёплый белый, жёлтый для акций */
:root {
  --bg: #0e0e0f;
  --surface: #17171a;
  --surface-2: #202024;
  --line: #2c2c31;
  --text: #f6f1e9;
  --muted: #a19c94;
  --red: #d71920;
  --red-hover: #ee2a31;
  --yellow: #f5b301;
  --green: #3fb96b;
  --radius: 16px;
  --head: 'Oswald', 'Arial Narrow', sans-serif;
  --body: 'Manrope', system-ui, -apple-system, sans-serif;
  --header-h: 64px;
  --cats-h: 54px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + var(--cats-h) + 12px); }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 15px/1.45 var(--body);
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
}
body.locked { overflow: hidden; }
a { color: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
img { display: block; max-width: 100%; }
[hidden] { display: none !important; }

.wrap { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 16px; }

/* ---------- шапка ---------- */
.header {
  position: sticky; top: 0; z-index: 20;
  background: rgba(14, 14, 15, .92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.header__row { height: var(--header-h); display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; }
.brand img { width: 44px; height: 44px; }
.brand__text { display: flex; flex-direction: column; line-height: 1.1; }
.brand__text b { font: 700 22px/1 var(--head); letter-spacing: .04em; }
.brand__text small { color: var(--muted); font-size: 12px; margin-top: 3px; }
.header__info { display: flex; align-items: center; gap: 14px; }
.status { font-size: 13px; color: var(--muted); display: none; }
.status::before { content: ''; display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--green); margin-right: 6px; vertical-align: 1px; }
.status.closed::before { background: var(--red); }
.phone {
  display: flex; align-items: center; gap: 8px; text-decoration: none;
  font-weight: 700; padding: 9px 12px; border-radius: 999px; background: var(--surface-2);
}
.phone svg { width: 18px; height: 18px; fill: var(--red); }
.phone span { display: none; }
@media (min-width: 720px) {
  .status { display: inline; }
  .phone span { display: inline; }
}

/* ---------- категории ---------- */
.cats { height: var(--cats-h); }
.cats__row {
  display: flex; gap: 8px; align-items: center; height: 100%;
  overflow-x: auto; scrollbar-width: none;
}
.cats__row::-webkit-scrollbar { display: none; }
.cat {
  flex: none; border: 0; background: transparent; color: var(--muted);
  padding: 8px 14px; border-radius: 999px; font-weight: 700; font-size: 14px; white-space: nowrap;
  transition: background .15s, color .15s;
}
.cat:hover { color: var(--text); }
.cat.active { background: var(--red); color: #fff; }

/* ---------- уведомление ---------- */
.notice {
  margin-top: 16px; padding: 12px 16px; border-radius: 12px;
  background: rgba(245, 179, 1, .12); color: var(--yellow); font-weight: 600; font-size: 14px;
}

/* ---------- акции ---------- */
.promos {
  display: grid; grid-auto-flow: column; grid-auto-columns: 100%;
  gap: 16px; margin: 16px -16px 0; padding: 0 16px 4px; scroll-padding: 0 16px;
  overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none;
  overscroll-behavior-x: contain;
}
/* точки под каруселью акций — только на телефоне */
.promo-dots { display: flex; justify-content: center; gap: 6px; margin-top: 10px; }
.promo-dots button { width: 7px; height: 7px; padding: 0; border: 0; border-radius: 4px; background: var(--line); transition: width .2s, background .2s; }
.promo-dots button.on { width: 20px; background: var(--red); }
@media (min-width: 720px) { .promo-dots { display: none; } }
.promos::-webkit-scrollbar { display: none; }
@media (min-width: 720px) { .promos { grid-auto-flow: row; grid-template-columns: repeat(3, 1fr); margin: 20px 0 0; padding: 0; overflow: visible; } }
.promo {
  scroll-snap-align: start; scroll-snap-stop: always;
  position: relative; overflow: hidden; border: 0; text-align: left;
  min-height: 160px; padding: 20px; border-radius: var(--radius);
  display: flex; flex-direction: column; justify-content: space-between;
}
.promo h3 { margin: 0; font: 700 26px/1.05 var(--head); text-transform: uppercase; max-width: 70%; position: relative; }
.promo p { margin: 6px 0 0; font-size: 13px; font-weight: 600; opacity: .85; max-width: 65%; position: relative; }
.promo__price { font: 700 34px/1 var(--head); position: relative; }
.promo__price s { font-size: 18px; opacity: .6; margin-left: 6px; font-weight: 500; }
.promo__art { position: absolute; right: -10px; bottom: -14px; font-size: 104px; line-height: 1; transform: rotate(-10deg); }
.promo--dark { background: radial-gradient(circle at 85% 30%, #3a2a1c 0, #1b1713 60%); color: var(--text); }
.promo--dark .promo__price { color: var(--red-hover); }
.promo--yellow { background: radial-gradient(circle at 80% 20%, #ffd04a 0, var(--yellow) 45%, #e09200 100%); color: #1a1205; }
.promo--red { background: radial-gradient(circle at 85% 25%, #f03b40 0, var(--red) 55%, #9e0f15 100%); color: #fff; cursor: default; }
.promo--red .promo__art { font-size: 90px; }

.terms {
  display: flex; flex-wrap: wrap; gap: 6px 16px; margin-top: 14px;
  color: var(--muted); font-size: 13px;
}
.terms b { color: var(--text); font-weight: 700; }

/* ---------- меню ---------- */
.section { padding-top: 28px; }
.section__title {
  display: inline-block; margin: 0 0 16px; position: relative;
  font: 700 28px/1 var(--head); text-transform: uppercase; letter-spacing: .02em;
}
.section__title::after {
  content: ''; position: absolute; left: -4px; right: -10px; bottom: -6px; height: 8px;
  background: var(--red); border-radius: 2px 8px 3px 6px; transform: skewX(-18deg); z-index: -1; opacity: .9;
}
.grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
@media (min-width: 720px) { .grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; } }
@media (min-width: 1024px) { .grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }

.card {
  position: relative; background: var(--surface); border-radius: var(--radius); overflow: hidden;
  display: flex; flex-direction: column; cursor: pointer;
  border: 1px solid transparent; transition: border-color .15s, transform .15s;
}
.card:hover { border-color: var(--line); }
.card:active { transform: scale(.99); }
.card.off { opacity: .45; pointer-events: none; }

.pic {
  position: relative; aspect-ratio: 4 / 3; overflow: hidden;
  display: grid; place-items: center;
  background:
    radial-gradient(circle at 50% 55%, rgba(215, 25, 32, .28) 0, transparent 58%),
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='40' height='20' viewBox='0 0 40 20'%3E%3Cg fill='none' stroke='%23ffffff' stroke-opacity='.05'%3E%3Cpath d='M0 20a20 20 0 0 1 40 0M10 20a10 10 0 0 1 20 0M-20 20a20 20 0 0 1 40 0M20 20a20 20 0 0 1 40 0'/%3E%3C/g%3E%3C/svg%3E"),
    #1d1d21;
}
.pic img { width: 100%; height: 100%; object-fit: cover; }
.pic__emoji { font-size: clamp(54px, 15vw, 80px); line-height: 1; filter: drop-shadow(0 10px 14px rgba(0,0,0,.5)); }
.badges { position: absolute; top: 8px; left: 8px; display: flex; gap: 4px; }
.badge { font-size: 11px; font-weight: 800; padding: 3px 8px; border-radius: 999px; background: var(--yellow); color: #1a1205; text-transform: uppercase; letter-spacing: .03em; }
.badge--hot { background: var(--red); color: #fff; }

.card__body { padding: 12px; display: flex; flex-direction: column; gap: 4px; flex: 1; }
.card__name { margin: 0; font-weight: 800; font-size: 15px; line-height: 1.25; }
.card__desc {
  margin: 0; color: var(--muted); font-size: 12.5px; line-height: 1.35;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.card__foot { margin-top: auto; padding-top: 10px; display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.price { font: 600 20px/1 var(--head); white-space: nowrap; }
.price s { color: var(--muted); font-size: 14px; font-weight: 500; margin-left: 4px; }

.add {
  flex: none; width: 40px; height: 40px; border-radius: 12px; border: 0;
  background: var(--red); color: #fff; font-size: 24px; line-height: 1; font-weight: 500;
  display: grid; place-items: center; transition: background .15s;
}
.add:hover { background: var(--red-hover); }
.stepper { display: flex; align-items: center; background: var(--surface-2); border-radius: 12px; height: 40px; }
.stepper button { width: 36px; height: 40px; border: 0; background: none; font-size: 20px; font-weight: 600; }
.stepper span { min-width: 20px; text-align: center; font-weight: 800; }
.card .stepper button:last-child { color: var(--red-hover); }

/* ---------- подвал ---------- */
.footer { margin-top: 56px; padding: 32px 0 120px; border-top: 1px solid var(--line); color: var(--muted); font-size: 14px; }
.footer__grid { display: grid; gap: 24px; grid-template-columns: 1fr; }
@media (min-width: 720px) { .footer__grid { grid-template-columns: auto 1fr 1fr 1fr; } }
.footer h4 { margin: 0 0 8px; color: var(--text); font: 600 16px var(--head); text-transform: uppercase; letter-spacing: .04em; }
.footer p { margin: 0 0 6px; }
.footer a { text-decoration: none; color: var(--text); }

/* ---------- плавающая корзина ---------- */
.cartbar {
  position: fixed; z-index: 30; left: 16px; right: 16px; bottom: calc(16px + env(safe-area-inset-bottom));
  max-width: 420px; margin: 0 auto;
  display: flex; align-items: center; gap: 12px;
  height: 56px; padding: 0 20px 0 10px; border: 0; border-radius: 18px;
  background: var(--red); color: #fff; font-weight: 800; font-size: 16px;
  box-shadow: 0 12px 32px rgba(215, 25, 32, .35);
  animation: rise .25s ease-out;
}
.cartbar:hover { background: var(--red-hover); }
.cartbar__count { min-width: 36px; height: 36px; padding: 0 6px; border-radius: 12px; background: rgba(0,0,0,.22); display: grid; place-items: center; }
.cartbar__label { flex: 1; text-align: left; }
.cartbar__sum { font: 600 20px var(--head); }
@media (min-width: 720px) { .cartbar { left: auto; right: 24px; bottom: 24px; width: 320px; } }
@keyframes rise { from { transform: translateY(30px); opacity: 0; } }

/* ---------- шторки ---------- */
.sheet { position: fixed; inset: 0; z-index: 40; display: flex; align-items: flex-end; justify-content: center; }
.sheet__backdrop { position: absolute; inset: 0; background: rgba(0,0,0,.6); animation: fade .2s; }
.sheet__panel {
  position: relative; width: 100%; max-width: 560px; max-height: 92vh; overflow-y: auto;
  background: var(--surface); border-radius: 22px 22px 0 0;
  padding: 20px 16px calc(20px + env(safe-area-inset-bottom));
  animation: up .25s ease-out;
  overscroll-behavior: contain;
}
.sheet__close {
  position: absolute; top: 12px; right: 12px; z-index: 2;
  width: 36px; height: 36px; border-radius: 50%; border: 0;
  background: rgba(0,0,0,.5); color: #fff; font-size: 24px; line-height: 1;
}
@media (min-width: 720px) {
  .sheet { align-items: center; }
  .sheet__panel { border-radius: 22px; padding: 24px; }
  .sheet--side { justify-content: flex-end; align-items: stretch; }
  .sheet--side .sheet__panel { max-width: 440px; max-height: none; height: 100%; border-radius: 0; animation: slide .25s ease-out; }
}
@keyframes fade { from { opacity: 0; } }
@keyframes up { from { transform: translateY(40px); opacity: .5; } }
@keyframes slide { from { transform: translateX(40px); opacity: .5; } }

/* карточка блюда в шторке */
.sheet__panel--item { padding: 0 0 calc(16px + env(safe-area-inset-bottom)); }
.item__pic { aspect-ratio: 16 / 10; }
.item__pic .pic__emoji { font-size: 120px; }
.item__body { padding: 18px 16px 0; }
@media (min-width: 720px) { .sheet__panel--item { padding: 0 0 20px; overflow: hidden auto; } .item__body { padding: 20px 24px 0; } }
.item__name { margin: 0 0 6px; font: 700 26px/1.1 var(--head); text-transform: uppercase; }
.item__desc { margin: 0; color: var(--muted); }
.opt { margin-top: 18px; }
.opt__title { font-weight: 800; margin-bottom: 8px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  border: 1px solid var(--line); background: var(--surface-2); color: var(--text);
  padding: 9px 14px; border-radius: 12px; font-weight: 600; font-size: 14px;
}
.chip.on { border-color: var(--red); background: rgba(215, 25, 32, .16); }
.item__foot { display: flex; gap: 12px; align-items: center; margin-top: 22px; }
.item__foot .stepper { height: 52px; border-radius: 14px; }
.item__foot .stepper button { height: 52px; width: 44px; }

/* кнопки */
.btn {
  display: flex; align-items: center; justify-content: center; gap: 8px; flex: 1;
  height: 52px; padding: 0 20px; border: 0; border-radius: 14px;
  background: var(--red); color: #fff; font-weight: 800; font-size: 16px; text-decoration: none;
  transition: background .15s, opacity .15s;
}
.btn:hover { background: var(--red-hover); }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn--ghost { background: var(--surface-2); color: var(--text); }
.btn--ghost:hover { background: var(--line); }
.link { border: 0; background: none; color: var(--muted); text-decoration: underline; padding: 0; font-size: 14px; }

/* ---------- корзина ---------- */
.cart__title { margin: 4px 0 16px; font: 700 26px var(--head); text-transform: uppercase; }
.progress { background: var(--surface-2); border-radius: 12px; padding: 12px 14px; font-size: 14px; margin-bottom: 14px; }
.progress__bar { height: 6px; border-radius: 6px; background: var(--line); margin-top: 8px; overflow: hidden; }
.progress__bar i { display: block; height: 100%; background: var(--green); border-radius: 6px; transition: width .3s; }
.progress.done { color: var(--green); font-weight: 700; }

.line { display: grid; grid-template-columns: 52px 1fr auto; gap: 12px; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--line); }
.line__pic { width: 52px; height: 52px; border-radius: 12px; font-size: 30px; aspect-ratio: auto; }
.line__name { font-weight: 700; font-size: 14px; line-height: 1.25; }
.line__opts { color: var(--muted); font-size: 12px; }
.line__price { font: 600 16px var(--head); margin-top: 2px; }
.line .stepper { height: 34px; }
.line .stepper button { width: 30px; height: 34px; font-size: 18px; }

.promo-row { display: flex; gap: 8px; margin: 16px 0 6px; }
.promo-row input { flex: 1; text-transform: uppercase; }
.promo-row .btn { flex: none; height: 46px; }
.hint { font-size: 13px; margin: 2px 0 0; color: var(--muted); }
.hint.ok { color: var(--green); }
.hint.err { color: #ff6b6b; }

.totals { margin: 16px 0; font-size: 15px; }
.totals div { display: flex; justify-content: space-between; padding: 4px 0; }
.totals .grand { font: 700 22px var(--head); padding-top: 10px; margin-top: 6px; border-top: 1px solid var(--line); }
.totals .green { color: var(--green); }

/* ---------- оформление ---------- */
.seg { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; padding: 4px; border-radius: 14px; background: var(--surface-2); margin-bottom: 16px; }
.seg button { height: 42px; border: 0; border-radius: 11px; background: none; font-weight: 700; color: var(--muted); }
.seg button.on { background: var(--text); color: #111; }

.field { display: block; margin-bottom: 12px; }
.field > span { display: block; font-size: 13px; color: var(--muted); margin-bottom: 5px; font-weight: 600; }
.input, .field input, .field select, .field textarea {
  width: 100%; height: 48px; padding: 0 14px; border-radius: 12px;
  border: 1px solid var(--line); background: var(--bg); color: var(--text); font-size: 16px;
  outline: none; transition: border-color .15s;
}
.field textarea { height: 76px; padding: 12px 14px; resize: vertical; }
.input:focus, .field input:focus, .field select:focus, .field textarea:focus { border-color: var(--red); }
.field.invalid input { border-color: #ff6b6b; }
.row { display: grid; gap: 10px; grid-template-columns: repeat(var(--cols, 2), minmax(0, 1fr)); }
.block-title { margin: 22px 0 10px; font: 600 17px var(--head); text-transform: uppercase; letter-spacing: .04em; }
.radios { display: grid; gap: 8px; }
.radio {
  display: flex; align-items: center; gap: 12px; padding: 13px 14px;
  border: 1px solid var(--line); border-radius: 12px; cursor: pointer; font-weight: 600;
}
.radio input { accent-color: var(--red); width: 18px; height: 18px; margin: 0; }
.radio small { display: block; font-weight: 500; color: var(--muted); font-size: 12px; }
.radio:has(input:checked) { border-color: var(--red); background: rgba(215, 25, 32, .1); }
.pickup-box { padding: 14px; border-radius: 12px; background: var(--surface-2); font-size: 14px; }
.error-box { padding: 12px 14px; border-radius: 12px; background: rgba(255, 107, 107, .12); color: #ff8a8a; font-size: 14px; margin-bottom: 12px; }
.sticky-submit { position: sticky; bottom: calc(-20px - env(safe-area-inset-bottom)); margin: 0 -16px calc(-20px - env(safe-area-inset-bottom)); padding: 12px 16px calc(16px + env(safe-area-inset-bottom)); background: linear-gradient(transparent, var(--surface) 30%); }
@media (min-width: 720px) { .sticky-submit { bottom: -24px; margin: 0 -24px -24px; padding: 12px 24px 24px; } }
.back { margin-bottom: 8px; }

.empty { text-align: center; padding: 48px 8px; color: var(--muted); }
.empty div { font-size: 64px; margin-bottom: 8px; }

.success { text-align: center; padding: 32px 8px 8px; }
.success__icon { width: 84px; height: 84px; border-radius: 50%; margin: 0 auto 16px; background: var(--red); display: grid; place-items: center; font-size: 42px; }
.success h2 { font: 700 30px var(--head); text-transform: uppercase; margin: 0 0 8px; }
.success p { color: var(--muted); margin: 0 0 6px; }

/* ---------- уведомления ---------- */
.toast {
  position: fixed; z-index: 60; left: 50%; bottom: 90px; transform: translate(-50%, 20px);
  background: var(--text); color: #111; padding: 10px 16px; border-radius: 12px; font-weight: 700; font-size: 14px;
  opacity: 0; pointer-events: none; transition: opacity .2s, transform .2s; white-space: nowrap;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } html { scroll-behavior: auto; } }
.sticky-submit .btn, .success .btn, .empty + .btn { width: 100%; }
@media (max-width: 479px) { .row--stack { grid-template-columns: 1fr; gap: 0; } }
.credits { margin-top: 24px; font-size: 12px; opacity: .6; }
.pic img { position: absolute; inset: 0; }

/* согласие в оформлении */
.consent { display: flex; gap: 10px; align-items: flex-start; padding: 12px 14px; border: 1px solid var(--line); border-radius: 12px; font-size: 14px; cursor: pointer; }
.consent input { width: 20px; height: 20px; margin: 0; flex: none; accent-color: var(--red); }
.consent.invalid { border-color: #ff6b6b; background: rgba(255, 107, 107, .08); }
.consent a, .hint a { color: var(--text); }
.consent + .hint { margin: 8px 0 12px; }

/* юридические страницы */
.legal main { max-width: 760px; padding-top: 24px; padding-bottom: 64px; }
.legal h1 { font: 700 30px/1.15 var(--head); text-transform: uppercase; margin: 20px 0 6px; }
.legal h2 { font: 600 19px var(--head); text-transform: uppercase; letter-spacing: .03em; margin: 28px 0 8px; }
.legal p, .legal li { color: #d9d4cc; }
.legal .muted { color: var(--muted); font-size: 13px; }
.legal mark { background: rgba(245, 179, 1, .2); color: var(--yellow); padding: 0 4px; border-radius: 4px; }
.legal a { color: var(--text); }
.card__weight { color: var(--muted); font-weight: 600; font-size: 12px; white-space: nowrap; }
.item__meta { margin: 10px 0 0; color: var(--muted); font-size: 13px; }
.footnote { font-size: 12px; opacity: .75; }

/* карта в оформлении */
.mapbox { height: 260px; border-radius: 14px; overflow: hidden; border: 1px solid var(--line); background: var(--surface-2); }
.mapbox.invalid { border-color: #ff6b6b; box-shadow: 0 0 0 2px rgba(255, 107, 107, .25); }
#map { width: 100%; height: 100%; }
#zoneInfo { margin: 8px 0 14px; }
@media (min-width: 720px) { .mapbox { height: 300px; } }
/* КБЖУ на 100 г в карточке блюда */
.nutri { margin-top: 14px; padding: 12px; border-radius: 12px; background: var(--surface-2); }
.nutri__head { font-size: 13px; color: var(--muted); margin-bottom: 8px; }
.nutri__head b { color: var(--text); background: rgba(215, 25, 32, .22); padding: 1px 6px; border-radius: 6px; }
.nutri__grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; text-align: center; }
.nutri__grid b { display: block; font: 600 18px var(--head); }
.nutri__grid span { font-size: 11px; color: var(--muted); }
