:root {
  color-scheme: light;
  --ink: #070707;
  --muted: #6b6b6b;
  --line: #e4e4e4;
  --paper: #f3f3f3;
  --surface: #ffffff;
  --teal: #0b0b0b;
  --teal-dark: #000000;
  --mint: #f7f7f7;
  --charcoal: #060606;
  --charcoal-soft: #171717;
  --red: #b42318;
  --gold: #111111;
  --gold-dark: #000000;
  --shadow: 0 22px 52px rgba(0, 0, 0, 0.12);
  --button-shadow: 0 14px 30px rgba(0, 0, 0, 0.18);
}

body.crm-shell-body .crm-page .top-actions::before,
body.crm-shell-body .crm-page .client-list::before {
  content: none !important;
  display: none !important;
}

body.crm-shell-body .crm-manager-create-form {
  grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  align-items: end !important;
  gap: 12px !important;
  padding: 16px !important;
  border-color: rgba(167, 139, 250, .22) !important;
  background: linear-gradient(145deg, rgba(14, 22, 45, .84), rgba(35, 29, 70, .62)) !important;
}

body.crm-shell-body .crm-manager-create-form label {
  min-width: 0 !important;
  color: rgba(237, 233, 254, .82) !important;
  font-size: .74rem !important;
  font-weight: 900 !important;
}

body.crm-shell-body .crm-manager-create-form input,
body.crm-shell-body .crm-manager-create-form select {
  width: 100% !important;
  min-height: 44px !important;
  border: 1px solid rgba(148, 163, 184, .22) !important;
  border-radius: 10px !important;
  background: rgba(2, 6, 23, .48) !important;
  color: #fff !important;
  padding: 0 12px !important;
  font-weight: 850 !important;
}

body.crm-shell-body .crm-manager-create-form select option {
  background: #111827 !important;
  color: #fff !important;
}

body.crm-shell-body .crm-manager-create-form button {
  grid-column: auto !important;
  min-height: 44px !important;
  border: 0 !important;
  border-radius: 10px !important;
  background: linear-gradient(135deg, #4f8cff, #8b5cf6) !important;
  color: #fff !important;
  font-size: .82rem !important;
  font-weight: 950 !important;
  box-shadow: 0 14px 30px rgba(79, 140, 255, .18) !important;
}

body.crm-shell-body .crm-pane#profile,
body.crm-shell-body .crm-pane#profile .panel-title h2,
body.crm-shell-body .crm-pane#profile .panel-title span,
body.crm-shell-body .crm-pane#profile .session-row,
body.crm-shell-body .crm-pane#profile .session-row b,
body.crm-shell-body .crm-pane#profile .session-row small {
  color: #fff !important;
}

body.crm-shell-body .crm-pane#profile .session-row p {
  color: rgba(237, 233, 254, .72) !important;
  word-break: break-word !important;
}

body.crm-shell-body .secure-task-overlay {
  background: rgba(3, 7, 18, .68) !important;
  backdrop-filter: blur(18px) !important;
}

body.crm-shell-body .secure-task-modal {
  border: 1px solid rgba(167, 139, 250, .24) !important;
  background:
    radial-gradient(circle at 12% 0%, rgba(79, 140, 255, .22), transparent 34%),
    linear-gradient(145deg, rgba(10, 16, 34, .98), rgba(31, 24, 62, .98)) !important;
  color: #fff !important;
}

body.crm-shell-body .secure-task-head h2,
body.crm-shell-body .secure-task-fields label,
body.crm-shell-body .secure-task-field {
  color: #fff !important;
}

body.crm-shell-body .secure-task-head p,
body.crm-shell-body .secure-task-head span {
  color: rgba(237, 233, 254, .78) !important;
}

body.crm-shell-body .secure-task-fields input,
body.crm-shell-body .secure-task-fields select {
  border-color: rgba(148, 163, 184, .28) !important;
  background: rgba(2, 6, 23, .5) !important;
  color: #fff !important;
}

body.crm-shell-body .secure-task-close,
body.crm-shell-body .secure-task-cancel {
  background: rgba(255, 255, 255, .08) !important;
  color: #fff !important;
}

@media (max-width: 1080px) {
  body.crm-shell-body .crm-manager-create-form {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }

  body.crm-shell-body .crm-manager-create-form button {
    grid-column: 1 / -1 !important;
  }
}

/* Final interaction overrides. */
.toast {
  top: 18px;
  right: 18px;
  bottom: auto;
  border: 1px solid rgba(121, 85, 255, 0.24);
  border-radius: 14px;
  background: linear-gradient(135deg, #1f1b46, #33256f);
  color: #fff;
  box-shadow: 0 18px 44px rgba(62, 47, 142, 0.28);
  transform: translateY(-18px);
  z-index: 1200;
}

.toast.visible {
  transform: translateY(0);
}

.task-screen.hidden,
.crypto-task-panel {
  display: none;
}

.crypto-task-panel.active {
  display: grid;
  gap: 12px;
}

.task-exit-button {
  justify-self: start;
  border: 1px solid rgba(255,255,255,0.14);
  border-radius: 10px;
  background: rgba(255,255,255,0.06);
  color: inherit;
  padding: 9px 12px;
}

.task-focus-head {
  border: 1px solid rgba(79,140,255,0.22);
  border-radius: 14px;
  background: rgba(79,140,255,0.08);
  padding: 12px 14px;
}

.task-focus-head span {
  display: block;
  color: var(--muted);
  font-size: 11px;
}

.task-focus-head b {
  display: block;
  margin-top: 4px;
  font-size: 15px;
}

body.app-task-focus .mobile-product .client-header,
body.app-task-focus .mobile-product .bottom-tabs,
body.app-task-focus .mobile-product .transfer-mode-tabs,
body.app-task-focus .mobile-product .crypto-wallet-card,
body.app-task-focus .mobile-product .crypto-task-panel:not(.active) {
  display: none !important;
}

body.app-task-focus .mobile-product #crypto.mobile-screen.active {
  display: grid;
  min-height: 100vh;
  align-content: start;
}

.local-pin-control {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  width: min(260px, 100%);
}

.local-pin-control input,
.local-pin-control button {
  min-height: 42px;
  border-radius: 8px;
}

.local-pin-control input {
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink);
  font-size: 1.05rem;
  font-weight: 900;
  letter-spacing: 0;
  text-align: center;
}

.local-pin-control button {
  border: 0;
  padding: 0 14px;
  background: linear-gradient(135deg, #7c3aed, #a855f7);
  color: #fff;
  font-weight: 900;
  box-shadow: 0 12px 26px rgba(124,58,237,0.22);
}

.secure-task-overlay {
  position: fixed;
  inset: 0;
  z-index: 2400;
  display: grid;
  place-items: center;
  padding: 22px;
  background: rgba(15, 15, 26, 0.54);
  backdrop-filter: blur(16px);
}

.secure-task-modal {
  width: min(380px, 100%);
  display: grid;
  gap: 14px;
  position: relative;
  padding: 22px;
  border: 1px solid rgba(255,255,255,0.18);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  box-shadow: 0 26px 70px rgba(0,0,0,0.32);
}

.secure-task-close {
  position: absolute;
  top: 10px;
  right: 10px;
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 50%;
  background: #f3f4f6;
  color: #111827;
  font-size: 1.1rem;
  font-weight: 900;
}

.secure-task-head {
  display: grid;
  gap: 5px;
  padding-right: 32px;
}

.secure-task-head span {
  width: max-content;
  padding: 4px 8px;
  border-radius: 999px;
  background: rgba(124,58,237,0.12);
  color: #6d28d9;
  font-size: 0.72rem;
  font-weight: 950;
}

.secure-task-head h2 {
  margin: 0;
  font-size: 1.25rem;
}

.secure-task-head p {
  margin: 0;
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 800;
}

.secure-task-fields {
  display: grid;
  gap: 10px;
}

.secure-task-fields label,
.secure-task-field {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 850;
}

.secure-task-fields input {
  width: 100%;
  min-height: 48px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #f9fafb;
  color: #111827;
  padding: 0 14px;
  font-size: 0.98rem;
  font-weight: 850;
  text-align: center;
}

.secure-task-submit,
.secure-task-cancel {
  min-height: 46px;
  border: 0;
  border-radius: 8px;
  font-weight: 950;
}

.secure-task-submit {
  background: linear-gradient(135deg, #7c3aed, #a855f7);
  color: #fff;
  box-shadow: 0 16px 30px rgba(124,58,237,0.24);
}

.secure-task-submit:disabled {
  opacity: 0.58;
}

.secure-task-cancel {
  background: #f3f4f6;
  color: #111827;
}

.local-pin-overlay {
  position: fixed;
  inset: 0;
  z-index: 2200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background:
    radial-gradient(circle at 50% 0, rgba(21, 60, 77, .9) 0, transparent 38%),
    linear-gradient(160deg, #091019, #0c1722 60%, #090b11);
  color: #f8fafc;
}

.local-pin-box {
  width: min(355px, 92vw);
  display: grid;
  justify-items: center;
  gap: 0;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  text-align: center;
}

.local-pin-logo {
  display: grid;
  place-items: center;
  width: 92px;
  height: 92px;
  margin: 0 auto 18px;
  border-radius: 28px;
  overflow: hidden;
  background: linear-gradient(145deg, #24c08b, #4f86f7);
  box-shadow: 0 18px 46px rgba(49, 94, 135, .5);
}

.local-pin-logo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.local-pin-box h2 {
  margin: 0;
  color: #f8fafc;
  font-size: 26px;
  font-weight: 950;
}

.local-pin-box p {
  margin: 7px 0 0;
  color: #8e9aac;
  font-size: 12px;
}

.local-pin-dots {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin: 24px;
}

.local-pin-dots i {
  width: 13px;
  height: 13px;
  border: 1px solid #557b76;
  border-radius: 50%;
  background: transparent;
}

.local-pin-dots i.on {
  background: #29d58a;
  border-color: #29d58a;
  box-shadow: 0 0 14px #29d58a;
}

.local-pin-keys {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  width: 100%;
}

.local-pin-keys button {
  min-height: 58px;
  border: 1px solid rgba(255, 255, 255, .09);
  border-radius: 18px;
  background: rgba(255, 255, 255, .045);
  color: #fff;
  font-size: 20px;
  font-weight: 900;
  cursor: pointer;
  touch-action: manipulation;
  transition: transform .16s ease, filter .16s ease, background .16s ease;
}

.local-pin-keys button:active {
  transform: scale(.985);
  filter: brightness(1.12);
}

.local-pin-error {
  min-height: 22px;
  margin-top: 12px;
  color: #ff7284;
  font-size: 11px;
}

body.crm-task-focus .crm-page .client-list,
body.crm-task-focus .crm-page .crm-nav,
body.crm-task-focus .crm-page .crm-top,
body.crm-task-focus .crm-page .crm-insight-grid,
body.crm-task-focus .crm-page .crm-chart-panel,
body.crm-task-focus .crm-page .comments-panel:not(:has(.crm-withdraw-form)),
body.crm-task-focus .crm-page #crmTransactionsList {
  display: none !important;
}

body.crm-task-focus .crm-page .client-detail {
  display: block !important;
  min-height: 100vh;
}

.crm-focus-panel {
  display: none;
}

body.crm-task-focus .crm-page .crm-focus-panel {
  display: grid;
  gap: 12px;
  margin-bottom: 14px;
}

.crm-task-head {
  margin-bottom: 12px;
}

.crm-login-panel {
  min-height: calc(100vh - 140px);
  display: grid;
  align-items: center;
}

.crm-login-shell {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(320px, .75fr);
  gap: 18px;
  width: min(980px, 100%);
  margin: 0 auto;
}

.crm-manager-form {
  display: grid;
}

#forgotTaskScreen,
#resetTaskScreen {
  grid-column: 2;
}

:root[data-theme="purple-dark"] .toast {
  border-color: rgba(139,92,246,0.35);
  background: linear-gradient(135deg, #151f30, #2d1f63);
  color: #fff;
}

/* Last-mile overrides: keep CRM desktop shell and client modal above legacy theme blocks. */
@media (min-width: 901px) {
  body.crm-shell-body .crm-page {
    display: grid !important;
    grid-template-columns: 276px minmax(0, 1fr) !important;
    padding: 0 !important;
    max-width: none !important;
  }

  body.crm-shell-body .crm-page .topbar {
    position: sticky !important;
    top: 0 !important;
    width: 276px !important;
    height: 100vh !important;
    display: grid !important;
    align-content: start !important;
    border-right: 1px solid rgba(255,255,255,.08) !important;
    border-radius: 0 !important;
  }

  body.crm-shell-body .crm-page #crm {
    grid-column: 2 !important;
    padding: 28px 32px !important;
  }

  body.crm-shell-body .crm-page .crm-side-menu {
    display: grid !important;
  }

  body.crm-shell-body .crm-page .client-list .mini-tabs:not(.legacy-tabs) {
    display: none !important;
  }

  body.crm-shell-body .crm-page .client-detail {
    display: none !important;
  }

  body.crm-shell-body .crm-page.detail-open::after {
    content: "" !important;
    position: fixed !important;
    inset: 0 !important;
    z-index: 9000 !important;
    background: rgba(3,7,18,.58) !important;
    backdrop-filter: blur(14px) !important;
  }

  body.crm-shell-body .crm-page.detail-open .client-detail {
    position: fixed !important;
    inset: 32px !important;
    z-index: 9010 !important;
    display: block !important;
    width: min(1040px, calc(100vw - 64px)) !important;
    max-height: calc(100vh - 64px) !important;
    margin: auto !important;
    overflow: auto !important;
  }

  body.mobile-product .app-content {
    display: grid !important;
    grid-template-columns: 220px minmax(0, 1fr) !important;
    gap: 18px !important;
    align-items: start !important;
    width: min(1280px, 100%) !important;
    max-width: 1280px !important;
  }

  body.mobile-product .desktop-app-sidebar {
    position: sticky;
    top: 16px;
    display: grid !important;
    gap: 7px;
    min-height: calc(100vh - 32px);
    padding: 18px 12px;
    border: 1px solid rgba(148,128,255,0.14);
    border-radius: 8px;
    background: rgba(10,18,39,0.96);
    box-shadow: 0 18px 44px rgba(6,10,24,0.24);
  }

  .desktop-app-brand {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 2px 8px 18px;
    color: #fff;
    font-weight: 950;
  }

  .desktop-app-sidebar button {
    min-height: 40px;
    border: 1px solid transparent;
    border-radius: 8px;
    background: transparent;
    color: #9aa7bd;
    padding: 0 12px;
    font-size: .82rem;
    font-weight: 850;
    text-align: left;
  }

  .desktop-app-sidebar button.active {
    border-color: rgba(79,140,255,.22);
    background: linear-gradient(90deg, rgba(79,140,255,.18), rgba(139,92,246,.06));
    color: #fff;
    box-shadow: inset 3px 0 #4f8cff;
  }

  body.mobile-product .app-content > .mobile-screen,
  body.mobile-product .app-content > .bottom-tabs {
    grid-column: 2;
  }

  body.mobile-product .bottom-tabs {
    display: none !important;
  }
}

.crm-session-overlay {
  position: fixed;
  inset: 0;
  z-index: 9020;
  display: grid;
  place-items: center;
  padding: 22px;
  background: rgba(3,7,18,.58);
  backdrop-filter: blur(14px);
}

.crm-session-modal {
  width: min(620px, 100%);
  max-height: min(720px, calc(100vh - 44px));
  overflow: auto;
  display: grid;
  gap: 14px;
  position: relative;
  padding: 20px;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 15px;
  background: rgba(13,20,33,.98);
  color: #f5f7fb;
  box-shadow: 0 28px 90px rgba(0,0,0,.62);
}

body.crm-shell-body,
body.crm-shell-body::before,
body.crm-shell-body::after {
  background:
    radial-gradient(circle at 15% 5%, rgba(79,140,255,.13), transparent 30%),
    radial-gradient(circle at 90% 20%, rgba(139,92,246,.10), transparent 30%),
    #060911 !important;
}

body.crm-shell-body .crm-page,
body.crm-shell-body .product-view {
  background: transparent !important;
}

:root[data-theme="purple-dark"] .secure-task-modal,
body.mobile-product .secure-task-modal {
  border-color: rgba(148,128,255,0.18);
  background: linear-gradient(145deg, rgba(18,30,58,0.98), rgba(26,21,55,0.98));
  color: #f8f6ff;
}

:root[data-theme="purple-dark"] .secure-task-head h2,
body.mobile-product .secure-task-head h2 {
  color: #fff;
}

:root[data-theme="purple-dark"] .secure-task-fields input,
:root[data-theme="purple-dark"] .secure-choice,
body.mobile-product .secure-task-fields input,
body.mobile-product .secure-choice {
  border-color: rgba(148,128,255,0.18);
  background: rgba(8,16,35,0.92);
  color: #fff !important;
}

:root[data-theme="purple-dark"] .secure-choice b,
body.mobile-product .secure-choice b {
  color: #fff;
}

:root[data-theme="purple-dark"] .secure-choice small,
body.mobile-product .secure-choice small {
  color: #b8b2d8;
}

@media (max-width: 900px) {
  .desktop-app-sidebar {
    display: none !important;
  }
}

/* Final override: Customers owns the scroll so pagination can load at the bottom. */
.crm-page #applications .crm-list {
  height: min(70vh, 760px) !important;
  max-height: min(70vh, 760px) !important;
  overflow-x: hidden !important;
  overflow-y: auto !important;
  overscroll-behavior: contain;
}

@media (max-width: 900px) {
  .crm-page #applications .crm-list {
    height: 62vh !important;
    max-height: 62vh !important;
  }
}

/* Absolute final desktop CRM and wallet polish. */
@media (min-width: 901px) {
  .crm-page {
    display: grid !important;
    grid-template-columns: 276px minmax(0, 1fr) !important;
    gap: 0 !important;
    width: 100% !important;
    max-width: none !important;
    min-height: 100vh !important;
    padding: 0 !important;
    background:
      radial-gradient(circle at 15% 5%, rgba(79,140,255,.13), transparent 30%),
      radial-gradient(circle at 90% 20%, rgba(139,92,246,.10), transparent 30%),
      #060911 !important;
  }

  .crm-page .topbar {
    position: sticky !important;
    top: 0 !important;
    left: auto !important;
    bottom: auto !important;
    grid-column: 1 !important;
    width: 276px !important;
    height: 100vh !important;
    display: grid !important;
    align-content: start !important;
    gap: 14px !important;
    padding: 24px 16px !important;
    border: 0 !important;
    border-right: 1px solid rgba(255,255,255,.08) !important;
    border-radius: 0 !important;
    background: linear-gradient(180deg, #09111e, #060b14) !important;
    box-shadow: none !important;
  }

  .crm-page #crm {
    grid-column: 2 !important;
    min-width: 0 !important;
    padding: 28px 32px !important;
  }

  .crm-page .top-actions {
    display: grid !important;
    gap: 10px !important;
  }

  .crm-side-menu {
    display: grid;
    gap: 5px;
    margin: 8px 0 10px;
  }

  .crm-side-menu span {
    padding: 13px 12px 5px;
    color: #536176;
    font-size: 9px;
    font-weight: 900;
    letter-spacing: 1.8px;
    text-transform: uppercase;
  }

  .crm-side-menu button,
  .crm-page .language-switch button,
  .crm-page .theme-switch button,
  .crm-page .staff-link {
    min-height: 40px !important;
    border: 1px solid transparent !important;
    border-radius: 11px !important;
    background: transparent !important;
    color: #8d99ad !important;
    padding: 0 13px !important;
    font-size: 11px !important;
    font-weight: 750 !important;
    text-align: left !important;
    justify-content: start !important;
    box-shadow: none !important;
  }

  .crm-side-menu button.active,
  .crm-page .language-switch .active,
  .crm-page .theme-switch .active {
    color: #fff !important;
    border-color: rgba(79,140,255,.18) !important;
    background: linear-gradient(90deg, rgba(79,140,255,.18), rgba(79,140,255,.04)) !important;
    box-shadow: inset 3px 0 #4f8cff !important;
  }

  .crm-page .client-list .mini-tabs:not(.legacy-tabs) {
    display: none !important;
  }

  .crm-page .crm-layout {
    grid-template-columns: minmax(0, 1fr) !important;
  }

  .crm-page .client-detail {
    display: none !important;
  }

  .crm-page.detail-open::after {
    content: "" !important;
    position: fixed !important;
    inset: 0 !important;
    z-index: 7000 !important;
    background: rgba(3,7,18,.58) !important;
    backdrop-filter: blur(14px) !important;
  }

  .crm-page.detail-open .client-detail {
    position: fixed !important;
    inset: 32px !important;
    z-index: 7010 !important;
    display: block !important;
    width: min(1040px, calc(100vw - 64px)) !important;
    max-height: calc(100vh - 64px) !important;
    margin: auto !important;
    overflow: auto !important;
    border-radius: 17px !important;
    background: rgba(13,20,33,.98) !important;
    box-shadow: 0 28px 90px rgba(0,0,0,.62) !important;
  }

  .crm-page.detail-open .topbar,
  .crm-page.detail-open .section-head,
  .crm-page.detail-open .client-list {
    filter: blur(2px);
  }

  .mobile-product #crypto.mobile-screen.active {
    grid-template-columns: minmax(0, 1.05fr) minmax(280px, .62fr);
    gap: 16px;
    align-items: start;
  }

  .mobile-product #crypto .section-head,
  .mobile-product #crypto .transfer-mode-tabs,
  .mobile-product #crypto .crypto-task-panel {
    grid-column: 1;
  }

  .mobile-product #crypto .crypto-wallet-card,
  .mobile-product #crypto .desktop-market-panel {
    grid-column: 2;
  }

  .desktop-market-panel {
    display: grid;
    gap: 12px;
    padding: 14px;
    border: 1px solid rgba(148,128,255,0.16);
    border-radius: 8px;
    background: rgba(13,20,33,.82);
    color: #fff;
    box-shadow: 0 18px 44px rgba(6,10,24,0.24);
  }

  .desktop-market-grid {
    display: grid;
    gap: 8px;
  }

  .desktop-market-grid article {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 3px 10px;
    align-items: center;
    min-height: 54px;
    padding: 10px;
    border: 1px solid rgba(255,255,255,.08);
    border-radius: 8px;
    background: rgba(255,255,255,.035);
  }

  .desktop-market-grid span {
    grid-row: span 2;
    display: grid;
    place-items: center;
    width: 34px;
    height: 34px;
    border-radius: 10px;
    background: linear-gradient(135deg, #4f8cff, #8b5cf6);
    color: #fff;
    font-size: .76rem;
    font-weight: 950;
  }

  .desktop-market-grid b {
    color: #fff;
    font-size: .98rem;
  }

  .desktop-market-grid small {
    color: #7d8aa1;
    font-size: .72rem;
    font-weight: 800;
  }

  .desktop-market-grid article.up small { color: #58ea87; }
  .desktop-market-grid article.down small { color: #ff7b7b; }

  .mobile-product #crypto .transfer-mode-tabs {
    width: max-content;
    max-width: 100%;
    grid-template-columns: repeat(3, auto);
  }

  .mobile-product #crypto .transfer-mode-tabs button {
    width: auto;
    min-width: 118px;
    padding: 0 14px;
  }

  .mobile-product #crypto .crypto-form {
    width: max-content;
    min-width: 220px;
    padding: 12px;
  }
}

@media (max-width: 900px) {
  .desktop-market-panel,
  .crm-side-menu {
    display: none !important;
  }
}

/* CRM control-center skin based on the Desktop single-file CRM prototype. */
.crm-shell-body {
  min-height: 100vh;
  background:
    radial-gradient(circle at 15% 5%, rgba(79,140,255,.13), transparent 30%),
    radial-gradient(circle at 90% 20%, rgba(139,92,246,.10), transparent 30%),
    #060911;
  color: #f5f7fb;
}

.crm-page {
  width: 100%;
  min-height: 100vh;
  padding: 28px 32px 28px 292px;
  background: transparent;
}

