/* ── Checkbox / radio filter option rows (fixes invisible checkboxes) ── */
.product_filter_checkbox.ppf-filter-option {
    display: flex;
    align-items: center;
    gap: 10px;
    /* padding: 6px 0; */
    cursor: pointer;
    position: relative;
}
.product_filter_checkbox.ppf-filter-option input[type="checkbox"],
.product_filter_checkbox.ppf-filter-option input[type="radio"] {
    position: absolute;
    opacity: 0;
    width: 18px;
    height: 18px;
    margin: 0;
    cursor: pointer;
}
.product_filter_checkmark.ppf-checkmark,
.ppf-checkmark {
    flex-shrink: 0;
    width: 18px;
    height: 18px;
    border: 1.5px solid #c7d0d8;
    border-radius: 4px;
    background: #fff;
    position: relative;
    transition: background .15s, border-color .15s;
    display: inline-block;
}
/* Radio variant gets round checkmark */
.product_filter_checkbox.ppf-filter-option input[type="radio"] ~ .ppf-checkmark {
    border-radius: 50%;
}
.ppf-checkmark::after {
    content: "";
    position: absolute;
    display: none;
    left: 5px;
    top: 1px;
    width: 5px;
    height: 9px;
    border: solid #fff;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}
input[type="radio"] ~ .ppf-checkmark::after {
    left: 50%;
    top: 50%;
    width: 8px;
    height: 8px;
    border: none;
    border-radius: 50%;
    background: #fff;
    transform: translate(-50%, -50%);
}
.product_filter_checkbox.ppf-filter-option input:checked ~ .ppf-checkmark {
    background: var(--ppf-primary, #1b3b53);
    border-color: var(--ppf-primary, #1b3b53);
}
.product_filter_checkbox.ppf-filter-option input:checked ~ .ppf-checkmark::after {
    display: block;
}
.ppf-option-label { flex: 1 1 auto; }

/* ── Attribute display style: Color Swatches (.ppf-color-swatches / .ppf-swatch) ── */
.ppf-color-swatches {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 10px !important;
    width: auto !important;
}
button.ppf-swatch,
.ppf-color-swatches button.ppf-swatch {
    display: inline-block !important;
    position: relative !important;
    width: 32px !important;
    height: 32px !important;
    min-width: 32px !important;
    max-width: 32px !important;
    line-height: normal !important;
    padding: 0 !important;
    margin: 0 !important;
    border: 2px solid #fff !important;
    outline: 1.5px solid #d1d9e0 !important;
    outline-offset: 0 !important;
    border-radius: 50% !important;
    background: var(--ppf-swatch-color, #ccc) !important;
    cursor: pointer !important;
    box-sizing: border-box !important;
    transition: outline-color .15s, transform .15s !important;
    flex: 0 0 32px !important;
    flex-shrink: 0 !important;
    -webkit-appearance: none !important;
    appearance: none !important;
}
button.ppf-swatch:hover {
    outline-color: var(--ppf-primary, #1b3b53) !important;
    transform: translateY(-1px);
}
button.ppf-swatch.active {
    outline-color: var(--ppf-accent, #e8a000) !important;
    outline-width: 2px !important;
}
button.ppf-swatch span {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 13px;
    font-weight: 700;
    text-shadow: 0 1px 2px rgba(0,0,0,.5);
    pointer-events: none;
}

/* ── Attribute display style: Text Labels (.ppf-label-swatches / .ppf-label-swatch) ── */
.ppf-label-swatches {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 8px !important;
    width: auto !important;
}
button.ppf-label-swatch,
.ppf-label-swatches button.ppf-label-swatch {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: auto !important;
    height: auto !important;
    padding: 6px 14px !important;
    margin: 0 !important;
    border: 1.5px solid #d1d9e0 !important;
    border-radius: var(--ppf-radius, 6px) !important;
    background: #fff !important;
    color: #374151 !important;
    font-size: 13px !important;
    font-weight: 600 !important;
    line-height: normal !important;
    cursor: pointer !important;
    transition: background .15s, border-color .15s, color .15s !important;
    box-sizing: border-box !important;
    -webkit-appearance: none !important;
    appearance: none !important;
}
button.ppf-label-swatch:hover {
    border-color: var(--ppf-primary, #1b3b53) !important;
    color: var(--ppf-primary, #1b3b53) !important;
}
button.ppf-label-swatch.active {
    background: var(--ppf-primary, #1b3b53) !important;
    border-color: var(--ppf-primary, #1b3b53) !important;
    color: #fff !important;
}

/* ── Accordion collapse/expand (Categories, Price, Attributes, etc.) ── */
.ppf-section-title {
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
    user-select: none;
    -webkit-user-select: none;
}
.ppf-section-toggle {
    width: 9px;
    height: 9px;
    border-right: 2px solid #8a98a3;
    border-bottom: 2px solid #8a98a3;
    transform: rotate(45deg);
    transition: transform .2s ease;
    margin-left: 8px;
    flex-shrink: 0;
}
.ppf-section.ppf-collapsed .ppf-section-toggle {
    transform: rotate(-45deg);
}
.ppf-section-body {
    overflow: hidden;
    max-height: 1000px;
    transition: max-height .25s ease, opacity .2s ease;
    opacity: 1;
}
.ppf-section.ppf-collapsed .ppf-section-body {
    max-height: 0 !important;
    opacity: 0;
    pointer-events: none;
}

/* ── Mobile filter toggle / close (show-hide only, no drawer styling) ── */
.ppf-mobile-toggle { display: none; }
.ppf-mobile-overlay { display: none; }
.ppf-mobile-close { display: none; }
@media (max-width: 991px) {
    .ppf-mobile-toggle { display: inline-flex; align-items: center; gap: 6px; cursor: pointer; }
    .ppf-mobile-close { display: inline-flex; cursor: pointer; }
    .ppf-sidebar:not(.ppf-open) { display: none; }
    /* .ppf-mobile-overlay.active { display: block; position: fixed; inset: 0; background: rgba(0,0,0,.4); z-index: 9998; } */
    
    /* .ppf-mobile-toggle { display: none; }
    .ppf-mobile-close { display: none; } */
    
}

/* ── Loading overlay (full page) ── */
.ppf-fullpage-loader {
    display: none;
    position: fixed;
    inset: 0;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, .7);
    -webkit-backdrop-filter: blur(2px);
    backdrop-filter: blur(2px);
    z-index: 99999;
}
.ppf-fullpage-loader.active { display: flex; }

.ppf-fullpage-loader-inner {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 18px 26px;
    font-size: 15px;
    color: #555;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 6px 24px rgba(0,0,0,.15);
}

.ppf-spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(27,59,83,.2);
    border-top-color: #1b3b53;
    border-radius: 50%;
    animation: ppf-spin .7s linear infinite;
}
@keyframes ppf-spin { to { transform: rotate(360deg); } }

/* ── Products grid wrapper ── */
.ppf-products-wrap {
    position: relative;
    min-height: 200px;
}
.ppf-products-wrap.ppf-busy .ppf-grid {
    opacity: .4;
    pointer-events: none;
    transition: opacity .3s;
}

/* ── Toolbar (legacy / fallback selectors) ── */
.ppf-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 18px;
    flex-wrap: wrap;
    gap: 10px;
}
.ppf-result-count {
    font-size: 20px;
    color: #666;
    margin: 0;
}

/* ── Toolbar (filter_bar layout — matches theme markup) ── */
.filter_bar.ppf-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 12px;
    margin-bottom: 18px;
}
.filter_bar .filter_left p.ppf-result-count {
    margin: 0;
    font-size: 20px;
    color: #666;
}
.filter_bar .filter_right {
    display: flex;
    align-items: center;
    gap: 18px;
    flex-wrap: wrap;
}
.filter_bar .input-group.select-box {
    display: flex;
    align-items: center;
    gap: 8px;
}
.filter_bar .input-group.select-box span {
    font-size: 20px;
    color: #555;
    white-space: nowrap;
}
.filter_bar .view_btn {
    display: flex;
    align-items: center;
    gap: 0px;
}
.filter_bar .view_btn span {
    font-size: 20px;
    color: #555;
    white-space: nowrap;
}
.filter_bar .ppf-view-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 6px;
    transition: background .15s;
    opacity: .5;
}
.filter_bar .ppf-view-toggle:hover { background: #f3f5f7; }
.filter_bar .ppf-view-toggle.active { opacity: 1; background: #f3f5f7; }
.filter_bar .ppf-view-toggle.active svg path { fill: #FFCA2C; }
.filter_bar .ppf-view-toggle svg { display: block; }
.filter_bar .ppf-view-toggle svg path { fill: #555555; }

/* ── List view layout ── */
#ppf-product-grid.ppf-list-view {
    display: flex;
    flex-direction: column;
    gap: 0;
}
#ppf-product-grid.ppf-list-view > [class*="col-"] {
    width: 100% !important;
    max-width: 100% !important;
    flex: 0 0 100% !important;
    padding: 0;
    margin-bottom: 12px;
}
#ppf-product-grid.ppf-list-view .featured-box {
    display: flex;
    flex-direction: row;
    align-items: stretch;
    gap: 0;
    border-radius: 10px;
    overflow: hidden;
    border: 1px solid #e8edf0;
    background: #fff;
    min-height: 160px;
}
#ppf-product-grid.ppf-list-view .product-image-wrap {
    flex: 0 0 200px;
    width: 200px;
    min-height: 160px;
    position: relative;
    background: #f5f7f9;
    overflow: hidden;
}
#ppf-product-grid.ppf-list-view .product-image-wrap_main {
    display: block;
    width: 100%;
    height: 100%;
}
#ppf-product-grid.ppf-list-view .product-image-wrap_main img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
#ppf-product-grid.ppf-list-view .sale-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    z-index: 2;
}
#ppf-product-grid.ppf-list-view .product-info {
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 20px 24px;
    position: relative;
}
#ppf-product-grid.ppf-list-view .featured_cart-btn {
    position: absolute;
    bottom: 20px;
    right: 20px;
}

/* ── Apply button ── */
.ppf-apply-btn {
    display: block;
    width: 100%;
    background: #1b3b53;
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 13px 20px;
    font-size: 15px;
    font-weight: 700;
    letter-spacing: .04em;
    cursor: pointer;
    margin-top: 24px;
    transition: background .2s, transform .15s;
    text-align: center;
}
.ppf-apply-btn:hover {
    background: #0f2744;
    transform: translateY(-1px);
}

/* ── Active filter tags ── */
.ppf-active-filters { margin-top: 10px; }

#ppf-active-tags-wrap,
.ppf-active-tags,
.ppf-active-tags-bar {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 6px !important;
    margin: 8px 0 14px !important;
    align-items: center !important;
    width: auto !important;
    padding: 0 !important;
    background: none !important;
    border: none !important;
    box-shadow: none !important;
}

.ppf-active-tag,
#ppf-active-tags-wrap .ppf-active-tag {
    display: inline-flex !important;
    align-items: center !important;
    gap: 4px !important;
    background: #fff !important;
    color: #1b3b53 !important;
    border: 1.5px solid #c8d5de !important;
    border-radius: 999px !important;
    padding: 4px 8px 4px 12px !important;
    font-size: 12px !important;
    font-weight: 600 !important;
    line-height: 1.4 !important;
    white-space: nowrap !important;
    box-shadow: 0 1px 3px rgba(0,0,0,.06) !important;
    width: auto !important;
    max-width: none !important;
    min-width: 0 !important;
    flex: 0 0 auto !important;
    box-sizing: border-box !important;
}

