:root {
  --brick: #C3322A;        /* красный с балконов */
  --brick-d: #9E2820;
  --blue: #4C5A68;         /* серый цоколь корпусов */
  --blue-d: #36414C;
  --sand: #F0E9E7;
  --sky: #E8EAED;
  --ink: #1F2328;
  --text2: #4A4F55;
  --text3: #3A3F45;
  --muted: #6E7378;
  --muted2: #8C9196;
  --line: #E4E0DA;
  --line2: #D8D4CD;
  --soft: #F5F3F0;
  --dark: #2B3139;
  --on-dark: #F2F1EE;
  --on-dark2: #CDD3D9;
  --on-dark3: #C6CDD4;
  --err: #B5452F;
  --off: #BDB9B3;
  --pad: clamp(14px, 2vw, 28px);
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: #FFFFFF; color: var(--ink); font-family: Manrope, system-ui, sans-serif; -webkit-font-smoothing: antialiased; }
a { color: inherit; text-decoration: none; }
a:hover { color: var(--brick); }
img { display: block; }
input::placeholder { color: var(--muted2); }
.is-hidden { display: none !important; }
.shell { max-width: 1440px; margin: 0 auto; background: #FFFFFF; overflow-x: clip; }
h1, h2, h3 { font-family: Jost, sans-serif; font-weight: 300; margin: 0; }
h2 { font-size: clamp(28px, 3.2vw, 46px); line-height: 1.1; }
p { margin: 0; }
section { padding: clamp(52px, 6.5vw, 108px) var(--pad) 0; }
.eyebrow { display: block; font-size: 11px; letter-spacing: .2em; text-transform: uppercase; color: var(--brick); margin-bottom: 18px; }
.label { font-size: 11px; letter-spacing: .2em; text-transform: uppercase; color: var(--muted); }

/* Кнопки */
.btn { display: inline-flex; align-items: center; justify-content: center; font: inherit; font-size: 12px; letter-spacing: .12em; text-transform: uppercase; padding: 17px 32px; border: 0; cursor: pointer; white-space: nowrap; }
.btn-main { background: var(--brick); color: #FFFFFF; }
.btn-main:hover { background: var(--brick-d); color: #FFFFFF; }
.btn-out { background: #FFFFFF; color: var(--brick); border: 1px solid var(--brick); }
.btn-out:hover { background: var(--soft); color: var(--brick-d); }
.btn-light { background: var(--on-dark); color: var(--dark); }
.btn-ghost { background: transparent; color: var(--on-dark); border: 1px solid rgba(242,241,238,.5); }
.btn-ghost:hover { background: var(--on-dark); color: var(--dark); }
.btn.is-off { background: var(--off); cursor: not-allowed; }

/* Шапка */
.site-header { position: sticky; top: 0; z-index: 60; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px 20px; padding: 14px clamp(14px, 3vw, 44px); background: rgba(255,255,255,.96); backdrop-filter: blur(14px); border-bottom: 1px solid var(--line); }
.logo-row { display: flex; align-items: center; gap: 14px; }
.logo { font-family: Jost, sans-serif; font-weight: 400; font-size: clamp(17px, 1.4vw, 21px); letter-spacing: .14em; text-transform: uppercase; white-space: nowrap; }
.badge-out { padding: 5px 11px; border: 1px solid var(--brick); color: var(--brick); font-size: 10px; letter-spacing: .16em; text-transform: uppercase; white-space: nowrap; }
.main-nav { display: flex; flex-wrap: wrap; flex: 1 1 auto; gap: 10px clamp(10px, 1.4vw, 24px); font-size: 14px; color: var(--text2); }
.header-right { display: flex; align-items: center; gap: 16px; }
.header-phone { text-align: right; line-height: 1.3; }
.header-phone a { display: block; font-size: 16px; white-space: nowrap; }
.header-phone span { font-size: 11px; color: var(--muted2); }
.btn-call { display: inline-flex; align-items: center; padding: 13px 22px; background: var(--brick); color: #FFFFFF; font: inherit; font-size: 12px; letter-spacing: .1em; text-transform: uppercase; white-space: nowrap; border: 0; cursor: pointer; }
.btn-call:hover { background: var(--brick-d); color: #FFFFFF; }
.call-icon, .burger { display: none; width: 44px; height: 44px; align-items: center; justify-content: center; border: 0; background: transparent; cursor: pointer; padding: 0; }
.call-icon { background: var(--brick); color: #FFFFFF; }
.burger span { display: grid; gap: 5px; width: 24px; }
.burger i { display: block; height: 2px; width: 24px; background: var(--ink); }
.icon-btn { width: 44px; height: 44px; background: transparent; border: 0; font-size: 28px; line-height: 1; cursor: pointer; color: var(--ink); }

/* Мобильное меню */
.drawer { position: fixed; inset: 0; z-index: 99; background: #FFFFFF; display: flex; flex-direction: column; overflow-y: auto; }
.drawer-head { display: flex; justify-content: space-between; align-items: center; padding: 16px 14px; border-bottom: 1px solid var(--line); }
.drawer-head span { font-family: Jost, sans-serif; font-size: 17px; letter-spacing: .14em; text-transform: uppercase; }
.drawer nav { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 32px 24px; font-size: 20px; }
.drawer nav a { padding: 10px 16px; }
.drawer-foot { display: flex; flex-direction: column; align-items: center; gap: 14px; padding: 0 24px 40px; }
.drawer-foot hr { width: 100%; max-width: 320px; height: 1px; background: var(--line); border: 0; margin: 0 0 10px; }
.drawer-foot .phone-lg { font-family: Jost, sans-serif; font-size: 22px; }
.drawer-foot .hours { font-size: 12px; color: var(--muted2); margin-top: -6px; }
.drawer-foot .btn { width: 100%; max-width: 320px; }

/* Первый экран */
.hero { padding: var(--pad) var(--pad) 0; }
.hero-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr)); min-height: min(76vh, 720px); }
.hero-text { display: flex; flex-direction: column; justify-content: center; gap: 26px; padding: clamp(30px, 4vw, 68px) clamp(22px, 3.6vw, 60px); background: var(--sand); }
.hero-badges { display: flex; flex-wrap: wrap; gap: 8px; }
.badge-line { padding: 7px 13px; border: 1px solid var(--brick); color: var(--brick); font-size: 11px; letter-spacing: .14em; text-transform: uppercase; white-space: nowrap; }
.badge-fill { padding: 7px 13px; background: var(--sky); color: var(--blue-d); font-size: 11px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; white-space: nowrap; }
.hero h1 { font-size: clamp(30px, 3.6vw, 54px); line-height: 1.08; max-width: 18ch; text-wrap: balance; }
.hero-lead { max-width: 46ch; font-size: 17px; font-weight: 300; line-height: 1.7; color: var(--text2); text-wrap: pretty; }
.hero-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 24px; }
.hero-note { font-size: 14px; color: var(--muted); }
.hero-img { position: relative; min-height: 380px; overflow: hidden; background: var(--sky); }
.hero-img img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }

/* Акция */
.promo-section { padding: var(--pad) var(--pad) 0; }
.promo { background: var(--dark); color: var(--on-dark); display: grid; grid-template-columns: minmax(0, 1fr) auto auto; grid-template-areas: 'text timer btn'; align-items: center; gap: 20px clamp(20px, 3.5vw, 56px); padding: clamp(22px, 2.6vw, 34px) clamp(22px, 3.6vw, 60px); }
.promo-text { grid-area: text; display: flex; flex-direction: column; gap: 8px; }
.promo-kicker { font-size: 11px; letter-spacing: .2em; text-transform: uppercase; color: var(--on-dark3); }
.promo-title { font-family: Jost, sans-serif; font-weight: 300; font-size: clamp(22px, 2.2vw, 32px); line-height: 1.15; }
.promo-timer { grid-area: timer; display: flex; align-items: flex-start; gap: clamp(10px, 1.2vw, 18px); justify-self: center; }
.cd-unit { display: flex; flex-direction: column; align-items: center; gap: 6px; }
.cd-num { font-family: Jost, sans-serif; font-weight: 300; font-size: clamp(32px, 3.2vw, 46px); line-height: 1; font-variant-numeric: tabular-nums; }
.cd-num.sec { color: var(--on-dark3); }
.cd-lab { font-size: 10px; letter-spacing: .18em; text-transform: uppercase; color: var(--on-dark2); }
.cd-sep { font-family: Jost, sans-serif; font-weight: 300; font-size: clamp(26px, 2.6vw, 38px); line-height: 1; color: var(--on-dark3); }
.promo .btn { grid-area: btn; justify-self: end; }

/* Цифры */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 190px), 1fr)); gap: 1px; padding: clamp(26px, 3.6vw, 56px) var(--pad); }
.stat { padding: clamp(18px, 2.2vw, 30px) clamp(16px, 2vw, 26px); border-left: 1px solid var(--brick); }
.stat-v { font-family: Jost, sans-serif; font-weight: 300; font-size: clamp(26px, 2.6vw, 40px); line-height: 1; margin-bottom: 10px; }
.stat-l { font-size: 13px; line-height: 1.6; color: var(--muted); }

