/**
 * @file
 * Drupal status messages as standard Bootstrap 5 alerts (overrides Barrio message color packs).
 */

/* Wrapper: space from surrounding layout (regions, cards, forms). */
.drupal-status-messages {
  margin: 0 0 1.25rem;
  padding: 0.25rem 0;
}

.drupal-status-messages:last-child {
  margin-bottom: 0;
}

/* Scope so we do not fight admin toolbar or unrelated .alert usage. */
.drupal-status-messages .alert {
  font-size: 0.9375rem;
  line-height: 1.5;
  margin-bottom: 1rem;
  padding: 0.875rem 1.125rem;
}

.drupal-status-messages .drupal-message__icon-i {
  font-size: 1.35rem;
  line-height: 1;
  vertical-align: middle;
}

.drupal-status-messages .drupal-message-alert .drupal-message__icon {
  color: currentColor;
  opacity: 0.92;
  padding-top: 0.125rem;
}

.drupal-status-messages .alert:last-child {
  margin-bottom: 0;
}

/* Extra breathing room between icon column and text (beyond Bootstrap gap). */
.drupal-status-messages .drupal-message__body {
  padding-top: 0.0625rem;
}

/* Classic Bootstrap 5 alert colors (override Barrio messages-gray dark theme). */
.drupal-status-messages .alert-success {
  color: #0f5132;
  background-color: #d1e7dd;
  border-color: #badbcc !important;
}

.drupal-status-messages .alert-danger {
  color: #842029;
  background-color: #f8d7da;
  border-color: #f5c2c7 !important;
}

.drupal-status-messages .alert-warning {
  color: #664d03;
  background-color: #fff3cd;
  border-color: #ffecb5 !important;
}

.drupal-status-messages .alert-info {
  color: #055160;
  background-color: #cff4fc;
  border-color: #b6effb !important;
}

.drupal-status-messages .alert p:last-child {
  margin-bottom: 0;
}

.drupal-status-messages .alert a {
  font-weight: 600;
  text-decoration: underline;
}

/* Inline form error summary / item lists inside a message. */
.drupal-status-messages .alert .item-list,
.drupal-status-messages .alert ul {
  margin: 0.35rem 0 0;
  padding-left: 1.25rem;
}

.drupal-status-messages .alert .item-list li,
.drupal-status-messages .alert ul li {
  margin-bottom: 0.15rem;
}

.drupal-status-messages .alert .item-list--comma-list li {
  display: list-item;
  list-style: disc;
}

/* Highlighted region spacing (login, etc.). */
.region-highlighted .drupal-status-messages {
  max-width: 100%;
}
