:root {
  --gallery-modal-backdrop-color: rgba(43, 42, 51, 0.9);
  --gallery-modal-titlebar-background-color: #1c1c22;
  --gallery-modal-titlebar-title-color: #bbc1c7;
  --gallery-modal-titlebar-control-border: #2b2a33;
  --gallery-modal-titlebar-icon-color: #fff;
  --gallery-modal-caption-background-color: rgba(28, 28, 34, 0.9);
  --gallery-modal-caption-color: #bbc1c7;
  --gallery-modal-tags-background-color: rgba(28, 28, 34, 0.9);
  --gallery-modal-tags-color: #bbc1c7;
  --gallery-modal-item-background-color: #1d2327;
  --gallery-item-hover-background-color: rgba(43, 42, 51, 0.9);
  --gallery-item-hover-color: #fff;
  --sub-gallery-select-hover-background-color: rgba(43, 42, 51, 0.9);
  --gallery-filter-modal-label-background: #e1e1e1;
  --gallery-filter-modal-label-border: #d5d5d5;
}

/*	Gallery .site-content classes
    --------------------------------------------------------------------------	*/

.site-content.gallery.max-width #content {
  padding-left: 30px;
  padding-right: 30px;
}

/*	Gallery modal box
    --------------------------------------------------------------------------	*/

.site-gallery-modal {
  width: 100%;
  height: 100%;
  background: var(--gallery-modal-backdrop-color);
  /*backdrop-filter: blur(2px);*/
  position: fixed;
  top: 0;
  left: 0;
  display: none;
  z-index: 9999999;
}
.site-gallery-modal .modal-controls {
  width: 100%;
  height: 3rem;
  background: var(--gallery-modal-titlebar-background-color);
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: flex-end;
}
.site-gallery-modal .modal-controls .title {
  margin-right: auto;
  text-align: left;
  padding: 0 0 0 1rem;
  color: var(--gallery-modal-titlebar-title-color);
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: flex-start;
}
.site-gallery-modal .modal-controls .title i {
  font-size: 1.5rem;
  margin: 0 0.5rem 0 0;
}
.site-gallery-modal .control {
  width: 3rem;
  height: 3rem;
  cursor: pointer;
  border-left: 1px solid var(--gallery-modal-titlebar-control-border);
  transition: 0.5s all;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: 0.5s all;
}
.site-gallery-modal .control[disabled] {
  opacity: 0.5;
}
.site-gallery-modal .control[disabled]:hover {
  background: var(--primary);
}
.site-gallery-modal .control:not([disabled]):hover {
  background: var(--primary-hover);
}
.site-gallery-modal .control.close {
  background: var(--primary);
}
.site-gallery-modal .control.close:hover {
  background: var(--primary-hover);
}
.site-gallery-modal .control i {
  font-size: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--gallery-modal-titlebar-icon-color);
}
.site-gallery-modal .modal-container {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: calc(100% - 3rem);
}
.site-gallery-modal .modal {
  width: auto;
  height: auto;
  margin: 0 auto;
  display: block;
}
.site-gallery-modal .modal-content {
  width: 100%;
}
.site-gallery-modal .gallery-item {
  position: relative;
  overflow: hidden;
  background: var(--gallery-modal-item-background-color);
  border-radius: var(--border-radius);
}
.site-gallery-modal .gallery-item img {
  width: auto;
  max-width: calc(100vw - 4rem);
  height: auto;
  max-height: calc(100vh - 8rem);
  margin: 0 auto;
  display: block;
}

.site-gallery-modal:not(.magnify) .control-magnify {
  display: none;
}

.site-gallery-modal .control-magnify.active {
  background-color: var(--primary-hover);
}

.site-gallery-modal.magnify .gallery-item {
  overflow: visible !important;
}

/* Gallery modal captions */

.site-gallery-modal .gallery-item p {
  padding: 1rem;
  margin: 0;
  display: inline-block;
  width: calc(100% - 2rem);
  display: block;
  position: absolute;
  border-radius: var(--border-radius);
  left: 0;
  right: 0;
  margin: 0 auto;
  bottom: 1rem;
  background: var(--gallery-modal-caption-background-color);
  color: var(--gallery-modal-caption-color);
  overflow: hidden;
  text-transform: capitalize;
}

