.gallery-trigger { display: inline-block; text-decoration: underline; text-underline-offset: .2em; }
.work > .gallery-trigger { margin-top: 12px; }
.image-gallery { width: min(1100px, calc(100% - 24px)); max-width: calc(100% - 24px); max-height: calc(100dvh - 24px); padding: 20px; border: 1px solid #8d8170; background: var(--paper, #faf7f0); color: var(--ink, #172638); overflow: auto; overscroll-behavior: contain; }
.image-gallery::backdrop { background: rgb(0 0 0 / 80%); }
.image-gallery .gallery-toolbar { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 12px; }
.image-gallery button { min-height: 44px; padding: 8px 12px; background: var(--paper, #faf7f0); color: inherit; border: 1px solid currentColor; cursor: pointer; }
.image-gallery button:disabled { opacity: .5; cursor: default; }
.image-gallery img { width: 100%; height: auto; max-height: 65dvh; object-fit: contain; }
.image-gallery figcaption, .image-gallery p { color: inherit; font-size: 1rem; overflow-wrap: anywhere; }
.image-gallery a { display: inline-block; padding-block: 8px; text-decoration: underline; }
@media (max-width: 500px) { .image-gallery { padding: 12px; } }
