/* Fixes for Máquinas layout and spacing */

/* Reducir espacio entre Estadísticas y Jackpots */
#juego-view-maquinas .sbc-module-stats {
    margin-top: 3rem !important;
    margin-bottom: 3rem !important;
    transform: none !important;
    display: flex;
    justify-content: center;
    gap: 2rem;
    flex-wrap: wrap;
}

#juego-view-maquinas .sbc-module-premios {
    padding-top: 2.5rem !important;
    padding-bottom: 2rem !important;
}

#juego-view-maquinas .sbc-module-premios .mod-title,
#juego-view-maquinas .sbc-module-premios .section-title {
    font-size: clamp(2.2rem, 3.5vw, 3rem) !important;
    margin-bottom: 1.5rem !important;
}

#juego-view-maquinas .premios-gallery {
    margin-top: 1.5rem !important;
}

/* Espaciado para Máquinas Destacadas */












/* 3. Separar el texto descriptivo del hero de las estadísticas */
#juego-view-maquinas .hero-content .mod-intro {
    margin-bottom: 3rem !important;
}

/* 4. Uniformar las tarjetas de estadísticas */
#juego-view-maquinas .sbc-stat-card {
    min-width: 260px !important;
    height: 145px !important;
    padding: 1.5rem !important;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

#juego-view-maquinas .sbc-stat-card:nth-child(2) {
    min-width: 400px !important;
}

/* Asegurar que los valores no salten de línea */
#juego-view-maquinas .stat-card-value,
#juego-view-maquinas .sbc-stat-number,
#juego-view-maquinas .sbc-stat-card h4 {
    font-size: clamp(2.6rem, 3.5vw, 3.5rem) !important;
    line-height: 1;
    white-space: nowrap;
}

/* 7. Eliminar overlays y tintes azules en Jackpots */
#juego-view-maquinas .premios-grid,
#juego-view-maquinas .premios-track {
  background: transparent !important;
  background-image: none !important;
  filter: none !important;
  mix-blend-mode: normal !important;
  opacity: 1 !important;
}

#juego-view-maquinas .premios-grid::before,
#juego-view-maquinas .premios-grid::after,
#juego-view-maquinas .premios-track::before,
#juego-view-maquinas .premios-track::after,
#juego-view-maquinas .premios-card::before,
#juego-view-maquinas .premios-card::after {
  display: none !important;
  content: none !important;
  background: none !important;
  opacity: 0 !important;
}

/* Estado Normal de Premios Card */
#juego-view-maquinas .premios-card {
  background: transparent !important;
  background-image: none !important;
  filter: none !important;
  mix-blend-mode: normal !important;
  opacity: 1 !important;
  border: 1px solid rgba(255,255,255,0.08) !important;
  outline: none !important;
  box-shadow: 0 12px 28px rgba(0,0,0,.35) !important;
  overflow: hidden !important;
  border-radius: 14px !important;
  height: auto !important;
  min-height: unset !important;
}

#juego-view-maquinas .premios-card img {
  width: 100% !important;
  height: auto !important; /* CRITICAL FIX: prevents collapsing */
  max-height: 360px !important;
  display: block !important;
  border-radius: inherit !important;
  object-fit: contain !important; 
  filter: none !important;
  mix-blend-mode: normal !important;
  opacity: 1 !important;
}

/* Hover Effect */
#juego-view-maquinas .premios-card:hover {
  border-color: rgba(212,175,55,.55) !important;
}

#juego-view-maquinas .premios-card:hover img {
  transform: scale(1.04) !important;
  transition: transform 0.3s ease !important;
}

/* Anular bordes dorados fijos en clases activas */
#juego-view-maquinas .premios-card.active,
#juego-view-maquinas .premios-card.selected,
#juego-view-maquinas .premios-card:nth-child(n) {
  border-color: rgba(255,255,255,0.08) !important;
}

#juego-view-maquinas .premios-card.active:hover,
#juego-view-maquinas .premios-card.selected:hover,
#juego-view-maquinas .premios-card:nth-child(n):hover {
  border-color: rgba(212,175,55,.55) !important;
}

/* =========================================
   REDISEÑO PANEL VIP JACKPOTS 
   ========================================= */

/* Ocultar el subtítulo original de afuera */
#juego-view-maquinas .premios-section .grp-subtitle {
    display: none !important;
}

