:root {
  --bg: #f6f7f9; --panel: #fff; --ink: #0f172a; --muted: #5b6577; --line: #e3e6eb;
  --up: #0f8a5f; --down: #c2364b; --hold: #8a6d1a; --accent: #2f5bd3; --demo: #7a4d00; --demo-bg: #fff4d6;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root { --bg: #0d1117; --panel: #151b23; --ink: #e6e9ee; --muted: #97a1b1; --line: #283140;
    --up: #3fbf8a; --down: #f0707f; --hold: #d9b45a; --accent: #7aa2ff; --demo: #ffd27a; --demo-bg: #3a2b08; }
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 15px/1.5 ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif; }
a { color: inherit; }
.num { font-variant-numeric: tabular-nums; }
.up { color: var(--up); } .down { color: var(--down); } .muted { color: var(--muted); }

.demo-banner { background: var(--demo-bg); color: var(--demo); text-align: center; padding: 8px 16px; font-size: 14px; font-weight: 600; }
header.top { background: var(--panel); border-bottom: 1px solid var(--line); }
header.top .wrap { display: flex; align-items: center; gap: 24px; padding-top: 14px; padding-bottom: 14px; flex-wrap: wrap; }
.brand { font-weight: 800; font-size: 18px; text-decoration: none; letter-spacing: -0.01em; }
nav.links { display: flex; gap: 18px; font-size: 14px; }
nav.links a { text-decoration: none; color: var(--muted); }
nav.links a[aria-current="page"], nav.links a:hover { color: var(--ink); }
.wrap { max-width: 1160px; margin: 0 auto; padding-left: 20px; padding-right: 20px; }
main.wrap { padding-top: 28px; padding-bottom: 28px; }
h1 { font-size: 28px; letter-spacing: -0.02em; margin: 0 0 4px; }
h2 { font-size: 13px; text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); margin: 0 0 14px; font-weight: 650; }
.sub { color: var(--muted); margin: 0 0 22px; font-size: 14px; }

.panel { background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 20px; margin-bottom: 20px; }
.grid { display: grid; gap: 16px; }
.g4 { grid-template-columns: repeat(4, 1fr); } .g3 { grid-template-columns: repeat(3, 1fr); } .g2 { grid-template-columns: repeat(2, 1fr); }
@media (max-width: 860px) { .g4 { grid-template-columns: repeat(2, 1fr); } .g3, .g2 { grid-template-columns: 1fr; } }
.stat { background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 16px; }
.stat .k { font-size: 12px; color: var(--muted); } .stat .v { font-size: 22px; font-weight: 650; margin-top: 2px; } .stat .s { font-size: 12px; color: var(--muted); }

.card { display: block; border: 1px solid var(--line); border-radius: 12px; padding: 16px; text-decoration: none; transition: border-color .15s; }
.card:hover { border-color: var(--accent); }
.card .row { display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; }
.coin { display: flex; align-items: center; gap: 10px; }
.coin img { width: 24px; height: 24px; border-radius: 50%; }
.coin .sym { font-weight: 700; text-transform: uppercase; } .coin .nm { font-size: 12px; color: var(--muted); }

