/**
 * Video Carousel widget — uses tokens from variables.css (cnvp-variables).
 */
.video-carousel-section {
  font-family: var(--cnvp-font-sans);
  overflow: hidden;
}

.video-carousel-inner {
  max-width: var(--cnvp-container-max-width);
  margin: 0 auto;
  padding: 0 20px;
  box-sizing: border-box;
}

.video-carousel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
  margin-bottom: 40px;
}

.video-carousel-section-title {
  color: var(--cnvp-color-navy);
  margin: 0;
  font-weight: 600;
  line-height: 1.15;
  font-size: 2rem;
}

.video-carousel-see-more {
  background: var(--cnvp-color-cta);
  color: var(--cnvp-color-navy);
  padding: 10px 20px;
  border-radius: 4px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  text-decoration: none;
  flex-shrink: 0;
  transition: opacity 0.2s ease, background-color 0.2s ease;
}

.video-carousel-see-more:hover {
  opacity: 0.92;
  color: white;
  background: var(--cnvp-color-accent);
}

.video-carousel-see-more svg {
  width: 20px;
  height: 20px;
}

.video-carousel-see-more:hover svg path {
  fill: white;
}

.video-carousel-body {
  width: 100%;
  display: flex;
  flex-direction: column;
}

.video-carousel-slider-wrap {
  position: relative;
  width: 100%;
}

.video-carousel-swiper {
  width: 100%;
  overflow: hidden;
}

.video-carousel-swiper .swiper-wrapper {
  display: flex;
}

.video-carousel-card {
  background: var(--cnvp-color-white);
  border-radius: 8px;
  overflow: hidden;
  height: 100%;
  box-shadow: var(--cnvp-shadow-search);
  border: 1px solid var(--cnvp-color-border);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.video-carousel-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--cnvp-shadow-header);
}

.video-carousel-media {
  position: relative;
}

.video-carousel-play {
  display: block;
  text-decoration: none;
  color: inherit;
  cursor: pointer;
  position: relative;
  z-index: 2;
}

.video-carousel-cover {
  position: relative;
  height: 220px;
  background-size: cover;
  background-position: center;
  background-color: var(--cnvp-color-navy);
}

.video-carousel-cover--empty {
  background-image: linear-gradient(
    135deg,
    var(--cnvp-color-navy) 0%,
    var(--cnvp-color-accent-deep) 100%
  );
}

.video-carousel-cover::before {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(2, 3, 7, 0.25);
  transition: background 0.3s ease;
}

.video-carousel-play:hover .video-carousel-cover::before {
  background: rgba(2, 3, 7, 0.4);
}

.video-carousel-play-btn {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: var(--cnvp-color-accent);
  color: var(--cnvp-color-white);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.25);
  transition: background-color 0.2s ease, transform 0.2s ease;
  z-index: 1;
}

.video-carousel-play-btn svg {
  width: 28px;
  height: 28px;
  margin-left: 4px;
}

.video-carousel-play:hover .video-carousel-play-btn {
  background: var(--cnvp-color-accent-deep);
  transform: translate(-50%, -50%) scale(1.05);
}

.video-carousel-content {
  padding: 20px;
}

.video-carousel-title {
  font-size: 20px;
  line-height: 1.4;
  margin: 0 0 10px;
  font-weight: 600;
  color: var(--cnvp-color-navy);
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  overflow: hidden;
}

.video-carousel-description {
  margin: 0;
  font-size: 15px;
  line-height: 1.5;
  color: var(--cnvp-color-muted);
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  line-clamp: 3;
  overflow: hidden;
}

.video-carousel-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 28px;
}

.video-carousel-navigation {
  position: absolute;
  inset: 0;
  z-index: 4;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 4px;
  pointer-events: none;
}

.video-carousel-arrow {
  width: 50px !important;
  height: 50px !important;
  background-color: var(--cnvp-color-accent) !important;
  border: none;
  border-radius: 50%;
  position: static !important;
  top: auto !important;
  left: auto !important;
  right: auto !important;
  margin: 0 !important;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  color: var(--cnvp-color-white);
  pointer-events: auto;
  opacity: 0;
  visibility: hidden;
  transform: translateY(0);
  transition:
    background-color 0.2s ease,
    opacity 0.25s ease,
    visibility 0.25s ease,
    transform 0.25s ease;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
}

.video-carousel-slider-wrap:hover .video-carousel-arrow,
.video-carousel-slider-wrap:focus-within .video-carousel-arrow {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.video-carousel-arrow:hover {
  background-color: var(--cnvp-color-accent-deep);
}

.video-carousel-arrow::after {
  display: none;
}

.video-carousel-arrow.swiper-button-disabled {
  opacity: 0.5 !important;
  cursor: not-allowed;
}

.video-carousel-arrow svg {
  width: 24px;
  height: 24px;
}

.video-carousel-body .video-carousel-dots {
  position: static !important;
  width: auto !important;
  display: flex;
  align-items: center;
  justify-content: center;
}

.video-carousel-body .video-carousel-dots .swiper-pagination-bullet {
  background: var(--cnvp-color-border);
  opacity: 1;
  width: 12px;
  height: 12px;
  margin: 0 5px !important;
  transition: all 0.3s;
}

.video-carousel-body .video-carousel-dots .swiper-pagination-bullet-active {
  background: var(--cnvp-color-accent) !important;
  width: 50px !important;
  height: 15px !important;
  border-radius: 30px !important;
}

.video-carousel-section--empty {
  padding: 24px;
  text-align: center;
  color: var(--cnvp-color-muted);
  border: 1px dashed var(--cnvp-color-border);
  border-radius: 8px;
}

.video-carousel-navigation svg path {
  stroke: white;
}

@media (max-width: 992px) {
  .video-carousel-section-title {
    font-size: 30px;
  }

  .video-carousel-header {
    flex-direction: row;
    align-items: center;
  }

  .video-carousel-see-more {
    font-size: 14px;
    padding: 8px 20px !important;
  }

  .video-carousel-see-more svg {
    width: 15px;
    height: 15px;
  }

  .video-carousel-swiper {
    overflow: visible !important;
  }

  .video-carousel-cover {
    height: 200px;
  }

  .video-carousel-navigation {
    padding: 0;
  }

  .video-carousel-navigation svg path {
    stroke: white;
  }

  .video-carousel-arrow {
    width: 42px !important;
    height: 42px !important;
  }
}
