/* FundYourDreams dashboard restyle (Dashboard view).
   Design system: tokens.json / tokens.css of the FYD system (welcome + login pages).
   Loaded AFTER the inline styles of index.html. Pure overrides, scoped to
   body:not(.light-theme) #dashboardView, so the light theme is untouched.
   No id, class or data attribute used by the JS is changed. */

:root {
  --bg: #1a1a24;
  --panel: rgba(34,34,46,0.738);
  --panel-2: rgba(42,42,56,0.9);
  --surface-modal: #22222e;
  --nav-bg: rgba(26,26,36,0.88);
  --field-fill: rgba(255,255,255,0.04);
  --line: rgba(255,255,255,0.14);
  --line-strong: rgba(255,255,255,0.26);
  --line-faint: rgba(255,255,255,0.08);
  --text: #f2f2f5;
  --text-dim: #a4a4b0;
  --text-faint: #8a8a98;
  --gold: #ffd700;
  --gold-2: #ffed4e;
  --gold-3: #ffa500;
  --gold-soft: rgba(255,215,0,0.14);
  --on-gold: #14120a;
  --pos: #c0f5d9;
  --neg: #ff7b7b;
  --contour-line: rgba(255,215,0,0.75);
  --shadow-contour: 0 0 6px rgba(255,215,0,0.45), 0 0 16px rgba(255,215,0,0.14), inset 0 0 12px rgba(255,215,0,0.07);
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-pill: 50px;
  --font-mono: "Share Tech Mono", ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  --font-title: "Audiowide", system-ui, sans-serif;
}

body:not(.light-theme) { background: var(--bg); color-scheme: dark; }

/* ---- the old variables, re-pointed to the design tokens (every old rule follows) ---- */
body:not(.light-theme) #dashboardView {
  --bg-primary: #1a1a24;
  --bg-secondary: #22222e;
  --bg-card: rgba(34,34,46,0.738);
  --bg-card-hover: rgba(42,42,56,0.9);
  --border-color: rgba(255,255,255,0.14);
  --text-primary: #f2f2f5;
  --text-secondary: #a4a4b0;
  --text-muted: #8a8a98;
  --accent-purple: #ffd700;
  --accent-purple-light: #ffed4e;
  --accent-purple-dark: #ffa500;
  --primary: #ffd700;
  --positive: #c0f5d9;
  --positive-bg: rgba(192,245,217,0.12);
  --negative: #ff7b7b;
  --negative-bg: rgba(255,123,123,0.12);
  --error: #ff7b7b;
  --error-bg: rgba(255,123,123,0.12);
  --shadow-sm: none;
  --shadow-md: none;
  --shadow-lg: none;
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  color: var(--text);
}
body:not(.light-theme) #dashboardView button,
body:not(.light-theme) #dashboardView input,
body:not(.light-theme) #dashboardView select,
body:not(.light-theme) #dashboardView textarea { font-family: inherit; }
body:not(.light-theme) #dashboardView :focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }

/* ---- signature: the gold contour of light, on every card ---- */
body:not(.light-theme) #dashboardView .bot-status-card,
body:not(.light-theme) #dashboardView .bot-status-card-mobile,
body:not(.light-theme) #dashboardView .admin-panel,
body:not(.light-theme) #dashboardView .kpi-card,
body:not(.light-theme) #dashboardView .kpi-card-premium,
body:not(.light-theme) #dashboardView .chart-card,
body:not(.light-theme) #dashboardView .goal-card,
body:not(.light-theme) #dashboardView .liquidity-card,
body:not(.light-theme) #dashboardView .activity-card,
body:not(.light-theme) #dashboardView #pendingRequestsBanner,
body:not(.light-theme) #dashboardView [style*="--card-bg"] {
  background: var(--panel) !important;
  border: 1px solid var(--contour-line) !important;
  border-radius: var(--radius-lg) !important;
  box-shadow: var(--shadow-contour) !important;
}
body:not(.light-theme) #dashboardView .kpi-card:hover,
body:not(.light-theme) #dashboardView .kpi-card-premium:hover { transform: none; }
body:not(.light-theme) #dashboardView .kpi-card-premium::before,
body:not(.light-theme) #dashboardView .bot-status-card::before { display: none; }

/* ---- titles: Audiowide, uppercase ---- */
body:not(.light-theme) #dashboardView .page-title,
body:not(.light-theme) #dashboardView .chart-title,
body:not(.light-theme) #dashboardView .activity-title,
body:not(.light-theme) #dashboardView .goal-title,
body:not(.light-theme) #dashboardView .liquidity-title,
body:not(.light-theme) #dashboardView .admin-panel-title,
body:not(.light-theme) #dashboardView .dashboard h2,
body:not(.light-theme) #dashboardView .dashboard h3 {
  font-family: var(--font-title) !important;
  font-weight: 400 !important;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}
body:not(.light-theme) #dashboardView .page-title { font-size: 24px; line-height: 1.1; }

/* ---- sidebar ---- */
body:not(.light-theme) #dashboardView .sidebar {
  background: var(--nav-bg);
  border-right: 1px solid var(--line);
  backdrop-filter: blur(6px);
}
body:not(.light-theme) #dashboardView .logo img {
  border-radius: var(--radius-lg);
  border: 1px solid var(--contour-line);
  box-shadow: var(--shadow-contour);
}
body:not(.light-theme) #dashboardView .nav-item,
body:not(.light-theme) #dashboardView .logout-btn {
  min-height: 44px;
  padding: 0 12px;
  border: 1px solid transparent;
  border-radius: var(--radius-md);
  color: var(--text-dim);
  font-size: 13px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
body:not(.light-theme) #dashboardView .logout-btn { border-color: var(--line-strong); background: var(--panel-2); color: var(--text); width: 100%; }
body:not(.light-theme) #dashboardView .nav-item:hover,
body:not(.light-theme) #dashboardView .logout-btn:hover { background: transparent; border-color: var(--gold); color: var(--text); }
body:not(.light-theme) #dashboardView .logout-btn:hover { background: var(--panel-2); }
body:not(.light-theme) #dashboardView .nav-item.active { background: var(--gold); border-color: var(--gold); color: var(--on-gold); font-weight: 500; }
body:not(.light-theme) #dashboardView .bot-status-icon { background: var(--gold); border-radius: var(--radius-md); }
body:not(.light-theme) #dashboardView .bot-status-icon svg { stroke: var(--on-gold); }
body:not(.light-theme) #dashboardView .bot-status-label { font-weight: 400; letter-spacing: 0.08em; text-transform: uppercase; font-size: 12px; }
body:not(.light-theme) #dashboardView .bot-gauge-bg { stroke: var(--line-faint); }
body:not(.light-theme) #dashboardView .bot-gauge-fill { stroke: url(#gaugeGradientGold); }
body:not(.light-theme) #dashboardView #botStatusCardMobile .bot-gauge-fill { stroke: url(#gaugeGradientGoldMobile); }
body:not(.light-theme) #dashboardView .bot-gauge-percent { font-family: var(--font-title); font-weight: 400; color: var(--gold); }
body:not(.light-theme) #dashboardView .bot-gauge-label,
body:not(.light-theme) #dashboardView .bot-info-label { color: var(--text-faint); letter-spacing: 0.1em; }
body:not(.light-theme) #dashboardView .bot-info-value { font-weight: 500; }

