/* Base & Animations */
@keyframes fade-up {
    from {
        opacity: 0;
        transform: translateY(24px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fade-up {
    animation: fade-up 0.8s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

/* Scroll-triggered reveal */
.reveal {
    opacity: 0;
    transform: translateY(32px);
    transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), 
                transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

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

/* Navbar scroll state */
.nav-scrolled {
    background: rgba(254, 253, 248, 0.95);
    backdrop-filter: blur(12px);
    box-shadow: 0 1px 0 rgba(61, 99, 38, 0.08);
}

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

.mobile-menu-open .menu-line:first-child {
    transform: rotate(45deg) translate(3px, 3px);
}

.mobile-menu-open .menu-line:last-child {
    transform: rotate(-45deg) translate(3px, -3px);
}

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

/* Custom selection color */
::selection {
    background: rgba(61, 99, 38, 0.2);
    color: #28401a;
}

/* Input autofill styling */
input:-webkit-autofill,
textarea:-webkit-autofill {
    -webkit-box-shadow: 0 0 0 30px #28401a inset !important;
    -webkit-text-fill-color: #fefdf8 !important;
}

/* Focus visible for accessibility */
:focus-visible {
    outline: 2px solid #769d52;
    outline-offset: 4px;
}

/* Image hover zoom */
.group:hover img {
    transform: scale(1.05);
    transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

.group img {
    transition: transform 0.6s cubic-bezier(0.16, 1, 0.3, 1);
}

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

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

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

/* Close button animation */
.mobile-menu-open .menu-line {
    background: #28401a !important;
}
