/* === Custom Styles for Double Tree Resort Room 606 === */

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #1a2744;
}
::-webkit-scrollbar-thumb {
    background: #c9a84c;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #d4b85e;
}

/* Selection color */
::selection {
    background: #c9a84c;
    color: #0d1524;
}

/* === Navigation === */
.nav-link {
    position: relative;
}
.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 1px;
    background: #c9a84c;
    transition: width 0.3s ease;
}
.nav-link:hover::after {
    width: 100%;
}

/* Mobile nav links */
.mobile-nav-link {
    position: relative;
}

/* === Hero === */
#hero {
    position: relative;
}

/* === Reveal Animations (progressive enhancement) === */
@media (prefers-reduced-motion: no-preference) {
    .reveal-up,
    .reveal-left,
    .reveal-right {
        opacity: 1;
        transform: none;
        transition: opacity 0.8s ease, transform 0.8s ease;
    }
    
    /* When JS is enabled, set initial hidden state and animate on scroll */
    .js .reveal-up {
        opacity: 0;
        transform: translateY(40px);
    }
    .js .reveal-left {
        opacity: 0;
        transform: translateX(-40px);
    }
    .js .reveal-right {
        opacity: 0;
        transform: translateX(40px);
    }
    
    .js .reveal-up.revealed,
    .js .reveal-left.revealed,
    .js .reveal-right.revealed {
        opacity: 1;
        transform: none;
    }
}

/* Always visible regardless of JS */
.reveal-up,
.reveal-left,
.reveal-right {
    opacity: 1;
    transform: none;
}

/* === Navbar scroll state === */
#navbar.scrolled {
    background: rgba(13, 21, 36, 0.95);
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
}

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

#navbar.scrolled .mobile-nav-link {
    color: #ffffff;
}

/* === Cards hover effect === */
#spaces .group:hover .w-14 {
    transform: scale(1.1);
}
#spaces .group .w-14 {
    transition: transform 0.3s ease, background-color 0.3s ease;
}

/* === Button focus states === */
button:focus-visible,
a:focus-visible {
    outline: 2px solid #c9a84c;
    outline-offset: 2px;
}

/* === Form focus states === */
input:focus,
textarea:focus {
    outline: none;
}

/* === Decorative gold line animations === */
.w-12.h-px.bg-gold-500 {
    transition: width 0.3s ease;
}

/* === Map container === */
iframe {
    filter: saturate(0.8) contrast(1.05);
    transition: filter 0.3s ease;
}
iframe:hover {
    filter: saturate(1) contrast(1);
}

/* === Mobile menu transitions === */
#mobile-menu {
    animation: slideDown 0.3s ease forwards;
}
@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* === Staggered card animations === */
.js #spaces .reveal-up {
    transition-delay: 0ms;
}
.js #spaces .reveal-up:nth-child(2) {
    transition-delay: 100ms;
}
.js #spaces .reveal-up:nth-child(3) {
    transition-delay: 200ms;
}
.js #spaces .reveal-up:nth-child(4) {
    transition-delay: 300ms;
}
.js #spaces .reveal-up:nth-child(5) {
    transition-delay: 400ms;
}
.js #spaces .reveal-up:nth-child(6) {
    transition-delay: 500ms;
}
