:root {
  --bg: #0d0d0d;
  --card: #1a1a1a;
  --card-2: #141414;
  --line: rgba(255, 255, 255, 0.08);
  --accent: #ff8a1f;
  --accent-2: #ff9d42;
  --text: #ffffff;
  --muted: #b7b7b7;
  --dim: #8d8d8d;
  --cream: #f6f1e8;
  --ink: #1c140f;
  --danger: #ffb4a2;
  --radius: 20px;
  --shadow: 0 16px 40px rgba(0, 0, 0, 0.35);
  --font: "Manrope", "Segoe UI", sans-serif;
  --hand: "Caveat", cursive;
  --container: 1120px;
}

*,
*::before,
*::after { box-sizing: border-box; }

[hidden] { display: none !important; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.5;
  color-scheme: dark;
}

body.nav-lock { overflow: hidden; }

img { max-width: 100%; display: block; }

a { color: inherit; }

button, input, textarea { font: inherit; color: inherit; }

h1, h2, h3, p { margin: 0; }

h1 {
  font-size: clamp(40px, 6vw, 72px);
  line-height: 0.98;
  letter-spacing: -0.045em;
  font-weight: 800;
}

h2 {
  font-size: clamp(32px, 4vw, 48px);
  line-height: 1.05;
  letter-spacing: -0.04em;
  font-weight: 800;
}

h3 { font-size: 18px; line-height: 1.25; font-weight: 700; }

.accent { color: var(--accent); }

.container {
  width: min(var(--container), calc(100% - 32px));
  margin-inline: auto;
}

.skip-link {
  position: absolute;
  left: 16px;
  top: -40px;
  background: var(--accent);
  color: var(--ink);
  padding: 8px 12px;
  border-radius: 8px;
  z-index: 100;
}

.skip-link:focus { top: 12px; }

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

::selection { background: rgba(255, 138, 31, 0.35); }

.wave {
  display: block;
  width: 78px;
  height: 12px;
  margin: 12px 0 16px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 78 12'%3E%3Cpath d='M1 7c4-5 8-5 12 0s8 5 12 0 8-5 12 0 8 5 12 0 8-5 12 0 8 4 16 0' fill='none' stroke='%23FF8A1F' stroke-width='2.2' stroke-linecap='round'/%3E%3C/svg%3E") left center / contain no-repeat;
}

.lead {
  color: var(--muted);
  font-size: 18px;
  max-width: 38ch;
}

.section { padding: 28px 0 72px; }

.section-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}

/* Кнопки */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 0;
  border-radius: 999px;
  padding: 14px 22px;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn svg { width: 18px; height: 18px; flex: none; }

.btn-accent {
  background: var(--accent);
  color: #1a1008;
}

.btn-accent:hover {
  background: var(--accent-2);
  box-shadow: 0 10px 28px rgba(255, 138, 31, 0.35);
  transform: translateY(-1px);
}

.btn-light {
  background: var(--cream);
  color: var(--ink);
}

.btn-light:hover {
  background: #fff;
  box-shadow: 0 10px 28px rgba(255, 255, 255, 0.12);
  transform: translateY(-1px);
}

.btn-ghost {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--line);
}

.btn-ghost:hover { border-color: rgba(255, 138, 31, 0.7); color: var(--accent); }

.btn-sm { padding: 10px 14px; font-size: 14px; }

.btn-block { width: 100%; }

.btn:disabled { opacity: 0.4; cursor: default; transform: none; box-shadow: none; }

.icon-btn {
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: 50%;
  background: #242424;
  color: white;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.icon-btn svg { width: 18px; height: 18px; }

.icon-btn:hover { background: var(--accent); color: var(--ink); }

/* Шапка */
#site-header {
  position: sticky;
  top: 0;
  z-index: 40;
}

.header-wrap {
  padding: 12px 16px 10px;
  background: linear-gradient(#0d0d0d 62%, rgba(13, 13, 13, 0));
}

.header-bar {
  width: min(var(--container), 100%);
  margin: 0 auto;
  min-height: 72px;
  padding: 10px 12px 10px 18px;
  display: flex;
  align-items: center;
  gap: 18px;
  background: rgba(18, 18, 18, 0.92);
  border: 1px solid var(--line);
  border-radius: 22px;
  backdrop-filter: blur(16px);
  position: relative;
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  font-weight: 800;
  letter-spacing: -0.03em;
  flex: none;
}



.logo-word { font-size: 18px; line-height: 1; text-transform: uppercase; letter-spacing: 0.01em; }

.site-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px 18px;
  flex: 1;
}

.site-nav a {
  text-decoration: none;
  color: #dedede;
  font-size: 15px;
  font-weight: 600;
  padding: 6px 2px;
}

