/* AST Group — мебель на заказ, Астана */

:root {
  /* нейтральная шкала: тёплый крем мебельного шоурума */
  --bg: #F2EEE4;
  --surface: #F8F5EE;
  --raised: #EDE4D3;
  --line: rgba(30, 28, 25, 0.1);
  --line-strong: rgba(30, 28, 25, 0.24);

  /* текст */
  --text: #1E1C19;
  --text-2: #514742;
  --text-3: #6E655D;

  /* акцент — фирменный тёмный */
  --accent: #1E1C19;
  --accent-hover: #36312B;
  --on-accent: #F8F5EE;

  /* тёмная секция */
  --dark: #24201B;
  --on-dark: #F2EEE4;
  --on-dark-2: #C2B8A9;
  --on-dark-line: rgba(242, 238, 228, 0.14);

  /* фирменное золото: только логотип и звезда рейтинга */
  --gold: #C9A227;
  --open: #3E7A4C;

  --serif: "EB Garamond", "PT Serif", Georgia, serif;
  --sans: "Commissioner", "Golos Text", system-ui, -apple-system, "Segoe UI", sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;

  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --pad: 20px;
  --header-h: 64px;
  --bar-h: 72px;
  --section: 64px;
}

@media (min-width: 720px) {
  :root { --pad: 32px; }
}

@media (min-width: 960px) {
  :root { --pad: 40px; --header-h: 72px; --section: 112px; }
}

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 16px);
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 400 16px/1.6 var(--sans);
  -webkit-font-smoothing: antialiased;
  padding-bottom: var(--bar-h);
}

@media (min-width: 960px) {
  body { font-size: 17px; padding-bottom: 0; }
}

img, video { display: block; max-width: 100%; height: auto; }

a { color: inherit; }

h1, h2, h3 { margin: 0; font-weight: 500; }

p { margin: 0; }

.icon { display: block; flex-shrink: 0; }

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

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

.skip {
  position: absolute;
  left: 16px; top: -64px;
  z-index: 100;
  background: var(--accent);
  color: var(--on-accent);
  padding: 12px 16px;
  border-radius: 8px;
  text-decoration: none;
}
.skip:focus { top: 12px; }

.container {
  width: 100%;
  max-width: 1280px;
  margin-inline: auto;
  padding-inline: var(--pad);
}

