/* itach-soft.ru — шаблон itach_soft.
   Визуальный язык построен на логотипе Itach: скруглённый треугольник «плей» (assets/img/mark.svg)
   и его градиент #FF6713 → #DC281E — единственный акцент. Холодный светлый фон, белые карточки,
   шрифт Manrope (как в макете sofiyawalko.github.io/Itach-soft). Сайт всегда светлый.
   Скругления: кнопки и чипы — капсула, поля 12px, карточки 20px, фото 24px, крупные панели 28px.
   Знак-треугольник — только крупная форма за фото в первом экране (одна на страницу). */

/* Manrope (как в макете) — variable-шрифт 400–800, свои файлы вместо Google Fonts; кириллица и латиница отдельно по unicode-range. */
@font-face { font-family: "Manrope"; src: url("../fonts/Manrope-cyrillic.woff2") format("woff2"); font-weight: 400 800; font-display: swap; unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116; }
@font-face { font-family: "Manrope"; src: url("../fonts/Manrope-latin.woff2") format("woff2"); font-weight: 400 800; font-display: swap; unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }

:root {
  --bg: #f3f4f7;
  --surface: #ffffff;
  --surface-2: #eceef3;
  --text: #171922;
  --text-muted: #5b6072;
  --line: #e1e4eb;
  /* Тёмный цвет кнопок и выделенных карточек. */
  --ink: #171922;
  --ink-text: #ffffff;
  --ink-muted: #b9bdcb;
  /* Фирменный градиент логотипа. Для текста — затемнённый тон с контрастом AA на белом. */
  --brand-1: #ff6713;
  --brand-2: #dc281e;
  --grad: linear-gradient(135deg, var(--brand-1), var(--brand-2));
  --accent: #f0510f;
  --accent-strong: #c22f12;
  --accent-soft: #fff0e8;
  --grad-soft: linear-gradient(135deg, #fff4ec 0%, #ffe7dc 100%);
  --mark: url("../img/mark.svg");
  --shadow: 0 1px 2px rgb(23 25 34 / .04), 0 14px 36px rgb(23 25 34 / .07);
  --shadow-hover: 0 2px 4px rgb(23 25 34 / .05), 0 22px 48px rgb(23 25 34 / .11);
  --radius-control: 999px;
  --radius-input: 12px;
  --radius-card: 20px;
  --radius-media: 24px;
  --radius-panel: 28px;
  --container: 1320px;
  --header-h: 64px;
  --ease: cubic-bezier(.16, 1, .3, 1);
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--header-h) + 32px); }
body {
  margin: 0;
  font-family: "Manrope", system-ui, -apple-system, "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
.hero__grid > *, .flagship > *, .bento > *, .cases > *, .lead-form > *, .footer__cols > * { min-width: 0; }
a { color: inherit; }
h1, h2, h3, h4 { margin: 0; line-height: 1.15; font-weight: 700; letter-spacing: -.015em; }
h1 { font-weight: 800; letter-spacing: -.03em; }
h2 { font-weight: 600; letter-spacing: -.03em; } /* заголовки секций — полужирные, как в макете */
p { margin: 0; }
:focus-visible { outline: 2px solid var(--accent-strong); outline-offset: 3px; border-radius: 6px; }
.nowrap { white-space: nowrap; }


.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 24px; }
@media (max-width: 767px) { .container { padding: 0 16px; } }

.section { padding: 88px 0; }
.section--tight { padding: 48px 0; }
.section__title { font-size: clamp(30px, 3.4vw, 46px); line-height: 1.06; max-width: 24ch; text-wrap: balance; }
.section__lead { margin-top: 16px; color: var(--text-muted); max-width: 62ch; }
.section__head { margin-bottom: 40px; }
@media (max-width: 767px) { .section { padding: 56px 0; } .section__head { margin-bottom: 28px; } }

