/* ── Base & Resets ── */
*, *::before, *::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    margin: 0;
    overflow-x: hidden;
}

::selection {
    background: #D4A017;
    color: #1a0d20;
}

/* ── Scroll Reveal (progressive enhancement) ── */
@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 0;
        transform: translateY(30px);
        transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1), transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
    }

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

/* Fallback: always visible if JS is disabled or prefers-reduced-motion */
.js-enabled .reveal {
    opacity: 1;
    transform: none;
}

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

#header.scrolled {
    background: rgba(26, 13, 32, 0.95);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 0 1px 0 rgba(212, 160, 23, 0.1);
}

.nav-link {
    position: relative;
}

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

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

/* ── Mobile Menu ── */
#mobileMenu.open {
    max-height: 400px;
    opacity: 1;
}

.menu-line:last-child {
    transition: all 0.3s ease;
}

#menuBtn.active .menu-line:first-child {
    transform: rotate(45deg) translate(3px, 3px);
}

#menuBtn.active .menu-line:nth-child(2) {
    opacity: 0;
}

#menuBtn.active .menu-line:last-child {
    width: 24px;
    transform: rotate(-45deg) translate(3px, -3px);
}

.mobile-nav-link {
    position: relative;
}

/* ── Buttons ── */
button, input, select, textarea {
    font-family: inherit;
}

select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%235B2C6F' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    padding-right: 2.5rem;
}

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

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

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

::-webkit-scrollbar-thumb:hover {
    background: #966aad;
}

/* ── Utility ── */
@media (max-width: 767px) {
    .font-serif {
        line-height: 1.1;
    }
}
