/* Opt-in native gallery: square previews with complete originals available on request. */
.wp-block-gallery.has-nested-images.is-style-bm-carousel { display:flex; flex-wrap:nowrap; gap:0; overflow-x:auto; scroll-snap-type:x mandatory; max-width:480px; margin-inline:auto; }
.wp-block-gallery.has-nested-images.is-style-bm-carousel > figure.wp-block-image { flex:0 0 100%; width:100% !important; margin:0; scroll-snap-align:start; display:flex; flex-direction:column; align-self:flex-start; }
.wp-block-gallery.has-nested-images.is-style-bm-carousel > figure.wp-block-image > a { display:block; width:100%; }
.wp-block-gallery.has-nested-images.is-style-bm-carousel > figure.wp-block-image img { width:100%; height:auto !important; aspect-ratio:1; object-fit:cover !important; background:#080808; flex:none; }
.wp-block-gallery.has-nested-images.is-style-bm-carousel > figure.wp-block-image figcaption { position:static; width:100%; box-sizing:border-box; max-height:none; margin:0; padding:12px; background:#080808; color:#fff; font-size:14px; }
.bm-carousel { margin-block:28px; }
.bm-carousel-controls { display:flex; align-items:center; justify-content:center; gap:18px; margin-top:10px; }
.bm-carousel-controls[hidden] { display:none; }
#bandmonkey-feed-and-pages .bm-carousel-controls button { min-width:44px; min-height:44px; padding:8px; background:var(--bm-ink); border:1px solid var(--bm-line); color:var(--bm-green); }
#bandmonkey-feed-and-pages .bm-carousel-controls button:disabled { opacity:.35; }
#bandmonkey-feed-and-pages .bm-post-actions { margin-block:24px; }
#bandmonkey-feed-and-pages .bm-post-social > span { color:var(--bm-muted); font-size:13px; }
#bandmonkey-feed-and-pages .bm-post-social > div, #bandmonkey-feed-and-pages .bm-share { display:flex; align-items:center; flex-wrap:wrap; gap:12px; margin-top:12px; }
#bandmonkey-feed-and-pages .bm-post-social a, #bandmonkey-feed-and-pages .bm-share button { display:inline-flex; gap:8px; align-items:center; min-height:44px; padding:8px 12px; border:1px solid var(--bm-line); background:var(--bm-ink); color:var(--bm-green); font-size:14px; text-decoration:none; }
#bandmonkey-feed-and-pages .bm-share button[hidden], #bandmonkey-feed-and-pages .bm-share input[hidden] { display:none; }
#bandmonkey-feed-and-pages .bm-share input { width:100%; }
#bandmonkey-feed-and-pages .bm-share [role=status] { font-size:13px; }

/* Image buttons preserve square geometry before their deferred source loads. */
#bandmonkey-feed-and-pages .bm-photo-expand { display:block; width:100%; aspect-ratio:1; padding:0; border:0; background:#080808; cursor:zoom-in; overflow:hidden; }
#bandmonkey-feed-and-pages .bm-photo-expand img { display:block; height:100% !important; }
#bandmonkey-feed-and-pages .bm-photo-expand:focus-visible { outline:2px solid var(--bm-green); outline-offset:-3px; }
/* Use a native modal for keyboard focus containment, Escape, and uncropped originals. */
.bm-photo-dialog { box-sizing:border-box; max-width:96vw; max-height:94dvh; width:max-content; padding:48px 12px 12px; border:1px solid #333; background:#080808; color:#fff; }
.bm-photo-dialog::backdrop { background:rgba(0,0,0,.9); }
.bm-photo-dialog img { display:block; width:auto; height:auto; max-width:calc(96vw - 26px); max-height:calc(94dvh - 62px); object-fit:contain; }
.bm-photo-dialog button { position:absolute; top:4px; right:8px; width:40px; min-height:40px; padding:0; background:transparent; border:0; color:#aaa; font:400 24px/1 Inter,Arial,sans-serif; cursor:pointer; }
/* Keep pointer focus quiet while preserving a clear keyboard focus indicator. */
.bm-photo-dialog button:is(:hover,:focus) { background:transparent; color:#fff; }
.bm-photo-dialog button:focus:not(:focus-visible) { outline:none; }
.bm-photo-dialog button:focus-visible { outline:2px solid #39ed72; }
body.bm-photo-open { overflow:hidden; }
/* Quiet inline sharing controls sit below the gallery without large button boxes. */
#bandmonkey-feed-and-pages .bm-share { gap:16px; }
#bandmonkey-feed-and-pages .bm-share button { gap:5px; min-height:32px; padding:3px 0; border:0; background:transparent; color:var(--bm-muted); font:600 11px/1.4 Inter,Arial,sans-serif; cursor:pointer; }
#bandmonkey-feed-and-pages .bm-share button svg { color:var(--bm-green); width:14px; height:14px; flex:none; }
#bandmonkey-feed-and-pages .bm-share button:hover { color:var(--bm-green); }
#bandmonkey-feed-and-pages .bm-share button:focus-visible { outline:2px solid var(--bm-green); outline-offset:3px; }
#bandmonkey-feed-and-pages .bm-share [role=status] { font-size:11px; }

/* Wider screens show a strip of square photos while mobile keeps one swipeable frame. */
.wp-block-gallery.has-nested-images.is-style-bm-carousel { --bm-visible:1; --bm-photo-gap:0px; max-width:100%; gap:var(--bm-photo-gap); }
.wp-block-gallery.has-nested-images.is-style-bm-carousel > figure.wp-block-image { flex-basis:calc((100% - (var(--bm-visible) - 1)*var(--bm-photo-gap))/var(--bm-visible)); width:calc((100% - (var(--bm-visible) - 1)*var(--bm-photo-gap))/var(--bm-visible)) !important; }
@media (min-width:700px) { .wp-block-gallery.has-nested-images.is-style-bm-carousel { --bm-visible:2; --bm-photo-gap:12px; } }
@media (min-width:1000px) { .wp-block-gallery.has-nested-images.is-style-bm-carousel { --bm-visible:3; } }
/* A shared divider anchors topics and sharing to the end of the article. */
#bandmonkey-feed-and-pages .bm-story-footer { display:flex; flex-wrap:wrap; align-items:center; justify-content:space-between; gap:16px 24px; max-width:720px; margin:28px auto 0; padding:16px 0; border-top:1px solid var(--bm-line); }
#bandmonkey-feed-and-pages .bm-story-footer .bm-story-topics { margin:0; }
#bandmonkey-feed-and-pages .bm-story-footer .bm-post-actions { margin:0; }
#bandmonkey-feed-and-pages .bm-story-footer .bm-share { margin:0; }
#bandmonkey-feed-and-pages .bm-story-footer .bm-post-social { margin-bottom:8px; }


/* Mobile dots replace the counter row; larger screens keep arrows beside the photos. */
.bm-carousel { position:relative; }
.bm-carousel-controls > [role="status"] { position:absolute; width:1px; height:1px; padding:0; overflow:hidden; clip-path:inset(50%); white-space:nowrap; }
.bm-carousel-dots { display:flex; justify-content:center; gap:2px; }
#bandmonkey-feed-and-pages .bm-carousel-dots button { display:grid; place-items:center; min-width:28px; min-height:28px; padding:0; border:0; background:transparent; }
#bandmonkey-feed-and-pages .bm-carousel-dots button::before { content:""; width:6px; height:6px; border-radius:50%; background:var(--bm-muted); opacity:.5; }
#bandmonkey-feed-and-pages .bm-carousel-dots button[aria-current="true"]::before { background:var(--bm-green); opacity:1; }
#bandmonkey-feed-and-pages .bm-carousel-controls button:focus-visible { outline:2px solid var(--bm-green); outline-offset:2px; }
@media (max-width:699px) {
  #bandmonkey-feed-and-pages .bm-carousel-controls > [data-direction] { display:none; }
  .bm-carousel-controls { margin-top:6px; }
}
@media (min-width:700px) {
  .bm-carousel-controls { margin:0; }
  .bm-carousel-dots { display:none; }
  #bandmonkey-feed-and-pages .bm-carousel-controls > [data-direction] { position:absolute; top:var(--bm-arrow-y); transform:translateY(-50%); min-width:36px; min-height:36px; padding:4px; border:1px solid #ffffff30; border-radius:50%; background:#080808df; }
  #bandmonkey-feed-and-pages .bm-carousel-controls > [data-direction="-1"] { left:6px; }
  #bandmonkey-feed-and-pages .bm-carousel-controls > [data-direction="1"] { right:6px; }
  #bandmonkey-feed-and-pages .bm-carousel-controls > [data-direction]:disabled { visibility:hidden; }
}

/* One icon occupies a fixed footer column while tags wrap beside it. */
#bandmonkey-feed-and-pages .bm-story-footer { display:grid; grid-template-columns:minmax(0,1fr) auto; gap:12px; align-items:start; }
/* Keep sharing beside tags; optional social destinations get their own compact row. */
#bandmonkey-feed-and-pages .bm-story-footer .bm-post-actions { display:contents; }
#bandmonkey-feed-and-pages .bm-story-footer .bm-story-topics { grid-column:1; grid-row:1; }
#bandmonkey-feed-and-pages .bm-story-footer .bm-share { grid-column:2; grid-row:1; }
#bandmonkey-feed-and-pages .bm-story-footer .bm-post-social { grid-column:1 / -1; grid-row:2; display:flex; flex-wrap:wrap; align-items:center; gap:6px 12px; margin:0; }
#bandmonkey-feed-and-pages .bm-story-footer .bm-post-social > span { font-size:11px; }
#bandmonkey-feed-and-pages .bm-story-footer .bm-post-social > div { margin:0; gap:6px; }
#bandmonkey-feed-and-pages .bm-story-footer .bm-post-social a { min-height:32px; padding:4px 8px; border-radius:4px; font-size:11px; }
#bandmonkey-feed-and-pages .bm-story-footer .bm-post-social .bm-icon { width:14px; height:14px; }
#bandmonkey-feed-and-pages .bm-share { position:relative; justify-content:flex-end; }
#bandmonkey-feed-and-pages .bm-share .bm-native-share { width:32px; min-height:32px; justify-content:center; padding:6px; border:1px solid var(--bm-line); border-radius:4px; background:#11140f; }
#bandmonkey-feed-and-pages .bm-share .bm-native-share:hover { border-color:var(--bm-green); background:#182019; }
#bandmonkey-feed-and-pages .bm-share .bm-native-share svg { width:16px; height:16px; }
#bandmonkey-feed-and-pages .bm-share [role=status]:not(:empty) { position:absolute; right:0; bottom:calc(100% + 6px); width:max-content; max-width:220px; padding:5px 8px; border:1px solid var(--bm-line); border-radius:4px; background:#11140f; color:var(--bm-white); }
#bandmonkey-feed-and-pages .bm-share .bm-share-url:not([hidden]) { position:absolute; right:0; top:38px; width:min(260px,70vw); z-index:2; }