/* Кнопки: капсулы. Основная — тёмная, вторичная — белая. */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 50px; padding: 0 26px;
  border: 1px solid transparent; border-radius: var(--radius-control);
  font-family: inherit; font-size: 16px; font-weight: 600; line-height: 1; white-space: nowrap;
  text-decoration: none; cursor: pointer;
  transition: background-color .2s var(--ease), color .2s var(--ease), border-color .2s var(--ease), transform .15s var(--ease), box-shadow .2s var(--ease);
}
.btn:active { transform: translateY(1px) scale(.99); }
.btn--primary { background: var(--ink); color: #fff; }
.btn--primary:hover { background: #2b2e3b; box-shadow: 0 10px 24px rgb(23 25 34 / .18); }
.btn--ghost { background: var(--surface); color: var(--text); border-color: var(--line); }
.btn--ghost:hover { border-color: var(--text); }
.btn--sm { min-height: 42px; padding: 0 18px; font-size: 15px; }
/* Акцентная кнопка (шапка, первый экран главной): фирменный оранжевый, затемнён до контраста с белым текстом. */
.btn--accent { background: linear-gradient(135deg, #f0510f, #c8301a); color: #fff; }
.btn--accent:hover { box-shadow: 0 10px 26px rgb(232 72 15 / .32); filter: brightness(1.05); }

.link-arrow { display: inline-flex; align-items: center; gap: 8px; color: var(--accent-strong); font-weight: 600; text-decoration: none; }
.link-arrow::after { content: "→"; transition: transform .2s var(--ease); }
.link-arrow:hover::after { transform: translateX(3px); }

/* Шапка: белая плавающая панель-капсула над серым фоном */
.header { position: sticky; top: 0; z-index: 30; padding: 12px 0; background: linear-gradient(var(--bg) 60%, rgb(243 244 247 / 0)); }
.header__inner {
  display: flex; align-items: center; gap: 20px; height: var(--header-h);
  max-width: calc(var(--container) - 24px); padding: 0 12px 0 24px;
  background: rgb(255 255 255 / .92); border: 1px solid var(--line); border-radius: var(--radius-control);
  box-shadow: 0 6px 24px rgb(23 25 34 / .05);
  backdrop-filter: saturate(160%) blur(12px); -webkit-backdrop-filter: saturate(160%) blur(12px);
}
/* Главная: шапка без подложки-градиента, первый экран заезжает под неё (см. .home-hero) */
.header--over { background: none; }
.header__logo { flex: none; display: block; }
.header__logo img { width: auto; height: 44px; } /* как в макете: 2.75rem на десктопе, 2.5rem до 1024px */
@media (max-width: 1023px) { .header__logo img { height: 40px; } }
.header__nav { flex: 1; margin-left: clamp(8px, 6vw, 88px); } /* как в макете: пункты отступают от логотипа, ближе к центру */
.header__aside { display: flex; align-items: center; gap: 16px; flex: none; }
.header__phone { font-weight: 700; text-decoration: none; white-space: nowrap; }
.header__burger { display: none; }

.nav { display: flex; align-items: center; gap: 2px; list-style: none; margin: 0; padding: 0; }
.nav__item { position: relative; }
.nav__link {
  display: inline-flex; align-items: center; gap: 4px; height: var(--header-h); padding: 0 10px;
  font-weight: 600; font-size: 15px; text-decoration: none; color: var(--text);
  background: none; border: 0; cursor: pointer; font-family: inherit;
}
.nav__link[aria-current="page"] { color: var(--accent-strong); }
/* Подчёркивание градиентом рисуется слева направо при наведении (как в макете). */
.nav__text { padding-bottom: 3px; background: var(--grad) left bottom / 0 2px no-repeat; transition: background-size .35s var(--ease); }
.nav__link:hover .nav__text, .nav__link:focus-visible .nav__text, .nav__item.is-open > .nav__link .nav__text { background-size: 100% 2px; }

/* Выпадающие панели меню: белая карточка под шапкой */
.mega {
  position: absolute; left: -16px; top: calc(100% - 4px); z-index: 5;
  padding: 12px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-panel); box-shadow: var(--shadow-hover);
  opacity: 0; visibility: hidden; transform: translateY(6px);
  transition: opacity .2s var(--ease), transform .2s var(--ease), visibility .2s;
}
.nav__item.is-open > .mega { opacity: 1; visibility: visible; transform: none; }
.mega--list { display: grid; min-width: 260px; }
.mega__item {
  display: block; padding: 9px 14px; border-radius: 12px; color: var(--text-muted); font-size: 15px; font-weight: 500; line-height: 1.35; text-decoration: none;
  transition: color .15s var(--ease), transform .4s var(--ease);
}
.mega__item:hover { color: var(--text); transform: translateX(6px); }
/* Мега-меню услуг: на всю ширину шапки — категории | услуги в две колонки | баннер заявки */
.nav__item--mega { position: static; }
.mega--wide {
  left: 0; right: 0; top: calc(100% + 8px);
  display: grid; grid-template-columns: 240px minmax(0, 1fr) 280px; gap: 32px; padding: 28px;
}
.mega--wide::before { content: ""; position: absolute; left: 0; right: 0; bottom: 100%; height: 12px; } /* мостик: курсор не «проваливается» между шапкой и панелью */
.mega__cats { display: grid; align-content: start; gap: 4px; list-style: none; margin: 0; padding: 0; }
.mega__cat {
  display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 11px 14px; border-radius: 14px;
  font-weight: 600; line-height: 1.3; text-decoration: none; transition: background-color .15s var(--ease);
}
.mega__cat::after { content: ""; width: 7px; height: 7px; border: solid var(--text-muted); border-width: 1.5px 1.5px 0 0; transform: rotate(45deg); transition: transform .2s var(--ease); }
.mega__cat:hover, .mega__cat.is-active { background: var(--bg); }
.mega__cat.is-active::after { border-color: var(--text); transform: translateX(2px) rotate(45deg); }
.mega__all { margin: 12px 14px 0; font-size: 15px; }
.mega__panel { display: none; }
.mega__panel.is-active { display: block; }
.mega__panel-head { display: none; }
.mega__list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); grid-template-rows: repeat(var(--rows, 5), auto); grid-auto-flow: column; /* --rows = половина списка (шаблон меню): две колонки сверху вниз */ column-gap: 24px; row-gap: 2px; align-content: start; list-style: none; margin: 0; padding: 0; }
.mega__promo {
  display: flex; flex-direction: column; gap: 10px; overflow: hidden;
  min-height: 300px; padding: 24px; border-radius: var(--radius-card); background: var(--bg);
}
/* Текст баннера — свой у каждой категории; виден текст активной */
.mega__promo-body { display: none; flex-direction: column; align-items: flex-start; gap: 10px; }
.mega__promo-body.is-active { display: flex; }
.mega__promo-title { font-size: 21px; font-weight: 700; letter-spacing: -.02em; line-height: 1.15; }
.mega__promo-text { font-size: 15px; line-height: 1.45; color: var(--text-muted); }
.mega__promo .btn { margin-top: 6px; }
/* Иллюстрация из макета прижата к низу карточки */
.mega__promo-image { flex: none; align-self: center; width: 100%; height: auto; margin-top: auto; padding-top: 16px; }
@media (max-width: 1320px) { .mega--wide { grid-template-columns: 220px minmax(0, 1fr); } .mega__promo { display: none; } }

/* Выбор города */
.region { position: relative; }
.region__toggle {
  display: inline-flex; align-items: center; gap: 6px; padding: 8px 0;
  background: none; border: 0; color: var(--text-muted); font-family: inherit; font-size: 15px; font-weight: 500; line-height: 1; cursor: pointer; white-space: nowrap;
}
.region__toggle:hover { color: var(--text); }
.region__toggle::after { content: ""; width: 6px; height: 6px; border: solid currentColor; border-width: 0 1.5px 1.5px 0; transform: translateY(-2px) rotate(45deg); }
.region__list {
  position: absolute; right: 0; top: calc(100% + 12px); z-index: 2;
  width: 520px; max-width: calc(100vw - 32px); padding: 14px;
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 2px;
  list-style: none; margin: 0;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-card); box-shadow: var(--shadow-hover);
}
.region__list[hidden] { display: none; }
.region__link { display: block; padding: 9px 12px; border-radius: 12px; text-decoration: none; font-size: 15px; }
.region__link:hover { background: var(--accent-soft); }
.region__link[aria-current="true"] { color: var(--accent-strong); font-weight: 600; }
.region__suggest {
  position: absolute; right: 0; top: calc(100% + 12px); z-index: 3;
  width: 300px; max-width: calc(100vw - 32px); padding: 18px;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-card); box-shadow: var(--shadow-hover);
}
.region__suggest-text { margin: 0 0 12px; font-size: 16px; }
.region__suggest-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.region__list:not([hidden]) ~ .region__suggest { display: none; }
@media (max-width: 767px) {
  .region__suggest, .region__list { position: fixed; left: 16px; right: 16px; top: calc(var(--header-h) + 28px); width: auto; max-width: none; }
}

