:root {
  --bg: #f5f6f8; --card: #ffffff; --ink: #1f2329; --quiet: #646a73; --line: #e5e6eb;
  --accent: #2b6de5; --accent-soft: #e8f0fd; --up: #1f9d55; --down: #d4380d; --warn: #d48806;
}
* { box-sizing: border-box; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 14px/1.5 -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", sans-serif; }
header { background: #fff; border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 10; }
.bar { max-width: 1440px; margin: 0 auto; padding: 0 24px; display: flex; align-items: center; gap: 24px; height: 56px; }
.brand { font-weight: 600; font-size: 16px; white-space: nowrap; }
nav a { color: var(--quiet); text-decoration: none; padding: 17px 4px; margin-right: 16px; border-bottom: 2px solid transparent; }
nav a.on { color: var(--accent); border-bottom-color: var(--accent); font-weight: 600; }
.filters { margin-left: auto; display: flex; gap: 12px; align-items: center; color: var(--quiet); flex-wrap: wrap; }
select { font: inherit; padding: 4px 8px; border: 1px solid var(--line); border-radius: 6px; background: #fff; max-width: 320px; }
main { max-width: 1440px; margin: 0 auto; padding: 0 24px 48px; }
.brand { color: var(--ink); text-decoration: none; }
.fbar { max-width: 1392px; margin: 16px auto; background: #fff; border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px;
  display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
@media (max-width: 1440px) { .fbar { margin: 16px 24px; } }
.fbar .combo { display: inline-flex; align-items: center; justify-content: space-between; gap: 6px; min-width: 120px; max-width: 320px; height: 32px; padding: 0 8px;
  border: 1px solid var(--line); border-radius: 6px; background: #fff; font: inherit; color: var(--ink); cursor: pointer; text-align: left; }
.fbar .combo span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.fbar .combo::after { content: ""; flex: none; width: 6px; height: 6px; border-right: 1.5px solid var(--quiet); border-bottom: 1.5px solid var(--quiet); transform: translateY(-2px) rotate(45deg); }
.fbar .combo.wide { min-width: 220px; }
.fbar .combo:hover, .fbar .combo:focus { border-color: var(--accent); outline: none; }
.combo-pop { position: absolute; z-index: 100; background: #fff; border: 1px solid var(--line); border-radius: 8px; box-shadow: 0 6px 24px rgba(31, 35, 41, .14); padding: 6px; max-width: 420px; }
.combo-pop input { width: 100%; height: 30px; border: 1px solid var(--line); border-radius: 6px; padding: 0 8px; font: inherit; margin-bottom: 4px; }
.combo-pop input:focus { border-color: var(--accent); outline: none; }
.combo-list { max-height: 300px; overflow: auto; }
.combo-item { padding: 6px 8px; border-radius: 4px; cursor: pointer; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.combo-item.hl { background: #f2f5fb; }
.combo-item.on { color: var(--accent); font-weight: 600; }
.combo-none { padding: 8px; color: var(--quiet); font-size: 12px; }
.fbar .range { display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--line); border-radius: 6px; padding: 0 8px; height: 32px; color: var(--quiet); }
.fbar input[type=date] { border: 0; font: inherit; color: var(--ink); background: transparent; }
.fbar input[type=search] { height: 32px; border: 1px solid var(--line); border-radius: 6px; padding: 0 10px; font: inherit; min-width: 180px; }
.fbar button { height: 32px; padding: 0 14px; border: 1px solid var(--line); border-radius: 6px; background: #fff; font: inherit; cursor: pointer; }
.fbar button:hover { border-color: var(--accent); color: var(--accent); }
.fbar .fb-tip { margin-left: auto; color: var(--quiet); font-size: 12px; }
tr.clickable { cursor: pointer; }
tr.clickable:hover td { background: #f5f8ff; }
tr.sel td { background: var(--accent-soft); }
.period { color: var(--quiet); margin-bottom: 12px; }
.grid { display: grid; gap: 16px; }
.g6 { grid-template-columns: repeat(6, 1fr); }
.g5 { grid-template-columns: repeat(5, 1fr); }
.g4 { grid-template-columns: repeat(4, 1fr); }
.g3 { grid-template-columns: repeat(3, 1fr); }
.g2 { grid-template-columns: repeat(2, 1fr); }
.span2 { grid-column: span 2; }
.span3 { grid-column: span 3; }
@media (max-width: 1100px) { .g6, .g5, .g4 { grid-template-columns: repeat(2, 1fr); } .g3, .g2 { grid-template-columns: 1fr; } .span2, .span3 { grid-column: auto; } }
.card { background: var(--card); border: 1px solid var(--line); border-radius: 10px; padding: 16px; min-width: 0; }
.card h3 { margin: 0 0 4px; font-size: 15px; }
.card .sub { color: var(--quiet); font-size: 12px; margin-bottom: 8px; }
.kpi .t { color: var(--quiet); font-size: 13px; }
.kpi .v { font-size: 26px; font-weight: 600; margin: 4px 0; white-space: nowrap; }
.kpi .c { font-size: 12px; color: var(--quiet); }
.up { color: var(--up); } .down { color: var(--down); }
.chart { width: 100%; height: 320px; }
.chart.tall { height: 400px; }
.chart.short { height: 240px; }
table { width: 100%; border-collapse: collapse; font-size: 13px; }
th, td { padding: 7px 8px; border-bottom: 1px solid var(--line); text-align: right; white-space: nowrap; }
th { color: var(--quiet); font-weight: 500; background: #fafbfc; position: sticky; top: 0; }
td.l, th.l { text-align: left; }
td.kw { white-space: normal; min-width: 200px; max-width: 280px; text-align: left; }
td.kw small { color: var(--quiet); display: block; }
.tbl { max-height: 520px; overflow: auto; }
.tag { display: inline-block; padding: 0 6px; border-radius: 4px; font-size: 12px; background: #f2f3f5; color: var(--quiet); margin: 2px 4px 2px 0; }
.tag.own { background: var(--accent-soft); color: var(--accent); }
.heat td { text-align: center; }
.heat td.l { text-align: left; }
.section { margin-top: 24px; }
.section > h2 { font-size: 16px; margin: 0 0 12px; }
.empty { color: var(--quiet); padding: 24px; text-align: center; }
.err { background: #fff2e8; color: var(--down); padding: 12px 16px; border-radius: 8px; margin-bottom: 12px; }
.info { display: flex; gap: 16px; align-items: center; }
.info img { width: 72px; height: 72px; object-fit: contain; border: 1px solid var(--line); border-radius: 8px; background: #fff; }
.info .kv { display: grid; grid-template-columns: repeat(4, auto); gap: 4px 20px; color: var(--quiet); font-size: 13px; }
.info .kv b { color: var(--ink); font-weight: 500; }
.note { color: var(--quiet); font-size: 12px; margin-top: 6px; }
.home { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; margin-top: 24px; }
.home a { text-decoration: none; color: inherit; }
.home .card:hover { border-color: var(--accent); }
