/* ==================================================
    STRUCTURE GÉNÉRALE DU SITE
   ================================================== */

/*
    Donne une hauteur minimale à la page complète.
    Cela permet au navigateur de considérer que le site
    occupe au moins toute la hauteur de l’écran.
*/
html,
body {
    min-height: 100%;
}

/*
    Transforme le body en colonne verticale :
    - header en haut
    - navbar ensuite
    - contenu principal au centre
    - footer en bas
*/
body {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/*
    Le main représente le contenu principal de chaque page.
    flex: 1 lui permet de prendre tout l’espace disponible
    entre la navbar et le footer.

    Résultat :
    si une page a peu de contenu, le footer reste quand même
    collé en bas de l’écran.
*/
main {
    flex: 1;
}

/* ==================================================
    TEXTES GÉNÉRAUX
   ================================================== */

/*
    Justifie les paragraphes des pages de contenu statique.
    Utilisé notamment pour les pages :
    - Qui sommes-nous
    - Adhésion
    - Mentions légales
    - Cookies
    - Agenda
*/
.text-justify,
.editorial-content,
.agenda-content,
.offre-content,
.accordion-body {
    text-align: justify;
}

.text-justify p,
.editorial-content p,
.agenda-content p,
.offre-content p,
.accordion-body p {
    text-align: justify;
    margin-bottom: 0.8rem;
}

/*
    Couleur orange soutenue pour les titres principaux des pages.
    Plus lisible qu’un orange trop clair sur fond blanc.
*/
.page-title-orange {
    color: #f79330;
}

/*
    Mise en page commune des contenus rédigés.
    Utilisé pour :
    - Agenda
    - Dates mémorables
    - Personnalités inspirantes
    - Ressources éducatives
    - Offres publiques
    - Événements
*/
.editorial-content,
.agenda-content,
.offre-content {
    max-width: 760px;
    margin: 0 auto;
    line-height: 1.6;
    font-size: 1rem;
    text-align: justify;
}

.editorial-content p,
.agenda-content p,
.offre-content p {
    margin-bottom: 1.25rem;
}

/*
    Mise en forme des listes éventuelles dans l'agenda.
*/
.agenda-content ul {
    list-style: none;
    padding-left: 0;
    margin: 1.5rem 0;
}

.agenda-content li {
    background-color: #fff4df;
    border-left: 4px solid #f6a400;
    border-radius: 0.5rem;
    padding: 0.75rem 1rem;
    margin-bottom: 0.75rem;
}
/* ==================================================
    HEADER DU SITE
   ================================================== */

/*
    Bandeau orange situé au-dessus de la navbar.
    Le logo est centré horizontalement et verticalement.
*/
.site-header {
    background-color: orange;
    height: 130px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/*
    Le lien entourant le logo ne doit pas être souligné.
*/
.site-logo-link {
    text-decoration: none;
    display: inline-block;
}

/*
    Taille du logo NVI.
    object-fit permet de conserver ses proportions.
*/
.site-logo {
    width: 180px;
    height: auto;
    display: block;
}


/* ==================================================
    NAVBAR - MENU PRINCIPAL
   ================================================== */

/* 
    La liste des onglets occupe toute la largeur de la barre de navigation. Les onglets sont répartis régulièrement.
*/
.navbar-nav {
    width: 100%;
    justify-content: space-evenly;
}

/*
    Chaque onglet principal occupe une partie de l'espace disponible dans la navbar.
*/
.navbar-nav > .nav-item {
    flex: 1;
    margin: 0 5px;
}

/*
Apparence des liens principaux :
    - contour orange
    - coins arrondis
    - texte centré et en gras
    - empêche le texte de passer sur deux lignes
*/
.navbar-nav > .nav-item > .nav-link {
    border: 2px solid orange;
    border-radius: 8px;
    padding: 8px 14px;
    text-align: center;
    font-weight: bold;
    white-space: nowrap;
}

/*
    Au survol d'un onglet principal, son fond devient orange clair.
*/
.navbar-nav > .nav-item > .nav-link:hover {
    background-color: #ffd6a0;
}

/* ==================================================
    MENUS DÉROULANTS
   ================================================== */

/*
    Change la couleur de fond lorsqu'on survole un élément d'un menu déroulant.
*/
.dropdown-menu .dropdown-item:hover {
    background-color: #ffd6a0;
}

/* ==================================================
    SOUS-MENUS : NOS COURS / ÉVÉNEMENTS
   ================================================== */

/*
    Le parent sert de point de référence pour positionner son sous-menu.
*/
.dropdown-submenu {
    position: relative;
}


/*
    Place le sous-menu à droite du menu parent. Il est caché par défaut.
*/
.dropdown-submenu > .dropdown-menu {
    top: 0;
    left: 100%;
    margin-top: -1px;
    display: none;
}

/*
    Affiche le sous-menu lorsque la souris survole "Nos cours" ou "Événements".
*/
.dropdown-submenu:hover > .dropdown-menu {
    display: block;
}
/* ==================================================
    FOOTER
   ================================================== */

/* Bandeau principal du footer */
.site-footer {
    background-color: orange;
    padding: 15px 20px;
    margin-top: auto;
}

/* Liens du footer */
.site-footer a {
    color: #f7f2f2;
    text-decoration: none;
    font-weight: bold;
}

/* Effet au survol */
.site-footer a:hover {
    text-decoration: underline;
}

/* Espacement entre les réseaux sociaux */
.social-links {
    display: flex;
    gap: 15px;
    align-items: center;
}

/* Taille des icônes des réseaux sociaux */
.social-links a {
    font-size: 1.5rem;
}

/* Adaptation sur téléphone */
@media (max-width: 767px) {
    .site-footer .row {
        gap: 15px;
    }

    .social-links {
        justify-content: center;
    }
}
/* ==================================================
    BANDEAU DE CONSENTEMENT AUX COOKIES
   ================================================== */

.cookie-banner {
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1055;
    background-color: #ffffff;
    border-top: 2px solid orange;
    box-shadow: 0 -4px 12px rgba(0, 0, 0, 0.15);
    padding: 15px 20px;
}

.cookie-banner__content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.cookie-banner__text {
    margin: 0;
}

.cookie-banner__actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

@media (max-width: 767px) {
    .cookie-banner__content {
        flex-direction: column;
        align-items: stretch;
    }

    .cookie-banner__actions {
        justify-content: center;
    }

    .cookie-banner__text {
        text-align: center;
    }
}
/* ==================================================
   PAGE D'ACCUEIL - INFORMATIONS PRATIQUES
   ================================================== */

.home-info-card {
    background-color: #0d6efd;
    color: white;
    border: 3px solid orange;
    border-radius: 35px;
    padding: 25px 20px;
}

.home-info-card hr {
    border-color: white;
    opacity: 1;
}

.home-info-card .btn {
    margin-top: 15px;
    border: 3px solid orange;
    font-weight: bold;
}
/* ==================================================
    PAGE D'ACCUEIL - CARROUSEL
   ================================================== */

#homeCarousel {
    border: 3px solid orange;
    border-radius: 25px;
    overflow: hidden;
}

.home-carousel-image {
    height: 420px;
    object-fit: contain;
    background-color: #fff;
}

/* Bouton "Découvrir" sans fond sombre */
#homeCarousel .carousel-caption {
    background: transparent;
    padding: 0;
}

