/* ==========================================================================
   Аргентум-ЭКО — фирменный стиль 2026
   Палитра — по логотипу: фирменный фиолетовый + серебристо-серый («аргентум» — серебро);
   мотив — параллельные полосы фирменного знака
   Шрифты системные — без загрузки со сторонних серверов.
   ========================================================================== */

:root {
    /* сайт спроектирован светлым: просим браузер не затемнять его принудительно (тёмная тема сайтов в Chrome для Android и др.) */
    color-scheme: only light;
    /* Фирменные цвета логотипа: фиолетовый (CMYK 100/100/0/0) и серебристо-серый «ЭКО» (K20) */
    --primary-900: #150a3f;   /* самый тёмный: верхняя строка, первый экран, код */
    --primary-800: #1f1060;
    --primary: #29166f;       /* фирменный фиолетовый: кнопки, ссылки */
    --primary-hover: #3b26a3;
    --primary-50: #f2f0fa;
    --primary-100: #e1dcf3;
    --accent: #5a43c9;      /* светлее фирменного: надписи-метки, маркеры, даты на светлом фоне (контраст 6.8:1) */
    --silver: #c1c1c1;      /* фирменный серый: акценты на тёмном фоне */
    --silver-50: #f3f3f6;
    --metal: linear-gradient(180deg, #fff 0%, #e8e8ec 55%, #c9c9cf 100%); /* «серебро» (argentum) — кнопки на тёмном фоне */
    --focus: #7b66e8;       /* рамка фокуса: заметна и на белом, и на тёмно-фиолетовом */
    --ink: #16112e;
    --text: #2c2942;
    --muted: #65627a;
    --line: #e5e3ee;
    --bg: #f6f5fa;
    --white: #fff;
    --ok: #1a8f5f;
    --warn: #b7791f;
    --err: #c53030;
    --radius: 16px;
    --radius-sm: 10px;
    --shadow-sm: 0 1px 2px rgba(26, 13, 79, .06);
    --shadow: 0 1px 2px rgba(26, 13, 79, .05), 0 10px 30px rgba(26, 13, 79, .08);
    --shadow-lg: 0 24px 60px rgba(26, 13, 79, .18);
    --container: 1240px;
    --gutter: clamp(16px, 4vw, 32px);
    --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", "Liberation Sans", sans-serif;
    --header-h: 76px;
}

*, *::before, *::after { box-sizing: border-box; }
html { font-size: 100%; -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px);
    /* страховка: случайный широкий элемент не должен растягивать страницу на телефоне (иначе браузер уменьшает масштаб
       и «прилипающие» к низу экрана блоки уезжают); на html не мешает липкой шапке */
    overflow-x: hidden; overflow-x: clip; }
body { margin: 0; font-family: var(--font); font-size: 1rem; line-height: 1.6; color: var(--text); background: var(--white); text-rendering: optimizeLegibility; -webkit-font-smoothing: antialiased; }
img { max-width: 100%; height: auto; border: 0; }
a { color: var(--primary); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--primary-hover); }
button { font: inherit; cursor: pointer; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 4px; }
h1, h2, h3, h4 { color: var(--ink); line-height: 1.2; letter-spacing: -.01em; margin: 0 0 .6em;
    overflow-wrap: anywhere; } /* слово шире экрана (крупный шрифт на узком телефоне) переносится, а не раздвигает страницу */
p { margin: 0 0 1em; }
.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 var(--gutter); }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.muted { color: var(--muted); }
.small { font-size: .875rem; }
.icon { width: 1.25em; height: 1.25em; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; flex: none; vertical-align: -.25em; }
[hidden] { display: none !important; }

