/* =====================================================================
   Мастерская ТрансЛаб — стили сайта
   Один файл, без фреймворков. Цвета/размеры — в переменных ниже.
   ===================================================================== */

@font-face { font-family: "Inter"; font-style: normal; font-weight: 400; font-display: swap; src: url("/static/fonts/inter-Regular.woff2") format("woff2"), url("/static/fonts/inter-Regular.woff") format("woff"); }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 500 600; font-display: swap; src: url("/static/fonts/inter-SemiBold.woff2") format("woff2"), url("/static/fonts/inter-SemiBold.woff") format("woff"); }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 700 900; font-display: swap; src: url("/static/fonts/inter-ExtraBold.woff2") format("woff2"), url("/static/fonts/inter-ExtraBold.woff") format("woff"); }

:root {
  --navy-950: #0a1330;
  --navy-900: #0f1a3d;
  --navy-800: #16234a;
  --navy-700: #1f3266;
  --navy-600: #2c4588;
  --navy-300: #9fb0d6;
  --bg: #e8ecf2;     /* страница: мягкий холодно-серый вместо почти белого */
  --bg-2: #dfe5ee;
  --surface: #f8fafc; /* карточки: чуть светлее фона, но не чисто белые */
  --surface-2: #f0f3f8; /* светлые секции — тонированные, чтобы не было «бело-белого» */
  --field: #fcfdfe;   /* поля ввода */
  --line: #d5dce7;
  --line-2: #c9d3e3;
  --text: #172033;
  --muted: #5a6680;
  --accent: #1f5fd6;
  --accent-600: #174bb0;
  --accent-50: #eaf1ff;
  --green: #127a4a;   /* текст «в наличии» на светлом: 4,8:1 (было #17945a — 3,5:1) */
  --green-50: #e7f6ee;
  --red: #c02c2c;     /* ошибки и «закрыто»: 5:1 на розовом (было #d63b3b — 4:1) */
  --red-50: #fdecec;
  --link: #1d4fc9;
  /* заливка кнопок и активных пунктов с белым текстом — отдельно от --accent,
     потому что в тёмной теме акцент как цвет текста светлее, а под белым текстом нужен темнее */
  --btn: var(--accent);
  --btn-hover: var(--accent-600);
  --placeholder: #677289;
  --field-border: #8792a9; /* рамка полей ввода: 3:1 к фону поля (WCAG 1.4.11) */
  /* цвета мессенджеров — притемнены до 4,5:1 под белым текстом, узнаваемость сохраняется */
  --tg: #1677ab;
  --tg-hover: #12668f;
  --wa: #0f7f43;
  --wa-hover: #0b6b38;
  --d2: #e31e24;
  --d2-hover: #c4161c;
  --brand-red: #b31942; /* «Лаб» в логотипе */

  --font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --radius: 16px;
  --radius-sm: 10px;
  --shadow-1: 0 1px 2px rgba(15, 26, 61, .06), 0 2px 8px rgba(15, 26, 61, .05);
  --shadow-2: 0 10px 30px -10px rgba(15, 26, 61, .22), 0 2px 6px rgba(15, 26, 61, .06);
  --shadow-3: 0 24px 60px -20px rgba(15, 26, 61, .35);
  --ease: cubic-bezier(.22, 1, .36, 1);
  --container: 1240px;
  --gutter: 20px;
  --header-h: 64px;
}

