#header .logo,
#header .logo-subtitle {
  max-width: 100%;
}

@media (max-width: 750px) {
  #header .logo {
    font-size: clamp(1.25rem, 5vw, 2.5rem);
    line-height: 1.1;
  }

  #header .logo-subtitle {
    font-size: clamp(0.75rem, 3vw, 1rem);
    line-height: 1.2;
  }
}

#mobileNav {
  overflow: hidden;
  transition: height 0.2s ease;
}

#header {
  transition: top 0.2s ease;
}

/* Squarespace gallery thumbs stay opacity:0 until ImageLoader adds .loaded */
.sqs-gallery-block-grid img.thumb-image[src],
.sqs-gallery-block-grid img.loaded,
.sqs-gallery-block-grid .sqs-video-overlay img[src],
.sqs-gallery-block-grid .sqs-video-overlay img.loaded,
#projectThumbs img[src],
#projectThumbs img.loaded {
  opacity: 1;
}

/* Square grid crops (replaces ImageLoader fill mode + focal point) */
.sqs-gallery-block-grid.sqs-gallery-aspect-ratio-square .slide .margin-wrapper a.image-slide-anchor.content-fit,
.sqs-gallery-block-grid.sqs-gallery-aspect-ratio-square .slide .margin-wrapper .content-wrapper.content-fit {
  position: relative;
  overflow: hidden;
}

.sqs-gallery-block-grid .slide .margin-wrapper a.image-slide-anchor.content-fit img.thumb-image,
.sqs-gallery-block-grid .slide .margin-wrapper .content-wrapper.content-fit .sqs-video-overlay img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  max-width: none;
  max-height: none;
  object-fit: cover;
  object-position: center center;
  display: block;
}

.sqs-gallery-block-grid .slide .margin-wrapper .content-wrapper.content-fit .sqs-video-wrapper {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

.sqs-gallery-block-grid .slide .margin-wrapper .content-wrapper.content-fit .sqs-video-overlay {
  opacity: 1 !important;
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}

.sqs-gallery-block-grid.sqs-gallery-thumbnails-per-row-6 .slide {
  width: 16.66666667%;
}

.sqs-gallery-block-grid.sqs-gallery-thumbnails-per-row-6 .slide:nth-child(6n + 1) {
  clear: left;
}

@media (max-width: 767px) {
  .sqs-gallery-block-grid .slide {
    width: 50% !important;
    clear: none !important;
  }
}

#projectThumbs img {
  object-fit: cover;
  object-position: center center;
}

.site-lightbox {
  border: none;
  padding: 0;
  margin: 0;
  max-width: none;
  max-height: none;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.88);
  color: #fff;
}

.site-lightbox::backdrop {
  background: rgba(0, 0, 0, 0.88);
}

.site-lightbox__panel {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 3rem 1rem 1rem;
  box-sizing: border-box;
}

.site-lightbox__content {
  max-width: min(96vw, 1200px);
  max-height: calc(100vh - 6rem);
  display: flex;
  align-items: center;
  justify-content: center;
}

.site-lightbox__content img {
  display: block;
  max-width: 100%;
  max-height: calc(100vh - 6rem);
  width: auto;
  height: auto;
}

.site-lightbox__video iframe {
  display: block;
  max-width: 100%;
  border: 0;
}

.site-lightbox__caption {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 1rem 4rem;
  text-align: center;
  font-size: 0.95rem;
  line-height: 1.4;
}

.site-lightbox__close,
.site-lightbox__prev,
.site-lightbox__next {
  position: absolute;
  border: 0;
  background: transparent;
  color: #fff;
  font-size: 2rem;
  line-height: 1;
  cursor: pointer;
  padding: 0.5rem;
}

.site-lightbox__close {
  top: 0.5rem;
  right: 0.5rem;
}

.site-lightbox__prev {
  left: 0.25rem;
  top: 50%;
  transform: translateY(-50%);
}

.site-lightbox__next {
  right: 0.25rem;
  top: 50%;
  transform: translateY(-50%);
}
