/* Borealis Ultra Navbar CSS v2.1 */
/* Polished | Responsive | Sales-Focused */

:root {
    /* Local Scoped Variables for Navbar */
    --nav-bg: rgba(2, 12, 27, 0.85);
    --nav-scrolled: rgba(2, 12, 27, 0.98);
    --nav-glass: blur(12px);
    --accent-primary: #64ffda;
    --accent-secondary: #00b4d8;
    --accent-alert: #ff6b6b;
    --text-main: #e6f1ff;
    --text-muted: #8892b0;
    --font-mono: 'Fira Code', monospace;
    --font-sans: 'Inter', sans-serif;
    --ease-out: cubic-bezier(0.645, 0.045, 0.355, 1);
}

/* === Main Wrapper === */
.ultra-nav-wrapper {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 90px;
    background: var(--nav-bg);
    backdrop-filter: var(--nav-glass);
    border-bottom: 1px solid rgba(100, 255, 218, 0.05);
    z-index: 1000;
    transition: all 0.4s var(--ease-out);
}

.ultra-nav-wrapper.scrolled {
    height: 70px;
    background: var(--nav-scrolled);
    box-shadow: 0 10px 30px -10px rgba(2, 12, 27, 0.7);
    border-bottom: 1px solid rgba(100, 255, 218, 0.1);
}

.ultra-nav-container {
    max-width: 1400px;
    margin: 0 auto;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 2rem;
}

/* === Brand Identity === */
.ultra-brand {
    display: flex;
    align-items: center;
    gap: 14px;
    text-decoration: none;
    z-index: 1002;
}

.brand-logo-svg {
    width: 42px;
    height: 42px;
    transition: transform 0.5s var(--ease-out);
    filter: drop-shadow(0 0 5px rgba(100, 255, 218, 0.2));
}

.ultra-brand:hover .brand-logo-svg {
    transform: rotate(180deg);
    filter: drop-shadow(0 0 8px rgba(100, 255, 218, 0.5));
}

.brand-core {
    transform-origin: center;
    animation: pulseCore 3s infinite;
}

@keyframes pulseCore {
    0% { opacity: 0.5; }
    50% { opacity: 1; }
    100% { opacity: 0.5; }
}

.brand-info {
    display: flex;
    flex-direction: column;
}

.brand-text {
    font-family: var(--font-sans);
    font-weight: 800;
    font-size: 1.25rem;
    color: var(--text-main);
    letter-spacing: -0.5px;
    line-height: 1;
}

.brand-text span { color: var(--accent-primary); }

.brand-meta {
    font-family: var(--font-mono);
    font-size: 0.65rem;
    color: var(--text-muted);
    margin-top: 4px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.status-indicator {
    width: 6px;
    height: 6px;
    background: var(--accent-primary);
    border-radius: 50%;
    box-shadow: 0 0 4px var(--accent-primary);
}

/* === Desktop Links === */
.ultra-nav-links {
    display: flex;
    gap: 2.5rem;
    height: 100%;
    align-items: center;
}

.nav-item {
    height: 100%;
    display: flex;
    align-items: center;
    position: relative;
}

.nav-link {
    font-family: var(--font-mono);
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text-muted);
    text-decoration: none;
    padding: 0.5rem 0;
    transition: color 0.2s;
    position: relative;
}

.nav-link::before, .nav-link::after {
    position: absolute;
    opacity: 0;
    color: var(--accent-primary);
    transition: all 0.3s var(--ease-out);
    font-weight: 700;
}

.nav-link::before { content: '<'; left: -12px; transform: translateX(10px); }
.nav-link::after { content: '/>'; right: -18px; transform: translateX(-10px); }

.nav-link:hover, .nav-link.active { color: var(--accent-primary); }

.nav-link:hover::before, .nav-link.active::before,
.nav-link:hover::after, .nav-link.active::after {
    opacity: 1;
    transform: translateX(0);
}

/* === Mega Menu (Intel Cache) === */
.mega-menu {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%) translateY(20px) scale(0.98);
    width: 850px;
    background: rgba(10, 25, 47, 0.98);
    border: 1px solid rgba(100, 255, 218, 0.2);
    border-top: 3px solid var(--accent-primary);
    border-radius: 0 0 8px 8px;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s var(--ease-out);
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
    display: grid;
    grid-template-columns: 280px 1fr;
    overflow: hidden;
}

.nav-item:hover .mega-menu {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0) scale(1);
}

/* Sidebar */
.mega-sidebar {
    background: rgba(2, 12, 27, 0.6);
    padding: 2rem;
    border-right: 1px solid rgba(100, 255, 218, 0.1);
    display: flex;
    flex-direction: column;
}

.sidebar-label {
    font-family: var(--font-mono);
    font-size: 0.7rem;
    color: var(--accent-primary);
    letter-spacing: 1px;
    margin-bottom: 1.5rem;
    opacity: 0.8;
}

.sidebar-content h3 {
    font-family: var(--font-sans);
    color: #fff;
    font-size: 1.4rem;
    line-height: 1.2;
    margin-bottom: 1rem;
}

.sidebar-content p {
    font-size: 0.85rem;
    color: var(--text-muted);
    line-height: 1.6;
    margin-bottom: 2rem;
}

.sidebar-metric {
    background: rgba(100, 255, 218, 0.05);
    border: 1px dashed rgba(100, 255, 218, 0.2);
    padding: 1rem;
    border-radius: 4px;
    margin-bottom: 2rem;
}

.metric-value {
    font-family: var(--font-mono);
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--accent-primary);
}

