/*
  НАТИВ — квартал бизнес-класса на западе Москвы. Девелопер FORMA.

  В отличие от SOUL и PORTLAND, у этого проекта светлая айдентика:
  презентация набрана на белом, акцент — приглушённый оливковый #A6A459,
  снятый прямо с цифр в разделе «Проект в цифрах». Поэтому схема здесь
  перевёрнута: светлая бумага, тёмный графит текста, оливковый на действии.
  Ритм и структура — те же, что у эталона uglichi.com.
*/

:root {
  --paper: #F6F5F1;
  --paper-2: #FFFFFF;
  --paper-3: #EEEDE7;
  --ink: #23241F;
  --ink-dim: rgba(35, 36, 31, 0.68);
  --ink-faint: rgba(35, 36, 31, 0.46);
  --accent: #A6A459;
  --accent-deep: #8C8A45;
  --line: rgba(35, 36, 31, 0.14);
  --font-display: "Onest", system-ui, sans-serif;
  --font-body: "Manrope", system-ui, sans-serif;
  --pad: clamp(20px, 5vw, 64px);
}

* { box-sizing: border-box; }
html {
  scroll-behavior: smooth;
  /* Safari на телефоне самовольно укрупняет текст в длинных блоках — от этого
     заголовки распухают и строки уезжают за экран. Запрещаем. */
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  overflow-x: hidden;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.62;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
h1, h2, h3 { margin: 0; font-family: var(--font-display); font-weight: 500; letter-spacing: -0.02em; }
.h-display { font-family: var(--font-display); font-weight: 500; }

/* ---------- Шапка ---------- */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 60;
  display: flex; align-items: center; gap: 20px;
  padding: 14px var(--pad);
  background: rgba(246, 245, 241, 0.9);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
}
.nav-logo {
  font-family: var(--font-display); font-weight: 600; font-size: 16px;
  letter-spacing: 0.28em; color: var(--ink); text-decoration: none; white-space: nowrap;
}
.nav-links { display: flex; gap: 26px; margin-left: auto; }
.nav-links a { color: var(--ink-dim); text-decoration: none; font-size: 14px; transition: color .2s; }
.nav-links a:hover { color: var(--ink); }
.nav-cta {
  margin-left: auto; border: 0; border-radius: 999px; padding: 11px 20px;
  background: var(--accent-deep); color: #fff;
  font-family: var(--font-body); font-size: 13px; font-weight: 600; letter-spacing: .05em;
  cursor: pointer; white-space: nowrap; transition: background .2s;
}
.nav-cta:hover { background: var(--accent); }
.nav-links + .nav-cta { margin-left: 0; }

