/* ─── Base & Typography ─── */
html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    overflow-x: hidden;
}

::selection {
    background-color: #8a1515;
    color: #fff8f6;
}

/* ─── Scroll Reveal (progressive enhancement) ─── */
@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.visible {
        opacity: 1;
        transform: translateY(0);
    }

    .reveal-delay-1 { transition-delay: 0.1s; }
    .reveal-delay-2 { transition-delay: 0.2s; }
    .reveal-delay-3 { transition-delay: 0.3s; }
    .reveal-delay-4 { transition-delay: 0.4s; }
}

/* ─── Navbar Transition ─── */
#navbar {
    background: transparent;
}

#navbar.scrolled {
    background: rgba(255, 248, 246, 0.95);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    box-shadow: 0 1px 0 rgba(138, 21, 21, 0.08);
}

#navbar.scrolled .font-serif,
#navbar.scrolled a:not(.bg-burgundy-700) {
    color: #5f1212;
}

/* ─── Floating Cards Animation ─── */
@media (prefers-reduced-motion: no-preference) {
    .float-card-1 { animation: float1 6s ease-in-out infinite; }
    .float-card-2 { animation: float2 7s ease-in-out infinite; }
    .float-card-3 { animation: float3 5.5s ease-in-out infinite; }
    .float-card-4 { animation: float4 6.5s ease-in-out infinite; }
}

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

@keyframes float2 {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(10px); }
}

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

@keyframes float4 {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(14px); }
}

/* ─── Mobile Menu ─── */
#mobile-menu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

#mobile-menu.open {
    max-height: 400px;
}

/* ─── Button Focus States ─── */
a:focus-visible, button:focus-visible {
    outline: 2px solid #8a1515;
    outline-offset: 2px;
    border-radius: 4px;
}

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

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

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

::-webkit-scrollbar-thumb:hover {
    background: #8a1515;
}
