/* ==========================================================
   КОНТРАСТ — студия дизайна интерьера
   Идея: чёрное и белое как в логотипе. Секции чередуются
   тёмная / светлая, шапка инвертируется поверх любого фона.
   ========================================================== */

:root {
  --ink: #232323;
  --ink-2: #2e2e2e;
  --ink-3: #3a3a3a;
  --paper: #eeeeea;
  --paper-2: #e2e2dd;
  --white: #ffffff;

  --line-d: rgba(255, 255, 255, .18);
  --line-l: rgba(35, 35, 35, .2);

  --serif: "Cormorant", "Times New Roman", serif;
  --sans: "Manrope", system-ui, -apple-system, "Segoe UI", sans-serif;

  --pad: clamp(20px, 4vw, 64px);
  --ease: cubic-bezier(.22, 1, .36, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--ink);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
ul, ol { list-style: none; margin: 0; padding: 0; }
h1, h2, h3, p, figure, dl, dd { margin: 0; }

:focus-visible { outline: 2px solid currentColor; outline-offset: 4px; }

.wrap { width: 100%; max-width: 1440px; margin: 0 auto; padding: 0 var(--pad); }

/* ---------- Секции ---------- */
.section { padding: clamp(64px, 8vw, 120px) 0; position: relative; }
.section.dark { background: var(--ink); color: var(--white); }
.section.light { background: var(--paper); color: var(--ink); }

.section-head {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px var(--pad);
  align-items: end;
  margin-bottom: clamp(32px, 4.5vw, 64px);
}
.h2 {
  font-family: var(--serif);
  font-weight: 400;
  font-size: clamp(30px, 3.5vw, 54px);
  line-height: 1.08;
  letter-spacing: -.01em;
}
.h2-xl { font-size: clamp(32px, 4.2vw, 64px); margin-bottom: 18px; }
.lead { font-size: clamp(15px, 1.1vw, 17px); max-width: 46ch; opacity: .72; }
.section-head .lead { justify-self: end; }

/* ---------- Кнопки ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  height: 50px; padding: 0 28px;
  border-radius: 999px;
  font-weight: 500; font-size: 15px;
  border: 1px solid transparent;
  transition: background .35s var(--ease), color .35s var(--ease), border-color .35s var(--ease), transform .35s var(--ease);
}
.btn:active { transform: scale(.97); }
.btn-lg { height: 58px; padding: 0 36px; font-size: 16px; }
.btn-light { background: var(--white); color: var(--ink); }
.btn-light:hover { background: transparent; color: var(--white); border-color: var(--white); }
.btn-ghost { border-color: var(--line-d); color: var(--white); }
.btn-ghost:hover { background: var(--white); color: var(--ink); border-color: var(--white); }

/* ---------- Логотип ---------- */
.logo {
  display: inline-flex; align-items: center;
  font-family: var(--serif);
  font-size: 24px; font-weight: 500; letter-spacing: .06em; line-height: 1;
}
.logo-ring {
  width: .86em; height: .86em;
  border: 1.5px solid currentColor; border-radius: 50%;
  margin: 0 .06em 0 .12em;
  transition: transform .6s var(--ease);
}
.logo:hover .logo-ring { transform: rotate(180deg) scale(1.12); }

/* ---------- Шапка: инвертируется над любым фоном ---------- */
.header {
  position: fixed; inset: 0 0 auto 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  padding: 22px var(--pad);
  color: #fff;
  mix-blend-mode: difference;
  transition: transform .5s var(--ease);
}
.header.is-hidden { transform: translateY(-110%); }
.nav { display: flex; gap: clamp(16px, 2.2vw, 36px); font-size: 14px; }
.nav a { position: relative; padding: 4px 0; }
.nav a::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1px;
  background: currentColor; transform: scaleX(0); transform-origin: right;
  transition: transform .45s var(--ease);
}
.nav a:hover::after { transform: scaleX(1); transform-origin: left; }
.header-cta {
  font-size: 14px; font-weight: 500;
  padding: 10px 20px; border: 1px solid currentColor; border-radius: 999px;
  transition: background .3s, color .3s;
}
.header-cta:hover { background: #fff; color: #000; }

.burger { display: none; width: 44px; height: 44px; position: relative; }
.burger span {
  position: absolute; left: 10px; right: 10px; height: 1.5px; background: currentColor;
  transition: transform .4s var(--ease), top .4s var(--ease);
}
.burger span:nth-child(1) { top: 17px; }
.burger span:nth-child(2) { top: 26px; }
.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); }

