/* Custom styles for Maple Lake Eastside Campground */

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

/* Base typography */
body {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Hero fade-in animation */
@keyframes heroFadeUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero-fade {
    animation: heroFadeUp 0.8s ease-out forwards;
    opacity: 0;
}

.hero-fade:nth-child(1) { animation-delay: 0.1s; }
.hero-fade:nth-child(2) { animation-delay: 0.3s; }
.hero-fade:nth-child(3) { animation-delay: 0.5s; }
.hero-fade:nth-child(4) { animation-delay: 0.7s; }

/* Stat card float animation */
@keyframes float {
    0%, 100% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-8px);
    }
}

.stat-card {
    animation: float 6s ease-in-out infinite;
}

.stat-card:nth-child(2) {
    animation-delay: -2s;
    animation-duration: 7s;
}

.stat-card:nth-child(3) {
    animation-delay: -4s;
    animation-duration: 5.5s;
}

/* Scroll reveal animation */
.reveal-on-scroll {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

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

/* Navbar transition */
.nav-scrolled {
    background: rgba(250, 250, 248, 0.95);
    backdrop-filter: blur(12px);
    box-shadow: 0 1px 0 rgba(40, 67, 44, 0.08);
}

/* Mobile menu transition */
#mobileMenu {
    transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

#mobileMenu.open {
    transform: translateX(0);
}

#mobileMenu.closed {
    transform: translateX(100%);
}

/* Hamburger animation */
#menuBtn.active #hamburger span:nth-child(1) {
    transform: rotate(45deg) translate(3px, 3px);
}

#menuBtn.active #hamburger span:nth-child(2) {
    opacity: 0;
}

#menuBtn.active #hamburger span:nth-child(3) {
    transform: rotate(-45deg) translate(3px, -3px);
    width: 1.5rem;
}

/* Mobile link animation */
.mobile-link {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.4s ease, transform 0.4s ease, color 0.3s ease;
}

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

#mobileMenu.open .mobile-link:nth-child(1) { transition-delay: 0.1s; }
#mobileMenu.open .mobile-link:nth-child(2) { transition-delay: 0.15s; }
#mobileMenu.open .mobile-link:nth-child(3) { transition-delay: 0.2s; }
#mobileMenu.open .mobile-link:nth-child(4) { transition-delay: 0.25s; }
#mobileMenu.open .mobile-link:nth-child(5) { transition-delay: 0.3s; }
#mobileMenu.open .mobile-link:nth-child(6) { transition-delay: 0.35s; }

/* Back to top button */
.back-to-top {
    transition: opacity 0.4s ease, transform 0.4s ease;
}

.back-to-top.visible {
    opacity: 1;
    pointer-events: auto;
}

.back-to-top:not(.visible) {
    transform: translateY(10px);
}

/* Subtle image zoom on scroll */
@media (prefers-reduced-motion: no-preference) {
    .reveal-on-scroll img {
        transition: transform 0.7s ease;
    }
}

/* Focus styles */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible {
    outline: 2px solid #4f8356;
    outline-offset: 2px;
}

/* Selection color */
::selection {
    background: #c6dfc9;
    color: #213725;
}

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

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

::-webkit-scrollbar-thumb {
    background: #9cc6a3;
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: #6ea376;
}

/* Form focus transitions */
input:focus,
textarea:focus {
    background: #ffffff;
}

/* Print styles */
@media print {
    .back-to-top,
    #menuBtn,
    #mobileMenu {
        display: none !important;
    }
    
    body {
        color: #000;
        background: #fff;
    }
    
    .bg-forest-950 {
        background: #fff !important;
        color: #000 !important;
    }
}