.site-nav a:hover,
.site-nav a[aria-current="page"] { color: var(--accent); }

.nav-toggle {
  display: none;
  width: 44px;
  height: 44px;
  margin-left: auto;
  border: 0;
  background: transparent;
  padding: 10px;
  cursor: pointer;
}

.nav-toggle span {
  display: block;
  height: 2px;
  margin: 5px 0;
  border-radius: 2px;
  background: white;
}

#header-order { flex: none; padding: 12px 18px; }

/* Подвал */
#site-footer {
  padding: 28px 0 96px;
  border-top: 1px solid var(--line);
}

.footer-grid {
  display: grid;
  gap: 28px;
}

.slogan { color: var(--muted); margin-top: 10px; }

.footer-links {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.footer-links a { text-decoration: none; color: #ddd; font-weight: 600; }

.footer-links a:hover { color: var(--accent); }

.copyright {
  width: min(var(--container), calc(100% - 32px));
  margin: 28px auto 0;
  color: var(--dim);
  font-size: 14px;
}

/* Формы */
.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; }

.field label,
.field legend { font-size: 14px; font-weight: 700; }

.field input,
.field textarea {
  width: 100%;
  background: #101010;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 13px 14px;
}

.field textarea { resize: vertical; min-height: 96px; }

.field input:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(255, 138, 31, 0.25);
}

.field input[aria-invalid="true"],
.field textarea[aria-invalid="true"] { border-color: var(--danger); }

.field-error {
  min-height: 1.2em;
  color: var(--danger);
  font-size: 13px;
  margin: 6px 0 0;
}

.choice-row { display: flex; gap: 8px; }

.choice {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 10px 12px;
  cursor: pointer;
  background: #101010;
}

.choice:has(input:checked) {
  border-color: var(--accent);
  background: rgba(255, 138, 31, 0.14);
}

.choice input { accent-color: var(--accent); }

/* Счётчик */
.qty {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: #111;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 3px;
}

.qty button {
  width: 32px;
  height: 32px;
  border: 0;
  border-radius: 50%;
  background: #2a2a2a;
  color: white;
  cursor: pointer;
}

.qty button:hover { background: var(--accent); color: var(--ink); }

.qty span { min-width: 1.4em; text-align: center; font-weight: 700; }

.price { font-weight: 800; }

/* Карточки блюд */
.card-photo {
  border-radius: 16px;
  overflow: hidden;
  background: #111;
  aspect-ratio: 4 / 3;
}

.card-photo img { width: 100%; height: 100%; object-fit: cover; }

.card-body { display: flex; flex-direction: column; gap: 8px; padding-top: 12px; }

.card-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-top: 4px;
}

.menu-card,
.hit-card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 12px;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.menu-card:hover,
.hit-card:hover,
.promo-card:hover,
.info-card:hover {
  transform: translateY(-4px);
  border-color: rgba(255, 138, 31, 0.45);
  box-shadow: 0 16px 40px rgba(255, 138, 31, 0.14);
}

/* Карусель */
.carousel-nav { display: flex; gap: 8px; }

.carousel-nav button {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: #161616;
  color: white;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.carousel-nav button svg { width: 18px; height: 18px; }

.carousel-nav button:hover:not(:disabled) { background: var(--accent); color: var(--ink); border-color: transparent; }

.hits-track {
  display: flex;
  gap: 16px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
  padding: 6px 2px 12px;
}

.hits-track::-webkit-scrollbar { display: none; }

.hit-card {
  flex: 0 0 85%;
  scroll-snap-align: start;
}

/* Табы */
.tabs {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 4px;
  margin: 8px 0 22px;
}

.tabs button {
  flex: none;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: #161616;
  color: white;
  padding: 10px 16px;
  font-weight: 700;
  cursor: pointer;
}

.tabs button[aria-selected="true"] {
  background: var(--accent);
  color: var(--ink);
  border-color: transparent;
}

.menu-grid {
  display: grid;
  gap: 16px;
}

.menu-empty { color: var(--muted); }

/* Плавающая корзина */
.cart-fab {
  position: fixed;
  right: 16px;
  bottom: 16px;
  z-index: 60;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px 10px 12px;
  border-radius: 999px;
  background: var(--accent);
  color: var(--ink);
  text-decoration: none;
  font-weight: 800;
  box-shadow: 0 12px 30px rgba(255, 138, 31, 0.35);
}

.cart-fab svg { width: 22px; height: 22px; }

.cart-fab.is-hidden { display: none; }

.fab-count {
  min-width: 22px;
  height: 22px;
  padding: 0 6px;
  border-radius: 999px;
  background: #1a1008;
  color: white;
  font-size: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* Панель корзины */
.cart-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.62);
  z-index: 70;
}

