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

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

::selection {
    background-color: #d9a02e;
    color: #102a43;
}

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

#navbar.scrolled {
    background: rgba(255, 255, 255, 0.97);
    backdrop-filter: blur(12px);
    box-shadow: 0 1px 0 rgba(16, 42, 67, 0.08);
}

.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 1px;
    background-color: #d9a02e;
    transition: width 0.3s ease;
}

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

#navbar.scrolled .nav-link {
    color: #102a43;
}

#navbar:not(.scrolled) .nav-link {
    color: rgba(255, 255, 255, 0.85);
}

#navbar:not(.scrolled) .nav-link:hover {
    color: #d9a02e;
}

#navbar:not(.scrolled) .nav-text {
    color: #ffffff;
}

#navbar.scrolled .nav-text {
    color: #102a43;
}

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

.mobile-link {
    font-family: 'Cormorant Garamond', Georgia, serif;
    font-size: 1.75rem;
}

/* ─── Residence Cards ─── */
.residence-card {
    opacity: 1;
}

.residence-card:hover .residence-card-img {
    transform: scale(1.05);
}

/* ─── Scroll Reveal ─── */
.reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

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

/* ─── Button Focus ─── */
button:focus-visible,
a:focus-visible,
input:focus-visible,
textarea:focus-visible {
    outline: 2px solid #d9a02e;
    outline-offset: 2px;
}

/* ─── Reduced Motion ─── */
@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
    .reveal {
        opacity: 1;
        transform: none;
        transition: none;
    }
    .residence-card img {
        transition: none;
    }
    .residence-card:hover img {
        transform: none;
    }
}

/* ─── Mobile Adjustments ─── */
@media (max-width: 768px) {
    #hero {
        min-height: 100vh;
        min-height: 100dvh;
    }

    .font-serif {
        line-height: 1.1;
    }
}
