/* =========================================
   STYLE.CSS — FEUILLE DE STYLE GLOBALE
   Sections : Variables, Base, Boutons,
   Hero, Références, Modales, Projets,
   Galerie, Footer, Navbar, Contact, Portfolio,
   Mentions légales, Cookies, SEO local,
   FAQ, Figure/Figcaption
   ========================================= */

/* =========================================
   1. VARIABLES & BASE
   ========================================= */

:root {
    /* --- PALETTE DE COULEURS --- */
    --primary-red: #881D19;
    --primary-red-hover: #b71c1c;
    --bg-dark: #1e1d1b;
    --bg-card: #2c2c2c;
    --text-white: #ffffff;
    --text-gray: #e0e0e0;

    /* --- TYPOGRAPHIE --- */
    --font-main: 'Josefin Sans', sans-serif;     /* Titres et UI */
    --font-sub: 'Lato', sans-serif;  /* Sous-titres élégants */
    --font-body: 'Segoe UI', sans-serif;   /* Texte courant */
    --font-accent: 'Anton', sans-serif;    /* Gros titres artistiques */
}

html {
    font-size: 100%; /* Base 16px */
    scroll-behavior: smooth;
}

body {
    margin: 0;
    padding: 0;
    font-family: var(--font-body);
    background-color: var(--bg-dark);
    color: var(--text-white);
    line-height: 1.6; /* Meilleure lisibilité */
    overflow-x: hidden;
}

/* =========================================
   2. COMPOSANTS GLOBAUX : BOUTONS & TITRES
   ========================================= */

h1 {
    font-family: var(--font-main);
    margin-top: 0;
}

h2 {
    font-family: var(--font-sub);
    font-weight: 100;
    font-style: italic;
    margin-top: 0;
}

h3 {
    font-family: var(--font-main);
    margin-top: 0;
}

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

/* Boutons standardisés */
.btn-primary {
    background: var(--primary-red);
    font-family: var(--font-sub);
    color: white;
    padding: 0.8rem 1.5rem;
    border-radius: 5px;
    font-weight: 700;
    font-size: 1rem;
    transition: transform 0.2s ease, background-color 0.3s ease;
    display: inline-block;
    cursor: pointer;
    border: none;
    position: relative;
    overflow: hidden;
    animation: pulse 2.5s ease-in-out infinite;
}

/* Le reflet lumineux */
.btn-primary::after {
    content: '';
    position: absolute;
    top: 0;
    left: -75%;
    width: 50%;
    height: 100%;
    background: linear-gradient(
        120deg,
        rgba(255, 255, 255, 0) 0%,
        rgba(255, 255, 255, 0.3) 50%,
        rgba(255, 255, 255, 0) 100%
    );
    animation: shimmer 2.5s ease-in-out infinite;
    animation-delay: 0.5s;
}

@keyframes shimmer {
    0%   { left: -75%; }
    50%  { left: 125%; }
    100% { left: 125%; }
}
@keyframes pulse {
    0%   { transform: scale(1); box-shadow: 0 0 0 0 rgba(136, 29, 25, 0.5); }
    50%  { transform: scale(1.04); box-shadow: 0 0 12px 6px rgba(136, 29, 25, 0); }
    100% { transform: scale(1); box-shadow: 0 0 0 0 rgba(136, 29, 25, 0); }
}


.btn-primary:hover {
    background-color: var(--primary-red-hover);
    transform: scale(1.05);
    text-decoration: none;
  
}

/* Bouton contour blanc (secondaire) */
.btn-outline {
    background: transparent;
    font-family: var(--font-sub);
    color: white;
    padding: 0.8rem 1.5rem;
    border-radius: 5px;
    font-weight: 700;
    font-size: 1rem;
    border: 2px solid white;
    transition: transform 0.2s ease, background-color 0.3s ease, color 0.3s ease;
    display: inline-block;
    cursor: pointer;
}

.btn-outline:hover {
    background-color: rgba(255, 255, 255, 0.15);
    transform: scale(1.05);
    text-decoration: none;
}

/* Titres de section (style badge) */
.section-title {
    font-size: 1.5rem; /* Réduit de 3.1rem */
    font-weight: 900;
    text-transform: uppercase;
    color: white;
    background-color: var(--primary-red);
    padding: 0.5rem 1.5rem;
    border-radius: 8px;
    display: inline-block;
    margin-bottom: 1rem;
    text-align: center;
    /* Animation */
    opacity: 0; 
    transform: translateX(-30px);
    animation: slideIn 1s ease forwards;
    white-space: nowrap;
}

/* =========================================
   3. HERO SECTION (ACCUEIL)
   ========================================= */
.hero {
    position: relative;
    height: 100vh;
    height: 100svh; /* Fix iOS Safari : évite le débordement causé par la barre d'adresse */
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    text-align: left;
    overflow: hidden;
    padding-left: 6%;
}

.hero video {
    position: absolute;
    top: 50%;
    left: 50%;
    min-width: 100%;
    min-height: 100%;
    transform: translate(-50%, -50%);
    filter: brightness(0.4);
    z-index: 1;
    object-fit: cover;
}

.hero .content {
    position: relative;
    z-index: 2;
    animation: fadeIn 2s ease forwards;
    padding: 0 20px;
}

.hero h1 {
    font-size: 5.5rem;
    margin-bottom: 0;
    font-weight: 900;
    letter-spacing: -0.02em;
    color: #f0f0f0;
    text-transform: uppercase;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.5);
    line-height: 1;
}

.hero h2 {
    font-size: 1.5rem;
    font-weight: 300;
    color: #f0f0f0;
    margin-top: 0;
    margin-bottom: 2rem;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.5);
}

.hero-brand {
    font-size: 1.6rem;
    font-weight: 400;
    font-style: italic;
    color: #f0f0f0;
    letter-spacing: 0.12em;
    margin: 0 0 0.4rem 0;
    line-height: 1.2;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.5);
}

.hero-author {
    position: absolute;
    bottom: 2.5rem;
    right: 9%;
    color: rgba(240, 240, 240, 0.65);
    font-family: var(--font-main);
    font-size: 1rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    z-index: 2;
}

.hero .cta {
    display: flex;
    justify-content: flex-start;
    gap: 1rem;
}

/* =========================================
   4. SECTION RÉFÉRENCES / LOGOS CLIENTS
   ========================================= */
.references {
    padding: 5rem 5%; /* Marge gauche/droite réduite à 5% */
    background: linear-gradient(135deg, #2a2a28, #1e1d1b);
    border-radius: 30px 30px 0 0;
    box-shadow: 0 -10px 30px rgba(0, 0, 0, 0.4);
    position: relative;
    z-index: 10;
}

.references .content {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 4rem;
    max-width: 1400px;
    margin: 0 auto;
}


.references .intro {
    flex: 1 1 500px;
}

.references .intro p {
    font-size: 1.1rem; /* Réduit de 1.7rem -> Beaucoup plus standard */
    color: var(--text-gray);
    text-align: justify;
    margin-bottom: 1rem;
    opacity: 0;
    transform: translateY(20px);
    animation: fadeText 1s ease-in-out forwards 0.5s;
}

.references .logos-block {
    flex: 1 1 300px;
    display: flex;
    align-items: center;
}

.references .logos {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    width: 100%;
}

.references .logos img {
    width: 100%;
    max-width: 180px; /* Limite la taille des logos */
    height: auto;
    filter: grayscale(100%) brightness(0.7);
    transition: filter 0.3s ease, transform 0.3s ease;
    margin: 0 auto;
    display: block;
}

.references .logos img:hover {
    filter: none;
    transform: scale(1.1);
}

/* =========================================
   5. MODALES & LIGHTBOX
   ========================================= */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.85);
    justify-content: center;
    align-items: center;
    z-index: 2001;
    opacity: 0;
    transition: opacity 0.3s ease;
    padding: 20px; /* Marge de sécurité mobile */
    box-sizing: border-box;
}

