html { scroll-behavior: smooth; }
a:focus-visible, button:focus-visible { outline: 3px solid #087eaf; outline-offset: 4px; }
.document-viewer { position: fixed; inset: 0; width: 100vw; height: 100dvh; max-width: none; max-height: none; margin: 0; padding: 64px 60px 48px; border: 0; background: #14191ef5; color: white; overflow: hidden; }
.document-viewer::backdrop { background: #14191e; }
.document-viewer[open] { display: grid; grid-template-rows: minmax(0,1fr) auto; gap: 16px; }
.document-toolbar { position: absolute; top: 8px; left: 20px; right: 16px; height: 44px; display: flex; align-items: center; gap: 20px; }
.document-counter { margin-right: auto; }
.document-viewer button { color: white; background: transparent; border: 0; cursor: pointer; min-width: 44px; min-height: 44px; font: inherit; font-size: 32px; border-radius: 8px; padding: 0; }
.document-viewer button:hover { background: #ffffff26; }
.document-original { color: white; font-size: 15px; text-underline-offset: 4px; }
.document-stage { min-height: 0; overflow: auto; display: flex; align-items: center; justify-content: center; }
.document-full { display: block; width: auto; height: auto; max-width: 100%; max-height: 100%; object-fit: contain; }
.document-viewer.is-zoomed .document-stage { display: block; }
.document-viewer.is-zoomed .document-full { max-width: none; max-height: none; width: max(100%, 1100px); margin: 0 auto; }
.previous-document, .next-document { position: absolute; top: calc(50% - 22px); }
.previous-document { left: 4px; }
.next-document { right: 4px; }
.document-caption { text-align: center; font-size: 16px; line-height: 1.4; }
body:has(.document-viewer[open]) { overflow: hidden; }
@media (max-width: 767px) {
 .document-viewer { padding: 64px 42px 24px; }
 .document-toolbar { gap: 8px; left: 12px; right: 8px; }
 .document-original { font-size: 13px; }
 .document-caption { font-size: 14px; }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
