/* ============ BASE & RESET ============ */
*, *::before, *::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

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

img, svg {
    display: block;
    max-width: 100%;
}

/* ============ NAVBAR ============ */
#navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    transition: background-color 0.3s ease, box-shadow 0.3s ease, padding 0.3s ease;
    padding: 0.5rem 0;
}

#navbar.nav-scrolled {
    background-color: rgba(253, 250, 245, 0.97);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 0 1px 20px rgba(123, 45, 59, 0.08);
    padding: 0.25rem 0;
}

/* ============ MOBILE MENU ============ */
.mobile-menu {
    animation: fadeIn 0.3s ease forwards;
}

.mobile-menu.hidden {
    display: none;
}

.mobile-link {
    animation: slideUp 0.3s ease forwards;
}

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

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

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

/* ============ HERO BLOBS ============ */
.hero-blob-1,
.hero-blob-2,
.hero-blob-3 {
    animation: blobFloat 8s ease-in-out infinite;
}

.hero-blob-2 {
    animation-delay: -3s;
    animation-duration: 10s;
}

.hero-blob-3 {
    animation-delay: -5s;
    animation-duration: 12s;
}

@keyframes blobFloat {
    0%, 100% { transform: translate(0, 0) scale(1); }
    25% { transform: translate(20px, -20px) scale(1.05); }
    50% { transform: translate(-10px, 15px) scale(0.95); }
    75% { transform: translate(15px, 10px) scale(1.02); }
}

/* ============ MENU CARDS ============ */
.menu-card {
    transform: translateY(0);
}

.menu-card:hover {
    transform: translateY(-6px);
}

/* ============ COMMUNITY CARDS ============ */
.community-card {
    transform: translateY(0);
}

.community-card:hover {
    transform: translateY(-4px);
}

/* ============ SCROLL REVEAL (progressive enhancement) ============ */
@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 0;
        transform: translateY(30px);
        transition: opacity 0.7s ease, transform 0.7s ease;
    }
    
    .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; }
}

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

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

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

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

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

/* ============ SELECTION ============ */
::selection {
    background-color: #f9d4d9;
    color: #7B2D3B;
}

/* ============ FOCUS STYLES ============ */
a:focus-visible,
button:focus-visible {
    outline: 3px solid #c4274a;
    outline-offset: 2px;
    border-radius: 4px;
}

/* ============ RESPONSIVE ============ */
@media (max-width: 768px) {
    .font-display {
        line-height: 1.15;
    }
}
