/* RestBook — светлая тема с сине-оранжевой айдентикой логотипа */

:root {
  color-scheme: light;
  --bg: #ffffff;
  --bg-soft: #f4f7fc;
  --surface: #ffffff;
  --surface-2: #f4f7fc;
  --line: #dbe2ee;
  --line-soft: #e9edf5;
  --ink: #0f1e42;
  --muted: #5f6d8c;
  --blue: #1b3f7d;
  --blue-hi: #2f6bff;
  --blue-deep: #0d2350;
  --blue-soft: #eaf0fc;
  --blue-text: #1b3f7d;
  --orange: #ff6b1a;
  --orange-hi: #ff8642;
  --amber-soft: #fff0e2;
  --amber-text: #c2560d;
  --radius: 14px;
  --shadow-sm: 0 1px 3px rgba(15, 30, 66, .10);
  --shadow: 0 4px 8px rgba(15, 30, 66, .06), 0 14px 34px rgba(15, 30, 66, .10);
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }

body {
  background: var(--bg);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 15px;
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
button { font: inherit; }
::selection { background: var(--blue); color: #fff; }

.container { max-width: 1320px; margin: 0 auto; padding: 0 28px; }
h1, h2, h3, h4 { letter-spacing: -.015em; }

/* ---------- Шапка ---------- */
.header { position: sticky; top: 0; z-index: 60; background: var(--bg); border-bottom: 1px solid var(--line-soft); }
.topbar { border-bottom: 1px solid var(--line-soft); }
.topbar__inner { display: flex; justify-content: flex-end; align-items: center; gap: 12px; height: 40px; font-size: 13.5px; font-weight: 600; color: var(--muted); }
.topbar a { display: inline-flex; align-items: center; gap: 7px; text-decoration: underline; }
.topbar a:hover { color: var(--blue-hi); }
.topbar__sep { color: var(--line); }

.header__main { background: var(--bg); }
.header__inner { display: flex; align-items: center; gap: 22px; height: 92px; }

.logo { display: flex; align-items: center; gap: 10px; flex: none; }
.logo__mark { width: 58px; height: 34px; display: grid; place-items: center; }
.logo__mark svg { width: 100%; height: 100%; }
.logo__mark--sm { width: 40px; height: 24px; flex: none; }
.logo__text { font-weight: 700; font-size: 24px; letter-spacing: -.04em; color: var(--blue); }
.logo em { font-style: normal; color: var(--orange); }

.searchbar {
  flex: 1; display: flex; align-items: center; border: 1px solid var(--line); border-radius: 12px;
  height: 62px; padding: 0 8px 0 0; background: var(--surface); max-width: 1000px;
}
.searchbar__field { display: flex; align-items: center; gap: 10px; padding: 0 18px; height: 100%; flex: 1; min-width: 0; }
.searchbar__field--city { flex: 0 0 34%; border-right: 1px solid var(--line-soft); }
.searchbar__field svg { width: 19px; height: 19px; color: var(--blue-hi); flex: none; }
.searchbar input { border: 0; outline: none; font: inherit; font-size: 16px; width: 100%; min-width: 0; color: var(--ink); background: transparent; }
.searchbar select {
  border: 0; outline: none; font: inherit; font-size: 16px; width: 100%; min-width: 0; color: var(--ink);
  background: transparent; appearance: none; cursor: pointer; padding-right: 18px;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23888' stroke-width='2.4' stroke-linecap='round'><path d='M6 9l6 6 6-6'/></svg>");
  background-repeat: no-repeat; background-position: right center; background-size: 13px;
}
.searchbar select option { background: var(--surface); color: var(--ink); }
.searchbar input::placeholder { color: #8b97b1; }
.searchbar .btn { flex: none; }

.header__nav { margin-left: auto; display: flex; align-items: center; gap: 10px; flex: none; }
.icon-link { display: flex; align-items: center; gap: 8px; height: 44px; padding: 0 12px; border-radius: 999px; font-size: 14px; font-weight: 700; }
.icon-link:hover { background: var(--bg-soft); }
.icon-link.is-active { background: var(--blue-soft); }
.icon-link.is-active .ic--heart { color: var(--orange); }
.icon-link .badge { min-width: 20px; height: 20px; padding: 0 6px; border-radius: 999px; background: var(--blue); color: #fff; font-size: 12px; font-weight: 800; display: grid; place-items: center; }
.avatar-chip { width: 36px; height: 36px; border-radius: 50%; border: 2px solid var(--blue); color: var(--blue-hi); display: grid; place-items: center; font-weight: 800; font-size: 13px; overflow: hidden; background: var(--surface); }
.avatar-chip img { width: 100%; height: 100%; object-fit: cover; }

/* ---------- Кнопки ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 46px; padding: 0 26px;
  border-radius: 8px; border: 2px solid transparent; background: var(--blue); color: #fff; font-weight: 800;
  font-size: 14px; letter-spacing: .06em; text-transform: uppercase; cursor: pointer;
  transition: background .15s ease, color .15s ease, border-color .15s ease;
}
.btn:hover { background: var(--blue-hi); }
.btn--ghost { background: transparent; color: var(--blue-hi); border-color: var(--blue); }
.btn--ghost:hover { background: var(--blue-soft); color: var(--blue-deep); }
.btn--quiet { background: var(--surface); color: var(--ink); border-color: var(--line); text-transform: none; letter-spacing: 0; font-weight: 700; }
.btn--quiet:hover { background: var(--surface-2); }
.btn--dark { background: var(--blue-deep); border-color: var(--blue); }
.btn--dark:hover { background: var(--blue); }
.btn--sm { height: 38px; padding: 0 16px; font-size: 12px; }
.btn--block { width: 100%; }
.btn--plain { text-transform: none; letter-spacing: 0; }

/* ---------- Секции ---------- */
.section { padding: 44px 0; }
.section--soft { background: var(--bg-soft); }
.section__head { display: flex; align-items: baseline; justify-content: space-between; gap: 20px; margin-bottom: 22px; }
.section__head h2 { margin: 0; font-size: 30px; font-weight: 800; }
.section__head a { font-weight: 700; text-decoration: underline; font-size: 14px; color: var(--blue-text); }
.section__head a:hover { color: var(--blue-hi); }

.row-4 { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 22px; }

/* Подборки главной: лента карточек, которую листают вбок */
.section__sub { margin: 6px 0 0; color: var(--muted); font-size: 14px; }
.rail { display: flex; gap: 22px; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 6px; scrollbar-width: none; }
.rail::-webkit-scrollbar { display: none; }
.rail > .card { flex: 0 0 285px; scroll-snap-align: start; }

.promo { border-radius: var(--radius); overflow: hidden; display: flex; flex-direction: column; background: linear-gradient(160deg, var(--blue), var(--blue-deep)); }
.promo .photo { height: 190px; }
.promo__body { padding: 22px; }
.promo__body h3 { margin: 0 0 8px; font-size: 26px; font-weight: 800; color: #fff; }
.promo__body p { margin: 0 0 18px; color: #cfdcf3; font-size: 15px; }
.promo__body a { font-weight: 800; text-transform: uppercase; font-size: 13px; letter-spacing: .05em; color: var(--orange); }
.promo__body a:hover { text-decoration: underline; }

/* ---------- Карточка ресторана ---------- */
.card {
  position: relative; background: var(--surface); border: 1px solid var(--line-soft); border-radius: var(--radius);
  overflow: hidden; display: flex; flex-direction: column; transition: border-color .15s ease, box-shadow .15s ease;
}
.card:hover { border-color: var(--blue); box-shadow: var(--shadow); }
.card__media { position: relative; aspect-ratio: 16 / 11; background: var(--surface-2); }
.card__media .photo { width: 100%; height: 100%; object-fit: cover; }
.card__badges { position: absolute; left: 12px; top: 12px; display: flex; gap: 6px; flex-wrap: wrap; }
.badge-soft { display: inline-flex; align-items: center; gap: 5px; background: #fff; color: var(--blue); font-size: 12px; font-weight: 700; padding: 6px 11px; border-radius: 999px; box-shadow: var(--shadow-sm); }
.badge-soft svg { width: 14px; height: 14px; }
.like {
  position: absolute; right: 12px; top: 12px; width: 34px; height: 34px; border-radius: 50%;
  background: rgba(255, 255, 255, .92); border: 0; cursor: pointer; display: grid; place-items: center;
  color: var(--blue); line-height: 1; box-shadow: var(--shadow-sm);
}
.like svg { width: 19px; height: 19px; }
.like:hover { background: #fff; }
.like.is-on { color: var(--orange); }

.card__body { padding: 16px 18px 18px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.card__top { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.card__name { margin: 0; font-size: 17px; font-weight: 800; line-height: 1.25; }
.card__score { text-align: right; flex: none; }
.card__score b { display: block; font-size: 17px; font-weight: 800; color: var(--blue-hi); }
.card__score small { color: var(--muted); font-size: 13px; }
.card__meta { margin: 0; font-size: 14px; color: var(--ink); }
.card__meta--muted { color: var(--muted); }
.card__pills { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 4px; }
.pill-offer { background: var(--blue-soft); color: var(--blue-text); font-size: 12.5px; font-weight: 700; padding: 5px 10px; border-radius: 6px; }
.pill-points { background: var(--amber-soft); color: var(--amber-text); font-size: 12.5px; font-weight: 700; padding: 5px 10px; border-radius: 6px; }
.card__bookings { margin-top: auto; padding-top: 8px; font-size: 12.5px; color: var(--muted); }

.photo { display: grid; place-items: center; font-size: 56px; }

/* ---------- Каталог ---------- */
.filters__title { font-size: 32px; font-weight: 800; margin: 0 0 6px; }
.filters__sub { margin: 0 0 20px; color: var(--muted); font-size: 15px; }
.filters__row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.filters__row[hidden] { display: none; }   /* атрибут hidden той же специфичности, что и .filters__row — без этого проигрывал каскаду */
.countries { margin-bottom: 6px; }

.select, .chip {
  height: 42px; padding: 0 16px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface);
  color: var(--ink); font-size: 14px; font-weight: 700; cursor: pointer; display: inline-flex; align-items: center; gap: 8px;
}
.select {
  padding-right: 38px; appearance: none;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%235089ff' stroke-width='2.4' stroke-linecap='round'><path d='M6 9l6 6 6-6'/></svg>");
  background-repeat: no-repeat; background-position: right 14px center; background-size: 14px;
}
.select option { background: var(--surface); color: var(--ink); }
.chip:hover { border-color: var(--blue); }
.chip.is-active { background: var(--blue); border-color: var(--blue); color: #fff; }
.chip .count { min-width: 20px; height: 20px; border-radius: 999px; background: #fff; color: var(--blue); font-size: 12px; font-weight: 800; display: grid; place-items: center; padding: 0 5px; }

.results-bar__count { font-size: 14px; color: var(--muted); }
.results-bar__count b { color: var(--ink); }
.active-filters { display: flex; gap: 8px; flex-wrap: wrap; }
.tag { display: inline-flex; align-items: center; gap: 6px; height: 30px; padding: 0 12px; border-radius: 999px; background: var(--blue-soft); color: var(--blue-text); font-size: 13px; font-weight: 700; }
.tag button { background: none; border: 0; cursor: pointer; color: inherit; font-size: 15px; line-height: 1; padding: 0; }

.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(272px, 1fr)); gap: 22px; padding-bottom: 50px; }
.empty { text-align: center; padding: 60px 20px; color: var(--muted); }
.empty h3 { color: var(--ink); margin: 0 0 6px; }

/* ---------- Панель фильтров ---------- */
/* Полоса в две строки: выбор визита сверху, фильтры под ним */
.toolbar { position: relative; display: flex; flex-direction: column; align-items: stretch; gap: 10px; padding: 14px 0 6px; }
.toolbar__pick { display: flex; }
.toolbar__filters { position: relative; display: flex; align-items: center; gap: 14px; }
.toolbar__scroll { display: flex; align-items: center; gap: 12px; overflow-x: auto; scroll-behavior: smooth; padding: 6px 2px; flex: 1; scrollbar-width: none; }
.toolbar__scroll::-webkit-scrollbar { display: none; }
.toolbar__arrow {
  position: absolute; top: 50%; transform: translateY(-50%); z-index: 8; width: 40px; height: 40px; border-radius: 50%;
  background: #fff; border: 1px solid var(--line); box-shadow: var(--shadow); cursor: pointer;
  display: grid; place-items: center; color: var(--ink);
}
.toolbar__arrow .ic { width: 20px; height: 20px; }
.toolbar__arrow--prev { left: -12px; }
.toolbar__arrow--prev .ic { transform: rotate(180deg); }
.toolbar__arrow--next { right: -12px; }

.seg { display: flex; align-items: center; border: 1.5px solid var(--blue); border-radius: 999px; height: 50px; flex: none; background: var(--surface); }
.seg__item { display: flex; align-items: center; gap: 8px; padding: 0 18px; height: 100%; background: none; border: 0; border-right: 1px solid var(--line); font-size: 15px; font-weight: 600; cursor: pointer; color: var(--ink); }
.seg__item:last-child { border-right: 0; }
.seg__item .ic { width: 18px; height: 18px; color: var(--muted); }
.seg__item .ic--caret { width: 14px; height: 14px; }
.seg__item.is-set { color: var(--blue-hi); font-weight: 800; }
.seg__item.is-set .ic { color: var(--blue-hi); }

.fbtn {
  display: inline-flex; align-items: center; gap: 9px; height: 50px; padding: 0 22px; border-radius: 999px;
  border: 1px solid var(--line); background: var(--surface); color: var(--ink); font-size: 15px; font-weight: 600;
  cursor: pointer; white-space: nowrap; flex: none;
}
.fbtn:hover { border-color: var(--blue); }
.fbtn .ic { width: 19px; height: 19px; color: var(--muted); }
.fbtn .ic--caret { width: 14px; height: 14px; }
.fbtn--primary { background: var(--blue); border-color: var(--blue); color: #fff; font-weight: 700; }
.fbtn--primary .ic { color: #fff; }
.fbtn--primary:hover { background: var(--blue-hi); }
.fbtn.is-on { border-color: var(--blue); background: var(--blue-soft); color: var(--blue); font-weight: 700; }
.fbtn.is-on .ic { color: var(--blue-hi); }
.fbtn__count { background: var(--blue); color: #fff; border-radius: 999px; font-size: 12px; font-weight: 800; padding: 2px 7px; }
.clear-all { background: none; border: 0; color: var(--blue-hi); font-weight: 800; font-size: 14px; letter-spacing: .04em; text-transform: uppercase; cursor: pointer; white-space: nowrap; flex: none; }
.clear-all:hover { text-decoration: underline; }

.fdrop-wrap { position: relative; flex: none; }
.fdrop {
  position: absolute; left: 0; top: calc(100% + 12px); width: 340px; background: var(--surface-2);
  border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow); z-index: 40; display: none; overflow: hidden;
}
.fdrop.is-open { display: block; }
.fdrop__head { padding: 20px 22px 14px; }
.fdrop__head h4 { margin: 0 0 14px; font-size: 21px; font-weight: 800; }
.fdrop__search { position: relative; }
.fdrop__search .ic { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); width: 18px; height: 18px; color: var(--blue-hi); }
.fdrop__search input { width: 100%; height: 46px; border: 1px solid var(--line); border-radius: 10px; padding: 0 14px 0 42px; font: inherit; font-size: 15px; outline: none; background: var(--surface); color: var(--ink); }
.fdrop__search input:focus { border-color: var(--blue); }
.fdrop__list { max-height: 260px; overflow-y: auto; border-top: 1px solid var(--line-soft); padding: 6px 0; }
.fdrop__row { display: flex; align-items: center; gap: 14px; padding: 11px 22px; cursor: pointer; font-size: 16px; position: relative; }
.fdrop__row:hover { background: var(--surface); }
.fdrop__row input { position: absolute; opacity: 0; width: 0; height: 0; }
.fdrop__box { width: 22px; height: 22px; border: 2px solid #b9c4d8; border-radius: 4px; flex: none; display: grid; place-items: center; }
.fdrop__box::after { content: ""; width: 11px; height: 6px; border-left: 2.5px solid #fff; border-bottom: 2.5px solid #fff; transform: rotate(-45deg) scale(0); transition: transform .12s; margin-top: -2px; }
.fdrop__row input:checked + .fdrop__box { background: var(--blue); border-color: var(--blue); }
.fdrop__row input:checked + .fdrop__box::after { transform: rotate(-45deg) scale(1); }
.fdrop__foot { border-top: 1px solid var(--line-soft); padding: 16px 22px; display: flex; justify-content: flex-end; }
.fdrop__empty { padding: 18px 22px; color: var(--muted); font-size: 14px; }

.range { padding: 26px 22px 26px; }
.range__track { position: relative; height: 34px; }
.range__line { position: absolute; top: 15px; left: 0; right: 0; height: 4px; background: var(--line); border-radius: 999px; }
.range__fill { position: absolute; top: 15px; height: 4px; background: var(--blue); border-radius: 999px; }
.range input[type=range] { position: absolute; top: 6px; left: 0; width: 100%; margin: 0; background: none; pointer-events: none; appearance: none; height: 22px; }
.range input[type=range]::-webkit-slider-thumb { appearance: none; pointer-events: auto; width: 26px; height: 26px; border-radius: 50%; background: #fff; border: 1px solid var(--line); box-shadow: var(--shadow); cursor: pointer; }
.range input[type=range]::-moz-range-thumb { pointer-events: auto; width: 24px; height: 24px; border-radius: 50%; background: #fff; border: 0; cursor: pointer; }
.range__values { display: flex; justify-content: space-between; font-size: 15px; color: var(--muted); margin-top: 20px; }
.range__bubble {
  position: absolute; top: -30px; transform: translateX(-50%); background: var(--ink); color: #fff;
  font-size: 13px; font-weight: 800; padding: 4px 9px; border-radius: 6px; white-space: nowrap;
}
/* Уголок под подписью — она указывает на свою ручку */
.range__bubble::after {
  content: ''; position: absolute; left: 50%; top: 100%; transform: translateX(-50%);
  border: 5px solid transparent; border-top-color: var(--ink);
}
/* Две ручки лежат друг на друге: событиям доступны только сами кружки */
.range--pair .range__track { height: 34px; }
.range--pair input[type=range] { pointer-events: none; }
.range--pair input[type=range]::-webkit-slider-thumb { pointer-events: auto; }
.range--pair input[type=range]::-moz-range-thumb { pointer-events: auto; }

/* ---------- Карта ---------- */
.map { position: relative; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: var(--surface-2); }
.map__canvas { display: block; width: 100%; height: 100%; object-fit: cover; }
#ymap { width: 100%; height: 100%; }
.map__pins { position: absolute; inset: 0; }
.pin { position: absolute; transform: translate(-50%, -100%); display: flex; flex-direction: column; align-items: center; cursor: pointer; z-index: 1; }
.pin:hover { z-index: 6; }
.pin__rating { background: #fff; color: var(--ink); font-size: 12px; font-weight: 800; padding: 3px 8px; border-radius: 5px; box-shadow: 0 2px 6px rgba(0, 0, 0, .6); line-height: 1.3; }
.pin__off { background: var(--orange); color: #fff; font-size: 11.5px; font-weight: 800; padding: 2px 7px; border-radius: 5px; margin-top: 2px; box-shadow: 0 2px 6px rgba(0, 0, 0, .5); }
.pin.is-active .pin__rating { background: var(--blue); color: #fff; }
.pin__card {
  position: absolute; bottom: calc(100% + 8px); left: 50%; transform: translateX(-50%); width: 230px;
  background: var(--surface); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow);
  overflow: hidden; display: none; z-index: 8;
}
.pin:hover .pin__card { display: block; }
.pin.is-below .pin__card { bottom: auto; top: calc(100% + 8px); }
/* Фото заведения в подсказке на карте */
.pin__photo { height: 120px; background: var(--surface-2); }
.pin__photo .photo { width: 100%; height: 100%; object-fit: cover; font-size: 34px; }
.pin__body { padding: 10px 12px 12px; }
.pin__card h4 { margin: 0 0 4px; font-size: 14px; }
.pin__card p { margin: 0; font-size: 12.5px; color: var(--muted); }
.pin__offer { margin-top: 5px !important; color: var(--blue-text); font-weight: 700; }
.map__zoom { position: absolute; right: 14px; top: 14px; display: grid; gap: 8px; z-index: 10; }
.map__zoom button { width: 38px; height: 38px; border-radius: 8px; background: var(--surface-2); border: 1px solid var(--line); font-size: 19px; font-weight: 700; color: var(--ink); cursor: pointer; box-shadow: var(--shadow-sm); display: grid; place-items: center; }
.map__zoom button:hover { background: var(--blue); border-color: var(--blue); color: #fff; }

.results-layout { display: grid; grid-template-columns: 1fr 46%; gap: 26px; align-items: start; padding-bottom: 50px; }
/* На широком экране список слева, карта справа — независимо от порядка в разметке */
.results-sheet { grid-column: 1; grid-row: 1; }
.results-map { grid-column: 2; grid-row: 1; position: sticky; top: 108px; height: calc(100vh - 150px); border-radius: var(--radius); overflow: hidden; }
.sheet-grab { display: none; }
/* Квадратная кнопка карты в строке поиска — нужна там, где карта прячется за шторкой */
.searchbar__map { display: none; }
.results-list { display: grid; gap: 16px; }
.results-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px 0; flex-wrap: wrap; }
.link-underline { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 600; text-decoration: underline; color: var(--muted); }
.link-underline:hover { color: var(--ink); }

.result { display: grid; grid-template-columns: 240px 1fr; border: 1px solid var(--line-soft); border-radius: var(--radius); overflow: hidden; background: var(--surface); position: relative; transition: border-color .15s ease; }
.result:hover { border-color: var(--blue); }
.result__media { position: relative; min-height: 210px; overflow: hidden; }
.result__media .photo { width: 100%; height: 100%; object-fit: cover; }
.result__body { padding: 18px 20px; display: flex; flex-direction: column; gap: 7px; }
/* Сердечко висит в правом верхнем углу карточки и перекрывало бы оценку —
   поэтому в списке освобождаем под него место */
.result__top { display: flex; align-items: flex-start; justify-content: space-between; gap: 14px; padding-right: 42px; }
.result__top h3 { margin: 0; font-size: 19px; font-weight: 800; }
.result__meta { margin: 0; font-size: 14.5px; color: var(--muted); }
.result__pills { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 2px; }
.slotbar { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 10px; }
.slotbar__item { display: flex; flex-direction: column; align-items: center; gap: 5px; }
.slotbar button { background: var(--blue); color: #fff; border: 0; border-radius: 8px; padding: 10px 14px; font-weight: 700; font-size: 14px; cursor: pointer; min-width: 68px; }
.slotbar button:hover { background: var(--blue-hi); }
.slotbar em { font-style: normal; background: var(--blue-soft); color: var(--blue-text); font-size: 11.5px; font-weight: 800; padding: 2px 7px; border-radius: 5px; }

/* ---------- Модальное окно ---------- */
.modal { position: fixed; inset: 0; z-index: 120; display: none; }
.modal.is-open { display: block; }
.modal__backdrop { position: absolute; inset: 0; background: rgba(15, 30, 66, .38); }
.modal__panel { position: absolute; right: 0; top: 0; bottom: 0; width: min(470px, 100%); background: var(--surface); display: flex; flex-direction: column; border-left: 1px solid var(--line); }
.modal__head, .modal__foot { padding: 18px 24px; display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.modal__head { border-bottom: 1px solid var(--line-soft); }
.modal__foot { border-top: 1px solid var(--line-soft); }
.modal__head h3 { margin: 0; font-size: 20px; font-weight: 800; }
.modal__body { padding: 4px 24px 24px; overflow-y: auto; flex: 1; }
.modal__close { background: none; border: 0; font-size: 24px; cursor: pointer; color: var(--muted); line-height: 1; }
.fieldset { padding: 20px 0; border-bottom: 1px solid var(--line-soft); }
.fieldset:last-child { border-bottom: 0; }
.fieldset h4 { margin: 0 0 12px; font-size: 13px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); }
.checks { display: flex; flex-wrap: wrap; gap: 8px; }
.check input { position: absolute; opacity: 0; width: 0; height: 0; }
.check span { display: inline-flex; align-items: center; height: 40px; padding: 0 15px; border-radius: 999px; border: 1px solid var(--line); font-size: 14px; font-weight: 700; cursor: pointer; }
.check input:checked + span { background: var(--blue); border-color: var(--blue); color: #fff; }
.switch-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 10px 0; }
.switch-row p { margin: 3px 0 0; font-size: 13px; color: var(--muted); }
.switch { position: relative; width: 48px; height: 27px; flex: none; }
.switch input { position: absolute; opacity: 0; width: 0; height: 0; }
.switch i { position: absolute; inset: 0; background: #cfd7e6; border-radius: 999px; transition: background .15s; }
.switch i::after { content: ""; position: absolute; left: 3px; top: 3px; width: 21px; height: 21px; background: #fff; border-radius: 50%; transition: transform .15s; }
.switch input:checked + i { background: var(--blue); }
.switch input:checked + i::after { transform: translateX(21px); }

/* ---------- Иконки, хлебные крошки ---------- */
.ic { display: inline-grid; place-items: center; width: 20px; height: 20px; flex: none; }
.ic svg { width: 100%; height: 100%; }
.ic--heart { width: 24px; height: 24px; color: var(--blue-hi); }

.crumbs { display: flex; align-items: center; gap: 8px; padding: 18px 0 10px; font-size: 14px; color: var(--muted); flex-wrap: wrap; }
.crumbs a { color: var(--blue-text); font-weight: 600; }
.crumbs a:hover { text-decoration: underline; }
.crumbs .ic { width: 16px; height: 16px; }

/* ---------- Профиль ресторана ---------- */
.rest-title { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; }
.rest-title h1 { margin: 0 0 14px; font-size: 36px; font-weight: 800; }
.rest-fav { width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--line); background: var(--surface); color: var(--ink); cursor: pointer; display: grid; place-items: center; flex: none; }
.rest-fav .ic { width: 24px; height: 24px; }
.rest-fav:hover { border-color: var(--blue); }
.rest-fav.is-on { color: var(--blue-hi); border-color: var(--blue); }

/* Избранное и «Поделиться» держатся парой у правого края заголовка */
.rest-acts { display: flex; gap: 10px; flex: none; }

/* Кнопка «Поделиться» повторяет вид избранного */
.rest-share { width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--line); background: var(--surface); color: var(--ink); cursor: pointer; display: grid; place-items: center; flex: none; }
.rest-share .ic { width: 22px; height: 22px; }
.rest-share:hover { border-color: var(--blue); color: var(--blue-hi); }

/* Своё окно «Поделиться» — там, где системного меню браузер не даёт */
.share-panel { max-width: 460px; }
.share-sub { margin: 0 0 18px; color: var(--muted); font-size: 15px; line-height: 1.5; }
.share-nets { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-bottom: 20px; }
.share-net { display: grid; justify-items: center; gap: 9px; padding: 16px 8px; border: 1px solid var(--line); border-radius: 16px; text-decoration: none; color: var(--ink); font-size: 13.5px; font-weight: 600; }
.share-net:hover { border-color: var(--blue); background: var(--blue-soft); }
.share-net__ic svg { width: 40px; height: 40px; display: block; }
.share-link { display: flex; gap: 10px; }
.share-link input { flex: 1; min-width: 0; padding: 12px 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface-2); color: var(--muted); font-size: 14px; font-family: inherit; }
.share-link .btn { flex: none; }
.rest-rows { display: grid; gap: 9px; margin-bottom: 20px; }
.rest-row { display: flex; align-items: center; gap: 10px; font-size: 15.5px; color: #384766; }
.rest-row .ic { color: var(--muted); }
.rest-row b { font-weight: 800; color: var(--ink); }
.rest-row .muted-count { color: var(--muted); }
.chip-soft { background: var(--surface-2); border-radius: 999px; padding: 5px 12px; font-size: 13.5px; color: var(--muted); }
.badge-insider { display: inline-flex; align-items: center; gap: 6px; background: var(--blue-soft); color: var(--blue-text); font-size: 12.5px; font-weight: 700; padding: 6px 12px; border-radius: 999px; margin-bottom: 14px; }
.badge-insider .ic { width: 15px; height: 15px; }

.rgallery { display: grid; grid-template-columns: 1.55fr 1.1fr .85fr; grid-template-rows: 150px 150px; gap: 12px; margin: 6px 0 4px; }
.rgallery > * { border-radius: 12px; overflow: hidden; position: relative; }
.rgallery > *:nth-child(1), .rgallery > *:nth-child(2) { grid-row: span 2; }
.rgallery .photo { width: 100%; height: 100%; object-fit: cover; }
.rgallery__more { position: absolute; inset: 0; background: rgba(15, 30, 66, .55); color: #fff; display: flex; align-items: center; justify-content: center; gap: 9px; font-weight: 800; font-size: 18px; cursor: pointer; }
.rgallery__more .ic { width: 22px; height: 22px; }
/* Настоящие фото открываются на весь экран */
.rgallery img.photo--img { cursor: zoom-in; transition: transform .25s ease; }
.rgallery > *:hover img.photo--img { transform: scale(1.03); }

/* ---------- Просмотр фото на весь экран ---------- */
.lightbox {
  position: fixed; inset: 0; z-index: 200; display: none; place-items: center;
  background: rgba(8, 14, 30, .93); padding: 24px;
}
.lightbox.is-open { display: grid; }
.lightbox img {
  max-width: min(1200px, 94vw); max-height: 88vh; width: auto; height: auto;
  object-fit: contain; border-radius: 12px; box-shadow: 0 20px 60px rgba(0, 0, 0, .5);
}
.lightbox__close, .lightbox__nav {
  position: absolute; display: grid; place-items: center; border: 0; cursor: pointer;
  background: rgba(255, 255, 255, .14); color: #fff; border-radius: 999px;
  backdrop-filter: blur(4px); line-height: 1;
}
.lightbox__close:hover, .lightbox__nav:hover { background: rgba(255, 255, 255, .28); }
.lightbox__close { top: 18px; right: 20px; width: 44px; height: 44px; font-size: 30px; }
.lightbox__nav { top: 50%; transform: translateY(-50%); width: 52px; height: 52px; font-size: 34px; }
.lightbox__nav--prev { left: 20px; }
.lightbox__nav--next { right: 20px; }
.lightbox__count {
  position: absolute; bottom: 22px; left: 50%; transform: translateX(-50%);
  color: #fff; font-size: 13.5px; font-weight: 700; background: rgba(255, 255, 255, .14);
  padding: 7px 14px; border-radius: 999px; font-variant-numeric: tabular-nums;
}
@media (max-width: 640px) {
  .lightbox { padding: 12px; }
  .lightbox__nav { width: 44px; height: 44px; font-size: 28px; }
  .lightbox__nav--prev { left: 8px; }
  .lightbox__nav--next { right: 8px; }
}

.booking { position: sticky; top: 112px; border-radius: 16px; background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow); overflow: hidden; }
.booking__head { padding: 22px 24px 18px; background: var(--surface-2); }
.booking__head h3 { margin: 0 0 4px; font-size: 26px; font-weight: 800; }
.booking__head p { margin: 0; font-size: 14px; color: var(--muted); }
.stepper { display: flex; align-items: center; background: var(--blue-soft); border-radius: 999px; margin: 18px 24px 0; overflow-x: auto; scrollbar-width: none; }
.stepper::-webkit-scrollbar { display: none; }
.panel > [data-stepper] .stepper { margin: 0 0 18px; }
.stepper__item { display: flex; align-items: center; gap: 8px; padding: 10px 16px; font-size: 14px; font-weight: 700; color: var(--blue-text); background: none; border: 0; cursor: pointer; }
/* Значок шага крупнее подписи и на светлом фоне сидит в белом кружке —
   так полоса шагов читается с одного взгляда */
.stepper__item .ic { width: 22px; height: 22px; }
.stepper__item:not(.is-active) .ic {
  width: 30px; height: 30px; padding: 4px; box-sizing: border-box;
  background: var(--surface); border-radius: 999px; box-shadow: 0 1px 2px rgba(20, 40, 80, .10);
}
.stepper__item { padding: 8px 12px; }
.stepper__item.is-active { padding: 8px 16px; }
.stepper__item.is-active { background: var(--blue); color: #fff; border-radius: 999px; }
.stepper__arrow { color: var(--blue-text); display: grid; place-items: center; width: 16px; height: 16px; opacity: .8; }
.booking__body { padding: 20px 24px 24px; }
.booking__label { font-size: 13px; font-weight: 800; margin: 0 0 10px; }

/* Полоса дат */
.daystrip { display: flex; gap: 8px; overflow-x: auto; padding-bottom: 4px; scrollbar-width: thin; }
.day { min-width: 62px; padding: 8px 6px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); cursor: pointer; text-align: center; color: var(--ink); flex: none; }
.day:hover { border-color: var(--blue); }
.day b { display: block; font-size: 17px; font-weight: 800; line-height: 1.2; }
.day small { display: block; font-size: 11.5px; color: var(--muted); }
.day.is-active { background: var(--blue); border-color: var(--blue); color: #fff; }
.day.is-active small { color: #cfdcf3; }

/* Выбор числа гостей */
.guests { display: flex; flex-wrap: wrap; gap: 8px; }
.guest { width: 48px; height: 46px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); font-weight: 800; font-size: 15px; cursor: pointer; color: var(--ink); }
.guest:hover { border-color: var(--blue); }
.guest.is-active { background: var(--blue); border-color: var(--blue); color: #fff; }
.booking__row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 16px; }
.booking__summary { background: var(--blue-soft); color: var(--blue-text); border-radius: 10px; padding: 13px 15px; font-size: 13.5px; margin-bottom: 16px; }
.booking__summary b { color: var(--blue-deep); }
/* Подсказка вместо кнопки, пока не выбраны дата, время и гости */
.booking__pick { margin: 0; font-size: 13px; color: var(--muted); text-align: center; }

.tabs { display: flex; gap: 6px; border-bottom: 1px solid var(--line-soft); margin-top: 28px; overflow-x: auto; }
.tab { background: none; border: 0; border-bottom: 3px solid transparent; padding: 14px; font-size: 15px; font-weight: 700; color: var(--muted); cursor: pointer; white-space: nowrap; }
.tab:hover { color: var(--ink); }
.tab.is-active { color: var(--blue); border-bottom-color: var(--blue); }
.tab-panel { display: none; padding: 28px 0 56px; }
.tab-panel.is-active { display: block; }

/* Профиль ресторана: разделы идут сплошной лентой, полоса вкладок липнет
   к шапке и сама подсвечивает тот раздел, до которого дошла прокрутка */
.tabs--sticky { position: sticky; top: 108px; z-index: 20; background: var(--bg); }
.rest-flow .tab-panel { display: block; padding: 26px 0 34px; border-top: 1px solid var(--line-soft); }
.rest-flow .tab-panel:first-child { border-top: 0; }
.rest-phone { font-weight: 700; color: var(--blue-text); }

.layout-2 { display: grid; grid-template-columns: 1fr 350px; gap: 34px; align-items: start; }

/* Страница ресторана: слева карточка и вкладки, справа бронирование во всю высоту */
.rest-layout__head { grid-column: 1; grid-row: 1; }
.rest-layout__aside { grid-column: 2; grid-row: 1 / span 2; }
.rest-layout__tabs { grid-column: 1; grid-row: 2; }
.panel { border: 1px solid var(--line-soft); border-radius: var(--radius); padding: 22px; background: var(--surface); }
.panel h3 { margin: 0 0 14px; font-size: 18px; font-weight: 800; }
.panel--green { background: var(--blue-soft); border-color: var(--blue); }

.rsection { padding: 8px 0 34px; }
.rsection > h2 { font-size: 28px; font-weight: 800; margin: 0 0 18px; }
.offer-row { display: flex; align-items: center; gap: 16px; padding: 10px 0; cursor: pointer; }
.offer-row__icon { width: 46px; height: 46px; border-radius: 10px; background: var(--blue-soft); color: var(--blue-hi); display: grid; place-items: center; flex: none; }
.offer-row__icon .ic { width: 26px; height: 26px; }
.offer-row__main { flex: 1; }
.offer-row__main h4 { margin: 0 0 3px; font-size: 17px; font-weight: 800; }
.offer-row__main p { margin: 0; font-size: 14.5px; color: var(--muted); }
.offer-row .ic--chevron { width: 20px; height: 20px; color: var(--muted); }

.info-card { border: 1px solid var(--line-soft); border-radius: 12px; overflow: hidden; margin: 20px 0 26px; background: var(--surface); }
.info-card__row { display: flex; align-items: center; gap: 16px; padding: 16px 18px; border-bottom: 1px solid var(--line-soft); }
.info-card__row:last-child { border-bottom: 0; }
.info-card__row .ic { width: 24px; height: 24px; color: var(--blue-hi); }
.info-card__row h4 { margin: 0 0 2px; font-size: 15px; font-weight: 800; }
.info-card__row p { margin: 0; font-size: 14px; color: var(--muted); }
.info-card__row > div { flex: 1; }

.info-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px 30px; margin: 22px 0 26px; }
.info-grid__item { display: flex; gap: 14px; align-items: flex-start; }
.info-grid__item .ic { width: 24px; height: 24px; color: var(--blue-hi); margin-top: 2px; }
.info-grid__item h4 { margin: 0 0 2px; font-size: 15px; font-weight: 800; }
.info-grid__item p { margin: 0; font-size: 14px; color: var(--muted); }

.menu-nav { display: flex; align-items: center; gap: 20px; padding: 16px 0; border-bottom: 1px solid var(--line-soft); overflow-x: auto; }
.menu-nav a { font-size: 15px; font-weight: 700; text-decoration: underline; white-space: nowrap; padding: 6px 10px; border-radius: 999px; color: var(--blue-text); }
.menu-nav a.is-active { background: var(--blue-soft); color: var(--blue); }

.photo-strip { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; margin: 14px 0 26px; }
.photo-strip .photo { height: 150px; border-radius: 10px; }
.food-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin: 14px 0 30px; }
.food-grid > * { position: relative; border-radius: 10px; overflow: hidden; }
.food-grid .photo { height: 118px; }
.food-grid__more { position: absolute; inset: 0; background: rgba(15, 30, 66, .55); color: #fff; display: grid; place-items: center; font-weight: 800; font-size: 17px; }

.dish { display: grid; grid-template-columns: 1fr auto; gap: 6px 20px; padding: 14px 0; }
.dish__name { font-size: 16.5px; font-weight: 600; }
.dish__price { font-size: 16px; font-weight: 700; white-space: nowrap; color: var(--blue-hi); }
.dish__desc { grid-column: 1 / -1; margin: 0; font-size: 14.5px; color: var(--muted); }
.dish-group { padding-bottom: 12px; border-bottom: 1px solid var(--line-soft); margin-bottom: 24px; }
.dish-group h3 { font-size: 22px; font-weight: 800; margin: 22px 0 6px; }

/* Папки меню у гостя: плитки в два столбца, внутри папки товары идут в один */
.menu-folders { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; margin-top: 16px; }
.menu-folder {
  display: grid; gap: 4px; padding: 0 0 14px; text-align: left; cursor: pointer;
  border: 1px solid var(--line); border-radius: 14px; overflow: hidden;
  background: var(--surface); color: var(--ink); font: inherit;
}
.menu-folder:hover { border-color: var(--blue); box-shadow: var(--shadow-sm); }
.menu-folder img, .menu-folder__emoji {
  width: 100%; height: 132px; object-fit: cover; display: grid; place-items: center;
  background: var(--surface-2); font-size: 38px; margin-bottom: 10px;
}
.menu-folder__name { padding: 0 14px; font-size: 16px; font-weight: 800; }
.menu-folder__count { padding: 0 14px; font-size: 13px; color: var(--muted); }

.slots { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 8px; }
.slot { position: relative; border: 1px solid var(--line); background: var(--surface); border-radius: 8px; padding: 10px 14px; font-weight: 800; font-size: 14px; cursor: pointer; color: var(--ink); }
.slot:hover { border-color: var(--blue); }
.slot.is-active { background: var(--blue); border-color: var(--blue); color: #fff; }
.slot em { position: absolute; top: -9px; right: -9px; font-style: normal; background: var(--blue-soft); color: var(--blue-text); font-size: 11px; font-weight: 800; padding: 2px 6px; border-radius: 6px; }

.field { margin-bottom: 15px; }
.field label { display: block; font-size: 13px; font-weight: 800; margin-bottom: 6px; }
.field input, .field select, .field textarea {
  width: 100%; height: 44px; padding: 0 13px; border: 1px solid var(--line); border-radius: 8px; font: inherit;
  font-size: 14px; background: var(--surface-2); color: var(--ink); outline: none;
}
.field textarea { height: auto; padding: 11px 13px; min-height: 96px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { border-color: var(--blue); }
.field select option { background: var(--surface-2); }
.notice { background: var(--blue-soft); border-radius: 10px; padding: 15px 17px; font-size: 14px; margin-top: 15px; color: var(--blue-text); }
.notice b { color: var(--blue-deep); }
.notice--private { display: flex; align-items: flex-start; gap: 10px; margin: 0 0 18px; }
.notice--private .ic { width: 18px; height: 18px; flex: none; color: var(--blue); margin-top: 1px; }

/* Предупреждение: тем же блоком, но янтарным — например «Telegram отклонил сообщение» */
.notice--warn { display: flex; align-items: flex-start; gap: 10px; background: var(--amber-soft); color: var(--amber-text); }
.notice--warn .ic { width: 18px; height: 18px; flex: none; margin-top: 1px; }

/* Подключение Telegram идёт по шагам: пройденные бледнеют, будущие ждут своей очереди */
.tg-step { border-top: 1px solid var(--line-soft); padding: 18px 0 4px; }
.tg-step:first-of-type { border-top: 0; padding-top: 4px; }
.tg-step h4 { display: flex; align-items: center; gap: 10px; margin: 0 0 6px; font-size: 15.5px; }
.tg-step p.muted { margin: 0 0 14px; font-size: 13.5px; line-height: 1.5; }
.tg-step__n { width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; flex: none; font-size: 13px; font-weight: 800; background: var(--surface-2); color: var(--muted); }
.tg-step.is-now .tg-step__n { background: var(--blue); color: #fff; }
.tg-step.is-done .tg-step__n { background: var(--blue-soft); color: var(--blue); }
.tg-step.is-off { opacity: .55; }
.tg-step .list-card { margin-bottom: 12px; }
.tg-list { margin: 0 0 14px; padding-left: 20px; display: grid; gap: 7px; font-size: 14px; line-height: 1.5; }

/* ---------- Отзывы ---------- */
.reviews-summary { display: flex; align-items: center; gap: 34px; flex-wrap: wrap; margin-bottom: 22px; }
.score-star { display: flex; align-items: baseline; gap: 8px; }
.score-star .ic { width: 26px; height: 26px; color: var(--blue-hi); align-self: center; }
.score-star b { font-size: 40px; font-weight: 800; line-height: 1; }
.score-star span { font-size: 15px; color: var(--muted); }
.score-word b { display: block; font-size: 17px; font-weight: 800; }
.score-word span { font-size: 14px; color: var(--muted); }
.metrics { display: flex; gap: 30px; flex-wrap: wrap; }
.metric { min-width: 130px; }
.metric h5 { margin: 0 0 8px; font-size: 15px; font-weight: 700; }
.metric__line { display: flex; align-items: center; gap: 10px; }
.metric__bar { flex: 1; height: 4px; background: var(--line); border-radius: 999px; overflow: hidden; }
.metric__bar i { display: block; height: 100%; background: var(--blue); }
.metric span { font-size: 14px; font-weight: 600; }

.banner-green { background: var(--blue-soft); border: 1px solid var(--line); border-radius: 12px; padding: 18px 20px; display: flex; gap: 14px; align-items: flex-start; margin: 22px 0 28px; }
.banner-green .ic { width: 22px; height: 22px; color: var(--blue-hi); margin-top: 1px; }
.banner-green h4 { margin: 0 0 4px; font-size: 16px; font-weight: 800; color: var(--blue-deep); }
.banner-green p { margin: 0 0 8px; font-size: 14px; color: var(--blue-text); }
.banner-green a { font-weight: 700; text-decoration: underline; display: inline-flex; align-items: center; gap: 6px; color: var(--blue); }
.banner-green a .ic { width: 16px; height: 16px; color: currentColor; }

.review-filters { display: flex; gap: 12px; flex-wrap: wrap; margin: 14px 0 20px; }
.review { padding: 22px 0; border-bottom: 1px solid var(--line-soft); }
.review__head { display: flex; align-items: center; gap: 12px; margin-bottom: 10px; }
.review__avatar { width: 42px; height: 42px; border-radius: 50%; background: var(--surface-2); color: var(--blue-hi); display: grid; place-items: center; font-weight: 800; }
.review__avatar .ic { width: 22px; height: 22px; }
.review__name { font-size: 16px; font-weight: 600; }
.review__sub { font-size: 13px; color: var(--muted); }
.review__score { display: flex; align-items: center; gap: 8px; font-size: 15px; font-weight: 800; margin-bottom: 8px; }
.review__score .ic { width: 17px; height: 17px; color: var(--blue-hi); }
.review__score span { font-weight: 500; color: var(--muted); font-size: 13.5px; }
.review__text { margin: 0 0 10px; font-size: 15px; }
.review__helpful { display: inline-flex; align-items: center; gap: 7px; background: none; border: 0; cursor: pointer; font-size: 14px; font-weight: 600; text-decoration: underline; padding: 0; color: var(--ink); }
.review__helpful .ic { width: 18px; height: 18px; }
.review__reply { border-left: 3px solid var(--line); padding: 4px 0 4px 16px; margin: 14px 0 0 8px; }
.review__reply-head { display: flex; align-items: center; gap: 10px; font-size: 15px; font-weight: 600; margin-bottom: 6px; }
.review__reply-head .ic { width: 20px; height: 20px; color: var(--muted); }
.review__reply p { margin: 0; font-size: 14.5px; color: #384766; }

.info-list { display: grid; gap: 14px; }
.info-list div { display: grid; grid-template-columns: 190px 1fr; gap: 14px; font-size: 14px; }
.info-list dt { color: var(--muted); }
.pill-list { display: flex; flex-wrap: wrap; gap: 8px; }
.pill { background: var(--blue-soft); color: var(--blue-text); border-radius: 999px; padding: 7px 13px; font-size: 13px; font-weight: 700; }

/* ---------- Профиль клиента ---------- */
.profile-head { display: flex; align-items: center; gap: 22px; padding: 34px 0 26px; flex-wrap: wrap; }
.profile-avatar { width: 92px; height: 92px; border-radius: 50%; background: var(--surface-2); color: var(--blue-hi); display: grid; place-items: center; font-size: 30px; font-weight: 800; overflow: hidden; border: 2px solid var(--blue); }
.profile-avatar img { width: 100%; height: 100%; object-fit: cover; }
.profile-head__name { display: flex; gap: 10px; flex-wrap: wrap; }
.profile-head__name input { height: 44px; padding: 0 13px; border: 1px solid var(--line); border-radius: 8px; font: inherit; font-size: 16px; font-weight: 800; width: 200px; outline: none; background: var(--surface); color: var(--ink); }
.profile-head__name input:focus { border-color: var(--blue); }
.profile-head p { margin: 8px 0 0; color: var(--muted); font-size: 14px; }

.points-card { background: linear-gradient(140deg, var(--blue), var(--blue-deep)); color: #fff; border-radius: var(--radius); padding: 26px; display: flex; align-items: center; justify-content: space-between; gap: 22px; flex-wrap: wrap; }
.points-card__num { font-size: 40px; font-weight: 800; line-height: 1; }
.points-card small { opacity: .85; }
.points-card .btn { background: #fff; color: var(--blue-deep); }
.points-card .btn:hover { background: var(--orange); color: #fff; }
.progress { height: 8px; background: rgba(255, 255, 255, .25); border-radius: 999px; overflow: hidden; margin-top: 12px; width: 100%; }
.progress i { display: block; height: 100%; background: #fff; }

.list-card { border: 1px solid var(--line-soft); border-radius: var(--radius); overflow: hidden; background: var(--surface); }
.list-row { display: flex; align-items: center; gap: 15px; padding: 17px 19px; border-bottom: 1px solid var(--line-soft); }
.list-row:last-child { border-bottom: 0; }
.list-row__icon { width: 44px; height: 44px; border-radius: 12px; background: var(--blue-soft); display: grid; place-items: center; font-size: 19px; flex: none; }
.list-row__main { flex: 1; min-width: 0; }
.list-row__main h4 { margin: 0 0 2px; font-size: 15px; font-weight: 800; }
.list-row__main p { margin: 0; font-size: 13px; color: var(--muted); }
.list-row__side { text-align: right; font-weight: 800; font-size: 14px; white-space: nowrap; }
.list-row__side small { display: block; font-weight: 600; color: var(--muted); font-size: 12px; }

.section-title { font-size: 22px; font-weight: 800; margin: 32px 0 14px; }
.muted { color: var(--muted); }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; }

.gift-card { border-radius: var(--radius); padding: 22px; color: #fff; background: linear-gradient(140deg, var(--blue), #0d2a66); display: flex; flex-direction: column; justify-content: space-between; min-height: 150px; }
.gift-card--dark { background: linear-gradient(140deg, var(--ink), #050d21); }
.gift-card b { font-size: 26px; }
.gift-card small { opacity: .85; }

.faq { border: 1px solid var(--line-soft); border-radius: var(--radius); overflow: hidden; background: var(--surface); }
.faq details { border-bottom: 1px solid var(--line-soft); }
.faq details:last-child { border-bottom: 0; }
.faq summary { padding: 17px 19px; cursor: pointer; font-weight: 700; list-style: none; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; float: right; color: var(--blue-hi); font-weight: 800; }
.faq details[open] summary::after { content: "–"; }
.faq p { margin: 0; padding: 0 19px 17px; color: var(--muted); font-size: 14px; }

/* ---------- Нижняя плашка ---------- */
.newsbar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 90; background: var(--surface); border-top: 1px solid var(--line); }
.newsbar__inner { display: flex; align-items: center; gap: 18px; padding: 14px 28px; max-width: 1320px; margin: 0 auto; }
.newsbar__text { flex: 1; font-size: 14.5px; }
.newsbar__text a { text-decoration: underline; font-weight: 700; color: var(--blue-text); }
.newsbar__close { background: none; border: 0; font-size: 22px; color: var(--muted); cursor: pointer; line-height: 1; }

/* ---------- Подвал ---------- */
.footer { border-top: 1px solid var(--line-soft); padding: 32px 0 90px; color: var(--muted); font-size: 13px; }
.footer__inner { display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap; }
.footer a:hover { color: var(--blue-hi); }

/* ---------- Уведомление ---------- */
.toast {
  position: fixed; left: 50%; bottom: 92px; transform: translateX(-50%) translateY(16px); background: var(--blue);
  color: #fff; padding: 12px 22px; border-radius: 999px; font-size: 14px; font-weight: 700; opacity: 0;
  pointer-events: none; transition: all .2s ease; z-index: 200; box-shadow: var(--shadow);
}
.toast.is-on { opacity: 1; transform: translateX(-50%) translateY(0); }

/* ---------- Адаптив ---------- */
@media (max-width: 1100px) {
  .row-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .layout-2 { grid-template-columns: 1fr; }
  /* В одну колонку блоки идут подряд по разметке */
  .rest-layout__head, .rest-layout__aside, .rest-layout__tabs { grid-column: auto; grid-row: auto; }
  .results-layout { grid-template-columns: 1fr; }
  /* На планшете список остаётся сверху, карта уходит под него */
  .results-sheet { grid-column: 1; grid-row: 1; }
  .results-map { grid-column: 1; grid-row: 2; position: relative; top: 0; height: 420px; }
  .food-grid { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 900px) {
  .header__inner { height: auto; padding: 14px 0; flex-wrap: wrap; }
  .searchbar { order: 3; flex-basis: 100%; max-width: none; }
  .grid-2 { grid-template-columns: 1fr; }
  .info-list div { grid-template-columns: 1fr; gap: 2px; }
}
@media (max-width: 760px) {
  .result { grid-template-columns: 1fr; }
  .result__media { min-height: 190px; }
  .rgallery { grid-template-columns: 1fr 1fr; grid-template-rows: 130px 130px; }
  .rgallery > *:nth-child(1), .rgallery > *:nth-child(2) { grid-row: auto; }
  .rgallery > *:nth-child(1) { grid-column: span 2; }
  .info-grid, .photo-strip { grid-template-columns: 1fr; }
  .food-grid { grid-template-columns: repeat(2, 1fr); }
  .rest-title h1 { font-size: 26px; }
}
@media (max-width: 640px) {
  .container { padding: 0 16px; }
  .row-4 { grid-template-columns: 1fr; }
  .searchbar { height: auto; flex-wrap: wrap; padding: 8px; gap: 8px; }
  .searchbar__field { flex: 1 1 100%; border-right: 0; height: 44px; padding: 0 10px; }
  .searchbar .btn { width: 100%; }
  .section__head h2, .filters__title { font-size: 24px; }
  .newsbar__inner { flex-wrap: wrap; }
}

/* Запасной вид карты, если Яндекс недоступен */
.map__fallback { position: absolute; inset: 0; background: var(--surface-2); overflow: hidden; }
.map__hint { position: absolute; left: 14px; right: 14px; bottom: 14px; margin: 0; background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 10px 14px; font-size: 12.5px; color: var(--muted); box-shadow: var(--shadow-sm); }
.map__hint code { background: var(--surface-2); padding: 1px 5px; border-radius: 4px; }
.map__fallback[hidden] { display: none; }

/* ---------- Кабинет ресторана ---------- */
.partner-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 22px; padding: 30px 0 22px; flex-wrap: wrap; }
.partner-head h1 { margin: 2px 0 6px; font-size: 32px; font-weight: 800; }
.partner-head__label { margin: 0; font-size: 13px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--blue-hi); }
.partner-head p { margin: 0; font-size: 14px; }
.partner-head__actions { display: flex; gap: 10px; flex-wrap: wrap; }

.stat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 18px; margin-top: 6px; }
.stat { border: 1px solid var(--line-soft); border-radius: var(--radius); padding: 20px; background: var(--surface); }
.stat__label { margin: 0 0 8px; font-size: 13px; font-weight: 700; color: var(--muted); }
.stat__value { margin: 0 0 4px; font-size: 30px; font-weight: 800; color: var(--blue); letter-spacing: -.02em; }
.stat__sub { margin: 0; font-size: 13px; color: var(--muted); }

.panel code { background: var(--surface-2); padding: 1px 6px; border-radius: 4px; font-size: 13px; }

/* ---------- Тёмная тема ---------- */
:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #05080f;
  --bg-soft: #0a1120;
  --surface: #0f1829;
  --surface-2: #141f36;
  --line: #22304f;
  --line-soft: #1a2440;
  --ink: #e9eefb;
  --muted: #8fa0c4;
  --blue: #2f6bff;
  --blue-hi: #5089ff;
  --blue-deep: #0b1f4d;
  --blue-soft: #16264d;
  --blue-text: #9dc0ff;
  --amber-soft: #2e1b0c;
  --amber-text: #ff9a52;
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, .5);
  --shadow: 0 6px 26px rgba(0, 0, 0, .55);
}
:root[data-theme="dark"] .logo__text { color: #dbe6ff; }
:root[data-theme="dark"] .logo__mark svg g:first-child { fill: #dbe6ff; }
:root[data-theme="dark"] .badge-soft { background: rgba(5, 8, 15, .84); color: var(--ink); border: 1px solid var(--line); box-shadow: none; }
:root[data-theme="dark"] .like { background: rgba(5, 8, 15, .6); color: #fff; }
:root[data-theme="dark"] .like:hover { background: rgba(5, 8, 15, .85); }
:root[data-theme="dark"] .like.is-on { color: var(--orange); }
:root[data-theme="dark"] .toolbar__arrow { background: var(--surface-2); }
:root[data-theme="dark"] .fdrop { background: var(--surface-2); }
:root[data-theme="dark"] .fdrop__box { border-color: #3d4d75; }
:root[data-theme="dark"] .switch i { background: #29354f; }
:root[data-theme="dark"] .range__bubble { background: #fff; color: #05080f; }
:root[data-theme="dark"] .range__bubble::after { border-top-color: #fff; }
:root[data-theme="dark"] .pin__rating { background: #0f1829; color: #fff; }
:root[data-theme="dark"] .modal__backdrop { background: rgba(0, 0, 0, .68); }
:root[data-theme="dark"] .promo__body p { color: #b9caea; }
:root[data-theme="dark"] .tab.is-active { color: var(--blue-hi); border-bottom-color: var(--blue-hi); }
:root[data-theme="dark"] .points-card .btn { background: #fff; color: var(--blue-deep); }
:root[data-theme="dark"] .banner-green h4,
:root[data-theme="dark"] .booking__summary b,
:root[data-theme="dark"] .notice b { color: #fff; }
:root[data-theme="dark"] .newsbar { box-shadow: 0 -4px 18px rgba(0, 0, 0, .5); }

/* ---------- Календарь выбора даты ---------- */
.calendar { border: 1px solid var(--line-soft); border-radius: 12px; padding: 14px 16px 16px; background: var(--surface); }
.calendar__head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 12px; }
.calendar__title { font-size: 16px; font-weight: 800; text-transform: capitalize; }
.calendar__nav { display: flex; gap: 6px; }
.calendar__nav button {
  width: 34px; height: 34px; border-radius: 8px; border: 1px solid var(--line); background: var(--surface);
  color: var(--ink); cursor: pointer; display: grid; place-items: center;
}
.calendar__nav button:hover:not(:disabled) { border-color: var(--blue); color: var(--blue); }
.calendar__nav button:disabled { opacity: .35; cursor: default; }
.calendar__nav .ic { width: 16px; height: 16px; }
.calendar__nav .ic--prev { transform: rotate(180deg); }
.calendar__grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; }
.calendar__dow { text-align: center; font-size: 11.5px; font-weight: 700; color: var(--muted); text-transform: uppercase; padding-bottom: 6px; }
.calendar__day {
  position: relative; aspect-ratio: 1; border: 0; border-radius: 9px; background: transparent; color: var(--ink);
  font-size: 14px; font-weight: 600; cursor: pointer; display: grid; place-items: center;
}
.calendar__day:hover:not(:disabled) { background: var(--blue-soft); }
.calendar__day:disabled { color: var(--muted); opacity: .4; cursor: default; }
.calendar__day.is-today { box-shadow: inset 0 0 0 1.5px var(--line); }
.calendar__day.is-selected { background: var(--blue); color: #fff; font-weight: 800; }
.calendar__day.has-offer::after {
  content: ""; position: absolute; bottom: 6px; width: 4px; height: 4px; border-radius: 50%; background: var(--orange);
}
.calendar__day.is-selected.has-offer::after { background: #fff; }
.calendar__legend { display: flex; align-items: center; gap: 7px; margin-top: 12px; font-size: 12.5px; color: var(--muted); }
.calendar__legend i { width: 6px; height: 6px; border-radius: 50%; background: var(--orange); display: inline-block; }
.calendar__quick { display: flex; gap: 8px; margin-bottom: 12px; flex-wrap: wrap; }
.calendar__quick button {
  height: 34px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--line); background: var(--surface);
  font-size: 13px; font-weight: 700; cursor: pointer; color: var(--ink);
}
.calendar__quick button:hover { border-color: var(--blue); }
.calendar__quick button.is-active { background: var(--blue); border-color: var(--blue); color: #fff; }

/* Переключатели языка и темы */
.pref-row { display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 14px 0; border-bottom: 1px solid var(--line-soft); flex-wrap: wrap; }
.pref-row:last-child { border-bottom: 0; }
.pref-row h4 { margin: 0 0 2px; font-size: 15px; font-weight: 800; }
.pref-row p { margin: 0; font-size: 13px; color: var(--muted); }
.seg-toggle { display: inline-flex; border: 1px solid var(--line); border-radius: 999px; overflow: hidden; }
.seg-toggle button { padding: 9px 16px; border: 0; background: var(--surface); color: var(--ink); font-size: 14px; font-weight: 700; cursor: pointer; }
.seg-toggle button + button { border-left: 1px solid var(--line); }
.seg-toggle button.is-active { background: var(--blue); color: #fff; }
.lang-switch { display: inline-flex; align-items: center; gap: 6px; }
.lang-switch button {
  height: 30px; padding: 0 10px; border-radius: 8px; border: 1px solid transparent; background: none;
  color: var(--muted); font-size: 13px; font-weight: 700; cursor: pointer;
}
.lang-switch button:hover { color: var(--ink); }
.lang-switch button.is-active { background: var(--blue-soft); color: var(--blue); border-color: var(--blue); }
:root[data-theme="dark"] .lang-switch button.is-active { color: #fff; }

/* ---------- Экран входа и регистрации ---------- */
.auth-page { min-height: 100vh; display: grid; place-items: center; padding: 40px 20px; background: var(--bg-soft); }
.auth-card { width: 100%; max-width: 520px; background: var(--surface); border: 1px solid var(--line-soft); border-radius: 18px; padding: 32px; box-shadow: var(--shadow); }
.auth-top { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 26px; }
.auth-title { margin: 0 0 6px; font-size: 28px; font-weight: 800; }
.auth-sub { margin: 0 0 24px; color: var(--muted); font-size: 15px; }
.auth-note { margin: 22px 0 0; font-size: 12.5px; color: var(--muted); line-height: 1.5; }
.auth-error { margin: 0 0 14px; font-size: 14px; font-weight: 600; color: #c2360d; }
:root[data-theme="dark"] .auth-error { color: #ff8f66; }
.auth-back { background: none; border: 0; color: var(--muted); font-size: 14px; font-weight: 700; cursor: pointer; padding: 0 0 12px; }
.auth-back:hover { color: var(--ink); }

.role-grid { display: grid; gap: 14px; }
.role-card {
  display: grid; gap: 6px; text-align: left; padding: 22px; border: 1px solid var(--line); border-radius: 14px;
  background: var(--surface); cursor: pointer; color: var(--ink); transition: border-color .15s ease, background .15s ease;
}
.role-card:hover { border-color: var(--blue); background: var(--blue-soft); }
.role-card__icon { width: 46px; height: 46px; border-radius: 12px; background: var(--blue-soft); color: var(--blue); display: grid; place-items: center; margin-bottom: 6px; }
.role-card__icon .ic { width: 26px; height: 26px; }
.role-card b { font-size: 19px; font-weight: 800; }
.role-card > span:not(.role-card__icon):not(.role-card__go) { font-size: 14px; color: var(--muted); }
.role-card__go { display: inline-flex; align-items: center; gap: 6px; margin-top: 8px; font-size: 13px; font-weight: 800; color: var(--blue); text-transform: uppercase; letter-spacing: .05em; }
.role-card__go .ic { width: 15px; height: 15px; }
@media (max-width: 560px) { .auth-card { padding: 22px; } .auth-title { font-size: 23px; } }

/* ---------- Сети и филиалы ---------- */
.result__meta--chain { display: inline-flex; align-items: center; gap: 6px; color: var(--blue-text); font-weight: 700; }
.result__meta--chain .ic { width: 14px; height: 14px; }
.chain-modal {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%);
  width: min(560px, calc(100% - 32px)); max-height: 84vh; background: var(--surface);
  border-radius: 16px; box-shadow: var(--shadow); overflow: hidden; display: flex; flex-direction: column;
}
.chain-modal .modal__body { overflow-y: auto; padding: 0; }
.chain-modal .list-card { border: 0; border-radius: 0; }
.branch-row { cursor: pointer; }
.branch-row:hover { background: var(--bg-soft); }
.branch-row .list-row__side b { font-size: 15px; color: var(--blue); }
.branch-row .list-row__side small { display: block; font-weight: 600; color: var(--muted); font-size: 12px; }

.branch-switch { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin: 4px 0 14px; }
.branch-switch__label { display: inline-flex; align-items: center; gap: 7px; font-size: 13.5px; color: var(--muted); }
.branch-switch__label b { color: var(--ink); }
.branch-switch__label .ic { width: 15px; height: 15px; color: var(--blue); }
.branch-switch__list { display: flex; gap: 8px; flex-wrap: wrap; }
.branch-switch__list .chip { height: 32px; font-size: 12.5px; }
.branch-tag { display: inline-flex; align-items: center; gap: 6px; color: var(--blue); }
.branch-tag .ic { width: 14px; height: 14px; }

/* ---------- Хостес-панель ---------- */
.partner-sections { margin: 6px 0 24px; }
.hostess__head { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; flex-wrap: wrap; margin-bottom: 20px; }
.hostess__head h2 { margin: 0 0 4px; font-size: 26px; font-weight: 800; }
.hostess__head p { margin: 0; font-size: 14px; max-width: 520px; }
.hostess__date { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.hostess__datepicker {
  height: 42px; padding: 0 12px; border: 1px solid var(--line); border-radius: 999px;
  background: var(--surface); color: var(--ink); font: inherit; font-size: 14px; font-weight: 700;
}
.hostess__legend { display: flex; gap: 18px; flex-wrap: wrap; margin: 22px 0 4px; font-size: 13.5px; color: var(--muted); }
.legend-item { display: inline-flex; align-items: center; gap: 7px; }
.table-dot { width: 11px; height: 11px; border-radius: 50%; display: inline-block; }

.floor { display: grid; grid-template-columns: repeat(auto-fill, minmax(178px, 1fr)); gap: 14px; margin-bottom: 8px; }
.table-card {
  display: grid; gap: 4px; align-content: start; text-align: left; padding: 15px 16px 15px 19px;
  border-radius: 14px; cursor: pointer; position: relative; overflow: hidden;
  border: 1.5px solid var(--line); background: var(--surface); color: var(--ink);
  transition: transform .12s ease, box-shadow .12s ease;
}
/* Цветная полоса статуса слева */
.table-card::before { content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 5px; background: var(--line); }
.table-card:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.table-card__top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.table-card__name { font-size: 17px; font-weight: 800; }
.table-card__seats { display: inline-flex; align-items: center; gap: 4px; font-size: 13px; font-weight: 700; color: var(--muted); }
.table-card__seats .ic { width: 14px; height: 14px; }
.table-card__status { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 700; margin-top: 2px; }
.table-card__line { font-size: 12.5px; color: var(--muted); }
.table-card__flag {
  display: inline-block; align-self: start; margin-top: 4px; font-size: 11.5px; font-weight: 800;
  background: color-mix(in srgb, #e5484d 16%, var(--surface)); color: #c2360d; padding: 3px 9px; border-radius: 999px;
}
.table-card__act {
  margin-top: 9px; height: 32px; border-radius: 9px; border: 1px solid var(--line);
  background: var(--surface); color: var(--blue); font: inherit; font-size: 12.5px; font-weight: 800; cursor: pointer;
}
.table-card__act:hover { background: var(--blue); border-color: var(--blue); color: #fff; }
.table-card.is-late { border-color: #e5484d; }
.table-card.is-late::before { background: #e5484d; }
.table-card.is-free::before { background: #35a26a; }
.table-card.is-reserved::before { background: var(--blue); }
.table-card.is-seated::before { background: var(--orange); }
.table-card.is-cleaning::before { background: #98a2b8; }

/* Статус в списке столов */
.table-status { display: inline-flex; padding: 4px 11px; border-radius: 999px; font-size: 12.5px; font-weight: 700; background: var(--surface-2); color: var(--muted); }
.table-status.is-free { background: color-mix(in srgb, #35a26a 15%, var(--surface)); color: #2f8f5b; }
.table-status.is-reserved { background: var(--blue-soft); color: var(--blue-text); }
.table-status.is-seated { background: var(--amber-soft); color: var(--amber-text); }

/* Плитки смены */
.stat-grid--hostess { grid-template-columns: repeat(auto-fit, minmax(215px, 1fr)); gap: 14px; }
.stat--rich { display: grid; gap: 8px; padding: 18px 20px; }
.stat__head { display: flex; align-items: center; gap: 9px; }
.stat__icon { width: 32px; height: 32px; border-radius: 9px; display: grid; place-items: center; background: var(--blue-soft); color: var(--blue); }
.stat__icon .ic { width: 17px; height: 17px; }
.stat--rich .stat__label { margin: 0; }
.stat__row { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.stat--rich .stat__value { margin: 0; font-size: 28px; }
.stat--orange .stat__icon { background: var(--amber-soft); color: var(--amber-text); }
.stat--orange .stat__value { color: var(--amber-text); }
.stat__bar { display: block; height: 6px; border-radius: 999px; background: var(--surface-2); overflow: hidden; }
.stat__bar i { display: block; height: 100%; border-radius: 999px; background: var(--blue); }
.stat--orange .stat__bar i { background: var(--orange); }
.stat__ring {
  width: 54px; height: 54px; border-radius: 50%; display: grid; place-items: center; flex: none;
  background: conic-gradient(var(--blue) calc(var(--pct) * 1%), var(--surface-2) 0);
}
.stat__ring b { width: 38px; height: 38px; border-radius: 50%; background: var(--surface); }

/* Опоздания */
.hostess__alert {
  display: flex; gap: 12px; align-items: flex-start; margin: 18px 0 4px; padding: 14px 18px;
  border-radius: 12px; background: color-mix(in srgb, #e5484d 10%, var(--surface)); border: 1px solid color-mix(in srgb, #e5484d 35%, var(--surface));
}
.hostess__alert .ic { width: 20px; height: 20px; color: #c2360d; flex: none; margin-top: 2px; }
.hostess__alert b { display: block; font-size: 14.5px; color: #c2360d; }
.hostess__alert p { margin: 3px 0 0; font-size: 13px; color: var(--muted); }

/* Лента ближайших визитов */
.timeline { display: flex; gap: 12px; overflow-x: auto; padding: 4px 2px 12px; scrollbar-width: thin; }
.timeline--empty { color: var(--muted); font-size: 14px; padding: 16px 0; }
.tl-card {
  flex: none; width: 178px; display: grid; gap: 3px; text-align: left; cursor: pointer;
  padding: 13px 15px; border-radius: 12px; border: 1.5px solid var(--line-soft);
  background: var(--surface); color: var(--ink); font: inherit; border-left: 4px solid var(--blue);
}
.tl-card:hover { border-color: var(--blue); box-shadow: var(--shadow-sm); }
.tl-card__time { font-size: 17px; font-weight: 800; color: var(--blue); font-variant-numeric: tabular-nums; }
.tl-card__name { font-size: 13.5px; font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tl-card__meta { font-size: 12px; color: var(--muted); }
.tl-card__left { font-size: 12px; font-weight: 800; color: var(--muted); margin-top: 2px; }
.tl-card.is-arrived { border-left-color: var(--orange); }
.tl-card.is-arrived .tl-card__time { color: var(--amber-text); }
.tl-card.is-late { border-left-color: #e5484d; background: color-mix(in srgb, #e5484d 6%, var(--surface)); }
.tl-card.is-late .tl-card__left { color: #c2360d; }
.tl-card__actions { display: flex; gap: 6px; margin-top: 8px; }
.tl-card__seat, .tl-card__cancel {
  flex: 1 1 0; min-width: 0; height: 30px; border-radius: 8px; border: 1px solid var(--line);
  background: var(--surface); font: inherit; font-size: 11.5px; font-weight: 800; cursor: pointer; padding: 0 4px;
}
.tl-card__seat { color: var(--blue); }
.tl-card__seat:hover { background: var(--blue); border-color: var(--blue); color: #fff; }
.tl-card__cancel { color: #c2360d; }
.tl-card__cancel:hover { background: #e5484d; border-color: #e5484d; color: #fff; }

/* Отчёты */
.reports__tools { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.reports__period { margin: 0 0 18px; font-size: 13.5px; font-weight: 700; color: var(--muted); }
.bar-cell {
  position: relative; display: inline-flex; align-items: center; min-width: 46px; padding: 3px 10px;
  border-radius: 6px; font-weight: 800; color: var(--blue-text); overflow: hidden;
}
.bar-cell::before { content: ''; position: absolute; inset: 0; width: var(--w); background: var(--blue-soft); border-radius: 6px; }
.bar-cell { z-index: 0; }
.bar-cell::before { z-index: -1; }

/* Отчёты: сравнение, графики, печать */
.reports__actions { display: flex; gap: 8px; }
.reports__custom { display: flex; gap: 14px; flex-wrap: wrap; margin: 0 0 14px; }
.reports__custom .field { margin: 0; }
.reports__vs { display: block; font-weight: 600; color: var(--muted); font-size: 12.5px; margin-top: 2px; }
.delta { font-size: 12.5px; font-weight: 800; padding: 3px 9px; border-radius: 999px; white-space: nowrap; }
.delta--up { background: color-mix(in srgb, #35a26a 16%, var(--surface)); color: #2f8f5b; }
.delta--down { background: color-mix(in srgb, #e5484d 14%, var(--surface)); color: #c2360d; }
.delta--flat { background: var(--surface-2); color: var(--muted); }
.reports__hl {
  display: flex; align-items: center; gap: 10px; margin: 18px 0 4px; padding: 14px 18px;
  border-radius: 12px; background: var(--blue-soft); color: var(--blue-text); font-size: 14px; font-weight: 700;
}
.reports__hl .ic { width: 18px; height: 18px; flex: none; }

.week-chart { display: flex; align-items: flex-end; gap: 8px; padding: 18px 20px; }
.week-chart__col { flex: 1; display: grid; justify-items: center; gap: 4px; }
.week-chart__col i { display: block; width: 100%; max-width: 30px; border-radius: 6px 6px 3px 3px; background: var(--blue-soft); }
.week-chart__col b { font-size: 11.5px; font-weight: 800; color: var(--blue); min-height: 14px; }
.week-chart__col span { font-size: 11.5px; color: var(--muted); }

.party-stack { display: grid; gap: 7px; }
.party-stack__row { display: grid; grid-template-columns: 34px 1fr 28px; align-items: center; gap: 10px; font-size: 12.5px; }
.party-stack__row i { display: block; height: 8px; border-radius: 999px; background: var(--orange); min-width: 3px; }
.party-stack__row b { text-align: right; font-weight: 800; }
.admin-table tr.is-current { background: var(--blue-soft); }
.admin-table tr.is-current td { font-weight: 700; }

@media print {
  .header, .footer, .partner-head__actions, .partner-sections,
  .reports__tools, .reports__custom { display: none !important; }
  .work-grid { grid-template-columns: 1fr; }
  .work-card, .stat { break-inside: avoid; box-shadow: none; }
  .work-card__body { max-height: none; overflow: visible; }
}

/* Подбор стола под компанию */
.party-bar {
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin: 14px 0 2px;
  padding: 12px 16px; border-radius: 12px; background: var(--surface-2);
}
.party-bar__label { display: inline-flex; align-items: center; gap: 8px; font-size: 13.5px; font-weight: 800; }
.party-bar__label .ic { width: 16px; height: 16px; color: var(--blue); }
.party-bar__hint { font-size: 13px; font-weight: 700; color: var(--blue); }
.guests--inline { display: flex; gap: 8px; margin: 0; }
.guests--inline .guest { width: 42px; height: 38px; }

/* Подсветка подходящих столов */
.table-card.is-match { border-color: var(--orange); box-shadow: 0 0 0 3px color-mix(in srgb, var(--orange) 22%, transparent); }
.table-card.is-dim { opacity: .45; }
.table-card__line--free { color: #2f8f5b; font-weight: 700; }
/* Детские стулья */
.table-card__chairs { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; font-weight: 700; color: var(--amber-text); }
.table-card__chairs .ic { width: 14px; height: 14px; }
.chair-row {
  display: flex; align-items: center; gap: 14px; flex-wrap: wrap; margin-top: 18px;
  padding: 12px 16px; border-radius: 12px; background: var(--surface-2);
}
.chair-row__label { display: inline-flex; align-items: center; gap: 8px; font-size: 13.5px; font-weight: 800; }
.chair-row__label .ic { width: 17px; height: 17px; color: var(--amber-text); }
.chair-row__ctrl { display: inline-flex; align-items: center; gap: 10px; margin-left: auto; }
.chair-row__ctrl b { min-width: 22px; text-align: center; font-size: 17px; font-weight: 800; font-variant-numeric: tabular-nums; }
.chair-row__hint { flex: 1 1 100%; font-size: 12.5px; color: var(--muted); }
.chair-btn {
  width: 36px; height: 36px; border-radius: 10px; border: 1px solid var(--line); background: var(--surface);
  color: var(--blue); font: inherit; font-size: 19px; font-weight: 800; cursor: pointer; line-height: 1;
}
.chair-btn:hover:not(:disabled) { background: var(--blue); border-color: var(--blue); color: #fff; }
.chair-btn:disabled { opacity: .4; cursor: default; }

.table-card__note { font-size: 12px; color: var(--blue-text); display: inline-flex; align-items: center; gap: 5px; }
.table-card__note .ic { width: 13px; height: 13px; }
.table-card__flag--ok { background: var(--amber-soft); color: var(--amber-text); }
.phone-link { text-decoration: underline; }
.phone-link:hover { color: var(--blue); }

/* Панель инструментов зала */
.hostess__tools { display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; margin: 18px 0 2px; }
/* Нижний блок хостес-панели: брони, лист ожидания, новая бронь */
.work-grid { display: grid; grid-template-columns: 1.35fr 1fr; gap: 20px; margin-top: 30px; align-items: start; }
.work-card { border: 1px solid var(--line-soft); border-radius: var(--radius); background: var(--surface); overflow: hidden; }
.work-card--wide { grid-column: 1 / -1; }
.work-card__head {
  display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap;
  padding: 16px 20px; border-bottom: 1px solid var(--line-soft); background: var(--surface-2);
}
.work-card__head h3 { margin: 0; font-size: 16px; font-weight: 800; display: inline-flex; align-items: center; gap: 9px; }
.work-card__head small { font-size: 12.5px; color: var(--muted); text-transform: lowercase; }
.count-badge {
  min-width: 24px; height: 24px; padding: 0 8px; border-radius: 999px; background: var(--blue); color: #fff;
  font-size: 12.5px; font-weight: 800; display: inline-grid; place-items: center;
}
.work-card__tools { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; padding: 14px 20px; border-bottom: 1px solid var(--line-soft); }
.work-card__tools .admin-search { flex: 1 1 260px; min-width: 220px; }
.work-card__tools .admin-search input { height: 40px; }
.work-card__body { max-height: 460px; overflow-y: auto; }
.work-card__body .list-card { border: 0; border-radius: 0; }
.work-card__body .list-row:last-child { border-bottom: 0; }
.chip--sm { height: 32px; padding: 0 13px; font-size: 12.5px; }
.empty--tight { padding: 30px 20px; }
.work-card__form {
  display: grid; grid-template-columns: 1.3fr 1.2fr 120px 110px auto; gap: 14px; align-items: end;
  padding: 18px 20px; border-top: 1px solid var(--line-soft);
}
.work-card__form .field { margin: 0; position: relative; }
/* Подсказка о постоянном госте под полем телефона */
.guest-hint {
  display: flex; align-items: center; gap: 6px; margin: 6px 0 0;
  font-size: 12px; font-weight: 700; color: var(--amber-text);
}
.guest-hint .ic { width: 13px; height: 13px; flex: none; }
.work-card__form .field input { width: 100%; }
.work-card__form .btn { margin-bottom: 1px; white-space: nowrap; }
.work-card__form--wait { grid-template-columns: 1fr 110px auto; }

/* В карточке строки переносятся: кнопки уходят под текст, а не сжимают его */
.work-card .list-row { flex-wrap: wrap; row-gap: 4px; }
.work-card .list-row__main { flex: 1 1 220px; min-width: 180px; }
/* Кнопки действий переносим под текст, а обычные цифры оставляем справа */
.work-card .list-row__side.hostess__actions { flex: 1 1 100%; text-align: left; }
.work-card .hostess__actions { justify-content: flex-start; margin-top: 4px; }
.work-card .list-row__main h4 { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }

@media (max-width: 1080px) {
  .work-grid { grid-template-columns: 1fr; }
  .work-card__form { grid-template-columns: 1fr 1fr; }
  .work-card__form--wait { grid-template-columns: 1fr 110px; }
  .work-card__form .btn { grid-column: 1 / -1; }
}
.list-row.is-late { background: color-mix(in srgb, #e5484d 6%, var(--surface)); }
.tag-chair {
  font-style: normal; display: inline-flex; align-items: center; gap: 4px; font-size: 11.5px; font-weight: 800;
  color: var(--amber-text); background: var(--amber-soft); padding: 2px 8px; border-radius: 999px;
}
.tag-chair .ic { width: 12px; height: 12px; }
.tl-card__chair { display: inline-flex; align-items: center; gap: 4px; font-size: 11.5px; font-weight: 800; color: var(--amber-text); }
.tl-card__chair .ic { width: 12px; height: 12px; }
.tag-late { font-style: normal; font-size: 11.5px; font-weight: 800; color: #c2360d; margin-left: 6px; }

.table-card.is-free { border-color: #cfe0d6; background: color-mix(in srgb, #35a26a 8%, var(--surface)); }
.table-card.is-free .table-card__status { color: #2f8f5b; }
.table-dot.is-free { background: #35a26a; }

.table-card.is-reserved { border-color: var(--blue); background: var(--blue-soft); }
.table-card.is-reserved .table-card__status { color: var(--blue); }
.table-dot.is-reserved { background: var(--blue); }

.table-card.is-seated { border-color: var(--orange); background: color-mix(in srgb, var(--orange) 10%, var(--surface)); }
.table-card.is-seated .table-card__status { color: #c2560d; }
.table-dot.is-seated { background: var(--orange); }

.table-card.is-cleaning { border-color: #c9ceda; background: var(--surface-2); }
.table-card.is-cleaning .table-card__status { color: var(--muted); }
.table-dot.is-cleaning { background: #98a2b8; }

:root[data-theme="dark"] .table-card.is-seated .table-card__status { color: var(--orange); }
:root[data-theme="dark"] .table-card.is-free .table-card__status { color: #56c68c; }

.table-modal {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%);
  width: min(460px, calc(100% - 32px)); background: var(--surface); border-radius: 16px;
  box-shadow: var(--shadow); overflow: hidden; max-height: 86vh; display: flex; flex-direction: column;
}
.table-modal .modal__body { overflow-y: auto; }
.hostess__actions { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
@media (max-width: 720px) {
  .hostess__head { flex-direction: column; }
  .floor { grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); }
}

/* Стол, который держим под бронь */
.table-card.is-locked { border-style: dashed; opacity: .92; }
.table-card__lock { font-size: 12px; font-weight: 700; color: var(--blue); }
.table-dot.is-locked { background: repeating-linear-gradient(45deg, var(--blue), var(--blue) 3px, #fff 3px, #fff 5px); }
.table-card.is-target { border-color: var(--orange); box-shadow: 0 0 0 3px color-mix(in srgb, var(--orange) 25%, transparent); }
.zone-input {
  width: 100%; max-width: 260px; height: 36px; padding: 0 10px; border: 1px solid transparent; border-radius: 8px;
  background: transparent; color: var(--ink); font: inherit; font-size: 15px; font-weight: 800;
}
.zone-input:hover { border-color: var(--line); }
.zone-input:focus { border-color: var(--blue); background: var(--surface); outline: none; }

/* Ташкентское время */
.tz-clock {
  display: inline-flex; align-items: center; gap: 8px; height: 42px; padding: 0 14px;
  border: 1px solid var(--line); border-radius: 999px; background: var(--surface); font-size: 14px;
}
.tz-clock b { font-size: 15px; font-weight: 800; font-variant-numeric: tabular-nums; }
.tz-clock small { color: var(--muted); font-size: 12.5px; }
.tz-clock .ic { width: 16px; height: 16px; color: var(--blue); }
.booking__tz { display: flex; align-items: center; gap: 6px; margin: 8px 0 0 !important; font-size: 12.5px; color: var(--muted); }
.booking__tz .ic { width: 14px; height: 14px; }

.table-modal__booking {
  display: grid; gap: 3px; margin-top: 14px; padding: 14px 16px; border-radius: 12px;
  background: var(--blue-soft); color: var(--blue-text);
}
.table-modal__booking b { font-size: 16px; color: var(--blue-deep); }
.table-modal__booking span { font-size: 13.5px; }
:root[data-theme="dark"] .table-modal__booking b { color: #fff; }

/* ---------- Редактор меню в кабинете ---------- */
.admin { padding-top: 8px; }
.admin-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin: 6px 0 16px; flex-wrap: wrap; }
.admin-head h3 { margin: 0; font-size: 20px; font-weight: 800; }
.admin-crumbs { display: flex; align-items: center; gap: 10px; font-size: 14px; color: var(--muted); margin-bottom: 14px; flex-wrap: wrap; }
.admin-crumbs button { background: none; border: 0; padding: 0; cursor: pointer; color: var(--blue); font: inherit; }
.admin-crumbs b { color: var(--ink); }

.admin-search { position: relative; flex: 1; max-width: 340px; }
.admin-search .ic { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); width: 18px; height: 18px; color: var(--muted); }
.admin-search input {
  width: 100%; height: 44px; padding: 0 14px 0 42px; border: 1px solid var(--line); border-radius: 10px;
  background: var(--surface); color: var(--ink); font: inherit; font-size: 15px; outline: none;
}
.admin-search input:focus { border-color: var(--blue); }

.admin-table-wrap { border: 1px solid var(--line-soft); border-radius: var(--radius); overflow-x: auto; background: var(--surface); }
.admin-table { width: 100%; border-collapse: collapse; font-size: 14px; min-width: 760px; }
.admin-table th {
  text-align: left; padding: 14px 16px; font-size: 13px; font-weight: 800; color: var(--muted);
  border-bottom: 1px solid var(--line-soft); white-space: nowrap;
}
.admin-table td { padding: 12px 16px; border-bottom: 1px dashed var(--line-soft); vertical-align: middle; }
.admin-table tbody tr { cursor: pointer; }
.admin-table tbody tr:hover { background: var(--bg-soft); }
.admin-table tbody tr:last-child td { border-bottom: 0; }
.admin-table__name { font-weight: 700; }
.admin-table__name small { display: block; font-weight: 500; color: var(--muted); font-size: 12.5px; }
.admin-table__slug { color: var(--muted); font-size: 13px; }
.admin-table__price { color: var(--blue); font-weight: 700; white-space: nowrap; }
.admin-table__empty { text-align: center; color: var(--muted); padding: 30px 16px; }

.admin-thumb { width: 56px; height: 44px; border-radius: 8px; object-fit: cover; display: grid; place-items: center; }
.admin-thumb--empty { background: var(--surface-2); font-size: 22px; }

.pill-status { display: inline-flex; padding: 5px 12px; border-radius: 999px; font-size: 12.5px; font-weight: 700; }
.pill-status.is-on { background: color-mix(in srgb, #35a26a 16%, var(--surface)); color: #2f8f5b; }
.pill-status.is-off { background: color-mix(in srgb, #e5484d 14%, var(--surface)); color: #c2360d; }
.pill-status.is-soon { background: var(--blue-soft); color: var(--blue-text); }
.pill-status.is-muted { background: var(--surface-2); color: var(--muted); }

/* Кнопки под бронью в кабинете гостя */
.booking-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; margin-top: 9px; }
.booking-actions .btn { flex: none; }
.booking-hint { font-size: 12.5px; color: var(--muted); }

/* Список столов в кабинете: строка открывает настройку */
.list-row--tap { cursor: pointer; }
.list-row--tap:hover { background: var(--bg-soft); }
.list-row--edit { flex-wrap: wrap; background: var(--bg-soft); }
.table-edit { display: flex; gap: 12px; flex: 1; min-width: 260px; }
.table-edit .field { flex: 1; }
.table-edit input, .table-edit select { width: 100%; }
.table-edit label { font-size: 12px; }
/* Строка брони на узком экране: статус сверху справа, текст и кнопки — во всю ширину */
@media (max-width: 640px) {
  .list-row--booking { flex-wrap: wrap; align-items: flex-start; padding: 14px 15px; gap: 8px 12px; }
  .list-row--booking .list-row__icon { width: 36px; height: 36px; order: -2; }
  .list-row--booking .list-row__side { order: -1; margin-left: auto; text-align: right; }
  .list-row--booking .list-row__main { flex: 1 1 100%; }
  .list-row--booking .booking-actions { width: 100%; }
  .list-row--booking .booking-actions .btn { flex: 1 1 46%; padding: 0 10px; }
  .list-row--booking .booking-hint { flex: 1 1 100%; }
}

.icon-btn { width: 36px; height: 36px; border-radius: 8px; border: 1px solid var(--line); background: var(--surface); color: var(--blue); cursor: pointer; display: grid; place-items: center; }
.icon-btn:hover { border-color: var(--blue); }
.icon-btn .ic { width: 18px; height: 18px; }

.item-form { display: grid; grid-template-columns: 180px 1fr; gap: 24px; align-items: start; }
.photo-drop {
  display: grid; place-items: center; gap: 8px; width: 100%; aspect-ratio: 1; border: 2px dashed var(--line);
  border-radius: 12px; cursor: pointer; overflow: hidden; position: relative; background: var(--surface-2); text-align: center;
}
.photo-drop:hover { border-color: var(--blue); }
.photo-drop img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.photo-drop span { font-size: 42px; }
.photo-drop b { position: absolute; left: 0; right: 0; bottom: 0; padding: 8px; font-size: 12.5px; background: rgba(15, 30, 66, .72); color: #fff; }

.lang-fields { display: grid; gap: 8px; }
.lang-field { display: grid; grid-template-columns: 34px 1fr; gap: 10px; align-items: center; }
.lang-field span { font-size: 12px; font-weight: 800; color: var(--muted); }
.lang-field input, .lang-field textarea {
  width: 100%; padding: 10px 12px; border: 1px solid var(--line); border-radius: 8px;
  background: var(--surface); color: var(--ink); font: inherit; font-size: 14px; outline: none; resize: vertical;
}
.lang-field input { height: 42px; padding: 0 12px; }
.lang-field input:focus, .lang-field textarea:focus { border-color: var(--blue); }

.admin-form-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 22px; }

@media (max-width: 720px) {
  .item-form { grid-template-columns: 1fr; }
  .photo-drop { aspect-ratio: 16 / 9; }
}

/* Блюдо с фотографией */
.dish--rich { grid-template-columns: 72px 1fr auto; align-items: start; column-gap: 16px; }
.dish__photo { grid-row: span 2; width: 72px; height: 72px; border-radius: 10px; object-fit: cover; display: grid; place-items: center; }
.dish__photo--empty { background: var(--surface-2); font-size: 28px; }
.dish--rich .dish__desc { grid-column: 2 / -1; }

/* Фотографии заведения */
.photo-drop--wide { aspect-ratio: 16 / 10; }
.gallery-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.gallery-cell { position: relative; aspect-ratio: 1; border-radius: 10px; overflow: hidden; background: var(--surface-2); }
.gallery-cell img { width: 100%; height: 100%; object-fit: cover; }
.gallery-cell__del {
  position: absolute; right: 6px; top: 6px; width: 26px; height: 26px; border-radius: 50%;
  border: 0; background: rgba(15, 30, 66, .72); color: #fff; font-size: 16px; cursor: pointer; line-height: 1;
}
.gallery-cell__del:hover { background: rgba(15, 30, 66, .92); }
.gallery-cell--add {
  display: grid; place-items: center; gap: 2px; border: 2px dashed var(--line); cursor: pointer; color: var(--muted);
}
.gallery-cell--add:hover { border-color: var(--blue); color: var(--blue); }
.gallery-cell--add span { font-size: 26px; font-weight: 700; }
.gallery-cell--add small { font-size: 11.5px; }
.photo--img { object-fit: cover; }

/* Настройки и выход в шапке профиля */
.profile-head { align-items: flex-start; }
.profile-head__main { flex: 1; min-width: 240px; }
.profile-head__tools { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-left: auto; }
.profile-head__tools .seg-toggle button { padding: 8px 14px; font-size: 13.5px; }
@media (max-width: 720px) {
  .profile-head__tools { margin-left: 0; width: 100%; }
}

/* Выбор рабочей даты в хостес-панели */
.date-nav { display: flex; align-items: center; gap: 8px; }
.date-nav__arrow {
  width: 42px; height: 42px; border-radius: 50%; border: 1px solid var(--line); background: var(--surface);
  color: var(--ink); cursor: pointer; display: grid; place-items: center;
}
.date-nav__arrow:hover { border-color: var(--blue); color: var(--blue); }
.date-nav__arrow .ic { width: 18px; height: 18px; }
.date-nav__arrow .ic--prev { transform: rotate(180deg); }
.date-nav__value {
  display: inline-flex; align-items: center; gap: 10px; height: 42px; padding: 0 16px; border-radius: 999px;
  border: 1px solid var(--line); background: var(--surface); color: var(--ink); font: inherit; font-size: 14px; cursor: pointer;
}
.date-nav__value:hover { border-color: var(--blue); }
.date-nav__value b { font-weight: 800; text-transform: capitalize; }
.date-nav__value em { font-style: normal; font-size: 12px; font-weight: 700; color: var(--blue); background: var(--blue-soft); padding: 2px 8px; border-radius: 999px; }
.date-nav__value .ic { width: 18px; height: 18px; color: var(--muted); }
.date-nav__value .ic--caret { width: 13px; height: 13px; }

/* Список сортировки */
.fbtn--sort { gap: 8px; }
.fbtn--sort .fbtn__label { color: var(--muted); font-weight: 600; }
.fbtn--sort b { font-weight: 800; }
.fdrop--right { left: auto; right: 0; width: 300px; }
.sort-option {
  display: flex; align-items: center; justify-content: space-between; gap: 12px; width: 100%;
  padding: 12px 22px; border: 0; background: none; color: var(--ink); font: inherit; font-size: 15px;
  text-align: left; cursor: pointer;
}
.sort-option:hover { background: var(--bg-soft); }
.sort-option.is-active { color: var(--blue); font-weight: 800; }
.sort-option .ic { width: 18px; height: 18px; color: var(--blue); }
@media (max-width: 640px) {
  .fdrop--right { right: auto; left: 0; width: min(300px, calc(100vw - 40px)); }
}

/* Выбор адреса на карте */
.address-row { display: flex; gap: 10px; align-items: center; }
.address-row input { flex: 1; }
.address-row .btn { flex: none; white-space: nowrap; }
.address-row .btn .ic { width: 16px; height: 16px; }

.picker-modal {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%);
  width: min(720px, calc(100% - 32px)); max-height: 88vh; background: var(--surface);
  border-radius: 16px; box-shadow: var(--shadow); overflow: hidden; display: flex; flex-direction: column;
}
.picker-modal__map { height: min(60vh, 460px); }
#ymap-picker { width: 100%; height: 100%; }
.picker-modal__foot {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 16px 22px; border-top: 1px solid var(--line-soft); flex-wrap: wrap;
}
.picker-modal__address { display: grid; gap: 2px; min-width: 0; }
.picker-modal__address b { font-size: 15px; }
.picker-modal__address span { font-size: 12.5px; color: var(--muted); font-variant-numeric: tabular-nums; }

.map-picker__dot {
  width: 22px; height: 22px; border-radius: 50%; background: var(--orange); border: 3px solid #fff;
  box-shadow: 0 2px 8px rgba(15, 30, 66, .45); transform: translate(-50%, -50%);
}

/* ---------- Телефон ----------
   Колонка сетки по умолчанию не уже своего содержимого, поэтому длинное фото
   или строка вкладок растягивали страницу вбок. min-width: 0 это снимает. */
.layout-2 > *, .results-layout > *, .work-grid > *, .grid-2 > *, .row-4 > * { min-width: 0; }

@media (max-width: 900px) {
  /* Карточка бронирования встаёт в поток: липкой ей уже негде держаться */
  .booking { position: static; }
  .results-map { position: relative; top: 0; height: 340px; }
}

@media (max-width: 640px) {
  /* Шапка компактная и не липкая — иначе на телефоне она съедает треть экрана */
  .header { position: static; }
  .topbar__inner { height: 34px; gap: 8px; font-size: 12.5px; }
  .header__inner { height: auto; padding: 10px 0; gap: 10px; }
  .logo__mark { width: 46px; height: 27px; }
  .logo__text { font-size: 21px; }
  .header__nav { gap: 2px; }
  .icon-link { padding: 0 8px; }
  .icon-link__name { display: none; }
  /* Поиск в две строки: запрос сверху, город и кнопка — снизу */
  .searchbar { gap: 8px; padding: 8px; }
  .searchbar__field { height: 42px; flex: 1 1 100%; order: 1; }
  .searchbar__field--city { order: 2; flex: 1 1 auto; border-right: 0; }
  .searchbar .btn { order: 3; width: auto; flex: 0 0 auto; height: 42px; padding: 0 20px; }

  /* iOS увеличивает страницу при фокусе, если шрифт поля меньше 16px */
  input, select, textarea,
  .field input, .field select, .field textarea,
  .lang-field input, .lang-field textarea, .zone-input { font-size: 16px; }

  /* Подборки на телефоне листаются вбок, как на витрине приложения,
     а не растягиваются на весь экран по одной карточке */
  .row-4, .rail {
    display: flex; grid-template-columns: none; gap: 12px;
    overflow-x: auto; scroll-snap-type: x mandatory; -webkit-overflow-scrolling: touch;
    margin: 0 -18px; padding: 2px 18px 8px; scrollbar-width: none;
  }
  .row-4::-webkit-scrollbar, .rail::-webkit-scrollbar { display: none; }
  .row-4 > .promo, .row-4 .card { flex: 0 0 74%; scroll-snap-align: start; }
  /* Лента рекомендаций мельче: помещается две карточки и начало третьей */
  .rail > .card { flex: 0 0 43%; scroll-snap-align: start; }

  /* Карточки в подборках чуть мельче, чем в общем списке */
  .rail .card__body, .row-4 .card__body { padding: 12px 13px 14px; gap: 4px; }
  .row-4 .card__name { font-size: 15.5px; }
  .row-4 .card__score b { font-size: 15.5px; }
  .row-4 .card__meta { font-size: 13px; }
  .row-4 .card__bookings { font-size: 11.5px; }
  .row-4 .pill-offer { font-size: 11.5px; padding: 4px 8px; }
  .row-4 .promo .photo { height: 140px; }
  .row-4 .promo__body { padding: 16px 18px 18px; }
  .row-4 .promo__body h3 { font-size: 20px; }
  .row-4 .promo__body p { font-size: 13.5px; margin-bottom: 12px; }

  /* Заголовки и отступы под узкий экран */
  .layout-2 { gap: 22px; }
  .tab-panel { padding: 20px 0 34px; }
  .rest-row { font-size: 14px; flex-wrap: wrap; row-gap: 4px; }
  .chip-soft { font-size: 12.5px; }
  .section { padding: 30px 0; }
  /* Полоса городов теперь скрыта, и после ленты рекомендаций перед фильтрами
     оставались чужие двойные отступы секций — сверху зазор ощутимо больше, чем
     нужно, поэтому его специально ужимаем именно здесь */
  #catalog { padding-top: 8px; }
  .section__head { gap: 12px; }
  .section__head h2 { font-size: 20px; }
  .section__head a { flex: none; white-space: nowrap; font-size: 13px; }
  .section-title { font-size: 19px; margin: 24px 0 12px; }
  .rest-title h1 { font-size: 24px; }
  .partner-head h1, .hostess__head h2 { font-size: 22px; }

  /* Кнопки избранного и «Поделиться» держим рядом, не растягивая заголовок */
  .rest-title { gap: 10px; }
  .rest-fav, .rest-share { width: 40px; height: 40px; }
  .share-nets { gap: 9px; }
  .share-net { padding: 13px 4px; font-size: 12.5px; }
  .share-net__ic svg { width: 36px; height: 36px; }
  .share-link { flex-direction: column; }
  .share-link input { font-size: 16px; }        /* меньше — и iOS увеличит страницу */
  .promo__body h3 { font-size: 22px; }

  /* Вкладки листаются пальцем */
  /* Шапка на телефоне не липкая — полоса вкладок держится у самого верха */
  .tabs--sticky { top: 0; }
  .tabs { gap: 0; margin-top: 18px; scrollbar-width: none; -webkit-overflow-scrolling: touch; }
  .tabs::-webkit-scrollbar { display: none; }
  .tab { padding: 12px 11px; font-size: 14px; }

  /* Кабинет гостя */
  .profile-head { gap: 14px; padding: 20px 0 16px; }
  .profile-avatar { width: 64px; height: 64px; font-size: 21px; }
  .profile-head__name { width: 100%; gap: 8px; }
  .profile-head__name input { width: auto; flex: 1 1 130px; height: 42px; }
  .profile-head__tools { gap: 8px; }
  .profile-head__tools .btn { flex: 1 1 100%; }

  /* Плитки по две в ряд, а не по одной на весь экран */
  .stat-grid, .stat-grid--hostess { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .stat { padding: 14px; }
  .stat--rich { padding: 14px; gap: 6px; }
  .stat__value, .stat--rich .stat__value { font-size: 22px; }
  .stat__label { font-size: 12px; }
  .stat__sub { font-size: 12px; }
  .stat__icon { width: 28px; height: 28px; }

  /* Хостес-панель: столы мельче, действия во всю ширину */
  .floor { grid-template-columns: repeat(auto-fill, minmax(104px, 1fr)); gap: 10px; }
  .table-card { padding: 12px; }
  .table-card__name { font-size: 14.5px; }
  .table-card__status, .table-card__seats { font-size: 12px; }
  .table-card__line { font-size: 11.5px; }
  .hostess__legend { gap: 10px 14px; font-size: 12.5px; }
  .hostess__actions { justify-content: flex-start; }
  .hostess__actions .btn { flex: 1 1 auto; }
  .work-card__form, .work-card__form--wait { grid-template-columns: 1fr; }
  .date-nav__value { padding: 0 12px; font-size: 13px; }

  /* Каталог как в мобильных приложениях: карта на весь экран, список — шторкой поверх.
     Потянул список вниз — открылась карта. */
  .container { padding: 0 18px; }
  #catalog .filters__title { font-size: 22px; }
  #catalog .filters__sub { font-size: 13.5px; margin-bottom: 14px; }
  .toolbar { position: sticky; top: 0; z-index: 30; background: var(--bg); padding: 10px 0 8px; margin: 0 -18px; gap: 8px; }
  /* Дата, время и гости занимают всю ширину экрана, фильтры листаются под ними */
  .toolbar__pick { padding: 0 18px; }
  .toolbar__pick .fdrop-wrap, .toolbar__pick .seg { width: 100%; }
  /* Три кнопки делят ширину поровну и не переносятся на вторую строку */
  .toolbar__pick .seg__item { flex: 1; min-width: 0; justify-content: center; gap: 5px; padding: 0 6px; font-size: 13.5px; white-space: nowrap; }
  .toolbar__pick .seg__item .ic { width: 16px; height: 16px; }
  .toolbar__pick .seg__item .ic--caret { width: 12px; height: 12px; }
  .toolbar__scroll { padding: 2px 18px; }
  .toolbar__arrow { display: none; }

  .results-layout { display: block; position: relative; padding-bottom: 0; }
  .results-map {
    position: sticky; top: 56px; height: calc(100vh - 56px); height: calc(100dvh - 56px);
    margin: 0 -18px; border-radius: 0;
  }
  .results-sheet {
    /* По умолчанию список закрывает карту целиком — никакой полоски карты
       не видно, открыть её можно только кнопкой в строке поиска или ручкой.
       Скруглённые углы срезали бы уголки и в них проглядывала бы карта — поэтому
       в закрытом виде углы прямые, скругление появляется только когда шторку
       утянули вниз (см. .results-layout.is-map ниже) */
    position: relative; z-index: 10; margin: calc(-100dvh + 56px) -18px 0;
    padding: 14px 18px 24px; background: var(--surface);
    border-radius: 0; box-shadow: 0 -8px 24px rgba(15, 30, 66, .16);
    transition: transform .28s ease, border-radius .28s ease;
  }
  /* Пока список закрывает карту, тянуть и нажимать нечего — ручки нет совсем,
     карту открывает только кнопка. Ручка появляется, только когда карта уже
     открыта (см. .results-layout.is-map ниже) — ей список возвращают обратно */
  .sheet-grab { display: none; }
  .results-layout.is-map .sheet-grab {
    display: block; width: 100%; height: 30px; padding: 0; border: 0; background: none;
    position: relative; cursor: grab; touch-action: manipulation;
  }
  .sheet-grab::before {
    content: ''; position: absolute; left: 50%; top: 11px; transform: translateX(-50%);
    width: 46px; height: 5px; border-radius: 999px; background: var(--line);
  }
  .sheet-grab:active::before { background: var(--blue); }
  /* Квадратная кнопка карты справа от поля поиска */
  .searchbar__map {
    display: grid; place-items: center; flex: 0 0 auto; order: 1;
    width: 42px; height: 42px; padding: 0; border: 1px solid var(--line); border-radius: 10px;
    background: var(--surface); color: var(--blue); cursor: pointer;
  }
  .searchbar__map:active { background: var(--blue-soft); }
  .searchbar__map svg { width: 21px; height: 21px; }

  /* Поле поиска делит первую строку с кнопкой карты, город и «Найти» уходят вниз */
  .searchbar__field { flex: 1 1 calc(100% - 52px); }
  .searchbar__field--city { flex: 1 1 55%; }

  /* Когда карта открыта, ручка становится стрелкой вверх: потяните — вернётся список */
  .results-layout.is-map .sheet-grab { height: 38px; }
  .results-layout.is-map .sheet-grab::before { width: 0; height: 0; }
  .results-layout.is-map .sheet-grab::after {
    content: ''; position: absolute; left: 50%; top: 13px; width: 13px; height: 13px;
    border-left: 2.5px solid var(--blue); border-top: 2.5px solid var(--blue); border-radius: 2px;
    transform: translateX(-50%) rotate(45deg);
  }
  .results-head { padding: 4px 0 10px; }
  .results-list { padding-bottom: 10px; }
  /* Фото ресторана широкое, как в мобильных приложениях, а не квадрат */
  .result__media { aspect-ratio: 16 / 10; min-height: 0; }
  .result__media .photo { height: 100%; }
  .map__zoom { bottom: auto; top: 12px; }

  /* Карточка бронирования: полоса шагов целиком помещается в экран */
  .booking__head { padding: 18px 16px 14px; }
  .booking__head h3 { font-size: 21px; }
  .booking__body { padding: 16px; }
  .stepper { margin: 14px 16px 0; }
  .stepper__item { padding: 8px 10px; gap: 5px; font-size: 13px; }
  .stepper__item .ic { width: 16px; height: 16px; }
  .stepper__arrow { width: 10px; }

  /* Адрес и кнопка выбора на карте — в столбик, иначе поле сжимается */
  .address-row { flex-wrap: wrap; }
  .address-row input { flex: 1 1 100%; }
  .address-row .btn { width: 100%; }

  /* Диалоги на весь экран */
  .modal__panel { width: 100%; border-left: 0; }
  .modal__head, .modal__foot { padding: 14px 16px; }
  .modal__body { padding: 4px 16px 16px; }
  .table-modal, .picker-modal { width: calc(100% - 20px); max-height: 90vh; }
  .picker-modal__map { height: min(50vh, 320px); }

  /* Действия карточек и форм переносятся, а не сжимаются */
  .admin-form-actions .btn, .reports__actions .btn { flex: 1 1 auto; }
  .booking-actions .btn { flex: 1 1 auto; }
}

/* Таймер стола: сколько гости уже сидят */
.table-timer {
  display: inline-flex; align-items: center; gap: 5px; align-self: flex-start;
  padding: 3px 9px; border-radius: 999px; background: var(--blue-soft); color: var(--blue-text);
  font-size: 12.5px; font-weight: 800; font-variant-numeric: tabular-nums;
}
.table-timer .ic { width: 13px; height: 13px; }
/* Засиделись — подсказка хостес, что стол скоро понадобится */
.table-timer.is-long { background: var(--amber-soft); color: var(--amber-text); }
.table-modal__timer { display: flex; align-items: center; gap: 8px; margin: 10px 0 0; font-size: 13.5px; color: var(--muted); }

/* Точка гостя на карте */
.map-me {
  width: 16px; height: 16px; border-radius: 50%; background: var(--blue-hi);
  border: 3px solid #fff; box-shadow: 0 0 0 4px color-mix(in srgb, var(--blue-hi) 25%, transparent);
  transform: translate(-50%, -50%);
}

/* Кнопка «показать, где я» на карте */
.map__locate .ic, .map__locate svg { width: 20px; height: 20px; }
.map__locate.is-busy { opacity: .55; pointer-events: none; }

/* Выбор детских стульев при бронировании */
.chairs-pick {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  margin-top: 16px; padding: 12px 14px; border: 1px solid var(--line); border-radius: 12px;
  background: var(--surface-2);
}
.chairs-pick__label { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 700; }
.chairs-pick__label .ic { width: 18px; height: 18px; color: var(--blue); }
.chairs-pick__ctrl { display: inline-flex; align-items: center; gap: 12px; }
.chairs-pick__ctrl b { min-width: 18px; text-align: center; font-size: 16px; font-weight: 800; }
.chairs-pick__ctrl button {
  width: 34px; height: 34px; border-radius: 9px; border: 1px solid var(--line);
  background: var(--surface); color: var(--ink); font-size: 19px; line-height: 1; cursor: pointer;
}
.chairs-pick__ctrl button:hover:not(:disabled) { border-color: var(--blue); color: var(--blue); }
.chairs-pick__ctrl button:disabled { opacity: .4; cursor: default; }

/* ---------- Нижняя панель разделов (только телефон) ---------- */
.tabbar { display: none; }

@media (max-width: 640px) {
  .tabbar {
    position: fixed; left: 0; right: 0; bottom: 0; z-index: 90;
    display: grid; grid-template-columns: repeat(5, 1fr);
    background: var(--surface); border-top: 1px solid var(--line-soft);
    padding-bottom: env(safe-area-inset-bottom);          /* полоса жестов у iPhone */
    box-shadow: 0 -2px 12px rgba(15, 30, 66, .08);
  }
  .tabbar__item {
    position: relative; display: grid; justify-items: center; gap: 3px;
    padding: 9px 4px 8px; color: var(--muted); font-size: 11px; font-weight: 700;
  }
  .tabbar__item .ic { width: 23px; height: 23px; }
  .tabbar__item.is-active { color: var(--blue); }
  .tabbar__label { line-height: 1.1; }
  .tabbar__badge {
    position: absolute; top: 4px; left: 50%; margin-left: 6px;
    min-width: 17px; height: 17px; padding: 0 5px; border-radius: 999px;
    background: var(--orange); color: #fff; font-size: 10.5px; font-weight: 800;
    display: grid; place-items: center;
  }

  /* Чтобы панель не закрывала последний ресторан и подвал */
  body { padding-bottom: 62px; }
  .footer { padding-bottom: 24px; }

  /* Открытая карта: язычок списка поднимается над панелью */
}

/* ---------- Лента карточек поверх раскрытой карты (телефон) ---------- */
.map-cards { display: none; }

@media (max-width: 640px) {
  .results-layout.is-map .map-cards {
    display: block; position: fixed; left: 0; right: 0; bottom: 62px; z-index: 20;
    padding-bottom: env(safe-area-inset-bottom);
  }
  .map-cards__row {
    display: flex; gap: 10px; overflow-x: auto; scroll-snap-type: x mandatory;
    padding: 0 14px 10px; scrollbar-width: none;
  }
  .map-cards__row::-webkit-scrollbar { display: none; }
  .map-card {
    flex: 0 0 78%; scroll-snap-align: center; display: grid; grid-template-columns: 92px 1fr;
    background: var(--surface); border-radius: 14px; overflow: hidden; box-shadow: var(--shadow);
  }
  .map-card__media { display: block; height: 96px; }
  .map-card__media .photo { width: 100%; height: 100%; object-fit: cover; font-size: 30px; }
  .map-card__body { display: grid; align-content: start; gap: 3px; padding: 10px 12px; min-width: 0; }
  .map-card__top { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
  .map-card__top b { font-size: 14.5px; font-weight: 800; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .map-card__score { flex: none; font-size: 14px; font-weight: 800; color: var(--blue-hi); }
  .map-card__meta { font-size: 12.5px; color: var(--muted); }
  .map-card .pill-offer { font-size: 11px; padding: 3px 7px; justify-self: start; }

  /* Кнопка возврата к списку — по центру над панелью разделов */
  .map-cards__list {
    display: block; margin: 0 auto 10px; padding: 9px 20px; border: 0; border-radius: 999px;
    background: var(--blue); color: #fff; font: inherit; font-size: 13px; font-weight: 800;
    box-shadow: var(--shadow); cursor: pointer;
  }

  /* На раскрытой карте список уходит за нижний край: вместо него лента карточек,
     а вернуть его можно кнопкой «Показать список» */
  .results-layout.is-map .results-sheet {
    transform: translateY(calc(100dvh - 186px));
    border-radius: 20px 20px 0 0;                /* тут скругление уместно — шторка стала карточкой поверх открытой карты */
    padding-top: 0;                               /* здесь сверху уже ручка карты, свой отступ ни к чему */
  }
}

/* ---------- Экран поиска ---------- */
.search-page { padding-top: 18px; max-width: 720px; }
.search-field {
  display: flex; align-items: center; gap: 12px; margin-bottom: 12px;
  padding: 0 16px; height: 52px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface);
}
.search-field:focus-within { border-color: var(--blue); }
.search-field .ic { width: 20px; height: 20px; color: var(--muted); flex: none; }
.search-field input, .search-field select {
  flex: 1; min-width: 0; border: 0; background: none; outline: none;
  font: inherit; font-size: 16px; color: var(--ink);
}

.search-hint { margin: -4px 0 0; font-size: 12.5px; color: var(--muted); }
.search-block { margin-top: 26px; }
.search-block__head { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.search-block h2 { margin: 0 0 6px; font-size: 20px; font-weight: 800; }
.search-block__head button { border: 0; background: none; cursor: pointer; font: inherit; }

.search-row {
  display: flex; align-items: center; gap: 14px; padding: 15px 2px;
  border-bottom: 1px solid var(--line-soft); color: var(--ink);
}
.search-row:last-child { border-bottom: 0; }
.search-row .ic { width: 22px; height: 22px; color: var(--ink); flex: none; }
.search-row .ic--chevron { width: 16px; height: 16px; color: var(--muted); margin-left: auto; }
.search-row__main { flex: 1; min-width: 0; font-size: 15.5px; font-weight: 600; display: grid; gap: 2px; }
.search-row__main small { font-size: 13px; font-weight: 500; color: var(--muted); }
.search-row__x { border: 0; background: none; font-size: 20px; color: var(--muted); cursor: pointer; padding: 0 4px; }
.search-row--all { border-bottom: 1px solid var(--line); }
.search-row:hover .search-row__main { color: var(--blue); }

/* ---------- Плавающая кнопка «Карта» (телефон) ---------- */
.view-map { display: none; }

@media (max-width: 640px) {
  .view-map {
    display: inline-flex; align-items: center; gap: 8px;
    position: fixed; left: 50%; transform: translateX(-50%); bottom: 76px; z-index: 40;
    padding: 11px 20px; border: 0; border-radius: 999px;
    background: var(--blue-deep); color: #fff; font: inherit; font-size: 14px; font-weight: 800;
    box-shadow: var(--shadow); cursor: pointer;
  }
  .view-map[hidden] { display: none; }
  .view-map svg { width: 17px; height: 17px; }
  .search-page { padding-top: 12px; }
  .search-block h2 { font-size: 18px; }
}

/* ---------- Приложение на iPhone ----------
   Когда сайт открыт с экрана «Домой», у него нет полос браузера,
   поэтому содержимое надо отодвинуть от «чёлки» и от полосы жестов. */
@supports (padding: env(safe-area-inset-top)) {
  @media (display-mode: standalone), (display-mode: fullscreen) {
    .topbar__inner { padding-top: env(safe-area-inset-top); }
    .tabbar { padding-bottom: max(env(safe-area-inset-bottom), 6px); }
    body { padding-bottom: calc(62px + env(safe-area-inset-bottom)); }
    .view-map { bottom: calc(76px + env(safe-area-inset-bottom)); }
    .map-cards { bottom: calc(62px + env(safe-area-inset-bottom)); }
  }
}

/* Правовые страницы: удобная ширина строки для чтения */
.legal { max-width: 760px; padding-bottom: 60px; }
.legal h2 { font-size: 20px; font-weight: 800; margin: 30px 0 10px; }
.legal p { margin: 0 0 12px; font-size: 15.5px; line-height: 1.6; color: var(--ink); }
.legal a { color: var(--blue-text); text-decoration: underline; }

/* ---------- Интро при первом запуске ----------
   Полноэкранный слой поверх сайта: в приложении из магазина это первое,
   что видит человек. Кнопка внизу — под большой палец, как в приложениях. */
.intro {
  position: fixed; inset: 0; z-index: 200;
  display: flex; flex-direction: column;
  background: var(--bg);
  padding: calc(14px + env(safe-area-inset-top)) 22px calc(22px + env(safe-area-inset-bottom));
  animation: intro-in .28s ease-out;
}
.intro.is-away { opacity: 0; transform: scale(1.02); transition: opacity .24s ease, transform .24s ease; }
@keyframes intro-in { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

.intro__top { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.intro__logo { display: block; width: 96px; }
.intro__logo svg { width: 100%; height: auto; display: block; }
.intro__skip {
  background: none; border: 0; cursor: pointer;
  font-size: 15px; font-weight: 700; color: var(--muted); padding: 8px 4px;
}

.intro__stage { flex: 1; display: flex; align-items: center; justify-content: center; }
.intro__slide { max-width: 420px; text-align: center; animation: intro-slide .26s ease-out; }
@keyframes intro-slide { from { opacity: 0; transform: translateX(16px); } to { opacity: 1; transform: none; } }
.intro__art { margin: 0 auto 30px; max-width: 300px; }
.intro__art svg { width: 100%; height: auto; display: block; }
.intro__slide h2 { margin: 0 0 12px; font-size: 27px; font-weight: 800; letter-spacing: -.4px; }
.intro__slide p { margin: 0; font-size: 16px; line-height: 1.55; color: var(--muted); }

.intro__foot { display: flex; flex-direction: column; align-items: center; gap: 20px; }
.intro__dots { display: flex; gap: 8px; }
.intro__dot {
  width: 8px; height: 8px; border-radius: 999px; background: var(--line);
  cursor: pointer; transition: width .2s ease, background .2s ease;
}
.intro__dot.is-on { width: 26px; background: var(--blue); }
.intro__foot .btn { max-width: 420px; }

@media (min-width: 641px) {
  .intro { padding: 26px 32px 32px; }
  .intro__slide h2 { font-size: 32px; }
}

/* ---------- «Нужен аккаунт» ----------
   Окно поверх страницы: гость смотрит сайт свободно, а на действии
   (бронь, избранное, отзыв) объясняем, зачем нужен вход. */
/* `.modal__panel` — боковая панель фильтров, а это окно должно стоять по центру */
.auth-ask {
  position: relative; inset: auto; right: auto; top: auto; bottom: auto;
  width: min(440px, calc(100% - 36px)); max-height: 90vh; margin: auto;
  border: 0; border-radius: 18px; box-shadow: var(--shadow);
}
.modal.is-open:has(.auth-ask) { display: flex; align-items: center; justify-content: center; }
.auth-ask .modal__body { padding-top: 4px; }
.auth-ask__text { margin: 0; font-size: 15.5px; line-height: 1.55; color: var(--muted); }
/* «Не сейчас» слева, действия справа — иначе кнопки переносятся на вторую строку */
.auth-ask .modal__foot { flex-wrap: nowrap; justify-content: flex-end; gap: 10px; }
.auth-ask .modal__foot .btn--quiet { margin-right: auto; }
.auth-ask .modal__foot .btn { white-space: nowrap; }

@media (max-width: 640px) {
  /* На телефоне окно прижимаем к низу — так до кнопок дотягивается большой палец */
  .auth-ask { margin: auto 0 0; width: 100%; border-radius: 20px 20px 0 0; }
  .auth-ask .modal__foot { flex-direction: column-reverse; align-items: stretch; }
  .auth-ask .modal__foot .btn { width: 100%; text-align: center; }
}

/* ---------- Счёт стола и переключатель оборота ---------- */
.bill-modal { max-width: 420px; }
.bill-modal input[type="number"] { font-size: 22px; font-weight: 700; text-align: center; }
.bill-sum { color: var(--blue-hi); white-space: nowrap; }

/* Компактный переключатель в шапке отчётов */
.switch-inline { display: inline-flex; align-items: center; gap: 8px; cursor: pointer; font-size: 13px; font-weight: 700; color: var(--muted); }
.switch-inline input { position: absolute; opacity: 0; pointer-events: none; }
.switch-inline i { width: 34px; height: 20px; border-radius: 999px; background: var(--line); position: relative; transition: background .18s ease; }
.switch-inline i::after { content: ''; position: absolute; top: 2px; left: 2px; width: 16px; height: 16px; border-radius: 50%; background: #fff; transition: transform .18s ease; }
.switch-inline input:checked + i { background: var(--blue); }
.switch-inline input:checked + i::after { transform: translateX(14px); }
.switch-inline input:checked ~ span { color: var(--blue-text); }

/* ---------- Заставка приложения ----------
   Видна только в установленном приложении: логотип проявляется, надпись
   подтягивается снизу, три точки показывают, что идёт загрузка. */
.splash {
  position: fixed; inset: 0; z-index: 300;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 14px;
  background: var(--blue);
  animation: splash-in .25s ease-out;
}
.splash.is-away { opacity: 0; transform: scale(1.06); transition: opacity .4s ease, transform .4s ease; }
@keyframes splash-in { from { opacity: 0; } to { opacity: 1; } }

/* Знак: чуть подрастает и мягко встаёт на место */
.splash__mark { width: 190px; animation: splash-mark .8s cubic-bezier(.2, .8, .3, 1) both; }
.splash__mark svg { width: 100%; height: auto; display: block; }
/* Стулья на синем фоне — белые, стол остаётся оранжевым */
.splash__mark svg g[fill="#1b3f7d"] { fill: #fff; }
@keyframes splash-mark {
  from { opacity: 0; transform: scale(.82) translateY(14px); }
  to   { opacity: 1; transform: none; }
}

.splash__name { font-size: 34px; font-weight: 800; color: #fff; letter-spacing: -.5px; animation: splash-up .6s .25s ease-out both; }
.splash__name em { font-style: normal; color: var(--orange); }
.splash__tag { font-size: 15px; color: #ffffffb8; animation: splash-up .6s .4s ease-out both; }
@keyframes splash-up {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: none; }
}

/* Точки-«загрузка»: перебор по очереди */
.splash__dots { display: flex; gap: 7px; margin-top: 10px; animation: splash-up .5s .6s ease-out both; }
.splash__dots i { width: 7px; height: 7px; border-radius: 50%; background: #ffffff6b; animation: splash-dot 1s infinite; }
.splash__dots i:nth-child(2) { animation-delay: .15s; }
.splash__dots i:nth-child(3) { animation-delay: .3s; }
@keyframes splash-dot {
  0%, 100% { opacity: .35; transform: translateY(0); }
  40%      { opacity: 1;   transform: translateY(-4px); background: var(--orange); }
}

/* Кому анимация мешает — показываем статичный экран */
@media (prefers-reduced-motion: reduce) {
  .splash, .splash__mark, .splash__name, .splash__tag, .splash__dots, .splash__dots i { animation: none; }
}
