:root {
  --color-accent: #3f5073;
  --color-accent-hover: #334361;
  --color-accent-light: #5a6d94;
  --color-accent-muted: rgba(63, 80, 115, 0.1);
  --color-gold: #c4a96a;
  --color-gold-hover: #b39655;
  --color-bg: #ffffff;
  --color-bg-soft: #f4f6f9;
  --color-bg-dark: #2a3549;
  --color-placeholder: #e8ecf2;
  --color-text: #1c2433;
  --color-text-muted: #5c6678;
  --color-border: #dde3ec;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --radius-btn: 10px;
  --container-outer-max: 1440px;
  --container-outer-max-xl: 1920px;
  --container-inner-max: 1358px;
  --container-inner-max-xl: 1758px;
  --header-bar-radius: 14px;
  --header-bar-shadow: 0 12px 40px rgba(42, 53, 73, 0.12), 0 2px 8px rgba(42, 53, 73, 0.06);
  --header-glass-bg: rgba(255, 255, 255, 0.82);
  --header-glass-bg-pinned: rgba(255, 255, 255, 0.94);
  --header-glass-border: rgba(63, 80, 115, 0.12);
  --header-glass-blur: saturate(160%) blur(18px);
  --header-nav-color: #4a5568;
  --header-float-top: 16px;
  --header-bar-min-h: 68px;
  --header-bar-inner-pad-y: 31px;
  --hero-pad-top: var(--header-sticky-offset);
  --hero-pad-bottom: calc(32px + 48px + 32px);
  --header-sticky-offset: calc(
    var(--header-float-top) + var(--header-bar-min-h) + var(--header-bar-inner-pad-y) + 12px
  );
  --header-sticky-offset-compact: calc(
    var(--header-bar-min-h) + var(--header-bar-inner-pad-y) + 8px
  );
  --header-pin-duration: 0.82s;
  --header-pin-ease: cubic-bezier(0.28, 0.65, 0.32, 1);
  --font: "Onest", system-ui, -apple-system, sans-serif;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--header-sticky-offset);
  overscroll-behavior-y: none;
  /* при «натяжении» за верх слайдера не показывать белый фон страницы */
  background-color: #1a2235;
}

html.header-is-pinned {
  scroll-padding-top: var(--header-sticky-offset-compact);
}

html.header-is-pinned .hero__slide {
  padding-top: var(--header-sticky-offset-compact);
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 15px;
  line-height: 1.55;
  color: var(--color-text);
  background: var(--color-bg);
  overscroll-behavior-y: none;
}

@media only screen and (max-width: 900px) {
  html,
  body {
    overflow-x: hidden;
    max-width: 100%;
  }
}

/* Mobile scroll safety: ensure page can scroll */
@media (max-width: 900px) {
  html,
  body {
    overflow-y: auto !important;
    height: auto !important;
    overscroll-behavior-y: auto !important;
  }

  html {
    scroll-behavior: auto;
    background-color: var(--color-bg);
  }
}

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

a {
  color: inherit;
  text-decoration: none;
}

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
}

/* Внешний контейнер — как .Container_Container__Fc7xs в Arcada */
.container {
  width: 100%;
  max-width: var(--container-outer-max);
  margin: 0 auto;
  padding: 0 40px;
}

@media only screen and (min-width: 1770px) {
  .container {
    max-width: var(--container-outer-max-xl);
    padding: 0 80px;
  }
}

@media only screen and (min-width: 1281px) and (max-width: 1600px) {
  .container {
    max-width: var(--container-outer-max);
    padding: 0 40px;
  }
}

@media only screen and (min-width: 1024px) and (max-width: 1280px) {
  .container {
    padding: 0 30px;
  }
}

@media only screen and (min-width: 768px) and (max-width: 1023.9px) {
  .container {
    padding: 0 24px;
  }
}

@media only screen and (max-width: 767px) {
  .container {
    padding: 0 20px;
  }
}

/* Внутренний контейнер — как ряд шапки Arcada (max-width 1358 / 1758) */
.container-inner {
  width: 100%;
  max-width: var(--container-inner-max);
  margin-left: auto;
  margin-right: auto;
}

@media only screen and (min-width: 1770px) {
  .container-inner {
    max-width: var(--container-inner-max-xl);
  }
}

.section {
  padding: 40px 0;
}

.section-title {
  margin: 0 0 40px;
  font-size: clamp(28px, 4vw, 40px);
  font-weight: 700;
  letter-spacing: -0.02em;
  position: relative;
  padding-bottom: 16px;
}

.section-title::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 56px;
  height: 3px;
  border-radius: 2px;
  background: linear-gradient(90deg, var(--color-gold) 0%, var(--color-accent) 100%);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 28px;
  font-size: 14px;
  font-weight: 600;
  border-radius: var(--radius-btn);
  transition: background 0.2s, color 0.2s, box-shadow 0.2s, border-color 0.2s, transform 0.15s;
}

.btn:active {
  transform: scale(0.98);
}

.btn--primary {
  background: var(--color-accent);
  color: #fff;
  border: 1px solid var(--color-accent);
}

.btn--primary:hover {
  background: var(--color-accent-hover);
  border-color: var(--color-accent-hover);
  box-shadow: 0 8px 24px rgba(63, 80, 115, 0.35);
}

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

.btn--outline:hover {
  border-color: var(--color-accent);
  color: var(--color-accent);
}

.btn--outline-light {
  background: transparent;
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.95);
}

.btn--outline-light:hover {
  background: rgba(255, 255, 255, 0.12);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

.btn--outline-light-on-pink {
  background: transparent;
  color: #fff;
  border: 1px solid #fff;
}

.btn--outline-light-on-pink:hover {
  background: rgba(255, 255, 255, 0.15);
}

.btn--sm {
  padding: 12px 22px;
  font-size: 13px;
  white-space: nowrap;
}

.logo {
  display: inline-flex;
  align-items: center;
  line-height: 0;
}

.logo__img {
  display: block;
  height: 36px;
  width: auto;
  flex-shrink: 0;
}

.logo--footer .logo__img {
  height: 32px;
}

.nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(20px, 3vw, 40px);
  flex: 1 1 auto;
}

.nav a {
  font-size: 14px;
  font-weight: 500;
  color: var(--header-nav-color);
  white-space: nowrap;
  transition: color 0.2s;
}

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

.header__right {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 16px;
  flex-shrink: 0;
}

.header__phone {
  font-size: 17px;
  font-weight: 600;
  color: var(--color-text);
  white-space: nowrap;
  letter-spacing: -0.01em;
  transition: color 0.2s;
}

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

/* Круглая кнопка звонка — только узкая шапка; справа от логотипа, левее бургера */
.header__call-btn {
  display: flex;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(244, 244, 244, 0.75);
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: background 0.2s, box-shadow 0.2s, transform 0.15s;
  position: relative;
  overflow: hidden;
}

.header__call-btn:active {
  transform: scale(0.97);
}

.header__call-btn::before {
  content: "";
  width: 18px;
  height: 18px;
  display: block;
  background-color: var(--color-accent);
  -webkit-mask: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A//www.w3.org/2000/svg%27%20viewBox%3D%270%200%2024%2024%27%3E%3Cpath%20d%3D%27M14.25%209.75v-4.5m0%204.5h4.5m-4.5%200%206-6m-3%2018c-8.284%200-15-6.716-15-15V4.5A2.25%202.25%200%200%201%204.5%202.25h1.372c.516%200%20.966.351%201.091.852l1.106%204.423c.11.44-.054.902-.417%201.173l-1.293.97a1.062%201.062%200%200%200-.38%201.21%2012.035%2012.035%200%200%200%207.143%207.143c.441.162.928-.004%201.21-.38l.97-1.293a1.125%201.125%200%200%201%201.173-.417l4.423%201.106c.5.125.852.575.852%201.091V19.5a2.25%202.25%200%200%201-2.25%202.25h-2.25Z%27/%3E%3C/svg%3E") center / contain no-repeat;
  mask: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A//www.w3.org/2000/svg%27%20viewBox%3D%270%200%2024%2024%27%3E%3Cpath%20d%3D%27M14.25%209.75v-4.5m0%204.5h4.5m-4.5%200%206-6m-3%2018c-8.284%200-15-6.716-15-15V4.5A2.25%202.25%200%200%201%204.5%202.25h1.372c.516%200%20.966.351%201.091.852l1.106%204.423c.11.44-.054.902-.417%201.173l-1.293.97a1.062%201.062%200%200%200-.38%201.21%2012.035%2012.035%200%200%200%207.143%207.143c.441.162.928-.004%201.21-.38l.97-1.293a1.125%201.125%200%200%201%201.173-.417l4.423%201.106c.5.125.852.575.852%201.091V19.5a2.25%202.25%200%200%201-2.25%202.25h-2.25Z%27/%3E%3C/svg%3E") center / contain no-repeat;
  position: relative;
  z-index: 1;
  transition: background-color 220ms ease;
}

.header__call-btn::after {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--color-accent);
  border-radius: inherit;
  transform: scale(0);
  transform-origin: center;
  transition: transform 220ms ease;
  z-index: 0;
}

.header__call-btn:hover::after {
  transform: scale(1);
}

.header__call-btn:hover::before {
  background-color: #fff;
}

button.header__call-btn {
  border: none;
  padding: 0;
  margin: 0;
  font: inherit;
  color: inherit;
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
}

.header__burger {
  display: none;
  width: 44px;
  height: 44px;
  border: none;
  padding: 0;
  margin: 0;
  font: inherit;
  color: inherit;
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
  border-radius: 0;
  background: transparent;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  flex-shrink: 0;
  transition: opacity 0.2s, transform 0.15s;
}

.header__burger:active {
  transform: scale(0.97);
}

.header__burger-line {
  display: block;
  width: 18px;
  height: 2px;
  border-radius: 1px;
  background: #2b2b2b;
  transition: transform 0.25s ease, opacity 0.2s ease;
}

.header__burger.is-open .header__burger-line:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.header__burger.is-open .header__burger-line:nth-child(2) {
  opacity: 0;
}

.header__burger.is-open .header__burger-line:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* Выезжающее меню (моб.) */
.mobile-drawer {
  position: fixed;
  inset: 0;
  z-index: 200;
  pointer-events: none;
  visibility: hidden;
}

.mobile-drawer.is-open {
  pointer-events: auto;
  visibility: visible;
}

.mobile-drawer__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 15, 20, 0.45);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.mobile-drawer.is-open .mobile-drawer__backdrop {
  opacity: 1;
}

.mobile-drawer__panel {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(100%, 360px);
  max-width: 92vw;
  background: #fff;
  box-shadow: -12px 0 40px rgba(0, 0, 0, 0.12);
  transform: translateX(100%);
  transition: transform 0.32s cubic-bezier(0.28, 0.65, 0.32, 1);
  display: flex;
  flex-direction: column;
  padding: env(safe-area-inset-top, 0px) 0 env(safe-area-inset-bottom, 0px);
}

.mobile-drawer.is-open .mobile-drawer__panel {
  transform: translateX(0);
}

.mobile-drawer__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 18px 14px;
  border-bottom: 1px solid rgba(0, 0, 0, 0.08);
  flex-shrink: 0;
}

.mobile-drawer__title {
  font-size: 17px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--color-text);
}

.mobile-drawer__close {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #2b2b2b;
  transition: background 0.2s, color 0.2s;
}

.mobile-drawer__close:hover {
  background: rgba(0, 0, 0, 0.06);
  color: var(--color-accent);
}

.mobile-drawer__nav {
  display: flex;
  flex-direction: column;
  padding: 12px 10px 24px;
  gap: 4px;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.mobile-drawer__nav a {
  display: block;
  padding: 14px 14px;
  font-size: 16px;
  font-weight: 600;
  color: var(--header-nav-color);
  border-radius: 12px;
  transition: background 0.2s, color 0.2s;
}

.mobile-drawer__nav a:hover {
  background: rgba(63, 80, 115, 0.08);
  color: var(--color-accent);
}

html.mobile-drawer-open,
html.mobile-drawer-open body,
html.callback-drawer-open,
html.callback-drawer-open body {
  overflow: hidden;
  touch-action: none;
}

/* Заказ звонка: панель справа (десктоп), на моб. — на весь экран */
.callback-drawer {
  position: fixed;
  inset: 0;
  z-index: 250;
  pointer-events: none;
  visibility: hidden;
}

.callback-drawer.is-open {
  pointer-events: auto;
  visibility: visible;
}

.callback-drawer__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 15, 20, 0.45);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.callback-drawer.is-open .callback-drawer__backdrop {
  opacity: 1;
}