/* ==========================================================
   HERO
   ========================================================== */
.hero {
  position: relative;
  min-height: 100vh; min-height: 100svh;
  background: var(--ink); color: var(--white);
  display: flex; align-items: flex-end;
  padding: 120px var(--pad) clamp(32px, 5vw, 64px);
  overflow: hidden;
  isolation: isolate;
}
/* Белый диск с blend difference: всё, что под ним, инвертируется.
   Это буквально «контраст» — белый текст внутри диска становится тёмным. */
.hero-disc {
  position: absolute; top: 0; left: 0; z-index: 3;
  width: clamp(250px, 22vw, 340px); aspect-ratio: 1;
  border-radius: 50%;
  background: #fff;
  mix-blend-mode: difference;
  pointer-events: none;
  will-change: transform;
  opacity: 0;
  transition: opacity 1.2s var(--ease) .5s;
}
.hero.is-ready .hero-disc { opacity: 1; }

/* Логотип в цвет фона: виден только внутри белого круга (clip-path задаёт app.js) */
.hero-logo {
  position: absolute; z-index: 4;
  top: 50%; right: var(--pad); margin-top: calc(clamp(360px, 46vw, 820px) * .15 * -1);
  width: clamp(360px, 46vw, 820px); height: auto;
  clip-path: circle(0 at 50% 50%);
  pointer-events: none; user-select: none; -webkit-user-drag: none;
  opacity: 0; transition: opacity 1.2s var(--ease) .5s;
}
.hero.is-ready .hero-logo { opacity: 1; }
/* Мобильная версия: логотип над заголовком, круг сам проплывает над ним */
@media (max-width: 900px) {
  .hero { --lw: min(calc(100vw - 2 * var(--pad)), 460px); padding-top: calc(200px + var(--lw) * .302 + 28px); }
  .hero-logo { top: 200px; left: var(--pad); right: auto; margin-top: 0; width: var(--lw); }
}

.hero-inner { position: relative; z-index: 2; width: 100%; max-width: 1440px; margin: 0 auto; }
.hero-title {
  font-family: var(--serif); font-weight: 400;
  font-size: clamp(36px, 6.2vw, 98px);
  line-height: .98; letter-spacing: -.02em;
}
.hero-title .line { display: block; overflow: hidden; padding-bottom: .08em; margin-bottom: -.08em; }
.hero-title .line > span {
  display: block; transform: translateY(110%);
  transition: transform 1.1s var(--ease);
}
.hero.is-ready .hero-title .line > span { transform: none; }
.hero.is-ready .hero-title .line:nth-child(2) > span { transition-delay: .1s; }
.hero.is-ready .hero-title .line:nth-child(3) > span { transition-delay: .2s; }

/* Линия из логотипа: утолщение слева, остриё справа, точка на конце */
.hero-rule { display: flex; align-items: center; gap: 14px; margin: clamp(28px, 3.5vw, 48px) 0 clamp(20px, 2.5vw, 32px); }
.hero-rule i {
  flex: 1; height: 12px; background: #fff;
  clip-path: polygon(0 0, 100% 46%, 100% 54%, 0 100%);
  border-radius: 6px 0 0 6px;
  transform: scaleX(0); transform-origin: left;
  transition: transform 1.6s var(--ease) .5s;
}
.hero-rule b {
  width: 14px; height: 14px; border-radius: 50%; background: #fff;
  transform: scale(0); transition: transform .6s var(--ease) 1.9s;
}
.hero.is-ready .hero-rule i { transform: none; }
.hero.is-ready .hero-rule b { transform: none; }

