/* ============================================================
   Void & Form — авторское дизайн-бюро
   Дизайн-система: архитектурный минимализм, монохром
   Один шрифт — Montserrat. Никаких скруглений.
   ============================================================ */

/* Montserrat — вариативный, хостится локально: не зависит от Google Fonts */
@font-face {
  font-family: "Montserrat";
  font-style: normal;
  font-weight: 300 600;
  font-display: swap;
  src: url("../assets/fonts/montserrat-cyrillic.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}

@font-face {
  font-family: "Montserrat";
  font-style: normal;
  font-weight: 300 600;
  font-display: swap;
  src: url("../assets/fonts/montserrat-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --bg:        #FFFFFF;
  --bg-soft:   #F5F5F5;
  --bg-deep:   #EDEDED;
  --dark:      #17181A;
  --ink:       #111111;
  --ink-soft:  #555555;
  --muted:     #909090;
  --line:      #E3E3E3;
  --line-dark: rgba(255, 255, 255, .16);
  --accent:    #E8641B;

  --font: "Montserrat", "Helvetica Neue", Helvetica, Arial, sans-serif;

  --container: 1480px;
  --gutter: clamp(20px, 4.6vw, 72px);
  /* отступ от края экрана до колонки контейнера — чтобы full-bleed блоки
     (hero) выравнивались по той же вертикали, что и шапка с секциями */
  --edge: max(var(--gutter), calc((100vw - var(--container)) / 2 + var(--gutter)));
  --section-y: clamp(72px, 10vw, 168px);
  --header-h: 84px;
  --ease: cubic-bezier(.22, .61, .36, 1);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  font-size: 16px;
  font-weight: 400;
  line-height: 1.7;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img, svg { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }

.container {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

/* ---------- Типографика ---------- */

h1, h2, h3 {
  font-weight: 600;
  line-height: 1.12;
  letter-spacing: -.018em;
}

.section-label {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .24em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 26px;
}

.section-label::before {
  content: "";
  width: 28px;
  height: 1px;
  background: currentColor;
  flex-shrink: 0;
}

.section-title {
  font-size: clamp(27px, 3.5vw, 52px);
  max-width: 15em;
}

.lead {
  font-size: clamp(15px, 1.15vw, 17px);
  color: var(--ink-soft);
  max-width: 36em;
}

/* ---------- Кнопки ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 19px 44px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .2em;
  text-transform: uppercase;
  border: 1px solid var(--accent);
  background: var(--accent);
  color: #fff;
  cursor: pointer;
  transition: background .4s var(--ease), color .4s var(--ease), border-color .4s var(--ease);
}

.btn:hover { background: #C9510F; border-color: #C9510F; color: #fff; }

.btn--ghost { background: transparent; border-color: var(--ink); color: var(--ink); }
.btn--ghost:hover { background: var(--ink); color: #fff; }

/* компактный вариант — для шапки */
.btn--sm {
  padding: 13px 19px;
  font-size: 11px;
  letter-spacing: .12em;
  white-space: nowrap;
}

/* ---------- Шапка ---------- */

.header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 60;
  background: var(--bg);
  border-bottom: 1px solid transparent;
  transition: border-color .4s var(--ease);
}

.header.is-scrolled { border-bottom-color: var(--line); }

.header__in {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  height: var(--header-h);
}

.logo {
  display: flex;
  align-items: center;
  gap: 13px;
  flex-shrink: 0;
  padding: 8px 0; /* зона нажатия ~46px */
}

.logo__mark { width: 30px; color: var(--ink); }

.logo__text {
  font-size: 14px;
  font-weight: 600;
  letter-spacing: .2em;
  text-transform: uppercase;
  white-space: nowrap;
}

.nav { display: flex; gap: clamp(20px, 2.4vw, 44px); }

.nav a {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--ink-soft);
  padding: 11px 0;
  position: relative;
  transition: color .3s;
}

.nav a::after {
  content: "";
  position: absolute;
  left: 0; bottom: 7px;
  width: 100%;
  height: 1px;
  background: var(--ink);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform .4s var(--ease);
}

.nav a:hover { color: var(--ink); }
.nav a:hover::after { transform: scaleX(1); transform-origin: left; }

/* призыв-кнопка внутри меню не должна перенимать оформление пунктов */
.nav a.btn {
  padding: 17px 28px;
  font-size: 11px;
  letter-spacing: .2em;
  color: #fff;
}
.nav a.btn:hover { color: var(--ink); }
.nav a.btn::after { display: none; }

.header__contacts {
  display: flex;
  align-items: center;
  gap: clamp(10px, 1.2vw, 18px);
  flex-shrink: 0;
}

.header__phone {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: .04em;
  white-space: nowrap;
  padding: 12px 0;
  transition: color .3s;
}

.header__messengers { display: flex; gap: 6px; }

.header__messengers a {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  color: var(--ink);
  transition: background .35s var(--ease), border-color .35s var(--ease), color .35s var(--ease);
}

.header__messengers svg { width: 16px; height: 16px; fill: currentColor; }

.header__messengers a:hover { background: var(--ink); border-color: var(--ink); color: #fff; }

/* контакты внутри мобильного меню — на десктопе не нужны */
.nav__contacts { display: none; }

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

.burger {
  display: none;
  width: 44px; height: 44px;
  border: 0; background: none; cursor: pointer;
  flex-direction: column;
  align-items: center; justify-content: center;
  gap: 7px;
}

.burger span {
  width: 24px; height: 1px;
  background: var(--ink);
  transition: transform .4s var(--ease), opacity .3s;
}

.burger.is-open span:nth-child(1) { transform: translateY(4px) rotate(45deg); }
.burger.is-open span:nth-child(2) { opacity: 0; }
.burger.is-open span:nth-child(3) { transform: translateY(-4px) rotate(-45deg); }

/* ---------- Hero: архитектурный сплит ---------- */

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  min-height: 100svh;
  padding-top: var(--header-h);
}

.hero__text {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(48px, 7vw, 100px) clamp(24px, 3.4vw, 64px) clamp(48px, 7vw, 100px) var(--edge);
}

.hero__title {
  font-size: clamp(34px, 4.6vw, 72px);
  max-width: 11em;
  text-wrap: balance;
}

.hero__sub {
  margin-top: clamp(20px, 2.2vw, 30px);
  font-size: clamp(15px, 1.15vw, 17px);
  color: var(--ink-soft);
  max-width: 30em;
}

.hero__cta {
  margin-top: clamp(30px, 3.4vw, 48px);
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.hero__meta {
  margin-top: clamp(34px, 5vw, 64px);
  padding-top: 22px;
  border-top: 1px solid var(--line);
  display: flex;
  flex-wrap: wrap;
  gap: 10px 30px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--muted);
}

.hero__media {
  position: relative;
  overflow: hidden;
  background: var(--bg-deep);
}

/* снимок вертикальный: позиционируем абсолютно, иначе он растягивает
   hero по своей натуральной высоте и текст «проваливается» к центру */
.hero__media img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero__eyebrow {
  display: block;
  margin-bottom: clamp(18px, 2vw, 28px);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--muted);
}

/* ---------- Манифест ---------- */

.manifest { padding: var(--section-y) 0; }

.manifest__quote {
  font-size: clamp(21px, 2.5vw, 38px);
  font-weight: 600;
  line-height: 1.32;
  letter-spacing: -.015em;
  max-width: 22em;
  margin: 0 auto;
  text-align: center;
  text-wrap: balance;
}

/* ---------- Секции ---------- */

.section { padding: var(--section-y) 0; }
.section--soft { background: var(--bg-soft); }
.section--dark { background: var(--dark); color: #fff; }
.section--dark .section-label { color: rgba(255, 255, 255, .5); }

.section__head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 28px;
  margin-bottom: clamp(40px, 5.5vw, 80px);
}

/* ---------- Проекты ---------- */

.projects-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: clamp(20px, 2.6vw, 40px);
}

.project-card__media {
  position: relative;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  background: var(--bg-deep);
}

.project-card__media img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 1.2s var(--ease);
}

