/* ============ ТОО «КТ Қарлығаш» — дизайн-система ============ */
:root {
  --brand: #007a40;
  --brand-dark: #005a30;
  --brand-soft: #f1f7f4;
  --accent: #b4975a;
  --accent-soft: #f1ebe0;
  --ink: #14251d;
  --muted: #64756c;
  --line: #e6e2d6;
  --paper: #ffffff;
  --surface: #ffffff;
  --surface-2: #fbf9f1;
  --cream: #fcfaf2;
  --hero-veil: linear-gradient(105deg, rgba(6, 34, 27, .88) 0%, rgba(8, 45, 36, .66) 45%, rgba(10, 58, 46, .26) 100%);
  --radius: 16px;
  --radius-sm: 10px;
  --shadow: 0 18px 40px rgba(20, 37, 29, .08);
  --shadow-lg: 0 30px 70px rgba(20, 37, 29, .16);
  --wrap: 1200px;
}

[data-theme="dark"] {
  --brand: #45c088;
  --brand-dark: #2f9a6a;
  --brand-soft: #12241e;
  --accent: #e2ab55;
  --accent-soft: #2a2114;
  --ink: #e9efea;
  --muted: #9aa8a1;
  --line: #23312b;
  --paper: #0c1210;
  --surface: #121a16;
  --surface-2: #101815;
  --cream: #101815;
  --hero-veil: linear-gradient(105deg, rgba(3, 12, 9, .95) 0%, rgba(5, 20, 16, .9) 50%, rgba(7, 28, 22, .62) 100%);
  --shadow: 0 18px 40px rgba(0, 0, 0, .45);
  --shadow-lg: 0 30px 70px rgba(0, 0, 0, .55);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: "Inter", "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;
  color: var(--ink);
  background: var(--paper);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  transition: background-color .3s ease, color .3s ease;
}
img { max-width: 100%; display: block; }
a { color: var(--brand); text-decoration: none; }
a:hover { color: var(--brand-dark); }
h1, h2, h3, h4 { margin: 0 0 .5em; line-height: 1.15; letter-spacing: -.02em; font-weight: 650; }
p { margin: 0 0 1em; }
ul, ol { margin: 0 0 1em; padding-left: 1.2em; }
.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 24px; }
.skip { position: absolute; left: -9999px; }
.skip:focus { left: 12px; top: 12px; background: var(--surface); padding: 10px 14px; border-radius: 8px; z-index: 100; }

/* ============ Кнопки ============ */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 13px 22px; border-radius: 999px; border: 1px solid transparent;
  font-size: 15px; font-weight: 600; cursor: pointer; white-space: nowrap;
  transition: transform .18s ease, background-color .18s ease, color .18s ease, border-color .18s ease, box-shadow .18s ease;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--brand); color: #fff; box-shadow: 0 10px 24px rgba(0, 122, 64, .22); }
