/* =========================================================
   Салютем — юридическая компания, Казань
   V3. Визуальная концепция: «Архитектурный чертёж».
   Палитра взята из фирменного логотипа: глубокий сине-зелёный
   (надпись), бирюза (пирамида), оливково-зелёный (лист), графит.
   Только системные шрифты, без внешних запросов.
   ========================================================= */

/* ---------------------------------------------------------
   1. Токены
   --------------------------------------------------------- */
:root {
  /* Фирменные цвета */
  --teal-900: #072E37;   /* самый глубокий — фон акцентной секции */
  --teal-800: #0B3A44;
  --teal-700: #0E4A56;   /* надпись логотипа, основной акцент */
  --teal-500: #2E7488;   /* середина пирамиды */
  --teal-100: #E3EDEE;   /* светлая заливка */
  --olive-600: #6E7F22;
  --olive-500: #8B9E2C;  /* лист логотипа */
  --olive-200: #DFE6C4;

  /* Нейтральные */
  --ink: #0A2C33;
  --ink-2: #47575C;
  --ink-3: #7A888C;
  --paper: #F2F3EF;
  --paper-2: #E9EBE4;
  --surface: #FFFFFF;
  --rule: #DBDFD6;
  --rule-2: #C6CCC0;

  /* На тёмном */
  --on-dark: #EAF0EF;
  --on-dark-2: #A9BCBE;
  --on-dark-rule: rgba(255, 255, 255, 0.14);

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

  /* Раскладка */
  --shell: 1220px;
  --gutter: 20px;
  --radius: 4px;
  --radius-lg: 8px;

  /* Движение */
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
  --dur: 0.45s;
}

@media (min-width: 768px) { :root { --gutter: 32px; } }
@media (min-width: 1200px) { :root { --gutter: 40px; } }

/* ---------------------------------------------------------
   2. База
   --------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

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

@media (min-width: 768px) { body { font-size: 1.0625rem; } }

img, svg, iframe { display: block; max-width: 100%; }
img { height: auto; }

h1, h2, h3 {
  font-family: var(--serif);
  color: var(--ink);
  font-weight: 700;
  margin: 0 0 0.5em;
}

h1 {
  font-size: clamp(2.5rem, 1.5rem + 3.6vw, 4.5rem);
  line-height: 1.03;
  letter-spacing: -0.022em;
}
h2 {
  font-size: clamp(1.8rem, 1.35rem + 1.7vw, 2.65rem);
  line-height: 1.13;
  letter-spacing: -0.014em;
}
h3 {
  font-size: 1.15rem;
  line-height: 1.32;
  letter-spacing: -0.005em;
}

p { margin: 0 0 1em; max-width: 66ch; }
p:last-child { margin-bottom: 0; }

a { color: var(--teal-700); text-underline-offset: 0.18em; }
a:hover { color: var(--olive-600); }

ul, ol { margin: 0; padding: 0; }

:focus-visible {
  outline: 2px solid var(--olive-600);
  outline-offset: 3px;
  border-radius: 2px;
}

.svg-sprite { position: absolute; width: 0; height: 0; overflow: hidden; }

.skip-link {
  position: absolute; left: 16px; top: -80px; z-index: 200;
  background: var(--teal-700); color: #fff;
  padding: 12px 20px; border-radius: var(--radius);
  text-decoration: none; font-weight: 600;
  transition: top 0.18s var(--ease);
}
.skip-link:focus { top: 16px; color: #fff; }

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

/* ---------------------------------------------------------
   3. Секции и ритм
   --------------------------------------------------------- */
.section { padding-block: 68px; position: relative; }
@media (min-width: 768px) { .section { padding-block: 92px; } }
@media (min-width: 1200px) { .section { padding-block: 112px; } }

.section--services { background: var(--surface); border-block: 1px solid var(--rule); }
.section--reasons { background: var(--paper); }
.section--steps { background: var(--surface); border-block: 1px solid var(--rule); }
.section--about { background: var(--paper); }
.section--consult { background: var(--paper-2); border-block: 1px solid var(--rule); }
.section--contacts { background: var(--surface); }

/* Заголовок секции: узкая колонка слева, подводка справа */
.section-head {
  margin-bottom: 40px;
  padding-top: 26px;
  border-top: 1px solid var(--rule-2);
}
.section-head__title { margin-bottom: 0.35em; }
.section-head__lede { color: var(--ink-2); max-width: 58ch; margin: 0; }

@media (min-width: 900px) {
  .section-head {
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.95fr);
    gap: 56px;
    align-items: start;
    margin-bottom: 56px;
  }
  .section-head__title { margin-bottom: 0; }
}

/* Двухколоночная «редакционная» раскладка: тема слева, содержание справа */
.editorial { display: grid; gap: 36px; }
.editorial__aside h2 { margin-bottom: 0; }

@media (min-width: 1000px) {
  .editorial {
    grid-template-columns: minmax(220px, 300px) minmax(0, 1fr);
    gap: 72px;
  }
  .editorial__aside { position: sticky; top: 120px; align-self: start; }
}

/* ---------------------------------------------------------
   4. Кнопки и ссылки-действия
   --------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 15px 28px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  font-family: var(--sans);
  font-size: 0.98rem;
  font-weight: 600;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.22s var(--ease), color 0.22s var(--ease),
              border-color 0.22s var(--ease), box-shadow 0.22s var(--ease),
              transform 0.22s var(--ease);
}

.btn--sm { padding: 11px 20px; font-size: 0.92rem; }
.btn--block { display: flex; width: 100%; }

.btn--primary {
  background: var(--teal-700);
  color: #fff;
  box-shadow: 0 1px 0 rgba(7, 46, 55, 0.28);
}
.btn--primary:hover {
  background: var(--teal-800);
  color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(7, 46, 55, 0.2);
}
.btn--primary:active { transform: translateY(0); }
.btn--primary:disabled { opacity: 0.6; cursor: default; transform: none; }

.btn--ghost {
  background: transparent;
  border-color: var(--rule-2);
  color: var(--ink);
}
.btn--ghost:hover {
  border-color: var(--teal-700);
  color: var(--teal-700);
  background: rgba(14, 74, 86, 0.04);
}

.btn__arrow { width: 18px; height: 18px; flex: none; }
.btn__arrow use,
.btn__arrow { transition: transform 0.25s var(--ease); }
.btn:hover .btn__arrow { transform: translateX(4px); }

svg[class*="arrow"],
.btn__arrow,
.link-arrow svg,
.service-card__cue svg,
.lightbox__nav svg {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  color: var(--teal-700);
}
.link-arrow svg { width: 17px; height: 17px; transition: transform 0.25s var(--ease); }
.link-arrow:hover { color: var(--olive-600); }
.link-arrow:hover svg { transform: translateX(4px); }

/* ---------------------------------------------------------
   5. Шапка
   --------------------------------------------------------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 60;
  background: rgba(242, 243, 239, 0.86);
  -webkit-backdrop-filter: saturate(160%) blur(12px);
  backdrop-filter: saturate(160%) blur(12px);
  border-bottom: 1px solid transparent;
  transition: background-color 0.3s var(--ease), border-color 0.3s var(--ease),
              box-shadow 0.3s var(--ease);
}
.site-header.is-stuck {
  background: rgba(255, 255, 255, 0.92);
  border-bottom-color: var(--rule);
  box-shadow: 0 6px 24px rgba(10, 44, 51, 0.06);
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding-block: 16px;
  transition: padding 0.3s var(--ease);
}
.site-header.is-stuck .site-header__inner { padding-block: 10px; }

.logo { display: block; flex: none; line-height: 0; }
.logo img {
  width: 150px;
  height: auto;
  transition: width 0.3s var(--ease);
}
.site-header.is-stuck .logo img { width: 126px; }

@media (min-width: 768px) {
  .logo img { width: 178px; }
  .site-header.is-stuck .logo img { width: 148px; }
}

.main-nav { display: none; }
.main-nav__list { display: flex; align-items: center; gap: 30px; list-style: none; }
.main-nav__list > li { position: relative; }
.main-nav__list > li > a {
  position: relative;
  display: block;
  padding-block: 8px;
  color: var(--ink-2);
  font-size: 0.96rem;
  font-weight: 500;
  text-decoration: none;
  transition: color 0.2s var(--ease);
}
.main-nav__list > li > a::after {
  content: "";
  position: absolute;
  left: 0; bottom: 2px;
  width: 100%; height: 2px;
  background: var(--olive-500);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.28s var(--ease);
}
.main-nav__list > li > a:hover { color: var(--ink); }
.main-nav__list > li:hover > a::after,
.main-nav__list > li:focus-within > a::after { transform: scaleX(1); }

.dropdown {
  position: absolute;
  top: calc(100% + 10px);
  left: -18px;
  min-width: 302px;
  padding: 8px;
  background: var(--surface);
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  box-shadow: 0 16px 40px rgba(10, 44, 51, 0.12);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-6px);
  transition: opacity 0.22s var(--ease), transform 0.22s var(--ease), visibility 0.22s;
}
.has-dropdown:hover .dropdown,
.has-dropdown:focus-within .dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.dropdown a {
  display: block;
  padding: 10px 14px;
  border-radius: 3px;
  font-size: 0.93rem;
  color: var(--ink-2);
  text-decoration: none;
  transition: background-color 0.16s var(--ease), color 0.16s var(--ease);
}
.dropdown a:hover { background: var(--teal-100); color: var(--teal-700); }

.header-actions { display: flex; align-items: center; gap: 16px; }
.header-phone {
  display: none;
  color: var(--ink);
  font-weight: 600;
  font-size: 0.96rem;
  text-decoration: none;
  white-space: nowrap;
}
.header-phone:hover { color: var(--teal-700); }
.header-cta { display: none; }

.nav-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px; height: 44px;
  padding: 0;
  background: var(--surface);
  border: 1px solid var(--rule-2);
  border-radius: var(--radius);
  color: var(--ink);
  font-size: 1rem;
  cursor: pointer;
  transition: border-color 0.2s var(--ease), background-color 0.2s var(--ease);
}
.nav-toggle:hover { border-color: var(--teal-700); }

.nav-toggle__bars { position: relative; display: block; width: 19px; height: 2px; background: var(--ink); }
.nav-toggle__bars::before,
.nav-toggle__bars::after {
  content: ""; position: absolute; left: 0;
  width: 19px; height: 2px; background: var(--ink);
}
.nav-toggle__bars::before { top: -6px; }
.nav-toggle__bars::after { top: 6px; }
.nav-toggle--close .nav-toggle__bars { display: none; }

/* Кнопка звонка — на узких экранах телефон остаётся в один тап */
.header-call {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px; height: 44px;
  background: var(--teal-700);
  border-radius: var(--radius);
  color: #fff;
  transition: background-color 0.2s var(--ease);
}
.header-call:hover { background: var(--teal-800); color: #fff; }
.header-call svg {
  width: 20px; height: 20px;
  fill: none; stroke: currentColor;
  stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round;
}

@media (min-width: 620px) {
  .header-phone { display: block; }
  .header-call { display: none; }
}
@media (min-width: 1040px) {
  .main-nav { display: block; }
  .header-cta { display: inline-flex; }
  .nav-toggle { display: none; }
}

/* ---------------------------------------------------------
   6. Мобильное меню
   --------------------------------------------------------- */
.mobile-menu {
  position: fixed;
  inset: 0;
  z-index: 90;
  display: none;
  flex-direction: column;
  padding: 18px var(--gutter) 28px;
  background: var(--paper);
  overflow-y: auto;
  overscroll-behavior: contain;
}
.mobile-menu.is-open { display: flex; }
body.menu-open { overflow: hidden; }

.mobile-menu__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--rule);
  margin-bottom: 20px;
}
.logo--mobile img { width: 140px; }

