:root {
    /* Belmotors.by — светлая витрина как оригинал: белый / cyan / красный акцент */
    --bg: #f5f7fa;
    --card: #fff;
    --text: #1c2430;
    --muted: #6b7582;
    --accent: #00a8e8;
    --accent-dark: #0088c2;
    --line: #e2e8f0;
    --header: #ffffff;
    --header-2: #f3f5f8;
    --badge: #00a8e8;
    --badge-hot: #e30613;
    --font: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", sans-serif;
}

html {
    font-size: 17px;
    /* Safari iOS: не даём странице уезжать вбок из‑за off-screen / wide children */
    overflow-x: hidden;
}
* { box-sizing: border-box; }
body {
    margin: 0;
    font-family: var(--font);
    font-size: 1rem;
    line-height: 1.45;
    color: var(--text);
    background: linear-gradient(180deg, #e4eaf1 0%, var(--bg) 220px);
    min-height: 100vh;
    max-width: 100%;
    overflow-x: hidden;
}
body.is-menu-open {
    position: fixed;
    left: 0; right: 0;
    width: 100%;
    overflow: hidden;
}
a { color: var(--accent-dark); text-decoration: none; }
a:hover { text-decoration: underline; }
.container { width: min(1180px, calc(100% - 24px)); margin: 0 auto; }

.site-header {
    background: var(--header); color: var(--text);
    position: relative; z-index: 40;
    border-bottom: 1px solid var(--line);
    box-shadow: 0 4px 18px -10px rgba(15, 23, 42, 0.08);
}
.top-menu {
    background: #f8fafc;
    border-bottom: 1px solid var(--line);
    font-size: 0.86rem;
}
.top-menu-inner {
    display: flex; flex-wrap: wrap; gap: 8px 16px;
    padding: 10px 0; align-items: center; justify-content: space-between;
}
.top-menu-links {
    display: flex; flex-wrap: wrap; gap: 6px 32px; align-items: center; min-width: 0;
}
.top-menu-links a {
    color: #64748b; text-decoration: none; font-weight: 500;
    transition: color .18s ease;
}
.top-menu-links a:hover { color: var(--accent-dark); text-decoration: none; }
.top-menu-social {
    display: inline-flex; align-items: center; gap: 8px; margin-left: auto; flex-shrink: 0;
}
.top-menu-social-label {
    color: #64748b; font-weight: 600; font-size: 0.82rem; white-space: nowrap;
}
.soc-icon {
    display: inline-flex; align-items: center; justify-content: center;
    width: 28px; height: 28px; border-radius: 50%;
    background: var(--soc-color, var(--accent)); color: #fff !important;
    text-decoration: none !important; transition: transform .15s ease, opacity .15s ease;
    box-sizing: border-box;
}
.soc-icon:hover { transform: translateY(-1px); opacity: .92; text-decoration: none !important; }
.soc-icon svg { display: block; }
.soc-icon--avito {
    background: #fff !important;
    border: 1.5px solid #c5cad3;
    color: #334155 !important;
}
.soc-icon--avito:hover { opacity: 1; border-color: #94a3b8; }
.header-top {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    gap: 14px;
    align-items: center;
    justify-items: stretch;
    padding: 16px 0;
}
.logo {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--text); font-weight: 800; font-size: 1.4rem; letter-spacing: .02em;
    text-decoration: none; white-space: nowrap;
}
.logo:hover { text-decoration: none; color: var(--text); }
.logo-img {
    display: block;
    height: 48px;
    width: auto;
    max-width: min(240px, 52vw);
}
.logo-icon {
    display: block;
    width: 1.15em;
    height: 1.15em;
    flex-shrink: 0;
}
.logo-text { display: inline; }
.logo-mark {
    background-image:
        linear-gradient(
            100deg,
            transparent 0%,
            transparent 44%,
            rgba(255, 255, 255, .92) 50%,
            transparent 56%,
            transparent 100%
        ),
        linear-gradient(105deg, #7ec4ff 0%, #00a8e8 48%, #2ad4c8 100%);
    background-size: 220% 100%, 100% 100%;
    background-position: 100% 50%, 0 50%;
    background-repeat: no-repeat;
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    -webkit-text-fill-color: transparent;
    animation: logo-shine 7.5s ease-in-out infinite;
}
.header-locs {
    display: flex; flex-wrap: wrap; justify-content: flex-end; align-items: flex-end;
    gap: 4px 16px;
}
.header-locs--multi { max-width: none; }
.hc-loc {
    display: flex; flex-direction: column; align-items: flex-end; gap: 2px; line-height: 1.2;
}
.hc-loc-head {
    display: flex; align-items: center; justify-content: flex-end; gap: 8px;
}
.hc-loc-title {
    font-size: 0.78rem; font-weight: 700; color: var(--muted); white-space: nowrap;
}
.hc-loc-phones {
    display: flex; flex-direction: column; align-items: flex-end; gap: 0;
}
.hc-loc-phones .phone,
.hc-loc-phones .phone-extra {
    color: var(--text) !important; font-weight: 700; font-size: 0.98rem; white-space: nowrap;
    letter-spacing: -0.01em; text-decoration: none; line-height: 1.25;
}
.hc-loc-phones .phone:hover,
.hc-loc-phones .phone-extra:hover { color: var(--accent-dark) !important; }
.hc-messengers { display: inline-flex; align-items: center; gap: 4px; }
.hc-msg {
    display: inline-flex; align-items: center; justify-content: center;
    width: 22px; height: 22px; border-radius: 50%; color: #fff !important;
    text-decoration: none !important;
}
.hc-msg--telegram { background: #2AABEE; }
.hc-msg--viber { background: #7360F2; }
.hc-msg--whatsapp { background: #25D366; }
.hc-msg svg { width: 12px; height: 12px; display: block; }
.hc-hours {
    color: var(--muted); font-size: 0.75rem; line-height: 1.25;
    text-align: right; margin-top: 1px; white-space: nowrap;
}
.logo:hover .logo-mark,
.footer-title .logo-mark {
    color: transparent;
    -webkit-text-fill-color: transparent;
}
@keyframes logo-shine {
    /* и старт, и финиш — блик за краем текста, сброс цикла незаметен */
    0%, 70% { background-position: 100% 50%, 0 50%; }
    85%, 100% { background-position: 0% 50%, 0 50%; }
}
@media (prefers-reduced-motion: reduce) {
    .logo-mark { animation: none; }
}

.header-mid { display: flex; align-items: center; gap: 10px; min-width: 0; width: 100%; }
.catalog-wrap { position: static; flex-shrink: 0; }
.catalog-btn {
    background: var(--accent); color: #fff; border: 0; border-radius: 8px;
    padding: 11px 18px; font-weight: 700; cursor: pointer; font-size: 0.95rem; font-family: inherit;
    transition: background-color .18s ease, box-shadow .18s ease;
    box-shadow: 0 4px 12px rgba(0, 168, 232, 0.28);
}
.catalog-btn:hover, .catalog-btn[aria-expanded="true"] {
    background: var(--accent-dark); box-shadow: 0 6px 16px rgba(0, 136, 194, 0.28);
}
.catalog-btn--icon { display: none; }
.icon-btn {
    display: none;
    align-items: center; justify-content: center;
    width: 42px; height: 42px; padding: 0;
    border: 0; border-radius: 8px;
    background: var(--accent); color: #fff; cursor: pointer;
}
.icon-btn:hover, .icon-btn[aria-expanded="true"] { background: var(--accent-dark); }
.search-toggle { display: none; }

.catalog-panel {
    position: fixed;
    left: 0; right: 0;
    width: 100%;
    background: rgba(10, 14, 22, .4);
    color: var(--text);
    border: 0; border-radius: 0;
    box-shadow: none;
    z-index: 50;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    cursor: pointer;
}
.catalog-panel[hidden] { display: none !important; }
.catalog-panel-bar {
    display: none;
    align-items: center; justify-content: space-between;
    padding: 10px 14px; border-bottom: 1px solid var(--line);
    background: #f7f9fb; flex-shrink: 0;
}
.catalog-close {
    border: 0; background: transparent; font-size: 1.6rem; line-height: 1;
    cursor: pointer; color: var(--muted); padding: 0 4px;
}
.catalog-panel-inner {
    display: grid; grid-template-columns: 290px 1fr;
    flex: 1 1 auto;
    min-height: 0;
    width: min(1180px, calc(100% - 24px));
    margin: 0 auto;
    height: 100%;
    max-height: 100%;
    background: #fff;
    border-radius: 0 0 8px 8px;
    box-shadow: 0 16px 40px rgba(20, 30, 45, .22);
    overflow: hidden;
    cursor: default;
}
.catalog-groups {
    overflow: auto; border-right: 1px solid var(--line); padding: 8px;
    background: #f7f9fb; min-height: 0;
}
.catalog-all, .catalog-group {
    display: flex; align-items: center; justify-content: space-between; gap: 8px;
    width: 100%; text-align: left;
    border: 0; background: transparent; padding: 7px 10px; border-radius: 5px;
    font: inherit; color: var(--text); cursor: pointer; text-decoration: none;
    white-space: nowrap; line-height: 1.25;
}
.catalog-all { font-weight: 700; color: var(--accent-dark); }
.catalog-group::after {
    content: ">";
    flex-shrink: 0;
    font-size: 0.95em;
    line-height: 1;
    color: var(--muted);
    font-weight: 400;
}
.catalog-group:hover, .catalog-group.is-active { background: #e8eef8; text-decoration: none; }
.catalog-group:hover::after, .catalog-group.is-active::after { color: var(--accent-dark); }
.catalog-types {
    display: flex; flex-direction: column;
    overflow: hidden; padding: 0; min-height: 0; background: #fff;
}
.catalog-types-hint { color: var(--muted); margin: 12px 14px; font-size: 0.95rem; }
.catalog-types-top {
    flex-shrink: 0;
    position: sticky; top: 0; z-index: 2;
    background: #fff;
    padding: 12px 14px 10px;
    border-bottom: 1px solid var(--line);
}
.catalog-types-head { margin: 0 0 10px; font-size: 1rem; }
.catalog-types-back {
    display: none; border: 0; background: transparent; color: var(--accent-dark);
    font: inherit; cursor: pointer; padding: 0; margin: 0 0 10px;
}
.catalog-list-filter {
    width: 100%; margin: 0; padding: 8px 10px;
    border: 1px solid var(--line); border-radius: 6px; font: inherit;
    box-sizing: border-box;
}
.catalog-types-list {
    flex: 1 1 auto;
    overflow: auto;
    min-height: 0;
    padding: 8px 14px 12px;
    display: flex;
    flex-direction: column;
    gap: 26px;
}
.catalog-types-list .marks-letter-row {
    display: grid;
    grid-template-columns: repeat(var(--marks-cols, 3), minmax(0, 1fr));
    gap: 0 24px;
    align-items: start;
}
.catalog-types-list .catalog-types-letter-block {
    margin: 0;
}
.catalog-types-list .marks-letter-list a:hover { color: var(--accent-dark); }

.search-form {
    display: flex; align-items: center; gap: 2px; flex: 1; min-width: 0;
    height: 42px; box-sizing: border-box;
    background: #f1f5f9; border: 1.5px solid var(--line); border-radius: 10px; padding: 2px 2px 2px 4px;
    transition: background-color .18s ease, border-color .18s ease, box-shadow .18s ease;
}
.search-form:focus-within {
    background: #fff; border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(0, 168, 232, 0.18);
}
.search-suggest-wrap { position: relative; flex: 1; min-width: 0; display: flex; height: 100%; }
.search-form input {
    flex: 1; height: 100%; padding: 0 12px; border: 0; border-radius: 8px; font-size: 0.95rem;
    min-width: 0; font-family: inherit; width: 100%; background: transparent; box-sizing: border-box;
}
.search-form input:focus { outline: none; }
.search-suggest {
    position: absolute;
    left: 0; right: 0; top: calc(100% + 4px);
    z-index: 80;
    background: #fff;
    border: 1px solid var(--border, #d8dee8);
    border-radius: 8px;
    box-shadow: 0 10px 28px rgba(20, 40, 80, 0.14);
    max-height: min(80vh, 560px);
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}
.search-suggest-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 10px;
    color: var(--text);
    text-decoration: none !important;
    border-bottom: 1px solid #eef1f6;
}
.search-suggest-item:last-child { border-bottom: 0; }
.search-suggest-item:hover,
.search-suggest-item.is-active {
    background: #f3f6fb;
}
.search-suggest-photo {
    width: 40px; height: 40px; object-fit: cover; border-radius: 4px; flex-shrink: 0; background: #e8edf5;
}
.search-suggest-photo.is-empty { display: inline-block; }
.search-suggest-body { min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.search-suggest-title {
    font-size: 0.88rem; line-height: 1.3;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.search-suggest-meta { font-size: 0.78rem; color: #6b7a90; }
.btn {
    background: var(--accent); color: #fff; border: 0; border-radius: 6px;
    padding: 10px 16px; cursor: pointer; font-weight: 600; display: inline-block; font-family: inherit; font-size: 1rem;
}
.btn:hover { background: var(--accent-dark); text-decoration: none; color: #fff; }
.search-form .search-submit {
    flex: 0 0 38px; width: 38px; height: 36px; padding: 0; margin: 0;
    display: inline-flex; align-items: center; justify-content: center;
    background: var(--accent); color: #fff; border: 0; border-radius: 8px;
    box-shadow: none; cursor: pointer; position: relative;
}
.search-form .search-submit:hover { background: var(--accent-dark); color: #fff; }
.search-form .search-submit svg { display: block; }
.search-form .search-submit-text {
    position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
    overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}
.btn-sm { padding: 8px 12px; font-size: 0.9rem; width: 100%; text-align: center; }
.btn.is-in-cart {
    background: #8b95a5; color: #fff;
    cursor: pointer;
}
.btn.is-in-cart:hover {
    background: #6f7a8b; color: #fff; text-decoration: none;
}
.cart-price-cell { white-space: nowrap; text-align: right; vertical-align: middle; }
.cart-price-row { display: inline-flex; align-items: center; gap: 6px; }
.cart-price-value { white-space: nowrap; }
.cart-remove {
    display: inline-flex; align-items: center; justify-content: center;
    color: #c62828; font-size: 1.35rem; font-weight: 700; line-height: 1;
    text-decoration: none !important; padding: 0 2px;
}
.cart-remove:hover { color: #8a1c14; }

.header-contacts {
    text-align: right; font-size: 0.95rem;
    display: flex; flex-direction: row; align-items: center; justify-content: flex-end;
    gap: 14px; flex-shrink: 0;
}
.header-contacts a { color: var(--text); }
.header-contacts .cart-link { flex-shrink: 0; align-self: center; }
.cart-link {
    display: inline-flex; align-items: center; gap: 8px; position: relative;
    color: var(--text) !important; font-weight: 700; text-decoration: none !important;
    background: #fff; border: 1.5px solid var(--line);
    padding: 8px 14px; border-radius: 10px;
    transition: border-color .18s ease, background-color .18s ease, box-shadow .18s ease;
}
.cart-link-icon { display: none; flex-shrink: 0; }
.cart-link:hover {
    border-color: var(--accent); background: #e8f7fc;
    text-decoration: none !important; box-shadow: 0 2px 10px rgba(0, 168, 232, 0.15);
}
.cart-link:hover .cart-link-text { text-decoration: none; }
.cart-badge {
    display: inline-flex; align-items: center; justify-content: center;
    min-width: 1.4em; height: 1.4em; padding: 0 6px;
    border-radius: 999px; background: var(--badge); color: #fff;
    font-size: 0.8rem; font-weight: 800; line-height: 1;
    text-decoration: none !important;
}
.cart-badge.is-empty { display: none; }

.quick-links {
    background: #f3f5f8;
    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
}
.quick-links .container {
    display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center;
    gap: 8px 18px; padding: 18px 0; font-size: 1.02rem;
    text-transform: none; letter-spacing: 0;
}
.quick-links a {
    color: #334155; font-weight: 600;
    text-decoration: none !important;
    padding: 4px 2px;
    transition: color .18s ease;
}
.quick-links a:hover { color: var(--accent-dark); text-decoration: none !important; }

.main { padding: 32px 0 48px; }
.product-heading > h1 { margin: 0; line-height: 1.25; font-size: clamp(1.35rem, 2.2vw, 1.75rem); }
.product-heading .meta {
    color: var(--muted); margin: 8px 0 0; font-size: 0.95rem; line-height: 1.4;
}
.hero {
    background:
        radial-gradient(circle at 92% 10%, rgba(0, 168, 232, 0.16), transparent 42%),
        linear-gradient(135deg, #f0f9fd 0%, #ffffff 55%, #f8fafc 100%);
    color: var(--text);
    border-radius: 16px; padding: 32px 28px; margin-bottom: 24px;
    border: 1px solid #cfeef9;
}
.hero-badge {
    display: inline-block; margin-bottom: 12px;
    padding: 5px 12px; border-radius: 999px; font-size: 0.78rem; font-weight: 800;
    color: var(--accent-dark); background: #e8f7fc; border: 1px solid #b8e4f5;
}
.hero h1 { margin: 0 0 10px; font-size: clamp(1.65rem, 3vw, 2.2rem); line-height: 1.2; color: var(--text); }
.hero p { color: #475569; margin: 0; max-width: 720px; }
.hero .btn { display: inline-block; margin-top: 12px; }

.section h1, .section h2 { margin-top: 0; }
.section h1 { line-height: 1.2; }
.section-head {
    display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between;
    gap: 8px 16px; margin-bottom: 14px;
}
.section-head h2 { margin: 0; }
.section-more { color: var(--accent, #2f6fed); text-decoration: none; font-size: 0.95rem; white-space: nowrap; }
.section-more:hover { text-decoration: underline; }
.muted { color: var(--muted); }

.marks-section { margin-bottom: 28px; }
.marks-alpha {
    column-count: 5;
    column-gap: 28px;
}
.marks-alpha--compact { column-count: 4; }
.marks-letter-block {
    break-inside: avoid;
    display: grid;
    grid-template-columns: 1.6rem 1fr;
    gap: 4px 10px;
    margin: 0 0 14px;
    align-items: start;
}
.marks-letter {
    font-weight: 800; font-size: 1.35rem; line-height: 1.2; color: #9da8b7;
}
.marks-letter-list {
    display: flex; flex-direction: column; gap: 8px;
    margin-top: 2px;
}
.marks-letter-list a {
    color: var(--text); font-size: 0.95rem; line-height: 1.35;
}
.marks-letter-list a:hover { color: var(--accent-dark); }
.popular-marks {
    margin-top: 36px; padding-top: 24px; border-top: 1px solid var(--line);
}
.popular-marks h2 { margin: 0 0 14px; font-size: 1.2rem; }

.related-parts {
    margin-top: 28px; padding-top: 24px; border-top: 1px solid var(--line);
}
.related-parts h2 { margin: 0 0 16px; font-size: 1.2rem; }
.donor-parts-title { font-weight: 700; line-height: 1.35; }
.donor-parts-all {
    color: var(--accent-dark);
    font-weight: 400;
    text-decoration: underline;
}
.donor-parts-all:hover { color: var(--accent); }
.related-parts-group { margin: 0 0 18px; }
.related-parts-group + .related-parts-group { margin-top: 40px; }
.related-parts-group:last-child { margin-bottom: 0; }
.related-parts-group h3 {
    margin: 0 0 8px; font-size: 0.95rem; font-weight: 600;
    color: var(--muted); text-transform: none; letter-spacing: 0;
}
.related-parts-list {
    column-count: 3;
    column-gap: 28px;
}
.related-parts-list a {
    display: block;
    break-inside: avoid;
    padding: 3px 0;
    color: var(--text);
    text-decoration: none;
}
.related-parts-list a:hover { color: var(--accent-dark); text-decoration: underline; }
.related-parts-list .muted { font-weight: 400; }
.donor-filter-note {
    margin: -8px 0 16px;
    font-size: 0.95rem;
}

.home-search {
    background: var(--card); border: 1px solid var(--line); border-radius: 8px;
    padding: 16px; margin: 0 0 24px;
}
.home-search-row {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
    margin-bottom: 12px;
    align-items: end;
}
.home-search label { display: grid; gap: 4px; font-size: 0.9rem; color: var(--muted); }
.home-search select, .home-search input {
    padding: 8px 10px; border: 1px solid var(--line); border-radius: 6px;
    font: inherit; color: var(--text); background-color: #fff; width: 100%;
}
.home-search select:disabled:not(.combo-native) {
    color: var(--muted);
    -webkit-text-fill-color: var(--muted);
    background-color: #f5f7fa;
    cursor: not-allowed;
    opacity: 1;
}
.home-search .combo { min-width: 0; width: 100%; }
.home-search .combo-filter {
    width: calc(100% - 16px);
    min-width: 0;
    max-width: calc(100% - 16px);
}
.home-search-actions {
    display: flex; flex-wrap: wrap; gap: 10px 14px; align-items: center;
    padding-bottom: 2px;
}
.home-search-more { margin-top: 4px; }
.home-search-more > summary {
    cursor: pointer; color: var(--accent-dark); list-style: none;
    text-decoration: underline; text-decoration-style: dashed; text-underline-offset: 3px;
    font-size: 0.95rem; margin-bottom: 10px;
}
.home-search-more > summary::-webkit-details-marker { display: none; }

/* До initCombos: убрать системную стрелку select, тот же шеврон что у combo */
select[data-searchable]:not(.combo-native) {
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    padding-right: 28px;
    background-color: #fff;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath fill='%236b7582' d='M0 0h10L5 6z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 10px center;
    background-size: 10px 6px;
}
select[data-searchable]:not(.combo-native)::-ms-expand { display: none; }

/* Searchable combo */
.combo { position: relative; min-width: 0; }
.combo-trigger {
    width: 100%; text-align: left; padding: 8px 28px 8px 10px; border: 1px solid var(--line);
    border-radius: 6px; background-color: #fff; font: inherit; color: var(--text); cursor: pointer;
    position: relative; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
    box-sizing: border-box;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath fill='%236b7582' d='M0 0h10L5 6z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 10px center;
    background-size: 10px 6px;
}
/* Зависимые селекты («Сначала марка» и т.п.) — визуально неактивные */
.combo.is-disabled .combo-trigger,
.combo.is-disabled .combo-trigger:disabled {
    color: var(--muted);
    background-color: #f5f7fa;
    cursor: not-allowed;
    opacity: 1;
}
.combo.is-open .combo-trigger {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath fill='%236b7582' d='M5 0l5 6H0z'/%3E%3C/svg%3E");
}
.combo.is-loading .combo-trigger {
    color: var(--muted);
    background-color: #f5f7fa;
    background-image: none;
    cursor: wait;
}
.combo.is-loading .combo-trigger::after {
    content: '';
    position: absolute; right: 10px; top: 50%;
    width: 12px; height: 12px; margin-top: -6px;
    border: 2px solid #c5d0e0;
    border-top-color: var(--accent);
    border-radius: 50%;
    box-sizing: border-box;
    animation: facet-spin .55s linear infinite;
}
select.is-loading {
    color: var(--muted);
    background: #f5f7fa;
    cursor: wait;
}
@keyframes facet-spin {
    to { transform: rotate(360deg); }
}
.combo-drop {
    position: absolute; left: 0; top: calc(100% + 4px); z-index: 60;
    min-width: 100%; width: 100%;
    box-sizing: border-box;
    background: #fff; border: 1px solid var(--line); border-radius: 6px;
    box-shadow: 0 10px 28px rgba(20,30,45,.16);
    max-height: min(70vh, 560px);
    display: flex; flex-direction: column; overflow: hidden;
}
.combo-drop[hidden] { display: none !important; }
.combo-filter {
    display: block;
    margin: 8px;
    padding: 8px 10px;
    border: 1px solid var(--line);
    border-radius: 6px;
    font: inherit;
    box-sizing: border-box;
    width: calc(100% - 16px);
    min-width: 0;
    max-width: calc(100% - 16px);
    flex-shrink: 0;
}
.combo-list {
    list-style: none; margin: 0; padding: 0 0 8px;
    overflow: auto; flex: 1 1 auto; min-height: 0;
}
.combo-list li button {
    display: block; width: 100%; text-align: left; border: 0; background: transparent;
    padding: 9px 12px; font: inherit; font-size: 0.95rem; cursor: pointer; color: var(--text);
    white-space: normal; line-height: 1.35;
}
.combo-list li button:hover, .combo-list li button.is-active { background: #e8eef8; }
.combo-list li.is-hidden { display: none; }
.combo select.combo-native,
.combo select.combo-native:disabled {
    position: absolute; opacity: 0; pointer-events: none;
    width: 1px; height: 1px; min-width: 0; padding: 0; border: 0;
    background: transparent; -webkit-text-fill-color: transparent;
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
    align-items: stretch;
}
.product-card {
    background: var(--card); border: 1px solid var(--line); border-radius: 16px; overflow: hidden;
    display: flex; flex-direction: column; height: 100%;
    box-shadow: 0 2px 12px -4px rgba(15, 23, 42, 0.08);
    transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.product-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 14px 28px -10px rgba(15, 23, 42, 0.14);
    border-color: #b8e4f5;
}
.product-card-img {
    display: block; aspect-ratio: 4/3; background: #f1f5f9; position: relative; flex-shrink: 0;
    margin: 12px 12px 0; border-radius: 12px; overflow: hidden; border: 1px solid #eef2f6;
}
.product-card-img img { width: 100%; height: 100%; object-fit: cover; }
.no-photo {
    display: grid; place-items: center; width: 100%; height: 100%; color: var(--muted); font-size: 0.9rem;
}
.no-photo.big { min-height: 280px; background: #f1f5f9; border-radius: 10px; }
.product-card-body {
    padding: 14px 16px 16px; display: flex; flex-direction: column; gap: 8px; flex: 1 1 auto;
}
.product-card-body .title {
    font-weight: 700; color: var(--text); line-height: 1.35; font-size: 1.02rem;
    text-decoration: none;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.product-card-body .title:hover { color: var(--accent-dark); text-decoration: none; }
.product-card-body .meta {
    color: #475569; font-size: 0.8rem; margin: 0; line-height: 1.35; font-weight: 600;
    background: #f8fafc; border: 1px solid #eef2f6; padding: 4px 10px; border-radius: 999px;
    align-self: flex-start;
    display: -webkit-box; -webkit-line-clamp: 1; -webkit-box-orient: vertical; overflow: hidden;
}
.product-card-foot {
    margin-top: auto; padding-top: 12px; border-top: 1px dashed var(--line);
    display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px;
}
.product-card-foot .price { margin: 0; font-size: 1.22rem; font-weight: 900; letter-spacing: -0.02em; }
.product-card-foot .btn { margin-top: 0; width: auto; padding: 9px 16px; border-radius: 10px; }
.price { color: var(--text); font-weight: 800; font-size: 1.08rem; }
.price.big { font-size: 1.7rem; letter-spacing: -0.02em; }

.filters {
    display: flex; flex-direction: column; gap: 12px;
    background: var(--card); border: 1px solid var(--line); border-radius: 8px;
    padding: 14px; margin: 16px 0 20px;
}
.filters-row {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
    align-items: end;
}
.filters label { display: grid; gap: 4px; font-size: 0.9rem; color: var(--muted); min-width: 0; }
.filters select, .filters input {
    padding: 8px 10px; border: 1px solid var(--line); border-radius: 6px;
    font: inherit; color: var(--text); background-color: #fff; width: 100%;
    box-sizing: border-box;
}
.filters .combo { min-width: 0; width: 100%; }
.filters select:disabled:not(.combo-native) {
    color: var(--muted);
    -webkit-text-fill-color: var(--muted);
    background-color: #f5f7fa;
    cursor: not-allowed;
    opacity: 1;
}
.filters label:has(select[name="tip"]) .combo-drop {
    width: max(100%, min(340px, calc(100vw - 28px)));
    max-width: calc(100vw - 28px);
}
.filters-actions {
    display: flex; flex-wrap: wrap; gap: 10px 14px; align-items: center;
    padding-bottom: 2px;
}
.filters-more { margin-top: 0; }
.filters-disk-block {
    margin-top: 14px;
    padding: 12px 14px 10px;
    border: 1px solid #c5d4ea;
    border-radius: 8px;
    background: linear-gradient(180deg, #f3f7fc 0%, #eef3fa 100%);
}
.filters-disk-heading {
    font-size: 0.95rem;
    font-weight: 700;
    color: var(--text);
    margin: 0 0 10px;
}
.filters-disk-block .filters-more { margin-top: 8px; }
.filters-disk-block .filters-more > summary { color: var(--accent-dark); }
.filters-more > summary {
    cursor: pointer; color: var(--accent-dark); list-style: none;
    text-decoration: underline; text-decoration-style: dashed; text-underline-offset: 3px;
    font-size: 0.95rem; margin-bottom: 10px;
}
.filters-more > summary::-webkit-details-marker { display: none; }
.filters-more[open] > summary { margin-bottom: 12px; }
.filters-more .filters-row {
    grid-template-columns: repeat(4, minmax(0, 1fr));
}
@media (min-width: 700px) {
    .combo-drop {
        width: max(100%, 280px);
        max-width: min(400px, calc(100vw - 32px));
    }
}
@media (max-width: 899px) {
    .filters-row,
    .filters-more .filters-row {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .filters-actions { grid-column: 1 / -1; }
}
@media (max-width: 699px) {
    .filters-row,
    .filters-more .filters-row {
        grid-template-columns: 1fr;
    }
    /* На узком экране не шире поля — иначе уезжает за край (особенно «Модель» справа) */
    .filters .combo-drop {
        left: auto;
        right: 0;
        width: 100%;
        min-width: 100%;
        max-width: calc(100vw - 28px);
    }
    .filters label:has(select[name="tip"]) .combo-drop {
        width: 100%;
    }
    .filters-actions {
        flex-direction: column;
        align-items: stretch;
    }
    .filters-actions .btn { width: 100%; }
    .filter-reset { text-align: center; }
    .filters-more > summary,
    .home-search-more > summary { text-align: center; }
}
.filters .combo-filter {
    min-width: 0;
    width: calc(100% - 16px);
    max-width: calc(100% - 16px);
}
.filters .btn {
    align-self: flex-end;
}
.filter-reset {
    font-size: 0.95rem;
    color: var(--muted);
    text-decoration: underline;
    white-space: nowrap;
    line-height: 1.2;
}
.filter-reset:hover { color: var(--text); }

.pagination { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 20px; align-items: center; }
.pagination a {
    padding: 6px 10px; border: 1px solid var(--line); border-radius: 6px; background: #fff; color: var(--text);
}
.pagination a.active { background: var(--accent); color: #fff; border-color: var(--accent-dark); font-weight: 800; }
.pag-gap { color: var(--muted); padding: 0 4px; }

.product-page {
    display: grid;
    grid-template-columns: 1.1fr 1fr;
    grid-template-areas:
        "crumbs crumbs"
        "gallery title"
        "gallery info"
        "donor info";
    gap: 12px 28px;
    align-items: start;
}
.product-page > .breadcrumbs { grid-area: crumbs; margin: 0; }
.product-heading { grid-area: title; }
.product-gallery { grid-area: gallery; min-width: 0; }
.product-info { grid-area: info; }
.product-donor { grid-area: donor; }

.breadcrumbs {
    display: flex; flex-wrap: wrap; gap: 6px; align-items: center;
    font-size: 0.88rem; color: var(--muted); margin: 0 0 10px;
}
.breadcrumbs a { color: var(--muted); }
.breadcrumbs a:hover { color: var(--accent-dark); }
.bc-sep { opacity: .5; }

.product-main-img {
    width: 100%; height: auto; display: block; border-radius: 8px; background: #fff; border: 1px solid var(--line); cursor: zoom-in;
}
/* Одна лента превью: на мобиле видно «хвост» следующей фотки — ясно, что можно листать */
.thumbs {
    display: flex;
    flex-wrap: nowrap;
    gap: 8px;
    margin-top: 10px;
    max-width: 100%;
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior-x: contain;
    touch-action: pan-x;
    scrollbar-width: thin;
    padding-bottom: 2px;
}
.thumbs::-webkit-scrollbar { height: 4px; }
.thumbs::-webkit-scrollbar-thumb {
    background: #c5d0e0;
    border-radius: 4px;
}
.thumb {
    flex: 0 0 auto;
    border: 1px solid var(--line);
    padding: 0;
    background: #fff;
    cursor: pointer;
    border-radius: 6px;
}
.thumb.is-active { border-color: var(--accent); box-shadow: 0 0 0 2px rgba(47,111,237,.25); }
.thumb img { width: 64px; height: 48px; object-fit: cover; display: block; border-radius: 5px; }

.specs-plain {
    display: grid; gap: 6px; margin: 14px 0 10px; padding: 0;
}
.specs-plain > div {
    display: flex; flex-wrap: wrap; gap: 6px 8px; align-items: baseline;
}
.specs-plain dt { margin: 0; color: var(--muted); font-weight: 400; }
.specs-plain dd { margin: 0; color: var(--text); font-weight: 600; }
.specs-plain .donor-label { font-weight: 400; }
.specs-plain a {
    color: var(--accent-dark);
    font-weight: 400;
    text-decoration: underline;
}
.specs-plain a:hover { color: var(--accent); }
.donor-group {
    display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 8px;
    margin: 0 0 10px; font-size: 0.95rem;
}
.donor-group a {
    color: var(--accent-dark);
    font-weight: 400;
    text-decoration: underline;
}
.donor-group a:hover { color: var(--accent); }

.buy-row {
    display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px 32px;
    margin: 12px 0 18px; padding: 14px; background: var(--card);
    border: 1px solid var(--line); border-radius: 8px;
}
.buy-row .price.big { margin: 0; padding-right: 12px; }
.specs {
    display: grid; gap: 8px 12px; margin: 0;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
}
.specs:empty { display: none; }
.specs > div {
    background: #fff; border: 1px solid var(--line); border-radius: 6px; padding: 8px 10px;
}
.specs dt { margin: 0; font-size: 0.85rem; color: var(--muted); }
.specs dd { margin: 2px 0 0; font-weight: 600; }
/* Honeypot антиспама — без left:-10000px: в Safari iOS это даёт горизонтальный скролл страницы */
.field-hp {
    position: absolute !important;
    left: 0 !important;
    top: 0 !important;
    width: 0 !important;
    height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    clip-path: inset(50%) !important;
    border: 0 !important;
    opacity: 0 !important;
    pointer-events: none !important;
}

.quick-order-spoiler {
    margin-top: 4px;
}
.quick-order-spoiler > summary {
    cursor: pointer; color: var(--accent-dark); font-weight: 600; font-size: 1.05rem;
    list-style: none; text-decoration: underline; text-decoration-style: dashed;
    text-underline-offset: 4px; margin-bottom: 10px;
}
.quick-order-spoiler > summary::-webkit-details-marker { display: none; }
.quick-order {
    position: relative;
    margin-top: 0; padding: 16px; background: var(--card); border: 1px solid var(--line); border-radius: 8px;
    display: grid; gap: 12px; max-width: none; width: 100%;
}
.quick-order h2 { margin: 0; font-size: 1.15rem; }
.quick-order-opts {
    margin: 0; padding: 10px 12px; border: 1px solid var(--line); border-radius: 6px;
    display: grid; gap: 6px;
}
.quick-order-opts legend {
    padding: 0 4px; font-size: 0.9rem; font-weight: 600; color: var(--muted);
}
.quick-order-opt {
    display: flex; gap: 8px; align-items: flex-start; cursor: pointer;
    font-size: 0.95rem; line-height: 1.35;
}
.quick-order-opt input { margin-top: 3px; flex-shrink: 0; }
.quick-order .field { display: grid; gap: 5px; }
.quick-order .field span { font-size: 0.9rem; color: var(--muted); }
.quick-order input,
.quick-order textarea {
    width: 100%; padding: 10px 12px; border: 1px solid var(--line); border-radius: 6px;
    font: inherit; color: var(--text); background: #fff;
}
.quick-order .btn {
    width: 100%; padding: 16px 20px; font-size: 1.1rem; border-radius: 8px;
    letter-spacing: 0.01em;
}

.cart-table { width: 100%; border-collapse: collapse; background: #fff; }
.cart-table th, .cart-table td { border: 1px solid var(--line); padding: 10px; text-align: left; vertical-align: middle; }
.cart-table th:last-child,
.cart-table td:last-child { text-align: right; white-space: nowrap; }
.cart-table .cart-article {
    text-align: center;
    white-space: nowrap;
}
.cart-table td.cart-article {
    font-size: 0.85rem;
    color: var(--muted);
}
.cart-item-link {
    color: var(--text);
    text-decoration: underline;
    text-decoration-style: dashed;
    text-underline-offset: 3px;
    line-height: 1.35;
}
.cart-item-link:hover {
    color: var(--accent-dark);
    text-decoration-style: solid;
}
.cart-total {
    text-align: right;
    font-size: 1.55rem;
    font-weight: 700;
    margin: 16px 0 8px;
    color: var(--text);
}
.cart-total strong { font-weight: 800; }
.flash.ok { background: #e7f7ec; border: 1px solid #b7e0c2; padding: 10px 12px; border-radius: 6px; }
.flash.err { background: #fdecea; border: 1px solid #f5c2c0; padding: 10px 12px; border-radius: 6px; }

/* Admin bar (витрина, как в WordPress) — только для залогиненного админа */
.admin-bar {
    position: fixed;
    top: 0; left: 0; right: 0;
    z-index: 99999;
    height: 32px;
    background: #1d2327;
    color: #f0f0f1;
    font-size: 13px;
    line-height: 32px;
    border-bottom: 1px solid #2c3338;
}
.admin-bar-inner {
    display: flex;
    align-items: stretch;
    justify-content: space-between;
    height: 100%;
    max-width: 100%;
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: thin;
}
.admin-bar-menu {
    display: flex;
    align-items: stretch;
    list-style: none;
    margin: 0;
    padding: 0;
    flex-shrink: 0;
}
.admin-bar-menu--right { margin-left: auto; }
.admin-bar-item { margin: 0; padding: 0; }
.admin-bar-item a {
    display: block;
    padding: 0 10px;
    color: #c3c4c7;
    text-decoration: none;
    white-space: nowrap;
    font-weight: 500;
}
.admin-bar-item a:hover {
    background: #2c3338;
    color: #fff;
    text-decoration: none;
}
.admin-bar-item--site a {
    font-weight: 700;
    color: #fff;
}
.admin-bar-logo {
    letter-spacing: .02em;
}
.admin-bar-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 1.35em;
    height: 1.35em;
    padding: 0 5px;
    margin-left: 5px;
    border-radius: 999px;
    background: var(--badge);
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    line-height: 1;
    vertical-align: 1px;
}
body.has-admin-bar {
    padding-top: 32px;
}
body.has-admin-bar.is-menu-open {
    /* fixed body уже с top:-scroll; бар остаётся поверх */
    padding-top: 32px;
}

/* Баннер админу на витрине при сбое уведомлений о заказах */
.admin-front-alert {
    background: #7a1f1a;
    color: #fff;
    padding: 10px 16px;
    font-size: 0.9rem;
    line-height: 1.4;
    text-align: center;
}
.admin-front-alert a {
    color: #ffd5d0;
    font-weight: 600;
    text-decoration: underline;
}
.admin-front-alert a:hover { color: #fff; }

.checkout-form { margin-top: 20px; }
.checkout-form > h2 { margin: 0 0 14px; font-size: 1.25rem; }
.checkout-options {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
    margin-bottom: 16px;
}
.checkout-card {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 16px;
    box-shadow: 0 2px 10px rgba(20, 30, 45, .06);
}
.checkout-card h3 { margin: 0 0 6px; font-size: 1.1rem; }
.checkout-card-sub { margin: 0 0 22px; color: var(--muted); font-size: 0.9rem; line-height: 1.35; }
.checkout-card-label { margin: 0 0 8px; font-size: 0.85rem; color: var(--muted); font-weight: 600; }
.checkout-option {
    display: flex; gap: 10px; align-items: flex-start;
    padding: 10px 0; border-top: 1px solid var(--line);
    cursor: pointer; margin: 0;
}
.checkout-option:first-of-type { border-top: 0; padding-top: 0; }
.checkout-option input {
    margin-top: 3px; accent-color: var(--accent); flex-shrink: 0;
}
.checkout-option-body {
    display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 4px 12px; flex: 1; min-width: 0;
}
.checkout-option-text { color: var(--text); font-weight: 500; line-height: 1.35; }
.checkout-option-price { color: var(--muted); font-size: 0.95rem; white-space: nowrap; margin-left: auto; }
.checkout-option-note {
    flex-basis: 100%;
    color: var(--muted);
    font-size: 0.88rem;
    line-height: 1.35;
    text-align: left;
}
.checkout-fields {
    position: relative;
    background: var(--card); border: 1px solid var(--line); border-radius: 8px;
    padding: 16px; display: grid; gap: 12px;
}
.checkout-fields .field { display: grid; gap: 5px; }
.checkout-fields .field span { font-size: 0.9rem; color: var(--muted); }
.checkout-fields input,
.checkout-fields textarea {
    width: 100%; padding: 10px 12px; border: 1px solid var(--line); border-radius: 6px;
    font: inherit; color: var(--text); background: #fff;
}
.checkout-fields .btn {
    width: 100%; padding: 16px 20px; font-size: 1.1rem; border-radius: 8px;
    letter-spacing: 0.01em;
}

.static-page-body { max-width: 720px; line-height: 1.55; }
.static-page-body p { margin: 0 0 12px; }
.static-page-body h2, .static-page-body h3 { margin: 1.2em 0 0.5em; }
.static-page-body ul, .static-page-body ol { margin: 0 0 14px; padding-left: 1.25em; }
.static-page-body li { margin: 0 0 6px; }
.contacts-map-title { margin: 28px 0 12px; font-size: 1.25rem; font-weight: 700; }
.contacts-map {
    max-width: 100%;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #f3f5f8;
    min-height: 320px;
}
.contacts-map iframe,
.contacts-map > ymaps {
    display: block;
    width: 100%;
    max-width: 100%;
    border: 0;
    min-height: 420px;
    height: 420px;
}

.site-footer {
    background: #f8fafc;
    color: #475569;
    padding: 40px 0 22px;
    margin-top: auto;
    border-top: 3px solid var(--accent);
    box-shadow: 0 -6px 24px rgba(15, 23, 42, 0.03);
}
.footer-grid {
    display: grid;
    grid-template-columns: minmax(240px, 0.95fr) minmax(0, 1.5fr);
    gap: 28px 36px;
    align-items: start;
}
.footer-title {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin: 0 0 12px;
    color: var(--text);
    font-size: 1.05rem;
    font-weight: 800;
}
.footer-title .logo-img { height: 40px; }
.site-footer a { color: #334155; transition: color .18s ease; }
.site-footer a:hover { color: var(--accent-dark); }
.footer-social-row { margin-top: 18px; }
.footer-social { margin-top: 0; }
.footer-social-title {
    display: block; margin: 0 0 8px; font-size: 0.95rem; color: var(--text);
}
.footer-social-btns {
    display: flex; flex-wrap: wrap; align-items: center; gap: 8px;
}
.footer-soc-btn {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 5px 10px 5px 6px; border-radius: 999px;
    background: #fff; border: 1px solid var(--line);
    color: var(--text) !important; font-weight: 700; font-size: 0.8rem;
    text-decoration: none !important; white-space: nowrap; flex-shrink: 0;
}
.footer-soc-btn:hover {
    border-color: var(--accent); background: #e8f7fc; text-decoration: none !important;
}
.footer-soc-btn .soc-icon { width: 22px; height: 22px; flex-shrink: 0; }
.footer-cats-cols {
    display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px 16px; font-size: 0.92rem;
}
.footer-note {
    margin-top: 28px; padding-top: 16px;
    border-top: 1px solid var(--line);
    color: var(--muted); font-size: 0.84rem;
}
.footer-note-cols {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 24px 40px;
    font-size: inherit;
    line-height: 1.45;
}
.footer-note-col { flex: 1 1 0; min-width: 0; }
.footer-note-col--left { text-align: left; }
.footer-note-col--right { text-align: right; }
.footer-note-col a { text-decoration: underline; text-underline-offset: 2px; }
.footer-note-links { display: block; margin-top: 10px; }
@media (max-width: 720px) {
    .footer-note-cols { flex-direction: column; gap: 12px; }
    .footer-note-col--right { text-align: left; }
}

/* Toast — всегда в видимой зоне вьюпорта */
.cart-toast {
    position: fixed;
    right: 16px;
    bottom: 24px;
    top: auto;
    left: auto;
    z-index: 10000;
    background: #1a2332;
    color: #fff;
    padding: 12px 16px;
    border-radius: 8px;
    box-shadow: 0 10px 28px rgba(0,0,0,.25);
    font-size: 0.95rem;
    max-width: min(320px, calc(100vw - 32px));
    transform: translateY(120%);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: transform .2s ease, opacity .2s ease, visibility .2s;
}
.cart-toast.is-on {
    transform: translateY(0);
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}
.cart-toast a { color: #9ec0ff; }

/* Lightbox */
.lb-overlay {
    position: fixed; inset: 0; background: rgba(10, 14, 22, .55);
    z-index: 100; display: flex; align-items: center; justify-content: center;
    padding: 16px;
}
.lb-overlay[hidden] { display: none !important; }
.lb-box {
    position: relative;
    width: min(960px, 100%); max-height: 92vh;
    display: flex; flex-direction: column; gap: 10px;
}
.lb-frame {
    position: relative;
}
.lb-close,
.lb-nav {
    position: absolute;
    z-index: 2;
    width: 44px;
    height: 44px;
    margin: 0;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: #fff;
    color: #8a93a3;
    cursor: pointer;
    box-shadow: 0 2px 10px rgba(10, 14, 22, .16);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    line-height: 0;
}
.lb-close svg,
.lb-nav svg {
    width: 20px;
    height: 20px;
    display: block;
    flex-shrink: 0;
}
.lb-close svg path,
.lb-nav svg path {
    fill: none;
    stroke: currentColor;
    stroke-width: 2.25;
    stroke-linecap: round;
    stroke-linejoin: round;
}
.lb-close {
    top: 12px;
    right: 12px;
    z-index: 3;
}
.lb-close:hover,
.lb-nav:hover {
    color: #4a5568;
    background: #f7f8fa;
}
.lb-nav {
    top: 50%;
    transform: translateY(-50%);
}
.lb-nav:hover { color: var(--accent, #2f6fed); }
.lb-nav[hidden] { display: none !important; }
.lb-prev { left: 12px; }
.lb-next { right: 12px; }
.lb-stage {
    position: relative;
    overflow: hidden;
    width: 100%;
    height: min(72vh, 640px);
    border-radius: 8px;
    background: #fff;
    touch-action: none;
    cursor: grab;
}
.lb-stage.is-dragging { cursor: grabbing; }
.lb-stage img {
    position: absolute;
    left: 50%; top: 50%;
    max-width: none;
    width: auto; height: auto;
    max-height: 100%;
    transform: translate(-50%, -50%) scale(1);
    transform-origin: center center;
    user-select: none;
    -webkit-user-drag: none;
    pointer-events: none;
}
.lb-toolbar {
    display: flex; gap: 8px; align-items: center; flex-wrap: wrap; justify-content: center;
}
.lb-toolbar button {
    background: #fff; border: 0; border-radius: 6px; padding: 8px 12px;
    font-weight: 700; cursor: pointer; font-family: inherit;
}

@media (max-width: 860px) {
    .lb-close,
    .lb-nav { width: 38px; height: 38px; }
    .lb-close svg,
    .lb-nav svg { width: 18px; height: 18px; }
    .lb-close { top: 8px; right: 8px; }
    .lb-prev { left: 8px; }
    .lb-next { right: 8px; }

    html { font-size: 16px; }
    .header-top {
        grid-template-columns: auto 1fr auto;
        justify-items: stretch;
        gap: 10px;
        align-items: center;
    }
    .logo { text-align: center; font-size: 1.25rem; justify-self: center; }
    .header-mid {
        display: contents;
    }
    .catalog-wrap { grid-column: 1; grid-row: 1; }
    .logo { grid-column: 2; grid-row: 1; }
    .search-toggle {
        display: inline-flex;
        grid-column: 3; grid-row: 1;
        justify-self: end;
    }
    .catalog-btn--text { display: none; }
    .catalog-btn--icon { display: inline-flex; }
    .header-contacts {
        grid-column: 1 / -1;
        text-align: center; width: 100%;
        padding-top: 4px;
        flex-direction: column;
        align-items: center;
        gap: 10px;
    }
    .header-locs { max-width: none; justify-content: center; width: 100%; }
    .hc-loc { align-items: center; }
    .hc-loc-head, .hc-loc-phones { align-items: center; justify-content: center; }
    .hc-hours { text-align: center; max-width: none; white-space: normal; }

    /* Плавающая корзина — жирная иконка + бейдж, только при товарах */
    .header-contacts .cart-link {
        display: none !important;
    }
    .header-contacts .cart-link:not(.is-empty) {
        display: inline-flex !important;
        position: fixed;
        top: max(7rem, calc(env(safe-area-inset-top, 0px) + 6.5rem));
        right: max(12px, env(safe-area-inset-right, 0px));
        z-index: 55;
        width: auto; height: auto; min-width: 44px; min-height: 44px;
        padding: 8px; gap: 0;
        border-radius: 12px;
        justify-content: center;
        align-items: center;
        background: #fff;
        border: 1.5px solid var(--line);
        color: var(--text) !important;
        box-shadow: 0 3px 14px rgba(15, 30, 55, 0.2);
    }
    .header-contacts .cart-link .cart-link-text { display: none; }
    .header-contacts .cart-link:not(.is-empty) .cart-link-icon {
        display: block !important;
        width: 28px; height: 28px;
    }
    .header-contacts .cart-link .cart-badge {
        position: absolute; top: -4px; right: -4px;
        min-width: 1.35em; height: 1.35em; font-size: 0.72rem;
    }

    .search-form {
        display: none;
        grid-column: 1 / -1;
        grid-row: 2;
        width: 100%;
    }
    body.is-search-open .search-form { display: flex; }
    body.is-search-open .search-submit { display: none; }
    /* почти до низа экрана — раньше 50vh/320px обрезало список посередине */
    body.is-search-open .search-suggest {
        max-height: calc(100vh - 11rem);
        max-height: calc(100dvh - 11rem);
    }

    .top-menu-inner {
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
        justify-content: flex-start;
        font-size: 0.82rem;
    }
    .top-menu-scroll {
        min-width: 0;
        max-width: 100%;
        overflow: hidden;
        -webkit-mask-image: linear-gradient(90deg, #000 0%, #000 calc(100% - 1.75rem), transparent 100%);
        mask-image: linear-gradient(90deg, #000 0%, #000 calc(100% - 1.75rem), transparent 100%);
    }
    .top-menu-links {
        flex-wrap: nowrap;
        overflow-x: auto;
        overflow-y: hidden;
        -webkit-overflow-scrolling: touch;
        touch-action: pan-x;
        scrollbar-width: none;
        gap: 6px 14px;
        padding: 2px 0 4px;
    }
    .top-menu-links::-webkit-scrollbar { display: none; }
    .top-menu-links a { flex-shrink: 0; white-space: nowrap; }
    .top-menu-social { margin-left: 0; width: 100%; justify-content: center; }
    .top-menu-social-label { display: none; }

    .quick-links .container {
        flex-wrap: nowrap;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        justify-content: flex-start;
        gap: 8px 14px;
        padding: 12px 4px;
        font-size: 0.8rem;
        -webkit-mask-image: linear-gradient(90deg, #000 0%, #000 calc(100% - 1.75rem), transparent 100%);
        mask-image: linear-gradient(90deg, #000 0%, #000 calc(100% - 1.75rem), transparent 100%);
    }
    .quick-links .container::-webkit-scrollbar { display: none; }
    .quick-links .container a { flex-shrink: 0; white-space: nowrap; }

    .catalog-panel-bar { display: flex; }
    .catalog-panel {
        background: #fff;
        cursor: default;
        z-index: 90;
    }
    .catalog-panel-inner {
        width: 100%;
        margin: 0;
        grid-template-columns: 1fr;
        height: 100%;
        flex: 1 1 auto;
        min-height: 0;
        overflow: hidden;
        display: flex;
        flex-direction: column;
        box-shadow: none;
        border-radius: 0;
    }
    .catalog-groups {
        border-right: 0;
        max-height: none;
        flex: 1 1 auto;
        min-height: 0;
        overflow: auto;
        padding: 8px 10px;
    }
    .catalog-all, .catalog-group {
        padding: 8px 10px;
    }
    .catalog-types {
        display: none;
        flex: 1 1 auto;
        min-height: 0;
        overflow: hidden;
        padding: 0;
    }
    .catalog-types-top {
        padding: 12px 14px 10px;
    }
    .catalog-panel.is-types .catalog-groups { display: none; }
    .catalog-panel.is-types .catalog-types { display: flex; flex-direction: column; }
    .catalog-types-back { display: inline-block; }
    .catalog-types-hint { display: none; }
    .catalog-types-list {
        padding: 8px 14px 14px;
        gap: 20px;
    }
    .catalog-types-list .marks-letter-row {
        gap: 0 16px;
    }

    .product-page {
        grid-template-columns: 1fr;
        grid-template-areas:
            "crumbs"
            "title"
            "gallery"
            "info"
            "donor";
        gap: 12px;
    }
    .product-heading > h1 {
        font-size: 1.12rem;
        line-height: 1.3;
    }
    .product-heading .meta {
        margin-top: 6px;
        font-size: 0.88rem;
    }
    /* Чуть крупнее превью — удобнее тапать; на экране ~4 шт + «хвост» следующей */
    .thumb img { width: 72px; height: 54px; }
    .footer-grid { grid-template-columns: 1fr; }
    .footer-cats-cols { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .product-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 10px;
    }
    .product-card-body { padding: 10px 10px 12px; }
    .product-card-body .title { font-size: 0.9rem; }
    .product-card-img { margin: 8px 8px 0; border-radius: 10px; }
    .btn-sm { padding: 8px 12px; font-size: 0.85rem; }
    .marks-alpha { column-count: 2; column-gap: 16px; }
    .marks-alpha--compact { column-count: 2; }
    .related-parts-list { column-count: 2; column-gap: 16px; }
    .home-search-row { grid-template-columns: 1fr; }
    .home-search-actions {
        flex-direction: column;
        align-items: stretch;
    }
    .home-search-actions .btn { width: 100%; }
    .home-search-actions .filter-reset { text-align: center; }
    .checkout-options { grid-template-columns: 1fr; }
    .cart-toast { right: 10px; left: 10px; bottom: 16px; max-width: none; }
    .logo-img { height: 36px; }
    .features-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* Контентные страницы и блоки главной (content/*.html) */
.btn-secondary {
    background: #fff; color: var(--text); border: 1px solid var(--line);
    box-shadow: none;
}
.btn-secondary:hover {
    background: #e8f7fc; border-color: var(--accent); color: var(--accent-dark);
}
.info-lead {
    margin: 0 0 22px; padding: 18px 22px;
    background: linear-gradient(135deg, #e8f7fc 0%, #ffffff 70%);
    border: 1px solid #b8e4f5; border-radius: 12px; color: #475569;
}
.info-cards-grid {
    display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 14px; margin: 0 0 22px;
}
.info-card {
    background: #fff; border: 1px solid var(--line); border-radius: 12px;
    padding: 18px 20px; box-shadow: 0 2px 8px rgba(15, 23, 42, 0.04);
}
.info-card h2, .info-card h3 { margin: 0 0 8px; font-size: 1.05rem; color: var(--text); }
.info-card p { margin: 0; color: #475569; }
.info-callout {
    margin: 18px 0; padding: 16px 18px;
    background: #e8f7fc; border: 1px solid #b8e4f5;
    border-left: 4px solid var(--accent); border-radius: 10px;
}
.requisites-box {
    margin-top: 18px; padding: 16px 18px; background: #f8fafc;
    border: 1px solid var(--line); border-radius: 12px;
}
.external-badges, .tk-badges, .home-trust-links {
    display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0 0;
}
.ext-badge, .tk-badge {
    display: inline-flex; align-items: center;
    padding: 7px 12px; border-radius: 999px; font-size: 0.86rem; font-weight: 700;
    background: #fff; border: 1px solid var(--line); color: var(--text);
    text-decoration: none !important;
}
.ext-badge:hover { border-color: var(--accent); background: #e8f7fc; }
.tk-badge { background: #e8f7fc; border-color: #b8e4f5; color: var(--accent-dark); }
.contacts-summary-grid {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 14px; margin-bottom: 22px;
}
.contact-big-phone { font-size: 1.35rem; font-weight: 800; margin: 0 0 6px; }
.contact-big-phone a { color: var(--text); text-decoration: none; }
.warehouse-block {
    margin: 0 0 22px; padding: 18px 20px; background: #fff;
    border: 1px solid var(--line); border-radius: 12px;
}
.warehouse-header { margin-bottom: 8px; }
.warehouse-tag {
    display: inline-flex; padding: 4px 10px; border-radius: 999px;
    background: var(--accent); color: #fff; font-size: 0.78rem; font-weight: 800;
}
.home-features { margin-top: 28px; }
.features-grid {
    display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px;
}
.feature-card {
    background: #fff; border: 1px solid var(--line); border-top: 3px solid var(--accent);
    border-radius: 12px; padding: 18px 16px;
}
.feature-icon {
    width: 40px; height: 40px; margin-bottom: 10px; color: var(--accent-dark);
    display: flex; align-items: center; justify-content: center;
}
.feature-icon svg { width: 28px; height: 28px; }
.feature-card h3 { margin: 0 0 6px; font-size: 1rem; }
.feature-card p { margin: 0; font-size: 0.9rem; color: #475569; }
.home-banner-row { margin-top: 22px; }
.home-trust-box {
    background: linear-gradient(135deg, #e8f7fc 0%, #ffffff 70%);
    border: 1px solid #b8e4f5; border-radius: 12px; padding: 20px 22px;
}
.home-trust-badge {
    display: inline-block; margin-bottom: 8px;
    padding: 4px 10px; border-radius: 999px; font-size: 0.75rem; font-weight: 800;
    background: var(--badge-hot); color: #fff;
}
.home-trust-links .btn-sm { width: auto; }

/* Bento + редакционный блок со старой главной */
.bm-bento {
    display: grid;
    grid-template-columns: 1.35fr 1fr;
    gap: 16px;
    margin-top: 8px;
}
.bm-bento-main {
    background: linear-gradient(145deg, #e8f7fc 0%, #ffffff 55%);
    border: 1px solid #b8e4f5;
    border-radius: 16px;
    padding: 26px 28px;
    box-shadow: 0 4px 18px rgba(0, 168, 232, 0.08);
}
.bm-chip {
    display: inline-block; margin-bottom: 12px;
    padding: 4px 10px; border-radius: 999px; font-size: 0.75rem; font-weight: 800;
    background: var(--accent); color: #fff;
}
.bm-bento-main h3 { margin: 0 0 10px; font-size: 1.35rem; color: var(--text); }
.bm-bento-main p { margin: 0 0 14px; color: #475569; }
.bm-checklist {
    margin: 0; padding-left: 18px; display: grid; gap: 6px; color: #334155;
}
.bm-checklist li::marker { color: var(--accent); }
.bm-bento-side { display: grid; gap: 12px; }
.bm-mini-card {
    background: #fff; border: 1px solid var(--line); border-radius: 14px;
    padding: 16px 18px; box-shadow: 0 2px 10px rgba(15, 23, 42, 0.04);
}
.bm-mini-card strong {
    display: block; font-size: 1.15rem; color: var(--accent-dark); margin-bottom: 4px;
}
.bm-mini-card span { color: #64748b; font-size: 0.92rem; line-height: 1.4; }

.bm-editorial { margin-top: 36px; }
.bm-editorial-grid {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 20px;
}
.bm-editorial-lead,
.bm-editorial-points {
    background: #fff; border: 1px solid var(--line); border-radius: 16px;
    padding: 22px 24px; box-shadow: 0 2px 10px rgba(15, 23, 42, 0.04);
}
.bm-editorial-lead p { margin: 0 0 12px; color: #475569; line-height: 1.55; }
.bm-editorial-lead p:last-child { margin-bottom: 0; }
.bm-editorial-points h3 { margin: 0 0 12px; font-size: 1.08rem; }
.bm-editorial-points ol {
    margin: 0; padding-left: 18px; display: grid; gap: 10px; color: #475569;
}
.bm-editorial-points li::marker { color: var(--accent-dark); font-weight: 800; }

@media (max-width: 899px) {
    .bm-bento, .bm-editorial-grid { grid-template-columns: 1fr; }
    .features-grid { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
    .features-grid { grid-template-columns: 1fr; }
    .product-card-foot { flex-direction: column; align-items: stretch; }
    .product-card-foot .btn { width: 100%; text-align: center; }
}
/* —— Страница 404 —— */
.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;
}
.page-404 { max-width: 960px; }
.page-404-hero {
    background: linear-gradient(135deg, #f8fafc 0%, #ffffff 55%, #f1f5f9 100%);
    border: 1px solid var(--line);
    border-radius: 16px;
    padding: 28px 26px 24px;
    margin-bottom: 28px;
}
.page-404-code {
    font-size: clamp(2.6rem, 6vw, 3.6rem);
    font-weight: 900;
    line-height: 1;
    letter-spacing: -0.04em;
    color: var(--accent);
    margin-bottom: 8px;
}
.page-404-hero h1 {
    margin: 0 0 10px;
    font-size: clamp(1.45rem, 2.6vw, 1.9rem);
    line-height: 1.25;
}
.page-404-hero > p {
    margin: 0;
    color: #475569;
    max-width: 640px;
    line-height: 1.55;
}
.page-404-search {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 18px;
}
.page-404-search input[type="search"] {
    flex: 1 1 240px;
    min-width: 0;
    padding: 11px 14px;
    border: 1px solid var(--line);
    border-radius: 10px;
    font: inherit;
    background: #fff;
}
.page-404-search input[type="search"]:focus {
    outline: 2px solid var(--accent);
    outline-offset: 1px;
    border-color: var(--accent);
}
.page-404-cta {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px 16px;
    margin-top: 16px;
}
.page-404-link-quiet {
    color: var(--accent-dark, var(--accent));
    font-weight: 600;
    text-decoration: none;
}
.page-404-link-quiet:hover { text-decoration: underline; }
.page-404-block { margin-bottom: 8px; }
.page-404-block h2 {
    margin: 0 0 12px;
    font-size: 1.15rem;
}
.page-404-links {
    display: flex;
    flex-wrap: wrap;
    gap: 8px 10px;
}
.page-404-links a {
    display: inline-block;
    padding: 8px 12px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: #fff;
    color: var(--text);
    font-weight: 600;
    font-size: 0.92rem;
    text-decoration: none !important;
    transition: border-color .15s ease, color .15s ease;
}
.page-404-links a:hover {
    border-color: var(--accent);
    color: var(--accent-dark, var(--accent));
}
.page-404-note { margin: 20px 0 0; line-height: 1.5; }
@media (max-width: 560px) {
    .page-404-hero { padding: 22px 16px 18px; }
    .page-404-search .btn { width: 100%; text-align: center; }
}
