/* ---------------------------------------------------------
   Self-hosted IBM Plex Sans (WOFF2)
   ---------------------------------------------------------
   We ship fonts locally to avoid CDN blocking and to keep rendering
   consistent. We also include a LIGHT weight to reduce the “too bold”
   look on Chrome/Windows compared to legacy browsers.
*/

@font-face {
  font-family: "IBM Plex Sans";
  src: url("/fonts/IBM_Plex_Sans_woff2/IBMPlexSans-Light.woff2") format("woff2");
  font-weight: 300;
  font-style: normal;
  font-display: block;
}
@font-face {
  font-family: "IBM Plex Sans";
  src: url("/fonts/IBM_Plex_Sans_woff2/IBMPlexSans-Regular.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: block;
}
@font-face {
  font-family: "IBM Plex Sans";
  src: url("/fonts/IBM_Plex_Sans_woff2/IBMPlexSans-Medium.woff2") format("woff2");
  font-weight: 500;
  font-style: normal;
  font-display: block;
}
@font-face {
  font-family: "IBM Plex Sans";
  src: url("/fonts/IBM_Plex_Sans_woff2/IBMPlexSans-SemiBold.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: block;
}
@font-face {
  font-family: "IBM Plex Sans";
  src: url("/fonts/IBM_Plex_Sans_woff2/IBMPlexSans-Bold.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: block;
}

:root {
  --font-sans: "IBM Plex Sans";
  /* Typography scale (base is html{font-size}) */
  --fs-xs: 0.8rem;   /* 12px when base is 15px */
  --fs-sm: 0.875rem; /* ~13px */
  --fs-md: 1rem;     /* 15px */

  --bg: #f5f5f7;
  --bg-elevated: #ffffff;
  /* Brand (primary) color matches footer for a more corporate look */
  --accent: #020617;
  --accent-hover: #0b1224;
  --text-main: #111827;
  --text-muted: #6b7280;
  --radius-lg: 14px;
  --radius-sm: 8px;
  --btn-border: rgba(2, 6, 23, 0.14);
  --btn-bg: rgba(2, 6, 23, 0.04);
  --btn-bg-hover: rgba(2, 6, 23, 0.07);
}

* {
  box-sizing: border-box;
}

html {
  /* Single baseline across the whole UI (keeps tables/labels consistent) */
  font-size: 14px;
  -webkit-text-size-adjust: 100%;
  /* Chrome on Windows can render optimizeLegibility noticeably heavier */
  text-rendering: auto;
}

/* Prevent accidental horizontal scrolling on mobile (often caused by long tokens / grids) */
html, body { overflow-x: hidden; height: 100%; }


/* HARD FONT LOCK */
*, *::before, *::after { font-family: var(--font-sans) !important; }
body {
  margin: 0;
  font-family: var(--font-sans);
  font-weight: 300;
  /* Keep font rendering consistent across browsers (Chrome vs Edge/IE)
     by avoiding synthetic bold/italic. */
  font-synthesis: none;
  line-height: 1.5;
  letter-spacing: 0;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  background: var(--bg);
  color: var(--text-main);

  /* Sticky footer: keep the footer at the very bottom on short pages */
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* Sticky footer helpers */
.page-content { flex: 1 0 auto; }
.main-footer { margin-top: auto; }

/* ---------------------------------------------------------
   Global typography (avoid browser default heading sizes)
   --------------------------------------------------------- */
h1, h2, h3, h4 {
  margin: 0;
  font-family: var(--font-sans);
}
h1 { font-size: 22px; line-height: 1.25; font-weight: 500; }
h2 { font-size: 16px; line-height: 1.25; font-weight: 500; }
h3 { font-size: 14px; line-height: 1.25; font-weight: 500; }
h4 { font-size: 13px; line-height: 1.25; font-weight: 500; }

button, input, select, textarea {
  font: inherit;
  color: inherit;
}

a {
  color: var(--accent);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

.container {
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  /* Keep header/main/footer perfectly aligned on iOS (safe-area) */
  padding-left: calc(20px + env(safe-area-inset-left));
  padding-right: calc(20px + env(safe-area-inset-right));
}

/* Prevent iOS Safari horizontal jitter when any child overflows by a pixel */
html, body {
  width: 100%;
  overflow-x: hidden;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(245, 245, 247, 0.96);
  backdrop-filter: blur(12px);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 0;
}


/* Base primary nav */
.nav{
  display:flex;
  align-items:center;
  gap: 8px;
  flex-wrap: wrap;
}
.logo {
  font-weight: 500;
  letter-spacing: 0.04em;
  font-size: 18px;
}

.nav a {
  margin-right: 16px;
  font-size: 14px;
  color: var(--text-muted);
}

.nav a:last-child {
  margin-right: 0;
}

.nav a:hover {
  color: var(--text-main);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
}

.user-label {
  margin-right: 4px;
  color: var(--text-muted);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--btn-border);
  font-size: 13px;
  cursor: pointer;
  text-decoration: none;
  white-space: nowrap;
  background: var(--btn-bg);
  color: var(--text-main);
  gap: 8px;
  line-height: 1;
  transition: background 160ms ease, border-color 160ms ease, color 160ms ease, transform 120ms ease;
}

.btn:hover { background: var(--btn-bg-hover); text-decoration: none; }
.btn:active { transform: translateY(0.5px); }
.btn:focus-visible { outline: none; box-shadow: 0 0 0 3px rgba(2, 6, 23, 0.10); }

.btn[disabled], .btn:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none;
}

.btn.primary {
  background: var(--accent);
  color: #ffffff;
  border-color: transparent;
}

.btn.primary:hover { background: var(--accent-hover); }

.btn.ghost {
  background: transparent;
  border-color: var(--btn-border);
}

.btn.ghost:hover { background: rgba(2, 6, 23, 0.05); }

/* Aliases used in some pages */
.btn-primary { background: var(--accent); color:#fff; border-color: transparent; }
.btn-primary:hover { background: var(--accent-hover); }
.btn-secondary { background: var(--btn-bg); border-color: var(--btn-border); color: var(--text-main); }
.btn-secondary:hover { background: var(--btn-bg-hover); }

.btn.small {
  padding: 4px 10px;
  font-size: 12px;
}

.page-content {
  padding: 32px 0 40px;
  flex: 1 0 auto;
}

/* Two-column page layout (forms + meaningful illustration). Hidden on mobile to keep it clean. */
.page-split{
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 420px);
  gap: 24px;
  align-items: start;
}
.page-split__aside{
  position: sticky;
  top: 92px;
}
.page-illustration{
  border-radius: 16px;
  padding: 16px;
  border: 1px solid rgba(15, 23, 42, 0.08);
  background: #fff;
}
.page-illustration__img{
  width: 100%;
  height: auto;
  display: block;
}
.page-illustration__cap{
  margin-top: 10px;
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.35;
}

  top: auto;
  display: flex;
  align-items: center;
}
  padding: 0;
  border: none;
  background: transparent;
  border-radius: 0;
}
  max-width: 520px;
}
  max-width: 520px;
}


  top: auto;
  display: flex;
  align-items: center;
}
  padding: 0;
  border: none;
  background: transparent;
  border-radius: 0;
}
  max-width: 440px;
}
  max-width: 420px;
}

  top: auto;
  display: flex;
  align-items: center;
}
  padding: 0;
  border: none;
  background: transparent;
  border-radius: 0;
}
  margin-top: 12px;
}

  top: auto;
  display: flex;
  align-items: center;
}
  padding: 0;
  border: none;
  background: transparent;
  border-radius: 0;
}
  max-width: 440px;
}
  max-width: 420px;
}



.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
  gap: 32px;
  align-items: center;
  margin-top: 16px;
}

.hero--marketing{
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: 26px;
}
.hero--marketing{
  align-items: center;
}
.hero--marketing .hero-main{
  padding-top: 2px;
}
.hero--marketing .hero-media{ display:flex; justify-content:flex-end; align-items:center; }
.hero--solo{
  grid-template-columns: 1fr;
}
.hero--solo .hero-main{ max-width: 720px; }


/* --- Marketing (landing) polish --- */
.hero--marketing .hero-main p{ max-width: 560px; }
.marketing-badges{
  display:flex;
  flex-wrap:wrap;
  gap:8px;
  margin-bottom: 12px;
}
.badge{
  display:inline-flex;
  align-items:center;
  padding: 0;
  border-radius: 0;
  font-size: 12px;
  color: var(--text-muted);
  background: transparent;
  border: none;
}
.badge--muted{
  color: var(--text-muted);
}
.marketing-fineprint{
  margin-top: 14px;
  font-size: 12px;
  color: var(--text-muted);
  max-width: 560px;
}

.hero-media{ display:flex; justify-content:flex-end; align-items:flex-start; }
.marketing-visual{ width: 100%; max-width: 420px; }
.phone-mock{
  border-radius: 30px;
  padding: 14px;
  background: linear-gradient(135deg, rgba(17,24,39,0.10), rgba(2,6,23,0.12));
  border: 1px solid rgba(15,23,42,0.10);
}
.phone-screen{
  position: relative;
  background: #0b1220;
  border-radius: 24px;
  padding: 18px;
  overflow: hidden;
  box-shadow: 0 18px 40px rgba(15,23,42,0.20);
}
.phone-notch{
  width: 46%;
  height: 12px;
  background: rgba(15,23,42,0.22);
  border-radius: 0 0 14px 14px;
  margin: 0 auto 10px;
}
.phone-top{ display:flex; flex-direction:column; gap:8px; }
.phone-top .dot{ width: 10px; height: 10px; border-radius: 99px; background: rgba(255,255,255,0.55); }
.phone-top .line{ height: 10px; border-radius: 10px; background: rgba(255,255,255,0.14); width: 84%; }
.phone-top .line.small{ width: 60%; }
.phone-card{
  margin-top: 14px;
  border-radius: 18px;
  background: linear-gradient(135deg, rgba(2,6,23,0.80), rgba(51,65,85,0.55));
  padding: 14px;
  display:flex;
  gap: 12px;
  align-items:center;
}
.chip{ width: 34px; height: 26px; border-radius: 8px; background: rgba(255,255,255,0.36); }
.card-lines{ display:flex; flex-direction:column; gap:8px; width: 100%; }
.phone-card .line{ background: rgba(255,255,255,0.32); height: 10px; border-radius: 10px; width: 78%; }
.phone-card .line.small{ width: 52%; }
.phone-list{ margin-top: 14px; display:flex; flex-direction:column; gap: 10px; }
.phone-list .row{ display:flex; justify-content:space-between; gap: 10px; }
.phone-list .row span{ display:block; height: 10px; border-radius: 10px; background: rgba(255,255,255,0.14); width: 46%; }
.phone-pill{ margin: 16px auto 0; width: 44%; height: 12px; border-radius: 99px; background: rgba(255,255,255,0.10); }
.visual-caption{ margin-top: 12px; color: var(--text-muted); font-size: 12px; }
.cap-title{ color: var(--text-main); font-weight: 600; margin-bottom: 2px; }

.marketing-section{ margin-top: 90px; }

@media (max-width: 860px) {
  .marketing-section{ margin-top: 64px; }
}
.marketing-trio{
  display:grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}
.marketing-card{
  padding: 4px 0;
}
.marketing-card h3{ margin: 10px 0 6px; font-size: 15px; }
.marketing-card p{ margin: 0; color: var(--text-muted); font-size: 13px; }
.mc-icon{
  width: 22px; height: 22px;
  display:flex; align-items:center; justify-content:center;
  background: transparent;
  border-radius: 0;
  color: var(--text-main);
}

.mc-icon svg{ width: 22px; height: 22px; }

/*
  Marketing split layout
  Use flex (not CSS grid) to avoid Safari/mobile rendering quirks.
  Desktop: 2 columns with optional reverse.
  Mobile: stacked, always text first then media.
*/
.m-split{
  display:flex;
  gap: 20px;
  align-items:flex-start;
}
.m-split .m-text,
.m-split .m-media{
  flex: 1 1 0;
  min-width: 0;
}
.m-split .m-media{
  display:flex;
  justify-content:flex-end;
  align-items:flex-start;
}
/* Reverse (desktop/tablet): media left, text right */
.m-split.m-split--reverse{ flex-direction: row-reverse; }
.m-split.m-split--reverse .m-media{ justify-content:flex-start; }


.m-text .page-intro{ margin-bottom: 12px; }

/* Section title accents (left + right underline) */
.m-title{
  position: relative;
  display: inline-block;
  padding-bottom: 10px;
}
.m-title::before{
  content: "";
  position: absolute;
  left: 0;
  bottom: 2px;
  width: 44px;
  height: 2px;
  border-radius: 99px;
  /* Marketing accent matches brand (footer color) */
  background: rgba(2, 6, 23, 0.65);
}
.m-title::after{
  content: "";
  position: absolute;
  right: 0;
  bottom: 2px;
  width: 18px;
  height: 2px;
  border-radius: 99px;
  background: rgba(2, 6, 23, 0.28);
}

/* Global titles: same accent as marketing (corporate, subtle) */
.ui-title{
  position: relative;
  /* Keep headings and optional icons perfectly centered vertically */
  display: inline-flex;
  align-items: center;
  gap: 10px;
  width: fit-content;
  max-width: 100%;
  padding-bottom: 10px;
  margin: 0 0 16px;
}
.ui-title .title-ico{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  width:18px;
  height:18px;
  padding:0;
  border-radius:0 !important;
  background:transparent !important;
  color: rgba(2, 6, 23, 0.78);
  flex: 0 0 auto;
}
.ui-title .title-ico svg{width:18px;height:18px;display:block}
.ui-title::before{
  content: "";
  position: absolute;
  left: 0;
  bottom: 2px;
  width: 44px;
  height: 2px;
  border-radius: 99px;
  background: rgba(2, 6, 23, 0.65);
}
.ui-title::after{
  content: "";
  position: absolute;
  right: 0;
  bottom: 2px;
  width: 18px;
  height: 2px;
  border-radius: 99px;
  background: rgba(2, 6, 23, 0.28);
}

/* Smaller variant for card titles */
.ui-title--sm{
  padding-bottom: 8px;
  margin: 0;
}
.ui-title--sm::before{ width: 34px; }
.ui-title--sm::after{ width: 14px; }

/*
  Typography policy (end-user UI): keep bold only for headings.
  Applied everywhere except marketing page and staff panels.
*/
/* Client app typography lock: applies to ALL roles while using the client UI.
   Staff panels use .bo and are excluded. */
body[data-scope="app"]:not(.bo) *{
  font-weight: 400 !important;
}
body[data-scope="app"]:not(.bo) h1,
body[data-scope="app"]:not(.bo) h2,
body[data-scope="app"]:not(.bo) h3,
body[data-scope="app"]:not(.bo) h4,
body[data-scope="app"]:not(.bo) h5,
body[data-scope="app"]:not(.bo) h6,
body[data-scope="app"]:not(.bo) .ui-title,
body[data-scope="app"]:not(.bo) .banking-card__title,
body[data-scope="app"]:not(.bo) .page-titlebar .ui-title,
body[data-scope="app"]:not(.bo) .logo,
body[data-scope="app"]:not(.bo) .nav-link span,
body[data-scope="app"]:not(.bo) .btn,
body[data-scope="app"]:not(.bo) .menu-item span,
body[data-scope="app"]:not(.bo) .profile-name,
body[data-scope="app"]:not(.bo) .notif-head,
body[data-scope="app"]:not(.bo) .tab,
body[data-scope="app"]:not(.bo) .pill{
  font-weight: 500 !important;
}

/* Keep bold tags subtle in client UI */
body[data-scope="app"]:not(.bo) b,
body[data-scope="app"]:not(.bo) strong{
  font-weight: 500 !important;
}

/* Subtle section separator (use where it actually adds clarity) */
.ui-sep{
  height: 1px;
  background: rgba(15, 23, 42, 0.08);
  margin: 14px 0;
}

/* Titles with icons: keep vertical centering consistent across pages */
.title-inline{
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}
.title-inline__ico{
  width: 18px;
  height: 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  color: rgba(2, 6, 23, 0.78);
}
.title-inline__ico svg{ width: 18px; height: 18px; display: block; }

/* Generic card headings */
.card-head{
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-width: 0;
}
h2.card-title{
  margin: 0 0 12px;
  font-size: 15px;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  position: relative;
  padding-bottom: 8px;
}
h2.card-title::before{
  content: "";
  position: absolute;
  left: 0;
  bottom: 2px;
  width: 34px;
  height: 2px;
  border-radius: 99px;
  background: rgba(2, 6, 23, 0.65);
}
h2.card-title::after{
  content: "";
  position: absolute;
  right: 0;
  bottom: 2px;
  width: 14px;
  height: 2px;
  border-radius: 99px;
  background: rgba(2, 6, 23, 0.28);
}
h2.card-title .ct-ico{
  width: 18px;
  height: 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: rgba(2, 6, 23, 0.78);
}
h2.card-title .ct-ico svg{ width: 18px; height: 18px; display: block; }

/* Icon wrapper used inside buttons/labels across pages */
.ico-wrap{ display: inline-flex; align-items: center; justify-content: center; }
.ico-wrap .ico{ width: 16px; height: 16px; display: block; }

/* Hero facts */
.hero-facts{
  margin: 14px 0 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-width: 560px;
}
.hero-facts li{
  padding-left: 14px;
  border-left: 2px solid rgba(2, 6, 23, 0.42);
  color: var(--text-muted);
  font-size: 13px;
  line-height: 1.35;
}
.hero-facts strong{ color: var(--text-main); font-weight: 600; }

.marketing-actions{ display:flex; gap: 10px; flex-wrap: wrap; margin-top: 12px; }

.marketing-note{
  margin-top: 12px;
  padding-left: 14px;
  border-left: 2px solid rgba(2, 6, 23, 0.42);
}
.mn-title{ font-weight: 600; margin-bottom: 4px; }
.mn-text{ color: var(--text-muted); font-size: 13px; }
.mn-actions{ margin-top: 10px; display:flex; gap: 10px; flex-wrap: wrap; }

.split{
  display:grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr);
  gap: 18px;
  align-items: start;
}
.split--reverse .split-text{ order: 2; }
.split--reverse .split-media{ order: 1; }
.split-text p{ color: var(--text-muted); font-size: 14px; }
.split-text .checklist{ margin: 12px 0 0; padding-left: 18px; color: var(--text-muted); font-size: 13px; }
.split-text .checklist li{ margin: 6px 0; }
.split-media{ display:flex; justify-content:flex-end; }
.media-card{
  width: 100%;
}
.media-graphic{ padding: 0; }
.media-caption{
  padding-top: 8px;
  color: var(--text-muted);
  font-size: 12px;
}
.media-meta{ padding: 12px 14px 14px; border-top: 1px solid rgba(15,23,42,0.08); }
.mm-title{ font-weight: 600; margin-bottom: 4px; }
.mm-text{ color: var(--text-muted); font-size: 12px; }

.marketing-grid2{
  margin-top: 14px;
  display:grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}
.marketing-tile{
  background: transparent;
  border: none;
  border-radius: 0;
  padding: 0;
}
.marketing-tile h3{ margin: 0 0 6px; font-size: 15px; }
.marketing-tile p{ margin: 0; color: var(--text-muted); font-size: 13px; }

.cta{
  background: linear-gradient(135deg, rgba(2,6,23,0.06), rgba(17,24,39,0.03));
  border: 1px solid rgba(15,23,42,0.10);
  border-radius: var(--radius-lg);
  padding: 18px;
  display:flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items:center;
  justify-content: space-between;
}
.cta h2{ margin: 0; font-size: 18px; }
.cta p{ margin: 4px 0 0; color: var(--text-muted); font-size: 13px; max-width: 620px; }
.cta-actions{ display:flex; gap: 10px; flex-wrap: wrap; }

.hero-main h1 {
  font-size: 30px;
  line-height: 1.2;
  margin-bottom: 12px;
}

.hero-main p {
  color: var(--text-muted);
  font-size: 14px;
  max-width: 520px;
}

.hero-actions {
  margin-top: 18px;
  display: flex;
  gap: 10px;
}

.hero-side {
  display: flex;
  justify-content: flex-end;
}

.hero-card {
  background: var(--bg-elevated);
  border-radius: var(--radius-lg);
  padding: 20px 18px;
}

.hero-card h2 {
  font-size: 17px;
  margin-bottom: 8px;
}

.hero-card p {
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 8px;
}

.hero-list {
  list-style: none;
  padding: 0;
  margin: 12px 0 0;
  font-size: 13px;
  color: var(--text-muted);
}

.hero-list li {
  margin-bottom: 4px;
}

.feature-section {
  margin-top: auto;
}

.feature-section h2 {
  font-size: 20px;
  margin-bottom: 14px;
}

.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 16px;
}

.feature-item {
  padding: 4px 0;
  font-size: 13px;
  color: var(--text-muted);
}

.feature-item h3 {
  font-size: 15px;
  margin-bottom: 6px;
  color: var(--text-main);
}

.page-intro {
  color: var(--text-muted);
  font-size: 14px;
  max-width: 640px;
  margin-bottom: 16px;
}

