body.page-template-template-carte-new{
    margin:0;
    
    small{
        display:block;
        margin-top:-10px;
        font-style: italic;
    }
    [type="checkbox"] + span:not(.lever){
        padding-left:25px;        
    }
    input[type="date"]:not(.browser-default):focus:not([readonly]){
        border-bottom:0;
        box-shadow: none;
    }
    
}
input[type="date"]:not(.browser-default){
    height:30px;
    margin:0;
    border:0;
    font-family: 'Lato', sans-serif;
    color:#000;
}
.filter-date::-moz-calendar-picker-indicator,
.filter-date::-webkit-calendar-picker-indicator {
    filter: invert(58%) sepia(19%) saturate(728%) hue-rotate(152deg) brightness(92%) contrast(90%);
 }

.officiel-map-container {
    display: flex;
    position:relative;
    /* height: 900px;*/
}
.filters-container {
    width: 310px;
    padding: 10px;    
    background: rgba(70, 150, 164, 0.32);
    box-shadow: 0px 0px 30px rgba(0, 0, 0, 0.2);
}
.date-filter{
    background: #FFFFFF;
    border: 2px solid #4696A4;
    border-radius: 19px;
    display:flex;
    margin-bottom:5px;
}

.date-filter > label{
    margin-right: 10px;
    width:120px;    
    text-align: center;
    background:#4696A4;
    color:#fff;
    display:block;
    font-weight: 700;
    font-size: 14px;
    line-height: 30px;
    text-transform: uppercase;    
    border-top-left-radius: 14px;
    border-bottom-left-radius: 14px;
    position:relative;
}

.date-filter > label:after{
    display: block;
    content:'';
    position: absolute;
    width: 8px;
    height: 8px;
    right: -4px;
    top: 11px;

    background: #4696A4;
    transform: rotate(45deg);

}


.establishments-list-wrapper {
    position: relative;
    border-right:1px solid #789FA9;
    /* transition: width 0.3s ease; */
}
.establishments-list-wrapper .tri-affichage{
    display:flex;
    justify-content: space-between;
}
.establishments-list-wrapper .tri, .establishments-list-wrapper .type-affichage{
    margin-top:10px;    
    display:flex;
    justify-content: start;
    align-items: center;
    gap:10px;    
    margin-left: 20px;    
}
.establishments-list-wrapper .type-affichage{
    margin-right:20px;
}

.establishments-list-wrapper .type-affichage img{
    opacity:0.6;
    cursor: pointer;
}
.establishments-list-wrapper .type-affichage #affiche-grid.sel img,
.establishments-list-wrapper .type-affichage #affiche-map.sel img{
    opacity:1;
}
.establishments-list-wrapper .type-affichage > div:first-child,
.establishments-list-wrapper .tri > div:first-child{
    color:#003941;
    font-size:14px;
}

.establishments-list-wrapper .tri label{
    color:#999;
    cursor:pointer; 
    font-size:16px !important;
    font-weight: bold;
}

.establishments-list-wrapper .tri input[type="radio"]:checked + label {   
    color:#000;   
    line-height: 20px;
}

.establishments-list-container {    
    width: 660px;
    height:1100px;
    padding: 20px;    
    overflow-y: auto;
}

.establishments-list-container > ul{
    display:grid;
    grid-template-columns: repeat(2, 1fr);
    gap:18px 16px;
}
.establishments-list-container.extended{
    width: 100%;
}

.establishments-list-container.extended > ul{
    grid-template-columns: repeat(3, 1fr);
}

.filter-tiles {
    filter: grayscale(100%);
   
}

#officiel-map {
    flex-grow: 1;
} 
.marker-cluster {
    background-clip: padding-box;
    border-radius: 20px;
  }
  
  .marker-cluster div {
    width: 30px;
    height: 30px;
    margin-left: 5px;
    margin-top: 5px;
    text-align: center;
    border-radius: 15px;
    font-size: 12px;
    font-weight: bold;
    display: flex;
    align-items: center;
    justify-content: center;
  }
  
.filter-group {
    margin-bottom: 20px;   
    padding:15px;
    padding-top:5px;
    background: #FFFFFF;
    border-bottom: 1px solid rgba(0, 0, 0, 0.25);
    border-radius: 6px;
}
.filter-group.triangle-up{
    position: relative;
    margin-top:15px;
}

