:root {
  --canvas: #0a0e11;
  --canvas-raised: #0d1216;
  --surface: #11181c;
  --surface-raised: #162025;
  --surface-hover: #19252a;
  --line: #26343a;
  --line-strong: #33434a;
  --text: #e7eef0;
  --text-soft: #b6c2c6;
  --muted: #7f9298;
  --muted-deep: #5f7177;
  --accent: #55d6bd;
  --accent-quiet: #1b4944;
  --positive: #7ed89b;
  --positive-quiet: #173a2a;
  --warning: #e8be68;
  --warning-quiet: #473818;
  --negative: #ed8d83;
  --negative-quiet: #4a2422;
  --info: #83b8e9;
  --sidebar-width: 232px;
  --radius: 4px;
  --shadow-panel: 0 12px 32px rgb(0 0 0 / 18%);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--text);
  background: var(--canvas);
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  min-height: 100%;
  background: var(--canvas);
}

body {
  min-width: 320px;
  min-height: 100vh;
  margin: 0;
  color: var(--text);
  background: var(--canvas);
  font-size: 14px;
  line-height: 1.45;
  text-rendering: optimizeLegibility;
}

button,
input,
select {
  font: inherit;
}

button {
  color: inherit;
}

button:focus-visible,
input:focus-visible,
select:focus-visible,
[tabindex]:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

button:not(:disabled),
select:not(:disabled) {
  cursor: pointer;
}

button:disabled {
  cursor: not-allowed;
  opacity: 0.58;
}

svg {
  display: block;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

h1,
h2,
h3,
p {
  margin: 0;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.eyebrow {
  color: var(--muted);
  font-size: 10px;
  font-weight: 720;
  letter-spacing: 0.1em;
  line-height: 1.2;
  text-transform: uppercase;
}

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--text);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 15px;
  font-weight: 780;
  letter-spacing: 0.04em;
  line-height: 1;
}

.wordmark-mark {
  width: 22px;
  height: 22px;
  color: var(--accent);
  fill: currentColor;
  stroke: none;
}

.wordmark-divider {
  color: var(--muted-deep);
  font-weight: 400;
}

.wordmark-subtitle {
  color: var(--text-soft);
  font-size: 10px;
  font-weight: 650;
  letter-spacing: 0.09em;
}

.login-screen {
  display: grid;
  min-height: 100vh;
  padding: 32px;
  place-items: center;
  background:
    linear-gradient(90deg, transparent 0, transparent calc(50% - 1px), rgb(83 112 118 / 9%) calc(50% - 1px), rgb(83 112 118 / 9%) 50%, transparent 50%),
    var(--canvas);
  background-size: 132px 100%;
}

.login-panel {
  width: min(100%, 410px);
  padding: 32px;
  border: 1px solid var(--line);
  border-top-color: var(--line-strong);
  background: var(--surface);
  box-shadow: var(--shadow-panel);
}

.login-copy {
  margin-top: 43px;
}

.login-copy h1 {
  margin-top: 10px;
  font-size: 26px;
  font-weight: 670;
  letter-spacing: -0.035em;
  line-height: 1.12;
}

.login-copy p:last-child {
  max-width: 310px;
  margin-top: 12px;
  color: var(--text-soft);
  font-size: 13px;
  line-height: 1.55;
}

.login-form {
  display: grid;
  gap: 9px;
  margin-top: 31px;
}

.login-form label {
  color: var(--text-soft);
  font-size: 12px;
  font-weight: 650;
}

.password-field {
  display: flex;
  align-items: center;
  border: 1px solid var(--line-strong);
  background: var(--canvas-raised);
}

.password-field:focus-within {
  border-color: var(--accent);
}

.password-field input {
  width: 100%;
  min-width: 0;
  height: 41px;
  padding: 0 9px 0 12px;
  border: 0;
  outline: 0;
  color: var(--text);
  background: transparent;
}

.icon-button {
  display: grid;
  width: 36px;
  height: 36px;
  margin-right: 2px;
  padding: 0;
  border: 0;
  place-items: center;
  color: var(--muted);
  background: transparent;
}

.icon-button:hover {
  color: var(--text);
}

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

.form-message {
  min-height: 18px;
  margin: 2px 0 -2px;
  color: var(--negative);
  font-size: 12px;
}

.primary-button {
  min-height: 40px;
  margin-top: 8px;
  padding: 0 16px;
  border: 1px solid #70e0ca;
  border-radius: 2px;
  color: #071110;
  background: var(--accent);
  font-size: 13px;
  font-weight: 750;
}

