/* Mintoro Technologies — shared styles. Light tokens on :root, dark via system setting or [data-theme]. */
:root {
  --bg: #F5F6F2; --surface: #FFFFFF; --surface2: #ECEFE8; --term: #F9FAF7; --line: #D9DED6; --dash: #B9C2B7;
  --fg: #0E1512; --muted: #55615B; --accent: #0B8A5E; --accent-text: #08754F; --accent-ink: #FFFFFF;
  --accent-soft: rgba(11,138,94,.10); --violet: #6544D6; --violet-text: #5A38CF; --red: #B4301F; --warn: #93580A;
  --blue: #1F5FB4; --face: #0E1512; --face-eye: #F5F6F2; --star: #6D4AE0; --device: #12142A;
  --blue-soft: rgba(31,95,180,.10); --violet-soft: rgba(101,68,214,.10); --warn-soft: rgba(147,88,10,.10);
  --c0: #0B8A5E; --c1: #6544D6; --c2: #93580A; --c3: #1F5FB4; --c4: #C0306E; --c5: #007FA3;   /* book colours, validated (28 Nov) */
  --mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, monospace;   /* logs only */
  --sans: Inter, system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --display: 'Space Grotesk', Inter, system-ui, sans-serif;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0B0E12; --surface: #12161C; --surface2: #1A2029; --term: #0E1218; --line: #252D38; --dash: #3A4656;
    --fg: #E8ECEF; --muted: #9AA7B4; --accent: #34E0A1; --accent-text: #34E0A1; --accent-ink: #04130D;
    --accent-soft: rgba(52,224,161,.12); --violet: #B39DFB; --violet-text: #C2B0FF; --red: #FF7A7A; --warn: #F5B83D;
    --blue: #7AB8FF; --face: #1E242D; --face-eye: #F2F5F7; --star: #FFFFFF; --device: #1B2040;
    --blue-soft: rgba(122,184,255,.14); --violet-soft: rgba(179,157,251,.16); --warn-soft: rgba(245,184,61,.16);
    --c0: #1FA874; --c1: #8A6CF0; --c2: #BC8418; --c3: #4F95EC; --c4: #D9508F; --c5: #2A9BD0;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #0B0E12; --surface: #12161C; --surface2: #1A2029; --term: #0E1218; --line: #252D38; --dash: #3A4656;
  --fg: #E8ECEF; --muted: #9AA7B4; --accent: #34E0A1; --accent-text: #34E0A1; --accent-ink: #04130D;
  --accent-soft: rgba(52,224,161,.12); --violet: #B39DFB; --violet-text: #C2B0FF; --red: #FF7A7A; --warn: #F5B83D;
  --blue: #7AB8FF; --face: #1E242D; --face-eye: #F2F5F7; --star: #FFFFFF; --device: #1B2040;
  --blue-soft: rgba(122,184,255,.14); --violet-soft: rgba(179,157,251,.16); --warn-soft: rgba(245,184,61,.16);
    --c0: #1FA874; --c1: #8A6CF0; --c2: #BC8418; --c3: #4F95EC; --c4: #D9508F; --c5: #2A9BD0;
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--fg); font-family: var(--sans); line-height: 1.5; font-variant-numeric: tabular-nums;
  transition: background .3s, color .3s; overflow-x: clip; }   /* last safety net only; the cause is fixed where it is */
a { color: inherit; text-decoration: none; }
a:hover { opacity: .85; }
img { max-width: 100%; height: auto; }
button { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 6px; }
.mono { font-family: var(--mono); }
.muted { color: var(--muted); }
.accent { color: var(--accent-text); }
.violet { color: var(--violet-text); }
.red { color: var(--red); }
.warn { color: var(--warn); }
.blue { color: var(--blue); }
.wrap { max-width: 1200px; margin: 0 auto; padding-inline: 24px; }
.wrap-wide { max-width: 1320px; margin: 0 auto; padding-inline: 24px; }
.skip { position: absolute; left: -999px; top: 8px; background: var(--surface); padding: 8px 12px; border-radius: 8px; z-index: 10; }
.skip:focus { left: 8px; }

/* ---------- header ---------- */
.site-header { border-bottom: 1px solid var(--line); position: relative; overflow: hidden; }
.site-header .wrap, .site-header .wrap-wide { padding-block: 18px; display: flex; flex-wrap: wrap; align-items: center; gap: 16px 32px; }
.brand { display: flex; align-items: center; gap: 10px; }
.brand svg { flex: none; }
.brand .mark-fill { fill: var(--accent); }
.brand .mark-stroke { stroke: var(--bg); }
.brand-name { font-family: var(--display); font-weight: 700; font-size: 22px; letter-spacing: -0.02em; }
.brand-tag { font-family: var(--sans); font-size: 11px; color: var(--muted); border: 1px solid var(--line); padding: 2px 6px; border-radius: 6px; }
.nav { display: flex; flex-wrap: wrap; gap: 8px 28px; font-size: 15px; font-weight: 500; flex: 1 1 auto; }
.nav a[aria-current="page"] { color: var(--accent-text); }
.nav a.games[aria-current="page"] { color: var(--violet-text); }
.header-right { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.live-pill { font-family: var(--sans); font-size: 12px; color: var(--muted); white-space: nowrap; }
.theme-btn { height: 44px; padding: 0 14px; border-radius: 22px; border: 1px solid var(--line); background: var(--surface);
  font: 500 14px var(--sans); cursor: pointer; display: inline-flex; align-items: center; gap: 8px; }
.theme-btn .sun { display: none; }
:root[data-theme="dark"] .theme-btn .sun { display: inline; }
:root[data-theme="dark"] .theme-btn .moon { display: none; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .theme-btn .sun { display: inline; }
  :root:not([data-theme="light"]) .theme-btn .moon { display: none; }
}
.scanline { position: absolute; left: 0; right: 0; bottom: 0; height: 1px; background: linear-gradient(90deg, transparent, var(--accent), transparent);
  animation: mt-scan 3.2s linear infinite; }

/* ---------- shared bits ---------- */
.dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; background: var(--accent); vertical-align: middle;
  animation: mt-pulse 1.8s infinite; }
.dot.off { background: var(--warn); animation: none; }
.dot.down { background: var(--red); animation: none; }
.eyebrow { margin: 0; font-family: var(--sans); font-size: 13px; color: var(--accent-text); letter-spacing: .08em; }
.crumbs { margin: 0; font-family: var(--sans); font-size: 13px; color: var(--muted); }
.crumbs .here { color: var(--accent-text); }
.btn { height: 48px; padding: 0 22px; display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  border-radius: 12px; font-weight: 600; font-size: 15px; border: 1px solid transparent; }
.btn-accent { background: var(--accent); color: var(--accent-ink); }
.btn-ghost { border-color: var(--line); }
.btn-ink { background: var(--fg); color: var(--bg); }
.chip { font-family: var(--sans); font-size: 12px; background: var(--surface2); border-radius: 8px; padding: 6px 10px; }
.tag { font-family: var(--sans); font-size: 12px; color: var(--muted); border: 1px solid var(--line); border-radius: 6px; padding: 3px 8px; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; }
.h2 { margin: 8px 0 0; font-family: var(--display); font-size: clamp(30px, 4vw, 40px); letter-spacing: -0.03em; line-height: 1.1; }
.tick-up { animation: mt-flash-up .9s ease-out; }
.tick-down { animation: mt-flash-down .9s ease-out; }
.reconnect { color: var(--warn); }

/* ---------- footer ---------- */
.site-footer { border-top: 1px solid var(--line); }
.site-footer .wrap, .site-footer .wrap-wide { padding-block: 32px 48px; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 16px; font-size: 14px; color: var(--muted); }
.site-footer nav { display: flex; gap: 20px; }
.site-footer nav a:hover { color: var(--fg); }
.site-footer .risk { font-family: var(--sans); font-size: 12px; flex: 1 1 100%; }

