/* ==============================> WHATSAPP — WIDGET FLOTANTE PANEL */

/* -> Disparador (botón circular fijo) */

.wsp-widget-disparador {
    position: fixed;
    bottom: 36px;
    left: 36px;
    z-index: 1000;
    width: 65px;
    height: 65px;
    background: #25d366;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 4px 16px rgba(37, 211, 102, 0.45);
    -webkit-animation: pulso-wsp 1.6s infinite;
    animation: pulso-wsp 1.6s infinite;
    -webkit-transition: background .3s ease, -webkit-transform .3s ease;
    transition: background .3s ease, transform .3s ease;
}

.wsp-widget-disparador:hover {
    background: #128c7e;
    -webkit-transform: scale(1.08);
    transform: scale(1.08);
}

.wsp-widget-icono-svg {
    width: 38px;
    height: 38px;
    display: block;
    pointer-events: none;
}

/* -> Badge de notificación */

.wsp-widget-badge {
    position: absolute;
    top: 4px;
    right: 4px;
    width: 20px;
    height: 20px;
    background: #e53e3e;
    color: #fff;
    font-size: 11px;
    font-weight: 700;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    -webkit-transition: opacity .3s ease;
    transition: opacity .3s ease;
}

/* -> Panel principal */

.wsp-widget-panel {
    position: fixed;
    bottom: 116px;
    left: 36px;
    z-index: 999;
    width: 320px;
    background: #f0f0f0;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.18);
    opacity: 0;
    pointer-events: none;
    -webkit-transform: translateY(12px) scale(0.97);
    transform: translateY(12px) scale(0.97);
    -webkit-transform-origin: bottom left;
    transform-origin: bottom left;
    -webkit-transition: opacity .28s ease, -webkit-transform .28s ease;
    transition: opacity .28s ease, transform .28s ease;
}

.wsp-widget-panel--abierto {
    opacity: 1;
    pointer-events: auto;
    -webkit-transform: translateY(0) scale(1);
    transform: translateY(0) scale(1);
}

/* -> Cabecera */

.wsp-widget-cabecera {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    background: #1a6b38;
}

.wsp-widget-avatar {
    flex-shrink: 0;
    width: 46px;
    height: 46px;
    background: #25d366;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 15px;
    font-weight: 700;
    color: #fff;
    letter-spacing: 0.5px;
}

.wsp-widget-info {
    display: flex;
    flex-direction: column;
    gap: 3px;
    flex: 1;
    min-width: 0;
}

.wsp-widget-nombre {
    font-size: 15px;
    font-weight: 700;
    color: #fff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.wsp-widget-estado {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 12px;
    color: rgba(255, 255, 255, 0.82);
}

.wsp-widget-punto {
    width: 8px;
    height: 8px;
    background: #25d366;
    border-radius: 50%;
    display: inline-block;
    flex-shrink: 0;
    box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.3);
}

.wsp-widget-cerrar {
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: #fff;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 18px;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    -webkit-transition: background .25s ease;
    transition: background .25s ease;
}

.wsp-widget-cerrar:hover {
    background: rgba(255, 255, 255, 0.38);
}

/* -> Cuerpo */

.wsp-widget-cuerpo {
    padding: 16px 14px 10px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/* -> Burbuja de mensaje */

.wsp-widget-burbuja {
    background: #fff;
    border-radius: 0 10px 10px 10px;
    padding: 12px 14px 8px;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.08);
    position: relative;
}

.wsp-widget-burbuja p {
    margin: 0 0 6px;
    font-size: 13px;
    color: #333;
    line-height: 1.55;
}

.wsp-widget-hora {
    display: block;
    text-align: right;
    font-size: 11px;
    color: #aaa;
}

/* -> Opciones de acción */

.wsp-widget-opciones {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.wsp-widget-opcion {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    padding: 11px 14px;
    background: #fff;
    border: none;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 600;
    color: #222;
    cursor: pointer;
    text-align: left;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.07);
    -webkit-transition: background .22s ease, -webkit-transform .22s ease;
    transition: background .22s ease, transform .22s ease;
}

.wsp-widget-opcion:hover {
    background: #eafaf0;
    -webkit-transform: translateX(2px);
    transform: translateX(2px);
}

.wsp-opcion-icono {
    font-size: 17px;
    flex-shrink: 0;
}

/* -> Pie con botón principal */

.wsp-widget-pie {
    padding: 10px 14px 14px;
}

.wsp-widget-boton-principal {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 12px 16px;
    background: #25d366;
    border: none;
    border-radius: 10px;
    color: #fff;
    cursor: pointer;
    gap: 2px;
    -webkit-transition: background .25s ease, -webkit-transform .25s ease;
    transition: background .25s ease, transform .25s ease;
}

.wsp-widget-boton-principal strong {
    font-size: 15px;
    font-weight: 700;
    color: #fff;
    line-height: 1.3;
}

