/* ===== Шрифты (локально, без внешних запросов) ===== */
@font-face { font-family: "Unbounded"; font-weight: 500; font-display: swap; src: url(../fonts/unbounded-cyrillic-500-normal.woff2) format("woff2"); unicode-range: U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116; }
@font-face { font-family: "Unbounded"; font-weight: 500; font-display: swap; src: url(../fonts/unbounded-latin-500-normal.woff2) format("woff2"); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+2000-206F,U+20AC,U+20BD,U+2122,U+2212; }
@font-face { font-family: "Unbounded"; font-weight: 700; font-display: swap; src: url(../fonts/unbounded-cyrillic-700-normal.woff2) format("woff2"); unicode-range: U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116; }
@font-face { font-family: "Unbounded"; font-weight: 700; font-display: swap; src: url(../fonts/unbounded-latin-700-normal.woff2) format("woff2"); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+2000-206F,U+20AC,U+20BD,U+2122,U+2212; }
@font-face { font-family: "Onest"; font-weight: 400; font-display: swap; src: url(../fonts/onest-cyrillic-400-normal.woff2) format("woff2"); unicode-range: U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116; }
@font-face { font-family: "Onest"; font-weight: 400; font-display: swap; src: url(../fonts/onest-latin-400-normal.woff2) format("woff2"); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+2000-206F,U+20AC,U+20BD,U+2122,U+2212; }
@font-face { font-family: "Onest"; font-weight: 500; font-display: swap; src: url(../fonts/onest-cyrillic-500-normal.woff2) format("woff2"); unicode-range: U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116; }
@font-face { font-family: "Onest"; font-weight: 500; font-display: swap; src: url(../fonts/onest-latin-500-normal.woff2) format("woff2"); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+2000-206F,U+20AC,U+20BD,U+2122,U+2212; }
@font-face { font-family: "Onest"; font-weight: 600; font-display: swap; src: url(../fonts/onest-cyrillic-600-normal.woff2) format("woff2"); unicode-range: U+0301,U+0400-045F,U+0490-0491,U+04B0-04B1,U+2116; }
@font-face { font-family: "Onest"; font-weight: 600; font-display: swap; src: url(../fonts/onest-latin-600-normal.woff2) format("woff2"); unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+2000-206F,U+20AC,U+20BD,U+2122,U+2212; }

