/* =========================================
   1. VARIABLES & BASE (Thème 100% harmonisé)
   ========================================= */
:root {
    /* Couleurs de fond (Thème sombre global) */
    --bg-dark: #0f1115;        /* Fond très sombre (Hero, Contact) */
    --bg-alt: #161a20;         /* Fond légèrement plus clair (Cartes, À propos, Détails) */
    
    /* Couleur d'accentuation (Le Bleu du Hero) */
    --accent-blue: #0084ff;
    --accent-blue-hover: #006dd4;
    
    /* Textes */
    --text-main: #fcfcfc;      /* Texte principal blanc */
    --text-secondary: #aaaaaa; /* Texte secondaire gris clair */
    
    /* Police */
    --font-main: 'Eras ITC', 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

@font-face {
    font-family: 'Eras ITC';
    src: url('../fonts/eras-itc-medium.ttf') format('truetype');
    font-display: swap;
}

html {
    scroll-behavior: smooth;
}

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

body {
    background-color: var(--bg-dark); 
    color: var(--text-main);
    font-family: var(--font-main);
    line-height: 1.6;
    overflow-x: hidden; /* Empêche le défilement horizontal */
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

a {
    text-decoration: none;
    color: inherit;
    transition: color 0.3s ease;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* =========================================
   2. TYPOGRAPHIE & SECTIONS
   ========================================= */
.title-color { 
    color: var(--accent-blue); 
    text-transform: uppercase; 
    font-weight: bold;
    margin-bottom: 20px; 
}

.styling-dark { 
    background-color: var(--bg-dark); 
    color: var(--text-main); 
    padding: 80px 15px; 
}

.styling-light { 
    background-color: var(--bg-alt); 
    color: var(--text-main); 
    padding: 80px 15px; 
}

/* =========================================
   3. BOUTONS
   ========================================= */
.btn {
    display: inline-block;
    padding: 10px 24px;
    border-radius: 6px;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    border: none;
    text-align: center;
    transition: all 0.3s ease;
}

.btn-blue, .button-bg {
    background-color: var(--accent-blue);
    color: #fff;
    font-weight: 700;
}
.btn-blue:hover, .button-bg:hover { 
    background-color: var(--accent-blue-hover); 
    color: #fff; 
    transform: translateY(-2px); 
}

.btn-large {
    padding: 14px 32px;
    font-size: 16px;
}

/* =========================================
   4. HEADER & NAVIGATION
   ========================================= */
header {
    background-color: rgba(15, 17, 21, 0.98); /* Fond opaque pour éviter le bug sur mobile */
    padding: 15px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo-img { height: 60px; width: auto; }

nav ul {
    list-style: none;
    display: flex;
    gap: 30px;
    margin: 0;
    padding: 0;
}

nav a {
    font-size: 15px;
    font-weight: 500;
    color: var(--text-secondary);
}

nav a:hover { color: var(--text-main); }

#nav-menu {
    display: block !important;
}

#nav-menu ul {
    display: flex !important;
    list-style: none;
    gap: 30px;
}

.menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 21px;
    background: transparent;
    border: none;
    cursor: pointer;
    z-index: 1001;
}

.menu-toggle .bar {
    width: 100%;
    height: 3px;
    background-color: var(--text-main);
    border-radius: 3px;
    transition: all 0.3s ease;
}

.header-cta a {
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 600;
    letter-spacing: 1px;
    text-transform: uppercase;
    padding-bottom: 4px;
    border-bottom: 2px solid transparent;
    transition: all 0.3s ease;
}

.header-cta a:hover {
    color: var(--accent-blue) !important;
    border-bottom: 2px solid var(--accent-blue);
}

/* =========================================
   5. HERO SECTION
   ========================================= */
.hero {
    position: relative;
    padding: 140px 0;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    text-align: center;
    color: var(--text-main);
}

.hero-overlay {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: radial-gradient(circle, rgba(15,17,21,0.6) 0%, rgba(15,17,21,0.95) 100%);
    z-index: 1;
}

.hero-container {
    position: relative;
    z-index: 2;
    max-width: 900px;
    margin: 0 auto;
}

.hero-title {
    font-size: clamp(28px, 5vw, 40px);
    font-weight: 800;
    margin-bottom: 20px;
    line-height: 1.2;
}

.hero-title span {
    display: block;
    font-size: clamp(18px, 4vw, 24px);
    font-weight: 600;
    color: var(--text-secondary);
    margin-top: 10px;
}

.hero-subtitle {
    font-size: 18px;
    color: var(--text-secondary);
    margin-bottom: 40px;
    font-weight: 400;
}

/* =========================================
   6. CARTES DE SERVICES
   ========================================= */
.services {
    padding: 60px 0;
    background-color: var(--bg-dark);
}

.services-container {
    display: flex;
    justify-content: center;
    gap: 30px;
    flex-wrap: wrap;
}

.card {
    background-color: var(--bg-alt);
    color: var(--text-main);
    border-radius: 12px;
    padding: 30px;
    flex: 1 1 300px;
    max-width: 360px;
    border: 2px solid transparent;
    transition: transform 0.3s ease, border-color 0.3s ease;
    text-align: center;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
}

.card:hover { transform: translateY(-8px); }
.card.active { border-color: var(--accent-blue); background-color: #1a222b; }
.card-icon { margin-bottom: 25px; display: flex; justify-content: center; align-items: center; }
.card-icon img { height: 48px; width: auto; }
.card-title { font-size: 16px; font-weight: 700; margin-bottom: 12px; }
.card-text { font-size: 14px; color: var(--text-secondary); }

/* =========================================
   7. CONTENU DÉTAILLÉ (Listes, Carrousels, À propos)
   ========================================= */
.prestations-list {
    margin-left: 20px;
    margin-bottom: 30px;
    color: var(--text-secondary);
}
.prestations-list li { margin-bottom: 8px; }

/* Carrousels */
.carousel-item img {
    width: 100%;
    max-height: 450px;
    object-fit: cover;
    border-radius: 8px;
}

/* À propos (Identité) */
.presentation-wrapper {
    display: flex;
    align-items: flex-start;
    gap: 40px;
}

.identity-img {
    width: 100%;
    max-width: 300px;
    border-radius: 12px;
    object-fit: cover;
    flex-shrink: 0;
    border: 2px solid rgba(255,255,255,0.05); 
}

.identity-text p {
    color: var(--text-secondary);
}

/* Pictogrammes */
.bloc-picto {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
    margin-top: 40px;
}

.bloc-picto img {
    width: 50px;
    height: 50px;
    object-fit: contain;
    filter: invert(1) opacity(0.5); 
    transition: transform 0.3s ease, filter 0.3s ease;
}

.bloc-picto img:hover {
    transform: scale(1.15);
    filter: invert(1) opacity(1); 
}

/* Formulaire de Contact */
.contact-form {
    background: var(--bg-alt);
    padding: 30px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}

.form-label {
    color: var(--text-secondary);
}

.form-control {
    background-color: rgba(0,0,0,0.2) !important;
    border: 1px solid rgba(255,255,255,0.1) !important;
    color: var(--text-main) !important;
}
.form-control:focus {
    border-color: var(--accent-blue) !important;
    box-shadow: 0 0 0 0.25rem rgba(0, 132, 255, 0.25) !important;
}

/* Bouton Retour en haut */
#backToTop {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 100;
    border-radius: 5px;
    padding: 10px 15px;
    background-color: var(--accent-blue);
    color: white;
    border: none;
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(0,0,0,0.3);
    transition: background-color 0.3s ease;
}
#backToTop:hover { background-color: var(--accent-blue-hover); }

/* Quand le menu est ouvert, on fait disparaître les titres de la page */
body.menu-open h1, 
body.menu-open .title-color,
body.menu-open .hero-title {
    display: none !important;
}

/* =========================================
   8. RESPONSIVE MOBILE & TABLETTE
   ========================================= */
@media (max-width: 992px) {
    .presentation-wrapper {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }
    .identity-img { margin-bottom: 20px; }
}

@media (max-width: 768px) {
    .menu-toggle { display: flex; }
    .header-cta { display: none; }

}
    /* CORRECTION DU MENU MOBILE ICI */
    nav {
        position: fixed;
        top: 0;
        right: 0;
        transform: translateX(100%); /* Cache le menu à droite sans casser la largeur de l'écran */
        width: 80%;
        max-width: 300px;
        height: 100vh;
        background-color: rgba(15, 17, 21, 0.98);
        padding: 100px 30px 30px;
        transition: transform 0.4s ease; /* Animation propre du transform */
        box-shadow: -5px 0 15px rgba(0,0,0,0.5);
        z-index: 1000;
        overflow-y: auto;
    }

    nav.active { 
        transform: translateX(0); /* Fait glisser le menu par-dessus le contenu */
    }

    nav ul { flex-direction: column; align-items: center; gap: 30px; }
    nav a { font-size: 18px; color: var(--text-main); }

    .hero { padding: 100px 0; }
    .hero-subtitle { font-size: 16px; }
    
    .styling-dark, .styling-light { padding: 50px 15px; }

    .carousel-item img { max-height: 300px; }
    .bloc-picto img { width: 40px; height: 40px; }


/* --- Carrousels plus discrets --- */
.carousel-item img {
    width: 100%;
    max-height: 380px; /* On réduit la hauteur pour moins d'encombrement */
    object-fit: cover;
    border-radius: 15px; /* Bord arrondi plus doux */
    border: 1px solid rgba(255, 255, 255, 0.1); /* Filet très fin pour délimiter l'image */
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5); /* Ombre portée pour donner de la profondeur */
    filter: brightness(0.9); /* On baisse légèrement la luminosité pour l'accorder au thème sombre */
    transition: filter 0.3s ease;
}

