/* Custom styles for Goodness to Go */

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

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #FDF8F0;
}
::-webkit-scrollbar-thumb {
    background: #e05530;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #cc3d1e;
}

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

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

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

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

/* Scroll line animation */
@keyframes scroll-line {
    0% { opacity: 0; transform: scaleY(0); transform-origin: top; }
    50% { opacity: 1; transform: scaleY(1); transform-origin: top; }
    51% { transform-origin: bottom; }
    100% { opacity: 0; transform: scaleY(0); transform-origin: bottom; }
}

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

/* Hero entrance animation */
.hero-badge {
    animation: fadeInDown 0.8s ease-out 0.2s both;
}

h1 {
    animation: fadeInUp 0.8s ease-out 0.4s both;
}

.hero > div:last-child > p {
    animation: fadeInUp 0.8s ease-out 0.6s both;
}

.hero > div:last-child > div {
    animation: fadeInUp 0.8s ease-out 0.8s both;
}

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

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

/* Scroll reveal base - content visible by default */
.reveal-up,
.reveal-left,
.reveal-right {
    opacity: 1;
    transform: none;
    transition: opacity 0.7s ease, transform 0.7s ease;
}

/* Only apply hidden state when JS adds the class */
.reveal-up.is-hidden,
.reveal-left.is-hidden,
.reveal-right.is-hidden {
    opacity: 0;
}

.reveal-up.is-hidden {
    transform: translateY(40px);
}

.reveal-left.is-hidden {
    transform: translateX(-40px);
}

.reveal-right.is-hidden {
    transform: translateX(40px);
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    .reveal-up,
    .reveal-left,
    .reveal-right {
        opacity: 1;
        transform: none;
        transition: none;
    }
    
    .animate-float,
    .animate-float-delay,
    .animate-scroll-line {
        animation: none;
    }
    
    html {
        scroll-behavior: auto;
    }
    
    .hero-badge,
    h1 {
        animation: none;
        opacity: 1;
    }
}

/* Mobile menu transitions */
#mobile-menu {
    transition: opacity 0.4s ease, pointer-events 0.4s ease;
}

#mobile-menu.active {
    opacity: 1;
    pointer-events: all;
}

/* Navbar glass effect */
#navbar.scrolled {
    background: rgba(253, 248, 240, 0.95);
    backdrop-filter: blur(12px);
    box-shadow: 0 1px 20px rgba(0, 0, 0, 0.08);
}

/* Image hover zoom */
.group img {
    transition: transform 0.7s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* Product card hover */
.group:hover .absolute {
    opacity: 1;
}

/* Button focus styles */
a:focus-visible,
button:focus-visible {
    outline: 2px solid #e05530;
    outline-offset: 2px;
    border-radius: 4px;
}
