/* ==========================================================================
   MÓDULO: mifloatingcontact
   Contiene:
     1. Header-top al 100% de ancho
     2. Botón flotante de contacto
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. HEADER-TOP AL 100% DEL ANCHO
   --------------------------------------------------------------------------
   Si tu tema tiene el .header-top dentro de un .container que lo limita,
   estas reglas lo expanden a todo el viewport.
   -------------------------------------------------------------------------- */

.header-top {
    width: 100% !important;
    max-width: 100% !important;
    left: 0 !important;
    right: 0 !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
    box-sizing: border-box !important;
}

/* Contenido interior con padding cómodo */
.header-top > .container,
.header-top .container {
    max-width: 100% !important;
    width: 100% !important;
    padding-left: 24px !important;
    padding-right: 24px !important;
    box-sizing: border-box !important;
}

/* Técnica para romper el max-width heredado del padre */
#header .header-top,
.page-header .header-top {
    position: relative;
    left: 50%;
    right: 50%;
    margin-left: -50vw;
    margin-right: -50vw;
    width: 100vw !important;
    max-width: 100vw !important;
}


/* --------------------------------------------------------------------------
   2. BOTÓN FLOTANTE DE CONTACTO
   -------------------------------------------------------------------------- */

/* Contenedor principal - esquina inferior derecha */
.mfc-flotante {
    position: fixed;
    bottom: 32px;
    right: 32px;
    z-index: 99999;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 10px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Arial, sans-serif;
}

/* ── Botón principal ── */
.mfc-btn-principal {
    background: linear-gradient(135deg, #4a6cf7 0%, #6a3de8 100%);
    color: #fff;
    border: none;
    border-radius: 50px;
    padding: 14px 22px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 6px 22px rgba(74, 108, 247, 0.45);
    display: flex;
    align-items: center;
    gap: 9px;
    text-decoration: none;
    transition: transform 0.22s ease, box-shadow 0.22s ease;
    white-space: nowrap;
    outline: none;
}

.mfc-btn-principal:hover,
.mfc-btn-principal:focus {
    transform: translateY(-3px) scale(1.04);
    box-shadow: 0 10px 30px rgba(74, 108, 247, 0.55);
    color: #fff;
}

.mfc-btn-principal.activo {
    background: linear-gradient(135deg, #e74c3c, #c0392b);
    box-shadow: 0 6px 22px rgba(231, 76, 60, 0.45);
}

/* Puntito verde "en línea" */
.mfc-punto-online {
    display: inline-block;
    width: 9px;
    height: 9px;
    background: #2ecc71;
    border-radius: 50%;
    flex-shrink: 0;
    animation: mfc-pulso 1.6s ease-in-out infinite;
}

@keyframes mfc-pulso {
    0%, 100% { transform: scale(1);   opacity: 1; }
    50%       { transform: scale(1.5); opacity: 0.65; }
}

/* ── Sub-menú de opciones ── */
.mfc-opciones {
    display: flex;
    flex-direction: column;
    gap: 8px;
    opacity: 0;
    pointer-events: none;
    transform: translateY(12px) scale(0.97);
    transition: opacity 0.25s ease, transform 0.25s ease;
    will-change: opacity, transform;
}

.mfc-opciones.abierto {
    opacity: 1;
    pointer-events: all;
    transform: translateY(0) scale(1);
}

/* Cada tarjeta de opción */
.mfc-opcion {
    background: #fff;
    color: #333 !important;
    border-radius: 50px;
    padding: 10px 18px;
    font-size: 0.88rem;
    font-weight: 600;
    text-decoration: none !important;
    box-shadow: 0 3px 16px rgba(0, 0, 0, 0.13);
    display: flex;
    align-items: center;
    gap: 9px;
    transition: background 0.2s, color 0.2s, transform 0.2s;
    white-space: nowrap;
}

.mfc-opcion:hover {
    transform: translateX(-5px);
}

/* Colores específicos por canal */
.mfc-whatsapp:hover    { background: #25D366; color: #fff !important; }
.mfc-email:hover       { background: #e74c3c; color: #fff !important; }
.mfc-llamar:hover      { background: #2ecc71; color: #fff !important; }
.mfc-formulario:hover  { background: #4a6cf7; color: #fff !important; }

/* Icono SVG hereda el color del texto */
.mfc-opcion svg {
    flex-shrink: 0;
    stroke: currentColor;
}
.mfc-btn-principal svg { stroke: currentColor; }

/* ── Responsive: móvil ── */
@media (max-width: 480px) {
    .mfc-flotante {
        bottom: 18px;
        right: 16px;
    }
    .mfc-btn-principal {
        padding: 12px 16px;
        font-size: 0.88rem;
    }
    .mfc-label {
        display: none; /* Solo icono en pantallas muy pequeñas */
    }
}
