/*
 * ========================================================
 * [ÉTAT : FINAL] Date : 21-05-2026 15:08:00
 * FICHIER : global.css
 * RÔLE : Feuille de style globale, charte graphique et navigation principale
 * Auteurs : Yvan Dubé & Gemini (IA Collaboratrice)
 * =========================================================
 */

/* ==========================================================================
   1. VARIABLES & CONFIGURATION UNIFIÉES
   ========================================================================== */
:root {
    --couleur-primaire: #7b1c8d;
    --couleur-primaire-hover: #6e4874;
    --couleur-grise: #efefef;
    --couleur-grise-pale: #f5f5f5;
    --couleur-bordure: #ccc;
    --couleur-erreur: #ff0000;
    --couleur-succes: #008000;
    --radius: 6px;
    --transition-rapide: 0.2s ease-in-out;
    --transition-messages: 0.8s ease;
}

/* ==========================================================================
   2. RESET & BASE (Standardisation de l'affichage)
   ========================================================================== */
* { 
    box-sizing: border-box; 
}

html, body { 
    margin: 0; 
    padding: 0; 
    background-color: #fff; 
    font-family: 'Segoe UI', Arial, sans-serif;
    color: #333;
}


body { 
    width: 100%;
    max-width: 1600px; 
    margin: 0 auto; 
    
    /* C'est ici ! On ajoute 10px d'espace vide tout autour du contenu */
    padding: 10px; 
    
    overflow-x: hidden; 
    line-height: 1.5;
}


/* ==========================================================================
   3. BOUTONS & FORMULAIRES STANDARDS
   ========================================================================== */
input:not([type="checkbox"]):not([type="submit"]), 
select, 
textarea {
    border-radius: var(--radius);
    border: 1px solid var(--couleur-bordure);
    padding: 8px;
    font-size: 14px;
}

input[type="submit"], 
button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 20px;
    border-radius: var(--radius);
    background: var(--couleur-grise);
    color: #000;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition-rapide);
    border: none;
    text-decoration: none;
}

input[type="submit"]:hover, 
button:hover {
    background: var(--couleur-primaire-hover);
    color: #fff;
}

.btn-cancel-search {
    padding: 0 !important;
    background: none !important;
    border: none !important;
}

/* ==========================================================================
   4. BANNIÈRE UNIVERSELLE (NAVIGATION EN GRILLE STRICTE)
   ========================================================================== */

#container-top { 
    position: sticky; 
    top: 0; 
    z-index: 2000; 
    background: #fff;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    padding: 15px 0; 
    margin-bottom: 20px;
}

/* Le conteneur principal avec l'espace latéral ajusté */
#banniere, .banniere-grille {
    display: grid;
    grid-template-columns: repeat(8, 1fr); 
    gap: 10px;
    width: 100%;
    max-width: 100%; /* <-- CORRECTION : On redonne la pleine largeur */
    margin: 0;       /* <-- CORRECTION : On enlève la marge automatique */
    padding: 0 20px; /* C'est ici qu'on crée ton espace à gauche et à droite */
    align-items: center;
}

/* La "case" invisible qui maintient l'espace */
.inside_banniere, .banniere-slot {
    display: flex;
    justify-content: center; /* Les boutons du centre restent centrés dans leur case */
    align-items: center;
    height: 100%;
    width: 100%;
}

/* Force le premier bouton (gauche) à s'aligner sur la ligne du padding */
.banniere-slot:first-child {
    justify-content: flex-start;
}

/* Force le dernier bouton (droite) à s'aligner sur la ligne du padding */
.banniere-slot:last-child {
    justify-content: flex-end;
}

/* Les boutons de navigation à l'intérieur de la grille */
#banniere .btn-nav, .btn-nav {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;            
    max-width: 160px;       
    height: 40px;
    padding: 0 15px;      
    font-size: 14px;
    font-weight: bold;
    text-align: center;
    background-color: var(--couleur-grise);
    color: #333 !important;
    border: 1px solid var(--couleur-bordure);
    border-radius: var(--radius);
    text-decoration: none;
    transition: var(--transition-rapide);
    
    /* Gestion des textes trop longs */
    white-space: nowrap;    
    overflow: hidden;
    text-overflow: ellipsis;
}

#banniere .btn-nav:hover, .btn-nav:hover {
    background-color: var(--couleur-primaire) !important;
    color: #fff !important;
    border-color: var(--couleur-primaire);
}

/* État désactivé (ex: Langue anglaise) */
.btn-nav.disabled, .disabled {
    background: var(--couleur-grise-pale) !important;
    color: #999 !important;
    cursor: not-allowed !important;
    border-color: var(--couleur-bordure) !important;
    opacity: 0.7;
    pointer-events: none; 
}

