/**
 * servicios.css - Estilos para páginas de servicios
 * Basado en 4.1.1-tabla-efectos-servicios.md
 */

/* ==========================================================================
   Hero Servicio
   ========================================================================== */
.hero-servicio {
    position: relative;
    min-height: 60vh;
    display: flex;
    align-items: center;
    overflow: hidden;
    background: linear-gradient(135deg, #1a1a1a 0%, #2d2d2d 100%);
}

.hero-servicio::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--hero-bg) center center/cover no-repeat;
    opacity: 0.4;
    z-index: 0;
    transition: all 0.5s ease;
}

.hero-servicio:hover::before {
    transform: scale(1.05);
}

.hero-servicio .container {
    position: relative;
    z-index: 2;
}

.hero-servicio h1 {
    font-size: 3rem;
    font-weight: 700;
    color: white;
    margin-bottom: 1rem;
}

.hero-servicio p {
    font-size: 1.25rem;
    color: rgba(255, 255, 255, 0.95);
    max-width: 700px;
    margin-bottom: 2rem;
}

.hero-servicio .btn-group-cta .btn {
    margin-right: 1rem;
    padding: 0.875rem 2rem;
    font-weight: 600;
}

/* ==========================================================================
   Descripción del Servicio
   ========================================================================== */
.descripcion-servicio {
    padding: 5rem 0;
}

.descripcion-servicio h2 {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
}

.descripcion-servicio .highlight-text {
    background: var(--donosti-light-gray);
    border-left: 4px solid var(--donosti-red);
    padding: 1.5rem;
    margin: 2rem 0;
    font-size: 1.125rem;
    font-weight: 600;
    border-radius: 0.375rem;
}

.descripcion-servicio .lead {
    font-size: 1.125rem;
    line-height: 1.8;
    color: var(--donosti-gray);
}

/* ==========================================================================
   Beneficios del Servicio (con fondo)
   ========================================================================== */
.beneficios-servicio {
    position: relative;
    padding: 6rem 0;
    background: #1a1a1a;
    overflow: hidden;
    color: white;
}

.beneficios-servicio::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--bg-img) center center/cover no-repeat;
    background-attachment: fixed;
    opacity: 0.35;
    z-index: 0;
}

.beneficios-servicio .container {
    position: relative;
    z-index: 1;
}

.beneficios-servicio .section-title {
    color: white;
}

.beneficios-servicio .section-title::after {
    background: white;
}

.beneficios-servicio .section-subtitle {
    color: rgba(255, 255, 255, 0.9);
}

.beneficio-card {
    background: white;
    padding: 2rem;
    border-radius: 0.75rem;
    display: flex;
    align-items: flex-start;
    height: 100%;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    color: var(--donosti-dark);
}

.beneficio-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
}

.beneficio-card i {
    font-size: 2.5rem;
    color: var(--donosti-red);
    margin-right: 1.5rem;
    flex-shrink: 0;
    transition: all 0.3s ease;
}

.beneficio-card:hover i {
    transform: scale(1.1);
}

.beneficio-card h5 {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
}

.beneficio-card p {
    font-size: 0.95rem;
    color: var(--donosti-gray);
    margin-bottom: 0;
    line-height: 1.6;
}

/* ==========================================================================
   CTA Mantenimiento (CTA Final con fondo)
   ========================================================================== */
.cta-mantenimiento {
    position: relative;
    background: #1a1a1a;
    overflow: hidden;
    color: white;
}

.cta-mantenimiento::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--cta-bg) center center/cover no-repeat;
    background-attachment: fixed;
    opacity: 0.5;
    z-index: 0;
}

.cta-mantenimiento .container {
    position: relative;
    z-index: 1;
}

.cta-mantenimiento h2,
.cta-mantenimiento p {
    color: white !important;
}

@media (max-width: 991.98px) {

    .beneficios-servicio::before,
    .cta-mantenimiento::before {
        background-attachment: scroll;
    }
}

/* ==========================================================================
   CTA Intermedio
   ========================================================================== */
.cta-intermedio {
    background: linear-gradient(135deg, var(--donosti-red) 0%, #c82333 100%);
    padding: 4rem 0;
    color: white;
    text-align: center;
}

.cta-intermedio h3 {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.cta-intermedio p {
    font-size: 1.125rem;
    opacity: 0.95;
    margin-bottom: 2rem;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

.cta-intermedio .btn-light {
    padding: 1rem 2.5rem;
    font-size: 1.125rem;
    font-weight: 600;
}

/* ==========================================================================
   Galería del Servicio
   ========================================================================== */
.galeria-servicio {
    padding: 5rem 0;
}

.galeria-servicio .gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
}

.galeria-servicio .gallery-item {
    position: relative;
    overflow: hidden;
    border-radius: 0.75rem;
    cursor: pointer;
    height: 350px;
}

.galeria-servicio .gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: all 0.4s ease;
}

.galeria-servicio .gallery-item:hover img {
    transform: scale(1.1);
}

/* Overlay con transición desde abajo (efecto rojo) */
.galeria-servicio .gallery-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(180deg, transparent 0%, rgba(220, 53, 69, 0.95) 100%);
    padding: 2rem;
    transform: translateY(100%);
    transition: all 0.4s ease;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    height: 100%;
}

.galeria-servicio .gallery-item:hover .gallery-overlay {
    transform: translateY(0);
}

.galeria-servicio .gallery-overlay h5 {
    color: white;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.galeria-servicio .gallery-overlay p {
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.9rem;
    margin-bottom: 0;
}

/* ==========================================================================
   Modal de Galería
   ========================================================================== */
.modal-gallery .modal-content {
    background: transparent;
    border: none;
}

.modal-gallery .modal-body {
    padding: 0;
}

.modal-gallery img {
    width: 100%;
    height: auto;
    border-radius: 0.5rem;
}

.modal-gallery .btn-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: white;
    opacity: 1;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    z-index: 10;
}

/* ==========================================================================
   Proceso del Servicio
   ========================================================================== */
.proceso-servicio {
    background: var(--donosti-light-gray);
    padding: 5rem 0;
}

.proceso-step {
    text-align: center;
    padding: 2rem 1.5rem;
}

.proceso-step .step-number {
    width: 60px;
    height: 60px;
    background: var(--donosti-red);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0 auto 1.5rem;
    transition: all 0.3s ease;
}

.proceso-step:hover .step-number {
    transform: scale(1.1) rotate(5deg);
    box-shadow: 0 4px 12px rgba(220, 53, 69, 0.3);
}

.proceso-step h5 {
    font-weight: 600;
    margin-bottom: 0.75rem;
}

.proceso-step p {
    color: var(--donosti-gray);
    margin-bottom: 0;
}

/* ==========================================================================
   Responsive Adjustments
   ========================================================================== */
@media (max-width: 768px) {
    .hero-servicio {
        min-height: 50vh;
    }

    .hero-servicio h1 {
        font-size: 2.25rem;
    }

    .hero-servicio .btn-group-cta .btn {
        display: block;
        width: 100%;
        margin-bottom: 0.75rem;
    }

    .galeria-servicio .gallery-grid {
        grid-template-columns: 1fr;
    }

    .galeria-servicio .gallery-item {
        height: 300px;
    }
}