/* ===== CUSTOM STYLES ===== */

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

/* Custom scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #ecfdf5;
}
::-webkit-scrollbar-thumb {
    background: #6ee7b7;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #34d399;
}

/* Selection color */
::selection {
    background: #6ee7b7;
    color: #022c22;
}

/* Navbar scroll state */
.nav-header.scrolled {
    box-shadow: 0 1px 20px rgba(4, 120, 87, 0.08);
}

/* Mobile menu animation */
#mobileMenu.show {
    animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-8px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Mobile menu toggle animation */
.menu-line:nth-child(1) {
    transition: transform 0.3s ease, width 0.3s ease;
}
.menu-line:nth-child(2) {
    transition: opacity 0.3s ease;
}
.menu-line:nth-child(3) {
    transition: transform 0.3s ease, width 0.3s ease;
}

#menuToggle.active .menu-line:nth-child(1) {
    transform: translateY(4px) rotate(45deg);
}
#menuToggle.active .menu-line:nth-child(2) {
    opacity: 0;
}
#menuToggle.active .menu-line:nth-child(3) {
    transform: translateY(-4px) rotate(-45deg);
    width: 1.5rem;
}

/* Mobile nav links */
.mobile-link {
    display: block;
    font-family: 'Space Grotesk', sans-serif;
    font-weight: 500;
    color: #064e3b;
    font-size: 1.125rem;
    padding: 0.5rem 0;
    border-bottom: 1px solid #d1fae5;
    text-decoration: none;
    transition: color 0.2s ease;
}
.mobile-link:hover {
    color: #059669;
}

/* Scroll reveal animations (progressive enhancement) */
.reveal {
    opacity: 1;
    transform: none;
    transition: opacity 0.6s ease, transform 0.6s ease;
}

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

@media (prefers-reduced-motion: no-preference) {
    .reveal {
        opacity: 0;
        transform: translateY(24px);
    }
    .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; }
}

/* Focus styles for accessibility */
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible {
    outline: 2px solid #34d399;
    outline-offset: 2px;
    border-radius: 4px;
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    html {
        scroll-behavior: auto;
    }
}
