/* =====================================================
   ONNTRADE COMPLETE GLOBAL PREMIUM THEME
   WHITE + SKY BLUE | ALL CLIENT PAGES
   UI ONLY - NO BACKEND OR BUSINESS LOGIC CHANGES
   ===================================================== */

:root {
  --ot-bg: #ffffff;
  --ot-card: #e5f1ff;
  --ot-card-light: #f2f7ff;
  --ot-border: #b8d5ff;
  --ot-text: #142b4d;
  --ot-muted: #526987;
  --ot-blue: #0875ed;
  --ot-blue-dark: #0756bd;
  --ot-green: #0ba878;
  --ot-red: #e05267;
  --ot-shadow: 0 6px 22px rgba(30, 90, 160, .09);
}

/* GLOBAL BACKGROUND AND TEXT */
html, body, #root {
  background: var(--ot-bg) !important;
  color: var(--ot-text) !important;
}

#root .app-shell,
#root .app-main,
#root .page,
#root .page-content,
#root .dashboard-page,
#root .placeholder-page,
#root .zx-dashboard,
#root .zx-wrap,
#root .my-wallet-page,
#root .crypto-ex-shell,
#root .crypto-ex-history {
  background: #ffffff !important;
  color: var(--ot-text) !important;
}

/* SIDEBAR */
#root .sidebar {
  background: #ffffff !important;
  border-right: 1px solid var(--ot-border) !important;
}

#root .sidebar-section-title {
  color: var(--ot-blue) !important;
}

#root .nav-item {
  color: var(--ot-text) !important;
  background: transparent !important;
}

#root .nav-item:hover,
#root .nav-item.active,
#root .nav-item[aria-current="page"] {
  background: linear-gradient(110deg,#0875ed,#3998ff) !important;
  color: #ffffff !important;
}

#root .nav-icon {
  color: var(--ot-blue) !important;
}

/* HEADER */
#root .topbar {
  background: #ffffff !important;
  color: var(--ot-text) !important;
  border-bottom: 1px solid var(--ot-border) !important;
}

/* ALL COMMON CARDS */
#root :is(
.dashboard-card,
.stat-card,
.section-card,
.panel,
.zx-panel,
.zx-ref-card,
.mw-section,
.mw-wallet-card,
.mw-stat-card,
.mw-panel,
.mw-action-panel,
.crypto-ex-panel,
.crypto-ex-market-card,
.crypto-ex-futures-card,
.crypto-ex-detail-panel,
.crypto-ex-account,
.crypto-ex-accounts,
.account-main,
.account-row,
.ot-stat-panel,
.ot-price-card,
.ot-access-card,
.ot-calculator-card,
.ot-crypto-card,
.ot-exchange-card,
.ot-forex-broker-card,
.ot-mt5-platform-card,
.ONNTRADE-referral-card,
.ONNTRADE-signup-card,
.ONNTRADE-signup-form-panel
) {
  background: var(--ot-card) !important;
  color: var(--ot-text) !important;
  border: 1px solid var(--ot-border) !important;
  box-shadow: var(--ot-shadow) !important;
  border-radius: 16px !important;
}

/* DASHBOARD HERO */
#root :is(.zx-hero,.zx-ref-card) {
  background: linear-gradient(120deg,#d9eaff,#edf6ff) !important;
  color: var(--ot-text) !important;
  border-color: var(--ot-border) !important;
}

/* WALLET */
#root .my-wallet-page {
  background: #ffffff !important;
}

#root .my-wallet-page :is(
.mw-wallet-card,
.mw-stat-card,
.mw-section,
.mw-panel,
.mw-action-panel
) {
  background: var(--ot-card) !important;
  border: 1px solid var(--ot-border) !important;
  color: var(--ot-text) !important;
}

#root .my-wallet-page :is(
.mw-wallet-card-label,
.mw-wallet-balance,
.mw-wallet-breakdown strong,
.mw-section-title,
.mw-stat-value,
.mw-action-panel-title,
.mw-empty-title
) {
  color: var(--ot-text) !important;
  opacity: 1 !important;
}

#root .my-wallet-page :is(
.mw-wallet-breakdown span,
.mw-panel-text,
.mw-empty-text,
.mw-footer-note
) {
  color: var(--ot-muted) !important;
  opacity: 1 !important;
}

/* ADD FUNDS AND TRANSFER */
#root .my-wallet-page :is(
.mw-section,
.mw-action-panel,
.mw-action-row,
.mw-deposit-info
) {
  background: var(--ot-card) !important;
  color: var(--ot-text) !important;
  border-color: var(--ot-border) !important;
}

#root .my-wallet-page :is(
.mw-action-title,
.mw-action-text,
.mw-field label,
.mw-form-field label
) {
  color: var(--ot-text) !important;
}

/* TRANSACTION TABLES */
#root :is(
.mw-table,
.responsive-table,
.table-responsive,
.table-wrap,
.table-wrapper,
.crypto-ex-table-wrap
) {
  background: #ffffff !important;
  color: var(--ot-text) !important;
}

