/* Sidebar flottante pour les filtres */
.filter-sidebar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9999;
    visibility: hidden !important;
    opacity: 0 !important;
    pointer-events: none !important;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.filter-sidebar.active {
    visibility: visible !important;
    opacity: 1 !important;
    pointer-events: auto !important;
}

.filter-sidebar-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    cursor: pointer;
}

.filter-sidebar-content {
    position: absolute;
    top: 0;
    left: 0;
    width: 400px;
    max-width: 90%;
    height: 100%;
    background-color: #FCF7F7;
    box-shadow: 2px 0 10px rgba(0, 0, 0, 0.1);
    transform: translateX(-100%);
    transition: transform 0.3s ease;
    display: flex;
    flex-direction: column;
    border-top-right-radius: 23px;
    border-bottom-right-radius: 23px;
    padding: 31px 20px 50px;
}

.filter-sidebar-header h3{
    font-family: "Josefin Sans", sans-serif;
    font-weight: 400;
    font-size: 24px;
    line-height: 1;
    letter-spacing: 7px;
    text-align: center;
    text-transform: uppercase;
}

.filter-sidebar.active .filter-sidebar-content {
    transform: translateX(0);
}

.filter-sidebar-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #97979726;
    flex-shrink: 0;
    padding: 0;
    padding-bottom: 22px;
}

.filter-sidebar-header h3 {
    margin: 0;
    font-size: 1.5rem;
    font-weight: 600;
    color: #173036;
}

.close-filter-sidebar {
    background: none;
    border: none;
    cursor: pointer;
    padding: 5px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.2s;
}

.close-filter-sidebar:hover {
    opacity: 0.7;
}

.close-filter-sidebar svg {
    width: 20px;
    height: 20px;
}

.filter-sidebar-body {
    flex: 1;
    overflow-y: auto;
    padding: 0;
    padding-top: 30px;
}

/* Afficher tous les filtres dans la sidebar */
.filter-sidebar-body .PM_ASCriterionsGroup,
.filter-sidebar-body .PM_ASShowCriterionsGroupHidden ~ .PM_ASCriterionsGroup{
    display: block !important;
    width: 100%;
    max-width: unset;
}

.filter-sidebar-body .PM_ASCriterionsOutput.livraison_garantie_avant_noel_ .PM_ASCriterionsGroupOuter .custom-checkbox label{
    max-width: unset;
}

.filter-sidebar-body .PM_ASCriterionsGroupTitle{
    font-family: "Lato", sans-serif;
    font-weight: 900;
    font-size: 16px;
    margin-bottom: 27px;
}

.filter-sidebar-body  .PM_ASCriterionsGroupName{
    font-family: "Lato", sans-serif;
    font-weight: 900;
    font-size: 16px;
    line-height: 1;
    letter-spacing: 2px;
}

.filter-sidebar-body  .PM_ASCriterionsGroupTitle .mp-arrow-regular-down,
.filter-sidebar-body  .PM_ASCriterionsGroupTitle .count{
    display: none;
}

.filter-sidebar-body .PM_ASCriterionsGroupOuter{
    display: block !important
}

.filter-sidebar-body .PM_ASCriterionGroupCheckbox li:not(:last-child){
    margin-bottom: 15px;
}

.filter-sidebar-body .PM_ASCriterionGroupCheckbox li .custom-checkbox input[type="checkbox"]+span+p,
.filter-sidebar-body .PM_ASCriterionsOutput.livraison_garantie_avant_noel_ .PM_ASCriterionsGroupOuter .custom-checkbox input[type="checkbox"]+span+p,
.filter-sidebar-body .PM_ASCritRangeValue{
    font-family: "Lato", sans-serif;
    font-weight: 400;
    font-size: 16px;
    line-height: 1;
    letter-spacing: 2px;

}

.filter-sidebar-body .PM_ASCriterionsOutput.livraison_garantie_avant_noel_ .PM_ASCriterionsGroupOuter .custom-checkbox input[type="checkbox"]+span,
.filter-sidebar-body .custom-checkbox input[type="checkbox"]+span{
    width: 30px;
    height: 30px;
    margin-right: 19px;
}

.filter-sidebar-body .custom-checkbox input[type="checkbox"]+span+p {
    width: calc(100% - 49px);
}

.filter-sidebar-body .PM_ASCriterionsGroup{
    padding-bottom: 30px;
    margin-bottom: 30px;
    border-bottom: 1px solid #97979726;
}
.filter-sidebar-body .PM_ASCriterionsGroup:last-child{
    margin-bottom: 0;
    border-bottom: none;
}

.filter-sidebar-body select.form-control{
    border: 1px solid #1730364D;
    border-radius: 40px;
    font-family: "Lato", sans-serif;
    font-weight: 400;
    font-size: 16px;
    line-height: 1;
    letter-spacing: 2px;
    padding: 9px 45px 10px 25px;
    height: 39px;
    background-position: right 25px center;
    background-position-y: 12px;
}

.filter-sidebar-footer{
    display: flex;
    justify-content: space-between;
    align-content: center;
    gap: 20px;
    padding-top: 30px;
    border-top: 1px solid #97979726;
}
.filter-sidebar-footer .btn{

}

.PM_ASShowCriterionsGroupHidden ~ .PM_ASCriterionsGroup{
    display: none !important;
}

/* Masquer le bouton "Plus de filtres" dans la sidebar */
.filter-sidebar-body .PM_ASShowCriterionsGroupHidden {
    display: none !important;
}
.filter-sidebar.active + .PM_ASBlockOutput .PM_ASShowCriterionsGroupHidden{
    display: none;
}

/* Responsive */
@media (max-width: 768px) {
    .filter-sidebar-content {
        width: 320px;
    }
}
