/* ===================== BASE STYLES ===================== */
:root {
  --bkash-pink: #E2136E;
  --bkash-light: #FCE4EC;
  --bkash-dark: #C2185B;
  --nagad-orange: #F6921E;
  --nagad-light: #FFF3E0;
  --nagad-dark: #E65100;
  --upay-blue: #0077C8;
  --upay-light: #E0F0FF;
  --rocket-purple: #8B2F8E;
  --rocket-light: #F3E5F5;
  --binance-yellow: #F0B90B;
  --binance-light: #FFF8E1;
  --crypto-gold: #F59E0B;
  --crypto-light: #FFFBEB;
  --success: #22C55E;
  --success-bg: #F0FDF4;
  --danger: #EF4444;
  --danger-bg: #FEF2F2;
  --warning: #F59E0B;
  --warning-bg: #FFFBEB;
  --info: #3B82F6;
  --info-bg: #EFF6FF;
  --bg: #F8FAFC;
  --card-bg: #FFFFFF;
  --text: #1E293B;
  --text-light: #64748B;
  --border: #E2E8F0;
  --shadow: 0 1px 3px rgba(0,0,0,0.1), 0 1px 2px rgba(0,0,0,0.06);
  --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.1), 0 4px 6px -2px rgba(0,0,0,0.05);
  --shadow-xl: 0 20px 25px -5px rgba(0,0,0,0.1), 0 10px 10px -5px rgba(0,0,0,0.04);
  --radius: 16px;
  --radius-sm: 10px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  -webkit-tap-highlight-color: transparent;
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  min-height: 100vh;
  min-height: -webkit-fill-available;
  -webkit-font-smoothing: antialiased;
  padding-bottom: env(safe-area-inset-bottom, 0);
}

.container {
  max-width: 680px;
  margin: 0 auto;
  padding: 0 16px;
  padding-left: max(16px, env(safe-area-inset-left));
  padding-right: max(16px, env(safe-area-inset-right));
}

/* ===================== DEPOSIT PAGE ===================== */
.deposit-page {
  background: #F5F7FA;
  min-height: 100vh;
  position: relative;
}

.deposit-page::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 280px;
  background: linear-gradient(135deg, #635BFF 0%, #0A2540 100%);
  z-index: 0;
}

.deposit-page .container { position: relative; z-index: 1; }

.deposit-header {
  background: transparent;
  color: white;
  padding: 32px 0 16px;
  padding-top: max(32px, env(safe-area-inset-top));
  text-align: center;
  position: relative;
  z-index: 1;
}

.deposit-header h1 {
  font-size: 1.6rem;
  font-weight: 700;
  margin-bottom: 4px;
  letter-spacing: -0.3px;
  color: #fff;
}

.deposit-header h1 i {
  margin-right: 8px;
  opacity: 0.85;
}

.deposit-header p {
  opacity: 0.7;
  font-size: 0.85rem;
  font-weight: 400;
  letter-spacing: 0.3px;
}

/* Status Check Bar */
.status-check-bar {
  margin-top: 20px;
  margin-bottom: 8px;
}

.status-form {
  display: flex;
  gap: 8px;
}

.status-form input {
  flex: 1;
  padding: 12px 14px;
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 16px;
  font-family: inherit;
  outline: none;
  transition: border-color 0.2s;
  -webkit-appearance: none;
  appearance: none;
}

.status-form input:focus { border-color: var(--info); }

.status-form button {
  padding: 12px 18px;
  background: var(--info);
  color: white;
  border: none;
  border-radius: var(--radius-sm);
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  transition: background 0.2s;
  white-space: nowrap;
  min-height: 48px;
}

