
/* =========================================
   EN-TÊTE ET MENU DU SITE
   ========================================= */

#main .site-header {
    width: 100%;
    padding: 14px 20px 12px;
    background-color: white;
}

#main .site-brand {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
    margin-bottom: 14px;
}

#main .site-brand h2 {
    font-family: "Montserrat", Arial, sans-serif;
    font-size: 1.3rem;
    font-weight: 400;
    line-height: 1.3;
    margin: 0;
}

#main .site-brand img {
    display: block;
    width: 36px;
    height: auto;
}

/* Navigation horizontale sur ordinateur */

#main .site-nav {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    column-gap: 22px;
    row-gap: 8px;
}

#main .site-nav a {
    display: inline-block;
    padding: 7px 0 5px;
    border-bottom: 1px solid transparent;
    color: #777777;
    font-family: "Montserrat", Arial, sans-serif;
    font-size: 0.9rem;
    line-height: 1.4;
    text-decoration: none;
    white-space: nowrap;
}

#main .site-nav a:hover {
    color: #303030;
}

#main .site-nav a.active {
    color: #303030;
    border-bottom-color: #303030;
}

/* Le bouton hamburger est masqué sur ordinateur */

#main .menu-toggle {
    display: none;
}


/* =========================================
   TÉLÉPHONES ET PETITES TABLETTES
   ========================================= */

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

    #main .site-header {
        padding: 12px 14px;
    }

    #main .site-brand {
        gap: 8px;
        margin-bottom: 10px;
    }

    #main .site-brand h2 {
        font-size: 1rem;
    }

    #main .site-brand img {
        width: 26px;
    }

    /* Bouton d'ouverture du menu */

    #main .menu-toggle {
        display: inline-block;
        padding: 8px 14px;
        border: 1px solid #e1e1de;
        border-radius: 4px;
        background: white;
        color: #303030;
        font-family: "Montserrat", Arial, sans-serif;
        font-size: 0.95rem;
        cursor: pointer;
    }

    /* Menu fermé par défaut sur téléphone */

    #main .site-nav {
        display: none;
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        margin-top: 8px;
    }

    /* Menu ouvert après clic */

    #main .site-nav.open {
        display: flex;
    }

    #main .site-nav a {
        display: block;
        width: 100%;
        padding: 12px 6px;
        border-bottom: 1px solid #e1e1de;
        font-size: 0.95rem;
        text-align: center;
        white-space: normal;
    }

    #main .site-nav a.active {
        color: #303030;
        border-bottom-color: #303030;
        font-weight: 500;
    }
}


/* =========================================
   CORRECTIONS POUR LES ÉCRANS MOBILES
   ========================================= */

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

    #main {
        position: sticky;
        top: 0;
        left: 0;
        width: 100%;
        max-width: 100%;
    }

    #main .site-header {
        width: 100%;
        max-width: 100%;
    }

    #page {
        width: 100%;
        max-width: 100%;
        margin-top: 35px;
        margin-left: 0;
        margin-right: 0;
        padding-left: 15px;
        padding-right: 15px;
    }

    #page p {
        font-size: 16px;
        line-height: 1.5;
    }

    #page > h2 {
        font-size: 1.7em;
        line-height: 1.3;
        text-align: center;
        margin-bottom: 1.5em;
}

}
