/* ============================================================
   Сувенир Плюс — тема v3 (редизайн 2026)
   Чистый современный e-commerce. Без jQuery, без WP-наследия.
   ============================================================ */

/* ---------- Шрифт ----------
   Manrope, вариативный (все веса 400–800 в одном файле на сабсет),
   захостен локально в /assets/v3/fonts/. Больше не грузим Google Fonts.
   Критичные сабсеты (cyrillic, latin) предзагружаются в _layout.twig. */
@font-face {
  font-family: 'Manrope';
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url(fonts/manrope-cyrillic.woff2) format('woff2');
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: 'Manrope';
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url(fonts/manrope-latin.woff2) format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Manrope';
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url(fonts/manrope-latin-ext.woff2) format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

/* ---------- Токены ----------
   палитра: design-system.html в корне репо */
:root {
  --ink: #292929;          /* основной текст / тёмный фон */
  --ink-2: #1f2330;        /* футер */
  --ink-3: #393939;        /* вторичный тёмный */
  --muted: #6f6f6f;        /* вторичный текст */
  --gray-2: #9a9a9a;
  --gray-3: #c3c3c3;       /* бордеры, приглушённый текст на тёмном */
  --accent: #b43637;       /* фирменный красный — главный акцент */
  --accent-hover: #9c2e2f;
  --accent-soft: #f7eceb;  /* мягкий розовый фон */
  --accent-light: #e86b6c; /* светлый акцент на тёмном фоне */
  --blue: #2f7bd6;         /* инфо-синий */
  --blue-soft: #e6effa;
  --amber: #ff7a00;        /* тёплый акцент */
  --amber-soft: #fff1e2;
  --bg: #ffffff;
  --bg-soft: #f1f3f5;
  --bg-dark-grad: linear-gradient(135deg, #393939 0%, #292929 100%);
  --line: #e6e6e6;
  --ok: #2fb45a;
  --radius: 20px;
  --radius-sm: 12px;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, .06);
  --shadow-md: 0 6px 24px -6px rgba(0, 0, 0, .10);
  --shadow-lg: 0 24px 64px -16px rgba(0, 0, 0, .22);
  --container: 1200px;
  --font: "Manrope", "Segoe UI", system-ui, -apple-system, Arial, sans-serif;
}

/* ---------- Сброс ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.65;
  color: var(--ink);
  background: var(--bg);
}
img { max-width: 100%; height: auto; }
a { color: var(--ink-3); text-decoration: none; transition: color .15s ease; }
a:hover { color: var(--accent); }
h1, h2, h3, h4, h5 { line-height: 1.25; font-weight: 800; color: var(--ink); margin: 0 0 .6em; }
h1 { font-size: clamp(34px, 4.6vw, 56px); letter-spacing: -.03em; line-height: 1.08; }
h2 { font-size: clamp(26px, 3.4vw, 40px); letter-spacing: -.025em; line-height: 1.12; }
h3 { font-size: 20px; }
h5 { font-size: 13px; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
p { margin: 0 0 1em; }
table { border-collapse: collapse; }
button { font-family: inherit; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* ---------- Каркас ---------- */
.container { width: 100%; }
.container > .content {
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 20px;
}
.section { padding: 64px 0; }

/* ---------- Кнопки ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 16px 32px;
  border: 1.5px solid var(--ink);
  border-radius: 999px;
  background: transparent;
  color: var(--ink);
  font-weight: 700;
  font-size: 15px;
  line-height: 1.2;
  cursor: pointer;
  white-space: nowrap;
  transition: all .18s ease;
}
.btn:hover { border-color: var(--accent); color: var(--accent); transform: translateY(-2px); }
.btn-order:hover, .btn-form-submit:hover { transform: translateY(-2px) scale(1.02); }
.btn-order, .btn-form-submit {
  background: linear-gradient(135deg, #c4494a 0%, #b43637 100%);
  border-color: transparent;
  color: #fff;
  box-shadow: 0 8px 18px -6px rgba(180, 54, 55, .5);
}
.btn-order:hover, .btn-form-submit:hover {
  background: linear-gradient(135deg, #b43637 0%, #9c2e2f 100%);
  border-color: transparent;
  color: #fff;
  box-shadow: 0 10px 22px -6px rgba(180, 54, 55, .6);
}
.btn-light { border-color: rgba(255,255,255,.6); color: #fff; }
.btn-light:hover { border-color: #fff; color: #fff; background: rgba(255,255,255,.1); }
.btn[disabled] { opacity: .55; pointer-events: none; }

/* ============================================================
   Шапка
   ============================================================ */
.site-header { position: sticky; top: 0; z-index: 900;
  background: linear-gradient(140deg, #c4494a 0%, #b43637 45%, #8f292a 100%);
  background-attachment: fixed; }

.header-topbar { background: transparent; color: rgba(255,255,255,.85); font-size: 13.5px; }
.header-topbar .content {
  display: flex; align-items: flex-end;
  gap: 16px; min-height: 44px; padding-bottom: 6px; flex-wrap: wrap;
}
.header-topbar a { color: #ececec; font-weight: 600; }
.header-topbar a:hover { color: #fff; }
.topbar-msgrs { display: inline-flex; align-items: center; gap: 10px; }
.topbar-msgrs img { width: 18px; height: 18px; display: block; }
.topbar-right { display: flex; align-items: center; gap: 16px; margin-left: auto; }
.topbar-schedule { color: rgba(255,255,255,.7); }

.header-main {
  background: transparent;
  border-bottom: 0;
  transition: box-shadow .2s ease;
}
.is-scrolled .site-header { box-shadow: var(--shadow-md); }
.header-main .content {
  display: flex; align-items: center; gap: 28px; min-height: 50px; padding-bottom: 8px;
}

/* Бесшовная шапка на главной.
   background-attachment:fixed на мобилках не якорится к вьюпорту, поэтому
   шапка и hero рисовали один и тот же 140deg-градиент каждый по своему боксу
   разной высоты — на стыке появлялся шов. Решение: на главной шапка в самом
   верху прозрачна, а красный фон под ней даёт сам hero (единый градиент, без шва).
   hero подтянут вверх под шапку на её высоту (--hdr-h ставит theme.js).
   При скролле шапка получает свой градиент-бар (см. .is-scrolled ниже). */
body.home .hero {
  margin-top: calc(-1 * var(--hdr-h, 114px));
  padding-top: var(--hdr-h, 114px);
}
body.home .site-header { background: transparent; }
body.home.is-scrolled .site-header {
  background: linear-gradient(140deg, #c4494a 0%, #b43637 45%, #8f292a 100%);
}

/* Логотип */
.site-logo a { display: flex; align-items: center; gap: 12px; color: #fff; }
.logo-mark {
  display: flex; align-items: center; justify-content: center;
  width: auto; height: 50px; max-height: 75px; flex-shrink: 0;
}
.logo-mark img { width: auto; height: 100%; object-fit: contain; }
.logo-text { line-height: 1.15; }
.logo-sign { font-size: 19px; font-weight: 800; letter-spacing: -.01em; white-space: nowrap; }
.logo-sub { font-size: 11.5px; color: rgba(255,255,255,.72); }

/* Навигация */
.main-nav { margin-left: auto; }
.main-nav > ul { display: flex; gap: 2px; margin: 0; padding: 0; list-style: none; }
.main-nav > ul > li { position: relative; }
.main-nav > ul > li > a {
  display: block; padding: 10px 14px; border-radius: var(--radius-sm);
  font-weight: 700; font-size: 15px; color: #fff; white-space: nowrap;
}
.main-nav > ul > li > a:hover,
.main-nav > ul > li.open > a { background: var(--accent-soft); color: var(--accent); }
/* последний пункт — текст вплотную к правому краю контейнера (в ряд с телефонами) */
.main-nav > ul > li:last-child > a { padding-right: 0; }
.nav-caret { display: inline-block; margin-left: 5px; width: 8px; height: 8px;
  border-right: 1.8px solid currentColor; border-bottom: 1.8px solid currentColor;
  transform: rotate(45deg) translateY(-3px); opacity: .55; }

/* Мега-меню услуг — строится из дочерних страниц services (см. header.twig).
   Пункты раскладываются по колонкам; группы и ссылки не рвутся между колонками. */
.mega {
  position: absolute; top: calc(100% + 8px); left: 50%;
  columns: 3; column-gap: 40px;
  visibility: hidden; opacity: 0;
  transform: translateX(-50%) translateY(6px);
  transition: opacity .16s ease, transform .16s ease, visibility 0s linear .25s;
  background: #fff; border: 1px solid var(--line);
  border-radius: var(--radius); box-shadow: var(--shadow-lg);
  padding: 26px 30px; width: 760px; max-width: 92vw; z-index: 950;
}
/* невидимый мостик поверх зазора — ховер не срывается по пути к панели */
.mega::before { content: ""; position: absolute; left: 0; right: 0; top: -14px; height: 14px; }
.main-nav li:hover > .mega, .main-nav li.open > .mega {
  visibility: visible; opacity: 1;
  transform: translateX(-50%) translateY(0);
  transition-delay: 0s;
}
/* группа-раздел (родитель с подстраницами, напр. «Сублимационная печать»):
   заголовок — обычная жирная ссылка-категория, дочерние — с отступом; сверху воздух,
   чтобы не липла к предыдущему пункту в колонке */
.mega-group { break-inside: avoid; margin-top: 14px; margin-bottom: 16px; }
.mega-group h5 { margin: 0 0 2px; font-size: 14.5px; font-weight: 700; text-transform: none; letter-spacing: 0; color: var(--ink); }
.mega-group h5 a { color: var(--ink); }
.mega-group h5 a:hover { color: var(--accent); }
.mega-link { display: block; padding: 5px 0; font-size: 14.5px; color: var(--ink); font-weight: 500; break-inside: avoid; }
.mega-group > a { display: block; padding: 5px 0; font-size: 14.5px; color: var(--ink); font-weight: 500; }
.mega-link:hover, .mega-group > a:hover { color: var(--accent); }

/* CTA + бургер */
.header-cta { flex-shrink: 0; }
.nav-burger {
  display: none; flex-direction: column; gap: 5px; padding: 12px 10px;
  background: none; border: 0; cursor: pointer;
}
.nav-burger span { width: 24px; height: 2.5px; background: #fff; border-radius: 2px; transition: .2s; }

/* Лупа в строке шапки и блок контактов в меню — только на мобилке
   (на десктопе поиск — в строке поиска, телефон/график/мессенджеры — в верхней плашке) */
.header-search-icon { display: none; color: #fff; }
.header-search-icon:hover { color: #fff; }
.header-mobile-contacts { display: none; }
.menu-contacts { display: none; }

/* Поиск в шапке */
.header-search {
  position: relative;
  display: flex; align-items: center; flex: 0 1 380px;
  background: #fff; border: 1.5px solid var(--line); border-radius: var(--radius-sm);
  transition: border-color .15s ease, box-shadow .15s ease;
}
.header-search:focus-within { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.header-search--menu { display: none; }
.header-search-field {
  flex: 1; min-width: 0; padding: 9px 2px 9px 14px;
  border: 0; background: none; outline: none; font: inherit; font-size: 14.5px; color: var(--ink);
}
.header-search-field::placeholder { color: var(--muted); }
.header-search-submit {
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
  padding: 8px 12px; background: none; border: 0; color: var(--muted); cursor: pointer;
  transition: color .15s ease;
}
.header-search-submit:hover { color: var(--accent); }
.header-search-drop {
  position: absolute; top: calc(100% + 6px); left: 0; right: 0; z-index: 960;
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius-sm);
  box-shadow: var(--shadow-lg); max-height: 70vh; overflow-y: auto;
}
.header-search-item {
  display: flex; align-items: center; gap: 10px; padding: 9px 14px;
  color: var(--ink); border-bottom: 1px solid var(--line);
}
.header-search-item:hover, .header-search-item.active { background: var(--accent-soft); }
.hs-item-t { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 14px; font-weight: 600; }
.hs-item-p { flex-shrink: 0; color: var(--accent); font-weight: 700; white-space: nowrap; font-size: 13.5px; }
.header-search-all {
  display: block; padding: 10px 14px; text-align: center;
  font-size: 13px; font-weight: 700; color: var(--accent);
  background: var(--accent-soft);
}
.header-search-all.active { background: var(--accent); color: #fff; }
.header-search-empty { padding: 12px 14px; color: var(--muted); font-size: 13.5px; }

/* Страница поиска /search/ */
.search-page .content { padding-top: 44px; padding-bottom: 64px; }
.search-page .search-input {
  width: 100%; max-width: 560px; margin: 6px 0 4px; padding: 13px 18px;
  font: inherit; font-size: 16px; color: var(--ink);
  background: #fff; border: 1.5px solid var(--line); border-radius: var(--radius-sm); outline: none;
}
.search-page .search-input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.search-stat { color: var(--muted); font-size: 14px; margin: 6px 0 18px; }
/* тулбар и сетка результатов переиспользуют стили каталога (.listing-toolbar, .items-container, .item*) */
.search-page .listing-toolbar { margin: 10px 0 4px; }

/* ============================================================
   Хлебные крошки
   ============================================================ */
.menu-container { background: var(--bg-soft); border-bottom: 1px solid var(--line); }
.navigation-menu {
  display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px;
  padding: 12px 0; font-size: 13.5px; color: var(--muted);
}
.navigation-menu a { color: var(--muted); font-weight: 600; }
.navigation-menu a:hover { color: var(--accent); }
.navigation-menu .dash { width: 4px; height: 4px; border-radius: 50%; background: var(--gray-3); }
.navigation-menu .current, .navigation-menu > span:last-child:not(:first-child) { color: var(--ink); font-weight: 600; }

/* ============================================================
   Главная
   ============================================================ */
/* Hero */
.hero { background: linear-gradient(140deg, #c4494a 0%, #b43637 45%, #8f292a 100%); background-attachment: fixed; color: #fff; overflow: hidden; position: relative; }
.hero::before { content: ""; position: absolute; inset: 0;
  background-image: radial-gradient(rgba(255,255,255,.07) 1px, transparent 1px);
  background-size: 26px 26px; mask-image: linear-gradient(180deg, rgba(0,0,0,.8), transparent 75%); pointer-events: none; }
.hero::after { content: ""; position: absolute; width: 720px; height: 720px; right: -200px; top: -260px;
  background: radial-gradient(circle, rgba(255,255,255,.14), transparent 65%); pointer-events: none; }
.hero .content {
  display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr);
  align-items: center; gap: 48px; padding-top: 96px; padding-bottom: 110px; position: relative; z-index: 1;
}
.hero h1 { color: #fff; margin-bottom: 22px; }
.hero-eyebrow { display: inline-flex; align-items: center; gap: 8px; padding: 7px 16px; border-radius: 999px; background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.14); font-size: 13px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--accent-soft); margin-bottom: 22px; }
.hero h1 .accent { color: var(--accent-soft); }
.hero-lead { font-size: 19px; line-height: 1.7; color: rgba(255,255,255,.85); max-width: 46ch; margin-bottom: 36px; }
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; }
/* красная кнопка на красном фоне сливается — в hero инвертируем */
.hero .btn-order {
  background: #fff; color: var(--accent);
  box-shadow: 0 8px 18px -6px rgba(0, 0, 0, .35);
}
.hero .btn-order:hover {
  background: var(--accent-soft); color: var(--accent-hover);
  box-shadow: 0 10px 22px -6px rgba(0, 0, 0, .4);
}
.hero-stats { display: flex; gap: 0; margin-top: 56px; flex-wrap: wrap; border-top: 1px solid rgba(255,255,255,.12); }
.hero-stat { padding: 22px 38px 0 0; margin-right: 38px; }
.hero-stat:last-child { margin-right: 0; }
.hero-stat b { display: block; font-size: 32px; font-weight: 800; color: #fff; letter-spacing: -.02em; }
.hero-stat span { font-size: 13.5px; color: rgba(255,255,255,.7); }

/* плавающие карточки с продукцией — наследник старого parallax-блока */
.hero-visual { position: relative; min-height: 560px; }
.hv {
  position: absolute; margin: 0; height: auto;
  filter: drop-shadow(0 22px 30px rgba(0, 0, 0, .45));
  animation: hv-float 8s ease-in-out infinite;
  --r: 0deg;
}
@keyframes hv-float {
  0%, 100% { transform: rotate(var(--r)) translateY(0); }
  50% { transform: rotate(var(--r)) translateY(-14px); }
}
.hv-1 { width: 38%; top: 0; right: 4%; --r: 5deg; z-index: 3; }          /* футболка */
.hv-2 { width: 34%; top: 8%; left: 0; --r: -7deg; animation-delay: -2.4s; z-index: 4; }  /* кружка */
.hv-3 { width: 30%; bottom: 0; left: 6%; --r: -4deg; animation-delay: -4.2s; z-index: 2; } /* рюкзак */
.hv-4 { width: 22%; bottom: 4%; left: 41%; --r: 6deg; animation-delay: -1.2s; z-index: 3; } /* блокнот */
.hv-5 { width: 30%; top: 40%; left: 27%; --r: -12deg; animation-delay: -5.6s; z-index: 1; } /* ручка */
.hv-6 { width: 34%; bottom: 0; right: 0; --r: 4deg; animation-delay: -3.1s; z-index: 2; }  /* зонт */
.hv-7 { width: 15%; top: 34%; right: 2%; --r: 8deg; animation-delay: -6.8s; }  /* термокружка */
.hv-8 { width: 13%; top: 2%; left: 38%; --r: -9deg; animation-delay: -7.7s; }  /* бутылка */
@media (prefers-reduced-motion: reduce) { .hv { animation: none; } }
.hero-visual .blob {
  position: absolute; inset: 8% 4%; border-radius: 50%;
  background:
    radial-gradient(circle at 30% 25%, rgba(255, 255, 255, .30), transparent 55%),
    radial-gradient(circle at 70% 75%, rgba(0, 0, 0, .16), transparent 60%),
    radial-gradient(circle at 35% 30%, rgba(255,255,255,.12), rgba(255,255,255,.02) 70%);
}

/* Преимущества */
.features { background: var(--bg); }
.features .content { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; padding-top: 96px; padding-bottom: 96px; }
.feature-card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 14px 14px 30px; transition: transform .25s ease, box-shadow .25s ease;
  box-shadow: var(--shadow-sm);
}
.feature-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); }
.feature-card h2, .feature-card p { padding: 0 16px; }
.feature-card .icon {
  width: 100%; height: 190px; border-radius: var(--radius-sm);
  display: flex; align-items: center; justify-content: center;
  background: var(--accent-soft); color: var(--accent); margin-bottom: 20px;
  overflow: hidden;
}
.feature-card .icon img { width: 100%; height: 100%; object-fit: cover; }
.feature-card:nth-child(2) .icon { background: var(--blue-soft); color: var(--blue); }
.feature-card:nth-child(3) .icon { background: var(--amber-soft); color: var(--amber); }
.feature-card { border-top: 3px solid var(--accent); }
.feature-card:nth-child(2) { border-top-color: var(--blue); }
.feature-card:nth-child(3) { border-top-color: var(--amber); }
.vote svg { width: 22px; height: 22px; }
.feature-card h2 { font-size: 19px; text-transform: none; margin-bottom: 8px; }
.feature-card p { font-size: 15px; line-height: 1.7; color: var(--muted); margin: 0; }

/* О компании / «запомнят» */
.remember { background: var(--bg-soft); }
.remember .content { padding-top: 90px; padding-bottom: 90px; }
/* пока .estimate скрыт — одна колонка; при возврате: 1.1fr .9fr */
.remember-grid { display: grid; grid-template-columns: 1fr; gap: 44px; align-items: center; }
.remember p { font-size: 16.5px; color: var(--ink-3); }
.estimate {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: var(--shadow-md); padding: 30px; text-align: center;
}
.estimate h3 { font-size: 16px; }
.estimate .votes { display: flex; align-items: center; justify-content: center; gap: 18px; margin-top: 12px; }
.vote { width: 52px; height: 52px; border-radius: 50%; border: 1.5px solid var(--line);
  display: flex; align-items: center; justify-content: center; font-size: 22px; cursor: pointer; transition: .15s; }
.vote:hover { transform: scale(1.08); }
.vote.like:hover { border-color: var(--ok); color: var(--ok); }
.vote.dislike:hover { border-color: var(--accent); color: var(--accent); }

/* Категории-промо (бывший слайдер) */
.promo-banner {
  border-radius: var(--radius); overflow: hidden; position: relative;
  background: var(--ink) center/cover no-repeat; color: #fff;
  display: flex; flex-direction: column; justify-content: flex-end;
  min-height: 400px; padding: 44px;
}
.promo-banner::before { content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(30,30,30,.05) 20%, rgba(30,30,30,.85) 100%); }
.promo-banner > * { position: relative; }
.promo-banner .slide-caption { font-size: clamp(20px, 2.4vw, 30px); font-weight: 800; margin-bottom: 18px; max-width: 22ch; }

/* Отзывы */
.comments .content { padding-top: 96px; padding-bottom: 100px; }
.comments-sub { color: var(--muted); margin-top: -8px; }
.comments-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; margin-top: 30px; }
.comment {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; box-shadow: var(--shadow-sm); transition: box-shadow .2s, transform .2s;
}
.comment:hover { box-shadow: var(--shadow-lg); transform: translateY(-5px); }
.comment-header { position: relative; aspect-ratio: 16/9; background: var(--ink); }
.comment-header img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.comment-body { padding: 20px 22px 22px; }
.comment-body p:first-child { font-size: 15.5px; font-weight: 600; color: var(--ink-3); }
.comment-body h3 { font-size: 16px; margin: 0; }
.comment-body p:last-child { margin: 2px 0 0; font-size: 13.5px; color: var(--muted); }
.production { text-align: center; margin-top: 44px; font-size: 19px; font-weight: 700; color: var(--ink); }
.production .nowrap { color: var(--accent); }

/* CTA-полоса */
.cta-strip { background: linear-gradient(135deg, #b43637 0%, #9c2e2f 100%); color: #fff; }
.cta-strip p { color: var(--accent-soft) !important; }
.cta-strip .content {
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  padding-top: 44px; padding-bottom: 44px; flex-wrap: wrap;
}
.cta-strip h2 { color: #fff; margin: 0; font-size: clamp(20px, 2.6vw, 28px); }
.cta-strip p { margin: 6px 0 0; }

/* ============================================================
   Каталог: индекс категорий
   ============================================================ */
.catalog .content { padding-top: 56px; padding-bottom: 80px; }
.catalog-head { margin-bottom: 36px; }
.catalog-sub { color: var(--muted); font-size: 17px; margin: -6px 0 0; }
.index-catalog-list {
  list-style: none; margin: 0; padding: 0;
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px;
}
.catalog-block {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  overflow: hidden; display: flex; flex-direction: column;
  transition: box-shadow .25s, transform .25s;
}
.catalog-block:hover { box-shadow: var(--shadow-lg); transform: translateY(-5px); border-color: transparent; }
.catalog-cover {
  position: relative; display: flex; align-items: center; justify-content: center;
  height: 210px; background: var(--bg-soft); overflow: hidden;
}
.catalog-cover img { max-height: 82%; max-width: 78%; object-fit: contain;
  mix-blend-mode: multiply; transition: transform .35s ease; }
.catalog-block:hover .catalog-cover img { transform: scale(1.08); }
.catalog-count {
  position: absolute; top: 14px; right: 14px; padding: 4px 12px;
  background: #fff; border: 1px solid var(--line); border-radius: 999px;
  font-size: 12.5px; font-weight: 700; color: var(--muted); box-shadow: var(--shadow-sm);
}
.catalog-block-body { padding: 20px 22px 24px; display: flex; flex-direction: column; gap: 12px; flex: 1; }
.catalog-block a.title { font-size: 18px; font-weight: 800; color: var(--ink); letter-spacing: -.01em; }
.catalog-block a.title:hover { color: var(--accent); }
.catalog-chips { display: flex; flex-wrap: wrap; gap: 7px; }
.chip {
  padding: 6px 13px; border-radius: 999px; background: var(--bg-soft);
  font-size: 12.5px; font-weight: 600; color: var(--ink-3); transition: .15s;
}
.chip:hover { background: var(--accent-soft); color: var(--accent); }
.chip-more { background: transparent; border: 1px dashed var(--line); color: var(--muted); }

/* ============================================================
   Каталог: категория
   ============================================================ */
.catalog-category .content { padding-top: 40px; padding-bottom: 64px; }
.category-description { color: var(--muted); max-width: 75ch; }
.category-layout { display: grid; grid-template-columns: 250px minmax(0, 1fr); gap: 34px; margin-top: 26px; }

.left-block { position: sticky; top: 140px; align-self: start; }
.filter-block {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 22px; margin-bottom: 18px; box-shadow: var(--shadow-sm);
}
.filter-block h5 { margin-bottom: 14px; }
.price_slider_amount input {
  width: 100%; padding: 10px 14px; margin-bottom: 10px;
  border: 1.5px solid var(--line); border-radius: var(--radius-sm);
  font: inherit; font-size: 14px; background: #fff;
}
.price_slider_amount input:focus { border-color: var(--ink-3); outline: none; }
.price_slider_amount .btn { width: 100%; padding: 11px; }
.subcategories div { padding: 4px 0; }
.subcategories a { font-size: 14.5px; font-weight: 600; color: var(--ink-3); }
.subcategories a:hover { color: var(--accent); }
.subcategories .current a { color: var(--accent); }

/* Сортировка */
.select-container { display: flex; justify-content: flex-end; margin-bottom: 20px; }
.woocommerce-ordering select {
  appearance: none; -webkit-appearance: none;
  padding: 10px 40px 10px 16px; border: 1.5px solid var(--line); border-radius: 999px;
  font: inherit; font-size: 14px; font-weight: 600; color: var(--ink-3);
  background: #fff url("data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236f6f6f' stroke-width='2.4'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") right 14px center/16px no-repeat;
  cursor: pointer;
}

/* Сетка товаров */
.items-container { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.item-inner {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 14px 14px 18px; height: 100%; display: flex; flex-direction: column;
  transition: box-shadow .25s, transform .25s, border-color .25s; position: relative;
}
.item-inner:hover { box-shadow: var(--shadow-lg); transform: translateY(-5px); border-color: transparent; }
.item-img { display: block; }
.item-img > div {
  aspect-ratio: 1; border-radius: var(--radius-sm); background: var(--bg-soft);
  display: flex; align-items: center; justify-content: center; overflow: hidden; margin-bottom: 14px;
}
.item-img img { mix-blend-mode: multiply; max-height: 86%; max-width: 86%; object-fit: contain; transition: transform .35s ease; }
.item-inner:hover .item-img img { transform: scale(1.08); }
.item-name {
  font-size: 14.5px; font-weight: 600; line-height: 1.45; color: var(--ink);
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
  min-height: 2.9em; margin-bottom: 10px;
}
.item-name:hover { color: var(--accent); }
.item-stock { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 12px; }
.stock-pill {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 4px 10px; border-radius: 999px; background: var(--bg-soft);
  font-size: 11.5px; font-weight: 600; color: var(--gray-2);
}
.stock-pill::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--gray-3); }
.stock-pill.on { color: var(--ok); background: #eaf7ef; }
.stock-pill.on::before { background: var(--ok); }
.item-bottom { margin-top: auto; display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.item-price { font-size: 20px; font-weight: 800; color: var(--ink); letter-spacing: -.02em; }
.item-article { font-size: 11.5px; color: var(--gray-2); }
.count-shop, .count-order { font-size: 12.5px; color: var(--muted); }
.count-shop span, .count-order span { font-weight: 600; color: var(--ok); }
.count-shop .out-of-stock, .count-order .out-of-stock { color: var(--accent); }
/* тулбар листинга */
.listing-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.listing-count { font-size: 14px; font-weight: 700; color: var(--muted); }
.listing-controls { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.irk-filter { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 600; color: var(--ink-3); cursor: pointer; user-select: none; white-space: nowrap; }
.irk-filter input { width: 17px; height: 17px; margin: 0; accent-color: var(--ok); cursor: pointer; }
.item.is-hidden { display: none; }

/* Показать ещё */
.show-more-container { text-align: center; margin-top: 34px; color: var(--muted); font-size: 14px; }
.show-more-container .btn-more { margin-bottom: 12px; }
.btn-more .plus { font-size: 19px; line-height: 1; }
.ajax-loader { display: block; margin: 0 auto 12px; }

/* ============================================================
   Карточка товара
   ============================================================ */
.catalog-item .content { padding-top: 40px; padding-bottom: 64px; }
.product-layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 44px; }
.item-pictures .big {
  border: 1px solid var(--line); border-radius: var(--radius); background: #fff;
  aspect-ratio: 1; overflow: hidden;
}
/* Трек — нативный горизонтальный scroll-snap: свайп на тачскринах работает
   без единой строчки JS для самого жеста, миниатюры лишь скроллят к слайду. */
.item-pictures .big-track {
  display: flex; width: 100%; height: 100%;
  overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none;
}
.item-pictures .big-track::-webkit-scrollbar { display: none; }
.item-pictures .big-slide {
  flex: 0 0 100%; scroll-snap-align: start;
  display: flex; align-items: center; justify-content: center; padding: 28px;
}
.item-pictures .big-slide img { max-width: 100%; max-height: 100%; object-fit: contain; mix-blend-mode: multiply; }
.item-pictures .small { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 12px; }
.item-pictures .thumb {
  width: 74px; height: 74px; padding: 6px; cursor: pointer;
  background: #fff; border: 1.5px solid var(--line); border-radius: var(--radius-sm);
  transition: border-color .15s;
}
.item-pictures .thumb img { width: 100%; height: 100%; object-fit: contain; mix-blend-mode: multiply; display: block; }
.item-pictures .thumb:hover { border-color: var(--gray-3); }
.item-pictures .thumb.active { border-color: var(--accent); }
.item-info h1, .item-info h2 { margin-bottom: 10px; }
.item-info h1 { font-size: clamp(17px, 2.3vw, 28px); }
.item-info .article { color: var(--muted); font-size: 14px; margin-bottom: 16px; }
.item-info .colors { font-size: 14.5px; margin-bottom: 12px; }
.item-info .stock { font-size: 14.5px; margin: 4px 0; color: var(--muted); }
.item-info .stock span { font-weight: 700; color: var(--ok); }
.item-info .stock .out-of-stock { color: var(--accent); }
.item-info .price { font-size: 38px; font-weight: 800; color: var(--ink); letter-spacing: -.02em; margin: 22px 0 20px; }
.item-info .price::after { content: " / шт."; font-size: 15px; font-weight: 600; color: var(--muted); letter-spacing: 0; }
.item-details { margin-top: 56px; }
.item-details h2 { font-size: 22px; }
.details-grid { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, .8fr); gap: 36px; }
.details-container p { color: var(--ink-3); }
.table-container table { width: 100%; font-size: 14.5px; table-layout: fixed; }
.table-container th, .table-container td { text-align: left; padding: 11px 14px; border-bottom: 1px solid var(--line); overflow-wrap: anywhere; }
.table-container th { color: var(--muted); font-weight: 600; width: 38%; }
.table-container p { margin: 0; }

/* ============================================================
   Текстовые страницы, поиск, 404
   ============================================================ */
.about-header { background: var(--bg-dark-grad); color: #fff; }
.about-header .content { padding-top: 44px; padding-bottom: 44px; }
.about-header h1, .about-header h2 { color: #fff; margin: 0; }

/* Фото-баннер вверху страницы (поле heroImage; на услугах — стандартное фото) */
.page-hero img { display: block; width: 100%; height: 385px; object-fit: cover; }

.page-body .content, .error-404 .content { padding-top: 44px; padding-bottom: 44px; }
.page-body { font-size: 16.5px; line-height: 1.75; }
.page-body img { max-width: 100%; border-radius: var(--radius-sm); box-shadow: var(--shadow-sm); height: auto; }
.page-body iframe { max-width: 100%; border: 0; border-radius: var(--radius-sm); }
.page-body iframe[src*="youtube"] { width: 100%; aspect-ratio: 16/9; height: auto; }
.page-body h2, .page-body h3 { margin-top: 1.6em; }
.page-body ul, .page-body ol { padding-left: 1.3em; margin: 0 0 1.2em; }
.page-body li { margin-bottom: .4em; }
/* Таблицы в контенте страниц. Оформление из Excel/Word (высота/рамки/фон/шрифт)
   гасим темой сайта (!important), но ширину колонок НЕ трогаем — чтобы не ломать
   вёрстку; слишком широкая таблица не рвёт страницу, а скроллится в обёртке
   .table-wrap (её вешает _pages/page.twig вокруг каждой <table>). */
.page-body .table-wrap { max-width: 100%; overflow-x: auto; margin: 0 0 1.6em; }
.page-body .table-wrap > table { margin: 0; }
/* CKEditor оборачивает таблицы в <figure class="table"> и вешает на неё инлайн-ширину/высоту
   (напр. width:1397px или height:339px из Excel) — гасим и ширину, и высоту: иначе низкая
   фигура обрезается по height, а таблица (её реальная высота больше) вылезает вниз под футер.
   Скролл по ширине даёт .table-wrap внутри. */
.page-body figure.table { width: auto !important; max-width: 100% !important; height: auto !important; margin: 0 0 1.6em; display: flex; flex-direction: column; }
.page-body figure.table > table, .page-body figure.table > .table-wrap { margin: 0; min-width: 0; }
/* Подпись таблицы (<figcaption>) в разметке стоит ПОСЛЕ таблицы — поднимаем её НАД
   таблицей (flex order) и оформляем как заголовок. */
.page-body figure.table > figcaption {
  order: -1; margin: 0 0 .7em;
  font-size: 19px; font-weight: 800; line-height: 1.3; color: var(--ink);
}
.page-body table {
  width: 100%; max-width: none; height: auto !important; font-size: 15px;
  margin: 0 0 1.6em; border-collapse: separate !important; border-spacing: 0 !important;
  border: 1px solid var(--line); border-radius: var(--radius-sm);
  overflow: hidden; box-shadow: var(--shadow-sm); background: #fff;
}
/* ширину колонок НЕ ломаем (сохраняем вёрстку — напр. календарь): слишком широкая
   таблица скроллится в .table-wrap. Гасим только оформление из Excel/Word (рамки/фон/шрифт). */
.page-body table td, .page-body table th {
  padding: 13px 18px !important; border: 0 !important; border-bottom: 1px solid var(--line) !important;
  background: #fff !important; color: var(--ink) !important; font-family: inherit !important;
  text-align: left; overflow-wrap: anywhere;
}
.page-body table th {
  background: var(--ink) !important; color: #fff !important; font-weight: 700 !important;
  font-size: 13px !important; text-transform: uppercase; letter-spacing: .05em;
  border-bottom: 0 !important;
}
.page-body table tr:nth-child(even) td { background: var(--bg-soft) !important; }
.page-body table tr:hover td { background: var(--accent-soft) !important; }
.page-body table tr:last-child td { border-bottom: 0 !important; }
.page-body table td:first-child { font-weight: 600; white-space: normal; }
.page-body blockquote { margin: 0 0 1.2em; padding: 16px 22px; background: var(--bg-soft);
  border-left: 3px solid var(--ink); border-radius: 0 var(--radius-sm) var(--radius-sm) 0; }
/* легаси <center> со стопкой картинок -> аккуратная сетка */
.page-body center { display: flex; flex-wrap: wrap; gap: 14px; justify-content: center; margin: 0 0 1.4em; }
.page-body center img { width: calc(33.333% - 10px); min-width: 240px; object-fit: contain; margin: 0; }
.page-body center br { display: none; }
/* легаси <pre> с прайсами -> карточка */
.page-body pre {
  font-family: inherit; font-size: 15px; white-space: pre-wrap; overflow: auto;
  background: var(--bg-soft); border: 1px solid var(--line); border-radius: var(--radius-sm);
  padding: 18px 22px; margin: 0 0 1.4em;
}
.page-body p > img:only-child { display: block; margin: 0 auto; }
.page-body hr { border: 0; border-top: 1px solid var(--line); margin: 2em 0; }
.aligncenter { display: block; margin-left: auto; margin-right: auto; text-align: center; }
.alignleft { float: left; margin: 0 24px 16px 0; }
.alignright { float: right; margin: 0 0 16px 24px; }

/* Легаси-компоненты из контента старых страниц */
.service { display: grid; grid-template-columns: 280px minmax(0,1fr); gap: 26px; align-items: start;
  background: var(--bg-soft); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 24px; margin: 0 0 22px; }
.service-image img { border-radius: var(--radius-sm); width: 100%; object-fit: cover; }
.service-info h3 a { color: var(--ink); }
.service-info h3 a:hover { color: var(--accent); }
.service .line { display: none; }
.learn-more { font-weight: 700; color: var(--accent); }
/* Кнопка «Получить консультацию» внизу страниц услуг */
.services-cta .content { display: flex; justify-content: center; padding-bottom: 64px; }
.sort-menu { display: flex; flex-wrap: wrap; gap: 10px; margin: 0 0 26px; }
.sort-menu-item {
  padding: 9px 20px; border: 1.5px solid var(--line); border-radius: 999px;
  font-size: 14px; font-weight: 600; cursor: pointer; transition: .15s; background: #fff;
}
.sort-menu-item:hover { border-color: var(--accent); color: var(--accent); }
.sort-menu-item.active { background: var(--accent); border-color: var(--accent); color: #fff; }
.photos { display: none; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.photos.active { display: grid; }
.photos img { border-radius: var(--radius-sm); width: 100%; height: 100%; object-fit: cover; }
.contact__phonesItem { margin-bottom: 10px; }
.contact__phonesItemLinkNumber { font-weight: 800; font-size: 18px; color: var(--ink); }
.contact__phonesItemComment { color: var(--muted); font-size: 13.5px; }
.fact { background: var(--accent-soft); border-left: 3px solid var(--accent);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0; padding: 16px 22px; margin: 0 0 18px; }

/* Контакты */
.contacts-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 22px; margin: 8px 0 30px; }
.ccard {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 24px 26px; box-shadow: var(--shadow-sm);
}
.ccard h3 {
  display: flex; align-items: center; gap: 10px;
  font-size: 16px; margin-bottom: 16px;
}
.ccard h3 svg { width: 20px; height: 20px; flex: none; color: var(--accent); }
.ccard p { margin: 0 0 12px; line-height: 1.5; }
.ccard p:last-child { margin-bottom: 0; }
.ccard-strong { display: block; font-weight: 700; font-size: 16.5px; color: var(--ink); overflow-wrap: anywhere; }
a[href^="tel:"].ccard-strong { white-space: nowrap; }
a.ccard-strong:hover { color: var(--accent); }
.ccard-note { display: block; font-size: 13.5px; color: var(--muted); margin-top: 2px; }
.ccard-note a { color: var(--ink-3); font-weight: 600; }
.ccard-link { font-weight: 700; color: var(--accent); }
.ccard-partner { background: var(--bg-soft); grid-column: 1 / -1; }
.ccard-partner h3 { margin-bottom: 12px; }
.ccard-partner-row { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 36px; }
.ccard-partner-row p { margin: 0; }
.contacts-map { border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow-sm); }
.contacts-map iframe { display: block; width: 100%; height: 380px; border: 0; }

.error-404 .content { text-align: center; max-width: 640px; }

/* ============================================================
   Формы и модалка заявки
   ============================================================ */
.suvenir-lead-form p, .wpcf7-form p { margin: 0 0 6px; font-size: 14px; font-weight: 600; color: var(--ink-3); }
.suvenir-lead-form p:has(input), .suvenir-lead-form p:has(textarea) { margin-bottom: 16px; }
.suvenir-lead-form input[type="text"], .suvenir-lead-form textarea,
.wpcf7-form input[type="text"], .wpcf7-form input[type="email"], .wpcf7-form textarea {
  width: 100%; padding: 12px 16px; border: 1.5px solid var(--line); border-radius: var(--radius-sm);
  font: inherit; font-size: 15px; background: #fff; transition: border-color .15s;
}
.suvenir-lead-form input:focus, .suvenir-lead-form textarea:focus,
.wpcf7-form input:focus, .wpcf7-form textarea:focus { border-color: var(--ink-3); outline: none; }
.suvenir-lead-form textarea, .wpcf7-form textarea { resize: vertical; min-height: 96px; }
.wpcf7-form-control-wrap { display: block; }
.wpcf7-response-output { display: none; margin-top: 14px; padding: 12px 16px;
  border-radius: var(--radius-sm); background: var(--accent-soft); color: var(--accent-hover);
  font-size: 14.5px; font-weight: 600; }
.wpcf7-response-output.visible { display: block; }
.wpcf7-response-output.success { background: #eaf7ef; color: var(--ok); }
.suvenir-inline-lead { max-width: 560px; margin: 26px 0; padding: 26px;
  background: var(--bg-soft); border: 1px solid var(--line); border-radius: var(--radius); }
.lead-form-product { color: var(--muted); }

/* Модалка */
.modal-overlay {
  position: fixed; inset: 0; z-index: 1000; background: rgba(20, 20, 20, .55);
  backdrop-filter: blur(3px); display: none; align-items: center; justify-content: center; padding: 20px;
}
.modal-overlay.open { display: flex; }
.modal {
  background: #fff; border-radius: var(--radius); box-shadow: var(--shadow-lg);
  width: 100%; max-width: 560px; max-height: 92vh; overflow: auto; padding: 34px 36px;
  position: relative; animation: modal-in .22s ease;
}
@keyframes modal-in { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
.modal h3 { font-size: 19px; padding-right: 36px; margin-bottom: 20px; }
.modal-close {
  position: absolute; top: 16px; right: 16px; width: 36px; height: 36px;
  display: flex; align-items: center; justify-content: center;
  border: 0; border-radius: 50%; background: var(--bg-soft); cursor: pointer;
  font-size: 17px; line-height: 1; color: var(--muted); transition: .15s;
}
.modal-close:hover { background: var(--accent-soft); color: var(--accent); }
body.modal-open { overflow: hidden; }

/* Попап «Получить расчёт» */
.kp-lead { color: var(--muted); margin: -6px 0 22px; line-height: 1.55; }
.kp-contacts { display: grid; gap: 10px; }
.kp-contact {
  display: flex; align-items: center; gap: 14px;
  padding: 12px 14px; border: 1px solid var(--line); border-radius: var(--radius-sm);
  color: var(--ink); transition: border-color .15s ease, background .15s ease, transform .12s ease;
}
.kp-contact:hover { border-color: var(--accent); background: var(--accent-soft); transform: translateY(-1px); }
.kp-contact-ic {
  flex: 0 0 44px; width: 44px; height: 44px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: var(--accent-soft); color: var(--accent);
}
.kp-contact-ic img { width: 22px; height: 22px; display: block; }
.kp-contact-body { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.kp-contact-label { font-size: 12.5px; color: var(--muted); }
.kp-contact-val { font-size: 16px; font-weight: 700; word-break: break-word; }
.kp-contact:hover .kp-contact-val { color: var(--accent); }

/* ============================================================
   Подвал
   ============================================================ */
.footer { background: var(--ink-2); color: #aab2c5; font-size: 14.5px; margin-top: auto; }
.footer .content {
  display: grid; grid-template-columns: 1.3fr 1fr 1fr; gap: 44px;
  padding-top: 56px; padding-bottom: 40px;
}
.footer h3 { color: #fff; font-size: 14px; text-transform: uppercase; letter-spacing: .07em; margin-bottom: 16px; }
.footer a { color: #cdd4e2; font-weight: 500; }
.footer a:hover { color: #fff; }
.footer .links div, .footer .navigation div { padding: 4px 0; }
.footer-copyright { margin-top: 20px; font-size: 13px; color: #8c94aa; }

/* ---------- Появление при скролле ---------- */
@media (prefers-reduced-motion: no-preference) {
  .reveal { opacity: 0; transform: translateY(26px); transition: opacity .6s ease, transform .6s ease; }
  .reveal.in { opacity: 1; transform: none; }
  .reveal:nth-child(2) { transition-delay: .08s; }
  .reveal:nth-child(3) { transition-delay: .16s; }
  .reveal:nth-child(4) { transition-delay: .24s; }
}

/* ============================================================
   Адаптив
   ============================================================ */
@media (max-width: 1024px) {
  .items-container { grid-template-columns: repeat(3, 1fr); }
  .index-catalog-list { grid-template-columns: repeat(2, 1fr); }
  .comments-grid { grid-template-columns: 1fr; max-width: 560px; margin-left: auto; margin-right: auto; }
  .hero .content { grid-template-columns: 1fr; padding-bottom: 56px; }
  .hero-visual { min-height: 380px; }
  .hv-5, .hv-7 { display: none; }
  .remember-grid { grid-template-columns: 1fr; }
  .features .content { grid-template-columns: 1fr; }
  .product-layout, .details-grid { grid-template-columns: 1fr; }
}
@media (max-width: 1100px) {
  .main-nav {
    position: fixed; inset: 0; top: 0; background: #fff; z-index: 980;
    padding: 86px 24px 40px; overflow: auto; display: none; margin: 0;
  }
  body.nav-open .main-nav { display: block; }
  body.nav-open { overflow: hidden; }
  /* backdrop-filter на .header-main создаёт containing block для position:fixed —
     из-за него меню (inset:0) прибивалось к строке шапки, а не к вьюпорту.
     Снимаем фильтр на время открытого меню, чтобы панель раскрылась на весь экран. */
  body.nav-open .header-main { backdrop-filter: none; -webkit-backdrop-filter: none; }
  .main-nav > ul { flex-direction: column; gap: 0; }
  .main-nav > ul > li > a { font-size: 18px; padding: 13px 4px; border-radius: 0; border-bottom: 1px solid var(--line); color: var(--ink); }
  .mega {
    position: static; transform: none; width: auto; max-width: none; columns: 1; min-width: 0;
    border: 0; box-shadow: none;
    padding: 8px 4px 16px; display: none; visibility: visible; opacity: 1; transition: none;
  }
  .mega::before { display: none; }
  .main-nav li.open > .mega { display: block; transform: none; }
  .main-nav li:hover > .mega { display: none; }
  .main-nav li.open:hover > .mega { display: block; }
  /* Компактная шапка одной строкой, слева-направо:
     [лого] [лупа] [телефон · мессенджеры] [бургер].
     Плашку .header-topbar убираем — телефон и мессенджеры дублируются прямо
     в строке (.header-mobile-contacts). Ряд — flex без переноса: margin-left:auto
     на лупе и на бургере делят свободное место поровну, центрируя кластер
     [лупа·телефон·мессенджеры] между лого слева и бургером справа.
     padding-top/bottom — длиннохендлы, чтобы НЕ сбросить боковые 20px из .content
     (иначе логотип прилипает к краю экрана). */
  .header-topbar { display: none; }
  .header-main .content {
    display: flex; align-items: center; flex-wrap: nowrap;
    gap: 5px; padding-top: 12px; padding-bottom: 7px; min-height: 0;
  }
  .site-logo { flex-shrink: 0; }
  .logo-mark { height: 36px; }
  .header-search-icon { display: inline-flex; align-items: center; flex-shrink: 0; margin-left: auto; }
  .header-mobile-contacts { display: flex; align-items: center; gap: 7px; flex-shrink: 0; }
  /* телефон плавно 12→13px (clamp): пол 12px на узких (≤~353px) — чтобы ряд влез,
     потолок 13px на широких (≥~382px), между — текучий */
  .hmc-phone { color: #fff; font-weight: 600; font-size: clamp(12px, 3.4vw, 13px); white-space: nowrap; }
  .header-mobile-contacts .topbar-msgrs { display: inline-flex; align-items: center; gap: 7px; }
  .header-mobile-contacts .topbar-msgrs img { width: 18px; height: 18px; display: block; }
  .nav-burger { display: flex; z-index: 990; margin-left: auto; flex-shrink: 0; padding: 10px 4px; }
  .header-search:not(.header-search--menu) { display: none; }
  .header-search--menu { display: flex; flex: 1 1 auto; width: 100%; margin: 0 0 20px; }
  /* Контакты внизу мобильного меню */
  .menu-contacts { display: block; margin-top: 28px; padding-top: 20px; border-top: 1px solid var(--line); }
  .menu-schedule { color: var(--muted); font-size: 14px; margin-bottom: 6px; }
  .menu-phones { font-size: 20px; font-weight: 800; margin-bottom: 14px; }
  .menu-phones a { color: var(--ink); }
  .menu-phones a:hover { color: var(--accent); }
  .menu-contacts .topbar-msgrs { display: inline-flex; align-items: center; gap: 12px; }
  .menu-contacts .topbar-msgrs img { width: 24px; height: 24px; display: block; }
  body.nav-open .nav-burger span { background: var(--ink); }
  body.nav-open .nav-burger span:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
  body.nav-open .nav-burger span:nth-child(2) { opacity: 0; }
  body.nav-open .nav-burger span:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg); }
  .header-cta { display: none; }
  .category-layout { grid-template-columns: 1fr; }
  /* на мобилке подкатегории не должны липнуть и ехать со скролом */
  .left-block { position: static; top: auto; }
  .footer .content { grid-template-columns: 1fr; gap: 28px; }
  .service { grid-template-columns: 1fr; }
  .page-hero img { height: 200px; }
  .photos.active { grid-template-columns: repeat(2, 1fr); }
  .hero .content { padding-top: 28px; padding-bottom: 40px; }
}
@media (max-width: 600px) {
  .items-container { grid-template-columns: repeat(2, 1fr); gap: 12px; }
  .index-catalog-list { grid-template-columns: 1fr; }
  .hero-stats { gap: 22px; }
  .section, .features .content, .remember .content, .comments .content { padding-top: 44px; padding-bottom: 44px; }
  .modal { padding: 26px 22px; }
  /* Таблицы-прайсы (много узких числовых колонок) на мобиле НЕ ужимаем в ширину экрана —
     иначе overflow-wrap дробит цену по одной цифре в столбик. Держим ячейки в одну строку,
     таблица сохраняет свою ширину и скроллится по горизонтали в .table-wrap.
     Первый столбец (подписи + строки-заголовки на colspan) при этом переносим как обычно. */
  .page-body table td, .page-body table th { white-space: nowrap; overflow-wrap: normal; }
  .page-body table td:first-child, .page-body table th:first-child { white-space: normal; overflow-wrap: break-word; }
  /* nowrap выше пришпиливает числовые колонки на всю ширину — картиночная колонка
     (единственная сжимаемая, т.к. у <img> max-width в ПРОЦЕНТАХ → min-content 0) схлопывается
     в 0, и картинка пропадает. Даём картинке фиксированную ширину (не %) — колонка получает
     ненулевой min-content и больше не голодает. figure.image несёт дефолтный margin:0 40px
     (bootstrap.css) — гасим, чтобы 80px по бокам не съедали место в узкой колонке. */
  .page-body table img { width: auto; max-width: 140px; height: auto; }
  .page-body table figure.image { margin: 0; }
}
