:root { --negro: #0f172a; --oro: #facc15; --rojo: #e11d48; --verde: #22c55e; }

body { font-family: 'Arial Black', sans-serif; background: #f1f5f9; margin: 0; padding-bottom: 120px; }

.header-principal { background: var(--negro); height: 55px; display: flex; align-items: center; justify-content: space-between; padding: 0 2px; position: sticky; top: 0; z-index: 2000; border-bottom: 3px solid var(--oro); }
.header-extremo { width: 90px; display: flex; justify-content: center; } 
.header-centro { flex: 1; display: flex; justify-content: center; }
.logo-superior { height: 95px; position: relative; top: 20px; z-index: 2001; filter: drop-shadow(0 4px 10px rgba(0,0,0,0.5)); }
.btn-rect { background: #1e293b; color: white; border: 1px solid white; padding: 12px 2px; border-radius: 6px; font-size: 0.6rem; font-weight: bold; cursor: pointer; width: 100%; line-height: 1.2; text-align: center; }
.btn-rect.rojo { background: var(--rojo); }

.titulo-rifa { text-align: center; margin-top: 40px; font-size: 2rem; font-weight: 900; font-style: italic; text-transform: uppercase; color: var(--oro); letter-spacing: 1px; text-shadow: 2px 2px 0px var(--negro), -1px -1px 0px var(--negro), 1px -1px 0px var(--negro), -1px 1px 0px var(--negro), 1px 1px 0px var(--negro), 0px 5px 0px #b45309, 0px 8px 10px rgba(0,0,0,0.6); padding: 0 10px; }

/* CARRUSEL Y FLECHAS ULTRADELGADAS */
.contenedor-carrusel { width: 95%; margin: 15px auto; border: 8px solid var(--oro); border-radius: 20px; overflow: hidden; background: #000; box-shadow: 0 10px 20px rgba(0,0,0,0.2); }
.carrusel-visor { height: 280px; position: relative; width: 100%; overflow: hidden; border-radius: 5px; }
.slide { position: absolute; width: 100%; height: 100%; object-fit: cover; opacity: 0; visibility: hidden; transform: scale(0.85); transition: opacity 0.6s ease-in-out, transform 0.6s cubic-bezier(0.2, 0.8, 0.2, 1), visibility 0.6s; z-index: 1; }
.slide.active { opacity: 1; visibility: visible; transform: scale(1); z-index: 2; }
.carrusel-btn { position: absolute; top: 0; bottom: 0; width: 20px; background: rgba(0, 0, 0, 0); color: rgba(255, 255, 255, 0.15); border: none; font-size: 2rem; font-weight: 100; cursor: pointer; z-index: 10; display: flex; align-items: center; justify-content: center; transition: 0.3s ease; }
.carrusel-btn:hover { background: rgba(0, 0, 0, 0.4); color: white; }
.carrusel-btn.prev { left: 0; }
.carrusel-btn.next { right: 0; }

.cuerpo-info { display: flex; flex-direction: column; align-items: center; width: 100%; }
.precio-grande { color: var(--rojo); font-size: 2.8rem; margin: 5px 0 0 0; font-weight: 900; text-align: center; }
.txt-por-boleto { color: #64748b; font-size: 1rem; font-weight: bold; margin: 0 0 10px 0; text-align: center; }

.barra-ancha-progreso { display: flex; width: 95%; max-width: 600px; height: 35px; background: #cbd5e1; border-radius: 10px; overflow: hidden; border: 1px solid #94a3b8; margin: 10px 0; }
.progreso-segmento { text-align: center; line-height: 35px; color: white; font-size: 0.8rem; font-weight: bold; }
.progreso-segmento.verde { background: var(--verde); }
.progreso-segmento.amarillo { background: var(--oro); color: black; }

.banner-promociones { width: 90%; max-width: 550px; padding: 15px; border-radius: 10px; border: 3px dashed var(--oro); font-weight: bold; text-align: center; margin-top: 10px; }
.parpadeo-fuerte { animation: promo-blink 1s infinite; }
@keyframes promo-blink { 0%, 100% { background: #fffbeb; color: #854d0e; } 50% { background: var(--rojo); color: white; transform: scale(1.02); } }

.seccion-busqueda { text-align: center; padding: 10px 20px 20px 20px; display: flex; flex-direction: column; align-items: center; }
.btn-maquina-suerte { background: var(--oro); color: var(--negro); border: 3px solid var(--negro); padding: 12px 20px; font-size: 1.1rem; font-weight: 900; border-radius: 30px; cursor: pointer; width: 85%; max-width: 450px; box-shadow: 0 5px 10px rgba(0,0,0,0.2); transition: transform 0.1s; margin-top: 35px; margin-bottom: 35px; }
.btn-maquina-suerte:active { transform: scale(0.95); }
.etiqueta-busqueda { font-weight: 900; color: var(--negro); font-size: 1.1rem; margin-bottom: 12px;}
#inputBusqueda { width: 85%; max-width: 450px; padding: 15px; border-radius: 40px; border: 3px solid var(--negro); font-size: 1.2rem; text-align: center; margin-bottom: 15px; }

.grid-boletos { display: grid; grid-template-columns: repeat(auto-fill, minmax(48px, 1fr)); gap: 6px; padding: 10px; touch-action: manipulation; }
.boleto { background: white; border: 1px solid #ccc; text-align: center; font-size: 0.85rem; font-weight: bold; border-radius: 6px; cursor: pointer; transition: 0.1s; height: 42px; display: flex; align-items: center; justify-content: center; user-select: none; -webkit-tap-highlight-color: transparent; }
.boleto.selected { background: var(--negro) !important; color: white !important; transform: scale(1.1); box-shadow: 0 4px 8px rgba(0,0,0,0.3); }

/* ==================================================
   CARRITO PEGADO AL PISO Y ETIQUETAS PEQUEÑAS
   ================================================== */
.barra-reservados { 
    position: fixed; 
    bottom: 0; 
    width: 100%; 
    background: white; 
    /* El ultimo '0px' elimina el espacio debajo del boton */
    padding: 10px 10px 0px 10px; 
    flex-direction: column; gap: 5px; 
    box-shadow: 0 -10px 25px rgba(0,0,0,0.4); 
    z-index: 5000; 
    border-radius: 20px 20px 0 0; 
    box-sizing: border-box;
}

/* BOLETOS COMPRADOS (ROJO) */
    .boleto-pagado {
        background-color: #d32f2f !important; 
        color: white !important;
        border: 1px solid #b71c1c !important;
        cursor: not-allowed !important;
    }

    /* BOLETOS RESERVADOS (AMARILLO) */
    .boleto-reservado {
        background-color: #ffeb3b !important; 
        color: black !important;
        border: 1px solid #fbc02d !important;
        cursor: not-allowed !important;
    }


.resumen-pago { 
    display: flex; justify-content: space-between; 
    font-weight: bold; font-size: 1rem; 
    border-bottom: 1px solid #eee; 
    padding-bottom: 5px; margin-bottom: 5px; 
}

.numeros-elegidos { 
    display: flex; flex-wrap: wrap; 
    gap: 4px; /* Gap super reducido para que quepan mas */
    max-height: 95px; 
    overflow-y: auto; padding-right: 5px;
}

/* ETIQUETAS A LA MITAD DE TAMAÑO */
.num-tag-borrable { 
    background: #e2e8f0; color: #0f172a; 
    padding: 2px 5px; /* Relleno chiquito */
    border-radius: 4px; 
    font-size: 0.7rem; /* Letra miniatura */
    font-weight: bold; 
    display: inline-flex; align-items: center; gap: 3px; 
    border: 1px solid #cbd5e1; cursor: pointer; transition: 0.2s; 
}
.num-tag-borrable:hover { background: #fecdd3; border-color: #f43f5e; color: #9f1239; }
.tachita { color: #e11d48; font-size: 0.75rem; line-height: 1; }

.btn-apartar-flash { 
    background: var(--rojo); color: white; border: none; 
    padding: 12px; border-radius: 10px 10px 0 0; /* Base plana para pegar al suelo */
    font-weight: 900; font-size: 1.1rem; cursor: pointer; 
    animation: pulse-red 1.5s infinite; 
    margin-top: 2px; margin-bottom: 0px; 
}
@keyframes pulse-red { 0%, 100% { transform: scale(1); box-shadow: 0 0 0px var(--rojo); } 50% { transform: scale(1.02); background: #ff0000; box-shadow: 0 0 15px rgba(225, 29, 72, 0.5); } }

/* ==========================================
   MODAL MAQUINA TRAGAMONEDAS CLÁSICA
   ========================================== */

/* EL FONDO OSCURO (Sin esto no se abre) */
.modal-overlay { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.85); justify-content: center; align-items: center; z-index: 6000; }

/* EL CHASIS DE LA MÁQUINA */
.casino-style { background: linear-gradient(to bottom, #d32f2f, #990000); border: 8px solid #c0c0c0; padding: 30px 20px 40px 20px; border-radius: 60px 60px 15px 15px; width: 90%; max-width: 380px; text-align: center; position: relative; box-shadow: 0 20px 40px rgba(0,0,0,0.9), inset 0 8px 15px rgba(255,255,255,0.3), inset 0 -10px 20px rgba(0,0,0,0.6); }

.btn-cerrar-modal { position: absolute; top: -15px; right: -10px; background: #111; color: white; border: 3px solid #c0c0c0; border-radius: 50%; width: 45px; height: 45px; font-weight: 900; cursor: pointer; font-size: 1.2rem; box-shadow: 0 4px 8px rgba(0,0,0,0.5); z-index: 10; }

/* EL LETRERO SUPERIOR ILUMINADO */
.titulo-maquina-neon { background: #FFD700; color: #990000; font-weight: 900; font-size: 1.6rem; margin: -30px -20px 20px -20px; padding: 25px 10px 15px 10px; border-radius: 50px 50px 0 0; text-transform: uppercase; border-bottom: 5px solid #888; box-shadow: inset 0 -5px 10px rgba(0,0,0,0.3); letter-spacing: 1px; }

/* EL PANEL DE CONTROL METÁLICO */
.caja-input-azar { background: linear-gradient(to bottom, #dcdcdc, #a0a0a0); border: 3px solid #777; border-radius: 10px; padding: 15px; margin-bottom: 25px; box-shadow: inset 0 2px 5px rgba(255,255,255,0.8), 0 5px 10px rgba(0,0,0,0.5); }
.txt-maquina-nuevo { font-weight: 900; color: #333; margin: 0 0 10px 0; font-size: 1.1rem; text-transform: uppercase; }
.input-azar-gigante { width: 100px; padding: 5px; font-size: 1.8rem; font-weight: 900; text-align: center; border: 3px inset #666; border-radius: 5px; background: #fff; color: #990000; }

/* LA PANTALLA HUNDIDA DE LOS RODILLOS */
.maquina-tragamonedas { display: flex; justify-content: center; gap: 12px; margin-bottom: 25px; background: #111; padding: 30px 15px; border-radius: 10px; border: 6px solid #a0a0a0; box-shadow: inset 0 15px 25px rgba(0,0,0,0.9); position: relative; }
.maquina-tragamonedas::before { content: ''; position: absolute; top: 50%; left: 0; width: 100%; height: 4px; background: rgba(255, 0, 0, 0.6); z-index: 5; transform: translateY(-50%); box-shadow: 0 0 10px rgba(255,0,0,0.8); }

/* LOS RODILLOS BLANCOS Y ANIMACIÓN DE GIRO */
.ventana-rodillo { width: 75px; height: 95px; background: linear-gradient(to bottom, #cccccc, #ffffff 30%, #ffffff 70%, #cccccc); border-radius: 5px; overflow: hidden; display: flex; justify-content: center; align-items: center; position: relative; border: 2px solid #555; box-shadow: inset 0 8px 10px rgba(0,0,0,0.6), 0 2px 0px rgba(255,255,255,0.2); }
.rodillo { font-size: 4rem; font-weight: 900; color: #111; position: absolute; text-shadow: 0 2px 3px rgba(0,0,0,0.3); }

/* ANIMACIÓN PARA CUANDO ESTÁN DANDO VUELTAS */
.girando { animation: spin-reels 0.1s linear infinite; filter: blur(2px); }
@keyframes spin-reels { 0% { transform: translateY(-100%); } 100% { transform: translateY(100%); } }

/* EL BOTÓN GIGANTE ESTILO "PALANCA" */
.btn-tirar-palanca { background: linear-gradient(to bottom, #ff3333, #b30000); color: white; border: 2px solid #660000; padding: 18px; font-size: 1.4rem; font-weight: 900; border-radius: 50px; cursor: pointer; width: 90%; box-shadow: 0 10px 0px #660000, 0 15px 20px rgba(0,0,0,0.6), inset 0 5px 10px rgba(255,255,255,0.4); transition: 0.1s; text-transform: uppercase; text-shadow: 1px 1px 2px black; }
.btn-tirar-palanca:active { transform: translateY(10px); box-shadow: 0 0px 0px #660000, 0 5px 10px rgba(0,0,0,0.6), inset 0 5px 10px rgba(255,255,255,0.4); }

/* ==========================================
   NOTIFICACION VIP (Lo que perdimos de vista)
   ========================================== */
.notificacion-overlay { position: fixed; top: 0; left: 0; width: 100%; height: 100%; background: rgba(0,0,0,0.9); justify-content: center; align-items: center; z-index: 9000; }
.notificacion-caja { background: white; border: 8px solid var(--oro); padding: 30px 20px; border-radius: 30px; width: 90%; max-width: 400px; text-align: center; animation: zoomIn 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275); }
@keyframes zoomIn { from { transform: scale(0.5); opacity: 0; } to { transform: scale(1); opacity: 1; } }
.fuegos-artificiales { font-size: 3rem; margin-bottom: 10px; }
#noti-titulo { color: var(--rojo); font-size: 2.2rem; font-weight: 900; margin-bottom: 10px; }
#noti-mensaje { color: var(--negro); font-size: 1.1rem; font-weight: bold; line-height: 1.4; margin-bottom: 25px; }
.btn-reservar-directo { background: var(--rojo); color: white; border: none; padding: 15px; border-radius: 50px; font-size: 1.2rem; font-weight: 900; cursor: pointer; width: 100%; margin-bottom: 10px; box-shadow: 0 5px 15px rgba(225, 29, 72, 0.4); animation: pulse-red 1.5s infinite; }
.btn-entendido-secundario { background: #cbd5e1; color: #475569; border: none; padding: 12px; border-radius: 50px; font-size: 0.9rem; font-weight: 900; cursor: pointer; width: 100%; }

/* WHATSAPP */
.btn-whatsapp { position: fixed; bottom: 30px; left: 20px; width: 65px; height: 65px; background-color: #25d366; border-radius: 50%; display: flex; justify-content: center; align-items: center; box-shadow: 0px 4px 15px rgba(0, 0, 0, 0.3); z-index: 4000; transition: all 0.3s ease-in-out; animation: latido-wa 2s infinite; }
.btn-whatsapp img { width: 40px; height: 40px; }
@keyframes latido-wa { 0% { transform: scale(1); } 50% { transform: scale(1.05); } 100% { transform: scale(1); } }
.barra-whatsapp-final { position: relative; background: #25D366; color: white; font-weight: 900; font-size: 1rem; text-align: center; padding: 20px 10px; margin-top: 30px; display: flex; align-items: center; justify-content: center; text-decoration: none; border-radius: 15px; box-shadow: 0 4px 10px rgba(0,0,0,0.1); width: 90%; margin-left: auto; margin-right: auto; }
.barra-whatsapp-final img { width: 30px; margin-right: 15px; }

.hidden { display: none !important; }
.show-flex { display: flex !important; }

/* VISTA PARA COMPUTADORA */
@media (min-width: 768px) {
    body { background-color: #94a3b8; display: flex; flex-direction: column; align-items: center; }
    .header-principal, .contenedor-web, .barra-reservados { width: 100%; max-width: 500px !important; margin-left: auto !important; margin-right: auto !important; left: 0; right: 0; }
    .contenedor-web { background: #f1f5f9; min-height: 100vh; box-shadow: 0 0 30px rgba(0,0,0,0.3); }
    .btn-whatsapp { left: calc(50% - 250px + 20px); }
}