#root .mw-table th,
#root .responsive-table th {
  background: #cfe4ff !important;
  color: #142b4d !important;
  border-color: var(--ot-border) !important;
}

#root .mw-table td,
#root .mw-table tr,
#root .responsive-table td {
  color: var(--ot-text) !important;
  border-color: #d4e5fb !important;
}

#root .mw-table tbody tr:nth-child(even) {
  background: #f2f7ff !important;
}

#root .mw-table tbody tr:nth-child(odd) {
  background: #ffffff !important;
}

/* ALL HEADINGS AND TEXT */
#root :is(
h1,h2,h3,h4,h5,h6,
.page-title,
.section-title,
.panel-title,
.panel-header,
.mw-section-title
) {
  color: var(--ot-text) !important;
  opacity: 1 !important;
}

#root :is(
.page-content p,
.page-content label,
.page-content small,
.page-content .description,
.dashboard-page p,
.my-wallet-page p
) {
  color: var(--ot-muted) !important;
  opacity: 1 !important;
}

/* FORMS AND INPUTS */
#root input,
#root textarea,
#root select {
  background: #ffffff !important;
  color: var(--ot-text) !important;
  border: 1px solid var(--ot-border) !important;
  border-radius: 10px !important;
}

#root input::placeholder,
#root textarea::placeholder {
  color: #7187a3 !important;
  opacity: 1 !important;
}

#root label {
  color: var(--ot-text) !important;
}

/* BUTTONS */
#root button,
#root .mw-primary,
#root .mw-action-button {
  border-radius: 10px;
}

#root :is(
.mw-primary,
.ONNTRADE-signup-submit,
.ONNTRADE-copy-button
) {
  background: linear-gradient(110deg,#0875ed,#3998ff) !important;
  color: #ffffff !important;
  border-color: var(--ot-blue) !important;
}

#root button:not(:disabled):hover {
  filter: brightness(.97);
}

/* ICONS */
#root .nav-icon,
#root .mw-action-icon,
#root .mw-stat-icon,
#root .ot-mt5-logo,
#root .ot-exchange-logo {
  color: var(--ot-blue) !important;
}

/* PRESERVE SEMANTIC FINANCIAL COLORS */
#root :is(.credit,.success,.completed) {
  color: var(--ot-green) !important;
}

#root :is(.debit,.error,.failed) {
  color: var(--ot-red) !important;
}

/* AUTHENTICATION PAGES */
#root :is(
.login-page,
.ONNTRADE-signup-page,
.zfx-auth-page,
.zx-auth-page
) {
  background: #ffffff !important;
  color: var(--ot-text) !important;
}

#root :is(
.login-card,
.ONNTRADE-signup-card,
.zfx-auth-card,
.zx-auth-card
) {
  background: var(--ot-card) !important;
  color: var(--ot-text) !important;
  border: 1px solid var(--ot-border) !important;
}

/* REFERRAL LEVELS */
#root .zx-referral-grid,
#root .ONNTRADE-referral-row {
  color: var(--ot-text) !important;
}

/* TABLE AND CONTENT READABILITY */
#root .responsive-table,
#root .table-responsive {
  overflow-x: auto !important;
  -webkit-overflow-scrolling: touch;
}

/* REMOVE DARK BACKGROUNDS FROM KNOWN CLIENT COMPONENTS */
#root :is(
.crypto-ex-shell,
.crypto-ex-panel,
.crypto-ex-history,
.zx-mt5,
.zx-mt5-grid
) {
  background-color: #ffffff !important;
  color: var(--ot-text) !important;
}

/* MOBILE */
@media(max-width:768px) {
  #root .page-content,
  #root .my-wallet-page {
    padding-left: 12px !important;
    padding-right: 12px !important;
  }

  #root :is(
  .dashboard-card,
  .stat-card,
  .section-card,
  .mw-wallet-card,
  .mw-section
  ) {
    border-radius: 13px !important;
  }

  #root .mw-table-wrap {
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch;
  }
}

/* END ONNTRADE GLOBAL THEME */

/* ONNTRADE QR CODE - FINAL SCANNABLE FIX */

/* First SVG path: white background */
#root .my-wallet-page .mw-auto-deposit-premium svg > path:first-of-type {
  fill: #ffffff !important;
  opacity: 1 !important;
}

/* Second SVG path: black QR modules */
#root .my-wallet-page .mw-auto-deposit-premium svg > path:last-of-type {
  fill: #000000 !important;
  opacity: 1 !important;
}

/* QR container */
#root .my-wallet-page .mw-auto-deposit-premium svg {
  display: block !important;
  width: 184px !important;
  height: 184px !important;
  max-width: 100% !important;
  background: #ffffff !important;
  padding: 8px !important;
  border-radius: 10px !important;
  shape-rendering: crispEdges !important;
}

/* END QR FIX */

/* =====================================================
   ONNTRADE TRANSFER FUNDS - PREMIUM FINAL UI
   WHITE + SKY BLUE
   CSS ONLY - NO FUNCTIONALITY CHANGES
   ===================================================== */

