/* ==========================================================================
   Lettonia Digital Systems — единственная таблица стилей сайта.
   Перенос с WordPress (Phlox Pro + Elementor) в чистую статику: та же
   палитра, типографика и состав секций, но без рантайма конструктора.

   Содержание:
     1. Токены и сброс
     2. Типографика и утилиты
     3. Кнопки
     4. Шапка и меню
     5. Секции-обёртки
     6. Главная: герой, услуги, работы, счётчики
     7. Карточки тарифов
     8. Портфолио
     9. Care-планы
    10. Контакты и формы
    11. Юридические страницы
    12. Подвал
    13. Появление при скролле
    14. Адаптив
   ========================================================================== */

/* ------------------------------------------------------ 1. Токены и сброс */
:root {
  --yellow: #f0ff00;
  --yellow-soft: #f7ff66;
  --ink: #101316;          /* фон тёмных секций */
  --ink-2: #1a1e22;        /* карточки на тёмном */
  --text: #444444;
  --text-dark: #111111;
  --muted: #8b8b8b;
  --muted-dark: #9aa0a6;   /* вторичный текст на тёмном */
  --line: #e6e6e6;
  --line-dark: rgba(255, 255, 255, 0.14);
  --white: #ffffff;

  --font-head: 'Raleway', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-body: 'Nunito Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;

  --wrap: 1200px;
  --pad: clamp(20px, 4vw, 40px);
  --sec-y: clamp(64px, 8vw, 120px);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --t: 0.28s;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.75;
  color: var(--text);
  background: var(--white);
  overflow-x: hidden;
}

img, svg, video { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; }
ul, ol { margin: 0; padding: 0; list-style: none; }

/* --------------------------------------------- 2. Типографика и утилиты */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-head);
  font-weight: 800;
  line-height: 1.16;
  letter-spacing: -0.01em;
  color: var(--text-dark);
  margin: 0 0 0.5em;
}
h1 { font-size: clamp(2.2rem, 4.6vw, 3.4rem); }
h2 { font-size: clamp(1.8rem, 3.4vw, 2.7rem); }
h3 { font-size: clamp(1.35rem, 2.2vw, 1.85rem); }
h4 { font-size: clamp(1.1rem, 1.5vw, 1.25rem); font-weight: 700; }
h5 { font-size: 1rem; font-weight: 700; }
p { margin: 0 0 1.1em; }
p:last-child { margin-bottom: 0; }

.wrap { width: 100%; max-width: var(--wrap); margin-inline: auto; padding-inline: var(--pad); }
.wrap--narrow { max-width: 880px; }

.eyebrow {
  font-family: var(--font-head);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--muted);
  display: inline-block;
  margin-bottom: 14px;
}
.eyebrow--light { color: var(--yellow); }

/* Жёлтая подсветка под словом — как мазок кистью в оригинале, но рисуем
   градиентом: у исходного SVG вес 1.3 МБ при той же роли. */
.mark {
  position: relative;
  display: inline;
  background-image: linear-gradient(var(--yellow), var(--yellow));
  background-repeat: no-repeat;
  background-position: 0 88%;
  background-size: 100% 0.32em;
  padding-inline: 0.04em;
}
.mark--thick { background-size: 100% 0.5em; background-position: 0 80%; }

.lead { font-size: clamp(1rem, 1.3vw, 1.08rem); color: var(--text); }
.muted { color: var(--muted); }
.center { text-align: center; }
.sec-head { max-width: 640px; margin-bottom: clamp(32px, 4vw, 56px); }
.sec-head.center { margin-inline: auto; text-align: center; }
.sec-head p { color: var(--muted); }

/* ------------------------------------------------------------ 3. Кнопки */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-family: var(--font-head);
  font-size: 12.5px;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  padding: 16px 28px;
  border: 2px solid var(--text-dark);
  background: transparent;
  color: var(--text-dark);
  cursor: pointer;
  transition: background var(--t) var(--ease), color var(--t) var(--ease),
              border-color var(--t) var(--ease), transform var(--t) var(--ease);
}
.btn::after {
  content: "";
  width: 26px;
  height: 2px;
  background: currentColor;
  transition: width var(--t) var(--ease);
}
.btn:hover { background: var(--yellow); border-color: var(--yellow); color: var(--text-dark); }
.btn:hover::after { width: 34px; }

