/* Opt-in and frontend only: without JS, the native gallery remains available. */
.est-gallery-slider-shell { --est-slide-height: clamp(170px, 23vw, 300px); --est-slider-stage-height: calc(var(--est-slide-height) * 1.22); position: relative; margin: 48px auto 0; }
.is-frontend .wp-block-gallery:is(.est-gallery-slider, .is-style-est-slider).is-enhanced {
  display: flex; flex-wrap: nowrap; align-items: center; gap: 20px; height: var(--est-slider-stage-height); max-width: 100%; margin: 0;
  padding-block: 16px; box-sizing: border-box; overflow-x: auto; overflow-y: hidden; overscroll-behavior-x: contain;
  scrollbar-width: none;
}
.wp-block-gallery.is-enhanced::-webkit-scrollbar { display: none; }
.is-frontend .wp-block-gallery.is-enhanced::before,
.is-frontend .wp-block-gallery.is-enhanced::after { content: ''; display: block; height: 1px; }
.is-frontend .wp-block-gallery.is-enhanced::before { flex: 0 0 var(--est-edge-start, 0px); }
.is-frontend .wp-block-gallery.is-enhanced::after { flex: 0 0 var(--est-edge-end, 0px); }
.is-frontend .wp-block-gallery.is-enhanced > figure.wp-block-image {
  /* Override the native gallery's ID-specific column widths and automatic bottom margin. */
  flex: 0 0 auto; width: min(calc(var(--est-slide-height) * var(--est-slide-ratio, 1.5)), calc(100% - 64px)) !important;
  height: auto; aspect-ratio: var(--est-slide-ratio, 1.5); margin: 0 !important; position: relative;
  transform: scale(1); transition: transform .25s ease; z-index: 0;
}
.is-frontend .wp-block-gallery.is-enhanced > figure.wp-block-image.is-active { transform: scale(1.15); z-index: 1; }
.is-frontend .wp-block-gallery.is-enhanced > figure.wp-block-image a { display: block; width: 100%; height: 100%; }
.is-frontend .wp-block-gallery.is-enhanced > figure.wp-block-image img { display: block; width: 100%; height: 100%; max-width: none; object-fit: contain; }
.est-gallery-slider__arrow { position: absolute; top: calc((var(--est-slider-stage-height) - 44px) / 2); z-index: 2; width: 44px; height: 44px; padding: 0; border: 1px solid rgba(255,255,255,.6); background: rgba(16,75,102,.8); color: #fff; font-size: 32px; line-height: 1; cursor: pointer; }
.est-gallery-slider__arrow:hover { background: var(--accent); }
.est-gallery-slider__arrow:disabled { opacity: .3; cursor: default; }
.est-gallery-slider__arrow--previous { left: 8px; }
.est-gallery-slider__arrow--next { right: 8px; }
.est-gallery-slider__dots { display: flex; flex-wrap: wrap; justify-content: center; gap: 0; max-width: 100%; margin: 6px auto 0; }
.est-gallery-slider__dot { display: grid; place-items: center; width: 28px; height: 36px; padding: 0; border: 0; background: transparent; color: var(--accent); cursor: pointer; }
.est-gallery-slider__dot::before { content: ''; width: 8px; height: 8px; border: 1px solid currentColor; border-radius: 50%; }
.est-gallery-slider__dot[aria-current='true']::before { background: currentColor; }
.est-gallery-slider__dot:hover { background: var(--base-2); color: var(--accent); }
.est-gallery-slider__status { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.est-events-content .est-events-slider-heading { max-width: 790px; margin: 48px auto 0; }
.est-events-slider-heading + .est-gallery-slider-shell { margin-top: 16px; }
@media (prefers-reduced-motion: reduce) {
  .is-frontend .wp-block-gallery.is-enhanced > figure.wp-block-image { transition: none; }
}
