/* ==========================================================================
   Трактиръ Ямской — общий стиль
   Рустикальный тёмный трактир: дерево и золото
   ========================================================================== */

:root {
  --bg: #160f0b;
  --surface: #211711;
  --ink: #f3e6d2;
  --muted: #b39b80;
  --accent: #c9a24b;
  --accent2: #7a2e22;

  --surface-2: #2b1f16;
  --line: rgba(201, 162, 75, 0.22);
  --shadow: 0 18px 40px rgba(0, 0, 0, 0.55);

  --font-head: "Playfair Display", Georgia, "Times New Roman", serif;
  --font-body: "PT Serif", Georgia, "Times New Roman", serif;

  --maxw: 1160px;
  --radius: 6px;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background-color: var(--bg);
  background-image:
    radial-gradient(1200px 500px at 50% -120px, rgba(201, 162, 75, 0.10), transparent 70%),
    repeating-linear-gradient(90deg, rgba(0, 0, 0, 0.22) 0 2px, transparent 2px 7px),
    linear-gradient(180deg, #1b130d, #160f0b 40%, #130c08);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 18px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}

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

a {
  color: var(--accent);
  text-decoration: none;
  transition: color 0.2s ease;
}

a:hover {
  color: #e4c477;
}

h1,
h2,
h3,
h4 {
  font-family: var(--font-head);
  font-weight: 700;
  line-height: 1.15;
  color: var(--ink);
  margin: 0 0 0.5em;
  letter-spacing: 0.01em;
}

h1 {
  font-size: clamp(2.1rem, 5.5vw, 3.6rem);
}

h2 {
  font-size: clamp(1.6rem, 3.6vw, 2.5rem);
}

h3 {
  font-size: clamp(1.2rem, 2.4vw, 1.5rem);
}

p {
  margin: 0 0 1.1em;
}

/* Accessibility --------------------------------------------------------- */

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

.skip-link {
  position: absolute;
  left: 16px;
  top: -60px;
  background: var(--accent);
  color: #160f0b;
  padding: 10px 18px;
  border-radius: var(--radius);
  font-family: var(--font-head);
  font-weight: 700;
  z-index: 200;
  transition: top 0.2s ease;
}

.skip-link:focus {
  top: 16px;
  color: #160f0b;
}

.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;
}

/* Layout ---------------------------------------------------------------- */

.container {
  width: 100%;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 16px;
}

.section {
  padding: clamp(48px, 7vw, 92px) 0;
}

.section--tight {
  padding: clamp(36px, 5vw, 64px) 0;
}

.eyebrow {
  font-family: var(--font-body);
  text-transform: uppercase;
  letter-spacing: 0.32em;
  font-size: 0.78rem;
  color: var(--accent);
  margin: 0 0 0.8em;
}

.lead {
  font-size: clamp(1.05rem, 2vw, 1.25rem);
  color: var(--muted);
  max-width: 62ch;
}

/* Header & navigation --------------------------------------------------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(19, 12, 8, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 72px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--ink);
  font-family: var(--font-head);
}

.brand:hover {
  color: var(--ink);
}

.brand__mark {
  width: 42px;
  height: 42px;
  flex: 0 0 auto;
}

.brand__name {
  font-size: 1.28rem;
  font-weight: 700;
  line-height: 1.05;
}

.brand__name span {
  display: block;
  font-family: var(--font-body);
  font-size: 0.62rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--accent);
}

.nav__links {
  display: flex;
  align-items: center;
  gap: 4px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav__links a {
  display: inline-block;
  padding: 8px 14px;
  color: var(--ink);
  font-size: 0.98rem;
  border-radius: var(--radius);
  position: relative;
}

.nav__links a::after {
  content: "";
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 2px;
  height: 2px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.22s ease;
}

.nav__links a:hover::after {
  transform: scaleX(1);
}

.nav__links a[aria-current="page"] {
  color: var(--accent);
}

.nav__links a[aria-current="page"]::after {
  transform: scaleX(1);
}

.nav__toggle {
  display: none;
  flex: 0 0 auto;
  width: 46px;
  height: 46px;
  background: transparent;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--ink);
  cursor: pointer;
  align-items: center;
  justify-content: center;
}

.nav__toggle span,
.nav__toggle span::before,
.nav__toggle span::after {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--ink);
  position: relative;
  transition: transform 0.25s ease, opacity 0.25s ease;
}

.nav__toggle span::before,
.nav__toggle span::after {
  content: "";
  position: absolute;
  left: 0;
}

.nav__toggle span::before { top: -7px; }
.nav__toggle span::after { top: 7px; }

.nav__toggle[aria-expanded="true"] span { background: transparent; }
.nav__toggle[aria-expanded="true"] span::before { transform: translateY(7px) rotate(45deg); }
.nav__toggle[aria-expanded="true"] span::after { transform: translateY(-7px) rotate(-45deg); }

/* Buttons --------------------------------------------------------------- */

.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1rem;
  padding: 13px 26px;
  border-radius: var(--radius);
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.15s ease, background 0.2s ease, color 0.2s ease;
}

