/* ========================================
   Overlay de Foco para Widget
   ======================================== */
   .overlay-foco {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85); /* Más oscuro que antes */
    backdrop-filter: blur(8px); /* Más difuminado */
    z-index: 9998;
    opacity: 0;
    visibility: hidden;
    transition: all 0.4s ease;
    pointer-events: none;
}

.overlay-foco.activo {
    opacity: 1;
    visibility: visible;
    pointer-events: all;
}

/* ========================================
   Contenedor del Widget
   ======================================== */
.widget-container {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.9);
    z-index: 9999;
    opacity: 0;
    visibility: hidden;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    width: 90%;
    max-width: 400px;
    pointer-events: none;
}

.widget-container.mostrar {
    opacity: 1;
    visibility: visible;
    transform: translate(-50%, -50%) scale(1);
    pointer-events: all;
}

/* Botón de cerrar */
.widget-close-btn {
    position: absolute;
    top: -40px;
    right: -10px;
    width: 35px;
    height: 35px;
    background: var(--dorado);
    color: var(--negro-primario);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 10000;
    border: 2px solid rgba(255, 255, 255, 0.2);
}

.widget-close-btn:hover {
    background: var(--dorado-claro);
    transform: rotate(90deg) scale(1.1);
}

/* Contenedor interno del widget */
#widgetAsistente {
    width: 100%;
    height: 600px;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
    background: #fff;
    position: relative;
}

/* Asegurar que el iframe del widget ocupe todo el espacio */
#widgetAsistente iframe,
#widgetAsistente > div {
    width: 100%;
    height: 100%;
    border: none;
    border-radius: 15px;
}

/* ========================================
   Efectos Hover en Tarjetas
   ======================================== */
.tarjeta-servicio {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.tarjeta-servicio:hover {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ========================================
   Resaltado de Enlace de Navegación Activo
   ======================================== */
.enlace-nav.activo {
    color: var(--dorado);
}

.enlace-nav.activo::after {
    width: 100%;
}

/* ========================================
   Efectos de Hover adicionales
   ======================================== */
.opcion-mantenimiento .boton-tarjeta:hover,
.tarjeta-servicio .boton-tarjeta:hover {
    background: var(--dorado);
    color: var(--negro-primario);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(255, 215, 0, 0.3);
}

/* ========================================
   Responsive para Widget
   ======================================== */
@media (max-width: 768px) {
    .widget-container {
        width: 95%;
        max-width: 350px;
    }
    
    #widgetAsistente {
        height: 500px;
    }
    
    .widget-close-btn {
        top: -35px;
        right: -5px;
        width: 30px;
        height: 30px;
        font-size: 20px;
    }
}

@media (max-width: 480px) {
    .widget-container {
        width: 100%;
        max-width: 320px;
    }
    
    #widgetAsistente {
        height: 450px;
        border-radius: 10px;
    }
    
    .widget-close-btn {
        top: -30px;
        right: 5px;
        width: 28px;
        height: 28px;
        font-size: 18px;
    }
}