.woo-filter-container {
    position: fixed;
    top: 0;
    left: 100%;
    height: 100%;
    width: 400px;
    max-width: 90%;
    display: flex;
    flex-direction: column;
    background-color: #fff;
    z-index: 9999;
    padding: var(--wp--preset--spacing--15) 0 var(--wp--preset--spacing--15) var(--wp--preset--spacing--15);
    transform: translateX(0);
    transition: transform 0.2s ease-in-out;
}

.woo-filter-container.is-open {
    transform: translateX(-100%);
}

.admin-bar .woo-filter-container {
    top: 32px;
}

/* Header */
.woo-filter-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 1rem;
    padding-right: var(--wp--preset--spacing--15);
}

.woo-filter-header > * {
    margin: 0;
}

/* Content */
.woo-filter-content {
    flex-grow: 1;
    overflow: auto;
    padding-right: var(--wp--preset--spacing--15);
}

/* Footer */
.woo-filter-footer {
    display: flex;
    justify-content: space-between;
    padding-top: var(--wp--preset--spacing--15);
    padding-right: var(--wp--preset--spacing--15);
}

.admin-bar .woo-filter-footer {
    padding-bottom: 32px; 
}

@media (max-width: 782px) {
    .admin-bar .woo-filter-footer {
        padding-bottom: 46px;
    }
}

/* Overlay */

#woo-filter-overlay {
    position: fixed;
    top: 0;
    left: 0;
    height: 100%;
    width: 100%;
    background-color: rgba(0, 0, 0, 0.3);
    opacity: 0;
    visibility: hidden;
    z-index: 9998;
    transition: opacity 0.2s ease-in-out;
}

#woo-filter-overlay.is-open {
    opacity: 1;
    visibility: visible;
}

/* Attribute accordions */
.woo-filter-attribute {
    margin-bottom: 1rem;
    border-bottom: 1px solid #cccccc;
}

.woo-filter-attribute__header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 1rem;
    cursor: pointer;
}

.woo-filter-attribute__toggle {
    display: flex;
    align-items: center;
    padding: .6rem;
    background-color: transparent;
    border: unset;
    cursor: pointer;
}

.woo-filter-attribute__toggle img {
    transition: transform 0.2s ease-in-out;
    will-change: transform;
}

.woo-filter-attribute__toggle[aria-expanded="true"] img {
    transform: rotate(45deg);
}

.woo-filter-attribute__terms {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s cubic-bezier(0.5, 0, 0, 1) 0s;
}
/* Buttons */
.woo-filter-btn {
    appearance: none;
    border: 0;
    padding: var(--wp--preset--spacing--05) var(--wp--preset--spacing--10);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: .5rem;
    transition: background-color .1s ease-in-out, color .1s ease-in-out;
}

.woo-filter-btn img {
    transition: filter .1s ease-in-out;
}

.primary-btn {
    background-color: var(--wp--preset--color--primary);
    color: var(--wp--preset--color--white);
}

.outline-btn {
    background-color: var(--wp--preset--color--white);
    border: 1px solid var(--wp--preset--color--black);
}

.outline-btn:hover {
    background-color: var(--wp--preset--color--black);
    color: var(--wp--preset--color--white);
}

.text-btn {
    background-color: transparent;
    color: var(--wp--preset--color--text-color-dark);
}

.text-btn:hover {
    background-color: var(--wp--preset--color--primary);
    color: var(--wp--preset--color--white);
}
.text-btn:has(img):hover img {
    filter: invert(1);
}

.woo-filter-attribute__toggle.woo-filter-btn {
    padding: var(--wp--preset--spacing--05) 0 var(--wp--preset--spacing--05) var(--wp--preset--spacing--10);
}

/* Swatches */

.woo-filter-swatches {
    display: flex;
    flex-wrap: wrap;
    gap: 0.875rem;
    padding: .2rem 0 1rem 0.2rem;
}

