.gallery-viewer-trigger{margin-top:16px}
.gallery-viewer{width:min(1100px,calc(100% - 32px));max-height:calc(100dvh - 32px);padding:22px;border:1px solid var(--line,#d7e1e6);border-radius:14px;background:var(--white,#fff);color:var(--ink,#22343b);box-shadow:0 20px 80px #132c3b45;overscroll-behavior:contain;overflow:auto}
.gallery-viewer:not([open]){display:none}
.gallery-viewer::backdrop{background:#142934bd}
.gallery-viewer-header{display:flex;align-items:center;justify-content:space-between;gap:20px;margin-bottom:16px}
.gallery-viewer-title{font-size:22px;margin:0;line-height:1.35}
.gallery-viewer-close{flex-shrink:0}
.gallery-viewer-stage{position:relative;height:min(61dvh,670px);min-height:200px;background:#e9eff2;border-radius:8px;overflow:hidden;touch-action:pan-y pinch-zoom}
.gallery-viewer-image{display:block;width:100%;height:100%;object-fit:contain;-webkit-user-drag:none;user-select:none}
.gallery-viewer-image[hidden]{display:none}
.gallery-viewer-status{position:absolute;left:12px;right:12px;top:12px;width:fit-content;max-width:calc(100% - 24px);padding:5px 9px;border-radius:5px;background:#fffffff2;color:var(--ink,#22343b);font-size:12px;line-height:1.5;pointer-events:none}
.gallery-viewer-retry{position:absolute;left:50%;top:55%;transform:translate(-50%,-50%);background:var(--teal,#184d59);color:#fff;min-width:190px}
.gallery-viewer-navigation{display:flex;align-items:center;justify-content:space-between;gap:15px;margin-top:14px}
.gallery-viewer-counter{white-space:nowrap;font-size:14px;font-variant-numeric:tabular-nums}
.gallery-viewer-caption{margin-top:10px;font-size:14px;line-height:1.6}
.gallery-viewer-thumbnails{display:flex;gap:9px;overflow-x:auto;margin-top:16px;padding:4px 3px 10px;scrollbar-width:thin;overscroll-behavior:contain}
.gallery-viewer-thumbnail{flex-shrink:0;width:76px;height:94px;padding:2px;border:2px solid transparent;border-radius:7px;background:#edf3f5;overflow:hidden}
.gallery-viewer-thumbnail img{display:block;width:100%;height:100%;object-fit:contain}
.gallery-viewer-thumbnail[aria-current=true]{border-color:var(--teal,#184d59);background:#cee2eb}
.gallery-viewer-thumbnail:hover{border-color:#7e9fae}
.gallery-viewer button:focus-visible,.gallery-viewer-trigger:focus-visible{outline:3px solid #067ca1;outline-offset:3px}
@media(max-width:600px){.gallery-viewer{width:calc(100% - 16px);max-height:calc(100dvh - 16px);padding:15px;border-radius:10px}.gallery-viewer-header{gap:12px;margin-bottom:12px}.gallery-viewer-title{font-size:17px}.gallery-viewer-close{font-size:12px;padding-inline:12px}.gallery-viewer-stage{height:54dvh;min-height:200px}.gallery-viewer-navigation{gap:8px}.gallery-viewer-navigation .button{min-height:44px;font-size:12px;padding-inline:11px}.gallery-viewer-counter{font-size:12px}.gallery-viewer-caption{font-size:13px}.gallery-viewer-status{font-size:11px}.gallery-viewer-thumbnail{width:64px;height:78px}}
@media(prefers-reduced-motion:reduce){.gallery-viewer *{scroll-behavior:auto!important;transition:none!important}}
