/* =====================================================================
   SweetAlert2 restyled to match the Aurora Brand Glass theme.
   Loaded after sweetalert2.min.css, only on pages with a form.
   ===================================================================== */

.swal2-popup {
  font-family: "Plus Jakarta Sans", system-ui, sans-serif;
  border-radius: 22px;
  padding: 2rem 1.75rem 1.5rem;
  background: var(--glass-strong, rgba(255, 255, 255, .92));
  -webkit-backdrop-filter: var(--blur, blur(18px) saturate(160%));
  backdrop-filter: var(--blur, blur(18px) saturate(160%));
  border: 1px solid rgba(255, 255, 255, .75);
  box-shadow: 0 30px 80px -30px rgba(10, 33, 64, .55),
              inset 0 1px 0 rgba(255, 255, 255, .9);
}

.swal2-title {
  font-size: 1.5rem;
  font-weight: 700;
  color: #0a2140;
}

.swal2-html-container {
  font-size: 1rem;
  line-height: 1.6;
  color: rgba(10, 33, 64, .78);
}

/* Buttons reuse the site's pill styling. */
.swal2-styled.swal2-confirm,
.swal2-styled.swal2-cancel {
  border-radius: 999px;
  padding: .7rem 1.5rem;
  font-weight: 600;
  box-shadow: none;
}

.swal2-styled.swal2-confirm {
  background: var(--blue, #1552a1);
  color: #fff;
  box-shadow: 0 12px 26px -12px rgba(21, 82, 161, .8);
}

.swal2-styled.swal2-confirm:focus-visible,
.swal2-styled.swal2-cancel:focus-visible {
  outline: 3px solid var(--sun, #facf00);
  outline-offset: 2px;
  box-shadow: none;
}

.swal2-styled.swal2-cancel {
  background: rgba(10, 33, 64, .08);
  color: #0a2140;
}

.swal2-icon.swal2-success [class^="swal2-success-line"] { background-color: #1a8f5f; }
.swal2-icon.swal2-success .swal2-success-ring { border-color: rgba(26, 143, 95, .3); }
.swal2-icon.swal2-error { border-color: #c2384a; }
.swal2-icon.swal2-error [class^="swal2-x-mark-line"] { background-color: #c2384a; }

/* The site honours prefers-reduced-motion; so should the dialog. */
@media (prefers-reduced-motion: reduce) {
  .swal2-popup,
  .swal2-icon,
  .swal2-icon [class^="swal2-success-line"],
  .swal2-icon [class^="swal2-x-mark-line"] {
    animation: none !important;
    transition: none !important;
  }
}

/* Inline field errors rendered by _form_field.html */
.form-error {
  margin: .35rem 0 0;
  font-size: .875rem;
  font-weight: 600;
  color: #c2384a;
}

.form-control.is-invalid {
  border-color: #c2384a;
}