.carousel-item img:hover {
    filter: brightness(1); /* L'image s'éclaire quand on passe dessus */
}

/* --- Photo de profil / Images libres de droit --- */
.identity-img {
    width: 100%;
    max-width: 280px; /* Taille plus petite et élégante */
    border-radius: 20px;
    object-fit: cover;
    border: 1px solid rgba(0, 132, 255, 0.3); /* Bordure bleue très fine pour rappeler le Hero */
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.4);
    margin: 0 auto;
}

/* Optionnel : ajouter un léger reflet sur l'image pour qu'elle "fonde" dans le noir */
.presentation-wrapper {
    position: relative;
}

.presentation-wrapper::after {
    content: "";
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: linear-gradient(to bottom, transparent 80%, var(--bg-alt) 100%);
    pointer-events: none; /* Effet de dégradé au pied de la photo pour la fondre dans le fond */
}

.bloc-picto img {
    width: 45px; /* Encore un peu plus petit */
    height: 45px;
    object-fit: contain;
    filter: invert(1) opacity(0.3); /* Très discret par défaut */
    transition: all 0.4s ease;
}

.bloc-picto img:hover {
    filter: invert(1) opacity(0.9);
    transform: translateY(-5px); /* Petit saut élégant */
}

/* --- Style du Footer Harmonisé --- */
footer.styling-dark {
    background-color: var(--bg-dark); /* Assure que le fond est le même que le Hero */
}

