/* Main Variables */
:root {
    --primary-color: #6366f1;
    /* Indigo */
    --primary-dark: #4f46e5;
    --secondary-color: #06b6d4;
    /* Cyan/Teal */
    --accent-color: #8b5cf6;
    /* Violet */
    --dark-bg: #0f172a;
    --light-bg: #f8fafc;
    --text-main: #1e293b;
    --text-muted: #64748b;
    --text-light: #f1f5f9;
    --white: #ffffff;
    --success: #10b981;

    --font-heading: 'Outfit', sans-serif;
    --font-body: 'Inter', sans-serif;

    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
    --shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1);

    --radius-sm: 0.375rem;
    --radius-md: 0.5rem;
    --radius-lg: 1rem;
    --radius-full: 9999px;

    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Reset & Base */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
    overflow-x: hidden;
}

body {
    font-family: var(--font-body);
    font-weight: 400;
    line-height: 1.6;
    color: var(--text-main);
    background-color: var(--light-bg);
    overflow-x: hidden;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    font-weight: 700;
    line-height: 1.2;
    color: var(--dark-bg);
    margin-bottom: 1rem;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* Container */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* Helper Classes */
.text-gradient {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.bg-gradient {
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.875rem 2rem;
    font-weight: 600;
    border-radius: var(--radius-full);
    transition: var(--transition);
    cursor: pointer;
    font-size: 1rem;
}

.btn-primary {
    background: var(--primary-color);
    color: var(--white);
    box-shadow: var(--shadow-md);
}

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-outline {
    background: transparent;
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
}

.btn-outline:hover {
    background: var(--primary-color);
    color: var(--white);
}

.section-padding {
    padding: 5rem 0;
}

/* Header & Nav */
.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    z-index: 1000;
    padding: 1rem 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    transition: var(--transition);
}

.nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--dark-bg);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    height: 44px;
    /* Strict height constraint */
}

.logo img {
    height: 100%;
    width: auto;
    object-fit: contain;
    background: none;
    max-height: none;
    /* Let the wrapper control height */
    max-width: 100%;
    /* Prevent overflow */
}

.nav-links {
    display: flex;
    gap: 2rem;
    margin-left: 3rem;
}

.nav-link {
    font-weight: 500;
    color: var(--text-muted);
}

.nav-link:hover {
    color: var(--primary-color);
}

.mobile-toggle {
    display: none;
    font-size: 1.5rem;
    cursor: pointer;
}

/* Hero Section */
.hero {
    padding-top: 8rem;
    padding-bottom: 6rem;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: -20%;
    right: -10%;
    width: 50%;
    height: 80%;
    background: radial-gradient(circle, rgba(99, 102, 241, 0.15) 0%, rgba(255, 255, 255, 0) 70%);
    border-radius: 50%;
    z-index: -1;
}

.hero-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.hero-content h1 {
    font-size: 3.5rem;
    margin-bottom: 1.5rem;
    line-height: 1.1;
}

.hero-content p {
    font-size: 1.25rem;
    color: var(--text-muted);
    margin-bottom: 2.5rem;
    max-width: 500px;
}

.hero-img-wrapper {
    position: relative;
    z-index: 1;
}

.hero-img {
    border-radius: var(--radius-lg);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    border: 1px solid rgba(255, 255, 255, 0.5);
    width: 100%;
}

.hero-badge {
    position: absolute;
    bottom: -20px;
    left: -20px;
    background: var(--white);
    padding: 1rem 1.5rem;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    display: flex;
    align-items: center;
    gap: 1rem;
    animation: float 4s ease-in-out infinite;
}

@keyframes float {
    0% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-10px);
    }

    100% {
        transform: translateY(0);
    }
}

/* Problem/Solution */
.problem-solution {
    background: var(--white);
}

.section-header {
    text-align: center;
    max-width: 800px;
    margin: 0 auto 4rem;
}

