/* ================================================================
   dashboard2.css  |  assets/css/dashboard2.css
   New dark-themed dashboard redesign
================================================================ */

:root {
  --db-bg: #f3f5f9;
  --db-card: #ffffff;
  --db-card2: #f8fafc;
  --db-accent: #4b38f5;
  --db-accent2: #6a5cff;
  --db-gold: #c9a227;
  --db-green: #00a878;
  --db-red: #e53935;
  --db-text: #021633;
  --db-muted: #64748b;
  --db-border: #e8eaf0;
  --db-radius: 18px;
}

/* ── DARK MODE variables ── */
.dark-mode {
  --db-bg: #0a0f1e !important;
  --db-card: #141929 !important;
  --db-card2: #1a2035 !important;
  --db-text: #ffffff !important;
  --db-muted: rgba(255, 255, 255, 0.55) !important;
  --db-border: rgba(255, 255, 255, 0.08) !important;
  --db-green: #00c896 !important;
  --db-red: #ff4d6d !important;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}
body {
  font-family: "Inter", sans-serif;
  background: var(--db-bg);
  color: var(--db-text);
  min-height: 100vh;
  padding-bottom: 80px;
}
a {
  text-decoration: none;
  color: inherit;
}

/* ── HEADER ── */
.db-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--db-card);
  border-bottom: 1px solid var(--db-border);
  padding: 0 20px;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
}
.db-header-inner {
  max-width: 1200px;
  margin: 0 auto;
  height: 60px;
  display: flex;
  align-items: center;
  gap: 12px;
}
.db-ham {
  background: none;
  border: none;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding: 6px;
  flex-shrink: 0;
}
.db-ham span {
  width: 22px;
  height: 2px;
  background: var(--db-text);
  border-radius: 2px;
  display: block;
  transition: background 0.3s;
}
.db-brand {
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 1;
}
.db-logo {
  height: 44px;
  width: auto;
  max-width: 120px;
  object-fit: contain;
  border-radius: 0;
  display: block;
}
.db-brand-name {
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--db-text);
  line-height: 1.2;
}
.db-notif {
  background: var(--db-bg);
  border: none;
  border-radius: 50%;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  position: relative;
  color: var(--db-text);
}
.notif-dot {
  width: 8px;
  height: 8px;
  background: var(--db-red);
  border-radius: 50%;
  position: absolute;
  top: 8px;
  right: 8px;
}

/* ── SLIDE MENU ── */
.db-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  z-index: 200;
}
.db-overlay.open {
  display: block;
}
.db-menu {
  position: fixed;
  top: 0;
  left: 0;
  width: 280px;
  height: 100%;
  background: var(--db-card);
  z-index: 201;
  padding: 24px 20px;
  transform: translateX(-100%);
  transition: transform 0.3s ease;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.db-menu.open {
  transform: translateX(0);
}
.db-menu-top {
  display: flex;
  align-items: center;
  gap: 12px;
}
.db-menu-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--db-accent);
}
.db-menu-name {
  font-weight: 700;
  font-size: 0.95rem;
}
.db-menu-email {
  font-size: 0.75rem;
  color: var(--db-muted);
  margin-top: 2px;
}
.db-menu-close {
  margin-left: auto;
  background: none;
  border: none;
  color: var(--db-muted);
  font-size: 1.2rem;
  cursor: pointer;
}
.db-menu-bal {
  background: linear-gradient(135deg, var(--db-accent), var(--db-accent2));
  border-radius: 14px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.db-menu-bal span {
  font-size: 0.75rem;
  opacity: 0.8;
}
.db-menu-bal strong {
  font-size: 1.4rem;
  font-weight: 800;
}
.db-menu-nav {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.db-menu-nav a {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border-radius: 12px;
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--db-muted);
  transition: 0.2s;
}
.db-menu-nav a:hover {
  background: rgba(255, 255, 255, 0.06);
  color: var(--db-text);
}
.db-menu-nav a .material-icons-outlined {
  font-size: 1.1rem;
}
.db-menu-toggles {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.db-toggle-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.85rem;
  color: var(--db-muted);
}
.db-switch-btn {
  background: var(--db-accent);
  color: white;
  border: none;
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 0.78rem;
  font-weight: 600;
  cursor: pointer;
  font-family: "Inter", sans-serif;
}
.db-logout {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--db-red);
  font-size: 0.88rem;
  font-weight: 600;
  padding: 12px 14px;
  border-radius: 12px;
  margin-top: auto;
  transition: 0.2s;
}
.db-logout:hover {
  background: rgba(255, 77, 109, 0.1);
}

