.photoZoom {
  width:calc(100vw - 32px);
  height:calc(100vh - 32px);
  height:calc(100dvh - 32px);
  max-width:1440px;
  max-height:none;
  margin:auto;
  padding:0;
  overflow:hidden;
  border:1px solid rgba(255,255,255,.3);
  border-radius:18px;
  background:#0e1b30;
  color:#fff;
  box-shadow:0 20px 70px rgba(0,0,0,.5);
}
.photoZoom::backdrop {
  background:rgba(0,8,22,.85);
}
.photoZoomLayout {
  height:100%;
  display:grid;
  grid-template-rows:auto minmax(0,1fr) auto;
}
.photoZoomHead {
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  padding:6px 10px 6px 18px;
  font-size:18px;
  font-weight:700;
}
.photoZoomClose {
  flex:0 0 44px;
  width:44px;
  height:44px;
  border:1px solid rgba(255,255,255,.4);
  border-radius:50%;
  background:#f0f6ff;
  color:#173e6b;
  font:32px/1 sans-serif;
  cursor:pointer;
}
.photoZoomBody {
  min-height:0;
  padding:0;
  margin:0 10px;
  overflow:hidden;
  touch-action:none;
  cursor:grab;
  user-select:none;
}
.photoZoomImage {
  display:block;
  width:100%;
  height:100%;
  object-fit:contain;
  transform-origin:center;
  will-change:transform;
  pointer-events:none;
}
.photoZoomCaption {
  padding:10px 16px 14px;
  max-height:20vh;
  overflow:auto;
  text-align:center;
  white-space:pre-line;
  font-size:14px;
  line-height:1.5;
}
#photoImg, #photoCaption {
  cursor:zoom-in;
}
#photoImg:focus-visible, .photoZoomClose:focus-visible {
  outline:3px solid #ffe078;
  outline-offset:3px;
}
@media (max-width:700px) {
  .photoZoom {
    width:calc(100vw - 12px);
    height:calc(100vh - 12px);
    height:calc(100dvh - 12px);
    border-radius:12px;
  }
  .photoZoomCaption {font-size:12px;}
}

.photoZoomTools {display:flex;gap:4px;margin-left:auto;}
.photoZoomTools button {
  min-width:40px;height:40px;padding:4px 8px;
  border:1px solid rgba(255,255,255,.4);border-radius:8px;
  background:#193350;color:#fff;font:700 16px/1 system-ui;cursor:pointer;
}
.photoZoomTools button:disabled {opacity:.4;cursor:default;}
.photoZoomBody.is-zoomed:active {cursor:grabbing;}
.photoZoomTools button:focus-visible {outline:3px solid #ffe078;outline-offset:2px;}