/* Секции */
.sec-head { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr)); gap: clamp(28px, 4.5vw, 88px); padding: 0 clamp(8px, 2vw, 36px); align-items: end; margin-bottom: clamp(28px, 3.6vw, 48px); }
.sec-head h2 { max-width: 18ch; text-wrap: balance; }
.sec-text { display: flex; flex-direction: column; gap: 14px; font-size: 16px; font-weight: 300; line-height: 1.75; color: var(--text2); max-width: 56ch; }
.photos { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr)); gap: clamp(8px, 1vw, 14px); }
.photos figure { margin: 0; display: flex; flex-direction: column; gap: 10px; }
.ph { overflow: hidden; background: var(--line); aspect-ratio: 4/3; }
.ph img { width: 100%; height: 100%; object-fit: cover; transition: transform 1.2s cubic-bezier(.22,1,.36,1); }
.ph img:hover { transform: scale(1.04); }
.photos figcaption { font-size: 13px; color: var(--muted); }

.split { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr)); background: var(--soft); }
.split-img { position: relative; min-height: 420px; overflow: hidden; background: var(--sky); }
.split-img img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.split-text { padding: clamp(30px, 4vw, 68px) clamp(22px, 3.6vw, 60px); display: flex; flex-direction: column; justify-content: center; gap: 20px; }
.split-text h2 { max-width: 16ch; text-wrap: balance; }
.split-text p { font-size: 16px; font-weight: 300; line-height: 1.75; color: var(--text2); max-width: 48ch; }

