/* BankU PG user portal shell. Every rule is role-scoped so the admin UI stays unchanged. */
body.portal-user {
  --np-purple-950: #190638;
  --np-purple-900: #250857;
  --np-purple-800: #351078;
  --np-purple-700: #4b1bb3;
  --np-purple-600: #6534e8;
  --np-purple-100: #eee8ff;
  --np-purple-50: #f7f4ff;
  --np-blue-700: #0068e8;
  --np-blue-600: #0784ff;
  --np-blue-500: #1aa2ff;
  --np-blue-100: #e3f2ff;
  --np-green: #0aa77a;
  --np-amber: #db8d16;
  --np-red: #d54b68;
  --np-ink: #211938;
  --np-muted: #706b82;
  --np-line: #e7e3f0;
  --np-surface: #fff;
  --np-bg: #f6f5fa;
  --np-shadow-sm: 0 6px 20px rgba(41, 20, 87, .06);
  --np-shadow-md: 0 16px 44px rgba(41, 20, 87, .1);
  --ink: var(--np-ink);
  --muted: var(--np-muted);
  --line: var(--np-line);
  --paper: var(--np-surface);
  --bg: var(--np-bg);
  --blue: var(--np-blue-700);
  --violet: var(--np-purple-700);
  --violet-dark: var(--np-purple-900);
  --violet-soft: var(--np-purple-100);
  min-width: 320px;
  background:
    radial-gradient(circle at 8% 15%, rgba(101, 52, 232, .055), transparent 25rem),
    radial-gradient(circle at 92% 12%, rgba(7, 132, 255, .055), transparent 27rem),
    var(--np-bg);
  color: var(--np-ink);
}

body.portal-user :where(a, button, input, select, textarea, [tabindex]):focus-visible {
  outline: 3px solid rgba(7, 132, 255, .38);
  outline-offset: 3px;
  box-shadow: none;
}

/* Fixed top navigation */
body.portal-user .northpay-user-header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 200;
  min-height: 76px;
  border-bottom: 1px solid rgba(69, 35, 128, .12);
  background: rgba(255, 255, 255, .94);
  box-shadow: 0 8px 34px rgba(31, 12, 70, .055);
  backdrop-filter: blur(18px) saturate(1.25);
  -webkit-backdrop-filter: blur(18px) saturate(1.25);
}

body.portal-user .northpay-user-header.is-scrolled {
  box-shadow: 0 12px 36px rgba(31, 12, 70, .1);
}

body.portal-user .northpay-user-bar {
  width: min(100%, 1800px);
  min-height: 76px;
  margin: 0 auto;
  padding: 10px clamp(18px, 2.5vw, 42px);
  display: flex;
  align-items: center;
  gap: clamp(14px, 2vw, 34px);
}

body.portal-user .northpay-wordmark {
  width: 156px;
  height: 52px;
  display: block;
  flex: 0 0 auto;
  text-decoration: none;
}

body.portal-user .northpay-wordmark-image {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: contain;
  object-position: left center;
}

body.portal-user .northpay-user-drawer {
  min-width: 0;
  display: flex;
  align-items: center;
  flex: 1;
  gap: clamp(12px, 1.8vw, 28px);
}

body.portal-user .northpay-user-nav {
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  flex: 1;
  gap: 3px;
}

body.portal-user .northpay-user-nav > a,
body.portal-user .northpay-user-nav .nav-parent {
  min-height: 42px;
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 10px 11px;
  border: 0;
  border-radius: 11px;
  background: transparent;
  color: #5f5871;
  text-decoration: none;
  white-space: nowrap;
  font-size: 12px;
  line-height: 1;
  transition: color .18s ease, background .18s ease, transform .18s ease;
}

body.portal-user .northpay-user-nav .nav-parent {
  width: 100%;
  cursor: pointer;
}

body.portal-user .northpay-user-nav .nav-parent:not(button) {
  cursor: default;
}

body.portal-user .northpay-user-nav b {
  font-size: inherit;
  font-weight: 700;
}

body.portal-user .northpay-user-nav > a:first-child {
  font-size: 0;
}

body.portal-user .northpay-user-nav > a:first-child b {
  font-size: 12px;
}

body.portal-user .northpay-user-nav .nav-parent > span:first-child {
  color: var(--np-purple-600);
  font-size: 14px;
}

body.portal-user .northpay-user-nav .nav-chevron {
  margin-left: 1px;
  color: #938aa5;
  font-size: 14px;
  font-style: normal;
  transition: transform .18s ease;
}

body.portal-user .northpay-user-nav > a:hover,
body.portal-user .northpay-user-nav .nav-parent:hover,
body.portal-user .northpay-user-nav > a.active,
body.portal-user .northpay-user-nav .nav-group.open > .nav-parent,
body.portal-user .northpay-user-nav .nav-group.has-active > .nav-parent {
  background: var(--np-purple-50);
  color: var(--np-purple-800);
}