/* ---- header ---- */
body:not(.light-theme) #dashboardView .header {
  background: var(--nav-bg);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(6px);
  min-height: 64px;
  padding-top: 8px;
  padding-bottom: 8px;
}
body:not(.light-theme) #dashboardView .strategy-badge,
body:not(.light-theme) #dashboardView .view-indicator,
body:not(.light-theme) #dashboardView .view-indicator.global {
  background: transparent;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-md);
  box-shadow: none;
  color: var(--gold);
  font-size: 12px;
  font-weight: 400;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
body:not(.light-theme) #dashboardView .strategy-badge svg { color: var(--gold); stroke: var(--gold); }
body:not(.light-theme) #dashboardView .role-badge,
body:not(.light-theme) #dashboardView .role-badge.admin,
body:not(.light-theme) #dashboardView .role-badge.client {
  background: transparent;
  border: 1px solid var(--gold);
  border-radius: var(--radius-md);
  color: var(--gold);
  font-weight: 400;
  letter-spacing: 0.08em;
}
body:not(.light-theme) #dashboardView .lang-selector { background: none; border: 0; padding: 0; gap: 6px; }
body:not(.light-theme) #dashboardView .lang-btn,
body:not(.light-theme) #dashboardView .strategy-toggle,
body:not(.light-theme) #dashboardView .goal-btn,
body:not(.light-theme) #dashboardView .chart-tab {
  min-height: 44px;
  padding: 0 12px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-md);
  background: var(--panel-2);
  color: var(--text);
  font-size: 13px;
  font-weight: 400;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
body:not(.light-theme) #dashboardView .strategy-toggle,
body:not(.light-theme) #dashboardView .goal-btn { padding: 0 16px; }
body:not(.light-theme) #dashboardView .lang-btn:hover,
body:not(.light-theme) #dashboardView .strategy-toggle:hover,
body:not(.light-theme) #dashboardView .goal-btn:hover,
body:not(.light-theme) #dashboardView .chart-tab:hover { background: var(--panel-2); border-color: var(--gold); color: var(--text); }
body:not(.light-theme) #dashboardView .lang-btn.active,
body:not(.light-theme) #dashboardView .strategy-toggle.active,
body:not(.light-theme) #dashboardView .chart-tab.active {
  background: var(--gold);
  border-color: var(--gold);
  color: var(--on-gold);
  font-weight: 500;
}
body:not(.light-theme) #dashboardView .user-profile { background: var(--panel-2); border: 1px solid var(--line-strong); border-radius: var(--radius-md); }
body:not(.light-theme) #dashboardView .user-avatar { background: var(--gold); color: var(--on-gold); border-radius: 50%; font-weight: 500; }
body:not(.light-theme) #dashboardView .user-name { font-weight: 400; }
body:not(.light-theme) #dashboardView .user-role { color: var(--text-faint); letter-spacing: 0.06em; text-transform: uppercase; font-size: 11px; }

/* ---- admin controls ---- */
body:not(.light-theme) #dashboardView .admin-panel-title { font-size: 16px; }
body:not(.light-theme) #dashboardView .admin-panel-title svg { color: var(--gold); }
body:not(.light-theme) #dashboardView .client-selector label { font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-faint); }
body:not(.light-theme) #dashboardView .client-selector select,
body:not(.light-theme) #dashboardView .invite-controls input {
  min-height: 46px;
  padding: 0 12px;
  background: var(--field-fill);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-md);
  color: var(--text);
  font-size: 15px;
  color-scheme: dark;
}

/* ---- pending requests banner (inline styles in the markup, hence !important) ---- */
body:not(.light-theme) #dashboardView #pendingRequestsBanner strong { color: var(--gold) !important; font-weight: 400; letter-spacing: 0.08em; text-transform: uppercase; font-size: 13px; }
body:not(.light-theme) #dashboardView #pendingRequestsBanner button {
  min-height: 44px;
  background: var(--panel-2) !important;
  border: 1px solid var(--line-strong) !important;
  border-radius: var(--radius-md) !important;
  color: var(--text) !important;
  padding: 0 14px !important;
  font-size: 13px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
body:not(.light-theme) #dashboardView #pendingRequestsBanner button:hover { border-color: var(--gold) !important; }
body:not(.light-theme) #dashboardView #pendingRequestsBannerList > div { border-top-color: var(--line) !important; }

/* ---- KPI cards ---- */
body:not(.light-theme) #dashboardView .kpi-card .kpi-label,
body:not(.light-theme) #dashboardView .kpi-card-premium .kpi-label {
  font-size: 11px;
  font-weight: 400;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-faint);
}
body:not(.light-theme) #dashboardView .kpi-card .kpi-value,
body:not(.light-theme) #dashboardView .kpi-card-premium .kpi-value {
  font-weight: 500;
  letter-spacing: 0;
  color: var(--gold);
}
body:not(.light-theme) #dashboardView .kpi-card .kpi-value.positive,
body:not(.light-theme) #dashboardView .kpi-card-premium .kpi-value.positive { color: var(--pos); }
body:not(.light-theme) #dashboardView .kpi-card .kpi-value.negative,
body:not(.light-theme) #dashboardView .kpi-card-premium .kpi-value.negative { color: var(--neg); }
body:not(.light-theme) #dashboardView .kpi-card .kpi-subtitle,
body:not(.light-theme) #dashboardView .kpi-card-premium .kpi-subtitle { color: var(--text-dim); }
body:not(.light-theme) #dashboardView .kpi-icon,
body:not(.light-theme) #dashboardView .kpi-icon.purple,
body:not(.light-theme) #dashboardView .kpi-icon.green,
body:not(.light-theme) #dashboardView .kpi-icon.orange {
  background: var(--field-fill);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  color: var(--gold);
}
body:not(.light-theme) #dashboardView .kpi-icon svg { color: var(--gold); stroke: var(--gold); }

/* ---- chart ---- */
body:not(.light-theme) #dashboardView .chart-tabs { background: none; padding: 0; gap: 6px; flex-wrap: wrap; }
body:not(.light-theme) #dashboardView .chart-line { stroke: var(--gold); stroke-width: 2; }
body:not(.light-theme) #dashboardView #chartGradient stop { stop-color: #ffd700 !important; }
body:not(.light-theme) #dashboardView .chart-label { font-size: 10px; color: var(--text-faint); letter-spacing: 0.04em; }
body:not(.light-theme) #dashboardView .chart-tooltip { background: var(--surface-modal); border: 1px solid var(--line-strong); border-radius: var(--radius-md); box-shadow: none; }
body:not(.light-theme) #dashboardView .tooltip-value { color: var(--gold); font-weight: 500; text-shadow: none; }
body:not(.light-theme) #dashboardView .tooltip-date { color: var(--text-faint); }

/* ---- goal and drawdown ---- */
body:not(.light-theme) #dashboardView .goal-current { font-family: var(--font-title); font-weight: 400; color: var(--gold); }
body:not(.light-theme) #dashboardView .goal-bar,
body:not(.light-theme) #dashboardView .liquidity-bar { background: var(--line-faint); border-radius: var(--radius-pill); }
body:not(.light-theme) #dashboardView .goal-fill { background: linear-gradient(90deg, var(--gold-3), var(--gold-2)); border-radius: var(--radius-pill); }
body:not(.light-theme) #dashboardView .goal-percentage { color: var(--gold); font-weight: 500; }
body:not(.light-theme) #dashboardView .liquidity-fill { background: linear-gradient(90deg, var(--gold-3), var(--gold-2)); border-radius: var(--radius-pill); }
body:not(.light-theme) #dashboardView .liquidity-percentage,
body:not(.light-theme) #dashboardView .liquidity-value { color: var(--pos); font-weight: 500; }

