/* Variables globales */
:root {
    --color-bg: #0a0a1a;
    --color-accent: #00a8ff;
    --color-white: #ffffff;
    --color-purple: #8a2be2;
    --color-cyan: #00ffff;
    --font-title: 'Orbitron', sans-serif;
    --font-text: 'Exo 2', sans-serif;
}

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

html {
    overflow-x: hidden;
}

body {
    background-color: var(--color-bg);
    color: var(--color-white);
    font-family: var(--font-text);
    min-height: 100vh;
    overflow-x: hidden;
    padding-top: 70px !important; /* Espace fixe pour la navbar */
    max-width: 100vw;
}

@media (max-width: 768px) {
    body {
        padding-top: 55px !important;
    }
}

/* Arrière-plan spécial pour la page d'accueil */
body.home-page {
    background-image: url('../assets/SAO-Font.png');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    background-repeat: no-repeat;
}

body.home-page::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(10, 10, 26, 0.7);
    z-index: -1;
}

/* Écran de chargement supprimé - CSS nettoyé */

/* Éléments admin masqués par défaut */
.admin-only {
    display: none !important;
}

/* Styles globaux pour boutons et formulaires */
button, 
.btn,
input[type="button"],
input[type="submit"] {
    font-family: var(--font-title);
    border: 2px solid transparent;
    border-radius: 8px;
    background: linear-gradient(135deg, rgba(0, 168, 255, 0.8), rgba(138, 43, 226, 0.8));
    color: var(--color-white);
    padding: 12px 20px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 1px;
    font-weight: 600;
    font-size: 14px;
}

button:hover,
.btn:hover,
input[type="button"]:hover,
input[type="submit"]:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 168, 255, 0.4);
    border-color: rgba(0, 168, 255, 0.8);
}

button:focus,
.btn:focus,
input[type="button"]:focus,
input[type="submit"]:focus {
    outline: none;
    box-shadow: 0 0 15px rgba(0, 168, 255, 0.6);
}

select,
input[type="text"],
input[type="email"],
input[type="password"],
input[type="search"],
textarea {
    font-family: var(--font-title);
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.6), rgba(13, 25, 43, 0.6));
    border: 2px solid rgba(0, 168, 255, 0.3);
    border-radius: 8px;
    color: var(--color-white);
    padding: 12px 15px;
    transition: all 0.3s ease;
    font-size: 14px;
}

select:focus,
input[type="text"]:focus,
input[type="email"]:focus,
input[type="password"]:focus,
input[type="search"]:focus,
textarea:focus {
    outline: none;
    border-color: rgba(0, 168, 255, 0.8);
    box-shadow: 0 0 15px rgba(0, 168, 255, 0.3);
}

select option {
    background-color: var(--color-bg);
    color: var(--color-white);
}

/* Navigation stable - Version unifiée */
.nav-container {
    min-height: 60px;
    flex-wrap: nowrap;
    overflow: visible;
    width: 100%;
    box-sizing: border-box;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px; /* Espacement entre les 3 sections */
    padding: 0 20px;
}

/* Hamburger menu */
.hamburger {
    display: none !important;
    flex-direction: column;
    gap: 4px;
    cursor: pointer;
    padding: 8px;
    background: none;
    border: none;
    z-index: 1001;
}

@media (max-width: 768px) {
    .hamburger {
        display: flex !important;
    }
}

.hamburger span {
    width: 25px;
    height: 3px;
    background: #4ecdc4;
    border-radius: 2px;
    transition: all 0.3s ease;
    display: block;
}

.hamburger.active span:nth-child(1) {
    transform: rotate(45deg) translateY(10px);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
}

.hamburger.active span:nth-child(3) {
    transform: rotate(-45deg) translateY(-10px);
}

/* Navigation globale - style stable et centré */
body .nav-menu {
    display: flex !important;
    gap: 2rem;
    list-style: none;
    font-family: var(--font-title);
    margin: 0;
    padding: 0;
    justify-content: center;
    align-items: center;
    flex-shrink: 1; /* Peut rétrécir si nécessaire */
    position: static;
    order: 2; /* Élément central */
    flex: 0 1 auto; /* Ne prend que l'espace nécessaire */
}