/* ── MAIN ── */
.db-main {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 28px 32px;
  display: flex;
  flex-direction: column;
  gap: 28px;
}

/* ── HERO BALANCE ── */
.db-hero {
  background: linear-gradient(135deg, #1a2a6c, #2d1f6e 50%, #0a1a4e);
  border-radius: var(--db-radius);
  padding: 24px 20px 20px;
  margin-top: 16px;
  position: relative;
  overflow: hidden;
}
.db-hero::before {
  content: "";
  position: absolute;
  top: -40px;
  right: -40px;
  width: 140px;
  height: 140px;
  border-radius: 50%;
  background: rgba(75, 56, 245, 0.2);
  pointer-events: none;
}
.db-hero-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 20px;
}
.db-greeting {
  font-size: 1.1rem;
  font-weight: 700;
  color: #ffffff !important;
}
.db-welcome {
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.7) !important;
  margin-top: 2px;
}
.db-user-pic {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid rgba(255, 255, 255, 0.3);
  cursor: pointer;
}
.db-balance-box {
  margin-bottom: 20px;
}
.db-bal-label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 1px;
  margin-bottom: 6px;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.75) !important;
}
.db-total {
  font-family: "Sora", sans-serif;
  font-size: 2.4rem;
  font-weight: 800;
  line-height: 1;
  margin-bottom: 6px;
  color: #ffffff !important; /* always white — hero card is always dark */
}
.db-bal-sub {
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.65) !important;
}
.db-quick {
  display: flex;
  gap: 12px;
  justify-content: center;
}
.db-qbtn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  font-size: 0.72rem;
  color: #ffffff !important;
  flex: 1;
}
.db-qicon {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(10px);
  transition: 0.2s;
}
.db-qbtn:hover .db-qicon {
  background: rgba(255, 255, 255, 0.25);
}
.db-qicon .material-icons-outlined {
  font-size: 1.3rem;
}

/* ── SECTION HEADER ── */
.db-section-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 14px;
}
.db-section-head h3 {
  font-size: 1rem;
  font-weight: 700;
}
.db-see-all {
  font-size: 0.78rem;
  color: var(--db-accent2);
  font-weight: 600;
}

/* ── QUICK ACTIONS ── */
.db-actions-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}
.db-action-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  font-size: 0.7rem;
  color: var(--db-muted);
  text-align: center;
}
.db-action-icon {
  width: 52px;
  height: 52px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: 0.2s;
}
.db-action-icon:hover {
  transform: translateY(-3px);
}
.db-action-icon.blue {
  background: rgba(75, 56, 245, 0.2);
  color: #7c6fff;
}
.db-action-icon.purple {
  background: rgba(150, 80, 255, 0.2);
  color: #b56eff;
}
.db-action-icon.green {
  background: rgba(0, 200, 150, 0.2);
  color: #00c896;
}
.db-action-icon.gold {
  background: rgba(201, 162, 39, 0.2);
  color: #c9a227;
}
.db-action-icon .material-icons-outlined {
  font-size: 1.3rem;
}