.btn:active { transform: translateY(1px); }

.btn--primary {
  background: linear-gradient(180deg, #d8b45c, #b88a2f);
  color: #160f0b;
  box-shadow: 0 10px 24px rgba(201, 162, 75, 0.25);
}

.btn--primary:hover { color: #160f0b; background: linear-gradient(180deg, #e4c477, #c9a24b); }

.btn--ghost {
  background: transparent;
  border-color: var(--accent);
  color: var(--accent);
}

.btn--ghost:hover { background: rgba(201, 162, 75, 0.12); color: #e4c477; }

/* Ornamental divider ---------------------------------------------------- */

.divider {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  margin: 8px auto 0;
  max-width: 420px;
  color: var(--accent);
}

.divider::before,
.divider::after {
  content: "";
  height: 1px;
  flex: 1;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
}

.divider svg {
  width: 46px;
  height: 22px;
  flex: 0 0 auto;
}

/* Hero ------------------------------------------------------------------ */

.hero {
  position: relative;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
}

.hero__inner {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 48px;
  align-items: center;
  padding: clamp(56px, 9vw, 120px) 0;
}

.hero__title {
  margin-bottom: 0.3em;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 28px;
}

.hero__art {
  position: relative;
  aspect-ratio: 4 / 5;
  border-radius: 10px;
  border: 1px solid var(--line);
  background:
    radial-gradient(120% 80% at 70% 15%, rgba(201, 162, 75, 0.28), transparent 55%),
    repeating-linear-gradient(118deg, rgba(0, 0, 0, 0.25) 0 6px, transparent 6px 16px),
    linear-gradient(160deg, #3a281a, #241811 60%, #1a110b);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.hero__art::after {
  content: "";
  position: absolute;
  inset: 14px;
  border: 1px solid rgba(201, 162, 75, 0.35);
  border-radius: 6px;
  pointer-events: none;
}

.hero__crest {
  position: absolute;
  inset: 0;
  margin: auto;
  width: 58%;
  height: auto;
}

/* Generic image placeholders (CSS only) --------------------------------- */

.ph {
  position: relative;
  border-radius: 8px;
  border: 1px solid var(--line);
  overflow: hidden;
  background:
    radial-gradient(100% 120% at 20% 0%, rgba(201, 162, 75, 0.18), transparent 60%),
    repeating-linear-gradient(125deg, rgba(0, 0, 0, 0.22) 0 7px, transparent 7px 18px),
    linear-gradient(150deg, #34241700, #241811);
  background-color: #2a1d13;
}

.ph::after {
  content: "";
  position: absolute;
  inset: 10px;
  border: 1px solid rgba(201, 162, 75, 0.22);
  border-radius: 5px;
}

/* Cards ----------------------------------------------------------------- */

.grid {
  display: grid;
  gap: 24px;
}

.grid--3 { grid-template-columns: repeat(3, 1fr); }
.grid--2 { grid-template-columns: repeat(2, 1fr); }

.card {
  background: linear-gradient(180deg, var(--surface-2), var(--surface));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px;
  box-shadow: var(--shadow);
}

.card__icon {
  width: 52px;
  height: 52px;
  color: var(--accent);
  margin-bottom: 14px;
}

.card h3 { margin-bottom: 0.4em; }

.card p { color: var(--muted); margin-bottom: 0; }

/* Section headings ------------------------------------------------------ */

.section-head {
  text-align: center;
  max-width: 64ch;
  margin: 0 auto 44px;
}

.section-head .lead { margin: 0 auto; }

/* Menu tabs (feature) --------------------------------------------------- */

.menu-tabs {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
  margin-bottom: 36px;
}

.menu-tabs__btn {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.02rem;
  background: var(--surface);
  color: var(--ink);
  border: 1px solid var(--line);
  padding: 11px 24px;
  border-radius: 999px;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.menu-tabs__btn:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.menu-tabs__btn[aria-selected="true"] {
  background: linear-gradient(180deg, #d8b45c, #b88a2f);
  color: #160f0b;
  border-color: transparent;
}

.menu-panel { display: none; }
.menu-panel.is-active { display: block; }

.menu-list {
  display: grid;
  gap: 18px;
  grid-template-columns: repeat(2, 1fr);
  list-style: none;
  margin: 0;
  padding: 0;
}

.dish {
  display: flex;
  gap: 16px;
  align-items: baseline;
  background: linear-gradient(180deg, var(--surface-2), var(--surface));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px 22px;
}

.dish__body { flex: 1; }

.dish__name {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.18rem;
  margin: 0 0 4px;
  display: flex;
  align-items: baseline;
  gap: 10px;
}

.dish__dots {
  flex: 1;
  border-bottom: 1px dotted rgba(201, 162, 75, 0.5);
  transform: translateY(-4px);
}

.dish__price {
  font-family: var(--font-head);
  font-weight: 700;
  color: var(--accent);
  white-space: nowrap;
}

.dish__desc {
  margin: 0;
  color: var(--muted);
  font-size: 0.96rem;
  line-height: 1.5;
}

.dish__tag {
  display: inline-block;
  margin-top: 8px;
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--accent2);
  background: rgba(122, 46, 34, 0.18);
  border: 1px solid rgba(122, 46, 34, 0.5);
  padding: 2px 10px;
  border-radius: 999px;
}

/* Gallery --------------------------------------------------------------- */

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.gallery-grid figure { margin: 0; }

.gallery-grid .ph {
  aspect-ratio: 4 / 3;
}

.gallery-grid .ph--tall { aspect-ratio: 3 / 4; }
.gallery-grid .ph--wide { grid-column: span 2; aspect-ratio: 16 / 9; }

.gallery-grid figcaption {
  margin-top: 8px;
  color: var(--muted);
  font-size: 0.9rem;
}

/* Feature / split rows -------------------------------------------------- */

.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
}

.split .ph { aspect-ratio: 5 / 4; }

/* Stats ----------------------------------------------------------------- */

.stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  text-align: center;
}

.stat__num {
  font-family: var(--font-head);
  font-size: clamp(2rem, 5vw, 3rem);
  color: var(--accent);
  line-height: 1;
}

.stat__label {
  color: var(--muted);
  font-size: 0.92rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

/* Banquet packages ------------------------------------------------------ */

.price-card {
  background: linear-gradient(180deg, var(--surface-2), var(--surface));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 32px 28px;
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
}

.price-card--featured {
  border-color: var(--accent);
  box-shadow: 0 18px 50px rgba(201, 162, 75, 0.2);
}

.price-card__tag {
  align-self: flex-start;
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #160f0b;
  background: var(--accent);
  padding: 3px 12px;
  border-radius: 999px;
  margin-bottom: 14px;
}

.price-card__price {
  font-family: var(--font-head);
  font-size: 2.2rem;
  color: var(--accent);
  margin: 6px 0 2px;
}

.price-card__price small {
  font-size: 0.95rem;
  color: var(--muted);
}

.price-card ul {
  list-style: none;
  margin: 18px 0 24px;
  padding: 0;
}

.price-card li {
  padding: 8px 0 8px 28px;
  position: relative;
  color: var(--muted);
  border-bottom: 1px solid rgba(201, 162, 75, 0.1);
}

.price-card li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 15px;
  width: 14px;
  height: 14px;
  background: var(--accent);
  clip-path: polygon(50% 0, 61% 35%, 98% 35%, 68% 57%, 79% 91%, 50% 70%, 21% 91%, 32% 57%, 2% 35%, 39% 35%);
}

.price-card .btn { margin-top: auto; }

/* Form ------------------------------------------------------------------ */

.form {
  background: linear-gradient(180deg, var(--surface-2), var(--surface));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(24px, 4vw, 40px);
  box-shadow: var(--shadow);
}

.field { margin-bottom: 20px; }

.field label {
  display: block;
  font-family: var(--font-head);
  font-size: 0.98rem;
  margin-bottom: 8px;
  color: var(--ink);
}

.field input,
.field textarea,
.field select {
  width: 100%;
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 1rem;
  padding: 12px 14px;
}

.field input::placeholder,
.field textarea::placeholder { color: #6f5d49; }

.field input:focus,
.field textarea:focus,
.field select:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(201, 162, 75, 0.2);
}

.field-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.form__note {
  font-size: 0.85rem;
  color: var(--muted);
  margin-top: 4px;
}

.form__status {
  margin-top: 16px;
  padding: 14px 16px;
  border-radius: var(--radius);
  background: rgba(201, 162, 75, 0.14);
  border: 1px solid var(--accent);
  color: var(--ink);
  display: none;
}

.form__status.is-visible { display: block; }

/* Contact info ---------------------------------------------------------- */

.info-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 22px;
}

.info-list li {
  display: flex;
  gap: 16px;
  align-items: flex-start;
}

.info-list svg {
  width: 30px;
  height: 30px;
  color: var(--accent);
  flex: 0 0 auto;
  margin-top: 2px;
}

.info-list strong {
  display: block;
  font-family: var(--font-head);
  margin-bottom: 2px;
}

.info-list span { color: var(--muted); }

/* Map placeholder ------------------------------------------------------- */

.map-ph {
  aspect-ratio: 16 / 7;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background:
    radial-gradient(60% 80% at 40% 30%, rgba(201, 162, 75, 0.14), transparent),
    repeating-linear-gradient(0deg, rgba(201, 162, 75, 0.06) 0 1px, transparent 1px 42px),
    repeating-linear-gradient(90deg, rgba(201, 162, 75, 0.06) 0 1px, transparent 1px 42px),
    linear-gradient(160deg, #241811, #1a110b);
  position: relative;
  display: grid;
  place-items: center;
  color: var(--muted);
  overflow: hidden;
}

.map-ph svg { width: 44px; height: 44px; color: var(--accent); }

/* CTA band -------------------------------------------------------------- */

.cta {
  text-align: center;
  background:
    radial-gradient(80% 140% at 50% 0%, rgba(201, 162, 75, 0.16), transparent 60%),
    linear-gradient(180deg, var(--surface-2), var(--surface));
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: clamp(40px, 6vw, 72px) 24px;
  box-shadow: var(--shadow);
}

.cta .btn { margin-top: 24px; }

/* Hours table ----------------------------------------------------------- */

.hours {
  width: 100%;
  border-collapse: collapse;
}

.hours td {
  padding: 12px 4px;
  border-bottom: 1px solid rgba(201, 162, 75, 0.14);
  color: var(--muted);
}

.hours td:last-child {
  text-align: right;
  color: var(--ink);
  font-family: var(--font-head);
}

/* Timeline (about) ------------------------------------------------------ */

.timeline {
  list-style: none;
  margin: 0;
  padding: 0;
  border-left: 2px solid var(--line);
}

.timeline li {
  position: relative;
  padding: 0 0 32px 32px;
}

.timeline li::before {
  content: "";
  position: absolute;
  left: -9px;
  top: 4px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 4px var(--bg);
}

.timeline .year {
  font-family: var(--font-head);
  color: var(--accent);
  font-size: 1.3rem;
}

/* Page header ----------------------------------------------------------- */

.page-head {
  text-align: center;
  padding: clamp(48px, 7vw, 86px) 0 clamp(28px, 4vw, 44px);
  border-bottom: 1px solid var(--line);
  background: radial-gradient(90% 140% at 50% -40%, rgba(201, 162, 75, 0.12), transparent 60%);
}

/* Footer ---------------------------------------------------------------- */

.site-footer {
  border-top: 1px solid var(--line);
  background: linear-gradient(180deg, #130c08, #0f0906);
  padding: 56px 0 28px;
  margin-top: 20px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 40px;
}

.footer-grid h4 {
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--accent);
  margin-bottom: 16px;
}

.footer-grid ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
}

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

.footer-grid p { color: var(--muted); }

.footer-bottom {
  margin-top: 44px;
  padding-top: 22px;
  border-top: 1px solid rgba(201, 162, 75, 0.12);
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  justify-content: space-between;
  align-items: center;
  color: var(--muted);
  font-size: 0.9rem;
}

.footer-bottom .brand__name { font-size: 1rem; }

/* Reveal animation ------------------------------------------------------ */

.reveal {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

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

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

/* Responsive ------------------------------------------------------------ */

@media (max-width: 920px) {
  .hero__inner { grid-template-columns: 1fr; gap: 36px; }
  .hero__art { max-width: 420px; margin: 0 auto; width: 100%; }
  .split { grid-template-columns: 1fr; gap: 28px; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .stats { grid-template-columns: repeat(2, 1fr); gap: 30px; }
}

@media (max-width: 760px) {
  body { font-size: 17px; }

  .nav__toggle { display: inline-flex; }

  .nav__links {
    position: absolute;
    top: 72px;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
    background: rgba(15, 9, 6, 0.98);
    border-bottom: 1px solid var(--line);
    padding: 12px 16px 20px;
    transform: translateY(-12px);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease, transform 0.2s ease;
  }

  .nav__links.is-open {
    opacity: 1;
    transform: none;
    pointer-events: auto;
  }

  .nav__links a { padding: 13px 10px; font-size: 1.05rem; }
  .nav__links a::after { display: none; }
  .nav__links a[aria-current="page"] {
    background: rgba(201, 162, 75, 0.12);
  }

  .grid--3,
  .grid--2 { grid-template-columns: 1fr; }
  .menu-list { grid-template-columns: 1fr; }
  .gallery-grid { grid-template-columns: repeat(2, 1fr); }
  .gallery-grid .ph--wide { grid-column: span 2; }
  .field-row { grid-template-columns: 1fr; }
}

@media (max-width: 440px) {
  .footer-grid { grid-template-columns: 1fr; }
  .stats { grid-template-columns: 1fr 1fr; }
  .gallery-grid { grid-template-columns: 1fr; }
  .gallery-grid .ph--wide { grid-column: span 1; }
  .hero__actions .btn { width: 100%; justify-content: center; }
}
