/* ═══════════════════════════════════════════════
   NAVIGATION — AC-CRÉATION
   Structure : Plateforme | Métiers | Ressources | Tarifs | CTA
   ═══════════════════════════════════════════════ */

nav {
    position: fixed; top: 0; left: 0; right: 0;
    z-index: 100; padding: 16px 0;
    transition: all 0.35s ease; background: transparent;
}
nav.scrolled {
    background: rgba(4, 8, 15, 0.95);
    backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
    padding: 10px 0;
    border-bottom: 1px solid rgba(139, 92, 246, 0.08);
}
.nav-inner {
    max-width: 1200px; margin: 0 auto; padding: 0 32px;
    display: flex; align-items: center; justify-content: space-between;
}

/* ── Logo ── */
.nav-logo { display: flex; align-items: center; gap: 12px; text-decoration: none; z-index: 160; position: relative; }
.nav-logo-mark {
    width: 40px; height: 40px; border-radius: 12px;
    background: linear-gradient(135deg, #7c3aed, #06b6d4);
    display: flex; align-items: center; justify-content: center;
    font-family: 'Space Grotesk', sans-serif; font-weight: 700; font-size: 16px; color: white;
}
.nav-logo-text { font-family: 'Space Grotesk', sans-serif; font-weight: 600; font-size: 1.1rem; color: white; }

/* ── Desktop nav links ── */
.nav-links { display: flex; align-items: center; gap: 4px; }
.nav-link-item {
    color: #94a3b8; text-decoration: none; font-size: 0.9rem; font-weight: 500;
    padding: 8px 16px; border-radius: 8px; transition: all 0.2s ease;
}
.nav-link-item:hover { color: white; background: rgba(255,255,255,0.05); }

/* ── CTA ── */
.nav-cta {
    background: linear-gradient(135deg, #7c3aed, #8b5cf6) !important;
    color: white !important; padding: 10px 20px !important;
    border-radius: 10px !important; font-weight: 600 !important;
    font-size: 0.85rem !important; margin-left: 8px;
    transition: all 0.3s ease !important; text-decoration: none !important;
}
.nav-cta:hover { transform: translateY(-1px); box-shadow: 0 4px 20px rgba(124, 58, 237, 0.4); }

/* ════════════════════════════════════════
   DETAILS / SUMMARY DROPDOWNS
   ════════════════════════════════════════ */
.nav-details { position: relative; }
.nav-summary {
    list-style: none; cursor: pointer; color: #94a3b8;
    font-size: 0.9rem; font-weight: 500; padding: 8px 14px;
    border-radius: 8px; transition: all 0.2s ease;
    display: flex; align-items: center; gap: 5px;
    user-select: none; -webkit-user-select: none;
}
.nav-summary::-webkit-details-marker { display: none; }
.nav-summary::marker { display: none; content: ''; }
.nav-summary:hover { color: white; background: rgba(255,255,255,0.05); }
.nav-summary .chevron-down { font-size: 0.55rem; transition: transform 0.3s ease; opacity: 0.6; }
.nav-details[open] > .nav-summary .chevron-down { transform: rotate(180deg); }
.nav-details[open] > .nav-summary { color: white; }

/* ── Desktop dropdown panel ── */
.nav-dropdown-list {
    position: absolute; top: calc(100% + 8px); left: 50%; transform: translateX(-50%);
    background: rgba(10, 15, 30, 0.97);
    backdrop-filter: blur(30px); -webkit-backdrop-filter: blur(30px);
    border: 1px solid rgba(139, 92, 246, 0.12);
    border-radius: 16px; padding: 10px;
    min-width: 300px; box-shadow: 0 20px 60px rgba(0,0,0,0.5);
    z-index: 200; display: flex; flex-direction: column; gap: 2px;
    animation: ddFade 0.2s ease;
}
@keyframes ddFade {
    from { opacity: 0; transform: translateX(-50%) translateY(-8px); }
    to   { opacity: 1; transform: translateX(-50%) translateY(0); }
}

/* Lien avec description (Plateforme, Ressources) */
.nav-drop-link {
    display: flex; align-items: center; gap: 12px;
    padding: 12px 14px; color: #cbd5e1; text-decoration: none;
    border-radius: 12px; transition: all 0.15s ease;
}
.nav-drop-link:hover { background: rgba(139, 92, 246, 0.1); color: white; }
.nav-drop-link strong { display: block; font-size: 0.9rem; font-weight: 600; color: #e2e8f0; }
.nav-drop-link small { display: block; font-size: 0.75rem; color: #64748b; margin-top: 2px; }
.nav-drop-link:hover strong { color: white; }
.nav-drop-icon { font-size: 1.2rem; width: 28px; text-align: center; flex-shrink: 0; }

/* Lien compact (Métiers) */
.nav-drop-link-sm {
    display: flex; align-items: center; gap: 8px;
    padding: 9px 14px; color: #cbd5e1; text-decoration: none;
    font-size: 0.88rem; font-weight: 500;
    border-radius: 10px; transition: all 0.15s ease; white-space: nowrap;
}
.nav-drop-link-sm:hover { color: white; background: rgba(139, 92, 246, 0.1); }

/* Métiers dropdown = grille 3 colonnes sur desktop */
.nav-dropdown-metiers {
    min-width: 420px;
    display: grid !important; grid-template-columns: repeat(3, 1fr); gap: 2px;
}

/* ── Hamburger ── */
.mobile-toggle {
    display: none; flex-direction: column; align-items: center; justify-content: center;
    gap: 5px; background: none; border: none; color: white;
    cursor: pointer; padding: 8px; z-index: 160; position: relative;
}
.mobile-toggle span { display: block; width: 22px; height: 2px; background: white; transition: all 0.3s ease; border-radius: 2px; }
.mobile-toggle.active span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.mobile-toggle.active span:nth-child(2) { opacity: 0; }
.mobile-toggle.active span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }

/* ── Overlay ── */
.nav-overlay {
    display: none; position: fixed; top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0, 0, 0, 0.25); z-index: 99;
}
.nav-overlay.active { display: block; }

/* ════════════════════════════════════════
   MOBILE — max-width: 968px
   ════════════════════════════════════════ */
@media (max-width: 968px) {
    .mobile-toggle { display: flex; }

    .nav-links {
        position: fixed; top: 0; right: 0;
        width: 88%; max-width: 420px; height: 100vh; height: 100dvh;
        background: rgba(4, 8, 15, 0.98);
        backdrop-filter: blur(30px); -webkit-backdrop-filter: blur(30px);
        flex-direction: column; align-items: stretch;
        padding: 90px 24px 40px; gap: 0; z-index: 150;
        border-left: 1px solid rgba(139, 92, 246, 0.12);
        box-shadow: -4px 0 30px rgba(0,0,0,0.4);
        transform: translateX(100%);
        transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        overflow-y: auto;
    }
    .nav-links.active { transform: translateX(0); }

    /* Lien direct mobile */
    .nav-link-item {
        display: block; width: 100%; padding: 15px 4px;
        border-bottom: 1px solid rgba(255,255,255,0.06);
        border-radius: 0; font-size: 1rem; color: #e2e8f0; text-align: left;
    }
    .nav-link-item:hover { background: none; }

    /* Details/Summary mobile */
    .nav-details { border-bottom: 1px solid rgba(255,255,255,0.06); }
    .nav-summary { padding: 15px 4px; font-size: 1rem; color: #e2e8f0; border-radius: 0; }
    .nav-summary:hover { background: none; }

    /* Dropdown inline (pas absolute) */
    .nav-dropdown-list {
        position: static !important; transform: none !important;
        margin: 0 0 8px 0; background: rgba(139, 92, 246, 0.05);
        border: none; border-radius: 12px; padding: 8px;
        min-width: unset !important; box-shadow: none; animation: none;
    }
    .nav-dropdown-metiers {
        display: flex !important; flex-direction: column; gap: 2px;
    }
    .nav-drop-link { padding: 10px 12px; border-radius: 8px; }
    .nav-drop-link-sm { padding: 11px 12px; font-size: 0.95rem; border-radius: 8px; }
    .nav-drop-link strong { font-size: 0.95rem; }
    .nav-drop-link small { font-size: 0.78rem; }

    /* CTA mobile */
    .nav-cta {
        margin-top: 16px !important; margin-left: 0 !important;
        display: flex !important; justify-content: center !important;
        padding: 14px 24px !important; font-size: 0.95rem !important;
        border-radius: 12px !important; border-bottom: none !important;
        box-shadow: 0 4px 20px rgba(124, 58, 237, 0.3) !important;
    }
}

@media (max-width: 480px) {
    .nav-links { width: 100%; max-width: 100%; padding: 85px 18px 40px; }
}

/* ── NAV-TOGGLE (compatibilité) ── */
.nav-toggle {
    display: none; flex-direction: column; align-items: center; justify-content: center;
    gap: 5px; background: none; border: none; color: white;
    cursor: pointer; padding: 8px; z-index: 160; position: relative;
}
.nav-toggle span { display: block; width: 22px; height: 2px; background: white; transition: all 0.3s ease; border-radius: 2px; }
.nav-toggle.active span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.nav-toggle.active span:nth-child(2) { opacity: 0; }
.nav-toggle.active span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }

/* Nav overlay (compatibilité) */
.nav-mobile-overlay {
    display: none; position: fixed; top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0, 0, 0, 0.25); z-index: 99;
}
.nav-mobile-overlay.active { display: block; }

@media (max-width: 968px) {
    .nav-toggle { display: flex; }
}

