/* ── Base ── */
html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    overflow-x: hidden;
}

/* ── Nav ── */
.nav-text {
    transition: color 0.3s ease;
}

header.scrolled .nav-text {
    color: #3A3430;
}

header:not(.scrolled) .nav-text {
    color: #3A3430;
}

.nav-link {
    position: relative;
    color: #3A3430;
    text-decoration: none;
    transition: color 0.3s ease;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 1px;
    background: #C4724E;
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}

.nav-link:hover {
    color: #C4724E;
}

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

.mobile-link {
    text-decoration: none;
    transition: color 0.3s ease;
}

.mobile-link:hover {
    color: #C4724E;
}

.menu-line {
    transition: all 0.3s ease;
}

#menu-toggle.active .menu-line:nth-child(1) {
    transform: rotate(45deg) translate(3px, 3px);
}

#menu-toggle.active .menu-line:nth-child(2) {
    opacity: 0;
}

#menu-toggle.active .menu-line:nth-child(3) {
    width: 24px;
    transform: rotate(-45deg) translate(3px, -3px);
}

/* ── Hero ── */
.hero-eyebrow {
    opacity: 0;
    transform: translateY(20px);
    animation: fadeUp 0.8s ease forwards;
    animation-delay: 0.3s;
}

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

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

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

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

/* ── Scroll indicator ── */
.scroll-indicator {
    animation: scrollBounce 2s ease-in-out infinite;
}

@keyframes scrollBounce {
    0%, 100% { transform: scaleY(1); opacity: 0.6; }
    50% { transform: scaleY(0.5); opacity: 0.3; }
}

/* ── Stats ── */
.stat-item {
    opacity: 0;
    transform: translateY(20px);
}

.stat-item.revealed {
    animation: fadeUp 0.6s ease forwards;
}

/* ── Eyebrow ── */
.eyebrow {
    display: block;
}

/* ── Service cards ── */
.service-card {
    opacity: 0;
    transform: translateY(30px);
}

.service-card.revealed {
    animation: fadeUp 0.6s ease forwards;
}

.service-card:nth-child(1).revealed { animation-delay: 0s; }
.service-card:nth-child(2).revealed { animation-delay: 0.1s; }
.service-card:nth-child(3).revealed { animation-delay: 0.2s; }
.service-card:nth-child(4).revealed { animation-delay: 0.3s; }
.service-card:nth-child(5).revealed { animation-delay: 0.4s; }
.service-card:nth-child(6).revealed { animation-delay: 0.5s; }

/* ── Reveal on scroll ── */
.reveal {
    opacity: 0;
    transform: translateY(40px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

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

/* ── Testimonial cards ── */
.testimonial-card {
    opacity: 0;
    transform: translateY(30px);
}

.testimonial-card.revealed {
    animation: fadeUp 0.6s ease forwards;
}

.testimonial-card:nth-child(1).revealed { animation-delay: 0s; }
.testimonial-card:nth-child(2).revealed { animation-delay: 0.15s; }
.testimonial-card:nth-child(3).revealed { animation-delay: 0.3s; }

/* ── Method steps ── */
.method-step {
    opacity: 0;
    transform: translateY(30px);
}

.method-step.revealed {
    animation: fadeUp 0.6s ease forwards;
}

.method-step:nth-child(1).revealed { animation-delay: 0s; }
.method-step:nth-child(2).revealed { animation-delay: 0.15s; }
.method-step:nth-child(3).revealed { animation-delay: 0.3s; }

/* ── CTA section ── */
.cta-primary {
    position: relative;
    overflow: hidden;
}

.cta-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.15), transparent);
    transition: left 0.5s ease;
}

.cta-primary:hover::before {
    left: 100%;
}

/* ── Cursive accent ── */
.font-serif em {
    font-style: italic;
}

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

::-webkit-scrollbar-track {
    background: #FDFBF8;
}

::-webkit-scrollbar-thumb {
    background: #D4845E;
    border-radius: 3px;
}

::-webkit-scrollbar-thumb:hover {
    background: #C4724E;
}

/* ── Selection ── */
::selection {
    background: #E4A88A;
    color: #3A3430;
}

/* ── Focus visible ── */
:focus-visible {
    outline: 2px solid #C4724E;
    outline-offset: 2px;
}

/* ── 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;
    }
}

/* ── Responsive tweaks ── */
@media (max-width: 767px) {
    .hero-title {
        font-size: 2.75rem;
    }

    .font-serif.text-4xl,
    .font-serif.text-5xl {
        font-size: 2.25rem;
    }

    .stat-item {
        padding-bottom: 1.5rem;
    }

    .stat-item.md\:border-r {
        border-right: none;
        border-bottom: 1px solid rgba(107, 101, 96, 0.1);
    }

    .stat-item:last-child {
        border-bottom: none;
    }
}
