/* ── SERVICES PAGE CSS — ANIMATED ── */

@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@400;700;900&family=DM+Sans:wght@300;400;500;600&display=swap');

:root {
    --dark: #0f172a;
    --dark-card: #1e293b;
    --green: #4ade80;
    --green-pale: rgba(74, 222, 128, 0.12);
    --blue: #3b82f6;
    --gold: #f59e0b;
    --muted: #64748b;
    --muted-light: #94a3b8;
    --border: rgba(255, 255, 255, 0.1);
    /* Animation timing */
    --ease-out-expo: cubic-bezier(0.16, 1, 0.3, 1);
    --ease-out-back: cubic-bezier(0.34, 1.56, 0.64, 1);
    --duration-fast: 0.25s;
    --duration-base: 0.5s;
    --duration-slow: 0.75s;
}

body {
    font-family: 'DM Sans', sans-serif;
    background: var(--dark);
    color: #e2e8f0;
    line-height: 1.6;
}

/* ──────────────────────────────────────────
   KEYFRAMES
────────────────────────────────────────── */

@keyframes fadeSlideUp {
    from {
        opacity: 0;
        transform: translateY(36px);
    }

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

@keyframes fadeSlideLeft {
    from {
        opacity: 0;
        transform: translateX(40px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeSlideRight {
    from {
        opacity: 0;
        transform: translateX(-40px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.88);
    }

    to {
        opacity: 1;
        transform: scale(1);
    }
}

@keyframes badgePulse {
    0%, 100% {
        box-shadow: 0 0 0 0 rgba(74, 222, 128, 0.5);
    }

    50% {
        box-shadow: 0 0 0 8px rgba(74, 222, 128, 0);
    }
}

@keyframes shimmer {
    from {
        background-position: -400px 0;
    }

    to {
        background-position: 400px 0;
    }
}

@keyframes heroTextReveal {
    from {
        opacity: 0;
        transform: translateY(24px) skewY(1deg);
    }

    to {
        opacity: 1;
        transform: translateY(0) skewY(0deg);
    }
}

@keyframes dotPop {
    0% {
        transform: scale(0);
        opacity: 0;
    }

    60% {
        transform: scale(1.35);
        opacity: 1;
    }

    100% {
        transform: scale(1);
        opacity: 1;
    }
}

@keyframes ripple {
    from {
        transform: scale(0);
        opacity: 0.6;
    }

    to {
        transform: scale(3.5);
        opacity: 0;
    }
}

@keyframes borderGlow {
    0%, 100% {
        border-color: rgba(255,255,255,0.1);
    }

    50% {
        border-color: rgba(74,222,128,0.35);
    }
}

/* ──────────────────────────────────────────
   HERO — staggered text reveals
────────────────────────────────────────── */

.page-hero {
    background: linear-gradient(135deg, #065f46 0%, #1e3a8a 100%);
    color: #fff;
    padding: 7rem 2rem 5rem;
    position: relative;
    text-align: center;
    overflow: hidden;
}

.page-hero-texture {
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse 50% 70% at 10% 40%, rgba(74,222,128,0.1) 0%, transparent 60%), radial-gradient(ellipse 40% 60% at 90% 60%, rgba(59,130,246,0.1) 0%, transparent 60%);
    animation: fadeSlideUp var(--duration-slow) var(--ease-out-expo) both;
}

.page-hero-grid {
    position: absolute;
    inset: 0;
    background-image: linear-gradient(rgba(255,255,255,0.03) 1px, transparent 1px), linear-gradient(90deg, rgba(255,255,255,0.03) 1px, transparent 1px);
    background-size: 60px 60px;
    animation: fadeSlideUp 1.2s var(--ease-out-expo) 0.1s both;
}

.page-hero-inner {
    position: relative;
    z-index: 2;
    max-width: 800px;
    margin: 0 auto;
}

.page-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: rgba(74,222,128,0.12);
    border: 1px solid rgba(74,222,128,0.3);
    color: #4ade80;
    font-size: 0.75rem;
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    padding: 0.5rem 1.25rem;
    border-radius: 100px;
    margin-bottom: 2rem;
    animation: scaleIn var(--duration-slow) var(--ease-out-back) 0.15s both;
}

    .page-eyebrow::before {
        content: '';
        width: 6px;
        height: 6px;
        border-radius: 50%;
        background: #4ade80;
        animation: badgePulse 2.4s ease-in-out 1s infinite;
    }

.page-heading {
    font-family: 'Playfair Display', serif;
    font-size: clamp(2.5rem, 5vw, 4.5rem);
    font-weight: 900;
    line-height: 1.1;
    margin-bottom: 1.5rem;
    animation: heroTextReveal var(--duration-slow) var(--ease-out-expo) 0.3s both;
}

    .page-heading .accent {
        color: #4ade80;
        font-style: italic;
    }

.page-sub {
    font-size: 1.05rem;
    color: rgba(255,255,255,0.65);
    max-width: 520px;
    margin: 0 auto;
    animation: fadeSlideUp var(--duration-slow) var(--ease-out-expo) 0.45s both;
}

/* ──────────────────────────────────────────
   SECTION LAYOUT
────────────────────────────────────────── */

.section {
    padding: 6rem 2rem;
}

.section-alt {
    background: rgba(255,255,255,0.02);
}

.container {
    max-width: 1100px;
    margin: 0 auto;
}

/* ──────────────────────────────────────────
   SCROLL-REVEAL SYSTEM
   Add .reveal to any element, JS adds .visible
────────────────────────────────────────── */

.reveal {
    opacity: 0;
    transform: translateY(32px);
    transition: opacity var(--duration-slow) var(--ease-out-expo), transform var(--duration-slow) var(--ease-out-expo);
}

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

.reveal-left {
    opacity: 0;
    transform: translateX(40px);
    transition: opacity var(--duration-slow) var(--ease-out-expo), transform var(--duration-slow) var(--ease-out-expo);
}

    .reveal-left.visible {
        opacity: 1;
        transform: translateX(0);
    }

.reveal-right {
    opacity: 0;
    transform: translateX(-40px);
    transition: opacity var(--duration-slow) var(--ease-out-expo), transform var(--duration-slow) var(--ease-out-expo);
}

    .reveal-right.visible {
        opacity: 1;
        transform: translateX(0);
    }

/* Stagger delays for children — add .stagger-N to children */
.stagger-1 {
    transition-delay: 0.05s;
}

.stagger-2 {
    transition-delay: 0.12s;
}

.stagger-3 {
    transition-delay: 0.20s;
}

.stagger-4 {
    transition-delay: 0.30s;
}

.stagger-5 {
    transition-delay: 0.42s;
}

/* ──────────────────────────────────────────
   SERVICE BLOCKS
────────────────────────────────────────── */

.service-block {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: start;
    padding: 5rem 0;
    border-bottom: 1px solid var(--border);
    transition: border-color var(--duration-base) ease;
}

    .service-block:last-child {
        border-bottom: none;
    }

    .service-block:hover {
        border-color: rgba(74,222,128,0.2);
    }

    .service-block.reverse .service-card {
        order: 2;
    }

    .service-block.reverse .service-copy {
        order: 1;
    }

/* ──────────────────────────────────────────
   SERVICE CARD — glass + hover lift
────────────────────────────────────────── */

.service-card {
    padding: 2.25rem 2rem;
    border-radius: 20px;
    background: rgba(255,255,255,0.05);
    border: 1px solid var(--border);
    position: relative;
    overflow: hidden;
    cursor: default;
    /* Lift + glow on hover */
    transition: background var(--duration-base) ease, border-color var(--duration-base) ease, transform var(--duration-base) var(--ease-out-expo), box-shadow var(--duration-base) ease;
}

    .service-card::before {
        content: '';
        position: absolute;
        inset: 0;
        background: linear-gradient( 135deg, rgba(74,222,128,0.06) 0%, transparent 60% );
        opacity: 0;
        transition: opacity var(--duration-base) ease;
        border-radius: inherit;
        pointer-events: none;
    }

    /* Shimmer sweep on hover */
    .service-card::after {
        content: '';
        position: absolute;
        top: 0;
        left: -100%;
        width: 60%;
        height: 100%;
        background: linear-gradient( 90deg, transparent, rgba(255,255,255,0.04), transparent );
        transition: left var(--duration-slow) var(--ease-out-expo);
        pointer-events: none;
    }

    .service-card:hover {
        background: rgba(255,255,255,0.09);
        border-color: rgba(74,222,128,0.2);
        transform: translateY(-6px);
        box-shadow: 0 20px 40px rgba(0,0,0,0.3), 0 0 0 1px rgba(74,222,128,0.08), 0 0 60px rgba(74,222,128,0.06);
    }

        .service-card:hover::before {
            opacity: 1;
        }

        .service-card:hover::after {
            left: 140%;
        }

/* ──────────────────────────────────────────
   CARD BADGE — animated pulse
────────────────────────────────────────── */

.card-badge {
    position: absolute;
    top: 1rem;
    left: 1rem;
    padding: 0.25rem 0.75rem;
    font-size: 0.75rem;
    font-weight: 600;
    border-radius: 100px;
    text-transform: uppercase;
    color: #fff;
    animation: scaleIn var(--duration-base) var(--ease-out-back) 0.6s both;
    transition: transform var(--duration-fast) var(--ease-out-back);
}

    .card-badge:hover {
        transform: scale(1.08);
    }

.badge-green {
    background: linear-gradient(135deg, #065f46, #4ade80);
    animation-name: scaleIn, badgePulse;
    animation-duration: var(--duration-base), 3s;
    animation-delay: 0.6s, 1.5s;
    animation-timing-function: var(--ease-out-back), ease-in-out;
    animation-fill-mode: both, none;
    animation-iteration-count: 1, infinite;
}

.badge-blue {
    background: linear-gradient(135deg, #1e3a8a, #3b82f6);
}

.badge-gold {
    background: linear-gradient(135deg, #92400e, #f59e0b);
}

/* ──────────────────────────────────────────
   CARD CONTENT
────────────────────────────────────────── */

.card-title {
    font-family: 'Playfair Display', serif;
    font-size: 1.75rem;
    margin: 1rem 0;
    color: #e2e8f0;
    transition: color var(--duration-fast) ease;
}

.service-card:hover .card-title {
    color: #fff;
}

.card-desc {
    font-size: 1rem;
    color: var(--muted-light);
    margin-bottom: 1rem;
    line-height: 1.75;
    transition: color var(--duration-fast) ease;
}

.service-card:hover .card-desc {
    color: #b0c4d0;
}

/* ──────────────────────────────────────────
   FEATURE LIST — staggered dots
────────────────────────────────────────── */

.feature-list {
    list-style: none;
    padding-left: 0;
    margin-bottom: 1rem;
}

    .feature-list li {
        display: flex;
        align-items: flex-start;
        margin-bottom: 0.5rem;
        font-size: 0.9rem;
        color: var(--muted-light);
        line-height: 1.7;
        transition: color var(--duration-fast) ease, transform var(--duration-fast) ease;
    }

        .feature-list li:hover {
            color: #e2e8f0;
            transform: translateX(4px);
        }

.feature-dot {
    width: 10px;
    height: 10px;
    background: #4ade80;
    border-radius: 50%;
    margin-right: 0.75rem;
    flex-shrink: 0;
    margin-top: 5px;
    /* Stagger each dot's pop-in via nth-child in JS or manual classes */
    animation: dotPop var(--duration-base) var(--ease-out-back) both;
    transition: transform var(--duration-fast) var(--ease-out-back);
}

.feature-list li:hover .feature-dot {
    transform: scale(1.4);
}

.feature-dot-gold {
    background: var(--gold);
}

/* ──────────────────────────────────────────
   PRICE ROW — animated number reveal
────────────────────────────────────────── */

.price-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border);
    transition: border-color var(--duration-base) ease;
}

.service-card:hover .price-row {
    border-color: rgba(74,222,128,0.2);
}

.price-label {
    font-size: 0.85rem;
    color: var(--muted-light);
}

.price-num {
    font-size: 1.5rem;
    font-weight: 900;
    color: #4ade80;
    display: block;
    line-height: 1;
    transition: color var(--duration-fast) ease, transform var(--duration-fast) var(--ease-out-back);
}

.service-card:hover .price-num {
    color: #6ee7a0;
    transform: scale(1.05);
}

.price-strike {
    font-size: 0.85rem;
    color: var(--muted);
    text-decoration: line-through;
}

.price-save {
    font-size: 0.85rem;
    color: #f87171;
    animation: badgePulse 2.5s ease-in-out 2s infinite;
}

/* ──────────────────────────────────────────
   CTA BUTTONS — ripple effect
────────────────────────────────────────── */

.card-cta {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 0.5rem;
    padding: 0.75rem 1.25rem;
    border-radius: 12px;
    font-weight: 600;
    text-decoration: none;
    font-size: 0.875rem;
    position: relative;
    overflow: hidden;
    transition: opacity var(--duration-fast) ease, transform var(--duration-fast) var(--ease-out-back), box-shadow var(--duration-fast) ease;
}

    .card-cta::after {
        content: '';
        position: absolute;
        inset: 50% auto auto 50%;
        width: 8px;
        height: 8px;
        border-radius: 50%;
        background: rgba(255,255,255,0.4);
        transform: scale(0);
        opacity: 0;
        pointer-events: none;
    }

    .card-cta:hover {
        opacity: 0.9;
        transform: translateY(-2px) scale(1.02);
        box-shadow: 0 8px 20px rgba(0,0,0,0.25);
    }

    .card-cta:active {
        transform: translateY(0) scale(0.98);
    }

        .card-cta:active::after {
            animation: ripple 0.5s ease-out forwards;
        }

.card-cta-green {
    background: linear-gradient(135deg, #065f46, #1e3a8a);
    color: #4ade80;
}

.card-cta-blue {
    background: linear-gradient(135deg, #1e3a8a, #065f46);
    color: #93c5fd;
}

.card-cta-gold {
    background: linear-gradient(135deg, #92400e, #1e3a8a);
    color: #fcd34d;
}

/* Arrow nudge on hover */
.card-cta svg,
.card-cta .arrow {
    transition: transform var(--duration-fast) var(--ease-out-back);
}

.card-cta:hover svg,
.card-cta:hover .arrow {
    transform: translateX(3px);
}

/* ──────────────────────────────────────────
   SERVICE COPY
────────────────────────────────────────── */

.service-copy .section-label {
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    color: #4ade80;
    letter-spacing: 0.1em;
    margin-bottom: 0.5rem;
    /* Animated underline */
    display: inline-block;
    position: relative;
}

    .service-copy .section-label::after {
        content: '';
        position: absolute;
        bottom: -2px;
        left: 0;
        width: 0;
        height: 1px;
        background: #4ade80;
        transition: width var(--duration-slow) var(--ease-out-expo);
    }

.service-copy:hover .section-label::after {
    width: 100%;
}

.copy-heading {
    font-family: 'Playfair Display', serif;
    font-size: 1.75rem;
    margin-bottom: 1rem;
    color: #e2e8f0;
}

.copy-body {
    font-size: 0.9rem;
    color: var(--muted-light);
    margin-bottom: 1.5rem;
    line-height: 1.8;
}

/* ──────────────────────────────────────────
   BENEFIT LIST — staggered card pop-in
────────────────────────────────────────── */

.benefit-list {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
}

.benefit-item {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    flex: 1 1 200px;
    padding: 1.25rem;
    border-radius: 14px;
    background: rgba(255,255,255,0.04);
    border: 1px solid var(--border);
    position: relative;
    overflow: hidden;
    transition: background var(--duration-base) ease, border-color var(--duration-base) ease, transform var(--duration-base) var(--ease-out-expo), box-shadow var(--duration-base) ease;
}

    /* Shimmer on benefit-item hover */
    .benefit-item::after {
        content: '';
        position: absolute;
        top: 0;
        left: -100%;
        width: 50%;
        height: 100%;
        background: linear-gradient(90deg, transparent, rgba(255,255,255,0.04), transparent);
        transition: left var(--duration-slow) var(--ease-out-expo);
        pointer-events: none;
    }

    .benefit-item:hover {
        background: rgba(255,255,255,0.08);
        border-color: rgba(74,222,128,0.2);
        transform: translateY(-4px);
        box-shadow: 0 12px 28px rgba(0,0,0,0.2), 0 0 30px rgba(74,222,128,0.05);
    }

        .benefit-item:hover::after {
            left: 150%;
        }

    /* Stagger benefit items via nth-child */
    .benefit-item:nth-child(1) {
        transition-delay: 0s;
    }

    .benefit-item:nth-child(2) {
        transition-delay: 0.06s;
    }

    .benefit-item:nth-child(3) {
        transition-delay: 0.12s;
    }

    .benefit-item:nth-child(4) {
        transition-delay: 0.18s;
    }

.benefit-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    background: var(--green-pale);
    flex-shrink: 0;
    transition: transform var(--duration-fast) var(--ease-out-back), background var(--duration-fast) ease;
}

.benefit-item:hover .benefit-icon {
    transform: scale(1.15) rotate(-5deg);
    background: rgba(74,222,128,0.2);
}

.benefit-title {
    font-weight: 700;
    margin-bottom: 0.25rem;
    font-size: 0.95rem;
    color: #e2e8f0;
    transition: color var(--duration-fast) ease;
}

.benefit-item:hover .benefit-title {
    color: #fff;
}

.benefit-desc {
    font-size: 0.875rem;
    color: var(--muted-light);
    line-height: 1.65;
    transition: color var(--duration-fast) ease;
}

.benefit-item:hover .benefit-desc {
    color: #b0c4d0;
}

/* ──────────────────────────────────────────
   RESPONSIVE
────────────────────────────────────────── */

@media (max-width: 768px) {
    .service-block {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

        .service-block.reverse .service-card,
        .service-block.reverse .service-copy {
            order: 0;
        }

    .benefit-list {
        flex-direction: column;
    }

    /* Reduce motion on small screens by default */
    .service-card:hover {
        transform: translateY(-3px);
    }

    .benefit-item:hover {
        transform: translateY(-2px);
    }
}

/* ──────────────────────────────────────────
   REDUCED MOTION — respects user preference
────────────────────────────────────────── */

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

    .reveal,
    .reveal-left,
    .reveal-right {
        opacity: 1;
        transform: none;
    }
}