.cart-drawer {
  position: fixed;
  top: 0;
  right: 0;
  z-index: 80;
  width: min(440px, 100%);
  height: 100%;
  background: #121212;
  border-left: 1px solid var(--line);
  transform: translateX(105%);
  transition: transform 0.28s ease;
  visibility: hidden;
}

.cart-drawer.is-open {
  transform: none;
  visibility: visible;
}

.cart-drawer > * {
  height: 100%;
  display: flex;
  flex-direction: column;
  min-height: 0;
}

.drawer-head,
.checkout-actions,
.cart-summary {
  padding: 16px 18px;
}

.drawer-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid var(--line);
}

.cart-list {
  list-style: none;
  margin: 0;
  padding: 8px 18px;
  overflow: auto;
  flex: 1;
}

.cart-empty {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 16px;
  padding: 24px 20px;
  color: var(--muted);
}

.cart-line {
  display: grid;
  grid-template-columns: 72px 1fr auto;
  grid-template-areas:
    "img info remove"
    "img qty sum";
  gap: 6px 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
}

.cart-line img {
  grid-area: img;
  width: 72px;
  height: 72px;
  object-fit: cover;
  border-radius: 12px;
}

.cart-line-info { grid-area: info; }
.cart-line-info p { color: var(--muted); font-size: 14px; }
.cart-line .qty { grid-area: qty; justify-self: start; }
.cart-line strong { grid-area: sum; justify-self: end; align-self: center; }
.cart-line .icon-btn { grid-area: remove; justify-self: end; width: 34px; height: 34px; }

.cart-summary { border-top: 1px solid var(--line); }

.sum-row {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 6px;
  color: var(--muted);
}

.sum-row.is-discount { color: var(--accent); }

.sum-row.is-total {
  color: white;
  font-size: 18px;
  margin: 8px 0;
}

.sum-note { color: var(--dim); font-size: 13px; min-height: 1em; margin-bottom: 10px; }

.checkout-body { overflow: auto; flex: 1; padding: 16px 18px; }

.checkout-actions {
  display: flex;
  gap: 8px;
  border-top: 1px solid var(--line);
}

.checkout-actions .btn-accent { flex: 1; }

.thanks {
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 12px;
  padding: 32px 24px;
}

.thanks-mark {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: rgba(255, 138, 31, 0.15);
  color: var(--accent);
  display: grid;
  place-items: center;
}

.thanks-mark svg { width: 34px; height: 34px; }

.thanks p { color: var(--muted); max-width: 28ch; }

/* Появление секций */
.js .reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.js .reveal.is-in { opacity: 1; transform: none; }

@media (min-width: 720px) {
  .footer-grid { grid-template-columns: 1fr auto; gap: 48px; align-items: start; }
  .menu-grid { grid-template-columns: 1fr 1fr; }
  .hit-card { flex-basis: calc((100% - 16px) / 2); }
}

@media (min-width: 980px) {
  .menu-grid { grid-template-columns: 1fr 1fr 1fr; }
  .hit-card { flex-basis: calc((100% - 32px) / 3); }
}

@media (max-width: 1000px) {
  .nav-toggle { display: inline-block; }
  .site-nav {
    display: none;
    position: absolute;
    top: calc(100% + 8px);
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    padding: 10px;
    background: #161616;
    border: 1px solid var(--line);
    border-radius: 16px;
    box-shadow: var(--shadow);
  }
  .site-nav.is-open { display: flex; }
  .site-nav a { padding: 12px; border-radius: 10px; }
  .site-nav a:hover { background: rgba(255, 255, 255, 0.04); }
  #header-order { padding: 10px 14px; }
}

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

