/* ==========================================================================
   PrimeExchange Bank — sandbox digital banking UI
   Design tokens, shell, components, views, responsive & print
   ========================================================================== */

/* ------------------------------------------------------------------ Tokens */
:root {
  --sidebar-w: 268px;
  --demo-h: 36px;
  --radius-sm: 10px;
  --radius: 16px;
  --radius-lg: 22px;
  --radius-xl: 28px;
  --font-ui: "Manrope", "Segoe UI", system-ui, -apple-system, sans-serif;
  --font-display: "Instrument Serif", "Iowan Old Style", Georgia, serif;
  --fs-xs: 11.5px;
  --fs-sm: 13px;
  --fs-base: 14.5px;
  --ease: cubic-bezier(.22, .8, .3, 1);
  --t-fast: .16s var(--ease);
  --t: .28s var(--ease);
}

:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #070f0d;
  --bg-2: #0a1512;
  --panel: #0d1916;
  --panel-2: #11211d;
  --card: #0f1d19;
  --card-hi: #142621;
  --text: #eef6f2;
  --muted: #9cb3ab;
  --faint: #6d857d;
  --line: rgba(238, 246, 242, .075);
  --line-strong: rgba(238, 246, 242, .15);
  --accent: #63e6b5;
  --accent-strong: #45d9a3;
  --accent-ink: #052b20;
  --accent-soft: rgba(99, 230, 181, .11);
  --accent-glow: rgba(99, 230, 181, .22);
  --gold: #e7c98d;
  --gold-soft: rgba(231, 201, 141, .12);
  --danger: #ff8585;
  --danger-soft: rgba(255, 133, 133, .12);
  --warn: #ffcb70;
  --warn-soft: rgba(255, 203, 112, .12);
  --info: #8db9ff;
  --info-soft: rgba(141, 185, 255, .12);
  --hero: #0d3227;
  --hero-2: #0a231c;
  --shadow-sm: 0 6px 20px rgba(0, 0, 0, .22);
  --shadow: 0 24px 60px rgba(0, 0, 0, .38);
  --shadow-lg: 0 40px 100px rgba(0, 0, 0, .5);
  --scrim: rgba(3, 9, 7, .72);
  --svga-bg: #0b1915;
  --code-bg: #091511;
}

:root[data-theme="light"] {
  color-scheme: light;
  --bg: #f3f5ee;
  --bg-2: #edf0e7;
  --panel: #ffffff;
  --panel-2: #f6f8f2;
  --card: #ffffff;
  --card-hi: #f8faf4;
  --text: #10211b;
  --muted: #586c64;
  --faint: #85938d;
  --line: rgba(16, 33, 27, .09);
  --line-strong: rgba(16, 33, 27, .17);
  --accent: #0b8a61;
  --accent-strong: #076f4e;
  --accent-ink: #eafff8;
  --accent-soft: rgba(11, 138, 97, .09);
  --accent-glow: rgba(11, 138, 97, .18);
  --gold: #9a7326;
  --gold-soft: rgba(154, 115, 38, .1);
  --danger: #c34242;
  --danger-soft: rgba(195, 66, 66, .09);
  --warn: #9a6500;
  --warn-soft: rgba(154, 101, 0, .1);
  --info: #2f6bcc;
  --info-soft: rgba(47, 107, 204, .09);
  --hero: #0d3528;
  --hero-2: #092a20;
  --shadow-sm: 0 4px 16px rgba(22, 46, 36, .06);
  --shadow: 0 20px 50px rgba(22, 46, 36, .09);
  --shadow-lg: 0 36px 90px rgba(22, 46, 36, .16);
  --scrim: rgba(18, 32, 26, .45);
  --code-bg: #f0f3ec;
}

/* ------------------------------------------------------------------ Reset */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100vh;
  padding-top: var(--demo-h);
  font-family: var(--font-ui);
  font-size: var(--fs-base);
  line-height: 1.55;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background:
    radial-gradient(760px 520px at 82% -10%, var(--accent-soft), transparent 65%),
    radial-gradient(620px 420px at -8% 30%, rgba(231, 201, 141, .055), transparent 60%),
    radial-gradient(700px 500px at 55% 118%, rgba(99, 230, 181, .045), transparent 65%);
}
img, svg { display: block; max-width: 100%; }
h1, h2, h3, h4, p { margin: 0; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
button { background: none; border: 0; cursor: pointer; }
ul, ol { margin: 0; padding: 0; list-style: none; }
table { border-collapse: collapse; width: 100%; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 6px; }
::selection { background: var(--accent-glow); color: var(--text); }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--line-strong); border-radius: 99px; border: 2px solid transparent; background-clip: padding-box; }
::-webkit-scrollbar-thumb:hover { background: var(--faint); background-clip: padding-box; }

.skip-link {
  position: fixed; top: 12px; left: 12px; z-index: 200;
  padding: 10px 16px; border-radius: 10px;
  background: var(--accent); color: var(--accent-ink);
  font-weight: 700; transform: translateY(-160%);
  transition: transform var(--t-fast);
}
.skip-link:focus { transform: none; }