/* Flèches du carrousel */
#homeCarousel .carousel-control-prev-icon,
#homeCarousel .carousel-control-next-icon {
    background-image: none;
    width: auto;
    height: auto;
}

#homeCarousel .carousel-control-prev-icon::after {
    content: "‹";
    color: orange;
    font-size: 4rem;
    font-weight: bold;
}

#homeCarousel .carousel-control-next-icon::after {
    content: "›";
    color: orange;
    font-size: 4rem;
    font-weight: bold;
}


/* ==================================================
    PAGE D'ACCUEIL - LE BOUTON ADHESION
   ================================================== */

/* Bouton d'adhésion sous la carte horaires */
.home-adhesion-button {
    margin-top: 15px;
    text-align: center;
}

.home-adhesion-button .btn {
    background-color: #0d6efd;
    border: 3px solid orange;
    border-radius: 8px;
    color: #fff;
    font-weight: bold;
}

.home-adhesion-button .btn:hover {
    background-color: orange;
    border-color: orange;
    color: #fff;
}


/* ==================================================
    PAGE D'ACCUEIL - VERSION MOBILE
   ================================================== */

@media (max-width: 767px) {

    /* Taille du carrousel */
    .home-carousel-image {
        height: 250px;
    }

    /* Bouton d'adhésion */
    .home-adhesion-button {
        margin-top: 10px;
    }

    .home-adhesion-button .btn {
        font-size: 0.85rem;
        padding: 6px 12px;
    }

    /* Carte adresse / horaires */
    .home-info-card {
        width: 75%;
        max-width: 280px;
        max-height: 160px;
        margin: 0 auto;
        padding: 8px 10px;
        overflow-y: auto;
        border-radius: 15px;
    }

    .home-info-card h2,
    .home-info-card h3 {
        font-size: 0.95rem;
        margin: 3px 0;
    }

    .home-info-card p {
        font-size: 0.8rem;
        margin: 3px 0;
        line-height: 1.15;
    }

    .home-info-card hr {
        margin: 4px 0;
    }

    /* Barre de défilement de la carte horaires */
    .home-info-card::-webkit-scrollbar {
        width: 6px;
    }

    .home-info-card::-webkit-scrollbar-track {
        background: transparent;
    }

    .home-info-card::-webkit-scrollbar-thumb {
        background-color: orange;
        border-radius: 10px;
    }
}
/* ============================= */
/* Page publique contenu éditorial */
/* ============================= */