/* ==========================================================================
   5. TITRES & STRUCTURE GÉNÉRALE
   ========================================================================== */
h1, h2, h3 { 
    color: var(--couleur-primaire); 
    text-align: center; 
    margin-top: 20px;
}

/* ==========================================================================
   5. LISTE VIDE
   ========================================================================== */
.aucun-item {
    color: var(--couleur-primaire);
    font-size: 16px;
    font-weight: bold;
    padding: 15px;
    border: 2px dashed var(--couleur-primaire);
    border-radius: 8px; 
    width: 50%;
    max-width: 600px; 
    background-color: #fdf7ff; 
    margin: 30px auto;
    text-align: center;
    box-shadow: 0 4px 10px rgba(0,0,0,0.05); 
}

/* ==========================================================================
   6. IMPRESSION (PRINT) & ACCESSIBILITÉ
   ========================================================================== */
@media print {
    .no_print { display: none !important; }
    body { width: 100%; margin: 0; padding: 0; }
}

/* ==========================================================================
   7. ÉLÉMENTS DÉSACTIVÉS & BULLES D'INFORMATION (TOOLTIPS)
   ========================================================================== */

/* Conteneur pour permettre le survol sur un élément disabled */
.tooltip-wrapper {
    display: inline-block;
    width: 100%;            /* Pour épouser la largeur du bouton dans la grille */
    max-width: 160px;       /* Aligné sur la taille de vos .btn-nav */
    cursor: not-allowed;    /* Affiche le curseur d'interdiction */
}

/* On s'assure que le bouton lui-même ne bloque pas les événements du wrapper */
.btn-nav.disabled {
    pointer-events: none; 
    opacity: 0.6;
}

/* Style de la bulle d'info (Tooltip navigateur amélioré) */
.tooltip-wrapper[title] {
    position: relative;
}

/* Note : On utilise ici l'attribut standard 'title' du navigateur pour 
   maximiser la compatibilité sans ajouter de JavaScript. */

/**
 * ========================================================
 * [ÉTAT : EN DÉVELOPPEMENT] Date : 23-05-2026 18:42:00
 * FICHIER : banniere_survol.css
 * RÔLE : Styles pour la barre de navigation avec menus déroulants
 * Auteurs : Yvan Dubé & Gemini (IA Collaboratrice)
 * =========================================================
 */

#banniere-survol {
    background-color: #f8f9fa; /* Ajuste avec la couleur de fond que tu désires */
    border-bottom: 1px solid #ddd;
    padding: 0.5rem 2rem;
    display: flex;
    justify-content: center; /* Centre le menu, utilise 'flex-start' si tu le veux à gauche */
}

.menu-principal {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    gap: 1rem;
    align-items: center;
}

.menu-principal > li {
    position: relative; /* Indispensable pour positionner le sous-menu */
}

.nav-item {
    display: block;
    padding: 0.8rem 1.5rem;
    text-decoration: none;
    color: #333;
    font-weight: 500;
    border-radius: 6px;
    transition: background-color 0.2s, color 0.2s;
}

.nav-item:hover, .nav-item.active {
    background-color: #e2e8f0; /* Un bleu-gris très léger */
    color: #0056b3;
}

.nav-item.disabled {
    color: #aaa;
    cursor: not-allowed;
}

/* --- Menu déroulant (Dropdown) --- */
.dropdown-menu {
    display: none; /* Masqué par défaut */
    position: absolute;
    top: 100%;
    left: 0;
    background-color: #ffffff;
    min-width: 220px;
    box-shadow: 0 8px 16px rgba(0,0,0,0.1);
    border: 1px solid #ddd;
    border-radius: 6px;
    list-style: none;
    padding: 0.5rem 0;
    z-index: 1000; /* Assure que le menu passe par-dessus le contenu */
}

/* Apparition du menu au survol du <li> parent */
.dropdown:hover .dropdown-menu {
    display: block;
}

.dropdown-menu li a {
    display: block;
    padding: 0.6rem 1.5rem;
    text-decoration: none;
    color: #444;
    transition: background-color 0.2s;
}

.dropdown-menu li a:hover {
    background-color: #f1f5f9;
    color: #0056b3;
}

/* Ligne de séparation dans le menu */
.dropdown-menu .separator {
    height: 1px;
    background-color: #eee;
    margin: 0.5rem 0;
}
/******************/
/* Titres de sous-sections à l'intérieur des menus déroulants */
.dropdown-menu .dropdown-header {
    padding: 0.4rem 1.2rem;
    font-size: 0.8rem;
    text-transform: uppercase;
    color: #888;
    font-weight: bold;
    letter-spacing: 0.5px;
    background-color: #f9f9f9;
    pointer-events: none; /* Empêche le survol ou le clic */
    margin-top: 0.2rem;
}