/* =========================
   Block base
   ========================= */
.cg-wrapper:not(.is-editor):not(.cg-ready) .cg-slide a,
.cg-wrapper:not(.is-editor):not(.cg-ready) .cg-slide img,
.cg-wrapper:not(.is-editor):not(.cg-ready) .cg-slide iframe {
  pointer-events: none;
}

.wp-block-carousel-gallery-wrapper,
.cg-wrapper {
  display: block;
  box-sizing: border-box;
  inline-size: 100%;
  max-inline-size: 100%;
  min-inline-size: 0;
}

.cg-wrapper .cg-track {
  inline-size: 100%;
  max-inline-size: 100%;
  min-inline-size: 0;
  box-sizing: border-box;
}

.cg-wrapper .cg-slide img,
.cg-wrapper .cg-slide video {
  max-width: 100%;
  height: auto;
  width: 100%;
}

.cg-wrapper .cg-slide img {
  border-radius: 15px;
  object-fit: cover; 
  cursor: zoom-in;
  /* Prevent browser-native image dragging globally */
  -webkit-user-drag: none;
  -khtml-user-drag: none;
  -moz-user-drag: none;
  -o-user-drag: none;
  user-drag: none;
}

.cg-wrapper .cg-slide img, 
.cg-wrapper .cg-slide video, 
.cg-slide iframe {
  width: 100%;
  aspect-ratio: 16 / 9;
  height: auto;
}

/* Slide embeds */
.cg-slide iframe {
  width: 100%;
  aspect-ratio: 16 / 9;
  border: 0;
  border-radius: 15px;
}

.cg-slide__placeholder {
  padding: 24px;
  border: 1px dashed #ccc;
  text-align: center;
}

.cg-wrapper .cg-slide video,
.cg-lightbox__stage video {
  width: 100%;
  max-width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  border-radius: 15px;
  display: block;
}

.cg-lightbox__stage video {
  width: 100%;
  max-height: 86vh;
}

@media (max-width: 1024px) {
  .cg-lightbox__stage video {
    width: 100%;
    max-height: 80vh;
  }
}


/* =========================
   CAROUSEL mode
   ========================= */

.cg-wrapper:not(.is-editor):not(.cg-ready) .cg-track > * {
  display: none;
}

.cg-wrapper:not(.is-editor):not(.cg-ready) .cg-track > *:first-child {
  display: block;
}

.cg-wrapper.is-carousel {
  position: relative;
  overflow-x: hidden;
  overflow-y: visible;
}

@supports (overflow: clip) {
  .cg-wrapper.is-carousel {
    overflow-x: clip;
    overflow-y: visible;
  }
}

.cg-wrapper.is-carousel .cg-track {
  display: flex;
  flex-direction: row;
  gap: 0; 
  inline-size: 100%;
  max-inline-size: 100%;
  box-sizing: border-box;
  overflow: visible;
  cursor: grab;
  padding-inline: 0;
  will-change: transform;
  touch-action: pan-y pinch-zoom;
}

.cg-wrapper.is-carousel .cg-track > * {
  --cg-overflow-guard: 0px;
  flex: 0 0 100%;
  scroll-snap-align: start;
  min-inline-size: 0;
  box-sizing: border-box;
}

.cg-wrapper.is-carousel .cg-slide {
  display: block;
}

/* =========================
   Nav (below carousel)
   ========================= */
.cg-wrapper.is-carousel .cg-nav {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 12px;
  margin-top: 16px;
}

.cg-wrapper.is-carousel .cg-nav__slot {
  display: flex;
  align-items: center;
}
.cg-wrapper.is-carousel .cg-nav__slot--prev { justify-content: flex-start; }
.cg-wrapper.is-carousel .cg-nav__slot--center { justify-content: center; }
.cg-wrapper.is-carousel .cg-nav__slot--next { justify-content: flex-end; }

/* =========================
   Arrows (in nav)
   ========================= */
