/* «Ольха» — ресторан на крыше. Современный сдержанный интерфейс поверх 3D-зала: Inter Tight + IBM Plex Mono,
   тёплые нейтральные цвета, светлые листы, много воздуха, плавная анимация без свечений. */
@font-face { font-family: 'Inter Tight'; font-style: normal; font-weight: 400 700; font-display: swap; src: url('../fonts/inter-tight-400-700-cyrillic.04e86540.woff2') format('woff2'); unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: 'Inter Tight'; font-style: normal; font-weight: 400 700; font-display: swap; src: url('../fonts/inter-tight-400-700-latin.83d548cd.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'IBM Plex Mono'; font-style: normal; font-weight: 400; font-display: swap; src: url('../fonts/ibm-plex-mono-400-cyrillic.7b59d6bf.woff2') format('woff2'); unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: 'IBM Plex Mono'; font-style: normal; font-weight: 400; font-display: swap; src: url('../fonts/ibm-plex-mono-400-latin.c36f509c.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+2000-206F, U+20AC, U+2212, U+FEFF, U+FFFD; }
@font-face { font-family: 'IBM Plex Mono'; font-style: normal; font-weight: 500; font-display: swap; src: url('../fonts/ibm-plex-mono-500-cyrillic.d524dc8f.woff2') format('woff2'); unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: 'IBM Plex Mono'; font-style: normal; font-weight: 500; font-display: swap; src: url('../fonts/ibm-plex-mono-500-latin.a76f53ca.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+2000-206F, U+20AC, U+2212, U+FEFF, U+FFFD; }

:root {
  --milk: #f6f3ee; --sand: #ece6dc; --stone: #cfc6b8; --ash: #8b8479; --graphite: #24221f; --ink: #161512;
  --lamp: #e9a75c; --busy: #b9b2a8; --line: rgba(36, 34, 31, .1); --line-d: rgba(246, 243, 238, .16);
  --sheet: rgba(246, 243, 238, .95);
  --e: cubic-bezier(.2, .72, .12, 1);
  --sans: 'Inter Tight', 'Helvetica Neue', Helvetica, Arial, sans-serif;
  --mono: 'IBM Plex Mono', ui-monospace, Menlo, monospace;
  --safe-b: env(safe-area-inset-bottom, 0px); --safe-t: env(safe-area-inset-top, 0px);
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; overflow: hidden; overscroll-behavior: none; background: #0c0b0a; color: var(--milk); }
body { font: 400 15px/1.45 var(--sans); letter-spacing: -.005em; -webkit-font-smoothing: antialiased; -webkit-tap-highlight-color: transparent; }
button, input { font: inherit; color: inherit; }
button { cursor: pointer; border: 0; background: none; padding: 0; -webkit-tap-highlight-color: transparent; }
.mono { font-family: var(--mono); font-size: 12.5px; letter-spacing: .04em; text-transform: uppercase; }
#track { position: absolute; left: 0; top: 0; width: 1px; height: 0; visibility: hidden; pointer-events: none; }
#gl { position: fixed; inset: 0; width: 100vw; height: 100vh; display: block; touch-action: none; outline: none; }
.ui { position: fixed; inset: 0; pointer-events: none; z-index: 2; }
.ui > * { pointer-events: none; }
.veil { position: fixed; inset: 0; background: #0c0b0a; opacity: 0; pointer-events: none; z-index: 3; transition: opacity .4s ease; }

/* ── шапка ── */
.top { position: absolute; left: 0; right: 0; top: 0; display: flex; align-items: center; gap: 28px; padding: calc(22px + var(--safe-t)) 36px 0;
  opacity: 0; transform: translateY(-10px); transition: opacity 1s var(--e), transform 1s var(--e); }
.chrome .top { opacity: 1; transform: none; pointer-events: auto; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--milk); text-decoration: none; font-weight: 600; font-size: 22px; letter-spacing: -.03em; }
.brand-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--milk); }
.brand-sub { color: rgba(246, 243, 238, .62); margin-left: -14px; padding-top: 3px; }
.nav { display: flex; gap: 4px; margin-left: auto; padding: 4px; border-radius: 999px; background: rgba(20, 19, 16, .32); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); }
.nav button { height: 40px; padding: 0 16px; border-radius: 999px; color: rgba(246, 243, 238, .74); font-weight: 500; transition: color .3s, background .3s; }
.nav button:hover { color: var(--milk); }
.nav button.on { color: var(--ink); background: var(--milk); }
.cta { height: 48px; padding: 0 22px; border-radius: 999px; background: var(--milk); color: var(--ink); font-weight: 600; letter-spacing: -.01em; transition: transform .4s var(--e), background .3s; }
.cta:hover { transform: translateY(-1px); background: #fff; }
.burger { display: none; width: 48px; height: 48px; border-radius: 50%; background: rgba(20, 19, 16, .32); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); position: relative; }
.burger i { position: absolute; left: 15px; right: 15px; height: 1.6px; background: var(--milk); border-radius: 2px; }
.burger i:first-child { top: 19px; } .burger i:last-child { top: 27px; }

/* ── титр вступления ── */
/* титр — в небе над горизонтом: на кадре террасы ниже стоят библиотека и Старый город */
.intro-title { position: absolute; left: 0; right: 0; top: 17%; text-align: center; opacity: 0; transform: translateY(12px); transition: opacity 1.2s var(--e), transform 1.8s var(--e); text-shadow: 0 2px 34px rgba(40, 26, 14, .26); }
.intro-title.on { opacity: 1; transform: none; }
.it1 { font-weight: 600; font-size: clamp(56px, 9vw, 132px); letter-spacing: -.045em; line-height: .95; }
.it2 { margin-top: 18px; color: var(--milk); font-size: 13px; text-shadow: 0 1px 3px rgba(30, 20, 10, .35), 0 1px 16px rgba(30, 20, 10, .5); }

/* ── подсказка, подпись стола, подпись вида ── */
.hint { position: absolute; left: 50%; bottom: calc(118px + var(--safe-b)); transform: translateX(-50%); display: flex; align-items: center; gap: 12px; white-space: nowrap;
  color: rgba(246, 243, 238, .82); font-size: 15px; text-shadow: 0 1px 12px rgba(0, 0, 0, .5); opacity: 0; transition: opacity .9s var(--e) .3s; }
.chrome .hint { opacity: 1; }
.chrome .hint.gone, .sheet-open .hint, .seated .hint { opacity: 0; transition-delay: 0s; }
.dot-sep { width: 3px; height: 3px; border-radius: 50%; background: currentColor; opacity: .6; }
.hint .only-touch { display: none; }
@media (hover: none) and (pointer: coarse) { .hint .only-mouse { display: none; } .hint .only-touch { display: inline; } }
.tip { position: absolute; left: 0; top: 0; padding: 8px 12px; border-radius: 12px; background: var(--sheet); color: var(--graphite); font-size: 15px; font-weight: 500; white-space: nowrap;
  display: flex; align-items: center; gap: 8px; box-shadow: 0 10px 30px rgba(0, 0, 0, .18); opacity: 0; transition: opacity .2s; }
.tip.on { opacity: 1; }
.tip .st { color: var(--ash); font-weight: 400; }
.sd { width: 8px; height: 8px; border-radius: 50%; background: var(--busy); flex: none; }
.sd.free, .sd.until, .sd.mine { background: var(--lamp); }
.caption { position: absolute; left: 36px; bottom: calc(116px + var(--safe-b)); max-width: 46vw; opacity: 0; transform: translateY(10px); transition: opacity 1s var(--e), transform 1.2s var(--e); }
.caption.on { opacity: 1; transform: none; transition-delay: .25s; }
.caption .c0 { color: rgba(246, 243, 238, .7); text-shadow: 0 1px 10px rgba(0, 0, 0, .5); }
.caption .c1 { margin-top: 6px; font-weight: 600; font-size: clamp(30px, 3.4vw, 50px); letter-spacing: -.035em; line-height: 1.02; text-shadow: 0 2px 24px rgba(0, 0, 0, .35); }

/* ── карточка стола ── */
.tcard { position: absolute; right: 36px; bottom: calc(116px + var(--safe-b)); width: 360px; padding: 22px 22px 18px; border-radius: 22px; background: var(--sheet); color: var(--graphite);
  backdrop-filter: blur(22px) saturate(1.2); -webkit-backdrop-filter: blur(22px) saturate(1.2); box-shadow: 0 30px 80px rgba(0, 0, 0, .25);
  opacity: 0; transform: translateY(16px); transition: opacity .6s var(--e), transform .8s var(--e); }
.tcard.on { opacity: 1; transform: none; pointer-events: auto; }
.tcard .row { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.tcard .n { font-weight: 600; font-size: 28px; letter-spacing: -.035em; }
.tcard .seats { color: var(--ash); }
.tcard .zone { margin-top: 4px; font-weight: 500; }
.tcard .note { color: var(--ash); margin-top: 2px; }
.tcard .stat { margin-top: 14px; display: flex; align-items: center; gap: 9px; padding: 11px 12px; border-radius: 14px; background: rgba(36, 34, 31, .045); }
.tcard .stat b { font-weight: 600; }
.tcard .stat span { color: var(--ash); }
.btns { display: flex; gap: 8px; margin-top: 16px; flex-wrap: wrap; }
.btn { min-height: 48px; padding: 0 20px; border-radius: 999px; font-weight: 600; letter-spacing: -.01em; display: inline-flex; align-items: center; justify-content: center; gap: 8px; transition: transform .35s var(--e), background .3s, opacity .3s; }
.btn.dark { background: var(--graphite); color: var(--milk); }
.btn.dark:hover { background: var(--ink); transform: translateY(-1px); }
.btn.line { border: 1px solid rgba(36, 34, 31, .16); color: var(--graphite); }
.btn.line:hover { background: rgba(36, 34, 31, .05); }
.btn[disabled] { opacity: .38; pointer-events: none; }
.btn.grow { flex: 1; }

/* ── нижняя панель: дата · время · гости · сводка ── */
.bar { position: absolute; left: 50%; bottom: calc(28px + var(--safe-b)); transform: translate(-50%, 16px); display: flex; align-items: stretch; height: 64px; padding: 6px; gap: 2px;
  border-radius: 22px; background: var(--sheet); color: var(--graphite); backdrop-filter: blur(22px) saturate(1.2); -webkit-backdrop-filter: blur(22px) saturate(1.2);
  box-shadow: 0 24px 70px rgba(0, 0, 0, .28); opacity: 0; transition: opacity 1s var(--e), transform 1s var(--e); }
.chrome .bar { opacity: 1; transform: translate(-50%, 0); pointer-events: auto; }
.seg { display: flex; flex-direction: column; justify-content: center; align-items: flex-start; gap: 1px; min-width: 104px; padding: 0 16px; border-radius: 16px; text-align: left; transition: background .25s; }
button.seg:hover, .seg.open { background: rgba(36, 34, 31, .06); }
.seg .k { color: var(--ash); font-size: 11px; }
.seg .v { font-weight: 600; font-size: 16px; letter-spacing: -.015em; white-space: nowrap; font-variant-numeric: tabular-nums; }
.seg + .seg { position: relative; }
.seg + .seg::before { content: ''; position: absolute; left: -1px; top: 14px; bottom: 14px; width: 1px; background: var(--line); }
.stepper { display: flex; align-items: center; gap: 2px; margin-left: -8px; }
.stepper button { width: 34px; height: 34px; border-radius: 50%; font-size: 18px; color: var(--graphite); transition: background .2s; }
.stepper button:hover { background: rgba(36, 34, 31, .07); }
.stepper .v { min-width: 18px; text-align: center; }
.sum { display: flex; align-items: center; gap: 10px; padding: 0 18px 0 16px; margin-left: 4px; border-left: 1px solid var(--line); font-size: 15px; color: var(--ash); white-space: nowrap; }
.sum b { color: var(--graphite); font-weight: 600; font-variant-numeric: tabular-nums; }
.pop { position: absolute; left: 50%; bottom: calc(102px + var(--safe-b)); transform: translate(-50%, 10px); width: min(560px, calc(100vw - 24px)); max-height: 56vh; overflow: auto; padding: 18px;
  border-radius: 22px; background: var(--sheet); color: var(--graphite); backdrop-filter: blur(22px) saturate(1.2); -webkit-backdrop-filter: blur(22px) saturate(1.2);
  box-shadow: 0 30px 90px rgba(0, 0, 0, .3); opacity: 0; transition: opacity .35s var(--e), transform .5s var(--e); }
.pop.on { opacity: 1; transform: translate(-50%, 0); pointer-events: auto; }
.pop h4 { margin: 0 0 12px; font-weight: 600; font-size: 15px; }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(76px, 1fr)); gap: 6px; }
.chip { min-height: 44px; padding: 0 12px; border-radius: 14px; border: 1px solid var(--line); background: rgba(255, 255, 255, .35); font-weight: 500; font-variant-numeric: tabular-nums;
  display: inline-flex; flex-direction: column; align-items: center; justify-content: center; gap: 0; line-height: 1.15; transition: background .2s, border-color .2s, color .2s; }