.section-label {
    display: inline-block;
    padding: 0.5rem 1rem;
    background: rgba(99, 102, 241, 0.1);
    color: var(--primary-color);
    border-radius: var(--radius-full);
    font-weight: 600;
    font-size: 0.875rem;
    margin-bottom: 1rem;
}

.section-header h2 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.grid-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.card {
    background: var(--light-bg);
    padding: 2rem;
    border-radius: var(--radius-lg);
    transition: var(--transition);
    border: 1px solid transparent;
}

.card:hover {
    background: var(--white);
    box-shadow: var(--shadow-lg);
    border-color: rgba(99, 102, 241, 0.2);
    transform: translateY(-5px);
}

.card-icon {
    width: 60px;
    height: 60px;
    background: var(--white);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: var(--primary-color);
    margin-bottom: 1.5rem;
    box-shadow: var(--shadow-sm);
}

.card h3 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
}

.card p {
    color: var(--text-muted);
}

/* Features */
.features {
    background: var(--light-bg);
}

.feature-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    margin-bottom: 6rem;
}

.feature-row.reverse {
    direction: rtl;
    /* Simple way to swap, need to handle text alignment */
}

.feature-row.reverse>* {
    direction: ltr;
    /* Reset text direction */
}

.feature-content h3 {
    font-size: 2rem;
    margin-bottom: 1rem;
}

.feature-content p {
    font-size: 1.125rem;
    color: var(--text-muted);
    margin-bottom: 1.5rem;
}

.feature-list li {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
    color: var(--dark-bg);
    font-weight: 500;
}

.feature-list li svg {
    color: var(--success);
    flex-shrink: 0;
}

.feature-img-wrapper {
    position: relative;
}

.feature-img {
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-xl);
}

/* How it works */
.how-it-works {
    background: var(--dark-bg);
    color: var(--white);
}

.how-it-works h2,
.how-it-works p {
    color: var(--white);
}

.how-it-works p {
    opacity: 0.8;
}

.steps {
    display: flex;
    justify-content: space-between;
    gap: 2rem;
    margin-top: 4rem;
    position: relative;
}

.step-card {
    background: rgba(255, 255, 255, 0.05);
    padding: 2rem;
    border-radius: var(--radius-lg);
    border: 1px solid rgba(255, 255, 255, 0.1);
    flex: 1;
    position: relative;
    backdrop-filter: blur(10px);
}

.step-number {
    font-size: 4rem;
    font-weight: 800;
    color: rgba(255, 255, 255, 0.1);
    position: absolute;
    top: 10px;
    right: 20px;
    line-height: 1;
}

.step-card h3 {
    color: var(--white);
    margin-top: 1rem;
}

/* Use Cases */
.use-cases {
    background: var(--white);
}

.use-case-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
}

.use-case-item {
    background: var(--light-bg);
    padding: 2rem;
    border-radius: var(--radius-md);
    text-align: center;
    transition: var(--transition);
}

.use-case-item:hover {
    background: var(--white);
    box-shadow: var(--shadow-lg);
    transform: translateY(-5px);
}

.use-case-icon {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

/* Stats / Trust */
.stats {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: var(--white);
    padding: 4rem 0;
}

.stats-grid {
    display: flex;
    justify-content: space-around;
    text-align: center;
}

.stat-item h3 {
    color: var(--white);
    font-size: 3rem;
    margin-bottom: 0;
}

.stat-item p {
    color: rgba(255, 255, 255, 0.9);
    font-weight: 500;
}

/* CTA */
.cta-section {
    text-align: center;
    background: var(--white);
}

.cta-box {
    background: var(--dark-bg);
    border-radius: 2rem;
    padding: 5rem 2rem;
    color: var(--white);
    position: relative;
    overflow: hidden;
}

.cta-box h2 {
    color: var(--white);
}

.cta-box p {
    color: rgba(255, 255, 255, 0.8);
    max-width: 600px;
    margin: 0 auto 2.5rem;
}

.cta-box::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -20%;
    width: 80%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, rgba(255, 255, 255, 0) 70%);
    transform: rotate(45deg);
}

