/* ================================================================
   ODS Sidebar XL — 300px → 420px + cards respirantes + labels bold
   Niveau 2 FAANG biotech — effet dashboard Linear/Vercel/Benchling
   Deploy: 22 avril 2026
   Rollback: sudo rm /var/www/omicsdatasolutions.com/wp-content/mu-plugins/ods-sidebar-xl.php

   Stratégie :
   - Override --sidebar-w à 420px (propage automatiquement sur sidebar + main + topbar + footer via style.css astra-child)
   - Topbar "Make an Appointment" (section 2a89ce8) suit automatiquement via ligne 182-185 de style.css
   - Cards nav : padding 16px 18px, font 18px, icônes 22px
   - Labels NAV/COMPANY : 13px, weight 700, letter-spacing 0.12em
   - Logo : un peu plus grand pour remplir la nouvelle largeur
   ================================================================ */

/* ========= 1. VARIABLE CENTRALE — tout le layout suit ========= */
html:root {
    --sidebar-w: 420px !important;
}

html body {
    --sidebar-w: 420px !important;
}

/* Alignement explicite desktop (sécurité anti-cache) */
@media (min-width: 1025px) {
    body aside.ods-sidebar {
        width: 420px !important;
    }
}

/* État mobile hidden aligné sur nouvelle largeur */
@media (max-width: 1024px) {
    body .ods-sidebar {
        transform: translateX(-420px) !important;
        width: 420px !important;
    }
    body .ods-sidebar.open {
        transform: translateX(0) !important;
    }
}

/* ========= 2. CONTAINER SIDEBAR — padding respirant ========= */
body aside.ods-sidebar {
    padding-left: 28px !important;
    padding-right: 28px !important;
    padding-top: 56px !important;
    padding-bottom: 40px !important;
}

/* ========= 3. LOGO — un peu plus grand ========= */
body aside.ods-sidebar .ods-sb-logo {
    margin-bottom: 52px !important;
    padding-left: 4px !important;
    padding-right: 4px !important;
}

body aside.ods-sidebar .ods-sb-logo img {
    max-height: 56px !important;
    width: auto !important;
    height: auto !important;
}

/* ========= 4. LABELS NAVIGATION / COMPANY — 13px bold ========= */
body aside.ods-sidebar .ods-sb-label {
    font-family: 'JetBrains Mono', 'SF Mono', Menlo, monospace !important;
    font-size: 13px !important;
    font-weight: 700 !important;
    letter-spacing: 0.12em !important;
    text-transform: uppercase !important;
    color: #64748B !important;
    padding: 28px 14px 14px 14px !important;
    margin: 0 !important;
    line-height: 1.4 !important;
}

/* ========= 5. NAV CONTAINER — gap entre cards ========= */
body aside.ods-sidebar nav.ods-sb-nav {
    display: flex !important;
    flex-direction: column !important;
    gap: 6px !important;
}

/* ========= 6. CARDS NAV — padding + font-size up ========= */
body aside.ods-sidebar .ods-side-link,
body aside.ods-sidebar nav.ods-sb-nav > a {
    display: flex !important;
    align-items: center !important;
    gap: 16px !important;
    font-family: 'DM Sans', -apple-system, BlinkMacSystemFont, sans-serif !important;
    font-size: 18px !important;
    font-weight: 500 !important;
    line-height: 1.35 !important;
    letter-spacing: -0.01em !important;
    color: #0F172A !important;
    padding: 16px 18px !important;
    border-radius: 12px !important;
    background: #FFFFFF !important;
    border: 1px solid rgba(226, 232, 240, 0.6) !important;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.03) !important;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1) !important;
    text-decoration: none !important;
    position: relative !important;
    margin: 0 !important;
}

/* Icônes des cards — plus grandes avec la card */
body aside.ods-sidebar .ods-side-link svg,
body aside.ods-sidebar nav.ods-sb-nav > a svg {
    width: 22px !important;
    height: 22px !important;
    flex-shrink: 0 !important;
    color: #64748B !important;
    stroke: #64748B !important;
    transition: color 0.2s !important;
}

/* HOVER — préserve l'effet lift existant */
body aside.ods-sidebar .ods-side-link:hover,
body aside.ods-sidebar nav.ods-sb-nav > a:hover {
    background: #FFFFFF !important;
    border-color: rgba(45, 122, 31, 0.25) !important;
    box-shadow: 0 6px 16px rgba(15, 23, 42, 0.07), 0 2px 4px rgba(15, 23, 42, 0.04) !important;
    transform: translateY(-1px) !important;
    color: #2D7A1F !important;
}

body aside.ods-sidebar .ods-side-link:hover svg,
body aside.ods-sidebar nav.ods-sb-nav > a:hover svg {
    color: #2D7A1F !important;
    stroke: #2D7A1F !important;
}

/* ACTIVE — préserve l'état actif vert */
body aside.ods-sidebar .ods-side-link.active,
body aside.ods-sidebar .ods-side-link.current-menu-item,
body aside.ods-sidebar .ods-side-link[aria-current="page"],
body aside.ods-sidebar nav.ods-sb-nav > a.active,
body aside.ods-sidebar nav.ods-sb-nav > a.current-menu-item,
body aside.ods-sidebar nav.ods-sb-nav > a[aria-current="page"] {
    background: #F0F7ED !important;
    border-color: rgba(45, 122, 31, 0.35) !important;
    color: #2D7A1F !important;
    font-weight: 600 !important;
    box-shadow: 0 2px 10px rgba(45, 122, 31, 0.09), 0 1px 2px rgba(45, 122, 31, 0.05) !important;
}

/* ========= 7. FIX DOUBLE-MARGIN — header/footer sections ========= */
@media (min-width: 1025px) {
    body.has-ods-sidebar .elementor-element-2a89ce8,
    body.has-ods-sidebar .elementor-element-6baf339,
    body.has-ods-sidebar .elementor-element-2604811 {
        margin-left: 0 !important;
        width: 100% !important;
    }

    body.has-ods-sidebar .ods-footer-main {
        margin-left: 0 !important;
        width: 100% !important;
    }
}