.hero-cta {
  display: flex; gap: 12px; flex-wrap: wrap;
  margin-top: 0;
  opacity: 0; transform: translateY(16px);
  transition: opacity .9s var(--ease) .7s, transform .9s var(--ease) .7s;
}
.hero.is-ready .hero-cta { opacity: 1; transform: none; }
.hero-sub {
  max-width: 56ch; font-size: clamp(14px, 1.1vw, 16.5px); opacity: 0;
  transition: opacity .9s var(--ease) 1.3s;
  margin-top: clamp(20px, 2.5vw, 32px);
}
.hero.is-ready .hero-sub { opacity: .75; }

/* ==========================================================
   БЕГУЩИЕ ЛЕНТЫ (marquee)
   ========================================================== */
.gallery { background: var(--ink); padding: clamp(56px, 7vw, 104px) 0 0; overflow: hidden; }
.gallery + .section-slider { padding-top: clamp(56px, 7vw, 96px); }
.marquee { overflow: hidden; margin-bottom: 14px; }
.marquee-track {
  display: flex; width: max-content;
  animation: marquee 100s linear infinite;
  will-change: transform;
}
.marquee-rev .marquee-track { animation-direction: reverse; animation-duration: 120s; }
.marquee:hover .marquee-track { animation-play-state: paused; }
@keyframes marquee { to { transform: translateX(-50%); } }

.m-item {
  flex: none; margin-right: 14px;
  width: clamp(150px, 14vw, 210px); aspect-ratio: 1 / 1.414;
  border-radius: 6px; overflow: hidden; background: var(--ink-2);
}
.marquee-rev .m-item { aspect-ratio: 5 / 4; width: clamp(190px, 20vw, 300px); }
.m-item img {
  width: 100%; height: 100%; object-fit: cover; object-position: 50% 35%;
  transition: transform 1.2s var(--ease);
}
.m-item:hover img { transform: scale(1.08); }
.marquee:not(.marquee-rev) .m-item img { object-position: 50% 50%; }

/* ==========================================================
   О КОМПАНИИ
   ========================================================== */
.about-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 6vw, 96px); align-items: start;
}
.about-grid .h2 { max-width: 20ch; }
.about-body { display: flex; flex-direction: column; gap: 18px; max-width: 56ch; font-size: clamp(15px, 1.1vw, 17px); }
.about-body p { opacity: .82; }
.stats { display: flex; gap: clamp(24px, 4vw, 56px); margin-top: 24px; padding-top: 28px; border-top: 1px solid var(--line-l); }
.stats dt { font-family: var(--serif); font-size: clamp(34px, 3.6vw, 52px); line-height: 1; }
.stats dd { font-size: 13.5px; opacity: .65; margin-top: 6px; max-width: 14ch; }

/* ==========================================================
   ПРЕИМУЩЕСТВА (bento)
   ========================================================== */
.bento {
  display: grid; gap: 14px;
  grid-template-columns: repeat(6, 1fr);
  grid-auto-rows: minmax(190px, auto);
}
.tile {
  position: relative; overflow: hidden;
  padding: clamp(20px, 2.2vw, 32px);
  border-radius: 8px;
  display: flex; flex-direction: column; justify-content: flex-end; gap: 12px;
  background: var(--ink-2);
  transition: transform .6s var(--ease), background .5s var(--ease), color .5s var(--ease);
}
.tile h3 { font-family: var(--serif); font-weight: 500; font-size: clamp(20px, 1.7vw, 26px); line-height: 1.08; }
.tile p { font-size: 14.5px; opacity: .72; max-width: 44ch; }
.tile:hover { background: var(--white); color: var(--ink); }
.tile-a { grid-column: span 4; grid-row: span 2; background: var(--white); color: var(--ink); }
.tile-a h3 { font-size: clamp(26px, 2.8vw, 42px); max-width: 16ch; }
.tile-a:hover { background: var(--paper-2); }
.tile-b { grid-column: span 2; }
.tile-c { grid-column: span 2; background: var(--ink-3); }
.tile-d { grid-column: span 2; }
.tile-e { grid-column: span 3; }
.tile-f { grid-column: span 3; background: var(--ink-3); }
.tile-ring {
  position: absolute; top: -12%; right: -6%;
  width: min(60%, 360px); aspect-ratio: 1;
  border: 1.5px solid var(--ink); border-radius: 50%;
  transition: transform 1.2s var(--ease);
}
.tile-a:hover .tile-ring { transform: scale(1.15) rotate(40deg); }
.tile-ring::after {
  content: ""; position: absolute; left: -30%; right: -30%; top: 56%; height: 8px;
  background: var(--ink); clip-path: polygon(0 0, 100% 46%, 100% 54%, 0 100%);
}

