:root {
    --primary: #635bff;
    --text-dark: #0a2540;
    --text-light: #425466;
    --text-muted: #8898aa;
    --bg-main: #f6f9fc;
    --bg-white: #ffffff;
    --border-light: #f0f4f8;
    --border-dark: #e6ebf1;
    --hover-bg: #f1f5f9;
    --hover-text: #0f172a;
}


/* Secondary Sub-header */
.sub-header {
    background: var(--bg-white);
    border-bottom: 1px solid var(--border-light);
    padding: 0.5rem 1.5rem;
}

.sub-header-container {
    max-width: 1080px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    font-size: 0.85rem;
}

.sub-brand {
    font-weight: 700;
    color: var(--primary);
    text-decoration: none;
}

.sub-link {
    color: var(--primary);
    text-decoration: none;
    font-weight: 500;
}

/* Primary Navbar */
.navbar {
    position: relative;
    z-index: 100;
}

.nav-container {
    margin: 0 auto;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.logo {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--text-dark);
    text-decoration: none;
    letter-spacing: -0.03em;
}

/* Desktop Links */
.desktop-nav {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.nav-btn,
.static-link {
    background: none;
    border: none;
    font-size: 0.95rem;
    font-weight: 600;
    padding: 0.5rem 0.8rem;
    cursor: pointer;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 0.25rem;
    border-radius: 16px;
    transition: background-color 0.2s ease, color 0.2s ease;
}

.nav-btn:hover,
.static-link:hover {
    background: var(--hover-bg);
    color: var(--hover-text);
}

/* Lightweight CSS-drawn chevron (replaces inline SVG) */
.nav-btn::after {
    content: "";
    width: 6px;
    height: 6px;
    margin-left: 2px;
    border-right: 1.5px solid currentColor;
    border-bottom: 1.5px solid currentColor;
    opacity: 0.95;
    transform: rotate(45deg) translateY(-1px);
    transition: transform 0.2s ease, opacity 0.2s ease;
}

.nav-btn:hover::after {
    opacity: 0.85;
}

.nav-btn.active::after {
    opacity: 1;
    transform: rotate(225deg) translateY(-1px);
}

/* Actions */
.nav-actions {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.link-sign-in {
    color: var(--text-dark);
    font-size: 0.9rem;
    font-weight: 600;
    text-decoration: none;
}

.btn-sales {
    font-size: 0.85rem;
    font-weight: 600;
    padding: 0.4rem 0.9rem;
    border-radius: 20px;
    text-decoration: none;
}

.hamburger-btn {
    display: none;
    background: var(--text-dark);
    border: none;
    padding: 0.5rem;
    border-radius: 6px;
    cursor: pointer;
    flex-direction: column;
    gap: 3px;
}

.hamburger-btn span {
    display: block;
    width: 14px;
    height: 2px;
    background: var(--bg-white);
}

/* DESKTOP MORPHING CONTAINER */
.popover-wrapper {
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    margin-left: 0;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    --pop-x: 0px;
    transform: translate(var(--pop-x), 10px);
    transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s;
}

.popover-wrapper.open {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translate(var(--pop-x), 0px);
}

.popover-box {
    width: 100%;
    border-radius: 0;
    box-shadow: 0 13px 27px -5px rgba(50, 50, 93, 0.25), 0 8px 16px -8px rgba(0, 0, 0, 0.3);
    overflow: hidden;
    transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), height 0.25s cubic-bezier(0.16, 1, 0.3, 1);
    transform-origin: top;
}

.popover-content {
    position: relative;
}

.panel {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    max-width: 1080px;
    margin: 0 auto;
    right: 0;
    padding: 1.5rem;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.2s ease;
}

.panel.active {
    opacity: 1;
    visibility: visible;
    position: relative;
}

/* Panel Layout Grids */
.desktop-menu-grid {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: 180px;
    gap: 1.5rem;
    width: fit-content;
    margin: auto;
    padding: 20px;
    border-radius: 5px;
    background: var(--background);
}

.desktop-menu-grid h5 {
    font-size: 0.75rem;
    text-transform: uppercase;
    color: var(--text-muted);
    margin-bottom: 0.75rem;
}

/* Nav Lists (Replaces nested divs) */
ul.nav-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.nav-list a {
    display: block;
    text-decoration: none;
    margin-bottom: 0.8rem;
}

.nav-list a strong {
    display: block;
    font-size: 0.85rem;
}

.nav-list a span {
    display: block;
    font-size: 0.75rem;
}



/* Bug fix */
#mobile-track .mobile-screen:not(#mobile-main-screen) {
    display: none;
}

