/* ============================================================
   БЦ ВИКА-ЦЕНТР — дизайн-система
   Построена на языке ИГ ВИКА (vika.ru): фирменный синий #326292,
   белое пространство, крупная типографика Inter, монохромный UI.
   Весь контент и структура разделов сохранены.
   ============================================================ */

/* ---------- Шрифт ---------- */
@font-face {
  font-family: "Inter";
  src: url("../fonts/inter-cyrillic.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: "Inter";
  src: url("../fonts/inter-latin.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+2000-206F,
    U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215;
}

/* ---------- Токены ---------- */
:root {
  /* Нейтральные */
  --ink: #1d1d1f;
  --deep-gray: #474747;
  --mid-gray: #6e6e73;
  --quiet: #86868b;
  --hairline: #d6d6d6;
  --cool-wash: #e8e8ed;
  --canvas: #f5f5f7;
  --faded: #fafafc;
  --paper: #ffffff;

  /* Фирменный синий ВИКА */
  --brand: #326292;
  --brand-deep: #1d4470;
  --brand-night: #10294a;
  --brand-mid: #326292;
  --brand-light: #0071e3;
  --link: #0066cc;
  --gold: #dbca89;
  --accent: #ef742f; /* исторический акцент БЦ ВИКА */

  --font: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    Helvetica, Arial, sans-serif;

  --wrap: 1200px;
  --radius-card: 28px;
  --radius-pill: 980px;

  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
  --ease-soft: cubic-bezier(0.4, 0, 0.2, 1);
  --header-h: 72px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--header-h);
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  padding: 0;
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.6;
  letter-spacing: -0.022em;
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: var(--link);
  text-decoration: none;
  transition: color 0.3s var(--ease), opacity 0.3s var(--ease);
}
a:hover {
  text-decoration: underline;
}

::selection {
  background: rgba(50, 98, 146, 0.16);
  color: var(--ink);
}

/* ---------- Фокус с клавиатуры ---------- */
:focus-visible {
  outline: 2px solid var(--brand-light);
  outline-offset: 3px;
  border-radius: 4px;
}
/* На тёмном фоне синее кольцо теряется — берём светлое */
.hero :focus-visible,
.section--dark :focus-visible,
.footer :focus-visible,
.lightbox :focus-visible,
.header:not(.is-solid) :focus-visible {
  outline-color: #fff;
}

/* Пиксель Метрики для случая с отключённым JS — вне потока и вне экрана.
   Классом, а не style="", чтобы CSP не требовала 'unsafe-inline'. */
.metrika-pixel {
  position: absolute;
  left: -9999px;
}

/* ---------- Типографика ---------- */
h1,
h2,
h3,
h4 {
  margin: 0;
  font-weight: 700;
  line-height: 1.06;
  letter-spacing: -0.03em;
  color: var(--ink);
}

h2 {
  font-size: clamp(36px, 5.2vw, 68px);
}

h3 {
  font-size: clamp(22px, 2.4vw, 30px);
  line-height: 1.15;
  letter-spacing: -0.02em;
}

h4 {
  font-size: clamp(18px, 1.8vw, 22px);
  line-height: 1.25;
}

p {
  margin: 0 0 24px;
  color: var(--deep-gray);
  font-size: 17px;
  line-height: 1.65;
}

strong,
b {
  color: var(--ink);
  font-weight: 600;
}

.eyebrow {
  display: block;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--brand);
  margin: 0 0 16px;
}

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 0 24px;
}

.section {
  padding: clamp(72px, 11vw, 128px) 0;
  position: relative;
}
.section--light {
  background: var(--paper);
}
.section--tint {
  background: var(--canvas);
}
.section--dark {
  background: var(--brand-night);
  color: var(--paper);
}
.section--dark h2,
.section--dark h3,
.section--dark h4 {
  color: var(--paper);
}
.section--dark .eyebrow {
  color: var(--gold);
}
.section--dark p {
  color: rgba(255, 255, 255, 0.72);
}

.section-head {
  max-width: 900px;
  margin-bottom: clamp(44px, 6vw, 72px);
}
.section-sub {
  font-weight: 600;
  color: var(--mid-gray);
  font-size: clamp(18px, 1.9vw, 23px);
  line-height: 1.4;
  letter-spacing: -0.015em;
  margin: 22px 0 0;
}
.section--dark .section-sub {
  color: rgba(255, 255, 255, 0.7);
}

.sub-head {
  margin: clamp(64px, 8vw, 96px) 0 clamp(28px, 3.4vw, 40px);
  display: flex;
  align-items: baseline;
  gap: 18px;
}
.sub-head:first-of-type {
  margin-top: 0;
}
.sub-head .idx {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--brand);
  font-variant-numeric: tabular-nums;
  flex-shrink: 0;
}
.section--dark .sub-head .idx {
  color: var(--gold);
}

/* ============================================================
   ПРОГРЕСС ПРОКРУТКИ
   ============================================================ */
.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 2px;
  z-index: 200;
  pointer-events: none;
  background: transparent;
}
.scroll-progress span {
  display: block;
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, var(--brand), var(--brand-light));
  transition: width 0.1s linear;
}

/* ============================================================
   ШАПКА
   ============================================================ */
.header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 100;
  transition: background 0.45s var(--ease), backdrop-filter 0.45s var(--ease),
    border-color 0.45s var(--ease), transform 0.45s var(--ease);
  border-bottom: 1px solid transparent;
}
.header-inner {
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 0 24px;
  height: var(--header-h);
  display: flex;
  align-items: center;
  gap: 24px;
}

.header.is-solid {
  background: rgba(255, 255, 255, 0.72);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  backdrop-filter: saturate(180%) blur(20px);
  border-bottom-color: rgba(0, 0, 0, 0.08);
}
.header.is-hidden {
  transform: translateY(-100%);
}

