/* ЖК «Табысты» — стили. Одна палитра, два шрифта, без фреймворков. */
:root {
  --navy: #16233a;
  --navy-2: #1f3150;
  --ivory: #f6f2ea;
  --sand: #ece5d8;
  --paper: #fffdf9;
  --gold: #c4a46b;
  --gold-dark: #8c6b36;
  --ink: #1b2433;
  --muted: #5d6676;
  --line: rgba(27, 36, 51, .12);

  --serif: "Cormorant Garamond", Georgia, serif;
  --sans: "Manrope", system-ui, -apple-system, "Segoe UI", sans-serif;

  --wrap: 1240px;
  --pad: clamp(20px, 4vw, 48px);
  --r: 14px;
  --ease: cubic-bezier(.22, .61, .36, 1);
  --header: 76px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: var(--header); -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--ivory); color: var(--ink);
  font: 400 17px/1.65 var(--sans); -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; }
h1, h2, h3 { margin: 0; font-family: var(--serif); font-weight: 500; line-height: 1.08; letter-spacing: -.01em; }
h2 { font-size: clamp(34px, 4.4vw, 56px); margin-bottom: 24px; }
h3 { font-size: 25px; margin-bottom: 8px; }
p { margin: 0 0 16px; }
figure { margin: 0; }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; border-radius: 4px; }

.wrap { width: 100%; max-width: calc(var(--wrap) + var(--pad) * 2); margin: 0 auto; padding: 0 var(--pad); }
.section { padding: clamp(80px, 11vw, 140px) 0; }
.eyebrow { font-size: 13px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--gold-dark); margin-bottom: 18px; }
.head { max-width: 720px; margin-bottom: clamp(36px, 5vw, 60px); }
.head--row { max-width: none; display: flex; justify-content: space-between; align-items: end; gap: 40px; }
.head--row h2 { margin-bottom: 0; }
.head__note { max-width: 380px; color: var(--muted); margin: 0; }
.fine { font-size: 13px; color: var(--muted); margin: 14px 0 0; }

.skip { position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--gold); color: var(--navy); padding: 10px 16px; border-radius: 8px; }
.skip:focus { top: 12px; }

/* Кнопки и ссылки */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 52px; padding: 0 28px; border-radius: 999px;
  font-size: 15px; font-weight: 600; letter-spacing: .01em; white-space: nowrap;
  transition: background-color .3s var(--ease), color .3s var(--ease), border-color .3s var(--ease), transform .2s var(--ease);
}
.btn:active { transform: scale(.97); }
.btn--sm { min-height: 42px; padding: 0 20px; font-size: 14px; }
.btn--gold { background: var(--gold); color: var(--navy); }
.btn--gold:hover { background: #d6b882; }
.btn--dark { background: var(--navy); color: var(--ivory); }
.btn--dark:hover { background: var(--navy-2); }
.btn--line { border: 1px solid rgba(246, 242, 234, .45); color: var(--ivory); }
.btn--line:hover { border-color: var(--gold); color: var(--gold); }

.link {
  display: inline; font-weight: 500; color: inherit;
  background: linear-gradient(currentColor, currentColor) 0 100% / 100% 1px no-repeat;
  padding-bottom: 2px; transition: background-size .35s var(--ease), color .2s;
}
.link:hover { background-size: 0 1px; background-position: 100% 100%; color: var(--gold-dark); }

/* Шапка */
.header { position: fixed; inset: 0 0 auto; z-index: 50; height: var(--header); color: var(--ivory); transition: background-color .35s var(--ease), box-shadow .35s; }
.header.is-solid { background: rgba(22, 35, 58, .96); backdrop-filter: blur(10px); box-shadow: 0 1px 0 rgba(255, 255, 255, .06); }
.header__in { height: 100%; display: flex; align-items: center; gap: 32px; }
.header__logo img { width: 92px; height: auto; }
.nav { display: flex; gap: 26px; margin-left: auto; font-size: 14px; font-weight: 500; }
.nav a { position: relative; padding: 6px 0; opacity: .85; transition: opacity .2s; }
.nav a::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1px; background: var(--gold); transform: scaleX(0); transform-origin: right; transition: transform .35s var(--ease); }
.nav a:hover, .nav a.is-active { opacity: 1; }
.nav a:hover::after, .nav a.is-active::after { transform: scaleX(1); transform-origin: left; }
.nav__phone { display: none; }
.header__phone { font-size: 14px; font-weight: 600; white-space: nowrap; }
.burger { display: none; width: 44px; height: 44px; position: relative; }
.burger span { position: absolute; left: 11px; right: 11px; height: 1.5px; background: currentColor; transition: transform .3s var(--ease), top .3s var(--ease); }
.burger span:first-child { top: 18px; }
.burger span:last-child { top: 25px; }
.burger[aria-expanded="true"] span:first-child { top: 21px; transform: rotate(45deg); }
.burger[aria-expanded="true"] span:last-child { top: 21px; transform: rotate(-45deg); }

