/**
 * @file
 * Dialog (pop-up) title fixes.
 *
 * Core's jQuery UI dialog CSS keeps the title on one line and cuts it off
 * with "..." (white-space: nowrap; overflow: hidden; text-overflow: ellipsis).
 * With the theme's large heading font, titles such as the Social Health
 * Connector "Congratulations, you're done!" pop-up became unreadable.
 * Let the title wrap instead, and leave room for the close button.
 *
 * Plain CSS on purpose: the theme has no Sass build in the repo, and
 * css/style.css is generated.
 */
.ui-dialog .ui-dialog-titlebar {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
}

.ui-dialog .ui-dialog-titlebar .ui-dialog-title {
  float: none;
  flex: 1 1 auto;
  width: auto;
  min-width: 0;
  margin: 0.1em 0;
  white-space: normal;
  overflow: visible;
  text-overflow: clip;
  overflow-wrap: anywhere;
  line-height: 1.15;
}

.ui-dialog .ui-dialog-titlebar .ui-dialog-titlebar-close {
  position: static;
  flex: 0 0 auto;
  margin: 0;
}