.btn--solid { background: var(--yellow); border-color: var(--yellow); }
.btn--solid:hover { background: var(--text-dark); border-color: var(--text-dark); color: var(--white); }

.btn--light { border-color: var(--white); color: var(--white); }
.btn--light:hover { background: var(--yellow); border-color: var(--yellow); color: var(--text-dark); }

.btn--sm { padding: 12px 20px; font-size: 11.5px; }
.btn--plain::after { display: none; }

/* Текстовая ссылка со стрелкой-линией */
.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-family: var(--font-head);
  font-size: 12.5px;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-dark);
}
.link-arrow::after { content: ""; width: 34px; height: 2px; background: currentColor; transition: width var(--t) var(--ease); }
.link-arrow:hover::after { width: 48px; }
.link-arrow--light { color: var(--white); }

/* ------------------------------------------------- 4. Шапка и меню */
.nav {
  position: sticky;
  top: 0;
  z-index: 60;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid transparent;
  transition: border-color var(--t), box-shadow var(--t);
}
.nav.is-stuck { border-bottom-color: var(--line); box-shadow: 0 6px 24px rgba(0, 0, 0, 0.05); }
.nav__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  min-height: 84px;
}
.nav__logo img { width: 108px; }
.nav__links { display: flex; align-items: center; gap: clamp(18px, 2.4vw, 34px); }
.nav__link {
  position: relative;
  font-family: var(--font-head);
  font-size: 14.5px;
  font-weight: 700;
  color: var(--muted);
  padding: 6px 0;
  transition: color var(--t);
}
.nav__link:hover { color: var(--text-dark); }
.nav__link.is-active { color: var(--text-dark); }
.nav__link.is-active::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 3px;
  background: var(--yellow);
}
.nav__cta { display: flex; align-items: center; gap: 14px; }

.nav__burger {
  display: none;
  width: 44px; height: 44px;
  border: 2px solid var(--text-dark);
  background: transparent;
  cursor: pointer;
  padding: 0;
  place-items: center;
}
.nav__burger span {
  display: block;
  width: 20px; height: 2px;
  background: var(--text-dark);
  transition: transform var(--t) var(--ease), opacity var(--t);
}
.nav__burger span + span { margin-top: 5px; }
.nav.is-open .nav__burger span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav.is-open .nav__burger span:nth-child(2) { opacity: 0; }
.nav.is-open .nav__burger span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.drawer {
  display: none;
  flex-direction: column;
  gap: 2px;
  padding: 8px 0 24px;
  border-top: 1px solid var(--line);
}
.drawer a {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 17px;
  color: var(--text-dark);
  padding: 13px 0;
  border-bottom: 1px solid var(--line);
}
.drawer .btn { margin-top: 18px; justify-content: center; }

/* -------------------------------------------------- 5. Секции-обёртки */
.sec { position: relative; padding-block: var(--sec-y); }
.sec--tight { padding-block: clamp(44px, 5vw, 72px); }
.sec--dark { background: var(--ink); color: #d4d7da; }
.sec--dark h1, .sec--dark h2, .sec--dark h3, .sec--dark h4, .sec--dark h5 { color: var(--white); }
.sec--dark .sec-head p, .sec--dark .muted { color: var(--muted-dark); }
.sec--edge { border-top: 1px solid var(--line); }

/* Точечный декор, как в оригинале */
.dots {
  position: absolute;
  width: 180px;
  opacity: 0.5;
  pointer-events: none;
  user-select: none;
}
.dots--tr { top: 8%; right: 2%; }
.dots--bl { bottom: 8%; left: 2%; }

/* --------------------------------- 6. Главная: герой, услуги, работы */
.hero { position: relative; padding-block: clamp(48px, 7vw, 104px) clamp(56px, 8vw, 120px); overflow: hidden; }
.hero__grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);
  gap: clamp(28px, 5vw, 64px);
  align-items: center;
}
.hero h1 { margin-bottom: 24px; }
.hero p { max-width: 46ch; color: var(--muted); margin-bottom: 30px; }
.hero__media { position: relative; }
.hero__media img { width: 100%; }
.hero__media::before {
  content: "";
  position: absolute;
  left: -22px; bottom: -22px;
  width: 62%; height: 58%;
  background: var(--yellow);
  z-index: -1;
}

