
/* ==========================================================
   TUBODY — VIDEO CENTRAL + CUATRO FOTOS V4
   ========================================================== */

.selected-layout{
  display:grid !important;
  grid-template-columns:
    minmax(145px,.34fr)
    minmax(0,1.55fr)
    minmax(145px,.34fr) !important;
  grid-template-rows:repeat(2,minmax(0,1fr));
  gap:2px !important;
  align-items:stretch;
  overflow:hidden;
  background:#fff !important;
}

.selected-main{
  grid-column:2;
  grid-row:1 / 3;
  position:relative;
  width:100%;
  min-width:0;
  min-height:0 !important;
  height:auto !important;
  aspect-ratio:16 / 9 !important;
  overflow:hidden;
  align-self:center;
  background:#071c1a !important;
}

.selected-main video{
  position:absolute;
  inset:0;
  width:100% !important;
  height:100% !important;
  min-height:0 !important;
  display:block;
  object-fit:cover;
  background:#071c1a;
}

.selected-main-placeholder{
  position:absolute !important;
  inset:0 !important;
  width:100%;
  height:100%;
}

/*
  Los cuatro elementos dentro de selectedPhotos participan directamente
  en la cuadrícula principal. Así quedan dos a la izquierda y dos a la derecha.
*/
.selected-photos{
  display:contents !important;
}

.selected-photo{
  width:100%;
  height:100%;
  min-height:0 !important;
  aspect-ratio:auto !important;
}

.selected-photo:nth-child(1){
  grid-column:1;
  grid-row:1;
}

.selected-photo:nth-child(2){
  grid-column:1;
  grid-row:2;
}

.selected-photo:nth-child(3){
  grid-column:3;
  grid-row:1;
}

.selected-photo:nth-child(4){
  grid-column:3;
  grid-row:2;
}

.selected-photo:nth-child(n+5){
  display:none !important;
}

.selected-photo img{
  width:100%;
  height:100%;
  object-fit:cover;
}

/* Elimina cualquier franja sobrante bajo el reproductor. */
.selected-layout::after,
.selected-main::after{
  display:none !important;
  content:none !important;
}

.selected-session-actions{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:22px;
  padding:13px 0 0;
}

.selected-session-actions button{
  min-height:42px;
  padding:0 17px;
  border:1px solid var(--accent);
  background:var(--accent);
  color:#fff;
  font-size:.54rem;
  font-weight:700;
  letter-spacing:.11em;
  text-transform:uppercase;
}

.selected-session-actions button span{
  color:rgba(255,255,255,.72);
}

.selected-session-actions p{
  max-width:570px;
  margin:0;
  color:var(--muted);
  font-size:.63rem;
  line-height:1.45;
  text-align:right;
}

/* ==========================================================
   MODAL DE SESIÓN COMPLETA
   ========================================================== */

.session-gallery-modal{
  position:fixed;
  inset:0;
  z-index:99998;
  display:grid;
  place-items:center;
  padding:22px;
  background:rgba(3,16,14,.94);
}

.session-gallery-dialog{
  position:relative;
  width:min(1240px,100%);
  max-height:94vh;
  overflow:auto;
  border:1px solid rgba(255,255,255,.12);
  background:#061916;
  color:#fff;
}

.session-gallery-close{
  position:absolute;
  top:0;
  right:0;
  z-index:5;
  width:48px;
  height:48px;
  border:0;
  background:var(--accent);
  color:#fff;
  font-size:1.55rem;
}

.session-gallery-head{
  min-height:92px;
  display:flex;
  align-items:flex-end;
  justify-content:space-between;
  gap:28px;
  padding:20px 68px 18px 20px;
  border-bottom:1px solid rgba(255,255,255,.10);
}

.session-gallery-head h2{
  margin:5px 0 0;
  font-size:clamp(1.7rem,4vw,3rem);
  line-height:1;
  letter-spacing:-.045em;
  font-weight:260;
}

.session-gallery-head p{
  max-width:480px;
  margin:0;
  color:rgba(255,255,255,.48);
  font-size:.66rem;
  line-height:1.45;
  text-align:right;
}

.session-gallery-body{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:2px;
  padding:2px;
  background:rgba(255,255,255,.10);
}

.session-gallery-item{
  position:relative;
  min-width:0;
  overflow:hidden;
  background:#092521;
}

.session-gallery-item.is-video{
  grid-column:1 / -1;
  aspect-ratio:16 / 9;
}

.session-gallery-item.is-photo{
  aspect-ratio:4 / 5;
  cursor:pointer;
}

.session-gallery-item video,
.session-gallery-item img{
  width:100%;
  height:100%;
  display:block;
  object-fit:cover;
}

.session-gallery-item.is-video video{
  object-fit:contain;
  background:#020b0a;
}

.session-gallery-item-copy{
  position:absolute;
  right:0;
  bottom:0;
  left:0;
  z-index:2;
  padding:28px 12px 11px;
  background:linear-gradient(to top,rgba(2,15,13,.88),transparent);
}

.session-gallery-item-copy strong,
.session-gallery-item-copy small{
  display:block;
}

.session-gallery-item-copy strong{
  font-size:.69rem;
  font-weight:610;
}

.session-gallery-item-copy small{
  margin-top:3px;
  color:rgba(255,255,255,.58);
  font-size:.48rem;
  letter-spacing:.08em;
  text-transform:uppercase;
}

.session-gallery-empty{
  grid-column:1 / -1;
  min-height:360px;
  display:grid;
  place-items:center;
  padding:30px;
  background:#071b19;
  color:rgba(255,255,255,.55);
  font-size:.73rem;
  text-align:center;
}

@media(max-width:920px){
  .selected-layout{
    grid-template-columns:minmax(110px,.34fr) minmax(0,1.45fr) minmax(110px,.34fr) !important;
  }

  .session-gallery-body{
    grid-template-columns:repeat(2,minmax(0,1fr));
  }
}

@media(max-width:700px){
  .selected-layout{
    grid-template-columns:1fr 1fr !important;
    grid-template-rows:auto auto auto !important;
  }

  .selected-main{
    grid-column:1 / -1;
    grid-row:1;
  }

  .selected-photo:nth-child(1){
    grid-column:1;
    grid-row:2;
  }

  .selected-photo:nth-child(2){
    grid-column:2;
    grid-row:2;
  }

  .selected-photo:nth-child(3){
    grid-column:1;
    grid-row:3;
  }

  .selected-photo:nth-child(4){
    grid-column:2;
    grid-row:3;
  }

  .selected-photo{
    aspect-ratio:4 / 5 !important;
  }

  .selected-session-actions{
    align-items:stretch;
    flex-direction:column;
  }

  .selected-session-actions button{
    width:100%;
  }

  .selected-session-actions p{
    max-width:none;
    text-align:left;
  }

  .session-gallery-head{
    display:block;
  }

  .session-gallery-head p{
    margin-top:10px;
    text-align:left;
  }
}

@media(max-width:500px){
  .session-gallery-modal{
    padding:0;
  }

  .session-gallery-dialog{
    width:100%;
    max-height:100vh;
    min-height:100vh;
    border:0;
  }

  .session-gallery-body{
    grid-template-columns:1fr;
  }

  .session-gallery-item.is-video{
    grid-column:auto;
  }
}