.form-grid {
  background: var(--bg-elevated);
  border-radius: var(--radius-lg);
  padding: 20px;
  display: grid;
  gap: 16px;
  margin-top: 16px;
}

.form-grid.narrow {
  max-width: 420px;
}

fieldset {
  border: none;
  padding: 0;
  margin: 0;
}

legend {
  padding: 0 0 8px;
  font-size: 13px;
  color: var(--text-muted);
  font-weight: 500;
}

label {
  display: block;
  font-size: 13px;
  margin-bottom: 6px;
}

/*
  Form controls
  NOTE: KYC uses inputs wrapped inside <label> elements, but other pages (e.g. Transfers)
  use a separate <label> + <input class="input">. To keep the UI consistent,
  we style BOTH patterns.
*/

label input,
input.input,
.input,
select,
textarea {
  margin-top: 6px;
  width: 100%;
  border-radius: 12px;
  border: 1px solid rgba(15, 23, 42, 0.14);
  background: #ffffff;
  color: var(--text-main);
  padding: 11px 12px;
  font-size: 14px;
  transition: box-shadow .15s ease, border-color .15s ease, background .15s ease;
}

input:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: rgba(15, 23, 42, 0.28);
  box-shadow: 0 0 0 4px rgba(15, 23, 42, 0.08);
  background: #f9fafb;
}

textarea {
  resize: vertical;
}

.field-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 10px;
}

.form-actions {
  display: flex;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 4px;
}

/* Mobile: actions should not look cramped or overflow */
@media (max-width: 520px){
  .form-actions{
    justify-content: stretch;
  }
  .form-actions .btn{
    flex: 1 1 auto;
  }
}

.alert {
  max-width: 720px;
  margin-left: auto;
  margin-right: auto;
  text-align: center;

  padding: 10px 12px;
  border-radius: 10px;
  font-size: 13px;
  margin-bottom: 12px;
}

.alert .btn{
  margin-left: 10px;
  vertical-align: middle;
}
@media (max-width: 520px){
  .alert .btn{
    margin-left: 0;
    margin-top: 8px;
  }
}

.alert.error {
  background: #fee2e2;
  color: #991b1b;
}

.alert.info {
  background: #f1f5f9;
  color: #0f172a;
}

.table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 16px;
  font-size: 13px;
  background: var(--bg-elevated);
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.table th,
.table td {
  padding: 9px 10px;
  border-bottom: 1px solid #e5e7eb;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.table th {
  text-align: left;
  background: #f3f4f6;
  font-weight: 500;
  font-size: 12px;
  color: var(--text-muted);
}

.table tr:last-child td {
  border-bottom: none;
}

.text-small {
  font-size: 12px;
  color: var(--text-muted);
}

.stats-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 18px;
}

.stat-card {
  flex: 0 0 150px;
  padding: 10px 12px;
  border-radius: var(--radius-lg);
  background: var(--bg-elevated);
}

/* Moderator overview: stretch KPI cards across full container */
body.bo-moderator .stats-row{
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 12px;
}
body.bo-moderator .stat-card{
  flex: unset;
  width: 100%;
}

