/* Enhanced Animations for Trancekraft4000 */

/* Neon glow effect */
@keyframes neonGlow {
    0% {
        text-shadow: 0 0 6px rgba(124, 31, 31, 0.4), 0 0 12px rgba(59, 175, 187, 0.25);
    }
    50% {
        text-shadow: 0 0 14px rgba(204, 69, 69, 0.45), 0 0 22px rgba(59, 175, 187, 0.35);
    }
    100% {
        text-shadow: 0 0 6px rgba(124, 31, 31, 0.4), 0 0 12px rgba(59, 175, 187, 0.25);
    }
}

/* Box glow effect */
@keyframes boxGlow {
    0% {
        box-shadow: 0 0 10px rgba(124, 31, 31, 0.35);
    }
    50% {
        box-shadow: 0 0 18px rgba(204, 69, 69, 0.45), 0 0 24px rgba(59, 175, 187, 0.3);
    }
    100% {
        box-shadow: 0 0 10px rgba(124, 31, 31, 0.35);
    }
}

/* Fade in animation */
@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* Slide in animations */
@keyframes slideInUp {
    from {
        transform: translateY(50px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

@keyframes slideInRight {
    from {
        transform: translateX(50px);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes slideInLeft {
    from {
        transform: translateX(-50px);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Pulse scale animation */
@keyframes pulseScale {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
    100% {
        transform: scale(1);
    }
}

/* Floating animation */
@keyframes float {
    0% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-10px);
    }
    100% {
        transform: translateY(0px);
    }
}

/* Border glow effect */
@keyframes borderGlow {
    0% {
        border-color: var(--primary-color);
    }
    50% {
        border-color: var(--secondary-color);
        box-shadow: 0 0 15px var(--secondary-color);
    }
    100% {
        border-color: var(--primary-color);
    }
}

/* Background pulse animation */
@keyframes backgroundPulse {
    0% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
    100% {
        background-position: 0% 50%;
    }
}

/* Loader animation */
@keyframes loaderBar {
    0% {
        width: 0%;
        background: var(--primary-color);
    }
    50% {
        background: var(--secondary-color);
    }
    100% {
        width: 100%;
        background: var(--primary-color);
    }
}

/* Shimmer effect for buttons */
@keyframes shimmer {
    0% {
        background-position: -200% 0;
    }
    100% {
        background-position: 200% 0;
    }
}

/* Applying animations to elements */

/* Text animations */
.neon-link {
    animation: neonGlow 2s infinite;
}

.fade-in-text {
    animation: fadeIn 1.5s ease-out;
}

/* Container animations */
.container-box,
.countdown-item,
.dj-list li {
    animation: boxGlow 4s infinite;
}

.hero-content {
    animation: fadeIn 1.5s ease-out;
}

/* Element sequence animations */
.dj-list li {
    animation: slideInUp 0.5s ease-out;
    animation-fill-mode: both;
}

/* Stagger DJ list items */
.dj-list li:nth-child(1) { animation-delay: 0.1s; }
.dj-list li:nth-child(2) { animation-delay: 0.2s; }
.dj-list li:nth-child(3) { animation-delay: 0.3s; }
.dj-list li:nth-child(4) { animation-delay: 0.4s; }
.dj-list li:nth-child(5) { animation-delay: 0.5s; }

/* Stagger spenden-type items */
.spenden-type:nth-child(1) { animation: slideInRight 0.5s ease-out; animation-delay: 0.1s; animation-fill-mode: both; }
.spenden-type:nth-child(2) { animation: slideInRight 0.5s ease-out; animation-delay: 0.2s; animation-fill-mode: both; }
.spenden-type:nth-child(3) { animation: slideInRight 0.5s ease-out; animation-delay: 0.3s; animation-fill-mode: both; }

/* Stagger kontakt-card items */
.kontakt-card:nth-child(1) { animation: slideInLeft 0.5s ease-out; animation-delay: 0.1s; animation-fill-mode: both; }
.kontakt-card:nth-child(2) { animation: slideInLeft 0.5s ease-out; animation-delay: 0.2s; animation-fill-mode: both; }
.kontakt-card:nth-child(3) { animation: slideInLeft 0.5s ease-out; animation-delay: 0.3s; animation-fill-mode: both; }

/* Button animations */
.cta-button {
    animation: pulseScale 2s infinite;
    background-size: 200% 100%;
    background-image: linear-gradient(90deg, 
        var(--primary-color) 0%, 
        var(--secondary-color) 25%,
        var(--secondary-color) 75%, 
        var(--primary-color) 100%);
    animation: backgroundPulse 5s infinite linear;
}

.spenden-button {
    animation: pulseScale 2s infinite;
}

/* Logo animation */
.main-logo {
    animation: float 4s ease-in-out infinite;
    filter: drop-shadow(0 0 15px var(--primary-color));
}

/* Loader bar */
.loader-bar {
    height: 5px;
    width: 0%;
    background: var(--primary-color);
    position: fixed;
    top: 0;
    left: 0;
    z-index: 9999;
    animation: loaderBar 2s forwards;
}

/* Scroll animation classes */
.reveal-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.reveal-on-scroll.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Stagger reveal for lists */
.reveal-list .reveal-item {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.reveal-list .reveal-item.visible {
    opacity: 1;
    transform: translateY(0);
}

.reveal-list .reveal-item:nth-child(1) { transition-delay: 0.1s; }
.reveal-list .reveal-item:nth-child(2) { transition-delay: 0.2s; }
.reveal-list .reveal-item:nth-child(3) { transition-delay: 0.3s; }
.reveal-list .reveal-item:nth-child(4) { transition-delay: 0.4s; }
.reveal-list .reveal-item:nth-child(5) { transition-delay: 0.5s; }

/* Background particles animation */
.particle {
    position: absolute;
    background-color: var(--secondary-color);
    border-radius: 50%;
    opacity: 0.3;
    animation: floatParticle 15s infinite linear;
}

@keyframes floatParticle {
    0% {
        transform: translateY(100vh) translateX(0);
        opacity: 0;
    }
    10% {
        opacity: 0.3;
    }
    90% {
        opacity: 0.2;
    }
    100% {
        transform: translateY(-20vh) translateX(20px);
        opacity: 0;
    }
}

/* Neon button pulse */
.neon-button {
    position: relative;
    display: inline-block;
    overflow: hidden;
}

.neon-button::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(204, 69, 69, 0.2);
    border-radius: inherit;
    transform: scale(0);
    opacity: 0;
    transition: transform 0.5s ease, opacity 0.5s ease;
    z-index: -1;
}

.neon-button:hover::after {
    transform: scale(1.2);
    opacity: 1;
}

/* Mobile-friendly animations */
@media (prefers-reduced-motion: reduce), (max-width: 768px) {
    .neon-link,
    .container-box,
    .countdown-item,
    .cta-button,
    .dj-list li,
    .spenden-type,
    .kontakt-card,
    .main-logo {
        /* Reduce or disable animations for better performance on mobile */
        animation-duration: 4s; /* Slower animations */
        animation-iteration-count: 2; /* Limited repeats */
    }
    
    /* Disable complex animations completely for very small devices */
    @media (max-width: 480px) {
        .particle,
        .neon-button::after {
            display: none;
        }
        
        .cta-button {
            animation: none;
            background: linear-gradient(45deg, var(--primary-color), var(--secondary-color));
        }
    }
}
