/* ─── BASE ─── */
*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

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

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

/* ─── NAVBAR ─── */
#navbar {
    background: transparent;
    transition: background 0.4s ease, box-shadow 0.4s ease, padding 0.4s ease;
}

#navbar.scrolled {
    background: rgba(250, 245, 247, 0.92);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    box-shadow: 0 1px 20px rgba(76, 38, 54, 0.08);
}

.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 0;
    height: 2px;
    background: #f0980b;
    transition: width 0.3s ease;
    border-radius: 1px;
}

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

.nav-link.scrolled {
    color: #5a2940;
}

.nav-link.scrolled:hover {
    color: #d17806;
}

/* Mobile nav links */
.mobile-nav-link {
    transition: background 0.2s ease, color 0.2s ease;
}

/* ─── HERO ─── */
#hero {
    position: relative;
}

.hero-bg {
    position: absolute;
    inset: 0;
    background:
        url('https://images.pexels.com/photos/3985091/pexels-photo-3985091.jpeg?auto=compress&cs=tinysrgb&fit=crop&w=1920&h=1080')
        center center / cover no-repeat;
    z-index: 0;
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        180deg,
        rgba(44, 18, 32, 0.72) 0%,
        rgba(44, 18, 32, 0.55) 40%,
        rgba(44, 18, 32, 0.78) 100%
    );
    z-index: 1;
}

.hero-grain {
    position: absolute;
    inset: 0;
    opacity: 0.03;
    z-index: 2;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
    pointer-events: none;
}

/* Hero badge */
.hero-badge {
    animation: fadeInDown 0.8s ease both;
}

/* Hero heading */
#hero h1 {
    animation: fadeInUp 0.8s ease 0.2s both;
}

/* Hero paragraph */
#hero p {
    animation: fadeInUp 0.8s ease 0.4s both;
}

/* Hero buttons */
#hero .flex > a:first-child,
#hero .flex > a:nth-child(2) {
    animation: fadeInUp 0.8s ease 0.55s both;
}

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

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

/* ─── BUTTONS ─── */
.btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: #f0980b;
    color: #2c1220;
    font-weight: 600;
    font-size: 0.95rem;
    padding: 0.875rem 1.75rem;
    border-radius: 9999px;
    border: none;
    cursor: pointer;
    text-decoration: none;
    transition: all 0.3s ease;
    box-shadow: 0 4px 20px rgba(240, 152, 11, 0.35);
}

.btn-primary:hover {
    background: #d17806;
    transform: translateY(-2px);
    box-shadow: 0 8px 28px rgba(240, 152, 11, 0.45);
    color: #2c1220;
}

.btn-secondary {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    color: #ffffff;
    font-weight: 600;
    font-size: 0.95rem;
    padding: 0.875rem 1.75rem;
    border-radius: 9999px;
    border: 1px solid rgba(255, 255, 255, 0.25);
    cursor: pointer;
    text-decoration: none;
    transition: all 0.3s ease;
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.22);
    transform: translateY(-2px);
    color: #ffffff;
}

/* ─── SCROLL HINT ─── */
.scroll-hint {
    animation: fadeInUp 1s ease 1s both;
}

/* ─── MENU CARDS ─── */
.menu-card {
    opacity: 1;
}

/* ─── REVEAL ANIMATIONS ─── */
/* Default state: visible (progressive enhancement) */
.reveal-up,
.reveal-left,
.reveal-right {
    opacity: 1;
    transform: none;
    transition: opacity 0.7s ease, transform 0.7s ease;
}

/* Only apply hidden state when JS is enabled and media query allows */
@media (prefers-reduced-motion: no-preference) {
    .reveal-up,
    .reveal-left,
    .reveal-right {
        opacity: 0;
    }

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

    .reveal-up {
        transform: translateY(32px);
    }

    .reveal-left {
        transform: translateX(-32px);
    }

    .reveal-left.revealed {
        opacity: 1;
        transform: translateX(0);
    }

    .reveal-right {
        transform: translateX(32px);
    }

    .reveal-right.revealed {
        opacity: 1;
        transform: translateX(0);
    }
}

/* If JS is disabled, content stays visible via default styles */
.no-js .reveal-up,
.no-js .reveal-left,
.no-js .reveal-right {
    opacity: 1;
    transform: none;
}

/* ─── RESPONSIVE ─── */
@media (max-width: 640px) {
    #hero h1 {
        font-size: 2.75rem;
    }

    #hero h1 br {
        display: none;
    }

    .hero-badge {
        font-size: 0.75rem;
    }
}

@media (min-width: 641px) and (max-width: 767px) {
    #hero h1 {
        font-size: 3.5rem;
    }
}

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

/* ─── SELECTION ─── */
::selection {
    background: #dbaac;
    color: #2c1220;
}
