/* FRA Prop HQ v6.10.1 — warm charcoal + lime accent palette
   Colour-only refresh. Lock-In mindset system and all functionality preserved. */

:root,
:root[data-theme="dark"] {
  --bg: #121416;
  --bg-2: #171a1d;
  --sidebar: rgba(20, 23, 25, .96);
  --topbar: rgba(19, 21, 23, .82);
  --panel: rgba(29, 32, 35, .92);
  --panel-2: #202428;
  --panel-3: #282d31;
  --input: #1a1d20;
  --hover: #292e32;
  --border: rgba(248, 239, 225, .09);
  --border-strong: rgba(248, 239, 225, .18);
  --text: #eee8de;
  --text-strong: #fffaf2;
  --muted: #aaa39a;
  --muted-2: #7d7770;
  --accent: #cdf45b;
  --accent-soft: rgba(205, 244, 91, .11);
  --green: #88cf82;
  --amber: #e0b46d;
  --blue: #8eafe4;
  --teal: #7fb9a7;
  --red: #ed7e78;
  --purple: #b4a2d8;
  --warm: #d9b98b;
  --warm-soft: rgba(217, 185, 139, .10);
  --chart-fill: rgba(205, 244, 91, .15);
  --chart-fill-end: rgba(205, 244, 91, 0);
  --chart-grid: rgba(255, 248, 237, .05);
}

:root[data-theme="light"] {
  --bg: #eeeae2;
  --bg-2: #e6e1d8;
  --sidebar: rgba(249, 247, 242, .97);
  --topbar: rgba(238, 234, 226, .88);
  --panel: rgba(255, 253, 248, .96);
  --panel-2: #f5f1e9;
  --panel-3: #ebe6dd;
  --input: #fffdf8;
  --hover: #ece8df;
  --border: rgba(50, 48, 44, .11);
  --border-strong: rgba(50, 48, 44, .21);
  --text: #302f2c;
  --text-strong: #171713;
  --muted: #716d65;
  --muted-2: #928d83;
  --accent: #77980d;
  --accent-soft: rgba(119, 152, 13, .10);
  --green: #4c9058;
  --amber: #9f6c28;
  --blue: #526f9a;
  --teal: #477d70;
  --red: #b55751;
  --purple: #776b96;
  --warm: #7c6040;
  --warm-soft: rgba(124, 96, 64, .08);
}

body {
  background:
    radial-gradient(circle at 87% -5%, rgba(205, 244, 91, .075), transparent 31%),
    radial-gradient(circle at 8% 75%, rgba(217, 185, 139, .055), transparent 35%),
    linear-gradient(145deg, var(--bg), var(--bg-2)) !important;
}

