/* ─── Base & Reset ─── */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; }

/* ─── Scrollbar ─── */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: #ecfdf5; }
::-webkit-scrollbar-thumb { background: #059669; border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: #047857; }

/* ─── Scroll Animation Utilities ─── */
.scroll-reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.7s cubic-bezier(0.22, 1, 0.36, 1), transform 0.7s cubic-bezier(0.22, 1, 0.36, 1);
}
.scroll-reveal.revealed {
    opacity: 1;
    transform: translateY(0);
}
.scroll-reveal.delay-1 { transition-delay: 0.1s; }
.scroll-reveal.delay-2 { transition-delay: 0.2s; }
.scroll-reveal.delay-3 { transition-delay: 0.3s; }
.scroll-reveal.delay-4 { transition-delay: 0.4s; }
.scroll-reveal.delay-5 { transition-delay: 0.5s; }
.scroll-reveal.delay-6 { transition-delay: 0.6s; }

/* ─── Hero Scroll Indicator ─── */
@keyframes scrollDown {
    0% { transform: translateY(-100%); }
    100% { transform: translateY(100%); }
}
.animate-scroll-down {
    height: 100%;
    animation: scrollDown 1.5s ease-in-out infinite;
}

/* ─── Navbar ─── */
#navbar {
    background: transparent;
    transition: background 0.3s ease, box-shadow 0.3s ease, backdrop-filter 0.3s ease;
}
#navbar.scrolled {
    background: rgba(254, 253, 248, 0.92);
    backdrop-filter: blur(16px);
    box-shadow: 0 1px 20px rgba(0, 0, 0, 0.06);
}

/* ─── Hero Floating Cards ─── */
.stat-card {
    animation: float 6s ease-in-out infinite;
}
.stat-card:nth-child(2) { animation-delay: -1.5s; }
.stat-card:nth-child(3) { animation-delay: -3s; }
.stat-card:nth-child(4) { animation-delay: -4.5s; }

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

/* ─── Service Cards ─── */
.service-card {
    position: relative;
    overflow: hidden;
}
.service-card::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #059669, #10b981);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.4s cubic-bezier(0.22, 1, 0.36, 1);
}
.service-card:hover::after {
    transform: scaleX(1);
}

/* ─── Testimonial Cards ─── */
.testimonial-card {
    position: relative;
}
.testimonial-card::before {
    content: '"';
    position: absolute;
    top: 16px;
    right: 24px;
    font-family: 'Playfair Display', serif;
    font-size: 6rem;
    line-height: 1;
    color: rgba(255, 255, 255, 0.05);
    pointer-events: none;
}

/* ─── Form Focus States ─── */
input:focus, textarea:focus {
    outline: none;
}

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

/* ─── Mobile Menu Transition ─── */
#mobile-menu {
    animation: slideDown 0.3s cubic-bezier(0.22, 1, 0.36, 1);
}
@keyframes slideDown {
    from { opacity: 0; transform: translateY(-8px); }
    to { opacity: 1; transform: translateY(0); }
}