#root .my-wallet-page .mw-action-panel:has(.mw-form-grid select) {
  width: 100% !important;
  max-width: 1080px !important;
  margin: 20px auto !important;
  padding: 28px !important;
  background: linear-gradient(145deg,#f5f9ff,#e5f1ff) !important;
  border: 1px solid #b8d5ff !important;
  border-radius: 20px !important;
  box-shadow: 0 12px 32px rgba(31,100,180,.09) !important;
  color: #142b4d !important;
}

#root .my-wallet-page .mw-action-panel:has(.mw-form-grid select) .mw-action-panel-head {
  display: flex !important;
  align-items: flex-start !important;
  justify-content: space-between !important;
  gap: 16px !important;
  margin-bottom: 24px !important;
}

#root .my-wallet-page .mw-action-panel:has(.mw-form-grid select) .mw-action-panel-title {
  color: #123665 !important;
  font-size: 23px !important;
  font-weight: 800 !important;
  line-height: 1.4 !important;
}

#root .my-wallet-page .mw-action-panel:has(.mw-form-grid select) .mw-action-panel-text {
  color: #526987 !important;
  font-size: 14px !important;
  line-height: 1.7 !important;
  margin-top: 6px !important;
}

#root .my-wallet-page .mw-action-panel:has(.mw-form-grid select) .mw-form-grid {
  display: grid !important;
  grid-template-columns: repeat(2,minmax(0,1fr)) !important;
  gap: 20px !important;
  align-items: start !important;
}

#root .my-wallet-page .mw-action-panel:has(.mw-form-grid select) .mw-form-wide {
  grid-column: 1 / -1 !important;
}

#root .my-wallet-page .mw-action-panel:has(.mw-form-grid select) .mw-form-field {
  display: flex !important;
  flex-direction: column !important;
  gap: 9px !important;
  min-width: 0 !important;
  color: #183b66 !important;
  font-size: 13px !important;
  font-weight: 750 !important;
}

#root .my-wallet-page .mw-action-panel:has(.mw-form-grid select) .mw-form-field:has(input[type="number"]),
#root .my-wallet-page .mw-action-panel:has(.mw-form-grid select) .mw-form-field:has(input[type="password"]) {
  grid-column: span 1 !important;
}

#root .my-wallet-page .mw-action-panel:has(.mw-form-grid select) .mw-form-field input,
#root .my-wallet-page .mw-action-panel:has(.mw-form-grid select) .mw-form-field select {
  width: 100% !important;
  min-width: 0 !important;
  height: 54px !important;
  padding: 0 16px !important;
  border: 1px solid #b5d2fb !important;
  border-radius: 12px !important;
  background: #ffffff !important;
  color: #142b4d !important;
  font-size: 14px !important;
  font-weight: 600 !important;
  box-shadow: 0 2px 5px rgba(30,90,160,.04) !important;
}

#root .my-wallet-page .mw-action-panel:has(.mw-form-grid select) .mw-form-field input::placeholder {
  color: #8298b5 !important;
  opacity: 1 !important;
}

#root .my-wallet-page .mw-action-panel:has(.mw-form-grid select) .mw-form-field input:focus,
#root .my-wallet-page .mw-action-panel:has(.mw-form-grid select) .mw-form-field select:focus {
  border-color: #2584ff !important;
  outline: 3px solid rgba(37,132,255,.12) !important;
}

#root .my-wallet-page .mw-action-panel:has(.mw-form-grid select) .mw-deposit-info {
  grid-column: 1 / -1 !important;
  display: grid !important;
  grid-template-columns: repeat(2,minmax(0,1fr)) !important;
  gap: 14px !important;
  padding: 20px !important;
  background: #ffffff !important;
  border: 1px solid #c6dcff !important;
  border-radius: 15px !important;
  color: #526987 !important;
  font-size: 13px !important;
  line-height: 1.7 !important;
}

#root .my-wallet-page .mw-action-panel:has(.mw-form-grid select) .mw-deposit-info strong {
  color: #145db0 !important;
  font-weight: 800 !important;
}

#root .my-wallet-page .mw-action-panel:has(.mw-form-grid select) .mw-deposit-info > div:last-child {
  grid-column: 1 / -1 !important;
  padding-top: 12px !important;
  border-top: 1px solid #e1ebfa !important;
}

#root .my-wallet-page .mw-action-panel:has(.mw-form-grid select) .mw-form-actions {
  grid-column: 1 / -1 !important;
  display: flex !important;
  justify-content: flex-end !important;
  margin-top: 2px !important;
}

#root .my-wallet-page .mw-action-panel:has(.mw-form-grid select) .mw-primary-action {
  min-width: 210px !important;
  min-height: 52px !important;
  padding: 13px 25px !important;
  border: 0 !important;
  border-radius: 12px !important;
  background: linear-gradient(110deg,#0876ee,#369cff) !important;
  color: #ffffff !important;
  font-size: 15px !important;
  font-weight: 800 !important;
  box-shadow: 0 7px 18px rgba(20,112,225,.2) !important;
  cursor: pointer !important;
}