.callback-drawer__panel {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(100%, 440px);
  max-width: 100%;
  background: #fff;
  box-shadow: -12px 0 40px rgba(0, 0, 0, 0.12);
  transform: translateX(100%);
  transition: transform 0.32s cubic-bezier(0.28, 0.65, 0.32, 1);
  display: flex;
  flex-direction: column;
  padding: env(safe-area-inset-top, 0px) 0 env(safe-area-inset-bottom, 0px);
}

.callback-drawer.is-open .callback-drawer__panel {
  transform: translateX(0);
}

@media (max-width: 900px) {
  .callback-drawer__panel {
    width: 100%;
    left: 0;
    box-shadow: none;
  }
}

.callback-drawer__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 20px 20px 16px;
  border-bottom: 1px solid rgba(0, 0, 0, 0.08);
  flex-shrink: 0;
}

.callback-drawer__title {
  margin: 0;
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--color-text);
}

.callback-drawer__close {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #2b2b2b;
  transition: background 0.2s, color 0.2s;
  border: none;
  padding: 0;
  margin: 0;
  background: transparent;
  cursor: pointer;
  flex-shrink: 0;
}

.callback-drawer__close:hover {
  background: rgba(0, 0, 0, 0.06);
  color: var(--color-accent);
}

.callback-drawer__body {
  padding: 20px 20px 28px;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  flex: 1;
}

.callback-drawer__lead {
  margin: 0 0 20px;
  font-size: 14px;
  line-height: 1.55;
  color: var(--color-text-muted);
}

.callback-drawer__field {
  margin-bottom: 18px;
}

.callback-drawer__label {
  display: block;
  margin-bottom: 8px;
  font-size: 13px;
  font-weight: 600;
  color: var(--color-text);
}

.callback-drawer__input {
  width: 100%;
  box-sizing: border-box;
  padding: 14px 16px;
  font: inherit;
  font-size: 15px;
  color: var(--color-text);
  border: 1px solid var(--color-border);
  border-radius: 12px;
  background: #fff;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.callback-drawer__input::placeholder {
  color: #a8a8a8;
}

.callback-drawer__input:hover {
  border-color: rgba(0, 0, 0, 0.18);
}

.callback-drawer__input:focus {
  outline: none;
  border-color: var(--color-accent);
  box-shadow: 0 0 0 3px rgba(63, 80, 115, 0.12);
}

.callback-drawer__consent {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  margin: 16px 0 0;
  cursor: pointer;
  text-align: left;
}

.callback-drawer__consent-input {
  flex-shrink: 0;
  width: 18px;
  height: 18px;
  margin: 2px 0 0;
  accent-color: var(--color-accent);
  cursor: pointer;
}

.callback-drawer__consent-text {
  font-size: 12px;
  line-height: 1.5;
  color: var(--color-text-muted);
  text-align: left;
}

.callback-drawer__consent-text a {
  color: var(--color-accent);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.callback-drawer__consent-text a:hover {
  color: var(--color-accent-hover);
}

.callback-drawer__submit {
  width: 100%;
  justify-content: center;
  margin-top: 16px;
  min-height: 52px;
  font-size: 15px;
  font-weight: 700;
}

.callback-drawer__msg {
  margin: 16px 0 0;
  padding: 14px 16px;
  font-size: 14px;
  line-height: 1.45;
  text-align: center;
  border-radius: 12px;
  background: rgba(63, 80, 115, 0.08);
  color: var(--color-text);
}

.callback-drawer__msg[hidden] {
  display: none !important;
}

.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  width: 100%;
  z-index: 100;
  padding: var(--header-float-top) 0 0;
  background: transparent;
  pointer-events: none;
  transition:
    padding var(--header-pin-duration) var(--header-pin-ease),
    background-color 0.45s ease,
    box-shadow 0.45s ease;
}

/* Закрепление: без отдельного фона на .header — только полоска .header__bar на всю ширину */
.header--pinned {
  padding-top: 0;
}

.header--pinned .header__shell {
  max-width: 100%;
  width: 100%;
  padding: 0;
}

.header--pinned .header__bar,
.header.header--pinned .header__bar {
  transform: translateY(0) scale(1, 1);
  background: var(--header-glass-bg-pinned);
  -webkit-backdrop-filter: var(--header-glass-blur);
  backdrop-filter: var(--header-glass-blur);
  border-radius: 0;
  border: none;
  border-bottom: 1px solid rgba(255, 255, 255, 0.45);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
}

@media (prefers-reduced-motion: reduce) {
  .header,
  .header__shell {
    transition: none;
  }
}

@supports not ((-webkit-backdrop-filter: blur(1px)) or (backdrop-filter: blur(1px))) {
  .header__bar {
    background: rgba(255, 255, 255, 0.94);
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
  }

  .header--pinned .header__bar {
    background: rgba(255, 255, 255, 0.96);
    -webkit-backdrop-filter: none;
    backdrop-filter: none;
  }
}

.header__shell {
  pointer-events: auto;
  transition:
    max-width var(--header-pin-duration) var(--header-pin-ease),
    width var(--header-pin-duration) var(--header-pin-ease),
    padding var(--header-pin-duration) var(--header-pin-ease);
}

.header__bar {
  background: var(--header-glass-bg);
  -webkit-backdrop-filter: var(--header-glass-blur);
  backdrop-filter: var(--header-glass-blur);
  border: 1px solid var(--header-glass-border);
  border-radius: var(--header-bar-radius);
  box-shadow: var(--header-bar-shadow);
  transform-origin: top center;
  transition:
    transform var(--header-pin-duration) var(--header-pin-ease),
    border-radius var(--header-pin-duration) var(--header-pin-ease),
    box-shadow calc(var(--header-pin-duration) * 0.85) ease,
    background-color calc(var(--header-pin-duration) * 0.85) ease,
    border-color calc(var(--header-pin-duration) * 0.85) ease,
    -webkit-backdrop-filter calc(var(--header-pin-duration) * 0.85) ease,
    backdrop-filter calc(var(--header-pin-duration) * 0.85) ease;
}

.header:not(.header--pinned) .header__bar {
  /* убираем сужение по ширине — совпадение с контейнером */
  transform: translateY(6px);
}

@media (prefers-reduced-motion: reduce) {
  .header__bar {
    transition: none !important;
  }

  .header .header__bar {
    transform: none !important;
  }
}

.header__bar-inner {
  display: flex;
  align-items: center;
  gap: 20px;
  min-height: var(--header-bar-min-h);
  padding: 15px 26px 16px;
}

.header__bar-inner .logo {
  flex-shrink: 0;
}

@media only screen and (min-width: 1024px) and (max-width: 1280px) {
  .header__bar-inner {
    padding: 13px 16px 14px;
  }
}

@media only screen and (min-width: 768px) and (max-width: 1023.9px) {
  .header__bar-inner {
    padding: 10px 16px 11px;
  }
}

@media (max-width: 900px) {
  .nav {
    display: none;
  }

  .header__phone {
    display: none;
  }

  .header__burger {
    display: flex;
  }

  .header__right {
    margin-left: auto;
    gap: 8px;
  }

  .header__bar-inner {
    gap: 12px;
  }
}

@media (max-width: 767px) {
  .header__bar-inner {
    padding: 8px 14px 9px;
  }
}

@media (max-width: 480px) {
  .logo__img {
    height: 26px;
  }

  .header__call-btn,
  .header__burger {
    width: 42px;
    height: 42px;
  }
}

/* Hero */
.hero {
  position: relative;
  min-height: min(100vh, 900px);
  color: #fff;
  overflow: hidden;
}

.hero--boxed {
  min-height: auto;
  overflow: visible;
  background: var(--color-bg);
  /* header is fixed, so push hero below it */
  padding: var(--header-sticky-offset) 0 40px;
}

.hero--boxed .container {
  /* reduce side gutters only for the boxed slider */
  padding-left: 24px;
  padding-right: 24px;
}

@media only screen and (min-width: 1770px) {
  .hero--boxed .container {
    padding-left: 40px;
    padding-right: 40px;
  }
}

@media only screen and (max-width: 767px) {
  .hero--boxed .container {
    padding-left: 16px;
    padding-right: 16px;
  }
}

.hero--boxed .hero__frame {
  position: relative;
  min-height: min(72vh, 720px);
  border-radius: 22px;
  overflow: hidden;
  background: #1a2235;
  box-shadow: 0 18px 55px rgba(26, 34, 53, 0.28);
}

/* Полноэкранный герой — отличие от boxed-стиля Аркады */
.hero--full {
  min-height: min(100vh, 920px);
  padding-top: 0;
}

.hero--full .hero__frame {
  position: relative;
  min-height: min(100vh, 920px);
  border-radius: 0;
  overflow: hidden;
  background: #1a2235;
}

.hero--full .hero__overlay {
  background: linear-gradient(
    105deg,
    rgba(26, 34, 53, 0.78) 0%,
    rgba(63, 80, 115, 0.42) 48%,
    rgba(26, 34, 53, 0.28) 100%
  );
}

.hero--full .hero__bg:not(img) {
  background:
    radial-gradient(900px 600px at 75% 25%, rgba(196, 169, 106, 0.12), transparent),
    linear-gradient(135deg, #2a3549 0%, #3f5073 45%, #1a2235 100%);
}

.hero--full .hero__title {
  font-weight: 800;
  letter-spacing: -0.035em;
}

.hero--full .hero__slide {
  justify-content: center;
}

.hero--full .hero__intro {
  margin-left: 0;
}

.hero--full .hero__arrow {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.22);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.18);
  position: relative;
  overflow: hidden;
}

.hero--full .hero__arrow::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--color-gold);
  border-radius: inherit;
  transform: scale(0);
  transform-origin: center;
  transition: transform 220ms ease;
  z-index: 0;
}

.hero--full .hero__arrow svg {
  position: relative;
  z-index: 1;
  transition: color 220ms ease;
}

.hero--full .hero__arrow:hover::before {
  transform: scale(1);
}

.hero--full .hero__arrow:hover {
  color: var(--color-bg-dark);
  background: transparent;
}

.hero--full .hero__progress-bar {
  background: var(--color-gold);
}

.hero--full .hero-badge--accent {
  background: var(--color-gold);
  color: var(--color-bg-dark);
  box-shadow: none;
}

.hero--boxed .hero__slides {
  position: absolute;
  inset: 0;
}

.hero--boxed .hero__content-inner,
.hero--boxed .hero__controls-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 14px;
}

.hero--boxed .hero__intro {
  margin-left: 0;
  margin-top: 0;
}

.hero__slides {
  position: absolute;
  inset: 0;
}

.hero__slide {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: stretch;
  /* ровно между низом шапки и верхом пагинации; flex center — середина этой полосы */
  padding-top: var(--hero-pad-top);
  padding-bottom: var(--hero-pad-bottom);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.6s ease, visibility 0.6s;
}

@media (prefers-reduced-motion: reduce) {
  .hero__slide {
    transition: opacity 0.2s ease, visibility 0.2s;
  }
}

.hero__slide.is-active {
  opacity: 1;
  visibility: visible;
  z-index: 1;
}

/* Главная (boxed): блок с текстом у верхней зоны под шапкой */
.hero--boxed .hero__slide {
  justify-content: flex-start;
}

/* Страница проекта: на десктопе вертикально по центру между низом шапки и зоной пагинации */
@media (min-width: 768px) {
  .hero--project .hero__slide {
    justify-content: center;
  }
}

.hero__bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  z-index: 0;
}

/* fallback, если фон ещё не загружен из админки */
.hero__bg:not(img) {
  background: radial-gradient(1200px 800px at 70% 30%, rgba(255, 255, 255, 0.16), rgba(0, 0, 0, 0.2)),
    linear-gradient(90deg, rgba(0, 0, 0, 0.62) 0%, rgba(0, 0, 0, 0.2) 55%, rgba(0, 0, 0, 0.18) 100%);
}

.hero__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    rgba(0, 0, 0, 0.55) 0%,
    rgba(0, 0, 0, 0.25) 45%,
    rgba(0, 0, 0, 0.15) 100%
  );
  z-index: 1;
  pointer-events: none;
}

.hero--boxed .hero__overlay {
  background: linear-gradient(
    90deg,
    rgba(0, 0, 0, 0.30) 0%,
    rgba(0, 0, 0, 0.10) 55%,
    rgba(0, 0, 0, 0.05) 100%
  );
}

.hero__content {
  position: relative;
  z-index: 2;
  flex-shrink: 0;
  width: 100%;
  padding-top: 0;
  padding-bottom: 0;
  pointer-events: none;
}

