.article-gallery { margin-block: 2rem; clear: both; }
.article-gallery [hidden] { display: none !important; }
.article-gallery-stage { position: relative; }
.article-gallery-ready .article-gallery-stage { aspect-ratio: 3 / 2; overflow: hidden; touch-action: pan-y pinch-zoom; background: #101817; }
.article-gallery .article-gallery-slide { margin: 0; }
.article-gallery-ready .article-gallery-slide,
.article-gallery-ready .article-gallery-slide a { display: block; height: 100%; }
.article-gallery .article-gallery-slide img { display: block; width: 100%; margin: 0; }
.article-gallery-ready .article-gallery-slide img { height: 100%; object-fit: cover; border-radius: 0; }
.article-gallery-ready .article-gallery-slide figcaption { display: none; }
.article-gallery .article-gallery-caption { margin: 8px 0 0; color: var(--color-muted, #596663); font-size: .85rem; line-height: 1.5; }
.article-gallery-count, .article-gallery-control {
  position: absolute;
  z-index: 1;
  color: #fff;
  background: rgb(0 0 0 / 68%);
  border: 0;
}
.article-gallery .article-gallery-count { margin: 0; inset: 10px auto auto 10px; padding: 5px 9px; border-radius: 5px; font-size: .8rem; }
.article-gallery-control { display: grid; place-items: center; width: 44px; height: 44px; font: inherit; font-size: 28px; line-height: 1; border-radius: 50%; cursor: pointer; }
.article-gallery-control:hover { background: #000; }
.article-gallery-control:focus-visible, .article-gallery-slide a:focus-visible { outline: 2px solid white; outline-offset: -3px; }
.article-gallery-control[data-gallery-action="prev"] { left: 10px; top: 50%; transform: translateY(-50%); }
.article-gallery-control[data-gallery-action="next"] { right: 10px; top: 50%; transform: translateY(-50%); }
.article-gallery-control[data-gallery-action="open"],
.article-gallery-control[data-gallery-action="close"] { right: 10px; top: 10px; border-radius: 6px; }
.article-gallery-dialog {
  box-sizing: border-box;
  position: fixed;
  inset: 0;
  width: 100%;
  max-width: none;
  height: 100%;
  max-height: none;
  margin: 0;
  padding: 56px clamp(48px, 6vw, 88px) 24px;
  border: 0;
  background: #101817;
  touch-action: pan-y pinch-zoom;
  color: #fff;
}
.article-gallery-dialog[open] { display: grid; place-items: center; }
.article-gallery-dialog::backdrop { background: #101817; }
.article-gallery .article-gallery-dialog figure { margin: 0; min-width: 0; max-width: 100%; text-align: center; }
.article-gallery .article-gallery-dialog img { display: block; max-width: 100%; max-height: 78dvh; margin: auto; object-fit: contain; }
.article-gallery .article-gallery-dialog figcaption { margin-top: 8px; color: #fff; font-size: .9rem; }
