/* ==========================================================================
   Кьево — главная страница
   Дизайн-система: тёплая светлая база + глубокий чёрный, тонкие линии
   в духе логотипа, Manrope (лёгкие начертания) + курсив Cormorant для акцентов.
   ========================================================================== */

/* --------------------------------------------------------------------------
   Шрифты лежат на сайте (assets/fonts), а не на Google Fonts: данные посетителей
   не уходят в Google. Manrope и Cormorant Garamond — лицензия SIL Open Font License 1.1.
   Переменные шрифты: один файл на набор символов покрывает все начертания.
   -------------------------------------------------------------------------- */
/* Cormorant Garamond, cyrillic-ext */
@font-face {
  font-family: "Cormorant Garamond";
  font-style: italic;
  font-weight: 400 500;
  font-display: swap;
  src: url("../fonts/cormorant-garamond-italic-cyrillic-ext.woff2") format("woff2");
  unicode-range: U+0460-052F, U+1C80-1C8A, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F;
}
/* Cormorant Garamond, cyrillic */
@font-face {
  font-family: "Cormorant Garamond";
  font-style: italic;
  font-weight: 400 500;
  font-display: swap;
  src: url("../fonts/cormorant-garamond-italic-cyrillic.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
/* Cormorant Garamond, latin-ext */
@font-face {
  font-family: "Cormorant Garamond";
  font-style: italic;
  font-weight: 400 500;
  font-display: swap;
  src: url("../fonts/cormorant-garamond-italic-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* Cormorant Garamond, latin */
@font-face {
  font-family: "Cormorant Garamond";
  font-style: italic;
  font-weight: 400 500;
  font-display: swap;
  src: url("../fonts/cormorant-garamond-italic-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;
}
/* Manrope, cyrillic-ext */
@font-face {
  font-family: "Manrope";
  font-style: normal;
  font-weight: 200 600;
  font-display: swap;
  src: url("../fonts/manrope-cyrillic-ext.woff2") format("woff2");
  unicode-range: U+0460-052F, U+1C80-1C8A, U+20B4, U+2DE0-2DFF, U+A640-A69F, U+FE2E-FE2F;
}
/* Manrope, cyrillic */
@font-face {
  font-family: "Manrope";
  font-style: normal;
  font-weight: 200 600;
  font-display: swap;
  src: url("../fonts/manrope-cyrillic.woff2") format("woff2");
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
/* Manrope, latin-ext */
@font-face {
  font-family: "Manrope";
  font-style: normal;
  font-weight: 200 600;
  font-display: swap;
  src: url("../fonts/manrope-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
/* Manrope, latin */
@font-face {
  font-family: "Manrope";
  font-style: normal;
  font-weight: 200 600;
  font-display: swap;
  src: url("../fonts/manrope-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 {
  /* Цвета */
  --paper: #f4f2ee;
  --paper-2: #ebe8e2;
  --ink: #131312;
  --ink-2: #4b4843;
  --ink-3: #6f6a63;
  --line: rgba(19, 19, 18, 0.14);

  --night: #0e0e0d;
  --night-2: #191917;
  --on-night: #f2efe9;
  --on-night-2: rgba(242, 239, 233, 0.68);
  --line-night: rgba(242, 239, 233, 0.16);

  --accent: #e3a85f;      /* тёплый «сценический» свет */
  --danger: #f0a487;

  /* Типографика */
  --font-sans: "Manrope", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --font-serif: "Cormorant Garamond", "Times New Roman", Georgia, serif;

  /* Сетка и ритм */
  --maxw: 1440px;
  --gutter: clamp(20px, 4vw, 56px);
  --section-y: clamp(88px, 11vw, 168px);
  --header-h: 76px;
  --ease: cubic-bezier(0.2, 0.7, 0.1, 1);

  /* Толщина линий логотипа (наследуется внутрь <use>) */
  --logo-lw: 2.2;
  --logo-lw-circle: 2.4;
  --logo-lw-lines: 1.5;
}

/* --------------------------------------------------------------------------
   База
   -------------------------------------------------------------------------- */

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 8px);
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 1rem;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

img, svg { display: block; max-width: 100%; }
img { height: auto; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; }
p { margin: 0; }
h1, h2, h3 { margin: 0; font-weight: 300; }

:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

::selection { background: var(--accent); color: var(--night); }

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

.skip-link {
  position: fixed;
  top: 12px; left: 12px;
  z-index: 100;
  padding: 10px 18px;
  border-radius: 999px;
  background: var(--accent);
  color: var(--night);
  font-weight: 600;
  transform: translateY(-160%);
  transition: transform 0.3s var(--ease);
}
.skip-link:focus { transform: none; }

.container {
  width: 100%;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

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

.section--night {
  background: var(--night);
  color: var(--on-night);
}

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

.label {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 28px;
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.label__num {
  font-variant-numeric: tabular-nums;
  color: var(--ink);
}
.label__num::after {
  content: "";
  display: inline-block;
  width: 28px;
  height: 1px;
  margin-left: 12px;
  vertical-align: middle;
  background: currentColor;
  opacity: 0.5;
}
.section--night .label { color: var(--on-night-2); }
.section--night .label__num { color: var(--accent); }

.h2 {
  font-size: clamp(2.25rem, 4.6vw, 4.25rem);
  font-weight: 300;
  line-height: 1.04;
  letter-spacing: -0.035em;
  text-wrap: balance;
}

/* Курсивный акцент */
.h1 em,
.h2 em,
.statement em,
.serif {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  font-size: 1.1em;
  line-height: 0.9;
  letter-spacing: -0.01em;
}

.lead {
  font-size: clamp(1.0625rem, 1.3vw, 1.1875rem);
  line-height: 1.6;
  color: var(--ink-2);
}

/* Заголовок секции: метка слева, заголовок по сетке справа */
.section-head {
  display: grid;
  gap: 20px 32px;
  margin-bottom: clamp(48px, 7vw, 96px);
}
.section-head .label { margin: 0; }
.section-head__text {
  max-width: 52ch;
  color: var(--ink-2);
}
.section--night .section-head__text { color: var(--on-night-2); }

@media (min-width: 900px) {
  .section-head { grid-template-columns: repeat(12, minmax(0, 1fr)); align-items: end; }
  .section-head .label { grid-column: 1 / 4; align-self: start; padding-top: 1.1em; }
  .section-head .h2 { grid-column: 4 / 13; }
  .section-head__text { grid-column: 4 / 10; }
  .section-head__aside { grid-column: 10 / 13; justify-self: end; }
}

/* --------------------------------------------------------------------------
   Кнопки и ссылки
   -------------------------------------------------------------------------- */

.btn {
  --btn-bg: var(--ink);
  --btn-fg: var(--paper);
  --btn-border: var(--btn-bg);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  height: 54px;
  padding: 0 28px;
  border: 1px solid var(--btn-border);
  border-radius: 999px;
  background: var(--btn-bg);
  color: var(--btn-fg);
  font-size: 0.9375rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color 0.35s var(--ease), color 0.35s var(--ease), border-color 0.35s var(--ease);
}
.btn svg { width: 16px; height: 16px; flex: none; transition: transform 0.4s var(--ease); }
.btn:hover svg { transform: translateX(4px); }
.btn:hover { --btn-bg: #2a2926; }

.btn--light { --btn-bg: var(--on-night); --btn-fg: var(--night); }
.btn--light:hover { --btn-bg: var(--accent); }

.btn--ghost-light {
  --btn-bg: transparent;
  --btn-fg: var(--on-night);
  --btn-border: rgba(242, 239, 233, 0.38);
}
.btn--ghost-light:hover { --btn-bg: rgba(242, 239, 233, 0.08); --btn-border: var(--on-night); }

.btn--ghost {
  --btn-bg: transparent;
  --btn-fg: var(--ink);
  --btn-border: rgba(19, 19, 18, 0.3);
}
.btn--ghost:hover { --btn-bg: var(--ink); --btn-fg: var(--paper); --btn-border: var(--ink); }

.btn--sm { height: 44px; padding: 0 20px; font-size: 0.875rem; gap: 10px; }

.btn[disabled] { opacity: 0.6; cursor: progress; }

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 500;
  border-bottom: 1px solid currentColor;
  padding-bottom: 4px;
}
.link-arrow svg { width: 14px; height: 14px; transition: transform 0.4s var(--ease); }
.link-arrow:hover svg { transform: translateX(4px); }

/* Подчёркивание при наведении */
.u-line {
  background: linear-gradient(currentColor, currentColor) no-repeat 0 100% / 0 1px;
  transition: background-size 0.45s var(--ease);
}
.u-line:hover,
a:focus-visible .u-line { background-size: 100% 1px; }

/* --------------------------------------------------------------------------
   Логотип
   -------------------------------------------------------------------------- */

.logo { display: inline-flex; color: inherit; }
.logo svg { width: 128px; height: auto; overflow: visible; }

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

.header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 50;
  height: var(--header-h);
  color: var(--on-night);
  border-bottom: 1px solid transparent;
  transition: background-color 0.45s var(--ease), color 0.45s var(--ease),
              border-color 0.45s var(--ease), transform 0.5s var(--ease);
}
.header.is-solid {
  background: rgba(244, 242, 238, 0.88);
  -webkit-backdrop-filter: saturate(1.4) blur(16px);
  backdrop-filter: saturate(1.4) blur(16px);
  color: var(--ink);
  border-bottom-color: var(--line);
}
.header.is-solid.on-dark {
  background: rgba(14, 14, 13, 0.82);
  color: var(--on-night);
  border-bottom-color: var(--line-night);
}
.header.is-solid.on-dark .header__cta { --btn-bg: var(--on-night); --btn-fg: var(--night); --btn-border: var(--on-night); }
.header.is-hidden { transform: translateY(-100%); }

.header__inner {
  height: 100%;
  display: flex;
  align-items: center;
  gap: 24px;
}

.nav { display: none; margin-left: auto; }
.nav ul { display: flex; gap: clamp(16px, 1.4vw, 32px); list-style: none; margin: 0; padding: 0; }
.logo { flex: none; }
.nav a { font-size: 0.875rem; font-weight: 500; padding-block: 6px; }

.header__phone {
  display: none;
  font-size: 0.875rem;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.header__cta { display: none; }
.header.is-solid .header__cta { --btn-bg: var(--ink); --btn-fg: var(--paper); --btn-border: var(--ink); }

.header__tel-icon,
.burger {
  display: inline-grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border: 1px solid currentColor;
  border-radius: 50%;
  background: transparent;
  cursor: pointer;
  opacity: 0.9;
}
.header__tel-icon { margin-left: auto; }
.header__tel-icon svg { width: 18px; height: 18px; }

.burger { position: relative; }
.burger span {
  position: absolute;
  left: 50%;
  width: 18px;
  height: 1.5px;
  margin-left: -9px;
  background: currentColor;
  transition: transform 0.4s var(--ease), top 0.4s var(--ease);
}
.burger span:nth-child(1) { top: 17px; }
.burger span:nth-child(2) { top: 25px; }
.burger[aria-expanded="true"] span:nth-child(1) { top: 21px; transform: rotate(45deg); }
.burger[aria-expanded="true"] span:nth-child(2) { top: 21px; transform: rotate(-45deg); }

@media (min-width: 640px) {
  .header__cta { display: inline-flex; margin-left: auto; }
  .header__tel-icon { margin-left: 0; }
}

/* Полное меню — с 1100px. На ноутбуках с масштабированием Windows (1100–1279px)
   шапка компактная: номер телефона — значком, пункты меню плотнее */
@media (min-width: 1100px) {
  .nav { display: block; }
  .header__cta { margin-left: 0; }
  .burger { display: none; }
}
@media (min-width: 1100px) and (max-width: 1279.98px) {
  .header__inner { gap: 16px; }
  .nav ul { gap: 14px; }
  .nav a { font-size: 0.8125rem; }
  .nav .ny-mark { font-size: 0.75rem; letter-spacing: 0.06em; }
  .logo svg { width: 116px; }
}
@media (min-width: 1280px) {
  .header__phone { display: inline; }
  .header__tel-icon { display: none; }
  .logo svg { width: 136px; }
}

/* Мобильное меню */
.menu {
  position: fixed;
  inset: 0;
  z-index: 40;
  display: flex;
  flex-direction: column;
  padding: calc(var(--header-h) + 24px) var(--gutter) 32px;
  overflow-y: auto;
  background: var(--night);
  color: var(--on-night);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.4s var(--ease), visibility 0s linear 0.4s;
}
.menu-open { overflow: hidden; }
.menu-open .menu { opacity: 1; visibility: visible; transition: opacity 0.4s var(--ease); }
.menu-open .header { color: var(--on-night); background: transparent; border-bottom-color: transparent; transform: none; }
.menu-open .header .header__cta { display: none; }

.menu__nav ul { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line-night); }
.menu__nav li { border-bottom: 1px solid var(--line-night); }
.menu__nav a {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 0;
  font-size: clamp(1.75rem, 7vw, 2.75rem);
  font-weight: 300;
  letter-spacing: -0.03em;
  line-height: 1.1;
}
.menu__nav a svg { width: 20px; height: 20px; opacity: 0.5; }
.menu__foot { margin-top: auto; padding-top: 40px; display: grid; gap: 20px; }
.menu__phone { font-size: 1.5rem; font-weight: 300; letter-spacing: -0.02em; }
.menu__links { display: flex; flex-wrap: wrap; gap: 8px 20px; color: var(--on-night-2); }

/* --------------------------------------------------------------------------
   Hero
   -------------------------------------------------------------------------- */

.hero {
  position: relative;
  isolation: isolate;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  background: var(--night);
  color: var(--on-night);
  overflow: hidden;
}

.hero__media { position: absolute; inset: 0; z-index: -1; }
.hero__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 62% 40%;
  transform: scale(1.06);
  animation: hero-zoom 16s var(--ease) forwards;
}
.hero__media::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(14, 14, 13, 0.6) 0%, rgba(14, 14, 13, 0) 28%, rgba(14, 14, 13, 0.2) 52%, rgba(14, 14, 13, 0.92) 100%),
    linear-gradient(90deg, rgba(14, 14, 13, 0.55) 0%, rgba(14, 14, 13, 0) 65%);
}

/* Для светлых кадров — плотнее затемнение под текстом */
.hero--dim .hero__media::after {
  background:
    linear-gradient(180deg, rgba(14, 14, 13, 0.6) 0%, rgba(14, 14, 13, 0.25) 28%, rgba(14, 14, 13, 0.45) 52%, rgba(14, 14, 13, 0.94) 100%),
    linear-gradient(90deg, rgba(14, 14, 13, 0.75) 0%, rgba(14, 14, 13, 0.1) 70%);
}

@keyframes hero-zoom { to { transform: scale(1); } }

.hero__inner {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding-top: calc(var(--header-h) + 48px);
  padding-bottom: clamp(28px, 4vw, 48px);
}

.hero__eyebrow {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 14px;
  margin-bottom: clamp(20px, 2.4vw, 32px);
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--on-night-2);
}
.hero__eyebrow i {
  width: 5px; height: 5px;
  border-radius: 50%;
  background: var(--accent);
}

.h1 {
  font-size: clamp(2.6rem, 6.3vw, 6rem);
  font-weight: 300;
  line-height: 1;
  letter-spacing: -0.042em;
}
.h1 em { display: block; margin-top: 0.06em; color: var(--on-night); }

.hero__bottom {
  display: grid;
  gap: 28px;
  margin-top: clamp(36px, 5vw, 72px);
  padding-top: clamp(24px, 2.6vw, 32px);
  border-top: 1px solid var(--line-night);
}
.hero__lead { max-width: 44ch; color: var(--on-night-2); font-size: clamp(1rem, 1.2vw, 1.125rem); }
.hero__actions { display: flex; flex-wrap: wrap; gap: 12px; }
.hero__caption {
  font-size: 0.8125rem;
  color: var(--on-night-2);
  display: flex;
  align-items: center;
  gap: 10px;
}
.hero__caption::before {
  content: "";
  width: 24px; height: 1px;
  background: currentColor;
  opacity: 0.6;
}

@media (min-width: 900px) {
  .hero__bottom { grid-template-columns: repeat(12, minmax(0, 1fr)); align-items: end; gap: 32px; }
  .hero__bottom > .hero__lead { grid-column: 1 / 5; }
  .hero__bottom > .hero__actions { grid-column: 5 / 10; }
  .hero__bottom > .hero__caption { grid-column: 10 / 13; justify-content: flex-end; text-align: right; }
  .hero__caption::before { display: none; }
}

/* Группа кнопок вне первого экрана */
.actions { display: flex; flex-wrap: wrap; gap: 12px; }

@media (max-width: 899px) {
  .hero__actions .btn,
  .actions .btn { flex: 1 1 220px; }
}

/* Узкие телефоны: длинная надпись на кнопке переносится, а не вылезает за край */
@media (max-width: 380px) {
  .hero__actions .btn,
  .actions .btn,
  .form__footer .btn { height: auto; min-height: 54px; padding: 10px 18px; gap: 10px; white-space: normal; text-align: center; }
}

@media (max-width: 700px) {
  .hero__media::after {
    background: linear-gradient(180deg, rgba(14, 14, 13, 0.6) 0%, rgba(14, 14, 13, 0.25) 22%, rgba(14, 14, 13, 0.72) 50%, rgba(14, 14, 13, 0.95) 100%);
  }
  /* Кадр с лицом в верхней трети: на телефоне фото занимает верх экрана и плавно уходит в фон, текст не закрывает лицо */
  .hero--photo-top .hero__media img {
    height: 72%;
    -webkit-mask-image: linear-gradient(180deg, #000 68%, transparent);
    mask-image: linear-gradient(180deg, #000 68%, transparent);
  }
}

@media (max-width: 519px) {
  .hero__eyebrow-lead { display: none; }
}

/* --------------------------------------------------------------------------
   Об агентстве
   -------------------------------------------------------------------------- */

.intro__grid { display: grid; gap: 28px 32px; }

.statement {
  font-size: clamp(1.75rem, 3.5vw, 3.375rem);
  font-weight: 300;
  line-height: 1.14;
  letter-spacing: -0.028em;
  text-wrap: pretty;
}

.intro__aside { display: grid; gap: 28px; justify-items: start; }
.intro__aside p { max-width: 54ch; color: var(--ink-2); font-size: 1.0625rem; }
.intro__aside p + p { margin-top: -12px; }

@media (min-width: 900px) {
  .intro__grid { grid-template-columns: repeat(12, minmax(0, 1fr)); }
  .intro__grid > .label { grid-column: 1 / 4; padding-top: 1.1em; margin: 0; }
  .statement { grid-column: 4 / 13; }
  .intro__aside { grid-column: 7 / 13; margin-top: 24px; }
}

.facts {
  display: grid;
  margin: clamp(64px, 9vw, 128px) 0 0;
  padding: 0;
  list-style: none;
  border-top: 1px solid var(--line);
}
.fact { padding: 28px 0; border-bottom: 1px solid var(--line); }
.fact__value {
  display: block;
  font-size: clamp(3.5rem, 7vw, 6.5rem);
  font-weight: 200;
  line-height: 0.95;
  letter-spacing: -0.05em;
  font-variant-numeric: lining-nums;
}
.fact__label { display: block; margin-top: 16px; max-width: 26ch; color: var(--ink-2); }

@media (min-width: 700px) {
  .facts { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .fact { border-bottom: 0; padding: 32px 32px 0 0; }
  .fact + .fact { border-left: 1px solid var(--line); padding-left: 32px; }
}

/* --------------------------------------------------------------------------
   Направления
   -------------------------------------------------------------------------- */

.services__layout { display: grid; gap: 48px; }

.services__list { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.service { border-bottom: 1px solid var(--line); }

.service__link {
  position: relative;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 10px 20px;
  padding: clamp(24px, 3vw, 40px) 0;
}

.service__media {
  grid-column: 1 / -1;
  margin: 0 0 12px;
  aspect-ratio: 3 / 2;
  overflow: hidden;
  background: var(--paper-2);
}
.service__media img { width: 100%; height: 100%; object-fit: cover; }

.service__num {
  padding-top: 0.95em;
  font-size: 0.8125rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  color: var(--ink-3);
  font-variant-numeric: tabular-nums;
}

.service__title {
  display: block;
  font-size: clamp(1.875rem, 3.6vw, 3.25rem);
  font-weight: 300;
  line-height: 1.08;
  letter-spacing: -0.032em;
  transition: color 0.4s var(--ease), transform 0.6s var(--ease);
}
.service__title small {
  font-size: 0.42em;
  letter-spacing: 0.02em;
  color: var(--ink-3);
  vertical-align: 0.9em;
  margin-left: 6px;
}
.service__text { display: block; margin-top: 14px; max-width: 48ch; color: var(--ink-2); }
.service__tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 20px; }
.service__tags span {
  padding: 5px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 0.8125rem;
  color: var(--ink-2);
}

/* На мобильных стрелка лежит в углу фотографии */
.service__arrow {
  position: absolute;
  top: calc(clamp(24px, 3vw, 40px) + 14px);
  right: 14px;
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border: 1px solid transparent;
  border-radius: 50%;
  background: var(--paper);
  transition: background-color 0.4s var(--ease), color 0.4s var(--ease), border-color 0.4s var(--ease), transform 0.4s var(--ease);
}
.service__arrow svg { width: 16px; height: 16px; transform: rotate(-45deg); transition: transform 0.4s var(--ease); }

.service__link:hover .service__arrow {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--paper);
}
.service__link:hover .service__arrow svg { transform: rotate(0); }

.services__preview { display: none; }

@media (min-width: 1000px) {
  .service__link { grid-template-columns: auto minmax(0, 1fr) auto; gap: 10px 24px; }
  .service__arrow {
    position: static;
    width: 52px;
    height: 52px;
    margin-top: 0.3em;
    border-color: var(--line);
    background: transparent;
  }
  .service.is-active .service__arrow { background: var(--ink); border-color: var(--ink); color: var(--paper); }
  .service.is-active .service__arrow svg { transform: rotate(0); }

  .services__layout {
    grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
    gap: clamp(48px, 6vw, 112px);
    align-items: start;
  }
  .service__media { display: none; }
  .service.is-active .service__title { transform: translateX(10px); }
  .services__list:hover .service:not(:hover) .service__title { color: var(--ink-3); }

  .services__preview {
    display: block;
    position: sticky;
    top: calc(var(--header-h) + 24px);
  }
  .services__frame {
    position: relative;
    aspect-ratio: 4 / 5;
    overflow: hidden;
    background: var(--paper-2);
  }
  .services__frame img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0;
    transform: scale(1.06);
    transition: opacity 0.8s var(--ease), transform 1.4s var(--ease);
  }
  .services__frame img.is-active { opacity: 1; transform: scale(1); }
  .services__caption {
    display: flex;
    justify-content: space-between;
    margin-top: 16px;
    font-size: 0.8125rem;
    color: var(--ink-3);
    font-variant-numeric: tabular-nums;
  }
}

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

.projects__grid {
  display: grid;
  gap: 56px 32px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.project a { display: block; }

.project__media {
  position: relative;
  margin: 0;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: var(--night-2);
}
.project--portrait .project__media { aspect-ratio: 4 / 5; }
.project__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 1.4s var(--ease);
}
.project a:hover .project__media img { transform: scale(1.04); }

.project__go {
  position: absolute;
  right: 20px;
  bottom: 20px;
  display: grid;
  place-items: center;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--on-night);
  color: var(--night);
  transform: scale(0.6);
  opacity: 0;
  transition: transform 0.5s var(--ease), opacity 0.5s var(--ease);
}
.project__go svg { width: 18px; height: 18px; transform: rotate(-45deg); }
.project a:hover .project__go,
.project a:focus-visible .project__go { transform: none; opacity: 1; }

.project__meta { margin-top: 20px; }
.project__cat {
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
}
.project__title {
  margin: 10px 0 6px;
  max-width: 30ch;
  font-size: clamp(1.25rem, 1.9vw, 1.75rem);
  font-weight: 300;
  line-height: 1.22;
  letter-spacing: -0.02em;
}
.project__place { color: var(--on-night-2); font-size: 0.9375rem; }

@media (min-width: 800px) {
  .projects__grid { grid-template-columns: repeat(12, minmax(0, 1fr)); gap: clamp(56px, 7vw, 112px) clamp(20px, 2.4vw, 32px); }
  /* Узор из четырёх карточек повторяется; одиночная третья в конце встаёт справа, как четвёртая */
  .project:nth-child(4n+1) { grid-column: 1 / 8; }
  .project:nth-child(4n+2) { grid-column: 9 / 13; align-self: end; }
  .project:nth-child(4n+3) { grid-column: 2 / 6; }
  .project:nth-child(4n+4),
  .project:nth-child(4n+3):last-child { grid-column: 7 / 13; margin-top: clamp(64px, 10vw, 160px); }
}

/* --------------------------------------------------------------------------
   Как мы работаем
   -------------------------------------------------------------------------- */

.approach__grid { display: grid; gap: 56px; }

.approach__intro .h2 { margin-bottom: 0; }
.approach__media {
  margin: clamp(32px, 4vw, 56px) 0 0;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: var(--paper-2);
}
.approach__media img { width: 100%; height: 100%; object-fit: cover; }

.steps { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.step {
  display: grid;
  grid-template-columns: 56px minmax(0, 1fr);
  gap: 0 20px;
  padding: clamp(24px, 3vw, 36px) 0;
  border-bottom: 1px solid var(--line);
}
.step__num {
  padding-top: 0.55em;
  font-size: 0.8125rem;
  font-weight: 500;
  color: var(--ink-3);
  font-variant-numeric: tabular-nums;
}
.step__title {
  font-size: clamp(1.5rem, 2.4vw, 2.125rem);
  font-weight: 300;
  line-height: 1.15;
  letter-spacing: -0.025em;
}
.step__text { grid-column: 2; margin-top: 10px; max-width: 54ch; color: var(--ink-2); }

@media (min-width: 1000px) {
  .approach__grid { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(48px, 6vw, 112px); }
  .approach__intro { position: sticky; top: calc(var(--header-h) + 32px); align-self: start; }
  .steps { margin-top: 0.4em; }
  .step { grid-template-columns: 96px minmax(0, 1fr); }
}

/* --------------------------------------------------------------------------
   Клиенты
   -------------------------------------------------------------------------- */

.clients { background: var(--paper-2); }

.clients__grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--line);
  border-left: 1px solid var(--line);
  background: var(--paper-2); /* фон для mix-blend-mode у логотипов с белой подложкой */
}
.client {
  position: relative;
  aspect-ratio: 3 / 2;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.client img {
  position: absolute;
  top: 24%;
  left: 18%;
  width: 64%;
  height: 52%;
  object-fit: contain;
  mix-blend-mode: multiply;
  filter: grayscale(1) contrast(1.15);
  opacity: 0.7;
  transition: filter 0.5s var(--ease), opacity 0.5s var(--ease);
}
.client:hover img { filter: none; opacity: 1; }

@media (min-width: 640px) { .clients__grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (min-width: 1000px) { .clients__grid { grid-template-columns: repeat(6, minmax(0, 1fr)); } }

/* --------------------------------------------------------------------------
   Команда
   -------------------------------------------------------------------------- */

/* Фото и подписи по центру; неполный последний ряд тоже встаёт по центру */
.team__grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 40px 16px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.person { flex: 0 0 calc((100% - 16px) / 2 - 1px); text-align: center; }
.person__photo {
  width: min(100%, 220px);
  margin: 0 auto 18px;
  aspect-ratio: 1;
  overflow: hidden;
  border-radius: 50%;
  clip-path: circle(50%); /* обрезает и увеличенное при наведении фото */
  background: var(--paper-2);
}
.person__photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: grayscale(1) contrast(1.05);
  transition: filter 0.7s var(--ease), transform 1.2s var(--ease);
}
.person:hover .person__photo img { filter: grayscale(0); transform: scale(1.03); }
.person__name { font-size: 1.0625rem; font-weight: 500; letter-spacing: -0.01em; line-height: 1.3; }
.person__role { margin-top: 4px; font-size: 0.875rem; color: var(--ink-3); }

@media (min-width: 700px) {
  .team__grid { gap: 56px 24px; }
  .person { flex-basis: calc((100% - 48px) / 3 - 1px); }
}
@media (min-width: 1200px) { .person { flex-basis: calc((100% - 96px) / 5 - 1px); } }

/* --------------------------------------------------------------------------
   Заявка / расчёт стоимости
   -------------------------------------------------------------------------- */

.brief__grid { display: grid; gap: 56px; }

.brief__intro .h2 { margin-bottom: 24px; }
.brief__intro > p { max-width: 44ch; color: var(--on-night-2); }
.brief__intro > p a { color: var(--on-night); text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }

.contact-list {
  list-style: none;
  margin: clamp(32px, 4vw, 56px) 0 0;
  padding: 0;
  border-top: 1px solid var(--line-night);
}
.contact-list li { border-bottom: 1px solid var(--line-night); }
.contact-list a {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 18px 0;
  transition: color 0.3s var(--ease);
}
.contact-list a:hover { color: var(--accent); }
.contact-list span:first-child { font-size: 0.8125rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--on-night-2); }
.contact-list strong { font-weight: 400; font-size: 1.0625rem; }

@media (min-width: 1000px) {
  .brief__grid { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(48px, 6vw, 112px); }
}

.form { display: grid; gap: clamp(32px, 3.4vw, 44px); }
.form__group { margin: 0; padding: 0; border: 0; min-width: 0; }
.form__legend {
  margin-bottom: 14px;
  padding: 0;
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--on-night-2);
}
.form__legend small { text-transform: none; letter-spacing: 0; font-size: 0.8125rem; opacity: 0.8; }

.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { position: relative; display: inline-flex; }
.chip input {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  opacity: 0;
  cursor: pointer;
}
.chip span {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 8px 18px;
  border: 1px solid var(--line-night);
  border-radius: 999px;
  font-size: 0.9375rem;
  line-height: 1.3;
  user-select: none;
  transition: background-color 0.3s var(--ease), color 0.3s var(--ease), border-color 0.3s var(--ease);
}
.chip:hover span { border-color: rgba(242, 239, 233, 0.5); }
.chip input:checked + span { background: var(--on-night); border-color: var(--on-night); color: var(--night); }
.chip input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }

.fields { display: grid; gap: 8px 28px; }
@media (min-width: 640px) {
  .fields { grid-template-columns: 1fr 1fr; }
  .field--full { grid-column: 1 / -1; }
}

.field { position: relative; }
.field input,
.field textarea {
  display: block;
  width: 100%;
  padding: 28px 0 10px;
  border: 0;
  border-bottom: 1px solid var(--line-night);
  border-radius: 0;
  background: transparent;
  color: var(--on-night);
  font: inherit;
  font-size: 1.0625rem;
  outline: none;
  transition: border-color 0.3s var(--ease);
}
.field textarea { min-height: 96px; resize: vertical; }
.field label {
  position: absolute;
  left: 0;
  top: 28px;
  color: var(--on-night-2);
  pointer-events: none;
  transform-origin: left top;
  transition: transform 0.3s var(--ease), color 0.3s var(--ease);
}
.field input:focus,
.field textarea:focus { border-bottom-color: var(--on-night); }
.field input:focus + label,
.field input:not(:placeholder-shown) + label,
.field textarea:focus + label,
.field textarea:not(:placeholder-shown) + label { transform: translateY(-22px) scale(0.78); }
.field.is-invalid input { border-bottom-color: var(--danger); }
.field.is-invalid label { color: var(--danger); }

.check {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  font-size: 0.875rem;
  line-height: 1.5;
  color: var(--on-night-2);
  cursor: pointer;
}
.check input {
  appearance: none;
  -webkit-appearance: none;
  display: grid;
  place-items: center;
  flex: none;
  width: 20px;
  height: 20px;
  margin: 1px 0 0;
  border: 1px solid rgba(242, 239, 233, 0.45);
  border-radius: 5px;
  cursor: pointer;
  transition: background-color 0.3s var(--ease), border-color 0.3s var(--ease);
}
.check input:checked { background: var(--on-night); border-color: var(--on-night); }
.check input:checked::after {
  content: "";
  width: 10px;
  height: 5px;
  border-left: 1.6px solid var(--night);
  border-bottom: 1.6px solid var(--night);
  transform: translateY(-1px) rotate(-45deg);
}
.check a { color: var(--on-night); text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }
.check.is-invalid input { border-color: var(--danger); }
.check.is-invalid { color: var(--danger); }

.form__footer { display: flex; flex-wrap: wrap; align-items: center; gap: 20px 28px; }
.form__status { min-height: 1.5em; font-size: 0.9375rem; color: var(--on-night-2); }
.form__status.is-error { color: var(--danger); }
.form__status.is-success { color: var(--accent); }

/* --------------------------------------------------------------------------
   Подвал
   -------------------------------------------------------------------------- */

.footer {
  background: var(--night);
  color: var(--on-night);
  padding-top: clamp(72px, 9vw, 128px);
  border-top: 1px solid var(--line-night);
}

.footer__top { display: grid; gap: 16px; }
.footer__kicker { color: var(--on-night-2); }
.footer__phone {
  justify-self: start;
  font-size: clamp(2.5rem, 7vw, 6rem);
  font-weight: 200;
  line-height: 1;
  letter-spacing: -0.045em;
  font-variant-numeric: lining-nums;
  transition: color 0.35s var(--ease);
}
.footer__phone:hover { color: var(--accent); }

.footer__grid {
  display: grid;
  gap: 40px 32px;
  margin-top: clamp(56px, 7vw, 96px);
  padding-top: 40px;
  border-top: 1px solid var(--line-night);
}
.footer__title {
  margin-bottom: 16px;
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--on-night-2);
}
.footer__list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.footer address { font-style: normal; color: var(--on-night); line-height: 1.6; }

@media (min-width: 640px) { .footer__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1100px) { .footer__grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }

.footer__wordmark {
  --logo-lw: 1.1;
  --logo-lw-circle: 1.2;
  --logo-lw-lines: 0.8;
  margin-top: clamp(64px, 9vw, 128px);
  color: var(--on-night);
}
.footer__wordmark svg { width: 100%; height: auto; overflow: visible; }
@media (min-width: 900px) {
  .footer__wordmark { --logo-lw: 0.55; --logo-lw-circle: 0.6; --logo-lw-lines: 0.42; }
}

.footer__bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px 32px;
  margin-top: clamp(32px, 4vw, 56px);
  padding: 24px 0 32px;
  border-top: 1px solid var(--line-night);
  font-size: 0.8125rem;
  color: var(--on-night-2);
}
.footer__bottom a:hover { color: var(--on-night); }
.footer__docs { display: flex; flex-wrap: wrap; gap: 8px 28px; margin: 0; padding: 0; list-style: none; }
.footer__docs button { padding: 0; border: 0; background: none; color: inherit; font: inherit; cursor: pointer; }
.footer__docs button:hover { color: var(--on-night); }