.cg-wrapper.is-carousel .cg-arrow {
  appearance: none;
  background: transparent;
  border: 0;
  cursor: pointer;
  padding: 0;
  line-height: 0;
  color: #C7C7C7;
  font-size: 33px;
}
.cg-wrapper.is-carousel .cg-arrow:hover {
  color: #122638;
}
.cg-wrapper.is-carousel .cg-arrow:disabled {
  opacity: 0.4;
  cursor: default;
}
@media (max-width:768px) {
 .cg-wrapper.is-carousel .cg-arrow {
    position:absolute;
    display:inherit;
    top:42%;
  }
  .cg-wrapper.is-carousel .cg-arrow.cg-prev {
    left:-30px;
    right:auto;
  }
  .cg-wrapper.is-carousel .cg-arrow.cg-next {
    left:auto;
    right:-30px;
  }
}
/* =========================
   Numbers
   ========================= */
.cg-wrapper.is-carousel .cg-numbers {
  display: flex;
  gap: 8px;
  align-items: center;
}
@media (max-width:768px) {
    .cg-wrapper.is-carousel .cg-numbers {
      display: block;
      text-align: center;
    }
}
.cg-wrapper.is-carousel .cg-numbers button {
  appearance: none;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: transparent;
  border: 1px solid transparent;
  cursor: pointer;
  font: inherit;
  font-weight: 600;
  color: #122638;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;  
}
.cg-wrapper.is-carousel .cg-numbers button:hover {
  background-color: #122638;
  border-color: #122638;
  color: #fff;
}
.cg-wrapper.is-carousel .cg-numbers button[aria-selected="true"] {
  background-color: #47A14B;
  border-color: #47A14B;
  color: #fff;
}

/* =========================
   Dots
   ========================= */
.cg-wrapper.is-carousel .cg-dots {
  display: flex;
  gap: 10px;
  justify-content: center;
}
.cg-wrapper.is-carousel .cg-dots.align-left { justify-content: flex-start; }
.cg-wrapper.is-carousel .cg-dots.align-right { justify-content: flex-end; }

.cg-wrapper.is-carousel .cg-dots button {
  inline-size: 10px;
  block-size: 10px;
  border-radius: 50%;
  border: 0;
  background-color: #D8D8D8;
  padding: 0;
  cursor: pointer;
}
.cg-wrapper.is-carousel .cg-dots button:hover {
  background-color: #122638;
}
.cg-wrapper.is-carousel .cg-dots button[aria-selected="true"] {
  background-color: #47A14B;
}

/* =========================
   Lightbox
   ========================= */
.cg-lightbox {
  position: fixed;
  inset: 0;
  background: #fff;
  z-index: 999999;
  display: none;
}
.cg-lightbox[aria-hidden="false"] {
  display: block;
}

.cg-lightbox__inner {
  position: absolute;
  inset: 0;
}
.cg-lightbox__stage {
  overflow: hidden;
  touch-action: pan-y pinch-zoom;
}

.cg-lightbox__media {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.25s ease;
  will-change: transform;
}

.cg-lightbox__media.is-dragging {
  transition: none;
}

.cg-lightbox__stage video {
  width: 100%;
  max-height: 86vh;
}

@media (max-width: 1024px) {
  .cg-lightbox__stage video {
    width: 100%;
    max-height: 80vh;
  }
}

.cg-lightbox__stage img {
  cursor: grab;
}

.cg-lightbox__media.is-dragging img {
  cursor: grabbing;
}
.cg-lightbox__stage {
  width: 100%;
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  box-sizing: border-box;
}
.cg-lightbox__media {
  width: min(1200px, 92vw);
  max-width: 100%;
}

.cg-lightbox__stage img,
.cg-lightbox__stage a,
.cg-lightbox__media img {
  -webkit-user-drag: none;
  -khtml-user-drag: none;
  -moz-user-drag: none;
  -o-user-drag: none;
  user-drag: none;
  user-select: none;
}