.ppf-remove-tag,
#ppf-active-tags-wrap .ppf-remove-tag {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    background: #dde6ec !important;
    border: none !important;
    border-radius: 50% !important;
    color: #1b3b53 !important;
    cursor: pointer !important;
    width: 16px !important;
    height: 16px !important;
    font-size: 13px !important;
    line-height: 1 !important;
    padding: 0 !important;
    transition: background .15s, color .15s !important;
    flex-shrink: 0 !important;
    min-width: 0 !important;
    max-width: none !important;
}
.ppf-remove-tag:hover,
#ppf-active-tags-wrap .ppf-remove-tag:hover {
    background: #1b3b53 !important;
    color: #fff !important;
}

.ppf-clear-all,
#ppf-active-tags-wrap .ppf-clear-all {
    display: inline-flex !important;
    align-items: center !important;
    background: #eb2530 !important;
    color: #fff !important;
    border-radius: 999px !important;
    padding: 4px 14px !important;
    font-size: 12px !important;
    font-weight: 700 !important;
    text-decoration: none !important;
    transition: background .2s !important;
    white-space: nowrap !important;
    width: auto !important;
    flex: 0 0 auto !important;
    border: none !important;
    box-shadow: none !important;
}
.ppf-clear-all:hover,
#ppf-active-tags-wrap .ppf-clear-all:hover {
    background: #c91f2a !important;
    color: #fff !important;
    text-decoration: none !important;
}