/* MOBILE DRILL-DOWN OVERLAY */
.mobile-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    /* background: var(--bg-white); */
    z-index: 1000;
    flex-direction: column;
}

.mobile-overlay.open {
    display: flex;
}

.mobile-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 1rem 1.5rem;
}

.mobile-title-spacer {
    flex: 1;
}

.back-btn {
    background: none;
    border: none;
    color: var(--primary);
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.back-btn.hidden {
    opacity: 0;
    pointer-events: none;
}

.back-btn-stripe.hidden {
    display: none;
}

.icon-chevron {
    display: inline-block;
    flex-shrink: 0;
}

.close-btn {
    background: #e0e7ff;
    color: var(--primary);
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.mobile-viewport {
    flex: 1;
    overflow: hidden;
    position: relative;
}

.mobile-track {
    display: flex;
    width: 200%;
    height: 100%;
    transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.mobile-track.sliding {
    transform: translateX(-50%);
}

.mobile-screen {
    width: 50%;
    height: 100%;
    overflow-y: auto;
    padding: 1rem 1.5rem;
}

/* Screen 1 List */
.mobile-menu-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.mobile-menu-list li {
    border-bottom: 1px dashed var(--primary-surface-border);
}

.mobile-nav-item,
.mobile-static-item {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
    background: none;
    border: none;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--color);
    text-decoration: none;
    cursor: pointer;
}

    .mobile-nav-item::after {
        content: "";
        width: 6px;
        height: 6px;
        margin-left: 2px;
        border-right: 1.5px solid currentColor;
        border-bottom: 1.5px solid currentColor;
        opacity: 0.95;
        transform: rotate(-45deg) translateY(-1px);
        transition: transform 0.2s ease, opacity 0.2s ease;
    }

.mobile-nav-item .arrow {
    color: var(--color);
    transition: transform 0.2s ease;
}

.mobile-nav-item[aria-expanded="true"] .arrow {
    transform: rotate(90deg);
}

/* Screen 2 Content */
.mobile-cat-heading {
    font-size: 0.9rem;
    color: var(--primary-color);
    padding-bottom: 0.5rem;
    margin-top: 1rem;
    border-bottom: 2px solid;
    border-image: linear-gradient(to right, var(--primary), #00d4b6) 1;
}

.mobile-link-group {
    margin-bottom: 1.5rem;
}

.mobile-link-group a {
    display: block;
    text-decoration: none;
    margin-top: 0.8rem;
    margin-bottom: 0;
}

.mobile-link-group a strong {
    display: block;
    font-size: 0.95rem;
    color: var(--color);
}

.mobile-link-group a span {
    display: block;
    font-size: 0.8rem;
    color: color-mix(in srgb, currentColor 65%, transparent);
}

/* Fixed Mobile Bottom Bar */
.mobile-bottom-bar {
    padding: 1rem 1.5rem 1.5rem;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.btn-start {
    background: var(--text-dark);
    color: var(--bg-white);
    padding: 0.6rem 1.2rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    text-decoration: none;
}

.link-contact {
    color: var(--text-dark);
    font-size: 0.85rem;
    font-weight: 600;
    text-decoration: none;
}

/* RESPONSIVE BREAKPOINT */
@media (max-width: 850px) {

    .desktop-nav,
    .link-sign-in,
    .btn-sales,
    .sub-header {
        display: none;
    }

    .hamburger-btn {
        display: flex;
    }
}