.filter-group.triangle-up:before {
    content: '';
    position: absolute;
    top: -10px;
    left: 25%;
    transform: translateX(-50%);
    width: 0;
    height: 0;
    border-left: 10px solid transparent;
    border-right: 10px solid transparent;
    border-bottom: 10px solid white;
}
.filter-group.mini-cures{
    display:none;
}
.filter-group.mini-cures.triangle-up:before{
    left:75%;
}
.ascenseur{
    max-height:250px;
    overflow-y: auto;
    scrollbar-width: thin;          /* 'thin' ou 'auto' */
    scrollbar-color: #4696A4 #ccc;
}
.ascenseur::-webkit-scrollbar {
    width: 5px;  /* Largeur de l'ascenseur */
  }
  
.ascenseur::-webkit-scrollbar-thumb {
    background-color: #ccc;  /* Couleur de la "poignée" de l'ascenseur */
    border-radius: 1px;     /* Coins arrondis optionnels */
}
.ascenseur::-webkit-scrollbar-track {
    background: transparent; /* Fond transparent */
}
.ascenseur::-webkit-scrollbar-button {
    display: none;        /* Suppression des boutons haut/bas */
}

.lst-filter{
    display:flex;    
    gap:10px;
}

.filter-group h3 {
    color:#000;
    margin-bottom: 10px;
    font-size:18px;
    font-weight: bold;
    margin-top:5px;
}

.switch-container {
    width: 100%;
    display: flex;
    background-color: #4797A4;
    border-radius: 9999px;
    padding: 4px;
    user-select: none;
    margin-bottom:10px;
  }
  
  .switch-option {
    flex: 1;
    text-align: center;
    padding: 8px 4px;
    font-size: 14px;
    color: white;
    cursor: pointer;
    border-radius: 9999px;
    transition: all 0.2s ease-in-out;
    font-family: sans-serif;    
  }
  
  .switch-option.active {
    background-color: white;
    color: #003941;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    font-weight: bold;
  }
  .div-nb-results{
    display:none;
  }
input.filter-results{    
    display: none;
    margin:0 auto;
    background:#4696A4;
    color:#fff;
    padding:10px 20px;
    font-size: 16px;
    font-weight: 500;
    text-align: center;
    border:0;
    border-radius:20px;    
}
#establishments-list {
    list-style-type: none;
    padding: 0;
    margin:0;
}
#establishments-list li {   
    cursor: pointer;
    border:1px solid rgb(216, 216, 216);
    padding-bottom:10px;
    border-radius:8px;
    border-bottom: 2px solid rgba(0, 0, 0, 0.2);
    box-shadow: 0px 2px 5px rgba(0, 0, 0, 0.25);
   
}
#establishments-list  li.partner{
    background-color: #ffcc00;
    border-bottom: 2px solid rgba(0, 0, 0, 0.2);
    box-shadow: 0px 2px 5px rgba(0, 0, 0, 0.25);
}
#establishments-list li img.estab-img {
    width: 100%;
    height: 185px;
    object-fit: cover;   
    border-top-left-radius: 8px;
    border-top-right-radius: 8px;
}


.establishment-info {
    display: block;
    padding: 10px 15px;
}
#establishments-list li a {
    font-weight: bold;
    text-decoration: none;
    color: #003941;
}
#establishments-list li p {
    margin: 5px 0 0;
    font-size: 0.7em;
    color: #000;
}
#establishments-list li p span{
    color:#003941;
}
.establishment-popup,
#establishments-list li{
    span.tag{
        background:#4696A4;
        padding:4px 8px;
        color:#fff;
        text-transform: uppercase;
        font-size:11px;
        border-radius: 3px;;
    }
}
.map-tooltip {
    font-size: 16px;
    font-weight: bold; 
}
.leaflet-tooltip {
    border-radius: 8px;
}
.filter-label {
    display: flex;
    align-items: center;    
}
.filter-checkbox {
    margin-right: 5px;
}
.filter-text {
    color:#444;
    transition: font-weight 0.3s ease;
    font-size:15px !important;
    height: inherit !important;
}
.filter-checkbox:checked + .filter-text {
    font-weight: bold;
    color:#4696a4;
}
select.filter-select{
    display:block;
    border: 2px solid #4696A4;
    border-radius: 19px;
    height:2rem;
    margin-bottom:10px;    
    padding: 8px 15px;    
    font-size: 14px;        
    cursor: pointer;
    outline: none; 
    appearance: none;
}

div.map-select{
    position:relative;
}
div.map-select:after{
    z-index:0;
    display: block;
    content:'';
    position: absolute;
    width: 0;
    height: 0;
    right:15px;
    top:15px;
    border-left: 6.5px solid transparent;
    border-right: 6.5px solid transparent;
    border-top: 8px solid #003941;

}
.titre-inter {
    font-size:20px;
    display: inline-block;
    margin-bottom: 10px;
    text-decoration: none;
    color: #000000;
    font-weight: bold;
}
.titre-filter{
    display:flex;
    justify-content: space-between;
    align-items: center;
}
#clear-filters {
    font-size: 14px;
    color: #000;
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