@media (max-width: 1280px) {
  .header__phone { display: none; }
}
/* Минимальная шапка рекламного визита: логотип, телефон, кнопка заявки. Телефон виден на любой ширине. */
.header--minimal .header__inner { justify-content: space-between; }
.header--minimal .header__phone { display: inline; }
.header--minimal .header__aside > .btn { display: inline-flex; }
@media (max-width: 480px) { .header--minimal .header__aside .btn { display: none; } }
@media (max-width: 1180px) {
  .header__nav, .header__aside > .btn { display: none; }
  .header__burger {
    display: inline-flex; flex-direction: column; justify-content: center; gap: 5px;
    width: 44px; height: 44px; margin-left: auto; padding: 0 12px;
    background: var(--ink); border: 0; border-radius: 50%; cursor: pointer;
  }
  .header__burger span { display: block; height: 2px; background: #fff; border-radius: 2px; }
  /* backdrop-filter делает капсулу containing block для fixed-потомков — пока меню открыто, снимаем его, иначе слой меню сжимается до высоты шапки */
  .header.is-menu-open .header__inner { -webkit-backdrop-filter: none; backdrop-filter: none; background: var(--surface); }
  .header.is-menu-open .header__nav {
    display: block; position: fixed; inset: calc(var(--header-h) + 24px) 0 0 0; overflow-y: auto;
    background: var(--bg); padding: 16px;
  }
  .nav { flex-direction: column; align-items: stretch; }
  .nav__link { height: auto; padding: 14px 4px; font-size: 18px; width: 100%; justify-content: space-between; }
  .mega { position: static; min-width: 0; grid-template-columns: 1fr; padding: 0 0 8px 8px; border: 0; box-shadow: none; background: none; display: none; opacity: 1; visibility: visible; transform: none; }
  .nav__item.is-open > .mega { display: grid; }
  .nav__link--parent::after { content: ""; width: 8px; height: 8px; border: solid currentColor; border-width: 0 1.5px 1.5px 0; transform: translateY(-3px) rotate(45deg); transition: transform .2s var(--ease); }
  .nav__item.is-open > .nav__link--parent::after { transform: translateY(2px) rotate(-135deg); }
  .mega__item { padding: 9px 4px; font-size: 16px; }
  .mega__item:hover { transform: none; }
  .mega--wide { grid-template-columns: 1fr; gap: 0; padding: 0 0 8px 8px; }
  .mega--wide::before, .mega__cats, .mega__promo { display: none; }
  .mega__panel { display: block; padding-bottom: 8px; }
  .mega__panel-head { display: block; padding: 10px 4px 4px; font-weight: 700; text-decoration: none; }
  .mega__list { grid-template-columns: 1fr; grid-template-rows: none; grid-auto-flow: row; }
  .nav__text { background: none; padding: 0; }
  .region__list { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 767px) {
  .header { padding: 8px 0; }
  .header__inner { margin: 0 8px; width: auto; padding: 0 6px 0 18px; }
}

/* Главный экран посадочных: текст слева, фото справа на фирменном знаке */
.hero { padding: 40px 0 72px; overflow-x: clip; }
.hero__grid { position: relative; isolation: isolate; display: grid; grid-template-columns: 1.1fr 1fr; gap: 64px; align-items: center; }
.hero__grid::after {
  content: ""; position: absolute; z-index: -1; right: -40px; top: -24px; width: min(30vw, 380px); aspect-ratio: 54 / 60;
  background: var(--mark) center / contain no-repeat; opacity: .9; pointer-events: none;
}
.hero__title { font-size: clamp(32px, 4.2vw, 58px); line-height: 1.04; text-wrap: balance; }
.hero__title em { display: block; font-style: normal; color: var(--accent-strong); }
.hero__lead { margin-top: 22px; font-size: 19px; color: var(--text-muted); max-width: 46ch; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.hero__media { border-radius: var(--radius-media); overflow: hidden; aspect-ratio: 4 / 3; background: var(--surface-2); box-shadow: var(--shadow); }
.hero__media img { width: 100%; height: 100%; object-fit: cover; }
@media (max-width: 900px) {
  .hero { padding: 24px 0 48px; }
  .hero__grid { grid-template-columns: 1fr; gap: 32px; }
  .hero__grid::after { width: 46vw; right: -24px; top: auto; bottom: 30%; }
}

/* Факты о статусе: белая панель с разделителями */
.facts__list {
  display: grid; grid-template-columns: repeat(4, 1fr); list-style: none; margin: 0; padding: 0;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-card);
}
.facts__item { padding: 26px 28px; }
.facts__item + .facts__item { border-left: 1px solid var(--line); }
.facts__value { display: block; font-weight: 800; font-size: 21px; letter-spacing: -.02em; }
.facts__label { display: block; margin-top: 4px; font-size: 15px; color: var(--text-muted); }
.facts__list--5 { grid-template-columns: repeat(5, 1fr); }
.page-head + .facts { margin-top: 28px; }
@media (max-width: 900px) {
  .facts__list, .facts__list--5 { grid-template-columns: 1fr 1fr; }
  .facts__item, .facts__item + .facts__item { padding: 20px; border-left: 0; border-top: 1px solid var(--line); }
  .facts__item:nth-child(-n+2) { border-top: 0; }
  .facts__item:nth-child(even) { border-left: 1px solid var(--line); }
}

/* Плитка разного размера (разделы /cms/, /developer/ и др.) */
.bento { display: grid; grid-template-columns: repeat(6, 1fr); gap: 16px; }
.bento__cell {
  position: relative; display: flex; flex-direction: column; justify-content: flex-end; gap: 10px;
  min-height: 240px; padding: 28px;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-card);
  text-decoration: none; overflow: hidden; isolation: isolate;
  transition: transform .25s var(--ease), box-shadow .25s var(--ease);
}
a.bento__cell:hover { transform: translateY(-3px); box-shadow: var(--shadow-hover); }
.bento__cell--lead { grid-column: span 4; grid-row: span 2; min-height: 496px; }
.bento__cell--photo { color: #fff; border: 0; }
.bento__cell--photo::before { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgb(23 25 34 / 0) 30%, rgb(23 25 34 / .84)); z-index: 0; }
.bento__cell--photo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -1; }
.bento__cell--photo > * { position: relative; z-index: 1; }
.bento__cell--wide { grid-column: span 3; }
.bento__cell--side { grid-column: span 2; }
.bento__cell--tint { background: var(--grad-soft); border-color: transparent; }
.bento__title { font-size: 22px; }
.bento__cell--lead .bento__title { font-size: clamp(26px, 2.6vw, 34px); }
.bento__text { color: var(--text-muted); font-size: 16px; max-width: 44ch; }
.bento__cell--photo .bento__text { color: rgb(255 255 255 / .86); }
@media (max-width: 900px) {
  .bento { grid-template-columns: 1fr; }
  .bento__cell, .bento__cell--lead, .bento__cell--wide, .bento__cell--side { grid-column: auto; grid-row: auto; min-height: 200px; }
  .bento__cell--lead { min-height: 360px; }
}

/* Флагман: текст и фото в белой панели */
.flagship { display: grid; grid-template-columns: 1fr 1.1fr; gap: 56px; align-items: center; }
.flagship__media { border-radius: var(--radius-media); overflow: hidden; aspect-ratio: 3 / 2; }
.flagship__media img { width: 100%; height: 100%; object-fit: cover; }
@media (max-width: 900px) { .flagship { grid-template-columns: 1fr; gap: 28px; } }