/* Баннер о cookie (создаёт counters.js). Справа внизу, чтобы не закрывать кнопки первого экрана,
   и поверх всего остального, пока посетитель не сделал выбор */
.cookie {
  position: fixed;
  right: var(--gutter);
  bottom: 24px;
  z-index: 2147483000;
  display: grid;
  gap: 16px;
  width: min(440px, calc(100% - 24px));
  padding: 22px 24px 24px;
  border: 1px solid var(--line-night);
  background: var(--night-2);
  color: var(--on-night);
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
  animation: cookie-in 0.6s var(--ease) both;
}
.cookie[hidden] { display: none; }
.cookie__text { margin: 0; font-size: 0.875rem; line-height: 1.55; color: var(--on-night-2); }
.cookie__text a { color: var(--on-night); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
.cookie__actions { display: flex; flex-wrap: wrap; gap: 8px; }
.cookie__actions .btn { flex: 1 1 140px; }
@keyframes cookie-in { from { opacity: 0; transform: translateY(16px); } }

/* --------------------------------------------------------------------------
   «Новый год 2027» в меню: надпись в гирляндах.
   Лампочки (span.garland > i) добавляет main.js к элементу [data-garland].
   --bulb — ширина лампочки, --step — шаг лампочек и период провода
   -------------------------------------------------------------------------- */
.ny-mark {
  --bulb: 5px;
  --step: 13px;
  position: relative;
  display: inline-block;
  padding: calc(var(--bulb) * 2.6) 2px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  white-space: nowrap;
}
.nav .ny-mark { font-size: 0.8125rem; }
.nav .ny-link { padding-block: 0; }
.nav ul { align-items: center; }
.nav .ny-link[aria-current="page"] .ny-mark { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 4px; }
.menu__nav .ny-mark { --bulb: 7px; --step: 19px; font-size: 0.72em; font-weight: 400; letter-spacing: 0.05em; }

.garland {
  position: absolute;
  left: 50%;
  width: calc(100% + var(--step));
  width: round(down, calc(100% + var(--step)), var(--step));
  height: calc(var(--bulb) * 2.4);
  display: flex;
  gap: calc(var(--step) - var(--bulb));
  padding-left: calc((var(--step) - var(--bulb)) / 2);
  overflow: hidden;
  transform: translateX(-50%);
  pointer-events: none;
  /* провод: провисает между лампочками */
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 14 7' preserveAspectRatio='none'%3E%3Cpath d='M0 1Q7 9 14 1' fill='none' stroke='%238a9c80' stroke-width='1' vector-effect='non-scaling-stroke'/%3E%3C/svg%3E") repeat-x 0 0 / var(--step) calc(var(--bulb) * 1.3);
}
.garland--top { top: 0; }
.garland--bottom { bottom: 0; }
.garland i {
  flex: none;
  width: var(--bulb);
  height: calc(var(--bulb) * 1.35);
  margin-top: calc(var(--bulb) * 0.8);
  border-radius: 45% 45% 50% 50% / 35% 35% 65% 65%;
  background: currentColor;
  color: #ff5a4e;
  box-shadow: 0 0 calc(var(--bulb) * 1.2) calc(var(--bulb) * 0.15) currentColor;
  animation: bulb-twinkle 1.8s ease-in-out infinite alternate;
}
.garland i:nth-child(4n+2) { color: #ffcf5c; animation-delay: -0.45s; }
.garland i:nth-child(4n+3) { color: #47d18c; animation-delay: -0.9s; }
.garland i:nth-child(4n) { color: #59b6ff; animation-delay: -1.35s; }
.garland--bottom i { animation-direction: alternate-reverse; }
.ny-link:hover .garland i { animation-duration: 0.7s; }
@keyframes bulb-twinkle {
  0%, 25% { opacity: 0.35; box-shadow: 0 0 0 0 currentColor; }
  100% { opacity: 1; }
}
@media (prefers-reduced-motion: reduce) {
  .garland i { animation: none; }
}
@media (max-width: 600px) {
  .cookie { left: 12px; right: 12px; bottom: 12px; width: auto; padding: 18px 18px 20px; }
}

/* --------------------------------------------------------------------------
   Страницы направлений
   -------------------------------------------------------------------------- */

.nav a[aria-current="page"] { background-size: 100% 1px; }
.menu__nav a[aria-current="page"] { color: var(--accent); }

.breadcrumbs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 clamp(20px, 2.4vw, 32px);
  padding: 0;
  list-style: none;
  font-size: 0.8125rem;
  color: var(--on-night-2);
}
.breadcrumbs li + li::before { content: "/"; margin-right: 8px; opacity: 0.5; }
.breadcrumbs a { transition: color 0.3s var(--ease); }
.breadcrumbs a:hover { color: var(--on-night); }

.section--tight { padding-block: clamp(40px, 5vw, 72px); }
.section--alt { background: var(--paper-2); }

/* Полоса цифр под первым экраном */
.stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin: 0;
  padding: 0;
  list-style: none;
}
.stat { padding: 20px 16px 20px 0; border-top: 1px solid var(--line); }
.stat__value {
  display: block;
  font-size: clamp(2.25rem, 3.6vw, 3.25rem);
  font-weight: 200;
  line-height: 1;
  letter-spacing: -0.045em;
}
.stat__label { display: block; margin-top: 10px; max-width: 26ch; font-size: 0.9375rem; color: var(--ink-2); }

@media (min-width: 900px) {
  .stats { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .stat { padding: 28px 28px 8px 0; }
  .stat + .stat { padding-left: 28px; border-left: 1px solid var(--line); }
}

/* Плитки с тонкими линиями: форматы, условия */
.tiles {
  display: grid;
  margin: 0;
  padding: 0;
  list-style: none;
  border-top: 1px solid var(--line);
}
.tile {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 28px 0 32px;
  border-bottom: 1px solid var(--line);
}
.tile__num { font-size: 0.8125rem; font-weight: 500; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.tile__title { font-size: clamp(1.5rem, 2.2vw, 1.875rem); font-weight: 300; line-height: 1.15; letter-spacing: -0.025em; }
.tile__text { color: var(--ink-2); max-width: 44ch; }
.tile__note { margin-top: auto; padding-top: 12px; font-size: 0.875rem; color: var(--ink-3); }
.tile__note b { font-weight: 500; color: var(--ink-2); }

@media (min-width: 700px) {
  .tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); border-left: 1px solid var(--line); }
  .tile { padding: 36px 32px 36px; border-right: 1px solid var(--line); }
}
@media (min-width: 1100px) {
  .tiles--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .tiles--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}

/* Кейсы: факты-чипсы под заголовком */
.project__facts { display: flex; flex-wrap: wrap; gap: 6px; margin: 14px 0 0; padding: 0; list-style: none; }
.project__facts li {
  padding: 4px 11px;
  border: 1px solid var(--line-night);
  border-radius: 999px;
  font-size: 0.8125rem;
  color: var(--on-night-2);
}

/* Что входит */
.included {
  display: grid;
  column-gap: 56px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.included li {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr);
  gap: 4px 16px;
  padding: 22px 0;
  border-bottom: 1px solid var(--line);
}
.included li:first-child { border-top: 1px solid var(--line); }
.included__num { padding-top: 0.3em; font-size: 0.8125rem; font-weight: 500; color: var(--ink-3); font-variant-numeric: tabular-nums; }
.included__title { font-size: 1.1875rem; font-weight: 500; letter-spacing: -0.01em; line-height: 1.35; }
.included__text { grid-column: 2; color: var(--ink-2); font-size: 0.9375rem; }

@media (min-width: 800px) {
  .included { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .included li:nth-child(2) { border-top: 1px solid var(--line); }
}

/* Артисты и ведущие — типографический список */
.names {
  display: flex;
  flex-wrap: wrap;
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: clamp(1.75rem, 4.2vw, 3.75rem);
  font-weight: 200;
  line-height: 1.2;
  letter-spacing: -0.035em;
}
.names li { display: inline-flex; align-items: center; }
.names li:not(:last-child)::after {
  content: "";
  flex: none;
  width: 0.13em;
  height: 0.13em;
  margin: 0 0.42em;
  border-radius: 50%;
  background: var(--accent);
}
.names--small { font-size: clamp(1.25rem, 2.3vw, 1.875rem); font-weight: 300; color: var(--on-night-2); }

@media (max-width: 699px) {
  .names { flex-direction: column; }
  .names li::after { display: none; }
}
.names__label { margin: clamp(40px, 5vw, 64px) 0 16px; }
.artists__note { margin-top: clamp(40px, 5vw, 64px); max-width: 56ch; color: var(--on-night-2); }

/* Артисты с фото: снимок слева, имена справа */
.artists__layout { display: grid; gap: clamp(40px, 5vw, 64px); }
.artists__photo { margin: 0; max-width: 420px; }
.artists__photo img { width: 100%; height: auto; aspect-ratio: 4 / 5; object-fit: cover; }
.artists__photo figcaption { margin-top: 14px; font-size: 0.875rem; color: var(--on-night-2); }
.artists__layout .names__label:first-child { margin-top: 0; }

@media (min-width: 900px) {
  .artists__layout { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); align-items: start; gap: clamp(48px, 6vw, 96px); }
  .artists__photo { max-width: none; }
}

/* Площадки */
.venues { display: grid; gap: 48px; }
.venues__list { margin: 0; padding: 0; list-style: none; border-top: 1px solid var(--line); }
.venues__list li {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 20px;
  padding: 16px 0;
  border-bottom: 1px solid var(--line);
  font-size: 1.125rem;
}
.venues__list span { flex: none; max-width: 52%; text-align: right; font-size: 0.875rem; color: var(--ink-3); }
.venues .label { margin-bottom: 16px; }

@media (min-width: 900px) {
  .venues { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 64px; }
}

/* Блок «фото + текст» */
.feature { display: grid; gap: 40px; align-items: center; }
.feature__media { margin: 0; aspect-ratio: 4 / 3; overflow: hidden; background: var(--night-2); }
.feature__media img { width: 100%; height: 100%; object-fit: cover; }
.feature__text { display: grid; gap: 24px; justify-items: start; }
.feature__text .label { margin: 0; }
.feature__text p { max-width: 52ch; color: var(--ink-2); }
.section--night .feature__text p { color: var(--on-night-2); }
/* Что клиент получает и в какой срок */
.feature__points { width: 100%; max-width: 52ch; margin: 0; padding: 0; list-style: none; border-top: 1px solid var(--line-night); }
.feature__points li { display: grid; grid-template-columns: 5.5em minmax(0, 1fr); gap: 16px; padding: 14px 0; border-bottom: 1px solid var(--line-night); }
.feature__points b { font-weight: 500; color: var(--accent); }

@media (min-width: 1000px) {
  .feature { grid-template-columns: minmax(0, 6fr) minmax(0, 5fr); gap: clamp(48px, 6vw, 112px); }
}

/* Промо-блок с фотографией */
.promo {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  background: var(--night);
  color: var(--on-night);
}
.promo__media { position: absolute; inset: 0; z-index: -1; }
.promo__media img { width: 100%; height: 100%; object-fit: cover; }
.promo__media::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(14, 14, 13, 0.92) 0%, rgba(14, 14, 13, 0.7) 45%, rgba(14, 14, 13, 0.25) 100%);
}
.promo__inner {
  display: grid;
  gap: 24px;
  justify-items: start;
  padding-block: clamp(96px, 12vw, 176px);
}
.promo__inner > * { max-width: 640px; }
.promo__inner p { color: var(--on-night-2); font-size: clamp(1rem, 1.2vw, 1.125rem); }
.promo .label { margin-bottom: 0; color: var(--on-night-2); }
.promo .label__num { color: var(--accent); }