/* Cacher le menu sur mobile par défaut */
@media (max-width: 768px) {
    body .nav-menu {
        display: none !important;
    }
    
    body .nav-menu.active {
        display: flex !important;
    }
}

body .nav-menu li {
    margin: 0;
    flex-shrink: 0;
}

body .nav-menu a {
    color: var(--color-white);
    text-decoration: none;
    font-family: var(--font-title);
    font-size: 1rem;
    font-weight: 400;
    position: relative;
    padding: 0.5rem 1rem; /* Padding horizontal pour éviter les chevauchements */
    /* SUPPRIMÉ: transition: color 0.3s ease; */
    display: block;
    white-space: nowrap;
    text-align: center;
    /* Stabiliser les dimensions */
    min-width: auto;
    box-sizing: border-box;
}

body .nav-menu a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--color-accent);
    /* SUPPRIMÉ: transition: width 0.3s ease; */
}

body .nav-menu a:hover::after,
body .nav-menu a.active::after {
    width: 100%;
}

body .nav-menu a:hover {
    color: var(--color-accent);
}

body .nav-menu a.active {
    color: var(--color-accent);
}

/* Logo et bouton connexion - positionnement flexbox stable */
body .nav-logo-container {
    flex-shrink: 0; /* Ne pas rétrécir */
    width: 150px; /* Largeur fixe */
    order: 1; /* Premier élément */
}

body .nav-logo-safe {
    height: 40px;
    width: auto;
    max-height: 40px;
    object-fit: contain;
    display: block;
}

body .nav-connexion {
    flex-shrink: 0; /* Ne pas rétrécir */
    width: auto; /* Largeur automatique basée sur le contenu */
    min-width: 300px; /* Largeur minimale */
    white-space: nowrap;
    order: 3; /* Dernier élément */
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 20px; /* Espace entre les boutons */
    /* Anti-déplacement stabilisation */
    position: relative;
}

body .nav-connexion .connexion-link,
body .nav-connexion .nav-link {
    padding: 0.5rem 1rem !important;
    background: rgba(0, 168, 255, 0.1) !important;
    border: 1px solid var(--color-accent) !important;
    border-radius: 8px !important;
    /* SUPPRIMÉ: transition: all 0.3s ease !important; */
    color: var(--color-white) !important;
    text-decoration: none !important;
    font-family: var(--font-title) !important;
    /* Anti-déplacement - stabilisation absolue */
    position: relative;
    will-change: auto;
    transform: none;
    contain: layout style;
    box-sizing: border-box;
    /* Empêche tout changement de layout */
    min-height: 40px;
    min-width: 100px;
}

/* Bouton connexion masqué par défaut - contrôlé par JavaScript */
body .nav-connexion .connexion-link,
body .nav-connexion .nav-link.connexion-link {
    display: none; /* Masqué par défaut, géré par JS */
}

/* Info utilisateur masquée par défaut - contrôlée par JavaScript */
body .nav-connexion .user-info {
    display: none; /* Masqué par défaut, géré par JS */
    align-items: center;
    gap: 30px;
    flex-shrink: 0;
}

