@import url("attributes.css");

/* MODAL OVERLAY - fondo alegre, semitransparente, blur, nada fúnebre */
.eg-ofer-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(255, 245, 225, 0.85);
    backdrop-filter: blur(18px);
    z-index: 3000;
    display: flex;
    align-items: center;
    justify-content: center;
    visibility: hidden;
    opacity: 0;
    transition: visibility 0.2s, opacity 0.35s cubic-bezier(0.2, 0.9, 0.4, 1.1);
}
.eg-ofer-modal.eg-ofer-active {
    visibility: visible;
    opacity: 1;
}

/* Contenedor principal del modal - vidrio dulce y brillante */
.eg-ofer-glass {
    width: 90%;
    max-width: 1100px;
    background: rgba(255, 255, 245, 0.95);
    border-radius: 64px;
    padding: 20px;
    box-shadow: 0 30px 55px rgba(255, 107, 0, 0.25), 0 0 0 4px rgba(255, 215, 0, 0.6), 0 0 0 8px rgba(255, 107, 0, 0.2);
    backdrop-filter: blur(2px);
    position: relative;
    transition: transform 0.3s cubic-bezier(0.2, 0.9, 0.4, 1.1);
    animation: eg-ofer-float 0.4s ease-out;
}

@keyframes eg-ofer-float {
    0% {
        transform: scale(0.92) translateY(15px);
        opacity: 0;
    }
    100% {
        transform: scale(1) translateY(0);
        opacity: 1;
    }
}

/* Botón cerrar (X) superior derecha - solo aparece tras 5 segundos (diseño dulce) */
.eg-ofer-close-x {
    position: absolute;
    top: -18px;
    right: -18px;
    background: linear-gradient(145deg, #ff8c42, #ffb347);
    width: 48px;
    height: 48px;
    border-radius: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 3100;
    font-size: 28px;
    font-weight: bold;
    color: #fff6e5;
    box-shadow: 0 8px 18px rgba(0,0,0,0.15), 0 0 0 2px #fff0c0;
    transition: 0.2s;
    opacity: 0;
    visibility: hidden;
    transform: scale(0.8);
    transition: opacity 0.3s, visibility 0s linear 0.3s, transform 0.2s;
}
.eg-ofer-close-x.eg-ofer-revealed {
    opacity: 1;
    visibility: visible;
    transform: scale(1);
    transition: opacity 0.3s, visibility 0s linear 0s, transform 0.2s cubic-bezier(0.34, 1.2, 0.64, 1);
}
.eg-ofer-close-x:hover {
    transform: scale(1.1);
    background: linear-gradient(145deg, #ff9f4a, #ffcc66);
    color: white;
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

/* Contenedor de imagen con efecto "metal brillante / reflejo dulce" */
.eg-ofer-mirror {
    position: relative;
    border-radius: 48px;
    overflow: hidden;
    box-shadow: 0 20px 35px rgba(255, 107, 0, 0.3);
    background: #fff2e0;
}
/* Efecto brillo / reflejo tipo caramelo brillante */
.eg-ofer-mirror::before {
    content: "";
    position: absolute;
    top: 0;
    left: -75%;
    width: 50%;
    height: 100%;
    background: linear-gradient(120deg, rgba(255,255,200,0) 0%, rgba(255,235,140,0.6) 45%, rgba(255,215,0,0.3) 70%, rgba(255,255,200,0) 100%);
    transform: skewX(-18deg);
    z-index: 6;
    pointer-events: none;
    animation: eg-ofer-shine 5.5s infinite ease-in-out;
}
/* segunda capa de reflejo sutil dorado */
.eg-ofer-mirror::after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at 25% 35%, rgba(255, 200, 100, 0.2), rgba(255, 220, 120, 0.05));
    pointer-events: none;
    z-index: 5;
    border-radius: 48px;
}

@keyframes eg-ofer-shine {
    0% { left: -75%; opacity: 0.4; }
    35% { left: 10%; opacity: 0.9; }
    70% { left: 70%; opacity: 0.8; }
    100% { left: 130%; opacity: 0; }
}

/* Estilos slick carousel: imágenes dentro del modal */
.eg-ofer-slick-slider {
    margin: 0;
    border-radius: 48px;
}
.eg-ofer-slick-list {
    border-radius: 48px;
}
.eg-ofer-slide {
    outline: none;
    position: relative;
}
.eg-ofer-slide img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 48px;
    pointer-events: none;
    background: #fffaef;
    user-drag: none;
    -webkit-user-drag: none;
    user-select: none;
    transition: filter 0.2s;
}

