/* NEUTRALISATION AGRESSIVE DES STYLES SPIP NATIFS */
#page, .contenu, .contenu-pied, .spip, .spip_div, .formulaire_spip {
    margin: 0 !important;
    padding: 0 !important;
    border: none !important;
    background: transparent !important;
    width: auto !important;
    float: none !important;
    clear: none !important;
}

/* Force votre body à reprendre le dessus */
body {
    margin: 0 !important; /* Souvent écrasé par SPIP sur mobile */
    padding: 0 !important;
    overflow-x: hidden !important;
}

/* RESET & BASE */
* { margin: 0; padding: 0; box-sizing: border-box; }

body { 
    font-family: 'Georgia', 'Times New Roman', serif; 
    line-height: 1.6; 
    color: #333; 
    background-color: #fcfafb;
    overflow-x: hidden;
}

a { text-decoration: none; color: inherit; transition: 0.3s; }
ul { list-style: none; }

/* VARIABLES COULEURS */
:root {
    --primary-violet: #8B1C5B; /* Couleur exacte du logo */
    --dark-violet: #5a0f3a;
    --light-bg: #fcfafb;
    --text-grey: #555;
    --header-height: 80px;
}

/* HEADER & NAVIGATION */
header {
    position: fixed;
    top: 0;
    width: 100%;
    background: #fff;
    box-shadow: 0 2px 15px rgba(139, 28, 91, 0.1);
    z-index: 80;
    transition: transform 0.4s ease-in-out;
    border-bottom: 1px solid var(--primary-violet);
    height: var(--header-height);
    display: flex;
    align-items: center;
}

header.hidden { transform: translateY(-100%); }

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 2rem;
}

/* LOGO */
.logo-container img {
    height: 55px;
    width: auto;
    display: block;
    z-index: 10;
}

/* MENU DESKTOP */
.main-menu { display: flex; gap: 2rem; }
.main-menu > li {
    position: relative; /* Nécessaire pour positionner la fausse barre */
    padding: 10px 0;
    cursor: pointer;
    font-weight: bold;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--primary-violet);
    transition: color 0.3s ease; /* Transition uniquement sur la couleur du texte */
}
/* --- LA FAUSSE BARRE (Pseudo-élément) --- */
.main-menu > li::after {
    content: '';
    position: absolute;
    width: 0; /* Invisible par défaut */
    height: 3px;
    background-color: var(--primary-violet);
    bottom: 0; /* Positionnée en bas */
    left: 50%; /* Centrée horizontalement */
    transform: translateX(-50%); /* Ajustement du centrage */
    transition: width 0.3s ease; /* Animation fluide de la largeur */
}
.main-menu > li:hover {
    color: var(--dark-violet); /* Le texte fonce */
    /* Pas de border, pas de padding changeant = pas de saut ! */
}
.main-menu > li:hover::after {
    width: 100%; /* La barre s'étend sur toute la largeur */
}
.main-menu > li.active {
    color: var(--dark-violet);
}

.main-menu > li.active::after {
    width: 100%; /* La barre est toujours visible à 100% */
}


/* SOUS-MENU DESKTOP */
.submenu {
    position: absolute;
    top: 100%;
    left: 0;
    
    background: #fff;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    min-width: 220px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.3s ease;
    border-top: 3px solid var(--primary-violet);
    border: 1px solid #eee;
}
.main-menu > li:hover .submenu { opacity: 1; visibility: visible; transform: translateY(0); }
.submenu li a { 
    display: block; 
    padding: 0.9rem 1.2rem; 
    font-size: 0.85rem; 
    border-bottom: 1px solid #f5f5f5; 
    color: var(--text-grey);
    text-transform: none;
    font-family: 'Georgia', serif;
}
.submenu li a:hover { 
    background: #fcfafb; 
    color: var(--primary-violet); 
    padding-left: 1.5rem; 
}

/* BURGER MENU (Caché sur Desktop) */
.burger {
    display: none;
    cursor: pointer;
    flex-direction: column;
    gap: 5px;
}
.burger div {
    width: 25px;
    height: 3px;
    background-color: var(--primary-violet);
    transition: all 0.3s ease;
}


