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

body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

::selection {
    background: #f9d0d9;
    color: #5c1a26;
}

/* ===== Navbar ===== */
#navbar {
    background: rgba(254, 253, 251, 0.85);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(244, 168, 188, 0.3);
}

#navbar.scrolled {
    background: rgba(254, 253, 251, 0.95);
    box-shadow: 0 4px 30px rgba(123, 45, 59, 0.08);
}

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

#mobile-menu.open .mobile-link {
    animation: fadeSlideIn 0.4s ease forwards;
    opacity: 0;
}

#mobile-menu.open .mobile-link:nth-child(1) { animation-delay: 0.05s; }
#mobile-menu.open .mobile-link:nth-child(2) { animation-delay: 0.1s; }
#mobile-menu.open .mobile-link:nth-child(3) { animation-delay: 0.15s; }
#mobile-menu.open .mobile-link:nth-child(4) { animation-delay: 0.2s; }
#mobile-menu.open .mobile-link:nth-child(5) { animation-delay: 0.25s; }

@keyframes fadeSlideIn {
    from { opacity: 0; transform: translateY(12px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ===== Hamburger ===== */
.hamburger-line {
    transition: all 0.35s cubic-bezier(0.4, 0, 0.2, 1);
}

#mobile-toggle.active .hamburger-line:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

#mobile-toggle.active .hamburger-line:nth-child(2) {
    opacity: 0;
}

#mobile-toggle.active .hamburger-line:nth-child(3) {
    width: 1.25rem;
    transform: rotate(-45deg) translate(4px, -4px);
}

/* ===== Menu Tabs ===== */
.menu-tab {
    background: transparent;
    color: #7B2D3B;
    opacity: 0.5;
}

.menu-tab.active {
    background: #7B2D3B;
    color: #fefdfb;
    opacity: 1;
    box-shadow: 0 4px 15px rgba(123, 45, 59, 0.3);
}

.menu-tab:hover:not(.active) {
    opacity: 0.8;
    background: rgba(123, 45, 59, 0.08);
}

/* ===== Scroll Reveal ===== */
.reveal {
    opacity: 1;
    transform: none;
    transition: opacity 0.8s cubic-bezier(0.4, 0, 0.2, 1), transform 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.reveal.revealed {
    opacity: 1;
    transform: none;
}

@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 0;
        transform: translateY(32px);
    }

    .reveal.revealed {
        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; }
}

/* ===== Smooth image loading ===== */
img {
    image-rendering: auto;
}

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

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

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

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

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