#root .my-wallet-page .mw-action-panel:has(.mw-form-grid select) .mw-primary-action:hover {
  filter: brightness(1.05) !important;
  transform: translateY(-1px) !important;
}

#root .my-wallet-page .mw-action-panel:has(.mw-form-grid select) .mw-action-close {
  background: #ffffff !important;
  color: #174b83 !important;
  border: 1px solid #c4dcff !important;
  border-radius: 10px !important;
}

#root .my-wallet-page .mw-action-panel:has(.mw-form-grid select) .mw-action-error,
#root .my-wallet-page .mw-action-panel:has(.mw-form-grid select) .mw-action-success {
  grid-column: 1 / -1 !important;
}

/* MOBILE */
@media(max-width:700px) {
  #root .my-wallet-page .mw-action-panel:has(.mw-form-grid select) {
    padding: 17px !important;
    border-radius: 15px !important;
  }

  #root .my-wallet-page .mw-action-panel:has(.mw-form-grid select) .mw-form-grid {
    grid-template-columns: 1fr !important;
    gap: 15px !important;
  }

  #root .my-wallet-page .mw-action-panel:has(.mw-form-grid select) .mw-form-field,
  #root .my-wallet-page .mw-action-panel:has(.mw-form-grid select) .mw-deposit-info,
  #root .my-wallet-page .mw-action-panel:has(.mw-form-grid select) .mw-form-actions {
    grid-column: 1 / -1 !important;
  }

  #root .my-wallet-page .mw-action-panel:has(.mw-form-grid select) .mw-deposit-info {
    grid-template-columns: 1fr !important;
    padding: 15px !important;
  }

  #root .my-wallet-page .mw-action-panel:has(.mw-form-grid select) .mw-primary-action {
    width: 100% !important;
  }
}

/* END PREMIUM TRANSFER UI */

/* =====================================================
   ONNTRADE EXCHANGE CONNECT + HISTORY
   COMPLETE WHITE / SKY BLUE PREMIUM UI
   ===================================================== */

/* Main ExchangeHub */
#root main:has(> div > button) {
  background: #ffffff !important;
  color: #142b4d !important;
}

/* Exchange tabs header */
#root main:has(> div > button) > div:first-child {
  background: #ffffff !important;
  border-bottom: 1px solid #c5dcff !important;
  padding: 18px 24px !important;
}

/* Connect Exchange and Exchange History buttons */
#root main:has(> div > button) > div:first-child button {
  background: #e5f1ff !important;
  color: #1454a0 !important;
  border: 1px solid #a9ccff !important;
  border-radius: 12px !important;
  font-weight: 800 !important;
  box-shadow: 0 3px 12px rgba(30,100,190,.07) !important;
}

#root main:has(> div > button) > div:first-child button:hover {
  background: #d5e8ff !important;
  color: #075fc7 !important;
}

#root main:has(> div > button) > div:first-child button:focus,
#root main:has(> div > button) > div:first-child button:active {
  outline: 2px solid #70adff !important;
}

/* Coming Soon outer background */
#root main:has(> div > button) div[style*="radial-gradient"] {
  background: #ffffff !important;
  padding: 30px 22px !important;
}

/* Coming Soon premium card */
#root main:has(> div > button) div[style*="max-width: 760px"] {
  background: linear-gradient(145deg,#ffffff,#edf5ff) !important;
  border: 1px solid #b8d5ff !important;
  border-radius: 24px !important;
  box-shadow: 0 15px 40px rgba(35,100,180,.10) !important;
  padding: 48px 30px !important;
}

/* Coming Soon icon */
#root main:has(> div > button) div[style*="max-width: 760px"] > div:first-child {
  background: #dcecff !important;
  border: 1px solid #a9ccff !important;
  color: #0877ee !important;
}

/* Platform update label */
#root main:has(> div > button) div[style*="max-width: 760px"] > div:nth-child(2) {
  color: #0877ee !important;
}

/* Coming Soon heading */
#root main:has(> div > button) div[style*="max-width: 760px"] h2 {
  color: #142b4d !important;
  font-weight: 900 !important;
}

/* Coming Soon descriptions */
#root main:has(> div > button) div[style*="max-width: 760px"] p {
  color: #526987 !important;
}

/* Development badge */
#root main:has(> div > button) div[style*="max-width: 760px"] > div:nth-of-type(2) {
  background: #e3f1ff !important;
  border: 1px solid #b8d5ff !important;
  color: #0877ee !important;
}

/* Exchange History component */
#root main:has(> div > button) [class^="crypto-ex-"],
#root main:has(> div > button) [class*=" crypto-ex-"] {
  color: #142b4d;
}

/* Exchange history detail rows */
#root main:has(> div > button) .crypto-ex-detail-row {
  background: #f0f6ff !important;
  color: #142b4d !important;
  border-bottom: 1px solid #d5e5fa !important;
}

#root main:has(> div > button) .crypto-ex-detail-row strong {
  color: #142b4d !important;
}

