:root {
  --bg: #ffffff;
  --line: #e8e6ee;
  --line-2: #d9d6e2;
  --text: #16141c;
  --muted: #6b6775;
  --faint: #9a96a3;
  --purple: #8842fd;
  --purple-2: #c394ff;
  --green: #12805c;
  --amber: #b86e00;
  --red: #c23a4a;
  --chip: #f4f1fa;
  --shadow: 0 16px 40px rgba(67, 0, 59, .08);
  --font: "Inter", ui-sans-serif, system-ui, sans-serif;
  --title: "Outfit", "PingFang SC", "Hiragino Sans GB", "Noto Sans SC", "Microsoft YaHei", sans-serif;
}
* { box-sizing: border-box; }
html, body { margin: 0; background: var(--bg); color: var(--text); font-family: var(--font); }
button, input, select { font: inherit; color: inherit; }
button { cursor: pointer; }
a { color: var(--purple); text-decoration: none; }
.wrap { max-width: 1280px; margin: 0 auto; padding: 0 32px 96px; position: relative; }
.narrow { max-width: 760px; }

header.top {
  display: flex; align-items: center; gap: 28px;
  height: 64px; border-bottom: 1px solid var(--line);
  position: sticky; top: 0; background: #fff; z-index: 8;
}
.brand { display: flex; align-items: center; gap: 10px; font-weight: 600; font-size: 15px; color: var(--text); }
.mark {
  width: 22px; height: 22px; border-radius: 6px; background: var(--purple);
  box-shadow: inset 0 0 0 2px #fff, 0 0 0 1px var(--purple);
}
.nav { display: flex; gap: 20px; color: var(--muted); font-size: 14px; flex: 1; }
.nav a { color: var(--muted); }
.nav a.on, .nav b { color: var(--text); font-weight: 500; }
.search-wrap {
  display: flex; align-items: center; gap: 8px;
  height: 36px; padding: 0 10px 0 12px; min-width: 220px;
  border: 1px solid var(--line-2); border-radius: 8px; background: #faf9fc;
}
.search-wrap input { border: 0; outline: 0; background: transparent; width: 100%; font-size: 13px; }
.kbd {
  font-size: 11px; color: var(--faint); border: 1px solid var(--line-2);
  border-radius: 5px; padding: 1px 6px; background: #fff;
}

.hero { padding: 48px 0 8px; }
.kicker { color: var(--purple); font-size: 13px; font-weight: 500; }
h1 {
  margin: 10px 0 12px; font-family: var(--title); font-size: 48px;
  font-weight: 700; letter-spacing: -.03em; line-height: 1.08;
}
h2 { font-family: var(--title); font-size: 28px; font-weight: 650; margin: 36px 0 12px; letter-spacing: -.02em; }
.lede { color: var(--muted); max-width: 680px; line-height: 1.6; font-size: 16px; }