/* Bloquear selección y descarga */
img {
    -webkit-touch-callout: none;
    -webkit-user-select: none;
    -khtml-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
    pointer-events: none;
}

/* Dots personalizados (alegres) */
.slick-dots {
    /*bottom: -38px;*/
}
.slick-dots li button:before {
    font-size: 12px;
    color: #ffaa44;
    opacity: 0.7;
    transition: 0.2s;
}
.slick-dots li.slick-active button:before {
    color: #ff6b00;
    opacity: 1;
    text-shadow: 0 0 4px #ffbc6e;
    transform: scale(1.2);
}

/* Flechas slick personalizadas: tonos dulces */
.slick-prev, .slick-next {
    background: #ffaa55 !important;
    border-radius: 50% !important;
    width: 42px !important;
    height: 42px !important;
    z-index: 20;
    transition: 0.2s;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}
.slick-prev:hover, .slick-next:hover {
    background: #ff8c2e !important;
    transform: scale(1.05);
}
.slick-prev:before, .slick-next:before {
    font-size: 28px !important;
    color: white !important;
    opacity: 1;
}

/* Texto marca o protección - solo decorativo, no es botón */
.eg-ofer-watermark {
    text-align: center;
    margin-top: 38px;
    font-size: 0.7rem;
    color: #e68a2e;
    font-weight: 600;
    background: rgba(255,235,200,0.6);
    display: inline-block;
    width: auto;
    padding: 4px 16px;
    border-radius: 60px;
    backdrop-filter: blur(2px);
    pointer-events: none;
}

/* Responsive */
@media (max-width: 700px) {
    .eg-ofer-glass {
        padding: 14px;
        border-radius: 48px;
    }
    .eg-ofer-close-x {
        width: 42px;
        height: 42px;
        top: -12px;
        right: -12px;
        font-size: 24px;
    }
    .slick-prev, .slick-next {
        width: 32px !important;
        height: 32px !important;
    }
    .slick-prev:before, .slick-next:before {
        font-size: 22px !important;
    }
}

/* Protección impresión */
@media print {
    .eg-ofer-modal {
        display: none !important;
    }
    body {
        visibility: hidden;
    }
}

/* toast personalizado alegre */
.eg-ofer-toast {
    position: fixed;
    bottom: 25%;
    left: 50%;
    transform: translateX(-50%);
    background: linear-gradient(135deg, #ffaa44, #ff6b00);
    color: #2e1c08;
    padding: 10px 24px;
    border-radius: 60px;
    font-weight: bold;
    z-index: 10001;
    font-family: 'Poppins', sans-serif;
    font-size: 0.9rem;
    box-shadow: 0 8px 20px rgba(0,0,0,0.2);
    backdrop-filter: blur(4px);
    border: 1px solid #ffdd99;
    white-space: nowrap;
}



/*Banner para promociones horizontales*/
#eg-promo-hori-container {
    position: absolute;
    right: 60px;
    height: 70px;
    width: auto; /* Ajusta según el ancho promedio de tus promos 250px default*/
    display: flex;
    justify-content: flex-end;
    align-items: center;
}

.eg-promo-hori-img {
    position: absolute;
    height: 70px;
    width: auto;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.8s ease-in-out; /* Transición suave de fundido */

    /* Esquinas y borde */
    border-radius: 12px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

/* Clase que activa la imagen actual */
.eg-promo-hori-img.active {
    opacity: 1;
    visibility: visible;
    /* Efecto de atención: vibra/pulsa al final de su ciclo de 10s */
    animation: eg-promo-hori-attention 3s ease-in-out infinite;
}

@keyframes eg-promo-hori-attention {
    0%, 90%, 100% { transform: scale(1); }
    95% { transform: scale(1.08); filter: brightness(1.1); }
}

/* Responsivo */
@media (max-width: 600px) {
    #eg-promo-hori-container {
        right: 60px;
        height: 68px;
    }
    .eg-promo-hori-img {
        height: 68px;
        border-width: 2px;
    }
}