.ms-trading-monitor {
  --tm-bg: #f2f3f5;
  --tm-panel: #ffffff;
  --tm-line: #d3d7dc;
  --tm-ink: #1f2328;
  --tm-muted: #5f6b76;
  --tm-buy: #1e63d6;
  --tm-sell: #c0392b;
  --tm-profit: #1e63d6;
  --tm-loss: #c0392b;
  --tm-chip: #eef2f6;
  font-family: "Segoe UI", Tahoma, sans-serif;
  color: var(--tm-ink);
}

.ms-trading-monitor__header,
.ms-trading-monitor__shell,
.ms-trading-monitor__account-summary,
.ms-trading-monitor__table-wrap {
  background: var(--tm-panel);
  border: 1px solid var(--tm-line);
}

.ms-trading-monitor__header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 14px 16px;
  margin-bottom: 12px;
}

.ms-trading-monitor__eyebrow {
  margin: 0 0 4px;
  font-size: 12px;
  color: var(--tm-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.ms-trading-monitor__title {
  margin: 0;
  font-size: 26px;
  line-height: 1.1;
}

.ms-trading-monitor__refresh,
.ms-trading-monitor__load-more {
  border: 1px solid #2d6cdf;
  background: #2d6cdf;
  color: #fff;
  font: inherit;
  padding: 9px 14px;
  cursor: pointer;
}

.ms-trading-monitor__shell {
  display: grid;
  grid-template-columns: 280px minmax(0, 1fr);
  min-height: 720px;
}

.ms-trading-monitor__accounts {
  border-right: 1px solid var(--tm-line);
  background: #fafbfc;
}

.ms-trading-monitor__accounts-header {
  padding: 12px 14px;
  font-weight: 700;
  border-bottom: 1px solid var(--tm-line);
}

.ms-trading-monitor__accounts-list {
  display: flex;
  flex-direction: column;
}

.ms-trading-monitor__account-button {
  width: 100%;
  text-align: left;
  background: transparent;
  border: 0;
  border-bottom: 1px solid var(--tm-line);
  padding: 12px 14px;
  cursor: pointer;
}

.ms-trading-monitor__account-button.is-active {
  background: #dce9ff;
}

.ms-trading-monitor__account-label {
  font-size: 17px;
  font-weight: 700;
  margin-bottom: 2px;
}

.ms-trading-monitor__account-meta,
.ms-trading-monitor__account-submeta {
  font-size: 12px;
  color: var(--tm-muted);
}

.ms-trading-monitor__content {
  padding: 12px;
  background: var(--tm-bg);
}

.ms-trading-monitor__account-summary {
  padding: 14px 16px;
  margin-bottom: 12px;
}

.ms-trading-monitor__summary-title {
  margin: 0 0 8px;
  font-size: 21px;
}

.ms-trading-monitor__summary-subtitle {
  margin: 0 0 12px;
  color: var(--tm-muted);
  font-size: 13px;
}

.ms-trading-monitor__chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.ms-trading-monitor__chip {
  background: var(--tm-chip);
  border: 1px solid var(--tm-line);
  padding: 6px 10px;
  font-size: 12px;
}

.ms-trading-monitor__table-wrap {
  overflow: hidden;
}

.ms-trading-monitor__table-scroll {
  overflow: auto;
}

.ms-trading-monitor__table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
  font-size: 13px;
}

.ms-trading-monitor__table th,
.ms-trading-monitor__table td {
  border-bottom: 1px solid var(--tm-line);
  padding: 6px 8px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ms-trading-monitor__table th {
  position: sticky;
  top: 0;
  z-index: 1;
  background: #eff1f4;
  font-weight: 600;
}

.ms-trading-monitor__table tbody tr:nth-child(odd) {
  background: #ffffff;
}

.ms-trading-monitor__table tbody tr:nth-child(even) {
  background: #f8f9fb;
}

.ms-trading-monitor__table td:nth-child(7) {
  background: #ffd8d8;
}

.ms-trading-monitor__trade-type--buy {
  color: var(--tm-buy);
  font-weight: 700;
}

.ms-trading-monitor__trade-type--sell {
  color: var(--tm-sell);
  font-weight: 700;
}

.ms-trading-monitor__profit--positive {
  color: var(--tm-profit);
  font-variant-numeric: tabular-nums;
}

.ms-trading-monitor__profit--negative {
  color: var(--tm-loss);
  font-variant-numeric: tabular-nums;
}

.ms-trading-monitor__placeholder,
.ms-trading-monitor__empty {
  color: var(--tm-muted);
  text-align: center;
  padding: 24px 12px;
}

.ms-trading-monitor__footer {
  display: flex;
  justify-content: center;
  padding: 12px 0 4px;
}

@media (max-width: 1100px) {
  .ms-trading-monitor__shell {
    grid-template-columns: 1fr;
  }

  .ms-trading-monitor__accounts {
    border-right: 0;
    border-bottom: 1px solid var(--tm-line);
  }
}