.modal.show { display: flex; opacity: 1; }

.modal-content {
    position: relative;
    background-color: var(--bg-card);
    transform: scale(0.9);
    animation: popIn 0.4s ease forwards;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    border-radius: 15px;
    box-shadow: 0 5px 25px rgba(0,0,0,0.5);
    padding: 40px;
}

.modal-close {
    position: absolute;
    /* Position fixe par rapport à l'écran */
    top: 30px;  
    right: 30px;
    
    background: var(--primary-red);
    color: white;
    border: none;
    border-radius: 50%;
    width: 40px;  /* Légèrement plus grand pour être facile à viser */
    height: 40px;
    font-size: 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    
    /* Z-index très haut pour passer au-dessus de tout (même des flèches) */
    z-index: 2100; 
    transition: transform 0.3s ease, background-color 0.3s ease;
    box-shadow: 0 2px 10px rgba(0,0,0,0.5); /* Petite ombre pour bien ressortir */
}

.modal-close:hover {
    background-color: white;
    color: var(--primary-red);
    transform: rotate(90deg); /* Petite animation sympa au survol */
}

/* Ajustement Mobile pour la croix */
@media (max-width: 768px) {
    .modal-close {
        top: 15px;
        right: 15px;
        width: 35px;
        height: 35px;
        font-size: 1.2rem;
    }
}

/* Spécifique Video */
#videoModal .modal-content {
    width: 100%;
    max-width: 900px;
    aspect-ratio: 16/9;
    padding: 0;
    background: black;
}
.modal-content video { width: 100%; height: 100%; }

/* Spécifique Contact */
#contactModal .modal-content {
    width: 100%;
    max-width: 500px;
}

#contactModal h3 {
    font-size: 1.8rem; /* Réduit de 2.8rem !important */
    color: white;
    text-transform: uppercase;
    background-color: var(--primary-red);
    padding: 0.5rem 1.5rem;
    border-radius: 8px;
    margin-bottom: 1rem;
    text-align: center;
}

#contactModal .contact-subtitle {
    font-size: 1rem; /* Réduit de 1.7rem */
    color: var(--text-gray);
    text-align: center;
    margin-bottom: 2rem;
}

.contact-link {
    font-family: var(--font-sub);
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    color: #fff;
    background-color: rgba(255, 255, 255, 0.05);
    padding: 15px 20px;
    margin: 10px auto;
    border-radius: 8px;
    transition: all 0.3s ease;
    font-size: 1.1rem; /* Réduit de 1.4rem */
    border: 1px solid rgba(255,255,255,0.1);
    width: 100%;
    max-width: 300px;
    box-sizing: border-box;
}

.contact-link .icon { margin-right: 10px; font-size: 1.2rem; }
.contact-link:hover {
    background-color: var(--primary-red);
    transform: translateY(-3px);
}

/* =========================================
   6. SECTION PROJETS (ACCUEIL)
   ========================================= */
.derniers-projets {
    scroll-margin-top: 80px;
    padding: 5rem 10%;
    background-color: var(--bg-dark);
    text-align: center;
}

.projets-grid-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); /* Responsive automatique */
    gap: 1.5rem;
    padding: 2rem 0;
    max-width: 1200px;
    margin: 0 auto;
}

.projet-item {
    position: relative;
    background: var(--bg-card);
    border-radius: 10px;
    overflow: hidden;
    aspect-ratio: 16 / 9;
    cursor: pointer;
    transition: transform 0.3s ease;
}
.projet-item:hover { transform: scale(1.02); }

.projet-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease, filter 0.3s ease;
}
.projet-item:hover img {
    transform: scale(1.1);
    filter: brightness(0.5);
}
.projet-text-overlay {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center; /* Centre verticalement le bloc global */
    align-items: center;     /* Centre horizontalement */
    opacity: 0;
    transition: opacity 0.3s ease;
    padding: 1rem;           /* Sécurité pour ne pas toucher les bords */
    box-sizing: border-box;
}
.projet-item:hover .projet-text-overlay { opacity: 1; }

.projet-text-overlay h3 {
    font-size: 1.4rem;
    text-shadow: 0 2px 4px rgba(0,0,0,0.8);
    font-weight: 600;
    
    /* --- CORRECTIONS --- */
    margin: 0;               /* Supprime les marges par défaut énormes */
    margin-bottom: 0.3rem;   /* Définit un petit espace contrôlé avec la catégorie */
    line-height: 1.2;        /* Resserre les lignes si le titre est long */
}

.projet-text-overlay .category {
    font-family: var(--font-sub);
    font-weight: 300;
    font-size: 1rem;
    font-style: italic;
    color: var(--text-gray);
    
    /* --- CORRECTIONS --- */
    margin: 0;               /* Supprime la marge par défaut pour un centrage parfait */
}

.cta-projets { margin-top: 3rem; }

/* =========================================
   7. ANIMATIONS (@keyframes)
   ========================================= */
@keyframes fadeIn { from { opacity: 0; transform: translateY(20px); } to { opacity: 1; transform: translateY(0); } }
@keyframes slideIn { from { opacity: 0; transform: translateX(-30px); } to { opacity: 1; transform: translateX(0); } }
@keyframes fadeText { from { opacity: 0; transform: translateY(30px); } to { opacity: 1; transform: translateY(0); } }
@keyframes popIn { 0% { transform: scale(0.9); opacity: 0; } 100% { transform: scale(1); opacity: 1; } }
@keyframes popOut { 0% { transform: scale(1); opacity: 1; } 100% { transform: scale(0.9); opacity: 0; } }

/* =========================================
   8. RESPONSIVE GLOBAL
   ========================================= */
@media (max-width: 992px) {
    .references .content { flex-direction: column; align-items: center; text-align: center; }
    
    /* MODIFICATION ICI : */
    .references .intro p { 
        text-align: justify;       /* Texte aligné proprement à gauche et à droite */
        text-align-last: left;   /* La dernière ligne du paragraphe est centrée (optionnel, très joli pour les bios) */
        padding: 0 10px;           /* Ajoute un peu d'espace pour que le texte ne colle pas aux bords de l'écran */
    }

    .hero h1 { font-size: 4rem; }
}

@media (max-width: 768px) {
    .hero h1 { font-size: 3rem; }
    .hero h2 { font-size: 1.2rem; }
    .hero {
        justify-content: center;
        text-align: center;
        padding-left: 0;
    }
    .hero .cta { justify-content: center; }
    .hero-author { right: 50%; bottom: 8rem; transform: translateX(50%); }
    .section-title { font-size: 1.2rem; padding: 0.4rem 1.2rem; white-space: normal; }
    
    .references, .derniers-projets { padding: 4rem 5%; }
    
    .projets-grid-container { grid-template-columns: 1fr; }
    
    #contactModal .modal-content { padding: 25px; }
    #contactModal h3 { font-size: 1.5rem; }
    .contact-link { font-size: 1rem; }
}

/* =========================================
   9. NAVIGATION GALERIE (FLÈCHES)
   ========================================= */

.nav-arrow {
    position: absolute; /* Absolu par rapport à l'écran noir (.modal) */
    top: 50%;
    transform: translateY(-50%);
    
    /* Design du bouton */
    background-color: rgba(0, 0, 0, 0.5);
    color: white;
    width: 60px; /* Un peu plus grand pour cliquer facilement */
    height: 60px;
    display: none; /* Géré par le JS */
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.8rem;
    user-select: none;
    transition: all 0.3s ease;
    
    /* Assure que la flèche est toujours AU-DESSUS de l'image (z-index) */
    z-index: 2050; 
}