/* ---- tables ---- */
body:not(.light-theme) #dashboardView .activity-header { border-bottom: 1px solid var(--line); }
body:not(.light-theme) #dashboardView .activity-table th {
  background: none;
  border-bottom: 1px solid var(--line-strong);
  color: var(--text-faint);
  font-size: 11px;
  font-weight: 400;
  letter-spacing: 0.1em;
}
body:not(.light-theme) #dashboardView .activity-table td { border-bottom: 1px solid var(--line); }
body:not(.light-theme) #dashboardView .activity-table tr:hover td { background: var(--field-fill); }
body:not(.light-theme) #dashboardView .capital-amount { color: var(--gold); font-weight: 500; }
body:not(.light-theme) #dashboardView .status-badge { border-radius: var(--radius-md); font-weight: 400; letter-spacing: 0.06em; }

/* ---- asset performance (inline-styled) ---- */
body:not(.light-theme) #dashboardView #assetStatsDisplay .asset-stat > span:first-child { font-size: 11px !important; letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-faint) !important; }
body:not(.light-theme) #dashboardView #assetStatsDisplay .asset-stat > span:nth-child(2) { font-weight: 500 !important; }

/* ---- layout polish ---- */
body:not(.light-theme) #dashboardView .header-left { flex-wrap: wrap; gap: 12px; min-width: 0; }
body:not(.light-theme) #dashboardView .header-right { flex-wrap: wrap; gap: 12px; }
body:not(.light-theme) #dashboardView .strategy-badge { white-space: nowrap; }
/* the admin panel and the pending banner sit outside .dashboard: give them the same side gutter */
body:not(.light-theme) #dashboardView .admin-panel,
body:not(.light-theme) #dashboardView #pendingRequestsBanner { margin-left: 32px !important; margin-right: 32px !important; margin-top: 24px; }
@media (max-width: 768px) {
  body:not(.light-theme) #dashboardView .admin-panel,
  body:not(.light-theme) #dashboardView #pendingRequestsBanner { margin-left: 16px !important; margin-right: 16px !important; }
}

/* =====================================================================
   v2: unmistakably the welcome page (type, rain, corner ticks, top bar, logo)
   ===================================================================== */
#dashRain { position: fixed; inset: 0; width: 100%; height: 100%; z-index: 0; opacity: 0.30; pointer-events: none; }
body:not(.light-theme) #dashboardView { position: relative; z-index: 1; background: transparent; }
body:not(.light-theme) .main-content,
body:not(.light-theme) #dashboardView .main-content { background: transparent; }

/* ---- type: Share Tech Mono for ALL text, Audiowide for titles and KPI numbers ---- */
body:not(.light-theme) #dashboardView * { font-family: var(--font-mono) !important; }
body:not(.light-theme) #dashboardView .page-title,
body:not(.light-theme) #dashboardView .chart-title,
body:not(.light-theme) #dashboardView .activity-title,
body:not(.light-theme) #dashboardView .goal-title,
body:not(.light-theme) #dashboardView .liquidity-title,
body:not(.light-theme) #dashboardView .admin-panel-title,
body:not(.light-theme) #dashboardView .dashboard h1,
body:not(.light-theme) #dashboardView .dashboard h2,
body:not(.light-theme) #dashboardView .dashboard h3,
body:not(.light-theme) #dashboardView .kpi-card .kpi-value,
body:not(.light-theme) #dashboardView .kpi-card-premium .kpi-value,
body:not(.light-theme) #dashboardView .goal-current,
body:not(.light-theme) #dashboardView .bot-gauge-percent,
body:not(.light-theme) #dashboardView #assetStatsDisplay .asset-stat > span:nth-child(2),
body:not(.light-theme) #dashboardView .lv-t { font-family: var(--font-title) !important; font-weight: 400 !important; }
body:not(.light-theme) #dashboardView .kpi-card .kpi-value,
body:not(.light-theme) #dashboardView .kpi-card-premium .kpi-value { font-size: clamp(20px, 2.2vw, 28px); overflow-wrap: anywhere; line-height: 1.1; }
body:not(.light-theme) #dashboardView .dashboard h3 { font-size: 18px; }
body:not(.light-theme) #dashboardView th,
body:not(.light-theme) #dashboardView label,
body:not(.light-theme) #dashboardView .kpi-label,
body:not(.light-theme) #dashboardView .chart-label { text-transform: uppercase; letter-spacing: 0.1em; }
body:not(.light-theme) #dashboardView .chart-title,
body:not(.light-theme) #dashboardView .activity-title { font-size: 20px; text-transform: uppercase; }

/* ---- cards: gold contour + the corner ticks of the welcome .box ---- */
body:not(.light-theme) #dashboardView .bot-status-card,
body:not(.light-theme) #dashboardView .bot-status-card-mobile,
body:not(.light-theme) #dashboardView .admin-panel,
body:not(.light-theme) #dashboardView .kpi-card,
body:not(.light-theme) #dashboardView .kpi-card-premium,
body:not(.light-theme) #dashboardView .chart-card,
body:not(.light-theme) #dashboardView .goal-card,
body:not(.light-theme) #dashboardView .liquidity-card,
body:not(.light-theme) #dashboardView .activity-card,
body:not(.light-theme) #dashboardView #pendingRequestsBanner,
body:not(.light-theme) #dashboardView [style*="--card-bg"] {
  --t: var(--line-strong);
  background-color: var(--panel) !important;
  background-image: linear-gradient(var(--t), var(--t)), linear-gradient(var(--t), var(--t)), linear-gradient(var(--t), var(--t)), linear-gradient(var(--t), var(--t)), linear-gradient(var(--t), var(--t)), linear-gradient(var(--t), var(--t)), linear-gradient(var(--t), var(--t)), linear-gradient(var(--t), var(--t)) !important;
  background-repeat: no-repeat !important;
  background-size: 8px 1px, 1px 8px, 8px 1px, 1px 8px, 8px 1px, 1px 8px, 8px 1px, 1px 8px !important;
  background-position: 10px 10px, 10px 10px, calc(100% - 10px) 10px, calc(100% - 10px) 10px, 10px calc(100% - 10px), 10px calc(100% - 10px), calc(100% - 10px) calc(100% - 10px), calc(100% - 10px) calc(100% - 10px) !important;
}
body:not(.light-theme) #dashboardView .kpi-card, body:not(.light-theme) #dashboardView .kpi-card-premium { border-radius: var(--radius-lg) !important; }
/* the pending banner keeps its amber warning edge, as a contour */
body:not(.light-theme) #dashboardView #pendingRequestsBanner { border-color: rgba(251,191,36,0.75) !important; box-shadow: 0 0 6px rgba(251,191,36,0.4), 0 0 16px rgba(251,191,36,0.12), inset 0 0 12px rgba(251,191,36,0.06) !important; }

/* ---- sidebar logo: removed from view (node kept, storage-images.js still queries it) ---- */
body:not(.light-theme) #dashboardView .sidebar .logo { display: none !important; }

