/* Timeline CSS - Adaptation aux nouvelles maquettes avec zone dynamique */

/* Reset de base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Page principale avec header fixe */
.timeline-page {
    padding-top: 80px; /* Hauteur du header fixe */
}

/* Ajustement pour le breadcrumb */
.timeline-body .breadcrumb {
    z-index: 2;
    margin-top: 10px;
}

/* Styles dynamiques pour le fil d'Ariane selon le type de slide */
.timeline-body .breadcrumb.breadcrumb-white {
    color: white;
}

.timeline-body .breadcrumb.breadcrumb-white a {
    color: white;
}

.timeline-body .breadcrumb.breadcrumb-white .breadcrumb-separator {
    color: white;
}

.timeline-body .breadcrumb.breadcrumb-white .breadcrumb-chevron {
    color: white;
}

.timeline-body .breadcrumb.breadcrumb-white span {
    color: white;
}

.timeline-body .breadcrumb.breadcrumb-black {
    color: black;
}

.timeline-body .breadcrumb.breadcrumb-black a {
    color: black;
}

.timeline-body .breadcrumb.breadcrumb-black .breadcrumb-separator {
    color: black;
}

.timeline-body .breadcrumb.breadcrumb-black .breadcrumb-chevron {
    color: black;
}

.timeline-body .breadcrumb.breadcrumb-black span {
    color: black;
}

/* Container principal de la timeline */
.timeline-container {
    width: 100%;
    height: 100vh; /* Hauteur complète de la fenêtre */
    position: relative;
    background: white;
    margin-top: -80px; /* Compenser le padding-top du .timeline-page */
}

.timeline-swiper {
    width: 100%;
    height: 100%;
    position: relative;
}

.timeline-slide {
    display: flex;
    align-items: center;
    background: white;
    width: 100%;
    height: 100%;
}

.timeline-slide-content {
    width: 100%;
    height: 100%;
    position: relative;
    display: flex;
    align-items: center;
}

.timeline-text-content {
    padding: 11rem 5% 0 100px;
}

/* ==================================
   HOME SLIDE LAYOUT (slide d'accueil)
   ================================== */
.timeline-home-layout {
    display: flex;
    width: 100%;
    height: 100%;
    position: relative;
}

.timeline-home-content {
    display: flex;
    width: 100%;
    height: 100%;
    align-items: center;
}

.timeline-home-text {
    flex: 0 0 50%;
    padding: 12rem 5% 0 100px; /* Espace pour le breadcrumb */
    background: #900C22;
    display: flex;
    flex-direction: column;
    height: 100%;
    color: white;
    position: relative;
    overflow: hidden;
}

/* Galet SVG décoratif en bas à gauche pour home slide */
.timeline-home-galet {
    position: absolute;
    bottom: -35px;
    left: -77px;
    width: 601px;
    height: 400px;
    z-index: 1;
    pointer-events: none;
}

/* Galet SVG blanc pour les autres slides */
.timeline-galet-white {
    position: absolute;
    bottom: -35px;
    left: -77px;
    width: 601px;
    height: 400px;
    z-index: 1;
    pointer-events: none;
}

/* Breadcrumb dans toutes les slides - positionnement absolu en haut */
.timeline-slide .breadcrumb {
    position: absolute;
    top: 100px; /* Sous le header fixe (80px) + marge */
    left: 5%;
    right: 5%;
    margin: 0;
    padding: 0;
    z-index: 10;
    display: block;
}

/* Breadcrumb dans la home slide (fond rouge) */
.timeline-body .breadcrumb a,
.timeline-body .breadcrumb span {
    color: white;
    text-decoration: none;
}

.timeline-body .breadcrumb a:hover {
    text-decoration: underline;
}

/* Breadcrumb dans les slides text-only (fond rouge) - position spécifique */
.timeline-text-only-layout .breadcrumb {
    position: fixed !important;
    top: 100px !important;
    left: 8% !important;
    right: auto !important;
    width: auto !important;
    z-index: 100 !important;
    margin: 0 !important;
    padding: 0 !important;
    text-align: left !important;
}