.hero__content a,
.hero__content button {
  pointer-events: auto;
}

.hero__intro {
  max-width: 640px;
  margin-left: clamp(20px, 5vw, 80px);
}

.hero__badges {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 0 0 18px;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  padding: 7px 14px;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: 0.01em;
  border-radius: 10px;
  color: #fff;
}

.hero-badge--dark {
  background: rgba(38, 38, 38, 0.92);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.06) inset;
}

.hero-badge--accent {
  background: var(--color-accent);
  box-shadow: 0 1px 0 rgba(0, 0, 0, 0.12) inset;
}

.hero__title {
  margin: 0 0 16px;
  font-size: clamp(40px, 6vw, 64px);
  font-weight: 700;
  line-height: 1.05;
  letter-spacing: -0.03em;
  color: #fff;
}

.hero__subtitle {
  margin: 0 0 32px;
  font-size: 17px;
  line-height: 1.6;
  opacity: 0.95;
  max-width: 560px;
  color: #fff;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}

/* как шапка: .header → .header__shell.container → .header__bar → .header__bar-inner.container-inner */
.hero__controls {
  position: absolute;
  bottom: 32px;
  left: 0;
  right: 0;
  z-index: 3;
  pointer-events: none;
}

.hero__controls-shell {
  pointer-events: auto;
}

.hero__controls-bar {
  /* структурный слой как .header__bar — без стекла, только выравнивание по сетке */
  width: 100%;
}

.hero__controls-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  width: 100%;
}

.hero__progress {
  flex: 1;
  max-width: 120px;
  height: 4px;
  background: rgba(255, 255, 255, 0.25);
  border-radius: 4px;
  overflow: hidden;
}

.hero__progress-bar {
  height: 100%;
  width: 0%;
  background: var(--color-accent);
  border-radius: 4px;
  transition: width 0.1s linear;
}

.hero__arrows {
  display: flex;
  gap: 12px;
}

.hero__arrow {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: #fff;
  color: #2e2e2e;
  border: none;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.12);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s, transform 0.15s, box-shadow 0.2s;
}

.hero--boxed .hero__arrow {
  background: var(--header-glass-bg-pinned);
  border: none;
  outline: none;
  -webkit-backdrop-filter: var(--header-glass-blur);
  backdrop-filter: var(--header-glass-blur);
  box-shadow: 0 10px 22px rgba(0, 0, 0, 0.12);
  position: relative;
  overflow: hidden;
}

.hero__arrow:hover {
  background: #f5f5f5;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
}

.hero--boxed .hero__arrow:hover {
  background: rgba(255, 255, 255, 0.86);
}

.hero--boxed .hero__arrow::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--color-accent);
  border-radius: inherit;
  transform: scale(0);
  transform-origin: center;
  transition: transform 220ms ease;
  z-index: 0;
}

.hero--boxed .hero__arrow svg {
  position: relative;
  z-index: 1;
  transition: color 220ms ease;
}

.hero--boxed .hero__arrow:hover::before {
  transform: scale(1);
}

.hero--boxed .hero__arrow:focus,
.hero--boxed .hero__arrow:focus-visible {
  outline: none;
}

.hero--boxed .hero__arrow:hover {
  color: #fff;
  border: none;
  outline: none;
}

.hero__arrow:active {
  transform: scale(0.96);
}

@media only screen and (max-width: 767px) {
  :root {
    /* чуть плотнее снизу на малых экранах */
    --hero-pad-bottom: calc(24px + 48px + 20px);
  }
}

/* Info cards */
.info-cards {
  background: var(--color-bg);
  padding: 0 0 40px 0;
}

.info-cards__grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(0, 1.45fr);
  gap: 24px;
  align-items: stretch;
}

@media (max-width: 900px) {
  .info-cards__grid {
    grid-template-columns: 1fr;
  }
}

.info-card {
  border-radius: var(--radius-btn);
  padding: 32px 28px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 16px;
}

.info-card .btn {
  margin-top: 8px;
}

.info-card--sheet {
  background: #fff;
  border: 1px solid #ebebeb;
}

.info-card--sheet .btn--outline {
  color: var(--color-accent);
  border-color: var(--color-accent);
}

.info-card--sheet .btn--outline:hover {
  color: var(--color-accent-hover);
  border-color: var(--color-accent-hover);
  background: var(--color-accent-muted);
}

.info-card__accent {
  margin: 0;
  font-size: 28px;
  font-weight: 700;
  color: var(--color-accent);
  letter-spacing: -0.02em;
  line-height: 1.05;
  min-height: 44px;
  display: flex;
  align-items: flex-end;
  gap: 6px;
}

.info-card__accent--dark {
  color: #1f1f1f;
}

.info-card__accent strong {
  font-size: 40px;
  font-weight: 900;
  letter-spacing: -0.03em;
  line-height: 1;
}

.info-card__accent span {
  font-size: 18px;
  font-weight: 800;
  margin-left: 6px;
}

.info-card__text {
  margin: 0;
  flex: 1;
  font-size: 14px;
  color: var(--color-text-muted);
}

.info-card--accent {
  background: linear-gradient(145deg, #3f5073 0%, #334361 55%, #2a3549 100%);
  color: #fff;
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 16px 48px rgba(42, 53, 73, 0.22);
}

.info-card__title-light {
  margin: 0;
  font-size: 28px;
  font-weight: 700;
  color: #fff;
  line-height: 1.25;
  min-height: 44px;
  display: flex;
  align-items: flex-end;
}

.info-card__text-light {
  margin: 0;
  flex: 1;
  font-size: 14px;
  color: rgba(255, 255, 255, 0.92);
}

.info-card--accent .btn--outline {
  border-color: #fff;
  color: #fff;
}

.info-card--accent .btn--outline:hover {
  background: rgba(255, 255, 255, 0.15);
  border-color: #fff;
  color: #fff;
}

/* Projects */
.projects {
  background: var(--color-bg-soft);
}

.projects-page {
  background: var(--color-bg);
}

.projects-page .projects {
  padding-top: calc(
    var(--header-sticky-offset) + env(safe-area-inset-top, 0px) + 12px
  );
}

@media (min-width: 768px) {
  .projects-page .section-title {
    text-align: center;
  }

  .projects-page__empty {
    text-align: center;
    max-width: 36ch;
    margin-left: auto;
    margin-right: auto;
  }
}

.projects-page__empty {
  margin: 0;
  font-size: 16px;
  color: var(--color-text-muted);
}

@media (max-width: 767px) {
  /* не даём шорткату .section перебить отступ под fixed-шапку */
  .projects-page .projects.section {
    padding-top: calc(
      var(--header-sticky-offset) + env(safe-area-inset-top, 0px) + 20px
    );
    padding-bottom: 32px;
  }

}

.mortgage-page {
  background: var(--color-bg);
}

.mortgage-page .mortgage {
  padding-top: calc(
    var(--header-sticky-offset) + env(safe-area-inset-top, 0px) + 12px
  );
}

.projects__grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 32px;
}

@media (max-width: 768px) {
  .projects__grid {
    grid-template-columns: 1fr;
  }
}

.project-card {
  border-radius: var(--radius-md);
  overflow: hidden;
  background: #fff;
  border: 1px solid var(--color-border);
  box-shadow: 0 8px 32px rgba(42, 53, 73, 0.08);
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.project-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 16px 48px rgba(42, 53, 73, 0.14);
}

.project-card__media {
  display: block;
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  border-radius: var(--radius-lg);
}

.project-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.project-card__badges {
  position: absolute;
  top: 16px;
  left: 16px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  z-index: 2;
}

.project-card__badges .badge {
  border-radius: 10px;
}

.badge {
  padding: 6px 12px;
  font-size: 12px;
  font-weight: 600;
  border-radius: var(--radius-btn);
}

.badge--pink {
  background: var(--color-accent);
  color: #fff;
}

.badge--dark {
  background: rgba(30, 30, 30, 0.9);
  color: #fff;
}

/* Project page */
.project-page {
  background: var(--color-bg);
}

.hero--project {
  min-height: min(75vh, 700px);
}

/* project hero typography (не как на главной) */
.hero--project .hero__title {
  font-size: clamp(34px, 4.5vw, 54px);
}

.hero--project .hero__subtitle {
  font-size: 15px;
  max-width: 520px;
  margin-bottom: 24px;
}

.hero--project .hero__actions .btn {
  padding: 12px 22px;
  font-size: 13px;
}

.hero--project .hero__intro {
  margin-top: 0;
}

@media (max-width: 767px) {
  /* Слайдер: слева как на десктопе; заголовок/текст/бейджи чуть крупнее базовой мобильной версии */
  /* Проект: контент у низа кадра, над полосой и стрелками */
  .hero--project .hero__slide {
    justify-content: flex-end;
    padding-bottom: calc(32px + 36px + env(safe-area-inset-bottom, 0px));
    padding-top: calc(
      var(--header-sticky-offset) + env(safe-area-inset-top, 0px) + 8px
    );
  }

  .hero--boxed .hero__slide {
    justify-content: flex-start;
    padding-bottom: calc(28px + 36px + env(safe-area-inset-bottom, 0px));
    padding-top: max(
      env(safe-area-inset-top, 0px) + 4px,
      calc(var(--header-sticky-offset) + env(safe-area-inset-top, 0px) - 72px)
    );
  }

  /* При закреплении шапки не пересчитывать отступ — иначе текст слайдера «прыгает» */
  html.header-is-pinned .hero--boxed .hero__slide {
    padding-top: max(
      env(safe-area-inset-top, 0px) + 4px,
      calc(var(--header-sticky-offset) + env(safe-area-inset-top, 0px) - 72px)
    );
  }

  .hero--project .hero__intro {
    margin-left: clamp(0px, 3vw, 20px);
    margin-right: 0;
    margin-top: 0;
    max-width: 100%;
    text-align: left;
    padding: 0;
  }

  .hero--boxed .hero__intro {
    margin-left: 0;
    margin-right: 0;
    margin-top: clamp(6px, 1.2vh, 14px);
    max-width: 100%;
    text-align: left;
    padding: 0;
  }

  .hero--project .hero__badges,
  .hero--boxed .hero__badges {
    justify-content: flex-start;
    margin-bottom: 14px;
  }

  .hero--project .hero-badge,
  .hero--boxed .hero-badge {
    padding: 7px 14px;
    font-size: 13px;
  }

  .hero--project .hero__title {
    font-size: clamp(30px, 8.2vw, 42px);
    margin-bottom: 12px;
    line-height: 1.06;
  }

  .hero--project .hero__subtitle {
    margin-left: 0;
    margin-bottom: 20px;
    font-size: 16px;
    line-height: 1.55;
    max-width: 36rem;
    text-align: left;
  }

  .hero--boxed .hero__title {
    font-size: clamp(30px, 8.2vw, 44px);
    margin-bottom: 12px;
    line-height: 1.06;
  }

  .hero--boxed .hero__subtitle {
    margin-left: 0;
    margin-bottom: 20px;
    font-size: 16px;
    line-height: 1.55;
    max-width: 36rem;
    text-align: left;
  }

  .hero--project .hero__actions,
  .hero--boxed .hero__actions {
    justify-content: flex-start;
    gap: 10px;
    flex-wrap: wrap;
  }

  .hero--project .hero__actions .btn,
  .hero--boxed .hero__actions .btn {
    padding: 12px 22px;
    font-size: 13px;
    font-weight: 600;
    border-radius: 14px;
  }

  /* Нижняя панель: прогресс и стрелки в одну линию, стрелки меньше и ниже */
  .hero--project .hero__controls,
  .hero--boxed .hero__controls {
    bottom: calc(10px + env(safe-area-inset-bottom, 0px));
  }

  .hero--project .hero__controls-inner,
  .hero--boxed .hero__controls-inner {
    gap: 10px;
    align-items: center;
  }

  .hero--project .hero__progress,
  .hero--boxed .hero__progress {
    flex: 0 0 auto;
    width: min(72px, 22vw);
    max-width: 72px;
    min-width: 0;
    height: 2px;
    border-radius: 2px;
  }

  .hero--project .hero__progress-bar,
  .hero--boxed .hero__progress-bar {
    border-radius: 2px;
  }

  .hero--project .hero__arrows,
  .hero--boxed .hero__arrows {
    gap: 6px;
    flex-shrink: 0;
  }

  .hero--project .hero__arrow,
  .hero--boxed .hero__arrow {
    width: 34px;
    height: 34px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  }

  .hero--project .hero__arrow svg,
  .hero--boxed .hero__arrow svg {
    width: 15px;
    height: 15px;
  }

  .hero--project {
    min-height: min(70vh, 640px);
  }

  .hero--boxed .hero__frame {
    min-height: min(62vh, 560px);
  }
}