/* Каталог */
.flats-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 20px; padding: 0 clamp(8px, 2vw, 36px); margin-bottom: clamp(24px, 3vw, 40px); }
.filters { display: flex; flex-wrap: wrap; gap: 8px; }
.filters button { cursor: pointer; font: inherit; font-size: 12px; letter-spacing: .1em; text-transform: uppercase; padding: 0 18px; min-height: 44px; border: 1px solid var(--line2); background: #FFFFFF; color: var(--text2); }
.filters button.is-active { background: var(--brick); border-color: var(--brick); color: #FFFFFF; }
.cat-note { padding: 14px clamp(16px, 2vw, 26px); margin-bottom: 16px; background: var(--sky); color: var(--blue-d); font-size: 13px; line-height: 1.6; }
.flats-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.card { background: #FFFFFF; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); padding: clamp(18px, 1.8vw, 28px); display: flex; flex-direction: column; gap: 18px; }
.card-badge { align-self: flex-start; padding: 6px 11px; background: var(--sky); color: var(--blue-d); font-size: 10px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; white-space: nowrap; }
.card-top { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.card-title { font-family: Jost, sans-serif; font-weight: 400; font-size: 20px; }
.card-floor { font-size: 13px; color: var(--muted); white-space: nowrap; }
.card-fin { margin-top: -10px; font-size: 13px; color: var(--muted); }
.card-plan { position: relative; aspect-ratio: 1/1; background: var(--soft); display: grid; place-items: center; }
.card-plan span { font-size: 12px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted2); }
.card-plan img { position: absolute; inset: 10px; width: calc(100% - 20px); height: calc(100% - 20px); object-fit: contain; }
.floor-rows { display: flex; flex-direction: column; border-top: 1px solid var(--line); }
.floor-head, .floor-row { display: grid; grid-template-columns: 1fr 1fr 1.5fr; gap: 8px; align-items: center; }
.floor-head { padding: 10px 6px 6px; font-size: 10px; letter-spacing: .14em; text-transform: uppercase; color: var(--muted2); }
.floor-head span:last-child { text-align: right; }
.floor-row { font: inherit; text-align: left; background: transparent; border: 0; border-bottom: 1px solid var(--line); padding: 11px 6px; cursor: pointer; }
.floor-row:last-child { border-bottom: 0; }
.floor-row:hover { background: var(--soft); }
.floor-row b { font-weight: 500; font-size: 14px; color: var(--ink); }
.floor-row span { font-size: 13px; color: var(--muted); }
.floor-row em { font-style: normal; font-family: Jost, sans-serif; font-size: 17px; color: var(--ink); text-align: right; white-space: nowrap; display: flex; flex-direction: column; align-items: flex-end; line-height: 1.15; }
.floor-row em s { margin-bottom: 2px; font-family: Manrope, system-ui, sans-serif; font-size: 12px; font-weight: 400; color: var(--muted2); }
.more-row { display: flex; justify-content: center; margin-top: 22px; }

/* Расположение */
.location-text { padding: clamp(30px, 4vw, 68px) clamp(22px, 3.6vw, 60px); display: flex; flex-direction: column; gap: 28px; }
.location-text p { font-size: 16px; font-weight: 300; line-height: 1.75; color: var(--text2); max-width: 48ch; }
.poi { display: grid; gap: 0; }
.poi-row { display: flex; gap: 16px; align-items: baseline; padding: 11px 0; border-bottom: 1px solid var(--line2); }
.poi-row b { font-family: Jost, sans-serif; font-weight: 300; font-size: 19px; min-width: 92px; white-space: nowrap; color: var(--brick); }
.poi-row span { font-size: 14px; color: var(--text3); }
.map { min-height: 460px; background: var(--line); }
.map iframe { width: 100%; height: 100%; min-height: 460px; border: 0; display: block; }

/* Оплата */
.pay-head { padding: 0 clamp(8px, 2vw, 36px); margin-bottom: clamp(24px, 3vw, 40px); }
.pay-head h2 { max-width: 20ch; }
.pay-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); }
.pay-card { background: #FFFFFF; padding: clamp(22px, 2.2vw, 36px); display: flex; flex-direction: column; gap: 12px; }
.pay-card b { font-family: Jost, sans-serif; font-weight: 300; font-size: 24px; line-height: 1.15; }
.pay-card span { font-size: 14px; font-weight: 300; line-height: 1.7; color: var(--text2); }

/* Заявка */
.request { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr)); background: var(--dark); color: var(--on-dark); }
.request-text { padding: clamp(30px, 4vw, 68px) clamp(22px, 3.6vw, 60px); display: flex; flex-direction: column; gap: 18px; justify-content: center; }
.request-text .eyebrow { color: var(--on-dark3); }
.request-text h2 { max-width: 16ch; }
.request-text p { font-size: 16px; font-weight: 300; line-height: 1.75; color: var(--on-dark2); max-width: 44ch; }
.request-form { padding: clamp(30px, 4vw, 68px) clamp(22px, 3.6vw, 60px); display: flex; flex-direction: column; gap: 12px; justify-content: center; }
.request-form input[type=text], .request-form input[type=tel] { font: inherit; font-size: 16px; padding: 16px 0; background: transparent; border: 0; border-bottom: 1px solid rgba(242,241,238,.35); color: var(--on-dark); outline: none; }
.request-form input:focus { border-bottom-color: var(--on-dark3); }
.request-form input::placeholder { color: var(--on-dark2); opacity: .75; }
.agree { display: flex; align-items: flex-start; gap: 12px; font-size: 13px; line-height: 1.55; cursor: pointer; margin-top: 8px; color: var(--on-dark2); }
.agree input { width: 18px; height: 18px; margin: 1px 0 0; flex-shrink: 0; accent-color: var(--on-dark3); cursor: pointer; }
.agree a { text-decoration: underline; }
.request-form .btn { margin-top: 6px; align-self: flex-start; }
.request-done .title { font-family: Jost, sans-serif; font-weight: 300; font-size: 28px; }
.request-done p { font-size: 15px; color: var(--on-dark2); line-height: 1.7; margin-top: 10px; }
.form-err { font-size: 13px; color: #FFB4A2; }
.honeypot { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; pointer-events: none; }

/* Подвал */
.site-footer { padding: clamp(52px, 6vw, 92px) clamp(22px, 3.6vw, 60px) 36px; display: flex; flex-direction: column; gap: 36px; }
.footer-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); gap: 28px; }
.footer-brand { font-family: Jost, sans-serif; font-size: 20px; letter-spacing: .14em; text-transform: uppercase; margin-bottom: 10px; }
.footer-addr, .footer-office { font-size: 14px; color: var(--muted); line-height: 1.7; }
.footer-cap { font-size: 11px; letter-spacing: .2em; text-transform: uppercase; color: var(--muted2); margin-bottom: 10px; }
.footer-phone { font-family: Jost, sans-serif; font-size: 22px; }
.footer-hours { font-size: 13px; color: var(--muted); margin-top: 6px; }
.footer-col { display: flex; flex-direction: column; gap: 9px; font-size: 14px; color: var(--text2); }
.footer-legal { border-top: 1px solid var(--line); padding-top: 20px; display: grid; gap: 10px; font-size: 11px; color: var(--muted2); line-height: 1.8; }
.footer-legal a { color: var(--muted); text-decoration: underline; }