/* Panel VIP de Jackpots */
#juego-view-maquinas .premios-hero-stat {
    background: linear-gradient(145deg, #050505, #111) !important;
    border: 1px solid rgba(212, 175, 55, 0.2) !important;
    border-top: 2px solid #D4AF37 !important;
    border-bottom: 2px solid #D4AF37 !important;
    box-shadow: 0 25px 50px rgba(0,0,0,0.8), inset 0 0 30px rgba(212,175,55,0.03) !important;
    border-radius: 12px !important;
    padding: 2.5rem 1rem !important; /* Reducción de altura */
    margin: 1rem auto 3rem !important;
    max-width: 800px;
    position: relative;
    display: block !important;
}

/* El número protagonista + Glow Dorado */
#juego-view-maquinas .central-monto {
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    gap: 0.5rem !important;
    /* Glow dorado detrás del número */
    text-shadow: 0 0 40px rgba(212, 175, 55, 0.6) !important;
    margin-bottom: 1rem !important;
}

#juego-view-maquinas .premios-stat-number,
#juego-view-maquinas .monto-prefix {
    font-size: clamp(4rem, 7vw, 6rem) !important;
    font-weight: 800 !important;
    line-height: 1 !important;
    letter-spacing: -2px !important;
    background: linear-gradient(to bottom, #ffffff 0%, #D4AF37 100%) !important;
    -webkit-background-clip: text !important;
    -webkit-text-fill-color: transparent !important;
}

/* Reemplazo visual del texto inferior en dos líneas */
#juego-view-maquinas .monto-context-line {
    visibility: hidden;
    position: relative;
    height: 3rem; /* Espacio para las dos líneas absolutas */
    margin: 0 !important;
}

#juego-view-maquinas .monto-context-line::after {
    content: "PAGOS EN PREMIOS\A ESTA SEMANA" !important;
    visibility: visible;
    position: absolute;
    left: 0;
    right: 0;
    top: 0;
    white-space: pre-line !important;
    color: #a0a0a0 !important;
    font-size: clamp(0.9rem, 1.5vw, 1.1rem) !important;
    letter-spacing: 4px !important;
    font-weight: 600 !important;
    line-height: 1.4 !important;
    text-transform: uppercase !important;
}


/* =========================================
   REDISEÑO MÁQUINAS DESTACADAS
   ========================================= */

#juego-view-maquinas .sbc-module-featured {
  max-width: 1200px !important;
  margin: 0 auto 3rem auto !important;
  padding: 0 2rem !important;
}

#juego-view-maquinas .sbc-module-featured .mod-title,
#juego-view-maquinas .sbc-module-featured .section-title,
#juego-view-maquinas .sbc-module-featured .grp-title {
  text-align: left !important;
  margin-left: 0 !important;
}

#juego-view-maquinas .sbc-module-featured .mod-subtitle,
#juego-view-maquinas .sbc-module-featured .section-subtitle,
#juego-view-maquinas .sbc-module-featured .grp-subtitle {
  text-align: left !important;
  margin-left: 0 !important;
  margin-bottom: 1.5rem !important;
}

#juego-view-maquinas .sbc-featured-gallery {
  display: grid !important;
  grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
  gap: 1.75rem !important;
  align-items: stretch !important;
}

#juego-view-maquinas .sbc-featured-card {
  display: flex !important;
  flex-direction: column !important;
  height: 100% !important;
  min-height: auto !important;
}

#juego-view-maquinas .sbc-featured-card .fc-image {
  height: 190px !important;
  object-fit: cover !important;
}

#juego-view-maquinas .sbc-featured-card .fc-content-wrapper {
  display: flex !important;
  flex-direction: column !important;
  flex: 1 !important;
}

#juego-view-maquinas .sbc-featured-card .fc-content {
  flex: 1 !important;
}

#juego-view-maquinas .sbc-featured-card .fc-cta {
  margin-top: auto !important;
}


/* =========================================
   OCULTAR METADATA DE TARJETAS (ej. 8 Pos)
   ========================================= */
#juego-view-maquinas .sbc-featured-card .fc-info {
  display: none !important;
}




/* =========================================
   COMPORTAMIENTO EXPANDIBLE NATURAL - FINAL
   ========================================= */