#clear-filters.has-filters {
    background-color: #000;
    color: #fff;
    padding: 5px;
    padding-left:10px;
    border-radius: 15px;
    font-weight: 400;
}

#clear-filters:hover {
    text-decoration: underline;
}

.filter-count {
    margin-right: 5px;
}

.filter-close {
    display: inline-flex;
    justify-content: center;
    line-height:20px;
    width:20px;
    height:20px;
    font-size: 18px;
    font-weight: bold;
    margin-left: 5px;
    cursor: pointer;
    color:#000;
    background:#fff;
    border-radius:30px;
}

.toggle-list-btn {
    position: absolute;
    top: 550px;
    right: -30px;
    width: 30px;
    height: 60px;
    background-color: #fff;

    border-width: 1px 1px 1px 0px;
    border-style: solid;
    border-color: #789FA9;
    border-radius: 0px 8px 8px 0px;   

    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 1000;

}
.toggle-list-btn > span{
    width: 0;
    height: 0;
    border-top: 7px solid transparent;
    border-bottom: 7px solid transparent;
    border-right: 8px solid #4696a4;
}
.establishments-list-wrapper.folded {
    width: 0;
}
.establishments-list-wrapper.folded .establishments-list-container {
    width: 0;
    padding: 0;
    overflow: hidden;
}
.establishments-list-wrapper.folded .toggle-list-btn {
    right: -30px;    
}
.establishments-list-wrapper.folded .toggle-list-btn {
    span{
        transform: rotate(180deg);
    }
}
.establishments-list-wrapper .onglet-liste{
    display: none;
}
.leaflet-popup-content-wrapper{
    padding:0;
}
.leaflet-popup-content{
    margin:0;
}
.leaflet-popup-content div.inner{
    padding:20px;
    padding-top:5px;
}
.leaflet-popup-content .establishment-popup{    
    font-size:14px;
}
.leaflet-popup-content p{
    margin:5px 0;
}
.leaflet-popup-content ul{
    margin:0;
    padding:0;
}
.leaflet-popup-content ul li{
    list-style-type: disc;
}
.establishment-popup .lst-orientation{
    padding:0 !important;
    margin-top:15px;
}
.establishment-popup .lst-orientation li{
    list-style-type: none;
    background-image: url('/wp-content/uploads/2025/02/fleche-etab.svg');
    background-repeat: no-repeat;
    background-position: left center;
    padding-left: 20px;
    margin-bottom:10px;
    color:#003941;
    font-size:14px;
    font-weight: bold;
}
.establishment-popup img{    
    width:100%;
    height: 194px !important;
    object-fit: cover;
    object-position: center center;
    border-top-left-radius: 8px;
    border-top-right-radius: 8px;
}
.establishment-popup h6{    
    color:#000;
}
.leaflet-container a.leaflet-popup-close-button{
    background: #fff;
    border-radius: 20px;
    width: 20px;
    height: 20px;
    padding: 0;
    line-height: 20px;
    top: 10px;
    right: 10px;
    color:#000;
}
.leaflet-container a.btn-std{
    color:#fff;
    margin-bottom: 10px;
    border-radius: 8px;
    background-color: #003941;
    font-size:15px;
}
.leaflet-container a.btn-std.ctc{
    background-color: #FFCC00;
    color:#003941;
}

.leaflet-marker-icon:hover{
    opacity: 0.6;
}

/* Styles for mobile filter toggle */
.mobile-filter-switch{
    display:none;
}
.mobile-switch,
.mobile-filter-toggle {
    background-color: #003941;
    color: white;
    padding: 10px;
    text-align: center;
    cursor: pointer;
    border-radius: 8px;
}

@keyframes bounce {
    0% {
        margin-top: -40px;
        animation-timing-function: ease-in;
    }   
    40% {
        margin-top: -50px; /* Rebond vers le haut */
        animation-timing-function: ease-in;
    }   
    100% {
        margin-top: -40px;
    }
}

.marker-bounce {
animation: bounce 0.8s infinite;    
z-index:1001;
width:35px !important;
height:35px !important;
}

/* Modifier la classe existante pour ajouter un effet de hover */
#establishments-list li:hover {
background-color: #4696a4;

}
#establishments-list li:hover a,  #establishments-list li:hover p{
color:#fff;
}