/* ── ACCOUNTS ── */
.db-acct-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.db-acct-row {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--db-card);
  border-radius: 16px;
  padding: 16px;
  border: 1px solid var(--db-border);
  transition: 0.2s;
}
.db-acct-row:hover {
  border-color: rgba(75, 56, 245, 0.4);
}
.db-acct-icon {
  width: 44px;
  height: 44px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.db-acct-icon.blue {
  background: rgba(75, 56, 245, 0.2);
  color: #7c6fff;
}
.db-acct-icon.purple {
  background: rgba(150, 80, 255, 0.2);
  color: #b56eff;
}
.db-acct-icon.gold {
  background: rgba(201, 162, 39, 0.2);
  color: #c9a227;
}
.db-acct-icon .material-icons-outlined {
  font-size: 1.2rem;
}
.db-acct-info {
  flex: 1;
  min-width: 0;
}
.db-acct-name {
  font-size: 0.88rem;
  font-weight: 700;
  display: block;
}
.db-acct-num {
  font-size: 0.72rem;
  color: var(--db-muted);
  display: block;
  margin-top: 2px;
}
.db-acct-right {
  text-align: right;
  margin-right: 6px;
}
.db-acct-bal {
  font-size: 0.95rem;
  font-weight: 700;
  display: block;
}
.db-acct-tag {
  font-size: 0.68rem;
  color: var(--db-green);
  display: block;
  margin-top: 2px;
}
.db-chevron {
  color: var(--db-muted);
  font-size: 1.1rem !important;
}

/* ── ATM CARD with image + overlay ── */
.db-card-scroll {
  display: flex;
  gap: 16px;
  overflow-x: auto;
  padding-bottom: 6px;
  scrollbar-width: none;
}
.db-card-scroll::-webkit-scrollbar {
  display: none;
}

.db-atm-wrap {
  position: relative;
  min-width: 300px;
  flex-shrink: 0;
  border-radius: 16px;
  overflow: hidden;
  cursor: pointer;
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.35);
  transition: transform 0.3s;
}
.db-atm-wrap:hover {
  transform: translateY(-4px);
}
.db-atm-img {
  width: 100%;
  height: 185px;
  object-fit: cover;
  object-position: center;
  display: block;
}
.db-atm-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 12px 18px;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.75) 0%, transparent 100%);
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
}
.db-atm-name {
  font-size: 0.82rem;
  font-weight: 700;
  color: white !important;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.5);
}
.db-atm-visa {
  font-size: 0.65rem;
  color: rgba(255, 255, 255, 0.9);
  text-align: right;
  line-height: 1.3;
  text-shadow: 0 1px 4px rgba(0, 0, 0, 0.5);
}
.db-visa-word {
  font-size: 1.1rem;
  font-weight: 900;
  font-style: italic;
  display: block;
}

/* ── TRANSACTIONS ── */
.db-txns {
}
.history-card {
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--db-card);
  border-radius: 14px;
  padding: 14px 16px;
  margin-bottom: 10px;
  border: 1px solid var(--db-border);
}
.txn-icon {
  width: 42px;
  height: 42px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  font-weight: 700;
  flex-shrink: 0;
}
.txn-icon-credit {
  background: rgba(0, 168, 120, 0.12);
  color: var(--db-green);
} /* green down — money IN  */
.txn-icon-debit {
  background: rgba(229, 57, 53, 0.12);
  color: var(--db-red);
} /* red up   — money OUT */

/* Left section — takes all available space, text truncates */
.history-left {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 1;
  min-width: 0; /* critical — allows flex children to shrink below content size */
  overflow: hidden;
}
.history-text-col {
  flex: 1;
  min-width: 0;
  overflow: hidden;
}
.history-title {
  font-size: 0.88rem;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
  display: block;
}
.history-detail {
  font-size: 0.72rem;
  color: var(--db-muted);
  margin-top: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
  display: block;
}
.history-date {
  font-size: 0.65rem;
  color: var(--db-muted);
  margin-top: 3px;
  display: block;
}