/* Прелоадер: шанырак крутится, затем проявляется название */
.preloader { position: fixed; inset: 0; z-index: 200; display: grid; place-content: center; justify-items: center; gap: 26px; background: var(--navy) url(../img/pattern.webp) center / cover; transition: opacity .7s var(--ease), visibility .7s; }
.preloader.is-done { opacity: 0; visibility: hidden; }
.preloader__mark { width: 96px; height: 96px; animation: spin 1.6s var(--ease) both, glow 1.6s var(--ease) both; }
@keyframes spin { from { transform: rotate(-270deg) scale(.6); opacity: 0; } 30% { opacity: 1; } to { transform: rotate(0) scale(1); } }
@keyframes glow { 60% { filter: drop-shadow(0 0 0 rgba(210, 180, 122, 0)); } 100% { filter: drop-shadow(0 0 22px rgba(210, 180, 122, .45)); } }
.preloader__name { margin: 0; font-family: var(--sans); font-weight: 500; font-size: 28px; letter-spacing: .42em; padding-left: .42em; color: var(--ivory); display: flex; }
.preloader__name span { opacity: 0; transform: translateY(10px); filter: blur(4px); animation: letter .6s var(--ease) forwards; }
.preloader__name span:nth-child(1) { animation-delay: .9s; } .preloader__name span:nth-child(2) { animation-delay: .98s; }
.preloader__name span:nth-child(3) { animation-delay: 1.06s; } .preloader__name span:nth-child(4) { animation-delay: 1.14s; }
.preloader__name span:nth-child(5) { animation-delay: 1.22s; } .preloader__name span:nth-child(6) { animation-delay: 1.3s; }
.preloader__name span:nth-child(7) { animation-delay: 1.38s; }
@keyframes letter { to { opacity: 1; transform: none; filter: none; } }
.is-loading { overflow: hidden; }

/* Первый экран: узорный синий фон + рендер, башня выходит из рамки */
.hero { position: relative; min-height: 100svh; display: flex; flex-direction: column; color: var(--ivory); overflow: hidden;
  background: radial-gradient(60% 50% at 50% 30%, rgba(80, 130, 180, .28), transparent 70%), var(--navy) url(../img/pattern.webp) center / cover; }
.hero::before { content: ""; position: absolute; inset: 0; background: radial-gradient(40% 35% at var(--lx, 50%) 30%, rgba(210, 180, 122, .12), transparent 70%); transition: background .2s; pointer-events: none; }
.hero__top { position: relative; display: flex; justify-content: space-between; align-items: end; gap: 40px; padding-top: calc(var(--header) + clamp(28px, 4vh, 48px)); }
.hero h1 { font-size: clamp(40px, 4.6vw, 66px); line-height: 1.02; margin-bottom: 8px; }
.hero__sub { font-family: var(--serif); font-size: clamp(24px, 2.4vw, 34px); color: var(--gold); margin: 0; }
.hero__side { display: grid; gap: 14px; justify-items: end; text-align: right; padding-bottom: 6px; }
.hero__pdf { display: inline-flex; align-items: center; gap: 12px; font-size: 15px; font-weight: 500; color: var(--ivory); transition: color .25s; }
.hero__pdf svg { color: var(--gold); transition: transform .3s var(--ease); }
.hero__pdf:hover { color: var(--gold); } .hero__pdf:hover svg { transform: translateY(2px); }
.hero__pdf small { font-size: 12px; opacity: .6; margin-left: 4px; }
.hero__mort { margin: 0; font-family: var(--serif); font-size: 26px; line-height: 1.2; }
.hero__mort span { display: block; font-family: var(--sans); font-size: 13px; letter-spacing: .14em; text-transform: uppercase; color: var(--gold); margin-top: 6px; }