/* Блок «текст + две фотографии внахлёст» */
.stack { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(28px, 5vw, 64px); align-items: center; }
.stack__media { position: relative; padding: 0 0 64px 0; }
.stack__media img:first-child { width: 78%; }
.stack__media img:last-child {
  position: absolute;
  right: 0; bottom: 0;
  width: 52%;
  border: 10px solid var(--white);
}
.stack__media::before {
  content: "";
  position: absolute;
  left: -28px; top: 40px;
  width: 46%; height: 70%;
  background: var(--yellow);
  z-index: -1;
}

/* Три услуги плиткой */
.svc-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2px; }
.svc-tile {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-height: 230px;
  padding: 30px;
  background: var(--ink-2);
  color: var(--white);
  overflow: hidden;
  transition: background var(--t) var(--ease), transform var(--t) var(--ease);
}
.svc-tile:nth-child(even) { background: var(--yellow); color: var(--text-dark); }
.svc-tile__num {
  font-family: var(--font-head);
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.22em;
  opacity: 0.6;
  margin-bottom: auto;
}
.svc-tile h3 { color: inherit; margin-bottom: 6px; font-size: clamp(1.15rem, 1.7vw, 1.4rem); }
.svc-tile p { font-size: 14px; opacity: 0.75; margin: 0; }
.svc-tile:hover { transform: translateY(-4px); }
.svc-tile:hover:nth-child(odd) { background: #232a30; }
.svc-tile:hover:nth-child(even) { background: var(--yellow-soft); }

/* Сетка работ — шахматка жёлтый/чёрный, как в оригинале */
.work-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 2px; }
.work-card {
  position: relative;
  display: block;
  padding: clamp(26px, 3vw, 46px);
  background: var(--ink);
  overflow: hidden;
}
.work-grid .work-card:nth-child(2), .work-grid .work-card:nth-child(3) { background: var(--yellow); }
.work-card__img { overflow: hidden; }
.work-card__img img { width: 100%; transition: transform 0.5s var(--ease); }
.work-card:hover .work-card__img img { transform: scale(1.05); }
.work-card__meta { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; margin-top: 22px; }
.work-card h3 { font-size: clamp(1.05rem, 1.5vw, 1.3rem); color: var(--white); margin: 0; }
.work-card__tag { font-family: var(--font-head); font-size: 11px; font-weight: 800; letter-spacing: 0.2em; text-transform: uppercase; color: var(--muted-dark); }
.work-grid .work-card:nth-child(2) h3, .work-grid .work-card:nth-child(3) h3 { color: var(--text-dark); }
.work-grid .work-card:nth-child(2) .work-card__tag, .work-grid .work-card:nth-child(3) .work-card__tag { color: rgba(0, 0, 0, 0.55); }

/* Счётчики */
.stats { display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--line-dark); border-left: 1px solid var(--line-dark); }
.stat { padding: clamp(26px, 3.4vw, 46px) 20px; text-align: center; border-right: 1px solid var(--line-dark); border-bottom: 1px solid var(--line-dark); }
.stat__num { font-family: var(--font-head); font-size: clamp(2rem, 3.6vw, 2.9rem); font-weight: 800; color: var(--white); line-height: 1; }
.stat__num span { color: var(--yellow); }
.stat__label { font-size: 13px; letter-spacing: 0.08em; color: var(--muted-dark); margin-top: 10px; }

