/**
 * @file
 * Views Vanilla JavaScript Basic Carousel.
 *
 * Filename:     vvjb.css
 * Website:      https://www.flashwebcenter.com
 * Developer:    Alaa Haddad https://www.alaahaddad.com.
 */

/* Base Carousel Styles */
.vvjb-carousel .visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
  white-space: nowrap;
}

.vvjb-carousel,
.vvjb-carousel * {
  box-sizing: border-box;
}

.vvjb .vvjb-carousel-outer {
  position: relative;
  display: block;
  width: 100%;
  height: 100%;
}

.vvjb.vvjb-orientation-vertical .vvjb-carousel-outer {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
}

.vvjb.vvjb-nav-dots .vvjb-carousel-outer,
.vvjb.vvjb-nav-none .vvjb-carousel-outer {
  padding: 0;
}

.vvjb .vvjb-carousel-wrapper {
  position: relative;
  overflow: hidden;
  width: auto;
  height: auto;
  margin: 0 auto;
  opacity: 0;
  visibility: hidden;
  transition: all 0.4s ease;
}

.vvjb .vvjb-carousel-wrapper.is-visible {
  opacity: 1;
  visibility: visible;
}

.vvjb .vvjb-items {
  display: flex;
  will-change: transform;
  transition: transform 0.5s ease-in-out;
  transform: translateX(0);
}

.vvjb .vvjb-item {
  flex: 0 0 auto;
  transition: transform 0.5s ease, opacity 0.5s ease;
  scroll-snap-align: start;
}

.vvjb .vvjb-item.active-slide {
  opacity: 1;
  pointer-events: auto;
}

.vvjb .vvjb-item.non-active-slide {
  opacity: 0.15;
  pointer-events: none;
}

/* Horizontal and Hybrid Layout */
.vvjb.vvjb-orientation-hybrid .vvjb-items,
.vvjb.vvjb-orientation-horizontal .vvjb-items {
  flex-direction: row;
}

.vvjb.vvjb-orientation-hybrid.vvjb-nav-arrows .vvjb-carousel-outer,
.vvjb.vvjb-orientation-hybrid.vvjb-nav-both .vvjb-carousel-outer,
.vvjb.vvjb-orientation-horizontal.vvjb-nav-arrows .vvjb-carousel-outer,
.vvjb.vvjb-orientation-horizontal.vvjb-nav-both .vvjb-carousel-outer {
  padding: 0 50px;
}

.vvjb.vvjb-orientation-hybrid .vvjb-carousel-options,
.vvjb.vvjb-orientation-horizontal .vvjb-carousel-options {
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  transform: translateY(-50%);
  display: flex;
  justify-content: space-between;
  align-items: center;
  pointer-events: none;
  padding: 0;
  margin: 0;
  z-index: 1;
}

.vvjb.vvjb-orientation-hybrid .vvjb-carousel-options .vvjb-button,
.vvjb.vvjb-orientation-horizontal .vvjb-carousel-options .vvjb-button {
  pointer-events: all;
}

/* Vertical Layout */
.vvjb.vvjb-orientation-vertical .vvjb-items {
  flex-direction: column;
  transform: translateY(0);
}

.vvjb.vvjb-orientation-vertical.vvjb-nav-arrows .vvjb-carousel-outer,
.vvjb.vvjb-orientation-vertical.vvjb-nav-both .vvjb-carousel-outer {
  padding: 50px 0;
}

.vvjb.vvjb-orientation-vertical .vvjb-item {
  width: 100%;
}

.vvjb.vvjb-orientation-vertical .vvjb-carousel-options {
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 0;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: center;
  pointer-events: none;
  padding: 0;
  margin: 0;
  z-index: 1;
}

.vvjb.vvjb-orientation-vertical .vvjb-carousel-options .vvjb-button {
  pointer-events: all;
}

.vvjb.vvjb-orientation-vertical button svg {
  transform: rotate(-90deg);
}

/* Carousel Arrow Button Styles */
.vvjb .vvjb-carousel-options .vvjb-button {
  width: 48px;
  height: 48px;
  background: transparent;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  padding: 0;
  margin: 0;
  transition: all 0.3s ease;
}

.vvjb .vvjb-carousel-options .vvjb-button svg {
  width: 32px;
  height: 32px;
}

.vvjb .vvjb-carousel-options .vvjb-button[style*='visibility:hidden'] {
  opacity: 0;
  pointer-events: none;
}

/* Carousel Dots Navigation Styles */
.vvjb .vvjb-carousel-dots {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 12px;
  margin-top: 1rem;
  padding: 0;
  flex-wrap: wrap;
  width: 100%;
}

.vvjb .vvjb-carousel-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  border: 2px solid currentColor;
  background-color: transparent;
  cursor: pointer;
  padding: 0;
  margin: 0;
  opacity: 0.5;
  transition: all 0.3s ease;
}

/* Active dot state - matches JavaScript class name */
.vvjb .vvjb-carousel-dot.active-slide {
  background-color: currentColor;
  opacity: 1;
  transform: scale(1.2);
}

/* Hover and focus states */
.vvjb .vvjb-carousel-dot:hover {
  opacity: 0.8;
  transform: scale(1.1);
}

.vvjb .vvjb-carousel-dot:focus-visible {
  opacity: 1;
  outline: 2px solid currentColor;
  outline-offset: 4px;
}

/* Pressed/active interaction state */
.vvjb .vvjb-carousel-dot:active {
  transform: scale(0.9);
}

/* Alternative square dot style */
.square-dots .vvjb .vvjb-carousel-dots .vvjb-carousel-dot {
  border-radius: 2px;
  width: 10px;
  height: 10px;
}

/* Alternative bar/line indicator style */
.bar-dots .vvjb .vvjb-carousel-dots .vvjb-carousel-dot {
  border-radius: 2px;
  width: 24px;
  height: 4px;
}

.bar-dots .vvjb .vvjb-carousel-dots .vvjb-carousel-dot.active-slide {
  transform: scaleX(1.5);
}

/* Accessibility and Motion Support */
.vvjb .reduced-motion .vvjb-item {
  transition: none !important;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
  .vvjb .vvjb-carousel-dot {
    border-width: 3px;
    opacity: 0.7;
  }

  .vvjb .vvjb-carousel-dot.active-slide {
    opacity: 1;
    background-color: currentColor;
  }
}

/* Reduced motion support */
@media (prefers-reduced-motion: reduce) {
  .vvjb .vvjb-carousel-dot {
    transition: opacity 0.2s ease;
    transform: none;
  }

  .vvjb .vvjb-carousel-dot.active-slide {
    transform: none;
  }

  .vvjb .vvjb-carousel-dot:hover,
  .vvjb .vvjb-carousel-dot:active {
    transform: none;
  }
}

/* Optional: Hide scrollbars */
.vvjb .vvjb-carousel-wrapper::-webkit-scrollbar {
  display: none;
}
