/* Shared by empty lists, media pickers, the public gallery and guide search. */
.empty-state-card,
#search-status.empty-state-card {
  box-sizing: border-box;
  display: flex;
  flex: 0 0 auto;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  grid-column: 1 / -1;
  align-self: start;
  width: calc(100% - 28px);
  min-width: 0;
  min-height: 92px;
  gap: 6px;
  margin: 10px auto 0;
  padding: 12px;
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 12px;
  background: rgba(255,255,255,.045);
  color: rgba(255,255,255,.72);
  font-size: 13px;
  font-weight: 850;
  line-height: 1.4;
  text-align: center;
  overflow-wrap: anywhere;
}
.empty-state-card[hidden] { display: none; }

/* Bound the card by the window as well as by its list. Lists with their
   own horizontal padding already provide some or all of the 14px inset. */
@supports (width: 1cqi) {
  :is(.panel-modal-box, .pill-overlay, .photo-viewer-shell,
      .viewer-album-dropdown, .viewer-share-dropdown):has(.empty-state-card) {
    container-type: inline-size;
  }
  :is(.panel-modal-box, .pill-overlay, .photo-viewer-shell,
      .viewer-album-dropdown, .viewer-share-dropdown) .empty-state-card {
    width: min(100%, calc(100cqi - 28px));
  }
}

/* These containers already supply the inset or gap above their first item. */
:is(.publication-picker-body, .publication-picker-scroll, .panel-body,
    .progress-section-list, .settings-support-request-list, .contacts-directory-grid,
    .discussions-list, .viewer-album-body) > .empty-state-card:first-child {
  margin-top: 0;
}
.panel-body:has(> .empty-state-card:first-child) { padding-top: 10px; }
.viewer-album-body:has(> .empty-state-card:only-child) { padding-top: 10px; }
.shared-gallery:has(> .empty-state-card) { padding: 10px 14px; }
.shared-gallery > .empty-state-card { margin-top: 0; width: 100%; }