/* HERO SECTION */
.hero {
    height: 80vh;
    background: linear-gradient(rgba(139, 28, 91, 0.7), rgba(90, 15, 58, 0.8)), 
                url('https://images.unsplash.com/photo-1503095396549-807759245b35?ixlib=rb-1.2.1&auto=format&fit=crop&w=1950&q=80');
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: #fff;
    padding: 0 20px;
    margin-top: var(--header-height);
}
.hero-content h1 { 
    font-size: 3.8rem; 
    margin-bottom: 1rem; 
    font-style: italic; 
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}
.hero-content p { 
    font-size: 1.3rem; 
    max-width: 650px; 
    margin: 0 auto 2.5rem auto; 
    font-family: 'Helvetica', sans-serif; 
    font-weight: 300;
}
.btn-cta {
    background: var(--primary-violet);
    color: #fff;
    padding: 1.1rem 2.5rem;
    font-size: 0.95rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    display: inline-block;
    border: 2px solid var(--primary-violet);
    font-weight: bold;
	transition: all 0.3s ease;
}
.btn-cta:hover { background: #fff; color: var(--primary-violet); border: 2px solid var(--primary-violet); }

/* --- GRILLE DES SPECTACLES --- */
.programs-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr); /* 2 colonnes par défaut */
    gap: 2rem;
    margin-top: 2rem;
}

/* CLASSE SPÉCIFIQUE POUR LA MISE EN AVANT (Remplace :first-child) */
.program-card.mise-en-avant {
    grid-column: 1 / -1; /* S'étend sur toute la largeur (2 colonnes) */
    display: flex;
    flex-direction: row; 
    background: #fff;
    border: 1px solid #eee;
    border-left: 6px solid var(--primary-violet);
    box-shadow: 0 10px 30px rgba(139, 28, 91, 0.1);
    overflow: hidden;
}

/* Ajustements internes pour la mise en avant */
.program-card.mise-en-avant .card-image {
    width: 50%;
    height: auto;
    min-height: 350px;
    flex-shrink: 0;
}