.stat-label {
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 4px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.stat-value {
  font-size: 18px;
  font-weight: 600;
}

.site-footer {
  padding: 16px 0 24px;
  color: var(--text-muted);
  font-size: 12px;
  border-top: 1px solid #e5e7eb;
  margin-top: 32px;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.footer-note {
  max-width: 380px;
}

@media (max-width: 840px) {
  .hero {
    grid-template-columns: 1fr;
  }
  .hero-side {
    justify-content: flex-start;
  }
  .nav {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
  }
  .marketing-trio{ grid-template-columns: 1fr; }

  /* Stack marketing split blocks on small screens: text first, media after (always) */
  .m-split{ flex-direction: column; gap: 14px; }
  /* Reverse sections must NOT stay row-reverse on phones (it pushes blocks off-screen) */
  .m-split.m-split--reverse{ flex-direction: column; }
  .m-split .m-text,
  .m-split .m-media{ flex: 0 0 auto; }
  .m-split .m-media{ justify-content:flex-start; }


  .split{ grid-template-columns: 1fr; }
  .split-media{ justify-content:flex-start; }
  .marketing-grid2{ grid-template-columns: 1fr; }
}


/* --- KYC stepper & uploads --- */
.kyc-form { margin-top: 14px; }

/* KYC modern overrides */
.kyc-step {
  background: var(--bg-elevated);
  border: 1px solid rgba(0,0,0,0.06);
  border-radius: 16px;
  padding: 18px;
}

.kyc-step .form-grid {
  background: transparent;
  border: none;
  padding: 0;
  margin-top: 14px;
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

@media (max-width: 720px) {
  /* Match content cards' edge spacing on phones (fixes header/footer looking "shorter" than cards) */
  .container {
    /* Tighter, symmetrical gutter on iPhone to avoid the "shift right" feeling */
    padding-left: calc(12px + env(safe-area-inset-left));
    padding-right: calc(12px + env(safe-area-inset-right));
  }

  .footer-inner {
    padding-left: calc(12px + env(safe-area-inset-left));
    padding-right: calc(12px + env(safe-area-inset-right));
  }

  /* Keep form pages clean on mobile */
  .page-split{ grid-template-columns: 1fr; }
  .page-split__aside{ position: static; display: none; }

  /* Mobile banking dashboard polish */
  .qa-row{ grid-template-columns: 1fr; }
  .qa-btn{ flex-direction: row; align-items: center; justify-content: center; text-align:center; }
  .qa-btn__label{ text-align:center; }
  .month-summary{ display:grid; grid-template-columns: repeat(3, minmax(0, 1fr)); padding: 14px; }
  .month-summary__item{ padding: 10px 6px; }
  .month-summary__item + .month-summary__item{ border-top: 0; border-left: 1px solid rgba(15,23,42,0.10); }
  .month-summary__meta{ display:flex; flex-direction:column; align-items:center; justify-content:center; gap: 6px; text-align:center; }
  .month-summary__label{ margin:0; }
  .month-summary__value{ text-align:center; font-weight: 600; }

  /* Balance structure: avoid iOS overflow by stacking the progress bar below. */
  .structure-row{
    grid-template-columns: 1fr auto;
    grid-template-areas:
      "left right"
      "bar  bar";
    row-gap: 8px;
  }
  .structure-row__left{ grid-area: left; }
  .structure-row__bar{ grid-area: bar; }
  .structure-row__right{ grid-area: right; justify-self: end; text-align:right; }
  .structure-amount{ font-size: 13px; }
  .structure-percent{ font-size: 12px; }
  .banking-subtitle{ font-size: 13px; }

  .kyc-step .form-grid { grid-template-columns: 1fr; }
}

.field-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

@media (max-width: 720px) {
  .field-row { grid-template-columns: 1fr; }
}

.divider {
  height: 1px;
  background: rgba(0,0,0,0.06);
  margin: 16px 0;
  border-radius: 999px;
}

.upload-grid {
  margin-top: 14px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

@media (max-width: 900px) {
  .upload-grid { grid-template-columns: 1fr; }
}

.upload-preview { margin-top: 10px; display: grid; gap: 8px; }
.preview-img {
  width: 100%;
  border-radius: 12px;
  border: 1px solid rgba(0,0,0,0.06);
  display: block;
}

.file-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid rgba(0,0,0,0.08);
  background: rgba(0,0,0,0.03);
  font-weight: 700;
  font-size: 12px;
}

/* KYC: client-side optimization hint */
.kyc-upload-hint {
  font-size: 12px;
  color: var(--text-muted);
  padding-top: 2px;
}

/* KYC: submission overlay (loading animation) */
.kyc-submit-overlay {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(245, 245, 247, 0.75);
  backdrop-filter: blur(8px);
}

.kyc-submit-overlay .box {
  width: min(420px, 92vw);
  background: var(--bg-elevated);
  border: 1px solid rgba(2, 6, 23, 0.12);
  border-radius: 18px;
  box-shadow: 0 20px 60px rgba(2, 6, 23, 0.12);
  padding: 18px 18px 16px;
  display: grid;
  gap: 10px;
  text-align: center;
}

.kyc-submit-overlay .title {
  font-size: 14px;
  font-weight: 600;
  letter-spacing: -0.1px;
  color: var(--text-main);
}

.kyc-submit-overlay .sub {
  font-size: 12px;
  color: var(--text-muted);
}

.kyc-submit-overlay .spinner {
  width: 46px;
  height: 46px;
  margin: 6px auto 0;
  border-radius: 999px;
  border: 3px solid rgba(2, 6, 23, 0.14);
  border-top-color: var(--accent);
  animation: kycSpin 0.9s linear infinite;
}

@keyframes kycSpin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.summary-card summary {
  cursor: pointer;
  list-style: none;
}
.summary-card summary::-webkit-details-marker { display: none; }

.kyc-stepper {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  background: transparent;
  border: none;
  border-radius: 0;
  padding: 0;
  margin: 14px 0 16px;
}

.step {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 14px;
  color: var(--text-muted);
  position: relative;
  user-select: none;
  border: 1px solid rgba(0,0,0,0.06);
  background: rgba(0,0,0,0.015);
}

.step .step-icon {
  width: 34px;
  height: 34px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  background: rgba(0,0,0,0.04);
  border: 1px solid rgba(0,0,0,0.06);
}

.step .step-icon svg {
  width: 18px;
  height: 18px;
  fill: #2f343a; /* modern dark gray */
  opacity: 0.85;
}

.step .step-label { font-weight: 600; font-size: 10.5pt; }

.step.active {
  color: var(--text-main);
  border-color: rgba(0,0,0,0.12);
  background: rgba(0,0,0,0.02);
}

.step.completed {
  color: var(--text-main);
}

.step.completed .step-icon {
  background: rgba(30, 160, 90, 0.12);
  border-color: rgba(30, 160, 90, 0.25);
}

.step.completed .step-icon svg { display: none; }
.step.completed .step-icon::after {
  content: "✓";
  font-weight: 700;
  font-size: 12pt;
  color: rgb(30, 160, 90);
}

.kyc-title { margin-top: 0; }

.kyc-actions {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-top: 12px;
}

.hint {
  margin-top: 6px;
  padding: 0;
  border-radius: 0;
  background: transparent;
  border: 0;
  color: var(--text-muted);
  font-size: 12.5px;
  line-height: 1.35;
}

.upload-card {
  padding: 12px;
  border-radius: 14px;
  border: 1px dashed rgba(0,0,0,0.18);
  background: rgba(0,0,0,0.02);
  min-width: 0;
  overflow: hidden;
}

.upload-title { font-weight: 700; margin-bottom: 8px; }

/* KYC: styled file upload (prevents native input overflow on mobile) */
.upload-grid > * { min-width: 0; }

.file-uploader {
  position: relative;
  display: block;
  width: 100%;
  border-radius: 12px;
  border: 1px solid rgba(2, 6, 23, 0.14);
  background: rgba(255,255,255,0.75);
  padding: 10px 10px;
  cursor: pointer;
  overflow: hidden;
}

.file-uploader input[type="file"] {
  position: absolute;
  inset: 0;
  opacity: 0;
  width: 100%;
  height: 100%;
  cursor: pointer;
}

.file-uploader-ui {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.file-uploader-left {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.file-uploader-ico {
  width: 34px;
  height: 34px;
  border-radius: 12px;
  border: 1px solid rgba(2, 6, 23, 0.10);
  background: rgba(2, 6, 23, 0.04);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  color: var(--accent);
}

.file-uploader-ico svg {
  width: 18px;
  height: 18px;
  opacity: 0.85;
}

.file-uploader-text {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.file-uploader-main {
  font-weight: 800;
  color: var(--text-main);
  line-height: 1.05;
}

.file-uploader-sub {
  font-size: 12px;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.file-uploader-action {
  flex: 0 0 auto;
  padding: 8px 10px;
  border-radius: 10px;
  border: 1px solid var(--btn-border);
  background: var(--btn-bg);
  font-weight: 800;
  font-size: 12px;
}

.file-uploader:hover .file-uploader-action {
  background: var(--btn-bg-hover);
}

.file-uploader:focus-within {
  box-shadow: 0 0 0 3px rgba(2, 6, 23, 0.10);
  border-color: rgba(2, 6, 23, 0.24);
}

.file-uploader-note {
  margin-top: 8px;
  line-height: 1.35;
}


.upload-preview { margin-top: 10px; display: grid; gap: 8px; }
.file-preview-img {
  max-width: 100%;
  border-radius: 12px;
  border: 1px solid rgba(0,0,0,0.08);
}
.file-meta { font-size: 10.5pt; color: var(--text-muted); }
.file-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid rgba(0,0,0,0.12);
  background: rgba(0,0,0,0.03);
  width: fit-content;
  font-weight: 700;
  letter-spacing: 0.04em;
  font-size: 10pt;
}

.summary-card {
  padding: 14px;
  border-radius: 14px;
  background: var(--bg-elevated);
  border: 1px solid rgba(0,0,0,0.06);
}
.summary-title { font-weight: 700; margin-bottom: 8px; }
.summary-grid { display: grid; gap: 8px; }
.summary-row { display: grid; grid-template-columns: 180px 1fr; gap: 10px; padding: 8px 10px; border-radius: 12px; background: rgba(0,0,0,0.03); }
.summary-row .k { color: var(--text-muted); font-weight: 600; }
.summary-row .v { color: var(--text-main); word-break: break-word; }

.check {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  margin-top: 12px;
  padding: 10px 12px;
  border-radius: 14px;
  border: 1px solid rgba(0,0,0,0.06);
  background: rgba(0,0,0,0.02);
}

/* --- KYC review (final step) --- */
.kyc-review{ margin-top: 14px; }
.kyc-review-block{ margin-top: 14px; }
.kyc-review-title{
  font-weight: 700;
  letter-spacing: -0.01em;
  margin: 0 0 8px;
}
.kyc-review-note{ margin-top: 14px; }

/* Thin-divider key/value list (no pills, no outer border) */
.kyc-kv-row{
  display: grid;
  grid-template-columns: 210px minmax(0, 1fr);
  column-gap: 16px;
  padding: 10px 0;
  border-top: 1px solid rgba(15, 23, 42, 0.08);
}
.kyc-kv-row:first-child{ border-top: 0; padding-top: 0; }
.kyc-kv-k{ color: var(--text-muted); font-size: 12.5px; line-height: 1.35; }
.kyc-kv-v{ font-size: 12.5px; font-weight: 700; line-height: 1.35; overflow-wrap:anywhere; }

@media (max-width: 720px){
  .kyc-kv-row{ grid-template-columns: 1fr; row-gap: 6px; }
}

/* --- Moderator detail layout --- */
.grid-2 { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 14px; }
@media (max-width: 900px) { .grid-2 { grid-template-columns: 1fr; } }

.card {
  background: var(--bg-elevated);
  border: 1px solid rgba(0,0,0,0.06);
  border-radius: 14px;
  padding: 14px;
}

.kv { display: grid; grid-template-columns: 160px 1fr; gap: 8px 12px; }
.kv .k { color: var(--text-muted); font-weight: 600; }
.kv .v { color: var(--text-main); word-break: break-word; }
.mono{
  /* Hard-lock typography: keep IBM Plex Sans everywhere, including "code"/refs.
     Use tabular numbers to keep alignment without switching fonts. */
  font-family: "IBM Plex Sans", system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif !important;
  font-variant-numeric: tabular-nums;
  font-feature-settings: "tnum" 1;
  font-size: 12px;
  overflow-wrap: anywhere;
  word-break: break-word;
}
.pill {
  display: inline-flex;
  padding: 3px 8px;
  border-radius: 999px;
  border: 1px solid rgba(0,0,0,0.10);
  background: rgba(0,0,0,0.03);
  /* Use real IBM Plex Sans weights (prevents Chrome synthesising heavy glyphs) */
  font-weight: 600;
  font-size: 9.5pt;
  margin-right: 6px;
}

.pill.danger{
  background: #fee2e2;
  color: #991b1b;
  border-color: rgba(153, 27, 27, 0.18);
}
.pill.warn{
  background: #ffedd5;
  color: #9a3412;
  border-color: rgba(154, 52, 18, 0.18);
}
.pill.ok{
  background: #dcfce7;
  color: #166534;
  border-color: rgba(22, 101, 52, 0.18);
}

.files-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
@media (max-width: 900px) { .files-grid { grid-template-columns: 1fr; } }

.file-card {
  border: 1px solid rgba(0,0,0,0.06);
  border-radius: 14px;
  padding: 12px;
  background: rgba(0,0,0,0.02);
}
.file-title { font-weight: 700; margin-bottom: 8px; }
.file-img { width: 100%; border-radius: 12px; border: 1px solid rgba(0,0,0,0.08); }

.role-links{display:flex;gap:8px;flex-wrap:wrap;justify-content:flex-end;margin-right:10px}
@media (max-width:900px){.role-links{display:none}}


/* KYC — Stepper (minimal) */
.kyc-stepper-min{
  margin: 10px 0 18px;
}

.kyc-stepper-row{
  display:flex;
  align-items:center;
  justify-content:center;
  gap:14px;
  padding: 6px 2px;
  overflow-x:auto;
  -webkit-overflow-scrolling: touch;
}

.kyc-stepper-row::-webkit-scrollbar{ height: 8px; }
.kyc-stepper-row::-webkit-scrollbar-thumb{ background: rgba(0,0,0,.10); border-radius: 999px; }
.kyc-stepper-row::-webkit-scrollbar-track{ background: transparent; }

.kyc-step-item{
  display:flex;
  flex-direction:column;
  align-items:center;
  text-align:center;
  min-width: 92px;
  user-select:none;
}

.kyc-step-iconWrap{
  width: 46px;
  height: 46px;
  border-radius: 999px;
  background: #f2f3f5;
  display:grid;
  place-items:center;
  position:relative;
}

.kyc-step-item .kyc-ico{
  width: 24px;
  height: 24px;
  color:#3f4650;
}

.kyc-step-label{
  margin-top: 8px;
  font-size: 12px;
  font-weight: 600;
  color:#5b636e;
  letter-spacing: .2px;
}

.kyc-step-arrow{
  width: 22px;
  flex: 0 0 22px;
  display:flex;
  align-items:center;
  justify-content:center;
  opacity: .55;
}

.kyc-step-arrow svg{
  width: 18px;
  height: 18px;
  color:#7b838f;
}

.kyc-stepper-divider{
  height: 1px;
  background: #e7eaee;
  margin-top: 12px;
}

/* states driven by /public/js/kyc.js */
.kyc-step-item.active .kyc-step-iconWrap{
  background:#eceff3;
}

.kyc-step-item.active .kyc-ico{
  color:#1b2129;
}

.kyc-step-item.active .kyc-step-label{
  color:#1b2129;
}

.kyc-step-item.future{
  opacity: .90;
}

.kyc-step-item.completed .kyc-step-iconWrap{
  background: rgba(15, 23, 42, 0.06);
}

.kyc-step-item.completed .kyc-ico{
  color: rgba(15, 23, 42, 0.86);
}

.kyc-step-item.completed .kyc-step-label{
  color:#1b2129;
}

.kyc-step-check{
  position:absolute;
  right: -2px;
  bottom: -2px;
  width: 18px;
  height: 18px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.10);
  display:none;
  align-items:center;
  justify-content:center;
  box-shadow: 0 0 0 2px #ffffff;
  color: rgba(15, 23, 42, 0.90);
}

.kyc-step-check svg{ width: 12px; height: 12px; }

.kyc-step-item.completed .kyc-step-check{
  display:flex;
}

/* color the arrows after completed steps */
.kyc-step-item.completed + .kyc-step-arrow svg{
  color: rgba(15, 23, 42, 0.55);
  opacity: .9;
}



/* Stepper icon normalization */
.kyc-step-item .kyc-ico{
  width:24px;
  height:24px;
  display:block;
}


/* Checkbox / Radio — unified bank-style controls */
input[type="checkbox"],
input[type="radio"]{
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  width: 18px;
  height: 18px;
  border-radius: 6px;
  border: 1px solid rgba(15, 23, 42, 0.18);
  background: #ffffff;
  display: inline-grid;
  place-content: center;
  margin: 0;
  flex: 0 0 18px;
}

input[type="radio"]{ border-radius: 999px; }

input[type="checkbox"]:focus,
input[type="radio"]:focus{
  outline: none;
  border-color: rgba(15, 23, 42, 0.28);
  box-shadow: 0 0 0 4px rgba(15, 23, 42, 0.08);
}

input[type="checkbox"]:checked{
  background: rgb(30, 160, 90);
  border-color: rgb(30, 160, 90);
}

input[type="checkbox"]:checked::after{
  content: "";
  width: 6px;
  height: 10px;
  border-right: 2px solid #ffffff;
  border-bottom: 2px solid #ffffff;
  transform: translateY(-1px) rotate(45deg);
}

input[type="radio"]:checked{
  border-color: rgb(30, 160, 90);
}

input[type="radio"]:checked::after{
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: rgb(30, 160, 90);
}

/* Declaration/consent line */
.checkline{
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 12px 14px;
  border: 1px solid rgba(15, 23, 42, 0.10);
  background: #f6f7f9;
  border-radius: 14px;
  line-height: 1.35;
  cursor: pointer;
}

.checkline input{ margin-top: 2px; }

.checkline span{
  font-size: 13.5px;
  color: var(--text-main);
}

.checkline:hover{
  border-color: rgba(15, 23, 42, 0.18);
  background: #f4f5f7;
}


/* Status card */
.status-card{
  max-width: 860px;
  margin: 18px auto;
  background: var(--bg-elevated);
  border-radius: 18px;
  padding: 18px 18px;
  display: grid;
  grid-template-columns: 58px 1fr;
  gap: 16px;
  border: 1px solid rgba(15, 23, 42, 0.10);
}

.status-card .status-icon{
  width: 48px;
  height: 48px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  background: rgba(15, 23, 42, 0.06);
  color: rgba(15, 23, 42, 0.74);
  margin-top: 2px;
}

.status-card .status-icon svg{
  width: 26px;
  height: 26px;
}

/* KYC status page refinements (match marketing/style system)
   - remove the "pill" behind the header icon
   - use thin dividers (no outer table border)
   - increase vertical rhythm between text, table, and actions */
.page-content[data-page="kyc-status"] .status-card .status-icon{
  background: transparent;
  width: auto;
  height: auto;
  border-radius: 0;
  margin-top: 0;
  color: rgba(15, 23, 42, 0.74);
}
.page-content[data-page="kyc-status"] .status-card .status-icon svg{
  width: 28px;
  height: 28px;
}
.page-content[data-page="kyc-status"] .status-text{
  margin-bottom: 22px;
}
.page-content[data-page="kyc-status"] .status-meta.kyc-meta{
  background: transparent;
  border: none;
  border-radius: 0;
  padding: 0;
  margin: 18px 0 24px;
}
.page-content[data-page="kyc-status"] .kyc-meta .meta-row{
  padding: 12px 0;
}
.page-content[data-page="kyc-status"] .status-actions{
  margin-top: 6px;
  margin-bottom: 14px;
}
.page-content[data-page="kyc-status"] .btn .btn-ico svg{
  width: 16px;
  height: 16px;
}

.status-title{
  margin: 0 0 6px;
  font-size: 20px;
  letter-spacing: .2px;
}

.status-text{
  margin: 0 0 14px;
  color: var(--text-muted);
  font-size: 14px;
  line-height: 1.5;
}

.status-meta{
  background: #ffffff;
  border: 1px solid rgba(15, 23, 42, 0.08);
  border-radius: 16px;
  padding: 12px 14px;
  margin-bottom: 14px;
}

.meta-row{
  display: grid;
  grid-template-columns: 170px 1fr;
  gap: 12px;
  padding: 8px 0;
}

.meta-row + .meta-row{
  border-top: 1px solid rgba(15, 23, 42, 0.06);
}

.meta-k{
  font-size: 12px;
  color: var(--text-muted);
}

.meta-v{
  font-size: 13.5px;
  color: var(--text-main);
}

.status-actions{
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 10px;
}

.status-footnote{
  margin: 0;
  font-size: 12px;
  color: var(--text-muted);
}

@media (max-width: 640px){
  .status-card{
    grid-template-columns: 1fr;
  }
  .status-card .status-icon{
    width: 44px;
    height: 44px;
    border-radius: 14px;
  }
  .page-content[data-page="kyc-status"] .status-card .status-icon{
    width: auto;
    height: auto;
    border-radius: 0;
    background: transparent;
  }
  .meta-row{
    grid-template-columns: 1fr;
  }
}


/* Back-office (admin/moderation workspace) */
body.backoffice{
  background: #0b1220;
}



.bo-scrim{
  display:none;
  position: fixed;
  inset: 0;
  background: rgba(2,6,23,0.50);
  z-index: 40;
}
html.bo-open .bo-scrim{ display:block; }
.bo-shell{
  min-height: 100vh;
  display: grid;
  grid-template-columns: 260px 1fr;
}

.bo-sidebar{
  background: #0f172a;
  border-right: 1px solid rgba(255,255,255,0.06);
  padding: 18px 14px;
  display:flex;
  flex-direction: column;
  gap: 14px;
}

.bo-brand{
  padding: 10px 10px 14px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}

.bo-logo{
  color: #e5e7eb;
  font-weight: 700;
  letter-spacing: .4px;
}

.bo-sub{
  margin-top: 6px;
  font-size: 12px;
  color: rgba(229,231,235,0.62);
}

.bo-nav{
  display:flex;
  flex-direction: column;
  gap: 6px;
  padding: 0 6px;
}

.bo-nav-section{
  margin-top: 10px;
  margin-bottom: 6px;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .12em;
  color: rgba(229,231,235,0.45);
  padding-left: 6px;
}

.bo-link{
  display:flex;
  align-items:center;
  gap: 10px;
  padding: 10px 10px;
  border-radius: 12px;
  color: rgba(229,231,235,0.86);
  text-decoration: none;
  border: 1px solid transparent;
}

.bo-link:hover{
  background: rgba(255,255,255,0.04);
  border-color: rgba(255,255,255,0.06);
}

.bo-link.active{
  background: rgba(59,130,246,0.14);
  border-color: rgba(59,130,246,0.22);
  color: #e5e7eb;
}

.bo-sidebar-foot{
  margin-top: auto;
  padding: 8px 6px 0;
  display:flex;
  flex-direction: column;
  gap: 6px;
  border-top: 1px solid rgba(255,255,255,0.06);
}

.bo-link.danger{
  color: rgba(248,113,113,0.92);
}

.bo-main{
  background: #f3f4f6;
}



.bo-menu-btn{ display:none; }
.bo-topbar{
  background: #ffffff;
  border-bottom: 1px solid rgba(15,23,42,0.08);
  padding: 14px 18px;
  display:flex;
  align-items:center;
  justify-content: space-between;
}

.bo-title{
  font-size: 14px;
  font-weight: 700;
  color: #0f172a;
}

.bo-user{
  display:flex;
  align-items: baseline;
  gap: 10px;
}

.bo-user-name{
  font-weight: 700;
  color: #0f172a;
  font-size: 13px;
}

.bo-user-role{
  font-size: 12px;
  color: rgba(15,23,42,0.55);
}

.bo-content{
  padding: 18px;
}

.bo-card{
  background: #ffffff;
  border: 1px solid rgba(15,23,42,0.08);
  border-radius: 16px;
  padding: 16px;
}

.bo-card-title{
  font-weight: 700;
  margin-bottom: 8px;
  color:#0f172a;
}

.bo-card-text{
  margin:0;
  color: rgba(15,23,42,0.62);
  line-height: 1.5;
}

/* Back-office button variants */
.btn.danger{
  background: rgb(239, 68, 68);
  border-color: rgb(239, 68, 68);
  color: #fff;
}
.btn.danger:hover{
  filter: brightness(0.97);
}

/* Warning action (used sparingly in back-office flows) */
.btn.warn{
  background: rgba(245, 158, 11, 0.92);
  border-color: rgba(245, 158, 11, 0.92);
  color: #111827;
}
.btn.warn:hover{ filter: brightness(0.97); }

@media (max-width: 980px){
  .bo-shell{ grid-template-columns: 1fr; }
  .bo-sidebar{ position: sticky; top: 0; z-index: 20; }
}


/* Back-office (header nav) — separate from online banking UI */
body.bo{
  background: #0b1220;
}

.bo-header{
  background: #0f172a;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}

.bo-header-inner{
  max-width: 1180px;
  margin: 0 auto;
  padding: 14px 16px;
  display:flex;
  align-items:center;
  justify-content: space-between;
  gap: 14px;
}

.bo-brand{
  display:flex;
  align-items:center;
  gap: 10px;
  min-width: 220px;
}

.bo-logo{
  color:#e5e7eb;
  font-weight: 700;
  letter-spacing: .4px;
}

.bo-badge{
  font-size: 12px;
  color: rgba(229,231,235,0.72);
  padding: 6px 10px;
  border: 1px solid rgba(255,255,255,0.10);
  border-radius: 999px;
  background: rgba(255,255,255,0.04);
}

.bo-nav{
  display:flex;
  align-items:center;
  gap: 8px;
  flex-wrap: wrap;
}

.bo-nav-link{
  color: rgba(229,231,235,0.80);
  text-decoration:none;
  padding: 8px 10px;
  border-radius: 10px;
  border: 1px solid transparent;
  font-weight: 600;
  font-size: 13px;
}

.bo-nav-link:hover{
  background: rgba(255,255,255,0.04);
  border-color: rgba(255,255,255,0.08);
}

.bo-nav-link.active{
  background: rgba(59,130,246,0.16);
  border-color: rgba(59,130,246,0.24);
  color: #e5e7eb;
}

.bo-actions{
  display:flex;
  align-items:center;
  gap: 10px;
  flex-wrap: wrap;
}

.bo-main{
  background: #f3f4f6;
  min-height: calc(100vh - 64px);
}

.bo-container{
  max-width: 1180px;
  margin: 0 auto;
  padding: 18px 16px;
}

/* Cards in back-office */
.bo-card{
  background:#ffffff;
  border: 1px solid rgba(15,23,42,0.08);
  border-radius: 16px;
  padding: 16px;
}

.bo-card-title{
  font-weight: 700;
  margin-bottom: 8px;
  color:#0f172a;
}

.bo-card-text{
  margin: 0;
  color: rgba(15,23,42,0.62);
  line-height: 1.5;
}



/* Back-office UI — minimalist, system-like (no cards/borders/shadows in chrome) */
body.bo{
  background: #f6f7f9;
}

.bo-header{
  background: #ffffff;
}

.bo-header-inner{
  max-width: 1180px;
  margin: 0 auto;
  padding: 18px 16px 12px;
  display:flex;
  align-items:flex-end;
  justify-content: space-between;
  gap: 16px;
}

.bo-brand{
  display:flex;
  align-items: baseline;
  gap: 12px;
}

.bo-logo{
  font-weight: 700;
  letter-spacing: .3px;
  color: #0f172a;
  font-size: 16px;
}

.bo-area{
  font-size: 13px;
  color: rgba(15,23,42,0.56);
  font-weight: 600;
}

.bo-head-meta{
  display:flex;
  align-items:flex-end;
  gap: 18px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.bo-user{
  display:flex;
  flex-direction: column;
  align-items:flex-end;
  line-height: 1.1;
}

.bo-user-name{
  font-size: 13px;
  font-weight: 600;
  color: #0f172a;
}

.bo-user-role{
  margin-top: 4px;
  font-size: 12px;
  color: rgba(15,23,42,0.54);
}

.bo-head-actions{
  display:flex;
  align-items:center;
  gap: 10px;
}

.bo-head-link{
  color: rgba(15,23,42,0.70);
  text-decoration:none;
  font-weight: 600;
  font-size: 13px;
}

.bo-head-link:hover{
  color: rgba(15,23,42,0.92);
}

.bo-head-link.danger{
  color: rgb(220, 38, 38);
}

.bo-dot{
  color: rgba(15,23,42,0.28);
  user-select: none;
}

/* Sub-navigation (tabs under header) */
.bo-subnav{
  border-top: 1px solid rgba(15,23,42,0.06);
  border-bottom: 1px solid rgba(15,23,42,0.08);
  background: #ffffff;
}

.bo-subnav-inner{
  max-width: 1180px;
  margin: 0 auto;
  padding: 10px 16px;
  display:flex;
  align-items:center;
  gap: 18px;
  flex-wrap: wrap;
}

/* Backoffice tab rows: force two-line nav without single orphan items */
.bo-subnav-rows{
  width:100%;
  display:flex;
  flex-direction:column;
  gap: 6px;
}

.bo-subnav-row{
  display:flex;
  align-items:center;
  gap: 18px;
  width: 100%;
}

/* Moderator navigation: stretch to full container width (two rows), evenly distributed */
body.bo-moderator .bo-subnav-row{
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 12px;
  width: 100%;
  align-items: stretch;
}
body.bo-moderator .bo-subnav-row .bo-tab{
  width: 100%;
  justify-content: center;
  text-align: center;
}
body.bo-moderator .bo-tab > span{ text-align: center; }

.bo-subnav-row .bo-tab{
  flex: 1 1 0;
  min-width: 0;
  padding: 10px 10px;
  border-radius: 12px;
}

.bo-subnav-row .bo-tab:hover{
  background: rgba(15,23,42,0.04);
}

.bo-subnav-row .bo-tab.active{
  background: rgba(15,23,42,0.06);
}

.bo-subnav-row .bo-tab.active::after{
  left: 10px;
  right: 10px;
}

/* Back-office tabs: no underline indicator (active state is the pill background). */
.bo-subnav-row .bo-tab.active::after{ display: none !important; }

@media (max-width: 720px){
  .bo-subnav-row{
    flex-wrap: wrap;
  }
  .bo-subnav-row .bo-tab{
    flex: 1 1 calc(50% - 10px);
  }
}

.bo-tab{
  display:inline-flex;
  align-items:center;
  gap: 10px;
  padding: 10px 2px;
  text-decoration:none;
  color: rgba(15,23,42,0.62);
  font-weight: 700;
  font-size: 13.5px;
  position: relative;
}

.bo-tab-ico{
  width: 18px;
  height: 18px;
  display:inline-grid;
  place-items:center;
  color: rgba(15,23,42,0.48);
}

.bo-tab-ico svg{
  width: 18px;
  height: 18px;
}

.bo-tab:hover{
  color: rgba(15,23,42,0.88);
}

.bo-tab:hover .bo-tab-ico{
  color: rgba(15,23,42,0.66);
}

.bo-tab.active{
  color: #0f172a;
}

.bo-tab.active .bo-tab-ico{
  color: rgba(15,23,42,0.82);
}

.bo-tab.active::after{
  content: "";
  display: none;
}

.bo-tab.active::after{ display: none !important; }

/* Moderator navigation should look centred and balanced. */
.bo-moderator .bo-subnav-row{ justify-content: center; }

/* Moderator global notice (top-of-panel) */
.bo-global-note{
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  padding: 12px 14px;
  border-radius: 16px;
  border: 1px solid rgba(0,0,0,0.08);
  background: rgba(2,6,23,0.03);
}
.bo-global-note__ico{
  width: 22px;
  height: 22px;
  display:flex;
  align-items:center;
  justify-content:center;
  color: rgba(2, 6, 23, 0.72);
  flex: 0 0 auto;
  margin-top: 2px;
}
.bo-global-note__ico svg{ width: 22px; height: 22px; }
.bo-global-note__main{ min-width: 0; max-width: 920px; }
.bo-global-note__title{ margin:0; }
.bo-global-note__text{
  margin-top: 6px;
  opacity: 0.88;
  white-space: pre-wrap;
  font-size: 13px;
  line-height: 1.35;
}
.bo-global-note__actions{ flex: 0 0 auto; }
@media (max-width: 720px){
  .bo-global-note{ flex-wrap: wrap; }
  .bo-global-note__actions{ width: 100%; }
  .bo-global-note__actions .btn{ width: 100%; }
}

/* Main */
.bo-main{
  background: transparent;
  min-height: calc(100vh - 110px);
}

.bo-container{
  max-width: 1180px;
  margin: 0 auto;
  padding: 18px 16px 26px;
}

/* Back-office content blocks */
.bo-card{
  background: #ffffff;
  border-radius: 16px;
  padding: 16px;
}

/* Make existing .btn less "app-like" in back-office (keep but subtle) */
body.bo .btn{
  border-radius: 12px;
}



/* Back-office polish — alignment & hover */
.bo-header-inner{
  align-items: center;
}

.bo-brand{
  align-items: center;
}

.bo-head-meta{
  align-items: center;
}

.bo-user{
  align-items: flex-end;
}

.bo-head-actions{
  align-items: center;
}

/* Tabs: no underline on hover; highlight the clickable area instead */
.bo-tab,
.bo-tab:hover{
  text-decoration: none !important;
}

.bo-tab{
  padding: 10px 10px;
  border-radius: 12px;
}

.bo-tab:hover{
  background: rgba(15,23,42,0.04);
}

.bo-tab.active{
  background: rgba(15,23,42,0.03);
}

.bo-tab.active::after{
  left: 10px;
  right: 10px;
}

/* Exit link: neutral (not danger/red) */
.bo-head-link.danger{
  color: rgba(15,23,42,0.70);
}



/* Header — aligned container + divider */
.site-header{
  background: #ffffff;
}
.header-inner{
  display:flex;
  align-items:center;
  justify-content: space-between;
  gap: 18px;
}
.logo{
  font-weight: 700;
  letter-spacing: .3px;
  text-decoration: none;
  color: #0f172a;
}
.header-divider{
  height: 1px;
  background: rgba(15, 23, 42, 0.10);
}

/* Primary nav — hover area + animated underline (no text underline) */
.nav{
  display:flex;
  align-items:center;
  gap: 6px;
}
.nav-link{
  position: relative;
  padding: 10px 12px;
  border-radius: 12px;
  color: rgba(15,23,42,0.70);
  text-decoration: none !important;
  /* Navigation should be regular weight (only headings are bold) */
  font-weight: 400;
  font-size: 13.5px;
}

/* Defensive: ensure text inside nav links never becomes bold via nested tags/rules */
.nav-link span,
.nav-link b,
.nav-link strong{ font-weight: 400 !important; }
.nav-link:hover{
  background: rgba(15,23,42,0.04);
  color: rgba(15,23,42,0.92);
}
.nav-link::after{
  content:"";
  position:absolute;
  left: 12px;
  right: 12px;
  bottom: 6px;
  height: 2px;
  background: rgba(15, 23, 42, 0.90);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .18s ease;
}
.nav-link:hover::after{
  transform: scaleX(1);
}
.nav-link.active{
  color: #0f172a;
  /* Keep navigation text regular even when active */
  font-weight: 400 !important;
}

.nav-link.active span{
  font-weight: 400 !important;
}

.nav-link.active::after{
  transform: scaleX(1);
}

/* Notifications (bell) */
.notif-menu{ position: relative; }
.notif-trigger{
  border: 0;
  background: transparent;
  display:flex;
  align-items:center;
  justify-content:center;
  padding: 8px 10px;
  border-radius: 14px;
  cursor: pointer;
  position: relative;
}
.notif-trigger:hover{ background: rgba(15,23,42,0.04); }
.notif-ico{ display:grid; place-items:center; color: rgba(15,23,42,0.68); }
.notif-ico svg{ width: 22px; height: 22px; }
.notif-badge{
  position:absolute;
  top: 4px;
  right: 5px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 999px;
  background: rgb(219, 0, 17);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  display:flex;
  align-items:center;
  justify-content:center;
  line-height: 1;
}

.notif-dropdown{
  position:absolute;
  top: calc(100% + 10px);
  right: 0;
  width: 340px;
  background:#ffffff;
  border: 1px solid rgba(15,23,42,0.10);
  border-radius: 16px;
  padding: 10px;
  display:none;
  z-index: 60;
}
.notif-dropdown.open{ display:block; }
/* Mobile: keep notifications dropdown inside viewport */
@media (max-width: 640px){
  .notif-dropdown{
    position: fixed;
    top: 74px; /* below header */
    left: 12px;
    right: 12px;
    width: auto;
    max-width: calc(100vw - 24px);
    max-height: calc(100dvh - 96px - env(safe-area-inset-bottom, 0px));
    overflow: auto;
    overscroll-behavior: contain;
  }
}

.notif-head{
  padding: 8px 10px 10px;
  font-weight: 700;
  color: #0f172a;
  font-size: 13.5px;
}
.notif-list{ padding: 0 4px 4px; }
.notif-empty{
  padding: 10px;
  font-size: 12.5px;
  color: rgba(15,23,42,0.55);
}
.notif-item{
  display:flex;
  gap: 10px;
  padding: 10px 10px;
  border-radius: 12px;
  text-decoration:none !important;
  color: rgba(15,23,42,0.78);
}
.notif-item:hover{ background: rgba(15,23,42,0.04); }
.notif-dot{
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: rgba(15,23,42,0.30);
  margin-top: 4px;
  flex: 0 0 10px;
}
.notif-body{ display:flex; flex-direction:column; gap: 4px; }
.notif-title{ font-weight: 700; font-size: 12.8px; color: rgba(15,23,42,0.90); }
.notif-text{ font-size: 12.5px; color: rgba(15,23,42,0.70); }
.notif-time{ font-size: 11.5px; color: rgba(15,23,42,0.50); }

/* Profile menu */
.profile-menu{ position: relative; }
.profile-trigger{
  border: 0;
  background: transparent;
  display:flex;
  align-items:center;
  gap: 6px;
  padding: 8px 10px;
  border-radius: 14px;
  cursor: pointer;
}
.profile-trigger:hover{
  background: rgba(15,23,42,0.04);
}
.profile-ico, .profile-caret{
  display:grid;
  place-items:center;
  color: rgba(15,23,42,0.68);
}
.profile-ico svg{ width: 22px; height: 22px; }
.profile-caret svg{ width: 16px; height: 16px; }

.profile-dropdown{
  position:absolute;
  top: calc(100% + 10px);
  right: 0;
  width: 260px;
  background:#ffffff;
  border: 1px solid rgba(15,23,42,0.10);
  border-radius: 16px;
  padding: 10px;
  display:none;
  z-index: 50;
}
.profile-dropdown.open{ display:block; }

.profile-head{
  padding: 8px 10px 10px;
}
.profile-name{
  font-weight: 700;
  color: #0f172a;
  font-size: 13.5px;
}
.profile-meta{
  margin-top: 4px;
  font-size: 12px;
  color: rgba(15,23,42,0.55);
  word-break: break-all;
}

.menu-item{
  display:flex;
  align-items:center;
  gap: 10px;
  padding: 10px 10px;
  border-radius: 12px;
  text-decoration:none !important;
  color: rgba(15,23,42,0.78);
  font-weight: 600;
  font-size: 13.5px;
}
.menu-item:hover{
  background: rgba(15,23,42,0.04);
  color: rgba(15,23,42,0.92);
}
.mi-ico{
  width: 18px;
  height: 18px;
  display:grid;
  place-items:center;
  color: rgba(15,23,42,0.58);
}
.mi-ico svg{ width: 18px; height: 18px; }
.menu-item:hover .mi-ico{ color: rgba(15,23,42,0.70); }

.menu-divider{
  height: 1px;
  background: rgba(15,23,42,0.08);
  margin: 8px 8px;
}

.menu-item.logout{
  margin-top: 2px;
}

/* Ensure header actions align to container edges */
.header-actions{
  display:flex;
  align-items:center;
  justify-content:flex-end;
  gap: 10px;
}



/* Header refinement — bank-like, aligned, non-toy */
.site-header{
  background:#ffffff;
  border-bottom: 1px solid rgba(15, 23, 42, 0.10);
}

.site-header .header-inner{
  height: 64px;
  padding: 0;
}

.site-header .logo{
  display:flex;
  align-items:center;
  height: 64px;
}

.site-header .nav{
  height: 64px;
  gap: 4px;
  flex: 1;
  min-width: 0;
  justify-content: center;
  overflow-x: auto;
  overflow-y: hidden;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none; /* Firefox */
}

.site-header .nav::-webkit-scrollbar{ height: 0; width: 0; }

.site-header .nav-link{
  height: 64px;
  display:flex;
  align-items:center;
  gap: 10px;
  padding: 0 12px;
  border-radius: 10px;
  font-weight: 600;
}

.site-header .nav-link::after{
  left: 12px;
  right: 12px;
  bottom: 0px; /* sits on header baseline */
  height: 2px;
}

.site-header .nav-link:hover{
  background: rgba(15,23,42,0.035);
}

.site-header .nav-ico{
  width: 18px;
  height: 18px;
  display:grid;
  place-items:center;
  color: rgba(15,23,42,0.52);
}

.site-header .nav-ico svg{
  width: 18px;
  height: 18px;
}

.site-header .nav-link:hover .nav-ico{
  color: rgba(15,23,42,0.70);
}

.site-header .header-actions{
  height: 64px;
}

.profile-trigger{
  height: 40px;
  padding: 0 10px;
  border-radius: 12px;
}

.profile-ico svg{
  width: 18px;
  height: 18px;
}

.profile-caret svg{
  width: 14px;
  height: 14px;
}

/* Dropdown less toy-ish */
.profile-dropdown{
  border-radius: 12px;
  padding: 8px;
  width: 252px;
}

.menu-item{
  padding: 9px 10px;
  border-radius: 10px;
}





/* Header polish — tighter baseline, cleaner hover (underline only) */
.site-header{
  border-bottom: 1px solid rgba(15, 23, 42, 0.10);
}

.site-header .header-inner{
  height: 56px;
}

.site-header .logo{
  height: 56px;
}

.site-header .nav{
  height: 56px;
}

.site-header .nav-link{
  height: 56px;
  padding: 0 10px;
  border-radius: 0; /* prevent toy-ish pills */
}

.site-header .nav-link:hover{
  background: transparent !important;
}

.site-header .nav-link::after{
  left: 10px;
  right: 10px;
  bottom: 0; /* exactly on divider */
  height: 2px;
  background: rgba(8, 24, 64, 0.95); /* deep navy */
}

.site-header .nav-ico{
  color: rgba(15,23,42,0.55);
}

.site-header .nav-link:hover .nav-ico{
  color: rgba(8, 24, 64, 0.80);
}

/* Profile trigger — smaller, tighter */
.profile-trigger{
  height: 36px;
  padding: 0 8px;
  border-radius: 10px;
}

.profile-trigger:hover{
  background: rgba(15,23,42,0.04);
}

.profile-ico svg{ width: 16px; height: 16px; }
.profile-caret svg{ width: 12px; height: 12px; }



/* Nav icon normalization (consistent with legacy set) */
.site-header .nav-link{
  gap: 8px;
}

.site-header .nav-ico{
  width: 16px;
  height: 16px;
  flex: 0 0 16px;
  display: inline-grid;
  place-items: center;
}

.site-header .nav-ico svg{
  width: 16px;
  height: 16px;
  display:block;
}

.site-header .nav-link span{
  line-height: 1;
}

/* Underline-only hover: ensure no background highlighting */
.site-header .nav-link:hover{
  background: transparent !important;
}


/* =========================
   BANKING DASHBOARD (REALTIME)
   ========================= */

.banking-page {
  padding: 18px 0 34px;
}

/* Top session card */
.banking-hero-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  width: 100%;
  box-sizing: border-box;
  padding: 16px 18px;
  background: var(--bg-elevated);
  border-radius: 18px;
  margin-bottom: 18px;
}

.banking-hero-card__title {
  font-size: 20px;
  font-weight: 600;
  letter-spacing: -0.015em;
  display: flex;
  gap: 6px;
  align-items: baseline;
}

.banking-hero-card__meta {
  margin-top: 6px;
  font-size: 13px;
}

.banking-welcome {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding: 6px 0 18px;
}

.banking-welcome__ico svg {
  width: 20px;
  height: 20px;
  color: var(--text-muted);
}

.banking-welcome__meta-ico svg {
  width: 16px;
  height: 16px;
  color: var(--text-muted);
}

.banking-welcome__title {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 22px;
  font-weight: 500;
  letter-spacing: -0.02em;
}

.banking-welcome__meta {
  margin-top: 6px;
  font-size: 13px;
  color: var(--text-muted);
}

.banking-session {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(37, 99, 235, 0.08);
  color: #1e3a8a;
  user-select: none;
}

.banking-session__ico svg {
  width: 18px;
  height: 18px;
  display: block;
  transform: translateY(1px);
}

.banking-session__text {
  font-size: 13px;
  font-weight: 500;
}

.banking-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
  align-items: stretch;
}

.banking-card--full {
  grid-column: 1 / -1;
}

.notify-list {
  margin-top: 8px;
  display: flex;
  flex-direction: column;
  gap: 0;
  border-top: 1px solid rgba(15, 23, 42, 0.08);
}

.notify-item {
  position: relative;
  display: flex;
  gap: 12px;
  padding: 12px 12px 12px 18px;
  background: transparent;
  border: 0;
  border-bottom: 1px solid rgba(15, 23, 42, 0.08);
}

.notify-item::before {
  content: "";
  position: absolute;
  left: 0;
  top: 10px;
  bottom: 10px;
  width: 2px;
  border-radius: 2px;
  background: rgba(15, 23, 42, 0.90); /* same tone as nav underline */
}


/* Notification severity accents (left underline) */
:root{
  --level-info: rgba(59, 130, 246, 0.95);
  --level-warning: rgba(245, 158, 11, 0.95);
  --level-danger: rgba(239, 68, 68, 0.95);
  --level-success: rgba(34, 197, 94, 0.95);
}

.notify-item--info::before { background: var(--level-info); }
.notify-item--warning::before { background: var(--level-warning); }
.notify-item--warn::before { background: var(--level-warning); } /* backward compat */
.notify-item--danger::before { background: var(--level-danger); }
.notify-item--error::before { background: var(--level-danger); } /* backward compat */
.notify-item--success::before { background: var(--level-success); }

.notify-item--info .notify-item__ico { color: var(--level-info); }
.notify-item--warning .notify-item__ico,
.notify-item--warn .notify-item__ico { color: var(--level-warning); }
.notify-item--danger .notify-item__ico,
.notify-item--error .notify-item__ico { color: var(--level-danger); }
.notify-item--success .notify-item__ico { color: var(--level-success); }

.notify-item:hover {
  background: rgba(15, 23, 42, 0.02);
}

.notify-item__ico {
  width: 18px;
  height: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border-radius: 0;
  flex: 0 0 auto;
  margin-top: 2px;
  color: rgba(15, 23, 42, 0.85);
}

.notify-item__ico svg {
  width: 18px;
  height: 18px;
}

.notify-item__title {
  font-weight: 700;
  font-size: 13px;
  margin-bottom: 2px;
  color: rgba(15, 23, 42, 0.92);
}

.notify-item__text {
  color: var(--text-muted);
  font-size: 13px;
  line-height: 1.45;
}

.notify-item__meta {
  margin-top: 6px;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  color: var(--text-muted);
  font-size: 12.5px;
}


/* My accounts: AML freeze banner (clean, minimal) */
.accounts-status{
  margin: 10px 0 8px;
}

.acc-alert{
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  /* No рамок/подложек: только компактная строка с левым severity-андерлайном */
  padding: 6px 0 6px 14px;
  border: 0;
  border-radius: 0;
  background: transparent;
}

.acc-alert::before{
  content: "";
  position: absolute;
  left: 0;
  top: 6px;
  bottom: 6px;
  width: 2px;
  border-radius: 2px;
  background: rgba(15, 23, 42, 0.90);
}

.acc-alert--danger{
  /* keep only left indicator + icon color */
}
.acc-alert--danger::before{ background: var(--level-danger); }
.acc-alert--danger .acc-alert__ico{ color: var(--level-danger); }

.acc-alert--success{
  /* success variant: keep only left indicator + icon color */
}
.acc-alert--success::before{ background: var(--level-success); }
.acc-alert--success .acc-alert__ico{ color: var(--level-success); }

.acc-alert__ico{
  width: 18px;
  height: 18px;
  display:flex;
  align-items:center;
  justify-content:center;
  flex: 0 0 auto;
}
.acc-alert__ico svg{ width: 18px; height: 18px; }

.acc-alert__text{
  font-size: 13px;
  color: rgba(15, 23, 42, 0.90);
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: baseline;
}
.acc-alert__title{ font-weight: 600; }
.acc-alert__link{
  color: rgba(15, 23, 42, 0.92);
  text-decoration: underline;
  text-underline-offset: 2px;
  font-weight: 600;
}
.acc-alert__link:hover{ opacity: 0.85; }
.acc-alert__pipe{ color: rgba(15, 23, 42, 0.45); }

.tx-list {
  margin-top: 6px;
  display: flex;
  flex-direction: column;
  gap: 0;
}

.tx-list--full {
  margin-top: 0;
}

.tx-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 2px;
  border-radius: 0;
  border: none;
  background: transparent;
  cursor: pointer;
  user-select: none;
}

.tx-item + .tx-item {
  border-top: 1px solid rgba(15, 23, 42, 0.08);
}

.tx-item:hover {
  background: rgba(15, 23, 42, 0.02);
}

.tx-item:active {
  background: rgba(15, 23, 42, 0.04);
}

.tx-left {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.tx-ico {
  width: 18px;
  height: 18px;
  border-radius: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  flex: 0 0 auto;
}

.tx-ico svg {
  width: 18px;
  height: 18px;
}

.tx-meta {
  min-width: 0;
}

.tx-title {
  font-weight: 600;
  font-size: 13px;
  white-space: normal;
  overflow: visible;
  text-overflow: clip;
  max-width: none;
}


.tx-empty {
  font-size: 13px;
  padding: 8px 0;
}
.tx-sub {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: 2px;
}

.tx-amount {
  font-weight: 600;
  letter-spacing: -0.01em;
  white-space: nowrap;
}

/* History: list rows should be regular weight (only headings are bold) */
body[data-page="history"] .tx-title,
body[data-page="history"] .tx-amount{
  font-weight: 400;
}

.tx-chev {
  width: 18px;
  height: 18px;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
}

.tx-chev svg {
  width: 18px;
  height: 18px;
}

.banking-card {
  height: 100%;
  display: flex;
  flex-direction: column;
  background: var(--bg-elevated);
  border-radius: 18px;
  padding: 18px 18px 16px;
  /* no borders, no shadows by design */
}

.banking-card__footer {
  margin-top: auto;
  padding-top: 10px;
}

.banking-card__body {
  flex: 1 1 auto;
  min-height: 0;
}

.banking-card__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
}

.banking-card--total .banking-card__head {
  align-items: center;
}

.banking-card__title {
  font-size: 16px;
  font-weight: 600;
}

.banking-card__amount {
  font-size: 22px;
  /* Keep numeric amounts consistent across browsers */
  font-weight: 600;
  letter-spacing: -0.02em;
}

.banking-card__amount--xl {
  font-size: 34px;
  font-weight: 700;
  letter-spacing: -0.03em;
}

.banking-card__divider {
  height: 1px;
  background: rgba(15, 23, 42, 0.08);
  margin: 6px 0 0;
}

.banking-updated {
  margin-top: 8px;
  font-size: 12.5px;
}

.banking-subtitle {
  margin-top: 14px;
  font-size: 12px;
  font-weight: 500;
  color: var(--text-muted);
  text-transform: none;
}

.structure-empty {
  margin-top: 8px;
}

.balance-structure {
  margin-top: 10px;
}

.structure-row {
  display: grid;
  /* Prevent iOS overflow: allow the middle track to shrink (minmax(0, 1fr)). */
  grid-template-columns: 140px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  padding: 6px 0;
}

.structure-row + .structure-row {
  margin-top: 2px;
}

.structure-row__left {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.dot {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  display: inline-block;
}

.dot--debit { background: var(--accent); }
.dot--savings { background: rgba(17, 24, 39, 0.35); }

.structure-label {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-main);
}

.bar {
  height: 8px;
  width: 100%;
  border-radius: 999px;
  background: rgba(17, 24, 39, 0.08);
  overflow: hidden;
}

.bar__fill {
  height: 100%;
  border-radius: 999px;
  background: var(--accent);
  width: 0%;
  transition: width 240ms ease;
}
.bar__fill--debit {
  background: var(--accent);
}

.bar__fill--savings {
  background: rgba(17, 24, 39, 0.35);
}


.structure-row__right {
  display: inline-flex;
  align-items: baseline;
  justify-content: flex-end;
  gap: 10px;
  text-align: right;
  min-width: 0;
}

.structure-amount {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-main);
}

.structure-percent {
  font-size: 12px;
  color: var(--text-muted);
}

.month-summary {
  margin-top: 10px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  padding: 12px;
  border-radius: 16px;
  background: rgba(17, 24, 39, 0.04);
}

.month-summary__item {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
  justify-content: center;
}

.month-summary__ico svg {
  width: 18px;
  height: 18px;
  color: var(--text-muted);
}

.month-summary__label {
  font-size: 12.5px;
  color: var(--text-muted);
  line-height: 1.1;
}

.month-summary__value {
  margin-top: 2px;
  font-size: 15px;
  /* Avoid non-existent 750 weight (Chrome renders it too bold) */
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--text-main);
}

.month-summary__meta {
  min-width: 0;
  text-align: center;
}

@media (max-width: 820px) {
  .month-summary {
    grid-template-columns: 1fr;
  }
}

.month-row {
  margin-top: 10px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.month-metric {
  background: rgba(17, 24, 39, 0.04);
  border-radius: 14px;
  padding: 10px 12px;
}

.month-metric__label {
  font-size: 12px;
  color: var(--text-muted);
}

.month-metric__value {
  margin-top: 6px;
  font-size: 13px;
  font-weight: 700;
}

.qa-row {
  margin-top: 10px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.qa-row--single {
  grid-template-columns: 1fr;
}

.qa-row--two {
  grid-template-columns: repeat(2, 1fr);
}

.qa-btn {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  gap: 10px;
  padding: 12px 12px;
  border-radius: 14px;
  background: rgba(17, 24, 39, 0.04);
  color: var(--text-main);
  border: 0;
  text-decoration: none;
  cursor: pointer;
  transition: background 160ms ease, transform 160ms ease;
}

.qa-btn:hover {
  background: rgba(37, 99, 235, 0.08);
  text-decoration: none;
  transform: translateY(-1px);
}

.qa-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}

.qa-btn__ico svg {
  width: 18px;
  height: 18px;
  color: var(--text-muted);
}

.qa-btn__label {
  font-size: 12.5px;
  /* Quick actions labels should not be bold */
  font-weight: 400;
  line-height: 1.1;
}

.accounts-list {
  margin-top: 12px;
  /* keep My accounts minimal: no inner grey container */
  padding: 0;
  border-radius: 0;
  background: transparent;
}

.account-row {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 12px 0;
  border-radius: 0;
  background: transparent;
}

.account-row + .account-row {
  margin-top: 0;
  border-top: 1px solid rgba(15, 23, 42, 0.06);
}

.account-row__left {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.account-row__ico svg {
  width: 18px;
  height: 18px;
  color: var(--text-muted);
}

.account-row__name {
  font-size: 14px;
  font-weight: 600;
}

.account-row__sub {
  margin-top: 2px;
  font-size: 12.5px;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 320px;
}

.account-row__right {
  font-size: 13px;
  font-weight: 600;
}

.account-row {
  cursor: pointer;
}

.account-row:hover {
  background: transparent;
}

.account-row__name {
  display: flex;
  align-items: center;
  gap: 8px;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 0;
  border-radius: 0;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.2;
  background: transparent;
  color: var(--text-muted);
}

.badge::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 999px;
  background: rgba(17, 24, 39, 0.30);
}

.badge--warn {
  color: rgba(146, 64, 14, 1);
}

.badge--warn::before {
  background: rgba(245, 158, 11, 0.85);
}

.badge--danger {
  color: rgba(153, 27, 27, 1);
}

.badge--danger::before {
  background: rgba(220, 38, 38, 0.90);
}

.badge--ok {
  color: rgba(22, 101, 52, 1);
}

.badge--ok::before {
  background: rgba(34, 197, 94, 0.90);
}

.badge--bad {
  color: rgba(153, 27, 27, 1);
}

.badge--bad::before {
  background: rgba(220, 38, 38, 0.90);
}

.badge--muted {
  color: var(--text-muted);
}

.badge--muted::before {
  background: rgba(17, 24, 39, 0.30);
}

/* Support: unread counter next to "Open" button (moderator) */
.btn-badge-wrap{
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.unread-pill{
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 18px;
  height: 18px;
  padding: 0 6px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 700;
  line-height: 1;
  background: rgba(245, 158, 11, 0.16);
  border: 1px solid rgba(245, 158, 11, 0.35);
  color: rgba(146, 64, 14, 1);
}

/* Profile: notifications box */
.notif-box{
  padding: 14px;
  border-radius: 16px;
  background: rgba(0,0,0,0.02);
  border: 1px solid rgba(0,0,0,0.06);
}
.notif-box__row{ display:flex; gap: 12px; align-items: center; }
.notif-box__ico{
  width: 40px;
  height: 40px;
  border-radius: 14px;
  background: rgba(0,0,0,0.04);
  border: 1px solid rgba(0,0,0,0.06);
  display: grid;
  place-items: center;
  color: var(--text-muted);
  flex: 0 0 auto;
}
.notif-box__text{ flex: 1; min-width: 0; display: grid; gap: 2px; }
.notif-box__title{ font-weight: 700; }
.notif-box__actions{ display:flex; gap: 10px; justify-content: flex-end; flex-wrap: wrap; margin-top: 12px; }

.iban-mono {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  letter-spacing: 0.2px;
}

/* IBAN in compact account rows must use the same corporate font (avoid browser fallbacks) */
.iban-full,
.iban-short{
  font-family: inherit;
  letter-spacing: 0;
}

.dot-sep {
  margin: 0 4px;
  color: var(--text-muted);
}

.icon-btn {
  appearance: none;
  border: 0;
  background: transparent;
  color: var(--text-muted);
  padding: 2px;
  border-radius: 8px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.icon-btn:hover {
  background: rgba(17, 24, 39, 0.06);
  color: var(--text);
}

.icon-btn--sm svg {
  width: 16px;
  height: 16px;
}

.icon-btn--ok {
  color: rgba(22, 163, 74, 1);
}

/* Modal (transaction details) */
.modal {
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: none;
}

.modal[aria-hidden="false"] {
  display: block;
}

.modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 23, 42, 0.35);
}

.modal__panel {
  position: relative;
  width: calc(100% - 24px);
  max-width: 720px;
  margin: 10vh auto;
  background: #fff;
  border-radius: 18px;
  border: 1px solid rgba(15, 23, 42, 0.10);
  box-shadow: 0 20px 60px rgba(15, 23, 42, 0.18);
  overflow: hidden;
}

/* Modal mobile fit */
@media (max-width: 760px){
  .modal__panel{
    margin: 12px auto;
    width: calc(100% - 16px);
    max-width: 100%;
    max-height: calc(100dvh - 24px - env(safe-area-inset-top) - env(safe-area-inset-bottom));
    display: flex;
    flex-direction: column;
  }
  .modal__body{
    overflow: auto;
    -webkit-overflow-scrolling: touch;
  }
  .modal__foot{
    padding-bottom: calc(14px + env(safe-area-inset-bottom));
  }
}


.modal__head {
  padding: 14px 16px;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  border-bottom: 1px solid rgba(15, 23, 42, 0.08);
}

.modal__title {
  font-size: 14px;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.modal__subtitle {
  margin-top: 3px;
  font-size: 12.5px;
}

.modal__body {
  padding: 14px 16px 16px;
}

.modal__foot{
  padding: 12px 16px 14px;
  display:flex;
  justify-content:flex-end;
  gap: 10px;
  border-top: 1px solid rgba(15, 23, 42, 0.08);
}
.modal__toast{
  padding: 0 16px;
  height: 0;
  overflow: hidden;
  opacity: 0;
  transition: opacity .18s ease, height .18s ease;
  color: rgba(15, 23, 42, 0.85);
  font-size: 12.5px;
}
.modal__toast[data-show="1"]{
  height: auto;
  opacity: 1;
  padding-top: 10px;
}
.modal__toast::before{
  content:"";
  display:block;
  width: 0;
  height: 0;
}

/* Banking transaction modal (new layout) */
.tx-modal-hero{
  display:flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 14px;
  padding-bottom: 12px;
  margin-bottom: 12px;
  border-bottom: 1px solid rgba(15, 23, 42, 0.08);
}
.tx-modal-hero__left{ min-width:0; }
.tx-modal-hero__badge{
  display:flex;
  align-items:center;
  gap: 8px;
  font-size: 12.5px;
  color: var(--text-muted);
}
.tx-modal-hero__ico{
  width: 18px;
  height: 18px;
  display:flex;
  align-items:center;
  justify-content:center;
  flex: 0 0 auto;
}
.tx-modal-hero__ico svg{ width:18px; height:18px; }
.tx-modal-hero__amount{
  margin-top: 6px;
  font-weight: 700;
  letter-spacing: -0.015em;
  font-size: 16px;
  white-space: nowrap;
}
.tx-modal-hero__meta{
  margin-top: 4px;
  font-size: 12.5px;
}
.tx-modal-hero__right{ min-width:0; text-align:right; }
.tx-modal-hero__title{
  font-weight: 700;
  font-size: 13.5px;
  letter-spacing: -0.01em;
}
.tx-modal-hero__sub{
  margin-top: 4px;
  font-size: 12.5px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 360px;
}
@media (max-width: 520px){
  .tx-modal-hero{ flex-direction: column; }
  .tx-modal-hero__right{ text-align:left; }
  .tx-modal-hero__sub{ max-width: 100%; }
}

.tx-modal-grid{
  display:grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px 14px;
}
.tx-field{
  border-top: 1px solid rgba(15, 23, 42, 0.08);
  padding-top: 10px;
}
.tx-field:nth-child(-n+2){ border-top: 0; padding-top: 0; }
.tx-field__k{
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 4px;
}
.tx-field__v{
  font-size: 12.8px;
  font-weight: 700;
  color: rgba(15, 23, 42, 0.92);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.tx-iban{
  color: var(--text-muted);
  font-weight: 600;
}
.tx-field__v--wrap{
  white-space: normal;
  overflow-wrap: anywhere;
}
.tx-field--full{
  grid-column: 1 / -1;
}
@media (max-width: 520px){
  .tx-modal-grid{ grid-template-columns: 1fr; }
}


/* Transaction details (history modal) */
.tx-modal-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 14px;
  padding-bottom: 12px;
  margin-bottom: 10px;
  border-bottom: 1px solid rgba(15, 23, 42, 0.08);
}

/* Transfer receipt card (Transfers → Result step) */
.transfer-receipt{
  padding: 14px;
}
.receipt-actions{
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 10px;
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid rgba(15, 23, 42, 0.08);
}
@media (max-width: 520px){
  .receipt-actions{
    flex-direction: column;
    align-items: stretch;
  }
  .receipt-actions .btn{
    width: 100%;
    justify-content: center;
  }
}

.tx-modal-top__left {
  min-width: 0;
}

.tx-modal-top__dir {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12.5px;
  color: var(--text-muted);
}

.tx-modal-top__ico {
  width: 18px;
  height: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
}

.tx-modal-top__ico svg {
  width: 18px;
  height: 18px;
}

.tx-modal-top__title {
  font-weight: 700;
  font-size: 13.5px;
  letter-spacing: -0.01em;
  margin-top: 4px;
  white-space: normal;
  overflow: visible;
}

.tx-modal-top__sub {
  font-size: 12.5px;
  margin-top: 3px;
}

.tx-modal-top__amount {
  font-weight: 700;
  letter-spacing: -0.015em;
  font-size: 14px;
  white-space: nowrap;
}

/* Key/Value grid for moderator/admin detail cards (avoid flex kv collision) */
.kv-grid {
  display: grid;
  grid-template-columns: 220px minmax(0, 1fr);
  column-gap: 16px;
  row-gap: 10px;
  padding-top: 6px;
}

.kv-grid__k {
  color: var(--text-muted);
  font-size: 12.5px;
  line-height: 1.35;
}

.kv-grid__v {
  font-size: 12.5px;
  font-weight: 700;
  text-align: left;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

@media (max-width: 720px) {
  .kv-grid {
    grid-template-columns: 1fr;
  }
  .kv-grid__v {
    margin-top: -6px;
  }
}

.kv {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 0;
  border-top: 1px solid rgba(15, 23, 42, 0.08);
}

.kv:first-child {
  border-top: 0;
  padding-top: 0;
}

.kv__k {
  color: var(--text-muted);
  font-size: 12.5px;
}

.kv__v {
  font-size: 12.5px;
  font-weight: 600;
  text-align: right;
  max-width: 440px;
  overflow: hidden;
  text-overflow: ellipsis;
}

.page-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  margin-bottom: 10px;
}

.page-head__actions {
  display: flex;
  gap: 8px;
  align-items: center;
}

.page-head__left{min-width:0;flex:1}
.page-head__right{display:flex;gap:10px;align-items:center;flex-wrap:wrap}
.page-actions .btn{white-space:nowrap}

/* Do not override the global .ui-title here.
   A second definition (block-level flex) makes the accent underline stretch
   and moves the right underline far away from the title text. */

.page-intro{margin:8px 0 0 0;max-width:820px;line-height:1.45}

/* Loans-style page header: title on top, then a second row where intro (left)
   starts on the same height as the action buttons (right). */
body:not(.bo) .page-titlebar{margin-bottom:0}
body:not(.bo) .page-titlebar .ui-title{margin:0}
body:not(.bo) .page-subhead{
  display:grid;
  grid-template-columns: minmax(0,1fr) auto;
  column-gap: 16px;
  row-gap: 8px;
  align-items:start;
  margin: 0 0 10px;
  padding-left: 16px;
  padding-right: 16px;
}
body:not(.bo) .page-titlebar{
  padding-left: 16px;
  padding-right: 16px;
}
body:not(.bo) .page-subhead .page-intro{
  margin:0;
  min-width:0;
  max-width:none;
  overflow-wrap:anywhere;
  padding-top: 6px;
}
body:not(.bo) .page-subhead .page-actions{
  display:flex;
  gap:10px;
  align-items:center;
  flex-wrap:wrap;
  justify-content:flex-end;
}
@media (max-width: 720px){
  body:not(.bo) .page-subhead{display:flex;flex-direction:column;align-items:flex-start}
  body:not(.bo) .page-subhead .page-actions{width:100%;justify-content:stretch}
  body:not(.bo) .page-subhead .page-actions .btn{width:100%;justify-content:center}
}


/* Align page actions with the intro line (Loans-style symmetry)
   Uses :has() (supported by modern Chromium). Falls back to the flex layout. */
@supports selector(.page-head:has(.page-intro)) {
  @media (min-width: 721px){
    body:not(.bo) .page-head:has(.page-intro){
      display:grid;
      grid-template-columns: 1fr auto;
      grid-template-areas:
        "title ."
        "intro actions";
      gap: 6px 16px;
      align-items:start;
    }
    body:not(.bo) .page-head:has(.page-intro) .page-head__left{display:contents}
    body:not(.bo) .page-head:has(.page-intro) .ui-title{grid-area:title}
    body:not(.bo) .page-head:has(.page-intro) .page-intro{grid-area:intro;margin:0}
    body:not(.bo) .page-head:has(.page-intro) .page-head__right{grid-area:actions;margin:0;align-self:start}
  }
}

/* Global compact hints (also for pages not using form-row/form-field wrappers) */
body:not(.bo) .hint,
body:not(.bo) .note,
body:not(.bo) .help{
  font-size:12.5px;
  line-height:1.35;
  margin-top:6px;
}

/* Compact field hints (like Loans) */
.form-row .muted.small,
.form-field .muted.small,
.form-row .hint,
.form-field .hint,
.form-row .note,
.form-field .note,
.form-row .help,
.form-field .help{
  font-size:12.5px;
  margin-top:6px;
  line-height:1.35;
}

/* Standard form rows: label right above its input (avoid “floating captions”). */
.form-row{
  display:flex;
  flex-direction:column;
  gap:6px;
  min-width:0;
}
.form-row .label{
  display:block;
  margin:0;
  font-size:12.5px;
  line-height:1.2;
  font-weight:600;
  color:var(--text-muted);
  letter-spacing:.15px;
}
.form-row .input{margin:0;}

/* Small section header used inside multi-part forms (e.g., SWIFT transfer details). */
.form-subtitle{
  margin-top:12px;
  margin-bottom:6px;
  font-size:12px;
  line-height:1.2;
  font-weight:600;
  letter-spacing:.25px;
  text-transform:uppercase;
  color:var(--text-muted);
}
.form-subtitle:first-child{margin-top:0;}

@media (max-width: 720px){
  .page-head{flex-direction:column;align-items:flex-start}
  .page-head__right{width:100%}
  .page-actions{gap:8px}
  .page-actions .btn{width:100%;justify-content:center}
}


.account-row__right {
  text-align: right;
  min-width: 140px;
}

.account-row__amount {
  font-size: 14px;
  /* Amounts should not look overly bold (Chrome vs Edge consistency) */
  font-weight: 600;
  letter-spacing: 0.1px;
}

.account-row__meta2 {
  margin-top: 2px;
  font-size: 12.5px;
  display: flex;
  justify-content: space-between;
  gap: 10px;
}

.account-row__chev svg {
  width: 18px;
  height: 18px;
  color: rgba(17, 24, 39, 0.35);
}

.account-row__chev {
  display: flex;
  align-items: center;
}

.account-row__main {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 0;
  border-radius: 0;
}

.account-row:hover .account-row__main {
  background: transparent;
}

.account-row__details {
  display: none;
  padding-top: 8px;
  border-top: 1px solid rgba(15, 23, 42, 0.06);
  margin-top: 4px;
}

.account-row--open {
  background: transparent;
}

.account-row--open .account-row__main {
  background: transparent;
}

.account-row--open .account-row__details {
  display: block;
}

.account-row--open .account-row__chev svg {
  transform: rotate(90deg);
}

.account-details-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 8px 16px;
  font-size: 12px;
}

.account-detail__label {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-muted);
  margin-bottom: 2px;
}

.account-detail__value {
  font-weight: 500;
}

.account-detail--full {
  grid-column: 1 / -1;
}

.banking-note {
  margin-top: 10px;
  font-size: 12px;
  color: var(--text-muted);
}

@media (max-width: 880px) {
  .banking-grid {
    grid-template-columns: 1fr;
  }
  .structure-row {
    grid-template-columns: 120px 1fr 120px;
  }
}

@media (max-width: 520px) {
  .qa-row {
    grid-template-columns: 1fr;
  }
  .month-row {
    grid-template-columns: 1fr;
  }
  .structure-row {
    grid-template-columns: 1fr;
    gap: 8px;
  }
  .structure-row__right {
    justify-content: flex-start;
  }
}


/* Transfers */
.transfer-shell {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}

.transfer-card {
  padding: 16px;
}

.transfer-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 12px;
}

.transfer-title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
}