/* ===== PROFIL - Style cyan ===== */
body .nav-connexion a[href*="profil"] {
    background: linear-gradient(135deg, #4ecdc4, #44a3ff);
    border: 2px solid rgba(78, 205, 196, 0.5);
    color: white;
    box-shadow: 0 2px 10px rgba(78, 205, 196, 0.3);
}

body .nav-connexion a[href*="profil"]:hover {
    background: linear-gradient(135deg, #5ed9d1, #55b0ff);
    border-color: #4ecdc4;
    box-shadow: 0 4px 15px rgba(78, 205, 196, 0.5);
    transform: translateY(-2px);
}

/* Lien actif (page courante) */
body .nav-connexion a.active[href*="admin-dashboard"] {
    background: linear-gradient(135deg, #ff6b35, #fa709a) !important;
    color: white !important;
    border-color: #ff6b35 !important;
    box-shadow: 0 4px 20px rgba(255, 107, 53, 0.5) !important;
}

body .nav-connexion a.active[href*="profil"] {
    background: linear-gradient(135deg, #4ecdc4, #44a3ff) !important;
    color: white !important;
    border-color: #4ecdc4 !important;
    box-shadow: 0 4px 20px rgba(78, 205, 196, 0.5) !important;
}

/* Style pour le nom d'utilisateur cliquable */
.username-link {
    color: #4ecdc4;
    text-decoration: none;
    font-weight: 500;
    padding: 8px 15px;
    border-radius: 8px;
    transition: all 0.3s ease;
    display: inline-block;
}

.username-link:hover {
    background: rgba(78, 205, 196, 0.1);
    color: #5ed9d1;
    transform: translateY(-1px);
}

body .nav-connexion .connexion-link:hover,
body .nav-connexion .nav-link:hover {
    background: var(--color-accent) !important;
    color: var(--color-white) !important;
    /* Anti-déplacement sur hover */
    transform: none !important;
    will-change: auto !important;
    /* Empêche tout changement de dimensions */
    padding: 0.5rem 1rem !important;
    border: 1px solid var(--color-accent) !important;
    box-sizing: border-box !important;
}

/* Anti-déplacement général pour tous les éléments cliquables */
body .nav-connexion * {
    will-change: auto;
    transform: translateZ(0);
    backface-visibility: hidden;
}

/* Stabilisation des boutons de déconnexion */
body .nav-connexion .logout-btn {
    will-change: auto;
    transform: none;
    contain: layout style;
    box-sizing: border-box;
}

/* Menu hamburger amélioré */
.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    background: none;
    border: none;
    padding: 0.5rem;
    position: relative;
    z-index: 101;
    width: 30px;
    height: 30px;
    justify-content: center;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background: var(--color-white);
    margin: 2px 0;
    /* SUPPRIMÉ: transition: all 0.3s ease; */
    border-radius: 2px;
    /* SUPPRIMÉ: transform-origin: center; */
}

/* Animation du hamburger actif */
.hamburger.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
    transform: translateX(-20px);
}

.hamburger.active span:nth-child(3) {
    transform: rotate(-45deg) translate(7px, -6px);
}

/* Header et Navigation - Version améliorée pour mobile */
.header {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    z-index: 100 !important;
    background: linear-gradient(to bottom, rgba(10, 10, 26, 0.95), rgba(10, 10, 26, 0.85)) !important;
    backdrop-filter: blur(15px) !important;
    padding: 1rem 0 !important;
    margin: 0 !important;
    border-bottom: 1px solid rgba(0, 168, 255, 0.2) !important;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3) !important;
    min-height: 60px !important;
}

/* Auto-hide navbar on scroll down (mobile only) */
.header.hidden {
    transform: translateY(-100%);
}

.nav-container {
    max-width: 1200px !important;
    margin: 0 auto !important;
    padding: 0 2rem !important;
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    position: relative !important;
    
    /* Stabilisation supplémentaire */
    box-sizing: border-box !important;
    min-height: 60px !important;
    will-change: auto !important;
}

.nav-logo {
    height: 40px;
    width: auto;
}

.nav-logo-safe {
    height: 40px !important;
    width: auto !important;
    max-height: 40px !important;
    max-width: 200px !important;
    z-index: 2 !important;
}

/* === STABILISATION ANTI-DÉPLACEMENT === */
/* Empêcher tous les déplacements lors des clics/hover */
.nav-menu,
.nav-connexion,
.nav-link,
.connexion-link,
.nav-menu a,
.nav-connexion a,
.nav-connexion button {
    /* Empêcher les déplacements lors des interactions */
    will-change: auto !important;
    transform: none !important;
    backface-visibility: hidden !important;
    -webkit-backface-visibility: hidden !important;
    
    /* Maintenir la position stable */
    position: relative !important;
    
    /* Désactiver les transitions perturbantes */
    transition: color 0.2s ease !important;
}

/* Hover effects SANS déplacement */
.nav-link:hover,
.connexion-link:hover,
.nav-menu a:hover {
    /* Seulement changer la couleur/fond, jamais la position */
    color: var(--color-accent) !important;
    background-color: rgba(0, 168, 255, 0.1) !important;
    
    /* Forcer aucun déplacement */
    transform: none !important;
    will-change: auto !important;
}

/* États focus/active SANS déplacement */
.nav-link:focus,
.connexion-link:focus,
.nav-link:active,
.connexion-link:active,
.nav-menu a:focus,
.nav-menu a:active {
    transform: none !important;
    will-change: auto !important;
    outline: 1px solid var(--color-accent) !important;
    outline-offset: 2px !important;
}

/* === FIN STABILISATION === */

.nav-menu {
    display: flex;
    gap: 2rem;
    list-style: none;
    justify-content: center;
    align-items: center;
    margin: 0;
    padding: 0;
}

.nav-connexion {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.nav-link {
    color: var(--color-white);
    text-decoration: none;
    font-family: var(--font-title);
    font-size: 1rem;
    position: relative;
    padding: 0.5rem 1rem;
    border-radius: 6px;
    transition: all 0.3s ease;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--color-accent);
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}

/* Section Héros */
.hero {
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    padding-top: 60px;
}

.hero-content {
    text-align: center;
    z-index: 1;
    max-width: 900px;
    padding: 0 20px;
}

.hero-title {
    font-family: var(--font-title);
    font-size: 4rem;
    margin-bottom: 1rem;
    background: linear-gradient(135deg, var(--color-white), var(--color-accent));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 0 0 40px rgba(0, 168, 255, 0.5);
}

.hero-subtitle {
    font-size: 1.8rem;
    margin-bottom: 1rem;
    color: var(--color-cyan);
    font-weight: 600;
}

.hero-description {
    font-size: 1.2rem;
    margin-bottom: 2.5rem;
    color: rgba(255, 255, 255, 0.8);
    line-height: 1.6;
}

.hero-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap;
}