.nav-arrow:hover {
    background-color: var(--primary-red);
    transform: translateY(-50%) scale(1.1);
}

/* Positionnement Écran (Ne bougera plus jamais !) */
.nav-arrow.prev { 
    left: 30px; /* Marge gauche fixe */
}

.nav-arrow.next { 
    right: 30px; /* Marge droite fixe */
}

/* Ajustement Mobile */
@media (max-width: 768px) {
    .nav-arrow {
        width: 45px;
        height: 45px;
        font-size: 1.2rem;
        background-color: rgba(0, 0, 0, 0.7); /* Plus sombre sur mobile pour lisibilité */
    }
    .nav-arrow.prev { left: 10px; }
    .nav-arrow.next { right: 10px; }
}

/* =========================================
   10. FILTRES MÉDIAS
   ========================================= */
.media-filters {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-top: 15px;
    width: 100%;
    position: relative;
    z-index: 20;
}

.filter-btn {
    background-color: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
    padding: 8px 20px;
    border-radius: 20px;
    cursor: pointer;
    font-family: var(--font-main); /* Utilise votre police Nunito */
    font-size: 0.9rem;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.filter-btn:hover {
    background-color: rgba(255, 255, 255, 0.3);
}

/* Style quand le bouton est sélectionné */
.filter-btn.active {
    background-color: var(--primary-red);
    border-color: var(--primary-red);
    font-weight: bold;
}

/* =========================================
   11. FOOTER
   ========================================= */

    .footer-custom {
        background-color: #222;
        color: #eee;
        padding: 40px 20px;
        font-family: 'Nunito', sans-serif;
        text-align: center;
    }

    .footer-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-around;
    gap: 30px;
}

.footer-col {
    flex: 1 1 0; /* Assure une largeur égale */
    min-width: 0; /* Permet de réduire si besoin */
    text-align: left;
}

    .footer-col:first-child p {
    max-width: 320px;
    margin-right: auto;
    text-align: justify;
    }

    .footer-col h3 {
        color: #fff;
        margin-bottom: 15px;
        font-size: 1.5em;
        font-weight: 500;
    }

    .footer-col p {
        margin-bottom: 10px;
        line-height: 1.6;
        font-weight: 400;
    }

    .contact-item,
    .social-item {
        display: flex;
        align-items: center;
        margin-bottom: 10px;
    }

    .contact-item .icon-wrapper,
    .social-item .icon-wrapper {
        
        width: 40px;
        height: 40px;
        border-radius: 50%;
        background-color: #A03131;
        display: flex;
        justify-content: center;
        align-items: center;
        margin-right: 15px;
        color: #fff;
        font-size: 1.2em;
        overflow: hidden;
        transition: transform 0.2s ease, opacity 0.2s ease;
        text-decoration: none;
    }

    .social-item .icon-wrapper img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        transform: scale(1.1);
        text-decoration: none;
    }

    .contact-item a.contact-bubble-red,
    .social-item a {
        
        text-decoration: none;
        font-family: var(--font-sub);
        color: #eee;
        display: flex;
        align-items: center;
        padding: 8px 15px;
        border-radius: 50px;
        font-weight: 600;
        font-size: 1.1em;
        background-color: #A03131;
        transition: transform 0.2s ease, opacity 0.2s ease;
    }

    /* ZOOM et OPACITY au survol pour les deux sections */
    .social-item:hover .icon-wrapper,
    .social-item:hover a,
    .contact-item:hover .icon-wrapper,
    .contact-item:hover a.contact-bubble-red {
        transform: scale(1.07);
        opacity: 0.8;
        

    }

    .social-item .linkedin {
        background-color: #0C6FCC;
    }

    .social-item .instagram {
        background: linear-gradient(45deg, #f09433 0%, #e6683c 25%, #dc2743 50%, #cc2366 75%, #bc1888 100%);
    }

    .social-item .linkaband {
    background: linear-gradient(-45deg, #FF6B00 0%, #FFC200 100%);

}

    .social-item .portfolio {
        background-color: #555;
    }

    .footer-copyright {
        margin-top: 30px;
        padding-top: 20px;
        border-top: 1px solid #444;
        font-size: 0.9em;
        text-align: center;
        font-weight: 400;
    }

    @media (max-width: 768px) {
        .footer-container {
            flex-direction: column;
            align-items: center;
        }


        .footer-col {
            text-align: center;
            margin-bottom: 20px;
            width: 100%;
        }

        .footer-col p {
        text-align: justify;       /* Justifie le texte (bords droits) */
        text-align-last: center;   /* Centre la dernière ligne */
        padding: 0 20px;           /* Ajoute une marge de sécurité pour ne pas coller aux bords */
    }

        .contact-item,
        .social-item {
            justify-content: center;
        }

        .contact-item .icon-wrapper,
        .social-item .icon-wrapper {
            margin-right: 10px;
        }
        /* À placer DANS le bloc @media (max-width: 768px) tout en bas du fichier */

.footer-col:first-child p {
    max-width: 100%;    /* Annule la limite de 320px */
    margin-right: 0;    /* Annule le décalage */
    margin-left: 0;     /* S'assure que c'est bien calé */
}

    }

/* =========================================
   PAGE PORTFOLIO SPÉCIFIQUE
   ========================================= */

/* Couleur de fond spécifique au portfolio */
body.page-portfolio {
    background-color: #242321;
}

/* --- BOUTON RETOUR ACCUEIL --- */
.back-home-container {
    position: absolute; 
    top: 20px; 
    left: 20px; 
    z-index: 100;
}

.btn-back-home {
    color: white;
    font-family: var(--font-sub);
    font-weight: bold;
    background: rgba(0,0,0,0.5);
    padding: 10px 20px;
    border-radius: 5px;
    transition: background 0.3s ease, transform 0.2s ease;
    display: inline-block;
}

.btn-back-home:hover {
    background: var(--primary-red);
    transform: translateX(-5px); /* Petite animation sympa vers la gauche */
}

/* --- HERO PORTFOLIO --- */
.hero-portfolio {
    position: relative;
    height: 100vh;
    height: 100svh; /* Fix iOS Safari */
    min-height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    text-align: center;
    overflow: hidden;
}

.hero-portfolio video {
    position: absolute;
    top: 50%; left: 50%;
    min-width: 100%; min-height: 100%;
    width: auto; height: auto;
    transform: translate(-50%, -50%);
    z-index: -1;
    filter: brightness(0.5);
}

.hero-portfolio .hero-content h1 {
    font-family: var(--font-main); /* Uniformisation avec Josefin Sans */
    font-size: 2.8em;
    font-weight: 700;
    margin-bottom: 10px;
}

.hero-portfolio .hero-content h2 {
    font-family: var(--font-sub); /* Uniformisation avec Lato */
    font-weight: 200;
    font-size: 1.3em;
    color: #ddd;
}

/* --- MENU DE FILTRES --- */
.filter-menu {
    margin: 40px 0;
    text-align: center;
}

.filter-menu button {
    font-family: var(--font-sub);
    background: #9A291D; /* Rouge légèrement différent, ou utilisez var(--primary-red) */
    color: #fff;
    border: none;
    padding: 10px 20px;
    margin: 5px;
    cursor: pointer;
    border-radius: 50px;
    transition: all 0.2s ease;
    font-size: 1rem;
}

.filter-menu button:hover, 
.filter-menu button.active {
    background: #ba2326;
    transform: scale(1.05);
    font-weight: bold;
    box-shadow: 0 4px 10px rgba(0,0,0,0.3);
}

/* --- GRILLE DES PROJETS (PORTFOLIO) --- */
/* Note: Ceci est distinct de .projets-grid-container de l'accueil */
.grid-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 25px;
    padding: 20px 5%;
    max-width: 1600px;
    margin: 0 auto;
    padding-bottom: 80px;
}

.grid-item {
    position: relative;
    background: #2c2c2c;
    border-radius: 10px;
    overflow: hidden;
    aspect-ratio: 16 / 9;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.grid-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.4);
}

