:root { color-scheme: light; --bg: #f6f7f4; --surface: #fff; --line: #d7ded5; --text: #17211b; --muted: #68756c; --accent: #1f6f8b; --good: #16794c; --bad: #ad2f32; font-family: Inter, system-ui, "Segoe UI", "Noto Sans TC", sans-serif; color: var(--text); background: var(--bg); }
* { box-sizing: border-box; }
body { margin: 0; }
a { color: var(--accent); }
button, input, select { font: inherit; }
button, .button { display: inline-flex; align-items: center; justify-content: center; min-height: 36px; padding: 8px 13px; border: 1px solid var(--line); border-radius: 7px; background: white; color: var(--text); text-decoration: none; font-size: 13px; cursor: pointer; }
button:hover, .button:hover { border-color: var(--accent); }
button:disabled { opacity: .5; cursor: default; }
.primary { background: var(--accent); color: white; }
:is(a, button, input):focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.performance-header { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 14px 24px; border-bottom: 1px solid var(--line); background: white; }
.brand { display: inline-flex; gap: 10px; align-items: center; color: var(--text); font-size: 20px; font-weight: 700; text-decoration: none; }
.brand-mark { display: grid; place-items: center; width: 38px; height: 38px; border-radius: 8px; background: var(--accent); color: white; font-size: 15px; }
nav { display: flex; gap: 18px; font-size: 13px; }
main { max-width: 1480px; margin: 0 auto; padding: 28px 24px 44px; }
h1, h2, h3, p { margin: 0; }
h1 { font-size: 28px; margin: 5px 0 10px; }
h2 { font-size: 18px; }
h3 { font-size: 15px; }
.eyebrow { color: var(--accent); font-size: 12px; }
.muted { color: var(--muted); }
.intro { max-width: 850px; font-size: 13px; line-height: 1.7; }
.page-heading { display: flex; justify-content: space-between; align-items: center; gap: 20px; }
.page-heading .button { flex-shrink: 0; }
.page-message { min-height: 22px; margin: 16px 0; font-size: 13px; line-height: 1.7; }
.page-message.error { color: var(--bad); }
.performance-layout { display: grid; grid-template-columns: 260px minmax(0, 1fr); gap: 20px; align-items: start; }
.tracking-sidebar, .performance-detail, .empty-state { min-width: 0; padding: 18px; border: 1px solid var(--line); border-radius: 10px; background: white; }
.sidebar-heading { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 8px; margin-bottom: 14px; }
.sidebar-heading h2 { font-size: 15px; }
.sidebar-heading label { display: flex; align-items: center; gap: 4px; font-size: 11px; color: var(--muted); }
.track-card { display: block; margin-bottom: 9px; padding: 12px; border: 1px solid var(--line); border-radius: 7px; color: var(--text); text-decoration: none; }
.track-card:hover { border-color: var(--accent); }
.track-card.selected { border-color: var(--accent); background: #edf6f7; }
.track-card strong { display: block; font-size: 13px; overflow-wrap: anywhere; }
.track-card .purpose { margin-top: 6px; color: var(--text); font-size: 11px; line-height: 1.5; overflow-wrap: anywhere; }
.track-card .meta { margin: 6px 0; color: var(--muted); font-size: 11px; line-height: 1.5; }
.track-card .return { font-size: 18px; font-weight: 700; }
.track-card .benchmark-return { display: block; margin-top: 3px; color: var(--muted); font-size: 11px; }
.detail-heading { display: flex; gap: 12px; align-items: flex-start; justify-content: space-between; margin-bottom: 18px; }
.detail-heading h2 { overflow-wrap: anywhere; }
.detail-heading p { margin-top: 5px; font-size: 12px; line-height: 1.6; }
.detail-heading .track-purpose { max-width: 760px; color: var(--text); overflow-wrap: anywhere; }
.detail-actions { display: flex; gap: 8px; flex-shrink: 0; }
.statistics { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.stat { padding: 12px; border: 1px solid var(--line); border-radius: 7px; }
.stat span { display: block; color: var(--muted); font-size: 11px; line-height: 1.5; }
.stat strong { display: block; margin-top: 6px; font-size: 23px; }
.positive { color: var(--good); }
.negative { color: var(--bad); }
.coverage { padding: 10px 0; font-size: 12px; line-height: 1.7; }
.coverage.warning { color: #80580a; }
.entry-snapshot { margin: 8px 0 18px; padding: 13px; border: 1px solid #c7dbdf; border-radius: 7px; background: #f1f8f8; }
.entry-snapshot p { margin-top: 6px; font-size: 12px; line-height: 1.7; color: var(--muted); }
.snapshot-actions { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 12px; }
.entry-snapshot iframe { width: 100%; height: 520px; margin-top: 14px; border: 1px solid var(--line); border-radius: 6px; background: white; }
.legacy-snapshot { border-color: #e2d5b5; background: #fff9ee; }
.chart-panel { margin-top: 6px; }
.chart-panel h3 { margin-bottom: 8px; }
.performance-chart { display: block; width: 100%; height: 210px; }
.chart-legend { display: flex; flex-wrap: wrap; gap: 16px; color: var(--muted); font-size: 11px; }
.chart-legend span { display: inline-flex; align-items: center; gap: 6px; }
.chart-legend i { display: inline-block; width: 16px; height: 3px; border-radius: 2px; background: #1f6f8b; }
.chart-legend .spy-key { background: #d18a24; }
.stat small { display: block; margin-top: 4px; color: var(--muted); font-size: 10px; }
.chart-note { margin-top: 5px; font-size: 11px; line-height: 1.6; }
.criteria { margin: 18px 0; padding: 12px; border-radius: 7px; background: #f6f7f4; font-size: 12px; }
.criteria strong { display: block; margin-bottom: 7px; }
.criteria-heading { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 8px; }
.criteria-heading strong { margin-bottom: 0; }
.criteria p { margin-bottom: 8px; }
.criteria ul { margin: 0; padding-left: 20px; display: flex; flex-wrap: wrap; gap: 6px 28px; line-height: 1.6; }
.holdings-heading { margin: 20px 0 10px; display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.holdings-heading span { font-size: 11px; }
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: 12px; }
th, td { padding: 11px 9px; border-bottom: 1px solid var(--line); text-align: left; }
th { background: #f6f7f4; font-weight: 600; white-space: nowrap; }
td.number, th.number { text-align: right; white-space: nowrap; }
td small { display: block; font-size: 10px; color: var(--muted); margin-top: 4px; line-height: 1.5; }
td.error { color: var(--bad); font-size: 11px; max-width: 240px; }
.empty-state { padding: 42px 26px; }
.empty-state p { margin: 12px 0 22px; font-size: 14px; line-height: 1.8; }
[hidden] { display: none !important; }
@media (max-width: 1000px) { .performance-layout { grid-template-columns: 210px minmax(0, 1fr); gap: 14px; } .statistics { grid-template-columns: repeat(2, minmax(0, 1fr)); } .detail-heading { flex-wrap: wrap; } }
@media (max-width: 700px) { main { padding: 22px 14px; } .performance-header { padding: 12px 14px; } .page-heading { align-items: flex-start; flex-direction: column; gap: 10px; } .performance-layout { grid-template-columns: 1fr; } #performanceTrackList { max-height: 240px; overflow-y: auto; } .performance-detail { padding: 14px; } }
