/* Base & Reset */
*, *::before, *::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    margin: 0;
    overflow-x: hidden;
}

img {
    max-width: 100%;
    height: auto;
}

/* Scroll Reveal - Progressive Enhancement */
@media (prefers-reduced-motion: no-preference) {
    .scroll-reveal {
        opacity: 0;
        transform: translateY(30px);
        transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
    }
    
    .scroll-reveal.revealed {
        opacity: 1;
        transform: translateY(0);
    }
    
    .scroll-reveal:nth-child(2) { transition-delay: 0.1s; }
    .scroll-reveal:nth-child(3) { transition-delay: 0.2s; }
    .scroll-reveal:nth-child(4) { transition-delay: 0.3s; }
}

/* Fallback: always show content even if JS is disabled */
.no-js .scroll-reveal,
.scroll-reveal {
    opacity: 1;
    transform: none;
}

@media (prefers-reduced-motion: no-preference) {
    .no-js .scroll-reveal {
        opacity: 1;
        transform: none;
    }
}

/* Navbar transition states */
.nav-scrolled {
    background: rgba(253, 248, 245, 0.95) !important;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 0 1px 0 rgba(44, 44, 44, 0.08);
}

.nav-scrolled .font-serif,
.nav-scrolled .font-sans {
    color: #2C2C2C !important;
}

.nav-scrolled #navbar a:not(.bg-coral):not(.text-coral) {
    color: #2C2C2C !important;
}

/* Hero parallax-like effect */
#hero img {
    will-change: transform;
}

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

/* Selection color */
::selection {
    background: #E07A5F;
    color: #2C2C2C;
}

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

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

::-webkit-scrollbar-thumb {
    background: #2C2C2C;
    border-radius: 4px;
}

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

/* Mobile menu transitions */
#mobileMenu {
    transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

#mobileMenu.open {
    transform: translateX(0);
}

#mobileMenu.closed {
    transform: translateX(-100%);
}

/* Button hover effects */
a[href="#menu"],
a[href="#visit"],
button[type="submit"] {
    position: relative;
    overflow: hidden;
}

/* Image hover containers */
div[class*="aspect-"] img {
    transition: transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

/* Print styles */
@media print {
    nav, #gallery, .scroll-reveal { display: none; }
    body { color: #000; background: #fff; }
}