.footer-link {
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 14px;
    transition: color 0.3s ease;
}

.footer-link:hover {
    color: var(--accent-blue); /* Le lien devient bleu au survol */
}

/* Si ton icône LinkedIn est noire à l'origine, ce filtre la rendra blanche */
.linkedin-icon {
    width: 30px;
    height: auto;
    filter: invert(1) brightness(1.5); /* Rend l'icône blanche/claire */
    opacity: 0.6;
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.linkedin-icon:hover {
    opacity: 1;
    transform: scale(1.1);
}

/* Style spécifique pour le contenu légal */
.legal-content p {
    margin-bottom: 1.2rem;
    line-height: 1.7;
    color: var(--text-secondary); /* Texte gris clair pour ne pas fatiguer l'oeil */
}

.legal-content strong {
    color: var(--text-main); /* On met en blanc brillant les noms importants */
}

.legal-content h2 {
    margin-top: 2rem;
    letter-spacing: 1px;
}

.text-accent {
    color: var(--accent-blue) !important;
    text-decoration: underline;
}

.text-accent:hover {
    color: white !important;
}

/* On s'assure que styling-light ne flashe pas en blanc sur cette page */
.styling-light header {
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

/* Animation du bouton burger en croix */
.menu-toggle.is-active .bar:nth-child(2) {
    opacity: 0;
}
.menu-toggle.is-active .bar:nth-child(1) {
    transform: translateY(9px) rotate(45deg);
}
.menu-toggle.is-active .bar:nth-child(3) {
    transform: translateY(-9px) rotate(-45deg);
}

/* Rend TOUS les éléments de la liste de compétences blancs et lisibles sur mobile */
@media (max-width: 768px) {
    #identity .identity-text ul li {
        color: #ffffff !important;
        opacity: 1 !important;
        font-weight: 500; /* Optionnel : rend le texte un peu plus costaud */
        margin-bottom: 10px;
    }
}

/* On ne cache QUE le bloc titre qui a la classe header-titre-page */
body.menu-open .header-titre-page {
    display: none !important;
}

/* On s'assure que la barre de navigation (le vrai header) reste visible */
body.menu-open header {
    display: block !important; /* Ou flex selon ton style de base */
}