.metric-label {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.sidebar-link {
    font-family: var(--font-mono);
    font-size: 0.8rem;
    color: var(--accent-primary);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: gap 0.2s;
}

.sidebar-link:hover { gap: 12px; }

/* Grid */
.mega-grid {
    padding: 2rem;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
}

.mega-group-title {
    font-family: var(--font-mono);
    font-size: 0.7rem;
    color: var(--text-muted);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding-bottom: 0.5rem;
    margin-bottom: 1rem;
}

.mega-link {
    display: flex;
    gap: 12px;
    text-decoration: none;
    padding: 0.75rem;
    border-radius: 6px;
    transition: all 0.2s;
    border: 1px solid transparent;
}

.mega-link:hover {
    background: rgba(100, 255, 218, 0.05);
    border-color: rgba(100, 255, 218, 0.1);
    transform: translateX(4px);
}

/* Glitch Effect for Alert Items */
.mega-link.alert-hover:hover .mega-icon-box.alert {
    color: var(--accent-alert);
    animation: glitch-skew 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94) both infinite;
}

@keyframes glitch-skew {
    0% { transform: skew(0deg); }
    20% { transform: skew(-10deg); }
    40% { transform: skew(10deg); }
    60% { transform: skew(-5deg); }
    80% { transform: skew(5deg); }
    100% { transform: skew(0deg); }
}

.mega-icon-box {
    color: var(--accent-primary);
    font-size: 1.1rem;
    padding-top: 2px;
}

.mega-icon-box.alert { color: var(--text-muted); transition: color 0.3s; }

.mega-text h4 {
    color: var(--text-main);
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 2px;
}

.mega-link:hover h4 { color: var(--accent-primary); }
.mega-link.alert-hover:hover h4 { color: var(--accent-alert); }

.mega-text p {
    color: var(--text-muted);
    font-size: 0.75rem;
    margin: 0;
}

/* === CTA Button === */
.nav-cta { margin-left: 1.5rem; }

.scan-btn {
    position: relative;
    background: rgba(100, 255, 218, 0.05);
    border: 1px solid var(--accent-primary);
    color: var(--accent-primary);
    padding: 0.75rem 1.5rem;
    font-family: var(--font-mono);
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.5px;
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 10px;
    overflow: hidden;
    transition: all 0.3s;
}

.scan-btn:hover {
    background: rgba(100, 255, 218, 0.15);
    box-shadow: 0 0 20px rgba(100, 255, 218, 0.3);
    transform: translateY(-2px);
}

.scan-glare {
    position: absolute;
    top: 0; left: -100%;
    width: 50%; height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transform: skewX(-25deg);
    transition: left 0.5s;
}

.scan-btn:hover .scan-glare {
    left: 200%;
    transition: left 0.7s ease-in-out;
}

.status-dot-nav {
    width: 8px;
    height: 8px;
    background: var(--accent-alert);
    border-radius: 50%;
    box-shadow: 0 0 8px var(--accent-alert);
    animation: pulseAlert 1.5s infinite;
}

@keyframes pulseAlert {
    0% { opacity: 1; box-shadow: 0 0 0 0 rgba(255, 107, 107, 0.7); }
    70% { opacity: 0.8; box-shadow: 0 0 0 6px rgba(255, 107, 107, 0); }
    100% { opacity: 1; box-shadow: 0 0 0 0 rgba(255, 107, 107, 0); }
}

/* === Mobile Menu === */
.mobile-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    flex-direction: column;
    gap: 5px;
    width: 30px;
    padding: 0;
    z-index: 1005;
}

.mobile-toggle span {
    display: block;
    width: 100%;
    height: 2px;
    background: var(--accent-primary);
    transition: all 0.3s;
}

.mobile-panel {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100vh;
    background: rgba(2, 12, 27, 0.98);
    backdrop-filter: blur(15px);
    z-index: 1004;
    padding: 2rem;
    transform: translateX(100%);
    transition: transform 0.4s var(--ease-out);
    display: flex;
    flex-direction: column;
}

.mobile-panel.active { transform: translateX(0); }

.mobile-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 3rem;
}

.mobile-close {
    background: none;
    border: none;
    color: var(--text-muted);
    font-family: var(--font-mono);
    font-size: 0.9rem;
    cursor: pointer;
}

.mobile-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.mobile-item { margin-bottom: 1.5rem; }

.mobile-link, .mobile-accordion-trigger {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-main);
    text-decoration: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
}

.mobile-sub {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
    padding-left: 1rem;
    border-left: 1px solid rgba(255,255,255,0.1);
}

.mobile-sub a {
    display: block;
    color: var(--text-muted);
    padding: 10px 0;
    text-decoration: none;
    font-family: var(--font-mono);
    font-size: 0.9rem;
}

.mobile-actions {
    margin-top: auto;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.mobile-cta-btn {
    background: rgba(100, 255, 218, 0.1);
    color: var(--accent-primary);
    text-align: center;
    padding: 1rem;
    font-weight: 700;
    font-family: var(--font-mono);
    text-decoration: none;
    border: 1px solid var(--accent-primary);
}

.mobile-call-btn {
    color: var(--accent-alert);
    text-align: center;
    text-decoration: none;
    font-size: 0.9rem;
    font-weight: 600;
}

.mobile-footer {
    margin-top: 2rem;
    border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 1rem;
    font-family: var(--font-mono);
    font-size: 0.75rem;
    color: var(--text-muted);
    display: flex;
    justify-content: space-between;
}

.led.green {
    display: inline-block;
    width: 6px;
    height: 6px;
    background: #0f0;
    border-radius: 50%;
    box-shadow: 0 0 5px #0f0;
    margin-right: 5px;
}

/* Responsive Breakpoints */
@media (max-width: 1024px) {
    .ultra-nav-links, .nav-cta { display: none; }
    .mobile-toggle { display: flex; }
}