/* Ценности: подпись-заголовок + слово-акцент */
.value-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 2px; }
.value {
  padding: clamp(24px, 3vw, 38px);
  background: #fafafa;
  border: 1px solid var(--line);
  transition: background var(--t), transform var(--t) var(--ease);
}
.value:hover { background: var(--yellow); transform: translateY(-4px); }
.value__key { font-family: var(--font-head); font-size: 11.5px; font-weight: 800; letter-spacing: 0.24em; color: var(--muted); margin-bottom: 12px; }
.value:hover .value__key { color: rgba(0, 0, 0, 0.6); }
.value h4 { margin: 0; }

/* Полоса призыва «Have a project in mind?» */
.cta-band { background: var(--yellow); }
.cta-band .wrap { display: flex; align-items: center; justify-content: space-between; gap: 24px; padding-block: clamp(36px, 4.6vw, 64px); }
.cta-band h2 { margin: 0; font-size: clamp(1.6rem, 3vw, 2.4rem); }

/* ------------------------------------------------- 7. Карточки тарифов */
.price-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.price-card {
  display: flex;
  flex-direction: column;
  padding: clamp(26px, 3vw, 38px);
  background: var(--ink);
  color: #cfd3d6;
  text-align: center;
}
.price-card__ico { width: 46px; height: 46px; margin: 0 auto 18px; color: var(--yellow); }
.price-card__ico svg { width: 100%; height: 100%; }
.price-card h3 {
  font-size: 15px;
  font-weight: 800;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--white);
  margin-bottom: 6px;
}
.price-card__sum { font-family: var(--font-head); font-size: clamp(1.6rem, 2.4vw, 2rem); font-weight: 800; color: var(--yellow); margin-bottom: 18px; }
.price-card ul { display: flex; flex-direction: column; gap: 9px; margin-bottom: 26px; text-align: left; }
.price-card li {
  position: relative;
  padding-left: 22px;
  font-size: 12.5px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted-dark);
}
.price-card li::before {
  content: "";
  position: absolute;
  left: 0; top: 0.62em;
  width: 10px; height: 2px;
  background: var(--yellow);
}
.price-card .btn { margin-top: auto; align-self: center; }

/* Блок услуги: текст слева, фото справа (и наоборот) */
.service-block { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(28px, 5vw, 64px); align-items: center; }
.service-block--flip .service-block__media { order: -1; }
.service-block__media { position: relative; }
.service-block__media::before {
  content: "";
  position: absolute;
  right: -20px; top: -20px;
  width: 55%; height: 55%;
  background: var(--yellow);
  z-index: -1;
}
.service-block--flip .service-block__media::before { right: auto; left: -20px; }
.service-block h2 { margin-bottom: 18px; }
.service-block .eyebrow { margin-bottom: 10px; }

/* ------------------------------------------------------- 8. Портфолио */
.filter { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin-bottom: clamp(28px, 3.4vw, 44px); }
.filter__btn {
  font-family: var(--font-head);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  padding: 11px 20px;
  border: 2px solid var(--line);
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  transition: all var(--t) var(--ease);
}
.filter__btn:hover { border-color: var(--text-dark); color: var(--text-dark); }
.filter__btn.is-on { background: var(--yellow); border-color: var(--yellow); color: var(--text-dark); }
.work-card.is-hidden { display: none; }

.work-hero { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); gap: clamp(28px, 5vw, 56px); align-items: center; }
.work-facts { display: grid; gap: 2px; margin-top: 28px; }
.work-facts div { display: flex; justify-content: space-between; gap: 16px; padding: 13px 0; border-bottom: 1px solid var(--line); font-size: 14.5px; }
.work-facts dt, .work-facts .k { font-family: var(--font-head); font-weight: 800; letter-spacing: 0.12em; text-transform: uppercase; font-size: 11.5px; color: var(--muted); }
.work-nav { display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap; padding-top: 28px; border-top: 1px solid var(--line); }