.grid-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease, filter 0.3s ease;
}

.grid-item:hover img {
    transform: scale(1.1);
    filter: brightness(0.4);
}

/* Overlay Textuel sur les projets */
.text-overlay {
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    opacity: 0;
    transition: opacity 0.3s ease;
    width: 90%;
    pointer-events: none;
}

.grid-item:hover .text-overlay {
    opacity: 1;
}

.text-overlay p {
    font-family: var(--font-main);
    font-weight: bold;
    color: #fff;
    font-size: 1.4em;
    margin: 0;
}

.text-overlay .category {
    font-family: var(--font-sub);
    font-size: 1em;
    color: #ccc;
    font-weight: 300;
    font-style: italic;
    text-transform: none;
    margin: 0;
}

/* --- RESPONSIVE PORTFOLIO --- */
@media (max-width: 768px) {
    .hero-portfolio {
        height: 40vh;
    }
    
    .hero-portfolio .hero-content h1 {
        font-size: 2rem;
    }
    
    .grid-container {
        grid-template-columns: 1fr; /* Une seule colonne sur mobile */
        padding: 20px;
    }
}

/* =========================================
   13. CRÉDITS LIGHTBOX
   ========================================= */
.media-credits {
    display: none; /* Caché par défaut */
    margin-top: 15px;
    color: #bbb; /* Gris clair pour ne pas éblouir */
    font-family: var(--font-sub);
    font-size: 0.95rem;
    text-align: center;
    width: 100%;
    padding: 0 10px;
    box-sizing: border-box;
    animation: fadeIn 0.5s ease;
}

/* Optionnel : si vous voulez mettre des noms en gras */
.media-credits strong {
    color: #fff;
    font-weight: 700;
}

/* =========================================
   14. MODALE VIDÉO : MODES D'AFFICHAGE
   ========================================= */

/* Surcharge spéciale quand c'est une photo */
#videoModal .modal-content.mode-photo {
    background-color: transparent; /* Fond transparent */
    box-shadow: none;              /* Enlève l'ombre portée du cadre */
    aspect-ratio: auto;            /* Enlève le format 16/9 forcé */
    width: auto;                   /* La largeur s'adapte à l'image */
    height: auto;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* On s'assure que l'image elle-même n'a pas de fond noir */
#imagePlayer {
    background-color: transparent; 
    box-shadow: 0 0 20px rgba(0,0,0,0.5); /* Petite ombre esthétique directement sur l'image */
    border-radius: 4px; /* Optionnel : léger arrondi */
    max-height: 85vh; /* L'image ne dépassera pas 85% de la hauteur de l'écran */
    width: auto;
    max-width: 95vw; /* Marge de sécurité sur les côtés */
}



/* =========================================
   15. PAGE MENTIONS LÉGALES
   ========================================= */

.legal-section {
    padding: 6rem 20px;
    background-color: var(--bg-dark);
    min-height: 100vh;
    display: flex;
    justify-content: center;
}

.legal-container {
    max-width: 800px;
    width: 100%;
    background-color: var(--bg-card);
    padding: 40px;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    text-align: left; /* Pour le texte courant */
}

/* Le titre principal : Style .section-title adapté */
.legal-main-title {
    /* Style visuel identique aux autres titres de section */
    background-color: var(--primary-red);
    color: white;
    font-weight: 900;
    text-transform: uppercase;
    border-radius: 8px;
    padding: 0.8rem 2.5rem;
    font-family: var(--font-main);
    
    /* Spécificités pour cette page : Plus gros et centré */
    font-size: 2.5rem; /* Taille imposante */
    display: table;    /* Astuce pour que le fond rouge colle au texte */
    margin: 0 auto 3rem auto; /* Centrage horizontal + marge bas */
    box-shadow: 0 4px 15px rgba(0,0,0,0.5); /* Petite ombre pour le relief */
}

.legal-intro {
    font-size: 1.1rem;
    color: var(--text-gray);
    margin-bottom: 3rem;
    text-align: justify;
}

.legal-block {
    margin-bottom: 2.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding-bottom: 1.5rem;
}

.legal-block:last-child {
    border-bottom: none;
}

.legal-block h2 {
    font-family: var(--font-sub); /* Lato, comme les sous-titres du site */
    font-size: 1.5rem;
    color: var(--text-white);
    margin-bottom: 1rem;
    font-weight: 700;
    border-left: 4px solid var(--primary-red); /* Petit rappel visuel discret */
    padding-left: 15px;
}

.legal-block p, .legal-contact-list li {
    font-family: var(--font-body);
    color: #ccc;
    font-size: 1rem;
    line-height: 1.8;
    margin-bottom: 0.5rem;
}

/* MODIFICATION : Éléments importants en Blanc et Gras (plus de rouge) */
.legal-block strong,
.legal-block a {
    color: var(--text-white); /* Blanc pur */
    font-weight: 700;         /* Gras */
    text-decoration: none;
}

/* Interaction subtile pour les liens */
.legal-block a:hover {
    text-decoration: underline;
    opacity: 0.9;
}

.legal-contact-list {
    list-style: none;
    padding: 0;
}

/* Responsive */
@media (max-width: 768px) {
    .legal-container {
        padding: 25px;
    }
    .legal-main-title {
        font-size: 1.6rem; /* Plus petit sur mobile pour ne pas déborder */
        padding: 0.6rem 1.5rem;
        width: 100%;       /* Prend toute la largeur si besoin */
        box-sizing: border-box;
        text-align: center;
    }
}

/* =========================================
   SECTION PARCOURS / A PROPOS (Mise à jour)
   ========================================= */

.about-container {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 50px;
  margin-top: 80px;
  margin-bottom: 20px;
  text-align: left;
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-top: 60px;
}

.about-image {
  flex: 1;
  max-width: 400px;
}

.about-image img {
  width: 100%;
  height: auto;
  border-radius: 4px;
  box-shadow: 0 5px 20px rgba(0,0,0,0.2); 
  object-fit: cover;
}

.about-text {
  flex: 1.5;
}

/* Style des paragraphes : Justifié comme la section précédente */
.about-text p {
  text-align: justify;       /* Texte aligné à gauche et à droite */
  text-align-last: left;     /* La dernière ligne reste à gauche */
  margin-bottom: 1rem;
  color: var(--text-gray);   /* Utilisation de votre variable couleur */
  font-size: 1.1rem;         /* Même taille que l'intro */
}

.about-text h3.section-title {
  margin-bottom: 30px;
  text-align: left;
}

/* --- Responsive Mobile --- */
@media (max-width: 900px) {
  .about-container {
    flex-direction: column;
    gap: 30px;
    margin-top: 50px;
    padding-top: 40px;
  }

  .about-image {
    max-width: 100%;
    margin: 0 auto;
    order: -1;
  }
  
  .about-text h3.section-title {
      text-align: center;
  }
  
  /* Sur mobile, on centre souvent le bouton */
  .about-text div {
      text-align: center;
  }
}

/* =========================================
   SECTION SERVICES (MISE À JOUR)
   ========================================= */

.services-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-top: 120px; /* AUGMENTÉ : Plus d'espace avec la section précédente */
  width: 100%;
}

.services-main-title {
  margin-top: 10px;
  align-self: center; 
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 30px;
  width: 100%;
}

.service-card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.05);
  padding: 40px 30px;
  border-radius: 10px;
  text-align: center;
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
  position: relative;
  overflow: hidden;
  display: flex;           /* Flexbox pour aligner le contenu */
  flex-direction: column;  /* Verticalement */
  justify-content: space-between; /* Pousse le contenu pour remplir la carte */
}