.mobile-menu__list { list-style: none; }
.mobile-menu__list a {
  display: block;
  padding: 13px 2px;
  border-bottom: 1px solid var(--rule);
  font-family: var(--serif);
  font-size: 1.08rem;
  color: var(--ink);
  text-decoration: none;
}
.mobile-menu__list a:hover { color: var(--teal-700); }

.mobile-menu__contacts {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 28px;
  padding-top: 22px;
  border-top: 1px solid var(--rule);
}
.mobile-menu__phone {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--ink);
  text-decoration: none;
}

/* ---------------------------------------------------------
   7. Hero
   --------------------------------------------------------- */
.hero { position: relative; background: var(--paper); overflow: hidden; }

.hero__media { position: relative; overflow: hidden; }
.hero__media img {
  width: 100%;
  height: 210px;
  object-fit: cover;
  object-position: 50% 62%;
  filter: saturate(0.92) contrast(1.05);
}
.hero__scrim {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(to bottom, rgba(7, 46, 55, 0.42) 0%, rgba(7, 46, 55, 0.1) 45%, var(--paper) 100%),
    linear-gradient(115deg, rgba(14, 74, 86, 0.45), rgba(46, 116, 136, 0.12) 60%, transparent);
}

.hero__inner { position: relative; z-index: 2; padding-block: 40px 60px; }
.hero__title { margin-bottom: 0.42em; }
.hero__title span { display: block; color: var(--teal-700); }
.hero__lede {
  font-size: 1.05rem;
  color: var(--ink-2);
  max-width: 54ch;
  margin-bottom: 32px;
}
.hero__actions { display: flex; flex-wrap: wrap; gap: 14px; }

.hero__card {
  margin-top: 40px;
  padding: 28px 26px;
  background: var(--surface);
  border: 1px solid var(--rule);
  border-top: 3px solid var(--teal-700);
  border-radius: var(--radius);
  box-shadow: 0 18px 44px rgba(10, 44, 51, 0.09);
}
.hero__card-title {
  font-size: 1.05rem;
  letter-spacing: 0;
  margin-bottom: 16px;
}
.hero__card-contacts { list-style: none; display: grid; gap: 7px; margin-bottom: 22px; }
.hero__card-contacts a {
  font-size: 1.06rem;
  font-weight: 600;
  color: var(--ink);
  text-decoration: none;
}
.hero__card-contacts a:hover { color: var(--teal-700); }

.hero__card-meta {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 6px 18px;
  margin: 0 0 22px;
  padding-top: 20px;
  border-top: 1px solid var(--rule);
  font-size: 0.9rem;
}
.hero__card-meta dt { color: var(--ink-3); }
.hero__card-meta dd { margin: 0; color: var(--ink-2); }

@media (min-width: 700px) {
  .hero__media img { height: 280px; }
}

@media (min-width: 1100px) {
  .hero__media {
    position: absolute;
    top: 0; right: 0; bottom: 0;
    width: 62%;
    z-index: 1;
  }
  .hero__media img {
    width: 100%;
    height: 100%;
    object-position: 55% 55%;
  }
  .hero__scrim {
    background:
      linear-gradient(to right, var(--paper) 0%, rgba(242, 243, 239, 0.8) 15%, rgba(242, 243, 239, 0.14) 38%, rgba(242, 243, 239, 0) 54%),
      linear-gradient(202deg, rgba(7, 46, 55, 0.3), rgba(46, 116, 136, 0.06) 52%, transparent);
  }
  .hero__inner {
    display: grid;
    grid-template-columns: minmax(0, 1.02fr) minmax(320px, 0.78fr);
    gap: 56px;
    align-items: center;
    min-height: 640px;
    padding-block: 76px 88px;
  }
  .hero__card { margin-top: 0; padding: 32px 30px; }
}

@media (min-width: 1320px) {
  .hero__inner { min-height: 700px; }
}

/* ---------------------------------------------------------
   8. Карточки услуг
   --------------------------------------------------------- */
.services-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}
@media (min-width: 620px) { .services-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1080px) { .services-grid { grid-template-columns: repeat(4, 1fr); gap: 16px; } }

.service-card {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 26px 24px 28px;
  background: var(--surface);
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  transition: transform 0.28s var(--ease), box-shadow 0.28s var(--ease),
              border-color 0.28s var(--ease);
}
.service-card::before {
  content: "";
  position: absolute;
  left: -1px; right: -1px; top: -1px;
  height: 3px;
  background: linear-gradient(90deg, var(--teal-700), var(--olive-500));
  border-radius: var(--radius) var(--radius) 0 0;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.34s var(--ease);
}

/* Верхняя строка карточки: иконка слева, указатель перехода справа */
.service-card__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 54px; height: 54px;
  background: var(--teal-100);
  border-radius: var(--radius);
  color: var(--teal-700);
  transition: background-color 0.28s var(--ease), color 0.28s var(--ease);
}
.service-card__icon svg {
  width: 28px; height: 28px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.service-card__cue {
  position: absolute;
  top: 30px; right: 22px;
  display: inline-flex;
  align-items: center;
  color: var(--ink-3);
  transition: color 0.28s var(--ease), transform 0.28s var(--ease);
}
.service-card__cue svg { width: 19px; height: 19px; }

.service-card h3 {
  margin: 0;
  font-size: 1.24rem;
  line-height: 1.24;
}
.service-card h3 a { color: var(--ink); text-decoration: none; }
/* Вся карточка кликабельна, но в потоке табуляции остаётся одна ссылка */
.service-card h3 a::after { content: ""; position: absolute; inset: 0; }

.service-card p {
  margin: 0;
  font-size: 0.94rem;
  line-height: 1.58;
  color: var(--ink-2);
}

.service-card:hover,
.service-card:focus-within {
  transform: translateY(-4px);
  border-color: var(--rule-2);
  box-shadow: 0 18px 38px rgba(10, 44, 51, 0.11);
}
.service-card:hover::before,
.service-card:focus-within::before { transform: scaleX(1); }
.service-card:hover .service-card__icon,
.service-card:focus-within .service-card__icon { background: var(--teal-700); color: #fff; }
.service-card:hover .service-card__cue,
.service-card:focus-within .service-card__cue {
  color: var(--teal-700);
  transform: translateX(4px);
}
.service-card:hover h3 a { color: var(--teal-700); }

.service-card:focus-within { outline: 2px solid var(--olive-600); outline-offset: 3px; }

/* Правило появления .js [data-reveal].is-visible задаёт transform: none
   и по специфичности перебивает .service-card:hover, из-за чего подъём
   карточки не срабатывал. Возвращаем его более специфичным селектором. */
.js .service-card[data-reveal].is-visible:hover,
.js .service-card[data-reveal].is-visible:focus-within {
  transform: translateY(-4px);
}
.service-card h3 a:focus-visible { outline: none; }

/* ---------------------------------------------------------
   9. Почему обращаются
   --------------------------------------------------------- */
.reasons { display: grid; gap: 30px; }
@media (min-width: 640px) { .reasons { grid-template-columns: repeat(2, 1fr); gap: 34px 44px; } }

.reason { padding-top: 20px; border-top: 1px solid var(--rule-2); }
.reason h3 { margin-bottom: 0.45em; }
.reason p { margin: 0; font-size: 0.96rem; color: var(--ink-2); }

/* ---------------------------------------------------------
   10. Управляющий (тёмная акцентная секция)
   --------------------------------------------------------- */
.section--manager {
  background: var(--teal-900);
  color: var(--on-dark-2);
  overflow: hidden;
}
.section--manager h2,
.section--manager h3 { color: var(--on-dark); }

.manager { display: grid; gap: 32px; }

.manager__photo { position: relative; }
.manager__photo::after {
  content: "";
  position: absolute;
  left: 14px; bottom: -14px;
  width: 72px; height: 4px;
  background: var(--olive-500);
}
.manager__photo img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  object-position: 50% 28%;
  border-radius: var(--radius);
  filter: saturate(0.9) contrast(1.02);
}

.manager__role {
  margin-bottom: 10px;
  padding-left: 18px;
  position: relative;
  font-size: 0.94rem;
  color: var(--on-dark-2);
}
.manager__role::before {
  content: "";
  position: absolute;
  left: 0; top: 0.72em;
  width: 10px; height: 2px;
  background: var(--olive-500);
}

.manager__name {
  font-size: clamp(1.85rem, 1.3rem + 2vw, 2.9rem);
  margin-bottom: 0.4em;
}
.manager__lede {
  font-size: 1.06rem;
  color: var(--on-dark);
  max-width: 56ch;
  margin-bottom: 32px;
}

.career { margin-bottom: 30px; }
.career__title { font-size: 1.05rem; margin-bottom: 0.5em; }
.career__intro { font-size: 0.94rem; margin-bottom: 16px; color: var(--on-dark-2); }

.career__list {
  list-style: none;
  position: relative;
  padding-left: 24px;
  display: grid;
  gap: 13px;
}
.career__list::before {
  content: "";
  position: absolute;
  left: 3px; top: 8px; bottom: 8px;
  width: 1px;
  background: var(--on-dark-rule);
}
.career__list li {
  position: relative;
  font-size: 0.96rem;
  line-height: 1.5;
  color: var(--on-dark);
}
.career__list li::before {
  content: "";
  position: absolute;
  left: -24px; top: 0.6em;
  width: 7px; height: 7px;
  border: 1px solid var(--olive-500);
  background: var(--teal-900);
  border-radius: 50%;
}

.manager__focus {
  padding: 22px 24px;
  background: rgba(255, 255, 255, 0.045);
  border-left: 2px solid var(--olive-500);
  border-radius: 0 var(--radius) var(--radius) 0;
}
.manager__focus h3 { font-size: 0.98rem; margin-bottom: 0.5em; }
.manager__focus p { margin: 0; font-size: 0.95rem; color: var(--on-dark-2); }

@media (min-width: 900px) {
  .manager {
    grid-template-columns: minmax(0, 0.82fr) minmax(0, 1.18fr);
    gap: 56px;
    align-items: start;
  }
  .manager__photo { position: sticky; top: 118px; }
  .manager__photo img { aspect-ratio: 3 / 4; object-position: 50% 22%; }
}
@media (min-width: 1200px) { .manager { gap: 72px; } }

/* ---------------------------------------------------------
   11. Документы
   --------------------------------------------------------- */
.credentials {
  margin-top: 56px;
  padding-top: 40px;
  border-top: 1px solid var(--on-dark-rule);
}
.credentials__head { margin-bottom: 28px; }
.credentials__head h3 { font-size: 1.3rem; margin-bottom: 0.35em; }
.credentials__head p { margin: 0; font-size: 0.93rem; color: var(--on-dark-2); }

@media (min-width: 800px) {
  .credentials__head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 32px;
  }
  .credentials__head h3 { margin-bottom: 0; }
}

