/* ========== KEYFRAME ANIMATIONS ========== */

@keyframes glowPulse {
    0%, 100% { transform: translate(-50%, -50%) scale(1); opacity: 0.5; }
    50% { transform: translate(-50%, -50%) scale(1.2); opacity: 1; }
}

@keyframes pulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.7; transform: scale(0.97); }
}

@keyframes loadProgress {
    from { width: 0%; }
    to { width: 100%; }
}

@keyframes badgeSlide {
    from { opacity: 0; transform: translateY(-20px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes dotPulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.5; transform: scale(0.8); }
}

@keyframes avatarFloat {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes avatarSpin {
    0%   { box-shadow: 0 0 40px rgba(99, 102, 241, 0.3), 0 0 80px rgba(99, 102, 241, 0.1); }
    25%  { box-shadow: 0 0 40px rgba(34, 211, 238, 0.3), 0 0 80px rgba(34, 211, 238, 0.1); }
    50%  { box-shadow: 0 0 40px rgba(244, 114, 182, 0.3), 0 0 80px rgba(244, 114, 182, 0.1); }
    75%  { box-shadow: 0 0 40px rgba(34, 211, 238, 0.3), 0 0 80px rgba(34, 211, 238, 0.1); }
    100% { box-shadow: 0 0 40px rgba(99, 102, 241, 0.3), 0 0 80px rgba(99, 102, 241, 0.1); }
}

@keyframes orbit {
    from { transform: translate(-50%, -50%) rotate(0deg); }
    to { transform: translate(-50%, -50%) rotate(360deg); }
}

@keyframes nameSlide {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes scrollWheel {
    0% { transform: translateY(0); opacity: 1; }
    100% { transform: translateY(12px); opacity: 0; }
}

@keyframes fadeInUp {
    from { opacity: 0; transform: translateX(-50%) translateY(20px); }
    to { opacity: 1; transform: translateX(-50%) translateY(0); }
}

@keyframes floatBob {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

/* ========== LOADER ========== */
#loader {
    position: fixed;
    inset: 0;
    background: var(--bg-dark);
    z-index: 100000;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 20px;
    transition: opacity 0.6s ease, visibility 0.6s ease;
}

#loader.hidden { opacity: 0; visibility: hidden; }

.loader-logo {
    font-size: 3rem;
    font-weight: 900;
    background: linear-gradient(135deg, var(--primary), var(--secondary), var(--accent));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: pulse 1s ease-in-out infinite;
}

.loader-bar { width: 200px; height: 3px; background: var(--bg-card2); border-radius: 10px; overflow: hidden; }
.loader-progress { height: 100%; background: linear-gradient(90deg, var(--primary), var(--secondary)); border-radius: 10px; animation: loadProgress 2.5s ease forwards; }

/* ========== CURSOR ========== */
.cursor {
    width: 12px; height: 12px;
    background: var(--primary);
    border-radius: 50%;
    position: fixed;
    top: 0; left: 0;
    pointer-events: none;
    z-index: 10000;
    transition: transform 0.1s ease;
    mix-blend-mode: difference;
}

.cursor-follower {
    width: 40px; height: 40px;
    border: 2px solid var(--primary);
    border-radius: 50%;
    position: fixed;
    top: 0; left: 0;
    pointer-events: none;
    z-index: 9999;
    transition: transform 0.15s ease, width 0.3s, height 0.3s;
    opacity: 0.6;
}

.cursor-follower.hovered {
    width: 60px; height: 60px;
    opacity: 0.3;
    border-color: var(--accent);
}

/* ========== MOUSE LIGHT ========== */
.mouse-light {
    position: fixed;
    width: 300px; height: 300px;
    background: radial-gradient(circle, rgba(99, 102, 241, 0.06) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
    z-index: 1;
    transform: translate(-50%, -50%);
    transition: opacity 0.3s ease;
}

/* ========== MOBILE MENU ========== */
.mobile-menu {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 999;
    background: rgba(3, 7, 18, 0.98);
    backdrop-filter: blur(20px);
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2rem;
}

.mobile-menu.open { display: flex; }

.mobile-menu a {
    color: var(--text-primary);
    text-decoration: none;
    font-size: 1.5rem;
    font-weight: 600;
    font-family: 'Space Grotesk', sans-serif;
    transition: color 0.3s;
}

.mobile-menu a:hover { color: var(--primary); }

.mobile-close {
    position: absolute;
    top: 1.5rem; right: 1.5rem;
    background: none;
    border: 1px solid var(--border);
    color: var(--text-primary);
    font-size: 1.2rem;
    padding: 0.5rem 0.75rem;
    border-radius: 8px;
    cursor: pointer;
}