/* Карточки-ссылки (отрасли, задачи на посадочных) */
.h-head { display: flex; justify-content: space-between; align-items: end; gap: 24px; margin-bottom: 36px; }
.h-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; list-style: none; margin: 0; padding: 0; }
.h-grid > * { min-width: 0; display: flex; }
.h-grid__cell {
  flex: 1; display: flex; flex-direction: column; justify-content: space-between; gap: 28px; min-height: 200px; padding: 28px;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-card);
  text-decoration: none; transition: transform .25s var(--ease), box-shadow .25s var(--ease), border-color .25s var(--ease);
}
a.h-grid__cell:hover { transform: translateY(-3px); box-shadow: var(--shadow-hover); border-color: transparent; }
.h-grid__title { font-size: 21px; font-weight: 700; line-height: 1.25; letter-spacing: -.01em; }
.h-grid__text { margin-top: 10px; font-size: 15px; color: var(--text-muted); }
/* Стрелка — SVG-маской: у прежнего уголка из повёрнутой рамки острие выглядело срезанным */
.h-grid__arrow {
  flex: none; display: block; width: 24px; height: 14px; background: var(--accent-strong);
  -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 14' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M1 7h21M16 1l6 6-6 6'/%3E%3C/svg%3E") center / contain no-repeat;
          mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 14' fill='none' stroke='%23000' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M1 7h21M16 1l6 6-6 6'/%3E%3C/svg%3E") center / contain no-repeat;
  transition: transform .25s var(--ease);
}
a:hover > .h-grid__arrow, a:hover .h-grid__arrow { transform: translateX(5px); }
/* Выделенная ячейка — тёплая фирменная заливка. */
.h-grid__cell--ink { background: var(--grad-soft); border-color: transparent; }
.h-grid__cell--ink .h-grid__title { font-size: clamp(22px, 2vw, 28px); font-weight: 800; letter-spacing: -.02em; }
@media (max-width: 1100px) { .h-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .h-grid { grid-template-columns: 1fr; } .h-grid__cell { min-height: 0; padding: 22px; } }

/* Кейсы */
.cases { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.case {
  display: flex; flex-direction: column; text-decoration: none;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-card); overflow: hidden;
  transition: transform .25s var(--ease), box-shadow .25s var(--ease), border-color .25s var(--ease);
}
.case:hover { transform: translateY(-3px); border-color: transparent; box-shadow: var(--shadow-hover); }
.case__media { aspect-ratio: 16 / 10; background: var(--surface-2); overflow: hidden; }
.case__media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s var(--ease); }
.case:hover .case__media img { transform: scale(1.03); }
.case__title { order: 1; margin: 24px 28px 0; font-size: 20px; line-height: 1.3; }
.case__text { order: 1; margin: 10px 28px 0; font-size: 15px; line-height: 1.5; color: var(--text-muted); }
.case__tags { order: 2; display: flex; flex-wrap: wrap; gap: 6px; margin: auto 28px 0; padding: 24px 40px 28px 0; position: relative; }
.case__tags::after { content: "→"; position: absolute; right: 0; bottom: 28px; font-size: 20px; line-height: 1; color: var(--accent-strong); transition: transform .25s var(--ease); }
.case:hover .case__tags::after { transform: translateX(5px); }
.chip {
  display: inline-flex; align-items: center; padding: 6px 12px; border-radius: var(--radius-control);
  background: var(--surface-2); font-size: 13px; font-weight: 600; color: var(--text-muted); line-height: 1.2;
}
.cases__more { margin-top: 40px; }
/* Текстовые карточки (главная): название, теги и знак внизу. */
.cases--text .case { min-height: 280px; padding: 28px 0 0; }
.cases--text .case__num { order: 0; margin: 0 28px; font-size: 14px; font-weight: 600; color: var(--accent-strong); }
.cases--text .case__title { margin-top: 14px; font-size: 21px; }
.case--all { justify-content: space-between; padding: 28px; background: var(--grad-soft); border-color: transparent; min-height: 280px; }
.cases--text .case--all { padding: 28px; }
.case--all .h-grid__title { font-size: clamp(22px, 2vw, 28px); font-weight: 800; letter-spacing: -.02em; }
@media (max-width: 1100px) { .cases { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 640px) { .cases { grid-template-columns: 1fr; } }

/* Этапы работы: белые карточки с номером */
.steps { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 16px; list-style: none; margin: 0; padding: 0; counter-reset: step; }
.step { counter-increment: step; padding: 26px 24px 28px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-card); }
.step__marker { display: flex; align-items: center; gap: 10px; margin-bottom: 20px; }
.step__marker::after { content: counter(step, decimal-leading-zero); font-size: 28px; font-weight: 800; letter-spacing: -.03em; line-height: 1; color: var(--accent-strong); }
.step__title { font-size: 18px; }
.step__text { margin-top: 10px; font-size: 15px; color: var(--text-muted); }
@media (max-width: 1100px) { .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .steps { grid-template-columns: 1fr; } .step__marker { margin-bottom: 14px; } }

/* Чек-лист: маркер — точка в цвете акцента */
.checklist { list-style: none; margin: 28px 0 32px; padding: 0; display: grid; gap: 18px; }
.checklist li { position: relative; padding-left: 26px; }
.checklist li::before { content: ""; position: absolute; left: 2px; top: .5em; width: 9px; height: 9px; border-radius: 50%; background: var(--grad); }
.checklist strong { display: block; }
.checklist span { color: var(--text-muted); font-size: 16px; }

/* FAQ: вопросы в белой карточке */
.faq { max-width: 880px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-card); padding: 4px 28px; }
.faq__item + .faq__item { border-top: 1px solid var(--line); }
.faq__item summary {
  display: flex; justify-content: space-between; align-items: center; gap: 24px; padding: 22px 0;
  font-weight: 600; font-size: 18px; cursor: pointer; list-style: none;
}
.faq__item summary::-webkit-details-marker { display: none; }
.faq__item summary::after {
  content: "+"; flex: none; display: grid; place-items: center; width: 32px; height: 32px; border-radius: 50%;
  background: var(--accent-soft); color: var(--accent-strong); font-size: 20px; line-height: 1; transition: transform .2s var(--ease);
}
.faq__item[open] summary::after { transform: rotate(45deg); }
.faq__answer { padding: 0 0 24px; color: var(--text-muted); max-width: 70ch; }
.faq__answer p + p { margin-top: 12px; }
@media (max-width: 560px) { .faq { padding: 0 18px; } .faq__item summary { font-size: 17px; } }

/* Блок заявки (как в макете): тёплая градиентная панель, за формой — волна из линий (canvas, main.js),
   форма Битрикс24 — в белой карточке с градиентной рамкой */
