/**
 * Services / Trust Section
 *
 * Clean, centered design matching Screenshot 1:
 * Eyebrow in brand color, big bold title, gray subtitle.
 * 4 centered items: Solar line-duotone icon in brand color, bold title, gray description.
 * Responsive: 2 columns on tablet, 1 on mobile. RTL compatible.
 */

.codleade-services-section {
    --svc-ground: #ffffff;
    --svc-ink: #111827;
    --svc-muted: #6b7280;
    --svc-icon: var(--codleade-brand);
    --svc-hairline: transparent;

    background-color: var(--svc-ground);
    border-top: 1px solid var(--svc-hairline);
    border-bottom: 1px solid var(--svc-hairline);
    padding-block: clamp(48px, 6vw, 76px);
}

.services-header {
    text-align: center;
    max-width: 680px;
    margin: 0 auto clamp(36px, 4.5vw, 56px);
    padding-inline: 16px;
}

.services-subtitle {
    display: block;
    color: var(--codleade-brand);
    font-size: clamp(13px, 0.95vw, 15px);
    font-weight: 600;
    letter-spacing: normal;
    text-transform: none;
    margin-bottom: 10px;
}

.services-main-title {
    font-size: clamp(26px, 2.6vw, 36px);
    font-weight: 700;
    letter-spacing: -0.015em;
    text-transform: none;
    margin: 0 0 14px;
    color: var(--svc-ink);
    line-height: 1.25;
}

.services-description {
    color: var(--svc-muted);
    font-size: clamp(14px, 1vw, 15.5px);
    line-height: 1.6;
    margin: 0 auto;
    max-width: 620px;
}

/* ── Grid: 4 columns desktop ────────────────────────────────────────── */
.services-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: clamp(24px, 3vw, 40px);
    width: 100%;
    max-width: 1200px;
    margin-inline: auto;
    padding-inline: clamp(16px, 3vw, 32px);
    align-items: start;
    box-sizing: border-box;
}

.service-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 0;
    background: none;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    width: 100%;
    max-width: 280px;
    margin-inline: auto;
}

.service-icon {
    width: clamp(48px, 3.6vw, 54px);
    height: clamp(48px, 3.6vw, 54px);
    margin-bottom: clamp(16px, 1.8vw, 22px);
    color: var(--svc-icon, var(--codleade-brand));
    display: flex;
    align-items: center;
    justify-content: center;
}

.service-icon svg {
    width: 100%;
    height: 100%;
    display: block;
}

.service-title {
    font-size: clamp(16px, 1.15vw, 18px);
    font-weight: 700;
    letter-spacing: normal;
    text-transform: none;
    line-height: 1.35;
    margin: 0 0 clamp(8px, 0.8vw, 10px);
    color: var(--svc-ink);
    text-wrap: balance;
}

.service-text {
    font-size: clamp(13px, 0.92vw, 14.5px);
    line-height: 1.55;
    color: var(--svc-muted);
    margin: 0 auto;
    max-width: 26ch;
}

/* ── Responsive adjustments: 2 columns on tablet and mobile ───────── */
@media (max-width: 991px) {
    .services-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: clamp(32px, 4vw, 48px) 24px;
        max-width: 600px;
    }
}

@media (max-width: 767px) {
    .codleade-services-section {
        padding-block: 32px;
    }

    .services-header {
        margin: 0 auto 20px;
        padding-inline: 8px;
    }

    .services-subtitle {
        font-size: 14px;
        margin-bottom: 6px;
    }

    .services-main-title {
        font-size: 22px;
        margin: 0 0 8px;
    }

    .services-description {
        font-size: 14px;
        line-height: 1.45;
    }

    .services-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 20px 12px;
        max-width: 100%;
        padding-inline: 4px;
    }

    .service-item {
        max-width: 100%;
    }

    .service-icon {
        width: 36px;
        height: 36px;
        margin-bottom: 10px;
    }

    .service-title {
        font-size: 15px;
        line-height: 1.3;
        margin-bottom: 4px;
    }

    .service-text {
        font-size: 13px;
        line-height: 1.4;
        max-width: 100%;
    }
}

/* Flush against footer if at the bottom */
#primary:has(.codleade-services-section) + .codleade-footer {
    margin-top: 0;
}