/* Footer */
footer {
    background: var(--light-bg);
    padding: 4rem 0 2rem;
    border-top: 1px solid rgba(0, 0, 0, 0.05);
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 4rem;
    margin-bottom: 3rem;
}

.footer-brand p {
    margin-top: 1rem;
    color: var(--text-muted);
}

.footer-col h4 {
    font-size: 1.125rem;
    margin-bottom: 1.5rem;
}

.footer-col a {
    display: block;
    color: var(--text-muted);
    margin-bottom: 0.75rem;
    color: var(--text-muted);
    transition: var(--transition);
}

.footer-col a:hover {
    color: var(--primary-color);
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(0, 0, 0, 0.05);
    color: var(--text-muted);
    font-size: 0.875rem;
}

/* Dropdown Menu */
.dropdown {
    position: relative;
    display: flex;
    align-items: center;
}

.dropdown-menu {
    position: absolute;
    top: 100%;
    left: 0;
    background: var(--white);
    box-shadow: var(--shadow-lg);
    border-radius: var(--radius-md);
    min-width: 200px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: var(--transition);
    padding: 0.5rem 0;
    z-index: 100;
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.dropdown:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-item {
    display: block;
    padding: 0.75rem 1.5rem;
    color: var(--text-main);
    font-weight: 500;
    transition: var(--transition);
    font-size: 0.95rem;
}

.dropdown-item:hover {
    background: var(--light-bg);
    color: var(--primary-color);
    padding-left: 1.75rem;
    /* Subtle indent effect */
}

/* Updated nav link */
.nav-link {
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 4px;
}

/* Responsive */
@media (max-width: 992px) {

    .hero-grid,
    .feature-row,
    .grid-3,
    .use-case-grid {
        grid-template-columns: 1fr;
    }

    .hero {
        text-align: center;
        padding-top: 7rem;
    }

    .hero-content p {
        margin: 0 auto 2.5rem;
    }

    .feature-row {
        gap: 3rem;
    }

    .feature-row.reverse {
        direction: ltr;
        /* Reset for stacking */
    }

    .feature-img {
        order: -1;
    }

    .steps {
        flex-direction: column;
    }

    .footer-grid {
        grid-template-columns: 1fr 1fr;
        gap: 2rem;
    }

    /* Navigation on mobile */
    .nav-links {
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: var(--white);
        flex-direction: column;
        padding: 0;
        box-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1);
        display: none;
        max-height: calc(100vh - 70px);
        overflow-y: auto;
        border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    }

    .nav-links.active {
        display: flex;
    }

    .nav-link {
        padding: 1rem 2rem;
        border-bottom: 1px solid rgba(0, 0, 0, 0.05);
        width: 100%;
        justify-content: space-between;
    }

    .btn {
        margin: 1rem 2rem;
        width: calc(100% - 4rem);
    }

    /* Mobile Dropdowns */
    .dropdown {
        flex-direction: column;
        align-items: flex-start;
        width: 100%;
    }

    .dropdown .nav-link {
        width: 100%;
    }

    .dropdown-menu {
        position: static;
        width: 100%;
        box-shadow: none;
        border: none;
        padding: 0;
        opacity: 1;
        visibility: visible;
        transform: none;
        display: none;
        background: var(--light-bg);
    }

    .dropdown.active .dropdown-menu {
        display: block;
    }

    .dropdown-item {
        padding-left: 3rem;
        border-bottom: 1px solid rgba(0, 0, 0, 0.02);
    }

    .dropdown-item:hover {
        padding-left: 3.5rem;
    }

    /* Mobile Mega Menu Fix */
    .dropdown-mega {
        grid-template-columns: 1fr;
        padding: 0;
    }

    .dropdown-mega>div {
        padding: 0;
        border: none !important;
        margin: 0 !important;
    }

    .dropdown-mega-group {
        padding: 1rem 0;
    }

    .dropdown-mega-group h5 {
        padding: 0 3rem;
        margin-top: 1rem;
        font-size: 0.85rem;
        color: var(--primary-color);
        text-transform: uppercase;
        letter-spacing: 0.5px;
    }

    /* Fix the 'Vue d'ensemble' link in mega menu mobile */
    .dropdown-mega a[href="secteurs.html"] {
        padding: 1rem 3rem !important;
        background: rgba(99, 102, 241, 0.05);
        margin-bottom: 0 !important;
    }
}