.transfer-title__ico svg {
  width: 18px;
  height: 18px;
  color: var(--text-muted);
}

.transfer-subtitle {
  margin-top: 2px;
}

.stepper {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 8px;
  padding: 10px;
  border-radius: 14px;
  background: rgba(17, 24, 39, 0.02);
  margin-bottom: 12px;
}

.step {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  border-radius: 12px;
  color: var(--text-muted);
  user-select: none;
}

.step__dot {
  width: 22px;
  height: 22px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: rgba(17, 24, 39, 0.06);
  font-size: 12px;
  font-weight: 700;
}

.step--active {
  background: rgba(17, 24, 39, 0.06);
  color: var(--text);
}

.step--active .step__dot {
  background: rgba(17, 24, 39, 0.12);
}

.step--done {
  color: rgba(22, 163, 74, 1);
}

.step--done .step__dot {
  background: rgba(22, 163, 74, 0.10);
}

.step-panel {
  display: none;
}

.step-panel.is-active {
  display: block;
}

.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

/* Transfers: add breathing room between consecutive field groups on desktop and mobile.
   Prevents label/help text from visually "sticking" to the next block. */
.transfer-body .form-row + .grid-2,
.transfer-body .grid-2 + .grid-2,
.transfer-body .grid-2 + .check-row,
.transfer-body .check-row + .grid-2 {
  margin-top: 12px;
}