.lead-form {
  position: relative; isolation: isolate; overflow: hidden;
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: 48px; align-items: center; padding: 64px 48px;
  border-radius: 36px;
  background:
    radial-gradient(60% 90% at 100% 0%, rgb(255 122 31 / .38), transparent 70%),
    radial-gradient(55% 80% at 0% 100%, rgb(255 122 168 / .42), transparent 70%),
    linear-gradient(135deg, #fff1e6, #ffe9f1);
}
.lead-form__wave { position: absolute; inset: 0; z-index: -1; width: 100%; height: 100%; pointer-events: none; }
.lead-form__intro .section__title { max-width: 14ch; }
.lead-form__text { max-width: 30rem; margin-top: 24px; font-size: 20px; line-height: 1.5; color: var(--text-muted); }
.lead-form__card {
  padding: 24px 28px; border-radius: var(--radius-panel); border: 2px solid transparent;
  background: linear-gradient(var(--surface), var(--surface)) padding-box, linear-gradient(90deg, #ff7a1f, #ff7aa8, #ff7a1f) border-box;
}
@media (max-width: 900px) {
  .lead-form { grid-template-columns: 1fr; gap: 28px; padding: 32px 16px 16px; border-radius: var(--radius-panel); }
  .lead-form__intro { padding: 0 8px; }
  .lead-form__text { font-size: 17px; margin-top: 16px; }
  .lead-form__card { padding: 16px; border-radius: var(--radius-card); }
}

/* Подвал */
/* Футер (по макету sofiyawalko.github.io/Itach-soft): белая карточка — логотип, колонки направлений из меню, контакты, копирайт */
.footer { padding: 24px 0 32px; font-size: 15px; }
.footer__card { padding: 48px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-panel); }
.footer__top { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px 40px; }
.footer__logo img { width: 66px; height: auto; }
.footer__about { max-width: 46ch; color: var(--text-muted); }
.footer__cols { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 40px 32px; margin-top: 48px; }
.footer__title { display: block; margin-bottom: 16px; font-size: 16px; font-weight: 700; line-height: 1.3; color: var(--text); text-decoration: none; }
a.footer__title:hover { color: var(--accent-strong); }
.footer__list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; line-height: 1.35; }
.footer__list a { color: var(--text-muted); text-decoration: none; transition: color .15s var(--ease); }
.footer__list a:hover { color: var(--text); }
.footer__contacts { margin-top: 48px; padding-top: 40px; border-top: 1px solid var(--line); }
.footer__contact-list { display: flex; flex-wrap: wrap; align-items: baseline; gap: 10px 40px; list-style: none; margin: 0; padding: 0; color: var(--text-muted); }
.footer__contact-list a { color: var(--text); text-decoration: none; }
.footer__contact-list a:hover { color: var(--accent-strong); }
.footer__phone { font-size: 20px; font-weight: 700; }
.footer__bottom { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; margin-top: 40px; padding-top: 24px; border-top: 1px solid var(--line); font-size: 14px; color: var(--text-muted); }
.footer__bottom a { color: inherit; }
@media (max-width: 1100px) { .footer__cols { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 767px) {
  .footer { padding: 16px 0 24px; }
  .footer__card { padding: 28px 20px; border-radius: var(--radius-card); }
  .footer__cols { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 28px 20px; margin-top: 32px; }
  .footer__contacts { margin-top: 32px; padding-top: 28px; }
  .footer__contact-list { flex-direction: column; }
}

/* Блог на главной (по макету): карточки — метка темы, дата, заголовок, оранжевая кнопка-стрелка; вся карточка кликабельна */
.home-blog__head { margin-bottom: 40px; }
.blog-cards { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; list-style: none; margin: 0; padding: 0; }
.blog-card {
  --mx: 50%; --my: 50%;
  position: relative; display: flex; flex-direction: column; min-height: 320px; padding: 24px;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-panel);
}
/* Градиентный контур у курсора (как .glow-card в макете): --mx/--my выставляет main.js, внутренность вырезана маской */
.blog-card::before {
  content: ""; position: absolute; inset: -1px; padding: 2px; border-radius: inherit; pointer-events: none;
  background: radial-gradient(circle var(--glow-radius, 147px) at var(--mx) var(--my), var(--brand-1) 35%, #f2456b 75%, transparent);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor;
          mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0);
  opacity: 0; transition: opacity .22s var(--ease);
}
.blog-card__meta { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.blog-card__tag {
  padding: 6px 14px; font-size: 13px; font-weight: 600; line-height: 1.2; border-radius: 999px; border: 1.5px solid transparent;
  background: linear-gradient(var(--surface), var(--surface)) padding-box, linear-gradient(90deg, var(--brand-1), #f2456b, var(--brand-1)) border-box;
  background-size: auto, 200% 100%;
}
.blog-card__date { font-size: 14px; color: var(--text-muted); }
.blog-card__title { margin-top: 24px; font-size: 20px; font-weight: 600; line-height: 1.25; letter-spacing: -.015em; text-wrap: pretty; }
.blog-card__link { color: inherit; text-decoration: none; }
.blog-card__link::after { content: ""; position: absolute; inset: 0; border-radius: inherit; }
.blog-card__go {
  position: relative; align-self: flex-end; margin-top: auto; width: 48px; height: 48px; border-radius: 14px;
  background: linear-gradient(90deg, #f0510f, #e0365a, #f0510f); background-size: 200% 100%;
  box-shadow: 0 8px 20px rgb(232 72 15 / .25);
}
.blog-card__go::before { content: ""; position: absolute; inset: 0; margin: auto; width: 10px; height: 10px; border: solid #fff; border-width: 2px 2px 0 0; transform: translateX(-2px) rotate(45deg); transition: transform .3s var(--ease); }
@media (hover: hover) {
  .blog-card:hover::before { opacity: 1; }
  .blog-card:hover .blog-card__go::before { transform: translateX(1px) rotate(45deg); }
}
/* При наведении метка и заголовок сдвигаются вправо, рамка метки и заливка стрелки текут градиентом */
@media (prefers-reduced-motion: no-preference) {
  .blog-card__tag, .blog-card__title { transition: transform .4s var(--ease); }
  @media (hover: hover) {
    .blog-card:hover :is(.blog-card__tag, .blog-card__title) { transform: translateX(12px); }
    .blog-card:hover .blog-card__tag { animation: border-flow 3s linear infinite; }
    .blog-card:hover .blog-card__go { animation: gradient-flow 3s linear infinite; }
  }
  /* Когда блок появляется на экране, контур один раз пробегает по карточкам слева направо (is-revealed ставит main.js) */
  .blog-cards.is-revealed > .blog-card::before { animation: border-sweep .7s linear calc(var(--i, 0) * 90ms); }
}
@property --mx { syntax: "<length-percentage>"; inherits: true; initial-value: 50%; }
@keyframes gradient-flow { to { background-position: 200% 0; } }
@keyframes border-flow { to { background-position: 0 0, 200% 0; } }
@keyframes border-sweep { 0% { --mx: -25%; opacity: 0; } 15%, 85% { opacity: 1; } 100% { --mx: 125%; opacity: 0; } }
.home-blog__action { display: flex; justify-content: center; margin-top: 40px; }
@media (max-width: 1100px) { .blog-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) { .blog-cards { grid-template-columns: 1fr; } .blog-card { min-height: 0; } .blog-card__go { margin-top: 24px; } }

/* Хлебные крошки и заголовок внутренних страниц */
.page-head { padding: 32px 0 8px; }
.page-head__title { font-size: clamp(32px, 3.8vw, 50px); text-wrap: balance; }
.breadcrumbs { display: flex; flex-wrap: wrap; gap: 6px; list-style: none; margin: 0 0 16px; padding: 0; font-size: 14px; color: var(--text-muted); }
.breadcrumbs a { color: inherit; text-decoration: none; }
.breadcrumbs a:hover { color: var(--accent-strong); }
.breadcrumbs li + li::before { content: "/"; margin-right: 6px; opacity: .6; }

/* Уникальный текст региона: заголовок и текст одной колонкой у левого края */
.region-text > * { max-width: 760px; }
.region-text .section__lead p + p { margin-top: 12px; }

/* ===== Главная ===== */

/* Первый экран: текст слева, на фоне — анимированная лента из линий (assets/js/hero-ribbon.js) и метки направлений */
/* Первый экран главной (по макету sofiyawalko.github.io/Itach-soft): крупный заголовок капсом, WebGL-ткань (hero-gl.js)
   и стеклянные карточки с цифрами внизу. Белая панель заезжает под шапку и скругляется снизу. */
.home-hero {
  --over: calc(var(--header-h) + 24px);
  position: relative; isolation: isolate; overflow: clip;
  display: flex; flex-direction: column; min-height: 100svh;
  margin-top: calc(-1 * var(--over)); padding: calc(var(--over) + 48px) 0 40px;
  background: var(--surface); border-radius: 0 0 var(--radius-panel) var(--radius-panel);
}
.home-hero__gl { position: absolute; z-index: -1; inset: 0; width: 100%; height: 100%; pointer-events: none; filter: blur(.6px); }
.home-hero__inner { flex: 1; display: flex; flex-direction: column; gap: 48px; }
.home-hero__copy { margin-block: auto; }
.home-hero__title { font-size: clamp(34px, 1rem + 4.6vw, 84px); font-weight: 800; line-height: 1.02; letter-spacing: -.03em; text-wrap: balance; }
.home-hero__line { display: block; text-transform: uppercase; }
.home-hero__title em { font-style: normal; background: linear-gradient(90deg, var(--brand-1) 40%, #f2456b); -webkit-background-clip: text; background-clip: text; color: transparent; }
.home-hero__kicker {
  display: table; margin-bottom: 24px; padding: 8px 16px;
  font-size: 15px; font-weight: 600; letter-spacing: 0; line-height: 1.3; color: var(--text);
  background: rgb(255 255 255 / .7); border: 1px solid var(--line); border-radius: 999px;
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
}
.home-hero__lead { margin-top: 24px; max-width: 41rem; font-size: 20px; line-height: 1.55; color: var(--text-muted); text-wrap: pretty; }
.home-hero__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 36px; }
.home-hero__stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; list-style: none; margin: 0; padding: 0; }
.home-stat {
  display: grid; align-content: start; gap: 6px; padding: 24px 32px;
  background: rgb(255 255 255 / .7); border: 1px solid rgb(23 25 34 / .08); border-radius: var(--radius-panel);
  box-shadow: 0 12px 40px rgb(23 25 34 / .1);
  -webkit-backdrop-filter: blur(20px) saturate(140%); backdrop-filter: blur(20px) saturate(140%);
}
.home-stat__value { font-size: clamp(30px, 1rem + 1.8vw, 42px); font-weight: 700; line-height: 1.1; letter-spacing: -.025em; white-space: nowrap; }
.home-stat__label { font-size: 16px; font-weight: 700; line-height: 1.3; }
.home-stat__note { font-size: 14px; line-height: 1.4; color: var(--text-muted); }
@media (prefers-reduced-motion: no-preference) {
  .home-hero__copy > *, .home-hero__title > * { animation: rise .8s var(--ease) both; }
  .home-hero__title > :nth-child(2) { animation-delay: .06s; }
  .home-hero__title > :nth-child(3) { animation-delay: .12s; }
  .home-hero__lead { animation-delay: .2s; }
  .home-hero__actions { animation-delay: .28s; }
  .home-hero__gl { animation: fade-in 1.6s ease both .1s; }
  .home-stat { animation: rise .9s var(--ease) both; animation-delay: calc(.4s + var(--i) * .08s); }
}
@keyframes rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
@keyframes fade-in { from { opacity: 0; } to { opacity: 1; } }
@media (max-width: 1023px) { .home-hero__stats { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 767px) {
  .home-hero { --over: calc(var(--header-h) + 16px); min-height: 0; padding: calc(var(--over) + 32px) 0 24px; }
  .home-hero__gl { opacity: .4; }
  .home-hero__lead { font-size: 18px; }
  .home-hero__actions .btn { flex: 1 1 100%; }
  .home-hero__stats { gap: 12px; }
  .home-stat { padding: 18px; border-radius: var(--radius-card); }
  .home-stat__note { display: none; }
}

/* Заявление о компании: крупный текст, ключевые направления выделены цветом текста */
.home-statement-wrap { padding: 72px 0 8px; }
.home-statement {
  max-width: 30ch; font-size: clamp(26px, 3.2vw, 44px); font-weight: 700; line-height: 1.18; letter-spacing: -.025em;
  color: #9a9eae; text-wrap: pretty;
}
.home-statement b { color: var(--text); font-weight: 800; }
@media (max-width: 767px) { .home-statement-wrap { padding: 48px 0 0; } }

/* Лента статусов и цифр: белая панель с разделителями (сейчас — «Почему у нас» на страницах услуг, .svc-why) */
.home-proof__list {
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)) auto; align-items: center;
  list-style: none; margin: 0; padding: 8px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-panel);
}
.home-proof__item { padding: 18px 24px; }
.home-proof__item + .home-proof__item { border-left: 1px solid var(--line); }
.home-proof__value { display: block; white-space: nowrap; font-size: clamp(19px, 1.75vw, 25px); font-weight: 800; letter-spacing: -.025em; line-height: 1.1; }
.home-proof__label { display: block; margin-top: 4px; font-size: 15px; color: var(--text-muted); }
.home-proof__item--link { padding-right: 16px; }
@media (max-width: 1100px) {
  .home-proof__list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .home-proof__item { border-left: 0 !important; border-top: 1px solid var(--line); }
  .home-proof__item:nth-child(-n+2) { border-top: 0; }
  .home-proof__item:nth-child(even) { border-left: 1px solid var(--line) !important; }
  .home-proof__item--link { grid-column: 1 / -1; border-left: 0 !important; }
}
@media (max-width: 480px) { .home-proof__item { padding: 16px; } }

/* Направления: указатель услуг — три группы в одной панели, услуги строками с номером, тегами и стрелкой */
.home-svc { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-panel); padding: 8px 40px; }
.home-svc__group { display: grid; grid-template-columns: 260px minmax(0, 1fr); gap: 40px; padding: 32px 0; }
.home-svc__group + .home-svc__group { border-top: 1px solid var(--line); }
.home-svc__head { position: sticky; top: calc(var(--header-h) + 40px); align-self: start; padding-top: 18px; }
.home-svc__group-title { font-size: 28px; font-weight: 800; letter-spacing: -.03em; line-height: 1.1; }
.home-svc__status { display: flex; align-items: center; gap: 8px; margin-top: 12px; font-size: 14px; font-weight: 600; color: var(--text-muted); }
.home-svc__status::before { content: ""; flex: none; width: 8px; height: 8px; border-radius: 50%; background: var(--grad); }
.home-svc__list { list-style: none; margin: 0; padding: 0; }
.home-svc__list > li + li { border-top: 1px solid var(--line); }
.home-svc__row {
  display: grid; grid-template-columns: 44px minmax(0, 1fr) auto 48px; align-items: center; gap: 24px;
  padding: 22px 16px; margin: 0 -16px; border-radius: var(--radius-card); color: var(--text); text-decoration: none;
  transition: background-color .25s var(--ease);
}
.home-svc__num { font-size: 14px; font-weight: 700; color: var(--text-muted); font-variant-numeric: tabular-nums; }
.home-svc__main { display: grid; gap: 6px; }
.home-svc__name { font-size: 22px; font-weight: 700; line-height: 1.2; letter-spacing: -.015em; transition: color .25s var(--ease); }
.home-svc__text { font-size: 15px; line-height: 1.45; color: var(--text-muted); }
.home-svc__tags { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 6px; max-width: 380px; }
.home-svc__tags span { padding: 5px 11px; border: 1px solid var(--line); border-radius: var(--radius-control); font-size: 13px; font-weight: 600; line-height: 1.2; color: var(--text-muted); white-space: nowrap; }
.home-svc__go { position: relative; width: 48px; height: 48px; border-radius: 50%; border: 1px solid var(--line); transition: background .25s var(--ease), border-color .25s var(--ease), transform .25s var(--ease); }
.home-svc__go::before, .home-svc__go::after { content: ""; position: absolute; left: 50%; top: 50%; }
.home-svc__go::before { width: 16px; height: 2px; margin: -1px 0 0 -9px; border-radius: 2px; background: var(--text); }
.home-svc__go::after { width: 8px; height: 8px; margin: -5px 0 0 -3px; border: solid var(--text); border-width: 2px 2px 0 0; transform: rotate(45deg); }
.home-svc__row:hover { background: var(--bg); }
.home-svc__row:hover .home-svc__name { color: var(--accent-strong); }
.home-svc__row:hover .home-svc__num { color: var(--accent-strong); }
.home-svc__row:hover .home-svc__go { background: var(--grad); border-color: transparent; transform: rotate(-45deg); }
.home-svc__row:hover .home-svc__go::before { background: #fff; }
.home-svc__row:hover .home-svc__go::after { border-color: #fff; }
@media (max-width: 1100px) {
  .home-svc__group { grid-template-columns: 1fr; gap: 12px; }
  .home-svc__head { position: static; padding-top: 0; }
  .home-svc__row { grid-template-columns: 36px minmax(0, 1fr) 44px; }
  .home-svc__tags { grid-column: 2; grid-row: 2; justify-content: flex-start; max-width: none; }
  .home-svc__go { grid-column: 3; grid-row: 1 / span 2; width: 44px; height: 44px; }
}
@media (max-width: 600px) {
  .home-svc { padding: 4px 20px; }
  .home-svc__group { padding: 24px 0; }
  .home-svc__group-title { font-size: 24px; }
  .home-svc__row { grid-template-columns: minmax(0, 1fr) 40px; gap: 14px; padding: 18px 12px; margin: 0 -12px; }
  .home-svc__num { display: none; }
  .home-svc__main { grid-column: 1; }
  .home-svc__tags { grid-column: 1; }
  .home-svc__go { grid-column: 2; width: 40px; height: 40px; }
  .home-svc__name { font-size: 19px; }
}


/* Кейсы — плитки с кадром сайта (главная и /portfolio/). У длинных скриншотов кадр едет вниз при наведении. */
.pf-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 48px 28px; }
.pf-grid > [hidden] { display: none; }
.pf-card { display: flex; flex-direction: column; gap: 6px; min-width: 0; text-decoration: none; }
.pf-card__tile {
  position: relative; display: block; aspect-ratio: 1; margin-bottom: 12px; overflow: hidden;
  border-radius: var(--radius-media); background: var(--surface-2); box-shadow: var(--shadow);
  transition: transform .35s var(--ease), box-shadow .35s var(--ease);
}
.pf-card__tile img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 0; }
.pf-card:hover .pf-card__tile { transform: translateY(-4px); box-shadow: var(--shadow-hover); }
.pf-card__tile--logo { background: var(--surface); }
.pf-card__tile--logo img { object-fit: contain; object-position: center; padding: 14%; }
.pf-card__placeholder { display: grid; place-items: center; height: 100%; padding: 24px; text-align: center; font-size: 22px; font-weight: 800; color: var(--accent-strong); background: var(--grad-soft); }
@media (prefers-reduced-motion: no-preference) {
  .pf-card__tile--scroll img { transition: object-position 5s cubic-bezier(.45, 0, .55, 1); }
  .pf-card:hover .pf-card__tile--scroll img, .pf-card:focus-visible .pf-card__tile--scroll img { object-position: 50% 100%; }
}
.pf-card__client { font-size: 24px; font-weight: 800; letter-spacing: -.02em; line-height: 1.2; }
.pf-card:hover .pf-card__client { color: var(--accent-strong); }
.pf-card__task { font-size: 15px; line-height: 1.4; color: var(--text-muted); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.pf-card__tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 4px; }
.pf-card__tags span { padding: 4px 10px; border-radius: var(--radius-control); background: var(--surface); border: 1px solid var(--line); font-size: 12px; font-weight: 600; color: var(--text-muted); }
@media (max-width: 899px) { .pf-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 32px 16px; } .pf-card__client { font-size: 18px; } }
@media (max-width: 479px) { .pf-grid { grid-template-columns: 1fr; } }

