/* ============================================
   Catlin Guest House — Custom Styles
   Classic & Elegant | Plum + Amber Palette
   ============================================ */

/* Base Reset & Typography */
*, *::before, *::after {
    box-sizing: border-box;
}

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

body {
    overflow-x: hidden;
}

/* Selection Color */
::selection {
    background-color: #D4A84B;
    color: #22132b;
}

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

::-webkit-scrollbar-track {
    background: #22132b;
}

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

::-webkit-scrollbar-thumb:hover {
    background: #D4A84B;
}

/* ============================================
   Scroll Reveal Animations (progressive enhancement)
   ============================================ */
@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 0;
        transform: translateY(30px);
        transition: opacity 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94),
                    transform 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    }

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

    .reveal-delay-1 { transition-delay: 0.1s; }
    .reveal-delay-2 { transition-delay: 0.2s; }
    .reveal-delay-3 { transition-delay: 0.3s; }
    .reveal-delay-4 { transition-delay: 0.4s; }
}

/* ============================================
   Navbar Scroll State
   ============================================ */
.navbar-scrolled #navbar {
    background-color: rgba(34, 19, 43, 0.97);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.3);
}

.navbar-scrolled .navbar-text {
    color: #f5f0f7;
}

.navbar-scrolled .navbar-subtext {
    color: #D4A84B;
}

.navbar-scrolled .menu-line {
    background-color: #f5f0f7;
}

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

#mobile-menu.open .mobile-link {
    animation: slideIn 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94) forwards;
}

#mobile-menu.open .mobile-link:nth-child(1) { animation-delay: 0.05s; }
#mobile-menu.open .mobile-link:nth-child(2) { animation-delay: 0.1s; }
#mobile-menu.open .mobile-link:nth-child(3) { animation-delay: 0.15s; }
#mobile-menu.open .mobile-link:nth-child(4) { animation-delay: 0.2s; }
#mobile-menu.open .mobile-link:nth-child(5) { animation-delay: 0.25s; }

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

/* Hamburger Animation */
.menu-btn.active .menu-line:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

.menu-btn.active .menu-line:nth-child(2) {
    opacity: 0;
    transform: scaleX(0);
}

.menu-btn.active .menu-line:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
    width: 6px;
}

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

/* ============================================
   Image Aspect Ratio Utilities
   ============================================ */
img {
    max-width: 100%;
    height: auto;
}

/* ============================================
   Print Styles
   ============================================ */
@media print {
    #navbar,
    #mobile-menu,
    #contact-form,
    .reveal {
        display: none !important;
    }
    
    body {
        background: white;
        color: black;
    }
}
