/* ============================================
   Panadería y Pastelería La Alegria
   Custom Styles — Midnight Blue & Mint
   ============================================ */

/* Base & Typography */
html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Lato', Arial, sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4 {
    font-family: 'Playfair Display', Georgia, serif;
}

/* Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #0a1628;
}
::-webkit-scrollbar-thumb {
    background: #1e3a54;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #2e5070;
}

/* ============================================
   Floating Card Animations
   ============================================ */
.floating-card-1 {
    animation: float-1 6s ease-in-out infinite;
}
.floating-card-2 {
    animation: float-2 7s ease-in-out infinite;
}
.floating-card-3 {
    animation: float-3 5s ease-in-out infinite;
}

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

@keyframes float-2 {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-16px) rotate(-0.5deg); }
}

@keyframes float-3 {
    0%, 100% { transform: translateY(0px) rotate(0deg); }
    50% { transform: translateY(-10px) rotate(0.3deg); }
}

/* ============================================
   Scroll Reveal Animations
   Only active when JS is enabled AND user prefers motion
   ============================================ */
@media (prefers-reduced-motion: no-preference) {
    .reveal-up {
        opacity: 0;
        transform: translateY(30px);
        transition: opacity 0.7s ease, transform 0.7s ease;
    }
    .reveal-up.revealed {
        opacity: 1;
        transform: translateY(0);
    }
    .reveal-left {
        opacity: 0;
        transform: translateX(-30px);
        transition: opacity 0.7s ease, transform 0.7s ease;
    }
    .reveal-left.revealed {
        opacity: 1;
        transform: translateX(0);
    }
    .reveal-right {
        opacity: 0;
        transform: translateX(30px);
        transition: opacity 0.7s ease, transform 0.7s ease;
    }
    .reveal-right.revealed {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Fallback: always visible if JS is disabled or reduced motion */
@media (prefers-reduced-motion: reduce) {
    .reveal-up,
    .reveal-left,
    .reveal-right {
        opacity: 1;
        transform: none;
    }
}

/* ============================================
   Navbar States
   ============================================ */
.nav-scrolled {
    background: rgba(10, 22, 40, 0.95) !important;
    backdrop-filter: blur(12px);
    border-bottom: 1px solid rgba(168, 213, 186, 0.08);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
}

/* ============================================
   Mobile Menu
   ============================================ */
.mobile-menu-open {
    opacity: 1 !important;
    pointer-events: all !important;
}

/* ============================================
   Button & Link Focus States
   ============================================ */
a:focus-visible,
button:focus-visible {
    outline: 2px solid #88d4ab;
    outline-offset: 3px;
    border-radius: 4px;
}

/* ============================================
   Selection Color
   ============================================ */
::selection {
    background: rgba(58, 157, 104, 0.3);
    color: #d4dce8;
}

/* ============================================
   Image Optimization
   ============================================ */
img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* ============================================
   Responsive Adjustments
   ============================================ */
@media (max-width: 768px) {
    .floating-card-1,
    .floating-card-2,
    .floating-card-3 {
        display: none;
    }
}

/* ============================================
   Print Styles
   ============================================ */
@media print {
    nav, .floating-card-1, .floating-card-2, .floating-card-3,
    #gallery, .reveal-up, .reveal-left, .reveal-right {
        display: none !important;
    }
    body {
        background: white;
        color: #1a1a1a;
    }
}