#establishments-list li .establishment-link{
    display:none;
}

/* Responsive styles */
@media screen and (max-width: 768px) {    
    body.page-template-template-carte-new{
        margin:0;
        main{
            margin-top:71px;
        }
    }
    input.filter-results{    
        display: block;
        cursor: pointer;
    }
    .div-nb-results{
        display:block;
        position:fixed;
        bottom:0;
        left:0;
        width:100%;
        background:rgba(70,150,164, 1);
        padding:10px;
    }
    .officiel-map-container {
        flex-direction: column;
        height: auto;
        position: relative;
    }
       
    .mobile-filter-switch{
        position:absolute;
        display: flex;
        justify-content: space-between;
        left:0;
        top:10px;        
        z-index: 2002;      
        width:calc(100vw - 10px);  
        > div{
            width:100px;
            height:35px;
            display:flex;
            justify-content: center;
            align-items: center;
            font-size:15px;
            padding:2px;   
            
        }
        > div .btn-carte{
            display: none;
            cursor: pointer;
        }
    }
    .mobile-filter-toggle:after{        
        content:'';
        display: inline-block;
        background:url('/wp-content/uploads/2025/02/filtrer.svg');
        width:18px;
        height:18px;
        margin-left:10px;
    }
    .mobile-filter-switch.back{
        position:fixed;
        width:calc(100vw);
        top:70px;
        > div{
            width:calc(100vw + 10px);
            justify-content: left;
        }        
    }
    .mobile-filter-switch.back > div:nth-child(1){
        display:none;
    }
    .mobile-filter-switch.back .mobile-filter-toggle{
        border-radius: 0;
        text-align: left;      
    }
    .mobile-filter-switch.back .mobile-filter-toggle:before{
        content:'';
        display: inline-block;
        background:url('/wp-content/uploads/2025/02/fleche-filter-gauche.svg');
        width:22px;
        height:22px;
        background-size: cover;
        margin-left:10px;
        margin-right:10px;        
    }
    .mobile-filter-switch.back .mobile-filter-toggle:after{
        display:none;
    }
    .filters-container{
        display:none;
        width: 100%;
        order: 1;
        z-index:2003;
        background-color: #c4dde2;
    }
    .filters-container.show {
        display: block;
        max-height: 82vh;
        overflow-y: auto;
        position: fixed;
        top: 106px;

    }
    .establishments-list-wrapper .type-affichage{
        display: none;
    }
   
    .establishments-list-wrapper {
        width: 100%;
        order: 2;
        position:absolute;
        background: #fff;
        top:80vh;
        z-index:2001;
        border-top-left-radius: 20px;
        border-top-right-radius: 20px;
    }    
    .establishments-list-wrapper.full{
        top:37px;
        border-radius: 0;
    }
    .establishments-list-wrapper .onglet-liste{
        cursor: pointer;
        display:block;
        position: absolute;
        left: calc(50% - 30px);
        top: -26px;
    }
    .establishments-list-wrapper.full .onglet-liste{
        display: none;
    }
    .establishments-list-wrapper.show{
        display:block;
    }
    .establishments-list-container {
        width: 100%;
        height: 100vh;             
    }    
    .establishments-list-container > ul{
        grid-template-columns: repeat(1, 1fr);
    }
    #establishments-list li{
        padding-bottom:0;
        border-bottom:0 !important;
    
    }
    #establishments-list li .establishment-link{
        display:flex;
        background-color: #fff;
        border-top:1px solid rgba(0, 57, 65, 0.25);
        border-bottom-left-radius: 8px;
        border-bottom-right-radius: 8px;
        > a{
            width:50%;
           justify-content: center;
            display:flex;
            color:#4696A4;
            padding-top:6px;
            padding-bottom:6px;
            font-size:14px;
            img{
                margin-right: 8px;
            }
            &:nth-child(2){
                border-left:1px solid rgba(0, 57, 65, 0.25);
            }
        }
    }
    #officiel-map {
        /*display:none; */
        height: 90vh;
        order: 3;
    }
    .toggle-list-btn {
        display: none;
    }
    .establishment-popup img{               
        height: 150px !important;
        object-fit: cover;
        object-position: center center;
    }
    .establishment-popup .lst-orientation li{
        padding-bottom:5px;
    }
    h6{        
       /* margin:0;*/
        line-height:100%;
    }
    .btn-std{
        font-size:12px;
        padding:10px;
    }
    .leaflet-popup-content p{
        margin:5px 0;
    }
    #en-tete{
        display: flex;
        flex-direction: column-reverse;
    }
}