/* 1. Tarjetas compactas por defecto (420px) */
#juego-view-maquinas .sbc-featured-card {
  height: auto !important;
  min-height: 420px !important;
  display: flex !important;
  flex-direction: column !important;
  transition: all 0.3s ease !important;
  cursor: pointer !important;
  /* Eliminar scrollbars de todo el componente */
  scrollbar-width: none !important;
}

#juego-view-maquinas .sbc-featured-card ::-webkit-scrollbar {
  display: none !important;
}

#juego-view-maquinas .sbc-featured-card .fc-content-wrapper,
#juego-view-maquinas .sbc-featured-card .fc-content {
  flex: 1 !important;
  display: flex !important;
  flex-direction: column !important;
}

/* 2. Límite de 2 líneas en estado inicial (requiere overflow hidden localmente) */
#juego-view-maquinas .sbc-featured-card .fc-content > p {
  display: -webkit-box !important;
  -webkit-line-clamp: 2 !important;
  -webkit-box-orient: vertical !important;
  overflow: hidden !important;
  max-height: 3.4em !important;
  margin-bottom: 0 !important;
}

/* Ocultar bloque expandido por defecto */
#juego-view-maquinas .sbc-featured-card .fc-expanded-content {
  display: none !important;
  margin-top: 1rem !important;
}

/* =================ESTADO EXPANDIDO================= */

/* 3. Asegurar altura natural (auto) y visibilidad de los contenidos */
#juego-view-maquinas .sbc-featured-card.is-expanded {
  height: auto !important;
  min-height: 420px !important;
}

#juego-view-maquinas .sbc-featured-card.is-expanded .fc-content,
#juego-view-maquinas .sbc-featured-card.is-expanded .fc-content-wrapper {
  overflow: visible !important;
}

#juego-view-maquinas .sbc-featured-card.is-expanded .fc-content > p {
  -webkit-line-clamp: unset !important;
  overflow: visible !important;
  max-height: none !important;
}

#juego-view-maquinas .sbc-featured-card.is-expanded .fc-expanded-content {
  display: block !important;
  overflow: visible !important;
  max-height: none !important;
  animation: fadeIn 0.3s ease forwards;
}

/* ================== ALINEACIÓN DE BOTONES ================== */

/* Estado normal: se va al fondo con auto para simetría */
#juego-view-maquinas .sbc-featured-card .fc-cta {
  margin-top: auto !important;
  padding-top: 1rem !important; 
  background: transparent !important;
}

/* Estado expandido: se acomoda justo debajo del texto */
#juego-view-maquinas .sbc-featured-card.is-expanded .fc-cta {
  margin-top: 1rem !important;
}

/* Reemplazo de texto y flecha */
#juego-view-maquinas .sbc-featured-card .fc-cta span {
  text-transform: uppercase !important;
}

#juego-view-maquinas .sbc-featured-card.is-expanded .fc-cta span {
  font-size: 0 !important;
}

#juego-view-maquinas .sbc-featured-card.is-expanded .fc-cta span::after {
  content: "VER MENOS ↑";
  font-size: 0.9rem !important;
  letter-spacing: 2px !important;
  font-weight: 600 !important;
}

#juego-view-maquinas .sbc-featured-card.is-expanded .fc-cta svg {
  display: none !important;
}

/* 4. ERRADICAR TEXTO "8 POS" */
#juego-view-maquinas .sbc-featured-card .fc-info {
  display: none !important;
  width: 0 !important; height: 0 !important; margin: 0 !important; padding: 0 !important;
  opacity: 0 !important; position: absolute !important;
}


/* =========================================
   BLOQUES FINALES (INFO & LISTADOS)
   ========================================= */

#juego-view-maquinas .sbc-module-text,
#juego-view-maquinas .sbc-module-games-lists {
  max-width: 1200px !important;
  margin-left: auto !important;
  margin-right: auto !important;
  padding-left: 2rem !important;
  padding-right: 2rem !important;
  
  display: grid !important;
  gap: 1.6rem !important;
  
  /* Remove any invented widths or box-sizings from previous steps */
  width: auto !important;
  box-sizing: inherit !important;
}

#juego-view-maquinas .sbc-module-text {
  margin-top: 2.4rem !important;
  margin-bottom: 1.2rem !important;
}

#juego-view-maquinas .sbc-module-games-lists {
  gap: 1.6rem !important;
  margin-bottom: 3rem !important;
}