.credentials-grid {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
}
@media (min-width: 760px) { .credentials-grid { grid-template-columns: repeat(4, 1fr); gap: 18px; } }

.credential__link {
  display: flex;
  flex-direction: column;
  height: 100%;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--on-dark-rule);
  border-radius: var(--radius);
  text-decoration: none;
  overflow: hidden;
  transition: transform 0.28s var(--ease), border-color 0.28s var(--ease),
              background-color 0.28s var(--ease);
}
.credential__link:hover {
  transform: translateY(-4px);
  border-color: rgba(139, 158, 44, 0.6);
  background: rgba(255, 255, 255, 0.09);
}

.credential__frame {
  display: block;
  padding: 14px 14px 0;
}
.credential__frame img {
  width: 100%;
  height: 168px;
  object-fit: contain;
  object-position: center top;
  background: #fff;
  border-radius: 2px;
}
.credential__frame--wide img { height: 168px; object-fit: contain; }

@media (min-width: 760px) { .credential__frame img { height: 190px; } }

.credential__body {
  display: block;
  padding: 14px 16px 18px;
}
.credential__name {
  display: block;
  font-family: var(--serif);
  font-size: 0.98rem;
  line-height: 1.3;
  color: var(--on-dark);
  margin-bottom: 4px;
}
.credential__kind {
  display: block;
  font-size: 0.82rem;
  line-height: 1.4;
  color: var(--on-dark-2);
}

/* ---------------------------------------------------------
   12. Этапы работы
   --------------------------------------------------------- */
/* Направляющая, соединяющая этапы: на мобильном — вертикальные
   отрезки внутри каждого шага, на десктопе — одна линия,
   которая прочерчивается при появлении секции. */
.steps-wrap { position: relative; }

.steps__rail { display: none; }

.steps {
  list-style: none;
  display: grid;
  gap: 0;
  counter-reset: none;
}
.step {
  position: relative;
  padding: 22px 0 22px 58px;
  border-top: 1px solid var(--rule);
}
.step:last-child { border-bottom: 1px solid var(--rule); }
.step__num {
  position: absolute;
  left: 0; top: 20px;
  width: 38px; height: 38px;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--serif);
  font-size: 1.05rem;
  color: var(--teal-700);
  border: 1px solid var(--rule-2);
  border-radius: 50%;
  background: var(--surface);
}
.step:not(:last-child)::after {
  content: "";
  position: absolute;
  left: 19px;
  top: 58px;
  bottom: -21px;
  width: 1px;
  background: var(--rule-2);
}

.step h3 { margin-bottom: 0.35em; }
.step p { margin: 0; font-size: 0.94rem; color: var(--ink-2); }

@media (min-width: 900px) {
  .steps {
    grid-template-columns: repeat(5, 1fr);
    border-top: 1px solid var(--rule);
    padding-top: 30px;
  }
  .step {
    padding: 0 22px 0 0;
    border-top: none;
  }
  .step:last-child { border-bottom: none; }
  .step__num {
    position: static;
    margin-bottom: 18px;
  }
  /* На десктопе вертикальные отрезки не нужны — их заменяет
     горизонтальная направляющая под кружками. */
  .step:not(:last-child)::after { content: none; }

  .steps__rail {
    display: block;
    position: absolute;
    top: 50px;
    left: 19px;
    width: 80%;
    height: 1px;
    background: var(--teal-500);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 1.1s var(--ease);
  }
  .steps__rail.is-drawn { transform: scaleX(1); }
}

/* ---------------------------------------------------------
   13. О компании
   --------------------------------------------------------- */
.about { display: grid; gap: 40px; }

.about__visual { position: relative; }
/* Реальная фотография кабинета вместо схематичного рисунка.
   Тонкая рамка и та же геометрия, что была у чертежа, сохраняют
   архитектурный характер блока. */
.about__photo {
  margin: 0;
  overflow: hidden;
  background: var(--surface);
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  box-shadow: 0 14px 34px rgba(10, 44, 51, 0.07);
}
.about__photo img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  object-position: 50% 46%;
  filter: saturate(0.94) contrast(1.03);
  transform: scale(1.005);
  transition: transform 0.7s var(--ease);
}
.about__visual:hover .about__photo img { transform: scale(1.03); }

.about__plate {
  margin-top: -34px;
  margin-left: 16px;
  margin-right: 16px;
  position: relative;
  padding: 20px 22px;
  background: var(--teal-900);
  border-radius: var(--radius);
  box-shadow: 0 14px 32px rgba(10, 44, 51, 0.16);
}
.about__plate p { margin: 0; max-width: none; }
.about__plate-label { font-size: 0.82rem; color: var(--on-dark-2); margin-bottom: 5px !important; }
.about__plate-value { font-family: var(--serif); font-size: 1.14rem; color: var(--on-dark); }
.about__plate-note { font-size: 0.9rem; color: var(--on-dark-2); }
.about__plate-coords {
  margin-top: 12px !important;
  padding-top: 12px;
  border-top: 1px solid var(--on-dark-rule);
  font-size: 0.84rem;
  color: var(--olive-200);
  font-variant-numeric: tabular-nums;
}

.about__text h2 { margin-bottom: 0.5em; }
.about__text p { margin-bottom: 1.1em; }
.about__text .btn { margin-top: 8px; }

@media (min-width: 960px) {
  .about {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 64px;
    align-items: center;
  }
  .about__plate { margin-left: 28px; margin-right: 52px; margin-top: -34px; }
}

/* ---------------------------------------------------------
   14. Консультация и форма
   --------------------------------------------------------- */
.consult { display: grid; gap: 36px; }
@media (min-width: 900px) {
  .consult { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 60px; align-items: start; }
}

.consult__text h2 { margin-bottom: 0.5em; }
.consult__contacts {
  list-style: none;
  display: grid;
  gap: 7px;
  margin: 24px 0;
  padding: 20px 0;
  border-block: 1px solid var(--rule-2);
}
.consult__contacts a {
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--ink);
  text-decoration: none;
}
.consult__contacts a:hover { color: var(--teal-700); }
.consult__note { font-size: 0.87rem; color: var(--ink-3); }

.form {
  padding: 28px 24px;
  background: var(--surface);
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  box-shadow: 0 14px 34px rgba(10, 44, 51, 0.06);
}
@media (min-width: 560px) { .form { padding: 32px 30px; } }

.form-row { margin-bottom: 18px; }
.form-row label {
  display: block;
  margin-bottom: 7px;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--ink);
}
.form-row input[type="text"],
.form-row input[type="tel"],
.form-row textarea {
  width: 100%;
  padding: 12px 14px;
  font-family: var(--sans);
  font-size: 1rem;
  color: var(--ink);
  background: var(--paper);
  border: 1px solid var(--rule-2);
  border-radius: var(--radius);
  transition: border-color 0.2s var(--ease), background-color 0.2s var(--ease),
              box-shadow 0.2s var(--ease);
}
.form-row input:hover,
.form-row textarea:hover { border-color: var(--ink-3); }
.form-row input:focus,
.form-row textarea:focus {
  outline: none;
  background: var(--surface);
  border-color: var(--teal-700);
  box-shadow: 0 0 0 3px rgba(14, 74, 86, 0.12);
}
.form-row textarea { min-height: 108px; resize: vertical; }

.form-consent { display: flex; align-items: flex-start; gap: 11px; }
.form-consent input { margin-top: 4px; width: 17px; height: 17px; flex: none; accent-color: var(--teal-700); }
.form-consent label { font-weight: 400; font-size: 0.87rem; color: var(--ink-2); margin-bottom: 0; }

.form-hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.form-status {
  display: none;
  margin-top: 16px;
  padding: 13px 15px;
  border-radius: var(--radius);
  font-size: 0.92rem;
}
.form-status.is-success { display: block; background: #E8F1EA; color: #245A3D; border: 1px solid #C3DDCB; }
.form-status.is-error { display: block; background: #F8ECEA; color: #8E3128; border: 1px solid #E6C8C3; }

/* ---------------------------------------------------------
   15. Контакты
   --------------------------------------------------------- */
.contacts { display: grid; gap: 36px; }
@media (min-width: 900px) {
  .contacts { grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr); gap: 56px; align-items: start; }
}

.contacts__list { margin: 0 0 24px; }
.contacts__list dt {
  margin-top: 20px;
  font-size: 0.82rem;
  color: var(--ink-3);
}
.contacts__list dt:first-child { margin-top: 0; }
.contacts__list dd {
  margin: 5px 0 0;
  font-size: 1rem;
  color: var(--ink);
  max-width: 40ch;
}
.contacts__list dd a { font-weight: 600; color: var(--ink); text-decoration: none; }
.contacts__list dd a:hover { color: var(--teal-700); }

.contacts__map {
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--paper-2);
}
.contacts__map iframe { width: 100%; height: 340px; border: 0; }
@media (min-width: 900px) { .contacts__map iframe { height: 420px; } }

/* ---------------------------------------------------------
   16. Подвал
   --------------------------------------------------------- */
.site-footer {
  background: var(--teal-900);
  color: var(--on-dark-2);
  padding-block: 56px 26px;
}

.footer-grid { display: grid; gap: 34px; padding-bottom: 34px; border-bottom: 1px solid var(--on-dark-rule); }
@media (min-width: 640px) { .footer-grid { grid-template-columns: repeat(2, 1fr); gap: 34px 40px; } }
@media (min-width: 1000px) { .footer-grid { grid-template-columns: 1.3fr 1fr 1fr 1fr; gap: 48px; } }

.footer-logo {
  display: inline-block;
  padding: 12px 16px;
  background: var(--surface);
  border-radius: var(--radius);
  line-height: 0;
  margin-bottom: 16px;
}
.footer-logo img { width: 152px; height: auto; }
.footer-brand p { margin: 0; font-size: 0.9rem; max-width: 30ch; color: var(--on-dark-2); }