/* ---- hero card logo: the Audiowide reference variant (Word Font Compare) at 75%: 300px card.
   Everything inside is in cqw of the card (1cqw = 1% of its inner width = 2.98px at 300px), so the proportions hold when it shrinks. ---- */
body:not(.light-theme) #dashboardView .hero-logo-card {
  flex: 0 0 auto; width: min(300px, 100%); margin-inline: auto; container-type: inline-size; background: #fff; border-radius: 12px; padding: 0; text-align: center;
  --navy: #02244d; --gold-logo: #f4af07; --big: 14.6cqw;
}
body:not(.light-theme) #dashboardView .hero-logo-card img { content: url("welcome-logo-art.png"); display: block; width: 71.76cqw; max-width: none; height: auto; margin: 5cqw auto 1.5cqw; filter: none; border-radius: 0; }
body:not(.light-theme) #dashboardView .hero-logo-card .lv-t { font-family: var(--font-title) !important; font-weight: 400; color: var(--navy); text-transform: uppercase; line-height: 1; -webkit-text-stroke: 0.6cqw var(--navy); letter-spacing: 0; }
body:not(.light-theme) #dashboardView .hero-logo-card .lv-fund, body:not(.light-theme) #dashboardView .hero-logo-card .lv-dreams { display: block; font-size: var(--big); line-height: .82; }
body:not(.light-theme) #dashboardView .hero-logo-card .lv-dreams { margin-bottom: 6cqw; }
body:not(.light-theme) #dashboardView .hero-logo-card .lv-your { display: flex; align-items: center; gap: 2.5cqw; margin: 0 5.52cqw; width: auto; line-height: 1; color: var(--gold-logo); -webkit-text-stroke-color: var(--gold-logo); font-size: calc(var(--big) * .42); }
body:not(.light-theme) #dashboardView .hero-logo-card .lv-your::before, body:not(.light-theme) #dashboardView .hero-logo-card .lv-your::after { content: ""; flex: 1; height: 1cqw; border-radius: 2px; background: var(--gold-logo); }
body:not(.light-theme) #dashboardView .lv-t { font-weight: 400; color: var(--navy); text-transform: uppercase; -webkit-text-stroke: 1.6px var(--navy); letter-spacing: 0; }
body:not(.light-theme) #dashboardView .lv-fund, body:not(.light-theme) #dashboardView .lv-dreams { display: block; font-size: var(--big); line-height: .82; }
body:not(.light-theme) #dashboardView .lv-your { display: flex; align-items: center; gap: .4em; margin: 0 auto; width: min(100%, calc(var(--big) * 6)); line-height: 1; font-size: calc(var(--big) * .42); color: var(--gold-logo); -webkit-text-stroke: 1px var(--gold-logo); }
body:not(.light-theme) #dashboardView .lv-your::before, body:not(.light-theme) #dashboardView .lv-your::after { content: ""; flex: 1; height: calc(var(--big) * .065); border-radius: 2px; background: var(--gold-logo); }

/* ---- top bar: title left, profile right, 1px line below ---- */
body:not(.light-theme) #dashboardView .header {
  display: flex; align-items: center; gap: 12px; min-height: 64px; padding: 8px 32px;
  background: var(--nav-bg); border-bottom: 1px solid var(--line); backdrop-filter: blur(6px);
}
body:not(.light-theme) #dashboardView .header-right { display: contents; }
body:not(.light-theme) #dashboardView .header-left { order: 0; flex: 1; }
body:not(.light-theme) #dashboardView .user-profile { order: 2; margin-left: auto; min-height: 44px; padding: 0 14px 0 6px; }
body:not(.light-theme) #dashboardView .page-title { font-size: 20px; }
body:not(.light-theme) #dashboardView .user-avatar { width: 32px; height: 32px; font-size: 12px; }
body:not(.light-theme) #dashboardView .lang-btn { min-height: 44px; min-width: 44px; padding: 0 12px; }

/* ---- badges and pills: mono caps, 1px line ---- */
body:not(.light-theme) #dashboardView .role-badge,
body:not(.light-theme) #dashboardView .role-badge.admin,
body:not(.light-theme) #dashboardView .role-badge.client,
body:not(.light-theme) #dashboardView .strategy-badge,
body:not(.light-theme) #dashboardView .status-badge,
body:not(.light-theme) #dashboardView .view-indicator {
  text-transform: uppercase; letter-spacing: 0.08em; font-size: 12px; border-radius: var(--radius-md); background: transparent; box-shadow: none;
}
body:not(.light-theme) #dashboardView .status-badge { border: 1px solid var(--line-strong); padding: 4px 10px; }

/* ---- sidebar: mono pills, gold active ---- */
body:not(.light-theme) #dashboardView .nav-item { gap: 12px; }
body:not(.light-theme) #dashboardView .nav-item.active svg { stroke: var(--on-gold); }
body:not(.light-theme) #dashboardView .bot-status-card, body:not(.light-theme) #dashboardView .bot-status-card-mobile { padding: 14px; }
/* ---- mobile cards (Hugo 2026-10-19): goal + bots titles = the Performance title; Modifier inside its card; bots row on one line; drawdown buttons + note above the title and % ---- */
@media (max-width: 768px) {
  body:not(.light-theme) #dashboardView .dashboard h3.goal-title,
  body:not(.light-theme) #dashboardView .bot-status-card-mobile .bot-status-label { font-family: var(--font-title) !important; font-size: 20px; font-weight: 400; letter-spacing: 0.02em; text-transform: uppercase; }
  body:not(.light-theme) #dashboardView .goal-header { gap: 12px; padding-right: 8px; }
  body:not(.light-theme) #dashboardView .bot-status-card-mobile .bot-status-header { flex-wrap: nowrap; white-space: nowrap; gap: 8px; }
  body:not(.light-theme) #dashboardView .liquidity-card { display: flex; flex-direction: column; }
  body:not(.light-theme) #dashboardView .liquidity-card .liquidity-info { order: -1; }
  body:not(.light-theme) #dashboardView .liquidity-card .liquidity-title { margin: 16px 0 0; }
}
@media (max-width: 768px) {
  body:not(.light-theme) #dashboardView .header { padding: 8px 16px; flex-wrap: wrap; }
  body:not(.light-theme) #dashboardView .header-left { flex-basis: 100%; order: 1; }
}

/* ---- hero card: the same dark panel as the KPI rectangles, no blue tint ---- */
body:not(.light-theme) #dashboardView .guest-hero-section {
  --t: var(--line-strong);
  background-color: var(--panel) !important;
  background-image: linear-gradient(var(--t), var(--t)), linear-gradient(var(--t), var(--t)), linear-gradient(var(--t), var(--t)), linear-gradient(var(--t), var(--t)), linear-gradient(var(--t), var(--t)), linear-gradient(var(--t), var(--t)), linear-gradient(var(--t), var(--t)), linear-gradient(var(--t), var(--t)) !important;
  background-repeat: no-repeat !important;
  background-size: 8px 1px, 1px 8px, 8px 1px, 1px 8px, 8px 1px, 1px 8px, 8px 1px, 1px 8px !important;
  background-position: 10px 10px, 10px 10px, calc(100% - 10px) 10px, calc(100% - 10px) 10px, 10px calc(100% - 10px), 10px calc(100% - 10px), calc(100% - 10px) calc(100% - 10px), calc(100% - 10px) calc(100% - 10px) !important;
  border: 1px solid var(--contour-line) !important;
  border-radius: var(--radius-lg) !important;
  box-shadow: var(--shadow-contour) !important;
}

