:root {
    --red: #E53935;
    --red-dark: #C62828;
    --bg: #f3f5f8;
    --card: #fff;
    --text: #1c1f26;
    --muted: #6b7280;
    --border: #e6e8ee;
    --sidebar: #12141a;
    --sidebar-text: #d5d8e0;
    --shadow: 0 1px 2px rgba(16, 24, 40, .04), 0 8px 24px rgba(16, 24, 40, .04);
}
* { box-sizing: border-box; }
body { margin: 0; font-family: "Segoe UI", system-ui, -apple-system, sans-serif; background: var(--bg); color: var(--text); }
.hidden { display: none !important; }

.admin-login {
    min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 24px;
    background:
        radial-gradient(900px 420px at 0% 0%, rgba(229,57,53,.28), transparent 55%),
        radial-gradient(700px 380px at 100% 100%, rgba(229,57,53,.16), transparent 50%),
        linear-gradient(165deg, #12141a 0%, #1c2028 58%, #2a181b 100%);
}
.admin-login-card {
    background: #fff; border-radius: 20px; padding: 36px 32px 28px; width: 100%; max-width: 420px;
    box-shadow: 0 24px 60px rgba(0,0,0,.32);
}
.admin-login-mark {
    width: 56px; height: 56px; margin: 0 auto 14px; border-radius: 16px;
    background: var(--red); color: #fff; display: flex; align-items: center; justify-content: center;
    font-weight: 800; font-size: 1.45rem;
}
.admin-login-card h1 { margin: 0; color: var(--red); text-align: center; letter-spacing: 3px; font-size: 1.7rem; }
.admin-sub { text-align: center; color: var(--muted); margin: 6px 0 28px; }
.admin-login-card label { font-weight: 600; color: #424242; }
.admin-login-card input:focus {
    outline: none; border-color: var(--red); box-shadow: 0 0 0 3px rgba(229,57,53,.16);
}
.login-field { position: relative; }
.login-field input { padding-right: 44px; }
.login-toggle {
    position: absolute; right: 6px; top: 5px; width: 32px; height: 32px;
    border: none; background: transparent; color: #6b7280; cursor: pointer;
    display: flex; align-items: center; justify-content: center; padding: 0; border-radius: 8px;
}
.login-toggle:hover { color: var(--text); background: #f3f4f6; }
.field-icon { position: relative; }
.field-leading {
    position: absolute; left: 12px; top: 12px; color: #9ca3af; pointer-events: none;
    display: flex;
}
.with-leading { padding-left: 40px; }
.admin-login-card .btn-primary { margin-top: 4px; padding: 12px 16px; }
.admin-login-card .btn-primary:disabled { opacity: .65; cursor: progress; }
.admin-hint { font-size: .8rem; color: var(--muted); text-align: center; margin: 16px 0 0; line-height: 1.4; }
.admin-error { color: var(--red); font-size: .9rem; margin-top: 12px; text-align: center; line-height: 1.4; }
code { background: #f0f0f0; padding: 2px 6px; border-radius: 4px; font-size: .85em; }

label { display: block; font-size: .8rem; font-weight: 600; color: #374151; margin-bottom: 6px; }
input, select, textarea {
    width: 100%; min-height: 42px; padding: 10px 12px; border: 1px solid #d8dbe3;
    border-radius: 10px; font: inherit; font-size: .95rem; margin-bottom: 14px;
    background: #fff; color: var(--text); transition: border-color .15s, box-shadow .15s;
}
textarea { min-height: 96px; resize: vertical; }
input:focus, select:focus, textarea:focus {
    outline: none; border-color: #e7a3a1; box-shadow: 0 0 0 3px rgba(229,57,53,.12);
}
input:disabled, select:disabled, textarea:disabled { background: #f3f4f6; color: #6b7280; }
select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' stroke='%236b7280' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 6l4 4 4-4'/%3E%3C/svg%3E");
    background-repeat: no-repeat; background-position: right 12px center; padding-right: 36px;
}
.banner-thumb { width: 96px; height: 48px; object-fit: cover; border-radius: 8px; background: var(--line, #eee); display: block; }
input[type="checkbox"] { width: 16px; min-height: 16px; margin: 3px 0 0; padding: 0; accent-color: var(--red); }

.ico { width: 18px; height: 18px; display: block; stroke: currentColor; fill: none; stroke-width: 1.75; stroke-linecap: round; stroke-linejoin: round; }
.nav-ico { display: inline-flex; flex-shrink: 0; opacity: .8; }
.nav-item.active .nav-ico, .nav-item:hover .nav-ico { opacity: 1; }
.nav-text { flex: 1; min-width: 0; }

.btn {
    border: none; border-radius: 10px; padding: 10px 16px;
    font-size: .92rem; font-weight: 600; cursor: pointer;
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
}
.btn-primary { background: var(--red); color: #fff; }
.btn-primary:hover { background: var(--red-dark); }
.admin-login-card .btn-primary { width: 100%; }
.btn-secondary { background: #fff; border: 1px solid var(--border); color: var(--text); }
.btn-ghost { background: transparent; color: var(--sidebar-text); border: 1px solid rgba(255,255,255,.16); width: 100%; }
.btn-sm { padding: 6px 10px; font-size: .8rem; }
.btn-sm .ico { width: 14px; height: 14px; }
.btn-danger { background: #ffebee; color: var(--red); border: 1px solid #ffcdd2; }
.btn-success { background: #e8f5e9; color: #2e7d32; border: 1px solid #c8e6c9; }
.btn:disabled { opacity: .65; cursor: progress; }
.btn:focus-visible, .nav-item:focus-visible, .stat-card:focus-visible { outline: 2px solid var(--red); outline-offset: 2px; }

.admin-shell { display: flex; min-height: 100vh; }
.admin-sidebar {
    width: 252px; background: var(--sidebar); color: var(--sidebar-text);
    display: flex; flex-direction: column; padding: 18px 12px 12px; flex-shrink: 0;
}
.admin-brand { display: flex; align-items: center; gap: 12px; padding: 6px 10px 18px; }
.brand-mark {
    width: 36px; height: 36px; border-radius: 10px; background: var(--red); color: #fff;
    display: flex; align-items: center; justify-content: center; font-weight: 800;
}
.brand-text { display: flex; flex-direction: column; line-height: 1.15; }
.brand-text strong { color: #fff; font-size: 1rem; }
.brand-text span { color: #9aa0ab; font-size: .75rem; }
.admin-sidebar nav { flex: 1; display: flex; flex-direction: column; gap: 2px; overflow: auto; padding-right: 2px; }
.nav-label {
    margin: 14px 12px 6px; font-size: .68rem; font-weight: 700; letter-spacing: .08em;
    text-transform: uppercase; color: #8b919c;
}
.nav-item {
    border: none; background: transparent; color: var(--sidebar-text);
    text-align: left; padding: 9px 12px; border-radius: 8px; cursor: pointer;
    font-size: .9rem; text-decoration: none; display: flex; align-items: center; justify-content: flex-start; gap: 10px;
}
.nav-item:hover, .nav-item.active { background: rgba(229,57,53,.18); color: #fff; }
.nav-badge {
    margin-left: auto;
    min-width: 20px; height: 20px; padding: 0 6px; border-radius: 999px;
    background: var(--red); color: #fff; font-size: .7rem; font-weight: 700;
    display: inline-flex; align-items: center; justify-content: center;
}
.admin-sidebar-foot { padding: 12px 8px 4px; border-top: 1px solid rgba(255,255,255,.08); margin-top: 12px; }
.admin-user { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.admin-avatar {
    width: 36px; height: 36px; border-radius: 50%; background: rgba(229,57,53,.22); color: #fff;
    display: flex; align-items: center; justify-content: center; font-weight: 700; flex-shrink: 0;
}
.admin-user-name { font-size: .84rem; opacity: .95; display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.admin-user-mail { font-size: .72rem; opacity: .7; word-break: break-all; }
.admin-support-mail {
    display: block; margin: 0 0 10px; padding: 8px 10px; border-radius: 10px;
    color: #ffcdd2; text-decoration: none; font-size: .78rem; word-break: break-all;
    background: rgba(229,57,53,.16); border: 1px solid rgba(229,57,53,.28);
}
.admin-support-mail:hover { color: #fff; background: rgba(229,57,53,.28); }

.admin-main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.admin-topbar {
    background: rgba(255,255,255,.92); border-bottom: 1px solid var(--border);
    padding: 14px 24px; display: flex; align-items: center; gap: 14px;
    position: sticky; top: 0; z-index: 5; backdrop-filter: blur(8px);
}
.topbar-text { flex: 1; min-width: 0; }
.admin-topbar h2 { margin: 0; font-size: 1.2rem; letter-spacing: -.02em; }
.admin-topbar p { margin: 2px 0 0; color: var(--muted); font-size: .84rem; }
.btn-menu {
    display: none; width: 40px; height: 40px; border: 1px solid var(--border); border-radius: 10px;
    background: #fff; padding: 10px 9px; flex-direction: column; justify-content: space-between; cursor: pointer;
}
.btn-menu span { display: block; height: 2px; background: var(--text); border-radius: 2px; }
.sidebar-backdrop { position: fixed; inset: 0; background: rgba(15, 18, 24, .48); z-index: 20; }
.admin-content { padding: 24px; flex: 1; }

.stats-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin-bottom: 16px; }
.stat-card {
    background: var(--card); border: 1px solid var(--border); border-radius: 14px; padding: 16px;
    box-shadow: var(--shadow); display: flex; flex-direction: column; gap: 8px; min-height: 118px;
}
button.stat-card { font: inherit; text-align: left; color: inherit; cursor: pointer; width: 100%; }
button.stat-card:hover { border-color: #f0b4b2; transform: translateY(-1px); }
.stat-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.stat-ico {
    width: 34px; height: 34px; border-radius: 10px; background: #f4f5f7; color: #374151;
    display: inline-flex; align-items: center; justify-content: center; order: 2;
}
.stat-label { font-size: .84rem; font-weight: 600; color: #4b5563; }
.stat-val { font-size: 1.7rem; font-weight: 700; letter-spacing: -.03em; line-height: 1.1; }
.stat-hint { font-size: .8rem; color: var(--muted); margin-top: auto; }
.stat-card-alert { background: #fff8f8; border-color: #ffcdd2; }
.stat-card-alert .stat-val, .stat-card-alert .stat-ico { color: var(--red-dark); }
.stat-card-alert .stat-ico { background: #ffebee; }
.notice-banner {
    width: 100%; display: flex; justify-content: space-between; align-items: center; gap: 12px;
    margin-bottom: 16px; padding: 14px 16px; border: 0; border-radius: 14px; cursor: pointer;
    background: #1c1f26; color: #fff; text-align: left; font: inherit;
}
.notice-banner strong { display: flex; align-items: center; gap: 10px; }
.notice-banner span { color: #f3b4b2; font-size: .88rem; }
.dash-layout { display: grid; grid-template-columns: minmax(0, 1.7fr) minmax(240px, .85fr); gap: 16px; align-items: start; }
.quick-list { display: flex; flex-direction: column; gap: 8px; }
.quick-list .btn { justify-content: flex-start; width: 100%; }

.admin-card { background: var(--card); border: 1px solid var(--border); border-radius: 14px; padding: 18px 18px 8px; box-shadow: var(--shadow); margin-bottom: 16px; }
.admin-card h3 { margin: 0 0 14px; font-size: .98rem; color: var(--text); display: flex; align-items: center; gap: 8px; }
.card-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 14px; }
.card-head h3 { margin: 0; }
.lead { color: var(--muted); font-size: .92rem; margin: 0 0 16px; line-height: 1.45; }

.list-toolbar { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; }
.search-field { position: relative; flex: 1; max-width: 440px; }
.search-field input { margin: 0; width: 100%; background: #f8f9fb; }
.list-count { color: var(--muted); font-size: .82rem; white-space: nowrap; }
.table-wrap { overflow-x: auto; margin: 0 -4px 6px; }
.admin-table { width: 100%; border-collapse: collapse; font-size: .78rem; line-height: 1.25; }
.admin-table th, .admin-table td { padding: 5px 8px; border-bottom: 1px solid var(--border); text-align: left; vertical-align: middle; }
.admin-table th { color: var(--muted); font-weight: 700; font-size: .66rem; text-transform: uppercase; letter-spacing: .04em; }
.admin-table tbody tr:hover { background: #fafbfc; }
.admin-table tr.row-link { cursor: pointer; }
.toolbar-select { width: auto; min-width: 150px; margin: 0; background-color: #fff; }
.admin-table .badge { padding: 1px 6px; font-size: .66rem; }
.admin-table .btn-sm { padding: 2px 7px; font-size: .72rem; border-radius: 7px; gap: 4px; }
.admin-table .btn-sm .ico { width: 12px; height: 12px; }
.admin-table code { font-size: .72rem; padding: 1px 4px; }
.cell-muted { color: var(--muted); }
.row-actions { display: flex; gap: 4px; }
.badge { display: inline-block; padding: 3px 8px; border-radius: 999px; font-size: .72rem; font-weight: 700; }
.badge-actif { background: #e8f5e9; color: #2e7d32; }
.badge-suspendu { background: #ffebee; color: #c62828; }
.badge-inactif { background: #f3f4f6; color: #4b5563; }
.badge-type { background: #e8eefc; color: #1d4ed8; }
.empty-state { padding: 28px 8px 22px; text-align: center; color: var(--muted); }
.empty-state strong { display: block; color: var(--text); margin-bottom: 4px; }
.loading-state { display: flex; align-items: center; gap: 10px; color: var(--muted); padding: 12px 0; }
.spinner {
    width: 16px; height: 16px; border-radius: 50%; border: 2px solid #e5e7eb; border-top-color: var(--red);
    animation: spin .7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; }
.form-grid .full { grid-column: 1 / -1; }
.form-section {
    border: 1px solid var(--border); border-radius: 12px; padding: 14px 14px 2px; margin-bottom: 14px; background: #fbfcfd;
}
.form-section h3 { display: flex; align-items: center; gap: 8px; margin: 0 0 12px; font-size: .92rem; }
.type-fields { display: none; }
.type-fields.visible { display: block; }
.form-actions { display: flex; justify-content: flex-end; gap: 8px; flex-wrap: wrap; margin-bottom: 8px; }
.gps-row { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.example-box {
    margin: 4px 0 12px; padding: 12px 14px; border-radius: 12px; background: #f6f7f9; color: #374151; font-size: .92rem;
}
.tafuta-phone-row { display: flex; gap: 8px; }
.tafuta-phone-dial, .tafuta-phone-national { margin-bottom: 14px; min-height: 42px; }
.tafuta-phone-dial { flex: 0 0 auto; max-width: 48%; min-width: 130px; padding: 10px 8px; border: 1px solid #d8dbe3; border-radius: 10px; font-size: .9rem; background: #fff; }
.tafuta-phone-national { flex: 1; min-width: 0; padding: 10px 12px; border: 1px solid #d8dbe3; border-radius: 10px; font-size: .95rem; }

.alert { padding: 12px 16px; border-radius: 10px; margin-bottom: 16px; }
.alert-ok { background: #e8f5e9; color: #2e7d32; }
.alert-err { background: #ffebee; color: #c62828; }
.admin-gps-hint { font-size: .85rem; color: var(--muted); margin-left: 8px; }
.check-row {
    display: flex; align-items: flex-start; gap: 12px; padding: 14px; margin-bottom: 12px;
    border: 1px solid var(--border); border-radius: 12px; background: #fafbfc;
}
.check-row input { width: auto; margin: 4px 0 0; }
.check-row label { margin: 0; color: var(--text); }
.check-row label span { display: block; color: var(--muted); font-size: .88rem; font-weight: 400; margin-top: 2px; }

@media (max-width: 480px) {
    .admin-login { padding: 16px; }
    .admin-login-card { padding: 28px 18px 22px; }
}
@media (max-width: 1100px) {
    .stats-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .dash-layout { grid-template-columns: 1fr; }
}
@media (max-width: 900px) {
    .btn-menu { display: flex; }
    .admin-sidebar {
        position: fixed; z-index: 30; inset: 0 auto 0 0; width: min(300px, 88vw);
        transform: translateX(-105%); transition: transform .2s ease; box-shadow: 12px 0 40px rgba(0,0,0,.25);
    }
    .admin-sidebar.open { transform: none; }
    .admin-topbar, .admin-content { padding-left: 16px; padding-right: 16px; }
    .form-grid { grid-template-columns: 1fr; }
    .list-toolbar { flex-direction: column; align-items: stretch; }
    .search-field { max-width: none; }
    .notice-banner { flex-direction: column; align-items: flex-start; }
    .health-grid { grid-template-columns: 1fr; }
    .toolbar-select { width: 100%; }
}

.account-modal {
    position: fixed; inset: 0; z-index: 8000;
    display: flex; align-items: center; justify-content: center; padding: 20px 16px;
}
.account-modal-backdrop { position: absolute; inset: 0; background: rgba(15, 18, 24, .5); }
.account-modal-panel {
    position: relative; z-index: 1; width: 100%; max-width: 680px; max-height: min(88vh, 820px);
    background: #fff; border-radius: 16px; box-shadow: 0 24px 60px rgba(0,0,0,.28);
    display: flex; flex-direction: column; overflow: hidden;
}
.account-modal-head, .account-modal-foot {
    padding: 14px 18px; display: flex; align-items: center; justify-content: space-between; gap: 12px;
}
.account-modal-head { border-bottom: 1px solid var(--border); }
.account-modal-foot { border-top: 1px solid var(--border); background: #fafbfc; }
.account-modal-head h3 { margin: 0; font-size: 1rem; }
.account-modal-head p { margin: 2px 0 0; color: var(--muted); font-size: .8rem; }
.account-modal-body { padding: 14px 18px 8px; overflow: auto; }
.account-section { margin-bottom: 14px; }
.account-section h4 {
    margin: 0 0 8px; font-size: .72rem; letter-spacing: .06em; text-transform: uppercase; color: var(--muted);
}
.detail-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 12px; }
.detail-item { min-width: 0; }
.detail-item.wide { grid-column: 1 / -1; }
.detail-label { display: block; font-size: .68rem; font-weight: 700; color: var(--muted); margin-bottom: 2px; }
.detail-value { font-size: .84rem; word-break: break-word; }
.detail-empty { color: #9ca3af; }
.detail-file { color: var(--red-dark); font-weight: 600; text-decoration: none; }
.detail-file:hover { text-decoration: underline; }
.detail-thumb { display: block; width: 96px; height: 72px; object-fit: cover; border-radius: 8px; border: 1px solid var(--border); background: #f3f4f6; }
.mini-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.mini-stat { border: 1px solid var(--border); border-radius: 10px; padding: 8px 10px; background: #fafbfc; }
.mini-stat strong { display: block; font-size: 1rem; letter-spacing: -.02em; }
.mini-stat span { font-size: .7rem; color: var(--muted); }
.account-note { margin: 0 0 12px; font-size: .84rem; color: #6b7280; }
.seg-tabs { display: flex; gap: 8px; margin-bottom: 14px; flex-wrap: wrap; }
.seg-tab {
    border: 1px solid var(--border); background: #fff; color: var(--text);
    border-radius: 999px; padding: 8px 14px; font: inherit; font-size: .86rem; font-weight: 650;
    display: inline-flex; align-items: center; gap: 8px; cursor: pointer;
}
.seg-tab.active { background: #1c1f26; color: #fff; border-color: #1c1f26; }
.health-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin-bottom: 14px; }
.health-card {
    background: #fff; border: 1px solid var(--border); border-radius: 14px; padding: 14px 16px;
    display: flex; flex-direction: column; gap: 4px; box-shadow: var(--shadow);
}
.health-card span { font-size: .75rem; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
.health-card strong { font-size: 1.05rem; }
.health-card em { font-style: normal; color: var(--muted); font-size: .8rem; }
.health-ok { border-color: #c8e6c9; background: #f4fbf5; }
.health-bad { border-color: #ffcdd2; background: #fff8f8; }
.health-bad strong { color: var(--red-dark); }
.log-context { margin-top: 6px; }
.log-context summary { cursor: pointer; color: var(--muted); font-size: .75rem; }
.log-context pre {
    margin: 6px 0 0; padding: 8px 10px; background: #f6f7f9; border-radius: 8px;
    white-space: pre-wrap; word-break: break-word; font-size: .72rem;
}
@media (max-width: 640px) {
    .detail-grid { grid-template-columns: 1fr; }
    .account-modal-foot { flex-wrap: wrap; }
    .mini-stats { grid-template-columns: 1fr 1fr; }
}
.tw-dialog {
    position: fixed; inset: 0; z-index: 9200;
    display: flex; align-items: center; justify-content: center;
    padding: 20px 18px;
}
.tw-dialog-backdrop { position: absolute; inset: 0; background: rgba(15, 23, 32, .48); }
.tw-dialog-panel {
    position: relative; z-index: 1; width: 100%; max-width: 360px;
    background: #fff; border-radius: 16px; padding: 20px 18px 14px;
    box-shadow: 0 18px 48px rgba(0,0,0,.22);
}
.tw-dialog-title { margin: 0 0 8px; font-size: 1.1rem; font-weight: 800; }
.tw-dialog-msg { margin: 0 0 16px; color: #546e7a; line-height: 1.45; white-space: pre-wrap; }
.tw-dialog-actions { display: flex; gap: 8px; justify-content: flex-end; }
.tw-dialog-btn {
    font: inherit; font-size: .9rem; font-weight: 700; border: 0; border-radius: 10px;
    padding: 10px 16px; cursor: pointer; min-width: 88px;
}
.tw-dialog-btn--ghost { background: #f1f3f5; color: #37474f; }
.tw-dialog-btn--primary { background: #e53935; color: #fff; }
.tw-dialog-btn--danger { background: #c62828; color: #fff; }
.tw-toast {
    position: fixed; left: 50%; bottom: 28px; transform: translateX(-50%);
    background: #1c1f26; color: #fff; padding: 12px 18px; border-radius: 12px;
    font-weight: 600; z-index: 9300; opacity: 0; pointer-events: none; transition: opacity .2s;
}
.tw-toast.visible { opacity: 1; }

.retrait-toolbar {
    display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; margin-bottom: 14px;
}
.retrait-toolbar h3 { margin: 0 0 4px; font-size: 1.05rem; }
.retrait-toolbar p { margin: 0; color: var(--muted); font-size: .84rem; line-height: 1.4; max-width: 62ch; }
.retrait-toolbar-actions { display: flex; gap: 8px; flex-wrap: wrap; flex-shrink: 0; }
.wallet-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin-bottom: 14px; }
.wallet-airtel { --wallet: #e4002b; }
.wallet-mpesa { --wallet: #00a651; }
.wallet-orange { --wallet: #ff7900; }
.wallet-card {
    background: var(--card); border: 1px solid var(--border); border-radius: 14px; padding: 16px 18px;
    box-shadow: var(--shadow); min-height: 148px; display: flex; flex-direction: column; gap: 8px;
    border-top: 4px solid var(--wallet, #1c1f26);
}
.wallet-card-top { display: flex; align-items: center; gap: 10px; }
.wallet-mark {
    width: 36px; height: 36px; border-radius: 10px; background: var(--wallet, #1c1f26); color: #fff;
    display: flex; align-items: center; justify-content: center; font-weight: 800; flex-shrink: 0;
}
.wallet-source {
    display: block; font-size: .68rem; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; color: var(--muted);
}
.wallet-name { display: block; font-weight: 700; font-size: .95rem; }
.wallet-prefixes { display: block; color: var(--muted); font-size: .75rem; margin-top: 2px; }
.wallet-card strong { font-size: 1.45rem; letter-spacing: -.03em; line-height: 1.15; font-variant-numeric: tabular-nums; }
.wallet-card em { font-style: normal; color: var(--muted); font-size: .78rem; margin-top: auto; }
.wallet-empty { background: #fafbfc; }
.wallet-empty strong { color: var(--muted); }
.wallet-note { margin: 0 0 16px; color: var(--muted); font-size: .82rem; line-height: 1.45; max-width: 78ch; }
.wallet-mini { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin-bottom: 14px; }
.wallet-mini-item {
    border: 1px solid var(--border); border-radius: 10px; padding: 8px 10px; background: #fafbfc;
    border-top: 3px solid var(--wallet, #1c1f26);
}
.wallet-mini-item span { display: block; font-size: .68rem; font-weight: 700; color: var(--muted); letter-spacing: .02em; }
.wallet-mini-item strong { display: block; margin-top: 2px; font-size: .92rem; font-variant-numeric: tabular-nums; }
.wallet-mini-item.active { background: #fff; box-shadow: 0 0 0 2px var(--wallet, #1c1f26); }
.account-modal-panel.modal-wallet { border-top: 4px solid var(--wallet, var(--red)); }
#maisha-free-hint p { margin: 0 0 8px; font-size: .84rem; line-height: 1.45; }
#maisha-free-hint p:last-child { margin-bottom: 0; }
.retrait-kpis { display: grid; grid-template-columns: 1.35fr 1fr 1fr; gap: 14px; margin-bottom: 12px; }
.retrait-kpi {
    background: var(--card); border: 1px solid var(--border); border-radius: 14px; padding: 16px 18px;
    box-shadow: var(--shadow); min-height: 112px; display: flex; flex-direction: column; gap: 6px;
}
.retrait-kpi-label {
    font-size: .72rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted);
}
.retrait-kpi strong { font-size: 1.35rem; letter-spacing: -.03em; line-height: 1.15; font-variant-numeric: tabular-nums; }
.retrait-kpi em { font-style: normal; color: var(--muted); font-size: .8rem; margin-top: auto; }
.retrait-kpi-hero { background: #1c1f26; color: #fff; border-color: #1c1f26; }
.retrait-kpi-hero .retrait-kpi-label, .retrait-kpi-hero em { color: #b7bcc6; }
.retrait-kpi-warn { background: #fff8f8; border-color: #ffcdd2; }
.retrait-kpi-warn strong { color: var(--red-dark); }
.retrait-kpi-span { grid-column: 1 / -1; }
.retrait-card { padding-bottom: 16px; }
.retrait-card-sub { margin: 4px 0 0; color: var(--muted); font-size: .84rem; line-height: 1.4; max-width: 62ch; }
.retrait-split { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(240px, .85fr); gap: 18px; align-items: start; }
.retrait-fields { display: grid; grid-template-columns: 1fr 1fr; gap: 0 14px; }
.retrait-field-wide, .retrait-actions { grid-column: 1 / -1; }
.retrait-actions { display: flex; justify-content: flex-start; }
.retrait-suffix {
    display: flex; align-items: stretch; border: 1px solid #d8dbe3; border-radius: 10px;
    background: #fff; margin-bottom: 14px; overflow: hidden;
}
.retrait-suffix:focus-within { border-color: #e7a3a1; box-shadow: 0 0 0 3px rgba(229,57,53,.12); }
.retrait-suffix input { border: 0; margin: 0; box-shadow: none; border-radius: 0; background: transparent; }
.retrait-suffix input:focus { box-shadow: none; }
.retrait-suffix span {
    display: flex; align-items: center; padding: 0 12px; color: var(--muted); font-weight: 700; font-size: .8rem;
    border-left: 1px solid var(--border); background: #f8f9fb;
}
.retrait-preview { background: #f6f7f9; border-radius: 14px; padding: 16px 16px 12px; }
.retrait-preview-kicker {
    margin: 0 0 8px; font-size: .72rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--muted);
}
.retrait-preview-list { list-style: none; margin: 0; padding: 0; }
.retrait-preview-list li {
    display: flex; justify-content: space-between; align-items: baseline; gap: 12px;
    padding: 9px 0; border-bottom: 1px solid #e6e8ee; font-size: .9rem;
}
.retrait-preview-list li:last-child { border-bottom: 0; }
.retrait-preview-list strong { font-variant-numeric: tabular-nums; }
.retrait-preview-note { margin: 8px 0 0; color: var(--muted); font-size: .78rem; line-height: 1.4; }
.retrait-money { display: flex; flex-direction: column; gap: 1px; }
.retrait-money strong { font-variant-numeric: tabular-nums; }
.retrait-money span { color: var(--muted); font-size: .72rem; }
@media (max-width: 900px) {
    .retrait-kpis, .retrait-split, .retrait-fields, .wallet-grid { grid-template-columns: 1fr; }
    .retrait-toolbar { flex-direction: column; align-items: stretch; }
    .wallet-mini { grid-template-columns: 1fr; }
}
