/* Animated Star Background */
.star-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
    background: linear-gradient(to bottom, #0a0f1e, #1a1b4b);
}

.stars {
    position: absolute;
    width: 100%;
    height: 100%;
}

.star {
    position: absolute;
    background-color: #fff;
    border-radius: 50%;
    animation: twinkle var(--duration) infinite;
    opacity: 0;
    box-shadow: 0 0 4px rgba(255, 255, 255, 0.5);
}

.star.small {
    background-color: #fff;
}

.star.medium {
    background-color: #a8d8ff;
    box-shadow: 0 0 6px rgba(168, 216, 255, 0.6);
}

.star.large {
    background-color: #ffd700;
    box-shadow: 0 0 8px rgba(255, 215, 0, 0.7);
}

@keyframes twinkle {
    0%, 100% {
        opacity: 0;
        transform: scale(0.5);
    }
    50% {
        opacity: var(--opacity);
        transform: scale(1);
    }
}

/* Shooting stars */
.shooting-star {
    position: absolute;
    width: 150px;
    height: 2px;
    background: linear-gradient(90deg, 
        rgba(255,255,255,0) 0%, 
        rgba(255,255,255,0.8) 50%, 
        rgba(255,255,255,0) 100%);
    animation: shoot var(--duration) linear infinite;
    opacity: 0;
    box-shadow: 0 0 8px rgba(255, 255, 255, 0.8);
}

.shooting-star::after {
    content: '';
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 20px;
    height: 20px;
    background: radial-gradient(circle, rgba(255,255,255,0.8) 0%, rgba(255,255,255,0) 70%);
    border-radius: 50%;
}

@keyframes shoot {
    0% {
        transform: translateX(-100%) translateY(0) rotate(45deg);
        opacity: 0;
    }
    10% {
        opacity: 1;
    }
    70% {
        opacity: 1;
    }
    100% {
        transform: translateX(200%) translateY(200%) rotate(45deg);
        opacity: 0;
    }
}

/* Nebula effect */
.nebula {
    position: absolute;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at 50% 50%,
        rgba(76, 0, 255, 0.1) 0%,
        rgba(0, 0, 0, 0) 70%);
    animation: nebula-pulse 20s infinite alternate;
}

@keyframes nebula-pulse {
    0% {
        opacity: 0.3;
        transform: scale(1);
    }
    100% {
        opacity: 0.6;
        transform: scale(1.2);
    }
}

/* Interactive Particle Network Background */
.particle-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
    background: linear-gradient(135deg, #0a0f1e 0%, #1a1b4b 100%);
}

#particles-js {
    position: absolute;
    width: 100%;
    height: 100%;
}

/* Particle customization */
#particles-js canvas {
    display: block;
    vertical-align: bottom;
    -webkit-transform: scale(1);
    -ms-transform: scale(1);
    transform: scale(1);
    opacity: 0.8;
    transition: opacity 0.3s ease;
}

#particles-js canvas:hover {
    opacity: 1;
}

/* Gradient overlay */
.particle-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at center,
        rgba(99, 102, 241, 0.1) 0%,
        rgba(139, 92, 246, 0.05) 50%,
        rgba(0, 0, 0, 0) 70%);
    pointer-events: none;
    animation: pulse 8s infinite alternate;
}

@keyframes pulse {
    0% {
        opacity: 0.5;
        transform: scale(1);
    }
    100% {
        opacity: 0.8;
        transform: scale(1.1);
    }
}

/* Mouse trail particles */
.trail-particle {
    position: fixed;
    pointer-events: none;
    width: 8px;
    height: 8px;
    background: radial-gradient(circle, 
        rgba(99, 102, 241, 0.8) 0%,
        rgba(139, 92, 246, 0.4) 50%,
        rgba(217, 70, 239, 0) 100%);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    animation: trail 1s ease-out forwards;
    z-index: 9999;
}

@keyframes trail {
    0% {
        transform: translate(-50%, -50%) scale(1);
        opacity: 1;
    }
    100% {
        transform: translate(-50%, -50%) scale(0);
        opacity: 0;
    }
}

/* Glow effect for particles */
.particle-glow {
    position: absolute;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at center,
        rgba(99, 102, 241, 0.2) 0%,
        rgba(139, 92, 246, 0.1) 50%,
        rgba(0, 0, 0, 0) 70%);
    filter: blur(20px);
    pointer-events: none;
    animation: glow 4s infinite alternate;
}

@keyframes glow {
    0% {
        opacity: 0.3;
        transform: scale(1);
    }
    100% {
        opacity: 0.6;
        transform: scale(1.2);
    }
} 