/* ---- hero text block: pitch title, welcome "Trade" + rotating word box, badge, tags ---- */
body:not(.light-theme) #dashboardView .hero-word-box { display: block; width: 100%; container-type: inline-size; position: relative; overflow: hidden; padding: 24px 8px; text-align: center; border: 1px solid var(--line); border-radius: 12px; background-color: rgba(255,255,255,0.03); }
body:not(.light-theme) #dashboardView .hero-word-box .label { display: block; margin-bottom: 6px; font-size: 11px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--text-faint); }
/* welcome: 56px / 42px / 61.6px in a 704px box = 7.95cqw / 5.97cqw / 8.75cqw of the box */
body:not(.light-theme) #dashboardView .hero-word-box .hero-word { font-family: "Orbitron", var(--font-title) !important; font-size: 7.95cqw; font-weight: 700 !important; letter-spacing: 0.01em; color: var(--gold); text-transform: uppercase; line-height: 1.1; white-space: nowrap; display: flex; align-items: center; justify-content: center; height: 8.75cqw; transition: opacity .35s ease, transform .35s ease; }
body:not(.light-theme) #dashboardView .hero-word-box .hero-word.long { font-size: 5.97cqw; }
body:not(.light-theme) #dashboardView .hero-word-box .hero-word.out { opacity: 0; transform: translateY(-14px); }
body:not(.light-theme) #dashboardView .hero-word-box .hero-word.in { opacity: 0; transform: translateY(14px); transition: none; }
@media (prefers-reduced-motion: reduce) { body:not(.light-theme) #dashboardView .hero-word-box .hero-word, body:not(.light-theme) #dashboardView .hero-word-box .hero-word.out, body:not(.light-theme) #dashboardView .hero-word-box .hero-word.in { transition: none; } }
/* pitch: last line of the whole hero card, full width, one line (welcome .pitch, scaled by the card width) */
body:not(.light-theme) #dashboardView .guest-hero-section { flex-wrap: wrap !important; container-type: inline-size; }
body:not(.light-theme) #dashboardView .hero-pitch { flex: 0 0 100%; margin: 0; padding: 4px 0 0; text-align: center; font-size: clamp(11px, 1.95vw, 25px); font-weight: 300; text-transform: uppercase; letter-spacing: 0.03em; line-height: 1.6; color: var(--text); }
body:not(.light-theme) #dashboardView .guest-hero-title,
body:not(.light-theme) #dashboardView .guest-hero-title > span { font-family: var(--font-title) !important; }
body:not(.light-theme) #dashboardView .guest-hero-title { font-size: clamp(11px, calc((100cqw - 34px) / 19.9), 52px); white-space: nowrap; font-weight: 400; text-transform: uppercase; color: #fff; line-height: 1.1; letter-spacing: 0; }
body:not(.light-theme) #dashboardView .guest-hero-section .guest-hero-titles { flex: 1 1 0; min-width: 0; }
body:not(.light-theme) #dashboardView .guest-hero-badges { justify-content: center; }
body:not(.light-theme) #dashboardView .guest-hero-section .guest-hero-titles { container-type: inline-size; }
body:not(.light-theme) #dashboardView .guest-hero-section { gap: 20px !important; padding-inline: 20px !important; }
body:not(.light-theme) #dashboardView .guest-hero-title { display: flex; align-items: center; gap: 8px; }
body:not(.light-theme) #dashboardView .guest-hero-title .hero-icon svg { width: 24px; height: 24px; }
body:not(.light-theme) #dashboardView .guest-hero-badges { align-self: center; }
/* hero "Powered by AI" badge: the base markup hard-codes a green two-tone
   gradient — Hugo wants one solid gold pill (var(--gold), follows the
   theme: gold / #2E5BFF / #A30000), white text, no gradient. The title sun
   next to "NEW GENERATION TRADING BOTS" keeps the theme color. */
body:not(.light-theme) #dashboardView .hero-badge {
  background: var(--gold);
  color: var(--on-gold);
  box-shadow: none;
  text-transform: uppercase; /* POWERED BY AI / PILOTÉ PAR IA, both languages (Hugo 2026-10-19) */
}
/* FR hero title is wider than the card (its font size is calibrated on the EN text): let it
   wrap instead of running past the card edge, sun icon included. EN still fits on one line. */