.primary-button:hover:not(:disabled) {
  background: #72dfc9;
}

.login-footnote {
  margin-top: 25px;
  padding-top: 17px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 11px;
  line-height: 1.45;
}

.app-shell {
  display: grid;
  grid-template-columns: var(--sidebar-width) minmax(0, 1fr);
  min-height: 100vh;
}

.sidebar {
  position: sticky;
  top: 0;
  display: flex;
  min-height: 100vh;
  flex-direction: column;
  border-right: 1px solid var(--line);
  background: #0d1317;
}

.brand-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 63px;
  padding: 0 18px;
  border-bottom: 1px solid var(--line);
}

.private-badge {
  padding: 3px 5px;
  border: 1px solid #315752;
  color: var(--accent);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 8px;
  font-weight: 720;
  letter-spacing: 0.08em;
}

.primary-nav {
  display: grid;
  gap: 3px;
  padding: 16px 11px;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 11px;
  width: 100%;
  min-height: 39px;
  padding: 0 10px;
  border: 1px solid transparent;
  border-radius: 3px;
  color: var(--text-soft);
  background: transparent;
  text-align: left;
  font-size: 13px;
}

.nav-item svg {
  width: 17px;
  height: 17px;
  color: var(--muted);
}

.nav-item:hover {
  color: var(--text);
  background: rgb(255 255 255 / 3%);
}

.nav-item.is-active {
  border-color: #2f4748;
  color: var(--text);
  background: #142524;
}

.nav-item.is-active svg {
  color: var(--accent);
}

.sidebar-status {
  display: grid;
  gap: 6px;
  margin: auto 18px 0;
  padding: 14px 0;
  border-top: 1px solid var(--line);
}

.status-line,
.live-indicator {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--text-soft);
  font-size: 12px;
}

.status-dot {
  display: inline-block;
  width: 7px;
  height: 7px;
  flex: 0 0 7px;
  border-radius: 50%;
  background: var(--muted-deep);
  box-shadow: 0 0 0 3px rgb(113 135 140 / 10%);
}

.status-dot.is-live {
  background: var(--positive);
  box-shadow: 0 0 0 3px rgb(126 216 155 / 12%);
}

.status-dot.is-reconnecting {
  background: var(--warning);
  box-shadow: 0 0 0 3px rgb(232 190 104 / 12%);
}

.status-dot.is-error {
  background: var(--negative);
  box-shadow: 0 0 0 3px rgb(237 141 131 / 12%);
}

.sequence-text,
.last-updated,
.muted-inline {
  color: var(--muted);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 10px;
}

.sidebar-account {
  display: grid;
  gap: 12px;
  margin-top: 0;
  padding: 14px 18px 17px;
  border-top: 1px solid var(--line);
}

.account-label {
  display: flex;
  align-items: center;
  gap: 9px;
  min-width: 0;
}

.account-avatar {
  display: grid;
  width: 27px;
  height: 27px;
  flex: 0 0 27px;
  border: 1px solid #306059;
  border-radius: 3px;
  place-items: center;
  color: var(--accent);
  background: #112725;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 12px;
  font-weight: 760;
}

.account-label strong,
.account-label small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.account-label strong {
  max-width: 145px;
  color: var(--text-soft);
  font-size: 11px;
  font-weight: 640;
}

.account-label small {
  margin-top: 1px;
  color: var(--muted);
  font-size: 10px;
}

.text-button {
  width: fit-content;
  min-height: 24px;
  padding: 0;
  border: 0;
  color: var(--muted);
  background: transparent;
  font-size: 11px;
  text-decoration: underline;
  text-decoration-color: transparent;
  text-underline-offset: 3px;
}

.text-button:hover {
  color: var(--text);
  text-decoration-color: currentColor;
}

.main-column {
  min-width: 0;
}

.topbar {
  position: sticky;
  z-index: 10;
  top: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 63px;
  padding: 11px 28px;
  border-bottom: 1px solid var(--line);
  background: rgb(10 14 17 / 94%);
  backdrop-filter: blur(14px);
}

.topbar-title h1 {
  margin-top: 4px;
  font-size: 18px;
  font-weight: 670;
  letter-spacing: -0.022em;
  line-height: 1.15;
}

.topbar-meta {
  display: flex;
  align-items: center;
  gap: 17px;
}