.crm-page .topbar {
  position: fixed;
  left: 0;
  top: 0;
  bottom: 0;
  z-index: 50;
  width: 260px;
  display: block;
  padding: 26px 16px;
  border-right: 1px solid rgba(255,255,255,.08);
  border-bottom: 0;
  border-radius: 0;
  background: linear-gradient(180deg, #09111e, #060b14);
  box-shadow: none;
}

.crm-page .brand {
  display: flex;
  align-items: center;
  gap: 13px;
  min-height: 54px;
  margin-bottom: 28px;
  padding: 4px 10px;
  color: #fff;
}

.crm-page .brand-mark {
  width: 45px;
  height: 45px;
  border-radius: 14px;
  background: linear-gradient(135deg, #4f8cff, #8b5cf6);
  box-shadow: none;
}

.crm-page .brand span:last-child {
  display: grid;
  color: #fff;
  font-size: 15px;
  font-weight: 900;
  text-transform: uppercase;
}

.crm-page .brand span:last-child::after {
  content: "CRM CONTROL CENTER";
  margin-top: 4px;
  color: #7d8aa1;
  font-size: 8px;
  letter-spacing: 1.6px;
}

.crm-page .top-actions {
  display: grid;
  gap: 10px;
  margin-top: 20px;
}

.crm-page .top-actions::before,
.crm-page .client-list::before {
  content: "Operations";
  padding: 13px 12px 3px;
  color: #536176;
  font-size: 9px;
  font-weight: 900;
  letter-spacing: 1.8px;
  text-transform: uppercase;
}

.crm-page .language-switch,
.crm-page .theme-switch {
  width: 100%;
  display: grid;
  grid-template-columns: 1fr 1fr;
  padding: 0;
  border: 0;
  background: transparent;
  gap: 5px;
}

.crm-page .language-switch button,
.crm-page .theme-switch button,
.crm-page .staff-link,
.crm-page .mini-tabs button {
  min-height: 43px;
  justify-content: start;
  border: 1px solid transparent;
  border-radius: 11px;
  background: transparent;
  color: #8d99ad;
  padding: 0 13px;
  font-size: 11px;
  font-weight: 750;
  text-align: left;
  box-shadow: none;
}

.crm-page .staff-link {
  display: grid;
  align-items: center;
  text-decoration: none;
}

.crm-page .language-switch .active,
.crm-page .theme-switch .active,
.crm-page .mini-tabs .active {
  color: #fff;
  border-color: rgba(79,140,255,.18);
  background: linear-gradient(90deg, rgba(79,140,255,.18), rgba(79,140,255,.04));
  box-shadow: inset 3px 0 #4f8cff;
}

.crm-page .section-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin: 0 0 28px;
  padding: 0;
  border: 0;
  background: transparent;
  box-shadow: none;
}

.crm-page .section-head h1 {
  margin: 0;
  color: #f5f7fb;
  font-size: 25px;
  line-height: 1.1;
}

.crm-page .access-badge {
  border: 1px solid rgba(34,197,94,.20);
  border-radius: 7px;
  background: rgba(34,197,94,.12);
  color: #58ea87;
  padding: 9px 12px;
  font-size: 9px;
}

.crm-page .crm-layout {
  display: grid;
  grid-template-columns: minmax(360px, 1fr) minmax(440px, .92fr);
  gap: 14px;
  align-items: start;
}

.crm-page .client-list,
.crm-page .client-detail,
.crm-page .comments-panel,
.crm-page .crm-chart-panel,
.crm-page .crm-insight-grid article,
.crm-page .metric-row,
.crm-page .transaction-row,
.crm-page .support-ticket-row,
.crm-page .chat-ticket {
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 15px;
  background: rgba(13,20,33,.82);
  color: #f5f7fb;
  box-shadow: none;
}

.crm-page .client-list {
  padding: 14px;
}

.crm-page .mini-tabs {
  display: grid;
  grid-template-columns: 1fr;
  gap: 5px;
  margin-bottom: 18px;
  border: 0;
  background: transparent;
}

.crm-table-head {
  display: grid;
  grid-template-columns: 2.2fr 1.3fr 1.4fr 1.2fr 1.3fr 1fr;
  padding: 13px 18px;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 15px 15px 0 0;
  background: rgba(255,255,255,.025);
  color: #64738b;
  font-size: 8px;
  font-weight: 900;
  letter-spacing: .8px;
  text-transform: uppercase;
}

.crm-page #applications .crm-list {
  display: grid;
  gap: 0;
  height: min(70vh, 760px);
  overflow: auto;
  overscroll-behavior: contain;
  contain: strict;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.08);
  border-top: 0;
  border-radius: 0 0 15px 15px;
  background: rgba(13,20,33,.82);
}

/* Keep thousands of CRM rows cheap to paint while preserving native scrolling. */
.crm-page #applications .crm-list {
  overflow-y: auto;
  scrollbar-gutter: stable;
}

.crm-page #applications .request-card {
  content-visibility: auto;
  contain-intrinsic-size: 76px;
}

.crm-customer-search {
  display: block;
  margin: 0 0 12px;
}

.crm-customer-search input {
  width: 100%;
  min-height: 42px;
  padding: 0 13px;
  border: 1px solid rgba(255,255,255,.10);
  border-radius: 10px;
  background: rgba(5,10,22,.72);
  color: #f5f7fb;
  outline: none;
}

.crm-customer-search input:focus {
  border-color: rgba(79,140,255,.72);
  box-shadow: 0 0 0 3px rgba(79,140,255,.12);
}

.crm-load-more {
  width: 100%;
  margin-top: 10px;
  min-height: 40px;
}

.crm-page #unworked .crm-list {
  display: grid;
  gap: 0;
  margin-top: 14px;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 15px;
  background: rgba(13,20,33,.82);
}

.crm-page .request-card {
  display: grid;
  grid-template-columns: 2.2fr 1.3fr 1.4fr 1.2fr 1.3fr 1fr;
  align-items: center;
  min-height: 66px;
  padding: 8px 18px;
  border: 0;
  border-top: 1px solid rgba(255,255,255,.045);
  border-radius: 0;
  background: transparent;
  color: #c7d0df;
  cursor: pointer;
  transition: background 160ms ease, padding 160ms ease;
}

.crm-page .request-card:hover,
.crm-page .request-card.selected {
  padding-left: 22px;
  border-color: rgba(79,140,255,.16);
  background: rgba(79,140,255,.055);
}

.crm-page .request-card b,
.crm-page .request-card strong,
.crm-page .detail-top h2,
.crm-page .panel-title h2 {
  color: #f5f7fb;
}

.crm-page .request-card span,
.crm-page .request-card small,
.crm-page .detail-top p,
.crm-page .comments-panel p,
.crm-page .comment-feed,
.crm-page .comment-feed p {
  color: #7d8aa1;
}

.crm-page .request-card em {
  width: max-content;
  border: 1px solid rgba(79,140,255,.13);
  border-radius: 7px;
  background: rgba(79,140,255,.08);
  color: #7caaff;
  padding: 6px 8px;
  font-size: 8px;
  font-style: normal;
  font-weight: 800;
}

.crm-page .client-detail {
  padding: 0;
  overflow: hidden;
}

.crm-page .crm-back-button {
  width: auto;
  min-height: 38px;
  margin: 16px 16px 0;
}

.crm-page .detail-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  margin: 16px;
  padding: 24px;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 17px;
  background:
    radial-gradient(circle at 0 50%, rgba(79,140,255,.11), transparent 35%),
    #0d1421;
}

.crm-page .detail-top > div:first-child {
  display: grid;
  gap: 5px;
}

.crm-page .balance-pill {
  min-width: 150px;
  border: 0;
  background: transparent;
  color: #9bbcff;
  text-align: right;
}

.crm-page .balance-pill span {
  display: block;
  color: #7d8aa1;
  font-size: 8px;
}

.crm-page .balance-pill strong {
  display: block;
  color: #9bbcff;
  font-size: 25px;
}

.crm-page .action-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 16px 15px;
}

.crm-page button,
.crm-page .action-grid a,
.crm-page .comment-form button,
.crm-page .crm-withdraw-form button,
.crm-page .chat-ticket button,
.crm-page .support-ticket-row button,
.crm-page .crm-back-button {
  min-height: 38px;
  border-radius: 9px;
  border: 0;
  padding: 10px 15px;
  color: #fff;
  background: linear-gradient(135deg, #4f8cff, #6366f1);
  font-size: 9px;
  font-weight: 850;
  text-decoration: none;
  box-shadow: none;
}

.crm-page .action-grid a:nth-child(1),
.crm-page .secondary-button,
.crm-page .crm-back-button {
  border: 1px solid rgba(255,255,255,.08);
  background: rgba(255,255,255,.045);
  color: #dce6f8;
}

.crm-page .action-grid a:nth-child(2) {
  border: 1px solid rgba(34,197,94,.20);
  background: rgba(34,197,94,.12);
  color: #58ea87;
}

.crm-page .crm-insight-grid,
.crm-page .crm-operations-grid {
  margin: 0 16px 15px;
}

.crm-page .comments-panel,
.crm-page .crm-chart-panel {
  margin: 0 16px 15px;
  padding: 18px;
}

.crm-page .panel-title {
  align-items: center;
  margin-bottom: 13px;
}

.crm-page .panel-title span {
  border: 1px solid rgba(79,140,255,.13);
  border-radius: 7px;
  background: rgba(79,140,255,.08);
  color: #7caaff;
  padding: 6px 8px;
  font-size: 8px;
}

.crm-page input,
.crm-page textarea,
.crm-page select,
.crm-page .comment-feed {
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 9px;
  background: #111827;
  color: #fff;
}

.crm-page input::placeholder,
.crm-page textarea::placeholder {
  color: #64738b;
}

.crm-page .crm-withdraw-form label {
  color: #7d8aa1;
  font-size: 8px;
}

.crm-page .crm-login-panel {
  position: fixed;
  inset: 0;
  z-index: 100;
  background:
    radial-gradient(circle at 15% 5%, rgba(79,140,255,.13), transparent 30%),
    radial-gradient(circle at 90% 20%, rgba(139,92,246,.10), transparent 30%),
    #060911;
}

.crm-page .crm-login-shell,
.crm-page .crm-login-hero,
.crm-page .crm-manager-form {
  border-color: rgba(255,255,255,.08);
  background: rgba(13,20,33,.86);
  color: #f5f7fb;
}

.crm-page .crm-login-hero .brand-mark {
  background: linear-gradient(135deg, #4f8cff, #8b5cf6);
}

@media (max-width: 900px) {
  .crm-page {
    padding: 92px 12px 18px;
  }

  .crm-page .topbar {
    right: 0;
    bottom: auto;
    width: 100%;
    min-height: 78px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px;
    border-right: 0;
    border-bottom: 1px solid rgba(255,255,255,.08);
  }

  .crm-page .brand {
    margin: 0;
    padding: 0;
  }

  .crm-page .top-actions {
    display: none;
  }

  .crm-page .crm-layout,
  .crm-page.detail-open .crm-layout {
    grid-template-columns: 1fr;
  }

  .crm-table-head {
    display: none;
  }

  .crm-page #applications .crm-list {
    border-top: 1px solid rgba(255,255,255,.08);
    border-radius: 15px;
    height: 62vh;
  }

  .crm-page .request-card {
    grid-template-columns: 1fr;
    gap: 8px;
    align-items: start;
    padding: 14px;
  }

  .crm-page .detail-top,
  .crm-page .action-grid {
    display: grid;
    grid-template-columns: 1fr;
  }
}

/* CRM modal workflow corrections. */
.crm-page {
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
  align-items: start;
  gap: 0;
  padding: 0;
}

.crm-page .topbar {
  position: sticky;
  grid-column: 1;
  top: 0;
  height: 100vh;
  width: 260px;
}

.crm-page #crm {
  grid-column: 2;
  min-width: 0;
  padding: 28px 32px;
}

.crm-page .crm-layout {
  grid-template-columns: minmax(0, 1fr);
}

.crm-page .client-detail {
  display: none;
}

.crm-page.detail-open::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 2200;
  background: rgba(3,7,18,.58);
  backdrop-filter: blur(13px);
}

.crm-page.detail-open .topbar,
.crm-page.detail-open .section-head,
.crm-page.detail-open .client-list {
  filter: blur(2px);
}

.crm-page.detail-open .client-detail {
  position: fixed;
  inset: 32px;
  z-index: 2210;
  display: block;
  width: min(980px, calc(100vw - 28px));
  max-height: calc(100vh - 64px);
  margin: auto;
  overflow: auto;
  border-radius: 17px;
  box-shadow: 0 28px 90px rgba(0,0,0,.58);
}

.crm-page.detail-open .client-list {
  display: block;
}

.secure-choice-grid {
  display: grid;
  gap: 9px;
}

.secure-choice {
  display: grid !important;
  grid-template-columns: auto 1fr;
  gap: 4px 10px !important;
  align-items: center;
  min-height: 62px;
  padding: 12px;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  background: #f9fafb;
  color: #111827 !important;
}

.secure-choice input {
  width: 18px;
  height: 18px;
  min-height: 0;
  margin: 0;
  accent-color: #7c3aed;
}

.secure-choice b {
  color: #111827;
  font-size: .92rem;
}

.secure-choice small {
  grid-column: 2;
  color: #6b7280;
  font-size: .74rem;
  font-weight: 750;
}

@media (max-width: 900px) {
  .crm-page {
    display: block;
    padding: 0;
  }

  .crm-page .topbar {
    position: sticky;
    width: 100%;
    height: auto;
  }

  .crm-page #crm {
    padding: 18px 12px;
  }

  .crm-page.detail-open .client-detail {
    inset: 10px;
    width: calc(100vw - 20px);
    max-height: calc(100vh - 20px);
  }
}

/* Interaction polish: task screens, CRM login, top events, and animated panel transitions. */
.product-view,
.crm-pane,
.mobile-screen,
.crypto-task-panel,
.task-screen {
  animation: eyFadeUp 220ms ease both;
}