/* ----------------------------------------------------- 9. Care-планы */
.plans-switch { display: flex; flex-direction: column; align-items: center; gap: 12px; margin-bottom: clamp(28px, 3.4vw, 44px); }
.plans-switch[hidden] { display: none; }
.plans-switch__label { font-family: var(--font-head); font-size: 11.5px; font-weight: 800; letter-spacing: 0.24em; text-transform: uppercase; color: var(--muted); }
.plans-switch__row { display: inline-flex; gap: 2px; border: 2px solid var(--text-dark); }
.plans-switch__btn {
  display: inline-flex; align-items: center; gap: 9px;
  font-family: var(--font-head); font-size: 12.5px; font-weight: 800;
  letter-spacing: 0.14em; text-transform: uppercase;
  padding: 13px 22px; border: 0; background: transparent; color: var(--text-dark); cursor: pointer;
  transition: background var(--t), color var(--t);
}
.plans-switch__btn:hover { background: #f4f4f4; }
.plans-switch__btn.is-on { background: var(--text-dark); color: var(--white); }
.plans-switch__off { font-size: 10.5px; letter-spacing: 0.08em; padding: 3px 7px; background: var(--yellow); color: var(--text-dark); }
.plans-switch__btn.is-on .plans-switch__off { background: var(--yellow); }

.plan-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; align-items: start; }
.plan { display: flex; flex-direction: column; padding: clamp(26px, 3vw, 38px); border: 2px solid var(--line); background: var(--white); transition: border-color var(--t), transform var(--t) var(--ease); }
.plan:hover { border-color: var(--text-dark); transform: translateY(-4px); }
.plan--featured { background: var(--ink); border-color: var(--ink); color: #cfd3d6; }
.plan--featured h3 { color: var(--white); }
.plan__head { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin-bottom: 18px; }
.plan__tag { font-family: var(--font-head); font-size: 10.5px; font-weight: 800; letter-spacing: 0.2em; text-transform: uppercase; padding: 5px 10px; background: var(--yellow); color: var(--text-dark); }
.plan h3 { margin-bottom: 10px; }
.plan > p { font-size: 15px; color: var(--muted); }
.plan--featured > p { color: var(--muted-dark); }
.plan ul { display: flex; flex-direction: column; gap: 10px; margin: 18px 0 26px; }
.plan li { position: relative; padding-left: 24px; font-size: 14.5px; }
.plan li::before { content: ""; position: absolute; left: 0; top: 0.62em; width: 12px; height: 2px; background: var(--yellow); }
.plan__foot { margin-top: auto; }
.plan__price { display: none; }
.plan__price.is-on { display: block; }
.plan__amt { font-family: var(--font-head); font-size: clamp(1.9rem, 2.8vw, 2.3rem); font-weight: 800; color: var(--text-dark); line-height: 1; }
.plan--featured .plan__amt { color: var(--yellow); }
.plan__per { display: block; font-size: 11.5px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); margin-top: 6px; }
.plan__save { display: block; margin: 10px 0 18px; font-family: var(--font-head); font-size: 12.5px; font-weight: 800; color: #1a8f3c; }
.plan--featured .plan__save { color: var(--yellow); }
.plan__save.is-blank { color: transparent; }
.plan .btn { width: 100%; justify-content: center; }
/* На тёмной карточке обычная кнопка — жёлтая обводка; сплошную не трогаем,
   иначе жёлтый текст ляжет на жёлтый фон. */
.plan--featured .btn:not(.btn--solid) { border-color: var(--yellow); color: var(--yellow); }
.plan--featured .btn:not(.btn--solid):hover { background: var(--yellow); color: var(--text-dark); }
.plans-note { max-width: 760px; margin: clamp(28px, 3.4vw, 40px) auto 0; font-size: 14.5px; color: var(--muted); text-align: center; }
.plans-note a { color: var(--text-dark); border-bottom: 2px solid var(--yellow); }

/* Цена и кнопка на одной линии у всех трёх карточек: строки задаёт внешний грид,
   карточка наследует их через subgrid, поэтому высота каждой строки — максимум по
   карточкам при любой ширине. min-height не годится: высота описаний и списков
   меняется с шириной окна. Без поддержки subgrid объявление игнорируется и
   карточка остаётся обычной колонкой. */
@media (min-width: 621px) {
  .plan-grid { grid-template-rows: repeat(4, auto); }
  .plan { display: grid; grid-row: span 4; grid-template-rows: subgrid; align-content: start; }
  .plan ul { margin-bottom: 0; }
  .plan__foot { margin-top: 26px; }
}

/* ------------------------------------------------ 10. Контакты и формы */
.contact-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); gap: clamp(28px, 5vw, 64px); align-items: start; }
.contact-list { display: grid; gap: 2px; }
.contact-list li { padding: 20px 0; border-bottom: 1px solid var(--line); }
.contact-list h5 { font-family: var(--font-head); font-size: 11.5px; font-weight: 800; letter-spacing: 0.22em; text-transform: uppercase; color: var(--muted); margin-bottom: 6px; }
.contact-list p, .contact-list a { font-size: 17px; color: var(--text-dark); }
.contact-list a:hover { border-bottom: 2px solid var(--yellow); }