.hero__stage { position: relative; flex: 1; display: flex; align-items: end; justify-content: center; padding: 0 var(--pad) clamp(24px, 4vh, 48px); }
.hero__render { position: relative; width: min(100%, 1320px, calc((100svh - var(--header) - 190px) * 2.05)); will-change: transform; }
.hero__render img { width: 100%; filter: drop-shadow(0 30px 40px rgba(5, 10, 20, .45)); }
.hero__shine { position: absolute; inset: 0; pointer-events: none;
  -webkit-mask: url(../img/hero-render.webp) center / 100% 100% no-repeat; mask: url(../img/hero-render.webp) center / 100% 100% no-repeat;
  background: linear-gradient(105deg, transparent 35%, rgba(255, 255, 255, .35) 50%, transparent 65%) -100% 0 / 60% 100% no-repeat; }
.ready .hero__shine { animation: shine 2.6s 1s var(--ease) both, shine 3s 9s var(--ease) infinite; }
@keyframes shine { 0% { background-position: -100% 0; } 60%, 100% { background-position: 260% 0; } }
.hero__badge { position: absolute; left: calc(var(--pad) + 2%); bottom: clamp(40px, 9vh, 90px); display: flex; align-items: center; gap: 18px; padding: 12px 12px 12px 24px; border-radius: 999px; background: rgba(22, 35, 58, .82); backdrop-filter: blur(10px); border: 1px solid rgba(210, 180, 122, .35); }
.hero__badge p { margin: 0; font-size: 15px; white-space: nowrap; }
.hero__badge b { font-family: var(--serif); font-weight: 500; font-size: 28px; margin: 0 2px; }

.leaf { position: absolute; width: clamp(110px, 14vw, 220px); opacity: .9; pointer-events: none; animation: sway 7s ease-in-out infinite alternate; }
.leaf--l { left: 0; bottom: -8%; transform-origin: 0 60%; transform: scaleX(-1); animation-name: swayL; }
.leaf--r { right: 0; top: -6%; transform-origin: 100% 60%; }
@keyframes sway { from { rotate: -3deg; } to { rotate: 4deg; } }
@keyframes swayL { from { transform: scaleX(-1) rotate(-3deg); } to { transform: scaleX(-1) rotate(4deg); } }

/* вход первого экрана — после прелоадера */
[data-in], .hero__render { opacity: 0; }
.ready [data-in] { animation: rise .9s var(--ease) both; }
.ready .hero__render { animation: renderIn 1.4s .15s var(--ease) both; }
.ready .hero__title [data-in]:nth-child(1) { animation-delay: .1s; } .ready .hero__title [data-in]:nth-child(2) { animation-delay: .22s; }
.ready .hero__side [data-in]:nth-child(1) { animation-delay: .3s; } .ready .hero__side [data-in]:nth-child(2) { animation-delay: .4s; }
.ready .hero__badge { animation-delay: .9s; }
@keyframes rise { from { opacity: 0; transform: translateY(22px); } to { opacity: 1; transform: none; } }
@keyframes renderIn { from { opacity: 0; transform: translateY(60px) scale(.96); } to { opacity: 1; transform: none; } }

/* Цифры */
.facts { background: var(--paper); border-bottom: 1px solid var(--line); }
.facts__grid { display: grid; grid-template-columns: repeat(4, 1fr); }
.fact { padding: 44px 28px 40px; border-left: 1px solid var(--line); }
.fact:first-child { border-left: 0; padding-left: 0; }
.fact__num { display: block; font-family: var(--serif); font-size: clamp(44px, 5vw, 64px); line-height: 1; color: var(--navy); margin-bottom: 12px; font-variant-numeric: lining-nums; }
.fact__txt { font-size: 15px; color: var(--muted); }

/* Две колонки */
.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(40px, 7vw, 110px); align-items: center; }
.split--top { align-items: start; }
.split--rev .split__text { order: 2; }
.split__text { max-width: 540px; }
.split__text > p { color: var(--muted); }
.frame { overflow: hidden; border-radius: var(--r); background: var(--sand); }
.frame img { width: 100%; height: 100%; object-fit: cover; transition: transform .9s var(--ease); }
.frame:hover img, a:hover > .frame img { transform: scale(1.03); }
.about .split__media { aspect-ratio: 4 / 5; max-height: 720px; }
.docs-inline { list-style: none; padding: 0; margin: 28px 0 34px; display: grid; gap: 10px; font-size: 15px; }

