/*Youtube CSS*/
.yt-playlist {
  width: 100%;
  max-width: 100%;
  margin: 1rem 0;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.yt-player-wrapper {
  position: relative;
  width: 100%;
  padding-top: 56.25%; /* 16:9 */
}

.yt-player {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

.yt-list {
  order: -1;
  display: flex;
  flex-wrap: nowrap;
  gap: 0.5rem;
  overflow-x: auto;
  overflow-y: hidden;
  padding: 0.2rem 0;
  -webkit-overflow-scrolling: touch;
  scroll-snap-type: x proximity;
  scrollbar-width: thin;
}

.yt-item {
  flex: 0 0 110px;
  width: 110px;
  min-width: 110px;
  max-width: 110px;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  cursor: pointer;
  scroll-snap-align: start;
  transition: transform 0.2s ease;
}

.yt-item:hover {
  transform: translateY(-2px);
}

.yt-item.active {
  outline: 2px solid #4f9d7b;
  outline-offset: 2px;
}

.yt-item img {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: 4px;
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.15);
}

.yt-item-title {
  display: block;
  width: 100%;
  min-width: 0;
  font-size: 0.75rem;
  line-height: 1.2;
  color: #1f1f1f;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Mobile */
@media (max-width: 768px) {
  .yt-item {
    flex: 0 0 90px;
    width: 90px;
    min-width: 90px;
    max-width: 90px;
  }
}