.wsp-widget-boton-principal span {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.88);
    line-height: 1;
}

.wsp-widget-boton-principal:hover {
    background: #1da855;
    -webkit-transform: translateY(-1px);
    transform: translateY(-1px);
}

/* -> Animación de pulso */

@-webkit-keyframes pulso-wsp {
    0% {
        box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.65);
    }
    70% {
        box-shadow: 0 0 0 14px rgba(37, 211, 102, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(37, 211, 102, 0);
    }
}

@keyframes pulso-wsp {
    0% {
        box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.65);
    }
    70% {
        box-shadow: 0 0 0 14px rgba(37, 211, 102, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(37, 211, 102, 0);
    }
}

/* -> Responsive 768px */

@media (max-width: 768px) {
    .wsp-widget-disparador {
        bottom: 20px;
        left: 20px;
        width: 56px;
        height: 56px;
    }

    .wsp-widget-icono-svg {
        width: 32px;
        height: 32px;
    }

    .wsp-widget-panel {
        left: 14px;
        right: 14px;
        bottom: 90px;
        width: auto;
    }
}


/* ==============================> WHATSAPP — SHORTCODE [whatsapp-boton] */

/* -> WSP Predeterminado */

.whatsapp-predeterminado {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 24px;
    border-radius: var(--wd-brd-radius);
    background: var(--e-global-color-secondary);
    font-size: var(--wd-text-font-size);
    line-height: calc(var(--wd-text-font-size) + 4px);
    color: #fff;
    -webkit-transition: background .3s ease;
    transition: background .3s ease;
}

.whatsapp-predeterminado i {
    font-size: calc(var(--wd-text-font-size) + 4px);
    -webkit-transition: -webkit-transform .3s ease;
    transition: transform .3s ease;
}

.whatsapp-predeterminado:hover {
    background: var(--e-global-color-primary);
    color: #fff;
}

.whatsapp-predeterminado:hover i {
    -webkit-transform: scale(1.15);
    transform: scale(1.15);
}

/* -> WSP Cabecera */

.whatsapp-cabecera {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    color: var(--e-global-color-text);
    font-size: var(--wd-text-font-size);
    line-height: calc(var(--wd-text-font-size) + 4px);
    -webkit-transition: color .3s ease;
    transition: color .3s ease;
}

.whatsapp-cabecera i {
    font-size: calc(var(--wd-text-font-size) + 4px);
    -webkit-transition: -webkit-transform .3s ease;
    transition: transform .3s ease;
}

.whatsapp-cabecera:hover {
    color: var(--e-global-color-primary);
}

.whatsapp-cabecera:hover i {
    -webkit-transform: scale(1.15);
    transform: scale(1.15);
}

/* -> WSP Icono */

.whatsapp-icono {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 4px;
    border-radius: var(--wd-brd-radius);
    font-size: var(--wd-text-font-size);
    width: 20px;
    height: 20px;
    background: #25d366;
    color: #fff;
    -webkit-transition: background .3s ease, -webkit-transform .3s ease;
    transition: background .3s ease, transform .3s ease;
}

.whatsapp-icono:hover {
    background: #1da855;
    color: #fff;
    -webkit-transform: scale(1.12);
    transform: scale(1.12);
}


/* ==============================> WHATSAPP — BOTÓN EN LOOP DE PRODUCTO */

/* -> Fila interna precio + carrito dentro del contenedor columna (layout bloques) */

.wd-5b91211b {
    flex-direction: column !important;
    gap: 10px;
}

.wd-5b91211b-inner-row {
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

/* -> Contenedor del botón (ambos layouts) */

.wsp-loop-producto {
    width: 100%;
    padding: 6px 0 0;
}

.wsp-loop-producto__boton {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    width: 100%;
    padding: 8px 12px;
    background: #25d366;
    border-radius: var(--wd-brd-radius, 6px);
    font-size: 13px;
    font-weight: 600;
    color: #fff;
    text-decoration: none;
    white-space: nowrap;
    -webkit-transition: background .28s ease, -webkit-transform .28s ease;
    transition: background .28s ease, transform .28s ease;
}

.wsp-loop-producto__boton i {
    font-size: 15px;
    flex-shrink: 0;
    -webkit-transition: -webkit-transform .28s ease;
    transition: transform .28s ease;
}

.wsp-loop-producto__boton:hover {
    background: #1da855;
    color: #fff;
    -webkit-transform: translateY(-1px);
    transform: translateY(-1px);
}

.wsp-loop-producto__boton:hover i {
    -webkit-transform: scale(1.18);
    transform: scale(1.18);
}

/* -> Responsive 768px */

@media (max-width: 768px) {
    .wsp-loop-producto__boton {
        font-size: 12px;
        padding: 7px 8px;
    }
}