.loading {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  height: 100%;
  z-index: 999999999999;
  background: rgba(0, 0, 0, 0.25);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  direction: ltr;
}
@keyframes mgd-spin { to { transform: rotate(360deg); } }

.btn-supporting-info {
  margin-bottom: 0.5rem;
  background: #fff;
  color: #659be0;
  border: 1px solid;
  border-radius: 6px !important;
  font-size: 1.33rem;
}

.kv-grid-container {
  /* max-height: 400px; */
  overflow-y: auto;
}

.required {
  content: " *";
  color: darkred;
}

/* =============================================
   Modal Standardization
   ============================================= */

/* Header */
.modal-header {
  background-color: #1b7398;
  color: #fff;
  padding: 12px 18px;
  border-bottom: none;
  border-radius: 4px 4px 0 0;
}

.modal-title {
  font-size: 1rem;
  font-weight: 600;
  color: #fff !important;
}

/* Close button */
.modal-header .close,
.modal-header button[data-dismiss="modal"],
.modal-header button[data-bs-dismiss="modal"] {
  color: #fff;
  opacity: 0.85;
  font-size: 1.4rem;
  line-height: 1;
  padding: 0 4px;
  background: transparent;
  border: none;
  cursor: pointer;
  text-shadow: none;
}

.modal-header .close:hover,
.modal-header button[data-dismiss="modal"]:hover,
.modal-header button[data-bs-dismiss="modal"]:hover {
  opacity: 1;
  color: #fff;
}

/* Sub-header (portlet-title inside modal) */
.modal .portlet-title {
  background-color: #e8f4fa;
  border-left: 4px solid #1b7398;
  /* padding: 8px 12px;
  margin-bottom: 12px;
  border-radius: 2px;
  font-weight: 600; */
}

.modal .portlet-title .caption-subject {
  font-size: 0.92rem;
  color: #1b7398 !important;
  font-weight: 600;
}

.modal .portlet-title i {
  color: #1b7398 !important;
  margin-inline-end: 6px;
}

/* Modal body */
.modal-body {
  padding: 18px 20px;
  font-size: 0.92rem;
}

.modal-body label {
  font-size: 0.88rem;
  font-weight: 600;
  color: #444;
  margin-bottom: 3px;
}

.modal-body .form-control,
.modal-body select,
.modal-body textarea {
  font-size: 0.88rem;
  border-radius: 4px;
  border: 1px solid #c8d3e0;
  padding: 5px 10px;
}

.modal-body .form-control:focus,
.modal-body select:focus,
.modal-body textarea:focus {
  border-color: #1b7398;
  box-shadow: 0 0 0 2px rgba(27, 115, 152, 0.15);
  outline: none;
}

/* Footer */
.modal-footer {
  padding: 10px 18px;
  border-top: 1px solid #dde5ed;
  background-color: #f8fafb;
}

.modal-footer .btn {
  font-size: 0.88rem;
  padding: 6px 18px;
  border-radius: 4px;
}

/* Table inside modal */
.modal-body table {
  font-size: 0.88rem;
}

/* ── Select2 dropdown arrow – hidden globally ────────────────────────────── */
/* Ensure the clear button can anchor inside the field */
.select2-container .select2-selection--single {
  position: relative !important;
}
.select2-container .select2-selection--single .select2-selection__arrow {
  display: none !important;
}
/* Exception: phone dial-code picker keeps its arrow */
.pf-phone-flag .select2-container .select2-selection--single .select2-selection__arrow {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
}

/* ── Select2 clear button – global style ────────────────────────────────────
   Replaces the plain "×" text with a clean circular badge on every Select2
   field that has allowClear: true (single and multiple selections).
   Scoped to krajee and default Select2 containers used throughout the app.
──────────────────────────────────────────────────────────────────────────── */
.select2-container--krajee .select2-selection__clear,
.select2-container--krajee-bs4 .select2-selection__clear,
.select2-container--default .select2-selection__clear {
  width: 18px;
  height: 18px;
  background: #e5e7eb;
  border-radius: 50%;
  display: flex !important;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
  line-height: 1;
  color: #6b7280;
  cursor: pointer;
  transition: background .15s, color .15s;
  padding: 0;
  text-decoration: none;
  border: none;
  /* Pin to top-right corner of the selection field */
  position: absolute !important;
  top: 4px !important;
  right: 4px !important;
}
.select2-container--krajee .select2-selection__clear:hover,
.select2-container--krajee-bs4 .select2-selection__clear:hover,
.select2-container--default .select2-selection__clear:hover {
  background: #fecaca;
  color: #dc2626;
}
/* RTL (Arabic): flip × badge to top-LEFT corner */
[dir="rtl"] .select2-container--krajee .select2-selection__clear,
[dir="rtl"] .select2-container--krajee-bs4 .select2-selection__clear,
[dir="rtl"] .select2-container--default .select2-selection__clear {
  right: auto !important;
  left: 4px !important;
}