.project-stats {
  /* не залезаем на слайдер */
  margin-top: 40px;
}

.project-stats__row {
  display: grid;
  grid-template-columns: minmax(0, 2.2fr) repeat(3, minmax(0, 1fr));
  gap: 18px;
  background: #fff;
  border-radius: 18px;
  padding: 18px 18px;
  border: 1px solid rgba(0, 0, 0, 0.06);
}

.project-stats__left {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 8px;
  padding: 10px 10px;
}

.project-stats__title {
  font-size: 22px;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--color-text);
  line-height: 1.15;
}

.project-stats__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  color: var(--color-text-muted);
  font-size: 12px;
}

.project-stats__meta-item + .project-stats__meta-item::before {
  content: "•";
  margin-right: 10px;
  color: rgba(0, 0, 0, 0.25);
}

.project-stats__meta-item--eta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.project-stats__eta-icon {
  flex-shrink: 0;
  opacity: 0.85;
}

.project-stat {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 10px 10px;
  justify-content: center;
}

.project-stat__label {
  font-size: 12px;
  color: var(--color-text-muted);
}

.project-stat__value {
  font-size: 16px;
  font-weight: 700;
  color: var(--color-text);
}

@media (max-width: 767px) {
  .project-stats {
    margin-top: 12px;
  }

  .project-stats .container-inner {
    min-width: 0;
  }

  .project-stats__row {
    padding: 18px 16px 20px;
    gap: 0;
    border-radius: 16px;
  }

  .project-stats__left {
    padding: 0 0 16px;
    gap: 6px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
  }

  .project-stats__title {
    font-size: clamp(19px, 5.2vw, 22px);
    line-height: 1.2;
  }

  .project-stats__meta {
    font-size: 13px;
    gap: 8px 10px;
    line-height: 1.45;
  }

  .project-stat {
    padding: 14px 0 16px;
    gap: 4px;
    min-width: 0;
    align-items: flex-start;
    justify-content: flex-start;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
  }

  .project-stat:last-child {
    border-bottom: none;
    padding-bottom: 0;
  }

  .project-stat__value {
    font-size: 15px;
    line-height: 1.35;
    word-break: break-word;
  }

  .project-stat__label {
    font-size: 12px;
    line-height: 1.35;
  }
}

.project-about__grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 64px;
  align-items: center;
}

/* Страница проекта: один блок #f6f7fb под слайдером и текстом */
.project-page .project-about__grid {
  gap: 0;
  align-items: stretch;
  background: #f6f7fb;
  border-radius: var(--radius-md);
  overflow: hidden;
}

.project-page .project-about__grid > * {
  min-height: 0;
  min-width: 0;
  max-width: 100%;
}

.project-page .project-about__grid > .media-slider {
  min-height: 0;
  height: 100%;
  align-self: stretch;
  display: flex;
  flex-direction: column;
}

.project-page .project-about__grid > .media-slider .media-slider__viewport {
  flex: 1 1 auto;
  width: 100%;
  min-height: 0;
  height: 100%;
  aspect-ratio: unset;
  border-radius: var(--radius-md);
  overflow: hidden;
  background: #f6f7fb;
}

@media (max-width: 1023px) {
  .project-page .project-about__grid > .media-slider .media-slider__viewport {
    aspect-ratio: 16 / 11;
    min-height: 300px;
    height: auto;
    flex: 0 0 auto;
  }
}

@media (min-width: 1024px) {
  .project-page .project-about__grid {
    grid-template-rows: minmax(380px, clamp(380px, 42vw, 480px));
    min-height: 380px;
  }

  .project-page .project-about__grid > .media-slider .media-slider__viewport {
    flex: 1 1 auto;
    min-height: 0;
    height: 100%;
  }

  .project-page .project-about__grid > .project-about__text {
    height: 100%;
    min-height: 0;
    overflow-y: auto;
    justify-content: center;
  }
}

.media-slider__viewport {
  position: relative;
  border-radius: 18px;
  overflow: hidden;
  background: #f3f3f3;
  aspect-ratio: 16 / 11;
}

.media-slider--wide .media-slider__viewport {
  aspect-ratio: 16 / 9;
}

.project-architecture .media-slider--wide .media-slider__viewport {
  aspect-ratio: 16 / 11;
}

.media-slider__slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.35s ease, visibility 0.35s ease;
}

.media-slider__slide.is-active {
  opacity: 1;
  visibility: visible;
}

.media-slider__slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.media-slider__arrows {
  position: absolute;
  right: 14px;
  bottom: 14px;
  display: flex;
  gap: 10px;
  z-index: 3;
}

.media-slider__arrow {
  width: 40px;
  height: 40px;
  border-radius: 999px;
  background: #fff;
  color: #2e2e2e;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.12);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s, transform 0.15s, box-shadow 0.2s;
  position: relative;
  overflow: hidden;
}

.project-page .media-slider__arrow::before,
.project-page .hero__arrow::before {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--color-accent);
  border-radius: inherit;
  transform: scale(0);
  transform-origin: center;
  transition: transform 220ms ease;
  z-index: 0;
}

.project-page .media-slider__arrow svg,
.project-page .hero__arrow svg {
  position: relative;
  z-index: 1;
}

.project-page .media-slider__arrow:hover::before,
.project-page .hero__arrow:hover::before {
  transform: scale(1);
}

.project-page .media-slider__arrow:hover,
.project-page .hero__arrow:hover {
  color: #fff;
}

.project-page .hero__arrow {
  position: relative;
  overflow: hidden;
}

.project-page .hero__arrow:hover {
  background: #fff;
}

.media-slider__arrow:hover {
  background: #f5f5f5;
}

.media-slider__arrow:active {
  transform: scale(0.96);
}

.project-about__title {
  margin: 0 0 14px;
  font-size: 28px;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.project-about__lead {
  margin: 0 0 16px;
  color: var(--color-text-muted);
  overflow-wrap: break-word;
  word-wrap: break-word;
}

.project-page .project-about__lead,
.project-page .project-about__lead * {
  max-width: 100%;
  overflow-wrap: break-word;
  word-wrap: break-word;
}

.project-page .project-about__lead img,
.project-page .project-about__lead table,
.project-page .project-about__lead iframe,
.project-page .project-about__lead video {
  max-width: 100%;
  height: auto;
}

.project-about__list {
  margin: 0 0 18px;
  padding-left: 18px;
  color: var(--color-text);
}

.project-about__list li {
  margin: 0 0 8px;
}

.project-page .project-about__text {
  background: transparent;
  border-radius: 0;
  padding: clamp(22px, 3vw, 40px) clamp(26px, 3.2vw, 44px);
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  min-width: 0;
  width: 100%;
  max-width: 100%;
  overflow-wrap: break-word;
}

.project-page .project-about__title,
.project-page .project-about__list {
  min-width: 0;
  max-width: 100%;
  overflow-wrap: break-word;
}

.project-page .project-about__text > .btn {
  align-self: flex-start;
}

.pill-tabs {
  display: inline-flex;
  gap: 10px;
  padding: 10px;
  border-radius: 999px;
  background: #f4f4f4;
}

.pill-tabs__btn {
  padding: 10px 16px;
  border-radius: 999px;
  background: transparent;
  font-weight: 600;
  font-size: 13px;
  color: #2b2b2b;
  transition: background 0.2s, color 0.2s;
}

.pill-tabs__btn.is-active {
  background: var(--color-accent);
  color: #fff;
}

.project-architecture {
  padding: 28px 0 10px;
}

.project-architecture .project-feature-tabs {
  background: #f6f7fb;
  box-shadow: none;
}

/* Внешняя оболочка: не даёт табам раздвигать страницу; скролл — у .project-feature-tabs */
.project-feature-tabs-viewport {
  max-width: 100%;
  min-width: 0;
}

.project-architecture .project-feature-tabs-viewport {
  margin: 0 auto 28px;
}

.project-feature-tabs {
  width: fit-content;
  max-width: 100%;
  margin: 0;
  display: flex;
  gap: 8px;
  padding: 10px;
  border-radius: 999px;
  background: #fff;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.08);
  position: relative;
}

.project-feature-tabs__btn {
  padding: 10px 16px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 13px;
  color: #2b2b2b;
  transition: background 0.2s, color 0.2s;
  position: relative;
  z-index: 2;
}

.project-feature-tabs__btn.is-active {
  color: #fff;
}

.project-feature-tabs__pill {
  position: absolute;
  top: 3px;
  bottom: 3px;
  left: 0;
  width: 0;
  border-radius: 999px;
  background: var(--color-accent);
  z-index: 1;
  transition: transform 260ms ease, width 260ms ease;
  will-change: transform, width;
}

.project-feature-tabs[data-pill-ready="false"] .project-feature-tabs__pill {
  display: none;
}

.project-feature-panel {
  display: none;
}

.project-feature-panel.is-active {
  display: block;
  margin-top: 15px;
}

.project-architecture__grid {
  display: grid;
  grid-template-columns: minmax(0, 2.85fr) minmax(260px, 1fr);
  gap: 0;
  background: var(--color-bg);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: none;
  min-height: 0;
}

.project-architecture__media {
  min-width: 0;
  background: #0f0f0f;
  overflow: hidden;
}

.project-architecture__visual {
  position: relative;
  width: 100%;
  min-height: 280px;
  aspect-ratio: 16 / 10;
}

.project-architecture__visual .media-slider--architecture {
  position: absolute;
  inset: 0;
  display: block;
}

.project-architecture__visual .media-slider--architecture .media-slider__viewport {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  aspect-ratio: unset;
  border-radius: 0;
}

.project-architecture__overlay-title {
  position: absolute;
  z-index: 3;
  left: 0;
  right: 0;
  top: 0;
  margin: 0;
  padding: clamp(22px, 4vw, 40px) clamp(20px, 3.5vw, 44px) 72px;
  max-width: 22ch;
  font-size: clamp(22px, 2.6vw, 34px);
  font-weight: 700;
  line-height: 1.18;
  letter-spacing: -0.02em;
  color: #fff;
  text-shadow: 0 2px 28px rgba(0, 0, 0, 0.45), 0 1px 3px rgba(0, 0, 0, 0.35);
  pointer-events: none;
}

.project-architecture__bottom-pag {
  position: absolute;
  z-index: 4;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  justify-content: flex-start;
  align-items: stretch;
  padding: 14px clamp(16px, 2.5vw, 28px) 18px clamp(20px, 5vw, 48px);
  background: linear-gradient(to top, rgba(0, 0, 0, 0.55), transparent);
  pointer-events: none;
}

.project-architecture__photo-pag {
  pointer-events: auto;
  display: flex;
  align-items: flex-end;
  gap: 8px;
  width: min(560px, 78%);
  max-width: calc(100% - 24px);
}

.project-architecture__photo-pag-item {
  flex: 1 1 0;
  min-width: 0;
  height: 26px;
  padding: 0 0 2px;
  border: 0;
  background: transparent;
  cursor: pointer;
  display: flex;
  align-items: flex-end;
  justify-content: stretch;
}

.project-architecture__photo-pag-track {
  display: block;
  width: 100%;
  height: 3px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.22);
  overflow: hidden;
}

.project-architecture__photo-pag-item.is-active .project-architecture__photo-pag-track {
  height: 4px;
  background: rgba(255, 255, 255, 0.32);
}

.project-architecture__photo-pag-fill {
  display: block;
  height: 100%;
  width: 0%;
  border-radius: inherit;
  background: var(--color-accent);
  box-shadow: 0 0 12px rgba(63, 80, 115, 0.45);
  transition: none;
  will-change: width;
}

.project-architecture__photo-pag-item.is-behind .project-architecture__photo-pag-fill {
  background: rgba(255, 255, 255, 0.38);
  box-shadow: none;
}

.project-architecture__card {
  background: #f6f7fb;
  padding: clamp(22px, 3vw, 40px) clamp(22px, 2.8vw, 36px) clamp(20px, 2.5vw, 32px);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 28px;
  min-height: 0;
}

.project-architecture__card-body {
  flex: 1 1 auto;
  min-height: 0;
}

.project-architecture__card-body p {
  margin: 0;
  color: var(--color-text-muted);
  font-size: 15px;
  line-height: 1.6;
}

.project-architecture__card-nav {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 16px;
  flex-shrink: 0;
  margin-top: auto;
}

.project-architecture__card-arrows {
  display: flex;
  align-items: center;
  gap: 10px;
}

.project-architecture__card-arrows .project-architecture__slide-counter {
  margin-left: 4px;
}