.btn-primary:hover { background: var(--brand-dark); color: #fff; box-shadow: 0 14px 30px rgba(0, 122, 64, .3); }
[data-theme="dark"] .btn-primary { color: #06110d; }
.btn-ghost { border-color: var(--line); color: var(--ink); background: var(--surface); }
.btn-ghost:hover { border-color: var(--brand); color: var(--brand); }
.btn-light { background: #fff; color: #005a30; }
.btn-light:hover { background: #f1f7f4; color: #083f31; }
.btn-outline-light { border-color: rgba(255,255,255,.45); color: #fff; background: rgba(255,255,255,.04); }
.btn-outline-light:hover { border-color: #fff; color: #fff; background: rgba(255,255,255,.12); }
.btn-sm { padding: 9px 16px; font-size: 14px; }

/* ============ Шапка ============ */
.site-header {
  position: sticky; top: 0; z-index: 50; background: var(--paper);
  border-bottom: 1px solid var(--line); transition: box-shadow .2s ease, background-color .3s ease;
}
.header-inner { display: flex; align-items: center; gap: 22px; min-height: 82px; }
.brand { display: flex; align-items: center; gap: 12px; color: var(--ink); flex-shrink: 0; }
.brand-mark {
  width: 44px; height: 44px; border-radius: 13px; background: var(--brand);
  display: grid; place-items: center; color: #fff; font-weight: 700; font-size: 17px; letter-spacing: .02em;
  box-shadow: 0 8px 18px rgba(0, 122, 64, .25);
}
[data-theme="dark"] .brand-mark { color: #06110d; }
.brand-text { display: flex; flex-direction: column; line-height: 1.15; }
.brand-text strong { font-size: 17px; font-weight: 700; letter-spacing: .01em; }
.brand-text small { color: var(--muted); font-size: 11.5px; }

.main-nav { display: flex; align-items: center; gap: 2px; margin-left: auto; }
.main-nav > a, .nav-drop > button {
  display: inline-flex; align-items: center; gap: 6px; padding: 10px; background: none; border: 0;
  font: inherit; font-size: 14.5px; color: var(--ink); cursor: pointer; border-radius: 10px;
  white-space: nowrap; transition: background-color .16s ease, color .16s ease;
}
.main-nav > a:hover, .nav-drop > button:hover { background: var(--brand-soft); color: var(--brand); }
.nav-drop { position: relative; }
.nav-drop > button::after {
  content: ""; width: 6px; height: 6px; border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor; transform: rotate(45deg) translateY(-2px);
  transition: transform .2s ease;
}
.nav-drop:hover > button::after { transform: rotate(225deg) translateY(-1px); }
.drop-panel {
  position: absolute; top: calc(100% + 10px); left: 0; min-width: 300px; background: var(--surface);
  border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow-lg);
  padding: 8px; display: none;
}
.nav-drop:hover .drop-panel, .nav-drop:focus-within .drop-panel { display: block; animation: dropIn .18s ease both; }
@keyframes dropIn { from { opacity: 0; transform: translateY(-6px); } to { opacity: 1; transform: none; } }
.drop-panel a { display: block; padding: 9px 12px; border-radius: 9px; font-size: 14.5px; color: var(--ink); }
.drop-panel a:hover { background: var(--brand-soft); color: var(--brand); }

.header-actions { display: flex; align-items: center; gap: 10px; }
.header-phone { display: flex; flex-direction: column; line-height: 1.15; text-align: right; white-space: nowrap; }
.header-phone span { font-size: 11px; color: var(--muted); }
.header-phone strong { font-size: 15.5px; color: var(--ink); }

.theme-toggle {
  width: 40px; height: 40px; border-radius: 12px; border: 1px solid var(--line); background: var(--surface);
  color: var(--ink); display: grid; place-items: center; cursor: pointer;
  transition: border-color .18s ease, transform .18s ease, background-color .2s ease;
}
.theme-toggle:hover { border-color: var(--brand); transform: translateY(-1px); }
.theme-toggle svg { width: 18px; height: 18px; }
.theme-toggle .icon-moon { display: none; }
[data-theme="dark"] .theme-toggle .icon-moon { display: block; }
[data-theme="dark"] .theme-toggle .icon-sun { display: none; }

.burger { display: none; background: none; border: 1px solid var(--line); border-radius: 10px; width: 42px; height: 42px; cursor: pointer; }
.burger span, .burger::before, .burger::after { content: ""; display: block; width: 18px; height: 2px; background: var(--ink); margin: 4px auto; transition: transform .2s ease; }

/* ============ Первый экран ============ */
.hero { position: relative; overflow: hidden; color: #fff; background: var(--brand-dark); }
.hero-media { position: absolute; inset: 0; }
.hero-media img { width: 100%; height: 100%; object-fit: cover; animation: kenburns 26s ease-in-out infinite alternate; }
@keyframes kenburns { from { transform: scale(1.04); } to { transform: scale(1.15) translate3d(-1.5%, -1.5%, 0); } }
.hero-overlay { position: absolute; inset: 0; background: var(--hero-veil); }
.hero-overlay::after {
  content: ""; position: absolute; inset: 0;
  background-image: radial-gradient(rgba(255,255,255,.14) 1px, transparent 1px);
  background-size: 26px 26px; opacity: .16;
}
.hero-inner { position: relative; z-index: 1; padding: 96px 24px 0; }
.hero-kicker {
  display: inline-flex; align-items: center; gap: 10px; padding: 7px 14px;
  border: 1px solid rgba(255,255,255,.28); border-radius: 999px; font-size: 13px;
  color: rgba(255,255,255,.92); margin-bottom: 26px;
}
.hero h1 { font-size: clamp(34px, 5vw, 62px); max-width: 900px; font-weight: 680; text-shadow: 0 2px 30px rgba(0,0,0,.28); }
.hero-accent { color: #f0c987; }
.hero-sub { font-size: clamp(16px, 1.6vw, 19px); color: rgba(255,255,255,.9); max-width: 620px; margin: 18px 0 32px; }
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; }
.hero-note { margin-top: 18px; font-size: 13px; color: rgba(255,255,255,.72); }

.stat-row {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; margin-top: 56px;
  background: rgba(255,255,255,.18); border-top-left-radius: 20px; border-top-right-radius: 20px; overflow: hidden;
}
.stat { background: rgba(9, 38, 30, .4); padding: 26px 24px; transition: background-color .2s ease; }
.stat:hover { background: rgba(9, 38, 30, .58); }
.stat-value { font-size: clamp(22px, 2.4vw, 30px); font-weight: 650; letter-spacing: -.02em; }
.stat-label { font-size: 13.5px; color: rgba(255,255,255,.78); }
.stat-note { font-size: 12px; color: rgba(255,255,255,.6); margin-top: 6px; }

/* ============ Секции ============ */
.section { padding: 88px 0; }
.section--tight { padding: 56px 0; }
.section--cream { background: var(--surface-2); }
.section--soft { background: var(--brand-soft); }
.section--dark { background: var(--brand-dark); color: #fff; }
[data-theme="dark"] .section--dark { background: #07110e; }
.section-head { max-width: 760px; margin-bottom: 44px; }
.kicker {
  display: inline-block; font-size: 12.5px; letter-spacing: .14em; text-transform: uppercase;
  color: var(--brand); font-weight: 700; margin-bottom: 12px;
}
.section--dark .kicker { color: #f0c987; }
.h2 { font-size: clamp(26px, 3vw, 40px); }
.lead { font-size: 17px; color: var(--muted); }
.section--dark .lead { color: rgba(255,255,255,.78); }

/* ============ Анимация появления ============ */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity .7s ease, transform .8s cubic-bezier(.22,.61,.36,1); transition-delay: var(--d, 0ms); }
.reveal.in { opacity: 1; transform: none; }

/* ============ Факты ============ */
.facts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.fact {
  border: 1px solid var(--line); border-radius: var(--radius); padding: 24px;
  background: var(--surface); display: flex; flex-direction: column; gap: 6px;
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.fact:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: var(--brand); }
.fact-value { font-size: clamp(26px, 2.6vw, 38px); font-weight: 680; color: var(--brand); letter-spacing: -.03em; }
.fact-label { font-weight: 600; font-size: 15px; }
.fact-note { font-size: 13.5px; color: var(--muted); }

/* ============ Карточки программ ============ */
.cards-scroll { display: flex; gap: 18px; overflow-x: auto; padding: 4px 4px 18px; scroll-snap-type: x mandatory; scrollbar-width: thin; }
.cards-scroll > * { scroll-snap-align: start; flex: 0 0 340px; }
.card {
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; display: flex; flex-direction: column;
  transition: transform .22s ease, box-shadow .22s ease, border-color .22s ease;
}
.card:hover { box-shadow: var(--shadow-lg); transform: translateY(-4px); border-color: var(--brand); }
.card-media { position: relative; aspect-ratio: 16 / 9; background: var(--brand-soft); overflow: hidden; }
.card-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s cubic-bezier(.2,.7,.2,1); }
.card:hover .card-media img { transform: scale(1.06); }
.card-media::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0,0,0,0) 45%, rgba(6, 22, 18, .42) 100%); }
.card-badge {
  position: absolute; left: 12px; top: 12px; z-index: 1; background: var(--accent); color: #241703;
  font-size: 11.5px; font-weight: 700; padding: 5px 10px; border-radius: 999px; letter-spacing: .02em;
}
.card-body { padding: 20px 20px 22px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.card-cat { font-size: 11.5px; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); font-weight: 700; }
.card h3 { font-size: 20px; margin: 0; }
.card h3 a { color: var(--ink); }
.card h3 a:hover { color: var(--brand); }
.card p { font-size: 14.5px; color: var(--muted); margin: 0; }
.params { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin: 6px 0 14px; }
.param { border-top: 1px solid var(--line); padding-top: 10px; }
.param-label { font-size: 11px; color: var(--muted); text-transform: uppercase; letter-spacing: .08em; }
.param-value { font-size: 17px; font-weight: 650; line-height: 1.25; }
.param-note { font-size: 11.5px; color: var(--muted); }
.card .param-note { display: none; }
.card .param-value { font-size: 15px; }
.card-actions { margin-top: auto; display: flex; flex-direction: column; align-items: stretch; gap: 8px; }
.card-actions .btn { width: 100%; }
.card-actions .link-arrow { font-size: 14px; text-align: center; }
.link-arrow { font-weight: 600; font-size: 14.5px; }
.link-arrow::after { content: " →"; display: inline-block; transition: transform .2s ease; }
.link-arrow:hover::after { transform: translateX(3px); }

/* ============ Таймлайн шагов ============ */
.flow { position: relative; display: grid; grid-template-columns: repeat(var(--cols, 5), 1fr); gap: 16px; padding-top: 6px; }
.flow-line, .flow-progress { position: absolute; top: 24px; left: 0; height: 2px; border-radius: 2px; }
.flow-line { right: 0; background: var(--line); }
.flow-progress { width: 0; background: linear-gradient(90deg, var(--brand), var(--accent)); box-shadow: 0 0 12px rgba(0, 122, 64, .35); transition: width .35s ease; }
.flow-step { position: relative; padding-top: 60px; }
.flow-dot {
  position: absolute; top: 9px; left: 0; width: 32px; height: 32px; border-radius: 50%;
  background: var(--surface); border: 2px solid var(--line); color: var(--muted);
  display: grid; place-items: center; font-size: 13px; font-weight: 700;
  transition: background-color .3s ease, color .3s ease, border-color .3s ease, box-shadow .3s ease, transform .3s ease;
}
.flow-step.in .flow-dot { background: var(--brand); border-color: var(--brand); color: #fff; transform: scale(1.06); box-shadow: 0 0 0 6px rgba(0, 122, 64, .12); }
[data-theme="dark"] .flow-step.in .flow-dot { color: #06110d; }
.flow-step h3 { font-size: 17px; margin: 0 0 6px; }
.flow-step p, .flow-step .step-text { font-size: 14px; color: var(--muted); margin: 0; }
.flow-step .step-text p:last-child { margin-bottom: 0; }
.flow-step .step-text ul { padding-left: 18px; margin: 6px 0 0; }

/* Старая сетка шагов (совместимость) */
.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 18px; }
.step { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; }
.step-num { width: 34px; height: 34px; border-radius: 10px; background: var(--brand-soft); color: var(--brand); display: grid; place-items: center; font-weight: 700; font-size: 15px; margin-bottom: 14px; }
.step h3 { font-size: 17px; margin: 0 0 6px; }
.step p { font-size: 14px; color: var(--muted); margin: 0; }

/* ============ Каналы ============ */
.channels { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 18px; }
.channel {
  border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; background: var(--surface);
  display: flex; flex-direction: column; gap: 8px; transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.channel:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: var(--brand); }
.channel-logo { height: 40px; display: flex; align-items: center; }
.channel h3 { font-size: 17px; margin: 0; }
.channel p { font-size: 14px; color: var(--muted); margin: 0 0 6px; }

/* ============ CTA ============ */
.cta-band {
  background: linear-gradient(120deg, var(--brand-soft), var(--surface-2));
  border: 1px solid var(--line); border-radius: 26px; padding: 52px;
  display: flex; align-items: center; justify-content: space-between; gap: 32px; flex-wrap: wrap;
}
.cta-band h2 { font-size: clamp(24px, 2.6vw, 34px); max-width: 560px; margin: 0; }
.cta-band p { color: var(--muted); margin: 10px 0 0; max-width: 560px; }

/* ============ Цифры доверия ============ */
.trust { display: grid; grid-template-columns: 1.05fr 1fr; gap: 48px; align-items: center; }
.trust-badge {
  width: 104px; height: 104px; border-radius: 26px; border: 1px solid rgba(255,255,255,.28);
  display: grid; place-items: center; font-size: 30px; font-weight: 700; color: #f0c987;
  margin-bottom: 22px; background: rgba(255,255,255,.05);
}
.metrics { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
.metric { border: 1px solid rgba(255,255,255,.16); border-radius: var(--radius); padding: 22px; background: rgba(255,255,255,.04); }
.metric-value { font-size: 26px; font-weight: 680; }
.metric-label { font-size: 13.5px; color: rgba(255,255,255,.72); }

/* ============ Подвал ============ */
.site-footer { background: #072019; color: rgba(255,255,255,.78); padding: 64px 0 28px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 36px; }
.site-footer h4 { color: #fff; font-size: 13px; letter-spacing: .08em; text-transform: uppercase; margin-bottom: 14px; }
.site-footer a { color: rgba(255,255,255,.78); font-size: 14.5px; }
.site-footer a:hover { color: #fff; }
.site-footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 9px; }
.footer-brand { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; }
.footer-brand .brand-mark { background: #fff; color: #005a30; box-shadow: none; }
.footer-brand strong { color: #fff; font-size: 16px; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.12); margin-top: 42px; padding-top: 22px; display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; font-size: 12.5px; color: rgba(255,255,255,.55); }

/* ============ Внутренние страницы ============ */
.page-hero { background: var(--brand-soft); padding: 56px 0 48px; }
.page-hero h1 { font-size: clamp(28px, 4vw, 46px); max-width: 900px; }
.crumbs { font-size: 13px; color: var(--muted); margin-bottom: 16px; }
.crumbs a { color: var(--muted); }
.page-body { padding: 56px 0 88px; }
.prose { max-width: 780px; }
.prose h2 { font-size: clamp(22px, 2.4vw, 30px); margin-top: 42px; }
.prose h3 { font-size: 20px; margin-top: 32px; }
.prose ul li, .prose ol li { margin-bottom: 8px; }
.prose blockquote { border-left: 3px solid var(--accent); margin: 24px 0; padding: 4px 0 4px 18px; color: var(--muted); }
.prose table { width: 100%; border-collapse: collapse; margin: 20px 0; font-size: 15px; }
.prose th, .prose td { border-bottom: 1px solid var(--line); padding: 10px 12px; text-align: left; }
.prose code { background: var(--surface-2); padding: 2px 6px; border-radius: 6px; font-size: 14px; }

.layout-grid { display: grid; grid-template-columns: 2fr 1fr; gap: 44px; align-items: start; }
.aside-card { border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; background: var(--surface); }
.aside-card + .aside-card { margin-top: 16px; }
.aside-card h3 { font-size: 16px; margin-bottom: 10px; }

/* Документы */
.doc-list { display: grid; gap: 10px; }
.doc-item { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px 18px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--surface); }
.doc-item strong { font-weight: 600; }
.doc-item span { color: var(--muted); font-size: 13px; }

/* FAQ */
.faq-nav { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 30px; }
.chip { padding: 8px 14px; border-radius: 999px; border: 1px solid var(--line); font-size: 14px; color: var(--ink); background: var(--surface); transition: background-color .18s ease, border-color .18s ease, color .18s ease; }
.chip:hover, .chip.active { border-color: var(--brand); background: var(--brand-soft); color: var(--brand); }
details.qa { border-bottom: 1px solid var(--line); padding: 6px 0; }
details.qa summary { cursor: pointer; padding: 16px 40px 16px 0; font-weight: 600; list-style: none; position: relative; }
details.qa summary::-webkit-details-marker { display: none; }
details.qa summary::after { content: "+"; position: absolute; right: 6px; top: 14px; font-size: 22px; color: var(--brand); font-weight: 400; }
details.qa[open] summary::after { content: "–"; }
details.qa .qa-body { padding: 0 0 18px; max-width: 860px; opacity: .86; animation: qaIn .25s ease both; }
@keyframes qaIn { from { opacity: 0; transform: translateY(-4px); } to { opacity: .86; transform: none; } }
details.qa .qa-body p:last-child { margin-bottom: 0; }

/* Фильтры каталога */
.filter-bar { display: flex; gap: 18px; flex-wrap: wrap; align-items: flex-end; margin-bottom: 30px; }
.filter-group { display: flex; flex-direction: column; gap: 6px; }
.filter-group label { font-size: 12px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); font-weight: 700; }
select.filter {
  appearance: none; border: 1px solid var(--line); border-radius: 12px; padding: 11px 38px 11px 14px;
  font: inherit; font-size: 15px; color: var(--ink); background-color: var(--surface);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%235e6d66' stroke-width='1.6' fill='none'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 14px center;
}
.grid-3 { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 20px; }

/* Страница программы */
.product-head { position: relative; overflow: hidden; background: var(--brand-dark); color: #fff; padding: 56px 0 0; }
.product-head-media { position: absolute; inset: 0; }
.product-head-media img { width: 100%; height: 100%; object-fit: cover; opacity: .6; }
.product-head-veil { position: absolute; inset: 0; background: var(--hero-veil); }
.product-head .wrap { position: relative; z-index: 1; }
.product-head h1 { font-size: clamp(30px, 4vw, 48px); }
.product-head .lead { color: rgba(255,255,255,.85); max-width: 720px; }
.product-params { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: rgba(255,255,255,.2); border-radius: 18px; overflow: hidden; margin-top: 36px; }
.product-param { background: rgba(9, 38, 30, .45); padding: 22px 24px; }
.product-param .param-label { color: rgba(255,255,255,.65); }
.product-param .param-value { font-size: clamp(20px, 2.2vw, 28px); color: #fff; }
.product-param .param-note { color: rgba(255,255,255,.65); }

.calc-box { border: 1px dashed var(--line); border-radius: var(--radius); padding: 28px; background: var(--surface-2); }
.calc-title { display: flex; align-items: center; gap: 12px; font-weight: 650; font-size: 18px; margin-bottom: 8px; }
.calc-tag { font-size: 11.5px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: #8a5a12; background: var(--accent-soft); padding: 4px 10px; border-radius: 999px; }
[data-theme="dark"] .calc-tag { color: var(--accent); }
.calc-fields { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 14px; margin: 18px 0; }
.calc-field { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px; }
.calc-field span { font-size: 12px; color: var(--muted); display: block; }
.calc-field strong { font-size: 18px; }
.calc-note { font-size: 13px; color: var(--muted); }

.feature-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; }
.feature { border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 20px; background: var(--surface); }
.feature h3 { font-size: 16px; margin: 0 0 6px; }
.feature p { font-size: 14px; color: var(--muted); margin: 0; }

.notice { border-left: 3px solid var(--accent); background: var(--accent-soft); padding: 18px 22px; border-radius: 0 var(--radius-sm) var(--radius-sm) 0; }
.notice strong { display: block; margin-bottom: 4px; }

.stub-card { border: 1px solid var(--line); border-radius: 24px; padding: 48px; background: var(--surface-2); text-align: center; max-width: 720px; margin: 0 auto; }
.stub-icon { width: 64px; height: 64px; margin: 0 auto 20px; border-radius: 18px; background: var(--brand-soft); color: var(--brand); display: grid; place-items: center; font-size: 26px; }
.stub-card h2 { font-size: clamp(22px, 2.6vw, 30px); }
.stub-card p { color: var(--muted); max-width: 520px; margin: 0 auto 22px; }
.stub-list { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; margin-bottom: 24px; }
.stub-list span { font-size: 12.5px; padding: 6px 12px; border-radius: 999px; background: var(--surface); border: 1px solid var(--line); color: var(--muted); }

/* Контакты */
.contact-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; }
.contact-tile { border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; background: var(--surface); }
.contact-tile .label { font-size: 11.5px; text-transform: uppercase; letter-spacing: .09em; color: var(--muted); font-weight: 700; }
.contact-tile .value { font-size: 18px; font-weight: 600; margin-top: 6px; }
.contact-tile a { font-weight: 600; }
.branch-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 16px; }
.branch { border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 18px 20px; background: var(--surface); }
.branch h3 { font-size: 16px; margin: 0 0 4px; }
.branch .city { font-size: 13px; color: var(--muted); text-transform: uppercase; letter-spacing: .08em; }

/* ============ Адаптив ============ */
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1 !important; transform: none !important; transition: none !important; }
  .hero-media img { animation: none; }
  html { scroll-behavior: auto; }
}
@media (max-width: 1080px) {
  .main-nav { display: none; }
  .burger { display: block; order: 4; }
  .header-actions .header-phone { display: none; }
  .site-header.nav-open .main-nav {
    display: flex; position: absolute; left: 0; right: 0; top: 100%; background: var(--surface);
    flex-direction: column; align-items: stretch; padding: 16px 24px 28px; border-bottom: 1px solid var(--line);
    max-height: calc(100vh - 68px); overflow: auto; box-shadow: var(--shadow-lg);
  }
  .site-header.nav-open .drop-panel { position: static; display: block; box-shadow: none; border: 0; padding: 0 0 8px 12px; background: transparent; animation: none; }
  .site-header.nav-open .main-nav > a, .site-header.nav-open .nav-drop > button { padding: 10px 0; }
  .stat-row { grid-template-columns: repeat(2, 1fr); }
  .facts { grid-template-columns: repeat(2, 1fr); }
  .flow { grid-template-columns: 1fr; gap: 24px; padding-left: 46px; }
  .flow-line, .flow-progress { top: 0; bottom: 0; left: 15px; right: auto; width: 2px; height: auto; }
  .flow-progress { width: 2px; height: 0; transition: height .3s ease; }
  .flow-step { padding-top: 0; }
  .flow-dot { top: 0; left: -46px; }
  .trust { grid-template-columns: 1fr; gap: 32px; }
  .layout-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 720px) {
  body { font-size: 16px; overflow-x: hidden; }
  .header-inner { gap: 10px; min-height: 68px; }
  .brand { min-width: 0; flex: 1 1 auto; }
  .brand-text { min-width: 0; max-width: 190px; }
  .brand-text strong { font-size: 14.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .brand-text small { font-size: 10.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .header-actions .btn-primary { display: none; }
  .header-actions .btn { padding: 8px 12px; }
  .section { padding: 60px 0; }
  .hero-inner { padding-top: 64px; }
  .stat-row { grid-template-columns: 1fr 1fr; }
  .facts { grid-template-columns: 1fr; }
  .product-params { grid-template-columns: 1fr; }
  .cta-band { padding: 30px; }
  .footer-grid { grid-template-columns: 1fr; }
  .cards-scroll > * { flex-basis: 85%; }
  .stub-card { padding: 30px 22px; }
  .metrics { grid-template-columns: 1fr 1fr; }
}

/* Вертикальный таймлайн (страницы «этапы» при любой ширине) */
.flow--vertical { grid-template-columns: 1fr; gap: 26px; padding-left: 46px; }
.flow--vertical .flow-line, .flow--vertical .flow-progress { top: 0; bottom: 0; left: 15px; right: auto; width: 2px; height: auto; }
.flow--vertical .flow-progress { width: 2px; height: 0; transition: height .35s ease; }
.flow--vertical .flow-step { padding-top: 0; }
.flow--vertical .flow-dot { top: 0; left: -46px; }

/* Уточнения по мобильной вёрстке и вертикальному таймлайну */
.trust > *, .metrics > * { min-width: 0; }
.flow--vertical { gap: 30px; padding-left: 52px; }
.flow--vertical .flow-dot { left: -52px; width: 34px; height: 34px; }
.flow--vertical .flow-line, .flow--vertical .flow-progress { left: 16px; }
.flow--vertical .flow-step h3 { font-size: 18px; }
@media (max-width: 720px) {
  .metrics { grid-template-columns: 1fr; }
  .stat-row { gap: 1px; }
  .hero h1 { font-size: clamp(28px, 8vw, 40px); }
}

/* Сетки не должны раздуваться от длинных слов */
.stat, .metric, .fact, .flow-step, .channel, .card, .contact-tile, .doc-item, .step { min-width: 0; }
.stat-label, .metric-label, .fact-label, .param-value, .contact-tile .value { overflow-wrap: anywhere; }
@media (max-width: 720px) {
  .stat { padding: 18px 16px; }
  .stat-value { font-size: 20px; }
  .stat-label { font-size: 12.5px; }
  .metric { padding: 18px; }
}

/* ============ Блоки контентных страниц ============ */
.page-lead { max-width: 820px; font-size: 17.5px; }
.pg-blocks { margin-top: 8px; }
.pg-block { margin-top: 54px; }
.pg-title { font-size: clamp(21px, 2.4vw, 28px); margin: 0 0 16px; }
.pg-intro { color: var(--muted); max-width: 820px; margin: 0 0 20px; font-size: 16px; }
.pg-block.prose { max-width: 820px; }

.b-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 16px; }
.b-card {
  position: relative; overflow: hidden; border: 1px solid var(--line); border-radius: var(--radius);
  background: var(--surface); padding: 24px;
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.b-card::after {
  content: ""; position: absolute; right: -40px; top: -40px; width: 120px; height: 120px; border-radius: 50%;
  background: radial-gradient(circle, color-mix(in srgb, var(--brand) 14%, transparent), transparent 70%);
  pointer-events: none;
}
.b-card:hover { transform: translateY(-3px); box-shadow: var(--shadow); border-color: var(--brand); }
.b-icon {
  width: 46px; height: 46px; border-radius: 13px; background: var(--brand-soft); color: var(--brand);
  display: grid; place-items: center; font-size: 20px; font-weight: 700; margin-bottom: 14px;
}
.b-card h3 { font-size: 18px; margin: 0 0 8px; }
.b-text { color: var(--muted); font-size: 14.8px; }
.b-text p { margin: 0 0 .6em; }
.b-text p:last-child { margin-bottom: 0; }
.b-text ul { padding-left: 18px; margin: 6px 0 0; }

.steps-rail { position: relative; display: grid; gap: 20px; padding-left: 58px; }
.steps-rail::before {
  content: ""; position: absolute; left: 19px; top: 6px; bottom: 14px; width: 2px;
  background: linear-gradient(var(--brand), color-mix(in srgb, var(--brand) 25%, transparent));
}
.s-item { position: relative; }
.s-item h3 { font-size: 17px; margin: 0 0 4px; }
.s-dot {
  position: absolute; left: -58px; top: -2px; width: 40px; height: 40px; border-radius: 12px;
  background: var(--brand); color: #fff; display: grid; place-items: center;
  font-weight: 700; font-size: 13.5px; letter-spacing: .02em;
  box-shadow: 0 8px 18px rgba(0, 122, 64, .22);
}
[data-theme="dark"] .s-dot { color: #06110d; }
.s-text { color: var(--muted); font-size: 14.8px; }
.s-text p { margin: 0 0 .5em; }
.s-text p:last-child { margin-bottom: 0; }

.checklist { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; max-width: 860px; }
.checklist li { display: flex; gap: 12px; align-items: flex-start; font-size: 15.5px; }
.checklist li::before {
  content: "✓"; flex: 0 0 26px; width: 26px; height: 26px; border-radius: 50%;
  background: var(--brand-soft); color: var(--brand); display: grid; place-items: center;
  font-size: 13px; font-weight: 700; margin-top: 1px;
}
.cl-text { color: var(--muted); font-size: 14.5px; margin-top: 2px; }
.cl-text p { margin: 0; }

.b-callout {
  display: flex; gap: 18px; align-items: flex-start;
  border: 1px solid var(--line); border-radius: var(--radius); padding: 26px 28px;
  background: linear-gradient(120deg, var(--brand-soft), var(--surface-2));
}
.b-callout .c-icon { font-size: 26px; line-height: 1; }
.b-callout h3 { font-size: 19px; margin: 0 0 8px; }
.c-text { color: var(--ink); opacity: .85; font-size: 15.5px; }
.c-text p { margin: 0 0 .6em; }
.c-text p:last-child { margin-bottom: 0; }

@media (max-width: 720px) {
  .steps-rail { padding-left: 48px; }
  .s-dot { left: -48px; width: 34px; height: 34px; font-size: 12px; border-radius: 10px; }
  .steps-rail::before { left: 16px; }
  .b-callout { padding: 20px; flex-direction: column; gap: 10px; }
  .pg-block { margin-top: 40px; }
}

/* Иконки блоков и боковая панель страницы */
.ico { width: 22px; height: 22px; display: block; }
.b-icon .ico { width: 24px; height: 24px; }
.b-num-ico { font-size: 18px; font-weight: 700; color: var(--brand); }
.c-icon {
  flex: 0 0 46px; width: 46px; height: 46px; border-radius: 13px; background: var(--surface);
  border: 1px solid var(--line); color: var(--brand); display: grid; place-items: center;
}
.c-icon .ico { width: 24px; height: 24px; }
.b-card::after { width: 90px; height: 90px; right: -34px; top: -34px; background: radial-gradient(circle, color-mix(in srgb, var(--brand) 9%, transparent), transparent 70%); }

.page-layout { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 48px; align-items: start; }
.page-main { min-width: 0; }
.page-aside { position: sticky; top: 104px; }
.page-aside .aside-card { padding: 22px; }
@media (max-width: 1080px) {
  .page-layout { grid-template-columns: 1fr; gap: 32px; }
  .page-aside { position: static; display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
  .page-aside .aside-card + .aside-card { margin-top: 0; }
}
@media (max-width: 720px) {
  .page-aside { grid-template-columns: 1fr; }
}

/* Оформление шапки контентной страницы */
.page-hero { position: relative; overflow: hidden; background: linear-gradient(125deg, var(--brand-soft), var(--surface-2) 70%); }
.page-hero::after {
  content: ""; position: absolute; right: -70px; top: -80px; width: 340px; height: 340px; border-radius: 50%;
  background: radial-gradient(circle, color-mix(in srgb, var(--brand) 16%, transparent), transparent 68%);
  pointer-events: none;
}
.page-hero::before {
  content: ""; position: absolute; right: 24px; bottom: 18px; width: 180px; height: 120px;
  background-image: radial-gradient(color-mix(in srgb, var(--brand) 30%, transparent) 1px, transparent 1px);
  background-size: 14px 14px; opacity: .5; pointer-events: none;
}
.page-hero .wrap { position: relative; z-index: 1; }
@media (max-width: 720px) {
  .page-hero::before { display: none; }
  .page-hero::after { width: 200px; height: 200px; right: -60px; top: -60px; }
}

/* Карточки блоков: 3 в ряд на широком экране */
.b-cards { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
@media (max-width: 720px) { .b-cards { grid-template-columns: 1fr; } }

.contact-grid { grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); }
.contact-tile--full { grid-column: 1 / -1; }

/* ============ Слайдер программ ============ */
.slider { position: relative; }
.slider .cards-scroll { scrollbar-width: none; -ms-overflow-style: none; scroll-behavior: smooth; }
.slider .cards-scroll::-webkit-scrollbar { display: none; }
.slider-btn {
  position: absolute; top: 50%; transform: translateY(-50%); z-index: 2;
  width: 46px; height: 46px; border-radius: 50%;
  background: var(--surface); border: 1px solid var(--line); color: var(--ink);
  display: grid; place-items: center; cursor: pointer;
  box-shadow: 0 10px 26px rgba(20, 37, 29, .16);
  transition: background-color .18s ease, color .18s ease, border-color .18s ease, transform .18s ease, opacity .18s ease;
}
.slider-btn svg { width: 20px; height: 20px; }
.slider-btn:hover { background: var(--brand); border-color: var(--brand); color: #fff; }
[data-theme="dark"] .slider-btn:hover { color: #06110d; }
.slider-btn:disabled { opacity: .35; cursor: default; box-shadow: none; }
.slider-btn--prev { left: -8px; }
.slider-btn--next { right: -8px; }
.slider.is-static .slider-btn { display: none; }

/* ============ Кнопка «наверх» ============ */
.to-top {
  position: fixed; right: 22px; bottom: 24px; width: 50px; height: 50px; border-radius: 50%;
  background: var(--brand); color: #fff; border: 0; display: grid; place-items: center; cursor: pointer;
  box-shadow: 0 14px 34px rgba(0, 122, 64, .35); opacity: 0; visibility: hidden; transform: translateY(12px);
  transition: opacity .25s ease, transform .25s ease, background-color .2s ease;
  z-index: 60;
}
.to-top svg { width: 22px; height: 22px; }
.to-top.is-visible { opacity: 1; visibility: visible; transform: none; }
.to-top:hover { background: var(--brand-dark); transform: translateY(-2px); }
[data-theme="dark"] .to-top { color: #06110d; }

/* ============ Выезжающее меню ============ */
body.nav-locked { overflow: hidden; }
.nav-close { display: none; }
.nav-backdrop {
  position: fixed; inset: 0; background: rgba(6, 20, 16, .45); backdrop-filter: blur(2px);
  opacity: 0; visibility: hidden; transition: opacity .25s ease, visibility .25s ease; z-index: 60;
}
.site-header.nav-open .nav-backdrop { opacity: 1; visibility: visible; }
.nav-backdrop[hidden] { display: none; }

@media (max-width: 1080px) {
  .main-nav {
    display: flex; position: fixed; top: 0; right: 0; bottom: 0; width: min(360px, 86vw);
    background: var(--surface); border-left: 1px solid var(--line);
    flex-direction: column; align-items: stretch; gap: 2px;
    padding: 84px 22px 28px; overflow-y: auto;
    transform: translateX(104%); transition: transform .3s cubic-bezier(.22,.61,.36,1);
    box-shadow: -24px 0 60px rgba(0, 0, 0, .22); z-index: 70;
  }
  .site-header.nav-open .main-nav {
    display: flex; position: fixed; transform: none; max-height: none;
    padding: 84px 22px 28px; box-shadow: -24px 0 60px rgba(0, 0, 0, .22);
  }
  .nav-close {
    display: grid; place-items: center; position: absolute; top: 18px; right: 18px;
    width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--line);
    background: var(--surface-2); color: var(--ink); cursor: pointer;
  }
  .nav-close svg { width: 18px; height: 18px; }
  .main-nav > a, .nav-drop > button { padding: 12px 4px; font-size: 16px; }
  .site-header.nav-open .drop-panel {
    position: static; display: none; box-shadow: none; border: 0; padding: 0 0 8px 10px;
    background: transparent; animation: none;
  }
  .site-header.nav-open .nav-drop.open .drop-panel { display: block; }
  .site-header.nav-open .nav-drop.open > button::after { transform: rotate(225deg); }
}

@media (max-width: 720px) {
  .slider-btn { width: 40px; height: 40px; }
  .slider-btn--prev { left: -4px; }
  .slider-btn--next { right: -4px; }
  .slider-btn svg { width: 18px; height: 18px; }
  .to-top { right: 16px; bottom: 18px; width: 46px; height: 46px; }
}

/* Панель меню должна позиционироваться от окна: убираем backdrop-filter у шапки на мобильных */
@media (max-width: 1080px) {
  .site-header { backdrop-filter: none; }
}

@media (max-width: 1080px) {
  .main-nav,
  .site-header.nav-open .main-nav {
    top: 0;
    right: 0;
    bottom: 0;
    left: auto;
    height: auto;
    max-height: none;
    border-radius: 0;
  }
}

.nav-extra { display: none; }
@media (max-width: 1080px) {
  .nav-extra {
    display: grid; gap: 10px; margin-top: 20px; padding-top: 18px;
    border-top: 1px solid var(--line);
  }
  .nav-extra .btn { width: 100%; }
  .nav-phone { font-size: 15px; font-weight: 600; color: var(--brand); text-align: center; }
}

/* Стрелки слайдера: не перекрывают текст карточки (внутри её отступа) */
.slider-btn { width: 40px; height: 40px; }
.slider-btn svg { width: 18px; height: 18px; }
.slider-btn--prev { left: -20px; }
.slider-btn--next { right: -20px; }
@media (max-width: 720px) {
  .slider-btn { width: 36px; height: 36px; }
  .slider-btn svg { width: 16px; height: 16px; }
  .slider-btn--prev { left: -18px; }
  .slider-btn--next { right: -18px; }
}

/* Параметры карточки: переносим по словам, без разрыва внутри слова */
.param-value, .card .param-value { overflow-wrap: break-word; word-break: normal; hyphens: auto; }
@media (max-width: 720px) {
  .card .param-value { font-size: 14px; }
  .card .param-label { font-size: 10.5px; }
}

.param-value, .card .param-value { hyphens: manual; }

/* ============ Логотип: зелёный в светлой теме, белый в тёмной ============ */
.brand-mark {
  background: transparent; box-shadow: none; width: 46px; height: 46px;
  display: grid; place-items: center; color: var(--brand);
}
.brand-svg { width: 100%; height: 100%; display: block; }
[data-theme="dark"] .brand-mark { color: #ffffff; }
.site-footer .brand-mark { color: #ffffff; width: 42px; height: 42px; }
.site-footer .brand-mark .brand-svg { width: 100%; height: 100%; }

/* Подвал: эмблема белая на тёмном, без белого квадрата */
.site-footer .brand-mark,
.footer-brand .brand-mark {
  background: transparent !important;
  color: #ffffff !important;
  width: 42px; height: 42px;
}

/* ============ Шире контент, как на корпоративных порталах ============ */
:root { --wrap: 1400px; }
@media (min-width: 1600px) { :root { --wrap: 1520px; } }

.wrap { padding: 0 28px; }
.section-head { max-width: 860px; }
.prose, .page-lead, .pg-intro, .pg-block.prose, .steps-rail, .checklist { max-width: 900px; }
.page-layout { grid-template-columns: minmax(0, 1fr) 340px; gap: 52px; }
.layout-grid { grid-template-columns: minmax(0, 1fr) 340px; gap: 52px; }
.grid-3 { grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); }
@media (min-width: 1081px) { .footer-grid { grid-template-columns: 1.5fr 1fr 1fr 1fr; } }
.b-cards { grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); }

@media (min-width: 721px) {
  .cards-scroll > * { flex-basis: 360px; }
  .slider-btn--prev { left: -20px; }
  .slider-btn--next { right: -20px; }
}

@media (max-width: 1080px) {
  .page-layout, .layout-grid { grid-template-columns: 1fr; gap: 32px; }
}
@media (max-width: 720px) {
  .wrap { padding: 0 20px; }
  .cards-scroll > * { flex-basis: 85%; }
}

/* Выезжающее меню не должно расширять страницу по горизонтали */
@media (max-width: 1080px) {
  html, body { overflow-x: clip; }
}

/* ============ Первый экран: больше воздуха сверху и выше изображение ============ */
.hero { min-height: 700px; display: flex; flex-direction: column; }
.hero-inner { padding-top: clamp(110px, 13vw, 190px); flex: 1 1 auto; display: flex; flex-direction: column; }
.hero-inner .stat-row { margin-top: auto; }
.hero-sub, .hero-actions, .hero-note, .hero h1, .hero-kicker { flex: 0 0 auto; }

@media (max-width: 1080px) {
  .hero { min-height: 0; }
  .hero-inner { padding-top: 96px; }
}
@media (max-width: 720px) {
  .hero-inner { padding-top: 84px; }
  .hero-inner .stat-row { margin-top: 40px; }
}

/* Первый экран: бейдж по ширине текста, заголовок в одну строку на десктопе */
.hero-kicker { align-self: flex-start; }
.hero h1 { max-width: 1150px; }
.hero-sub { max-width: 680px; }

@media (max-width: 720px) {
  .hero h1 { font-size: clamp(26px, 7.2vw, 34px); }
  .stat-value { font-size: 18px; white-space: nowrap; }
  .stat-label { font-size: 12px; }
}

@media (max-width: 720px) {
  .hero h1 { font-size: clamp(23px, 6.6vw, 32px); letter-spacing: -.01em; }
}

/* Акцентная фраза не разрывается: на узких экранах перенос идёт перед ней */
.hero-accent { white-space: nowrap; }

/* ============ Мобильное меню: полный список, закреплённый низ ============ */
.mobile-menu { display: none; }

@media (max-width: 1080px) {
  .mobile-menu {
    display: flex; flex-direction: column;
    position: fixed; top: 0; right: 0; bottom: 0; width: min(392px, 90vw);
    background: var(--surface); z-index: 80;
    transform: translateX(102%);
    transition: transform .32s cubic-bezier(.22, .61, .36, 1);
    box-shadow: -24px 0 60px rgba(0, 0, 0, .25);
    overflow: hidden;
  }
  body.nav-locked .mobile-menu { transform: none; }

  .mm-head {
    display: flex; align-items: center; gap: 12px; flex: 0 0 auto;
    padding: 16px 18px; border-bottom: 1px solid var(--line);
  }
  .mm-title { display: flex; flex-direction: column; line-height: 1.15; min-width: 0; }
  .mm-title strong { font-size: 15px; }
  .mm-title small { font-size: 11px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .mm-head .brand-mark { width: 38px; height: 38px; }
  .mm-head .nav-close { position: static; margin-left: auto; flex: 0 0 auto; }

  .mm-body { flex: 1 1 auto; overflow-y: auto; padding: 4px 18px 16px; -webkit-overflow-scrolling: touch; }
  .mm-group { padding: 12px 0; border-bottom: 1px solid var(--line); }
  .mm-group:last-child { border-bottom: 0; }
  .mm-group-title {
    display: block; font-size: 11px; letter-spacing: .1em; text-transform: uppercase;
    color: var(--muted); font-weight: 700; margin-bottom: 4px;
  }
  .mm-group a { display: block; padding: 9px 0; font-size: 15.5px; color: var(--ink); }
  .mm-group a:active, .mm-group a:hover { color: var(--brand); }
  .mm-link-strong { font-weight: 600; }
  .mm-contacts a { font-weight: 600; color: var(--brand); }
  .mm-hours { display: block; font-size: 12.5px; color: var(--muted); margin-top: 6px; }

  .mm-foot {
    flex: 0 0 auto; display: grid; gap: 10px;
    padding: 14px 18px calc(16px + env(safe-area-inset-bottom));
    border-top: 1px solid var(--line); background: var(--surface);
  }
  .mm-foot .btn { width: 100%; }
  .mm-phone { text-align: center; font-weight: 700; font-size: 17px; color: var(--brand); }
}

@media (max-width: 1080px) {
  .mm-main { display: grid; grid-template-columns: 1fr 1fr; gap: 4px 10px; padding-top: 14px; }
  .mm-main a { font-weight: 600; font-size: 15px; padding: 10px 0; }
  .mm-group-title { color: color-mix(in srgb, var(--ink) 55%, transparent); }
}

/* На узких экранах верхнее меню полностью заменено шторкой */
@media (max-width: 1080px) {
  .main-nav { display: none !important; }
}

/* ============ Извещения ============ */
.notice-list { display: grid; gap: 12px; max-width: 1200px; }
.notice {
  display: grid; grid-template-columns: 148px minmax(0, 1fr) 24px; gap: 18px; align-items: start;
  padding: 20px 22px; border: 1px solid var(--line); border-radius: 14px;
  background: var(--card); color: inherit; text-decoration: none;
  transition: border-color .2s ease, transform .2s ease, box-shadow .2s ease;
}
.notice:hover { border-color: var(--brand); transform: translateY(-1px); box-shadow: 0 10px 26px rgba(0, 122, 64, .08); }
.notice-date { font-size: 13px; font-weight: 600; color: var(--muted); letter-spacing: .02em; }
.notice-text strong { display: block; font-size: 17px; line-height: 1.38; }
.notice-lead { display: block; margin-top: 6px; font-size: 14px; line-height: 1.5; color: var(--muted); }
.notice-arrow { color: var(--brand); font-size: 18px; align-self: center; }
.notice-list--compact .notice { padding: 14px 18px; }
.notice-list--compact .notice-text strong { font-size: 15.5px; }

@media (max-width: 720px) {
  .notice { grid-template-columns: minmax(0, 1fr); gap: 6px; padding: 16px 18px; }
  .notice-arrow { display: none; }
  .notice-text strong { font-size: 15.5px; }
}

/* Нумерованные и маркированные списки в тексте — с висячим отступом */
.prose ol { padding-left: 30px; }
.prose ul { padding-left: 24px; }
.prose li { padding-left: 4px; }
.prose li::marker { color: var(--brand); font-weight: 600; }
.prose li > p { margin: 0 0 10px; }
.prose li:last-child > p { margin-bottom: 0; }

/* Мобильная шторка: три быстрых ссылки в ряд */
@media (max-width: 1080px) {
  .mm-main { grid-template-columns: repeat(3, 1fr); }
  .mm-main a { font-size: 14.5px; }
}

/* Шапка: на средних экранах телефон убираем, чтобы меню и кнопка не жались */
@media (max-width: 1240px) {
  .header-phone { display: none; }
  .main-nav { gap: 18px; }
}

/* На узких десктопах кнопка заявки живёт в меню-шторке */
@media (max-width: 1260px) {
  .header-actions .btn-primary { display: none; }
  .main-nav { gap: 14px; }
  .main-nav a, .nav-drop > button { font-size: 14.5px; }
}

/* ============ Подвал: адаптив ============ */
@media (min-width: 721px) and (max-width: 1080px) {
  .footer-grid > div:first-child { grid-column: 1 / -1; }
}

@media (max-width: 720px) {
  .site-footer { padding: 44px 0 24px; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 26px 22px; }
  .footer-grid > div:first-child { grid-column: 1 / -1; }
  .footer-grid > div:nth-child(2) { grid-column: 1 / -1; }
  .footer-grid > div:nth-child(2) ul { display: flex; flex-wrap: wrap; gap: 10px 26px; }
  .site-footer h4 { font-size: 12px; margin-bottom: 10px; }
  .site-footer a { font-size: 14px; }
  .site-footer p { font-size: 13.5px !important; }
  .footer-brand { margin-bottom: 12px; }
  .footer-bottom { margin-top: 30px; padding-top: 18px; flex-direction: column; gap: 8px; font-size: 12px; }
}

/* Кнопка «наверх» не должна накрывать текст нижней строки подвала */
.footer-bottom { padding-right: 64px; }
@media (max-width: 720px) {
  .footer-bottom { padding-right: 54px; }
}

/* Телефон: разделы подвала в одну колонку, а списки внутри — в две */
@media (max-width: 720px) {
  .footer-grid { grid-template-columns: 1fr; gap: 22px; }
  .footer-grid > div { grid-column: auto; }
  .footer-grid ul { grid-template-columns: 1fr 1fr; gap: 8px 18px; }
  .footer-grid > div:nth-child(2) ul { display: flex; flex-wrap: wrap; gap: 8px 24px; }
  .site-footer h4 { margin-bottom: 8px; }
}

/* Планшет и телефон: подвал в одну колонку, списки внутри — в две */
@media (max-width: 1080px) {
  .footer-grid { grid-template-columns: 1fr; gap: 24px; }
  .footer-grid > div { grid-column: auto; }
  .footer-grid ul { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px 24px; }
  .footer-grid > div:nth-child(2) ul { display: flex; flex-wrap: wrap; gap: 10px 30px; }
}

/* ============ Мастер подбора программы ============ */
.pk-hero .pk-kicker {
  display: inline-flex; align-items: center; gap: 8px; margin-bottom: 14px;
  padding: 7px 14px; border-radius: 999px;
  background: color-mix(in srgb, var(--brand) 10%, transparent);
  color: var(--brand); font-size: 12.5px; font-weight: 700; letter-spacing: .02em;
}

.pk {
  max-width: 980px; padding: 28px 30px 26px;
  border: 1px solid var(--line); border-radius: 20px; background: var(--surface);
  box-shadow: var(--shadow);
}
.pk-head { margin-bottom: 24px; }
.pk-steps { display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 14px; }
.pk-dot { display: inline-flex; align-items: center; gap: 8px; color: var(--muted); font-size: 12.5px; }
.pk-dot b {
  display: grid; place-items: center; width: 26px; height: 26px; border-radius: 50%;
  border: 1px solid var(--line); font-size: 12.5px; font-weight: 700; background: var(--surface-2);
}
.pk-dot.is-active { color: var(--ink); }
.pk-dot.is-active b { background: var(--brand); border-color: var(--brand); color: #fff; }
.pk-dot.is-done b { background: color-mix(in srgb, var(--brand) 16%, transparent); border-color: transparent; color: var(--brand); }
.pk-bar { height: 4px; border-radius: 999px; background: var(--surface-2); overflow: hidden; }
.pk-bar span { display: block; height: 100%; width: 25%; border-radius: inherit; background: var(--brand); transition: width .3s ease; }

.pk-step { display: none; }
.pk-step.is-active { display: block; animation: pk-fade .25s ease; }
@keyframes pk-fade { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.pk-step h2 { font-size: clamp(20px, 2.4vw, 26px); margin-bottom: 6px; }
.pk-hint { color: var(--muted); font-size: 14px; margin: 0 0 18px; }

.pk-options { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.pk-options--grid { grid-template-columns: repeat(3, 1fr); }
.pk-opt {
  position: relative; display: flex; gap: 12px; align-items: flex-start;
  padding: 16px 18px; border: 1px solid var(--line); border-radius: 14px;
  background: var(--surface); cursor: pointer;
  transition: border-color .18s ease, box-shadow .18s ease, transform .18s ease;
}
.pk-opt:hover { border-color: color-mix(in srgb, var(--brand) 45%, var(--line)); transform: translateY(-1px); }
.pk-opt input { position: absolute; opacity: 0; pointer-events: none; }
.pk-opt-ic { font-size: 22px; line-height: 1.2; }
.pk-opt-tx strong { display: block; font-size: 15.5px; line-height: 1.3; }
.pk-opt-tx small { display: block; margin-top: 4px; color: var(--muted); font-size: 13px; line-height: 1.4; }
.pk-opt--sm { align-items: center; padding: 14px 16px; }
.pk-opt--sm .pk-opt-tx strong { font-size: 15px; }
.pk-opt:has(input:checked) {
  border-color: var(--brand);
  box-shadow: inset 0 0 0 1px var(--brand), 0 8px 20px rgba(0, 122, 64, .08);
  background: color-mix(in srgb, var(--brand) 5%, var(--surface));
}
.pk-opt:has(input:focus-visible) { outline: 2px solid var(--brand); outline-offset: 2px; }
.pk-step.is-error .pk-options { outline: 2px solid rgba(179, 38, 30, .35); outline-offset: 6px; border-radius: 12px; }

.pk-nav { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-top: 22px; }
.pk-note { color: var(--muted); font-size: 13px; }
.pk-note[hidden] { display: none; }

.pk-hintbox {
  margin-top: 20px; padding: 14px 18px; border-radius: 12px;
  background: var(--surface-2); color: var(--muted); font-size: 13.5px; line-height: 1.5;
}
.pk-hintbox--top { margin: 24px 0 0; }

/* Результат */
.pk-summary {
  display: flex; flex-wrap: wrap; align-items: center; gap: 18px 26px;
  padding: 16px 20px; border: 1px solid var(--line); border-radius: 16px; background: var(--surface);
}
.pk-sum-item { display: flex; align-items: center; gap: 10px; }
.pk-sum-ic { font-size: 22px; }
.pk-sum-item small {
  display: block; font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted);
}
.pk-sum-item strong { font-size: 15px; }
.pk-edit { margin-left: auto; color: var(--brand); font-weight: 600; font-size: 14px; }

.pk-res-title { font-size: clamp(20px, 2.2vw, 25px); margin: 30px 0 16px; }
.pk-results { display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); }
.pk-res {
  display: flex; flex-direction: column; gap: 12px;
  padding: 20px; border: 1px solid var(--line); border-radius: 16px; background: var(--surface);
  transition: border-color .2s ease, box-shadow .2s ease;
}
.pk-res:hover { border-color: color-mix(in srgb, var(--brand) 40%, var(--line)); box-shadow: var(--shadow); }
.pk-res-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.pk-res-head h3 { font-size: 17px; line-height: 1.3; margin: 0; }
.pk-res-head h3 a { color: var(--ink); }
.pk-badge {
  flex: 0 0 auto; padding: 4px 10px; border-radius: 999px; font-size: 11.5px; font-weight: 700;
  background: color-mix(in srgb, var(--accent) 18%, transparent); color: #8a5c14; white-space: nowrap;
}
.pk-res-params {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px;
  padding: 12px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
}
.pk-res-params small { display: block; font-size: 11px; color: var(--muted); margin-bottom: 3px; }
.pk-res-params strong { font-size: 14.5px; }
.pk-res-desc { color: var(--muted); font-size: 13.5px; line-height: 1.5; margin: 0; }
.pk-fit { display: flex; flex-wrap: wrap; gap: 8px; }
.fit {
  font-size: 11.5px; font-weight: 700; padding: 4px 10px; border-radius: 999px;
  background: color-mix(in srgb, var(--brand) 10%, transparent); color: var(--brand);
}
.fit--warn { background: rgba(192, 135, 46, .16); color: #8a5c14; }
.pk-res-actions { display: flex; gap: 10px; margin-top: auto; padding-top: 4px; }

/* Форма консультации */
.pk-lead {
  margin-top: 28px; padding: 24px; border: 1px solid var(--line); border-radius: 18px;
  background: var(--surface); display: grid; grid-template-columns: 1fr 1fr; gap: 26px; align-items: start;
}
.pk-lead-tx h2 { font-size: 20px; margin-bottom: 8px; }
.pk-lead-tx p { color: var(--muted); font-size: 14px; line-height: 1.55; margin: 0 0 8px; }
.pk-lead-hours { font-size: 13px !important; }
.pk-form { display: grid; gap: 12px; }
.pk-form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.pk-form label span { display: block; font-size: 12.5px; color: var(--muted); margin-bottom: 6px; }
.pk-form input, .pk-form textarea {
  width: 100%; padding: 11px 14px; border: 1px solid var(--line); border-radius: 10px;
  background: var(--surface); color: var(--ink); font: inherit; resize: vertical;
}
.pk-form input:focus, .pk-form textarea:focus {
  outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px rgba(0, 122, 64, .12);
}
.pk-form .btn { justify-self: start; }
.pk-err {
  padding: 10px 14px; border-radius: 10px; font-size: 13px;
  background: rgba(179, 38, 30, .08); color: #b3261e;
}
.pk-sent {
  display: grid; gap: 8px; padding: 18px 20px; border-radius: 14px;
  border: 1px solid color-mix(in srgb, var(--brand) 28%, transparent);
  background: color-mix(in srgb, var(--brand) 6%, transparent);
}
.pk-sent strong { font-size: 15px; }
.pk-sent span { font-size: 13.5px; color: var(--muted); }
.pk-sent .btn { justify-self: start; margin-top: 4px; }

@media (max-width: 900px) {
  .pk { padding: 22px 20px; }
  .pk-options { grid-template-columns: 1fr; }
  .pk-options--grid { grid-template-columns: 1fr 1fr; }
  .pk-lead { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
  .pk-options--grid { grid-template-columns: 1fr; }
  .pk-steps { gap: 8px; }
  .pk-dot i { display: none; }
  .pk-res-params { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
  .pk-res-params strong { font-size: 13.5px; }
  .pk-form-row { grid-template-columns: 1fr; }
  .pk-edit { margin-left: 0; }
  .pk-res-actions .btn { flex: 1 1 auto; justify-content: center; }
}

.pk-res-title--alt { margin-top: 34px; font-size: 19px; color: var(--muted); }
.pk-results--soft .pk-res { background: var(--surface-2); }

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

.pk-opt-ic .ico, .pk-sum-ic .ico { width: 22px; height: 22px; color: var(--brand); display: block; }

.btn:disabled { opacity: .55; cursor: not-allowed; transform: none; }

.pk-res-params strong { white-space: nowrap; }
.pk-res-params div { min-width: 0; }

/* ============ Каталог: переключатели направлений и целей ============ */
.pf { display: grid; gap: 14px; margin-bottom: 30px; }
.pf-row { display: grid; grid-template-columns: 136px minmax(0, 1fr); gap: 16px; align-items: start; }
.pf-label {
  font-size: 12px; text-transform: uppercase; letter-spacing: .08em;
  color: var(--muted); font-weight: 700; padding-top: 11px;
}
.pf-chips { display: flex; flex-wrap: wrap; gap: 8px; min-width: 0; }
.pf-chip {
  display: inline-flex; align-items: center; gap: 8px; padding: 9px 14px;
  border: 1px solid var(--line); border-radius: 999px; background: var(--surface);
  color: var(--ink); font-size: 14px; text-decoration: none; cursor: pointer;
  transition: background-color .18s ease, border-color .18s ease, color .18s ease, transform .18s ease;
}
.pf-chip:hover { border-color: color-mix(in srgb, var(--brand) 45%, var(--line)); transform: translateY(-1px); }
.pf-chip.is-active { background: var(--brand); border-color: var(--brand); color: #fff; }
.pf-count {
  font-size: 11.5px; font-weight: 700; padding: 1px 7px; border-radius: 999px;
  background: var(--surface-2); color: var(--muted); min-width: 20px; text-align: center;
}
.pf-chip.is-active .pf-count { background: rgba(255, 255, 255, .22); color: #fff; }
.pf-meta { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; margin-top: 2px; }
.pf-found { font-size: 14px; color: var(--muted); }
.pf-found b { color: var(--ink); font-size: 15px; }
.pf-reset { font-size: 14px; font-weight: 600; color: var(--brand); }

.pf-item { display: flex; min-width: 0; }
.pf-item > .card { width: 100%; }
.pf-item.is-hidden { display: none; }
.pf-empty {
  display: grid; gap: 6px; margin-top: 26px; padding: 22px 24px;
  border: 1px dashed var(--line); border-radius: 14px; color: var(--muted); font-size: 14px;
}
.pf-empty[hidden] { display: none; }
.pf-empty strong { color: var(--ink); font-size: 16px; }

@media (max-width: 720px) {
  .pf-row { grid-template-columns: 1fr; gap: 8px; }
  .pf-label { padding-top: 0; }
  .pf-chip { font-size: 13.5px; padding: 8px 12px; }
  .pf-chips { gap: 6px; }
}

.pf-chip.is-empty:not(.is-active) { opacity: .55; }
.pf-chip.is-empty:hover { opacity: 1; }

.pf-meta { gap: 16px; }
.pf-podbor { margin-left: auto; }
@media (max-width: 720px) { .pf-podbor { margin-left: 0; } }

/* Контакты: карточки во всю ширину, как карточка адреса */
.contact-grid { grid-template-columns: 1fr; gap: 12px; }
.contact-grid .contact-tile {
  display: flex; align-items: baseline; justify-content: space-between; gap: 20px;
  padding: 20px 24px;
}
.contact-grid .contact-tile .label { margin: 0; }
.contact-grid .contact-tile .value { margin-top: 0; font-size: 18px; }
.contact-grid .contact-tile--full { align-items: flex-start; }

@media (max-width: 720px) {
  .contact-grid .contact-tile { flex-direction: column; gap: 6px; align-items: flex-start; padding: 18px 20px; }
  .contact-grid .contact-tile .value { font-size: 16.5px; }
}

/* Контакты: три карточки в ряд на всю ширину, адрес — отдельной строкой */
.contact-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.contact-grid .contact-tile { display: block; padding: 24px; }
.contact-grid .contact-tile .label { margin: 0; }
.contact-grid .contact-tile .value { margin-top: 6px; font-size: 18px; }

@media (max-width: 900px) {
  .contact-grid { grid-template-columns: 1fr 1fr; }
  .contact-grid .contact-tile--full { grid-column: 1 / -1; }
}
@media (max-width: 720px) {
  .contact-grid { grid-template-columns: 1fr; }
  .contact-grid .contact-tile { padding: 20px; }
  .contact-grid .contact-tile .value { font-size: 16.5px; }
}

/* ============ Установка приложения (PWA) ============ */
.mm-install { width: 100%; margin-bottom: 2px; }
.mm-install svg { width: 18px; height: 18px; }

.install-fab {
  position: fixed; left: 20px; bottom: 20px; z-index: 45;
  display: inline-flex; align-items: center; gap: 10px;
  padding: 12px 16px 12px 14px; border-radius: 999px; border: 1px solid transparent;
  background: var(--brand); color: #fff; font: inherit; font-size: 14px; font-weight: 600;
  cursor: pointer; box-shadow: 0 14px 30px rgba(0, 122, 64, .28);
  transition: transform .18s ease, box-shadow .18s ease, background-color .18s ease;
}
.install-fab:hover { transform: translateY(-2px); background: var(--brand-dark); box-shadow: 0 18px 36px rgba(0, 122, 64, .34); }
.install-fab svg { width: 18px; height: 18px; }
.install-fab[hidden] { display: none; }
.install-x {
  display: grid; place-items: center; width: 20px; height: 20px; margin-left: 2px;
  border-radius: 50%; background: rgba(255, 255, 255, .18); font-size: 14px; line-height: 1;
}
.install-x:hover { background: rgba(255, 255, 255, .3); }

.install-hint {
  position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); z-index: 90;
  max-width: min(420px, calc(100vw - 32px)); padding: 14px 18px; border-radius: 14px;
  background: var(--ink); color: #fff; font-size: 13.5px; line-height: 1.5;
  box-shadow: 0 18px 40px rgba(20, 37, 29, .35);
}
.install-hint[hidden] { display: none; }

@media (max-width: 1080px) {
  .install-fab { display: none !important; }
}

/* Первый экран: видео вместо фотографии */
.hero-media .hero-still { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero-media .hero-video {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  opacity: 0; transition: opacity .8s ease;
}
.hero-media .hero-video.is-ready { opacity: 1; }
@media (prefers-reduced-motion: reduce) { .hero-media .hero-video { display: none; } }

/* Кнопка установки: чуть компактнее, чтобы меньше перекрывать контент */
.install-fab { left: 16px; bottom: 16px; padding: 10px 14px 10px 12px; font-size: 13.5px; opacity: .97; }
.install-fab:hover { opacity: 1; }

/* --- переключатель направлений на главной --- */
.pf--compact { gap: 10px; margin-bottom: 24px; }
.pf--compact .pf-chip { cursor: pointer; font-family: inherit; }
.cards-scroll > .card.is-hidden { display: none; }
.pf-empty-line { margin: 16px 0 0; font-size: 14px; color: var(--muted); }
@media (max-width: 720px) {
  .pf--compact .pf-row { gap: 6px; }
  .pf--compact { margin-bottom: 18px; }
  .pf--compact .pf-chips {
    flex-wrap: nowrap;
    overflow-x: auto;
    padding-bottom: 2px;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }
  .pf--compact .pf-chips::-webkit-scrollbar { display: none; }
  .pf--compact .pf-chip { flex: 0 0 auto; }
}

/* --- блок председателя --- */
.chairman { display: grid; grid-template-columns: 0.82fr 1.18fr; gap: 56px; align-items: center; }
.chairman-media { margin: 0; max-width: 460px; align-self: center; }
.chairman-media img {
  width: 100%; height: auto; display: block; border-radius: var(--radius);
  box-shadow: var(--shadow); object-fit: cover;
}
.chairman-monogram {
  aspect-ratio: 4 / 5; display: grid; place-items: center;
  border-radius: var(--radius); color: #fff;
  background: linear-gradient(158deg, var(--brand) 0%, var(--brand-dark) 62%, #04402b 100%);
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(84px, 11vw, 148px); line-height: 1;
  padding-bottom: .3em;
  box-shadow: var(--shadow);
}
.chairman-body { max-width: 640px; min-width: 0; }
.chairman-quote {
  margin: 18px 0 22px; padding: 0; border: 0;
  font-size: 17.5px; line-height: 1.68; color: var(--ink);
}
.chairman-quote p { margin: 0 0 13px; }
.chairman-quote p:last-child { margin-bottom: 0; }
.chairman-sign { display: grid; gap: 3px; padding-top: 18px; border-top: 1px solid var(--line); }
.chairman-sign strong { font-size: 16px; }
.chairman-sign span { font-size: 14px; color: var(--muted); }

@media (max-width: 960px) {
  .chairman { grid-template-columns: 1fr; gap: 24px; }
  .chairman-media { max-width: 230px; }
  .chairman-monogram { aspect-ratio: 1 / 1; font-size: 72px; padding-bottom: .22em; }
  .chairman-quote { font-size: 16.5px; }
}

/* --- главная: четыре программы в ряд без прокрутки --- */
.slider--grid .cards-scroll {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 20px;
  overflow: visible;
  padding: 4px 0 6px;
  scroll-snap-type: none;
}
.slider--grid .cards-scroll > * { flex: initial; min-width: 0; }
.slider--grid .slider-btn { display: none; }
.slider--grid .card-body { padding: 18px 18px 20px; gap: 9px; }
.slider--grid .card-body h3 { font-size: 17px; }
.slider--grid .params { gap: 8px; margin: auto 0 12px; }
.slider--grid .param-value { font-size: 15.5px; }
.slider--grid .card-actions { gap: 10px; flex-wrap: wrap; }

@media (max-width: 1180px) {
  .slider--grid .cards-scroll { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 700px) {
  .slider--grid .cards-scroll { grid-template-columns: 1fr; }
}

/* --- «Другие программы» на странице программы --- */
.related-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 18px; flex-wrap: wrap; max-width: none; }
.related-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px; margin-top: 26px; }
.related-card {
  position: relative; display: flex; flex-direction: column; overflow: hidden;
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
  color: inherit; text-decoration: none;
  transition: transform .22s ease, box-shadow .22s ease, border-color .22s ease;
}
.related-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); border-color: var(--brand); }
.related-card__media { display: block; aspect-ratio: 16 / 9; background: var(--brand-soft); overflow: hidden; }
.related-card__media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s cubic-bezier(.2,.7,.2,1); }
.related-card:hover .related-card__media img { transform: scale(1.05); }
.related-card__body { display: flex; flex-direction: column; gap: 8px; padding: 18px 18px 20px; flex: 1; }
.related-card__cat { font-size: 11px; text-transform: uppercase; letter-spacing: .1em; font-weight: 700; color: var(--muted); }
.related-card__body strong { font-size: 17px; line-height: 1.32; }
.related-card__params {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px;
  margin-top: auto; padding-top: 12px; border-top: 1px solid var(--line);
}
.related-card__params span { display: grid; gap: 2px; font-size: 14px; font-weight: 650; line-height: 1.25; }
.related-card__params small {
  font-size: 10.5px; text-transform: uppercase; letter-spacing: .07em;
  color: var(--muted); font-weight: 600;
}
.related-card__arrow {
  position: absolute; top: 12px; right: 12px; width: 32px; height: 32px; border-radius: 50%;
  display: grid; place-items: center; font-size: 15px; color: var(--brand);
  background: rgba(255, 255, 255, .93);
  opacity: 0; transform: translateX(-4px); transition: opacity .2s ease, transform .2s ease;
}
.related-card:hover .related-card__arrow, .related-card:focus-visible .related-card__arrow { opacity: 1; transform: none; }

@media (max-width: 980px) { .related-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; } }
@media (max-width: 640px) { .related-grid { grid-template-columns: 1fr; } }

/* --- шапка раздела извещений --- */
.notice-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 24px; flex-wrap: wrap; }
.notice-head__text { min-width: 0; }
.notice-head__text .lead { max-width: 820px; margin-top: 12px; }
.notice-head .btn { flex: 0 0 auto; }

/* условия в карточках программ прижаты к низу — линия на одном уровне у всех карточек */
.card-body .params { margin-top: auto; }
.card-body .param-value { min-height: 2lh; }
.card-body > p { flex: 1 1 auto; }
