header {
    font-family: 'Roboto', sans-serif;
    margin: 0;
    padding: 0;
}

.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100px;
    padding: 20px 0 0 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: padding 0.3s ease, background-color 0.3s ease, opacity 0.3s ease;
    z-index: 2000;
    background: linear-gradient(rgba(0, 0, 0, 1), rgba(0, 0, 0, 0)), linear-gradient(to top, transparent 100%, black 100%);
}

.header.scrolled {
    background-color: rgba(0, 0, 0, 0.5); /* Noir avec 50% d'opacité */
    padding: 10px 0 10px 0;
    /*padding-top: 5px;
    padding-bottom: 5px;*/
}

.background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    transition: opacity 0.3s ease;
}

.header.opaque .background {
    opacity: 0.7; /* Opacité réduite de l'arrière-plan lors du scroll */
}

.header .logo img {
    display: block;
    max-height: 100%;
    width: auto;
    margin: 0;
    border: none;
    max-width: 100px;
    object-position: center;
}

.header .logo {
    margin-left: 20px;
    display: flex;
    align-items: center;
    height: 100%;
}

.menu {
    margin-right: 20px;
}

.menu ul {
    list-style-type: none;
    margin: 0;
    padding: 0;
    display: flex;
    gap: 20px;
}

.menu li {
    display: flex;
    align-items: center;
    margin: 0;
    padding: 0;
}


.menu a {
    display: flex;
    align-items: center;
    gap: 5px;
    text-decoration: none;
    color: white;
    padding: 8px 16px;
    transition: background-color 0.3s;
}

.devis {
    display: flex;
    align-items: center;
    gap: 5px;
}

.casePanier {
    position: absolute;
    bottom: 3px;
    display: inline-block; /* Permet de définir la taille en fonction du contenu */
}

.nbPanier {
    position: absolute;
    top: 20px;
    left: 50%;
    transform: translate(-50%, -50%);
    padding: 4px 8px; /* Ajouter un peu de marge autour du numéro */
    border-radius: 50%; /* Pour arrondir les bords et obtenir un cercle */
    font-size: 14px; /* Taille de la police */
    font-weight: bold; /* Gras pour une meilleure visibilité */
}

.textePanier {
    padding-left: 35px; /* Ajouter un peu de marge à gauche du texte */
}


.menu img[alt="Panier"] {
    width: 30px;
    height: 30px;
    margin: 0;
    padding: 0;
}

.header .menu > ul > li > a {
    position: relative;
    display: inline-block;
    padding: 8px 0;
}

.header .menu > ul > li > a::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background-color: white;
    transform: scaleX(0);
    transform-origin: bottom right;
    transition: transform 0.3s ease;
}

.header .menu > ul > li > a:hover::after,
.header .menu > ul > li > a.active::after {
    transform: scaleX(1);
    transform-origin: bottom left;
}

.menu ul li {
    margin-right: 50px;
}

/* Burger Menu */
.burger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 5px;
    margin-right: 30px;
    z-index: 2100;
}

.burger span {
    width: 25px;
    height: 3px;
    background-color: white;
    transition: 0.3s;
}

/* Masquer le menu par défaut sur mobile */
.menu {
    display: flex;
}

.menu ul {
    display: flex;
}

.burger-container {
    display: flex;
    align-items: center;
    gap: 25px;
}

.mobile-panier {
    position: relative;
    bottom: 2px;
    display: none; /* Permet de définir la taille en fonction du contenu */
}

.mobile-panier .nbPanier {
    position: absolute;
    top: 20px;
    color: white;
    left: 50%;
    transform: translate(-50%, -50%);
    padding: 4px 8px; /* Ajouter un peu de marge autour du numéro */
    border-radius: 50%; /* Pour arrondir les bords et obtenir un cercle */
    font-size: 14px; /* Taille de la police */
    font-weight: bold; /* Gras pour une meilleure visibilité */
}

.mobile-panier img[alt="Panier"] {
    width: 30px;
    height: 30px;
    margin: 0;
    padding: 0;
}

@media (max-width: 1024px) {
    .mobile-panier {
        display: block; /* Affiche le panier en mode mobile */
    }
}

/* Styles Responsive */
@media (max-width: 1024px) {
    .header {
        height: 80px;
        padding: 14px 0 0 0;
    }

    .header .logo img {
        max-width: 80px;
    }

    .header.scrolled {
        padding: 7px 0 7px 0;
    }

    .burger {
        display: flex;
    }

    .menu {
        display: none;
        flex-direction: column;
        position: absolute;
        top: 0;
        left: 50%;
        transform: translateX(-50%);
        width: 90%;
        background-color: rgba(0, 0, 0, 0.9);
        z-index: 2000;
        padding: 70px 20px 20px 20px;
        border-radius: 10px;
    }

    .menu ul {
        flex-direction: column;
        gap: 20px;
    }

    .menu.show {
        display: flex;
    }
}

@media (max-width: 768px) {
    .header {
        height: 60px;
        padding: 10px 0 0 0;
    }

    .header .logo img {
        max-width: 60px;
    }

    .header.scrolled {
        padding: 5px 0 5px 0;
    }
}