.project-architecture__card-nav .media-slider__arrow {
  position: relative;
  width: 44px;
  height: 44px;
  background: #f8f8f8;
  color: #2e2e2e;
  box-shadow: none;
  border: 1px solid rgba(0, 0, 0, 0.06);
}

.project-architecture__card-nav .media-slider__counter {
  position: static;
  font-size: 13px;
  font-weight: 600;
  color: rgba(0, 0, 0, 0.38);
  text-shadow: none;
  white-space: nowrap;
  align-self: center;
  line-height: 1;
}

@media (max-width: 900px) {
  .project-architecture {
    padding: 20px 0 8px;
  }

  .project-architecture .container-inner {
    min-width: 0;
  }

  .mortgage-head-row,
  .mortgage-widget,
  .project-architecture .container-inner,
  .project-page .container-inner {
    min-width: 0;
    max-width: 100%;
  }

  /* Табы: viewport по ширине экрана; скролл только у внутреннего ряда */
  .project-feature-tabs-viewport {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    overflow: visible;
    box-sizing: border-box;
  }

  .project-architecture .project-feature-tabs-viewport {
    margin-bottom: 18px;
    background: #f6f7fb;
    border-radius: 18px;
    box-shadow: none;
    padding: 12px;
  }

  .project-architecture .project-feature-tabs-viewport > .project-feature-tabs {
    background: transparent;
    box-shadow: none;
    padding: 0;
  }

  /* Карточка (фон + тень) на viewport; внутри — только скролл кнопок */
  .mortgage-head-row .project-feature-tabs-viewport,
  .apartments-page__head .project-feature-tabs-viewport {
    background: #fff;
    border-radius: 999px;
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.08);
    padding: 10px;
    margin-bottom: 8px;
    filter: none;
  }

  .mortgage-head-row .project-feature-tabs-viewport {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    flex: 1 1 auto;
    align-self: stretch;
  }

  .mortgage-head-row .project-feature-tabs-viewport > .project-feature-tabs,
  .apartments-page__head .project-feature-tabs-viewport > .project-feature-tabs {
    background: transparent;
    box-shadow: none;
    padding: 0;
  }

  .project-feature-tabs-viewport > .project-feature-tabs,
  .project-architecture .project-feature-tabs,
  .mortgage-head-row .mortgage-program-tabs,
  .mortgage-program-tabs {
    width: 100%;
    min-width: 0;
    max-width: 100%;
    margin-left: 0;
    margin-right: 0;
    display: flex;
    flex-direction: row;
    flex-wrap: nowrap;
    align-items: center;
    gap: 8px;
    padding: 5px;
    border-radius: 26px;
    box-sizing: border-box;
    overflow-x: auto;
    overflow-y: visible;
    -webkit-overflow-scrolling: touch;
    touch-action: pan-x;
    overscroll-behavior-x: contain;
    scrollbar-width: none;
    -ms-overflow-style: none;
  }

  .project-feature-tabs-viewport > .project-feature-tabs::-webkit-scrollbar,
  .project-architecture .project-feature-tabs::-webkit-scrollbar,
  .mortgage-program-tabs::-webkit-scrollbar {
    display: none;
  }

  .project-architecture .project-feature-tabs__pill,
  .mortgage-program-tabs .project-feature-tabs__pill {
    display: block;
  }

  /* padding перенесён на viewport — pill на всю высоту кнопки */
  .project-feature-tabs-viewport > .project-feature-tabs .project-feature-tabs__pill {
    top: 0;
    bottom: 0;
  }

  .project-architecture .project-feature-tabs__btn,
  .mortgage-program-tabs .project-feature-tabs__btn {
    width: auto;
    max-width: none;
    flex: 0 0 auto;
    box-sizing: border-box;
    border-radius: 999px;
    text-align: center;
    white-space: nowrap;
    line-height: 1.35;
    font-size: 13px;
    padding: 10px 16px;
    background: transparent;
    border: none;
    color: #2b2b2b;
    transition: color 0.2s;
  }

  .project-architecture .project-feature-tabs__btn.is-active,
  .mortgage-program-tabs .project-feature-tabs__btn.is-active {
    background: transparent;
    border: none;
    color: #fff;
  }

  .project-architecture__grid {
    grid-template-columns: 1fr;
    grid-template-rows: none;
    min-width: 0;
    border-radius: 16px;
  }

  .project-architecture__media {
    height: auto;
  }

  .project-architecture__visual {
    aspect-ratio: 16 / 11;
    min-height: 220px;
  }

  .project-architecture__overlay-title {
    max-width: none;
    font-size: clamp(19px, 5.2vw, 26px);
    padding: 20px 18px 64px;
  }

  .project-architecture__bottom-pag {
    padding: 12px 16px 16px 18px;
    justify-content: flex-start;
  }

  .project-architecture__photo-pag {
    width: 100%;
    max-width: calc(100vw - 48px);
  }

  .project-architecture__card {
    padding: 20px 18px 22px;
    gap: 20px;
    height: auto;
    overflow-y: visible;
  }

  .project-architecture__card-nav {
    flex-wrap: wrap;
  }

  .project-architecture__media .media-slider__viewport {
    border-radius: 0;
  }
}

@media (max-width: 480px) {
  .project-architecture .project-feature-tabs__btn,
  .mortgage-program-tabs .project-feature-tabs__btn {
    font-size: 12px;
    padding: 10px 14px;
  }

  .project-architecture__card {
    padding: 18px 16px 20px;
  }
}

@media (min-width: 901px) {
  .project-architecture__media {
    border-radius: 0 var(--radius-md) var(--radius-md) 0;
    height: 100%;
    min-height: 0;
  }

  .project-architecture__grid {
    grid-template-rows: minmax(380px, clamp(380px, 42vw, 480px));
    min-height: 380px;
  }

  .project-architecture__visual {
    height: 100%;
    min-height: 0;
    aspect-ratio: unset;
  }

  .project-architecture__card {
    height: 100%;
    min-height: 0;
    overflow-y: auto;
    padding: clamp(16px, 2.2vw, 28px) clamp(18px, 2.4vw, 30px) clamp(14px, 2vw, 22px);
    gap: 18px;
  }

  .project-architecture__overlay-title {
    padding: clamp(18px, 3vw, 32px) clamp(18px, 3vw, 36px) 52px;
    font-size: clamp(20px, 2.2vw, 30px);
    max-width: 24ch;
  }

  .project-architecture__bottom-pag {
    padding: 12px clamp(14px, 2vw, 24px) 14px clamp(18px, 4vw, 40px);
  }

  .project-architecture__card-nav .media-slider__arrow {
    width: 40px;
    height: 40px;
  }
}

.media-slider__counter {
  position: absolute;
  left: 18px;
  bottom: 18px;
  z-index: 3;
  font-size: 12px;
  font-weight: 600;
  color: #fff;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.35);
}

.big-form-placeholder {
  height: 560px;
  border-radius: 18px;
  border: 1px solid rgba(0, 0, 0, 0.08);
  background: #fff;
}

.big-form-placeholder--embed {
  position: relative;
  overflow: hidden;
}

.form-dot {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--color-accent);
  margin: 18px auto 8px;
}

.form-dot-label {
  text-align: center;
  font-size: 12px;
  color: var(--color-text-muted);
}

.mortgage__lead {
  margin: -16px 0 18px;
  color: var(--color-text-muted);
  max-width: 720px;
}

.mortgage .container-inner {
  min-width: 0;
}

.mortgage-widget {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(0, 1fr) minmax(0, 1.35fr);
  gap: 16px;
  min-width: 0;
  background: transparent;
  border-radius: 0;
  border: none;
  box-shadow: none;
  padding: 0;
}

.mortgage--programs-top .mortgage-head-row,
.mortgage--programs-top .mortgage__lead {
  grid-column: 1 / -1;
}

.mortgage-head-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px 24px;
  flex-wrap: wrap;
  width: 100%;
}

.mortgage-head-row__title {
  margin: 0 !important;
  flex: 0 1 auto;
  min-width: 0;
}

.mortgage--programs-top .project-feature-tabs-viewport {
  /* базовый .project-feature-tabs задаёт margin: 0 auto — снимаем, чтобы блок прижался к правому краю */
  margin-left: auto;
  margin-right: 0;
  margin-bottom: 0;
  flex: 0 1 auto;
  min-width: 0;
  max-width: 100%;
}

.mortgage-program-tabs .project-feature-tabs__btn {
  font-size: 12px;
  padding: 10px 14px;
}

.mortgage--programs-top .mortgage__lead {
  margin: 0 0 8px;
}

.mortgage--programs-top .mortgage-widget {
  min-width: 0;
}

.mortgage-widget__programs--no-pills .mortgage-widget__programs-sub {
  margin-bottom: 10px;
}


@media (max-width: 900px) {
  .mortgage-head-row {
    flex-direction: column;
    align-items: stretch;
    gap: 16px;
    min-width: 0;
  }

  .mortgage-head-row__title {
    width: 100%;
    min-width: 0;
  }

  .mortgage--programs-top .project-feature-tabs-viewport {
    margin-left: 0;
    width: 100%;
    max-width: 100%;
    flex: 1 1 auto;
  }
}

/* Страница «Квартиры»: заголовок слева, табы справа — как блок ипотеки */
.apartments-page__head .project-feature-tabs-viewport {
  margin-left: auto;
  margin-right: 0;
  margin-bottom: 0;
  flex: 0 1 auto;
  min-width: 0;
  max-width: 100%;
}

@media (max-width: 900px) {
  .apartments-page__head .project-feature-tabs-viewport {
    margin-left: 0;
    width: 100%;
    flex: 1 1 auto;
  }
}

.apartments-page__head {
  margin-bottom: clamp(18px, 2.5vw, 28px);
}

.apartments-page__empty {
  margin: 0;
  max-width: 52ch;
  line-height: 1.55;
  color: var(--color-text-muted);
}

.apartments-page {
  background: var(--color-bg);
}

/* как /mortgage: контент не уезжает под fixed-шапку */
.apartments-page > .section:first-child {
  padding-top: calc(
    var(--header-sticky-offset) + env(safe-area-inset-top, 0px) + 12px
  );
}

.mortgage-widget__calc,
.mortgage-widget__summary {
  background: #f6f7fb;
  border-radius: 18px;
  padding: 18px 18px;
}

.mortgage-widget__programs {
  background: #fff;
  border-radius: 18px;
  padding: 26px 28px 24px;
  border: 1px solid rgba(0, 0, 0, 0.05);
}

.mortgage-widget__field {
  margin-bottom: 14px;
}

.mortgage-widget__label {
  font-size: 12px;
  color: var(--color-text-muted);
  margin-bottom: 8px;
}

.mortgage-widget__input {
  height: 42px;
  border-radius: 12px;
  background: #fff;
  border: 1px solid rgba(0, 0, 0, 0.06);
  display: flex;
  align-items: center;
  padding: 0 14px;
  font-weight: 600;
  color: var(--color-text);
}

.mortgage-widget__row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.mortgage-widget__percent {
  font-size: 12px;
  color: var(--color-text-muted);
  font-weight: 600;
  min-width: 42px;
  text-align: right;
}

.mortgage-widget__range {
  width: 100%;
  margin-top: 10px;
  height: 28px;
  background: transparent;
  -webkit-appearance: none;
  appearance: none;
}

.mortgage-widget__range:focus {
  outline: none;
}

.mortgage-widget__range::-webkit-slider-runnable-track {
  height: 6px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.12);
}

.mortgage-widget__range::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--color-accent);
  margin-top: -4px;
  box-shadow: 0 0 0 6px rgba(63, 80, 115, 0.14);
  cursor: grab;
}

.mortgage-widget__range:active::-webkit-slider-thumb {
  cursor: grabbing;
}

.mortgage-widget__range::-moz-range-track {
  height: 6px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.12);
}

.mortgage-widget__range::-moz-range-thumb {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--color-accent);
  border: none;
  box-shadow: 0 0 0 6px rgba(63, 80, 115, 0.14);
  cursor: grab;
}

.mortgage-widget__cta {
  width: 100%;
  justify-content: center;
  margin-top: 8px;
}

.mortgage-widget__title {
  font-weight: 700;
  font-size: 16px;
  margin-bottom: 14px;
}

.mortgage-widget__kv {
  display: grid;
  gap: 12px;
  margin-bottom: 14px;
}

.mortgage-widget__kv span {
  display: block;
  font-size: 12px;
  color: var(--color-text-muted);
  margin-bottom: 4px;
}

.mortgage-widget__kv strong {
  font-size: 18px;
  font-weight: 800;
  letter-spacing: -0.01em;
}