.header-logo {
  display: flex;
  align-items: center;
  flex-shrink: 0;
  position: relative;
  height: 44px; /* палец попадает, картинка внутри остаётся 26px */
  opacity: 0;
  transform: translateY(-6px);
  transition: opacity 0.5s var(--ease), transform 0.5s var(--ease);
  pointer-events: none;
}
.header.is-solid .header-logo {
  opacity: 1;
  transform: none;
  pointer-events: auto;
}
.header-logo-img {
  height: 26px;
  width: auto;
  transition: opacity 0.4s var(--ease);
}
.header-logo-img.dark {
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  opacity: 0;
}
.header.is-solid .header-logo-img.light {
  opacity: 0;
}
.header.is-solid .header-logo-img.dark {
  opacity: 1;
}

.nav {
  margin-left: auto;
}
.nav ul {
  display: flex;
  align-items: center;
  gap: 2px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.nav li a {
  display: block;
  padding: 8px 14px;
  font-size: 15px;
  font-weight: 500;
  letter-spacing: -0.01em;
  color: rgba(255, 255, 255, 0.92);
  border-radius: var(--radius-pill);
  transition: color 0.3s var(--ease), background 0.3s var(--ease);
  white-space: nowrap;
}
.nav li a:hover {
  background: rgba(255, 255, 255, 0.16);
  text-decoration: none;
}
.header.is-solid .nav li a {
  color: var(--ink);
}
.header.is-solid .nav li a:hover {
  background: var(--cool-wash);
  color: var(--brand);
}
.nav li a.is-active {
  color: #fff;
  background: rgba(255, 255, 255, 0.16);
}
.header.is-solid .nav li a.is-active {
  color: var(--brand);
  background: var(--cool-wash);
}
.nav-mobile-extra {
  display: none;
}

.header-side {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-shrink: 0;
}
.header-side .tel {
  display: flex;
  align-items: center;
  min-height: 44px;
  font-size: 15px;
  font-weight: 600;
  color: #fff;
  letter-spacing: -0.01em;
  white-space: nowrap;
  transition: color 0.3s var(--ease);
}
.header-side .tel:hover {
  text-decoration: none;
  opacity: 0.75;
}
.header.is-solid .header-side .tel {
  color: var(--ink);
}
.header.is-solid .header-side .tel:hover {
  color: var(--brand);
}

/* Бургер */
.menu-icon {
  display: none;
  width: 44px;
  height: 44px;
  margin-right: -10px; /* оптическое выравнивание по краю макета */
  border: 0;
  background: transparent;
  cursor: pointer;
  padding: 12px 10px;
  flex-direction: column;
  justify-content: space-between;
  -webkit-appearance: none;
}
.menu-icon span {
  display: block;
  height: 2px;
  width: 100%;
  background: #fff;
  border-radius: 2px;
  transition: transform 0.4s var(--ease), opacity 0.3s var(--ease),
    background 0.4s var(--ease);
}
.header.is-solid .menu-icon span {
  background: var(--ink);
}
.menu-icon.is-open span {
  background: var(--ink);
}
.menu-icon.is-open span:nth-child(1) {
  transform: translateY(9px) rotate(45deg);
}
.menu-icon.is-open span:nth-child(2) {
  opacity: 0;
}
.menu-icon.is-open span:nth-child(3) {
  transform: translateY(-9px) rotate(-45deg);
}

.nav-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.35);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.4s var(--ease), visibility 0.4s var(--ease);
  z-index: 98;
  -webkit-backdrop-filter: blur(3px);
  backdrop-filter: blur(3px);
}
.nav-backdrop.is-visible {
  opacity: 1;
  visibility: visible;
}

/* ============================================================
   ГЛАВНЫЙ ЭКРАН
   ============================================================ */
.hero {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  overflow: hidden;
  background: var(--brand-night);
  padding: calc(var(--header-h) + 40px) 24px 210px;
}

.hero-media {
  position: absolute;
  inset: 0;
  overflow: hidden;
  z-index: 0;
}
.hero-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 72%;
  transform: scale(1.16);
  animation: heroZoom 3s var(--ease) forwards;
  will-change: transform;
}
@keyframes heroZoom {
  to {
    transform: scale(1.04);
  }
}

.hero-scrim {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(
    to bottom,
    rgba(16, 41, 74, 0.9) 0%,
    rgba(29, 68, 112, 0.7) 38%,
    rgba(29, 68, 112, 0.62) 62%,
    rgba(16, 41, 74, 0.92) 100%
  );
}
/* Мягкое свечение — «дыхание» фона */
.hero-glow {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  overflow: hidden;
}
.hero-glow i {
  position: absolute;
  display: block;
  border-radius: 50%;
  filter: blur(70px);
  opacity: 0.5;
  will-change: transform;
}
.hero-glow i:nth-child(1) {
  width: 46vw;
  height: 46vw;
  left: -10vw;
  top: 4vh;
  background: radial-gradient(
    circle,
    rgba(0, 113, 227, 0.55),
    rgba(0, 113, 227, 0) 68%
  );
  animation: drift1 22s var(--ease-soft) infinite alternate;
}
.hero-glow i:nth-child(2) {
  width: 38vw;
  height: 38vw;
  right: -8vw;
  top: 24vh;
  background: radial-gradient(
    circle,
    rgba(219, 202, 137, 0.34),
    rgba(219, 202, 137, 0) 68%
  );
  animation: drift2 27s var(--ease-soft) infinite alternate;
}
.hero-glow i:nth-child(3) {
  width: 52vw;
  height: 52vw;
  left: 28vw;
  bottom: -22vh;
  background: radial-gradient(
    circle,
    rgba(50, 98, 146, 0.6),
    rgba(50, 98, 146, 0) 70%
  );
  animation: drift3 19s var(--ease-soft) infinite alternate;
}
@keyframes drift1 {
  to {
    transform: translate3d(9vw, 7vh, 0) scale(1.16);
  }
}
@keyframes drift2 {
  to {
    transform: translate3d(-8vw, 10vh, 0) scale(0.86);
  }
}
@keyframes drift3 {
  to {
    transform: translate3d(-11vw, -6vh, 0) scale(1.12);
  }
}