.project-card:hover .project-card__media img { transform: scale(1.04); }

.project-card__num {
  position: absolute;
  top: 0; left: 0;
  padding: 14px 18px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .2em;
  color: #fff;
  mix-blend-mode: difference;
}

.project-card__body {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  padding-top: 20px;
  margin-top: 20px;
  border-top: 1px solid var(--line);
}

.section--soft .project-card__body { border-top-color: #DEDEDE; }

.project-card__name {
  font-size: clamp(19px, 1.5vw, 24px);
  font-weight: 400;
  letter-spacing: -.01em;
}

.project-card__area {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--muted);
  white-space: nowrap;
}

.project-card__desc {
  margin-top: 8px;
  font-size: 14px;
  color: var(--ink-soft);
}

/* ---------- Философия ---------- */

.about {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(36px, 6vw, 100px);
  align-items: center;
}

.about__media {
  position: relative;
  aspect-ratio: 4 / 5;
  overflow: hidden;
  background: var(--bg-deep);
}

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

.about__text p {
  color: var(--ink-soft);
  margin-top: 18px;
  max-width: 34em;
}

.stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  margin-top: clamp(34px, 4.5vw, 56px);
  padding-top: clamp(26px, 3.4vw, 40px);
  border-top: 1px solid var(--line);
}

