/* Reusable lightbox (gwt-lightbox-gallery) — no hardcoded images; styling only */

.gwt-lb {
  position: fixed;
  inset: 0;
  z-index: 10050;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: env(safe-area-inset-top) env(safe-area-inset-right) env(safe-area-inset-bottom) env(safe-area-inset-left);
  box-sizing: border-box;
}

.gwt-lb[hidden] {
  display: none !important;
}

.gwt-lb__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(5, 5, 6, 0.94);
  cursor: grab;
}

.gwt-lb__panel {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  width: min(100vw - 1.5rem, 1200px);
  max-height: min(100vh - 1.5rem, 100dvh);
  outline: none;
}

.gwt-lb__close {
  position: absolute;
  top: 0.25rem;
  right: 0.25rem;
  z-index: 3;
  width: 2.75rem;
  height: 2.75rem;
  border: none;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  font-size: 1.75rem;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s ease, transform 0.12s ease;
}

.gwt-lb__close:hover,
.gwt-lb__close:focus-visible {
  background: rgba(255, 255, 255, 0.2);
  outline: 2px solid rgba(255, 255, 255, 0.5);
  outline-offset: 2px;
}

.gwt-lb__main {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.25rem;
  flex: 1 1 auto;
  min-height: 0;
  padding: 2.75rem 0.5rem 0.5rem;
  touch-action: pan-y;
}

@media (min-width: 768px) {
  .gwt-lb__main {
    padding: 2.5rem 0.75rem 0.75rem;
    gap: 0.5rem;
  }
}

.gwt-lb__stage {
  flex: 1 1 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 0;
  max-height: min(70vh, 70dvh);
  overflow: hidden;
  border-radius: 6px;
  background: rgba(0, 0, 0, 0.35);
}

@media (min-width: 768px) {
  .gwt-lb__stage:hover .gwt-lb__img {
    transform: scale(1.02);
  }
}

.gwt-lb__img {
  max-width: 100%;
  max-height: min(70vh, 70dvh);
  width: auto;
  height: auto;
  object-fit: contain;
  display: block;
  margin: 0 auto;
  transition: opacity 0.22s ease, transform 0.35s ease;
  user-select: none;
  -webkit-user-drag: none;
}

.gwt-lb__img.is-fading {
  opacity: 0;
}

.gwt-lb__nav {
  flex: 0 0 auto;
  width: 2.5rem;
  height: 2.5rem;
  border: none;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.15s ease, opacity 0.15s ease;
}

@media (min-width: 768px) {
  .gwt-lb__nav {
    width: 3rem;
    height: 3rem;
    font-size: 1.75rem;
  }
}

.gwt-lb__nav:hover:not(:disabled),
.gwt-lb__nav:focus-visible:not(:disabled) {
  background: rgba(255, 255, 255, 0.2);
  outline: 2px solid rgba(255, 255, 255, 0.45);
  outline-offset: 2px;
}

.gwt-lb__nav:disabled {
  opacity: 0.25;
  cursor: not-allowed;
}

.gwt-lb__thumbs-wrap {
  flex: 0 0 auto;
  max-width: 100%;
  padding: 0.5rem 0 0.25rem;
}

.gwt-lb__thumbs {
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  gap: 0.5rem;
  overflow-x: auto;
  overflow-y: hidden;
  padding: 0.35rem 0.15rem 0.5rem;
  -webkit-overflow-scrolling: touch;
  scroll-behavior: smooth;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.35) transparent;
}

.gwt-lb__thumbs::-webkit-scrollbar {
  height: 6px;
}

.gwt-lb__thumbs::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.3);
  border-radius: 3px;
}

.gwt-lb__thumb {
  flex: 0 0 auto;
  width: 4.5rem;
  height: 3.2rem;
  border: 2px solid transparent;
  border-radius: 6px;
  padding: 0;
  overflow: hidden;
  cursor: pointer;
  background: #111;
  transition: border-color 0.15s ease, transform 0.12s ease, opacity 0.15s ease;
  opacity: 0.75;
}

@media (min-width: 768px) {
  .gwt-lb__thumb {
    width: 5.5rem;
    height: 3.6rem;
  }
}

.gwt-lb__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  pointer-events: none;
}

.gwt-lb__thumb:hover,
.gwt-lb__thumb:focus-visible {
  opacity: 1;
  outline: none;
}

.gwt-lb__thumb.is-active {
  border-color: #c8e86c;
  opacity: 1;
  box-shadow: 0 0 0 1px rgba(200, 232, 108, 0.5);
}

body.gwt-lb--open {
  overflow: hidden;
  touch-action: none;
}

body.gwt-lb--open .gwt-lb__backdrop {
  cursor: default;
}

@media (max-width: 480px) {
  .gwt-lb__nav--prev,
  .gwt-lb__nav--next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 2;
  }

  .gwt-lb__nav--prev {
    left: 0.25rem;
  }

  .gwt-lb__nav--next {
    right: 0.25rem;
  }

  .gwt-lb__main {
    padding-left: 0.15rem;
    padding-right: 0.15rem;
  }
}
