/* --- GRILLE FLEXIBLE (CENTRAGE DYNAMIQUE) --- */
.spec-grid {
    display: flex; /* On passe en Flex pour le centrage */
    flex-wrap: wrap; /* On permet le retour à la ligne */
    justify-content: center; /* C'est ici que la magie opère : tout est centré */
    gap: 40px;
    max-width: 1500px;
    margin: 0 auto;
    padding: 0 30px;
}

.spec-card {
    background: #ffffff !important;
    border: 4px solid black;
    box-shadow: var(--comedia-shadow);
    transition: 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    text-decoration: none !important;
    color: black !important;
    /* Largeur des cartes : environ 1/3 de la page moins le gap */
    flex: 0 1 420px; 
    min-width: 320px;
}

.spec-card:hover {
    transform: translate(-8px, -8px);
    box-shadow: 20px 20px 0px var(--comedia-pink);
}

.spec-body {
    padding: 30px;
    text-align: center;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    flex-grow: 1;
}

.spec-body h2 {
    font-family: 'Oswald';
    text-transform: uppercase;
    font-size: 1.8rem;
    margin-bottom: 10px;
}

.spec-date {
    font-weight: 800;
    text-transform: uppercase;
    color: var(--comedia-pink);
    font-size: 1.1rem;
    margin-bottom: 20px;
}

/* --- BOUTONS --- */
.btn-reserve {
    background: black;
    color: white;
    padding: 12px 20px;
    font-weight: 900;
    text-transform: uppercase;
    display: inline-block;
    border: none;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    text-decoration: none;
}

.spec-card:hover .btn-reserve {
    background: var(--comedia-pink);
    transform: scale(1.05);
    box-shadow: 0px 8px 20px rgba(191, 13, 92, 0.4);
    letter-spacing: 1px;
}

.badge-complet {
    background: #000;
    color: #fff;
    padding: 10px;
    font-weight: 900;
    text-transform: uppercase;
    border: 2px solid red;
}

/* --- RESPONSIVE --- */
@media (max-width: 768px) {
    .hero-section {
    height: 35vh;}
    .spec-card { flex: 0 1 100%; max-width: 600px; }
    .hero-title { padding: 20px; transform: none; width: 90%; transform: scale(1.1);}
    .stage-blur-zone { padding: 40px 0; }
}

.btn-back {
    background: white; color: black; border: 3px solid black;
    padding: 15px 40px; font-weight: 900; text-transform: uppercase;
    text-decoration: none; box-shadow: 6px 6px 0px var(--comedia-pink);
    display: inline-block; margin-top: 60px;
}
.btn-back:hover { background: black; color: white; transform: translate(-3px, 3px); }

/* --- CAROUSEL HAUTE COUTURE --- */
.carousel-custom {
    max-width: 1200px;
    margin: 40px auto;
    border: 5px solid black;
    box-shadow: 15px 15px 0px #000;
    background: #000;
    overflow: hidden;
}

/* --- LOGIQUE BUREAU (Priorité Hauteur) --- */
.carousel-img-wrapper {
    height: 550px;
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
}

.carousel-img-wrapper img {
    height: 100%;
    width: auto;
    max-width: 100%;
    object-fit: contain; /* On voit la photo en entier sans rognage */
}

/* --- LOGIQUE MOBILE (Priorité Largeur) --- */
@media (max-width: 768px) {
    .carousel-img-wrapper {
        height: 350px; /* On réduit la hauteur pour le mobile */
    }

    .carousel-img-wrapper img {
        
        height: 100% !important;
        object-fit: cover; /* La photo remplit le cadre pour un look pro sur tel */
    }
    
    .carousel-control-prev, .carousel-control-next {
        width: 50px;
    }
}
.carousel-inner {
    
    text-align: center !important;
    
}

    /* Style pour les spectacles passés */
.spec-card.past-event {
    filter: grayscale(1);
    opacity: 0.6;
    transition: 0.3s;
}
.spec-card.past-event:hover {
    opacity: 0.8;
}
.badge-passe {
    background-color: #6c757d;
    color: #fff;
    text-align: center;
    padding: 10px;
    font-family: 'Oswald', sans-serif;
    font-weight: 700;
    letter-spacing: 1px;
    border: 2px solid black;
    box-shadow: 4px 4px 0px #000;
}