:root {
  color-scheme: dark;
  --bg: #101210;
  --surface: #171a17;
  --surface-raised: #1d211e;
  --surface-soft: #222723;
  --border: #303631;
  --border-strong: #424a44;
  --text: #f2f5f2;
  --text-soft: #c6cdc8;
  --muted: #8f9992;
  --price: #59d4a5;
  --price-soft: #18382e;
  --bottom: #f2c75c;
  --bottom-soft: #3b321b;
  --top: #ff7167;
  --top-soft: #442421;
  --blue: #78a9ff;
  --violet: #b59cff;
  --danger: #ff7167;
  --shadow: 0 14px 34px rgba(0, 0, 0, 0.22);
}

* {
  box-sizing: border-box;
  letter-spacing: 0;
}

html {
  min-width: 320px;
  background: var(--bg);
}

body {
  min-width: 320px;
  min-height: 100vh;
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: Inter, "Noto Sans SC", "Microsoft YaHei", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 14px;
  line-height: 1.5;
}

button,
input,
select {
  font: inherit;
}

button {
  color: inherit;
}

button:focus-visible,
a:focus-visible {
  outline: 2px solid var(--price);
  outline-offset: 2px;
}

.tabular-nums {
  font-variant-numeric: tabular-nums;
}

.app-header {
  min-height: 68px;
  padding: 12px clamp(16px, 3vw, 40px);
  border-bottom: 1px solid var(--border);
  background: rgba(16, 18, 16, 0.96);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  position: sticky;
  top: 0;
  z-index: 20;
  backdrop-filter: blur(14px);
}

.brand {
  display: flex;
  align-items: center;
  gap: 11px;
  min-width: 0;
}

.brand-mark {
  width: 38px;
  height: 38px;
  border: 1px solid #6f5925;
  border-radius: 8px;
  background: var(--bottom-soft);
  color: var(--bottom);
  display: grid;
  place-items: center;
  flex: 0 0 auto;
}

.brand-mark svg {
  width: 21px;
  height: 21px;
}

.brand h1 {
  margin: 0;
  font-size: 18px;
  line-height: 1.2;
  font-weight: 500;
}

.brand p {
  margin: 3px 0 0;
  color: var(--muted);
  font-size: 12px;
}

.header-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  min-width: 0;
}

.data-state {
  min-width: 0;
  margin-right: 4px;
  color: var(--text-soft);
  font-size: 12px;
  display: flex;
  align-items: center;
  gap: 7px;
}

.status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--muted);
  box-shadow: 0 0 0 3px rgba(143, 153, 146, 0.12);
  flex: 0 0 auto;
}

.data-state.is-live .status-dot {
  background: var(--price);
  box-shadow: 0 0 0 3px rgba(89, 212, 165, 0.13);
}

.data-state.is-cache .status-dot {
  background: var(--bottom);
  box-shadow: 0 0 0 3px rgba(242, 199, 92, 0.13);
}

.data-state.is-error .status-dot {
  background: var(--top);
  box-shadow: 0 0 0 3px rgba(255, 113, 103, 0.13);
}

.icon-button {
  width: 38px;
  height: 38px;
  padding: 0;
  border: 1px solid var(--border);
  border-radius: 7px;
  background: var(--surface);
  display: inline-grid;
  place-items: center;
  cursor: pointer;
  position: relative;
  transition: background-color 150ms ease, border-color 150ms ease, transform 150ms ease;
}

.icon-button:hover {
  background: var(--surface-soft);
  border-color: var(--border-strong);
}

.icon-button:active {
  transform: translateY(1px);
}

.icon-button:disabled {
  cursor: wait;
  opacity: 0.68;
}

.icon-button.is-spinning svg {
  animation: spin 800ms linear infinite;
}

.icon-button svg {
  width: 17px;
  height: 17px;
}

[data-tooltip]::after {
  content: attr(data-tooltip);
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  width: max-content;
  max-width: 180px;
  padding: 5px 8px;
  border: 1px solid var(--border);
  border-radius: 5px;
  background: #252a26;
  color: var(--text);
  box-shadow: var(--shadow);
  font-size: 12px;
  line-height: 1.3;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translateY(-2px);
  transition: opacity 120ms ease, transform 120ms ease, visibility 120ms ease;
  z-index: 50;
}