@media (max-width: 768px) {


    /* ... existing mobile styles ... */
    .logo {
        height: 34px;
        /* Strict mobile height */
    }

    .logo img {
        max-height: 100%;
        max-width: 100%;
    }

    .mobile-toggle {
        display: block;
    }

    .hero-content h1 {
        font-size: 2.5rem;
    }

    .stats-grid {
        flex-direction: column;
        gap: 2rem;
    }

    .footer-grid {
        grid-template-columns: 1fr;
    }

    /* ========================================
       MOBILE VIEWPORT FIX - PREVENT OVERFLOW
       ======================================== */

    /* Fix hero badge position on mobile */
    .hero-badge {
        left: 10px;
        bottom: -10px;
    }

    /* Fix hero pseudo-element overflow */
    .hero::before {
        right: 0;
        width: 40%;
    }

    /* Override inline 2-column grids on mobile - utility class */
    .mobile-stack {
        grid-template-columns: 1fr !important;
        gap: 2rem !important;
    }

    .mobile-stack-item {
        border-right: none !important;
        border-bottom: 1px solid rgba(0, 0, 0, 0.05) !important;
        padding-right: 0 !important;
        padding-bottom: 2rem !important;
        margin-bottom: 0 !important;
    }

    /* Also catch any remaining inline 2-column grids */
    [style*="grid-template-columns: 1fr 1fr"] {
        grid-template-columns: 1fr !important;
        gap: 2rem !important;
    }

    /* Fix CTA box overflow from pseudo-element */
    .cta-box {
        overflow: hidden;
    }

    .cta-box::before {
        left: -50%;
        width: 100%;
    }

    /* Ensure all section content stays within viewport */
    section>.container {
        max-width: 100%;
        overflow-x: hidden;
    }

    /* Fix hero content padding */
    .hero-content {
        padding: 0 0.5rem;
    }

    /* Smaller title on very small screens */
    .hero-content h1 {
        font-size: 2rem;
    }

    /* Fix comparison section borders on mobile */
    [style*="border-right: 1px"] {
        border-right: none !important;
        border-bottom: 1px solid rgba(0, 0, 0, 0.05) !important;
        padding-right: 0 !important;
        padding-bottom: 2rem !important;
        margin-bottom: 2rem !important;
    }

    [style*="padding-left: 2rem"] {
        padding-left: 0 !important;
    }

    /* Reduce gap in inline styled grids */
    [style*="gap: 4rem"] {
        gap: 2rem !important;
    }

    /* Ensure cards fit mobile width */
    .card {
        max-width: 100%;
    }

    /* Fix feature row image wrapper */
    .feature-img-wrapper {
        max-width: 100%;
        overflow: hidden;
    }
}

/* Extra small screens (small phones) */
@media (max-width: 480px) {
    .container {
        padding: 0 1rem;
    }

    .hero-content h1 {
        font-size: 1.75rem;
        line-height: 1.2;
    }

    .hero-content p {
        font-size: 1rem;
    }

    .btn {
        padding: 0.75rem 1.5rem;
        font-size: 0.9rem;
    }

    .section-header h2 {
        font-size: 1.75rem;
    }

    .section-padding {
        padding: 3rem 0;
    }

    /* Hide decorative badge on very small screens */
    .hero-badge {
        display: none;
    }

    /* Reduce CTA box padding */
    .cta-box {
        padding: 3rem 1rem;
    }

    /* Smaller step cards */
    .step-card {
        padding: 1.5rem;
    }

    .step-number {
        font-size: 3rem;
    }
}

/* Animations */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
    will-change: opacity, transform;
}

