/* ============================================
   Trails Of Cherry Valley — Custom Styles
   ============================================ */

/* --- Base & Typography --- */
html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    overflow-x: hidden;
}

::selection {
    background-color: rgba(99, 193, 158, 0.3);
    color: #f0f4f8;
}

/* --- Navigation --- */
.nav-link {
    position: relative;
}

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

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

.nav-link::after {
    transition: width 0.3s ease;
}

/* Navbar scroll state */
.navbar-scrolled {
    background-color: rgba(5, 8, 13, 0.95) !important;
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(99, 193, 158, 0.1);
}

/* --- Hero Animations --- */
.hero-content {
    opacity: 1;
    transform: translateY(0);
    animation: heroEnter 1s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

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

/* --- Scroll Reveal (Progressive Enhancement) --- */
.reveal-section {
    /* Default: visible — JS enhances with animation */
    opacity: 1;
    transform: translateY(0);
    transition: opacity 0.7s cubic-bezier(0.16, 1, 0.3, 1),
                transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

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

/* Only animate when JS is active and user prefers motion */
@media (prefers-reduced-motion: no-preference) {
    .reveal-section {
        opacity: 0;
        transform: translateY(30px);
    }
    
    .reveal-section.revealed {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Stagger delays */
.reveal-section:nth-child(1) { transition-delay: 0ms; }
.reveal-section:nth-child(2) { transition-delay: 100ms; }
.reveal-section:nth-child(3) { transition-delay: 200ms; }
.reveal-section:nth-child(4) { transition-delay: 300ms; }
.reveal-section:nth-child(5) { transition-delay: 400ms; }
.reveal-section:nth-child(6) { transition-delay: 500ms; }

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

.mobile-link {
    position: relative;
}

/* --- Button Hover Effects --- */
button, a {
    -webkit-tap-highlight-color: transparent;
}

/* --- Card Hover --- */
.group:hover .group-hover\:scale-110 {
    transform: scale(1.1);
}

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

::-webkit-scrollbar-track {
    background: #0a1018;
}

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

::-webkit-scrollbar-thumb:hover {
    background: #4a6f8e;
}

/* --- Focus Styles --- */
input:focus, textarea:focus, button:focus {
    outline: none;
}

/* --- Responsive Adjustments --- */
@media (max-width: 768px) {
    .font-serif {
        line-height: 1.1;
    }
}

/* --- Print Styles --- */
@media print {
    nav, #contact, .reveal-section {
        opacity: 1 !important;
        transform: none !important;
    }
    
    body {
        background: white;
        color: black;
    }
}
