/* ================================================================
   Klincheck – Main Stylesheet
   Professional Blue Fintech Theme
   ================================================================ */

/* ── Reset & Variables ─────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --primary:      #0b1829;
  --primary-light:#1648cc;
  --primary-dark: #060f1a;
  --accent:       #1648cc;
  --success:      #059669;
  --warning:      #d97706;
  --danger:       #dc2626;
  --info:         #0284c7;

  --bg:           #f3f6fc;
  --surface:      #ffffff;
  --border:       #dce4f5;
  --text:         #1a2440;
  --text-muted:   #7682a0;
  --text-light:   #a0aec0;

  --sidebar-w:    260px;
  --topbar-h:     60px;
  --radius:       8px;
  --shadow:       0 1px 3px rgba(0,0,0,.1), 0 1px 2px rgba(0,0,0,.06);
  --shadow-md:    0 4px 6px rgba(0,0,0,.07), 0 2px 4px rgba(0,0,0,.06);
  --shadow-lg:    0 10px 15px rgba(0,0,0,.1), 0 4px 6px rgba(0,0,0,.05);

  --font: 'Inter', system-ui, -apple-system, sans-serif;
}

[data-theme="dark"] {
  --bg:      #0f172a;
  --surface: #1e293b;
  --border:  #334155;
  --text:    #e2e8f0;
  --text-muted: #94a3b8;
}

html { font-size: 16px; scroll-behavior: smooth; }
body { font-family: var(--font); background: var(--bg); color: var(--text); line-height: 1.6; }

/* ── Scrollbar ─────────────────────────────────────────────────── */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 3px; }

/* ── Layout ────────────────────────────────────────────────────── */
.sidebar {
  position: fixed; top: 0; left: 0; bottom: 0; width: var(--sidebar-w);
  background: var(--primary); color: #fff; overflow-y: auto; z-index: 300;
  display: flex; flex-direction: column; transition: transform .25s ease;
}
.main-wrapper {
  margin-left: var(--sidebar-w);
  min-height: 100vh;
  display: flex; flex-direction: column;
}
.topbar {
  position: sticky; top: 0; z-index: 200;
  height: var(--topbar-h);
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  display: flex; align-items: center; padding: 0 1.5rem;
  gap: 1rem;
  box-shadow: var(--shadow);
}
.main-content { flex: 1; padding: 1.5rem; max-width: 1280px; width: 100%; }

