/* Base Styles */
html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    overflow-x: hidden;
}

/* Selection */
::selection {
    background-color: #1B4332;
    color: #FDFCF8;
}

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

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

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

::-webkit-scrollbar-thumb:hover {
    background: #477a47;
}

/* Hero Animations */
.hero-subtitle {
    animation: fadeUp 0.8s ease forwards 0.2s;
}

.hero-title {
    animation: fadeUp 0.8s ease forwards 0.4s;
}

.hero-description {
    animation: fadeUp 0.8s ease forwards 0.6s;
}

.hero-ctas {
    animation: fadeUp 0.8s ease forwards 0.8s;
}

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

/* Scroll Line Animation */
.animate-scroll-line {
    animation: scrollLine 2s ease-in-out infinite;
}

@keyframes scrollLine {
    0%, 100% {
        opacity: 0.3;
        transform: scaleY(0.5);
        transform-origin: top;
    }
    50% {
        opacity: 1;
        transform: scaleY(1);
    }
}

/* Room Card Hover */
.room-card {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.6s ease, transform 0.6s ease;
}

.room-card.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Nav Link Underline Animation */
.nav-link {
    position: relative;
}

/* Mobile Menu */
.mobile-nav-link {
    opacity: 0;
    transform: translateY(12px);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.mobile-menu-open .mobile-nav-link {
    opacity: 1;
    transform: translateY(0);
}

/* Staggered mobile menu */
.mobile-menu-open .mobile-nav-link:nth-child(1) { transition-delay: 0.05s; }
.mobile-menu-open .mobile-nav-link:nth-child(2) { transition-delay: 0.1s; }
.mobile-menu-open .mobile-nav-link:nth-child(3) { transition-delay: 0.15s; }
.mobile-menu-open .mobile-nav-link:nth-child(4) { transition-delay: 0.2s; }
.mobile-menu-open .mobile-nav-link:nth-child(5) { transition-delay: 0.25s; }

/* Menu Toggle Animation */
.menu-open .menu-line:nth-child(1) {
    transform: rotate(45deg) translate(3px, 3px);
}

.menu-open .menu-line:nth-child(2) {
    opacity: 0;
}

.menu-open .menu-line:nth-child(3) {
    transform: rotate(-45deg) translate(3px, -3px);
    width: 1.5rem;
}

/* Navbar Scroll State */
.nav-scrolled {
    background-color: rgba(253, 252, 248, 0.95) !important;
    backdrop-filter: blur(12px);
    box-shadow: 0 1px 0 rgba(27, 67, 50, 0.08);
}

.nav-scrolled .font-serif {
    color: #1B4332 !important;
}

.nav-scrolled .text-forest-500 {
    color: #477a47 !important;
}

.nav-scrolled .menu-line {
    background-color: #1B4332 !important;
}

/* Fade In Animation */
.fade-in {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.7s ease, transform 0.7s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Image Hover */
.overflow-hidden img {
    transition: transform 0.7s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* Button Focus */
button:focus-visible,
a:focus-visible {
    outline: 2px solid #1B4332;
    outline-offset: 2px;
}

/* Input Focus */
input:focus,
textarea:focus {
    box-shadow: 0 0 0 1px #477a47;
}

/* Responsive Typography */
@media (max-width: 640px) {
    html {
        font-size: 15px;
    }
}

@media (min-width: 1280px) {
    html {
        font-size: 17px;
    }
}

/* Print Styles */
@media print {
    header, #contact, footer {
        display: none;
    }
    
    body {
        color: #000;
        background: #fff;
    }
}