.transfer-body .help {
  margin-top: 6px;
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

.form-row .small {
  margin-top: 6px;
}

.choice-card {
  width: 100%;
  border: 1px solid rgba(17, 24, 39, 0.08);
  background: #fff;
  padding: 14px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  text-align: left;
  cursor: pointer;
}

.choice-card:hover {
  border-color: rgba(17, 24, 39, 0.18);
  background: rgba(17, 24, 39, 0.01);
}

.choice-card__ico svg {
  width: 20px;
  height: 20px;
  color: var(--text-muted);
}

.choice-card__text {
  flex: 1;
  min-width: 0;
}

.choice-card__title {
  font-weight: 700;
}

.choice-card__desc {
  margin-top: 4px;
  font-size: 12px;
}

.choice-card__chev svg {
  width: 18px;
  height: 18px;
  color: rgba(17, 24, 39, 0.35);
}

.hint-row {
  margin-top: 12px;
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(17, 24, 39, 0.02);
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.hint-row__ico svg {
  width: 18px;
  height: 18px;
  color: var(--text-muted);
  margin-top: 0;
}

.check-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 10px;
  font-size: 13px;
}

.error-box {
  margin-top: 12px;
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(220, 38, 38, 0.08);
  color: rgba(153, 27, 27, 1);
  font-size: 13px;
  font-weight: 600;
}

.review-card {
  border: 1px solid rgba(17, 24, 39, 0.08);
  border-radius: 16px;
  padding: 14px;
}

.review-card__title {
  font-weight: 700;
  margin-bottom: 10px;
}

.review-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.review-item {
  padding: 10px 12px;
  border-radius: 14px;
  background: rgba(17, 24, 39, 0.02);
}

.result-box {
  border: 1px solid rgba(17, 24, 39, 0.08);
  border-radius: 16px;
  padding: 14px;
  background: rgba(22, 163, 74, 0.06);
}

.result-box__title {
  font-weight: 700;
}

.result-box__meta {
  margin-top: 6px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  font-size: 12px;
}

.transfer-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid rgba(17, 24, 39, 0.08);
}

.transfer-footer__right {
  display: flex;
  align-items: center;
  gap: 10px;
}

.transfer-list {
  display: grid;
  gap: 10px;
}

.transfer-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding: 12px;
  border-radius: 16px;
  background: rgba(17, 24, 39, 0.02);
}

