.image-viewer-trigger { cursor: zoom-in; }
.image-viewer:not([open]) { display: none; }
html:has(.image-viewer[open]) { overflow: hidden; }

.image-viewer {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  max-width: none;
  max-height: none;
  margin: 0;
  padding: 72px clamp(12px, 3vw, 48px) 24px;
  border: 0;
  background: #151515;
  color: #fff;
}
.image-viewer[open] {
  display: grid;
  grid-template: minmax(0, 1fr) / minmax(0, 1fr);
  place-items: center;
}
.image-viewer img {
  width: 100%;
  height: 100%;
  min-width: 0;
  min-height: 0;
  object-fit: contain;
}
.image-viewer-close {
  position: absolute;
  top: 14px;
  right: clamp(12px, 3vw, 48px);
  min-height: 44px;
  padding: 0 16px;
  border: 1px solid #999;
  border-radius: 4px;
  background: #252525;
  color: inherit;
  cursor: pointer;
}
.image-viewer-close:hover { background: #3a3a3a; }
.image-viewer-close:focus-visible { outline-color: #fff; }