.status-form button:hover { background: #2563EB; }

.status-result {
  margin-top: 10px;
  padding: 12px 16px;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  font-weight: 500;
}

.status-result.pending { background: var(--warning-bg); color: #92400E; border: 1px solid #FCD34D; }
.status-result.approved { background: var(--success-bg); color: #166534; border: 1px solid #86EFAC; }
.status-result.rejected { background: var(--danger-bg); color: #991B1B; border: 1px solid #FCA5A5; }
.status-result.error { background: var(--danger-bg); color: #991B1B; border: 1px solid #FCA5A5; }

/* Deposit Card */
.deposit-card {
  background: #FFFFFF;
  border-radius: var(--radius);
  box-shadow: 0 2px 8px rgba(0,0,0,0.06), 0 0 1px rgba(0,0,0,0.1);
  padding: 28px;
  margin: 12px 0 20px;
  animation: cardIn 0.35s ease-out;
}

@keyframes cardIn {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

.step-section { margin-bottom: 28px; }
.step-section:last-of-type { margin-bottom: 0; }

.step-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
}

.step-number {
  width: 32px;
  height: 32px;
  background: #635BFF;
  color: white;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.8rem;
  flex-shrink: 0;
}

.step-header h2 {
  font-size: 1.05rem;
  font-weight: 600;
  color: #0A2540;
}

/* Payment Methods */
.payment-methods {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 12px;
}

.payment-method-card {
  border: 1px solid #E3E8EE;
  border-radius: 12px;
  padding: 14px 16px;
  cursor: pointer;
  transition: all 0.15s ease;
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 68px;
  -webkit-user-select: none;
  user-select: none;
  background: #fff;
}

.payment-method-card:active {
  transform: scale(0.98);
}

.payment-method-card:hover {
  border-color: #C4C9D2;
  box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

.payment-method-card.bkash.selected {
  border-color: var(--bkash-pink);
  background: var(--bkash-light);
}

.payment-method-card.nagad.selected {
  border-color: var(--nagad-orange);
  background: var(--nagad-light);
}

.payment-method-card.upay.selected {
  border-color: var(--upay-blue);
  background: var(--upay-light);
}

.payment-method-card.rocket.selected {
  border-color: var(--rocket-purple);
  background: var(--rocket-light);
}

.payment-method-card.binance.selected {
  border-color: var(--binance-yellow);
  background: var(--binance-light);
}

.payment-method-card.crypto.selected {
  border-color: var(--crypto-gold);
  background: var(--crypto-light);
}

.method-icon {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  overflow: hidden;
  background: transparent;
}

.method-icon svg,
.method-icon img {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  object-fit: cover;
}

.method-info { flex: 1; }
.method-info .method-name { font-weight: 700; font-size: 0.95rem; }
.method-info .method-number { color: var(--text-light); font-size: 0.85rem; margin-top: 2px; }
.method-info .method-agent { color: var(--text-light); font-size: 0.8rem; }

.no-wallets {
  text-align: center;
  padding: 32px;
  color: var(--text-light);
}

.no-wallets i { font-size: 2rem; margin-bottom: 12px; color: var(--warning); }

/* Agent Info Card */
.agent-info-card {
  background: #F7F8FA;
  border-radius: 12px;
  padding: 24px;
  text-align: center;
  margin-bottom: 16px;
  border: 1px solid #E3E8EE;
}

.agent-type-badge {
  display: inline-block;
  padding: 4px 16px;
  border-radius: 20px;
  font-weight: 700;
  font-size: 0.8rem;
  margin-bottom: 12px;
  color: white;
}

.bdt-conversion {
  background: linear-gradient(135deg, #F0FDF4, #DCFCE7);
  border: 1px solid #86EFAC;
  border-radius: 8px;
  padding: 8px 12px;
  margin-top: 6px;
  font-size: 0.9rem;
  font-weight: 600;
  color: #166534;
  text-align: center;
}

.history-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.85rem;
}
.history-table th {
  background: var(--bg);
  padding: 10px 12px;
  text-align: left;
  font-weight: 700;
  font-size: 0.75rem;
  text-transform: uppercase;
  color: var(--text-light);
  border-bottom: 2px solid #E2E8F0;
}
.history-table td {
  padding: 10px 12px;
  border-bottom: 1px solid #F1F5F9;
}
.history-table tr:hover { background: #F8FAFC; }
.history-status {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 12px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
}
.history-status.pending { background: var(--warning-bg); color: var(--warning); }
.history-status.approved { background: var(--success-bg); color: var(--success); }
.history-status.rejected { background: var(--danger-bg); color: var(--danger); }

.btn-verify {
  background: #3B82F6;
  color: white;
  border: none;
  border-radius: 6px;
  padding: 6px 12px;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
}
.btn-verify:hover { background: #2563EB; }

.badge-logo {
  display: inline-block;
  width: 22px;
  height: 22px;
  vertical-align: middle;
  margin-right: 4px;
}
.badge-logo svg,
.badge-logo img {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  object-fit: cover;
}

.agent-type-badge.bkash { background: var(--bkash-pink); }
.agent-type-badge.nagad { background: var(--nagad-orange); }
.agent-type-badge.upay { background: var(--upay-blue); }
.agent-type-badge.rocket { background: var(--rocket-purple); }
.agent-type-badge.binance { background: var(--binance-yellow); color: #1E293B; }
.agent-type-badge.crypto { background: linear-gradient(135deg, #F59E0B, #D97706); }

.agent-label {
  color: var(--text-light);
  font-size: 0.9rem;
  margin-bottom: 8px;
}

.agent-number-display {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-bottom: 8px;
  flex-wrap: wrap;
}

.agent-number {
  font-size: 1.6rem;
  font-weight: 800;
  letter-spacing: 1px;
  color: var(--text);
  word-break: break-all;
  text-align: center;
  line-height: 1.3;
}

.copy-btn {
  width: 44px;
  height: 44px;
  border: 2px solid var(--border);
  background: white;
  border-radius: 8px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-light);
  transition: all 0.2s;
  font-size: 1.1rem;
}

.copy-btn:active {
  transform: scale(0.9);
  background: var(--info-bg);
}

.copy-btn:hover { border-color: var(--info); color: var(--info); }

@media (max-width: 480px) {
  .agent-number {
    font-size: 1rem;
    letter-spacing: 0;
  }
  .agent-number-display {
    flex-direction: column;
    gap: 12px;
  }
  .copy-btn {
    width: 100%;
    height: 48px;
    border-radius: 10px;
    font-size: 0.9rem;
    gap: 8px;
    background: #635BFF;
    color: white;
    border: none;
  }
  .copy-btn::after {
    content: 'Tap to Copy';
    font-weight: 600;
    font-family: inherit;
  }
  .copy-btn:active {
    background: #5851DB;
    transform: scale(0.97);
  }
}

.agent-name { color: var(--text-light); font-size: 0.85rem; }

/* Crypto QR Code */
.crypto-qr {
  margin: 16px 0 12px;
}
.qr-wrapper {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  background: #fff;
  border: 1px solid #E3E8EE;
  border-radius: 12px;
  padding: 16px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.06);
}
.qr-wrapper svg,
.qr-image {
  border-radius: 8px;
  width: 180px;
  height: 180px;
  object-fit: contain;
}
.qr-label {
  margin-top: 8px;
  font-size: 0.75rem;
  color: #8898AA;
  font-weight: 500;
}

.send-instructions {
  background: var(--info-bg);
  border: 1px solid #BFDBFE;
  border-radius: var(--radius-sm);
  padding: 16px;
}

.send-instructions h3 {
  font-size: 0.9rem;
  color: #1E40AF;
  margin-bottom: 10px;
}

.send-instructions ol {
  padding-left: 20px;
  font-size: 0.85rem;
  color: #1E40AF;
}

.send-instructions ol li { margin-bottom: 4px; }

/* Deposit Form */
.deposit-form { display: flex; flex-direction: column; gap: 16px; }

.form-group { display: flex; flex-direction: column; gap: 6px; }

.form-group label {
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--text);
}

.form-group label i {
  margin-right: 6px;
  color: var(--text-light);
}

.form-group input {
  padding: 12px 14px;
  border: 1px solid #E3E8EE;
  border-radius: 8px;
  font-size: 16px;
  font-family: inherit;
  outline: none;
  transition: all 0.15s ease;
  -webkit-appearance: none;
  appearance: none;
  min-height: 48px;
  background: #fff;
  box-shadow: 0 1px 2px rgba(0,0,0,0.04);
}

.form-group input:focus {
  border-color: #635BFF;
  box-shadow: 0 0 0 3px rgba(99,91,255,0.12), 0 1px 2px rgba(0,0,0,0.04);
}

.form-group small { color: var(--text-light); font-size: 0.8rem; }

/* Quick Amount Buttons */
.quick-amounts {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin-bottom: 10px;
}

.quick-amt-btn {
  padding: 12px 6px;
  border: 2px solid var(--border);
  background: var(--bg);
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  color: var(--text);
  transition: all 0.15s ease;
  min-height: 46px;
  -webkit-user-select: none;
  user-select: none;
}

.quick-amt-btn:active {
  transform: scale(0.95);
}

.quick-amt-btn:hover {
  border-color: var(--info);
  color: var(--info);
  background: var(--info-bg);
}

.quick-amt-btn.selected {
  border-color: var(--info);
  background: var(--info);
  color: white;
}

@media (max-width: 480px) {
  .quick-amounts {
    grid-template-columns: repeat(4, 1fr);
    gap: 6px;
  }
  .quick-amt-btn {
    padding: 8px 4px;
    font-size: 0.78rem;
  }
}

.submit-btn {
  padding: 14px;
  background: #635BFF;
  color: white;
  border: none;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  transition: all 0.15s ease;
  margin-top: 8px;
  min-height: 52px;
  -webkit-user-select: none;
  user-select: none;
  letter-spacing: 0.2px;
}

.submit-btn:hover { background: #5851DB; box-shadow: 0 4px 12px rgba(99,91,255,0.25); }
.submit-btn:active { transform: scale(0.98); }
.submit-btn:disabled { opacity: 0.5; cursor: not-allowed; transform: none; }

/* Success Section */
.success-section {
  text-align: center;
  padding: 32px 16px;
}

.success-icon {
  font-size: 4rem;
  color: var(--success);
  margin-bottom: 16px;
}

.success-section h2 {
  font-size: 1.3rem;
  margin-bottom: 8px;
}

.success-section > p {
  color: var(--text-light);
  margin-bottom: 20px;
}

.success-details {
  background: var(--success-bg);
  border: 1px solid #86EFAC;
  border-radius: var(--radius-sm);
  padding: 16px;
  text-align: left;
  font-size: 0.9rem;
  margin-bottom: 20px;
}

.success-details p { margin-bottom: 6px; }
.success-details strong { color: var(--text); }

.new-deposit-btn {
  padding: 14px 28px;
  background: var(--info);
  color: white;
  border: none;
  border-radius: var(--radius-sm);
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  font-size: 1rem;
  transition: all 0.2s;
  min-height: 50px;
}

.new-deposit-btn:active { transform: scale(0.97); }

.new-deposit-btn:hover { background: #2563EB; }

/* ===================== ADMIN PAGE ===================== */
.admin-page { background: var(--bg); }

.admin-page .container {
  max-width: 1200px;
}

/* Admin Login */
.login-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 16px;
}

.login-card {
  background: white;
  border-radius: var(--radius);
  padding: 32px;
  width: 100%;
  max-width: 400px;
  box-shadow: var(--shadow-xl);
  text-align: center;
}

.login-card h1 {
  font-size: 1.5rem;
  margin-bottom: 4px;
}

.login-card .subtitle {
  color: var(--text-light);
  font-size: 0.9rem;
  margin-bottom: 24px;
}

.login-card .login-icon {
  font-size: 2.5rem;
  color: var(--info);
  margin-bottom: 16px;
}

.login-form { display: flex; flex-direction: column; gap: 14px; }

.login-form input {
  padding: 12px 14px;
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 1rem;
  font-family: inherit;
  outline: none;
  transition: border-color 0.2s;
}

.login-form input:focus { border-color: var(--info); }

.login-btn {
  padding: 12px;
  background: linear-gradient(135deg, #1E293B, #334155);
  color: white;
  border: none;
  border-radius: var(--radius-sm);
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  font-family: inherit;
  transition: all 0.2s;
}

.login-btn:hover { transform: translateY(-1px); box-shadow: var(--shadow-lg); }

.login-error {
  color: var(--danger);
  font-size: 0.85rem;
  font-weight: 500;
  min-height: 20px;
}

/* Admin Header */
.admin-header {
  background: linear-gradient(135deg, #1E293B 0%, #334155 100%);
  color: white;
  padding: 16px 0;
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: var(--shadow-lg);
}

.admin-header .header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.admin-header h1 {
  font-size: 1.2rem;
  font-weight: 700;
}

.admin-header h1 i { margin-right: 8px; }

.header-right {
  display: flex;
  align-items: center;
  gap: 12px;
}

.admin-user {
  font-size: 0.85rem;
  opacity: 0.8;
}

.logout-btn {
  padding: 6px 14px;
  background: rgba(255,255,255,0.15);
  color: white;
  border: 1px solid rgba(255,255,255,0.3);
  border-radius: 6px;
  cursor: pointer;
  font-size: 0.8rem;
  font-family: inherit;
  font-weight: 500;
  transition: background 0.2s;
}

.logout-btn:hover { background: rgba(255,255,255,0.25); }

/* Admin Navigation Tabs */
.admin-tabs {
  display: flex;
  gap: 4px;
  background: var(--card-bg);
  padding: 8px;
  border-radius: var(--radius);
  margin: 16px auto;
  box-shadow: var(--shadow);
  overflow-x: auto;
}

.admin-tab {
  padding: 10px 16px;
  border: none;
  background: none;
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  color: var(--text-light);
  transition: all 0.2s;
  white-space: nowrap;
  display: flex;
  align-items: center;
  gap: 6px;
}

.admin-tab:hover { background: var(--bg); color: var(--text); }

.admin-tab.active {
  background: #1E293B;
  color: white;
}

.admin-tab .badge {
  background: var(--danger);
  color: white;
  font-size: 0.7rem;
  padding: 2px 7px;
  border-radius: 10px;
  font-weight: 700;
}

.admin-tab.active .badge {
  background: white;
  color: var(--danger);
}

/* Stats Grid */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 12px;
  margin-bottom: 20px;
}

.stat-card {
  background: var(--card-bg);
  border-radius: var(--radius-sm);
  padding: 16px;
  box-shadow: var(--shadow);
}

.stat-card .stat-label {
  font-size: 0.8rem;
  color: var(--text-light);
  font-weight: 500;
  margin-bottom: 4px;
}

.stat-card .stat-value {
  font-size: 1.5rem;
  font-weight: 800;
}

.stat-card.pending .stat-value { color: var(--warning); }
.stat-card.approved .stat-value { color: var(--success); }
.stat-card.rejected .stat-value { color: var(--danger); }
.stat-card.info .stat-value { color: var(--info); }

/* Tables */
.table-container {
  background: var(--card-bg);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
  margin-bottom: 20px;
}

.table-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
  flex-wrap: wrap;
  gap: 12px;
}

.table-header h3 {
  font-size: 1rem;
  font-weight: 700;
}

.table-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.filter-select, .search-input {
  padding: 8px 12px;
  border: 2px solid var(--border);
  border-radius: 6px;
  font-size: 0.85rem;
  font-family: inherit;
  outline: none;
  transition: border-color 0.2s;
}

.filter-select:focus, .search-input:focus { border-color: var(--info); }

.search-input { min-width: 200px; }

.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.85rem;
}

.data-table thead th {
  background: var(--bg);
  padding: 10px 14px;
  text-align: left;
  font-weight: 600;
  color: var(--text-light);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}

.data-table tbody td {
  padding: 12px 14px;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
}

.data-table tbody tr:last-child td { border-bottom: none; }
.data-table tbody tr:hover { background: var(--bg); }

.table-responsive {
  overflow-x: auto;
}

/* Status Badges */
.badge-status {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 600;
}

.badge-status.pending { background: var(--warning-bg); color: #92400E; }
.badge-status.approved { background: var(--success-bg); color: #166534; }
.badge-status.rejected { background: var(--danger-bg); color: #991B1B; }

.badge-type {
  display: inline-flex;
  align-items: center;
  padding: 3px 8px;
  border-radius: 4px;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
}

.badge-type.bkash { background: var(--bkash-light); color: var(--bkash-pink); }
.badge-type.nagad { background: var(--nagad-light); color: var(--nagad-orange); }
.badge-type.upay { background: var(--upay-light); color: var(--upay-blue); }
.badge-type.rocket { background: var(--rocket-light); color: var(--rocket-purple); }
.badge-type.binance { background: var(--binance-light); color: #B8860B; }
.badge-type.crypto { background: var(--crypto-light); color: #92400E; }

/* Action Buttons */
.btn-approve, .btn-reject {
  padding: 6px 12px;
  border: none;
  border-radius: 6px;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  transition: all 0.2s;
}

.btn-approve {
  background: var(--success);
  color: white;
}

.btn-approve:hover { background: #16A34A; }

.btn-reject {
  background: var(--danger);
  color: white;
}

.btn-reject:hover { background: #DC2626; }

.btn-sm {
  padding: 4px 10px;
  font-size: 0.75rem;
}

.action-buttons { display: flex; gap: 6px; }

/* Wallet Management */
.add-wallet-form {
  background: var(--bg);
  border-radius: var(--radius-sm);
  padding: 20px;
  margin-bottom: 20px;
  border: 2px solid var(--border);
}

.add-wallet-form h3 {
  font-size: 1rem;
  margin-bottom: 14px;
}

.wallet-form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr auto;
  gap: 10px;
  align-items: end;
}

.wallet-form-grid .form-group { margin-bottom: 0; }

.wallet-form-grid select,
.wallet-form-grid input {
  padding: 10px 12px;
  border: 2px solid var(--border);
  border-radius: 6px;
  font-size: 0.9rem;
  font-family: inherit;
  outline: none;
  transition: border-color 0.2s;
}

.wallet-form-grid select:focus,
.wallet-form-grid input:focus { border-color: var(--info); }

.btn-add {
  padding: 10px 20px;
  background: var(--info);
  color: white;
  border: none;
  border-radius: 6px;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  font-size: 0.9rem;
  transition: background 0.2s;
  height: fit-content;
}

.btn-add:hover { background: #2563EB; }

.wallet-status-toggle {
  padding: 4px 10px;
  border: none;
  border-radius: 4px;
  font-size: 0.75rem;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
}

.wallet-status-toggle.active { background: var(--success-bg); color: #166534; }
.wallet-status-toggle.inactive { background: var(--danger-bg); color: #991B1B; }

.btn-delete {
  padding: 4px 10px;
  background: none;
  color: var(--danger);
  border: 1px solid var(--danger);
  border-radius: 4px;
  font-size: 0.75rem;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  transition: all 0.2s;
}

.btn-delete:hover { background: var(--danger); color: white; }

.btn-view {
  padding: 4px 10px;
  background: none;
  color: var(--info);
  border: 1px solid var(--info);
  border-radius: 4px;
  font-size: 0.75rem;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  transition: all 0.2s;
}

.btn-view:hover { background: var(--info); color: white; }

/* Modal */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  padding: 16px;
}

.modal-content {
  background: white;
  border-radius: var(--radius);
  width: 100%;
  max-width: 800px;
  max-height: 80vh;
  overflow-y: auto;
  box-shadow: var(--shadow-xl);
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  background: white;
  z-index: 1;
}

.modal-header h3 { font-size: 1.1rem; }

.modal-close {
  width: 32px;
  height: 32px;
  border: none;
  background: var(--bg);
  border-radius: 6px;
  cursor: pointer;
  font-size: 1.1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-light);
  transition: all 0.2s;
}

.modal-close:hover { background: var(--danger-bg); color: var(--danger); }

.modal-body { padding: 20px; }

/* Pagination */
.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 16px;
  border-top: 1px solid var(--border);
}

.page-btn {
  padding: 6px 12px;
  border: 1px solid var(--border);
  background: white;
  border-radius: 6px;
  cursor: pointer;
  font-family: inherit;
  font-size: 0.85rem;
  transition: all 0.2s;
}

.page-btn:hover { border-color: var(--info); color: var(--info); }
.page-btn.active { background: #1E293B; color: white; border-color: #1E293B; }
.page-btn:disabled { opacity: 0.4; cursor: not-allowed; }

.page-info { font-size: 0.85rem; color: var(--text-light); }

/* Tab Content */
.tab-content { display: none; }
.tab-content.active { display: block; }

/* Toast */
.toast {
  position: fixed;
  bottom: 24px;
  left: 50%;
  transform: translateX(-50%) translateY(100px);
  padding: 12px 24px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 0.9rem;
  z-index: 10000;
  transition: transform 0.3s ease;
  box-shadow: var(--shadow-xl);
  max-width: 90%;
  text-align: center;
}

.toast.show { transform: translateX(-50%) translateY(0); }

.toast.success { background: #166534; color: white; }
.toast.error { background: #991B1B; color: white; }
.toast.info { background: #1E40AF; color: white; }

/* Empty state */
.empty-state {
  text-align: center;
  padding: 40px 20px;
  color: var(--text-light);
}

.empty-state i {
  font-size: 2.5rem;
  margin-bottom: 12px;
  opacity: 0.5;
}

.empty-state p { font-size: 0.9rem; }

/* Utility */
.hidden { display: none !important; }
.text-right { text-align: right; }
.text-center { text-align: center; }
.font-mono { font-family: 'Courier New', monospace; }
.text-sm { font-size: 0.85rem; }
.text-muted { color: var(--text-light); }
.mb-4 { margin-bottom: 16px; }
.mt-2 { margin-top: 8px; }

/* Responsive */
@media (max-width: 768px) {
  .wallet-form-grid {
    grid-template-columns: 1fr;
  }

  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .admin-tabs {
    gap: 2px;
    padding: 6px;
    -webkit-overflow-scrolling: touch;
  }

  .admin-tab {
    padding: 10px 14px;
    font-size: 0.8rem;
    min-height: 44px;
  }

  .table-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .table-actions {
    width: 100%;
  }

  .search-input {
    min-width: unset;
    width: 100%;
    min-height: 44px;
  }

  .filter-select {
    min-height: 44px;
  }

  .payment-methods {
    grid-template-columns: 1fr;
  }

  .header-right {
    gap: 8px;
  }

  .admin-user {
    display: none;
  }

  .deposit-header h1 {
    font-size: 1.5rem;
  }

  .step-header h2 {
    font-size: 1rem;
  }

  .btn-approve, .btn-reject {
    padding: 8px 14px;
    min-height: 38px;
  }

  .action-buttons {
    flex-wrap: wrap;
  }

  .modal-content {
    max-height: 90vh;
    border-radius: var(--radius) var(--radius) 0 0;
    margin-top: auto;
  }

  .modal-overlay {
    align-items: flex-end;
    padding: 0;
  }

  .table-responsive {
    -webkit-overflow-scrolling: touch;
  }
}

@media (max-width: 480px) {
  .container {
    padding: 0 12px;
  }

  .stats-grid {
    grid-template-columns: 1fr 1fr;
    gap: 8px;
  }

  .stat-card {
    padding: 12px;
  }

  .stat-card .stat-value {
    font-size: 1.2rem;
  }

  .deposit-card {
    padding: 14px;
    border-radius: var(--radius-sm);
    margin: 12px 0 32px;
  }

  .deposit-header {
    padding: 20px 0 18px;
  }

  .deposit-header h1 {
    font-size: 1.35rem;
  }

  .deposit-header p {
    font-size: 0.82rem;
  }

  .agent-number {
    font-size: 1.4rem;
  }

  .agent-info-card {
    padding: 16px 12px;
  }

  .send-instructions {
    padding: 14px 12px;
  }

  .send-instructions ol {
    padding-left: 18px;
    font-size: 0.82rem;
  }

  .send-instructions ol li {
    margin-bottom: 6px;
  }

  .form-group label {
    font-size: 0.88rem;
  }

  .form-group small {
    font-size: 0.75rem;
  }

  .status-form {
    flex-direction: column;
  }

  .status-form button {
    width: 100%;
  }

  .status-result {
    font-size: 0.82rem;
    word-break: break-word;
  }

  .success-section {
    padding: 24px 12px;
  }

  .success-icon {
    font-size: 3rem;
  }

  .success-section h2 {
    font-size: 1.15rem;
  }

  .success-details {
    font-size: 0.85rem;
    padding: 12px;
  }

  .new-deposit-btn {
    width: 100%;
  }

  .submit-btn {
    font-size: 1rem;
  }

  .login-card {
    padding: 24px 20px;
  }

  .login-card h1 {
    font-size: 1.3rem;
  }

  .toast {
    bottom: 16px;
    left: 12px;
    right: 12px;
    transform: translateY(100px);
    max-width: none;
    border-radius: var(--radius-sm);
  }

  .toast.show {
    transform: translateY(0);
  }

  .confirm-modal .confirm-buttons {
    flex-direction: column;
  }

  .confirm-modal .confirm-buttons button {
    width: 100%;
  }
}

/* Refresh button */
.btn-refresh {
  padding: 8px 14px;
  background: var(--bg);
  border: 2px solid var(--border);
  border-radius: 6px;
  cursor: pointer;
  font-family: inherit;
  font-size: 0.85rem;
  font-weight: 500;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  gap: 6px;
}

.btn-refresh:hover { border-color: var(--info); color: var(--info); }

/* Loading spinner */
.spinner {
  display: inline-block;
  width: 16px;
  height: 16px;
  border: 2px solid rgba(255,255,255,0.3);
  border-radius: 50%;
  border-top-color: white;
  animation: spin 0.6s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* Amount highlight */
.amount-display {
  font-weight: 700;
  color: var(--text);
}

/* Note input in modal */
.note-input {
  width: 100%;
  padding: 8px 12px;
  border: 2px solid var(--border);
  border-radius: 6px;
  font-size: 0.85rem;
  font-family: inherit;
  outline: none;
  margin-top: 8px;
  transition: border-color 0.2s;
}

.note-input:focus { border-color: var(--info); }

/* Confirm modal */
.confirm-modal {
  max-width: 420px;
}

.confirm-modal .modal-body {
  text-align: center;
}

.confirm-modal .confirm-buttons {
  display: flex;
  gap: 10px;
  justify-content: center;
  margin-top: 16px;
}

.confirm-modal .confirm-buttons button {
  padding: 10px 24px;
  border: none;
  border-radius: 6px;
  font-weight: 600;
  cursor: pointer;
  font-family: inherit;
  font-size: 0.9rem;
}

.btn-cancel {
  background: var(--bg);
  color: var(--text);
  border: 2px solid var(--border) !important;
}

.btn-cancel:hover { background: var(--border); }
