.live-zoom {
  box-sizing: border-box;
  position: fixed;
  inset: 0;
  margin: auto;
  width: min(1560px, calc(100% - 32px));
  height: calc(100vh - 32px);
  height: calc(100dvh - 32px);
  max-width: none;
  max-height: none;
  padding: 0;
  overflow: hidden;
  overscroll-behavior: contain;
  border: 1px solid #b8cad8;
  border-radius: 8px;
  background: white;
  color: #163756;
  font-family: var(--font-ui, Inter, Arial, sans-serif);
}
.live-zoom[open] { display: grid; grid-template-rows: auto minmax(0, 1fr) auto; }
.live-zoom::backdrop { background: rgb(7 22 35 / .87); }
.live-zoom-header, .live-zoom-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 8px 16px;
}
.live-zoom-title { margin: 0; font: 650 1.05rem/1.3 var(--font-ui, Inter, Arial, sans-serif); overflow-wrap: anywhere; }
.live-zoom-footer { color: #163756; background: #fff; }
.live-zoom-stage {
  position: relative;
  overflow: hidden;
  isolation: isolate;
  min-width: 0;
  min-height: 0;
  touch-action: none;
  user-select: none;
  background: #142633;
}
.live-zoom-stage.can-pan { cursor: grab; }
.live-zoom-stage.can-pan.dragging { cursor: grabbing; }
.live-zoom .live-zoom-photo {
  display: block;
  position: absolute;
  left: 50%;
  top: 50%;
  width: 0;
  height: 0;
  max-width: none;
  max-height: none;
  pointer-events: none;
}
.live-zoom-message {
  position: absolute;
  inset: 50% auto auto 50%;
  transform: translate(-50%, -50%);
  width: max-content;
  max-width: 90%;
  text-align: center;
  color: white;
}
.live-zoom-message[hidden] { display: none; }
.live-zoom-help { margin: 0; color: #465967; font-size: .85rem; line-height: 1.4; }
.live-zoom-controls { display: flex; align-items: center; gap: 6px; flex: none; }
.live-zoom-button {
  box-sizing: border-box;
  min-width: 42px;
  height: 42px;
  padding: 0 9px;
  border: 1px solid #c8d6e1;
  border-radius: 4px;
  background: white;
  color: #163756;
  font: 600 1.25rem/1 var(--font-ui, Inter, Arial, sans-serif);
  cursor: pointer;
}
.live-zoom-button:hover:enabled { background: #edf4f8; border-color: #517594; }
.live-zoom-button:disabled { color: #708190; background: #f4f6f7; cursor: default; }
.live-zoom-button:focus-visible { outline: 3px solid #2375aa; outline-offset: 2px; }
.live-zoom-stage:focus-visible { outline: 2px solid #87c2de; outline-offset: -3px; }
.live-zoom-close { flex: none; font-size: 1.55rem; }
.live-zoom-fit { font-size: .85rem; }
.live-zoom-percent { min-width: 4ch; text-align: center; font-size: .84rem; font-variant-numeric: tabular-nums; }
@media (max-width: 640px), (max-height: 480px) {
  .live-zoom { width: 100%; height: 100vh; height: 100dvh; border: 0; border-radius: 0; }
  .live-zoom-header, .live-zoom-footer { padding: 6px 10px; gap: 8px; }
  .live-zoom-footer { padding-bottom: max(6px, env(safe-area-inset-bottom)); }
}
@media (max-width: 480px) and (min-height: 481px) {
  .live-zoom-footer { flex-direction: column-reverse; gap: 3px; }
  .live-zoom-help { font-size: .76rem; text-align: center; }
}
