/* Onboard Business — v1 (adaptive) shell + primitives + dashboard
   Tokens are shared with v0 — do not redefine colors/type here. */
@import url("../v0/design-system/colors_and_type.css");

* { box-sizing: border-box; }
html, body, #root { height: 100%; }
body { margin: 0; background: var(--bg-canvas); color: var(--fg-default); font-family: var(--font-sans); }
a { color: inherit; }
button { font-family: var(--font-sans); }

/* ---------- Shared atoms (kept minimal — v1 owns its own layout) ---------- */
.btn {
  letter-spacing: 0.02rem;
  padding: 11px 16px;
  border-radius: var(--radius-lg);
  font-size: 13.5px; font-weight: 500; line-height: 1;
  border: 0; cursor: pointer; color: #fff; background: var(--info-700);
  transition: background-color .15s ease;
  display: inline-flex; align-items: center; gap: 8px;
}
.btn:hover { background: #1E40AF; }
.btn:disabled { background: var(--gray-300); color: var(--gray-500); cursor: not-allowed; }
.btn.btn-lg { padding: 14px 18px; font-size: 14px; }
.btn.btn-sm { padding: 7px 12px; font-size: 12px; border-radius: 8px; }
.btn.btn-soft { background: var(--info-100); color: var(--info-700); }
.btn.btn-soft:hover { background: #BFDBFE; }
.btn-ghost { background: transparent; color: var(--gray-700); }
.btn-ghost:hover { background: var(--gray-100); }
.btn svg { width: 14px; height: 14px; }

.crumbs { display: flex; align-items: center; gap: 8px; font-size: 12px; color: var(--gray-600); margin-bottom: 14px; }
.crumbs a { color: var(--info-700); cursor: pointer; text-decoration: none; }
.crumb-back { display: inline-flex !important; align-items: center; gap: 6px; padding: 6px 10px 6px 8px; border-radius: 8px; color: var(--gray-700) !important; font-size: 13px; font-weight: 500; }
.crumb-back:hover { background: var(--gray-100); color: var(--gray-900) !important; }
.crumb-back svg { width: 14px; height: 14px; }
.crumb-sep { color: var(--gray-400); }
.crumb-current { color: var(--gray-600); font-size: 13px; font-weight: 500; }

.pill {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 3px 10px; border-radius: 999px;
  font-size: 11.5px; font-weight: 500; white-space: nowrap;
}
.pill .dot { width: 6px; height: 6px; border-radius: 999px; background: currentColor; }
.pill.success { background: var(--success-100); color: var(--success-700); }
.pill.warn    { background: var(--warning-100); color: #A16207; }
.pill.danger  { background: var(--danger-100); color: var(--danger-700); }
.pill.info    { background: var(--info-100); color: var(--info-700); }
.pill.neutral { background: var(--gray-200); color: var(--gray-700); }

.field { display: flex; flex-direction: column; margin-bottom: 16px; }
.field .lbl { font-size: 11.5px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--gray-700); margin-bottom: 8px; }
.field .help { font-size: 12px; color: var(--gray-600); margin-top: 6px; }
.inp {
  appearance: none; width: 100%; box-sizing: border-box;
  background: #fff; border: 2px solid var(--gray-300);
  border-radius: var(--radius-lg); padding: 13px 16px;
  font-family: var(--font-sans); font-size: 14px; color: var(--gray-900);
  transition: border-color .12s ease, box-shadow .12s ease;
}
.inp::placeholder { color: var(--gray-500); }
.inp:focus { outline: none; border-color: var(--info-700); box-shadow: 0 0 0 3px rgba(29,78,216,.12); }
.inp.inp-error { border-color: #DC2626; }
.inp.inp-error:focus { border-color: #DC2626; box-shadow: 0 0 0 3px rgba(220,38,38,.12); }

.card {
  background: #fff;
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-card);
  padding: 20px;
}

.ccy-flag { border-radius: 999px; background-size: cover; background-position: center; flex-shrink: 0; }

/* =====================================================
   Shell — adaptive: sidebar+topnav (desktop) / bottom tabs (mobile)
   ===================================================== */
.shell { min-height: 100vh; display: flex; flex-direction: column; }

/* ---------- Desktop ---------- */
.shell.is-desktop { display: grid; grid-template-columns: var(--layout-sidebar) 1fr; grid-template-rows: var(--layout-nav-h) 1fr; height: 100vh; overflow: hidden; }
.shell.is-desktop.has-demo-banner { grid-template-rows: var(--demo-banner-h) var(--layout-nav-h) 1fr; }

/* ---------- Demo mode banner ---------- */
:root { --demo-banner-h: 38px; }
.demo-banner {
  grid-column: 1 / -1; height: var(--demo-banner-h); flex-shrink: 0;
  background: var(--gray-900); color: #fff;
  display: flex; align-items: center; justify-content: center; gap: 14px;
  padding: 0 16px; font-size: 12.5px; text-align: center; flex-wrap: wrap;
  position: relative; z-index: 6;
}
.demo-banner-cta {
  display: inline-flex; align-items: center; gap: 5px;
  color: #fff; font-weight: 600; text-decoration: underline; white-space: nowrap;
}
.demo-banner-cta:hover { text-decoration: none; }
.demo-banner-cta svg { width: 12px; height: 12px; }
.shell.is-mobile .demo-banner {
  flex-direction: column; gap: 3px; font-size: 10.5px; line-height: 1.35;
  padding: 7px 14px; height: auto; min-height: 32px;
}

/* ---------- Demo entry gate ---------- */
.demo-entry {
  min-height: 100vh; display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 24px; padding: 24px; background: var(--gray-100);
}
.demo-entry-logo img { height: 22px; }
.demo-entry-logo svg { height: 22px; width: auto; display: block; color: var(--primary-logo); }
.demo-entry-hero .demo-entry-logo svg { color: #fff; }
.demo-entry-card-shell { position: relative; width: 100%; max-width: 420px; }
.demo-entry-card-shell::before {
  content: ""; position: absolute; left: 6px; right: 6px; bottom: -10px; height: 40px;
  background: #C6FF00; border-radius: 16px; z-index: 0;
}
.demo-entry-card {
  position: relative; z-index: 1;
  width: 100%; background: #fff; border-radius: 16px;
  padding: 33px 36px; box-shadow: 0 1px 2px rgba(16, 24, 40, .04);
  display: flex; flex-direction: column; align-items: stretch; text-align: center;
}
.demo-entry-eyebrow {
  align-self: center; display: inline-flex; align-items: center; gap: 8px;
  background: #fff; color: #1D1700; box-shadow: 0 0 0 1px #1D1700, inset 0 -2px 6px rgba(255, 255, 255, .1);
  font-family: "Euclid Circular A", sans-serif; font-size: 13px; font-weight: 500; letter-spacing: 0;
  text-transform: none; padding: 8px 16px 8px 14px; border-radius: 999px; margin-bottom: 16px;
}
.demo-entry-dot { position: relative; width: 8px; height: 8px; flex-shrink: 0; }
.demo-entry-dot-core, .demo-entry-dot-ring { position: absolute; inset: 0; border-radius: 50%; background: #FF3600; }
.demo-entry-dot-ring { animation: demo-dot-pulse 1.8s ease-out infinite; }
@keyframes demo-dot-pulse {
  0% { transform: scale(1); opacity: .7; }
  100% { transform: scale(2.6); opacity: 0; }
}
@media (prefers-reduced-motion: reduce) { .demo-entry-dot-ring { animation: none; opacity: .35; } }
.demo-entry-card h1 {
  font-family: "Feature Display Trial", Georgia, serif;
  font-size: 27px; font-weight: 400; color: #000; margin: 0 0 12px; line-height: 1.22; letter-spacing: -0.01em;
}
.demo-entry-lede { font-size: 13.5px; color: var(--gray-500); margin: 0 0 20px; line-height: 1.55; }
.demo-entry-features {
  display: flex; flex-direction: column; gap: 12px; text-align: left;
  background: var(--gray-50); border-radius: 10px; padding: 16px; margin-bottom: 22px;
}
.demo-entry-feature { display: flex; align-items: center; gap: 12px; font-size: 13.5px; color: #000; font-weight: 300; }
.demo-entry-divider { display: flex; align-items: center; gap: 10px; margin: 20px 0; color: var(--gray-400); font-size: 12px; }
.demo-entry-divider::before, .demo-entry-divider::after { content: ""; flex: 1; height: 1px; background: var(--gray-200); }
.demo-entry-personal-lbl { font-size: 12.5px; font-weight: 600; color: #2A313C; margin-bottom: 10px; }
.demo-entry-stores { display: flex; gap: 8px; }
.demo-entry-store {
  flex: 1; display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 10px 12px; border: 1px solid var(--gray-200); border-radius: 10px;
  font-size: 12.5px; font-weight: 600; color: #2A313C; text-decoration: none;
}
.demo-entry-store svg { flex-shrink: 0; }
.demo-entry-store:hover { border-color: var(--gray-300); background: var(--gray-50); }

/* Desktop: photo is full-bleed behind everything, card floats on top of it — matches the
   design reference (not a two-column split). */
.demo-entry.demo-entry-hero {
  position: relative; min-height: 100vh; overflow: hidden;
  display: block; padding: 0; background: #0c1a2e;
}
.demo-entry-hero-photo {
  position: absolute; inset: 0; z-index: 0;
  background-image: url("../v0/design-system/assets/demo-entry-hero.jpg");
  background-size: cover; background-position: center;
}
.demo-entry-hero-scrim {
  position: absolute; left: 0; right: 0; bottom: 0; height: 55%; z-index: 1;
  background: linear-gradient(180deg, rgba(12, 26, 46, 0) 0%, rgba(12, 26, 46, .82) 100%);
}
.demo-entry-hero .demo-entry-accent {
  position: absolute; right: 0; bottom: 0; width: 50%; height: auto; z-index: 1; pointer-events: none;
}
.demo-entry-hero .demo-entry-logo {
  position: absolute; top: 44px; left: 64px; z-index: 2;
}
.demo-entry-hero .demo-entry-card-shell {
  position: relative; z-index: 2; margin: 168px 0 0 64px; max-width: 460px;
}
.demo-entry-hero .demo-entry-card { box-shadow: 0 12px 40px rgba(12, 26, 46, .22); }
.demo-entry-hero .demo-entry-card h1 { font-size: 32px; }

/* ---------- Demo completion-moment CTA ---------- */
.demo-cta {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  margin-top: 18px; padding: 14px 16px; border-radius: 12px;
  background: var(--gray-50); border: 1px solid var(--gray-200);
  font-size: 12.5px; color: var(--gray-700); text-align: left;
}
.demo-cta .btn { flex-shrink: 0; }

/* ---------- Demo guided-nudges panel ---------- */
.nudges-fab {
  position: fixed; right: 20px; bottom: 20px; z-index: 8;
  display: flex; align-items: center; gap: 8px;
  background: var(--gray-900); color: #fff; border: 0; border-radius: 999px;
  padding: 9px 16px 9px 9px; font-size: 12.5px; font-weight: 600; cursor: pointer;
  box-shadow: 0 4px 16px rgba(15, 23, 42, .22);
}
.nudges-fab-ring { width: 22px; height: 22px; flex-shrink: 0; }
.nudges-fab-ring svg { width: 100%; height: 100%; }
.shell.is-mobile .nudges-fab { bottom: 84px; right: 14px; }

.nudges-panel {
  position: fixed; right: 20px; bottom: 20px; z-index: 8; width: 268px;
  background: #fff; border: 1px solid var(--gray-200); border-radius: 14px;
  box-shadow: 0 8px 28px rgba(15, 23, 42, .16); overflow: hidden;
}
.shell.is-mobile .nudges-panel { right: 14px; left: 14px; width: auto; bottom: 84px; }
.nudges-head { display: flex; align-items: flex-start; justify-content: space-between; padding: 14px 14px 10px; }
.nudges-title { font-size: 13.5px; font-weight: 600; color: var(--gray-900); }
.nudges-sub { font-size: 11.5px; color: var(--gray-500); margin-top: 2px; }
.nudges-min {
  width: 22px; height: 22px; border-radius: 999px; border: 1px solid var(--gray-200); background: #fff;
  color: var(--gray-500); font-size: 15px; line-height: 1; cursor: pointer; flex-shrink: 0;
}
.nudges-list { display: flex; flex-direction: column; padding: 0 8px 6px; }
.nudges-item {
  display: flex; align-items: center; gap: 9px; text-align: left;
  border: 0; background: transparent; border-radius: 8px; padding: 8px 6px;
  font-size: 12.5px; color: var(--gray-700); cursor: pointer;
}
.nudges-item:hover { background: var(--gray-50); }
.nudges-item.active { background: var(--gray-50); color: var(--gray-900); font-weight: 600; }
.nudges-item.done { color: var(--gray-400); text-decoration: line-through; }
.nudges-check {
  width: 16px; height: 16px; border-radius: 999px; border: 1.5px solid var(--gray-300); flex-shrink: 0;
  display: grid; place-items: center; color: #fff;
}
.nudges-item.done .nudges-check { background: var(--success-600, #16A34A); border-color: var(--success-600, #16A34A); }
.nudges-cta {
  display: flex; align-items: center; justify-content: center; gap: 6px;
  margin: 6px 10px 0; padding: 10px; background: var(--gray-900); color: #fff;
  border-radius: 9px; font-size: 12.5px; font-weight: 600; text-decoration: none;
}
.nudges-secondary {
  display: block; text-align: center; margin: 8px 10px 0; padding: 8px;
  font-size: 11.5px; font-weight: 600; color: var(--gray-600); text-decoration: none;
  border: 1px solid var(--gray-200); border-radius: 9px;
}
.nudges-secondary:hover { background: var(--gray-50); }
.nudges-dismiss {
  display: block; width: 100%; text-align: center; border: 0; background: transparent;
  color: var(--gray-400); font-size: 11.5px; padding: 10px 0 12px; cursor: pointer;
}
.nudges-dismiss:hover { color: var(--gray-600); }

.topbar {
  grid-column: 1 / -1;
  background: #fff;
  display: flex; align-items: center;
  padding: 0 28px 0 22px;
  box-shadow: var(--shadow-nav);
  position: relative; z-index: 5;
}
.topbar .brand { display: flex; align-items: center; gap: 12px; flex: 0 0 calc(var(--layout-sidebar) - 22px); }
.topbar .brand img { height: 18px; width: auto; }
.topbar .right { margin-left: auto; display: flex; align-items: center; gap: 14px; }
.topbar .avatar {
  width: 34px; height: 34px; border-radius: 999px;
  background: linear-gradient(135deg, #5433FF, #321F99);
  color: #fff; display: grid; place-items: center; font-weight: 600; font-size: 12px;
}
.topnav-wa {
  display: flex; align-items: center; justify-content: center;
  width: 34px; height: 34px; border-radius: 8px;
  color: #16A34A;
  text-decoration: none;
  flex-shrink: 0;
}
.topnav-wa:hover { background: #F0FDF4; }
.topbar .gear {
  width: 34px; height: 34px; border-radius: 999px; background: var(--gray-100);
  display: grid; place-items: center; color: var(--gray-700); border: 0; cursor: pointer; flex-shrink: 0;
}
.topbar .gear:hover { background: var(--gray-200); }

.sidebar-v1 { background: #fff; padding: 12px 0 24px; overflow: hidden; border-right: 1px solid var(--gray-200); min-height: 0; display: flex; flex-direction: column; }
.sb-item {
  display: flex; align-items: center; gap: 12px;
  padding: 11px 22px; font-size: 13.5px; color: var(--gray-900);
  cursor: pointer; border-right: 2px solid transparent; user-select: none;
}
.sb-item:hover { background: var(--row-hover); }
.sb-item.active { color: var(--info-700); border-right-color: var(--info-700); font-weight: 500; background: #F8FAFD; }
.sb-item svg { width: 18px; height: 18px; }
.nav-badge {
  margin-left: -8px; flex-shrink: 0;
  font-size: 9.5px; font-weight: 700; letter-spacing: 0.04em; text-transform: uppercase;
  color: var(--gray-500); background: var(--gray-100);
  padding: 2px 7px; border-radius: 999px; line-height: 1.5;
}
.sb-group { padding: 18px 22px 6px; font-size: 11px; font-weight: 700; color: var(--gray-600); letter-spacing: 0.06em; text-transform: uppercase; }
.sb-foot { margin-top: auto; padding: 14px 22px; font-size: 11px; color: var(--gray-500); }

.sb-am-card { margin: 0 10px 8px; padding: 12px 14px; background: #F0FDF4; border: 1px solid #BBF7D0; border-radius: 12px; }
.sb-am-top { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.sb-am-ava { width: 32px; height: 32px; border-radius: 999px; background: #16A34A; color: #fff; display: grid; place-items: center; font-size: 11.5px; font-weight: 700; flex-shrink: 0; letter-spacing: 0.02em; }
.sb-am-name { font-size: 12.5px; font-weight: 600; color: var(--gray-900); line-height: 1.3; }
.sb-am-role { font-size: 11px; color: var(--gray-600); margin-top: 1px; }
.sb-am-cta { display: flex; align-items: center; justify-content: center; gap: 7px; width: 100%; padding: 7px 10px; background: #16A34A; color: #fff; border-radius: 8px; font-size: 12px; font-weight: 500; text-decoration: none; }
.sb-am-cta:hover { background: #15803D; }

/* ---------- Mobile ---------- */
.shell.is-mobile { padding-bottom: calc(68px + env(safe-area-inset-bottom)); }

.topbar-mobile {
  position: sticky; top: 0; z-index: 5;
  background: #fff; box-shadow: var(--shadow-nav);
  display: flex; align-items: center; gap: 12px;
  padding: 14px 18px;
  padding-top: calc(14px + env(safe-area-inset-top));
}
.topbar-mobile .brand img { height: 16px; width: auto; }
.topbar-mobile .right { margin-left: auto; display: flex; align-items: center; gap: 10px; }
.topbar-mobile .avatar {
  width: 30px; height: 30px; border-radius: 999px;
  background: linear-gradient(135deg, #5433FF, #321F99);
  color: #fff; display: grid; place-items: center; font-weight: 600; font-size: 11px;
}
.topbar-mobile .gear {
  width: 30px; height: 30px; border-radius: 999px; background: var(--gray-100);
  display: grid; place-items: center; color: var(--gray-700); border: 0; cursor: pointer;
}
.topbar-mobile .topnav-wa { width: 30px; height: 30px; border-radius: 999px; }

.bottom-tabs {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 10;
  display: flex;
  background: #fff;
  border-top: 1px solid var(--gray-200);
  box-shadow: 0 -6px 20px rgba(15, 23, 42, .08);
  padding: 8px 4px calc(8px + env(safe-area-inset-bottom));
}
.bt-item {
  flex: 1; display: flex; flex-direction: column; align-items: center; gap: 3px;
  padding: 2px 2px; color: var(--gray-500); cursor: pointer; user-select: none;
  border: 0; background: transparent; font-family: var(--font-sans);
}
.bt-ic { display: flex; align-items: center; justify-content: center; width: 40px; height: 26px; border-radius: 14px; transition: background-color .15s, color .15s; }
.bt-ic svg { width: 21px; height: 21px; }
.bt-item .lbl { font-size: 10.5px; font-weight: 500; margin-top: 1px; transition: color .15s, font-weight .15s; }
.bt-item.active { color: var(--info-700); }
.bt-item.active .bt-ic { background: var(--info-100); color: var(--info-700); }
.bt-item.active .lbl { font-weight: 600; }

/* ---------- Content ---------- */
.content-desktop { min-width: 0; min-height: 0; display: flex; flex-direction: column; overflow-y: auto; }
.content-mobile { flex: 1; }

.page { padding: 60px 80px 80px; width: 100%; min-width: 0; }
.page h1.title { margin: 0 0 4px; font-size: 22px; font-weight: 600; color: var(--gray-900); letter-spacing: -0.01em; }
.page .subtitle { margin: 0 0 22px; font-size: 13px; color: var(--gray-600); }
.page.page-mobile { padding: 18px 16px 32px; }
.page.page-mobile h1.title { font-size: 19px; }
.page-head { display: flex; align-items: flex-end; justify-content: space-between; margin-bottom: 22px; gap: 16px; flex-wrap: wrap; }
.page-head .title { margin-bottom: 4px; }
.page-head .subtitle { margin: 0; }

/* =====================================================
   Sheet — bottom sheet (mobile) / centered modal (desktop)
   ===================================================== */
.sheet-overlay {
  position: fixed; inset: 0; z-index: 50;
  background: rgba(15, 23, 42, 0.45);
  display: flex;
}
.sheet {
  background: #fff;
  display: flex; flex-direction: column;
  max-height: 86vh;
}
.sheet-bottom {
  margin-top: auto; width: 100%;
  border-radius: 18px 18px 0 0;
  padding-bottom: env(safe-area-inset-bottom);
  animation: sheet-up .18s ease-out;
}
@keyframes sheet-up { from { transform: translateY(24px); opacity: .6; } to { transform: translateY(0); opacity: 1; } }
.sheet-modal {
  margin: auto; width: 440px; max-width: calc(100vw - 40px);
  border-radius: 12px;
}
.sheet-handle { width: 36px; height: 4px; border-radius: 999px; background: var(--gray-300); margin: 10px auto 0; flex-shrink: 0; }
.sheet-head { display: flex; align-items: center; justify-content: space-between; padding: 16px 20px 12px; flex-shrink: 0; }
.sheet-title { font-size: 15px; font-weight: 600; color: var(--gray-900); }
.sheet-close { width: 28px; height: 28px; border-radius: 999px; border: 0; background: var(--gray-100); color: var(--gray-600); display: grid; place-items: center; cursor: pointer; }
.sheet-body { padding: 0 20px 20px; overflow-y: auto; }

/* =====================================================
   Records — adaptive table (desktop) / card list (mobile)
   ===================================================== */
.records-card { background: #fff; border-radius: var(--radius-sm); box-shadow: var(--shadow-card); overflow: hidden; }
.records-head { display: flex; justify-content: space-between; align-items: center; padding: 14px 18px; gap: 12px; }
.records-head h2 { margin: 0; font-size: 16px; font-weight: 600; color: var(--gray-900); }
.records-head .meta { font-size: 12px; color: var(--gray-600); }
.records-head-right { display: flex; align-items: center; gap: 10px; }
.records-viewall { font-size: 12px; color: var(--info-700); cursor: pointer; font-weight: 500; text-decoration: none; }
.records-viewall:hover { text-decoration: underline; }

table.records-table { width: 100%; border-collapse: collapse; font-size: 13px; }
table.records-table th, table.records-table td { padding: 12px 18px; text-align: left; vertical-align: middle; white-space: nowrap; }
table.records-table th { color: var(--gray-600); font-weight: 600; font-size: 11px; text-transform: uppercase; letter-spacing: 0.06em; border-top: 1px solid var(--gray-200); border-bottom: 1px solid var(--gray-200); background: #FAFBFC; }
table.records-table tbody tr { border-bottom: 1px solid var(--gray-200); }
table.records-table tbody tr:last-child { border-bottom: 0; }
table.records-table tbody tr:hover td { background: var(--row-hover); cursor: pointer; }
table.records-table .num { text-align: right; font-variant-numeric: tabular-nums; }
table.records-table th.num { text-align: right; }

.records-list { display: flex; flex-direction: column; }
.records-row {
  display: flex; align-items: center; gap: 12px;
  padding: 14px 16px; border-bottom: 1px solid var(--gray-200);
}
.records-row:last-child { border-bottom: 0; }
.records-row .ic {
  width: 36px; height: 36px; border-radius: 999px; flex-shrink: 0;
  display: grid; place-items: center;
  position: relative;
}
.records-row .ic.in  { background: var(--success-100); color: var(--success-700); }
.records-row .ic.out { background: var(--gray-100); color: var(--gray-700); }
.records-row .ic svg { width: 16px; height: 16px; }

/* Tiny pulsing corner dot — flags a row as still in flight (processing / on hold)
   without touching the icon's color or shape, which still carries the in/out meaning. */
.ic-dot {
  /* A circle's arc curves away from its bounding box's corners, so a badge parked at
     top:-2px/right:-2px (the corner) reads as floating. Sitting near 0/0 lands it on the
     curve itself, roughly where a ray from the circle's center at 45° actually crosses it. */
  position: absolute; top: 0; right: 0;
  width: 9px; height: 9px; border-radius: 999px;
  background: var(--warning-500);
  box-shadow: 0 0 0 2px #fff;
  animation: ic-dot-pulse 1.6s ease-in-out infinite;
}
@keyframes ic-dot-pulse {
  0%, 100% { box-shadow: 0 0 0 2px #fff, 0 0 0 2px rgba(234, 179, 8, .5); }
  50%      { box-shadow: 0 0 0 2px #fff, 0 0 0 6px rgba(234, 179, 8, 0); }
}

/* Failed is a terminal state, not an in-flight one — a static badge (not a pulse) reads as
   "this needs attention" rather than "still working". Softer tint (100/600, matching the
   .pill.danger / .set-chip.danger treatment elsewhere) instead of a solid red disc — less
   alarming. The X is two CSS bars, not an SVG stroke or a text glyph: both of those turned
   to mush or sat off-center at this size; two explicitly-sized, explicitly-centered
   rectangles can't drift regardless of font metrics or viewBox scaling. */
.ic-badge {
  /* The X is a background-image SVG rather than a stroked child, text glyph, or CSS bars —
     all of those drifted off-center by a subpixel at this size (inline baseline gap /
     font metrics / fractional-margin rounding that shifts with scroll position). As a
     background image the browser rasterizes and centers it in one pass, so it stays put. */
  position: absolute; top: -1px; right: -1px;
  width: 13px; height: 13px; border-radius: 999px;
  box-shadow: 0 0 0 2px #fff;
  background-color: var(--danger-100);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23DC2626' stroke-width='3' stroke-linecap='round'%3E%3Cpath d='M5 5l14 14M19 5L5 19'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
  background-size: 8px 8px;
}
.records-row .mid { flex: 1; min-width: 0; }
.records-row .party { font-size: 13.5px; font-weight: 500; color: var(--gray-900); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.records-row .sub { font-size: 11.5px; color: var(--gray-500); margin-top: 2px; display: flex; align-items: center; gap: 6px; }
.records-row .amt { text-align: right; flex-shrink: 0; }
.records-row .amt .n { font-weight: 600; font-variant-numeric: tabular-nums; font-size: 13.5px; }
.records-row .amt .n.in  { color: var(--success-700); }
.records-row .amt .n.out { color: var(--gray-900); }

.empty { text-align: center; padding: 40px 16px; color: var(--gray-600); }
.empty .ic { width: 40px; height: 40px; border-radius: 999px; background: var(--gray-100); color: var(--gray-500); display: grid; place-items: center; margin: 0 auto 12px; }
.empty .ic svg { width: 18px; height: 18px; }

/* =====================================================
   Dashboard
   ===================================================== */
.home-hero { background: #fff; border-radius: var(--radius-sm); box-shadow: var(--shadow-card); padding: 26px 28px; margin-bottom: 22px; }
.home-hero-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 18px; }
.home-acct-label { display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 500; color: var(--gray-700); }
.home-status { display: flex; align-items: center; gap: 6px; font-size: 12px; color: var(--gray-600); }
.home-status .dot { width: 6px; height: 6px; border-radius: 999px; background: #22C55E; }
.home-balance { display: flex; align-items: baseline; gap: 8px; margin-bottom: 22px; }
.home-balance-num { font-size: 36px; font-weight: 600; color: var(--gray-900); letter-spacing: -0.015em; font-variant-numeric: tabular-nums; }
.home-balance-ccy { font-size: 14px; font-weight: 500; color: var(--gray-500); }
.home-actions { display: flex; gap: 12px; margin-bottom: 20px; }
.home-divider { height: 1px; background: var(--gray-200); margin-bottom: 14px; }
.home-rails-note { font-size: 12px; color: var(--gray-500); }

.page-mobile .home-hero { padding: 20px; }
.page-mobile .home-balance-num { font-size: 30px; }
.page-mobile .home-actions { flex-direction: row; }

.skel { background: linear-gradient(90deg, var(--gray-100) 25%, var(--gray-200) 37%, var(--gray-100) 63%); background-size: 400% 100%; animation: skel-shine 1.4s ease infinite; border-radius: 6px; }
@keyframes skel-shine { 0% { background-position: 100% 0; } 100% { background-position: 0 0; } }

/* =====================================================
   Deposit — rail tabs, banners, field/fee grids, status panels
   ===================================================== */
.rail-tabs {
  display: flex; gap: 4px;
  border-bottom: 1px solid var(--gray-200);
  margin: 0 -24px; padding: 0 24px 0;
  overflow-x: auto; -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.rail-tabs::-webkit-scrollbar { display: none; }
.rail-tab {
  appearance: none; background: transparent; border: 0;
  padding: 10px 14px; font-family: var(--font-sans);
  font-size: 13px; font-weight: 500; color: var(--gray-600);
  cursor: pointer; white-space: nowrap; flex-shrink: 0;
  border-bottom: 2px solid transparent; margin-bottom: -1px;
  transition: color .12s ease, border-color .12s ease;
}
.rail-tab:hover { color: var(--gray-900); }
.rail-tab.on { color: var(--info-700); border-bottom-color: var(--info-700); }
.page-mobile .rail-tabs { margin: 0 -16px; padding: 0 16px 0; }

.banner {
  display: flex; align-items: flex-start; gap: 14px;
  padding: 16px 20px; border-radius: var(--radius-sm); border: 1px solid;
  margin-bottom: 18px;
}
/* Title-less notices are a single line (or two) of copy — center the icon against it so the
   36px icon square doesn't leave dead space below the text (which top-alignment does). */
.banner.banner-notitle { align-items: center; }
.banner .icw { flex: 0 0 36px; height: 36px; border-radius: 8px; display: grid; place-items: center; }
.banner .icw svg { width: 18px; height: 18px; }
.banner .body { flex: 1; min-width: 0; }
.banner .ttl { font-size: 14px; font-weight: 600; color: var(--gray-900); margin: 0 0 2px; }
.banner .copy { font-size: 13px; color: var(--gray-700); line-height: 1.5; }

/* Title-less notices (single-line rate/conversion/warning copy) read as oversized at the full
   titled-banner size — trim padding/icon/type for that case only. Titled banners (e.g. "Deposits
   disabled") keep the larger treatment on both breakpoints. Desktop gets the biggest trim (more
   dead space at that width); mobile gets a lighter touch. */
@media (min-width: 768px) {
  .banner.banner-notitle { padding: 11px 16px; gap: 10px; }
  .banner.banner-notitle .icw { flex-basis: 26px; height: 26px; border-radius: 7px; }
  .banner.banner-notitle .icw svg { width: 13px; height: 13px; }
  .banner.banner-notitle .copy { font-size: 12.5px; }
}
.page-mobile .banner.banner-notitle { padding: 13px 16px; gap: 12px; }
.page-mobile .banner.banner-notitle .icw { flex-basis: 30px; height: 30px; border-radius: 7px; }
.page-mobile .banner.banner-notitle .icw svg { width: 15px; height: 15px; }
.page-mobile .banner.banner-notitle .copy { font-size: 12.5px; }
.banner.info    { background: #EFF6FF; border-color: #BFDBFE; }
.banner.info    .icw { background: var(--info-100); color: var(--info-700); }
.banner.warn    { background: #FFFBEB; border-color: #FDE68A; }
.banner.warn    .icw { background: #FEF3C7; color: #A16207; }
.banner.danger  { background: #FEF2F2; border-color: #FECACA; }
.banner.danger  .icw { background: var(--danger-100); color: var(--danger-700); }
.banner.neutral { background: #F8FAFC; border-color: var(--gray-300); }
.banner.neutral .icw { background: var(--gray-200); color: var(--gray-700); }

.copyinline {
  background: transparent; border: 0; cursor: pointer; color: var(--gray-500);
  display: inline-flex; align-items: center; justify-content: center;
  padding: 6px; border-radius: 6px;
  transition: background-color .12s ease, color .12s ease;
}
.copyinline:hover { background: var(--info-100); color: var(--info-700); }
.copyinline svg { width: 14px; height: 14px; }

.timechip {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 4px 10px; border-radius: 999px;
  background: var(--gray-100); color: var(--gray-700);
  font-size: 11.5px; font-weight: 500; flex-shrink: 0;
}
.timechip svg { width: 12px; height: 12px; }
.timechip.fast { background: var(--success-100); color: var(--success-700); }
.timechip.med  { background: var(--info-100); color: var(--info-700); }
.timechip.slow { background: var(--warning-100); color: #A16207; }

.field-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 24px; margin-bottom: 20px; }
.field-grid-mobile { grid-template-columns: 1fr; gap: 14px; }
.field-item { min-width: 0; }
.field-k { font-size: 11px; font-weight: 600; letter-spacing: 0.04em; color: var(--gray-500); text-transform: uppercase; margin-bottom: 5px; }
.field-v { font-size: 13.5px; color: var(--gray-900); font-weight: 500; font-variant-numeric: tabular-nums; display: flex; align-items: center; gap: 6px; }
.field-v span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.fee-section { border-top: 1px solid var(--gray-200); padding-top: 18px; margin-bottom: 20px; }
.fee-section-label { font-size: 11px; font-weight: 600; letter-spacing: 0.04em; color: var(--gray-500); text-transform: uppercase; margin-bottom: 12px; }
.fee-grid { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 10px; }
.fee-grid-mobile { grid-template-columns: 1fr; }
.fee-card { padding: 12px 14px; background: var(--gray-50); border-radius: 10px; border: 1px solid var(--gray-200); }
.fee-rail { font-size: 12.5px; font-weight: 600; color: var(--gray-900); margin-bottom: 8px; }
.fee-line { font-size: 12px; color: var(--gray-600); margin-bottom: 4px; }
.fee-line span { font-weight: 500; color: var(--gray-900); }
.fee-line:last-child { margin-bottom: 0; }

.rail-panel { padding: 24px 28px 28px; }
.page-mobile .rail-panel { padding: 18px 16px 24px; }
.panel-intro { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 18px; }
.panel-intro-desc { font-size: 12.5px; color: var(--gray-700); line-height: 1.55; flex: 1 1 auto; min-width: 0; }

/* Stablecoin deposit — QR alongside the address (stacks on narrow widths). */
.qr-block { display: flex; align-items: center; gap: 20px; flex-wrap: wrap; margin-bottom: 20px; }
.qr-frame { width: 148px; height: 148px; padding: 8px; background: #fff; border: 1px solid var(--gray-200); border-radius: 12px; flex-shrink: 0; }
.qr-frame .qr { display: block; width: 100%; height: 100%; }
.qr-side { flex: 1; min-width: 200px; }
.qr-side-lbl { font-size: 11px; font-weight: 600; letter-spacing: 0.04em; color: var(--gray-500); text-transform: uppercase; margin-bottom: 6px; }
.qr-side-addr { font-size: 13.5px; color: var(--gray-900); font-weight: 500; font-variant-numeric: tabular-nums; white-space: nowrap; line-height: 1.5; margin-bottom: 12px; }
.qr-side-hint { font-size: 12px; color: var(--gray-500); line-height: 1.5; margin-top: 12px; }

/* Desktop keeps the tab bar (RailTabs supplies its own divider + spacing), so the head has
   no bottom border/padding there. Mobile swaps in the currency selector and needs its own
   divider + bottom padding since the tab bar is gone. */
.deposit-head { padding: 22px 28px 0; }
.page-mobile .deposit-head { padding: 16px 16px 16px; border-bottom: 1px solid var(--gray-200); }
.deposit-head-row { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; flex-wrap: wrap; margin-bottom: 14px; }
.page-mobile .deposit-head-row { margin-bottom: 12px; }
.deposit-head-row h2 { margin: 0; font-size: 15.5px; font-weight: 600; color: var(--gray-900); }
.deposit-head-note { font-size: 12.5px; color: var(--gray-600); }

.usd-rail-badge { padding: 5px 12px; border-radius: 6px; font-size: 12px; font-weight: 600; background: var(--gray-100); color: var(--gray-700); letter-spacing: 0.02em; }

.status-panel { padding: 40px 28px 44px; text-align: center; }
.status-panel-ic { width: 52px; height: 52px; border-radius: 14px; display: grid; place-items: center; margin: 0 auto 16px; }
.status-panel-ic svg { width: 24px; height: 24px; }
.status-panel-title { font-size: 16px; font-weight: 600; color: var(--gray-900); margin-bottom: 8px; }
.status-panel-desc { font-size: 13.5px; color: var(--gray-600); max-width: 420px; margin: 0 auto 20px; line-height: 1.6; }
.page-mobile .status-panel { padding: 32px 20px 36px; }

.stepper { display: flex; align-items: center; justify-content: center; margin-bottom: 40px; flex-wrap: wrap; }
.stepper-line { flex: 0 1 32px; height: 1px; margin: 0 10px; }
.stepper-node { display: flex; align-items: center; gap: 6px; flex-shrink: 0; }
.stepper-dot { width: 24px; height: 24px; border-radius: 99px; font-size: 12px; font-weight: 600; display: grid; place-items: center; }
.stepper-dot svg { width: 14px; height: 14px; }
.stepper-label { font-size: 13px; }

/* Mobile — a horizontal 3-step row with real labels ("Verify with partner") just wraps
   into a mess at phone width. Stack it as a small vertical timeline instead: dot+label
   per row, with a short connecting tick between rows rather than the horizontal dash. */
.page-mobile .stepper { flex-direction: column; align-items: flex-start; gap: 0; margin-bottom: 28px; }
.page-mobile .stepper-line { display: none; }
.page-mobile .stepper-node { width: 100%; position: relative; margin-bottom: 14px; }
.page-mobile .stepper-node:last-child { margin-bottom: 0; }
.page-mobile .stepper-node:not(:first-child)::before {
  content: "";
  position: absolute; left: 11px; top: -14px;
  width: 2px; height: 14px;
  background: var(--gray-200);
}
.page-mobile .stepper-label { font-size: 13.5px; }

.chan-picker { display: flex; gap: 8px; flex-wrap: wrap; }
.chan-btn {
  padding: 6px 14px; border-radius: 8px; border: 1.5px solid var(--gray-200);
  background: #fff; color: var(--gray-700); font-size: 13px; font-weight: 500;
  cursor: pointer; display: inline-flex; align-items: center; gap: 7px;
}
.chan-btn.on { background: var(--info-100); color: var(--info-700); border-color: var(--info-100); }
.chan-btn svg { width: 16px; height: 16px; flex-shrink: 0; }

/* Mobile network dropdown — deliberately lighter than the Combobox currency selector
   (plain select, no card/avatar/search): it's a secondary choice nested under the coin,
   and a real backend can list ~10 networks — too many to lay out as wrapping chips. */
.net-select-wrap { position: relative; display: block; width: 100%; }
.net-select {
  appearance: none; -webkit-appearance: none; width: 100%;
  padding: 9px 32px 9px 12px; border: 1px solid var(--gray-300); border-radius: 8px;
  background: #fff; font-size: 13px; font-weight: 500; color: var(--gray-900);
  font-family: inherit; cursor: pointer; outline: none;
}
.net-select-wrap .net-select-icon + .net-select { padding-left: 34px; }
.net-select:hover { border-color: var(--gray-400); }
.net-select:focus { border-color: var(--info-700); box-shadow: 0 0 0 3px rgba(29,78,216,.10); }
.net-select-wrap > svg { position: absolute; right: 10px; top: 50%; transform: translateY(-50%); width: 14px; height: 14px; color: var(--gray-500); pointer-events: none; }
.net-select-icon { position: absolute; left: 10px; top: 50%; transform: translateY(-50%); width: 16px; height: 16px; display: flex; align-items: center; justify-content: center; pointer-events: none; }
.net-select-icon svg { width: 16px; height: 16px; }

.gen-progress { height: 4px; width: 160px; margin: 0 auto; border-radius: 999px; background: var(--gray-200); overflow: hidden; }
.gen-progress span { display: block; height: 100%; width: 40%; background: var(--info-700); border-radius: 999px; animation: gen-progress-slide 1.1s ease-in-out infinite; }
@keyframes gen-progress-slide { 0% { margin-left: -40%; } 100% { margin-left: 100%; } }
.spin { display: inline-block; border: 2.5px solid var(--info-100); border-top-color: var(--info-700); border-radius: 999px; animation: spin-rotate .7s linear infinite; }
@keyframes spin-rotate { to { transform: rotate(360deg); } }

.toast {
  position: fixed; bottom: 24px; right: 24px;
  background: #0F172A; color: #fff; padding: 10px 16px; border-radius: 8px;
  font-size: 13px; font-weight: 500; display: flex; align-items: center; gap: 8px;
  box-shadow: 0 12px 32px rgba(0,0,0,.18); z-index: 100;
  animation: toast-in .2s ease-out;
}
.toast svg { width: 14px; height: 14px; color: #4ADE80; }
.toast-mobile { left: 16px; right: 16px; bottom: calc(76px + env(safe-area-inset-bottom)); justify-content: center; }
@keyframes toast-in { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: translateY(0); } }

/* =====================================================
   Send payment
   ===================================================== */
.flow-shell { display: grid; grid-template-columns: 184px 1fr; gap: 0 48px; align-items: start; }
.flow-steps { padding-top: 4px; position: sticky; top: 32px; }
.flow-step { display: flex; align-items: center; gap: 12px; }
.flow-step-dot { width: 26px; height: 26px; border-radius: 999px; display: grid; place-items: center; font-size: 12px; font-weight: 600; flex-shrink: 0; }
.flow-step-dot svg { width: 13px; height: 13px; }
.flow-step.todo   .flow-step-dot { background: transparent; color: var(--gray-400); border: 1.5px solid var(--gray-300); }
.flow-step.active .flow-step-dot { background: var(--info-700); color: #fff; border: 1.5px solid var(--info-700); }
.flow-step.done   .flow-step-dot { background: var(--gray-100); color: var(--gray-500); border: 1.5px solid var(--gray-200); }
.flow-step-lbl { font-size: 13px; font-weight: 500; }
.flow-step.todo   .flow-step-lbl { color: var(--gray-400); }
.flow-step.active .flow-step-lbl { color: var(--gray-900); font-weight: 600; }
.flow-step.done   .flow-step-lbl { color: var(--gray-500); }
.flow-step-connector { height: 20px; width: 1.5px; background: var(--gray-200); margin: 3px 0 3px 12px; }
.flow-content { min-width: 0; }
.flow-content .pay-panel { min-height: unset; }

/* Mobile — horizontal compact step bar instead of the vertical sidebar */
.flow-mobile-bar { display: flex; align-items: center; gap: 6px; margin-bottom: 16px; }
.flow-mobile-dot { width: 8px; height: 8px; border-radius: 999px; background: var(--gray-300); flex-shrink: 0; }
.flow-mobile-dot.active { background: var(--info-700); width: 20px; border-radius: 999px; }
.flow-mobile-dot.done { background: var(--success-500); }
.flow-mobile-label { font-size: 12.5px; font-weight: 600; color: var(--gray-900); margin-left: 8px; }

.pay-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 22px; align-items: start; }
@media (max-width: 1100px) { .pay-grid { grid-template-columns: 1fr; } }

.pay-panel { background: #fff; border-radius: var(--radius-sm); box-shadow: var(--shadow-card); padding: 22px 24px; display: flex; flex-direction: column; min-height: 520px; }
.page-mobile .pay-panel { padding: 16px; min-height: unset; }
.pay-panel.placeholder { background: #FAFBFC; border: 1.5px dashed var(--gray-300); box-shadow: none; }
.pay-panel-head { margin-bottom: 16px; }
.pay-panel-title { font-size: 15px; font-weight: 600; color: var(--gray-900); }
.pay-panel-title.muted { color: var(--gray-500); }
.pay-panel-sub { font-size: 12.5px; color: var(--gray-600); margin-top: 2px; }

.pay-tabs { display: inline-flex; align-self: flex-start; background: var(--gray-100); border-radius: 10px; padding: 3px; gap: 2px; margin: 12px 0; }
.pay-tabs button { padding: 5px 14px; border-radius: 8px; font-size: 13px; font-weight: 500; border: none; cursor: pointer; background: transparent; color: var(--gray-500); font-family: var(--font-sans); }
.pay-tabs button.on { background: #fff; color: var(--gray-900); box-shadow: 0 1px 3px rgba(0,0,0,.1); }
.pay-tabs button .n { margin-left: 6px; font-size: 11px; font-weight: 600; opacity: .45; }

.pay-search { position: relative; margin-bottom: 12px; }
.pay-search svg { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); width: 14px; height: 14px; color: var(--gray-500); }
.pay-search input { width: 100%; box-sizing: border-box; padding: 9px 12px 9px 34px; font-size: 13px; font-family: var(--font-sans); border: 1px solid var(--gray-300); border-radius: 8px; background: #fff; outline: none; }
.pay-search input:focus { border-color: var(--info-700); box-shadow: 0 0 0 3px rgba(29,78,216,.12); }

.recip-add { display: flex; align-items: center; gap: 12px; width: 100%; padding: 11px 14px; border-radius: 8px; border: 1.5px dashed var(--gray-300); background: #fff; cursor: pointer; font-family: var(--font-sans); font-size: 13px; color: var(--gray-900); font-weight: 500; margin-bottom: 10px; }
.recip-add:hover { border-color: var(--info-700); background: #F8FAFE; }
.recip-add .ic { width: 26px; height: 26px; border-radius: 999px; background: var(--info-100); color: var(--info-700); display: grid; place-items: center; flex-shrink: 0; }
.recip-add .ic svg { width: 14px; height: 14px; }
.recip-add .t { flex: 1; text-align: left; }
.recip-add svg { width: 14px; height: 14px; color: var(--gray-500); }

.recip-list { display: flex; flex-direction: column; gap: 4px; overflow-y: auto; }
.recip-row { position: relative; display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 8px; border: 1.5px solid transparent; background: transparent; cursor: pointer; font-family: var(--font-sans); text-align: left; width: 100%; }
.recip-row:hover { background: var(--row-hover); }
.recip-row.on { background: #F8FAFE; border-color: var(--info-700); }
.recip-row .ava { position: relative; width: 36px; height: 36px; border-radius: 999px; background: linear-gradient(135deg, #5433FF, #321F99); color: #fff; font-size: 12px; font-weight: 600; display: grid; place-items: center; flex-shrink: 0; }
.recip-row .ava .ccy-flag { position: absolute; right: -2px; bottom: -2px; box-shadow: inset 0 0 0 1px rgba(15,23,42,.08), 0 0 0 2px #fff; }
.recip-row .meta { flex: 1; min-width: 0; }
.recip-row .meta .t { font-size: 13px; font-weight: 500; color: var(--gray-900); }
.recip-row .meta .s { font-size: 11.5px; color: var(--gray-600); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.recip-row .rt { text-align: right; font-size: 11.5px; }
.recip-row .rt .ccy { color: var(--gray-900); font-weight: 600; font-size: 12px; }
.recip-row .rt .last { color: var(--gray-500); font-size: 11px; margin-top: 1px; }
.recip-row .selected-mark { width: 20px; height: 20px; border-radius: 999px; background: var(--info-700); display: grid; place-items: center; flex-shrink: 0; }
.recip-row .selected-mark svg { width: 12px; height: 12px; stroke: #fff; color: #fff; }
.recip-row .selected-spacer { width: 20px; flex-shrink: 0; }
.recip-loader, .tx-loader { display: flex; align-items: center; justify-content: center; gap: 8px; padding: 16px; font-size: 12.5px; color: var(--gray-500); }
.recip-end, .tx-end { text-align: center; padding: 14px; font-size: 12px; color: var(--gray-500); }

.pay-recip-strip { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 10px; background: #F8FAFE; border: 1px solid #DBEAFE; margin-bottom: 16px; }
.pay-recip-strip .ava { position: relative; width: 32px; height: 32px; border-radius: 999px; background: linear-gradient(135deg, #5433FF, #321F99); color: #fff; font-size: 11px; font-weight: 600; display: grid; place-items: center; flex-shrink: 0; }
.pay-recip-strip .ava .ccy-flag { position: absolute; right: -2px; bottom: -2px; box-shadow: inset 0 0 0 1px rgba(15,23,42,.08), 0 0 0 2px #F8FAFE; }
.pay-recip-strip .meta { flex: 1; min-width: 0; }
.pay-recip-strip .meta .t { font-size: 13px; font-weight: 500; color: var(--gray-900); }
.pay-recip-strip .meta .s { font-size: 11.5px; color: var(--gray-600); }
.pay-recip-strip .rt { font-size: 12px; font-weight: 600; color: var(--info-700); }

.pay-fx { margin-bottom: 18px; position: relative; }
.pay-fx-row + .pay-fx-row { margin-top: 10px; }
.pay-fx-row .lb { font-size: 11.5px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--gray-700); margin-bottom: 8px; }
.amt-box { display: grid; grid-template-columns: 1fr auto; align-items: center; border: 2px solid var(--gray-300); border-radius: var(--radius-lg); background: #fff; }
.amt-box:focus-within { border-color: var(--info-700); box-shadow: 0 0 0 3px rgba(29,78,216,.12); }
.amt-box-err { border-color: var(--danger-600) !important; }
.amt-inp { appearance: none; border: 0; outline: none; background: transparent; padding: 14px 16px; font-family: var(--font-sans); font-size: 22px; font-weight: 600; color: var(--gray-900); font-variant-numeric: tabular-nums; letter-spacing: -0.01em; min-width: 0; width: 100%; }
.amt-inp::placeholder { color: var(--gray-400); font-weight: 500; }
.ccy-locked { display: inline-flex; align-items: center; gap: 8px; padding: 8px 14px; margin-right: 6px; background: #fff; border-radius: 8px; font-size: 13px; font-weight: 600; color: var(--gray-900); border: 1px solid var(--gray-300); }
.pay-fx-row .hint { margin-top: 6px; font-size: 11.5px; color: var(--gray-600); display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.pay-fx-row .hint .rate { font-weight: 500; color: var(--gray-700); font-variant-numeric: tabular-nums; display: inline-flex; align-items: center; gap: 6px; }
.pay-fx-row .hint .rate-fee { margin-left: auto; font-weight: 500; color: var(--gray-800); font-variant-numeric: tabular-nums; font-size: 12.5px; }
/* When the rate/countdown text is too wide to share the row (e.g. a double-digit rate), the fee
   used to wrap alone and float right via margin-left:auto, looking orphaned. Drop it to its own
   full-width, left-aligned line instead so it always reads as part of the same hint group. */
.page-mobile .pay-fx-row .hint .rate-fee { margin-left: 0; flex-basis: 100%; }
.rate-pulse { width: 6px; height: 6px; border-radius: 999px; background: #22C55E; box-shadow: 0 0 0 0 rgba(34,197,94,.55); animation: rate-pulse 1.8s ease-out infinite; display: inline-block; }
@keyframes rate-pulse { 0% { box-shadow: 0 0 0 0 rgba(34,197,94,.55); } 70% { box-shadow: 0 0 0 6px rgba(34,197,94,0); } 100% { box-shadow: 0 0 0 0 rgba(34,197,94,0); } }
.rate-refresh { color: var(--gray-500); font-size: 11.5px; font-variant-numeric: tabular-nums; margin-left: 4px; }
.pay-fx-divider { display: flex; align-items: center; justify-content: center; margin: 8px 0; position: relative; }
.pay-fx-divider::before, .pay-fx-divider::after { content: ""; flex: 1; height: 1px; background: var(--gray-200); }
.pay-fx-divider svg { margin: 0 12px; width: 14px; height: 14px; color: var(--gray-500); background: #fff; border: 1px solid var(--gray-300); border-radius: 999px; padding: 4px; box-sizing: content-box; }

.ccy-dd { position: relative; padding: 6px; }
.ccy-dd-btn { display: inline-flex; align-items: center; gap: 8px; padding: 8px 12px; background: #fff; border: 1px solid var(--gray-300); border-radius: 8px; font-family: var(--font-sans); font-size: 13px; font-weight: 600; color: var(--gray-900); cursor: pointer; }
.ccy-dd-btn:hover { background: var(--gray-100); }
.ccy-dd-btn svg { width: 12px; height: 12px; color: var(--gray-500); }
.ccy-dd-veil { position: fixed; inset: 0; z-index: 20; }
.ccy-dd-pop { position: absolute; top: calc(100% + 4px); right: 0; z-index: 21; background: #fff; border: 1px solid var(--gray-200); border-radius: 10px; box-shadow: var(--shadow-drop); padding: 4px; min-width: 220px; max-width: calc(100vw - 32px); max-height: 320px; overflow-y: auto; }
.ccy-dd-opt { display: flex; align-items: center; gap: 10px; width: 100%; padding: 9px 10px; background: transparent; border: 0; border-radius: 6px; font-family: var(--font-sans); font-size: 13px; color: var(--gray-900); cursor: pointer; text-align: left; }
.ccy-dd-opt:hover { background: var(--row-hover); }
.ccy-dd-opt.on { background: #F8FAFE; }
.ccy-dd-opt span { font-weight: 600; }
.ccy-dd-opt .muted { color: var(--gray-600); font-weight: 400; font-size: 12px; flex: 1; }
.ccy-dd-opt svg { width: 14px; height: 14px; color: var(--info-700); }

.pay-fields { margin-top: 18px; }
.pay-fields .lbl .req, .pay-fields .lbl .opt { color: var(--gray-500); font-weight: 500; }
.pay-select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23718096' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 9l7 7 7-7'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; padding-right: 38px; cursor: pointer; }
.pay-memo { resize: vertical; min-height: 56px; font-family: var(--font-sans); }

.pay-empty { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 40px 24px; }
.pay-empty .ic { width: 56px; height: 56px; border-radius: 14px; background: var(--gray-200); color: var(--gray-500); display: grid; place-items: center; margin-bottom: 16px; }
.pay-empty .ic svg { width: 24px; height: 24px; }
.pay-empty .t { font-size: 15px; font-weight: 600; color: var(--gray-700); margin-bottom: 6px; }
.pay-empty .s { font-size: 12.5px; color: var(--gray-600); max-width: 320px; line-height: 1.55; margin-bottom: 28px; }
.dotted-fields { display: flex; flex-direction: column; gap: 10px; width: 100%; max-width: 280px; opacity: .55; }
.dotted-row { height: 36px; border: 1.5px dashed var(--gray-300); border-radius: 8px; }
.dotted-row.short { width: 60%; }

.pay-flow-card { background: #fff; border-radius: var(--radius-sm); box-shadow: var(--shadow-card); padding: 26px 28px; }
.page-mobile .pay-flow-card { padding: 18px 16px; }

.pay-review-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; margin-bottom: 22px; flex-wrap: wrap; }
.pay-review-hero { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 12px; background: linear-gradient(180deg, #F8FAFE 0%, #fff 100%); border: 1px solid #DBEAFE; border-radius: 12px; padding: 22px 24px; margin-bottom: 24px; }
.page-mobile .pay-review-hero { grid-template-columns: 1fr; text-align: left; padding: 18px; gap: 14px; }
.page-mobile .pay-review-hero .arrow { transform: rotate(90deg); margin: 0; }
.pay-review-hero .leg .lbl { font-size: 11.5px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--gray-600); margin-bottom: 8px; }
.pay-review-hero .leg.right { text-align: right; }
.page-mobile .pay-review-hero .leg.right { text-align: left; }
.pay-review-hero .leg.right .sub { justify-content: flex-end; }
.page-mobile .pay-review-hero .leg.right .sub { justify-content: flex-start; }
.pay-review-hero .leg .big { font-size: 24px; font-weight: 600; color: var(--gray-900); font-variant-numeric: tabular-nums; letter-spacing: -0.015em; margin-bottom: 6px; }
.pay-review-hero .leg .sub { font-size: 12px; color: var(--gray-600); display: inline-flex; align-items: center; gap: 6px; }
.pay-review-hero .arrow { width: 36px; height: 36px; border-radius: 999px; background: #fff; border: 1px solid #DBEAFE; color: var(--info-700); display: grid; place-items: center; margin: 0 auto; }
.pay-review-hero .arrow svg { width: 16px; height: 16px; }
.pay-review-list { border-top: 1px solid var(--gray-200); }
.pay-review-list .row-item { display: grid; grid-template-columns: 220px 1fr; padding: 14px 0; border-bottom: 1px solid var(--gray-200); gap: 16px; align-items: start; }
.page-mobile .pay-review-list .row-item { grid-template-columns: 1fr; gap: 4px; }
.pay-review-list .row-item:last-child { border-bottom: 0; }
.pay-review-list .row-item .k { font-size: 12px; color: var(--gray-600); text-transform: uppercase; letter-spacing: 0.06em; font-weight: 600; }
.pay-review-list .row-item .v { font-size: 13.5px; color: var(--gray-900); }
.pay-review-list .row-item .v.strong { font-weight: 600; font-size: 15px; font-variant-numeric: tabular-nums; }
.pay-review-list .row-item .v svg { width: 13px; height: 13px; vertical-align: -2px; margin-right: 4px; color: var(--info-700); }
.pay-review-list .row-item .v .rate-refresh { margin-left: 8px; color: var(--gray-500); font-weight: 400; font-size: 12px; }
.pay-review-foot { display: flex; justify-content: space-between; align-items: center; margin-top: 24px; gap: 12px; }

.pay-confirm .pay-flow-card { text-align: center; padding: 64px 32px 44px; }
.page-mobile .pay-confirm .pay-flow-card { padding: 40px 20px 28px; }
.pay-confirm-icon { width: 72px; height: 72px; border-radius: 999px; background: var(--success-100); color: var(--success-700); display: grid; place-items: center; margin: 0 auto 22px; box-shadow: 0 0 0 8px rgba(34,197,94,.08); }
.pay-confirm-icon svg { width: 32px; height: 32px; }
.pay-confirm-title { font-size: 22px; font-weight: 600; color: var(--gray-900); letter-spacing: -0.01em; margin-bottom: 8px; }
.pay-confirm-sub { font-size: 14px; color: var(--gray-700); max-width: 480px; margin: 0 auto 28px; line-height: 1.55; }
.pay-confirm-ref { background: #F8FAFE; border: 1px solid #DBEAFE; text-align: center; border-radius: 12px; padding: 16px 22px; margin-bottom: 20px; display: inline-block; }
.pay-confirm-ref .lb { font-size: 11px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--info-700); margin-bottom: 4px; }
.pay-confirm-ref .ref { font-size: 20px; font-weight: 600; color: var(--gray-900); font-variant-numeric: tabular-nums; letter-spacing: 0.02em; }
.pay-confirm-meta { display: flex; flex-direction: column; gap: 8px; margin: 14px auto 0; width: max-content; max-width: 100%; padding-top: 14px; border-top: 1px dashed #DBEAFE; }
.pay-confirm-meta .m { display: flex; align-items: center; gap: 8px; }
.pay-confirm-meta .m svg { width: 14px; height: 14px; color: var(--gray-500); flex-shrink: 0; }
.pay-confirm-meta .m .t { font-size: 12.5px; color: var(--gray-700); }
.pay-confirm-meta .m .s { font-size: 12.5px; color: var(--gray-900); font-weight: 500; }
.pay-confirm-actions { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }

.pay-approve { max-width: 540px; margin: 0 auto; }
.pay-approve .pay-flow-card { text-align: center; padding: 56px 36px 36px; }
.page-mobile .pay-approve .pay-flow-card { padding: 32px 18px 24px; }
.pay-approve-icon { width: 64px; height: 64px; border-radius: 999px; background: var(--info-100); color: var(--info-700); display: grid; place-items: center; margin: 0 auto 18px; box-shadow: 0 0 0 8px rgba(59,130,246,.07); }
.pay-approve-icon svg { width: 28px; height: 28px; }
.pay-approve-title { font-size: 21px; font-weight: 600; color: var(--gray-900); letter-spacing: -0.01em; margin-bottom: 6px; }
.pay-approve-sub { font-size: 13.5px; color: var(--gray-600); max-width: 380px; margin: 0 auto 22px; line-height: 1.5; }
.pay-approve-summary { background: var(--gray-50); border: 1px solid var(--gray-200); border-radius: 10px; padding: 12px 16px; max-width: 380px; margin: 0 auto 24px; text-align: left; }
.pay-approve-summary .row { display: flex; justify-content: space-between; align-items: center; font-size: 12.5px; padding: 4px 0; }
.pay-approve-summary .row + .row { border-top: 1px dashed var(--gray-200); margin-top: 4px; padding-top: 8px; }
.pay-approve-summary .lb { color: var(--gray-600); }
.pay-approve-summary .vl { color: var(--gray-900); font-weight: 500; font-variant-numeric: tabular-nums; }
.pay-otp-row { display: flex; gap: 10px; justify-content: center; margin-bottom: 14px; }
.page-mobile .pay-otp-row { gap: 7px; }
.pay-otp-input { width: 48px; height: 56px; font-size: 22px; font-weight: 600; text-align: center; border: 1.5px solid var(--gray-300); border-radius: 10px; background: white; color: var(--gray-900); font-variant-numeric: tabular-nums; }
.page-mobile .pay-otp-input { width: 40px; height: 48px; font-size: 18px; }
.pay-otp-input:focus { outline: none; border-color: var(--info-500); box-shadow: 0 0 0 3px rgba(59,130,246,.15); }
.pay-otp-row.err .pay-otp-input { border-color: #DC2626; background: #FEF2F2; }
.pay-approve-err { font-size: 12.5px; color: #DC2626; margin-bottom: 12px; }
.pay-approve-meta { display: flex; flex-direction: column; align-items: center; gap: 6px; font-size: 12.5px; color: var(--gray-600); margin-bottom: 28px; min-height: 20px; }
.btn-link { background: none; border: none; padding: 0; color: var(--info-700); font-weight: 500; cursor: pointer; font-size: 12.5px; font-family: inherit; }
.btn-link:hover:not(:disabled) { text-decoration: underline; }
.btn-link:disabled { color: var(--gray-500); cursor: default; }
.pay-approve-actions { display: flex; flex-direction: column; align-items: center; gap: 10px; max-width: 380px; margin: 0 auto; }
.pay-approve-primary { width: 100%; justify-content: center; }
.pay-approve-altmethod { background: none; border: none; font-size: 13px; color: var(--info-700); font-weight: 500; cursor: pointer; padding: 6px 8px; border-radius: 6px; font-family: inherit; }
.pay-approve-altmethod:hover:not(:disabled) { background: var(--info-100); }
.pay-approve-altmethod:disabled { color: var(--gray-400); cursor: default; }
.pay-approve-back { background: none; border: none; font-size: 12.5px; color: var(--gray-600); font-weight: 500; cursor: pointer; padding: 4px 8px; border-radius: 6px; font-family: inherit; }
.pay-approve-back:hover:not(:disabled) { color: var(--gray-900); }
.pay-approve-back:disabled { color: var(--gray-400); cursor: default; }

.pay-method-opt { display: flex; align-items: center; gap: 12px; width: 100%; text-align: left; padding: 14px; background: #fff; border: 1px solid var(--gray-200); border-radius: 12px; cursor: pointer; font-family: inherit; margin-top: 8px; }
.pay-method-opt:hover { background: var(--gray-50); border-color: var(--gray-300); }
.pay-method-opt.on { border-color: var(--info-700); background: var(--info-100); }
.pay-method-opt .ic { width: 36px; height: 36px; border-radius: 10px; background: #fff; border: 1px solid var(--gray-200); color: var(--info-700); display: grid; place-items: center; flex-shrink: 0; }
.pay-method-opt.on .ic { background: var(--info-700); color: #fff; border-color: var(--info-700); }
.pay-method-opt .ic svg { width: 18px; height: 18px; }
.pay-method-opt .meta { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
.pay-method-opt .t { font-size: 14px; font-weight: 500; color: var(--gray-900); display: inline-flex; align-items: center; gap: 8px; }
.pay-method-opt .s { font-size: 12.5px; color: var(--gray-600); line-height: 1.45; }
.pay-method-opt .rec { font-size: 10.5px; font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase; background: var(--success-100); color: var(--success-700); padding: 2px 6px; border-radius: 4px; }
.pay-method-opt .chk { color: var(--info-700); display: grid; place-items: center; }
.pay-method-opt .chk svg { width: 18px; height: 18px; }

/* =====================================================
   Recipients
   ===================================================== */
.tx-filterbar { display: flex; align-items: flex-end; gap: 14px; flex-wrap: wrap; margin-bottom: 16px; padding: 14px 16px; background: #fff; border-radius: var(--radius-sm); box-shadow: var(--shadow-card); }
.tx-search { flex: 1 1 280px; min-width: 220px; position: relative; }
.tx-search svg { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); width: 14px; height: 14px; color: var(--gray-500); }
.tx-search input { width: 100%; box-sizing: border-box; padding: 9px 12px 9px 34px; border: 1px solid var(--gray-300); border-radius: 8px; font-size: 13px; outline: none; background: var(--bg-canvas); font-family: var(--font-sans); }
.tx-search input:focus { border-color: var(--info-700); background: #fff; box-shadow: 0 0 0 3px rgba(29,78,216,.10); }
.tx-filtergroup { display: flex; flex-direction: column; gap: 6px; }
.tx-filtergroup .lbl { font-size: 10.5px; font-weight: 700; letter-spacing: 0.06em; color: var(--gray-600); text-transform: uppercase; }
.tx-select-wrap { position: relative; display: inline-block; }
.tx-select { appearance: none; -webkit-appearance: none; padding: 8px 30px 8px 12px; border: 1px solid var(--gray-300); border-radius: 8px; background: #fff; font-size: 13px; color: var(--gray-900); font-family: inherit; cursor: pointer; outline: none; min-width: 150px; }
.tx-select:hover { border-color: var(--gray-400); }
.tx-select:focus { border-color: var(--info-700); box-shadow: 0 0 0 3px rgba(29,78,216,.10); }
.tx-select-wrap > svg { position: absolute; right: 10px; top: 50%; transform: translateY(-50%); width: 14px; height: 14px; color: var(--gray-500); pointer-events: none; }
.tx-clearfilters { align-self: flex-end; padding: 8px 12px; background: transparent; border: 0; font-size: 12.5px; color: var(--info-700); font-weight: 500; cursor: pointer; font-family: inherit; }
.tx-clearfilters:hover { text-decoration: underline; }
.page-mobile .tx-filterbar { padding: 12px; gap: 10px; }
.page-mobile .tx-select { min-width: 0; }

/* Mobile filter bar — just search + a fab that opens the actual controls in a Sheet,
   instead of stacking 2-3 dropdowns inline (reads as noise on a phone). */
.tx-filterbar-mobile { align-items: center; flex-wrap: nowrap; }
.tx-filterbar-mobile .tx-search { flex: 1 1 auto; min-width: 0; }
.filter-fab {
  position: relative; flex-shrink: 0;
  width: 38px; height: 38px; border-radius: 8px;
  background: #fff; border: 1px solid var(--gray-300);
  display: grid; place-items: center; color: var(--gray-700); cursor: pointer;
}
.filter-fab svg { width: 16px; height: 16px; }
.filter-fab-badge {
  position: absolute; top: -5px; right: -5px;
  min-width: 16px; height: 16px; padding: 0 3px; border-radius: 999px;
  background: var(--info-700); color: #fff;
  font-size: 10px; font-weight: 700; line-height: 16px; text-align: center;
  box-shadow: 0 0 0 2px #fff;
}

/* Filter options inside the mobile Sheet — tappable pills, not native selects. */
.filter-group-lbl { font-size: 11px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--gray-600); margin-bottom: 10px; }
.filter-pills { display: flex; flex-wrap: wrap; gap: 8px; }
.filter-pill {
  padding: 8px 14px; border-radius: 999px;
  border: 1px solid var(--gray-300); background: #fff; color: var(--gray-700);
  font-size: 13px; font-weight: 500; font-family: var(--font-sans); cursor: pointer;
}
.filter-pill.on { background: var(--info-700); border-color: var(--info-700); color: #fff; }

.skel-row { display: flex; align-items: center; gap: 12px; padding: 13px 20px; border-bottom: 1px solid var(--gray-100); }
.skel-row:last-child { border-bottom: none; }

.rc-list { display: flex; flex-direction: column; }
.rc-row { display: grid; grid-template-columns: 40px minmax(0, 1.5fr) 110px 1fr auto; align-items: center; gap: 16px; padding: 14px 24px; cursor: pointer; border-top: 1px solid var(--gray-100); }
.rc-row:hover { background: var(--row-hover); }
.rc-row .ava { position: relative; width: 36px; height: 36px; border-radius: 999px; background: linear-gradient(135deg, #5433FF, #321F99); color: #fff; display: grid; place-items: center; font-weight: 600; font-size: 12px; flex-shrink: 0; }
.rc-row .ava .ccy-flag { position: absolute; right: -2px; bottom: -2px; box-shadow: inset 0 0 0 1px rgba(15,23,42,.08), 0 0 0 2px #fff; }
.rc-row:hover .ava .ccy-flag { box-shadow: inset 0 0 0 1px rgba(15,23,42,.08), 0 0 0 2px var(--row-hover); }
.rc-row .meta { min-width: 0; }
.rc-row .meta .t { font-size: 13.5px; font-weight: 500; color: var(--gray-900); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rc-row .meta .s { font-size: 12px; color: var(--gray-600); margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rc-row .ccy-cell { display: inline-flex; align-items: center; gap: 8px; font-size: 12.5px; font-weight: 500; color: var(--gray-900); }
.rc-row .last-cell { font-size: 12px; color: var(--gray-600); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rc-row .actions { display: flex; align-items: center; gap: 6px; }
.rc-row .rc-pay { display: inline-flex; align-items: center; gap: 6px; padding: 6px 12px; font-size: 12px; font-weight: 500; background: transparent; border: 1px solid var(--gray-300); border-radius: 8px; color: var(--gray-700); cursor: pointer; font-family: inherit; opacity: 0; transition: opacity .12s, background-color .12s, color .12s; }
.rc-row:hover .rc-pay { opacity: 1; }
.rc-row .rc-pay:hover { background: var(--info-700); color: #fff; border-color: var(--info-700); }
.rc-row .rc-pay svg { width: 13px; height: 13px; }
.rc-row .rc-iconbtn { width: 28px; height: 28px; border-radius: 8px; background: transparent; border: 0; color: var(--gray-500); cursor: pointer; font-family: inherit; display: grid; place-items: center; opacity: 0; transition: opacity .12s, background-color .12s; }
.rc-row:hover .rc-iconbtn { opacity: 1; }
.rc-row .rc-iconbtn:hover { background: var(--gray-100); color: var(--gray-700); }
.rc-row .rc-iconbtn .dots { font-size: 16px; line-height: 1; letter-spacing: -1px; }

/* Mobile — stacked card row; actions are always visible since touch has no hover */
.rc-row-mobile { display: flex; align-items: center; gap: 12px; padding: 14px 16px; border-top: 1px solid var(--gray-100); }
.rc-row-mobile .ava { position: relative; width: 40px; height: 40px; border-radius: 999px; background: linear-gradient(135deg, #5433FF, #321F99); color: #fff; display: grid; place-items: center; font-weight: 600; font-size: 13px; flex-shrink: 0; }
.rc-row-mobile .ava .ccy-flag { position: absolute; right: -2px; bottom: -2px; box-shadow: inset 0 0 0 1px rgba(15,23,42,.08), 0 0 0 2px #fff; }
.rc-row-mobile .meta { flex: 1; min-width: 0; }
.rc-row-mobile .meta .t { font-size: 13.5px; font-weight: 500; color: var(--gray-900); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rc-row-mobile .meta .s { font-size: 12px; color: var(--gray-600); margin-top: 2px; display: flex; align-items: center; gap: 5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rc-row-mobile .rc-iconbtn { width: 32px; height: 32px; border-radius: 8px; background: transparent; border: 0; color: var(--gray-500); display: grid; place-items: center; flex-shrink: 0; }

.rc-delete-icon { width: 44px; height: 44px; border-radius: 50%; background: #FEF2F2; color: #DC2626; display: grid; place-items: center; margin-bottom: 16px; }
.rc-delete-icon svg { width: 20px; height: 20px; }

/* =====================================================
   Transactions
   ===================================================== */
.tx-stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 10px; margin-bottom: 18px; }
.tx-stat { background: #fff; border-radius: var(--radius-sm); box-shadow: var(--shadow-card); padding: 14px 16px; }
.tx-stat .v { font-size: 22px; font-weight: 600; color: var(--gray-900); font-variant-numeric: tabular-nums; letter-spacing: -0.01em; }
.tx-stat .l { font-size: 11.5px; color: var(--gray-600); text-transform: uppercase; letter-spacing: 0.06em; font-weight: 600; margin-top: 4px; }
.tx-stat.warn .v { color: #A16207; }
.tx-stat.danger .v { color: var(--danger-700); }

.dir-in { color: var(--success-700); }
.dir-out { color: var(--gray-900); }

/* ---------- Transaction detail ---------- */
.td-flow .leg .lbl-row { display: inline-flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.td-flow .leg.right .lbl-row { justify-content: flex-end; }
.td-flow .leg .lbl-row .lbl { margin-bottom: 0; }
.td-flow .leg .lbl-row .ccy-flag { box-shadow: inset 0 0 0 1px rgba(15,23,42,.08); }
.page-mobile .td-flow .leg.right .lbl-row { justify-content: flex-start; flex-direction: row-reverse; }

.td-stamps { margin-top: 22px; padding-top: 18px; border-top: 1px solid var(--gray-100); display: flex; align-items: center; gap: 12px; }
.td-stamp { display: inline-flex; align-items: center; gap: 8px; font-size: 12.5px; }
.td-stamp svg { width: 14px; height: 14px; flex-shrink: 0; }
.td-stamp .pulse { width: 8px; height: 8px; border-radius: 999px; background: var(--info-700); animation: pulse 1.4s ease-in-out infinite; }
.td-stamp-meta { display: flex; align-items: baseline; gap: 6px; }
.td-stamp .t { font-weight: 500; color: var(--gray-900); }
.td-stamp .s { color: var(--gray-600); }
.td-stamp.done svg { color: var(--success-700); }
.td-stamp.active .t { color: var(--info-700); }
.td-stamp.fail svg { color: var(--danger-700); }
.td-stamp.fail .t { color: var(--danger-700); }
.td-stamp-bar { flex: 1; height: 1px; background: var(--gray-200); max-width: 120px; }
.page-mobile .td-stamps { align-items: flex-start; }
.page-mobile .td-stamp { align-items: flex-start; }
.page-mobile .td-stamp svg { margin-top: 2px; }
.page-mobile .td-stamp .pulse { margin-top: 5px; }
.page-mobile .td-stamp-bar { align-self: flex-start; margin-top: 9px; }
.page-mobile .td-stamp-meta { flex-direction: column; align-items: flex-start; gap: 1px; }

.td-flow { display: grid; grid-template-columns: 1fr auto 1fr; gap: 24px; align-items: center; }
.td-flow .leg .lbl { font-size: 11.5px; font-weight: 700; letter-spacing: 0.06em; color: var(--gray-600); text-transform: uppercase; margin-bottom: 8px; }
.td-flow .leg .big { font-size: 24px; font-weight: 600; color: var(--gray-900); font-variant-numeric: tabular-nums; letter-spacing: -0.01em; }
.page-mobile .td-flow .leg .big { font-size: 19px; }
.td-flow .leg .sub { font-size: 12.5px; color: var(--gray-600); margin-top: 6px; }
.td-flow .leg .sub .ccy-flag { vertical-align: -2px; margin-right: 4px; }
.td-flow .leg .sub strong { color: var(--gray-900); font-weight: 500; }
.td-flow .leg.right { text-align: right; }
.td-flow .leg.right .sub { display: flex; justify-content: flex-end; align-items: center; gap: 4px; }
.td-arrow { width: 36px; height: 36px; border-radius: 999px; background: var(--info-100); color: var(--info-700); display: grid; place-items: center; }
.td-arrow svg { width: 16px; height: 16px; }
.page-mobile .td-arrow { width: 26px; height: 26px; margin: 2px 0; }
.page-mobile .td-arrow svg { width: 12px; height: 12px; }

.td-grid { display: grid; grid-template-columns: 1.4fr 1fr; gap: 22px; }
.td-col { display: flex; flex-direction: column; }
@media (max-width: 1080px) {
  .td-grid { grid-template-columns: 1fr; }
  .td-flow { grid-template-columns: 1fr; gap: 12px; }
  .td-flow .leg.right { text-align: left; }
  .td-flow .leg.right .sub { justify-content: flex-start; }
  .td-arrow { transform: rotate(90deg); }
}

.copy-inline { margin-left: 8px; width: 22px; height: 22px; background: transparent; border: 0; padding: 0; display: inline-grid; place-items: center; border-radius: 6px; color: var(--gray-500); cursor: pointer; vertical-align: middle; }
.copy-inline:hover { background: var(--gray-100); color: var(--info-700); }
.copy-inline svg { width: 13px; height: 13px; }

.td-banner { margin-top: 8px; padding: 12px 14px; border-radius: 10px; display: flex; gap: 12px; align-items: flex-start; }
.td-banner svg { width: 18px; height: 18px; flex-shrink: 0; margin-top: 1px; }
.td-banner .t { font-size: 12.5px; font-weight: 600; }
.td-banner .s { font-size: 11.5px; margin-top: 3px; line-height: 1.5; }
.td-banner.info { background: var(--info-100); color: var(--info-700); }
.td-banner.info .s { color: var(--gray-700); }
.td-banner.danger { background: var(--danger-100); color: var(--danger-700); }
.td-banner.danger .s { color: var(--gray-700); }

.td-money { display: flex; flex-direction: column; }
.td-money .row { display: flex; align-items: baseline; justify-content: space-between; padding: 10px 0; border-bottom: 1px solid var(--gray-100); }
.td-money .row:last-child { border-bottom: 0; }
.td-money .row .k { font-size: 12.5px; color: var(--gray-700); }
.td-money .row .v { font-size: 13px; color: var(--gray-900); font-variant-numeric: tabular-nums; }
.td-money .row.total { border-top: 1px solid var(--gray-200); border-bottom: 0; margin-top: 6px; padding-top: 14px; }
.td-money .row.total .k { font-weight: 600; color: var(--gray-900); }
.td-money .row.total .v { font-weight: 600; font-size: 15px; }
.tag { font-size: 10px; font-weight: 600; letter-spacing: 0.02em; color: var(--gray-500); background: var(--gray-100); border-radius: 5px; padding: 2px 7px; white-space: nowrap; }

.td-breakdown { display: flex; flex-direction: column; }
.td-breakdown .bd-row, .td-breakdown .bd-eq { display: flex; align-items: baseline; justify-content: space-between; padding: 10px 0; }
.td-breakdown .bd-k { font-size: 12.5px; color: var(--gray-700); }
.td-breakdown .bd-v { font-size: 13px; color: var(--gray-900); font-variant-numeric: tabular-nums; white-space: nowrap; }
.td-breakdown .bd-v.strong { font-weight: 600; font-size: 15px; }
.td-breakdown .bd-eq { border-top: 1px dashed var(--gray-300); margin-top: 2px; }
.td-breakdown .bd-eq .bd-k { font-weight: 600; color: var(--gray-900); }
.td-breakdown .bd-eq.final { border-top: 1px solid var(--gray-300); margin-top: 4px; padding-top: 14px; }
.td-breakdown .bd-eq.final .bd-k { font-size: 13px; }
.td-breakdown .bd-eq.final .bd-v.strong { font-size: 17px; color: var(--gray-900); }
.td-breakdown .bd-op { display: grid; grid-template-columns: 22px 1fr auto; align-items: baseline; gap: 10px; padding: 6px 0 8px; color: var(--gray-600); }
.td-breakdown .bd-op .op { font-size: 16px; font-weight: 500; color: var(--gray-500); text-align: center; font-variant-numeric: tabular-nums; line-height: 1; }
.td-breakdown .bd-op .op-lbl { font-size: 12px; color: var(--gray-600); }
.td-breakdown .bd-op .op-v { font-size: 12.5px; color: var(--gray-700); }

.td-actions { display: flex; flex-direction: column; gap: 6px; }
.td-action { display: flex; align-items: center; gap: 12px; padding: 12px 14px; background: transparent; border: 1px solid var(--gray-200); border-radius: 10px; cursor: pointer; text-align: left; font-family: inherit; }
.td-action:hover { background: var(--row-hover); border-color: var(--gray-300); }
.td-action .ic { width: 32px; height: 32px; border-radius: 8px; background: var(--info-100); color: var(--info-700); display: grid; place-items: center; flex-shrink: 0; }
.td-action .ic svg { width: 15px; height: 15px; }
.td-action .t { flex: 1; min-width: 0; font-size: 13px; color: var(--gray-900); font-weight: 500; }
.td-action > svg { width: 14px; height: 14px; color: var(--gray-500); }

@keyframes pulse { 0%, 100% { box-shadow: 0 0 0 0 rgba(29,78,216,.4); } 50% { box-shadow: 0 0 0 8px rgba(29,78,216,0); } }

/* =====================================================
   Add recipient — combobox + form + name resolution
   ===================================================== */
.cbox { position: relative; display: inline-block; width: 100%; }
.cbox-trigger { width: 100%; display: flex; align-items: center; gap: 12px; padding: 13px 16px; background: #fff; border: 2px solid var(--gray-300); border-radius: var(--radius-lg); cursor: pointer; font-family: inherit; text-align: left; }
.cbox-trigger:hover { border-color: var(--gray-400); }
.cbox.open .cbox-trigger, .cbox-trigger:focus { border-color: var(--info-700); box-shadow: 0 0 0 3px rgba(29,78,216,.10); outline: none; }
.cbox.disabled .cbox-trigger { opacity: 0.5; cursor: not-allowed; }
.cbox.locked .cbox-trigger { cursor: default; }
.cbox.locked .cbox-trigger:hover { border-color: var(--gray-300); }
.cbox.locked .cbox-caret { display: none; }
.cbox-trigger .cbox-selected, .cbox-trigger .cbox-placeholder { flex: 1; min-width: 0; display: flex; align-items: center; gap: 12px; }
.cbox-placeholder { color: var(--gray-500); font-size: 14px; }
.cbox-leading { flex-shrink: 0; display: flex; align-items: center; }
.cbox-method-ic { width: 42px; height: 42px; border-radius: 10px; background: var(--info-100); color: var(--info-700); display: grid; place-items: center; flex-shrink: 0; }
.cbox-method-ic svg { width: 22px; height: 22px; }
.cbox-opt.on .cbox-method-ic { background: var(--info-700); color: #fff; }
.cbox-trigger .cbox-method-ic { background: var(--info-700); color: #fff; }
.cbox-meta { flex: 1; min-width: 0; }
.cbox-t { font-size: 14px; font-weight: 500; color: var(--gray-900); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cbox-s { font-size: 12px; color: var(--gray-600); margin-top: 2px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cbox-caret { color: var(--gray-500); flex-shrink: 0; transition: transform .15s; }
.cbox-caret svg { width: 16px; height: 16px; }
.cbox.open .cbox-caret { transform: rotate(180deg); color: var(--info-700); }
.cbox-pop { position: absolute; top: calc(100% + 6px); left: 0; right: 0; background: #fff; border: 1px solid var(--gray-200); border-radius: 12px; box-shadow: 0 12px 32px rgba(15,23,42,.12), 0 2px 6px rgba(15,23,42,.06); z-index: 200; overflow: hidden; animation: cbox-pop .12s ease-out; }
@keyframes cbox-pop { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: translateY(0); } }
.cbox-search { display: flex; align-items: center; gap: 8px; padding: 10px 12px; border-bottom: 1px solid var(--gray-100); background: var(--gray-50); }
.cbox-search svg { width: 14px; height: 14px; color: var(--gray-500); flex-shrink: 0; }
.cbox-search input { flex: 1; border: 0; outline: none; background: transparent; font-size: 13px; color: var(--gray-900); font-family: inherit; }
.cbox-list { max-height: 280px; overflow-y: auto; padding: 4px; }
.cbox-empty { padding: 16px; text-align: center; font-size: 13px; color: var(--gray-500); }
.cbox-opt { width: 100%; display: flex; align-items: center; gap: 12px; padding: 10px 12px; background: transparent; border: 0; border-radius: 8px; cursor: pointer; font-family: inherit; text-align: left; }
.cbox-opt.hi:not(.disabled), .cbox-opt:hover:not(.disabled) { background: var(--row-hover); }
.cbox-opt.on { background: #F8FAFE; }
.cbox-opt.disabled { opacity: 0.45; cursor: not-allowed; }
.cbox-opt .cbox-meta { flex: 1; min-width: 0; }
.cbox-opt .cbox-check { width: 18px; height: 18px; border-radius: 999px; background: var(--info-700); display: grid; place-items: center; flex-shrink: 0; }
.cbox-opt .cbox-check svg { width: 11px; height: 11px; stroke: #fff; color: #fff; }
.cbox-field { display: flex; flex-direction: column; gap: 6px; }
.cbox-field-lbl { font-size: 12px; font-weight: 600; color: var(--gray-700); }

.ar-form { display: flex; flex-direction: column; gap: 16px; padding: 18px 0 4px; }
.ar-form .field { margin-bottom: 0; }
.ar-form .lbl { font-size: 12px; font-weight: 600; color: var(--gray-700); margin-bottom: 6px; display: flex; align-items: center; gap: 6px; }
.ar-form .req { color: var(--danger-700); font-weight: 500; font-size: 11px; }
.ar-form .opt { color: var(--gray-500); font-weight: 500; font-size: 11px; }
.ar-form .help { font-size: 11.5px; color: var(--gray-600); margin-top: 6px; }

.ar-namecheck { margin-top: 10px; padding: 12px 14px; background: var(--info-100); border: 1px solid transparent; border-radius: 10px; display: flex; align-items: flex-start; gap: 12px; color: var(--info-700); }
.ar-namecheck > .ic { width: 28px; height: 28px; border-radius: 8px; background: rgba(255,255,255,.6); display: grid; place-items: center; flex-shrink: 0; }
.ar-namecheck > .ic svg { width: 16px; height: 16px; margin: 0; }
.ar-namecheck svg { width: 16px; height: 16px; flex-shrink: 0; margin-top: 2px; }
.ar-namecheck .t { font-size: 12.5px; font-weight: 600; color: var(--info-700); }
.ar-namecheck .s { font-size: 11.5px; color: var(--gray-700); margin-top: 2px; line-height: 1.5; }
.ar-namecheck .s .strong { font-weight: 600; color: var(--gray-900); }
.ar-namecheck .s.warn { color: var(--danger-700); margin-top: 6px; }
.ar-namecheck.idle { background: var(--gray-50); border-color: var(--gray-200); color: var(--gray-600); }
.ar-namecheck.idle svg { color: var(--gray-500); }
.ar-namecheck.idle .t { color: var(--gray-700); }
.ar-namecheck.loading { background: #FFF8EB; border-color: #F8DEA1; color: #92400E; }
.ar-namecheck.loading .t { color: #92400E; }
.ar-namecheck.loading .ic .spinner { width: 16px; height: 16px; border-radius: 999px; border: 2px solid rgba(146,64,14,.2); border-top-color: #92400E; animation: ar-spin .7s linear infinite; margin-top: 1px; }
@keyframes ar-spin { to { transform: rotate(360deg); } }
.ar-namecheck.ok { background: #ECFDF5; border-color: #A7F3D0; }
.ar-namecheck.ok svg { color: var(--success-700); }
.ar-namecheck.ok .t { color: var(--success-700); }
.ar-namecheck.warn { background: #FFFBEB; border-color: #FCD34D; }
.ar-namecheck.warn svg { color: #B45309; }
.ar-namecheck.warn .t { color: #B45309; }
.ar-namecheck .meta { flex: 1; min-width: 0; }

.ar-tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 18px; margin-bottom: 6px; }
.page-mobile .ar-tabs { grid-template-columns: 1fr; }
.ar-tab { display: flex; align-items: center; gap: 12px; padding: 14px 16px; border: 1px solid var(--gray-200); border-radius: 12px; background: #fff; cursor: pointer; font-family: inherit; text-align: left; }
.ar-tab:hover { background: var(--row-hover); }
.ar-tab.on { background: #F8FAFE; border-color: var(--info-700); box-shadow: 0 0 0 3px rgba(29,78,216,.08); }
.ar-tab .ic { width: 36px; height: 36px; border-radius: 10px; background: var(--gray-100); color: var(--gray-700); display: grid; place-items: center; flex-shrink: 0; }
.ar-tab .ic svg { width: 18px; height: 18px; }
.ar-tab.on .ic { background: var(--info-700); color: #fff; }
.ar-tab .meta { flex: 1; min-width: 0; }
.ar-tab .meta .t { font-size: 13.5px; font-weight: 500; color: var(--gray-900); }
.ar-tab .meta .s { font-size: 11.5px; color: var(--gray-600); margin-top: 2px; }

.ar-compliance { display: flex; align-items: flex-start; gap: 12px; margin-top: 16px; padding: 14px 16px; background: #FFFBEB; border: 1px solid #FCD34D; border-radius: 12px; }
.ar-compliance .ic { width: 32px; height: 32px; border-radius: 8px; background: #FEF3C7; color: #B45309; display: grid; place-items: center; flex-shrink: 0; }
.ar-compliance .ic svg { width: 16px; height: 16px; }
.ar-compliance .meta { flex: 1; min-width: 0; }
.ar-compliance .meta .t { font-size: 13px; font-weight: 600; color: #92400E; }
.ar-compliance .meta .s { font-size: 12px; color: var(--gray-700); margin-top: 3px; line-height: 1.5; }
.ar-compliance .btn { flex-shrink: 0; align-self: center; text-decoration: none; }

/* =====================================================
   Settings & Developer
   ===================================================== */
.settings-shell { display: grid; grid-template-columns: 248px 1fr; gap: 28px; align-items: start; margin-top: 8px; }
@media (max-width: 880px) { .settings-shell { grid-template-columns: 1fr; } }
.settings-rail { display: flex; flex-direction: column; gap: 4px; position: sticky; top: 24px; }
@media (max-width: 880px) { .settings-rail { position: static; flex-direction: row; overflow-x: auto; } }
.settings-rail-item { display: flex; align-items: center; gap: 12px; padding: 10px 12px; background: transparent; border: 1px solid transparent; border-radius: 10px; cursor: pointer; text-align: left; font-family: inherit; color: var(--gray-700); flex-shrink: 0; }
.settings-rail-item:hover { background: var(--row-hover); color: var(--gray-900); }
.settings-rail-item.on { background: var(--info-100); color: var(--info-700); }
.settings-rail-item .ic { width: 32px; height: 32px; border-radius: 8px; background: var(--gray-100); color: var(--gray-700); display: grid; place-items: center; flex-shrink: 0; }
.settings-rail-item .ic svg { width: 16px; height: 16px; }
.settings-rail-item.on .ic { background: var(--info-700); color: #fff; }
.settings-rail-item .meta { display: flex; flex-direction: column; min-width: 0; }
.settings-rail-item .meta .t { font-size: 13.5px; font-weight: 500; }
.settings-rail-item .meta .s { font-size: 11.5px; color: var(--gray-600); margin-top: 1px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.settings-rail-item.on .meta .s { color: var(--info-700); opacity: 0.75; }
.settings-body { display: flex; flex-direction: column; gap: 20px; min-width: 0; }

.set-card { background: #fff; border: 1px solid var(--gray-200); border-radius: var(--radius-sm); padding: 22px 24px; }
.page-mobile .set-card { padding: 16px; }
.set-card-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; margin-bottom: 18px; flex-wrap: wrap; }
.set-card-head:last-child { margin-bottom: 0; }
.set-card-title { margin: 0; font-size: 15.5px; font-weight: 600; color: var(--gray-900); }
.set-card-sub { margin: 4px 0 0; font-size: 12.5px; color: var(--gray-600); line-height: 1.5; }

.set-list { display: flex; flex-direction: column; }
.set-row { display: grid; grid-template-columns: 200px 1fr auto; gap: 16px; align-items: center; padding: 14px 0; border-top: 1px solid var(--gray-100); }
.page-mobile .set-row { grid-template-columns: 1fr; gap: 4px; }
.set-row:first-child { border-top: 0; padding-top: 4px; }
.set-row:last-child { padding-bottom: 4px; }
.set-row-k { font-size: 11.5px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--gray-600); }
.set-row-v { min-width: 0; }
.set-row-v .strong { font-size: 14px; font-weight: 500; color: var(--gray-900); }
.set-row-help { font-size: 11.5px; color: var(--gray-600); margin-top: 4px; display: inline-flex; align-items: center; gap: 6px; }
.set-row-help svg { width: 12px; height: 12px; }
.set-row-edit { background: transparent; border: 0; cursor: pointer; font-size: 12.5px; font-weight: 500; color: var(--info-700); padding: 6px 10px; border-radius: 6px; font-family: inherit; }
.set-row-edit:hover { background: var(--info-100); }

.set-address { font-size: 14px; color: var(--gray-900); line-height: 1.7; background: var(--gray-50); border: 1px solid var(--gray-100); border-radius: 8px; padding: 14px 16px; }

.set-banner { display: flex; align-items: center; gap: 16px; padding: 18px 22px; border-radius: 12px; border: 1px solid var(--gray-200); background: #fff; flex-wrap: wrap; }
.set-banner .ic { width: 44px; height: 44px; border-radius: 12px; background: var(--gray-100); color: var(--gray-700); display: grid; place-items: center; flex-shrink: 0; }
.set-banner .ic svg { width: 22px; height: 22px; }
.set-banner .meta { flex: 1; min-width: 0; }
.set-banner .meta .t { font-size: 15px; font-weight: 600; color: var(--gray-900); }
.set-banner .meta .s { font-size: 12.5px; color: var(--gray-700); margin-top: 4px; line-height: 1.5; }
.set-banner.ok { background: #ECFDF5; border-color: #A7F3D0; }
.set-banner.ok .ic { background: var(--success-700); color: #fff; }
.set-banner.ok .meta .t { color: var(--success-700); }
.set-banner.info { background: var(--info-100); border-color: #BFDBFE; }
.set-banner.info .ic { background: var(--info-700); color: #fff; }
.set-banner.info .meta .t { color: var(--info-700); }
.set-banner.warn { background: #FFFBEB; border-color: #FDE68A; }
.set-banner.warn .ic { background: #B45309; color: #fff; }
.set-banner.warn .meta .t { color: #92400E; }
.set-banner.warn .meta .s { color: #92400E; }
.set-banner.danger { background: var(--danger-100); border-color: #FECACA; }
.set-banner.danger .ic { background: var(--danger-700); color: #fff; }
.set-banner.danger .meta .t { color: var(--danger-700); }

.set-chip { display: inline-flex; align-items: center; gap: 4px; padding: 4px 10px; border-radius: 999px; font-size: 11.5px; font-weight: 500; background: var(--gray-100); color: var(--gray-700); white-space: nowrap; }
.set-chip svg { width: 12px; height: 12px; }
.set-chip.ok { background: var(--success-100); color: var(--success-700); }
.set-chip.warn { background: #FEF3C7; color: #92400E; }
.set-chip.danger { background: var(--danger-100); color: var(--danger-700); }

.set-totp-status { display: flex; align-items: center; gap: 16px; padding: 16px 18px; background: var(--gray-50); border: 1px solid var(--gray-200); border-radius: 12px; }
.set-totp-status .ic { width: 40px; height: 40px; border-radius: 10px; background: #fff; border: 1px solid var(--gray-200); color: var(--info-700); display: grid; place-items: center; flex-shrink: 0; }
.set-totp-status .ic svg { width: 18px; height: 18px; }
.set-totp-status .meta { flex: 1; min-width: 0; }
.set-totp-status .meta .t { font-size: 14px; font-weight: 500; color: var(--gray-900); }
.set-totp-status .meta .s { font-size: 12px; color: var(--gray-600); margin-top: 3px; line-height: 1.5; }

.set-support-note { display: flex; align-items: flex-start; gap: 12px; padding: 14px 18px; background: var(--gray-50); border: 1px dashed var(--gray-300); border-radius: 12px; font-size: 12.5px; color: var(--gray-700); line-height: 1.55; }
.set-support-note > svg { width: 18px; height: 18px; color: var(--gray-600); flex-shrink: 0; margin-top: 1px; }
.set-support-note a { color: var(--info-700); font-weight: 500; text-decoration: none; }
.set-support-note a:hover { text-decoration: underline; }

.set-apikey-card { border: 1px solid var(--gray-200); border-radius: 12px; padding: 16px 18px; background: #fff; }
.set-apikey-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.set-apikey-label { font-size: 13px; font-weight: 600; color: var(--gray-900); padding: 2px 10px; background: var(--gray-100); border-radius: 6px; }
.set-apikey-field { padding: 8px 0; border-top: 1px solid var(--gray-100); }
.set-apikey-field:first-of-type { border-top: 1px solid var(--gray-200); }
.set-apikey-field-label { font-size: 11px; font-weight: 500; color: var(--gray-500); text-transform: uppercase; letter-spacing: 0.04em; margin-bottom: 4px; }
.set-apikey-field-value { display: flex; align-items: center; gap: 8px; }
.set-apikey-field-value code { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 12.5px; color: var(--gray-900); flex: 1; min-width: 0; word-break: break-all; }
.set-apikey-copy { background: transparent; border: 0; cursor: pointer; color: var(--gray-500); padding: 4px; border-radius: 6px; display: flex; align-items: center; flex-shrink: 0; }
.set-apikey-copy:hover { background: var(--gray-100); color: var(--gray-700); }
.set-apikey-copy svg { width: 14px; height: 14px; }
.set-apikey-toggle { background: transparent; border: 1px solid var(--gray-200); cursor: pointer; padding: 2px 10px; border-radius: 6px; font-size: 11.5px; font-weight: 500; color: var(--gray-600); font-family: inherit; flex-shrink: 0; }
.set-apikey-toggle:hover { background: var(--gray-100); color: var(--gray-900); }
.set-apikey-action { background: transparent; border: 0; cursor: pointer; color: var(--gray-500); padding: 5px; border-radius: 6px; display: flex; align-items: center; flex-shrink: 0; }
.set-apikey-action:hover { background: var(--danger-100); color: var(--danger-600); }
.set-apikey-action svg { width: 14px; height: 14px; }
.set-apikey-meta { font-size: 11.5px; color: var(--gray-500); margin-top: 10px; padding-top: 10px; border-top: 1px solid var(--gray-100); }

.set-modal-foot { display: flex; justify-content: flex-end; gap: 10px; margin-top: 20px; }

/* ---------- Mock sheet ---------- */
.mock-group { margin-bottom: 18px; }
.mock-label { font-size: 11px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--gray-500); margin-bottom: 8px; }
.mock-row { display: flex; gap: 8px; flex-wrap: wrap; }
.mock-row button {
  border: 1px solid var(--gray-300); background: #fff; color: var(--gray-700);
  padding: 7px 12px; border-radius: 999px; font-size: 12.5px; cursor: pointer; font-family: var(--font-sans);
}
.mock-row button.on { background: var(--info-700); border-color: var(--info-700); color: #fff; }

/* ---------- Auth ---------- */
.btn.btn-block { width: 100%; justify-content: center; }
.btn.btn-dark { background: #0F172A; color: #fff; }
.btn.btn-dark:hover { background: #1E293B; }
.btn.btn-dark:disabled { background: var(--gray-300); color: var(--gray-500); }

.auth-foot { margin-top: 22px; text-align: center; font-size: 12.5px; color: var(--gray-600); }
.auth-foot a { color: var(--info-700); text-decoration: none; cursor: pointer; font-weight: 500; }
.auth-foot a:hover { text-decoration: underline; }

.otp-row { display: flex; gap: 10px; justify-content: center; margin: 8px 0 4px; }
.otp-cell {
  width: 52px; height: 60px;
  border: 2px solid var(--gray-300);
  border-radius: 10px;
  background: #fff;
  display: grid; place-items: center;
  font-size: 22px; font-weight: 600; color: var(--gray-900);
  font-variant-numeric: tabular-nums;
  font-family: var(--font-sans);
  text-align: center;
}
.otp-cell:focus { outline: none; border-color: var(--info-700); box-shadow: 0 0 0 3px rgba(29,78,216,.12); }
.otp-cell.filled { border-color: var(--info-700); background: #F8FAFE; }

/* Mobile: single centered column (no right info panel) */
.auth-centered {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  background:
    radial-gradient(ellipse 900px 600px at 50% -5%, rgba(84, 51, 255, 0.06) 0%, transparent 70%),
    var(--bg-canvas);
  padding: 32px 20px 24px;
}
.auth-centered-logo { margin-bottom: 32px; }
.auth-centered-logo img { height: 22px; width: auto; display: block; }
.auth-centered-body { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; width: 100%; }
.auth-card-wrap {
  width: 100%;
  max-width: 100%;
  background: #fff;
  border-radius: 16px;
  border: 1px solid var(--gray-200);
  box-shadow: 0 1px 3px rgba(0,0,0,.04), 0 8px 32px rgba(15,23,42,.06);
  padding: 28px 22px 24px;
}
.auth-card-wrap h1 { font-size: 21px; font-weight: 700; color: var(--gray-900); margin: 0 0 6px; letter-spacing: -0.015em; text-align: center; }
.auth-lede { font-size: 13.5px; color: var(--gray-600); margin: 0 0 26px; text-align: center; line-height: 1.5; }
.auth-centered-legal { font-size: 11px; color: var(--gray-500); line-height: 1.55; max-width: 480px; text-align: center; margin-top: auto; padding-top: 32px; }

/* Desktop: split two-column (form left, marketing panel right) */
.auth-split { display: grid; grid-template-columns: 3fr 2fr; min-height: 100vh; }
.auth-split-left { display: flex; flex-direction: column; align-items: center; padding: 48px 48px 32px; background: #fff; overflow-y: auto; }
.auth-split-left .auth-card-wrap { width: 100%; max-width: 440px; background: transparent; border: none; box-shadow: none; padding: 0; border-radius: 0; }
.auth-split-left .auth-card-wrap h1 { font-size: 24px; }
.auth-split-left .auth-centered-legal { max-width: 420px; }

.auth-split-right {
  background: linear-gradient(145deg, #0F172A 0%, #1E293B 50%, #0F172A 100%);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  padding: 60px 56px; position: relative; overflow: hidden;
}
.auth-split-right::before {
  content: "";
  position: absolute; inset: 0;
  background:
    radial-gradient(600px 400px at 70% 20%, rgba(84, 51, 255, 0.15) 0%, transparent 70%),
    radial-gradient(500px 300px at 30% 80%, rgba(59, 130, 246, 0.1) 0%, transparent 70%);
  pointer-events: none;
}
.auth-info-panel { position: relative; z-index: 1; max-width: 440px; width: 100%; display: flex; flex-direction: column; align-items: stretch; height: 100%; justify-content: flex-start; }
.auth-info-tagline { font-size: 30px; font-weight: 700; color: #fff; letter-spacing: -0.025em; line-height: 1.25; margin: 0 0 16px; }
.auth-info-tagline span { background: linear-gradient(135deg, #818CF8, #A78BFA); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
.auth-info-sub { font-size: 14.5px; color: rgba(255,255,255,0.52); line-height: 1.65; margin: 0; }

.auth-iframe-mobile { position: fixed; inset: 0; z-index: 60; background: #fff; }
.auth-iframe-close {
  position: absolute; top: 16px; left: 16px; z-index: 10;
  display: flex; align-items: center; gap: 6px;
  background: rgba(255,255,255,0.9); backdrop-filter: blur(6px);
  border: 1px solid var(--gray-200); border-radius: 8px;
  padding: 7px 12px; font-size: 12.5px; font-weight: 500;
  color: var(--gray-700); cursor: pointer;
  box-shadow: 0 1px 4px rgba(0,0,0,0.08);
  font-family: var(--font-sans);
}

.auth-mock-gear {
  position: fixed; top: 16px; right: 16px; z-index: 70;
  width: 34px; height: 34px; border-radius: 999px;
  background: #fff; border: 1px solid var(--gray-200);
  box-shadow: 0 1px 4px rgba(0,0,0,.08);
  display: grid; place-items: center; cursor: pointer; color: var(--gray-600);
}

/* TOTP setup */
.totp-setup-body { display: flex; flex-direction: column; gap: 24px; }
.totp-steps { display: flex; flex-direction: column; gap: 12px; }
.totp-instruction { display: flex; align-items: center; gap: 12px; }
.totp-instruction-num {
  width: 24px; height: 24px; border-radius: 999px;
  background: var(--gray-100); color: var(--gray-700);
  display: grid; place-items: center;
  font-size: 12px; font-weight: 600; flex-shrink: 0;
}
.totp-instruction-text { font-size: 13.5px; font-weight: 500; color: var(--gray-900); line-height: 1.4; }
.totp-instruction-sub { font-size: 12px; color: var(--gray-600); margin-top: 2px; }
.totp-qr-section {
  display: flex; flex-direction: column; align-items: center; gap: 16px;
  padding: 20px; background: #fff; border: 1px solid var(--gray-200); border-radius: 12px;
}
.totp-qr-placeholder { display: flex; align-items: center; justify-content: center; }
.totp-manual-key { text-align: center; }
.totp-manual-label { font-size: 11.5px; color: var(--gray-600); margin-bottom: 6px; text-transform: uppercase; letter-spacing: 0.04em; font-weight: 600; }
.totp-manual-value {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 12px; background: var(--gray-100); border-radius: 8px;
  font-size: 13.5px; font-weight: 600; color: var(--gray-900);
  font-variant-numeric: tabular-nums; letter-spacing: 0.04em;
}
.totp-copy-btn { background: transparent; border: 0; cursor: pointer; color: var(--gray-600); padding: 2px; border-radius: 4px; display: inline-flex; align-items: center; }
.totp-copy-btn:hover { color: var(--info-700); }
.totp-copy-btn svg { width: 14px; height: 14px; }
.totp-verify-section { display: flex; flex-direction: column; gap: 12px; }

@media (max-width: 767px) {
  .otp-row { gap: 8px; }
  .otp-cell { width: 44px; height: 52px; font-size: 19px; }
  .totp-qr-section { padding: 16px; }
}

@media (max-width: 400px) {
  .otp-cell { width: 38px; height: 48px; font-size: 17px; }
  .otp-row { gap: 6px; }
}

/* ---------- Cards ---------- */
.card-visual {
  position: relative; overflow: hidden; flex-shrink: 0;
  background-size: cover; background-position: center;
  color: #fff; display: flex; flex-direction: column;
}
.card-visual::before { content: ""; position: absolute; inset: 0; z-index: 1; display: none; }
.card-visual.frozen::before { display: block; background: rgba(80,100,130,.65); }
.card-visual.failed::before { display: block; background: rgba(80,80,80,.5); }
.card-visual.muted:not(.frozen):not(.failed)::before { display: block; background: rgba(100,80,160,.3); }
.card-visual-content { position: relative; z-index: 2; display: flex; flex-direction: column; flex: 1; }
.card-status-badge {
  margin-top: 5px; display: inline-block; font-size: 9px; font-weight: 600;
  background: rgba(255,255,255,.18); border-radius: 5px; padding: 2px 7px;
  letter-spacing: 0.04em; text-transform: uppercase;
}
.card-status-badge.failed { background: rgba(239,68,68,.65); }
.card-visual-pulse { position: absolute; inset: 0; z-index: 0; animation: cardPulse 2s ease-in-out infinite; }
.card-field { position: relative; display: inline-block; border-radius: 6px; padding: 3px 6px; transition: background .12s; }
.card-field-lbl { opacity: 0.6; margin-bottom: 1px; text-transform: uppercase; letter-spacing: 0.06em; }
.card-tip {
  position: absolute; left: 50%; bottom: calc(100% + 6px); transform: translateX(-50%);
  white-space: nowrap; font-size: 10.5px; font-weight: 500; color: var(--gray-900);
  background: #fff; border-radius: 5px; padding: 3px 8px; pointer-events: none;
  box-shadow: 0 2px 8px rgba(0,0,0,.15); z-index: 5;
}

.card-tile { cursor: pointer; display: flex; flex-direction: column; align-items: center; gap: 12px; width: 260px; }
.card-tile-status { display: flex; align-items: center; justify-content: center; gap: 6px; margin-top: 4px; font-size: 12px; }
.card-new-tile {
  flex-shrink: 0; cursor: pointer; width: 260px; height: 164px; border-radius: 14px;
  border: 2px dashed var(--gray-400); display: flex; flex-direction: column;
  align-items: center; justify-content: center; gap: 8px; transition: border-color .12s, background .12s;
}
.card-new-tile:hover { border-color: var(--gray-500); background: var(--gray-50); }
.page-mobile .card-tile, .page-mobile .card-new-tile { width: 220px; }
.page-mobile .card-new-tile { height: 140px; }

.card-detail-grid { display: grid; grid-template-columns: 360px 1fr; gap: 32px; align-items: flex-start; }
.page-mobile .card-detail-grid { grid-template-columns: 1fr; gap: 20px; }
.card-detail-left { display: flex; flex-direction: column; }
.card-detail-right { min-width: 0; }
.card-detail-row { padding: 16px 20px; border-bottom: 1px solid var(--gray-100); }
.card-detail-row-head { display: flex; align-items: center; gap: 6px; margin-bottom: 6px; font-size: 11px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--gray-500); }
.card-detail-row-head button { background: none; border: 0; padding: 2px; cursor: pointer; color: var(--gray-400); display: inline-flex; align-items: center; }
.card-detail-row-head button:hover { color: var(--gray-600); }
.card-detail-row-head svg { width: 13px; height: 13px; }

.card-name-chips { display: flex; gap: 6px; margin-top: 8px; overflow-x: auto; padding-bottom: 2px; }
.card-name-chip {
  display: inline-block; cursor: pointer; white-space: nowrap; padding: 5px 12px; border-radius: 999px;
  font-size: 12px; font-weight: 500; user-select: none; background: var(--gray-100); color: var(--gray-600);
  border: 1px solid transparent; transition: background-color .1s, color .1s, border-color .1s;
}
.card-name-chip.on { background: #7C3AED; color: #fff; border-color: #7C3AED; }

.card-type-opt { flex: 1; padding: 14px 16px; border-radius: 10px; text-align: left; }
.card-type-opt.on { border: 2px solid #7C3AED; background: #F5F3FF; cursor: pointer; }
.card-type-opt.disabled { border: 1px solid var(--gray-200); background: var(--gray-50); cursor: not-allowed; opacity: 0.6; }

.cards-apply { max-width: 600px; margin: 40px auto; text-align: center; }
.cards-apply-eyebrow { font-size: 11px; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; color: var(--gray-500); margin-bottom: 12px; }
.cards-apply-h1 { font-size: 26px; font-weight: 700; color: var(--gray-900); margin: 0 0 12px; line-height: 1.3; }
.cards-apply-lede { font-size: 14.5px; color: var(--gray-600); line-height: 1.6; max-width: 440px; margin: 0 auto 32px; }
.cards-apply-visual {
  width: 280px; height: 178px; border-radius: 16px; padding: 22px; flex-shrink: 0;
  background-image: url(../v0/design-system/assets/card-bg.svg); background-size: cover; background-position: center;
  color: #fff; display: flex; flex-direction: column; overflow: hidden;
  box-shadow: 0 12px 40px rgba(79,70,229,.3); transform: rotate(-3deg);
}
.cards-apply-features { display: flex; gap: 20px; margin-bottom: 36px; text-align: left; }
.page-mobile .cards-apply-features { flex-direction: column; gap: 20px; }
.cards-apply-feature-ic { width: 36px; height: 36px; border-radius: 10px; background: var(--purple-50,#F5F3FF); display: grid; place-items: center; color: var(--purple-600,#7C3AED); margin-bottom: 10px; }
.cards-apply-feature-ic svg { width: 18px; height: 18px; }
.page-mobile .cards-apply { margin: 20px auto; }
.page-mobile .cards-apply-h1 { font-size: 22px; }
.page-mobile .cards-apply-visual { width: 100%; max-width: 280px; transform: none; }