.stat__num {
  font-size: clamp(30px, 3.2vw, 46px);
  font-weight: 600;
  letter-spacing: -.02em;
}

.stat__label {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--muted);
  margin-top: 8px;
}

/* ---------- Услуги ---------- */

.services-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border-top: 1px solid var(--line);
  border-left: 1px solid var(--line);
}

.service {
  padding: clamp(28px, 2.8vw, 44px);
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  gap: 14px;
  background: var(--bg);
  transition: background .4s var(--ease);
}

.service:hover { background: var(--bg-soft); }

.service__num {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .2em;
  color: var(--muted);
}

.service h3 {
  font-size: clamp(18px, 1.5vw, 23px);
  font-weight: 400;
  letter-spacing: -.01em;
}

.service p {
  font-size: 14px;
  color: var(--ink-soft);
  flex-grow: 1;
}

.service__meta {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 14px;
  padding-top: 16px;
  border-top: 1px solid var(--line);
}

.service__meta dt {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--muted);
}

.service__meta dd {
  font-size: 13.5px;
  font-weight: 500;
  text-align: right;
}

.services-note {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: clamp(20px, 3vw, 48px);
  margin-top: clamp(28px, 3.4vw, 46px);
}

.services-note__text { max-width: 46em; }

.services-note__text .section-label { margin-bottom: 12px; }

.services-note__text p {
  font-size: clamp(14.5px, 1.05vw, 16px);
  color: var(--ink-soft);
}

/* ---------- Процесс ---------- */

.process__row {
  display: grid;
  grid-template-columns: 72px minmax(0, 3.2fr) minmax(0, 6fr);
  gap: clamp(16px, 3vw, 56px);
  padding: clamp(24px, 3vw, 40px) 0;
  border-top: 1px solid var(--line-dark);
  align-items: baseline;
}

.process__row:last-child { border-bottom: 1px solid var(--line-dark); }

.process__num {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .2em;
  color: rgba(255, 255, 255, .45);
}

.process__name {
  font-size: clamp(19px, 1.9vw, 28px);
  font-weight: 600;
  letter-spacing: -.015em;
}

.process__text {
  color: rgba(255, 255, 255, .62);
  font-size: 14.5px;
  max-width: 40em;
}

/* ---------- FAQ ---------- */

.faq { max-width: 900px; }

.faq details { border-top: 1px solid var(--line); }
.faq details:last-child { border-bottom: 1px solid var(--line); }

.faq summary {
  list-style: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 26px 2px;
  font-size: clamp(16px, 1.4vw, 20px);
  font-weight: 400;
  letter-spacing: -.01em;
  transition: color .3s;
}

