*, *::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;
}

::selection {
    background-color: #b83434;
    color: #fdf8f6;
}

/* ── Scroll Reveal ── */
@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 0;
        transform: translateY(32px);
        transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
    }

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

    .reveal:nth-child(2) { transition-delay: 0.1s; }
    .reveal:nth-child(3) { transition-delay: 0.2s; }
    .reveal:nth-child(4) { transition-delay: 0.3s; }
}

/* ── Navbar ── */
#site-header {
    background: transparent;
    transition: background 0.4s ease, box-shadow 0.4s ease, backdrop-filter 0.4s ease;
}

#site-header.scrolled {
    background: rgba(253, 248, 246, 0.95);
    backdrop-filter: blur(12px);
    box-shadow: 0 1px 20px rgba(61, 15, 15, 0.08);
}

.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 50%;
    width: 0;
    height: 1px;
    background: #b83434;
    transition: width 0.3s ease, left 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
    left: 0;
}

/* ── Hero Parallax ── */
#hero {
    position: relative;
}

#hero img {
    will-change: transform;
}

/* ── Mobile Menu ── */
#mobile-menu.open {
    opacity: 1;
    pointer-events: all;
}

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

.mobile-link {
    transition: transform 0.2s ease, opacity 0.2s ease;
}

.mobile-link:hover {
    transform: scale(1.05);
}

/* ── Hamburger Animation ── */
#menu-toggle[aria-expanded="true"] #bar1 {
    transform: translateY(6px) rotate(45deg);
}

#menu-toggle[aria-expanded="true"] #bar2 {
    opacity: 0;
    transform: scaleX(0);
}

#menu-toggle[aria-expanded="true"] #bar3 {
    transform: translateY(-6px) rotate(-45deg);
    width: 1.25rem;
}

/* ── Buttons ── */
a, button {
    cursor: pointer;
}

button, input, textarea, select {
    font-family: inherit;
    font-size: inherit;
}

/* ── Focus Styles ── */
:focus-visible {
    outline: 2px solid #b83434;
    outline-offset: 2px;
}

/* ── Smooth Scrollbar ── */
::-webkit-scrollbar {
    width: 8px;
}

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

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

::-webkit-scrollbar-thumb:hover {
    background: #9a2929;
}

/* ── Image Loading ── */
img {
    image-rendering: auto;
    loading: lazy;
}

/* ── Form ── */
input:focus, textarea:focus {
    box-shadow: 0 0 0 3px rgba(184, 52, 52, 0.1);
}

/* ── Print ── */
@media print {
    #site-header, #menu-toggle, .reveal { display: none; }
    body { background: white; color: black; }
    a { color: black; text-decoration: underline; }
}
