.pageContainer {
  animation: fadeIn 0.3s ease-out;
}

.header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 24px;
  margin-bottom: 32px;
}

.title {
  font-size: 2.5rem;
  font-weight: 800;
  color: var(--primary);
  margin-bottom: 8px;
}

.subtitle {
  color: rgba(255, 255, 255, 0.6);
  font-size: 1rem;
}

.notice {
  display: inline-flex;
  margin-top: 12px;
  padding: 8px 12px;
  border: 1px solid rgba(16, 185, 129, 0.24);
  border-radius: 8px;
  background: rgba(16, 185, 129, 0.08);
  color: var(--success);
  font-size: 0.82rem;
  font-weight: 700;
}

.controls {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.searchInput,
.filterSelect {
  padding: 12px 16px;
  background: rgba(0, 0, 0, 0.2);
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--foreground);
  font-size: 0.875rem;
}

.searchInput {
  min-width: 280px;
}

.searchInput:focus,
.filterSelect:focus {
  outline: none;
  border-color: var(--primary);
}

.rewardPanel {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) repeat(3, minmax(150px, 180px)) auto;
  align-items: end;
  gap: 14px;
  margin-bottom: 24px;
  padding: 18px;
  border-radius: 12px;
}

.rewardPanel h2 {
  margin-bottom: 4px;
  color: var(--foreground);
  font-size: 1.05rem;
}

.rewardPanel p {
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.86rem;
}

.rewardField {
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.rewardField span {
  color: rgba(255, 255, 255, 0.56);
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
}

.rewardField input {
  width: 100%;
  min-height: 38px;
  padding: 9px 11px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.2);
  color: var(--foreground);
  font-size: 0.9rem;
}

.rewardField input:focus {
  border-color: var(--primary);
  outline: none;
}

.summaryGrid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 24px;
}

.summaryCard {
  padding: 18px 20px;
  border-radius: 12px;
}

.summaryLabel {
  display: block;
  color: rgba(255, 255, 255, 0.55);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.5px;
  margin-bottom: 8px;
  text-transform: uppercase;
}

.summaryValue {
  color: var(--foreground);
  font-size: 1.5rem;
  line-height: 1;
}

.tableContainer {
  padding: 24px;
  border-radius: 16px;
  overflow-x: auto;
}

.table {
  width: 100%;
  border-collapse: collapse;
  min-width: 980px;
}

.table th {
  text-align: left;
  padding: 16px 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.5);
  font-size: 0.875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.table td {
  padding: 20px 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  font-size: 0.875rem;
  vertical-align: middle;
}

.table tr:last-child td {
  border-bottom: none;
}

.walletInfo,
.userDetails,
.transactionInfo {
  display: flex;
  flex-direction: column;
}

.walletId {
  font-size: 1rem;
  font-weight: 700;
}

.reference,
.userEmail,
.userRole,
.transactionInfo span,
.transactionInfo small {
  color: rgba(255, 255, 255, 0.5);
  font-size: 0.75rem;
  margin-top: 4px;
}

.userCell {
  display: flex;
  align-items: center;
  gap: 12px;
}

.avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--primary);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.875rem;
  font-weight: 700;
}

.userName {
  color: var(--foreground);
  font-weight: 600;
}

.userRole {
  text-transform: uppercase;
}

.balance {
  color: var(--foreground);
  font-size: 1rem;
}

.transactionInfo {
  gap: 2px;
}

.transactionInfo .typeBadge {
  margin-top: 0;
}

.creditAmount,
.debitAmount {
  font-size: 1rem;
  margin-top: 4px;
}

.creditAmount {
  color: var(--success);
}

.debitAmount {
  color: #60a5fa;
}

.typeBadge,
.badge {
  padding: 6px 12px;
  border-radius: 12px;
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 600;
  width: fit-content;
}

.typeBadge.reward,
.typeBadge.credit {
  background: rgba(16, 185, 129, 0.1);
  color: var(--success);
  border: 1px solid rgba(16, 185, 129, 0.2);
}

.typeBadge.withdrawal,
.typeBadge.debit {
  background: rgba(59, 130, 246, 0.1);
  color: #60a5fa;
  border: 1px solid rgba(59, 130, 246, 0.2);
}