.lang { position: relative; flex-shrink: 0; }
.lang summary {
  list-style: none; cursor: pointer; font-size: 13px; color: var(--muted);
  padding: 6px 0;
}
.lang summary::-webkit-details-marker { display: none; }
.lang-menu {
  position: absolute; right: 0; top: 36px; min-width: 148px;
  background: #fff; border: 1px solid var(--line-2); border-radius: 10px;
  box-shadow: var(--shadow); padding: 6px 0; z-index: 12;
}
.lang-menu a { display: block; padding: 6px 12px; color: var(--text); font-size: 13px; }
.lang-menu a:hover, .lang-menu a.on { background: #faf8ff; color: var(--purple); }

.kpis { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin: 36px 0 28px; }
.kpi { border: 1px solid var(--line); border-radius: 12px; padding: 18px 16px 16px; background: #fff; overflow: visible; }
.kpi .label { color: var(--text); font-family: var(--title); font-size: 20px; font-weight: 800; font-style: italic; letter-spacing: -.02em; }
.kpi .value { font-family: var(--title); font-size: 34px; font-weight: 700; margin: 8px 0 4px; letter-spacing: -.03em; }
.kpi .sub { color: var(--faint); font-size: 12px; }

.aa-chart {
  display: grid;
  grid-template-columns: repeat(var(--n, 8), minmax(0, 1fr));
  align-items: end;
  gap: 3px;
  min-height: 248px;
  margin-top: 16px;
}
.aa-col {
  display: flex; flex-direction: column; align-items: center;
  min-width: 0; color: inherit; text-decoration: none; position: relative;
}
.aa-plot {
  display: flex; flex-direction: column; align-items: center; justify-content: flex-end;
  width: 100%; height: 154px;
}
.aa-val {
  font-size: 13.5px; font-weight: 700; font-variant-numeric: tabular-nums;
  margin-bottom: 4px; color: var(--text); letter-spacing: -.03em; line-height: 1;
  white-space: nowrap; max-width: 100%; overflow: hidden;
}
.aa-chart.dense .aa-val { font-size: 12.5px; font-weight: 700; }
.aa-bar {
  width: 72%; max-width: 34px; height: var(--h);
  background: var(--c); border-radius: 3px 3px 1px 1px; min-height: 4px;
  transition: filter .15s, transform .15s;
}
.aa-col:hover .aa-bar, .aa-col:focus-visible .aa-bar {
  filter: brightness(1.1); transform: translateY(-2px);
}
.aa-foot {
  display: flex; flex-direction: column; align-items: center; gap: 6px;
  margin-top: 8px; height: 78px;
}
.aa-mark {
  width: 20px; height: 20px; border-radius: 5px;
  background: #fff; color: var(--c); border: 1px solid var(--line);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0; overflow: hidden;
}
.aa-mark svg { width: 14px; height: 14px; display: block; }
.aa-name {
  writing-mode: vertical-rl; transform: rotate(180deg);
  font-size: 11px; font-weight: 400; color: var(--text); line-height: 1.15;
  max-height: 56px; overflow: hidden;
}
.aa-tip {
  position: absolute; left: 50%; bottom: calc(100% + 4px); transform: translateX(-50%);
  background: #16141c; color: #fff; font-size: 12px; line-height: 1.35;
  padding: 8px 10px; border-radius: 8px; white-space: nowrap;
  opacity: 0; pointer-events: none; z-index: 6; box-shadow: var(--shadow);
}
.aa-col:hover .aa-tip, .aa-col:focus-visible .aa-tip { opacity: 1; }
.aa-col:first-child .aa-tip { left: 0; transform: none; }
.aa-col:last-child .aa-tip { left: auto; right: 0; transform: none; }

.toolbar { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; padding: 6px 0 14px; }
.sel {
  height: 34px; border: 1px solid var(--line-2); background: #fff;
  border-radius: 8px; padding: 0 10px; font-size: 13px;
}
.filter { display: flex; align-items: center; gap: 6px; color: var(--muted); font-size: 13px; }
.btn { display: inline-flex; align-items: center; gap: 6px; background: transparent; border: 0; color: var(--purple); padding: 0 4px; }
.btn.ghost { color: var(--muted); }
.count { margin-left: auto; color: var(--faint); font-size: 13px; }

.table-shell { overflow: auto; border-top: 1px solid var(--line); }
table { border-collapse: separate; border-spacing: 0; min-width: 1100px; width: 100%; font-size: 13.5px; }
thead th {
  position: sticky; top: 0; z-index: 3;
  background: #fff; color: var(--muted); font-weight: 500;
  border-bottom: 1px solid var(--line); padding: 10px 12px; text-align: left;
  white-space: nowrap; user-select: none;
}
thead tr.groups th {
  top: 0; font-size: 11px; letter-spacing: .04em; text-transform: uppercase;
  color: var(--faint); border-bottom: 1px solid var(--line); padding-top: 14px;
}
thead tr.cols th { top: 34px; cursor: pointer; }
thead tr.cols th:hover { color: var(--text); }
thead tr.cols th.sort { color: var(--purple); }
tbody td {
  padding: 11px 12px; border-bottom: 1px solid var(--line); vertical-align: middle;
  white-space: nowrap;
}
tbody tr { cursor: pointer; }
tbody tr:hover td { background: #faf8ff; }
.sticky-col { position: sticky; left: 0; z-index: 2; background: #fff; min-width: 200px; }
thead .sticky-col { z-index: 4; }
tbody tr:hover .sticky-col { background: inherit; }
.plan-name { font-weight: 500; color: var(--text); }
.plan-sub { color: var(--faint); font-size: 12px; margin-top: 2px; }
.num { font-variant-numeric: tabular-nums; text-align: right; }
th.num, td.num { text-align: right; }
.muted { color: var(--muted); }
.faint { color: var(--faint); }
.good { color: var(--purple); }
.bad { color: var(--red); }
.chip {
  display: inline-block; background: var(--chip); border: 1px solid var(--line);
  padding: 1px 7px; border-radius: 999px; font-size: 11px; color: #4b4458;
}
.status { font-size: 12px; font-weight: 500; text-transform: capitalize; }
.status.open { color: var(--green); }
.status.restock { color: var(--amber); }
.status.paused, .status.retired { color: var(--red); }
.spark { display: block; }

.cols-panel {
  position: fixed; top: 72px; right: 32px; width: 400px; max-height: calc(100vh - 100px);
  overflow: auto; background: #fff; border: 1px solid var(--line-2); border-radius: 12px;
  box-shadow: var(--shadow); z-index: 15; padding: 16px 16px 18px; display: none;
}
.cols-panel.on { display: block; }
.cols-panel h3 { margin: 0 0 10px; font-family: var(--title); font-size: 22px; font-weight: 650; }
.col-actions { display: flex; gap: 12px; margin-bottom: 14px; }
.col-group { margin-bottom: 12px; }
.col-group h4 { margin: 0 0 6px; color: var(--faint); font-size: 11px; letter-spacing: .06em; text-transform: uppercase; }
.col-item { display: flex; align-items: center; gap: 8px; font-size: 13px; padding: 3px 0; }
.col-item input { accent-color: var(--purple); }

.note { margin-top: 28px; color: var(--faint); font-size: 13px; line-height: 1.6; }
.article { font-size: 16px; line-height: 1.7; color: #2b2833; }
.article p { margin: 0 0 16px; }
.article ul { padding-left: 20px; }
.article code { background: var(--chip); padding: 1px 6px; border-radius: 4px; font-size: 13px; }
.meta { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 16px; margin: 18px 0 22px; }
.meta .k { color: var(--muted); font-size: 12px; }
.meta .v { font-size: 15px; margin-top: 3px; }
.section-t { font-size: 12px; color: var(--faint); text-transform: uppercase; letter-spacing: .06em; margin: 26px 0 10px; }
.hist-chart {
  position: relative;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 8px 8px 4px;
  background: #fff;
  margin: 0 0 4px;
}
.hist-chart svg { width: 100%; height: 280px; display: block; }
.hist-chart .grid { stroke: #efeef4; stroke-width: 1; }
.hist-chart .axis { fill: var(--faint); font-size: 11px; font-family: var(--font); }
.hist-chart .line { fill: none; stroke-width: 2; stroke-linejoin: round; }
.hist-chart .area { fill-opacity: .12; }
.hist-chart .dot { stroke: #fff; stroke-width: 1.5; }
.hist-chart .hover-line { stroke: var(--text); stroke-width: 1; stroke-dasharray: 3 3; opacity: .35; }
.hist-tip {
  position: absolute; top: 12px; left: 64px;
  background: #16141c; color: #fff; font-size: 12px; line-height: 1.35;
  padding: 8px 10px; border-radius: 8px; pointer-events: none;
  opacity: 0; z-index: 3; box-shadow: var(--shadow); white-space: nowrap;
}
.hist-chart.is-hover .hist-tip { opacity: 1; }
.hist-empty { color: var(--faint); font-size: 13px; padding: 28px 12px; }
.change {
  display: grid; grid-template-columns: 110px 1fr auto; gap: 16px;
  padding: 16px 0; border-bottom: 1px solid var(--line); align-items: baseline;
}
.change .date { color: var(--faint); font-size: 13px; }
.related { display: flex; flex-wrap: wrap; gap: 8px; }
.related a { border: 1px solid var(--line); border-radius: 8px; padding: 8px 12px; color: var(--text); }
.related a:hover { border-color: var(--purple); }
.compare-picks { display: flex; flex-wrap: wrap; gap: 8px; margin: 16px 0 24px; }
.compare-picks label { border: 1px solid var(--line); border-radius: 8px; padding: 8px 10px; font-size: 13px; }
footer.site {
  margin-top: 64px; padding-top: 24px; border-top: 1px solid var(--line);
  color: var(--faint); font-size: 13px; display: flex; justify-content: space-between; gap: 16px;
}
.search-pop {
  position: absolute; right: 32px; top: 68px; width: 360px; max-height: 360px; overflow: auto;
  background: #fff; border: 1px solid var(--line-2); border-radius: 12px;
  box-shadow: var(--shadow); display: none; z-index: 20;
}
.search-pop.on { display: block; }
.search-pop a { display: block; padding: 10px 14px; color: var(--text); border-bottom: 1px solid var(--line); }
.search-pop a:hover { background: #faf8ff; }
.search-pop .sub { color: var(--faint); font-size: 12px; }
@media (max-width: 900px) {
  .kpis { grid-template-columns: 1fr; }
  .wrap { padding: 0 16px 60px; }
  h1 { font-size: 36px; }
  header.top { gap: 12px; }
  .nav { display: none; }
  .change { grid-template-columns: 1fr; }
  .aa-chart { min-height: 220px; }
  .aa-plot { height: 132px; }
  .aa-name { max-height: 48px; font-size: 10.5px; font-weight: 400; }
  .hist-chart svg { height: 220px; }
}
