/* Custom styles for Timeless Treats Ice Cream Trucks */

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

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

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

::-webkit-scrollbar-thumb {
    background: #065f46;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #047857;
}

/* Selection color */
::selection {
    background: #065f46;
    color: #fffbf5;
}

/* Reveal animations - progressive enhancement only */
.reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}

/* Reduced motion preference */
@media (prefers-reduced-motion: reduce) {
    .reveal {
        opacity: 1;
        transform: none;
        transition: none;
    }
    
    html {
        scroll-behavior: auto;
    }
    
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

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

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

#mobile-menu.closed {
    opacity: 0;
    pointer-events: none;
}

/* Form focus styles */
input:focus,
select:focus,
textarea:focus {
    outline: none;
}

/* Image loading placeholder */
img {
    background-color: #d1fae5;
}

/* Navbar glass effect */
#navbar.scrolled {
    background: rgba(255, 251, 245, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 1px 0 rgba(6, 95, 70, 0.1);
}

/* Hero gradient animation */
@keyframes gradientShift {
    0%, 100% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
}

/* Button hover effects */
button, a {
    -webkit-tap-highlight-color: transparent;
}

/* Touch device optimizations */
@media (hover: none) {
    .group:hover .group-hover\:scale-105 {
        transform: none;
    }
    
    .group:hover .group-hover\:scale-110 {
        transform: none;
    }
}

/* Print styles */
@media print {
    nav, #mobile-menu-btn, #mobile-menu {
        display: none !important;
    }
    
    .reveal {
        opacity: 1 !important;
        transform: none !important;
    }
}