.typeBadge.donation {
  background: rgba(245, 158, 11, 0.1);
  color: var(--warning);
  border: 1px solid rgba(245, 158, 11, 0.2);
}

.typeBadge.adjustment {
  background: rgba(168, 85, 247, 0.1);
  color: #c084fc;
  border: 1px solid rgba(168, 85, 247, 0.2);
}

.badge.completed {
  background: rgba(16, 185, 129, 0.1);
  color: var(--success);
  border: 1px solid rgba(16, 185, 129, 0.2);
}

.badge.pending {
  background: rgba(245, 158, 11, 0.1);
  color: var(--warning);
  border: 1px solid rgba(245, 158, 11, 0.2);
}

.badge.failed,
.badge.cancelled {
  background: rgba(239, 68, 68, 0.1);
  color: var(--danger);
  border: 1px solid rgba(239, 68, 68, 0.2);
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.actionBtn {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border);
  color: var(--foreground);
  padding: 6px 12px;
  border-radius: 6px;
  font-size: 0.75rem;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--transition-fast);
  white-space: nowrap;
}

.actionBtn:hover {
  background: rgba(255, 255, 255, 0.1);
}

.btnPrimary {
  border-color: var(--primary);
  color: var(--primary);
}

.btnPrimary:hover {
  background: rgba(16, 185, 129, 0.1);
}

.btnDanger {
  border-color: rgba(239, 68, 68, 0.5);
  color: var(--danger);
}

.btnDanger:hover {
  background: rgba(239, 68, 68, 0.1);
}

.emptyState {
  padding: 40px 16px;
  color: rgba(255, 255, 255, 0.56);
  text-align: center;
}

.modalOverlay {
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(3, 7, 18, 0.74);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.modal {
  width: min(760px, 100%);
  max-height: min(760px, calc(100vh - 48px));
  overflow: auto;
  padding: 24px;
  background: #101814;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 16px;
  color: #f0fdf4;
  box-shadow: 0 28px 90px rgba(0, 0, 0, 0.5);
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}

.modalHeader {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 20px;
}

.modalHeader h2 {
  margin: 0 0 6px;
  color: #f0fdf4;
  font-size: 1.4rem;
}

.modalHeader p {
  margin: 0;
  color: rgba(240, 253, 244, 0.66);
  font-size: 0.9rem;
}

.closeButton {
  width: 36px;
  height: 36px;
  flex: 0 0 36px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.06);
  color: #f0fdf4;
  cursor: pointer;
  font-size: 1rem;
  line-height: 1;
  transition: all var(--transition-fast);
}

.closeButton:hover {
  background: rgba(255, 255, 255, 0.12);
  border-color: rgba(255, 255, 255, 0.24);
}

.detailGrid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.detailBlock,
.notesBlock {
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.06);
}

.detailBlock {
  min-height: 116px;
  padding: 14px;
}

.detailBlock span,
.notesBlock span {
  display: block;
  margin-bottom: 6px;
  color: rgba(240, 253, 244, 0.66);
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
}

.detailBlock strong {
  display: block;
  color: #f0fdf4;
  font-size: 1rem;
  overflow-wrap: anywhere;
}

.detailBlock small {
  display: block;
  margin-top: 8px;
  color: rgba(240, 253, 244, 0.66);
  font-size: 0.78rem;
}

.notesBlock {
  margin-top: 16px;
  padding: 16px;
}

.notesBlock p {
  margin: 0;
  color: #f0fdf4;
  line-height: 1.6;
}

.modalActions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 20px;
}

@media (max-width: 1100px) {
  .header {
    align-items: flex-start;
    flex-direction: column;
  }

  .rewardPanel {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .controls {
    justify-content: flex-start;
    width: 100%;
  }

  .summaryGrid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .title {
    font-size: 2rem;
  }

  .searchInput,
  .filterSelect {
    width: 100%;
  }

  .summaryGrid {
    grid-template-columns: 1fr;
  }

  .rewardPanel {
    grid-template-columns: 1fr;
  }

  .modalOverlay {
    align-items: stretch;
    padding: 12px;
  }

  .modal {
    max-height: calc(100vh - 24px);
    padding: 18px;
  }

  .detailGrid {
    grid-template-columns: 1fr;
  }

  .modalActions {
    align-items: stretch;
    flex-direction: column;
  }
}