.service-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.4);
  border-color: var(--primary-red);
}

.service-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; width: 100%; height: 3px;
  background: var(--primary-red);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s ease;
}

.service-card:hover::before {
  transform: scaleX(1);
}

.service-card .icon-wrapper {
  font-size: 2.5rem;
  color: var(--primary-red);
  margin-bottom: 20px;
  background: rgba(136, 29, 25, 0.1);
  width: 80px; height: 80px;
  line-height: 80px;
  border-radius: 50%;
  margin-left: auto; margin-right: auto;
  transition: background 0.3s ease, color 0.3s ease;
}

.service-card:hover .icon-wrapper {
  background: var(--primary-red);
  color: white;
}

.service-card h4 {
  font-family: var(--font-main);
  font-size: 1.4rem;
  margin-bottom: 15px;
  color: var(--text-white);
  text-transform: uppercase;
  font-weight: 700;
}

.service-card p {
  color: var(--text-gray);
  font-size: 1rem;
  line-height: 1.6;
  text-align: justify;
  text-align-last: center;
  margin-bottom: 15px; /* Petit espace avant les exemples */
}

/* NOUVEAU : Style spécifique pour la ligne d'exemples */
.service-examples {
  font-family: var(--font-sub); /* Police Lato */
  font-size: 0.95rem !important; /* Force une taille légèrement plus petite */
  font-style: italic;
  color: #aaa !important; /* Gris un peu plus clair */
  margin-top: auto; /* Pousse vers le bas si les cartes ont des hauteurs différentes */
  border-top: 1px solid rgba(255,255,255,0.1); /* Petite ligne de séparation */
  padding-top: 15px;
}

/* Responsive Mobile */
@media (max-width: 768px) {
  .services-grid {
    grid-template-columns: 1fr;
  }
  .service-card {
    padding: 30px 20px;
  }
}


/* =========================================
   SECTION MÉTHODE (MISE À JOUR FINALE)
   ========================================= */

.method-container {
    /* 1. SEPARATEUR ET ESPACEMENT */
    margin-top: 80px;      /* Marge extérieure au-dessus du trait */
    padding-top: 80px;     /* Espace intérieur en dessous du trait */
    border-top: 1px solid rgba(255,255,255,0.1); /* Trait fin identique aux autres */
    width: 100%;
}

/* Conteneur global qui gère les 2 colonnes */
.method-wrapper {
    display: flex;
    flex-wrap: wrap; 
    gap: 60px;       
    align-items: flex-start; 
}

/* --- Colonne Gauche (Texte) : 40% --- */
.method-intro {
    flex: 4;             /* Ratio 40 */
    min-width: 300px;    /* Sécurité pour ne pas être trop écrasé */
    text-align: left;    
}

.method-intro h3 {
    margin-bottom: 30px;
    display: inline-block; 
}

.method-intro p {
    color: var(--text-gray);
    font-size: 1.05rem;
    line-height: 1.8;
    margin-bottom: 20px;
    text-align: justify; 
}

/* --- Colonne Droite (Les Étapes) : 60% --- */
.method-steps {
    flex: 6; /* Ratio 60 */
    
    display: grid;
    /* 3. FORCER L'AFFICHAGE PAR PAIRE */
    grid-template-columns: 1fr 1fr; /* Deux colonnes de même taille strictement */
    column-gap: 40px;
    row-gap: 50px;
}

.step {
    text-align: left;
    padding-left: 25px; 
    border-left: 1px solid rgba(255,255,255,0.1);
    transition: border-color 0.3s ease;
    position: relative; 
}

.step:hover {
    border-left-color: var(--primary-red);
}

/* LE CHIFFRE (Avec Animation) */
.step-number {
    font-family: var(--font-accent); 
    font-size: 3rem;
    color: rgba(255, 255, 255, 0.1); 
    display: block;
    margin-bottom: 10px;
    line-height: 1;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275); 
    transform-origin: left bottom; 
}

.step:hover .step-number {
    color: var(--primary-red);     
    transform: scale(1.3) rotate(-10deg); 
    text-shadow: 10px 10px 0px rgba(0,0,0,0.2); 
}

.step h5 {
    font-family: var(--font-main);
    font-size: 1.3rem;
    color: white;
    margin: 15px 0 10px 0;
    text-transform: uppercase;
    font-weight: 700;
}

.step p {
    font-size: 0.95rem;
    color: #aaa;
    line-height: 1.6;
}

/* --- Responsive Mobile --- */
@media (max-width: 900px) {
    .method-container {
        margin-top: 50px;
        padding-top: 50px;
    }

    .method-wrapper {
        flex-direction: column; /* Tout s'empile */
        gap: 40px;
    }
    
    .method-intro {
        text-align: center; 
        flex: auto; /* Réinitialise le ratio sur mobile */
        width: 100%;
    }
    
    .method-intro p {
        text-align: justify; /* Garde le justifié même sur mobile */
    }

    .method-steps {
        flex: auto; /* Réinitialise le ratio sur mobile */
        width: 100%;
        grid-template-columns: 1fr; /* Une seule colonne d'étapes sur mobile pour la lisibilité */
    }
}




/* =========================================
   19. BANNIÈRE COOKIES
   ========================================= */
.cookie-stripe {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background-color: #222; /* Noir profond */
    border-top: 1px solid rgba(255,255,255,0.1);
    z-index: 9999;
    padding: 15px 5%;
    box-sizing: border-box;
}

.cookie-content {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
}

.cookie-content p {
    color: #fff;
    margin: 0;
    font-family: var(--font-body);
    font-size: 0.9rem;
    line-height: 1.4;
    flex: 1;
}

.cookie-buttons {
    display: flex;
    align-items: center;
    gap: 30px;
}

.btn-deny {
    background: none;
    border: none;
    color: var(--primary-red); /* Votre rouge */
    font-family: var(--font-main);
    font-weight: 800;
    font-size: 0.85rem;
    cursor: pointer;
    text-transform: uppercase;
    padding: 10px;
    transition: color 0.3s;
}

.btn-deny:hover {
    color: #fff;
}

.btn-accept {
    background-color: #fff;
    color: #000;
    border: none;
    font-family: var(--font-main);
    font-weight: 800;
    font-size: 0.85rem;
    padding: 12px 25px;
    cursor: pointer;
    text-transform: uppercase;
    border-radius: 2px;
    transition: background 0.3s;
}

.btn-accept:hover {
    background-color: #e0e0e0;
}

/* Mobile */
@media (max-width: 768px) {
    .cookie-content { flex-direction: column; text-align: center; }
    .cookie-buttons { width: 100%; justify-content: center; }
}

/* =========================================
   CORRECTIF RESPONSIVE TITRE MÉTHODE
   ========================================= */

/* 1. On autorise le titre à passer sur 2 lignes si nécessaire */
.method-intro h3.section-title {
    white-space: normal;  /* Annule l'interdiction de retour à la ligne */
    word-wrap: break-word; /* Coupe proprement les mots si besoin */
    max-width: 100%;      /* Empêche de dépasser de la colonne */
    line-height: 1.4;     /* Espacement propre si le texte passe sur 2 lignes */
    display: inline-block;
}

/* 2. On réduit la taille du texte sur les écrans moyens (Tablettes / Petits PC) */
@media (max-width: 1200px) {
    .method-intro h3.section-title {
        font-size: 1.1rem; /* Taille réduite pour éviter le chevauchement */
        padding: 0.5rem 1rem; /* On réduit aussi un peu le padding rouge */
    }
    
    /* On force un peu plus d'espace entre les colonnes si ça devient serré */
    .method-wrapper {
        gap: 30px; 
    }
}

/* =========================================
   SECTION MAILLAGE LOCAL (PRE-FOOTER)
   ========================================= */