/* Стоимость */
.prices { border-top: 1px solid var(--line); }
.price {
  display: grid;
  gap: 8px 32px;
  padding: 28px 0;
  border-bottom: 1px solid var(--line);
}
.price__name { font-size: clamp(1.375rem, 2vw, 1.75rem); font-weight: 300; line-height: 1.2; letter-spacing: -0.02em; }
.price__guests { display: block; margin-top: 6px; font-size: 0.875rem; color: var(--ink-3); }
.price__desc { color: var(--ink-2); }
.price__value { font-size: clamp(1.25rem, 1.8vw, 1.5rem); font-weight: 400; letter-spacing: -0.01em; white-space: nowrap; }
.price__value small { display: block; font-size: 0.8125rem; color: var(--ink-3); letter-spacing: 0; }

@media (min-width: 900px) {
  .price { grid-template-columns: minmax(0, 4fr) minmax(0, 5fr) minmax(0, 3fr); align-items: baseline; }
  .price__value { text-align: right; }
}

.factors { display: flex; flex-wrap: wrap; gap: 8px; margin: 28px 0 0; padding: 0; list-style: none; }
.factors li { padding: 6px 14px; border: 1px solid var(--line); border-radius: 999px; font-size: 0.875rem; color: var(--ink-2); }
.section--night .factors li { border-color: var(--line-night); color: var(--on-night-2); }
.feature__text .factors { margin-top: 4px; }
.prices__footer { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 24px; margin-top: 36px; }
.fineprint { font-size: 0.8125rem; color: var(--ink-3); }