/* Логотип, описания и размеры в карточках */
.logo .icon-logo { width: 46px; height: 46px; flex: none; border-radius: 11px; display: block; box-shadow: 0 4px 14px rgba(255, 179, 0, 0.25); }
.logo-text { display: flex; flex-direction: column; gap: 3px; }
.logo-sub { font-size: 9px; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; color: var(--dim); line-height: 1; }
.card-photo { position: relative; }
.hit-badge { position: absolute; left: 10px; top: 10px; background: var(--accent); color: #1a1008; font-weight: 800; font-size: 12px; border-radius: 999px; padding: 5px 10px; }
.desc { color: var(--muted); font-size: 14px; line-height: 1.4; }
.variants { display: grid; gap: 10px; margin-top: 4px; }
.variant { display: grid; gap: 6px; padding-top: 10px; border-top: 1px solid var(--line); }
.variant:first-child { border-top: 0; padding-top: 0; }
.variant-info { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.variant-label { color: var(--muted); font-weight: 700; font-size: 14px; }
.promo-price { font-weight: 800; font-size: 20px; color: var(--ink); margin: 6px 0 10px; }

/* Листание фото в карточках */
.card-photo { background: #e8e9eb; }
.gallery { display: flex; width: 100%; height: 100%; overflow-x: auto; overflow-y: hidden; scroll-snap-type: x mandatory; scrollbar-width: none; overscroll-behavior-x: contain; -webkit-overflow-scrolling: touch; touch-action: pan-x pan-y; }
.gallery::-webkit-scrollbar { display: none; }
.gallery img { flex: 0 0 100%; width: 100%; height: 100%; object-fit: cover; scroll-snap-align: center; scroll-snap-stop: always; }
.gallery:focus-visible { outline: 3px solid var(--accent); outline-offset: -3px; }
.gal-btn { position: absolute; top: 50%; transform: translateY(-50%); width: 34px; height: 34px; border: 0; border-radius: 50%; display: grid; place-items: center; background: rgba(13, 13, 13, 0.62); color: #fff; cursor: pointer; opacity: 0; transition: opacity 0.2s ease, background 0.2s ease; }
.gal-btn svg { width: 18px; height: 18px; }
.gal-prev { left: 8px; } .gal-next { right: 8px; }
.card-photo:hover .gal-btn, .gal-btn:focus-visible { opacity: 1; }
.gal-btn:hover { background: var(--accent); color: #1a1008; }
.gal-dots { position: absolute; left: 0; right: 0; bottom: 8px; display: flex; justify-content: center; gap: 5px; pointer-events: none; }
.gal-dot { width: 6px; height: 6px; border-radius: 50%; background: rgba(13, 13, 13, 0.35); box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.55); transition: width 0.2s ease, background 0.2s ease; }
.gal-dot.is-on { width: 16px; border-radius: 3px; background: var(--accent); }
@media (hover: none) { .gal-btn { display: none; } }

/* Мобильная версия */
@media (max-width: 719px) {
  .menu-grid { grid-template-columns: 1fr; gap: 14px; }
  .menu-card { display: grid; grid-template-columns: 42% 1fr; gap: 12px; align-items: start; padding: 10px; }
  .menu-card .card-photo { border-radius: 12px; }
  .menu-card .card-body { padding-top: 0; gap: 6px; }
  .menu-card h3 { font-size: 16px; line-height: 1.2; }
  .menu-card .desc { font-size: 12.5px; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
  .menu-card .price { font-size: 17px; }
  .menu-card .card-actions { gap: 6px; }
  .menu-card .btn-sm { padding: 8px 12px; font-size: 13px; }
  .tabs { margin-left: -16px; margin-right: -16px; padding-left: 16px; padding-right: 16px; scrollbar-width: none; scroll-snap-type: x proximity; }
  .tabs::-webkit-scrollbar { display: none; }
  .tabs button { flex: none; white-space: nowrap; }
  .hit-card { flex-basis: 78%; }
  .logo-sub { display: none; }
  .promo-card { padding: 16px; }
}
@media (max-width: 420px) {
  .menu-card { grid-template-columns: 1fr; }
  .menu-card .desc { -webkit-line-clamp: 4; }
}

/* Шапка и герой на телефоне */
.nav-toggle { flex: none; }
@media (max-width: 520px) {
  .header-bar { gap: 6px; padding: 8px 8px 8px 12px; min-height: 64px; }
  .logo-word { font-size: 15px; }
  .logo .icon-logo { width: 40px; height: 40px; border-radius: 10px; }
  #header-order { padding: 9px 13px; font-size: 14px; }
}

/* Переключатель языка RU / KZ */
.lang-switch {
  display: inline-flex;
  flex: none;
  gap: 2px;
  padding: 3px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--line);
  border-radius: 999px;
}

.lang-switch button {
  min-width: 38px;
  height: 32px;
  padding: 0 10px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: #dedede;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.04em;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease;
}

.lang-switch button:hover { color: var(--accent); }

.lang-switch button.is-on {
  background: var(--accent);
  color: #1a1008;
  cursor: default;
}

.lang-nav { display: none; }

@media (max-width: 1000px) {
  .logo { order: 0; }
  .lang-bar { order: 1; margin-left: auto; }
  .nav-toggle { order: 2; margin-left: 0; }
  #header-order { order: 3; }
}

@media (max-width: 520px) {
  .lang-bar { display: none; }
  .nav-toggle { margin-left: auto; }
  .lang-nav { display: inline-flex; align-self: flex-start; margin: 6px 12px 4px; }
}

/* Широкий логотип в шапке */
.logo-wide-img { height: 48px; width: auto; display: block; border-radius: 9px; box-shadow: 0 4px 14px rgba(255, 179, 0, 0.25); }
@media (max-width: 520px) {
  .logo-wide-img { height: 40px; }
}
