/* ==========================================================================
   DaDuNya — «С любовью к знаниям!»
   Магазин образовательных постеров. Основная таблица стилей.
   Структура: 1) Токены 2) Сброс 3) Типографика 4) Утилиты 5) Кнопки/формы
              6) Хедер 7) Главная 8) Карточки товара 9) Каталог 10) Товар
              11) Корзина/Заказ 12) Контент-страницы 13) Футер 14) Адаптив
   Внешний вид приведён к утверждённому макету главной («Пример 1»):
   заголовки антиквой PT Serif, светлые тёплые фоны, плотный ритм секций,
   крупные карточки с рамой-паспарту, подвал с правовыми ссылками.
   ========================================================================== */

/* ------------------------------------------------------------------ 0. Шрифты темы
   Переменные шрифты (один файл — все начертания), только латиница +
   кириллица, ~100 КБ на оба. Vela Sans — OFL, HONOR Sans — бесплатный
   шрифт HONOR (лицензии рядом, в fonts/). */
@font-face {
    font-family: 'Vela Sans';
    src: url('fonts/vela-sans-vf.woff2') format('woff2-variations'), url('fonts/vela-sans-vf.woff2') format('woff2');
    font-weight: 200 800; font-style: normal; font-display: swap;
}
@font-face {
    font-family: 'HONOR Sans';
    src: url('fonts/honor-sans-vf.woff2') format('woff2-variations'), url('fonts/honor-sans-vf.woff2') format('woff2');
    font-weight: 100 900; font-style: normal; font-display: swap;
}

/* ------------------------------------------------------------------ 1. Токены */
:root {
    /* Цвет */
    --white: #ffffff;
    --cream: #faf7f2;
    --cream-2: #f3ede4;
    --cream-3: #ece4d8;
    --ink: #1a1a1a;
    --ink-2: #4a4a4a;
    --muted: #857e73;
    --line: #e7e2d9;
    --line-2: #d9d2c6;

    --accent: #e1252c;
    --accent-dark: #bd1b21;
    --accent-soft: #fdeeee;

    --green: #3f7a5e;
    --gold: #e8a359;

    /* Геометрия */
    --r-btn: 8px;
    --r: 12px;
    --r-card: 14px;
    --r-lg: 24px;
    --r-pill: 999px;

    /* Тени */
    --sh-sm: 0 2px 8px rgba(26, 26, 26, .05);
    --sh: 0 4px 20px rgba(26, 26, 26, .06);
    --sh-md: 0 10px 30px rgba(26, 26, 26, .09);
    --sh-lg: 0 24px 60px rgba(26, 26, 26, .13);

    /* Сетка */
    --container: 1280px;
    --gutter: 32px;
    --section: 72px;
    /* Насколько блок может «вылезти» из контейнера до правого края окна
       (фото/иллюстрация на первом экране и в «Нашей философии», как в макете) */
    --bleed: max(var(--gutter), calc((100vw - var(--container)) / 2 + var(--gutter)));
    --r-media: 22px;

    /* Шрифты */
    /* Заголовки — Vela Sans, текст — HONOR Sans (оба лежат в теме, fonts/);
       подписи «от руки» — Caveat; надпись логотипа — Montserrat. */
    --font-display: 'Vela Sans', 'HONOR Sans', 'Segoe UI', system-ui, sans-serif;
    --font-body: 'HONOR Sans', 'Segoe UI', 'DejaVu Sans', system-ui, sans-serif;
    --font-hand: 'Caveat', 'Segoe Script', cursive;
    --font-logo: 'Montserrat', 'Segoe UI', 'DejaVu Sans', system-ui, sans-serif;

    /* Тёплый светлый фон секций (первый экран, «Наша философия») */
    --soft: #f7f4ef;
    --wood: #c9a27a;

    --header-h: 84px;
}

/* ------------------------------------------------------------------ 2. Сброс */
*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
    margin: 0;
    background: var(--white);
    color: var(--ink);
    font-family: var(--font-body);
    font-size: 16px;
    line-height: 1.6;
    font-optical-sizing: auto;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
}

img, svg { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; }
ul, ol { margin: 0; padding: 0; list-style: none; }

:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 3px;
    border-radius: 4px;
}

::selection { background: var(--accent); color: #fff; }

/* ------------------------------------------------------------------ 3. Типографика */
h1, h2, h3, h4 {
    font-family: var(--font-display);
    font-weight: 650;
    color: var(--ink);
    margin: 0;
    letter-spacing: -.015em;
}

h1, .h1 { font-size: clamp(30px, 3.4vw, 46px); line-height: 1.1; }
h2, .h2 { font-size: clamp(24px, 2.3vw, 32px); line-height: 1.18; }
h3, .h3 { font-size: clamp(19px, 1.6vw, 23px); line-height: 1.25; }
h4 { font-size: 16px; line-height: 1.35; }

p { margin: 0 0 1em; }
p:last-child { margin-bottom: 0; }

.lead { font-size: 17px; line-height: 1.6; color: var(--ink-2); }
.muted { color: var(--muted); }
.small { font-size: 14px; }

.eyebrow {
    font-family: var(--font-body);
    font-size: 11.5px;
    font-weight: 500;
    letter-spacing: .28em;
    text-transform: uppercase;
    color: var(--muted);
    margin: 0 0 16px;
}

.hand {
    font-family: var(--font-hand);
    font-size: 30px;
    line-height: 1.25;
    color: var(--ink);
    font-weight: 600;
}

.accent { color: var(--accent); }

/* ------------------------------------------------------------------ 4. Утилиты */
.container {
    width: 100%;
    max-width: var(--container);
    margin: 0 auto;
    padding: 0 var(--gutter);
}

.section { padding: var(--section) 0; }
.section--tight { padding: 44px 0; }
.section--cream { background: var(--cream); }
/* Секции главной идут плотно, как в макете: между блоками ~44px,
   а не 128px, как было (64px снизу + 64px сверху). */
.section--home { padding: 18px 0; }
.hero + .section--home { padding-top: 40px; }

.section-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    margin-bottom: 20px;
}

.link-more {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 13.5px;
    font-weight: 500;
    color: var(--ink-2);
    white-space: nowrap;
    transition: color .18s, gap .18s;
}
.link-more:hover { color: var(--accent); gap: 12px; }
.link-more svg { width: 16px; height: 16px; }

.divider { height: 1px; background: var(--line); border: 0; margin: 0; }