/* Тонкая сетка поверх — «чертёж» */
.hero-grid {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background-image: linear-gradient(
      rgba(255, 255, 255, 0.055) 1px,
      transparent 1px
    ),
    linear-gradient(90deg, rgba(255, 255, 255, 0.055) 1px, transparent 1px);
  background-size: 96px 96px;
  -webkit-mask-image: radial-gradient(
    ellipse at 50% 40%,
    #000 10%,
    transparent 74%
  );
  mask-image: radial-gradient(ellipse at 50% 40%, #000 10%, transparent 74%);
  opacity: 0;
  animation: gridIn 2.4s var(--ease) 0.5s forwards;
}
@keyframes gridIn {
  to {
    opacity: 1;
  }
}

.hero-content {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 1020px;
  text-align: center;
  margin-top: auto;
  margin-bottom: auto;
}

.hero-title {
  margin: 0;
  padding: 0;
  font-size: 0;
  line-height: 0;
}

.hero-logo {
  width: 100%;
  max-width: 720px;
  margin: 0 auto 34px;
  opacity: 0;
  transform: translateY(28px) scale(0.97);
  filter: drop-shadow(0 12px 46px rgba(0, 0, 0, 0.4));
  animation: heroRise 1.5s var(--ease) 0.25s forwards;
}
@keyframes heroRise {
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.hero-class {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 7px 18px 7px 12px;
  margin: 0 0 26px;
  border-radius: var(--radius-pill);
  border: 1px solid rgba(255, 255, 255, 0.28);
  background: rgba(255, 255, 255, 0.1);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  color: rgba(255, 255, 255, 0.94);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  opacity: 0;
  transform: translateY(14px);
  animation: heroRise 1.1s var(--ease) 0.7s forwards;
}
.hero-class b {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--gold);
  color: var(--brand-night);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0;
}

.hero-lines {
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
  align-items: center;
}
.hero-lines li {
  color: rgba(255, 255, 255, 0.92);
  font-size: clamp(15px, 1.7vw, 20px);
  font-weight: 500;
  letter-spacing: -0.01em;
  text-shadow: 0 2px 22px rgba(0, 0, 0, 0.35);
  opacity: 0;
  transform: translateY(16px);
  animation: heroRise 1.1s var(--ease) forwards;
}
.hero-lines li:nth-child(1) {
  animation-delay: 0.88s;
}
.hero-lines li:nth-child(2) {
  animation-delay: 1s;
}
.hero-lines li:nth-child(3) {
  animation-delay: 1.12s;
}
.hero-lines a {
  color: #fff;
  font-weight: 600;
  border-bottom: 1px solid rgba(255, 255, 255, 0.4);
}
.hero-lines a:hover {
  text-decoration: none;
  border-bottom-color: #fff;
}
.hero-lines .metro {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}
.hero-lines .metro:before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--gold);
  flex-shrink: 0;
}

/* Быстрые ссылки внизу героя */
ul.service {
  position: absolute;
  left: 50%;
  bottom: 76px;
  transform: translateX(-50%);
  z-index: 2;
  width: 100%;
  max-width: 940px;
  padding: 0 clamp(6px, 2.5vw, 24px);
  margin: 0;
  list-style: none;
  display: flex;
  flex-wrap: nowrap;
  justify-content: space-between;
  align-items: flex-start;
  gap: clamp(3px, 1vw, 12px);
}
ul.service:after {
  content: "";
  position: absolute;
  top: calc(clamp(9px, 1.5vw, 15px) + clamp(4px, 0.6vw, 7px));
  left: 0;
  right: 0;
  height: 1px;
  background: linear-gradient(
    90deg,
    rgba(255, 255, 255, 0) 0%,
    rgba(255, 255, 255, 0.35) 16%,
    rgba(255, 255, 255, 0.35) 84%,
    rgba(255, 255, 255, 0) 100%
  );
  z-index: 0;
  transform: scaleX(0);
  transform-origin: center;
  animation: lineGrow 1.4s var(--ease) 1.25s forwards;
}
@keyframes lineGrow {
  to {
    transform: scaleX(1);
  }
}
ul.service li {
  position: relative;
  z-index: 1;
  flex: 1 1 0;
  min-width: 0;
  opacity: 0;
  transform: translateY(18px);
  animation: heroRise 1s var(--ease) forwards;
}
ul.service li:nth-child(1) {
  animation-delay: 1.32s;
}
ul.service li:nth-child(2) {
  animation-delay: 1.46s;
}
ul.service li:nth-child(3) {
  animation-delay: 1.6s;
}
ul.service li:nth-child(4) {
  animation-delay: 1.74s;
}
ul.service a {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: clamp(8px, 1.4vw, 16px);
  color: #fff;
  text-align: center;
}
ul.service a:hover {
  text-decoration: none;
}
ul.service i {
  display: block;
  width: clamp(8px, 1.2vw, 14px);
  height: clamp(8px, 1.2vw, 14px);
  border-radius: 50%;
  background: #fff;
  margin-top: clamp(9px, 1.5vw, 15px);
  box-shadow: 0 0 0 clamp(3px, 0.5vw, 6px) rgba(255, 255, 255, 0.16);
  transition: transform 0.45s var(--ease), box-shadow 0.45s var(--ease),
    background 0.45s var(--ease);
  flex-shrink: 0;
}
ul.service a:hover i {
  transform: scale(1.5);
  background: var(--gold);
  box-shadow: 0 0 0 10px rgba(219, 202, 137, 0.22);
}
ul.service span {
  display: block;
  width: 100%;
  max-width: 17ch;
  margin: 0 auto;
  font-size: clamp(9px, 2.2vw, 14px);
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: -0.015em;
  color: rgba(255, 255, 255, 0.9);
  transition: color 0.35s var(--ease), transform 0.45s var(--ease);
  overflow-wrap: break-word;
  -webkit-hyphens: none;
  hyphens: none;
}
ul.service a:hover span {
  color: #fff;
  transform: translateY(-2px);
}

