/* Custom styles for Vallarta Grocery */

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

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

@keyframes float-delayed {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-8px); }
}

.animate-float {
    animation: float 4s ease-in-out infinite;
}

.animate-float-delayed {
    animation: float-delayed 4s ease-in-out infinite;
    animation-delay: 1s;
}

/* Fade-in on scroll */
.fade-in {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.7s ease, transform 0.7s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Stagger children */
.fade-in-stagger > * {
    opacity: 0;
    transform: translateY(16px);
    transition: opacity 0.5s ease, transform 0.5s ease;
}

.fade-in-stagger.visible > * {
    opacity: 1;
    transform: translateY(0);
}

.fade-in-stagger.visible > *:nth-child(1) { transition-delay: 0.05s; }
.fade-in-stagger.visible > *:nth-child(2) { transition-delay: 0.1s; }
.fade-in-stagger.visible > *:nth-child(3) { transition-delay: 0.15s; }
.fade-in-stagger.visible > *:nth-child(4) { transition-delay: 0.2s; }
.fade-in-stagger.visible > *:nth-child(5) { transition-delay: 0.25s; }
.fade-in-stagger.visible > *:nth-child(6) { transition-delay: 0.3s; }

/* Nav active state */
nav.scrolled {
    background: rgba(253, 248, 240, 0.95);
    box-shadow: 0 1px 20px rgba(4, 78, 59, 0.06);
}

/* Product card hover glow */
.group:hover .group-hover\:scale-105 {
    transform: scale(1.05);
}

/* Custom selection color */
::selection {
    background: #A7F3D0;
    color: #064E3B;
}

/* Mobile menu transition */
#mobileMenu {
    transition: max-height 0.3s ease, opacity 0.3s ease;
}

#mobileMenu.hidden {
    max-height: 0;
    opacity: 0;
    overflow: hidden;
}

#mobileMenu:not(.hidden) {
    max-height: 400px;
    opacity: 1;
}