.badge { display: inline-block; white-space: nowrap; border-radius: 999px; font-size: 12px; font-weight: 700; padding: 2px 9px; border: 1px solid; }
.badge.sb { background: var(--up); border-color: var(--up); color: #fff; } .badge.b { color: var(--up); }
.badge.h { color: var(--hold); } .badge.s { color: var(--down); } .badge.ss { background: var(--down); border-color: var(--down); color: #fff; }
.badge.lg { font-size: 14px; padding: 4px 12px; }

.toolbar { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; justify-content: space-between; margin-bottom: 14px; }
input[type=search] { background: var(--panel); color: var(--ink); border: 1px solid var(--line); border-radius: 10px; padding: 9px 12px; min-width: 240px; font: inherit; font-size: 14px; }
input[type=search]:focus { outline: none; border-color: var(--accent); }
.seg { display: inline-flex; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; }
.seg button { background: transparent; color: var(--muted); border: 0; padding: 7px 12px; font: inherit; font-size: 13px; cursor: pointer; }
.seg button[aria-pressed="true"] { background: var(--accent); color: #fff; }

.tablewrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th { text-align: left; font-size: 11px; text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); font-weight: 600; padding: 8px 10px; border-bottom: 1px solid var(--line); white-space: nowrap; }
th.sortable { cursor: pointer; user-select: none; } th.sortable:hover { color: var(--ink); }
td { padding: 10px; border-bottom: 1px solid var(--line); white-space: nowrap; }
tr:last-child td { border-bottom: 0; } tbody tr:hover { background: var(--bg); }
.r { text-align: right; }
.star { background: none; border: 0; cursor: pointer; font-size: 17px; color: var(--muted); padding: 0 2px; line-height: 1; }
.star[aria-pressed="true"] { color: #e0a800; }
.meter { display: inline-flex; align-items: center; gap: 8px; } .meter b { width: 26px; text-align: right; }
.bar { position: relative; display: inline-block; width: 64px; height: 6px; background: var(--line); border-radius: 99px; overflow: hidden; }
.bar i { position: absolute; inset: 0 auto 0 0; background: var(--accent); border-radius: 99px; }

.note { font-size: 12px; color: var(--muted); }
.alert { border: 1px solid var(--down); color: var(--down); border-radius: 12px; padding: 14px 16px; margin-bottom: 20px; }
.alert.warn { border-color: var(--hold); color: var(--hold); }
dl.kv { display: grid; grid-template-columns: 1fr auto; gap: 8px 20px; margin: 0; font-size: 14px; }
dl.kv dt { color: var(--muted); } dl.kv dd { margin: 0; text-align: right; font-weight: 600; font-variant-numeric: tabular-nums; }
ul.points { list-style: none; padding: 0; margin: 0; font-size: 14px; } ul.points li { padding-left: 16px; position: relative; margin-bottom: 8px; }
ul.points li::before { content: ""; position: absolute; left: 0; top: 8px; width: 6px; height: 6px; border-radius: 50%; background: var(--muted); }
ul.points.pro li::before { background: var(--up); } ul.points.con li::before { background: var(--down); }
.part { margin-bottom: 12px; font-size: 14px; } .part .row { display: flex; justify-content: space-between; } .part .bar { width: 100%; margin-top: 4px; }
.hero { display: flex; justify-content: space-between; align-items: flex-end; gap: 20px; flex-wrap: wrap; margin-bottom: 20px; }
.scorebox { display: flex; gap: 26px; background: var(--panel); border: 1px solid var(--line); border-radius: 14px; padding: 14px 20px; }
.scorebox .k { font-size: 12px; color: var(--muted); } .scorebox .v { font-size: 26px; font-weight: 700; }
#chart { height: 360px; }
footer.wrap { color: var(--muted); font-size: 12px; padding-bottom: 40px; }
.loading { color: var(--muted); padding: 30px 0; text-align: center; }

.tabs a { padding: 8px 18px; font-size: 14px; font-weight: 600; color: var(--muted); text-decoration: none; }
.tabs a[aria-selected="true"] { background: var(--accent); color: #fff; }
code { background: var(--bg); padding: 1px 5px; border-radius: 4px; }

/* ---------- bubble map ---------- */
.wrap.wide { max-width: none; }
.seg a { display: inline-block; padding: 7px 12px; font-size: 13px; color: var(--muted); text-decoration: none; }
.seg a[aria-selected="true"] { background: var(--accent); color: #fff; }
nav.links a[aria-current="page"] { font-weight: 700; }
.bubble-page { display: flex; flex-direction: column; height: 100vh; height: 100dvh; overflow: hidden; }
.controls { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; padding-top: 10px; padding-bottom: 10px; border-bottom: 1px solid var(--line); background: var(--panel); }
.controls input[type=search] { min-width: 150px; padding: 7px 10px; }
.controls .spacer { flex: 1; }
#status .alert { margin: 12px 0 0; }
#stage { position: relative; flex: 1; min-height: 320px; background: radial-gradient(ellipse at center, var(--stage-glow), var(--stage)); }
:root { --stage: #eef1f5; --stage-glow: #f8fafc; }
@media (prefers-color-scheme: dark) { :root { --stage: #070a0f; --stage-glow: #111827; } }
#bubbles { position: absolute; inset: 0; width: 100%; height: 100%; touch-action: none; cursor: grab; }
#bubbles.dragging { cursor: grabbing; }
#loading { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; }
#panel { position: absolute; top: 14px; right: 14px; width: 330px; max-height: calc(100% - 28px); overflow: auto; background: var(--panel); border: 1px solid var(--line);
  border-radius: 16px; padding: 18px; box-shadow: 0 12px 40px rgba(0,0,0,.25); }
#panel .close { position: absolute; top: 10px; right: 12px; background: none; border: 0; font-size: 22px; color: var(--muted); cursor: pointer; line-height: 1; }
#panel .chg { display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px; margin: 14px 0; }
#panel .chg div { background: var(--bg); border-radius: 8px; padding: 6px 4px; text-align: center; font-size: 12px; }
#panel .chg b { display: block; font-size: 13px; }
#panel .btn { display: block; text-align: center; background: var(--accent); color: #fff; text-decoration: none; border-radius: 10px; padding: 10px; font-weight: 650; margin-top: 14px; }
footer.mini { font-size: 11px; color: var(--muted); padding-top: 6px; padding-bottom: 6px; border-top: 1px solid var(--line); background: var(--panel); }
footer.mini a { color: inherit; }
@media (max-width: 700px) {
  .controls { gap: 6px; } .controls .seg button, .controls .seg a { padding: 6px 8px; font-size: 12px; }
  #summary { display: none; }
  #panel { top: auto; bottom: 0; right: 0; left: 0; width: auto; max-height: 70%; border-radius: 16px 16px 0 0; }
}
[hidden] { display: none !important; }
.bubble-page > * { width: 100%; margin-left: 0; margin-right: 0; flex-shrink: 0; box-sizing: border-box; }
.bubble-page > #stage { flex: 1 1 auto; }
@media (max-width: 700px) {
  .controls { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
  .controls > * { flex-shrink: 0; }
  .controls input[type=search] { min-width: 120px; }
  .controls .spacer { display: none; }
}

/* ---------- Tradonomix brand ---------- */
:root { --navy: #0b1f4d; --brand-green: #3fa21a; --brand-blue: #1e6fd9; }
@media (prefers-color-scheme: dark) { :root { --navy: #e6ecff; --brand-green: #6fd14a; } }
header.top .navrow { display: flex; align-items: center; gap: 22px; padding-top: 10px; padding-bottom: 10px; }
.brand { display: inline-flex; align-items: center; gap: 8px; font-size: 21px; font-weight: 900; letter-spacing: -0.02em; font-style: italic; }
.brand img { height: 44px; width: auto; display: block; }
.brand .t1 { color: var(--navy); } .brand .t2 { color: var(--brand-green); }
header.top nav.links { flex: 1; overflow-x: auto; scrollbar-width: none; white-space: nowrap; }
.acct { display: flex; gap: 10px; align-items: center; white-space: nowrap; }
.acct .signin { font-size: 14px; color: var(--muted); text-decoration: none; }
.pill { display: inline-block; border: 1px solid var(--line); border-radius: 999px; padding: 6px 14px; font-size: 13px; font-weight: 650; text-decoration: none; }
.pill.join { background: var(--brand-green); border-color: var(--brand-green); color: #fff; }
.btn { display: inline-block; background: var(--brand-green); color: #fff; text-decoration: none; font-weight: 700; border-radius: 12px; padding: 12px 22px; border: 0; font: inherit; font-weight: 700; cursor: pointer; }
.btn.secondary { background: transparent; color: var(--ink); border: 1px solid var(--line); }
@media (max-width: 760px) {
  header.top .navrow { flex-wrap: wrap; gap: 8px 14px; }
  header.top nav.links { order: 3; flex-basis: 100%; }
  .brand img { height: 36px; }
}
footer#site-footer { color: var(--muted); font-size: 12px; padding: 24px 0 40px; border-top: 1px solid var(--line); margin-top: 30px; }
footer#site-footer a { color: inherit; }
.bubble-page footer#site-footer { display: none; }

/* ---------- members-only preview ---------- */
body.is-teaser [data-gated] { filter: blur(6px) saturate(0.8); pointer-events: none; user-select: none; }
.paywall { position: fixed; inset: 0; display: flex; align-items: center; justify-content: center; padding: 20px; z-index: 50; background: rgba(8, 12, 20, 0.25); }
.paywall-card { max-width: 440px; background: var(--panel); border: 1px solid var(--line); border-radius: 20px; padding: 28px; text-align: center; box-shadow: 0 20px 60px rgba(0,0,0,.3); }
.paywall-card h2 { font-size: 22px; text-transform: none; letter-spacing: -0.01em; color: var(--ink); margin: 10px 0 8px; }
.paywall-card p { color: var(--muted); font-size: 14px; }

/* ---------- home ---------- */
.hero { display: grid; grid-template-columns: 1.1fr 1fr; gap: 30px; align-items: center; }
.hero h1 { font-size: 40px; line-height: 1.1; }
.hero .logo-big { width: 100%; max-width: 560px; height: auto; display: block; margin: 0 auto; }
.features { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.feature { background: var(--panel); border: 1px solid var(--line); border-radius: 16px; padding: 18px; }
.feature h3 { margin: 6px 0; font-size: 16px; } .feature p { margin: 0; color: var(--muted); font-size: 14px; }
.feature .ico { font-size: 22px; }
.pricing { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.plan { background: var(--panel); border: 1px solid var(--line); border-radius: 18px; padding: 22px; }
.plan.best { border: 2px solid var(--brand-green); }
.plan .price { font-size: 34px; font-weight: 800; } .plan ul { padding-left: 18px; color: var(--muted); font-size: 14px; }
.plan li { margin-bottom: 6px; }
@media (max-width: 860px) { .hero, .pricing { grid-template-columns: 1fr; } .features { grid-template-columns: 1fr 1fr; } .hero h1 { font-size: 30px; } }
@media (max-width: 520px) { .features { grid-template-columns: 1fr; } }
.chip { display: inline-block; font-size: 11px; font-weight: 700; padding: 2px 8px; border-radius: 999px; background: var(--bg); color: var(--muted); }
.chip.buy { color: var(--up); } .chip.sell { color: var(--down); }
.tabsline { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 14px; }

/* ---------- free Markets page ---------- */
.mood { display: flex; gap: 20px; align-items: center; flex-wrap: wrap; }
.gauge-wrap { position: relative; width: 240px; flex: none; text-align: center; }
.gauge-wrap svg { width: 240px; height: auto; display: block; }
.gauge-label .v { font-size: 24px; font-weight: 800; margin-top: -6px; }
.breadth { height: 6px; background: color-mix(in srgb, var(--down) 55%, var(--line)); border-radius: 99px; overflow: hidden; margin-top: 8px; }
.breadth i { display: block; height: 100%; background: var(--up); }
.heatgroups { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 14px; }
.tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(78px, 1fr)); gap: 6px; margin-top: 4px; }
.tile { display: flex; flex-direction: column; align-items: center; justify-content: center; min-height: 58px; border-radius: 10px; text-decoration: none; color: var(--ink); font-size: 12px; }
.tile b { font-size: 14px; } .tile:hover { outline: 2px solid var(--accent); }
.dbars { display: grid; gap: 8px; }
.dbar { display: grid; grid-template-columns: 120px 1fr 64px; align-items: center; gap: 10px; font-size: 13px; }
.dbar .lbl { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .dbar .num { text-align: right; }
.dbar .track { position: relative; height: 12px; background: var(--bg); border-radius: 6px; }
.dbar .track::after { content: ""; position: absolute; left: 50%; top: -3px; bottom: -3px; width: 1px; background: var(--line); }
.dbar i { position: absolute; top: 0; bottom: 0; border-radius: 6px; }
.dbar i.pos { left: 50%; background: var(--up); } .dbar i.neg { right: 50%; background: var(--down); }
.stack { display: flex; height: 16px; border-radius: 8px; overflow: hidden; background: var(--bg); }
.stack i { display: block; height: 100%; }
.legend { display: flex; flex-wrap: wrap; gap: 8px 14px; margin-top: 10px; font-size: 13px; }
.legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 5px; vertical-align: middle; }
.lockbox { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; margin-top: 14px; padding: 12px 14px;
  border: 1px dashed color-mix(in srgb, var(--brand-green) 60%, var(--line)); border-radius: 12px; background: color-mix(in srgb, var(--brand-green) 6%, var(--panel)); font-size: 13px; }
.lockrow { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.lockcell { display: flex; flex-direction: column; gap: 4px; border: 1px solid var(--line); border-radius: 12px; padding: 12px; text-decoration: none; }
.blurbadge { filter: blur(4px); user-select: none; font-size: 12px; font-weight: 700; color: var(--up); }
@media (max-width: 560px) { .dbar { grid-template-columns: 90px 1fr 56px; } .gauge-wrap { margin: 0 auto; } }

.lock { font-size: 10px; opacity: .55; }

.grid > * { min-width: 0; }
@media (max-width: 560px) {
  .mood { flex-direction: column; align-items: stretch; }
  #breadth { grid-template-columns: repeat(3, 1fr); gap: 8px; }
  #breadth .stat { padding: 10px; } #breadth .v { font-size: 17px; } #breadth .s { font-size: 11px; }
}

body[data-page="markets"] td { white-space: normal; }
body[data-page="markets"] table { table-layout: auto; }

/* ---------- Markets page, round 2 ---------- */
.majors { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.major, .sparkcard { display: block; border: 1px solid var(--line); border-radius: 12px; padding: 12px; text-decoration: none; }
.major:hover, .sparkcard:hover { border-color: var(--accent); }
.spark { display: block; width: 100%; height: 34px; margin-top: 8px; }
.sparkcard .spark { height: 44px; }
.sparks { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 10px; }
.linechart { width: 100%; height: auto; display: block; }
ul.news { list-style: none; margin: 0; padding: 0; }
ul.news li { padding: 8px 0; border-bottom: 1px solid var(--line); font-size: 14px; }
ul.news li:last-child { border-bottom: 0; }
ul.news a { text-decoration: none; font-weight: 600; display: block; } ul.news a:hover { color: var(--accent); }
.earn { display: grid; gap: 10px; }
.erow { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; padding: 6px 0; border-bottom: 1px dashed var(--line); font-size: 14px; }
.erow a { text-decoration: none; }
.hbars { display: grid; gap: 7px; }
.hbar { display: grid; grid-template-columns: 56px 1fr 52px 46px; align-items: center; gap: 8px; font-size: 13px; }
.hbar .track { height: 12px; background: var(--bg); border-radius: 6px; overflow: hidden; }
.hbar .track i { display: block; height: 100%; background: linear-gradient(90deg, var(--brand-blue), var(--brand-green)); border-radius: 6px; }
.hbar .num { text-align: right; }

/* ---------- Pro features ---------- */
table.compare th[scope="row"] { text-transform: none; letter-spacing: 0; font-size: 14px; color: var(--ink); font-weight: 500; white-space: normal; padding: 10px; }
table.compare .c { text-align: center; white-space: normal; font-size: 13px; }
table.compare td.yes { color: var(--up); font-weight: 800; font-size: 16px; } table.compare td.no { color: var(--muted); }
.toast { position: fixed; left: 50%; bottom: 22px; transform: translateX(-50%); z-index: 60; background: var(--ink); color: var(--panel); padding: 12px 18px; border-radius: 12px; font-size: 14px; box-shadow: 0 8px 30px rgba(0,0,0,.25); max-width: 92vw; }
.toast a { color: inherit; font-weight: 700; }
details.menu { position: relative; }
details.menu summary { list-style: none; cursor: pointer; }
details.menu summary::-webkit-details-marker { display: none; }
details.menu summary::after { content: " ▾"; font-size: 11px; }
details.menu .menu-list { position: absolute; right: 0; top: calc(100% + 8px); z-index: 50; min-width: 200px; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 6px; box-shadow: 0 10px 30px rgba(0,0,0,.14); }
details.menu .menu-list a { display: block; padding: 8px 12px; border-radius: 8px; text-decoration: none; color: var(--ink); font-size: 14px; }
details.menu .menu-list a:hover { background: var(--bg); }
.pill.ai { background: var(--accent); color: #fff; border-color: var(--accent); }
.dot { display: inline-flex; align-items: center; justify-content: center; width: 30px; height: 30px; border-radius: 50%; font-size: 11px; font-weight: 700; border: 2px solid var(--line); color: var(--muted); }
.dot.on { background: var(--up); border-color: var(--up); color: #fff; }
.dot.none { border-style: dashed; opacity: .55; }
.radarscore { font-size: 20px; font-weight: 750; }
tr.alert-row td:first-child { box-shadow: inset 3px 0 0 var(--up); }
tr.detail td { white-space: normal; background: var(--bg); font-size: 13px; color: var(--muted); }
.kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin-bottom: 20px; }
@media (max-width: 760px) { .kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.md h3, .md h4 { margin: 14px 0 6px; font-size: 15px; } .md p { margin: 6px 0; } .md ul { margin: 6px 0; padding-left: 20px; } .md li { margin: 3px 0; }
.chat { display: flex; flex-direction: column; gap: 14px; min-height: 260px; }
.msg { max-width: 86%; padding: 12px 16px; border-radius: 14px; font-size: 14.5px; line-height: 1.55; }
.msg.user { align-self: flex-end; background: var(--accent); color: #fff; border-bottom-right-radius: 4px; }
.msg.bot { align-self: flex-start; background: var(--bg); border: 1px solid var(--line); border-bottom-left-radius: 4px; }
.msg .stamp { font-size: 11px; color: var(--muted); margin-top: 8px; }
.ask { display: flex; gap: 10px; margin-top: 16px; }
.ask textarea, .field { flex: 1; font: inherit; font-size: 15px; padding: 11px 14px; border: 1px solid var(--line); border-radius: 12px; background: var(--panel); color: var(--ink); resize: vertical; }
select.field, input.field { flex: initial; padding: 9px 12px; font-size: 14px; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 10px 0 0; }
.chips button { font: inherit; font-size: 13px; padding: 7px 12px; border-radius: 999px; border: 1px solid var(--line); background: var(--panel); color: var(--ink); cursor: pointer; }
.chips button:hover { border-color: var(--accent); }
.locked { position: relative; border: 1px dashed var(--line); border-radius: 14px; padding: 18px; text-align: center; color: var(--muted); }
.locked h3 { color: var(--ink); margin: 0 0 6px; font-size: 16px; }
.rowform { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
button.x { border: 0; background: none; color: var(--muted); cursor: pointer; font-size: 16px; padding: 2px 6px; }
button.x:hover { color: var(--down); }

/* ---- grouped top menu ---- */
header.top nav.links { overflow: visible; flex-wrap: wrap; row-gap: 6px; white-space: nowrap; align-items: center; }
nav.links details.dd summary { color: var(--muted); }
nav.links details.dd summary[aria-current="page"], nav.links details.dd[open] summary, nav.links details.dd summary:hover { color: var(--ink); }
nav.links details.dd summary[aria-current="page"] { font-weight: 700; }
nav.links details.dd .menu-list { left: -10px; right: auto; min-width: 230px; max-width: calc(100vw - 24px); white-space: normal; }
nav.links details.dd .menu-list a[aria-current="page"] { font-weight: 700; background: var(--bg); }
@media (max-width: 760px) { nav.links { gap: 10px 16px; } }

/* ---- Pro tools ---- */
.filters { display: flex; flex-wrap: wrap; gap: 10px 14px; align-items: center; margin-bottom: 10px; }
.filters label { display: inline-flex; gap: 6px; align-items: center; font-size: 13px; color: var(--muted); }
.filters select, .filters input { font: inherit; font-size: 14px; padding: 7px 10px; border: 1px solid var(--line); border-radius: 10px; background: var(--panel); color: var(--ink); max-width: 260px; }
.btn.small { padding: 8px 14px; font-size: 14px; border-radius: 10px; }
.btn.ghost { background: transparent; color: var(--ink); border: 1px solid var(--line); }
.btn[disabled] { opacity: .5; cursor: default; }
.seg.tabs { flex-wrap: wrap; margin: 4px 0 18px; }
.sc { font-weight: 750; font-variant-numeric: tabular-nums; margin-right: 4px; }
.hz { white-space: nowrap; font-size: 12px; color: var(--muted); margin-right: 4px; } .hz .badge { font-size: 11px; }
td.hzs { white-space: normal; min-width: 190px; }
.soon { border-style: dashed; } .soon h3 { margin-top: 0; font-size: 16px; }
.ed { display: inline-block; width: 11px; height: 11px; border-radius: 50%; background: var(--line); margin-right: 4px; }
.ed.up { background: var(--up); } .ed.down { background: var(--down); }
.chip.phase.leading { color: var(--up); } .chip.phase.improving { color: var(--accent); } .chip.phase.weakening { color: var(--hold); } .chip.phase.lagging { color: var(--down); }
.dbar1 { height: 8px; background: var(--line); border-radius: 99px; overflow: hidden; margin-bottom: 2px; }
.dbar1 i { display: block; height: 100%; border-radius: 99px; background: var(--muted); } .dbar1 i.up { background: var(--up); } .dbar1 i.down { background: var(--down); }
.hb { display: flex; justify-content: space-between; gap: 12px; padding: 6px 0; border-bottom: 1px dashed var(--line); font-size: 14px; }
.bigscore { font-size: 54px; font-weight: 800; line-height: 1; margin: 6px 0 10px; font-variant-numeric: tabular-nums; } .bigscore small { font-size: 18px; color: var(--muted); font-weight: 600; }
.warn { color: #b7791f; } .muted { color: var(--muted); }
.panel .meter { display: block; margin-bottom: 12px; } .panel .meter .mrow { display: flex; justify-content: space-between; font-size: 14px; } .panel .meter .bar { width: 100%; display: block; margin: 4px 0 2px; }
table.compare th[scope=row] { text-align: left; color: var(--muted); font-weight: 600; white-space: nowrap; }
table.compare td { white-space: normal; vertical-align: middle; min-width: 140px; } table.compare td.best { background: color-mix(in srgb, var(--up) 12%, transparent); }
.minibar { display: inline-block; width: 70px; height: 6px; background: var(--line); border-radius: 99px; overflow: hidden; vertical-align: middle; margin-right: 6px; } .minibar i { display: block; height: 100%; background: var(--accent); }
tr.past td { opacity: .6; }
.linechart .gl { stroke: var(--line); } .linechart .ax { fill: var(--muted); font-size: 11px; }
.linechart .ln1 { fill: none; stroke: var(--accent); stroke-width: 2.2; } .linechart .ln2 { fill: none; stroke: var(--muted); stroke-width: 1.5; stroke-dasharray: 5 4; }
.inbox li { list-style: none; padding: 10px 0; border-bottom: 1px solid var(--line); } .inbox { padding: 0; margin: 0; } .inbox li.new b::before { content: "● "; color: var(--accent); }
.switch { display: flex; gap: 10px; align-items: flex-start; padding: 8px 0; border-bottom: 1px dashed var(--line); font-size: 14px; } .switch input { margin-top: 3px; }
.horizons { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin: 12px 0; } .horizons > div { border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; }
.horizons .k { font-size: 12px; color: var(--muted); } .horizons b { display: block; font-size: 20px; margin: 2px 0 4px; }
@media (max-width: 520px) { .horizons { grid-template-columns: 1fr; } }
header.top nav.links { gap: 6px 15px; }
.acct .chip { display: none; }
@media (min-width: 1440px) { .acct .chip { display: inline-block; } }