.woo-filter-swatch {
    width: 1.5rem;
    height: 1.5rem;
    border-radius: 50%;
    border: 0;
    position: relative;
    margin: 0;
    padding: 0;
    display: block;
    box-shadow: 0 0 4px rgba(0, 0, 0, 0.4);
    appearance: none;
    cursor: pointer;
}

.woo-filter-swatch::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 125%;
    height: 125%;
    border: 1px solid #000;
    border-radius: 50%;
    opacity: 0;
    pointer-events: none;
}

.woo-filter-swatch[data-selected="true"]::after {
    opacity: 1;
}

/* Checkboxes */
.woo-filter-checkboxes {
    display: flex;
    flex-wrap: wrap;
    gap: var(--wp--preset--spacing--10);
    padding-bottom: 1rem;
}

.woo-filter-checkbox {
    flex: 0 0 calc(50% - 1rem);
}

.woo-filter-checkbox label {
    height: 100%;
    display: flex;
    gap: .5rem;
    position: relative;
    cursor: pointer;
    margin: 0;
    align-items: center;
}
.woo-filter-checkbox input {
    border: 1px solid #000;
    min-width: 1.375rem;
    width: 1.375rem;
    height: 1.375rem;
    margin: 0 !important;
    padding: 0 !important;
    appearance: none;
}

.woo-filter-checkbox .checkmark {
    position: absolute;
    background-color: #000;
    height: 1rem;
    width: 1rem;
    left: calc(1.375rem / 2);
    top: 50%;
    transform: translate(-50%, -50%);
    opacity: 0;
}

.woo-filter-checkbox input:checked ~ .checkmark {
    opacity: 1;
}

@media only screen and (max-width: 782px) {
    .admin-bar .woo-filter-container {
        top: 46px;
    }
}

/* Range slider */
.woo-filter-slider-values {
    display: flex;
    justify-content: space-between;
    padding-top: var(--wp--preset--spacing--05);
    padding-bottom: var(--wp--preset--spacing--10);
}

.woo-filter-slider-values input {
    max-width: 80px;
    padding: 5px 8px;
    border-radius: 4px;
    border: 1px solid var(--wp--preset--color--black);
}

/* Tags */
#woo-filter-active {
    display: flex;
    flex-wrap: wrap;
    gap: var(--wp--preset--spacing--05);
}

.woo-filter-active__filter {
    display: flex;
    align-items: center;
    padding: 0 .5rem;
    background-color: transparent;
    border-radius: 8px;
    border: 1px solid var(--wp--preset--color--light-grey);
}

.woo-filter-active__filter__remove {
    display: flex;
    justify-content: center;
    align-items: center;
    appearance: none;
    background: transparent;
    border: 0;
    padding: 5px 0 5px 8px;
    font-size: var(--wp--preset--font-size--small);
    font-family: var(--wp--preset--font-family--heading);
}

/* WooCommerce overrides */
.wc-block-components-price-slider--is-input-inline .wc-block-components-price-slider__controls .wc-block-components-price-slider__amount {
    max-width: 70px;
}

.wc-block-components-price-slider__range-input-wrapper {
    margin: 15px 2px;
}

/* NoUiSlider overrides */
.noUi-target {
    background: transparent;
    border-radius: unset;
    border: none;
    box-shadow: none;
    display: flex;
    justify-content: center;
    align-items: center;
}

.noUi-base {
    height: 4px;
    margin: 0 18px 0 6px;
}

.noUi-horizontal .noUi-handle {
    border: 3px solid var(--wp--preset--color--black);
    border-radius: 50%;
    background: #FFF;
    cursor: default;
    box-shadow: none;
    width: 22px;
    height: 22px;
    top: -9px;
}

.noUi-handle:after, 
.noUi-handle:before {
    content: none;
    display: none;
}

.noUi-horizontal {
    height: 30px;
}

.noUi-connect {
    background: var(--wp--preset--color--black);
}