/* ── Category count ── */
.ppf-count {
    color: #999;
    font-size: 11px;
    margin-left: 3px;
}

/* ── Parent/child category hierarchy indent (frontend filter) ── */
.ppf-cat-child {
    padding-left: 22px !important;
    position: relative;
}
.ppf-cat-child::before {
    content: "";
    position: absolute;
    left: 8px;
    top: 50%;
    width: 8px;
    height: 1px;
    background: #c9c9c9;
}

/* ── Price range slider (pristine — byte-identical to original, not touched) ── */
.ppf-range-slider {
    position: relative;
    height: 6px;
    margin: 18px 0 10px;
}
.ppf-slider-track {
    position: absolute;
    width: 100%;
    height: 6px;
    background: #e0e0e0;
    border-radius: 3px;
    top: 0;
}
.slider-range {
    position: absolute;
    height: 6px;
    background: #e8a000;
    border-radius: 3px;
    top: 0;
}
.ppf-range-slider input[type="range"] {
    position: absolute;
    width: 100%;
    height: 6px;
    top: 0;
    background: transparent;
    -webkit-appearance: none;
    pointer-events: none;
    z-index: 2;
}
.ppf-range-slider input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #e8a000;
    border: 2px solid #fff;
    box-shadow: 0 1px 4px rgba(0,0,0,.25);
    pointer-events: all;
    cursor: pointer;
    margin-top: -6px;
    transition: background .2s;
}
.ppf-range-slider input[type="range"]::-webkit-slider-thumb:hover { background: #d49000; }
.ppf-range-slider input[type="range"]::-moz-range-thumb {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #e8a000;
    border: 2px solid #fff;
    box-shadow: 0 1px 4px rgba(0,0,0,.25);
    pointer-events: all;
    cursor: pointer;
}
.ppf-range-slider input[type="range"]::-webkit-slider-runnable-track { height: 6px; }

/* ── Dimension range slider — scoped entirely under the existing .ppf-dim-slider wrapper class
     (already present in the HTML; no markup or class changes). Does not touch .range-slider,
     .ppf-slider-track, or the unscoped .slider-range — those remain exactly as above, so the
     Price slider's CSS and appearance are completely unaffected by this block. Same visual
     values (track gray, fill/thumb #e8a000) so Dimensions matches Price exactly. ── */
.ppf-dim-slider .slider-track {
    position: absolute;
    width: 100%;
    height: 6px;
    background: #e0e0e0;
    border-radius: 3px;
    top: 0;
}
.ppf-dim-slider .slider-range {
    position: absolute;
    height: 6px;
    background: #e8a000;
    border-radius: 3px;
    top: 0;
}
.ppf-dim-slider input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #e8a000;
    border: 2px solid #fff;
    box-shadow: 0 1px 4px rgba(0,0,0,.25);
    pointer-events: all;
    cursor: pointer;
    margin-top: -6px;
    transition: background .2s;
}
.ppf-dim-slider input[type="range"]::-webkit-slider-thumb:hover { background: #d49000; }
.ppf-dim-slider input[type="range"]::-moz-range-thumb {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: #e8a000;
    border: 2px solid #fff;
    box-shadow: 0 1px 4px rgba(0,0,0,.25);
    pointer-events: all;
    cursor: pointer;
}

/* ── Pagination ── */
.ppf-pagination {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 4px;
    margin-top: 32px;
    align-items: center;
}
.ppf-page-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 36px;
    height: 36px;
    padding: 0 10px;
    border: 1.5px solid #d1d9e0;
    border-radius: 6px;
    background: #fff;
    color: #333;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all .2s;
    width: auto !important;
    max-width: none !important;
    flex: 0 0 auto !important;
    box-sizing: border-box;
}
.ppf-page-btn:hover,
.ppf-page-btn.active {
    background: #1b3b53;
    border-color: #1b3b53;
    color: #fff;
}
.ppf-page-btn.ppf-prev,
.ppf-page-btn.ppf-next {
    font-size: 18px;
    color: #555;
}
.ppf-page-btn.disabled {
    opacity: .35;
    cursor: not-allowed;
    pointer-events: none;
}
.ppf-ellipsis {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    color: #999;
    font-size: 14px;
}

