/* Custom styles for JJP Masonry */

:root {
    --forest-50: #f2f7f4;
    --forest-100: #e3efe7;
    --forest-200: #c5dfca;
    --forest-300: #97c6a0;
    --forest-400: #67a570;
    --forest-500: #43824c;
    --forest-600: #2d6436;
    --forest-700: #234f2a;
    --forest-800: #1d4022;
    --forest-900: #18341c;
    --off-white: #f8faf8;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 80px;
}

body {
    background-color: var(--off-white);
    color: var(--forest-900);
    font-family: 'Manrope', sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Navbar scroll state */
.nav-scrolled {
    background: rgba(255, 255, 255, 0.95) !important;
    backdrop-filter: blur(12px);
    box-shadow: 0 1px 0 rgba(45, 100, 54, 0.08);
}

.nav-scrolled .nav-link {
    color: var(--forest-700) !important;
}

/* Floating card animations */
.floating-card {
    animation: float 6s ease-in-out infinite;
}

.floating-card:nth-child(2) {
    animation-delay: -2s;
}

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

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-12px); }
}

/* Service card hover */
.service-card {
    position: relative;
    overflow: hidden;
}

.service-card::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--forest-500), var(--forest-300));
    transform: scaleX(0);
    transition: transform 0.3s ease;
    transform-origin: left;
}

.service-card:hover::after {
    transform: scaleX(1);
}

/* Scroll reveal animations */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

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

/* Project card hover */
.project-card {
    cursor: pointer;
}

/* Mobile menu transitions */
#mobile-menu {
    animation: slideDown 0.3s ease;
}

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

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    .floating-card {
        animation: none;
    }
    
    .reveal {
        opacity: 1;
        transform: none;
    }
    
    html {
        scroll-behavior: auto;
    }
    
    .project-card img {
        transition: none;
    }
    
    .service-card::after {
        transition: none;
    }
}

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

::-webkit-scrollbar-track {
    background: var(--off-white);
}

::-webkit-scrollbar-thumb {
    background: var(--forest-200);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--forest-300);
}

/* Selection color */
::selection {
    background: var(--forest-200);
    color: var(--forest-900);
}
