/* Reset and base styles */
* {
    box-sizing: border-box;
}

body {
    margin: 0;
    padding: 0;
    overflow-x: hidden;
}

/* Grid pattern background */
.grid-pattern {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: 
        linear-gradient(rgba(0, 217, 255, 0.1) 1px, transparent 1px),
        linear-gradient(90deg, rgba(0, 217, 255, 0.1) 1px, transparent 1px);
    background-size: 50px 50px;
    animation: grid-move 20s linear infinite;
}

@keyframes grid-move {
    0% { transform: translate(0, 0); }
    100% { transform: translate(50px, 50px); }
}

/* Navigation blur effect */
#navbar {
    backdrop-filter: blur(10px);
    background: rgba(0, 0, 0, 0.8);
}

#navbar.scrolled {
    background: rgba(0, 0, 0, 0.95);
    backdrop-filter: blur(20px);
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #111111;
}

::-webkit-scrollbar-thumb {
    background: #333333;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #555555;
}

/* Gradient text selection */
::selection {
    background: rgba(0, 217, 255, 0.2);
    color: white;
}

/* Button hover effects */
.btn-glow:hover {
    box-shadow: 0 0 30px rgba(0, 217, 255, 0.5);
}

/* Card animations */
.capability-card {
    transition: all 0.3s ease;
}

.capability-card:hover {
    transform: translateY(-5px);
}

/* Floating animation for particles canvas */
#energy-particles {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}

/* Smooth scroll behavior */
html {
    scroll-behavior: smooth;
}

/* Additional hover effects for cards */
.group:hover .group-hover\:opacity-100 {
    opacity: 1 !important;
}

/* Feature pills animation */
.feature-pill {
    transition: all 0.3s ease;
}

.feature-pill:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 20px rgba(0, 217, 255, 0.3);
}

/* CTA button enhanced styling */
.cta-button {
    position: relative;
    overflow: hidden;
}

.cta-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.cta-button:hover::before {
    left: 100%;
}

/* Glass morphism effect */
.glass {
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .grid-pattern {
        background-size: 30px 30px;
    }
    
    #energy-particles {
        display: none; /* Hide particles on mobile for performance */
    }
}

/* Loading animation */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in-up {
    animation: fadeInUp 0.6s ease-out;
}

/* Stagger animation delays */
.delay-100 { animation-delay: 0.1s; }
.delay-200 { animation-delay: 0.2s; }
.delay-300 { animation-delay: 0.3s; }
.delay-400 { animation-delay: 0.4s; }

/* Enhanced glow effects */
.glow-cyan {
    box-shadow: 0 0 20px rgba(0, 217, 255, 0.3);
}

.glow-green {
    box-shadow: 0 0 20px rgba(0, 255, 136, 0.3);
}

.glow-blue {
    box-shadow: 0 0 20px rgba(59, 130, 246, 0.3);
}

.glow-purple {
    box-shadow: 0 0 20px rgba(168, 85, 247, 0.3);
}

/* Text shadow for better readability */
.text-shadow {
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

/* Pulse animation for accent elements */
@keyframes pulse-glow {
    0%, 100% {
        box-shadow: 0 0 5px rgba(0, 217, 255, 0.5);
    }
    50% {
        box-shadow: 0 0 20px rgba(0, 217, 255, 0.8);
    }
}

.pulse-glow {
    animation: pulse-glow 2s ease-in-out infinite;
}

/* Hero section enhancements */
.hero-content h1 {
    text-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

/* Capability card enhanced hover effects */
.capability-card {
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.capability-card:hover {
    border-color: rgba(0, 217, 255, 0.5);
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}

/* Footer enhancements */
footer {
    position: relative;
}

footer::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(0, 217, 255, 0.5), transparent);
}

/* Mobile navigation improvements */
@media (max-width: 767px) {
    .mobile-menu {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100vh;
        background: rgba(0, 0, 0, 0.95);
        backdrop-filter: blur(20px);
        z-index: 100;
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        transform: translateX(-100%);
        transition: transform 0.3s ease;
    }
    
    .mobile-menu.active {
        transform: translateX(0);
    }
    
    .mobile-menu a {
        font-size: 1.5rem;
        margin: 1rem 0;
        color: white;
        text-decoration: none;
        transition: color 0.3s ease;
    }
    
    .mobile-menu a:hover {
        color: #00D9FF;
    }
}

/* Performance optimizations */
.gpu-accelerated {
    transform: translateZ(0);
    will-change: transform;
}

/* Intersection observer fade-in */
.fade-in {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Enhanced button styling */
.btn-primary {
    background: linear-gradient(135deg, #00D9FF, #3B82F6);
    border: none;
    color: white;
    font-weight: 600;
    padding: 0.75rem 2rem;
    border-radius: 50px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(0, 217, 255, 0.4);
}

.btn-primary::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.btn-primary:active::after {
    width: 300px;
    height: 300px;
}