/* ==========================================================
   КАК МЫ РАБОТАЕМ
   ========================================================== */
.steps { border-top: 1px solid var(--line-l); }
.step {
  position: relative;
  display: grid; grid-template-columns: 90px minmax(0, 1.1fr) minmax(0, 1.2fr) 90px;
  gap: 24px; align-items: center;
  padding: clamp(20px, 2.4vw, 34px) 0;
  border-bottom: 1px solid var(--line-l);
  transition: padding .6s var(--ease), color .4s;
}
.step::before {
  content: ""; position: absolute; inset: 0 calc(var(--pad) * -1);
  background: var(--ink); z-index: -1;
  transform: scaleY(0); transform-origin: bottom;
  transition: transform .6s var(--ease);
}
.step:hover { color: var(--white); padding-left: 24px; padding-right: 24px; }
.step:hover::before { transform: scaleY(1); }
.step { isolation: isolate; }
.step-num { font-family: var(--serif); font-size: 20px; opacity: .6; }
.step h3 { font-family: var(--serif); font-weight: 500; font-size: clamp(22px, 2.1vw, 32px); line-height: 1.05; }
.step p { font-size: 14.5px; opacity: .75; max-width: 52ch; }
.step-time { justify-self: end; font-size: 14px; opacity: .6; white-space: nowrap; }

/* ==========================================================
   КОМАНДА
   ========================================================== */
.team-list { display: grid; gap: clamp(32px, 5vw, 72px); }
.person {
  display: grid; grid-template-columns: 1fr 1fr; gap: clamp(24px, 5vw, 80px); align-items: center;
}
/* шахматный порядок: фото слева → фото справа */
.person:nth-child(even) .person-photo { order: 2; }
.person-photo {
  width: 100%; max-width: 400px; aspect-ratio: 4 / 5; overflow: hidden; border-radius: 6px; background: var(--ink-2);
}
.person:nth-child(even) .person-photo { justify-self: end; }
.person-photo img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 28%; transition: transform 1.2s var(--ease); }
.person:hover .person-photo img { transform: scale(1.05); }
.person-text { max-width: 54ch; display: flex; flex-direction: column; gap: 14px; }
.person-text h3 { font-family: var(--serif); font-weight: 500; font-size: clamp(26px, 2.6vw, 40px); line-height: 1.1; }
.person-role { font-size: 14px; opacity: .6; margin-top: -8px; }
.person-text p { font-size: 15px; opacity: .78; }

/* ==========================================================
   ФОРМАТЫ РАБОТЫ
   ========================================================== */