.mortgage-widget__payment {
  padding-top: 12px;
  border-top: 1px solid rgba(0, 0, 0, 0.06);
}

.mortgage-widget__payment span {
  display: block;
  font-size: 12px;
  color: var(--color-text-muted);
  margin-bottom: 6px;
}

.mortgage-widget__payment strong {
  font-size: 30px;
  font-weight: 900;
  letter-spacing: -0.02em;
  color: var(--color-accent);
}

.mortgage-widget__legal-note {
  margin: 14px 0 0;
  padding: 10px 12px;
  font-size: 11px;
  line-height: 1.45;
  font-weight: 500;
  color: rgba(43, 43, 43, 0.62);
  text-align: left;
  letter-spacing: 0.01em;
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.65);
}

.mortgage-widget__programs-title {
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--color-accent);
  margin-bottom: 8px;
}

.mortgage-widget__programs-panel .mortgage-widget__programs-title {
  font-size: clamp(21px, 4vw, 26px);
  font-weight: 800;
  letter-spacing: -0.025em;
  color: #1c1c1f;
  margin: 0 0 16px;
  padding-left: 16px;
  line-height: 1.25;
  border-left: 4px solid var(--color-accent);
}

.mortgage-widget__programs-sub {
  color: var(--color-text-muted);
  margin-bottom: 12px;
  font-size: 13px;
  line-height: 1.45;
}

.mortgage-widget__programs-panel .mortgage-widget__programs-sub {
  margin: 0 0 18px;
  max-width: 52ch;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.5;
  color: #5c5c66;
}

.mortgage-widget__programs-list {
  list-style: none;
  margin: 0 0 8px;
  padding: 0;
  counter-reset: mortgage-cond;
  font-size: 14px;
  line-height: 1.55;
  color: #2b2b2b;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.mortgage-widget__programs-list li {
  counter-increment: mortgage-cond;
  display: flex;
  align-items: flex-start;
  gap: 14px;
  margin: 0;
  padding: 0;
  background: none;
  border: none;
  box-shadow: none;
  border-radius: 0;
}

.mortgage-widget__programs-list li:last-child {
  margin-bottom: 0;
}

.mortgage-widget__programs-list li::before {
  content: counter(mortgage-cond);
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  height: 36px;
  border-radius: 11px;
  background: transparent;
  border: 2px solid var(--color-accent);
  color: var(--color-accent);
  font-weight: 800;
  font-size: 14px;
  line-height: 1;
}

.mortgage-widget__pills {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 8px;
}

.mortgage-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 36px;
  padding: 0 14px;
  border-radius: 10px;
  background: #fff;
  border: 1px solid rgba(0, 0, 0, 0.10);
  font-size: 12px;
  font-weight: 700;
  color: #2b2b2b;
  transition: background 0.2s, color 0.2s, border-color 0.2s;
}

.mortgage-pill.is-active {
  background: #fff;
  border-color: rgba(63, 80, 115, 0.30);
  color: var(--color-accent);
}

/* Ипотека: пилюли программ — на узких экранах столбиком, как табы на странице /mortgage */
@media (max-width: 900px) {
  .mortgage-widget__pills {
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
  }

  .mortgage-pill {
    width: 100%;
    height: auto;
    min-height: 44px;
    padding: 12px 16px;
    box-sizing: border-box;
    white-space: normal;
    text-align: center;
    line-height: 1.35;
    justify-content: center;
  }
}

@media (max-width: 767px) {
  /* не сбрасывать padding-top шорткатом — первая секция на /mortgage уйдёт под fixed-шапку */
  .mortgage.section {
    padding-bottom: 32px;
    padding-top: 28px;
  }

  .mortgage-page .mortgage.section {
    padding-top: calc(
      var(--header-sticky-offset) + env(safe-area-inset-top, 0px) + 16px
    );
  }

  .apartments-page > .section:first-child {
    padding-top: calc(
      var(--header-sticky-offset) + env(safe-area-inset-top, 0px) + 16px
    );
  }

  .mortgage:not(.mortgage--programs-top) > .container > .container-inner > .section-title {
    margin-bottom: 12px;
    font-size: clamp(24px, 6.5vw, 34px);
  }

  .mortgage__lead {
    margin: 0 0 14px;
    max-width: none;
    font-size: 14px;
    line-height: 1.5;
  }

  .mortgage--programs-top .mortgage__lead {
    margin: 0 0 10px;
  }

  .mortgage-head-row__title.section-title {
    font-size: clamp(24px, 6.5vw, 34px) !important;
  }

  .mortgage-widget {
    gap: 12px;
  }

  .mortgage-widget__calc,
  .mortgage-widget__summary {
    padding: 16px 14px;
    border-radius: 16px;
  }

  .mortgage-widget__field {
    margin-bottom: 12px;
  }

  .mortgage-widget__input {
    min-width: 0;
    font-size: 14px;
    padding: 0 12px;
  }

  .mortgage-widget__title {
    font-size: 15px;
    margin-bottom: 12px;
  }

  .mortgage-widget__kv {
    gap: 10px;
    margin-bottom: 12px;
  }

  .mortgage-widget__kv strong {
    font-size: 16px;
  }

  .mortgage-widget__payment strong {
    font-size: clamp(22px, 9vw, 28px);
  }

  .mortgage-widget__range {
    height: 36px;
    margin-top: 12px;
  }

  .mortgage-widget__range::-webkit-slider-thumb {
    width: 20px;
    height: 20px;
    margin-top: -7px;
  }

  .mortgage-widget__range::-moz-range-thumb {
    width: 20px;
    height: 20px;
  }

  .mortgage-widget__cta {
    margin-top: 6px;
    min-height: 48px;
    padding-left: 20px;
    padding-right: 20px;
  }

  .mortgage-widget__programs-panel .mortgage-widget__programs-sub {
    max-width: none;
  }
}

@media (max-width: 480px) {
  .mortgage-widget__programs {
    padding: 20px 16px 18px;
  }

  .mortgage-widget__programs-panel .mortgage-widget__programs-title {
    padding-left: 12px;
    margin-bottom: 12px;
    border-left-width: 3px;
  }

  .mortgage-widget__programs-list {
    gap: 14px;
  }

  .mortgage-widget__programs-list li {
    gap: 12px;
    font-size: 13px;
  }

  .mortgage-widget__programs-list li::before {
    min-width: 32px;
    height: 32px;
    font-size: 13px;
    border-radius: 9px;
    border-width: 2px;
  }

  .mortgage-widget__programs-panel .mortgage-widget__programs-sub {
    font-size: 13px;
    margin-bottom: 14px;
  }
}

@media (max-width: 1023px) {
  .project-about__grid {
    grid-template-columns: minmax(0, 1fr);
    width: 100%;
  }

  .project-page .project-about__grid {
    grid-template-rows: none;
    overflow: visible;
  }

  .project-page .project-about__grid > .media-slider {
    width: 100%;
    max-width: 100%;
    overflow: hidden;
    border-radius: var(--radius-md) var(--radius-md) 0 0;
  }

  .project-page .project-about__grid > .project-about__text {
    height: auto;
    overflow: visible;
    overflow-y: visible;
    justify-content: flex-start;
    width: 100%;
  }

  .project-page .project-about__text {
    padding: 20px 18px 22px;
  }

  .project-about__title {
    font-size: clamp(20px, 5.5vw, 26px);
    line-height: 1.25;
  }

  .project-about__lead {
    font-size: 14px;
    line-height: 1.55;
  }

  .project-stats__row {
    grid-template-columns: 1fr;
  }
  .mortgage-widget {
    grid-template-columns: 1fr;
    gap: 14px;
  }
}

.project-card__body {
  padding: 24px 28px 28px;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 0;
}

@media (max-width: 767px) {
  .project-card__body {
    padding: 24px 15px 28px;
  }
}

.project-card__title {
  margin: 0 0 10px;
  font-size: 22px;
  font-weight: 700;
}

.project-card__location-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 20px;
}

.project-card__address {
  margin: 0;
  font-size: 13px;
  line-height: 1.4;
  color: var(--color-text-muted);
  min-width: 0;
  flex: 1;
}

.project-card__address-sep {
  margin: 0 0.4em;
  opacity: 0.55;
  font-weight: 500;
}

.project-card__eta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  flex-shrink: 0;
  font-size: 13px;
  color: var(--color-text-muted);
}

.project-card__eta-icon {
  flex-shrink: 0;
  opacity: 0.85;
}

.project-card__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.project-card__prices {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 4px;
  min-width: 0;
}

.project-card__price {
  margin: 0;
  font-size: 18px;
  font-weight: 700;
  color: var(--color-text);
}

.project-card__price-month {
  margin: 0;
  font-size: 13px;
  font-weight: 400;
  color: var(--color-text-muted);
  line-height: 1.3;
}

/* Locations */
.locations {
  background: #fff;
}

.locations__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.locations__head .section-title {
  margin-bottom: 28px;
}

.locations__count {
  display: inline-flex;
  align-items: baseline;
  gap: 10px;
  margin-bottom: 28px;
}

.locations__grid {
  display: grid;
  grid-template-columns: 1fr 1.35fr;
  gap: 40px;
  align-items: stretch;
}

@media (max-width: 900px) {
  .locations__grid {
    grid-template-columns: 1fr;
  }
}

.locations__num {
  font-size: clamp(44px, 6vw, 72px);
  font-weight: 700;
  color: var(--color-accent);
  line-height: 1;
}

.locations__lead-text {
  font-size: 20px;
  font-weight: 600;
  color: var(--color-text);
}

.locations__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.locations__item {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 12px 16px;
  background: #fff;
  border-radius: var(--radius-md);
  box-shadow: 0 2px 16px rgba(0, 0, 0, 0.04);
  transition: box-shadow 0.2s;
}

.locations__item:hover {
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.08);
}

.locations__thumb {
  width: 88px;
  height: 88px;
  border-radius: var(--radius-sm);
  background: var(--color-placeholder) center / cover no-repeat;
  flex-shrink: 0;
}

.locations__item-text {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.locations__item-title {
  font-weight: 600;
  font-size: 17px;
}

.locations__item-address {
  font-size: 13px;
  color: var(--color-text-muted);
  margin-top: -2px;
}

.locations__item-price {
  margin-top: 6px;
  font-size: 14px;
  font-weight: 600;
  color: var(--color-text-muted);
}

.locations__map {
  min-height: 360px;
  background: #fff;
  border-radius: var(--radius-lg);
  border: none;
  overflow: hidden;
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.08);
  position: relative;
}

.locations__map-embed {
  width: 100%;
  height: 420px;
}

.locations__map-embed iframe {
  width: 100%;
  height: 100%;
  border: 0;
  filter: none;
}

.locations__map-activate {
  position: absolute;
  left: 14px;
  bottom: 14px;
  z-index: 5;
  padding: 10px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid rgba(0, 0, 0, 0.08);
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.10);
  font-size: 12px;
  font-weight: 600;
  color: #2b2b2b;
}

.locations__map.is-interactive .locations__map-activate {
  display: none;
}

@media (max-width: 900px) {
  /* On mobile, prevent the embedded map from "eating" page scroll until user activates it */
  .locations__map:not(.is-interactive) .locations__map-embed iframe {
    pointer-events: none;
  }
}

/* Comfort */
.comfort {
  background: var(--color-bg);
}

.comfort__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px 24px;
  flex-wrap: wrap;
  margin-bottom: clamp(20px, 3vw, 32px);
}

.comfort__heading {
  margin: 0 !important;
  flex: 1 1 auto;
  min-width: 0;
}

