/* Custom styles for Tails & Scales Pet Shop */

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

/* Scroll reveal animations - progressive enhancement, only active when JS adds class */
.scroll-reveal {
    /* Default: visible (works without JS) */
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

@media (prefers-reduced-motion: no-preference) {
    .scroll-reveal {
        /* Hidden state for JS to animate - only works when JS runs */
        opacity: 0;
        transform: translateY(24px);
    }
    
    .scroll-reveal.revealed {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Mobile menu transitions */
#mobile-menu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

#mobile-menu.open {
    max-height: 400px;
}

/* Navbar scroll effect */
#navbar.scrolled {
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f5f3ee;
}

::-webkit-scrollbar-thumb {
    background: #89c989;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #5aad5a;
}

/* Selection color */
::selection {
    background: #dcefdc;
    color: #1e451e;
}

/* Focus visible styles */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible {
    outline: 2px solid #5aad5a;
    outline-offset: 2px;
    border-radius: 4px;
}

/* Ensure images don't cause layout shift */
img {
    max-width: 100%;
    height: auto;
}

/* Touch-friendly tap targets on mobile */
@media (max-width: 640px) {
    a, button {
        min-height: 44px;
    }
}
