/* ===================================
   SERVICE PAGE - HERO BANNER
   =================================== */
.service-hero {
    position: relative;
    min-height: 100px;
    max-width: 700px; /* Igual que en Jobs */
    margin: 2rem auto;
    background-image: url('../assets/img/service/service-banner.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 2rem;
}

.service-hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4);
    z-index: 1;
}

.service-hero-content {
    position: relative;
    z-index: 2;
    text-align: center;
}

.service-hero-title-white {
    font-size: 3rem;
    font-weight: 700;
    color: white;
    margin: 0;
    text-transform: capitalize;
}

/* ===================================
   SERVICES SECTION - GRID (IGUAL QUE JOBS)
   =================================== */
.services {
    padding: 5rem 2rem; /* Aumentado de 3rem a 5rem para igualar a Jobs */
    background-color: #fff;
}

.service-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2.5rem;       /* Aumentado a 2.5rem igual que Jobs */
    max-width: 1200px; /* Aumentado a 1200px igual que Jobs */
    margin: 0 auto;
    padding: 0 50px;
}

/* LA TARJETA */
.service-card {
    position: relative;
    overflow: hidden;
    border-radius: 8px;
    aspect-ratio: 4/3; /* Cambiado de 1/1 a 4/3 para igualar a Jobs */
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.service-card picture {
    position: absolute; /* Agregado */
    top: 0;             /* Agregado */
    left: 0;            /* Agregado */
    width: 100%;
    height: 100%;
    display: block;
}

/* NUEVO: Estilo para las imágenes dentro de <picture> */
.service-image-fluid {
    position: absolute; /* Esto la obliga a alinearse con la tarjeta */
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover; /* Esto hace que se recorte para llenar el cuadro sin deformarse */
    display: block;
    transition: transform 0.5s ease;
    z-index: 1; /* Para que quede detrás del texto */
}

.service-image {
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    transition: transform 0.5s ease;
}

/* EL OVERLAY */
.service-card .service-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.4s ease;
    z-index: 5;
}

/* EL TEXTO DENTRO DE LA IMAGEN */
.service-card .service-overlay h3 {
    color: white !important;
    font-size: 1.4rem; 
    font-weight: 400; 
    text-align: center;
    margin: 0;
    padding: 0 10px;
    transform: translateY(20px);
    transition: transform 0.4s ease;
}

/* ===================================
   ESTADOS HOVER
   =================================== */
.service-card:hover .service-overlay {
    opacity: 1 !important;
    visibility: visible !important;
}

.service-card:hover .service-overlay h3 {
    transform: translateY(0);
}

/* MODIFICADO: Aplica zoom a ambos tipos de imagen */
.service-card:hover .service-image,
.service-card:hover .service-image-fluid {
    transform: scale(1.1);
}

/* ===================================
   RESPONSIVE
   =================================== */
@media (max-width: 992px) {
    .service-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    /* Ajustes de la cuadrícula y contenedores */
    .services {
        padding: 3rem 1rem;
    }

    .service-grid {
        grid-template-columns: 1fr;
        padding: 0; /* Eliminamos el espacio lateral para cuadros más grandes */
        gap: 1.5rem;
    }

    .service-hero-title-white {
        font-size: 2.2rem;
    }

    /* Cuadros más grandes y texto centrado */
    .service-card {
        aspect-ratio: 16/9; /* Hace el cuadro más rectangular y grande */
    }

    .service-card .service-overlay {
        opacity: 1;
        visibility: visible;
        background: rgba(0, 0, 0, 0.5);
        display: flex;
        align-items: flex-start;
        justify-content: center;
        padding-top: 85px;
    }
    
    .service-card .service-overlay h3 {
        transform: translateY(0);
        font-size: 1.6rem; /* Texto más grande */
        font-weight: 700;
        text-align: center;
    }

    /* --- CÓDIGO DEL MENÚ PARA ESTA PÁGINA --- */
    .menu-hamburger {
        display: flex !important;
    }

    .nav-links {
        display: flex !important;
        position: fixed;
        right: -100%;
        top: 0;
        background-color: white;
        width: 75%;
        height: 100vh;
        flex-direction: column;
        justify-content: center;
        align-items: center;
        gap: 30px;
        transition: 0.5s ease;
        box-shadow: -10px 0 20px rgba(0,0,0,0.1);
        z-index: 1050;
    }

    .nav-links.active {
        right: 0 !important;
    }

    .contact-phone {
        display: none;
    }
}

/* --- ESTILO BASE HAMBURGUESA (Fuera del media query) --- */
.menu-hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 5px;
    z-index: 1100;
}

.menu-hamburger span {
    width: 25px;
    height: 3px;
    background-color: #333;
    border-radius: 2px;
    transition: 0.3s;
}