.form { display: grid; gap: 18px; }
.form__row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.field { display: grid; gap: 8px; }
.field label { font-family: var(--font-head); font-size: 11.5px; font-weight: 800; letter-spacing: 0.18em; text-transform: uppercase; color: var(--muted); }
.field input, .field select, .field textarea {
  font-family: var(--font-body);
  font-size: 15px;
  color: var(--text-dark);
  padding: 14px 16px;
  border: 2px solid var(--line);
  background: var(--white);
  transition: border-color var(--t);
}
.field textarea { min-height: 150px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--text-dark); }
.form__note { font-size: 13px; color: var(--muted); }
.form__ok { display: none; padding: 26px; border: 2px solid var(--yellow); background: #fffde3; }
.form__ok.is-on { display: block; }

/* ------------------------------------------- 11. Юридические страницы */
.legal { max-width: 820px; }
.legal h2 { font-size: clamp(1.3rem, 2vw, 1.6rem); margin-top: 2em; }
.legal h2:first-of-type { margin-top: 0; }
.legal h3 { font-size: 1.15rem; margin-top: 1.6em; }
.legal ul { list-style: disc; padding-left: 22px; margin-bottom: 1.1em; }
.legal ul li { margin-bottom: 8px; }
.legal a { color: var(--text-dark); border-bottom: 2px solid var(--yellow); }
.legal__meta { font-size: 13.5px; color: var(--muted); padding-bottom: 18px; border-bottom: 1px solid var(--line); margin-bottom: 32px; }
.legal__toc { padding: 24px; background: #fafafa; border: 1px solid var(--line); margin-bottom: 40px; }
.legal__toc h4 { margin-bottom: 12px; }
.legal__toc ol { list-style: decimal; padding-left: 20px; display: grid; gap: 6px; }
.legal__toc a { border-bottom: 0; color: var(--text); }
.legal__toc a:hover { color: var(--text-dark); border-bottom: 2px solid var(--yellow); }

/* ------------------------------------------------------- 12. Подвал */
.footer { background: var(--ink); color: var(--muted-dark); padding-block: clamp(48px, 6vw, 80px) 0; }
.footer__grid { display: grid; grid-template-columns: 1.4fr repeat(3, 1fr); gap: clamp(24px, 3vw, 48px); }
.footer h5 { font-family: var(--font-head); font-size: 11.5px; font-weight: 800; letter-spacing: 0.22em; text-transform: uppercase; color: var(--yellow); margin-bottom: 16px; }
.footer a { color: var(--muted-dark); transition: color var(--t); }
.footer a:hover { color: var(--white); }
.footer__col ul { display: grid; gap: 10px; font-size: 14.5px; }
.footer__logo img { width: 120px; margin-bottom: 18px; }
.footer__about { font-size: 14.5px; max-width: 34ch; }
.footer__bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  margin-top: clamp(36px, 4vw, 56px);
  padding-block: 22px;
  border-top: 1px solid var(--line-dark);
  font-size: 13.5px;
}
.footer__legal-links { display: flex; gap: 18px; flex-wrap: wrap; }

/* --------------------------------------------- 13. Появление при скролле */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity 0.6s var(--ease), transform 0.6s var(--ease); transition-delay: var(--d, 0s); }
.reveal.is-in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
}

