/* Legacy Shift V3 - Advanced Glow Navigation System */
/* DesignForge Premium Effects with Legacy Shift Branding */

/* ===== GLOW NAVIGATION BASE ===== */
.glow-nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 9999;
    height: 85px;
    overflow: hidden;
    
    /* Advanced performance optimization */
    will-change: transform, backdrop-filter;
    contain: layout style paint;
    transform: translateZ(0);
}

/* Advanced Glassmorphism Background */
.glow-nav-background {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    
    /* Premium glassmorphism */
    background: linear-gradient(135deg, 
        rgba(15, 20, 25, 0.85) 0%, 
        rgba(0, 188, 212, 0.15) 25%,
        rgba(26, 35, 50, 0.90) 50%,
        rgba(0, 188, 212, 0.10) 75%,
        rgba(15, 20, 25, 0.85) 100%);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    
    /* Advanced borders with glow */
    border-bottom: 1px solid rgba(0, 188, 212, 0.3);
    box-shadow: 
        0 8px 32px rgba(0, 0, 0, 0.3),
        0 2px 16px rgba(0, 188, 212, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
    
    /* Smooth transitions */
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Scroll state enhancement */
.glow-nav.scrolled .glow-nav-background {
    background: linear-gradient(135deg, 
        rgba(15, 20, 25, 0.95) 0%, 
        rgba(0, 188, 212, 0.20) 25%,
        rgba(26, 35, 50, 0.98) 50%,
        rgba(0, 188, 212, 0.15) 75%,
        rgba(15, 20, 25, 0.95) 100%);
    backdrop-filter: blur(30px) saturate(200%);
    border-bottom-color: rgba(0, 188, 212, 0.5);
    box-shadow: 
        0 12px 48px rgba(0, 0, 0, 0.4),
        0 4px 24px rgba(0, 188, 212, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.15);
}

/* Main Navigation Container */
.glow-nav-container {
    position: relative;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    z-index: 10;
}

/* ===== LOGO WITH ADVANCED GLOW ===== */
.glow-nav-logo {
    position: relative;
    display: flex;
    align-items: center;
    text-decoration: none;
    z-index: 12;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.glow-logo-icon {
    position: relative;
    width: 45px;
    height: 45px;
    margin-right: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    overflow: hidden;
    
    /* Premium gradient background */
    background: linear-gradient(135deg, #00BCD4 0%, #26A69A 100%);
    box-shadow: 
        0 4px 16px rgba(0, 188, 212, 0.3),
        0 2px 8px rgba(0, 188, 212, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
    
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.glow-logo-icon i {
    font-size: 1.4rem;
    color: white;
    position: relative;
    z-index: 2;
    transition: all 0.3s ease;
}

/* Logo Particles Effect */
.glow-logo-particles {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    opacity: 0;
    background: radial-gradient(circle at 30% 40%, rgba(0, 188, 212, 0.8) 0%, transparent 70%),
                radial-gradient(circle at 70% 70%, rgba(38, 166, 154, 0.6) 0%, transparent 60%),
                radial-gradient(circle at 50% 20%, rgba(0, 188, 212, 0.4) 0%, transparent 50%);
    animation: logoParticles 3s ease-in-out infinite;
    transition: opacity 0.3s ease;
}

@keyframes logoParticles {
    0%, 100% { transform: scale(1) rotate(0deg); opacity: 0; }
    25% { transform: scale(1.1) rotate(90deg); opacity: 0.7; }
    50% { transform: scale(1.05) rotate(180deg); opacity: 0.5; }
    75% { transform: scale(1.15) rotate(270deg); opacity: 0.8; }
}

.glow-logo-text {
    font-weight: 700;
    font-size: 1.5rem;
    color: #ffffff;
    text-shadow: 
        0 2px 4px rgba(0, 0, 0, 0.3),
        0 0 10px rgba(0, 188, 212, 0.3);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Logo underline effect */
.glow-logo-underline {
    position: absolute;
    bottom: -2px;
    left: 60px;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, #00BCD4, transparent);
    border-radius: 2px;
    opacity: 0;
    transform: scaleX(0);
    transform-origin: left;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Logo hover effects */
.glow-nav-logo:hover .glow-logo-icon {
    transform: translateY(-2px) scale(1.05);
    box-shadow: 
        0 8px 24px rgba(0, 188, 212, 0.4),
        0 4px 12px rgba(0, 188, 212, 0.3),
        inset 0 2px 0 rgba(255, 255, 255, 0.4);
}

.glow-nav-logo:hover .glow-logo-particles {
    opacity: 1;
}

.glow-nav-logo:hover .glow-logo-text {
    color: #00BCD4;
    text-shadow: 
        0 2px 4px rgba(0, 0, 0, 0.4),
        0 0 20px rgba(0, 188, 212, 0.6),
        0 0 40px rgba(0, 188, 212, 0.3);
}

.glow-nav-logo:hover .glow-logo-underline {
    opacity: 1;
    transform: scaleX(1);
}

/* ===== NAVIGATION LINKS WITH GLOW ===== */
.glow-nav-links {
    display: flex;
    align-items: center;
    list-style: none;
    gap: 0.5rem;
    margin: 0;
    padding: 0;
}

.glow-nav-item {
    position: relative;
}

.glow-nav-link {
    position: relative;
    display: block;
    padding: 0.75rem 1.5rem;
    text-decoration: none;
    color: rgba(255, 255, 255, 0.8);
    font-weight: 500;
    font-size: 0.95rem;
    border-radius: 10px;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1;
}

.glow-link-text {
    position: relative;
    z-index: 3;
    transition: all 0.3s ease;
}

/* Link background glow */
.glow-link-bg {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, 
        rgba(0, 188, 212, 0.1) 0%, 
        rgba(38, 166, 154, 0.05) 100%);
    opacity: 0;
    transform: scale(0.8);
    border-radius: 10px;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1;
}

/* Link border glow */
.glow-link-border {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border: 1px solid rgba(0, 188, 212, 0);
    border-radius: 10px;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 2;
}

/* Link hover effects */
.glow-nav-link:hover {
    color: #00BCD4;
    transform: translateY(-1px);
    text-shadow: 0 0 10px rgba(0, 188, 212, 0.5);
}

.glow-nav-link:hover .glow-link-bg {
    opacity: 1;
    transform: scale(1);
    box-shadow: 
        0 4px 16px rgba(0, 188, 212, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.glow-nav-link:hover .glow-link-border {
    border-color: rgba(0, 188, 212, 0.5);
    box-shadow: 
        0 0 20px rgba(0, 188, 212, 0.3),
        inset 0 0 20px rgba(0, 188, 212, 0.1);
}

/* Active link state */
.glow-nav-link.active {
    color: #00BCD4;
    text-shadow: 0 0 10px rgba(0, 188, 212, 0.6);
}

.glow-nav-link.active .glow-link-bg {
    opacity: 1;
    transform: scale(1);
    background: linear-gradient(135deg, 
        rgba(0, 188, 212, 0.2) 0%, 
        rgba(38, 166, 154, 0.1) 100%);
    box-shadow: 
        0 4px 16px rgba(0, 188, 212, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.15);
}

.glow-nav-link.active .glow-link-border {
    border-color: rgba(0, 188, 212, 0.6);
    box-shadow: 
        0 0 20px rgba(0, 188, 212, 0.4),
        inset 0 0 20px rgba(0, 188, 212, 0.15);
}

/* ===== CTA BUTTON WITH PREMIUM GLOW ===== */
.glow-nav-cta {
    position: relative;
    display: inline-block;
    padding: 0.75rem 2rem;
    text-decoration: none;
    color: white;
    font-weight: 600;
    font-size: 0.95rem;
    border-radius: 12px;
    overflow: hidden;
    background: linear-gradient(135deg, #00BCD4 0%, #26A69A 100%);
    box-shadow: 
        0 4px 16px rgba(0, 188, 212, 0.3),
        0 2px 8px rgba(0, 188, 212, 0.2);
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1;
}

.glow-cta-text {
    position: relative;
    z-index: 4;
    transition: all 0.3s ease;
}

/* CTA background animation */
.glow-cta-bg {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, #26A69A 0%, #00BCD4 100%);
    opacity: 0;
    transition: all 0.3s ease;
    z-index: 1;
}

/* CTA particles effect */
.glow-cta-particles {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    opacity: 0;
    background: 
        radial-gradient(circle at 20% 80%, rgba(255, 255, 255, 0.3) 0%, transparent 50%),
        radial-gradient(circle at 80% 20%, rgba(255, 255, 255, 0.2) 0%, transparent 50%),
        radial-gradient(circle at 40% 40%, rgba(255, 255, 255, 0.1) 0%, transparent 50%);
    animation: ctaParticles 2s ease-in-out infinite;
    z-index: 2;
}

@keyframes ctaParticles {
    0%, 100% { transform: scale(1) rotate(0deg); opacity: 0; }
    50% { transform: scale(1.1) rotate(180deg); opacity: 1; }
}

/* CTA shine effect */
.glow-cta-shine {
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, 
        transparent, 
        rgba(255, 255, 255, 0.3), 
        transparent);
    transition: left 0.6s ease;
    z-index: 3;
}

/* CTA hover effects */
.glow-nav-cta:hover {
    transform: translateY(-2px) scale(1.02);
    box-shadow: 
        0 8px 32px rgba(0, 188, 212, 0.4),
        0 4px 16px rgba(0, 188, 212, 0.3),
        0 0 0 1px rgba(255, 255, 255, 0.2);
}

.glow-nav-cta:hover .glow-cta-bg {
    opacity: 1;
}

.glow-nav-cta:hover .glow-cta-particles {
    opacity: 1;
}

.glow-nav-cta:hover .glow-cta-shine {
    left: 100%;
}

/* ===== MOBILE TOGGLE WITH GLOW ===== */
.glow-nav-toggle {
    display: none;
    position: relative;
    width: 50px;
    height: 50px;
    cursor: pointer;
    border-radius: 10px;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.glow-toggle-icon {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 5px;
    z-index: 2;
}

.glow-toggle-line {
    width: 24px;
    height: 2px;
    background: rgba(255, 255, 255, 0.8);
    border-radius: 2px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    transform-origin: center;
}

.glow-toggle-bg {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, 
        rgba(0, 188, 212, 0.1) 0%, 
        rgba(38, 166, 154, 0.05) 100%);
    opacity: 0;
    border-radius: 10px;
    border: 1px solid rgba(0, 188, 212, 0);
    transition: all 0.3s ease;
    z-index: 1;
}

/* Mobile toggle hover */
.glow-nav-toggle:hover .glow-toggle-bg {
    opacity: 1;
    border-color: rgba(0, 188, 212, 0.3);
    box-shadow: 0 0 20px rgba(0, 188, 212, 0.2);
}

.glow-nav-toggle:hover .glow-toggle-line {
    background: #00BCD4;
    box-shadow: 0 0 10px rgba(0, 188, 212, 0.5);
}

/* Mobile toggle active state */
.glow-nav-toggle.active .glow-toggle-line:nth-child(1) {
    transform: rotate(45deg) translate(6px, 6px);
}

.glow-nav-toggle.active .glow-toggle-line:nth-child(2) {
    opacity: 0;
    transform: scale(0);
}

.glow-nav-toggle.active .glow-toggle-line:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
}

/* ===== MOBILE MENU WITH GLOW ===== */
.glow-nav-mobile {
    position: fixed;
    top: 85px;
    left: 0;
    right: 0;
    max-height: 0;
    overflow: hidden;
    z-index: 9998;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.glow-nav-mobile.active {
    max-height: 100vh;
}

.glow-mobile-bg {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(180deg, 
        rgba(15, 20, 25, 0.95) 0%, 
        rgba(26, 35, 50, 0.98) 100%);
    backdrop-filter: blur(20px) saturate(180%);
    border-bottom: 1px solid rgba(0, 188, 212, 0.3);
    box-shadow: 
        0 8px 32px rgba(0, 0, 0, 0.3),
        0 0 40px rgba(0, 188, 212, 0.1);
}

.glow-nav-mobile-links {
    position: relative;
    list-style: none;
    padding: 2rem;
    margin: 0;
    z-index: 2;
}

.glow-mobile-item {
    margin-bottom: 0.5rem;
}

.glow-mobile-link {
    position: relative;
    display: block;
    padding: 1rem 1.5rem;
    text-decoration: none;
    color: rgba(255, 255, 255, 0.8);
    font-weight: 500;
    font-size: 1.1rem;
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.glow-mobile-text {
    position: relative;
    z-index: 2;
    transition: all 0.3s ease;
}

.glow-mobile-link-bg {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, 
        rgba(0, 188, 212, 0.1) 0%, 
        rgba(38, 166, 154, 0.05) 100%);
    opacity: 0;
    border: 1px solid rgba(0, 188, 212, 0);
    border-radius: 12px;
    transition: all 0.3s ease;
    z-index: 1;
}

.glow-mobile-link:hover {
    color: #00BCD4;
    text-shadow: 0 0 10px rgba(0, 188, 212, 0.5);
}

.glow-mobile-link:hover .glow-mobile-link-bg {
    opacity: 1;
    border-color: rgba(0, 188, 212, 0.3);
    box-shadow: 0 0 20px rgba(0, 188, 212, 0.2);
}

.glow-mobile-link.active {
    color: #00BCD4;
    text-shadow: 0 0 15px rgba(0, 188, 212, 0.6);
}

.glow-mobile-link.active .glow-mobile-link-bg {
    opacity: 1;
    border-color: rgba(0, 188, 212, 0.5);
    box-shadow: 0 0 25px rgba(0, 188, 212, 0.3);
}

/* Mobile CTA */
.glow-mobile-cta-container {
    position: relative;
    padding: 0 2rem 2rem;
    z-index: 2;
}

.glow-mobile-cta {
    position: relative;
    display: block;
    width: 100%;
    padding: 1rem;
    text-decoration: none;
    color: white;
    font-weight: 600;
    font-size: 1.1rem;
    text-align: center;
    border-radius: 12px;
    background: linear-gradient(135deg, #00BCD4 0%, #26A69A 100%);
    box-shadow: 
        0 4px 16px rgba(0, 188, 212, 0.3),
        0 2px 8px rgba(0, 188, 212, 0.2);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
}

.glow-mobile-cta-text {
    position: relative;
    z-index: 2;
}

.glow-mobile-cta-bg {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, #26A69A 0%, #00BCD4 100%);
    opacity: 0;
    transition: all 0.3s ease;
    z-index: 1;
}

.glow-mobile-cta:hover {
    transform: translateY(-2px);
    box-shadow: 
        0 8px 24px rgba(0, 188, 212, 0.4),
        0 4px 12px rgba(0, 188, 212, 0.3);
}

.glow-mobile-cta:hover .glow-mobile-cta-bg {
    opacity: 1;
}

/* ===== SCROLL PROGRESS WITH GLOW ===== */
.glow-nav-progress {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 3px;
    width: 0%;
    background: linear-gradient(90deg, #00BCD4 0%, #26A69A 100%);
    box-shadow: 
        0 0 10px rgba(0, 188, 212, 0.5),
        0 2px 20px rgba(0, 188, 212, 0.3);
    transition: width 0.1s ease-out;
    z-index: 11;
}

/* ===== RESPONSIVE DESIGN ===== */
@media (max-width: 768px) {
    .glow-nav {
        height: 75px;
    }
    
    .glow-nav-container {
        padding: 0 1.5rem;
    }
    
    .glow-nav-links,
    .glow-nav-cta {
        display: none;
    }
    
    .glow-nav-toggle {
        display: block;
    }
    
    .glow-nav-mobile {
        top: 75px;
    }
    
    .glow-logo-icon {
        width: 40px;
        height: 40px;
        margin-right: 0.5rem;
    }
    
    .glow-logo-text {
        font-size: 1.3rem;
    }
}

@media (max-width: 480px) {
    .glow-nav-container {
        padding: 0 1rem;
    }
    
    .glow-nav-mobile-links {
        padding: 1.5rem;
    }
    
    .glow-mobile-cta-container {
        padding: 0 1.5rem 1.5rem;
    }
    
    .glow-logo-icon {
        width: 35px;
        height: 35px;
    }
    
    .glow-logo-text {
        font-size: 1.2rem;
    }
    
    .glow-nav-toggle {
        width: 45px;
        height: 45px;
    }
    
    .glow-toggle-line {
        width: 20px;
    }
}

/* ===== PERFORMANCE OPTIMIZATIONS ===== */
.glow-nav *,
.glow-nav *::before,
.glow-nav *::after {
    will-change: auto;
}

.glow-nav-link:hover,
.glow-nav-cta:hover,
.glow-mobile-link:hover {
    will-change: transform;
}

/* Reduced Motion Support */
@media (prefers-reduced-motion: reduce) {
    .glow-nav * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    .glow-logo-particles,
    .glow-cta-particles {
        display: none;
    }
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    .glow-nav-background {
        background: rgba(0, 0, 0, 0.95);
        border-bottom-color: #00BCD4;
    }
    
    .glow-nav-link,
    .glow-mobile-link {
        color: white;
    }
    
    .glow-nav-link:hover,
    .glow-mobile-link:hover {
        background: rgba(0, 188, 212, 0.3);
    }
}