#markettech-view { color: var(--text-1); }

.mt-hero {
  display: flex; align-items: flex-start; justify-content: space-between; gap: var(--sp-4);
  padding: var(--sp-4) var(--sp-5); margin-bottom: var(--sp-4);
  border: 1px solid var(--border); border-radius: var(--r-xl); background: var(--card);
}
.mt-hero h2 { margin: 0 0 var(--sp-1); font-family: var(--font-heading); font-size: var(--fs-display); }
.mt-hero div > span, .mt-hero p { color: var(--text-2); font-size: var(--fs-ui); }
.mt-hero p { margin: 0; max-width: 520px; text-align: right; line-height: var(--lh-snug); }
.mt-hero-copy { min-width: 0; }
.mt-hero-copy > strong { display: block; margin-bottom: var(--sp-1); font-family: var(--font-heading); font-size: var(--fs-display); }
.mt-hero-copy > span { display: block; }
.mt-hero-copy p { margin-top: var(--sp-2); text-align: left; }
.mt-stale-note { display: block; margin-top: var(--sp-1); color: var(--accent) !important; font-size: var(--fs-meta) !important; }
.mt-state-space {
  margin-bottom: var(--sp-5); overflow: hidden; border: 1px solid var(--border);
  border-radius: var(--r-xl); background: var(--card); box-shadow: 0 1px 0 rgba(58,56,50,.03);
}
.mt-state-space-head {
  display: flex; align-items: flex-end; justify-content: space-between; gap: var(--sp-5);
  padding: var(--sp-4) var(--sp-5);
}
.mt-state-space-head > div > span, .mt-state-space-kicker {
  display: block; margin-bottom: 3px; color: var(--accent); font-size: var(--fs-meta);
  font-weight: 700; letter-spacing: .08em;
}
.mt-state-space-head h3 { margin: 0; font-family: var(--font-heading); font-size: var(--fs-display); }
.mt-state-space-head p { max-width: 680px; margin: 0; color: var(--text-2); font-size: var(--fs-ui); line-height: var(--lh-body); }
.mt-state-space-head p b { color: var(--text-1); }
.mt-state-space-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border-top: 1px solid var(--border-soft); }
.mt-state-space-grid article { min-width: 0; padding: var(--sp-4) var(--sp-5); background: linear-gradient(180deg, rgba(245,242,237,.40), rgba(255,255,255,0)); }
.mt-state-space-grid article + article { border-left: 1px solid var(--border-soft); }
.mt-state-space-grid h4 { margin: 0 0 var(--sp-3); color: var(--text-0); font-family: var(--font-heading); font-size: var(--fs-title); }
.mt-state-space-grid ul { margin: 0; padding: 0; list-style: none; }
.mt-state-space-grid li { padding: 8px 0; border-top: 1px solid var(--border-soft); }
.mt-state-space-grid li:first-child { padding-top: 0; border-top: 0; }
.mt-state-space-grid li b { display: block; margin-bottom: 2px; color: var(--text-1); font-size: var(--fs-meta); }
.mt-state-space-grid li span { display: block; color: var(--text-2); font-size: var(--fs-meta); line-height: var(--lh-snug); }
.mt-index-switch {
  display: flex; flex: 0 0 auto; flex-wrap: wrap; justify-content: flex-end; gap: 6px;
  padding: 4px; border: 1px solid var(--border-soft); border-radius: var(--r-lg); background: var(--bg-2);
}
.mt-index-btn {
  min-height: 34px; padding: 6px 12px; border: 1px solid transparent; border-radius: var(--r-md);
  background: transparent; color: var(--text-2); font-size: var(--fs-ui); font-weight: 600; cursor: pointer;
  transition: background .15s ease, border-color .15s ease, color .15s ease;
}
.mt-index-btn:hover { border-color: var(--border); background: var(--card); color: var(--text-1); }
.mt-index-btn.active { border-color: var(--accent); background: var(--card); color: var(--accent); box-shadow: 0 1px 2px rgba(58,56,50,.08); }
.mt-index-btn:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.mt-index-btn:disabled { opacity: .38; cursor: not-allowed; }