.faq summary::-webkit-details-marker { display: none; }

.faq summary::after {
  content: "";
  width: 12px; height: 12px;
  flex-shrink: 0;
  background:
    linear-gradient(var(--ink), var(--ink)) center/12px 1px no-repeat,
    linear-gradient(var(--ink), var(--ink)) center/1px 12px no-repeat;
  transition: transform .4s var(--ease);
}

.faq details[open] summary::after { transform: rotate(135deg); }
.faq summary:hover { color: var(--accent); }

.faq .faq__a {
  padding: 0 2px 28px;
  color: var(--ink-soft);
  font-size: 15px;
  max-width: 46em;
}

.faq .faq__a a { text-decoration: underline; text-underline-offset: 3px; }

/* ---------- Контакты ---------- */

.contact {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: clamp(40px, 6vw, 110px);
  align-items: start;
}

.contact__info { display: flex; flex-direction: column; gap: 30px; }

.contact__label {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .2em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 8px;
}

.contact__row a, .contact__row p {
  display: inline-block;
  font-size: clamp(19px, 1.8vw, 26px);
  font-weight: 600;
  letter-spacing: -.015em;
  transition: color .3s;
}

.contact__row a { padding: 8px 0; }

/* Мессенджеры — монохромные кнопки в духе остального сайта */
.messengers {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 4px;
}

/* селектор с тегом — иначе более специфичное .contact__row a перебивает flex */
a.messenger {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 22px;
  border: 1px solid var(--line);
  background: var(--bg);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .16em;
  line-height: 1;
  text-transform: uppercase;
  white-space: nowrap;
  color: var(--ink);
  transition: background .35s var(--ease), border-color .35s var(--ease), color .35s var(--ease);
}

a.messenger svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  fill: currentColor;
}

a.messenger:hover {
  background: var(--ink);
  border-color: var(--ink);
  color: #fff;
}

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

.form {
  display: flex;
  flex-direction: column;
  gap: 24px;
  padding: clamp(28px, 3.4vw, 48px);
  background: var(--bg);
  border: 1px solid var(--line);
}

.form__field label {
  display: block;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 10px;
}

.form__field input,
.form__field textarea {
  width: 100%;
  padding: 12px 0;
  font: 400 15px/1.5 var(--font);
  color: var(--ink);
  background: transparent;
  border: 0;
  border-bottom: 1px solid var(--line);
  outline: none;
  transition: border-color .3s;
  resize: vertical;
}