@media ( max-width: 580px ) {
  .site-gallery-modal .gallery-item:not(.is-video) p {
    padding: 0.2rem;
    font-size: .6rem;
  }
  
  .site-gallery-modal .gallery-item .tags {
    padding: 0.2rem;
    font-size: .5rem;
  }
}

@media (orientation: landscape) and (max-width: 768px) {
  .site-gallery-modal .gallery-item:not(.is-video) p {
    padding: 0.2rem;
    font-size: .6rem;
  }
  
  .site-gallery-modal .gallery-item .tags {
    padding: 0.2rem;
    font-size: .5rem;
  }
}

.site-gallery-modal .gallery-item .tags {
  margin: 0;
  display: inline-block;
  width: calc(100% - 2rem);
  position: absolute;
  left: 0;
  right: 0;
  margin: 0 auto;
  top: 1rem;
  color: var(--gallery-modal-tags-color);
  overflow: hidden;
  gap: .5em;
}

.site-gallery-modal .gallery-item .tags .tag {
  display: inline-block;
  border-radius: var(--border-radius);
  background: var(--gallery-modal-tags-background-color);
  color: var(--gallery-modal-tags-color);
  min-width: 60px;
  margin-right: .5em;
  text-align: center;
  padding: .5em;
  margin-bottom: .3em;
}

.site-gallery-modal .modal-content .tags .tag {
  float: left;
}

.site-gallery-container .show-more-btn,
.sub-gallery .show-more-btn {
  margin-top: 20px;
  text-align: center;
}

.site-gallery-container .show-more-btn a,
.sub-gallery .show-more-btn a {
  width: 100%;
}

.site-gallery.grid .gallery-item.show-more-hidden {
  display: none !important;
}

/*	Grid Gallery
    --------------------------------------------------------------------------	*/

/* The grid gallery columns */

.site-gallery.grid {
  display: grid;
  grid-template-columns: repeat(3, 3fr);
  gap: 1rem;
}

.site-gallery.grid[data-columns="1"] {
  grid-template-columns: repeat(1, 4fr);
}

.site-gallery.grid[data-columns="2"] {
  grid-template-columns: repeat(2, 4fr);
}

.site-gallery.grid[data-columns="4"] {
  grid-template-columns: repeat(4, 4fr);
}

.site-gallery.grid[data-columns="6"] {
  grid-template-columns: repeat(6, 6fr);
}

/* Smaller device gallery column sizes */

@media(max-width: 1032px) {
  .site-gallery.grid,
  .site-gallery.grid[data-columns] {
    grid-template-columns: repeat(2, 2fr);
  }
}
@media(max-width: 768px) {
  .site-gallery.grid,
  .site-gallery.grid[data-columns] {
    grid-template-columns: repeat(1, 1fr);
  }
}

/* Max-width only: larger window gallery column sizes */

@media(min-width: 1400px) {
  .site-content.gallery.max-width .site-gallery.grid,
  .site-content.gallery.max-width .site-gallery.grid[data-columns] {
    grid-template-columns: repeat(4, 4fr);
  }
}
@media(min-width: 1800px) {
  .site-content.gallery.max-width .site-gallery.grid,
  .site-content.gallery.max-width .site-gallery.grid[data-columns] {
    grid-template-columns: repeat(5, 5fr);
  }
}

/* The aspect ratio of the gallery images */

.site-gallery.grid .gallery-item {
  display: block;
  position: relative;
  width: 100%;
  height: auto;
  padding-bottom: calc(100%);
  overflow: hidden;
  border-radius: 0;
}

/* Crop and scale the gallery images */

.site-gallery.grid .gallery-item img {
  position: absolute;
  width: 100%;
  height: 100%;
  top: 0;
  left: 0;
  object-fit: cover;
}

/* The gallery image zoom icon */