body:not(.light-theme) #dashboardView .guest-hero-title { white-space: normal; }
body:not(.light-theme) #dashboardView .guest-hero-title > span:last-child { min-width: 0; }
@media (max-width: 768px) { body:not(.light-theme) #dashboardView .guest-hero-title { justify-content: center; text-align: center; } }
/* Phone hero title (Hugo 2026-10-19): sun above, the title on exactly two lines and as big as the card allows.
   cqw = width of .guest-hero-titles. EN longest line "NEW GENERATION" ~10.1em, FR "NOUVELLE GÉNÉRATION" ~13.7em. */
@media (max-width: 768px) {
  body:not(.light-theme) #dashboardView .guest-hero-title { flex-direction: column; gap: 6px; text-wrap: balance; }
  html[lang="en"] body:not(.light-theme) #dashboardView .guest-hero-title { font-size: 9cqw; }
  html[lang="fr"] body:not(.light-theme) #dashboardView .guest-hero-title { font-size: 6.8cqw; }
}
body:not(.light-theme) #dashboardView .guest-hero-title .hero-icon svg { color: var(--gold); }
body:not(.light-theme) #dashboardView .guest-hero-section .guest-hero-titles { width: 100%; }
body:not(.light-theme) #dashboardView .hero-pitch { width: 100%; box-sizing: border-box; }
@media (max-width: 768px) { body:not(.light-theme) #dashboardView .hero-pitch { flex: 0 0 auto; } }
/* v9: pitch is its own line under the hero card, on the page background (no box) */
body:not(.light-theme) #dashboardView .guest-hero-section { margin-bottom: 16px !important; }
body:not(.light-theme) #dashboardView > .dashboard > .hero-pitch, body:not(.light-theme) #dashboardView .hero-pitch { grid-column: 1 / -1; margin: 0 0 48px; padding: 0; background: none; border: 0; box-shadow: none; }
body:not(.light-theme) #dashboardView .hero-pitch { text-align: center; font-size: clamp(11px, 1.95vw, 25px); font-weight: 300; text-transform: uppercase; letter-spacing: 0.03em; line-height: 1.6; color: var(--text); }
/* phone: pitch bigger, exactly two balanced lines (Hugo, 2026-10-18); the typewriter overlay inherits the same font and box */
@media (max-width: 768px) { body:not(.light-theme) #dashboardView .hero-pitch { font-size: clamp(15px, 4.9vw, 20px); letter-spacing: 0; line-height: 1.35; text-wrap: balance; } }
/* v11: pitch typewriter. The real (i18n) text stays in .hero-pitch-src and keeps the height; the effect is an overlay. */
body:not(.light-theme) #dashboardView .hero-pitch { position: relative; }
body:not(.light-theme) #dashboardView .hero-pitch-fx { display: none; }
body:not(.light-theme) #dashboardView .hero-pitch.fx-on .hero-pitch-src { opacity: 0; }
body:not(.light-theme) #dashboardView .hero-pitch.fx-on .hero-pitch-fx { display: block; position: absolute; inset: 0; }
body:not(.light-theme) #dashboardView .hero-pitch.fx-on .hero-pitch-fx.fading { opacity: .1; transition: opacity 3s linear; }
body:not(.light-theme) #dashboardView .hero-pitch-rest { visibility: hidden; }
body:not(.light-theme) #dashboardView .hero-pitch-fx.typing .hero-pitch-typed::after { content: ""; display: inline-block; width: 0; height: 1em; margin-right: -2px; vertical-align: text-bottom; border-right: 2px solid var(--gold); animation: heroPitchBlink .9s steps(1) infinite; }
@keyframes heroPitchBlink { 50% { border-color: transparent; } }

/* =====================================================================
   Classic theme: one electric blue (#2E5BFF) replaces every gold in the
   dashboard. Applied when the dashboard theme is "Classic" (body carries
   none of .gold-theme, .bloody-theme, .emerald-theme). Light mode
   (body.light-theme) is untouched by design. The logo card keeps its
   white card and navy Fund/Dreams text; only the word "Your" and its
   side lines (--gold-logo) take the theme color. Welcome/login pages and
   the client share cards do not load these styles and stay gold.
   ===================================================================== */
body:not(.light-theme):not(.gold-theme):not(.bloody-theme):not(.emerald-theme) #dashboardView {
  --gold: #2E5BFF;
  --gold-2: #2E5BFF;
  --gold-3: #2E5BFF;
  --gold-soft: rgba(46, 91, 255, 0.14);
  --on-gold: #ffffff;
  --contour-line: rgba(46, 91, 255, 0.75);
  --shadow-contour: 0 0 6px rgba(46, 91, 255, 0.45), 0 0 16px rgba(46, 91, 255, 0.14), inset 0 0 12px rgba(46, 91, 255, 0.07);
  --accent-purple: #2E5BFF;
  --accent-purple-light: #2E5BFF;
  --accent-purple-dark: #2E5BFF;
  --primary: #2E5BFF;
}
/* chart area gradient stops are hard-coded gold above; re-point them */
body:not(.light-theme):not(.gold-theme):not(.bloody-theme):not(.emerald-theme) #dashboardView #chartGradient stop { stop-color: #2E5BFF !important; }
body:not(.light-theme):not(.gold-theme):not(.bloody-theme):not(.emerald-theme) #dashboardView .chart-point { fill: #2E5BFF; }
/* bot gauge: the blue gradient of the base theme, stops forced to the one blue */
body:not(.light-theme):not(.gold-theme):not(.bloody-theme):not(.emerald-theme) #dashboardView .bot-gauge-fill { stroke: url(#gaugeGradient); }
body:not(.light-theme):not(.gold-theme):not(.bloody-theme):not(.emerald-theme) #dashboardView #botStatusCardMobile .bot-gauge-fill { stroke: url(#gaugeGradientMobile); }
body:not(.light-theme):not(.gold-theme):not(.bloody-theme):not(.emerald-theme) #dashboardView #gaugeGradient stop,
body:not(.light-theme):not(.gold-theme):not(.bloody-theme):not(.emerald-theme) #dashboardView #gaugeGradientMobile stop { stop-color: #2E5BFF !important; }
/* pending-requests banner: its amber warning edge becomes the same blue */
body:not(.light-theme):not(.gold-theme):not(.bloody-theme):not(.emerald-theme) #dashboardView #pendingRequestsBanner { border-color: rgba(46, 91, 255, 0.75) !important; box-shadow: 0 0 6px rgba(46, 91, 255, 0.4), 0 0 16px rgba(46, 91, 255, 0.12), inset 0 0 12px rgba(46, 91, 255, 0.06) !important; }
body:not(.light-theme):not(.gold-theme):not(.bloody-theme):not(.emerald-theme) #dashboardView .gold-contour { border-color: rgba(46, 91, 255, 0.75); box-shadow: 0 0 6px rgba(46, 91, 255, 0.45), 0 0 16px rgba(46, 91, 255, 0.14), inset 0 0 12px rgba(46, 91, 255, 0.07); }
/* logo card: only the word "Your" and its side lines take the theme color */
body:not(.light-theme):not(.gold-theme):not(.bloody-theme):not(.emerald-theme) #dashboardView .hero-logo-card { --gold-logo: #2E5BFF; }

/* =====================================================================
   Bloody Diamond theme: one deep blood red (#A30000) replaces every gold
   in the dashboard. Applied when the dashboard theme is "Bloody Diamond"
   (body carries .bloody-theme). Light mode (body.light-theme) is
   untouched by design. The logo card keeps its white card and navy
   Fund/Dreams text; only the word "Your" and its side lines (--gold-logo)
   take the theme color. Welcome/login pages and the client share cards
   do not load these
   styles and stay gold.
   ===================================================================== */
body:not(.light-theme).bloody-theme #dashboardView {
  --gold: #A30000;
  --gold-2: #A30000;
  --gold-3: #A30000;
  --gold-soft: rgba(163, 0, 0, 0.14);
  --on-gold: #ffffff;
  --contour-line: rgba(163, 0, 0, 0.75);
  --shadow-contour: 0 0 6px rgba(163, 0, 0, 0.45), 0 0 16px rgba(163, 0, 0, 0.14), inset 0 0 12px rgba(163, 0, 0, 0.07);
  --accent-purple: #A30000;
  --accent-purple-light: #A30000;
  --accent-purple-dark: #A30000;
  --primary: #A30000;
}
/* chart area gradient stops are hard-coded gold above; re-point them */
body:not(.light-theme).bloody-theme #dashboardView #chartGradient stop { stop-color: #A30000 !important; }
body:not(.light-theme).bloody-theme #dashboardView .chart-point { fill: #A30000; }
/* bot gauge: the blue gradient of the base theme, stops forced to the one red */
body:not(.light-theme).bloody-theme #dashboardView .bot-gauge-fill { stroke: url(#gaugeGradient); }
body:not(.light-theme).bloody-theme #dashboardView #botStatusCardMobile .bot-gauge-fill { stroke: url(#gaugeGradientMobile); }
body:not(.light-theme).bloody-theme #dashboardView #gaugeGradient stop,
body:not(.light-theme).bloody-theme #dashboardView #gaugeGradientMobile stop { stop-color: #A30000 !important; }
/* pending-requests banner: its amber warning edge becomes the same red */
body:not(.light-theme).bloody-theme #dashboardView #pendingRequestsBanner { border-color: rgba(163, 0, 0, 0.75) !important; box-shadow: 0 0 6px rgba(163, 0, 0, 0.4), 0 0 16px rgba(163, 0, 0, 0.12), inset 0 0 12px rgba(163, 0, 0, 0.06) !important; }
body:not(.light-theme).bloody-theme #dashboardView .gold-contour { border-color: rgba(163, 0, 0, 0.75); box-shadow: 0 0 6px rgba(163, 0, 0, 0.45), 0 0 16px rgba(163, 0, 0, 0.14), inset 0 0 12px rgba(163, 0, 0, 0.07); }
/* logo card: only the word "Your" and its side lines take the theme color */
body:not(.light-theme).bloody-theme #dashboardView .hero-logo-card { --gold-logo: #A30000; }

/* =====================================================================
   Natural Emerald theme: the deep emerald green (#004400) replaces
   every gold in the dashboard. Applied when the dashboard theme is
   "Natural Emerald" (body carries .emerald-theme). Light mode
   (body.light-theme) is untouched by design. The logo card keeps its
   white card and navy Fund/Dreams text; only the word "Your" and its
   side lines (--gold-logo) take the theme color. Welcome/login pages and
   the client share cards do not load these styles and stay gold.
   ===================================================================== */
body:not(.light-theme).emerald-theme #dashboardView {
  --gold: #004400;
  --gold-2: #004400;
  --gold-3: #004400;
  --gold-soft: rgba(0, 68, 0, 0.14);
  --on-gold: #ffffff;
  --contour-line: rgba(0, 68, 0, 0.75);
  --shadow-contour: 0 0 6px rgba(0, 68, 0, 0.45), 0 0 16px rgba(0, 68, 0, 0.14), inset 0 0 12px rgba(0, 68, 0, 0.07);
  --accent-purple: #004400;
  --accent-purple-light: #004400;
  --accent-purple-dark: #004400;
  --primary: #004400;
}
/* Deposit / Withdraw modals sit outside #dashboardView, so they never saw the theme
   tokens above and stayed on the body-level blue (Hugo, 2026-10-18). Gold and blue are
   already right (body.gold-theme / body default); only red and green need the tokens. */