[data-tooltip]:hover::after,
[data-tooltip]:focus-visible::after {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.app-main {
  width: min(1560px, 100%);
  margin: 0 auto;
  padding: 0 clamp(14px, 2.4vw, 36px) 36px;
}

.ticker-band {
  min-height: 96px;
  padding: 18px 0;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
}

.ticker-price {
  display: flex;
  align-items: baseline;
  gap: 13px;
  min-width: 0;
  flex-wrap: wrap;
}

.ticker-price .symbol {
  color: var(--muted);
  font-size: 12px;
  font-weight: 500;
}

.ticker-price strong {
  font-size: 30px;
  line-height: 1;
  font-weight: 500;
}

.change {
  font-size: 13px;
  font-weight: 500;
}

.change.positive {
  color: var(--price);
}

.change.negative {
  color: var(--top);
}

.change.neutral {
  color: var(--muted);
}

.ticker-metrics {
  margin: 0;
  display: grid;
  grid-template-columns: repeat(4, minmax(96px, auto));
  gap: clamp(18px, 3vw, 48px);
}

.ticker-metrics div {
  min-width: 0;
}

.ticker-metrics dt {
  margin-bottom: 5px;
  color: var(--muted);
  font-size: 12px;
}

.ticker-metrics dd {
  margin: 0;
  color: var(--text-soft);
  font-size: 14px;
  white-space: nowrap;
}

.dashboard-grid {
  margin-top: 24px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 370px;
  gap: 18px;
  align-items: stretch;
}

.tool-panel {
  min-width: 0;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: var(--surface);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.tool-header {
  min-height: 70px;
  padding: 16px 18px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
}

.tool-header h2,
.section-heading h2 {
  margin: 0;
  font-size: 15px;
  line-height: 1.3;
  font-weight: 500;
}

.heading-line {
  display: flex;
  align-items: center;
  gap: 9px;
  flex-wrap: wrap;
}

.model-badge,
.state-chip,
.source-label {
  min-height: 22px;
  padding: 2px 7px;
  border: 1px solid var(--border-strong);
  border-radius: 5px;
  color: var(--text-soft);
  background: var(--surface-soft);
  font-size: 11px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  white-space: nowrap;
}

.state-chip.bottom {
  border-color: #796429;
  background: var(--bottom-soft);
  color: var(--bottom);
}

.state-chip.top {
  border-color: #81413d;
  background: var(--top-soft);
  color: var(--top);
}

.state-chip.neutral {
  color: var(--text-soft);
}

.chart-legend,
.signal-legend {
  margin-top: 9px;
  display: flex;
  align-items: center;
  gap: 14px;
  color: var(--muted);
  font-size: 12px;
  flex-wrap: wrap;
}

.chart-legend span,
.signal-legend span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.legend-swatch {
  width: 14px;
  height: 3px;
  border-radius: 2px;
  display: inline-block;
  flex: 0 0 auto;
}

.legend-swatch.price {
  background: var(--price);
}

.legend-swatch.ma200 {
  background: var(--bottom);
}

.legend-swatch.ma2y {
  background: var(--blue);
}

.legend-swatch.ma200w {
  background: var(--violet);
}

.legend-swatch.bottom {
  background: var(--bottom);
}

.legend-swatch.top {
  background: var(--top);
}

.chart-controls {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
}

.segmented {
  height: 34px;
  padding: 3px;
  border: 1px solid var(--border);
  border-radius: 7px;
  background: var(--bg);
  display: inline-flex;
  align-items: center;
  gap: 2px;
}

.segmented button {
  height: 26px;
  min-width: 44px;
  padding: 0 9px;
  border: 0;
  border-radius: 5px;
  background: transparent;
  color: var(--muted);
  font-size: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  cursor: pointer;
}

.segmented button:hover {
  color: var(--text);
  background: var(--surface-soft);
}

.segmented button[aria-pressed="true"] {
  color: var(--text);
  background: var(--surface-soft);
  box-shadow: inset 0 0 0 1px var(--border-strong);
}

.segmented svg {
  width: 14px;
  height: 14px;
}

.price-chart {
  width: 100%;
  height: 470px;
  background: var(--surface);
}

.chart-footer {
  min-height: 44px;
  padding: 10px 18px;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  color: var(--muted);
  font-size: 12px;
}

.decision-panel {
  display: flex;
  flex-direction: column;
}

.decision-panel .tool-header {
  align-items: center;
}

.coverage-line {
  margin: 7px 0 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: var(--muted);
  font-size: 12px;
}

.coverage-line span:first-child {
  color: var(--text-soft);
  font-weight: 500;
}

.coverage-line strong {
  color: var(--text-soft);
  font-weight: 500;
}

.score-stack {
  padding: 17px 18px 14px;
  border-bottom: 1px solid var(--border);
  display: grid;
  gap: 17px;
}

.score-row {
  min-width: 0;
}

.score-meta {
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: var(--text-soft);
  font-size: 13px;
}

.score-meta span {
  display: inline-flex;
  align-items: center;
  gap: 7px;
}

.score-meta strong {
  color: var(--text);
  font-size: 20px;
  line-height: 1;
  font-weight: 500;
}

.score-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
}

.score-dot.bottom {
  background: var(--bottom);
}

.score-dot.top {
  background: var(--top);
}

.meter {
  height: 9px;
  border-radius: 4px;
  background: var(--surface-soft);
  position: relative;
  overflow: hidden;
}

.meter > span {
  display: block;
  width: 0;
  height: 100%;
  background: var(--bottom);
  border-radius: inherit;
  transition: width 360ms ease;
}

.top-meter > span {
  background: var(--top);
}

.threshold {
  width: 1px;
  height: 100%;
  background: rgba(242, 245, 242, 0.28);
  position: absolute;
  top: 0;
  z-index: 2;
}

.threshold-mid {
  left: 45%;
}

.threshold-high {
  left: 70%;
}

.zone-panel {
  padding: 14px 18px;
  border-bottom: 1px solid var(--border);
  background: rgba(34, 39, 35, 0.34);
  display: grid;
  gap: 13px;
}

.zone-row {
  min-width: 0;
  display: grid;
  grid-template-columns: 76px minmax(0, 1fr);
  align-items: center;
  gap: 12px;
}

.zone-heading {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.zone-heading span {
  color: var(--muted);
  font-size: 10px;
}

.zone-heading strong {
  color: var(--text);
  font-size: 14px;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
}

.zone-track {
  height: 28px;
  border: 1px solid var(--border);
  border-radius: 5px;
  background: var(--bg);
  display: flex;
  position: relative;
  overflow: hidden;
}

.zone-track > span {
  min-width: 0;
  height: 100%;
  border-right: 1px solid var(--border);
  color: var(--muted);
  font-size: 10px;
  display: grid;
  place-items: center;
  position: relative;
  z-index: 1;
}

.zone-track > span:last-of-type {
  border-right: 0;
}

.zone-track > span.is-active {
  background: var(--bottom-soft);
  color: var(--bottom);
  font-weight: 500;
}

.top-zone-track > span.is-active {
  background: var(--top-soft);
  color: var(--top);
}

.zone-track > i {
  width: 2px;
  height: 34px;
  background: var(--text);
  position: absolute;
  left: 0;
  top: -4px;
  z-index: 3;
  transform: translateX(-1px);
  transition: left 300ms ease;
  pointer-events: none;
}

.action-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border-bottom: 1px solid var(--border);
}

.primary-action,
.secondary-action {
  min-width: 0;
  min-height: 122px;
  padding: 17px 18px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.primary-action {
  background: rgba(242, 199, 92, 0.07);
  border-right: 1px solid var(--border);
}

.secondary-action {
  background: rgba(255, 113, 103, 0.05);
}

.primary-action span,
.secondary-action span {
  color: var(--muted);
  font-size: 12px;
}

.primary-action strong,
.secondary-action strong {
  margin: 6px 0 3px;
  font-size: 30px;
  line-height: 1;
  font-weight: 500;
}

.primary-action strong {
  color: var(--bottom);
}

.secondary-action strong {
  color: var(--top);
}

.primary-action small,
.secondary-action small {
  color: var(--text-soft);
  font-size: 12px;
}

.confirmation-row {
  min-height: 76px;
  padding: 13px 18px;
  border-bottom: 1px solid var(--border);
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}

.confirmation-row div {
  min-width: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
}

.confirmation-row div + div {
  padding-left: 18px;
  border-left: 1px solid var(--border);
}

.confirmation-row span {
  color: var(--muted);
  font-size: 11px;
}

.confirmation-row strong {
  overflow: hidden;
  color: var(--text-soft);
  font-size: 13px;
  font-weight: 500;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.score-chart-wrap {
  min-height: 226px;
  padding: 15px 14px 8px;
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
}

.mini-heading {
  padding: 0 4px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.mini-heading h3 {
  margin: 0;
  font-size: 13px;
  font-weight: 500;
}

.mini-heading span {
  color: var(--muted);
  font-size: 11px;
}

.score-readout {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 9px;
  flex-wrap: wrap;
}

.score-readout strong {
  color: var(--muted);
  font-size: 11px;
  font-weight: 400;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.score-readout b {
  color: var(--text);
  font-size: 12px;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
}

.score-legend {
  margin-top: 9px;
  display: grid;
  gap: 9px;
}

.score-legend div {
  display: flex;
  align-items: baseline;
  gap: 10px;
}

.score-legend > div > span {
  min-width: 82px;
  color: var(--text-soft);
  font-size: 12px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.score-legend small {
  min-width: 0;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.35;
}

.score-context {
  min-height: 38px;
  margin: 10px 0 2px;
  padding: 9px 10px;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--surface-soft);
  color: var(--text-soft);
  font-size: 12px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.score-context.is-hover {
  border-color: var(--border-strong);
  background: var(--surface-raised);
}

.score-chart {
  width: 100%;
  height: 184px;
  margin-top: 7px;
}

.data-section {
  margin-top: 34px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
}

.section-heading {
  margin-bottom: 15px;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px;
}

.section-heading p {
  margin: 5px 0 0;
  color: var(--muted);
  font-size: 12px;
}

.source-label svg {
  width: 13px;
  height: 13px;
}

.table-wrap,
.signal-table-wrap {
  width: 100%;
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
}

th,
td {
  padding: 13px 14px;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
}

th {
  color: var(--muted);
  background: rgba(29, 33, 30, 0.72);
  font-size: 11px;
  font-weight: 500;
  white-space: nowrap;
}

td {
  color: var(--text-soft);
  font-size: 13px;
}

tbody tr:hover {
  background: rgba(34, 39, 35, 0.54);
}

th.numeric,
td.numeric {
  text-align: right;
}

td.numeric {
  color: var(--text);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.level-name {
  color: var(--text);
  font-weight: 500;
  white-space: nowrap;
}

.distance-positive {
  color: var(--price);
}

.distance-negative {
  color: var(--top);
}

.row-status {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}

.row-status::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--muted);
}

.row-status.bottom::before {
  background: var(--bottom);
}

.row-status.top::before {
  background: var(--top);
}

.row-status.neutral::before {
  background: var(--blue);
}

.empty-cell {
  height: 92px;
  color: var(--muted);
  text-align: center;
}

.signal-legend {
  margin-top: 0;
}

.signal-table {
  table-layout: fixed;
}

.signal-table th:first-child,
.signal-table td:first-child {
  width: 20%;
}

.signal-table th:nth-child(2),
.signal-table td:nth-child(2) {
  width: 22%;
}

.signal-table th:nth-child(3),
.signal-table td:nth-child(3) {
  width: 10%;
}

.signal-table th:nth-child(4),
.signal-table td:nth-child(4),
.signal-table th:nth-child(5),
.signal-table td:nth-child(5) {
  width: 24%;
}

.signal-name {
  color: var(--text);
  font-weight: 500;
}

.signal-name small {
  display: block;
  margin-top: 2px;
  color: var(--muted);
  font-size: 10px;
  font-weight: 400;
}

.signal-value {
  color: var(--text-soft);
  font-variant-numeric: tabular-nums;
}

.contribution {
  min-width: 150px;
  display: grid;
  grid-template-columns: minmax(70px, 1fr) 36px;
  align-items: center;
  gap: 9px;
}

.contribution-track {
  height: 7px;
  border-radius: 4px;
  background: var(--surface-soft);
  overflow: hidden;
}

.contribution-fill {
  display: block;
  width: 0;
  height: 100%;
  background: var(--bottom);
  border-radius: inherit;
  transition: width 300ms ease;
}

.contribution-fill.top {
  background: var(--top);
}

.contribution-value {
  color: var(--muted);
  font-size: 11px;
  font-variant-numeric: tabular-nums;
  text-align: right;
}

.coverage-notes {
  margin-top: 14px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px 18px;
  color: var(--muted);
  font-size: 11px;
  flex-wrap: wrap;
}

.coverage-notes span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.coverage-notes span:first-child {
  color: var(--price);
}

.coverage-notes svg {
  width: 13px;
  height: 13px;
}

.app-footer {
  width: min(1560px, 100%);
  min-height: 76px;
  margin: 0 auto;
  padding: 22px clamp(14px, 2.4vw, 36px);
  border-top: 1px solid var(--border);
  color: var(--muted);
  font-size: 11px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.method-dialog {
  width: min(620px, calc(100% - 28px));
  max-height: min(760px, calc(100vh - 28px));
  padding: 0;
  border: 1px solid var(--border-strong);
  border-radius: 8px;
  background: var(--surface-raised);
  color: var(--text);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.48);
  overflow: auto;
}

.method-dialog::backdrop {
  background: rgba(0, 0, 0, 0.72);
  backdrop-filter: blur(4px);
}

.dialog-header {
  min-height: 78px;
  padding: 16px 18px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.dialog-kicker {
  color: var(--price);
  font-size: 11px;
}

.dialog-header h2 {
  margin: 3px 0 0;
  font-size: 18px;
  font-weight: 500;
}

.dialog-content {
  padding: 4px 18px 10px;
}

.dialog-content section {
  padding: 16px 0;
  border-bottom: 1px solid var(--border);
}

.dialog-content section:last-child {
  border-bottom: 0;
}

.dialog-content h3 {
  margin: 0 0 7px;
  font-size: 13px;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 8px;
}

.dialog-content h3 svg {
  width: 16px;
  height: 16px;
  color: var(--price);
}

.dialog-content p {
  margin: 0;
  color: var(--text-soft);
  font-size: 13px;
}

.dialog-footer {
  padding: 13px 18px;
  border-top: 1px solid var(--border);
  background: var(--surface);
  color: var(--muted);
  font-size: 11px;
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.loading-overlay {
  position: fixed;
  inset: 0;
  z-index: 100;
  background: rgba(16, 18, 16, 0.9);
  color: var(--text-soft);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  transition: opacity 220ms ease, visibility 220ms ease;
}

.loading-overlay.is-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.loading-mark {
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  color: var(--price);
}

.loading-mark svg {
  width: 24px;
  height: 24px;
  animation: spin 900ms linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

@media (max-width: 1120px) {
  .dashboard-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .decision-panel {
    display: grid;
    grid-template-columns: minmax(260px, 0.9fr) minmax(340px, 1.1fr);
  }

  .decision-panel .tool-header,
  .decision-panel .score-stack,
  .decision-panel .action-grid,
  .decision-panel .confirmation-row {
    grid-column: 1;
  }

  .score-chart-wrap {
    grid-column: 2;
    grid-row: 1 / span 4;
    min-height: 100%;
    border-left: 1px solid var(--border);
  }
}

@media (max-width: 820px) {
  .app-header {
    position: static;
  }

  .data-state {
    max-width: 150px;
    overflow: hidden;
  }

  .data-state span:last-child {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .ticker-band {
    align-items: flex-start;
    flex-direction: column;
    gap: 17px;
  }

  .ticker-metrics {
    width: 100%;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px 24px;
  }

  .tool-header {
    flex-direction: column;
    align-items: stretch;
  }

  .chart-controls {
    justify-content: space-between;
  }

  .price-chart {
    height: 390px;
  }

  .decision-panel {
    display: flex;
  }

  .score-chart-wrap {
    border-left: 0;
    border-top: 1px solid var(--border);
  }

  .signal-table {
    min-width: 760px;
  }
}

@media (max-width: 560px) {
  .app-header {
    min-height: 62px;
    padding: 10px 14px;
  }

  .brand-mark {
    width: 34px;
    height: 34px;
  }

  .brand h1 {
    font-size: 16px;
  }

  .brand p,
  .data-state {
    display: none;
  }

  .ticker-price strong {
    font-size: 26px;
  }

  .ticker-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .dashboard-grid {
    margin-top: 18px;
  }

  .chart-controls {
    align-items: stretch;
    flex-direction: column;
  }

  .segmented {
    width: 100%;
  }

  .segmented button {
    flex: 1 1 0;
  }

  .price-chart {
    height: 340px;
  }

  .chart-footer {
    align-items: flex-start;
    flex-direction: column;
    gap: 4px;
  }

  .action-grid {
    grid-template-columns: 1fr;
  }

  .primary-action {
    border-right: 0;
    border-bottom: 1px solid var(--border);
  }

  .section-heading {
    align-items: flex-start;
    flex-direction: column;
  }

  th,
  td {
    padding: 11px 12px;
  }

  .levels-section table {
    min-width: 650px;
  }

  .app-footer {
    align-items: flex-start;
    flex-direction: column;
    gap: 7px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}