.site-gallery.grid .gallery-item::after {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  content: '';
  background: var(--gallery-item-hover-background-color);
  background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" fill="%23fbfbfe" class="bi bi-arrows-angle-expand" viewBox="0 0 16 16"><path fill-rule="evenodd" d="M5.828 10.172a.5.5 0 0 0-.707 0l-4.096 4.096V11.5a.5.5 0 0 0-1 0v3.975a.5.5 0 0 0 .5.5H4.5a.5.5 0 0 0 0-1H1.732l4.096-4.096a.5.5 0 0 0 0-.707zm4.344-4.344a.5.5 0 0 0 .707 0l4.096-4.096V4.5a.5.5 0 1 0 1 0V.525a.5.5 0 0 0-.5-.5H11.5a.5.5 0 0 0 0 1h2.768l-4.096 4.096a.5.5 0 0 0 0 .707z"/></svg>');
  background-repeat: no-repeat;
  background-size: 3rem;
  background-position: center;
  font-size: 4rem;
  opacity: 0;
  transition: 0.5s all;
  cursor: zoom-in;
  border-radius: var(--border-radius);
}

.site-gallery.grid .gallery-item.is-video::after {
  font-family: 'Font Awesome 5 Pro';
  content: '\f04b';
  font-weight: 900;
  font-size: 4rem;
  background-image: none;
  color: var(--gallery-item-hover-color);
}

.site-gallery.grid .gallery-item:hover::after {
  opacity: 1;
}

.site-gallery.grid .gallery-item p,
.site-gallery.grid .gallery-item .tags {
  display: none;
}

/* Tags */

.filter-tags {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1em;
  margin-bottom: 1em;
}

.filter-tags a {
  text-align: center;
  background: var(--primary);
  padding: 5px 10px;
  border-radius: 500px;
  min-width: 100px;
  color: var(--light);
}

.filter-tags a.active {
  background: var(--primary);
  color: var(--light);
}

.filter-tags a:visited {
  color: var(--light);
}

.filter-tags a:hover,
.filter-tags a.selected {
  background: var(--secondary);
  color: var(--light);
}

/* Multi filter checkboxes */
.site-gallery-modal.filter-modal .modal-container {
  height: 100%;
}

.site-gallery-modal.filter-modal .modal-content {
  background: var(--light);
  width: 600px;
  height: calc(100vh - 8rem);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 5px 5px 10px 5px
}

.site-gallery-modal.filter-modal .inner {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  grid-row: auto auto;
  grid-column-gap: 40px;
  grid-row-gap: 20px;
  overflow: auto;
  width: 100%;
  padding: 5px;
}

@media ( max-width: 600px ) {
  .site-gallery-modal.filter-modal .modal-content {
    width: 100%;
  }
  .site-gallery-modal.filter-modal .modal {
    width: 100%;
  }
  .site-gallery-modal.filter-modal .inner {
    grid-template-columns: 1fr;
  }
  .site-gallery-modal.filter-modal .modal-content {
    height: calc(100vh - 8rem);
    width: calc(100vw - 2rem);
    margin: auto;
  }
}

.site-gallery-modal.filter-modal .footer {
  margin-top: 10px;
}

.site-gallery-modal.filter-modal .clear-filters {
  margin-bottom: 10px;
}

.site-gallery-modal.filter-modal input[type="checkbox"] {
  margin: 0;
  padding: 0;
  height: 15px;
  width: 15px;
}

.site-gallery-modal.filter-modal .inner label {
  background: var(--gallery-filter-modal-label-background);
  padding: .4rem;
  border: 1px solid var(--gallery-filter-modal-label-border);
  font-size: 1.1rem;
  cursor: pointer;
}

.site-gallery-modal.filter-modal .site-btn a {
  display: block;
  text-align: center;
}

.sub-gallery-title {
  margin-left: 5px;
}

.sub-gallery-title:not(:empty):before {
  content: '-';
  margin-right: 5px;
}

/* Sub Galleries */

.sub-gallery-select {
  position: relative;
  display: grid;
  gap: 2rem;
  grid-template-columns: repeat(auto-fit,minmax(20rem,1fr));
}

