/* =================================================
 * OVERRIDE GLIGHTBOX INLINE STYLES
 * ================================================= */

/* Core media wrapper */
.glightbox-container .mbl-gallery .gslide-media {
  width: 100vw !important;
  max-width: 100vw !important;
  height: 100vh !important;
  max-height: calc(100vh - 48px) !important;
  margin: 0 auto !important;
  padding: 48px 0 0 !important;
  display: flex !important;
  justify-content: center !important;
  align-items: flex-start !important;
  overflow: hidden;
}

/* Inner wrappers GLightbox injects */
.glightbox-container .ginner-container,
.glightbox-container .ginner-content {
  width: 100% !important;
  max-width: 100% !important;
  height: auto !important;
  max-height: none !important;

  display: flex !important;
  justify-content: center !important;
  align-items: flex-start !important;

  padding: 0 !important;
  margin: 0 !important;
  transform: none !important;
}

/* Prevent GLightbox from centering via inline translate */
.glightbox-container .gslide {
  transform: none !important;
}

/* =================================================
 * SLIDE LAYOUT (FIXED WIDTH, CENTERED)
 * ================================================= */

.mlb-slide {
  gap: 48px;
  width: 100% !important;
  max-width: 100% !important;
  height: 100% !important;
  justify-content: center;
  align-items: flex-start;
  overflow-y: auto !important;
  overflow-x: hidden !important;
}

.mlb-slide-inner {
  display: flex !important;
  gap: 48px;
  width: 100% !important; 
  max-width: 100% !important;
  justify-content: center;
  align-items: flex-start;
  padding-bottom: 4.8rem;
  flex-wrap: wrap;
}

/* Desktop image */
.desktop-image {
  width: 720px;
  max-width: 720px !important;
  height: auto;
  flex: 0 0 720px;
}

/* Mobile image */
.mobile-image {
  width: 250px;
  max-width: 250px !important;
  height: auto;
  flex: 0 0 250px;
}

/* Images: natural rendering */
.mlb-slide img {
  display: block;
  width: auto;
  height: auto;
  max-width: none;
  max-height: none;
  object-fit: unset;
}

 @media (min-width: 720px) {
  .mlb-slide .hide-desktop {
    display: none;
  }
 }

/* =================================================
 * MOBILE VIEW
 * ================================================= */
@media (max-width: 719px) {
  .mlb-slide {
    width: 100%;
    max-width: 100%;
    flex-direction: column;
    gap: 24px;
  }

  .mlb-slide .hide-mobile {
    display: none;
  }

  .mlb-img-mobile {
    width: 100%;
    flex: 0 0 auto;
  }
  .mlb-slide-inner {
    gap: 2.4rem;
    flex-wrap: wrap;
  }
}

.gslide-inline .ginlined-content {
  padding: 0;
  overflow: unset;
}

.gslide-inline {
  background-color: #F0F0F0;
}

.mlb-group-nav {
  position: relative;
  z-index: 99999;  
  display: none;
}

/* Hide default GLightbox close button */
.glightbox-container .gclose, .glightbox-clean .gnext, .glightbox-clean .gprev {
  display: none !important;
}

/* =================================================
 * Gallery Title Bar with Close Button
 * ================================================= */

.mlb-gallery-title {
  position: sticky;
  top: 0;
  z-index: 1003;

  display: flex;
  align-items: center;
  justify-content: space-between;

  padding: 1.6rem 2.4rem;
  background: #F0F0F0;
  border-bottom: 1px solid #D7D7D7;
  font-weight: 700;
}

.mlb-gallery-title-text {
  font-size: 16px;
  font-weight: 600;
}

/* Custom close button */
.mlb-gallery-close {
  border: none;
  padding: 1rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

.mlb-gallery-close:hover {
  opacity: 0.7;
}



/* =================================================
 * Bottom Arrow Navigation
 * ================================================= */

.mlb-bottom-nav {
  position: fixed;
  left: 50%;
  bottom: 2.4rem;
  transform: translateX(-50%);
  z-index: 1001;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 1.2rem 1.6rem;
  background: #000;
  color: #fff;
  z-index: 9999;
  min-width: 22.2rem;
  border-radius: 0.4rem;
  backdrop-filter: blur(2px);
}

/* Title */
.mlb-nav-title {
  font-size: 14px;
  font-weight: 500;
  white-space: nowrap;
}

/* Arrows */
.mlb-bottom-nav button {
  background: none;
  border: none;
  color: inherit;
  font-size: 18px;
  cursor: pointer;
  padding: 4px 8px;
}

/* Disabled state */
.mlb-bottom-nav button:disabled {
  opacity: 0.3;
  cursor: default;
}

.mlb-bottom-nav button:hover {
  opacity: 0.6; 
  background: none;
}


/* =================================================
 * Modal Loader
 * ================================================= */

.mlb-loader {
  position: fixed;
  inset: 0;
  z-index: 1002;
  background: rgba(0, 0, 0, 0.35);

  display: flex;
  align-items: center;
  justify-content: center;

  pointer-events: none; /* allow nav clicks if needed */
}

/* Spinner */
.mlb-spinner {
  width: 42px;
  height: 42px;
  border: 3px solid rgba(255, 255, 255, 0.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: mlb-spin 0.9s linear infinite;
}

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


.mlb-initial-loader {
  width: 100vw;
  height: 100vh;

  display: flex;
  align-items: center;
  justify-content: center;
}

.mlb-spinner {
  width: 42px;
  height: 42px;
  border: 3px solid rgba(255,255,255,0.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: mlb-spin 0.9s linear infinite;
}

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