/* Значение, которое ещё нужно заполнить (видно на странице, чтобы не забыть) */
.todo { outline: 1px dashed var(--accent); outline-offset: 3px; border-radius: 2px; }

/* Примеры программ (выездные мероприятия) */
.programs { display: grid; gap: 20px; margin: 0; padding: 0; list-style: none; }
.program {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: clamp(24px, 2.6vw, 36px) clamp(22px, 2.2vw, 32px);
  border: 1px solid var(--line);
  background: var(--paper);
}
.program__place { font-size: 0.75rem; font-weight: 500; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-3); }
.program__title { font-size: clamp(1.5rem, 2.2vw, 1.875rem); font-weight: 300; line-height: 1.15; letter-spacing: -0.025em; }
.program__days { display: grid; gap: 14px; margin: 0; padding: 16px 0 0; list-style: none; border-top: 1px solid var(--line); }
.program__days li { font-size: 0.9375rem; color: var(--ink-2); }
.program__days b {
  display: block;
  margin-bottom: 2px;
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink);
}
.program__price { margin-top: auto; padding-top: 16px; border-top: 1px solid var(--line); font-size: 1.25rem; }
.program__price small { font-size: 0.8125rem; color: var(--ink-3); }

@media (min-width: 900px) {
  .programs { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

/* Вопросы и ответы */
.faq-layout { display: grid; gap: 40px; }
.faq { border-top: 1px solid var(--line); }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
  padding: 24px 0;
  list-style: none;
  cursor: pointer;
  font-size: clamp(1.125rem, 1.6vw, 1.375rem);
  line-height: 1.35;
  letter-spacing: -0.01em;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "";
  flex: none;
  width: 14px;
  height: 14px;
  background:
    linear-gradient(currentColor, currentColor) center / 100% 1.4px no-repeat,
    linear-gradient(currentColor, currentColor) center / 1.4px 100% no-repeat;
  transition: transform 0.35s var(--ease);
}
.faq details[open] summary::after { transform: rotate(45deg); }
.faq__answer { max-width: 68ch; padding: 0 0 26px; color: var(--ink-2); }
.faq__answer a { color: var(--ink); text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }

@media (min-width: 1000px) {
  .faq-layout { grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); gap: clamp(48px, 6vw, 112px); }
  .faq-layout .section-head { display: block; margin: 0; }
  .faq-layout .section-head .label { margin-bottom: 28px; padding: 0; }
}