/* Conteneur général de la page.
   Les marges gauche/droite sont d’environ 2 cm sur ordinateur. */
.contenu-editorial-page {
    padding: 3rem 2cm;
}

/* Bloc principal de l’article.
   La largeur maximale évite que les lignes soient trop longues à lire. */
.contenu-editorial-article {
    max-width: 900px;
    margin: 0 auto;
}

/* Titre principal de l’article. */
.contenu-editorial-title {
    text-align: center;
    margin-bottom: 2rem;
}

/* Bloc qui contient l’image principale. */
.contenu-editorial-image-wrapper {
    text-align: center;
    margin-bottom: 2rem;
}

/* Image principale du contenu éditorial.
   Elle reste responsive et ne dépasse pas la largeur disponible. */
.contenu-editorial-image {
    max-width: 100%;
    height: auto;
    border-radius: 1rem;
}

/* Résumé ou introduction du contenu.
   Il est centré pour se distinguer du texte principal. */
.contenu-editorial-resume {
    font-size: 1.2rem;
    font-weight: 500;
    text-align: center;
    margin-bottom: 2rem;
}

/* Corps du texte principal.
   Le texte est justifié sur ordinateur pour un rendu plus éditorial. */
.contenu-editorial-content {
    text-align: justify;
    line-height: 1.8;
    font-size: 1.05rem;
}

/* Adaptation responsive pour tablette et mobile.
    Les marges passent à environ 1 cm.
   Le texte repasse aligné à gauche pour éviter les grands espaces irréguliers. */
@media (max-width: 768px) {
    .contenu-editorial-page {
        padding: 2rem 1cm;
    }

    .contenu-editorial-content {
        text-align: left;
    }
}
/* 
 * Contenus éditoriaux
 * Image responsive utilisée sur les pages de contenu :
 * - Manifestations
 * - Dates mémorables
 * - Personnalités inspirantes
 * - Ressources éducatives
 * - Articles éditoriaux
 */
.editorial-image {
    width: 100%;
    max-height: 520px;
    object-fit: contain;
}

/*
 * Améliore la lisibilité des textes éditoriaux.
 */
.editorial-content {
    line-height: 1.8;
}

 /*============================= */
/* Mise en page des pages d'offres publiques. */
/* ============================= */

.offre-content {
    max-width: 760px;
    margin: 0 auto;
    line-height: 1.8;
}

.offre-content p {
    margin-bottom: 1.2rem;
}

/*
    FAQ : Couleur orange pour les questions ouvertes de la FAQ.
*/
.accordion-button:not(.collapsed) {
    color: #f79330;
    background-color: #fff4df;
    font-weight: 600;
}

/*
    Couleur orange au survol des questions de la FAQ.
*/
.accordion-button:hover {
    color: #f79330;
}

/*
    Retire l'effet bleu Bootstrap au focus.
*/
.accordion-button:focus {
    border-color: #f79330;
    box-shadow: 0 0 0 0.25rem rgba(247, 147, 48, 0.25);
}