.timeline-text-only-layout .breadcrumb a,
.timeline-text-only-layout .breadcrumb span {
    color: white;
    text-decoration: none;
}

.timeline-text-only-layout .breadcrumb a:hover {
    text-decoration: underline;
}

/* Breadcrumb dans les autres slides (fond blanc) */
.timeline-one-image-layout .breadcrumb a,
.timeline-two-images-layout .breadcrumb a,
.timeline-video-layout .breadcrumb a {
    color: #333;
    text-decoration: none;
}

.timeline-one-image-layout .breadcrumb span,
.timeline-two-images-layout .breadcrumb span,
.timeline-video-layout .breadcrumb span {
    color: #666;
}

.timeline-one-image-layout .breadcrumb a:hover,
.timeline-two-images-layout .breadcrumb a:hover,
.timeline-video-layout .breadcrumb a:hover {
    text-decoration: underline;
}

.timeline-home-title {
    font-size: 48px;
    font-weight: bold;
    line-height: 1.2;
    margin-bottom: 2rem;
    position: relative;
    z-index: 2;
}

.timeline-home-description {
    font-size: 18px;
    line-height: 1.6;
    position: relative;
    z-index: 2;
}

.timeline-home-image {
    flex: 1;
    height: 100%;
    overflow: hidden;
    background: #f5f5f5; /* Couleur de fond si pas d'image */
    display: flex;
    align-items: center;
}

.timeline-home-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Placeholder si pas d'image */
.timeline-home-layout:not(:has(.timeline-home-image img)) .timeline-home-image::after {
    content: "Image à venir";
    color: #999;
    font-style: italic;
}

/* ==================================
   ONE IMAGE SLIDE LAYOUT
   ================================== */

/* Fond rouge sur la partie droite pour toutes les slides sauf home-slide */
.timeline-one-image-layout::after,
.timeline-two-images-layout::after,
.timeline-video-layout::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 20%;
    height: 100%;
    background: #AF0522;
    z-index: 0;
}

.timeline-one-image-layout .timeline-content-wrapper {
    display: flex;
    width: 100%;
    height: 100%;
    align-items: center;
}

.timeline-one-image-layout .timeline-text-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    height: 100%;
    position: relative;
    z-index: 1;
}

.timeline-one-image-layout .timeline-main-image {
    margin-right: 80px;
    position: relative;
    z-index: 1;
}

.timeline-one-image-layout .timeline-main-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.timeline-one-image-layout .timeline-main-image img {
    border-radius: 24px;
}

/* ==================================
   TEXT ONLY SLIDE LAYOUT
   ================================== */
.timeline-text-only-layout {
    display: flex;
    width: 100%;
    height: 100%;
    background: #AF0522;
    position: relative;
    overflow: hidden;
    align-items: center;
    justify-content: center;
}

/* Galet SVG rouge centré pour text-only layout */
.timeline-galet-red-center {
    position: absolute;
    top: 70%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 800px;
    height: 600px;
    z-index: 1;
    pointer-events: none;
}