/* ---------- кнопки ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 48px;
  padding: 0 20px;
  white-space: nowrap;
  border: 1px solid transparent;
  border-radius: 8px;
  font: 500 16px/1.2 var(--sans);
  text-decoration: none;
  text-align: center;
  cursor: pointer;
  transition: background-color .15s var(--ease), color .15s var(--ease), border-color .15s var(--ease), transform .15s var(--ease);
}
.btn:active { transform: scale(0.98); }

.btn-primary { background: var(--accent); color: var(--on-accent); }
.btn-primary:hover { background: var(--accent-hover); }

.btn-secondary {
  background: transparent;
  color: var(--text);
  border-color: var(--line-strong);
}
.btn-secondary:hover { background: var(--raised); }

.btn-sm { min-height: 44px; padding: 0 16px; font-size: 15px; }

.btn-icon {
  width: 48px;
  min-height: 48px;
  padding: 0;
  flex-shrink: 0;
}

/* ---------- шапка ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--bg);
  border-bottom: 1px solid transparent;
  transition: background-color .18s var(--ease), border-color .18s var(--ease);
}
.site-header.is-scrolled {
  background: var(--surface);
  border-bottom-color: var(--line);
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 24px;
  height: var(--header-h);
  max-width: 1280px;
  margin-inline: auto;
  padding-inline: var(--pad);
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  margin-right: auto;
  min-height: 44px;
}
.brand img { width: 40px; height: 40px; border-radius: 50%; }
.brand-text { display: flex; flex-direction: column; line-height: 1.1; }
.brand-name { font: 500 21px/1.1 var(--serif); }
.brand-sub { font-size: 13px; line-height: 1.25; color: var(--text-3); margin-top: 2px; }

.nav { display: none; gap: 4px; }
.nav a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 8px;
  border-radius: 8px;
  font-size: 15px;
  white-space: nowrap;
  color: var(--text-2);
  text-decoration: none;
  transition: color .15s var(--ease), background-color .15s var(--ease);
}
.nav a:hover { color: var(--text); background: var(--raised); }

.header-actions { display: flex; align-items: center; gap: 12px; }
.header-cta { display: none; }

.lang { display: flex; gap: 2px; }
.lang button {
  min-width: 44px;
  min-height: 44px;
  padding: 0 8px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--text-3);
  font: 500 14px/1 var(--sans);
  cursor: pointer;
  transition: color .15s var(--ease), background-color .15s var(--ease);
}
.lang button:hover { color: var(--text); }
.lang button[aria-pressed="true"] { color: var(--text); background: var(--raised); }
.header-actions .lang { display: none; }

.menu-btn {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  background: transparent;
  color: var(--text);
  cursor: pointer;
}
.no-js .menu-btn { display: none; }
.menu-btn .icon-close { display: none; }
.menu-btn[aria-expanded="true"] .icon-open { display: none; }
.menu-btn[aria-expanded="true"] .icon-close { display: block; }

.mobile-menu {
  border-top: 1px solid var(--line);
  background: var(--surface);
  padding: 8px var(--pad) 24px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.06);
}
.mobile-menu nav { display: grid; }
.mobile-menu nav a {
  display: flex;
  align-items: center;
  min-height: 52px;
  border-bottom: 1px solid var(--line);
  font-size: 18px;
  text-decoration: none;
}
.mobile-menu-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 16px;
}
.mobile-menu-foot a { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; text-decoration: none; font-weight: 500; }

@media (min-width: 720px) {
  .header-actions .lang { display: flex; }
}

@media (min-width: 1200px) {
  .nav { display: flex; }
  .header-inner { gap: 20px; }
  .header-inner .brand-sub { display: none; }
  .header-cta { display: inline-flex; }
  .menu-btn { display: none; }
  .mobile-menu { display: none !important; }
}

/* ---------- первый экран ---------- */

.hero {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-height: calc(100svh - var(--header-h) - var(--bar-h));
  overflow: hidden;
  background: #2B2620;
  color: #F8F5EE;
}

.hero-text {
  position: relative;
  z-index: 1;
  padding: 40px var(--pad) 32px;
}

.hero h1 {
  font: 500 clamp(38px, 3.4vw + 18px, 64px)/1.04 var(--serif);
  letter-spacing: -0.015em;
  text-wrap: balance;
}

.hero-lead {
  margin-top: 16px;
  max-width: 34rem;
  font-size: 17px;
  line-height: 1.55;
  color: rgba(248, 245, 238, 0.88);
}

.hero-actions { display: none; }

.hero-trust {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 24px;
  list-style: none;
  margin: 24px 0 0;
  padding: 0;
  font-size: 15px;
}
.hero-trust a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  text-decoration: none;
  color: rgba(248, 245, 238, 0.9);
  transition: color .15s var(--ease);
}
.hero-trust a:hover { color: #FFFFFF; }
.hero-trust b { font-weight: 500; color: #FFFFFF; }
.hero-trust .star { color: var(--gold); }

.hero-media {
  position: absolute;
  inset: 0;
}
.hero-media > * {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 62% 18%;
}
.hero-media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(16, 14, 11, 0.88) 0%, rgba(16, 14, 11, 0.76) 40%, rgba(16, 14, 11, 0.4) 64%, rgba(16, 14, 11, 0) 86%);
}

@media (min-width: 960px) {
  .hero {
    display: grid;
    grid-template-columns: 1.05fr .95fr;
    align-items: center;
    gap: 64px;
    max-width: 1280px;
    margin-inline: auto;
    min-height: 0;
    padding: 40px var(--pad) 72px;
    overflow: visible;
    background: none;
    color: var(--text);
  }
  .hero-text { padding: 0; }
  .hero-lead { color: var(--text-2); font-size: 19px; margin-top: 24px; }
  .hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 40px;
  }
  .hero-trust { margin-top: 32px; }
  .hero-trust a { color: var(--text-2); }
  .hero-trust a:hover { color: var(--text); }
  .hero-trust b { color: var(--text); }
  .hero-trust .star { color: var(--gold); }
  .hero-media {
    position: relative;
    inset: auto;
    width: 100%;
    aspect-ratio: 4 / 5;
    max-height: max(520px, calc(100vh - var(--header-h) - 112px));
  }
  .hero-media > * { object-position: 50% 50%; }
  .hero-media::after { display: none; }
}