/* Преимущества */
.why { background: var(--paper); }
.why__grid { display: grid; grid-template-columns: 1.05fr 1fr; gap: clamp(40px, 6vw, 90px); align-items: start; }
.why__photo { aspect-ratio: 4 / 5; position: sticky; top: calc(var(--header) + 24px); }
.why__list { list-style: none; padding: 0; margin: 0; counter-reset: w; display: grid; grid-template-columns: 1fr 1fr; gap: 44px 40px; }
.why__list li { counter-increment: w; padding-top: 22px; border-top: 1px solid var(--line); }
.why__list li::before { content: "0" counter(w); display: block; font-size: 13px; font-weight: 600; color: var(--gold-dark); letter-spacing: .1em; margin-bottom: 14px; }
.why__list p { color: var(--muted); font-size: 16px; margin: 0; }

/* Галерея */
.mosaic { display: grid; grid-template-columns: repeat(12, 1fr); grid-auto-rows: clamp(110px, 12vw, 160px); gap: 14px; }
.mosaic a { overflow: hidden; border-radius: var(--r); background: var(--sand); }
.mosaic img { width: 100%; height: 100%; object-fit: cover; transition: transform .9s var(--ease); }
.mosaic a:hover img { transform: scale(1.04); }
.mosaic a { grid-row: span 2; }
.m-a { grid-column: span 6; } .m-b, .m-c { grid-column: span 3; }
.m-d, .m-e, .m-f { grid-column: span 4; }
.m-g { grid-column: span 7; } .m-h { grid-column: span 5; }

/* Лайтбокс */
.lb { position: fixed; inset: 0; z-index: 90; background: rgba(12, 19, 32, .94); display: grid; place-items: center; opacity: 0; transition: opacity .3s var(--ease); }
.lb.is-open { opacity: 1; }
.lb[hidden] { display: none; }
.lb__img { max-width: min(92vw, 1400px); max-height: 86vh; border-radius: 8px; }
.lb__close, .lb__nav { position: absolute; color: var(--ivory); font-size: 40px; line-height: 1; width: 56px; height: 56px; border-radius: 50%; transition: background .2s; }
.lb__close:hover, .lb__nav:hover { background: rgba(255, 255, 255, .1); }
.lb__close { top: 18px; right: 18px; }
.lb__prev { left: 18px; } .lb__next { right: 18px; }

