/* ==========================================================================
   AVS Product Filter — v1.0.4
   ========================================================================== */

/* --------------------------------------------------------------------------
   CSS Variables
   -------------------------------------------------------------------------- */
:root {
    --avs-primary:     var(--theme-color, #222222);
    --avs-primary-rgb: var(--theme-color-rgb, 34, 34, 34);
    --avs-text:        var(--et_color_base_text, #555555);
    --avs-heading:     var(--et_color_base_heading, #222222);
    --avs-border:      #e0e0e0;
    --avs-bg:          #ffffff;
    --avs-bg-hover:    #f7f7f7;
    --avs-radius:      4px;
    --avs-font:        inherit;
    --avs-sidebar-w:   280px;
    --avs-gap:         28px;
}

/* --------------------------------------------------------------------------
   Layout
   -------------------------------------------------------------------------- */
.avs-shop-layout {
    display: grid;
    grid-template-columns: var(--avs-sidebar-w) 1fr;
    gap: var(--avs-gap);
    align-items: start;
    width: 100%;
}

/* ПРОБЛЕМ 5 — No max-height/overflow on sidebar; sticky on desktop */
.avs-filter-sidebar {
    position: sticky;
    top: 20px;
    min-width: 260px;
}

.avs-filter-sidebar-inner {
    display: flex;
    flex-direction: column;
    gap: 0;
    border: 1px solid var(--avs-border);
    border-radius: var(--avs-radius);
    background: var(--avs-bg);
    overflow: hidden;
}

.avs-products-area {
    min-width: 0;
}

/* --------------------------------------------------------------------------
   Accordion sections — ПОДОБРЕНИЕ 1 + 2
   -------------------------------------------------------------------------- */
.avs-filter-section {
    border-bottom: 1px solid var(--avs-border);
}
.avs-filter-section:last-child {
    border-bottom: none;
}

/* Section head wrapper (holds toggle button + clear button side-by-side) */
.avs-section-head {
    display: flex;
    align-items: center;
}

.avs-section-header {
    display: flex;
    align-items: center;
    flex: 1;
    min-width: 0;
    background: none;
    border: none;
    padding: 12px 16px;
    font-size: 13px;
    font-weight: 600;
    font-family: var(--avs-font);
    color: var(--avs-heading);
    cursor: pointer;
    text-align: left;
    transition: background .15s;
    letter-spacing: .03em;
    text-transform: uppercase;
    gap: 6px;
}
.avs-section-header:hover { background: var(--avs-bg-hover); }

/* Title + summary wrapper — column layout so summary appears below title */
.avs-section-text {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 1px;
}

.avs-section-title { /* no flex: 1 — handled by parent */ }

/* ПОДОБРЕНИЕ 1 — Active count badge */
.avs-section-badge {
    font-size: 11px;
    font-weight: 700;
    color: var(--avs-primary);
    background: rgba(var(--avs-primary-rgb), .1);
    border-radius: 10px;
    padding: 1px 6px;
    flex-shrink: 0;
    transition: opacity .2s;
}
.avs-section-badge:empty { display: none; }

/* Section summary — applied values shown UNDER the title when collapsed */
.avs-section-summary {
    font-size: 11px;
    color: var(--avs-primary);
    font-weight: 600;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    line-height: 1.3;
}
.avs-section-summary:empty { display: none; }

/* Active section — pale green highlight on the header */
.avs-filter-section.avs-section-active > .avs-section-head .avs-section-header {
    background: rgba(76, 175, 80, .08);
    border-radius: var(--avs-radius);
}
.avs-filter-section.avs-section-active > .avs-section-head .avs-section-header:hover {
    background: rgba(76, 175, 80, .14);
}

.avs-chevron {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    transition: transform .2s;
    color: var(--avs-text);
}
.avs-section-header[aria-expanded="false"] .avs-chevron { transform: rotate(-90deg); }

/* ПОДОБРЕНИЕ 2 — Clear section button */
.avs-section-clear {
    background: none;
    border: none;
    padding: 4px 12px 4px 4px;
    font-size: 16px;
    line-height: 1;
    color: #bbb;
    cursor: pointer;
    flex-shrink: 0;
    transition: color .15s;
}
.avs-section-clear:hover { color: #c00; }

.avs-section-body {
    padding: 0 16px;
    max-height: 0;
    overflow: hidden;
    transition: max-height .25s ease, padding .25s ease;
}
.avs-section-body.open {
    max-height: 800px;
    padding: 4px 16px 14px;
    overflow-y: auto;
}

/* --------------------------------------------------------------------------
   Sort dropdown
   -------------------------------------------------------------------------- */
.avs-select {
    width: 100%;
    padding: 8px 10px;
    border: 1px solid var(--avs-border);
    border-radius: var(--avs-radius);
    background: var(--avs-bg);
    color: var(--avs-text);
    font-family: var(--avs-font);
    font-size: 13px;
    cursor: pointer;
    outline: none;
    -webkit-appearance: none;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%23999' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 10px center;
    padding-right: 30px;
}
.avs-select:focus { border-color: var(--avs-primary); }

/* --------------------------------------------------------------------------
   Checkboxes
   -------------------------------------------------------------------------- */
.avs-checkbox-list,
.avs-special-list {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.avs-cb-label {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 5px 4px;
    cursor: pointer;
    border-radius: var(--avs-radius);
    font-size: 13px;
    color: var(--avs-text);
    transition: background .12s, opacity .2s;
    line-height: 1.4;
}
.avs-cb-label:hover { background: var(--avs-bg-hover); }

/* ПРОБЛЕМ 2 — Disabled state for unavailable options */
.avs-cb-label.avs-disabled {
    opacity: 0.38;
    cursor: not-allowed;
    pointer-events: none;
}

.avs-cb-label input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.avs-cb-box {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    border: 1.5px solid var(--avs-border);
    border-radius: 3px;
    background: var(--avs-bg);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: border-color .15s, background .15s;
}
.avs-cb-label input:checked ~ .avs-cb-box {
    background: var(--avs-primary);
    border-color: var(--avs-primary);
}
.avs-cb-label input:checked ~ .avs-cb-box::after {
    content: '';
    display: block;
    width: 9px;
    height: 5px;
    border-left: 2px solid #fff;
    border-bottom: 2px solid #fff;
    transform: rotate(-45deg) translateY(-1px);
}

.avs-cb-text {
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.avs-cb-count {
    color: #aaa;
    font-size: 11px;
    flex-shrink: 0;
    transition: color .2s;
}

/* --------------------------------------------------------------------------
   Radio buttons
   -------------------------------------------------------------------------- */
.avs-radio-list {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.avs-radio-label {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 5px 4px;
    cursor: pointer;
    border-radius: var(--avs-radius);
    font-size: 13px;
    color: var(--avs-text);
    transition: background .12s;
}
.avs-radio-label:hover { background: var(--avs-bg-hover); }
.avs-radio-label input[type="radio"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}
.avs-radio-dot {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    border: 1.5px solid var(--avs-border);
    border-radius: 50%;
    background: var(--avs-bg);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: border-color .15s;
}
.avs-radio-label input:checked ~ .avs-radio-dot { border-color: var(--avs-primary); }
.avs-radio-label input:checked ~ .avs-radio-dot::after {
    content: '';
    display: block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--avs-primary);
}

/* --------------------------------------------------------------------------
   Stars
   -------------------------------------------------------------------------- */
.avs-stars-row {
    display: flex;
    align-items: center;
    gap: 1px;
}
.avs-star { font-size: 14px; line-height: 1; }
.avs-star.filled { color: #f5a623; }
.avs-star.empty  { color: #ddd; }
.avs-stars-label { font-size: 12px; color: var(--avs-text); margin-left: 4px; }

/* --------------------------------------------------------------------------
   Price slider
   -------------------------------------------------------------------------- */
.avs-price-range-display {
    text-align: center;
    font-size: 14px;
    font-weight: 600;
    color: var(--avs-heading);
    margin-bottom: 4px;
    letter-spacing: .01em;
}

.avs-price-wrap { padding: 4px 0; }

.avs-slider-track-wrap {
    position: relative;
    height: 20px;
    margin: 10px 0 14px;
}
.avs-slider-track {
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--avs-border);
    border-radius: 2px;
    transform: translateY(-50%);
}
.avs-slider-fill {
    position: absolute;
    top: 50%;
    height: 4px;
    background: var(--avs-primary);
    border-radius: 2px;
    transform: translateY(-50%);
    pointer-events: none;
    transition: left .1s, right .1s;
}

.avs-range {
    position: absolute;
    top: 50%;
    left: 0;
    width: 100%;
    height: 4px;
    transform: translateY(-50%);
    -webkit-appearance: none;
    appearance: none;
    background: transparent;
    pointer-events: none;
    outline: none;
}
.avs-range::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--avs-bg);
    border: 2px solid var(--avs-primary);
    cursor: pointer;
    pointer-events: all;
    box-shadow: 0 1px 3px rgba(0,0,0,.2);
    transition: box-shadow .15s;
}
.avs-range::-webkit-slider-thumb:hover { box-shadow: 0 2px 6px rgba(0,0,0,.25); }
.avs-range::-moz-range-thumb {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--avs-bg);
    border: 2px solid var(--avs-primary);
    cursor: pointer;
    pointer-events: all;
}

.avs-price-inputs {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
}
.avs-price-field {
    display: flex;
    align-items: center;
    gap: 4px;
    flex: 1;
    min-width: 0;
    font-size: 12px;
    color: var(--avs-text);
}
.avs-price-sep { color: var(--avs-border); }
.avs-price-txt {
    width: 60px;
    padding: 4px 6px;
    border: 1px solid var(--avs-border);
    border-radius: var(--avs-radius);
    font-size: 12px;
    text-align: center;
    outline: none;
    color: var(--avs-heading);
    background: var(--avs-bg);
    transition: border-color .15s;
}
.avs-price-txt:focus { border-color: var(--avs-primary); }
.avs-currency { font-size: 11px; color: #aaa; }

.avs-price-presets {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}
.avs-preset {
    padding: 4px 10px;
    border: 1px solid var(--avs-border);
    border-radius: 20px;
    background: var(--avs-bg);
    font-size: 11px;
    color: var(--avs-text);
    cursor: pointer;
    transition: border-color .15s, background .15s, color .15s;
    white-space: nowrap;
}
.avs-preset:hover,
.avs-preset.active {
    border-color: var(--avs-primary);
    background: var(--avs-primary);
    color: #fff;
}

/* --------------------------------------------------------------------------
   ПОДОБРЕНИЕ 3 — Color swatches
   -------------------------------------------------------------------------- */
.avs-swatch-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    padding: 4px 0;
}

.avs-swatch-item { display: inline-flex; }

.avs-swatch-input {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.avs-swatch {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: var(--avs-radius);
    border: 2px solid transparent;
    cursor: pointer;
    position: relative;
    transition: border-color .15s, transform .15s, box-shadow .15s, opacity .2s;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0,0,0,.15);
}
.avs-swatch:hover {
    border-color: var(--avs-primary);
    transform: scale(1.1);
    box-shadow: 0 2px 6px rgba(0,0,0,.2);
}
.avs-swatch.active {
    border-color: var(--avs-primary);
    box-shadow: 0 0 0 2px rgba(var(--avs-primary-rgb), .3);
}
.avs-swatch-light {
    border-color: var(--avs-border) !important;
}
.avs-swatch-light:hover,
.avs-swatch-light.active {
    border-color: var(--avs-primary) !important;
}

/* Text swatches (no color found) */
.avs-swatch-text {
    width: auto;
    padding: 4px 10px;
    font-size: 11px;
    color: var(--avs-text);
    background: var(--avs-bg);
    border-color: var(--avs-border);
    white-space: nowrap;
}
.avs-swatch-text.active { background: var(--avs-primary); color: #fff; border-color: var(--avs-primary); }

.avs-swatch-check {
    position: absolute;
    font-size: 14px;
    color: #fff;
    text-shadow: 0 0 2px rgba(0,0,0,.5);
    opacity: 0;
    transition: opacity .15s;
    line-height: 1;
}
.avs-swatch.active .avs-swatch-check { opacity: 1; }

/* Disabled state */
.avs-swatch.avs-swatch-disabled {
    opacity: 0.3;
    cursor: not-allowed;
    pointer-events: none;
}

/* --------------------------------------------------------------------------
   Active filters bar
   -------------------------------------------------------------------------- */
.avs-active-bar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin-bottom: 16px;
    min-height: 0;
}
.avs-active-bar:empty { display: none; }

.avs-active-label {
    font-size: 12px;
    font-weight: 600;
    color: var(--avs-heading);
    white-space: nowrap;
}
.avs-active-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    flex: 1;
}
.avs-chip {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 3px 10px;
    border-radius: 20px;
    border: 1px solid var(--avs-primary);
    background: rgba(var(--avs-primary-rgb), .06);
    font-size: 12px;
    color: var(--avs-heading);
    white-space: nowrap;
    animation: avs-fade-in .2s ease;
}
.avs-chip-remove {
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    font-size: 14px;
    line-height: 1;
    color: var(--avs-text);
    display: flex;
    align-items: center;
    transition: color .15s;
}
.avs-chip-remove:hover { color: #c00; }
.avs-clear-all-btn {
    padding: 4px 12px;
    border: 1px solid #ccc;
    border-radius: 20px;
    background: none;
    font-size: 12px;
    color: var(--avs-text);
    cursor: pointer;
    transition: border-color .15s, color .15s;
    white-space: nowrap;
}
.avs-clear-all-btn:hover { border-color: #c00; color: #c00; }

/* --------------------------------------------------------------------------
   Products area — loading state
   -------------------------------------------------------------------------- */
.avs-products-area.avs-loading {
    position: relative;
    pointer-events: none;
}
.avs-products-area.avs-loading::after {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(255,255,255,.55);
    z-index: 10;
    pointer-events: none;
}

.avs-no-products {
    padding: 40px 20px;
    text-align: center;
    color: var(--avs-text);
    font-size: 14px;
}

/* --------------------------------------------------------------------------
   ПОДОБРЕНИЕ 4 — Skeleton loader
   -------------------------------------------------------------------------- */
.avs-skeleton-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    padding: 4px 0;
}
@media (max-width: 1200px) { .avs-skeleton-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 600px)  { .avs-skeleton-grid { grid-template-columns: repeat(2, 1fr); } }

.avs-skeleton-card {
    border: 1px solid #eee;
    border-radius: var(--avs-radius);
    padding: 12px;
    overflow: hidden;
}
.avs-sk-img {
    width: 100%;
    padding-bottom: 90%;
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: avs-shimmer 1.4s infinite;
    border-radius: 2px;
    margin-bottom: 12px;
}
.avs-sk-line {
    height: 13px;
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: avs-shimmer 1.4s infinite;
    border-radius: 2px;
    margin-bottom: 8px;
}
.avs-sk-short { width: 65%; }
.avs-sk-price {
    height: 16px;
    width: 40%;
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: avs-shimmer 1.4s infinite;
    border-radius: 2px;
    margin-top: 10px;
}
@keyframes avs-shimmer {
    0%   { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* --------------------------------------------------------------------------
   ПОДОБРЕНИЕ 5 — Animations
   -------------------------------------------------------------------------- */
@keyframes avs-fade-in {
    from { opacity: 0; transform: translateY(-3px); }
    to   { opacity: 1; transform: translateY(0); }
}

.avs-cb-label,
.avs-radio-label,
.avs-swatch,
.avs-preset,
.avs-section-clear,
.avs-chip,
.avs-chip-remove,
.avs-clear-all-btn {
    transition: background .15s, border-color .15s, color .15s, opacity .2s, transform .15s;
}

/* --------------------------------------------------------------------------
   Pagination
   -------------------------------------------------------------------------- */
.avs-pagination {
    display: flex;
    justify-content: center;
    margin: 24px 0 0;
}
.avs-pagination .page-numbers {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 36px;
    height: 36px;
    padding: 0 8px;
    margin: 0 2px;
    border: 1px solid var(--avs-border);
    border-radius: var(--avs-radius);
    font-size: 13px;
    color: var(--avs-text);
    text-decoration: none;
    transition: border-color .15s, background .15s, color .15s;
}
.avs-pagination .page-numbers:hover,
.avs-pagination .page-numbers.current {
    border-color: var(--avs-primary);
    background: var(--avs-primary);
    color: #fff;
}
.avs-pagination .page-numbers.dots {
    border-color: transparent;
    background: none;
    cursor: default;
}

.avs-products-area .woocommerce-ordering { display: none !important; }

/* --------------------------------------------------------------------------
   ПРОБЛЕМ 1 — Toolbar (per-page selector)
   -------------------------------------------------------------------------- */
/* Product count display */
.avs-product-count {
    font-size: 13px;
    color: var(--avs-text);
    opacity: .75;
    padding: 4px 0 8px;
}
.avs-product-count:empty { display: none; }

.avs-toolbar {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding: 6px 0 10px;
    gap: 8px;
    border-bottom: 1px solid var(--avs-border);
    margin-bottom: 12px;
}

.avs-toolbar-right {
    display: flex;
    align-items: center;
    gap: 8px;
}

.avs-perpage-label {
    font-size: 12px;
    color: var(--avs-text);
    white-space: nowrap;
}

.avs-perpage-select {
    min-width: 72px;
    max-width: 90px;
    padding: 5px 8px;
    font-size: 13px;
    border: 1px solid var(--avs-border);
    border-radius: var(--avs-radius);
    background: var(--avs-bg);
    color: var(--avs-text);
    cursor: pointer;
    height: 32px;
}
.avs-perpage-select:focus {
    outline: 2px solid rgba(var(--avs-primary-rgb), .3);
    border-color: var(--avs-primary);
}

/* --------------------------------------------------------------------------
   ПРОБЛЕМ 2 — Active bar chip with "Изчисти" button below the value
   -------------------------------------------------------------------------- */
.avs-chip {
    display: inline-flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 2px;
    background: #f0f0f0;
    border: 1px solid var(--avs-border);
    border-radius: var(--avs-radius);
    padding: 4px 8px 5px;
    font-size: 12px;
    color: var(--avs-text);
    line-height: 1.3;
    cursor: default;
}

.avs-chip-val {
    font-weight: 500;
    color: var(--avs-heading);
    white-space: nowrap;
}

/* "Изчисти" button under the chip value */
.avs-chip-remove {
    display: inline-block;
    background: none;
    border: none;
    padding: 0;
    font-size: 10px;
    font-weight: 600;
    color: var(--avs-primary);
    cursor: pointer;
    line-height: 1;
    text-decoration: underline;
    text-underline-offset: 1px;
    letter-spacing: .02em;
    opacity: .8;
    transition: opacity .15s;
}
.avs-chip-remove:hover {
    opacity: 1;
    color: #c0392b;
    text-decoration: none;
}

/* --------------------------------------------------------------------------
   ПРОБЛЕМ 4 — Mobile filter button
   -------------------------------------------------------------------------- */
.avs-mobile-filter-btn {
    display: none;
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 9998;
    background: var(--avs-primary);
    color: #fff;
    border: none;
    border-radius: 30px;
    padding: 12px 24px;
    font-size: 14px;
    font-weight: 600;
    font-family: var(--avs-font);
    cursor: pointer;
    box-shadow: 0 4px 16px rgba(0,0,0,.28);
    align-items: center;
    gap: 8px;
    min-height: 44px;
    /* ПРОБЛЕМ 4 — smooth size transitions */
    transition: padding .25s ease, width .25s ease, border-radius .25s ease;
}

/* ПРОБЛЕМ 4 — Compact state on scroll */
.avs-mobile-filter-btn.avs-btn-compact {
    padding: 0;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    justify-content: center;
}
.avs-mobile-filter-btn.avs-btn-compact .avs-mobile-btn-text { display: none; }
.avs-mobile-filter-btn.avs-btn-compact .avs-filter-badge {
    position: absolute;
    top: -4px;
    right: -4px;
}

.avs-mobile-btn-icon { flex-shrink: 0; }

.avs-filter-badge {
    background: #fff;
    color: var(--avs-primary);
    border-radius: 50%;
    width: 20px;
    height: 20px;
    font-size: 11px;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

/* --------------------------------------------------------------------------
   Drawer overlay
   -------------------------------------------------------------------------- */
.avs-drawer-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.45);
    z-index: 9999;
}
.avs-drawer-overlay.open { display: block; }

/* --------------------------------------------------------------------------
   Drawer header & footer
   -------------------------------------------------------------------------- */
.avs-drawer-header {
    display: none;
    align-items: center;
    justify-content: space-between;
    padding: 16px;
    border-bottom: 1px solid var(--avs-border);
    font-weight: 700;
    font-size: 15px;
    color: var(--avs-heading);
    flex-shrink: 0;
}
.avs-drawer-close {
    background: none;
    border: none;
    font-size: 26px;
    line-height: 1;
    cursor: pointer;
    color: var(--avs-text);
    padding: 0;
    min-width: 44px;
    min-height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* ПОДОБРЕНИЕ 7 — Drawer footer with "Покажи X продукта" */
.avs-drawer-footer {
    display: none;
    padding: 12px 16px;
    border-top: 1px solid var(--avs-border);
    flex-shrink: 0;
}
.avs-drawer-apply {
    width: 100%;
    background: var(--avs-primary);
    color: #fff;
    border: none;
    border-radius: var(--avs-radius);
    padding: 13px;
    font-size: 14px;
    font-weight: 600;
    font-family: var(--avs-font);
    cursor: pointer;
    min-height: 44px;
    transition: opacity .15s;
}
.avs-drawer-apply:hover { opacity: .88; }

/* --------------------------------------------------------------------------
   Responsive — mobile drawer
   -------------------------------------------------------------------------- */
@media (max-width: 768px) {
    .avs-shop-layout { display: block; }

    .avs-filter-sidebar {
        position: fixed;
        top: 0;
        left: 0;
        bottom: 0;
        width: 300px;
        max-width: 90vw;
        background: var(--avs-bg);
        z-index: 10000;
        transform: translateX(-100%);
        transition: transform .28s ease;
        display: flex;
        flex-direction: column;
        overflow: hidden;
        max-height: 100vh;
    }
    .avs-filter-sidebar.avs-open { transform: translateX(0); }

    .avs-filter-sidebar-inner { flex: 1; overflow-y: auto; }

    .avs-drawer-header,
    .avs-drawer-footer { display: flex; }

    .avs-mobile-filter-btn { display: flex; }

    .avs-cb-label,
    .avs-radio-label { min-height: 44px; }
    .avs-section-header { min-height: 44px; }
}

@media (min-width: 769px) {
    .avs-mobile-filter-btn,
    .avs-drawer-overlay { display: none !important; }
}
.wpcf7 .screen-reader-response {
	position: absolute;
	overflow: hidden;
	clip: rect(1px, 1px, 1px, 1px);
	clip-path: inset(50%);
	height: 1px;
	width: 1px;
	margin: -1px;
	padding: 0;
	border: 0;
	word-wrap: normal !important;
}

.wpcf7 form .wpcf7-response-output {
	margin: 2em 0.5em 1em;
	padding: 0.2em 1em;
	border: 2px solid #00a0d2; /* Blue */
}

.wpcf7 form.init .wpcf7-response-output,
.wpcf7 form.resetting .wpcf7-response-output,
.wpcf7 form.submitting .wpcf7-response-output {
	display: none;
}

.wpcf7 form.sent .wpcf7-response-output {
	border-color: #46b450; /* Green */
}

.wpcf7 form.failed .wpcf7-response-output,
.wpcf7 form.aborted .wpcf7-response-output {
	border-color: #dc3232; /* Red */
}

.wpcf7 form.spam .wpcf7-response-output {
	border-color: #f56e28; /* Orange */
}

.wpcf7 form.invalid .wpcf7-response-output,
.wpcf7 form.unaccepted .wpcf7-response-output,
.wpcf7 form.payment-required .wpcf7-response-output {
	border-color: #ffb900; /* Yellow */
}

.wpcf7-form-control-wrap {
	position: relative;
}

.wpcf7-not-valid-tip {
	color: #dc3232; /* Red */
	font-size: 1em;
	font-weight: normal;
	display: block;
}

.use-floating-validation-tip .wpcf7-not-valid-tip {
	position: relative;
	top: -2ex;
	left: 1em;
	z-index: 100;
	border: 1px solid #dc3232;
	background: #fff;
	padding: .2em .8em;
	width: 24em;
}

.wpcf7-list-item {
	display: inline-block;
	margin: 0 0 0 1em;
}

.wpcf7-list-item-label::before,
.wpcf7-list-item-label::after {
	content: " ";
}

.wpcf7-spinner {
	visibility: hidden;
	display: inline-block;
	background-color: #23282d; /* Dark Gray 800 */
	opacity: 0.75;
	width: 24px;
	height: 24px;
	border: none;
	border-radius: 100%;
	padding: 0;
	margin: 0 24px;
	position: relative;
}

form.submitting .wpcf7-spinner {
	visibility: visible;
}

.wpcf7-spinner::before {
	content: '';
	position: absolute;
	background-color: #fbfbfc; /* Light Gray 100 */
	top: 4px;
	left: 4px;
	width: 6px;
	height: 6px;
	border: none;
	border-radius: 100%;
	transform-origin: 8px 8px;
	animation-name: spin;
	animation-duration: 1000ms;
	animation-timing-function: linear;
	animation-iteration-count: infinite;
}

@media (prefers-reduced-motion: reduce) {
	.wpcf7-spinner::before {
		animation-name: blink;
		animation-duration: 2000ms;
	}
}

@keyframes spin {
	from {
		transform: rotate(0deg);
	}

	to {
		transform: rotate(360deg);
	}
}

@keyframes blink {
	from {
		opacity: 0;
	}

	50% {
		opacity: 1;
	}

	to {
		opacity: 0;
	}
}

.wpcf7 [inert] {
	opacity: 0.5;
}

.wpcf7 input[type="file"] {
	cursor: pointer;
}

.wpcf7 input[type="file"]:disabled {
	cursor: default;
}

.wpcf7 .wpcf7-submit:disabled {
	cursor: not-allowed;
}

.wpcf7 input[type="url"],
.wpcf7 input[type="email"],
.wpcf7 input[type="tel"] {
	direction: ltr;
}

.wpcf7-reflection > output {
	display: list-item;
	list-style: none;
}

.wpcf7-reflection > output[hidden] {
	display: none;
}