.transfer-row__title {
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.transfer-row__meta {
  margin-top: 4px;
  font-size: 12px;
}

.transfer-row__right {
  text-align: right;
  min-width: 160px;
  display: grid;
  justify-items: end;
  gap: 6px;
}

.transfer-row__amount {
  font-weight: 600;
}

.btn-sm {
  padding: 8px 10px;
  border-radius: 12px;
  font-size: 12.5px;
}

@media (max-width: 860px) {
  .stepper {
    grid-template-columns: 1fr;
  }
  .grid-2 {
    grid-template-columns: 1fr;
  }
  .review-grid {
    grid-template-columns: 1fr;
  }
  .transfer-row {
    flex-direction: column;
    align-items: stretch;
  }
  .transfer-row__right {
    text-align: left;
    min-width: 0;
    justify-items: start;
  }
}
/* Back-office mini summary blocks */
.mini {
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 12px;
  background: #ffffff;
}
.mini-k {
  color: var(--text-muted);
  font-size: 12px;
  margin-bottom: 6px;
}
.mini-v {
  font-weight: 700;
  font-size: 14px;
}


/* Neutral bank colors for amounts */
.tx-amount--in {
  color: rgba(21, 128, 61, 0.90);
}
.tx-amount--out {
  color: rgba(185, 28, 28, 0.92);
}
.money-in {
  color: rgba(21, 128, 61, 0.90) !important;
}
.money-out {
  color: rgba(185, 28, 28, 0.92) !important;
}

/* --- Support chat (Telegram-like, neutral) --- */
.support-head{display:flex;align-items:center;gap:12px;margin:6px 0 16px}
.support-head-meta{display:flex;flex-direction:column;gap:2px}

.chat{
  border: 1px solid rgba(0,0,0,0.06);
  border-radius: 14px;
  background: var(--bg-elevated);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.chat-messages{
  max-height: 520px;
  overflow: auto;
  visibility: visible;
  padding: 12px 12px 16px;
  background: linear-gradient(180deg, rgba(245,245,247,0.72), rgba(245,245,247,0.92));
}

/* Footer / composer */
.chat-footer{padding:10px 12px 12px;border-top:1px solid rgba(0,0,0,0.06);background:#fff}
.chat-compose{
  display:flex;
  flex-direction:column;
  border:1px solid rgba(0,0,0,0.10);
  border-radius:14px;
  background:#fff;
  overflow:hidden;
}
.chat-compose:focus-within{border-color:rgba(0,0,0,0.14); box-shadow:none}

.chat-compose__field{padding:10px 12px}
.chat-compose__bar{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  padding:10px 12px;
  border-top:1px solid rgba(0,0,0,0.08);
}
.chat-compose__left{display:flex;align-items:center;gap:10px}
.chat-compose__right{display:flex;align-items:center;gap:10px}

.chat-action,
.chat-send{
  width:42px;
  height:42px;
  border-radius:12px;
  border:1px solid rgba(0,0,0,0.10);
  background:#fff;
  display:grid;
  place-items:center;
  cursor:pointer;
}
.chat-action svg,
.chat-send svg{width:20px;height:20px}
.chat-action[disabled],
.chat-send[disabled]{opacity:.55; cursor:not-allowed}

.chat-send{background: var(--accent); border-color: var(--accent); color:#fff}
.chat-send:hover{filter: brightness(0.98)}

/* Attach icon (no pill) */
.chat-action{
  width:32px;
  height:32px;
  border:none;
  background:transparent;
  border-radius:10px;
}
.chat-action:hover{background:rgba(0,0,0,0.04)}
.chat-action svg{width:18px;height:18px}

.chat-input{
  width:100%;
  min-height:44px;
  max-height:140px;
  padding:0;
  border:none;
  outline:none;
  background:transparent;
  resize:none;
  box-sizing:border-box;
  overflow-y:hidden;
}
.chat-file{display:none}
.chat-hint{font-size:12px;color:var(--text-muted);margin-top:8px}

/* Composer v2 (no inner highlight, actions below the frame) */
.chat-compose{border:none;background:transparent;overflow:visible}
.chat-compose__box{
  border:1px solid rgba(0,0,0,0.10);
  border-radius:14px;
  background: linear-gradient(180deg, rgba(245,245,247,0.85), rgba(245,245,247,0.95));
  padding:12px;
}
.chat-compose__box:focus-within{border-color:rgba(0,0,0,0.14)}

.chat-input{
  margin-top:0;
  border-radius:0;
}
.chat-input:focus{
  box-shadow:none !important;
  background:transparent !important;
}

.chat-compose__actions{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:12px;
  margin-top:10px;
}

/* Attach icon: bare */
.chat-action{
  width:30px;
  height:30px;
  border:none;
  background:transparent;
  border-radius:10px;
}
.chat-action:hover{background:rgba(0,0,0,0.04)}
.chat-action svg{width:18px;height:18px}

/* Send button: smaller but keeps current accent */
.chat-send{
  width:40px;
  height:40px;
  border-radius:12px;
}

/* Modal (used for moderator send confirmation) */
.ui-modal-backdrop{
  position:fixed;
  inset:0;
  background:rgba(2,6,23,0.45);
  display:flex;
  align-items:center;
  justify-content:center;
  padding:16px;
  z-index:9999;
}
.ui-modal{
  width:min(420px, 92vw);
  background:#fff;
  border:1px solid rgba(0,0,0,0.10);
  border-radius:16px;
  box-shadow:0 20px 60px rgba(0,0,0,0.25);
  padding:16px;
}
.ui-modal-title{font-weight:700;font-size:14px;margin:0 0 8px}
.ui-modal-text{font-size:13px;line-height:1.35;margin:0 0 14px;color:var(--text)}
.ui-modal-actions{display:flex;justify-content:flex-end;gap:10px}


.msg{max-width:74%;padding:6px 8px;border-radius:12px;margin:4px 0;box-shadow:none}
.msg-meta{display:flex;justify-content:space-between;gap:10px;font-size:10px;color:var(--text-muted);margin-bottom:2px}
.msg-body{white-space:pre-line;word-break:break-word;line-height:1.25;font-size:13px}

.msg-client{margin-left:auto;background:#fff}
.msg-operator{margin-right:auto;background:rgba(2,6,23,0.06)}

.msg-system{max-width:100%;margin:10px 0;padding:0;background:transparent;box-shadow:none}
.msg-system .msg-body{background:transparent;border:none;border-radius:0;padding:0}
.msg-system-html{font-size:13px;line-height:1.45}

.msg-image{display:block;max-width:100%;border-radius:12px;border:1px solid rgba(17,24,39,0.10)}
.msg-file{display:inline-flex;align-items:baseline;gap:8px;padding:8px 10px;border-radius:12px;border:1px dashed rgba(17,24,39,0.18);background:#fff}


/* --- Support: System note composer --- */
.grid2{display:grid;grid-template-columns:1fr 1fr;gap:16px}
@media (max-width: 900px){.grid2{grid-template-columns:1fr}}
.sysnote-toolbar{display:flex;gap:8px;flex-wrap:wrap;align-items:center}
.sysnote-editor{
  border:1px solid rgba(0,0,0,.12);
  border-radius:12px;
  padding:10px 12px;
  min-height:90px;
  outline:none;
  background:#fff;
}
.sysnote-editor[data-disabled="1"]{opacity:.6;pointer-events:none}
.sysnote-preview{margin-top:8px}
.sys-note{
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 0 6px 14px;
  border: 0;
  border-radius: 0;
  background: transparent;
}
.sys-note:before{
  content:"";
  position:absolute;
  left:0;
  top:6px;
  bottom:6px;
  width:2px;
  border-radius:2px;
  background: rgba(2,6,23,.55);
}
.sys-note .sys-ico{
  width:18px;
  height:18px;
  display:flex;
  align-items:center;
  justify-content:center;
  flex:0 0 auto;
  margin:0;
  opacity:1;
  color: rgba(15, 23, 42, 0.85);
}
.sys-note .sys-ico svg{width:18px;height:18px}
.sys-note .sys-title{
  font-weight:700;
  font-size:13px;
  margin:0;
  color: rgba(15, 23, 42, 0.92);
}
.sys-note .sys-title--notice{
  /* Notice title should look like a proper site heading (double underline left/right) */
  margin: 0;
  padding-bottom: 8px;
  font-size: 14px;
  /* override typography lock (client app) */
  font-weight: 600 !important;
}
.sys-note .sys-title--notice.ui-title::before{ bottom: 1px; }
.sys-note .sys-title--notice.ui-title::after{ bottom: 1px; }
.sys-note .sys-text{
  font-size:13px;
  line-height:1.35;
  color: var(--text-muted);
  margin-top: 6px;
  overflow-wrap: anywhere;
  word-break: break-word;
}

/* Normalize HTML spacing inside system notice bodies (avoid huge default margins) */
.sys-note .sys-text p{ margin: 0 0 10px; }
.sys-note .sys-text p:last-child{ margin-bottom: 0; }
.sys-note .sys-text ul{ margin: 0 0 10px; padding-left: 18px; }
.sys-note .sys-text ul:last-child{ margin-bottom: 0; }
.sys-note .sys-text li{ margin: 6px 0; }


/* Notice underline colors per theme */
.sys-theme-info .sys-title--notice.ui-title::before{ background: rgba(2, 6, 23, 0.65); }
.sys-theme-info .sys-title--notice.ui-title::after{ background: rgba(2, 6, 23, 0.28); }
.sys-theme-success .sys-title--notice.ui-title::before{ background: rgba(22, 163, 74, 0.75); }
.sys-theme-success .sys-title--notice.ui-title::after{ background: rgba(22, 163, 74, 0.28); }
.sys-theme-warn .sys-title--notice.ui-title::before{ background: rgba(217, 119, 6, 0.85); }
.sys-theme-warn .sys-title--notice.ui-title::after{ background: rgba(217, 119, 6, 0.28); }
.sys-theme-danger .sys-title--notice.ui-title::before{ background: rgba(220, 38, 38, 0.75); }
.sys-theme-danger .sys-title--notice.ui-title::after{ background: rgba(220, 38, 38, 0.28); }
.sys-theme-info:before{ background: rgba(2,6,23,.55)}
.sys-theme-success:before{ background: rgba(22,163,74,.65)}
.sys-theme-warn:before{ background: rgba(217,119,6,.75)}
.sys-theme-danger:before{ background: rgba(220,38,38,.65)}
.sys-theme-info .sys-ico{ color: rgba(2,6,23,.75)}
.sys-theme-success .sys-ico{ color: rgba(22,163,74,.75)}
.sys-theme-warn .sys-ico{ color: rgba(217,119,6,.85)}
.sys-theme-danger .sys-ico{ color: rgba(220,38,38,.75)}

.sys-toast{
  margin-top: 10px;
  padding: 10px 12px;
  border: 1px solid rgba(0,0,0,0.08);
  background: rgba(22,163,74,0.08);
  color: rgba(22,163,74,0.95);
  border-radius: 12px;
  font-size: 13px;
  font-weight: 600;
}
.sys-toast.is-error{
  background: rgba(220,38,38,0.08);
  color: rgba(220,38,38,0.95);
}

/* System notice composer */
.sysnote-row{display:flex;gap:10px;align-items:center;flex-wrap:wrap;margin:8px 0}
.sysnote-label{font-size:12px;opacity:.75;margin-right:6px}
.sysnote-themes{display:flex;gap:6px;align-items:center}
.sysnote-theme-btn{
  border:1px solid rgba(0,0,0,.12);
  background:#fff;
  border-radius:999px;
  padding:5px 10px;
  font-size:12px;
  cursor:pointer;
}
.sysnote-theme-btn.is-active{outline:2px solid rgba(0,0,0,.12)}
.sysnote-icons{display:flex;gap:6px;align-items:center;flex-wrap:wrap}
.sysnote-icon-btn{
  width:34px;height:34px;
  border:1px solid rgba(0,0,0,.12);
  background:#fff;
  border-radius:10px;
  display:flex;align-items:center;justify-content:center;
  cursor:pointer;
}
.sysnote-icon-btn svg{width:18px;height:18px}
.sysnote-icon-btn.is-active{outline:2px solid rgba(0,0,0,.12)}
.sysnote-editor{
  border:1px solid rgba(0,0,0,.12);
  border-radius:12px;
  padding:10px;
  min-height:88px;
  background:#fff;
}
.sysnote-preview{margin-top:10px}
.chat-error{
  font-size:12px;
  margin-top:6px;
  opacity:.85;
}

/* ===== S-BANK footer (admin-managed) ===== */
.main-footer {
  background: #020617;
  color: #e5e7eb;
  margin-top: auto;
}

.footer-top {
  padding: 22px 0;
  border-top: 1px solid rgba(148,163,184,0.16);
}

.footer-inner {
  display: grid;
  grid-template-columns: minmax(0, 2fr) repeat(3, minmax(0, 1fr));
  gap: 18px;
  align-items: flex-start;
}

@media (max-width: 980px) {
  .footer-inner {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 560px) {
  .footer-inner {
    grid-template-columns: 1fr;
  }
}

.footer-block h4 {
  margin: 0 0 10px;
  font-size: 13px;
  font-weight: 500;
  color: #e5e7eb;
  letter-spacing: 0.2px;
}

.footer-brand-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}

.footer-logo-img {
  height: 34px;
  width: auto;
  max-width: 160px;
  object-fit: contain;
  border-radius: 0;
  background: transparent;
  padding: 0;
  box-shadow: none;
}


.footer-bankname {
  font-weight: 700;
  font-size: 15px;
  line-height: 1.1;
}

.footer-tagline {
  font-size: 12px;
  color: #cbd5e1;
  margin-top: 2px;
}

.footer-desc {
  margin: 0;
  font-size: 12.5px;
  color: #cbd5e1;
  line-height: 1.5;
}

.footer-meta {
  margin-top: 10px;
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: #94a3b8;
}

.footer-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.footer-item {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #e5e7eb;
  text-decoration: none;
  font-size: 13px;
}

.footer-item:hover { opacity: 0.9; }

.footer-item--muted {
  color: #cbd5e1;
}

.footer-ico {
  width: 18px;
  height: 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #94a3b8;
}

.footer-ico svg { width: 18px; height: 18px; display: block; }

.footer-messengers {
  margin-top: 12px;
  display: flex;
  gap: 10px;
  align-items: center;
}

.footer-msg {
  width: 34px;
  height: 34px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  color: #e5e7eb;
  background: rgba(148,163,184,0.12);
  border: 1px solid rgba(148,163,184,0.18);
}

.footer-msg:hover { background: rgba(148,163,184,0.18); }

.footer-msg-ico svg { width: 18px; height: 18px; display: block; }

.footer-links {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.footer-links a {
  color: #cbd5e1;
  text-decoration: none;
  font-size: 13px;
}

.footer-links a:hover { color: #e5e7eb; }

.footer-bottom {
  border-top: 1px solid rgba(148,163,184,0.14);
  padding: 14px 0;
}

.footer-bottom-inner {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  justify-content: space-between;
}

/* Footer now uses the shared .container gutters (same as cards/header). */

@media (max-width: 780px) {
  .footer-bottom-inner {
    flex-direction: column;
  }
}

.footer-legal {
  color: #94a3b8;
  font-size: 12px;
  line-height: 1.4;
  white-space: pre-line;
  max-width: 760px;
}

.footer-legal-inline {
  margin-top: 12px;
}

.footer-copy {
  font-size: 12px;
  color: #94a3b8;
  white-space: nowrap;
}



/* =========================
   Mobile responsive overrides
   ========================= */
.nav-toggle{
  display:none;
  align-items:center;
  justify-content:center;
  width: 44px;
  height: 44px;
  border: 0;
  background: transparent;
  color: rgba(15,23,42,0.85);
  cursor: pointer;
}

.nav-toggle:hover{ background: rgba(255,255,255,0.92); }
.nav-toggle-ico svg{ width: 20px; height: 20px; }

.table-scroll{
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  border-radius: 14px;
}
.table-scroll table{
  min-width: 720px;
}

/* Prevent rare horizontal overflows on mobile (long refs/emails/notes) */
.card, .banking-card, .loan-panel{ max-width:100%; }
.table td, .table th{ overflow-wrap:anywhere; word-break:break-word; }
body:not(.bo) .page-titlebar, body:not(.bo) .page-subhead{ max-width:100%; }
body:not(.bo) .page-subhead .page-actions{ min-width:0; }

@media (max-width: 980px){
  .container{
    padding-left: calc(16px + env(safe-area-inset-left));
    padding-right: calc(16px + env(safe-area-inset-right));
  }
  .feature-grid{ grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hero-main{ grid-template-columns: 1fr; gap: 16px; }
  .hero-actions{ flex-wrap: wrap; }
  .bo-topbar{ position: sticky; top: 0; z-index: 20; }
}

/* iPhone: keep tighter, symmetrical gutters (avoids the "Total balance shifted right" impression) */
@media (max-width: 720px){
  .container{
    padding-left: calc(12px + env(safe-area-inset-left));
    padding-right: calc(12px + env(safe-area-inset-right));
  }
  .footer-inner{
    padding-left: calc(12px + env(safe-area-inset-left));
    padding-right: calc(12px + env(safe-area-inset-right));
  }
}


.nav-scrim{
  display:none;
}
@media (max-width: 860px){
  .nav-scrim{
    position: fixed;
    inset: 0;
    background: rgba(2, 6, 23, 0.35);
    backdrop-filter: blur(2px);
    display: none;
    z-index: 25;
  }
  html.nav-open .nav-scrim{ display:block; }
}

@media (max-width: 860px){
  .header-inner{ gap: 10px; }

  /* Header: prevent weird scrollbars */
  .site-header, .header-inner, .header-actions{ overflow: visible; }
  .header-actions > *{ overflow: visible; }
  .nav-toggle{ display:inline-flex; }

  /* Make header actions more compact */
  .header-actions{ gap: 6px; }
  .user-label{ display:none; }

  /* Off-canvas nav */
    .nav-toggle{ display:inline-flex; border:0; background: transparent; box-shadow:none; padding: 8px; border-radius: 10px; }
  .nav-toggle:active{ background: rgba(15,23,42,0.06); }
  .nav-toggle-ico svg{ width: 22px; height: 22px; }

  .nav{
    position: fixed;
    inset: 0 auto 0 0;
    width: min(86vw, 320px);
    padding: calc(14px + env(safe-area-inset-top)) 12px 14px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    background: rgba(245,245,247,0.98);
    backdrop-filter: blur(14px);
    border-right: 1px solid rgba(15,23,42,0.10);
    transform: translateX(-120%);
    pointer-events: none;
    transition: transform 180ms ease;
    max-height: 100vh;
    overflow: hidden;
    visibility: hidden;
    z-index: 30;
  }
  .site-header .nav{ height:auto; overflow: visible; justify-content:flex-start; }
  html.nav-open .nav{ transform: translateX(0); pointer-events: auto; overflow: auto; visibility: visible; }
.nav-link{ width:100%; justify-content:flex-start; padding: 12px 12px; }
  .nav-ico{ width: 18px; height: 18px; }
}

  .nav-link{
    width: 100%;
    justify-content: flex-start;
    padding: 12px 12px;
  }
  .nav-ico{ width: 18px; height: 18px; }
}

@media (max-width: 720px){
  .container{
    padding-left: calc(14px + env(safe-area-inset-left));
    padding-right: calc(14px + env(safe-area-inset-right));
  }
  h1{ font-size: 20px; }
  .hero{ padding: 18px 0 22px; }

  .feature-grid{ grid-template-columns: 1fr; }
  .field-row{ grid-template-columns: 1fr !important; }
  .banking-grid{ grid-template-columns: 1fr; }
  .banking-card--full{ grid-column: auto; }
  .accounts-grid{ grid-template-columns: 1fr; }
  .transfers-grid{ grid-template-columns: 1fr; }

  /* Footer: stack columns */
  .footer-inner{ grid-template-columns: 1fr; gap: 18px; }
  .footer-bottom-inner{ flex-direction: column; align-items: flex-start; gap: 8px; }

  /* Auth forms */
  .auth-card{ padding: 16px; }
  .btn{ width: 100%; justify-content: center; }
  .btn.ghost{ width: 100%; }
  .hero-actions .btn{ width: auto; }
  .hero-actions{ gap: 10px; }

  /* Tables become scrollable */
  .table-scroll table{ min-width: 680px; }

  /* Backoffice off-canvas */
  .bo-shell{ grid-template-columns: 1fr; }
  .bo-sidebar{
    position: fixed;
    inset: 0 auto 0 0;
    width: min(86vw, 300px);
    transform: translateX(-120%);
    pointer-events: none;
    transition: transform 180ms ease;
    z-index: 50;
  }
  html.bo-open .bo-sidebar{ transform: translateX(0); }
  .bo-scrim{
    display:none;
    position: fixed;
    inset: 0;
    background: rgba(2,6,23,0.50);
    z-index: 40;
  }
  html.bo-open .bo-scrim{ display:block; }
  .bo-menu-btn{
    display:inline-flex;
    align-items:center;
    justify-content:center;
    width: 44px;
    height: 44px;
    border-radius: 12px;
    border: 1px solid rgba(15,23,42,0.10);
    background: rgba(255,255,255,0.85);
    margin-right: 10px;
    cursor: pointer;
  }
  .bo-menu-btn svg{ width: 20px; height: 20px; }
  .bo-topbar{
    padding-left: 12px;
    padding-right: 12px;
    gap: 10px;
  }
  .bo-user{ display:none; }
  .bo-content{ padding: 14px 12px; }
}

@media (max-width: 520px){
  .logo{ font-size: 15px; }
  .nav{ top: 60px; max-height: calc(100vh - 60px); }
  .header-inner{ padding: 12px 0; }
  .hero-actions .btn{ width: 100%; }
  .hero-actions{ flex-direction: column; align-items: stretch; }
  .table-scroll table{ min-width: 620px; }
}



/* Extra mobile polish for public pages */
@media (max-width: 860px){
  .container{
    padding-left: calc(14px + env(safe-area-inset-left));
    padding-right: calc(14px + env(safe-area-inset-right));
  }
  .page-content{ padding: 18px 0 28px; }
  .logo{ font-size: 16px; }

  .banking-hero-card{
    flex-direction: column;
    align-items: flex-start;
  }
  .banking-session{
    width: 100%;
    justify-content: flex-start;
  }
  .banking-card__head{
    flex-direction: column;
    align-items: flex-start;
  }
  .banking-card__amount--xl{
    font-size: 28px;
  }
  .structure-row{
    grid-template-columns: 1fr;
    gap: 6px;
    padding: 8px 0;
  }
  .structure-row__right{ justify-content: flex-start; }
  .month-summary{
    grid-template-columns: 1fr;
    justify-items: stretch;
  }
  .month-summary__item{ justify-content: flex-start; }
}


/* =========================================================
   Public mobile upgrade v2 (excluding admin/moderator)
   ========================================================= */

@media (max-width: 720px){
  body:not(.bo){
    font-size: 14px;
    background: #f5f7fb;
  }

  body:not(.bo) main.site-main{
    padding-top: 14px;
    padding-bottom: 18px;
  }

  body:not(.bo) h1{ font-size: 20px; line-height: 1.25; margin-bottom: 8px; }
  body:not(.bo) h2{ font-size: 16px; line-height: 1.25; }
  body:not(.bo) .page-intro{ font-size: 13.5px; line-height: 1.45; }

  body:not(.bo) .card,
  body:not(.bo) .banking-card{
    border-radius: 18px;
  }

  body:not(.bo) .banking-grid{
    grid-template-columns: 1fr !important;
    gap: 12px !important;
  }

  body:not(.bo) .banking-card__head{
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }

  body:not(.bo) .banking-balance{
    width: 100%;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
  }

  body:not(.bo) .banking-balance__value{
    font-size: 30px;
    line-height: 1.1;
  }

  /* Quick actions -> 2x2 grid */
  body:not(.bo) .qa-row{
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }
  body:not(.bo) .qa-row.qa-row--single{
    grid-template-columns: 1fr;
  }
  body:not(.bo) .qa-btn{
    min-height: 48px;
    justify-content: flex-start;
  }

  /* Month summary */
  body:not(.bo) .month-summary{
    grid-template-columns: 1fr;
    gap: 10px;
  }
}

/* Accounts: mobile cards */
.accounts-cards{ display: none; }
@media (max-width: 720px){
  .accounts-table-wrap{ display: none; }
  .accounts-cards{
    display: grid;
    gap: 10px;
  }
}
.account-card{
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 12px;
  box-shadow: 0 10px 26px rgba(0,0,0,0.06);
}
.account-card__row{
  display:flex;
  align-items:center;
  justify-content: space-between;
  gap: 12px;
}
.account-card__left{ min-width: 0; }
.account-card__name{
  font-weight: 700;
  font-size: 14.5px;
  margin-bottom: 4px;
}
.account-card__sub{
  font-size: 12.5px;
  color: rgba(15,23,42,0.65);
}
.account-card__bal{
  font-weight: 700;
  font-size: 15px;
  white-space: nowrap;
}

/* Support: ticket cards (used as the primary list on all viewports) */
.tickets-cards{
  display: grid;
  gap: 10px;
  margin-bottom: 10px;
}
.ticket-card{
  display:block;
  text-decoration:none;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 12px;
  box-shadow: 0 10px 26px rgba(0,0,0,0.06);
  color: inherit;
}
.ticket-card:hover{ border-color: rgba(15,23,42,0.18); }
.ticket-card:hover{ text-decoration: none !important; }
.ticket-card:focus-visible{ outline: none; box-shadow: 0 0 0 3px rgba(2, 6, 23, 0.12); }
.ticket-card__top{
  display:flex;
  align-items:center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 8px;
}
.ticket-card__title{
  font-weight: 700;
  font-size: 14.5px;
  line-height: 1.2;
}
.ticket-card__meta{
  display:flex;
  flex-direction: column;
  gap: 4px;
  font-size: 12.5px;
  color: rgba(15,23,42,0.7);
}
.ticket-card__meta-item{ display:block; }

.ticket-card__actions{
  margin-top: 10px;
  display:flex;
  justify-content:flex-end;
}

.support-table{ margin-top: 0; }
.tickets-cards--mobile{ display: none; }

@media (max-width: 720px){
  .support-table-wrap{ display: none; }
  .tickets-cards--mobile{ display: grid; }
  .ticket-card__actions .btn{ width: 100%; justify-content: center; }
}

/* History list: tighter mobile layout */
@media (max-width: 720px){
  .tx-item{
    padding: 12px;
    gap: 10px;
  }
  .tx-left{
    min-width: 0;
  }
  .tx-title{
    font-size: 14px;
  }
  .tx-sub{
    font-size: 12.5px;
  }
  .tx-amount{
    font-size: 14px;
  }
}

/* History page: use the same transaction table look as Banking */
body[data-page="history"] .tx-table-head{
  display: grid;
  grid-template-columns: 34px 140px minmax(260px, 1fr) 120px 150px 170px;
  gap: 14px;
  padding: 0 0 8px;
  font-size: 11.5px;
  color: var(--text-muted);
  letter-spacing: 0.01em;
}
body[data-page="history"] .tx-row{
  display: grid;
  grid-template-columns: 34px 140px minmax(260px, 1fr) 120px 150px 170px;
  gap: 14px;
  padding: 12px 0;
  border-top: 1px solid rgba(0,0,0,0.06);
  align-items: center;
  cursor: pointer;
}
body[data-page="history"] .tx-row:hover{ background: rgba(0,0,0,0.01); }
body[data-page="history"] .tx-cell{ min-width:0; font-size: 13px; }
body[data-page="history"] .tx-cell--status{ justify-self:end; padding-right: 18px; color: var(--text-muted); }
body[data-page="history"] .tx-status{ font-weight: 400 !important; }
body[data-page="history"] .tx-ico{ width:18px; height:18px; display:flex; align-items:center; justify-content:center; }
body[data-page="history"] .tx-ico svg{ width:18px; height:18px; }
body[data-page="history"] .tx-desc,
body[data-page="history"] .tx-d1{
  color: var(--text-muted);
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: normal;
}
body[data-page="history"] .tx-num{ text-align:right; }
body[data-page="history"] .tx-mrow{
  display:none;
}

@media (max-width: 860px){
  body[data-page="history"] .tx-table-head{ display:none; }
  body[data-page="history"] .tx-row{ display:none; }
  body[data-page="history"] .tx-mrow{
    display:grid;
    grid-template-columns: 22px minmax(0,1fr) auto;
    align-items:center;
    gap: 12px;
    padding: 12px 0;
    border-top: 1px solid rgba(0,0,0,0.06);
    cursor: pointer;
  }
  body[data-page="history"] .tx-mico{
    width: 22px;
    height: 22px;
    display:grid;
    place-items:center;
    opacity: .85;
  }
  body[data-page="history"] .tx-mleft{ min-width:0; }
  body[data-page="history"] .tx-mright{ text-align:right; }
  body[data-page="history"] .tx-mbal{ margin-top: 3px; font-size: 12px; }
}

/* Footer accordion */
.footer-acc summary{
  list-style: none;
  cursor: pointer;
}
.footer-acc summary::-webkit-details-marker{ display:none; }
.footer-acc__summary{
  display:flex;
  align-items:center;
  justify-content: space-between;
  gap: 10px;
}
.footer-acc__chev svg{ width: 18px; height: 18px; opacity: .85; }

@media (min-width: 721px){
  .footer-acc summary{ cursor: default; }
  .footer-acc__chev{ display:none; }
}


/* ---- Mobile polish: Banking total balance & chat ---- */
@media (max-width: 720px){
  .banking-page{ padding: 14px 0 26px; }
  .banking-grid{ gap: 12px; }
  .banking-card{ padding: 16px 16px 14px; border-radius: 16px; }
  .banking-card__head{ flex-direction: column; align-items: flex-start; gap: 6px; }
  .banking-card__amount--xl{ font-size: 30px; line-height: 1.05; }
  .banking-updated{ margin-top: 8px; }
  .banking-hero-card{ padding: 14px 14px; border-radius: 16px; }
  .banking-hero-card__title{ font-size: 18px; }
  .banking-hero-card__right{ width: 100%; justify-content: flex-start; }
  .banking-session{ width: 100%; }
  .banking-month-grid{ grid-template-columns: 1fr; }
}

/* Chat: remove toy gradient + better mobile sizing */
.chat-messages{
  background: rgba(245,245,247,0.65);
}
@media (max-width: 720px){
  .support-head{ flex-direction: column; align-items: flex-start; gap: 10px; }
  .chat{ border-radius: 16px; }
  .chat-messages{ max-height: calc(100vh - 260px); padding: 12px 10px 14px; }
  .chat-input{ padding: 10px; }
  .chat-send{ width: 44px; height: 44px; border-radius: 14px; }
  .msg{ max-width: 86%; }
}



/* =========================================================
   Mobile presentation polish (public UI)
   - fixes burger/nav drawer
   - improves Total balance block, month summary, quick actions
   ========================================================= */

.site-header{
  position: sticky;
  top: 0;
  z-index: 1003;
  background: #fff;
}

.nav-toggle{
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  width: 44px;
  height: 44px;
  padding: 0;
  border-radius: 12px;
}

.hamburger{
  width: 20px;
  height: 14px;
  display: inline-flex;
  flex-direction: column;
  justify-content: space-between;
}
.hamburger span{
  display:block;
  height: 2px;
  width: 100%;
  background: rgba(15,23,42,0.85);
  border-radius: 999px;
}

.nav-scrim{
  display:none;
}

@media (max-width: 860px){
  .nav-scrim{
    position: fixed;
    inset: 0;
    background: rgba(2,6,23,0.35);
    z-index: 1001;
  }
  html.nav-open .nav-scrim{ display:block; }

  /* Drawer nav */
  .nav{
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    width: min(82vw, 320px);
    background: #fff;
    z-index: 1002;
    padding: 68px 14px calc(14px + env(safe-area-inset-bottom) + 24px);
    transform: translateX(-120%);
    pointer-events: none;
    transition: transform .18s ease;
    overflow: hidden;
    visibility: hidden;
    border-right: 1px solid rgba(15,23,42,0.08);
  }
  html.nav-open .nav{ transform: translateX(0); pointer-events: auto; overflow: auto; visibility: visible; }

  /* Ensure header stays above drawer */
  .site-header{ z-index: 1003; }

  /* Make nav links comfortable on mobile */
  .nav-link{
    padding: 12px 12px;
    border-radius: 12px;
  }
}

/* --- Banking dashboard tweaks on mobile --- */
@media (max-width: 560px){

  /* Balance structure: bar should take about half the screen; value+% sit on the right */
  .structure-row{
    grid-template-columns: auto minmax(0, 1fr) auto;
    gap: 10px;
  }
  .structure-row__bar{
    max-width: 52vw;
  }
  .structure-row__right{
    text-align: right;
    white-space: nowrap;
    display:flex;
    flex-direction: column;
    align-items:flex-end;
    gap: 2px;
  }
  .structure-amount{ font-size: 12.5px; }
  .structure-percent{ font-size: 12px; }

  /* This month: compact rows (label left, value right) */
  .month-summary{
    grid-template-columns: 1fr;
    gap: 8px;
    padding: 10px;
  }
  .month-summary__item{
    padding: 10px 12px;
    border-radius: 14px;
  }
  .month-summary__meta{
    display:flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 10px;
  }
  .month-summary__label{
    font-size: 12px;
    color: var(--text-muted);
  }
  .month-summary__value{
    font-size: 13.5px;
    font-weight: 700;
    white-space: nowrap;
  }

  /* Quick actions: 1 per row, centered */
  .qa-row{
    grid-template-columns: 1fr;
    gap: 10px;
  }
  .qa-btn{
    justify-content: center;
    text-align: center;
    padding: 14px 14px;
  }
  .qa-btn__label{
    text-align:center;
  }
  .qa-row--single .qa-btn{
    justify-content: center;
    text-align: center;
  }

  /* Recent transactions: make typography consistent and compact */
  .tx-title{ font-size: 12.5px; }
  .tx-sub{ font-size: 11.5px; }
  .tx-amount{ font-size: 13px; }
}

/* Support chat: mobile-friendly header spacing */
@media (max-width: 560px){
  .chat-head{
    padding: 12px 14px;
  }
  .chat-wrap{
    padding-left: 12px;
    padding-right: 12px;
  }
  .chat-messages{
    padding: 12px;
  }
  .chat-bubble{
    max-width: 92%;
  }
}


/* =========================================================
   FIX6: Mobile quick actions full-width + Desktop header restore
   ========================================================= */

/* --- Desktop: ensure header/nav stay inline and not affected by mobile drawer rules --- */
@media (min-width: 721px){
  html.nav-open .nav-scrim{ display:none !important; }
  .nav-scrim{ display:none !important; }

  .site-header{
    position: relative !important;
    top: auto !important;
    z-index: auto !important;
    backdrop-filter: none !important;
  }

  .nav{
    position: static !important;
    inset: auto !important;
    width: auto !important;
    height: auto !important;
    padding: 0 !important;
    background: transparent !important;
    box-shadow: none !important;
    border-right: 0 !important;
    overflow: visible !important;
    display: flex !important;
    align-items: center !important;
    gap: 6px !important;
    transform: none !important;
  }

  .nav-link{
    display: inline-flex !important;
    width: auto !important;
  }

  .nav-toggle{ display:none !important; }
  body{ overflow: auto !important; }
}

/* --- Mobile: Quick actions as 3 full-width buttons with centered content --- */
@media (max-width: 720px){
  .qa-row{
    grid-template-columns: 1fr !important;
    gap: 10px !important;
  }
  .qa-btn{
    width: 100% !important;
    min-height: 56px;
    align-items: center !important;
    justify-content: center !important;
    text-align: center !important;
    flex-direction: row !important;
    gap: 10px !important;
  }
  .qa-btn__label{
    display:inline-block;
    text-align:center;
  }

  /* Drawer must not be height-clipped by desktop nav rules */
  .site-header .nav{
    height: 100vh !important;
    max-height: none !important;
  }
}


/* Mobile: month summary (centered, 2 lines per item, no nested cards) */
@media (max-width: 720px){
  .month-summary{
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0;
  }
  .month-summary__item{
    background: transparent;
    border-radius: 0;
    padding: 10px 6px;
    justify-content: center;
  }
  .month-summary__item + .month-summary__item{
    border-top: none;
    border-left: 1px solid rgba(0,0,0,0.10);
  }
  .month-summary__meta{
    display:flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 6px;
  }
  .month-summary__label{
    font-size: 12px;
    color: #64748b;
  }
  .month-summary__value{
    font-size: 14px;
    font-weight: 700;
  }
}


/* ===== Mobile polish override: This month (centered, 3 columns, dividers) ===== */
@media (max-width: 720px) {
  .month-summary{
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    gap: 0 !important;
    padding: 12px !important;
    border-radius: 16px !important;
    background: rgba(17, 24, 39, 0.04) !important;
  }
  .month-summary__item{
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 12px 6px !important;
    min-width: 0 !important;
    border-top: 0 !important;
    background: transparent !important;
    border-radius: 0 !important;
  }
  .month-summary__item + .month-summary__item{
    border-left: 1px solid rgba(0,0,0,0.10) !important;
  }
  .month-summary__meta{
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 6px !important;
    text-align: center !important;
  }
  .month-summary__label{
    margin: 0 !important;
    font-size: 12px !important;
    color: var(--text-muted) !important;
  }
  .month-summary__value{
    margin: 0 !important;
    text-align: center !important;
    font-weight: 600 !important;
    line-height: 1.1 !important;
  }
}



/* Mobile: transaction title clamp */
@media (max-width: 560px) {
  .tx-title {
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 1;
    overflow: hidden;
  }
}


/* ===== Mobile drawer nav polish (public site only) ===== */
/* Ensure drawer-only elements never leak into desktop header after resizing */
.site-header .nav .nav-drawer-head { display: none; }
.nav-scrim { display: none; }

/* --- Mobile nav: make scrim NEVER visible unless menu is open (fix persistent blur) --- */
.nav-scrim[hidden] { display: none !important; }
html:not(.nav-open) .nav-scrim { display: none !important; }
html.nav-open .nav-scrim { display: block !important; }
.nav-toggle { display: none; }

@media (max-width: 860px) {
  /* Header: true centered title on mobile.
     Grid 1fr/auto/1fr keeps the logo centered regardless of left/right icon widths. */
  .site-header .header-inner{
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    justify-content: initial;
    column-gap: 10px;
  }
  .site-header .nav-toggle{ justify-self: start; }
  .site-header .logo{ justify-self: center; }
  .site-header .header-actions{
    justify-self: end;
    display: inline-flex;
    align-items: center;
    gap: 10px;
  }

  .nav-toggle { display: inline-flex; padding: 8px; border: 0; background: transparent; }
  .nav-toggle .hamburger { width: 22px; height: 16px; display: inline-flex; flex-direction: column; justify-content: space-between; }
  .nav-toggle .hamburger span { display:block; height:2px; width:100%; background:#0f172a; border-radius:2px; }

  .nav-scrim {
    display: block;
    position: fixed; inset: 0;
    background: rgba(15, 23, 42, 0.28);
    backdrop-filter: blur(2px);
    z-index: 80;
    display: block;
  }

  /* turn primary nav into drawer */
  .site-header .nav {
    position: fixed;
    top: 0; left: 0;
    /*
      iOS Safari (non-standalone) can overlay the bottom URL bar over 100vh.
      Use the small viewport height when available to keep the last item
      (e.g., Support) visible above the browser chrome.
    */
    height: 100vh;
    height: 100svh;
    width: min(86vw, 340px);
    background: #ffffff;
    z-index: 90;
    transform: translateX(-110%);
    transition: transform .22s ease;
    box-shadow: 0 12px 40px rgba(15, 23, 42, 0.18);
    /* Extra bottom padding so the last item (e.g., Support) doesn't sit under Safari's URL bar */
    padding: 14px 14px calc(16px + env(safe-area-inset-bottom) + 72px);
    display: flex;
    flex-direction: column;
    gap: 6px;
    /* allow scrolling if browser chrome reduces visible height */
    overflow-y: auto;
    overscroll-behavior: contain;
    visibility: hidden;
  }

  html.nav-open .site-header .nav { transform: translateX(0); }

  .site-header .nav .nav-drawer-head {
    display:flex;
    align-items:center;
    justify-content:space-between;
    padding: 6px 2px 12px;
    border-bottom: 1px solid rgba(15, 23, 42, 0.08);
    margin-bottom: 6px;
  }

  .nav-drawer-title { font-weight: 700; font-size: 16px; color:#0f172a; line-height: 1.1; }
  .nav-drawer-sub { font-size: 12.5px; color: rgba(15, 23, 42, 0.62); margin-top: 2px; }

  .nav-drawer-close {
    border: 0; background: transparent;
    width: 36px; height: 36px;
    border-radius: 10px;
    display:flex; align-items:center; justify-content:center;
    color:#0f172a;
  }
  .nav-drawer-close:active { background: rgba(15, 23, 42, 0.06); }

  .site-header .nav-link {
    display:flex;
    align-items:center;
    gap: 10px;
    padding: 12px 12px;
    border-radius: 12px;
    text-decoration:none;
    color:#0f172a;
  }

  .site-header .nav-link .nav-ico { opacity: .78; }
  .site-header .nav-link.active { background: rgba(15, 23, 42, 0.06); }
  .site-header .nav-link:active { background: rgba(15, 23, 42, 0.04); }

  /* Push support to bottom */
  .site-header .nav-link--support { margin-top: auto; }
  .site-header .nav-link--support { border-top: 1px solid rgba(15, 23, 42, 0.08); padding-top: 14px; border-radius: 0; }
  .site-header .nav-link--support:active { background: transparent; }
}


/* ==========================
   Profile page (public)
   ========================== */





/* Profile page (v3) — clean banking layout */
.pr3-hero{ padding: 16px; }
.pr3-hero__row{ display:flex; align-items:center; justify-content: space-between; gap: 14px; }
.pr3-hero__id{ display:flex; align-items:center; gap: 12px; min-width: 0; }
.pr3-avatar{
  width: 44px; height: 44px;
  border-radius: 12px;
  background: rgba(15,23,42,0.04);
  display:flex; align-items:center; justify-content:center;
  font-weight: 700;
  letter-spacing: 0.5px;
}
.pr3-idtext{ min-width: 0; }
.pr3-name{ font-size: 18px; font-weight: 700; line-height: 1.12; }
.pr3-sub{
  margin-top: 2px;
  font-size: 13px;
  color: rgba(15,23,42,0.66);
  font-weight: 600;
  display:flex; gap: 10px; align-items:center; flex-wrap: wrap;
}
.pr3-dot{ width: 3px; height: 3px; border-radius: 50%; background: rgba(15,23,42,0.22); display:inline-block; }
.pr3-muted{ color: rgba(15,23,42,0.66); font-weight: 600; }
.pr3-strong{ color: rgba(15,23,42,0.92); font-weight: 700; }
.pr3-hero__actions{ display:flex; gap: 10px; flex-wrap: wrap; justify-content: flex-end; }
.pr3-btn{ padding: 8px 12px; }

.pr3-divider{ margin: 14px 0; border-radius: 999px; }

.pr3-meta{
  display:grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}
.pr3-meta__item{ padding: 2px 0; }
.pr3-meta__k{ font-size: 12px; color: rgba(15,23,42,0.55); font-weight: 600; }
.pr3-meta__v{ font-size: 13.5px; color: rgba(15,23,42,0.88); font-weight: 700; margin-top: 2px; }

.pr3-shell{
  margin-top: 14px;
  display:grid;
  grid-template-columns: 320px minmax(0, 1fr);
  gap: 14px;
  align-items: start;
}

.pr3-nav{ padding: 10px 12px; }
.pr3-nav__item{
  width: 100%;
  text-align: left;
  background: transparent;
  border: 0;
  padding: 12px 10px;
  border-radius: 12px;
  cursor: pointer;
  display:flex;
  align-items:center;
  gap: 10px;
}
.pr3-nav__ico{
  width: 20px;
  height: 20px;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  margin-top: 0;
  opacity: .88;
}
.pr3-nav__ico .ico{ width: 18px; height: 18px; }
.pr3-nav__stack{ display:grid; gap: 2px; min-width: 0; }
.pr3-nav__label{ font-weight: 700; font-size: 13.5px; }
.pr3-nav__hint{ font-weight: 600; font-size: 12.5px; color: rgba(15,23,42,0.60); }
.pr3-nav__item:hover{ background: rgba(15,23,42,0.03); }
.pr3-nav__item.is-active{ background: rgba(15,23,42,0.05); }
.pr3-sep{ height: 1px; background: rgba(0,0,0,0.06); }

.pr3-panel{ padding: 14px 16px; }
.pr3-tabs{
  display:none;
  gap: 10px;
  flex-wrap: wrap;
}
.pr3-tab{
  border: 0;
  background: transparent;
  font-weight: 700;
  font-size: 13px;
  color: rgba(15,23,42,0.70);
  cursor: pointer;
  padding: 8px 0;
  position: relative;
}
.pr3-tab.is-active{
  color: rgba(15,23,42,0.92);
}
.pr3-tab.is-active::after{
  content:"";
  position:absolute;
  left: 0;
  right: 0;
  bottom: -2px;
  height: 2px;
  background: rgba(15,23,42,0.22);
  border-radius: 999px;
}

.pr3-section{ display:none; }
.pr3-section.is-active{ display:block; }

.pr3-title{ font-weight: 700; font-size: 16px; }
.pr3-text{
  margin-top: 4px;
  color: rgba(15,23,42,0.66);
  font-weight: 600;
  font-size: 13px;
  max-width: 760px;
}

.pr3-form{ margin-top: 2px; }
.pr3-grid{
  display:grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}
.pr3-span{ grid-column: 1 / -1; }

.pr3-actions{
  display:flex;
  gap: 10px;
  flex-wrap: wrap;
}
.pr3-btnWide{ min-width: 180px; }

.pr3-row{
  display:flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 0;
}
.pr3-row__main{ min-width: 0; }
.pr3-row__title{ font-weight: 700; }
.pr3-row__sub{ margin-top: 2px; color: rgba(15,23,42,0.62); font-weight: 600; font-size: 12.8px; }
.pr3-row__right{ display:flex; align-items:center; gap: 12px; flex-wrap: wrap; justify-content: flex-end; }
.pr3-row__actions{ display:flex; gap: 8px; }

.pr3-fineprint{
  margin-top: 10px;
  color: rgba(15,23,42,0.58);
  font-size: 12.7px;
  font-weight: 600;
}

@media (max-width: 980px){
  .pr3-shell{ grid-template-columns: 1fr; }
  .pr3-nav{ display:none; }
  .pr3-tabs{ display:grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; padding: 2px 0 6px; }
  .pr3-tab{ background: rgba(15,23,42,0.03); border-radius: 14px; padding: 10px 8px; display:flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; color: rgba(15,23,42,0.78); }
  .pr3-tab__ico{ width: 22px; height: 22px; display:inline-flex; align-items:center; justify-content:center; opacity: .9; }
  .pr3-tab__ico .ico{ width: 20px; height: 20px; }
  .pr3-tab__txt{ font-weight: 800; font-size: 12.2px; line-height: 1.1; text-align:center; }
  .pr3-tab.is-active{ background: rgba(15,23,42,0.06); color: rgba(15,23,42,0.92); }
  .pr3-tab.is-active::after{ display:none; }
  .pr3-hero__row{ flex-direction: column; align-items: flex-start; }
  .pr3-hero__actions{ width: 100%; justify-content: flex-start; }
  .pr3-meta{ grid-template-columns: 1fr; }
  .pr3-btnWide{ flex: 1 1 200px; }
}

@media (max-width: 680px){
  .pr3-grid{ grid-template-columns: 1fr; }
  .pr3-btnWide{ width: 100%; }
}




/* Profile page (v3) — polish pass */
.pr3-shell{ align-items: stretch; }
.pr3-nav, .pr3-panel{ height: 100%; }
.pr3-panel{ display: flex; flex-direction: column; }
.pr3-panelBody{ flex: 1; display: flex; flex-direction: column; }
.pr3-section{ width: 100%; }

.pr3-hero__actions .btn{ font-size: 10.8pt; }
.pr3-hero__actions .btn .ico-wrap{ display:inline-flex; align-items:center; }
.pr3-btn{ padding: 8px 12px; line-height: 1; }

.pr3-name{ font-size: 17px; }
.pr3-title{ font-size: 15px; line-height: 1.2; }
.pr3-text{ font-size: 13px; }

.pr3-meta__k{ font-size: 11.8px; }
.pr3-meta__v{ font-size: 13.2px; line-height: 1.2; }

.pr3-row{ align-items: flex-start; }
.pr3-row__right{ padding-top: 2px; }
.pr3-row__title{ line-height: 1.2; }
.pr3-row__sub{ line-height: 1.25; }

.pr3-actions .btn{ font-size: 10.8pt; }
.pr3-fineprint{ line-height: 1.35; }

.pr3-email{ color: rgba(15,23,42,0.78); font-weight: 600; }

/* Overview information grid */
.pr3-infoGrid{
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}
.pr3-infoItem{
  padding: 2px 0;
  min-width: 0;
}
.pr3-infoK{
  font-size: 11.8px;
  color: rgba(15,23,42,0.55);
  font-weight: 600;
}
.pr3-infoV{
  margin-top: 2px;
  font-size: 13.2px;
  color: rgba(15,23,42,0.88);
  font-weight: 700;
  line-height: 1.25;
  word-break: break-word;
}
.pr3-infoSpan{ grid-column: 1 / -1; }

@media (max-width: 980px){
  .pr3-infoGrid{ grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 680px){
  .pr3-infoGrid{ grid-template-columns: 1fr; }
}

@media (max-width: 980px){
  .pr3-panel{ height: auto; }
}


/* Accounts page (v2) — banking layout */
.ac-hero{ padding: 16px; }
.ac-hero__row{ display:flex; align-items:flex-end; justify-content:space-between; gap: 14px; }
.ac-hero__title .muted{ margin-top: 4px; }
.ac-hero__actions{ display:flex; gap: 10px; flex-wrap: wrap; justify-content:flex-end; }


.ac-shell{
  margin-top: 14px;
  display:grid;
  grid-template-columns: 360px minmax(0, 1fr);
  gap: 14px;
  align-items: stretch;
  min-width: 0;
}

/* Prevent any flex/grid child from forcing horizontal overflow (mobile jitter fix) */
.ac-shell > .card, .ac-list, .ac-detail, .ac-tabs{ min-width:0; max-width:100%; }
.ac-list, .ac-detail{ overflow:hidden; }

.ac-tabs{ display:none; padding: 10px 12px; }
.ac-tab{
  border: 0;
  background: transparent;
  font-weight: 700;
  font-size: 13px;
  color: rgba(15,23,42,0.70);
  cursor: pointer;
  padding: 8px 0;
  position: relative;
  margin-right: 12px;
}
.ac-tab.is-active{ color: rgba(15,23,42,0.92); }
.ac-tab.is-active::after{
  content:"";
  position:absolute;
  left: 0;
  right: 0;
  bottom: -2px;
  height: 2px;
  background: rgba(15,23,42,0.22);
  border-radius: 999px;
}

.ac-list, .ac-detail{ height: 100%; }

/* Prevent any child content from stretching the cards on narrow screens */
body[data-page="accounts"] .ac-tabs,
body[data-page="accounts"] .ac-list,
body[data-page="accounts"] .ac-detail,
body[data-page="accounts"] .ac-items,
body[data-page="accounts"] .ac-item,
body[data-page="accounts"] .ac-detail__sub{ min-width:0; max-width:100%; }
body[data-page="accounts"] .ac-list,
body[data-page="accounts"] .ac-detail{ overflow:hidden; }

.ac-list{ padding: 12px 14px; }
.ac-list__head{ display:flex; align-items: center; justify-content: space-between; gap: 10px; }
.ac-list__title{ font-weight: 700; font-size: 14px; }
.ac-list__meta{ font-size: 12.5px; }

.ac-items{ padding: 4px 0; }
.ac-item{
  width: 100%;
  text-align: left;
  background: transparent;
  border: 0;
  padding: 12px 0;
  display:flex;
  align-items:center;
  justify-content: space-between;
  gap: 12px;
  cursor: pointer;
}
.ac-item + .ac-item{ border-top: 1px solid rgba(15,23,42,0.06); }
.ac-item.is-active{ background: transparent; }
.ac-item.is-active .ac-item__title{ color: rgba(15,23,42,0.92); }
.ac-item:hover{ background: transparent; }
.ac-item__main{ min-width: 0; }
.ac-item__title{ font-size: 13.8px; font-weight: 700; display:flex; gap: 8px; align-items: baseline; }
.ac-item__sub{ margin-top: 3px; font-size: 12.5px; color: rgba(15,23,42,0.62); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 320px; }
.ac-item__bal{ font-weight: 600; font-size: 13px; white-space: nowrap; }
.ac-tag{ font-size: 12px; font-weight: 600; color: rgba(15,23,42,0.58); }

.ac-detail{ padding: 12px 16px; display:flex; flex-direction: column; }
.ac-detail__head{ display:flex; flex-direction: column; gap: 2px; }
.ac-detail__title{ font-weight: 700; font-size: 15px; }
.ac-detail__sub{ font-size: 12.5px; color: rgba(15,23,42,0.62); }

.ac-status{
  margin-top: 10px;
  display:flex;
  gap: 10px;
  align-items:center;
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(15,23,42,0.03);
}
.ac-status__bar{ width: 3px; border-radius: 999px; background: rgba(15,23,42,0.22); margin-top: 2px; }
.ac-status[data-kind="warning"] .ac-status__bar{ background: rgba(245, 158, 11, 0.75); }
.ac-status__text{ font-size: 12.8px; font-weight: 600; color: rgba(15,23,42,0.78); line-height: 1.3; }

.ac-balance{ display:grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.ac-balance__k{ font-size: 11.8px; color: rgba(15,23,42,0.55); font-weight: 600; }
.ac-balance__v{ margin-top: 2px; font-size: 13.5px; font-weight: 700; }

.ac-kv{ display:grid; grid-template-columns: 170px minmax(0, 1fr); gap: 8px 12px; }
.ac-kv .k{ font-size: 12.5px; color: rgba(15,23,42,0.62); font-weight: 600; }
.ac-kv .v{ font-size: 12.8px; font-weight: 700; color: rgba(15,23,42,0.90); }

.ac-actions{ display:flex; gap: 10px; flex-wrap: wrap; }

.ac-activity__head{ display:flex; justify-content: space-between; gap: 10px; align-items: center; }
.ac-activity__title{ font-weight: 700; font-size: 14px; }

.ac-row{ display:flex; justify-content: space-between; gap: 12px; padding: 10px 0; }
.ac-row + .ac-row{ border-top: 1px solid rgba(15,23,42,0.06); }
.ac-row__main{ min-width: 0; }
.ac-row__desc{ font-weight: 500; font-size: 13px; line-height: 1.25; }
.ac-row__meta{ margin-top: 3px; font-size: 12.5px; }
.ac-row__amt{ font-weight: 600; font-size: 13px; white-space: nowrap; }
.ac-row__amt.is-neg{ color: rgba(15, 23, 42, 0.90); }
.ac-row__amt.is-pos{ color: rgba(21, 128, 61, 0.90); }
.ac-foot{ margin-top: 10px; font-size: 12.5px; }

@media (max-width: 980px){
  .ac-hero__row{ flex-direction: column; align-items:flex-start; }
  .ac-hero__actions{ justify-content:flex-start; }
  .ac-shell{ grid-template-columns: 1fr; }
  .ac-tabs{ display:block; }
  .ac-shell[data-ac-view="list"] .ac-detail{ display:none; }
  .ac-shell[data-ac-view="detail"] .ac-list{ display:none; }
  .ac-balance{ grid-template-columns: 1fr; }
  .ac-kv{ grid-template-columns: 1fr; }
  .ac-item__sub{ max-width: 100%; }
}

@media (max-width: 720px){
  body[data-page="accounts"] .ac-shell{ margin-top: 12px; }
}

/* Marketing illustrations (SVG) */
.marketing-illustration{
  width: 100%;
  max-width: 520px;
  height: auto;
  display:block;
}

/* Marketing note should match site style: plain, no card look */
.marketing-note{
  margin-top: 16px;
  padding: 0;
  border: none;
  background: transparent;
}
.mn-title{ font-weight: 600; margin-bottom: 6px; }
.mn-text{ color: var(--text-muted); font-size: 13px; max-width: 680px; }
.mn-actions{ margin-top: 12px; display:flex; gap: 10px; flex-wrap: wrap; }

/* Marketing photos (match site style) */
.marketing-photo{
  width: 100%;
  height: auto;
  display: block;
  border-radius: 22px;
}
.marketing-photo--hero{
  max-width: 520px;
  height: 280px;
  object-fit: cover;
}
.m-media .marketing-photo{
  max-width: 520px;
  height: 280px;
  object-fit: contain;
}
@media (max-width: 760px){
  .marketing-photo--hero,
  .m-media .marketing-photo{
    max-width: 560px;
    height: 210px;
    object-fit: contain;
  }
  /* Marketing layout on phones: text first, media after */
  .hero--marketing{ grid-template-columns: 1fr; }
  .hero--marketing .hero-main{ order: 1; }
  .hero--marketing .hero-media{ display:flex; justify-content:flex-start; align-items:center; }
}
.hero-media img{ width: 100%; display: block; }

/* Marketing hero SVG */
.marketing-hero-svg{
  width: 100%;
  max-width: 640px;
  height: auto;
  display: block;
}


/* SVG section visuals */
.marketing-photo{
  width: 100%;
  max-width: 520px;
  height: auto;
  display:block;
}
@media (max-width: 900px){
  .marketing-hero-svg{
  width: 100%;
  max-width: 640px;
  height: auto;
  display: block;
}

}


/* Key-value layout for detail views (moderator) */
.kv {
  margin: 0;
}
.kv-row {
  display: flex;
  gap: 12px;
  padding: 4px 0;
}
.kv-row dt {
  min-width: 150px;
  font-weight: 500;
  color: var(--muted-text);
}
.kv-row dd {
  margin: 0;
  flex: 1;
}

  top: auto;
  display: flex;
  align-items: center;
}
  padding: 0;
  border: none;
  background: transparent;
  border-radius: 0;
}
  max-width: 420px;
}
  max-width: 420px;
}

  top: auto;
  display: flex;
  align-items: center;
}
  padding: 0;
  border: none;
  background: transparent;
  border-radius: 0;
}
  max-width: 460px;
}
  max-width: 420px;
}

  top: auto;
  display: flex;
  align-items: center;
}
  padding: 0;
  border: none;
  background: transparent;
  border-radius: 0;
}
  max-width: 460px;
}
  margin-top: 12px;
  max-width: 420px;
}

  top: auto;
  display: flex;
  align-items: center;
}
  padding: 0;
  border: none;
  background: transparent;
  border-radius: 0;
}
  max-width: 460px;
}
  margin-top: 12px;
  max-width: 420px;
}














