/* Search toolbar + mobile filter drawer */

.new-wrapper .search-toolbar {
    position: relative;
}

.new-wrapper .search-toolbar-filters {
    display: none;
}

@media (min-width: 992px) {
    .new-wrapper .search-toolbar-filters {
        display: block !important;
    }
}

.new-wrapper .search-toolbar-filter {
    display: inline-block;
    margin-right: 0.5rem;
}

.new-wrapper .search-toolbar-filter.is-active .discover-menu__trigger--bordered,
.new-wrapper #search-filter-toggle.is-active {
    border-color: #365f98;
}

.new-wrapper #search-filter-toggle.is-active {
    background: #e8f4fc;
}

.new-wrapper .search-toolbar-dropdown {
    min-width: 280px!important;
    max-width: 360px;
    max-height: 420px;
    overflow: auto;
    padding: 0.75rem;
}

.new-wrapper .search-toolbar-dropdown .filter-title {
    display: none;
}

.new-wrapper .search-toolbar-dropdown .filter-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.new-wrapper .search-toolbar-dropdown .filter-list.checkbox .filter-list-item {
    align-items: center;
    border-radius: 8px;
    transition: background-color 0.2s ease;
}

.new-wrapper .search-toolbar-dropdown .filter-list.checkbox .filter-list-content label {
    font-weight: 600;
}

.new-wrapper .search-toolbar-dropdown .filter-price-submit {
    text-transform: none;
}

.new-wrapper .search-filter-panels {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.new-wrapper .search-category-chips__box {
    border-radius: 14px;
    background: #e8f4fc;
    padding: 0.75rem;

}

.new-wrapper .search-category-chips__heading {
    margin: 0 0 0.75rem;
    font-weight: 600;
    color: #163751;
    font-family: Montserrat, Arial, sans-serif;
}

.new-wrapper .search-category-chips__pills {
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
    gap: 0.65rem;
    margin: 0;
    width: max-content;
}

.new-wrapper .search-category-chips__more {
    border: 0;
    cursor: pointer;
    color: #fff;
    background: #163751;
    white-space: nowrap;
}

@media (max-width: 991.98px) {
    .new-wrapper .search-category-chips__pill--desktop-only {
        display: none !important;
    }
}

@media (min-width: 992px) {
    .new-wrapper .search-category-chips__more {
        display: none !important;
    }
}

.new-wrapper .discover-menu__trigger-icon .search-filter-icon {
    display: block;
    width: 18px;
    height: 18px;
}

.discover-mobile__row .search-filter-icon {
    display: block;
    flex-shrink: 0;
    width: 24px;
    height: 24px;
}

/* Mobile drawer */
body.search-filter-mobile-open {
    overflow: hidden;
}

.search-filter-mobile {
    position: fixed;
    inset: 0;
    z-index: 2100;
    pointer-events: none;
}

.search-filter-mobile.open {
    pointer-events: auto;
}

.search-filter-mobile__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 39, 58, 0.45);
    opacity: 0;
    transition: opacity 0.25s ease;
    cursor: pointer;
}

.search-filter-mobile.open .search-filter-mobile__backdrop {
    opacity: 1;
}

.search-filter-mobile__drawer {
    position: absolute;
    top: 0;
    right: 0;
    display: flex;
    flex-direction: column;
    width: 100%;
    max-width: 420px;
    height: 100dvh;
    background: #fff;
    border-left: 1px solid #d4e1ea;
    box-shadow: -12px 0 40px rgba(15, 39, 58, 0.14);
    transform: translateX(100%);
    transition: transform 0.3s ease;
}

.search-filter-mobile.open .search-filter-mobile__drawer {
    transform: translateX(0);
}

.search-filter-mobile__screens {
    display: flex;
    flex: 1;
    flex-direction: column;
    min-height: 0;
    overflow: hidden;
}

.search-filter-mobile__screen {
    display: none;
    flex: 1;
    flex-direction: column;
    min-height: 0;
    overflow: hidden;
}

.search-filter-mobile__screen.is-active {
    display: flex;
}

.search-filter-mobile__screen .discover-mobile__subheader {
    padding-left: 1rem;
    padding-right: 1rem;
}

.search-filter-mobile__screen .discover-mobile__panel-body {
    flex: 1;
    min-height: 0;
    padding: 1rem 1.25rem;
    overflow-x: hidden;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}

.search-filter-mobile__panel .checkbox-container,
.search-filter-mobile__panel .filter-collapse {
    min-height: 0;
}

.search-filter-mobile__panel .filter-list.checkbox {
    margin: 0;
    padding: 0;
    list-style: none;
}

.search-filter-mobile__panel .filter-list.checkbox:not(.checkbox-color) .filter-list-item {
    align-items: center;
    padding: 0.75rem 0;
    border-bottom: 1px solid #edf2f6;
    border-radius: 0;
}

.search-filter-mobile__panel .filter-list.checkbox:not(.checkbox-color) .filter-list-item:last-child {
    border-bottom: 0;
}

.search-filter-mobile__panel .filter-list.checkbox:not(.checkbox-color) .filter-list-item:active {
    background: #e8f4fc;
}

.search-filter-mobile__panel #size-wrapper.row {
    flex-direction: column;
    margin: 0;
}

.search-filter-mobile__panel #size-wrapper .col-6 {
    width: 100%;
    max-width: 100%;
    padding: 0;
}

.search-filter-mobile__footer {
    flex-shrink: 0;
    padding: 0.85rem 1rem;
    padding-bottom: max(0.85rem, env(safe-area-inset-bottom));
    border-top: 1px solid #edf2f6;
}

.search-filter-mobile__apply {
    display: block;
    width: 100%;
    padding: 0.85rem 1rem;
    border: 1px solid #dfe7f1;
    border-radius: 8px;
    background: #fff;
    color: #163751;
    font-family: Montserrat, Arial, sans-serif;
    font-size: 0.9375rem;
    font-weight: 700;
    text-align: center;
    cursor: pointer;
}

.search-filter-mobile__apply:active {
    background: #e8f4fc;
    border-color: #cfdded;
}

/* Filter content inside mobile drawer */
.search-filter-mobile__panel .filter-title {
    display: none !important;
}

.search-filter-mobile__panel .filter-wrapper {
    border: 0;
    padding: 0;
    margin: 0;
}

.search-filter-mobile__panel .filter-collapse,
.search-filter-mobile__panel .filter-collapse.collapse {
    display: block !important;
    height: auto !important;
    visibility: visible !important;
}

.search-filter-mobile__panel .filter-search {
    margin-bottom: 0.75rem;
    background: #fff;
}

.search-filter-mobile__panel .filter-price {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    margin-bottom: 0.75rem;
    justify-content: space-around
}

.filter-price-start-input,
.filter-price-end-input {
    max-width: 7rem;
    padding: 0.65rem 0.75rem;
    border: 1px solid #d4e1ea;
    border-radius: 8px;
    color: #163751;
}

.search-filter-mobile__panel .filter-price-submit {
    width: 100%;
    margin-top: 0.5rem;
    padding: 0.75rem;
    border: 0;
    border-radius: 8px;
    font-weight: 700;
    text-transform: none;
}

.search-filter-mobile__panel :is(.show-more, .togglemore) {
    margin-top: 0.75rem;
    margin-bottom: 0.25rem;
    padding: 0.75rem;
    font-size: 0.875rem;
}

@media (max-width: 575.98px) {
    .search-filter-mobile__drawer {
        max-width: none;
    }
}

@media (prefers-reduced-motion: reduce) {
    .search-filter-mobile__drawer,
    .search-filter-mobile__backdrop {
        transition: none;
    }
}