.hero-scroll {
  position: absolute;
  left: 50%;
  bottom: 17px;
  transform: translateX(-50%);
  z-index: 2;
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  animation: heroRise 1s var(--ease) 2s forwards;
}
.hero-scroll:hover {
  text-decoration: none;
}
.hero-scroll-line {
  width: 1px;
  height: 22px;
  background: rgba(255, 255, 255, 0.6);
  position: relative;
  overflow: hidden;
  display: block;
}
.hero-scroll-line:after {
  content: "";
  position: absolute;
  inset: 0;
  background: #fff;
  animation: scrollPulse 2s var(--ease) infinite;
}
@keyframes scrollPulse {
  0% {
    transform: translateY(-100%);
  }
  60%,
  100% {
    transform: translateY(100%);
  }
}

/* ============================================================
   ПОКАЗАТЕЛИ ЗДАНИЯ
   ============================================================ */
.specs {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 1px;
  background: var(--hairline);
  border: 1px solid var(--hairline);
  border-radius: var(--radius-card);
  overflow: hidden;
  margin-bottom: clamp(48px, 6vw, 80px);
}
.spec {
  background: var(--paper);
  padding: clamp(22px, 2.6vw, 34px) clamp(18px, 2vw, 28px);
  display: flex;
  flex-direction: column;
  gap: 8px;
  transition: background 0.5s var(--ease);
}
.spec:hover {
  background: var(--faded);
}
.spec-val {
  font-size: clamp(26px, 3.1vw, 42px);
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.04em;
  color: var(--brand);
  font-variant-numeric: tabular-nums;
}
.spec-val small {
  font-size: 0.44em;
  font-weight: 600;
  letter-spacing: -0.02em;
  margin-left: 6px;
  color: var(--mid-gray);
}
.spec-label {
  font-size: 13.5px;
  /* --quiet (#86868b) на белом даёт 3.6:1 — для 13px мало, берём --mid-gray */
  color: var(--mid-gray);
  font-weight: 500;
  letter-spacing: -0.01em;
  line-height: 1.35;
}
.spec-note {
  font-size: 13px;
  color: var(--mid-gray);
  font-weight: 500;
  margin-top: -2px;
}

/* ============================================================
   ДВУХКОЛОНОЧНЫЙ БЛОК: ГАЛЕРЕЯ + ФАКТЫ
   ============================================================ */
.split {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: clamp(36px, 5vw, 72px);
  align-items: start;
}

/* ---------- Галерея ---------- */
.gallery {
  position: sticky;
  top: calc(var(--header-h) + 32px);
}
.gallery-stage {
  position: relative;
  border-radius: var(--radius-card);
  overflow: hidden;
  background: var(--cool-wash);
  aspect-ratio: 16 / 10;
  box-shadow: 0 24px 60px -28px rgba(16, 41, 74, 0.45);
}
.gallery-stage img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0;
  transform: scale(1.06);
  transition: opacity 0.85s var(--ease), transform 1.4s var(--ease);
}
.gallery-stage img.is-current {
  opacity: 1;
  transform: scale(1);
}
.gallery-stage:hover img.is-current {
  transform: scale(1.035);
}
.gallery-zoom {
  position: absolute;
  right: 16px;
  bottom: 16px;
  z-index: 3;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 8px 15px;
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.9);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  color: var(--ink);
  font-size: 12.5px;
  font-weight: 600;
  min-height: 40px;
  border: 0;
  cursor: pointer;
  font-family: var(--font);
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 0.4s var(--ease), transform 0.4s var(--ease);
}
.gallery-stage:hover .gallery-zoom,
.gallery-zoom:focus-visible {
  opacity: 1;
  transform: none;
}
.gallery-arrow {
  position: absolute;
  top: 50%;
  z-index: 3;
  width: 44px;
  height: 44px;
  margin-top: -22px;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.86);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  color: var(--ink);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.4s var(--ease), transform 0.4s var(--ease),
    background 0.3s var(--ease);
}
.gallery-arrow svg {
  width: 17px;
  height: 17px;
}
.gallery-arrow--prev {
  left: 14px;
  transform: translateX(-8px);
}
.gallery-arrow--next {
  right: 14px;
  transform: translateX(8px);
}
.gallery-stage:hover .gallery-arrow,
.gallery-arrow:focus-visible {
  opacity: 1;
  transform: none;
}
.gallery-arrow:hover {
  background: #fff;
}

/* Колонок столько, сколько кадров — сетка не ломается при их числе */
.gallery-thumbs {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 1fr;
  gap: 12px;
  margin-top: 12px;
}
.gallery-thumb {
  position: relative;
  border: 0;
  padding: 0;
  cursor: pointer;
  border-radius: 14px;
  overflow: hidden;
  aspect-ratio: 4 / 3;
  background: var(--cool-wash);
  outline: 2px solid transparent;
  outline-offset: 2px;
  transition: outline-color 0.4s var(--ease), transform 0.4s var(--ease);
}
.gallery-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.55) brightness(0.92);
  transition: filter 0.5s var(--ease), transform 0.7s var(--ease);
}
.gallery-thumb:hover img {
  transform: scale(1.07);
}
.gallery-thumb.is-current {
  outline-color: var(--brand);
}
.gallery-thumb.is-current img,
.gallery-thumb:hover img {
  filter: none;
}

/* ---------- Факты ---------- */
.facts {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.fact {
  padding: 22px 0;
  border-bottom: 1px solid var(--hairline);
}
.fact:first-child {
  border-top: 1px solid var(--hairline);
}
.fact-key {
  display: block;
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--brand);
  margin-bottom: 10px;
}
.fact-val {
  margin: 0;
  color: var(--deep-gray);
  font-size: 16.5px;
  line-height: 1.6;
}
.fact-list {
  margin: 0;
  padding: 0;
  list-style: none;
}
.fact-list li {
  position: relative;
  padding-left: 22px;
  color: var(--deep-gray);
  font-size: 16.5px;
  line-height: 1.55;
  margin-bottom: 9px;
}
.fact-list li:last-child {
  margin-bottom: 0;
}
.fact-list li:before {
  content: "";
  position: absolute;
  left: 0;
  top: 12px;
  width: 9px;
  height: 1px;
  background: var(--brand);
}