@media (prefers-reduced-motion: no-preference) {
  .hero-text, .hero-media { animation: rise .6s var(--ease) both; }
  .hero-media { animation-delay: .08s; }
}
@keyframes rise {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: none; }
}

/* ---------- строка фактов ---------- */

.facts { border-block: 1px solid var(--line); background: var(--surface); }
.facts-list {
  display: grid;
  list-style: none;
  margin: 0 auto;
  padding-block: 8px;
}
.facts-list li {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  padding: 16px 0;
}
.facts-list li + li { border-top: 1px solid var(--line); }
.facts-list b { display: block; font-weight: 500; line-height: 1.4; }
.facts-list span:not(.ico) { display: block; font-size: 15px; color: var(--text-2); line-height: 1.45; }

.ico {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  flex-shrink: 0;
  border-radius: 10px;
  background: var(--raised);
  color: var(--text-2);
}

@media (min-width: 720px) {
  .facts-list { grid-template-columns: 1fr 1fr; column-gap: 32px; }
  .facts-list li + li { border-top: 0; }
  .facts-list li:nth-child(n+3) { border-top: 1px solid var(--line); }
}
@media (min-width: 1100px) {
  .facts-list { grid-template-columns: repeat(4, 1fr); column-gap: 0; padding-block: 0; }
  .facts-list li { padding: 28px 24px; }
  .facts-list li:first-child { padding-left: 0; }
  .facts-list li:nth-child(n+3) { border-top: 0; }
  .facts-list li + li { border-left: 1px solid var(--line); }
}

/* ---------- секции ---------- */

.section { padding-block: var(--section); }

.section-head { margin-bottom: 40px; max-width: 46rem; }
.section-head--row {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px 40px;
  max-width: none;
}

h2 {
  font: 500 clamp(34px, 1.6vw + 24px, 46px)/1.08 var(--serif);
  letter-spacing: -0.01em;
  text-wrap: balance;
}

.lead {
  margin-top: 16px;
  max-width: 36rem;
  color: var(--text-2);
  font-size: 17px;
}
@media (min-width: 960px) {
  .section-head { margin-bottom: 56px; }
  .lead { font-size: 18px; }
}

.tag {
  font: 400 14px/1.55 var(--mono);
  color: var(--text-3);
  transition: color .15s var(--ease);
}

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  font-weight: 500;
  text-decoration: none;
  border-bottom: 1px solid var(--line-strong);
  transition: border-color .15s var(--ease);
}
.link-arrow:hover { border-bottom-color: var(--text); }

/* ---------- работы ---------- */

.works-grid {
  display: flex;
  gap: 16px;
  list-style: none;
  margin: 0 calc(-1 * var(--pad));
  padding: 0 var(--pad) 8px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-padding-inline: var(--pad);
  scrollbar-width: none;
}
.works-grid::-webkit-scrollbar { display: none; }

.work { flex: 0 0 78%; scroll-snap-align: start; }
.work-open {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 5;
  padding: 0;
  border: 0;
  background: var(--raised);
  overflow: hidden;
  cursor: zoom-in;
}
.work-open img { width: 100%; height: 100%; object-fit: cover; }
.work .tag { margin-top: 12px; }
.work:hover .tag { color: var(--text); }

@media (min-width: 720px) {
  .works-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 40px 24px;
    margin: 0;
    padding: 0;
    overflow: visible;
  }
}
@media (min-width: 1100px) {
  .works-grid { gap: 48px 32px; }
}

/* ---------- что делаем ---------- */

