
/* css reset */


/* 
*{
    margin: 0;
    padding: 0;
    box-sizing: border-box;
} */
 .bg-white{
    background-color: white;
}

.opacity-0{
    opacity: 0;
}

.card-link{
    z-index: 99;
    display: contents;
}

.section-projets .title-projet-section {
    font-size: 30px;
    font-weight: 700;
    color: #0A0549;
    margin-bottom: 50px;
    position: relative;
    width: fit-content;
}

.section-projets .title-projet-section::after {
    content: "";
    position: absolute;
    display: block;
    width: 80%;
    height: 2px;
    background-color: #0A0549;
    margin: 10px 0;
    margin-left: auto;
    margin-right: auto;
}

/* taxonomie */

.taxonomies-selector{
    display: flex;
    gap: 10px;
    margin-bottom: 50px;
}

.taxonomy{
    font-size: 16px;
    margin-top: 40px;
    padding: 2px 20px;
    background-color: white;
    color: #0A0549;
    font-weight: 700;
    border: #0A0549 3px solid;
    cursor: pointer;
}

.taxonomy:hover{
    background-color: #0A0549;
    color: white;
}

.taxonomy.active{
    background-color: #0A0549;
    color: white;
}

/* ajax button */


.elementor-button[clicked="true"]{
    background-color: #0A0549;
    color: white;
}



/* Cards */

.container{
    margin: auto;
    max-width: 1200px;
    display: relative;
}


.projet-card-grid{
    padding: 0 150px 0 150px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 70px;
    
}