/* ── No results ── */
.ppf-no-results {
    text-align: center;
    padding: 60px 20px;
    color: #777;
    width: 100%;
}
.ppf-no-results svg {
    display: block;
    margin: 0 auto 16px;
    opacity: .3;
}

/* ── Dimension inputs ── */
.product_filter_dimension_fields {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
}
.product_filter_dimension_fields input {
    width: 100%;
    border: 1px solid #d1d9e0;
    border-radius: 8px;
    padding: 10px 12px;
    font-size: 20px;
    color: #111;
    background: #fff;
    outline: none;
    transition: border-color .15s;
    box-sizing: border-box;
}
.product_filter_dimension_fields input:focus {
    border-color: #1b3b53;
    box-shadow: 0 0 0 3px rgba(27,59,83,.1);
}

/* ── Reset button ── */
.ppf-reset-link,
#ppf-filter-form .ppf-reset-link,
a.ppf-reset-link {
    display: inline-flex !important;
    align-items: center !important;
    gap: 5px !important;
    background: none !important;
    color: #1b3b53 !important;
    border: 1.5px solid #1b3b53 !important;
    border-radius: 6px !important;
    padding: 6px 14px !important;
    font-size: 12px !important;
    font-weight: 600 !important;
    text-decoration: none !important;
    cursor: pointer !important;
    transition: background .2s, color .2s !important;
    width: auto !important;
    white-space: nowrap !important;
    letter-spacing: .03em !important;
    text-transform: uppercase !important;
}
.ppf-reset-link:hover,
#ppf-filter-form .ppf-reset-link:hover {
    background: #1b3b53 !important;
    color: #fff !important;
    text-decoration: none !important;
}