/* Controles compartidos del visor: perfil, vista previa y moderación. */
.gallery-dialog .gallery-video-controls {
  position: absolute;
  bottom: 1rem;
  left: 1rem;
  right: 1rem;
  display: flex;
  gap: .5rem;
  align-items: center;
  z-index: 2;
}
.gallery-dialog .gallery-video-controls[hidden] { display: none; }
.gallery-dialog .gallery-video-controls input { flex: 1; min-width: 0; }
.gallery-dialog .gallery-video-controls button { position: static; min-width: 44px; min-height: 44px; flex: 0 0 44px; }

/* The existing card/cover owns geometry. The movie overlays its poster without reflow. */
.animated-cover { display:block; position:relative; overflow:hidden; width:100%; }
.profile-card > .animated-cover--card { position:absolute; inset:0; height:100%; }
.profile-card > .animated-cover--card::after { content:""; position:absolute; inset:0; background:linear-gradient(to top,rgba(0,0,0,.88) 0%,rgba(0,0,0,.58) 16%,rgba(0,0,0,.12) 38%,transparent 54%); }
.animated-cover--profile { min-height:0; }
.animated-cover > img { display:block; width:100%; height:100%; object-fit:cover; }
.animated-cover > video { position:absolute; inset:0; width:100%; height:100%; object-fit:cover; opacity:0; pointer-events:none; }
.animated-cover.is-playing > video { opacity:1; }
@media (prefers-reduced-motion:reduce) { .animated-cover.is-playing > video { opacity:0; } }
.profile-video { position:relative; }
html body main#contenido .profile-public--showcase .profile-gallery--public :is(.profile-gallery-item,.profile-video) { aspect-ratio:180 / 280; }
.profile-video > .profile-video__poster { position:absolute; z-index:1; inset:0; width:100%; height:100%; object-fit:cover; pointer-events:none; }
.profile-video > .profile-video__media { position:absolute; z-index:2; inset:0; width:100%; height:100%; opacity:0; }
.profile-video.is-playing > .profile-video__media { opacity:1; }
.video-stage { isolation:isolate; }
.video-stage > .video-stage__poster { position:absolute; z-index:1; inset:0; width:100%; height:100%; object-fit:cover; pointer-events:none; transform:rotate(var(--rotation,0deg)); }
.video-stage > video[data-preview-src] { position:absolute; z-index:2; inset:0; width:100%; height:100%; object-fit:cover; opacity:0; }
.video-stage.is-playing > video[data-preview-src] { opacity:1; }
body.definitive-shell .media-tile .tile-preview .video-stage > video[data-preview-src] { opacity:0; object-fit:cover; }
body.definitive-shell .media-tile .tile-preview .video-stage.is-playing > video[data-preview-src] { opacity:1; }
body.definitive-shell .media-tile .tile-preview .video-stage > .video-stage__poster { object-fit:cover; }
.gallery-dialog .grado-video-poster { position:absolute; z-index:1; pointer-events:none; background:transparent; }
.gallery-dialog .grado-video-poster[hidden] { display:none; }
@media (prefers-reduced-motion:reduce) {
  .profile-video.is-playing > .profile-video__media,
  .video-stage.is-playing > video[data-preview-src] { opacity:0; }
}