/* Auth split: keep illustration but remove card look; center relative to the form */
.page-split--auth{ align-items: center; }

/* Auth split: keep illustration but remove card look; center relative to the form */
.page-split--auth{ align-items: center; }
.page-split--auth .page-split__aside{ position: static; top: auto; display: flex; align-items: center; }
.page-split--auth .page-illustration{ padding: 0; border: none; background: transparent; border-radius: 0; }
.page-split--auth .page-illustration__img{ max-width: 480px; }
.page-split--auth .page-illustration__cap{ margin-top: 12px; }

/* Auth split: the title/subhead are outside the split; keep the form naturally aligned */
.page-split--auth > section{ width:100%; }
.page-split--auth .page-split__aside{
  justify-content:center;
}

/* --- Compatibility aliases (auth visuals) --- */
/* Center the illustration and caption relative to the login form card */
.auth-visual{ display:flex; flex-direction:column; align-items:center; text-align:center; width:100%; }
.auth-visual__img{ max-width: 520px; width: 100%; height: auto; display:block; margin: 0 auto; }
.auth-visual__cap{ margin-top: 12px; color: var(--text-muted); font-size: 0.95rem; max-width: 420px; }

/* Auth: keep the split aligned to the form (title/subhead are outside the split) */
.page-subhead--auth{ margin-bottom: 18px; }
.page-split--auth .auth-form{ width:100%; }
/* Keep aside hidden on mobile (matches earlier requirement) */
@media (max-width: 720px){
  .page-split--auth .page-split__aside{ display:none !important; }
}