.services { background: var(--surface); border-block: 1px solid var(--line); }
.services-grid { display: grid; gap: 40px; }
.services-photo { margin: 32px 0 0; }
.services-photo img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; }
.services-photo figcaption { margin-top: 12px; }

.services-list {
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--line);
}
.services-list li {
  display: grid;
  grid-template-columns: 40px 1fr;
  gap: 16px;
  padding: 24px 0;
  border-bottom: 1px solid var(--line);
}
.num { font: 400 14px/2 var(--mono); color: var(--text-3); }
.services-list h3 { font: 500 28px/1.15 var(--serif); }
.services-list .num { padding-top: 4px; }
.services-list p { margin-top: 8px; color: var(--text-2); max-width: 40rem; }

@media (min-width: 960px) {
  .services-grid { grid-template-columns: 5fr 7fr; gap: 80px; align-items: start; }
  .services-intro { position: sticky; top: calc(var(--header-h) + 32px); }
  .services-photo { margin-top: 40px; }
  .services-list li { grid-template-columns: 56px 1fr; padding: 28px 0; }
  .services-list h3 { font-size: 32px; }
}

/* ---------- как работаем ---------- */

.process { background: var(--dark); color: var(--on-dark); }
.process .lead { color: var(--on-dark-2); }
.process-grid { display: grid; gap: 48px; }

.steps { list-style: none; margin: 40px 0 0; padding: 0; }
.steps li {
  display: grid;
  grid-template-columns: 40px 1fr;
  gap: 16px;
  padding: 20px 0;
  border-top: 1px solid var(--on-dark-line);
}
.steps li:last-child { border-bottom: 1px solid var(--on-dark-line); }
.steps .num { color: var(--on-dark-2); }
.steps h3 { font: 500 18px/1.4 var(--sans); }
.steps p { margin-top: 4px; color: var(--on-dark-2); font-size: 16px; }

.process-media { margin: 0; }
.process-media video {
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  background: #1A1713;
  pointer-events: none;
}
.process-media .tag { margin-top: 12px; color: var(--on-dark-2); }

@media (min-width: 960px) {
  .process-grid { grid-template-columns: 7fr 5fr; gap: 80px; align-items: center; }
  .steps li { grid-template-columns: 56px 1fr; padding: 24px 0; }
  .process-media { max-width: 440px; justify-self: end; width: 100%; }
  .process-media video { aspect-ratio: 9 / 16; }
}

/* ---------- шоурум ---------- */

.showroom-grid { display: grid; gap: 40px; }
.showroom-photo { margin: 0; }
.showroom-photo img { width: 100%; aspect-ratio: 3 / 4; object-fit: cover; }

.info-list {
  list-style: none;
  margin: 32px 0;
  padding: 0;
  display: grid;
  gap: 16px;
}
.info-list li { display: flex; align-items: flex-start; gap: 16px; }
.info-list .ico { margin-top: -6px; }
.info-list small { display: block; font-size: 15px; color: var(--text-2); }

.open-now {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 15px;
  color: var(--text-2);
}
.open-now::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--text-3);
}
.open-now.is-open { color: var(--text); }
.open-now.is-open::before { background: var(--open); }
.open-now[hidden] { display: none; }

@media (min-width: 960px) {
  .showroom-grid { grid-template-columns: 5fr 6fr; gap: 80px; align-items: center; }
}

/* ---------- отзывы ---------- */

.reviews { background: var(--raised); }
.rating-line { display: flex; align-items: center; gap: 8px; margin-top: 16px; color: var(--text-2); }
.rating-line b { font-weight: 500; color: var(--text); }
.rating-line .icon { color: var(--gold); }

.reviews-grid {
  display: grid;
  gap: 16px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.review {
  display: flex;
  flex-direction: column;
  gap: 24px;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--surface);
}
.review blockquote { margin: 0; }
.review blockquote p { font-size: 16px; line-height: 1.6; }
.review-meta {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 4px 16px;
  margin-top: auto;
  padding-top: 16px;
  border-top: 1px solid var(--line);
  font-size: 15px;
}
.review-meta span:last-child { color: var(--text-2); }