.local-mesh {
    background-color: #151515; /* Très sombre pour marquer la fin de page */
    padding: 60px 20px;
    border-top: 1px solid rgba(255,255,255,0.05);
    text-align: center;
}

.mesh-title {
    font-family: var(--font-main);
    font-weight: 300;
    color: white;
    font-size: 1.3rem;
    margin-bottom: 15px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.mesh-intro {
    color: var(--text-gray);
    font-size: 0.95rem;
    margin-bottom: 30px;
}

.city-links {
    list-style: none;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 15px;
}

.city-links li a {
    color: #888;
    font-family: var(--font-main);
    font-size: 0.9rem;
    text-decoration: none;
    border: 1px solid #333;
    padding: 8px 20px;
    border-radius: 50px; /* Style "Badge" arrondi */
    transition: all 0.3s ease;
    display: inline-block;
}

.city-links li a:hover {
    color: white;
    border-color: var(--primary-red);
    background-color: var(--primary-red);
    transform: translateY(-3px);
}


 /* =========================================
   PAGE CONTACT - REDESIGN PREMIUM
   ========================================= */

.contact-hero-wrapper {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 60px 80px 20px 80px; /* Padding haut pour compenser la navbar */
    background: radial-gradient(circle at top left, #2a2a2a, #1a1a1a); /* Fond sombre subtil */
    position: relative;
    overflow: hidden;
}

/* Grille 2 Colonnes */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    max-width: 1200px;
    width: 100%;
    align-items: center; /* Aligne verticalement au centre */
}

/* --- COLONNE GAUCHE (INFOS) --- */
.contact-info-col h1 {
    font-size: 3.5rem;
    font-family: var(--font-main);
    line-height: 1.1;
    margin-bottom: 20px;
    text-transform: uppercase;
}

.intro-text {
    font-size: 1.1rem;
    color: var(--text-gray);
    margin-bottom: 40px;
    max-width: 450px;
}

.info-items {
    display: flex;
    flex-direction: column;
    gap: 30px;
    margin-bottom: 40px;
}

.info-item {
    display: flex;
    align-items: flex-start;
    gap: 20px;
}

.icon-box {
    width: 50px;
    height: 50px;
    background: rgba(255,255,255,0.05);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-red);
    font-size: 1.2rem;
    border: 1px solid rgba(255,255,255,0.1);
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.info-item:hover .icon-box {
    background: var(--primary-red);
    color: white;
    transform: scale(1.1);
}

.info-item h4 {
    margin: 0 0 5px 0;
    font-family: var(--font-main);
    text-transform: uppercase;
    font-size: 1rem;
    color: white;
}

.info-item a, .info-item p {
    color: #ccc;
    font-size: 1.1rem;
    text-decoration: none;
    margin: 0;
    font-family: var(--font-sub);
    transition: color 0.3s;
}

.info-item a:hover { color: white; }

.sub-info {
    display: block;
    font-size: 0.85rem;
    color: #666;
    margin-top: 3px;
}

.social-mini {
    display: flex;
    gap: 20px;
}
.social-mini a {
    color: #666;
    font-size: 1.5rem;
    transition: color 0.3s, transform 0.3s;
}
.social-mini a:hover {
    color: var(--primary-red);
    transform: translateY(-3px);
}

/* --- COLONNE DROITE (FORMULAIRE STYLE GLASS) --- */
.contact-form-col {
    background: rgba(30, 30, 30, 0.4); /* Fond semi-transparent */
    backdrop-filter: blur(20px);         /* Flou d'arrière plan */
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 20px 50px rgba(0,0,0,0.3);
}

.form-title {
    margin-bottom: 25px;
    color: white;
    font-family: var(--font-main);
    text-transform: uppercase;
    font-size: 1.5rem;
}

.form-row {
    display: flex;
    gap: 20px;
}

.input-group {
    margin-bottom: 20px;
    width: 100%;
}

.input-group label {
    display: block;
    font-size: 0.85rem;
    color: #aaa;
    margin-bottom: 8px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.input-group input, 
.input-group textarea {
    width: 100%;
    background: rgba(255,255,255,0.03); /* Fond très léger */
    border: 1px solid rgba(255,255,255,0.1);
    color: white;
    padding: 15px;
    border-radius: 8px;
    font-family: var(--font-sub);
    font-size: 1rem;
    transition: all 0.3s ease;
    box-sizing: border-box; /* Important pour ne pas casser la largeur */
}

/* Focus : Le champ s'illumine en rouge */
.input-group input:focus, 
.input-group textarea:focus {
    background: rgba(255,255,255,0.08);
    border-color: var(--primary-red);
    outline: none;
    box-shadow: 0 0 15px rgba(136, 29, 25, 0.2);
}

.btn-submit {
    background: var(--primary-red);
    color: white;
    border: none;
    padding: 15px 30px;
    font-family: var(--font-main);
    font-weight: 700;
    text-transform: uppercase;
    border-radius: 8px;
    cursor: pointer;
    width: 100%;
    font-size: 1rem;
    transition: all 0.3s;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
}

.btn-submit:hover {
    background: white;
    color: var(--primary-red);
    transform: translateY(-2px);
}

/* --- SUCCESS BOX DESIGN --- */
.success-box {
    text-align: center;
    padding: 20px;
}
.success-icon {
    width: 80px; height: 80px;
    background: #27ae60;
    color: white;
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 2rem;
    margin: 0 auto 20px auto;
    animation: popIn 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}
.success-box h2 { color: white; margin-bottom: 10px; }
.success-box p { color: #ccc; margin-bottom: 20px; }
.btn-reset {
    background: transparent;
    border: 1px solid #555;
    color: #aaa;
    padding: 10px 20px;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.3s;
}
.btn-reset:hover { border-color: white; color: white; }

/* --- RESPONSIVE --- */
@media (max-width: 900px) {
    .contact-grid {
        grid-template-columns: 1fr; /* Une seule colonne sur mobile */
        gap: 40px;
    }
    
    .contact-hero-wrapper {
        padding-top: 100px;
        height: auto; /* Hauteur auto sur mobile */
        padding-left: 10%;
        padding-right: 10%;
    }

    .contact-info-col h1 { font-size: 2.5rem; text-align: center; }
    .intro-text { text-align: center; margin: 0 auto 40px auto; }
    
    .form-row { flex-direction: column; gap: 0; } /* Inputs empilés sur mobile */
    
    .social-mini { justify-content: center; margin-bottom: 30px; }
}

/* =========================================
   ANIMATIONS PAGE CONTACT (SÉQUENCAGE)
   ========================================= */

/* 1. On définit l'animation de base (si elle n'existe pas déjà) */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px); /* Vient d'un peu plus bas */
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* 2. Classe générique pour animer */
.fade-in {
    opacity: 0; /* Caché au départ */
    animation: fadeInUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

/* 3. LE SÉQUENCAGE (C'est ici que la magie opère) */

/* Le titre et le texte de gauche arrivent en premier (0.2s) */
.contact-info-col {
    animation-delay: 0.2s;
}

/* Les petites infos (Tel, Mail, Zone) arrivent en cascade */
.info-item {
    opacity: 0;
    animation: fadeInUp 0.6s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

.info-item:nth-child(1) { animation-delay: 0.4s; } /* Téléphone */
.info-item:nth-child(2) { animation-delay: 0.5s; } /* Email */
.info-item:nth-child(3) { animation-delay: 0.6s; } /* Zone */

/* Les réseaux sociaux arrivent après */
.social-mini {
    opacity: 0;
    animation: fadeInUp 0.6s ease forwards;
    animation-delay: 0.7s;
}

/* La grosse colonne Formulaire (à droite) arrive en dernier (0.4s) */
.contact-form-col {
    animation-delay: 0.4s;
}










    
  /* =========================================
   MENU NAVIGATION "DYNAMIC ISLAND" (ULTRA SMOOTH)
   ========================================= */

.navbar {
    position: fixed;
    top: 15px; /* Position finale désirée */
    left: 50%;
    
    /* État de départ : 
       - Décalé vers le haut (-100%)
       - Légèrement plus petit (scale 0.9) pour l'effet d'expansion
       - Centré horizontalement (-50%) */
    transform: translateX(-50%) translateY(-150%) scale(0.9);
    
    width: auto; /* S'adapte au contenu */
    min-width: 300px; /* Minimum de largeur */
    max-width: 90%; 
    
    padding: 10px 10px; /* Padding fin pour le côté "pillule" */
    z-index: 1000;
    
    /* Design Pilule Glassmorphism */
    background: rgba(18, 18, 18, 0.75); /* Noir profond mais transparent */
    backdrop-filter: blur(20px) saturate(180%); /* Flou intense type iOS */
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 100px; /* Arrondi maximal */
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4); /* Ombre diffuse et profonde */
    
    /* L'ANIMATION MAGIQUE */
    opacity: 0;
    /* Cubic-bezier(0.16, 1, 0.3, 1) = "Ease Out Expo" 
       C'est la courbe qui donne cet effet "rapide puis freinage très doux" */
    transition: 
        transform 0.8s cubic-bezier(0.16, 1, 0.3, 1),
        opacity 0.4s ease-out;
        
    pointer-events: none;
}

/* ÉTAT VISIBLE */
.navbar.visible {
    /* On remet tout à zéro : position normale et taille normale */
    transform: translateX(-50%) translateY(0) scale(1);
    opacity: 1;
    pointer-events: all;
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    padding: 0 15px; /* Petit padding interne */
}

/* Logo */
/* --- LOGO IMAGE --- */

/* On nettoie le style du lien conteneur */
.nav-logo {
    display: flex; /* Permet de bien centrer l'image verticalement */
    align-items: center;
    text-decoration: none;
    padding: 0; /* On enlève les marges parasites */
}

/* On contrôle la taille de l'image */
.nav-logo img {
    height: 35px; /* Hauteur idéale pour la barre "Dynamic Island" */
    width: auto;  /* La largeur s'adapte automatiquement */
    object-fit: contain; /* Assure que le logo ne soit pas déformé */
    
    /* Optionnel : Si votre logo est noir et que vous voulez le forcer en blanc via le code */
    /* filter: brightness(0) invert(1); */ 
}

/* Ajustement Mobile (parfois le logo doit être plus petit sur téléphone) */
@media (max-width: 900px) {
    .nav-logo img {
        height: 30px; /* Un peu plus petit sur mobile pour gagner de la place */
    }
}

.logo-red { color: #a52621; }

/* Liens Bureau */
.nav-links {
    list-style: none;
    display: flex;
    gap: 5px; /* On rapproche les éléments car c'est une pilule */
    align-items: center;
    margin: 0;
    padding: 0;
    background: rgba(255,255,255,0.05); /* Fond subtil derrière les liens */
    padding: 5px;
    border-radius: 50px;
}

.nav-links li a {
    font-family: var(--font-main);
    color: #aaa;
    font-weight: 500;
    font-size: 0.85rem;
    text-transform: uppercase;
    transition: all 0.3s ease;
    padding: 8px 16px;
    border-radius: 30px;
    display: block;
    white-space: nowrap;
}

/* Effet "Pastille" au survol ou actif */
.nav-links li a:hover,
.nav-links li a.active {
    color: white;
    background-color: rgba(255,255,255,0.1); /* Petite pastille qui s'allume */
}

/* Bouton Contact Spécial */
.nav-btn {
    background-color: var(--primary-red) !important;
    color: white !important;
    font-weight: 700 !important;
    box-shadow: 0 4px 15px rgba(136, 29, 25, 0.3);
    white-space: nowrap !important; /* Force le texte sur une ligne */
    display: inline-block; /* Assure que le bouton garde sa forme */
}

.nav-btn:hover {
    transform: scale(1.05);
    background-color: #a52621 !important;
}

/* Burger Menu (Mobile) */
.burger-menu {
    display: none;
    font-size: 1.2rem;
    color: white;
    cursor: pointer;
    padding-left: 10px;
}
/* =========================================
   CORRECTION MENU MOBILE (Display: None par défaut)
   ========================================= */

/* PAR DÉFAUT (ORDI) : Le menu mobile n'existe pas */
.mobile-nav {
    display: none; 
}

/* =========================================
   RESPONSIVE (TABLETTE & MOBILE < 900px)
   ========================================= */
@media (max-width: 900px) {
    
    /* 1. On adapte la barre principale */
    .navbar {
        width: 85%; 
        padding: 8px 15px; /* Un peu moins de padding */
    }
    
    /* 2. On cache les liens "PC" */
    .nav-links { 
        display: none; 
    }
    
    /* 3. On affiche le Burger */
    .burger-menu { 
        display: block; 
    }

    /* 4. ON ACTIVE LE MENU MOBILE UNIQUEMENT ICI */
    .mobile-nav {
        /* Positionnement */
        position: absolute;
        top: 60px; /* Juste sous la pilule */
        left: 0;
        width: 100%;
        
        /* Style Apple Glass */
        background-color: rgba(18, 18, 18, 0.95);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        border: 1px solid rgba(255,255,255,0.1);
        border-radius: 25px; 
        
        /* Mise en page interne */
        display: flex; /* C'est ICI qu'on le rend visible structurellement */
        flex-direction: column;
        align-items: center;
        padding: 10px 0;
        
        /* Animation d'apparition */
        opacity: 0;
        transform: translateY(-10px) scale(0.95);
        pointer-events: none; /* Empêche de cliquer quand c'est invisible */
        transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
        z-index: 900;
    }

    /* L'état actif (quand on clique sur le burger) */
    .mobile-nav.active {
        opacity: 1;
        transform: translateY(0) scale(1);
        pointer-events: all;
    }

    /* Style des liens mobiles */
    .mobile-nav a {
        padding: 15px;
        color: white;
        font-family: var(--font-main);
        text-transform: uppercase;
        font-size: 1rem;
        width: 100%;
        text-align: center;
        border-bottom: 1px solid rgba(255,255,255,0.05);
        text-decoration: none;
    }
    
    .mobile-nav a:last-child { 
        border-bottom: none; 
    }
}

/* =========================================
   ANIMATION MENU PAGE CONTACT (AVEC LATENCE)
   ========================================= */

/* 1. On définit le mouvement (exactement le même que votre effet "Dynamic Island") */
@keyframes slideDownNavbar {
    0% {
        transform: translateX(-50%) translateY(-150%) scale(0.9);
        opacity: 0;
    }
    100% {
        transform: translateX(-50%) translateY(0) scale(1);
        opacity: 1;
    }
}

/* 2. On l'applique sur la page contact et les articles */
body.page-contact .navbar,
body.page-article .navbar {
    /* On applique l'animation définie juste au-dessus */
    animation: slideDownNavbar 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;

    /* C'EST ICI QU'ON GÈRE LA LATENCE */
    animation-delay: 0.5s; /* Attend 0.5 seconde avant de descendre */

    /* On active les clics (mais le menu reste caché pendant la latence grâce à l'animation) */
    pointer-events: auto;
}


/* =========================================
   23. MODALE VIDÉO : CORRECTIFS LECTEURS
   ========================================= */

/* 1. La boite modale : On utilise FLEX pour empiler verticalement (Haut vers Bas) */
#videoModal .modal-content {
    display: flex;
    flex-direction: column; /* Indispensable pour que le texte soit SOUS la vidéo */
    justify-content: center;
    align-items: center;
    position: relative;
    overflow: visible; /* On laisse dépasser si besoin */
    height: auto;      /* La hauteur s'adapte au contenu */
    max-height: 95vh;  /* Sécurité pour ne pas sortir de l'écran */
    background: black;
}

/* 2. Les lecteurs : Ils ne sont PLUS en absolute, ils prennent de la place physique */
#videoPlayer, #iframePlayer {
    position: relative; /* Revient dans le flux normal */
    width: 100%;
    aspect-ratio: 16/9; /* Force le format vidéo standard pour réserver la place */
    height: auto;
    z-index: 10;
    display: none; /* Caché par défaut, le JS s'occupe de mettre display: block */
}

/* =========================================
   22. MENU DÉROULANT (DROPDOWN)
   ========================================= */

/* Le conteneur du lien parent */
.dropdown-item {
    position: relative; /* Indispensable pour positionner le sous-menu par rapport à lui */
    display: inline-block;
    height: 100%;
}

/* Le menu caché par défaut */
.dropdown-menu {
    position: absolute;
    top: 140%; /* On le place un peu en dessous de la barre */
    left: 50%;
    transform: translateX(-50%) translateY(-10px); /* Centré + petit décalage haut pour l'anim */
    
    min-width: 220px; /* Assez large pour le texte */
    background: rgba(18, 18, 18, 0.95); /* Noir profond comme la navbar */
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 15px;
    padding: 10px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    
    list-style: none;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 1000;
    display: flex;
    flex-direction: column;
    gap: 5px;
}

/* Petite flèche CSS pour relier le menu à la barre (optionnel mais esthétique) */
.dropdown-menu::before {
    content: '';
    position: absolute;
    top: -6px;
    left: 50%;
    transform: translateX(-50%) rotate(45deg);
    width: 12px;
    height: 12px;
    background: rgba(18, 18, 18, 0.95);
    border-top: 1px solid rgba(255, 255, 255, 0.12);
    border-left: 1px solid rgba(255, 255, 255, 0.12);
}

/* APPARITION AU SURVOL */
.dropdown-item:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0); /* Animation douce vers le bas */
}