body.portal-user .northpay-user-nav > a.active,
body.portal-user .northpay-user-nav .nav-group.open > .nav-parent,
body.portal-user .northpay-user-nav .nav-group.has-active > .nav-parent {
  box-shadow: inset 0 0 0 1px rgba(81, 30, 191, .08);
}

body.portal-user .northpay-user-nav .nav-group {
  position: relative;
}

body.portal-user .northpay-user-nav .northpay-doc-focus {
  position: absolute;
  inset: 0 0 auto;
  z-index: 2;
  height: 42px;
  border-radius: 11px;
}

body.portal-user .northpay-user-nav .nav-group::after {
  content: "";
  position: absolute;
  top: 100%;
  left: 0;
  width: 100%;
  height: 11px;
}

body.portal-user .northpay-user-nav .nav-submenu {
  position: absolute;
  top: calc(100% + 10px);
  left: 50%;
  z-index: 220;
  width: max-content;
  min-width: 218px;
  display: none;
  gap: 3px;
  padding: 9px;
  border: 1px solid rgba(61, 24, 133, .12);
  border-radius: 14px;
  background: rgba(255, 255, 255, .985);
  box-shadow: 0 20px 55px rgba(31, 12, 70, .17);
  transform: translateX(-50%);
}

body.portal-user .northpay-user-nav .nav-group:hover > .nav-submenu,
body.portal-user .northpay-user-nav .nav-group:focus-within > .nav-submenu,
body.portal-user .northpay-user-nav .nav-group.user-nav-open > .nav-submenu {
  display: grid;
  animation: np-menu-in .16s ease-out both;
}

body.portal-user .northpay-user-nav .sub-link {
  min-height: 39px;
  display: flex;
  align-items: center;
  padding: 9px 12px;
  border-radius: 9px;
  color: #625a75;
  text-decoration: none;
  font-size: 12px;
}