/* Amount — fixed width on the right, never pushed away */
.txn-amount-col {
  flex-shrink: 0;
  text-align: right;
  min-width: 70px;
}
.txn-credit {
  color: var(--db-green);
  font-weight: 700;
  font-size: 0.88rem;
  display: block;
}
.txn-debit {
  color: var(--db-red);
  font-weight: 700;
  font-size: 0.88rem;
  display: block;
}
.db-empty {
  text-align: center;
  padding: 32px;
  color: var(--db-muted);
}
.db-empty .material-icons-outlined {
  font-size: 2rem;
  display: block;
  margin-bottom: 8px;
}

/* ── BOTTOM NAV ── */
.db-bottom-nav {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: var(--db-card);
  border-top: 1px solid var(--db-border);
  display: flex;
  align-items: center;
  justify-content: space-around;
  padding: 8px 0 max(12px, env(safe-area-inset-bottom));
  z-index: 50;
}
.db-nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  font-size: 0.62rem;
  color: var(--db-muted);
  min-width: 48px;
  transition: 0.2s;
}
.db-nav-item.active,
.db-nav-item:hover {
  color: var(--db-accent2);
}
.db-nav-item .material-icons-outlined {
  font-size: 1.3rem;
}
.db-nav-center {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--db-accent), var(--db-accent2));
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: -22px;
  box-shadow: 0 6px 20px rgba(75, 56, 245, 0.5);
}
.db-nav-center .material-icons-outlined {
  font-size: 1.4rem;
}

/* ── DARK MODE body override ── */
.dark-mode body,
body.dark-mode {
  background: var(--db-bg) !important;
  color: var(--db-text) !important;
}

/* ── SWITCH for toggles ── */
.switch {
  position: relative;
  display: inline-block;
  width: 42px;
  height: 22px;
}
.switch input {
  opacity: 0;
  width: 0;
  height: 0;
}
.slider {
  position: absolute;
  cursor: pointer;
  inset: 0;
  background: #444;
  border-radius: 22px;
  transition: 0.3s;
}
.slider:before {
  content: "";
  position: absolute;
  width: 16px;
  height: 16px;
  left: 3px;
  bottom: 3px;
  background: white;
  border-radius: 50%;
  transition: 0.3s;
}
input:checked + .slider {
  background: var(--db-accent);
}
input:checked + .slider:before {
  transform: translateX(20px);
}

/* ── MODAL (keep existing) ── */
.modal.hidden {
  display: none !important;
}
.modal {
  display: flex;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  z-index: 500;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.modal-box {
  background: var(--db-card);
  border-radius: 20px;
  padding: 28px;
  max-width: 400px;
  width: 100%;
}
.modal-box h2 {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 16px;
}
.modal-box input,
.modal-box select {
  width: 100%;
  padding: 10px 14px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--db-border);
  border-radius: 10px;
  color: white;
  font-family: "Inter", sans-serif;
  margin-bottom: 10px;
  outline: none;
  font-size: 0.9rem;
}
.modal-box button,
.regionBtn,
.accountTypeBtn {
  width: 100%;
  padding: 12px;
  background: var(--db-accent);
  color: white;
  border: none;
  border-radius: 12px;
  font-weight: 600;
  cursor: pointer;
  margin-bottom: 8px;
  font-family: "Inter", sans-serif;
}