.timeline-text-only-layout .timeline-text-content {
    color: white;
    z-index: 2;
    position: relative;
    max-width: 70%;
    text-align: center;
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

/* ==================================
   TWO IMAGES SLIDE LAYOUT
   ================================== */
.timeline-one-image-layout,
.timeline-two-images-layout,
.timeline-video-layout {
    display: flex;
    width: 100%;
    height: 100%;
    background: #F6F6F6;
    position: relative;
    overflow: hidden;
}


.timeline-two-images-layout .timeline-content-wrapper {
    display: flex;
    width: 100%;
    height: 100%;
    align-items: center;
}

.timeline-two-images-layout .timeline-text-content {
    flex: 0 0 40%; /* Prend 40% de la largeur au lieu de flex: 1 */
    display: flex;
    flex-direction: column;
    height: 100%;
    position: relative;
    z-index: 1;
}

.timeline-two-images-layout .timeline-images-grid {
    flex: 1;
    height: 100%;
    display: flex;
    flex-wrap: wrap;
    align-content: center;
    padding: 2rem;
    gap: 2rem;
    position: relative;
    z-index: 1;
}

.timeline-two-images-layout .timeline-image {
    width: 280px;
    height: 200px;
    overflow: hidden;
    border-radius: 8px;
    position: relative;
}

/* Décalage vertical - première image (gauche) plus haute */
.timeline-two-images-layout .timeline-image:first-child {
    align-self: flex-start;
    margin-top: -20px;
}

/* Deuxième image (droite) plus basse */
.timeline-two-images-layout .timeline-image:last-child {
    align-self: flex-end;
    margin-top: 20px;
}

.timeline-two-images-layout .timeline-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* ==================================
   VIDEO SLIDE LAYOUT
   ================================== */

.timeline-video-layout .timeline-content-wrapper {
    display: flex;
    width: 100%;
    height: 100%;
    align-items: center;
}

.timeline-video-layout .timeline-text-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    height: 100%;
}

.timeline-video-layout .timeline-video {
    flex: 2;
    height: 100%;
    display: flex;
    flex-direction: column;
    padding: 2rem;
    justify-content: center;
    align-items: center;
}

.timeline-video-layout .timeline-video video {
    width: 100%;
    height: auto;
    max-height: 70%;
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    z-index: 1;
}

.timeline-video-caption {
    margin-top: 1rem;
    font-size: 14px;
    color: #900C22;
    text-align: left;
    position: relative;
    z-index: 2;
    align-self: flex-start;
    width: 100%;
}

/* ==================================
   STYLES COMMUNS POUR LES ÉLÉMENTS DE TEXTE
   ================================== */
.timeline-year {
    font-size: 96px;
    font-weight: bold;
    color: #8b1428;
    display: block;
    margin-bottom: 1rem;
    line-height: 1;
}

.timeline-title {
    font-size: 1.8rem;
    font-weight: bold;
    color: #900C22;
    margin-bottom: 1.5rem;
    line-height: 1.3;
    z-index: 1;
}

.timeline-description {
    font-size: 1rem;
    line-height: 1.6;
    color: #000000;
    z-index: 1;
}

/* Styles spéciaux pour text-only layout */
.timeline-text-only-layout .timeline-year,
.timeline-text-only-layout .timeline-title,
.timeline-text-only-layout .timeline-description {
    color: white;
}

/* ==================================
   NAVIGATION TIMELINE (selon maquette)
   ================================== */
.timeline-navigation {
    position: absolute;
    bottom: 5%;
    left: 50%;
    transform: translateX(-50%);
    background: white;
    border-radius: 24px;
    padding: 20px 40px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: center;
    gap: 2rem;
    z-index: 100;
}

/* Ligne grise entre le premier et dernier point */
.timeline-nav-dots::before {
    content: '';
    position: absolute;
    top: 79%;
    left: 0;
    right: 0;
    height: 1px;
    background: #e0e0e0;
    z-index: 1;
}

/* Style CTA secondaire pour les boutons précédent/suivant */
.timeline-nav-button {
    padding: 10px 20px;
    border: 1px solid #c41e3a;
    background: white;
    border-radius: 25px;
    cursor: pointer;
    font-size: 0.9rem;
    color: black;
    transition: all 0.3s ease;
    white-space: nowrap;
    display: flex;
    align-items: center;
    gap: 5px;
}

.timeline-nav-button:hover {
    background: #c41e3a;
    color: white;
}

.timeline-nav-button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    background: white;
    color: #999;
    border-color: #ddd;
}

.timeline-nav-button:disabled:hover {
    background: white;
    color: #999;
    border-color: #ddd;
}

.timeline-nav-dots {
    display: flex;
    align-items: center;
    gap: 2rem;
    position: relative;
}


.timeline-nav-dot {
    position: relative;
    cursor: pointer;
    padding: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    transition: all 0.3s ease;
    z-index: 3;
}

.timeline-nav-dot-circle {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #999;
    transition: all 0.3s ease;
    order: 2;
    position: relative;
    z-index: 3;
}

