/* ═══════════════════════════════════════════
   DROPDOWN NAV
═══════════════════════════════════════════ */
.nav-dropdown { position: relative; }

.nav-dropdown-menu {
    position: absolute;
    top: calc(100% + 12px);
    left: 50%;
    transform: translateX(-50%) translateY(-6px);
    opacity: 0;
    pointer-events: none;
    visibility: hidden;
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 1rem;
    padding: 0.5rem;
    min-width: 200px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.08);
    z-index: 100;
    transition: opacity 0.18s ease, transform 0.18s ease, visibility 0.18s ease;
}

/* Pont invisible pour couvrir le gap entre bouton et menu */
.nav-dropdown-menu::before {
    content: '';
    position: absolute;
    top: -14px;
    left: 0;
    right: 0;
    height: 14px;
    background: transparent;
}

.nav-dropdown.open .nav-dropdown-menu {
    opacity: 1;
    pointer-events: all;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

.nav-dropdown-menu a {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.55rem 0.85rem;
    border-radius: 0.6rem;
    font-size: 13px;
    font-weight: 600;
    color: #475569;
    text-decoration: none;
    transition: background 0.12s, color 0.12s;
}
.nav-dropdown-menu a:hover {
    background: #eef2ff;
    color: #4f46e5;
}
.nav-dropdown-menu a i {
    width: 16px;
    text-align: center;
    opacity: 0.7;
}
.nav-dropdown-menu .menu-divider {
    height: 1px;
    background: #f1f5f9;
    margin: 0.3rem 0.5rem;
}
.nav-dropdown > button {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 13px;
    font-weight: 700;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    cursor: pointer;
    background: none;
    border: none;
    padding: 0;
    transition: color 0.15s;
}
.nav-dropdown.open > button { color: #4f46e5; }
.nav-dropdown > button .chevron {
    font-size: 9px;
    transition: transform 0.18s;
    opacity: 0.6;
}
.nav-dropdown.open > button .chevron { transform: rotate(180deg); }

/* ═══════════════════════════════════════════
   SECTION DOCUMENTATION
═══════════════════════════════════════════ */
.doc-card {
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 1.5rem;
    padding: 1.75rem;
    transition: all 0.25s ease;
    cursor: pointer;
    text-decoration: none;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}
.doc-card:hover {
    border-color: #6366f1;
    box-shadow: 0 12px 30px rgba(99,102,241,0.1);
    transform: translateY(-3px);
}
.doc-card-icon {
    width: 44px;
    height: 44px;
    border-radius: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
}
.doc-terminal {
    background: #0f172a;
    border-radius: 1rem;
    padding: 1.25rem 1.5rem;
    font-family: 'Courier New', monospace;
    font-size: 13px;
    overflow: hidden;
}
.doc-terminal .line    { display: block; margin-bottom: 3px; }
.doc-terminal .prompt  { color: #6366f1; }
.doc-terminal .cmd     { color: #e2e8f0; }
.doc-terminal .comment { color: #475569; }
.doc-terminal .output  { color: #34d399; }
.doc-badge {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 3px 10px;
    border-radius: 999px;
    font-size: 10px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

/* Doc mini cards (homepage teaser) */
.doc-mini-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.45rem;
    padding: 0.875rem 0.5rem;
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 1rem;
    text-align: center;
    text-decoration: none;
    transition: all 0.2s;
    position: relative;
}
.doc-mini-card:hover {
    border-color: #6366f1;
    box-shadow: 0 4px 20px rgba(99,102,241,0.10);
    transform: translateY(-2px);
}
.doc-mini-icon {
    width: 36px;
    height: 36px;
    border-radius: 9px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
}
.doc-new-badge {
    position: absolute;
    top: 6px;
    right: 6px;
    font-size: 8px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    background: #6366f1;
    color: white;
    padding: 1px 5px;
    border-radius: 99px;
    line-height: 1.6;
}

/* ═══════════════════════════════════════════
   UTILITAIRES GLOBAUX
═══════════════════════════════════════════ */
.gradient-text {
    background: linear-gradient(135deg, #6366f1 0%, #a855f7 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.card-hover {
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.card-hover:hover {
    transform: translateY(-4px);
    box-shadow: 0 20px 40px rgba(0,0,0,0.08);
}

.fade-in {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}
.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ═══════════════════════════════════════════
   SCROLL PROGRESS BAR
═══════════════════════════════════════════ */
#scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    height: 3px;
    width: 0%;
    background: linear-gradient(90deg, #6366f1, #a855f7);
    z-index: 9999;
    transition: width 0.1s linear;
}

/* ═══════════════════════════════════════════
   SCROLL TO TOP
═══════════════════════════════════════════ */
#scrollToTop {
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease, transform 0.3s ease;
}
#scrollToTop.visible {
    opacity: 1;
    pointer-events: all;
}

/* ═══════════════════════════════════════════
   NAVBAR — glass-nav + delta-logo
═══════════════════════════════════════════ */
.glass-nav {
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
}

.delta-logo {
    width: 36px;
    height: 36px;
    flex-shrink: 0;
}

#mobileMenu {
    transform: translateX(100%);
    transition: transform 0.3s ease;
}
#mobileMenu.open {
    transform: translateX(0);
}

/* ═══════════════════════════════════════════
   TECH STACK — carousel scroll infini
═══════════════════════════════════════════ */
.tech-container {
    overflow: hidden;
    width: 100%;
    mask-image: linear-gradient(to right, transparent 0%, black 10%, black 90%, transparent 100%);
    -webkit-mask-image: linear-gradient(to right, transparent 0%, black 10%, black 90%, transparent 100%);
}
.tech-track {
    display: flex;
    gap: 1rem;
    width: max-content;
    animation: techScroll 30s linear infinite;
}
.tech-track:hover { animation-play-state: paused; }

.tech-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1.1rem;
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 999px;
    font-size: 13px;
    font-weight: 700;
    color: #475569;
    white-space: nowrap;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
    transition: border-color 0.2s, box-shadow 0.2s;
}
.tech-badge:hover {
    border-color: #6366f1;
    box-shadow: 0 4px 16px rgba(99,102,241,0.12);
}

@keyframes techScroll {
    from { transform: translateX(0); }
    to   { transform: translateX(-50%); }
}

/* ═══════════════════════════════════════════
   TESTIMONIALS — carousel scroll infini
═══════════════════════════════════════════ */
.testimonials-container {
    overflow: hidden;
    width: 100%;
    mask-image: linear-gradient(to right, transparent 0%, black 8%, black 92%, transparent 100%);
    -webkit-mask-image: linear-gradient(to right, transparent 0%, black 8%, black 92%, transparent 100%);
}
.testimonial-track {
    display: flex;
    gap: 1.5rem;
    width: max-content;
    animation: testimonialScroll 40s linear infinite;
    padding: 1rem 0;
}
.testimonial-track:hover { animation-play-state: paused; }

.testimonial-card {
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 1.5rem;
    padding: 1.5rem;
    width: 300px;
    flex-shrink: 0;
    box-shadow: 0 4px 20px rgba(0,0,0,0.05);
    transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.testimonial-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 32px rgba(99,102,241,0.1);
    border-color: #c7d2fe;
}

@keyframes testimonialScroll {
    from { transform: translateX(0); }
    to   { transform: translateX(-50%); }
}

/* ═══════════════════════════════════════════
   COOKIE BANNER
═══════════════════════════════════════════ */
#cookie-banner {
    position: fixed;
    bottom: 1.5rem;
    left: 50%;
    transform: translateX(-50%) translateY(20px);
    width: calc(100% - 3rem);
    max-width: 600px;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s ease, transform 0.4s ease;
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 1.5rem;
    box-shadow: 0 20px 60px rgba(0,0,0,0.12);
    z-index: 9999;
}
#cookie-banner.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
    pointer-events: all;
}
.cookie-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 1.5rem;
    cursor: pointer;
}
.cookie-detail-panel {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}
.cookie-detail-panel.open { max-height: 400px; }
.cookie-category {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.75rem 0;
    border-bottom: 1px solid #f1f5f9;
}
.cookie-category:last-child { border-bottom: none; }
.cookie-toggle {
    position: relative;
    display: inline-block;
    width: 40px;
    height: 22px;
    flex-shrink: 0;
    margin-top: 2px;
}
.cookie-toggle input { opacity: 0; width: 0; height: 0; }
.cookie-toggle-slider {
    position: absolute;
    inset: 0;
    background: #e2e8f0;
    border-radius: 999px;
    cursor: pointer;
    transition: background 0.2s;
}
.cookie-toggle-slider::before {
    content: '';
    position: absolute;
    width: 16px;
    height: 16px;
    left: 3px;
    top: 3px;
    background: white;
    border-radius: 50%;
    transition: transform 0.2s;
}
.cookie-toggle input:checked + .cookie-toggle-slider { background: #6366f1; }
.cookie-toggle input:checked + .cookie-toggle-slider::before { transform: translateX(18px); }
.cookie-toggle input:disabled + .cookie-toggle-slider { opacity: 0.5; cursor: not-allowed; }

/* ═══════════════════════════════════════════
   DARK THEME — couverture complète
═══════════════════════════════════════════ */

/* Base */
body.dark-theme {
    background-color: #0f172a;
    color: #e2e8f0;
}

/* Navbar */
body.dark-theme .glass-nav {
    background: rgba(15, 23, 42, 0.9);
    border-color: rgba(51, 65, 85, 0.4);
}

/* Dropdown */
body.dark-theme .nav-dropdown-menu {
    background: #1e293b;
    border-color: #334155;
    box-shadow: 0 20px 40px rgba(0,0,0,0.3);
}
body.dark-theme .nav-dropdown-menu a          { color: #94a3b8; }
body.dark-theme .nav-dropdown-menu a:hover    { background: rgba(99,102,241,0.1); color: #a5b4fc; }
body.dark-theme .nav-dropdown-menu .menu-divider { background: #334155; }

/* Textes */
body.dark-theme .text-slate-900 { color: #f1f5f9 !important; }
body.dark-theme .text-slate-800 { color: #e2e8f0 !important; }
body.dark-theme .text-slate-700 { color: #cbd5e1 !important; }
body.dark-theme .text-slate-600 { color: #94a3b8 !important; }
body.dark-theme .text-slate-500 { color: #64748b !important; }
body.dark-theme .text-slate-400 { color: #475569 !important; }

/* Fonds */
body.dark-theme .bg-white       { background-color: #1e293b !important; }
body.dark-theme .bg-slate-50    { background-color: #0f172a !important; }
body.dark-theme .bg-\[#F8FAFC\] { background-color: #0f172a !important; }

/* Bordures */
body.dark-theme .border-slate-200  { border-color: #334155 !important; }
body.dark-theme .border-slate-100  { border-color: #1e293b !important; }
body.dark-theme .border-b          { border-color: #1e293b !important; }
body.dark-theme .border-y          { border-color: #1e293b !important; }
body.dark-theme .border-t          { border-color: #334155 !important; }
body.dark-theme .w-px.bg-slate-200 { background-color: #334155 !important; }
body.dark-theme .h-5.w-px.bg-slate-200 { background-color: #334155 !important; }

/* Badges */
body.dark-theme .bg-indigo-50      { background-color: rgba(99,102,241,0.12) !important; }
body.dark-theme .border-indigo-100 { border-color: rgba(99,102,241,0.25) !important; }
body.dark-theme .text-indigo-700   { color: #a5b4fc !important; }
body.dark-theme .bg-green-50       { background-color: rgba(16,185,129,0.1) !important; }
body.dark-theme .border-green-100  { border-color: rgba(16,185,129,0.2) !important; }
body.dark-theme .text-green-700    { color: #6ee7b7 !important; }

/* Composants custom */
body.dark-theme .doc-card          { background: #1e293b; border-color: #334155; }
body.dark-theme .doc-card:hover    { background: #27364b; border-color: #6366f1; }
body.dark-theme .doc-mini-card     { background: #1e293b !important; border-color: #334155 !important; }
body.dark-theme .doc-mini-card:hover { background: #27364b !important; }
body.dark-theme .doc-mini-card p   { color: #e2e8f0 !important; }
body.dark-theme .testimonial-card  { background: #1e293b; border-color: #334155; }
body.dark-theme .tech-badge        { background: #1e293b; border-color: #334155; color: #94a3b8; }

/* Cards arrondies génériques (sections Ce qu'on fait, Comment commander, Garanties, Pricing…) */
body.dark-theme .bg-white.rounded-\[2rem\],
body.dark-theme .bg-white.rounded-\[2\.5rem\],
body.dark-theme .bg-slate-50.rounded-\[2rem\],
body.dark-theme .bg-slate-50.rounded-\[2\.5rem\] {
    background-color: #1e293b !important;
    border-color: #334155 !important;
}

/* Pricing card elite */
body.dark-theme .bg-slate-950 { background-color: #020617 !important; }

/* Formulaire contact */
body.dark-theme form.bg-white         { background-color: #1e293b !important; border-color: #334155 !important; }
body.dark-theme input,
body.dark-theme select,
body.dark-theme textarea              { background-color: #0f172a !important; border-color: #334155 !important; color: #f1f5f9 !important; }
body.dark-theme input::placeholder,
body.dark-theme textarea::placeholder { color: #475569 !important; }

/* Menu mobile */
body.dark-theme #mobileMenu          { background: #1e293b !important; border-color: #334155 !important; }
body.dark-theme #mobileMenu a        { color: #cbd5e1 !important; }
body.dark-theme #mobileMenu a:hover  { background: rgba(99,102,241,0.15) !important; color: #a5b4fc !important; }
body.dark-theme #closeMobileMenu     { background: #334155 !important; color: #e2e8f0 !important; }
body.dark-theme #themeToggle         { background-color: #334155; }

/* Cookie banner */
body.dark-theme #cookie-banner       { background: #1e293b !important; border-color: #334155 !important; }
body.dark-theme .cookie-category     { border-color: #334155 !important; }
body.dark-theme .cookie-toggle-slider::before { background: #94a3b8; }

/* Footer */
body.dark-theme footer               { background-color: #020617 !important; }
body.dark-theme .border-white\/5     { border-color: rgba(255,255,255,0.05) !important; }

/* Section doc teaser fond gradient */
body.dark-theme section[style*="gradient"] { background: #1e293b !important; }