/* ============================================================
   КАРТОЧКИ С ИКОНКАМИ
   ============================================================ */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.feature {
  position: relative;
  background: var(--paper);
  border: 1px solid var(--hairline);
  border-radius: var(--radius-card);
  padding: clamp(26px, 2.8vw, 34px);
  display: flex;
  flex-direction: column;
  gap: 18px;
  overflow: hidden;
  transition: transform 0.55s var(--ease), box-shadow 0.55s var(--ease),
    border-color 0.55s var(--ease);
}
.section--tint .feature {
  background: var(--paper);
  border-color: transparent;
}
.feature:before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(
    420px circle at var(--mx, 50%) var(--my, 0%),
    rgba(50, 98, 146, 0.09),
    transparent 62%
  );
  opacity: 0;
  transition: opacity 0.5s var(--ease);
  pointer-events: none;
}
.feature:hover {
  transform: translateY(-6px);
  box-shadow: 0 26px 54px -30px rgba(16, 41, 74, 0.5);
  border-color: rgba(50, 98, 146, 0.25);
}
.feature:hover:before {
  opacity: 1;
}
.feature-ico {
  width: 52px;
  height: 52px;
  border-radius: 16px;
  background: var(--canvas);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: background 0.5s var(--ease), transform 0.5s var(--ease);
}
.section--tint .feature-ico {
  background: var(--cool-wash);
}
.feature:hover .feature-ico {
  background: rgba(50, 98, 146, 0.12);
  transform: scale(1.06) rotate(-3deg);
}
.feature-ico img {
  width: 26px;
  height: 26px;
  object-fit: contain;
}
.feature p {
  margin: 0;
  font-size: 16px;
  line-height: 1.55;
  color: var(--deep-gray);
}

/* ============================================================
   ТРАНСПОРТ
   ============================================================ */
.dist-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}
.dist {
  position: relative;
  border-radius: var(--radius-card);
  padding: clamp(26px, 2.8vw, 34px);
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.14);
  display: flex;
  flex-direction: column;
  gap: 16px;
  overflow: hidden;
  transition: transform 0.55s var(--ease), background 0.55s var(--ease),
    border-color 0.55s var(--ease);
}
.dist:hover {
  transform: translateY(-6px);
  background: rgba(255, 255, 255, 0.09);
  border-color: rgba(219, 202, 137, 0.45);
}
.dist-ico {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.94);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.5s var(--ease);
}
.dist:hover .dist-ico {
  transform: scale(1.06) rotate(-3deg);
}
.dist-ico img {
  width: 24px;
  height: 24px;
  object-fit: contain;
}
.dist-num {
  font-size: clamp(28px, 3vw, 38px);
  font-weight: 700;
  line-height: 1;
  letter-spacing: -0.04em;
  color: #fff;
  font-variant-numeric: tabular-nums;
}
.dist-num small {
  font-size: 0.45em;
  font-weight: 600;
  color: var(--gold);
  margin-left: 4px;
  letter-spacing: -0.01em;
}
.dist p {
  margin: 0;
  font-size: 15.5px;
  line-height: 1.55;
  color: rgba(255, 255, 255, 0.68);
}
.dist a {
  color: var(--gold);
  font-weight: 500;
  border-bottom: 1px solid rgba(219, 202, 137, 0.35);
}
.dist a:hover {
  text-decoration: none;
  border-bottom-color: var(--gold);
}

/* Маршруты от метро */
.routes {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  align-items: start;
  gap: 20px;
}
.route {
  border-radius: var(--radius-card);
  background: rgba(255, 255, 255, 0.045);
  border: 1px solid rgba(255, 255, 255, 0.13);
  padding: clamp(26px, 3vw, 40px);
  transition: background 0.55s var(--ease), border-color 0.55s var(--ease);
}
.route:hover {
  background: rgba(255, 255, 255, 0.07);
  border-color: rgba(255, 255, 255, 0.22);
}
.route-head {
  display: flex;
  align-items: center;
  gap: 14px;
  padding-bottom: 20px;
  margin-bottom: 22px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.14);
}
.route-ico {
  width: 44px;
  height: 44px;
  border-radius: 13px;
  background: rgba(255, 255, 255, 0.94);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.route-ico img {
  width: 23px;
  height: 23px;
  object-fit: contain;
}
.route-head h4 {
  color: #fff;
  margin: 0;
}
.route-time {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: var(--gold);
  letter-spacing: 0.02em;
  margin-top: 4px;
}
.route p {
  margin: 0 0 18px;
  font-size: 15.5px;
  color: rgba(255, 255, 255, 0.66);
}
.route p a {
  color: var(--gold);
  border-bottom: 1px solid rgba(219, 202, 137, 0.35);
}
.route p a:hover {
  text-decoration: none;
  border-bottom-color: var(--gold);
}
.route ol {
  counter-reset: step;
  list-style: none;
  margin: 0;
  padding: 0;
}
.route ol li {
  counter-increment: step;
  position: relative;
  padding-left: 38px;
  padding-bottom: 18px;
  color: rgba(255, 255, 255, 0.72);
  font-size: 15.5px;
  line-height: 1.6;
}
.route ol li:last-child {
  padding-bottom: 0;
}
.route ol li:before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: 1px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.24);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  font-variant-numeric: tabular-nums;
  transition: background 0.4s var(--ease), border-color 0.4s var(--ease),
    color 0.4s var(--ease);
}
/* вертикальная нить между шагами */
.route ol li:after {
  content: "";
  position: absolute;
  left: 12px;
  top: 28px;
  bottom: 6px;
  width: 1px;
  background: rgba(255, 255, 255, 0.14);
}
.route ol li:last-child:after {
  display: none;
}
.route ol li:hover:before {
  background: var(--gold);
  border-color: var(--gold);
  color: var(--brand-night);
}

