/* WOW App — mobile-first styles */

body {
  background: #f0f2f5;
  font-size: 16px;
}

#app-wrap {
  max-width: 440px;
  margin: 0 auto;
  padding: 0 0 80px;
}

/* Title bar */
.wow-topbar {
  position: sticky;
  top: 0;
  z-index: 100;
  background: #1a1a2e;
  color: #fff;
  padding: 14px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.wow-topbar .brand {
  font-size: 1.2rem;
  font-weight: 700;
  letter-spacing: 1px;
}
.wow-topbar .topbar-right {
  font-size: 0.85rem;
  opacity: 0.75;
}

/* Cards */
.wow-card {
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0,0,0,.08);
  padding: 20px 16px;
  margin: 16px 12px;
}

/* Balance badge */
.balance-row {
  display: flex;
  gap: 12px;
}
.balance-row .balance-wrap {
  flex: 1;
}
.balance-wrap {
  text-align: center;
  padding: 10px 0 4px;
}
.balance-label {
  font-size: 0.8rem;
  color: #666;
  text-transform: uppercase;
  letter-spacing: .5px;
}
.balance-amount {
  font-size: 2rem;
  font-weight: 700;
  color: #1a1a2e;
}
.balance-amount-loan {
  color: #dc3545;
}

/* Big full-width buttons */
.btn-wow {
  display: block;
  width: 100%;
  padding: 14px;
  font-size: 1rem;
  font-weight: 600;
  border-radius: 10px;
  border: none;
  margin-bottom: 10px;
  cursor: pointer;
  transition: opacity .15s;
}
.btn-wow:disabled {
  opacity: .55;
  cursor: not-allowed;
}
.btn-primary-wow  { background: #1a1a2e; color: #fff; }
.btn-success-wow  { background: #198754; color: #fff; }
.btn-danger-wow   { background: #dc3545; color: #fff; }
.btn-secondary-wow{ background: #6c757d; color: #fff; }
.btn-outline-wow  { background: transparent; border: 2px solid #1a1a2e; color: #1a1a2e; }

/* Inputs */
.form-control-wow {
  display: block;
  width: 100%;
  padding: 13px 12px;
  font-size: 1rem;
  border: 1.5px solid #ced4da;
  border-radius: 8px;
  margin-bottom: 12px;
  box-sizing: border-box;
  transition: border-color .15s;
}
.form-control-wow:focus {
  outline: none;
  border-color: #1a1a2e;
}
.form-label-wow {
  display: block;
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 4px;
  color: #333;
}

/* Alert/toast */
#alert-area {
  margin: 0 12px;
}
.wow-alert {
  padding: 12px 14px;
  border-radius: 8px;
  font-size: 0.9rem;
  margin-bottom: 8px;
}
.wow-alert-success { background: #d1e7dd; color: #0a3622; }
.wow-alert-danger  { background: #f8d7da; color: #58151c; }

/* Loading overlay */
#loading-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(255,255,255,.65);
  z-index: 999;
  align-items: center;
  justify-content: center;
}
#loading-overlay.active {
  display: flex;
}

/* Preview table */
.preview-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
}
.preview-table td {
  padding: 7px 4px;
  border-bottom: 1px solid #f0f0f0;
}
.preview-table td:last-child {
  text-align: right;
  font-weight: 600;
}
.preview-total td {
  font-size: 1.05rem;
  font-weight: 700;
  border-bottom: none;
  padding-top: 10px;
}

/* History rows */
.txn-row {
  border-bottom: 1px solid #f0f0f0;
  padding: 10px 0;
}
.txn-row:last-child { border-bottom: none; }
.txn-type {
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .5px;
  padding: 2px 7px;
  border-radius: 20px;
}
.txn-deposit    { background: #d1e7dd; color: #0a3622; }
.txn-withdrawal { background: #fff3cd; color: #664d03; }
.txn-amount     { font-size: 1.05rem; font-weight: 700; }
.txn-amount-withdrawal { color: #5bc0de; }
.txn-pending    { font-size: 0.78rem; font-weight: 700; color: #999; text-transform: uppercase; letter-spacing: .4px; margin-top: 2px; }
.txn-sent       { color: #198754; font-weight: 600; margin-top: 1px; }
.txn-detail     { font-size: 0.82rem; color: #555; margin-top: 2px; }

/* History pagination arrows */
.hist-arrow {
  position: absolute;
  top: 18px;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  background: #1a1a2e;
  color: #fff;
  border: none;
  border-radius: 50%;
  cursor: pointer;
  line-height: 1;
}
.hist-arrow-left  { left: 16px; }
.hist-arrow-right { right: 16px; }
.hist-arrow-disabled { background: transparent; pointer-events: none; }

/* Pending list (admin) */
.pending-row {
  border-bottom: 1px solid #f0f0f0;
  padding: 12px 0;
}
.pending-row:last-child { border-bottom: none; }