.form__field input::placeholder,
.form__field textarea::placeholder { color: #B5B5B5; }

.form__field input:focus,
.form__field textarea:focus { border-color: var(--ink); }

.form__consent {
  font-size: 12px;
  line-height: 1.55;
  color: var(--muted);
  display: flex;
  gap: 10px;
  align-items: flex-start;
}

.form__consent a { text-decoration: underline; text-underline-offset: 2px; }

/* ловушка для спам-ботов: человек поля не видит, автозаполнялка — да */
.form__trap {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  border: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.form__done {
  display: none;
  padding: 16px 18px;
  background: var(--bg-soft);
  font-size: 14px;
  color: var(--ink);
}

.form.is-done .form__done { display: block; }

/* ---------- Фотоблок ---------- */

.photos {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: clamp(14px, 1.8vw, 24px);
}

.photos figure { margin: 0; }

.photos img {
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  display: block;
  filter: saturate(.92);
}

.photos figcaption {
  margin-top: 12px;
  font-size: 12.5px;
  line-height: 1.5;
  color: var(--muted);
}

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

/* ---------- Футер ---------- */

.footer {
  background: var(--dark);
  color: rgba(255, 255, 255, .6);
  padding: clamp(48px, 6vw, 80px) 0 clamp(30px, 3.4vw, 44px);
  font-size: 13px;
}

.footer__top {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: clamp(28px, 5vw, 70px);
  align-items: start;
  padding-bottom: clamp(32px, 4vw, 52px);
  border-bottom: 1px solid var(--line-dark);
}

.footer__logo { display: inline-flex; align-items: center; gap: 14px; color: #fff; }
.footer__logo svg { flex-shrink: 0; }
.footer__wordmark {
  font-size: 17px;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  white-space: nowrap;
}

.footer__nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0 30px;
  margin: -10px 0;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .18em;
  text-transform: uppercase;
}

.footer__nav a { padding: 12px 0; transition: color .3s; }
.footer a:hover { color: #fff; }

.footer__contact { display: flex; flex-direction: column; gap: 6px; align-items: flex-start; }

.footer__mail {
  display: inline-block;
  padding: 6px 0;
  font-size: 14px;
  color: rgba(255, 255, 255, .78);
  transition: color .3s;
}

.footer__messengers { display: flex; gap: 10px; margin-top: 12px; }

.footer__messengers a {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line-dark);
  color: rgba(255, 255, 255, .8);
  transition: background .35s var(--ease), color .35s var(--ease), border-color .35s var(--ease);
}

.footer__messengers svg { width: 18px; height: 18px; fill: currentColor; }

.footer__messengers a:hover { background: #fff; border-color: #fff; color: var(--dark); }

.footer__phone {
  display: inline-block;
  padding: 8px 0;
  font-size: clamp(17px, 1.5vw, 22px);
  font-weight: 600;
  letter-spacing: -.01em;
  color: #fff;
}

/* реквизиты юрлица — требование закона о защите прав потребителей */
.footer__legal {
  display: flex;
  flex-direction: column;
  gap: 4px;
  /* разделитель уже даёт border-bottom у .footer__top — своей линии не нужно */
  margin-top: clamp(20px, 2.6vw, 30px);
  font-size: 12px;
  line-height: 1.7;
  color: rgba(255, 255, 255, .45);
}

.footer__legal a {
  display: inline-block;
  padding: 10px 0;
  margin: -10px 0; /* зона нажатия ≥32px без раздувания вёрстки */
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: color .3s;
}
.footer__legal a:hover { color: #fff; }

.footer__bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-top: clamp(14px, 1.8vw, 20px);
  font-size: 12px;
}

/* зона нажатия для бейджа (сам бейдж-код не трогаем — padding задаётся снаружи) */
.footer__bottom a[href*="futureflow"] { padding: 12px 0; }

/* ---------- Страница проекта ---------- */

.project-hero { padding: calc(var(--header-h) + clamp(40px, 6vw, 84px)) 0 clamp(36px, 5vw, 64px); }

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 28px;
}

.breadcrumbs a { padding: 8px 0; margin: -8px 0; transition: color .3s; }
.breadcrumbs a:hover { color: var(--ink); }

.project-hero h1 {
  font-size: clamp(32px, 4.4vw, 68px);
}

/* смысловая часть заголовка — для читателя и для поиска */
.project-hero__sub {
  display: block;
  margin-top: 14px;
  font-size: clamp(13px, 1.15vw, 16px);
  font-weight: 400;
  letter-spacing: 0;
  line-height: 1.5;
  color: var(--ink-soft);
}

.project-facts {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: clamp(18px, 2.4vw, 40px);
  margin-top: clamp(30px, 4vw, 52px);
  padding-top: clamp(24px, 3vw, 34px);
  border-top: 1px solid var(--line);
}

.fact__label {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 8px;
}

.fact__value {
  font-size: clamp(15px, 1.25vw, 18px);
  font-weight: 400;
  letter-spacing: -.005em;
}

.project-gallery {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: clamp(16px, 2.2vw, 34px);
}

.project-gallery figure {
  overflow: hidden;
  cursor: zoom-in;
  background: var(--bg-deep);
}

.project-gallery figure.is-wide { grid-column: 1 / -1; }

.project-gallery img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 1.2s var(--ease);
}

.project-gallery figure:hover img { transform: scale(1.03); }

.project-about { max-width: 780px; }

.project-about p { color: var(--ink-soft); margin-top: 18px; }

.project-nav {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  margin-top: clamp(40px, 5vw, 64px);
  padding-top: clamp(28px, 3.4vw, 40px);
  border-top: 1px solid var(--line);
}

.project-nav a {
  padding: 12px 0;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--ink-soft);
  transition: color .3s;
}

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