/* Попап */
.overlay { position: fixed; inset: 0; z-index: 110; background: rgba(31,35,40,.55); display: grid; place-items: center; padding: 16px; overflow-y: auto; }
.popup { background: #FFFFFF; width: 100%; max-width: 500px; padding: clamp(26px, 3.6vw, 46px); position: relative; display: flex; flex-direction: column; gap: 20px; margin: auto; }
.popup .icon-btn { position: absolute; top: 10px; right: 10px; }
.popup-head { display: flex; flex-direction: column; gap: 10px; text-align: center; align-items: center; }
.popup-head h3 { font-size: clamp(26px, 2.8vw, 34px); line-height: 1.1; text-wrap: balance; }
.popup-head p { font-size: 15px; font-weight: 300; line-height: 1.6; color: var(--text2); max-width: 38ch; }
.popup-flat { font-size: 14px; color: var(--brick); }
.hr { height: 1px; background: var(--line); }
.field { display: flex; flex-direction: column; gap: 8px; font-size: 13px; color: var(--muted); }
.field input { font: inherit; font-size: 16px; color: var(--ink); padding: 15px 16px; border: 1px solid var(--line2); background: #FFFFFF; outline: none; }
.field input:focus { border-color: var(--brick); }
.popup .agree { color: var(--text2); margin-top: 0; }
.popup .agree input { accent-color: var(--brick); }
.popup .err { font-size: 13px; color: var(--err); margin-top: -10px; }
.popup .btn-submit { border: 0; background: var(--brick); color: #FFFFFF; font: inherit; font-size: 12px; letter-spacing: .12em; text-transform: uppercase; padding: 18px 26px; cursor: pointer; }
.popup .btn-submit:hover { background: var(--brick-d); }
.popup .btn-submit.is-off { background: var(--off); cursor: not-allowed; }
.popup-done { display: flex; flex-direction: column; gap: 12px; text-align: center; align-items: center; padding: 22px 0; }
.popup-done h3 { font-size: 30px; }
.popup-done p { font-size: 15px; font-weight: 300; line-height: 1.6; color: var(--text2); max-width: 34ch; }
.popup-done button { margin-top: 10px; cursor: pointer; border: 1px solid var(--line2); background: #FFFFFF; color: var(--ink); font: inherit; font-size: 12px; letter-spacing: .12em; text-transform: uppercase; padding: 14px 26px; }

/* Политика */
.page { padding: clamp(36px, 4.5vw, 64px) var(--pad) 0; }
.doc { max-width: 880px; margin: 0 auto; }
.crumbs { font-size: 13px; color: var(--muted); }
.doc h1 { font-size: clamp(28px, 3.2vw, 44px); line-height: 1.1; margin: 18px 0 28px; }
.doc h2 { font-size: clamp(19px, 1.8vw, 23px); line-height: 1.25; margin: 32px 0 0; }
.doc p, .doc li { font-size: 15px; font-weight: 300; line-height: 1.75; color: var(--text2); margin-top: 12px; }
.doc ul { margin: 0; padding-left: 20px; }

@media (max-width: 1240px) {
  .promo { grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: 'text timer' 'btn timer'; }
  .promo .btn { justify-self: start; }
}
@media (max-width: 900px) {
  .m-hide { display: none !important; }
  .call-icon, .burger { display: inline-flex; }
  .promo { grid-template-columns: 1fr; grid-template-areas: 'text' 'timer' 'btn'; }
  .promo-timer { justify-self: stretch; justify-content: space-between; }
  .promo .btn { justify-self: stretch; width: 100%; background: var(--on-dark); color: var(--dark); border: 0; }
  .filters { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 4px; width: 100%; }
  .filters button { padding: 6px 2px; min-height: 48px; font-size: 11px; letter-spacing: .03em; }
  .photos { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; margin: 0 calc(-1 * var(--pad)); padding: 0 var(--pad); }
  .photos::-webkit-scrollbar { display: none; }
  .photos > * { flex: 0 0 80%; scroll-snap-align: start; }
}
@media (prefers-reduced-motion: reduce) { * { animation: none !important; transition: none !important; } }

/* Каталог квартир из фида: фильтры в две строки и факты в карточке */
.filters-box { display: flex; flex-direction: column; gap: 10px; margin-bottom: 18px; }
.filter-row { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.filter-cap { font-size: 11px; letter-spacing: .2em; text-transform: uppercase; color: var(--muted); min-width: 86px; }
.filters button[disabled] { opacity: .4; cursor: not-allowed; }
.found { font-size: 14px; color: var(--muted); white-space: nowrap; }
.cat-note { padding: 0; margin: 0 0 18px; background: transparent; color: var(--muted); font-size: 13px; line-height: 1.6; }
.card-facts { display: flex; flex-direction: column; border-top: 1px solid var(--line); }
.card-facts div { display: flex; justify-content: space-between; gap: 12px; padding: 9px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.card-facts div:last-child { border-bottom: 0; }
.card-facts span:first-child { color: var(--muted); }
.card-price-row { display: flex; justify-content: space-between; align-items: flex-end; gap: 12px; margin-top: auto; }
.card-price { font-family: Jost, sans-serif; font-weight: 300; font-size: 28px; line-height: 1; }
.card-old { font-size: 13px; color: var(--muted2); margin-top: 6px; }
.card-old s { text-decoration: line-through; }
.card-btn { width: 100%; }
.empty { padding: 40px 24px; text-align: center; border: 1px solid var(--line); display: flex; flex-direction: column; align-items: center; gap: 14px; }
.empty span { font-family: Jost, sans-serif; font-weight: 300; font-size: 22px; }
@media (max-width: 900px) {
  .filter-row { align-items: flex-start; flex-direction: column; gap: 6px; }
  .filter-cap { min-width: 0; }
}

/* Фильтр квартир: чипы + диапазоны «от–до», как на mskver.ru */
.qf { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px 28px; padding: 22px clamp(16px, 2vw, 28px); background: var(--soft); border: 1px solid var(--line); margin-bottom: 22px; }
.qf-group { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.qf-wide { grid-column: span 1; }
.qf-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.qf-chips button { cursor: pointer; font: inherit; font-size: 12px; letter-spacing: .06em; text-transform: uppercase; padding: 0 14px; min-height: 40px; border: 1px solid var(--line2); background: #FFFFFF; color: var(--text2); }
.qf-chips button small { margin-left: 5px; font-size: 11px; color: var(--muted2); }
.qf-chips button.is-on { background: var(--brick); border-color: var(--brick); color: #FFFFFF; }
.qf-chips button.is-on small { color: rgba(255,255,255,.75); }
.qf-chips button:disabled { opacity: .45; cursor: default; }
.qf-chips button:not(.is-on):not(:disabled):hover { border-color: var(--brick); color: var(--brick); }
.qf-head { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.qf-val { font-size: 14px; color: var(--muted); white-space: nowrap; font-variant-numeric: tabular-nums; }
.qf-val b { font-family: Jost, sans-serif; font-weight: 400; font-size: 17px; color: var(--ink); }
.qf-range { --r: 10px; position: relative; height: 30px; touch-action: pan-y; }
.qf-track { position: absolute; left: var(--r); right: var(--r); top: 14px; height: 2px; background: var(--line2); }
.qf-track i { position: absolute; top: 0; bottom: 0; left: calc(var(--a, 0) * 100%); right: calc((1 - var(--b, 1)) * 100%); background: var(--brick); }
.qf-range input[type=range] { -webkit-appearance: none; appearance: none; position: absolute; inset: 0; width: 100%; height: 30px; margin: 0; background: none; pointer-events: none; }
.qf-range input[data-hi] { z-index: 2; }
.qf-range input[type=range]:focus { outline: none; }
.qf-range input[type=range]::-webkit-slider-runnable-track { height: 30px; background: none; border: 0; }
.qf-range input[type=range]::-moz-range-track { height: 30px; background: none; border: 0; }
.qf-range input[type=range]::-webkit-slider-thumb { -webkit-appearance: none; width: 20px; height: 20px; margin-top: 5px; border-radius: 50%; background: #FFFFFF; border: 1px solid var(--brick); box-shadow: 0 1px 3px rgba(31,35,40,.18); pointer-events: auto; cursor: grab; }
.qf-range input[type=range]::-moz-range-thumb { width: 20px; height: 20px; border-radius: 50%; background: #FFFFFF; border: 1px solid var(--brick); box-shadow: 0 1px 3px rgba(31,35,40,.18); pointer-events: auto; cursor: grab; }
.qf-range input[type=range]:active::-webkit-slider-thumb { cursor: grabbing; }
.qf-foot { grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: center; gap: 10px 24px; padding-top: 16px; border-top: 1px solid var(--line); }
.qf-found { font-size: 14px; color: var(--muted); }
.qf-found b { font-weight: 500; color: var(--ink); }
.qf-reset { cursor: pointer; font: inherit; font-size: 13px; color: var(--brick); background: none; border: 0; padding: 0; text-decoration: underline; }
.qf-sort { margin-left: auto; display: flex; align-items: center; gap: 10px; font-size: 13px; color: var(--muted); }
.qf-sort select { font: inherit; font-size: 14px; color: var(--ink); padding: 9px 12px; border: 1px solid var(--line2); background: #FFFFFF; cursor: pointer; }
@media (max-width: 1240px) { .qf { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 900px) {
  .qf { grid-template-columns: 1fr; gap: 16px; padding: 16px; }
  .qf-sort { margin-left: 0; width: 100%; justify-content: space-between; }
  .qf-chips { display: grid; grid-template-columns: repeat(2, 1fr); }
}

/* Окно квартиры: слева планировка, справа характеристики */
.flat-overlay { z-index: 100; padding: clamp(12px, 3vw, 40px); }
.flat-card { background: #FFFFFF; width: 100%; max-width: 1080px; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 380px), 1fr)); position: relative; margin: auto; }
.flat-card .icon-btn { position: absolute; top: 10px; right: 10px; z-index: 2; }
.flat-plan { background: var(--soft); padding: clamp(20px, 3vw, 44px); display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px; min-height: 340px; }
.flat-plan img { max-width: 100%; max-height: 520px; object-fit: contain; mix-blend-mode: multiply; }
.plan-note { font-size: 12px; color: var(--muted2); text-align: center; }
.flat-body { padding: clamp(24px, 3.2vw, 52px); display: flex; flex-direction: column; gap: 22px; }
.flat-body h3 { font-size: clamp(26px, 2.8vw, 38px); line-height: 1.1; }
.flat-badge { align-self: flex-start; padding: 6px 11px; background: var(--sky); color: var(--blue-d); font-size: 10px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; }
.flat-rows { display: flex; flex-direction: column; }
.flat-rows div { display: flex; justify-content: space-between; gap: 16px; padding: 11px 0; border-bottom: 1px solid var(--line); font-size: 15px; }
.flat-rows span:first-child { color: var(--muted); }
.flat-price { font-family: Jost, sans-serif; font-weight: 300; font-size: 38px; line-height: 1; }
.flat-save { font-size: 14px; color: var(--muted2); margin-top: 8px; }
.flat-save s { text-decoration: line-through; }
.flat-buttons { display: flex; flex-direction: column; gap: 8px; }
.flat-note { font-size: 12px; color: var(--muted2); line-height: 1.6; }
@media (max-width: 900px) { .flat-plan { min-height: 240px; } .flat-plan img { max-height: 320px; } }
/* Окно квартиры не должно быть шире экрана на телефоне */
.flat-card { max-width: min(1080px, 100%); }
.flat-rows div { flex-wrap: wrap; }
.flat-rows span { min-width: 0; overflow-wrap: anywhere; }
.flat-rows span:last-child { text-align: right; }

/* Комнатность — на всю ширину панели фильтра */
.qf-rooms { grid-column: auto; }

/* Две строки: комнатность · корпус · отделка, ниже три диапазона */
.qf-chips { row-gap: 6px; }
@media (min-width: 901px) { .qf-chips button { padding: 0 12px; } }

/* Живое фото на первом экране: медленный зум с лёгким смещением.
   26 секунд в одну сторону, потом обратно — движение почти незаметное,
   но кадр перестаёт выглядеть статичной картинкой. */
@keyframes vr-kenburns {
  from { transform: scale(1) translate(0, 0); }
  to { transform: scale(1.08) translate(-1.5%, -1%); }
}
.hero-img img { transform-origin: 55% 50%; animation: vr-kenburns 26s ease-in-out infinite alternate; will-change: transform; }

/* Бегущий блик на кнопке «Заказать звонок» — слева направо, по кругу */
@keyframes vr-shine {
  0% { transform: translateX(-160%) skewX(-20deg); }
  55%, 100% { transform: translateX(330%) skewX(-20deg); }
}
[data-call] { position: relative; overflow: hidden; }
[data-call]::after {
  content: ""; position: absolute; top: 0; left: 0; width: 45%; height: 100%;
  background: linear-gradient(100deg, rgba(255,255,255,0) 0%, rgba(255,255,255,.38) 50%, rgba(255,255,255,0) 100%);
  transform: translateX(-160%) skewX(-20deg);
  animation: vr-shine 3.2s ease-in-out infinite;
  pointer-events: none;
}

/* Планировка в окне квартиры во всю ширину колонки. Увеличения по клику нет:
   картинки обрезаны по чертежу и читаются как есть, а лупа обещала бы прибавку,
   которой почти нет. Понадобится — хватит data-zoom на картинке, зум даст слой. */
.flat-card { max-width: min(1200px, 100%); }
@media (min-width: 901px) { .flat-card { grid-template-columns: 1.1fr 0.9fr; } }
.flat-plan { padding: clamp(16px, 2vw, 28px); }
.flat-plan img { max-height: min(68vh, 720px); }
@media (max-width: 900px) { .flat-plan img { max-height: 56vh; } }

/* Кнопка «Показать ещё»: квартир много, список открывается страницами */
.flats-more { display: flex; justify-content: center; padding-top: clamp(28px, 3vw, 44px); }
.flats-more .btn { min-width: 260px; }

/* Выбор этажа в окне квартиры: карточка в каталоге показывает диапазон
   и цену «от», а конкретный этаж покупатель выбирает здесь. */
.flat-pick { display: flex; flex-direction: column; gap: 10px; }
.flat-pick-list { display: flex; flex-wrap: wrap; gap: 8px; }
.flat-pick-list button { font: inherit; font-size: 13px; text-align: left; padding: 8px 12px;
  background: #FFFFFF; border: 1px solid var(--line2); cursor: pointer; display: flex;
  flex-direction: column; gap: 2px; min-width: 112px; }
.flat-pick-list button b { font-weight: 500; }
.flat-pick-list button span { font-size: 12px; color: var(--muted); }
.flat-pick-list button:hover { border-color: var(--brick); }
.flat-pick-list button.is-on { border-color: var(--brick); background: var(--sand); }

/* «Показать все» — второстепенное действие рядом с «Показать ещё»:
   текстом, чтобы две одинаковые кнопки не спорили за внимание. */
.flats-more { gap: clamp(14px, 2vw, 28px); flex-wrap: wrap; align-items: center; }
.show-all { font: inherit; font-size: 13px; color: var(--muted); background: none;
  border: 0; padding: 8px 4px; cursor: pointer; text-decoration: underline;
  text-underline-offset: 4px; }
.show-all:hover { color: var(--brick); }

/* Раскладка фильтра. Пятый корпус не влезал в одну колонку и уезжал на вторую
   строку, а ползунок стоимости стоял в верхнем ряду, оторванный от двух других.
   Теперь корпуса занимают две колонки, а все три диапазона идут нижним рядом:
   стоимость принудительно начинает строку, площадь и этаж встают за ней.
   Только с 901 px: в одну колонку span 2 создал бы лишний столбец. */
@media (min-width: 901px) {
  .qf-group[data-range="price"] { grid-column: 1; }
}
/* Две колонки корпусам отдаём только там, где их три: на промежуточной ширине
   колонок всего две, и растянутый «Корпус» оставлял пустую половину строки
   рядом с комнатностью — там пусть чипы переносятся. */
@media (min-width: 1241px) {
  .qf-houses { grid-column: span 2; }
}

/* Счётчик в чипе — отдельной плашкой. Вплотную к названию он читался как
   часть номера: «КОРП. 1 47» выглядело как корпус 147. */
.qf-chips button small { margin-left: 9px; padding: 2px 7px; border-radius: 10px;
  background: var(--line); color: var(--muted); font-size: 11px; letter-spacing: 0;
  font-variant-numeric: tabular-nums; }
.qf-chips button.is-on small { background: rgba(255,255,255,.24); color: #FFFFFF; }
.qf-chips button:disabled small { background: var(--line); color: var(--muted2); }

/* Плашка со счётчиком сделала чипы шире, и четыре кнопки комнатности перестали
   помещаться в треть строки. На широком экране режем сетку на шесть долей:
   комнатность и корпус занимают по половине ряда, три ползунка — по трети.
   Так ничего не переносится и не остаётся пустых клеток. */
@media (min-width: 1241px) {
  .qf { grid-template-columns: repeat(6, minmax(0, 1fr)); }
  .qf-rooms, .qf-houses { grid-column: span 3; }
  .qf-group[data-range] { grid-column: span 2; }
  .qf-group[data-range="price"] { grid-column: 1 / span 2; }
}

/* Увеличение планировки по клику. Сам просмотрщик даёт общий слой — ему хватает
   data-zoom на картинке; своего не пишем, два подерутся за один клик.
   Чертежи из фида широкие (у трёшек 1090×584), в колонке окна они мельчают,
   поэтому увеличение здесь обязательно, в отличие от жк-вариант.рф. */
.flat-plan img { cursor: zoom-in; }

/* Вторая акция: бронь в день просмотра. Отдельно от месячной скидки —
   та живёт в [data-promo-block] и управляется слоем, эта от месяца не зависит.
   В окне квартиры — строкой под ценой, в попапе — под подзаголовком. */
.flat-bonus { margin-top: 10px; padding: 8px 12px; background: var(--sand);
  color: var(--brick-d); font-size: 13px; line-height: 1.4; display: inline-block; }
.popup-bonus { padding: 7px 12px; background: var(--sand); color: var(--brick-d);
  font-size: 13px; line-height: 1.4; }

/* Бонус за бронь — плашкой справа от цены, в том же духе, что «Акция до …»
   наверху карточки. В каталоге только сумма: условие в подсказке, в окне
   квартиры и в попапе. Цене запрещаем перенос — иначе плашка ломает её
   на две строки, а цена на карточке главная. */
.card-price { white-space: nowrap; }
.card-bonus { align-self: flex-end; white-space: nowrap; padding: 6px 10px;
  background: var(--sand); color: var(--brick-d); font-size: 12px;
  font-weight: 500; line-height: 1.2; }