/* ── Sidebar ───────────────────────────────────────────────────── */
.sidebar-header {
  padding: 1rem 1.25rem;
  border-bottom: 1px solid rgba(255,255,255,.1);
  display: flex; align-items: center; justify-content: space-between;
}
.sidebar-brand { color: #fff; text-decoration: none; display: flex; align-items: center; gap: .6rem; font-size: 1.1rem; font-weight: 700; }
.sidebar-brand i { font-size: 1.3rem; color: #60a5fa; }
.sidebar-close { display: none; background: none; border: none; color: rgba(255,255,255,.7); cursor: pointer; font-size: 1.1rem; }

.sidebar-user { padding: 1rem 1.25rem; border-bottom: 1px solid rgba(255,255,255,.1); display: flex; align-items: center; gap: .75rem; }
.sidebar-avatar { width: 38px; height: 38px; border-radius: 50%; background: rgba(255,255,255,.2); display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: .85rem; flex-shrink: 0; }
.sidebar-user-name { font-weight: 600; font-size: .9rem; }
.sidebar-user-bal { font-size: .78rem; color: #93c5fd; }

.sidebar-nav { padding: .5rem 0; flex: 1; }
.nav-section-title { font-size: .65rem; text-transform: uppercase; letter-spacing: 1px; color: rgba(255,255,255,.4); padding: .75rem 1.25rem .25rem; }
.nav-item { display: flex; align-items: center; gap: .6rem; padding: .55rem 1.25rem; color: rgba(255,255,255,.8); text-decoration: none; font-size: .875rem; transition: all .15s; }
.nav-item:hover, .nav-item.active { background: rgba(255,255,255,.1); color: #fff; }
.nav-item.active { border-left: 3px solid #60a5fa; }
.nav-item i { width: 18px; text-align: center; font-size: .9rem; }

/* ── Topbar ────────────────────────────────────────────────────── */
.topbar-toggle { background: none; border: none; cursor: pointer; color: var(--text-muted); font-size: 1.2rem; display: none; }
.topbar-title { font-weight: 600; font-size: 1rem; flex: 1; }
.topbar-right { display: flex; align-items: center; gap: .75rem; margin-left: auto; }
.d-none-sm { }

.theme-toggle { background: none; border: none; cursor: pointer; color: var(--text-muted); font-size: 1rem; padding: .4rem; border-radius: var(--radius); transition: .15s; }
.theme-toggle:hover { background: var(--bg); }

/* Notifications */
.notif-wrap, .user-menu-wrap { position: relative; }
.notif-btn, .user-menu-btn { background: none; border: none; cursor: pointer; color: var(--text-muted); font-size: 1rem; padding: .4rem .6rem; border-radius: var(--radius); display: flex; align-items: center; gap: .4rem; transition: .15s; }
.notif-btn:hover, .user-menu-btn:hover { background: var(--bg); color: var(--text); }
.notif-badge { position: absolute; top: 2px; right: 2px; background: var(--danger); color: #fff; border-radius: 99px; font-size: .65rem; padding: 0 4px; min-width: 16px; height: 16px; display: flex; align-items: center; justify-content: center; }
.user-avatar-sm { width: 28px; height: 28px; border-radius: 50%; background: var(--primary); color: #fff; display: flex; align-items: center; justify-content: center; font-size: .75rem; font-weight: 700; }
.dropdown-menu { position: absolute; right: 0; top: calc(100% + 4px); background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); box-shadow: var(--shadow-lg); min-width: 180px; z-index: 400; display: none; }
.dropdown-menu.show { display: block; }
.dropdown-menu a { display: flex; align-items: center; gap: .6rem; padding: .6rem 1rem; color: var(--text); text-decoration: none; font-size: .875rem; transition: .1s; }
.dropdown-menu a:hover { background: var(--bg); }
.dropdown-divider { border: none; border-top: 1px solid var(--border); margin: .25rem 0; }
.notif-dropdown { min-width: 300px; max-height: 400px; overflow-y: auto; }

/* ── Sidebar overlay (mobile) ──────────────────────────────────── */
.sidebar-overlay { display: none; position: fixed; inset: 0; background: rgba(0,0,0,.4); z-index: 250; }

/* ── Auth / Main layout ────────────────────────────────────────── */
.auth-body { background: var(--bg); min-height: 100vh; }
.auth-page { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 2rem 1rem; }
.auth-card { background: var(--surface); border-radius: 12px; box-shadow: var(--shadow-lg); padding: 2rem; width: 100%; max-width: 420px; }
.auth-logo { text-align: center; font-size: 1.5rem; font-weight: 800; color: var(--primary); margin-bottom: 1rem; }
.auth-logo i { color: var(--primary-light); margin-right: .3rem; }
.auth-title { text-align: center; font-size: 1.4rem; font-weight: 700; color: var(--text); margin-bottom: .25rem; }
.auth-subtitle { text-align: center; color: var(--text-muted); font-size: .875rem; margin-bottom: 1.5rem; }
.auth-divider { display: flex; align-items: center; gap: .75rem; color: var(--text-muted); font-size: .8rem; margin: 1rem 0; }
.auth-divider::before, .auth-divider::after { content: ''; flex: 1; border-top: 1px solid var(--border); }
.auth-footer-text { text-align: center; color: var(--text-muted); font-size: .875rem; margin-top: 1rem; }
.auth-footer-text a { color: var(--primary-light); text-decoration: none; font-weight: 600; }

/* ── Home page ─────────────────────────────────────────────────── */
.home-page { }
.home-nav { position: fixed; top: 0; left: 0; right: 0; z-index: 100; background: var(--primary); display: flex; align-items: center; justify-content: space-between; padding: 0 2rem; height: 64px; }
.home-nav .brand { color: #fff; text-decoration: none; font-size: 1.2rem; font-weight: 800; display: flex; align-items: center; gap: .5rem; }
.home-nav-links { display: flex; gap: .75rem; }
.hero { background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%); color: #fff; padding: 8rem 2rem 5rem; text-align: center; }
.hero h1 { font-size: 2.5rem; font-weight: 800; margin-bottom: 1rem; }
.hero p { font-size: 1.1rem; opacity: .9; margin-bottom: 2rem; max-width: 600px; margin-left: auto; margin-right: auto; }
.hero-actions { display: flex; gap: 1rem; justify-content: center; flex-wrap: wrap; }
.features { padding: 4rem 2rem; background: var(--bg); }
.features h2 { text-align: center; font-size: 1.8rem; font-weight: 700; margin-bottom: 2.5rem; }
.features-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 1.5rem; max-width: 1100px; margin: 0 auto; }
.feature-card { background: var(--surface); border-radius: var(--radius); padding: 1.75rem; box-shadow: var(--shadow); text-align: center; }
.feature-icon { width: 56px; height: 56px; border-radius: 50%; background: #ebf0ff; margin: 0 auto 1rem; display: flex; align-items: center; justify-content: center; }
.feature-icon i { font-size: 1.4rem; color: var(--primary-light); }
.feature-card h3 { font-size: 1rem; font-weight: 700; margin-bottom: .5rem; }
.feature-card p { font-size: .875rem; color: var(--text-muted); }
.home-footer { background: var(--primary); color: rgba(255,255,255,.7); text-align: center; padding: 1.5rem; font-size: .8rem; }
.container { max-width: 1200px; margin: 0 auto; }

/* ── Buttons ───────────────────────────────────────────────────── */
.btn { display: inline-flex; align-items: center; gap: .4rem; padding: .6rem 1.25rem; border-radius: var(--radius); font-size: .875rem; font-weight: 600; cursor: pointer; border: 2px solid transparent; text-decoration: none; transition: all .15s; white-space: nowrap; }
.btn-primary   { background: var(--primary); color: #fff; border-color: var(--primary); }
.btn-primary:hover { background: var(--primary-dark); border-color: var(--primary-dark); }
.btn-outline   { background: transparent; color: var(--primary); border-color: var(--primary); }
.btn-outline:hover { background: var(--primary); color: #fff; }
.btn-white     { background: #fff; color: var(--primary); border-color: #fff; }
.btn-white:hover { background: var(--bg); }
.btn-outline-white { background: transparent; color: #fff; border-color: #fff; }
.btn-outline-white:hover { background: rgba(255,255,255,.1); }
.btn-google    { background: #fff; color: #374151; border-color: var(--border); }
.btn-google:hover { background: var(--bg); }
.btn-google i  { color: #ea4335; }
.btn-block     { width: 100%; justify-content: center; }
.btn-lg        { padding: .75rem 1.75rem; font-size: 1rem; }
.btn-sm        { padding: .3rem .8rem; font-size: .8rem; }
.btn-primary-sm { @extend .btn; background: var(--primary); color: #fff; padding: .35rem .85rem; font-size: .8rem; border-radius: 6px; }
.btn-outline-sm { background: transparent; color: var(--primary); border: 1px solid var(--primary); padding: .35rem .85rem; font-size: .8rem; border-radius: 6px; cursor: pointer; font-weight: 600; text-decoration: none; display: inline-flex; align-items: center; gap: .3rem; }
.btn-green { background: var(--success); color: #fff; }
.btn-red   { background: var(--danger); color: #fff; }
.btn-icon  { background: none; border: none; cursor: pointer; padding: .3rem .5rem; color: var(--text-muted); border-radius: 4px; transition: .1s; font-size: .85rem; }
.btn-icon:hover { background: var(--bg); color: var(--text); }
.btn-icon.btn-danger { color: var(--danger); }
.btn-icon.btn-warn   { color: var(--warning); }
.btn-icon.btn-ok     { color: var(--success); }

.badge-admin { background: var(--primary); color: #fff; font-size: .75rem; padding: .25rem .75rem; border-radius: 99px; font-weight: 600; }
.badge-blue  { background: #dbeafe; color: var(--primary); font-size: .75rem; padding: .2rem .6rem; border-radius: 99px; }
.badge-gray  { background: #f1f5f9; color: var(--text-muted); font-size: .75rem; padding: .2rem .6rem; border-radius: 99px; }
.badge-credit { background: #dcfce7; color: #166534; }
.badge-debit  { background: #fee2e2; color: #991b1b; }

/* ── Forms ─────────────────────────────────────────────────────── */
.form-group { margin-bottom: 1rem; }
.form-group label { display: block; font-size: .8rem; font-weight: 600; color: var(--text); margin-bottom: .35rem; }
.form-control { width: 100%; padding: .55rem .75rem; border: 1px solid var(--border); border-radius: var(--radius); font-size: .875rem; color: var(--text); background: var(--surface); transition: border-color .15s; }
.form-control:focus { outline: none; border-color: var(--primary-light); box-shadow: 0 0 0 3px rgba(37,99,235,.1); }
.form-control:disabled { background: var(--bg); cursor: not-allowed; }
.form-control-sm { padding: .4rem .6rem; border: 1px solid var(--border); border-radius: 6px; font-size: .875rem; background: var(--surface); color: var(--text); }
.form-control-xs { width: 100px; padding: .3rem .5rem; border: 1px solid var(--border); border-radius: 6px; font-size: .8rem; }
.form-hint  { font-size: .75rem; color: var(--text-muted); margin-top: .25rem; }
.form-row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.form-row-3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: .75rem; }
.form-row-between { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1rem; font-size: .8rem; }
.req { color: var(--danger); }
.link-sm  { font-size: .8rem; color: var(--primary-light); text-decoration: none; cursor: pointer; background: none; border: none; }
.checkbox-label { display: flex; align-items: center; gap: .4rem; cursor: pointer; }
.input-icon-wrap { position: relative; }
.input-toggle-pw { position: absolute; right: .5rem; top: 50%; transform: translateY(-50%); background: none; border: none; cursor: pointer; color: var(--text-muted); padding: .25rem; }
.form-section-title { font-weight: 700; font-size: .85rem; color: var(--primary); text-transform: uppercase; letter-spacing: .5px; margin: 1.25rem 0 .5rem; border-bottom: 1px solid var(--border); padding-bottom: .35rem; }

textarea.form-control { resize: vertical; min-height: 80px; }

/* ── Cards ─────────────────────────────────────────────────────── */
.form-card { background: var(--surface); border-radius: var(--radius); padding: 1.5rem; box-shadow: var(--shadow); margin-bottom: 1.25rem; }
.form-card h3 { font-size: 1rem; font-weight: 700; margin-bottom: 1.25rem; color: var(--text); }
.form-card h4 { font-size: .9rem; font-weight: 600; margin: 1rem 0 .5rem; }

.two-col-form { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; }

/* ── Alerts ────────────────────────────────────────────────────── */
.alert { padding: .85rem 1rem; border-radius: var(--radius); margin-bottom: 1rem; font-size: .875rem; display: flex; align-items: flex-start; gap: .5rem; position: relative; }
.alert-success { background: #f0fdf4; color: #166534; border-left: 3px solid var(--success); }
.alert-error   { background: #fef2f2; color: #991b1b; border-left: 3px solid var(--danger); }
.alert-info    { background: #ebf0ff; color: #1e40af; border-left: 3px solid var(--info); }
.alert-warning { background: #fffbeb; color: #92400e; border-left: 3px solid var(--warning); }
.alert-close   { position: absolute; right: .75rem; top: .5rem; background: none; border: none; cursor: pointer; opacity: .5; }
.alert-close:hover { opacity: 1; }

/* ── Dashboard ─────────────────────────────────────────────────── */
.page-header { margin-bottom: 1.5rem; }
.page-header h1 { font-size: 1.5rem; font-weight: 800; color: var(--text); }
.page-header p  { color: var(--text-muted); font-size: .9rem; margin-top: .2rem; }
.header-actions { display: flex; gap: .5rem; }

.dashboard-top-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1.25rem; margin-bottom: 1.5rem; }

.wallet-card { background: linear-gradient(135deg, var(--primary), var(--primary-light)); color: #fff; border-radius: 12px; padding: 1.5rem; }
.wallet-label  { font-size: .8rem; opacity: .8; margin-bottom: .35rem; }
.wallet-amount { font-size: 2rem; font-weight: 800; margin-bottom: 1rem; }
.wallet-actions { display: flex; gap: .75rem; }
.btn-white-sm { background: rgba(255,255,255,.2); color: #fff; border: 1px solid rgba(255,255,255,.3); padding: .35rem .85rem; border-radius: 6px; font-size: .8rem; font-weight: 600; cursor: pointer; text-decoration: none; display: inline-flex; align-items: center; gap: .3rem; transition: .15s; }
.btn-white-sm:hover { background: rgba(255,255,255,.3); }
.btn-outline-white-sm { background: transparent; color: #fff; border: 1px solid rgba(255,255,255,.5); padding: .35rem .85rem; border-radius: 6px; font-size: .8rem; font-weight: 600; cursor: pointer; text-decoration: none; display: inline-flex; align-items: center; gap: .3rem; }

.account-card { background: var(--surface); border-radius: 12px; padding: 1.5rem; box-shadow: var(--shadow); }
.account-label   { font-size: .75rem; text-transform: uppercase; letter-spacing: .5px; color: var(--text-muted); margin-bottom: .5rem; }
.account-number  { font-size: 1.5rem; font-weight: 800; color: var(--primary); letter-spacing: 2px; }
.account-bank    { font-weight: 600; margin: .25rem 0; }
.account-name    { color: var(--text-muted); font-size: .875rem; }
.account-hint    { font-size: .75rem; color: var(--text-light); display: block; margin-top: .75rem; }
.account-card-empty { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .75rem; min-height: 140px; }
.account-card-empty i { font-size: 2rem; color: var(--text-light); }
.account-card-empty p { color: var(--text-muted); }

.stats-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; margin-bottom: 1.5rem; }
.stats-grid-4 { grid-template-columns: repeat(4, 1fr); }
.stat-card { background: var(--surface); border-radius: var(--radius); padding: 1.25rem; box-shadow: var(--shadow); display: flex; align-items: center; gap: 1rem; }
.stat-icon { width: 48px; height: 48px; border-radius: 10px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.stat-icon i { font-size: 1.2rem; color: #fff; }
.stat-value { font-size: 1.4rem; font-weight: 800; }
.stat-label { font-size: .75rem; color: var(--text-muted); margin-top: .1rem; }
.bg-blue   { background: var(--primary-light); }
.bg-green  { background: var(--success); }
.bg-orange { background: var(--warning); }
.bg-red    { background: var(--danger); }
.bg-purple { background: #8b5cf6; }
.bg-teal   { background: #0d9488; }
.bg-navy   { background: var(--primary); }

.section-header { margin: 1.5rem 0 .75rem; }
.section-header h2, .section-header h3 { font-size: 1.1rem; font-weight: 700; }

.services-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 1rem; margin-bottom: 1.5rem; }
.service-card  { background: var(--surface); border-radius: var(--radius); padding: 1.25rem 1rem; box-shadow: var(--shadow); text-align: center; text-decoration: none; color: var(--text); transition: .15s; }
.service-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); }
.service-icon  { width: 48px; height: 48px; border-radius: 50%; background: #ebf0ff; margin: 0 auto .75rem; display: flex; align-items: center; justify-content: center; }
.service-icon i { font-size: 1.2rem; color: var(--primary-light); }
.service-name  { font-size: .8rem; font-weight: 600; margin-bottom: .2rem; }
.service-price { font-size: .72rem; color: var(--text-muted); }

.dashboard-two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 1.25rem; }
.recent-card { background: var(--surface); border-radius: var(--radius); padding: 1.25rem; box-shadow: var(--shadow); }
.card-header-row { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1rem; }
.card-header-row h3 { font-size: .95rem; font-weight: 700; }

.txn-list { }
.txn-item { display: flex; align-items: center; gap: .75rem; padding: .6rem 0; border-bottom: 1px solid var(--border); }
.txn-item:last-child { border-bottom: none; }
.txn-icon { width: 34px; height: 34px; border-radius: 50%; display: flex; align-items: center; justify-content: center; flex-shrink: 0; font-size: .85rem; }
.txn-credit i { color: var(--success); }
.txn-debit  i { color: var(--danger); }
.txn-icon.txn-credit { background: #dcfce7; }
.txn-icon.txn-debit  { background: #fee2e2; }
.txn-info { flex: 1; min-width: 0; }
.txn-desc { font-size: .825rem; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.txn-ref  { font-size: .72rem; color: var(--text-muted); font-family: monospace; }
.txn-right { text-align: right; flex-shrink: 0; }
.txn-amount { font-size: .875rem; font-weight: 700; }
.txn-amount.txn-credit { color: var(--success); }
.txn-amount.txn-debit  { color: var(--danger); }
.txn-status { font-size: .7rem; }

.notif-item { display: flex; align-items: flex-start; gap: .6rem; padding: .6rem 0; border-bottom: 1px solid var(--border); }
.notif-item:last-child { border-bottom: none; }
.notif-item.unread { background: #f8faff; border-radius: 4px; padding: .6rem .5rem; }
.notif-dot  { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; margin-top: 5px; }
.notif-info  { background: var(--info); }
.notif-success { background: var(--success); }
.notif-warning { background: var(--warning); }
.notif-error   { background: var(--danger); }
.notif-title { font-size: .825rem; font-weight: 600; }
.notif-msg   { font-size: .78rem; color: var(--text-muted); }
.notif-time  { font-size: .7rem; color: var(--text-light); }

/* ── Tables ────────────────────────────────────────────────────── */
.table-card { background: var(--surface); border-radius: var(--radius); box-shadow: var(--shadow); overflow: auto; }
.data-table { width: 100%; border-collapse: collapse; font-size: .875rem; }
.data-table th { background: var(--bg); font-weight: 600; font-size: .75rem; text-transform: uppercase; letter-spacing: .4px; color: var(--text-muted); padding: .75rem 1rem; text-align: left; border-bottom: 1px solid var(--border); white-space: nowrap; }
.data-table td { padding: .7rem 1rem; border-bottom: 1px solid var(--border); vertical-align: middle; }
.data-table tr:last-child td { border-bottom: none; }
.data-table tr:hover td { background: var(--bg); }
.table-empty { text-align: center; color: var(--text-muted); padding: 2rem !important; }
.actions-cell { white-space: nowrap; }

.admin-response-row td { padding: 0 !important; }
.admin-response-box { background: #f0fdf4; border-left: 3px solid var(--success); padding: .6rem 1rem; font-size: .8rem; }
.attachment-link { color: var(--primary-light); text-decoration: none; margin-left: .5rem; font-size: .8rem; }

/* Status badges */
.status-badge { font-size: .7rem; font-weight: 600; padding: .2rem .6rem; border-radius: 99px; display: inline-block; }
.status-success, .status-completed { background: #dcfce7; color: #166534; }
.status-pending                    { background: #fef9c3; color: #854d0e; }
.status-failed                     { background: #fee2e2; color: #991b1b; }
.status-in_progress, .status-processing { background: #dbeafe; color: #1e40af; }

.badge-credit { background: #dcfce7; color: #166534; font-size: .7rem; padding: .2rem .6rem; border-radius: 99px; }
.badge-debit  { background: #fee2e2; color: #991b1b; font-size: .7rem; padding: .2rem .6rem; border-radius: 99px; }

/* ── Filters / Pagination ──────────────────────────────────────── */
.filter-bar { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-bottom: 1rem; flex-wrap: wrap; }
.total-count { font-size: .8rem; color: var(--text-muted); }
.pagination  { display: flex; gap: .35rem; justify-content: center; margin-top: 1.25rem; flex-wrap: wrap; }
.page-btn    { padding: .4rem .75rem; border-radius: 6px; text-decoration: none; font-size: .8rem; color: var(--text-muted); border: 1px solid var(--border); background: var(--surface); transition: .1s; }
.page-btn.active { background: var(--primary); color: #fff; border-color: var(--primary); }
.page-btn:hover:not(.active) { background: var(--bg); }

/* ── Result cards ──────────────────────────────────────────────── */
.result-card { background: var(--surface); border-radius: var(--radius); padding: 1.5rem; box-shadow: var(--shadow); margin-bottom: 1.25rem; }
.result-success { border-left: 4px solid var(--success); }
.result-error   { border-left: 4px solid var(--danger); }
.result-header  { font-size: 1rem; font-weight: 700; display: flex; align-items: center; gap: .5rem; margin-bottom: 1rem; }
.result-header i { color: var(--success); font-size: 1.1rem; }
.result-photo { width: 100px; height: 100px; border-radius: 50%; object-fit: cover; border: 3px solid var(--border); display: block; margin: 0 auto 1rem; }
.result-grid  { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: .75rem; }
.result-field span  { font-size: .72rem; text-transform: uppercase; color: var(--text-muted); letter-spacing: .3px; display: block; margin-bottom: .15rem; }
.result-field strong { font-size: .875rem; color: var(--text); }
.result-actions { display: flex; gap: .75rem; margin-top: 1rem; flex-wrap: wrap; }
.result-ref { font-size: .75rem; color: var(--text-muted); margin-top: .75rem; }

/* ── Wallet / Account info box ─────────────────────────────────── */
.account-info-box { background: var(--bg); border-radius: var(--radius); padding: 1rem; margin-bottom: 1rem; }
.account-info-row { display: flex; justify-content: space-between; padding: .45rem 0; border-bottom: 1px solid var(--border); font-size: .875rem; }
.account-info-row:last-child { border-bottom: none; }
.info-note { font-size: .8rem; color: var(--text-muted); display: flex; align-items: flex-start; gap: .4rem; }
.info-note i { color: var(--info); flex-shrink: 0; margin-top: 2px; }
.balance-note { font-size: .82rem; color: var(--text-muted); margin-bottom: 1rem; }
.balance-note strong { color: var(--text); }
.price-display { background: #ebf0ff; border-radius: 6px; padding: .6rem .85rem; font-size: .82rem; margin-bottom: 1rem; color: var(--primary); }

/* ── Quick amounts ─────────────────────────────────────────────── */
.quick-amounts { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: 1rem; }
.quick-amt-btn { padding: .35rem .8rem; border: 1px solid var(--primary); border-radius: 6px; background: transparent; color: var(--primary); font-size: .8rem; font-weight: 600; cursor: pointer; transition: .15s; }
.quick-amt-btn:hover { background: var(--primary); color: #fff; }

/* ── Tabs ──────────────────────────────────────────────────────── */
.tab-bar { display: flex; gap: .5rem; margin-bottom: 1rem; border-bottom: 2px solid var(--border); }
.tab-btn { padding: .6rem 1.25rem; background: none; border: none; cursor: pointer; font-size: .875rem; font-weight: 600; color: var(--text-muted); border-bottom: 2px solid transparent; margin-bottom: -2px; transition: .15s; }
.tab-btn.active { color: var(--primary); border-bottom-color: var(--primary); }

/* ── Modals ────────────────────────────────────────────────────── */
.modal-backdrop { position: fixed; inset: 0; background: rgba(0,0,0,.5); z-index: 500; display: flex; align-items: center; justify-content: center; padding: 1rem; }
.modal-box { background: var(--surface); border-radius: 12px; padding: 1.75rem; width: 100%; max-width: 500px; max-height: 90vh; overflow-y: auto; position: relative; box-shadow: var(--shadow-lg); }
.modal-lg  { max-width: 650px; }
.modal-close { position: absolute; top: 1rem; right: 1rem; background: none; border: none; cursor: pointer; color: var(--text-muted); font-size: 1.1rem; }
.modal-actions { display: flex; gap: .75rem; justify-content: flex-end; margin-top: 1.25rem; flex-wrap: wrap; }
.modal-icon { text-align: center; font-size: 2.5rem; color: var(--primary-light); margin-bottom: .75rem; }
.modal-request-info { background: var(--bg); border-radius: 6px; padding: .5rem .75rem; font-size: .8rem; margin-bottom: 1rem; color: var(--text-muted); }

/* ── Charts ────────────────────────────────────────────────────── */
.chart-card { background: var(--surface); border-radius: var(--radius); padding: 1.25rem; box-shadow: var(--shadow); }

/* ── Misc helpers ──────────────────────────────────────────────── */
.empty-state { text-align: center; padding: 2.5rem 1rem; color: var(--text-muted); }
.empty-state i { font-size: 2.5rem; display: block; margin-bottom: .75rem; opacity: .4; }
.info-box { border-radius: var(--radius); padding: .75rem 1rem; margin-bottom: 1rem; font-size: .875rem; display: flex; align-items: flex-start; gap: .5rem; }
.info-blue { background: #ebf0ff; color: #1e40af; border-left: 3px solid var(--info); }
.benefit-list { list-style: none; margin: .75rem 0 1.5rem; }
.benefit-list li { padding: .3rem 0; font-size: .875rem; display: flex; align-items: center; gap: .5rem; }
.info-icon-header { text-align: center; font-size: 2.5rem; color: var(--primary-light); margin-bottom: .75rem; }

.text-green { color: var(--success); }
.text-red   { color: var(--danger); }
.mt-2 { margin-top: .5rem; }

code { font-family: monospace; background: var(--bg); padding: .1rem .35rem; border-radius: 4px; font-size: .8rem; }

.network-input-wrap { position: relative; }
.network-badge { position: absolute; right: .6rem; top: 50%; transform: translateY(-50%); font-size: .7rem; font-weight: 700; color: var(--primary); background: #ebf0ff; padding: .1rem .4rem; border-radius: 4px; }
.network-tag { font-size: .7rem; font-weight: 700; padding: .2rem .5rem; border-radius: 4px; }
.network-mtn    { background: #fef9c3; color: #854d0e; }
.network-airtel { background: #fee2e2; color: #991b1b; }
.network-glo    { background: #dcfce7; color: #166534; }
.network-9mobile { background: #e0f2fe; color: #0c4a6e; }

.director-block { border: 1px solid var(--border); border-radius: var(--radius); padding: 1rem; margin-bottom: .75rem; }
.director-header { font-weight: 700; font-size: .875rem; margin-bottom: .75rem; display: flex; justify-content: space-between; align-items: center; }
.row-highlight { background: #f0fff4 !important; }
.api-cred-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 1rem; }
.toggle-label { display: flex; align-items: center; gap: .4rem; font-size: .8rem; cursor: pointer; }

/* ── Error pages ───────────────────────────────────────────────── */
.error-page { text-align: center; padding: 4rem 2rem; }
.error-code  { font-size: 6rem; font-weight: 900; color: var(--primary); line-height: 1; }
.error-title { font-size: 1.5rem; font-weight: 700; margin: .5rem 0 1rem; }

/* ── Admin sidebar override ────────────────────────────────────── */
.admin-sidebar { background: #060f1a; }
.admin-body { background: #f1f5f9; }

/* ── Responsive ────────────────────────────────────────────────── */
@media (max-width: 1024px) {
  .stats-grid-4 { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 768px) {
  .sidebar { transform: translateX(-100%); }
  .sidebar.open { transform: translateX(0); }
  .sidebar-close { display: block; }
  .sidebar-overlay.show { display: block; }
  .topbar-toggle { display: block; }
  .main-wrapper { margin-left: 0; }
  .d-none-sm { display: none; }

  .dashboard-top-grid { grid-template-columns: 1fr; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .two-col-form { grid-template-columns: 1fr; }
  .dashboard-two-col { grid-template-columns: 1fr; }
  .form-row-2 { grid-template-columns: 1fr; }
  .form-row-3 { grid-template-columns: 1fr; }
  .hero h1 { font-size: 1.75rem; }

  .home-nav { padding: 0 1rem; }
  .main-content { padding: 1rem; }
}
@media (max-width: 480px) {
  .stats-grid { grid-template-columns: 1fr; }
  .services-grid { grid-template-columns: repeat(2, 1fr); }
  .hero-actions { flex-direction: column; align-items: center; }
}