/* ---------- Текстовая страница ---------- */

.text-page { max-width: 800px; }
.text-page__body { margin-top: clamp(26px, 3vw, 40px); display: flex; flex-direction: column; gap: 18px; }
.text-page__body p { color: var(--ink-soft); font-size: 15px; }
.text-page__body a { text-decoration: underline; text-underline-offset: 3px; }
.text-page__body h2 { margin-top: 22px; font-size: 19px; font-weight: 500; letter-spacing: -.01em; }
.text-page__body ul { margin: 0; padding-left: 20px; display: flex; flex-direction: column; gap: 8px; }
.text-page__body li { color: var(--ink-soft); font-size: 15px; }
.text-page__note { margin-top: 8px; padding: 16px 18px; background: var(--bg-soft); font-size: 13.5px; color: var(--muted); }

/* ---------- Плавающая кнопка связи (только смартфоны) ---------- */

.fab {
  position: fixed;
  right: clamp(14px, 4vw, 22px);
  bottom: clamp(14px, 4vw, 22px);
  z-index: 70;
  display: none;
  flex-direction: column;
  align-items: flex-end;
  gap: 10px;
  opacity: 0;
  transform: translateY(12px);
  /* видна сразу при загрузке страницы, с короткой задержкой на появление */
  animation: fabIn .5s var(--ease) .4s forwards;
}

@keyframes fabIn {
  to { opacity: 1; transform: none; }
}

/* прячем, когда открыто меню или модальное окно */
body.is-locked .fab {
  animation: none;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.fab__menu {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: opacity .3s var(--ease), transform .3s var(--ease), visibility .3s;
}

.fab.is-open .fab__menu { opacity: 1; visibility: visible; transform: none; }

.fab__item {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 48px;
  padding: 0 18px 0 14px;
  border: 1px solid var(--line);
  background: var(--bg);
  color: var(--ink);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: .14em;
  text-transform: uppercase;
  white-space: nowrap;
  box-shadow: 0 10px 30px -14px rgba(0, 0, 0, .35);
}

.fab__item svg { width: 18px; height: 18px; flex-shrink: 0; fill: currentColor; }

.fab__toggle {
  position: relative;
  width: 56px;
  height: 56px;
  display: grid;
  place-items: center;
  border: 0;
  background: var(--accent);
  color: #fff;
  cursor: pointer;
  box-shadow: 0 12px 30px -12px rgba(232, 100, 27, .6);
}

.fab__toggle svg { width: 22px; height: 22px; fill: currentColor; transition: transform .35s var(--ease); }
.fab.is-open .fab__toggle svg { transform: rotate(45deg); }

/* мягкая пульсация — привлекает внимание, но не мельтешит */
.fab__toggle::after {
  content: "";
  position: absolute;
  inset: 0;
  border: 1.5px solid var(--ink);
  animation: fabPulse 3.4s ease-out infinite;
  pointer-events: none;
}

.fab.is-open .fab__toggle::after { animation: none; }

@keyframes fabPulse {
  0%        { transform: scale(1);    opacity: .55; }
  70%, 100% { transform: scale(1.45); opacity: 0; }
}

@media (max-width: 999px) { .fab { display: flex; } }

@media (prefers-reduced-motion: reduce) {
  .fab, .fab__menu { transition: none; }
  .fab { animation: none; opacity: 1; transform: none; }
  .fab__toggle::after { animation: none; }
}

/* ---------- Модальное окно с формой ---------- */

.modal {
  position: fixed;
  inset: 0;
  z-index: 95;
  display: none;
  align-items: center;
  justify-content: center;
  padding: clamp(16px, 5vw, 40px);
}

.modal.is-open { display: flex; }

.modal__overlay {
  position: absolute;
  inset: 0;
  background: rgba(10, 10, 10, .55);
  backdrop-filter: blur(2px);
}

.modal__box {
  position: relative;
  width: min(460px, 100%);
  max-height: 92svh;
  overflow-y: auto;
  padding: clamp(26px, 5vw, 40px);
  background: var(--bg);
  border: 1px solid var(--line);
  animation: modalIn .35s var(--ease);
}

@keyframes modalIn {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: none; }
}

