html, body {
  margin: 0;
  padding: 0;
  overflow-x: hidden;
  max-width: 100%;
}
/* =========================
   BASE
========================= */
body {
  margin: 0;
  font-family: 'Poppins', sans-serif;

  background-image: url("https://images.unsplash.com/photo-1486406146926-c627a92ad1ab?auto=format&fit=crop&w=1920&q=80");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  background-attachment: fixed;
}

/* =========================
   HEADER
========================= */
.topbar {
  background: linear-gradient(90deg, #38bdf8, #0ea5e9);
  color: white;
  backdrop-filter: blur(10px);
  box-shadow: 0 10px 25px rgba(14, 165, 233, 0.35);
}

.menu-icons {
  display: flex;
  justify-content: space-around;
  margin-bottom: 10px;
}

.icon {
  text-align: center;
  font-size: 12px;
  color: #374151;
}

.icon a {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  color: inherit;
}

.circle {
  width: 55px;
  height: 55px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: auto;
  font-size: 22px;
  color: white;
  box-shadow: 0 6px 12px rgba(0,0,0,0.15);
  overflow: hidden;
}

.green {
  background: #22c55e;
}

.orange {
  background: #fb923c;
}

.circle .icon-img {
  width: 28px !important;
  height: 28px !important;
  object-fit: contain;
  display: block;
}

/* =========================
   HERO
========================= */
.hero-app {
  position: relative;
  padding: 80px 20px 60px;
  text-align: center;
  overflow: hidden;
}

/* capa oscura elegante */
.hero-app::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    180deg,
    rgba(255,255,255,0.25),
    rgba(255,255,255,0.85)
  );
  backdrop-filter: blur(3px);
  z-index: 0;
}

/* contenido encima */
.hero-app h1,
.hero-app p {
  position: relative;
  z-index: 1;
}
.hero-app h1 {
  font-size: 40px;
  font-weight: 900;
  letter-spacing: 0.5px;
  color: #0f172a;
  text-shadow: 0 10px 30px rgba(0,0,0,0.12);
}

.hero-app p {
  font-size: 15px;
  color: rgba(15, 23, 42, 0.75);
  font-weight: 500;
  max-width: 360px;
  margin: 0 auto;
  line-height: 1.6;
}
/* =========================
   CARD RIFA
========================= */
.card-rifa {
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(14px);
  border: 1px solid rgba(255,255,255,0.5);
  border-radius: 20px;
  padding: 26px;
  margin: -25px 15px 25px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.12);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card-rifa:hover {
  transform: translateY(-3px);
  box-shadow: 0 30px 70px rgba(0,0,0,0.18);
}

.card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
  margin-bottom: 10px;
}
.titulo-box h2 {
  font-size: 20px;
  font-weight: 900;
  color: #0f172a;
  letter-spacing: 0.3px;
}
.subtitulo {
  font-size: 13px;
  color: rgba(15, 23, 42, 0.65);
  margin-top: 4px;
}

.estado {
  background: #e0f2fe;
  color: #0369a1;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 12px;
}

.fecha,
.fecha-titulo {
  color: #6b7280;
  font-size: 14px;
}

/* =========================
   PRECIO
========================= */
.precio-box {
  background: #fef3c7;
  padding: 18px;
  border-radius: 14px;
  text-align: center;
  margin-top: 10px;
}

.precio-box h3 {
  margin: 0;
  font-size: 28px;
  color: #b45309;
}

.precio-box p {
  margin: 0;
  font-size: 13px;
  color: #92400e;
}

/* =========================
   BOTÓN
========================= */
.btn-main {
  width: 100%;
  padding: 14px;
  background: #22c55e;
  color: white;
  border: none;
  border-radius: 12px;
  font-weight: bold;
  margin-top: 12px;
  cursor: pointer;
  transition: 0.2s;
}

.btn-main:hover {
  background: #16a34a;
  transform: translateY(-2px);
}

/* =========================
   NUMEROS
========================= */
.numeros-section {
  margin: 15px;
  background: white;
  padding: 20px;
  border-radius: 16px;
}

.numeros-section h2 {
  text-align: center;
  margin-bottom: 15px;
}

#numeros {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(45px, 1fr));
  gap: 8px;
  width: 100%;
  box-sizing: border-box; /* 👈 importante */
}

