/* =========================================
   1. VARIABLES & RESET
   ========================================= */
:root {
    --primary: #1A2E44;      /* Bleu Abysse */
    --accent: #E29791;       /* Granite Rose */
    --bg-light: #F8F9FA;     /* Blanc cassé */
    --text: #2c3e50;         /* Gris foncé */
    --white: #ffffff;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
    font-family: 'Montserrat', sans-serif;
    color: var(--text);
    line-height: 1.6;
    background-color: var(--white);
    scroll-behavior: smooth;
}

h1, h2, h3 {
    font-family: 'Playfair Display', serif;
    color: var(--primary);
    font-weight: 700;
}

a { text-decoration: none; color: inherit; }

.container { width: 90%; max-width: 1200px; margin: 0 auto; }
.section-padding { padding: 5rem 0; }
.bg-light { background-color: var(--bg-light); }
.section-header { text-align: center; margin-bottom: 3rem; max-width: 700px; margin-left: auto; margin-right: auto; }
.section-header p { color: #666; margin-top: 0.5rem; }

/* BOUTONS GÉNÉRAUX */
.btn-reserver {
    display: inline-block;
    background: var(--accent);
    color: var(--white) !important;
    padding: 0.7rem 1.5rem;
    border-radius: 4px;
    font-weight: 600;
    transition: 0.3s;
    border: none;
    cursor: pointer;
}
.btn-reserver:hover { background: #d6857f; transform: translateY(-2px); }

.full-width { width: 100%; text-align: center; font-size: 1rem; padding: 15px; margin-top: 10px; }


/* =========================================
   2. HEADER & NAVIGATION
   ========================================= */
header {
    position: fixed; top: 0; width: 100%; z-index: 1000;
    /* On sépare les transitions : 0.5s très doux pour le fond et l'ombre, 0.2s rapide pour le texte */
    transition: background-color 0.3s ease-in-out, box-shadow 0.3s ease-in-out, color 0.3s ease, transform 0.3s ease;
    background-color: transparent; /* <-- IMPORTANT : background-color au lieu de background */
    color: var(--white);
    height: 90px; 
    display: flex; 
    align-items: center; 
}

header.header-white {
    background-color: rgba(255, 255, 255, 0.98); /* <-- IMPORTANT : background-color */
    box-shadow: 0 2px 15px rgba(0,0,0,0.05);
    color: var(--primary);
}

header.header-white .nav-links a,
header.header-white .dropdown span { color: var(--primary); }
header.header-white .btn-reserver { color: var(--white) !important; }

.nav-flex {
    display: flex; 
    justify-content: space-between;
    align-items: center;
    width: 100%; 
    height: 100%;
}

.logo a {
    font-size: 1.4rem; font-weight: 700; letter-spacing: 2px;
    text-decoration: none; color: inherit; text-transform: uppercase;
}

/* LA BARRE DE NAVIGATION */
.nav-links {
    display: flex; 
    align-items: center; /* C'EST ICI QUE TOUT S'ALIGNE */
    gap: 30px; 
    height: 100%;
}

.btn-connexion{

    position : relative;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
}

/* Liens simples et le lien "Connexion" */
.nav-links > a:not(.btn-reserver) {
    text-decoration: none; color: inherit; font-weight: 500; font-size: 0.95rem;
    display: flex; align-items: center; /* Centre le texte dans son lien */
    height: 100%;
}
.nav-links > a:not(.btn-reserver):hover { color: var(--accent); }

/* --- MENU DÉROULANT (MON COMPTE) --- */
.dropdown {
    position: relative;
    display: flex; 
    align-items: center; /* Centre le texte "Mon Compte" verticalement */
    height: 100%; 
    cursor: pointer;
    padding: 0 5px;
}

/* Le texte "Mon Compte" */
.dropdown span {
    font-weight: 600; 
    font-size: 0.95rem;
    display: flex; 
    align-items: center;
    height: 100%;
}

.dropdown-content {
    display: none;
    position: absolute;
    top: 70px; /* Ajusté pour tomber sous le header de 90px */
    right: -10px;
    padding-top: 20px; /* Pont invisible */
    z-index: 1000;
}

.dropdown-inner {
    background-color: white;
    min-width: 200px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
    border-radius: 8px;
    padding: 10px 0;
    text-align: left;
}

.dropdown:hover .dropdown-content { display: block; }

.dropdown-inner a {
    display: block; padding: 12px 20px; color: #333 !important;
    font-size: 0.9rem; text-decoration: none;
    align-items: flex-start; height: auto; /* Reset des styles des liens du header */
}
.dropdown-inner a:hover { background: #f8f9fa; color: var(--primary) !important; }

/* BOUTON RÉSERVER PRINCIPAL (Style "Pavé arrondi") */
.btn-reserver {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    height: 45px;
    padding: 0 25px;
    
    border-radius: 8px; /* C'EST ICI : Moins rond (avant c'était 50px) */
    
    background: var(--accent);
    color: white !important;
    font-weight: 700;
    margin-left: 10px;
    text-decoration: none !important;
    transition: 0.3s;
}
.btn-reserver:hover { background: #d6857f; transform: translateY(-2px); }


.logout-link {
    border-top: 1px solid #f1f5f9;
    margin-top: 5px !important;
    padding-top: 10px !important;
    color: #ef4444 !important; /* Rouge standard */
    font-weight: 500;
}

.logout-link:hover {
    background-color: #ffe0e0 !important; /* Fond rouge très clair (Apple/Airbnb style) */
    color: #b91c1c !important; /* Texte rouge sang */
}

/* =========================================
   3. HERO SECTION
   ========================================= */
.hero {
    background-image: linear-gradient(rgba(0, 0, 0, 0.4), rgba(0, 0, 0, 0.4)), 
                      url('https://images.unsplash.com/photo-1770881686543-b2a411c71c05?auto=format&fit=crop&q=80&w=2000');
    background-size: cover; background-position: center;
    min-height: 100vh;
    display: flex; align-items: center; justify-content: center;
    text-align: center; color: white;
}
.hero-content h1 {
    color: var(--white); font-size: clamp(2.5rem, 5vw, 4.5rem); line-height: 1.1; margin-bottom: 1.5rem;
}
.hero-content p { font-size: 1.2rem; margin-bottom: 2.5rem; font-weight: 300; }


/* =========================================
   4. CAPITAINE & SÉCURITÉ
   ========================================= */
.section-capitaine { padding: 100px 0; background-color: #fff; }
.flex-capitaine { display: flex; gap: 80px; align-items: stretch; }

.photo-capitaine-wrapper { flex: 1; max-width: 450px; }
.photo-capitaine-wrapper img {
    width: 100%; height: 100%; object-fit: cover; border-radius: 8px; object-position: center 20%;
    box-shadow: 20px 20px 0 var(--bg-light);
}

.texte-capitaine { flex: 1.2; display: flex; flex-direction: column; justify-content: center; }
.display-title { font-size: 2.5rem; margin-bottom: 1.5rem; }

/* Sécurité Cards */
.safety-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 2rem; }
.safety-card { position: relative; height: 450px; border-radius: 24px; overflow: hidden; }
.safety-card img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.5s ease; }
.safety-card:hover img { transform: scale(1.05); }

.safety-bubble {
    position: absolute; bottom: 20px; left: 20px; right: 20px;
    background: rgba(255, 255, 255, 0.9); backdrop-filter: blur(10px);
    padding: 1.5rem; border-radius: 16px; text-align: center;
}
.safety-bubble .icon { font-size: 2rem; margin-bottom: 0.5rem; }


/* =========================================
   5. OFFRES (GRILLE & PRIX)
   ========================================= */

/* --- LE CONTENEUR PRINCIPAL (C'est lui qui centre tout) --- */
.container {
    width: 90%;
    max-width: 1200px; /* Largeur max du site */
    margin: 0 auto;    /* LA COMMANDE MAGIQUE POUR CENTRER */
    position: relative;
}

.offers-grid { 
    display: grid; 
    grid-template-columns: 1fr 1fr; /* 2 colonnes égales */
    gap: 30px; /* Espace entre les cartes */
    width: 100%;
}

.offer-card {
    position: relative; 
    height: 500px; 
    background-size: cover; 
    background-position: center;
    border-radius: 20px; 
    overflow: hidden; 
    cursor: pointer;
    
    /* Animation de la carte elle-même */
    transition: transform 0.4s ease, box-shadow 0.4s ease;
}

/* Au survol : La carte monte et l'ombre grandit */
.offer-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.3);
}

.offer-overlay {
    position: absolute; bottom: 0; left: 0; width: 100%; height: 100%;
    background: linear-gradient(to top, rgba(0,0,0,0.9) 0%, rgba(0,0,0,0.3) 50%, transparent 100%);
    display: flex; flex-direction: column; justify-content: flex-end;
    padding: 2.5rem;
    
    /* Animation du texte */
    transition: padding-bottom 0.4s ease, background 0.4s ease;
}

/* Au survol : Le texte remonte et le fond s'assombrit pour la lisibilité */
.offer-card:hover .offer-overlay {
    padding-bottom: 4rem; /* C'est ça qui fait remonter le texte ! */
    background: linear-gradient(to top, rgba(0,0,0,1) 0%, rgba(0,0,0,0.5) 60%, transparent 100%);
}

.offer-details { width: 100%; }
.offer-details h3 { color: white; font-size: 2rem; margin-bottom: 0.5rem; text-shadow: 0 2px 4px rgba(0,0,0,0.5); }
.offer-details p { color: rgba(255,255,255,0.9); margin-bottom: 20px; font-size: 0.95rem; }

/* Ligne Prix à gauche / Bouton à droite */
.offer-action-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    border-top: 1px solid rgba(255,255,255,0.2);
    padding-top: 15px;
}

