/* =========================================================
   CSS — Carrusel de videos (3 desktop / 2 tablet / 1 móvil)
   ========================================================= */
.video-carousel {
  position: relative;
  width: 95%;
  max-width: 1480px;
  margin: 2% auto 0;
  --vc-color: #e4002b;   /* flechas y punto activo */
  --vc-gap: 12px;        /* espacio entre videos */
  --vc-per-view: 1;      /* videos visibles */
}

.video-carousel .vc-viewport {
  display: flex;
  flex-wrap: nowrap;
  gap: var(--vc-gap);
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x mandatory;
  overscroll-behavior-x: contain;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  -ms-overflow-style: none;
}
.video-carousel .vc-viewport::-webkit-scrollbar { display: none; }

/* Slide: el ancho depende de --vc-per-view */
.video-carousel .vc-slide {
  flex: 0 0 calc((100% - var(--vc-gap) * (var(--vc-per-view) - 1)) / var(--vc-per-view));
  min-width: 0;
  scroll-snap-align: start;
}

/* Contenedor 16:9 del video */
.video-carousel .vc-video {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #000;
  border: 1px solid #dddbde;
  border-radius: 5px;
  overflow: hidden;
  box-sizing: border-box;
}

/* Portada (miniatura + botón play). El iframe se carga solo al hacer clic */
.video-carousel .vc-poster {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  padding: 0;
  border: 0;
  background: #000 center / cover no-repeat;
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
}
.video-carousel .vc-play {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 68px;
  height: 48px;
  transform: translate(-50%, -50%);
  background: rgba(228, 0, 43, 0.92);
  border-radius: 12px;
  transition: transform 0.2s, background 0.2s;
}
.video-carousel .vc-play::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-35%, -50%);
  border-style: solid;
  border-width: 9px 0 9px 16px;
  border-color: transparent transparent transparent #fff;
}
.video-carousel .vc-poster:hover .vc-play { transform: translate(-50%, -50%) scale(1.08); }

.video-carousel .vc-video iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

/* Título opcional debajo del video */
.video-carousel .vc-title {
  margin: 8px 2px 0;
  font: 600 14px/1.3 Arial, sans-serif;
  color: #222;
}

/* Flechas */
.video-carousel .vc-arrow {
  position: absolute;
  top: 0;
  bottom: 30px;                 /* alto de la zona de puntos */
  margin: auto 0;
  width: 40px;
  height: 40px;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: 0;
  border-radius: 50%;
  -webkit-appearance: none;
  appearance: none;
  background: rgba(255, 255, 255, 0.92);
  color: var(--vc-color);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
  cursor: pointer;
  transition: background 0.2s;
}
.video-carousel .vc-prev { left: 10px; }
.video-carousel .vc-next { right: 10px; }
.video-carousel .vc-arrow:hover { background: #fff; }

/* Puntos */
.video-carousel .vc-dots {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 30px;
}
.video-carousel .vc-dot {
  width: 10px;
  height: 10px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  -webkit-appearance: none;
  appearance: none;
  background: #b5b5b5;
  cursor: pointer;
  transition: width 0.25s, background 0.25s;
}
.video-carousel .vc-dot.is-active {
  width: 26px;
  border-radius: 5px;
  background: var(--vc-color);
}

/* ===== Breakpoints =====
   0 - 450px      → 1 video
   451 - 1023px   → 2 videos (tablet)
   1024px en más  → 3 videos (desktop)
   Si cambias estos valores, cambia también perView() en el JS. */
@media (min-width: 451px)  { .video-carousel { --vc-per-view: 2; --vc-gap: 14px; } }
@media (min-width: 1024px) { .video-carousel { --vc-per-view: 3; --vc-gap: 16px; } }

@media (max-width: 450px) {
  .video-carousel .vc-arrow { width: 32px; height: 32px; }
  .video-carousel .vc-prev { left: 6px; }
  .video-carousel .vc-next { right: 6px; }
}