/* Design System Variables */
:root {
    --bg-main: #080D1A;
    --bg-cards: #0F1629;
    --bg-sections-alt: #0C1322;
    --accent-blue: #0099FF;
    --accent-green: #00C27C;
    --text-primary: #F0F4FF;
    --text-secondary: #8A9CC2;
    --border-glass: rgba(0, 153, 255, 0.18);
    --glow-blue: rgba(0, 153, 255, 0.12);
    --glow-green: rgba(0, 194, 124, 0.12);
    --font-titles: 'Plus Jakarta Sans', sans-serif;
    --font-body: 'Inter', sans-serif;
}

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

body {
    background-color: var(--bg-main) !important;
    color: var(--text-primary);
    font-family: var(--font-body);
    line-height: 1.75;
    overflow-x: hidden;
    width: 100%;
    min-height: 100vh;
}

h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-titles);
    font-weight: 800;
}

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

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

ul {
    list-style: none;
}

/* Logos */
.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    font-family: var(--font-titles);
    font-size: 1.4rem;
    font-weight: 800;
    color: var(--text-primary);
}

.logo img {
    height: 32px;
    width: auto;
    transition: transform 0.3s ease;
}

.logo:hover img {
    transform: rotate(-5deg) scale(1.1);
}

/* Layout */
#main-header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    padding: 20px 0;
    border-bottom: 1px solid var(--border-glass);
    transition: all 0.4s ease;
    background: transparent;
}

.navbar-scrolled {
    background: rgba(8, 13, 26, 0.8) !important;
    backdrop-filter: blur(16px);
    padding: 12px 0 !important;
    border-bottom: 1px solid rgba(0, 153, 255, 0.3);
}

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

.nav-links {
    display: flex;
    gap: 30px;
}

.nav-links a {
    font-weight: 500;
    font-size: 0.95rem;
}

.nav-links a:hover, .nav-links a.active {
    color: var(--accent-blue);
}

.nav-cta {
    display: block;
}

    /* Burger Menu Styles */
    .burger {
        display: none;
        flex-direction: column;
        justify-content: space-between;
        width: 30px;
        height: 20px;
        background: transparent !important;
        border: none !important;
        outline: none !important;
        cursor: pointer;
        padding: 0;
        z-index: 2005;
        position: relative;
    }

.burger div {
    width: 100%;
    height: 3px;
    background-color: #FFFFFF !important;
    border-radius: 2px;
    transition: all 0.3s ease;
    display: block;
    box-shadow: 0 0 8px rgba(255, 255, 255, 0.8) !important;
}

/* Animation vers la croix */
.burger-active div:nth-child(1) {
    transform: translateY(8.5px) rotate(45deg) !important;
}

.burger-active div:nth-child(2) {
    opacity: 0 !important;
}

.burger-active div:nth-child(3) {
    transform: translateY(-8.5px) rotate(-45deg) !important;
}

@media (max-width: 992px) {
    .nav-links {
        display: none;
    }

    .nav-links-mobile {
        display: flex !important;
        position: fixed;
        top: 0;
        right: 0;
        height: 100vh;
        width: 100%;
        background: var(--bg-main) !important;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 40px;
        z-index: 1050;
        animation: fadeIn 0.3s ease;
    }

    .nav-links-mobile a {
        font-size: 1.5rem;
        font-family: var(--font-titles);
        color: white !important;
    }

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

    .burger {
        display: flex !important;
        flex-direction: column !important;
        justify-content: space-between !important;
        width: 30px !important;
        height: 20px !important;
        background: transparent !important;
        border: none !important;
        cursor: pointer !important;
        padding: 0 !important;
        z-index: 2005 !important;
        position: relative !important;
        visibility: visible !important;
        opacity: 1 !important;
    }

    .burger div {
        display: block !important;
        width: 100% !important;
        height: 3px !important;
        background-color: #FFFFFF !important;
        border-radius: 2px !important;
        transition: all 0.3s ease !important;
        box-shadow: 0 0 8px rgba(255, 255, 255, 0.8) !important;
    }

    .nav-cta {
        display: none;
    }

    .nav-links-mobile .nav-cta-mobile {
        display: block !important;
    }

    main {
        padding-top: 80px; /* Éviter que le contenu soit caché sous la navbar fixe */
    }
}

/* Footer Responsive */
@media (max-width: 768px) {
    .footer-grid {
        grid-template-columns: 1fr !important;
        gap: 40px !important;
        text-align: center;
    }

    .footer-brand .logo {
        justify-content: center;
    }

    .footer-brand p {
        margin: 20px auto;
        max-width: 300px;
    }

    .footer-links h3, .footer-legal h3 {
        margin-bottom: 20px;
    }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.btn {
    padding: 10px 20px;
    border-radius: 50px;
    font-weight: 700;
    display: inline-block;
}

.btn-green {
    background-color: var(--accent-green);
    color: white;
}

/* Animations */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: 0.7s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.reveal.active {
    opacity: 1 !important;
    transform: translateY(0) !important;
}

/* ===== Fond constellation global (tout le site) =====
   Le canvas est un calque fixe en fond, dessiné par assets/js/animations.js.
   Il est peint au-dessus du fond sombre du <body> mais sous tout le contenu. */
#particles-canvas {
    position: fixed;
    inset: 0;
    width: 100vw;
    height: 100vh;
    z-index: 0;
    pointer-events: none;
}

/* Le contenu passe au-dessus du canvas (le header #main-header est déjà en z-index 1000). */
main,
#main-footer {
    position: relative;
    z-index: 1;
}

/* Le footer devient transparent pour laisser voir la constellation (sa bordure haute suffit à le séparer). */
#main-footer {
    background: transparent;
}
