/* ===== Mexicana Bakery — Custom Styles ===== */

/* --- Reset & Base --- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 80px; }
body { margin: 0; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }
img { max-width: 100%; height: auto; display: block; }

/* --- Navbar --- */
#navbar {
    background: transparent;
    transition: background 0.4s ease, box-shadow 0.4s ease, padding 0.3s ease;
}
#navbar.scrolled {
    background: rgba(255, 255, 255, 0.97);
    box-shadow: 0 1px 20px rgba(0, 0, 0, 0.08);
}
.nav-logo-text {
    transition: color 0.4s ease;
}
#navbar.scrolled .nav-logo-text { color: #0f766e; }
.nav-link {
    position: relative;
}
.nav-link::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: #2dd4bf;
    transition: width 0.3s ease;
    border-radius: 1px;
}
.nav-link:hover::after { width: 100%; }
#navbar.scrolled .nav-link { color: #334155; }
#navbar.scrolled .nav-link:hover { color: #0f766e; }
#navbar.scrolled .nav-link::after { background: #0d9488; }

/* --- Mobile Menu --- */
#mobile-menu {
    animation: slideDown 0.3s ease;
}
@keyframes slideDown {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}
.mobile-link {
    border-radius: 0.5rem;
    padding: 0.5rem 0.75rem;
    transition: background 0.2s ease, color 0.2s ease;
}
.mobile-link:hover {
    background: #f0fdfa;
}

/* --- Reveal Animations (progressive enhancement) --- */
.reveal-up, .reveal-left, .reveal-right {
    opacity: 1;
    transform: none;
    transition: opacity 0.7s ease, transform 0.7s ease;
}

@media (prefers-reduced-motion: no-preference) {
    .reveal-up, .reveal-left, .reveal-right {
        opacity: 0;
        transform: translateY(30px);
        transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1), transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
    }
    .reveal-left { transform: translateX(-30px); }
    .reveal-right { transform: translateX(30px); }
    .reveal-up.is-visible,
    .reveal-left.is-visible,
    .reveal-right.is-visible {
        opacity: 1;
        transform: none;
    }
}

/* --- Image hover zoom (only when JS is active) --- */
.group:hover .group-hover\:scale-105 {
    transform: scale(1.05);
}

/* --- Custom scrollbar --- */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: #f1f5f9; }
::-webkit-scrollbar-thumb { background: #94a3b8; border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: #64748b; }

/* --- Selection --- */
::selection { background: #99f6e4; color: #042f2e; }

/* --- Focus visible --- */
:focus-visible {
    outline: 2px solid #14b8a6;
    outline-offset: 2px;
    border-radius: 4px;
}

/* --- Subtle card tilt on hover --- */
@media (hover: hover) {
    .reveal-up:hover {
        transform: translateY(-4px);
    }
}

/* --- Map container --- */
iframe { filter: saturate(0.85) contrast(1.05); }