/* Style des liens dans le sous-menu */
.dropdown-menu li a {
    display: block;
    padding: 10px 15px;
    border-radius: 8px;
    text-align: center; /* Ou left selon ta préférence */
    white-space: normal; /* Autorise le retour à la ligne si besoin */
    font-size: 0.9rem;
    color: #ccc;
    transition: all 0.2s ease;
}

.dropdown-menu li a:hover {
    background-color: rgba(255, 255, 255, 0.1);
    color: white;
    transform: translateX(5px); /* Petite animation vers la droite */
}

/* Ajustement de la flèche icône quand on survole */
.dropdown-item:hover .dropdown-trigger i {
    transform: rotate(180deg);
    transition: transform 0.3s ease;
}

/* 1. GESTION DU CHARGEMENT (Anti-Flash Gris) */
/* Quand le JS dit "c'est en train de charger", on rend tout transparent immédiatement */
#videoModal .modal-content.is-loading {
    background-color: transparent !important;
    box-shadow: none !important;
    transition: none !important; /* On coupe l'animation pour que ça disparaisse tout de suite */
}

/* 2. MODE NATIF (Vidéos internes MP4) */
#videoModal .modal-content.mode-native {
    /* On annule le 16:9 et les dimensions fixes */
    aspect-ratio: unset !important;
    
    /* C'est ICI que se joue le centrage des 16:9 */
    width: fit-content !important;  /* Le conteneur colle à la vidéo */
    margin: auto !important;        /* Le conteneur se centre dans l'écran */
    
    background-color: transparent !important; /* Pas de fond gris */
    box-shadow: none !important;              /* Pas d'ombre */
    
    /* On s'assure que le flex parent peut bien le centrer */
    align-self: center; 
}