/* --------------------------------------------------------- 14. Адаптив */
@media (max-width: 1024px) {
  .svc-grid, .price-grid, .plan-grid, .value-grid { grid-template-columns: repeat(2, 1fr); }
  .footer__grid { grid-template-columns: 1fr 1fr; }
  .stats { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 860px) {
  .nav__links, .nav__cta .btn { display: none; }
  .nav__burger { display: grid; }
  .nav.is-open .drawer { display: flex; }
  .hero__grid, .stack, .service-block, .contact-grid, .work-hero { grid-template-columns: 1fr; }
  .service-block--flip .service-block__media { order: 0; }
  .stack__media { padding-bottom: 48px; }
  .work-grid { grid-template-columns: 1fr; }
  .cta-band .wrap { flex-direction: column; align-items: flex-start; }
}

@media (max-width: 620px) {
  .svc-grid, .price-grid, .plan-grid, .value-grid, .form__row, .footer__grid { grid-template-columns: 1fr; }
  .stats { grid-template-columns: 1fr; }
  .plans-switch__row { width: 100%; flex-direction: column; }
  .plans-switch__btn { justify-content: center; }
  .btn { width: 100%; justify-content: center; }
  .hero__media::before, .stack__media::before, .service-block__media::before { display: none; }
}

/* Care plans: visible entry points and clear maintenance offers. */
.nav__link--plans { color: var(--text-dark); white-space: nowrap; background: linear-gradient(var(--yellow), var(--yellow)) left bottom / 100% 3px no-repeat; }
.hero__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 24px; }
.hero__care-link { display: flex; flex-direction: column; gap: 3px; color: var(--text-dark); }
.hero__care-link strong { font-family: var(--font-head); font-size: 16px; }
.hero__care-link strong span { display: inline-block; margin-left: 8px; }
.hero__care-link > span { font-size: 14px; color: #62676a; }
.hero__care-link:hover strong { text-decoration: underline; text-decoration-color: var(--yellow); text-decoration-thickness: 3px; text-underline-offset: 5px; }
.care-section { background: #f7f8f2; border-block: 1px solid var(--line); scroll-margin-top: 100px; }
.care-section .sec-head { margin-bottom: 24px; }
.care-section .sec-head p { color: #5a6165; font-size: 17px; }
.care-section .eyebrow { color: #5a6165; }
.care-benefits { display: flex; justify-content: center; flex-wrap: wrap; gap: 12px 28px; margin: 0 0 36px; font-size: 14px; font-weight: 700; color: var(--text-dark); }
.care-benefits li { display: inline-flex; align-items: center; gap: 9px; }
.care-benefits li::before { content: "✓"; display: grid; place-items: center; width: 22px; height: 22px; background: var(--yellow); font-size: 13px; }
.care-section .plan__head { flex-direction: column-reverse; align-items: flex-start; gap: 14px; }
.care-section .plan__head h3 { margin-bottom: 0; }
.care-section .plan > p, .care-section .plans-note { color: #62676a; }
.care-section .plan--featured > p { color: #bdc3c7; }
.care-section .plans-switch__label { color: #62676a; }
.care-section .plans-switch__row { background: var(--white); }
.care-section .plans-note strong { color: var(--text-dark); }
.hero__care-link:focus-visible, .nav__link--plans:focus-visible, .care-section a:focus-visible, .plans-switch__btn:focus-visible { outline: 3px solid #406321; outline-offset: 5px; }
@media (max-width: 1100px) {
  .nav__links, .nav__cta .btn { display: none; }
  .nav__burger { display: grid; }
  .nav.is-open .drawer { display: flex; }
}
@media (max-width: 620px) {
  .hero__care-link { width: 100%; padding-block: 4px; }
  .care-benefits { flex-direction: column; align-items: flex-start; gap: 12px; }
  .care-section .plan__head { flex-direction: row; align-items: center; flex-wrap: wrap; }
}