/* ---------- home ---------- */
.hero { padding-block: 88px 72px; display: flex; flex-wrap: wrap; gap: 48px; align-items: center; }
.hero-copy { flex: 1 1 480px; min-width: 0; }
.hero h1 { margin: 18px 0 0; font-family: var(--display); font-weight: 700; font-size: clamp(40px, 6vw, 72px); line-height: 1.02; letter-spacing: -0.035em; }
.hero .lead { margin: 24px 0 0; max-width: 520px; font-size: 18px; line-height: 1.6; color: var(--muted); }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 36px; }
.hero-term { flex: 1 1 420px; min-width: 0; background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 22px;
  font-family: var(--sans); animation: mt-float 6s ease-in-out infinite; display: block; }
.hero-term .top { display: flex; justify-content: space-between; align-items: center; gap: 10px; font-size: 12px; color: var(--muted); }
.hero-term .big { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 14px; margin-top: 14px; }
.hero-term .big .num { font-size: 40px; font-weight: 600; letter-spacing: -0.02em; }
.hero-term .big .chg { font-size: 14px; }
.hero-term svg { display: block; margin-top: 12px; width: 100%; height: 120px; }
.mini-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin-top: 14px; }
.mini { border: 1px solid var(--line); border-radius: 10px; padding: 10px; min-width: 0; }
.mini .k { font-size: 11px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mini .v { font-size: 15px; margin-top: 4px; }
.prompt { margin: 14px 0 0; font-size: 12px; color: var(--muted); font-family: var(--mono); }
.caret { color: var(--accent); animation: mt-blink 1s steps(1) infinite; }
.section { padding-block: 40px; }
.section-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: end; gap: 12px; }
.section-head a { font-weight: 600; color: var(--accent-text); }
.bot-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); gap: 20px; margin-top: 28px; }
.bot-card { display: block; padding: 26px; }
.bot-card .row { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.bot-card h3 { margin: 20px 0 6px; font-family: var(--display); font-size: 28px; letter-spacing: -0.02em; }
.bot-card p { margin: 0; color: var(--muted); font-size: 15px; line-height: 1.55; }
.bot-card .chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.bot-card .stat { margin: 16px 0 0; font-family: var(--sans); font-size: 13px; color: var(--fg); }
.bot-card .go { margin: 18px 0 0; font-weight: 600; color: var(--accent-text); }
.live-tag { font-family: var(--sans); font-size: 12px; color: var(--accent-text); white-space: nowrap; }
.game-band { margin-top: 28px; display: flex; flex-wrap: wrap; gap: 28px; padding: 28px; align-items: center; border-radius: 22px; }
.game-band .shot { flex: 1 1 380px; min-width: 0; display: block; border-radius: 16px; overflow: hidden; }
.game-band .shot img { display: block; width: 100%; aspect-ratio: 1288 / 722; object-fit: cover; }
.game-band .copy { flex: 1 1 320px; min-width: 0; }
.game-band .kicker { margin: 0; font-family: var(--sans); font-size: 12px; letter-spacing: .1em; color: var(--violet-text); }
.game-band .copy p.body { margin: 12px 0 0; font-size: 17px; line-height: 1.6; color: var(--muted); }
.game-band .actions { margin-top: 24px; }

/* ---------- apps ---------- */
.page-main { padding-block: 56px 80px; }
.page-title { margin: 12px 0 0; font-family: var(--display); font-size: clamp(36px, 5vw, 56px); letter-spacing: -0.035em; line-height: 1.05; }
.tabs { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 28px; }
.tab { height: 44px; padding: 0 18px; border-radius: 12px; border: 1px solid var(--line); background: transparent; color: var(--muted);
  font: 500 14px var(--sans); display: inline-flex; align-items: center; }
.tab[aria-selected="true"] { border-color: var(--accent); background: var(--accent-soft); color: var(--accent-text); font-weight: 600; }
.tab[disabled] { border-style: dashed; }
.app-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 340px), 1fr)); gap: 24px; margin-top: 32px; }
.app-card { border-radius: 20px; padding: 28px; display: flex; flex-direction: column; gap: 20px; min-width: 0; }
.app-card .top { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; }
.app-card .id { display: flex; align-items: center; gap: 14px; min-width: 0; }
.app-card .icon { width: 52px; height: 52px; border-radius: 14px; flex: none; }
.app-card h2 { margin: 0; font-family: var(--display); font-size: 26px; letter-spacing: -0.02em; }
.app-card .market { margin: 2px 0 0; font-family: var(--sans); font-size: 12px; color: var(--muted); }
.stat3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; font-family: var(--sans); }
.stat3 > div { border: 1px solid var(--line); border-radius: 12px; padding: 12px; min-width: 0; }
.stat3 .k { font-size: 11px; color: var(--muted); }
.stat3 .v { font-size: 18px; margin-top: 6px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.book-rows { display: flex; flex-direction: column; gap: 8px; }
.book-row { display: flex; justify-content: space-between; align-items: center; gap: 10px; padding: 10px 12px; border-radius: 10px;
  background: var(--surface2); font-family: var(--sans); font-size: 13px; }
.book-row span:last-child { color: var(--muted); text-align: right; }
.note { margin: 20px 0 0; font-family: var(--sans); font-size: 12px; color: var(--muted); }

/* ---------- dashboard ---------- */
.dash { font-family: var(--sans); }
.dash-bar .wrap-wide { padding-block: 14px; display: flex; flex-wrap: wrap; align-items: center; gap: 12px 24px; font-family: var(--sans); }
.dash-bar .back { font-weight: 600; font-size: 14px; color: var(--muted); }
.bot-tabs { display: flex; gap: 8px; flex: 1 1 auto; }
.bot-tab { height: 44px; padding: 0 16px; border-radius: 10px; border: 1px solid var(--line); color: var(--muted);
  font: 600 13px var(--sans); display: inline-flex; align-items: center; }
.bot-tab[aria-current="page"] { border-color: var(--accent); background: var(--accent-soft); color: var(--accent-text); }
.dash-main { padding-block: 28px 60px; display: flex; flex-direction: column; gap: 20px; }
.dash-hero { display: flex; flex-wrap: wrap; gap: 24px 40px; align-items: center; justify-content: space-between; }
.dash-id { display: flex; align-items: center; gap: 22px; min-width: 0; }
.face { width: 104px; height: 104px; border-radius: 30px; background: var(--face); border: 2px solid var(--line); display: flex;
  align-items: center; justify-content: center; flex: none; animation: bd-glow 2.4s ease-in-out infinite; }
.face { color: var(--face-eye); } .face.nse { color: #F59E2E; }
.face svg { overflow: visible; }
.face rect { fill: currentColor; transform-origin: center; transform-box: fill-box; animation: bd-eye 4s infinite; }
.dash-id h1 { margin: 0; font-family: var(--display); font-size: clamp(28px, 3.6vw, 42px); font-weight: 700; letter-spacing: -0.03em; }
.dash-id h1 .sub { display: block; font-family: var(--sans); font-size: 15px; font-weight: 500; letter-spacing: 0; color: var(--muted); }
.dash-id .ver { font-size: 12px; border: 1px solid var(--line); border-radius: 8px; padding: 4px 8px; color: var(--muted); }
.dash-id .title-row { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.run-line { margin: 10px 0 0; font-size: 15px; font-weight: 500; color: var(--accent-text); }
.run-line.reconnect { color: var(--warn); }
.run-line .dot { margin-right: 10px; width: 9px; height: 9px; }
.exec-chip { margin: 10px 0 0; display: inline-block; font-size: 13px; font-weight: 500; border: 0; background: var(--violet-soft);
  color: var(--violet-text); border-radius: 8px; padding: 6px 10px; max-width: 100%; overflow-wrap: anywhere; }
.big4 { display: grid; grid-template-columns: repeat(2, minmax(0, auto)); gap: 8px 48px; }
.big4 .n { font-family: var(--display); font-size: clamp(30px, 4vw, 52px); font-weight: 700; letter-spacing: -0.03em; line-height: 1.15; }
.big4 .l { font-size: 13px; font-weight: 500; color: var(--muted); }
.dash-cols { display: flex; flex-wrap: wrap; gap: 20px; align-items: flex-start; }
.strategies { flex: 1 1 300px; min-width: 0; display: flex; flex-direction: column; gap: 12px; }
.label-row { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; color: var(--muted); }
.strat { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 16px 18px; transition: border-color .3s; }
.strat.active { border: 1px solid var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.strat .row { display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.strat .who { display: flex; align-items: center; gap: 12px; min-width: 0; }
.strat .ic { width: 38px; height: 38px; border-radius: 10px; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 13px; flex: none; }
/* one colour per book (by name, dashboard.js COLOR), six validated slots */
.ic-0 { background: color-mix(in srgb, var(--c0) 13%, transparent); color: var(--c0); }
.ic-1 { background: color-mix(in srgb, var(--c1) 13%, transparent); color: var(--c1); }
.ic-2 { background: color-mix(in srgb, var(--c2) 13%, transparent); color: var(--c2); }
.ic-3 { background: color-mix(in srgb, var(--c3) 13%, transparent); color: var(--c3); }
.ic-4 { background: color-mix(in srgb, var(--c4) 13%, transparent); color: var(--c4); }
.ic-5 { background: color-mix(in srgb, var(--c5) 13%, transparent); color: var(--c5); }
.strat .nm { font-family: var(--display); font-weight: 700; font-size: 17px; }
.strat.active .nm { color: var(--accent-text); }
.strat .st { font-size: 12px; font-weight: 600; background: var(--surface2); color: var(--muted); border-radius: 999px; padding: 3px 10px; white-space: nowrap; }
.strat.active .st { background: var(--accent-soft); color: var(--accent-text); }
.strat.paused { opacity: .62; }
.strat.paused .st { background: var(--warn-soft); color: var(--warn); }
.strat .desc { margin: 10px 0 0; font-family: var(--sans); font-size: 13px; color: var(--muted); }
.strat .line { margin: 8px 0 0; font-size: 14px; font-weight: 500; overflow-wrap: anywhere; }
.strat .bal { margin: 6px 0 0; font-size: 12px; color: var(--muted); }
.dash-right { flex: 999 1 640px; min-width: 0; display: flex; flex-direction: column; gap: 20px; }
.panel { background: var(--surface); border: 1px solid var(--line); border-radius: 18px; padding: 20px; min-width: 0; }
/* Balance by strategy: start vs now allocation bars, then one card per running strategy */
.split-bars { margin-top: 14px; display: grid; gap: 8px; }
.split-row { display: grid; grid-template-columns: 44px 1fr; align-items: center; gap: 10px; }
.split-l { font-size: 12px; color: var(--muted); }
.split-bar { display: flex; height: 22px; border-radius: 7px; overflow: hidden; background: var(--surface2); gap: 2px; }
.split-bar span { display: flex; align-items: center; justify-content: center; min-width: 0; font-size: 11px; font-weight: 600;
  color: #fff; white-space: nowrap; overflow: hidden; transition: flex-grow .8s ease; }
.sw-0 { background: var(--c0); } .sw-1 { background: var(--c1); } .sw-2 { background: var(--c2); }
.sw-3 { background: var(--c3); } .sw-4 { background: var(--c4); } .sw-5 { background: var(--c5); }
.split-bar [class^="sw-"] { color: #FFFFFF; }
.split-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 12px; margin-top: 16px; }
.split-card { border: 1px solid var(--line); border-radius: 14px; padding: 14px 16px; min-width: 0; }
.split-card .nm { display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; color: var(--muted); }
.split-card .nm i { width: 10px; height: 10px; border-radius: 3px; flex: none; }
.split-card .nm .tag { margin-left: auto; font-size: 11px; font-weight: 600; border-radius: 999px; padding: 2px 8px; white-space: nowrap; flex: none; line-height: 1.5; background: var(--accent-soft); color: var(--accent-text); }
.split-card .nm span:nth-child(2) { min-width: 0; }
.split-grid[data-n="6"], .split-grid[data-n="3"] { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.split-grid[data-n="4"] { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 1000px) { .split-grid[data-n="4"] { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.split-card .bal { font-family: var(--display); font-size: 24px; font-weight: 700; letter-spacing: -0.02em; margin-top: 6px; font-variant-numeric: tabular-nums; }
.split-card .chg { font-size: 14px; font-weight: 600; font-variant-numeric: tabular-nums; }
.split-card .meta { margin: 8px 0 0; font-size: 12px; color: var(--muted); line-height: 1.6; white-space: pre-line; }
@media (max-width: 640px) {
  .split-grid, .split-grid[data-n] { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  .split-card { padding: 12px; }
  .split-card .nm { font-size: 11px; gap: 6px; flex-wrap: wrap; }
  .split-card .nm .tag { margin-left: 0; }
  .split-card .bal { font-size: 18px; }
  .split-card .chg { font-size: 12px; }
  .split-card .meta { font-size: 11px; }
  .split-row { grid-template-columns: 34px 1fr; gap: 8px; }
}
.watch-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; margin-top: 16px; }
.watch { border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; min-width: 0; transition: border-color .4s; }
.watch.hot { border-color: var(--accent); }
.watch .row { display: flex; justify-content: space-between; align-items: center; gap: 8px; }
.watch .sym { font-weight: 600; font-size: 16px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.watch .pip { width: 8px; height: 8px; border-radius: 50%; flex: none; }
.watch .nt { font-size: 12px; color: var(--muted); margin-top: 4px; }
.watch-empty { margin: 16px 0 0; font-size: 13px; color: var(--muted); }
  justify-content: center; color: var(--muted); font-weight: 700; font-size: 12px; transition: all .3s; }
.orb-wrap { position: relative; margin-top: 8px; }
.orb { display: block; width: 100%; height: clamp(240px, 30vw, 330px); }
.orb-cap { margin: 0; text-align: center; font-size: 14px; font-weight: 500; color: var(--muted); }
.orb-cap .dot { margin-right: 8px; }
.orb-sub { margin: 4px 0 0; text-align: center; font-size: 12px; color: var(--muted); min-height: 1.4em; }
.stat4 { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 10px; margin-top: 20px; }
.stat4 > div { border: 1px solid var(--line); border-radius: 12px; padding: 12px 14px; min-width: 0; }
.stat4 .k { font-size: 12px; font-weight: 600; }
.stat4 .v { font-family: var(--display); font-size: 24px; font-weight: 700; margin-top: 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.stat4 .s { font-size: 12px; color: var(--muted); overflow-wrap: anywhere; }
.pair { display: flex; flex-wrap: wrap; gap: 20px; }
.pair > section { flex: 1 1 320px; min-width: 0; }
.pair > section.log { flex: 1 1 360px; }
/* Today's events fills its card (28 Nov 2026): the card stretches to the Open trades card's height (at least 420px);
   the list takes the space left and scrolls inside it. height: 0 keeps the list's own length out of the row height. */
section.panel.log { display: flex; flex-direction: column; min-height: 420px; }
section.panel.log > .log-head, section.panel.log > .log-jump, section.panel.log > .caret { flex: none; }
section.panel.log > .log-jump { align-self: flex-start; }
/* The live log is the one terminal on the site: mono, always dark, neon colours. */
/* The live log: a terminal, mono with neon colours in dark, ink colours on a pale terminal in light (28 Nov 2026). */
.log { --n-bg: #F4F8F6; --n-line: #D3E1DA; --n-fg: #13281F; --n-dim: #5A7066; --n-green: #08754F; --n-cyan: #0E7490; --n-pink: #A8307A;
  --n-amber: #8A5A00; --n-red: #B4301F; --n-violet: #5A38CF; --n-glow: 0px; --n-thumb: #C3D3CB;
  background: var(--n-bg) !important; border-color: var(--n-line) !important; color: var(--n-fg); font-family: var(--mono); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .log { --n-bg: #070B0A; --n-line: #18231F; --n-fg: #C9F7E3; --n-dim: #6F8F84; --n-green: #39FF9F; --n-cyan: #3DE7FF; --n-pink: #FF5FD2; --n-amber: #FFD23F; --n-red: #FF4D6D; --n-violet: #B388FF; --n-glow: 6px; --n-thumb: #22352E; box-shadow: inset 0 0 40px rgba(57,255,159,.05); } }
:root[data-theme="dark"] .log { --n-bg: #070B0A; --n-line: #18231F; --n-fg: #C9F7E3; --n-dim: #6F8F84; --n-green: #39FF9F; --n-cyan: #3DE7FF; --n-pink: #FF5FD2; --n-amber: #FFD23F; --n-red: #FF4D6D; --n-violet: #B388FF; --n-glow: 6px; --n-thumb: #22352E; box-shadow: inset 0 0 40px rgba(57,255,159,.05); }
.log .accent, .log .caret { color: var(--n-green); }
.log .muted, .log .log-line .why { color: var(--n-dim); }
.log .k-entry { color: var(--n-violet); } .log .k-exit-win { color: var(--n-green); } .log .k-exit-loss { color: var(--n-red); }
.log .k-arm { color: var(--n-amber); } .log .k-order { color: var(--n-cyan); } .log .k-skip { color: var(--n-pink); }
.log .accent, .log .caret, .log .k-entry, .log .k-exit-win, .log .k-exit-loss, .log .k-arm, .log .k-order {
  text-shadow: 0 0 var(--n-glow) color-mix(in srgb, currentColor 55%, transparent); }
.open-badge { background: var(--accent-soft); color: var(--accent-text); border-radius: 999px; padding: 3px 10px; font-weight: 600; }
.open-badge.flat { background: var(--surface2); color: var(--muted); }
.trade + .trade { margin-top: 18px; padding-top: 18px; border-top: 1px solid var(--line); }
.trade .head { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; margin-top: 14px; }
.trade .sym { font-family: var(--display); font-size: 28px; font-weight: 700; letter-spacing: -0.02em; overflow-wrap: anywhere; }
.trade .side { font-size: 12px; font-weight: 600; background: var(--violet-soft); color: var(--violet-text); border-radius: 999px; padding: 3px 10px; text-transform: capitalize; }
.trade .pnl { margin-left: auto; font-size: 22px; font-weight: 600; }
.trade dl { margin: 16px 0 0; display: grid; grid-template-columns: 96px 1fr; gap: 8px 12px; font-size: 15px; }
.trade dt { color: var(--muted); }
.trade dd { margin: 0; overflow-wrap: anywhere; }
.trade .mg { margin: 10px 0 0; text-align: right; font-size: 14px; font-weight: 600; color: var(--muted); font-variant-numeric: tabular-nums; }
.trade .why { margin: 14px 0 0; font-size: 13px; line-height: 1.6; overflow-wrap: anywhere; }
.trade .why b { color: var(--muted); font-weight: 600; margin-right: 4px; }
.flat-msg { margin: 16px 0 0; font-size: 14px; color: var(--muted); }
.log-head { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 4px 10px; font-size: 13px; }
.log-lines { margin-top: 14px; display: flex; flex-direction: column; gap: 10px; font-size: 13px;
  flex: 1 1 auto; height: 0; min-height: 0; overflow-y: auto; overscroll-behavior: contain; padding-right: 6px;
  scrollbar-width: thin; scrollbar-color: var(--n-line) transparent; }
.log-lines::-webkit-scrollbar { width: 6px; }
.log-lines::-webkit-scrollbar-thumb { background: var(--n-thumb); border-radius: 3px; }
.log-day { color: var(--n-dim); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; display: flex; align-items: center; gap: 10px; }
.log-day::after { content: ""; flex: 1; border-top: 1px dashed var(--n-line); }
.log-jump { margin-top: 10px; font: inherit; font-size: 12px; color: var(--n-bg); background: var(--n-green); border: 0; border-radius: 999px; padding: 4px 12px; cursor: pointer; }
.log-line .meta { overflow-wrap: anywhere; }
.log-line .why { color: var(--muted); padding-left: 52px; overflow-wrap: anywhere; }
.log-line.new { animation: bd-in .45s ease-out; }
.k-entry { color: var(--violet); } .k-exit-win { color: var(--accent-text); } .k-exit-loss { color: var(--red); }
.k-arm { color: var(--warn); } .k-order { color: var(--blue); } .k-skip { color: var(--muted); }
.eq-plot { position: relative; margin-top: 12px; touch-action: pan-y; cursor: crosshair; -webkit-user-select: none; user-select: none; outline: none; border-radius: 6px; }
.eq-plot:focus-visible { box-shadow: 0 0 0 2px var(--accent); }
.eq svg { display: block; width: 100%; height: 180px; }
.eq-cross { position: absolute; top: 0; bottom: 0; width: 0; border-left: 1px dashed var(--muted); pointer-events: none; }
.eq-pin { position: absolute; width: 12px; height: 12px; margin: -6px 0 0 -6px; border-radius: 50%; background: var(--accent);
  border: 2px solid var(--surface); box-shadow: 0 0 0 4px var(--accent-soft); pointer-events: none; }
.eq-pin.down { background: var(--red); }
.eq-tip { position: absolute; top: 0; transform: translateY(-6px); background: var(--surface2); border: 1px solid var(--line); border-radius: 10px;
  padding: 7px 10px; font-size: 13px; line-height: 1.35; white-space: nowrap; pointer-events: none; box-shadow: 0 6px 20px rgba(0,0,0,.18); z-index: 2; }
.eq-tip b { display: block; font-family: var(--display); font-size: 15px; font-variant-numeric: tabular-nums; }
.eq-tip .chg { font-variant-numeric: tabular-nums; }
.eq-tip .t { color: var(--muted); font-size: 12px; }
.eq-tip .blk { display: block; }
.eq-axis { position: relative; height: 18px; margin-top: 6px; font-size: 11px; color: var(--muted); border-top: 1px solid var(--line); }
.eq-axis span { position: absolute; top: 4px; white-space: nowrap; transform: translateX(-50%); }
.eq-axis span::before { content: ""; position: absolute; left: 50%; top: -5px; height: 4px; border-left: 1px solid var(--line); }
.eq-axis span.first { transform: none; } .eq-axis span.first::before { left: 0; }
.eq-axis span.last { transform: translateX(-100%); } .eq-axis span.last::before { left: 100%; }
.eq .foot { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px; margin-top: 10px; font-size: 15px; }
.eq-line { fill: none; stroke: var(--accent); stroke-width: 2.5; stroke-linejoin: round; vector-effect: non-scaling-stroke; }
.eq-line.down { stroke: var(--red); }
.eq-area { fill: var(--accent-soft); stroke: none; }
.eq-base { stroke: var(--line); stroke-dasharray: 4 6; vector-effect: non-scaling-stroke; }
.eq-line.draw { stroke-dasharray: 2400; animation: bd-draw 1.6s ease-out; }
.dash-note { margin: 0; font-size: 12px; color: var(--muted); }
.past-note { margin: 6px 0 0; font-size: 13px; color: var(--muted); }
.past [data-f="pastsum"] { font-weight: 500; color: var(--fg); }
.past [data-f="pastsum"] b { white-space: nowrap; }
.table-scroll { overflow-x: auto; margin-top: 14px; -webkit-overflow-scrolling: touch; }
.past-table { width: 100%; border-collapse: collapse; font-size: 14px; min-width: 720px; }
.past-table th, .past-table td { text-align: left; padding: 12px 10px; border-top: 1px solid var(--line); vertical-align: top; white-space: nowrap; }
.past-table thead th { border-top: 0; font-size: 12px; font-weight: 600; color: var(--muted); padding-top: 0; }
.past-table .num { text-align: right; }
.past-table tbody th { font-weight: 600; white-space: normal; min-width: 180px; }
.past-table .pn { display: block; }
.past-table .pd { display: block; font-size: 12px; font-weight: 400; color: var(--muted); }
.pill { display: inline-block; font-size: 12px; font-weight: 600; border-radius: 999px; padding: 2px 10px; }
.pill.paused { background: var(--warn-soft); color: var(--warn); }
.pill.retired { background: var(--surface2); color: var(--muted); }
@media (max-width: 640px) {
  .past-table { min-width: 0; }
  .past-table thead { display: none; }
  .past-table, .past-table tbody { display: block; }
  .past-table tr { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 16px; padding: 14px 0; border-top: 1px solid var(--line); }
  .past-table th, .past-table td { display: block; padding: 0; border: 0; white-space: normal; text-align: left; }
  .past-table tbody th { grid-column: 1 / -1; min-width: 0; }
  .past-table .num { text-align: left; }
  .past-table td::before { content: attr(data-label); display: block; font-size: 11px; font-weight: 600; color: var(--muted); }
}

/* ---------- game ---------- */
.game-hero { position: relative; overflow: hidden; border-bottom: 1px solid var(--line); }
.game-hero .sky { position: absolute; inset: 0; width: 100%; height: 100%; }
.game-hero .sky circle.st { fill: var(--star); animation: ns-twinkle 3s ease-in-out infinite; }
.game-hero .sky circle.orbit { fill: none; stroke: var(--violet); stroke-opacity: .3; stroke-dasharray: 3 12;
  transform-origin: center; transform-box: fill-box; animation: ns-spin 40s linear infinite; }
.game-hero .inner { position: relative; padding-block: 64px 72px; display: flex; flex-wrap: wrap; gap: 40px; align-items: center; }
.game-hero .copy { flex: 1 1 380px; min-width: 0; }
.game-hero .kicker { margin: 22px 0 0; font-family: var(--sans); font-size: 13px; letter-spacing: .1em; color: var(--violet-text); }
.game-hero h1 { margin: 10px 0 0; font-family: var(--display); font-weight: 700; font-size: clamp(44px, 6.5vw, 80px); line-height: .98; letter-spacing: -0.045em; }
.game-hero .lead { margin: 22px 0 0; max-width: 460px; font-size: 18px; line-height: 1.6; color: var(--muted); }
.game-hero .fine { margin: 18px 0 0; font-size: 14px; color: var(--muted); }
.device-wrap { flex: 1 1 560px; min-width: 0; }
.device { border-radius: 28px; padding: 12px; background: var(--device); box-shadow: 0 30px 60px -30px rgba(0,0,0,.5); animation: ns-float 6s ease-in-out infinite; }
.device img { display: block; width: 100%; aspect-ratio: 1288 / 722; object-fit: cover; border-radius: 18px; }
.device img.fade { animation: ns-fade .4s ease-out; }
.crumbs .here-v { color: var(--violet-text); }
.shots { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr)); gap: 18px; margin-top: 22px; }
.shots button { padding: 0; border-radius: 16px; border: 1px solid var(--line); background: transparent; cursor: pointer; overflow: hidden; }
.shots button[aria-pressed="true"] { border: 3px solid var(--violet); }
.shots img { display: block; width: 100%; aspect-ratio: 1288 / 722; object-fit: cover; }
.facts { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr)); gap: 18px; margin-top: 48px; }
.facts > div { padding: 22px; }
.facts .k { margin: 0; font-family: var(--sans); font-size: 12px; color: var(--violet-text); }
.facts .v { margin: 8px 0 0; font-size: 17px; }

/* ---------- legal ---------- */
.legal { max-width: 820px; }
.legal h1 { margin: 12px 0 32px; font-family: var(--display); font-size: clamp(34px, 5vw, 48px); letter-spacing: -0.03em; }
.legal section { margin-bottom: 32px; }
.legal h2 { font-family: var(--display); font-size: 22px; margin: 0 0 12px; letter-spacing: -0.01em; }
.legal h3 { font-size: 17px; margin: 18px 0 8px; }
.legal h4 { font-size: 15px; margin: 0 0 6px; }
.legal p, .legal li { color: var(--muted); line-height: 1.7; }
.legal ul, .legal ol { padding-left: 22px; }
.legal li + li { margin-top: 4px; }
.legal strong { color: var(--fg); }
.legal section > div { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 14px 18px; margin: 12px 0; }
.legal section > div > div { border-left: 3px solid var(--accent); padding-left: 14px; margin: 10px 0; }
.legal section > div p { margin: 4px 0; }

/* ---------- 404 ---------- */
.lost { padding-block: 120px; text-align: center; }
.lost h1 { font-family: var(--display); font-size: clamp(40px, 6vw, 64px); margin: 10px 0; letter-spacing: -0.03em; }

/* ---------- motion ---------- */
@keyframes mt-pulse { 0% { box-shadow: 0 0 0 0 rgba(52,224,161,.55); } 70% { box-shadow: 0 0 0 10px rgba(52,224,161,0); } 100% { box-shadow: 0 0 0 0 rgba(52,224,161,0); } }
@keyframes mt-float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
@keyframes mt-scan { 0% { transform: translateX(-100%); } 100% { transform: translateX(100%); } }
@keyframes mt-blink { 0%, 49% { opacity: 1; } 50%, 100% { opacity: 0; } }
@keyframes mt-flash-up { 0% { color: var(--accent-text); } 100% { color: inherit; } }
@keyframes mt-flash-down { 0% { color: var(--red); } 100% { color: inherit; } }
@keyframes bd-move { from { background-position: 0 0; } to { background-position: 28px 0; } }
@keyframes bd-in { from { opacity: 0; transform: translateX(-8px); } to { opacity: 1; transform: none; } }
@keyframes bd-glow { 0%, 100% { filter: none; } 50% { filter: drop-shadow(0 0 10px rgba(52,224,161,.55)); } }
@keyframes bd-draw { from { stroke-dashoffset: 2400; } to { stroke-dashoffset: 0; } }
@keyframes bd-eye { 0%, 92%, 100% { transform: scaleY(1); } 95% { transform: scaleY(.1); } }
@keyframes ns-twinkle { 0%, 100% { opacity: .25; } 50% { opacity: 1; } }
@keyframes ns-float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }
@keyframes ns-spin { from { transform: rotate(0); } to { transform: rotate(360deg); } }
@keyframes ns-fade { from { opacity: .2; } to { opacity: 1; } }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}

/* ---------- phone ---------- */
@media (max-width: 640px) {
  .wrap, .wrap-wide { padding-inline: 16px; }
  .site-header .wrap, .site-header .wrap-wide { gap: 12px 20px; }
  .brand-tag { display: none; }
  .nav { order: 3; flex-basis: 100%; gap: 8px 22px; }
  .header-right { margin-left: auto; }
  .live-pill { display: none; }
  .hero { padding-block: 48px 40px; gap: 32px; }
  .hero-term .big .num { font-size: 32px; }
  .mini .v { font-size: 13px; }
  .bot-card, .app-card { padding: 20px; }
  .game-band { padding: 18px; }
  .dash-id { gap: 14px; }
  .face { width: 72px; height: 72px; border-radius: 22px; }
  .face svg { width: 38px; height: 28px; }
  .big4 { gap: 8px 28px; width: 100%; }
  .stage { flex: 1 1 33%; }
  .stage .node { width: 64px; }
  .stage .circle { width: 44px; height: 44px; }
  .stage .link { display: none; }
  .log-line .why { padding-left: 0; }
  .trade dl { grid-template-columns: 72px 1fr; }
  .stat3 .v { font-size: 15px; }
}
.eq-dot { fill: var(--accent); }
.eq-dot.down, .eq-area.down { fill: var(--red); }
.eq-area.down { opacity: .12; }
.watch.new { animation: bd-in .45s ease-out; }

/* ---------- daily P&L bars (26 Nov 2026) ---------- */
:root { --s-us: #1F5FB4; --s-ot: #93580A; }             /* validated pair: CVD dE 24, normal 26 (light) */
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { --s-us: #4F95EC; --s-ot: #BC8418; } }
:root[data-theme="dark"] { --s-us: #4F95EC; --s-ot: #BC8418; }                    /* dark: dE 27 / 28 */
/* screen-reader only. Use on a block (div/span), never on a <table>: a table ignores width: 1px and keeps its
   content width, which once pushed the dashboards 100px past a phone screen (26 Nov 2026). */
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; border: 0; }
table.sr-only { display: block; }
.daily { position: relative; }
.dl-legend { display: flex; flex-wrap: wrap; gap: 6px 16px; margin-top: 10px; font-size: 13px; color: var(--muted); }
.dl-legend .sw { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 6px; vertical-align: -1px; }
.sw.us { background: var(--s-us); } .sw.ot { background: var(--s-ot); }
.dl-scroll { overflow-x: auto; margin-top: 10px; -webkit-overflow-scrolling: touch; }
.dl-chart { position: relative; display: flex; gap: 2px; min-width: 510px; outline: none; border-radius: 6px;
  touch-action: pan-x pan-y; -webkit-user-select: none; user-select: none; }
.dl-chart:focus-visible { box-shadow: 0 0 0 2px var(--accent); }
.dl-col { flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; align-items: stretch; border-radius: 8px; cursor: default; }
.dl-col.on { background: var(--surface2); }
.dl-val { height: 18px; line-height: 18px; text-align: center; font-size: 11px; font-weight: 600; font-variant-numeric: tabular-nums;
  white-space: nowrap; color: var(--muted); }
.dl-val.up { color: var(--accent-text); } .dl-val.down { color: var(--red); }
.dl-plot { position: relative; height: 150px; }
.dl-seg { position: absolute; left: 22%; right: 22%; max-width: 28px; margin: 0 auto; }
.dl-seg.us { background: var(--s-us); } .dl-seg.ot { background: var(--s-ot); }
.dl-seg.end.pos { border-radius: 4px 4px 0 0; } .dl-seg.end.neg { border-radius: 0 0 4px 4px; }
.dl-zero { position: absolute; left: 0; right: 0; height: 0; border-top: 1px solid var(--dash); pointer-events: none; z-index: 1; }
.dl-day { text-align: center; font-size: 11px; color: var(--muted); font-variant-numeric: tabular-nums; margin-top: 4px; line-height: 14px; }
.dl-day .m { display: block; min-height: 14px; }
.dl-col.today .dl-day { color: var(--fg); font-weight: 600; }
.dl-tip { position: absolute; z-index: 3; pointer-events: none; background: var(--surface2); border: 1px solid var(--line); border-radius: 10px;
  padding: 8px 10px; font-size: 13px; min-width: 170px; box-shadow: 0 6px 20px rgba(0,0,0,.12); }
.dl-tip .t { color: var(--muted); font-size: 12px; }
.dl-tip b { display: block; font-family: var(--display); font-size: 15px; font-variant-numeric: tabular-nums; }
.dl-tip .row { display: flex; justify-content: space-between; gap: 12px; font-variant-numeric: tabular-nums; }
.dl-tip .row .sw { display: inline-block; width: 9px; height: 9px; border-radius: 2px; margin-right: 6px; }
.dl-note { margin: 10px 0 0; font-size: 12px; color: var(--muted); }
.mini-grid.two { grid-template-columns: repeat(2, minmax(0, 1fr)); }
/* NSE: one series (no US-session split): no legend, one colour */
.daily.single .dl-legend { display: none; }
.daily.single .dl-seg.ot { background: var(--s-us); }

/* ---------- UI refresh (28 Nov 2026): book-coloured tiles, sparklines, trade bar, log badges, bigger orb ---------- */
.strat { position: relative; overflow: hidden; border-left-width: 3px; }
.strat.bk-0 { border-left-color: var(--c0); --bk: var(--c0); } .strat.bk-1 { border-left-color: var(--c1); --bk: var(--c1); }
.strat.bk-2 { border-left-color: var(--c2); --bk: var(--c2); } .strat.bk-3 { border-left-color: var(--c3); --bk: var(--c3); }
.strat.bk-4 { border-left-color: var(--c4); --bk: var(--c4); } .strat.bk-5 { border-left-color: var(--c5); --bk: var(--c5); }
.strat.active { border-color: var(--bk, var(--accent)); border-left-width: 3px; box-shadow: 0 0 0 3px color-mix(in srgb, var(--bk, var(--accent)) 14%, transparent); }
.strat.active .nm { color: var(--fg); }
.strat.active .st { display: inline-flex; align-items: center; gap: 6px; }
.strat.active .st::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--accent); animation: mt-live 1.6s ease-out infinite; }
.strat.winning { box-shadow: 0 0 0 3px var(--accent-soft), 0 8px 30px -8px color-mix(in srgb, var(--accent) 45%, transparent); }
.strat.winning::after, .strat.losing::after { content: ""; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(120% 80% at 100% 0%, color-mix(in srgb, var(--accent) 10%, transparent), transparent 60%); animation: mt-glow 3s ease-in-out infinite; }
.strat.losing::after { background: radial-gradient(120% 80% at 100% 0%, color-mix(in srgb, var(--red) 8%, transparent), transparent 60%); }
.strat-spark, .hero-spark { height: 28px; margin-top: 10px; }
.strat-spark svg, .hero-spark svg { display: block; width: 100%; height: 100%; overflow: visible; }
.sp-line { fill: none; stroke: var(--accent); stroke-width: 1.8; vector-effect: non-scaling-stroke; stroke-linejoin: round; stroke-linecap: round; }
.sp-area { fill: var(--accent); opacity: .10; }
.sp-dot { fill: var(--accent); }
.down > svg .sp-line { stroke: var(--red); } .down > svg .sp-area, .down > svg .sp-dot { fill: var(--red); }
.hero-spark { width: min(160px, 100%); margin-top: 4px; }
.big4 .n.tick-up { animation: mt-hero-up 1.1s ease-out; } .big4 .n.tick-down { animation: mt-hero-down 1.1s ease-out; }
@keyframes mt-hero-up { 0% { color: var(--accent-text); text-shadow: 0 0 24px color-mix(in srgb, var(--accent) 70%, transparent); } 100% { text-shadow: none; } }
@keyframes mt-hero-down { 0% { color: var(--red); text-shadow: 0 0 24px color-mix(in srgb, var(--red) 60%, transparent); } 100% { text-shadow: none; } }
@keyframes mt-live { 0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--accent) 60%, transparent); } 100% { box-shadow: 0 0 0 8px transparent; } }
@keyframes mt-glow { 0%, 100% { opacity: .55; } 50% { opacity: 1; } }
.trade .pnl.tick-up, .trade .pnl.tick-down { animation-duration: 1.1s; }

/* trade bar: stop -> entry -> now */
.tbar { margin-top: 16px; }
.tb-track { position: relative; height: 8px; border-radius: 4px; background: var(--surface2); }
.tb-fill { position: absolute; top: 0; bottom: 0; border-radius: 4px; transition: left .7s ease, width .7s ease; }
.tb-fill.up { background: color-mix(in srgb, var(--accent) 55%, transparent); }
.tb-fill.down { background: color-mix(in srgb, var(--red) 50%, transparent); }
.tb-stop, .tb-entry { position: absolute; top: -4px; width: 2px; height: 16px; margin-left: -1px; border-radius: 1px; transition: left .7s ease; }
.tb-stop { background: var(--red); } .tb-stop.locked { background: var(--accent); }
.tb-entry { background: var(--muted); }
.tb-now { position: absolute; top: 50%; width: 14px; height: 14px; margin: -7px 0 0 -7px; border-radius: 50%; border: 2px solid var(--surface);
  transition: left .7s ease; }
.tb-now.up { background: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft), 0 0 14px color-mix(in srgb, var(--accent) 60%, transparent); }
.tb-now.down { background: var(--red); box-shadow: 0 0 0 4px color-mix(in srgb, var(--red) 14%, transparent), 0 0 14px color-mix(in srgb, var(--red) 50%, transparent); }
.tb-lab { position: relative; height: 34px; font-size: 11px; color: var(--muted); }
.tb-lab span { position: absolute; top: 8px; transform: translateX(-50%); white-space: nowrap; transition: left .7s ease; }
.tb-lab .l-now { top: 21px; font-weight: 600; }
.tb-lab .l-stop { color: var(--red); }

/* live log: book colour dot, entry / exit as badges */
.log .bk-dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; margin-right: 6px; vertical-align: 1px; box-shadow: 0 0 6px currentColor; }
.log .kb { border: 1px solid currentColor; border-radius: 4px; padding: 0 5px; font-size: 11px; font-weight: 700; letter-spacing: .04em; }
.log .log-line.new { animation: lg-in .55s ease-out; }
@keyframes lg-in { 0% { opacity: 0; transform: translateX(-10px); background: rgba(57,255,159,.10); } 100% { opacity: 1; transform: none; background: transparent; } }


/* ---------- the orb, both dashboards (28 Nov 2026): light and dark, from the --o-* tokens ---------- */
.orbx { --o-bg: #F7F9FC; --o-panel: #FFFFFF; --o-line: #DCE3EC; --o-line2: #CBD5E1; --o-dim: #5E6B7E; --o-text: #334155; --o-hi: #0B1220;
  --o-green: #0B8A5E; --o-cyan: #0E7490; --o-amber: #B45309; --o-gold: #A16207; --o-red: #B4301F; --o-halo: rgba(14,116,144,.07);
  background: radial-gradient(900px 500px at 60% 50%, var(--o-halo), transparent 70%), var(--o-bg) !important;
  border-color: var(--o-line) !important; color: var(--o-text); font-family: var(--mono); font-size: 11px; padding: 14px 16px 16px; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .orbx { --o-bg: #060A12; --o-panel: #0A101C; --o-line: #1A2537; --o-line2: #24324A; --o-dim: #64758E; --o-text: #B9C6D8; --o-hi: #EEF4FF; --o-green: #3DFFA8; --o-cyan: #4CC9F0; --o-amber: #F5B83D; --o-gold: #E3C04F; --o-red: #FF5470; --o-halo: rgba(76,201,240,.06); } }
:root[data-theme="dark"] .orbx { --o-bg: #060A12; --o-panel: #0A101C; --o-line: #1A2537; --o-line2: #24324A; --o-dim: #64758E; --o-text: #B9C6D8; --o-hi: #EEF4FF; --o-green: #3DFFA8; --o-cyan: #4CC9F0; --o-amber: #F5B83D; --o-gold: #E3C04F; --o-red: #FF5470; --o-halo: rgba(76,201,240,.06); }
.ox-top { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 4px 12px; }
.ox-t { color: var(--o-hi); font-size: 12px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; }
.ox-t::before { content: "● "; color: var(--o-cyan); }
.ox-s, .ox-lbl { color: var(--o-dim); font-size: 10px; letter-spacing: .12em; text-transform: uppercase; }
.ox-lbl { margin-bottom: 8px; } .ox-lbl b { color: var(--o-text); font-weight: 600; }
.ox-up { color: var(--o-green); } .ox-down { color: var(--o-red); }
.ox-grid { position: relative; display: grid; grid-template-columns: minmax(200px, 240px) minmax(0, 1fr); gap: 12px; margin-top: 12px; }
.ox-wires { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 1; }
.ox-side { position: relative; z-index: 2; min-width: 0; }
.ox-chans, .ox-stack { display: flex; flex-direction: column; gap: 6px; }
.ox-chan { border-left: 2px solid var(--bk); padding: 5px 8px 6px; border-radius: 0 4px 4px 0;
  background: linear-gradient(90deg, color-mix(in srgb, var(--bk) 10%, transparent), transparent); }
.ox-chan .r1, .ox-chan .r2 { display: flex; justify-content: space-between; gap: 6px; }
.ox-chan .nm { color: var(--o-hi); font-weight: 600; font-size: 10.5px; letter-spacing: .05em; }
.ox-chan .st { font-size: 9px; padding: 0 5px; border-radius: 3px; color: var(--bk); border: 1px solid color-mix(in srgb, var(--bk) 60%, transparent); white-space: nowrap; }
.ox-chan.live .st { background: var(--bk); color: #fff; }
.ox-chans { justify-content: center; height: 100%; }
.ox-chan .sp { height: 22px; margin-top: 3px; }
.ox-chan .sp svg { display: block; width: 100%; height: 100%; overflow: visible; }
.ox-chan .sp polyline { fill: none; stroke: var(--bk); stroke-width: 1.5; vector-effect: non-scaling-stroke; }
.ox-chan .sp polygon { fill: var(--bk); opacity: .14; }
.ox-chan .r2 { font-size: 10px; margin-top: 1px; } .ox-chan .bl { color: var(--o-hi); }
.ox-chan .sb { color: var(--o-dim); font-size: 9.5px; overflow-wrap: anywhere; }
.ox-cell { position: relative; z-index: 0; display: flex; flex-direction: column; }
.ox-orb { display: block; width: 100%; height: clamp(560px, 78vh, 860px); }
.ox-head, .ox-cap, .ox-sub { margin: 0; text-align: center; letter-spacing: .08em; }
.ox-head { color: var(--o-dim); font-size: 11px; text-transform: uppercase; } .ox-head b { color: var(--o-hi); }
.ox-cap { color: var(--o-text); font: 500 13px var(--sans); letter-spacing: 0; } .ox-cap .dot { margin-right: 8px; }
.ox-sub { color: var(--o-dim); font-size: 10px; margin-top: 3px; text-transform: uppercase; } .ox-sub b { color: var(--o-hi); font-weight: 600; }
.ox-empty { margin: 0; color: var(--o-dim); }
@media (max-width: 1100px) {
  .ox-grid { grid-template-columns: minmax(0, 1fr); }
  .ox-wires { display: none; }
  .ox-cell { order: -1; min-height: 0; }
  .ox-orb { height: clamp(380px, 100vw, 640px); }
  .ox-chans { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); }
  .ox-chans { height: auto; }
}
@media (max-width: 640px) {
  .orbx { padding: 12px 8px 14px; }
  .ox-orb { height: clamp(360px, 108vw, 520px); margin-inline: -4px; width: calc(100% + 8px); }
  .ox-chans { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* theme switch on the dashboards: a small round icon button, top right */
.theme-btn.ico { width: 38px; height: 38px; padding: 0; border-radius: 50%; justify-content: center; gap: 0; color: var(--muted); }
.theme-btn.ico:hover { color: var(--fg); }
.theme-btn.ico .label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.dash-bar .theme-btn { margin-left: auto; width: 34px; height: 34px; padding: 0; border-radius: 50%; justify-content: center; gap: 0; color: var(--muted); }
.dash-bar .theme-btn:hover { color: var(--fg); border-color: var(--dash); }
.dash-bar .theme-btn .label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- the bot's face: scanning, looking around, thinking, sleeping (28 Nov 2026) ---------- */
.face .fe, .face .fz, .face .ft { transform-box: view-box; transition: opacity .4s; }
.face .fz text { fill: currentColor; font: 700 11px var(--sans); }
.face .ft circle { fill: currentColor; }
.face .fz, .face .ft { opacity: 0; }
/* scanning: the eyes sweep along the market, left to right, with a quick blink */
.face.m-scan .fe { animation: fc-dart 2.4s ease-in-out infinite; }
@keyframes fc-dart { 0%, 100% { transform: translateX(-5px); } 45%, 55% { transform: translateX(5px); } }
/* looking around */
.face.m-look .fe { animation: fc-look 4.5s ease-in-out infinite; }
@keyframes fc-look { 0%, 8% { transform: translate(0, 0); } 18%, 32% { transform: translate(-7px, -3px); } 42%, 56% { transform: translate(7px, -4px); }
  66%, 80% { transform: translate(3px, 5px); } 90%, 100% { transform: translate(0, 0); } }
/* thinking: eyes up and to the side, thought bubbles */
.face.m-think .fe { transform: translate(4px, -5px); transition: transform .5s; }
.face.m-think .fe rect { animation: fc-squint 4.5s ease-in-out infinite; }
.face.m-think .ft { opacity: 1; }
.face.m-think .ft circle { animation: fc-bubble 1.5s ease-in-out infinite; transform-box: fill-box; transform-origin: center; }
.face.m-think .ft circle:nth-child(2) { animation-delay: .2s; } .face.m-think .ft circle:nth-child(3) { animation-delay: .4s; }
@keyframes fc-squint { 0%, 100% { transform: scaleY(1); } 40%, 60% { transform: scaleY(.7); } }
@keyframes fc-bubble { 0%, 100% { opacity: .35; transform: scale(.8); } 50% { opacity: 1; transform: scale(1.1); } }
/* sleeping: closed eyes, slow breathing glow, floating z's */
.face.m-sleep { animation: bd-sleep 5s ease-in-out infinite; }
.face.m-sleep .fe { transform: translateY(8px); }
.face.m-sleep .fe rect { animation: none; transform: scaleY(.14); }
.face.m-sleep .fz { opacity: 1; }
.face.m-sleep .fz text { animation: fc-z 3s ease-in-out infinite; opacity: 0; }
.face.m-sleep .fz text:nth-child(2) { animation-delay: 1s; } .face.m-sleep .fz text:nth-child(3) { animation-delay: 2s; }
@keyframes fc-z { 0% { opacity: 0; transform: translate(0, 6px); } 30% { opacity: 1; } 100% { opacity: 0; transform: translate(6px, -8px); } }
@keyframes bd-sleep { 0%, 100% { box-shadow: 0 0 0 0 transparent; } 50% { box-shadow: 0 0 0 6px var(--accent-soft); } }

/* ---------- apps page revamp (28 Nov 2026) ---------- */
.dot.idle { background: var(--muted); animation: none; }
.app-strip { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 24px; font: 500 13px var(--sans); color: var(--muted); }
.app-strip span { border: 1px solid var(--line); border-radius: 999px; padding: 6px 12px; background: var(--surface); }
.app-strip span.on { color: var(--accent-text); border-color: color-mix(in srgb, var(--accent) 45%, var(--line)); }
.app-grid { align-items: start; }
.app-card { gap: 16px; }
.app-card .face { width: 60px; height: 60px; border-radius: 18px; border-width: 1.5px; }
.app-card .face svg { width: 36px; height: 28px; }
.app-when { margin: -4px 0 0; font: 500 13px var(--sans); color: var(--muted); }
.kpi4 { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; font-family: var(--sans); }
.kpi4 > div { border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; min-width: 0; position: relative; }
.kpi4 .k { font-size: 11px; color: var(--muted); line-height: 1.3; }
.kpi4 .kh { display: block; font-size: 10px; opacity: .8; }
.kpi4 .v { font-size: 17px; font-weight: 600; margin-top: 6px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; font-variant-numeric: tabular-nums; }
.kspark { display: block; width: 100%; height: 18px; margin-top: 6px; overflow: visible; }
.kspark path { fill: none; stroke: var(--accent); stroke-width: 1.6; vector-effect: non-scaling-stroke; stroke-linejoin: round; }
.kspark.down path { stroke: var(--red); }
.app-last { margin: 0; font: 13px var(--sans); line-height: 1.5; padding-top: 12px; border-top: 1px dashed var(--line); }
.app-foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 16px; }
.past-link { font: 500 13px var(--sans); color: var(--muted); }
.past-link:hover { color: var(--fg); }
@media (max-width: 520px) {
  .kpi4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .app-card .face { width: 52px; height: 52px; border-radius: 16px; }
}

/* ---------- margin in trades vs free (At a glance, 28 Nov 2026) ---------- */
.mg { margin-top: 12px; border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px; }
.mg-top { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.mg-top .r { text-align: right; }
.mg .k { font-size: 12px; font-weight: 600; color: var(--violet-text); } .mg .r .k { color: var(--accent-text); }
.mg .v { font-family: var(--display); font-size: 24px; font-weight: 700; margin-top: 4px; font-variant-numeric: tabular-nums; }
.mg .s { font-size: 12px; color: var(--muted); }
.mg-bar { height: 10px; border-radius: 6px; background: var(--accent-soft); overflow: hidden; margin-top: 12px; }
.mg-bar span { display: block; height: 100%; width: 0; background: var(--violet); border-radius: 6px 0 0 6px; transition: width .8s ease; }
.mg-rows { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 10px 24px; margin-top: 14px; }
.mg-row { display: grid; grid-template-columns: 10px minmax(0, 1fr) auto; align-items: center; gap: 4px 10px; font-size: 12px; }
.mg-row i { width: 10px; height: 10px; border-radius: 3px; }
.mg-row .n { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mg-row .u { color: var(--muted); font-variant-numeric: tabular-nums; white-space: nowrap; }
.mg-row .u b { color: var(--fg); font-weight: 600; }
.mg-row .rb { grid-column: 2 / -1; height: 6px; border-radius: 4px; background: var(--surface2); overflow: hidden; }
.mg-row .rb span { display: block; height: 100%; width: 0; border-radius: 4px; transition: width .8s ease; }
@media (max-width: 640px) { .mg-top .r { text-align: left; } .mg .v { font-size: 20px; } }

/* phones and narrow windows (the two cards stack): the list keeps its 420px cap */
@media (max-width: 760px) {
  section.panel.log { min-height: 0; }
  .log-lines { flex: none; height: auto; max-height: 420px; }
}

/* shared books (29 Nov 2026): split by strategy inside each book card */
.split-card .strats { margin-top: 10px; border-top: 1px dashed var(--line); padding-top: 8px; display: grid; gap: 6px; }
.split-card .st-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 2px 10px; font-size: 12px; }
.split-card .st-n { font-weight: 600; color: var(--fg); }
.split-card .st-t { grid-column: 1; color: var(--muted); }
.split-card .st-p { grid-column: 2; grid-row: 1 / span 2; align-self: center; font-weight: 600; font-variant-numeric: tabular-nums; }
