/* ========== Trang Khoản Vay Của Tôi / Lịch sử vay ========== */
.page-loan-history {
  background: linear-gradient(180deg, #1a2d42 0%, #2d4a6f 30%, #3d5a80 60%, #2d4a6f 100%);
  min-height: 100vh;
}

.loan-history-app {
  position: relative;
  min-height: 100vh;
  padding-bottom: 2rem;
  overflow: hidden;
}

/* Nền bokeh + 2026 */
.loan-history-bg {
  position: fixed;
  inset: 0;
  background: radial-gradient(circle at 30% 20%, rgba(251, 191, 36, 0.25) 0%, transparent 45%),
              radial-gradient(circle at 70% 50%, rgba(245, 158, 11, 0.2) 0%, transparent 40%),
              radial-gradient(circle at 50% 85%, rgba(34, 197, 94, 0.15) 0%, transparent 35%),
              radial-gradient(circle at 80% 90%, rgba(120, 80, 40, 0.12) 0%, transparent 30%);
  pointer-events: none;
  z-index: 0;
}

.loan-history-year {
  position: absolute;
  left: 50%;
  top: 45%;
  transform: translate(-50%, -50%);
  font-size: 6rem;
  font-weight: 800;
  color: rgba(251, 191, 36, 0.18);
  letter-spacing: 0.05em;
  user-select: none;
}

/* Thanh tiêu đề */
.loan-history-header {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 16px;
  background: rgba(30, 58, 95, 0.9);
  backdrop-filter: blur(8px);
}

.loan-history-back {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  text-decoration: none;
  font-size: 1.2rem;
}

.loan-history-title {
  font-size: 1.125rem;
  font-weight: 700;
  color: #fff;
  margin: 0;
}

.loan-history-placeholder {
  width: 40px;
}

/* Phần tóm tắt (ngày + số tiền vay) */
.loan-history-summary {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 20px 8px;
}

.loan-history-summary-icon {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(34, 197, 94, 0.5);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 0.85rem;
}

.loan-history-summary-text {
  flex: 1;
  min-width: 0;
}

.loan-history-date {
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.9);
  margin: 0 0 1px 0;
  letter-spacing: 0.02em;
}

.loan-history-amount {
  font-size: 0.98rem;
  font-weight: 700;
  color: #fff;
  margin: 0;
  line-height: 1.25;
}

/* Thẻ chi tiết */
.loan-history-card {
  position: relative;
  z-index: 1;
  margin: 0 20px;
  padding: 14px 16px;
  background: rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(10px);
  border-radius: 12px;
}

.loan-history-detail {
  margin-bottom: 14px;
}

.loan-history-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 6px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.15);
  gap: 10px;
}

.loan-history-meta:last-of-type {
  border-bottom: none;
}

.loan-history-label {
  font-size: 0.82rem;
  color: rgba(255, 255, 255, 0.9);
  flex-shrink: 0;
}

.loan-history-value {
  font-size: 0.82rem;
  font-weight: 600;
  color: #fff;
  text-align: right;
}

.loan-history-value--green {
  color: #22c55e;
}

.loan-history-meta--status .loan-history-status {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 0.82rem;
  font-weight: 600;
  color: #22c55e;
}

.loan-history-meta--status .loan-history-status i {
  font-size: 0.75rem;
}

.loan-history-meta--status .loan-history-status.loan-history-status--rejected {
  color: #dc2626;
}

/* Nút Xem chi tiết */
.loan-history-cta {
  width: 100%;
  padding: 12px;
  border: none;
  border-radius: 10px;
  background: #22c55e;
  color: #fff;
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  cursor: pointer;
  transition: background 0.2s, transform 0.1s;
}

.loan-history-cta:hover {
  background: #16a34a;
}

.loan-history-cta:active {
  transform: scale(0.98);
}

.loan-history-empty {
  position: relative;
  z-index: 1;
}

.loan-history-list {
  position: relative;
  z-index: 1;
  padding: 8px 0 24px;
}

.loan-history-item {
  margin-bottom: 20px;
}

.loan-history-item:last-child {
  margin-bottom: 0;
}
