/**
 * NextGo Swiper Engine
 * Scope: only elements with .nextgo-swiper
 * Does not style global .swiper / .swiper-slide / .swiper-wrapper classes.
 */

.nextgo-swiper {
  --nextgo-swiper-cols: 1;
  --nextgo-swiper-gap: 20px;
  --nextgo-arrow-size: 42px;
  --nextgo-arrow-offset: -18px;
  position: relative;
  width: 100%;
}

.nextgo-swiper-viewport {
  width: 100%;
  overflow: hidden;
}

.nextgo-swiper-track {
  min-width: 0;
}

/* Static grid mode: used on desktop/tablet when .nextgo-mode-mobile is active. */
.nextgo-swiper:not(.nextgo-is-swiper) .nextgo-swiper-track {
  display: grid !important;
  grid-template-columns: repeat(var(--nextgo-swiper-cols), minmax(0, 1fr));
  gap: var(--nextgo-swiper-gap) !important;
  transform: none !important;
}

.nextgo-swiper:not(.nextgo-is-swiper) .nextgo-swiper-item {
  min-width: 0;
  width: auto !important;
  margin-right: 0 !important;
}

/* Active Swiper mode. */
.nextgo-swiper.nextgo-is-swiper .nextgo-swiper-track {
  display: flex !important;
  gap: 0 !important;
}

.nextgo-swiper.nextgo-is-swiper .nextgo-swiper-item {
  flex-shrink: 0;
  height: auto;
  min-width: 0;
}

/* Hide auto controls while block is in static grid mode. */
.nextgo-swiper:not(.nextgo-is-swiper) .nextgo-swiper-pagination,
.nextgo-swiper:not(.nextgo-is-swiper) .nextgo-swiper-button {
  display: none !important;
}

/* Shared line pagination. */
.nextgo-swiper-pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  width: 100%;
  margin-top: 18px;
}

.nextgo-swiper-bullet {
  display: inline-block;
  width: 30px;
  height: 4px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: currentColor;
  opacity: 0.22;
  cursor: pointer;
  transition: opacity 0.2s ease, width 0.2s ease;
}

.nextgo-swiper-bullet-active {
  width: 38px;
  opacity: 1;
}

/* Shared arrows. */
.nextgo-swiper-button {
  position: absolute;
  top: 50%;
  z-index: 5;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: var(--nextgo-arrow-size);
  height: var(--nextgo-arrow-size);
  padding: 0;
  border: 1px solid rgba(0, 0, 0, 0.08);
  border-radius: 999px;
  background: #fff;
  color: #000;
  box-shadow: 0 10px 28px rgba(15, 23, 42, 0.12);
  cursor: pointer;
  transform: translateY(-50%);
  transition: color 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease, opacity 0.2s ease;
}

.nextgo-swiper-button:hover,
.nextgo-swiper-button:focus-visible {
  color: var(--theme-palette-color-1);
  border-color: var(--theme-palette-color-1);
  box-shadow: 0 12px 34px rgba(15, 23, 42, 0.16);
}

.nextgo-swiper-button:disabled,
.nextgo-swiper-button.nextgo-swiper-button-disabled {
  opacity: 0.35;
  cursor: default;
  pointer-events: none;
}

.nextgo-swiper-button svg {
  display: block;
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.nextgo-swiper-button-prev {
  left: var(--nextgo-arrow-offset);
}

.nextgo-swiper-button-next {
  right: var(--nextgo-arrow-offset);
}

.nextgo-arrows-inside {
  --nextgo-arrow-offset: 12px;
}

.nextgo-arrows-outside {
  --nextgo-arrow-offset: -18px;
}

/* WooCommerce shortcode wrapper: keep product card styling controlled by Blocksy/WooCommerce. */
.nextgo-woo-carousel {
  position: relative;
  width: 100%;
  max-width: 100%;
}

.nextgo-woo-carousel .nextgo-swiper-viewport {
  width: 100%;
  max-width: 100%;
  overflow: hidden;
}

.nextgo-woo-carousel .nextgo-swiper-track {
  display: flex;
  align-items: stretch;
}

.nextgo-woo-carousel .nextgo-swiper-item {
  min-width: 0;
  max-width: none;
  flex-shrink: 0;
  box-sizing: border-box;
}

.nextgo-woo-carousel__slide {
  height: auto;
}

.nextgo-woo-carousel__products {
  display: block !important;
  width: 100% !important;
  max-width: 100% !important;
  margin: 0 !important;
  padding: 0 !important;
  list-style: none !important;
}

.nextgo-woo-carousel__products > li.product {
  display: block;
  float: none !important;
  clear: none !important;
  width: 100% !important;
  max-width: 100% !important;
  min-width: 0 !important;
  margin: 0 !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
  list-style: none !important;
  box-sizing: border-box;
}

.nextgo-woo-carousel__products > li.product > * {
  max-width: 100%;
  box-sizing: border-box;
}

.nextgo-woo-carousel__products img {
  max-width: 100%;
  height: auto;
}
