
body.evidence-image-open{overflow:hidden!important}
.reader-content img[role="button"]:focus-visible{outline:2px solid #27675f;outline-offset:4px}
dialog.evidence-image-viewer{position:fixed;inset:0;width:100%;height:100%;max-width:none;max-height:none;margin:0;padding:0;border:0;background:transparent;color:#243b3a;overflow:hidden}
dialog.evidence-image-viewer::backdrop{background:rgba(225,229,232,.10);backdrop-filter:blur(5px);-webkit-backdrop-filter:blur(5px)}
.evidence-image-viewer .eiv-toolbar{position:absolute;inset:0 0 auto;min-height:64px;box-sizing:border-box;display:flex;align-items:center;justify-content:space-between;gap:16px;padding:10px 24px;background:rgba(250,251,252,.91);border-bottom:1px solid rgba(80,100,100,.13);z-index:2;font:500 15px/1.4 system-ui,sans-serif}
.evidence-image-viewer .eiv-controls{display:flex;align-items:center;gap:8px}
.evidence-image-viewer button{float:none;margin:0;min-width:40px;min-height:40px;padding:6px 12px;border:1px solid #bdc9ca;border-radius:5px;background:rgba(255,255,255,.94);color:#243b3a;font:500 15px/1.4 system-ui,sans-serif;cursor:pointer}
.evidence-image-viewer button:hover{background:#e6efec;border-color:#78998e}
.evidence-image-viewer button:disabled{opacity:.4;cursor:default}
.evidence-image-viewer button:focus-visible{outline:2px solid #27675f;outline-offset:2px}
.evidence-image-viewer [data-action="close"]{font-size:26px;line-height:24px;margin-left:8px}
.evidence-image-viewer .eiv-scale{min-width:46px;text-align:center;font-variant-numeric:tabular-nums}
.evidence-image-viewer .eiv-stage{position:absolute;inset:64px 0 48px;overflow:hidden;touch-action:none;cursor:grab;user-select:none}
.evidence-image-viewer .eiv-stage.is-dragging{cursor:grabbing}
dialog.evidence-image-viewer img.eiv-image{display:block;position:absolute;left:50%;top:50%;max-width:none;max-height:none;margin:0;padding:0;object-fit:contain;transform-origin:50% 50%;box-shadow:0 6px 30px rgba(35,50,55,.17);background:transparent;user-select:none;-webkit-user-drag:none}
.evidence-image-viewer .eiv-footer{position:absolute;inset:auto 0 0;min-height:48px;display:flex;align-items:center;justify-content:center;gap:14px;box-sizing:border-box;padding:8px 16px;background:rgba(250,251,252,.9);font:14px/1.5 system-ui,sans-serif;z-index:2}
.evidence-image-viewer .eiv-status{color:#415b59}
.evidence-image-viewer.is-loading .eiv-status::before{content:'';display:inline-block;vertical-align:-2px;width:12px;height:12px;border:2px solid #c5cfce;border-top-color:#376d60;border-radius:50%;margin-right:7px;animation:eiv-spin .8s linear infinite}
.evidence-image-viewer [hidden]{display:none!important}
@keyframes eiv-spin{to{transform:rotate(360deg)}}
@media(max-width:600px){.evidence-image-viewer .eiv-toolbar{padding:8px 10px;gap:6px}.evidence-image-viewer .eiv-title{display:none}.evidence-image-viewer .eiv-controls{width:100%;justify-content:center;gap:6px}.evidence-image-viewer .eiv-footer{font-size:12px;gap:6px;flex-wrap:wrap}.evidence-image-viewer .eiv-hint{display:none}.evidence-image-viewer .eiv-stage{bottom:40px}}
@media(prefers-reduced-motion:reduce){.evidence-image-viewer.is-loading .eiv-status::before{animation:none}}
@media print{dialog.evidence-image-viewer{display:none!important}}

/* Reserve the figure box before its lazy preview arrives. */
.reader-content figure>img[data-full-width]{width:min(100%,var(--evidence-image-width));}