/* ============================================================
   СВОБОДНЫЕ ПОМЕЩЕНИЯ
   ============================================================ */
.rooms-note {
  max-width: 900px;
  font-size: 15px;
  line-height: 1.7;
  color: var(--mid-gray);
  margin: 0 0 40px;
}
.rooms-price {
  display: inline-flex;
  align-items: baseline;
  gap: 10px;
  padding: 14px 24px;
  border-radius: var(--radius-pill);
  background: var(--paper);
  border: 1px solid var(--hairline);
  margin-bottom: 28px;
  font-size: 15px;
  color: var(--mid-gray);
  font-weight: 500;
}
.rooms-price b {
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.03em;
  color: var(--brand);
  white-space: nowrap;
}
/* Самое длинное слово в быстрых ссылках — «Транспортная», 64px при 9px.
   Ниже 400px колонка становится уже него, поэтому поджимаем поля героя
   и кегль: слово должно уместиться целиком, а не рваться посередине. */
@media (max-width: 400px) {
  .hero {
    padding-left: 14px;
    padding-right: 14px;
  }
  ul.service {
    padding-left: 0;
    padding-right: 0;
  }
  ul.service span {
    font-size: 8.5px;
    max-width: none;
  }
}

@media (max-width: 620px) {
  .rooms-price {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
    border-radius: 20px;
    padding: 18px 22px;
  }
}

.table-wrap {
  border-radius: var(--radius-card);
  border: 1px solid var(--hairline);
  background: var(--paper);
  overflow: hidden;
}
.table-scroll {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}
table.rooms {
  width: 100%;
  border-collapse: collapse;
  min-width: 780px;
}
table.rooms th {
  text-align: left;
  padding: 20px 22px;
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--brand);
  background: var(--canvas);
  border-bottom: 1px solid var(--hairline);
  white-space: nowrap;
  vertical-align: bottom;
  line-height: 1.35;
}
table.rooms td {
  padding: 20px 22px;
  font-size: 16px;
  color: var(--deep-gray);
  border-bottom: 1px solid var(--hairline);
  font-variant-numeric: tabular-nums;
}
table.rooms tbody tr {
  transition: background 0.35s var(--ease);
}
table.rooms tbody tr:hover {
  background: var(--faded);
}
table.rooms tbody tr:last-child td {
  border-bottom: 0;
}
.rooms-empty {
  padding: clamp(44px, 6vw, 76px) 28px;
  text-align: center;
}
.rooms-empty-ico {
  width: 58px;
  height: 58px;
  margin: 0 auto 22px;
  border-radius: 18px;
  background: var(--canvas);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--brand);
}
.rooms-empty-ico svg {
  width: 26px;
  height: 26px;
}
.rooms-empty p {
  max-width: 520px;
  margin: 0 auto 26px;
  color: var(--mid-gray);
  font-size: 16.5px;
}

/* ============================================================
   КНОПКИ
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  background: var(--brand);
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: -0.01em;
  padding: 13px 26px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--brand);
  transition: background 0.35s var(--ease), transform 0.35s var(--ease),
    box-shadow 0.35s var(--ease), border-color 0.35s var(--ease);
}
.btn:hover {
  background: var(--brand-light);
  border-color: var(--brand-light);
  text-decoration: none;
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 14px 30px -14px rgba(0, 113, 227, 0.7);
}
.btn svg {
  width: 16px;
  height: 16px;
}
.btn--ghost {
  background: transparent;
  color: var(--brand);
  border-color: var(--hairline);
}
.btn--ghost:hover {
  background: var(--brand);
  border-color: var(--brand);
  color: #fff;
  box-shadow: none;
}

/* ============================================================
   КОНТАКТЫ + КАРТА
   ============================================================ */
.contacts-grid {
  display: grid;
  grid-template-columns: 1fr 1.15fr;
  gap: clamp(36px, 5vw, 68px);
  align-items: center;
}
.contact-list {
  margin: 34px 0 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
}
.contact-list li {
  border-top: 1px solid rgba(255, 255, 255, 0.16);
}
.contact-list li:last-child {
  border-bottom: 1px solid rgba(255, 255, 255, 0.16);
}
.contact-list a,
.contact-list span {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 22px 4px;
  color: #fff;
  font-size: clamp(17px, 1.9vw, 22px);
  font-weight: 600;
  letter-spacing: -0.02em;
  transition: gap 0.4s var(--ease), color 0.35s var(--ease);
}
.contact-list a:hover {
  text-decoration: none;
  gap: 24px;
  color: var(--gold);
}
.contact-list .ico {
  width: 44px;
  height: 44px;
  border-radius: 13px;
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.16);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: background 0.4s var(--ease), border-color 0.4s var(--ease);
}
.contact-list a:hover .ico {
  background: rgba(219, 202, 137, 0.18);
  border-color: rgba(219, 202, 137, 0.5);
}
.contact-list .ico img {
  width: 20px;
  height: 20px;
  object-fit: contain;
  filter: brightness(0) invert(1);
}
.contact-list span {
  color: rgba(255, 255, 255, 0.86);
  font-weight: 500;
  font-size: clamp(16px, 1.6vw, 19px);
  line-height: 1.4;
}
.contacts-actions {
  margin-top: 34px;
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}
.btn--gold {
  background: var(--gold);
  border-color: var(--gold);
  color: var(--brand-night);
}
.btn--gold:hover {
  background: #fff;
  border-color: #fff;
  color: var(--brand-night);
  box-shadow: 0 14px 30px -14px rgba(255, 255, 255, 0.5);
}
.btn--outline-light {
  background: transparent;
  color: #fff;
  border-color: rgba(255, 255, 255, 0.4);
}
.btn--outline-light:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: #fff;
  color: #fff;
  box-shadow: none;
}