/* Компактная сетка логотипов (12 штук) */
.clients--compact .clients__grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (min-width: 640px) { .clients--compact .clients__grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (min-width: 1000px) { .clients--compact .clients__grid { grid-template-columns: repeat(6, minmax(0, 1fr)); } }

/* --------------------------------------------------------------------------
   Портфолио
   -------------------------------------------------------------------------- */

/* Тёмная шапка страницы без фотографии */
.page-head {
  background: var(--night);
  color: var(--on-night);
  padding: calc(var(--header-h) + clamp(56px, 8vw, 128px)) 0 clamp(32px, 4vw, 48px);
}
.page-head__grid { display: grid; gap: 24px 32px; }
.page-head__lead { max-width: 46ch; color: var(--on-night-2); font-size: clamp(1rem, 1.2vw, 1.125rem); }
@media (min-width: 1000px) {
  .page-head__grid { grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); align-items: end; }
}

.filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: clamp(40px, 5vw, 72px);
  padding-top: 28px;
  border-top: 1px solid var(--line-night);
}
.filter {
  min-height: 44px;
  padding: 8px 20px;
  border: 1px solid var(--line-night);
  border-radius: 999px;
  background: transparent;
  color: var(--on-night-2);
  font-size: 0.9375rem;
  cursor: pointer;
  transition: background-color 0.3s var(--ease), color 0.3s var(--ease), border-color 0.3s var(--ease);
}
.filter:hover { border-color: rgba(242, 239, 233, 0.5); color: var(--on-night); }
a.filter { display: inline-flex; align-items: center; }
.filter--primary,
.filter--primary:hover { background: var(--on-night); border-color: var(--on-night); color: var(--night); }
.filter[aria-pressed="true"] { background: var(--on-night); border-color: var(--on-night); color: var(--night); }

