.services_section {
    position: relative;
    padding: 80px 0;
    background: #ffffff;
    overflow: hidden;
}

/* =========================================================
   ANIMACIÓN DE FONDO & ORBES FLOTANTES
========================================================= */

/* Orbe luminoso superior derecho */
.services_section::before {
    content: '';
    position: absolute;
    top: -5%;
    right: -5%;
    width: 400px;
    height: 400px;
    border-radius: 50%;
    background: radial-gradient(circle, color-mix(in srgb, var(--color-secundario) 12%, transparent) 0%, transparent 70%);
    pointer-events: none;
    animation: floatOrbServices 10s infinite ease-in-out alternate;
}

/* Orbe luminoso inferior izquierdo */
.services_section::after {
    content: '';
    position: absolute;
    bottom: -5%;
    left: -5%;
    width: 350px;
    height: 350px;
    border-radius: 50%;
    background: radial-gradient(circle, color-mix(in srgb, var(--color-primario) 10%, transparent) 0%, transparent 70%);
    pointer-events: none;
    animation: floatOrbServices 8s infinite ease-in-out alternate-reverse;
}

@keyframes floatOrbServices {
    0% { transform: translateY(0) scale(1); }
    100% { transform: translateY(35px) scale(1.1); }
}

.section_heading_description {
    position: relative;
    z-index: 2;
    font-size: 15px;
    line-height: 1.8;
    color: #64748b;
    max-width: 620px;
    margin: 0 auto;
}


/* =========================================================
   TARJETA DE SERVICIO (SERVICE CARD)
========================================================= */

.service_card {
    position: relative;
    z-index: 2;
    background: #ffffff;
    border-radius: 20px;
    overflow: hidden;
    height: 100%;
    transition: transform .45s cubic-bezier(0.165, 0.84, 0.44, 1), box-shadow .45s ease, border-color .45s ease;
    border: 1px solid #eef2f7;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
    display: flex;
    flex-direction: column;
}

.service_card:hover {
    transform: translateY(-10px);
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.12);
    border-color: color-mix(in srgb, var(--color-secundario) 40%, transparent);
}


/* =========================================================
   PORTADA Y OVERLAY CON ANIMACIONES
========================================================= */

.service_cover {
    position: relative;
    width: 100%;
    height: 220px;
    overflow: hidden;
}

.service_cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .7s cubic-bezier(0.25, 1, 0.5, 1);
}

.service_card:hover .service_cover img {
    transform: scale(1.09);
}

.service_cover_overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        180deg,
        rgba(0, 0, 0, 0.10) 0%,
        rgba(0, 0, 0, 0.75) 100%
    );
    transition: opacity .4s ease;
}

.service_card:hover .service_cover_overlay {
    opacity: 0.9;
}

.service_cover_text {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    padding: 18px 22px;
    color: #ffffff;
    font-size: 20px;
    font-weight: 700;
    line-height: 1.35;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
    z-index: 1;
    transition: transform .4s ease;
}

.service_card:hover .service_cover_text {
    transform: translateY(-2px);
}


/* =========================================================
   CONTENIDO INTERNO Y TÍTULO ANIMADO
========================================================= */

.service_content {
    position: relative;
    padding: 24px 24px 28px;
    display: flex;
    flex-direction: column;
    flex: 1;
}

.service_content h3 {
    color: var(--color-texto);
    font-size: 22px;
    line-height: 1.3;
    font-weight: 700;
    margin-bottom: 12px;
    position: relative;
    padding-bottom: 14px;
}

/* Línea decorativa bajo el título que se expande al hacer hover */
.service_content h3::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 0;
    width: 50px;
    height: 3px;
    border-radius: 20px;
    background: linear-gradient(to right,
            var(--color-primario),
            var(--color-secundario));
    transition: width .4s ease;
}

.service_card:hover .service_content h3::after {
    width: 85px;
}

.service_content p {
    color: #64748b;
    font-size: 13.5px;
    line-height: 1.7;
    margin-bottom: 22px;
}


/* =========================================================
   BOTÓN CON DESTELLO AUTOMÁTICO
========================================================= */

.service_btn {
    position: relative;
    display: inline-flex;
    align-items: center;
    align-self: flex-start;
    gap: 10px;
    margin-top: auto;
    padding: 11px 24px;
    border-radius: 50px;
    background: linear-gradient(135deg,
            var(--color-primario),
            var(--color-secundario));
    color: #fff;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    overflow: hidden;
    transition: all .35s ease;
    box-shadow: 0 8px 22px color-mix(in srgb, var(--color-primario) 30%, transparent);
}

/* Brillo automático animado para destacar la llamada a la acción */
.service_btn::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -60%;
    width: 30%;
    height: 200%;
    background: rgba(255, 255, 255, 0.35);
    transform: rotate(30deg);
    animation: btnShine 4.5s infinite ease-in-out;
}

@keyframes btnShine {
    0% { left: -60%; }
    20% { left: 130%; }
    100% { left: 130%; }
}

.service_btn:hover {
    transform: translateY(-3px);
    color: #fff;
    box-shadow: 0 14px 28px color-mix(in srgb, var(--color-primario) 45%, transparent);
}

.service_btn i {
    transition: transform .3s ease;
    font-size: 12px;
}

.service_btn:hover i {
    transform: translateX(6px);
}


/* =========================================================
   RESPONSIVE
========================================================= */

@media(max-width:768px) {
    .services_section {
        padding: 50px 0;
    }

    .service_cover {
        height: 200px;
    }

    .service_content {
        padding: 20px 20px 24px;
    }

    .service_content h3 {
        font-size: 20px;
    }

    .service_content p {
        font-size: 14px;
    }

    .service_cover_text {
        font-size: 18px;
    }
}