/* ===== Токены ===== */
:root {
  --black: #000;
  --white: #fff;
  --violet: #7B2CFF;
  --violet-hover: #6414F0;
  --violet-soft: #B794FF;
  --lilac: #F2EBFF;
  --muted: #5E5670;
  --line: #E4DDF0;
  --on-dark-muted: rgba(255, 255, 255, .68);
  --on-dark-line: rgba(255, 255, 255, .18);
  --f-display: "Unbounded", "Arial Black", system-ui, sans-serif;
  --f-text: "Onest", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --wrap: 1320px;
  --gutter: clamp(20px, 4vw, 48px);
  --header-h: 72px;
  --paper: #F7F5FB;
  --card-line: #E7E1F1;
  --shadow-soft: 0 14px 34px rgba(46, 16, 101, .07);
  --shadow-lift: 0 24px 52px rgba(46, 16, 101, .14);
  --r: 22px;
  --r-lg: 32px;
  --ease: cubic-bezier(.2, .75, .15, 1);
  --ease-expo: cubic-bezier(.16, 1, .3, 1);
  --section-y: clamp(84px, 10vw, 150px);
  --check-violet: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='M2 6.2 4.8 9 10 3' fill='none' stroke='%237B2CFF' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  --check-white: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='M2 6.2 4.8 9 10 3' fill='none' stroke='%23fff' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  --check-soft: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 12'%3E%3Cpath d='M2 6.2 4.8 9 10 3' fill='none' stroke='%23B794FF' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");

  /* Цвета темы. Светлая — по умолчанию; тёмная ниже. Тёмные блоки (шапка, первый экран, подвал) в обеих темах тёмные */
  color-scheme: light;
  --bg: var(--paper);
  --surface: #fff;
  --ink: #000;
  --accent-text: var(--violet);
  --tint-bg: linear-gradient(180deg, #F2EBFF 0%, #F6F1FF 100%);
  --fmt-top-bg: linear-gradient(135deg, #F5EFFF, #E4D5FF);
  --check-accent: var(--check-violet);
  --float-bg: rgba(255, 255, 255, .96);
  --shadow-float: 0 16px 40px rgba(46, 16, 101, .16);
  --field-line: rgba(0, 0, 0, .25);
  --chip-line: rgba(0, 0, 0, .16);
  --btn-line: #D9CCF5;
  --box-line: #C4B9D6;
  --night-line: transparent;
}

/* Тёмная тема: выбрана вручную или так настроена система посетителя.
   Два одинаковых блока: один для выбора кнопкой, второй для системной настройки */
:root[data-theme="dark"] {
  color-scheme: dark;
  --paper: #0C0914;
  --surface: #161120;
  --ink: #F3F0F8;
  --muted: #A69EB6;
  --line: rgba(255, 255, 255, .12);
  --card-line: rgba(255, 255, 255, .08);
  --lilac: #241A3A;
  --accent-text: #B794FF;
  --tint-bg: linear-gradient(180deg, #130D20 0%, #0F0A19 100%);
  --fmt-top-bg: linear-gradient(135deg, #1F1633, #2C1C4C);
  --check-accent: var(--check-soft);
  --float-bg: rgba(22, 17, 32, .94);
  --shadow-soft: 0 14px 34px rgba(0, 0, 0, .35);
  --shadow-lift: 0 24px 52px rgba(0, 0, 0, .55);
  --shadow-float: 0 16px 40px rgba(0, 0, 0, .5);
  --field-line: rgba(255, 255, 255, .3);
  --chip-line: rgba(255, 255, 255, .22);
  --btn-line: rgba(183, 148, 255, .38);
  --box-line: rgba(255, 255, 255, .3);
  --night-line: rgba(255, 255, 255, .09);
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --paper: #0C0914;
    --surface: #161120;
    --ink: #F3F0F8;
    --muted: #A69EB6;
    --line: rgba(255, 255, 255, .12);
    --card-line: rgba(255, 255, 255, .08);
    --lilac: #241A3A;
    --accent-text: #B794FF;
    --tint-bg: linear-gradient(180deg, #130D20 0%, #0F0A19 100%);
    --fmt-top-bg: linear-gradient(135deg, #1F1633, #2C1C4C);
    --check-accent: var(--check-soft);
    --float-bg: rgba(22, 17, 32, .94);
    --shadow-soft: 0 14px 34px rgba(0, 0, 0, .35);
    --shadow-lift: 0 24px 52px rgba(0, 0, 0, .55);
    --shadow-float: 0 16px 40px rgba(0, 0, 0, .5);
    --field-line: rgba(255, 255, 255, .3);
    --chip-line: rgba(255, 255, 255, .22);
    --btn-line: rgba(183, 148, 255, .38);
    --box-line: rgba(255, 255, 255, .3);
    --night-line: rgba(255, 255, 255, .09);
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--header-h) + 16px); }
body {
  margin: 0;
  font: 400 17px/1.6 var(--f-text);
  color: var(--ink);
  background: var(--paper);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
h1, h2, h3 { margin: 0; font-weight: 700; }
h1, h2 { font-family: var(--f-display); letter-spacing: -.02em; line-height: 1.06; }
h1 { font-size: clamp(34px, 5.6vw, 76px); max-width: 17ch; }
h2 { font-size: clamp(28px, 3.8vw, 54px); font-weight: 500; max-width: 22ch; margin-bottom: clamp(24px, 3vw, 40px); }
h3 { font-size: 19px; line-height: 1.3; font-weight: 600; }
p { margin: 0 0 1em; }
button { font: inherit; color: inherit; }

:focus-visible { outline: 3px solid var(--violet); outline-offset: 3px; }
.skip { position: absolute; left: -9999px; top: 8px; z-index: 100; background: var(--violet); color: #fff; padding: 10px 16px; }
.skip:focus { left: 8px; }

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }
.muted { color: var(--muted); }

/* ===== Кнопки ===== */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  min-height: 52px; padding: 0 28px; border-radius: 100px;
  font: 600 16px/1 var(--f-text); text-decoration: none; cursor: pointer;
  border: 1.5px solid transparent; transition: background-color .2s, color .2s, border-color .2s, transform .35s var(--ease), box-shadow .3s;
  white-space: nowrap; position: relative; overflow: hidden; isolation: isolate;
}
.btn-violet { background: var(--violet); color: #fff; }
.btn-violet:hover { background: var(--violet-hover); }
.btn-black { background: var(--black); color: #fff; }
.btn-black:hover { background: #fff; color: var(--black); }
.btn-ghost { border-color: rgba(255, 255, 255, .5); color: #fff; background: transparent; }
.btn-ghost:hover { border-color: #fff; background: #fff; color: var(--black); }
.btn-ghost-dark { border-color: var(--ink); color: var(--ink); background: transparent; }
.btn-ghost-dark:hover { background: var(--ink); color: var(--bg); }
.btn-block { width: 100%; }
.btn[disabled] { opacity: .6; cursor: progress; }

.text-link { font-weight: 600; color: var(--accent-text); text-decoration: none; border-bottom: 1.5px solid currentColor; padding-bottom: 2px; }
.text-link:hover { color: var(--ink); }

/* ===== Шапка ===== */
.site-header { position: sticky; top: 0; z-index: 50; background: var(--black); color: #fff; }
.header-row { height: var(--header-h); display: flex; align-items: center; gap: 32px; }
.logo { display: inline-flex; align-items: baseline; gap: 6px; text-decoration: none; line-height: 1; }
.logo-a { font: 700 22px/1 var(--f-display); letter-spacing: -.03em; }
.logo-b { font: 500 15px/1 var(--f-text); color: var(--violet-soft); }
.logo-lg .logo-a { font-size: 34px; }
.logo-lg .logo-b { font-size: 20px; }

.nav { display: flex; align-items: center; gap: 28px; margin-left: auto; }
.nav-link { font-size: 15px; font-weight: 500; color: var(--on-dark-muted); text-decoration: none; background: none; border: 0; padding: 8px 0; cursor: pointer; }
.nav-link:hover, .nav-link.is-active, .nav-drop[aria-expanded="true"] { color: #fff; }
.nav-link.is-active { box-shadow: inset 0 -2px 0 var(--violet); }
.nav-drop::after { content: ""; display: inline-block; width: 6px; height: 6px; margin-left: 8px; border-right: 1.5px solid; border-bottom: 1.5px solid; transform: translateY(-3px) rotate(45deg); transition: transform .2s; }
.nav-drop[aria-expanded="true"]::after { transform: translateY(0) rotate(-135deg); }
.nav-phone { font-weight: 600; font-size: 15px; text-decoration: none; white-space: nowrap; }
.nav-phone:hover { color: var(--violet-soft); }
.nav-cta { display: none; }
.header-cta { min-height: 44px; padding: 0 20px; font-size: 15px; }

.nav-services { position: static; }
.mega {
  position: absolute; left: 0; right: 0; top: var(--header-h);
  background: var(--black); border-top: 1px solid var(--on-dark-line); border-bottom: 1px solid var(--on-dark-line);
  display: none; grid-template-columns: repeat(4, 1fr); gap: 32px;
  padding: 36px max(var(--gutter), calc((100vw - var(--wrap)) / 2 + var(--gutter)));
}
.nav-services.is-open .mega { display: grid; }
.mega-col { display: flex; flex-direction: column; gap: 10px; }
.mega-title { font: 700 20px/1.2 var(--f-display); text-decoration: none; margin-bottom: 6px; }
.mega-title:hover, .mega-link:hover { color: var(--violet-soft); }
.mega-link { color: var(--on-dark-muted); text-decoration: none; }

.burger { display: none; margin-left: auto; width: 44px; height: 44px; background: none; border: 0; cursor: pointer; position: relative; }
.burger span { position: absolute; left: 10px; right: 10px; height: 2px; background: #fff; transition: transform .2s; }
.burger span:first-child { top: 17px; }
.burger span:last-child { top: 25px; }
.burger[aria-expanded="true"] span:first-child { transform: translateY(4px) rotate(45deg); }
.burger[aria-expanded="true"] span:last-child { transform: translateY(-4px) rotate(-45deg); }

/* ===== Первый экран ===== */
.hero { background: var(--black); color: #fff; padding: clamp(40px, 7vw, 96px) 0 0; overflow: hidden; }
.hero-title {
  font-size: clamp(30px, 9.2vw, 136px); line-height: .98; letter-spacing: -.035em;
  max-width: 13ch; margin-bottom: clamp(28px, 4vw, 48px);
}
.hero-title .w { display: inline-block; overflow: hidden; vertical-align: top; padding-bottom: .06em; margin-bottom: -.06em; }
.hero-title .w > span { display: inline-block; transform: translateY(105%); animation: rise .9s cubic-bezier(.2, .75, .15, 1) forwards; animation-delay: calc(var(--i) * 80ms + 80ms); }
@keyframes rise { to { transform: none; } }
.hero-sub { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 24px 48px; margin-bottom: clamp(48px, 7vw, 96px); }
.hero-sub p { max-width: 46ch; font-size: clamp(17px, 1.5vw, 20px); color: var(--on-dark-muted); margin: 0; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }

/* Главный элемент: указатель направлений */
.dir-index { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--on-dark-line); }
.dir-index li { border-bottom: 1px solid var(--on-dark-line); }
.dir-row {
  position: relative; display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr) 150px;
  align-items: center; gap: 12px 40px; padding: clamp(18px, 2.4vw, 30px) 0; text-decoration: none; isolation: isolate;
}
.dir-row::before {
  content: ""; position: absolute; inset: 0 calc(var(--gutter) * -1); z-index: -1;
  background: var(--violet); transform: scaleY(0); transform-origin: bottom; transition: transform .35s cubic-bezier(.2, .75, .15, 1);
}
.dir-row:hover::before, .dir-row:focus-visible::before { transform: scaleY(1); }
.dir-name { font: 700 clamp(30px, 5.2vw, 78px)/1 var(--f-display); letter-spacing: -.03em; }
.dir-subs { color: var(--on-dark-muted); font-size: 16px; transition: color .2s; }
.dir-price { font-weight: 600; font-size: 17px; white-space: nowrap; text-align: right; color: var(--violet-soft); transition: color .2s; }
.dir-row:hover .dir-subs, .dir-row:hover .dir-price { color: #fff; }

/* ===== Секции ===== */
.section { padding: var(--section-y) 0; }
.section-tight { padding: clamp(48px, 6vw, 88px) 0; }
.section:not(.section-lilac):not(.process) + .section:not(.section-lilac):not(.process) { padding-top: 0; }
.section-lilac { background: var(--lilac); }
.section-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 12px 32px; margin-bottom: clamp(24px, 3vw, 40px); }
.section-head h2 { margin: 0; }
.lead-text { font-size: clamp(18px, 1.6vw, 21px); line-height: 1.55; max-width: 52ch; }
.empty { font-size: 18px; color: var(--muted); }

.about-grid { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: clamp(40px, 6vw, 96px); align-items: start; }
.facts { margin: 0; display: grid; gap: 0; }
.facts div { display: grid; grid-template-columns: minmax(120px, auto) 1fr; align-items: baseline; gap: 20px; padding: 20px 0; border-top: 1px solid var(--ink); }
.facts div:last-child { border-bottom: 1px solid var(--ink); }
.facts dt { font: 700 clamp(40px, 5vw, 68px)/1 var(--f-display); color: var(--accent-text); letter-spacing: -.03em; }
.facts dd { margin: 0; color: var(--muted); font-size: 17px; }

/* Этапы — это последовательность, поэтому номера */
.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 32px; counter-reset: step; }
.steps li { counter-increment: step; border-top: 2px solid var(--ink); padding-top: 20px; }
.steps li::before { content: counter(step); display: block; font: 700 44px/1 var(--f-display); color: var(--accent-text); margin-bottom: 20px; }
.steps h3 { margin-bottom: 8px; font-size: 20px; }
.steps p { color: var(--muted); margin: 0; font-size: 16px; }
.process { background: var(--lilac); }

.calc-band { background: var(--violet); color: #fff; padding: clamp(48px, 6vw, 80px) 0; }
.calc-band-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 24px 48px; }
.calc-band h2 { margin-bottom: 12px; }
.calc-band p { margin: 0; font-size: 18px; color: rgba(255, 255, 255, .85); }

/* ===== Портфолио ===== */
.projects-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(28px, 3vw, 44px) clamp(20px, 2.5vw, 32px); }
.projects-grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.projects-grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.project-card { text-decoration: none; display: block; }
.project-card.is-big { grid-column: 1 / -1; }
.project-card.is-big .cover { aspect-ratio: 21 / 8; }
.project-card.is-big h3 { font-size: clamp(22px, 2.4vw, 32px); }
.project-card h3 { font-family: var(--f-display); font-size: 20px; line-height: 1.2; margin: 8px 0 8px; transition: color .2s; letter-spacing: -.01em; }
.project-card p { color: var(--muted); margin: 0; font-size: 16px; max-width: 60ch; }
.project-card:hover h3 { color: var(--accent-text); }
.project-meta { display: flex; gap: 16px; font-size: 14px; color: var(--muted); margin-top: 16px; }

.cover {
  --h: 270;
  position: relative; overflow: hidden; aspect-ratio: 4 / 3; container-type: inline-size;
  background:
    radial-gradient(circle at 88% 12%, hsl(var(--h) 100% 72%) 0 18%, transparent 18.5%),
    hsl(var(--h) 82% 52%);
}
.cover img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s cubic-bezier(.2, .75, .15, 1); }
.project-card:hover .cover img { transform: scale(1.03); }
.cover-word {
  position: absolute; left: 6%; right: -20%; bottom: -4%;
  font: 700 17cqw/0.9 var(--f-display); letter-spacing: -.04em; color: var(--black); white-space: nowrap;
}
.cover-hero { aspect-ratio: 21 / 9; margin-top: clamp(-64px, -5vw, -32px); }

.filters { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 32px; }
.chip { display: inline-flex; align-items: center; min-height: 40px; padding: 0 18px; border-radius: 100px; border: 1.5px solid var(--on-dark-line); color: #fff; text-decoration: none; font-weight: 500; font-size: 15px; }
.chip:hover { border-color: #fff; }
.chip.is-active { background: var(--violet); border-color: var(--violet); }

.project-facts { display: flex; flex-wrap: wrap; gap: 16px 48px; margin: 32px 0 0; }
.project-facts dt, .hp-label { display: block; font-size: 14px; color: var(--on-dark-muted); margin-bottom: 4px; }
.project-facts dd { margin: 0; font-weight: 600; }
.project-facts a { text-decoration: none; border-bottom: 1px solid var(--violet-soft); }

.metrics { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 32px; margin: 0; }
.metrics div { border-top: 2px solid var(--ink); padding-top: 16px; }
.metrics dt { font: 700 clamp(36px, 4.4vw, 60px)/1 var(--f-display); color: var(--accent-text); letter-spacing: -.03em; margin-bottom: 8px; }
.metrics dd { margin: 0; color: var(--muted); }

.case-body { display: grid; gap: clamp(40px, 5vw, 64px); }
.case-part { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); gap: 16px 48px; border-top: 1px solid var(--line); padding-top: 32px; }
.case-part h2 { font-size: clamp(22px, 2.4vw, 30px); margin: 0; }

/* ===== Шапка внутренних страниц ===== */
.page-head { background: var(--black); color: #fff; padding: clamp(32px, 4vw, 48px) 0 clamp(56px, 7vw, 96px); }
.page-head h1 { margin: 24px 0 20px; }
.page-lead { font-size: clamp(17px, 1.6vw, 21px); max-width: 58ch; color: var(--on-dark-muted); margin: 0; }
.crumbs { display: flex; flex-wrap: wrap; gap: 8px; font-size: 14px; color: var(--on-dark-muted); }
.crumbs a { text-decoration: none; }
.crumbs a:hover { color: #fff; }
.page-404 { padding: 120px 0; }
.page-404 .hero-actions { margin-top: 32px; }

.head-price { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 24px 56px; margin-top: 40px; padding-top: 28px; border-top: 1px solid var(--on-dark-line); }
.hp-value { font: 700 clamp(20px, 2vw, 26px)/1.2 var(--f-display); letter-spacing: -.01em; }
.head-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-left: auto; }

/* ===== Услуги списком ===== */
.svc-list { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--ink); }
.svc-list li { border-bottom: 1px solid var(--ink); }
.svc-row { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr) 170px; gap: 8px 40px; align-items: baseline; padding: 28px 0; text-decoration: none; }
.svc-title { font: 700 clamp(22px, 2.4vw, 32px)/1.15 var(--f-display); letter-spacing: -.02em; transition: color .2s; }
.svc-lead { color: var(--muted); font-size: 16px; }
.svc-price { font-weight: 600; white-space: nowrap; text-align: right; }
.svc-row:hover .svc-title { color: var(--accent-text); }

.includes { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 20px 40px; }
.includes li { position: relative; padding-left: 28px; font-size: 18px; font-weight: 500; }
.includes li::before { content: ""; position: absolute; left: 0; top: .5em; width: 12px; height: 12px; background: var(--violet); }

.faq-wrap { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.8fr); gap: 16px 64px; }
.faq details { border-bottom: 1px solid var(--line); }
.faq details:first-child { border-top: 1px solid var(--line); }
.faq summary { list-style: none; cursor: pointer; padding: 22px 48px 22px 0; font-weight: 600; font-size: 18px; position: relative; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: ""; position: absolute; right: 8px; top: 50%; width: 14px; height: 14px; margin-top: -7px;
  background: linear-gradient(currentColor, currentColor) center / 100% 2px no-repeat, linear-gradient(currentColor, currentColor) center / 2px 100% no-repeat; transition: transform .2s; }
.faq details[open] summary::after { transform: rotate(45deg); color: var(--accent-text); }
.faq p { color: var(--muted); padding: 0 48px 22px 0; margin: 0; }

/* ===== Текст ===== */
.prose-wrap { display: flex; }
.prose { max-width: 68ch; font-size: 18px; line-height: 1.7; }
.prose h2 { font-size: clamp(24px, 2.6vw, 32px); margin: 1.6em 0 .6em; }
.prose h3 { font-size: 21px; margin: 1.4em 0 .5em; }
.prose > :first-child { margin-top: 0; }
.prose ul, .prose ol { padding-left: 1.3em; margin: 0 0 1em; }
.prose li { margin-bottom: .4em; }
.prose li::marker { color: var(--accent-text); }
.prose a { color: var(--accent-text); }
.prose blockquote { margin: 1.5em 0; padding: 4px 0 4px 24px; border-left: 3px solid var(--violet); font-size: 20px; font-weight: 500; }
.post-figure { margin: 0 0 32px; }
.post-image { width: 100%; }

/* ===== Блог ===== */
.posts-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 40px 32px; }
.posts-grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.post-card { display: block; text-decoration: none; border-top: 2px solid var(--ink); padding-top: 20px; }
.post-card h3 { font: 700 21px/1.25 var(--f-display); letter-spacing: -.01em; margin: 14px 0 10px; transition: color .2s; }
.post-card p { color: var(--muted); font-size: 16px; margin: 0; }
.post-card:hover h3 { color: var(--accent-text); }
.post-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 16px; font-size: 14px; color: var(--muted); }
.page-head .post-meta { color: var(--on-dark-muted); margin-top: 24px; }
.page-head-post h1 { max-width: 24ch; font-size: clamp(30px, 4.4vw, 58px); }
.tag { display: inline-block; padding: 4px 12px; border-radius: 100px; background: var(--lilac); color: var(--accent-text); font-weight: 600; text-decoration: none; }
.page-head .tag { background: var(--violet); color: #fff; }
.post-layout { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 64px; align-items: start; }
.post-aside { position: sticky; top: calc(var(--header-h) + 24px); border-top: 2px solid var(--ink); padding-top: 20px; display: grid; gap: 4px; }
.aside-title { font: 700 18px/1.2 var(--f-display); margin: 0 0 12px; }
.aside-link { display: flex; justify-content: space-between; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); text-decoration: none; font-weight: 500; }
.aside-link:hover { color: var(--accent-text); }
.aside-price { color: var(--muted); font-size: 14px; white-space: nowrap; }
.post-aside .btn { margin-top: 20px; }
.pager { display: flex; gap: 8px; margin-top: 48px; }
.pager a { min-width: 44px; height: 44px; display: grid; place-items: center; border: 1.5px solid var(--ink); border-radius: 100px; text-decoration: none; font-weight: 600; }
.pager a.is-active { background: var(--ink); color: var(--bg); }

/* ===== Отзывы, принципы, контакты ===== */
.reviews { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 40px; }
.review { margin: 0; border-top: 2px solid var(--ink); padding-top: 20px; }
.review blockquote { margin: 0 0 16px; font-size: 18px; }
.review figcaption { color: var(--muted); }
.principles { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 40px; }
.principles h3 { font: 700 21px/1.2 var(--f-display); margin-bottom: 10px; }
.principles p { color: var(--muted); margin: 0; }
.requisites { display: flex; flex-wrap: wrap; gap: 16px 56px; margin: 0; }
.requisites dt { font-size: 14px; color: var(--muted); }
.requisites dd { margin: 0; font-weight: 600; }
.contact-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 0; margin-bottom: 56px; }
.contact-card { display: block; padding: 28px 0; border-top: 2px solid var(--ink); text-decoration: none; margin-right: 32px; }
.contact-card .hp-label { color: var(--muted); }
.contact-value { font: 700 clamp(20px, 2.2vw, 28px)/1.2 var(--f-display); letter-spacing: -.01em; word-break: break-word; transition: color .2s; }
.contact-card:hover .contact-value { color: var(--accent-text); }

/* ===== Заявка ===== */
.lead-section { background: var(--black); color: #fff; padding: clamp(64px, 9vw, 128px) 0; }
.lead-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: clamp(40px, 6vw, 96px); }
.lead-intro p { color: var(--on-dark-muted); font-size: 18px; max-width: 44ch; }
.lead-contacts { list-style: none; padding: 0; margin: 32px 0 0; display: grid; gap: 10px; }
.lead-contacts a { font: 700 clamp(18px, 1.8vw, 22px)/1.3 var(--f-display); text-decoration: none; }
.lead-contacts a:hover { color: var(--violet-soft); }

.lead-form {
  --f-fg: var(--ink); --f-line: var(--field-line); --f-muted: var(--muted);
  display: grid; grid-template-columns: 1fr 1fr; gap: 20px 24px;
}
.lead-section .lead-form { --f-fg: #fff; --f-line: rgba(255, 255, 255, .35); --f-muted: var(--on-dark-muted); }
.field { display: grid; gap: 6px; }
.field-wide { grid-column: 1 / -1; }
.field label { font-size: 14px; color: var(--f-muted); }
.opt { opacity: .7; }
.field input, .field textarea {
  width: 100%; font: 500 18px/1.4 var(--f-text); color: var(--f-fg); background: transparent;
  border: 0; border-bottom: 1.5px solid var(--f-line); padding: 10px 0; border-radius: 0; resize: vertical;
}
.field input:focus, .field textarea:focus { outline: none; border-bottom-color: var(--violet); box-shadow: 0 1.5px 0 var(--violet); }
.field input::placeholder { color: var(--f-muted); opacity: .6; }
.field.has-error input { border-bottom-color: #FF4D6D; }
.consent { display: flex; align-items: flex-start; gap: 12px; font-size: 14px; color: var(--f-muted); cursor: pointer; }
.consent input { width: 20px; height: 20px; margin: 1px 0 0; accent-color: var(--violet); flex-shrink: 0; }
.consent a { color: inherit; }
.form-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 16px 24px; margin-top: 8px; }
.form-status { margin: 0; font-size: 15px; font-weight: 500; }
.form-status.is-error { color: #FF4D6D; }
.form-status.is-ok { color: var(--accent-text); }
.lead-section .form-status.is-ok { color: var(--violet-soft); }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.notice { padding: 14px 18px; border-left: 3px solid var(--violet); background: rgba(123, 44, 255, .12); margin-bottom: 24px; }
.notice-error { border-color: #FF4D6D; background: rgba(255, 77, 109, .12); }
.lead-form.is-sent { display: none; }
.sent-msg { font: 700 clamp(22px, 2.4vw, 30px)/1.25 var(--f-display); }

.lead-dialog { width: min(600px, calc(100vw - 32px)); max-height: calc(100dvh - 32px); border: 0; padding: clamp(28px, 4vw, 48px); background: var(--surface); color: var(--ink); }
.lead-dialog::backdrop { background: rgba(0, 0, 0, .72); }
.lead-dialog h2 { font-size: clamp(24px, 3vw, 34px); margin-bottom: 12px; padding-right: 40px; }
.lead-dialog > p { margin-bottom: 28px; }
.dialog-close { position: absolute; right: 16px; top: 16px; width: 44px; height: 44px; font-size: 30px; line-height: 1; background: none; border: 0; cursor: pointer; }
.dialog-close:hover { color: var(--accent-text); }

/* ===== Калькулятор ===== */
.calc { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 24px 64px; align-items: start; }
.calc-progress { grid-column: 1 / -1; list-style: none; margin: 0 0 16px; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; counter-reset: cs; }
.calc-progress li { counter-increment: cs; border-top: 3px solid var(--line); padding-top: 10px; font-size: 14px; color: var(--muted); }
.calc-progress li::before { content: counter(cs) ". "; }
.calc-progress li.is-done { border-color: var(--ink); color: var(--ink); }
.calc-progress li.is-current { border-color: var(--violet); color: var(--ink); font-weight: 600; }
.calc-q { font-size: clamp(24px, 3vw, 38px); margin-bottom: 24px; }
.calc-choices { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 12px; margin-bottom: 24px; }
.choice {
  text-align: left; cursor: pointer; background: var(--surface); border: 1.5px solid var(--ink); padding: 22px 24px;
  display: grid; gap: 8px; transition: background-color .15s, color .15s;
}
.choice-title { font: 700 20px/1.2 var(--f-display); letter-spacing: -.01em; }
.choice-lead { font-size: 15px; color: var(--muted); line-height: 1.45; }
.choice-price { font-weight: 600; color: var(--accent-text); }
.choice:hover { background: var(--black); color: #fff; }
.choice:hover .choice-lead { color: var(--on-dark-muted); }
.choice:hover .choice-price { color: var(--violet-soft); }
.choice[aria-pressed="true"] { background: var(--violet); border-color: var(--violet); color: #fff; }
.choice[aria-pressed="true"] .choice-lead, .choice[aria-pressed="true"] .choice-price { color: #fff; }
.calc-options { display: grid; gap: 0; border-top: 1px solid var(--line); margin-bottom: 28px; }
.opt-row { display: flex; align-items: center; gap: 16px; padding: 18px 4px; border-bottom: 1px solid var(--line); cursor: pointer; font-size: 18px; font-weight: 500; }
.opt-row input { width: 22px; height: 22px; accent-color: var(--violet); flex-shrink: 0; }
.opt-row .opt-price { margin-left: auto; color: var(--muted); white-space: nowrap; font-weight: 400; }
.opt-row:hover { background: var(--lilac); }
.calc-nav { display: flex; flex-wrap: wrap; gap: 12px; }
.calc-back { margin-top: 8px; }
.calc-result-label { color: var(--muted); margin-bottom: 4px; }
.calc-result { font: 700 clamp(40px, 6vw, 80px)/1 var(--f-display); color: var(--accent-text); letter-spacing: -.03em; margin-bottom: 16px; }
.calc-summary { font-size: 17px; margin-bottom: 8px; }
.calc-step[data-step="4"] .lead-form { margin: 28px 0 16px; }
.calc-total { position: sticky; top: calc(var(--header-h) + 24px); background: var(--black); color: #fff; padding: 28px; display: grid; gap: 6px; }
.calc.is-final .calc-total { display: none; }
.calc-total-value { font: 700 24px/1.2 var(--f-display); letter-spacing: -.02em; }
.calc-total-note { color: var(--on-dark-muted); font-size: 15px; }

/* ===== Подвал ===== */
.site-footer { background: var(--black); color: #fff; padding: 64px 0 32px; border-top: 1px solid var(--on-dark-line); }
.footer-top { display: grid; grid-template-columns: 1.4fr repeat(4, 1fr); gap: 40px 32px; }
.footer-brand p { color: var(--on-dark-muted); margin-top: 16px; max-width: 30ch; font-size: 15px; }
.footer-col { display: flex; flex-direction: column; gap: 8px; font-size: 15px; }
.footer-col a { color: var(--on-dark-muted); text-decoration: none; }
.footer-col a:hover, .footer-contacts a:hover, .footer-bottom a:hover { color: #fff; }
.footer-col .footer-title { color: #fff; font-weight: 600; margin-bottom: 4px; }
.footer-contacts { display: flex; flex-wrap: wrap; gap: 12px 40px; margin: 48px 0 32px; padding-top: 32px; border-top: 1px solid var(--on-dark-line); }
.footer-contacts a { font: 700 18px/1.3 var(--f-display); text-decoration: none; }
.footer-bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px 32px; font-size: 13px; color: var(--on-dark-muted); }
.footer-bottom a { text-decoration: none; }

/* ===== Адаптив ===== */
@media (max-width: 1180px) {
  .nav { gap: 20px; }
  .nav-phone { display: none; }
}
@media (max-width: 1000px) {
  .burger { display: block; }
  .header-cta { display: none; }
  .nav {
    position: fixed; inset: var(--header-h) 0 0 0; background: var(--black);
    flex-direction: column; align-items: stretch; gap: 0; padding: 16px var(--gutter) 40px; overflow-y: auto;
    display: none;
  }
  .nav.is-open { display: flex; }
  .nav-link { font-size: 22px; padding: 14px 0; border-bottom: 1px solid var(--on-dark-line); text-align: left; width: 100%; color: #fff; }
  .nav-link.is-active { box-shadow: none; color: var(--violet-soft); }
  .mega { position: static; padding: 8px 0 20px; border: 0; grid-template-columns: 1fr 1fr; gap: 20px; }
  .mega-title { font-size: 17px; }
  .nav-phone { display: block; margin-top: 24px; font-size: 22px; }
  .nav-cta { display: flex; margin-top: 20px; }
  body.nav-open { overflow: hidden; }

  .about-grid, .lead-grid, .faq-wrap, .post-layout, .calc { grid-template-columns: 1fr; }
  .post-aside, .calc-total { position: static; }
  .calc-total { order: -1; grid-row: 2; }
  .projects-grid, .projects-grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .project-card.is-big .cover { aspect-ratio: 16 / 9; }
  .posts-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .footer-top { grid-template-columns: repeat(2, 1fr); }
  .footer-brand { grid-column: 1 / -1; }
  .dir-row { grid-template-columns: 1fr auto; }
  .dir-price, .svc-price { text-align: left; }
  .dir-subs { grid-column: 1 / -1; grid-row: 2; }
  .svc-row { grid-template-columns: 1fr auto; }
  .svc-lead { grid-column: 1 / -1; grid-row: 2; }
  .case-part { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  body { font-size: 16px; }
  .projects-grid, .projects-grid-2, .projects-grid-3, .posts-grid, .posts-grid-2 { grid-template-columns: 1fr; }
  .lead-form { grid-template-columns: 1fr; }
  .dir-row { grid-template-columns: 1fr; }
  .dir-price { grid-row: 3; }
  .svc-row { grid-template-columns: 1fr; }
  .svc-lead { grid-row: auto; }
  .head-actions { margin-left: 0; width: 100%; }
  .head-actions .btn, .hero-actions .btn { flex: 1 1 auto; }
  .mega { grid-template-columns: 1fr; }
  .facts div { grid-template-columns: 1fr; gap: 6px; }
  .cover-hero { aspect-ratio: 4 / 3; }
  .calc-progress li { font-size: 0; }
  .calc-progress li::before { font-size: 14px; content: counter(cs); }
  .calc-progress li.is-current { font-size: 14px; }
  .calc-progress li.is-current::before { content: counter(cs) ". "; }
  .footer-top { grid-template-columns: 1fr; }
  .contact-card { margin-right: 0; }
}

/* =====================================================================
   Оформление 2.0: воздух, карточки, анимации
   ===================================================================== */

/* ----- Общие элементы ----- */
.eyebrow { font: 700 13px/1.5 var(--f-text); letter-spacing: .12em; text-transform: uppercase; color: var(--accent-text); margin: 0 0 16px; }
.eyebrow-light { color: var(--violet-soft); }
.section-sub { font-size: clamp(17px, 1.5vw, 20px); color: var(--muted); max-width: 54ch; margin: calc(clamp(24px, 3vw, 40px) * -1 + 12px) 0 clamp(32px, 4vw, 56px); }
.section-lilac { background: var(--tint-bg); }
.pill { display: inline-flex; align-items: center; gap: 8px; margin: 0 0 28px; padding: 8px 14px; border-radius: 999px; font: 600 13px/1 var(--f-text); letter-spacing: .02em; background: rgba(255, 255, 255, .07); border: 1px solid rgba(255, 255, 255, .16); color: var(--violet-soft); }
.pill::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--violet-soft); box-shadow: 0 0 0 4px rgba(183, 148, 255, .2); animation: pulse 2.4s ease-in-out infinite; }
.text-link span { display: inline-block; transition: transform .3s var(--ease); }
.text-link:hover span { transform: translateX(4px); }

.btn-violet { box-shadow: 0 12px 26px rgba(123, 44, 255, .28); }
.btn-violet::after {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(110deg, transparent 30%, rgba(255, 255, 255, .35) 50%, transparent 70%);
  transform: translateX(-120%); transition: transform .9s var(--ease);
}
.btn-violet:hover::after { transform: translateX(120%); }
.btn-violet:hover { box-shadow: 0 16px 34px rgba(123, 44, 255, .38); }

.checklist { list-style: none; margin: 0 0 28px; padding: 0; display: grid; gap: 14px; }
.checklist li { position: relative; padding-left: 38px; line-height: 1.45; }
.checklist li::before { content: ""; position: absolute; left: 0; top: -1px; width: 24px; height: 24px; border-radius: 50%; background: var(--lilac) var(--check-accent) center / 12px no-repeat; }
.checklist-lg li { font-size: 18px; font-weight: 500; }

/* ----- Шапка ----- */
.site-header { transition: transform .5s var(--ease-expo), background-color .3s; view-transition-name: site-header; }
.site-header.is-scrolled { background: rgba(0, 0, 0, .86); -webkit-backdrop-filter: saturate(160%) blur(14px); backdrop-filter: saturate(160%) blur(14px); }
.site-header.is-hidden { transform: translateY(-100%); }

/* ----- Первый экран ----- */
.hero {
  position: relative; isolation: isolate;
  padding: clamp(56px, 8vw, 120px) 0 clamp(16px, 2vw, 28px);
  border-radius: 0 0 clamp(28px, 4vw, 48px) clamp(28px, 4vw, 48px);
}
.hero-glow {
  position: absolute; z-index: -1; right: -12%; top: -38%; width: min(1000px, 110vw); aspect-ratio: 1; pointer-events: none;
  background: radial-gradient(closest-side, rgba(123, 44, 255, .55), rgba(123, 44, 255, .16) 50%, transparent 72%);
  translate: calc(var(--px, 0) * 70px) calc(var(--py, 0) * 50px);
  animation: glow-drift 18s ease-in-out infinite alternate;
}
.hero::before {
  content: ""; position: absolute; z-index: -1; left: -18%; bottom: -30%; width: min(700px, 90vw); aspect-ratio: 1; pointer-events: none;
  background: radial-gradient(closest-side, rgba(183, 148, 255, .22), transparent 70%);
  translate: calc(var(--px, 0) * -40px) calc(var(--py, 0) * -30px);
  animation: glow-drift 22s ease-in-out infinite alternate-reverse;
}
.hero::after {
  content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none; opacity: .09; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
/* Первый экран — ровно на высоту окна: размеры считаются и от ширины, и от высоты */
.hero {
  display: flex; flex-direction: column;
  min-height: calc(100vh - var(--header-h)); min-height: calc(100svh - var(--header-h));
  padding: clamp(24px, 4.5vh, 72px) 0 clamp(36px, 6.5vh, 88px);
}
.hero > .wrap { flex: 1; display: flex; flex-direction: column; }
.hero .dir-index { margin-top: auto; }
.hero-pill { align-self: flex-start; margin-bottom: clamp(12px, 2.4vh, 28px); }
.hero-title { max-width: none; font-size: clamp(32px, min(9.2vw, 8.8vh), 136px); margin-bottom: clamp(16px, 3vh, 44px); }
.hero-title .accent > span {
  color: var(--violet); /* если градиентный текст не поддерживается */
  background: linear-gradient(100deg, #7B2CFF 0%, #A56BFF 45%, #C9ADFF 60%, #7B2CFF 100%) 0 0 / 220% 100%;
  -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
  animation: rise .9s cubic-bezier(.2, .75, .15, 1) forwards, shimmer 6s ease-in-out 1.4s infinite;
  animation-delay: calc(var(--i) * 80ms + 80ms), 1.4s;
}
@keyframes shimmer { 0%, 100% { background-position: 0 0; } 50% { background-position: 100% 0; } }
.hero-sub { margin-bottom: clamp(20px, 4vh, 64px); }
.hero-sub p { max-width: 60ch; }
@media (min-width: 1001px) {
  .hero-sub { flex-wrap: nowrap; }
  .hero-sub p { flex: 1 1 auto; }
  .hero-actions { flex-shrink: 0; }
}
.hero .dir-row { padding: clamp(10px, 1.4vh, 28px) 0; }
.hero .dir-name { font-size: clamp(24px, min(5.2vw, 4.6vh), 78px); }
.hero .dir-subs { font-size: 15px; line-height: 1.45; }
.home-about { padding-top: clamp(96px, 12vw, 168px); }
.hero-pill { animation: fade-up .8s var(--ease-expo) both; }
.hero-sub { animation: fade-up 1s var(--ease-expo) .55s both; }
.dir-index li { animation: fade-up .9s var(--ease-expo) both; animation-delay: calc(var(--n, 0) * 80ms + 750ms); }
.dir-name { transition: transform .5s var(--ease-expo); }
.dir-row:hover .dir-name, .dir-row:focus-visible .dir-name { transform: translateX(14px); }
.dir-index li:last-child { border-bottom: 0; }

/* ----- Шапка внутренних страниц ----- */
.page-head {
  position: relative; isolation: isolate; overflow: hidden;
  padding: clamp(40px, 5vw, 64px) 0 clamp(72px, 8vw, 120px);
  border-radius: 0 0 clamp(28px, 4vw, 48px) clamp(28px, 4vw, 48px);
}
.page-head::before {
  content: ""; position: absolute; z-index: -1; right: -10%; top: -60%; width: min(820px, 100vw); aspect-ratio: 1; pointer-events: none;
  background: radial-gradient(closest-side, rgba(123, 44, 255, .45), rgba(123, 44, 255, .12) 50%, transparent 72%);
  translate: calc(var(--px, 0) * 60px) calc(var(--py, 0) * 40px);
  animation: glow-drift 18s ease-in-out infinite alternate;
}
.page-head .crumbs, .page-head h1, .page-head .page-lead, .page-head .head-price, .page-head .post-meta, .page-head .filters, .page-head .project-facts { animation: fade-up .9s var(--ease-expo) both; }
.page-head h1 { animation-delay: .08s; }
.page-head .page-lead, .page-head .post-meta { animation-delay: .18s; }
.page-head .head-price, .page-head .filters, .page-head .project-facts { animation-delay: .28s; }
.cover-hero { border-radius: var(--r-lg); }

/* ----- О студии на главной ----- */
.about-split { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: clamp(40px, 6vw, 104px); align-items: center; }
.about-visual {
  position: relative; isolation: isolate; overflow: hidden; min-height: clamp(400px, 42vw, 580px); border-radius: 28px;
  background:
    radial-gradient(120% 90% at 85% 8%, rgba(183, 148, 255, .9) 0, transparent 55%),
    linear-gradient(155deg, #7B2CFF 0%, #4B12B8 58%, #1A0548 100%);
}
.about-mark { position: absolute; left: -3%; bottom: 14%; z-index: -1; font: 700 clamp(120px, 15vw, 230px)/.8 var(--f-display); letter-spacing: -.06em; color: rgba(255, 255, 255, .1); }
.about-chips { list-style: none; margin: 0; padding: clamp(24px, 3vw, 36px); display: flex; flex-wrap: wrap; gap: 10px; }
.about-chips li {
  padding: 10px 16px; border-radius: 999px; font-weight: 500; font-size: 15px; color: #fff;
  background: rgba(255, 255, 255, .12); border: 1px solid rgba(255, 255, 255, .24);
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
  animation: float 6s ease-in-out infinite; animation-delay: calc(var(--n, 0) * -1.5s);
}
.float-card {
  position: absolute; left: 20px; right: 20px; bottom: 20px; display: flex; align-items: center; gap: 14px;
  padding: 16px 18px; border-radius: 16px; background: var(--float-bg); color: var(--ink); text-decoration: none;
  box-shadow: 0 14px 32px rgba(20, 0, 60, .28); transition: transform .4s var(--ease-expo);
}
.float-card:hover { transform: translateY(-4px); }
.float-icon { width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; background: var(--lilac); color: var(--accent-text); flex-shrink: 0; }
.float-card strong { display: block; font-weight: 600; }
.float-card small { color: var(--muted); font-size: 14px; }
.about-content h2 { max-width: 16ch; }
.about-content .lead-text { color: var(--muted); margin-bottom: 32px; }

.proof {
  margin: clamp(56px, 7vw, 96px) 0 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px;
  padding: clamp(24px, 3vw, 36px) clamp(24px, 3vw, 40px); background: var(--surface); border: 1px solid var(--card-line); border-radius: 24px; box-shadow: var(--shadow-soft);
}
.proof div { display: grid; gap: 6px; align-content: start; padding-left: clamp(16px, 2.5vw, 32px); border-left: 1px solid var(--card-line); }
.proof div:first-child { border-left: 0; padding-left: 0; }
.proof dt { font: 700 clamp(36px, 4vw, 56px)/1 var(--f-display); color: var(--accent-text); letter-spacing: -.03em; font-variant-numeric: tabular-nums; }
.proof dd { margin: 0; color: var(--muted); }

/* ----- Карточки ----- */
.projects-grid { gap: clamp(24px, 3vw, 40px); }
.project-card {
  background: var(--surface); border: 1px solid var(--card-line); border-radius: var(--r); padding: 10px 10px 26px;
  box-shadow: var(--shadow-soft); transition: transform .5s var(--ease-expo), box-shadow .5s var(--ease-expo);
}
.project-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lift); }
.project-card .cover { border-radius: 15px; }
.project-card .project-meta, .project-card h3, .project-card p { padding: 0 14px; }
.cover::after {
  content: ""; position: absolute; inset: 0; pointer-events: none; opacity: 0; transition: opacity .4s;
  background: radial-gradient(circle at var(--mx, 50%) var(--my, 50%), rgba(255, 255, 255, .3), transparent 46%);
}
.project-card:hover .cover::after { opacity: 1; }
.cover-word { transition: transform .9s var(--ease-expo); }
.project-card:hover .cover-word { transform: translateX(-4%); }

.posts-grid { gap: clamp(20px, 2.5vw, 32px); }
.post-card {
  background: var(--surface); border: 1px solid var(--card-line); border-radius: 20px; padding: 28px; box-shadow: var(--shadow-soft);
  transition: transform .5s var(--ease-expo), box-shadow .5s var(--ease-expo);
}
.post-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-lift); }

.steps { gap: 18px; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); }
.steps li { background: var(--surface); border: 1px solid var(--card-line); border-radius: 20px; padding: 28px 26px 30px; box-shadow: var(--shadow-soft); }
.steps li::before { font-size: 40px; margin-bottom: 36px; }

.reviews { gap: 20px; }
.review { background: var(--surface); border: 1px solid var(--card-line); border-radius: 20px; padding: 32px; box-shadow: var(--shadow-soft); }

.svc-row { padding: 36px 0; }
.svc-list li { transition: background-color .3s; }

/* ----- Форматы работы ----- */
.fmt-tabs {
  display: none; position: relative; gap: 4px; padding: 6px; margin: 0 0 32px; max-width: 100%; width: max-content; overflow-x: auto; scrollbar-width: none;
  background: var(--surface); border: 1px solid var(--card-line); border-radius: 999px; box-shadow: var(--shadow-soft);
}
.fmt-tabs::-webkit-scrollbar { display: none; }
.js .fmt-tabs { display: flex; }
.fmt-tabs::before {
  content: ""; position: absolute; top: 6px; bottom: 6px; left: 0; width: var(--ink-w, 0); border-radius: 999px; background: var(--ink);
  transform: translateX(var(--ink-x, 0)); transition: transform .55s var(--ease-expo), width .55s var(--ease-expo);
}
.fmt-tab { position: relative; z-index: 1; flex-shrink: 0; border: 0; background: none; padding: 12px 22px; border-radius: 999px; font-weight: 600; font-size: 15px; color: var(--muted); cursor: pointer; transition: color .3s; }
.fmt-tab:hover { color: var(--ink); }
.fmt-tab[aria-selected="true"] { color: var(--bg); }
.js .has-tabs .fmt-panel:not(.is-active) { display: none; }
.js .has-tabs .fmt-panel-title, .home-formats:not(.has-tabs) .fmt-panel-title { display: none; }
.fmt-panel-title { font: 500 24px/1.2 var(--f-display); margin: 48px 0 20px; }
.fmt-panel-title a { text-decoration: none; }
.fmt-panel:first-of-type .fmt-panel-title { margin-top: 0; }
.fmt-panel.is-entering .fmt-card { animation: fade-up .7s var(--ease-expo) both; }
.fmt-panel.is-entering .fmt-card:nth-child(2) { animation-delay: .08s; }
.fmt-panel.is-entering .fmt-card:nth-child(3) { animation-delay: .16s; }

.fmt-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 360px), 1fr)); gap: clamp(18px, 2vw, 26px); align-items: stretch; }
.fmt-grid.is-single { max-width: 680px; }
.fmt-card {
  display: flex; flex-direction: column; overflow: hidden; background: var(--surface); border: 1px solid var(--card-line); border-radius: var(--r);
  box-shadow: var(--shadow-soft); transition: transform .5s var(--ease-expo), box-shadow .5s var(--ease-expo);
}
.fmt-card:hover { transform: translateY(-5px); box-shadow: var(--shadow-lift); }
.fmt-card.is-featured { border-color: var(--violet); }
/* Шапки карточек в одном ряду одной высоты, «Что входит» начинается на одном уровне */
@supports (grid-template-rows: subgrid) {
  .fmt-card { display: grid; grid-row: span 2; grid-template-rows: subgrid; gap: 0; }
}
.fmt-top { position: relative; padding: clamp(26px, 3vw, 34px); background: var(--fmt-top-bg); }
.is-featured .fmt-top {
  color: #fff;
  background: radial-gradient(90% 130% at 100% 0, rgba(183, 148, 255, .5), transparent 60%), linear-gradient(135deg, #12002E, #3F0F99);
}
.fmt-label { display: inline-block; margin: 0 0 20px; padding: 5px 12px; border-radius: 999px; border: 1px solid var(--chip-line); font: 700 12px/1.5 var(--f-text); letter-spacing: .08em; text-transform: uppercase; }
.is-featured .fmt-label { border-color: rgba(255, 255, 255, .45); }
.fmt-title { font: 500 clamp(26px, 2.6vw, 36px)/1.1 var(--f-display); letter-spacing: -.02em; margin: 0 0 12px; }
.fmt-lead { margin: 0; color: var(--muted); }
.is-featured .fmt-lead { color: rgba(255, 255, 255, .76); }
.fmt-body { display: flex; flex-direction: column; flex: 1; padding: clamp(26px, 3vw, 34px); }
.fmt-sub { font: 500 20px/1.3 var(--f-display); margin: 0 0 18px; }
.fmt-note { margin: 0 0 26px; padding: 14px 16px; border-radius: 12px; background: var(--paper); color: var(--muted); }
.fmt-foot { margin-top: auto; padding-top: 22px; border-top: 1px solid var(--card-line); display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; }
.fmt-price { font: 700 clamp(21px, 2vw, 27px)/1.2 var(--f-display); letter-spacing: -.02em; color: var(--accent-text); }
.fmt-foot .btn { min-height: 48px; padding: 0 22px; font-size: 15px; }

/* ----- Плашка калькулятора ----- */
.cta-card {
  position: relative; isolation: isolate; overflow: hidden; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 28px 48px;
  padding: clamp(40px, 5.5vw, 80px); border-radius: var(--r-lg); color: #fff;
  background: linear-gradient(135deg, #7B2CFF 0%, #5A12E0 100%); box-shadow: 0 26px 60px rgba(123, 44, 255, .3);
}
.cta-card h2 { margin-bottom: 14px; }
.cta-card p:not(.eyebrow) { margin: 0; font-size: 18px; color: rgba(255, 255, 255, .86); max-width: 46ch; }
.cta-card .eyebrow-light { color: rgba(255, 255, 255, .7); }
.cta-glow {
  position: absolute; z-index: -1; right: -140px; top: -220px; width: 560px; aspect-ratio: 1; pointer-events: none;
  background: radial-gradient(closest-side, rgba(255, 255, 255, .36), transparent);
  translate: calc(var(--px, 0) * 90px) calc(var(--py, 0) * 60px);
  animation: glow-drift 14s ease-in-out infinite alternate;
}

/* ----- Заявка ----- */
.lead-section { background: transparent; color: inherit; padding: var(--section-y) 0; }
.lead-card {
  position: relative; isolation: isolate; overflow: hidden; background: var(--black); color: #fff;
  border-radius: var(--r-lg); padding: clamp(36px, 6vw, 88px);
}
.lead-card::before {
  content: ""; position: absolute; z-index: -1; left: -15%; bottom: -60%; width: 760px; aspect-ratio: 1; pointer-events: none;
  background: radial-gradient(closest-side, rgba(123, 44, 255, .4), transparent 72%);
  animation: glow-drift 20s ease-in-out infinite alternate;
}

/* ----- Cookie ----- */
/* Полоска внизу экрана: текст слева, кнопки справа в одну строку */
.cookie {
  position: fixed; z-index: 90; left: 24px; right: 24px; bottom: 24px; display: flex; justify-content: center; pointer-events: none;
  opacity: 0; transform: translateY(24px); transition: transform .6s var(--ease-expo), opacity .4s;
}
.cookie.is-shown { opacity: 1; transform: none; }
.cookie-bar {
  pointer-events: auto; width: 100%; max-width: var(--wrap); display: flex; align-items: center; justify-content: space-between; gap: 24px;
  padding: 16px 16px 16px 24px; border-radius: 18px; color: var(--ink);
  background: var(--float-bg); border: 1px solid var(--card-line); box-shadow: var(--shadow-float);
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
}
.cookie-text { margin: 0; max-width: 680px; font-size: 14px; line-height: 1.45; color: var(--muted); }
.cookie-text a { color: var(--accent-text); }
.cookie-actions { display: flex; gap: 8px; flex-shrink: 0; }
.cookie-btn {
  min-height: 44px; padding: 0 18px; border-radius: 999px; border: 1px solid var(--btn-line); background: transparent;
  font: 600 14px/1 var(--f-text); color: var(--accent-text); white-space: nowrap; cursor: pointer;
  transition: background-color .2s, border-color .2s, color .2s;
}
.cookie-btn:hover { border-color: var(--violet); background: var(--lilac); }
.cookie-btn.is-primary { background: var(--violet); border-color: var(--violet); color: #fff; }
.cookie-btn.is-primary:hover { background: var(--violet-hover); border-color: var(--violet-hover); }
@media (max-width: 760px) {
  .cookie { left: 12px; right: 12px; bottom: 12px; }
  .cookie-bar { flex-direction: column; align-items: stretch; gap: 12px; padding: 16px; }
  .cookie-actions { flex-wrap: wrap; }
  .cookie-btn { flex: 1 1 auto; }
}
.footer-links { display: flex; flex-wrap: wrap; gap: 8px 24px; }
.footer-cookie { padding: 0; border: 0; background: none; font: inherit; color: inherit; cursor: pointer; }
.footer-cookie:hover { color: #fff; }

/* Кнопка «Настройки cookie» после выбора, как на sitedona: таблетка в правом нижнем углу */
.cookie-fab {
  position: fixed; z-index: 89; right: 24px; bottom: 24px; min-height: 44px; padding: 0 16px; border-radius: 999px;
  border: 1px solid var(--btn-line); background: var(--float-bg); color: var(--accent-text); font: 600 13px/1 var(--f-text);
  box-shadow: 0 6px 18px rgba(46, 16, 101, .12); cursor: pointer; -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  opacity: 0; transform: translateY(12px); transition: opacity .4s, transform .5s var(--ease-expo), border-color .2s;
}
.cookie-fab.is-shown { opacity: 1; transform: none; }
.cookie-fab:hover { border-color: var(--violet); }
@media (max-width: 760px) { .cookie-fab { right: 12px; bottom: 12px; } }

/* ----- Переключатель темы ----- */
.theme-toggle {
  order: 3; flex-shrink: 0; width: 40px; height: 40px; display: grid; place-items: center; padding: 0;
  border-radius: 50%; border: 1px solid var(--on-dark-line); background: transparent; color: #fff; cursor: pointer;
  transition: border-color .2s, background-color .2s;
}
.header-cta { order: 4; }
.theme-toggle:hover { border-color: #fff; background: rgba(255, 255, 255, .08); }
.theme-toggle svg { width: 18px; height: 18px; transition: transform .6s var(--ease-expo); }
.theme-toggle:hover svg { transform: rotate(-20deg); }
.theme-toggle .i-sun { display: none; }
:root[data-theme="dark"] .theme-toggle .i-sun { display: block; }
:root[data-theme="dark"] .theme-toggle .i-moon { display: none; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .theme-toggle .i-sun { display: block; }
  :root:not([data-theme="light"]) .theme-toggle .i-moon { display: none; }
}
@media (max-width: 1000px) {
  .header-row { gap: 12px; }
  .theme-toggle { order: 0; margin-left: auto; }
  .header-row .burger { margin-left: 0; }
}
/* Смена темы — мягкое перетекание вместо сдвига страниц */
:root.vt-theme::view-transition-old(root) { animation: vt-fade-out .35s ease both; }
:root.vt-theme::view-transition-new(root) { animation: vt-fade-in .35s ease both; }
@keyframes vt-fade-out { to { opacity: 0; } }
@keyframes vt-fade-in { from { opacity: 0; } }

/* В тёмной теме тёмные блоки отделены от фона тонкой линией */
.hero, .page-head { box-shadow: 0 1px 0 var(--night-line); }
.lead-card { box-shadow: inset 0 0 0 1px var(--night-line); }

/* ----- Калькулятор ----- */
.calc-hint { color: var(--muted); margin: -12px 0 24px; }
.calc-step:not([hidden]) { animation: fade-up .6s var(--ease-expo) both; }
.calc-nav { margin-top: 32px; }
.calc-nav .btn[disabled] { opacity: .35; cursor: not-allowed; box-shadow: none; }
.calc-choices { gap: 14px; margin-bottom: 0; }
.choice {
  position: relative; border: 1.5px solid var(--card-line); border-radius: 18px; padding: 24px 58px 24px 24px; box-shadow: var(--shadow-soft);
  transition: background-color .25s, color .25s, border-color .25s, transform .4s var(--ease-expo), box-shadow .4s var(--ease-expo);
}
.choice:hover { background: var(--surface); color: var(--ink); border-color: var(--ink); transform: translateY(-3px); box-shadow: var(--shadow-lift); }
.choice:hover .choice-lead { color: var(--muted); }
.choice:hover .choice-price { color: var(--accent-text); }
.choice[aria-pressed="true"], .choice[aria-pressed="true"]:hover { background: var(--violet); border-color: var(--violet); color: #fff; box-shadow: 0 16px 34px rgba(123, 44, 255, .3); }
.choice[aria-pressed="true"] .choice-lead, .choice[aria-pressed="true"] .choice-price { color: #fff; }
.choice-check { position: absolute; top: 22px; right: 22px; width: 24px; height: 24px; border-radius: 7px; border: 1.5px solid var(--box-line); background: var(--surface); transition: border-color .25s, background-color .25s; }
.choice[aria-pressed="true"] .choice-check { border-color: #fff; background: #fff var(--check-violet) center / 14px no-repeat; animation: pop .4s var(--ease-expo); }
.calc-group + .calc-group { margin-top: 36px; }
.calc-group-title { font: 700 13px/1.4 var(--f-text); letter-spacing: .1em; text-transform: uppercase; color: var(--accent-text); margin: 0 0 14px; }
.calc-options { overflow: hidden; margin-bottom: 0; border: 1px solid var(--card-line); border-radius: 18px; background: var(--surface); box-shadow: var(--shadow-soft); }
.opt-row { position: relative; padding: 18px 22px; border-bottom: 1px solid var(--card-line); transition: background-color .2s; }
.opt-row:last-child { border-bottom: 0; }
.opt-row input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.opt-box { width: 22px; height: 22px; flex-shrink: 0; border-radius: 6px; border: 1.5px solid var(--box-line); transition: background-color .2s, border-color .2s; }
.opt-row input:checked + .opt-box { background: var(--violet) var(--check-white) center / 12px no-repeat; border-color: var(--violet); animation: pop .35s var(--ease-expo); }
.opt-row input:focus-visible + .opt-box { outline: 3px solid var(--violet); outline-offset: 2px; }
.calc-total { border-radius: 22px; box-shadow: inset 0 0 0 1px var(--night-line), 0 22px 48px rgba(0, 0, 0, .2); }
.calc-total-value { font-variant-numeric: tabular-nums; }
.calc-total-list { list-style: none; margin: 14px 0 0; padding: 14px 0 0; border-top: 1px solid rgba(255, 255, 255, .14); display: grid; gap: 8px; font-size: 14px; color: var(--on-dark-muted); }
.calc-total-list:empty { display: none; }
.calc-total-list li { display: flex; gap: 10px; align-items: baseline; }
.calc-total-list li::before { content: ""; flex-shrink: 0; width: 6px; height: 6px; border-radius: 50%; background: var(--violet-soft); transform: translateY(-2px); }
.calc-result { display: flex; flex-direction: column; gap: 8px; font-variant-numeric: tabular-nums; }
.calc-result-extra { font-size: .5em; color: var(--ink); }
.calc-lines { list-style: none; margin: 8px 0 20px; padding: 0; background: var(--surface); border: 1px solid var(--card-line); border-radius: 18px; box-shadow: var(--shadow-soft); }
.calc-lines:empty { display: none; }
.calc-lines > li { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 4px 24px; padding: 18px 22px; border-bottom: 1px solid var(--card-line); }
.calc-lines > li:last-child { border-bottom: 0; }
.cl-name { display: grid; }
.cl-title { font-weight: 600; }
.cl-dir { font-size: 14px; color: var(--muted); }
.cl-price { font-weight: 600; color: var(--accent-text); white-space: nowrap; }
.cl-opts { grid-column: 1 / -1; list-style: none; margin: 6px 0 0; padding: 0; display: grid; gap: 4px; font-size: 15px; color: var(--muted); }
.cl-opts li { display: flex; justify-content: space-between; gap: 16px; }
.cl-opts li span:first-child::before { content: "+ "; color: var(--accent-text); }
.calc-summary:empty { display: none; }

/* ----- Появление при прокрутке ----- */
.js [data-rv]:not(.split) { opacity: 0; transform: translate3d(0, 34px, 0); }
.js [data-rv].is-in:not(.split) { opacity: 1; transform: none; transition: opacity .9s var(--ease), transform 1.1s var(--ease-expo); transition-delay: var(--rd, 0ms); }
.split .w { display: inline-block; overflow: hidden; vertical-align: top; padding-bottom: .14em; margin-bottom: -.14em; }
.split .w > span { display: inline-block; transform: translateY(110%); transition: transform 1.1s var(--ease-expo); transition-delay: calc(var(--i, 0) * 45ms + var(--rd, 0ms)); }
.split.is-in .w > span { transform: none; }

/* ----- Переходы между страницами (Chrome, Edge, Safari 18+) ----- */
@view-transition { navigation: auto; }
::view-transition-old(root) { animation: vt-out .25s var(--ease) both; }
::view-transition-new(root) { animation: vt-in .55s var(--ease-expo) both; }

@keyframes fade-up { from { opacity: 0; transform: translate3d(0, 28px, 0); } to { opacity: 1; transform: none; } }
@keyframes glow-drift { 0% { transform: translate3d(0, 0, 0) scale(1); } 50% { transform: translate3d(-4%, 6%, 0) scale(1.08); } 100% { transform: translate3d(3%, -3%, 0) scale(.96); } }
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
@keyframes pulse { 0%, 100% { box-shadow: 0 0 0 4px rgba(183, 148, 255, .2); } 50% { box-shadow: 0 0 0 8px rgba(183, 148, 255, 0); } }
@keyframes pop { 0% { transform: scale(.6); } 60% { transform: scale(1.12); } 100% { transform: scale(1); } }
@keyframes vt-out { to { opacity: 0; transform: translateY(-10px); } }
@keyframes vt-in { from { opacity: 0; transform: translateY(16px); } }

/* ----- Адаптив нового оформления ----- */
@media (max-width: 1000px) {
  .about-split { grid-template-columns: 1fr; }
  .about-visual { min-height: 380px; order: 2; }
  .cta-card { flex-direction: column; align-items: flex-start; }
}
@media (max-width: 640px) {
  .proof { grid-template-columns: 1fr; gap: 0; padding: 8px 24px; }
  .proof div { padding: 18px 0; border-left: 0; border-top: 1px solid var(--card-line); }
  .proof div:first-child { border-top: 0; }
  .fmt-foot { flex-direction: column; align-items: stretch; }
  .fmt-foot .btn { width: 100%; }
  .choice { padding: 20px 54px 20px 20px; }
  .calc-lines > li { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-delay: 0s !important; transition-duration: .01ms !important; transition-delay: 0s !important; }
  .hero-title .w > span, .split .w > span { transform: none; }
  .js [data-rv]:not(.split) { opacity: 1; transform: none; }
  @view-transition { navigation: none; }
}
