/* ========== PREMIUM ANIMATIONS & TRANSITIONS ========== */

/* Smooth page load fade-in */
@keyframes pageLoad {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

body {
    animation: pageLoad 0.6s ease-out;
}

/* Enhanced Product Card 3D Hover */
.product-card {
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    transform-style: preserve-3d;
    position: relative;
}

.product-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(211, 19, 19, 0.1), rgba(212, 175, 55, 0.1));
    opacity: 0;
    transition: opacity 0.4s ease;
    border-radius: 12px;
    z-index: -1;
}

.product-card:hover {
    transform: translateY(-15px) scale(1.03);
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.25),
        0 0 40px rgba(211, 19, 19, 0.1);
}

.product-card:hover::before {
    opacity: 1;
}

/* Image zoom on hover */
.product-img {
    transition: transform 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.product-card:hover .product-img {
    transform: scale(1.1) rotate(2deg);
}

/* Button ripple effect */
.btn {
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.btn:hover::before {
    width: 300px;
    height: 300px;
}

.btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 35px rgba(211, 19, 19, 0.3);
}

/* Gradient animation background */
@keyframes gradientShift {
    0% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }

    100% {
        background-position: 0% 50%;
    }
}

.hero {
    position: relative;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(45deg,
            rgba(211, 19, 19, 0.1),
            rgba(212, 175, 55, 0.1),
            rgba(10, 10, 10, 0.1),
            rgba(211, 19, 19, 0.1));
    background-size: 300% 300%;
    animation: gradientShift 15s ease infinite;
    pointer-events: none;
    z-index: 1;
}

.hero-content {
    position: relative;
    z-index: 2;
}

/* Scroll reveal animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.scroll-reveal {
    opacity: 0;
    animation: fadeInUp 0.8s ease forwards;
}

.scroll-reveal.delay-1 {
    animation-delay: 0.1s;
}

.scroll-reveal.delay-2 {
    animation-delay: 0.2s;
}

.scroll-reveal.delay-3 {
    animation-delay: 0.3s;
}

/* Stagger grid animation */
.product-grid.animate .product-card {
    animation: fadeInUp 0.6s ease backwards;
}

.product-grid.animate .product-card:nth-child(1) {
    animation-delay: 0.1s;
}

.product-grid.animate .product-card:nth-child(2) {
    animation-delay: 0.2s;
}

.product-grid.animate .product-card:nth-child(3) {
    animation-delay: 0.3s;
}

.product-grid.animate .product-card:nth-child(4) {
    animation-delay: 0.4s;
}

.product-grid.animate .product-card:nth-child(5) {
    animation-delay: 0.5s;
}

.product-grid.animate .product-card:nth-child(6) {
    animation-delay: 0.6s;
}

/* Navigation link underline animation */
.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--primary-red), var(--accent-gold));
    transition: width 0.3s ease;
}

.nav-link:hover::after,
.nav-link.active-link::after {
    width: 100%;
}

/* Pulse animation for CTA */
@keyframes pulse {

    0%,
    100% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(211, 19, 19, 0.7);
    }

    50% {
        transform: scale(1.05);
        box-shadow: 0 0 0 20px rgba(211, 19, 19, 0);
    }
}

.btn-primary {
    animation: pulse 2s infinite;
}

/* Floating animation */
@keyframes float {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-10px);
    }
}

.shopee-logo-float {
    animation: float 3s ease-in-out infinite;
}

/* Section title glow effect */
.section-title {
    position: relative;
    display: inline-block;
    transition: all 0.3s ease;
}

.section-title:hover {
    text-shadow: 0 0 20px rgba(211, 19, 19, 0.3),
        0 0 40px rgba(212, 175, 55, 0.2);
}

/* Image lazy load fade-in */
@keyframes imageFadeIn {
    from {
        opacity: 0;
        filter: blur(10px);
    }

    to {
        opacity: 1;
        filter: blur(0);
    }
}

img[loading="lazy"] {
    animation: imageFadeIn 0.6s ease;
}

/* Retailer card entrance */
.retailer-card {
    transition: all 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

.retailer-card:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.15);
}

/* WhatsApp button pulse */
.whatsapp-float {
    animation: pulse 2s infinite;
}

/* Parallax text effect */
.page-header h1 {
    transition: transform 0.3s ease;
}

/* Smooth scroll behavior */
html {
    scroll-behavior: smooth;
}

/* Link hover glow */
a {
    transition: all 0.3s ease;
}

a:hover {
    filter: brightness(1.2);
    text-shadow: 0 0 10px rgba(211, 19, 19, 0.3);
}

/* Category button slide effect */
.cat-nav-btn {
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.cat-nav-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: left 0.5s ease;
}

.cat-nav-btn:hover::before {
    left: 100%;
}

/* Loading spinner for images */
.product-image-container {
    position: relative;
}

.product-image-container::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 40px;
    height: 40px;
    margin: -20px 0 0 -20px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid var(--primary-red);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    opacity: 0;
    transition: opacity 0.3s;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

/* Overlay slide animation */
.product-overlay {
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.product-card:hover .product-overlay {
    background: linear-gradient(135deg,
            rgba(211, 19, 19, 0.95),
            rgba(212, 175, 55, 0.95));
}

/* Icon animations */
@keyframes bounce {

    0%,
    20%,
    50%,
    80%,
    100% {
        transform: translateY(0);
    }

    40% {
        transform: translateY(-10px);
    }

    60% {
        transform: translateY(-5px);
    }
}

.btn-closer-look:hover {
    animation: bounce 0.6s;
}

/* Gradient text animation */
@keyframes gradientText {

    0%,
    100% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }
}

.hero-title {
    background: linear-gradient(45deg,
            var(--primary-red),
            var(--accent-gold),
            var(--primary-red));
    background-size: 200% 200%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: gradientText 5s ease infinite;
}