/* Отрасли: облако ссылок-капсул */
.home-pills { display: flex; flex-wrap: wrap; gap: 10px; list-style: none; margin: 0; padding: 0; }
.home-pills > li { display: flex; }
.home-pills .h-grid__cell {
  min-height: 0; flex-direction: row; align-items: center; gap: 14px; padding: 16px 22px 16px 24px;
  border-radius: var(--radius-control);
}
.home-pills .h-grid__title { font-size: 18px; font-weight: 600; }
.home-pills .h-grid__cell--ink .h-grid__title { font-size: 18px; font-weight: 700; letter-spacing: -.01em; }

/* «Как мы работаем» (по макету): крупные номера слева, линия прорисовывается при прокрутке (--progress из main.js),
   шаги серые, пока линия до них не дошла (.is-active); справа — карточка «Вы получаете». */
.section__title-muted { color: #9a9eae; }
.process { --line-x: 8px; position: relative; list-style: none; margin: 56px 0 0; padding: 0 0 0 32px; }
.process::before, .process::after { content: ""; position: absolute; top: 0; left: var(--line-x); width: 2px; border-radius: 2px; translate: -50% 0; }
.process::before { height: 100%; background: var(--line); }
.process::after { height: calc(var(--progress, 1) * 100%); background: linear-gradient(180deg, var(--brand-1), #f2456b); }
.process__step { position: relative; display: grid; gap: 16px; padding: 32px 0; transition: color .5s var(--ease); }
.process__step::before {
  content: ""; position: absolute; z-index: 1; top: 34px; left: calc(var(--line-x) - 32px); width: 14px; height: 14px; translate: -50% 0;
  border: 2px solid var(--brand-1); border-radius: 50%; background: var(--brand-1); transition: border-color .5s var(--ease), background-color .5s var(--ease);
}
.process__num {
  width: fit-content; font-size: clamp(48px, 2rem + 4vw, 96px); font-weight: 700; line-height: 1; letter-spacing: -.04em;
  background: linear-gradient(90deg, var(--brand-1) 55%, #f2456b); -webkit-background-clip: text; background-clip: text; color: transparent;
  transition: filter .5s var(--ease), opacity .5s var(--ease);
}
.process__title { font-size: clamp(24px, 1.1rem + 1.4vw, 40px); font-weight: 700; line-height: 1.1; letter-spacing: -.025em; text-wrap: balance; }
.process__text { max-width: 42rem; margin-top: 16px; font-size: 17px; line-height: 1.6; color: var(--text-muted); text-wrap: pretty; transition: color .5s var(--ease); }
/* Текст этапа из CMS (svc-prose со списками) — тем же приглушённым цветом и с тем же посерением */
.process .process__text.svc-prose { max-width: 42rem; color: var(--text-muted); }
.process .process__text :is(p, li) { color: inherit; }
.process__result { display: grid; gap: 8px; padding: 24px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius-card); }
.process__result-label {
  width: fit-content; font-size: 13px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase;
  background: linear-gradient(90deg, var(--brand-1) 50%, #f2456b); -webkit-background-clip: text; background-clip: text; color: transparent;
  transition: filter .5s var(--ease), opacity .5s var(--ease);
}
.process__result-text { font-size: 16px; font-weight: 600; line-height: 1.4; }
/* Серое состояние — только когда скрипт ведёт прокрутку (is-live); без JS шаги сразу «включены» */
.process.is-live .process__step:not(.is-active), .process.is-live .process__step:not(.is-active) .process__text { color: #b4b7c0; }
.process.is-live .process__step:not(.is-active)::before { border-color: #c9cbd3; background: var(--bg); }
.process.is-live .process__step:not(.is-active) :is(.process__num, .process__result-label) { filter: grayscale(1); opacity: .35; }
.home-process__action { display: flex; justify-content: center; margin-top: 40px; }
@media (min-width: 768px) {
  .process { --line-x: 208px; padding-left: 0; }
  .process__step { grid-template-columns: 176px 1fr; column-gap: 64px; align-items: start; padding: 48px 0; }
  .process__step::before { top: 54px; left: var(--line-x); }
  .process__result { grid-column: 2; max-width: 24rem; }
}
@media (min-width: 1100px) {
  .process__step { grid-template-columns: 176px 1fr 272px; }
  .process__result { grid-column: 3; grid-row: 1; }
}

/* Вопросы на главной: заголовок и контакт слева, ответы справа */
.home-faq { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.6fr); gap: 56px; align-items: start; }
.home-faq__aside { position: sticky; top: calc(var(--header-h) + 48px); }
.home-faq__aside .section__lead { margin-bottom: 24px; }
.home-faq__aside .section__title + .btn { margin-top: 28px; }
.home-faq .faq { max-width: none; }
@media (max-width: 900px) { .home-faq { grid-template-columns: 1fr; gap: 24px; } .home-faq__aside { position: static; } }

/* Появление при прокрутке */
@media (prefers-reduced-motion: no-preference) {
  .reveal { opacity: 0; transform: translateY(20px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
  .reveal.is-visible { opacity: 1; transform: none; }
}

/* Стеклянный кружок, который плавно тянется за курсором (как в макете). Системная стрелка остаётся видна.
   main.js показывает его только для мыши и без reduced motion; это popover — живёт в верхнем слое, над всплывающей формой Битрикс24 */
.cursor-halo {
  position: fixed; inset: 0 auto auto 0; z-index: 100; width: 28px; height: 28px; margin: 0; padding: 0; overflow: visible;
  border: 1px solid rgb(23 25 34 / .08); border-radius: 50%; background: rgb(255 255 255 / .25);
  -webkit-backdrop-filter: blur(6px) saturate(1.4); backdrop-filter: blur(6px) saturate(1.4);
  box-shadow: 0 8px 32px rgb(23 25 34 / .08); opacity: 0; pointer-events: none; transition: opacity .22s var(--ease);
}
.cursor-halo.is-visible { opacity: 1; }
.cursor-halo.is-visible.is-hidden { opacity: 0; } /* над полями ввода прячется, чтобы не мешать тексту */

/* Окно кейса (main.js, ссылки data-case-open): белая панель поверх затемнения, прокручивается само окно */
html.is-modal-open { overflow: hidden; }
.case-modal { width: 100%; max-width: none; height: 100%; max-height: none; margin: 0; padding: 64px 24px; border: 0; background: transparent; overflow-y: auto; overscroll-behavior: contain; }
.case-modal::backdrop { background: rgb(23 25 34 / .45); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); }
.case-modal__panel { position: relative; max-width: 1216px; margin: 0 auto; padding: 56px 40px 48px; background: var(--surface); border-radius: 40px; box-shadow: 0 30px 80px rgb(23 25 34 / .25); }
.case-modal__close { position: absolute; top: 28px; right: 28px; width: 44px; height: 44px; border: 0; border-radius: 50%; background: none; cursor: pointer; }
.case-modal__close::before, .case-modal__close::after { content: ""; position: absolute; inset: 0; margin: auto; width: 22px; height: 2px; border-radius: 2px; background: var(--text); transform: rotate(45deg); }
.case-modal__close::after { transform: rotate(-45deg); }
.case-modal__close:hover { background: var(--bg); }
.case-modal__eyebrow { width: fit-content; font-size: 15px; font-weight: 600; background: linear-gradient(90deg, #ff7a1f, #ff7aa8); -webkit-background-clip: text; background-clip: text; color: transparent; }
.case-modal__title { max-width: 22ch; margin-top: 12px; font-size: clamp(28px, 1rem + 2.4vw, 48px); font-weight: 600; line-height: 1.1; letter-spacing: -.03em; }
.case-modal__lead { max-width: 64ch; margin-top: 20px; font-size: 17px; color: var(--text-muted); }
.case-modal__actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.case-modal__shot { margin-top: 36px; overflow: hidden; border: 1px solid var(--line); border-radius: 24px; }
.case-modal__shot img { width: 100%; height: auto; }
.case-modal__part { margin-top: 48px; }
.case-modal__part .section__title { font-size: clamp(24px, 1rem + 1.4vw, 34px); }
.case-modal__loading { display: flex; justify-content: center; gap: 8px; padding: 120px 0; }
.case-modal__loading span { width: 10px; height: 10px; border-radius: 50%; background: var(--brand-1); animation: case-dot 1s ease-in-out infinite; }
.case-modal__loading span:nth-child(2) { animation-delay: .15s; }
.case-modal__loading span:nth-child(3) { animation-delay: .3s; }
@keyframes case-dot { 0%, 100% { opacity: .25; transform: translateY(0); } 50% { opacity: 1; transform: translateY(-6px); } }
@media (prefers-reduced-motion: no-preference) {
  .case-modal[open] .case-modal__panel { animation: rise .45s var(--ease) both; }
}
@media (max-width: 767px) {
  .case-modal { padding: 12px 8px; }
  .case-modal__panel { padding: 56px 20px 32px; border-radius: 24px; }
  .case-modal__close { top: 10px; right: 10px; }
  .case-modal__actions .btn { flex: 1 1 100%; white-space: normal; text-align: center; }
}

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

/* Блок «Коротко» в начале статьи блога */
.article-summary {
  margin: 0 0 32px; padding: 22px 26px;
  background: var(--grad-soft); border-radius: var(--radius-card);
}
.article-summary > :first-child { margin-top: 0; }
.article-summary p + p, .article-summary ul { margin-top: 8px; }