.cases { padding-top: clamp(32px, 4vw, 56px); }

.case-grid {
  display: grid;
  gap: clamp(40px, 4vw, 64px) clamp(16px, 2vw, 28px);
  margin: 0;
  padding: 0;
  list-style: none;
}
@media (min-width: 640px) { .case-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1100px) { .case-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (min-width: 1100px) { .case-grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

.case-card[hidden] { display: none; }
.case-card a { display: block; }
.case-card__media {
  position: relative;
  margin: 0;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: var(--night-2);
}
.case-card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform 1.2s var(--ease); }
.case-card a:hover .case-card__media img { transform: scale(1.04); }
.case-card a:hover .project__go,
.case-card a:focus-visible .project__go { transform: none; opacity: 1; }
.case-card__cat {
  margin-top: 18px;
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
}
.case-card__title {
  margin: 8px 0 6px;
  font-size: clamp(1.25rem, 1.7vw, 1.5rem);
  font-weight: 300;
  line-height: 1.22;
  letter-spacing: -0.02em;
  text-wrap: balance;
}
.case-card__meta { font-size: 0.9375rem; opacity: 0.68; }
.section--alt .case-card__media,
.section:not(.section--night) .case-card__media { background: var(--paper-2); }

/* «Остальные проекты покажем по запросу» */
.request {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 24px 40px;
  margin-top: clamp(72px, 9vw, 128px);
  padding-top: 32px;
  border-top: 1px solid var(--line-night);
}
.request__text {
  font-size: clamp(1.625rem, 3vw, 2.75rem);
  font-weight: 300;
  line-height: 1.12;
  letter-spacing: -0.03em;
}
.request__text em {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 400;
  font-size: 1.1em;
}

/* --------------------------------------------------------------------------
   Страница кейса
   -------------------------------------------------------------------------- */

.h1--case { font-size: clamp(2.25rem, 5vw, 4.75rem); }

/* Ключевые факты под первым экраном */
.case-facts {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin: 0;
}
.case-facts > div { padding: 20px 16px 20px 0; border-top: 1px solid var(--line); }
.case-facts dt {
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.case-facts dd {
  margin: 10px 0 0;
  font-size: clamp(1.0625rem, 1.35vw, 1.25rem);
  line-height: 1.35;
  letter-spacing: -0.01em;
}
@media (min-width: 900px) {
  .case-facts { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .case-facts > div { padding: 28px 28px 8px; border-left: 1px solid var(--line); }
  .case-facts > div:nth-child(4n + 1) { padding-left: 0; border-left: 0; }
}

/* Задача, сложность, итог — под ключевыми фактами кейса */
.case-outcome { display: grid; margin: 0; }
.case-outcome > div { padding: 22px 0; border-top: 1px solid var(--line); }
.case-outcome > div:first-child { border-top: 0; padding-top: 0; }
.case-outcome dt {
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-3);
}
.case-outcome dd { margin: 12px 0 0; max-width: 48ch; font-size: 1.0625rem; line-height: 1.6; color: var(--ink-2); }
.case-outcome > div:last-child dd { color: var(--ink); }
@media (min-width: 900px) {
  .case-outcome { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .case-outcome > div { padding: 8px 32px; border-top: 0; border-left: 1px solid var(--line); }
  .case-outcome > div:first-child { padding: 8px 32px 8px 0; border-left: 0; }
}

/* Рассказ о проекте */
.story__grid { display: grid; gap: 24px 32px; }
.story__grid > .label { margin: 0; align-self: start; }
.story__text { max-width: 62ch; }
.story__text p { font-size: 1.125rem; line-height: 1.65; color: var(--ink-2); }
.story__text p + p { margin-top: 1.1em; }
.story__text h3 {
  margin: 1.8em 0 0.6em;
  font-size: clamp(1.375rem, 2vw, 1.75rem);
  font-weight: 300;
  line-height: 1.2;
  letter-spacing: -0.02em;
  color: var(--ink);
}
.story__text h3:first-child { margin-top: 0; }
@media (min-width: 900px) {
  .story__grid { grid-template-columns: repeat(12, minmax(0, 1fr)); }
  .story__grid > .label { grid-column: 1 / 4; padding-top: 0.5em; }
  .story__text { grid-column: 4 / 12; }
}

/* Документы: политика и согласие на обработку персональных данных */
.doc h2 {
  margin: 2em 0 0.7em;
  font-size: clamp(1.375rem, 2vw, 1.75rem);
  font-weight: 300;
  line-height: 1.2;
  letter-spacing: -0.02em;
  color: var(--ink);
}
.doc h2:first-child { margin-top: 0; }
.doc p, .doc li { font-size: 1.0625rem; line-height: 1.65; color: var(--ink-2); }
.doc ul { margin: 0.8em 0 0; padding-left: 1.25em; }
.doc ul + p { margin-top: 1.1em; }
.doc li + li { margin-top: 0.5em; }
.doc li::marker { color: var(--ink-3); }
.doc strong { font-weight: 500; color: var(--ink); }
.doc a { color: var(--ink); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; overflow-wrap: anywhere; }
.doc a:hover { text-decoration-thickness: 2px; }
.doc .doc-meta { margin-top: 2.4em; padding-top: 20px; border-top: 1px solid var(--line); font-size: 0.875rem; color: var(--ink-3); }

.doc-aside { display: grid; gap: 20px; align-content: start; }
.doc-aside .label { margin: 0; }
.doc-toc ol { display: grid; gap: 10px; margin: 0; padding: 0; list-style: none; counter-reset: toc; }
.doc-toc li { counter-increment: toc; display: grid; grid-template-columns: 2em minmax(0, 1fr); font-size: 0.9375rem; line-height: 1.4; }
.doc-toc li::before { content: counter(toc, decimal-leading-zero); color: var(--ink-3); font-size: 0.8125rem; padding-top: 0.1em; }
.doc-toc a { color: var(--ink-2); transition: color 0.3s var(--ease); }
.doc-toc a:hover { color: var(--ink); }
@media (max-width: 899px) {
  .doc-toc { padding-bottom: 8px; border-bottom: 1px solid var(--line); }
  .doc-toc ol { padding-bottom: 20px; }
}
@media (min-width: 900px) {
  .doc-aside { grid-column: 1 / 4; position: sticky; top: calc(var(--header-h) + 24px); padding-top: 0.5em; padding-right: 24px; }
}

/* Галерея: ровные ряды одной высоты. Ширина фото пропорциональна его формату (--r = ширина / высота),
   поэтому каждый ряд заполнен целиком. Галереи по 6 и 9 фото на десктопе делятся на ряды по три. */
.gallery {
  --row: 230px;
  display: flex;
  flex-wrap: wrap;
  gap: clamp(8px, 1vw, 16px);
}
.gallery__item {
  flex: var(--r, 1.5) 1 calc(var(--r, 1.5) * var(--row));
  aspect-ratio: var(--r, 1.5);
  overflow: hidden;
  background: var(--night-2);
  cursor: zoom-in;
}
.gallery__item img { width: 100%; height: 100%; object-fit: cover; transition: transform 1.2s var(--ease); }
.gallery__item:hover img { transform: scale(1.03); }
@media (max-width: 699px) { .gallery { --row: 100px; } }
.gallery__title {
  margin: clamp(48px, 6vw, 80px) 0 24px;
  font-size: clamp(1.375rem, 2.2vw, 2rem);
  font-weight: 300;
  letter-spacing: -0.025em;
}
.gallery__title:first-child { margin-top: 0; }
.gallery__title span { color: var(--accent); margin-right: 12px; }

/* Просмотр фото на весь экран */
.lightbox {
  width: 100vw;
  height: 100vh;
  height: 100dvh;
  max-width: none;
  max-height: none;
  margin: 0;
  padding: 0;
  border: 0;
  background: rgba(10, 10, 9, 0.97);
  color: var(--on-night);
}
.lightbox[open] { display: grid; place-items: center; }
.lightbox::backdrop { background: rgba(10, 10, 9, 0.9); }
.lightbox__img {
  max-width: calc(100vw - 2 * var(--gutter));
  max-height: calc(100dvh - 150px);
  width: auto;
  height: auto;
  object-fit: contain;
  user-select: none;
}
.lightbox__caption {
  position: absolute;
  left: var(--gutter);
  right: var(--gutter);
  bottom: 24px;
  text-align: center;
  font-size: 0.875rem;
  color: var(--on-night-2);
}
.lightbox__btn {
  position: absolute;
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  border: 1px solid var(--line-night);
  border-radius: 50%;
  background: rgba(14, 14, 13, 0.6);
  color: var(--on-night);
  cursor: pointer;
  transition: background-color 0.3s var(--ease), border-color 0.3s var(--ease);
}
.lightbox__btn:hover { background: rgba(242, 239, 233, 0.12); border-color: var(--on-night); }
.lightbox__btn svg { width: 18px; height: 18px; }
.lightbox__close { top: 20px; right: 20px; }
.lightbox__prev { left: 20px; top: 50%; transform: translateY(-50%); }
.lightbox__prev svg { transform: rotate(180deg); }
.lightbox__next { right: 20px; top: 50%; transform: translateY(-50%); }
@media (max-width: 699px) {
  .lightbox__img { max-height: calc(100dvh - 190px); }
  .lightbox__prev,
  .lightbox__next { top: auto; bottom: 64px; transform: none; }
  .lightbox__caption { bottom: 20px; }
}
.lightbox-open { overflow: hidden; }

/* --------------------------------------------------------------------------
   Всплывающая заявка (кнопки «Обсудить проект», «Оставить заявку» и др.)
   -------------------------------------------------------------------------- */

.modal {
  width: 100%;
  height: 100%;
  max-width: none;
  max-height: none;
  margin: 0;
  padding: 24px var(--gutter);
  border: 0;
  background: transparent;
  color: var(--on-night);
  overflow-y: auto;
  overscroll-behavior: contain;
}
.modal[open] { display: grid; }
.modal::backdrop {
  background: rgba(10, 10, 9, 0.72);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
}
.modal__panel {
  position: relative;
  width: min(100%, 600px);
  margin: auto;
  padding: clamp(32px, 5vw, 56px);
  background: var(--night);
  border: 1px solid var(--line-night);
  box-shadow: 0 32px 120px rgba(0, 0, 0, 0.5);
}
.modal[open] .modal__panel { animation: modal-in 0.55s var(--ease) both; }
@keyframes modal-in { from { opacity: 0; transform: translateY(18px) scale(0.98); } }

.modal__close {
  position: absolute;
  top: 16px;
  right: 16px;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border: 1px solid var(--line-night);
  border-radius: 50%;
  background: transparent;
  color: var(--on-night);
  cursor: pointer;
  transition: background-color 0.3s var(--ease), border-color 0.3s var(--ease);
}
.modal__close:hover { background: rgba(242, 239, 233, 0.1); border-color: var(--on-night); }
.modal__close svg { width: 16px; height: 16px; }

.modal__logo { display: block; width: 116px; height: auto; overflow: visible; color: var(--on-night); }
.modal__title { margin-top: clamp(28px, 4vw, 40px); font-size: clamp(2rem, 4.4vw, 2.75rem); }
.modal__lead { margin-top: 16px; max-width: 42ch; color: var(--on-night-2); }

.modal .form { margin-top: clamp(20px, 3vw, 28px); gap: 28px; }
.modal .fields { grid-template-columns: 1fr; gap: 4px; }
.modal .field textarea { min-height: 76px; }

.modal__contacts { margin-top: clamp(32px, 4vw, 44px); padding-top: 24px; border-top: 1px solid var(--line-night); }
.modal__contacts-title {
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--on-night-2);
}
.modal .contact-list { margin-top: 8px; border-top: 0; }
.modal .contact-list li:last-child { border-bottom: 0; }
.modal .contact-list a { padding: 14px 0; }

.modal-open { overflow: hidden; }

@media (max-width: 600px) {
  .modal { padding: 0; }
  .modal__panel { width: 100%; min-height: 100%; padding: 28px var(--gutter) 40px; border: 0; box-shadow: none; }
  .modal__close { top: 14px; right: 12px; }
}
@media (prefers-reduced-motion: reduce) {
  .modal[open] .modal__panel { animation: none; }
}

.related__footer { margin-top: clamp(40px, 5vw, 64px); }

/* --------------------------------------------------------------------------
   Отзывы: вкладки площадок (Яндекс Карты, 2ГИС, Zoon)
   Без скрипта все панели видны подряд; со скриптом — по одной
   -------------------------------------------------------------------------- */

.reviews__layout { display: grid; gap: clamp(24px, 3vw, 40px); }

.reviews__tabs {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  align-self: start;
}
.reviews__tab {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
  min-width: 0;
  padding: 18px 18px 16px;
  border: 1px solid var(--line);
  background: transparent;
  color: var(--ink);
  font: inherit;
  text-align: left;
  cursor: pointer;
  transition: background-color 0.3s var(--ease), color 0.3s var(--ease), border-color 0.3s var(--ease);
}
.reviews__tab:hover { border-color: var(--ink); }
.reviews__tab:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.reviews__tab[aria-selected="true"] { background: var(--ink); border-color: var(--ink); color: var(--paper); }
.reviews__score { font-size: clamp(1.875rem, 3vw, 2.5rem); font-weight: 200; line-height: 1; letter-spacing: -0.02em; white-space: nowrap; }
.reviews__score::after { content: "\2605"; margin-left: 0.18em; font-size: 0.42em; vertical-align: 0.95em; color: var(--accent); }
.reviews__name { font-size: 0.75rem; font-weight: 500; letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink-3); overflow-wrap: anywhere; }
.reviews__tab[aria-selected="true"] .reviews__name { color: rgba(244, 242, 238, 0.72); }

.reviews__panel { display: grid; gap: 28px; justify-items: start; min-width: 0; }
.reviews__panel[hidden] { display: none; }

.reviews__frame {
  width: 100%;
  max-width: 760px;
  height: 640px;
  overflow: hidden;
  border: 1px solid var(--line);
  background: #fff;
}
.reviews__frame iframe { display: block; width: 100%; height: 100%; border: 0; }

.reviews__quotes {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr));
  gap: 16px;
  width: 100%;
  margin: 0;
  padding: 0;
  list-style: none;
}
.reviews__quotes li {
  display: flex;
  flex-direction: column;
  gap: 18px;
  padding: clamp(22px, 2.4vw, 32px);
  border: 1px solid var(--line);
}
.reviews__quotes li::before { content: "\2605\2605\2605\2605\2605"; font-size: 0.875rem; letter-spacing: 0.2em; color: var(--accent); }
.reviews__quotes blockquote { margin: 0; font-size: 0.9375rem; line-height: 1.65; color: var(--ink-2); }
.reviews__author { margin: auto 0 0; padding-top: 16px; border-top: 1px solid var(--line); font-size: 0.8125rem; color: var(--ink-3); }