.numero {
  background: #e5e7eb;
  text-align: center;
  border-radius: 8px;
  cursor: pointer;
  font-weight: bold;
  transition: 0.2s;

  display: flex;
  align-items: center;
  justify-content: center;

  aspect-ratio: 1 / 1;
  padding: 0;
  width: 100%; /* 👈 clave */
}

/* 📱 MOBILE */
@media (max-width: 480px) {
  #numeros {
    grid-template-columns: repeat(5, 1fr);
  }
}

.numero:hover {
  background: #22c55e;
  color: white;
  transform: scale(1.05);
}

.numero.ocupado {
  background: #ef4444;
  color: white;
  cursor: not-allowed;
}

/* =========================
   MODAL FONDO
========================= */
.modal {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.6);
  justify-content: center;
  align-items: center;
  z-index: 9999;
  opacity: 0;
  pointer-events: none;
  transition: 0.3s;
}

.modal.active {
  display: flex;
  opacity: 1;
  pointer-events: auto;
}

/* =========================
   MODAL PRO
========================= */
.modal-content {
  background: white;
  padding: 28px;
  border-radius: 20px;
  width: 90%;
  max-width: 420px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.25);
  animation: fadeIn 0.25s ease;
}

@keyframes fadeIn {
  from {
    transform: translateY(20px);
    opacity: 0;
  }
  to {
    transform: translateY(0);
    opacity: 1;
  }
}

/* TITULO */
.modal-content h2 {
  text-align: center;
  margin-bottom: 10px;
}

/* PRECIO */
.monto-ticket {
  text-align: center;
  background: #22c55e;
  color: white;
  padding: 10px;
  border-radius: 10px;
  margin-bottom: 15px;
  font-weight: bold;
}

/* INPUTS */
.modal-content input,
.modal-content select {
  width: 100%;
  padding: 12px;
  margin-bottom: 10px;
  border-radius: 10px;
  border: 1px solid #e5e7eb;
  background: #f9fafb;
  font-size: 14px;
  transition: 0.2s;
  box-sizing: border-box;
}

.modal-content input:focus,
.modal-content select:focus {
  outline: none;
  border-color: #22c55e;
  background: white;
}

/* CHECK */
.check {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  margin: 10px 0;
}

/* UPLOAD */
.upload-box {
  text-align: center;
  margin-bottom: 10px;
}

.upload-btn {
  display: inline-block;
  padding: 10px 16px;
  background: #111827;
  color: white;
  border-radius: 10px;
  cursor: pointer;
}

/* BOTONES */
.modal-content button {
  width: 100%;
  padding: 12px;
  margin-top: 8px;
  border: none;
  border-radius: 12px;
  font-weight: bold;
  cursor: pointer;
}

.modal-content button:first-of-type {
  background: #22c55e;
  color: white;
}

.modal-content button:first-of-type:hover {
  background: #16a34a;
}

.cerrar {
  background: #ef4444;
  color: white;
}

.cerrar:hover {
  background: #dc2626;
}
.icon[onclick] {
  cursor: pointer;
}
/* 🔥 OVERRIDE REAL (gana a TODO lo anterior) */
.circle .icon-img {
  width: 28px !important;
  height: 28px !important;
  object-fit: contain !important;
}

/* 🔥 EVITA QUE EL LINK ROMPA EL DISEÑO */
.icon a {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-decoration: none;
  color: inherit;
}

/* 🔥 CENTRADO ABSOLUTO */
.circle {
  display: flex;
  align-items: center;
  justify-content: center;
}
/* 🔥 QR MÁS PEQUEÑO Y CENTRADO */
.qr-img {
  width: 160px;        /* 👈 ajusta tamaño */
  max-width: 100%;
  display: block;
  margin: 10px auto;   /* 👈 centrado horizontal */
  border-radius: 12px;
}
/* MODAL PAGO ESTILO FOTO */
.pago-modal {
  text-align: center;
  max-width: 350px;
  background: #111827;
  color: white;
  border-radius: 18px;
}

.qr-img {
  width: 100%;
  max-width: 220px;
  margin: 15px auto;
  display: block;
  border-radius: 10px;
}

.titular {
  font-weight: bold;
  color: white;
  font-size: 18px;
  margin-top: 10px;
}

.yape-numero {
  color: #22c55e;
  font-size: 24px;
  font-weight: bold;
}
/* BOTÓN FLOTANTE PREMIUM */
.whatsapp-float {
  position: fixed;
  bottom: 25px;
  right: 25px;
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  z-index: 9999;
  animation: aparecer 0.6s ease;
}

