/* ============================================
   FOODFRAME PREMIUM ANIMATIONS & EFFECTS
   ============================================ */

/* ===== KEYFRAME ANIMATIONS ===== */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-40px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-40px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(40px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes float {
    0%, 100% { 
        transform: translateY(0px) rotate(0deg); 
    }
    25% { 
        transform: translateY(-10px) rotate(1deg); 
    }
    50% { 
        transform: translateY(-20px) rotate(0deg); 
    }
    75% { 
        transform: translateY(-10px) rotate(-1deg); 
    }
}

@keyframes floatSlow {
    0%, 100% { 
        transform: translateY(0px); 
    }
    50% { 
        transform: translateY(-15px); 
    }
}

@keyframes pulse {
    0%, 100% { 
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(245, 196, 83, 0.4); 
    }
    50% { 
        transform: scale(1.05);
        box-shadow: 0 0 0 20px rgba(245, 196, 83, 0); 
    }
}

@keyframes glow {
    0%, 100% { 
        box-shadow: 0 0 20px rgba(245, 196, 83, 0.2); 
    }
    50% { 
        box-shadow: 0 0 40px rgba(245, 196, 83, 0.5); 
    }
}

@keyframes shimmer {
    0% { 
        background-position: -200% center; 
    }
    100% { 
        background-position: 200% center; 
    }
}

@keyframes gradientFlow {
    0% { 
        background-position: 0% 50%; 
    }
    50% { 
        background-position: 100% 50%; 
    }
    100% { 
        background-position: 0% 50%; 
    }
}

@keyframes spin {
    from { 
        transform: rotate(0deg); 
    }
    to { 
        transform: rotate(360deg); 
    }
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% { 
        transform: translateY(0); 
    }
    40% { 
        transform: translateY(-20px); 
    }
    60% { 
        transform: translateY(-10px); 
    }
}

@keyframes shake {
    0%, 100% { 
        transform: translateX(0); 
    }
    10%, 30%, 50%, 70%, 90% { 
        transform: translateX(-5px); 
    }
    20%, 40%, 60%, 80% { 
        transform: translateX(5px); 
    }
}

@keyframes heartbeat {
    0%, 100% { 
        transform: scale(1); 
    }
    14% { 
        transform: scale(1.1); 
    }
    28% { 
        transform: scale(1); 
    }
    42% { 
        transform: scale(1.1); 
    }
    70% { 
        transform: scale(1); 
    }
}

@keyframes slideInFromTop {
    from {
        transform: translateY(-100%);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

@keyframes slideInFromBottom {
    from {
        transform: translateY(100%);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

@keyframes zoomIn {
    from {
        transform: scale(0.5);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

@keyframes rotateIn {
    from {
        transform: rotate(-200deg) scale(0);
        opacity: 0;
    }
    to {
        transform: rotate(0deg) scale(1);
        opacity: 1;
    }
}

@keyframes ripple {
    0% {
        transform: scale(0);
        opacity: 1;
    }
    100% {
        transform: scale(4);
        opacity: 0;
    }
}

@keyframes particleFloat {
    0%, 100% {
        transform: translateY(0) translateX(0);
        opacity: 0.6;
    }
    25% {
        transform: translateY(-30px) translateX(20px);
        opacity: 1;
    }
    50% {
        transform: translateY(-50px) translateX(-10px);
        opacity: 0.8;
    }
    75% {
        transform: translateY(-30px) translateX(15px);
        opacity: 0.6;
    }
}

@keyframes typewriter {
    from { width: 0; }
    to { width: 100%; }
}

@keyframes blink {
    0%, 50% { opacity: 1; }
    51%, 100% { opacity: 0; }
}

@keyframes colorShift {
    0% { filter: hue-rotate(0deg); }
    50% { filter: hue-rotate(30deg); }
    100% { filter: hue-rotate(0deg); }
}

/* ===== SCROLL REVEAL CLASSES ===== */
.reveal {
    opacity: 0;
    transform: translateY(50px);
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.reveal.active {
    opacity: 1;
    transform: translateY(0);
}

.reveal-left {
    opacity: 0;
    transform: translateX(-50px);
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.reveal-left.active {
    opacity: 1;
    transform: translateX(0);
}

.reveal-right {
    opacity: 0;
    transform: translateX(50px);
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.reveal-right.active {
    opacity: 1;
    transform: translateX(0);
}

.reveal-scale {
    opacity: 0;
    transform: scale(0.8);
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.reveal-scale.active {
    opacity: 1;
    transform: scale(1);
}

/* ===== ANIMATION DELAYS ===== */
.delay-100 { transition-delay: 0.1s !important; animation-delay: 0.1s !important; }
.delay-200 { transition-delay: 0.2s !important; animation-delay: 0.2s !important; }
.delay-300 { transition-delay: 0.3s !important; animation-delay: 0.3s !important; }
.delay-400 { transition-delay: 0.4s !important; animation-delay: 0.4s !important; }
.delay-500 { transition-delay: 0.5s !important; animation-delay: 0.5s !important; }
.delay-600 { transition-delay: 0.6s !important; animation-delay: 0.6s !important; }
.delay-700 { transition-delay: 0.7s !important; animation-delay: 0.7s !important; }
.delay-800 { transition-delay: 0.8s !important; animation-delay: 0.8s !important; }

/* ===== HOVER ANIMATION CLASSES ===== */
.hover-float:hover {
    animation: floatSlow 3s ease-in-out infinite;
}

.hover-pulse:hover {
    animation: pulse 1s ease-in-out infinite;
}

.hover-glow:hover {
    animation: glow 1.5s ease-in-out infinite;
}

.hover-shake:hover {
    animation: shake 0.5s ease-in-out;
}

.hover-bounce:hover {
    animation: bounce 0.6s ease;
}

.hover-heartbeat:hover {
    animation: heartbeat 1s ease-in-out;
}

/* ===== BUTTON ANIMATIONS ===== */
.btn-animated {
    position: relative;
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.btn-animated::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.6s ease, height 0.6s ease;
}

.btn-animated:hover::before {
    width: 300px;
    height: 300px;
}

.btn-animated:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.btn-animated:active {
    transform: translateY(-1px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

/* ===== CARD ANIMATIONS ===== */
.card-animated {
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.card-animated:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.25);
}

.card-3d {
    perspective: 1000px;
    transform-style: preserve-3d;
    transition: transform 0.6s ease;
}

.card-3d:hover {
    transform: rotateY(10deg) rotateX(5deg);
}

/* ===== IMAGE ANIMATIONS ===== */
.img-zoom {
    overflow: hidden;
}

.img-zoom img {
    transition: transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.img-zoom:hover img {
    transform: scale(1.15);
}

.img-shine {
    position: relative;
    overflow: hidden;
}

.img-shine::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(
        to right,
        rgba(255, 255, 255, 0) 0%,
        rgba(255, 255, 255, 0.3) 50%,
        rgba(255, 255, 255, 0) 100%
    );
    transform: rotate(30deg);
    transition: 0.6s;
    opacity: 0;
}

.img-shine:hover::after {
    opacity: 1;
    left: 100%;
}

/* ===== TEXT ANIMATIONS ===== */
.text-gradient-animated {
    background: linear-gradient(
        90deg,
        #f5c453,
        #ff6b6b,
        #4ecdc4,
        #f5c453
    );
    background-size: 400%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: gradientFlow 4s ease infinite;
}

.text-glow {
    text-shadow: 
        0 0 10px rgba(245, 196, 83, 0.5),
        0 0 20px rgba(245, 196, 83, 0.3),
        0 0 30px rgba(245, 196, 83, 0.2);
}

/* ===== LOADING ANIMATIONS ===== */
.spinner {
    width: 40px;
    height: 40px;
    border: 3px solid rgba(245, 196, 83, 0.2);
    border-top-color: #f5c453;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

.dots-loading {
    display: flex;
    gap: 8px;
}

.dots-loading span {
    width: 10px;
    height: 10px;
    background: #f5c453;
    border-radius: 50%;
    animation: bounce 1.4s ease-in-out infinite;
}

.dots-loading span:nth-child(2) {
    animation-delay: 0.2s;
}

.dots-loading span:nth-child(3) {
    animation-delay: 0.4s;
}

/* ===== PARTICLE BACKGROUND ===== */
.particles-bg {
    position: relative;
    overflow: hidden;
}

.particle {
    position: absolute;
    width: 10px;
    height: 10px;
    background: rgba(245, 196, 83, 0.6);
    border-radius: 50%;
    animation: particleFloat 8s ease-in-out infinite;
}

.particle:nth-child(1) { left: 10%; animation-delay: 0s; }
.particle:nth-child(2) { left: 25%; animation-delay: 1s; }
.particle:nth-child(3) { left: 40%; animation-delay: 2s; }
.particle:nth-child(4) { left: 55%; animation-delay: 3s; }
.particle:nth-child(5) { left: 70%; animation-delay: 4s; }
.particle:nth-child(6) { left: 85%; animation-delay: 5s; }

/* ===== TOAST ANIMATIONS ===== */
.toast-animated {
    animation: slideInFromBottom 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.toast-animated.hide {
    animation: fadeInUp 0.4s cubic-bezier(0.4, 0, 0.2, 1) reverse forwards;
}

/* ===== MODAL ANIMATIONS ===== */
.modal-animated {
    animation: zoomIn 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.modal-backdrop-animated {
    animation: fadeInUp 0.3s ease;
}

/* ===== SCROLL INDICATOR ===== */
.scroll-indicator {
    position: fixed;
    top: 0;
    left: 0;
    width: 0%;
    height: 4px;
    background: linear-gradient(90deg, #f5c453, #ff6b6b);
    z-index: 9999;
    transition: width 0.1s ease;
}

/* ===== CURSOR EFFECTS ===== */
.custom-cursor {
    width: 20px;
    height: 20px;
    border: 2px solid #f5c453;
    border-radius: 50%;
    position: fixed;
    pointer-events: none;
    transition: transform 0.15s ease, border-color 0.3s ease;
    z-index: 9999;
    mix-blend-mode: difference;
}

.custom-cursor.hover {
    transform: scale(2);
    border-color: #ff6b6b;
}

/* ===== MAGNETIC BUTTON EFFECT ===== */
.magnetic-btn {
    transition: transform 0.3s ease;
}

/* ===== SMOOTH TRANSITIONS FOR INTERACTIVITY ===== */
* {
    -webkit-tap-highlight-color: transparent;
}

a, button, input, select, textarea {
    transition: all 0.3s ease;
}

/* ===== PRELOADER ANIMATIONS ===== */
.preloader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #121212;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 99999;
    transition: opacity 0.5s ease, visibility 0.5s ease;
}

.preloader.hide {
    opacity: 0;
    visibility: hidden;
}

.preloader-content {
    text-align: center;
}

.preloader-logo {
    font-size: 48px;
    animation: heartbeat 1.5s ease-in-out infinite;
}

.preloader-text {
    color: #f5c453;
    font-size: 24px;
    font-weight: 700;
    margin-top: 16px;
    animation: pulse 1.5s ease-in-out infinite;
}

/* ===== GLASSMORPHISM EFFECTS ===== */
.glass {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.glass-dark {
    background: rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* ===== NEON EFFECTS ===== */
.neon-text {
    color: #fff;
    text-shadow:
        0 0 7px #f5c453,
        0 0 10px #f5c453,
        0 0 21px #f5c453,
        0 0 42px #f5c453;
}

.neon-border {
    box-shadow:
        0 0 7px #f5c453,
        0 0 10px #f5c453,
        0 0 21px #f5c453,
        inset 0 0 7px #f5c453;
}

/* ===== MORPHING SHAPES ===== */
.morph-shape {
    border-radius: 60% 40% 30% 70% / 60% 30% 70% 40%;
    animation: morph 8s ease-in-out infinite;
}

@keyframes morph {
    0%, 100% {
        border-radius: 60% 40% 30% 70% / 60% 30% 70% 40%;
    }
    25% {
        border-radius: 30% 60% 70% 40% / 50% 60% 30% 60%;
    }
    50% {
        border-radius: 50% 60% 30% 60% / 30% 60% 70% 40%;
    }
    75% {
        border-radius: 60% 40% 60% 30% / 70% 30% 50% 60%;
    }
}

/* ===== PRICE TAG ANIMATION ===== */
.price-tag {
    position: relative;
    display: inline-block;
}

.price-tag::after {
    content: '🔥';
    position: absolute;
    top: -10px;
    right: -20px;
    font-size: 16px;
    animation: bounce 1s ease infinite;
}

/* ===== NOTIFICATION BADGE PULSE ===== */
.badge-pulse {
    position: relative;
}

.badge-pulse::after {
    content: '';
    position: absolute;
    top: 0;
    right: 0;
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background: inherit;
    animation: ripple 1.5s ease infinite;
    z-index: -1;
}

/* ===== SUCCESS/ERROR ANIMATIONS ===== */
.success-checkmark {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: linear-gradient(135deg, #4ecdc4, #44a08d);
    display: flex;
    align-items: center;
    justify-content: center;
    animation: zoomIn 0.5s ease;
}

.success-checkmark::after {
    content: '✓';
    font-size: 40px;
    color: white;
    animation: bounce 0.5s ease 0.3s;
}

.error-cross {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: linear-gradient(135deg, #ff6b6b, #ee5a5a);
    display: flex;
    align-items: center;
    justify-content: center;
    animation: zoomIn 0.5s ease;
}

.error-cross::after {
    content: '✕';
    font-size: 40px;
    color: white;
    animation: shake 0.5s ease 0.3s;
}

/* ===== COUNTDOWN TIMER ANIMATION ===== */
.countdown-digit {
    display: inline-block;
    animation: bounce 0.3s ease;
}

/* ===== 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: shimmer 1.5s infinite;
    border-radius: 8px;
}

.skeleton-text {
    height: 16px;
    margin-bottom: 8px;
}

.skeleton-image {
    height: 200px;
}

.skeleton-circle {
    width: 50px;
    height: 50px;
    border-radius: 50%;
}
