/* =====================================================
   Nitro Motors – Mini Video Ecommerce
   Archivo: mini-video-ecommerce.css
   Ruta:    /wp-content/themes/TU-TEMA-HIJO/css/mini-video-ecommerce.css
   ===================================================== */

/* ── TÍTULO ── */
.tituloNitroWooco h2 {
  font-size: 22px;
  font-weight: 700;
  line-height: 1.2;
  color: #111110;
  margin-bottom: 12px;
}
.tituloNitroWooco h2 span {
  color: #ffcd00;
}

/* ── MINIATURA DEL VIDEO ── */
.nitro-video-thumb {
  position: relative;
  width: 250px;
  height: 130px;
  border-radius: 12px;
  border: 5px solid #ffcd00;
  overflow: hidden;
  cursor: pointer;
  touch-action: manipulation; /* elimina delay 300ms en iOS */
  -webkit-tap-highlight-color: transparent;
}
.nitro-video-bg {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  pointer-events: none; /* toque pasa al div padre */
}
.nitro-video-overlay {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background: rgba(0,0,0,0.4);
  transition: background 0.3s ease;
  pointer-events: none; /* toque pasa al div padre */
}
.nitro-play-btn {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 52px; height: 52px;
  transition: transform 0.2s ease;
  pointer-events: none; /* toque pasa al div padre */
}
.nitro-video-thumb:hover .nitro-play-btn {
  transform: translate(-50%, -50%) scale(1.1);
}
.nitro-play-btn svg {
  width: 100%; height: 100%;
}

/* ── AVATARES ── */
.nitro-asesores-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 10px;
  flex-wrap: wrap;
}
.nitro-asesor-avatar {
  width: 48px; height: 48px;
  border-radius: 50%;
  border: 2px solid #ffcd00;
  overflow: hidden;
  flex-shrink: 0;
}
.nitro-asesor-avatar img {
  width: 100%; height: 100%;
  object-fit: cover;
  display: block;
}
.nitro-asesor-link {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px; height: 40px;
  background: #ffcd00;
  border-radius: 50%;
  text-decoration: none;
  font-size: 18px;
  color: #111110;
  font-weight: 700;
  flex-shrink: 0;
  transition: transform .2s;
}
.nitro-asesor-link:hover { transform: scale(1.1); }

/* ── POPUP OVERLAY ── */
.video2-popup-overlay {
  display: none;
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background-color: rgba(0,0,0,0);
  z-index: 99999;
  transition: background-color 0.35s ease;
  align-items: center;
  justify-content: center;
}
.video2-popup-overlay.active {
  display: flex;
  background-color: rgba(0,0,0,0.82);
}

/* ── POPUP CONTAINER ── */
.video2-popup-container {
  position: relative;
  width: auto;
  max-width: 92vw;
  max-height: 88vh;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(0,0,0,0.5);
  opacity: 0;
  transition: opacity 0.35s ease;
  background: #000;
  display: flex;
  align-items: center;
  justify-content: center;
}
.video2-popup-overlay.active .video2-popup-container {
  opacity: 1;
}

/* ── POPUP VIDEO ── */
.video2-popup-video {
  display: block;
  width: auto;
  height: auto;
  max-width: 92vw;
  max-height: 53vh;
  background: #000;
  object-fit: contain;
}

/* ── POPUP CLOSE ── */
.video2-popup-close {
  position: absolute;
  top: 12px; right: 12px;
  background: rgba(0,0,0,0.65);
  border: none;
  color: #fff;
  font-size: 18px;
  width: 36px; height: 36px;
  border-radius: 50%;
  cursor: pointer;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s ease;
}
.video2-popup-close:hover { background: #ffcd00; color: #111110; }

/* ── FIX iOS/MÓVIL: body fijo no rompe el overlay ── */
body.modal-abierto {
  overflow: hidden !important;
  width: 100% !important;
}

/* Flatsome #wrapper no debe ocultar el popup */
body.modal-abierto #wrapper {
  overflow: visible !important;
}

/* El overlay SIEMPRE fixed y encima de todo */
.video2-popup-overlay {
  display: none;
  position: fixed !important;
  top: 0 !important;
  left: 0 !important;
  width: 100% !important;
  height: 100% !important;
  background-color: rgba(0,0,0,0);
  z-index: 999999 !important;
  transition: background-color 0.35s ease;
  align-items: center;
  justify-content: center;
}
.video2-popup-overlay.active {
  display: flex !important;
  background-color: rgba(0,0,0,0.82);
}

/* Container centrado en la pantalla */
.video2-popup-container {
  position: relative !important;
  width: 92% !important;
  max-width: 860px;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(0,0,0,0.5);
  opacity: 0;
  transition: opacity 0.35s ease;
  background: #000;
  max-height: 90vh;
  margin: auto;
  top: auto !important;
  left: auto !important;
  transform: none !important;
}
.video2-popup-overlay.active .video2-popup-container {
  opacity: 1;
}


@media (max-width: 768px) {
    .video2-popup-container {
        width: 95vw !important;
        max-width: calc(100vw - 20px) !important;
        height: 22vh !important;
    }
}


/* ── OCULTAR DESCARGA EN CONTROLES ── */
video::-webkit-media-controls-enclosure { overflow: hidden; }
video::-webkit-media-controls-panel { width: calc(100% + 30px); }

/* ── THUMBNAILS VERTICALES ── */
.vertical-thumbnails .col {
  width: 80% !important;
}