.screen-reader-text {
    position: absolute !important; width: 1px; height: 1px; padding: 0;
    margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
.sr-only {
    position: absolute; width: 1px; height: 1px; padding: 0;
    margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.skip-link {
    position: absolute; left: 16px; top: -60px; z-index: 200;
    background: var(--accent); color: #fff; padding: 10px 18px; border-radius: var(--r-btn);
    transition: top .2s;
}
.skip-link:focus { top: 16px; }

/* ------------------------------------------------------------------ 5. Кнопки и формы */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 14px 26px;
    border: 1px solid transparent;
    border-radius: var(--r-btn);
    font-family: var(--font-body);
    font-size: 15px;
    font-weight: 600;
    line-height: 1.2;
    cursor: pointer;
    transition: background .18s, color .18s, border-color .18s, transform .18s, box-shadow .18s;
    text-align: center;
}
.btn svg { width: 18px; height: 18px; flex: none; }

.btn--primary { background: var(--accent); color: #fff; }
.btn--primary:hover { background: var(--accent-dark); transform: translateY(-1px); box-shadow: 0 8px 20px rgba(225, 37, 44, .26); }
.btn--primary:active { transform: translateY(0); }

.btn--ghost { background: transparent; border-color: var(--line-2); color: var(--ink); }
.btn--ghost:hover { border-color: var(--ink); background: rgba(26, 26, 26, .03); }

.btn--outline-accent { background: transparent; border-color: var(--accent); color: var(--accent); }
.btn--outline-accent:hover { background: var(--accent); color: #fff; }

.btn--dark { background: var(--ink); color: #fff; }
.btn--dark:hover { background: #000; }

.btn--pill { border-radius: var(--r-pill); }
.btn--wide { width: 100%; }
.btn--sm { padding: 10px 18px; font-size: 14px; }
.btn--lg { padding: 15px 30px; font-size: 15.5px; }
.btn[disabled] { opacity: .45; pointer-events: none; }

.btn-underline {
    display: inline-flex; align-items: center; gap: 8px;
    font-weight: 500; font-size: 14.5px; padding: 6px 2px;
    border-bottom: 1.5px solid var(--accent); transition: color .2s;
}
.btn-underline:hover { color: var(--accent); }

.field { display: block; margin-bottom: 18px; }
.field__label { display: block; font-size: 13px; font-weight: 600; color: var(--ink-2); margin-bottom: 7px; }
.field__label .req { color: var(--accent); }

.input, .select, .textarea {
    width: 100%;
    padding: 13px 16px;
    border: 1px solid var(--line-2);
    border-radius: var(--r-btn);
    background: var(--white);
    font-family: var(--font-body);
    font-size: 15px;
    color: var(--ink);
    transition: border-color .18s, box-shadow .18s;
}
.input::placeholder, .textarea::placeholder { color: #b3aca1; }
.input:focus, .select:focus, .textarea:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px var(--accent-soft);
}
.textarea { min-height: 120px; resize: vertical; }
.select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5 6 6.5l5-5' stroke='%23857e73' stroke-width='1.6' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 15px center;
    background-size: 12px;
    padding-right: 40px;
}
.field--error .input, .field--error .select { border-color: var(--accent); }
.field__error { display: none; font-size: 12.5px; color: var(--accent); margin-top: 6px; }
.field--error .field__error { display: block; }

.check {
    display: flex; align-items: flex-start; gap: 10px;
    font-size: 13.5px; color: var(--ink-2); line-height: 1.5; cursor: pointer;
}
.check input { margin: 3px 0 0; accent-color: var(--accent); width: 16px; height: 16px; flex: none; }
.check a { text-decoration: underline; text-underline-offset: 2px; }

/* Радио-карточки (доставка, оплата, размер) */
.radio-card {
    display: flex; align-items: flex-start; gap: 12px;
    border: 1px solid var(--line-2); border-radius: var(--r);
    padding: 15px 17px; cursor: pointer; background: var(--white);
    transition: border-color .18s, background .18s, box-shadow .18s;
}
.radio-card:hover { border-color: var(--ink-2); }
.radio-card input { margin: 3px 0 0; accent-color: var(--accent); width: 17px; height: 17px; flex: none; }
.radio-card--active { border-color: var(--accent); background: var(--accent-soft); box-shadow: 0 0 0 2px rgba(225, 37, 44, .1); }
.radio-card > span { display: block; }
.radio-card__title { display: block; font-weight: 600; font-size: 15px; }
.radio-card__meta { display: block; font-size: 13px; color: var(--muted); line-height: 1.45; }
.radio-card__price { margin-left: auto; font-weight: 700; white-space: nowrap; align-self: center; }
.radio-card { align-items: center; }

/* ------------------------------------------------------------------ 6. Хедер */
.header {
    position: sticky; top: 0; z-index: 90;
    background: rgba(255, 255, 255, .94);
    backdrop-filter: saturate(160%) blur(10px);
    border-bottom: 1px solid var(--line);
}
.admin-bar .header { top: 32px; }
@media (max-width: 782px) { .admin-bar .header { top: 46px; } }
@media (max-width: 600px) { .admin-bar .header { top: 0; } }
.header__inner {
    display: flex; align-items: center; gap: 32px;
    min-height: var(--header-h);
}

/* Логотип: знак + надпись DaDuNya (или загруженная картинка логотипа)
   и слоган в две строки справа — как в макете. */
.logo { display: flex; align-items: center; gap: 10px; flex: none; }
.logo__mark { width: 40px; height: 40px; flex: none; }
.logo__img { height: 56px; width: auto; flex: none; }
.logo__word {
    font-family: var(--font-logo);
    font-weight: 700; font-size: 24px; line-height: 1; letter-spacing: -.01em; color: var(--ink);
}
.logo__word b { color: var(--accent); font-weight: 700; }
.logo__slogan {
    font-family: var(--font-body); font-size: 13.5px; font-weight: 500; line-height: 1.3;
    color: var(--ink-2); margin-left: 6px; white-space: nowrap;
}

.nav { display: flex; align-items: center; justify-content: center; gap: clamp(14px, 1.6vw, 24px); margin: 0 auto; flex: none; }
/* wp_nav_menu() рисует пункты как <li class="menu-item"> — убираем маркеры. */
.nav li, .nav .menu-item { list-style: none; margin: 0; padding: 0; }
.nav a {
    font-size: 14.5px; font-weight: 500; color: var(--ink);
    padding: 6px 0; position: relative; transition: color .18s;
    white-space: nowrap;   /* «О нас» не переносится на вторую строку */
}
.nav a::after {
    content: ''; position: absolute; left: 0; right: 100%; bottom: -2px;
    height: 1.5px; background: var(--accent); transition: right .22s;
}
.nav a:hover, .nav a.is-active, .nav .current-menu-item > a { color: var(--ink); }
.nav a:hover::after, .nav a.is-active::after, .nav .current-menu-item > a::after { right: 0; }

/* Поиск — тонкая линия снизу, без заливки (как в макете) */
.header__search { flex: 0 1 230px; min-width: 200px; position: relative; }
.header__search .input {
    height: 40px; padding: 8px 4px 8px 30px;
    background: transparent; border: 0; border-bottom: 1px solid var(--line-2); border-radius: 0;
    font-size: 14px;
}
.header__search .input:focus { background: transparent; border-bottom-color: var(--accent); box-shadow: none; }
.header__search svg {
    position: absolute; left: 2px; top: 50%; transform: translateY(-50%);
    width: 18px; height: 18px; color: var(--ink); pointer-events: none;
}

.header__actions { display: flex; align-items: center; gap: 4px; flex: none; }
.icon-btn {
    position: relative; display: grid; place-items: center;
    width: 44px; height: 44px; border: 0; background: transparent;
    border-radius: var(--r-pill); cursor: pointer; color: var(--ink);
    transition: background .18s, color .18s;
}
.icon-btn:hover { background: var(--cream-2); color: var(--accent); }
.icon-btn svg { width: 24px; height: 24px; }
.badge {
    position: absolute; top: 3px; right: 1px;
    min-width: 19px; height: 19px; padding: 0 5px;
    display: grid; place-items: center;
    background: var(--accent); color: #fff;
    font-size: 11px; font-weight: 700; line-height: 1;
    border-radius: var(--r-pill); border: 2px solid #fff;
}

.burger { display: none; }

/* Живой поиск */
.search-results {
    position: absolute; top: calc(100% + 8px); left: 0; right: 0; z-index: 30;
    background: #fff; border: 1px solid var(--line); border-radius: var(--r);
    box-shadow: var(--sh-md); overflow: hidden; display: none;
}
.search-results.is-open { display: block; }
.search-results a {
    display: flex; align-items: center; gap: 12px; padding: 10px 14px;
    border-bottom: 1px solid var(--line); transition: background .15s;
}
.search-results a:last-child { border-bottom: 0; }
.search-results a:hover { background: var(--cream); }
.search-results img { width: 34px; height: 46px; object-fit: cover; border-radius: 3px; background: var(--cream-2); }
.search-results__title { font-size: 14px; font-weight: 500; }
.search-results__price { margin-left: auto; font-size: 13px; font-weight: 700; color: var(--muted); }
.search-results__empty { padding: 16px; font-size: 14px; color: var(--muted); }

/* Мобильное меню */
.mobile-menu {
    position: fixed; inset: 0; z-index: 120;
    background: #fff; padding: 22px var(--gutter) 40px;
    transform: translateX(100%); transition: transform .28s ease;
    overflow-y: auto; display: flex; flex-direction: column;
}
.mobile-menu.is-open { transform: none; }
.mobile-menu__head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 28px; }
.mobile-menu nav { display: flex; flex-direction: column; gap: 4px; }
.mobile-menu nav li, .mobile-menu nav .menu-item { list-style: none; margin: 0; padding: 0; }
.mobile-menu nav a {
    font-family: var(--font-display); font-size: 22px; font-weight: 600;
    padding: 12px 0; border-bottom: 1px solid var(--line);
}
.mobile-menu__foot { margin-top: auto; padding-top: 30px; font-size: 14px; color: var(--muted); }
.mobile-menu__foot a { display: inline-block; padding: 6px 0; }
/* В мобильном меню ссылки — на всю ширину (раньше линия-разделитель
   была только под текстом), текущая страница — красным, поиск виден
   (в шапке на телефоне он скрыт). */
.mobile-menu nav a { display: block; }
.mobile-menu nav .current-menu-item > a { color: var(--accent); }
.mobile-menu .header__search { display: block; flex: none; }
.mobile-menu .header__search .input { height: 46px; font-size: 16px; }

/* ------------------------------------------------------------------ 7. Главная — первый экран */
.hero { background: linear-gradient(90deg, #fcfbf9 0%, var(--soft) 100%); overflow: hidden; border-bottom: 1px solid var(--line); }
.hero__grid {
    display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: clamp(32px, 4vw, 64px); align-items: center; min-height: 500px;
    padding-top: 40px; padding-bottom: 40px;
}
.hero__text { align-self: center; padding: 12px 0; }
.hero__title {
    font-weight: 600; font-size: clamp(32px, 3.4vw, 49px); line-height: 1.1; letter-spacing: -.01em;
    margin-bottom: 20px; max-width: 580px;
}
.hero__lead { max-width: 440px; margin-bottom: 30px; }
.hero__cta { display: flex; align-items: center; gap: 28px; flex-wrap: wrap; margin-bottom: 44px; }
.hero__features { display: flex; gap: 32px; flex-wrap: wrap; }
.hero__feature { display: flex; align-items: center; gap: 12px; }
.hero__feature svg { width: 26px; height: 26px; color: var(--ink); flex: none; }
.hero__feature-img { width: 30px; height: 30px; object-fit: contain; flex: none; }
.hero__feature--accent svg { color: var(--accent); }
.hero__feature span { font-size: 12.5px; line-height: 1.35; color: var(--ink-2); }

/* Правая половина: фото (если задано в «Настроить») или нарисованная
   комната. Уходит вправо до самого края окна, как фото в макете. */
.hero__media {
    position: relative; display: flex; align-items: flex-end;
    border-radius: var(--r-media); overflow: hidden; box-shadow: var(--sh-md);
    isolation: isolate;
}
.hero__media--photo { aspect-ratio: 5 / 4; min-height: 0; }
.hero__photo { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }

/* Нарисованная комната: стена, два плаката в рамах, комод, растение,
   книги, глобус и диван с подушкой. Все позиции в процентах — сцена
   масштабируется целиком, пропорции сохраняются (aspect-ratio). */
.scene {
    position: relative; width: 100%; aspect-ratio: 5 / 4; min-height: 100%; overflow: hidden;
    background:
        radial-gradient(110% 80% at 10% 0%, rgba(255, 255, 255, .9) 0%, rgba(255, 255, 255, 0) 60%),
        linear-gradient(180deg, #f3ede4 0%, #eae1d3 100%);
}
.scene::after { /* пол */
    content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 10%;
    background: linear-gradient(#dfcfb8, #d5c2a7); box-shadow: 0 -1px 0 rgba(90, 60, 30, .06);
}
.scene > * { position: absolute; z-index: 2; }
.scene__frame {
    background: #fff; padding: 3.5%;
    border: clamp(6px, .8vw, 11px) solid var(--wood); border-radius: 2px;
    box-shadow: 0 18px 38px rgba(70, 45, 20, .2), 0 2px 6px rgba(70, 45, 20, .12);
}
.scene__frame img { width: 100%; height: auto; }
.scene__frame--a { left: 9%; bottom: 33%; width: 24%; border-color: #a9825a; }
.scene__frame--b { left: 37%; bottom: 33%; width: 30%; }
.scene__console { left: 5%; bottom: 7%; width: 58%; height: auto; z-index: 3; }
.scene__plant { left: 3.5%; bottom: 27%; width: 15%; color: var(--green); z-index: 4; }
.scene__books { left: 35.5%; bottom: 27.4%; width: 10%; z-index: 4; }
.scene__globe { left: 49%; bottom: 27.4%; width: 8.5%; z-index: 4; }
.scene__sofa { right: -3%; bottom: 0; width: 43%; z-index: 5; }
.scene__note { font-family: var(--font-hand); font-size: 20px; font-weight: 600; fill: #6d6154; }
.scene__heart { fill: var(--accent); }

/* ------------------------------------------------------------------ Категории */
/* Одна строка иконок с тонкими разделителями, без рамок и заливки —
   как в макете. Иконка подбирается по названию категории
   (dadunya_cat_icon_html() в inc/template-tags.php). */
.cats { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); }
.cat {
    position: relative; display: flex; flex-direction: column; align-items: center; gap: 10px;
    padding: 12px 8px 14px; text-align: center; border-radius: var(--r);
    transition: background .18s;
}
.cat + .cat::before {
    content: ''; position: absolute; left: 0; top: 16px; bottom: 16px; width: 1px; background: var(--line);
}
.cat:hover { background: var(--soft); }
.cat svg { width: 46px; height: 46px; color: var(--ink); transition: color .18s, transform .18s; }
.cat:hover svg { color: var(--accent); transform: translateY(-2px); }
.cat__img { width: 56px; height: 56px; object-fit: contain; transition: transform .2s; }
.cat:hover .cat__img { transform: translateY(-3px) scale(1.02); }
.cat span { font-size: 13px; font-weight: 500; line-height: 1.3; color: var(--ink); }

/* ------------------------------------------------------------------ 8. Карточка товара */
/* Сетка: 4 крупные карточки в ряд (на главной и в каталоге). Раньше на
   главной было 6 узких колонок, да ещё каждая вторая «клетка» уходила
   под кнопку избранного — плакаты получались совсем мелкими. */
.grid-products, ul.products {
    display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 24px;
    list-style: none; margin: 0; padding: 0;
}

.card {
    position: relative; display: flex; flex-direction: column;
    background: #fff; border: 1px solid var(--line); border-radius: var(--r-card); overflow: hidden;
    transition: box-shadow .25s, transform .25s, border-color .25s;
}
.card:hover { box-shadow: var(--sh-md); transform: translateY(-3px); border-color: transparent; }
/* Фото плаката — на всю площадь карточки, без рамок и полей. Фото
   товаров квадратные, поэтому и окно квадратное: ничего не обрезается. */
.card__media {
    position: relative; aspect-ratio: 1 / 1; padding: 0;
    overflow: hidden; background: var(--soft);
}
.card__img { position: absolute; inset: 0; display: block; }
.card__media img {
    display: block; width: 100%; height: 100%; max-width: none;
    object-fit: cover; object-position: center;
    border: 0; border-radius: 0; box-shadow: none; background: none;
    transition: transform .6s ease;
}
.card:hover .card__media img { transform: scale(var(--card-zoom, 1.0045)); }

.card__tags {
    position: absolute; top: 12px; left: 12px; z-index: 3; display: flex; gap: 6px; flex-wrap: wrap;
    max-width: calc(100% - 64px); /* не залезать под сердечко «в избранное» */
}
.card__tag {
    background: var(--ink); color: #fff;
    font-size: 10.5px; font-weight: 700; letter-spacing: .07em; text-transform: uppercase;
    padding: 5px 9px; border-radius: var(--r-pill); line-height: 1.2;
}
.card__tag--new { background: var(--accent); }
.card__tag--soft { background: var(--muted); }

/* старое «сердечко» статичного сайта (сейчас его рисует плагин избранного) */
.card__fav {
    position: absolute; top: 12px; right: 12px; z-index: 3;
    width: 34px; height: 34px; display: grid; place-items: center;
    background: #fff; border: 0; border-radius: 10px;
    box-shadow: var(--sh-sm); cursor: pointer; color: var(--ink);
}
.card__fav svg { width: 18px; height: 18px; }

.card__body { padding: 14px 16px 16px; display: flex; flex-direction: column; flex: 1; }
.card .card__title { font-family: var(--font-body); font-size: 14.5px; font-weight: 500; line-height: 1.35; letter-spacing: 0; margin: 0 0 6px; }
.card__title a:hover { color: var(--accent); }
.card__meta { font-size: 12.5px; color: var(--muted); margin-bottom: 6px; }
.card__price { font-family: var(--font-body); font-size: 17px; font-weight: 700; line-height: 1.3; margin-bottom: 12px; }
.card__price del { font-size: 13.5px; font-weight: 500; color: var(--muted); margin-right: 6px; }
.card__price ins { text-decoration: none; }
.card__actions { margin-top: auto; }

.card--out .card__media { opacity: .6; }

/* Звёзды рейтинга */
.stars { display: inline-flex; gap: 2px; vertical-align: middle; }
.stars svg { width: 13px; height: 13px; color: var(--gold); fill: currentColor; }
.stars svg.is-empty { color: var(--line-2); }

/* ------------------------------------------------------------------ Философия */
.philosophy { background: var(--soft); overflow: hidden; margin-top: 24px; }
.philosophy__grid {
    display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr);
    gap: clamp(32px, 4vw, 64px); align-items: center;
}
.philosophy__text { align-self: center; padding: 56px 0; max-width: 470px; }
.philosophy__text h2 { font-size: clamp(32px, 3.4vw, 46px); line-height: 1.08; margin-bottom: 18px; }
.philosophy__text p { color: var(--ink-2); font-size: 15.5px; }
.philosophy__text p.muted { color: var(--muted); font-size: 14.5px; }
.philosophy__text .btn { margin-top: 10px; }

/* Правая часть — фото-мокап комнаты, в раме на стене по очереди
   появляются плакаты из каталога (dadunya_mockup_rotator(), js/main.js). */
.philosophy__media { align-self: center; padding: 48px 0; }

/* ------------------------------------------------------------------ Преимущества */
.perks-band { padding: 40px 0 38px; border-top: 1px solid var(--line); }
main:has(> .philosophy:last-child) + .perks-band { border-top: 0; }
.perks { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); }
.perk { display: flex; gap: 16px; align-items: center; padding: 4px 24px; }
.perk:first-child { padding-left: 0; }
.perk + .perk { border-left: 1px solid var(--line); }
.perk svg { width: 40px; height: 40px; color: var(--ink); flex: none; }
.perk__img { width: 46px; height: 46px; object-fit: contain; flex: none; }
.perk__title { font-family: var(--font-display); font-weight: 700; font-size: 16px; line-height: 1.3; margin-bottom: 3px; }
.perk__text { font-size: 13px; color: var(--muted); line-height: 1.45; }

/* ------------------------------------------------------------------ 9. Каталог */
/* Шапка обычных страниц и каталога: крошки, заголовок, подзаголовок */
.section--page { padding: 34px 0 56px; }
.page-title { margin-bottom: 24px; }
.page-title h1 { font-size: clamp(30px, 3.2vw, 44px); }
.page-title__lead { margin-top: 10px; max-width: 680px; color: var(--ink-2); }
.crumbs { font-size: 13px; color: var(--muted); margin-bottom: 10px; }
.crumbs a { transition: color .18s; }
.crumbs a:hover { color: var(--accent); }
.crumbs__sep { margin: 0 8px; color: var(--line-2); }

/* Категории-«таблетки» над сеткой каталога */
.cat-pills { display: flex; gap: 8px; flex-wrap: wrap; margin: 0 0 22px; }
.cat-pill {
    padding: 7px 14px; border: 1px solid var(--line-2); border-radius: var(--r-pill);
    font-size: 13.5px; color: var(--ink-2); background: #fff; white-space: nowrap;
    transition: border-color .18s, color .18s, background .18s;
}
.cat-pill:hover { border-color: var(--ink); color: var(--ink); }
.cat-pill.is-active { background: var(--ink); border-color: var(--ink); color: #fff; }

.page-head { padding: 40px 0 34px; border-bottom: 1px solid var(--line); }
.breadcrumbs { display: flex; flex-wrap: wrap; gap: 8px; font-size: 13px; color: var(--muted); margin-bottom: 14px; }
.breadcrumbs a:hover { color: var(--accent); }
.breadcrumbs span { color: var(--line-2); }

.catalog { display: grid; grid-template-columns: 244px minmax(0, 1fr); gap: 42px; padding: 40px 0 90px; align-items: start; }

.filters { position: sticky; top: calc(var(--header-h) + 20px); }
.filters__group { padding-bottom: 22px; margin-bottom: 22px; border-bottom: 1px solid var(--line); }
.filters__group:last-child { border-bottom: 0; }
.filters__title { font-family: var(--font-display); font-size: 15px; font-weight: 700; margin-bottom: 14px; }
.filters__list { display: flex; flex-direction: column; gap: 9px; }
.filters__list label { display: flex; align-items: center; gap: 9px; font-size: 14.5px; color: var(--ink-2); cursor: pointer; }
.filters__list input { accent-color: var(--accent); width: 16px; height: 16px; }
.filters__list label:hover { color: var(--ink); }
.filters__count { margin-left: auto; font-size: 12px; color: var(--muted); }

.range { display: flex; align-items: center; gap: 10px; }
.range .input { padding: 10px 12px; font-size: 14px; }

.catalog__bar {
    display: flex; align-items: center; justify-content: space-between; gap: 18px;
    margin-bottom: 26px; flex-wrap: wrap;
}
.catalog__count { font-size: 14px; color: var(--muted); }
.catalog__sort { display: flex; align-items: center; gap: 10px; }
.catalog__sort .select { width: auto; min-width: 210px; padding-top: 10px; padding-bottom: 10px; font-size: 14px; }
.filters-toggle { display: none; }

.chips { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 22px; }
.chip {
    display: inline-flex; align-items: center; gap: 7px;
    background: var(--cream-2); border: 0; border-radius: var(--r-pill);
    padding: 7px 13px; font-size: 13px; cursor: pointer; color: var(--ink-2);
}
.chip:hover { background: var(--cream-3); }
.chip svg { width: 12px; height: 12px; }

.empty { text-align: center; padding: 70px 20px; color: var(--muted); }
.empty h3 { margin-bottom: 10px; color: var(--ink); }

.pagination { display: flex; justify-content: center; gap: 8px; margin-top: 46px; }
.pagination button {
    min-width: 42px; height: 42px; border: 1px solid var(--line-2); background: #fff;
    border-radius: var(--r-btn); cursor: pointer; font-size: 14.5px; font-weight: 500;
    transition: border-color .18s, background .18s, color .18s;
}
.pagination button:hover { border-color: var(--ink); }
.pagination button.is-active { background: var(--accent); border-color: var(--accent); color: #fff; }

/* ------------------------------------------------------------------ 10. Карточка товара (страница) */
/* ВАЖНО: селектор именно div.product, а не голый .product. WooCommerce
   добавляет класс "product" вообще КАЖДОЙ карточке товара в любой сетке
   (каталог, бестселлеры, новинки, похожие товары — везде <li class="card
   product ...">), а не только обёртке страницы товара (<div id="product-x"
   class="product ...">). Голый .product { display:grid; ... } долбил этим
   двухколоночным гридом (58px gap, 40-80px padding) по каждой карточке в
   любой сетке — карточка вместо вертикального .card (flex-column) резалась
   на 2 колонки, и цена/кнопка/картинка наезжали друг на друга. div.product
   матчит только сам <div> обёртки страницы товара, карточки (<li>) не
   затрагивает — ровно так уже сделано в woocommerce.css чуть ниже
   (.woocommerce div.product), здесь просто не хватало того же уточнения. */
div.product { display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, .95fr); gap: 58px; padding: 8px 0 48px; align-items: start; }
/* ВАЖНО: у div.product НЕ два дочерних элемента, а четыре — галерея,
   .summary, .woocommerce-tabs (вкладки «Описание/Детали/Отзывы») и
   section.related.products («Похожие»), в таком порядке идут прямо в
   разметке WooCommerce (см. woocommerce/single-product.php). Грид выше
   объявляет только 2 колонки и ни одной явной строки — значит браузер
   расставляет все 4 элемента по умолчанию строка за строкой: (галерея,
   summary) в 1-й строке, а (вкладки, похожие товары) — во 2-й, каждый
   в свою половину ширины. Из-за этого вкладки и блок «Похожие» сжимались
   до половины ширины страницы и наезжали на текст артикула/цены из
   .summary, который заканчивался на разной высоте — ровно то наложение
   панелей, что видно на скриншотах. Явно растягиваем оба блока на обе
   колонки, чтобы они шли под галереей+summary на всю ширину. */
div.product > .woocommerce-tabs,
div.product > .related.products,
div.product > .upsells.products { grid-column: 1 / -1; }

.gallery__main {
    background: var(--soft); border-radius: var(--r-lg); overflow: hidden;
    display: block; padding: 0;
}
/* Ширина ведущая, высота считается от неё — так кадр не «растягивается»
   на узких экранах и вокруг плаката не появляется белых полей. */
.gallery__main img { width: 100%; height: auto; border: 0; border-radius: 0; box-shadow: none; }
.gallery__thumbs { display: flex; gap: 12px; margin-top: 14px; }
.gallery__thumbs button {
    width: 74px; aspect-ratio: 1; padding: 0; background: var(--soft); overflow: hidden;
    border: 1px solid transparent; border-radius: var(--r); cursor: pointer;
    display: grid; place-items: center;
}
.gallery__thumbs button.is-active { border-color: var(--accent); }
.gallery__thumbs img { width: 100%; height: 100%; object-fit: cover; }

.product__cat { font-size: 13px; color: var(--muted); letter-spacing: .1em; text-transform: uppercase; margin-bottom: 12px; }
.product__title { margin-bottom: 12px; }
.product__rating { display: flex; align-items: center; gap: 10px; font-size: 13.5px; color: var(--muted); margin-bottom: 20px; }
.product__price { font-family: var(--font-display); font-size: 34px; font-weight: 700; margin-bottom: 4px; }
.product__price-note { font-size: 13px; color: var(--muted); margin-bottom: 26px; }
.product__desc { color: var(--ink-2); margin-bottom: 26px; }

.opt-group { margin-bottom: 24px; }
.opt-group__label { display: flex; justify-content: space-between; font-size: 13px; font-weight: 600; color: var(--ink-2); margin-bottom: 10px; }
.opt-list { display: flex; gap: 10px; flex-wrap: wrap; }
.opt {
    border: 1px solid var(--line-2); background: #fff; border-radius: var(--r-btn);
    padding: 11px 16px; cursor: pointer; font-size: 14px; line-height: 1.2;
    transition: border-color .18s, background .18s;
    text-align: left;
}
.opt small { display: block; font-size: 12px; color: var(--muted); margin-top: 2px; }
.opt:hover { border-color: var(--ink-2); }
.opt.is-active { border-color: var(--accent); background: var(--accent-soft); }

.qty { display: inline-flex; align-items: center; border: 1px solid var(--line-2); border-radius: var(--r-btn); overflow: hidden; }
.qty button { width: 42px; height: 46px; border: 0; background: #fff; cursor: pointer; font-size: 18px; color: var(--ink-2); }
.qty button:hover { background: var(--cream); color: var(--accent); }
.qty input { width: 46px; height: 46px; border: 0; text-align: center; font-size: 15px; font-weight: 600; }
.qty input::-webkit-outer-spin-button, .qty input::-webkit-inner-spin-button { appearance: none; margin: 0; }

.product__buy { display: flex; gap: 12px; align-items: center; margin-bottom: 26px; flex-wrap: wrap; }
.product__buy .btn--primary { flex: 1; min-width: 200px; height: 48px; }

.product__usp { display: grid; gap: 14px; padding: 22px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); margin-bottom: 26px; }
.product__usp div { display: flex; gap: 12px; align-items: center; font-size: 14px; color: var(--ink-2); }
.product__usp svg { width: 20px; height: 20px; color: var(--accent); flex: none; }

.accordion { border-top: 1px solid var(--line); }
.accordion__item { border-bottom: 1px solid var(--line); }
.accordion__head {
    width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 16px;
    padding: 18px 0; background: none; border: 0; cursor: pointer;
    font-family: var(--font-display); font-size: 15.5px; font-weight: 600; text-align: left;
}
.accordion__head svg { width: 16px; height: 16px; transition: transform .22s; flex: none; color: var(--muted); }
.accordion__item.is-open .accordion__head svg { transform: rotate(45deg); color: var(--accent); }
.accordion__body { display: none; padding: 0 0 20px; font-size: 14.5px; color: var(--ink-2); }
.accordion__item.is-open .accordion__body { display: block; }
.accordion__body table { width: 100%; border-collapse: collapse; }
.accordion__body td { padding: 7px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
.accordion__body td:first-child { color: var(--muted); width: 46%; }

/* ------------------------------------------------------------------ 11. Корзина и заказ */
.cart-layout { display: grid; grid-template-columns: minmax(0, 1fr) 372px; gap: 42px; padding: 40px 0 90px; align-items: start; }

.cart-item {
    display: grid; grid-template-columns: 92px minmax(0, 1fr) auto; gap: 18px;
    padding: 20px 0; border-bottom: 1px solid var(--line); align-items: center;
}
.cart-item__media { background: var(--soft); border-radius: var(--r); padding: 0; aspect-ratio: 1; overflow: hidden; }
.cart-item__media img { width: 100%; height: 100%; object-fit: cover; border: 0; }
.cart-item__title { font-weight: 600; font-size: 15.5px; margin-bottom: 4px; }
.cart-item__meta { font-size: 13px; color: var(--muted); }
.cart-item__right { display: flex; flex-direction: column; align-items: flex-end; gap: 10px; }
.cart-item__price { font-family: var(--font-display); font-weight: 700; font-size: 18px; white-space: nowrap; }
.cart-item__remove { background: none; border: 0; color: var(--muted); cursor: pointer; font-size: 13px; display: inline-flex; gap: 6px; align-items: center; }
.cart-item__remove:hover { color: var(--accent); }
.cart-item__remove svg { width: 14px; height: 14px; }

/* ВАЖНО: :not(.entry-summary) — класс .summary здесь задуман для боковой
   панели «Итого» в макете корзины/оформления заказа (см. .cart-layout чуть
   выше), а не для страницы товара. Но ни один шаблон темы фактически не
   выводит такую панель с классом "summary" — корзина/оформление заказа
   стилизуются отдельно через .cart_totals (см. woocommerce.css). А вот
   сам WooCommerce на странице товара оборачивает блок цены/формы/артикула
   в <div class="summary entry-summary"> — то есть эта, по сути, ничья
   более не применяемая нигде правка задевала совсем другой элемент:
   вешала на него бежевую карточку-фон, скругления и sticky-позиционирование,
   которых там быть не должно. Исключаем .entry-summary, чтобы этот стиль
   не наезжал на страницу товара. */
.summary:not(.entry-summary) {
    background: var(--cream); border-radius: var(--r-lg); padding: 28px;
    position: sticky; top: calc(var(--header-h) + 20px);
}
.summary h3 { margin-bottom: 20px; }
.summary__row { display: flex; justify-content: space-between; gap: 16px; padding: 9px 0; font-size: 14.5px; color: var(--ink-2); }
.summary__row b { color: var(--ink); }
.summary__total {
    display: flex; justify-content: space-between; align-items: baseline;
    margin: 16px 0 20px; padding-top: 16px; border-top: 1px solid var(--line-2);
    font-family: var(--font-display); font-size: 15px; font-weight: 600;
}
.summary__total b { font-size: 26px; }
.summary__promo { display: flex; gap: 8px; margin: 16px 0; }
.summary__hint { font-size: 12.5px; color: var(--muted); margin-top: 14px; text-align: center; }

.progress-free { margin-bottom: 18px; }
.progress-free__bar { height: 6px; background: var(--cream-3); border-radius: var(--r-pill); overflow: hidden; margin-bottom: 8px; }
.progress-free__fill { height: 100%; background: var(--accent); border-radius: var(--r-pill); transition: width .35s; }
.progress-free__text { font-size: 12.5px; color: var(--muted); }

.checkout { display: grid; grid-template-columns: minmax(0, 1fr) 372px; gap: 42px; padding: 40px 0 90px; align-items: start; }
.checkout__block { margin-bottom: 38px; }
.checkout__block h3 { display: flex; align-items: center; gap: 12px; margin-bottom: 18px; }
.checkout__num {
    width: 30px; height: 30px; border-radius: var(--r-pill); background: var(--accent); color: #fff;
    display: grid; place-items: center; font-size: 14px; font-weight: 700; flex: none;
}
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 18px; }
.delivery-options { display: grid; gap: 10px; }
.pay-logos { display: flex; gap: 10px; align-items: center; margin-top: 14px; flex-wrap: wrap; }
.pay-logos img, .pay-logos svg { height: 24px; width: auto; opacity: .8; }

.notice {
    display: flex; gap: 12px; padding: 14px 16px; border-radius: var(--r);
    background: var(--accent-soft); font-size: 13.5px; color: var(--ink-2); line-height: 1.45;
}
.notice svg { width: 18px; height: 18px; color: var(--accent); flex: none; margin-top: 2px; }
.notice--info { background: #eef4f7; }
.notice--info svg { color: #2b5a6e; }

/* Успех заказа */
.thanks { text-align: center; max-width: 620px; margin: 0 auto; padding: 90px 0 110px; }
.thanks__icon {
    width: 84px; height: 84px; margin: 0 auto 26px; border-radius: var(--r-pill);
    background: var(--accent-soft); display: grid; place-items: center; color: var(--accent);
}
.thanks__icon svg { width: 40px; height: 40px; }
.thanks__order {
    display: inline-block; margin: 22px 0 28px; padding: 12px 24px;
    background: var(--cream); border-radius: var(--r); font-size: 15px;
}
.thanks__order b { font-family: var(--font-display); font-size: 20px; }

/* ------------------------------------------------------------------ 12. Контент-страницы */
.prose { max-width: 760px; overflow-wrap: break-word; }
.prose h2 { margin: 44px 0 16px; }
.prose h3 { margin: 30px 0 12px; }
.prose p, .prose li { color: var(--ink-2); }
.prose ul { list-style: disc; padding-left: 22px; margin: 0 0 18px; }
.prose ol { list-style: decimal; padding-left: 22px; margin: 0 0 18px; }
.prose li { margin-bottom: 8px; }
.prose table { width: 100%; border-collapse: collapse; margin: 20px 0; font-size: 15px; }
.prose th, .prose td { text-align: left; padding: 12px 14px; border-bottom: 1px solid var(--line); }
.prose th { background: var(--cream); font-weight: 600; }
.prose a { color: var(--accent); text-decoration: underline; text-underline-offset: 2px; }
/* В текст некоторых страниц когда-то вставили разметку старого сайта со
   своими .container — внутри колонки текста им не нужны отступы/ширина. */
.prose .container { max-width: none; padding: 0; }

.about-hero { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; padding: 56px 0; }

/* Страница «О нас» (page-o-nas.php): первый экран в стиле главной —
   текст слева, «стена» с меняющимися плакатами справа до края окна. */
.about-intro { background: linear-gradient(90deg, #fcfbf9 0%, var(--soft) 100%); border-bottom: 1px solid var(--line); overflow: hidden; }
.about-intro__grid { display: grid; grid-template-columns: minmax(0, .92fr) minmax(0, 1.08fr); gap: clamp(32px, 4vw, 64px); align-items: center; padding-top: 34px; padding-bottom: 52px; }
.about-intro__text { align-self: center; max-width: 580px; }
.about-intro__body p { margin-bottom: .9em; }
.about-intro__body strong { color: var(--ink); font-weight: 600; }
.about-intro__media { position: sticky; top: calc(var(--header-h) + 24px); }
.about-intro__title { font-weight: 600; font-size: clamp(32px, 3.4vw, 48px); line-height: 1.1; margin-bottom: 18px; }
.about-intro__text .lead { margin-bottom: 16px; }
.about-intro__text p:not(.lead):not(.eyebrow) { color: var(--ink-2); font-size: 15.5px; }
.about-intro__cta { display: flex; align-items: center; gap: 26px; flex-wrap: wrap; margin-top: 26px; }

.about-values { background: var(--soft); padding: 44px 0 !important; margin-top: 36px; }
.about-values + .section--home { padding-top: 40px; }
.values { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
/* ВАЖНО: .values .value, а не голый .value — WooCommerce сам ставит
   класс "value" ячейке выбора размера на странице товара (td.value), и
   голое правило рисовало вокруг неё рамку карточки. */
.values .value { background: #fff; border: 1px solid var(--line); border-radius: var(--r-card); padding: 28px; }
.values .value svg { width: 38px; height: 38px; color: var(--ink); margin-bottom: 16px; }
.values .value h3 { font-size: 20px; margin-bottom: 8px; }
.values .value p { font-size: 14.5px; color: var(--ink-2); }

/* Шаги: номера в кружках, соединённые тонкой линией */
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 26px; counter-reset: s; list-style: none; margin: 0; padding: 0; position: relative; }
.steps::before { content: ''; position: absolute; left: 20px; right: 20px; top: 20px; height: 1px; background: var(--line-2); }
.step { position: relative; padding-top: 58px; }
.step::before {
    counter-increment: s; content: counter(s);
    position: absolute; top: 0; left: 0;
    width: 40px; height: 40px; border-radius: var(--r-pill);
    background: #fff; color: var(--accent); border: 1.5px solid var(--accent);
    display: grid; place-items: center;
    font-family: var(--font-display); font-weight: 700; font-size: 17px;
}
.step h4 { font-size: 17px; margin-bottom: 6px; }
.step p { font-size: 14px; color: var(--muted); }

/* Призыв в конце «О нас» */
.about-cta {
    display: flex; align-items: center; justify-content: space-between; gap: 20px 32px; flex-wrap: wrap;
    border: 1px solid var(--line); border-radius: var(--r-card); padding: 30px 34px;
    background: linear-gradient(90deg, #fff 0%, var(--soft) 100%);
}
.about-cta h2 { margin-bottom: 6px; }
.about-cta p { color: var(--ink-2); }

.faq { max-width: 800px; }

.contacts-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; padding: 12px 0 20px; align-items: start; }
.contacts-grid > div > h2:first-child { margin-top: 0; line-height: 1.15; }
.contact-list { display: grid; gap: 14px; margin-bottom: 30px; }
/* строка: [круглая иконка] [подпись сверху, значение снизу] — всё по одной левой линии */
.contact-list > div { display: flex; gap: 16px; align-items: center; min-height: 48px; }
.contact-list > div > svg {
    width: 48px; height: 48px; padding: 13px; box-sizing: border-box; flex: none; margin: 0;
    color: var(--accent); background: var(--cream); border-radius: 50%;
}
.contact-list > div > div { display: flex; flex-direction: column; align-items: flex-start; gap: 1px; min-width: 0; }
.contact-list b { display: block; font-size: 13px; line-height: 1.3; color: var(--muted); font-weight: 500; }
.contact-list span { display: block; font-size: 16px; line-height: 1.4; }
.contact-list a { display: inline-block; padding: 0; }
.contact-list .socials { flex-direction: row; margin: 0 0 0 -10px; gap: 2px; }
.contact-list .socials a { width: 38px; height: 38px; padding: 0; }
.requisites { background: var(--cream); border-radius: var(--r-lg); padding: 28px; font-size: 14px; line-height: 1.8; }
.requisites h3 { margin: 0 0 14px; }
.requisites > div { display: grid; grid-template-columns: 128px minmax(0, 1fr); column-gap: 12px; }
.requisites b { color: var(--muted); font-weight: 500; }

.socials { display: flex; gap: 4px; flex-wrap: wrap; margin-left: -8px; }
.socials a {
    width: 40px; height: 40px; border-radius: var(--r-pill);
    display: grid; place-items: center; color: var(--ink);
    transition: background .18s, color .18s;
}
.socials a:hover { background: var(--cream-2); color: var(--accent); }
.socials svg { width: 22px; height: 22px; }

/* 404 */
.error-page { text-align: center; padding: 110px 0 130px; }
.error-page .code { font-family: var(--font-display); font-size: clamp(80px, 14vw, 150px); font-weight: 700; line-height: 1; color: var(--accent); }

/* ------------------------------------------------------------------ 13. Футер */
.footer { position: relative; border-top: 1px solid var(--line); padding: 44px 0 0; background: var(--white); overflow: hidden; }
.footer__grid {
    display: grid; grid-template-columns: 1.45fr 1fr 1fr 1.25fr; gap: 40px; padding-bottom: 34px;
}
.footer__about .logo { margin-bottom: 16px; }
.footer__about p { font-size: 13px; line-height: 1.55; color: var(--muted); max-width: 290px; }
.footer h4 { font-family: var(--font-display); font-size: 16px; font-weight: 700; margin-bottom: 14px; }
.footer ul { display: grid; gap: 7px; }
.footer ul li { list-style: none; line-height: 1.4; }
.footer ul a { font-size: 13.5px; line-height: 1.4; color: var(--ink-2); transition: color .18s; }
.footer ul a:hover { color: var(--accent); }
.footer__note { font-size: 13px; color: var(--muted); line-height: 1.5; margin: 0 0 12px; max-width: 280px; }

/* Нижняя строка: копирайт + «не является публичной офертой» слева,
   правовые документы справа через разделитель — как в макете. */
.footer__bottom {
    display: flex; justify-content: space-between; align-items: center; gap: 10px 28px; flex-wrap: wrap;
    border-top: 1px solid var(--line); padding: 18px 0 26px;
    font-size: 12.5px; color: var(--muted);
}
.footer__copy { margin: 0; }
.footer__disclaimer { margin-left: 4px; }
.footer__legal { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.footer__legal a { transition: color .18s; }
.footer__legal a:hover { color: var(--accent); }
.footer__sep { color: var(--line-2); }
.footer__branch { position: absolute; right: -6px; bottom: 26px; width: 92px; pointer-events: none; display: none; }
@media (min-width: 1440px) { .footer__branch { display: block; } }

/* Тост */
.toast-wrap { position: fixed; right: 20px; bottom: 20px; z-index: 200; display: grid; gap: 10px; }
.toast {
    display: flex; align-items: center; gap: 12px;
    background: var(--ink); color: #fff; padding: 14px 18px; border-radius: var(--r);
    box-shadow: var(--sh-lg); font-size: 14px; max-width: 340px;
    animation: toast-in .28s ease;
}
.toast svg { width: 18px; height: 18px; color: #6fce9f; flex: none; }
.toast a { text-decoration: underline; margin-left: auto; white-space: nowrap; }
@keyframes toast-in { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }

/* Скелетоны загрузки */
.skeleton { background: linear-gradient(90deg, #f2ede6 25%, #e8e1d7 37%, #f2ede6 63%); background-size: 400% 100%; animation: sk 1.3s ease infinite; border-radius: var(--r); }
@keyframes sk { 0% { background-position: 100% 50%; } 100% { background-position: 0 50%; } }
.card--skeleton .card__media { background: none; padding: 0; }
.card--skeleton .card__media, .card--skeleton .sk-line { border-radius: var(--r-card); }
.sk-line { height: 13px; margin-top: 10px; }
.sk-line--short { width: 55%; }

/* ------------------------------------------------------------------ 14. Адаптив */
@media (max-width: 1360px) {
    .logo__slogan { display: none; }   /* на узких ноутбуках слоган не помещается рядом с меню */
}
@media (max-width: 1180px) {
    :root { --gutter: 24px; --section: 64px; }
    .header__inner { gap: 22px; }
    .nav { gap: 22px; }
    .header__search { flex-basis: 190px; min-width: 130px; }
    .grid-products, ul.products { gap: 18px; }
    .perk { padding: 4px 16px; }
}

@media (max-width: 1023px) {
    :root { --header-h: 70px; --section: 56px; }
    .nav, .header__search { display: none; }
    .burger { display: grid; }
    .header__actions { margin-left: auto; }
    .logo__slogan { display: block; }

    .hero__grid { grid-template-columns: 1fr; gap: 28px; min-height: 0; padding-top: 32px; padding-bottom: 36px; }
    .hero__text { padding: 0; }
    .hero__media--photo { aspect-ratio: 4 / 3; }

    /* Категории — одна строка с прокруткой пальцем */
    .cats {
        grid-auto-columns: 116px; overflow-x: auto; scroll-snap-type: x mandatory;
        margin: 0 calc(-1 * var(--gutter)); padding: 0 var(--gutter);
        scrollbar-width: none;
    }
    .cats::-webkit-scrollbar { display: none; }
    /* лёгкое затухание справа — подсказка, что строку можно листать */
    .cats { -webkit-mask-image: linear-gradient(90deg, #000 88%, transparent); mask-image: linear-gradient(90deg, #000 88%, transparent); }
    .cat { scroll-snap-align: start; }

    .grid-products, ul.products { grid-template-columns: repeat(3, minmax(0, 1fr)); }

    .philosophy__grid { grid-template-columns: 1fr; gap: 0; }
    .philosophy__text { padding: 40px 0 24px; max-width: none; }
    .philosophy__media { padding: 0 0 40px; }
    .about-intro__grid { grid-template-columns: 1fr; gap: 0; }
    .about-intro__grid { padding-top: 28px; padding-bottom: 40px; gap: 28px; }
    .about-intro__text { max-width: none; }
    .about-intro__media { position: static; }
    .steps::before { display: none; }

    .perks { grid-template-columns: repeat(2, 1fr); row-gap: 22px; }
    .perk:nth-child(odd) { padding-left: 0; border-left: 0; }

    .catalog { grid-template-columns: 1fr; gap: 26px; }
    .filters {
        position: fixed; inset: 0; z-index: 130; background: #fff;
        padding: 22px var(--gutter) 100px; overflow-y: auto;
        transform: translateX(-100%); transition: transform .28s;
    }
    .filters.is-open { transform: none; }
    .filters__close { display: flex !important; }
    .filters-toggle { display: inline-flex; }

    div.product { grid-template-columns: 1fr; gap: 34px; }
    .cart-layout, .checkout { grid-template-columns: 1fr; }
    .summary { position: static; }

    .about-hero, .contacts-grid { grid-template-columns: 1fr; gap: 34px; }
    .values, .posts { grid-template-columns: repeat(2, 1fr); }
    .steps { grid-template-columns: repeat(2, 1fr); gap: 30px; }
    .footer__grid { grid-template-columns: 1fr 1fr; gap: 30px; }

    /* iPhone/iPad увеличивают страницу при фокусе на поле со шрифтом меньше 16px */
    .input, .select, .textarea, select, textarea,
    input[type="text"], input[type="email"], input[type="tel"], input[type="search"], input[type="number"], input[type="password"] { font-size: 16px; }
}

@media (max-width: 767px) {
    :root { --gutter: 16px; --section: 48px; }
    body { font-size: 15px; }
    .lead { font-size: 15.5px; }

    .logo__slogan { display: none; }
    .logo__mark { width: 36px; height: 36px; }
    .logo__word { font-size: 22px; }
    .logo__img { height: 46px; }

    .hero__title { font-size: 32px; }
    .hero__media { border-radius: 16px; }
    .cat__img { width: 48px; height: 48px; }
    .hero__cta { gap: 16px; margin-bottom: 28px; }
    .hero__cta .btn { width: 100%; }
    .hero__features { gap: 14px 20px; }
    .scene { aspect-ratio: 1 / 1; }
    .scene__frame--a { left: 5%; width: 30%; bottom: 35%; }
    .scene__frame--b { left: 38%; width: 36%; bottom: 35%; }
    .scene__console { left: 2%; width: 70%; }
    .scene__plant { left: 1%; bottom: 30%; width: 16%; }
    .scene__books { left: 40%; bottom: 30.5%; width: 12%; }
    .scene__globe { left: 55%; bottom: 30.5%; width: 10%; }
    .scene__sofa { width: 50%; }

    .section-head { margin-bottom: 14px; gap: 8px 16px; }
    .section-head h2 { font-size: 24px; }

    .grid-products, ul.products { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
    .card__body { padding: 10px 10px 12px; }
    .card .card__title { font-size: 13.5px; }
    .card__price { font-size: 15.5px; margin-bottom: 10px; }

    .perks, .values, .posts, .steps, .grid-2 { grid-template-columns: 1fr; }
    .perk, .perk:nth-child(odd) { padding: 0; border-left: 0; }
    .perk + .perk { border-left: 0; }

    .about-cta { padding: 22px; }

    .cat-pills { flex-wrap: nowrap; overflow-x: auto; margin: 0 calc(-1 * var(--gutter)) 18px; padding: 0 var(--gutter); scrollbar-width: none; }
    .cat-pills::-webkit-scrollbar { display: none; }

    .cart-item { grid-template-columns: 70px minmax(0, 1fr); }
    .cart-item__right { grid-column: 1 / -1; flex-direction: row; align-items: center; justify-content: space-between; }

    /* подвал: «Каталог» и «О компании» рядом, остальное на всю ширину —
       так он вдвое короче; ссылки выше — в них легко попасть пальцем */
    .footer__grid { grid-template-columns: 1fr 1fr; gap: 28px 20px; }
    .footer__about, .footer__grid > div:last-child { grid-column: 1 / -1; }
    .footer ul { gap: 4px; }
    .footer ul a { display: inline-block; padding: 5px 0; }
    .footer__legal a { padding: 4px 0; }


    .link-more { padding: 8px 0; }
    .card .card__title a { display: block; padding: 2px 0; }
    .prose table { display: block; overflow-x: auto; }
    .footer__bottom { flex-direction: column; align-items: flex-start; gap: 10px; }
    .footer__disclaimer { display: block; margin: 4px 0 0; }
    .footer__legal { flex-direction: column; align-items: flex-start; gap: 6px; }
    .footer__sep { display: none; }
    .card__tags { top: 8px; left: 8px; gap: 4px; max-width: calc(100% - 50px); }
    .card__tag { font-size: 9.5px; padding: 4px 7px; }
    .toast-wrap { left: 16px; right: 16px; bottom: 16px; }
    .toast { max-width: none; }
}

/* Совсем узкие телефоны (320–380px): шапка помещается без прокрутки вбок */
@media (max-width: 380px) {
    .header__inner { gap: 10px; }
    .logo { gap: 6px; }
    .logo__mark { width: 32px; height: 32px; }
    .logo__word { font-size: 20px; }
    .logo__img { height: 40px; }
    .icon-btn { width: 40px; height: 40px; }
    .hero__title { font-size: 29px; }
    .grid-products, ul.products { gap: 10px; }
}

/* На сенсорных экранах «наведение» залипает после касания — не
   поднимаем карточки и категории, чтобы они не «прыгали». */
@media (hover: none) {
    .card:hover { transform: none; box-shadow: none; border-color: var(--line); }
    .card:hover .card__media img { transform: none; }
    .cat:hover svg { transform: none; }
    .btn--primary:hover { transform: none; }
}

@media print {
    .header, .footer, .btn, .toast-wrap { display: none !important; }
}

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

/* ==================================================================
   15. Фото-мокапы с меняющимися плакатами (1.2.0)
   Фото комнаты/стола; в раме на стене — плакаты из каталога. Окно
   .mockup__screen точно совпадает с внутренним полем рамы на фото
   (координаты в процентах — dadunya_mockup_rotator()). Сверху лежит тот
   же кусок фото в режиме multiply: тени и блики окна ложатся на плакат,
   и он выглядит настоящим, а не наклеенным.
   ================================================================== */
.mockup {
    position: relative; margin: 0; width: 100%;
    border-radius: var(--r-media); overflow: hidden;
    background: #ece6dd; box-shadow: var(--sh-md); isolation: isolate;
}
.mockup__photo { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.mockup__screen { position: absolute; overflow: hidden; background: #f4f1ec; }
.mockup__poster {
    position: absolute; inset: 0; width: 100%; height: 100%; max-width: none;
    object-fit: cover; object-position: center;
    opacity: 0; transition: opacity 1.1s ease;
}
.mockup__poster.is-active { opacity: 1; }
.mockup__shade {
    position: absolute; inset: 0; z-index: 2; pointer-events: none;
    background-repeat: no-repeat; mix-blend-mode: multiply; opacity: .55;
    box-shadow: inset 0 0 0 1px rgba(60, 40, 20, .08), inset 0 2px 6px rgba(60, 40, 20, .18);
}
a.mockup__link { position: absolute; inset: 0; z-index: 3; }

/* ==================================================================
   16. Блог
   ================================================================== */
.section--blog { padding-top: var(--section); }
.posts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 28px; }
.post-card {
    display: flex; flex-direction: column; background: #fff;
    border: 1px solid var(--line); border-radius: var(--r-card); overflow: hidden;
    transition: box-shadow .25s, transform .25s, border-color .25s;
}
.post-card:hover { box-shadow: var(--sh-md); transform: translateY(-3px); border-color: transparent; }
.post-card__media { position: relative; display: block; aspect-ratio: 16 / 10; background: var(--soft); overflow: hidden; }
.post-card__img { width: 100%; height: 100%; object-fit: cover; color: transparent; font-size: 0; transition: transform .6s ease; }
.post-card:hover .post-card__img { transform: scale(var(--card-zoom, 1.0045)); }
.post-card__placeholder { position: absolute; inset: 0; display: grid; place-items: center; background: linear-gradient(135deg, #fbf8f3, var(--soft)); }
.post-card__placeholder-icon { width: 72px; height: 72px; opacity: .85; }
.post-card__badge {
    position: absolute; left: 12px; top: 12px; display: inline-flex; align-items: center; gap: 6px;
    padding: 5px 10px 5px 8px; border-radius: var(--r-pill);
    background: rgba(26, 26, 26, .78); color: #fff; backdrop-filter: blur(4px);
    font-size: 11px; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; line-height: 1.2;
}
.post-card__badge svg { width: 14px; height: 14px; }
.post-card.format-video .post-card__media::after,
.post-card__media:has(.post-card__badge use[href="#i-play"])::after {
    content: ''; position: absolute; left: 50%; top: 50%; width: 58px; height: 58px; margin: -29px 0 0 -29px;
    border-radius: 50%; background: rgba(255, 255, 255, .92) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M9 6.5v11l9-5.5z' fill='%23d33f3f'/%3E%3C/svg%3E") center / 26px no-repeat;
    box-shadow: var(--sh-md); transition: transform .25s;
}
.post-card:hover .post-card__media::after { transform: scale(1.08); }
.post-card__body { padding: 16px 18px 20px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.post-card__meta { display: flex; flex-wrap: wrap; gap: 6px; font-size: 12.5px; color: var(--muted); }
.post-card__meta a:hover { color: var(--accent); }
.post-card__title { font-size: 19px; line-height: 1.28; margin: 0; }
.post-card__title a:hover { color: var(--accent); }
.post-card__excerpt { font-size: 14.5px; color: var(--ink-2); margin: 0; }

.blog-empty { text-align: center; padding: 56px 20px 70px; border: 1px dashed var(--line-2); border-radius: var(--r-lg); }
.blog-empty__icon { width: 64px; height: 64px; margin: 0 auto 16px; }
.blog-empty h2 { font-size: 24px; margin-bottom: 8px; }
.blog-empty p { margin-bottom: 22px; }

.navigation.pagination { margin-top: 40px; }
.navigation.pagination .nav-links { display: flex; justify-content: center; gap: 6px; flex-wrap: wrap; }
.navigation.pagination .page-numbers {
    min-width: 42px; height: 42px; padding: 0 12px; display: inline-grid; place-items: center;
    border: 1px solid var(--line-2); border-radius: var(--r-pill); font-weight: 600; font-size: 14px;
}
.navigation.pagination .page-numbers.current { background: var(--ink); border-color: var(--ink); color: #fff; }
.navigation.pagination a.page-numbers:hover { border-color: var(--accent); color: var(--accent); }
.sr-only { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* Запись блога */
.container--narrow { max-width: 860px; }
.post-single { padding: 34px 0 20px; }
.post-single__head { margin: 10px 0 26px; }
.post-single__meta { display: flex; flex-wrap: wrap; gap: 8px; font-size: 13.5px; color: var(--muted); margin-bottom: 12px; }
.post-single__meta a:hover { color: var(--accent); }
.post-single__title { font-size: clamp(30px, 3.6vw, 46px); line-height: 1.1; }
.post-single__lead { font-size: 18px; color: var(--ink-2); margin-top: 14px; }
.post-single__cover { margin: 0 0 30px; border-radius: var(--r-lg); overflow: hidden; }
.post-single__cover img { width: 100%; height: auto; }
.post-single__content { max-width: none; font-size: 17px; line-height: 1.7; }
.post-single__content > * + * { margin-top: 0; }
.post-single__content img { border-radius: 14px; height: auto; }
.post-single__content figure { margin: 26px 0; }
.post-single__content figcaption { font-size: 13.5px; color: var(--muted); text-align: center; margin-top: 8px; }
.post-single__content blockquote, .post-single__content .wp-block-quote {
    margin: 26px 0; padding: 6px 0 6px 22px; border-left: 3px solid var(--accent);
    font-family: var(--font-display); font-size: 21px; line-height: 1.4; color: var(--ink);
}
.post-single__content blockquote cite { display: block; margin-top: 8px; font-family: var(--font-body); font-size: 14px; color: var(--muted); font-style: normal; }
.post-single__content .wp-block-gallery { gap: 10px; }
.post-single__content .wp-block-gallery img { border-radius: 10px; }
.post-single__content .alignwide { margin-left: -40px; margin-right: -40px; max-width: none; }
.post-single__content .wp-block-button__link { background: var(--accent); color: #fff; text-decoration: none; border-radius: var(--r-pill); padding: 12px 24px; }
.post-single__foot { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 16px; margin: 34px 0 0; padding: 22px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.post-single__tags { display: flex; flex-wrap: wrap; gap: 8px; }
.post-share { display: flex; align-items: center; gap: 6px; margin-left: auto; }
.post-share__label { font-size: 14px; color: var(--muted); margin-right: 4px; }
.post-share__btn {
    width: 40px; height: 40px; display: grid; place-items: center; border-radius: 50%;
    border: 1px solid var(--line-2); background: #fff; cursor: pointer; color: var(--ink); transition: .18s;
}
.post-share__btn:hover, .post-share__btn.is-copied { border-color: var(--accent); color: var(--accent); }
.post-share__btn svg { width: 18px; height: 18px; }
.post-nav { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin: 26px 0 0; }
.post-nav__link { display: flex; flex-direction: column; gap: 4px; padding: 16px 18px; border: 1px solid var(--line); border-radius: var(--r-card); transition: border-color .18s; }
.post-nav__link:hover { border-color: var(--accent); }
.post-nav__link span { font-size: 13px; color: var(--muted); }
.post-nav__link strong { font-weight: 600; line-height: 1.35; }
.post-nav__link--next { text-align: right; grid-column: 2; }

/* Встроенные видео и посты (YouTube, Rutube, VK, Telegram) */
.video-embed, .wp-block-embed.wp-has-aspect-ratio .wp-block-embed__wrapper {
    position: relative; aspect-ratio: 16 / 9; border-radius: 14px; overflow: hidden; background: #111; margin: 26px 0;
}
.wp-block-embed.wp-has-aspect-ratio .wp-block-embed__wrapper::before { display: none; }
.video-embed iframe, .video-embed video, .wp-block-embed.wp-has-aspect-ratio iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.wp-block-embed { margin: 26px 0; }
.wp-block-embed .video-embed { margin: 0; }
.wp-block-video video { width: 100%; border-radius: 14px; }
.tg-embed { margin: 26px auto; max-width: 560px; }
.tg-embed iframe { width: 100% !important; }

@media (max-width: 1023px) {
    .posts { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
    .post-single__content .alignwide { margin-left: 0; margin-right: 0; }
}
@media (max-width: 767px) {
    .posts { grid-template-columns: 1fr; gap: 16px; }
    .mockup { border-radius: 16px; }
    .post-single { padding-top: 22px; }
    .post-single__content { font-size: 16px; }
    .post-share { margin-left: 0; }
    .post-nav { grid-template-columns: 1fr; }
    .post-nav__link--next { grid-column: 1; }
}

/* ==================================================================
   17. Страница «Условия доставки» (1.3.0)
   ================================================================== */
.steps--delivery { margin: 14px 0 44px; }
.delivery-h2 { margin: 0 0 16px; }
.delivery-table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--r-card); max-width: 860px; }
.delivery-table { width: 100%; border-collapse: collapse; font-size: 15px; }
.delivery-table th { text-align: left; padding: 14px 18px; font-size: 12.5px; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); background: var(--soft); font-weight: 600; }
.delivery-table td { padding: 14px 18px; border-top: 1px solid var(--line); vertical-align: top; }
.delivery-table td:last-child { white-space: nowrap; font-weight: 600; }
.delivery-note { margin: 16px 0 0; padding: 14px 18px; max-width: 860px; background: var(--accent-soft); border-radius: var(--r); font-size: 15px; }
.delivery-terms { margin-top: 40px; }
.delivery-terms h2:first-child { margin-top: 0; }
@media (max-width: 767px) {
    .delivery-table th, .delivery-table td { padding: 12px 12px; }
    .delivery-table td:last-child { white-space: normal; }
    .delivery-terms { margin-top: 28px; }
}
