/* Reproductor de YouTube: portada propia y el video real solo al primer clic. */
.yt-facade {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  border-radius: 12px;
  background: #000;
  color: #fff;
  text-decoration: none;
  isolation: isolate;
}

.yt-facade img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 420ms cubic-bezier(0.22, 1, 0.36, 1), filter 420ms cubic-bezier(0.22, 1, 0.36, 1);
}

.yt-facade::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(180deg, rgba(0, 0, 0, 0) 45%, rgba(0, 0, 0, 0.82) 100%);
}

.yt-facade__play {
  position: absolute;
  top: 50%;
  left: 50%;
  z-index: 2;
  display: grid;
  place-items: center;
  width: clamp(64px, 11vw, 96px);
  aspect-ratio: 1;
  border-radius: 50%;
  background: #FF5B01;
  box-shadow: 0 0 0 0 rgba(255, 91, 1, 0.55), 0 12px 32px rgba(0, 0, 0, 0.45);
  transform: translate(-50%, -50%);
  transition: transform 260ms cubic-bezier(0.34, 1.56, 0.64, 1), background 180ms;
  animation: yt-facade-pulso 2.6s ease-out 3;
}

.yt-facade__play::before {
  content: "";
  width: 34%;
  aspect-ratio: 1 / 1.15;
  margin-left: 7%;
  background: #fff;
  clip-path: polygon(0 0, 100% 50%, 0 100%);
}

.yt-facade__pie {
  position: absolute;
  right: 16px;
  bottom: 14px;
  left: 16px;
  z-index: 2;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  font-family: 'Manrope', system-ui, sans-serif;
  font-weight: 700;
  line-height: 1.25;
}

.yt-facade__titulo {
  overflow: hidden;
  font-size: clamp(0.875rem, 1.6vw, 1.125rem);
  text-overflow: ellipsis;
  white-space: nowrap;
}

.yt-facade__cta {
  flex: none;
  font-family: 'Space Grotesk', monospace;
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.yt-facade:hover img,
.yt-facade:focus-visible img {
  transform: scale(1.04);
  filter: brightness(1.08);
}

.yt-facade:hover .yt-facade__play,
.yt-facade:focus-visible .yt-facade__play {
  background: #FF7A33;
  transform: translate(-50%, -50%) scale(1.1);
}

.yt-facade:focus-visible {
  outline: 3px solid #FF7A33;
  outline-offset: 3px;
}

.yt-facade__video {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  border: 0;
  border-radius: 12px;
  background: #000;
}

@keyframes yt-facade-pulso {
  70% { box-shadow: 0 0 0 26px rgba(255, 91, 1, 0), 0 12px 32px rgba(0, 0, 0, 0.45); }
  100% { box-shadow: 0 0 0 0 rgba(255, 91, 1, 0), 0 12px 32px rgba(0, 0, 0, 0.45); }
}

@media (max-width: 480px) {
  .yt-facade__cta { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  .yt-facade img,
  .yt-facade__play {
    animation: none;
    transition: none;
  }
}