/* Lime is a highlight, not the whole canvas. */
.button.primary {
  background: linear-gradient(135deg, #ddff7d, #bfe75a) !important;
  border-color: rgba(225, 255, 145, .28) !important;
  color: #1a1c14 !important;
  box-shadow: 0 10px 28px rgba(205, 244, 91, .12) !important;
}
.button.primary:hover { background: linear-gradient(135deg, #e5ff94, #c9ed68) !important; }
.link-button,
.settings-trust-links a,
.provider-scope-tags span { color: var(--accent) !important; }
.control:focus,
.text-input:focus { border-color: rgba(205, 244, 91, .58) !important; box-shadow: 0 0 0 3px rgba(205, 244, 91, .09) !important; }

/* App chrome */
.sidebar {
  background:
    radial-gradient(circle at 0 0, rgba(205, 244, 91, .055), transparent 34%),
    linear-gradient(180deg, rgba(23, 26, 28, .98), rgba(17, 19, 21, .98)) !important;
}
.sidebar::before { background: radial-gradient(circle, rgba(205, 244, 91, .10), transparent 68%) !important; }
.nav-item.active {
  background: linear-gradient(135deg, rgba(205, 244, 91, .09), rgba(255,255,255,.025)) !important;
  box-shadow: inset 0 0 0 1px rgba(205, 244, 91, .18), 0 9px 24px rgba(0,0,0,.12) !important;
}
.nav-item.active span { color: var(--accent) !important; }
.avatar {
  background: linear-gradient(135deg, #d9ff77, #91b93e) !important;
  color: #171a12 !important;
}
.topbar { background: var(--topbar) !important; }
.panel,
.kpi-card {
  background: linear-gradient(150deg, rgba(35, 38, 42, .96), rgba(25, 28, 31, .96)) !important;
}
#view-dashboard .kpi-card:nth-child(1) {
  background:
    radial-gradient(circle at 82% 22%, rgba(205, 244, 91, .11), transparent 37%),
    linear-gradient(145deg, rgba(37, 40, 42, .97), rgba(25, 28, 30, .97)) !important;
}
.progress-fill { background: linear-gradient(90deg, #d9ff78, #b9dd50) !important; }
.segmented button.active {
  background: rgba(205, 244, 91, .09) !important;
  border-color: rgba(205, 244, 91, .31) !important;
  color: #e5f9a5 !important;
}

/* Welcome and mindset remain warm and human. */
.dashboard-welcome-copy {
  background:
    radial-gradient(circle at 88% 18%, rgba(205, 244, 91, .10), transparent 36%),
    linear-gradient(145deg, rgba(35, 38, 40, .97), rgba(26, 29, 31, .97)) !important;
}
.dashboard-welcome-copy::after {
  border-color: rgba(205, 244, 91, .16) !important;
  box-shadow: 0 0 0 22px rgba(205, 244, 91, .025), 0 0 0 46px rgba(205, 244, 91, .018) !important;
}
.dashboard-eyebrow,
.quote-label { color: var(--accent) !important; }
.dashboard-eyebrow::before,
.quote-label::before {
  background: var(--accent) !important;
  box-shadow: 0 0 16px rgba(205, 244, 91, .36) !important;
}
.zone-quote-card {
  background:
    radial-gradient(circle at 100% 0, rgba(217, 185, 139, .11), transparent 39%),
    linear-gradient(145deg, rgba(38, 36, 33, .97), rgba(27, 29, 30, .97)) !important;
}
.quote-footer button { color: var(--warm) !important; }
.quote-mode-row button.active {
  color: #e5f9a5 !important;
  border-color: rgba(205, 244, 91, .28) !important;
  background: rgba(205, 244, 91, .08) !important;
}
.day-mindset-strip {
  background:
    radial-gradient(circle at 92% 0, rgba(217, 185, 139, .09), transparent 38%),
    linear-gradient(145deg, rgba(36, 35, 33, .96), rgba(26, 28, 29, .96)) !important;
}

/* Public landing: charcoal, stone and restrained lime. */
.fra-landing {
  color: #eee8df !important;
  background:
    linear-gradient(rgba(255,255,255,.014) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.014) 1px, transparent 1px),
    radial-gradient(circle at 71% 9%, rgba(205, 244, 91, .075), transparent 31rem),
    radial-gradient(circle at 12% 36%, rgba(217, 185, 139, .045), transparent 28rem),
    #121416 !important;
  background-size: 52px 52px, 52px 52px, auto, auto, auto !important;
}
.landing-nav { border-bottom-color: rgba(255, 247, 235, .09) !important; }
.landing-nav-links a { color: #9f9990 !important; }
.landing-nav-links a:hover { color: #fffaf2 !important; }
.brand-wordmark strong:first-child,
.brand-wordmark strong:last-child,
.landing-hero h1 em,
.section-kicker,
.feature-label,
.price-tier,
.trust-principles article > span { color: #cdf45b !important; }
.beta-pill {
  color: #b0aaa1 !important;
  border-color: rgba(205, 244, 91, .18) !important;
  background: rgba(28, 30, 31, .76) !important;
}
.beta-pill span,
.board-live i {
  background: #cdf45b !important;
  box-shadow: 0 0 14px rgba(205, 244, 91, .65) !important;
}
.landing-hero::after { background: radial-gradient(circle, rgba(205, 244, 91, .08), transparent 67%) !important; }
.landing-hero h1 { color: #fffaf2 !important; }
.landing-hero-copy > p,
.landing-proof-row { color: #aaa39a !important; }
.landing-proof-row span::before { color: #cdf45b !important; }
.command-board {
  border-color: rgba(255, 247, 235, .10) !important;
  background: linear-gradient(145deg, rgba(31, 34, 36, .99), rgba(18, 20, 22, .99)) !important;
}
.board-topline { background: rgba(20, 22, 24, .84) !important; border-bottom-color: rgba(255,247,235,.08) !important; }
.board-kpis article,
.board-chart-card,
.mini-card,
.feature-card,
.modern-price-card {
  background: linear-gradient(145deg, rgba(38, 41, 44, .88), rgba(27, 30, 32, .90)) !important;
  border-color: rgba(255, 247, 235, .08) !important;
}
.mini-card.accent,
.modern-price-card.featured {
  border-color: rgba(205, 244, 91, .22) !important;
  background: linear-gradient(145deg, rgba(205,244,91,.055), rgba(32,35,37,.94)) !important;
}
.feature-icon,
.chart-dot { color: #cdf45b !important; }
.chart-line { stroke: #cdf45b !important; }
.chart-area { fill: rgba(205, 244, 91, .12) !important; }
.mini-progress > span,
.rule-ring::before { background: #cdf45b !important; }
.workflow-section {
  background: radial-gradient(circle at 82% 18%, rgba(217,185,139,.055), transparent 32rem), #17191b !important;
}
.trader-code-section {
  background:
    radial-gradient(circle at 10% 100%, rgba(217,185,139,.06), transparent 35%),
    linear-gradient(145deg, #191b1d, #121416) !important;
}
.trader-code-quotes article { border-color: rgba(255,247,235,.09) !important; background: rgba(255,255,255,.025) !important; }
.trader-code-quotes article > span { color: #cdf45b !important; }
.landing-footer { border-top-color: rgba(255,247,235,.09) !important; }

/* Trust / provider pages */
.trust-page {
  background:
    radial-gradient(circle at 85% 0, rgba(205,244,91,.075), transparent 30%),
    radial-gradient(circle at 10% 85%, rgba(217,185,139,.055), transparent 32%),
    #121416 !important;
  color: #eee9e1 !important;
}
.trust-kicker,
.scope-box.good h3,
.status-chip.live,
.trust-contact-strip a { color: #cdf45b !important; }
.trust-page-nav nav a,
.trust-hero p,
.trust-card p,
.trust-card li,
.trust-section p,
.trust-section li,
.trust-status-line span { color: #aaa39a !important; }
.trust-card,
.trust-section,
.trust-hero-card,
.partner-brief-cta,
.trust-principles article {
  border-color: rgba(255,247,235,.09) !important;
  background: rgba(255,255,255,.027) !important;
}
.status-chip.live {
  background: rgba(205,244,91,.075) !important;
  border-color: rgba(205,244,91,.18) !important;
}

/* Keep profit/loss semantics distinct from brand lime. */
.positive,
.up,
.badge.green,
.trade-side.buy { color: var(--green) !important; }
.negative,
.down,
.badge.red,
.trade-side.sell { color: var(--red) !important; }

/* ==================================================================
   FRA Prop HQ v6.12.1 — proper light mode
   Warm paper canvas, crisp light surfaces, dark sidebar and lime accents.
   ================================================================== */
:root[data-theme="light"] {
  --bg: #eeeae2;
  --bg-2: #e6e1d8;
  --sidebar: #191c1d;
  --topbar: rgba(250, 248, 243, .93);
  --panel: #fbfaf6;
  --panel-2: #f4f1ea;
  --panel-3: #ebe7de;
  --input: #fffefb;
  --hover: #efebe3;
  --border: rgba(38, 40, 38, .11);
  --border-strong: rgba(38, 40, 38, .21);
  --text: #34342f;
  --text-strong: #181915;
  --muted: #6f6c65;
  --muted-2: #918c82;
  --accent: #78980e;
  --accent-soft: rgba(120, 152, 14, .11);
  --green: #3f8750;
  --amber: #9b6926;
  --blue: #4b6893;
  --teal: #3f786c;
  --red: #b44f4b;
  --purple: #756890;
  --warm: #80603d;
  --warm-soft: rgba(128, 96, 61, .08);
  --shadow: 0 18px 48px rgba(44, 42, 35, .08);
  --chart-grid: rgba(31, 35, 31, .08);
  --chart-fill: rgba(120, 152, 14, .13);
  --chart-fill-end: rgba(120, 152, 14, 0);
}

:root[data-theme="light"] body {
  background:
    radial-gradient(circle at 87% -6%, rgba(205, 244, 91, .12), transparent 31%),
    radial-gradient(circle at 8% 78%, rgba(217, 185, 139, .11), transparent 35%),
    linear-gradient(145deg, var(--bg), var(--bg-2)) !important;
  color: var(--text);
}

/* Keep the navigation as the dark anchor of the light theme. */
:root[data-theme="light"] .sidebar {
  background:
    radial-gradient(circle at 0 0, rgba(205, 244, 91, .075), transparent 34%),
    linear-gradient(180deg, #202426, #151819) !important;
  border-color: rgba(255, 248, 237, .10) !important;
  box-shadow: 0 22px 55px rgba(35, 34, 29, .18) !important;
}
:root[data-theme="light"] .sidebar .app-brand-word,
:root[data-theme="light"] .sidebar .user-name,
:root[data-theme="light"] .sidebar .sync-line strong,
:root[data-theme="light"] .sidebar .sidebar-feedback-button strong {
  color: #f6f1e8 !important;
}
:root[data-theme="light"] .sidebar .app-brand-word strong,
:root[data-theme="light"] .sidebar .nav-item.active span {
  color: #d1f45f !important;
}
:root[data-theme="light"] .sidebar .app-brand-tag,
:root[data-theme="light"] .sidebar .nav-item,
:root[data-theme="light"] .sidebar .nav-item span,
:root[data-theme="light"] .sidebar .sync-title,
:root[data-theme="light"] .sidebar .sync-small,
:root[data-theme="light"] .sidebar .user-role,
:root[data-theme="light"] .sidebar .sidebar-feedback-button small {
  color: #aaa59c !important;
}
:root[data-theme="light"] .sidebar .nav-item:hover {
  color: #f3eee5 !important;
  background: rgba(255,255,255,.045) !important;
}
:root[data-theme="light"] .sidebar .nav-item.active {
  color: #fffaf2 !important;
  background: linear-gradient(135deg, rgba(205,244,91,.12), rgba(255,255,255,.035)) !important;
  box-shadow: inset 0 0 0 1px rgba(205,244,91,.23), 0 9px 24px rgba(0,0,0,.14) !important;
}
:root[data-theme="light"] .sidebar .sync-card,
:root[data-theme="light"] .sidebar .sidebar-feedback-button {
  background: linear-gradient(145deg, rgba(255,255,255,.055), rgba(255,255,255,.025)) !important;
  border-color: rgba(255,248,237,.10) !important;
  color: #f6f1e8 !important;
}
:root[data-theme="light"] .sidebar .sidebar-feedback-button > span {
  color: #d1f45f !important;
  background: rgba(205,244,91,.10) !important;
}
:root[data-theme="light"] .sidebar .nav-divider,
:root[data-theme="light"] .sidebar .user-card {
  border-color: rgba(255,248,237,.08) !important;
}

/* Main chrome and controls. */
:root[data-theme="light"] .topbar {
  background: rgba(250, 248, 243, .92) !important;
  border-color: rgba(38,40,38,.10) !important;
  box-shadow: 0 12px 34px rgba(50,47,40,.07) !important;
}
:root[data-theme="light"] .topbar h1,
:root[data-theme="light"] .section-head h2,
:root[data-theme="light"] .panel-head h2,
:root[data-theme="light"] .kpi-value {
  color: var(--text-strong) !important;
}
:root[data-theme="light"] .control,
:root[data-theme="light"] .text-input,
:root[data-theme="light"] .theme-toggle,
:root[data-theme="light"] .icon-button,
:root[data-theme="light"] .button.secondary,
:root[data-theme="light"] .button.ghost {
  color: var(--text-strong) !important;
  background: #fffdf8 !important;
  border-color: rgba(42,43,39,.12) !important;
  box-shadow: 0 4px 14px rgba(48,45,37,.035) !important;
}
:root[data-theme="light"] .control:hover,
:root[data-theme="light"] .theme-toggle:hover,
:root[data-theme="light"] .button.secondary:hover,
:root[data-theme="light"] .button.ghost:hover {
  background: #f4f0e8 !important;
  border-color: rgba(120,152,14,.28) !important;
}

/* Light surfaces: remove the dark hard-coded card backgrounds. */
:root[data-theme="light"] .panel,
:root[data-theme="light"] .kpi-card,
:root[data-theme="light"] #view-dashboard .kpi-card,
:root[data-theme="light"] #view-dashboard .kpi-card:nth-child(1),
:root[data-theme="light"] .provider-review-panel {
  color: var(--text);
  background: linear-gradient(150deg, #fffefb, #f7f4ed) !important;
  border-color: rgba(40,42,38,.10) !important;
  box-shadow: 0 16px 42px rgba(51,48,40,.075) !important;
}
:root[data-theme="light"] #view-dashboard .kpi-card:nth-child(1) {
  background:
    radial-gradient(circle at 82% 22%, rgba(205,244,91,.20), transparent 38%),
    linear-gradient(145deg, #fffef9, #f5f1e8) !important;
}
:root[data-theme="light"] .panel-head {
  border-bottom-color: rgba(40,42,38,.08) !important;
}
:root[data-theme="light"] .data-table th {
  color: #6d6961 !important;
  background: #eeebe4 !important;
  border-bottom-color: rgba(40,42,38,.10) !important;
}
:root[data-theme="light"] .data-table td {
  color: #33332f !important;
  border-bottom-color: rgba(40,42,38,.07) !important;
}
:root[data-theme="light"] .data-table tbody tr:hover {
  background: rgba(120,152,14,.045) !important;
}
:root[data-theme="light"] .progress-track,
:root[data-theme="light"] .weekday-bar,
:root[data-theme="light"] .risk-meter {
  background: rgba(41,43,39,.09) !important;
}

/* Welcome and mindset cards need true light-theme treatments. */
:root[data-theme="light"] .dashboard-welcome-copy {
  color: var(--text);
  background:
    radial-gradient(circle at 88% 18%, rgba(205,244,91,.21), transparent 37%),
    linear-gradient(145deg, #fffdf8, #f2eee5) !important;
  border-color: rgba(40,42,38,.10) !important;
  box-shadow: 0 18px 46px rgba(51,48,40,.08) !important;
}
:root[data-theme="light"] .dashboard-welcome-copy::after {
  border-color: rgba(120,152,14,.18) !important;
  box-shadow: 0 0 0 22px rgba(120,152,14,.035), 0 0 0 46px rgba(120,152,14,.022) !important;
}
:root[data-theme="light"] .dashboard-welcome h2,
:root[data-theme="light"] .zone-quote-card blockquote {
  color: #1d1e1a !important;
}
:root[data-theme="light"] .dashboard-welcome-copy p,
:root[data-theme="light"] .quote-footer,
:root[data-theme="light"] .quote-support {
  color: #706c64 !important;
}
:root[data-theme="light"] .dashboard-focus-pills span,
:root[data-theme="light"] .quote-mode-row button {
  color: #68655e !important;
  background: rgba(255,255,255,.58) !important;
  border-color: rgba(40,42,38,.10) !important;
}
:root[data-theme="light"] .zone-quote-card {
  color: var(--text);
  background:
    radial-gradient(circle at 100% 0, rgba(217,185,139,.22), transparent 40%),
    linear-gradient(145deg, #fffdf8, #f3eee5) !important;
  border-color: rgba(40,42,38,.10) !important;
  box-shadow: 0 18px 46px rgba(51,48,40,.08) !important;
}
:root[data-theme="light"] .quote-mode-row button.active {
  color: #4e6606 !important;
  border-color: rgba(120,152,14,.34) !important;
  background: rgba(205,244,91,.18) !important;
}
:root[data-theme="light"] .quote-footer button {
  color: #76552f !important;
}
:root[data-theme="light"] .day-mindset-strip {
  color: var(--text);
  background:
    radial-gradient(circle at 92% 0, rgba(217,185,139,.18), transparent 38%),
    linear-gradient(145deg, #fffdf8, #f3eee6) !important;
  border-color: rgba(40,42,38,.10) !important;
}

/* Secondary widgets and modal surfaces. */
:root[data-theme="light"] .modal-card,
:root[data-theme="light"] .onboarding-card,
:root[data-theme="light"] .import-review-card,
:root[data-theme="light"] .import-complete-card,
:root[data-theme="light"] .plan-card,
:root[data-theme="light"] .eligibility-card,
:root[data-theme="light"] .notebook-search,
:root[data-theme="light"] .notebook-list-head select,
:root[data-theme="light"] .notebook-meta-grid > *,
:root[data-theme="light"] .editor-toolbar button,
:root[data-theme="light"] .notebook-link-row select,
:root[data-theme="light"] .notebook-link-row input {
  color: var(--text) !important;
  background: #fffdf8 !important;
  border-color: rgba(40,42,38,.11) !important;
}
:root[data-theme="light"] .segmented button {
  color: #66625b !important;
  background: #f7f4ed !important;
  border-color: rgba(40,42,38,.10) !important;
}
:root[data-theme="light"] .segmented button.active {
  color: #4e6508 !important;
  background: rgba(205,244,91,.19) !important;
  border-color: rgba(120,152,14,.30) !important;
}
:root[data-theme="light"] .mini-button {
  color: #3b3a35 !important;
  background: #fffdf8 !important;
  border-color: rgba(40,42,38,.12) !important;
}
:root[data-theme="light"] .demo-banner {
  color: #6e532c !important;
  background: rgba(224,180,109,.13) !important;
  border-color: rgba(159,108,40,.20) !important;
}

/* Semantic colours remain readable on pale surfaces. */
:root[data-theme="light"] .positive,
:root[data-theme="light"] .up,
:root[data-theme="light"] .badge.green,
:root[data-theme="light"] .trade-side.buy { color: #347b46 !important; }
:root[data-theme="light"] .negative,
:root[data-theme="light"] .down,
:root[data-theme="light"] .badge.red,
:root[data-theme="light"] .trade-side.sell { color: #ab4744 !important; }
:root[data-theme="light"] .kpi-label,
:root[data-theme="light"] .kpi-sub,
:root[data-theme="light"] .panel-sub,
:root[data-theme="light"] .account-name small,
:root[data-theme="light"] .progress-label {
  color: #77736b !important;
}