.footer-col h3 {
  font-size: 0.98rem;
  color: var(--on-dark);
  margin-bottom: 14px;
}
.footer-col ul { list-style: none; display: grid; gap: 9px; }
.footer-col li { font-size: 0.9rem; line-height: 1.45; }
.footer-col a { color: var(--on-dark-2); text-decoration: none; }
.footer-col a:hover { color: #fff; }

.footer-bottom {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding-top: 22px;
  font-size: 0.84rem;
  color: #7D9296;
}
@media (min-width: 700px) { .footer-bottom { flex-direction: row; justify-content: space-between; } }

/* ---------------------------------------------------------
   17. Lightbox
   --------------------------------------------------------- */
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 120;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.lightbox[hidden] { display: none; }

.lightbox__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(5, 26, 31, 0.9);
  -webkit-backdrop-filter: blur(3px);
  backdrop-filter: blur(3px);
}

.lightbox__dialog {
  position: relative;
  z-index: 1;
  width: min(460px, 100%);
  max-height: 100%;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.lightbox__figure { margin: 0; text-align: center; }
.lightbox__figure img {
  width: min(100%, 420px);
  height: auto;
  max-height: 64vh;
  object-fit: contain;
  margin-inline: auto;
  background: #fff;
  border-radius: var(--radius);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.45);
}
.lightbox__caption {
  margin-top: 14px;
  font-family: var(--serif);
  font-size: 1rem;
  color: var(--on-dark);
}

.lightbox__controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
}
.lightbox__nav {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px; height: 44px;
  padding: 0;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: 50%;
  color: #fff;
  cursor: pointer;
  transition: background-color 0.2s var(--ease), border-color 0.2s var(--ease);
}
.lightbox__nav:hover { background: rgba(255, 255, 255, 0.18); border-color: var(--olive-500); }
.lightbox__nav svg { width: 18px; height: 18px; }
.lightbox__counter {
  min-width: 52px;
  text-align: center;
  font-size: 0.88rem;
  color: var(--on-dark-2);
  font-variant-numeric: tabular-nums;
}

.lightbox__close {
  position: absolute;
  top: -8px; right: 0;
  width: 42px; height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: 50%;
  color: #fff;
  font-size: 1rem;
  cursor: pointer;
  transition: background-color 0.2s var(--ease), border-color 0.2s var(--ease);
}
.lightbox__close:hover { background: rgba(255, 255, 255, 0.18); border-color: var(--olive-500); }

@media (min-width: 700px) {
  .lightbox__dialog { width: min(520px, 100%); }
  .lightbox__figure img { width: min(100%, 480px); max-height: 70vh; }
  .lightbox__close { top: -16px; right: -16px; }
}

body.lightbox-open { overflow: hidden; }

/* ---------------------------------------------------------
   18. Появление при прокрутке
   Без JS (нет класса .js) содержимое видно всегда.
   --------------------------------------------------------- */
.js [data-reveal] {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.62s var(--ease), transform 0.62s var(--ease);
  transition-delay: var(--reveal-delay, 0ms);
  will-change: opacity, transform;
}
.js [data-reveal].is-visible {
  opacity: 1;
  transform: none;
  will-change: auto;
}

/* Заголовки H2 раскрываются вертикальной шторкой — «редакционный»
   приём, поддерживающий чертёжный характер макета. Нижний отступ
   отрицательный, чтобы не срезались выносные элементы букв.

   ВАЖНО: clip-path НИКОГДА не вешается на сам элемент с data-reveal.
   Chromium обрезает по clip-path прямоугольник, с которым работает
   IntersectionObserver, поэтому у полностью закрытого элемента
   intersectionRatio всегда 0 — наблюдатель не сработает, класс
   is-visible не появится, и заголовок останется скрытым навсегда.
   Поэтому маска накладывается либо на вложенный H2, либо на
   внутренний span.mask-line. */
.js [data-reveal] h2:not([data-reveal]),
.js h2[data-reveal] .mask-line {
  clip-path: inset(0 0 110% 0);
  transition: clip-path 0.85s var(--ease);
  transition-delay: calc(var(--reveal-delay, 0ms) + 60ms);
}
.js [data-reveal].is-visible h2:not([data-reveal]),
.js h2[data-reveal].is-visible .mask-line {
  clip-path: inset(0 0 -12% 0);
}

.mask-line { display: block; }

/* Вступительная последовательность hero — единственный «постановочный» момент */
.js .hero__title,
.js .hero__lede,
.js .hero__actions,
.js .hero__card {
  opacity: 0;
  transform: translateY(20px);
}
.js .hero.is-ready .hero__title,
.js .hero.is-ready .hero__lede,
.js .hero.is-ready .hero__actions,
.js .hero.is-ready .hero__card {
  opacity: 1;
  transform: none;
  transition: opacity 0.8s var(--ease), transform 0.8s var(--ease);
}
.js .hero.is-ready .hero__lede { transition-delay: 0.1s; }
.js .hero.is-ready .hero__actions { transition-delay: 0.2s; }
.js .hero.is-ready .hero__card { transition-delay: 0.3s; }

.js .hero__media img { transform: scale(1.06); transition: transform 1.6s var(--ease); }
.js .hero.is-ready .hero__media img { transform: scale(1); }

/* ---------------------------------------------------------
   19. Уважение к настройке «уменьшить движение»
   --------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }

  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    transition-delay: 0ms !important;
    scroll-behavior: auto !important;
  }

  .js [data-reveal],
  .js .hero__title,
  .js .hero__lede,
  .js .hero__actions,
  .js .hero__card {
    opacity: 1 !important;
    transform: none !important;
  }
  .js .hero__media img { transform: none !important; }

  .js [data-reveal] h2:not([data-reveal]),
  .js h2[data-reveal] .mask-line,
  .js [data-reveal].is-visible h2:not([data-reveal]),
  .js h2[data-reveal].is-visible .mask-line { clip-path: none !important; }

  .steps__rail { transform: scaleX(1) !important; }

  .about__photo img,
  .about__visual:hover .about__photo img { transform: none !important; }

  .btn:hover,
  .service-card:hover,
  .service-card:focus-within,
  .credential__link:hover { transform: none !important; }
}


/* =========================================================
   Проверка долгов и предварительная оценка банкротства
   Единая «панель-инструмент»: две связанные половины
   в общей рамке, разделённые волосяной линией.
   ========================================================= */

.section--debt { background: var(--paper); }

/* Общая рамка объединяет обе половины в один инструмент */
.debt-panel {
  display: grid;
  background: var(--surface);
  border: 1px solid var(--rule);
  border-top: 3px solid var(--teal-700);
  border-radius: var(--radius);
  box-shadow: 0 18px 44px rgba(10, 44, 51, 0.07);
  overflow: hidden;
}

.debt-panel__side {
  display: flex;
  flex-direction: column;
  padding: 30px 24px 32px;
}

.debt-panel__side + .debt-panel__side { border-top: 1px solid var(--rule); }

/* Левая половина слегка подкрашена — читается как «справка», */
/* правая остаётся белой рабочей областью                      */
.debt-fssp {
  background: linear-gradient(180deg, rgba(227, 237, 238, 0.6), rgba(227, 237, 238, 0) 58%);
}

/* Подпись-указатель: тот же приём, что у роли управляющего */
.debt-panel__label {
  position: relative;
  margin: 0 0 14px;
  padding-left: 18px;
  font-size: 0.88rem;
  color: var(--ink-3);
  max-width: none;
}
.debt-panel__label::before {
  content: "";
  position: absolute;
  left: 0; top: 0.72em;
  width: 10px; height: 2px;
  background: var(--olive-500);
}

.debt-panel h3 {
  font-size: clamp(1.35rem, 1.12rem + 0.72vw, 1.72rem);
  line-height: 1.2;
  max-width: 21ch;
  margin-bottom: 14px;
}

.debt-panel__side > p { color: var(--ink-2); font-size: 0.96rem; }
.debt-quiz-side h3 { max-width: 27ch; }

.debt-note {
  margin: 12px 0 0;
  font-size: 0.83rem;
  line-height: 1.45;
  color: var(--ink-3);
}

/* --- Левая половина: официальный источник --- */
.debt-source {
  margin: 20px 0 0;
  padding: 16px 18px;
  background: var(--paper);
  border-left: 2px solid var(--olive-500);
  border-radius: 0 var(--radius) var(--radius) 0;
}
.debt-source__owner {
  display: block;
  margin-bottom: 4px;
  font-size: 0.82rem;
  color: var(--ink-3);
}
.debt-source__name {
  display: block;
  font-family: var(--serif);
  font-size: 1.02rem;
  line-height: 1.32;
  color: var(--ink);
}

.debt-fssp__cta { margin-top: 26px; }
.debt-fssp__cta .btn { width: 100%; }

/* --- Правая половина: пошаговая оценка --- */

/* Индикатор шагов — три отрезка измерительной шкалы */
.debt-quiz__meter {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 1fr;
  gap: 6px;
  margin: 22px 0 10px;
}
.debt-quiz__seg {
  height: 3px;
  background: var(--rule);
  border-radius: 2px;
  overflow: hidden;
}
.debt-quiz__seg::after {
  content: "";
  display: block;
  height: 100%;
  background: linear-gradient(90deg, var(--teal-700), var(--olive-500));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.5s var(--ease);
}
.debt-quiz__seg.is-done::after { transform: scaleX(1); }

.debt-quiz__counter {
  margin: 0 0 20px;
  font-size: 0.85rem;
  color: var(--ink-3);
  font-variant-numeric: tabular-nums;
}

.debt-quiz { display: flex; flex-direction: column; }

/* Шаги лежат в одной ячейке сетки: высота равна самому высокому,
   поэтому при переходе между вопросами блок не «прыгает» */
.debt-quiz__stack { display: grid; }

.debt-quiz__step {
  grid-area: 1 / 1;
  min-inline-size: 0;
  margin: 0;
  padding: 0;
  border: 0;
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  /* visibility переключается без интерполяции: при уходе — после
     затухания, при появлении — сразу, иначе браузер откажет в фокусе */
  transition: opacity 0.38s var(--ease), transform 0.38s var(--ease),
              visibility 0s linear 0.38s;
}
.debt-quiz__step.is-active {
  opacity: 1;
  visibility: visible;
  transform: none;
  transition: opacity 0.38s var(--ease), transform 0.38s var(--ease),
              visibility 0s linear 0s;
}

.debt-quiz__step legend {
  padding: 0;
  margin-bottom: 16px;
  font-family: var(--serif);
  font-size: 1.1rem;
  line-height: 1.3;
  color: var(--ink);
}

.quiz-option {
  display: flex;
  align-items: center;
  gap: 13px;
  margin-bottom: 10px;
  padding: 13px 16px;
  background: var(--surface);
  border: 1px solid var(--rule-2);
  border-radius: var(--radius);
  cursor: pointer;
  transition: border-color 0.2s var(--ease), background-color 0.2s var(--ease),
              box-shadow 0.2s var(--ease);
}
.quiz-option:last-of-type { margin-bottom: 0; }
.quiz-option:hover { border-color: var(--teal-500); background: rgba(227, 237, 238, 0.45); }

