/**
 * My Wallet.
 *
 * The page wrapper is .bk-page itself (plus a .wallet-scope hook), not a new
 * class of its own -- exactly how subscriptions.html reuses it
 * (`class="bk-page pk-scope"`). .bk-state / .bk-btn / .bk-spinner all read
 * --bk-ink / --bk-thread / etc., which are only ever defined on `.bk-page,
 * .bk-drawer` in css/bookings.css; a wrapper under any other class name would
 * leave them unresolved. This file only supplies what that shared set does
 * not: the balance card and the transaction rows.
 */

/* ---------------------------------------------------------------- Balance */

.wallet-balance-card {
  background: linear-gradient(135deg, var(--primary-color) 0%, var(--accent-color) 100%);
  border-radius: 20px;
  padding: 26px 28px;
  color: #fff;
  margin-bottom: 32px;
  box-shadow: 0 12px 30px rgba(13, 59, 102, 0.25);
}

.wallet-balance-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 15px;
  color: rgba(255, 255, 255, 0.85);
  margin-bottom: 18px;
}

.wallet-balance-head i {
  font-size: 20px;
  color: rgba(255, 255, 255, 0.85);
}

.wallet-balance-loading,
.wallet-balance-error {
  display: flex;
  align-items: center;
  min-height: 44px;
}

.wallet-balance-loading .bk-spinner,
.wallet-balance-error .bk-btn {
  border-color: rgba(255, 255, 255, 0.4);
  color: #fff;
}

.wallet-balance-figure {
  display: flex;
  align-items: baseline;
  gap: 8px;
}

.wallet-balance-figure #walletBalanceAmount {
  font-family: var(--accent-font, serif);
  font-size: 40px;
  font-weight: 700;
  line-height: 1;
}

.wallet-balance-figure #walletBalanceCurrency {
  font-size: 18px;
  color: rgba(255, 255, 255, 0.9);
}

/* ------------------------------------------------------------ Transactions */

.wallet-section-title {
  font-size: 20px;
  font-weight: 600;
  color: #333;
  margin-bottom: 14px;
}

.wallet-tx-list {
  background: #fff;
  border: 1px solid #e0e0e0;
  border-radius: 12px;
  padding: 0 20px;
}

.wallet-tx-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 0;
  border-bottom: 1px solid #eee;
}

.wallet-tx-item:last-child {
  border-bottom: none;
}

.wallet-tx-icon {
  flex: 0 0 auto;
  width: 40px;
  height: 40px;
  border-radius: 11px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
}

.wallet-tx-icon.is-credit {
  background: rgba(47, 168, 160, 0.14);
  color: var(--accent-color);
}

.wallet-tx-icon.is-debit {
  background: rgba(230, 87, 87, 0.12);
  color: var(--error-color, #e65757);
}

.wallet-tx-body {
  flex: 1 1 auto;
  min-width: 0;
}

.wallet-tx-desc {
  font-size: 15px;
  font-weight: 500;
  color: #333;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.wallet-tx-date {
  font-size: 13px;
  color: #888;
  margin-top: 2px;
}

.wallet-tx-amount {
  flex: 0 0 auto;
  font-size: 15px;
  font-weight: 700;
  direction: ltr;
}

.wallet-tx-amount.is-credit {
  color: var(--accent-color);
}

.wallet-tx-amount.is-debit {
  color: var(--error-color, #e65757);
}

@media only screen and (max-width: 767px) {
  .wallet-balance-card {
    padding: 22px 20px;
  }

  .wallet-balance-figure #walletBalanceAmount {
    font-size: 32px;
  }

  .wallet-tx-list {
    padding: 0 14px;
  }
}