.projet-card{
    background-size: contain;
    background-repeat: no-repeat;
    aspect-ratio: 6/5;
    position: relative;
    filter: drop-shadow(2px 1px 5px #7e7e7ee5);
    height: 100%;
    transition: all .3s ease-in-out;
    
}

.projet-informations{
    padding: 10px;
    background-color: white;
    position: absolute;
    bottom: 35px;
    height: 20%;
    padding: 24px 10px 10px 28px;
    width: 65%;
    transition: .3s ease-in-out all;
    opacity: 1;
    overflow: hidden;
}

.projet-description{
    font-size: 14px;
    line-height: 20px;
    padding-top: 50px;
    color: #0A0549;
    margin-bottom: 10px;
    opacity: 0;
    transition: padding-top 0.3s ease-in-out;
    margin-top: 55px;
}

.projet-card:hover .projet-description{
    opacity: 1;
    padding-top: calc(60px + 1.5rem); /* Ajuste en fonction de la hauteur du titre */
}

.projet-card:hover .card-titles{
    width: 85%;
    height: auto; /* Laisse le titre s'étendre selon le contenu */
    padding-bottom: 20px; /* Ajoute un espace en bas pour la description */
}


.projet-card:hover .projet-informations{
    opacity: 1;
    height: 95%;
    width: 95%;
    bottom: 0;
}

.projet-ref{
    padding: 3px 0px;
    font-size: 16px;
    line-height: 10px;
    font-size: 13px;
    border: #0A0549 solid 1px;
    
}

.projet-card:hover .projet-ref{
    background-color: #0A0549;
    color: white!important;
}

.projet-infos{
    background-color: white;
    color: #0A0549;
    position: absolute;
    top: 20px;
    z-index: 10;
    right: 20px;
    display: block;
    transition: all .3s ease-in-out;
}  

.projet-infos-portable{
    display: none;
}

.projet-cat {
    padding: 5px 15px;
    border: #0A0549 solid;
    border-top-width: 0;
    border-left-width: 1px;
    border-right-width: 1px;
    border-bottom-width: 1px;
}

.projet-cat p{
   text-align: center;
   text-transform: uppercase;
}

.projet-ref p{
    display: inline-flex;
    gap: 20px;
    padding: 5px 15px;
}

.projet-more{
    border: #0A0549 solid 2px;
    border-style: inset;
    padding: 10px;
    background-color: white;
    z-index: 1;
    transform: translateY( calc(95% + 2px));
    transition: all .3s ease-in-out;
    cursor: pointer;
    color: #0A0549;
    text-decoration: none;
    text-align: center;
}

.projet-card:hover .projet-more{
    transform: translate(0%);
}

.projet-card .projet-informations p {
    opacity: 0;
}

.projet-card:hover .projet-informations p{
    opacity: 1;
}

.projet-more:hover{
    background-color: #0A0549;
    color: white;
}

.card-titles{
    width: 100%;
    background-color: white;
    position: absolute;
    padding: 10px 10px 10px 0px;
    z-index: 5;
    transition: all .3s ease-in-out;
    top: 0;
    line-height: 20px;
}

.card-titles p{
    line-height: 20px;
}

.projet-card:hover .card-titles{
    bottom: default;
    top: 0;
    height: auto; /* Laisse le titre s'étendre selon le contenu */
    padding-bottom: 20px; /* Ajoute un espace en bas pour la description */
}

.card-titles h3 {
/*     font-size: clamp(1rem, 2.5vw, 2rem); */
    font-size: 25px;
    /* overflow: hidden; */
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2; /* Nombre de lignes max */
    -webkit-box-orient: vertical;
    height: 3rem; /* Ajustez selon la taille de la police */
    line-height: 1.5rem; /* Ajustez selon la taille de la police */
}

.card-titles span{
    color: #0A0549;
}

.titre-categorie{
    color: #0A0549;
    font-weight: bold;
}

.projet-card-footer{
    display: grid;
    grid-template-columns: 1fr 1fr;
    position: absolute;
    width: 100%;
    bottom: 0;
}

.projet-card-footer div{
    padding: 10px;
    text-align: center;
    font-weight: 700;
}

.card-price{
    background-color: white;
    color: #0A0549;
    z-index: 99;
}

.projet-card-footer .card-city{
    background-color: #0A0549;
    color: white;
}

.card-city{
   position: relative;
   z-index: 5;
   border-top: 5px solid #A0B5D4;
}

.projet-card:hover .card-city{
    border-top: none;
}

.projet-card:hover .projet-infos{
    transform: translate(8%, -30%);
}

.enerj-container{
    /* padding-top: .75rem; */
    display: flex;
    flex-direction: row;
    gap: 5px;
    position: relative;
    width: 100%;

}

.dpe-container p , .ges-container p{
    margin-bottom: 10px!important;
}

/* DPE */

.dpe-container{
    font-size: 12px;
    font-weight: bold;
    display: flex;
    flex-direction: column;
    gap: 5px;
    width: 50%;
}

.dpe-colors{
    display: flex;
    gap: 4px;
    align-items: center;
}

.dpe-letters{
    display: none;
}



.dpe-color.open > .dpe-letters{
    display: block;
}

 /* align items vertically */

.dpe-color.open{
    height: 25px;
    border-radius: 5px;
}

.dpe-color{
    width: 12%;
    height: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.dpe-A{
    background-color: #00A774;
    border-top-left-radius: 50px;
    border-bottom-left-radius: 50px;
}
.dpe-B{
    background-color: #00BB54;
}
.dpe-C{
    background-color: #4AC57B;
}
.dpe-D{
    background-color: #FDEB00;
}
.dpe-E{
    background-color: #FFBC00;
}
.dpe-F{
    background-color: #FF882F;
    
}
.dpe-G{
    background-color: #EC0118;
    border-top-right-radius: 50px;
    border-bottom-right-radius: 50px;
}

/* GES */

.ges-container{
    font-size: 12px;
    font-weight: bold;
    display: flex;
    flex-direction: column;
    gap: 5px;
    width: 50%;
}

.ges-colors{
    display: flex;
    gap: 4px;
    align-items: center;
}

.ges-letters{
    display: none;
    color: white;
}



.ges-color.open > .ges-letters{
    display: block;
}

 /* align items vertically */

.ges-color.open{
    height: 25px;
    border-radius: 5px;
}

.ges-color{
    width: 12%;
    height: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.ges-A{
    background-color: #A3DBFC;
    border-top-left-radius: 50px;
    border-bottom-left-radius: 50px;
}
.ges-B{
    background-color: #8AB5D2;
}
.ges-C{
    background-color: #7692B1;
}
.ges-D{
    background-color: #5E708D;
}
.ges-E{
    background-color: #4D5272;
}
.ges-F{
    background-color: #393550;
    
}
.ges-G{
    background-color: #05003E;
    border-top-right-radius: 50px;
    border-bottom-right-radius: 50px;
}



/* PAGINATION */

.box-pagination {
    padding: 0; /* Supprimez tout padding indésirable */
    margin: 0 auto; /* Centre l'élément, en évitant tout espace supplémentaire */
    width: 100%; /* S'assure qu'elle occupe toute la largeur disponible */
    height: auto; /* Laisse la hauteur être déterminée par le contenu réel */
    display: flex; /* Centrer le contenu de manière horizontale */
    justify-content: center; /* Centrer le contenu à l'intérieur */
}

.box-pagination::after {
    content: "";
    display: table;
    clear: both;
}

.pagination {
    display: flex;
    justify-content: center;
    margin-top: 20px;
}

.projet-card-grid .pagination {
    grid-column: span 2;
    display: flex;
    justify-content: center;
    margin-top: 20px;
}


.pagination a {
    margin: 0 5px;
    padding: 8px 16px;
    background-color: #0A0549;
    color: white;
    text-decoration: none;
    border-radius: 5px;
    transition: background-color 0.3s;
}

.pagination a:hover {
    background-color: #4A4A8A;
}

.pagination .current {
    margin: 0 5px;
    padding: 8px 16px;
    background-color: #4A4A8A;
    color: white;
    border-radius: 5px;
}


/* media queries */ 
@media screen and (max-width: 945px){
    .card-titles{
        top: 0;
    }

    .projet-informations{
        padding: 24px 10px 10px 10px;
    }

    .projet-description{
        padding-top: 0;

    }
}


@media screen and (max-width: 768px){

    .projet-card{
        background-size: cover;
        background-position: center;
        aspect-ratio: inherit!important;
        height: 60vh;
    }

    .projet-card-grid {
        padding: 0 20px; /* Réduire les marges pour un écran plus petit */
        grid-template-columns: 1fr; /* Passer à une seule colonne */
        gap: 30px; /* Réduire l'espace entre les éléments pour mobile */
    }

/* Centrer la pagination sur mobile */
    .projet-card-grid .pagination {
        grid-column: span 1;
        display: flex;
        justify-content: center;
        margin-top: 20px;
    }

    .projet-card .card-titles{
        
        width: 85%;
        top: 5%;
    }

    .projet-infos{
        display: block;
        top: 0;
        right: 0;
        height: 5%;
    }

    .projet-infos .projet-cat{
        display: none;
    }

    .projet-card:hover .projet-infos {
        transform: inherit;
    }

    .projet-card:hover .projet-description {
        opacity: 1;
        padding-top: 0
    }

    .projet-card:hover .projet-informations {
        overflow-y: auto; /* Ajoute une barre de défilement verticale */
        max-height: 800px; /* Définir une hauteur maximale pour activer le défilement */
    }

    .projet-infos span{
        font-size: 12px;
    }

    .projet-ref {
        padding: 0;
        height: 100%;
    }

    .projet-more{
        transform: translateY(0%);
        z-index: 99;
        font-size: smaller;
    }

    .projet-infos-portable{
        gap: 15PX;
        justify-content: flex-end;
        padding: 5px;
        width: fit-content;
        display: flex;
    }
    .projet-card:hover .card-titles{
        position: relative!important;
    }

    .projet-informations {
        padding: 10px;
        background-color: white;
        position: absolute;
        bottom: 20px;
        height: 30%;
        padding: 24px 10px 10px 28px;
        width: 85%;
        transition: .3s ease-in-out all;
        opacity: 1;
        overflow: hidden;
    }

    .card-city{
        border-top: none;
    }

    .pagination {
/*         position: relative;
        z-index: 100;
        margin-top: 20px;
        text-align: center;
        bottom: 0;
        margin: 1550px 0 20px !important; */
        padding: 20px;
    }

    .card-titles h3 {
        font-size: 15px !important;
        height: 3rem !important; /* Ajustez selon la taille de la police */
        line-height: 1.5rem !important; /* Ajustez selon la taille de la police */
        margin-bottom: 5px;
    }

    .enerj-container {
        flex-direction: column;
        gap: 25px;
    }

    .ges-colors {
        margin-bottom: 75px;
    }

}

@media (min-width: 768px) and (max-width: 1000px) {

    .projet-card-grid {
        padding: 0 20px; /* Réduire les marges pour un écran plus petit */
        grid-template-columns: repeat(2, 1fr); /* Deux colonnes à partir de 768px */
        gap: 30px; /* Réduire l'espace entre les éléments pour mobile */
    }

/* Centrer la pagination sur mobile */
    .projet-card-grid .pagination {
        grid-column: span 1;
        display: flex;
        justify-content: center;
        margin-top: 20px;
    }

    .projet-card{
        background-size: cover;
        background-position: center;
        aspect-ratio: inherit!important;
        height: 60vh;
    }

    .projet-card .card-titles{
        
        width: 85%;
        top: 5%;
    }

    .projet-infos{
        display: block;
        top: 0;
        right: 0;
        height: 5%;
    }

    .projet-infos .projet-cat{
        display: none;
    }

    .projet-card:hover .projet-infos {
        transform: inherit;
    }

    .projet-card:hover .projet-description {
        opacity: 1;
        padding-top: 0
    }

    .projet-card:hover .projet-informations {
        overflow-y: auto; /* Ajoute une barre de défilement verticale */
        max-height: 800px; /* Définir une hauteur maximale pour activer le défilement */
    }

    .projet-infos span{
        font-size: 12px;
    }

    .projet-ref {
        padding: 0;
        height: 100%;
    }

    .projet-more{
        transform: translateY(0%);
        z-index: 99;
        font-size: smaller;
    }

    .projet-infos-portable{
        gap: 15PX;
        justify-content: flex-end;
        padding: 5px;
        width: fit-content;
        display: flex;
    }
    .projet-card:hover .card-titles{
        position: relative!important;
    }

    .projet-informations {
        padding: 10px;
        background-color: white;
        position: absolute;
        bottom: 35px;
        height: 30%;
        padding: 24px 10px 10px 28px;
        width: 85%;
        transition: .3s ease-in-out all;
        opacity: 1;
        overflow: hidden;
    }

    .card-city{
        border-top: none;
    }

    .pagination {
/*         position: relative;
        z-index: 100;
        margin-top: 20px;
        text-align: center;
        bottom: 0;
        margin: 1950px 0 20px !important; */
        padding: 20px;
    }

    .card-titles h3 {
        height: 3rem !important; /* Ajustez selon la taille de la police */
        line-height: 1.5rem !important; /* Ajustez selon la taille de la police */
        margin-bottom: 5px;
    }

    .enerj-container {
        flex-direction: column;
        gap: 25px;
    }

    .ges-colors {
        margin-bottom: 75px;
    }

}

@media (min-width: 1000px) and (max-width: 1500px) {

    .projet-card-grid {
        padding: 0 20px; /* Réduire les marges pour un écran plus petit */
        grid-template-columns: repeat(2, 1fr); /* Deux colonnes à partir de 768px */
        gap: 30px; /* Réduire l'espace entre les éléments pour mobile */
    }

/* Centrer la pagination sur mobile */
    .projet-card-grid .pagination {
        grid-column: span 1;
        display: flex;
        justify-content: center;
        margin-top: 20px;
    }

    .projet-card{
        box-sizing: content-box;
        background-size: cover;
        background-position: center;
        aspect-ratio: 6/6;
/*         height: 70vh; */
    }

    .projet-card .card-titles{
        width: 85%;
        top: 5%;
    }

    .projet-infos{
        display: block;
        top: 0;
        right: 0;
        height: 5%;
    }

    .projet-infos .projet-cat{
        display: none;
    }

    .projet-card:hover .projet-infos {
        transform: inherit;
    }

    .projet-card:hover .projet-description {
        opacity: 1;
        padding-top: 0
    }

    .projet-card:hover .projet-informations {
        overflow-y: auto; /* Ajoute une barre de défilement verticale */
        max-height: 800px; /* Définir une hauteur maximale pour activer le défilement */
    }

    .projet-infos span{
        font-size: 12px;
    }

    .projet-ref {
        padding: 0;
        height: 100%;
    }

    .projet-more{
        transform: translateY(0%);
        z-index: 99;
        font-size: smaller;
    }

    .projet-infos-portable{
        gap: 15PX;
        justify-content: flex-end;
        padding: 5px;
        width: fit-content;
        display: flex;
    }
    .projet-card:hover .card-titles{
        position: relative!important;
    }

    .projet-informations {
        padding: 10px;
        background-color: white;
        position: absolute;
        bottom: 20px;
        height: 15%;
        padding: 24px 10px 10px 28px;
        width: 85%;
        transition: .3s ease-in-out all;
        opacity: 1;
        overflow: hidden;
    }

    .card-city{
        border-top: none;
    }

    .card-titles h3 {
        height: 3rem !important; /* Ajustez selon la taille de la police */
        line-height: 20px !important; /* Ajustez selon la taille de la police */
        margin-bottom: 5px;
        font-size: 19px;
    }

    .enerj-container {
        flex-direction: column;
        gap: 25px;
    }

    .ges-colors {
        margin-bottom: 75px;
    }

}


@media (min-width: 1500px) and (max-width: 1900px) {
    .card-titles h3 {
        height: 3rem !important; /* Ajustez selon la taille de la police */
        line-height: 20px !important; /* Ajustez selon la taille de la police */
        margin-bottom: 5px;
        font-size: 19px;
    }

    .projet-card:hover .projet-informations {
        overflow-y: auto; /* Ajoute une barre de défilement verticale */
        max-height: 800px; /* Définir une hauteur maximale pour activer le défilement */
    }

    .projet-card:hover .projet-description {
        padding-top: 0;
    }

    .projet-informations {
        padding: 17px; 
    }

    .projet-description{
        margin-top: 70px;
    }

/*     .pagination {
        position: relative;
        z-index: 100;
        margin-top: 20px;
        text-align: center;
        bottom: 0;
        margin: 1950px 0 20px !important;
    } */
}