/* Point sélectionné - cercle rouge avec anneau blanc et bordure rouge */
.timeline-nav-dot.active .timeline-nav-dot-circle {
    width: 12px;
    height: 12px;
    background: #c41e3a;
    border-radius: 50%;
    border: 2px solid white;
    box-shadow: 0 0 0 1px #c41e3a;
}

/* Dates au-dessus des points */
.timeline-nav-dot-year {
    font-size: 0.8rem;
    color: #666;
    transition: all 0.3s ease;
    margin-bottom: 8px;
    order: 1;
}

.timeline-nav-dot.active .timeline-nav-dot-year {
    color: black;
    font-weight: bold;
    font-size: 0.9rem;
}

/* Effet hover sur les dates */
.timeline-nav-dot:hover .timeline-nav-dot-year {
    color: #c41e3a;
    text-decoration: underline;
}

/* Bouton suivant avec style CTA secondaire */
.timeline-nav-suivant {
    padding: 12px 24px;
    background: white;
    color: black;
    border: 1px solid #c41e3a;
    border-radius: 25px;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    white-space: nowrap;
}

.timeline-nav-suivant:hover {
    background: #c41e3a;
    color: white;
}

.timeline-nav-suivant::after {
    content: '→';
    font-size: 1rem;
}

.timeline-nav-suivant:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    background: white;
    color: #999;
    border-color: #ddd;
}

.timeline-nav-suivant:disabled:hover {
    background: white;
    color: #999;
    border-color: #ddd;
}

/* ==================================
   MASQUER LES CONTROLES SWIPER PAR DÉFAUT
   ================================== */
.swiper-button-prev,
.swiper-button-next,
.swiper-pagination {
    display: none;
}


/* ==================================
   RESPONSIVE DESIGN
   ================================== */

/* Tablettes */
@media (max-width: 768px) {
    .timeline-home-content,
    .timeline-one-image-layout .timeline-content-wrapper,
    .timeline-two-images-layout .timeline-content-wrapper,
    .timeline-video-layout .timeline-content-wrapper {
        flex-direction: column;
    }
    
    .timeline-home-text,
    .timeline-one-image-layout .timeline-text-content,
    .timeline-two-images-layout .timeline-text-content,
    .timeline-video-layout .timeline-text-content {
        flex: none;
        height: 50%;
        padding: 2rem;
    }
    
    .timeline-home-image,
    .timeline-one-image-layout .timeline-main-image,
    .timeline-two-images-layout .timeline-images-grid,
    .timeline-video-layout .timeline-video {
        flex: none;
        height: 50%;
    }
    
    .timeline-home-title {
        font-size: 2.5rem;
    }
    
    .timeline-year {
        font-size: 3rem;
    }
    
    .timeline-navigation {
        padding: 15px 20px;
        gap: 1rem;
    }
    
    .timeline-nav-dots {
        gap: 1rem;
    }
}

/* Mobiles */
@media (max-width: 480px) {
    .timeline-home-title {
        font-size: 2rem;
        margin-bottom: 1rem;
    }
    
    .timeline-year {
        font-size: 2.5rem;
    }
    
    .timeline-title {
        font-size: 1.4rem;
    }
    
    .timeline-navigation {
        padding: 10px 15px;
        gap: 0.5rem;
        bottom: 3%;
    }
    
    .timeline-nav-dots {
        gap: 0.5rem;
    }
    
    .timeline-nav-dot-year {
        font-size: 0.7rem;
    }
    
    .timeline-nav-suivant {
        padding: 8px 16px;
        font-size: 0.8rem;
    }
}

/* ==================================
   ÉTATS VIDES
   ================================== */
.timeline-slide--empty {
    background: #f8f9fa;
}

.timeline-empty-state {
    text-align: center;
    padding: 2rem;
}

.timeline-empty-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.timeline-empty-title {
    font-size: 1.5rem;
    color: #666;
    margin-bottom: 1rem;
}

.timeline-empty-description {
    color: #999;
    font-size: 1rem;
}