.sub-gallery-select > div {
  position: relative;
  cursor: pointer;
  font-size: 1.2rem;
  width: 100%;
  background-repeat: no-repeat;
  background-size: cover;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

.sub-gallery-select > div.selected .image::before {
  content: 'Viewing';
  position: absolute;
  font-size: 2.5rem;
  font-weight: bold;
  width: 100%;
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  color: #fff;
  z-index: 3;
  border-radius: var(--border-radius );
}

.sub-gallery-select > div > .label {
  text-align: center;
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  margin-bottom: .5rem;
  font-size: 1.15rem;
}

.sub-gallery-select > div > .image {
  position: relative;
  width: 100%;
  height: 19rem;
  background-position: bottom;
  background-size: cover;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

.sub-gallery-select > div.selected .image::before {
  content: 'Viewing';
  position: absolute;
  width: 100%;
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  color: #fff;
  z-index: 3;
  border-radius: var(--border-radius );
  background-color: var(--sub-gallery-select-hover-background-color);
  font-size: 1.5rem;
  font-weight: 500;
}

.sub-gallery-select > div:not(.selected) > .image::after {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  content: '';
  background: var(--sub-gallery-select-hover-background-color);
  background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" fill="%23fbfbfe" viewBox="0 0 512 512"><!--! Font Awesome Pro 6.4.0 by @fontawesome - https://fontawesome.com License - https://fontawesome.com/license (Commercial License) Copyright 2023 Fonticons, Inc. --><path d="M416 208c0 45.9-14.9 88.3-40 122.7L502.6 457.4c12.5 12.5 12.5 32.8 0 45.3s-32.8 12.5-45.3 0L330.7 376c-34.4 25.2-76.8 40-122.7 40C93.1 416 0 322.9 0 208S93.1 0 208 0S416 93.1 416 208zM208 352a144 144 0 1 0 0-288 144 144 0 1 0 0 288z"/></svg>');
  background-repeat: no-repeat;
  background-size: 3rem;
  background-position: center;
  font-size: 4rem;
  opacity: 0;
  transition: 0.5s all;
  cursor: zoom-in;
  border-radius: var(--border-radius );
  z-index: 3;
}
.sub-gallery-select > div:not(.selected):hover .image::after {
  opacity: 1;
}

.gallery-select-prompt,
.selected-gallery-name {
  font-size: 1.3rem;
  text-align: center;
  font-weight: 500;
  font-family: var(--font-heading);
}

/* Sub-Gallery Thumbnail Layouts */

.sub-gallery-select > div .label {
  z-index: 1;
  bottom: 0;
  background: var(--primary);
  width: 100%;
  padding: 10px 0;
  color: #fff;
  margin-bottom: 0;
  border-radius: 0;
  position: relative;
}

.sub-gallery-select>div .label:has(.inner-label):has(.inner-description) .inner-label {
  font-weight: 600;
  font-size: 1rem;
  margin-bottom: .1rem;
}

.sub-gallery-select>div .label .inner-description {
  font-size: .8rem;
}

.sub-gallery-select[thumbnail-label-layout="top"] .label {
  border-top-left-radius: var(--border-radius);
  border-top-right-radius: var(--border-radius);
}

.sub-gallery-select[thumbnail-label-layout="top"] > div:not(.selected):hover .label:after {
  opacity: 1;
}

.sub-gallery-select[thumbnail-label-layout="top"] .image,
.sub-gallery-select[thumbnail-label-layout="top"] .image::before,
.sub-gallery-select[thumbnail-label-layout="top"] .image::after {
  border-top-left-radius: 0 !important;
  border-top-right-radius: 0 !important;
  border-bottom-left-radius: var(--border-radius);
  border-bottom-right-radius: var(--border-radius);
}

.sub-gallery-select[thumbnail-label-layout="overlay"] .image {
  border-radius: var(--border-radius);
}

.sub-gallery-select[thumbnail-label-layout="overlay"] .label {
  position: absolute;
  border-bottom-left-radius: var(--border-radius);
  border-bottom-right-radius: var(--border-radius);
}

.sub-gallery-select[thumbnail-label-layout="overlay"] > div.selected .image::before,
.sub-gallery-select[thumbnail-label-layout="overlay"] > div:not(.selected) > .image::after {
  background-position-y: calc(50% - 10px);
}

.filter-no-results {
  display: none;
  text-align: center;
}

/* Magnifier */

.gallery-item .magnifier-glass {
  position: absolute;
  border: 3px solid var(--primary);
  border-radius: 50%;
  cursor: none;
  /*Set the size of the magnifier glass:*/
  width: 400px;
  height: 400px;
  z-index: 9999999;
  pointer-events: none;
  opacity: 1;
  transition: opacity 0.5s ease;
}

.site-gallery-modal.magnify-active .gallery-item.magnify-hover {
  cursor: none;
}

.gallery-item:not(.magnify-hover) .magnifier-glass {
  opacity: 0;
}

@media ( max-width: 768px ) {
  .gallery-item .magnifier-glass,
  .site-gallery-modal .control-magnify {
    display: none !important;
  }
}

/* Video Gallery Item */

.gallery-item.is-video video,
.gallery-item.is-video iframe,
.site-gallery-modal .gallery-item.is-video .magnifier-glass {
  display: none;
}

.site-gallery-modal .gallery-item.is-video {
  overflow: visible;
}

.site-gallery-modal .gallery-item.is-video video,
.site-gallery-modal .gallery-item.is-video iframe {
  display: block;
}

.site-gallery-modal .gallery-item.is-video img {
  display: none;
}

.site-gallery-modal .gallery-item.is-video p {
  width: 100%;
  bottom: -4rem;
}

.site-gallery-modal .gallery-item.is-video {
  max-width: 650px;
  margin: auto;
}

.site-gallery-modal .gallery-item.is-video video,
.site-gallery-modal .gallery-item.is-video iframe {
  max-height: 600px;
}

.site-gallery.grid .gallery-item.is-video::before {
  font-family: 'Font Awesome 5 Pro';
  content: '\f04b';
  position: absolute;
  bottom: 20px;
  right: 20px;
  z-index: 1;
  font-weight: 900;
  font-size: 2rem;
  color: var(--primary);
  opacity: .8;
}

.site-gallery.grid .gallery-item.is-video:hover::before {
  opacity: 0;
}

.site-gallery.grid .gallery-item.is-video::after {
  z-index: 2;
}

.site-gallery-modal .gallery-item.is-video.is-external {
  width: calc(100vw - 4rem);
}

.site-gallery-modal .external-container {
  position: relative;
  padding-bottom: 56.25%; /* 16:9 aspect ratio */
  height: 0;
  max-width: 100%;
}

.site-gallery-modal .external-container iframe {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

.site-gallery-modal .gallery-item.is-external .tags {
  top: -3rem;
  margin: 0;
}

/* Before After Slider */
.before-after-slider {
  width: 100%;
  min-height: 37.5rem;
  position: relative;
  overflow: hidden;
  border-radius: var(--border-radius);
  margin-top: 2rem;
}

.before-after-slider .before::before, .before-after-slider .after::before {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  font-weight: 400;
  color: var(--ultralight);
  letter-spacing: .5px;
  line-height: 1;
  padding: .5rem 1rem;
  background: var(--primary-opacity);
  border-radius: var(--border-radius);
  box-shadow: var(--box-shadow);
  position: absolute;
  top: 1rem;
  z-index: 3;
}

.before-after-slider .before::before {
  content: 'Before';
  left: 1rem
}

.before-after-slider .after::before {
  content: 'After';
  right: 1rem;
}

.before-after-slider .image {
  height: 100%;
  width: 100%;
  position: absolute;
  top: 0;
  left: 0;
  object-fit: cover;
}

.before-after-slider .image img {
  height: 100%;
  width: 100%;
  object-fit: cover;
  border-radius: 0 !important;
}

.before-after-slider input.slider:focus-within {
  border: none!important;
}

.before-after-slider .image.before {
  width: 100%;
  z-index: 2;
  clip-path: polygon(0 0, 50% 0, 50% 100%, 0% 100%)
}

.before-after-slider .image.after {
  width: 100%;
  z-index: 1
}

.before-after-slider .slider {
  width: 100%;
  height: 100%;
  outline: none;
  background-color: initial;
  position: absolute;
  margin: 0;
  cursor: pointer;
  appearance: none;
  -moz-appearance: none;
  -webkit-appearance: none;
  transition: .25s all ease-in-out;
  -moz-transition: .25s all ease-in-out;
  -webkit-transition: .25s all ease-in-out;
  z-index: 4
}

.before-after-slider .slider::-moz-range-thumb {
  position: relative;
  width: 10px;
  height: 100vh;
  left: 3px;
  background-color: #fff;
  cursor: pointer
}

.before-after-slider .slider::-webkit-slider-thumb {
  position: relative;
  width: 10px;
  height: 100vh;
  left: 3px;
  background-color: var(--primary);
  cursor: pointer;
  appearance: none;
  -moz-appearance: none;
  -webkit-appearance: none
}

.before-after-slider .slider-button {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  -moz-broder-radius: 50%;
  -webkit-border-radius: 50%;
  background-color: var(--primary);
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  z-index: 4;
  pointer-events: none;
}

@media ( min-width: 1920px ) {
  .before-after-slider .slider-button { 
    margin-left: -.2rem;
  }
}

.before-after-slider .slider-button:before,
.before-after-slider .slider-button:after {
  font-family: 'font awesome 7 pro';
  color: var(--ultralight);
  position: absolute;
  top: 50%;
  left: 0;
  transform: translate(50%, -50%);
}

.before-after-slider .slider-button:before {
  left: 0;
  content: "\f053"
}

.before-after-slider .slider-button:after {
  right: 0;
  content: "\f054"
}

@media ( max-width: 1920px ) {
  .before-after-slider .slider-button:after {
    right: -3px;
  }
}

/* Slideshow */
.site-slideshow {
  position: relative;
  width: 100%;
  overflow: hidden;
}

.site-slideshow .slideshow-viewport {
  position: relative;
  width: 100%;
  overflow: hidden;
  border-radius: var(--border-radius);
}

.site-slideshow .slideshow-track {
  display: flex;
  width: 100%;
  transition: transform 0.45s ease;
  will-change: transform;
}

.site-slideshow .slideshow-slide {
  flex: 0 0 100%;
  width: 100%;
  position: relative;
  box-sizing: border-box;
}

.site-slideshow .slide-inner {
  width: 100%;
}

.site-slideshow .slide-media {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: var(--dark);
}

.site-slideshow .slide-media img,
.site-slideshow .slide-media video,
.site-slideshow .slide-media iframe {
  display: block;
  width: 100%;
  height: 100%;
  max-height: 100% !important;
  object-fit: cover;
}

.site-slideshow .gallery-image,
.site-slideshow .gallery-video {
  display: block;
  width: 100%;
  height: 100%;
}

.site-slideshow .external-container {
  width: 100%;
  height: 100%;
}

.site-slideshow .external-frame {
  width: 100%;
  height: 100%;
}

.site-slideshow .slide-title {
  position: absolute;
  left: 1.25rem;
  bottom: 1.25rem;
  margin: 0;
  padding: 0.625rem 0.875rem;
  background: rgba(0, 0, 0, 0.6);
  color: #fff;
  z-index: 2;
}

.site-slideshow .tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.75rem;
}

.site-slideshow .tag {
  padding: 0.375rem 0.625rem;
  background: var(--accent);
  font-size: 0.875rem;
  line-height: 1;
}

.site-slideshow .slideshow-controls {
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  transform: translateY(-50%);
  display: flex;
  justify-content: space-between;
  pointer-events: none;
  padding: 0 0.75rem;
  z-index: 3;
}

.site-slideshow .control {
  pointer-events: auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 3rem;
  height: 3rem;
  border: 0;
  border-radius: 999px;
  background: var(--primary-opacity);
  color: var(--ultralight);
  cursor: pointer;
  transition: background 0.2s ease, opacity 0.2s ease;
}

.site-slideshow .control:hover {
  color: var(--primary-opacity);
  background: var(--light-opacity);
}

.site-slideshow .control:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.site-slideshow .control i {
  pointer-events: none;
}

@media (max-width: 47.9375rem) {
  .site-slideshow .slide-media {
    aspect-ratio: 4 / 3;
  }

  .site-slideshow .control {
    width: 2.5rem;
    height: 2.5rem;
  }

  .site-slideshow .slide-title {
    left: 0.75rem;
    right: 0.75rem;
    bottom: 0.75rem;
    padding: 0.5rem 0.625rem;
    font-size: 0.875rem;
  }
}

/* Slideshow Thumbnail Nav */
.slideshow-thumb-nav {
    position: relative;
    margin-top: 0.625rem;
    overflow: hidden;
}

.slideshow-thumb-nav-viewport {
    overflow: hidden;
    width: 100%;
}

.slideshow-thumb-nav-track {
    display: flex;
    transition: transform 0.35s ease;
    will-change: transform;
}

.slideshow-thumb-nav-item {
    flex: 0 0 calc(100% / 5);
    padding: 0.1875rem;
    border: 2px solid transparent;
    background: none;
    cursor: pointer;
    transition: border-color 0.2s ease;
    box-sizing: border-box;
}

.slideshow-thumb-nav-item img {
    display: block;
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    border-radius: var(--border-radius);
}

.slideshow-thumb-nav-item.is-active {
    border-color: var(--primary);
    border-radius: var(--border-radius);
}

.slideshow-thumb-nav-item:not(.is-active):hover {
    border-color: var(--primary-opacity);
    border-radius: var(--border-radius);
}

/* Bullets */
.slideshow-thumb-nav-bullets {
    display: flex;
    justify-content: center;
    gap: 0.4rem;
    margin-top: 0.5rem;
}

.slideshow-thumb-bullet {
    width: 0.625rem;
    height: 0.625rem;
    border-radius: 50%;
    border: 2px solid var(--primary);
    background: transparent;
    padding: 0;
    cursor: pointer;
    transition: background 0.2s ease;
}

.slideshow-thumb-bullet.is-active {
    background: var(--primary);
}

/* Thumb page prev/next */
.slideshow-thumb-nav-prev,
.slideshow-thumb-nav-next {
    position: absolute;
    top: 50%;
    transform: translateY(calc(-50% - 0.6rem)); /* nudge above bullets */
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    height: 2rem;
    border: 0;
    border-radius: 999px;
    background: var(--primary-opacity);
    color: var(--ultralight);
    cursor: pointer;
    z-index: 2;
    transition: background 0.2s ease, opacity 0.2s ease;
}

.slideshow-thumb-nav-prev { left: 0; }
.slideshow-thumb-nav-next { right: 0; }

.slideshow-thumb-nav-prev:hover,
.slideshow-thumb-nav-next:hover {
    background: var(--light-opacity);
}

.slideshow-thumb-nav-prev:disabled,
.slideshow-thumb-nav-next:disabled {
    opacity: 0.35;
    cursor: not-allowed;
}

.sub-gallery-button.site-btn a::after {
  content: '';
  padding: 0;
  margin: 0;
}

.sub-gallery-select[sub-gallery-type="buttons"] {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.5rem;
}

.sub-gallery-select[sub-gallery-type="buttons"] ~ .sub-gallery-outer {
  margin-top: 1rem;
}

.sub-gallery-select .sub-gallery-button {
  width: auto;
}

.sub-gallery-select[sub-gallery-type="buttons"] + hr {
  display: none!important;
}

.sub-gallery-button:not(.selected) a {
  background: var(--med);
  border-color: var(--med);
  color: var(--secondary)
}

.sub-gallery-select[sub-gallery-type="buttons"] ~ .selected-gallery-name {
  margin-top: 2rem;
  display: none!important;
}

@media ( min-width:1860px ) {
  a.inner-label {
    font-size: .8vw;
  }
}