/* Base styles and custom utilities */
html {
    scroll-behavior: smooth;
}

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

/* Navbar scroll state */
#navbar.scrolled {
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(191, 237, 214, 0.3);
    box-shadow: 0 1px 20px rgba(16, 42, 67, 0.06);
}

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

.nav-link {
    position: relative;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    width: 0;
    height: 2px;
    background: #3fb574;
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

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

/* Room card image zoom on hover handled by group-hover in HTML */

/* Scroll reveal base — progressive enhancement, content visible by default */
.scroll-reveal {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1), transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}

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

/* Only apply hidden state when JS is active and user prefers motion */
@media (prefers-reduced-motion: no-preference) {
    .scroll-reveal[data-reveal] {
        opacity: 0;
        transform: translateY(30px);
    }
    
    .scroll-reveal[data-reveal].revealed {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Mobile menu transitions */
#mobile-menu {
    animation: slideDown 0.3s ease-out;
}

#mobile-menu.hidden {
    animation: slideUp 0.25s ease-in forwards;
}

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

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

/* Mobile link hover */
.mobile-link {
    transition: all 0.2s ease;
}

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

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

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

::-webkit-scrollbar-thumb:hover {
    background: #9fb3c8;
}

/* Selection color */
::selection {
    background: #ceeedd;
    color: #102a43;
}

/* Focus visible for accessibility */
:focus-visible {
    outline: 2px solid #3fb574;
    outline-offset: 2px;
}

/* Subtle gradient text utility */
.gradient-text {
    background: linear-gradient(135deg, #102a43 0%, #3fb574 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* Input autofill styling */
input:-webkit-autofill,
textarea:-webkit-autofill {
    -webkit-box-shadow: 0 0 0 30px #f4fbf9 inset !important;
    -webkit-text-fill-color: #102a43 !important;
}
