/* ===== SORTIE.CSS - VERSION COMPLÈTE & CORRIGÉE ===== */

/* ... (toutes tes autres règles comme le header, la sidebar, etc. que je remets pour être complet) ... */

/* ----- HEADER DE LA SORTIE ----- */
.sortie-header { position: relative; padding: 4rem 1.5rem 3rem; color: #fff; background-color: var(--gray-700, #334155); background-size: cover; background-position: center; text-align: center; min-height: 30vh; display: flex; flex-direction: column; justify-content: center; align-items: center; border-bottom: 5px solid var(--accent-color, #3b82f6); }
.header-overlay { position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: linear-gradient(to top, rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.3)); }
.header-content { position: relative; z-index: 2; max-width: 800px; }
.activity-badge { display: inline-block; padding: 0.25rem 0.75rem; background: var(--accent-color, #3b82f6); color: #fff; border-radius: 999px; font-size: 0.8rem; font-weight: 600; margin-bottom: 1rem; text-transform: uppercase; }
.sortie-header h1 { font-size: clamp(1.8rem, 5vw, 3rem); margin: 0 0 1rem; font-weight: 800; text-shadow: 2px 2px 4px rgba(0,0,0,0.5); }
.header-meta { display: flex; justify-content: center; flex-wrap: wrap; gap: 0.5rem 1.5rem; opacity: 0.9; font-size: 0.9rem; }
.header-meta span { display: flex; align-items: center; gap: 0.5rem; }

/* --- MISE EN PAGE RESPONSIVE --- */
.sortie-main-content { background: var(--gray-50, #f8fafc); color: var(--nav-text, #1a1a1a); padding: 2rem 1rem; }
.sortie-layout { display: flex; flex-direction: column; gap: 2rem; max-width: 1200px; margin: 0 auto; }
.sortie-primary-col { order: 2; }
.sortie-secondary-col { order: 1; }
@media (min-width: 992px) {
    .sortie-main-content { padding: 3rem 1.5rem; }
    .sortie-layout { display: grid; grid-template-columns: minmax(0, 2.5fr) minmax(0, 1fr); gap: 3rem; }
    .sortie-primary-col, .sortie-secondary-col { order: initial; }
}
.sticky-sidebar { position: -webkit-sticky; position: sticky; top: 100px; display: flex; flex-direction: column; gap: 2rem; }

/* ----- SECTIONS DE CONTENU ----- */
.sortie-section { margin-bottom: 2.5rem; }
.section-title { font-size: 1.5rem; font-weight: 700; color: var(--gray-900, #0F172A); margin: 0 0 1.5rem; padding-bottom: 0.75rem; border-bottom: 3px solid var(--accent-color, #3b82f6); }
@media (min-width: 768px) { .section-title { font-size: 1.75rem; } }
.section-content-text { line-height: 1.7; color: var(--gray-700, #334155); }
.map-container { height: 400px; border-radius: 0.5rem; border: 1px solid var(--nav-border, #e0e0e0); box-shadow: var(--shadow-md); }
@media (min-width: 768px) { .map-container { height: 500px; } }

/* ----- STATISTIQUES (SIDEBAR) ----- */
.sidebar-widget { background: var(--nav-bg-solid, #fff); border-radius: 0.75rem; padding: 1.5rem; box-shadow: var(--shadow-md); border: 1px solid var(--nav-border); }
.widget-title { font-size: 1.25rem; margin: 0 0 1rem; color: var(--gray-900); }
.stats-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 0.75rem; }
.stats-list li { display: flex; justify-content: space-between; align-items: center; padding-bottom: 0.75rem; border-bottom: 1px solid var(--nav-border); font-size: 0.9rem; }
.stats-list li:last-child { border-bottom: none; }
.stats-list span { color: var(--nav-text-muted); }
.stats-list strong { color: var(--nav-text); font-weight: 600; }
.profile-image-container img { width: 100%; border-radius: 0.5rem; cursor: zoom-in; }

/* ===== CARROUSEL (DESIGN MOBILE-FIRST) ===== */
.carousel-container { position: relative; margin: 0 -1rem; /* S'étend aux bords sur mobile */ }
.carousel-wrapper { overflow: hidden; }
/* Modification pour le carrousel */
.carousel-track {
    display: flex;
    transition: transform 0.4s cubic-bezier(0.65, 0, 0.35, 1);
    width: 100%; /* Assurez-vous que le track prend toute la largeur */
}

.carousel-slide {
    flex: 0 0 100%; /* Important: utiliser flex au lieu de min-width */
    width: 100%; /* Définir explicitement la largeur */
    box-sizing: border-box;
    padding: 0 1rem;
}

.carousel-slide img { width: 100%; display: block; cursor: zoom-in; border-radius: 0.5rem; box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1); }

.carousel-btn { position: absolute; top: 50%; transform: translateY(-50%); z-index: 10; background-color: var(--nav-bg-solid, #fff); color: var(--nav-text, #1a1a1a); border: 1px solid var(--nav-border, #e0e0e0); box-shadow: 0 2px 5px rgba(0,0,0,0.1); border-radius: 50%; width: 40px; height: 40px; cursor: pointer; font-size: 1.5rem; line-height: 40px; text-align: center; padding: 0; transition: all 0.2s ease; opacity: 1; }
.carousel-btn:hover { transform: translateY(-50%) scale(1.1); background-color: var(--accent-color, #3b82f6); color: #fff; border-color: var(--accent-color, #3b82f6); }
.carousel-btn.prev { left: 1.5rem; /* Ajusté pour le padding du slide */ }
.carousel-btn.next { right: 1.5rem; /* Ajusté pour le padding du slide */ }

.carousel-dots { text-align: center; padding-top: 1.5rem; }
.dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; background-color: #ccc; margin: 0 5px; cursor: pointer; transition: all 0.3s; border: none; padding: 0; }
.dot.active { background-color: var(--accent-color, #3b82f6); transform: scale(1.2); }

/* --- Design Desktop du Carrousel --- */
@media (min-width: 768px) {
    .carousel-container { margin: 0; border: 1px solid var(--nav-border, #e0e0e0); border-radius: 0.5rem; overflow: hidden; }
    .carousel-wrapper { overflow: visible; }
    .carousel-slide { padding: 0; }
    .carousel-slide img { border-radius: 0; box-shadow: none; }
    .carousel-btn { background-color: rgba(0, 0, 0, 0.5); color: white; border: none; }
    .carousel-btn:hover { background-color: rgba(0, 0, 0, 0.8); color: white; }
    .carousel-btn.prev { left: 1rem; }
    .carousel-btn.next { right: 1rem; }
    .carousel-dots { position: absolute; bottom: 1rem; left: 50%; transform: translateX(-50%); padding-top: 0; }
    .dot { background-color: rgba(255, 255, 255, 0.5); }
    .dot.active { background-color: white; }
}

/* ===== MODAL ===== */
.modal { display: none; align-items: center; justify-content: center; position: fixed; z-index: 2000; left: 0; top: 0; width: 100%; height: 100%; background-color: rgba(15, 23, 42, 0.9); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); opacity: 0; transition: opacity 0.3s ease; }
.modal.visible { opacity: 1; }
.modal-content { display: block; max-width: 95vw; max-height: 90vh; transform: scale(0.95); transition: transform 0.3s ease; }
.modal.visible .modal-content { transform: scale(1); }
.modal-close { position: absolute; top: 10px; right: 15px; color: #fff; font-size: 2rem; font-weight: 300; cursor: pointer; line-height: 1; padding: 0.5rem; opacity: 0.8; transition: opacity 0.2s, transform 0.2s; }
.modal-close:hover { opacity: 1; transform: rotate(90deg); }

.leaflet-control-info-box {
    background-color: rgba(255, 255, 255, 0.8);
    border-radius: 5px;
    padding: 10px;
    border: 1px solid #ccc;
    box-shadow: 0 1px 5px rgba(0,0,0,0.4);
    font-family: Arial, sans-serif;
    color: #333;
    width: 180px; /* Un peu plus de largeur pour tout afficher */
}

.info-box-line {
    margin: 0;
    padding: 2px 0;
    font-size: 14px;
}

.info-box-line strong {
    display: inline-block;
    width: 70px; /* Pour aligner les valeurs */
}

/* ... ton CSS existant ... */

.info-box-line strong {
    display: inline-block;
    width: 70px; /* Pour aligner les valeurs */
}

/* ===== AJOUTER ICI LE CSS MÉTÉO ===== */
/* Widget météo */
.weather-widget {
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
    border: 1px solid var(--nav-border, #e0e0e0);
    position: relative;
    overflow: hidden;
}

.weather-widget::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #3b82f6, #06b6d4, #10b981);
}

.weather-content {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.weather-main {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--nav-border, #e0e0e0);
}

.weather-icon img {
    width: 60px;
    height: 60px;
    object-fit: contain;
}

.weather-temp {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.temp-main {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--gray-900, #0F172A);
}

.temp-range {
    font-size: 0.9rem;
    color: var(--nav-text-muted, #666);
    font-weight: 500;
}

.weather-condition {
    font-size: 0.85rem;
    color: var(--nav-text, #1a1a1a);
    font-weight: 500;
    text-transform: capitalize;
}

.weather-details {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
}

.weather-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.85rem;
}

.weather-icon-small {
    font-size: 1rem;
    width: 20px;
    text-align: center;
}

.weather-label {
    color: var(--nav-text-muted, #666);
    flex: 1;
}

.weather-value {
    color: var(--nav-text, #1a1a1a);
    font-weight: 600;
}

@media (max-width: 767px) {
    .weather-main {
        justify-content: center;
        text-align: center;
    }
    
    .weather-icon img {
        width: 50px;
        height: 50px;
    }
    
    .temp-main {
        font-size: 1.3rem;
    }
    
    .weather-details {
        grid-template-columns: 1fr;
        gap: 0.5rem;
    }
    
    .weather-item {
        justify-content: space-between;
        padding: 0.5rem 0;
        border-bottom: 1px solid #f1f5f9;
    }
    
    .weather-item:last-child {
        border-bottom: none;
    }
}

/* Style pour le bouton plein écran */
.leaflet-control-fullscreen-button {
    background-color: white;
    color: #333;
    border: 2px solid rgba(0,0,0,0.2);
    border-radius: 4px;
    background-clip: padding-box;
    text-decoration: none;
}

.leaflet-control-fullscreen-button:hover {
    background-color: #f4f4f4;
}

/* Style pour que le conteneur de la carte prenne toute la place en mode plein écran */
/* Le sélecteur :-webkit-full-screen est important pour la compatibilité avec Chrome/Safari */
#map:-webkit-full-screen {
    width: 100% !important;
    height: 100% !important;
}
#map:-ms-fullscreen {
    width: 100% !important;
    height: 100% !important;
}
#map:fullscreen {
    width: 100% !important;
    height: 100% !important;
}

/* --- AMÉLIORATIONS POUR LA LIGHTBOX (MODALE) --- */

/* La modale doit avoir une position relative pour contenir les boutons */
.modal {
    position: fixed;
    /* ... autres styles existants ... */
}

/* Style pour les boutons de navigation de la modale */
.modal-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(0, 0, 0, 0.4);
    color: white;
    border: none;
    font-size: 2rem;
    padding: 10px 15px;
    cursor: pointer;
    z-index: 1001; /* Doit être au-dessus de l'image modale */
    transition: background-color 0.2s;
    border-radius: 5px;
    user-select: none; /* Empêche la sélection du texte des flèches */
}

.modal-nav:hover {
    background-color: rgba(0, 0, 0, 0.7);
}

.modal-nav.prev {
    left: 20px;
}

.modal-nav.next {
    right: 20px;
}

/* Adaptation pour les petits écrans */
@media (max-width: 768px) {
    .modal-nav {
        font-size: 1.5rem;
        padding: 8px 12px;
        left: 10px;
    }
    .modal-nav.next {
        right: 10px;
    }
}