.program-card.mise-en-avant .card-content {
    width: 50%;
    padding: 3rem;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.program-card.mise-en-avant .card-title {
    font-size: 2.2rem;
    margin-bottom: 1rem;
}

.program-card.mise-en-avant .card-excerpt {
    font-size: 1.1rem;
    margin-bottom: 2rem;
}

.program-card.mise-en-avant .card-btn {
    align-self: flex-start;
    padding: 1rem 2.5rem;
    font-size: 1rem;
}

/* MOBILE : On annule la mise en avant pour tout empiler proprement */
@media (max-width: 900px) {
    .programs-grid {
        grid-template-columns: 1fr;
    }
    
    .program-card.mise-en-avant {
        flex-direction: column;
        grid-column: auto;
    }
    
    .program-card.mise-en-avant .card-image,
    .program-card.mise-en-avant .card-content {
        width: 100%;
    }
    
    .program-card.mise-en-avant .card-image {
        min-height: 200px;
    }
}





/* CONTENT STYLES */
.container { max-width: 1000px; margin: 5rem auto; padding: 0 20px; }
.welcome-section { text-align: center; margin-bottom: 5rem; }
.welcome-section h2 { font-size: 2.5rem; color: var(--primary-violet); margin-bottom: 1.5rem; font-style: italic; }
.welcome-section p { font-size: 1.15rem; color: var(--text-grey); text-align: justify; line-height: 1.8; }

.section-title-container {
    text-align: center;
    margin-bottom: 3rem; /* Espace entre le titre et la carte du spectacle */
}

.section-title {
    font-size: 2.2rem;
    color: var(--primary-violet);
    font-style: italic; /* Rappel du logo */
    font-weight: normal;
    margin-bottom: 1rem;
}

.title-separator {
    width: 60px;
    height: 3px;
    background-color: var(--dark-violet);
    margin: 0 auto; /* Centré */
}



.next-show {
    display: flex;
    background: #fff;
    box-shadow: 0 15px 40px rgba(139, 28, 91, 0.1);
    border-left: 6px solid var(--primary-violet);
}
.show-image { 
    flex: 1; 
    background: #ddd; 
    min-height: 350px; 
    overflow: hidden;  
}
.show-image img {
    width: 100%;
    height: 100%;
    object-fit: cover; /* L'image couvre tout l'espace sans être déformée */
    display: block;
}
.show-info { flex: 1; padding: 3.5rem; display: flex; flex-direction: column; justify-content: center;
	align-items: center; /* AJOUT : Centre horizontalement le contenu (titre, texte, bouton) */
    text-align: center;  /* AJOUT : Centre le texte */ }
.show-info h3 { font-size: 2rem; margin-bottom: 0.5rem; color: var(--dark-violet); font-style: italic; }
.show-date { color: var(--primary-violet); font-weight: bold; margin-bottom: 1.2rem; display: block; font-family: 'Helvetica', sans-serif; text-transform: uppercase; letter-spacing: 1px; font-size: 0.85rem; }
.show-desc { margin-bottom: 2.2rem; color: #666; line-height: 1.7; font-size: 1.05rem; text-align: justify; }

/* --- BOUTON RETOUR FICHE SPECTACLE --- */
.btn-retour {
    display: inline-block;
    color: var(--primary-violet);
    font-size: 0.95rem;
    font-weight: bold;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding: 10px 20px;
    border: 1px solid var(--primary-violet);
    border-radius: 30px; /* Bords arrondis pour un style plus doux */
    transition: all 0.3s ease;
    text-decoration: none;
}

.btn-retour:hover {
    background-color: var(--primary-violet);
    color: #fff;
    transform: translateX(-5px); /* Petit déplacement vers la gauche pour indiquer le "retour" */
    box-shadow: 0 4px 10px rgba(139, 28, 91, 0.2);
}

/* Ajustement Mobile */
@media (max-width: 900px) {
    .btn-retour {
        width: 100%;
        max-width: 250px;
        text-align: center;
    }
}

/* =========================================
   HABILLAGE DES COMMENTAIRES & FORUMS (ATP Lunel)
   ========================================= */

/* --- CONTENEUR PRINCIPAL --- */
.comments {
    margin-top: 3rem;
    padding: 2rem 0;
    border-top: 2px solid #f0f0f0; /* Bordure fine au lieu de 10px brute */
    font-family: 'Helvetica', sans-serif;
}

.comments h3, .forum-titre h3 {
    font-family: 'Georgia', serif;
    font-size: 1.8rem;
    color: var(--primary-violet);
    font-style: italic;
    margin-bottom: 1.5rem;
}

/* --- LISTE DES COMMENTAIRES --- */
.comments ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

/* --- ITEM INDIVIDUEL --- */
.comment-item {
    margin: 1.5rem 0;
    padding: 1.5rem;
    background: #fcfafb; /* Fond très légèrement teinté */
    border: 1px solid #e0e0e0;
    border-left: 4px solid var(--primary-violet); /* La touche ATP */
    border-radius: 4px;
    transition: transform 0.2s;
}

.comment-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(139, 28, 91, 0.1);
}

/* --- RÉPONSES IMBRIQUÉES (Niveau 2) --- */
.comments-items .comments-items {
    margin-left: 30px;
    padding-left: 20px;
    border-left: 2px solid #ddd; /* Ligne de connexion discrète */
    position: relative;
}
/* Petit indicateur visuel pour les réponses */
.comments-items .comments-items::before {
    content: '↩';
    position: absolute;
    left: -12px;
    top: 10px;
    color: #ccc;
    font-size: 1.2rem;
}

/* --- MÉTADONNÉES (Auteur, Date) --- */
.comment-meta {
    margin: 0 0 0.8rem 0;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.comment-meta strong {
    color: var(--dark-violet);
    font-weight: bold;
    font-size: 1rem;
}

.comment-meta small {
    color: #999;
    font-size: 0.85rem;
    font-weight: normal;
}

.comment-meta a {
    text-decoration: none;
    color: var(--primary-violet);
    transition: color 0.2s;
}

.comment-meta a:hover {
    color: var(--dark-violet);
    text-decoration: underline;
}

/* --- CONTENU DU MESSAGE --- */
.comment-content {
    color: var(--text-grey);
    line-height: 1.6;
    font-size: 0.95rem;
    overflow-wrap: break-word;
}

.comment-content p {
    margin-bottom: 0.8rem;
    text-align: left;
}

.comment-content .hyperlien {
    color: var(--primary-violet);
    font-weight: 600;
    text-decoration: underline;
    background: transparent;
    padding: 0;
}

/* --- FORMULAIRE DE COMMENTAIRE / FORUM --- */
.forum-titre {
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 2px dashed #ddd; /* Ligne pointillée pour séparer */
}

.formulaire_forum {
    background: #fff;
    padding: 2rem;
    /*border: 1px solid #eee;*/
    border-radius: 4px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    margin-top: 1.5rem;
}

.formulaire_forum legend {
    display: none;
}

/* Champs du formulaire */
.formulaire_forum input[type="text"],
.formulaire_forum input[type="email"],
.formulaire_forum textarea {
    width: 100%;
    padding: 12px;
    margin-bottom: 1rem;
    /*border: 1px solid #ccc;*/
    border-radius: 2px;
    font-family: 'Helvetica', sans-serif;
    font-size: 0.95rem;
    background: #fcfafb;
    transition: border-color 0.3s, background 0.3s;
    box-sizing: border-box; /* Important pour ne pas dépasser */
}

.formulaire_forum input:focus,
.formulaire_forum textarea:focus {
    outline: none;
    border-color: var(--primary-violet);
    background: #fff;
}

.formulaire_forum textarea {
    min-height: 120px;
    resize: vertical;
}

/* Explications (italique) */
.formulaire_forum .saisie_texte .explication {
    font-size: 0.85rem;
    font-style: italic;
    color: #888;
    margin: -0.5rem 0 1rem 0;
    display: block;
}

/* Bouton d'envoi */
.formulaire_forum .boutons {
    margin-top: 1.5rem;
    text-align: right;
}

.formulaire_forum input[type="submit"],
.formulaire_forum button {
    background: var(--primary-violet);
    color: #fff;
    border: none;
    padding: 12px 25px;
    font-size: 0.9rem;
    font-weight: bold;
    text-transform: uppercase;
    border-radius: 2px;
    cursor: pointer;
    transition: background 0.3s;
    font-family: 'Helvetica', sans-serif;
    letter-spacing: 0.5px;
}

.formulaire_forum input[type="submit"]:hover,
.formulaire_forum button:hover {
    background: var(--dark-violet);
}

/* Masquer les champs techniques inutiles */
.formulaire_forum .session_qui {
    display: none;
}

/* Mobile */
@media (max-width: 768px) {
    .comments-items .comments-items {
        margin-left: 10px;
        padding-left: 10px;
    }
    .formulaire_forum {
        padding: 1.5rem;
    }
    .formulaire_forum .boutons {
        text-align: center;
    }
    .formulaire_forum input[type="submit"],
    .formulaire_forum button {
        width: 100%;
    }
}

/* Mobile */
@media (max-width: 900px) {
    .section-nav-links {
        flex-direction: column;
        gap: 0.8rem;
        align-items: center;
    }
    .nav-item {
        width: 100%;
        max-width: 300px;
        justify-content: center;
    }
}

/* FOOTER */
footer {
    background: var(--dark-violet);
    color: #fff;
    text-align: center;
    padding: 2rem;
    margin-top: 4rem;
    font-size: 0.9rem;
}

/* --- RESPONSIVE MOBILE & TABLETTE --- */
@media (max-width: 900px) {
    .nav-container { padding: 0 1.5rem; }
    
    /* Afficher le burger */
    .burger { display: flex; z-index: 1002; }
    
    /* Animation Burger en X */
    .burger.toggle .line1 { transform: rotate(-45deg) translate(-5px, 6px); }
    .burger.toggle .line2 { opacity: 0; }
    .burger.toggle .line3 { transform: rotate(45deg) translate(-5px, -6px); }

    /* Menu Mobile Panel */
    .main-menu {
        position: fixed;
        top: 0;
        right: -100%;
        height: 100vh;
        width: 70%; /* RÉDUIT de 80% à 70% pour laisser plus de place au contenu */
        max-width: 280px; /* Largeur max réduite (était 300px) */
        background: #fff;
        flex-direction: column;
        align-items: flex-start;
        padding: 70px 15px 20px 15px; /* Padding réduit sur les côtés */
        gap: 0;
        transition: right 0.4s ease-in-out;
        box-shadow: -5px 0 15px rgba(0,0,0,0.1);
        overflow-y: auto;
    }
    .main-menu.active { right: 0; }
	

    .main-menu > li {
    	width: 100%;
    	border-bottom: 1px solid #eee;
    	padding: 12px 15px;
    	font-size: 0.85rem;

    	display: block;

    	line-height: 1.2;
    	transition: all 0.3s ease;
	}
	
	.main-menu > li > span,
	.main-menu > li > a {
    	display: block;
    	width: 100%;
	}
    /* EFFET DE SURVOL LÉGER */
    .main-menu > li:hover {
        background-color: #fcfafb;
        color: var(--dark-violet);
        padding-left: 20px; /* Léger déplacement vers la droite */
    }
	
	.main-menu > li.active {
        color: var(--dark-violet);
        font-weight: 700; /* Texte gras */
        background-color: #f4f0f3; /* Fond violet très pâle */
        border-left: none; /* Supprime toute barre verticale */
        border-top: none; /* Supprime la barre du haut visible sur la capture */
        border-bottom: 1px solid #e0e0e0; /* Garde juste la séparation fine en bas */
        padding-left: 15px; /* Alignement normal */
    }
	
	/* Survol sur la page active */
    .main-menu > li.active:hover {
        padding-left: 20px; /* Garde l'effet de déplacement */
        background-color: #ede6ec; /* Fond un peu plus foncé au survol */
    }


.main-menu > li:hover:not(.active) { 
    color: var(--dark-violet); 
    opacity: 0.8;
}

    /* Sous-menu Mobile Accordéon */
    .submenu {
        position: static;
        visibility: visible;
        opacity: 1;
        transform: none;
        box-shadow: none;
        border: none;
        background: #fcfafb;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.4s ease-out;
        width: 100%;
        min-width: 0;
        padding-left: 15px; /* Indentation réduite */
    }
    .submenu.open { max-height: 500px; }
    
    .submenu li a {
        padding: 8px 0;
        font-size: 0.8rem;
        border-bottom: 1px solid #eaeaea;
    }



    /* Logo centré sur mobile */
    .logo-container {
        position: absolute;
        left: 50%;
        transform: translateX(-50%);
    }
    .logo-container img { height: 45px; }

    /* Ajustements contenu */
    .hero-content h1 { font-size: 2.5rem; }
    .next-show { flex-direction: column; }
    .show-image { min-height: 250px; }
    .show-info { padding: 2rem; }
	

    .section-title {
        font-size: 1.8rem;
    }
    .section-title-container {
        margin-bottom: 2rem;
    }
	.show-image {
    min-height: 180px; /* Ajustement hauteur mobile si nécessaire */
	}
	.show-image img {
        height: 100%; /* Force l'image à remplir le nouveau conteneur réduit */
		object-fit: cover; /* Pour remplir le bloc joliment */
    }
	.show-info {
        padding: 2rem;
        align-items: center; /* S'assurer que c'est bien centré sur mobile aussi */
        text-align: center;
    }
    
    .btn-cta {
        width: 100%;         /* Sur mobile, on peut mettre le bouton en pleine largeur si désiré */
        max-width: 300px;    /* Mais avec une limite pour que ce soit joli */
    }
    
    /* Correction hover mobile spécifique si besoin */
    .btn-cta:hover {
        background: #fff;
        color: var(--primary-violet);
        border: 2px solid var(--primary-violet);
    }

}