/* спрятана выше экрана на всю свою высоту (при крупном шрифте она выше фиксированных 60px и выглядывала сверху) */
.skip-link { position: absolute; left: 16px; top: 0; transform: translateY(-110%); z-index: 1000; background: var(--primary-900); color: #fff; padding: 10px 16px; border-radius: 8px; }
.skip-link:focus { top: 12px; transform: none; color: #fff; }

/* ---------------------------------------------------------------- кнопки */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .5em; min-height: 44px; padding: .65em 1.25em; border-radius: 999px; border: 1.5px solid transparent;
    font-weight: 600; font-size: .95rem; line-height: 1.2; text-decoration: none; transition: background .2s, color .2s, border-color .2s, box-shadow .2s, transform .2s; white-space: nowrap; }
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: none; }
.btn-primary { background: var(--primary); color: #fff; box-shadow: 0 6px 18px rgba(41, 22, 111, .28); }
.btn-primary:hover { background: var(--primary-hover); color: #fff; }
/* главная кнопка на тёмном фоне — «серебро» (argentum) с фирменным фиолетовым текстом */
.btn-accent { background: var(--metal); color: var(--primary); border-color: rgba(255, 255, 255, .7); box-shadow: 0 8px 24px rgba(0, 0, 0, .28), inset 0 1px 0 #fff; }
.btn-accent:hover { background: #fff; color: var(--primary); }
.btn-outline { background: transparent; color: var(--primary); border-color: var(--primary-100); }
.btn-outline:hover { border-color: var(--primary); color: var(--primary-hover); background: var(--primary-50); }
.btn-ghost { background: rgba(255, 255, 255, .08); color: #fff; border-color: rgba(255, 255, 255, .35); }
.btn-ghost:hover { background: rgba(255, 255, 255, .16); color: #fff; }
.btn-light { background: #fff; color: var(--primary-900); }
.btn-light:hover { background: var(--silver-50); color: var(--primary-900); }
.btn-ghost-light { background: transparent; color: #fff; border-color: rgba(255, 255, 255, .5); }
.btn-ghost-light:hover { background: rgba(255, 255, 255, .12); color: #fff; }
.btn-link { background: none; color: var(--primary); padding-left: .5em; padding-right: .5em; }
.btn-sm { min-height: 38px; padding: .45em 1em; font-size: .875rem; }
.btn-lg { min-height: 54px; padding: .8em 1.6em; font-size: 1.02rem; }
.btn-block { width: 100%; }
.linklike { background: none; border: 0; padding: 0; color: inherit; text-decoration: underline; text-underline-offset: 3px; }
.icon-btn { display: inline-grid; place-items: center; width: 44px; height: 44px; border-radius: 12px; border: 1px solid var(--line); background: #fff; color: var(--primary-900); transition: .2s; }
.icon-btn:hover { border-color: var(--primary); color: var(--primary); }

/* ---------------------------------------------------------------- админ-панель на сайте */
.adminbar { display: flex; flex-wrap: wrap; gap: 6px 18px; align-items: center; padding: 6px var(--gutter); background: #111827; color: #d1d5db; font-size: .8rem; }
.adminbar a { color: #fff; text-decoration: none; display: inline-flex; align-items: center; gap: 4px; }
.adminbar-hello { display: inline-flex; align-items: center; gap: 4px; }
.adminbar-warn { background: #b45309; color: #fff; padding: 2px 8px; border-radius: 6px; }
.adminbar-info { background: #374151; padding: 2px 8px; border-radius: 6px; }

/* ---------------------------------------------------------------- верхняя строка */
.topbar { background: var(--primary-900); color: #d5d1ea; font-size: .85rem; }
.topbar-inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 40px; }
.topbar a { color: #fff; text-decoration: none; }
.topbar a:hover { color: var(--silver); }
.topbar-contacts { display: flex; flex-wrap: wrap; gap: 4px 22px; margin: 0; padding: 0; list-style: none; }
.topbar-contacts li { display: inline-flex; align-items: center; gap: 6px; }
.topbar-contacts a { white-space: nowrap; } /* номер не разрывается; при крупном шрифте переносится только название города */
.topbar-contacts .icon { color: var(--silver); }
.topbar-city { color: #a7a1cc; }
.topbar-right { display: flex; align-items: center; gap: 18px; }
.topbar-hours { display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; }
/* до 1239px режим работы в верхней строке не помещается (переносился в 3 строки) — он есть в подвале и контактах */
@media (max-width: 1239px) { .topbar-hours { display: none; } }
.a11y-toggle { display: inline-flex; align-items: center; gap: 6px; background: none; border: 1px solid rgba(255, 255, 255, .25); color: #fff; border-radius: 999px; padding: 4px 12px; font-size: .8rem; white-space: nowrap; }
.a11y-toggle:hover { border-color: var(--silver); }
.a11y-panel { background: #fff; color: var(--ink); border-bottom: 1px solid var(--line); }
.a11y-inner { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 28px; padding-top: 12px; padding-bottom: 12px; }
.a11y-group { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.a11y-group > span { font-weight: 600; margin-right: 4px; }
.a11y-panel button { min-height: 38px; min-width: 38px; padding: 4px 12px; border: 2px solid var(--ink); background: #fff; color: var(--ink); border-radius: 8px; font-weight: 700; }
.a11y-panel button[aria-pressed="true"] { background: var(--ink); color: #fff; }
.a11y-f2 { font-size: 1.2rem; } .a11y-f3 { font-size: 1.45rem; }
.a11y-panel .a11y-bw { background: #fff; color: #000; }
.a11y-panel .a11y-wb { background: #000; color: #fff; }
.a11y-reset { margin-left: auto; }

/* ---------------------------------------------------------------- шапка */
.header { position: sticky; top: 0; z-index: 50; background: rgba(255, 255, 255, .92); border-bottom: 1px solid transparent; transition: border-color .2s, box-shadow .2s; }
/* Размытие фона — на подложке, а не на самой шапке: backdrop-filter у шапки сделал бы её контейнером для position: fixed,
   и выезжающее меню сжалось бы до высоты шапки */
.header::before { content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none;
    -webkit-backdrop-filter: saturate(160%) blur(12px); backdrop-filter: saturate(160%) blur(12px); }
.header.is-scrolled { border-bottom-color: var(--line); box-shadow: 0 6px 24px rgba(26, 13, 79, .06); }
.header-inner { display: flex; align-items: center; gap: 24px; min-height: var(--header-h); }
.brand { display: inline-flex; align-items: center; text-decoration: none; flex: 0 1 auto; min-width: 0; }
.brand-img { max-height: 52px; width: auto; }
/* Фирменный логотип — вектор из макета CorelDRAW: полный (со строкой «научно-производственная компания»)
   и компактный, без неё, — для телефонов. Размер не зависит от шрифта (версия для слабовидящих) */
.brand-logo { display: block; width: 240px; max-width: 100%; height: auto; }
.brand-logo-compact { display: none; width: 220px; }

/* Меню правится в админке: если пунктов станет больше, чем помещается, оно переносится на вторую строку,
   а не уезжает за край и не обрезает кнопки шапки */
.nav { flex: 1; min-width: 0; display: flex; justify-content: center; }
.nav-drawer-head, .nav-drawer-foot { display: none; }
.nav-list { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 0; margin: 0; padding: 0; list-style: none; }
.nav-item { position: relative; }
.nav-link { display: inline-flex; align-items: center; gap: 4px; padding: 10px 8px; border-radius: 10px; border: 0; background: none; color: var(--ink); font-weight: 600; font-size: .92rem; text-decoration: none; white-space: nowrap; }
.nav-link:hover, .nav-item.has-sub:hover > .nav-link, .nav-link[aria-expanded="true"] { background: var(--primary-50); color: var(--primary); }
.nav-link.is-active { color: var(--primary); }
.nav-link.is-active::after { content: ""; position: absolute; left: 8px; right: 8px; bottom: 2px; height: 2px; background: var(--primary); border-radius: 2px; }
.nav-chev { width: 1em; height: 1em; transition: transform .2s; }
.nav-link[aria-expanded="true"] .nav-chev { transform: rotate(180deg); }
.nav-sub { position: absolute; top: calc(100% + 8px); left: 50%; transform: translate(-50%, 6px); min-width: 300px; max-width: min(720px, 90vw); background: #fff; border: 1px solid var(--line);
    border-radius: var(--radius); box-shadow: var(--shadow-lg); padding: 10px; opacity: 0; visibility: hidden; transition: opacity .18s, transform .18s, visibility .18s; z-index: 60; }
.nav-sub::before { content: ""; position: absolute; left: 0; right: 0; top: -12px; height: 12px; }
.nav-sub-wide { width: min(720px, 90vw); }
.nav-sub-wide .nav-sub-list { columns: 2; column-gap: 12px; }
.nav-item.has-sub:hover > .nav-sub, .nav-item.has-sub:focus-within > .nav-sub, .nav-item.is-open > .nav-sub { opacity: 1; visibility: visible; transform: translate(-50%, 0); }
.nav-sub-overview { display: flex; align-items: center; justify-content: space-between; gap: 8px; padding: 10px 12px; margin-bottom: 6px; border-radius: 10px; background: var(--bg); color: var(--primary-900); font-weight: 700; text-decoration: none; font-size: .9rem; }
.nav-sub-overview:hover { background: var(--primary-50); }
.nav-sub-list, .nav-sub3 { list-style: none; margin: 0; padding: 0; }
.nav-sub-list > li { break-inside: avoid; }
.nav-sub-link, .nav-sub-heading { display: block; padding: 8px 12px; border-radius: 8px; color: var(--text); text-decoration: none; font-size: .92rem; line-height: 1.35; }
a.nav-sub-link:hover, a.nav-sub-heading:hover { background: var(--primary-50); color: var(--primary); }
.nav-sub-link.is-active { color: var(--primary); font-weight: 600; }
.nav-sub-heading { font-weight: 700; color: var(--primary-900); }
.nav-sub-group { padding: 4px 0; }
.nav-sub3 { margin: 0 0 4px 12px; border-left: 2px solid var(--primary-100); }
.nav-sub3 .nav-sub-link { font-size: .88rem; padding: 6px 12px; }

.header-actions { display: flex; align-items: center; gap: 10px; flex: none; margin-left: auto; }
.nav-burger { display: none; }
.site-search { border-top: 1px solid var(--line); background: #fff; }
.site-search-form { display: flex; align-items: center; gap: 12px; padding-top: 14px; padding-bottom: 14px; }
.site-search-form .icon { color: var(--muted); }
.site-search-form input { flex: 1; border: 0; font: inherit; font-size: 1.1rem; padding: 10px 0; outline: none; background: transparent; }
.nav-backdrop { position: fixed; inset: 0; background: rgba(18, 10, 50, .5); z-index: 90; }

.header-cta { width: 44px; min-height: 44px; padding: 0; border-radius: 12px; }
.header-cta span { display: none; }
.topbar-cta { background: none; border: 0; padding: 0; color: var(--silver); font-weight: 600; font-size: .85rem; text-decoration: underline; text-underline-offset: 3px; white-space: nowrap; }
.topbar-cta:hover { color: #fff; }
/* Меню в строке шапки — с 1240px (шире контейнер не становится): подпись под логотипом в две строки,
   чтобы пункты меню помещались в одну строку с запасом */
@media (min-width: 1240px) {
    .header-inner { gap: 16px; }
    .nav-link { padding: 10px 7px; }
    .nav-link.is-active::after { left: 7px; right: 7px; }
    /* подменю крайних пунктов — от края пункта, а не по центру: широкое подменю иначе выходит за край окна */
    .nav-item.has-sub:nth-child(-n+2) > .nav-sub { left: 0; transform: translate(0, 6px); }
    .nav-item.has-sub:nth-last-child(-n+2) > .nav-sub { left: auto; right: 0; transform: translate(0, 6px); }
    .nav-item.has-sub:nth-child(-n+2):hover > .nav-sub, .nav-item.has-sub:nth-child(-n+2):focus-within > .nav-sub, .nav-item.has-sub.is-open:nth-child(-n+2) > .nav-sub,
    .nav-item.has-sub:nth-last-child(-n+2):hover > .nav-sub, .nav-item.has-sub:nth-last-child(-n+2):focus-within > .nav-sub, .nav-item.has-sub.is-open:nth-last-child(-n+2) > .nav-sub { transform: translate(0, 0); }
}
/* Меню в выезжающей панели — до 1239px: на меньших ширинах пункты меню, логотип и кнопки в одну строку не помещаются
   (граница продублирована в site.js — переменная mobile) */
@media (max-width: 1239px) {
    .nav-burger { display: inline-grid; }
    /* открытое меню со своим затемнением — поверх плашки cookie (150), но под модальными окнами (200) */
    .header.is-nav-open { z-index: 180; }
    /* Закрытая панель не сдвигается за край экрана (transform расширял страницу до ~720px на телефонах,
       из-за чего браузер уменьшал масштаб, а плашка cookie «уезжала» к середине страницы) — она обрезается clip-path */
    .nav { position: fixed; top: 0; right: 0; bottom: 0; width: min(420px, 92vw); z-index: 100; background: #fff; flex-direction: column; justify-content: flex-start;
        overflow-y: auto; box-shadow: var(--shadow-lg);
        -webkit-clip-path: inset(0 0 0 100%); clip-path: inset(0 0 0 100%); opacity: 0; visibility: hidden;
        transition: clip-path .28s ease, -webkit-clip-path .28s ease, opacity .2s ease, visibility 0s linear .28s; }
    .nav.is-open { -webkit-clip-path: inset(0); clip-path: inset(0); opacity: 1; visibility: visible;
        transition: clip-path .28s ease, -webkit-clip-path .28s ease, opacity .2s ease, visibility 0s; }
    .nav-drawer-head { display: flex; align-items: center; justify-content: space-between; padding: 16px 20px; border-bottom: 1px solid var(--line); }
    .nav-drawer-title { font-weight: 800; color: var(--primary-900); font-size: 1.1rem; }
    .nav-close { width: 44px; height: 44px; border: 1px solid var(--line); background: #fff; border-radius: 12px; display: grid; place-items: center; }
    .nav-list { flex-direction: column; flex-wrap: nowrap; align-items: stretch; padding: 8px 12px; gap: 0; }
    .nav-item { border-bottom: 1px solid var(--line); }
    .nav-link { width: 100%; justify-content: space-between; padding: 14px 8px; font-size: 1rem; }
    .nav-link.is-active::after { display: none; }
    .nav-sub { position: static; transform: none; opacity: 1; visibility: visible; box-shadow: none; border: 0; padding: 0 0 10px 8px; min-width: 0; max-width: none; width: auto; display: none; }
    .nav-sub::before { display: none; }
    .nav-item.is-open > .nav-sub { display: block; transform: none; }
    .nav-item.has-sub:hover > .nav-sub { transform: none; }
    .nav-sub-wide .nav-sub-list { columns: 1; }
    .nav-drawer-foot { display: flex; flex-direction: column; gap: 10px; padding: 20px; margin-top: auto; }
    .nav-drawer-mail { text-align: center; }
}
@media (max-width: 640px) {
    :root { --header-h: 64px; }
    .hide-sm { display: none !important; }
    .brand-logo-full { display: none; }
    .brand-logo-compact { display: block; }
    .topbar-inner { justify-content: center; flex-wrap: wrap; row-gap: 4px; }
    .topbar-contacts { justify-content: center; }
    .topbar-contacts li { flex-wrap: wrap; justify-content: center; }
    .a11y-toggle span { display: none; }
}
/* узкие телефоны (320–400px): логотип и три кнопки шапки помещаются в строку */
@media (max-width: 400px) {
    .header-inner { gap: 8px; }
    .header-actions { gap: 6px; }
    .header .icon-btn, .header-cta { width: 40px; height: 40px; min-height: 40px; }
}
@media (max-width: 360px) {
    :root { --gutter: 12px; }
}
/* узкие экраны: длинная надпись на кнопке переносится, а не вылезает за край (крупный шрифт) */
@media (max-width: 480px) { .btn { white-space: normal; max-width: 100%; text-align: center; } .cookie-actions .btn { white-space: nowrap; } }

/* ---------------------------------------------------------------- объявления */
.announce { position: relative; padding: 18px 0; background: var(--primary-50); color: var(--ink); }
.announce-inner { position: relative; display: flex; align-items: center; gap: 24px; }
.announce-media { flex: none; width: min(300px, 32%); border-radius: 12px; overflow: hidden; box-shadow: var(--shadow); }
.announce-media img { display: block; width: 100%; }
.announce-body { flex: 1; min-width: 0; padding-right: 40px; }
.announce-title { font-size: clamp(1.15rem, 2vw, 1.5rem); margin-bottom: .35em; }
.announce-text { font-size: .98rem; }
.announce-text p:last-child { margin-bottom: .6em; }
.announce-close { position: absolute; top: 0; right: var(--gutter); width: 38px; height: 38px; border-radius: 10px; border: 0; background: rgba(255, 255, 255, .6); color: inherit; display: grid; place-items: center; }
.announce-close:hover { background: #fff; }
.announce-info { background: linear-gradient(90deg, var(--primary-50), var(--silver-50)); }
.announce-success { background: #e8f7ef; }
.announce-warning { background: #fff5e0; }
.announce-festive { color: #fff; background: radial-gradient(1200px 300px at 10% 0%, rgba(255, 215, 128, .35), transparent 60%), linear-gradient(120deg, #7a0f1d, #b3172a 45%, #d9531e); }
.announce-festive::after { content: ""; position: absolute; inset: 0; pointer-events: none; opacity: .25;
    background-image: radial-gradient(circle at 20% 30%, #fff 1.2px, transparent 1.6px), radial-gradient(circle at 70% 60%, #fff 1px, transparent 1.4px), radial-gradient(circle at 40% 80%, #fff 1.4px, transparent 1.8px);
    background-size: 90px 90px, 130px 130px, 170px 170px; }
.announce-festive .announce-title, .announce-festive a:not(.btn) { color: #fff; }
.announce-festive .announce-text, .announce-festive .announce-text strong { color: #fff4e6; }
.announce-text.prose { font-size: .98rem; color: inherit; }
.announce-festive .announce-close { background: rgba(255, 255, 255, .18); color: #fff; }
.announce-image-only { padding: 16px 0; }
.announce-full { display: block; margin: 0 auto; max-width: 900px; border-radius: 14px; overflow: hidden; box-shadow: var(--shadow-lg); }
.announce-full img { display: block; width: 100%; }
@media (max-width: 720px) {
    .announce-inner { flex-direction: column; align-items: stretch; }
    .announce-media { width: 100%; }
    .announce-body { padding-right: 0; }
    .announce-close { top: -6px; }
}

/* ---------------------------------------------------------------- главная: первый экран */
.hero { position: relative; overflow: hidden; color: #fff; background: var(--primary-900); padding: clamp(48px, 7vw, 96px) 0 clamp(64px, 8vw, 104px); isolation: isolate; }
.hero-bg { position: absolute; inset: 0; z-index: -1;
    background: radial-gradient(900px 520px at 88% 12%, rgba(123, 102, 232, .32), transparent 62%), radial-gradient(760px 520px at 0% 100%, rgba(59, 38, 163, .5), transparent 62%), linear-gradient(135deg, #12093a 0%, #21105e 58%, #2e1a7a 100%); }
/* фирменный знак из параллельных полос — крупно, едва заметно, уходит за край */
.hero-bg::after { content: ""; position: absolute; top: 50%; right: -14%; width: min(1100px, 92vw); aspect-ratio: 169.3 / 100; transform: translateY(-46%); opacity: .07;
    background: url("../img/mark-white.svg") no-repeat center / contain; }
.hero-inner { display: grid; grid-template-columns: 1.05fr 1fr; gap: clamp(28px, 5vw, 64px); align-items: center; }
.eyebrow { display: inline-block; font-size: .8rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--accent); margin-bottom: .9em; }
.hero .eyebrow { color: var(--silver); }
.hero-title { font-size: clamp(2.2rem, 5.2vw, 4rem); font-weight: 800; color: #fff; letter-spacing: -.025em; line-height: 1.05; margin-bottom: .4em; }
.hero-lead { font-size: clamp(1.02rem, 1.5vw, 1.2rem); color: #dcd8ef; max-width: 36em; margin-bottom: 1.8em; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; }
.hero-visual { position: relative; }
.hero-card { background: #fff; border-radius: 22px; padding: 10px; box-shadow: 0 30px 80px rgba(0, 0, 0, .35); transform: rotate(-1.2deg); }
.hero-card img { display: block; border-radius: 14px; width: 100%; }
.hero-badge { position: absolute; display: flex; flex-direction: column; background: rgba(255, 255, 255, .96); color: var(--ink); border-radius: 14px; padding: 12px 16px; box-shadow: var(--shadow-lg); max-width: 220px; line-height: 1.2; }
.hero-badge strong { font-size: 1.6rem; color: var(--primary); letter-spacing: -.02em; }
.hero-badge span { font-size: .78rem; color: var(--muted); margin-top: 2px; }
.hero-badge-1 { left: -18px; bottom: -22px; }
.hero-badge-2 { right: -10px; top: -18px; }
/* нижний край первого экрана — три серебристые полосы, как в фирменном знаке */
.hero-stripes { position: absolute; left: 0; right: 0; bottom: 0; height: 16px;
    background: linear-gradient(180deg, transparent 0 2px, rgba(193, 193, 193, .35) 2px 4px, transparent 4px 8px, rgba(193, 193, 193, .65) 8px 10px, transparent 10px 14px, var(--silver) 14px 16px); }
@media (max-width: 900px) {
    .hero-inner { grid-template-columns: 1fr; }
    .hero-visual { max-width: 560px; margin: 12px auto 0; }
    .hero-badge-1 { left: 8px; } .hero-badge-2 { right: 8px; }
}

/* ---------------------------------------------------------------- цифры */
.stats { padding: 8px 0 24px; }
.stats-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.stat { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 20px 22px; box-shadow: var(--shadow-sm); display: flex; flex-direction: column; }
.stat-value { font-size: clamp(1.8rem, 3.2vw, 2.5rem); font-weight: 800; color: var(--primary-900); letter-spacing: -.03em; line-height: 1.1;
    background: linear-gradient(90deg, var(--primary), var(--accent)); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.stat-label { color: var(--muted); font-size: .9rem; margin-top: 4px; }
.stats-clients { text-align: center; color: var(--muted); margin: 22px auto 0; max-width: 860px; font-size: .95rem; }
@media (max-width: 860px) { .stats-list { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 400px) { .stats-list { gap: 10px; } .stat { padding: 14px; } .stat-label { hyphens: auto; overflow-wrap: break-word; } }

/* ---------------------------------------------------------------- секции */
.section { padding: clamp(48px, 7vw, 88px) 0; }
.section-sm { padding-top: 32px; padding-bottom: 64px; }
.section-tint { background: var(--bg); }
.section-title { font-size: clamp(1.6rem, 3vw, 2.3rem); font-weight: 800; letter-spacing: -.02em; }
.section-title-sm { font-size: clamp(1.2rem, 2vw, 1.5rem); }
.section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; margin-bottom: 28px; flex-wrap: wrap; }
.section-head .section-title { margin: 0; }
.link-more { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; text-decoration: none; }
.link-more .icon { transition: transform .2s; }
.link-more:hover .icon { transform: translateX(3px); }

.about-grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(28px, 5vw, 64px); align-items: start; }
.about-text .prose { margin-bottom: 20px; }
.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; counter-reset: s; }
.step-box { position: relative; display: flex; flex-direction: column; height: 100%; padding: 20px; border-radius: var(--radius); border: 1px solid var(--line); background: #fff; text-decoration: none; color: var(--text); transition: .2s; }
a.step-box:hover { border-color: var(--primary-100); box-shadow: var(--shadow); transform: translateY(-2px); }
.about-grid-single { grid-template-columns: minmax(0, 820px); }
.step-icon { width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center; background: var(--primary-50); color: var(--primary); margin-bottom: 12px; }
.step-icon .icon { width: 24px; height: 24px; }
.step-num { position: absolute; top: 18px; right: 20px; font-weight: 800; color: var(--primary-100); font-size: 1.4rem; }
.step-title { font-weight: 700; color: var(--ink); margin-bottom: 4px; }
.step-text { font-size: .9rem; color: var(--muted); }
@media (max-width: 900px) { .about-grid { grid-template-columns: 1fr; } }
@media (max-width: 520px) { .steps { grid-template-columns: 1fr; } }

.directions { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.direction { display: flex; flex-direction: column; padding: 24px; border-radius: var(--radius); background: #fff; border: 1px solid var(--line); position: relative; overflow: hidden; }
.direction::after { content: ""; position: absolute; right: -40px; bottom: -40px; width: 120px; height: 120px; border-radius: 50%; background: radial-gradient(circle, var(--primary-50), transparent 70%); }
.direction-icon { width: 52px; height: 52px; border-radius: 14px; display: grid; place-items: center; background: linear-gradient(135deg, var(--primary), var(--accent)); color: #fff; margin-bottom: 14px; }
.direction-icon .icon { width: 26px; height: 26px; }
.direction-title { font-weight: 700; color: var(--ink); font-size: 1.05rem; }
.direction-text { color: var(--muted); font-size: .92rem; margin-top: 4px; }
/* направление со ссылкой: кликабельна вся карточка */
.direction-link { text-decoration: none; }
.direction-link::before { content: ""; position: absolute; inset: 0; z-index: 1; border-radius: inherit; }
.direction:has(.direction-link) { transition: .2s; }
.direction:has(.direction-link:hover) { border-color: var(--primary-100); box-shadow: var(--shadow); transform: translateY(-2px); }
.direction-link:hover { color: var(--primary); }
@media (max-width: 900px) { .directions { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .directions { grid-template-columns: 1fr; } }

.equip-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.equip-card { display: flex; flex-direction: column; border-radius: var(--radius); border: 1px solid var(--line); background: #fff; overflow: hidden; text-decoration: none; color: var(--ink); transition: .2s; }
.equip-card:hover { box-shadow: var(--shadow); transform: translateY(-3px); color: var(--primary); }
.equip-media { aspect-ratio: 4 / 3; background: linear-gradient(180deg, var(--bg), #fff); display: grid; place-items: center; overflow: hidden; }
.equip-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.equip-card:hover .equip-media img { transform: scale(1.04); }
.equip-media .icon { width: 72px; height: 72px; color: var(--primary-100); }
.equip-title { padding: 14px 16px 18px; font-weight: 600; font-size: .95rem; line-height: 1.35; border-top: 1px solid var(--line); }
@media (max-width: 1000px) { .equip-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 720px) { .equip-grid { grid-template-columns: repeat(2, 1fr); } }

.cta-band { background: linear-gradient(120deg, var(--primary-800), var(--primary) 55%, var(--accent)); color: #fff; padding: clamp(36px, 5vw, 56px) 0; position: relative; overflow: hidden; }
/* фирменный знак из полос — крупно и едва заметно, как на первом экране */
.cta-band::before { content: ""; position: absolute; right: -60px; top: 50%; width: 520px; aspect-ratio: 169.3 / 100; transform: translateY(-50%); opacity: .08;
    background: url("../img/mark-white.svg") no-repeat center / contain; pointer-events: none; }
.cta-inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap; position: relative; }
.cta-text { max-width: 640px; }
.cta-text h2 { color: #fff; font-size: clamp(1.4rem, 2.6vw, 2rem); margin-bottom: .3em; }
.cta-text p { color: #dedaf2; margin: 0; }
.cta-actions { display: flex; gap: 12px; flex-wrap: wrap; }

/* ---------------------------------------------------------------- карточки */
.cards { display: grid; gap: 18px; }
.cards-news { grid-template-columns: repeat(4, 1fr); }
.cards-pages { grid-template-columns: repeat(3, 1fr); margin-top: 28px; }
.card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; display: flex; flex-direction: column; transition: .2s; }
.card:hover { box-shadow: var(--shadow); transform: translateY(-2px); }
.card-media { display: block; flex: none; aspect-ratio: 16 / 10; background: var(--bg); overflow: hidden; }
.card-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.card:hover .card-media img { transform: scale(1.03); }
.card-media-empty { display: grid; place-items: center; width: 100%; height: 100%; color: var(--primary-100); background: linear-gradient(135deg, var(--primary-50), var(--silver-50)); }
.card-media-empty .icon { width: 72px; height: 72px; }
/* Миниатюры новостей вписываются в рамку целиком (логотипы и баннеры любых пропорций), без обрезки;
   мелкие картинки увеличиваются не больше чем вдвое — пределы --mw/--mh задаёт img_limit() */
.card-news .card-media, .news-row-media { display: flex; align-items: center; justify-content: center; background: #fff; }
.card-news .card-media { border-bottom: 1px solid var(--line); }
.card-news .card-media img, .news-row-media img { width: min(100% - 28px, var(--mw, 100%)); height: min(100% - 28px, var(--mh, 100%)); object-fit: contain; }
.card-body { padding: 16px 18px 20px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.card-date { font-size: .8rem; color: var(--muted); font-weight: 600; text-transform: uppercase; letter-spacing: .04em; }
.card-title { font-size: 1rem; font-weight: 700; color: var(--ink); line-height: 1.35; margin: 0; }
.card-title a { color: inherit; text-decoration: none; }
.card-title a:hover { color: var(--primary); }
.card-text { color: var(--muted); font-size: .9rem; }
.card-more { margin-top: auto; padding-top: 6px; color: var(--primary); font-weight: 600; font-size: .9rem; display: inline-flex; align-items: center; gap: 4px; }
.card-page { text-decoration: none; color: inherit; }
.card-page .card-media img { object-fit: contain; padding: 12px; background: #fff; }
/* заглушка без картинки — той же высоты 16:10, что и картинки соседних карточек (не растягивается на свободное место) */
.card-media.card-media-empty { height: auto; }
/* раздел, где картинок нет ни у одной страницы: текстовые карточки с пиктограммой */
.cards-text .card-body { padding: 22px 22px 20px; gap: 8px; }
.card-icon { display: grid; place-items: center; width: 44px; height: 44px; margin-bottom: 6px; border-radius: 12px; flex: none;
    color: var(--primary); background: linear-gradient(135deg, var(--primary-50), var(--silver-50)); transition: .2s; }
.card-icon .icon { width: 30px; height: 30px; }
.card-page:hover .card-icon { color: #fff; background: linear-gradient(135deg, var(--primary), var(--accent)); }
.cards-text .card-title { font-size: 1.05rem; }
@media (max-width: 1000px) { .cards-news { grid-template-columns: repeat(2, 1fr); } .cards-pages { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .cards-news, .cards-pages { grid-template-columns: 1fr; } }

.consult-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
.consult-card { display: grid; grid-template-columns: auto 1fr; gap: 4px 16px; padding: 22px; border-radius: var(--radius); background: #fff; border: 1px solid var(--line); text-decoration: none; color: var(--text); transition: .2s; }
.consult-card:hover { box-shadow: var(--shadow); border-color: var(--primary-100); }
.consult-icon { grid-row: span 2; width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; background: var(--silver-50); color: var(--accent); }
.consult-title { font-weight: 700; color: var(--ink); line-height: 1.35; }
.consult-card:hover .consult-title { color: var(--primary); }
.consult-text { font-size: .9rem; color: var(--muted); }
@media (max-width: 760px) { .consult-grid { grid-template-columns: 1fr; } }

/* ---------------------------------------------------------------- отзывы */
.slider { position: relative; }
.slider-track { display: grid; grid-auto-flow: column; grid-auto-columns: calc((100% - 36px) / 3); gap: 18px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 4px 2px 18px; scrollbar-width: thin; }
.slider-track > * { scroll-snap-align: start; }
.slider-nav { display: flex; gap: 8px; justify-content: flex-end; }
@media (max-width: 1000px) { .slider-track { grid-auto-columns: calc((100% - 18px) / 2); } }
@media (max-width: 640px) { .slider-track { grid-auto-columns: 86%; } }

/* ---------------------------------------------------------------- галереи (главная, шорткод [[gallery]]) */
.gal { display: grid; gap: 12px; }
.gal-item { position: relative; display: block; overflow: hidden; border-radius: var(--radius); background: var(--primary-50); isolation: isolate; box-shadow: 0 0 0 1px var(--line); }
.gal-item img { display: block; width: 100%; height: 100%; object-fit: cover; border-radius: 0; transition: transform .6s cubic-bezier(.2, .7, .2, 1); }
.gal-item::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(21, 10, 63, 0) 45%, rgba(21, 10, 63, .78)); opacity: 0; transition: opacity .3s; pointer-events: none; }
.gal-item:hover img, .gal-item:focus-visible img { transform: scale(1.06); }
.gal-item:hover::after, .gal-item:focus-visible::after { opacity: 1; }
.gal-zoom { position: absolute; z-index: 1; top: 12px; right: 12px; width: 40px; height: 40px; border-radius: 12px; display: grid; place-items: center;
    background: rgba(255, 255, 255, .92); color: var(--primary); opacity: 0; transform: translateY(-6px); transition: .3s; }
.gal-zoom .icon { width: 20px; height: 20px; }
.gal-cap { position: absolute; z-index: 1; left: 16px; right: 16px; bottom: 14px; color: #fff; font-weight: 600; font-size: .92rem; line-height: 1.35;
    opacity: 0; transform: translateY(8px); transition: .3s; }
.gal-item:hover .gal-zoom, .gal-item:focus-visible .gal-zoom, .gal-item:hover .gal-cap, .gal-item:focus-visible .gal-cap { opacity: 1; transform: none; }
/* последняя плитка — «+N фото» в фирменном цвете */
.gal-more { position: absolute; z-index: 2; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
    background: linear-gradient(135deg, rgba(31, 16, 96, .82), rgba(90, 67, 201, .7)); color: #fff; font-weight: 800; font-size: clamp(1.5rem, 2.6vw, 2.2rem); line-height: 1; transition: background .3s; }
.gal-more small { font-size: .8rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--silver); }
.gal-item:hover .gal-more { background: linear-gradient(135deg, rgba(31, 16, 96, .68), rgba(90, 67, 201, .55)); }
/* мозаика: крупное фото слева и четыре поменьше */
.gal-mosaic { grid-template-columns: repeat(4, minmax(0, 1fr)); grid-auto-rows: clamp(140px, 16vw, 230px); }
.gal-mosaic .gal-item:first-child { grid-column: span 2; grid-row: span 2; }
.gal-mosaic.gal-n1 { grid-template-columns: minmax(0, 1fr); }
.gal-mosaic.gal-n1 .gal-item:first-child { grid-column: auto; }
.gal-mosaic.gal-n2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.gal-mosaic.gal-n2 .gal-item:first-child { grid-column: auto; }
.gal-mosaic.gal-n2 .gal-item { grid-row: span 2; }
.gal-mosaic.gal-n3 .gal-item:not(:first-child) { grid-column: span 2; }
.gal-mosaic.gal-n4 .gal-item:nth-child(2) { grid-column: span 2; }
/* плитка и лента */
.gal-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.gal-grid .gal-item, .gal-carousel .gal-item { aspect-ratio: 4 / 3; }
.gal-carousel .slider-track { grid-auto-columns: calc((100% - 54px) / 4); padding: 4px 1px 18px; scroll-padding: 0 1px; }
/* альбомы: обложка из трёх фото, название, число фото */
.albums { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.albums-n2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
/* один альбом — обложка слева, описание справа */
.albums-n1 { grid-template-columns: minmax(0, 1fr); }
.albums-n1 .album { flex-direction: row; }
.albums-n1 .album-cover { flex: 0 0 62%; }
.albums-n1 .album-body { justify-content: center; padding: 28px 32px; gap: 8px; }
.albums-n1 .album-title { font-size: 1.5rem; }
.album { display: flex; flex-direction: column; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; transition: .25s; }
.album:hover { border-color: var(--primary-100); box-shadow: var(--shadow); transform: translateY(-3px); }
.album-cover { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 1fr); grid-template-rows: repeat(2, minmax(0, 1fr)); gap: 4px; aspect-ratio: 16 / 10; padding: 4px; }
.album-cover .gal-item { border-radius: 12px; }
.album-cover .gal-item:first-child { grid-row: span 2; }
.album-cover.is-single { grid-template-columns: minmax(0, 1fr); grid-template-rows: minmax(0, 1fr); }
.album-cover .gal-zoom { top: 8px; right: 8px; width: 34px; height: 34px; border-radius: 10px; }
.album-body { flex: 1; display: flex; flex-direction: column; gap: 4px; padding: 14px 20px 20px; }
.album-count { display: inline-flex; align-items: center; gap: 6px; color: var(--accent); font-size: .78rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.album-count .icon { width: 16px; height: 16px; }
.album-title { margin: 0; font-size: 1.12rem; font-weight: 700; color: var(--ink); line-height: 1.3; }
.album-title a { color: inherit; text-decoration: none; }
.album-title a:hover { color: var(--primary); }
.album-text { margin: 0; color: var(--muted); font-size: .92rem; }
.album-link { margin-top: auto; padding-top: 8px; }
.gallery-embed { margin: 0 0 1.5em; }
.gallery-embed .gal-item img { margin: 0; }
@media (max-width: 1000px) {
    .gal-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
    .gal-carousel .slider-track { grid-auto-columns: calc((100% - 36px) / 3); }
    .albums { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 720px) {
    .gal { gap: 8px; }
    .gal-mosaic, .gal-mosaic.gal-n2 { grid-template-columns: repeat(2, minmax(0, 1fr)); grid-auto-rows: 38vw; }
    .gal-mosaic .gal-item:first-child { grid-column: span 2; grid-row: span 1; }
    .gal-mosaic.gal-n2 .gal-item, .gal-mosaic.gal-n3 .gal-item:not(:first-child), .gal-mosaic.gal-n4 .gal-item:nth-child(2) { grid-column: auto; grid-row: auto; }
    .gal-mosaic.gal-n4 .gal-item:last-child { grid-column: span 2; }
    .gal-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .gal-carousel .slider-track { grid-auto-columns: calc((100% - 18px) / 2); }
    .gal-item { border-radius: var(--radius-sm); }
}
@media (max-width: 560px) {
    .albums { grid-template-columns: minmax(0, 1fr); }
    .albums-n1 .album { flex-direction: column; }
    .albums-n1 .album-body { padding: 14px 20px 20px; }
    .albums-n1 .album-title { font-size: 1.12rem; }
    .gal-carousel .slider-track { grid-auto-columns: 80%; }
}
/* на сенсорных экранах наведения нет — подпись видна сразу */
@media (hover: none) {
    .gal-item::after { opacity: .9; background: linear-gradient(180deg, rgba(21, 10, 63, 0) 60%, rgba(21, 10, 63, .7)); }
    .gal-cap { opacity: 1; transform: none; font-size: .82rem; left: 10px; right: 10px; bottom: 8px; }
    .gal-item:not(:has(.gal-cap))::after { opacity: 0; }
}
.review-card { display: flex; gap: 16px; padding: 20px; border-radius: var(--radius); border: 1px solid var(--line); background: #fff; }
.review-letter { flex: none; width: 88px; align-self: flex-start; border-radius: 8px; overflow: hidden; border: 1px solid var(--line); box-shadow: var(--shadow-sm); background: #fff; }
.review-letter img { display: block; width: 100%; }
.review-body { position: relative; min-width: 0; }
.review-quote { width: 28px; height: 28px; color: var(--silver); }
.review-company { font-size: 1rem; margin: 6px 0; }
.review-company a { color: var(--ink); text-decoration: none; }
.review-company a:hover { color: var(--primary); }
.review-text { font-size: .9rem; color: var(--muted); margin: 0; }
.reviews-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; }
.review-tile { display: flex; gap: 18px; padding: 22px; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; }
.review-tile-media { flex: none; width: 120px; border-radius: 8px; overflow: hidden; border: 1px solid var(--line); align-self: flex-start; }
.review-tile-media img { display: block; width: 100%; }
.review-tile-body { min-width: 0; display: flex; flex-direction: column; }
.review-tile-body .link-more { margin-top: auto; }
.review-full { display: grid; grid-template-columns: 320px 1fr; gap: 32px; align-items: start; margin-bottom: 48px; }
.review-full-media { border-radius: 12px; overflow: hidden; border: 1px solid var(--line); box-shadow: var(--shadow); }
.review-full-media img { display: block; width: 100%; }
.review-full-text { font-size: 1.08rem; }
@media (max-width: 860px) { .reviews-grid, .review-full { grid-template-columns: 1fr; } .review-full-media { max-width: 360px; } }
@media (max-width: 520px) { .review-tile { flex-direction: column; } .review-tile-media { width: 140px; } }

.section-partners { padding-top: 24px; }
.section-partners .section-title { text-align: center; color: var(--muted); font-weight: 600; margin-bottom: 24px; }
.partners { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 12px; }
.partners li { display: grid; place-items: center; height: 76px; border-radius: 12px; border: 1px solid var(--line); background: #fff; padding: 8px; }
/* без mix-blend-mode: при затемнении сайта браузером (тёмная тема Android) «умножение» превращало логотипы в чёрные пятна */
.partners img { max-height: 56px; filter: grayscale(1); opacity: .75; transition: .2s; }
.partners li:hover img { filter: none; opacity: 1; }

/* ---------------------------------------------------------------- контакты */
.section-contact { background: linear-gradient(180deg, #fff, var(--bg)); }
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(24px, 4vw, 48px); align-items: start; }
.contact-form-card { background: #fff; border-radius: 20px; border: 1px solid var(--line); box-shadow: var(--shadow); padding: clamp(20px, 3vw, 32px); }
@media (max-width: 900px) { .contact-grid { grid-template-columns: 1fr; } }
.offices { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.office-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; }
.office-title { font-size: 1.05rem; margin-bottom: 2px; }
.office-city { color: var(--accent); font-weight: 600; font-size: .9rem; margin-bottom: 10px; }
.office-list { list-style: none; margin: 0 0 14px; padding: 0; display: grid; gap: 8px; }
.office-list li { display: flex; gap: 10px; align-items: flex-start; }
.office-list .icon { color: var(--primary); margin-top: 2px; }
.office-list a { text-decoration: none; font-weight: 600; }
.contact-box { border-radius: var(--radius); background: var(--primary-50); padding: 24px; }
.contact-box-title { font-size: 1.2rem; }
.contact-box-actions { display: flex; flex-wrap: wrap; gap: 10px; margin: 12px 0; }

/* ---------------------------------------------------------------- формы */
.form-title { font-size: 1.3rem; margin-bottom: 16px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.form-compact .form-grid { grid-template-columns: 1fr; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field-wide { grid-column: 1 / -1; }
.field label { font-weight: 600; font-size: .9rem; color: var(--ink); }
.req { color: var(--err); }
.field input, .field textarea, .field select, .search-page-form input { width: 100%; font: inherit; font-size: 1rem; color: var(--ink); background: #fff; border: 1.5px solid var(--line); border-radius: 12px; padding: 12px 14px; min-height: 48px; transition: border-color .2s, box-shadow .2s; }
.field textarea { resize: vertical; min-height: 110px; }
.field input:focus, .field textarea:focus, .field select:focus, .search-page-form input:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 4px rgba(41, 22, 111, .12); }
.field.has-error input, .field.has-error textarea, .field.has-error select { border-color: var(--err); }
.field-error { color: var(--err); font-size: .82rem; min-height: 0; }
.field-error:empty { display: none; }
.field-consent { margin-top: 14px; }
.check { display: flex; gap: 10px; align-items: flex-start; font-weight: 400 !important; font-size: .88rem !important; color: var(--text) !important; cursor: pointer; }
.check input { width: 20px; height: 20px; min-height: 0; margin: 1px 0 0; flex: none; accent-color: var(--primary); }
.form-actions { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; margin-top: 16px; }
.form-note { font-size: .8rem; color: var(--muted); }
.form.is-sending button[type="submit"] { opacity: .6; pointer-events: none; }
.form-result { margin-top: 14px; }
.hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; overflow: hidden; }
.alert { padding: 12px 16px; border-radius: 12px; font-size: .95rem; }
.alert-success { background: #e8f7ef; color: #11613f; border: 1px solid #bfe8d2; }
.alert-error { background: #fdecec; color: #8f1f1f; border: 1px solid #f5c2c2; }
@media (max-width: 560px) { .form-grid { grid-template-columns: 1fr; } }

/* ---------------------------------------------------------------- внутренние страницы */
.page-head { background: linear-gradient(135deg, var(--bg), var(--primary-50)); padding: 22px 0 30px; border-bottom: 1px solid var(--line); }
.breadcrumbs ol { list-style: none; margin: 0 0 12px; padding: 0; display: flex; flex-wrap: wrap; gap: 4px; font-size: .85rem; color: var(--muted); }
.breadcrumbs li:not(:last-child)::after { content: "/"; margin-left: 6px; color: #b5b0cb; }
.breadcrumbs a { color: var(--muted); text-decoration: none; }
.breadcrumbs a:hover { color: var(--primary); }
.page-title { font-size: clamp(1.7rem, 3.6vw, 2.6rem); font-weight: 800; letter-spacing: -.02em; margin: 0; }
.page-title-news { font-size: clamp(1.4rem, 3vw, 2.1rem); max-width: 30em; }
.page-lead { color: var(--muted); max-width: 48em; margin: 10px 0 0; }
.page-date { display: inline-flex; align-items: center; gap: 6px; color: var(--accent); font-weight: 700; font-size: .9rem; margin-bottom: 8px; }
.badge { display: inline-block; padding: 3px 10px; border-radius: 999px; background: var(--bg); font-size: .78rem; font-weight: 600; margin-top: 10px; }
.badge-warn { background: #fff1d6; color: #7a4d00; }
.page-layout { display: grid; grid-template-columns: 1fr; gap: 40px; padding-top: 36px; padding-bottom: 72px; }
.page-layout.has-aside { grid-template-columns: 280px minmax(0, 1fr); }
.page-layout.aside-right { grid-template-columns: minmax(0, 1fr) 300px; }
.page-body { min-width: 0; }
/* Боковая колонка «прилипает» целиком и не бывает выше экрана: блок «Нужна консультация?» всегда виден под списком,
   а длинный список раздела прокручивается внутри своей карточки. Раньше липкой была только карточка со списком —
   при прокрутке она наезжала на блок консультации. */
.page-aside { display: flex; flex-direction: column; gap: 16px; position: sticky; top: calc(var(--header-h) + 16px); align-self: start;
    max-height: calc(100vh - var(--header-h) - 32px); max-height: calc(100dvh - var(--header-h) - 32px); }
.aside-card { border: 1px solid var(--line); border-radius: var(--radius); padding: 16px; background: #fff; display: flex; flex-direction: column; min-height: 0; }
.aside-card > ul { min-height: 0; overflow-y: auto; scrollbar-width: thin; scrollbar-color: var(--primary-100) transparent; }
.aside-cta { flex: none; }
.aside-title { display: block; font-weight: 800; color: var(--primary-900); text-decoration: none; padding: 4px 8px 10px; border-bottom: 1px solid var(--line); margin-bottom: 8px; }
.aside-nav { list-style: none; margin: 0; padding: 0; }
.aside-nav a { display: block; padding: 8px 10px; border-radius: 8px; color: var(--text); text-decoration: none; font-size: .92rem; line-height: 1.35; }
.aside-nav a:hover { background: var(--primary-50); color: var(--primary); }
.aside-nav a.is-active { background: var(--primary); color: #fff; }
.aside-cta { border-radius: var(--radius); padding: 20px; background: linear-gradient(135deg, var(--primary-800), var(--primary)); color: #dedaf2; }
.aside-cta-title { color: #fff; font-weight: 800; font-size: 1.1rem; margin-bottom: 6px; }
.aside-cta .btn-primary { background: var(--metal); color: var(--primary); box-shadow: none; }
.aside-cta .btn-primary:hover { background: #fff; color: var(--primary); }
.aside-news { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.aside-news time { display: block; font-size: .78rem; color: var(--muted); }
.aside-news a { text-decoration: none; color: var(--ink); font-size: .92rem; line-height: 1.35; }
.aside-news a:hover { color: var(--primary); }
.page-form { margin-top: 40px; padding: 28px; border-radius: 20px; background: var(--bg); }
/* блок «Консультация» (текст — в настройках; включается у страницы или шорткодом [[consult]]) */
.consult-block { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 18px; align-items: start; margin: 36px 0 8px; padding: 24px 26px;
    border-radius: var(--radius); border: 1px solid var(--primary-100); background: linear-gradient(135deg, var(--primary-50), var(--silver-50)); }
.consult-block-icon { display: grid; place-items: center; width: 48px; height: 48px; border-radius: 14px; background: #fff; color: var(--primary); box-shadow: var(--shadow-sm); }
.consult-block-icon .icon { width: 26px; height: 26px; }
.consult-block-title { margin: 2px 0 8px; font-size: 1.12rem; font-weight: 700; color: var(--ink); }
.consult-block .prose > :first-child { margin-top: 0; }
.consult-block .prose > :last-child { margin-bottom: 0; }
.consult-block .prose ul { margin-bottom: 0; }
.consult-block a[href^="tel:"] { white-space: nowrap; font-weight: 600; }
.prose .consult-block { margin: 1.5em 0; }
@media (max-width: 560px) { .consult-block { grid-template-columns: minmax(0, 1fr); gap: 12px; padding: 20px 18px; } }
.doc-meta { color: var(--muted); font-size: .9rem; }
@media (max-width: 960px) {
    .page-layout.has-aside, .page-layout.aside-right { grid-template-columns: 1fr; }
    .page-layout.has-aside .page-aside { order: 2; }
    .page-aside { position: static; max-height: none; }
    .aside-card > ul { overflow: visible; }
}

/* ---------------------------------------------------------------- типографика контента */
.prose { font-size: 1.02rem; line-height: 1.7; color: var(--text); overflow-wrap: break-word; }
/* колонки сеток не шире экрана, даже если в тексте длинное слово или ссылка (крупный шрифт на узком телефоне) */
.hero-inner > *, .about-grid > *, .contact-grid > *, .consult-grid > *, .reviews-grid > *, .form-grid > *, .post-nav > *, .page-layout > * { min-width: 0; }
.prose > :first-child { margin-top: 0; }
.prose h2 { font-size: clamp(1.35rem, 2.4vw, 1.75rem); margin: 1.8em 0 .6em; }
.prose h3 { font-size: 1.2rem; margin: 1.6em 0 .5em; }
.prose h4 { font-size: 1.05rem; margin: 1.4em 0 .5em; }
.prose ul, .prose ol { padding-left: 1.4em; margin: 0 0 1.2em; }
.prose li { margin: .3em 0; }
.prose ul li::marker { color: var(--accent); }
.prose ol li::marker { color: var(--primary); font-weight: 700; }
.prose blockquote { margin: 1.5em 0; padding: 14px 20px; border-left: 4px solid var(--accent); background: var(--primary-50); border-radius: 0 12px 12px 0; }
.prose hr { border: 0; height: 1px; background: var(--line); margin: 2em 0; }
.prose img { border-radius: 10px; }
.prose code { background: var(--bg); padding: 2px 6px; border-radius: 6px; font-size: .9em; }
.prose pre { background: var(--primary-900); color: #ebe8f7; padding: 16px; border-radius: 12px; overflow-x: auto; }
.prose mark { background: #fff3b0; padding: 0 2px; }
.prose a.file-link::before { content: "📄 "; }
.table-wrap { overflow-x: auto; margin: 0 0 1.5em; border: 1px solid var(--line); border-radius: 12px; -webkit-overflow-scrolling: touch; }
.table-wrap table { width: 100%; border-collapse: collapse; font-size: .92rem; min-width: 480px; }
.table-wrap th, .table-wrap td { padding: 10px 14px; border-bottom: 1px solid var(--line); border-right: 1px solid var(--line); text-align: left; vertical-align: top; }
.table-wrap th:last-child, .table-wrap td:last-child { border-right: 0; }
.table-wrap tr:last-child td { border-bottom: 0; }
.table-wrap thead th, .table-wrap tr:first-child td[colspan] { background: var(--primary-50); color: var(--primary-900); font-weight: 700; }
.table-wrap tbody tr:nth-child(even) td { background: #fcfbfe; }
.requisites tbody th { width: 38%; background: var(--bg); color: var(--muted); font-weight: 600; }
.requisites thead th:first-child { width: 28%; }
.requisites thead th:nth-child(2) { width: 14%; }
.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 12px; margin: 0 0 1.5em; }
.gallery-item { margin: 0; border-radius: 12px; overflow: hidden; background: var(--bg); border: 1px solid var(--line); aspect-ratio: 4 / 3; display: grid; place-items: center; }
.gallery-item a { display: block; width: 100%; height: 100%; }
.gallery-item img { width: 100%; height: 100%; object-fit: cover; border-radius: 0; transition: transform .35s; }
.gallery-item a:hover img { transform: scale(1.04); }
.gallery-item a[target="_blank"] img { object-fit: contain; padding: 10px; background: #fff; filter: grayscale(.2); }
.callout { margin: 1.5em 0; padding: 16px 20px; border-radius: 12px; border: 1px solid var(--primary-100); background: var(--primary-50); }
.callout > :last-child { margin-bottom: 0; }
.callout-title { font-weight: 700; color: var(--ink); }
.callout-warning { background: #fff7e6; border-color: #f7d9a0; }
.callout-success { background: #e9f7ef; border-color: #bfe8d2; }
.ph-empty { background: #fff1d6; color: #7a4d00; border-radius: 4px; padding: 0 4px; font-size: .9em; }
.prose .office-title, .prose .contact-box-title, .prose .form-title { margin-top: 0; }
.prose .office-list { padding-left: 0; margin: 0 0 14px; }
.prose .office-list li { margin: 0; }
.prose .offices, .prose .contact-box, .prose .form { margin-bottom: 1.5em; }
.prose .form { padding: clamp(18px, 3vw, 28px); border-radius: 20px; background: var(--bg); }
.prose-legal { font-size: .98rem; }
.prose-legal h2 { font-size: 1.25rem; }

/* новости */
.news-list { display: grid; gap: 18px; }
.news-row { display: grid; grid-template-columns: 240px 1fr; gap: 24px; padding: 18px; border: 1px solid var(--line); border-radius: var(--radius); background: #fff; transition: .2s; }
.news-row:hover { box-shadow: var(--shadow); }
.news-row-media { aspect-ratio: 16 / 10; border-radius: 10px; overflow: hidden; border: 1px solid var(--line); }
.news-row-title { font-size: 1.15rem; margin: 4px 0 6px; }
.news-row-title a { color: var(--ink); text-decoration: none; }
.news-row-title a:hover { color: var(--primary); }
.news-row-text { color: var(--muted); margin: 0; font-size: .95rem; }
@media (max-width: 640px) { .news-row { grid-template-columns: 1fr; } }
.news-cover { display: block; float: right; width: min(320px, 45%, var(--mw, 320px)); margin: 0 0 16px 24px; border-radius: 12px; overflow: hidden; border: 1px solid var(--line); background: #fff; }
.news-cover img { display: block; width: 100%; height: auto; }
@media (max-width: 640px) { .news-cover { float: none; width: min(100%, var(--mw, 100%)); margin: 0 0 16px; } }
.post-nav { clear: both; display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 40px; padding-top: 24px; border-top: 1px solid var(--line); }
.post-nav a { display: flex; flex-direction: column; gap: 4px; padding: 14px; border-radius: 12px; border: 1px solid var(--line); text-decoration: none; color: var(--ink); font-size: .92rem; }
.post-nav a span { color: var(--primary); font-weight: 600; font-size: .82rem; display: inline-flex; align-items: center; gap: 4px; }
.post-nav-next { text-align: right; align-items: flex-end; }
.pagination { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; margin-top: 36px; }
.pagination a, .pagination span { min-width: 44px; height: 44px; display: inline-grid; place-items: center; border-radius: 12px; border: 1px solid var(--line); text-decoration: none; color: var(--ink); font-weight: 600; }
.pagination span[aria-current] { background: var(--primary); border-color: var(--primary); color: #fff; }
.pagination .gap { border: 0; }

/* поиск */
.search-page-form { display: flex; gap: 10px; margin-top: 18px; max-width: 640px; }
.search-page-form input { flex: 1; }
.search-results { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.search-results li { padding: 16px 18px; border: 1px solid var(--line); border-radius: 12px; }
.search-type { font-size: .75rem; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); font-weight: 700; }
.search-title { display: block; font-weight: 700; font-size: 1.08rem; margin: 2px 0 6px; }
.search-results p { margin: 0; color: var(--muted); font-size: .92rem; }
.search-results mark { background: #fff3b0; color: inherit; }
.sitemap-tree ul { list-style: none; padding-left: 1.2em; }
.sitemap-tree > ul { padding-left: 0; }
.sitemap-tree li { margin: .35em 0; }
.error-page { text-align: center; max-width: 640px; }
.error-code { font-size: 6rem; font-weight: 900; line-height: 1; margin: 0; background: linear-gradient(90deg, var(--primary), var(--accent)); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; }
.error-page .search-page-form { margin: 24px auto; }

/* ---------------------------------------------------------------- подвал */
.footer { background: #110834; color: #b4aed3; font-size: .92rem; margin-top: 0; }
.footer a { color: #e6e3f5; text-decoration: none; }
.footer a:hover { color: var(--silver); }
/* minmax(0, …) — колонки могут сжиматься уже содержимого (иначе длинные слова и телефоны раздвигают страницу) */
.footer-grid { display: grid; grid-template-columns: minmax(0, 1.5fr) repeat(3, minmax(0, 1fr)) minmax(0, 1.2fr); gap: 32px; padding-top: 56px; padding-bottom: 40px; }
.footer-grid > * { min-width: 0; overflow-wrap: anywhere; }
.footer-about { margin: 16px 0; }
.footer-legal { font-size: .82rem; color: #9791bd; display: grid; gap: 2px; }
.footer-title { color: #fff; font-size: .95rem; font-weight: 700; margin-bottom: 14px; }
.footer-col ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.footer-contacts { display: flex; flex-direction: column; gap: 10px; }
.footer-office-title { color: #fff; font-weight: 600; }
.footer-office .muted { color: #9791bd; font-size: .85rem; }
.footer .muted { color: #9791bd; }
.footer-bottom { border-top: 1px solid rgba(255, 255, 255, .08); }
.footer-bottom-inner { display: flex; justify-content: space-between; gap: 12px 24px; flex-wrap: wrap; padding-top: 18px; padding-bottom: 18px; font-size: .84rem; }
.footer-links { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px 18px; }
.footer-links button { color: #e6e3f5; font-size: inherit; }
.footer-notice { display: flex; align-items: center; gap: 8px; padding-bottom: 18px; font-size: .84rem; color: #d4d4da; }
@media (max-width: 1100px) { .footer-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } .footer-brand { grid-column: 1 / -1; } }
@media (max-width: 640px) { .footer-grid { grid-template-columns: minmax(0, 1fr); gap: 24px; } }
.to-top { position: fixed; right: 18px; bottom: 18px; z-index: 40; width: 48px; height: 48px; border-radius: 14px; border: 0; background: var(--primary); color: #fff; display: grid; place-items: center; box-shadow: var(--shadow-lg); }

/* ---------------------------------------------------------------- модальное окно, cookie, лайтбокс */
.modal { position: fixed; inset: 0; z-index: 200; display: grid; place-items: center; padding: 16px; }
.modal-backdrop { position: absolute; inset: 0; background: rgba(14, 8, 40, .6); backdrop-filter: blur(2px); }
.modal-dialog { position: relative; width: min(480px, 100%); max-height: calc(100vh - 32px); overflow-y: auto; background: #fff; border-radius: 22px; padding: 28px; box-shadow: var(--shadow-lg); animation: pop .22s ease; }
.modal-close { position: absolute; top: 14px; right: 14px; width: 40px; height: 40px; border-radius: 12px; border: 1px solid var(--line); background: #fff; display: grid; place-items: center; }
.modal-title { font-size: 1.4rem; padding-right: 40px; }
@keyframes pop { from { opacity: 0; transform: translateY(10px) scale(.98); } }
/* прокрутка под меню и модальными окнами блокируется на html: у html задан overflow-x, поэтому overflow у body
   не переходит к окну — он не блокировал бы прокрутку и «отклеивал» бы липкую шапку */
html.modal-open { overflow: hidden; }

.cookie { position: fixed; left: 16px; right: 16px; bottom: 16px; z-index: 150; display: flex; justify-content: center; pointer-events: none; }
.cookie-inner { pointer-events: auto; width: min(980px, 100%); background: #fff; border: 1px solid var(--line); border-radius: 18px; box-shadow: var(--shadow-lg); padding: 18px 20px; display: flex; gap: 20px; align-items: center; }
.cookie-text { flex: 1; font-size: .9rem; }
.cookie-text p { margin: 0; }
.cookie-options { display: grid; gap: 8px; margin-top: 12px; }
.cookie-actions { display: flex; flex-wrap: wrap; gap: 8px; justify-content: flex-end; flex: none; max-width: 360px; }
@media (max-width: 760px) { .cookie-inner { flex-direction: column; align-items: stretch; } .cookie-actions { max-width: none; justify-content: stretch; } .cookie-actions .btn { flex: 1; } }
/* Телефоны: компактная плашка у нижнего края экрана, не перекрывает контент */
@media (max-width: 640px) {
    .cookie { left: 8px; right: 8px; bottom: calc(8px + env(safe-area-inset-bottom, 0px)); }
    .cookie-inner { padding: 12px 14px; gap: 10px; border-radius: 14px; max-height: 45vh; overflow-y: auto; }
    .cookie-text { font-size: .82rem; line-height: 1.45; }
    .cookie-actions { gap: 6px; }
    .cookie-actions .btn { min-height: 38px; padding: .4em .8em; font-size: .82rem; }
    /* уведомление о технических cookie: текст и кнопка «Понятно» в одну строку */
    .cookie[data-mode="notice"] .cookie-inner { flex-direction: row; align-items: center; }
    .cookie[data-mode="notice"] .cookie-actions { flex: none; }
    .cookie[data-mode="notice"] .cookie-actions .btn { flex: none; }
}

.lightbox { position: fixed; inset: 0; z-index: 300; background: rgba(12, 7, 32, .92); display: flex; align-items: center; justify-content: center; padding: 56px 64px; }
.lightbox-figure { margin: 0; max-width: 100%; max-height: 100%; display: flex; flex-direction: column; align-items: center; }
.lightbox-figure img { max-width: 100%; max-height: calc(100vh - 140px); border-radius: 8px; box-shadow: 0 20px 60px rgba(0, 0, 0, .5); background: #fff; }
.lightbox-figure figcaption { color: #cbd5e1; margin-top: 10px; font-size: .9rem; text-align: center; }
.lightbox button { position: absolute; width: 48px; height: 48px; border-radius: 14px; border: 0; background: rgba(255, 255, 255, .12); color: #fff; display: grid; place-items: center; }
.lightbox button:hover { background: rgba(255, 255, 255, .24); }
.lightbox-close { top: 14px; right: 14px; }
.lightbox-prev { left: 12px; top: 50%; transform: translateY(-50%); }
.lightbox-next { right: 12px; top: 50%; transform: translateY(-50%); }
@media (max-width: 640px) { .lightbox { padding: 60px 8px; } .lightbox-prev, .lightbox-next { top: auto; bottom: 10px; transform: none; } }

/* ---------------------------------------------------------------- страница-заглушка */
.maint-body { min-height: 100vh; display: grid; place-items: center; background: radial-gradient(900px 500px at 80% 10%, rgba(123, 102, 232, .25), transparent 60%), linear-gradient(135deg, #12093a, #21105e 60%, #2e1a7a); padding: 24px; }
.maint { width: 100%; display: grid; place-items: center; }
.maint-card { width: min(640px, 100%); background: #fff; border-radius: 24px; padding: clamp(24px, 5vw, 48px); box-shadow: 0 40px 100px rgba(0, 0, 0, .35); text-align: center; }
.maint-card .brand { justify-content: center; margin-bottom: 28px; }
.maint-icon { width: 72px; height: 72px; margin: 0 auto 18px; border-radius: 20px; display: grid; place-items: center; background: linear-gradient(135deg, var(--primary), var(--accent)); color: #fff; }
.maint-icon .icon { width: 34px; height: 34px; }
.maint-card h1 { font-size: clamp(1.5rem, 3vw, 2rem); }
.maint-contacts { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin: 20px 0 12px; }
.maint-legal { font-size: .8rem; color: var(--muted); margin: 0; }

/* ---------------------------------------------------------------- соцсети и мессенджеры */
.sicon { width: 20px; height: 20px; fill: currentColor; flex: none; display: block; }
.sicon-img { width: 22px; height: 22px; object-fit: contain; }
.social { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.social-mark { font-size: .75em; font-weight: 700; line-height: 1; color: var(--accent); }
/* круглые кнопки: подвал, верхняя строка, мобильное меню; при наведении — фирменный цвет сети */
.social-btn { position: relative; display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; color: #e6e3f5; background: rgba(255, 255, 255, .08);
    border: 1px solid rgba(255, 255, 255, .14); text-decoration: none; transition: background .2s, color .2s, border-color .2s, transform .2s; }
.social-btn:hover, .social-btn:focus-visible { background: var(--brand, var(--primary)); border-color: transparent; color: #fff; transform: translateY(-2px); }
.social-btn .social-mark { position: absolute; top: -3px; right: -4px; font-size: .8rem; color: #d4d4da; }
.footer-social { margin: 0 0 18px; }
.footer-social-title { color: #fff; font-weight: 600; margin-bottom: 10px; }
.topbar-social { gap: 2px; flex-wrap: nowrap; }
/* верхняя строка заполнена контактами почти целиком: мессенджеры показываются на широких экранах вместо режима работы
   (он есть в подвале и блоках контактов), на остальных — в подвале и мобильном меню (оно до 1239px) */
@media (max-width: 1239px) { .topbar-social { display: none; } }
@media (min-width: 1240px) { .topbar-hours-narrow { display: none; } }
.topbar-social .social-btn { width: 30px; height: 30px; background: transparent; border-color: transparent; color: #d5d1ea; }
.topbar-social .social-btn:hover { color: #fff; transform: none; }
.topbar-social .sicon, .topbar-social .sicon-img { width: 17px; height: 17px; }
.topbar-social .social-mark { top: 0; right: -1px; }
.nav-drawer-social { margin-top: 4px; }
.nav-drawer-social .social-btn { color: var(--primary-900); background: var(--bg); border-color: var(--line); }
.nav-drawer-social .social-mark { color: var(--primary); }
/* плашки со способами связи: контакты, заглушка техработ, замена форм */
.social-chips { gap: 10px; }
.social-chip { display: inline-flex; align-items: center; gap: 10px; padding: 7px 16px 7px 7px; border-radius: 999px; border: 1px solid var(--line); background: #fff;
    color: var(--ink); text-decoration: none; line-height: 1.25; transition: border-color .2s, box-shadow .2s, transform .2s; }
.social-chip:hover, .social-chip:focus-visible { border-color: var(--brand, var(--primary)); box-shadow: var(--shadow-sm); transform: translateY(-1px); }
.social-chip-icon { display: grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; background: var(--brand, var(--primary)); color: #fff; flex: none; }
.social-chip-icon .sicon { width: 19px; height: 19px; }
.social-chip-text { display: grid; }
.social-chip-title { font-weight: 700; font-size: .92rem; }
.social-chip-title .social-mark { color: var(--primary); margin-left: 1px; }
.social-chip-label { font-size: .8rem; color: var(--muted); }
.contacts-social { margin-top: 24px; }
.contacts-social-title { font-size: 1.05rem; margin: 0 0 12px; }
.contact-box-sub { margin: 14px 0 10px; font-weight: 600; }
.contact-box .social-chip { background: #fff; }
.social-notes { display: grid; gap: 4px; padding-bottom: 18px; font-size: .78rem; line-height: 1.45; color: #9791bd; }
.social-notes p { margin: 0; }
.social-notes .social-mark { font-size: 1em; margin-right: 2px; }
/* заглушка техработ */
.maint-social { justify-content: center; margin: 0 0 16px; }
.maint-social .social-chip { text-align: left; }
.maint-notes { color: var(--muted); padding: 12px 0 0; }
.maint-access { margin-top: 22px; padding-top: 16px; border-top: 1px solid var(--line); font-size: .9rem; }
.maint-access summary { display: inline-flex; align-items: center; gap: 6px; cursor: pointer; color: var(--muted); list-style: none; }
.maint-access summary::-webkit-details-marker { display: none; }
.maint-access summary:hover { color: var(--primary); }
.maint-access-form { display: flex; flex-wrap: wrap; gap: 8px; justify-content: center; margin-top: 12px; }
.maint-access-form input { flex: 1 1 200px; max-width: 280px; min-height: 44px; padding: 8px 14px; border: 1px solid var(--line); border-radius: 10px; font: inherit; }
.maint-error { color: #b42318; margin: 10px 0 0; font-weight: 600; }
.adminbar-form { display: inline; margin: 0; }
.adminbar .linklike { color: #fff; text-decoration: underline; font-size: inherit; }
.adminbar-warn .icon { width: 1em; height: 1em; vertical-align: -.1em; }

/* ---------------------------------------------------------------- версия для слабовидящих */
html.a11y-font-2 { font-size: 125%; }
html.a11y-font-3 { font-size: 150%; }
html.a11y-font-2 .nav-sub-wide .nav-sub-list, html.a11y-font-3 .nav-sub-wide .nav-sub-list { columns: 1; }
html.a11y-contrast-high body, html.a11y-contrast-high .header, html.a11y-contrast-high .page-head, html.a11y-contrast-high .section-tint, html.a11y-contrast-high .card,
html.a11y-contrast-high .stat, html.a11y-contrast-high .step-box, html.a11y-contrast-high .direction, html.a11y-contrast-high .footer, html.a11y-contrast-high .topbar,
html.a11y-contrast-high .hero, html.a11y-contrast-high .cta-band, html.a11y-contrast-high .announce, html.a11y-contrast-high .aside-cta, html.a11y-contrast-high .equip-card,
html.a11y-contrast-high .consult-card, html.a11y-contrast-high .album, html.a11y-contrast-high .review-card, html.a11y-contrast-high .office-card, html.a11y-contrast-high .contact-form-card, html.a11y-contrast-high .section-contact {
    background: #fff !important; color: #000 !important; box-shadow: none !important; border-color: #000 !important; }
html.a11y-contrast-high .hero-bg, html.a11y-contrast-high .hero-stripes, html.a11y-contrast-high .announce::after, html.a11y-contrast-high .cta-band::before { display: none; }
html.a11y-contrast-high *, html.a11y-contrast-high *::before { color: #000 !important; -webkit-text-fill-color: #000 !important; text-shadow: none !important; }
html.a11y-contrast-high a { text-decoration: underline !important; }
html.a11y-contrast-high .btn { background: #fff !important; border: 2px solid #000 !important; }
html.a11y-contrast-inverse body, html.a11y-contrast-inverse .header, html.a11y-contrast-inverse .page-head, html.a11y-contrast-inverse .section-tint, html.a11y-contrast-inverse .card,
html.a11y-contrast-inverse .stat, html.a11y-contrast-inverse .step-box, html.a11y-contrast-inverse .direction, html.a11y-contrast-inverse .footer, html.a11y-contrast-inverse .topbar,
html.a11y-contrast-inverse .hero, html.a11y-contrast-inverse .cta-band, html.a11y-contrast-inverse .announce, html.a11y-contrast-inverse .aside-cta, html.a11y-contrast-inverse .equip-card,
html.a11y-contrast-inverse .consult-card, html.a11y-contrast-inverse .album, html.a11y-contrast-inverse .review-card, html.a11y-contrast-inverse .office-card, html.a11y-contrast-inverse .contact-form-card,
html.a11y-contrast-inverse .section-contact, html.a11y-contrast-inverse .nav, html.a11y-contrast-inverse .nav-sub, html.a11y-contrast-inverse .field input, html.a11y-contrast-inverse .field textarea,
html.a11y-contrast-inverse .table-wrap th, html.a11y-contrast-inverse .table-wrap td, html.a11y-contrast-inverse .modal-dialog, html.a11y-contrast-inverse .cookie-inner, html.a11y-contrast-inverse .a11y-panel,
html.a11y-contrast-inverse .icon-btn, html.a11y-contrast-inverse .nav-burger, html.a11y-contrast-inverse .nav-close, html.a11y-contrast-inverse .aside-card {
    background: #000 !important; color: #fff !important; box-shadow: none !important; border-color: #fff !important; }
html.a11y-contrast-inverse .hero-bg, html.a11y-contrast-inverse .hero-stripes, html.a11y-contrast-inverse .announce::after, html.a11y-contrast-inverse .cta-band::before { display: none; }
html.a11y-contrast-inverse *, html.a11y-contrast-inverse *::before { color: #fff !important; -webkit-text-fill-color: #fff !important; }
html.a11y-contrast-inverse a { color: #ffeb3b !important; -webkit-text-fill-color: #ffeb3b !important; text-decoration: underline !important; }
html.a11y-contrast-inverse .btn { background: #000 !important; border: 2px solid #fff !important; }
html.a11y-contrast-inverse .a11y-panel button[aria-pressed="true"] { background: #fff !important; color: #000 !important; -webkit-text-fill-color: #000 !important; }
html.a11y-contrast-high .social-btn, html.a11y-contrast-high .social-chip, html.a11y-contrast-high .social-chip-icon, html.a11y-contrast-high .consult-block, html.a11y-contrast-high .card-icon { background: #fff !important; border-color: #000 !important; box-shadow: none !important; }
html.a11y-contrast-inverse .social-btn, html.a11y-contrast-inverse .social-chip, html.a11y-contrast-inverse .social-chip-icon, html.a11y-contrast-inverse .consult-block, html.a11y-contrast-inverse .consult-block-icon, html.a11y-contrast-inverse .card-icon { background: #000 !important; border-color: #fff !important; box-shadow: none !important; }
/* логотип в режимах контрастности — одним цветом: чёрный на белом, белый на чёрном (цветной и светлый вариант иначе теряются) */
html.a11y-contrast-high .brand-logo { filter: brightness(0); }
html.a11y-contrast-inverse .brand-logo { filter: brightness(0) invert(1); }
html.a11y-noimg img:not(.brand-logo) { display: none !important; }
html.a11y-noimg .hero-card, html.a11y-noimg .card-media, html.a11y-noimg .equip-media, html.a11y-noimg .news-row-media, html.a11y-noimg .review-letter, html.a11y-noimg .gallery, html.a11y-noimg .section-gallery, html.a11y-noimg .gallery-embed { display: none !important; }
html.a11y-noimg .news-row { grid-template-columns: 1fr; }

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}

@media print {
    .topbar, .header, .footer, .cookie, .to-top, .announce, .page-aside, .adminbar, .modal { display: none !important; }
    .page-layout.has-aside { grid-template-columns: 1fr; }
    a { color: #000; }
}