.quiz-option input {
  appearance: none;
  -webkit-appearance: none;
  position: relative;
  flex: none;
  width: 19px; height: 19px;
  margin: 0;
  background: var(--surface);
  border: 1.5px solid var(--rule-2);
  border-radius: 50%;
  cursor: pointer;
  transition: border-color 0.2s var(--ease);
}
.quiz-option input::after {
  content: "";
  position: absolute;
  inset: 3px;
  background: var(--teal-700);
  border-radius: 50%;
  transform: scale(0);
  transition: transform 0.22s var(--ease);
}
.quiz-option input:checked { border-color: var(--teal-700); }
.quiz-option input:checked::after { transform: scale(1); }
.quiz-option input:focus-visible { outline: 2px solid var(--olive-600); outline-offset: 3px; }

.quiz-option span {
  font-size: 0.97rem;
  line-height: 1.42;
  color: var(--ink-2);
  transition: color 0.2s var(--ease);
}

/* Выбранный вариант: заливка, двойная рамка, плотное начертание */
.quiz-option:has(input:checked) {
  border-color: var(--teal-700);
  background: var(--teal-100);
  box-shadow: inset 0 0 0 1px var(--teal-700);
}
.quiz-option:has(input:checked) span { color: var(--ink); font-weight: 600; }

.debt-quiz__actions {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 24px;
}
.debt-quiz__actions .btn { min-width: 124px; justify-content: center; }
.debt-quiz__next { margin-left: auto; }
.debt-quiz__next:disabled { opacity: 0.45; cursor: not-allowed; transform: none; box-shadow: none; }

.debt-quiz__hint {
  min-height: 1.4em;
  margin: 10px 0 0;
  font-size: 0.85rem;
  color: #8E3128;
}

/* Атрибут hidden внутри панели должен побеждать display у .btn */
.debt-panel [hidden] { display: none !important; }

/* --- Результат --- */
.debt-quiz__result {
  margin-top: 4px;
  padding: 24px 24px 22px;
  background: var(--paper);
  border-left: 2px solid var(--olive-500);
  border-radius: 0 var(--radius) var(--radius) 0;
  animation: debtResultIn 0.45s var(--ease);
}
.debt-quiz__result:focus { outline: none; }
.debt-quiz__result:focus-visible { outline: 2px solid var(--olive-600); outline-offset: 3px; }

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

.debt-quiz__result-kicker {
  display: block;
  margin-bottom: 8px;
  font-size: 0.84rem;
  color: var(--ink-3);
}
.debt-quiz__result h4 {
  margin: 0 0 10px;
  font-family: var(--serif);
  font-weight: 700;
  font-size: 1.22rem;
  line-height: 1.28;
  letter-spacing: -0.008em;
  color: var(--ink);
}
.debt-quiz__result p { font-size: 0.95rem; max-width: 52ch; }

.debt-quiz__result-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px;
  margin: 20px 0 14px;
}

.link-button {
  padding: 0;
  background: none;
  border: 0;
  font-family: var(--sans);
  font-size: 0.93rem;
  font-weight: 600;
  color: var(--teal-700);
  text-decoration: underline;
  text-underline-offset: 0.2em;
  cursor: pointer;
}
.link-button:hover { color: var(--olive-600); }

/* Оценка целиком построена на JS: без него показываем только
   официальную проверку через ФССП, а не нерабочую форму */
.debt-quiz-side { display: none; }
.js .debt-quiz-side { display: flex; }

@media (min-width: 620px) {
  .debt-fssp__cta .btn { width: auto; }
}

@media (min-width: 980px) {
  .js .debt-panel { grid-template-columns: minmax(0, 0.88fr) minmax(0, 1.12fr); }
  .debt-panel__side { padding: 40px 36px 42px; }
  .js .debt-panel__side + .debt-panel__side {
    border-top: none;
    border-left: 1px solid var(--rule);
  }
}

@media (max-width: 420px) {
  /* На узких экранах длинная надпись кнопки должна остаться в одну строку */
  .debt-fssp__cta .btn { padding-inline: 18px; font-size: 0.94rem; }
}

@media (max-width: 400px) {
  .debt-panel__side { padding: 26px 18px 28px; }
  .debt-quiz__actions { gap: 10px; }
  .debt-quiz__actions .btn { min-width: 0; flex: 1; padding-inline: 16px; }
  .debt-quiz__result { padding: 20px 18px; }
}

@media (prefers-reduced-motion: reduce) {
  .debt-quiz__step,
  .debt-quiz__seg::after,
  .quiz-option,
  .quiz-option input,
  .quiz-option input::after { transition: none !important; }
  .debt-quiz__result { animation: none !important; }
  .quiz-option:hover { transform: none !important; }
}

/* =========================================================
   Внутренние страницы
   Продолжают визуальный язык главной: те же токены,
   та же сетка, та же типографика.
   ========================================================= */

/* --- Хлебные крошки --- */
.breadcrumbs {
  padding-top: 22px;
  font-size: 0.86rem;
  color: var(--ink-3);
}
.breadcrumbs ol {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 10px;
  list-style: none;
}
.breadcrumbs li { display: flex; align-items: center; gap: 10px; }
.breadcrumbs li:not(:last-child)::after {
  content: "";
  width: 12px; height: 1px;
  background: var(--rule-2);
}
.breadcrumbs a { color: var(--ink-3); text-decoration: none; }
.breadcrumbs a:hover { color: var(--teal-700); text-decoration: underline; }
.breadcrumbs [aria-current="page"] { color: var(--ink-2); }

/* --- Шапка внутренней страницы --- */
.page-hero {
  background: var(--paper);
  padding-bottom: 56px;
  border-bottom: 1px solid var(--rule);
}
.page-hero__inner { padding-top: 34px; }
.page-hero h1 {
  font-size: clamp(2rem, 1.4rem + 2.4vw, 3.2rem);
  max-width: 20ch;
  margin-bottom: 0.45em;
}
.page-hero__lede {
  font-size: 1.06rem;
  color: var(--ink-2);
  max-width: 62ch;
  margin-bottom: 28px;
}
.page-hero__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 22px; }
.page-hero__phone {
  font-size: 1.02rem;
  font-weight: 600;
  color: var(--ink);
  text-decoration: none;
  white-space: nowrap;
}
.page-hero__phone:hover { color: var(--teal-700); }

@media (min-width: 900px) {
  .page-hero { padding-bottom: 72px; }
  .page-hero__inner { padding-top: 40px; }
}

/* --- Текстовые блоки --- */
.prose h2 { margin-top: 0; }
.prose h3 {
  margin-top: 1.7em;
  margin-bottom: 0.5em;
  font-size: 1.1rem;
}
.prose h3:first-child { margin-top: 0; }
.prose p { margin-bottom: 1.05em; }
.prose > :last-child { margin-bottom: 0; }

.marked-list { list-style: none; display: grid; gap: 11px; margin: 0 0 1.2em; max-width: 66ch; }
.marked-list li {
  position: relative;
  padding-left: 22px;
  font-size: 0.97rem;
  line-height: 1.55;
  color: var(--ink-2);
}
.marked-list li::before {
  content: "";
  position: absolute;
  left: 0; top: 0.62em;
  width: 8px; height: 1px;
  background: var(--olive-500);
}
.marked-list strong { color: var(--ink); font-weight: 600; }
.marked-list > :last-child { margin-bottom: 0; }

/* --- Карточки-блоки --- */
.info-grid { display: grid; gap: 14px; margin-top: 30px; }
@media (min-width: 640px) { .info-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1040px) { .info-grid--3 { grid-template-columns: repeat(3, 1fr); } }

.info-card {
  padding: 24px 22px;
  background: var(--surface);
  border: 1px solid var(--rule);
  border-radius: var(--radius);
}
.section--surface .info-card { background: var(--paper); }
.info-card h3 { margin-bottom: 0.5em; font-size: 1.06rem; }
.info-card p { margin: 0; font-size: 0.95rem; color: var(--ink-2); }
.info-card .marked-list { margin-bottom: 0; }

/* --- Выделенная врезка --- */
.callout {
  margin: 28px 0;
  padding: 22px 24px;
  background: var(--paper);
  border-left: 2px solid var(--olive-500);
  border-radius: 0 var(--radius) var(--radius) 0;
}
.section--surface .callout { background: var(--paper); }
.section--reasons .callout,
.section--about .callout { background: var(--surface); }
.callout h3 { margin-bottom: 0.5em; font-size: 1.04rem; }
.callout p { margin: 0; font-size: 0.95rem; }
.callout p + p { margin-top: 0.8em; }

/* --- Нумерованные этапы --- */
.stages { list-style: none; counter-reset: stage; display: grid; gap: 0; margin-top: 28px; }
.stage {
  counter-increment: stage;
  position: relative;
  padding: 20px 0 20px 56px;
  border-top: 1px solid var(--rule);
}
.stage:last-child { border-bottom: 1px solid var(--rule); }
.stage::before {
  content: counter(stage);
  position: absolute;
  left: 0; top: 18px;
  width: 36px; height: 36px;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--serif);
  font-size: 1rem;
  color: var(--teal-700);
  background: var(--surface);
  border: 1px solid var(--rule-2);
  border-radius: 50%;
}
.section--surface .stage::before { background: var(--paper); }
.stage h3 { margin-bottom: 0.35em; font-size: 1.06rem; }
.stage p { margin: 0; font-size: 0.95rem; color: var(--ink-2); }

/* --- FAQ: нативный details, работает без JS и с клавиатуры --- */
.faq { display: grid; gap: 0; margin-top: 28px; }
.faq__item { border-top: 1px solid var(--rule); }
.faq__item:last-child { border-bottom: 1px solid var(--rule); }
.faq__item summary {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  padding: 20px 0;
  font-family: var(--serif);
  font-size: 1.05rem;
  line-height: 1.35;
  color: var(--ink);
  cursor: pointer;
  list-style: none;
}
.faq__item summary::-webkit-details-marker { display: none; }
.faq__item summary::after {
  content: "";
  flex: none;
  width: 13px; height: 13px;
  margin-top: 6px;
  border-right: 1.5px solid var(--teal-700);
  border-bottom: 1.5px solid var(--teal-700);
  transform: rotate(45deg);
  transition: transform 0.25s var(--ease);
}
.faq__item[open] summary::after { transform: rotate(-135deg); }
.faq__item summary:hover { color: var(--teal-700); }
.faq__item summary:focus-visible { outline: 2px solid var(--olive-600); outline-offset: 2px; }
.faq__answer { padding: 0 0 22px; }
.faq__answer p { margin: 0 0 0.9em; font-size: 0.96rem; }
.faq__answer > :last-child { margin-bottom: 0; }