#juego-view-maquinas .sbc-text-block,
#juego-view-maquinas .sbc-games-group {
  background: linear-gradient(180deg, rgba(255,255,255,.045), rgba(255,255,255,.018)) !important;
  border: 1px solid rgba(255,255,255,.08) !important;
  border-radius: 18px !important;
  padding: 1.6rem 1.8rem !important;
  min-height: 145px !important;
  box-shadow: 0 18px 40px rgba(0,0,0,.22) !important;
}

#juego-view-maquinas .sbc-text-block h3,
#juego-view-maquinas .sbc-games-group h3,
#juego-view-maquinas .sbc-games-group .grp-title {
  color: #d4af37 !important;
  font-size: 1.25rem !important;
  margin-bottom: .5rem !important;
  letter-spacing: .02em !important;
}

#juego-view-maquinas .sbc-text-block p,
#juego-view-maquinas .sbc-games-group p {
  max-width: 54ch !important;
  font-size: .95rem !important;
  line-height: 1.65 !important;
  word-spacing: .28rem !important;
  color: rgba(255,255,255,.86) !important;
}

@media (max-width: 900px) {
  #juego-view-maquinas .sbc-module-text,
  #juego-view-maquinas .sbc-module-games-lists {
    grid-template-columns: 1fr !important;
  }
}



/* =========================================
   BLOQUES FINALES (INFO & LISTADOS)
   ========================================= */

/* 1. Mismo ancho visual que las tarjetas superiores (1280px) */
#juego-view-maquinas .sbc-module-text,
#juego-view-maquinas .sbc-module-games-lists {
  max-width: 1200px !important;
  width: 100% !important;
  margin-left: auto !important;
  margin-right: auto !important;
  padding: 0 2rem !important;
  display: grid !important;
  gap: 1.6rem !important;
  box-sizing: border-box !important;
}

/* 2. Separar limpiamente las filas */
#juego-view-maquinas .sbc-module-text {
  margin-top: 2.4rem !important;
  margin-bottom: 1.2rem !important;
}

#juego-view-maquinas .sbc-module-games-lists {
  margin-bottom: 3rem !important;
}

/* 3. Estilo de cards premium con padding equilibrado y min-height libre */
#juego-view-maquinas .sbc-text-block,
#juego-view-maquinas .sbc-games-group {
  background: linear-gradient(180deg, rgba(255,255,255,.045), rgba(255,255,255,.018)) !important;
  border: 1px solid rgba(255,255,255,.08) !important;
  border-radius: 18px !important;
  padding: 1.45rem 1.8rem !important;
  min-height: 130px !important;
  box-shadow: 0 18px 40px rgba(0,0,0,.22) !important;
}

/* Gradient exclusivo para listado de juegos */
#juego-view-maquinas .sbc-games-group {
  background: linear-gradient(180deg, rgba(212,175,55,.06), rgba(255,255,255,.018)) !important;
}

/* 4. Títulos dorados y consistentes */
#juego-view-maquinas .sbc-text-block h3,
#juego-view-maquinas .sbc-games-group h3,
#juego-view-maquinas .sbc-games-group .grp-title {
  color: #d4af37 !important;
  font-size: 1.25rem !important;
  margin-bottom: .5rem !important;
  letter-spacing: .02em !important;
}

/* 5. Lectura óptima para descripciones */
#juego-view-maquinas .sbc-text-block p {
  max-width: 58ch !important;
  font-size: 1rem !important;
  line-height: 1.5 !important;
  color: rgba(255,255,255,.88) !important;
}

/* 6. Listados estilo "chips" respirados */
#juego-view-maquinas .sbc-games-group p {
  font-size: .95rem !important;
  line-height: 1.75 !important;
  word-spacing: .15rem !important;
  color: rgba(255,255,255,.86) !important;
}

/* Adaptación responsive */
@media (min-width: 901px) {
  #juego-view-maquinas .sbc-module-text,
  #juego-view-maquinas .sbc-module-games-lists {
    grid-template-columns: 1fr 1fr !important;
  }
}
@media (max-width: 900px) {
  #juego-view-maquinas .sbc-module-text,
  #juego-view-maquinas .sbc-module-games-lists {
    grid-template-columns: 1fr !important;
  }
}