@keyframes eyFadeUp {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

.task-screen {
  display: grid;
  gap: 12px;
}

.task-screen.hidden,
.crypto-task-panel {
  display: none;
}

.crypto-task-panel.active {
  display: grid;
  gap: 12px;
}

.task-back {
  width: 42px;
  height: 42px;
  border: 1px solid rgba(121, 85, 255, 0.22);
  border-radius: 12px;
  background: rgba(121, 85, 255, 0.10);
  color: var(--ink);
  font-weight: 950;
}

.task-head {
  display: grid;
  gap: 8px;
  justify-items: center;
  padding: 18px;
  border: 1px solid rgba(121, 85, 255, 0.16);
  border-radius: 16px;
  background: linear-gradient(135deg, rgba(121, 85, 255, 0.10), rgba(79, 140, 255, 0.08));
  text-align: center;
}

.task-head span {
  display: grid;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 10px;
  background: linear-gradient(135deg, #4f8cff, #8b5cf6);
  color: #fff;
  font-weight: 950;
}

.auth-hero.compact-task {
  padding: 14px;
}

.auth-hero.compact-task h1,
.auth-hero.compact-task p:last-child {
  display: none;
}

.code-box-input {
  height: 54px;
  padding: 0 7px;
  border-radius: 14px;
  letter-spacing: 13px;
  text-align: center;
  font-size: 1.25rem;
  font-weight: 900;
  font-variant-numeric: tabular-nums;
  background:
    linear-gradient(90deg, transparent 0 12%, rgba(121,85,255,0.12) 12% 14%, transparent 14% 28%, rgba(121,85,255,0.12) 28% 30%, transparent 30% 44%, rgba(121,85,255,0.12) 44% 46%, transparent 46% 60%, rgba(121,85,255,0.12) 60% 62%, transparent 62% 76%, rgba(121,85,255,0.12) 76% 78%, transparent 78%),
    rgba(255,255,255,0.88);
}

.transfer-mode-tabs {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
  padding: 6px;
  border: 1px solid rgba(121, 85, 255, 0.16);
  border-radius: 16px;
  background: rgba(121, 85, 255, 0.08);
}

.transfer-mode-tabs button {
  min-height: 42px;
  border: 0;
  border-radius: 12px;
  background: transparent;
  color: var(--muted);
  font-weight: 900;
}

.transfer-mode-tabs button.active {
  background: linear-gradient(135deg, #4f8cff, #8b5cf6);
  color: #fff;
  box-shadow: 0 12px 28px rgba(79, 140, 255, 0.24);
}

.welcome-overlay {
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center;
  z-index: 1500;
  background: rgba(6, 9, 17, 0.58);
  backdrop-filter: blur(12px);
}

.welcome-overlay.hidden {
  display: none;
}

.welcome-overlay > div {
  display: grid;
  gap: 14px;
  justify-items: center;
  min-width: min(320px, calc(100vw - 40px));
  padding: 28px;
  border: 1px solid rgba(255,255,255,0.10);
  border-radius: 22px;
  background: linear-gradient(135deg, #111b34, #2d1f63);
  color: #fff;
  box-shadow: 0 26px 80px rgba(0,0,0,0.38);
  animation: eyWelcome 900ms ease both;
}

@keyframes eyWelcome {
  0% { opacity: 0; transform: scale(0.92) translateY(18px); }
  35% { opacity: 1; transform: scale(1) translateY(0); }
  100% { opacity: 1; transform: scale(1) translateY(0); }
}

.crm-login-panel {
  min-height: calc(100vh - 140px);
  display: grid;
  align-items: center;
}

.crm-login-shell {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(320px, .75fr);
  gap: 18px;
  width: min(980px, 100%);
  margin: 0 auto;
}

.crm-login-hero,
.crm-manager-form {
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 22px;
  background: radial-gradient(circle at 0 0, rgba(79,140,255,0.18), transparent 38%), rgba(13,20,33,0.88);
  color: #f5f7fb;
  box-shadow: 0 24px 70px rgba(0,0,0,0.32);
}

.crm-login-hero {
  display: grid;
  align-content: end;
  gap: 14px;
  min-height: 360px;
  padding: 28px;
}

.crm-login-hero h1 {
  font-size: clamp(2rem, 4vw, 3.6rem);
}

.crm-login-hero p:last-of-type {
  max-width: 520px;
  color: #9aa8bf;
  line-height: 1.55;
}

.crm-login-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.crm-login-stats span {
  padding: 8px 11px;
  border: 1px solid rgba(79,140,255,0.20);
  border-radius: 999px;
  background: rgba(79,140,255,0.10);
  color: #9bbcff;
  font-size: .78rem;
  font-weight: 900;
}

.crm-manager-form {
  align-content: center;
  padding: 24px;
  background: rgba(13,20,33,0.92);
}

.crm-manager-form input {
  min-height: 52px;
  border-color: rgba(255,255,255,0.08);
  border-radius: 12px;
  background: #111827;
  color: #fff;
}

.crm-manager-form button {
  min-height: 52px;
  border-radius: 12px;
  background: linear-gradient(135deg, #4f8cff, #8b5cf6);
  box-shadow: 0 16px 34px rgba(79,140,255,0.28);
}

@media (max-width: 760px) {
  .crm-login-shell {
    grid-template-columns: 1fr;
  }

  .crm-login-hero {
    min-height: 230px;
  }
}

:root[data-theme="purple-dark"] .task-back,
:root[data-theme="purple-dark"] .task-head,
:root[data-theme="purple-dark"] .transfer-mode-tabs {
  border-color: rgba(139,92,246,0.24);
  background: rgba(139,92,246,0.10);
  color: #f5f7fb;
}

:root[data-theme="purple-dark"] .code-box-input {
  background:
    linear-gradient(90deg, transparent 0 12%, rgba(139,92,246,0.28) 12% 14%, transparent 14% 28%, rgba(139,92,246,0.28) 28% 30%, transparent 30% 44%, rgba(139,92,246,0.28) 44% 46%, transparent 46% 60%, rgba(139,92,246,0.28) 60% 62%, transparent 62% 76%, rgba(139,92,246,0.28) 76% 78%, transparent 78%),
    #0d1421;
}

:root[data-theme="purple-dark"] .toast {
  border-color: rgba(139,92,246,0.35);
  background: linear-gradient(135deg, #151f30, #2d1f63);
  color: #fff;
}

:root[data-theme="purple-dark"] {
  color-scheme: dark;
  --ink: #f6f6f6;
  --muted: #a8a8a8;
  --line: #252525;
  --paper: #050505;
  --surface: #101010;
  --charcoal: #ffffff;
  --charcoal-soft: #dedede;
  --shadow: 0 22px 52px rgba(0, 0, 0, 0.48);
  --button-shadow: 0 14px 30px rgba(255, 255, 255, 0.08);
}

:root[data-theme="dark"] {
  color-scheme: dark;
  --ink: #f6f6f6;
  --muted: #a8a8a8;
  --line: #252525;
  --paper: #050505;
  --surface: #101010;
  --charcoal: #ffffff;
  --charcoal-soft: #dedede;
  --shadow: 0 22px 52px rgba(0, 0, 0, 0.48);
  --button-shadow: 0 14px 30px rgba(255, 255, 255, 0.08);
}

:root[data-theme="purple-light"] {
  color-scheme: light;
  --ink: #171226;
  --muted: #746b86;
  --line: #d8cfee;
  --paper: #f2edf9;
  --surface: #fbf8ff;
  --charcoal: #6d4aff;
  --charcoal-soft: #8b5cf6;
  --shadow: 0 22px 52px rgba(109, 74, 255, 0.14);
  --button-shadow: 0 14px 30px rgba(109, 74, 255, 0.22);
}

* { box-sizing: border-box; }

.hidden { display: none !important; }

.bot-field {
  height: 0;
  left: -10000px;
  opacity: 0;
  overflow: hidden;
  position: absolute;
  top: auto;
  width: 1px;
}

body {
  margin: 0;
  background:
    linear-gradient(180deg, #ffffff 0%, #f4f4f4 44%, #eeeeee 100%);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

:root[data-theme="purple-dark"] body {
  background:
    linear-gradient(135deg, #060911 0%, #08101c 46%, #060b14 100%);
  color: var(--ink);
}

button, input, select, a { font: inherit; }
button { cursor: pointer; }

.app-shell {
  width: min(1240px, calc(100% - 28px));
  margin: 0 auto;
  padding: 18px 0 42px;
}

.topbar,
.top-actions,
.brand,
.section-head,
.detail-top,
.balance-top,
.profit-row,
.wallet-strip,
.positions article,
.operation-card,
.market-row,
.metric-row,
.request-card,
.panel-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.topbar {
  min-height: 52px;
}

.brand {
  justify-content: flex-start;
  color: var(--ink);
  font-weight: 900;
  text-decoration: none;
}

.brand-mark {
  display: grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border-radius: 8px;
  background: #050505;
  color: #fff;
  font-size: 0.8rem;
  font-weight: 950;
  overflow: hidden;
}

.brand-mark img {
  display: block;
  width: 100%;
  height: 100%;
}

:root[data-theme="purple-dark"] .brand-mark {
  border: 1px solid rgba(255,255,255,0.24);
  background: linear-gradient(135deg, #4f8cff, #8b5cf6);
  color: #fff;
}

.top-actions {
  justify-content: flex-end;
}

.language-switch,
.theme-switch,
.product-tabs,
.mini-tabs,
.app-menu {
  display: grid;
  gap: 6px;
  padding: 6px;
  border-radius: 8px;
  background: #eeeeee;
}

.language-switch { grid-template-columns: repeat(2, 40px); }
.theme-switch { grid-template-columns: repeat(2, minmax(64px, 1fr)); }
.product-tabs { grid-template-columns: repeat(4, 1fr); margin: 18px 0; }
.mini-tabs { grid-template-columns: repeat(4, 1fr); margin-bottom: 12px; }
.app-menu { grid-template-columns: repeat(4, 1fr); margin: 12px 0; }

.language-switch button,
.theme-switch button,
.product-tabs button,
.mini-tabs button,
.app-menu button {
  min-height: 36px;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: var(--muted);
  font-weight: 850;
}

.language-switch .active,
.theme-switch .active,
.product-tabs .active,
.mini-tabs .active,
.app-menu .active {
  background: var(--surface);
  color: #000;
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.07);
}

:root[data-theme="purple-dark"] .language-switch,
:root[data-theme="purple-dark"] .theme-switch,
:root[data-theme="purple-dark"] .product-tabs,
:root[data-theme="purple-dark"] .mini-tabs,
:root[data-theme="purple-dark"] .app-menu {
  background: #191919;
}

:root[data-theme="purple-dark"] .language-switch .active,
:root[data-theme="purple-dark"] .theme-switch .active,
:root[data-theme="purple-dark"] .product-tabs .active,
:root[data-theme="purple-dark"] .mini-tabs .active,
:root[data-theme="purple-dark"] .app-menu .active {
  background: #fff;
  color: #050505;
}

.install-button,
.staff-link,
.action-grid button,
.action-grid a,
.comment-form button,
.chat-form button,
.wallet-strip button,
.bank-form button {
  border: 0;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--charcoal), var(--charcoal-soft));
  color: #fff;
  font-weight: 850;
  text-decoration: none;
  box-shadow: var(--button-shadow);
  transition: transform 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

.staff-link:hover,
.action-grid button:hover,
.action-grid a:hover,
.comment-form button:hover,
.chat-form button:hover,
.wallet-strip button:hover,
.bank-form button:hover,
.auth-actions button:hover,
.verification-grid button:hover,
.verification-form button:hover,
.forgot-button:hover,
.forgot-toggle:hover,
.quick-grid button:hover,
.bottom-tabs button:hover {
  transform: translateY(-1px);
}

.install-button {
  min-height: 38px;
  padding: 0 14px;
}

.staff-link {
  display: grid;
  min-height: 38px;
  place-items: center;
  padding: 0 14px;
}

.mobile-product {
  background: #dcdcdc;
}

:root[data-theme="purple-dark"] .mobile-product {
  background: #000;
}

.mobile-shell {
  position: relative;
  width: min(430px, 100%);
  min-height: 100vh;
  margin: 0 auto;
  padding: 14px 14px 96px;
  background: #f7f7f7;
}

:root[data-theme="purple-dark"] .mobile-shell {
  background: #050505;
}

.mobile-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 16px;
}

.mobile-screen {
  display: none;
}

.mobile-screen.active {
  display: block;
}

.section-head.compact {
  margin-bottom: 12px;
  padding: 4px 0 12px;
}

.quick-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 10px;
  margin: 14px 0;
}

.quick-grid button {
  display: grid;
  min-height: 82px;
  place-items: center;
  gap: 6px;
  border: 0;
  border: 1px solid #e8e8e8;
  border-radius: 8px;
  background: rgba(255,255,255,0.94);
  color: var(--ink);
  font-size: 0.72rem;
  font-weight: 850;
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.08);
  transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease;
}

.quick-grid button:hover,
.asset-row:hover,
.crypto-actions button:hover,
.crypto-form button:hover {
  transform: translateY(-1px);
}

.quick-grid span,
.quick-grid em {
  display: block;
  font-style: normal;
}

.quick-grid span {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: #0a0a0a;
  color: #fff;
  line-height: 34px;
  font-weight: 900;
}

.market-card,
.profile-card {
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.profile-card {
  display: grid;
  gap: 6px;
  margin-bottom: 12px;
  text-align: center;
}

.profile-avatar {
  display: grid;
  width: 68px;
  height: 68px;
  margin: 0 auto 4px;
  place-items: center;
  border-radius: 50%;
  background: #050505;
  color: #fff;
  font-weight: 900;
}

.bottom-tabs {
  position: fixed;
  left: 50%;
  bottom: 0;
  z-index: 10;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  width: min(430px, 100%);
  padding: 9px 10px calc(9px + env(safe-area-inset-bottom));
  border-top: 1px solid rgba(0, 0, 0, 0.08);
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 -16px 36px rgba(0, 0, 0, 0.10);
  transform: translateX(-50%);
}

.bottom-tabs button {
  display: grid;
  gap: 3px;
  min-height: 54px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 850;
  place-items: center;
  transition: transform 160ms ease, background 160ms ease, color 160ms ease;
}

.bottom-tabs span {
  font-size: 1.05rem;
  line-height: 1;
}

.bottom-tabs b {
  font-size: 0.72rem;
}

.bottom-tabs .active {
  background: #050505;
  color: #fff;
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.18);
}

:root[data-theme="purple-dark"] .bottom-tabs {
  border-color: rgba(255,255,255,0.10);
  background: rgba(8,8,8,0.96);
  box-shadow: 0 -16px 36px rgba(0,0,0,0.45);
}

:root[data-theme="purple-dark"] .bottom-tabs .active {
  background: #fff;
  color: #050505;
}

.hero-strip {
  display: grid;
  grid-template-columns: 320px 1fr;
  gap: 22px;
  align-items: center;
  margin-top: 18px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.hero-strip img {
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  border-radius: 7px;
}

.eyebrow {
  margin: 0 0 6px;
  color: var(--teal);
  font-size: 0.76rem;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1, h2, h3, p { margin-top: 0; }
h1 { margin-bottom: 8px; font-size: clamp(1.8rem, 4vw, 3.4rem); line-height: 1.02; letter-spacing: 0; }
h2 { margin-bottom: 0; font-size: 1.45rem; letter-spacing: 0; }
h3 { margin-bottom: 6px; font-size: 1.02rem; letter-spacing: 0; }
p { color: var(--muted); line-height: 1.52; }

.product-view { display: none; }
.product-view.active { display: block; }

.section-head {
  align-items: flex-start;
  margin-bottom: 14px;
  padding: 14px 0;
}

.access-badge,
.balance-pill,
.panel-title span {
  border-radius: 999px;
  white-space: nowrap;
}

.access-badge {
  padding: 7px 10px;
  background: #e8f7ee;
  color: #177245;
  font-size: 0.78rem;
  font-weight: 900;
}

.access-badge.neutral { background: #f6edda; color: #8a641d; }

.crm-layout,
.banking-layout {
  display: grid;
  grid-template-columns: minmax(280px, 360px) 1fr;
  gap: 16px;
  align-items: start;
}

.client-list,
.client-detail,
.banking-summary,
.phone-frame,
.flow-grid article,
.security-grid article {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: 0 10px 28px rgba(16, 20, 23, 0.07);
}

.client-list,
.client-detail,
.banking-summary {
  padding: 16px;
}

.crm-pane,
.app-pane { display: none; }
.crm-pane.active,
.app-pane.active { display: grid; gap: 10px; }

.request-card {
  width: 100%;
  min-height: 70px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  text-align: left;
}

.request-card.selected {
  border-color: rgba(0, 107, 100, 0.44);
  background: var(--mint);
}

small {
  display: block;
  margin-top: 4px;
  color: var(--muted);
}

.metric-row,
.chat-ticket,
.comments-panel,
.operation-card,
.market-row {
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.chat-ticket {
  display: grid;
  gap: 8px;
}

.chat-ticket > div,
.support-ticket-row div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.chat-ticket button,
.support-ticket-row button {
  min-height: 32px;
  padding: 0 10px;
  border: 1px solid #050505;
  border-radius: 7px;
  background: #050505;
  color: #fff;
  font-size: 0.76rem;
  font-weight: 900;
}

.detail-top {
  align-items: flex-start;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
}

.balance-pill {
  display: grid;
  gap: 4px;
  padding: 10px 12px;
  background: var(--mint);
}

.balance-pill span { color: var(--muted); font-size: 0.75rem; font-weight: 800; }
.balance-pill strong { color: var(--teal-dark); }

.action-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 8px;
  margin: 14px 0;
}

.action-grid button,
.action-grid a {
  display: grid;
  min-height: 42px;
  place-items: center;
  padding: 0 10px;
  text-align: center;
}

.crm-page .detail-top {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  justify-items: center;
  text-align: center;
  gap: 14px;
}

.crm-page .detail-top > div:first-child {
  display: grid;
  justify-items: center;
  min-width: 0;
}

.crm-page .detail-top p,
.crm-page .detail-top b {
  max-width: 100%;
  overflow-wrap: anywhere;
}

.crm-page .balance-pill {
  justify-items: center;
  text-align: center;
}

.crm-page .action-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.comments-panel { background: #fbfcfc; }
.panel-title { align-items: flex-start; }
.panel-title span { padding: 6px 8px; background: #eef4f4; color: var(--muted); font-size: 0.75rem; font-weight: 850; }

.comment-feed {
  display: grid;
  gap: 8px;
  margin: 12px 0;
}

.comment-feed p {
  margin: 0;
  padding: 10px;
  border-radius: 7px;
  background: #fff;
  border: 1px solid var(--line);
  color: var(--ink);
}

.comment-form,
.chat-form {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
}

.comment-form.stacked-form {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.comment-form.stacked-form input,
.comment-form.stacked-form select,
.comment-form.stacked-form button {
  width: 100%;
  min-height: 44px;
}

.comment-form.stacked-form button {
  grid-column: 1 / -1;
}

.comment-form input,
.chat-form input,
.bank-form input,
.bank-form select {
  min-height: 40px;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 7px;
  padding: 0 12px;
}

.bank-form {
  display: grid;
  gap: 10px;
  margin-bottom: 12px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.auth-panel {
  display: grid;
  gap: 16px;
  min-height: auto;
  align-content: start;
  margin-bottom: 14px;
  padding: 10px 16px 22px;
}

.auth-language-row {
  display: flex;
  justify-content: flex-end;
}

.auth-hero,
.auth-form,
.forgot-form,
.reset-form,
.auth-mode-tabs,
.auth-footnote {
  width: 100%;
}

.auth-hero {
  display: grid;
  justify-items: start;
  padding: 22px;
  border-radius: 8px;
  background: linear-gradient(135deg, #ffffff 0%, #eef8f6 100%);
  border: 1px solid rgba(0, 107, 100, 0.16);
  box-shadow: 0 18px 42px rgba(16, 20, 23, 0.09);
}

.auth-emblem {
  display: grid;
  width: 64px;
  height: 64px;
  margin-bottom: 14px;
  place-items: center;
  border-radius: 16px;
  background: var(--teal);
  color: #fff;
  font-size: 1.05rem;
  font-weight: 950;
}

.auth-hero h1 {
  margin-bottom: 10px;
  font-size: 2rem;
}

.auth-hero p:last-child {
  margin-bottom: 0;
}

.auth-form,
.forgot-form,
.reset-form {
  display: grid;
  gap: 12px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 10px 26px rgba(16, 20, 23, 0.06);
}

.auth-form label,
.forgot-form label,
.reset-form label {
  display: grid;
  gap: 7px;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 850;
}

.auth-form label.hidden {
  display: none;
}

.settings-card,
.status-card,
.transaction-row,
.empty-state {
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.asset-stack {
  display: grid;
  gap: 10px;
  margin-top: 12px;
}

.asset-stack-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 0 2px;
  color: #111;
  font-size: 0.82rem;
  font-weight: 900;
}

.asset-stack-title button {
  min-height: 32px;
  padding: 0 12px;
  border: 0;
  border-radius: 999px;
  background: #050505;
  color: #fff;
  font-size: 0.76rem;
  font-weight: 900;
}

.asset-row {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr) auto;
  align-items: center;
  gap: 12px;
  width: 100%;
  min-height: 72px;
  padding: 12px;
  border: 1px solid #e7e7e7;
  border-radius: 8px;
  background: #fff;
  color: #050505;
  text-align: left;
  box-shadow: 0 14px 32px rgba(0,0,0,0.07);
  transition: transform 160ms ease, box-shadow 160ms ease;
}

.address-stack-title {
  margin-top: 4px;
}

.address-row {
  display: grid;
  grid-template-columns: 78px minmax(0, 1fr) 78px;
  justify-items: center;
  align-items: center;
  gap: 12px;
  min-height: 68px;
  padding: 12px;
  border: 1px solid #e7e7e7;
  border-radius: 8px;
  background: #fff;
  color: #050505;
  text-align: center;
  box-shadow: 0 14px 32px rgba(0,0,0,0.07);
}

.address-row span:nth-child(2) {
  display: grid;
  justify-items: center;
  min-width: 0;
}

.address-row small {
  color: var(--muted);
  overflow-wrap: anywhere;
}

.address-row button {
  min-width: 78px;
  min-height: 36px;
  padding: 0 14px;
  border: 1px solid #050505;
  border-radius: 8px;
  background: #050505;
  color: #fff;
  font-weight: 900;
}

.asset-row:hover {
  box-shadow: 0 18px 36px rgba(0,0,0,0.10);
}

.asset-row span:nth-child(2) {
  min-width: 0;
}

.asset-row b,
.asset-row small {
  display: block;
}

.asset-row small {
  color: var(--muted);
  font-size: 0.74rem;
}

.asset-row strong {
  white-space: nowrap;
  font-size: 0.9rem;
}

.token-mark {
  display: grid;
  width: 44px;
  height: 44px;
  place-items: center;
  border-radius: 50%;
  background: #050505;
  color: #fff;
  font-weight: 950;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,0.14);
}

.settings-card {
  display: grid;
  gap: 10px;
  margin-bottom: 12px;
}

.settings-action-button {
  min-height: 42px;
  border: 1px solid #050505;
  border-radius: 8px;
  background: #fff;
  color: #050505;
  font-weight: 900;
}

.settings-row,
.transaction-row,
.ledger-state {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.transaction-list {
  display: grid;
  gap: 8px;
}

.transaction-row small {
  color: var(--muted);
  text-transform: uppercase;
}

.transaction-row div:first-child {
  min-width: 0;
}

.transaction-row strong {
  white-space: nowrap;
}

.tx-actions {
  display: flex;
  gap: 6px;
}

.tx-actions button {
  min-height: 34px;
  padding: 0 10px;
}

.logout-button {
  width: 100%;
  min-height: 44px;
  margin-top: 8px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #fff;
  color: var(--red);
  font-weight: 850;
}

.ledger-state {
  margin-top: 14px;
  color: rgba(255,255,255,0.78);
  font-size: 0.8rem;
}

.ledger-state b {
  color: #d7f7e8;
}

.auth-form input,
.forgot-form input,
.reset-form input {
  min-height: 52px;
  border: 1px solid #cbd8da;
  border-radius: 8px;
  padding: 0 14px;
  background: #fbfdfd;
  color: var(--ink);
  font-size: 1rem;
  outline: none;
}

.auth-form input:focus,
.forgot-form input:focus,
.reset-form input:focus {
  border-color: var(--teal);
  box-shadow: 0 0 0 4px rgba(0, 107, 100, 0.12);
}

.auth-mode-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  padding: 6px;
  border-radius: 8px;
  background: #e9f0f0;
}

.auth-mode-tabs button {
  min-height: 42px;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: var(--muted);
  font-weight: 900;
}

.auth-mode-tabs .active {
  background: #fff;
  color: var(--teal);
  box-shadow: 0 8px 18px rgba(16, 20, 23, 0.06);
}

.auth-actions {
  display: grid;
}

.auth-actions button {
  min-height: 50px;
  border: 1px solid #050505;
  border-radius: 10px;
  background: #fff;
  color: #050505;
  box-shadow: 0 12px 26px rgba(0, 0, 0, 0.10);
  transition: transform 160ms ease, box-shadow 160ms ease;
  font-size: 1rem;
  font-weight: 950;
}

.reset-form button {
  min-height: 48px;
  border: 0;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--charcoal), var(--charcoal-soft));
  color: #fff;
  box-shadow: var(--button-shadow);
  font-weight: 950;
}

.auth-actions button:disabled,
.reset-form button:disabled,
.chat-form button:disabled,
.bank-form button:disabled,
.verification-grid button:disabled,
.verification-form button:disabled {
  cursor: wait;
  opacity: 0.7;
  transform: none;
}

.auth-footnote {
  margin: 0;
  padding: 0 4px;
  color: var(--muted);
  font-size: 0.82rem;
  line-height: 1.45;
}

.forgot-button,
.forgot-toggle {
  min-height: 42px;
  border: 1px solid rgba(0, 107, 100, 0.18);
  border-radius: 10px;
  background: #fff;
  color: var(--teal-dark);
  font-weight: 900;
  transition: transform 160ms ease, box-shadow 160ms ease;
}

.cf-turnstile {
  min-height: 65px;
}

.verification-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}

.verification-grid button,
.verification-form button {
  min-height: 40px;
  border: 0;
  border-radius: 9px;
  background: linear-gradient(135deg, var(--charcoal), var(--charcoal-soft));
  color: #fff;
  font-weight: 850;
  box-shadow: var(--button-shadow);
}

.verification-form {
  display: grid;
  grid-template-columns: 110px 1fr auto;
  gap: 8px;
}

.verification-form input,
.verification-form select {
  min-height: 40px;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 7px;
  padding: 0 10px;
}

.bank-form label {
  display: grid;
  gap: 5px;
  color: var(--muted);
  font-size: 0.8rem;
  font-weight: 850;
}

.bank-form button {
  min-height: 48px;
}

.comment-form button,
.chat-form button {
  min-width: 84px;
  padding: 0 12px;
}

.banking-layout {
  grid-template-columns: minmax(310px, 400px) 1fr;
}

.phone-frame {
  padding: 16px;
  background: #f8fbfb;
}

.phone-status,
.client-header,
.balance-top,
.profit-row {
  display: flex;
  justify-content: space-between;
  gap: 10px;
}

.phone-status {
  padding: 0 8px 12px;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 850;
}

.client-header {
  align-items: flex-start;
  margin-bottom: 12px;
}

.round-button {
  width: 38px;
  height: 38px;
  border: 0;
  border-radius: 8px;
  background: #fff;
  color: var(--red);
  font-weight: 900;
}

.balance-panel {
  padding: 20px;
  border-radius: 8px;
  background: linear-gradient(145deg, #1a1a1a 0%, #050505 100%);
  color: #fff;
  box-shadow: 0 20px 42px rgba(0,0,0,0.24);
}

.balance-panel p,
.balance-panel span { color: rgba(255,255,255,0.78); }
.balance-panel strong { display: block; margin-top: 12px; font-size: 2.15rem; letter-spacing: 0; }
.balance-panel button { border: 1px solid rgba(255,255,255,0.2); border-radius: 6px; padding: 6px 9px; background: rgba(255,255,255,0.10); color: #fff; font-weight: 850; }
.profit-row b { color: #d7f7e8; }

.trend-line {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  align-items: end;
  gap: 7px;
  height: 70px;
  margin: 14px 0;
  border-bottom: 1px solid rgba(255,255,255,0.22);
}

.trend-line span {
  height: 28px;
  border-radius: 6px 6px 0 0;
  background: rgba(255,255,255,0.7);
}
.trend-line span:nth-child(2) { height: 44px; }
.trend-line span:nth-child(3) { height: 34px; }
.trend-line span:nth-child(4) { height: 55px; }
.trend-line span:nth-child(5) { height: 49px; }
.trend-line span:nth-child(6) { height: 66px; background: #fff; }

.wallet-strip {
  display: grid;
  justify-items: center;
  text-align: center;
  gap: 6px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 12px 28px rgba(0,0,0,0.06);
}
.wallet-strip p { margin-bottom: 0; font-size: 0.78rem; }
.wallet-strip button { min-height: 34px; padding: 0 12px; }

.wallet-strip strong,
.wallet-strip small {
  max-width: 100%;
  overflow-wrap: anywhere;
}

.crypto-address-copy {
  width: 100%;
  margin-top: 6px;
  border: 1px solid #050505;
  background: #050505;
  color: #fff;
}

.crypto-wallet-card {
  display: grid;
  gap: 14px;
  padding: 20px;
  border-radius: 8px;
  color: #fff;
  background: linear-gradient(140deg, #1b1b1b 0%, #050505 58%, #141414 100%);
  box-shadow: 0 24px 48px rgba(0, 0, 0, 0.24);
}

.desktop-capital-panel,
.desktop-finance-banners {
  display: none;
}

.crypto-wallet-card .eyebrow,
.crypto-wallet-card p {
  color: rgba(255,255,255,0.76);
}

.crypto-orbit {
  width: 58px;
  height: 58px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255,255,255,0.28);
  border-radius: 50%;
  background: #fff;
  color: #050505;
  font-size: 1.5rem;
  font-weight: 950;
  box-shadow: 0 12px 30px rgba(255, 255, 255, 0.16);
}

.crypto-balance-line {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 12px;
  padding-top: 8px;
  border-top: 1px solid rgba(255,255,255,0.18);
}

.crypto-balance-line span {
  color: rgba(255,255,255,0.66);
  font-weight: 850;
}

.crypto-balance-line strong {
  font-size: 1.7rem;
}

.wallet-meta-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}

.wallet-meta-grid div {
  display: grid;
  gap: 3px;
  min-height: 58px;
  padding: 10px;
  border: 1px solid rgba(255,255,255,0.14);
  border-radius: 8px;
  background: rgba(255,255,255,0.07);
}

.wallet-meta-grid span {
  color: rgba(255,255,255,0.62);
  font-size: 0.68rem;
  font-weight: 850;
}

.wallet-meta-grid b {
  color: #fff;
  font-size: 0.82rem;
}

.crypto-address-strip {
  display: grid;
  justify-items: center;
  text-align: center;
  gap: 10px;
  margin-top: 14px;
  padding: 14px;
}

.crypto-address-strip strong {
  width: min(100%, 520px);
  overflow-wrap: anywhere;
  padding: 12px;
  border-radius: 8px;
  background: #f5f5f5;
  color: #050505;
  font-size: 0.92rem;
  line-height: 1.45;
}

.crypto-address-strip small {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 850;
}

.crypto-address-strip .crypto-address-copy {
  width: min(100%, 520px);
}

.wallet-info-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 12px;
}

.wallet-info-grid article {
  display: grid;
  gap: 6px;
  min-height: 72px;
  padding: 12px;
  border: 1px solid #e7e7e7;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 12px 28px rgba(0,0,0,0.06);
}

.wallet-info-grid span {
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 850;
}

.wallet-info-grid b {
  overflow-wrap: anywhere;
  font-size: 0.84rem;
}

.crypto-section-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 18px 2px 8px;
  font-weight: 950;
}

.crypto-section-title b {
  padding: 5px 9px;
  border-radius: 999px;
  background: #050505;
  color: #fff;
  font-size: 0.72rem;
}

.crypto-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  width: 100%;
}

.crypto-actions button,
.crypto-actions a,
.crypto-form button {
  width: 100%;
  min-height: 42px;
  display: grid;
  place-items: center;
  justify-content: center;
  align-content: center;
  border: 0;
  border-radius: 8px;
  background: #050505;
  color: #fff;
  font-weight: 900;
  text-decoration: none;
  text-align: center;
}

.wallet-strip .crypto-actions button {
  min-height: 44px;
  padding: 0;
}

.crypto-form {
  display: grid;
  gap: 12px;
  margin-top: 12px;
  padding: 16px;
  border: 1px solid #111;
  border-radius: 8px;
  background: #080808;
  color: #fff;
  box-shadow: 0 18px 42px rgba(0,0,0,0.20);
}

.crypto-form label {
  display: grid;
  gap: 7px;
  font-size: 0.82rem;
  font-weight: 850;
}

.crypto-form input {
  min-height: 50px;
  width: 100%;
  padding: 0 14px;
  border: 1px solid rgba(255,255,255,0.14);
  border-radius: 8px;
  background: rgba(255,255,255,0.08);
  color: #fff;
}

.paste-control {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: stretch;
  min-height: 50px;
  overflow: hidden;
  border: 1px solid rgba(255,255,255,0.14);
  border-radius: 8px;
  background: rgba(255,255,255,0.08);
}

.paste-control input {
  min-height: 48px;
  border: 0;
  border-radius: 0;
  background: transparent;
  text-align: center;
}

.paste-control button {
  width: auto;
  min-width: 76px;
  min-height: 48px;
  padding: 0 14px;
  border: 0;
  border-left: 1px solid rgba(255,255,255,0.14);
  border-radius: 0;
  background: rgba(255,255,255,0.12);
  color: #fff;
  box-shadow: none;
}

.crypto-form input::placeholder {
  color: rgba(255,255,255,0.48);
  text-align: center;
}

.crypto-form button {
  background: #fff;
  color: #050505;
}

.positions {
  display: grid;
  gap: 8px;
}
.positions article {
  min-height: 62px;
  padding: 12px;
  border-radius: 8px;
  background: #fff;
}
.positions div { flex: 1; }
.asset-dot { width: 12px; height: 12px; border-radius: 50%; }
.green { background: var(--teal); }
.gold { background: var(--gold); }
.red { background: var(--red); }
.up { color: #177245; }
.down { color: var(--red); }

.fine-print {
  margin: 0;
  font-size: 0.82rem;
}

.mobile-product .client-header,
.mobile-product .section-head.compact,
.mobile-product .balance-panel,
.mobile-product .status-card,
.mobile-product .asset-stack-title,
.mobile-product .asset-row,
.mobile-product .address-row,
.mobile-product .crypto-wallet-card,
.mobile-product .wallet-strip,
.mobile-product .wallet-info-grid article,
.mobile-product .crypto-section-title,
.mobile-product .crypto-form,
.mobile-product .transaction-row,
.mobile-product .empty-state,
.mobile-product .support-heading,
.mobile-product .support-card,
.mobile-product .support-history-card,
.mobile-product .support-ticket-row,
.mobile-product .settings-card {
  text-align: center;
}

.mobile-product .client-header,
.mobile-product .section-head.compact,
.mobile-product .balance-top,
.mobile-product .ledger-state,
.mobile-product .asset-stack-title,
.mobile-product .crypto-balance-line,
.mobile-product .crypto-section-title,
.mobile-product .support-heading,
.mobile-product .settings-row,
.mobile-product .transaction-row,
.mobile-product .support-ticket-row div {
  justify-content: center;
}

.mobile-product .client-header,
.mobile-product .section-head.compact {
  display: grid;
  justify-items: center;
}

.mobile-product .balance-top,
.mobile-product .ledger-state,
.mobile-product .crypto-balance-line,
.mobile-product .crypto-section-title,
.mobile-product .support-heading,
.mobile-product .settings-row {
  flex-wrap: wrap;
}

.mobile-product .asset-row {
  grid-template-columns: 1fr;
  justify-items: center;
}

.mobile-product .asset-row span:nth-child(2) {
  display: grid;
  justify-items: center;
}

.mobile-product .crypto-wallet-card,
.mobile-product .wallet-meta-grid div,
.mobile-product .wallet-info-grid article {
  justify-items: center;
}

.mobile-product .crypto-orbit,
.mobile-product .token-mark {
  margin: 0 auto;
}

.mobile-product .crypto-form label {
  text-align: center;
}

.mobile-product .crypto-form input,
.mobile-product .support-compose input,
.mobile-product .verification-form input {
  text-align: center;
}

.mobile-product .transaction-row {
  display: grid;
  justify-items: center;
}

.support-screen {
  min-height: calc(100vh - 190px);
}

.support-heading {
  align-items: flex-start;
}

.support-status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 10px;
  border-radius: 999px;
  background: #e8f7ee;
  color: #177245;
  font-size: 0.76rem;
  font-weight: 950;
  white-space: nowrap;
}

.support-status::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #1bbf68;
  box-shadow: 0 0 0 4px rgba(27, 191, 104, 0.14);
}

.support-card {
  display: grid;
  min-height: 430px;
  grid-template-rows: 1fr auto;
  overflow: hidden;
  border: 1px solid rgba(16, 20, 23, 0.08);
  border-radius: 12px;
  background: linear-gradient(180deg, #ffffff 0%, #f5f8f8 100%);
  box-shadow: 0 16px 40px rgba(16, 20, 23, 0.1);
}

.support-history-card {
  display: grid;
  gap: 10px;
  margin-top: 14px;
}

.support-ticket-list {
  display: grid;
  gap: 8px;
}

.support-ticket-row {
  display: grid;
  gap: 8px;
  padding: 12px;
  border: 1px solid #e7e7e7;
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 12px 28px rgba(0,0,0,0.06);
}

.support-ticket-row.active,
.chat-ticket.active {
  border-color: rgba(121, 85, 255, 0.58);
  box-shadow: 0 16px 34px rgba(70, 49, 160, 0.16);
}

.session-row p {
  font-size: 0.78rem;
  line-height: 1.35;
}

.support-ticket-row p {
  margin: 0;
  color: #111;
  overflow-wrap: anywhere;
}

.support-chat {
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: 280px;
  padding: 14px;
  overflow-y: auto;
}

.support-chat p { margin: 0; }

.chat-bubble {
  display: grid;
  gap: 4px;
  max-width: 86%;
  padding: 11px 12px;
  border-radius: 12px;
  line-height: 1.35;
}

.chat-bubble b {
  color: inherit;
  font-size: 0.76rem;
  font-weight: 950;
}

.chat-bubble span {
  color: inherit;
}

.support-bubble {
  align-self: flex-start;
  background: #fff;
  border: 1px solid var(--line);
  color: var(--ink);
}

.client-bubble {
  align-self: flex-end;
  background: var(--charcoal);
  color: #fff;
}

.support-chat .client-bubble {
  color: #fff;
}

.support-compose {
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
  padding: 12px;
  border-top: 1px solid rgba(16, 20, 23, 0.08);
  background: rgba(255, 255, 255, 0.9);
}

.support-compose input {
  min-height: 52px;
  border-radius: 12px;
  background: #fff;
  font-size: 1rem;
}

.chat-form .send-button {
  display: inline-grid;
  min-width: 104px;
  min-height: 52px;
  grid-template-columns: auto auto;
  place-items: center;
  gap: 7px;
  border-radius: 12px;
  border: 1px solid #050505;
  background: #fff;
  color: #050505;
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.10);
}

.chat-form .send-button span,
.chat-form .send-button b {
  color: inherit;
  line-height: 1;
}

.banking-summary ul {
  display: grid;
  gap: 10px;
  margin: 12px 0 0;
  padding-left: 18px;
  color: var(--muted);
  line-height: 1.5;
}

.flow-grid,
.security-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
}

.security-grid { grid-template-columns: repeat(3, 1fr); }

.flow-grid article,
.security-grid article {
  padding: 16px;
}

.flow-grid span {
  display: grid;
  width: 34px;
  height: 34px;
  margin-bottom: 12px;
  place-items: center;
  border-radius: 8px;
  background: var(--teal);
  color: #fff;
  font-weight: 900;
}

.toast {
  position: fixed;
  top: 24px;
  right: 24px;
  bottom: auto;
  max-width: min(430px, calc(100vw - 32px));
  min-height: 56px;
  display: grid;
  align-items: center;
  padding: 14px 18px 14px 20px;
  border: 1px solid rgba(196, 181, 253, 0.32);
  border-radius: 16px;
  background:
    radial-gradient(circle at 12% 0%, rgba(167, 139, 250, .34), transparent 36%),
    linear-gradient(135deg, rgba(18, 15, 42, .98), rgba(45, 31, 99, .98));
  color: #fff;
  font-size: .96rem;
  font-weight: 850;
  line-height: 1.35;
  box-shadow: 0 24px 70px rgba(20, 12, 55, 0.42);
  transform: translateY(-16px) scale(.98);
  opacity: 0;
  pointer-events: none;
  transition: opacity 180ms ease, transform 180ms ease;
  z-index: 10000;
}
.toast.visible { transform: translateY(0) scale(1); opacity: 1; }

:root[data-theme="purple-dark"] .crm-shell-body {
  background: linear-gradient(135deg, #060911 0%, #08101c 52%, #060b14 100%);
}

:root[data-theme="purple-dark"] .crm-page {
  width: min(1440px, calc(100% - 32px));
  padding-top: 18px;
}

:root[data-theme="purple-dark"] .crm-page .topbar {
  min-height: 68px;
  margin-bottom: 22px;
  padding: 12px;
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 15px;
  background: linear-gradient(180deg, rgba(9,17,30,0.96), rgba(6,11,20,0.96));
  box-shadow: 0 18px 42px rgba(0,0,0,0.28);
}

:root[data-theme="purple-dark"] .crm-page .section-head {
  margin-bottom: 18px;
  padding: 16px;
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 15px;
  background: rgba(13,20,33,0.82);
}

:root[data-theme="purple-dark"] .crm-page .section-head h1,
:root[data-theme="purple-dark"] .crm-page .section-head .eyebrow {
  color: #f5f7fb;
}

:root[data-theme="purple-dark"] .crm-page .access-badge {
  background: rgba(79,140,255,0.12);
  color: #7badff;
}

.crm-table-head {
  display: none;
}

:root[data-theme="purple-dark"] .crm-table-head {
  display: grid;
  grid-template-columns: 2fr 1fr 1.2fr 1fr 1.1fr .8fr;
  gap: 12px;
  padding: 13px 18px;
  border: 1px solid rgba(255,255,255,0.08);
  border-bottom: 0;
  border-radius: 15px 15px 0 0;
  background: rgba(255,255,255,0.025);
  color: #64738b;
  font-size: 0.68rem;
  font-weight: 900;
  letter-spacing: .7px;
  text-transform: uppercase;
}

:root[data-theme="purple-dark"] .crm-page .crm-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}

:root[data-theme="purple-dark"] .crm-page .client-list,
:root[data-theme="purple-dark"] .crm-page .client-detail,
:root[data-theme="purple-dark"] .crm-page .comments-panel,
:root[data-theme="purple-dark"] .crm-page .metric-row,
:root[data-theme="purple-dark"] .crm-page .chat-ticket,
:root[data-theme="purple-dark"] .crm-page .transaction-row {
  border-color: rgba(255,255,255,0.08);
  background: rgba(13,20,33,0.82);
  color: #f5f7fb;
  box-shadow: 0 18px 42px rgba(0,0,0,0.24);
}

:root[data-theme="purple-dark"] .crm-page .mini-tabs {
  margin-bottom: 0;
  border: 1px solid rgba(255,255,255,0.08);
  background: rgba(255,255,255,0.035);
}

:root[data-theme="purple-dark"] .crm-page .mini-tabs .active {
  background: linear-gradient(135deg, rgba(79,140,255,0.24), rgba(139,92,246,0.18));
  color: #fff;
  box-shadow: inset 3px 0 #4f8cff;
}

:root[data-theme="purple-dark"] .crm-page .crm-list {
  display: grid;
}

:root[data-theme="purple-dark"] .crm-page #applications .crm-list {
  border: 1px solid rgba(255,255,255,0.08);
  border-top: 0;
  border-radius: 0 0 15px 15px;
  overflow: hidden;
  background: rgba(13,20,33,0.82);
}

:root[data-theme="purple-dark"] .crm-page .request-card {
  display: grid;
  grid-template-columns: 2fr 1fr 1.2fr 1fr 1.1fr .8fr;
  align-items: center;
  gap: 12px;
  min-height: 66px;
  padding: 10px 18px;
  border: 0;
  border-top: 1px solid rgba(255,255,255,0.045);
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  text-align: left;
}

:root[data-theme="purple-dark"] .crm-page .request-card:hover {
  background: rgba(79,140,255,0.055);
}

:root[data-theme="purple-dark"] .crm-page .request-card.selected {
  background: linear-gradient(90deg, rgba(79,140,255,0.18), rgba(79,140,255,0.04));
  box-shadow: inset 3px 0 #4f8cff;
}

:root[data-theme="purple-dark"] .crm-page .request-card b,
:root[data-theme="purple-dark"] .crm-page .request-card strong {
  color: #f5f7fb;
}

:root[data-theme="purple-dark"] .crm-page .request-card span,
:root[data-theme="purple-dark"] .crm-page .request-card small {
  color: #7d8aa1;
}

:root[data-theme="purple-dark"] .crm-page .request-card em {
  justify-self: start;
  padding: 6px 8px;
  border-radius: 7px;
  background: rgba(34,197,94,0.08);
  color: #4ade80;
  font-size: 0.72rem;
  font-style: normal;
  font-weight: 850;
}

.crm-page .client-detail {
  display: none;
}

.crm-page.detail-open .client-list {
  display: none;
}

.crm-page.detail-open .client-detail {
  display: grid;
  gap: 14px;
}

.crm-back-button {
  min-height: 38px;
  justify-self: start;
  padding: 0 14px;
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 10px;
  background: rgba(255,255,255,0.045);
  color: #fff;
  font-weight: 850;
}

:root[data-theme="purple-dark"] .crm-page .detail-top {
  padding: 24px;
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 17px;
  background: linear-gradient(135deg, rgba(79,140,255,0.13), rgba(13,20,33,0.88) 42%, rgba(13,20,33,0.82));
}

:root[data-theme="purple-dark"] .crm-page .balance-pill {
  border: 1px solid rgba(79,140,255,0.18);
  border-radius: 12px;
  background: rgba(79,140,255,0.08);
}

:root[data-theme="purple-dark"] .crm-page .action-grid a,
:root[data-theme="purple-dark"] .crm-page .comment-form button,
:root[data-theme="purple-dark"] .crm-page .chat-ticket button,
:root[data-theme="purple-dark"] .crm-page .support-ticket-row button {
  border-color: rgba(79,140,255,0.28);
  background: linear-gradient(135deg, #4f8cff, #6366f1);
  color: #fff;
}

:root[data-theme="purple-dark"] .mobile-product {
  background: #060911;
}

:root[data-theme="purple-dark"] .mobile-shell {
  background: linear-gradient(180deg, #08101c 0%, #060911 100%);
}

:root[data-theme="purple-dark"] .mobile-product .balance-panel,
:root[data-theme="purple-dark"] .mobile-product .crypto-wallet-card {
  background: linear-gradient(135deg, rgba(79,140,255,0.18), #0d1421 45%, #060b14);
  border: 1px solid rgba(255,255,255,0.08);
}

:root[data-theme="purple-dark"] .mobile-product .quick-grid button,
:root[data-theme="purple-dark"] .mobile-product .asset-row,
:root[data-theme="purple-dark"] .mobile-product .address-row,
:root[data-theme="purple-dark"] .mobile-product .wallet-strip,
:root[data-theme="purple-dark"] .mobile-product .settings-card,
:root[data-theme="purple-dark"] .mobile-product .support-card,
:root[data-theme="purple-dark"] .mobile-product .support-history-card,
:root[data-theme="purple-dark"] .mobile-product .transaction-row {
  border-color: rgba(255,255,255,0.08);
  background: rgba(13,20,33,0.86);
  color: #f5f7fb;
}

:root[data-theme="purple-dark"] .mobile-product .quick-grid span,
:root[data-theme="purple-dark"] .mobile-product .token-mark {
  background: linear-gradient(135deg, #4f8cff, #8b5cf6);
  color: #fff;
}

:root[data-theme="purple-dark"] .auth-hero,
:root[data-theme="purple-dark"] .auth-form,
:root[data-theme="purple-dark"] .forgot-form,
:root[data-theme="purple-dark"] .reset-form,
:root[data-theme="purple-dark"] .profile-card,
:root[data-theme="purple-dark"] .settings-card,
:root[data-theme="purple-dark"] .asset-row,
:root[data-theme="purple-dark"] .address-row,
:root[data-theme="purple-dark"] .wallet-strip,
:root[data-theme="purple-dark"] .wallet-info-grid article,
:root[data-theme="purple-dark"] .transaction-row,
:root[data-theme="purple-dark"] .empty-state,
:root[data-theme="purple-dark"] .support-card,
:root[data-theme="purple-dark"] .support-history-card,
:root[data-theme="purple-dark"] .support-ticket-row,
:root[data-theme="purple-dark"] .quick-grid button,
:root[data-theme="purple-dark"] .bank-form,
:root[data-theme="purple-dark"] .client-list,
:root[data-theme="purple-dark"] .client-detail,
:root[data-theme="purple-dark"] .request-card,
:root[data-theme="purple-dark"] .metric-row,
:root[data-theme="purple-dark"] .chat-ticket,
:root[data-theme="purple-dark"] .comments-panel {
  border-color: #252525;
  background: #101010;
  color: #f6f6f6;
  box-shadow: 0 14px 34px rgba(0,0,0,0.42);
}

:root[data-theme="purple-dark"] .request-card.selected {
  border-color: #fff;
  background: #181818;
}

:root[data-theme="purple-dark"] .detail-top {
  border-bottom-color: #252525;
}

:root[data-theme="purple-dark"] .balance-pill {
  border: 1px solid #303030;
  background: #050505;
}

:root[data-theme="purple-dark"] .balance-pill strong {
  color: #fff;
}

:root[data-theme="purple-dark"] .comment-feed,
:root[data-theme="purple-dark"] .comment-feed p {
  border-color: #303030;
  background: #050505;
  color: #f6f6f6;
}

:root[data-theme="purple-dark"] .comment-feed .empty-state {
  border-color: #303030;
  background: #050505;
  color: #f6f6f6;
}

:root[data-theme="purple-dark"] .staff-link {
  border: 1px solid #2d2d2d;
  background: #050505;
  color: #fff;
  box-shadow: 0 12px 26px rgba(0,0,0,0.36);
}

:root[data-theme="purple-dark"] .comment-form input {
  border-color: #303030;
  background: #050505;
  color: #f6f6f6;
}

:root[data-theme="purple-dark"] .action-grid button,
:root[data-theme="purple-dark"] .action-grid a,
:root[data-theme="purple-dark"] .comment-form button,
:root[data-theme="purple-dark"] .tx-actions button,
:root[data-theme="purple-dark"] .chat-ticket button,
:root[data-theme="purple-dark"] .support-ticket-row button {
  border: 1px solid #fff;
  background: #fff;
  color: #050505;
  box-shadow: 0 12px 26px rgba(255,255,255,0.10);
}

:root[data-theme="purple-dark"] .auth-hero {
  background: linear-gradient(135deg, #111 0%, #050505 100%);
}

:root[data-theme="purple-dark"] .asset-stack-title {
  color: #f6f6f6;
}

:root[data-theme="purple-dark"] .balance-panel,
:root[data-theme="purple-dark"] .crypto-wallet-card,
:root[data-theme="purple-dark"] .crypto-form {
  border-color: #2d2d2d;
  background: #050505;
  color: #fff;
}

:root[data-theme="purple-dark"] input,
:root[data-theme="purple-dark"] select,
:root[data-theme="purple-dark"] textarea,
:root[data-theme="purple-dark"] .amount-control,
:root[data-theme="purple-dark"] .paste-control {
  border-color: #2c2c2c;
  background: #050505;
  color: #f6f6f6;
}

:root[data-theme="purple-dark"] .token-mark,
:root[data-theme="purple-dark"] .quick-grid span,
:root[data-theme="purple-dark"] .address-row button {
  background: #fff;
  color: #050505;
}

:root[data-theme="purple-dark"] .settings-action-button,
:root[data-theme="purple-dark"] .crypto-address-copy,
:root[data-theme="purple-dark"] .crypto-form button {
  border-color: #fff;
  background: #fff;
  color: #050505;
}

:root[data-theme="purple-dark"] .toast {
  background: #fff;
  color: #050505;
}

:root[data-theme="purple-dark"] .client-header,
:root[data-theme="purple-dark"] .section-head.compact,
:root[data-theme="purple-dark"] .support-heading {
  display: grid;
  min-height: 74px;
  align-content: center;
  justify-items: center;
  padding: 12px;
  border: 1px solid #252525;
  border-radius: 8px;
  background: #101010;
  color: #f6f6f6;
  box-shadow: 0 14px 34px rgba(0,0,0,0.34);
}

:root[data-theme="purple-dark"] .support-heading {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  justify-items: stretch;
}

:root[data-theme="purple-dark"] .support-heading > div {
  display: grid;
  justify-items: center;
}

:root[data-theme="purple-dark"] .section-head.compact .eyebrow {
  color: #fff;
}

:root[data-theme="purple-dark"] .client-detail .eyebrow {
  color: #fff;
}

:root[data-theme="purple-dark"] .panel-title span {
  background: #fff;
  color: #050505;
}

:root[data-theme="purple-dark"] .verification-grid button,
:root[data-theme="purple-dark"] .verification-form button,
:root[data-theme="purple-dark"] .settings-action-button,
:root[data-theme="purple-dark"] .support-compose button,
:root[data-theme="purple-dark"] .send-button {
  border: 1px solid #fff;
  background: #fff;
  color: #050505;
  box-shadow: 0 12px 26px rgba(255,255,255,0.10);
}

:root[data-theme="purple-dark"] .verification-grid button *,
:root[data-theme="purple-dark"] .verification-form button *,
:root[data-theme="purple-dark"] .settings-action-button *,
:root[data-theme="purple-dark"] .support-compose button *,
:root[data-theme="purple-dark"] .send-button * {
  color: #050505;
}

:root[data-theme="purple-dark"] .support-status {
  background: #102417;
  color: #8df0b8;
}

:root[data-theme="purple-dark"] .support-bubble,
:root[data-theme="purple-dark"] .chat-bubble {
  background: #050505;
  color: #f6f6f6;
}

:root[data-theme="purple-dark"] .support-compose {
  border-top-color: #303030;
  background: #242424;
}

:root[data-theme="purple-dark"] .support-compose input {
  border-color: #fff;
  background: #fff;
  color: #050505;
}

:root[data-theme="purple-dark"] .support-compose input::placeholder {
  color: #5f5f5f;
}

:root[data-theme="purple-dark"] .logout-button {
  border-color: #ff6b6b;
  background: linear-gradient(135deg, #b42318 0%, #7f1d1d 100%);
  color: #fff;
  box-shadow: 0 14px 30px rgba(180, 35, 24, 0.28);
}

:root[data-theme="purple-dark"] .crypto-section-title {
  color: #f6f6f6;
}

:root[data-theme="purple-dark"] .crypto-section-title b {
  background: #fff;
  color: #050505;
}

/* Final product theme overrides inspired by the CRM control-center reference. */
:root[data-theme="dark"] body {
  background: linear-gradient(180deg, #000 0%, #070707 48%, #111 100%);
  color: #f6f6f6;
}

:root[data-theme="dark"] .brand-mark {
  border: 1px solid rgba(255,255,255,0.24);
  background: #fff;
  color: #050505;
}

:root[data-theme="dark"] .language-switch,
:root[data-theme="dark"] .theme-switch,
:root[data-theme="dark"] .mini-tabs,
:root[data-theme="dark"] .product-tabs,
:root[data-theme="dark"] .app-menu {
  background: #191919;
}

:root[data-theme="dark"] .language-switch .active,
:root[data-theme="dark"] .theme-switch .active,
:root[data-theme="dark"] .mini-tabs .active,
:root[data-theme="dark"] .product-tabs .active,
:root[data-theme="dark"] .app-menu .active {
  background: #fff;
  color: #050505;
}

:root[data-theme="dark"] .crm-shell-body,
:root[data-theme="dark"] .mobile-product {
  background: #000;
}

:root[data-theme="dark"] .mobile-shell {
  background: #050505;
}

:root[data-theme="dark"] .crm-page .topbar,
:root[data-theme="dark"] .crm-page .section-head,
:root[data-theme="dark"] .crm-page .client-list,
:root[data-theme="dark"] .crm-page .client-detail,
:root[data-theme="dark"] .crm-page .comments-panel,
:root[data-theme="dark"] .crm-page .metric-row,
:root[data-theme="dark"] .crm-page .chat-ticket,
:root[data-theme="dark"] .crm-page .transaction-row,
:root[data-theme="dark"] .mobile-product .quick-grid button,
:root[data-theme="dark"] .mobile-product .asset-row,
:root[data-theme="dark"] .mobile-product .address-row,
:root[data-theme="dark"] .mobile-product .wallet-strip,
:root[data-theme="dark"] .mobile-product .wallet-info-grid article,
:root[data-theme="dark"] .mobile-product .settings-card,
:root[data-theme="dark"] .mobile-product .support-card,
:root[data-theme="dark"] .mobile-product .support-history-card,
:root[data-theme="dark"] .mobile-product .transaction-row,
:root[data-theme="dark"] .mobile-product .empty-state {
  border-color: #252525;
  background: #101010;
  color: #f6f6f6;
  box-shadow: 0 14px 34px rgba(0,0,0,0.42);
}

:root[data-theme="dark"] .crm-page .detail-top,
:root[data-theme="dark"] .mobile-product .balance-panel,
:root[data-theme="dark"] .mobile-product .crypto-wallet-card,
:root[data-theme="dark"] .crypto-form {
  border-color: #2d2d2d;
  background: #050505;
  color: #fff;
}

:root[data-theme="dark"] .crm-page .action-grid a,
:root[data-theme="dark"] .crm-page .comment-form button,
:root[data-theme="dark"] .crm-back-button,
:root[data-theme="dark"] .verification-grid button,
:root[data-theme="dark"] .verification-form button,
:root[data-theme="dark"] .settings-action-button,
:root[data-theme="dark"] .support-compose button,
:root[data-theme="dark"] .send-button,
:root[data-theme="dark"] .crypto-address-copy,
:root[data-theme="dark"] .crypto-form button {
  border-color: #fff;
  background: #fff;
  color: #050505;
}

:root[data-theme="dark"] .mobile-product .quick-grid span,
:root[data-theme="dark"] .mobile-product .token-mark,
:root[data-theme="dark"] .mobile-product .crypto-orbit {
  background: #fff;
  color: #050505;
}

:root[data-theme="purple-light"] body {
  background: linear-gradient(180deg, #fbf9ff 0%, #f2ecff 100%);
  color: #171226;
}

:root[data-theme="purple-light"] .brand-mark,
:root[data-theme="purple-light"] .mobile-product .quick-grid span,
:root[data-theme="purple-light"] .mobile-product .token-mark,
:root[data-theme="purple-light"] .mobile-product .crypto-orbit {
  background: linear-gradient(135deg, #7c3aed, #a855f7);
  color: #fff;
}

:root[data-theme="purple-light"] .language-switch,
:root[data-theme="purple-light"] .theme-switch,
:root[data-theme="purple-light"] .mini-tabs,
:root[data-theme="purple-light"] .product-tabs,
:root[data-theme="purple-light"] .app-menu {
  background: #eee7ff;
}

:root[data-theme="purple-light"] .language-switch .active,
:root[data-theme="purple-light"] .theme-switch .active,
:root[data-theme="purple-light"] .mini-tabs .active,
:root[data-theme="purple-light"] .product-tabs .active,
:root[data-theme="purple-light"] .app-menu .active {
  background: #fff;
  color: #4c1d95;
}

:root[data-theme="purple-light"] .crm-shell-body,
:root[data-theme="purple-light"] .mobile-product {
  background: #f6f2ff;
}

:root[data-theme="purple-light"] .mobile-shell {
  background: linear-gradient(180deg, #ffffff 0%, #f6f2ff 100%);
}

:root[data-theme="purple-light"] .crm-page .topbar,
:root[data-theme="purple-light"] .crm-page .section-head,
:root[data-theme="purple-light"] .crm-page .client-list,
:root[data-theme="purple-light"] .crm-page .client-detail,
:root[data-theme="purple-light"] .crm-page .comments-panel,
:root[data-theme="purple-light"] .crm-page .metric-row,
:root[data-theme="purple-light"] .crm-page .chat-ticket,
:root[data-theme="purple-light"] .crm-page .transaction-row,
:root[data-theme="purple-light"] .mobile-product .quick-grid button,
:root[data-theme="purple-light"] .mobile-product .asset-row,
:root[data-theme="purple-light"] .mobile-product .address-row,
:root[data-theme="purple-light"] .mobile-product .wallet-strip,
:root[data-theme="purple-light"] .mobile-product .wallet-info-grid article,
:root[data-theme="purple-light"] .mobile-product .settings-card,
:root[data-theme="purple-light"] .mobile-product .support-card,
:root[data-theme="purple-light"] .mobile-product .support-history-card,
:root[data-theme="purple-light"] .mobile-product .transaction-row,
:root[data-theme="purple-light"] .mobile-product .empty-state {
  border-color: #ddd5ef;
  background: rgba(255,255,255,0.92);
  color: #171226;
  box-shadow: 0 14px 34px rgba(109,74,255,0.12);
}

:root[data-theme="purple-light"] .crm-page .detail-top,
:root[data-theme="purple-light"] .mobile-product .balance-panel,
:root[data-theme="purple-light"] .mobile-product .crypto-wallet-card {
  border-color: rgba(124,58,237,0.18);
  background: linear-gradient(135deg, rgba(124,58,237,0.13), #fff 42%, #f6f2ff);
  color: #171226;
}

:root[data-theme="purple-light"] .crm-page .action-grid a,
:root[data-theme="purple-light"] .crm-page .comment-form button,
:root[data-theme="purple-light"] .crm-back-button,
:root[data-theme="purple-light"] .crypto-address-copy,
:root[data-theme="purple-light"] .crypto-form button {
  border-color: rgba(124,58,237,0.28);
  background: linear-gradient(135deg, #7c3aed, #a855f7);
  color: #fff;
}

:root[data-theme="purple-dark"] .crm-page .topbar,
:root[data-theme="purple-dark"] .crm-page .section-head,
:root[data-theme="purple-dark"] .crm-page .client-list,
:root[data-theme="purple-dark"] .crm-page .client-detail,
:root[data-theme="purple-dark"] .crm-page .comments-panel,
:root[data-theme="purple-dark"] .crm-page .metric-row,
:root[data-theme="purple-dark"] .crm-page .chat-ticket,
:root[data-theme="purple-dark"] .crm-page .transaction-row {
  border-color: rgba(255,255,255,0.08);
  background: rgba(13,20,33,0.86);
  color: #f5f7fb;
}

:root[data-theme="purple-dark"] .crm-page .request-card {
  grid-template-columns: 2fr 1fr 1.2fr 1fr 1.1fr .8fr;
  border-color: rgba(255,255,255,0.045);
  background: transparent;
  color: #f5f7fb;
}

:root[data-theme="purple-dark"] .crm-page .request-card:hover,
:root[data-theme="purple-dark"] .crm-page .request-card.selected {
  background: linear-gradient(90deg, rgba(79,140,255,0.18), rgba(79,140,255,0.04));
  box-shadow: inset 3px 0 #4f8cff;
}

:root[data-theme="purple-dark"] .crm-page .detail-top {
  background: linear-gradient(135deg, rgba(79,140,255,0.13), rgba(13,20,33,0.88) 42%, rgba(13,20,33,0.82));
}

:root[data-theme="purple-dark"] .crm-page .action-grid a,
:root[data-theme="purple-dark"] .crm-page .comment-form button,
:root[data-theme="purple-dark"] .crm-back-button {
  border-color: rgba(79,140,255,0.28);
  background: linear-gradient(135deg, #4f8cff, #6366f1);
  color: #fff;
}

:root[data-theme="purple-dark"] .mobile-product .balance-panel,
:root[data-theme="purple-dark"] .mobile-product .crypto-wallet-card {
  background: linear-gradient(135deg, rgba(79,140,255,0.18), #0d1421 45%, #060b14);
  border-color: rgba(255,255,255,0.08);
}

:root[data-theme="purple-dark"] .mobile-product .quick-grid button,
:root[data-theme="purple-dark"] .mobile-product .asset-row,
:root[data-theme="purple-dark"] .mobile-product .address-row,
:root[data-theme="purple-dark"] .mobile-product .wallet-strip,
:root[data-theme="purple-dark"] .mobile-product .wallet-info-grid article,
:root[data-theme="purple-dark"] .mobile-product .settings-card,
:root[data-theme="purple-dark"] .mobile-product .support-card,
:root[data-theme="purple-dark"] .mobile-product .support-history-card,
:root[data-theme="purple-dark"] .mobile-product .transaction-row,
:root[data-theme="purple-dark"] .mobile-product .empty-state {
  border-color: rgba(255,255,255,0.08);
  background: rgba(13,20,33,0.86);
  color: #f5f7fb;
}

:root[data-theme="purple-dark"] .mobile-product .quick-grid span,
:root[data-theme="purple-dark"] .mobile-product .token-mark,
:root[data-theme="purple-dark"] .mobile-product .crypto-orbit {
  background: linear-gradient(135deg, #4f8cff, #8b5cf6);
  color: #fff;
}

:root[data-theme="purple-dark"] .mobile-product .auth-hero,
:root[data-theme="purple-dark"] .mobile-product .auth-form,
:root[data-theme="purple-dark"] .mobile-product .forgot-form,
:root[data-theme="purple-dark"] .mobile-product .reset-form,
:root[data-theme="purple-dark"] .mobile-product .profile-card,
:root[data-theme="purple-dark"] .mobile-product .settings-card,
:root[data-theme="purple-dark"] .mobile-product .asset-row,
:root[data-theme="purple-dark"] .mobile-product .address-row,
:root[data-theme="purple-dark"] .mobile-product .wallet-strip,
:root[data-theme="purple-dark"] .mobile-product .wallet-info-grid article,
:root[data-theme="purple-dark"] .mobile-product .transaction-row,
:root[data-theme="purple-dark"] .mobile-product .empty-state,
:root[data-theme="purple-dark"] .mobile-product .support-card,
:root[data-theme="purple-dark"] .mobile-product .support-history-card,
:root[data-theme="purple-dark"] .mobile-product .support-ticket-row,
:root[data-theme="purple-dark"] .mobile-product .quick-grid button,
:root[data-theme="purple-dark"] .mobile-product .bank-form,
:root[data-theme="purple-dark"] .mobile-product .client-header,
:root[data-theme="purple-dark"] .mobile-product .section-head.compact,
:root[data-theme="purple-dark"] .mobile-product .support-heading,
:root[data-theme="purple-dark"] .mobile-product .crypto-form {
  border-color: rgba(139,92,246,0.18);
  background: linear-gradient(145deg, rgba(18,28,52,0.96), rgba(28,20,58,0.94));
  color: #f7f4ff;
  box-shadow: 0 18px 44px rgba(22,14,54,0.34);
}

:root[data-theme="purple-dark"] .mobile-product .balance-panel,
:root[data-theme="purple-dark"] .mobile-product .crypto-wallet-card {
  border-color: rgba(139,92,246,0.24);
  background:
    radial-gradient(circle at 50% 0%, rgba(139,92,246,0.26), transparent 38%),
    linear-gradient(135deg, #17233f 0%, #20163f 52%, #0d1530 100%);
  color: #fff;
}

:root[data-theme="purple-dark"] .mobile-product input,
:root[data-theme="purple-dark"] .mobile-product select,
:root[data-theme="purple-dark"] .mobile-product textarea,
:root[data-theme="purple-dark"] .mobile-product .amount-control,
:root[data-theme="purple-dark"] .mobile-product .paste-control,
:root[data-theme="purple-dark"] .mobile-product .support-bubble,
:root[data-theme="purple-dark"] .mobile-product .chat-bubble {
  border-color: rgba(139,92,246,0.2);
  background: rgba(11,18,35,0.92);
  color: #f7f4ff;
}

:root[data-theme="purple-dark"] .mobile-product .support-compose {
  border-top-color: rgba(139,92,246,0.18);
  background: rgba(22,17,45,0.94);
}

:root[data-theme="purple-dark"] .mobile-product .support-compose input {
  border-color: rgba(139,92,246,0.2);
  background: #eef0ff;
  color: #151225;
}

:root[data-theme="purple-dark"] .mobile-product .section-head.compact .eyebrow,
:root[data-theme="purple-dark"] .mobile-product .crypto-section-title,
:root[data-theme="purple-dark"] .mobile-product .asset-stack-title {
  color: #f7f4ff;
}

:root[data-theme="purple-light"] .mobile-product .crypto-wallet-card h2 {
  color: #171226;
}

:root[data-theme="purple-light"] .mobile-product .crypto-wallet-card .eyebrow,
:root[data-theme="purple-light"] .mobile-product .crypto-wallet-card p,
:root[data-theme="purple-light"] .mobile-product .crypto-balance-line span,
:root[data-theme="purple-light"] .mobile-product .wallet-meta-grid span {
  color: #62557a;
}

:root[data-theme="purple-light"] .mobile-product .crypto-balance-line {
  border-top-color: rgba(124,58,237,0.16);
}

:root[data-theme="purple-light"] .mobile-product .crypto-balance-line strong,
:root[data-theme="purple-light"] .mobile-product .wallet-meta-grid b {
  color: #171226;
}

:root[data-theme="purple-dark"] .mobile-product .logout-button {
  border-color: rgba(139,92,246,0.34);
  background: linear-gradient(135deg, #4f8cff, #8b5cf6);
  color: #fff;
  box-shadow: 0 14px 30px rgba(79,140,255,0.18);
}

:root[data-theme="purple-dark"] .mobile-product {
  background:
    radial-gradient(circle at 50% -12%, rgba(89,62,196,0.26), transparent 34%),
    linear-gradient(180deg, #091226 0%, #0b1022 52%, #070b18 100%);
}

:root[data-theme="purple-dark"] .mobile-shell {
  background: transparent;
}

:root[data-theme="purple-dark"] .mobile-product .client-header,
:root[data-theme="purple-dark"] .mobile-product .section-head.compact,
:root[data-theme="purple-dark"] .mobile-product .support-heading,
:root[data-theme="purple-dark"] .mobile-product .profile-card,
:root[data-theme="purple-dark"] .mobile-product .settings-card,
:root[data-theme="purple-dark"] .mobile-product .quick-grid button,
:root[data-theme="purple-dark"] .mobile-product .asset-row,
:root[data-theme="purple-dark"] .mobile-product .address-row,
:root[data-theme="purple-dark"] .mobile-product .wallet-strip,
:root[data-theme="purple-dark"] .mobile-product .wallet-info-grid article,
:root[data-theme="purple-dark"] .mobile-product .support-card,
:root[data-theme="purple-dark"] .mobile-product .support-history-card,
:root[data-theme="purple-dark"] .mobile-product .support-ticket-row,
:root[data-theme="purple-dark"] .mobile-product .transaction-row,
:root[data-theme="purple-dark"] .mobile-product .empty-state,
:root[data-theme="purple-dark"] .mobile-product .crypto-form {
  border-color: rgba(148,128,255,0.16);
  background: linear-gradient(145deg, rgba(18,30,58,0.94), rgba(26,21,55,0.94));
  color: #f8f6ff;
  box-shadow: 0 18px 44px rgba(6,10,24,0.36);
}

:root[data-theme="purple-dark"] .mobile-product .client-header .eyebrow,
:root[data-theme="purple-dark"] .mobile-product .section-head.compact .eyebrow,
:root[data-theme="purple-dark"] .mobile-product .settings-card .eyebrow,
:root[data-theme="purple-dark"] .mobile-product .profile-card h2,
:root[data-theme="purple-dark"] .mobile-product .settings-row > span,
:root[data-theme="purple-dark"] .mobile-product .asset-stack-title,
:root[data-theme="purple-dark"] .mobile-product .crypto-section-title,
:root[data-theme="purple-dark"] .mobile-product label > span {
  color: #fff;
}

:root[data-theme="purple-dark"] .mobile-product small,
:root[data-theme="purple-dark"] .mobile-product p,
:root[data-theme="purple-dark"] .mobile-product .fine-print,
:root[data-theme="purple-dark"] .mobile-product .ledger-state,
:root[data-theme="purple-dark"] .mobile-product .settings-row {
  color: #b8b2d8;
}

:root[data-theme="purple-dark"] .mobile-product .balance-panel,
:root[data-theme="purple-dark"] .mobile-product .crypto-wallet-card {
  border-color: rgba(148,128,255,0.22);
  background:
    radial-gradient(circle at 50% -10%, rgba(139,92,246,0.28), transparent 38%),
    linear-gradient(135deg, #17264a 0%, #251a52 55%, #101b39 100%);
  color: #fff;
}

:root[data-theme="purple-dark"] .mobile-product input,
:root[data-theme="purple-dark"] .mobile-product select,
:root[data-theme="purple-dark"] .mobile-product textarea,
:root[data-theme="purple-dark"] .mobile-product .amount-control,
:root[data-theme="purple-dark"] .mobile-product .paste-control,
:root[data-theme="purple-dark"] .mobile-product .support-bubble,
:root[data-theme="purple-dark"] .mobile-product .chat-bubble {
  border-color: rgba(148,128,255,0.18);
  background: rgba(8,16,35,0.92);
  color: #fff;
}

:root[data-theme="purple-dark"] .mobile-product input::placeholder,
:root[data-theme="purple-dark"] .mobile-product textarea::placeholder {
  color: #8f89ad;
}

:root[data-theme="purple-dark"] .mobile-product .language-switch,
:root[data-theme="purple-dark"] .mobile-product .theme-switch,
:root[data-theme="purple-dark"] .mobile-product .bottom-tabs {
  border: 1px solid rgba(148,128,255,0.14);
  background: rgba(10,18,39,0.96);
}

:root[data-theme="purple-dark"] .mobile-product .language-switch .active,
:root[data-theme="purple-dark"] .mobile-product .theme-switch .active,
:root[data-theme="purple-dark"] .mobile-product .bottom-tabs .active,
:root[data-theme="purple-dark"] .mobile-product .verification-grid button,
:root[data-theme="purple-dark"] .mobile-product .verification-form button,
:root[data-theme="purple-dark"] .mobile-product .settings-action-button,
:root[data-theme="purple-dark"] .mobile-product .support-compose button,
:root[data-theme="purple-dark"] .mobile-product .send-button,
:root[data-theme="purple-dark"] .mobile-product .crypto-address-copy,
:root[data-theme="purple-dark"] .mobile-product .crypto-form button,
:root[data-theme="purple-dark"] .mobile-product .address-row button,
:root[data-theme="purple-dark"] .mobile-product .logout-button {
  border-color: rgba(148,128,255,0.32);
  background: linear-gradient(135deg, #4f8cff, #8b5cf6);
  color: #fff;
  box-shadow: 0 14px 30px rgba(79,140,255,0.16);
}

:root[data-theme="purple-dark"] .mobile-product .verification-grid button *,
:root[data-theme="purple-dark"] .mobile-product .verification-form button *,
:root[data-theme="purple-dark"] .mobile-product .settings-action-button *,
:root[data-theme="purple-dark"] .mobile-product .support-compose button *,
:root[data-theme="purple-dark"] .mobile-product .send-button *,
:root[data-theme="purple-dark"] .mobile-product .crypto-form button *,
:root[data-theme="purple-dark"] .mobile-product .logout-button * {
  color: #fff;
}

:root[data-theme="purple-dark"] .mobile-product .paste-control button {
  background: rgba(148,128,255,0.12);
  color: #d9d4ff;
  box-shadow: none;
}

:root[data-theme="purple-dark"] .mobile-product .quick-grid span,
:root[data-theme="purple-dark"] .mobile-product .token-mark,
:root[data-theme="purple-dark"] .mobile-product .crypto-orbit,
:root[data-theme="purple-dark"] .mobile-product .profile-avatar,
:root[data-theme="purple-dark"] .mobile-product .crypto-section-title b {
  background: linear-gradient(135deg, #4f8cff, #8b5cf6);
  color: #fff;
}

:root[data-theme="purple-dark"] .mobile-product .support-status {
  background: rgba(79,140,255,0.14);
  color: #b8caff;
}

:root[data-theme="purple-dark"] .mobile-product .auth-panel {
  color: #f8f6ff;
}

:root[data-theme="purple-dark"] .mobile-product .auth-hero,
:root[data-theme="purple-dark"] .mobile-product .auth-form,
:root[data-theme="purple-dark"] .mobile-product .forgot-form,
:root[data-theme="purple-dark"] .mobile-product .reset-form {
  border-color: rgba(148,128,255,0.16);
  background: linear-gradient(145deg, rgba(18,30,58,0.94), rgba(26,21,55,0.94));
  color: #f8f6ff;
  box-shadow: 0 18px 44px rgba(6,10,24,0.36);
}

:root[data-theme="purple-dark"] .mobile-product .auth-emblem {
  background: linear-gradient(135deg, #4f8cff, #8b5cf6);
  color: #fff;
  box-shadow: 0 14px 30px rgba(79,140,255,0.18);
}

:root[data-theme="purple-dark"] .mobile-product .auth-mode-tabs {
  border: 1px solid rgba(148,128,255,0.14);
  background: rgba(10,18,39,0.96);
}

:root[data-theme="purple-dark"] .mobile-product .auth-mode-tabs button {
  background: transparent;
  color: #b8b2d8;
  box-shadow: none;
}

:root[data-theme="purple-dark"] .mobile-product .auth-mode-tabs .active,
:root[data-theme="purple-dark"] .mobile-product .auth-actions button,
:root[data-theme="purple-dark"] .mobile-product .forgot-button,
:root[data-theme="purple-dark"] .mobile-product .forgot-toggle,
:root[data-theme="purple-dark"] .mobile-product .reset-form button {
  border-color: rgba(148,128,255,0.32);
  background: linear-gradient(135deg, #4f8cff, #8b5cf6);
  color: #fff;
  box-shadow: 0 14px 30px rgba(79,140,255,0.16);
}

:root[data-theme="purple-dark"] .mobile-product .auth-form label,
:root[data-theme="purple-dark"] .mobile-product .forgot-form label,
:root[data-theme="purple-dark"] .mobile-product .reset-form label,
:root[data-theme="purple-dark"] .mobile-product .auth-footnote {
  color: #b8b2d8;
}

:root[data-theme="purple-dark"] .mobile-product .auth-form input,
:root[data-theme="purple-dark"] .mobile-product .forgot-form input,
:root[data-theme="purple-dark"] .mobile-product .reset-form input {
  border-color: rgba(148,128,255,0.18);
  background: rgba(8,16,35,0.92);
  color: #fff;
}

:root[data-theme="purple-dark"] .mobile-product .support-compose {
  border-top-color: rgba(148,128,255,0.16);
  background: rgba(12,20,42,0.94);
}

:root[data-theme="purple-dark"] .mobile-product .support-compose input {
  border-color: rgba(148,128,255,0.18);
  background: rgba(8,16,35,0.96);
  color: #fff;
}

.crm-page {
  width: min(1440px, calc(100% - 32px));
  margin-left: auto;
  margin-right: auto;
}

.crm-page .crm-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}

.crm-page .client-list,
.crm-page .client-detail {
  width: 100%;
}

.crm-table-head {
  display: grid;
  grid-template-columns: 2fr 1fr 1.2fr 1fr 1.1fr .8fr;
  gap: 12px;
  padding: 13px 18px;
  border: 1px solid var(--line);
  border-bottom: 0;
  border-radius: 15px 15px 0 0;
  background: rgba(124,58,237,0.055);
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 900;
  letter-spacing: .7px;
  text-transform: uppercase;
}

.crm-page #applications .crm-list {
  border: 1px solid var(--line);
  border-top: 0;
  border-radius: 0 0 15px 15px;
  overflow: hidden;
  background: var(--surface);
}

.crm-page .request-card {
  display: grid;
  grid-template-columns: 2fr 1fr 1.2fr 1fr 1.1fr .8fr;
  align-items: center;
  gap: 12px;
  min-height: 66px;
  padding: 10px 18px;
  border: 0;
  border-top: 1px solid var(--line);
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.crm-page .request-card:hover,
.crm-page .request-card.selected {
  background: linear-gradient(90deg, rgba(124,58,237,0.11), rgba(124,58,237,0.025));
  box-shadow: inset 3px 0 #8b5cf6;
}

.crm-insight-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}

.crm-insight-grid article,
.crm-chart-panel {
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface);
  box-shadow: 0 10px 28px rgba(16, 20, 23, 0.07);
}

.crm-insight-grid span,
.crm-insight-grid small {
  color: var(--muted);
  font-size: 0.74rem;
  font-weight: 800;
}

.crm-insight-grid b {
  display: block;
  margin: 8px 0 4px;
  color: var(--ink);
  font-size: 1rem;
}

.crm-activity-chart {
  display: flex;
  align-items: end;
  justify-content: center;
  gap: 10px;
  min-height: 150px;
  padding: 12px;
  border-radius: 12px;
  background: rgba(124,58,237,0.055);
}

.crm-activity-chart span {
  width: min(42px, 9%);
  min-height: 12px;
  border-radius: 8px 8px 3px 3px;
  background: linear-gradient(180deg, #8b5cf6, #4f8cff);
}

.crm-activity-chart span.failed {
  background: linear-gradient(180deg, #f87171, #8b5cf6);
}

.crm-activity-chart span.broadcast {
  background: linear-gradient(180deg, #60a5fa, #8b5cf6);
}

.crm-operations-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.crm-withdraw-form {
  display: grid;
  gap: 10px;
}

.crm-withdraw-form label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 850;
}

.crm-withdraw-form input {
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 12px;
}

.crm-withdraw-form button {
  min-height: 44px;
  width: 100%;
  padding: 0 16px;
  border: 0;
  border-radius: 12px;
  background: linear-gradient(135deg, #7c3aed, #a855f7);
  color: #fff;
  font-weight: 900;
  box-shadow: 0 14px 30px rgba(124,58,237,0.18);
}

.crm-message-feed {
  min-height: 150px;
}

.crm-recovery-form {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface);
  box-shadow: 0 10px 28px rgba(16, 20, 23, 0.07);
}

.crm-recovery-form label {
  display: grid;
  gap: 6px;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 850;
}

.crm-recovery-form .full {
  grid-column: 1 / -1;
}

.crm-recovery-form input,
.crm-recovery-form textarea {
  min-height: 42px;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 12px;
}

.crm-recovery-form textarea {
  min-height: 82px;
  padding-top: 10px;
}

.crm-recovery-form button {
  grid-column: 1 / -1;
  min-height: 46px;
  border: 1px solid rgba(124,58,237,0.24);
  border-radius: 12px;
  background: linear-gradient(135deg, #7c3aed, #a855f7);
  color: #fff;
  font-weight: 900;
  box-shadow: 0 14px 30px rgba(124,58,237,0.16);
}

.recovery-list {
  margin-top: 12px;
}

.recovery-card {
  display: grid;
  gap: 8px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface);
  box-shadow: 0 10px 28px rgba(16, 20, 23, 0.07);
}

.recovery-card small,
.recovery-card p {
  color: var(--muted);
  overflow-wrap: anywhere;
}

.recovery-card button {
  justify-self: start;
  min-height: 36px;
  padding: 0 12px;
  border: 1px solid rgba(124,58,237,0.22);
  border-radius: 10px;
  background: rgba(124,58,237,0.09);
  color: #4c1d95;
  font-weight: 850;
}

:root[data-theme="purple-light"] .mobile-product .verification-grid button,
:root[data-theme="purple-light"] .mobile-product .verification-form button,
:root[data-theme="purple-light"] .mobile-product .settings-action-button,
:root[data-theme="purple-light"] .mobile-product .support-compose button,
:root[data-theme="purple-light"] .mobile-product .send-button,
:root[data-theme="purple-light"] .mobile-product .crypto-address-copy,
:root[data-theme="purple-light"] .mobile-product .crypto-form button,
:root[data-theme="purple-light"] .mobile-product .address-row button,
:root[data-theme="purple-light"] .mobile-product .logout-button,
:root[data-theme="purple-light"] .mobile-product .paste-control button {
  border-color: rgba(124,58,237,0.24);
  background: linear-gradient(135deg, #7c3aed, #a855f7);
  color: #fff;
  box-shadow: 0 14px 30px rgba(124,58,237,0.16);
}

:root[data-theme="purple-light"] .mobile-product .verification-grid button *,
:root[data-theme="purple-light"] .mobile-product .verification-form button *,
:root[data-theme="purple-light"] .mobile-product .settings-action-button *,
:root[data-theme="purple-light"] .mobile-product .support-compose button *,
:root[data-theme="purple-light"] .mobile-product .send-button *,
:root[data-theme="purple-light"] .mobile-product .logout-button * {
  color: #fff;
}

:root[data-theme="purple-dark"] .crm-shell-body {
  background:
    radial-gradient(circle at 50% -14%, rgba(89,62,196,0.24), transparent 34%),
    linear-gradient(180deg, #091226 0%, #0b1022 52%, #070b18 100%);
}

:root[data-theme="purple-dark"] .crm-page .topbar,
:root[data-theme="purple-dark"] .crm-page .section-head,
:root[data-theme="purple-dark"] .crm-page .client-list,
:root[data-theme="purple-dark"] .crm-page .client-detail,
:root[data-theme="purple-dark"] .crm-page .comments-panel,
:root[data-theme="purple-dark"] .crm-page .metric-row,
:root[data-theme="purple-dark"] .crm-page .chat-ticket,
:root[data-theme="purple-dark"] .crm-page .transaction-row,
:root[data-theme="purple-dark"] .crm-page .support-ticket-row {
  border-color: rgba(148,128,255,0.16);
  background: linear-gradient(145deg, rgba(18,30,58,0.94), rgba(26,21,55,0.94));
  color: #f8f6ff;
  box-shadow: 0 18px 44px rgba(6,10,24,0.34);
}

:root[data-theme="purple-dark"] .crm-page .section-head h1,
:root[data-theme="purple-dark"] .crm-page .section-head .eyebrow,
:root[data-theme="purple-dark"] .crm-page .detail-top h2,
:root[data-theme="purple-dark"] .crm-page .panel-title h2,
:root[data-theme="purple-dark"] .crm-page .panel-title span,
:root[data-theme="purple-dark"] .crm-page .request-card b,
:root[data-theme="purple-dark"] .crm-page .request-card strong {
  color: #fff;
}

:root[data-theme="purple-dark"] .crm-page .section-head p,
:root[data-theme="purple-dark"] .crm-page .request-card span,
:root[data-theme="purple-dark"] .crm-page .request-card small,
:root[data-theme="purple-dark"] .crm-page .detail-top p,
:root[data-theme="purple-dark"] .crm-page .comment-feed,
:root[data-theme="purple-dark"] .crm-page .comment-feed p {
  color: #b8b2d8;
}

:root[data-theme="purple-dark"] .crm-page .crm-table-head {
  border-color: rgba(148,128,255,0.16);
  background: rgba(79,140,255,0.08);
  color: #b8b2d8;
}

:root[data-theme="purple-dark"] .crm-page #applications .crm-list {
  border-color: rgba(148,128,255,0.16);
  background: rgba(10,18,39,0.52);
}

:root[data-theme="purple-dark"] .crm-page .request-card {
  border-top-color: rgba(148,128,255,0.12);
  background: transparent;
}

:root[data-theme="purple-dark"] .crm-page .request-card:hover,
:root[data-theme="purple-dark"] .crm-page .request-card.selected {
  background: linear-gradient(90deg, rgba(79,140,255,0.18), rgba(139,92,246,0.06));
  box-shadow: inset 3px 0 #8b5cf6;
}

:root[data-theme="purple-dark"] .crm-page .detail-top,
:root[data-theme="purple-dark"] .crm-page .balance-pill,
:root[data-theme="purple-dark"] .crm-page .comment-feed,
:root[data-theme="purple-dark"] .crm-page .comment-feed p,
:root[data-theme="purple-dark"] .crm-page input,
:root[data-theme="purple-dark"] .crm-page textarea,
:root[data-theme="purple-dark"] .crm-page select {
  border-color: rgba(148,128,255,0.18);
  background: rgba(8,16,35,0.92);
  color: #fff;
}

:root[data-theme="purple-dark"] .crm-page .language-switch,
:root[data-theme="purple-dark"] .crm-page .theme-switch,
:root[data-theme="purple-dark"] .crm-page .mini-tabs {
  border: 1px solid rgba(148,128,255,0.14);
  background: rgba(10,18,39,0.96);
}

:root[data-theme="purple-dark"] .crm-page .language-switch .active,
:root[data-theme="purple-dark"] .crm-page .theme-switch .active,
:root[data-theme="purple-dark"] .crm-page .mini-tabs .active,
:root[data-theme="purple-dark"] .crm-page .action-grid a,
:root[data-theme="purple-dark"] .crm-page .comment-form button,
:root[data-theme="purple-dark"] .crm-page .chat-ticket button,
:root[data-theme="purple-dark"] .crm-page .support-ticket-row button,
:root[data-theme="purple-dark"] .crm-page .crm-back-button,
:root[data-theme="purple-dark"] .crm-page .staff-link {
  border-color: rgba(148,128,255,0.32);
  background: linear-gradient(135deg, #4f8cff, #8b5cf6);
  color: #fff;
  box-shadow: 0 14px 30px rgba(79,140,255,0.16);
}

:root[data-theme="purple-dark"] .crm-page .access-badge,
:root[data-theme="purple-dark"] .crm-page .request-card em {
  background: rgba(79,140,255,0.14);
  color: #b8caff;
}

:root[data-theme="purple-dark"] .crm-insight-grid article,
:root[data-theme="purple-dark"] .crm-chart-panel {
  border-color: rgba(148,128,255,0.16);
  background: linear-gradient(145deg, rgba(18,30,58,0.94), rgba(26,21,55,0.94));
  color: #f8f6ff;
  box-shadow: 0 18px 44px rgba(6,10,24,0.34);
}

:root[data-theme="purple-dark"] .crm-insight-grid b {
  color: #fff;
}

:root[data-theme="purple-dark"] .crm-insight-grid span,
:root[data-theme="purple-dark"] .crm-insight-grid small {
  color: #b8b2d8;
}

:root[data-theme="purple-dark"] .crm-activity-chart {
  background: rgba(8,16,35,0.72);
}

:root[data-theme="purple-dark"] .crm-page .panel-title span,
:root[data-theme="purple-dark"] .crm-page .crypto-section-title b {
  border: 1px solid rgba(148,128,255,0.2);
  background: rgba(79,140,255,0.14);
  color: #d8e2ff;
  box-shadow: none;
}

:root[data-theme="purple-dark"] .crm-page button,
:root[data-theme="purple-dark"] .crm-page .staff-link,
:root[data-theme="purple-dark"] .crm-page .action-grid a,
:root[data-theme="purple-dark"] .crm-page .comment-form button,
:root[data-theme="purple-dark"] .crm-page .crm-withdraw-form button,
:root[data-theme="purple-dark"] .crm-page .chat-ticket button,
:root[data-theme="purple-dark"] .crm-page .support-ticket-row button,
:root[data-theme="purple-dark"] .crm-page .crm-back-button {
  min-height: 40px;
  border: 1px solid rgba(148,128,255,0.24);
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(79,140,255,0.92), rgba(139,92,246,0.92));
  color: #fff;
  font-weight: 850;
  box-shadow: 0 12px 28px rgba(79,140,255,0.15);
}

:root[data-theme="purple-dark"] .crm-page .language-switch button,
:root[data-theme="purple-dark"] .crm-page .theme-switch button,
:root[data-theme="purple-dark"] .crm-page .mini-tabs button {
  min-height: 36px;
  background: transparent;
  color: #b8b2d8;
  box-shadow: none;
}

:root[data-theme="purple-dark"] .crm-page .language-switch .active,
:root[data-theme="purple-dark"] .crm-page .theme-switch .active,
:root[data-theme="purple-dark"] .crm-page .mini-tabs .active {
  background: linear-gradient(135deg, rgba(79,140,255,0.24), rgba(139,92,246,0.2));
  color: #fff;
  box-shadow: inset 3px 0 #8b5cf6;
}

:root[data-theme="purple-dark"] .crm-page .request-card {
  color: #f8f6ff;
}

:root[data-theme="purple-dark"] .crm-page .request-card em {
  border: 1px solid rgba(79,140,255,0.18);
  background: rgba(79,140,255,0.12);
  color: #b8caff;
}

:root[data-theme="purple-dark"] .crm-page input::placeholder,
:root[data-theme="purple-dark"] .crm-page textarea::placeholder {
  color: #8f89ad;
}

:root[data-theme="purple-dark"] .crm-recovery-form,
:root[data-theme="purple-dark"] .recovery-card {
  border-color: rgba(148,128,255,0.16);
  background: linear-gradient(145deg, rgba(18,30,58,0.94), rgba(26,21,55,0.94));
  color: #f8f6ff;
  box-shadow: 0 18px 44px rgba(6,10,24,0.34);
}

:root[data-theme="purple-dark"] .crm-recovery-form label,
:root[data-theme="purple-dark"] .recovery-card small,
:root[data-theme="purple-dark"] .recovery-card p {
  color: #b8b2d8;
}

:root[data-theme="purple-dark"] .crm-recovery-form input,
:root[data-theme="purple-dark"] .crm-recovery-form textarea {
  border-color: rgba(148,128,255,0.18);
  background: rgba(8,16,35,0.92);
  color: #fff;
}

:root[data-theme="purple-dark"] .crm-recovery-form button,
:root[data-theme="purple-dark"] .recovery-card button {
  border-color: rgba(148,128,255,0.28);
  background: linear-gradient(135deg, #4f8cff, #8b5cf6);
  color: #fff;
  box-shadow: 0 14px 30px rgba(79,140,255,0.16);
}

:root[data-theme="purple-dark"] .crm-page .crm-withdraw-form button,
:root[data-theme="purple-light"] .crm-page .crm-withdraw-form button {
  min-height: 46px;
  width: 100%;
  padding: 0 18px;
  border: 1px solid rgba(148,128,255,0.28);
  border-radius: 12px;
  background: linear-gradient(135deg, #4f8cff, #8b5cf6);
  color: #fff;
  font-weight: 900;
  letter-spacing: 0;
  box-shadow: 0 14px 30px rgba(79,140,255,0.16);
}

:root[data-theme="purple-light"] .crm-page .crm-withdraw-form button {
  border-color: rgba(124,58,237,0.24);
  background: linear-gradient(135deg, #7c3aed, #a855f7);
  box-shadow: 0 14px 30px rgba(124,58,237,0.16);
}

:root[data-theme="purple-light"] body {
  background:
    radial-gradient(circle at 50% -12%, rgba(124,58,237,0.12), transparent 32%),
    linear-gradient(180deg, #f7f2ff 0%, #f2edf9 54%, #eee8f7 100%);
}

:root[data-theme="purple-light"] .mobile-product,
:root[data-theme="purple-light"] .crm-shell-body {
  background:
    radial-gradient(circle at 50% -12%, rgba(124,58,237,0.12), transparent 32%),
    linear-gradient(180deg, #f7f2ff 0%, #f2edf9 54%, #eee8f7 100%);
}

:root[data-theme="purple-light"] .mobile-shell {
  background: linear-gradient(180deg, #f7f3ff 0%, #f1ebf8 100%);
}

:root[data-theme="purple-light"] .crm-page .topbar,
:root[data-theme="purple-light"] .crm-page .section-head,
:root[data-theme="purple-light"] .crm-page .client-list,
:root[data-theme="purple-light"] .crm-page .client-detail,
:root[data-theme="purple-light"] .crm-page .comments-panel,
:root[data-theme="purple-light"] .crm-page .metric-row,
:root[data-theme="purple-light"] .crm-page .chat-ticket,
:root[data-theme="purple-light"] .crm-page .transaction-row,
:root[data-theme="purple-light"] .crm-page .support-ticket-row,
:root[data-theme="purple-light"] .crm-insight-grid article,
:root[data-theme="purple-light"] .crm-chart-panel,
:root[data-theme="purple-light"] .mobile-product .auth-hero,
:root[data-theme="purple-light"] .mobile-product .auth-form,
:root[data-theme="purple-light"] .mobile-product .forgot-form,
:root[data-theme="purple-light"] .mobile-product .reset-form,
:root[data-theme="purple-light"] .mobile-product .client-header,
:root[data-theme="purple-light"] .mobile-product .profile-card,
:root[data-theme="purple-light"] .mobile-product .settings-card,
:root[data-theme="purple-light"] .mobile-product .quick-grid button,
:root[data-theme="purple-light"] .mobile-product .asset-row,
:root[data-theme="purple-light"] .mobile-product .address-row,
:root[data-theme="purple-light"] .mobile-product .wallet-strip,
:root[data-theme="purple-light"] .mobile-product .wallet-info-grid article,
:root[data-theme="purple-light"] .mobile-product .support-card,
:root[data-theme="purple-light"] .mobile-product .support-history-card,
:root[data-theme="purple-light"] .mobile-product .support-ticket-row,
:root[data-theme="purple-light"] .mobile-product .transaction-row,
:root[data-theme="purple-light"] .mobile-product .empty-state,
:root[data-theme="purple-light"] .mobile-product .crypto-form {
  border-color: #d8cfee;
  background: linear-gradient(145deg, #fbf8ff, #f4effb);
  color: #171226;
  box-shadow: 0 14px 34px rgba(109,74,255,0.11);
}

:root[data-theme="purple-light"] .mobile-product .balance-panel,
:root[data-theme="purple-light"] .mobile-product .crypto-wallet-card,
:root[data-theme="purple-light"] .crm-page .detail-top {
  border-color: rgba(124,58,237,0.18);
  background:
    radial-gradient(circle at 50% -10%, rgba(124,58,237,0.13), transparent 36%),
    linear-gradient(135deg, #fbf8ff 0%, #f2ecfb 58%, #eee8f7 100%);
  color: #171226;
}

:root[data-theme="purple-light"] input,
:root[data-theme="purple-light"] select,
:root[data-theme="purple-light"] textarea,
:root[data-theme="purple-light"] .paste-control,
:root[data-theme="purple-light"] .amount-control,
:root[data-theme="purple-light"] .crm-page .comment-feed,
:root[data-theme="purple-light"] .crm-page .comment-feed p,
:root[data-theme="purple-light"] .mobile-product .support-bubble,
:root[data-theme="purple-light"] .mobile-product .chat-bubble {
  border-color: #d8cfee;
  background: #f7f3ff;
  color: #171226;
}

:root[data-theme="purple-light"] .language-switch,
:root[data-theme="purple-light"] .theme-switch,
:root[data-theme="purple-light"] .mini-tabs,
:root[data-theme="purple-light"] .product-tabs,
:root[data-theme="purple-light"] .app-menu,
:root[data-theme="purple-light"] .bottom-tabs {
  border: 1px solid #ded6f0;
  background: #ede6f7;
}

:root[data-theme="purple-light"] .language-switch .active,
:root[data-theme="purple-light"] .theme-switch .active,
:root[data-theme="purple-light"] .mini-tabs .active,
:root[data-theme="purple-light"] .product-tabs .active,
:root[data-theme="purple-light"] .app-menu .active,
:root[data-theme="purple-light"] .bottom-tabs .active {
  background: linear-gradient(135deg, #fbf8ff, #f4effb);
  color: #4c1d95;
  box-shadow: 0 10px 22px rgba(109,74,255,0.12);
}

:root[data-theme="purple-light"] .crm-table-head,
:root[data-theme="purple-light"] .crm-page #applications .crm-list,
:root[data-theme="purple-light"] .crm-activity-chart {
  border-color: #d8cfee;
  background: #f4effb;
}

:root[data-theme="purple-light"] .crm-recovery-form,
:root[data-theme="purple-light"] .recovery-card {
  border-color: #d8cfee;
  background: linear-gradient(145deg, #fbf8ff, #f4effb);
  color: #171226;
  box-shadow: 0 14px 34px rgba(109,74,255,0.11);
}

:root[data-theme="purple-light"] .mobile-product .balance-panel p,
:root[data-theme="purple-light"] .mobile-product .balance-panel span,
:root[data-theme="purple-light"] .mobile-product .balance-top,
:root[data-theme="purple-light"] .mobile-product .ledger-state {
  color: #62557a;
}

:root[data-theme="purple-light"] .mobile-product .balance-panel strong,
:root[data-theme="purple-light"] .mobile-product .ledger-state b {
  color: #171226;
}

:root[data-theme="purple-light"] .mobile-product .balance-panel button {
  border-color: rgba(124,58,237,0.22);
  background: rgba(124,58,237,0.1);
  color: #4c1d95;
}

:root[data-theme="purple-light"] .mobile-product .auth-panel {
  color: #171226;
}

:root[data-theme="purple-light"] .mobile-product .auth-hero {
  border-color: rgba(124,58,237,0.18);
  background:
    radial-gradient(circle at 0 0, rgba(124,58,237,0.16), transparent 40%),
    linear-gradient(145deg, #f8f3ff, #efe8f8);
}

:root[data-theme="purple-light"] .mobile-product .auth-emblem {
  background: linear-gradient(135deg, #7c3aed, #a855f7);
  color: #fff;
  box-shadow: 0 14px 30px rgba(124,58,237,0.18);
}

:root[data-theme="purple-light"] .mobile-product .auth-form,
:root[data-theme="purple-light"] .mobile-product .forgot-form,
:root[data-theme="purple-light"] .mobile-product .reset-form {
  border-color: #d8cfee;
  background: linear-gradient(145deg, #fbf8ff, #f4effb);
}

:root[data-theme="purple-light"] .mobile-product .auth-form label,
:root[data-theme="purple-light"] .mobile-product .forgot-form label,
:root[data-theme="purple-light"] .mobile-product .reset-form label {
  color: #62557a;
}

:root[data-theme="purple-light"] .mobile-product .auth-form input,
:root[data-theme="purple-light"] .mobile-product .forgot-form input,
:root[data-theme="purple-light"] .mobile-product .reset-form input {
  border-color: #d8cfee;
  background: #f7f3ff;
  color: #171226;
}

:root[data-theme="purple-light"] .mobile-product .auth-form input:focus,
:root[data-theme="purple-light"] .mobile-product .forgot-form input:focus,
:root[data-theme="purple-light"] .mobile-product .reset-form input:focus {
  border-color: #8b5cf6;
  box-shadow: 0 0 0 4px rgba(124,58,237,0.13);
}

:root[data-theme="purple-light"] .mobile-product .auth-mode-tabs {
  border: 1px solid #d8cfee;
  background: #ede6f7;
}

:root[data-theme="purple-light"] .mobile-product .auth-mode-tabs button {
  color: #746b86;
}

:root[data-theme="purple-light"] .mobile-product .auth-mode-tabs .active {
  background: linear-gradient(135deg, #7c3aed, #a855f7);
  color: #fff;
  box-shadow: 0 14px 30px rgba(124,58,237,0.16);
}

:root[data-theme="purple-light"] .mobile-product .auth-actions button,
:root[data-theme="purple-light"] .mobile-product .forgot-button,
:root[data-theme="purple-light"] .mobile-product .forgot-toggle,
:root[data-theme="purple-light"] .mobile-product .reset-form button {
  border-color: rgba(124,58,237,0.24);
  background: linear-gradient(135deg, #7c3aed, #a855f7);
  color: #fff;
  box-shadow: 0 14px 30px rgba(124,58,237,0.16);
}

@media (max-width: 980px) {
  .hero-strip,
  .crm-layout,
  .banking-layout,
  .flow-grid,
  .security-grid {
    grid-template-columns: 1fr;
  }
  .product-tabs { grid-template-columns: repeat(2, 1fr); }
  .action-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 620px) {
  .app-shell { width: min(100% - 14px, 1240px); }
  .crm-page { width: min(100% - 14px, 1240px); padding-top: 10px; }
  .topbar { align-items: flex-start; flex-direction: column; }
  .top-actions { width: 100%; justify-content: space-between; gap: 8px; }
  .crm-page .topbar,
  .crm-page .section-head,
  .crm-page .client-list,
  .crm-page .client-detail,
  .crm-page .comments-panel {
    padding: 12px;
    border-radius: 12px;
  }
  .crm-page .brand {
    max-width: 100%;
    min-width: 0;
  }
  .crm-page .brand span:last-child,
  .crm-page .section-head h1 {
    overflow-wrap: anywhere;
    line-height: 1.15;
  }
  .crm-page .section-head {
    gap: 10px;
  }
  .crm-page .access-badge {
    max-width: 100%;
    white-space: normal;
    text-align: center;
  }
  .product-tabs,
  .app-menu { grid-template-columns: 1fr; }
  .mini-tabs { grid-template-columns: 1fr; }
  .crm-page .mini-tabs {
    gap: 7px;
  }
  .crm-page .mini-tabs button {
    min-height: 40px;
  }
  .action-grid { grid-template-columns: 1fr; }
  .crm-insight-grid,
  .crm-operations-grid,
  .crm-recovery-form { grid-template-columns: 1fr; }
  .detail-top,
  .section-head,
  .wallet-strip,
  .positions article { align-items: flex-start; flex-wrap: wrap; }
  .comment-form,
  .chat-form { grid-template-columns: 1fr; }
  .mobile-shell { width: 100%; }
  .verification-form { grid-template-columns: 1fr; }
  .crm-page .detail-top,
  .crm-page .action-grid { grid-template-columns: 1fr; }

  .crm-table-head {
    display: none;
  }

  .crm-page #applications .crm-list {
    border: 0;
    border-radius: 0;
    background: transparent;
  }

  .crm-page .request-card {
    display: grid;
    grid-template-columns: 1fr;
    gap: 8px;
    min-height: auto;
    padding: 12px;
    border: 1px solid var(--line);
    border-radius: 12px;
    text-align: center;
  }

  .crm-page .request-card > span,
  .crm-page .request-card > strong,
  .crm-page .request-card > em {
    min-width: 0;
    justify-self: center;
    max-width: 100%;
    overflow-wrap: anywhere;
    word-break: break-word;
    text-align: center;
  }

  .crm-page .request-card b,
  .crm-page .request-card small {
    max-width: 100%;
    overflow-wrap: anywhere;
  }

  .crm-page .request-card em {
    padding: 6px 10px;
    border-radius: 999px;
  }

  .crm-page .crm-list {
    gap: 10px;
  }
}

@media (min-width: 900px) {
  .mobile-product {
    background: linear-gradient(135deg, #e8f2f1, #f8fbfb);
  }

  :root[data-theme="purple-dark"] .mobile-product {
    background:
      radial-gradient(circle at 50% -12%, rgba(89,62,196,0.26), transparent 34%),
      linear-gradient(180deg, #091226 0%, #0b1022 52%, #070b18 100%);
  }

  :root[data-theme="purple-light"] .mobile-product {
    background: #f6f2ff;
  }

  .mobile-shell {
    width: min(1180px, calc(100% - 56px));
    display: grid;
    grid-template-columns: minmax(380px, 470px) minmax(0, 1fr);
    gap: 32px;
    align-content: start;
    padding: 8px 24px 24px;
    background: transparent;
  }

  :root[data-theme="purple-dark"] .mobile-shell {
    width: min(1360px, calc(100% - 40px));
    padding-left: 10px;
    padding-right: 10px;
  }

  :root[data-theme="purple-light"] .mobile-shell,
  :root[data-theme="purple-light"] .app-shell,
  :root[data-theme="purple-light"] .auth-panel,
  :root[data-theme="purple-light"] .app-content {
    margin-left: auto;
    margin-right: auto;
  }

  :root[data-theme="purple-light"] .mobile-shell {
    width: min(1360px, calc(100% - 40px));
    padding-left: 10px;
    padding-right: 10px;
  }

  .mobile-topbar,
  .auth-panel,
  .app-content {
    grid-column: 1 / -1;
  }

  .auth-panel,
  .app-content {
    width: min(860px, 100%);
    margin: 0 auto;
  }

  .auth-panel {
    grid-template-columns: minmax(300px, 360px) minmax(340px, 390px);
    grid-template-rows: auto auto auto auto auto auto auto;
    column-gap: 22px;
    align-items: start;
    align-content: start;
    padding-top: 0;
    min-height: auto;
  }

  .auth-language-row {
    grid-column: 1 / -1;
    grid-row: 1;
  }

  .auth-hero {
    grid-column: 1;
    grid-row: 2 / span 4;
    min-height: 300px;
    align-content: center;
  }

  .auth-mode-tabs { grid-column: 2; grid-row: 2; }
  .auth-form { grid-column: 2; grid-row: 3; }
  .forgot-toggle { grid-column: 2; grid-row: 4; }
  .forgot-form { grid-column: 2; grid-row: 5; }
  .reset-form { grid-column: 2; grid-row: 6; }
  .auth-footnote { grid-column: 2; grid-row: 7; }

  .app-content {
    max-width: 1040px;
    align-self: start;
  }

  :root[data-theme="purple-dark"] .app-content {
    width: min(1280px, 100%);
    max-width: 1280px;
  }

  :root[data-theme="purple-light"] .app-content {
    width: min(1280px, 100%);
    max-width: 1280px;
  }

  .crypto-address-strip {
    display: grid !important;
    justify-content: center;
    justify-items: center;
    text-align: center;
    width: 100%;
  }

  .crypto-address-strip strong,
  .crypto-address-strip small,
  .crypto-address-strip .crypto-address-copy {
    justify-self: center;
  }

  .crypto-form {
    width: min(100%, 640px);
    justify-self: center;
    margin-left: auto;
    margin-right: auto;
  }

  .bottom-tabs {
    position: sticky;
    left: auto;
    bottom: 0;
    width: 100%;
    transform: none;
  }
}

/* Final interaction overrides. */
.toast {
  top: 18px;
  right: 18px;
  bottom: auto;
  border: 1px solid rgba(121, 85, 255, 0.24);
  border-radius: 14px;
  background: linear-gradient(135deg, #1f1b46, #33256f);
  color: #fff;
  box-shadow: 0 18px 44px rgba(62, 47, 142, 0.28);
  transform: translateY(-18px);
  z-index: 1200;
}

.toast.visible {
  transform: translateY(0);
}

.task-screen.hidden,
.crypto-task-panel {
  display: none;
}

.crypto-task-panel.active {
  display: grid;
  gap: 12px;
}

.crm-login-panel {
  min-height: calc(100vh - 140px);
  display: grid;
  align-items: center;
}

.crm-login-shell {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(320px, .75fr);
  gap: 18px;
  width: min(980px, 100%);
  margin: 0 auto;
}

.crm-manager-form {
  display: grid;
}

:root[data-theme="purple-dark"] .toast {
  border-color: rgba(139,92,246,0.35);
  background: linear-gradient(135deg, #151f30, #2d1f63);
  color: #fff;
}

/* Tail override: production CRM desktop shell and modal profile. */
@media (min-width: 901px) {
  body.crm-shell-body .crm-page {
    display: grid !important;
    grid-template-columns: 276px minmax(0, 1fr) !important;
    padding: 0 !important;
    max-width: none !important;
  }

  body.crm-shell-body .crm-page .topbar {
    position: sticky !important;
    top: 0 !important;
    width: 276px !important;
    height: 100vh !important;
    display: grid !important;
    align-content: start !important;
    border-right: 1px solid rgba(255,255,255,.08) !important;
    border-radius: 0 !important;
  }

  body.crm-shell-body .crm-page #crm {
    grid-column: 2 !important;
    padding: 28px 32px !important;
  }

  body.crm-shell-body .crm-page .crm-side-menu {
    display: grid !important;
  }

  body.crm-shell-body .crm-page .client-list .mini-tabs:not(.legacy-tabs) {
    display: none !important;
  }

  body.crm-shell-body .crm-page .client-detail {
    display: none !important;
  }

  body.crm-shell-body .crm-page.detail-open::after {
    content: "" !important;
    position: fixed !important;
    inset: 0 !important;
    z-index: 9000 !important;
    background: rgba(3,7,18,.58) !important;
    backdrop-filter: blur(14px) !important;
  }

  body.crm-shell-body .crm-page.detail-open .client-detail {
    position: fixed !important;
    inset: 32px !important;
    z-index: 9010 !important;
    display: block !important;
    width: min(1040px, calc(100vw - 64px)) !important;
    max-height: calc(100vh - 64px) !important;
    margin: auto !important;
    overflow: auto !important;
  }

  body.mobile-product #crypto .transfer-mode-tabs {
    justify-self: center !important;
    width: auto !important;
    max-width: min(100%, 520px) !important;
    display: inline-grid !important;
    grid-template-columns: repeat(3, max-content) !important;
    justify-content: center !important;
    gap: 8px !important;
    margin: 12px auto 14px !important;
  }

  body.mobile-product #crypto .transfer-mode-tabs button {
    width: auto !important;
    min-width: 118px !important;
    max-width: 180px !important;
    padding: 0 14px !important;
    white-space: nowrap !important;
  }
}

body.crm-shell-body .crm-login-panel {
  min-height: calc(100vh - 118px) !important;
  place-items: center !important;
  padding: 28px 16px 44px !important;
}

body.crm-shell-body .crm-login-shell {
  width: min(920px, 100%) !important;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 410px) !important;
  gap: 0 !important;
  overflow: hidden !important;
  border: 1px solid rgba(167, 139, 250, .18) !important;
  border-radius: 26px !important;
  background:
    radial-gradient(circle at 18% 0%, rgba(139, 92, 246, .30), transparent 34%),
    linear-gradient(145deg, rgba(13, 12, 30, .96), rgba(26, 18, 54, .98)) !important;
  box-shadow: 0 30px 90px rgba(4, 6, 18, .48) !important;
}

body.crm-shell-body .crm-login-hero,
body.crm-shell-body .crm-manager-form {
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  color: #f8f7ff !important;
}

body.crm-shell-body .crm-login-hero {
  min-height: 420px !important;
  padding: 42px !important;
  align-content: center !important;
  gap: 16px !important;
}

body.crm-shell-body .crm-login-hero .eyebrow {
  color: #c4b5fd !important;
}

body.crm-shell-body .crm-login-hero h1 {
  max-width: 420px !important;
  font-size: clamp(2.2rem, 4vw, 4rem) !important;
  line-height: .96 !important;
  color: #fff !important;
}

body.crm-shell-body .crm-login-hero p:last-of-type {
  max-width: 430px !important;
  color: rgba(237, 233, 254, .76) !important;
}

body.crm-shell-body .crm-manager-form {
  margin: 18px !important;
  padding: 24px !important;
  align-self: center !important;
  border: 1px solid rgba(255, 255, 255, .10) !important;
  border-radius: 20px !important;
  background: rgba(8, 10, 24, .62) !important;
  backdrop-filter: blur(18px) !important;
}

body.crm-shell-body .crm-manager-form label span {
  color: rgba(237, 233, 254, .82) !important;
}

body.crm-shell-body .crm-manager-form input {
  border-color: rgba(167, 139, 250, .24) !important;
  background: rgba(255, 255, 255, .08) !important;
  color: #fff !important;
}

body.crm-shell-body .crm-manager-form input:focus {
  border-color: rgba(196, 181, 253, .70) !important;
  box-shadow: 0 0 0 4px rgba(139, 92, 246, .18) !important;
}

body.crm-shell-body .crm-manager-form .auth-actions button {
  background: linear-gradient(135deg, #7c3aed, #a78bfa) !important;
  color: #fff !important;
  box-shadow: 0 16px 34px rgba(124, 58, 237, .30) !important;
}

@media (max-width: 760px) {
  body.crm-shell-body .crm-login-shell {
    grid-template-columns: 1fr !important;
  }

  body.crm-shell-body .crm-login-hero {
    min-height: auto !important;
    padding: 28px 24px 8px !important;
  }

  body.crm-shell-body .crm-manager-form {
    margin: 12px !important;
  }
}

body.crm-shell-body .crm-page.detail-open #crm {
  position: relative !important;
  z-index: 9020 !important;
  pointer-events: none !important;
}

body.crm-shell-body .crm-page.detail-open::after {
  z-index: 9000 !important;
  pointer-events: auto !important;
}

body.crm-shell-body .crm-page.detail-open .section-head,
body.crm-shell-body .crm-page.detail-open .client-list,
body.crm-shell-body .crm-page.detail-open .crm-insight-grid,
body.crm-shell-body .crm-page.detail-open .crm-chart-panel {
  pointer-events: none !important;
  opacity: .18 !important;
  filter: blur(4px) !important;
}

body.crm-shell-body .crm-page.detail-open .client-detail {
  position: fixed !important;
  inset: 28px !important;
  z-index: 9030 !important;
  display: grid !important;
  gap: 14px !important;
  width: min(1040px, calc(100vw - 56px)) !important;
  max-height: calc(100vh - 56px) !important;
  margin: auto !important;
  overflow: auto !important;
  pointer-events: auto !important;
  border: 1px solid rgba(167, 139, 250, .20) !important;
  border-radius: 20px !important;
  background: linear-gradient(145deg, rgba(13, 12, 30, .98), rgba(20, 16, 42, .98)) !important;
  box-shadow: 0 34px 100px rgba(0, 0, 0, .68) !important;
}

@media (max-width: 760px) {
  body.crm-shell-body .crm-page.detail-open .client-detail {
    inset: 12px !important;
    width: calc(100vw - 24px) !important;
    max-height: calc(100vh - 24px) !important;
  }
}

@media (min-width: 901px) {
  body.mobile-product #home.mobile-screen.active {
    display: grid !important;
    grid-template-columns: minmax(0, 1.05fr) minmax(380px, .95fr) !important;
    gap: 18px !important;
    align-items: start !important;
  }

  body.mobile-product #home .client-header {
    grid-column: 1 / -1 !important;
  }

  body.mobile-product #home .quick-grid,
  body.mobile-product #home .asset-stack {
    grid-column: 1 / -1 !important;
  }

  body.mobile-product #home .balance-panel {
    min-height: 258px !important;
    padding: 26px !important;
    align-content: space-between !important;
    background:
      radial-gradient(circle at 16% 0%, rgba(167, 139, 250, .28), transparent 34%),
      linear-gradient(145deg, #0b1020 0%, #14102a 54%, #090b13 100%) !important;
    border: 1px solid rgba(167, 139, 250, .18) !important;
    box-shadow: 0 28px 82px rgba(3, 7, 18, .42) !important;
  }

  body.mobile-product #home .balance-panel strong {
    font-size: clamp(2.4rem, 5vw, 4.7rem) !important;
    line-height: .95 !important;
  }

  body.mobile-product .desktop-capital-panel {
    display: grid !important;
    grid-template-columns: minmax(0, 1.1fr) minmax(360px, .9fr) !important;
    gap: 16px !important;
    grid-column: 1 / -1 !important;
  }

  body.mobile-product .equity-curve-card,
  body.mobile-product .desktop-market-panel,
  body.mobile-product .desktop-finance-banners article {
    border: 1px solid rgba(167, 139, 250, .16) !important;
    border-radius: 10px !important;
    background:
      linear-gradient(180deg, rgba(255, 255, 255, .075), rgba(255, 255, 255, .025)),
      rgba(10, 13, 28, .86) !important;
    color: #fff !important;
    box-shadow: 0 20px 60px rgba(4, 6, 18, .28) !important;
  }

  body.mobile-product .equity-curve-card {
    display: grid !important;
    gap: 14px !important;
    min-height: 250px !important;
    padding: 18px !important;
    overflow: hidden !important;
  }

  body.mobile-product .equity-summary {
    display: flex !important;
    align-items: end !important;
    justify-content: space-between !important;
    gap: 12px !important;
  }

  body.mobile-product .equity-summary strong {
    color: #fff !important;
    font-size: clamp(1.8rem, 3vw, 3rem) !important;
    line-height: 1 !important;
  }

  body.mobile-product .equity-summary span {
    color: #4ade80 !important;
    font-weight: 900 !important;
    white-space: nowrap !important;
  }

  body.mobile-product .equity-summary span.down {
    color: #fb7185 !important;
  }

  body.mobile-product .equity-chart {
    width: 100% !important;
    height: 150px !important;
    overflow: visible !important;
    background:
      linear-gradient(rgba(255, 255, 255, .045) 1px, transparent 1px),
      linear-gradient(90deg, rgba(255, 255, 255, .035) 1px, transparent 1px) !important;
    background-size: 100% 37px, 84px 100% !important;
    border-radius: 8px !important;
  }

  body.mobile-product .equity-chart [data-equity-area] {
    fill: url(#equityFill) !important;
  }

  body.mobile-product .equity-chart [data-equity-line] {
    fill: none !important;
    stroke: #a78bfa !important;
    stroke-width: 4 !important;
    stroke-linecap: round !important;
    stroke-linejoin: round !important;
    filter: drop-shadow(0 8px 18px rgba(167, 139, 250, .42)) !important;
  }

  body.mobile-product #home .desktop-market-panel {
    display: grid !important;
    gap: 12px !important;
    padding: 16px !important;
  }

  body.mobile-product #crypto .desktop-market-panel {
    display: none !important;
  }

  body.mobile-product .desktop-market-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 10px !important;
  }

  body.mobile-product .desktop-market-grid article {
    min-height: 62px !important;
    border-color: rgba(255, 255, 255, .09) !important;
    background: rgba(255, 255, 255, .045) !important;
  }

  body.mobile-product .desktop-market-grid span {
    background: linear-gradient(135deg, #7c3aed, #14b8a6) !important;
  }

  body.mobile-product .desktop-finance-banners {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 14px !important;
    grid-column: 1 / -1 !important;
  }

  body.mobile-product .desktop-finance-banners article {
    display: grid !important;
    gap: 7px !important;
    min-height: 128px !important;
    padding: 18px !important;
    align-content: end !important;
    background:
      radial-gradient(circle at 88% 12%, rgba(20, 184, 166, .20), transparent 34%),
      linear-gradient(145deg, rgba(15, 23, 42, .92), rgba(30, 21, 63, .92)) !important;
  }

  body.mobile-product .desktop-finance-banners span {
    color: #c4b5fd !important;
    font-size: .74rem !important;
    font-weight: 950 !important;
    text-transform: uppercase !important;
  }

  body.mobile-product .desktop-finance-banners b {
    color: #fff !important;
    font-size: 1.12rem !important;
  }

  body.mobile-product .desktop-finance-banners small {
    color: rgba(237, 233, 254, .70) !important;
    line-height: 1.45 !important;
  }
}

@media (min-width: 901px) {
  body.crm-shell-body.crm-login-active .crm-page .topbar {
    display: none !important;
  }

  body.crm-shell-body.crm-login-active .crm-page {
    display: grid !important;
    place-items: stretch center !important;
    min-height: 100vh !important;
    padding: 0 !important;
  }

  body.crm-shell-body.crm-login-active .crm-page #crm {
    display: none !important;
  }

  body.crm-shell-body.crm-login-active .crm-login-panel {
    display: grid !important;
    min-height: 100vh !important;
    width: 100% !important;
    padding: 18px !important;
    place-items: center !important;
  }

  body.crm-shell-body.crm-login-active .crm-login-shell {
    width: calc(100vw - 36px) !important;
    min-height: calc(100vh - 36px) !important;
    grid-template-columns: minmax(520px, 1fr) minmax(430px, 520px) !important;
    align-items: center !important;
    border-radius: 18px !important;
  }

  body.crm-shell-body.crm-login-active .crm-login-hero {
    min-height: calc(100vh - 92px) !important;
    padding: 48px !important;
  }

  body.crm-shell-body.crm-login-active .crm-manager-form {
    width: min(520px, 100%) !important;
    margin: 0 34px 0 0 !important;
    justify-self: end !important;
    align-self: center !important;
    transform: translateY(-18px) !important;
  }

  body.crm-shell-body:not(.crm-authenticated) .crm-page .topbar {
    display: none !important;
  }

  body.crm-shell-body.crm-client-open::before {
    content: "" !important;
    position: fixed !important;
    inset: 0 !important;
    z-index: 5000 !important;
    background: rgba(3, 7, 18, .62) !important;
    backdrop-filter: blur(14px) !important;
    pointer-events: none !important;
  }

  body.crm-shell-body.crm-client-open .crm-page.detail-open::after {
    content: none !important;
  }

  body.crm-shell-body {
    overflow-x: hidden !important;
    background:
      radial-gradient(circle at 18% 0%, rgba(124, 58, 237, .24), transparent 34%),
      linear-gradient(180deg, #070914 0%, #090b16 100%) !important;
  }

  body.crm-shell-body .crm-page {
    display: block !important;
    width: 100% !important;
    max-width: none !important;
    min-height: 100vh !important;
    padding: 0 !important;
    overflow-x: hidden !important;
  }

  body.crm-shell-body .crm-page .topbar {
    position: fixed !important;
    inset: 0 auto 0 0 !important;
    z-index: 1200 !important;
    width: 292px !important;
    height: 100vh !important;
    overflow-y: auto !important;
    display: grid !important;
    grid-template-rows: auto 1fr !important;
    align-content: start !important;
    gap: 18px !important;
    padding: 22px 16px !important;
    border: 0 !important;
    border-right: 1px solid rgba(167, 139, 250, .16) !important;
    border-radius: 0 !important;
    background:
      linear-gradient(180deg, rgba(18, 15, 42, .98), rgba(7, 9, 20, .98)) !important;
    box-shadow: 18px 0 60px rgba(0, 0, 0, .28) !important;
  }

  body.crm-shell-body .crm-page .brand {
    width: 100% !important;
    padding: 10px 8px 16px !important;
    border-bottom: 1px solid rgba(255, 255, 255, .08) !important;
  }

  body.crm-shell-body .crm-page .top-actions {
    display: grid !important;
    align-content: start !important;
    gap: 14px !important;
    width: 100% !important;
  }

  body.crm-shell-body .crm-page .crm-side-menu {
    display: grid !important;
    gap: 8px !important;
    padding: 8px !important;
    border: 1px solid rgba(167, 139, 250, .14) !important;
    border-radius: 14px !important;
    background: rgba(255, 255, 255, .045) !important;
  }

  body.crm-shell-body .crm-side-menu span {
    margin: 8px 6px 2px !important;
    color: rgba(196, 181, 253, .78) !important;
    font-size: .68rem !important;
    font-weight: 950 !important;
    text-transform: uppercase !important;
  }

  body.crm-shell-body .crm-side-menu button {
    justify-content: flex-start !important;
    width: 100% !important;
    min-height: 42px !important;
    padding: 0 12px !important;
    border: 1px solid transparent !important;
    border-radius: 10px !important;
    background: transparent !important;
    color: rgba(237, 233, 254, .78) !important;
    text-align: left !important;
  }

  body.crm-shell-body .crm-side-menu button.active {
    border-color: rgba(167, 139, 250, .24) !important;
    background: linear-gradient(135deg, rgba(124, 58, 237, .32), rgba(20, 184, 166, .12)) !important;
    color: #fff !important;
    box-shadow: 0 12px 28px rgba(4, 6, 18, .22) !important;
  }

  body.crm-shell-body .crm-page #crm {
    margin-left: 292px !important;
    width: calc(100% - 292px) !important;
    min-height: 100vh !important;
    padding: 28px 34px 64px !important;
    overflow: visible !important;
  }

  body.crm-shell-body .crm-page .section-head,
  body.crm-shell-body .crm-page .client-list,
  body.crm-shell-body .crm-page .comments-panel,
  body.crm-shell-body .crm-page .metric-row,
  body.crm-shell-body .crm-page .transaction-row,
  body.crm-shell-body .crm-page .chat-ticket,
  body.crm-shell-body .crm-page .support-ticket-row {
    border-radius: 12px !important;
  }

  body.crm-shell-body .crm-page .section-head h1 {
    font-size: clamp(2rem, 3vw, 3.2rem) !important;
  }

  body.crm-shell-body .crm-page .crm-layout {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    gap: 18px !important;
  }

  body.crm-shell-body .crm-page .client-list {
    min-height: auto !important;
    padding: 18px !important;
  }

  body.crm-shell-body .crm-page #applications .crm-list {
    min-height: 520px !important;
  }

  body.crm-shell-body .crm-login-panel {
    min-height: 100vh !important;
    padding: 38px 44px 44px 336px !important;
  }

  body.crm-shell-body .crm-login-shell {
    width: min(1120px, 100%) !important;
    grid-template-columns: minmax(420px, 1fr) minmax(380px, 460px) !important;
  }

  body.crm-shell-body .crm-page.detail-open #crm {
    position: static !important;
    z-index: auto !important;
    pointer-events: auto !important;
  }

  body.crm-shell-body .crm-page.detail-open::after {
    content: none !important;
    position: fixed !important;
    inset: 0 !important;
    z-index: 5000 !important;
    background: rgba(3, 7, 18, .62) !important;
    backdrop-filter: blur(14px) !important;
    pointer-events: none !important;
  }

  body.crm-shell-body .crm-page.detail-open .client-detail {
    position: fixed !important;
    top: 28px !important;
    right: 32px !important;
    bottom: 28px !important;
    left: max(324px, calc(50vw - 430px)) !important;
    z-index: 5010 !important;
    display: grid !important;
    grid-template-columns: 1fr !important;
    align-content: start !important;
    gap: 14px !important;
    width: auto !important;
    max-width: 980px !important;
    max-height: none !important;
    padding: 16px !important;
    overflow: auto !important;
    pointer-events: auto !important;
    opacity: 1 !important;
    visibility: visible !important;
    border: 1px solid rgba(167, 139, 250, .22) !important;
    border-radius: 18px !important;
    background:
      radial-gradient(circle at 18% 0%, rgba(124, 58, 237, .24), transparent 32%),
      linear-gradient(145deg, rgba(13, 12, 30, .99), rgba(18, 21, 40, .99)) !important;
    box-shadow: 0 34px 110px rgba(0, 0, 0, .72) !important;
  }

  body.crm-shell-body .crm-page.detail-open .client-detail > * {
    opacity: 1 !important;
    visibility: visible !important;
  }

  body.crm-shell-body .crm-page.detail-open .detail-top {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) auto !important;
    margin: 0 !important;
    padding: 22px !important;
  }

  body.crm-shell-body .crm-page.detail-open .action-grid,
  body.crm-shell-body .crm-page.detail-open .crm-insight-grid,
  body.crm-shell-body .crm-page.detail-open .crm-operations-grid {
    display: grid !important;
  }

  body.crm-shell-body .crm-manager-create-form {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 12px !important;
    padding: 14px !important;
    margin-bottom: 14px !important;
    border: 1px solid rgba(167, 139, 250, .14) !important;
    border-radius: 12px !important;
    background: rgba(255, 255, 255, .045) !important;
  }

  body.crm-shell-body .crm-manager-create-form.hidden {
    display: none !important;
  }

  body.crm-shell-body .crm-manager-create-form label {
    display: grid !important;
    gap: 6px !important;
  }

  body.crm-shell-body .crm-manager-create-form button {
    grid-column: 1 / -1 !important;
  }

  body.crm-shell-body .crm-profile-card {
    display: grid !important;
    gap: 8px !important;
    min-height: 150px !important;
    padding: 20px !important;
    margin-bottom: 14px !important;
    align-content: end !important;
    border: 1px solid rgba(167, 139, 250, .18) !important;
    border-radius: 14px !important;
    background:
      radial-gradient(circle at 88% 10%, rgba(20, 184, 166, .22), transparent 34%),
      linear-gradient(145deg, rgba(15, 23, 42, .96), rgba(30, 21, 63, .92)) !important;
    color: #fff !important;
  }

  body.crm-shell-body .crm-profile-card span {
    color: #c4b5fd !important;
    font-size: .72rem !important;
    font-weight: 950 !important;
    text-transform: uppercase !important;
  }

  body.crm-shell-body .crm-profile-card h2 {
    margin: 0 !important;
    color: #fff !important;
    font-size: 1.8rem !important;
  }

  body.crm-shell-body .crm-profile-card p {
    color: rgba(237, 233, 254, .74) !important;
  }

  body.mobile-product #crypto.mobile-screen.active {
    justify-items: center !important;
  }

  body.mobile-product #crypto .section-head,
  body.mobile-product #crypto .crypto-task-panel {
    justify-self: stretch !important;
    width: 100% !important;
  }

  body.mobile-product #crypto .transfer-mode-tabs {
    grid-column: 1 / -1 !important;
    justify-self: center !important;
    place-self: center !important;
    width: fit-content !important;
    max-width: calc(100vw - 360px) !important;
    margin: 16px auto !important;
    display: inline-grid !important;
    grid-template-columns: repeat(3, max-content) !important;
    justify-content: center !important;
  }

  body.mobile-product #crypto .transfer-mode-tabs button {
    width: auto !important;
    min-width: 132px !important;
    max-width: 190px !important;
    text-align: center !important;
  }

  body.mobile-product #appContent #crypto .transfer-mode-tabs {
    position: relative !important;
    left: 50% !important;
    transform: translateX(-50%) !important;
    grid-column: 1 / -1 !important;
    justify-self: start !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
  }
}

body.crm-shell-body.crm-client-open::before,
body.crm-shell-body .crm-page.detail-open::after {
  content: none !important;
  display: none !important;
  backdrop-filter: none !important;
  background: transparent !important;
}

body.crm-shell-body .crm-page.detail-open .section-head,
body.crm-shell-body .crm-page.detail-open .client-list,
body.crm-shell-body .crm-page.detail-open .crm-insight-grid,
body.crm-shell-body .crm-page.detail-open .crm-chart-panel {
  opacity: 1 !important;
  filter: none !important;
}

body.crm-shell-body.crm-login-active {
  background:
    radial-gradient(circle at 18% 8%, rgba(124, 58, 237, .28), transparent 34%),
    linear-gradient(135deg, #070914 0%, #100b24 52%, #060812 100%) !important;
}

@media (min-width: 901px) {
  body.crm-shell-body.crm-login-active .crm-login-panel {
    padding: 0 !important;
    min-height: 100vh !important;
    width: 100vw !important;
    place-items: stretch !important;
  }

  body.crm-shell-body.crm-login-active .crm-login-shell {
    width: 100vw !important;
    min-height: 100vh !important;
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) minmax(420px, 560px) !important;
    gap: 0 !important;
    border: 0 !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    overflow: hidden !important;
    background:
      radial-gradient(circle at 18% 12%, rgba(124, 58, 237, .32), transparent 34%),
      linear-gradient(135deg, rgba(13, 12, 30, .98), rgba(9, 11, 22, .98)) !important;
  }

  body.crm-shell-body.crm-login-active .crm-login-hero {
    min-height: 100vh !important;
    padding: 70px 76px !important;
    align-content: center !important;
  }

  body.crm-shell-body.crm-login-active .crm-login-hero h1 {
    max-width: 520px !important;
    font-size: clamp(4rem, 7vw, 7rem) !important;
  }

  body.crm-shell-body.crm-login-active .crm-manager-form {
    align-self: center !important;
    justify-self: center !important;
    width: min(430px, calc(100% - 64px)) !important;
    margin: 0 !important;
    padding: 30px !important;
    transform: none !important;
    border: 1px solid rgba(167, 139, 250, .18) !important;
    border-radius: 18px !important;
    background: rgba(8, 10, 24, .74) !important;
    box-shadow: 0 28px 90px rgba(0, 0, 0, .42) !important;
  }

  body.crm-shell-body.crm-login-active .crm-manager-form .auth-actions,
  body.crm-shell-body.crm-login-active .crm-manager-form .auth-actions button {
    display: grid !important;
    width: 100% !important;
  }

  body.crm-shell-body.crm-login-active .crm-manager-form .auth-actions button {
    min-height: 52px !important;
    margin-top: 2px !important;
    border-radius: 12px !important;
  }
}

.toast {
  top: 24px !important;
  right: 24px !important;
  max-width: min(430px, calc(100vw - 32px)) !important;
  min-height: 56px !important;
  display: grid !important;
  align-items: center !important;
  padding: 14px 18px 14px 20px !important;
  border: 1px solid rgba(196, 181, 253, .32) !important;
  border-radius: 16px !important;
  background:
    radial-gradient(circle at 12% 0%, rgba(167, 139, 250, .34), transparent 36%),
    linear-gradient(135deg, rgba(18, 15, 42, .98), rgba(45, 31, 99, .98)) !important;
  color: #fff !important;
  font-size: .96rem !important;
  font-weight: 850 !important;
  line-height: 1.35 !important;
  box-shadow: 0 24px 70px rgba(20, 12, 55, .42) !important;
  transform: translateY(-16px) scale(.98) !important;
  opacity: 0;
  pointer-events: none;
  z-index: 10000 !important;
}

.toast.visible {
  transform: translateY(0) scale(1) !important;
  opacity: 1 !important;
}

body.crm-shell-body:not(.crm-authenticated) .crm-login-panel,
body.crm-shell-body.crm-login-active .crm-login-panel {
  position: fixed !important;
  inset: 0 !important;
  z-index: 3000 !important;
  display: grid !important;
  width: 100vw !important;
  height: 100vh !important;
  min-height: 100vh !important;
  padding: 0 !important;
  place-items: stretch !important;
  overflow: hidden !important;
  background:
    radial-gradient(circle at 18% 8%, rgba(124, 58, 237, .28), transparent 34%),
    linear-gradient(135deg, #070914 0%, #100b24 52%, #060812 100%) !important;
}

body.crm-shell-body:not(.crm-authenticated) .crm-login-shell,
body.crm-shell-body.crm-login-active .crm-login-shell {
  position: relative !important;
  z-index: 3001 !important;
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) minmax(420px, 560px) !important;
  align-items: center !important;
  width: 100vw !important;
  height: 100vh !important;
  min-height: 100vh !important;
  gap: 0 !important;
  margin: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
  overflow: visible !important;
}

body.crm-shell-body:not(.crm-authenticated) .crm-login-hero,
body.crm-shell-body.crm-login-active .crm-login-hero {
  display: grid !important;
  min-height: 100vh !important;
  padding: 70px 76px !important;
  align-content: center !important;
  opacity: 1 !important;
  visibility: visible !important;
}

body.crm-shell-body:not(.crm-authenticated) .crm-manager-form,
body.crm-shell-body.crm-login-active .crm-manager-form {
  position: fixed !important;
  top: 50% !important;
  right: clamp(32px, 7vw, 110px) !important;
  z-index: 3002 !important;
  display: grid !important;
  grid-template-columns: 1fr !important;
  gap: 14px !important;
  align-self: auto !important;
  justify-self: auto !important;
  width: min(430px, calc(100% - 64px)) !important;
  min-height: auto !important;
  margin: 0 !important;
  padding: 30px !important;
  transform: translateY(-50%) !important;
  opacity: 1 !important;
  visibility: visible !important;
  pointer-events: auto !important;
  border: 1px solid rgba(167, 139, 250, .18) !important;
  border-radius: 18px !important;
  background: rgba(8, 10, 24, .84) !important;
  box-shadow: 0 28px 90px rgba(0, 0, 0, .42) !important;
}

body.crm-shell-body:not(.crm-authenticated) .crm-manager-form label,
body.crm-shell-body.crm-login-active .crm-manager-form label,
body.crm-shell-body:not(.crm-authenticated) .crm-manager-form input,
body.crm-shell-body.crm-login-active .crm-manager-form input,
body.crm-shell-body:not(.crm-authenticated) .crm-manager-form .auth-actions,
body.crm-shell-body.crm-login-active .crm-manager-form .auth-actions,
body.crm-shell-body:not(.crm-authenticated) .crm-manager-form button,
body.crm-shell-body.crm-login-active .crm-manager-form button {
  display: grid !important;
  opacity: 1 !important;
  visibility: visible !important;
}

body.crm-shell-body:not(.crm-authenticated) .crm-manager-form input,
body.crm-shell-body.crm-login-active .crm-manager-form input {
  width: 100% !important;
  min-height: 52px !important;
}

body.crm-shell-body:not(.crm-authenticated) .crm-manager-form button,
body.crm-shell-body.crm-login-active .crm-manager-form button {
  width: 100% !important;
  min-height: 52px !important;
  border-radius: 12px !important;
}

@media (max-width: 760px) {
  body.crm-shell-body:not(.crm-authenticated) .crm-login-shell,
  body.crm-shell-body.crm-login-active .crm-login-shell {
    grid-template-columns: 1fr !important;
  }

  body.crm-shell-body:not(.crm-authenticated) .crm-login-hero,
  body.crm-shell-body.crm-login-active .crm-login-hero {
    min-height: auto !important;
    padding: 28px 22px 0 !important;
  }

  body.crm-shell-body:not(.crm-authenticated) .crm-manager-form,
  body.crm-shell-body.crm-login-active .crm-manager-form {
    position: relative !important;
    top: auto !important;
    right: auto !important;
    width: calc(100% - 28px) !important;
    transform: none !important;
  }
}

@media (min-width: 900px) {
  body.mobile-product #home .desktop-account-brief {
    display: grid !important;
    gap: 14px !important;
    min-height: 258px !important;
    padding: 22px !important;
    border: 1px solid rgba(167, 139, 250, .18) !important;
    border-radius: 10px !important;
    background:
      radial-gradient(circle at 90% 0%, rgba(20, 184, 166, .18), transparent 34%),
      linear-gradient(145deg, rgba(13, 20, 42, .94), rgba(31, 24, 62, .88)) !important;
    color: #fff !important;
    box-shadow: 0 28px 82px rgba(3, 7, 18, .34) !important;
  }

  body.mobile-product #home .desktop-account-brief .brief-head {
    display: flex !important;
    align-items: start !important;
    justify-content: space-between !important;
    gap: 14px !important;
  }

  body.mobile-product #home .desktop-account-brief .brief-head span,
  body.mobile-product #home .desktop-account-brief .brief-status-list span {
    color: #c4b5fd !important;
    font-size: .72rem !important;
    font-weight: 950 !important;
    text-transform: uppercase !important;
  }

  body.mobile-product #home .desktop-account-brief .brief-head b {
    padding: 6px 10px !important;
    border-radius: 999px !important;
    background: rgba(255, 255, 255, .10) !important;
    color: #fff !important;
    font-size: .76rem !important;
    white-space: nowrap !important;
  }

  body.mobile-product #home .desktop-account-brief .brief-metric-grid {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
    gap: 10px !important;
  }

  body.mobile-product #home .desktop-account-brief .brief-metric-grid article {
    display: grid !important;
    gap: 7px !important;
    min-height: 92px !important;
    padding: 14px !important;
    align-content: end !important;
    border: 1px solid rgba(255, 255, 255, .09) !important;
    border-radius: 8px !important;
    background: rgba(255, 255, 255, .055) !important;
  }

  body.mobile-product #home .desktop-account-brief .brief-metric-grid span {
    color: rgba(237, 233, 254, .68) !important;
    font-size: .74rem !important;
    font-weight: 850 !important;
  }

  body.mobile-product #home .desktop-account-brief .brief-metric-grid strong {
    min-width: 0 !important;
    color: #fff !important;
    font-size: clamp(1.25rem, 1.7vw, 1.85rem) !important;
    line-height: 1 !important;
    overflow-wrap: anywhere !important;
  }

  body.mobile-product #home .desktop-account-brief .brief-status-list {
    display: grid !important;
    gap: 8px !important;
  }

  body.mobile-product #home .desktop-account-brief .brief-status-list div {
    display: grid !important;
    grid-template-columns: 110px minmax(0, 1fr) !important;
    align-items: center !important;
    gap: 10px !important;
    padding: 9px 0 !important;
    border-bottom: 1px solid rgba(255, 255, 255, .08) !important;
  }

  body.mobile-product #home .desktop-account-brief .brief-status-list b {
    min-width: 0 !important;
    color: rgba(255, 255, 255, .92) !important;
    font-size: .86rem !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
    white-space: nowrap !important;
  }

  body.mobile-product #home .desktop-account-brief button {
    min-height: 46px !important;
    border: 0 !important;
    border-radius: 9px !important;
    background: linear-gradient(135deg, #4f8cff, #8b5cf6) !important;
    color: #fff !important;
    font-weight: 950 !important;
    box-shadow: 0 14px 32px rgba(79, 140, 255, .20) !important;
  }
}

@media (max-width: 899px) {
  body.mobile-product #home .desktop-account-brief {
    display: none !important;
  }

  body.mobile-product #home .desktop-fee-asset {
    display: none !important;
  }
}

/* Final CRM readability pass: larger, sharper operator UI. */
body.crm-shell-body,
body.crm-shell-body .crm-page {
  -webkit-font-smoothing: antialiased !important;
  -moz-osx-font-smoothing: grayscale !important;
  text-rendering: geometricPrecision !important;
}

body.crm-shell-body .crm-page {
  font-size: 16px !important;
}

body.crm-shell-body .crm-page .crm-side-menu button,
body.crm-shell-body .crm-page .language-switch button,
body.crm-shell-body .crm-page .theme-switch button,
body.crm-shell-body .crm-page .staff-link,
body.crm-shell-body .crm-page .mini-tabs button {
  font-size: .9rem !important;
  line-height: 1.25 !important;
}

@media (min-width: 901px) {
  body.crm-shell-body .crm-page .topbar {
    overflow-y: auto !important;
    overflow-x: hidden !important;
    scrollbar-width: thin !important;
  }

  body.crm-shell-body .crm-page .top-actions {
    min-height: 0 !important;
    padding-bottom: 24px !important;
  }

  body.crm-shell-body .crm-page .crm-side-menu {
    max-height: none !important;
    overflow: visible !important;
    gap: 6px !important;
  }

  body.crm-shell-body .crm-page .crm-side-menu button {
    min-height: 38px !important;
    flex-shrink: 0 !important;
  }

  body.crm-shell-body .crm-page .crm-side-menu [data-crm-tab="settings"] {
    display: flex !important;
  }
}

@media (max-width: 900px) {
  body.crm-shell-body {
    overflow-x: hidden !important;
    background: linear-gradient(180deg, #080b14, #0b1020) !important;
  }

  body.crm-shell-body .crm-page {
    width: 100% !important;
    max-width: none !important;
    padding: 0 !important;
  }

  body.crm-shell-body.crm-login-active .crm-page .topbar,
  body.crm-shell-body:not(.crm-authenticated) .crm-page .topbar {
    display: none !important;
  }

  body.crm-shell-body .crm-page .topbar {
    position: sticky !important;
    inset: auto !important;
    top: 0 !important;
    z-index: 1200 !important;
    width: 100% !important;
    height: auto !important;
    max-height: 52vh !important;
    overflow-y: auto !important;
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 12px !important;
    padding: 14px !important;
    border-right: 0 !important;
    border-bottom: 1px solid rgba(167, 139, 250, .16) !important;
    background: rgba(8, 11, 20, .98) !important;
  }

  body.crm-shell-body .crm-page .brand {
    order: 1 !important;
    width: 100% !important;
    min-height: 58px !important;
    margin: 0 !important;
    padding: 0 0 12px !important;
    border-bottom: 1px solid rgba(255, 255, 255, .08) !important;
  }

  body.crm-shell-body .crm-page .top-actions {
    order: 2 !important;
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 10px !important;
    width: 100% !important;
    margin: 0 !important;
  }

  body.crm-shell-body .crm-page .language-switch,
  body.crm-shell-body .crm-page .theme-switch {
    grid-template-columns: repeat(2, 1fr) !important;
  }

  body.crm-shell-body .crm-page .crm-side-menu {
    display: flex !important;
    gap: 8px !important;
    padding: 8px 0 2px !important;
    overflow-x: auto !important;
    border: 0 !important;
    background: transparent !important;
  }

  body.crm-shell-body .crm-page .crm-side-menu span {
    display: none !important;
  }

  body.crm-shell-body .crm-page .crm-side-menu button {
    flex: 0 0 auto !important;
    min-width: 112px !important;
    min-height: 42px !important;
    justify-content: center !important;
    text-align: center !important;
    border: 1px solid rgba(167, 139, 250, .16) !important;
    border-radius: 12px !important;
    background: rgba(255, 255, 255, .045) !important;
  }

  body.crm-shell-body .crm-page .staff-link {
    display: none !important;
  }

  body.crm-shell-body .crm-page #crm {
    width: 100% !important;
    margin: 0 !important;
    padding: 14px !important;
  }

  body.crm-shell-body .crm-page .section-head {
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 10px !important;
    padding: 16px !important;
  }

  body.crm-shell-body .crm-page .section-head h1 {
    font-size: clamp(1.55rem, 8vw, 2.35rem) !important;
    line-height: 1.05 !important;
  }

  body.crm-shell-body .crm-page .crm-layout,
  body.crm-shell-body .crm-page.detail-open .crm-layout {
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 14px !important;
  }

  body.crm-shell-body .crm-page .client-list,
  body.crm-shell-body .crm-page .client-detail,
  body.crm-shell-body .crm-page .comments-panel,
  body.crm-shell-body .crm-page .crm-chart-panel {
    border-radius: 14px !important;
    padding: 14px !important;
  }

  body.crm-shell-body .crm-table-head {
    display: none !important;
  }

  body.crm-shell-body .crm-page #applications .crm-list {
    border: 0 !important;
    background: transparent !important;
  }

  body.crm-shell-body .crm-page .request-card {
    grid-template-columns: 1fr !important;
    gap: 8px !important;
    min-height: auto !important;
    padding: 14px !important;
    border-radius: 14px !important;
    text-align: left !important;
  }

  body.crm-shell-body .crm-page .request-card > span,
  body.crm-shell-body .crm-page .request-card > strong,
  body.crm-shell-body .crm-page .request-card > em {
    justify-self: stretch !important;
    max-width: 100% !important;
    overflow-wrap: anywhere !important;
  }

  body.crm-shell-body .crm-page .crm-insight-grid,
  body.crm-shell-body .crm-page .crm-operations-grid,
  body.crm-shell-body .crm-page .action-grid,
  body.crm-shell-body .crm-page .detail-top,
  body.crm-shell-body .crm-page .comment-form.stacked-form {
    grid-template-columns: 1fr !important;
  }

  body.crm-shell-body.crm-client-open::before {
    content: none !important;
  }

  body.crm-shell-body.crm-client-open .crm-page.detail-open .client-list {
    display: none !important;
  }

  body.crm-shell-body.crm-client-open .crm-page.detail-open .client-detail {
    display: block !important;
  }
}

body.crm-shell-body .crm-side-menu span,
body.crm-shell-body .crm-page .top-actions::before,
body.crm-shell-body .crm-page .client-list::before,
body.crm-shell-body .crm-page .access-badge,
body.crm-shell-body .crm-page .request-card em,
body.crm-shell-body .crm-page .panel-title span,
body.crm-shell-body .crm-page .crm-withdraw-form label {
  font-size: .78rem !important;
  letter-spacing: .08em !important;
}

body.crm-shell-body .crm-table-head {
  font-size: .76rem !important;
  line-height: 1.25 !important;
}

body.crm-shell-body .crm-page .request-card span,
body.crm-shell-body .crm-page .request-card small,
body.crm-shell-body .crm-page .detail-top p,
body.crm-shell-body .crm-page .comments-panel p,
body.crm-shell-body .crm-page .comment-feed,
body.crm-shell-body .crm-page .comment-feed p,
body.crm-shell-body .crm-page .support-ticket-row,
body.crm-shell-body .crm-page .support-ticket-row p,
body.crm-shell-body .crm-page .transaction-row,
body.crm-shell-body .crm-page .chat-ticket,
body.crm-shell-body .crm-page .metric-row,
body.crm-shell-body .crm-page input,
body.crm-shell-body .crm-page textarea,
body.crm-shell-body .crm-page select {
  font-size: .95rem !important;
  line-height: 1.45 !important;
}

body.crm-shell-body .crm-page .request-card b,
body.crm-shell-body .crm-page .request-card strong,
body.crm-shell-body .crm-page .detail-top h2,
body.crm-shell-body .crm-page .panel-title h2,
body.crm-shell-body .crm-page .metric-row b {
  font-size: 1.08rem !important;
  line-height: 1.25 !important;
}

body.crm-shell-body .crm-page button,
body.crm-shell-body .crm-page .action-grid a,
body.crm-shell-body .crm-page .comment-form button,
body.crm-shell-body .crm-page .crm-withdraw-form button,
body.crm-shell-body .crm-page .chat-ticket button,
body.crm-shell-body .crm-page .support-ticket-row button,
body.crm-shell-body .crm-page .crm-back-button {
  font-size: .86rem !important;
  line-height: 1.2 !important;
}

body.crm-shell-body .crm-page .section-head h1 {
  font-size: clamp(2.35rem, 3.4vw, 3.6rem) !important;
}

body.crm-shell-body .crm-page .balance-pill span {
  font-size: .78rem !important;
}

body.crm-shell-body .crm-page .balance-pill strong {
  font-size: clamp(1.9rem, 2.4vw, 2.55rem) !important;
}

body.crm-shell-body .crm-manager-create-form label {
  font-size: .86rem !important;
}

body.crm-shell-body .crm-manager-create-form button {
  font-size: .9rem !important;
}

body.crm-shell-body .crm-profile-card span {
  font-size: .82rem !important;
}

body.crm-shell-body .crm-assignment-form {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) auto !important;
  gap: 10px !important;
  align-items: end !important;
  margin: 0 0 16px !important;
  padding: 14px !important;
  border: 1px solid rgba(167, 139, 250, .18) !important;
  border-radius: 10px !important;
  background: rgba(255, 255, 255, .045) !important;
}

body.crm-shell-body .crm-assignment-form.hidden {
  display: none !important;
}

body.crm-shell-body .webrtc-phone-panel {
  position: fixed;
  right: 22px;
  bottom: 22px;
  z-index: 12000;
  width: min(360px, calc(100vw - 28px));
  min-height: 118px;
  border: 1px solid rgba(96, 165, 250, .28);
  border-radius: 12px;
  background: linear-gradient(145deg, rgba(15, 23, 42, .96), rgba(35, 28, 74, .96));
  box-shadow: 0 24px 60px rgba(0, 0, 0, .42);
  color: #fff;
  overflow: hidden;
}

body.crm-shell-body .webrtc-phone-panel.hidden {
  display: none !important;
}

body.crm-shell-body .webrtc-phone-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 16px;
  border-bottom: 1px solid rgba(255, 255, 255, .1);
}

body.crm-shell-body .webrtc-phone-head span,
body.crm-shell-body .webrtc-phone-head strong {
  display: block;
}

body.crm-shell-body .webrtc-phone-head span {
  font-size: .78rem;
  font-weight: 900;
  color: rgba(196, 181, 253, .95);
  text-transform: uppercase;
}

body.crm-shell-body .webrtc-phone-head strong {
  margin-top: 3px;
  font-size: 1rem;
  color: #fff;
}

body.crm-shell-body #webrtcPhoneClose {
  width: 34px;
  height: 34px;
  border: 1px solid rgba(255, 255, 255, .16);
  border-radius: 9px;
  background: rgba(255, 255, 255, .08);
  color: #fff;
  font-size: 1.35rem;
  line-height: 1;
}

body.crm-shell-body .webrtc-phone-body {
  min-height: 54px;
  padding: 14px 16px;
  background: rgba(2, 6, 23, .34);
}

body.crm-shell-body #zdrmWPhI.zdrm-fixed,
body.crm-shell-body #zdrmWPhI {
  position: fixed !important;
  top: auto !important;
  left: auto !important;
  right: 24px !important;
  bottom: 154px !important;
  margin: 0 !important;
  z-index: 12100 !important;
}

body.crm-shell-body #zdrmWPhI .zdrm-webphone {
  max-width: min(348px, calc(100vw - 28px)) !important;
}

body.crm-shell-body #zdrmWPhI .zdrm-webphone-box,
body.crm-shell-body #zdrmWPhI .zdrm-webphone-call-btn {
  box-shadow: 0 16px 36px rgba(0, 0, 0, .28) !important;
}

@media (max-width: 640px) {
  body.crm-shell-body #zdrmWPhI.zdrm-fixed,
  body.crm-shell-body #zdrmWPhI {
    right: 14px !important;
    bottom: 132px !important;
  }
}

body.crm-shell-body .crm-assignment-form label {
  display: grid !important;
  gap: 7px !important;
  color: rgba(237, 233, 254, .82) !important;
  font-size: .84rem !important;
  font-weight: 900 !important;
}

body.crm-shell-body .crm-assignment-form select {
  min-height: 44px !important;
  border: 1px solid rgba(148, 163, 184, .24) !important;
  border-radius: 10px !important;
  background: rgba(2, 6, 23, .48) !important;
  color: #fff !important;
  padding: 0 12px !important;
}

body.crm-shell-body .crm-assignment-form button {
  min-height: 44px !important;
  border: 0 !important;
  border-radius: 10px !important;
  background: linear-gradient(135deg, #4f8cff, #8b5cf6) !important;
  color: #fff !important;
  font-weight: 950 !important;
}

body.crm-shell-body .crm-events-title {
  margin-top: 18px !important;
}

body.crm-shell-body .crm-event-row p {
  color: rgba(237, 233, 254, .74) !important;
  word-break: break-word !important;
}

body.crm-shell-body .crm-internal-chat {
  display: grid !important;
  gap: 12px !important;
  margin-bottom: 18px !important;
  padding: 16px !important;
  border: 1px solid rgba(167, 139, 250, .18) !important;
  border-radius: 10px !important;
  background:
    radial-gradient(circle at 92% 0%, rgba(20, 184, 166, .14), transparent 34%),
    rgba(255, 255, 255, .045) !important;
}

body.crm-shell-body .crm-internal-feed {
  display: grid !important;
  gap: 10px !important;
  max-height: 320px !important;
  overflow: auto !important;
  padding: 10px !important;
  border: 1px solid rgba(148, 163, 184, .16) !important;
  border-radius: 10px !important;
  background: rgba(2, 6, 23, .35) !important;
}

body.crm-shell-body .crm-internal-message {
  display: grid !important;
  gap: 4px !important;
  margin: 0 !important;
  padding: 11px 12px !important;
  border: 1px solid rgba(255, 255, 255, .08) !important;
  border-radius: 9px !important;
  background: rgba(255, 255, 255, .055) !important;
  color: #fff !important;
}

body.crm-shell-body .crm-internal-message b {
  color: #fff !important;
}

body.crm-shell-body .crm-internal-message span {
  color: rgba(237, 233, 254, .88) !important;
  line-height: 1.45 !important;
  word-break: break-word !important;
}

body.crm-shell-body .crm-internal-message small {
  color: rgba(237, 233, 254, .54) !important;
}

body.crm-shell-body .crm-support-title {
  margin-top: 4px !important;
}

/* CRM shell final layout guard: keeps brand, switches and navigation separated. */
@media (min-width: 901px) {
  body.crm-shell-body .crm-page .topbar {
    display: grid !important;
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-rows: auto auto !important;
    grid-template-areas: "brand" "actions" !important;
    align-content: start !important;
    align-items: start !important;
    gap: 14px !important;
    padding-top: 18px !important;
  }

  body.crm-shell-body .crm-page .brand {
    grid-area: brand !important;
    position: relative !important;
    z-index: 2 !important;
    min-height: 66px !important;
    margin: 0 !important;
    padding: 8px 8px 14px !important;
  }

  body.crm-shell-body .crm-page .top-actions {
    grid-area: actions !important;
    position: relative !important;
    z-index: 1 !important;
    top: auto !important;
    right: auto !important;
    bottom: auto !important;
    left: auto !important;
    margin: 0 !important;
    padding-bottom: 20px !important;
  }

  body.crm-shell-body .crm-page .language-switch,
  body.crm-shell-body .crm-page .theme-switch {
    min-height: 42px !important;
    margin: 0 !important;
  }
}

@media (max-width: 900px) {
  body.crm-shell-body .crm-page .topbar {
    position: sticky !important;
    top: 0 !important;
    z-index: 1200 !important;
    width: 100% !important;
    height: auto !important;
    max-height: none !important;
    display: grid !important;
    grid-template-columns: 1fr !important;
    grid-template-areas: "brand" "actions" !important;
    gap: 10px !important;
    padding: 12px !important;
    overflow: visible !important;
  }

  body.crm-shell-body .crm-page .brand {
    grid-area: brand !important;
    min-height: 56px !important;
    padding: 0 0 10px !important;
  }

  body.crm-shell-body .crm-page .top-actions {
    grid-area: actions !important;
    position: static !important;
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 8px !important;
    width: 100% !important;
  }

  body.crm-shell-body .crm-page .language-switch,
  body.crm-shell-body .crm-page .theme-switch {
    min-height: 40px !important;
  }

  body.crm-shell-body .crm-page .crm-side-menu {
    display: flex !important;
    gap: 8px !important;
    width: 100% !important;
    padding: 2px 0 4px !important;
    overflow-x: auto !important;
    overflow-y: hidden !important;
    scroll-snap-type: x proximity !important;
  }

  body.crm-shell-body .crm-page .crm-side-menu button {
    flex: 0 0 auto !important;
    min-width: 118px !important;
    min-height: 42px !important;
    scroll-snap-align: start !important;
  }

  body.crm-shell-body .crm-page #crm {
    margin: 0 !important;
    width: 100% !important;
    padding: 12px !important;
  }

  body.crm-shell-body .crm-page .crm-table-head {
    display: none !important;
  }

  body.crm-shell-body .crm-page .request-card {
    grid-template-columns: 1fr !important;
    align-items: start !important;
  }
}

/* Keep the Customers list scrollable after all theme and responsive rules. */
.crm-page #applications .crm-list {
  height: min(70vh, 760px) !important;
  max-height: min(70vh, 760px) !important;
  overflow-x: hidden !important;
  overflow-y: auto !important;
  overscroll-behavior: contain;
}

@media (max-width: 900px) {
  .crm-page #applications .crm-list {
    height: 62vh !important;
    max-height: 62vh !important;
  }
}
