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

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

body {
    overflow-x: hidden;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}
::-webkit-scrollbar-track {
    background: #f5f3ed;
}
::-webkit-scrollbar-thumb {
    background: #4a8256;
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: #366341;
}

/* Hero Animations */
.hero-subtitle {
    opacity: 0;
    transform: translateY(20px);
    animation: fadeUp 0.8s ease forwards 0.2s;
}

.hero-title {
    opacity: 0;
    transform: translateY(30px);
    animation: fadeUp 0.8s ease forwards 0.4s;
}

.hero-tagline {
    opacity: 0;
    transform: translateY(20px);
    animation: fadeUp 0.8s ease forwards 0.6s;
}

.hero-cta {
    opacity: 0;
    transform: translateY(20px);
    animation: fadeUp 0.8s ease forwards 0.8s;
}

@keyframes fadeUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Marquee Animation */
.marquee-track {
    animation: marquee 30s linear infinite;
}

@keyframes marquee {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}

/* Section Labels */
.section-label {
    opacity: 0;
    transform: translateY(15px);
    transition: all 0.6s ease;
}

.section-title {
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.6s ease 0.1s;
}

.section-label.visible,
.section-title.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Service Cards */
.service-card {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.5s ease;
}

.service-card.visible {
    opacity: 1;
    transform: translateY(0);
}

.service-card:nth-child(1) { transition-delay: 0.05s; }
.service-card:nth-child(2) { transition-delay: 0.1s; }
.service-card:nth-child(3) { transition-delay: 0.15s; }
.service-card:nth-child(4) { transition-delay: 0.2s; }
.service-card:nth-child(5) { transition-delay: 0.25s; }
.service-card:nth-child(6) { transition-delay: 0.3s; }

/* Gallery */
.gallery-item {
    opacity: 0;
    transform: scale(0.95);
    transition: all 0.5s ease;
    cursor: pointer;
}

.gallery-item.visible {
    opacity: 1;
    transform: scale(1);
}

.gallery-item:hover .gallery-img {
    transform: scale(1.08);
}

.gallery-img {
    transition: transform 0.6s ease;
}

/* Navbar Scroll State */
#navbar.scrolled {
    background: rgba(250, 249, 246, 0.95);
    backdrop-filter: blur(12px);
    box-shadow: 0 1px 0 rgba(43, 79, 52, 0.1);
}

#navbar.scrolled .menu-line {
    background: #1c3323;
}

/* Mobile Menu */
.mobile-link {
    opacity: 0;
    transform: translateY(15px);
    transition: all 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; }

/* Mobile Menu Button Animation */
#menu-btn.active .menu-line:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}
#menu-btn.active .menu-line:nth-child(2) {
    opacity: 0;
}
#menu-btn.active .menu-line:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
    width: 6px;
}

/* Responsive */
@media (max-width: 768px) {
    .hero-title {
        font-size: 3.5rem;
    }
    
    .section-title {
        font-size: 2.5rem;
    }
    
    .floating-card {
        position: relative;
        bottom: 0;
        right: 0;
        margin-top: 1rem;
    }
}

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        transition-duration: 0.01ms !important;
    }
    
    html {
        scroll-behavior: auto;
    }
    
    .marquee-track {
        animation: none;
    }
}
