:root {
  --bg: #f6f4ef; --surface: #ffffff; --surface2: #f0ede6; --ink: #1a1e22; --muted: #5a636d; --line: #e2ddd2;
  --accent: #165e57; --accent-ink: #ffffff; --real: #1c8a6c; --beta: #c0650f; --fee: #8b919a; --loss: #b23a48;
  --before: #a3abb5; --after: #165e57; --sim: #6b4fa0; --focus: #2a6df4;
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, "Book Antiqua", Georgia, serif;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --radius: 12px; color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #101316; --surface: #171b1f; --surface2: #1e2328; --ink: #e7e5e0; --muted: #9ba4ae; --line: #2a3137;
    --accent: #52b5a7; --accent-ink: #0d1a18; --real: #4cc29f; --beta: #e8a052; --fee: #8b919a; --loss: #e57380;
    --before: #8d97a3; --after: #52b5a7; --sim: #a88be0; color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --bg: #101316; --surface: #171b1f; --surface2: #1e2328; --ink: #e7e5e0; --muted: #9ba4ae; --line: #2a3137;
  --accent: #52b5a7; --accent-ink: #0d1a18; --real: #4cc29f; --beta: #e8a052; --fee: #8b919a; --loss: #e57380;
  --before: #8d97a3; --after: #52b5a7; --sim: #a88be0; color-scheme: dark;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 16px/1.55 var(--sans); font-variant-numeric: tabular-nums; }
a { color: var(--accent); }
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 16px; }
.skip { position: absolute; left: -999px; } .skip:focus { left: 8px; top: 8px; background: var(--surface); padding: 6px 10px; z-index: 9; }
.banner { background: var(--ink); color: var(--bg); text-align: center; font-size: 13px; padding: 5px 12px; }
.top { border-bottom: 1px solid var(--line); background: var(--surface); position: sticky; top: 0; z-index: 5; }
.top-in { display: flex; align-items: center; gap: 16px; min-height: 58px; flex-wrap: wrap; }
.brand { display: flex; align-items: baseline; gap: 8px; text-decoration: none; color: var(--ink); font-family: var(--serif); font-size: 21px; font-weight: 600; margin-right: auto; }
.brand small { font-family: var(--sans); font-size: 12px; color: var(--muted); font-weight: 400; }
.logo { width: 18px; height: 18px; border-radius: 5px; background: var(--accent); align-self: center; position: relative; }
.logo::after { content: ""; position: absolute; left: 4px; right: 4px; top: 8px; height: 2px; background: var(--surface); transform: rotate(-30deg); }
.nav { display: flex; gap: 4px; align-items: center; flex-wrap: wrap; }
.nav a { text-decoration: none; color: var(--muted); padding: 6px 10px; border-radius: 8px; font-size: 15px; }
.nav a:hover { color: var(--ink); background: var(--surface2); }
.nav a.on { color: var(--ink); background: var(--surface2); font-weight: 600; }
.theme-btn, .menu-btn { font: inherit; font-size: 14px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); border-radius: 8px; padding: 5px 10px; cursor: pointer; }
.menu-btn { display: none; }
@media (max-width: 760px) {
  .menu-btn { display: block; }
  .nav { display: none; width: 100%; flex-direction: column; align-items: stretch; padding-bottom: 10px; }
  .nav.open { display: flex; }
  .brand small { display: none; }
}
main { padding: 28px 16px 40px; min-height: 60vh; outline: none; }
h1, h2, h3 { font-family: var(--serif); line-height: 1.2; letter-spacing: -0.01em; }
h1 { font-size: clamp(30px, 5vw, 46px); margin: 6px 0 14px; font-weight: 600; }
h2 { font-size: clamp(22px, 3vw, 28px); margin: 36px 0 10px; font-weight: 600; }
h3 { font-size: 19px; margin: 18px 0 8px; font-weight: 600; }
p { margin: 0 0 12px; }
.lede { font-size: 18px; color: var(--muted); max-width: 760px; }
.muted { color: var(--muted); } .small { font-size: 13.5px; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; margin: 14px 0; min-width: 0; }
.grid { display: grid; gap: 14px; }
.g2 { grid-template-columns: repeat(2, minmax(0, 1fr)); } .g3 { grid-template-columns: repeat(3, minmax(0, 1fr)); } .g4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
@media (max-width: 860px) { .g3, .g4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .g2, .g3 { grid-template-columns: minmax(0, 1fr); } }
.stat { padding: 12px 14px; border: 1px solid var(--line); border-radius: 10px; background: var(--surface); min-width: 0; }
.stat .k { font-size: 12.5px; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
.stat .v { font-size: 26px; font-weight: 650; font-family: var(--serif); margin-top: 2px; overflow-wrap: anywhere; }
.stat .d { font-size: 13px; color: var(--muted); }
.pitch { list-style: none; padding: 0; margin: 0 0 8px; counter-reset: p; max-width: 820px; }
.pitch li { counter-increment: p; padding: 8px 0 8px 40px; position: relative; border-top: 1px solid var(--line); }
.pitch li::before { content: counter(p); position: absolute; left: 0; top: 8px; width: 26px; height: 26px; border-radius: 50%; background: var(--surface2); text-align: center; font-size: 14px; line-height: 26px; color: var(--muted); }
.tag { display: inline-block; font-size: 11.5px; padding: 1px 7px; border-radius: 99px; border: 1px solid var(--line); color: var(--muted); white-space: nowrap; vertical-align: 1px; }
.tag.sim { color: var(--sim); border-color: color-mix(in srgb, var(--sim) 45%, transparent); }
.tag.real { color: var(--real); border-color: color-mix(in srgb, var(--real) 45%, transparent); }
.tag.live { color: var(--accent); border-color: color-mix(in srgb, var(--accent) 45%, transparent); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 8px 0; }
.chip { font: inherit; font-size: 14px; border: 1px solid var(--line); background: var(--surface); color: var(--ink); border-radius: 99px; padding: 6px 12px; cursor: pointer; }
.chip[aria-pressed="true"] { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.tabs { display: inline-flex; border: 1px solid var(--line); border-radius: 10px; overflow: hidden; flex-wrap: wrap; }
.tabs button { font: inherit; font-size: 14px; border: 0; background: var(--surface); color: var(--muted); padding: 7px 12px; cursor: pointer; border-right: 1px solid var(--line); }
.tabs button:last-child { border-right: 0; }
.tabs button[aria-pressed="true"] { background: var(--ink); color: var(--bg); }
.row { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.row.sp { justify-content: space-between; }
table { width: 100%; border-collapse: collapse; font-size: 14px; }
th, td { text-align: left; padding: 8px 8px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { font-weight: 600; color: var(--muted); font-size: 12.5px; text-transform: uppercase; letter-spacing: .03em; }
td.n, th.n { text-align: right; white-space: nowrap; }
.tablewrap { overflow-x: auto; -webkit-overflow-scrolling: touch; max-width: 100%; }
@media (max-width: 640px) {
  table.stack thead { display: none; }
  table.stack, table.stack tbody, table.stack tr, table.stack td { display: block; width: 100%; }
  table.stack tr { border-bottom: 1px solid var(--line); padding: 8px 0; }
  table.stack td { border: 0; padding: 3px 0; text-align: left; }
  table.stack td.n { text-align: left; white-space: normal; }
  table.stack td[data-l]::before { content: attr(data-l) ": "; color: var(--muted); font-size: 12.5px; }
}
input[type="number"], select { font: inherit; font-size: 15px; padding: 6px 8px; border: 1px solid var(--line); border-radius: 8px; background: var(--surface); color: var(--ink); max-width: 100%; }
input[type="number"] { width: 130px; text-align: right; }
input[type="range"] { width: 220px; max-width: 100%; accent-color: var(--accent); }
.btn { font: inherit; font-size: 14px; border: 1px solid var(--accent); background: var(--accent); color: var(--accent-ink); border-radius: 8px; padding: 6px 12px; cursor: pointer; }
.btn.ghost { background: transparent; color: var(--accent); }
.xbtn { border: 0; background: transparent; color: var(--muted); cursor: pointer; font-size: 18px; line-height: 1; padding: 2px 6px; }
.costline { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin: 10px 0; }
@media (max-width: 560px) { .costline { grid-template-columns: minmax(0, 1fr); } }
.cost { border-left: 4px solid var(--line); padding: 6px 10px; background: var(--surface2); border-radius: 0 8px 8px 0; min-width: 0; }
.cost .v { font-size: 20px; font-weight: 650; font-family: var(--serif); }
.cost .k { font-size: 13px; color: var(--muted); }
.cost.beta { border-color: var(--beta); } .cost.real { border-color: var(--real); } .cost.fee { border-color: var(--fee); }
.split { display: flex; height: 12px; border-radius: 6px; overflow: hidden; background: var(--surface2); min-width: 60px; }
.split span { display: block; height: 100%; }
.split .r { background: var(--real); } .split .b { background: var(--beta); }
.legend { display: flex; gap: 14px; flex-wrap: wrap; font-size: 13px; color: var(--muted); margin: 4px 0; }
.legend i { display: inline-block; width: 11px; height: 11px; border-radius: 3px; margin-right: 5px; vertical-align: -1px; }
.chart { width: 100%; height: auto; display: block; overflow: visible; }
.chart text:not([fill]) { fill: var(--muted); font-size: 11px; font-family: var(--sans); }
.chart .ax { stroke: var(--line); }
.chart .grid { stroke: var(--line); stroke-dasharray: 2 3; }
.callout { border-left: 4px solid var(--accent); background: var(--surface2); padding: 10px 14px; border-radius: 0 10px 10px 0; margin: 12px 0; }
.loading { padding: 80px 0; text-align: center; color: var(--muted); }
.loading .bar { width: 240px; height: 4px; background: var(--line); margin: 0 auto 12px; border-radius: 2px; overflow: hidden; }
.loading .bar span { display: block; height: 100%; width: 5%; background: var(--accent); transition: width .2s; }
.foot { color: var(--muted); font-size: 13px; padding-top: 18px; padding-bottom: 40px; border-top: 1px solid var(--line); }
.pos-title { font-weight: 550; }
.mono { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 12.5px; }
.bar2 { display: flex; height: 10px; border-radius: 5px; overflow: hidden; background: var(--surface2); width: 120px; }
.bar2 .y { background: var(--accent); } .bar2 .n { background: var(--beta); }
details summary { cursor: pointer; color: var(--accent); }
.kpi-row { display: flex; gap: 10px; flex-wrap: wrap; }
.note { font-size: 13px; color: var(--muted); }
.warn { color: var(--loss); }
.prose { max-width: 780px; }
.prose li { margin-bottom: 6px; }
.hide { display: none !important; }
.holdings td { vertical-align: middle; }
.addrow { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 8px; }
.addrow select { max-width: 260px; }
.timing { font-size: 12px; color: var(--muted); }
.check { display: flex; gap: 6px; align-items: flex-start; font-size: 14px; padding: 4px 0; }
.check input { margin-top: 4px; }
.cols2 { columns: 2; column-gap: 24px; } @media (max-width: 640px) { .cols2 { columns: 1; } }
.blist { max-height: 360px; overflow-y: auto; border: 1px solid var(--line); border-radius: 8px; padding: 6px 10px; }
.badge2 { display: inline-block; font-size: 11.5px; padding: 1px 7px; border-radius: 99px; background: var(--real); color: var(--accent-ink); }
.badge1 { display: inline-block; font-size: 11.5px; padding: 1px 7px; border-radius: 99px; border: 1px solid var(--line); color: var(--muted); }
.verdict { font-size: 18px; font-family: var(--serif); background: var(--surface); border: 1px solid var(--line); border-left: 4px solid var(--accent); border-radius: 0 10px 10px 0; padding: 12px 16px; margin: 18px 0 8px; }
details.sec > summary { list-style: none; cursor: pointer; display: flex; align-items: baseline; gap: 12px; flex-wrap: wrap; border-bottom: 1px solid var(--line); margin-top: 18px; }
details.sec > summary::-webkit-details-marker { display: none; }
details.sec > summary h2 { margin: 10px 0 6px; }
details.sec > summary::before { content: "▸"; color: var(--muted); font-size: 14px; }
details.sec[open] > summary::before { content: "▾"; }
.c-real { color: var(--real); } .c-beta { color: var(--beta); } .c-acc { color: var(--accent); }
.cardlink { text-decoration: none; color: inherit; display: block; }
.pricing { margin: 10px 0; }
.h1s { font-size: clamp(24px, 3.6vw, 34px); }
#mpick { max-width: 100%; }
.hero-stats .v { font-size: 30px; }
@media (max-width: 560px) { .holdings th:nth-child(2), .holdings td:nth-child(2) { display: none; } }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .banner { background: #2a3137; color: #e7e5e0; } }
:root[data-theme="dark"] .banner { background: #2a3137; color: #e7e5e0; }
details.sec > summary { align-items: center; }