.animate-on-scroll.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Scroll to Top Button */
.scroll-top-btn {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    background: var(--primary-color);
    color: var(--white);
    width: 3rem;
    height: 3rem;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: var(--shadow-lg);
    border: none;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 999;
}

.scroll-top-btn.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.scroll-top-btn:hover {
    background: var(--primary-dark);
    transform: translateY(-5px);
}

/* Mega Dropdown Extensions */
.dropdown-static {
    position: static !important;
}

.dropdown-mega {
    width: 100%;
    left: 0;
    right: 0;
    margin-top: 0;
    /* Align with header bottom */
    transform: none;
    display: grid;
    grid-template-columns: repeat(8, 1fr);
    gap: 1rem;
    padding: 2.5rem 2rem;
    /* Side padding relative to screen */
    border-top: 1px solid rgba(0, 0, 0, 0.05);
    background: var(--white);
    max-width: 100%;
    /* Override previous constraint */
    overflow-y: auto;
    max-height: 80vh;
}

/* Make the Vue d'ensemble section a full-width top bar */
.sectors-overview-bar {
    grid-column: 1 / -1;
    display: flex;
    justify-content: center;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.08), rgba(99, 102, 241, 0.03));
    margin: -2.5rem -2rem 1.5rem -2rem;
    padding: 0.75rem 2rem;
    border-bottom: 1px solid rgba(99, 102, 241, 0.1);
}

.sectors-overview-bar .dropdown-item {
    font-size: 0.95rem;
    padding: 0.5rem 1.5rem;
    background: var(--primary-color);
    color: white !important;
    border-radius: var(--radius-full);
    font-weight: 600;
}

.sectors-overview-bar .dropdown-item:hover {
    background: var(--primary-hover);
    transform: scale(1.02);
}

/* Flatten the wrapper divs to expose groups as grid items (exclude close button and overview bar) */
.dropdown-mega>div:not(.mobile-dropdown-close):not(.sectors-overview-bar) {
    display: contents;
}

/* Mobile Responsive Adjustments */
@media (max-width: 1100px) {
    .dropdown-mega {
        grid-template-columns: repeat(4, 1fr);
    }
}

@media (max-width: 992px) {
    .dropdown-static {
        position: relative !important;
        /* Reset for mobile stack */
    }

    .dropdown-mega {
        position: static;
        width: 100%;
        box-shadow: none;
        padding: 0 1rem;
        display: none;
        /* Inherit toggle behavior or stick to hover if possible, but structure handles it */
        grid-template-columns: 1fr;
        gap: 0;
        border-top: none;
    }

    .dropdown-mega>div:not(.mobile-dropdown-close):not(.sectors-overview-bar) {
        display: block;
        /* Remove flattening on mobile */
    }

    .dropdown:hover .dropdown-mega {
        display: block;
        /* Enable visibility on tap/hover */
    }

    /* Reset Vue d'ensemble styling for mobile */
    .sectors-overview-bar {
        margin: 0;
        padding: 0.75rem 0;
        background: transparent;
        border-bottom: none;
    }

    .sectors-overview-bar .dropdown-item {
        font-size: 0.9rem;
        padding: 0.5rem 1rem;
    }

    /* Hide the 'Vue d'ensemble' if desired or keep it */
}

/* Sub-sector styling */
.dropdown-mega-group {
    margin-bottom: 0;
}

.dropdown-mega-group h5 {
    color: var(--primary-color);
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.75rem;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    padding-bottom: 0.25rem;
}

.dropdown-mega .dropdown-item {
    padding: 0.4rem 0.5rem;
    font-size: 0.9rem;
    color: var(--text-muted);
}

.dropdown-mega .dropdown-item:hover {
    color: var(--primary-color);
    background: rgba(99, 102, 241, 0.05);
    padding-left: 0.75rem;
    border-radius: var(--radius-sm);
}

/* Hide mobile close button on desktop */
.mobile-dropdown-close {
    display: none;
}

