

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* -------------------------------------------------------------------------
   Body lock — prevent scroll when overlay is open
   ------------------------------------------------------------------------- */

body.page-overlay--open {
  overflow: hidden;
}

/* -------------------------------------------------------------------------
   Overlay backdrop
   ------------------------------------------------------------------------- */

.page-overlay {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: rgba(0, 0, 0, 0);
  visibility: hidden;
  transition:
    background-color 0.35s ease,
    visibility 0.35s ease;
}

.page-overlay--visible {
  visibility: visible;
  background-color: rgba(0, 0, 0, 0.55);
}

/* -------------------------------------------------------------------------
   Shared container styles
   ------------------------------------------------------------------------- */

.page-overlay__container {
  position: relative;
  background: var(--page-overlay-bg, #fff);
  color: var(--page-overlay-color, #000);
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
  outline: none;
}

/* -------------------------------------------------------------------------
   Popup container
   ------------------------------------------------------------------------- */

.page-overlay__container--popup {
  width: 90vw;
  max-width: 960px;
  max-height: 85vh;
  border-radius: 6px;
  opacity: 0;
  transform: translateY(20px) scale(0.98);
  transition:
    opacity 0.35s ease,
    transform 0.35s ease;
}

.page-overlay--visible .page-overlay__container--popup {
  opacity: 1;
  transform: translateY(0) scale(1);
}

/* -------------------------------------------------------------------------
   Slideout container
   ------------------------------------------------------------------------- */

.page-overlay__container--slideout {
  position: fixed;
  top: 0;
  right: 0;
  width: 90vw;
  max-width: 560px;
  height: 100%;
  border-radius: 0;
  transform: translateX(100%);
  transition: transform 0.4s cubic-bezier(0.25, 1, 0.5, 1);
}

.page-overlay--visible .page-overlay__container--slideout {
  transform: translateX(0);
}

/* -------------------------------------------------------------------------
   Close button
   ------------------------------------------------------------------------- */

.page-overlay__close {
  position: sticky;
  top: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-left: auto;
  width: 44px;
  height: 44px;
  padding: 0;
  border: none;
  background: transparent;
  color: var(--page-overlay-close-color, #333);
  cursor: pointer;
  transition: opacity 0.2s ease;
}

.page-overlay__close:hover,
.page-overlay__close:focus-visible {
  opacity: 0.6;
}

.page-overlay__close:focus-visible {
  outline: 2px solid var(--page-overlay-focus-color, #4d90fe);
  outline-offset: 2px;
  border-radius: 4px;
}

/* -------------------------------------------------------------------------
   Content area
   ------------------------------------------------------------------------- */

.page-overlay__content {
  padding: 0;
}

/* Let Squarespace sections breathe inside the overlay */
.page-overlay__content .page-section {
  /* Reset any full-viewport constraints */
  min-height: auto !important;
}

/* -------------------------------------------------------------------------
   Loading state
   ------------------------------------------------------------------------- */

.page-overlay__loading {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 4rem 2rem;
}

.page-overlay__loading::after {
  content: '';
  width: 28px;
  height: 28px;
  border: 2px solid var(--page-overlay-loading-color, #ccc);
  border-top-color: var(--page-overlay-loading-accent, #333);
  border-radius: 50%;
  animation: page-overlay-spin 0.65s linear infinite;
}

@keyframes page-overlay-spin {
  to {
    transform: rotate(360deg);
  }
}

/* -------------------------------------------------------------------------
   Error state
   ------------------------------------------------------------------------- */

.page-overlay__error {
  padding: 3rem 2rem;
  text-align: center;
  color: var(--page-overlay-error-color, #888);
  font-size: 0.9rem;
}

/* -------------------------------------------------------------------------
   Focus styles for content inside the overlay
   ------------------------------------------------------------------------- */

.page-overlay__content a:focus-visible,
.page-overlay__content button:focus-visible,
.page-overlay__content input:focus-visible,
.page-overlay__content select:focus-visible,
.page-overlay__content textarea:focus-visible {
  outline: 2px solid var(--page-overlay-focus-color, #4d90fe);
  outline-offset: 2px;
}

/* -------------------------------------------------------------------------
   Responsive
   ------------------------------------------------------------------------- */

@media (max-width: 640px) {
  .page-overlay__container--popup {
    width: 95vw;
    max-height: 90vh;
    border-radius: 4px;
  }

  .page-overlay__container--slideout {
    width: 100vw;
    max-width: 100vw;
  }
}

/* -------------------------------------------------------------------------
   Reduced motion preference
   ------------------------------------------------------------------------- */

@media (prefers-reduced-motion: reduce) {
  .page-overlay,
  .page-overlay__container--popup,
  .page-overlay__container--slideout {
    transition-duration: 0.01ms !important;
  }

  .page-overlay__loading::after {
    animation-duration: 1.5s;
  }
}

/* -------------------------------------------------------------------------
   Custom properties reference — override these in Squarespace Custom CSS:
   
   :root {
     --page-overlay-bg: #ffffff;
     --page-overlay-color: #000000;
     --page-overlay-close-color: #333333;
     --page-overlay-focus-color: #4d90fe;
     --page-overlay-loading-color: #cccccc;
     --page-overlay-loading-accent: #333333;
     --page-overlay-error-color: #888888;
   }
   ------------------------------------------------------------------------- */


 #siteWrapper  .gallery-grid-item:not([data-show]) .gallery-grid-item-wrapper {
    opacity: 1;
}

.page-overlay__close {
    position: fixed;
    right: 1rem;
}

.page-overlay__container--slideout {
    max-width: 800px;
}