@media (min-width: 720px) {
  .reviews-grid { grid-template-columns: 1fr 1fr; }
}
@media (min-width: 1100px) {
  .reviews-grid { grid-template-columns: repeat(3, 1fr); gap: 24px; }
  .review { padding: 28px; }
}

/* ---------- instagram ---------- */

.insta-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.insta-grid a { display: block; aspect-ratio: 1 / 1; overflow: hidden; background: var(--raised); }
.insta-grid img { width: 100%; height: 100%; object-fit: cover; transition: opacity .15s var(--ease); }
.insta-grid a:hover img { opacity: .88; }

@media (min-width: 1100px) {
  .insta-grid { grid-template-columns: repeat(6, 1fr); gap: 16px; }
}

/* ---------- расчёт ---------- */

.calc { background: var(--surface); border-block: 1px solid var(--line); }
.calc-grid { display: grid; gap: 32px; }
.calc-box {
  padding: 24px 20px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--bg);
}
.calc-box fieldset { border: 0; margin: 0 0 28px; padding: 0; min-width: 0; }
.calc-box legend, .field-label {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin-bottom: 12px;
  padding: 0;
  font-weight: 500;
}
.q-num { font: 400 14px/1 var(--mono); color: var(--text-3); }
.field-label small { font-weight: 400; font-size: 14px; color: var(--text-3); }

.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { position: relative; }
.chip input {
  position: absolute;
  opacity: 0;
  width: 1px;
  height: 1px;
}
.chip span {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 16px;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  background: var(--surface);
  font-size: 15px;
  cursor: pointer;
  transition: background-color .15s var(--ease), color .15s var(--ease), border-color .15s var(--ease);
}
.chip span:hover { border-color: var(--text-2); }
.chip input:checked + span { background: var(--accent); border-color: var(--accent); color: var(--on-accent); }
.chip input:focus-visible + span { outline: 2px solid var(--text); outline-offset: 2px; }

.calc-box input[type="text"] {
  width: 100%;
  min-height: 48px;
  padding: 0 14px;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  background: var(--surface);
  color: var(--text);
  font: 400 16px/1.4 var(--sans);
}
.calc-box input[type="text"]::placeholder { color: var(--text-3); }
.calc-box input[type="text"]:focus-visible { outline: 2px solid var(--text); outline-offset: 1px; }

.calc-send { width: 100%; margin-top: 28px; }

.no-js .calc-steps { display: none; }
.no-js .calc-send { margin-top: 0; }

@media (min-width: 960px) {
  .calc-grid { grid-template-columns: 5fr 7fr; gap: 80px; align-items: start; }
  .calc-box { padding: 32px; }
}

/* ---------- вопросы ---------- */

.faq-grid { display: grid; gap: 32px; }
.faq-list { border-top: 1px solid var(--line); }
.faq-list details { border-bottom: 1px solid var(--line); }
.faq-list summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 64px;
  padding: 16px 0;
  font-size: 18px;
  font-weight: 500;
  line-height: 1.4;
  list-style: none;
  cursor: pointer;
}
.faq-list summary::-webkit-details-marker { display: none; }
.faq-list summary .icon { color: var(--text-3); transition: transform .18s var(--ease); }
.faq-list details[open] summary .icon { transform: rotate(180deg); }
.faq-list details p { padding: 0 40px 24px 0; color: var(--text-2); max-width: 44rem; }

@media (min-width: 960px) {
  .faq-grid { grid-template-columns: 5fr 7fr; gap: 80px; }
}

/* ---------- контакты ---------- */

.contacts { background: var(--surface); border-top: 1px solid var(--line); }
.contacts-grid { display: grid; gap: 40px; }

.contact-list {
  display: grid;
  gap: 20px;
  list-style: none;
  margin: 32px 0;
  padding: 0;
}
.contact-list li { display: flex; align-items: flex-start; gap: 16px; }
.contact-list .ico { margin-top: 2px; }
.contact-list .label { display: block; font-size: 14px; color: var(--text-3); }
.contact-list a { text-decoration: none; border-bottom: 1px solid var(--line-strong); }
.contact-list a:hover { border-bottom-color: var(--text); }
.contact-list .value { font-weight: 500; }