.workspace {
  width: min(100%, 1640px);
  margin: 0 auto;
  padding: 25px 28px 35px;
}

.metric-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--surface);
}

.metric-cell {
  min-width: 0;
  padding: 15px 17px 14px;
  border-right: 1px solid var(--line);
}

.metric-cell:last-child {
  border-right: 0;
}

.metric-label,
.metric-detail {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.metric-label {
  color: var(--muted);
  font-size: 10px;
  font-weight: 670;
  letter-spacing: 0.075em;
  text-transform: uppercase;
}

.metric-value {
  display: block;
  margin-top: 5px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 21px;
  font-weight: 680;
  letter-spacing: -0.055em;
  line-height: 1.2;
}

.metric-detail {
  margin-top: 4px;
  color: var(--muted);
  font-size: 10px;
}

.source-strip {
  display: flex;
  align-items: center;
  gap: 18px;
  min-height: 47px;
  margin-top: 12px;
  padding: 8px 14px;
  border: 1px solid var(--line);
  background: var(--surface);
}

.source-strip-title {
  display: flex;
  min-width: 129px;
  flex-direction: column;
  gap: 2px;
  color: var(--text-soft);
  font-size: 11px;
  font-weight: 640;
}

.source-strip-list {
  display: flex;
  flex: 1;
  flex-wrap: wrap;
  gap: 7px;
}

.source-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 27px;
  padding: 0 8px;
  border: 1px solid var(--line);
  color: var(--text-soft);
  background: var(--canvas-raised);
  font-size: 10px;
}

.source-chip .status-dot {
  width: 6px;
  height: 6px;
  flex-basis: 6px;
}

.source-chip-time {
  color: var(--muted);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 9px;
}

.signals-section {
  margin-top: 27px;
}

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

.section-heading-row h2,
.secondary-heading h2 {
  margin-top: 5px;
  font-size: 19px;
  font-weight: 660;
  letter-spacing: -0.028em;
  line-height: 1.2;
}

.feed-actions {
  display: flex;
  align-items: center;
  gap: 14px;
}

.result-count {
  color: var(--muted);
  font-size: 11px;
}

.icon-text-button {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 28px;
  padding: 0 0 0 7px;
  border: 0;
  color: var(--text-soft);
  background: transparent;
  font-size: 11px;
}

.icon-text-button:hover {
  color: var(--accent);
}

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

.filterbar {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
}

.search-field {
  display: flex;
  align-items: center;
  width: min(100%, 320px);
  height: 34px;
  border: 1px solid var(--line);
  background: var(--surface);
}

.search-field:focus-within {
  border-color: var(--line-strong);
  box-shadow: inset 0 -1px 0 var(--accent);
}

.search-field svg {
  width: 16px;
  height: 16px;
  margin-left: 10px;
  color: var(--muted);
}

.search-field input {
  width: 100%;
  min-width: 0;
  height: 100%;
  padding: 0 10px 0 8px;
  border: 0;
  outline: 0;
  color: var(--text);
  background: transparent;
  font-size: 12px;
}

.search-field input::placeholder {
  color: var(--muted-deep);
}

.segmented-control {
  display: inline-flex;
  min-height: 34px;
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--surface);
}

.segmented-control button {
  padding: 0 10px;
  border: 0;
  border-right: 1px solid var(--line);
  color: var(--muted);
  background: transparent;
  font-size: 11px;
}

.segmented-control button:last-child {
  border-right: 0;
}

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

.segmented-control button.is-selected {
  color: var(--text);
  background: #1a2a2c;
  box-shadow: inset 0 -1px 0 var(--accent);
}

.select-field select {
  height: 34px;
  padding: 0 28px 0 9px;
  border: 1px solid var(--line);
  border-radius: 0;
  outline: 0;
  color: var(--text-soft);
  background-color: var(--surface);
  font-size: 11px;
}

.signal-workspace {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 312px;
  align-items: start;
  gap: 10px;
}

.table-wrap {
  position: relative;
  min-width: 0;
  overflow: auto;
  border: 1px solid var(--line);
  background: var(--surface);
}

.signal-table {
  width: 100%;
  min-width: 770px;
  border-collapse: collapse;
  table-layout: fixed;
}

.signal-table th {
  position: sticky;
  z-index: 1;
  top: 0;
  height: 34px;
  padding: 0 10px;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  background: #11181c;
  font-size: 9px;
  font-weight: 710;
  letter-spacing: 0.08em;
  text-align: left;
  text-transform: uppercase;
  white-space: nowrap;
}

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