.simple-price { font-size: 0.95rem; color: white; font-family: 'Montserrat', sans-serif; }
.simple-price span { display: block; color: var(--accent); font-weight: 700; font-size: 1.3rem; }

.btn-reserver-small {
    background: white; color: var(--primary);
    padding: 10px 20px; 
    
    border-radius: 6px; /* C'EST ICI : Moins rond (avant 50px) */
    
    font-weight: 700; text-decoration: none; font-size: 0.9rem;
    white-space: nowrap; transition: 0.3s;
}
.btn-reserver-small:hover { background: var(--accent); color: white; }

/* RESPONSIVE : On repasse en 1 colonne sur mobile */
@media (max-width: 768px) {
    .offers-grid { grid-template-columns: 1fr; }
}

/* =========================================
   6. FAQ
   ========================================= */
.faq-container { max-width: 800px; margin: 0 auto; }
.accordion details {
    background: var(--white); margin-bottom: 1rem; padding: 1.5rem;
    border-radius: 12px; border: 1px solid #eee; transition: 0.3s;
}
.accordion summary {
    font-weight: 600; font-size: 1.1rem; list-style: none; color: var(--primary);
    position: relative; padding-right: 2rem; cursor: pointer;
}
.accordion summary::-webkit-details-marker { display: none; }
.accordion summary::after {
    content: '↓'; position: absolute; right: 0; top: 50%; transform: translateY(-50%);
    color: var(--accent); transition: transform 0.3s;
}
.accordion details[open] summary::after { transform: translateY(-50%) rotate(180deg); }


