/* Section: القروض (P3, on the API). From the approved demo's loans.css. Only the :root tokens from app.css; every
   class starts with "loan-". The progress bar's width is set through CSSOM (the CSP blocks style attributes). */

/* The big remaining balance on a loan's screen. */
.loan-hero {
  text-align: center;
}

.loan-hero-label {
  color: var(--muted);
  font-size: 15px;
  font-weight: 800;
}

.loan-hero-amount {
  margin: 2px 0 14px;
  font-size: 34px;
  line-height: 1.3;
}

.loan-hero-amount .money {
  font-weight: 900;
}

.loan-progress {
  height: 12px;
  border-radius: 999px;
  background: var(--line);
  overflow: hidden;
}

.loan-progress-fill {
  height: 100%;
  border-radius: inherit;
  background: var(--ok);
}

.loan-hero-sub {
  margin-top: 8px;
  color: var(--muted);
  font-size: 14px;
}

.loan-hero .btn-full {
  margin-top: 16px;
}

/* «يحتاج متابعة» box with the «تابعت» button. */
.loan-follow {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px 12px;
}

.loan-follow-text {
  display: flex;
  flex: 1 1 220px;
  flex-direction: column;
  gap: 2px;
}

.loan-follow-text strong {
  font-size: 16px;
  font-weight: 900;
}

.loan-follow-hint {
  font-size: 14px;
  font-weight: 500;
}

.loan-follow .btn {
  flex-shrink: 0;
}

/* إيصال · تعديل · حذف in one even row. */
.loan-actions {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin: 0 0 14px;
}

.loan-actions .btn {
  padding-inline: 8px;
}

.loan-actions .loan-delete {
  color: var(--late);
}

.loan-actions .loan-delete:hover:not(:disabled) {
  border-color: var(--late);
}

.loan-notes {
  margin: 0;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.loan-rep-title {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 6px;
}

/* «اعرض المسدّدة» under the open loans. */
.loan-list > .btn-full {
  margin-top: 22px;
}

/* Forms */
.loan-form-intro {
  margin: 0 0 14px;
  color: var(--muted);
  font-weight: 700;
}

.loan-fixed {
  display: flex;
  align-items: center;
  background: var(--bg);
  font-weight: 700;
}

.loan-amount-help {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: 8px;
  color: var(--muted);
  font-size: 14px;
}