/* ── RESPONSIVE ── */
/* ── DESKTOP LAYOUT (768px+) ── */
@media (min-width: 768px) {
  body {
    padding-bottom: 0;
  }

  /* Header expands fully */
  .db-header-inner {
    padding: 0 8px;
  }

  /* Hide mobile bottom nav on desktop */
  .db-bottom-nav {
    display: none;
  }

  /* Show hamburger menu as sidebar on desktop */
  .db-menu {
    position: fixed;
    top: 0;
    left: 0;
    width: 240px;
    height: 100%;
    transform: translateX(0) !important;
    border-right: 1px solid var(--db-border);
    box-shadow: none;
  }
  .db-overlay {
    display: none !important;
  }

  /* Push main content right of sidebar */
  .db-header {
    margin-left: 240px;
  }
  .db-main {
    margin-left: 240px;
    max-width: calc(1200px - 240px);
  }

  /* Hide hamburger button — menu always visible */
  .db-ham {
    display: none;
  }

  /* Hero card full width with better padding */
  .db-hero {
    padding: 32px 28px 24px;
    margin-top: 20px;
  }
  .db-total {
    font-size: 2.8rem;
  }

  /* Two column layout — accounts left, cards right */
  .db-desktop-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
  }

  /* Accounts + Quick Actions in left column, Cards + Transactions in right */
  .db-accounts,
  .db-actions {
    width: 100%;
  }

  /* Cards scroll wider */
  .db-atm-wrap {
    min-width: 340px;
  }

  /* Transactions table-like view */
  .history-card {
    padding: 16px 20px;
  }

  /* Quick actions 5 columns on desktop */
  .db-actions-grid {
    grid-template-columns: repeat(5, 1fr);
  }
}

/* ── LARGE DESKTOP (1024px+) ── */
@media (min-width: 1024px) {
  .db-main {
    display: grid;
    grid-template-columns: 1fr 400px;
    grid-template-rows: auto;
    column-gap: 28px;
  }

  /* Left column: hero + actions + accounts + transactions */
  .db-hero {
    grid-column: 1;
  }
  .db-actions {
    grid-column: 1;
  }
  .db-accounts {
    grid-column: 1;
  }
  .db-txns {
    grid-column: 1;
  }

  /* Right column: cards */
  .db-cards-section {
    grid-column: 2;
    grid-row: 1 / 5;
  }

  /* Cards stack vertically on right panel */
  .db-card-scroll {
    flex-direction: column;
    overflow-x: visible;
  }
  .db-atm-wrap {
    min-width: unset;
    width: 100%;
  }
  .db-atm-img {
    height: 200px;
  }
}

/* ── MOBILE (below 768px) ── */
@media (max-width: 767px) {
  .db-menu {
    transform: translateX(-100%);
  }
  .db-menu.open {
    transform: translateX(0);
  }
  .db-total {
    font-size: 2rem;
  }
  .db-actions-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
  }
  .db-action-icon {
    width: 44px;
    height: 44px;
  }
  .db-atm-wrap {
    min-width: calc(100vw - 56px);
  }
}

/* ── Business dashboard extras ── */
.db-back-btn {
  display: flex;
  align-items: center;
  color: var(--db-text);
  padding: 6px;
}
.db-back-btn .material-icons-outlined {
  font-size: 1.1rem;
}
.db-biz-badge {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(10px);
}
.db-biz-badge .material-icons-outlined {
  font-size: 1.4rem;
}

