.av-photo-thumb{cursor:zoom-in}
#av-photo-viewer [hidden]{display:none!important}
#av-photo-viewer{width:min(1400px,calc(100% - 24px));max-width:calc(100% - 24px);max-height:94vh;max-height:94dvh;padding:16px;margin:auto;border:0;border-radius:12px;background:white;color:#173646;overflow:auto;box-sizing:border-box}
#av-photo-viewer::backdrop{background:#10212ee0}
#av-photo-viewer .av-photo-head{display:flex;align-items:center;gap:12px;flex-wrap:wrap;margin:0 0 10px}
#av-photo-viewer .av-photo-head button{font:600 14px/1.35 Arial,sans-serif;display:inline-flex;align-items:center;justify-content:center;min-height:44px;padding:10px 16px;border:1px solid #cadbe4;border-radius:8px;background:white;color:#315465;cursor:pointer}
#av-photo-viewer .av-photo-head .av-photo-action{background:#147b88;color:white;border-color:#147b88}
#av-photo-viewer .av-photo-meta{font:12px/1.4 Arial,sans-serif;color:#2c7954;background:#e4f5ec;border-radius:8px;padding:4px 8px}
#av-photo-viewer .av-photo-meta:empty,#av-photo-viewer .av-photo-error:empty{display:none}
#av-photo-viewer .av-photo-error{margin:4px 0 10px;color:#b44238;font:14px/1.4 Arial,sans-serif}
#av-photo-viewer .av-photo-stage{display:grid;grid-template-columns:44px minmax(0,1fr) 44px;align-items:center;gap:12px}
#av-photo-viewer .av-photo-nav{display:flex;align-items:center;justify-content:center;width:44px;height:60px;min-height:44px;padding:0;border:1px solid #cadbe4;border-radius:9px;background:#f2f7f8;color:#147b88;font-size:27px;cursor:pointer}
#av-photo-viewer button:disabled{opacity:.4;cursor:default}
#av-photo-viewer button:focus-visible{outline:2px solid #147b88;outline-offset:2px}
#av-photo-viewer .av-photo-full{display:flex;align-items:center;justify-content:center;min-width:0;min-height:0;padding:0;border:0;background:transparent;cursor:zoom-out;max-width:100%}
#av-photo-viewer .av-photo-full img{display:block;max-width:100%;max-height:calc(94vh - 115px);max-height:calc(94dvh - 115px);width:auto;height:auto;object-fit:contain;margin:0}
@media(max-width:700px){#av-photo-viewer{padding:10px;width:calc(100% - 12px);max-width:calc(100% - 12px)}#av-photo-viewer .av-photo-head{font-size:12px;gap:8px}#av-photo-viewer .av-photo-head button{font-size:12px;padding:8px 10px}#av-photo-viewer .av-photo-stage{grid-template-columns:36px minmax(0,1fr) 36px;gap:4px}#av-photo-viewer .av-photo-nav{width:36px;height:52px;font-size:23px}}

/* Full viewport and a scrollable image instead of reserving side columns. */
#av-photo-viewer{height:94vh;height:94dvh;overflow:hidden}
#av-photo-viewer[open]{display:flex;flex-direction:column}
#av-photo-viewer .av-photo-head{flex-shrink:0}
#av-photo-viewer .av-photo-tools{display:flex;align-items:center;gap:8px;flex-wrap:wrap;flex-shrink:0}
#av-photo-viewer .av-photo-tools button,#av-photo-viewer .av-photo-tools a{display:inline-flex;align-items:center;justify-content:center;box-sizing:border-box;min-width:44px;min-height:44px;padding:8px 12px;border:1px solid #cadbe4;border-radius:8px;background:white;color:#315465;font:600 14px/1.35 Arial,sans-serif;text-decoration:none;cursor:pointer}
#av-photo-viewer .av-photo-tools span{min-width:32px;text-align:center;font:14px Arial,sans-serif}
#av-photo-viewer .av-photo-help{flex-shrink:0;margin:6px 0;font:12px/1.3 Arial,sans-serif;color:#526d78}
#av-photo-viewer .av-photo-stage{display:block;position:relative;flex:1;min-height:0;min-width:0;overflow:hidden}
#av-photo-viewer .av-photo-viewport{position:absolute;inset:0;overflow:auto;overscroll-behavior:contain;touch-action:none}
#av-photo-viewer .av-photo-full{display:block;max-width:none;margin-left:auto;margin-right:auto;box-sizing:content-box;line-height:0}
#av-photo-viewer .av-photo-full img{max-width:none;max-height:none;object-fit:fill}
#av-photo-viewer .is-zoomed .av-photo-full{cursor:grab}
#av-photo-viewer .is-zoomed .av-photo-full:active{cursor:grabbing}
#av-photo-viewer .av-photo-nav{position:absolute;z-index:2;top:50%;transform:translateY(-50%);opacity:.85}
#av-photo-viewer .av-photo-nav:first-of-type{left:0}
#av-photo-viewer .av-photo-nav:last-of-type{right:0}
@media(max-width:700px){#av-photo-viewer{width:100%;max-width:100%;height:100vh;height:100dvh;max-height:100vh;max-height:100dvh;border-radius:0;padding:10px}#av-photo-viewer .av-photo-head{margin-bottom:6px}#av-photo-viewer .av-photo-tools{gap:6px}}