@view-transition { navigation: auto; }

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 90px; }
body {
  margin: 0; font-family: var(--font); font-size: 16px; line-height: 1.6; color: var(--text);
  background: var(--bg); -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
  font-feature-settings: "cv11", "ss01"; overflow-wrap: break-word;
}
img, svg, video { max-width: 100%; height: auto; }
img { border-style: none; }
picture { display: contents; }
a { color: var(--link); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--accent-600); }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
h1, h2, h3, h4 { line-height: 1.2; letter-spacing: -.02em; color: var(--navy-900); margin: 0 0 .6em; font-weight: 800; }
h1 { font-size: clamp(28px, 3.4vw, 44px); }
h2 { font-size: clamp(23px, 2.4vw, 32px); }
h3 { font-size: clamp(19px, 1.8vw, 23px); font-weight: 700; }
h4 { font-size: 18px; font-weight: 700; }
p { margin: 0 0 1em; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; border-radius: 6px; }
::selection { background: var(--btn); color: #fff; }
.sr-only { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--btn); color: #fff; padding: 10px 16px; border-radius: 10px; font-weight: 600; transition: top .2s; }
.skip-link:focus { top: 12px; color: #fff; }

.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 var(--gutter); }
.icon { width: 20px; height: 20px; flex: none; display: inline-block; vertical-align: middle; }
.icon-lg { width: 28px; height: 28px; }

/* ---------- кнопки ---------- */
.btn {
  --b: var(--btn); display: inline-flex; align-items: center; justify-content: center; gap: 9px;
  min-height: 46px; padding: 0 22px; border-radius: 12px; border: 0; background: var(--b); color: #fff;
  font-weight: 600; font-size: 15.5px; text-decoration: none; white-space: nowrap; position: relative; overflow: hidden;
  transition: transform .25s var(--ease), box-shadow .25s var(--ease), background-color .2s;
  box-shadow: 0 6px 18px -6px rgba(31, 95, 214, .55);
}
.btn::after {
  content: ""; position: absolute; inset: 0; background: linear-gradient(110deg, transparent 30%, rgba(255,255,255,.35) 50%, transparent 70%);
  transform: translateX(-120%); transition: transform .7s var(--ease);
}
.btn:hover { color: #fff; background: var(--btn-hover); transform: translateY(-1px); box-shadow: 0 10px 24px -8px rgba(31, 95, 214, .7); }
.btn:hover::after { transform: translateX(120%); }
.btn:active { transform: translateY(0); }
.btn .icon { width: 18px; height: 18px; transition: transform .25s var(--ease); }
.btn:hover .icon-arrow { transform: translateX(3px); }
.btn-ghost { background: transparent; color: var(--navy-800); box-shadow: inset 0 0 0 1.5px var(--line-2); }
.btn-ghost:hover { background: var(--surface); color: var(--navy-900); box-shadow: inset 0 0 0 1.5px var(--navy-700); }
.btn-light { background: rgba(255,255,255,.1); color: #fff; box-shadow: inset 0 0 0 1.5px rgba(255,255,255,.28); }
.btn-light:hover { background: rgba(255,255,255,.18); box-shadow: inset 0 0 0 1.5px rgba(255,255,255,.5); }
.btn-navy { background: var(--navy-800); box-shadow: 0 6px 18px -8px rgba(15,26,61,.6); }
.btn-navy:hover { background: var(--navy-700); box-shadow: 0 10px 24px -10px rgba(15,26,61,.7); }
.btn-sm { min-height: 38px; padding: 0 15px; font-size: 14.5px; border-radius: 10px; }
.btn-block { width: 100%; }

.chip { display: inline-flex; align-items: center; gap: 6px; padding: 4px 11px; border-radius: 999px; background: var(--bg); color: var(--navy-700); font-size: 13px; font-weight: 600; line-height: 1.5; text-decoration: none; }
.chip-accent { background: var(--accent-50); color: var(--accent-600); }
.chip-green { background: var(--green-50); color: var(--green); }
.dot { width: 8px; height: 8px; border-radius: 50%; background: currentColor; display: inline-block; }
.dot-pulse { animation: pulse 2s infinite; }
@keyframes pulse { 0% { box-shadow: 0 0 0 0 rgba(23,148,90,.5) } 70% { box-shadow: 0 0 0 8px rgba(23,148,90,0) } 100% { box-shadow: 0 0 0 0 rgba(23,148,90,0) } }

/* =====================================================================
   ШАПКА: контакты → логотип+название → синий блок (описание, поиск, меню)
   ===================================================================== */
.topbar { background: var(--surface); border-bottom: 1px solid var(--line); font-size: 14px; }
.topbar .container { display: flex; align-items: center; justify-content: space-between; gap: 18px; min-height: 42px; }
.topbar-note { color: var(--muted); display: flex; align-items: center; gap: 8px; }
.topbar-note .icon { width: 16px; height: 16px; color: var(--accent); }
/* часы работы: две ровные строки, филиал — в своей колонке */
.topbar-hours { display: grid; grid-template-columns: auto auto; column-gap: 8px; font-size: 13px; line-height: 1.35; white-space: nowrap; }
.topbar-hours b { font-weight: 600; color: var(--text); }
.topbar-hours b::after { content: " —"; font-weight: 400; color: var(--muted); }
.topbar-contacts { display: flex; align-items: center; gap: 22px; margin-left: auto; }
.topbar-phone { display: inline-flex; align-items: baseline; gap: 7px; color: var(--navy-900); text-decoration: none; font-weight: 700; white-space: nowrap; }
.topbar-phone span { color: var(--muted); font-weight: 500; font-size: 13px; }
.topbar-phone:hover { color: var(--accent-600); }
.topbar-social { display: flex; gap: 6px; }
/* кнопки в цветах платформ: Telegram — синий, WhatsApp — зелёный, Drive2 — красный */
.topbar-social a { height: 30px; padding: 0 10px; border-radius: 8px; display: inline-flex; align-items: center; gap: 6px; color: #fff; font-size: 13px; font-weight: 600; text-decoration: none; transition: filter .2s, transform .2s var(--ease); }
.topbar-social a:hover { filter: brightness(.9); transform: translateY(-1px); }
.topbar-social .ts-tg { background: var(--tg); }
.topbar-social .ts-wa { background: var(--wa); }
.topbar-social .ts-d2 { background: var(--d2); font-size: 12.5px; }
.topbar-social .icon { width: 17px; height: 17px; }
@media (max-width: 1280px) { .topbar-social .ts-tg span, .topbar-social .ts-wa span { display: none; } .topbar-social a { padding: 0 8px; } }

.brandbar { background: var(--bg); }
.brandbar .container { display: flex; align-items: center; gap: 24px; min-height: 92px; }
.brand { display: flex; align-items: center; gap: 14px; text-decoration: none; color: var(--navy-900); }
.brand-logo { width: 68px; height: 68px; border-radius: 50%; box-shadow: var(--shadow-2); transition: transform .5s var(--ease); }
.brand:hover .brand-logo { transform: rotate(-8deg) scale(1.04); }
.brand-text { display: flex; flex-direction: column; line-height: 1.05; }
.brand-kicker { font-size: 13px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); }
.brand-name { font-size: clamp(26px, 3vw, 34px); font-weight: 800; letter-spacing: -.03em; color: var(--navy-900); }
.brand-name b { color: var(--brand-red); font-weight: 800; } /* красный флага США, в тон логотипу */
.brand-claim { margin-left: 8px; padding-left: 22px; border-left: 1px solid var(--line-2); color: var(--muted); font-size: 14.5px; line-height: 1.4; max-width: 300px; }
.brandbar-cta { margin-left: auto; display: flex; align-items: center; gap: 10px; }
.burger { display: none; width: 46px; height: 46px; border-radius: 12px; border: 0; background: var(--navy-800); color: #fff; place-items: center; }
.burger .icon { width: 24px; height: 24px; }
.mobile-call { display: none; width: 46px; height: 46px; border-radius: 12px; background: var(--btn); color: #fff; place-items: center; }

/* синий блок */
.navband { position: relative; background: var(--navy-800); color: #fff; isolation: isolate; }
.navband-deco { position: absolute; inset: 0; overflow: hidden; z-index: -1; pointer-events: none; }
.navband-deco::before { /* чертёжная сетка */
  content: ""; position: absolute; inset: 0; z-index: -1; opacity: .55;
  background-image:
    linear-gradient(rgba(255,255,255,.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.05) 1px, transparent 1px),
    linear-gradient(rgba(255,255,255,.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.025) 1px, transparent 1px);
  background-size: 96px 96px, 96px 96px, 24px 24px, 24px 24px;
  mask-image: radial-gradient(ellipse 80% 90% at 70% 30%, #000 30%, transparent 85%);
  animation: grid-pan 40s linear infinite;
}
.navband-deco::after {
  content: ""; position: absolute; z-index: -1; width: 680px; height: 680px; right: -160px; top: -300px;
  background: radial-gradient(circle, rgba(31,95,214,.28), transparent 62%); filter: blur(10px);
}
@keyframes grid-pan { to { background-position: 96px 96px, 96px 96px, 24px 24px, 24px 24px; } }
.navband-3d { position: absolute; right: max(0px, calc(50% - 680px)); top: 0; width: 460px; height: auto; z-index: -1; opacity: .75; -webkit-mask-image: linear-gradient(90deg, transparent, #000 35%); mask-image: linear-gradient(90deg, transparent, #000 35%); }
@keyframes spin { to { transform: rotate(360deg); } }
/* 3D-модели агрегатов белым каркасом на синем (js/models3d.js): на главной — крупная АКПП, на внутренних
   страницах — модель по разделу (.navband-3d);
   левый край растворяется, чтобы не мешать тексту */
.hero-3d { position: absolute; right: max(0px, calc(50% - 660px)); top: 20px; width: 560px; height: auto; z-index: -1; -webkit-mask-image: linear-gradient(90deg, transparent, #000 30%); mask-image: linear-gradient(90deg, transparent, #000 30%); }
.hero { padding: 42px 0 30px; max-width: 860px; }
.hero-kicker { display: inline-flex; align-items: center; gap: 8px; padding: 6px 14px 6px 8px; border-radius: 999px; background: rgba(255,255,255,.08); box-shadow: inset 0 0 0 1px rgba(255,255,255,.14); font-size: 13.5px; font-weight: 600; color: #d8e0f3; margin-bottom: 18px; }
.hero-kicker .chip { background: var(--btn); color: #fff; padding: 2px 9px; font-size: 12px; }
.hero h1 { color: #fff; font-size: clamp(30px, 4.2vw, 52px); letter-spacing: -.035em; margin-bottom: 14px; }
.hero h1 .accent { color: var(--accent); }
.hero-lead { color: #c8d2ea; font-size: clamp(16px, 1.5vw, 19px); max-width: 720px; margin-bottom: 0; }
.hero-compact { padding: 26px 0 8px; }
.hero-compact .hero-lead { font-size: 15.5px; }

/* поиск */
.search { position: relative; z-index: 30; margin: 26px 0 0; max-width: 860px; }
.search-form { display: flex; align-items: center; background: var(--surface); border-radius: 14px; padding: 6px; box-shadow: 0 18px 40px -16px rgba(0,0,0,.45); transition: box-shadow .25s; }
.search-form:focus-within { box-shadow: 0 0 0 4px rgba(31,95,214,.35), 0 18px 40px -16px rgba(0,0,0,.45); }
.search-form .icon { width: 22px; height: 22px; color: var(--muted); margin: 0 8px 0 12px; }
.search-input { flex: 1; min-width: 0; border: 0; outline: 0; background: transparent; height: 46px; font-size: 16.5px; color: var(--text); }
.search-input::placeholder { color: var(--placeholder); }
.search-form .btn { min-height: 46px; }
.search-tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; font-size: 13.5px; color: #9fb0d6; align-items: center; }
.search-tags a { color: #dfe6f6; text-decoration: none; padding: 3px 11px; border-radius: 999px; background: rgba(255,255,255,.07); box-shadow: inset 0 0 0 1px rgba(255,255,255,.12); transition: background .2s, color .2s; }
.search-tags a:hover { background: var(--btn); color: #fff; }
.suggest { position: absolute; left: 0; right: 0; top: calc(100% + 8px); background: #fff; border-radius: 14px; box-shadow: var(--shadow-3); z-index: 60; overflow: hidden; max-height: 70vh; overflow-y: auto; opacity: 0; transform: translateY(-6px); pointer-events: none; transition: opacity .18s, transform .18s var(--ease); }
.suggest.open { opacity: 1; transform: none; pointer-events: auto; }
/* синий блок изолирован, а липкое меню (z 50) лежит выше — пока подсказки открыты, поднимаем блок над меню */
.navband:has(.suggest.open) { z-index: 55; }
.suggest a { display: flex; gap: 12px; align-items: center; padding: 10px 14px; color: var(--text); text-decoration: none; border-bottom: 1px solid var(--bg); }
.suggest a:hover, .suggest a.active { background: var(--bg); }
.suggest img { width: 54px; height: 42px; object-fit: cover; border-radius: 8px; background: var(--bg); flex: none; }
.suggest .s-ico { width: 54px; height: 42px; border-radius: 8px; background: var(--bg); display: grid; place-items: center; color: var(--navy-600); flex: none; }
.suggest .s-title { font-weight: 600; font-size: 14.5px; line-height: 1.3; display: block; }
.suggest .s-meta { font-size: 12.5px; color: var(--muted); display: block; }
.suggest .s-price { margin-left: auto; font-weight: 700; color: var(--navy-900); white-space: nowrap; font-size: 14px; }
.suggest .s-all { justify-content: center; color: var(--link); font-weight: 600; font-size: 14px; }
.suggest .s-empty { padding: 16px; color: var(--muted); font-size: 14px; }

/* главное меню (липкое) */
.mainnav { position: sticky; top: 0; z-index: 50; background: var(--navy-800); border-top: 1px solid rgba(255,255,255,.08); transition: box-shadow .3s, background .3s; }
.mainnav.stuck { background: rgba(22, 35, 74, .94); backdrop-filter: saturate(1.4) blur(10px); -webkit-backdrop-filter: saturate(1.4) blur(10px); box-shadow: 0 10px 30px -12px rgba(0,0,0,.5); }
.mainnav .container { display: flex; align-items: center; gap: 10px; min-height: var(--header-h); }
.nav-mini { display: flex; align-items: center; gap: 10px; color: #fff; text-decoration: none; font-weight: 800; letter-spacing: -.02em; max-width: 0; overflow: hidden; opacity: 0; transition: max-width .4s var(--ease), opacity .3s, margin .3s; white-space: nowrap; }
.nav-mini img { width: 34px; height: 34px; border-radius: 50%; }
.mainnav.stuck .nav-mini { max-width: 200px; opacity: 1; margin-right: 6px; flex: none; }
.menu { display: flex; gap: 6px; list-style: none; margin: 0; padding: 0; flex: 1; }
.menu > li { position: relative; flex: 1 1 auto; }
.menu-link {
  display: flex; align-items: center; justify-content: center; gap: 6px; height: 46px; padding: 0 14px; border-radius: 11px;
  color: var(--navy-900); background: #fff; text-decoration: none; font-weight: 600; font-size: 14.5px; white-space: nowrap;
  transition: background .2s, color .2s, transform .25s var(--ease), box-shadow .25s;
}
.menu-link .icon { width: 16px; height: 16px; transition: transform .25s var(--ease); color: var(--muted); }
.menu > li:hover > .menu-link, .menu-link:focus-visible { background: var(--btn); color: #fff; box-shadow: 0 8px 20px -10px rgba(31,95,214,.8); }
.menu > li:hover > .menu-link .icon { transform: rotate(180deg); color: #fff; }
.menu-link.is-active { background: var(--accent-50); color: var(--accent-600); box-shadow: inset 0 0 0 2px var(--accent); }
.submenu {
  position: absolute; left: 0; top: calc(100% + 10px); min-width: 280px; list-style: none; margin: 0; padding: 8px;
  background: #fff; border-radius: 14px; box-shadow: var(--shadow-3); opacity: 0; visibility: hidden; transform: translateY(8px);
  transition: opacity .2s, transform .25s var(--ease), visibility 0s .25s; z-index: 70;
}
.submenu::before { content: ""; position: absolute; left: 0; right: 0; top: -12px; height: 12px; }
.menu > li:hover > .submenu, .menu > li:focus-within > .submenu { opacity: 1; visibility: visible; transform: none; transition-delay: 0s; }
.menu > li:last-child .submenu, .menu > li:nth-last-child(2) .submenu { left: auto; right: 0; }
.submenu a { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 10px; color: var(--text); text-decoration: none; font-size: 14.5px; font-weight: 500; transition: background .15s, color .15s, padding .2s var(--ease); }
.submenu a .icon { width: 18px; height: 18px; color: var(--navy-600); }
.submenu a:hover { background: var(--bg); color: var(--accent-600); padding-left: 16px; }
.submenu a.is-active { color: var(--accent-600); background: var(--accent-50); }
.nav-phone { display: none; color: #fff; text-decoration: none; font-weight: 700; white-space: nowrap; gap: 8px; align-items: center; margin-left: 6px; }
.mainnav.stuck .nav-phone { display: inline-flex; }
.nav-phone:hover { color: var(--accent); }
/* в липком меню не хватает места: сначала прячем телефон, потом название (остаётся значок) — без обрезки «Тра…» */
.mainnav.stuck .menu-link { padding: 0 10px; }
@media (max-width: 1439px) { .mainnav.stuck .nav-phone { display: none; } }
@media (max-width: 1120px) { .nav-mini span { display: none; } }

/* мобильное меню */
.drawer { position: fixed; inset: 0; z-index: 200; visibility: hidden; }
.drawer.open { visibility: visible; }
.drawer-backdrop { position: absolute; inset: 0; background: rgba(10, 19, 48, .55); opacity: 0; transition: opacity .3s; }
.drawer.open .drawer-backdrop { opacity: 1; }
.drawer-panel { position: absolute; right: 0; top: 0; bottom: 0; width: min(390px, 92vw); background: #fff; transform: translateX(100%); transition: transform .38s var(--ease); display: flex; flex-direction: column; overflow-y: auto; overscroll-behavior: contain; }
.drawer.open .drawer-panel { transform: none; }
.drawer-head { display: flex; align-items: center; justify-content: space-between; padding: 14px 16px; border-bottom: 1px solid var(--line); position: sticky; top: 0; background: #fff; z-index: 1; }
.drawer-close { width: 42px; height: 42px; border: 0; border-radius: 11px; background: var(--bg); display: grid; place-items: center; }
.drawer nav { padding: 8px 10px; }
.drawer details { border-bottom: 1px solid var(--bg); }
.drawer summary, .drawer .d-link { list-style: none; display: flex; align-items: center; justify-content: space-between; padding: 14px 10px; font-weight: 700; color: var(--navy-900); text-decoration: none; font-size: 16.5px; cursor: pointer; }
.drawer summary::-webkit-details-marker { display: none; }
.drawer summary .icon { transition: transform .25s var(--ease); }
.drawer details[open] summary .icon { transform: rotate(180deg); }
.drawer details a { display: block; padding: 10px 14px; color: var(--text); text-decoration: none; border-radius: 9px; }
.drawer details a:hover { background: var(--bg); }
.drawer-contacts { margin-top: auto; padding: 16px; background: var(--bg); display: grid; gap: 10px; }
.drawer-contacts a.ph { font-weight: 800; font-size: 19px; color: var(--navy-900); text-decoration: none; display: flex; flex-direction: column; line-height: 1.2; }
.drawer-contacts a.ph span { font-size: 13px; color: var(--muted); font-weight: 500; }

/* =====================================================================
   СЕКЦИИ И КАРТОЧКИ
   ===================================================================== */
main { display: block; }
.section { padding-top: 64px; padding-bottom: 64px; }
.section-tight { padding: 40px 0; }
.section-white { background: var(--surface-2); }
.section-head { display: flex; align-items: end; justify-content: space-between; gap: 20px; margin-bottom: 26px; }
.section-head h2 { margin: 0; }
.eyebrow { display: inline-flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--accent-600); margin-bottom: 10px; }
.eyebrow::before { content: ""; width: 22px; height: 2px; background: currentColor; border-radius: 2px; }
.section-sub { color: var(--muted); max-width: 640px; margin: 8px 0 0; }
.link-more { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; text-decoration: none; color: var(--navy-700); white-space: nowrap; }
.link-more .icon { width: 18px; height: 18px; transition: transform .25s var(--ease); }
.link-more:hover .icon { transform: translateX(4px); }

.card { background: var(--surface); border-radius: var(--radius); box-shadow: var(--shadow-1); border: 1px solid var(--line); }

/* статистика */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; background: rgba(255,255,255,.12); border-radius: 16px; overflow: hidden; margin: 30px 0 34px; box-shadow: inset 0 0 0 1px rgba(255,255,255,.12); }
.stat { background: rgba(15, 26, 61, .55); padding: 18px 20px; backdrop-filter: blur(4px); }
.stat-num { font-size: clamp(26px, 2.8vw, 36px); font-weight: 800; letter-spacing: -.03em; color: #fff; line-height: 1.1; font-variant-numeric: tabular-nums; }
.stat-num small { font-size: .5em; font-weight: 700; color: var(--accent); margin-left: 3px; letter-spacing: 0; }
.stat-label { color: #b9c5e2; font-size: 14px; line-height: 1.35; margin-top: 4px; }
/* главная, широкий экран: компактный первый экран, цифры — узкой полосой в 4 колонки под поиском */
@media (min-width: 1181px) {
  .hero-wrap { padding-bottom: 16px; } /* отступ внутри синего блока, а не margin у цифр — иначе под блоком светлая щель */
  .hero-wrap .hero { padding: 18px 0 12px; max-width: 860px; }
  .hero-wrap .hero-kicker { margin-bottom: 8px; padding-top: 4px; padding-bottom: 4px; font-size: 13px; }
  .hero-wrap .hero h1 { font-size: clamp(28px, 2.6vw, 36px); line-height: 1.12; margin-bottom: 8px; text-wrap: balance; }
  .hero-wrap .hero-lead { font-size: 15px; line-height: 1.5; max-width: 860px; }
  .hero-wrap .search { margin-top: 16px; }
  .hero-wrap .search-form { padding: 4px; }
  .hero-wrap .search-input, .hero-wrap .search-form .btn { height: 42px; min-height: 42px; }
  .hero-wrap .search-tags { margin-top: 8px; }
  .hero-wrap .stats { margin: 0; position: relative; }
  .hero-wrap .stat { padding: 8px 18px; display: flex; align-items: center; gap: 12px; }
  .hero-wrap .stat-num { font-size: 24px; flex: none; }
  .hero-wrap .stat-label { font-size: 13px; margin-top: 0; }
  .hero-3d { top: 6px; width: 500px; } /* низ модели уходит за полосу цифр */
  .brandbar .container { min-height: 74px; }
  .brand-logo { width: 56px; height: 56px; }
}

/* карусель */
.carousel { position: relative; }
.carousel-track { display: grid; grid-auto-flow: column; grid-auto-columns: calc((100% - 3 * 20px) / 4); gap: 20px; overflow-x: auto; scroll-snap-type: x mandatory; scroll-behavior: smooth; padding: 6px 2px 18px; margin: -6px -2px 0; scrollbar-width: none; overscroll-behavior-x: contain; }
.carousel-track::-webkit-scrollbar { display: none; }
.carousel-track > * { scroll-snap-align: start; }
.carousel-track.dragging { scroll-snap-type: none; scroll-behavior: auto; cursor: grabbing; }
.carousel-track.dragging * { pointer-events: none; }
.carousel-nav { display: flex; gap: 8px; }
.carousel-btn { width: 44px; height: 44px; border-radius: 12px; border: 0; background: var(--surface); color: var(--navy-800); display: grid; place-items: center; box-shadow: var(--shadow-1), inset 0 0 0 1px var(--line); transition: background .2s, color .2s, transform .2s var(--ease), opacity .2s; }
.carousel-btn:hover:not(:disabled) { background: var(--navy-800); color: #fff; transform: translateY(-1px); }
.carousel-btn:disabled { opacity: .4; cursor: default; }
.carousel-progress { height: 3px; background: var(--line); border-radius: 3px; overflow: hidden; margin-top: 6px; }
.carousel-progress span { display: block; height: 100%; width: 25%; background: var(--btn); border-radius: 3px; transition: transform .3s var(--ease); transform-origin: left; }

/* карточка агрегата */
.p-card { display: flex; flex-direction: column; background: var(--surface); border-radius: var(--radius); border: 1px solid var(--line); overflow: hidden; text-decoration: none; color: var(--text); transition: transform .35s var(--ease), box-shadow .35s var(--ease), border-color .2s; height: 100%; }
.p-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-2); border-color: transparent; color: var(--text); }
.p-media { position: relative; aspect-ratio: 4 / 3; background: linear-gradient(180deg, #f6f8fb, #e9eef6); overflow: hidden; }
.p-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--ease); }
.p-card:hover .p-media img { transform: scale(1.05); }
.p-badges { position: absolute; left: 10px; top: 10px; display: flex; gap: 6px; flex-wrap: wrap; }
.p-badges .chip { background: rgba(255,255,255,.92); backdrop-filter: blur(4px); box-shadow: 0 2px 8px rgba(15,26,61,.1); }
.p-badges .chip-green { color: var(--green); }
.p-body { display: flex; flex-direction: column; gap: 8px; padding: 14px 16px 16px; flex: 1; }
.p-cat { font-size: 12.5px; color: var(--muted); font-weight: 600; letter-spacing: .02em; }
.p-title { font-weight: 700; font-size: 15.5px; line-height: 1.35; color: var(--navy-900); display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; min-height: 3.9em; margin: 0; }
.p-foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: auto; padding-top: 6px; }
.price { font-weight: 800; font-size: 20px; letter-spacing: -.02em; color: var(--navy-900); white-space: nowrap; font-variant-numeric: tabular-nums; }
.price-old { font-size: 14px; color: var(--muted); text-decoration: line-through; font-weight: 500; margin-left: 6px; }
.p-go { width: 40px; height: 40px; border-radius: 11px; background: var(--bg); color: var(--navy-800); display: grid; place-items: center; transition: background .25s, color .25s, transform .25s var(--ease); flex: none; }
.p-card:hover .p-go { background: var(--btn); color: #fff; transform: rotate(-45deg); }

/* услуги */
.services { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.s-card { position: relative; display: flex; flex-direction: column; gap: 10px; padding: 22px; background: var(--surface); border-radius: var(--radius); border: 1px solid var(--line); text-decoration: none; color: var(--text); overflow: hidden; transition: transform .35s var(--ease), box-shadow .35s var(--ease), border-color .25s; min-height: 210px; }
.s-card::before { content: ""; position: absolute; inset: auto -40% -60% auto; width: 220px; height: 220px; border-radius: 50%; background: radial-gradient(circle, rgba(31,95,214,.14), transparent 65%); transform: scale(.4); opacity: 0; transition: transform .6s var(--ease), opacity .4s; }
.s-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-2); border-color: transparent; color: var(--text); }
.s-card:hover::before { transform: scale(1.2); opacity: 1; }
.s-ico { width: 54px; height: 54px; border-radius: 14px; background: var(--navy-800); color: #fff; display: grid; place-items: center; transition: background .3s, transform .5s var(--ease); }
.s-ico .icon { width: 28px; height: 28px; }
.s-card:hover .s-ico { background: var(--btn); transform: rotate(-10deg) scale(1.05); }
.s-card h3 { font-size: 18px; margin: 6px 0 0; }
.s-card p { color: var(--muted); font-size: 14.5px; line-height: 1.5; margin: 0; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.s-card .link-more { margin-top: auto; font-size: 14.5px; }
.s-card-accent { background: var(--navy-800); border-color: var(--navy-800); color: #fff; }
.s-card-accent h3 { color: #fff; }
.s-card-accent p { color: #c8d2ea; }
.s-card-accent .s-ico { background: var(--btn); }
.s-card-accent .link-more { color: #fff; }
.s-card-accent:hover { color: #fff; }

/* текстовый контент (из CMS) */
.prose { font-size: 16.5px; line-height: 1.72; color: #22304a; max-width: 78ch; }
.prose > :first-child { margin-top: 0; }
.prose h2 { margin: 1.6em 0 .6em; font-size: clamp(22px, 2.2vw, 28px); }
.prose h3 { margin: 1.5em 0 .5em; }
.prose h4 { margin: 1.4em 0 .5em; font-size: 18px; color: var(--navy-800); }
.prose p { margin: 0 0 1em; }
.prose ul, .prose ol { padding-left: 0; margin: 0 0 1.2em; list-style: none; }
.prose li { position: relative; padding-left: 30px; margin: 0 0 .55em; }
.prose ul > li::before { content: ""; position: absolute; left: 4px; top: .62em; width: 14px; height: 8px; border-left: 2.5px solid var(--accent); border-bottom: 2.5px solid var(--accent); transform: rotate(-45deg); border-radius: 1px; }
.prose ol { counter-reset: n; }
.prose ol > li { counter-increment: n; }
.prose ol > li::before { content: counter(n); position: absolute; left: 0; top: .15em; width: 22px; height: 22px; border-radius: 7px; background: var(--navy-800); color: #fff; font-size: 12.5px; font-weight: 700; display: grid; place-items: center; }
.prose li p { margin: 0; }
.prose a { color: var(--link); font-weight: 500; }
.prose strong, .prose b { color: var(--navy-900); font-weight: 700; }
.prose img { border-radius: 12px; height: auto; }
.prose figure { margin: 1.6em 0; }
.prose figure img { display: block; width: 100%; max-width: 100%; box-shadow: var(--shadow-1); }
.prose figcaption { color: var(--muted); font-size: 14px; margin-top: 8px; text-align: center; }
.prose p > img:not(.ico), .prose p > a > img:not(.ico) { display: block; margin: 1em 0; }
.prose img.ico { display: inline-block; height: 1.5em; width: auto; vertical-align: -0.35em; border-radius: 4px; margin: 0 2px; box-shadow: none; }
.prose blockquote { margin: 1.4em 0; padding: 16px 20px; border-left: 4px solid var(--accent); background: var(--accent-50); border-radius: 0 12px 12px 0; }
.prose hr { border: 0; height: 1px; background: var(--line); margin: 2em 0; }
.prose em, .prose i { color: #3e4c68; }
.table-wrap { overflow-x: auto; margin: 1.4em 0; border-radius: 14px; border: 1px solid var(--line); background: var(--surface); -webkit-overflow-scrolling: touch; }
.prose table { border-collapse: collapse; width: 100%; font-size: 14.5px; line-height: 1.45; min-width: 560px; }
.prose th, .prose td { padding: 10px 14px; border-bottom: 1px solid var(--line); text-align: left; vertical-align: top; }
.prose th { background: var(--navy-800); color: #fff; font-weight: 600; position: sticky; top: 0; }
.prose th strong, .prose th b { color: #fff; }
.prose tr:nth-child(even) td { background: #f7f9fc; }
.prose tr:hover td { background: var(--accent-50); }
.prose .table-wrap table { margin: 0; }
.prose a[data-lightbox] { cursor: zoom-in; display: block; }

.link-cards { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px; margin: 1.2em 0; }
.link-card { display: flex; flex-direction: column; gap: 6px; padding: 18px; border-radius: 14px; border: 1px solid var(--line); background: var(--surface); text-decoration: none; color: var(--text); transition: transform .3s var(--ease), box-shadow .3s, border-color .2s; }
.link-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-2); border-color: transparent; color: var(--text); }
.link-card strong { color: var(--navy-900); font-size: 16px; }
.link-card__desc { color: var(--muted); font-size: 14px; line-height: 1.5; }
.link-card__host { color: var(--accent-600); font-size: 13px; font-weight: 600; margin-top: auto; }

/* о компании на главной */
.about-grid { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: 40px; align-items: start; }
.aside-sticky { position: sticky; top: calc(var(--header-h) + 20px); display: grid; gap: 16px; }
.cta-card { padding: 24px; border-radius: var(--radius); background: var(--navy-800); color: #fff; position: relative; overflow: hidden; }
.cta-card::after { content: ""; position: absolute; right: -80px; bottom: -80px; width: 220px; height: 220px; border-radius: 50%; background: radial-gradient(circle, rgba(31,95,214,.4), transparent 65%); }
.cta-card h3 { color: #fff; margin-bottom: 8px; }
.cta-card p { color: #c8d2ea; font-size: 14.5px; }
.cta-card .ph { display: flex; flex-direction: column; color: #fff; text-decoration: none; font-weight: 800; font-size: 20px; line-height: 1.25; margin-bottom: 12px; position: relative; z-index: 1; }
.cta-card .ph span { color: #9fb0d6; font-weight: 500; font-size: 13px; }
.cta-card .ph:hover { color: var(--accent); }
.cta-card .btn { position: relative; z-index: 1; }
.facts { display: grid; gap: 12px; }
.fact { display: flex; gap: 12px; align-items: flex-start; padding: 14px 16px; background: var(--surface); border-radius: 14px; border: 1px solid var(--line); font-size: 14.5px; line-height: 1.45; }
.fact .icon { color: var(--accent); width: 24px; height: 24px; margin-top: 1px; }
.fact b { display: block; color: var(--navy-900); }

/* баннеры (слайдер исходного сайта) */
.banners { position: relative; border-radius: 20px; overflow: hidden; background: var(--surface); box-shadow: var(--shadow-1); aspect-ratio: 2000 / 420; }
.banner { position: absolute; inset: 0; opacity: 0; transition: opacity .9s ease, transform 6s linear; transform: scale(1.03); }
.banner.active { opacity: 1; transform: scale(1); z-index: 1; }
.banner img { width: 100%; height: 100%; object-fit: cover; }
.banner-dots { position: absolute; z-index: 2; left: 50%; bottom: 14px; transform: translateX(-50%); display: flex; gap: 8px; }
.banner-dots button { width: 28px; height: 6px; border-radius: 6px; border: 0; background: rgba(15,26,61,.25); padding: 0; transition: background .3s, width .3s var(--ease); }
.banner-dots button.active { background: var(--btn); width: 44px; }

/* новости */
.n-card { display: flex; flex-direction: column; background: var(--surface); border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); text-decoration: none; color: var(--text); height: 100%; transition: transform .35s var(--ease), box-shadow .35s var(--ease), border-color .2s; }
.n-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-2); border-color: transparent; color: var(--text); }
.n-media { aspect-ratio: 16 / 10; background: var(--bg-2); overflow: hidden; position: relative; }
.n-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--ease); }
.n-card:hover .n-media img { transform: scale(1.05); }
.n-media .chip { position: absolute; left: 10px; top: 10px; background: rgba(255,255,255,.92); }
.n-body { padding: 16px 18px 18px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.n-date { color: var(--muted); font-size: 13px; display: flex; align-items: center; gap: 6px; }
.n-date .icon { width: 15px; height: 15px; }
.n-title { font-weight: 700; color: var(--navy-900); font-size: 16.5px; line-height: 1.35; margin: 0; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.n-text { color: var(--muted); font-size: 14.5px; line-height: 1.5; margin: 0; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }

/* филиалы */
.branches { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
.branch { padding: 26px; display: flex; flex-direction: column; gap: 14px; }
.branch-head { display: flex; justify-content: space-between; gap: 12px; align-items: start; }
.branch h3 { margin: 0; font-size: 21px; }
.branch-status { white-space: nowrap; }
.branch-status.closed { background: var(--red-50); color: var(--red); }
.branch-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.branch-list li { display: flex; gap: 10px; align-items: flex-start; color: #34415d; font-size: 15px; }
.branch-list .icon { color: var(--navy-600); width: 20px; height: 20px; margin-top: 2px; }
.branch-list a { font-weight: 700; color: var(--navy-900); text-decoration: none; font-size: 17px; }
.branch-list a:hover { color: var(--accent-600); }
.branch-actions { display: flex; gap: 10px; flex-wrap: wrap; margin-top: auto; }
.map-embed { position: relative; aspect-ratio: 16 / 9; border-radius: 14px; overflow: hidden; background:
  linear-gradient(rgba(31,50,102,.06) 1px, transparent 1px) 0 0 / 22px 22px,
  linear-gradient(90deg, rgba(31,50,102,.06) 1px, transparent 1px) 0 0 / 22px 22px, #eef2f8; border: 1px solid var(--line); margin: 1em 0; }
.map-embed iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.map-load { position: absolute; inset: 0; margin: auto; width: max-content; height: max-content; }

/* форма */
.form { display: grid; gap: 14px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.field { display: grid; gap: 6px; }
.field label { font-size: 14px; font-weight: 600; color: var(--navy-900); }
.field label .req { color: var(--accent); }
.input, .select, .textarea {
  width: 100%; min-height: 48px; padding: 11px 14px; border-radius: 12px; border: 1.5px solid var(--field-border); background: var(--field);
  font-size: 16px; transition: border-color .2s, box-shadow .2s; outline: none; color: var(--text);
}
.textarea { min-height: 120px; resize: vertical; }
.input::placeholder, .textarea::placeholder { color: var(--placeholder); opacity: 1; }
.input:focus, .select:focus, .textarea:focus { border-color: var(--accent); box-shadow: 0 0 0 4px rgba(31,95,214,.15); }
.input:user-invalid { border-color: var(--red); }
.field-hint { font-size: 13px; color: var(--muted); }
.check { display: flex; gap: 10px; align-items: flex-start; font-size: 13.5px; color: var(--muted); line-height: 1.45; }
.check input { width: 18px; height: 18px; accent-color: var(--accent); margin-top: 1px; flex: none; }
.hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; overflow: hidden; }
.alert { padding: 14px 16px; border-radius: 12px; font-size: 15px; display: flex; gap: 10px; align-items: flex-start; }
.alert-ok { background: var(--green-50); color: #0f6a40; }
.alert-err { background: var(--red-50); color: var(--red); }
.alert .icon { margin-top: 2px; }
.form-done { text-align: center; padding: 30px 10px; }
.form-done .ok-ico { width: 72px; height: 72px; border-radius: 50%; background: var(--green-50); color: var(--green); display: grid; place-items: center; margin: 0 auto 14px; animation: pop .5s var(--ease); }
.form-done .ok-ico .icon { width: 36px; height: 36px; }
@keyframes pop { from { transform: scale(.4); opacity: 0; } }
.cta-band { background: var(--navy-800); color: #fff; border-radius: 24px; padding: 40px; display: grid; grid-template-columns: 1fr 1.1fr; gap: 40px; position: relative; overflow: hidden; isolation: isolate; }
.cta-band::before { content: ""; position: absolute; inset: 0; z-index: -1; opacity: .5; background-image: linear-gradient(rgba(255,255,255,.05) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,.05) 1px, transparent 1px); background-size: 32px 32px; mask-image: linear-gradient(90deg, #000, transparent 70%); }
.cta-band h2 { color: #fff; }
.cta-band p { color: #c8d2ea; }
.cta-band .form { background: var(--surface); color: var(--text); padding: 24px; border-radius: 18px; box-shadow: var(--shadow-3); }
.cta-points { list-style: none; padding: 0; margin: 20px 0 0; display: grid; gap: 10px; }
.cta-points li { display: flex; gap: 10px; align-items: center; color: #e2e8f6; }
.cta-points .icon { color: var(--accent); flex: none; }
.cta-points a { color: inherit; }

/* =====================================================================
   ВНУТРЕННИЕ СТРАНИЦЫ
   ===================================================================== */
.crumbs { display: flex; flex-wrap: wrap; gap: 4px 6px; list-style: none; padding: 0; margin: 0 0 14px; font-size: 13.5px; color: #9fb0d6; }
.crumbs a { color: #c8d2ea; text-decoration: none; }
.crumbs a:hover { color: #fff; text-decoration: underline; }
.crumbs li + li::before { content: "/"; margin-right: 6px; opacity: .5; }
.crumbs [aria-current] { color: #fff; }
.page-head { padding: 26px 0 24px; }
.page-head .search { margin-top: 18px; }
.page-head h1 { color: #fff; margin-bottom: 8px; }
.page-head .hero-lead { font-size: 16.5px; max-width: 860px; }
.page-meta { display: flex; flex-wrap: wrap; gap: 14px; color: #b9c5e2; font-size: 14px; align-items: center; }
.page-meta .icon { width: 16px; height: 16px; }
.page-meta span { display: inline-flex; gap: 6px; align-items: center; }

.layout { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 36px; align-items: start; padding-top: 36px; padding-bottom: 64px; }
.layout-wide { grid-template-columns: minmax(0, 1fr); }
.content-card { padding: clamp(20px, 3vw, 40px); }
.side-nav { padding: 10px; }
.side-nav h3 { font-size: 13px; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin: 8px 10px 6px; }
.side-nav a { display: flex; align-items: center; gap: 10px; padding: 10px; border-radius: 10px; color: var(--text); text-decoration: none; font-weight: 500; font-size: 15px; transition: background .15s, color .15s; }
.side-nav a .icon { color: var(--navy-600); width: 19px; height: 19px; }
.side-nav a:hover { background: var(--bg); }
.side-nav a.is-active { background: var(--accent-50); color: var(--accent-600); font-weight: 600; }
.side-nav a.is-active .icon { color: var(--accent); }
.child-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 14px; margin: 0 0 28px; }
.child-grid .s-card { min-height: 0; padding: 18px; }

/* каталог */
.cat-bar { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; justify-content: space-between; margin-bottom: 22px; }
.cat-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.cat-chip { display: inline-flex; align-items: center; gap: 8px; padding: 9px 15px; border-radius: 999px; background: var(--surface); border: 1px solid var(--line); color: var(--navy-800); text-decoration: none; font-weight: 600; font-size: 14.5px; transition: background .2s, color .2s, border-color .2s, transform .2s var(--ease); }
.cat-chip span { background: var(--bg); color: var(--muted); border-radius: 999px; padding: 0 8px; font-size: 12.5px; }
.cat-chip:hover { border-color: var(--navy-700); transform: translateY(-1px); }
.cat-chip.is-active { background: var(--navy-800); color: #fff; border-color: var(--navy-800); }
.cat-chip.is-active span { background: rgba(255,255,255,.18); color: #fff; }
.sort { display: flex; align-items: center; gap: 8px; color: var(--muted); font-size: 14px; }
.sort .select { min-height: 40px; padding: 6px 12px; width: auto; font-size: 14.5px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.empty { text-align: center; padding: 40px 20px; color: var(--muted); }
.empty .icon { width: 48px; height: 48px; color: var(--line-2); margin-bottom: 8px; }
.intro-card { padding: clamp(20px, 3vw, 32px); margin-top: 36px; }
/* описание раздела с фото в начале (например, «Восстановленные АКПП»): текст слева, фото справа небольшой колонкой, а не на всю ширину */
.intro-card .prose:has(> img:first-child) { max-width: none; display: grid; grid-template-columns: minmax(0, 1fr) minmax(260px, 380px); column-gap: 36px; align-items: start; }
.intro-card .prose:has(> img:first-child) > * { grid-column: 1; }
.intro-card .prose:has(> img:first-child) > img:first-child { grid-column: 2; grid-row: 1 / span 30; width: 100%; height: auto; margin: 6px 0 0; box-shadow: var(--shadow-1); }
.intro-card .prose:has(> img:first-child) > h2:nth-child(2) { margin-top: 0; }
@media (max-width: 760px) {
  .intro-card .prose:has(> img:first-child) { display: block; }
  .intro-card .prose:has(> img:first-child) > img:first-child { max-height: 260px; object-fit: cover; margin: 0 0 18px; }
}

/* товар */
.product { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); gap: 36px; padding: 36px 0 20px; align-items: start; }
.gallery-main { position: relative; aspect-ratio: 4 / 3; border-radius: 18px; overflow: hidden; background: linear-gradient(180deg, var(--surface), var(--bg)); border: 1px solid var(--line); cursor: zoom-in; }
.gallery-main img { width: 100%; height: 100%; object-fit: contain; transition: opacity .25s, transform .5s var(--ease); }
.gallery-main:hover img { transform: scale(1.02); }
.gallery-zoom { position: absolute; right: 12px; bottom: 12px; width: 42px; height: 42px; border-radius: 12px; background: rgba(255,255,255,.92); display: grid; place-items: center; color: var(--navy-800); box-shadow: var(--shadow-1); pointer-events: none; }
.gallery-thumbs { display: flex; gap: 10px; margin-top: 12px; overflow-x: auto; padding-bottom: 4px; scrollbar-width: thin; }
.gallery-thumbs button { flex: none; width: 86px; height: 66px; border-radius: 12px; overflow: hidden; border: 2px solid transparent; padding: 0; background: var(--surface); box-shadow: inset 0 0 0 1px var(--line); transition: border-color .2s, transform .2s var(--ease); }
.gallery-thumbs button:hover { transform: translateY(-2px); }
.gallery-thumbs button.active { border-color: var(--accent); }
.gallery-thumbs img { width: 100%; height: 100%; object-fit: cover; }
.buy { padding: 26px; position: sticky; top: calc(var(--header-h) + 20px); }
.buy h1 { font-size: clamp(22px, 2.3vw, 30px); color: var(--navy-900); }
.buy-price { display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; margin: 6px 0 18px; }
.buy-price .price { font-size: 34px; }
.specs { display: grid; grid-template-columns: auto 1fr; gap: 8px 18px; margin: 0 0 20px; font-size: 15px; }
.specs dt { color: var(--muted); }
.specs dd { margin: 0; font-weight: 600; color: var(--navy-900); }
.buy-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.buy-note { margin-top: 16px; padding: 14px; border-radius: 12px; background: var(--bg); font-size: 14px; color: #34415d; display: flex; gap: 10px; }
.buy-note .icon { color: var(--accent); }
.product-desc { padding: clamp(20px, 3vw, 36px); margin-bottom: 48px; }

/* публикации */
.post-cover { border-radius: 18px; overflow: hidden; margin: 0 0 28px; box-shadow: var(--shadow-1); background: var(--bg-2); }
.post-cover img { width: 100%; max-height: 520px; object-fit: cover; display: block; }
.post-nav { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 30px; }
.post-nav a { padding: 16px 18px; border-radius: 14px; border: 1px solid var(--line); background: var(--surface); text-decoration: none; color: var(--text); transition: transform .3s var(--ease), box-shadow .3s; display: flex; flex-direction: column; gap: 4px; }
.post-nav a:hover { transform: translateY(-2px); box-shadow: var(--shadow-2); color: var(--text); }
.post-nav small { color: var(--muted); display: flex; align-items: center; gap: 6px; }
.post-nav .next { text-align: right; align-items: flex-end; }
.post-nav strong { color: var(--navy-900); line-height: 1.35; }
.share { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-top: 26px; padding-top: 20px; border-top: 1px solid var(--line); }
.share span { color: var(--muted); font-size: 14px; margin-right: 4px; }
.share a, .share button { width: 40px; height: 40px; border-radius: 11px; border: 0; background: var(--bg); color: var(--navy-800); display: grid; place-items: center; transition: background .2s, color .2s, transform .2s var(--ease); text-decoration: none; font-weight: 800; font-size: 13px; }
.share a:hover, .share button:hover { background: var(--navy-800); color: #fff; transform: translateY(-2px); }
.progress { position: fixed; left: 0; top: 0; height: 3px; width: 100%; background: var(--btn); transform-origin: 0 50%; transform: scaleX(0); z-index: 300; }
.pager { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; margin-top: 34px; }
.pager a, .pager span { min-width: 44px; height: 44px; padding: 0 12px; border-radius: 12px; display: grid; place-items: center; background: var(--surface); border: 1px solid var(--line); color: var(--navy-800); text-decoration: none; font-weight: 600; transition: background .2s, color .2s; }
.pager a:hover { background: var(--navy-800); color: #fff; }
.pager .current { background: var(--btn); color: #fff; border-color: var(--btn); }
.tabs { display: inline-flex; gap: 6px; padding: 5px; background: rgba(255,255,255,.08); border-radius: 14px; margin-top: 18px; box-shadow: inset 0 0 0 1px rgba(255,255,255,.12); }
.tabs a { padding: 8px 16px; border-radius: 10px; color: #dfe6f6; text-decoration: none; font-weight: 600; font-size: 14.5px; transition: background .2s, color .2s; }
.tabs a:hover { color: #fff; background: rgba(255,255,255,.08); }
.tabs a.is-active { background: var(--surface); color: var(--navy-900); }

/* фотогалерея */
.masonry { columns: 4 240px; column-gap: 16px; }
.masonry a { display: block; margin: 0 0 16px; border-radius: 14px; overflow: hidden; break-inside: avoid; position: relative; background: var(--bg-2); box-shadow: var(--shadow-1); }
.masonry img { width: 100%; height: auto; display: block; transition: transform .6s var(--ease), filter .4s; }
.masonry a::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 55%, rgba(10,19,48,.55)); opacity: 0; transition: opacity .3s; }
.masonry a:hover img { transform: scale(1.05); }
.masonry a:hover::after { opacity: 1; }
.photo-view { text-align: center; }
.photo-view img { max-height: 76vh; width: auto; border-radius: 16px; box-shadow: var(--shadow-2); }

/* поиск */
.results { display: grid; gap: 12px; }
.result { display: flex; gap: 16px; padding: 16px; border-radius: 14px; background: var(--surface); border: 1px solid var(--line); text-decoration: none; color: var(--text); transition: transform .25s var(--ease), box-shadow .25s; align-items: center; }
.result:hover { transform: translateY(-2px); box-shadow: var(--shadow-2); color: var(--text); }
.result img, .result .s-ico { width: 96px; height: 72px; border-radius: 10px; object-fit: cover; flex: none; }
.result .s-ico { background: var(--bg); color: var(--navy-600); }
.result strong { color: var(--navy-900); display: block; margin: 2px 0; line-height: 1.35; }
.result p { margin: 0; color: var(--muted); font-size: 14.5px; }
.result mark { background: var(--accent-50); color: var(--accent-600); border-radius: 4px; padding: 0 2px; }

/* =====================================================================
   ПОДВАЛ
   ===================================================================== */
.footer { background: var(--navy-900); color: #b9c5e2; margin-top: 0; position: relative; overflow: hidden; }
.footer a { color: #dfe6f6; text-decoration: none; }
.footer a:hover { color: var(--accent); }
.footer-top { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1.2fr; gap: 36px; padding: 40px 0; }
.footer h4 { color: #fff; font-size: 15px; letter-spacing: .06em; text-transform: uppercase; margin-bottom: 16px; }
.footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 9px; font-size: 15px; }
.footer .brand-name { color: #fff; font-size: 26px; }
.footer .brand-kicker { color: #9fb0d6; }
.footer-about { font-size: 14.5px; line-height: 1.6; margin: 16px 0; }
.footer-quote { font-size: 13.5px; line-height: 1.55; font-style: italic; opacity: .75; margin: 0 0 16px; max-width: 46ch; }
.footer-phone { display: flex; flex-direction: column; font-size: 19px; font-weight: 800; color: #fff !important; line-height: 1.25; }
.footer-phone span { font-size: 13px; color: #9fb0d6; font-weight: 500; }
.footer-social { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; padding: 36px 0 32px; border-bottom: 1px solid rgba(255,255,255,.1); } /* кнопки соцсетей — в начале подвала */
.footer-social a { height: 48px; border-radius: 12px; background: rgba(255,255,255,.08); display: grid; place-items: center; transition: background .2s, transform .2s var(--ease); }
.footer-social a:hover { background: var(--btn); color: #fff; transform: translateY(-2px); }
.footer-social .tg-btn { padding: 0 12px; display: flex; align-items: center; justify-content: center; gap: 8px; white-space: nowrap; font-size: 14px; font-weight: 600; color: #fff; text-decoration: none; background: #229ed9; }
.footer-social .tg-btn:hover { background: var(--tg-hover); }
.footer-social .tg-btn .icon { width: 20px; height: 20px; flex: none; }
.footer-social .wa-btn { background: var(--wa); }
.footer-social .wa-btn:hover { background: var(--wa-hover); }
/* Drive2 — в стиле их логотипа: белые буквы на красном */
.footer-social .d2-btn { background: var(--d2); padding: 0 14px; }
.footer-social .d2-btn:hover { background: var(--d2-hover); }
.d2-logo { font-weight: 900; font-style: italic; letter-spacing: .02em; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.1); padding: 20px 0 28px; display: flex; gap: 20px; justify-content: space-between; flex-wrap: wrap; font-size: 13px; color: #8392b8; }
.footer-legal { max-width: 760px; }

/* куки, наверх, лайтбокс, модалка */
.cookie { position: fixed; left: 16px; bottom: 16px; z-index: 150; max-width: 460px; background: #fff; border-radius: 16px; box-shadow: var(--shadow-3); padding: 18px; display: none; gap: 14px; flex-direction: column; align-items: stretch; font-size: 13.5px; color: #34415d; line-height: 1.5; border: 1px solid var(--line); }
.cookie.show { display: flex; animation: slide-up .5s var(--ease); }
@keyframes slide-up { from { transform: translateY(20px); opacity: 0; } }
.to-top { position: fixed; right: 18px; bottom: 18px; z-index: 140; width: 48px; height: 48px; border-radius: 14px; border: 0; background: var(--navy-800); color: #fff; display: grid; place-items: center; box-shadow: var(--shadow-2); opacity: 0; transform: translateY(16px); pointer-events: none; transition: opacity .3s, transform .3s var(--ease), background .2s; }
.to-top.show { opacity: 1; transform: none; pointer-events: auto; }
.to-top:hover { background: var(--btn); }
.lightbox { position: fixed; inset: 0; z-index: 400; background: rgba(6, 11, 28, .92); display: none; align-items: center; justify-content: center; padding: 60px 70px; }
.lightbox.open { display: flex; animation: fade .25s; }
@keyframes fade { from { opacity: 0; } }
.lightbox img { max-width: 100%; max-height: 100%; border-radius: 10px; box-shadow: 0 30px 80px rgba(0,0,0,.5); animation: pop .35s var(--ease); }
.lb-btn { position: absolute; width: 50px; height: 50px; border-radius: 14px; border: 0; background: rgba(255,255,255,.1); color: #fff; display: grid; place-items: center; transition: background .2s; }
.lb-btn:hover { background: var(--btn); }
.lb-close { top: 16px; right: 16px; }
.lb-prev { left: 14px; top: 50%; transform: translateY(-50%); }
.lb-next { right: 14px; top: 50%; transform: translateY(-50%); }
.lb-count { position: absolute; bottom: 18px; left: 50%; transform: translateX(-50%); color: #c8d2ea; font-size: 14px; }
.modal { position: fixed; inset: 0; z-index: 350; display: none; align-items: center; justify-content: center; padding: 20px; background: rgba(10, 19, 48, .6); }
.modal.open { display: flex; animation: fade .2s; }
.modal-box { background: #fff; border-radius: 20px; width: min(520px, 100%); max-height: 92vh; overflow-y: auto; padding: 28px; position: relative; box-shadow: var(--shadow-3); animation: pop .35s var(--ease); }
.modal-close { position: absolute; top: 14px; right: 14px; width: 40px; height: 40px; border: 0; border-radius: 11px; background: var(--bg); display: grid; place-items: center; }
.modal-box h3 { padding-right: 40px; }

/* появление при прокрутке */
[data-reveal].pre { opacity: 0; transform: translateY(26px); }
[data-reveal].pre.in { opacity: 1; transform: none; transition: opacity .8s var(--ease), transform .8s var(--ease); transition-delay: calc(min(var(--d, 0), 8) * 70ms); }
.hero > *, .page-head > * { animation: hero-in .8s var(--ease) backwards; /* backwards, не both: «застывшая» анимация делает блок корнем размытия и ломает стекло подсказок */ }
.hero > *:nth-child(2), .page-head > *:nth-child(2) { animation-delay: .06s; }
.hero > *:nth-child(3), .page-head > *:nth-child(3) { animation-delay: .12s; }
.hero > *:nth-child(4), .page-head > *:nth-child(4) { animation-delay: .18s; }
.hero > *:nth-child(5) { animation-delay: .24s; }
@keyframes hero-in { from { opacity: 0; transform: translateY(18px); } }

/* =====================================================================
   АДАПТИВ
   ===================================================================== */
@media (max-width: 1180px) {
  .menu-link { padding: 0 10px; font-size: 13.8px; }
  .brand-claim { display: none; }
  .carousel-track { grid-auto-columns: calc((100% - 2 * 20px) / 3); }
  .services { grid-template-columns: repeat(3, 1fr); }
  .grid-4 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .footer-top { grid-template-columns: 1fr 1fr; }
  .footer-social { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 980px) {
  :root { --header-h: 0px; }
  .topbar-note { display: none; }
  .mainnav { display: none; }
  .burger, .mobile-call { display: grid; }
  .brandbar { position: sticky; top: 0; z-index: 60; background: rgba(239,243,248,.94); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); border-bottom: 1px solid var(--line); }
  .brandbar .container { min-height: 70px; }
  .brandbar-cta .btn { display: none; }
  .brand-logo { width: 50px; height: 50px; }
  .brand-name { font-size: 24px; }
  .about-grid, .layout, .product, .cta-band { grid-template-columns: minmax(0, 1fr); }
  .aside-sticky, .buy { position: static; }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .navband-3d { width: 320px; right: -60px; opacity: .45; }
  .hero-3d { width: 360px; right: -70px; top: 14px; opacity: .55; }
  .layout aside { order: 2; }
}
@media (max-width: 760px) {
  :root { --gutter: 16px; }
  body { font-size: 15.5px; }
  .topbar .container { min-height: 38px; justify-content: center; }
  .topbar-social { display: none; }
  .topbar-contacts { gap: 14px; margin: 0; font-size: 13px; }
  .topbar-phone span { display: none; }
  .brand-kicker { font-size: 11px; }
  .section { padding-top: 44px; padding-bottom: 44px; }
  .section-head { flex-wrap: wrap; align-items: center; }
  .carousel-track { grid-auto-columns: 78%; gap: 14px; }
  .carousel-nav { display: none; }
  .services, .grid-4, .grid-3, .branches, .link-cards { grid-template-columns: minmax(0, 1fr); }
  .grid-4.products-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .products-grid .p-body { padding: 10px 12px 12px; }
  .products-grid .p-title { font-size: 14px; }
  .products-grid .price { font-size: 16px; }
  .products-grid .price-old { display: block; margin-left: 0; }
  .products-grid .p-go { display: none; }
  .s-card { min-height: 0; }
  .search-form .btn span { display: none; }
  .search-form .btn { padding: 0 14px; }
  .hero { padding: 28px 0 18px; }
  .stat { padding: 14px; }
  .form-row, .buy-actions, .post-nav { grid-template-columns: 1fr; }
  .cta-band { padding: 22px; border-radius: 18px; }
  .cta-band .form { padding: 18px; }
  .banners { aspect-ratio: 2000 / 560; border-radius: 14px; }
  .lightbox { padding: 50px 8px; }
  .lb-prev, .lb-next { top: auto; bottom: 10px; transform: none; }
  .footer-top { grid-template-columns: 1fr; gap: 26px; }
  .footer-social { grid-template-columns: minmax(0, 1fr); }
  .cookie { left: 8px; right: 8px; bottom: 8px; max-width: none; flex-direction: column; align-items: stretch; }
  .result img, .result .s-ico { width: 72px; height: 56px; }
  .masonry { columns: 2 140px; column-gap: 10px; }
  .masonry a { margin-bottom: 10px; }
  .page-head { padding: 22px 0 22px; }
  .tabs { display: flex; flex-wrap: wrap; }
  .tabs a { flex: 1 1 auto; text-align: center; padding: 8px 10px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
  [data-reveal].pre { opacity: 1; transform: none; }
}
@media print {
  .topbar, .mainnav, .navband-3d, .hero-3d, .footer, .cookie, .to-top, .burger, .search, .cta-band, .share { display: none !important; }
  .navband { background: #fff; color: #000; }
  .navband h1, .page-head h1 { color: #000; }
}
.drawer-search { padding: 14px 16px 4px; }
.drawer-search .search { margin: 0; }
.drawer-search .search-form { box-shadow: inset 0 0 0 1.5px var(--line-2); }
.grid-3.products-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 760px) { .grid-3.products-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; } }
.cookie .btn { flex: none; }
.cookie-btns { display: flex; gap: 8px; flex: none; }
.cookie-btns .btn { flex: 1; }
.branch h3 a { color: var(--navy-900); text-decoration: none; }
.branch h3 a:hover { color: var(--accent-600); }
.collapsible.collapsed { max-height: 760px; overflow: hidden; position: relative; }
.collapsible.collapsed::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 180px; background: linear-gradient(rgba(248,250,252,0), var(--surface) 85%); pointer-events: none; }
.collapse-btn { margin-top: 14px; }
.collapse-btn .icon { transition: transform .3s var(--ease); }
.collapse-btn[aria-expanded="true"] .icon { transform: rotate(180deg); }
/* картинка внутри абзаца текста — обтекание, как на исходном сайте */
.prose p > img:not(.ico), .prose p > picture > img:not(.ico), .prose p > a > img:not(.ico), .prose p > a > picture > img:not(.ico) { float: right; width: auto; max-width: min(42%, 360px); margin: 6px 0 16px 26px; display: block; border-radius: 12px; box-shadow: var(--shadow-1); background: #fff; }
.prose h2, .prose h3, .prose h4, .prose figure, .prose .table-wrap, .prose ul, .prose ol { clear: both; }
@media (max-width: 760px) {
  .prose p > img:not(.ico), .prose p > picture > img:not(.ico), .prose p > a > img:not(.ico), .prose p > a > picture > img:not(.ico) { float: none; max-width: 100%; margin: 12px auto; }
}
.hero-kicker .chip { white-space: nowrap; flex: none; }
.branch-head { flex-wrap: wrap; }

/* Каталог по машинам, АКПП и ДВС */
.cat-sections { margin-bottom: 40px; }
.side-nav a small { color: var(--muted); font-weight: 400; margin-left: auto; white-space: nowrap; }
.cat-head.content-card { padding: clamp(16px, 2vw, 24px); }
.cat-intro { margin: 4px 4px 16px; }
.cat-intro p { margin: 0 0 8px; }
.cat-facts { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 10px 18px; margin: 0; padding: 14px 16px; background: var(--bg); border-radius: var(--radius-sm); }
.cat-facts .wide { grid-column: 1 / -1; }
.cat-facts dt { color: var(--muted); font-size: 12.5px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; }
.cat-facts dd { margin: 2px 0 0; font-weight: 600; }
.cat-exp .eyebrow { margin-bottom: 4px; }
.d2-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 12px; }
.d2-list a { display: grid; gap: 6px; padding: 16px 20px; color: var(--text); text-decoration: none; }
.d2-list a:hover strong { color: var(--accent-600); }
.d2-meta { font-size: 13px; color: var(--muted); }
.d2-meta .d2-logo { color: var(--d2); }
.d2-sum { color: var(--muted); font-size: 14.5px; line-height: 1.5; }

/* --- Каталог: подбор (свои выпадающие списки) и список ссылок --- */
.cat-pick { position: relative; z-index: 20; background: var(--surface); border-radius: var(--radius); box-shadow: var(--shadow-2); padding: 26px 28px 28px; margin: 0 0 44px; border: 1px solid var(--line); }
.cat-pick::before { content: ""; position: absolute; left: 0; top: 0; right: 0; height: 4px; border-radius: var(--radius) var(--radius) 0 0; background: linear-gradient(90deg, var(--accent), var(--navy-600)); }
.cat-pick-top { padding-top: clamp(20px, 3vw, 32px); }
.cat-pick-top + .layout { padding-top: 22px; }
.cat-pick-slim { padding: 14px; margin-bottom: 0; }
.cat-pick-slim .cat-pick-head { display: none; }
.cat-pick-slim + .cat-index, .section > .cat-pick-slim { margin-bottom: 28px; }
.cat-pick-head { display: flex; align-items: baseline; gap: 14px; margin-bottom: 18px; }
.cat-pick-head h2 { margin: 0; font-size: 22px; letter-spacing: -.01em; }
.cat-pick-head .eyebrow { margin: 0; }
.cat-pick-row { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)) auto; gap: 12px; align-items: stretch; }
.cat-pick-2 .cat-pick-row { grid-template-columns: minmax(0, .8fr) minmax(0, 1.6fr) auto; }
.pick { position: relative; min-width: 0; }
.pick-btn { width: 100%; height: 64px; display: flex; align-items: center; gap: 12px; padding: 0 16px 0 12px; text-align: left; background: var(--bg); border: 1.5px solid transparent; border-radius: 12px; transition: background .2s, border-color .2s, box-shadow .25s var(--ease); }
.pick-btn:hover:not(:disabled) { background: var(--surface); border-color: var(--line-2); }
.pick-btn:focus-visible, .pick.open .pick-btn { outline: none; background: var(--surface); border-color: var(--accent); box-shadow: 0 0 0 4px rgba(31,95,214,.14); }
.pick-btn:disabled { cursor: default; opacity: .55; }
.pick-n { flex: none; width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; font-size: 13.5px; font-weight: 700; background: var(--surface); color: var(--navy-600); box-shadow: inset 0 0 0 1.5px var(--line-2); transition: background .2s, color .2s, box-shadow .2s; }
.pick.done .pick-n { background: var(--btn); color: #fff; box-shadow: none; }
.pick-txt { flex: 1; min-width: 0; display: grid; line-height: 1.25; }
.pick-label { font-size: 12px; font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; }
.pick-val { font-size: 16px; font-weight: 600; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; margin-top: 2px; }
.pick.done .pick-val { color: var(--text); }
.pick-chev { flex: none; width: 18px; height: 18px; color: var(--muted); transition: transform .3s var(--ease); }
.pick.open .pick-chev { transform: rotate(180deg); color: var(--accent); }
.pick-pop { position: absolute; left: 0; top: calc(100% + 8px); width: max(100%, 300px); z-index: 45; background: #fff; border-radius: 14px; box-shadow: var(--shadow-3); border: 1px solid var(--line); padding: 6px; opacity: 0; visibility: hidden; transform: translateY(-6px) scale(.98); transform-origin: top center; transition: opacity .18s, transform .25s var(--ease), visibility 0s .25s; }
.pick.open .pick-pop { opacity: 1; visibility: visible; transform: none; transition-delay: 0s; }
.pick.up .pick-pop { top: auto; bottom: calc(100% + 8px); transform-origin: bottom center; transform: translateY(6px) scale(.98); }
.pick.up.open .pick-pop { transform: none; }
.cat-pick:has(.pick.open) { z-index: 60; }
.pick-search { display: flex; align-items: center; gap: 8px; margin: 2px 2px 6px; padding: 0 12px; height: 42px; border-radius: 10px; background: var(--bg); }
.pick-search .icon { width: 18px; height: 18px; color: var(--muted); flex: none; }
.pick-search input { flex: 1; min-width: 0; border: 0; background: none; outline: none; font-size: 15px; height: 100%; }
.pick-list { list-style: none; margin: 0; padding: 0; max-height: 320px; overflow-y: auto; overscroll-behavior: contain; scrollbar-width: thin; }
.pick-list li { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 10px; cursor: pointer; font-size: 15px; transition: background .12s, color .12s; }
.pick-list li[hidden] { display: none; }
.pick-name { flex: 1; min-width: 0; font-weight: 600; }
.pick-list small { flex: none; color: var(--muted); font-size: 13px; text-align: right; white-space: nowrap; }
.pick-ok { flex: none; width: 16px; height: 16px; color: var(--accent); opacity: 0; }
.pick-list li.is-focus { background: var(--bg); color: var(--accent-600); }
.pick-list li[aria-selected="true"] { background: var(--accent-50); color: var(--accent-600); }
.pick-list li[aria-selected="true"] .pick-ok { opacity: 1; }
.pick-opt { flex: 1; min-width: 0; display: grid; gap: 1px; }
.pick-2l .pick-name { white-space: normal; }
.pick-2l small { flex: initial; text-align: left; white-space: normal; font-size: 13px; line-height: 1.35; }
.pick-empty { margin: 0; padding: 14px 12px; color: var(--muted); font-size: 14px; }
.pick-go { height: 64px; padding: 0 28px; border-radius: 12px; }
.pick-go[aria-disabled="true"] { background: var(--bg-2); color: var(--muted); box-shadow: none; pointer-events: none; }
.pick-go[aria-disabled="true"]::after { display: none; }

.cat-index { display: grid; gap: 22px; }
.cat-brand { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-1); padding: 22px 26px 10px; scroll-margin-top: 90px; }
.cat-brand > h2 { display: flex; align-items: center; gap: 10px; margin: 0 0 6px; font-size: 22px; }
.cat-brand > h2 span { font-size: 13px; font-weight: 600; color: var(--muted); background: var(--bg); border-radius: 999px; padding: 2px 10px; }
.cat-models, .cat-units { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 40px; }
.cat-units { grid-template-columns: repeat(3, minmax(0, 1fr)); column-gap: 28px; }
.cat-models li, .cat-units li { border-top: 1px solid var(--line); }
.cat-models li { display: flex; align-items: center; gap: 14px; padding: 11px 0; }
.cat-models li:nth-child(-n+2), .cat-units li:nth-child(-n+3) { border-top-color: transparent; }
.cat-models-name { flex: none; min-width: 150px; font-weight: 700; color: var(--navy-900); text-decoration: none; transition: color .15s; }
.cat-models-name:hover { color: var(--accent-600); }
.cat-gens { display: flex; flex-wrap: wrap; gap: 6px; }
.cat-gens a { display: inline-flex; align-items: center; height: 30px; padding: 0 11px; border-radius: 8px; background: var(--bg); color: var(--navy-700); font-size: 14px; font-weight: 600; text-decoration: none; transition: background .15s, color .15s, transform .2s var(--ease); }
.cat-gens a:hover { background: var(--btn); color: #fff; transform: translateY(-1px); }
.cat-units a { display: grid; grid-template-columns: 1fr auto; column-gap: 10px; padding: 13px 0; text-decoration: none; color: var(--text); }
.cat-units strong { color: var(--navy-900); line-height: 1.35; transition: color .15s; }
.cat-units span { grid-column: 1; color: var(--muted); font-size: 13.5px; line-height: 1.4; margin-top: 3px; }
.cat-units .icon { grid-column: 2; grid-row: 1 / span 2; align-self: center; width: 16px; height: 16px; color: var(--accent); opacity: 0; transform: translateX(-6px); transition: opacity .2s, transform .25s var(--ease); }
.cat-units a:hover strong { color: var(--accent-600); }
.cat-units a:hover .icon { opacity: 1; transform: none; }
@media (max-width: 960px) {
  .cat-units { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .cat-units li:nth-child(3) { border-top-color: var(--line); }
  .cat-pick-row, .cat-pick-2 .cat-pick-row { grid-template-columns: 1fr; }
  .pick-pop { width: 100%; }
  .pick-go { height: 54px; }
}
@media (max-width: 760px) {
  .cat-pick { padding: 20px 16px; margin-bottom: 28px; }
  .cat-pick-top { padding-top: clamp(24px, 3vw, 36px); }
.cat-pick-slim { padding: 14px; margin-bottom: 0; }
.cat-pick-slim .cat-pick-head { display: none; }
.cat-pick-slim + .cat-index, .section > .cat-pick-slim { margin-bottom: 28px; }
.cat-pick-head { flex-direction: column; gap: 2px; }
  .cat-pick-head h2 { font-size: 20px; }
  .pick-btn { height: 58px; }
  .cat-brand { padding: 18px 16px 6px; }
  .cat-models, .cat-units { grid-template-columns: 1fr; }
  .cat-models li:nth-child(2), .cat-units li:nth-child(n+2) { border-top-color: var(--line); }
  .cat-models li { flex-wrap: wrap; gap: 8px 12px; }
  .cat-models-name { min-width: 92px; }
}

/* =====================================================================
   ТЁМНАЯ ТЕМА. Включается атрибутом data-theme="dark" на <html> (js/theme.js —
   по выбору посетителя или настройке системы). Палитра — те же синие тона
   бренда, только глубже: фон почти чёрный с синевой, карточки чуть светлее,
   акцент и ссылки ярче, чтобы читались на тёмном.
   ===================================================================== */
:root { color-scheme: light; }
:root[data-theme="dark"] {
  color-scheme: dark;
  --navy-950: #050a18;
  --navy-900: #e6ecf8;   /* в светлой теме — тёмные заголовки; здесь — светлые */
  --navy-800: #15214a;   /* синие блоки (шапка, меню, кнопки) */
  --navy-700: #22336a;
  --navy-600: #8ea4d8;   /* значки */
  --navy-300: #9fb0d6;
  --bg: #0b1222;
  --bg-2: #101a2e;
  --surface: #121b30;
  --surface-2: #121b30;
  --field: #121b30;
  --line: #22304d;
  --line-2: #33456b;
  --text: #d5ddec;
  --muted: #8f9cb8;
  --accent: #4b8bff;
  --accent-600: #82adff;
  --accent-50: rgba(75, 139, 255, .14);
  --green: #3fcf8e;
  --green-50: rgba(63, 207, 142, .13);
  --red: #ff8080;
  --red-50: rgba(255, 107, 107, .12);
  --link: #7eaaff;
  --btn: #2f6fe4;        /* белый текст 4,7:1 (на #4b8bff было 3,3:1) */
  --btn-hover: #2559c2;  /* при наведении темнее, а не светлее: на #82adff белый был 2,2:1 */
  --placeholder: #7d89a3;
  --field-border: #5a6b92;
  --brand-red: #ef4b67;
  --shadow-1: 0 1px 2px rgba(0, 0, 0, .35), 0 2px 8px rgba(0, 0, 0, .25);
  --shadow-2: 0 12px 30px -10px rgba(0, 0, 0, .6), 0 2px 6px rgba(0, 0, 0, .3);
  --shadow-3: 0 24px 60px -20px rgba(0, 0, 0, .75);
}
/* что в светлой теме белое или «тёмно-синим текстом» — на тёмном переводим на поверхности */
[data-theme="dark"] .search-form, [data-theme="dark"] .suggest, [data-theme="dark"] .submenu,
[data-theme="dark"] .drawer-panel, [data-theme="dark"] .drawer-head, [data-theme="dark"] .table-wrap,
[data-theme="dark"] .link-card, [data-theme="dark"] .cta-band .form, [data-theme="dark"] .input,
[data-theme="dark"] .select, [data-theme="dark"] .textarea, [data-theme="dark"] .post-nav a,
[data-theme="dark"] .pager a, [data-theme="dark"] .pager span:not(.current), [data-theme="dark"] .result,
[data-theme="dark"] .cookie, [data-theme="dark"] .modal-box, [data-theme="dark"] .gallery-thumbs button,
[data-theme="dark"] .banners, [data-theme="dark"] .pick-pop, [data-theme="dark"] .pick-n { background: var(--surface); }
[data-theme="dark"] .menu-link { background: rgba(255, 255, 255, .07); color: var(--text); }
[data-theme="dark"] .menu-link.is-active { background: var(--accent-50); color: #fff; }
[data-theme="dark"] .mainnav { border-top-color: rgba(255, 255, 255, .05); }
[data-theme="dark"] .mainnav.stuck { background: rgba(14, 22, 48, .92); }
[data-theme="dark"] .navband { background: linear-gradient(180deg, #121c40, #15214a); }
[data-theme="dark"] .footer { background: #070c19; }
[data-theme="dark"] .topbar { background: #0e1628; }
[data-theme="dark"] .tabs a.is-active { background: var(--surface); color: #fff; }
[data-theme="dark"] .prose { color: #cbd4e6; }
[data-theme="dark"] .prose em, [data-theme="dark"] .prose i { color: #b3bfd6; }
[data-theme="dark"] .prose tr:nth-child(even) td { background: rgba(255, 255, 255, .03); }
[data-theme="dark"] .prose p > img:not(.ico), [data-theme="dark"] .prose p > picture > img:not(.ico) { background: var(--surface); }
[data-theme="dark"] .prose img, [data-theme="dark"] .p-media img, [data-theme="dark"] .n-media img,
[data-theme="dark"] .masonry img, [data-theme="dark"] .post-cover img { filter: brightness(.92); }
[data-theme="dark"] .branch-list li, [data-theme="dark"] .buy-note, [data-theme="dark"] .cookie { color: var(--text); }
[data-theme="dark"] .branch-status.closed, [data-theme="dark"] .alert-err { background: rgba(255, 107, 107, .12); color: #ff9a9a; }
[data-theme="dark"] .alert-ok { color: #7fe0b2; }
[data-theme="dark"] .p-media, [data-theme="dark"] .gallery-main { background: linear-gradient(180deg, #1a2440, #121b30); }
[data-theme="dark"] .p-badges .chip, [data-theme="dark"] .n-media .chip, [data-theme="dark"] .gallery-zoom { background: rgba(12, 19, 36, .85); }
[data-theme="dark"] .map-embed { background-color: #101a2e; }
[data-theme="dark"] .pick-btn:hover:not(:disabled), [data-theme="dark"] .pick-btn:focus-visible, [data-theme="dark"] .pick.open .pick-btn { background: var(--surface); }
[data-theme="dark"] .collapsible.collapsed::after { background: linear-gradient(rgba(18, 27, 48, 0), var(--surface) 85%); }
/* текст, который в светлой теме был тёмно-синим, на тёмных кнопках и плашках — светлым */
[data-theme="dark"] .btn-ghost, [data-theme="dark"] .carousel-btn, [data-theme="dark"] .p-go,
[data-theme="dark"] .prose h4, [data-theme="dark"] .share a, [data-theme="dark"] .share button,
[data-theme="dark"] .pager a, [data-theme="dark"] .cat-chip, [data-theme="dark"] .chip,
[data-theme="dark"] .link-more, [data-theme="dark"] .cat-gens a, [data-theme="dark"] .gallery-zoom { color: var(--text); }
[data-theme="dark"] .btn-ghost:hover { color: #fff; box-shadow: inset 0 0 0 1.5px var(--navy-600); }
[data-theme="dark"] .cat-chip.is-active { background: var(--btn); border-color: var(--btn); }
[data-theme="dark"] .banner-dots button { background: rgba(255, 255, 255, .3); }
[data-theme="dark"] .btn-navy { background: var(--navy-700); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .1); }
[data-theme="dark"] .btn-navy:hover { background: var(--btn); }
[data-theme="dark"] .to-top { background: var(--navy-700); box-shadow: var(--shadow-2), inset 0 0 0 1px rgba(255, 255, 255, .12); }
[data-theme="dark"] .s-card::before { background: radial-gradient(circle, rgba(75, 139, 255, .18), transparent 65%); }
@media (max-width: 980px) {
  [data-theme="dark"] .brandbar { background: rgba(11, 18, 34, .92); }
}

/* логотип: днём — синий, ночью — светлый */
.logo-night { display: none; }
[data-theme="dark"] .brandbar .logo-day { display: none; }
[data-theme="dark"] .brandbar .logo-night { display: block; }

/* переключатель темы: в светлой теме — луна, в тёмной — солнце */
.theme-toggle { flex: none; width: 34px; height: 34px; border-radius: 10px; border: 0; padding: 0; display: grid; place-items: center; background: var(--bg); color: var(--navy-700); box-shadow: inset 0 0 0 1px var(--line); transition: background .2s, color .2s, transform .3s var(--ease); }
.theme-toggle:hover { background: var(--btn); color: #fff; box-shadow: none; }
.theme-toggle .icon { grid-area: 1 / 1; width: 18px; height: 18px; transition: transform .45s var(--ease), opacity .25s; }
.theme-toggle .tt-sun { opacity: 0; transform: rotate(-90deg) scale(.5); }
[data-theme="dark"] .theme-toggle { color: #ffd479; }
[data-theme="dark"] .theme-toggle:hover { color: #fff; }
[data-theme="dark"] .theme-toggle .tt-moon { opacity: 0; transform: rotate(90deg) scale(.5); }
[data-theme="dark"] .theme-toggle .tt-sun { opacity: 1; transform: none; }
/* в синем меню — светлая кнопка; там она видна только в липком режиме, вверху страницы есть кнопка в верхней строке */
.mainnav .theme-toggle { display: none; width: 40px; height: 40px; border-radius: 11px; background: rgba(255, 255, 255, .1); color: #fff; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .18); }
.mainnav.stuck .theme-toggle { display: grid; }
/* телефон в липком меню — круглой кнопкой: номер целиком вместе с переключателем не помещался */
.nav-phone span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.mainnav.stuck .nav-phone { flex: none; width: 40px; height: 40px; border-radius: 11px; justify-content: center; margin-left: 0; background: rgba(255, 255, 255, .1); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .18); transition: background .2s; }
.mainnav.stuck .nav-phone:hover { background: var(--btn); color: #fff; }
.mainnav.stuck .menu-link { padding: 0 8px; }
@media (min-width: 1240px) { .mainnav.stuck .nav-phone { display: inline-flex; } }
@media (max-width: 1120px) { .mainnav.stuck .menu { gap: 4px; } .mainnav.stuck .menu-link { padding: 0 6px; font-size: 13.2px; } }
.mainnav .theme-toggle:hover { background: var(--btn); }
/* в шапке с логотипом кнопка нужна только на телефоне/планшете: там липкая — она */
.brandbar-cta .theme-toggle { display: none; width: 46px; height: 46px; border-radius: 12px; }
.brandbar-cta .theme-toggle .icon { width: 22px; height: 22px; }
@media (max-width: 980px) { .brandbar-cta .theme-toggle { display: grid; } }
@media (max-width: 980px) { .topbar .theme-toggle { display: none; } }
@media (min-width: 981px) and (max-width: 1100px) { .topbar-phone span { display: none; } } /* иначе кнопка темы не влезает в строку */

/* плавная смена темы: круг расходится от нажатой кнопки (View Transitions), иначе — мягкое затухание цветов */
html.theme-vt::view-transition-old(root), html.theme-vt::view-transition-new(root) { animation: none; mix-blend-mode: normal; }
html.theme-fade, html.theme-fade *, html.theme-fade *::before, html.theme-fade *::after { transition: background-color .35s ease, color .35s ease, border-color .35s ease, box-shadow .35s ease !important; }

/* =====================================================================
   СТЕКЛО (в духе iOS): полупрозрачные меню, выпадающие списки, липкие
   панели и всплывающие окна с размытием того, что под ними. Правила с
   префиксом :root — чтобы перекрыть и светлые, и тёмные фоны выше.
   Без поддержки backdrop-filter — почти непрозрачный фон (читаемость важнее).
   ===================================================================== */
:root {
  --glass: rgba(255, 255, 255, .5);
  --glass-strong: rgba(255, 255, 255, .62);
  --glass-edge: rgba(255, 255, 255, .75);
  --glass-rim: rgba(15, 26, 61, .1);
  /* блик: светлая полоса по верхнему краю, как у стекла iOS */
  --glass-sheen: linear-gradient(180deg, rgba(255, 255, 255, .55), rgba(255, 255, 255, .12) 28%, rgba(255, 255, 255, 0) 60%);
  --glass-line: rgba(15, 26, 61, .08);
  --glass-hover: rgba(15, 26, 61, .06);
  --glass-blur: saturate(1.9) blur(18px);
  --glass-navy: rgba(22, 35, 74, .62);
  --glass-bar: rgba(15, 26, 54, .78); /* липкое меню: однотонный глубокий navy */
}
:root[data-theme="dark"] {
  --glass: rgba(18, 28, 52, .46);
  --glass-strong: rgba(16, 25, 46, .6);
  --glass-edge: rgba(255, 255, 255, .16);
  --glass-rim: rgba(0, 0, 0, .35);
  --glass-sheen: linear-gradient(180deg, rgba(255, 255, 255, .13), rgba(255, 255, 255, .03) 30%, rgba(255, 255, 255, 0) 60%);
  --glass-line: rgba(255, 255, 255, .07);
  --glass-hover: rgba(255, 255, 255, .07);
  --glass-navy: rgba(12, 19, 42, .62);
  --glass-bar: rgba(9, 15, 34, .8);
}
@supports not ((backdrop-filter: blur(1px)) or (-webkit-backdrop-filter: blur(1px))) {
  :root, :root[data-theme] { --glass-sheen: none; }
  :root { --glass: rgba(255, 255, 255, .97); --glass-strong: #fff; --glass-navy: rgba(22, 35, 74, .97); }
  :root[data-theme="dark"] { --glass: rgba(18, 27, 48, .97); --glass-strong: #121b30; --glass-navy: rgba(12, 19, 42, .97); }
}

/* всплывающие слои: подменю, подсказки поиска, списки подбора, плашка cookie, окно заявки */
:root .submenu, :root .suggest, :root .pick-pop, :root .cookie, :root .modal-box {
  background: var(--glass-sheen), var(--glass);
  -webkit-backdrop-filter: var(--glass-blur); backdrop-filter: var(--glass-blur);
  border: 1px solid var(--glass-edge);
  /* тонкая светлая грань сверху, тёмный кант по краю и мягкая тень — стекло «отрывается» от страницы */
  box-shadow: 0 0 0 .5px var(--glass-rim), 0 24px 60px -18px rgba(10, 19, 48, .45), inset 0 1px 0 var(--glass-edge), inset 0 -1px 0 rgba(255, 255, 255, .08);
}
:root .modal-box, :root .cookie, :root .suggest { background: var(--glass-sheen), var(--glass-strong); } /* в подсказках много текста — стекло плотнее */
:root .suggest a { border-bottom-color: var(--glass-line); }
:root .suggest a:hover, :root .suggest a.active, :root .pick-list li.is-focus, :root .submenu a:hover { background: var(--glass-hover); }
:root .suggest img, :root .suggest .s-ico, :root .pick-search, :root .modal-close { background: var(--glass-hover); }

/* подменю: раскрывается «пружиной» из-под пункта, пункты проявляются по очереди */
:root .submenu { transform: translateY(10px) scale(.96); transform-origin: top left; transition: opacity .22s, transform .38s cubic-bezier(.34, 1.4, .64, 1), visibility 0s .38s; }
.menu > li:last-child .submenu, .menu > li:nth-last-child(2) .submenu { transform-origin: top right; }
.submenu li { opacity: 0; transform: translateY(-4px); transition: opacity .25s, transform .3s var(--ease); }
.menu > li:hover > .submenu li, .menu > li:focus-within > .submenu li { opacity: 1; transform: none; }
.submenu li:nth-child(2) { transition-delay: .03s; } .submenu li:nth-child(3) { transition-delay: .06s; }
.submenu li:nth-child(4) { transition-delay: .09s; } .submenu li:nth-child(5) { transition-delay: .12s; }
.submenu li:nth-child(6) { transition-delay: .15s; } .submenu li:nth-child(n+7) { transition-delay: .18s; }
:root .suggest { transform: translateY(-8px) scale(.98); transform-origin: top center; transition: opacity .2s, transform .32s cubic-bezier(.34, 1.3, .64, 1); }
:root .suggest.open { transform: none; }

/* пункты главного меню — стеклянные «таблетки» на синем, с бликом сверху */
:root .menu-link {
  background: rgba(255, 255, 255, .1); color: #fff;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .16), inset 0 1px 0 rgba(255, 255, 255, .22);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
}
:root .menu-link .icon { color: rgba(255, 255, 255, .7); }
:root .menu > li:hover > .menu-link, :root .menu-link:focus-visible {
  background: var(--btn); color: #fff; transform: translateY(-1px);
  box-shadow: 0 10px 24px -10px rgba(31, 95, 214, .9), inset 0 1px 0 rgba(255, 255, 255, .3);
}
:root .menu-link.is-active { background: #fff; color: var(--accent-600); box-shadow: 0 6px 18px -10px rgba(0, 0, 0, .6); }
:root .menu-link.is-active .icon { color: var(--accent-600); }
:root[data-theme="dark"] .menu-link { background: rgba(255, 255, 255, .06); color: var(--text); }
:root[data-theme="dark"] .menu-link.is-active { background: var(--accent-50); color: #fff; box-shadow: inset 0 0 0 1.5px var(--accent); }
:root[data-theme="dark"] .menu-link.is-active .icon { color: #fff; }

/* липкие панели: меню на компьютере и шапка на телефоне */
/* размытие липкого меню — на подложке ::before: элемент с backdrop-filter не даёт размывать фон
   вложенным подменю (они видели бы только само меню, без страницы под ним) */
:root .mainnav.stuck { background: transparent; border-top-color: transparent; -webkit-backdrop-filter: none; backdrop-filter: none; box-shadow: 0 12px 32px -16px rgba(5, 10, 25, .55), inset 0 -1px 0 rgba(255, 255, 255, .08); }
/* в липком меню пункты — в тон подложке, чуть светлее, без бликов */
:root .mainnav.stuck .menu-link { background: rgba(255, 255, 255, .07); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .09); -webkit-backdrop-filter: none; backdrop-filter: none; }
:root .mainnav.stuck .menu > li:hover > .menu-link, :root .mainnav.stuck .menu-link:focus-visible { background: var(--btn); box-shadow: 0 8px 20px -10px rgba(31, 95, 214, .8); }
:root .mainnav.stuck .menu-link.is-active { background: rgba(255, 255, 255, .16); color: #fff; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .22); }
:root .mainnav.stuck .menu-link.is-active .icon { color: #fff; }
.mainnav::before { content: ""; position: absolute; inset: -1px 0 0; z-index: -1; background: var(--glass-bar); -webkit-backdrop-filter: blur(20px) saturate(180%); backdrop-filter: blur(20px) saturate(180%); opacity: 0; pointer-events: none; }
/* без плавного проявления: пока подложка «проявлялась», панель была прозрачной и над пунктами меню
   просвечивала полоса страницы — выглядело как зазор над липким меню */
.mainnav.stuck::before { opacity: 1; }
/* в мобильном меню панель сама стеклянная — подсказкам поиска внутри нужен плотный фон */
:root .drawer .suggest { background: var(--glass-strong); -webkit-backdrop-filter: none; backdrop-filter: none; }
@media (max-width: 980px) {
  :root .brandbar { background: var(--glass-sheen), var(--glass-strong); -webkit-backdrop-filter: var(--glass-blur); backdrop-filter: var(--glass-blur); border-bottom-color: var(--glass-line); }
}

/* мобильное меню: стеклянная панель, затемнение с размытием, пункты въезжают по очереди */
:root .drawer-panel { background: var(--glass-sheen), var(--glass-strong); -webkit-backdrop-filter: var(--glass-blur); backdrop-filter: var(--glass-blur); border-left: 1px solid var(--glass-edge); box-shadow: -20px 0 60px -20px rgba(0, 0, 0, .4); }
:root .drawer-head { background: transparent; border-bottom-color: var(--glass-line); }
:root .drawer details { border-bottom-color: var(--glass-line); }
:root .drawer details a:hover, :root .drawer-close { background: var(--glass-hover); }
:root .drawer-contacts { background: var(--glass-hover); }
.drawer-backdrop, .modal { -webkit-backdrop-filter: blur(6px) saturate(1.2); backdrop-filter: blur(6px) saturate(1.2); }
.drawer nav > * { opacity: 0; transform: translateX(24px); transition: opacity .3s, transform .45s var(--ease); }
.drawer.open nav > * { opacity: 1; transform: none; }
.drawer.open nav > :nth-child(2) { transition-delay: .04s; } .drawer.open nav > :nth-child(3) { transition-delay: .08s; }
.drawer.open nav > :nth-child(4) { transition-delay: .12s; } .drawer.open nav > :nth-child(5) { transition-delay: .16s; }
.drawer.open nav > :nth-child(6) { transition-delay: .2s; } .drawer.open nav > :nth-child(n+7) { transition-delay: .24s; }

/* кнопка «наверх», кнопки галереи — тоже стекло */
:root .to-top { background: var(--glass-navy); -webkit-backdrop-filter: var(--glass-blur); backdrop-filter: var(--glass-blur); box-shadow: var(--shadow-2), inset 0 0 0 1px rgba(255, 255, 255, .16); }
:root .to-top:hover { background: var(--btn); }
.lb-btn { -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .15); }
.lightbox { -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); }

/* окно заявки и плашка cookie появляются мягко, с лёгким увеличением */
.modal.open .modal-box { animation: glass-pop .45s cubic-bezier(.34, 1.3, .64, 1); }
.cookie.show { animation: glass-pop .5s cubic-bezier(.34, 1.3, .64, 1); }
@keyframes glass-pop { from { opacity: 0; transform: translateY(14px) scale(.96); } }

/* на телефоне модель — едва заметный фон, чтобы не спорить с заголовком */
@media (max-width: 760px) { .hero-3d { width: 340px; right: -110px; top: 130px; opacity: .35; } }
/* тёмное стекло над яркими фото: лёгкая тень у букв держит контраст */
[data-theme="dark"] .submenu a, [data-theme="dark"] .suggest a, [data-theme="dark"] .pick-list li { text-shadow: 0 1px 2px rgba(0, 0, 0, .45); }

/* ---------- большие экраны ----------
   На 1920+ колонка 1240px оставляет по 340px пустоты с краёв, а на 2560 (27" QHD, 4K с масштабом 150%)
   шрифт 16px читается как мелкий. Чуть шире колонка, дальше — пропорциональное увеличение всей
   страницы (zoom: макет, отступы и картинки растут вместе, строки текста остаются ~75 символов). */
@media (min-width: 1680px) { :root { --container: 1360px; } }
@media (min-width: 2200px) { html { zoom: 1.2; } }
@media (min-width: 3000px) { html { zoom: 1.5; } }
/* узкие телефоны (360–400): кнопка темы, звонок и меню наезжали на «ТрансЛаб» */
@media (max-width: 400px) {
  .brandbar .container { gap: 10px; }
  .brandbar-cta { gap: 6px; }
  .brandbar-cta .theme-toggle, .mobile-call, .burger { width: 42px; height: 42px; }
  .brand { gap: 8px; }
  .brand-logo { width: 44px; height: 44px; }
  .brand-name { font-size: 21px; }
}