/* Mobile Override for Mega Menu */
@media (max-width: 992px) {
    .dropdown-mega {
        position: static;
        width: 100%;
        max-width: 100%;
        transform: none;
        display: none;
        /* Hidden by default, shown via JS toggle */
        box-shadow: none;
        border: none;
        padding: 0;
        background: var(--light-bg);
        visibility: visible;
        opacity: 1;
        max-height: 50vh;
        /* Limit height to half viewport */
        overflow-y: auto;
        /* Enable scrolling within menu */
    }

    /* Show mega menu when dropdown is active */
    .dropdown.active .dropdown-mega {
        display: block;
    }

    .dropdown-mega-group {
        margin-bottom: 1rem;
        padding-left: 1rem;
    }

    .dropdown-mega .dropdown-item {
        padding: 0.5rem 1rem;
        font-size: 0.85rem;
    }

    /* Mobile dropdown close button */
    .mobile-dropdown-close {
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 0.75rem 1rem;
        background: rgba(99, 102, 241, 0.1);
        color: var(--primary-color);
        font-weight: 600;
        font-size: 0.9rem;
        border-bottom: 1px solid rgba(0, 0, 0, 0.05);
        cursor: pointer;
    }

    .mobile-dropdown-close i {
        font-size: 1.25rem;
    }

    /* Ensure regular dropdowns toggle correctly on mobile tap */
    .dropdown .dropdown-menu {
        display: none;
    }

    .dropdown.active .dropdown-menu {
        display: block;
        position: static;
        visibility: visible;
        opacity: 1;
        max-height: 50vh;
        overflow-y: auto;
    }

    /* Caret rotation when open */
    .dropdown.active .nav-link i.ph-caret-down {
        transform: rotate(180deg);
        transition: transform 0.3s ease;
    }

    .dropdown .nav-link i.ph-caret-down {
        transition: transform 0.3s ease;
    }
}

/* ========================================
   PRICING SECTION
   ======================================== */
.pricing-section {
    background: var(--light-bg);
}

.pricing-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    max-width: 1000px;
    margin: 0 auto;
}

.pricing-card {
    background: var(--white);
    border-radius: var(--radius-lg);
    padding: 2rem;
    text-align: center;
    border: 1px solid rgba(0, 0, 0, 0.05);
    transition: var(--transition);
    position: relative;
    display: flex;
    flex-direction: column;
}

.pricing-card:hover {
    box-shadow: var(--shadow-lg);
    transform: translateY(-5px);
    border-color: rgba(99, 102, 241, 0.2);
}

.pricing-card.popular {
    border: 2px solid var(--primary-color);
    box-shadow: var(--shadow-md);
}

.pricing-badge {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--primary-color);
    color: var(--white);
    padding: 0.25rem 1rem;
    border-radius: var(--radius-full);
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.pricing-card h3 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
    color: var(--dark-bg);
}

.pricing-card .price {
    font-size: 2.5rem;
    font-weight: 800;
    color: var(--primary-color);
    margin-bottom: 0.25rem;
}

.pricing-card .price span {
    font-size: 1rem;
    font-weight: 500;
    color: var(--text-muted);
}

.pricing-card .price-desc {
    font-size: 0.875rem;
    color: var(--text-muted);
    margin-bottom: 1.5rem;
}

.pricing-features {
    list-style: none;
    padding: 0;
    margin: 0 0 1.5rem 0;
    text-align: left;
    flex-grow: 1;
}

.pricing-features li {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 0;
    color: var(--text-main);
    font-size: 0.9rem;
    border-bottom: 1px solid rgba(0, 0, 0, 0.03);
}

.pricing-features li:last-child {
    border-bottom: none;
}

.pricing-features li i {
    color: var(--success);
    font-size: 1rem;
}

.pricing-card .btn {
    width: 100%;
    margin-top: auto;
}

/* Responsive Pricing */
@media (max-width: 992px) {
    .pricing-grid {
        grid-template-columns: 1fr;
        max-width: 400px;
    }

    .pricing-card.popular {
        order: -1;
    }
}