.chip small { font-family: var(--mono); font-size: 11px; color: var(--ash); letter-spacing: .03em; text-transform: uppercase; }
.chip:hover { border-color: rgba(36, 34, 31, .3); }
.chip.on { background: var(--graphite); border-color: var(--graphite); color: var(--milk); }
.chip.on small { color: rgba(246, 243, 238, .7); }
.chip[disabled] { opacity: .35; text-decoration: line-through; pointer-events: none; }
.chip .sun { display: block; width: 6px; height: 6px; border-radius: 50%; margin-top: 3px; background: var(--lamp); }

/* ── листы: бронь, меню, кухня, как добраться ── */
.sheet { position: absolute; top: 12px; right: 12px; bottom: 12px; width: min(460px, calc(100vw - 24px)); border-radius: 26px; background: var(--sheet); color: var(--graphite);
  backdrop-filter: blur(24px) saturate(1.2); -webkit-backdrop-filter: blur(24px) saturate(1.2); box-shadow: 0 40px 120px rgba(0, 0, 0, .35);
  transform: translateX(calc(100% + 24px)); transition: transform .8s var(--e); display: flex; flex-direction: column; }
.sheet.on { transform: none; pointer-events: auto; }
.sheet-grip { display: none; }
.sheet-x { position: absolute; top: 14px; right: 14px; width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; color: var(--graphite); z-index: 2; transition: background .2s; }
.sheet-x:hover { background: rgba(36, 34, 31, .07); }
.sheet-body { flex: 1; overflow: auto; padding: 30px 30px 26px; scrollbar-width: thin; }
.sheet-body h2 { margin: 0; font-weight: 600; font-size: 34px; letter-spacing: -.04em; line-height: 1; }
.sheet-body h3 { margin: 26px 0 10px; font-weight: 600; font-size: 17px; letter-spacing: -.02em; }
.sheet-body p { margin: 10px 0; color: #4b4741; }
.kick { color: var(--ash); margin-bottom: 10px; }
.lead { font-size: 17px; line-height: 1.5; color: #3d3a35 !important; }
.steps { display: flex; gap: 6px; margin: 18px 0 22px; }
.steps i { flex: 1; height: 3px; border-radius: 3px; background: rgba(36, 34, 31, .1); transition: background .5s var(--e); }
.steps i.on { background: var(--graphite); }
.field { display: block; margin-top: 14px; }
.field span { display: block; color: var(--ash); font-size: 13px; margin-bottom: 6px; }
.field input { width: 100%; height: 52px; padding: 0 16px; border-radius: 14px; border: 1px solid rgba(36, 34, 31, .16); background: rgba(255, 255, 255, .6); font-size: 17px; outline: none; transition: border-color .2s, background .2s; }
.field input:focus { border-color: var(--graphite); background: #fff; }
.field.err input { border-color: #b4532a; }
.field .msg { color: #b4532a; font-size: 13px; margin-top: 6px; min-height: 18px; }
.phone { display: flex; align-items: center; gap: 0; }
.phone .pre { height: 52px; display: grid; place-items: center; padding: 0 14px; border: 1px solid rgba(36, 34, 31, .16); border-right: 0; border-radius: 14px 0 0 14px; background: rgba(36, 34, 31, .04); font-weight: 600; font-variant-numeric: tabular-nums; }
.phone input { border-radius: 0 14px 14px 0; font-variant-numeric: tabular-nums; letter-spacing: .02em; }
.summary { margin-top: 16px; border-top: 1px solid var(--line); }
.summary div { display: flex; justify-content: space-between; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.summary div span { color: var(--ash); }
.summary div b { font-weight: 600; text-align: right; }
.pick { display: flex; flex-direction: column; gap: 8px; margin-top: 12px; }
.pick button { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 56px; padding: 10px 16px; border-radius: 16px; border: 1px solid var(--line); background: rgba(255, 255, 255, .4); text-align: left; transition: border-color .2s, background .2s; }
.pick button:hover { border-color: rgba(36, 34, 31, .3); }
.pick button.on { border-color: var(--graphite); background: #fff; }
.pick b { font-weight: 600; }
.pick span { color: var(--ash); font-size: 14px; }
.scroller { display: flex; gap: 6px; overflow-x: auto; padding-bottom: 6px; scrollbar-width: none; margin: 0 -2px; }
.scroller .chip { flex: none; min-width: 66px; }
.done { text-align: left; }
.done .code { display: inline-block; margin-top: 14px; padding: 8px 12px; border-radius: 10px; background: rgba(36, 34, 31, .06); font-family: var(--mono); font-size: 15px; letter-spacing: .08em; }
.menu-group { margin-top: 26px; }
.menu-group h3 { display: flex; justify-content: space-between; align-items: baseline; margin: 0 0 4px; }
.dish { display: grid; grid-template-columns: 1fr auto; gap: 2px 16px; padding: 13px 0; border-bottom: 1px solid var(--line); }
.dish b { font-weight: 600; }
.dish .p { font-variant-numeric: tabular-nums; font-weight: 500; }
.dish small { grid-column: 1 / -1; color: var(--ash); font-size: 14px; }
.tag { display: inline-block; margin-left: 6px; padding: 1px 7px; border-radius: 6px; background: rgba(36, 34, 31, .07); font-family: var(--mono); font-size: 10.5px; letter-spacing: .04em; text-transform: uppercase; vertical-align: 2px; color: var(--ash); }
.tasting { margin-top: 22px; padding: 18px; border-radius: 18px; background: var(--graphite); color: var(--milk); }
.tasting p { color: rgba(246, 243, 238, .74) !important; }
.tasting .row { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.tasting b { font-weight: 600; font-size: 20px; letter-spacing: -.02em; }
.facts { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 18px; margin-top: 18px; }
.facts div span { display: block; color: var(--ash); font-size: 13px; }
.facts div b { font-weight: 600; }
.hours div { display: flex; justify-content: space-between; padding: 9px 0; border-bottom: 1px solid var(--line); font-variant-numeric: tabular-nums; }
.foot { margin-top: 30px; padding-top: 16px; border-top: 1px solid var(--line); color: var(--ash); font-size: 14px; display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; }

.toast { position: absolute; left: 50%; top: calc(86px + var(--safe-t)); transform: translate(-50%, -8px); padding: 12px 18px; border-radius: 14px; background: var(--sheet); color: var(--graphite);
  box-shadow: 0 16px 40px rgba(0, 0, 0, .2); font-weight: 500; opacity: 0; transition: opacity .35s, transform .5s var(--e); white-space: nowrap; }
.toast.on { opacity: 1; transform: translate(-50%, 0); }

/* сдвиг панели и карточки, когда открыт лист (десктоп) */
@media (min-width: 900px) {
  .sheet-open .bar { transform: translate(calc(-50% - 230px), 0); }
  .sheet-open .tcard, .sheet-open .caption { opacity: 0; pointer-events: none; }
}

/* ── телефон ── */
@media (max-width: 899px) {
  .top { gap: 10px; padding: calc(14px + var(--safe-t)) 16px 0; }
  .brand { font-size: 20px; }
  .brand-sub, .nav { display: none; }
  .cta { margin-left: auto; height: 48px; padding: 0 18px; }
  .burger { display: block; }
  .bar { left: 10px; right: 10px; transform: translateY(16px); height: auto; flex-wrap: wrap; padding: 6px; border-radius: 22px; }
  .chrome .bar { transform: none; }
  .seg { flex: 1; min-width: 0; padding: 8px 12px; min-height: 56px; }
  .seg.guests { flex: 1.2; }
  .sum { order: -1; flex-basis: 100%; justify-content: center; border-left: 0; margin: 0; padding: 8px 0 6px; border-bottom: 1px solid var(--line); }
  .pop { bottom: calc(132px + var(--safe-b)); }
  .hint { bottom: calc(150px + var(--safe-b)); white-space: normal; text-align: center; width: calc(100% - 40px); justify-content: center; }
  .caption { left: 20px; right: 20px; max-width: none; top: calc(80px + var(--safe-t)); bottom: auto; }
  .caption .c1 { font-size: 32px; }
  .tcard { left: 10px; right: 10px; width: auto; bottom: calc(10px + var(--safe-b)); }
  .seated .bar { opacity: 0; pointer-events: none; }
  .sheet { top: auto; left: 0; right: 0; bottom: 0; width: 100%; max-height: 88vh; height: 88vh; border-radius: 26px 26px 0 0; transform: translateY(105%); }
  .sheet.on { transform: none; }
  .sheet.book { height: 64vh; } .sheet.compact { height: 50vh; } .sheet.scene { height: 58vh; }   /* кухня: над листом видна печь с огнём */
  .sheet-grip { display: block; width: 40px; height: 4px; border-radius: 4px; background: rgba(36, 34, 31, .18); margin: 10px auto 0; }
  .sheet-body { padding: 18px 20px calc(24px + var(--safe-b)); }
  .sheet-body h2 { font-size: 30px; }
  .sheet-open .bar { opacity: 0; pointer-events: none; }
  .toast { white-space: normal; width: calc(100% - 24px); text-align: center; }
  .facts { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: .01s !important; animation: none !important; }
}