/* --- Полоса призыва к действию --- */
.cta-band { background: var(--teal-900); color: var(--on-dark-2); }
.cta-band h2, .cta-band h3 { color: var(--on-dark); }
.cta-band p { color: var(--on-dark-2); }
.cta-band__grid { display: grid; gap: 34px; }
@media (min-width: 900px) {
  .cta-band__grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 60px; align-items: start; }
}
.cta-band__contacts { list-style: none; display: grid; gap: 8px; margin: 24px 0; padding: 22px 0; border-block: 1px solid var(--on-dark-rule); }
.cta-band__contacts a { font-size: 1.05rem; font-weight: 600; color: var(--on-dark); text-decoration: none; }
.cta-band__contacts a:hover { color: #fff; }
.cta-band .consult__note { color: #8FA3A6; }
.cta-band .consult__note a { color: var(--olive-200); }

/* --- Смежные услуги --- */
.related { display: grid; gap: 14px; margin-top: 28px; }
@media (min-width: 700px) { .related { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1100px) { .related--4 { grid-template-columns: repeat(4, 1fr); } }

.related__item {
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 22px 22px 24px;
  background: var(--surface);
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  text-decoration: none;
  transition: transform 0.26s var(--ease), border-color 0.26s var(--ease),
              box-shadow 0.26s var(--ease);
}
.section--surface .related__item { background: var(--paper); }
.related__item h3 { margin: 0; font-size: 1.06rem; color: var(--ink); }
.related__item p { margin: 0; font-size: 0.92rem; color: var(--ink-2); }
.related__item .link-arrow { margin-top: 6px; pointer-events: none; }
.related__item:hover {
  transform: translateY(-3px);
  border-color: var(--rule-2);
  box-shadow: 0 14px 30px rgba(10, 44, 51, 0.09);
}
.related__item:hover h3 { color: var(--teal-700); }
.related__item:hover .link-arrow svg { transform: translateX(4px); }

/* --- Полоса контактов внизу страницы --- */
.contact-strip { background: var(--paper-2); border-top: 1px solid var(--rule); }
.contact-strip__grid { display: grid; gap: 26px; }
@media (min-width: 700px) { .contact-strip__grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1040px) { .contact-strip__grid { grid-template-columns: repeat(4, 1fr); } }
.contact-strip__item dt { font-size: 0.82rem; color: var(--ink-3); margin-bottom: 6px; }
.contact-strip__item dd { margin: 0; font-size: 0.98rem; color: var(--ink); line-height: 1.5; }
.contact-strip__item a { color: var(--ink); font-weight: 600; text-decoration: none; }
.contact-strip__item a:hover { color: var(--teal-700); }

/* --- Таблица факторов стоимости --- */
.factor-list { display: grid; gap: 0; margin-top: 28px; }
.factor {
  display: grid;
  gap: 6px;
  padding: 20px 0;
  border-top: 1px solid var(--rule);
}
.factor:last-child { border-bottom: 1px solid var(--rule); }
@media (min-width: 800px) {
  .factor { grid-template-columns: minmax(0, 0.42fr) minmax(0, 0.58fr); gap: 32px; align-items: baseline; }
}
.factor__name { font-family: var(--serif); font-size: 1.05rem; color: var(--ink); }
.factor__note { margin: 0; font-size: 0.95rem; color: var(--ink-2); }

/* --- Служебные пометки (видны только в исходном коде staging) --- */
.doc-note {
  margin-top: 26px;
  padding: 18px 20px;
  background: var(--paper);
  border: 1px dashed var(--rule-2);
  border-radius: var(--radius);
  font-size: 0.9rem;
  color: var(--ink-3);
}
.doc-note strong { color: var(--ink-2); }

@media (prefers-reduced-motion: reduce) {
  .related__item:hover { transform: none !important; }
  .faq__item summary::after { transition: none !important; }
}

/* V9.1: отдельное согласие на обработку ПД и отдельная ссылка на Политику */
.form-consent__copy { min-width: 0; }
.form-consent__note { margin: 5px 0 0; font-size: 0.82rem; line-height: 1.45; color: var(--ink-3); }


/* =========================================================
   V10 — более содержательные внутренние страницы и услуги
   ========================================================= */
.section-head__eyebrow {
  margin: 0 0 10px;
  font-size: 0.78rem;
  line-height: 1.2;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--olive-600);
  font-weight: 700;
}

/* Главная: насыщенные карточки услуг */
@media (min-width: 1080px) {
  #services .services-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
}
.service-card--rich { gap: 16px; padding: 28px 26px 30px; min-height: 100%; }
.service-card--rich .service-card__top { display:flex; align-items:center; justify-content:space-between; gap:16px; }
.service-card__eyebrow {
  font-size: 0.78rem; line-height: 1.2; letter-spacing: .07em; text-transform: uppercase;
  color: var(--ink-3); font-weight: 700;
}
.service-card--rich .service-card__intro { font-size: 0.96rem; }
.service-card__list { list-style:none; display:grid; gap:8px; margin:2px 0 0; padding:16px 0 0; border-top:1px solid var(--rule); }
.service-card__list li { position:relative; padding-left:19px; font-size:.91rem; line-height:1.45; color:var(--ink-2); }
.service-card__list li::before { content:""; position:absolute; left:0; top:.67em; width:8px; height:1px; background:var(--olive-500); }
.service-card__more { display:inline-flex; align-items:center; gap:8px; margin-top:auto; padding-top:4px; color:var(--teal-700); font-size:.9rem; font-weight:700; }
.service-card__more svg { width:17px; height:17px; transition:transform .25s var(--ease); }
.service-card:hover .service-card__more svg, .service-card:focus-within .service-card__more svg { transform:translateX(4px); }

/* Каталог услуг */
.service-catalog { display:grid; gap:18px; margin-top:32px; }
@media (min-width: 860px) { .service-catalog { grid-template-columns:repeat(2,minmax(0,1fr)); } }
.service-detail-card {
  position:relative; display:flex; flex-direction:column; min-height:100%; padding:30px 28px;
  background:var(--surface); border:1px solid var(--rule); border-radius:var(--radius);
  transition:transform .28s var(--ease), box-shadow .28s var(--ease), border-color .28s var(--ease);
}
.section--surface .service-detail-card { background:var(--paper); }
.service-detail-card::before { content:""; position:absolute; left:-1px; right:-1px; top:-1px; height:3px; background:linear-gradient(90deg,var(--teal-700),var(--olive-500)); border-radius:var(--radius) var(--radius) 0 0; transform:scaleX(0); transform-origin:left; transition:transform .3s var(--ease); }
.service-detail-card:hover, .service-detail-card:focus-within { transform:translateY(-4px); border-color:var(--rule-2); box-shadow:0 18px 38px rgba(10,44,51,.10); }
.service-detail-card:hover::before, .service-detail-card:focus-within::before { transform:scaleX(1); }
.service-detail-card__head { display:flex; align-items:center; justify-content:space-between; gap:20px; margin-bottom:20px; }
.service-detail-card__number { font-family:var(--serif); font-size:1.2rem; color:var(--teal-700); }
.service-detail-card__audience { font-size:.76rem; font-weight:700; letter-spacing:.07em; text-transform:uppercase; color:var(--ink-3); }
.service-detail-card h3 { margin:0 0 12px; font-size:1.34rem; line-height:1.2; }
.service-detail-card h3 a { color:var(--ink); text-decoration:none; }
.service-detail-card h3 a::after { content:""; position:absolute; inset:0; }
.service-detail-card__intro { margin:0; color:var(--ink-2); font-size:.96rem; line-height:1.58; }
.service-detail-card__label { margin:20px 0 10px; padding-top:18px; border-top:1px solid var(--rule); color:var(--ink-3); font-size:.79rem; font-weight:700; letter-spacing:.06em; text-transform:uppercase; }
.service-detail-card__list { list-style:none; display:grid; gap:8px; margin:0 0 24px; padding:0; }
.service-detail-card__list li { position:relative; padding-left:20px; color:var(--ink-2); font-size:.92rem; line-height:1.45; }
.service-detail-card__list li::before { content:""; position:absolute; left:0; top:.66em; width:8px; height:1px; background:var(--olive-500); }
.service-detail-card__link { display:inline-flex; align-items:center; gap:8px; margin-top:auto; color:var(--teal-700); text-decoration:none; font-weight:700; font-size:.91rem; pointer-events:none; }
.service-detail-card__link svg { width:17px; height:17px; }

/* Навигация по жизненной ситуации */
.service-paths { background:var(--teal-900); color:var(--on-dark-2); }
.service-paths .section-head__eyebrow { color:var(--olive-200); }
.service-paths .section-head__title { color:var(--on-dark); }
.service-paths .section-head__lede { color:var(--on-dark-2); }
.service-paths__grid { display:grid; gap:1px; margin-top:32px; background:var(--on-dark-rule); border:1px solid var(--on-dark-rule); border-radius:var(--radius); overflow:hidden; }
@media (min-width: 760px) { .service-paths__grid { grid-template-columns:repeat(2,1fr); } }
.service-path { display:block; padding:28px 26px 30px; background:var(--teal-900); text-decoration:none; transition:background .25s var(--ease); }
.service-path:hover, .service-path:focus-visible { background:rgba(255,255,255,.045); }
.service-path span { display:block; margin-bottom:18px; font-family:var(--serif); color:var(--olive-200); }
.service-path h3 { margin:0 0 9px; color:var(--on-dark); font-size:1.12rem; }
.service-path p { margin:0; color:var(--on-dark-2); font-size:.93rem; line-height:1.55; }

/* Краткий состав работы на страницах услуг */
.service-scope__grid { display:grid; gap:14px; margin-top:30px; }
@media (min-width: 720px) { .service-scope__grid { grid-template-columns:repeat(2,minmax(0,1fr)); } }
.service-scope__item { position:relative; padding:26px 24px 28px; background:var(--surface); border:1px solid var(--rule); border-radius:var(--radius); }
.service-scope__item span { display:inline-block; margin-bottom:18px; font-family:var(--serif); font-size:1.05rem; color:var(--teal-700); }
.service-scope__item h3 { margin:0 0 8px; font-size:1.08rem; }
.service-scope__item p { margin:0; color:var(--ink-2); font-size:.94rem; line-height:1.55; }

/* Что должно быть понятно после первого разбора */
.first-step__grid { display:grid; gap:0; margin-top:30px; border-top:1px solid var(--rule); }
@media (min-width: 850px) { .first-step__grid { grid-template-columns:repeat(2,minmax(0,1fr)); } }
.first-step__item { position:relative; padding:26px 26px 28px 64px; border-bottom:1px solid var(--rule); }
@media (min-width: 850px) { .first-step__item:nth-child(odd) { border-right:1px solid var(--rule); } }
.first-step__item strong { position:absolute; left:0; top:29px; font-family:var(--serif); color:var(--teal-700); font-size:1rem; }
.first-step__item h3 { margin:0 0 8px; font-size:1.08rem; }
.first-step__item p { margin:0; color:var(--ink-2); font-size:.94rem; line-height:1.55; }

/* TODO остаются в исходнике, но не выводятся посетителю */
.doc-note { display:none !important; }

@media (prefers-reduced-motion: reduce) {
  .service-detail-card:hover, .service-detail-card:focus-within { transform:none !important; }
}


/* =========================================================
   V11 — фон внутренних страниц и расширенная подача услуг
   ========================================================= */
body.internal-page {
  background: #f4f6f5;
}
body.internal-page main {
  position: relative;
  isolation: isolate;
  background:
    radial-gradient(circle at 8% 12%, rgba(31,112,112,.075), transparent 29rem),
    radial-gradient(circle at 94% 42%, rgba(153,145,91,.075), transparent 27rem),
    linear-gradient(180deg, #f6f8f7 0%, #ffffff 29%, #f6f8f7 64%, #ffffff 100%);
}
body.internal-page main::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  opacity: .34;
  background-image:
    linear-gradient(rgba(13,66,70,.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(13,66,70,.035) 1px, transparent 1px);
  background-size: 68px 68px;
  -webkit-mask-image: linear-gradient(to bottom, transparent 0, #000 18%, #000 78%, transparent 100%);
  mask-image: linear-gradient(to bottom, transparent 0, #000 18%, #000 78%, transparent 100%);
}
body.internal-page .page-hero {
  position: relative;
  overflow: hidden;
  color: var(--on-dark-2);
  background:
    radial-gradient(circle at 84% 24%, rgba(194,185,117,.21), transparent 22rem),
    linear-gradient(122deg, #0a353c 0%, #0d4850 58%, #123f46 100%);
  border-bottom: 0;
}
body.internal-page .page-hero::before {
  content: "";
  position: absolute;
  width: 470px;
  height: 470px;
  right: -150px;
  bottom: -315px;
  border: 1px solid rgba(255,255,255,.10);
  border-radius: 50%;
  box-shadow: 0 0 0 72px rgba(255,255,255,.025), 0 0 0 145px rgba(255,255,255,.018);
  pointer-events: none;
}
body.internal-page .page-hero h1 { color: var(--on-dark); text-wrap: balance; }
body.internal-page .page-hero__lede { color: rgba(236,244,244,.82); max-width: 76ch; font-size: 1.08rem; line-height: 1.7; }
body.internal-page .page-hero__phone { color: var(--on-dark); }
body.internal-page .page-hero__phone:hover { color: var(--olive-200); }
body.internal-page .breadcrumbs { color: rgba(236,244,244,.58); }
body.internal-page .breadcrumbs a { color: rgba(236,244,244,.68); }
body.internal-page .breadcrumbs a:hover { color: var(--olive-200); }
body.internal-page .breadcrumbs [aria-current="page"] { color: rgba(236,244,244,.9); }
body.internal-page .breadcrumbs li:not(:last-child)::after { background: rgba(255,255,255,.22); }

body.internal-page .section { position: relative; }
body.internal-page .section--surface {
  background: rgba(255,255,255,.76);
  border-block: 1px solid rgba(13,66,70,.055);
  backdrop-filter: blur(2px);
}
body.internal-page .service-scope__item,
body.internal-page .info-card,
body.internal-page .related__item,
body.internal-page .service-detail-card {
  box-shadow: 0 12px 34px rgba(10,44,51,.045);
}
.service-scope__grid { gap: 18px; }
.service-scope__item { padding: 30px 28px 32px; }
.service-scope__item span { margin-bottom: 20px; }
.service-scope__item h3 { font-size: 1.12rem; }
.service-scope__item p { font-size: .96rem; line-height: 1.68; }
.service-when .info-card p,
.ecp-types .info-card p { line-height: 1.65; }
.service-when .callout { margin-top: 30px; }
.company-profile .info-card { min-height: 100%; }

@media (min-width: 980px) {
  .service-scope__grid { grid-template-columns: repeat(3, minmax(0,1fr)); }
}
@media (max-width: 720px) {
  body.internal-page .page-hero__lede { font-size: 1rem; line-height: 1.62; }
  body.internal-page main::before { background-size: 48px 48px; opacity: .24; }
  .service-scope__item { padding: 25px 22px 27px; }
}
@media (prefers-reduced-motion: reduce) {
  body.internal-page .section--surface { backdrop-filter: none; }
}


/* ============================================================
   V12 — editorial structure, legal reviews and outsourcing block
   Structural inspiration: mature legal-firm sites. No external
   assets, copied layouts or third-party icon files are used.
   ============================================================ */

@media (min-width: 1080px) and (max-width: 1240px) {
  .main-nav__list { gap: 20px; }
  .header-actions { gap: 12px; }
  .header-phone { font-size: .88rem; }
}

.section-head--wide { max-width: 900px; }

.section--outsourcing {
  background:
    radial-gradient(circle at 88% 12%, rgba(166,154,98,.12), transparent 26%),
    linear-gradient(135deg, #0b343b 0%, var(--teal-900) 58%, #102c31 100%);
  color: var(--on-dark-2);
  overflow: hidden;
}
.section--outsourcing .section-head__eyebrow { color: var(--olive-200); }
.section--outsourcing .section-head__title { color: var(--on-dark); }
.section--outsourcing .section-head__lede { color: rgba(236,244,244,.78); max-width: 82ch; }
.outsourcing-grid {
  display: grid;
  gap: 1px;
  margin-top: 38px;
  border: 1px solid rgba(255,255,255,.13);
  border-radius: 18px;
  overflow: hidden;
  background: rgba(255,255,255,.13);
}
@media (min-width: 780px) { .outsourcing-grid { grid-template-columns: repeat(2,minmax(0,1fr)); } }
@media (min-width: 1120px) { .outsourcing-grid { grid-template-columns: repeat(3,minmax(0,1fr)); } }
.outsourcing-card,
.outsourcing-cta {
  position: relative;
  padding: 32px 30px 34px;
  background: rgba(8,43,50,.96);
  min-height: 100%;
}
.outsourcing-card--lead { background: rgba(13,59,67,.98); }
.outsourcing-card__number {
  display: block;
  margin-bottom: 34px;
  font-family: var(--serif);
  font-size: 1.25rem;
  color: var(--olive-200);
}
.outsourcing-card__kicker,
.outsourcing-cta__eyebrow {
  margin: 0 0 10px;
  color: var(--olive-200);
  font-size: .76rem;
  font-weight: 800;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.outsourcing-card h3,
.outsourcing-cta h3 { margin: 0 0 13px; color: var(--on-dark); font-size: 1.2rem; line-height: 1.25; }
.outsourcing-card p,
.outsourcing-cta p { margin: 0; color: rgba(236,244,244,.72); font-size: .94rem; line-height: 1.65; }
.outsourcing-card__note,
.outsourcing-cta__note { margin-top: 18px !important; padding-top: 17px; border-top: 1px solid rgba(255,255,255,.12); font-size: .81rem !important; color: rgba(236,244,244,.54) !important; }
.outsourcing-cta {
  display: flex;
  flex-direction: column;
  justify-content: center;
  background: var(--paper-2);
}
.outsourcing-cta h3 { color: var(--ink); font-size: clamp(1.45rem,2vw,2rem); }
.outsourcing-cta p { color: var(--ink-2); }
.outsourcing-cta .outsourcing-cta__eyebrow { color: var(--teal-700); }
.outsourcing-cta__actions { display: grid; gap: 16px; align-items: start; margin-top: 24px; }
.outsourcing-cta .link-arrow { color: var(--teal-700); }
@media (max-width: 679px) {
  .outsourcing-card,.outsourcing-cta { padding: 27px 23px 29px; }
  .outsourcing-card__number { margin-bottom: 25px; }
}

.section--news { background: var(--paper); }
.news-heading {
  display: grid;
  gap: 20px;
  align-items: end;
  margin-bottom: 34px;
}
.news-heading h2 { margin: 0; max-width: 12ch; }
.news-heading > p { margin: 0; max-width: 60ch; color: var(--ink-2); line-height: 1.65; }
@media (min-width: 900px) { .news-heading { grid-template-columns: 1.05fr .95fr; } }
.news-grid { display: grid; gap: 16px; }
@media (min-width: 760px) { .news-grid { grid-template-columns: repeat(2,minmax(0,1fr)); } }
@media (min-width: 1080px) { .news-grid { grid-template-columns: 1.18fr .91fr .91fr; } }
.news-card {
  position: relative;
  min-height: 330px;
  border: 1px solid var(--rule);
  border-radius: var(--radius);
  overflow: hidden;
  background:
    linear-gradient(160deg, rgba(255,255,255,.96), rgba(244,246,243,.96)),
    var(--surface);
  transition: transform .25s var(--ease), box-shadow .25s var(--ease), border-color .25s var(--ease);
}
.news-card::before {
  content:"";
  position:absolute;
  width:180px;height:180px;
  right:-78px;top:-85px;
  border:1px solid rgba(30,92,101,.12);
  border-radius:50%;
  box-shadow: 0 0 0 34px rgba(30,92,101,.035), 0 0 0 68px rgba(30,92,101,.025);
}
.news-card--feature { background: linear-gradient(145deg,#0e3941,#143f45); border-color: transparent; }
.news-card--feature::before { border-color:rgba(230,219,158,.18); box-shadow:0 0 0 34px rgba(230,219,158,.04),0 0 0 68px rgba(230,219,158,.025); }
.news-card:hover,.news-card:focus-within { transform: translateY(-4px); box-shadow: 0 18px 42px rgba(10,44,51,.10); border-color: var(--rule-2); }
.news-card__link { position: relative; z-index:1; display:flex; flex-direction:column; min-height:100%; padding:28px 26px 29px; color:var(--ink); text-decoration:none; }
.news-card__meta { display:flex; gap:12px; flex-wrap:wrap; justify-content:space-between; margin-bottom:42px; color:var(--ink-3); font-size:.76rem; font-weight:700; letter-spacing:.04em; text-transform:uppercase; }
.news-card h3 { margin:0 0 14px; font-size:1.3rem; line-height:1.25; }
.news-card p { margin:0; color:var(--ink-2); font-size:.93rem; line-height:1.62; }
.news-card__more { display:inline-flex; align-items:center; gap:8px; margin-top:auto; padding-top:28px; color:var(--teal-700); font-size:.88rem; font-weight:800; }
.news-card__more svg { width:17px;height:17px; }
.news-card--feature .news-card__meta { color:rgba(236,244,244,.65); }
.news-card--feature h3 { color:var(--on-dark); }
.news-card--feature p { color:rgba(236,244,244,.75); }
.news-card--feature .news-card__more { color:var(--olive-200); }
.news-footer { margin-top:26px; }

.page-hero__kicker { margin:0 0 12px; color:var(--olive-200); font-size:.78rem; font-weight:800; letter-spacing:.09em; text-transform:uppercase; }
.news-index__intro { max-width:82ch; margin-bottom:34px; padding:22px 24px; border-left:3px solid var(--olive-500); background:var(--paper); color:var(--ink-2); }
.news-index__intro p { margin:0; line-height:1.65; }
.news-list { display:grid; gap:16px; }
.news-list-card { padding:30px 28px 32px; background:var(--paper); border:1px solid var(--rule); border-radius:var(--radius); }
.news-list-card__meta { display:flex; flex-wrap:wrap; gap:10px 18px; margin-bottom:18px; color:var(--ink-3); font-size:.77rem; font-weight:700; letter-spacing:.05em; text-transform:uppercase; }
.news-list-card h2 { margin:0 0 13px; font-size:clamp(1.35rem,2.2vw,1.8rem); }
.news-list-card h2 a { color:var(--ink); text-decoration:none; }
.news-list-card p { max-width:78ch; margin:0 0 20px; color:var(--ink-2); line-height:1.65; }
@media (min-width: 960px) { .news-list-card { padding:36px 38px 38px; } }

.article-layout { display:grid; gap:34px; align-items:start; }
@media (min-width: 980px) { .article-layout { grid-template-columns:minmax(0,1fr) 330px; gap:56px; } }
.legal-article { max-width:820px; }
.legal-article .article-lead { margin:0 0 34px; font-family:var(--serif); font-size:clamp(1.18rem,2vw,1.48rem); line-height:1.55; color:var(--ink); }
.legal-article h2 { margin:42px 0 14px; font-size:clamp(1.45rem,2.4vw,2rem); }
.legal-article p,.legal-article li { color:var(--ink-2); line-height:1.75; }
.legal-article ul { display:grid; gap:9px; padding-left:1.25em; }
.article-callout { margin:38px 0 0; padding:25px 26px; border-left:3px solid var(--teal-700); background:var(--paper-2); color:var(--ink-2); line-height:1.7; }
.article-sources { margin-top:54px; padding-top:32px; border-top:1px solid var(--rule); }
.article-sources h2 { margin-top:0; }
.article-sources ul { list-style:none; padding:0; }
.article-sources a { color:var(--teal-700); }
.article-sources p { margin-top:20px; font-size:.86rem; color:var(--ink-3); }
.article-aside { position:sticky; top:110px; padding:28px 26px; background:var(--paper); border:1px solid var(--rule); border-radius:var(--radius); }
.article-aside__eyebrow { margin:0 0 12px; color:var(--teal-700); font-size:.76rem; font-weight:800; letter-spacing:.07em; text-transform:uppercase; }
.article-aside h2 { margin:0 0 12px; font-size:1.35rem; }
.article-aside p { color:var(--ink-2); line-height:1.6; }
.article-aside .link-arrow { margin-top:20px; }
@media (max-width: 979px) { .article-aside { position:static; } }

@media (prefers-reduced-motion: reduce) {
  .news-card:hover,.news-card:focus-within { transform:none; }
}


/* ============================================================
   V13 — Telegram / MAX direct contact channels
   ============================================================ */
.messenger-contact{margin-top:22px}
.messenger-contact__lead{margin:0 0 13px;color:inherit;font-size:.94rem;line-height:1.55}
.messenger-actions{display:flex;flex-wrap:wrap;gap:12px}
.messenger-btn{display:inline-flex;align-items:center;justify-content:center;gap:11px;min-height:52px;padding:13px 20px;border:1px solid transparent;border-radius:13px;color:#fff;text-decoration:none;font-size:.94rem;font-weight:800;line-height:1.2;box-shadow:0 9px 24px rgba(7,35,42,.12);transition:transform .2s var(--ease),box-shadow .2s var(--ease),filter .2s var(--ease)}
.messenger-btn:hover,.messenger-btn:focus-visible{transform:translateY(-2px);box-shadow:0 13px 28px rgba(7,35,42,.18);filter:saturate(1.06)}
.messenger-btn:focus-visible{outline:3px solid rgba(230,219,158,.8);outline-offset:3px}
.messenger-btn--telegram{background:linear-gradient(135deg,#23a9e6 0%,#168bd2 100%)}
.messenger-btn--max{background:linear-gradient(135deg,#5365ef 0%,#8c43df 100%)}
.messenger-btn__icon{display:inline-grid;place-items:center;flex:0 0 auto;width:28px;height:28px;border-radius:50%;background:rgba(255,255,255,.16)}
.messenger-btn__icon svg{width:18px;height:18px;fill:currentColor}
.messenger-btn__icon--max svg{width:19px;height:19px}
.messenger-actions--compact{gap:8px}
.messenger-actions--compact .messenger-btn{min-height:42px;padding:10px 13px;border-radius:10px;font-size:.82rem}
.messenger-actions--compact .messenger-btn__icon{width:23px;height:23px}
.messenger-actions--compact .messenger-btn__icon svg{width:15px;height:15px}
.hero__messengers{margin:18px 0 2px;padding-top:18px;border-top:1px solid var(--rule)}
.hero__messengers>p{margin:0 0 10px;color:var(--ink-3);font-size:.78rem;font-weight:800;letter-spacing:.06em;text-transform:uppercase}
.hero__messengers .messenger-actions{display:grid;grid-template-columns:1fr 1fr}
.hero__messengers .messenger-btn{white-space:nowrap}
.cta-band .messenger-contact__lead{color:rgba(236,244,244,.76)}
.section--consult .messenger-contact__lead{color:var(--ink-2)}
.cta-band .messenger-contact,.section--consult .messenger-contact{padding-top:2px}
.info-grid--contact{display:grid;gap:16px}
@media(min-width:720px){.info-grid--contact{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(min-width:1180px){.info-grid--contact{grid-template-columns:repeat(4,minmax(0,1fr))}}
.contact-messenger-card .messenger-actions{margin-top:18px}
.contact-messenger-card .messenger-btn{width:100%}
.section--messenger-qr{background:radial-gradient(circle at 84% 18%,rgba(83,101,239,.09),transparent 28%),linear-gradient(180deg,var(--paper-2),#fff);border-block:1px solid var(--rule)}
.messenger-qr{display:grid;gap:34px;align-items:center}
.messenger-qr__copy{max-width:700px}
.messenger-qr__copy h2{margin:0 0 16px}
.messenger-qr__copy>p:not(.section-head__eyebrow):not(.messenger-qr__handle){color:var(--ink-2);line-height:1.7}
.messenger-qr__copy .messenger-actions{margin-top:24px}
.messenger-qr__handle{margin:18px 0 0;color:var(--ink-3)}
.messenger-qr__figure{width:min(100%,330px);margin:0 auto;padding:14px;border:1px solid var(--rule);border-radius:22px;background:#fff;box-shadow:0 18px 44px rgba(10,44,51,.09)}
.messenger-qr__figure img{display:block;width:100%;height:auto;border-radius:14px}
.messenger-qr__figure figcaption{margin-top:10px;color:var(--ink-3);font-size:.78rem;text-align:center}
@media(min-width:900px){.messenger-qr{grid-template-columns:minmax(0,1fr) 360px}}
@media(max-width:600px){.messenger-actions{display:grid;grid-template-columns:1fr}.messenger-btn{width:100%}.hero__messengers .messenger-actions{grid-template-columns:1fr}}
@media(prefers-reduced-motion:reduce){.messenger-btn{transition:none}.messenger-btn:hover,.messenger-btn:focus-visible{transform:none}}


/* ============================================================
   V15.1 HOTFIX — SVG arrows and messenger rendering
   ============================================================ */
.service-card__more svg,
.service-detail-card__link svg,
.news-card__more svg {
  width: 17px;
  height: 17px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex: 0 0 auto;
}

/* Defensive sizing so inline SVGs never fall back to browser default 300x150. */
.messenger-btn svg {
  max-width: none;
}


/* ============================================================
   V15.2 — explicit back button on service detail pages
   ============================================================ */
body.internal-page .service-back-btn {
  background: rgba(255,255,255,.07);
  border: 1px solid rgba(255,255,255,.28);
  color: var(--on-dark);
  box-shadow: none;
}
body.internal-page .service-back-btn:hover,
body.internal-page .service-back-btn:focus-visible {
  background: rgba(255,255,255,.14);
  border-color: var(--olive-200);
  color: var(--olive-100);
  transform: translateY(-1px);
}
body.internal-page .service-back-btn:focus-visible {
  outline: 3px solid rgba(230,219,158,.7);
  outline-offset: 3px;
}
@media (max-width: 600px) {
  body.internal-page .page-hero__actions .service-back-btn {
    width: 100%;
  }
}


/* ============================================================
   V15.4 — contact block moved into the left hero column
   ============================================================ */
.hero__copy {
  position: relative;
  z-index: 3;
}

.hero__copy .hero__card {
  margin-top: 28px;
  max-width: 560px;
  padding: 22px 24px;
  background: rgba(255,255,255,.88);
  -webkit-backdrop-filter: blur(10px) saturate(125%);
  backdrop-filter: blur(10px) saturate(125%);
  box-shadow: 0 12px 30px rgba(10,44,51,.08);
}

.hero__copy .hero__card-title {
  margin-bottom: 7px;
}

.hero__card-note {
  margin: 0 0 15px;
  color: var(--ink-3);
  font-size: .88rem;
  line-height: 1.5;
}

.hero__copy .hero__card-contacts {
  grid-template-columns: repeat(2, minmax(0, max-content));
  column-gap: 22px;
  row-gap: 7px;
  margin-bottom: 15px;
}

.hero__copy .hero__card-contacts li:last-child {
  grid-column: 1 / -1;
}

.hero__copy .hero__card-contacts a {
  font-size: .96rem;
}

.hero__copy .hero__messengers {
  margin-top: 13px;
  padding-top: 13px;
}

.hero__copy .hero__messengers > p {
  margin-bottom: 8px;
}

@media (min-width: 1100px) {
  .hero__media {
    width: 56%;
  }

  .hero__inner {
    display: block;
    min-height: 700px;
    padding-block: 72px 82px;
  }

  .hero__copy {
    width: 43%;
    max-width: 560px;
  }

  .hero__lede {
    max-width: 49ch;
  }

  .hero__copy .hero__card {
    width: 100%;
  }
}

@media (min-width: 1320px) {
  .hero__inner {
    min-height: 720px;
  }
  .hero__copy {
    width: 42%;
  }
}

@media (max-width: 699px) {
  .hero__copy .hero__card-contacts {
    grid-template-columns: 1fr;
  }
  .hero__copy .hero__card-contacts li:last-child {
    grid-column: auto;
  }
}

@media (max-width: 520px) {
  .hero__copy .hero__card {
    padding: 20px 18px;
  }
}
