/* css/animation.css */
@keyframes animate-stars-1 { from { transform: translateY(0px); } to { transform: translateY(-200px); } }
@keyframes animate-stars-2 { from { transform: translateY(0px); } to { transform: translateY(-300px); } }
@keyframes animate-stars-3 { from { transform: translateY(0px); } to { transform: translateY(-400px); } }

#stars1 { animation: animate-stars-1 100s linear infinite; }
#stars2 { animation: animate-stars-2 150s linear infinite; }
#stars3 { animation: animate-stars-3 200s linear infinite; }

/* --- NEW: Logo Animations --- */
@keyframes reveal-letter {
    from { opacity: 0; transform: translateY(10px) scale(0.8); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes glitch-effect {
    0% { text-shadow: 0 0 5px var(--accent-glow); opacity: 1; }
    25% { text-shadow: -2px 2px 3px #ff4d4d, 2px -2px 3px #4dffff; opacity: 0.8; }
    50% { text-shadow: 2px 2px 3px #4dffff, -2px -2px 3px #ff4d4d; transform: translateX(-1px); }
    75% { text-shadow: 0 0 5px var(--accent-glow); transform: translateX(1px); opacity: 0.9; }
    100% { text-shadow: none; opacity: 1; }
}

.logo .char {
    display: inline-block;
    opacity: 0;
    animation: reveal-letter 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards;
}

.logo.is-glitching {
    animation: glitch-effect 0.4s linear;
}
/* --- End Logo Animations --- */

#scroll-progress-bar {
    position: fixed; top: 0; left: 0; height: 4px;
    background: linear-gradient(90deg, #4A90E2, #9013FE);
    width: 0%; z-index: 1001; transition: width 0.1s linear;
    box-shadow: 0 0 10px rgba(74, 144, 226, 0.7);
}

body::before {
    content: ''; position: fixed; top: 0; left: 50%; transform: translateX(-50%);
    width: 600px; height: 600px; background: radial-gradient(circle, var(--accent-glow), transparent 70%);
    filter: blur(100px); z-index: -1; opacity: 0.5; pointer-events: none;
}

.reveal {
    opacity: 0; transform: translateY(30px);
    transition: opacity 0.8s cubic-bezier(0.175, 0.885, 0.32, 1.275), 
                transform 0.8s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}
.reveal.active { opacity: 1; transform: translateY(0); }

.nav-menu { transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1); }
.theme-toggle:hover { transform: scale(1.1); }
.footer-links a { transition: color 0.2s ease; }
.footer-links a:hover { color: var(--accent-color); }

.tool-card {
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275), box-shadow 0.3s ease, border-color 0.3s ease;
}
.tool-card::before {
    content: ''; position: absolute; top: -50%; right: -50%; width: 100%; height: 100%;
    background: radial-gradient(circle at top right, var(--accent-glow), transparent 70%);
    transform: scale(0); transition: transform 0.5s ease; pointer-events: none; opacity: 0.5;
}
.tool-card:hover, .tool-card:focus-within {
    transform: translateY(-8px); box-shadow: 0 15px 35px rgba(0,0,0,0.2); border-color: rgba(74, 144, 226, 0.5);
}
.tool-card:hover::before { transform: scale(2); }