/* ICONO */
.whatsapp-float img {
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: #25d366;
  padding: 10px;
  box-shadow: 0 10px 25px rgba(37, 211, 102, 0.35);
  transition: all 0.3s ease;
}

/* BURBUJA */
.whatsapp-float span {
  background: rgba(255,255,255,0.96);
  color: #111;
  padding: 12px 18px;
  border-radius: 30px;
  font-weight: 700;
  font-size: 14px;
  box-shadow: 0 8px 25px rgba(0,0,0,0.12);
  border: 1px solid rgba(255,255,255,0.8);
  backdrop-filter: blur(8px);
  white-space: nowrap;
  transition: all 0.3s ease;
}

/* HOVER */
.whatsapp-float:hover img {
  transform: scale(1.08) rotate(5deg);
  box-shadow: 0 12px 28px rgba(37, 211, 102, 0.45);
}

.whatsapp-float:hover span {
  transform: translateX(-3px);
  box-shadow: 0 10px 28px rgba(0,0,0,0.18);
}

/* ANIMACIÓN */
@keyframes aparecer {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* =========================
   🔥 UPGRADE VISUAL PRO
========================= */
/* HEADER MÁS PREMIUM */
.topbar {
  z-index: 9999;
  backdrop-filter: blur(10px);
  box-shadow: 0 10px 25px rgba(0,0,0,0.12);
}

/* EFECTO GLASS EN ICONOS */
.menu-icons {
  padding: 5px 0;
}

/* ICONOS MÁS PRO */
.icon {
  transition: transform 0.25s ease, filter 0.25s ease;
}

.icon:hover {
  transform: translateY(-3px) scale(1.05);
  filter: brightness(1.1);
}

/* CÍRCULOS MÁS GLOSSY */
.circle {
  position: relative;
  overflow: hidden;
}

/* brillo animado */
.circle::after {
  content: "";
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: linear-gradient(
    120deg,
    transparent,
    rgba(255,255,255,0.35),
    transparent
  );
  transform: rotate(25deg);
  animation: shine 4s infinite;
}

@keyframes shine {
  0% { transform: translateX(-100%) rotate(25deg); }
  50% { transform: translateX(100%) rotate(25deg); }
  100% { transform: translateX(100%) rotate(25deg); }
}

/* BOTONES MÁS PREMIUM */
.btn-main {
  box-shadow: 0 10px 25px rgba(34,197,94,0.35);
}

.btn-main:active {
  transform: scale(0.97);
}

/* CARDS MÁS MODERNAS */
.card-rifa::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: 20px;
  background: radial-gradient(
    circle at top,
    rgba(255,255,255,0.6),
    transparent 70%
  );
  pointer-events: none;
}
.card-rifa {
  background: linear-gradient(135deg, #f8fafc, #e0f2fe);
  border: 1px solid #dbeafe;
  box-shadow: 0 15px 30px rgba(37, 99, 235, 0.12);
}

/* NÚMEROS MÁS PRO */
.numero {
  transition: all 0.25s ease;
}

.numero:hover {
  box-shadow: 0 8px 18px rgba(34,197,94,0.25);
}

.numero.ocupado {
  opacity: 0.7;
}

/* MODAL MÁS PREMIUM */
.modal-content {
  border: 1px solid rgba(255,255,255,0.3);
  backdrop-filter: blur(12px);
}

/* WHATSAPP MÁS PRO */
.whatsapp-float img {
  animation: pulseWA 2.5s infinite;
}

@keyframes pulseWA {
  0% { transform: scale(1); }
  50% { transform: scale(1.08); }
  100% { transform: scale(1); }
}

/* SCROLL SUAVE GENERAL */
html {
  scroll-behavior: smooth;
}
.tc-item {
  border-bottom: 1px solid #e5e7eb;
}

.tc-title {
  padding: 14px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  user-select: none;
}

.tc-content {
  max-height: 0;
  overflow: hidden;
  padding: 0 14px;
  font-size: 14px;
  color: #374151;
  line-height: 1.6;
  transition: max-height 0.3s ease, padding 0.3s ease;
}
.tc-item.active .tc-content {
  max-height: 500px; /* clave */
  padding: 10px 14px 14px;
}
.link-terminos {
  cursor: pointer !important;
  text-decoration: underline;
  color: #2563eb;
  font-weight: 600;
}

.link-terminos:hover {
  color: #1d4ed8;
}
.empresa {
  text-align: center;
  margin: 10px auto 20px auto;
  font-size: 13px;
  color: #6b7280;
  line-height: 1.6;
  display: flex;
  flex-direction: column;
  align-items: center;
}
.modal {
  align-items: center;
}

.modal-content {
  max-height: 85vh;
  overflow-y: auto;
}
/* 👑 PREMIO PRINCIPAL */
.premio-principal {
  position: relative;
  background: linear-gradient(135deg, #facc15, #f59e0b);
  border-radius: 26px;
  padding: 25px;
  margin-bottom: 30px;
  text-align: center;
  overflow: hidden;
  transform: scale(1.05);
}

.titulo-principal {
  font-size: 18px;
  font-weight: 900;
  color: white;
  margin-bottom: 10px;
}

.nombre-principal {
  font-size: 18px;
  font-weight: 900;
  color: white;
}

.premio-principal img {
  width: 100%;
  max-width: 250px;
  border-radius: 18px;
  margin: 15px 0;
  box-shadow: 0 12px 30px rgba(0,0,0,.35);
}

/* ✨ BRILLO */
.brillo {
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(120deg, transparent, rgba(255,255,255,.5), transparent);
  animation: brillo 2.5s infinite;
}

/* 🎁 TARJETAS */
.premio-card {
  background: linear-gradient(135deg, #ffffff, #f8fafc);
  border-radius: 18px;
  padding: 18px;
  margin-bottom: 18px;
  box-shadow: 0 10px 25px rgba(0,0,0,.12);
  text-align: center;
  transition: .3s;
}

.premio-card:hover {
  transform: scale(1.04);
}

.titulo-card {
  font-size: 14px;
  color: #64748b;
  margin-bottom: 5px;
  font-weight: 600;
}

.nombre-card {
  font-size: 16px;
  font-weight: 700;
  color: #0f172a;
}

.premio-card img {
  width: 100%;
  max-width: 200px;
  border-radius: 14px;
  margin: 10px 0;
  box-shadow: 0 6px 15px rgba(0,0,0,.15);
}

/* 🔥 ANIMACIÓN */
@keyframes brillo {
  0% { left: -100%; }
  100% { left: 100%; }
}
/* ===== MODAL GANADORES PRO ===== */

.loading-ganadores{
  text-align:center;
  font-size:18px;
  color:#fff;
  animation:pulse 1s infinite;
}

@keyframes pulse{
  0%{opacity:0.4}
  50%{opacity:1}
  100%{opacity:0.4}
}

/* CARD */
.ganador-card{
  background: linear-gradient(145deg,#111,#1c1c1c);
  border:1px solid rgba(255,255,255,0.08);
  margin:12px 0;
  padding:18px;
  border-radius:14px;
  position:relative;
  overflow:hidden;
  color:#fff;

  transform: translateY(20px);
  opacity:0;
}

/* ANIMACIÓN ENTRADA */
.animate-in{
  animation: slideUp 0.6s ease forwards;
}

@keyframes slideUp{
  to{
    transform: translateY(0);
    opacity:1;
  }
}

/* BRILLO MOVIL */
.shine{
  position:absolute;
  top:-50%;
  left:-50%;
  width:200%;
  height:200%;
  background: linear-gradient(
    120deg,
    transparent,
    rgba(255,255,255,0.08),
    transparent
  );
  transform: rotate(25deg);
  animation: shineMove 2.5s infinite;
}

@keyframes shineMove{
  0%{transform:translateX(-100%) rotate(25deg);}
  100%{transform:translateX(100%) rotate(25deg);}
}

/* TITULO */
.titulo-ganador{
  font-size:13px;
  opacity:0.7;
  margin-bottom:5px;
  letter-spacing:1px;
}

/* NOMBRE */
.nombre-ganador{
  font-size:18px;
  font-weight:700;
}

/* EFECTO PRIMER GANADOR (BONUS) */
.ganador-card:first-child{
  background: linear-gradient(135deg,#ffd700,#ffb300);
  color:#000;
  font-weight:800;
  box-shadow:0 0 25px rgba(255,215,0,0.4);
}
.numero.ocupado {
  background: #ef4444;
  color: white;
}

.numero.pendiente {
  background: #f59e0b;
  color: white;
}
.contador {
  margin-top: 10px;
  font-weight: bold;
  font-size: 18px;
  color: #2563eb;
}
.card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
}

.titulo-box h2 {
  margin: 0;
  font-size: 18px;
  font-weight: 800;
  color: #111827;
}

.subtitulo {
  margin: 4px 0 0;
  font-size: 12px;
  color: #6b7280;
}

.estado {
  background: #ecfdf5;
  color: #059669;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
}

/* punto tipo “en vivo” */
.estado::before {
  content: "";
  display: inline-block;
  width: 8px;
  height: 8px;
  background: #22c55e;
  border-radius: 50%;
  margin-right: 6px;
  animation: pulse 1.5s infinite;
}

@keyframes pulse {
  0% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.6); opacity: 0.5; }
  100% { transform: scale(1); opacity: 1; }
}
.titulo-box h2 {
  font-size: 20px;
  font-weight: 900;
  letter-spacing: 0.5px;
  color: #0f172a;
}

.subtitulo {
  font-size: 13px;
  color: #64748b;
  font-weight: 500;
}
.premios-home{
  width:100%;
  max-width:900px;
  margin:20px auto;
  display:grid;
  grid-template-columns:repeat(auto-fit, minmax(250px, 1fr));
  gap:15px;
  padding:0 15px;
  justify-items: center; /* 🔥 ESTE ES EL CENTRADO REAL */
}

.premio-card{
  background:#fff;
  border-radius:15px;
  overflow:hidden;
  box-shadow:0 4px 12px rgba(0,0,0,.1);
}

.premio-card img{
  width: 100%;
  height: 220px;
  object-fit: cover;
  object-position: center;
  display: block;
}

.premio-info{
  padding:12px;
  text-align:center;
}

.premio-info h3{
  margin:0;
  font-size:18px;
  font-weight:600;

  position:relative;
  overflow:hidden;
}

.premio-info h3::after{
  content:"";
  position:absolute;
  top:0;
  left:-120%;

  width:40%;
  height:100%;

  background:linear-gradient(
      120deg,
      transparent,
      rgba(255,255,255,.7),
      transparent
  );

  animation: brilloNombre 3s infinite;
}
.premio-mayor{
  width:100%;
  grid-column:1 / -1;
  background:#fff;
  border-radius:20px;
  overflow:hidden;
  margin-bottom:25px;
  box-shadow:0 8px 25px rgba(0,0,0,.15);
}

.titulo-premio-mayor{
  position:relative;
  overflow:hidden;

  background:linear-gradient(135deg,#f59e0b,#f97316);
  color:#fff;
  text-align:center;
  padding:18px;
  font-size:30px;
  font-weight:700;
}

/* Efecto de brillo */
.titulo-premio-mayor::after{
  content:"";
  position:absolute;
  top:0;
  left:-120%;

  width:50%;
  height:100%;

  background:linear-gradient(
    120deg,
    transparent,
    rgba(255,255,255,.7),
    transparent
  );

  animation: brilloPremio 2.5s infinite;
}

@keyframes brilloPremio{
  from{
    left:-120%;
  }
  to{
    left:150%;
  }
}

.premio-mayor img{
  width:100%;
  max-height:500px;
  object-fit:cover;
  display:block;
}

.nombre-premio-mayor{
    text-align:center;
    font-size:32px;
    font-weight:700;
    padding:20px;

    position:relative;
    overflow:hidden;
}

.nombre-premio-mayor::after{
    content:"";
    position:absolute;
    top:0;
    left:-120%;

    width:40%;
    height:100%;

    background:linear-gradient(
        120deg,
        transparent,
        rgba(255,255,255,.7),
        transparent
    );

    animation: brilloNombre 3s infinite;
}

@keyframes brilloNombre{
    from{
        left:-120%;
    }
    to{
        left:150%;
    }
}

.premio-info{
  padding:12px;
  text-align:center;
}

.premio-info h3{
  margin:0;
  font-size:18px;
  font-weight:600;
}
@media (max-width: 600px){

  .premios-home{
    grid-template-columns: 1fr;
    padding: 0 10px;
  }

  .premio-card img{
    height: 200px;
    object-position: center;
  }

  .titulo-premio-mayor{
    font-size: 22px;
  }

  .nombre-premio-mayor{
    font-size: 24px;
  }
}