/* Demo banner */
.demo-banner {
  position: fixed; top: 0; left: 0; right: 0; z-index: 110;
  height: var(--demo-h);
  display: flex; align-items: center; justify-content: center; gap: 9px;
  padding: 0 16px;
  background: linear-gradient(90deg, var(--gold-soft), var(--accent-soft)), var(--bg-2);
  border-bottom: 1px solid var(--line-strong);
  font-size: 10.5px; line-height: 1;
  user-select: none;
}
.demo-banner-dot {
  width: 6px; height: 6px; border-radius: 50%; flex: 0 0 auto;
  background: var(--gold); box-shadow: 0 0 0 3px var(--gold-soft);
}
.demo-banner strong {
  font-size: 9.5px; font-weight: 800; letter-spacing: .14em;
  text-transform: uppercase; color: var(--gold); white-space: nowrap;
}
.demo-banner-text {
  color: var(--muted); font-weight: 600;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.demo-banner-short { display: none; color: var(--muted); font-weight: 600; }
@media (max-width: 640px) {
  .demo-banner { justify-content: flex-start; gap: 7px; padding: 0 12px; }
  .demo-banner-text { display: none; }
  .demo-banner-short { display: inline; }
}

/* ----------------------------------------------------------- Shared helpers */
.mono { font-variant-numeric: tabular-nums; }
.muted { color: var(--muted); }
.faint { color: var(--faint); }
.small { font-size: var(--fs-sm); }
.xs { font-size: var(--fs-xs); }
.strong { font-weight: 700; }
.nowrap { white-space: nowrap; }
.upper { text-transform: uppercase; letter-spacing: .1em; }
.hidden { display: none !important; }
.serif { font-family: var(--font-display); font-style: italic; font-weight: 400; letter-spacing: .01em; }
.neg { color: var(--danger); }
.pos { color: var(--accent); }
.hero-txt { color: var(--accent); }
.text-right { text-align: right; }
.full { width: 100%; }
.row { display: flex; align-items: center; gap: 10px; }
.row-between { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.wrap { flex-wrap: wrap; }
.stack { display: flex; flex-direction: column; gap: 16px; }
.gap-6 { gap: 6px; } .gap-8 { gap: 8px; } .gap-12 { gap: 12px; } .gap-20 { gap: 20px; }
.mt-8 { margin-top: 8px; } .mt-12 { margin-top: 12px; } .mt-16 { margin-top: 16px; }
.mt-24 { margin-top: 24px; } .mb-12 { margin-bottom: 12px; } .mb-20 { margin-bottom: 20px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.grid-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.grid-4 { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; }
.split-2 { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(300px, .85fr); gap: 22px; align-items: start; }
.split-even { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; align-items: start; }
.side-stack { display: flex; flex-direction: column; gap: 18px; position: sticky; top: 92px; }

/* ----------------------------------------------------------------- Buttons */
.btn {
  --btn-bg: var(--accent);
  --btn-fg: var(--accent-ink);
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 11px 18px;
  border-radius: 12px;
  background: var(--btn-bg);
  color: var(--btn-fg);
  font-size: 13.5px; font-weight: 700; letter-spacing: .01em;
  border: 1px solid transparent;
  transition: transform var(--t-fast), box-shadow var(--t-fast), background var(--t-fast), border-color var(--t-fast), opacity var(--t-fast);
  white-space: nowrap;
}
.btn:hover { transform: translateY(-1px); box-shadow: 0 8px 24px -8px var(--accent-glow); }
.btn:active { transform: translateY(0); }
.btn:disabled { opacity: .45; cursor: not-allowed; transform: none; box-shadow: none; }
.btn svg { width: 16px; height: 16px; }
.btn-lg { padding: 14px 24px; border-radius: 14px; font-size: 14.5px; }
.btn-sm { padding: 8px 13px; border-radius: 10px; font-size: 12.5px; }
.btn-ghost { --btn-bg: transparent; --btn-fg: var(--text); border-color: var(--line-strong); }
.btn-ghost:hover { background: var(--panel-2); border-color: var(--faint); box-shadow: none; }
.btn-soft { --btn-bg: var(--accent-soft); --btn-fg: var(--accent); border-color: transparent; }
.btn-soft:hover { box-shadow: none; background: var(--accent-soft); border-color: var(--accent-glow); }
.btn-dark { --btn-bg: var(--panel-2); --btn-fg: var(--text); border-color: var(--line); }
.btn-dark:hover { background: var(--card-hi); box-shadow: none; }
.btn-danger { --btn-bg: var(--danger-soft); --btn-fg: var(--danger); }
.btn-danger:hover { box-shadow: none; border-color: var(--danger); }
.btn-gold { --btn-bg: var(--gold-soft); --btn-fg: var(--gold); }
.btn-block { width: 100%; }
.btn[aria-busy="true"] { opacity: .7; pointer-events: none; }

.icon-btn {
  width: 38px; height: 38px; flex: 0 0 auto;
  display: inline-grid; place-items: center;
  border-radius: 11px;
  border: 1px solid var(--line);
  background: var(--panel);
  color: var(--muted);
  transition: color var(--t-fast), border-color var(--t-fast), background var(--t-fast), transform var(--t-fast);
  position: relative;
}
.icon-btn:hover { color: var(--text); border-color: var(--line-strong); background: var(--panel-2); }
.icon-btn svg { width: 18px; height: 18px; }
.icon-btn.is-active { color: var(--accent); border-color: var(--accent-glow); background: var(--accent-soft); }
.link-btn {
  display: inline-flex; align-items: center; gap: 5px;
  color: var(--accent); font-size: 12.5px; font-weight: 700;
  padding: 4px 2px; border-radius: 6px;
}
.link-btn:hover { text-decoration: underline; text-underline-offset: 3px; }
.link-btn svg { width: 13px; height: 13px; }

/* ------------------------------------------------------------------ Inputs */
.field { display: flex; flex-direction: column; gap: 7px; min-width: 0; }
.field-label { font-size: 12px; font-weight: 700; letter-spacing: .02em; color: var(--muted); display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.field-hint { font-size: var(--fs-xs); color: var(--faint); }
.input, .select, .textarea {
  width: 100%;
  padding: 12px 14px;
  border-radius: 12px;
  background: var(--bg-2);
  border: 1px solid var(--line);
  color: var(--text);
  font-size: 13.5px;
  transition: border-color var(--t-fast), box-shadow var(--t-fast), background var(--t-fast);
  appearance: none;
}
.input::placeholder, .textarea::placeholder { color: var(--faint); }
.input:hover, .select:hover, .textarea:hover { border-color: var(--line-strong); }
.input:focus, .select:focus, .textarea:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
  background: var(--panel);
}
.select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%239cb3ab' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 13px center;
  padding-right: 38px;
  cursor: pointer;
}
.textarea { min-height: 88px; resize: vertical; }
.input-wrap { position: relative; }
.input-wrap .input { padding-right: 44px; }
.input-affix {
  position: absolute; right: 12px; top: 50%; transform: translateY(-50%);
  color: var(--faint); display: inline-grid; place-items: center;
}
.input-affix svg { width: 17px; height: 17px; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.form-grid .span-2 { grid-column: 1 / -1; }
.form-actions { display: flex; align-items: center; justify-content: flex-end; gap: 10px; margin-top: 22px; flex-wrap: wrap; }
.form-note { display: flex; gap: 8px; align-items: flex-start; font-size: 11.5px; color: var(--faint); line-height: 1.5; margin-top: 16px; }
.form-note svg { width: 14px; height: 14px; flex: 0 0 auto; margin-top: 1px; }

.switch { display: inline-flex; align-items: center; gap: 10px; cursor: pointer; user-select: none; }
.switch input { position: absolute; opacity: 0; width: 0; height: 0; }
.switch-track {
  width: 42px; height: 24px; border-radius: 99px;
  background: var(--line-strong); position: relative;
  transition: background var(--t-fast);
  flex: 0 0 auto;
}
.switch-track::after {
  content: ""; position: absolute; top: 3px; left: 3px;
  width: 18px; height: 18px; border-radius: 50%;
  background: var(--text);
  transition: transform var(--t-fast), background var(--t-fast);
  box-shadow: 0 1px 4px rgba(0,0,0,.25);
}
.switch input:checked + .switch-track { background: var(--accent); }
.switch input:checked + .switch-track::after { transform: translateX(18px); background: var(--accent-ink); }
.switch input:focus-visible + .switch-track { outline: 2px solid var(--accent); outline-offset: 2px; }
.switch-label { font-size: 12.5px; color: var(--muted); }

.check { display: flex; align-items: flex-start; gap: 9px; cursor: pointer; font-size: 12.5px; color: var(--muted); }
.check input { width: 16px; height: 16px; accent-color: var(--accent); margin: 2px 0 0; flex: 0 0 auto; }

/* ------------------------------------------------------------------ Badges */
.badge {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 4px 9px; border-radius: 99px;
  font-size: 10.5px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase;
  background: var(--panel-2); color: var(--muted); border: 1px solid var(--line);
  white-space: nowrap;
}
.badge svg { width: 11px; height: 11px; }
.badge-green { background: var(--accent-soft); color: var(--accent); border-color: transparent; }
.badge-gold { background: var(--gold-soft); color: var(--gold); border-color: transparent; }
.badge-red { background: var(--danger-soft); color: var(--danger); border-color: transparent; }
.badge-blue { background: var(--info-soft); color: var(--info); border-color: transparent; }
.badge-amber { background: var(--warn-soft); color: var(--warn); border-color: transparent; }
.badge-dot::before { content: ""; width: 5px; height: 5px; border-radius: 50%; background: currentColor; }
.chip {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 3px 8px; border-radius: 7px;
  font-size: 11px; font-weight: 700;
  background: var(--panel-2); color: var(--muted);
}
.chip.up { background: var(--accent-soft); color: var(--accent); }
.chip.down { background: var(--danger-soft); color: var(--danger); }
.chip svg { width: 11px; height: 11px; }

/* ------------------------------------------------------------------- Shell */
#root { position: relative; z-index: 1; min-height: calc(100vh - var(--demo-h)); }
.app-shell { display: grid; grid-template-columns: var(--sidebar-w) minmax(0, 1fr); min-height: calc(100vh - var(--demo-h)); }

.sidebar {
  position: sticky; top: var(--demo-h);
  height: calc(100vh - var(--demo-h));
  display: flex; flex-direction: column;
  padding: 22px 16px 16px;
  background: linear-gradient(180deg, color-mix(in srgb, var(--panel) 92%, transparent), color-mix(in srgb, var(--bg) 88%, transparent));
  border-right: 1px solid var(--line);
  z-index: 60;
  backdrop-filter: blur(20px);
}
.brand { display: flex; align-items: center; gap: 11px; padding: 0 8px 20px; }
.brand-mark {
  width: 38px; height: 38px; border-radius: 12px;
  display: grid; place-items: center;
  background: linear-gradient(145deg, var(--accent), #2bbd8a);
  color: var(--accent-ink);
  box-shadow: 0 8px 24px -8px var(--accent-glow);
  flex: 0 0 auto;
}
.brand-mark svg { width: 21px; height: 21px; }
.brand-text { display: flex; flex-direction: column; line-height: 1.15; }
.brand-text strong { font-size: 18px; font-weight: 800; letter-spacing: -.02em; }
.brand-text em {
  font-style: normal; font-size: 9px; font-weight: 800;
  letter-spacing: .18em; text-transform: uppercase; color: var(--gold);
  margin-top: 3px;
}
.nav { flex: 1; overflow-y: auto; padding: 2px 0 12px; scrollbar-width: thin; }
.nav-label {
  padding: 16px 10px 7px;
  font-size: 9.5px; font-weight: 800; letter-spacing: .17em;
  text-transform: uppercase; color: var(--faint);
}
.nav-item {
  display: flex; align-items: center; gap: 11px;
  padding: 9px 11px; margin: 2px 0;
  border-radius: 11px;
  font-size: 13px; font-weight: 600;
  color: var(--muted);
  border: 1px solid transparent;
  transition: color var(--t-fast), background var(--t-fast), border-color var(--t-fast);
  position: relative;
}
.nav-item svg { width: 17px; height: 17px; flex: 0 0 auto; opacity: .9; }
.nav-item:hover { color: var(--text); background: var(--panel-2); }
.nav-item.is-active {
  color: var(--accent);
  background: var(--accent-soft);
  border-color: color-mix(in srgb, var(--accent) 16%, transparent);
}
.nav-item.is-active::before {
  content: ""; position: absolute; left: -16px; top: 9px; bottom: 9px;
  width: 3px; border-radius: 0 4px 4px 0; background: var(--accent);
  box-shadow: 0 0 14px var(--accent-glow);
}
.nav-item .nav-count {
  margin-left: auto; font-size: 10px; font-weight: 800;
  background: var(--accent); color: var(--accent-ink);
  border-radius: 99px; padding: 1px 6px;
}
.sidebar-footer { border-top: 1px solid var(--line); padding-top: 13px; display: flex; flex-direction: column; gap: 10px; }
.kyc-mini {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 11px; border-radius: 12px;
  background: linear-gradient(135deg, var(--accent-soft), transparent);
  border: 1px solid color-mix(in srgb, var(--accent) 14%, transparent);
}
.kyc-mini svg { width: 16px; height: 16px; color: var(--accent); flex: 0 0 auto; }
.kyc-mini p { font-size: 10.5px; line-height: 1.3; color: var(--muted); }
.kyc-mini strong { display: block; font-size: 11.5px; color: var(--text); font-weight: 700; }
.sidebar-demo {
  font-size: 10px; line-height: 1.45; color: var(--faint);
  padding: 0 4px;
}
.sidebar-demo b { color: var(--muted); }

.main { min-width: 0; display: flex; flex-direction: column; min-height: calc(100vh - var(--demo-h)); }

/* Topbar */
.topbar {
  position: sticky; top: var(--demo-h); z-index: 50;
  display: flex; align-items: center; gap: 14px;
  padding: 14px clamp(18px, 3vw, 36px);
  background: color-mix(in srgb, var(--bg) 80%, transparent);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(18px) saturate(1.2);
}
.topbar-crumb { display: flex; align-items: center; gap: 7px; font-size: 11.5px; color: var(--faint); font-weight: 600; white-space: nowrap; }
.topbar-crumb strong { color: var(--text); font-weight: 700; }
.topbar-actions { display: flex; align-items: center; gap: 8px; margin-left: auto; }
.search {
  position: relative; display: flex; align-items: center;
  width: min(280px, 28vw);
}
.search svg { position: absolute; left: 12px; width: 15px; height: 15px; color: var(--faint); pointer-events: none; }
.search input {
  width: 100%; padding: 9px 44px 9px 35px;
  border-radius: 10px;
  background: var(--panel); border: 1px solid var(--line);
  font-size: 12.5px; color: var(--text);
  transition: border-color var(--t-fast), background var(--t-fast);
}
.search input::placeholder { color: var(--faint); }
.search input:focus { outline: none; border-color: var(--accent); background: var(--panel-2); }
.search kbd {
  position: absolute; right: 9px;
  font-family: var(--font-ui); font-size: 9px; font-weight: 700;
  color: var(--faint); border: 1px solid var(--line); border-radius: 5px;
  padding: 1.5px 5px; background: var(--bg-2);
}
.menu-btn { display: none; }
.bell-dot {
  position: absolute; top: 8px; right: 9px;
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--accent); box-shadow: 0 0 0 2.5px var(--panel);
}
.avatar-btn {
  width: 38px; height: 38px; border-radius: 11px;
  display: grid; place-items: center;
  font-size: 12px; font-weight: 800; letter-spacing: .02em;
  background: linear-gradient(145deg, var(--accent), #2fb887);
  color: var(--accent-ink);
  border: 1px solid color-mix(in srgb, #fff 18%, transparent);
}
.view { padding: clamp(20px, 3vw, 34px) clamp(18px, 3vw, 36px) 40px; flex: 1; width: 100%; max-width: 1440px; margin: 0 auto; }
.footer {
  border-top: 1px solid var(--line);
  padding: 18px clamp(18px, 3vw, 36px) 26px;
  display: flex; gap: 14px; justify-content: space-between; flex-wrap: wrap;
  font-size: 10.5px; color: var(--faint); line-height: 1.5;
  max-width: 1440px; margin: 0 auto; width: 100%;
}
.footer b { color: var(--muted); }
.sidebar-scrim { display: none; }

/* Popovers */
.pop-wrap { position: relative; }
.popover {
  position: absolute; right: 0; top: calc(100% + 10px);
  width: 320px; max-width: calc(100vw - 32px);
  background: var(--panel);
  border: 1px solid var(--line-strong);
  border-radius: 16px;
  box-shadow: var(--shadow);
  z-index: 70;
  overflow: hidden;
  animation: popIn .18s var(--ease);
}
.pop-head { display: flex; align-items: center; justify-content: space-between; padding: 14px 16px 10px; border-bottom: 1px solid var(--line); }
.pop-head strong { font-size: 12.5px; }
.pop-list { max-height: 330px; overflow-y: auto; }
.pop-item {
  display: flex; gap: 10px; align-items: flex-start;
  padding: 11px 16px; border-bottom: 1px solid var(--line);
  transition: background var(--t-fast);
  width: 100%; text-align: left;
}
.pop-item:hover { background: var(--panel-2); }
.pop-item:last-child { border-bottom: 0; }
.pop-item .pop-ico { width: 30px; height: 30px; border-radius: 9px; flex: 0 0 auto; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent); }
.pop-item .pop-ico svg { width: 14px; height: 14px; }
.pop-item p { font-size: 11.5px; color: var(--text); line-height: 1.4; }
.pop-item span { font-size: 10px; color: var(--faint); }
.pop-item time { font-size: 9.5px; color: var(--faint); display: block; margin-top: 3px; }
.pop-empty { padding: 26px 16px; text-align: center; font-size: 12px; color: var(--faint); }
.user-pop { width: 260px; }
.user-head { padding: 16px; border-bottom: 1px solid var(--line); display: flex; gap: 11px; align-items: center; }
.user-head .avatar-btn { width: 42px; height: 42px; }
.user-head strong { display: block; font-size: 13px; }
.user-head span { font-size: 11px; color: var(--faint); }
.user-menu { padding: 6px; }
.user-menu a, .user-menu button {
  display: flex; align-items: center; gap: 9px;
  width: 100%; padding: 9px 10px; border-radius: 9px;
  font-size: 12.5px; color: var(--muted); text-align: left;
  transition: background var(--t-fast), color var(--t-fast);
}
.user-menu a:hover, .user-menu button:hover { background: var(--panel-2); color: var(--text); }
.user-menu svg { width: 15px; height: 15px; }
.user-menu .sep { height: 1px; background: var(--line); margin: 5px 8px; }
.user-menu .danger { color: var(--danger); }

/* --------------------------------------------------------------------- Page */
.page { animation: fadeUp .4s var(--ease); }
.page-head {
  display: flex; align-items: flex-end; justify-content: space-between;
  gap: 20px; flex-wrap: wrap; margin-bottom: 26px;
}
.eyebrow {
  font-size: 10px; font-weight: 800; letter-spacing: .18em; text-transform: uppercase;
  color: var(--accent); margin-bottom: 7px;
}
.page-title {
  font-size: clamp(26px, 2.6vw, 34px);
  font-weight: 800; letter-spacing: -.035em; line-height: 1.1;
}
.page-sub { color: var(--muted); font-size: 13px; margin-top: 7px; max-width: 640px; }
.page-actions { display: flex; align-items: center; gap: 9px; flex-wrap: wrap; }

/* Card / panel */
.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px;
  position: relative;
  min-width: 0;
}
.card.pad-lg { padding: 26px; }
.card.flush { padding: 0; overflow: hidden; }
.panel-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 16px; }
.panel-head h3 { font-size: 14px; font-weight: 800; letter-spacing: -.01em; display: flex; align-items: center; gap: 8px; }
.panel-head p { font-size: 11.5px; color: var(--faint); margin-top: 3px; }
.section-title { font-size: 15px; font-weight: 800; letter-spacing: -.015em; margin-bottom: 14px; display: flex; align-items: center; gap: 8px; }
.section-title .count { font-size: 10px; font-weight: 800; color: var(--faint); background: var(--panel-2); border: 1px solid var(--line); border-radius: 99px; padding: 1px 7px; }
.section-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; flex-wrap: wrap; }

/* Stats */
.stat {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 17px 18px; display: flex; flex-direction: column; gap: 11px;
  position: relative; overflow: hidden;
  transition: border-color var(--t-fast), transform var(--t-fast);
}
.stat:hover { border-color: var(--line-strong); transform: translateY(-2px); }
.stat-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.stat-label { font-size: 11px; font-weight: 700; color: var(--muted); }
.stat-ico { width: 28px; height: 28px; border-radius: 9px; display: grid; place-items: center; background: var(--panel-2); color: var(--muted); }
.stat-ico svg { width: 14px; height: 14px; }
.stat-ico.green { background: var(--accent-soft); color: var(--accent); }
.stat-ico.gold { background: var(--gold-soft); color: var(--gold); }
.stat-ico.blue { background: var(--info-soft); color: var(--info); }
.stat-value { font-size: 24px; font-weight: 800; letter-spacing: -.035em; line-height: 1.1; font-variant-numeric: tabular-nums; }
.stat-value small { font-size: 12px; color: var(--faint); font-weight: 600; letter-spacing: 0; }
.stat-foot { display: flex; align-items: center; gap: 7px; font-size: 10.5px; color: var(--faint); }

/* Hero balance */
.balance-hero {
  position: relative; overflow: hidden;
  border-radius: var(--radius-lg);
  padding: clamp(22px, 3vw, 30px);
  background:
    radial-gradient(520px 260px at 88% -30%, rgba(99, 230, 181, .28), transparent 65%),
    radial-gradient(400px 300px at 10% 120%, rgba(231, 201, 141, .12), transparent 60%),
    linear-gradient(135deg, var(--hero), var(--hero-2));
  color: #f2fdf8;
  border: 1px solid rgba(255, 255, 255, .08);
  box-shadow: 0 30px 70px -30px rgba(0, 0, 0, .6);
  min-height: 250px;
  display: flex; flex-direction: column;
}
.balance-hero::after {
  content: ""; position: absolute; right: -90px; bottom: -140px;
  width: 330px; height: 330px; border-radius: 50%;
  border: 1px solid rgba(255, 255, 255, .1);
  box-shadow: 0 0 0 40px rgba(255,255,255,.03), 0 0 0 90px rgba(255,255,255,.02);
  pointer-events: none;
}
.hero-top { display: flex; align-items: center; gap: 10px; position: relative; z-index: 1; }
.hero-label { font-size: 11px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: rgba(255,255,255,.62); display: flex; align-items: center; gap: 7px; }
.hero-label .icon-btn { width: 26px; height: 26px; background: rgba(255,255,255,.06); border-color: rgba(255,255,255,.1); color: rgba(255,255,255,.7); border-radius: 7px; }
.hero-label .icon-btn svg { width: 13px; height: 13px; }
.hero-badge {
  margin-left: auto; display: inline-flex; align-items: center; gap: 5px;
  font-size: 9.5px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase;
  color: var(--gold); background: rgba(231, 201, 141, .12);
  border: 1px solid rgba(231, 201, 141, .25);
  padding: 4px 9px; border-radius: 99px;
}
.hero-badge svg { width: 11px; height: 11px; }
.hero-amount {
  font-size: clamp(40px, 5vw, 58px);
  font-weight: 700; letter-spacing: -.045em; line-height: 1;
  margin: 18px 0 6px; position: relative; z-index: 1;
  font-variant-numeric: tabular-nums;
  font-family: var(--font-display);
  font-style: italic;
}
.hero-amount .cents { font-size: .55em; color: rgba(255,255,255,.6); }
.hero-sub { font-size: 11.5px; color: rgba(255,255,255,.6); position: relative; z-index: 1; display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.hero-sub .sep-dot { width: 3px; height: 3px; border-radius: 50%; background: rgba(255,255,255,.35); }
.hero-rate { font-size: 11px; font-weight: 700; color: var(--accent); display: inline-flex; align-items: center; gap: 4px; }
.hero-rate svg { width: 12px; height: 12px; }
.hero-actions { display: flex; gap: 9px; flex-wrap: wrap; margin-top: auto; padding-top: 24px; position: relative; z-index: 2; }
.hero-action {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 8px 13px 8px 9px;
  border-radius: 11px;
  background: rgba(255,255,255,.07);
  border: 1px solid rgba(255,255,255,.12);
  color: #f2fdf8; font-size: 11.5px; font-weight: 700;
  transition: background var(--t-fast), border-color var(--t-fast), transform var(--t-fast);
}
.hero-action:hover { background: rgba(255,255,255,.13); border-color: rgba(255,255,255,.24); transform: translateY(-1px); }
.hero-action .ha-ico { width: 25px; height: 25px; border-radius: 8px; display: grid; place-items: center; background: rgba(99, 230, 181, .16); color: var(--accent); }
.hero-action .ha-ico svg { width: 13px; height: 13px; }

/* Wallet strip */
.wallet-card {
  display: flex; align-items: center; gap: 12px;
  padding: 14px; border-radius: 14px;
  background: var(--card); border: 1px solid var(--line);
  transition: border-color var(--t-fast), transform var(--t-fast);
}
.wallet-card:hover { border-color: var(--line-strong); transform: translateY(-1px); }
.wallet-ico {
  width: 38px; height: 38px; border-radius: 12px; flex: 0 0 auto;
  display: grid; place-items: center; font-size: 11px; font-weight: 800;
  background: var(--panel-2); color: var(--muted); border: 1px solid var(--line);
  letter-spacing: -.02em;
}
.wallet-ico.fiat { background: var(--accent-soft); color: var(--accent); border-color: transparent; }
.wallet-ico.crypto { background: var(--gold-soft); color: var(--gold); border-color: transparent; }
.wallet-ico.savings { background: var(--info-soft); color: var(--info); border-color: transparent; }
.wallet-main { min-width: 0; flex: 1; }
.wallet-main strong { display: block; font-size: 11.5px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.wallet-main span { font-size: 10px; color: var(--faint); }
.wallet-amt { text-align: right; font-size: 12.5px; font-weight: 800; font-variant-numeric: tabular-nums; white-space: nowrap; }
.wallet-amt small { display: block; font-size: 9.5px; color: var(--faint); font-weight: 600; }

/* Charts */
.chart-box { position: relative; margin: 4px -4px 0; }
.chart-box svg { width: 100%; height: auto; overflow: visible; }
.chart-grid line { stroke: var(--line); stroke-width: 1; }
.chart-axis { fill: var(--faint); font-size: 9.5px; font-family: var(--font-ui); }
.chart-legend { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; font-size: 10.5px; color: var(--muted); margin-top: 8px; }
.chart-legend span { display: inline-flex; align-items: center; gap: 6px; }
.chart-legend i { width: 8px; height: 8px; border-radius: 3px; display: inline-block; }
.chart-tooltip {
  position: absolute; pointer-events: none; opacity: 0;
  transform: translate(-50%, -115%);
  background: var(--panel); border: 1px solid var(--line-strong);
  border-radius: 9px; padding: 6px 9px;
  font-size: 10.5px; font-weight: 700; white-space: nowrap;
  box-shadow: var(--shadow-sm); transition: opacity .1s;
  z-index: 3;
}
.chart-tooltip.show { opacity: 1; }
.donut-wrap { display: flex; align-items: center; gap: 22px; }
.donut { position: relative; width: 152px; height: 152px; flex: 0 0 auto; }
.donut svg { transform: rotate(-90deg); }
.donut-center { position: absolute; inset: 0; display: grid; place-content: center; text-align: center; }
.donut-center strong { font-size: 18px; font-weight: 800; letter-spacing: -.03em; display: block; line-height: 1.15; }
.donut-center span { font-size: 9.5px; color: var(--faint); display: block; }
.donut-legend { flex: 1; display: flex; flex-direction: column; gap: 9px; min-width: 0; }
.donut-legend-row { display: flex; align-items: center; gap: 8px; font-size: 11px; }
.donut-legend-row i { width: 7px; height: 7px; border-radius: 2px; flex: 0 0 auto; }
.donut-legend-row span { color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.donut-legend-row b { margin-left: auto; font-variant-numeric: tabular-nums; font-weight: 700; }

/* Transactions */
.txn-list { display: flex; flex-direction: column; }
.txn {
  display: flex; align-items: center; gap: 12px;
  padding: 11px 0;
  border-bottom: 1px solid var(--line);
}
.txn:last-child { border-bottom: 0; padding-bottom: 2px; }
.txn:first-child { padding-top: 2px; }
.txn-ico {
  width: 36px; height: 36px; border-radius: 11px; flex: 0 0 auto;
  display: grid; place-items: center;
  background: var(--panel-2); color: var(--muted);
  font-size: 10px; font-weight: 800;
  border: 1px solid var(--line);
}
.txn-ico svg { width: 16px; height: 16px; }
.txn-ico.green { background: var(--accent-soft); color: var(--accent); border-color: transparent; }
.txn-ico.gold { background: var(--gold-soft); color: var(--gold); border-color: transparent; }
.txn-ico.blue { background: var(--info-soft); color: var(--info); border-color: transparent; }
.txn-ico.red { background: var(--danger-soft); color: var(--danger); border-color: transparent; }
.txn-main { flex: 1; min-width: 0; }
.txn-title { font-size: 12.5px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.txn-meta { font-size: 10.5px; color: var(--faint); margin-top: 2px; display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.txn-meta .sep-dot { width: 3px; height: 3px; border-radius: 50%; background: var(--faint); }
.txn-amount { font-size: 12.5px; font-weight: 800; font-variant-numeric: tabular-nums; white-space: nowrap; text-align: right; }
.txn-amount small { display: block; font-size: 9.5px; color: var(--faint); font-weight: 600; }
.txn-amount.credit { color: var(--accent); }
.status-pill { display: inline-flex; align-items: center; gap: 4px; font-size: 9px; font-weight: 800; text-transform: uppercase; letter-spacing: .05em; }
.status-pill::before { content: ""; width: 4px; height: 4px; border-radius: 50%; background: currentColor; }
.status-completed { color: var(--accent); }
.status-pending { color: var(--warn); }
.status-failed { color: var(--danger); }
.status-verified { color: var(--accent); }

/* Data table */
.table-wrap { overflow-x: auto; margin: 0 -20px; padding: 0 20px; }
.data-table { width: 100%; font-size: 12px; min-width: 620px; }
.data-table th {
  text-align: left; font-size: 9.5px; font-weight: 800; letter-spacing: .1em;
  text-transform: uppercase; color: var(--faint);
  padding: 8px 12px; border-bottom: 1px solid var(--line);
  white-space: nowrap;
}
.data-table td { padding: 12px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.data-table tr:last-child td { border-bottom: 0; }
.data-table tbody tr { transition: background var(--t-fast); cursor: pointer; }
.data-table tbody tr:hover { background: var(--panel-2); }
.data-table .cell-main { font-weight: 700; font-size: 12px; white-space: nowrap; }
.data-table .cell-sub { font-size: 10px; color: var(--faint); margin-top: 2px; }
.data-table .num { text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }

/* Segmented / pills / tabs */
.segmented {
  display: inline-flex; padding: 3px; gap: 2px;
  background: var(--panel); border: 1px solid var(--line);
  border-radius: 11px;
}
.segmented button {
  padding: 6px 12px; border-radius: 8px;
  font-size: 11px; font-weight: 700; color: var(--faint);
  transition: background var(--t-fast), color var(--t-fast);
  white-space: nowrap;
}
.segmented button:hover { color: var(--text); }
.segmented button.is-active { background: var(--accent-soft); color: var(--accent); }
.chip-row { display: flex; gap: 7px; flex-wrap: wrap; }
.filter-chip {
  padding: 6px 12px; border-radius: 99px;
  border: 1px solid var(--line); background: var(--panel);
  font-size: 11px; font-weight: 700; color: var(--muted);
  transition: all var(--t-fast);
}
.filter-chip:hover { border-color: var(--line-strong); color: var(--text); }
.filter-chip.is-active { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.tabs { display: flex; gap: 3px; border-bottom: 1px solid var(--line); margin-bottom: 22px; overflow-x: auto; }
.tab {
  padding: 11px 14px; font-size: 12.5px; font-weight: 700; color: var(--faint);
  border-bottom: 2px solid transparent; margin-bottom: -1px;
  display: inline-flex; align-items: center; gap: 7px; white-space: nowrap;
  transition: color var(--t-fast), border-color var(--t-fast);
}
.tab:hover { color: var(--text); }
.tab.is-active { color: var(--accent); border-bottom-color: var(--accent); }
.tab svg { width: 15px; height: 15px; }
.pill-tabs { display: inline-flex; gap: 4px; padding: 4px; border-radius: 12px; background: var(--panel); border: 1px solid var(--line); }
.pill-tabs button { padding: 7px 15px; border-radius: 9px; font-size: 11.5px; font-weight: 700; color: var(--faint); transition: all var(--t-fast); }
.pill-tabs button:hover { color: var(--text); }
.pill-tabs button.is-active { background: var(--accent-soft); color: var(--accent); }

/* Empty state */
.empty {
  padding: 36px 20px; text-align: center;
  border: 1px dashed var(--line-strong); border-radius: 14px;
  color: var(--faint);
}
.empty .empty-ico { width: 46px; height: 46px; border-radius: 14px; background: var(--panel-2); color: var(--muted); display: grid; place-items: center; margin: 0 auto 12px; }
.empty .empty-ico svg { width: 20px; height: 20px; }
.empty strong { display: block; color: var(--text); font-size: 13px; margin-bottom: 4px; }
.empty p { font-size: 11.5px; max-width: 340px; margin: 0 auto; line-height: 1.55; }
.empty .btn { margin-top: 14px; }

/* Amount input */
.amount-box {
  display: flex; align-items: center; gap: 10px;
  padding: 14px 16px;
  border: 1px solid var(--line); border-radius: 14px;
  background: var(--bg-2);
  transition: border-color var(--t-fast), box-shadow var(--t-fast);
}
.amount-box:focus-within { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); background: var(--panel); }
.amount-ccy { font-size: 18px; font-weight: 700; color: var(--faint); }
.amount-input {
  border: 0; background: transparent; outline: none;
  font-size: 28px; font-weight: 800; letter-spacing: -.03em;
  width: 100%; min-width: 0; font-variant-numeric: tabular-nums;
}
.amount-input::placeholder { color: var(--faint); opacity: .6; }
.amount-side { font-size: 10.5px; color: var(--faint); text-align: right; white-space: nowrap; }
.amount-side b { display: block; color: var(--muted); font-size: 11px; }

/* Summary rows */
.summary-list { display: flex; flex-direction: column; gap: 11px; }
.summary-row { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; font-size: 12px; }
.summary-row .k { color: var(--muted); }
.summary-row .v { font-weight: 700; text-align: right; font-variant-numeric: tabular-nums; }
.summary-row .v small { display: block; font-size: 9.5px; color: var(--faint); font-weight: 500; }
.summary-total { border-top: 1px solid var(--line); padding-top: 13px; margin-top: 4px; }
.summary-total .k { font-weight: 700; color: var(--text); font-size: 12.5px; }
.summary-total .v { font-size: 18px; letter-spacing: -.02em; }
.review-hero { text-align: center; padding: 8px 0 22px; }
.review-hero .rh-ico { width: 52px; height: 52px; border-radius: 16px; background: var(--accent-soft); color: var(--accent); display: grid; place-items: center; margin: 0 auto 12px; }
.review-hero .rh-ico svg { width: 23px; height: 23px; }
.review-hero .rh-label { font-size: 10.5px; text-transform: uppercase; letter-spacing: .12em; color: var(--faint); font-weight: 800; }
.review-hero .rh-amount { font-family: var(--font-display); font-style: italic; font-size: 38px; line-height: 1.1; margin-top: 4px; letter-spacing: -.02em; }
.review-hero .rh-to { font-size: 12px; color: var(--muted); margin-top: 5px; }

/* Bank cards */
.bank-card {
  position: relative; overflow: hidden;
  aspect-ratio: 1.586 / 1;
  width: 100%; max-width: 390px;
  border-radius: 20px;
  padding: 21px 22px;
  color: #f4fbf8;
  display: flex; flex-direction: column;
  background: linear-gradient(138deg, #123c2f 0%, #0a231c 60%, #071713 100%);
  border: 1px solid rgba(255, 255, 255, .13);
  box-shadow: 0 26px 55px -22px rgba(0, 0, 0, .7);
  transition: transform var(--t), box-shadow var(--t);
  isolation: isolate;
  cursor: pointer;
}
.bank-card::before {
  content: ""; position: absolute; z-index: -1;
  width: 300px; height: 300px; right: -110px; top: -140px; border-radius: 50%;
  background: radial-gradient(circle, rgba(99, 230, 181, .38), transparent 65%);
}
.bank-card::after {
  content: ""; position: absolute; z-index: -1;
  width: 220px; height: 220px; left: -90px; bottom: -120px; border-radius: 50%;
  background: radial-gradient(circle, rgba(231, 201, 141, .2), transparent 65%);
}
.bank-card:hover { transform: translateY(-4px) rotateX(1.5deg); box-shadow: 0 34px 70px -24px rgba(0, 0, 0, .8); }
.bank-card.variant-mc,
.bank-card.variant-gold { background: linear-gradient(138deg, #3c2f16 0%, #241b0c 60%, #150f06 100%); }
.bank-card.variant-mc::before,
.bank-card.variant-gold::before { background: radial-gradient(circle, rgba(231, 201, 141, .4), transparent 65%); }
.bank-card.variant-mc::after,
.bank-card.variant-gold::after { background: radial-gradient(circle, rgba(255, 255, 255, .12), transparent 65%); }
.bank-card.is-frozen { filter: saturate(.35); }
.bank-card.is-frozen::after {
  content: ""; position: absolute; inset: 0; border-radius: inherit;
  background: rgba(140, 200, 230, .13);
  backdrop-filter: blur(2.5px);
  z-index: 4;
}
.bank-card.is-frozen .bc-inner { opacity: .7; }
.bank-card.is-selected { outline: 2px solid var(--accent); outline-offset: 3px; }
.bc-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.bc-brand { display: flex; align-items: center; gap: 7px; font-size: 13px; font-weight: 800; letter-spacing: -.01em; }
.bc-brand .bc-mark { width: 22px; height: 22px; border-radius: 7px; background: rgba(255,255,255,.14); display: grid; place-items: center; }
.bc-brand .bc-mark svg { width: 13px; height: 13px; color: var(--accent); }
.bc-network { font-size: 11px; font-weight: 800; letter-spacing: .08em; opacity: .9; }
.bc-mc { display: flex; align-items: center; }
.bc-mc i { width: 16px; height: 16px; border-radius: 50%; display: block; }
.bc-mc i:first-child { background: #eb001b; opacity: .9; }
.bc-mc i:last-child { background: #f79e1b; opacity: .9; margin-left: -7px; }
.bc-chip {
  width: 34px; height: 26px; border-radius: 6px; margin-top: 22px;
  background: linear-gradient(135deg, #f6e3b2, #c8a768);
  position: relative; opacity: .9;
  box-shadow: inset 0 0 0 1px rgba(0,0,0,.15);
}
.bc-chip::before, .bc-chip::after { content: ""; position: absolute; background: rgba(70, 52, 20, .45); }
.bc-chip::before { left: 0; right: 0; top: 50%; height: 1px; }
.bc-chip::after { top: 0; bottom: 0; left: 50%; width: 1px; }
.bc-number {
  font-family: var(--font-ui); font-size: clamp(14px, 2vw, 18px);
  letter-spacing: .13em; margin-top: auto; padding-top: 18px;
  font-variant-numeric: tabular-nums; font-weight: 600; white-space: nowrap;
  text-shadow: 0 1px 8px rgba(0,0,0,.4);
}
.bc-bottom { display: flex; align-items: flex-end; gap: 22px; margin-top: 14px; }
.bc-bottom span { display: block; font-size: 7px; letter-spacing: .16em; text-transform: uppercase; opacity: .55; margin-bottom: 2px; }
.bc-bottom strong { font-size: 9.5px; letter-spacing: .06em; font-weight: 700; text-transform: uppercase; }
.bc-bottom .bc-right { margin-left: auto; }
.bc-freeze-badge { position: absolute; top: 50%; left: 0; right: 0; z-index: 5; text-align: center; font-size: 10px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; color: #d9f4ff; display: none; }
.bank-card.is-frozen .bc-freeze-badge { display: block; }
.bc-freeze-badge svg { width: 20px; height: 20px; margin: 0 auto 5px; }
.bc-reveal-hint { font-size: 8.5px; letter-spacing: .05em; opacity: .5; text-align: right; margin-top: 4px; }
.card-picker { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; align-items: start; }
.card-picker .bank-card { max-width: none; }
.card-control-row {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 13px 0; border-bottom: 1px solid var(--line);
}
.card-control-row:last-child { border-bottom: 0; }
.card-control-row strong { display: block; font-size: 12px; font-weight: 700; }
.card-control-row span { display: block; font-size: 10px; color: var(--faint); margin-top: 1px; }
.card-title-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.util-bar { height: 6px; border-radius: 99px; background: var(--line); overflow: hidden; margin-top: 7px; }
.util-bar i { display: block; height: 100%; background: linear-gradient(90deg, var(--accent), #2bbd8a); border-radius: 99px; }

/* Beneficiaries */
.beneficiary-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; }
.beneficiary {
  background: var(--card); border: 1px solid var(--line); border-radius: 14px;
  padding: 16px; display: flex; flex-direction: column; gap: 13px;
  transition: border-color var(--t-fast), transform var(--t-fast);
}
.beneficiary:hover { border-color: var(--line-strong); transform: translateY(-2px); }
.ben-top { display: flex; align-items: center; gap: 11px; }
.avatar {
  width: 38px; height: 38px; border-radius: 12px; flex: 0 0 auto;
  display: grid; place-items: center;
  font-size: 11.5px; font-weight: 800;
  background: var(--panel-2); color: var(--text);
  border: 1px solid var(--line);
}
.avatar.lg { width: 48px; height: 48px; border-radius: 14px; font-size: 14px; }
.avatar.sm { width: 30px; height: 30px; border-radius: 9px; font-size: 9.5px; }
.ben-main { min-width: 0; flex: 1; }
.ben-main strong { display: block; font-size: 12.5px; font-weight: 700; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ben-main span { display: block; font-size: 10px; color: var(--faint); margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ben-acct { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 9px 11px; background: var(--bg-2); border-radius: 9px; font-size: 10.5px; color: var(--muted); }
.ben-acct .mono { letter-spacing: .04em; }
.ben-actions { display: flex; gap: 6px; }
.ben-actions .btn { flex: 1; }

/* Exchange */
.rate-row {
  display: grid; grid-template-columns: 1.2fr .9fr 1.2fr; gap: 10px;
  align-items: center; padding: 11px 0; border-bottom: 1px solid var(--line);
  font-size: 12px;
}
.rate-row:last-child { border-bottom: 0; }
.rate-row .rr-pair { display: flex; align-items: center; gap: 8px; font-weight: 700; }
.rate-row .rr-pair span { color: var(--faint); font-weight: 500; font-size: 10px; }
.rate-row .rr-rate { text-align: right; font-variant-numeric: tabular-nums; color: var(--muted); }
.rate-row .rr-spark { height: 22px; }
.rate-row .rr-spark svg { height: 22px; width: 100%; }
.swap-btn {
  width: 34px; height: 34px; border-radius: 50%;
  background: var(--accent); color: var(--accent-ink);
  display: grid; place-items: center;
  box-shadow: 0 6px 18px -6px var(--accent-glow);
  align-self: end; margin-bottom: -17px; z-index: 2;
}
.swap-btn:hover { transform: rotate(180deg); transition: transform .4s var(--ease); }
.swap-btn svg { width: 16px; height: 16px; }
.convert-box { background: var(--bg-2); border: 1px solid var(--line); border-radius: 14px; padding: 14px 16px; }
.convert-box .cb-label { display: flex; justify-content: space-between; gap: 10px; font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--faint); margin-bottom: 8px; }
.convert-box .cb-row { display: flex; align-items: center; gap: 10px; }
.convert-box .cb-amount { font-size: 22px; font-weight: 800; letter-spacing: -.03em; flex: 1; min-width: 0; border: 0; background: none; outline: none; font-variant-numeric: tabular-nums; }
.ccy-select { display: inline-flex; align-items: center; gap: 7px; padding: 7px 10px; border-radius: 9px; background: var(--panel); border: 1px solid var(--line); font-size: 11.5px; font-weight: 700; cursor: pointer; }
.ccy-select select { border: 0; background: none; font-size: 11.5px; font-weight: 700; cursor: pointer; outline: none; color: var(--text); }

/* Deposits */
.upload-zone {
  border: 1.5px dashed var(--line-strong); border-radius: 14px;
  padding: 26px 18px; text-align: center; cursor: pointer;
  transition: border-color var(--t-fast), background var(--t-fast);
  background: var(--bg-2);
}
.upload-zone:hover { border-color: var(--accent); background: var(--accent-soft); }
.upload-zone svg { width: 24px; height: 24px; color: var(--accent); margin: 0 auto 9px; }
.upload-zone strong { display: block; font-size: 12px; font-weight: 700; }
.upload-zone span { font-size: 10px; color: var(--faint); display: block; margin-top: 3px; }
.upload-preview { position: relative; border-radius: 12px; overflow: hidden; border: 1px solid var(--line); background: var(--bg-2); }
.upload-preview img { width: 100%; max-height: 190px; object-fit: cover; }
.upload-preview .up-remove { position: absolute; top: 7px; right: 7px; background: rgba(0,0,0,.6); color: #fff; border-radius: 7px; width: 26px; height: 26px; display: grid; place-items: center; }
.qr-box {
  background: #fff; border-radius: 14px; padding: 10px;
  width: 164px; height: 164px; margin: 0 auto;
  display: grid; place-items: center;
}
.qr-box svg { width: 100%; height: 100%; }
.addr-box { display: flex; align-items: center; gap: 8px; background: var(--bg-2); border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; font-size: 11px; }
.addr-box code { font-family: ui-monospace, "Cascadia Mono", monospace; font-size: 10.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; flex: 1; color: var(--muted); }
.deposit-tabs .tab svg { width: 14px; height: 14px; }

/* Loans */
.loan-hero {
  border-radius: var(--radius-lg); padding: 24px;
  background: linear-gradient(135deg, var(--hero), var(--hero-2));
  color: #f2fdf8; border: 1px solid rgba(255,255,255,.08);
  position: relative; overflow: hidden;
}
.loan-hero::after {
  content: ""; position: absolute; right: -60px; top: -100px;
  width: 280px; height: 280px; border-radius: 50%;
  background: radial-gradient(circle, rgba(99,230,181,.2), transparent 65%);
}
.loan-hero .lh-label { font-size: 10px; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; color: rgba(255,255,255,.55); }
.loan-hero .lh-amount { font-family: var(--font-display); font-style: italic; font-size: 42px; line-height: 1.1; margin: 8px 0 4px; letter-spacing: -.02em; }
.loan-hero .lh-sub { font-size: 11px; color: rgba(255,255,255,.6); }
.loan-meter { height: 7px; border-radius: 99px; background: rgba(255,255,255,.14); overflow: hidden; margin: 18px 0 8px; }
.loan-meter i { display: block; height: 100%; border-radius: 99px; background: linear-gradient(90deg, var(--accent), #b8f06a); }
.loan-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-top: 18px; }
.loan-stat { background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.1); border-radius: 11px; padding: 10px 12px; }
.loan-stat span { display: block; font-size: 8.5px; text-transform: uppercase; letter-spacing: .1em; color: rgba(255,255,255,.5); font-weight: 800; }
.loan-stat strong { display: block; font-size: 13px; margin-top: 3px; font-weight: 700; font-variant-numeric: tabular-nums; }
.product-card {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 20px; display: flex; flex-direction: column; gap: 12px;
  transition: border-color var(--t-fast), transform var(--t-fast);
}
.product-card:hover { border-color: var(--line-strong); transform: translateY(-2px); }
.product-card .pc-ico { width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent); }
.product-card .pc-ico svg { width: 18px; height: 18px; }
.product-card h4 { font-size: 13px; font-weight: 800; }
.product-card p { font-size: 11px; color: var(--muted); line-height: 1.5; }
.product-card .pc-rate { font-size: 24px; font-weight: 800; letter-spacing: -.03em; }
.product-card .pc-rate small { font-size: 10px; color: var(--faint); font-weight: 600; letter-spacing: 0; }
.schedule-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 9px 0; border-bottom: 1px solid var(--line); font-size: 11.5px; }
.schedule-row:last-child { border-bottom: 0; }
.schedule-row .sched-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--line-strong); flex: 0 0 auto; }
.schedule-row.paid .sched-dot { background: var(--accent); }
.schedule-row.due .sched-dot { background: var(--warn); box-shadow: 0 0 0 3px var(--warn-soft); }

/* FDR */
.fdr-card {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 20px; display: flex; flex-direction: column; gap: 15px;
  position: relative; overflow: hidden;
}
.fdr-card::before {
  content: ""; position: absolute; left: 0; top: 0; bottom: 0; width: 3px;
  background: linear-gradient(180deg, var(--accent), transparent);
}
.fdr-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.fdr-top h4 { font-size: 13px; font-weight: 800; }
.fdr-top p { font-size: 10px; color: var(--faint); margin-top: 2px; letter-spacing: .04em; }
.fdr-amount { font-size: 26px; font-weight: 800; letter-spacing: -.035em; font-variant-numeric: tabular-nums; }
.fdr-meta { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; padding: 12px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.fdr-meta div span { display: block; font-size: 8.5px; text-transform: uppercase; letter-spacing: .08em; color: var(--faint); font-weight: 800; }
.fdr-meta div strong { display: block; font-size: 11.5px; font-weight: 700; margin-top: 2px; }
.progress-ring { position: relative; width: 46px; height: 46px; flex: 0 0 auto; }
.progress-ring svg { transform: rotate(-90deg); }
.progress-ring span { position: absolute; inset: 0; display: grid; place-items: center; font-size: 8.5px; font-weight: 800; color: var(--muted); }
.fdr-term-pill { display: inline-flex; align-items: center; gap: 5px; font-size: 10px; font-weight: 700; background: var(--gold-soft); color: var(--gold); border-radius: 99px; padding: 3px 9px; }
.term-options { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.term-option input { position: absolute; opacity: 0; pointer-events: none; }
.term-option span {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
  padding: 11px 6px; border: 1px solid var(--line); border-radius: 11px;
  background: var(--bg-2); cursor: pointer; transition: all var(--t-fast); text-align: center;
}
.term-option span strong { font-size: 12px; font-weight: 800; }
.term-option span small { font-size: 9px; color: var(--faint); }
.term-option input:checked + span { border-color: var(--accent); background: var(--accent-soft); box-shadow: 0 0 0 1px var(--accent); }
.term-option input:checked + span small { color: var(--accent); }

/* Receipt (used in modal & print) */
.receipt {
  background: var(--panel); border: 1px solid var(--line-strong);
  border-radius: 16px; padding: 26px; position: relative; overflow: hidden;
}
.receipt::after {
  content: "SANDBOX"; position: absolute; top: 26px; right: -34px;
  transform: rotate(35deg); font-size: 9px; font-weight: 800; letter-spacing: .28em;
  color: var(--faint); border: 1px solid var(--line-strong);
  padding: 4px 40px; opacity: .65;
}
.receipt-head { display: flex; align-items: center; gap: 10px; padding-bottom: 16px; border-bottom: 1px dashed var(--line-strong); }
.receipt-head .brand-mark { width: 32px; height: 32px; border-radius: 9px; }
.receipt-head strong { font-size: 14px; display: block; }
.receipt-head span { font-size: 9px; color: var(--faint); letter-spacing: .12em; text-transform: uppercase; }
.receipt-title { font-size: 10px; font-weight: 800; letter-spacing: .16em; text-transform: uppercase; color: var(--faint); margin: 18px 0 4px; }
.receipt-amount { font-family: var(--font-display); font-style: italic; font-size: 34px; letter-spacing: -.02em; }
.receipt-body { margin-top: 16px; display: flex; flex-direction: column; gap: 10px; }
.receipt-row { display: flex; justify-content: space-between; gap: 20px; font-size: 11.5px; }
.receipt-row span { color: var(--faint); }
.receipt-row b { font-weight: 700; text-align: right; font-variant-numeric: tabular-nums; }
.receipt-note { margin-top: 16px; padding-top: 14px; border-top: 1px dashed var(--line-strong); font-size: 9.5px; line-height: 1.55; color: var(--faint); }
.code-chips { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 8px; }
.code-chip {
  background: var(--bg-2); border: 1px solid var(--line);
  border-radius: 8px; padding: 6px 9px; font-family: ui-monospace, "Cascadia Mono", monospace;
  font-size: 9.5px; color: var(--muted); letter-spacing: .03em;
}
.code-chip b { color: var(--text); font-weight: 700; margin-right: 4px; }
.certificate {
  border: 1px solid var(--line-strong); border-radius: 14px; padding: 22px;
  background:
    radial-gradient(400px 180px at 100% 0%, var(--gold-soft), transparent 70%),
    var(--panel);
}

/* Referrals */
.ref-hero {
  background:
    radial-gradient(500px 260px at 90% -40%, rgba(231,201,141,.28), transparent 60%),
    linear-gradient(135deg, var(--hero), var(--hero-2));
  border-radius: var(--radius-lg); padding: 26px; color: #f2fdf8;
  border: 1px solid rgba(255,255,255,.08); overflow: hidden; position: relative;
}
.ref-hero::after {
  content: ""; position: absolute; left: 40%; bottom: -160px; width: 300px; height: 300px; border-radius: 50%;
  border: 1px solid rgba(255,255,255,.08);
  box-shadow: 0 0 0 40px rgba(255,255,255,.025);
}
.ref-code-box { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-top: 16px; position: relative; z-index: 1; }
.ref-code {
  font-family: ui-monospace, "Cascadia Mono", monospace;
  background: rgba(255,255,255,.09); border: 1px dashed rgba(255,255,255,.28);
  border-radius: 10px; padding: 9px 14px; font-size: 14px; font-weight: 700; letter-spacing: .12em;
}
.ref-code-box .btn { background: rgba(255,255,255,.12); color: #fff; border: 1px solid rgba(255,255,255,.18); }
.tier-track { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 14px; }
.tier-step { padding: 10px 12px; border-radius: 10px; background: var(--bg-2); border: 1px solid var(--line); }
.tier-step.is-done { background: var(--gold-soft); border-color: transparent; }
.tier-step span { font-size: 8.5px; text-transform: uppercase; letter-spacing: .1em; font-weight: 800; color: var(--faint); display: block; }
.tier-step strong { font-size: 11.5px; display: block; margin-top: 2px; }
.referral-row { display: flex; align-items: center; gap: 11px; padding: 11px 0; border-bottom: 1px solid var(--line); }
.referral-row:last-child { border-bottom: 0; }

/* KYC */
.kyc-hero {
  display: flex; align-items: center; gap: 18px; flex-wrap: wrap;
  padding: 22px; border-radius: var(--radius-lg);
  background:
    radial-gradient(420px 220px at 100% 0%, var(--accent-soft), transparent 65%),
    var(--card);
  border: 1px solid color-mix(in srgb, var(--accent) 20%, var(--line));
}
.kyc-shield {
  width: 58px; height: 58px; border-radius: 18px; flex: 0 0 auto;
  display: grid; place-items: center;
  background: var(--accent-soft); color: var(--accent);
  border: 1px solid color-mix(in srgb, var(--accent) 25%, transparent);
  box-shadow: 0 12px 30px -12px var(--accent-glow);
}
.kyc-shield svg { width: 27px; height: 27px; }
.kyc-checks { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 10px; }
.kyc-check {
  display: flex; align-items: center; gap: 10px;
  padding: 12px; border-radius: 12px;
  background: var(--bg-2); border: 1px solid var(--line);
}
.kyc-check .kc-ico { width: 28px; height: 28px; border-radius: 9px; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent); flex: 0 0 auto; }
.kyc-check .kc-ico svg { width: 14px; height: 14px; }
.kyc-check strong { display: block; font-size: 11px; font-weight: 700; }
.kyc-check span { display: block; font-size: 9.5px; color: var(--faint); }
.doc-row { display: flex; align-items: center; gap: 11px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.doc-row:last-child { border-bottom: 0; }
.doc-row .doc-ico { width: 34px; height: 34px; border-radius: 10px; background: var(--panel-2); display: grid; place-items: center; color: var(--muted); flex: 0 0 auto; }
.doc-row .doc-ico svg { width: 16px; height: 16px; }
.liveness-box {
  aspect-ratio: 4 / 3; border-radius: 14px; border: 1px solid var(--line);
  background: radial-gradient(circle at 50% 45%, var(--panel-2), var(--bg-2));
  display: grid; place-items: center; position: relative; overflow: hidden;
}
.liveness-box .face { width: 92px; height: 112px; border: 1.5px dashed var(--line-strong); border-radius: 50% 50% 46% 46%; display: grid; place-items: center; color: var(--faint); }
.liveness-box .face svg { width: 38px; height: 38px; }
.liveness-box .scan-line { position: absolute; left: 18%; right: 18%; height: 2px; background: var(--accent); box-shadow: 0 0 16px var(--accent); animation: scan 2.4s var(--ease) infinite; }
.stepper { display: flex; align-items: center; gap: 0; margin-bottom: 22px; }
.step { display: flex; align-items: center; gap: 7px; flex: 1; min-width: 0; }
.step .step-dot {
  width: 24px; height: 24px; border-radius: 50%; flex: 0 0 auto;
  display: grid; place-items: center; font-size: 10px; font-weight: 800;
  background: var(--panel-2); border: 1px solid var(--line-strong); color: var(--faint);
}
.step .step-dot svg { width: 12px; height: 12px; }
.step span { font-size: 10px; font-weight: 700; color: var(--faint); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.step .step-line { height: 1px; background: var(--line-strong); flex: 1; margin: 0 6px; }
.step.is-active .step-dot { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.step.is-active span { color: var(--text); }
.step.is-done .step-dot { background: var(--accent-soft); border-color: var(--accent); color: var(--accent); }
.step.is-done span { color: var(--muted); }

/* Alerts */
.alert-row {
  display: flex; gap: 11px; padding: 13px 0; border-bottom: 1px solid var(--line);
  width: 100%; text-align: left; transition: background var(--t-fast);
}
.alert-row:hover { background: var(--panel-2); }
.alert-row:last-child { border-bottom: 0; }
.alert-row .ar-ico { width: 32px; height: 32px; border-radius: 10px; flex: 0 0 auto; display: grid; place-items: center; background: var(--panel-2); color: var(--muted); }
.alert-row .ar-ico svg { width: 15px; height: 15px; }
.alert-row.unread .ar-ico { background: var(--accent-soft); color: var(--accent); }
.alert-row .ar-main { flex: 1; min-width: 0; }
.alert-row .ar-main strong { font-size: 11.5px; font-weight: 700; display: flex; align-items: center; gap: 6px; }
.alert-row .ar-main .dot { width: 5px; height: 5px; border-radius: 50%; background: var(--accent); flex: 0 0 auto; }
.alert-row .ar-main p { font-size: 10.5px; color: var(--faint); margin-top: 2px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.alert-row time { font-size: 9.5px; color: var(--faint); white-space: nowrap; }
.email-view { font-size: 12px; line-height: 1.65; color: var(--muted); }
.email-view .ev-head { padding-bottom: 14px; border-bottom: 1px solid var(--line); margin-bottom: 16px; }
.email-view .ev-head strong { color: var(--text); font-size: 13px; display: block; }
.email-view .ev-head span { font-size: 10px; color: var(--faint); }
.email-view .ev-body { display: flex; flex-direction: column; gap: 12px; }
.email-view .ev-body strong { color: var(--text); }
.email-card { background: var(--bg-2); border: 1px solid var(--line); border-radius: 11px; padding: 13px; }

/* Settings */
.settings-row { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 15px 0; border-bottom: 1px solid var(--line); }
.settings-row:last-child { border-bottom: 0; }
.settings-row strong { display: block; font-size: 12.5px; font-weight: 700; }
.settings-row p { font-size: 10.5px; color: var(--faint); margin-top: 2px; max-width: 420px; line-height: 1.5; }
.session-row { display: flex; align-items: center; gap: 11px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.session-row:last-child { border-bottom: 0; }
.session-row .s-ico { width: 34px; height: 34px; border-radius: 10px; background: var(--panel-2); display: grid; place-items: center; color: var(--muted); flex: 0 0 auto; }
.session-row .s-ico svg { width: 16px; height: 16px; }
.theme-options { display: flex; gap: 8px; }
.theme-option { padding: 8px 13px; border-radius: 9px; border: 1px solid var(--line); font-size: 11px; font-weight: 700; color: var(--muted); display: inline-flex; align-items: center; gap: 6px; }
.theme-option svg { width: 14px; height: 14px; }
.theme-option.is-active { border-color: var(--accent); background: var(--accent-soft); color: var(--accent); }

/* Modal */
.modal-overlay {
  position: fixed; inset: 0; z-index: 120;
  background: var(--scrim);
  backdrop-filter: blur(6px);
  display: flex; align-items: center; justify-content: center;
  padding: 20px;
  animation: fade .2s var(--ease);
}
.modal {
  width: 100%; max-width: 460px; max-height: calc(100vh - 40px);
  background: var(--panel);
  border: 1px solid var(--line-strong);
  border-radius: 20px;
  box-shadow: var(--shadow-lg);
  display: flex; flex-direction: column;
  animation: modalIn .26s var(--ease);
  position: relative;
}
.modal.size-lg { max-width: 620px; }
.modal.size-xl { max-width: 780px; }
.modal-head { padding: 22px 24px 0; }
.modal-head h3 { font-size: 17px; font-weight: 800; letter-spacing: -.02em; padding-right: 30px; }
.modal-head p { font-size: 11.5px; color: var(--muted); margin-top: 5px; line-height: 1.5; }
.modal-body { padding: 18px 24px 22px; overflow-y: auto; }
.modal-foot { padding: 0 24px 22px; display: flex; gap: 9px; justify-content: flex-end; flex-wrap: wrap; }
.modal-foot .btn { flex: 0 0 auto; }
.modal-x {
  position: absolute; top: 16px; right: 16px;
  width: 30px; height: 30px; border-radius: 9px;
  display: grid; place-items: center;
  color: var(--faint); background: var(--panel-2);
  transition: color var(--t-fast), background var(--t-fast);
  z-index: 2;
}
.modal-x:hover { color: var(--text); background: var(--card-hi); }
.modal-x svg { width: 15px; height: 15px; }
.modal-icon {
  width: 52px; height: 52px; border-radius: 16px;
  background: var(--accent-soft); color: var(--accent);
  display: grid; place-items: center; margin-bottom: 14px;
}
.modal-icon.warn { background: var(--warn-soft); color: var(--warn); }
.modal-icon.danger { background: var(--danger-soft); color: var(--danger); }
.modal-icon svg { width: 23px; height: 23px; }

/* OTP */
.otp-inputs { display: flex; gap: 8px; justify-content: space-between; margin: 6px 0 4px; }
.otp-digit {
  width: 100%; aspect-ratio: 1 / 1.15; max-width: 58px;
  border-radius: 11px; border: 1px solid var(--line-strong);
  background: var(--bg-2); text-align: center;
  font-size: 20px; font-weight: 800; outline: none;
  transition: border-color var(--t-fast), box-shadow var(--t-fast), background var(--t-fast);
  font-variant-numeric: tabular-nums;
}
.otp-digit:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); background: var(--panel); }
.otp-digit.filled { border-color: var(--accent); background: var(--accent-soft); }
.otp-digit.shake { animation: shake .35s var(--ease); border-color: var(--danger); }
.otp-meta { display: flex; align-items: center; justify-content: space-between; gap: 10px; font-size: 10.5px; color: var(--faint); margin-top: 12px; flex-wrap: wrap; }
.sandbox-mail {
  border: 1px dashed color-mix(in srgb, var(--gold) 45%, transparent);
  background: var(--gold-soft);
  border-radius: 12px; padding: 12px 14px; margin-top: 16px;
  font-size: 10.5px; color: var(--muted); line-height: 1.5;
}
.sandbox-mail strong { color: var(--gold); display: flex; align-items: center; gap: 5px; font-size: 10px; text-transform: uppercase; letter-spacing: .08em; margin-bottom: 5px; }
.sandbox-mail strong svg { width: 12px; height: 12px; }
.sandbox-mail .mail-code { font-family: ui-monospace, "Cascadia Mono", monospace; font-size: 15px; font-weight: 800; letter-spacing: .22em; color: var(--text); display: inline-block; margin-top: 4px; }
.sandbox-mail .auto-fill { color: var(--gold); font-weight: 700; text-decoration: underline; text-underline-offset: 2px; font-size: 10px; cursor: pointer; }
.otp-error { color: var(--danger); font-size: 11px; font-weight: 600; margin-top: 8px; display: flex; align-items: center; gap: 5px; }
.otp-error svg { width: 13px; height: 13px; }

/* Toasts */
.toast-stack { position: fixed; right: 20px; bottom: 20px; z-index: 200; display: flex; flex-direction: column; gap: 9px; align-items: flex-end; pointer-events: none; }
.toast {
  display: flex; align-items: flex-start; gap: 10px;
  background: var(--panel); border: 1px solid var(--line-strong);
  border-radius: 12px; padding: 12px 14px;
  box-shadow: var(--shadow);
  min-width: 260px; max-width: 360px;
  pointer-events: auto;
  animation: toastIn .28s var(--ease);
  font-size: 11.5px; line-height: 1.45;
}
.toast.leaving { animation: toastOut .22s var(--ease) forwards; }
.toast .t-ico { width: 24px; height: 24px; border-radius: 8px; display: grid; place-items: center; flex: 0 0 auto; background: var(--accent-soft); color: var(--accent); }
.toast .t-ico svg { width: 13px; height: 13px; }
.toast.warn .t-ico { background: var(--warn-soft); color: var(--warn); }
.toast.danger .t-ico { background: var(--danger-soft); color: var(--danger); }
.toast.info .t-ico { background: var(--info-soft); color: var(--info); }
.toast strong { display: block; font-size: 11.5px; color: var(--text); font-weight: 700; }
.toast p { color: var(--muted); font-size: 10.5px; margin-top: 1px; }
.toast .t-close { margin-left: auto; color: var(--faint); padding: 2px; flex: 0 0 auto; }
.toast .t-close svg { width: 13px; height: 13px; }

/* Auth */
.auth { min-height: calc(100vh - var(--demo-h)); display: grid; grid-template-columns: 1.05fr .95fr; position: relative; z-index: 1; }
.auth-visual {
  position: relative; overflow: hidden;
  padding: clamp(28px, 4vw, 52px);
  display: flex; flex-direction: column;
  background:
    radial-gradient(600px 420px at 85% 10%, rgba(99, 230, 181, .18), transparent 60%),
    radial-gradient(500px 380px at 10% 100%, rgba(231, 201, 141, .1), transparent 60%),
    linear-gradient(155deg, #0c2b22, #06120f 72%);
  color: #f1fbf6;
  border-right: 1px solid rgba(255,255,255,.07);
}
.auth-visual::after {
  content: ""; position: absolute; right: -170px; bottom: -190px;
  width: 540px; height: 540px; border-radius: 50%;
  border: 1px solid rgba(255,255,255,.09);
  box-shadow: 0 0 0 60px rgba(255,255,255,.025), 0 0 0 130px rgba(255,255,255,.015);
}
.auth-brand { display: flex; align-items: center; gap: 11px; position: relative; z-index: 1; }
.auth-brand .brand-mark { width: 40px; height: 40px; }
.auth-brand strong { font-size: 20px; font-weight: 800; letter-spacing: -.025em; display: block; }
.auth-brand em { font-style: normal; font-size: 8.5px; letter-spacing: .2em; text-transform: uppercase; color: var(--gold); font-weight: 800; }
.auth-copy { margin: auto 0; position: relative; z-index: 1; max-width: 520px; }
.auth-copy .eyebrow { color: var(--accent); margin-bottom: 14px; }
.auth-copy h1 { font-size: clamp(34px, 4.2vw, 54px); line-height: 1.05; letter-spacing: -.045em; font-weight: 800; }
.auth-copy h1 .serif { font-weight: 400; color: var(--accent); }
.auth-copy p { color: rgba(255,255,255,.6); font-size: 13px; line-height: 1.7; margin-top: 18px; max-width: 430px; }
.auth-feats { display: flex; flex-direction: column; gap: 12px; margin-top: 30px; }
.auth-feat { display: flex; align-items: center; gap: 11px; font-size: 11.5px; color: rgba(255,255,255,.72); }
.auth-feat .af-ico { width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center; background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.1); color: var(--accent); flex: 0 0 auto; }
.auth-feat .af-ico svg { width: 14px; height: 14px; }
.auth-mini-card {
  position: relative; z-index: 1;
  display: flex; align-items: center; gap: 12px;
  padding: 12px 14px; border-radius: 13px;
  background: rgba(255,255,255,.055); border: 1px solid rgba(255,255,255,.1);
  backdrop-filter: blur(10px);
  max-width: 330px; margin-top: 32px;
}
.auth-mini-card .amc-ico { width: 32px; height: 32px; border-radius: 9px; background: var(--accent); color: var(--accent-ink); display: grid; place-items: center; flex: 0 0 auto; }
.auth-mini-card .amc-ico svg { width: 15px; height: 15px; }
.auth-mini-card p { font-size: 10px; color: rgba(255,255,255,.55); line-height: 1.45; }
.auth-mini-card strong { display: block; font-size: 11px; color: #fff; font-weight: 700; }
.auth-visual footer { position: relative; z-index: 1; margin-top: auto; padding-top: 26px; font-size: 9.5px; color: rgba(255,255,255,.35); line-height: 1.6; max-width: 440px; }
.auth-panel { display: flex; align-items: center; justify-content: center; padding: clamp(22px, 4vw, 48px); background: var(--bg); }
.auth-card { width: 100%; max-width: 400px; }
.auth-card > .badge { margin-bottom: 18px; }
.auth-card h2 { font-size: 27px; font-weight: 800; letter-spacing: -.035em; line-height: 1.15; }
.auth-card .auth-sub { color: var(--muted); font-size: 12.5px; margin-top: 7px; line-height: 1.6; }
.auth-form { display: flex; flex-direction: column; gap: 14px; margin-top: 24px; }
.demo-creds {
  margin-top: 18px; padding: 12px 14px; border-radius: 11px;
  border: 1px dashed var(--line-strong); background: var(--panel);
  font-size: 10.5px; color: var(--muted); line-height: 1.6;
}
.demo-creds b { color: var(--text); font-weight: 700; }
.demo-creds .creds-row { display: flex; justify-content: space-between; gap: 10px; margin-top: 6px; font-family: ui-monospace, monospace; font-size: 10px; }
.auth-foot { margin-top: 24px; font-size: 10px; color: var(--faint); line-height: 1.6; }
.auth-step { animation: fadeUp .3s var(--ease); }
.auth-back { display: inline-flex; align-items: center; gap: 5px; font-size: 11px; color: var(--muted); font-weight: 600; margin-bottom: 18px; }
.auth-back:hover { color: var(--text); }
.auth-back svg { width: 13px; height: 13px; }
.auth-switch { text-align: center; font-size: 10.5px; color: var(--faint); margin-top: 18px; }
.auth-switch b { color: var(--accent); font-weight: 700; cursor: pointer; }

/* Landing extras */
.trust-strip { display: flex; gap: 18px; flex-wrap: wrap; font-size: 10px; color: var(--faint); align-items: center; }
.trust-strip span { display: inline-flex; align-items: center; gap: 5px; }
.trust-strip svg { width: 12px; height: 12px; color: var(--muted); }
.info-note {
  display: flex; gap: 9px; align-items: flex-start;
  padding: 11px 13px; border-radius: 10px;
  background: var(--panel-2); border: 1px solid var(--line);
  font-size: 10.5px; color: var(--muted); line-height: 1.55;
}
.info-note svg { width: 14px; height: 14px; flex: 0 0 auto; margin-top: 1px; color: var(--accent); }
.info-note.warn svg { color: var(--warn); }
.info-note.gold svg { color: var(--gold); }

/* Utilities for visibility skeleton */
.skeleton { background: linear-gradient(90deg, var(--line), var(--panel-2), var(--line)); background-size: 200% 100%; animation: shimmer 1.6s infinite; border-radius: 8px; }

/* --------------------------------------------------------------- Animations */
@keyframes fade { from { opacity: 0; } to { opacity: 1; } }
@keyframes fadeUp { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
@keyframes popIn { from { opacity: 0; transform: translateY(-6px) scale(.98); } to { opacity: 1; transform: none; } }
@keyframes modalIn { from { opacity: 0; transform: translateY(14px) scale(.97); } to { opacity: 1; transform: none; } }
@keyframes toastIn { from { opacity: 0; transform: translateX(20px); } to { opacity: 1; transform: none; } }
@keyframes toastOut { to { opacity: 0; transform: translateX(20px); } }
@keyframes shake { 0%,100% { transform: translateX(0); } 20% { transform: translateX(-5px); } 40% { transform: translateX(5px); } 60% { transform: translateX(-4px); } 80% { transform: translateX(4px); } }
@keyframes scan { 0% { top: 24%; opacity: 0; } 15% { opacity: 1; } 85% { opacity: 1; } 100% { top: 76%; opacity: 0; } }
@keyframes shimmer { to { background-position: -200% 0; } }
@keyframes pulseDot { 0%,100% { opacity: 1; } 50% { opacity: .35; } }
.pulse { animation: pulseDot 1.8s infinite; }

/* --------------------------------------------------------------- Responsive */
@media (max-width: 1180px) {
  .split-2 { grid-template-columns: 1fr; }
  .side-stack { position: static; }
  .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .donut-wrap { flex-direction: column; align-items: stretch; }
  .donut { margin: 0 auto; }
  .card-picker { grid-template-columns: 1fr; }
}
@media (max-width: 1024px) {
  :root { --sidebar-w: 0px; }
  .app-shell { grid-template-columns: 1fr; }
  .sidebar {
    position: fixed; left: 0; top: var(--demo-h); bottom: 0;
    width: 280px; height: calc(100dvh - var(--demo-h));
    transform: translateX(-102%);
    transition: transform var(--t);
    box-shadow: var(--shadow-lg);
    background: var(--panel);
    border-right: 1px solid var(--line-strong);
  }
  .sidebar.is-open { transform: none; }
  .sidebar-scrim {
    display: block; position: fixed; inset: 0; z-index: 55;
    background: var(--scrim); opacity: 0; pointer-events: none;
    transition: opacity var(--t);
  }
  .sidebar-scrim.is-open { opacity: 1; pointer-events: auto; }
  .menu-btn { display: inline-grid; }
  .topbar-crumb { display: none; }
  .view { padding-top: 22px; }
  .auth { grid-template-columns: 1fr; }
  .auth-visual { display: none; }
}
@media (max-width: 860px) {
  .split-even { grid-template-columns: 1fr; }
  .grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .search { width: 190px; }
  .hero-amount { font-size: 46px; }
  .form-grid { grid-template-columns: 1fr; }
  .page-head { align-items: flex-start; }
}
@media (max-width: 640px) {
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .search { display: none; }
  .topbar { padding: 11px 16px; gap: 9px; }
  .view { padding: 18px 16px 32px; }
  .footer { padding: 16px; flex-direction: column; }
  .page-title { font-size: 26px; }
  .balance-hero { min-height: 0; }
  .hero-actions { padding-top: 20px; }
  .hero-action { flex: 1 1 calc(50% - 5px); padding: 8px; justify-content: center; }
  .hero-action .ha-ico { display: none; }
  .card { padding: 16px; }
  .card.pad-lg { padding: 18px; }
  .table-wrap { margin: 0 -16px; padding: 0 16px; }
  .modal-overlay { padding: 10px; }
  .modal { max-height: calc(100vh - 20px); }
  .modal-head { padding: 20px 18px 0; }
  .modal-body { padding: 16px 18px 18px; }
  .modal-foot { padding: 0 18px 18px; }
  .modal-foot .btn { flex: 1; }
  .otp-inputs { gap: 5px; }
  .otp-digit { font-size: 17px; border-radius: 9px; }
  .toast-stack { left: 12px; right: 12px; bottom: 12px; align-items: stretch; }
  .toast { min-width: 0; max-width: none; }
  .loan-hero .lh-amount { font-size: 34px; }
  .loan-stats { grid-template-columns: 1fr 1fr; }
  .fdr-meta { grid-template-columns: 1fr 1fr; }
  .term-options { grid-template-columns: repeat(2, 1fr); }
  .card-picker .bank-card { max-width: 100%; }
  .tier-track { grid-template-columns: 1fr; }
  .donut { width: 136px; height: 136px; }
  .auth-panel { padding: 24px 18px 36px; }
  .otp-meta { font-size: 9.5px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; scroll-behavior: auto !important; }
}

/* -------------------------------------------------------------------- Print */
@media print {
  body { background: #fff !important; color: #111 !important; padding-top: 0; }
  #root, body::before, .demo-banner, .sidebar, .topbar, .footer, .modal-x, .modal-foot, .toast-stack, .no-print { display: none !important; }
  .modal-overlay { position: static; background: #fff; padding: 0; display: block; backdrop-filter: none; }
  .modal { max-width: none; max-height: none; border: 0; box-shadow: none; background: #fff; color: #111; }
  .modal-head { display: none; }
  .modal-body { padding: 0; overflow: visible; }
  .receipt, .certificate { border: 1px solid #bbb !important; background: #fff !important; color: #111 !important; }
  .receipt-row span, .receipt-note, .receipt-head span { color: #555 !important; }
  .receipt::after { color: #999 !important; border-color: #ccc !important; }
  .code-chip { border-color: #ccc !important; color: #333 !important; background: #f7f7f7 !important; }
  .code-chip b { color: #111 !important; }
  .badge { border: 1px solid #ccc !important; color: #333 !important; background: #f5f5f5 !important; }
}