body:not(.light-theme).bloody-theme #withdrawModal, body:not(.light-theme).bloody-theme #depositModal { --primary: #A30000; --accent-purple: #A30000; }
body:not(.light-theme).emerald-theme #withdrawModal, body:not(.light-theme).emerald-theme #depositModal { --primary: #004400; --accent-purple: #004400; }
/* Profit pop-up (piggy + coin) also sits outside #dashboardView: give it the per-theme
   accent as --gold so its border, glow and badge follow the theme like the modals above.
   Gold theme and light mode keep the #FFD700 fallback in index.html. */
body:not(.light-theme):not(.gold-theme):not(.bloody-theme):not(.emerald-theme) #profitPopup { --gold: #2E5BFF; --on-gold: #fff; }
body:not(.light-theme).bloody-theme #profitPopup { --gold: #A30000; --on-gold: #fff; }
body:not(.light-theme).emerald-theme #profitPopup { --gold: #004400; --on-gold: #fff; }
/* Pop-up card = a dashboard card (Hugo, 2026-10-19), both modes: page base (--bg), then the live rain mirrored by dashboard-rain.js at #dashRain's own opacity, then the card tint --panel (alpha .738). Stack: card background < canvas (z -1) < ::after tint (z -1, later in tree order) < content. */
body #profitPopup .profit-popup-content { background: var(--bg, #1a1a24); }
#profitPopup .profit-popup-rain { position: absolute; inset: 0; width: 100%; height: 100%; z-index: -1; opacity: 0.30; pointer-events: none; }
body.dash-light #profitPopup .profit-popup-rain { opacity: 0.6; }
/* Dark mode only (Hugo, 2026-10-19: rain barely visible): the pop-up mirror is brighter (.6, the dashboard rain stays .30) and the tint thinner (.738 x 54% = .4). Text under the brightest digit stays >= 3.25:1. */
body:not(.dash-light) #profitPopup .profit-popup-rain { opacity: 0.6; }
body:not(.dash-light) #profitPopup .profit-popup-content::after { background: color-mix(in srgb, var(--panel) 54%, transparent); }
#profitPopup .profit-popup-content::after { content: ""; position: absolute; inset: 0; z-index: -1; background: var(--panel); pointer-events: none; }
/* Pop-up headline (the profit number) and date: white in dark mode, all themes (Hugo, 2026-10-19, after the badge-colour trial); light mode is navy in dashboard-light.css. */
body:not(.dash-light) #profitPopup .profit-popup-headline, body:not(.dash-light) #profitPopup .profit-popup-subdate { color: #FFFFFF; }
/* chart area gradient stops are hard-coded gold above; re-point them */
body:not(.light-theme).emerald-theme #dashboardView #chartGradient stop { stop-color: #004400 !important; }
body:not(.light-theme).emerald-theme #dashboardView .chart-point { fill: #004400; }
/* bot gauge: the blue gradient of the base theme, stops forced to the one green */
body:not(.light-theme).emerald-theme #dashboardView .bot-gauge-fill { stroke: url(#gaugeGradient); }
body:not(.light-theme).emerald-theme #dashboardView #botStatusCardMobile .bot-gauge-fill { stroke: url(#gaugeGradientMobile); }
body:not(.light-theme).emerald-theme #dashboardView #gaugeGradient stop,
body:not(.light-theme).emerald-theme #dashboardView #gaugeGradientMobile stop { stop-color: #004400 !important; }
/* pending-requests banner: its amber warning edge becomes the same green */
body:not(.light-theme).emerald-theme #dashboardView #pendingRequestsBanner { border-color: rgba(0, 68, 0, 0.75) !important; box-shadow: 0 0 6px rgba(0, 68, 0, 0.4), 0 0 16px rgba(0, 68, 0, 0.12), inset 0 0 12px rgba(0, 68, 0, 0.06) !important; }
body:not(.light-theme).emerald-theme #dashboardView .gold-contour { border-color: rgba(0, 68, 0, 0.75); box-shadow: 0 0 6px rgba(0, 68, 0, 0.45), 0 0 16px rgba(0, 68, 0, 0.14), inset 0 0 12px rgba(0, 68, 0, 0.07); }
/* logo card: only the word "Your" and its side lines take the theme color */
body:not(.light-theme).emerald-theme #dashboardView .hero-logo-card { --gold-logo: #004400; }

/* Emerald DARK mode only (Hugo, 2026-10-19): the theme green is the colour of the Matrix digits, #00E676 (dashboard-rain.js, emerald dark glyph), not the deep #004400.
   Same properties as the block above, scoped :not(.dash-light) and placed after it so it wins the tie; Emerald light (dash-light) keeps #004400. Text on the bright green is the dark #14120a (about 11:1), white would be 1.7:1. */