.map-card {
  display: block;
  position: relative;
  border-radius: var(--radius-card);
  overflow: hidden;
  line-height: 0;
  background: var(--cool-wash);
  box-shadow: 0 30px 70px -34px rgba(0, 0, 0, 0.65);
}
.map-card img {
  width: 100%;
  filter: grayscale(1) contrast(1.06);
  transition: filter 0.8s var(--ease), transform 1.2s var(--ease);
}
.map-card:hover img {
  filter: grayscale(0);
  transform: scale(1.03);
}
.map-hint {
  position: absolute;
  left: 50%;
  bottom: 22px;
  transform: translate(-50%, 8px);
  background: rgba(255, 255, 255, 0.95);
  color: var(--ink);
  font-size: 13px;
  font-weight: 600;
  line-height: 1;
  padding: 11px 20px;
  border-radius: var(--radius-pill);
  white-space: nowrap;
  opacity: 0;
  transition: opacity 0.4s var(--ease), transform 0.4s var(--ease);
}
.map-card:hover .map-hint {
  opacity: 1;
  transform: translate(-50%, 0);
}

/* ============================================================
   ФУТЕР
   ============================================================ */
.footer {
  background: var(--brand);
  color: #fff;
}
.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 28px;
  padding-top: 40px;
  padding-bottom: 40px;
  flex-wrap: wrap;
}
.footer-logo {
  height: 34px;
  width: auto;
  opacity: 0.95;
}
.footer-copy {
  font-size: 14px;
  color: rgba(255, 255, 255, 0.75);
  letter-spacing: -0.01em;
}
.footer-links {
  display: flex;
  gap: 26px;
  flex-wrap: wrap;
}
.footer-links a {
  color: rgba(255, 255, 255, 0.85);
  font-size: 15px;
  font-weight: 500;
}
.footer-links a:hover {
  color: #fff;
  text-decoration: none;
}

/* Кнопка «наверх» */
.to-top {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 90;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  border: 1px solid var(--hairline);
  background: rgba(255, 255, 255, 0.86);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  backdrop-filter: saturate(180%) blur(14px);
  color: var(--brand);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transform: translateY(12px);
  transition: opacity 0.4s var(--ease), transform 0.4s var(--ease),
    visibility 0.4s var(--ease), background 0.3s var(--ease),
    color 0.3s var(--ease);
}
.to-top svg {
  width: 17px;
  height: 17px;
}
.to-top.is-visible {
  opacity: 1;
  visibility: visible;
  transform: none;
}
.to-top:hover {
  background: var(--brand);
  color: #fff;
  border-color: var(--brand);
}

/* ============================================================
   ЛАЙТБОКС
   ============================================================ */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 300;
  background: rgba(10, 20, 34, 0.92);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 5vh 5vw;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.4s var(--ease), visibility 0.4s var(--ease);
}
.lightbox.is-open {
  opacity: 1;
  visibility: visible;
}
.lightbox img {
  max-width: 100%;
  max-height: 90vh;
  border-radius: 16px;
  box-shadow: 0 40px 90px -30px rgba(0, 0, 0, 0.8);
  transform: scale(0.94);
  transition: transform 0.5s var(--ease);
}
.lightbox.is-open img {
  transform: scale(1);
}
.lightbox-close,
.lightbox-nav {
  position: absolute;
  border: 1px solid rgba(255, 255, 255, 0.25);
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  border-radius: 50%;
  width: 46px;
  height: 46px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.3s var(--ease), border-color 0.3s var(--ease);
}
.lightbox-close:hover,
.lightbox-nav:hover {
  background: rgba(255, 255, 255, 0.22);
  border-color: rgba(255, 255, 255, 0.5);
}
.lightbox-close {
  top: 22px;
  right: 22px;
}
.lightbox-nav svg,
.lightbox-close svg {
  width: 18px;
  height: 18px;
}
.lightbox-nav--prev {
  left: 22px;
  top: 50%;
  margin-top: -23px;
}
.lightbox-nav--next {
  right: 22px;
  top: 50%;
  margin-top: -23px;
}

/* ============================================================
   АНИМАЦИИ ПОЯВЛЕНИЯ
   ============================================================ */
.has-js [data-anim] {
  opacity: 0;
  will-change: opacity, transform;
}
.has-js [data-anim="fade"] {
  transform: translateY(26px);
  transition: opacity 0.9s var(--ease), transform 0.9s var(--ease);
}
.has-js [data-anim="media"] {
  transform: translateY(34px) scale(0.97);
  transition: opacity 1.1s var(--ease), transform 1.1s var(--ease);
}
.has-js [data-anim="card"] {
  transform: translateY(30px);
  transition: opacity 0.9s var(--ease), transform 0.9s var(--ease);
}
.has-js [data-anim="row"] {
  transform: translateX(-22px);
  transition: opacity 0.85s var(--ease), transform 0.85s var(--ease);
}
.has-js [data-anim].is-in {
  opacity: 1;
  transform: none;
  will-change: auto;
}

/* ============================================================
   АДАПТИВНОСТЬ
   ============================================================ */
@media (min-width: 1500px) {
  :root {
    --wrap: 1320px;
  }
}

@media (max-width: 1100px) {
  .specs {
    grid-template-columns: repeat(3, 1fr);
  }
  .dist-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .feature-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 980px) {
  .split {
    grid-template-columns: 1fr;
    gap: 44px;
  }
  .gallery {
    position: static;
  }
  .routes {
    grid-template-columns: 1fr;
  }
  .contacts-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }
}

/* Логотип + меню + телефон занимают ~1070px — телефон убираем первым */
@media (max-width: 1099px) {
  .header-side .tel {
    display: none;
  }
}