.modal__close {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border: 0;
  background: none;
  cursor: pointer;
  color: var(--muted);
  transition: color .3s;
}

.modal__close:hover { color: var(--ink); }

.modal__close::before,
.modal__close::after {
  content: "";
  position: absolute;
  width: 15px;
  height: 1px;
  background: currentColor;
}

.modal__close::before { transform: rotate(45deg); }
.modal__close::after  { transform: rotate(-45deg); }

.modal__title {
  font-size: clamp(21px, 2.6vw, 28px);
  font-weight: 600;
  letter-spacing: -.015em;
  padding-right: 36px;
}

.modal__text {
  margin-top: 12px;
  font-size: 14px;
  color: var(--ink-soft);
}

.modal__box:focus { outline: none; }

.modal .form {
  border: 0;
  padding: 0;
  margin-top: 26px;
  gap: 20px;
}

/* Телефоны: окно должно целиком помещаться на экране даже с открытой
   клавиатурой — поэтому всё поджато, а поля ввода 16px (меньший размер
   заставляет iOS зумить страницу при тапе в поле). */
@media (max-width: 640px) {
  .modal { padding: 16px; align-items: center; }
  .modal__box { padding: 22px 20px 24px; max-height: 88svh; overscroll-behavior: contain; }
  .modal__close { top: 6px; right: 6px; }
  .modal__title { font-size: 20px; padding-right: 34px; }
  .modal__text { margin-top: 8px; font-size: 13px; line-height: 1.45; }
  .modal .form { margin-top: 18px; gap: 15px; }
  .modal .form__field label { margin-bottom: 4px; }
  .modal .form__field input { padding: 9px 0; }
  .modal .form__consent { font-size: 11.5px; line-height: 1.45; gap: 9px; }
  .modal .form .btn { padding: 16px 24px; }
}

/* низкие экраны (ландшафт телефона): окно прокручивается, а не обрезается */
@media (max-height: 560px) {
  .modal { align-items: flex-start; padding: 12px; }
  .modal__box { max-height: calc(100svh - 24px); }
}

/* ландшафт телефона: места по высоте нет, зато есть по ширине —
   раскладываем поля в две колонки, чтобы кнопка попадала на экран */
@media (max-height: 560px) and (min-width: 640px) {
  .modal__box { width: min(620px, 100%); padding: 20px 24px 22px; }
  .modal__text { display: none; }
  .modal .form {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px 28px;
    margin-top: 16px;
  }
  .modal .form__consent,
  .modal .form .btn,
  .modal .form__done { grid-column: 1 / -1; }
}

@media (prefers-reduced-motion: reduce) {
  .modal__box { animation: none; }
}

/* ---------- Лайтбокс ---------- */

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 90;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 4vmin;
  background: rgba(10, 10, 10, .94);
  cursor: zoom-out;
}

.lightbox.is-open { display: flex; }

.lightbox img { max-width: 100%; max-height: 100%; object-fit: contain; }

/* ---------- Появление при скролле ---------- */

.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 1s var(--ease), transform 1s var(--ease);
}

.reveal.is-visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
}

/* ---------- Адаптив ---------- */

@media (max-width: 1180px) {
  .services-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 1024px) {
  :root { --header-h: 72px; }

  .projects-grid { grid-template-columns: repeat(2, 1fr); }
  .project-facts { grid-template-columns: repeat(2, 1fr); }

  .footer__top { grid-template-columns: 1fr; }
}

@media (max-width: 1024px) and (min-width: 641px) {
  .projects-grid .project-card:last-child:nth-child(odd) { grid-column: 1 / -1; }
  .projects-grid .project-card:last-child:nth-child(odd) .project-card__media { aspect-ratio: 16 / 9; }
}

