/* Custom styles for Tacos Y Tortas San Bernardino */

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

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

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

::-webkit-scrollbar-thumb {
    background: #059669;
    border-radius: 5px;
}

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

/* Floating card animations */
.floating-card {
    animation: float 4s ease-in-out infinite;
}

.floating-card:nth-child(2) {
    animation-delay: -1s;
}

.floating-card:nth-child(3) {
    animation-delay: -2s;
}

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

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

@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 0;
        transform: translateY(30px);
        transition: opacity 0.6s ease-out, transform 0.6s ease-out;
    }
    
    .reveal.revealed {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Navbar styles */
.nav-scrolled {
    background: rgba(255, 254, 248, 0.95) !important;
    backdrop-filter: blur(12px);
    box-shadow: 0 4px 20px rgba(6, 78, 59, 0.1);
}

.nav-scrolled .logo-text {
    color: #064e3b !important;
}

.nav-scrolled .nav-link {
    color: #065f46 !important;
}

.nav-scrolled .nav-link:hover {
    color: #059669 !important;
}

.nav-scrolled .mobile-menu-link {
    color: #065f46 !important;
}

/* Geometric shape animations */
@media (prefers-reduced-motion: no-preference) {
    .geo-shape {
        animation: drift 8s ease-in-out infinite;
    }
    
    .geo-shape:nth-child(2) {
        animation-delay: -2s;
        animation-duration: 10s;
    }
    
    .geo-shape:nth-child(3) {
        animation-delay: -4s;
        animation-duration: 12s;
    }
}

@keyframes drift {
    0%, 100% {
        transform: translate(0, 0) rotate(0deg);
    }
    25% {
        transform: translate(10px, -15px) rotate(5deg);
    }
    50% {
        transform: translate(-5px, -25px) rotate(-3deg);
    }
    75% {
        transform: translate(-15px, -10px) rotate(3deg);
    }
}

/* Card hover effects */
.menu-card {
    transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.menu-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 25px 50px -12px rgba(6, 78, 59, 0.25);
}

/* Button hover glow */
.btn-glow:hover {
    box-shadow: 0 0 30px rgba(255, 235, 59, 0.4);
}

/* Image zoom container */
.img-zoom {
    overflow: hidden;
}

.img-zoom img {
    transition: transform 0.7s ease;
}

.img-zoom:hover img {
    transform: scale(1.1);
}

/* Mobile menu transition */
#mobileMenu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease, padding 0.4s ease;
}

#mobileMenu.open {
    max-height: 400px;
    padding: 1.5rem 0;
}

/* Selection color */
::selection {
    background: #059669;
    color: #fffef8;
}

/* Focus styles */
a:focus-visible,
button:focus-visible {
    outline: 3px solid #34d399;
    outline-offset: 2px;
    border-radius: 4px;
}

/* Prevent layout shift on images */
img {
    image-rendering: -webkit-optimize-contrast;
    image-rendering: crisp-edges;
}

/* Responsive typography adjustments */
@media (max-width: 640px) {
    .font-display {
        line-height: 1.1;
    }
}

/* Print styles */
@media print {
    nav, .floating-card, #mobileMenu {
        display: none !important;
    }
    
    body {
        background: white !important;
        color: black !important;
    }
}