.reviews__zoon { width: 100%; max-width: 760px; min-height: 320px; }

@media (max-width: 699px) {
  .reviews__frame { height: 560px; }
}
@media (max-width: 519px) {
  .reviews__tab { gap: 6px; padding: 14px 12px 12px; }
  .reviews__name { font-size: 0.6875rem; letter-spacing: 0.04em; }
}
@media (min-width: 1000px) {
  .reviews__layout { grid-template-columns: minmax(0, 3fr) minmax(0, 9fr); gap: clamp(40px, 5vw, 88px); }
  .reviews__tabs { grid-template-columns: 1fr; grid-auto-rows: 1fr; position: sticky; top: calc(var(--header-h) + 24px); }
  .reviews__tab { flex-direction: row; align-items: center; gap: 20px; padding: 22px 24px; }
}

/* Строка с оценками в блоке заявки (тёмный фон) */
.ratings {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: clamp(28px, 3vw, 40px) 0 0;
  padding: 0;
  list-style: none;
}
.ratings a {
  display: inline-flex;
  align-items: baseline;
  gap: 8px;
  padding: 8px 16px;
  border: 1px solid var(--line-night);
  border-radius: 999px;
  font-size: 0.875rem;
  color: var(--on-night-2);
  transition: border-color 0.3s var(--ease), color 0.3s var(--ease);
}
.ratings a:hover { border-color: var(--accent); color: var(--on-night); }
.ratings b { font-weight: 500; font-size: 1rem; color: var(--accent); }
.ratings b::after { content: " \2605"; font-size: 0.75em; }

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

.js [data-reveal] {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 1s var(--ease), transform 1.1s var(--ease);
  transition-delay: calc(var(--d, 0) * 90ms);
}
.js [data-reveal].is-in { opacity: 1; transform: none; }

/* Первый экран проявляется сразу при загрузке, без ожидания скрипта */
.hero [data-reveal] {
  animation: rise 1.1s var(--ease) both;
  animation-delay: calc(var(--d, 0) * 120ms + 80ms);
}
.js .hero [data-reveal] { opacity: 1; transform: none; transition: none; }

@keyframes rise {
  from { opacity: 0; transform: translateY(24px); }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    transition-delay: 0ms !important;
  }
  .js [data-reveal] { opacity: 1; transform: none; }
  .hero__media img { transform: none; }
}