.formats-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.format {
  display: flex; flex-direction: column; gap: 16px;
  padding: clamp(22px, 2.4vw, 34px);
  background: #fff; color: var(--ink); border-radius: 8px;
  transition: transform .6s var(--ease), box-shadow .6s var(--ease);
}
.format:hover { transform: translateY(-4px); box-shadow: 0 18px 40px -22px rgba(0, 0, 0, .35); }
.format-main { background: var(--ink); color: #fff; }
/* номер в кольце из логотипа */
.format-num {
  width: 46px; height: 46px; border-radius: 50%;
  display: grid; place-items: center;
  border: 1.5px solid currentColor;
  font-family: var(--serif); font-size: 17px; font-weight: 500;
  transition: background .5s var(--ease), color .5s var(--ease);
}
.format:not(.format-main):hover .format-num { background: var(--ink); color: #fff; }
.format-main:hover .format-num { background: #fff; color: var(--ink); }
.format h3 { font-family: var(--serif); font-weight: 500; font-size: clamp(22px, 2vw, 30px); line-height: 1.1; }
.format-lead { font-size: 14.5px; opacity: .72; }
.format ul { margin-top: 4px; }
.format li {
  position: relative; padding: 10px 0 10px 22px;
  border-top: 1px solid var(--line-l); font-size: 14.5px; line-height: 1.45;
}
.format-main li { border-top-color: var(--line-d); }
.format li::before {
  content: ""; position: absolute; left: 0; top: 17px;
  width: 9px; height: 9px; border-radius: 50%; border: 1.5px solid currentColor; opacity: .7;
}
/* низ карточки: цена слева, кнопка справа */
.format-foot {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  margin-top: auto; padding-top: 18px; border-top: 1px solid var(--line-l);
}
.format-main .format-foot { border-top-color: var(--line-d); }
.format-price { display: grid; gap: 2px; min-width: 0; }
.format-price small { font-size: 12.5px; opacity: .55; }
.format-price strong { font-family: var(--serif); font-weight: 500; font-size: clamp(20px, 1.8vw, 26px); line-height: 1.1; }
.format-foot .btn { flex: none; }
.format ul { margin-bottom: 12px; }
.btn-dark { background: var(--ink); color: #fff; }
.btn-dark:hover { background: transparent; color: var(--ink); border-color: var(--ink); }

/* ==========================================================
   СЛАЙДЕРЫ
   ========================================================== */
.section-slider { overflow: hidden; }
.slider { position: relative; overflow: hidden; cursor: grab; touch-action: pan-y; user-select: none; -webkit-user-select: none; }
.slider.is-dragging { cursor: grabbing; }
.track { display: flex; gap: clamp(14px, 2vw, 28px); padding: 0 var(--pad); width: max-content; will-change: transform; }

.slide { flex: none; width: clamp(240px, 26vw, 400px); }
.slide-photo {
  position: relative; aspect-ratio: 4 / 5; overflow: hidden; border-radius: 6px;
  background: var(--ink-2);
}
.slide-photo img {
  position: absolute; top: 0; left: -12%;
  width: 124%; height: 100%; object-fit: cover; max-width: none;
  will-change: transform; pointer-events: none; -webkit-user-drag: none;
}
.slide-photo::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(to top, rgba(0,0,0,.45), transparent 45%);
  opacity: 0; transition: opacity .5s var(--ease);
}
.slide:hover .slide-photo::after { opacity: 1; }
/* ---------- Карточка проекта ---------- */
.work-tag {
  position: absolute; top: 14px; left: 14px; z-index: 2;
  padding: 7px 14px; border-radius: 999px;
  font-size: 12.5px; font-weight: 500; line-height: 1.2; color: #fff;
  background: rgba(20, 20, 20, .5);
  border: 1px solid rgba(255, 255, 255, .22);
  -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px);
  pointer-events: none;
}
/* кольцо из логотипа с номером проекта */
.work-ring {
  position: absolute; top: 14px; right: 14px; z-index: 2;
  width: 46px; height: 46px; border-radius: 50%;
  display: grid; place-items: center;
  font-family: var(--serif); font-size: 17px; font-weight: 500; color: #fff;
  border: 1.5px solid #fff;
  background: rgba(20, 20, 20, .25);
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
  transition: background .5s var(--ease), color .5s var(--ease), transform .6s var(--ease);
  pointer-events: none;
}
.work:hover .work-ring { background: #fff; color: var(--ink); transform: scale(1.12); }
.work-info { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; margin-top: 18px; }
.work-info h3 { font-family: var(--serif); font-weight: 500; font-size: clamp(20px, 1.8vw, 27px); line-height: 1.12; }
.work-info p { font-size: 13.5px; opacity: .6; white-space: nowrap; }
/* линия из логотипа: острие справа, при наведении вытягивается на всю ширину */
.work-rule {
  display: block; height: 8px; margin-top: 16px; background: currentColor; opacity: .35;
  clip-path: polygon(0 0, 100% 46%, 100% 54%, 0 100%);
  transform: scaleX(.22); transform-origin: left;
  transition: transform .9s var(--ease), opacity .5s var(--ease);
}
.work:hover .work-rule { transform: none; opacity: .9; }

/* Отзывы — скриншоты одной высоты, ширина по пропорциям картинки */
.slider-reviews .slide { width: auto; }
.review-shot { height: clamp(300px, 30vw, 440px); }
.review-shot img {
  display: block; height: 100%; width: auto; max-width: none;
  border-radius: 10px; background: #fff;
  border: 1px solid var(--line-l);
  pointer-events: none; -webkit-user-drag: none;
  transition: transform .6s var(--ease), box-shadow .6s var(--ease);
}
.review-shot:hover img { transform: translateY(-4px); box-shadow: 0 22px 44px -26px rgba(0, 0, 0, .45); }

.slider-ui {
  display: flex; align-items: center; gap: 32px;
  margin-top: clamp(28px, 3.5vw, 52px);
}
.progress { flex: 1; height: 2px; background: var(--line-d); position: relative; overflow: hidden; }
.light .progress { background: var(--line-l); }
.progress i { position: absolute; inset: 0; background: currentColor; transform-origin: left; transform: scaleX(.1); }
.arrows { display: flex; gap: 10px; }
.arrow {
  width: 48px; height: 48px; border-radius: 50%;
  border: 1px solid currentColor; font-size: 20px; line-height: 1;
  opacity: .9;
  transition: background .3s, color .3s, transform .3s var(--ease), opacity .3s;
}
.dark .arrow:hover { background: var(--white); color: var(--ink); }
.light .arrow:hover { background: var(--ink); color: var(--white); }
.arrow:active { transform: scale(.92); }
.arrow:disabled { opacity: .25; pointer-events: none; }

.drag-cursor {
  position: fixed; top: 0; left: 0; z-index: 60;
  width: 76px; height: 76px; margin: -38px 0 0 -38px;
  border-radius: 50%; background: var(--white); color: var(--ink);
  display: grid; place-items: center;
  font-size: 14px; font-weight: 500;
  pointer-events: none;
  transform: translate3d(-200px, -200px, 0) scale(0);
  transition: opacity .3s;
  mix-blend-mode: normal;
}

/* ==========================================================
   МОДАЛЬНОЕ ОКНО ПРОЕКТА
   ========================================================== */
.work { cursor: pointer; }
.modal {
  position: fixed; inset: 0; z-index: 100;
  display: flex; overflow-y: auto; overscroll-behavior: contain;
  padding: clamp(12px, 3vw, 40px);
  visibility: hidden; opacity: 0;
  transition: opacity .45s var(--ease), visibility 0s linear .45s;
}
.modal.is-open { visibility: visible; opacity: 1; transition: opacity .45s var(--ease); }
.modal-backdrop {
  position: fixed; inset: 0;
  background: rgba(12, 12, 12, .74);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
}
.modal-panel {
  position: relative; margin: auto; width: 100%; max-width: 1120px;
  display: grid; grid-template-columns: 1.15fr 1fr;
  background: var(--ink); color: #fff; border-radius: 10px;
  box-shadow: 0 40px 90px -30px rgba(0, 0, 0, .8);
  transform: translateY(28px) scale(.98);
  transition: transform .7s var(--ease);
}
.modal.is-open .modal-panel { transform: none; }

.modal-close {
  position: fixed; top: clamp(16px, 3vw, 36px); right: clamp(16px, 3vw, 36px); z-index: 5;
  width: 46px; height: 46px; border-radius: 50%;
  background: #fff; color: var(--ink);
  transition: transform .4s var(--ease), background .3s;
}
.modal-close:hover { transform: rotate(90deg) scale(1.06); }
.modal-close span {
  position: absolute; left: 14px; right: 14px; top: 22px; height: 1.5px; background: currentColor;
}
.modal-close span:nth-child(1) { transform: rotate(45deg); }
.modal-close span:nth-child(2) { transform: rotate(-45deg); }

/* Колесо с фото */
.modal-photos { position: relative; min-width: 0; }
.wheel {
  position: relative; isolation: isolate; height: clamp(420px, 44vw, 620px); overflow: hidden;
  border-radius: 10px 0 0 10px;
  touch-action: pan-y; user-select: none; -webkit-user-select: none; cursor: grab;
}
.wheel.is-dragging { cursor: grabbing; }
.wheel-ring { position: absolute; inset: 0; transform: rotate(-9deg); }
.wheel-card {
  position: absolute; left: 50%; top: 50%;
  width: var(--cw, 300px); height: var(--ch, 240px);
  margin: calc(var(--ch, 240px) / -2) 0 0 calc(var(--cw, 300px) / -2);
  padding: 0; border: 0; border-radius: 12px; overflow: hidden;
  background: var(--ink-2); cursor: inherit;
  box-shadow: 0 22px 44px -20px rgba(0, 0, 0, .85);
  will-change: transform, filter;
}
.wheel-card img { display: block; width: 100%; height: 100%; object-fit: cover; pointer-events: none; }
.wheel-hint {
  position: absolute; left: 0; right: 0; bottom: 16px; z-index: 200;
  text-align: center; font-size: 12.5px; opacity: .5; pointer-events: none;
}

/* Фото на всё окно проекта */
.zoom { position: absolute; inset: 0; z-index: 4; display: none; border-radius: 10px; overflow: hidden; cursor: zoom-out; }
.zoom.is-on { display: block; }
.zoom-bg { position: absolute; inset: 0; background: var(--ink); opacity: 0; transition: opacity .6s var(--ease); }
.zoom.is-open .zoom-bg { opacity: 1; }
.zoom-stage {
  position: absolute; overflow: hidden; border-radius: 12px;
  transition: left .75s var(--ease), top .75s var(--ease), width .75s var(--ease), height .75s var(--ease), border-radius .75s var(--ease);
}
.zoom.is-open .zoom-stage { left: 0 !important; top: 0 !important; width: 100% !important; height: 100% !important; border-radius: 10px; }
.zoom-stage img { display: block; width: 100%; height: 100%; object-fit: contain; transition: opacity .25s; }
.zoom-back, .zoom-nav {
  position: absolute; z-index: 2; color: #fff; cursor: pointer;
  background: rgba(20, 20, 20, .55); border: 1px solid var(--line-d);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
  opacity: 0; transition: opacity .4s var(--ease), background .3s, color .3s;
}
.zoom-back { top: clamp(14px, 2vw, 26px); left: clamp(14px, 2vw, 26px); height: 44px; padding: 0 20px; border-radius: 999px; font-size: 14px; }
.zoom-nav { top: 50%; margin-top: -23px; width: 46px; height: 46px; border-radius: 50%; font-size: 20px; }
.zoom-prev { left: clamp(14px, 2vw, 26px); }
.zoom-next { right: clamp(14px, 2vw, 26px); }
.zoom-back:hover, .zoom-nav:hover { background: #fff; color: var(--ink); }
.zoom-count { position: absolute; z-index: 2; bottom: 18px; left: 0; right: 0; text-align: center; font-size: 13px; opacity: 0; transition: opacity .4s var(--ease); pointer-events: none; }
.zoom.is-open .zoom-back, .zoom.is-open .zoom-nav { opacity: 1; transition-delay: .45s; }
.zoom.is-open .zoom-count { opacity: .7; transition-delay: .45s; }

.modal-body {
  display: flex; flex-direction: column; align-items: flex-start; gap: 18px;
  padding: clamp(28px, 3.6vw, 56px) clamp(24px, 3.2vw, 52px) clamp(28px, 3.6vw, 56px) clamp(16px, 2vw, 32px);
}
.modal-tag {
  padding: 7px 14px; border-radius: 999px; font-size: 12.5px; font-weight: 500;
  border: 1px solid var(--line-d);
}
.modal-title { font-family: var(--serif); font-weight: 500; font-size: clamp(30px, 3.4vw, 52px); line-height: 1.04; margin-top: 4px; }
.modal-meta { font-size: 14px; opacity: .6; margin-top: -6px; }
.modal-meta:empty { display: none; }
.modal-text { display: grid; gap: 14px; font-size: 15.5px; opacity: .8; max-width: 52ch; padding-top: 18px; border-top: 1px solid var(--line-d); }
.modal-body .btn { margin-top: auto; }

@media (max-width: 900px) {
  .modal-panel { grid-template-columns: 1fr; }
  .wheel { height: clamp(300px, 88vw, 460px); border-radius: 10px 10px 0 0; }
  .modal-body { padding: 8px clamp(20px, 5vw, 32px) 32px; }
  .modal-body .btn { margin-top: 12px; }
}

/* ==========================================================
   КОНТАКТЫ
   ========================================================== */
.contact {  padding: clamp(48px, 6vw, 80px) 0; }
.contact-grid { display: grid; grid-template-columns: 1.1fr 1fr; gap: clamp(32px, 6vw, 96px); align-items: end; }
.contact-list { margin-top: 0; display: grid; gap: 6px; font-family: var(--serif); font-size: clamp(20px, 1.8vw, 27px); line-height: 1.25; }
.contact-list a { background: linear-gradient(currentColor, currentColor) left bottom / 0 1px no-repeat; transition: background-size .5s var(--ease); }
.contact-list a:hover { background-size: 100% 1px; }


.footer { background: var(--ink); color: var(--white); border-top: 1px solid var(--line-d); padding: 32px 0; }
.footer-in { display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap; font-size: 14px; }
.footer-in p { opacity: .6; }
.logo-sm { font-size: 20px; }

/* ==========================================================
   АДАПТИВ
   ========================================================== */
@media (max-width: 1100px) {
  .nav { display: none; }
  .burger { display: block; }
  .header-cta { margin-left: auto; }
  .nav.open {
    display: flex; position: fixed; inset: 0; z-index: -1;
    flex-direction: column; justify-content: center; align-items: flex-start; gap: 18px;
    padding: 100px var(--pad) 40px;
    background: #fff; color: var(--ink);
    font-family: var(--serif); font-size: clamp(34px, 8vw, 56px);
  }
  .step { grid-template-columns: 56px 1fr; }
  .step { grid-template-columns: 56px 1fr; }
  .step p { grid-column: 2; }
  .step-time { grid-column: 2; justify-self: start; }
}

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

@media (max-width: 860px) {
  .section-head { grid-template-columns: 1fr; }
  .section-head .lead { justify-self: start; }
  .about-grid { grid-template-columns: 1fr; }
  .bento { grid-template-columns: repeat(2, 1fr); grid-auto-rows: auto; }
  .tile { min-height: 220px; }
  .tile-a { grid-column: span 2; grid-row: auto; min-height: 380px; }
  .tile-b, .tile-c, .tile-d { grid-column: span 1; }
  .tile-e, .tile-f { grid-column: span 2; }
  .person { grid-template-columns: 1fr; }
  .person:nth-child(even) .person-photo { order: 0; justify-self: start; }
  .contact-grid { grid-template-columns: 1fr; align-items: start; }
}

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

@media (max-width: 560px) {
  .header-cta { display: none; }
  .burger { margin-left: auto; }
  .hero-cta { width: 100%; }
  .hero-cta .btn { flex: 1; padding: 0 16px; }
  .bento { grid-template-columns: 1fr; }
  .tile-b, .tile-c, .tile-d, .tile-e, .tile-f { grid-column: span 1; }
  .tile-a { grid-column: span 1; }
  .stats { flex-wrap: wrap; }
  .slider-ui { gap: 16px; }
  .arrow { width: 48px; height: 48px; }
  .drag-cursor { display: none; }
}

@media (hover: none) { .drag-cursor { display: none; } }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; }
  .marquee-track { animation: none; }
  .hero-title .line > span, .hero-cta, .hero-rule i, .hero-rule b { transform: none; opacity: 1; }
  .hero-sub { opacity: .75; }
}
.formats-download {
  display: inline-block; margin-top: 28px; padding-bottom: 2px;
  font-size: 14.5px; border-bottom: 1px solid currentColor; opacity: .75;
  transition: opacity .3s;
}
.formats-download:hover { opacity: 1; }
.header.menu-open { mix-blend-mode: normal; color: var(--ink); }
.footer-right { text-align: right; display: grid; gap: 4px; }