.gallery {
  max-width: 100%;
  padding: 0;
  margin: 0;
}

.featured {
  width: 100%;
  aspect-ratio: 16/9;
  border-radius: 12px;
  overflow: hidden;
  background: #f0f0f0;
  border: 1px solid #e0e0e0;
  margin-bottom: 0.75rem;
}

.featured iframe {
  width: 100%;
  height: 100%;
  border: none;
  display: block;
}

.thumbs {
  display: flex;
  gap: 0.75rem;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  padding-bottom: 4px;
}

.thumbs::-webkit-scrollbar {
  display: none;
}

.thumb {
  flex: 0 0 calc(33.333% - 0.5rem);
  min-width: 160px;
  aspect-ratio: 16/9;
  border-radius: 8px;
  overflow: hidden;
  cursor: pointer;
  position: relative;
  background: #f0f0f0;
  border: 1px solid #e0e0e0;
  transition: border-color 0.15s;
}

@media (max-width: 480px) {
  .thumb {
    flex: 0 0 72%;
  }
}

.thumb:hover {
  border-color: #aaa;
}

/* wrapper che taglia le scrollbar di Drive */
.iframe-crop {
  position: absolute;
  inset: -5px;
  overflow: hidden;
  border-radius: 8px;
}

.iframe-crop iframe {
  width: calc(100% + 16px);
  height: calc(100% + 16px);
  margin: -8px 0 0 -8px;
  border: none;
  display: block;
  pointer-events: none;
}

.thumb-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s;
  z-index: 1;
}

.thumb:hover .thumb-overlay {
  background: rgba(0, 0, 0, 0.08);
}

.play-icon {
  width: 32px;
  height: 32px;
  background: rgba(255, 255, 255, 0.88);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.play-icon svg {
  width: 14px;
  height: 14px;
  fill: #111;
  margin-left: 2px;
}

@media (max-width: 768px) {
  .gallery {
    grid-column: 1;
    grid-row: auto;
  }
}