.hero-button {
    display: inline-block;
    padding: 1rem 2.5rem;
    font-family: var(--font-title);
    font-size: 1.1rem;
    text-decoration: none;
    border-radius: 8px;
    transition: all 0.3s ease;
    font-weight: 600;
}

.hero-button.primary {
    background: linear-gradient(135deg, var(--color-accent), var(--color-purple));
    color: var(--color-white);
    border: none;
    box-shadow: 0 4px 15px rgba(0, 168, 255, 0.4);
}

.hero-button.primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 25px rgba(0, 168, 255, 0.6);
}

.hero-button.secondary {
    background: transparent;
    border: 2px solid var(--color-accent);
    color: var(--color-accent);
}

.hero-button.secondary:hover {
    background: rgba(0, 168, 255, 0.1);
    border-color: var(--color-cyan);
    color: var(--color-cyan);
}

/* Container générique */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Section Statistiques */
.stats-section {
    padding: 80px 0;
    background: linear-gradient(180deg, rgba(0, 0, 0, 0) 0%, rgba(0, 168, 255, 0.05) 100%);
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.stat-card {
    background: linear-gradient(135deg, rgba(0, 168, 255, 0.1), rgba(138, 43, 226, 0.1));
    border: 1px solid rgba(0, 168, 255, 0.3);
    border-radius: 15px;
    padding: 40px 20px;
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 168, 255, 0.3);
}

.stat-number {
    font-family: var(--font-title);
    font-size: 3rem;
    color: var(--color-accent);
    font-weight: bold;
    display: block;
    margin-bottom: 10px;
    text-shadow: 0 0 20px rgba(0, 168, 255, 0.5);
}

.stat-label {
    font-size: 1.1rem;
    color: rgba(255, 255, 255, 0.9);
}