.hours {
  display: grid;
  grid-template-columns: auto auto;
  gap: 2px 24px;
  width: max-content;
  margin: 4px 0 8px;
  padding: 0;
  list-style: none;
  font-variant-numeric: tabular-nums;
  color: var(--text-2);
}
.hours li { display: contents; }
.hours li.is-today span { color: var(--text); font-weight: 500; }

.contact-actions { display: flex; flex-wrap: wrap; gap: 12px; }

.map {
  min-height: 360px;
  border: 1px solid var(--line);
  border-radius: 16px;
  overflow: hidden;
  background: var(--raised);
}
.map iframe { display: block; width: 100%; height: 100%; min-height: 360px; border: 0; }

@media (min-width: 960px) {
  .contacts-grid { grid-template-columns: 1fr 1fr; gap: 64px; align-items: stretch; }
  .map, .map iframe { min-height: 520px; }
}

/* ---------- подвал ---------- */

.site-footer { padding-block: 40px; border-top: 1px solid var(--line); background: var(--bg); }
.footer-inner {
  display: grid;
  gap: 16px;
  font-size: 15px;
  color: var(--text-2);
}
.footer-inner .brand { margin: 0; color: var(--text); }
.footer-links { display: flex; flex-wrap: wrap; gap: 4px 20px; }
.footer-links a { display: inline-flex; align-items: center; min-height: 44px; text-decoration: none; color: var(--text-2); }
.footer-links a:hover { color: var(--text); }
.footer-small { font-size: 14px; color: var(--text-3); }

@media (min-width: 960px) {
  .footer-inner { grid-template-columns: 1fr auto; align-items: center; }
  .footer-small { grid-column: 1 / -1; }
}

/* ---------- нижняя панель на телефоне ---------- */

.mobile-bar {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 45;
  display: flex;
  gap: 8px;
  padding: 12px 12px calc(12px + env(safe-area-inset-bottom));
  background: var(--surface);
  border-top: 1px solid var(--line);
}
.mobile-bar .btn-primary { flex: 1; min-width: 0; padding: 0 12px; line-height: 1.2; white-space: normal; }
.mobile-bar .btn-secondary { background: var(--surface); }

@media (min-width: 960px) {
  .mobile-bar { display: none; }
}

/* ---------- просмотр фото ---------- */

.lightbox {
  width: 100vw;
  max-width: 100vw;
  height: 100vh;
  max-height: 100vh;
  height: 100dvh;
  max-height: 100dvh;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--on-dark);
}
.lightbox::backdrop { background: rgba(18, 16, 13, 0.94); }
.lightbox[open] { display: flex; align-items: center; justify-content: center; }

.lb-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  max-width: min(92vw, 1100px);
  padding: 16px;
}
.lb-img {
  max-width: 100%;
  max-height: calc(100dvh - 140px);
  width: auto;
  height: auto;
  object-fit: contain;
}
.lb-caption { color: var(--on-dark-2); text-align: center; max-width: 40rem; }
.lb-bar { display: flex; align-items: center; gap: 8px; }
.lb-count { min-width: 64px; text-align: center; font: 400 14px/1 var(--mono); color: var(--on-dark-2); font-variant-numeric: tabular-nums; }
.lb-btn {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border: 1px solid var(--on-dark-line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
  color: var(--on-dark);
  cursor: pointer;
  transition: background-color .15s var(--ease);
}
.lb-btn:hover { background: rgba(255, 255, 255, 0.1); }
.lb-btn:focus-visible { outline-color: var(--on-dark); }
.lb-prev .icon { transform: scaleX(-1); }
.lb-close { margin-left: 16px; }

/* ---------- анимация при прокрутке ---------- */

@media (prefers-reduced-motion: no-preference) {
  .reveal-on .reveal {
    opacity: 0;
    transform: translateY(10px);
    transition: opacity .45s var(--ease), transform .45s var(--ease);
  }
  .reveal-on .reveal.is-in { opacity: 1; transform: none; }
  .reveal-on .reveal.no-anim { transition: none; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: 0s !important; animation: none !important; }
}