#root main:has(> div > button) .crypto-ex-detail-empty,
#root main:has(> div > button) .crypto-ex-sync {
  color: #526987 !important;
  background: #f2f7ff !important;
}

/* History headings and labels */
#root main:has(> div > button) [class^="crypto-ex-"] h1,
#root main:has(> div > button) [class^="crypto-ex-"] h2,
#root main:has(> div > button) [class^="crypto-ex-"] h3 {
  color: #142b4d !important;
}

/* Positive and negative P&L retain their meaning */
#root main:has(> div > button) .positive {
  color: #079968 !important;
}

#root main:has(> div > button) .negative {
  color: #e05252 !important;
}

/* Mobile responsiveness */
@media(max-width:768px) {
  #root main:has(> div > button) > div:first-child {
    padding: 12px !important;
    gap: 8px !important;
  }

  #root main:has(> div > button) > div:first-child button {
    flex: 1 1 auto !important;
    padding: 11px 12px !important;
    font-size: 12px !important;
  }

  #root main:has(> div > button) div[style*="max-width: 760px"] {
    padding: 30px 18px !important;
    border-radius: 18px !important;
  }
}

/* END EXCHANGE PREMIUM THEME */

/* EXCHANGE HUB - DOM STRUCTURE BASED FINAL OVERRIDE */

body main:has(> div > button) {
  background: #ffffff !important;
  color: #142b4d !important;
}

/* Tab bar */
body main:has(> div > button) > div:first-child {
  background: #ffffff !important;
  border-bottom: 1px solid #c5dcff !important;
}

/* Tab buttons */
body main:has(> div > button) > div:first-child button {
  background: #e5f1ff !important;
  color: #1454a0 !important;
  border: 1px solid #a9ccff !important;
}

body main:has(> div > button) > div:first-child button:focus {
  background: #d5e8ff !important;
  color: #075fc7 !important;
}

/* Coming Soon outer container */
body main:has(> div > button) > div:nth-child(2) {
  background: #ffffff !important;
}

/* Coming Soon card */
body main:has(> div > button) > div:nth-child(2) > div:first-child {
  background: linear-gradient(145deg,#ffffff,#edf5ff) !important;
  border: 1px solid #b8d5ff !important;
  box-shadow: 0 15px 40px rgba(35,100,180,.10) !important;
}

/* Coming Soon icon */
body main:has(> div > button) > div:nth-child(2) > div:first-child > div:first-child {
  background: #dcecff !important;
  border-color: #a9ccff !important;
  color: #0877ee !important;
}

/* Coming Soon text */
body main:has(> div > button) h2 {
  color: #142b4d !important;
}

body main:has(> div > button) p {
  color: #526987 !important;
}

body main:has(> div > button) > div:nth-child(2) > div:first-child > div:nth-child(2) {
  color: #0877ee !important;
}

/* Development badge */
body main:has(> div > button) > div:nth-child(2) > div:first-child > div:nth-child(5) {
  background: #e3f1ff !important;
  border: 1px solid #b8d5ff !important;
  color: #0877ee !important;
}

/* Exchange history text and rows */
body main:has(> div > button) [class*="crypto-ex-"] {
  color: #142b4d;
}

body main:has(> div > button) .crypto-ex-detail-row {
  background: #f0f6ff !important;
  color: #142b4d !important;
  border-color: #d5e5fa !important;
}

body main:has(> div > button) .crypto-ex-detail-row strong {
  color: #142b4d !important;
}

body main:has(> div > button) .crypto-ex-detail-empty,
body main:has(> div > button) .crypto-ex-sync {
  color: #526987 !important;
}

@media(max-width:768px) {
  body main:has(> div > button) > div:first-child {
    padding: 12px !important;
  }

  body main:has(> div > button) > div:first-child button {
    padding: 10px 12px !important;
    font-size: 12px !important;
  }

  body main:has(> div > button) > div:nth-child(2) > div:first-child {
    padding: 28px 16px !important;
  }
}

/* END EXCHANGE DOM OVERRIDE */

/* ONNTRADE EXCHANGE - FINAL LABEL AND BADGE POLISH */

/* Platform update: remove unwanted full-width blue bar */
body main:has(> div > button)
> div:nth-child(2) > div:first-child > div:nth-child(2) {
  display: block !important;
  width: fit-content !important;
  max-width: 100% !important;
  margin: 0 auto 15px !important;
  padding: 0 !important;
  background: transparent !important;
  border: 0 !important;
  box-shadow: none !important;
  color: #0877ee !important;
  text-align: center !important;
  letter-spacing: 2px !important;
}

/* Development badge: premium blue style */
body main:has(> div > button)
> div:nth-child(2) > div:first-child > div:nth-child(5) {
  display: inline-flex !important;
  align-items: center !important;
  justify-content: center !important;
  width: fit-content !important;
  padding: 11px 20px !important;
  margin-top: 28px !important;
  border: 1px solid #a9ccff !important;
  border-radius: 999px !important;
  background: #e5f1ff !important;
  color: #0877ee !important;
  box-shadow: 0 5px 14px rgba(35,100,180,.08) !important;
}

/* Final card typography */
body main:has(> div > button)
> div:nth-child(2) > div:first-child h2 {
  color: #142b4d !important;
}

body main:has(> div > button)
> div:nth-child(2) > div:first-child p {
  color: #526987 !important;
}

/* END EXCHANGE FINISHING PATCH */

/* =====================================================
   ONNTRADE MT5 COMPLETE PREMIUM WHITE + SKY BLUE
   MT5 COPY TRADING + GAS FUEL SETTLEMENT
   UI ONLY - BUSINESS LOGIC UNCHANGED
   ===================================================== */

/* MT5 PAGE */
#root main:has([style*="#081820"]) {
  background: #ffffff !important;
  color: #142b4d !important;
}