/* Soft separators + notice cards */
.soft-hr{
  border:0;
  border-top:1px solid rgba(148,163,184,.35);
  margin:14px 0;
}
.notice-card{
  border:1px solid rgba(148,163,184,.35);
  border-radius:14px;
  padding:12px;
  background:rgba(15,23,42,.02);
}
.notice-line{
  display:flex;
  align-items:center;
  gap:10px;
  margin-bottom:8px;
  flex-wrap:wrap;
}
.notice-title{
  font-weight: 700;
}
.notice-text{
  color:var(--text-muted);
  font-size:14px;
  line-height:1.55;
}

/* ------------------------------------------------------------------
   Chrome typography normalisation
   Some Windows Chrome setups render semi-bold weights noticeably
   heavier than Edge/IE. Keep key numeric widgets at 500 instead of 600.
   ------------------------------------------------------------------ */

/* Numeric amounts (cards, lists, widgets) */
.banking-card__amount,
.month-summary__value,
.account-row__amount,
.ac-item__bal,
.ac-row__amt,
.tx-amount,
.tx-amount--in,
.tx-amount--out,
.money-in,
.money-out {
  font-weight: 500;
}

/* Extra-large key number (Total balance) */
.banking-card__amount--xl { font-weight: 600; }

/* Keep emphasis consistent (avoid extra-heavy synthetic bold) */
strong, b { font-weight: 500; }

/* CLIENT FONT WEIGHT NORMALISATION */
body:not(.bo):not(.backoffice) *{
  font-weight: 400 !important;
}
body:not(.bo):not(.backoffice) b,
body:not(.bo):not(.backoffice) strong{
  font-weight: 500 !important;
}
body:not(.bo):not(.backoffice) h1,
body:not(.bo):not(.backoffice) h2,
body:not(.bo):not(.backoffice) h3,
body:not(.bo):not(.backoffice) h4,
body:not(.bo):not(.backoffice) .logo,
body:not(.bo):not(.backoffice) .nav a,
body:not(.bo):not(.backoffice) .nav-link,
body:not(.bo):not(.backoffice) .page-title,
body:not(.bo):not(.backoffice) .cap-title,
body:not(.bo):not(.backoffice) .mn-title,
body:not(.bo):not(.backoffice) .mm-title,
body:not(.bo):not(.backoffice) .card-title,
body:not(.bo):not(.backoffice) .banking-card__title,
body:not(.bo):not(.backoffice) .section-title,
body:not(.bo):not(.backoffice) .table thead th,
body:not(.bo):not(.backoffice) th,
body:not(.bo):not(.backoffice) .btn,
body:not(.bo):not(.backoffice) .pill,
body:not(.bo):not(.backoffice) .badge,
body:not(.bo):not(.backoffice) .account-row__name,
body:not(.bo):not(.backoffice) .banking-session,
body:not(.bo):not(.backoffice) .banking-welcome__title{
  font-weight: 500 !important;
}
body:not(.bo):not(.backoffice) .amount,
body:not(.bo):not(.backoffice) .money,
body:not(.bo):not(.backoffice) .banking-card__amount,
body:not(.bo):not(.backoffice) .account-row__amount,
body:not(.bo):not(.backoffice) .tx-mamt,
body:not(.bo):not(.backoffice) .loan-amount,
body:not(.bo):not(.backoffice) .transfer-amount{
  font-weight: 500 !important;
}


/* Inline save/publish status pill */
.bo-inline-status{display:inline-flex;align-items:center;gap:6px;padding:6px 10px;border-radius:999px;font-size:13px;border:1px solid rgba(0,0,0,.08);background:#f3f4f6;color:#111827;}
.bo-inline-status.ok{background:rgba(22,163,74,.12);border-color:rgba(22,163,74,.22);color:#166534;}
.bo-inline-status.error{background:rgba(220,38,38,.12);border-color:rgba(220,38,38,.22);color:#991b1b;}


/* Backoffice: user card list */
.bo-usercards{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px;margin-top:14px;}
.user-card{background:#fff;border:1px solid rgba(0,0,0,.06);border-radius:16px;padding:14px 14px 12px;box-shadow:0 1px 2px rgba(0,0,0,.03);}
.user-card-top{display:flex;justify-content:space-between;gap:10px;align-items:flex-start;}
.user-name{font-size:15px;font-weight:650;color:#0f172a;line-height:1.2;}
.user-meta{font-size:13px;color:#64748b;margin-top:4px;}
.user-badges{display:flex;flex-wrap:wrap;gap:6px;justify-content:flex-end;}
.user-card-mid{display:grid;grid-template-columns:1fr 1fr;gap:10px;margin-top:12px;padding-top:12px;border-top:1px solid rgba(15,23,42,.06);}
.user-kv .k{font-size:11px;letter-spacing:.06em;text-transform:uppercase;color:#94a3b8;}
.user-kv .v{font-size:13px;color:#0f172a;margin-top:4px;}
.user-card-actions{display:flex;gap:8px;flex-wrap:wrap;margin-top:12px;padding-top:12px;border-top:1px solid rgba(15,23,42,.06);}
.user-card-actions .btn.small{padding:8px 10px;border-radius:12px;}
.pill{display:inline-flex;align-items:center;padding:5px 9px;border-radius:999px;border:1px solid rgba(0,0,0,.08);font-size:12px;color:#0f172a;background:rgba(241,245,249,.8);}
.pill.warn{background:rgba(245,158,11,.12);border-color:rgba(245,158,11,.35);color:#92400e;}
.pill.danger{background:rgba(239,68,68,.12);border-color:rgba(239,68,68,.35);color:#991b1b;}
.pill.muted{background:rgba(148,163,184,.12);border-color:rgba(148,163,184,.3);color:#475569;}
@media (max-width: 1100px){.bo-usercards{grid-template-columns:repeat(2,minmax(0,1fr));}}
@media (max-width: 700px){.bo-usercards{grid-template-columns:1fr;}}

/* Moderator overview: stack wide tables in one column (prevents horizontal overflow / right shift) */
body.bo-moderator .mod-overview-grid{
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
  width: 100%;
}
body.bo-moderator .mod-overview-grid > .card{ width: 100%; }

/* Transaction list alignment (Banking + History): keep the Status column header aligned with values */
.tx-head--status{ display:flex; align-items:center; justify-content:center; text-align:center; }
.tx-cell--status{ display:flex; align-items:center; justify-content:center; text-align:center; }


/* === KYC status page (underline + icon, no pills) === */
.kyc-meta .meta-row{ align-items: center; }
.kyc-status{
  display:inline-flex;
  align-items:center;
  gap: 8px;
  font-weight: 600;
  color: rgba(15,23,42,0.82);
}
.kyc-status__ico svg{ width: 18px; height: 18px; display:block; }
.kyc-status__label{
  display:inline-block;
  padding-bottom: 2px;
  border-bottom: 2px solid rgba(15,23,42,0.18);
}
.kyc-status[data-kind="pending"] .kyc-status__label{ border-bottom-color: rgba(245,158,11,0.55); }
.kyc-status[data-kind="approved"] .kyc-status__label{ border-bottom-color: rgba(22,163,74,0.55); }
.kyc-status[data-kind="rejected"] .kyc-status__label{ border-bottom-color: rgba(220,38,38,0.55); }

.kyc-reason-row .meta-v{
  color: rgba(15,23,42,0.82);
  font-weight: 500;
}

.is-hidden{ display:none !important; }

.status-footnote{
  margin: 10px 0 0;
  color: var(--text-muted);
  font-size: 12.5px;
  line-height: 1.45;
}

@media (max-width: 520px){
  .status-card{ grid-template-columns: 1fr; }
  .status-card .status-icon{ width: 44px; height: 44px; border-radius: 14px; }
}