/* Le lecteur vidéo lui-même */
#videoModal .modal-content.mode-native #videoPlayer {
    /* Hauteur fixe pour l'homogénéité (Verticale ou Horizontale = même hauteur) */
    height: 85vh !important;
    
    /* La largeur s'adapte toute seule */
    width: auto !important;
    
    /* Limites pour ne pas sortir de l'écran */
    max-width: 90vw; 
    
    display: block;
    object-fit: contain;
}

/* Ajustement Mobile */
@media (max-width: 768px) {
    #videoModal .modal-content.mode-native #videoPlayer {
        height: auto !important; /* Sur mobile, on laisse la hauteur auto */
        width: 100% !important;  /* On prend toute la largeur dispo */
        max-height: 80vh;        /* On bloque juste la hauteur max */
    }
}

/* =========================================
   24. FLÈCHE SCROLL HERO
   ========================================= */
.scroll-arrow {
    position: absolute;
    bottom: 8%;
    left: 50%;
    transform: translateX(-50%);
    z-index: 3;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px; /* ← Réduit de 6px à 2px */
    cursor: pointer;
    opacity: 1;
}

.scroll-arrow span {
    display: block;
    width: 14px;
    height: 14px;
    border-right: 2px solid rgba(255, 255, 255, 0.9);
    border-bottom: 2px solid rgba(255, 255, 255, 0.9);
    transform: rotate(45deg);
    animation: bounceArrow 1s ease-in-out infinite;
}

.scroll-arrow span:nth-child(2) {
    animation-delay: 0.2s;
    opacity: 0.6;
}

.scroll-arrow span:nth-child(3) {
    animation-delay: 0.4s;
    opacity: 0.3;
}

@keyframes bounceArrow {
    0%   { transform: rotate(45deg) translate(0, 0); opacity: 1; }
    50%  { transform: rotate(45deg) translate(4px, 4px); opacity: 0.5; }
    100% { transform: rotate(45deg) translate(0, 0); opacity: 1; }
}

/* =========================================
   25. FAQ STRUCTURÉE (SEO / GEO)
   ========================================= */

.faq-section {
    padding: 4rem 5%;
    background: var(--bg-dark);
}

.faq-list {
    margin: 0;
    padding: 0;
    max-width: 860px;
}

/* Accordion : <details> / <summary> */
.faq-item {
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.faq-item:last-child {
    border-bottom: none;
}

.faq-item[open] {
    border-bottom-color: rgba(136, 29, 25, 0.25);
}

.faq-question {
    list-style: none;
    cursor: pointer;
    font-family: var(--font-main);
    font-size: 1.05rem;
    color: var(--text-white);
    padding: 1.2rem 0.5rem 1.2rem 1.2rem;
    border-left: 3px solid var(--primary-red);
    display: flex;
    justify-content: space-between;
    align-items: center;
    user-select: none;
    line-height: 1.4;
    transition: color 0.2s ease;
}

.faq-question::-webkit-details-marker { display: none; }
.faq-question::marker { display: none; }

.faq-question::after {
    content: '+';
    color: var(--primary-red);
    font-size: 1.5rem;
    font-family: var(--font-sub);
    font-weight: 300;
    line-height: 1;
    margin-left: 1rem;
    flex-shrink: 0;
    transition: transform 0.25s ease;
}

.faq-item[open] .faq-question::after {
    content: '−';
}

.faq-question:hover {
    color: var(--text-gray);
}

.faq-answer {
    color: var(--text-gray);
    font-size: 0.95rem;
    line-height: 1.75;
    margin: 0;
    padding: 0.4rem 1.2rem 1.4rem 1.2rem;
}

@media (max-width: 768px) {
    .faq-section { padding: 3rem 5%; }
    .faq-question { font-size: 0.95rem; }
    .faq-answer { font-size: 0.9rem; }
}

/* =========================================
   26. FIGURE / FIGCAPTION
   ========================================= */

figure {
    margin: 0;
    padding: 0;
}

figcaption {
    font-family: var(--font-sub);
    font-size: 0.8rem;
    color: #888;
    text-align: center;
    margin-top: 0.5rem;
    font-style: italic;
}