/* MT5 Hero */
#root main:has([style*="#081820"]) [style*="#081820"],
#root main:has([style*="#081820"]) [style*="#0b1d2a"] {
  background: linear-gradient(135deg,#ffffff,#eaf4ff) !important;
  border: 1px solid #b8d5ff !important;
  box-shadow: 0 12px 35px rgba(30,100,180,.09) !important;
  color: #142b4d !important;
}

/* MT5 Typography */
#root main:has([style*="#081820"]) [style*="#f5f9fc"],
#root main:has([style*="#081820"]) [style*="#e8f1f8"],
#root main:has([style*="#081820"]) [style*="#e8f5fb"],
#root main:has([style*="#081820"]) [style*="#dceaf2"] {
  color: #142b4d !important;
}

#root main:has([style*="#081820"]) [style*="#91a9bb"],
#root main:has([style*="#081820"]) [style*="#7895a7"],
#root main:has([style*="#081820"]) [style*="#7795a8"],
#root main:has([style*="#081820"]) [style*="#627f91"] {
  color: #526987 !important;
}

/* Account strip and cards */
#root main:has([style*="#081820"]) [style*="#0b1b28"],
#root main:has([style*="#081820"]) [style*="rgba(7, 20, 29"] {
  background: #f0f6ff !important;
  border: 1px solid #c5dcff !important;
  color: #142b4d !important;
}

/* Account details */
#root main:has([style*="#081820"]) input,
#root main:has([style*="#081820"]) select,
#root main:has([style*="#081820"]) textarea {
  background: #ffffff !important;
  color: #142b4d !important;
  border: 1px solid #b8d5ff !important;
  border-radius: 10px !important;
  min-height: 44px;
}

#root main:has([style*="#081820"]) input::placeholder {
  color: #8296ad !important;
}

/* MT5 buttons */
#root main:has([style*="#081820"]) button {
  border-radius: 10px !important;
}

#root main:has([style*="#081820"]) button[type="submit"] {
  background: linear-gradient(110deg,#0877ee,#389cff) !important;
  color: #ffffff !important;
  border: 1px solid #0877ee !important;
  box-shadow: 0 6px 16px rgba(8,119,238,.16) !important;
}

/* =====================================================
   GAS FUEL SETTLEMENT
   ===================================================== */

#root .mt5-profit-history-page {
  background: #ffffff !important;
  color: #142b4d !important;
  padding: 24px !important;
}

/* All settlement panels */
#root .mt5-profit-history-page .mph-panel,
#root .mt5-profit-history-page .mph-stat {
  background: linear-gradient(145deg,#ffffff,#f0f6ff) !important;
  border: 1px solid #c5dcff !important;
  border-radius: 17px !important;
  box-shadow: 0 8px 25px rgba(35,100,180,.07) !important;
  color: #142b4d !important;
}

/* Settlement hero */
#root .mt5-profit-history-page .mph-hero {
  padding: 28px !important;
  background: linear-gradient(120deg,#ffffff,#e8f3ff) !important;
}

/* Settlement headings */
#root .mt5-profit-history-page .mph-title,
#root .mt5-profit-history-page .mph-card-title {
  color: #142b4d !important;
  font-weight: 850 !important;
}

#root .mt5-profit-history-page .mph-subtitle,
#root .mt5-profit-history-page .mph-card-text,
#root .mt5-profit-history-page .mph-secondary {
  color: #526987 !important;
}

#root .mt5-profit-history-page .mph-eyebrow,
#root .mt5-profit-history-page .mph-label {
  color: #0877ee !important;
  font-weight: 800 !important;
}

/* Settlement values */
#root .mt5-profit-history-page .mph-value {
  color: #142b4d !important;
  font-weight: 900 !important;
}

#root .mt5-profit-history-page .mph-value.fee {
  color: #e58a32 !important;
}

#root .mt5-profit-history-page .mph-value.net,
#root .mt5-profit-history-page .mph-value.positive {
  color: #079968 !important;
}

/* Source badge */
#root .mt5-profit-history-page .mph-source,
#root .mt5-profit-history-page .mph-count {
  background: #e5f1ff !important;
  color: #0877ee !important;
  border: 1px solid #b8d5ff !important;
  border-radius: 30px !important;
}