.mt-method-card {
  margin-bottom: var(--sp-5); overflow: hidden; border: 1px solid var(--border);
  border-radius: var(--r-xl); background: var(--card); box-shadow: 0 1px 0 rgba(58,56,50,.03);
}
.mt-method-head { display: grid; grid-template-columns: minmax(380px, 1fr) minmax(420px, 1.1fr); gap: var(--sp-5); padding: var(--sp-5); border-bottom: 1px solid var(--border-soft); }
.mt-method-kicker { display: inline-block; margin-bottom: var(--sp-1); color: var(--accent); font-size: var(--fs-meta); font-weight: 700; letter-spacing: .08em; }
.mt-method-head h3 { margin: 0 0 var(--sp-2); font-family: var(--font-heading); font-size: var(--fs-display); }
.mt-method-head > div > p { margin: 0; color: var(--text-2); font-size: var(--fs-ui); line-height: var(--lh-body); }
.mt-method-body { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 0; }
.mt-method-controls { margin-top: var(--sp-3); }
.mt-control-row { display: flex; flex-wrap: wrap; gap: var(--sp-2); }
.mt-control-row .mt-index-switch { justify-content: flex-start; }
.mt-control-row .mt-index-btn { min-height: 30px; padding: 4px 9px; font-size: var(--fs-meta); }
.mt-control-row .mt-timeframe-btn { min-width: 58px; }
.mt-control-row .mt-history-switch { margin-left: auto; }
.mt-control-row .mt-window-btn { min-width: 66px; }
.mt-method-meta { margin-top: var(--sp-2); color: var(--text-3); font-size: var(--fs-meta); line-height: var(--lh-snug); }
.mt-method-meta .mt-stale-note { display: inline; margin-left: var(--sp-2); }
.mt-chart { position: relative; min-width: 0; height: 450px; border-right: 1px solid var(--border-soft); }
#mt-chan-chart { height: 520px; }
.mt-chan-zones { position: absolute; inset: 0; z-index: 3; width: 100%; height: 100%; overflow: hidden; pointer-events: none; }
.mt-chan-zone { fill: rgba(224,139,50,.08); stroke: rgba(202,112,24,.62); stroke-width: 1; vector-effect: non-scaling-stroke; }
.mt-chan-zone.latest { fill: rgba(224,139,50,.15); stroke: rgba(190,92,12,.96); stroke-width: 1.5; }
.mt-chan-zone-extension { stroke: rgba(202,112,24,.48); stroke-width: 1; stroke-dasharray: 4 4; vector-effect: non-scaling-stroke; }
.mt-chan-zone-extension.latest { stroke: rgba(190,92,12,.78); stroke-width: 1.25; }
.mt-chan-zone-label { fill: #9d5c1c; font-size: 10px; font-weight: 650; paint-order: stroke; stroke: rgba(255,255,255,.92); stroke-width: 3px; stroke-linejoin: round; }
.mt-chan-zone-label.latest { fill: #7c3f0c; }
.mt-chan-legend { display: flex; flex-wrap: wrap; gap: 6px 14px; margin-top: var(--sp-2); color: var(--text-2); font-size: var(--fs-meta); }
.mt-chan-legend span { display: inline-flex; align-items: center; gap: 6px; }
.mt-chan-legend i { display: inline-block; width: 22px; height: 0; border-top: 3px solid; }
.mt-chan-legend i.bi-style { border-top: 1px dashed #66645e; }
.mt-chan-legend i.segment-style { border-color: #66645e; }
.mt-chan-legend i.same { border-color: #d97724; }
.mt-chan-legend i.reverse { border-color: #8a8a84; }
.mt-chan-legend i.zone { height: 8px; border: 1px solid #be5c0c; background: rgba(224,139,50,.15); }
.mt-side { padding: var(--sp-4); background: linear-gradient(180deg, rgba(245,242,237,.48), rgba(255,255,255,0)); }
.mt-side h4 { margin: 0 0 var(--sp-3); color: var(--text-2); font-size: var(--fs-ui); }

.mt-status-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--sp-2); }
.mt-status-item { min-width: 0; padding: var(--sp-2) var(--sp-3); border: 1px solid var(--border-soft); border-radius: var(--r-md); background: var(--bg-2); }
.mt-status-item span { display: block; margin-bottom: 2px; color: var(--text-3); font-size: var(--fs-meta); }
.mt-status-item strong { display: block; overflow: hidden; color: var(--text-0); font-size: var(--fs-ui); text-overflow: ellipsis; white-space: nowrap; }
.mt-summary { grid-column: 1 / -1; margin: var(--sp-3) 0 0; color: var(--text-2); font-size: var(--fs-ui); line-height: var(--lh-body); }

.mt-event-list { display: flex; flex-direction: column; gap: var(--sp-3); }
.mt-event-row { position: relative; display: grid; grid-template-columns: 8px minmax(0, 1fr); column-gap: var(--sp-2); }
.mt-event-dot { width: 7px; height: 7px; margin-top: 6px; border-radius: 50%; background: var(--flat); }
.mt-event-dot.bull { background: var(--up); }
.mt-event-dot.bear { background: var(--dn); }
.mt-event-row div { display: flex; align-items: baseline; justify-content: space-between; gap: var(--sp-2); }
.mt-event-row b { color: var(--text-1); font-size: var(--fs-ui); }
.mt-event-row span { color: var(--text-3); font-size: var(--fs-meta); }
.mt-event-row p { grid-column: 2; margin: 2px 0 0; color: var(--text-2); font-size: var(--fs-meta); line-height: var(--lh-snug); }

.mt-wave-list { display: flex; flex-direction: column; gap: var(--sp-2); }
.mt-wave-candidate { display: block; width: 100%; padding: var(--sp-3); border: 1px solid var(--border-soft); border-radius: var(--r-md); background: var(--card); color: inherit; font: inherit; text-align: left; cursor: pointer; transition: border-color .15s ease, background .15s ease, box-shadow .15s ease; }
.mt-wave-candidate:hover { border-color: var(--border-strong); background: var(--bg-2); }
.mt-wave-candidate:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.mt-wave-candidate.active { border-color: var(--accent); box-shadow: inset 3px 0 0 var(--accent); }
.mt-wave-candidate > div { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: var(--sp-2); }
.mt-wave-rank { padding: 2px 6px; border-radius: var(--r-pill); background: var(--tag-bg); color: var(--text-2); font-size: var(--fs-micro); }
.mt-wave-candidate strong { font-size: var(--fs-ui); }
.mt-wave-candidate > div > b { color: var(--accent); font-family: var(--font-mono); font-size: var(--fs-ui); }
.mt-wave-candidate p, .mt-wave-candidate small { display: block; margin: 5px 0 0; color: var(--text-3); font-size: var(--fs-meta); line-height: var(--lh-snug); }

.mt-method-foot { display: grid; grid-template-columns: 1fr 1fr; gap: var(--sp-4); padding: var(--sp-3) var(--sp-5); border-top: 1px solid var(--border-soft); background: var(--bg-2); color: var(--text-2); font-size: var(--fs-meta); line-height: var(--lh-snug); }
.mt-method-foot b { color: var(--text-1); }
.mt-erp-card {
  max-width: none; margin: 0 0 var(--sp-5); padding: var(--sp-5);
  border: 1px solid var(--border); border-radius: var(--r-xl); background: var(--card);
  box-shadow: 0 1px 0 rgba(58,56,50,.03);
}
.mt-erp-card .topview-h3 { margin-bottom: var(--sp-3); }
.mt-erp-card .mood-chart-wrap { max-width: none; }
/* 多级别核对 (2026-08-30) */
.mt-multilevel { margin: 0 0 var(--sp-4); padding: var(--sp-4) var(--sp-5); border: 1px solid var(--border); border-radius: var(--r-xl); background: var(--card); }
.mt-multilevel-head { display: flex; align-items: flex-start; justify-content: space-between; gap: var(--sp-4); margin-bottom: var(--sp-3); }
.mt-multilevel-head span { color: var(--accent); font-size: var(--fs-meta); font-weight: 800; letter-spacing: .1em; }
.mt-multilevel-head h3 { margin: 2px 0 0; font-family: var(--font-heading); font-size: var(--fs-display); }
.mt-multilevel-head p { max-width: 640px; margin: 0; color: var(--text-2); font-size: var(--fs-meta); line-height: var(--lh-snug); text-align: right; }
.mt-ml-agree { margin-bottom: var(--sp-3); color: var(--text-1); font-size: var(--fs-ui); }
.mt-ml-agree b { color: var(--accent-orange); }
.mt-ml-agree span { color: var(--text-3); font-size: var(--fs-meta); }
.mt-ml-table { width: 100%; border-collapse: collapse; font-size: var(--fs-meta); margin-bottom: var(--sp-3); }
.mt-ml-table th, .mt-ml-table td { padding: 6px 10px; text-align: left; border-bottom: 1px solid var(--border-soft); white-space: nowrap; }
.mt-ml-table thead th { color: var(--text-3); font-weight: 700; }
.mt-ml-table tbody th { color: var(--text-1); font-weight: 600; }
.mt-ml-table tbody td { color: var(--text-2); font-variant-numeric: tabular-nums; }
.mt-ml-table tbody td b { color: var(--text-1); }
.mt-ml-walk { white-space: normal; }
.mt-ml-band { color: var(--text-3); }
.mt-ml-note { margin: 0; color: var(--text-2); font-size: var(--fs-meta); line-height: var(--lh-body); }
@media (max-width: 680px) { .mt-multilevel-head { flex-direction: column; } .mt-multilevel-head p { text-align: left; } }
/* ERP 标准差轨道读数 (2026-08-30) —— 只排读数, 不带任何方向词 */
.erp-legend { display: flex; flex-wrap: wrap; gap: var(--sp-2) var(--sp-4); margin: var(--sp-2) 0 var(--sp-3); color: var(--text-2); font-size: var(--fs-meta); }
.erp-legend i { display: inline-block; width: 14px; height: 2px; margin-right: 6px; vertical-align: 3px; }
.erp-readings-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(132px, 1fr)); gap: 1px; margin-bottom: var(--sp-2); overflow: hidden; border: 1px solid var(--border-soft); border-radius: var(--r-lg); background: var(--border-soft); }
.erp-readings-grid > div { display: flex; align-items: baseline; justify-content: space-between; gap: var(--sp-2); padding: 7px var(--sp-3); background: var(--card); }
.erp-readings-grid span { color: var(--text-3); font-size: var(--fs-meta); }
.erp-readings-grid b { font-family: var(--font-mono); font-size: var(--fs-ui); color: var(--text-1); }
.erp-readings-grid .erp-hl b { color: var(--accent-orange); }
.erp-readings-note { color: var(--text-2); font-size: var(--fs-meta); line-height: var(--lh-body); }
.erp-readings-note b { color: var(--text-1); }
.erp-readings-empty { color: var(--text-2); font-size: var(--fs-meta); }
.mt-erp-card .theme-method-hint { margin-bottom: 0; }
.mt-loading, .mt-error, .mt-empty { padding: var(--sp-6); color: var(--text-2); text-align: center; }
.mt-error { display: flex; flex-direction: column; align-items: center; gap: var(--sp-2); border: 1px solid var(--border); border-radius: var(--r-xl); background: var(--card); }
.mt-error button { padding: 6px 16px; border: 1px solid var(--border-strong); border-radius: var(--r-md); background: var(--card); color: var(--text-1); cursor: pointer; }

@media (max-width: 900px) {
  .mt-state-space-head { align-items: flex-start; flex-direction: column; gap: var(--sp-2); }
  .mt-state-space-grid { grid-template-columns: 1fr; }
  .mt-state-space-grid article + article { border-top: 1px solid var(--border-soft); border-left: 0; }
  .mt-method-head { grid-template-columns: 1fr; gap: var(--sp-3); }
  .mt-method-body { grid-template-columns: 1fr; }
  .mt-chart { border-right: 0; border-bottom: 1px solid var(--border-soft); }
  .mt-side { max-height: 360px; overflow: auto; }
}

@media (max-width: 640px) {
  .mt-hero { flex-direction: column; padding: var(--sp-4); }
  .mt-hero p { text-align: left; }
  .mt-state-space-head, .mt-state-space-grid article { padding: var(--sp-4); }
  .mt-index-switch { width: 100%; justify-content: flex-start; }
  .mt-index-btn { flex: 1 1 calc(50% - 6px); }
  .mt-control-row { display: grid; grid-template-columns: 1fr; }
  .mt-control-row .mt-index-switch { width: 100%; }
  .mt-control-row .mt-history-switch { margin-left: 0; }
  .mt-control-row .mt-index-btn { flex: 1 1 calc(50% - 6px); }
  .mt-method-head { padding: var(--sp-4); }
  .mt-erp-card { padding: var(--sp-4); }
  .mt-status-grid { grid-template-columns: 1fr; }
  .mt-method-foot { grid-template-columns: 1fr; padding: var(--sp-3) var(--sp-4); }
  .mt-chart { height: 390px; }
  #mt-chan-chart { height: 470px; }
}
