/* ============================================
   OLD BAR ROCK THEME - Animations Stylesheet
   ============================================ */

/* ============================================
   KEYFRAME ANIMATIONS
   ============================================ */

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

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

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

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

/* Scale Animations */
@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes scaleUp {
    from {
        transform: scale(1);
    }
    to {
        transform: scale(1.05);
    }
}

/* Neon Flicker Effect */
@keyframes flicker {
    0%, 19.999%, 22%, 62.999%, 64%, 64.999%, 70%, 100% {
        opacity: 1;
        text-shadow: 
            0 0 4px #fff,
            0 0 11px #fff,
            0 0 19px #fff,
            0 0 40px var(--bright-red),
            0 0 80px var(--bright-red),
            0 0 90px var(--bright-red),
            0 0 100px var(--bright-red),
            0 0 150px var(--bright-red);
    }
    20%, 21.999%, 63%, 63.999%, 65%, 69.999% {
        opacity: 0.6;
        text-shadow: none;
    }
}

/* Neon Pulse */
@keyframes neonPulse {
    0% {
        text-shadow: 
            0 0 5px #fff,
            0 0 10px #fff,
            0 0 20px var(--bright-red),
            0 0 30px var(--bright-red),
            0 0 40px var(--bright-red);
    }
    50% {
        text-shadow: 
            0 0 2px #fff,
            0 0 5px #fff,
            0 0 10px var(--bright-red),
            0 0 15px var(--bright-red),
            0 0 20px var(--bright-red);
    }
    100% {
        text-shadow: 
            0 0 5px #fff,
            0 0 10px #fff,
            0 0 20px var(--bright-red),
            0 0 30px var(--bright-red),
            0 0 40px var(--bright-red);
    }
}

/* Gold Glow Pulse */
@keyframes goldGlow {
    0%, 100% {
        text-shadow: 
            0 0 5px var(--gold),
            0 0 10px var(--gold),
            0 0 20px var(--amber);
    }
    50% {
        text-shadow: 
            0 0 10px var(--gold),
            0 0 20px var(--gold),
            0 0 40px var(--amber),
            0 0 60px var(--amber);
    }
}

/* Bounce Animation */
@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateX(-50%) translateY(0);
    }
    40% {
        transform: translateX(-50%) translateY(-20px);
    }
    60% {
        transform: translateX(-50%) translateY(-10px);
    }
}

/* Scroll Mouse Animation */
@keyframes scrollMouse {
    0% {
        opacity: 1;
        top: 10px;
    }
    100% {
        opacity: 0;
        top: 30px;
    }
}

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

/* Loading Bar Animation */
@keyframes loading {
    0% {
        transform: translateX(-100%);
    }
    100% {
        transform: translateX(300%);
    }
}

/* Rotate Animation */
@keyframes rotate {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

/* Float Animation */
@keyframes float {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-20px);
    }
}

/* Shake Animation */
@keyframes shake {
    0%, 100% {
        transform: translateX(0);
    }
    10%, 30%, 50%, 70%, 90% {
        transform: translateX(-5px);
    }
    20%, 40%, 60%, 80% {
        transform: translateX(5px);
    }
}

/* Glow Border Animation */
@keyframes glowBorder {
    0%, 100% {
        border-color: var(--gold);
        box-shadow: 0 0 5px var(--gold), inset 0 0 5px rgba(255, 215, 0, 0.1);
    }
    50% {
        border-color: var(--amber);
        box-shadow: 0 0 20px var(--gold), inset 0 0 10px rgba(255, 215, 0, 0.2);
    }
}

/* Typewriter Effect */
@keyframes typewriter {
    from {
        width: 0;
    }
    to {
        width: 100%;
    }
}

@keyframes blink {
    50% {
        border-color: transparent;
    }
}

/* Particle Float */
@keyframes particleFloat {
    0%, 100% {
        transform: translateY(0) rotate(0deg);
        opacity: 0;
    }
    10% {
        opacity: 1;
    }
    90% {
        opacity: 1;
    }
    100% {
        transform: translateY(-1000px) rotate(720deg);
        opacity: 0;
    }
}

