/* PATCH 012 - SOLO INICIO: reparar "Lo que viene" */

#screen-home .home-events-panel{
  display:block;
  height:auto;
  min-height:0;
  padding:12px;
  border-radius:18px;
  overflow:hidden;
}

#screen-home .home-events-panel .home-panel-head{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
  margin:0 0 10px;
}

#screen-home .home-events-panel .home-panel-head h2{
  margin:2px 0 0;
  font-size:1.12rem;
  line-height:1.1;
}

#screen-home .home-events-panel .home-panel-head small{
  font-size:.62rem;
  letter-spacing:.13em;
}

#screen-home .home-events-panel .home-panel-head button{
  min-height:32px;
  padding:0 10px;
  border-radius:11px;
  font-size:.68rem;
  white-space:nowrap;
}

/* Lista limpia: nada montado, nada flotante */
#screen-home #homeUpcoming.home-upcoming-list{
  width:100%;
  display:grid;
  grid-template-columns:1fr;
  gap:9px;
  overflow:visible;
  padding:0;
  margin:0;
}

/* Tarjeta de evento compacta y estable */
#screen-home #homeUpcoming .home-event-card{
  width:100%;
  min-width:0;
  max-width:100%;
  min-height:0;
  display:grid;
  grid-template-columns:74px minmax(0,1fr);
  gap:9px;
  align-items:start;
  padding:8px;
  border-radius:15px;
  overflow:hidden;
  position:relative;
}

#screen-home #homeUpcoming .home-event-media{
  width:74px;
  height:74px;
  border-radius:12px;
  overflow:hidden;
}

#screen-home #homeUpcoming .home-event-media img{
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
}

#screen-home #homeUpcoming .home-event-copy{
  min-width:0;
  display:block;
}

#screen-home #homeUpcoming .home-event-copy h3{
  margin:1px 0 4px;
  font-size:.86rem;
  line-height:1.12;
  display:-webkit-box;
  -webkit-line-clamp:2;
  -webkit-box-orient:vertical;
  overflow:hidden;
}

#screen-home #homeUpcoming .home-event-line{
  margin:0 0 2px;
  font-size:.68rem;
  line-height:1.25;
  white-space:normal;
  overflow-wrap:anywhere;
}

#screen-home #homeUpcoming .event-status{
  margin-top:4px;
  font-size:.58rem;
}

/* Botones dentro de la tarjeta: debajo, no montados */
#screen-home #homeUpcoming .event-card-actions{
  width:100%;
  margin-top:7px;
  display:flex;
  flex-wrap:wrap;
  gap:6px;
}

#screen-home #homeUpcoming .event-card-actions button,
#screen-home #homeUpcoming .event-card-actions .primary{
  min-height:29px;
  padding:0 9px;
  border-radius:10px;
  font-size:.62rem;
  line-height:1;
  white-space:nowrap;
}

/* Desktop/tablet: 3 columnas normales */
@media(min-width:760px){
  #screen-home #homeUpcoming.home-upcoming-list{
    grid-template-columns:repeat(3,minmax(0,1fr));
  }

  #screen-home #homeUpcoming .home-event-card{
    grid-template-columns:82px minmax(0,1fr);
  }

  #screen-home #homeUpcoming .home-event-media{
    width:82px;
    height:82px;
  }
}

/* Móvil muy pequeño */
@media(max-width:370px){
  #screen-home #homeUpcoming .home-event-card{
    grid-template-columns:64px minmax(0,1fr);
    gap:7px;
  }

  #screen-home #homeUpcoming .home-event-media{
    width:64px;
    height:64px;
  }

  #screen-home #homeUpcoming .home-event-copy h3{
    font-size:.78rem;
  }

  #screen-home #homeUpcoming .home-event-line{
    font-size:.62rem;
  }
}
