.detail-lightbox {
  box-sizing: border-box;
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  max-width: none;
  max-height: none;
  margin: 0;
  border: 0;
  padding: 76px 88px;
  background: rgba(2, 13, 20, .96);
  color: #fff;
  overscroll-behavior: contain;
}
.detail-lightbox[open] { display: grid; place-items: center; }
.detail-lightbox::backdrop { background: rgba(2, 13, 20, .92); }
.detail-lightbox figure {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  width: 100%;
  max-width: 1200px;
  min-width: 0;
  margin: 0;
}
.detail-lightbox img {
  display: block;
  width: auto;
  height: auto;
  max-width: 100%;
  max-height: calc(100vh - 200px);
  max-height: calc(100dvh - 200px);
  object-fit: contain;
  border-radius: 12px;
}
.detail-lightbox figcaption {
  margin: 0;
  max-width: 70ch;
  color: rgba(255, 255, 255, .85);
  font-size: .9rem;
  line-height: 1.4;
  text-align: center;
}
.detail-lightbox button {
  position: absolute;
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, .4);
  border-radius: 50%;
  background: #fff;
  color: var(--navy, #0b2b43);
  cursor: pointer;
  touch-action: manipulation;
}
.detail-lightbox button:hover { background: #d5ae76; }
.detail-lightbox button:focus-visible { outline: 3px solid #d5ae76; outline-offset: 5px; }
.detail-lightbox button[hidden] { display: none; }
.detail-lightbox button svg { width: 24px; height: 24px; }
.detail-lightbox-close { top: 18px; right: 22px; font-size: 1.75rem; line-height: 1; }
.detail-lightbox-prev, .detail-lightbox-next { top: 50%; transform: translateY(-50%); }
.detail-lightbox-prev { left: 20px; }
.detail-lightbox-next { right: 20px; }
.detail-lightbox-counter {
  position: absolute;
  bottom: 27px;
  left: 50%;
  transform: translateX(-50%);
  margin: 0;
  color: #fff;
  font-size: .95rem;
  font-variant-numeric: tabular-nums;
}
@media (max-width: 620px) {
  .detail-lightbox { padding: 76px 14px 92px; }
  .detail-lightbox img { max-height: calc(100vh - 240px); max-height: calc(100dvh - 240px); border-radius: 8px; }
  .detail-lightbox button { width: 48px; height: 48px; }
  .detail-lightbox-close { top: 14px; right: 14px; }
  .detail-lightbox-prev, .detail-lightbox-next { top: auto; bottom: max(20px, env(safe-area-inset-bottom)); transform: none; }
  .detail-lightbox-counter { bottom: max(32px, calc(env(safe-area-inset-bottom) + 12px)); }
  .detail-lightbox figcaption { font-size: .82rem; }
}
@media (max-height: 500px) {
  .detail-lightbox { padding-top: 18px; padding-bottom: 50px; }
  .detail-lightbox img { max-height: calc(100vh - 110px); max-height: calc(100dvh - 110px); }
  .detail-lightbox figcaption { font-size: .75rem; }
  .detail-lightbox-counter { bottom: 14px; }
}