/* Ember Rise Animation */
@keyframes emberRise {
    0% {
        transform: translateY(0) scale(1);
        opacity: 1;
    }
    100% {
        transform: translateY(-100vh) scale(0);
        opacity: 0;
    }
}

/* Wave Animation */
@keyframes wave {
    0%, 100% {
        transform: translateY(0);
    }
    25% {
        transform: translateY(-5px);
    }
    75% {
        transform: translateY(5px);
    }
}

/* Slide In Animations */
@keyframes slideInLeft {
    from {
        transform: translateX(-100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

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

@keyframes slideInUp {
    from {
        transform: translateY(100%);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* ============================================
   ANIMATION CLASSES
   ============================================ */

/* Fade In Animations */
.animate-fade-in {
    animation: fadeIn 0.6s ease forwards;
}

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

.animate-fade-in-down {
    animation: fadeInDown 0.6s ease forwards;
}

.animate-fade-in-left {
    animation: fadeInLeft 0.6s ease forwards;
}

.animate-fade-in-right {
    animation: fadeInRight 0.6s ease forwards;
}

/* Scale Animations */
.animate-scale-in {
    animation: scaleIn 0.5s ease forwards;
}

/* Neon Effects */
.neon-flicker {
    animation: flicker 3s infinite;
}

.neon-pulse {
    animation: neonPulse 2s infinite;
}

.gold-glow {
    animation: goldGlow 2s infinite;
}

/* Other Animations */
.animate-float {
    animation: float 3s ease-in-out infinite;
}

.animate-shake {
    animation: shake 0.5s ease-in-out;
}

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

.animate-glow-border {
    animation: glowBorder 2s infinite;
}

/* ============================================
   SCROLL REVEAL ANIMATIONS
   ============================================ */

.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s cubic-bezier(0.5, 0, 0, 1);
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

.reveal-left {
    opacity: 0;
    transform: translateX(-50px);
    transition: all 0.8s cubic-bezier(0.5, 0, 0, 1);
}

.reveal-left.active {
    opacity: 1;
    transform: translateX(0);
}

.reveal-right {
    opacity: 0;
    transform: translateX(50px);
    transition: all 0.8s cubic-bezier(0.5, 0, 0, 1);
}

.reveal-right.active {
    opacity: 1;
    transform: translateX(0);
}

.reveal-scale {
    opacity: 0;
    transform: scale(0.8);
    transition: all 0.8s cubic-bezier(0.5, 0, 0, 1);
}

.reveal-scale.active {
    opacity: 1;
    transform: scale(1);
}

/* Staggered Animations */
.stagger-1 { transition-delay: 0.1s; }
.stagger-2 { transition-delay: 0.2s; }
.stagger-3 { transition-delay: 0.3s; }
.stagger-4 { transition-delay: 0.4s; }
.stagger-5 { transition-delay: 0.5s; }
.stagger-6 { transition-delay: 0.6s; }
.stagger-7 { transition-delay: 0.7s; }
.stagger-8 { transition-delay: 0.8s; }

/* ============================================
   HOVER EFFECTS
   ============================================ */

/* Hover Lift */
.hover-lift {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hover-lift:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

/* Hover Glow */
.hover-glow {
    transition: all 0.3s ease;
}

.hover-glow:hover {
    box-shadow: 0 0 30px rgba(255, 215, 0, 0.3);
}

/* Hover Scale */
.hover-scale {
    transition: transform 0.3s ease;
}

.hover-scale:hover {
    transform: scale(1.05);
}

/* Hover Rotate */
.hover-rotate {
    transition: transform 0.5s ease;
}

.hover-rotate:hover {
    transform: rotate(5deg);
}

/* Hover Shine Effect */
.hover-shine {
    position: relative;
    overflow: hidden;
}

.hover-shine::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 ease;
}

.hover-shine:hover::before {
    left: 100%;
}

/* ============================================
   TEXT EFFECTS
   ============================================ */

/* Gradient Text */
.text-gradient {
    background: var(--gradient-gold);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Text Shadow Effects */
.text-shadow-glow {
    text-shadow: 0 0 10px currentColor, 0 0 20px currentColor;
}

.text-shadow-neon {
    text-shadow: 
        0 0 5px #fff,
        0 0 10px #fff,
        0 0 20px var(--bright-red),
        0 0 30px var(--bright-red);
}

/* Typewriter Effect */
.typewriter {
    overflow: hidden;
    white-space: nowrap;
    border-right: 3px solid var(--gold);
    animation: 
        typewriter 3s steps(40) 1s 1 normal both,
        blink 0.7s step-end infinite;
}

/* Split Text Animation */
.split-text span {
    display: inline-block;
    opacity: 0;
    animation: fadeInUp 0.5s ease forwards;
}

.split-text span:nth-child(1) { animation-delay: 0.1s; }
.split-text span:nth-child(2) { animation-delay: 0.15s; }
.split-text span:nth-child(3) { animation-delay: 0.2s; }
.split-text span:nth-child(4) { animation-delay: 0.25s; }
.split-text span:nth-child(5) { animation-delay: 0.3s; }
.split-text span:nth-child(6) { animation-delay: 0.35s; }
.split-text span:nth-child(7) { animation-delay: 0.4s; }
.split-text span:nth-child(8) { animation-delay: 0.45s; }
.split-text span:nth-child(9) { animation-delay: 0.5s; }
.split-text span:nth-child(10) { animation-delay: 0.55s; }

/* ============================================
   PARTICLE EFFECTS
   ============================================ */

.particle {
    position: absolute;
    width: 5px;
    height: 5px;
    background: var(--gold);
    border-radius: 50%;
    animation: emberRise 10s linear infinite;
    pointer-events: none;
}

.particle:nth-child(1) { left: 10%; animation-delay: 0s; }
.particle:nth-child(2) { left: 20%; animation-delay: 2s; }
.particle:nth-child(3) { left: 30%; animation-delay: 4s; }
.particle:nth-child(4) { left: 40%; animation-delay: 1s; }
.particle:nth-child(5) { left: 50%; animation-delay: 3s; }
.particle:nth-child(6) { left: 60%; animation-delay: 5s; }
.particle:nth-child(7) { left: 70%; animation-delay: 2.5s; }
.particle:nth-child(8) { left: 80%; animation-delay: 4.5s; }
.particle:nth-child(9) { left: 90%; animation-delay: 1.5s; }
.particle:nth-child(10) { left: 15%; animation-delay: 3.5s; }

/* Ember Particles */
.ember {
    position: absolute;
    width: 3px;
    height: 3px;
    background: var(--amber);
    border-radius: 50%;
    box-shadow: 0 0 6px var(--amber), 0 0 12px var(--bright-red);
    animation: emberRise 8s linear infinite;
}

/* ============================================
   IMAGE EFFECTS
   ============================================ */

/* Ken Burns Effect */
.ken-burns {
    overflow: hidden;
}

.ken-burns img {
    transition: transform 20s ease;
}

.ken-burns:hover img {
    transform: scale(1.2);
}

/* Image Overlay Effects */
.img-overlay {
    position: relative;
}

.img-overlay::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, transparent 50%, rgba(0, 0, 0, 0.8));
    pointer-events: none;
}

/* Parallax Wrapper */
.parallax-wrapper {
    overflow: hidden;
    position: relative;
}

.parallax-bg {
    position: absolute;
    top: -50%;
    left: 0;
    width: 100%;
    height: 200%;
    background-size: cover;
    background-position: center;
    will-change: transform;
}

/* ============================================
   BUTTON EFFECTS
   ============================================ */

/* Ripple Effect */
.btn-ripple {
    position: relative;
    overflow: hidden;
}

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

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

/* Magnetic Button */
.btn-magnetic {
    transition: transform 0.3s ease;
}

/* ============================================
   CARD EFFECTS
   ============================================ */

/* 3D Card Flip */
.card-flip {
    perspective: 1000px;
}

.card-flip-inner {
    position: relative;
    width: 100%;
    height: 100%;
    transition: transform 0.8s;
    transform-style: preserve-3d;
}

.card-flip:hover .card-flip-inner {
    transform: rotateY(180deg);
}

.card-flip-front,
.card-flip-back {
    position: absolute;
    width: 100%;
    height: 100%;
    backface-visibility: hidden;
}

.card-flip-back {
    transform: rotateY(180deg);
}

/* Card Tilt Effect */
.card-tilt {
    transform-style: preserve-3d;
    transition: transform 0.5s ease;
}

/* ============================================
   LOADING STATES
   ============================================ */

/* Skeleton Loading */
.skeleton {
    background: linear-gradient(
        90deg,
        rgba(255, 255, 255, 0.05) 25%,
        rgba(255, 255, 255, 0.1) 50%,
        rgba(255, 255, 255, 0.05) 75%
    );
    background-size: 200% 100%;
    animation: skeleton 1.5s ease-in-out infinite;
}

@keyframes skeleton {
    0% {
        background-position: 200% 0;
    }
    100% {
        background-position: -200% 0;
    }
}

/* Spinner */
.spinner {
    width: 40px;
    height: 40px;
    border: 3px solid rgba(255, 215, 0, 0.2);
    border-top-color: var(--gold);
    border-radius: 50%;
    animation: rotate 1s linear infinite;
}

/* ============================================
   MENU BADGE ANIMATIONS
   ============================================ */

.badge-pulse {
    animation: pulse 2s infinite;
}

.badge-new {
    position: relative;
}

.badge-new::after {
    content: '';
    position: absolute;
    top: -2px;
    right: -2px;
    width: 8px;
    height: 8px;
    background: var(--bright-red);
    border-radius: 50%;
    animation: pulse 1s infinite;
}

/* ============================================
   SPECIAL EFFECTS
   ============================================ */

/* Glitch Effect */
.glitch {
    position: relative;
}

.glitch::before,
.glitch::after {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.glitch::before {
    left: 2px;
    text-shadow: -2px 0 var(--bright-red);
    clip: rect(24px, 550px, 90px, 0);
    animation: glitch-anim-1 2s infinite linear alternate-reverse;
}

.glitch::after {
    left: -2px;
    text-shadow: -2px 0 var(--gold);
    clip: rect(85px, 550px, 140px, 0);
    animation: glitch-anim-2 2s infinite linear alternate-reverse;
}

@keyframes glitch-anim-1 {
    0% { clip: rect(64px, 9999px, 12px, 0); }
    20% { clip: rect(29px, 9999px, 87px, 0); }
    40% { clip: rect(73px, 9999px, 54px, 0); }
    60% { clip: rect(2px, 9999px, 67px, 0); }
    80% { clip: rect(45px, 9999px, 23px, 0); }
    100% { clip: rect(89px, 9999px, 5px, 0); }
}

@keyframes glitch-anim-2 {
    0% { clip: rect(43px, 9999px, 32px, 0); }
    20% { clip: rect(78px, 9999px, 65px, 0); }
    40% { clip: rect(12px, 9999px, 94px, 0); }
    60% { clip: rect(56px, 9999px, 21px, 0); }
    80% { clip: rect(34px, 9999px, 88px, 0); }
    100% { clip: rect(67px, 9999px, 43px, 0); }
}

/* Smoke Effect */
.smoke {
    position: relative;
}

.smoke::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 200 200"><circle cx="100" cy="100" r="50" fill="%23fff" opacity="0.03"/></svg>');
    animation: smoke 10s infinite;
    pointer-events: none;
}

@keyframes smoke {
    0%, 100% {
        transform: translateY(0) scale(1);
        opacity: 0;
    }
    50% {
        transform: translateY(-50px) scale(1.5);
        opacity: 0.5;
    }
}

/* Vignette Effect */
.vignette {
    position: relative;
}

.vignette::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    box-shadow: inset 0 0 150px rgba(0, 0, 0, 0.8);
    pointer-events: none;
}