.cg-lightbox__stage img,
.cg-lightbox__stage iframe {
  width: 100%;
  max-width: 100%;
  display: block;
}

.cg-lightbox__stage iframe {
  aspect-ratio: 16 / 9;
  height: auto;
  min-width: 0;
}
@media (max-width: 1024px) {
  .cg-lightbox__media {
    width: 100%;
    max-width: 100%;
  }

  .cg-lightbox__stage iframe {
    width: 100% !important;
    max-width: 100% !important;
  }
}


.cg-lightbox__stage img,
.cg-lightbox__stage iframe {
  max-width: 100%;
  max-height: 86vh;
  border-radius: 15px;
  display: block;
}

.cg-lightbox__stage iframe {
  width: 100%;
  aspect-ratio: 16 / 9;
  height: auto;
  min-width: 0;
}

@media (max-width: 1024px) {
  .cg-lightbox__stage img,
  .cg-lightbox__stage iframe {
    width: 100%;
    max-width: 100%;
    max-height: 80vh;
    border-radius: 15px;
  }
}
@media (max-width: 1220px) {
  .cg-lightbox__stage {
    padding: 25px;
  }
 .cg-lightbox__prev {
  left: 0 !important;
  padding-left:5px;
 }
 .cg-lightbox__next {
  right: 0 !important;
  padding-right:5px;
 }    
}
.cg-lightbox__close {
  position: absolute;
  top: 16px;
  /*inset-inline-end: 16px;*/
  inset-inline-end: 0;
  appearance: none;
  background: transparent;
  border: 0;
  color: #122638;
  font-size: 32px !important;
  font-weight:300 !important;
  cursor: pointer;
  z-index: 2;
}
.cg-lightbox__close:hover,
.cg-lightbox__close:focus {
  background: transparent;
  color: #5AC560;
}
.cg-lightbox__arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  appearance: none;
  background: transparent;
  border: 0;
  color: #D8D8D8;
  font-size: 48px !important;
  font-weight: 300 !important;
  cursor: pointer;
  opacity: 0.9;
  z-index: 2;
}
.cg-lightbox__arrow:hover,
.cg-lightbox__arrow:focus,
.cg-lightbox__arrow:active {
  color: #5AC560;
  background-color: transparent;
}
.cg-lightbox__prev { left: 12px; }
.cg-lightbox__next { right: 12px; }
@media (min-width: 1300px) {
  .cg-lightbox__prev {
    left: calc(50% - 600px - 55px);
  }

  .cg-lightbox__next {
    right: calc(50% - 600px - 55px);
  }
}


.cg-lightbox__arrow:disabled {
  opacity: 0.1;
  cursor: default;
}

.cg-lightbox-open {
  overflow: hidden;
}

/* =========================
   Drag UX helpers
   ========================= */

/* Prevent browser ghosting and text selection globally on these elements */
.cg-track img, 
.cg-track a {
  -webkit-user-drag: none;
  -khtml-user-drag: none;
  -moz-user-drag: none;
  -o-user-drag: none;
  user-drag: none;
  user-select: none;
  /* Keep pointer events active so clicks can pass through by default */
  pointer-events: auto;
}

/* While dragging, we "mute" the slide contents.
   This prevents the 'click' event from firing at the end of a drag. */
.cg-wrapper.is-carousel.cg-dragging .cg-track,
.cg-wrapper.is-carousel .cg-track.cg-dragging {
  cursor: grabbing;
}

.cg-wrapper.is-carousel.cg-dragging .cg-track img,
.cg-wrapper.is-carousel.cg-dragging .cg-track a,
.cg-wrapper.is-carousel.cg-dragging .cg-track video,
.cg-track.cg-dragging img,
.cg-track.cg-dragging a,
.cg-track.cg-dragging video {
  pointer-events: none !important;
}

/* Avoid text selection while dragging */
.cg-no-select,
.cg-no-select * {
  -webkit-user-select: none;
  user-select: none;
  -webkit-touch-callout: none;
}