/* Search and filters */
#root .mt5-profit-history-page .mph-toolbar {
  display: grid !important;
  gap: 16px !important;
}

#root .mt5-profit-history-page .mph-input,
#root .mt5-profit-history-page .mph-select {
  background: #ffffff !important;
  color: #142b4d !important;
  border: 1px solid #b8d5ff !important;
  border-radius: 10px !important;
  min-height: 44px !important;
  width: 100% !important;
}

#root .mt5-profit-history-page .mph-field label {
  color: #294b72 !important;
  font-weight: 700 !important;
}

/* Refresh button */
#root .mt5-profit-history-page .mph-button {
  background: linear-gradient(110deg,#0877ee,#389cff) !important;
  color: #ffffff !important;
  border: 1px solid #0877ee !important;
  border-radius: 10px !important;
  font-weight: 800 !important;
}

/* Table */
#root .mt5-profit-history-page .mph-table-card {
  overflow: hidden !important;
}

#root .mt5-profit-history-page .mph-table-card table {
  width: 100% !important;
  border-collapse: separate !important;
  border-spacing: 0 !important;
  color: #142b4d !important;
}

#root .mt5-profit-history-page .mph-table-card th {
  background: #e5f1ff !important;
  color: #1454a0 !important;
  font-weight: 800 !important;
}

#root .mt5-profit-history-page .mph-table-card td {
  background: #ffffff !important;
  color: #294b72 !important;
  border-bottom: 1px solid #e0ebf8 !important;
}

#root .mt5-profit-history-page .mph-alert {
  background: #fff5f5 !important;
  color: #b42332 !important;
  border: 1px solid #ffd0d5 !important;
}

#root .mt5-profit-history-page .mph-empty {
  background: #f3f8ff !important;
  color: #526987 !important;
  border-radius: 14px !important;
}

/* MOBILE AND TABLET */
@media(max-width:768px) {
  #root .mt5-profit-history-page {
    padding: 13px !important;
  }

  #root .mt5-profit-history-page .mph-hero {
    padding: 20px 16px !important;
  }

  #root .mt5-profit-history-page .mph-stats {
    grid-template-columns: repeat(2,minmax(0,1fr)) !important;
    gap: 10px !important;
  }

  #root .mt5-profit-history-page .mph-stat {
    padding: 14px !important;
    min-width: 0 !important;
  }

  #root .mt5-profit-history-page .mph-value {
    font-size: 21px !important;
    overflow-wrap: anywhere !important;
  }

  #root .mt5-profit-history-page .mph-toolbar {
    grid-template-columns: 1fr !important;
  }

  #root .mt5-profit-history-page .mph-table-card {
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch !important;
  }

  #root .mt5-profit-history-page .mph-table-card table {
    min-width: 680px !important;
  }

  #root main:has([style*="#081820"]) {
    padding-left: 0 !important;
    padding-right: 0 !important;
  }
}

@media(max-width:380px) {
  #root .mt5-profit-history-page .mph-stats {
    grid-template-columns: 1fr !important;
  }
}

/* END ONNTRADE MT5 COMPLETE THEME */

/* =====================================================
   ONNTRADE MT5 - ROOT LEVEL FINAL WHITE BLUE THEME
   MT5 COPY TRADING + GAS FUEL SETTLEMENT
   UI ONLY
   ===================================================== */

/* MT5 actual page root: styles$2.page */
#root [style*="max-width: 1500px"] {
  background: #ffffff !important;
  color: #142b4d !important;
}

/* Hero and all MT5 cards */
#root [style*="max-width: 1500px"] section {
  color: #142b4d !important;
  border-color: #b8d5ff !important;
}

#root [style*="max-width: 1500px"] section[style*="linear-gradient"],
#root [style*="max-width: 1500px"] section[style*="#0b1b28"],
#root [style*="max-width: 1500px"] section[style*="#081820"] {
  background: linear-gradient(145deg,#ffffff,#edf5ff) !important;
  border: 1px solid #b8d5ff !important;
  box-shadow: 0 8px 26px rgba(30,100,180,.09) !important;
}

/* MT5 text */
#root [style*="max-width: 1500px"] h1,
#root [style*="max-width: 1500px"] h2,
#root [style*="max-width: 1500px"] h3,
#root [style*="max-width: 1500px"] strong {
  color: #142b4d !important;
}

/* Descriptions and labels */
#root [style*="max-width: 1500px"] p,
#root [style*="max-width: 1500px"] label {
  color: #526987 !important;
}

/* Account strip and metric cards */
#root [style*="max-width: 1500px"] [style*="rgba(7, 20, 29"],
#root [style*="max-width: 1500px"] [style*="#0b1b28"] {
  background: #f0f6ff !important;
  border-color: #c5dcff !important;
}

/* Inputs */
#root [style*="max-width: 1500px"] input,
#root [style*="max-width: 1500px"] select,
#root [style*="max-width: 1500px"] textarea {
  background: #ffffff !important;
  color: #142b4d !important;
  border: 1px solid #b8d5ff !important;
  border-radius: 10px !important;
}