.comfort__nav {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.comfort__nav.is-hidden {
  display: none;
}

.comfort__nav-btn {
  width: 44px;
  height: 44px;
  border-radius: 999px;
  border: none;
  padding: 0;
  margin: 0;
  font: inherit;
  background: #f8f8f8;
  color: #2e2e2e;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  transition: transform 0.15s, opacity 0.2s, color 220ms ease;
  -webkit-appearance: none;
  appearance: none;
}

.comfort__nav-btn::after {
  content: "";
  position: absolute;
  inset: 0;
  background: var(--color-accent);
  border-radius: inherit;
  transform: scale(0);
  transform-origin: center;
  transition: transform 220ms ease;
  z-index: 0;
}

.comfort__nav-btn svg {
  position: relative;
  z-index: 1;
  display: block;
}

.comfort__nav-btn:hover:not(:disabled)::after {
  transform: scale(1);
}

.comfort__nav-btn:hover:not(:disabled) {
  color: #fff;
}

.comfort__nav-btn:active:not(:disabled) {
  transform: scale(0.96);
}

.comfort__nav-btn:disabled {
  opacity: 0.35;
  cursor: default;
}

.comfort__nav-btn:disabled::after {
  display: none;
}

.comfort__viewport {
  display: flex;
  gap: 32px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  padding-bottom: 4px;
}

.comfort__viewport::-webkit-scrollbar {
  display: none;
}

.comfort__viewport:focus-visible {
  outline: 2px solid rgba(63, 80, 115, 0.35);
  outline-offset: 4px;
}

.comfort__item {
  flex: 0 0 calc((100% - 64px) / 3);
  max-width: calc((100% - 64px) / 3);
  scroll-snap-align: start;
  background: #fff;
  border: 1px solid rgba(0, 0, 0, 0.06);
  border-radius: 18px;
  padding: 18px 18px 20px;
  box-sizing: border-box;
}

@media (max-width: 900px) {
  .comfort__item {
    flex: 0 0 100%;
    max-width: 100%;
  }

  .comfort__head {
    align-items: flex-start;
  }

  .comfort__nav {
    margin-top: 4px;
  }
}

.comfort__title {
  margin: 0 0 10px;
  font-size: 20px;
  font-weight: 600;
}

.comfort__placeholder {
  width: 100%;
  aspect-ratio: 4 / 3;
  background: var(--color-placeholder);
  border-radius: 16px;
  margin-bottom: 14px;
  background-position: center;
  background-size: cover;
  background-repeat: no-repeat;
}

.comfort__text {
  margin: 0;
  font-size: 14px;
  color: var(--color-text-muted);
}

/* About (главная) */
.about.about-showcase {
  background: #fff;
  padding-top: clamp(48px, 8vw, 88px);
  padding-bottom: clamp(48px, 8vw, 96px);
}

.about-showcase__inner {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.about-showcase__top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: clamp(20px, 4vw, 40px);
  margin-bottom: clamp(20px, 3vw, 28px);
}

/* Минимальный зазор до лида «ведущий застройщик…»; без лида — отступ до мозаики */
.about-showcase__top:has(+ .about-showcase__sublead) {
  margin-bottom: clamp(2px, 0.5vw, 6px);
}

.about-showcase__title {
  margin: 0;
  flex: 1 1 auto;
  min-width: 0;
  max-width: min(760px, 100%);
  font-size: clamp(24px, 3.1vw, 36px);
  font-weight: 500;
  line-height: 1.28;
  letter-spacing: -0.025em;
  color: var(--color-text);
}

.about-showcase__top .about-showcase__pill {
  flex-shrink: 0;
  align-self: flex-start;
  margin-top: 2px;
}

.about-showcase__title strong {
  font-weight: 800;
}

.about-showcase__sublead {
  margin: 0 0 clamp(22px, 3vw, 32px);
  padding-top: 0;
  font-size: clamp(14px, 1.75vw, 16px);
  line-height: 1.55;
  color: var(--color-text-muted);
  max-width: 920px;
  font-weight: 400;
}

.about-showcase__sublead-accent {
  color: var(--color-accent);
  font-weight: 600;
}

.about-showcase__sublead-text {
  color: inherit;
}

.about-showcase__mosaic {
  margin-bottom: clamp(28px, 4vw, 48px);
}

.about-showcase__pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 13px 26px;
  border-radius: 999px;
  border: 1px solid var(--color-accent);
  background: transparent;
  color: var(--color-accent);
  font-size: 14px;
  font-weight: 600;
  line-height: 1.2;
  text-decoration: none;
  white-space: nowrap;
  transition:
    background 0.2s,
    color 0.2s,
    border-color 0.2s,
    transform 0.15s;
}

.about-showcase__pill:hover {
  background: rgba(63, 80, 115, 0.06);
  color: var(--color-accent-hover);
  border-color: var(--color-accent-hover);
}

.about-showcase__pill:active {
  transform: scale(0.98);
}

@media (max-width: 900px) {
  .about-showcase__top {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    margin-bottom: clamp(18px, 3vw, 24px);
  }

  .about-showcase__top:has(+ .about-showcase__sublead) {
    margin-bottom: 0;
  }

  .about-showcase__top:has(+ .about-showcase__sublead) + .about-showcase__sublead {
    margin-top: clamp(8px, 2vw, 12px);
  }

  .about-showcase__top .about-showcase__pill {
    display: none;
  }
}

/* Footer */
.footer {
  background: var(--color-bg-dark);
  color: rgba(255, 255, 255, 0.88);
  padding: 56px 0 36px;
  border-top: none;
}

.footer .footer__nav {
  border-bottom-color: rgba(255, 255, 255, 0.12);
}

.footer .footer__nav a {
  color: rgba(255, 255, 255, 0.82);
}

.footer .footer__nav a:hover {
  color: var(--color-gold);
}

.footer .footer__copyright,
.footer .footer__requisites {
  color: rgba(255, 255, 255, 0.55);
}

.footer .footer__policy {
  color: rgba(255, 255, 255, 0.55);
}

.footer .footer__policy:hover {
  color: var(--color-gold);
}

.footer .footer__contact-label {
  color: rgba(255, 255, 255, 0.5);
}

.footer .footer__contact-value {
  color: rgba(255, 255, 255, 0.92);
}

.footer .footer__contact-value--link:hover {
  color: var(--color-gold);
}

.footer .footer__contact-icon {
  color: var(--color-gold);
}

.footer .social-link {
  background: rgba(255, 255, 255, 0.08);
  color: rgba(255, 255, 255, 0.7);
}

.footer .social-link:hover {
  background: var(--color-gold);
  color: var(--color-bg-dark);
}

/* About company page */
.about-page {
  background: var(--color-bg);
}

.about-hero {
  /* header is fixed */
  padding-top: calc(var(--header-sticky-offset) + 28px);
}

.about-hero__title {
  margin: 0 0 10px;
  font-size: clamp(32px, 4vw, 44px);
  font-weight: 900;
  letter-spacing: -0.02em;
}

.about-hero__lead {
  margin: 0 0 22px;
  color: var(--color-text-muted);
  max-width: 760px;
  line-height: 1.6;
  font-size: 16px;
}

.about-hero__accent {
  color: var(--color-accent);
  font-weight: 800;
  margin-right: 6px;
}

.about-top {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 16px;
  align-items: stretch;
}

@media (max-width: 900px) {
  .about-top {
    grid-template-columns: 1fr;
  }
}

.about-highlight {
  position: relative;
  border-radius: 22px;
  background: var(--color-accent);
  color: #fff;
  overflow: hidden;
  min-height: 320px;
  padding: 36px 38px;
  box-shadow: 0 18px 55px rgba(42, 53, 73, 0.28);
}

.about-highlight__stripes {
  position: absolute;
  inset: 0;
  /* transparent diagonal stripes across full height */
  background: repeating-linear-gradient(
    135deg,
    rgba(255, 255, 255, 0.26) 0px,
    rgba(255, 255, 255, 0.26) 10px,
    rgba(255, 255, 255, 0.06) 10px,
    rgba(255, 255, 255, 0.06) 28px
  );
  opacity: 0.22;
  background-size: 140px 140px;
  animation: about-stripes 9s linear infinite;
  pointer-events: none;
  z-index: 0;
  mix-blend-mode: soft-light;
}

.about-highlight__icon {
  width: 62px;
  height: 62px;
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.16);
  display: grid;
  place-items: center;
  margin-bottom: 20px;
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.10);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  transform: rotate(-8deg);
  animation: about-star-float 2.8s ease-in-out infinite;
}

.about-highlight__icon svg {
  opacity: 0.95;
}

.about-highlight__value {
  font-size: clamp(40px, 5.4vw, 60px);
  font-weight: 900;
  letter-spacing: -0.03em;
  margin-bottom: 10px;
  position: relative;
  z-index: 1;
}

.about-highlight__text {
  font-size: 17px;
  opacity: 0.95;
  max-width: 520px;
  position: relative;
  z-index: 1;
}

.about-highlight__content.is-switching {
  opacity: 0;
  transform: translateY(8px);
}

.about-highlight__content {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  gap: 0;
  transition: opacity 260ms ease, transform 260ms ease;
  will-change: opacity, transform;
}

.about-typed {
  display: block;
  width: 100%;
}

.about-typed > span {
  display: inline-block;
  opacity: 0;
  transform: translateY(6px);
  animation: about-letter-in 420ms ease forwards;
}

@keyframes about-letter-in {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.about-top__stats {
  display: grid;
  grid-template-rows: 1fr 1fr;
  gap: 14px;
}

.about-stat-card {
  background: #fff;
  border: 1px solid rgba(0, 0, 0, 0.06);
  border-radius: 18px;
  padding: 24px 24px;
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.06);
  min-height: 153px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.about-stat-card__value {
  font-weight: 900;
  letter-spacing: -0.02em;
  margin-bottom: 6px;
  color: var(--color-text);
  display: flex;
  gap: 6px;
  align-items: baseline;
}

.about-stat-card__value-main {
  font-size: 46px;
  line-height: 1;
}

.about-stat-card__value-accent {
  font-size: 46px;
  font-weight: 800;
}

.about-stat-card__label {
  color: var(--color-text-muted);
  font-size: 13px;
  line-height: 1.45;
}

.about-history__grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 64px;
  align-items: center;
}

@media (max-width: 900px) {
  .about-history__grid {
    grid-template-columns: 1fr;
  }
}

.about-history__kicker {
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 11px;
  font-weight: 800;
  color: rgba(0, 0, 0, 0.45);
  margin-bottom: 10px;
}

.about-history__title {
  margin: 0 0 14px;
  font-size: clamp(28px, 4vw, 40px);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.about-history__value {
  margin-right: 8px;
}

.about-history__body {
  margin: 0;
  color: var(--color-text-muted);
  max-width: 720px;
  line-height: 1.6;
  font-size: 16px;
}

.about-history__extended {
  margin-top: 16px;
  max-width: 720px;
  color: var(--color-text-muted);
  font-size: 16px;
  line-height: 1.6;
}

.about-history__extended p {
  margin: 0 0 14px;
}

.about-history__extended p:last-child {
  margin-bottom: 0;
}

.about-history__media img,
.about-history__placeholder {
  width: 100%;
  border-radius: 18px;
  background: var(--color-placeholder);
  aspect-ratio: 4 / 3;
  object-fit: cover;
  box-shadow: 0 16px 44px rgba(0, 0, 0, 0.10);
}

/* «О компании»: два блока истории — как блоки «О ЖК» на странице проекта */
.about-page .about-history__grid {
  gap: 0;
  align-items: stretch;
  background: #f6f7fb;
  border-radius: var(--radius-md);
  overflow: hidden;
}

.about-page .about-history__grid > * {
  min-height: 0;
}

.about-page .about-history__text {
  background: transparent;
  border-radius: 0;
  padding: clamp(22px, 3vw, 40px) clamp(26px, 3.2vw, 44px);
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
}

.about-page .about-history__media {
  min-height: 0;
  align-self: stretch;
  display: flex;
  flex-direction: column;
}

@media (min-width: 1024px) {
  .about-page .about-history__grid {
    grid-template-rows: minmax(380px, clamp(380px, 42vw, 480px));
    min-height: 380px;
  }

  .about-page .about-history__grid > .about-history__text {
    height: 100%;
    overflow-y: auto;
    justify-content: center;
  }

  .about-page .about-history__media img,
  .about-page .about-history__media .about-history__placeholder {
    flex: 1 1 auto;
    width: 100%;
    min-height: 0;
    height: 100%;
    aspect-ratio: unset;
    border-radius: 18px;
    box-shadow: none;
    object-fit: cover;
  }
}

@media (max-width: 1023px) {
  .about-page .about-history__grid {
    grid-template-columns: 1fr;
    grid-template-rows: none;
  }

  .about-page .about-history__grid > .about-history__text {
    height: auto;
    overflow-y: visible;
    justify-content: flex-start;
    padding: 20px 18px 22px;
  }

  .about-page .about-history__media img,
  .about-page .about-history__media .about-history__placeholder {
    aspect-ratio: 16 / 11;
    min-height: 300px;
    height: auto;
    flex: 0 0 auto;
    border-radius: 18px;
    box-shadow: none;
    object-fit: cover;
  }
}

@keyframes about-stripes {
  0% { background-position: 0 0; }
  100% { background-position: 220px 0; }
}

@keyframes about-star-float {
  0%, 100% { transform: translateY(0) rotate(-8deg); }
  50% { transform: translateY(-6px) rotate(-8deg); }
}

.footer__top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px 32px;
  flex-wrap: wrap;
  margin-bottom: 32px;
}