/* =========================================
   7. FORMULAIRE CONTACT
   ========================================= */
.reservation-footer-section { background-color: #f8fafc; padding: 80px 0; }
.contact-wrapper {
    max-width: 700px; margin: 0 auto; background: white; padding: 40px;
    border-radius: 20px; box-shadow: 0 10px 40px rgba(0,0,0,0.05);
}
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.form-group label { display: block; margin-bottom: 8px; font-weight: 600; font-size: 0.9rem; color: var(--primary); }
.form-group input, .form-group textarea {
    width: 100%; padding: 12px 15px; border: 1px solid #e2e8f0; border-radius: 8px;
    font-family: 'Montserrat', sans-serif; font-size: 0.95rem; background: #fdfdfd;
}
.form-group input:focus, .form-group textarea:focus { border-color: var(--accent); outline: none; background: white; }


/* =========================================
   8. FOOTER
   ========================================= */
footer { background: var(--white); border-top: 1px solid #eee; padding: 3rem 0; margin-top: auto; font-size: 0.9rem; }
.footer-content { display: flex; justify-content: space-between; align-items: flex-end; }
.footer-links a { color: var(--text); margin-right: 1.5rem; }
.footer-links a:hover { color: var(--accent); }
.footer-legal p { color: #999; margin-top: 0.5rem; }


/* =========================================
   9. RESPONSIVE MOBILE
   ========================================= */
@media (max-width: 768px) {
    .hero-content h1 { font-size: 2.5rem; }
    .flex-capitaine { flex-direction: column; gap: 40px; }
    .photo-capitaine-wrapper { max-width: 100%; order: -1; }
    .offers-grid { grid-template-columns: 1fr; }
    .offer-card { height: 400px; }
    .form-grid { grid-template-columns: 1fr; }
    .footer-content { flex-direction: column; align-items: flex-start; gap: 2rem; }
    .nav-links { display: none; } /* Burger menu logique à ajouter si besoin */
    .contact-wrapper { padding: 20px; }
}


/* =========================================
   10. PAGES SPÉCIFIQUES (RESERVATION & COMPTE)
   Ne pas supprimer pour éviter de casser les autres pages
   ========================================= */

/* --- Page Réservation --- */

/* --- Page Réservation --- */
.reservation-page .header .nav-links a, 
.reservation-page .header .logo a { color: #1a1a1a !important; }
.reservation-page .header { border-bottom: 1px solid rgba(0,0,0,0.05); background-color: white; }

/* Styles de base FullCalendar (SANS bloquer les couleurs de fond) */
.fc-event-title { white-space: normal !important; overflow: visible !important; font-size: 0.85rem; }
.fc-daygrid-event { white-space: normal !important; height: auto !important; padding: 2px !important; }
/* ATTENTION : On enlève le !important sur le background et border s'il y en avait */
.fc-event { padding: 3px 8px !important; margin-bottom: 2px !important; border-radius: 4px !important; font-weight: 600 !important; }

/* Gérer le curseur selon l'état du créneau */
.fc-event.slot-past, .fc-event.slot-booked {
    cursor: not-allowed !important;
    opacity: 0.85; 
}
.fc-event.slot-available {
    cursor: pointer !important;
}

/* Wizard Styles */
.step-section { display: none; animation: fadeIn 0.3s; }
.step-section.active { display: block; }
.recap-box { background: #f8fafc; border: 1px solid #e2e8f0; border-radius: 8px; padding: 15px; margin-bottom: 20px; }
.recap-line { display: flex; justify-content: space-between; margin-bottom: 8px; }
.total-price { font-size: 1.4rem; color: #0ea5e9; font-weight: bold; text-align: right; border-top: 1px solid #cbd5e1; margin-top: 10px; padding-top: 10px; }
#wizard-subtitle { white-space: normal !important; overflow: visible !important; text-overflow: clip !important; line-height: 1.4; font-weight: bold; color: #334155; }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

/* --- Page Mon Compte --- */
.profile-card { background: white; padding: 3rem; border-radius: 15px; box-shadow: 0 4px 20px rgba(0,0,0,0.05); }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 2rem; margin-bottom: 1.5rem; }
.reservation-item { background: white; border-radius: 10px; padding: 1.5rem; display: flex; justify-content: space-between; align-items: center; margin-bottom: 1rem; border-left: 5px solid var(--primary); box-shadow: 0 2px 10px rgba(0,0,0,0.03); }
.res-status { font-size: 0.8rem; padding: 0.3rem 0.8rem; border-radius: 20px; font-weight: 600; }
.status-attente { background: #fff3cd; color: #856404; }
.status-valide { background: #d4edda; color: #155724; }
.status-termine { background: #e2e3e5; color: #383d41; }
.btn-facture { margin-left: 20px; font-size: 0.9rem; color: #007bff; border: 1px solid #007bff; padding: 5px 10px; border-radius: 5px; }
.btn-facture:hover { background: #007bff; color: white; }

/* =========================================
   11. SECTION AVIS (INDEX)
   ========================================= */
.reviews-preview-section {
    background-color: var(--white);
    padding: 60px 0;
    border-top: 1px solid #f1f5f9;
}

.reviews-header {
    text-align: center;
    margin-bottom: 2rem;
}

.reviews-header h2 {
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.reviews-carousel-index {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    gap: 20px;
    padding: 10px 20px 30px 20px; /* Padding latéral pour que les cartes ne soient pas collées au bord sur mobile */
    scrollbar-width: none; 
    -ms-overflow-style: none;
    max-width: 1200px;
    margin: 0 auto;
}
.reviews-carousel-index::-webkit-scrollbar { display: none; }

.review-card-index {
    min-width: 300px;
    max-width: 350px;
    scroll-snap-align: center;
    background: #f8fafc;
    border-radius: 16px;
    padding: 20px;
    border: 1px solid #e2e8f0;
    display: flex;
    flex-direction: column;
}

.review-header-index { display: flex; gap: 12px; align-items: center; margin-bottom: 10px; }
.review-avatar-index { width: 45px; height: 45px; border-radius: 50%; background: var(--primary); color: white; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 1.1rem; flex-shrink: 0; }
.review-author-index { font-weight: 700; color: var(--primary); font-size: 1rem; }
.review-stars-index { color: #f59e0b; font-size: 1rem; margin-bottom: 8px; letter-spacing: 2px; }
.review-title-index { font-family: 'Playfair Display', serif; font-size: 1.1rem; color: var(--primary); margin-bottom: 8px; font-weight: 700; }
.review-text-index { font-size: 0.9rem; color: #475569; line-height: 1.5; display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }

.reviews-action {
    text-align: center;
    margin-top: 20px;
}