/* === NUEVA REGLA: Bloquea el scroll de la página cuando el popup está abierto === */
body.popup-is-open {
    overflow: hidden;
}

/* Overlay que cubre toda la pantalla */
#veoveo-popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh; /* Usar vh para asegurar que cubra toda la altura visible */
    background-color: rgba(0, 0, 0, 0.7);
    z-index: 10000;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 15px; /* Añade un poco de espacio en los bordes de la pantalla */
    box-sizing: border-box;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}
#veoveo-popup-overlay.visible {
    opacity: 1;
    visibility: visible;
}

/* Contenido del popup */
#veoveo-popup-content {
    max-width: 600px;
    width: 100%; /* El padding del overlay controlará el espacio */
    max-height: 95vh; /* Limita la altura para que nunca sea más grande que la pantalla */
    overflow-y: auto; /* Permite scroll DENTRO del popup si el contenido es muy largo */
    position: relative;
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
    text-align: center;
}
.veoveo-popup-title {
    font-family: 'Manrope', Helvetica, Arial, Lucida, sans-serif;
}
.veoveo-popup-text {
    font-family: 'Open Sans', Helvetica, Arial, Lucida, sans-serif;
}

/* Botón de cerrar */
#veoveo-popup-close {
    position: absolute;
    top: 10px;
    right: 15px;
    background: none;
    border: none;
    font-size: 28px;
    line-height: 1;
    cursor: pointer;
    color: inherit;
    padding: 0;
}

/* Contenedor de productos */
.veoveo-popup-products {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
    margin-top: 20px;
}

/* Estilos de cada producto (AHORA ES UN ENLACE) */
.veoveo-product {
    flex: 1 1 180px; /* Permite que los productos se ajusten mejor */
    max-width: 200px;
    text-decoration: none;
    color: inherit;
    display: block;
    transition: transform 0.3s ease;
}
.veoveo-product:hover {
    transform: scale(1.05);
}
.veoveo-product:hover .veoveo-product-image img {
    border: 2px solid var(--popup-border-color, #dddddd);
}
.veoveo-product-image img {
    max-width: 100%;
    height: auto;
    border-radius: 5px;
    border: 2px solid transparent;
    transition: border 0.3s ease;
}
.veoveo-product-title {
    font-size: 1em;
    margin: 10px 0 5px;
    color: #1b3f82;
}
.veoveo-product-price {
    font-size: 0.9em;
}
.veoveo-product-price del {
    opacity: 0.7;
    margin-right: 8px;
}
.veoveo-product-price ins {
    text-decoration: none;
    font-weight: bold;
    color: #d63638;
}

/* ---- Responsive ---- */
@media (max-width: 480px) {
    .veoveo-popup-products {
        flex-direction: column;
        align-items: center;
    }
    .veoveo-product {
        flex-basis: 100%;
        max-width: 250px;
    }
}

/* === NUEVO: Estilo para el distintivo 2x1, 3x2, etc. === */
.veoveo-bogo-badge {
    background-color: #e63339; /* Un color que llame la atención */
    color: #ffffff;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.9em;
    font-weight: bold;
    margin: auto auto 0; /* Centrado y empujado hacia abajo */
    display: inline-block;
}

/* === NUEVO: Estilo para el mensaje de oferta en páginas de producto/tienda === */
.veoveo-bogo-message-product-page {
    background-color: #fff8e1; /* Un amarillo claro */
    border: 1px solid #ffecb3;
    color: #6d4c41;
    padding: 10px 15px;
    margin-top: 15px;
    text-align: center;
    border-radius: 5px;
    font-weight: bold;
}