/* ── NOTIFICATION PANEL ── */
.notif-panel {
  position: fixed;
  top: 62px;
  right: 12px;
  width: 320px;
  max-height: 420px;
  background: var(--db-card);
  border-radius: 18px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.18);
  border: 1px solid var(--db-border);
  z-index: 300;
  overflow: hidden;
  display: none;
  flex-direction: column;
}
.notif-panel.open {
  display: flex;
}
.notif-panel-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px 18px 12px;
  border-bottom: 1px solid var(--db-border);
}
.notif-panel-head h4 {
  font-size: 0.9rem;
  font-weight: 700;
}
.notif-clear {
  font-size: 0.72rem;
  color: var(--db-accent2);
  cursor: pointer;
  font-weight: 600;
  background: none;
  border: none;
  font-family: "Inter", sans-serif;
}
.notif-list {
  overflow-y: auto;
  flex: 1;
  padding: 8px 0;
}
.notif-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 18px;
  border-bottom: 1px solid var(--db-border);
  transition: background 0.2s;
}
.notif-item:last-child {
  border-bottom: none;
}
.notif-item:hover {
  background: rgba(75, 56, 245, 0.05);
}
.notif-item.unread {
  background: rgba(75, 56, 245, 0.04);
}
.notif-dot-icon {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  font-size: 0.85rem;
}
.notif-dot-icon.credit {
  background: rgba(0, 168, 120, 0.15);
  color: var(--db-green);
}
.notif-dot-icon.debit {
  background: rgba(255, 77, 109, 0.12);
  color: var(--db-red);
}
.notif-dot-icon.info {
  background: rgba(75, 56, 245, 0.12);
  color: var(--db-accent2);
}
.notif-body {
  flex: 1;
  min-width: 0;
}
.notif-title {
  font-size: 0.82rem;
  font-weight: 700;
  margin-bottom: 2px;
}
.notif-desc {
  font-size: 0.72rem;
  color: var(--db-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.notif-time {
  font-size: 0.65rem;
  color: var(--db-muted);
  margin-top: 3px;
  display: block;
}
.notif-empty {
  text-align: center;
  padding: 32px 20px;
  color: var(--db-muted);
  font-size: 0.85rem;
}
.notif-badge {
  position: absolute;
  top: -4px;
  right: -4px;
  background: var(--db-red);
  color: white;
  font-size: 0.6rem;
  font-weight: 800;
  min-width: 20px;
  height: 20px;
  padding: 0 4px;
  border-radius: 10px;
  display: none; /* hidden until there are unread notifs */
  align-items: center;
  justify-content: center;
  border: 2px solid var(--db-card);
  letter-spacing: 0.3px;
}
.db-notif {
  position: relative;
}

/* ── Expandable account detail ── */
.db-acct-expandable {
  cursor: pointer;
}
.db-acct-expandable:hover {
  border-color: rgba(75, 56, 245, 0.3);
}
.db-expand-arrow {
  transition: transform 0.2s;
}

.db-acct-detail {
  display: none;
  background: var(--db-card2);
  border: 1px solid var(--db-border);
  border-top: none;
  border-radius: 0 0 16px 16px;
  padding: 0 16px;
  margin-top: -6px;
  margin-bottom: 10px;
  overflow: hidden;
  transition: all 0.3s ease;
}
.db-acct-detail.open {
  display: block;
  padding: 14px 16px;
}
.db-acct-detail-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 9px 0;
  border-bottom: 1px solid var(--db-border);
  font-size: 0.82rem;
}
.db-acct-detail-row:last-of-type {
  border-bottom: none;
}
.db-acct-detail-row span:first-child {
  color: var(--db-muted);
}
.db-acct-detail-row span:last-child {
  font-weight: 600;
}
.db-acct-detail-link {
  display: block;
  text-align: center;
  padding: 10px 0 4px;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--db-accent2);
}

/* ============================================================
   BUSINESS DASHBOARD — TRANSACTION ROWS
   ============================================================ */
#bizTxns {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.txn-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 4px;
  border-bottom: 1px solid var(--db-border, #eef0f4);
}
.txn-row:last-child {
  border-bottom: none;
}
.txn-left {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 1;
  min-width: 0;
}
.txn-dot {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.txn-dot.cr {
  background: #e6f9f3;
  color: #00a878;
} /* credit = green */
.txn-dot.db {
  background: #ffeef0;
  color: #e53935;
} /* debit = red */
.txn-info {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
  flex: 1;
}
.txn-info strong {
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--db-text, #1e1e2d);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.txn-info span {
  font-size: 0.74rem;
  color: var(--db-muted, #8b949e);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.txn-amt {
  font-size: 0.92rem;
  font-weight: 800;
  white-space: nowrap;
  flex-shrink: 0;
}
.txn-amt.cr {
  color: #00a878;
} /* credit = green */
.txn-amt.db {
  color: #e53935;
} /* debit = red */
.empty-txn {
  text-align: center;
  color: var(--db-muted, #8b949e);
  font-size: 0.85rem;
  padding: 24px 0;
}