body.emerald-theme:not(.dash-light) #dashboardView {
  --gold: #00E676;
  --gold-2: #00E676;
  --gold-3: #00E676;
  --gold-soft: rgba(0, 230, 118, 0.14);
  --on-gold: #14120a;
  --contour-line: rgba(0, 230, 118, 0.75);
  --shadow-contour: 0 0 6px rgba(0, 230, 118, 0.45), 0 0 16px rgba(0, 230, 118, 0.14), inset 0 0 12px rgba(0, 230, 118, 0.07);
  --accent-purple: #00E676;
  --accent-purple-light: #00E676;
  --accent-purple-dark: #00E676;
  --primary: #00E676;
}
body.emerald-theme:not(.dash-light) #withdrawModal, body.emerald-theme:not(.dash-light) #depositModal { --primary: #00E676; --accent-purple: #00E676; }
body.emerald-theme:not(.dash-light) #profitPopup { --gold: #00E676; --on-gold: #14120a; }
body.emerald-theme:not(.dash-light) #dashboardView #chartGradient stop { stop-color: #00E676 !important; }
body.emerald-theme:not(.dash-light) #dashboardView .chart-point { fill: #00E676; }
body.emerald-theme:not(.dash-light) #dashboardView #gaugeGradient stop,
body.emerald-theme:not(.dash-light) #dashboardView #gaugeGradientMobile stop { stop-color: #00E676 !important; }
body.emerald-theme:not(.dash-light) #dashboardView #pendingRequestsBanner { border-color: rgba(0, 230, 118, 0.75) !important; box-shadow: 0 0 6px rgba(0, 230, 118, 0.4), 0 0 16px rgba(0, 230, 118, 0.12), inset 0 0 12px rgba(0, 230, 118, 0.06) !important; }
body.emerald-theme:not(.dash-light) #dashboardView .gold-contour { border-color: rgba(0, 230, 118, 0.75); box-shadow: 0 0 6px rgba(0, 230, 118, 0.45), 0 0 16px rgba(0, 230, 118, 0.14), inset 0 0 12px rgba(0, 230, 118, 0.07); }
body.emerald-theme:not(.dash-light) #dashboardView .hero-logo-card { --gold-logo: #00E676; }
/* Settings theme buttons (the quick-switch suns stay fixed per theme, a pin forbids restyling them), outside #dashboardView (index.html hard-codes #004400) */
/* Buttons that hard-code white text on the accent fill (inline style or index.html rules): white on bright green is 1.7:1, so the text goes dark, as --on-gold does elsewhere. */
body.emerald-theme:not(.dash-light) :is(#privacyModeToggleBtn, #settingsDreamSaveBtn, #contactSendBtn, #reinvestBonusBtn, #inviteApplyFiltersBtn, #submitDepositBtn, .modal-btn-primary, button[onclick="openDepositAddressesModal()"]) { color: #14120a !important; }
body.emerald-theme:not(.dash-light) .dashboard-theme-btn.active { background: linear-gradient(135deg, rgba(0, 230, 118, 0.15) 0%, rgba(0, 230, 118, 0.1) 100%); border: 2px solid #00E676; }
body.emerald-theme:not(.dash-light) .dashboard-theme-btn:hover { border-color: #00E676; }

/* Active Strategy pill: border follows the theme accent like .hero-word-box (Hugo, 2026-10-18); extra .header-left beats the 1px badge rule above */
body:not(.light-theme) #dashboardView .header-left .strategy-badge { border-color: var(--gold); }
/* Trade / Commodities-Crypto-Stocks box: border follows the theme accent (--gold is re-pointed per theme) */
body:not(.light-theme) #dashboardView .hero-word-box { border-color: var(--gold); }

/* Phone / home-screen app (viewport-fit=cover, translucent status bar): keep the sticky header below the notch.
   env() is 0 everywhere else, so desktop and normal browser tabs are unchanged. */
@media (max-width: 768px) {
  body:not(.light-theme) #dashboardView .header { padding-top: calc(8px + env(safe-area-inset-top, 0px)); }
}

/* Admin Approve / Reject buttons (requests.js, Withdraw + Deposit request lists): theme accent.
   Approve = filled accent, Reject = accent outline (inset ring, no layout change). Colors only. */
#dashboardView .req-btn-approve { background: var(--gold); color: #fff; }
body.gold-theme #dashboardView .req-btn-approve { color: #1a1a24; }
#dashboardView .req-btn-reject { background: transparent; color: var(--gold); box-shadow: inset 0 0 0 1px var(--gold); }
body.dash-light #dashboardView .req-btn-reject { color: var(--gold-ink); }
/* Dark accent (Bloody) vanishes as text on the dark panel: lift the Reject text toward white, hue kept. */
body.bloody-theme:not(.dash-light) #dashboardView .req-btn-reject { color: color-mix(in srgb, var(--gold) 50%, #fff); }

/* ---- Privacy mode (Hugo, 2026-10-19): the one existing state (body.privacy-mode, localStorage 'privacyMode') now hides EVERY dashboard figure, percentages included.
   Same blur masking as the legacy rules in index.html, extended to the figures those missed. The chart line keeps its shape, its tooltip value is replaced by dots in index.html. ---- */
body.privacy-mode #dashboardView :is(.kpi-value, .kpi-fees, .kpi-subtitle span[id], #kpiProfitSubtitle, #kpiAPRSubtitle, #kpiTotalAPRSubtitle, #kpiDrawdownSubtitle, #equityMexcSubtitle, #kpiCopybotDrawdownLine,
    .goal-current, .goal-target, .goal-percentage, .bot-gauge-percent, #botEngagedCount, #botEngagedCountMobile, .capital-amount, .activity-amount, .tooltip-value,
    #assetProfit, #assetROI, #assetAPR, #assetVolume, #assetEngaged, #assetAvgPrice, #copybotClosedTradesBody, #botsOpenPositionsList .bot-cap) { filter: blur(8px); user-select: none; }
/* top-bar eye button: theme accent outline, filled while privacy is on (dark = --gold re-pointed per theme; light = the opaque accent header, so --hdr-fg) */
#dashboardView .header-privacy-btn { color: var(--gold); border: 1px solid var(--gold); border-radius: 8px; padding: 6px; }
#dashboardView .header-privacy-btn:hover { color: var(--gold); background: var(--gold-soft, transparent); }
body.privacy-mode #dashboardView .header-privacy-btn { background: var(--gold); color: var(--on-gold, #1a1a24); }
body.dash-light #dashboardView .header-privacy-btn, body.dash-light #dashboardView .header-privacy-btn:hover { color: var(--hdr-fg); border-color: var(--hdr-fg); background: transparent; }
body.dash-light.privacy-mode #dashboardView .header-privacy-btn { background: var(--hdr-fg); color: var(--lt-accent); }
/* phone (Hugo 2026-10-19): header-left AND header-right are display:contents, so menu, title, role badge, strategy badge and the eye are ONE wrapped flex row set.
   Row 1 = menu + title (the title basis in index.html forces the break), row 2 = pills + the eye, shrunk to a small rectangle the height of the strategy pill. Same element, same handler. */
@media (max-width: 768px) {
  #dashboardView .header-left { display: contents; }
  #dashboardView .header-privacy-btn { box-sizing: border-box; min-width: 36px; min-height: 28px; height: 28px; padding: 0 !important; flex-shrink: 0; display: inline-flex; align-items: center; justify-content: center; border-radius: var(--radius-md, 8px); }
  #dashboardView .header-privacy-btn svg { width: 16px; height: 16px; }
  #dashboardView .header .page-title { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
}
/* 360px: role + strategy + eye must share one row; tighter column gap and strategy pill (colours and heights unchanged) */
@media (max-width: 480px) {
  body:not(.light-theme) #dashboardView .header { column-gap: 8px; }
  body:not(.light-theme) #dashboardView .header .strategy-badge { letter-spacing: 0.03em; padding: 6px 8px; gap: 4px; }
}

/* ---- .fyd-title: every section heading uses the page-title font (Hugo 2026-10-20).
   !important + this specificity beat `#dashboardView *` (mono, !important) above; the nested
   [data-i18n] spans (e.g. "Referral Reward") inherit instead of falling back to mono. ---- */
body:not(.light-theme) #dashboardView .fyd-title,
body:not(.light-theme) #dashboardView .fyd-title [data-i18n] {
  font-family: var(--font-title) !important;
  font-weight: 400 !important;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  overflow-wrap: anywhere;
}
