.meba-services-wrap,
.meba-services-wrap * {
    box-sizing: border-box;
}

.meba-services-wrap {
    --meba-red: #e50914;
    --meba-dark: #121212;
    --meba-muted: #6b7280;
    --meba-card-bg: #ffffff;
    --meba-border: rgba(18, 18, 18, .08);
    --meba-radius: 18px;
    --meba-container-width: 1200px;
    --meba-col-desktop: 4;
    --meba-col-tablet: 2;
    --meba-col-mobile: 1;
    width: 100%;
    max-width: 100%;
    overflow: hidden;
    padding: clamp(38px, 5vw, 78px) 16px;
    font-family: 'Poppins', Arial, sans-serif;
    background:
        radial-gradient(circle at 0% 0%, rgba(229, 9, 20, .055), transparent 32%),
        linear-gradient(180deg, #ffffff 0%, #fafafa 100%);
}

.meba-services-inner {
    width: min(100%, var(--meba-container-width));
    margin: 0 auto;
}

.meba-services-head {
    width: min(100%, 760px);
    margin: 0 auto clamp(24px, 3vw, 36px);
    text-align: center;
}

.meba-services-eyebrow {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin: 0 0 12px;
    color: var(--meba-red);
    font-size: 13px;
    line-height: 1.2;
    font-weight: 700;
    letter-spacing: .16em;
    text-transform: uppercase;
}

.meba-services-eyebrow::before,
.meba-services-eyebrow::after {
    content: '';
    width: 34px;
    height: 3px;
    border-radius: 999px;
    background: var(--meba-red);
}

.meba-services-title {
    margin: 0;
    color: var(--meba-dark);
    font-family: 'Poppins', Arial, sans-serif;
    font-size: clamp(28px, 3.2vw, 44px);
    line-height: 1.12;
    font-weight: 800;
    letter-spacing: -.04em;
}

.meba-services-subtitle {
    width: min(100%, 660px);
    margin: 14px auto 0;
    color: var(--meba-muted);
    font-family: 'Poppins', Arial, sans-serif;
    font-size: clamp(14px, 1.15vw, 16px);
    line-height: 1.75;
    font-weight: 400;
}

.meba-services-grid {
    display: grid;
    grid-template-columns: repeat(var(--meba-col-desktop), minmax(0, 1fr));
    gap: clamp(18px, 2.2vw, 30px);
    width: 100%;
    min-width: 0;
}

.meba-service-card {
    position: relative;
    display: flex;
    flex-direction: column;
    min-width: 0;
    overflow: hidden;
    color: inherit;
    text-decoration: none !important;
    background: var(--meba-card-bg);
    border: 1px solid var(--meba-border);
    border-radius: var(--meba-radius);
    box-shadow: 0 16px 40px rgba(15, 15, 15, .075);
    isolation: isolate;
    transform: translateY(0);
    transition: transform .28s ease, box-shadow .28s ease, border-color .28s ease;
}

.meba-service-card::before {
    content: '';
    position: absolute;
    inset: 0 0 auto 0;
    height: 4px;
    background: linear-gradient(90deg, var(--meba-red), rgba(229, 9, 20, .15));
    z-index: 2;
}

.meba-service-card:hover,
.meba-service-card:focus-visible {
    transform: translateY(-6px);
    border-color: rgba(229, 9, 20, .22);
    box-shadow: 0 22px 55px rgba(15, 15, 15, .12);
    outline: none;
}

.meba-service-image-wrap {
    position: relative;
    display: block;
    width: 100%;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    background: #f5f5f5;
}

.meba-service-image-wrap::after {
    content: '';
    position: absolute;
    inset: auto 0 0;
    height: 42%;
    background: linear-gradient(180deg, transparent 0%, rgba(0, 0, 0, .32) 100%);
    opacity: .38;
    transition: opacity .28s ease;
    pointer-events: none;
}

.meba-service-card:hover .meba-service-image-wrap::after {
    opacity: .52;
}

.meba-service-image-wrap img {
    display: block;
    width: 100%;
    height: 100%;
    max-width: none;
    object-fit: cover;
    object-position: center;
    border: 0;
    transform: scale(1.001);
    transition: transform .45s ease;
}

.meba-service-card:hover .meba-service-image-wrap img {
    transform: scale(1.06);
}

.meba-service-content {
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 10px;
    min-height: 112px;
    padding: 18px 18px 20px;
    text-align: center;
    background:
        linear-gradient(135deg, rgba(229, 9, 20, .04), transparent 34%),
        var(--meba-card-bg);
}

.meba-service-title {
    display: block;
    width: 100%;
    min-width: 0;
    color: var(--meba-dark);
    font-family: 'Poppins', Arial, sans-serif;
    font-size: clamp(15px, 1.1vw, 17px);
    line-height: 1.42;
    font-weight: 700;
    letter-spacing: -.02em;
    overflow-wrap: anywhere;
    word-break: normal;
    hyphens: auto;
}

.meba-service-more {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    align-self: center;
    gap: 8px;
    color: var(--meba-red);
    font-family: 'Poppins', Arial, sans-serif;
    font-size: 12px;
    line-height: 1.2;
    font-weight: 700;
    letter-spacing: .02em;
    opacity: .82;
}

.meba-service-more::after {
    content: '›';
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    color: #fff;
    background: var(--meba-red);
    border-radius: 999px;
    font-size: 18px;
    line-height: 18px;
    font-weight: 500;
    transition: transform .24s ease;
}

.meba-service-card:hover .meba-service-more::after {
    transform: translateX(3px);
}

@media (max-width: 1024px) {
    .meba-services-grid {
        grid-template-columns: repeat(var(--meba-col-tablet), minmax(0, 1fr));
    }
}

@media (max-width: 640px) {
    .meba-services-wrap {
        padding: 34px 14px;
    }

    .meba-services-head {
        margin-bottom: 22px;
    }

    .meba-services-grid {
        grid-template-columns: repeat(var(--meba-col-mobile), minmax(0, 1fr));
        gap: 16px;
    }

    .meba-services-eyebrow {
        font-size: 11px;
        letter-spacing: .13em;
    }

    .meba-services-eyebrow::before,
    .meba-services-eyebrow::after {
        width: 22px;
    }

    .meba-service-content {
        min-height: auto;
        padding: 16px 14px 18px;
    }

    .meba-service-card:hover {
        transform: none;
    }
}
