/* Multi-file metadata editor. Dialog frame, sections and fields are shared
   with the details modal (see file-modal.css). */

[id="bulk-modal"] {
  width: min(1480px, calc(100% - 32px));
  height: min(920px, calc(100dvh - 32px));
  max-height: none;
}
#bulk-modal-content { height: 100%; }

/* Same fixed-frame + grid-rows pinning as .file-modal (see detail-modal.css)
   instead of the default sticky-in-flow footer: with a fixed dialog height,
   sticky positioning only pins once the content actually overflows, so on a
   selection with little shared metadata the footer sits right under the
   content, floating well above the bottom of the box, not pinned to it. */
.bulk-modal { height: 100%; max-height: none; display: grid; grid-template-rows: minmax(0, 1fr) auto; padding: 0; overflow: hidden; }
.bulk-modal-scroll { min-height: 0; padding: 26px 32px 28px; overflow-y: auto; }
/* The grid row already pins this to the bottom, so the generic
   .editor-form .dialog-actions sticky rule (which assumes 32px of parent
   padding to cancel with a negative margin) is overridden the same way
   .file-modal overrides it. */
.bulk-modal .dialog-actions { position: static; z-index: 2; margin: 0; padding: 14px 32px; border-top: 1px solid var(--line); background: var(--paper-raised); box-shadow: 0 -8px 22px rgba(34, 31, 25, .045); }

.bulk-file-scroll { max-height: 260px; overflow-y: auto; }
.bulk-file-table td, .bulk-file-table th { padding-right: 16px; }
/* Outranks the list hover rule: this table is a read-only summary. */
.list-table.bulk-file-table tbody tr:hover { background: transparent; }
.bulk-file-name { max-width: 340px; color: var(--ink); }

.bulk-hint { margin: 0 0 16px; color: var(--muted); font: italic 12px/1.45 var(--serif); }
.bulk-warn { margin: 14px 0 0; color: var(--red); font-size: 11px; }

/* Assets are for looking at: previews side by side instead of a field form. */
.asset-gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 16px; }
.asset-tile { margin: 0; display: grid; gap: 8px; }
.asset-tile-body { height: 170px; overflow: hidden; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 3px; background: var(--paper); }
.asset-tile figcaption { overflow: hidden; color: var(--muted); font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.asset-tile figcaption { display: flex; align-items: center; gap: 6px; }
.asset-tile figcaption span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.asset-tile figcaption .icon-button { flex: 0 0 auto; }
