/* Сайт заведения. Цвет, шрифт, скругления и вид меню задаёт конструктор дизайна через переменные и data-атрибуты. */
:root { --r: 16px; --r-s: calc(var(--r) * .65); --font-head: var(--font-display); --header-h: 64px; }
:root[data-font="sans"] { --font-head: var(--font); }
:root[data-font="rounded"] { --font-head: ui-rounded, "SF Pro Rounded", "Nunito", var(--font); --font: ui-rounded, "SF Pro Rounded", -apple-system, "Segoe UI", Roboto, sans-serif; }
body { --radius: var(--r); --radius-s: var(--r-s); }
.btn { border-radius: var(--r-s); }
.btn.lg { border-radius: var(--r-s); }
.input { border-radius: var(--r-s); }
.modal { border-radius: calc(var(--r) * 1.3); }
.wrap { width: min(1180px, 100% - 32px); margin: 0 auto; }

/* шапка */
.s-top { position: sticky; top: 0; z-index: 60; height: var(--header-h); display: flex; align-items: center; gap: 12px; padding: 0 max(16px, calc((100% - 1180px) / 2)); background: color-mix(in srgb, var(--bg) 84%, transparent); backdrop-filter: blur(16px) saturate(1.4); -webkit-backdrop-filter: blur(16px) saturate(1.4); border-bottom: 1px solid transparent; transition: border-color .3s, background-color .3s; }
.s-top.scrolled { border-color: var(--line); }
.s-brand { display: flex; align-items: center; gap: 10px; text-decoration: none; min-width: 0; margin-right: auto; }
.s-brand img { width: 40px; height: 40px; border-radius: var(--r-s); object-fit: contain; flex: none; }
.s-brand b { font: 600 20px/1.1 var(--font-head); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.s-brand small { display: flex; align-items: center; gap: 6px; font-size: 12.5px; color: var(--muted); white-space: nowrap; }
.dot { width: 7px; height: 7px; border-radius: 50%; background: var(--ok); flex: none; } .dot.off { background: var(--muted); }
.cart-btn { position: relative; }
.cart-btn .n { min-width: 22px; height: 22px; padding: 0 6px; border-radius: 11px; background: var(--on-accent); color: var(--accent); font-size: 12.5px; font-weight: 700; display: grid; place-items: center; }
.cart-btn.bump { animation: cart-bump .5s var(--ease); }
@keyframes cart-bump { 35% { transform: scale(1.12); } }
@media (max-width: 720px) { .cart-btn.top-cart, .s-top .hide-s { display: none; } }

/* первый экран */
.hero { position: relative; overflow: hidden; isolation: isolate; }
.hero-cover { min-height: min(78dvh, 640px); display: grid; align-items: end; color: #fff; }
.hero-bg { position: absolute; inset: 0; z-index: -2; background: #1c1917 center / cover no-repeat; }
.hero-bg.plain { background: radial-gradient(90% 120% at 80% 0%, color-mix(in srgb, var(--accent) 55%, #1c1917), #1c1917 62%), #1c1917; }
.hero-bg.plain::after { content: ""; position: absolute; inset: 0; background-image: radial-gradient(rgba(255,255,255,.07) 1px, transparent 1.4px); background-size: 22px 22px; mask-image: linear-gradient(120deg, transparent 20%, #000); -webkit-mask-image: linear-gradient(120deg, transparent 20%, #000); }
.hero-shade { position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgba(12,10,9,.25) 0%, rgba(12,10,9,.1) 35%, rgba(12,10,9,.82) 100%), radial-gradient(120% 90% at 50% 40%, transparent 55%, rgba(0,0,0,.45)); }
.hero-inner { padding: clamp(28px, 6vw, 72px) 0 clamp(28px, 5vw, 56px); display: grid; gap: 18px; }
.hero h1 { font: 500 clamp(38px, 7.6vw, 84px)/1.02 var(--font-head); letter-spacing: -.025em; max-width: 14em; }
.hero h1 .line { display: block; overflow: hidden; padding-bottom: .08em; }
.hero h1 .line > span { display: inline-block; }
.hero-sub { font-size: clamp(16px, 2.1vw, 21px); max-width: 34em; opacity: .9; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 6px; }
.chip { display: inline-flex; align-items: center; gap: 7px; padding: 8px 14px; border-radius: 99px; font-size: 14px; font-weight: 500; background: rgba(255,255,255,.14); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border: 1px solid rgba(255,255,255,.18); }
.chip .ico { width: 16px; height: 16px; }
.hero-split { padding: clamp(24px, 5vw, 64px) 0; }
.hero-split .wrap { display: grid; grid-template-columns: 1.05fr .95fr; gap: clamp(24px, 5vw, 64px); align-items: center; }
.hero-split .hero-pic { aspect-ratio: 4 / 3.4; border-radius: calc(var(--r) * 1.6); overflow: hidden; position: relative; background: var(--surface-2); box-shadow: var(--shadow); }
.hero-split .hero-pic .hero-bg { z-index: 0; }
.hero-split .chip, .hero-minimal .chip { background: var(--surface); border-color: var(--line); backdrop-filter: none; }
.hero-minimal { padding: clamp(28px, 5vw, 56px) 0 8px; }
.hero-minimal h1 { font-size: clamp(34px, 6vw, 60px); }
.hero-split .hero-sub, .hero-minimal .hero-sub { color: var(--muted); opacity: 1; }
@media (max-width: 820px) { .hero-split .wrap { grid-template-columns: 1fr; } .hero-split .hero-pic { order: -1; aspect-ratio: 16 / 10; } }

/* навигация по разделам меню */
.cats { position: sticky; top: var(--header-h); z-index: 50; background: color-mix(in srgb, var(--bg) 88%, transparent); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); border-bottom: 1px solid var(--line); }
.cats-in { display: flex; gap: 6px; overflow-x: auto; padding: 10px max(16px, calc((100% - 1180px) / 2)); scrollbar-width: none; scroll-behavior: smooth; }
.cats-in::-webkit-scrollbar { display: none; }
.cat { flex: none; border: 0; background: transparent; padding: 9px 16px; border-radius: 99px; font-weight: 600; font-size: 15px; color: var(--muted); cursor: pointer; transition: background-color .3s, color .3s; }
.cat:hover { color: var(--text); }
.cat.on { background: var(--text); color: var(--bg); }

.notice-bar { background: var(--surface-2); padding: 12px 16px; text-align: center; font-size: 15px; }
.menu { padding: 12px 0 120px; }
.menu-section { padding-top: 36px; scroll-margin-top: calc(var(--header-h) + 56px); }
.menu-section h2 { font: 500 clamp(26px, 4vw, 38px)/1.1 var(--font-head); margin-bottom: 20px; }

/* карточки блюд */
.items { display: grid; gap: 18px; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); }
.item { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); overflow: hidden; display: flex; flex-direction: column; cursor: pointer; transition: transform .5s var(--ease), box-shadow .5s var(--ease), border-color .3s; position: relative; }
.item:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.item.na { opacity: .55; }
.item-pic { aspect-ratio: 4 / 3; background: var(--surface-2); position: relative; overflow: hidden; }
.item-pic img { width: 100%; height: 100%; object-fit: cover; transition: transform 1.2s var(--ease); }
.item:hover .item-pic img { transform: scale(1.06); }
.ph { width: 100%; height: 100%; display: grid; place-items: center; background: linear-gradient(135deg, color-mix(in srgb, var(--accent) 20%, var(--surface)), color-mix(in srgb, var(--accent) 5%, var(--surface))); font: 500 72px/1 var(--font-head); color: color-mix(in srgb, var(--accent) 45%, transparent); user-select: none; }
.item-badge { position: absolute; top: 12px; left: 12px; padding: 4px 11px; border-radius: 99px; background: var(--accent); color: var(--on-accent); font-size: 12.5px; font-weight: 700; z-index: 2; }
.item-body { padding: 16px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.item-body h3 { font-size: 17.5px; line-height: 1.25; }
.item-desc { font-size: 14px; color: var(--muted); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.item-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: auto; padding-top: 10px; }
.item-price { display: flex; flex-wrap: wrap; align-items: baseline; column-gap: 6px; min-width: 0; }
.item-price .price-old { margin-left: 0; }
.price-now { font-weight: 700; font-size: 18px; font-variant-numeric: tabular-nums; white-space: nowrap; }
.price-old { font-size: 13.5px; color: var(--muted); text-decoration: line-through; margin-left: 6px; }
.weight { font-size: 13px; color: var(--muted); }
.add { min-height: 40px; padding: 0 16px; }
.stepper { display: inline-flex; align-items: center; background: var(--accent); color: var(--on-accent); border-radius: var(--r-s); height: 40px; animation: pop .3s var(--ease); }
.stepper button { width: 38px; height: 40px; border: 0; background: transparent; color: inherit; cursor: pointer; display: grid; place-items: center; border-radius: var(--r-s); }
.stepper button:active { background: rgba(0,0,0,.14); }
.stepper .ico { width: 17px; height: 17px; }
.stepper b { min-width: 22px; text-align: center; font-variant-numeric: tabular-nums; }
.stepper.plain { background: var(--surface-2); color: var(--text); }

:root[data-cards="large"] .items { grid-template-columns: repeat(auto-fill, minmax(340px, 1fr)); gap: 22px; }
:root[data-cards="large"] .item-pic { aspect-ratio: 16 / 10; }
:root[data-cards="large"] .item-body { padding: 20px; }
:root[data-cards="large"] .item-body h3 { font: 500 23px/1.2 var(--font-head); }
:root[data-cards="list"] .items { grid-template-columns: repeat(auto-fill, minmax(420px, 1fr)); gap: 12px; }
:root[data-cards="list"] .item { flex-direction: row-reverse; align-items: stretch; }
:root[data-cards="list"] .item-pic { width: 132px; aspect-ratio: auto; flex: none; min-height: 132px; }
:root[data-cards="list"] .ph { font-size: 44px; }
:root[data-cards="list"] .item-badge { left: auto; right: 10px; top: 10px; }
@media (max-width: 560px) {
  .items, :root[data-cards="large"] .items, :root[data-cards="list"] .items { grid-template-columns: 1fr; }
  :root[data-cards="grid"] .items { grid-template-columns: 1fr 1fr; gap: 10px; }
  :root[data-cards="grid"] .item-body { padding: 11px; }
  :root[data-cards="grid"] .item-body h3 { font-size: 15px; }
  :root[data-cards="grid"] .item-foot { flex-direction: column; align-items: stretch; gap: 8px; }
  :root[data-cards="grid"] .add, :root[data-cards="grid"] .stepper { width: 100%; justify-content: space-between; }
  :root[data-cards="grid"] .ph { font-size: 52px; }
  :root[data-cards="list"] .item-pic { width: 108px; min-height: 108px; }
}

/* окно блюда */
.dish-pic { aspect-ratio: 16 / 11; border-radius: var(--r); overflow: hidden; background: var(--surface-2); margin-bottom: 18px; }
.dish-pic img { width: 100%; height: 100%; object-fit: cover; }
.dish h3 { font: 500 28px/1.15 var(--font-head); }

/* корзина */
.drawer-overlay { position: fixed; inset: 0; z-index: 800; background: rgba(12,10,9,.5); backdrop-filter: blur(4px); -webkit-backdrop-filter: blur(4px); animation: fade .3s; }
.drawer { position: fixed; z-index: 801; top: 0; right: 0; bottom: 0; width: min(440px, 100%); background: var(--bg); display: flex; flex-direction: column; box-shadow: var(--shadow); animation: drawer-in .5s var(--ease); }
@keyframes drawer-in { from { transform: translateX(100%); } }
.drawer.out { transform: translateX(100%); transition: transform .3s; } .drawer-overlay.out { opacity: 0; transition: opacity .3s; }
.drawer-head { display: flex; align-items: center; justify-content: space-between; padding: 16px 20px; border-bottom: 1px solid var(--line); }
.drawer-head h3 { font: 500 24px var(--font-head); }
.drawer-body { flex: 1; overflow-y: auto; padding: 8px 20px 20px; }
.drawer-foot { border-top: 1px solid var(--line); padding: 16px 20px calc(16px + env(safe-area-inset-bottom)); display: grid; gap: 10px; background: var(--surface); }
.cart-line { display: flex; gap: 12px; padding: 14px 0; border-bottom: 1px solid var(--line); align-items: center; }
.line-pic { width: 60px; height: 60px; border-radius: var(--r-s); overflow: hidden; flex: none; background: var(--surface-2); }
.line-pic img { width: 100%; height: 100%; object-fit: cover; } .line-pic .ph { font-size: 26px; }
.sum-row { display: flex; justify-content: space-between; gap: 12px; font-size: 15px; }
.sum-row.total { font-size: 19px; font-weight: 700; }
.free-hint { font-size: 13.5px; color: var(--muted); }
.free-hint .meter { height: 5px; margin-top: 6px; border-radius: 5px; background: var(--surface-2); overflow: hidden; }
.free-hint .meter i { display: block; height: 100%; background: var(--ok); border-radius: 5px; transition: width .6s var(--ease); }
.float-cart { position: fixed; z-index: 70; left: 12px; right: 12px; bottom: calc(12px + env(safe-area-inset-bottom)); display: none; box-shadow: 0 12px 32px -8px color-mix(in srgb, var(--accent) 50%, transparent); justify-content: space-between; animation: rise-in .5s var(--ease); }
@keyframes rise-in { from { transform: translateY(120%); } }
@media (max-width: 720px) { .float-cart.show { display: flex; } }
.fly { position: fixed; z-index: 999; width: 18px; height: 18px; border-radius: 50%; background: var(--accent); pointer-events: none; transition: transform .7s cubic-bezier(.5, -0.2, .7, 1), opacity .7s; }

/* выбор способа */
.choice { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.choice label { border: 1.5px solid var(--line); border-radius: var(--r-s); padding: 12px 14px; cursor: pointer; display: grid; gap: 2px; transition: border-color .2s, background-color .2s; }
.choice input { position: absolute; opacity: 0; }
.choice label:has(input:checked) { border-color: var(--accent); background: var(--accent-soft); }
.choice label:has(input:focus-visible) { outline: 2px solid var(--accent); outline-offset: 2px; }
.choice b { display: flex; align-items: center; gap: 8px; } .choice small { color: var(--muted); font-size: 13px; }

/* страница заказа и кабинет */
.page { padding: clamp(20px, 4vw, 48px) 0 120px; min-height: 70dvh; }
.page-narrow { max-width: 720px; margin: 0 auto; display: grid; gap: 18px; }
.page h1 { font: 500 clamp(30px, 5vw, 44px)/1.08 var(--font-head); }
.box { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: clamp(16px, 3vw, 26px); display: grid; gap: 14px; }
.track { display: grid; gap: 0; margin: 6px 0; }
.track-step { display: grid; grid-template-columns: 34px 1fr; column-gap: 14px; padding-bottom: 22px; position: relative; color: var(--muted); }
.track-step::before { content: ""; position: absolute; left: 16px; top: 34px; bottom: 0; width: 2px; background: var(--line); }
.track-step::after { content: ""; position: absolute; left: 16px; top: 34px; height: 0; width: 2px; background: var(--accent); transition: height .8s var(--ease); }
.track-step.done::after { height: calc(100% - 34px); }
.track-step:last-child { padding-bottom: 0; } .track-step:last-child::before, .track-step:last-child::after { display: none; }
.track-dot { grid-row: span 2; width: 34px; height: 34px; border-radius: 50%; border: 2px solid var(--line); display: grid; place-items: center; background: var(--surface); transition: background-color .5s, border-color .5s, color .5s; }
.track-dot .ico { width: 17px; height: 17px; opacity: 0; transition: opacity .4s; }
.track-step.done, .track-step.now { color: var(--text); }
.track-step.done .track-dot { background: var(--accent); border-color: var(--accent); color: var(--on-accent); } .track-step.done .track-dot .ico { opacity: 1; }
.track-step.now .track-dot { border-color: var(--accent); animation: now-pulse 2s infinite; }
.track-step.now .track-dot::after { content: ""; width: 12px; height: 12px; border-radius: 50%; background: var(--accent); }
.track-step.now .track-dot .ico { display: none; }
@keyframes now-pulse { 0% { box-shadow: 0 0 0 0 var(--accent-soft); } 70% { box-shadow: 0 0 0 12px transparent; } }
.track-step b { font-size: 16.5px; align-self: end; } .track-step small { font-size: 14px; color: var(--muted); }
.status-big { font: 500 clamp(26px, 5vw, 36px)/1.1 var(--font-head); }
.status-big.swap { animation: swap .6s var(--ease); }
@keyframes swap { from { opacity: 0; transform: translateY(12px); filter: blur(6px); } }
.order-row { display: flex; align-items: center; gap: 12px; padding: 14px 0; border-bottom: 1px solid var(--line); text-decoration: none; }
.order-row:last-child { border-bottom: 0; }
.success-mark { width: 72px; height: 72px; border-radius: 50%; background: var(--accent); color: var(--on-accent); display: grid; place-items: center; animation: pop .6s var(--ease); }
.success-mark .ico { width: 34px; height: 34px; }

/* подвал */
.s-foot { border-top: 1px solid var(--line); padding: 40px 0 110px; font-size: 15px; background: var(--surface); }
.s-foot-grid { display: grid; grid-template-columns: 1.2fr 1fr 1fr; gap: 28px; }
@media (max-width: 760px) { .s-foot-grid { grid-template-columns: 1fr; } }
.s-foot h4 { font: 500 20px var(--font-head); margin-bottom: 12px; }
.s-foot ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 7px; color: var(--muted); }
.s-foot a { text-decoration: none; } .s-foot a:hover { color: var(--text); }
.hours li { display: flex; justify-content: space-between; gap: 16px; max-width: 240px; } .hours li.today { color: var(--text); font-weight: 600; }
.powered { margin-top: 28px; padding-top: 18px; border-top: 1px solid var(--line); font-size: 13px; color: var(--muted); display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; }

/* ===== анимации: «кино», «спокойные», «выключены» ===== */
[data-reveal] { opacity: 0; }
[data-reveal].in { opacity: 1; }
:root[data-anim="cinema"] [data-reveal] { transform: translateY(34px) scale(.985); filter: blur(8px); transition: opacity 1s var(--ease), transform 1.1s var(--ease), filter 1s var(--ease); transition-delay: calc(var(--i, 0) * 70ms); }
:root[data-anim="cinema"] [data-reveal].in { transform: none; filter: none; }
:root[data-anim="soft"] [data-reveal] { transition: opacity .6s ease; }
:root[data-anim="off"] [data-reveal] { opacity: 1; }
:root[data-anim="cinema"] .hero-bg { animation: kenburns 22s ease-out both; }
@keyframes kenburns { from { transform: scale(1.16) translate3d(0, -1.5%, 0); } to { transform: scale(1.02); } }
:root[data-anim="cinema"] .hero-shade { animation: shade-in 1.8s ease both; }
@keyframes shade-in { from { background-color: #0c0a09; } to { background-color: transparent; } }
:root[data-anim="cinema"] .hero h1 .line > span { transform: translateY(110%); animation: line-up 1.3s var(--ease) forwards; animation-delay: calc(var(--d, 0) * 140ms + 350ms); }
@keyframes line-up { to { transform: none; } }
:root[data-anim="cinema"] .hero .fade { opacity: 0; transform: translateY(18px); animation: fade-up 1.1s var(--ease) forwards; animation-delay: calc(var(--d, 0) * 140ms + 600ms); }
:root[data-anim="soft"] .hero .fade, :root[data-anim="soft"] .hero h1 { animation: fade .8s ease both; }
@keyframes fade-up { to { opacity: 1; transform: none; } }
:root[data-anim="cinema"] .view { animation: view-in .7s var(--ease); }
@keyframes view-in { from { opacity: 0; transform: translateY(14px); } }
:root[data-anim="off"] *, :root[data-anim="off"] *::before, :root[data-anim="off"] *::after { animation: none !important; transition: none !important; }
:root[data-anim="off"] .item:hover { transform: none; }
:root[data-anim="soft"] .item:hover { transform: none; } :root[data-anim="soft"] .item:hover .item-pic img { transform: none; }
@media (prefers-reduced-motion: reduce) { [data-reveal] { opacity: 1 !important; transform: none !important; filter: none !important; } .hero h1 .line > span, .hero .fade { transform: none !important; opacity: 1 !important; } }

.closed-page { min-height: 100dvh; display: grid; place-items: center; text-align: center; padding: 24px; }
.closed-page h1 { font: 500 clamp(30px, 6vw, 48px) var(--font-head); margin: 16px 0 10px; }