.footer__top-left {
  display: flex;
  align-items: center;
  gap: 20px 24px;
  flex-wrap: wrap;
  min-width: 0;
}

.footer__contact-card {
  margin-left: auto;
  align-self: flex-start;
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: flex-end;
  gap: 28px 40px;
  padding: 0;
  max-width: 100%;
  box-sizing: border-box;
}

.footer__contact-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  flex: 0 1 auto;
  min-width: min(200px, 100%);
}

@media (min-width: 641px) {
  .footer__contact-card {
    flex-wrap: nowrap;
    justify-content: space-between;
    gap: 40px;
  }

  .footer__contact-item {
    flex: 0 0 auto;
    min-width: 0;
  }

  /* Give the address/sales office line more room */
  .footer__contact-item:last-child {
    flex: 1 1 auto;
    justify-content: flex-end;
  }
}

@media (min-width: 901px) {
  .footer__contact-item:last-child .footer__contact-value {
    white-space: nowrap;
  }
}

.footer__contact-icon {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  color: var(--color-accent);
  margin-top: 2px;
}

.footer__contact-icon-svg {
  display: block;
}

.footer__contact-body {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.footer__contact-label {
  font-size: 11px;
  font-weight: 500;
  line-height: 1.35;
  color: rgba(43, 43, 43, 0.55);
  letter-spacing: 0.01em;
}

.footer__contact-value {
  font-size: 14px;
  font-weight: 700;
  line-height: 1.35;
  color: #2b2b2b;
  letter-spacing: -0.01em;
}

.footer__contact-value--link {
  text-decoration: none;
  color: inherit;
  transition: color 0.2s;
}

.footer__contact-value--link:hover {
  color: var(--color-accent);
}

@media (max-width: 640px) {
  .footer__top {
    flex-direction: column;
    align-items: stretch;
  }

  .footer__contact-card {
    margin-left: 0;
    width: 100%;
    max-width: none;
    justify-content: flex-start;
    gap: 24px 32px;
  }
}

.footer__social {
  display: flex;
  gap: 12px;
}

.social-link {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-btn);
  background: var(--color-bg-soft);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 700;
  color: var(--color-text-muted);
  transition: background 0.2s, color 0.2s;
}

.social-link:hover {
  background: var(--color-accent);
  color: #fff;
}

.footer__nav {
  display: flex;
  flex-wrap: wrap;
  gap: 20px 28px;
  padding-bottom: 28px;
  border-bottom: 1px solid var(--color-border);
  margin-bottom: 24px;
}

.footer__nav a {
  font-size: 14px;
  font-weight: 500;
  color: var(--color-text);
}

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

.footer__bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px 24px;
}

.footer__bottom-meta {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
  max-width: min(720px, 100%);
}

.footer__bottom p,
.footer__copyright {
  margin: 0;
  font-size: 12px;
  color: var(--color-text-muted);
  line-height: 1.6;
}

.footer__requisites {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 16px;
  margin: 0;
  font-size: 12px;
  color: var(--color-text-muted);
  line-height: 1.5;
}

.footer__legal-links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px 20px;
}

.footer__policy {
  font-size: 12px;
  font-weight: 600;
  color: var(--color-text);
  text-decoration: underline;
  text-underline-offset: 3px;
  white-space: nowrap;
}

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

/* Legal / privacy policy page */
.legal-page {
  background: var(--color-bg);
}

.legal-main {
  padding-top: calc(var(--header-sticky-offset) + 28px);
  padding-bottom: 48px;
}

.legal-prose {
  max-width: 920px;
}

.legal-prose__title {
  margin: 0 0 8px;
  font-size: clamp(28px, 3.6vw, 40px);
  font-weight: 900;
  letter-spacing: -0.02em;
  line-height: 1.15;
}

.legal-prose__subtitle {
  margin: 0 0 28px;
  font-size: 18px;
  font-weight: 600;
  color: var(--color-text-muted);
  line-height: 1.45;
}

.legal-prose h2 {
  margin: 36px 0 14px;
  font-size: 18px;
  font-weight: 800;
  letter-spacing: -0.01em;
}

.legal-prose h2:first-of-type {
  margin-top: 0;
}

.legal-prose p,
.legal-prose li {
  margin: 0 0 12px;
  font-size: 16px;
  line-height: 1.65;
  color: var(--color-text);
}

.legal-prose ul {
  margin: 0 0 16px;
  padding-left: 1.25em;
}

.legal-prose li {
  margin-bottom: 8px;
}

.legal-prose a {
  color: var(--color-accent);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.legal-prose a:hover {
  text-decoration: none;
}

.legal-table-wrap {
  overflow-x: auto;
  margin: 8px 0 24px;
  border-radius: 12px;
  border: 1px solid var(--color-border);
  background: #fff;
}

.legal-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 640px;
  font-size: 15px;
}

.legal-table th,
.legal-table td {
  padding: 12px 14px;
  vertical-align: top;
  text-align: left;
  border-bottom: 1px solid var(--color-border);
}

.legal-table th {
  font-weight: 700;
  background: var(--color-bg-soft);
  font-size: 14px;
}

.legal-table tr:last-child td {
  border-bottom: none;
}

.legal-table ul {
  margin: 0;
  padding-left: 1.1em;
}

.legal-table li {
  margin-bottom: 6px;
  font-size: 14px;
}

/* Contacts page */
.contacts-page {
  background: var(--color-bg-soft);
}

.contacts-page .contacts {
  padding-top: calc(var(--header-sticky-offset) + 12px);
  padding-bottom: 48px;
}

.contacts-page .contacts .section-title {
  margin-bottom: 32px;
}

.contacts__grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.12fr);
  gap: 40px 56px;
  align-items: stretch;
}

@media (max-width: 900px) {
  .contacts__grid {
    grid-template-columns: 1fr;
    gap: 32px;
    align-items: start;
  }
}

.contacts__phone {
  display: inline-block;
  font-size: clamp(26px, 4.5vw, 40px);
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--color-accent);
  text-decoration: none;
  line-height: 1.15;
  transition: opacity 0.2s, color 0.2s;
}

.contacts__phone:hover {
  color: var(--color-accent-hover);
  opacity: 0.92;
}

.contacts__phone-note {
  margin: 10px 0 0;
  font-size: 15px;
  color: var(--color-text-muted);
}

.contacts__card {
  margin-top: 28px;
  padding: 0;
  overflow: hidden;
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  box-shadow:
    0 1px 0 rgba(255, 255, 255, 0.9) inset,
    0 18px 50px rgba(0, 0, 0, 0.06);
}

.contacts__card::before {
  content: "";
  display: block;
  height: 3px;
  background: linear-gradient(90deg, var(--color-accent) 0%, rgba(63, 80, 115, 0.35) 55%, transparent 100%);
}

.contacts__card-head {
  padding: 20px 24px 18px;
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

.contacts__card-title {
  margin: 0;
  font-size: clamp(18px, 2.2vw, 22px);
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.contacts__card-lead {
  margin: 8px 0 0;
  font-size: 14px;
  line-height: 1.45;
  color: var(--color-text-muted);
}

.contacts__address-block {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  padding: 22px 24px 20px;
}

.contacts__icon-ring {
  flex: 0 0 auto;
  width: 48px;
  height: 48px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-accent);
  background: rgba(63, 80, 115, 0.08);
  border: 1px solid rgba(63, 80, 115, 0.12);
}

.contacts__address-body {
  min-width: 0;
  padding-top: 2px;
}

.contacts__eyebrow {
  display: block;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-text-muted);
}

.contacts__address-text {
  margin: 8px 0 0;
  font-size: 17px;
  font-weight: 600;
  line-height: 1.4;
  letter-spacing: -0.01em;
  color: var(--color-text);
}

.contacts__schedule {
  padding: 18px 20px 22px;
  background: var(--color-bg-soft);
  border-top: 1px solid var(--color-border);
}

.contacts__schedule-title {
  margin: 0 0 14px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--color-text-muted);
}

.contacts__schedule-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.contacts__schedule-row {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 12px 16px;
  margin: 0;
  padding: 14px 16px;
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.03);
}

.contacts__schedule-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-accent);
  opacity: 0.95;
}

.contacts__schedule-days {
  font-size: 15px;
  font-weight: 600;
  color: var(--color-text);
  letter-spacing: -0.01em;
}

.contacts__schedule-time {
  font-size: 15px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: var(--color-accent);
  white-space: nowrap;
}

@media (max-width: 480px) {
  .contacts__schedule-row {
    grid-template-columns: auto 1fr;
    grid-template-rows: auto auto;
    gap: 4px 12px;
  }

  .contacts__schedule-icon {
    grid-row: 1 / span 2;
    align-self: start;
    margin-top: 2px;
  }

  .contacts__schedule-days {
    grid-column: 2;
    grid-row: 1;
  }

  .contacts__schedule-time {
    grid-column: 2;
    grid-row: 2;
    justify-self: start;
    font-size: 14px;
  }
}

.contact-map {
  min-width: 0;
  min-height: 0;
  display: flex;
  flex-direction: column;
}

.map-wrap {
  position: relative;
  flex: 1 1 auto;
  min-height: 320px;
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid var(--color-border);
  background: var(--color-placeholder);
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.05);
}

@media (max-width: 900px) {
  .contact-map {
    width: 100%;
  }

  .map-wrap {
    flex: 0 0 auto;
    min-height: min(420px, 70vh);
  }
}

.map-wrap iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

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

.map-wrap__seo-link {
  position: absolute;
  left: 0;
  top: 0;
}

/* Баннер cookie */
.cookie-banner {
  position: fixed;
  z-index: 240;
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.35s ease, visibility 0.35s ease, transform 0.35s ease;
}

.cookie-banner.is-visible {
  pointer-events: auto;
  opacity: 1;
  visibility: visible;
}

.cookie-banner[hidden]:not(.is-visible) {
  display: none !important;
}

.cookie-banner__panel {
  box-sizing: border-box;
  background: #fff;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.12), 0 2px 8px rgba(0, 0, 0, 0.06);
  padding: 18px 20px;
  max-width: min(420px, calc(100vw - 32px));
}

.cookie-banner__text {
  margin: 0 0 14px;
  font-size: 13px;
  line-height: 1.55;
  color: var(--color-text-muted);
  text-align: left;
}

.cookie-banner__text strong {
  color: var(--color-text);
  font-weight: 600;
}

.cookie-banner__text a {
  color: var(--color-accent);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.cookie-banner__text a:hover {
  color: var(--color-accent-hover);
}

.cookie-banner__actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 10px;
}

.cookie-banner__btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 0 18px;
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  border-radius: 12px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s, color 0.2s;
  white-space: nowrap;
}

.cookie-banner__btn--primary {
  background: var(--color-accent);
  border-color: var(--color-accent);
  color: #fff;
}

.cookie-banner__btn--primary:hover {
  background: var(--color-accent-hover);
  border-color: var(--color-accent-hover);
}

.cookie-banner__btn--ghost {
  background: transparent;
  border-color: var(--color-border);
  color: var(--color-text);
}

.cookie-banner__btn--ghost:hover {
  border-color: rgba(0, 0, 0, 0.2);
  background: rgba(0, 0, 0, 0.04);
}

/* Десктоп: левый нижний угол */
@media (min-width: 901px) {
  .cookie-banner {
    left: 24px;
    bottom: 24px;
    right: auto;
    transform: translateY(12px);
  }

  .cookie-banner.is-visible {
    transform: translateY(0);
  }
}

/* Мобильные: компактная полоса снизу */
@media (max-width: 900px) {
  .cookie-banner {
    left: 0;
    right: 0;
    bottom: 0;
    padding: 0 12px calc(12px + env(safe-area-inset-bottom, 0px));
    transform: translateY(100%);
  }

  .cookie-banner.is-visible {
    transform: translateY(0);
  }

  .cookie-banner__panel {
    width: 100%;
    max-width: none;
    border-radius: var(--radius-md) var(--radius-md) 0 0;
    padding: 14px 16px 16px;
    box-shadow: 0 -8px 32px rgba(0, 0, 0, 0.1);
  }

  .cookie-banner__text {
    margin-bottom: 12px;
    font-size: 12px;
    line-height: 1.45;
  }

  .cookie-banner__actions {
    gap: 8px;
  }

  .cookie-banner__btn {
    flex: 1 1 auto;
    min-height: 38px;
    padding: 0 14px;
    font-size: 12px;
  }

  .cookie-banner__btn--ghost {
    flex: 1 1 auto;
    min-width: 0;
    white-space: normal;
    line-height: 1.25;
    padding-top: 8px;
    padding-bottom: 8px;
  }
}