/* ---------- Герой ---------- */
.hero {
  position: relative; min-height: 100svh;
  display: flex; align-items: flex-end;
  padding: 120px var(--pad) clamp(56px, 9vh, 96px);
  overflow: hidden;
}
.hero-bg { position: absolute; inset: 0; background-size: cover; background-position: center; }
/* Кадр героя тёмный, текст на нём светлый — затемняем низ, чтобы читалось всегда. */
.hero-wash {
  position: absolute; inset: 0;
  background: linear-gradient(to top,
    rgba(20,21,17,0.92) 0%, rgba(20,21,17,0.74) 34%, rgba(20,21,17,0.30) 64%, rgba(20,21,17,0.40) 100%);
}
.hero-content { position: relative; max-width: 800px; color: #F6F5F1; }
.hero-content .eyebrow { color: #CFCE94; }
.eyebrow {
  display: inline-block; font-family: var(--font-body);
  font-size: 12px; font-weight: 600; letter-spacing: .2em; text-transform: uppercase;
  color: var(--accent-deep); margin-bottom: 18px;
}
.hero h1 { font-size: clamp(33px, 6.4vw, 70px); line-height: 1.06; margin-bottom: 20px; }
.lead { font-size: clamp(16px, 2.1vw, 20px); line-height: 1.6; max-width: 60ch; margin: 0 0 32px; color: var(--ink-dim); }
.hero-content .lead { color: rgba(246,245,241,0.82); }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; }

/* ---------- Кнопки ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  border: 0; border-radius: 999px;
  font-family: var(--font-body); font-weight: 600; font-size: 14px; letter-spacing: .04em;
  text-decoration: none; cursor: pointer; transition: background .2s, border-color .2s, color .2s;
}
.btn-xl { padding: 16px 30px; }
.btn-accent { background: var(--accent-deep); color: #fff; }
.btn-accent:hover { background: var(--accent); }
.btn-ghost { background: transparent; color: var(--ink); border: 1px solid var(--line); }
.btn-ghost:hover { border-color: var(--ink); }
.hero-cta .btn-ghost { color: #F6F5F1; border-color: rgba(246,245,241,0.4); }
.hero-cta .btn-ghost:hover { border-color: #F6F5F1; }

/* ---------- Секции ---------- */
.section { padding: clamp(64px, 11vh, 132px) var(--pad); }
.section-inner { max-width: 1240px; margin: 0 auto; }
.section-head { margin-bottom: 44px; }
.section-title { font-size: clamp(25px, 4.2vw, 46px); line-height: 1.14; max-width: 19ch; overflow-wrap: anywhere; }
.manifesto { background: var(--paper-3); }
.manifesto-text { font-family: var(--font-display); font-weight: 400; font-size: clamp(20px, 2.7vw, 30px); line-height: 1.42; max-width: 30ch; margin: 0; }
.note { max-width: 62ch; margin: 28px 0 0; font-size: 15px; line-height: 1.6; color: var(--ink-dim); }

/* ---------- Бенто-сетка ---------- */
.bento-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.bento-card {
  position: relative; min-height: 260px; border-radius: 6px; overflow: hidden;
  background: var(--paper-3); display: flex; flex-direction: column; justify-content: flex-end;
}
.bento-card.c2x2 { grid-column: span 2; grid-row: span 2; min-height: 540px; }
.bento-card.c2x1 { grid-column: span 2; }
.bento-card .img { position: absolute; inset: 0; background-size: cover; background-position: center; transition: transform .6s ease; }
.bento-card:hover .img { transform: scale(1.04); }
/* Подпись поверх фото: на светлой теме плашка тёмная, иначе текст исчезнет на снимке. */
.bento-card .meta {
  position: relative; padding: 22px 22px 20px; padding-top: 74px; color: #F6F5F1;
  background: linear-gradient(to top, rgba(20,21,17,0.94) 14%, rgba(20,21,17,0.72) 62%, rgba(20,21,17,0) 100%);
}
.bento-card .meta h3 { font-size: 21px; line-height: 1.24; margin-bottom: 8px; }
.bento-card .meta p { margin: 0; overflow-wrap: anywhere; font-size: 15px; line-height: 1.55; color: rgba(246,245,241,0.78); }

/* ---------- Цифры ---------- */
.facts { display: grid; grid-template-columns: repeat(4, 1fr); gap: 28px; margin-top: 40px; }
.fact { border-top: 1px solid var(--line); padding-top: 16px; }
.fact-val { font-family: var(--font-display); font-weight: 500; font-size: clamp(26px, 3.4vw, 40px); line-height: 1.12; letter-spacing: -0.03em; color: var(--accent-deep); }
.fact-lbl { margin-top: 6px; font-size: 14px; line-height: 1.45; color: var(--ink-dim); }

/* ---------- Метки ---------- */
.chips { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 28px; }
.chips span { border: 1px solid var(--line); border-radius: 999px; padding: 9px 16px; font-size: 14px; color: var(--ink-dim); }

/* ---------- Вопросы ---------- */
.faq-item { border-bottom: 1px solid var(--line); padding: 18px 0; }
.faq-item summary { cursor: pointer; font-family: var(--font-display); font-weight: 500; font-size: 18px; list-style: none; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: " +"; color: var(--accent-deep); }
.faq-item[open] summary::after { content: " −"; }
.faq-item p { margin: 12px 0 0; color: var(--ink-dim); max-width: 68ch; }

/* ---------- Подвал ---------- */
.footer { padding: 48px var(--pad) 64px; border-top: 1px solid var(--line); background: var(--paper-3); }
.footer p { margin: 0; font-size: 14px; color: var(--ink-dim); }
.footer-legal { margin-top: 14px !important; font-size: 12px; color: var(--ink-faint); }

/* ---------- Окно заявки ---------- */
.lead-modal { position: fixed; inset: 0; z-index: 90; display: none; align-items: center; justify-content: center; padding: 20px; }
.lead-modal.open { display: flex; }
.lead-overlay { position: absolute; inset: 0; background: rgba(20,21,17,0.62); }
.lead-dialog {
  position: relative; width: min(460px, 100%); max-height: 92vh; overflow-y: auto;
  background: var(--paper-2); border: 1px solid var(--line); border-radius: 8px; padding: 32px 26px 26px;
}
.lead-close { position: absolute; top: 12px; right: 14px; border: 0; background: transparent; color: var(--ink-dim); font-size: 26px; line-height: 1; cursor: pointer; }
.lead-dialog h3 { font-size: 24px; margin-bottom: 8px; }
.lead-sub { margin: 0 0 22px; font-size: 15px; color: var(--ink-dim); }
.lead-field { display: block; margin-bottom: 16px; }
.lead-field span { display: block; font-size: 12px; letter-spacing: .1em; text-transform: uppercase; color: var(--ink-faint); margin-bottom: 7px; }
.lead-field input {
  width: 100%; border: 0; border-bottom: 1px solid var(--line); background: transparent;
  color: var(--ink); font-family: var(--font-body); font-size: 17px; padding: 10px 0;
}
.lead-field input:focus { outline: none; border-bottom-color: var(--accent-deep); }
.lead-submit { width: 100%; margin-top: 8px; }
.lead-hp { position: absolute; left: -9999px; width: 1px; height: 1px; }
.lead-error { display: none; margin: 12px 0 0; color: #B24A32; font-size: 14px; }
.lead-modal.error .lead-error { display: block; }
.lead-consent { display: flex; gap: 10px; margin-top: 16px; font-size: 12px; line-height: 1.5; color: var(--ink-faint); }
.lead-consent input { margin-top: 2px; }
.lead-success { display: none; text-align: center; padding: 18px 0; }
.lead-modal.success .lead-form-wrap { display: none; }
.lead-modal.success .lead-success { display: block; }
.lead-success p { color: var(--ink-dim); }

/* ---------- Появление при прокрутке ---------- */
/* Контент виден без скриптов: если что-то не загрузится, страница не опустеет. */
.reveal { opacity: 1; }
.js-reveal .reveal { opacity: 0; transform: translateY(18px); }

/* ---------- Телефон ---------- */
@media (max-width: 980px) {
  .bento-grid { grid-template-columns: repeat(2, 1fr); }
  .bento-card.c2x2 { grid-column: span 2; grid-row: span 1; min-height: 320px; }
  .facts { grid-template-columns: repeat(2, 1fr); }
  .nav-links { display: none; }
  .nav-cta { margin-left: auto; }
}
@media (max-width: 560px) {
  body { font-size: 16px; }
  .bento-grid { grid-template-columns: 1fr; }
  .bento-card, .bento-card.c2x2, .bento-card.c2x1 { grid-column: span 1; min-height: 260px; }
  .facts { grid-template-columns: 1fr; gap: 20px; }
  .hero { min-height: 92svh; padding-top: 96px; }
  .hero-cta .btn { width: 100%; }
  .section-title, .manifesto-text { max-width: none; }
}