/* Горизонтальное меню перестаёт помещаться около 940px — уходим в бургер */
@media (max-width: 959px) {
  .menu-icon {
    display: flex;
  }
  .header-logo {
    opacity: 1;
    transform: none;
    pointer-events: auto;
  }

  .nav {
    position: fixed;
    top: 0;
    right: 0;
    width: min(86vw, 340px);
    height: 100%;
    background: var(--paper);
    padding: calc(var(--header-h) + 24px) 28px 40px;
    transform: translateX(100%);
    /* visibility убирает закрытое меню из обхода табом,
       transition держит его видимым, пока едет анимация */
    visibility: hidden;
    transition: transform 0.5s var(--ease), visibility 0.5s var(--ease);
    z-index: 99;
    margin: 0;
    overflow-y: auto;
    box-shadow: -20px 0 60px rgba(0, 0, 0, 0.12);
  }
  .nav.is-open {
    transform: translateX(0);
    visibility: visible;
  }
  .nav ul {
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
  }
  .nav li a,
  .header.is-solid .nav li a {
    color: var(--ink);
    font-size: 18px;
    font-weight: 600;
    letter-spacing: -0.02em;
    padding: 15px 0;
    border-radius: 0;
    border-bottom: 1px solid var(--hairline);
    background: transparent;
  }
  .nav li a:hover,
  .header.is-solid .nav li a:hover,
  .nav li a.is-active,
  .header.is-solid .nav li a.is-active {
    background: transparent;
    color: var(--brand);
  }
  .nav-mobile-extra {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 14px;
    margin-top: 32px;
  }
  .nav-tel,
  .nav-mail {
    display: flex;
    align-items: center;
    min-height: 44px;
  }
  .nav-tel {
    font-size: 22px;
    font-weight: 700;
    color: var(--ink);
    letter-spacing: -0.02em;
  }
  .nav-mail {
    font-size: 16px;
    color: var(--brand);
  }
}

@media (max-width: 768px) {
  .hero {
    justify-content: center;
    padding-top: calc(var(--header-h) + 24px);
    padding-bottom: 56px;
  }
  .hero-logo {
    max-width: 90%;
    margin-bottom: 26px;
  }
  .hero-content {
    margin-top: 0;
    margin-bottom: 0;
  }
  ul.service {
    position: relative;
    left: auto;
    bottom: auto;
    transform: none;
    width: 100%;
    max-width: 100%;
    margin-top: clamp(34px, 8vw, 60px);
  }
  .hero-scroll {
    display: none;
  }

  .specs {
    grid-template-columns: repeat(2, 1fr);
  }
  .feature-grid {
    grid-template-columns: 1fr;
  }
  .gallery-thumbs {
    gap: 8px;
  }
  .to-top {
    right: 16px;
    bottom: 16px;
  }
}

@media (max-width: 560px) {
  .dist-grid {
    grid-template-columns: 1fr;
  }
  .specs {
    grid-template-columns: 1fr;
  }
  .lightbox-nav--prev {
    left: 10px;
  }
  .lightbox-nav--next {
    right: 10px;
  }
}

@media (max-width: 480px) {
  body {
    font-size: 16px;
  }
  p {
    font-size: 16px;
  }
  .wrap {
    padding: 0 20px;
  }
  .header-inner {
    padding: 0 20px;
  }
  .hero {
    padding-bottom: 44px;
  }
  .route ol li {
    font-size: 15px;
  }
  .footer-inner {
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 22px;
    padding-bottom: 56px;
  }
  .footer-links {
    justify-content: center;
    gap: 14px 22px;
  }
}

@media (max-width: 360px) {
  .wrap,
  .header-inner {
    padding-left: 16px;
    padding-right: 16px;
  }
}

/* Экраны с вырезом */
@supports (padding: env(safe-area-inset-left)) {
  .header-inner,
  .wrap {
    padding-left: max(24px, env(safe-area-inset-left));
    padding-right: max(24px, env(safe-area-inset-right));
  }
  .nav {
    padding-right: max(28px, env(safe-area-inset-right));
  }
  @media (max-width: 480px) {
    .header-inner,
    .wrap {
      padding-left: max(20px, env(safe-area-inset-left));
      padding-right: max(20px, env(safe-area-inset-right));
    }
  }
}

/* Телефон в альбомной ориентации */
@media (max-height: 560px) and (orientation: landscape) {
  :root {
    --header-h: 56px;
  }
  .hero {
    min-height: 620px;
    padding-top: calc(var(--header-h) + 20px);
    padding-bottom: 36px;
  }
  .hero-logo {
    max-width: 420px;
    margin-bottom: 18px;
  }
}

/* ============================================================
   СЕНСОРНЫЕ ЭКРАНЫ
   Наведения нет — всё, что появлялось по hover, показываем сразу,
   иначе кнопки остаются невидимыми, но нажимаемыми.
   ============================================================ */
@media (hover: none) {
  .gallery-arrow,
  .gallery-zoom {
    opacity: 1;
    transform: none;
  }
  .gallery-arrow {
    background: rgba(255, 255, 255, 0.92);
  }
  .map-hint {
    opacity: 1;
    transform: translate(-50%, 0);
  }
  /* Миниатюры на тач-устройствах не обесцвечиваем — нет состояния наведения */
  .gallery-thumb img {
    filter: none;
  }
  /* Ховер-эффекты карточек не «залипают» после нажатия */
  .feature:hover,
  .dist:hover,
  .project-card:hover {
    transform: none;
    box-shadow: none;
  }
  .feature:hover .feature-ico,
  .dist:hover .dist-ico {
    transform: none;
  }
}

/* ============================================================
   ОЧЕНЬ БОЛЬШИЕ ЭКРАНЫ
   ============================================================ */
@media (min-width: 1800px) {
  :root {
    --wrap: 1440px;
  }
  body {
    font-size: 18px;
  }
  p {
    font-size: 18px;
  }
}
@media (min-width: 2400px) {
  :root {
    --wrap: 1600px;
    --header-h: 84px;
  }
  .hero-logo {
    max-width: 900px;
  }
  ul.service {
    max-width: 1200px;
  }
}

/* Уважение к настройке «меньше движения» */
@media (prefers-reduced-motion: reduce) {
  *,
  *:before,
  *:after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
  .hero-logo,
  .hero-class,
  .hero-lines li,
  ul.service li,
  .hero-scroll,
  .hero-grid {
    opacity: 1;
    transform: none;
  }
  ul.service:after {
    transform: scaleX(1);
  }
}