/* Section Titre */
.section-title {
    font-family: var(--font-title);
    font-size: 2.5rem;
    text-align: center;
    margin-bottom: 50px;
    background: linear-gradient(135deg, var(--color-white), var(--color-accent));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

/* Section Vidéo */
.video-section {
    padding: 80px 0;
    background: rgba(0, 0, 0, 0.3);
}

.video-container {
    max-width: 900px;
    margin: 0 auto;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 10px 40px rgba(0, 168, 255, 0.3);
}

.video-wrapper {
    position: relative;
    padding-bottom: 56.25%;
    height: 0;
    overflow: hidden;
}

.video-wrapper iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

/* Section Fonctionnalités */
.features-section {
    padding: 80px 0;
    background: linear-gradient(180deg, rgba(0, 0, 0, 0) 0%, rgba(138, 43, 226, 0.05) 100%);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.feature-card {
    background: linear-gradient(135deg, rgba(0, 0, 0, 0.6), rgba(13, 25, 43, 0.8));
    border: 1px solid rgba(0, 168, 255, 0.2);
    border-radius: 15px;
    padding: 40px 30px;
    text-align: center;
    transition: all 0.3s ease;
}

.feature-card:hover {
    transform: translateY(-5px);
    border-color: rgba(0, 168, 255, 0.5);
    box-shadow: 0 10px 30px rgba(0, 168, 255, 0.2);
}

.feature-icon {
    font-size: 4rem;
    margin-bottom: 20px;
    filter: drop-shadow(0 0 10px rgba(0, 168, 255, 0.5));
}

.feature-card h3 {
    font-family: var(--font-title);
    color: var(--color-accent);
    margin-bottom: 15px;
    font-size: 1.5rem;
}

.feature-card p {
    color: rgba(255, 255, 255, 0.8);
    line-height: 1.6;
    margin-bottom: 20px;
}

.feature-link {
    color: var(--color-cyan);
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s ease;
}

.feature-link:hover {
    color: var(--color-accent);
}

/* Section Call-to-Action */
.cta-section {
    padding: 100px 0;
    text-align: center;
    background: linear-gradient(135deg, rgba(0, 168, 255, 0.1), rgba(138, 43, 226, 0.1));
    border-top: 1px solid rgba(0, 168, 255, 0.3);
    border-bottom: 1px solid rgba(0, 168, 255, 0.3);
}

.cta-section h2 {
    font-family: var(--font-title);
    font-size: 2.5rem;
    margin-bottom: 20px;
    color: var(--color-white);
}

.cta-section p {
    font-size: 1.3rem;
    margin-bottom: 40px;
    color: rgba(255, 255, 255, 0.8);
}

.cta-button {
    display: inline-block;
    padding: 1.2rem 3rem;
    background: linear-gradient(135deg, var(--color-accent), var(--color-purple));
    color: var(--color-white);
    text-decoration: none;
    font-family: var(--font-title);
    font-size: 1.2rem;
    font-weight: 600;
    border-radius: 50px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 20px rgba(0, 168, 255, 0.4);
}

.cta-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 30px rgba(0, 168, 255, 0.6);
}





/* ===== MEDIA QUERIES - RESPONSIVE DESIGN ===== */

/* Tablettes et écrans moyens */
@media (max-width: 1024px) {
    .nav-container {
        padding: 0 1rem;
    }
    
    .hero-title {
        font-size: 3rem;
    }
    
    .hero-subtitle {
        font-size: 1.5rem;
    }
    
    .hero-description {
        font-size: 1.1rem;
    }
    
    .hero-content {
        padding: 0 1rem;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .features-grid {
        grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    }
}

/* Tablettes en mode portrait */
@media (max-width: 768px) {
    .header {
        padding: 0 !important;
        min-height: 60px !important;
        display: block !important;
        visibility: visible !important;
        background: #0a0a1a !important;
    }
    
    .nav-container {
        padding: 8px 10px !important;
        min-height: 60px !important;
        display: grid !important;
        grid-template-columns: 70px 1fr auto auto !important;
        grid-template-areas: "logo menu connexion hamburger" !important;
        align-items: center !important;
        gap: 8px !important;
    }
    
    .nav-logo-container {
        grid-area: logo !important;
        width: 70px !important;
        flex-shrink: 0 !important;
    }
    
    .nav-logo-safe {
        height: 35px !important;
        width: auto !important;
        max-width: 70px !important;
        display: block !important;
    }
    
    /* CACHER LE MENU DESKTOP SUR MOBILE */
    body .nav-menu {
        display: none !important;
        grid-area: menu !important;
    }
    
    .nav-connexion {
        grid-area: connexion !important;
        font-size: 0.7rem !important;
        white-space: nowrap !important;
        min-width: 0 !important;
        max-width: none !important;
        flex-shrink: 1 !important;
    }
    
    /* Gestion de la visibilité connexion/user-info sur mobile */
    .nav-connexion .connexion-link {
        font-size: 0.7rem !important;
        padding: 6px 10px !important;
        display: inline-block !important;
        background: rgba(78, 205, 196, 0.2) !important;
        border: 1px solid #4ecdc4 !important;
        border-radius: 5px !important;
        color: #4ecdc4 !important;
    }
    
    /* Cacher le bouton connexion quand l'utilisateur est connecté */
    .nav-connexion .connexion-link[style*="display: none"],
    .nav-connexion .connexion-link:not(.show):not(.js-visible) {
        display: none !important;
    }
    
    /* Afficher les infos utilisateur quand connecté */
    .nav-connexion .user-info {
        display: none !important;
    }
    
    .nav-connexion .user-info.show,
    .nav-connexion .user-info.js-visible,
    .nav-connexion .user-info[style*="display: flex"] {
        display: flex !important;
        flex-direction: row !important;
        gap: 8px !important;
        align-items: center !important;
    }
    
    .nav-connexion .username-link {
        font-size: 0.7rem !important;
        padding: 6px 10px !important;
        display: inline-block !important;
        background: rgba(78, 205, 196, 0.2) !important;
        border: 1px solid #4ecdc4 !important;
        border-radius: 5px !important;
        color: #4ecdc4 !important;
    }
    
    .nav-connexion .logout-btn {
        font-size: 0.65rem !important;
        padding: 4px 8px !important;
    }
    
    /* HAMBURGER ULTRA VISIBLE */
    .hamburger {
        grid-area: hamburger !important;
        display: flex !important;
        flex-direction: column !important;
        justify-content: center !important;
        align-items: center !important;
        width: 45px !important;
        height: 45px !important;
        background: rgba(78, 205, 196, 0.2) !important;
        border: 2px solid #4ecdc4 !important;
        border-radius: 8px !important;
        padding: 8px !important;
        gap: 5px !important;
        flex-shrink: 0 !important;
    }
    
    .hamburger span {
        width: 25px !important;
        height: 3px !important;
        background: #4ecdc4 !important;
        display: block !important;
        border-radius: 2px !important;
    }
    
    .hamburger span {
        width: 25px !important;
        height: 3px !important;
        background: #4ecdc4 !important;
        display: block !important;
        border-radius: 2px !important;
    }
    
    /* MENU MOBILE FULL SCREEN */
    body .nav-menu.active {
        display: flex !important;
        position: fixed !important;
        top: 60px !important;
        left: 0 !important;
        width: 100% !important;
        height: calc(100vh - 60px) !important;
        background: rgba(10, 10, 26, 0.98) !important;
        backdrop-filter: blur(20px) !important;
        padding: 2rem 1rem !important;
        flex-direction: column !important;
        align-items: center !important;
        justify-content: flex-start !important;
        gap: 1rem !important;
        z-index: 9999 !important;
        margin: 0 !important;
        list-style: none !important;
        border-top: 2px solid #4ecdc4 !important;
        transform: none !important;
        animation: slideIn 0.3s ease !important;
        pointer-events: auto !important;
    }
    
    @keyframes slideIn {
        from {
            opacity: 0;
            transform: translateY(-20px);
        }
        to {
            opacity: 1;
            transform: translateY(0);
        }
    }
    
    body .nav-menu.active li {
        width: 100%;
        max-width: 400px;
    }
    
    body .nav-menu.active a {
        display: block;
        width: 100%;
        padding: 15px 20px !important;
        background: rgba(78, 205, 196, 0.15) !important;
        border: 2px solid #4ecdc4 !important;
        border-radius: 10px !important;
        color: #4ecdc4 !important;
        font-size: 1.1rem !important;
        text-align: center !important;
        text-decoration: none !important;
        font-weight: 600 !important;
        transition: all 0.3s ease !important;
    }
    
    body .nav-menu.active a:hover,
    body .nav-menu.active a.active {
        background: rgba(78, 205, 196, 0.3) !important;
        transform: scale(1.02) !important;
    }
}
    
    /* Overlay pour fermer le menu */
    .nav-overlay {
        display: none !important;
        position: fixed;
        top: 55px;
        left: 0;
        width: 100%;
        height: calc(100vh - 55px);
        background: rgba(0, 0, 0, 0.5);
        z-index: 998;
        backdrop-filter: blur(2px);
        opacity: 0;
        transition: opacity 0.3s ease;
        pointer-events: none !important;
    }
    
    .nav-overlay.active {
        display: none !important;
        opacity: 1;
        pointer-events: none !important;
    }

/* Smartphones */
@media (max-width: 480px) {
    .header {
        min-height: 55px !important;
    }
    
    .nav-container {
        padding: 5px 8px !important;
        min-height: 55px !important;
        grid-template-columns: 60px 1fr auto auto !important;
        gap: 5px !important;
    }
    
    .nav-logo-container {
        width: 60px !important;
    }
    
    .nav-logo-safe {
        height: 30px !important;
        max-width: 60px !important;
    }
    
    .nav-connexion {
        font-size: 0.65rem !important;
    }
    
    .nav-connexion .user-info {
        flex-direction: row !important;
        gap: 5px !important;
    }
    
    .nav-connexion .connexion-link,
    .nav-connexion .username-link {
        font-size: 0.65rem !important;
        padding: 5px 8px !important;
    }
    
    .nav-connexion .logout-btn {
        font-size: 0.6rem !important;
        padding: 3px 6px !important;
    }
    
    .hamburger {
        width: 40px !important;
        height: 40px !important;
        padding: 6px !important;
    }
    
    .hamburger span {
        width: 22px !important;
        height: 2.5px !important;
    }
    
    body .nav-menu.active {
        top: 55px !important;
        height: calc(100vh - 55px) !important;
        padding: 1.5rem 1rem !important;
    }
    
    body .nav-menu.active a {
        padding: 12px 15px !important;
        font-size: 1rem !important;
    }
}
    
    .nav-overlay {
        top: 50px;
        height: calc(100vh - 50px);
    }
}

/* Très petits écrans */
@media (max-width: 320px) {
    .nav-container {
        padding: 4px 5px !important;
        grid-template-columns: 50px 1fr auto auto !important;
        gap: 4px !important;
    }
    
    .nav-logo-container {
        width: 50px !important;
    }
    
    .nav-logo-safe {
        height: 26px !important;
        max-width: 50px !important;
    }
    
    .nav-connexion .connexion-link,
    .nav-connexion .username-link {
        font-size: 0.6rem !important;
        padding: 4px 6px !important;
    }
    
    .hamburger {
        width: 35px !important;
        height: 35px !important;
        padding: 5px !important;
    }
    
    .hamburger span {
        width: 20px !important;
        height: 2px !important;
    }
    
    .hero-title {
        font-size: 1.8rem;
    }
    
    .hero-subtitle {
        font-size: 0.9rem;
    }
}

/* Styles d'authentification dans la navigation */
.user-info {
    display: flex;
    align-items: center;
    gap: 1rem;
    color: var(--color-white);
    font-size: 0.9rem;
}

.logout-btn {
    background: rgba(244, 67, 54, 0.2);
    border: 1px solid rgba(244, 67, 54, 0.5);
    color: #F44336;
    padding: 0.4rem 0.8rem;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 0.8rem;
    font-family: var(--font-text);
}

.logout-btn:hover {
    background: rgba(244, 67, 54, 0.3);
    transform: translateY(-1px);
}

@media (max-width: 768px) {
    .user-info {
        flex-direction: column;
        gap: 0.5rem;
        text-align: center;
    }
    
    .logout-btn {
        padding: 0.3rem 0.6rem;
    }
}
