.services-section {
    padding: 105px 0 120px;
    background: var(--panel);
}

.section-heading {
    display: flex;
    justify-content: space-between;
    align-items: end;
    gap: 40px;
    margin-bottom: 48px;
}

.section-heading>p {
    max-width: 335px;
    margin: 0 0 5px;
    color: var(--muted);
    line-height: 1.6;
    font-size: var(--type-secondary);
}

.services-intro {
    display: flex;
    align-items: end;
    gap: 24px;
}

.services-intro>p {
    max-width: 335px;
    margin: 0 0 5px;
    color: var(--muted);
    line-height: 1.6;
    font-size: var(--type-secondary);
}

.service-carousel-controls {
    display: flex;
    flex: 0 0 auto;
    gap: 8px;
}

.carousel-arrow {
    display: grid;
    width: 42px;
    height: 42px;
    place-items: center;
    border: 1px solid var(--line);
    border-radius: 50%;
    background: transparent;
    color: var(--ink);
    font: inherit;
    font-size: 1.25rem;
    cursor: pointer;
    transition: border-color .2s, background-color .2s, color .2s;
}

.carousel-arrow:disabled {
    opacity: .45;
    cursor: not-allowed;
}

.carousel-arrow:focus-visible,
.service-grid:focus-visible,
.card-link:focus-visible {
    outline: 3px solid #639c32;
    outline-offset: 3px;
}

.service-grid {
    display: flex;
    gap: 20px;
    overflow-x: auto;
    padding: 4px 4px 18px;
    scroll-padding-inline: 4px;
    scroll-snap-type: x mandatory;
    overscroll-behavior-inline: contain;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
}

.service-grid::-webkit-scrollbar {
    display: none;
}

.service-card {
    flex: 0 0 min(440px, 40vw);
    min-width: 0;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 4px;
    background: var(--paper);
    scroll-snap-align: start;
    transition: border-color .25s, box-shadow .25s;
}

.service-card:last-child {
    scroll-snap-align: end;
}

.service-image {
    position: relative;
    height: 260px;
    overflow: hidden;
}

.service-image::after {
    position: absolute;
    inset: 25% 0 0;
    background: linear-gradient(transparent, rgba(12, 16, 12, .76));
    content: "";
    pointer-events: none;
}

.service-photo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: var(--service-image-position, center);
    transition: transform 600ms ease;
}

.service-title {
    position: absolute;
    z-index: 1;
    right: 24px;
    bottom: 22px;
    left: 24px;
    margin: 0;
    color: #fff;
    font-family: var(--font-heading);
    font-size: var(--type-h3);
    font-weight: 700;
    line-height: 1.3;
}

.card-number {
    position: absolute;
    right: 15px;
    top: 15px;
    display: grid;
    place-items: center;
    width: 38px;
    height: 38px;
    z-index: 1;
    border-radius: 50%;
    background: var(--green);
    color: var(--whatsapp-ink);
    font-size: var(--type-label);
    font-weight: 600;
}

.service-content {
    padding: 21px 24px 24px;
}

.service-content p {
    min-height: 72px;
    margin: 0 0 18px;
    color: var(--muted);
    font-size: var(--type-secondary);
    line-height: 1.6;
}

.card-link {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 15px;
    border-top: 1px solid var(--line);
    transition: color .25s, background-color .25s;
}

.card-link span {
    display: inline-block;
    transition: transform .25s;
}

.visually-hidden {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

@media (hover: hover) and (pointer: fine) {
    .carousel-arrow:not(:disabled):hover {
        border-color: var(--green);
        background: var(--green);
        color: var(--whatsapp-ink);
    }

    .service-card:hover {
        border-color: var(--green);
        box-shadow: 0 12px 30px rgba(21, 23, 20, .12);
    }

    .service-card:hover .service-photo {
        transform: scale(1.05);
    }

    .service-card:hover .card-link {
        color: #4c7e24;
    }

    :root[data-theme="dark"] .service-card:hover .card-link {
        color: var(--contact-accent);
    }

    .service-card:hover .card-link span {
        transform: translateX(4px);
    }
}

@media (prefers-reduced-motion: reduce) {
    .service-card,
    .service-photo,
    .carousel-arrow,
    .card-link,
    .card-link span {
        transition: none;
    }
}