@media (max-width: 999px) {
  .nav {
    position: fixed;
    inset: 0;
    z-index: -1;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    background: var(--bg);
    opacity: 0;
    pointer-events: none;
    transition: opacity .4s var(--ease);
  }

  /* крупные зоны нажатия в мобильном меню */
  .nav a { font-size: 13px; letter-spacing: .22em; padding: 15px 28px; }
  .nav a::after { display: none; }

  .header.is-menu-open .nav { opacity: 1; pointer-events: auto; z-index: 55; }
  .header.is-menu-open .logo { position: relative; z-index: 56; }

  .burger { display: flex; position: relative; z-index: 56; }
  .header__contacts { display: none; }

  /* телефон и мессенджеры переезжают в раскрытое меню */
  .nav__contacts {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 18px;
    margin-top: 26px;
    padding-top: 30px;
    border-top: 1px solid var(--line);
    width: min(280px, 68%);
  }

  .nav__phone {
    font-size: 17px;
    font-weight: 400;
    letter-spacing: 0;
    color: var(--ink);
    padding: 6px 0;
  }

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

  .nav__messengers a,
  .nav__messengers .messenger-btn {
    width: 48px;
    height: 48px;
    padding: 0; /* иначе отступ пунктов меню (.nav a) схлопывает иконку */
    display: grid;
    place-items: center;
    border: 1px solid var(--line);
    background: transparent;
    color: var(--ink);
    cursor: pointer;
  }

  .nav__messengers svg { width: 19px; height: 19px; fill: currentColor; }

  .nav__cta { width: 100%; justify-content: center; }
  .nav__messengers .messenger-btn svg { width: 19px; height: 19px; }
}

/* на средних экранах в шапке остаётся только главный призыв:
   телефон и мессенджеры не помещаются рядом с навигацией */
@media (min-width: 1000px) and (max-width: 1250px) {
  .header__phone,
  .header__messengers { display: none; }
}

@media (max-width: 900px) {
  /* hero складывается: фото сверху, текст снизу */
  .hero {
    grid-template-columns: 1fr;
    min-height: 0;
  }

  .hero__media { aspect-ratio: 4 / 3; order: -1; max-height: 66svh; }

  .hero__text { padding: clamp(36px, 7vw, 60px) 0; }
  .hero__text > * { padding-left: var(--gutter); padding-right: var(--gutter); }

  .about { grid-template-columns: 1fr; }
  .contact { grid-template-columns: 1fr; }

  .process__row { grid-template-columns: 44px 1fr; row-gap: 10px; }
  .process__text { grid-column: 2; }
}

@media (max-width: 640px) {
  .projects-grid { grid-template-columns: 1fr; }
  .services-grid { grid-template-columns: 1fr; }
  .stats { grid-template-columns: 1fr 1fr; gap: 24px 20px; }
  .project-facts { grid-template-columns: 1fr 1fr; }
  .project-gallery { grid-template-columns: 1fr; }
  .hero__media { aspect-ratio: 3 / 4; }
  .form { padding: 24px 20px; gap: 20px; }
  /* 16px — минимум, при котором iOS не зумит страницу при фокусе в поле */
  .form__field input,
  .form__field textarea { font-size: 16px; }
}

/* низкие экраны: ландшафт телефона и небольшие ноутбуки */
@media (max-width: 900px) and (max-height: 560px) {
  .hero__media { aspect-ratio: auto; height: 46svh; max-height: none; }
}

@media (min-width: 901px) and (max-height: 800px) {
  .hero__text { padding-top: clamp(32px, 4vw, 60px); padding-bottom: clamp(32px, 4vw, 60px); }
  .hero__cta { margin-top: clamp(20px, 2.4vw, 32px); }
  .hero__meta { margin-top: clamp(20px, 2.6vw, 34px); padding-top: 16px; }
}

@media (max-width: 380px) {
  .logo__text { font-size: 12px; letter-spacing: .16em; }
  .logo__mark { width: 26px; }
  .btn { padding: 17px 30px; }
}
