/* Styles spécifiques au header */
#main-header {
    background-color: #faf1dd;
    padding: 40px 20px;
    text-align: center;
    position: relative;
    z-index: 1002;
}

/* Conteneur principal */
.header-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 40px;
}

/* Conteneur du logo */
.logo-container {
    display: flex;
    justify-content: center;
    align-items: center;
}

.logo img {
    animation: logoLoop 5s infinite ease-in-out;
    transition: transform 0.5s ease, filter 0.5s ease;
}

@keyframes logoLoop {
    0% {
        transform: rotate(0deg) scale(1);
    }
    25% {
        transform: rotate(3deg) scale(1.05);
    }
    50% {
        transform: rotate(0deg) scale(1.1);
    }
    75% {
        transform: rotate(-3deg) scale(1.05);
    }
    100% {
        transform: rotate(0deg) scale(1);
    }
}

/* Navbar - Menu Principal centré */
.navbar {
    width: 100%;
    max-width: 800px;
    margin: 0 auto;
}

.nav-menu {
    list-style: none;
    display: flex;
    justify-content: space-around;
    padding: 0;
    margin: 0;
    position: relative;
    z-index: 1003;
}

/* Styles des tuiles du menu */
.nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background-color: #fff7e7;
    padding: 20px;
    border-radius: 15px;
    transition: background-color 0.3s ease, transform 0.3s ease;
    cursor: pointer;
    width: 120px;
    text-align: center;
    box-shadow: 5px 5px 10px 0px #f7e9cf;
}

.nav-item:focus-within {
    outline: 2px dashed #42362d;
}

/* Effet hover pour les tuiles */
.nav-item:hover {
    background-color: #42362d;
    transform: translateY(-5px);
}

.nav-item:hover i,
.nav-item:hover span {
    color: #FFFFFF;
}

.nav-item a {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    gap: 5px;
}

.nav-item i {
    font-size: 2em;
    color: #42362d;
}

.nav-item span {
    font-size: 1em;
    font-weight: 600;
    color: #42362d;
}

/* Menu Toggle (Mobile) */
.menu-toggle {
    display: none;
    font-size: 2em;
    cursor: pointer;
    color: #42362d;
    position: absolute;
    top: 20px;
    right: 20px;
    z-index: 1004;
    padding: 5px 20px;
    border-radius: 10px;
    box-shadow: 5px 5px 10px 0px #f7e9cf;
    background-color: #fff7e7;
    position: fixed;
}

/* Bouton CTA centré */
.cta-container {
    width: 100%;
    text-align: center;
}

.cta-header-button {
    display: inline-block;
    background-color: #fef7e7;
    color: #42372d;
    padding: 15px 25px;
    border-radius: 50px;
    font-weight: 600;
    text-decoration: none;
    transition: background-color 0.3s ease, transform 0.3s ease;
    box-shadow: 5px 5px 10px 0px #f7e9cf;
}

.cta-header-button:hover {
    background-color: #42362d;
    color: #FFFFFF;
    transform: scale(1.05);
}

/* Responsive Styles pour tablette et mobile */
@media (max-width: 768px) {
    .menu-toggle {
        display: block;
    }

    .header-container {
        gap: 20px;
    }

    .logo img {
        width: 150px;
        height: 177px;
    }

    .nav-menu {
        position: absolute;
        top: 100px;
        right: 0;
        left: 0;
        flex-direction: column;
        align-items: center;
        padding: 20px;
        gap: 20px;
        opacity: 0;
        transform: translateY(-100px);
        pointer-events: none;
        transition: opacity 0.5s ease, transform 0.5s ease;
        z-index: 1003;
    }

    .nav-menu.active {
        opacity: 1;
        transform: translateY(0);
        pointer-events: all;
        position: fixed;
    }

    .nav-item {
        width: 150px;
        padding: 15px; /* Amélioration de la taille des tuiles pour mobile */
    }

    .nav-item i {
        font-size: 2.5em; /* Augmentation de la taille des icônes */
    }

    .nav-item span {
        font-size: 1.1em; /* Amélioration de la lisibilité sur mobile */
    }

    .cta-header-button {
        padding: 12px 20px;
        font-size: 0.9em;
    }
}

/* Overlay */
.overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: #faf1dd;
    z-index: 1001;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.overlay.show {
    display: block;
    opacity: 1;
}