/* Gallery settings apply only to the native core/gallery when this plugin is active. */
.nr-gallery-shell { position: relative; width: 100%; max-width: 100%; margin-inline: auto; min-width: 0; }
.nr-gallery-shell[data-nr-width="wide"] { width: min(1454px, calc(100vw - 48px)); max-width: none; left: 50%; transform: translateX(-50%); margin-inline: 0; }
/* clientWidth excludes the vertical scrollbar; 100vw includes it on browsers with classic scrollbars. */
.nr-gallery-shell[data-nr-width="full"] { width: var(--nr-gallery-viewport-width, 100%); max-width: none; left: 50%; transform: translateX(-50%); margin-inline: 0; }
.nr-gallery-shell > figure.wp-block-gallery.nr-enhanced-gallery {
  box-sizing: border-box;
  width: 100% !important;
  max-width: none !important;
  min-width: 0;
  margin: 0 !important;
  --nr-gallery-gap: 12px;
  --nr-gallery-height: 380px;
  --nr-gallery-radius: 0px;
  --nr-gallery-fit: cover;
}
.nr-gallery-shell > figure.nr-enhanced-gallery > figure.wp-block-image,
.nr-entry-body .nr-intro-gallery .nr-gallery-shell > figure.nr-enhanced-gallery > figure.wp-block-image:not(#individual-image) {
  box-sizing: border-box;
  min-width: 0;
  min-height: 0;
  max-width: none !important;
  margin: 0 !important;
  overflow: hidden;
  border-radius: var(--nr-gallery-radius);
}
.nr-gallery-shell > figure.nr-enhanced-gallery > figure.wp-block-image img,
.nr-entry-body .nr-intro-gallery .nr-gallery-shell > figure.nr-enhanced-gallery > figure.wp-block-image img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: var(--nr-gallery-fit);
  border-radius: inherit;
}
.nr-gallery-shell > figure.nr-enhanced-gallery > figure.wp-block-image img[role="button"] { cursor: zoom-in; }
.nr-gallery-shell > figure.nr-enhanced-gallery > figure.wp-block-image img:focus-visible { outline: 3px solid #456e8d; outline-offset: -3px; }

.nr-gallery-shell[data-nr-current-layout="grid"] > figure.nr-enhanced-gallery {
  display: grid !important;
  grid-template-columns: repeat(var(--nr-gallery-effective-columns, 3), minmax(0, 1fr)) !important;
  gap: var(--nr-gallery-gap) !important;
  height: auto !important;
  overflow: visible !important;
  padding: 0 !important;
}
.nr-gallery-shell[data-nr-current-layout="grid"] > figure.nr-enhanced-gallery > figure.wp-block-image,
.nr-entry-body .nr-intro-gallery .nr-gallery-shell[data-nr-current-layout="grid"] > figure.nr-enhanced-gallery > figure.wp-block-image:not(#individual-image) {
  display: block !important;
  width: 100% !important;
  height: var(--nr-gallery-height) !important;
  flex: none !important;
}
.nr-gallery-shell[data-nr-current-layout="masonry"] > figure.nr-enhanced-gallery {
  display: block !important;
  columns: var(--nr-gallery-effective-columns, 3);
  column-gap: var(--nr-gallery-gap);
  height: auto !important;
  padding: 0 !important;
  overflow: visible !important;
}
.nr-gallery-shell[data-nr-current-layout="masonry"] > figure.nr-enhanced-gallery > figure.wp-block-image,
.nr-entry-body .nr-intro-gallery .nr-gallery-shell[data-nr-current-layout="masonry"] > figure.nr-enhanced-gallery > figure.wp-block-image:not(#individual-image) {
  display: inline-block !important;
  width: 100% !important;
  height: auto !important;
  margin: 0 0 var(--nr-gallery-gap) !important;
  break-inside: avoid;
  vertical-align: top;
}
.nr-gallery-shell[data-nr-current-layout="masonry"] > figure.nr-enhanced-gallery > figure.wp-block-image img { height: auto !important; }

/* A five-panel Figma composition, never forced onto mobile unless explicitly selected. */
.nr-gallery-shell[data-nr-current-layout="strip"] > figure.nr-enhanced-gallery {
  display: grid !important;
  grid-template-columns: 1fr 1fr 2.2fr 1fr 1fr !important;
  gap: var(--nr-gallery-gap) !important;
  width: 100% !important;
  height: var(--nr-gallery-height) !important;
  padding: 0 !important;
  overflow: hidden !important;
}
.nr-gallery-shell[data-nr-current-layout="strip"] > figure.nr-enhanced-gallery > figure.wp-block-image,
.nr-entry-body .nr-intro-gallery .nr-gallery-shell[data-nr-current-layout="strip"] > figure.nr-enhanced-gallery > figure.wp-block-image:not(#individual-image) {
  display: block !important;
  width: 100% !important;
  height: 100% !important;
  flex: none !important;
}

.nr-gallery-shell[data-nr-current-layout="slider"] > figure.nr-enhanced-gallery {
  --nr-gallery-slide-basis: min(740px, 76%);
  display: flex !important;
  flex-wrap: nowrap !important;
  align-items: stretch !important;
  gap: var(--nr-gallery-gap) !important;
  height: var(--nr-gallery-height) !important;
  max-width: none !important;
  overflow-x: auto !important;
  overflow-y: hidden !important;
  padding: 0 max(18px, calc((100% - var(--nr-gallery-slide-basis)) / 2)) 8px !important;
  scroll-snap-type: x mandatory;
  overscroll-behavior-inline: contain;
  scrollbar-width: none;
  -webkit-overflow-scrolling: touch;
}
.nr-gallery-shell[data-nr-current-layout="slider"] > figure.nr-enhanced-gallery::-webkit-scrollbar { display: none; }
.nr-gallery-shell[data-nr-current-layout="slider"] > figure.nr-enhanced-gallery > figure.wp-block-image,
.nr-entry-body .nr-intro-gallery .nr-gallery-shell[data-nr-current-layout="slider"] > figure.nr-enhanced-gallery > figure.wp-block-image:not(#individual-image) {
  display: block !important;
  flex: 0 0 var(--nr-gallery-slide-basis) !important;
  width: var(--nr-gallery-slide-basis) !important;
  min-width: var(--nr-gallery-slide-basis);
  height: 100% !important;
  scroll-snap-align: center;
}
.nr-gallery-shell .nr-gallery-arrow {
  position: absolute;
  z-index: 3;
  top: 45%;
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  padding: 0 0 3px;
  border: 1px solid rgba(69,110,141,.35);
  border-radius: 50%;
  transform: translateY(-50%);
  background: #fff;
  color: #12324b;
  box-shadow: 0 4px 18px rgba(0,0,0,.12);
  font: 500 30px/1 Arial,sans-serif;
  cursor: pointer;
}
.nr-gallery-shell .nr-gallery-prev { left: 14px; }
.nr-gallery-shell .nr-gallery-next { right: 14px; }
.nr-gallery-shell .nr-gallery-arrow:disabled { opacity: .35; cursor: default; }
.nr-gallery-shell .nr-gallery-arrow:focus-visible,
.nr-gallery-shell .nr-gallery-dots button:focus-visible { outline: 3px solid #456e8d; outline-offset: 3px; }
.nr-gallery-dots { display: flex; justify-content: center; align-items: center; flex-wrap: wrap; gap: 10px; margin: 15px auto 0; }
.nr-gallery-dots button { width: 10px; height: 10px; padding: 0; border: 0; border-radius: 50%; background: #a8bbcb; cursor: pointer; }
.nr-gallery-dots button[aria-current="true"] { background: #12324b; transform: scale(1.25); }

.nr-gallery-lightbox { position: fixed; z-index: 100000; inset: 0; display: grid; place-items: center; padding: 60px; background: rgba(4,15,27,.94); }
.nr-gallery-lightbox-image { display: block; max-width: min(90vw, 1600px); max-height: 84vh; width: auto; height: auto; object-fit: contain; }
.nr-gallery-lightbox button { position: fixed; z-index: 1; display: grid; place-items: center; width: 48px; height: 48px; padding: 0; border: 1px solid rgba(255,255,255,.5); border-radius: 50%; background: rgba(0,0,0,.55); color: #fff; font: 32px/1 Arial,sans-serif; cursor: pointer; }
.nr-gallery-lightbox button:focus-visible { outline: 3px solid #fff; outline-offset: 3px; }
.nr-gallery-lightbox .nr-gallery-lightbox-close { top: 18px; right: 18px; }
.nr-gallery-lightbox .nr-gallery-lightbox-prev { top: 50%; left: 14px; transform: translateY(-50%); }
.nr-gallery-lightbox .nr-gallery-lightbox-next { top: 50%; right: 14px; transform: translateY(-50%); }
.nr-gallery-lightbox button[hidden] { display: none; }

@media (min-width: 768px) and (max-width: 1179px) {
  .nr-gallery-shell[data-nr-current-layout="slider"] > figure.nr-enhanced-gallery { --nr-gallery-slide-basis: min(650px, 78%); }
}
@media (max-width: 767px) {
  .nr-gallery-shell[data-nr-width="wide"] { width: calc(100vw - 36px); }
  .nr-gallery-shell[data-nr-current-layout="slider"] > figure.nr-enhanced-gallery {
    --nr-gallery-slide-basis: 82%;
    height: min(var(--nr-gallery-height), 80vw) !important;
    padding-inline: 18px !important;
    scroll-padding-inline: 18px;
  }
  .nr-gallery-shell[data-nr-current-layout="grid"] > figure.nr-enhanced-gallery > figure.wp-block-image { height: min(var(--nr-gallery-height), 80vw) !important; }
  .nr-gallery-shell .nr-gallery-arrow { width: 38px; height: 38px; font-size: 27px; }
  .nr-gallery-lightbox { padding: 15px; }
  .nr-gallery-lightbox-image { max-width: calc(100vw - 30px); max-height: calc(100dvh - 120px); }
}
@media (prefers-reduced-motion: reduce) {
  .nr-gallery-shell > figure.nr-enhanced-gallery { scroll-behavior: auto !important; }
  .nr-gallery-dots button { transition: none; }
}