body.portal-user .northpay-user-nav .sub-link:hover,
body.portal-user .northpay-user-nav .sub-link.active {
  background: linear-gradient(100deg, var(--np-purple-50), #eef7ff);
  color: var(--np-purple-800);
}

body.portal-user .northpay-user-nav .sub-link.active {
  box-shadow: inset 3px 0 0 var(--np-blue-600);
}

body.portal-user .northpay-user-tools {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 0 0 auto;
}

body.portal-user .northpay-support-link,
body.portal-user .northpay-user-profile,
body.portal-user .northpay-logout-form button {
  min-height: 43px;
  display: inline-flex;
  align-items: center;
  border: 1px solid #e4e0ed;
  border-radius: 12px;
  background: #fff;
  color: var(--np-ink);
  text-decoration: none;
}

body.portal-user .northpay-support-link {
  gap: 8px;
  padding: 5px 10px 5px 6px;
}

body.portal-user .northpay-support-link > span:first-child {
  width: 30px;
  height: 30px;
  display: grid;
  place-items: center;
  border-radius: 9px;
  background: #e4f8f1;
  color: #07875f;
  font-weight: 850;
}

body.portal-user .northpay-support-link small,
body.portal-user .northpay-support-link b,
body.portal-user .northpay-user-profile small,
body.portal-user .northpay-user-profile b {
  display: block;
  line-height: 1.2;
}

body.portal-user .northpay-support-link small,
body.portal-user .northpay-user-profile small {
  color: #8a829a;
  font-size: 8px;
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
}

body.portal-user .northpay-support-link b,
body.portal-user .northpay-user-profile b {
  margin-top: 3px;
  font-size: 11px;
  font-weight: 750;
}

body.portal-user .northpay-user-profile {
  gap: 8px;
  max-width: 150px;
  padding: 5px 10px 5px 5px;
}

body.portal-user .northpay-user-profile > span:last-child {
  min-width: 0;
}

body.portal-user .northpay-user-profile b {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.portal-user .northpay-user-avatar {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  flex: 0 0 32px;
  border-radius: 10px;
  background: linear-gradient(145deg, var(--np-purple-700), var(--np-blue-600));
  color: #fff;
  font-size: 13px;
  font-weight: 850;
  text-transform: uppercase;
}

body.portal-user .northpay-logout-form {
  margin: 0;
}

body.portal-user .northpay-logout-form button {
  min-width: 43px;
  justify-content: center;
  gap: 6px;
  padding: 7px 11px;
  color: #746c83;
  font-size: 15px;
}

body.portal-user .northpay-logout-form button span {
  display: none;
  font-size: 11px;
  font-weight: 700;
}

body.portal-user .northpay-support-link:hover,
body.portal-user .northpay-user-profile:hover,
body.portal-user .northpay-logout-form button:hover {
  border-color: #d4c9ec;
  background: var(--np-purple-50);
  transform: translateY(-1px);
}

body.portal-user .northpay-menu-toggle,
body.portal-user .northpay-user-backdrop {
  display: none;
}

/* Existing pages now sit below the user-only top navigation. */
body.portal-user .main {
  width: 100%;
  max-width: 1680px;
  min-height: 100vh;
  margin: 0 auto;
  padding: 104px clamp(20px, 3vw, 48px) 70px;
}

body.portal-user .main > header {
  position: sticky;
  top: 76px;
  z-index: 80;
  margin: -28px calc(clamp(20px, 3vw, 48px) * -1) 28px;
  padding: 16px clamp(20px, 3vw, 48px);
  border-bottom: 1px solid rgba(64, 34, 113, .1);
  background: rgba(246, 245, 250, .93);
  box-shadow: none;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

body.portal-user .main > header::after {
  display: none;
}

body.portal-user .main > header .header-greeting {
  color: var(--np-purple-600);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .08em;
}

body.portal-user .main > header h1 {
  color: var(--np-ink);
  font-size: clamp(23px, 2vw, 30px);
  font-weight: 780;
  letter-spacing: -.045em;
}

body.portal-user .main > header .header-actions {
  gap: 10px;
}

body.portal-user .header-profile {
  display: none;
}

body.portal-user .wallet-strip {
  border: 1px solid #e3deed;
  border-radius: 13px;
  background: rgba(255, 255, 255, .9);
  box-shadow: 0 7px 22px rgba(48, 20, 98, .055);
}

body.portal-user .wallet-strip > div {
  min-width: 126px;
  padding: 8px 14px;
  border-color: #ece7f3;
}

body.portal-user .wallet-strip small {
  color: #837b91;
  font-size: 8px;
  font-weight: 750;
  letter-spacing: .08em;
}

body.portal-user .wallet-strip strong {
  color: var(--np-ink) !important;
  font-size: 14px;
  font-weight: 780;
}

body.portal-user .request-console,
body.portal-user .docs-nav {
  top: 168px;
}

body.portal-user .request-console {
  height: calc(100vh - 188px);
}

/* Premium dashboard */
body.portal-user .np-dashboard {
  display: grid;
  gap: 20px;
}

body.portal-user .np-dashboard-hero {
  position: relative;
  min-height: 320px;
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(330px, .75fr);
  align-items: center;
  gap: clamp(34px, 5vw, 80px);
  overflow: hidden;
  padding: clamp(32px, 4.2vw, 58px);
  border: 1px solid rgba(91, 43, 210, .12);
  border-radius: 28px;
  background:
    radial-gradient(circle at 78% 12%, rgba(25, 159, 255, .2), transparent 18rem),
    radial-gradient(circle at 5% 110%, rgba(114, 58, 244, .18), transparent 25rem),
    linear-gradient(120deg, #fff 0%, #faf7ff 50%, #edf6ff 100%);
  box-shadow: 0 25px 70px rgba(49, 21, 104, .1);
}

body.portal-user .np-dashboard-hero::before,
body.portal-user .np-dashboard-hero::after {
  content: "";
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
}

body.portal-user .np-dashboard-hero::before {
  width: 420px;
  height: 420px;
  right: -190px;
  bottom: -270px;
  border: 1px solid rgba(66, 31, 153, .1);
  box-shadow: 0 0 0 55px rgba(77, 35, 180, .028), 0 0 0 110px rgba(7, 132, 255, .025);
}

body.portal-user .np-dashboard-hero::after {
  width: 120px;
  height: 120px;
  top: -75px;
  left: 44%;
  background: linear-gradient(145deg, rgba(95, 44, 224, .13), rgba(7, 132, 255, .08));
  filter: blur(2px);
}

body.portal-user .np-dashboard-hero-copy,
body.portal-user .np-route-card {
  position: relative;
  z-index: 1;
}

body.portal-user .np-live-status {
  width: fit-content;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 10px;
  border: 1px solid #d8d0e9;
  border-radius: 999px;
  background: rgba(255, 255, 255, .72);
  color: #655e74;
  font-size: 10px;
  font-weight: 750;
}

body.portal-user .np-live-status i,
body.portal-user .np-route-card-head i,
body.portal-user .np-chart-summary > span i {
  width: 7px;
  height: 7px;
  display: inline-block;
  border-radius: 50%;
  background: currentColor;
}

body.portal-user .np-live-status.is-ready {
  border-color: #c9eadf;
  color: #087959;
}

body.portal-user .np-live-status.needs-attention {
  border-color: #efdcae;
  color: #9a620c;
}

body.portal-user .np-overline {
  margin: 24px 0 8px;
  color: var(--np-purple-600);
  font-size: 10px;
  font-weight: 850;
  letter-spacing: .15em;
}

body.portal-user .np-dashboard-hero h2 {
  margin: 0;
  color: var(--np-purple-950);
  font-size: clamp(32px, 4vw, 55px);
  font-weight: 830;
  line-height: 1.02;
  letter-spacing: -.06em;
}

body.portal-user .np-dashboard-hero h2 span {
  background: linear-gradient(90deg, var(--np-purple-600), var(--np-blue-600));
  background-clip: text;
  -webkit-background-clip: text;
  color: transparent;
}

body.portal-user .np-dashboard-intro {
  max-width: 660px;
  margin: 18px 0 0;
  color: #6b6579;
  font-size: 14px;
  line-height: 1.7;
}

body.portal-user .np-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 27px;
}

body.portal-user .np-button {
  min-height: 45px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  padding: 11px 17px;
  border: 1px solid transparent;
  border-radius: 12px;
  text-decoration: none;
  font-size: 12px;
  font-weight: 780;
  transition: transform .18s ease, box-shadow .18s ease, background .18s ease;
}

body.portal-user .np-button:hover {
  transform: translateY(-2px);
}

body.portal-user .np-button-primary {
  background: linear-gradient(115deg, var(--np-purple-700), var(--np-purple-600) 50%, var(--np-blue-600));
  box-shadow: 0 12px 28px rgba(80, 32, 190, .22);
  color: #fff;
}

body.portal-user .np-button-primary:hover {
  box-shadow: 0 16px 34px rgba(80, 32, 190, .29);
}

body.portal-user .np-button-ghost {
  border-color: #d9d0e9;
  background: rgba(255, 255, 255, .75);
  color: var(--np-purple-800);
}

body.portal-user .np-button-ghost:hover {
  background: #fff;
}

body.portal-user .np-route-card {
  padding: 22px;
  border: 1px solid rgba(78, 32, 177, .14);
  border-radius: 22px;
  background: rgba(255, 255, 255, .78);
  box-shadow: 0 22px 55px rgba(47, 17, 110, .1);
  backdrop-filter: blur(14px);
}

body.portal-user .np-route-card-head,
body.portal-user .np-route-score,
body.portal-user .np-route-meta {
  display: flex;
  align-items: center;
}

body.portal-user .np-route-card-head {
  justify-content: space-between;
  padding-bottom: 17px;
  border-bottom: 1px solid #ebe5f3;
}

body.portal-user .np-route-card-head span {
  display: flex;
  align-items: center;
  gap: 7px;
  color: #7a7189;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: .12em;
}

body.portal-user .np-route-card-head span i {
  color: var(--np-green);
  box-shadow: 0 0 0 5px rgba(10, 167, 122, .1);
}

body.portal-user .np-route-card-head b {
  padding: 5px 8px;
  border-radius: 999px;
  background: #e5f8f1;
  color: #087959;
  font-size: 8px;
  letter-spacing: .08em;
}

body.portal-user .np-route-score {
  gap: 18px;
  padding: 24px 0;
}

body.portal-user .np-score-ring {
  --success-rate: 0;
  position: relative;
  width: 82px;
  height: 82px;
  display: grid;
  place-items: center;
  flex: 0 0 82px;
  border-radius: 50%;
  background: conic-gradient(var(--np-blue-600) calc(var(--success-rate) * 1%), #e9e4f1 0);
}

body.portal-user .np-score-ring::before {
  content: "";
  position: absolute;
  inset: 7px;
  border-radius: 50%;
  background: #fff;
}

body.portal-user .np-score-ring span {
  position: relative;
  z-index: 1;
  color: var(--np-purple-900);
}

body.portal-user .np-score-ring b {
  font-size: 21px;
  font-weight: 850;
}

body.portal-user .np-score-ring small {
  font-size: 9px;
  font-weight: 800;
}

body.portal-user .np-route-score > div:last-child {
  min-width: 0;
}

body.portal-user .np-route-score > div:last-child > small {
  color: #877f94;
  font-size: 8px;
  font-weight: 800;
  letter-spacing: .1em;
}

body.portal-user .np-route-score strong,
body.portal-user .np-route-score p {
  display: block;
}

body.portal-user .np-route-score strong {
  margin-top: 6px;
  overflow: hidden;
  color: var(--np-ink);
  font-size: 14px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.portal-user .np-route-score p {
  margin: 5px 0 0;
  color: #797287;
  font-size: 10px;
  line-height: 1.45;
}

body.portal-user .np-route-meta {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border-top: 1px solid #ebe5f3;
}

body.portal-user .np-route-meta span {
  min-width: 0;
  padding: 16px 12px 0 0;
}

body.portal-user .np-route-meta span + span {
  padding-left: 16px;
  border-left: 1px solid #ebe5f3;
}

body.portal-user .np-route-meta small,
body.portal-user .np-route-meta b {
  display: block;
}

body.portal-user .np-route-meta small {
  color: #938a9f;
  font-size: 8px;
  font-weight: 800;
  letter-spacing: .09em;
}

body.portal-user .np-route-meta b {
  margin-top: 4px;
  overflow: hidden;
  color: #3d3650;
  font-size: 10px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.portal-user .np-metric-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 15px;
}

body.portal-user .np-metric-card {
  position: relative;
  min-width: 0;
  display: flex;
  align-items: flex-start;
  gap: 13px;
  overflow: hidden;
  padding: 21px;
  border: 1px solid var(--np-line);
  border-radius: 18px;
  background: #fff;
  box-shadow: var(--np-shadow-sm);
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}

body.portal-user .np-metric-card:hover {
  border-color: #d6cce9;
  box-shadow: var(--np-shadow-md);
  transform: translateY(-2px);
}

body.portal-user .np-metric-card > div {
  min-width: 0;
}

body.portal-user .np-metric-icon {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  flex: 0 0 42px;
  border-radius: 13px;
  font-size: 16px;
  font-weight: 850;
}

body.portal-user .np-metric-icon.is-blue { background: var(--np-blue-100); color: var(--np-blue-700); }
body.portal-user .np-metric-icon.is-green { background: #e4f8f1; color: #08805e; }
body.portal-user .np-metric-icon.is-amber { background: #fff3dd; color: #b6720b; }
body.portal-user .np-metric-icon.is-purple { background: var(--np-purple-100); color: var(--np-purple-700); }

body.portal-user .np-metric-card small,
body.portal-user .np-metric-card strong,
body.portal-user .np-metric-card p {
  display: block;
}

body.portal-user .np-metric-card small {
  color: #8d8499;
  font-size: 8px;
  font-weight: 820;
  letter-spacing: .08em;
}

body.portal-user .np-metric-card strong {
  margin-top: 5px;
  overflow: hidden;
  color: var(--np-ink);
  font-size: clamp(17px, 1.65vw, 23px);
  font-weight: 820;
  letter-spacing: -.04em;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.portal-user .np-metric-card p {
  margin: 4px 0 0;
  color: #8b8495;
  font-size: 9px;
  line-height: 1.4;
}

body.portal-user .np-metric-accent {
  position: absolute;
  width: 45px;
  height: 45px;
  right: -23px;
  bottom: -23px;
  border: 8px solid var(--np-purple-100);
  border-radius: 50%;
  opacity: .7;
}

body.portal-user .np-dashboard-primary-grid,
body.portal-user .np-dashboard-secondary-grid {
  display: grid;
  gap: 20px;
}

body.portal-user .np-dashboard-primary-grid {
  grid-template-columns: minmax(0, 1.55fr) minmax(300px, .65fr);
}

body.portal-user .np-dashboard-secondary-grid {
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
}

body.portal-user .np-dashboard-card {
  min-width: 0;
  padding: 25px;
  border: 1px solid var(--np-line);
  border-radius: 20px;
  background: #fff;
  box-shadow: var(--np-shadow-sm);
}

body.portal-user .np-card-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
}

body.portal-user .np-card-heading small {
  color: #8b8298;
  font-size: 8px;
  font-weight: 820;
  letter-spacing: .11em;
}

body.portal-user .np-card-heading h3 {
  margin: 5px 0 0;
  color: var(--np-ink);
  font-size: 18px;
  font-weight: 780;
  letter-spacing: -.035em;
}

body.portal-user .np-card-heading > a,
body.portal-user .np-card-link {
  color: var(--np-blue-700);
  text-decoration: none;
  font-size: 10px;
  font-weight: 780;
  white-space: nowrap;
}

body.portal-user .np-chart-summary {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin-top: 20px;
}

body.portal-user .np-chart-summary small,
body.portal-user .np-chart-summary strong {
  display: block;
}

body.portal-user .np-chart-summary small {
  color: #948ca0;
  font-size: 8px;
  font-weight: 800;
  letter-spacing: .08em;
}

body.portal-user .np-chart-summary strong {
  margin-top: 4px;
  color: var(--np-purple-900);
  font-size: 23px;
  font-weight: 830;
  letter-spacing: -.04em;
}

body.portal-user .np-chart-summary > span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: #857c92;
  font-size: 9px;
}

body.portal-user .np-chart-summary > span i {
  color: var(--np-blue-600);
}

body.portal-user .np-bar-chart {
  height: 205px;
  display: flex;
  align-items: stretch;
  gap: clamp(7px, 1.4vw, 17px);
  margin-top: 15px;
  padding-top: 10px;
  border-bottom: 1px solid #e8e3ef;
  background-image: repeating-linear-gradient(to bottom, transparent 0, transparent 49px, rgba(63, 33, 112, .06) 50px);
}

body.portal-user .np-bar-column {
  min-width: 0;
  display: grid;
  grid-template-rows: 22px minmax(0, 1fr) 28px;
  flex: 1;
  text-align: center;
}

body.portal-user .np-bar-column > span {
  overflow: hidden;
  color: #8e859a;
  font-size: 7px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.portal-user .np-bar-track {
  display: flex;
  align-items: flex-end;
  justify-content: center;
}

body.portal-user .np-bar-track i {
  width: min(39px, 72%);
  min-height: 5px;
  display: block;
  border-radius: 8px 8px 3px 3px;
  background: linear-gradient(180deg, var(--np-blue-500), var(--np-purple-600));
  box-shadow: 0 8px 20px rgba(56, 57, 204, .18);
  transition: filter .18s ease, transform .18s ease;
}

body.portal-user .np-bar-column:hover .np-bar-track i {
  filter: saturate(1.25);
  transform: scaleX(1.08);
}

body.portal-user .np-bar-column > small {
  padding-top: 8px;
  color: #81798d;
  font-size: 9px;
  font-weight: 720;
}

body.portal-user .np-cycle-badge,
body.portal-user .np-health-badge {
  padding: 6px 9px;
  border-radius: 999px;
  font-size: 8px;
  font-weight: 820;
  white-space: nowrap;
}

body.portal-user .np-cycle-badge {
  background: var(--np-purple-100);
  color: var(--np-purple-700);
}

body.portal-user .np-health-badge.is-ready {
  background: #e4f8f1;
  color: #087959;
}

body.portal-user .np-health-badge.needs-attention {
  background: #fff3dd;
  color: #9e640d;
}

body.portal-user .np-balance-focus {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 21px 0 9px;
  padding: 17px;
  border: 1px solid #e4dcf2;
  border-radius: 15px;
  background: linear-gradient(115deg, var(--np-purple-50), #eef7ff);
}

body.portal-user .np-wallet-glyph {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  flex: 0 0 42px;
  border-radius: 13px;
  background: linear-gradient(145deg, var(--np-purple-700), var(--np-blue-600));
  color: #fff;
  font-size: 18px;
}

body.portal-user .np-balance-focus small,
body.portal-user .np-balance-focus strong {
  display: block;
}

body.portal-user .np-balance-focus small {
  color: #81768f;
  font-size: 8px;
  font-weight: 800;
  letter-spacing: .08em;
}

body.portal-user .np-balance-focus strong {
  margin-top: 4px;
  color: var(--np-purple-900);
  font-size: 21px;
  font-weight: 830;
}

body.portal-user .np-fund-list > div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 13px 3px;
  border-bottom: 1px solid #eeeaf3;
  color: #6f687c;
  font-size: 11px;
}

body.portal-user .np-fund-list span {
  display: flex;
  align-items: center;
  gap: 9px;
}

body.portal-user .np-fund-list span i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
}

body.portal-user .np-fund-list span i.is-blue { background: var(--np-blue-600); }
body.portal-user .np-fund-list span i.is-amber { background: var(--np-amber); }
body.portal-user .np-fund-list span i.is-red { background: var(--np-red); }
body.portal-user .np-fund-list strong { color: #3b3549; font-size: 11px; }

body.portal-user .np-card-link {
  display: inline-flex;
  gap: 10px;
  margin-top: 17px;
}

body.portal-user .np-integration-list {
  margin-top: 15px;
}

body.portal-user .np-integration-list > div {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 13px 0;
  border-top: 1px solid #eeeaf3;
}

body.portal-user .np-integration-icon {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  flex: 0 0 38px;
  border-radius: 11px;
  background: linear-gradient(140deg, var(--np-purple-100), var(--np-blue-100));
  color: var(--np-purple-700);
  font-size: 12px;
  font-weight: 800;
}

body.portal-user .np-integration-list > div > div {
  min-width: 0;
  flex: 1;
}

body.portal-user .np-integration-list strong,
body.portal-user .np-integration-list small {
  display: block;
}

body.portal-user .np-integration-list strong {
  color: #393348;
  font-size: 11px;
}

body.portal-user .np-integration-list small {
  margin-top: 3px;
  overflow: hidden;
  color: #8b8495;
  font-size: 9px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.portal-user .np-integration-list > div > b,
body.portal-user .np-integration-list > div > a {
  font-size: 9px;
  font-weight: 780;
  text-decoration: none;
}

body.portal-user .np-integration-list .is-ready { color: #07825e; }
body.portal-user .np-integration-list .needs-attention { color: #aa6a0c; }
body.portal-user .np-integration-list > div > a { color: var(--np-blue-700); }

body.portal-user .np-quick-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 17px;
}

body.portal-user .np-quick-grid > a {
  position: relative;
  min-width: 0;
  display: grid;
  grid-template-columns: 36px minmax(0, 1fr) 18px;
  grid-template-rows: auto auto;
  align-items: center;
  gap: 2px 10px;
  padding: 13px;
  border: 1px solid #e9e4f0;
  border-radius: 14px;
  background: #fbfaff;
  color: var(--np-ink);
  text-decoration: none;
  transition: border-color .18s ease, background .18s ease, transform .18s ease;
}

body.portal-user .np-quick-grid > a:hover {
  border-color: #d9ccec;
  background: linear-gradient(125deg, var(--np-purple-50), #f0f8ff);
  transform: translateY(-2px);
}

body.portal-user .np-quick-grid > a > span {
  width: 36px;
  height: 36px;
  grid-row: 1 / 3;
  display: grid;
  place-items: center;
  border-radius: 11px;
  background: #fff;
  box-shadow: inset 0 0 0 1px #e5dff0;
  color: var(--np-purple-700);
  font-size: 13px;
  font-weight: 800;
}

body.portal-user .np-quick-grid b {
  overflow: hidden;
  font-size: 10px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.portal-user .np-quick-grid small {
  overflow: hidden;
  color: #91899c;
  font-size: 8px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

body.portal-user .np-quick-grid i {
  grid-column: 3;
  grid-row: 1 / 3;
  color: var(--np-blue-600);
  font-size: 14px;
  font-style: normal;
}

@keyframes np-menu-in {
  from { opacity: 0; transform: translate(-50%, -5px); }
  to { opacity: 1; transform: translate(-50%, 0); }
}

@media (max-width: 1320px) {
  body.portal-user .northpay-support-link > span:last-child,
  body.portal-user .northpay-user-profile > span:last-child {
    display: none;
  }
  body.portal-user .northpay-support-link,
  body.portal-user .northpay-user-profile { padding-right: 5px; }
  body.portal-user .northpay-user-nav > a,
  body.portal-user .northpay-user-nav .nav-parent { padding-inline: 9px; }
}

@media (max-width: 1100px) {
  body.portal-user .northpay-user-bar { gap: 13px; padding-inline: 16px; }
  body.portal-user .northpay-wordmark { width: 140px; height: 47px; }
  body.portal-user .northpay-user-drawer { gap: 10px; }
  body.portal-user .northpay-user-nav > a,
  body.portal-user .northpay-user-nav .nav-parent { min-height: 39px; padding: 9px 7px; font-size: 11px; }
  body.portal-user .northpay-user-nav > a:first-child b { font-size: 11px; }
  body.portal-user .np-metric-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  body.portal-user .np-dashboard-primary-grid { grid-template-columns: minmax(0, 1.2fr) minmax(285px, .8fr); }
  body.portal-user .request-console { top: 0; height: auto; }
  body.portal-user .docs-nav { top: 0; }
}

@media (max-width: 880px) and (min-width: 701px) {
  body.portal-user .northpay-wordmark { width: 112px; height: 38px; }
  body.portal-user .northpay-user-nav > a,
  body.portal-user .northpay-user-nav .nav-parent { padding-inline: 6px; font-size: 10px; }
  body.portal-user .northpay-user-nav > a:first-child b { font-size: 10px; }
  body.portal-user .northpay-user-tools { gap: 4px; }
  body.portal-user .northpay-support-link { display: none; }
  body.portal-user .northpay-user-profile,
  body.portal-user .northpay-logout-form button { min-height: 38px; min-width: 38px; }
  body.portal-user .np-dashboard-hero { grid-template-columns: 1fr; }
  body.portal-user .np-route-card { width: 100%; max-width: 520px; }
  body.portal-user .np-dashboard-primary-grid,
  body.portal-user .np-dashboard-secondary-grid { grid-template-columns: 1fr; }
}

@media (max-width: 700px) {
  body.portal-user .northpay-user-header { min-height: 68px; }
  body.portal-user .northpay-user-bar { min-height: 68px; justify-content: space-between; padding: 8px 15px; }
  body.portal-user .northpay-wordmark { width: 145px; height: 48px; }
  body.portal-user .northpay-menu-toggle {
    min-height: 41px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 11px;
    border: 1px solid #ded5ec;
    border-radius: 11px;
    background: var(--np-purple-50);
    color: var(--np-purple-800);
    font-size: 11px;
    font-weight: 760;
  }
  body.portal-user .northpay-menu-toggle .menu-mark { width: 16px; display: grid; gap: 3px; }
  body.portal-user .northpay-menu-toggle .menu-mark i { width: 16px; height: 2px; display: block; border-radius: 2px; background: currentColor; }
  body.portal-user .northpay-user-drawer {
    position: fixed;
    top: 68px;
    right: 0;
    bottom: auto;
    height: calc(100vh - 68px);
    height: calc(100dvh - 68px);
    z-index: 221;
    width: min(365px, 92vw);
    display: flex;
    align-items: stretch;
    flex-direction: column;
    gap: 18px;
    padding: 18px 16px 24px;
    overflow-y: auto;
    background: #fff;
    box-shadow: -20px 0 45px rgba(31, 12, 70, .18);
    visibility: hidden;
    transform: translateX(105%);
    transition: transform .22s ease, visibility .22s ease;
  }
  body.portal-user.mobile-nav-open .northpay-user-drawer { visibility: visible; transform: translateX(0); }
  body.portal-user .northpay-user-nav {
    display: grid;
    align-content: start;
    justify-content: stretch;
    gap: 5px;
  }
  body.portal-user .northpay-user-nav > a,
  body.portal-user .northpay-user-nav .nav-parent {
    width: 100%;
    min-height: 45px;
    justify-content: flex-start;
    padding: 11px 13px;
    border-radius: 11px;
    font-size: 12px;
  }
  body.portal-user .northpay-user-nav > a:first-child b { font-size: 12px; }
  body.portal-user .northpay-user-nav .nav-chevron { margin-left: auto; }
  body.portal-user .northpay-user-nav .nav-group.open > .nav-parent .nav-chevron,
  body.portal-user .northpay-user-nav .nav-group.user-nav-open > .nav-parent .nav-chevron { transform: rotate(180deg); }
  body.portal-user .northpay-user-nav .nav-group::after { display: none; }
  body.portal-user .northpay-user-nav .nav-submenu {
    position: static;
    width: auto;
    min-width: 0;
    margin: 3px 0 6px 17px;
    padding: 4px 0 4px 12px;
    border: 0;
    border-left: 1px solid #dfd5ee;
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    transform: none;
  }
  body.portal-user .northpay-user-nav .nav-group:hover > .nav-submenu,
  body.portal-user .northpay-user-nav .nav-group:focus-within > .nav-submenu { display: none; animation: none; }
  body.portal-user .northpay-user-nav .nav-group.open > .nav-submenu,
  body.portal-user .northpay-user-nav .nav-group.user-nav-open > .nav-submenu,
  body.portal-user .northpay-user-nav .nav-parent:not(button) + .nav-submenu,
  body.portal-user .northpay-user-nav .northpay-doc-focus + .nav-submenu { display: grid; animation: none; }
  body.portal-user .northpay-user-nav .sub-link { min-height: 39px; padding: 9px 11px; }
  body.portal-user .northpay-user-tools {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 8px;
    margin-top: auto;
    padding-top: 16px;
    border-top: 1px solid #eae5f0;
  }
  body.portal-user .northpay-support-link { grid-column: 1 / -1; }
  body.portal-user .northpay-support-link > span:last-child,
  body.portal-user .northpay-user-profile > span:last-child { display: block; }
  body.portal-user .northpay-user-profile { max-width: none; padding-right: 11px; }
  body.portal-user .northpay-logout-form button { min-width: 45px; }
  body.portal-user .northpay-user-backdrop {
    position: fixed;
    inset: 68px 0 0;
    /* Keep the scrim below the header's stacking context so the drawer,
       which lives inside that header, remains visible and interactive. */
    z-index: 190;
    width: 100%;
    border: 0;
    background: rgba(20, 8, 45, .56);
    backdrop-filter: blur(2px);
  }
  body.portal-user.mobile-nav-open .northpay-user-backdrop { display: block; }
  body.portal-user.mobile-nav-open { overflow: hidden; }
  body.portal-user .main { padding: 94px 15px 46px; }
  body.portal-user .main > header {
    top: 68px;
    display: block;
    margin: -18px -15px 22px;
    padding: 14px 15px;
  }
  body.portal-user .main > header .header-actions { width: 100%; margin-top: 12px; }
  body.portal-user .wallet-strip { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); width: 100%; }
  body.portal-user .wallet-strip > div { min-width: 0; padding: 9px 10px; }
  body.portal-user .wallet-strip > div:nth-child(n+3) { border-top: 1px solid #ece7f3; }
  body.portal-user .wallet-strip > div:nth-child(odd) { border-left: 0; }
  body.portal-user .np-dashboard { gap: 15px; }
  body.portal-user .np-dashboard-hero { min-height: 0; grid-template-columns: 1fr; gap: 25px; padding: 25px 21px; border-radius: 21px; }
  body.portal-user .np-dashboard-hero h2 { font-size: clamp(30px, 10vw, 42px); }
  body.portal-user .np-dashboard-intro { font-size: 12px; }
  body.portal-user .np-route-card { padding: 18px; border-radius: 17px; }
  body.portal-user .np-route-score { gap: 14px; }
  body.portal-user .np-score-ring { width: 70px; height: 70px; flex-basis: 70px; }
  body.portal-user .np-metric-grid,
  body.portal-user .np-dashboard-primary-grid,
  body.portal-user .np-dashboard-secondary-grid { grid-template-columns: 1fr; gap: 13px; }
  body.portal-user .np-dashboard-card { padding: 19px; border-radius: 17px; }
  body.portal-user .np-metric-card { padding: 18px; }
  body.portal-user .np-quick-grid { grid-template-columns: 1fr; }
  body.portal-user .np-bar-chart { height: 180px; gap: 5px; }
  body.portal-user .np-bar-column > span { font-size: 6px; }
}

@media (max-width: 430px) {
  body.portal-user .northpay-wordmark { width: 132px; height: 44px; }
  body.portal-user .northpay-menu-toggle > span:last-child { display: none; }
  body.portal-user .northpay-menu-toggle { width: 42px; justify-content: center; padding: 8px; }
  body.portal-user .np-hero-actions { display: grid; }
  body.portal-user .np-button { width: 100%; }
  body.portal-user .np-card-heading { align-items: flex-start; }
  body.portal-user .np-card-heading > a { white-space: normal; text-align: right; }
  body.portal-user .np-chart-summary { align-items: flex-start; flex-direction: column; }
  body.portal-user .np-route-meta { grid-template-columns: 1fr; }
  body.portal-user .np-route-meta span + span { margin-top: 12px; padding: 12px 0 0; border-top: 1px solid #ebe5f3; border-left: 0; }
}

@media (prefers-reduced-motion: reduce) {
  body.portal-user .northpay-user-drawer,
  body.portal-user .np-button,
  body.portal-user .np-metric-card,
  body.portal-user .np-quick-grid > a,
  body.portal-user .np-bar-track i { transition: none; }
  body.portal-user .northpay-user-nav .nav-submenu { animation: none !important; }
}