#root [style*="max-width: 1500px"] input::placeholder {
  color: #8296ad !important;
}

/* Buttons */
#root [style*="max-width: 1500px"] button {
  border-radius: 10px !important;
}

/* Gas Fuel Settlement */
#root .mt5-profit-history-page,
#root .mt5-profit-history-page * {
  color: #142b4d;
}

#root .mt5-profit-history-page {
  background: #ffffff !important;
}

#root .mt5-profit-history-page .mph-panel,
#root .mt5-profit-history-page .mph-stat {
  background: linear-gradient(145deg,#ffffff,#edf5ff) !important;
  border: 1px solid #b8d5ff !important;
  box-shadow: 0 8px 25px rgba(30,100,180,.08) !important;
}

#root .mt5-profit-history-page .mph-title,
#root .mt5-profit-history-page .mph-card-title,
#root .mt5-profit-history-page .mph-value {
  color: #142b4d !important;
}

#root .mt5-profit-history-page .mph-label,
#root .mt5-profit-history-page .mph-eyebrow {
  color: #0877ee !important;
}

#root .mt5-profit-history-page .mph-secondary,
#root .mt5-profit-history-page .mph-subtitle {
  color: #526987 !important;
}

#root .mt5-profit-history-page .mph-value.positive,
#root .mt5-profit-history-page .mph-value.net {
  color: #079968 !important;
}

#root .mt5-profit-history-page .mph-value.fee {
  color: #e58a32 !important;
}

/* Mobile */
@media(max-width:768px) {
  #root [style*="max-width: 1500px"] {
    padding: 14px !important;
  }

  #root .mt5-profit-history-page {
    padding: 12px !important;
  }

  #root .mt5-profit-history-page .mph-stats {
    grid-template-columns: repeat(2,minmax(0,1fr)) !important;
  }
}

/* END FINAL MT5 ROOT THEME */

/* ONNTRADE — ALL PAGES SKY BLUE DASHBOARD THEME */
:root {
  --onn-blue: #1677e8;
  --onn-sky: #eaf4ff;
  --onn-sky-soft: #f3f8ff;
  --onn-border: #b8d6ff;
  --onn-text: #142b4d;
  --onn-muted: #526987;
}

/* Main content cards and panels */
#root main [class*="card" i],
#root main [class*="panel" i],
#root main [class*="widget" i],
#root main [class*="section-box" i] {
  background: var(--onn-sky) !important;
  border-color: var(--onn-border) !important;
  color: var(--onn-text) !important;
}

/* Text visibility inside content cards */
#root main [class*="card" i] *,
#root main [class*="panel" i] *,
#root main [class*="widget" i] * {
  color: inherit;
}

/* Form fields and dropdowns */
#root main input,
#root main select,
#root main textarea {
  background: #f4f9ff !important;
  color: var(--onn-text) !important;
  border: 1px solid var(--onn-border) !important;
}

#root main input::placeholder,
#root main textarea::placeholder {
  color: #7187a5 !important;
  opacity: 1 !important;
}

#root main select option {
  background: #eaf4ff !important;
  color: #142b4d !important;
}

/* Labels, headings and normal content */
#root main label,
#root main h1,
#root main h2,
#root main h3,
#root main h4,
#root main p,
#root main th,
#root main td {
  color: var(--onn-text);
}

/* Table surfaces */
#root main table,
#root main thead,
#root main tbody tr {
  background: var(--onn-sky-soft);
  color: var(--onn-text);
}

#root main th,
#root main td {
  border-color: var(--onn-border) !important;
}

/* Blue action buttons */
#root main button:not([class*="danger" i]):not([class*="reject" i]) {
  border-color: var(--onn-border);
}

/* Keep status indicators readable */
#root main [class*="success" i],
#root main [class*="approved" i],
#root main [class*="positive" i] {
  color: #087b59;
}

#root main [class*="danger" i],
#root main [class*="rejected" i],
#root main [class*="negative" i] {
  color: #c33b50;
}

/* ONNTRADE GLOBAL UNIFIED DIVIDER SYSTEM */
:root {
  --ot-unified-line: #b8d5ff;
  --ot-unified-line-width: 1px;
}

/* Logo bottom, sidebar and top header */
#root .sidebar-brand {
  border-bottom: var(--ot-unified-line-width) solid var(--ot-unified-line) !important;
}
#root .sidebar {
  border-right: var(--ot-unified-line-width) solid var(--ot-unified-line) !important;
}
#root .topbar {
  border-top: var(--ot-unified-line-width) solid var(--ot-unified-line) !important;
  border-bottom: var(--ot-unified-line-width) solid var(--ot-unified-line) !important;
}

/* Common page and section separators */
#root .panel-header,
#root .section-header,
#root .mw-section-header,
#root .zx-section-header {
  border-bottom: var(--ot-unified-line-width) solid var(--ot-unified-line) !important;
}
#root hr {
  border: 0 !important;
  border-top: var(--ot-unified-line-width) solid var(--ot-unified-line) !important;
}