/* Планировки */
.plans { background: var(--sand); }
.planner { display: grid; grid-template-columns: 400px 1fr; gap: 0; background: var(--paper); border-radius: 20px; overflow: hidden; }
.planner__controls { padding: 40px; border-right: 1px solid var(--line); display: flex; flex-direction: column; gap: 28px; }
.ctl__label { font-size: 13px; font-weight: 600; color: var(--muted); letter-spacing: .06em; text-transform: uppercase; margin-bottom: 12px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { min-height: 44px; padding: 0 16px; border-radius: 999px; border: 1px solid var(--line); font-size: 15px; font-weight: 500; transition: background-color .25s, color .25s, border-color .25s; }
.chip:hover { border-color: var(--navy); }
.chip[aria-checked="true"] { background: var(--navy); border-color: var(--navy); color: var(--ivory); }
.planner__sum { margin-top: auto; padding-top: 24px; border-top: 1px solid var(--line); }
.planner__area { font-family: var(--serif); font-size: 52px; line-height: 1; margin-bottom: 6px; color: var(--navy); }
.planner__meta { color: var(--muted); font-size: 15px; }
.planner__links { display: flex; gap: 22px; font-size: 15px; margin-bottom: 24px; flex-wrap: wrap; }
.planner__view { display: grid; place-items: center; padding: 32px; min-height: 560px; }
.planner__view img { max-height: 640px; width: auto; transition: opacity .35s var(--ease), transform .5s var(--ease); }
.planner__view img.is-swap { opacity: 0; transform: scale(.98); }

/* Отделка */
.spec { margin: 8px 0 0; }
.spec div { display: flex; justify-content: space-between; gap: 24px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.spec dt { color: var(--muted); }
.spec dd { margin: 0; text-align: right; font-weight: 500; }
.finish__pics { display: grid; grid-template-columns: 1fr 1fr; grid-template-rows: 240px 240px; gap: 14px; }
.finish__pics .f1 { grid-row: span 2; }
.finish__pics figure { position: relative; }
.finish__pics figcaption { position: absolute; left: 14px; bottom: 14px; background: rgba(22, 35, 58, .78); color: var(--ivory); font-size: 13px; padding: 6px 12px; border-radius: 999px; backdrop-filter: blur(6px); }

/* Расположение */
.place { background: var(--paper); }
.place__plan { aspect-ratio: 16 / 8; margin-bottom: 40px; }
.near { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px 32px; }
.near li { display: flex; align-items: center; gap: 16px; padding-bottom: 18px; border-bottom: 1px solid var(--line); font-weight: 500; }
.near img { width: 72px; height: 54px; object-fit: cover; border-radius: 8px; flex: none; }

/* Ипотека */
.cards { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.card { display: flex; flex-direction: column; padding: 32px 28px; background: var(--paper); border: 1px solid var(--line); border-radius: var(--r); transition: transform .35s var(--ease), box-shadow .35s var(--ease); }
.card:hover { transform: translateY(-3px); box-shadow: 0 18px 40px -24px rgba(22, 35, 58, .35); }
.card p { color: var(--muted); font-size: 16px; }
.card .link { margin-top: auto; align-self: flex-start; color: var(--navy); }
.card .card__tag { font-size: 12px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--gold-dark) !important; margin-bottom: 26px; }
.card--accent { background: var(--navy); border-color: var(--navy); color: var(--ivory); }
.card--accent p { color: rgba(246, 242, 234, .75); }
.card--accent .card .card__tag { color: var(--gold) !important; }
.card--accent .link { color: var(--gold); }

/* Застройщик */
.developer { background: var(--sand); }
.docs { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.docs a { display: block; background: var(--paper); border-radius: 12px; padding: 14px; height: 100%; transition: transform .35s var(--ease), box-shadow .35s var(--ease); }
.docs a:hover { transform: translateY(-3px); box-shadow: 0 18px 40px -24px rgba(22, 35, 58, .35); }
.docs img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; object-position: top; border-radius: 6px; margin-bottom: 12px; border: 1px solid var(--line); }
.docs span { display: block; font-size: 14px; line-height: 1.4; font-weight: 500; }

/* Контакты */
.contacts { background: var(--navy); color: var(--ivory); }
.contacts .eyebrow { color: var(--gold); }
.contacts__grid { display: grid; grid-template-columns: 1fr 1.15fr; gap: clamp(40px, 6vw, 90px); align-items: stretch; }
.contacts__list { margin: 0 0 36px; }
.contacts__list div { display: grid; grid-template-columns: 130px 1fr; gap: 20px; padding: 16px 0; border-bottom: 1px solid rgba(246, 242, 234, .12); }
.contacts__list dt { color: rgba(246, 242, 234, .55); font-size: 15px; }
.contacts__list dd { margin: 0; }
.contacts__list .link:hover { color: var(--gold); }
.contacts__phone { font-family: var(--serif); font-size: 30px; line-height: 1.1; }
.contacts__actions { display: flex; flex-wrap: wrap; gap: 14px; }
.map { min-height: 480px; border-radius: 20px; overflow: hidden; background: var(--navy-2); }

/* Подвал */
.footer { background: #101a2c; color: rgba(246, 242, 234, .6); padding: 56px 0 40px; font-size: 13px; }
.footer__in { display: grid; grid-template-columns: auto 1fr; gap: 28px 60px; align-items: center; }
.footer__in img { width: 96px; }
.footer__social { display: flex; gap: 26px; justify-content: flex-end; font-size: 15px; color: var(--ivory); }
.footer__legal { grid-column: 1 / -1; max-width: 900px; margin: 0; line-height: 1.6; }
.footer__copy { grid-column: 1 / -1; margin: 0; }

/* WhatsApp */
.wa { position: fixed; right: 22px; bottom: 22px; z-index: 40; width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center; background: #25d366; color: #fff; box-shadow: 0 10px 30px -10px rgba(0, 0, 0, .4); transition: transform .3s var(--ease); }
.wa:hover { transform: scale(1.07); }

/* Появление при прокрутке — мягко и один раз */
.js [data-reveal] { opacity: 0; transform: translateY(18px); transition: opacity .9s var(--ease), transform .9s var(--ease); }
.js [data-reveal].is-in { opacity: 1; transform: none; }

/* Адаптив */
@media (max-width: 1180px) {
  .nav { gap: 20px; }
  .header__phone { display: none; }
  .cards { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 980px) {
  :root { --header: 64px; }
  .burger { display: block; margin-left: 4px; }
  .header__cta { margin-left: auto; }
  .nav {
    position: fixed; inset: var(--header) 0 0; margin: 0; flex-direction: column; gap: 0;
    background: var(--navy); padding: 24px var(--pad) 40px; font-size: 26px; font-family: var(--serif);
    opacity: 0; visibility: hidden; transform: translateY(-8px); transition: opacity .3s var(--ease), transform .3s var(--ease), visibility .3s;
  }
  .nav.is-open { opacity: 1; visibility: visible; transform: none; }
  .nav a { padding: 14px 0; border-bottom: 1px solid rgba(246, 242, 234, .1); opacity: 1; }
  .nav a::after { display: none; }
  .nav__phone { display: block; margin-top: 18px; color: var(--gold); border: 0 !important; }
  .header { background: rgba(22, 35, 58, .96); }

  .hero { min-height: auto; }
  .hero__top { flex-direction: column; align-items: start; gap: 22px; }
  .hero__side { justify-items: start; text-align: left; }
  .hero__stage { flex-direction: column; align-items: stretch; padding-top: 30px; }
  .hero__render { width: 100%; }
  .hero__badge { position: relative; left: auto; bottom: auto; margin-top: 18px; justify-content: space-between; }
  .leaf { width: 90px; }

  .facts__grid { grid-template-columns: 1fr 1fr; }
  .fact { padding: 32px 20px; border-left: 0; border-top: 1px solid var(--line); }
  .fact:nth-child(-n+2) { border-top: 0; }
  .fact:nth-child(odd) { padding-left: 0; }
  .fact:nth-child(even) { border-left: 1px solid var(--line); }

  .split, .why__grid, .contacts__grid { grid-template-columns: 1fr; }
  .split--rev .split__text { order: 0; }
  .split__text { max-width: none; }
  .why__photo { position: static; aspect-ratio: 16 / 10; }
  .about .split__media { aspect-ratio: 4 / 3; }
  .head--row { flex-direction: column; align-items: start; gap: 16px; }

  .planner { grid-template-columns: 1fr; }
  .planner__controls { border-right: 0; border-bottom: 1px solid var(--line); padding: 28px; }
  .planner__view { min-height: 0; padding: 20px; order: -1; }
  .planner__view img { max-height: 420px; }

  .near { grid-template-columns: 1fr 1fr; }
  .docs { grid-template-columns: repeat(3, 1fr); }
  .map { min-height: 360px; }
}
@media (max-width: 640px) {
  body { font-size: 16px; }
  .header__cta { display: none; }
  .burger { margin-left: auto; }
  .header__logo img { width: 78px; }
  .hero__badge { flex-direction: column; align-items: stretch; border-radius: 18px; padding: 16px; gap: 12px; }
  .hero__badge p { text-align: center; }
  .mosaic { grid-template-columns: 1fr 1fr; grid-auto-rows: 150px; gap: 10px; }
  .mosaic a { grid-column: span 1 !important; grid-row: span 1 !important; }
  .mosaic .m-a, .mosaic .m-d { grid-column: span 2 !important; grid-row: span 2 !important; }
  .why__list { grid-template-columns: 1fr; gap: 28px; }
  .finish__pics { grid-template-rows: 180px 180px; }
  .near { grid-template-columns: 1fr; }
  .cards { grid-template-columns: 1fr; }
  .docs { grid-template-columns: 1fr 1fr; }
  .contacts__list div { grid-template-columns: 1fr; gap: 4px; }
  .contacts__actions .btn { flex: 1 1 100%; }
  .footer__in { grid-template-columns: 1fr; }
  .footer__social { justify-content: flex-start; }
  .lb__nav { bottom: 18px; top: auto; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
  .js [data-reveal], [data-in], .hero__render, .preloader__name span { opacity: 1; transform: none; filter: none; }
}
.map iframe { display: block; width: 100%; height: 100%; min-height: inherit; border: 0; }