.signal-table th:nth-child(1) { width: 26%; }
.signal-table th:nth-child(2) { width: 12%; }
.signal-table th:nth-child(3) { width: 13%; }
.signal-table th:nth-child(4) { width: 13%; }
.signal-table th:nth-child(5) { width: 8%; }
.signal-table th:nth-child(6) { width: 11%; }
.signal-table th:nth-child(7) { width: 10%; }
.signal-table th:nth-child(8) { width: 7%; }

.signal-table tbody tr {
  cursor: pointer;
  border-bottom: 1px solid rgb(43 57 62 / 75%);
  transition: background-color 100ms ease;
}

.signal-table tbody tr:last-child {
  border-bottom: 0;
}

.signal-table tbody tr:hover {
  background: var(--surface-hover);
}

.signal-table tbody tr.is-selected {
  background: #162728;
  box-shadow: inset 2px 0 0 var(--accent);
}

.signal-table td {
  height: 56px;
  padding: 8px 10px;
  vertical-align: middle;
}

.item-cell {
  min-width: 0;
}

.item-name-row {
  display: flex;
  align-items: center;
  min-width: 0;
  gap: 7px;
}

.item-name {
  overflow: hidden;
  color: var(--text);
  font-size: 12px;
  font-weight: 650;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.market-badge,
.tag-badge,
.basis-badge {
  display: inline-flex;
  align-items: center;
  min-height: 16px;
  padding: 0 4px;
  border: 1px solid var(--line-strong);
  color: var(--text-soft);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 8px;
  font-weight: 680;
  letter-spacing: 0.025em;
  line-height: 1;
  text-transform: uppercase;
  white-space: nowrap;
}

.market-badge.is-auction {
  border-color: #38526f;
  color: var(--info);
  background: #172534;
}

.market-badge.is-bazaar {
  border-color: #326154;
  color: var(--accent);
  background: #142924;
}

.variant-line {
  overflow: hidden;
  margin-top: 3px;
  color: var(--muted);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 9px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.currency,
.roi-value,
.age-value,
.hold-value {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 11px;
  letter-spacing: -0.035em;
  white-space: nowrap;
}

.currency {
  color: var(--text-soft);
}

.currency.is-positive,
.roi-value.is-positive {
  color: var(--positive);
}

.currency.is-negative,
.roi-value.is-negative {
  color: var(--negative);
}

.roi-value {
  color: var(--text-soft);
}

.quality-cell {
  display: grid;
  gap: 3px;
}

.quality-labels {
  display: flex;
  justify-content: space-between;
  color: var(--muted);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 8px;
  letter-spacing: -0.02em;
}

.quality-track {
  height: 3px;
  overflow: hidden;
  background: #253139;
}

.quality-fill {
  display: block;
  width: var(--value, 0%);
  height: 100%;
  background: var(--accent);
}

.hold-value,
.age-value {
  color: var(--muted);
}

.empty-state {
  display: grid;
  min-height: 272px;
  padding: 34px;
  place-items: center;
  align-content: center;
  gap: 7px;
  text-align: center;
}

.empty-state strong {
  font-size: 13px;
  font-weight: 650;
}

.empty-state p {
  max-width: 270px;
  color: var(--muted);
  font-size: 11px;
}

.empty-state .text-button {
  margin-top: 5px;
}

.detail-panel {
  position: sticky;
  top: 76px;
  min-height: 380px;
  border: 1px solid var(--line);
  background: var(--surface);
}

.detail-empty {
  display: grid;
  min-height: 380px;
  padding: 31px;
  place-items: center;
  align-content: center;
  gap: 8px;
  text-align: center;
}

.detail-empty svg {
  width: 25px;
  height: 25px;
  margin-bottom: 3px;
  color: var(--muted-deep);
}

.detail-empty strong {
  font-size: 13px;
  font-weight: 650;
}

.detail-empty p {
  max-width: 190px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.55;
}

.detail-head {
  padding: 17px 17px 13px;
  border-bottom: 1px solid var(--line);
}

.detail-market-row,
.detail-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.detail-title {
  overflow: hidden;
  margin-top: 9px;
  color: var(--text);
  font-size: 16px;
  font-weight: 670;
  letter-spacing: -0.027em;
  line-height: 1.2;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.detail-variant {
  display: -webkit-box;
  overflow: hidden;
  margin-top: 5px;
  color: var(--muted);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 9px;
  line-height: 1.45;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.detail-section {
  padding: 14px 17px;
  border-bottom: 1px solid var(--line);
}

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

.detail-section-title {
  margin-bottom: 10px;
  color: var(--muted);
  font-size: 9px;
  font-weight: 730;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.pricing-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px 12px;
}

.pricing-cell span,
.evidence-row span,
.detail-meta-row span {
  display: block;
  color: var(--muted);
  font-size: 10px;
}

.pricing-cell strong,
.evidence-row strong,
.detail-meta-row strong {
  display: block;
  overflow: hidden;
  margin-top: 2px;
  color: var(--text-soft);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 11px;
  font-weight: 620;
  letter-spacing: -0.035em;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.pricing-cell.is-net strong {
  color: var(--positive);
}

.quality-detail {
  display: grid;
  gap: 10px;
}

.quality-detail-row {
  display: grid;
  grid-template-columns: 77px 1fr 31px;
  align-items: center;
  gap: 8px;
}

.quality-detail-row > span {
  color: var(--text-soft);
  font-size: 10px;
}

.quality-detail-row > strong {
  color: var(--muted);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 10px;
  font-weight: 580;
  text-align: right;
}

.detail-track {
  height: 4px;
  overflow: hidden;
  background: #253139;
}

.detail-track i {
  display: block;
  width: var(--value, 0%);
  height: 100%;
  background: var(--accent);
}

.evidence-list,
.detail-meta {
  display: grid;
  gap: 9px;
}

.evidence-row,
.detail-meta-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 11px;
}

.evidence-row strong,
.detail-meta-row strong {
  max-width: 60%;
  text-align: right;
}

.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 10px;
}

.tag-badge,
.basis-badge {
  min-height: 19px;
  padding: 0 6px;
  color: var(--muted);
  background: var(--canvas-raised);
  font-size: 8px;
}

.copy-button {
  min-height: 25px;
  padding: 0 7px;
  border: 1px solid var(--line-strong);
  border-radius: 2px;
  color: var(--text-soft);
  background: var(--canvas-raised);
  font-size: 10px;
}

.copy-button:hover {
  border-color: #42635f;
  color: var(--accent);
}

.table-note {
  margin-top: 9px;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.5;
}

.secondary-view {
  max-width: 1150px;
}

.secondary-heading {
  max-width: 625px;
  padding: 15px 0 24px;
}

.secondary-heading > p:last-child {
  margin-top: 10px;
  color: var(--text-soft);
  font-size: 13px;
  line-height: 1.6;
}

.source-cards {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.source-card {
  padding: 19px;
  border: 1px solid var(--line);
  background: var(--surface);
}

.source-card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.source-card-top h3 {
  font-size: 14px;
  font-weight: 650;
}

.source-state {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--text-soft);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 10px;
  text-transform: uppercase;
}

.source-card-values {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 9px;
  margin-top: 22px;
}

.source-card-values span {
  display: block;
  color: var(--muted);
  font-size: 10px;
}

.source-card-values strong {
  display: block;
  margin-top: 3px;
  color: var(--text-soft);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: -0.04em;
}

.source-notes {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-top: 10px;
}

.source-notes article {
  min-height: 116px;
  padding: 16px 17px;
  border: 1px solid var(--line);
  background: var(--surface);
}

.source-notes h3,
.methodology-grid h3 {
  font-size: 12px;
  font-weight: 650;
}

.source-notes p,
.methodology-grid p {
  margin-top: 7px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.55;
}

.methodology-heading {
  border-bottom: 1px solid var(--line);
}

.methodology-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0;
  border: 1px solid var(--line);
  border-top: 0;
}

.methodology-grid article {
  min-height: 178px;
  padding: 22px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: var(--surface);
}

.methodology-grid article:nth-child(2n) {
  border-right: 0;
}

.methodology-grid article:nth-last-child(-n + 2) {
  border-bottom: 0;
}

.method-number {
  display: block;
  margin-bottom: 22px;
  color: var(--accent);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 10px;
  font-weight: 660;
}

.toast-region {
  position: fixed;
  z-index: 100;
  right: 20px;
  bottom: 20px;
  display: grid;
  width: min(360px, calc(100vw - 40px));
  gap: 8px;
  pointer-events: none;
}

.toast {
  padding: 10px 12px;
  border: 1px solid var(--line-strong);
  border-left: 2px solid var(--accent);
  color: var(--text-soft);
  background: #151e22;
  box-shadow: var(--shadow-panel);
  font-size: 11px;
}

.toast.is-warning {
  border-left-color: var(--warning);
}

.toast.is-error {
  border-left-color: var(--negative);
}

@media (max-width: 1280px) {
  .signal-workspace {
    grid-template-columns: minmax(0, 1fr) 288px;
  }

  .signal-table th:nth-child(1) { width: 28%; }
  .signal-table th:nth-child(3) { width: 0; }
  .signal-table td.col-resale,
  .signal-table th.col-resale {
    display: none;
  }
}

@media (max-width: 1060px) {
  .app-shell {
    grid-template-columns: 196px minmax(0, 1fr);
  }

  .brand-row,
  .sidebar-account {
    padding-left: 13px;
    padding-right: 13px;
  }

  .sidebar-status {
    margin-left: 13px;
    margin-right: 13px;
  }

  .primary-nav {
    padding-left: 8px;
    padding-right: 8px;
  }

  .topbar,
  .workspace {
    padding-left: 20px;
    padding-right: 20px;
  }

  .signal-workspace {
    grid-template-columns: minmax(0, 1fr);
  }

  .detail-panel {
    position: static;
    min-height: 0;
  }

  .detail-empty {
    min-height: 130px;
  }
}

@media (max-width: 800px) {
  .app-shell {
    display: block;
  }

  .sidebar {
    position: static;
    min-height: 0;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .brand-row {
    height: 53px;
  }

  .primary-nav {
    display: flex;
    gap: 1px;
    padding: 6px 8px;
    overflow-x: auto;
    border-top: 0;
  }

  .nav-item {
    width: auto;
    min-width: max-content;
    min-height: 33px;
    gap: 6px;
    padding: 0 8px;
    font-size: 11px;
  }

  .nav-item svg {
    width: 15px;
    height: 15px;
  }

  .sidebar-status,
  .sidebar-account {
    display: none;
  }

  .topbar {
    position: static;
    min-height: 57px;
    padding: 10px 15px;
  }

  .topbar-meta {
    gap: 8px;
  }

  .last-updated {
    display: none;
  }

  .workspace {
    padding: 16px 15px 26px;
  }

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

  .metric-cell:nth-child(2) {
    border-right: 0;
  }

  .metric-cell:nth-child(-n + 2) {
    border-bottom: 1px solid var(--line);
  }

  .metric-cell {
    padding: 12px;
  }

  .metric-value {
    font-size: 18px;
  }

  .source-strip {
    align-items: start;
    flex-direction: column;
    gap: 7px;
  }

  .source-strip-title {
    flex-direction: row;
    justify-content: space-between;
    width: 100%;
  }

  .section-heading-row {
    align-items: start;
  }

  .filterbar {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .search-field,
  .segmented-control {
    width: 100%;
  }

  .segmented-control button {
    flex: 1;
    padding: 0 5px;
  }

  .select-field select {
    width: 100%;
  }

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

  .signal-table td {
    height: 53px;
  }

  .col-quality,
  .quality-cell,
  .col-hold,
  .hold-cell {
    display: none;
  }

  .source-cards,
  .source-notes,
  .methodology-grid {
    grid-template-columns: 1fr;
  }

  .source-notes article {
    min-height: 0;
  }

  .methodology-grid article,
  .methodology-grid article:nth-child(2n),
  .methodology-grid article:nth-last-child(-n + 2) {
    min-height: 0;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .methodology-grid article:last-child {
    border-bottom: 0;
  }
}

@media (max-width: 480px) {
  .login-screen {
    padding: 16px;
    background: var(--canvas);
  }

  .login-panel {
    padding: 24px;
    box-shadow: none;
  }

  .login-copy {
    margin-top: 34px;
  }

  .wordmark-subtitle,
  .private-badge {
    display: none;
  }

  .feed-actions .icon-text-button span {
    display: none;
  }

  .feed-actions .icon-text-button {
    padding: 3px;
  }

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

  .signal-table th:nth-child(1) { width: 39%; }
  .signal-table th:nth-child(2) { width: 19%; }
  .signal-table th:nth-child(4) { width: 20%; }
  .signal-table th:nth-child(5) { width: 12%; }
  .signal-table th:nth-child(8) { width: 10%; }

  .table-note {
    font-size: 9px;
  }
}

@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;
  }
}
