:root {
  color-scheme: dark;
  --bg: #0b1220;
  --panel: #0b1220;
  --line: #1f2a3d;
  --grid: rgba(143, 155, 176, 0.08);
  --text: #d9e2f1;
  --muted: #8f9bb0;
  --green: #19c37d;
  --yellow: #f4b400;
  --red: #ef4444;
  --cyan: #22d3ee;
  --oi: #22d3ee;
  --price-scale-width: 62px;
  --price-scale-reserve: 66px;
  --price-scale-shelf-gap: 24px;
  --ui-sans: -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", Roboto, "Noto Sans", "Helvetica Neue", Arial, sans-serif;
}

@font-face {
  font-family: "ALSSchlangeslab-Bold";
  src: url("./assets/fonts/ALSSchlangeslab-Bold.ttf") format("truetype");
  font-style: normal;
  font-weight: 700;
  font-display: swap;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: var(--ui-sans);
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow: hidden;
}

html[data-dashboard-boot="loading"] .news-ribbon {
  opacity: 1;
}

html[data-dashboard-boot="loading"] .topbar {
  opacity: 1;
}

.app {
  height: 100vh;
  display: grid;
  grid-template-rows: auto 1fr auto;
  overflow: hidden;
}

.topbar {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 8px 12px 10px;
  border-bottom: 1px solid var(--line);
  background: #0b1220;
}

.topbar-main {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
}

.brand {
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 156px;
}

.topbar-controls {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 10px;
  min-width: 0;
  flex-wrap: wrap;
}

.topbar-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
  flex-wrap: wrap;
}

.brand-mark {
  display: inline-flex;
  align-items: flex-end;
  gap: 2px;
  color: #f5f8fb;
  text-decoration: none;
  font-family: "ALSSchlangeslab-Bold", "ALS Schlange Slab Bold", "Arvo", "Roboto Slab", "Trebuchet MS", "Segoe UI", Arial, sans-serif;
  font-size: 32px;
  line-height: 0.78;
  letter-spacing: -0.025em;
  font-weight: 700;
  white-space: nowrap;
}

.brand-word {
  display: inline-block;
}

.brand-triangle {
  width: 0;
  height: 0;
  border-left: 6px solid transparent;
  border-right: 6px solid transparent;
  border-top: 10px solid var(--red);
  margin: 0 0 1px;
  transition: border-top-color 160ms ease, border-bottom-color 160ms ease, transform 160ms ease;
}

.brand-mark[data-trend="up"] .brand-triangle {
  border-top: 0;
  border-bottom: 10px solid var(--green);
  transform: translateY(0);
}

.brand-mark[data-trend="down"] .brand-triangle {
  border-bottom: 0;
  border-top: 10px solid var(--red);
  transform: translateY(0);
}

.brand-mark[data-trend="neutral"] .brand-triangle {
  border-top: 0;
  border-bottom: 10px solid var(--green);
  transform: translateY(0);
}

.timeframe-picker {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 0 12px;
  border-left: 1px solid rgba(143, 155, 176, 0.35);
  border-right: 1px solid rgba(143, 155, 176, 0.35);
  height: 42px;
  flex: 0 0 auto;
}

.tf-btn {
  border: 1px solid transparent;
  border-radius: 7px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  color: #c8d1df;
  font-size: 14px;
  font-weight: 600;
  line-height: 1;
  min-height: 28px;
  padding: 5px 8px;
  cursor: pointer;
  transition: color 120ms ease, border-color 120ms ease, background-color 120ms ease;
  touch-action: manipulation;
}

.tf-btn:hover {
  color: #f3f7ff;
}

.tf-btn.active {
  color: #ffd768;
  background: rgba(244, 180, 0, 0.13);
  border-color: rgba(244, 180, 0, 0.4);
  box-shadow: inset 0 0 0 1px rgba(244, 180, 0, 0.08);
}

.dashboard-switcher {
  min-width: 0;
  width: auto;
  overflow: hidden;
}

.dashboard-grid-control {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 38px;
  padding: 0 12px;
  border: 1px solid rgba(34, 211, 238, 0.18);
  border-radius: 10px;
  background: linear-gradient(120deg, rgba(34, 211, 238, 0.08), rgba(11, 18, 32, 0.12));
}

.dashboard-grid-label {
  color: #8f9bb0;
  font-size: 10px;
  font-weight: 700;
  line-height: 1;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.dashboard-grid-input {
  width: 28px;
  border: 0;
  padding: 0;
  background: transparent;
  color: #dff5ff;
  font-size: 13px;
  font-weight: 700;
  line-height: 1;
  text-align: center;
  appearance: textfield;
  outline: none;
}

.dashboard-grid-input::-webkit-outer-spin-button,
.dashboard-grid-input::-webkit-inner-spin-button {
  margin: 0;
  -webkit-appearance: none;
}

.dashboard-grid-input:focus {
  color: #ffd768;
}

.dashboard-grid-sep {
  color: #8f9bb0;
  font-size: 12px;
  font-weight: 700;
  line-height: 1;
}

.topbar-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 0 0 auto;
  white-space: nowrap;
  justify-content: flex-end;
  flex-wrap: wrap;
}

.meta-pill {
  padding: 6px 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #0d1525;
  color: var(--muted);
  font-size: 11px;
}

.sync-pill {
  border-color: rgba(34, 211, 238, 0.28);
  color: #dff5ff;
  font-variant-numeric: tabular-nums;
  min-width: 135px;
  text-align: center;
}

.sync-pill[data-state="live"] {
  border-color: rgba(34, 211, 238, 0.36);
  color: #dff5ff;
}

.sync-pill[data-state="updating"] {
  border-color: rgba(244, 180, 0, 0.42);
  color: #fde68a;
}

.sync-pill[data-state="neutral"] {
  border-color: rgba(143, 155, 176, 0.28);
  color: #c8d1df;
}

.best-setup-pill {
  appearance: none;
  font: inherit;
  text-align: center;
  flex: 0 1 auto;
  max-width: min(320px, 22vw);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  padding: 5px 8px;
  font-size: 10px;
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: 0.01em;
  cursor: pointer;
  transition: border-color 140ms ease, color 140ms ease, background-color 140ms ease;
}

.best-setup-pill[data-compact="true"] {
  flex: 0 0 auto;
  width: 240px;
  max-width: 240px;
  min-width: 240px;
  padding: 4px 8px;
  border-color: rgba(244, 180, 0, 0.28);
  background: rgba(34, 24, 6, 0.46);
  font-size: 10px;
  line-height: 1;
  letter-spacing: 0.02em;
}

.trade-open-pill {
  padding: 5px 9px;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.01em;
  color: #c8d1df;
  border-color: rgba(143, 155, 176, 0.28);
}

.trade-open-pill[data-state="active"] {
  color: #dff5ff;
  border-color: rgba(34, 211, 238, 0.32);
}

.best-setup-pill[data-actionable="false"] {
  cursor: default;
}

.best-setup-pill[data-actionable="true"]:hover,
.best-setup-pill[data-actionable="true"]:focus-visible {
  border-color: rgba(34, 211, 238, 0.36);
  color: #eef7ff;
  outline: none;
}

.best-setup-pill[data-tone="up"] {
  border-color: rgba(244, 180, 0, 0.34);
  color: #f9df9b;
}

.best-setup-pill[data-tone="down"] {
  border-color: rgba(244, 180, 0, 0.34);
  color: #f9df9b;
}

.best-setup-pill[data-tone="neutral"] {
  border-color: rgba(244, 180, 0, 0.28);
  color: #f9df9b;
}

#best-setup[data-tone="up"] {
  border-color: rgba(244, 180, 0, 0.38);
  color: #f9df9b;
}

#best-setup[data-tone="down"] {
  border-color: rgba(244, 180, 0, 0.38);
  color: #f9df9b;
}

#best-setup[data-tone="neutral"] {
  border-color: rgba(244, 180, 0, 0.28);
  color: #f9df9b;
}

#news-tone[data-tone="bullish"] {
  border-color: rgba(25, 195, 125, 0.42);
  color: #a7f3d0;
}

#news-tone[data-tone="bearish"] {
  border-color: rgba(239, 68, 68, 0.42);
  color: #fecaca;
}

#news-tone[data-tone="neutral"] {
  border-color: rgba(244, 180, 0, 0.42);
  color: #fde68a;
}

.dashboard {
  display: grid;
  grid-template-rows: minmax(0, 1fr);
  gap: 1px;
  padding: 1px;
  background: var(--line);
  min-height: 0;
  overflow: hidden;
}

.dashboard-intel {
  display: grid;
  gap: 10px;
  padding: 10px 12px 12px;
  background:
    radial-gradient(circle at top left, rgba(34, 211, 238, 0.08), transparent 42%),
    linear-gradient(180deg, rgba(5, 10, 20, 0.96), rgba(5, 10, 20, 0.86));
}

.dashboard-strip {
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
  gap: 12px;
  min-height: 58px;
  max-height: 60px;
  padding: 8px 12px;
}

.dashboard-intel-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
  min-width: 0;
}

.dashboard-intel-copy {
  min-width: 0;
}

.dashboard-intel-kicker {
  font-size: 10px;
  line-height: 1;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(143, 232, 255, 0.76);
}

.dashboard-intel-title {
  margin-top: 4px;
  font-size: 16px;
  line-height: 1;
  font-weight: 700;
  color: #f3f8ff;
}

.dashboard-intel-status {
  flex: 0 0 auto;
  padding: 3px 8px;
  border-radius: 999px;
  border: 1px solid rgba(143, 155, 176, 0.22);
  background: rgba(8, 15, 29, 0.7);
  color: rgba(217, 226, 241, 0.74);
  font-size: 10px;
  line-height: 1.1;
  font-weight: 700;
  letter-spacing: 0.03em;
  white-space: nowrap;
}

.dashboard-intel-actions {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex: 0 0 auto;
}

.dashboard-intel-toggle {
  appearance: none;
  border: 1px solid rgba(143, 155, 176, 0.24);
  border-radius: 999px;
  background: rgba(8, 15, 29, 0.72);
  color: rgba(217, 226, 241, 0.8);
  padding: 4px 9px;
  font-size: 10px;
  line-height: 1;
  font-weight: 700;
  cursor: pointer;
  transition: border-color 140ms ease, color 140ms ease, background-color 140ms ease;
}

.dashboard-intel-toggle:hover,
.dashboard-intel-toggle:focus-visible {
  border-color: rgba(34, 211, 238, 0.34);
  color: #f3f8ff;
  outline: none;
}

.trade-ideas-list {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(196px, 1fr);
  gap: 10px;
  overflow-x: auto;
  padding-bottom: 2px;
  scrollbar-width: thin;
}

.trade-signals-list {
  display: flex;
  align-items: center;
  gap: 8px;
  overflow-x: auto;
  min-width: 0;
  padding-bottom: 0;
  scrollbar-width: thin;
}

.trade-signal-card {
  display: grid;
  gap: 3px;
  flex: 0 0 auto;
  min-width: 220px;
  max-width: 280px;
  padding: 8px 10px;
  border-radius: 12px;
  border: 1px solid rgba(143, 155, 176, 0.2);
  background:
    radial-gradient(circle at top left, rgba(255, 255, 255, 0.03), transparent 38%),
    linear-gradient(180deg, rgba(9, 17, 30, 0.98), rgba(7, 14, 26, 0.92));
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.02),
    0 6px 18px rgba(3, 8, 18, 0.16);
}

.trade-signal-card[data-action="ENTRY_LONG"] {
  border-color: rgba(25, 195, 125, 0.34);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.02),
    0 0 0 1px rgba(25, 195, 125, 0.08),
    0 12px 28px rgba(25, 195, 125, 0.08);
}

.trade-signal-card[data-action="ENTRY_SHORT"] {
  border-color: rgba(239, 68, 68, 0.34);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.02),
    0 0 0 1px rgba(239, 68, 68, 0.08),
    0 12px 28px rgba(239, 68, 68, 0.08);
}

.trade-signal-card[data-action^="CLOSE_"] {
  border-color: rgba(148, 163, 184, 0.22);
}

.trade-signal-top,
.trade-signal-chips {
  display: flex;
  align-items: center;
}

.trade-signal-top {
  justify-content: space-between;
  gap: 8px;
}

.trade-signal-title {
  min-width: 0;
  color: #f3f8ff;
  font-size: 12px;
  line-height: 1.1;
  font-weight: 800;
  letter-spacing: 0.01em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.trade-signal-chips {
  gap: 6px;
  flex: 0 0 auto;
}

.trade-signal-chip {
  padding: 2px 6px;
  border-radius: 999px;
  border: 1px solid rgba(143, 155, 176, 0.2);
  background: rgba(5, 10, 20, 0.78);
  color: rgba(217, 226, 241, 0.82);
  font-size: 8px;
  line-height: 1;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.trade-signal-meta,
.trade-signal-footer {
  color: rgba(217, 226, 241, 0.72);
  font-size: 10px;
  line-height: 1.2;
}

.trade-signal-footer {
  display: flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.trade-signal-pnl.is-up {
  color: #a7f3d0;
}

.trade-signal-pnl.is-down {
  color: #fecaca;
}

.trade-signal-pnl.is-flat {
  color: #e2e8f0;
}

#trade-signals-panel .dashboard-intel-copy {
  min-width: 124px;
}

#trade-signals-panel .dashboard-intel-title {
  margin-top: 2px;
  font-size: 13px;
}

#trade-signals-panel .dashboard-intel-kicker {
  font-size: 9px;
}

#trade-ideas-panel {
  align-content: start;
  max-height: 190px;
  overflow: hidden;
}

#trade-ideas-panel[data-collapsed="true"] {
  gap: 0;
  padding-bottom: 10px;
}

#trade-ideas-panel[data-collapsed="true"] .trade-ideas-list {
  display: none;
}

.trade-idea-card {
  display: grid;
  gap: 8px;
  min-width: 0;
  padding: 10px 11px;
  border-radius: 14px;
  border: 1px solid rgba(143, 155, 176, 0.16);
  background:
    linear-gradient(180deg, rgba(9, 17, 30, 0.96), rgba(7, 14, 26, 0.88));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.02);
}

.trade-idea-card[data-type="LONG"] {
  border-color: rgba(25, 195, 125, 0.28);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.02),
    0 0 0 1px rgba(25, 195, 125, 0.06);
}

.trade-idea-card[data-type="SHORT"] {
  border-color: rgba(239, 68, 68, 0.28);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.02),
    0 0 0 1px rgba(239, 68, 68, 0.06);
}

.trade-idea-card[data-type="HEDGE"],
.trade-idea-card[data-type="AVOID"] {
  border-color: rgba(244, 180, 0, 0.26);
}

.trade-idea-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
}

.trade-idea-ticker {
  font-size: 14px;
  line-height: 1;
  font-weight: 700;
  color: #f5f8fb;
  letter-spacing: 0.01em;
}

.trade-idea-chips {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 5px;
}

.trade-idea-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 3px 8px;
  border-radius: 999px;
  border: 1px solid rgba(143, 155, 176, 0.18);
  background: rgba(12, 20, 34, 0.72);
  font-size: 9px;
  line-height: 1;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  white-space: nowrap;
}

.trade-idea-chip-type-long {
  color: #bbf7d0;
  border-color: rgba(34, 197, 94, 0.3);
  background: rgba(15, 118, 73, 0.2);
}

.trade-idea-chip-type-short {
  color: #fecaca;
  border-color: rgba(239, 68, 68, 0.3);
  background: rgba(185, 28, 28, 0.18);
}

.trade-idea-chip-type-watch,
.trade-idea-chip-type-hedge,
.trade-idea-chip-type-avoid {
  color: #fde68a;
  border-color: rgba(244, 180, 0, 0.26);
  background: rgba(120, 82, 6, 0.18);
}

.trade-idea-chip-confidence-high {
  color: #dff5ff;
  border-color: rgba(34, 211, 238, 0.26);
}

.trade-idea-chip-confidence-medium {
  color: #fde68a;
}

.trade-idea-chip-confidence-low {
  color: rgba(217, 226, 241, 0.82);
}

.trade-idea-rationale {
  margin: 0;
  color: rgba(217, 226, 241, 0.82);
  font-size: 11px;
  line-height: 1.42;
  display: -webkit-box;
  overflow: hidden;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
}

.grid {
  --grid-cols: 3;
  --grid-rows: 3;
  height: 100%;
  min-height: 0;
  display: grid;
  grid-template-columns: repeat(var(--grid-cols), minmax(0, 1fr));
  grid-template-rows: repeat(var(--grid-rows), minmax(0, 1fr));
  gap: 1px;
}

.card {
  --card-head-height: 0px;
  position: relative;
  min-height: 0;
  background: var(--panel);
  overflow: hidden;
}

.card::after {
  content: "";
  position: absolute;
  inset: 0;
  border: 1px solid transparent;
  border-radius: inherit;
  pointer-events: none;
  z-index: 14;
  transition: border-color 180ms ease, box-shadow 180ms ease;
}

.card-live {
  --card-head-height: 0px;
}

.card-live[data-signal-tone="up"][data-signal-emphasis="watch"]::after {
  border-color: rgba(22, 163, 74, 0.16);
  box-shadow: inset 0 0 0 1px rgba(22, 163, 74, 0.03);
}

.card-live[data-signal-tone="down"][data-signal-emphasis="watch"]::after {
  border-color: rgba(220, 38, 38, 0.16);
  box-shadow: inset 0 0 0 1px rgba(220, 38, 38, 0.03);
}

.card-live[data-signal-tone="up"][data-signal-emphasis="active"]::after {
  border-color: rgba(74, 222, 128, 0.52);
  box-shadow:
    inset 0 0 0 1px rgba(34, 197, 94, 0.08),
    0 0 0 1px rgba(34, 197, 94, 0.08);
}

.card-live[data-signal-tone="down"][data-signal-emphasis="active"]::after {
  border-color: rgba(248, 113, 113, 0.52);
  box-shadow:
    inset 0 0 0 1px rgba(248, 113, 113, 0.08),
    0 0 0 1px rgba(248, 113, 113, 0.08);
}

.card-live[data-signal-tone="up"][data-signal-emphasis="active"][data-signal-fresh="true"]::after {
  border-color: rgba(74, 222, 128, 0.62);
  box-shadow:
    inset 0 0 0 1px rgba(74, 222, 128, 0.12),
    0 0 0 1px rgba(34, 197, 94, 0.12);
}

.card-live[data-signal-tone="down"][data-signal-emphasis="active"][data-signal-fresh="true"]::after {
  border-color: rgba(252, 165, 165, 0.62);
  box-shadow:
    inset 0 0 0 1px rgba(252, 165, 165, 0.12),
    0 0 0 1px rgba(248, 113, 113, 0.12);
}

.card-live[data-conviction-strong="true"]::after {
  animation: card-conviction-pulse 2.6s ease-in-out infinite;
}

.card-live[data-conviction-strong="true"][data-conviction-tone="up"]::after {
  border-color: rgba(74, 222, 128, 0.78);
  box-shadow:
    inset 0 0 0 1px rgba(74, 222, 128, 0.22),
    0 0 0 1px rgba(34, 197, 94, 0.24),
    0 0 24px rgba(34, 197, 94, 0.24);
}

.card-live[data-conviction-strong="true"][data-conviction-tone="down"]::after {
  border-color: rgba(252, 165, 165, 0.78);
  box-shadow:
    inset 0 0 0 1px rgba(252, 165, 165, 0.22),
    0 0 0 1px rgba(248, 113, 113, 0.24),
    0 0 24px rgba(248, 113, 113, 0.24);
}

.card-live[data-signal-exit="true"]::after {
  border-color: rgba(251, 191, 36, 0.78);
  box-shadow:
    inset 0 0 0 1px rgba(251, 191, 36, 0.24),
    0 0 0 1px rgba(245, 158, 11, 0.22),
    0 0 24px rgba(245, 158, 11, 0.22);
  animation: card-conviction-pulse 1.9s ease-in-out infinite;
}

.card-live[data-trade-entry="true"][data-trade-tone="up"]::after {
  border-color: rgba(74, 222, 128, 0.92);
  box-shadow:
    inset 0 0 0 1px rgba(74, 222, 128, 0.24),
    0 0 0 1px rgba(34, 197, 94, 0.24),
    0 0 28px rgba(34, 197, 94, 0.3);
}

.card-live[data-trade-entry="true"][data-trade-tone="down"]::after {
  border-color: rgba(252, 165, 165, 0.92);
  box-shadow:
    inset 0 0 0 1px rgba(252, 165, 165, 0.24),
    0 0 0 1px rgba(239, 68, 68, 0.24),
    0 0 28px rgba(239, 68, 68, 0.3);
}

.card-live[data-trade-entry="true"][data-trade-fresh="true"]::after {
  animation: card-conviction-pulse 1.5s ease-in-out infinite;
}

.card-empty {
  cursor: pointer;
}

@keyframes card-conviction-pulse {
  0%, 100% {
    opacity: 1;
  }
  50% {
    opacity: 0.88;
  }
}

.card-empty:hover,
.card-empty:focus-within {
  border-color: rgba(34, 211, 238, 0.28);
  box-shadow: inset 0 0 0 1px rgba(34, 211, 238, 0.08);
}

.card-head {
  position: absolute;
  top: 6px;
  left: 6px;
  right: 6px;
  z-index: 12;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: var(--card-head-height);
  padding: 6px 9px;
  border-radius: 12px;
  border: 1px solid rgba(26, 51, 86, 0.58);
  background: linear-gradient(180deg, rgba(5, 10, 20, 0.92), rgba(5, 10, 20, 0.76));
  box-shadow: 0 8px 24px rgba(3, 8, 18, 0.24);
  backdrop-filter: blur(10px);
  pointer-events: auto;
}

.card-head-live {
  align-items: stretch;
}

.card-head-status {
  --card-head-height: 48px;
}

.symbol-block {
  flex: 1 1 auto;
  min-width: 0;
  max-width: none;
  padding: 0;
  pointer-events: auto;
}

.symbol-row {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  flex-wrap: wrap;
}

.symbol-trigger {
  display: inline-flex;
  align-items: center;
  min-width: 0;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  cursor: pointer;
}

.symbol-trigger:hover .symbol,
.symbol-trigger:focus-visible .symbol {
  color: #8fe8ff;
}

.symbol-trigger:focus-visible {
  outline: 0;
}

.symbol {
  font-size: 15px;
  font-weight: 700;
  white-space: nowrap;
  text-shadow: 0 1px 0 rgba(3, 8, 18, 0.85);
}

.symbol-empty {
  color: #8fe8ff;
  font-size: 28px;
  line-height: 1;
}

.symbol-sub {
  margin-top: 3px;
  color: var(--muted);
  font-size: 10px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-shadow: 0 1px 0 rgba(3, 8, 18, 0.85);
}

.chart-label-stack {
  position: absolute;
  top: 6px;
  left: 6px;
  z-index: 7;
  display: grid;
  gap: 0;
  padding: 5px 7px 6px;
  border-radius: 9px;
  border: 1px solid rgba(255, 255, 255, 0.04);
  background: rgba(2, 6, 12, 0.74);
  box-shadow: 0 10px 24px rgba(2, 6, 12, 0.18);
  backdrop-filter: blur(2px);
  min-width: 0;
  max-width: calc(100% - 12px);
  justify-items: start;
  text-align: left;
}

.chart-title-row {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 6px;
  min-width: 0;
  width: 100%;
  flex-wrap: nowrap;
}

.chart-meta-row {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 6px;
  min-width: 0;
  width: 100%;
}

.chart-symbol {
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  padding: 0;
  border: 0;
  background: transparent;
  color: #f3f8ff;
  font-size: 13px;
  font-weight: 600;
  line-height: 1;
  letter-spacing: 0.01em;
  cursor: pointer;
  text-shadow: 0 1px 0 rgba(3, 8, 18, 0.92), 0 0 18px rgba(3, 8, 18, 0.42);
}

.chart-symbol:hover,
.chart-symbol:focus-visible {
  color: var(--yellow);
  outline: 0;
}

.chart-symbol-static {
  display: inline-flex;
  align-items: center;
  justify-content: flex-start;
  color: #f3f8ff;
  font-size: 13px;
  font-weight: 600;
  line-height: 1;
  letter-spacing: 0.01em;
  text-shadow: 0 1px 0 rgba(3, 8, 18, 0.92), 0 0 18px rgba(3, 8, 18, 0.42);
}

.chart-symbol-empty {
  color: #8fe8ff;
  font-size: 22px;
  line-height: 1;
}

.chart-meta-inline,
.chart-meta-change {
  font-size: 10px;
  line-height: 1.1;
  text-shadow: 0 1px 0 rgba(3, 8, 18, 0.88);
}

.chart-meta-inline {
  color: rgba(200, 209, 223, 0.82);
  flex: 1 1 auto;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.chart-pg-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  min-width: 0;
  padding: 2px 6px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  font-size: 9px;
  line-height: 1;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  font-variant-numeric: tabular-nums;
  box-shadow: 0 1px 0 rgba(3, 8, 18, 0.8);
}

.chart-pg-chip-up {
  color: #d7ffec;
  background: rgba(25, 195, 125, 0.22);
  border-color: rgba(25, 195, 125, 0.34);
}

.chart-pg-chip-down {
  color: #ffe0e0;
  background: rgba(239, 68, 68, 0.2);
  border-color: rgba(239, 68, 68, 0.34);
}

.chart-pg-chip-neutral {
  color: rgba(220, 226, 237, 0.9);
  background: rgba(96, 109, 128, 0.18);
  border-color: rgba(148, 163, 184, 0.2);
}

.chart-pg-why {
  width: 100%;
  margin-top: 2px;
  font-size: 10px;
  line-height: 1.22;
  white-space: normal;
  overflow: hidden;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  text-shadow: 0 1px 0 rgba(3, 8, 18, 0.88);
}

.chart-pg-why-up {
  color: rgba(205, 255, 230, 0.9);
}

.chart-pg-why-down {
  color: rgba(255, 220, 220, 0.9);
}

.chart-pg-why-neutral {
  color: rgba(200, 209, 223, 0.72);
}

.chart-meta-change {
  font-weight: 700;
  font-size: 11px;
  line-height: 1;
  letter-spacing: 0;
  font-variant-numeric: tabular-nums;
}

.chart-meta-change.price-change-up {
  color: #19c37d;
}

.chart-meta-change.price-change-down {
  color: #ef4444;
}

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

.trade-plan {
  display: grid;
  align-content: center;
  gap: 2px;
  flex: 0 1 41%;
  min-width: 132px;
  max-width: min(41%, 248px);
  margin-top: 0;
  margin-left: auto;
  padding: 0;
  border: 0;
  background: none;
  box-shadow: none;
}

.trade-plan-main {
  display: flex;
  align-items: center;
  gap: 5px;
  min-width: 0;
  justify-content: flex-end;
}

.trade-plan-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 2px 7px;
  border-radius: 999px;
  font-size: 9px;
  line-height: 1.2;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  white-space: nowrap;
}

.trade-plan-badge-up {
  color: #dcfce7;
  background: rgba(22, 163, 74, 0.24);
  border: 1px solid rgba(22, 163, 74, 0.44);
}

.trade-plan-badge-down {
  color: #fee2e2;
  background: rgba(220, 38, 38, 0.24);
  border: 1px solid rgba(220, 38, 38, 0.44);
}

.trade-plan-badge-neutral {
  color: #dbe7ff;
  background: rgba(51, 65, 85, 0.42);
  border: 1px solid rgba(100, 116, 139, 0.34);
}

.trade-plan-summary {
  min-width: 0;
  color: #edf4ff;
  font-size: 9px;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-align: right;
}

.trade-plan-meta {
  display: flex;
  align-items: center;
  gap: 4px;
  min-width: 0;
  justify-content: flex-end;
  flex-wrap: nowrap;
  overflow: hidden;
}

.trade-meta-chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  min-width: 0;
  padding: 1px 6px;
  border-radius: 999px;
  border: 1px solid transparent;
  font-size: 9px;
  line-height: 1.2;
  font-weight: 700;
  white-space: nowrap;
}

.trade-meta-chip-label {
  color: rgba(226, 232, 240, 0.82);
  font-size: 8px;
  letter-spacing: 0.04em;
}

.trade-meta-chip-up {
  color: #d1fae5;
  background: rgba(21, 128, 61, 0.18);
  border-color: rgba(34, 197, 94, 0.34);
}

.trade-meta-chip-down {
  color: #fee2e2;
  background: rgba(185, 28, 28, 0.18);
  border-color: rgba(248, 113, 113, 0.34);
}

.trade-meta-chip-neutral {
  color: #e2e8f0;
  background: rgba(51, 65, 85, 0.24);
  border-color: rgba(100, 116, 139, 0.3);
}

.trade-meta-chip-strong {
  color: #d1fae5;
  background: rgba(15, 118, 73, 0.22);
  border-color: rgba(34, 197, 94, 0.38);
}

.trade-meta-chip-good {
  color: #dbeafe;
  background: rgba(29, 78, 216, 0.2);
  border-color: rgba(96, 165, 250, 0.34);
}

.trade-meta-chip-weak {
  color: #fef3c7;
  background: rgba(180, 83, 9, 0.22);
  border-color: rgba(245, 158, 11, 0.34);
}

.price-head {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: flex-end;
  text-align: right;
}

.price-head-sub {
  margin-top: 2px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 700;
}

.price-head > .price-head-sub:first-child {
  margin-top: 0;
}

.price-head-sub.price-change-up {
  color: #a7f3d0;
}

.price-head-sub.price-change-down {
  color: #fecaca;
}

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

.chart-wrap {
  position: absolute;
  inset: 8px var(--price-scale-reserve) 30px 6px;
  background:
    linear-gradient(var(--grid) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid) 1px, transparent 1px),
    #0a1322;
  background-size: 100% 20%, 16.666% 100%;
  overflow: hidden;
}

.price-layer,
.liquidity-zone-layer,
.trade-guide-layer,
.price-guide-layer,
.volume-layer {
  position: absolute;
}

.price-layer,
.liquidity-zone-layer,
.trade-guide-layer,
.price-guide-layer {
  inset: 0;
}

.price-layer svg,
.liquidity-zone-layer svg,
.trade-guide-layer svg,
.price-guide-layer svg,
.volume-layer svg {
  width: 100%;
  height: 100%;
  display: block;
}

.price-layer {
  z-index: 3;
}

.liquidity-zone-layer {
  z-index: 1;
  pointer-events: none;
}

.trade-guide-layer {
  z-index: 4;
  pointer-events: none;
}

.trade-guide-line {
  position: absolute;
  left: 0;
  right: 0;
  border-top: 1px dashed rgba(148, 163, 184, 0.26);
}

.trade-guide-axis {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 0;
  border-left: 1px solid rgba(148, 163, 184, 0.22);
  box-shadow: 0 0 0 1px rgba(8, 15, 29, 0.14);
}

.trade-guide-axis-up {
  border-left-color: rgba(34, 197, 94, 0.56);
  box-shadow: 0 0 10px rgba(34, 197, 94, 0.16);
}

.trade-guide-axis-down {
  border-left-color: rgba(248, 113, 113, 0.56);
  box-shadow: 0 0 10px rgba(248, 113, 113, 0.16);
}

.trade-guide-line-entry {
  border-top-style: solid;
}

.trade-guide-line-crosshair {
  border-top-width: 1px;
}

.trade-guide-line-stop {
  border-top-style: dashed;
  border-top-color: rgba(245, 158, 11, 0.42);
}

.trade-guide-line-invalid {
  border-top-style: dashed;
  border-top-color: rgba(148, 163, 184, 0.34);
}

.trade-guide-line-risk {
  border-top-style: dashed;
  border-top-color: rgba(245, 158, 11, 0.34);
}

.trade-guide-line-trail {
  border-top-style: dashed;
  border-top-color: rgba(148, 163, 184, 0.38);
}

.trade-guide-line-lock {
  border-top-style: solid;
  border-top-color: rgba(34, 197, 94, 0.38);
}

.trade-guide-line-up {
  border-top-color: rgba(34, 197, 94, 0.52);
}

.trade-guide-line-down {
  border-top-color: rgba(248, 113, 113, 0.52);
}

.trade-guide-line-up.trade-guide-line-crosshair {
  border-top-color: rgba(34, 197, 94, 0.72);
  box-shadow: 0 0 10px rgba(34, 197, 94, 0.1);
}

.trade-guide-line-down.trade-guide-line-crosshair {
  border-top-color: rgba(248, 113, 113, 0.72);
  box-shadow: 0 0 10px rgba(248, 113, 113, 0.1);
}

.trade-guide-line-neutral {
  border-top-color: rgba(148, 163, 184, 0.34);
}

.trade-guide-label {
  position: absolute;
  right: 6px;
  top: 0;
  transform: translateY(-50%);
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 1px 5px;
  border-radius: 999px;
  border: 1px solid transparent;
  background: rgba(7, 14, 26, 0.88);
  font-size: 8px;
  line-height: 1.2;
  font-weight: 700;
  letter-spacing: 0.02em;
  box-shadow: 0 1px 0 rgba(3, 8, 18, 0.46);
}

.trade-guide-label-crosshair {
  background: rgba(7, 14, 26, 0.94);
  box-shadow: 0 0 0 1px rgba(8, 15, 29, 0.34), 0 1px 0 rgba(3, 8, 18, 0.52);
}

.trade-guide-label-trigger.trade-guide-label-up,
.trade-guide-label-entry.trade-guide-label-up {
  color: #dcfce7;
  border-color: rgba(34, 197, 94, 0.3);
}

.trade-guide-label-trigger.trade-guide-label-down,
.trade-guide-label-entry.trade-guide-label-down {
  color: #fee2e2;
  border-color: rgba(248, 113, 113, 0.3);
}

.trade-guide-label-stop {
  color: #fef3c7;
  border-color: rgba(245, 158, 11, 0.28);
}

.trade-guide-label-invalid {
  color: #e2e8f0;
  border-color: rgba(148, 163, 184, 0.24);
}

.trade-guide-label-risk {
  color: #fef3c7;
  border-color: rgba(245, 158, 11, 0.24);
}

.trade-guide-label-trail {
  color: #e2e8f0;
  border-color: rgba(148, 163, 184, 0.24);
}

.trade-guide-label-lock {
  color: #dcfce7;
  border-color: rgba(34, 197, 94, 0.28);
}

.price-guide-layer {
  z-index: 5;
  pointer-events: none;
}

.volume-layer {
  inset: auto 0 0 0;
  height: 22%;
  opacity: 0.48;
  z-index: 2;
}

.price-scale {
  position: absolute;
  top: 8px;
  right: 4px;
  bottom: 30px;
  width: var(--price-scale-width);
  z-index: 11;
  pointer-events: none;
  overflow: hidden;
  border-left: 1px solid rgba(31, 42, 61, 0.85);
  background: linear-gradient(180deg, rgba(7, 14, 26, 0.92), rgba(7, 14, 26, 0.72));
}

.liquidity-shelves {
  position: absolute;
  inset: 0 var(--price-scale-shelf-gap) 0 0;
  pointer-events: none;
  opacity: 1;
}

.liquidity-shelf {
  position: absolute;
  left: 3px;
  height: var(--shelf-height, 5px);
  width: min(var(--shelf-width, 20px), calc(100% - 6px));
  transform: translateY(-50%);
  border-radius: 0 999px 999px 0;
  opacity: var(--shelf-opacity, 0.36);
  box-shadow:
    0 0 0 1px rgba(6, 12, 22, 0.2),
    0 0 14px rgba(0, 0, 0, 0.12);
  filter: saturate(1.08) brightness(1.06);
}

.liquidity-shelf-above {
  background: linear-gradient(90deg, rgba(127, 29, 29, 0.14), rgba(248, 113, 113, 0.52), rgba(239, 68, 68, 0.96));
  box-shadow:
    0 0 0 1px rgba(127, 29, 29, 0.26),
    0 0 16px rgba(239, 68, 68, 0.28);
}

.liquidity-shelf-below {
  background: linear-gradient(90deg, rgba(6, 95, 70, 0.14), rgba(52, 211, 153, 0.52), rgba(16, 185, 129, 0.96));
  box-shadow:
    0 0 0 1px rgba(6, 95, 70, 0.26),
    0 0 16px rgba(16, 185, 129, 0.28);
}

.liquidity-shelf-neutral {
  background: linear-gradient(90deg, rgba(71, 85, 105, 0.08), rgba(148, 163, 184, 0.6));
}

.liquidity-shelf-stale {
  filter: saturate(0.82) brightness(0.92);
}

.liquidity-zone-band {
  position: absolute;
  left: 0;
  right: 0;
  border-top: 1px solid transparent;
  border-bottom: 1px solid transparent;
  opacity: var(--band-opacity, 0.16);
  box-shadow: inset 0 0 0 1px rgba(6, 12, 22, 0.08);
}

.liquidity-zone-band-above {
  background: linear-gradient(180deg, rgba(127, 29, 29, 0.09), rgba(248, 113, 113, 0.14), rgba(239, 68, 68, 0.24));
  border-top-color: rgba(248, 113, 113, 0.42);
  border-bottom-color: rgba(239, 68, 68, 0.34);
}

.liquidity-zone-band-below {
  background: linear-gradient(180deg, rgba(6, 95, 70, 0.09), rgba(52, 211, 153, 0.14), rgba(16, 185, 129, 0.24));
  border-top-color: rgba(52, 211, 153, 0.42);
  border-bottom-color: rgba(16, 185, 129, 0.34);
}

.liquidity-zone-band-neutral {
  background: linear-gradient(180deg, rgba(51, 65, 85, 0.06), rgba(100, 116, 139, 0.16));
  border-top-color: rgba(148, 163, 184, 0.22);
  border-bottom-color: rgba(100, 116, 139, 0.18);
}

.price-tick,
.time-tick {
  font-size: 8px;
  line-height: 1;
  color: rgba(143, 155, 176, 0.92);
}

.price-tick {
  position: absolute;
  right: 4px;
  transform: translateY(-50%);
  background: rgba(11, 18, 32, 0.56);
  border-radius: 3px;
  padding: 1px 3px;
  font-size: 9px;
}

.price-tick-extreme {
  color: rgba(188, 199, 219, 0.98);
  background: rgba(11, 18, 32, 0.8);
}

.price-tick-top {
  top: 0;
  transform: none;
}

.price-tick-bottom {
  top: auto;
  bottom: 0;
  transform: none;
}

.price-marker {
  position: absolute;
  left: 0;
  right: 0;
  transform: translateY(-50%);
  display: flex;
  justify-content: flex-end;
  width: 100%;
}

.price-marker-label {
  min-width: 0;
  width: auto;
  max-width: 100%;
  box-sizing: border-box;
  padding: 2px 6px 3px;
  border-radius: 4px;
  display: inline-flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 2px;
  font-size: 13px;
  line-height: 1;
  font-weight: 600;
  letter-spacing: 0.01em;
  text-align: right;
  box-shadow: 0 0 0 1px rgba(8, 15, 29, 0.72);
}

.price-marker-price {
  display: block;
  width: 100%;
  letter-spacing: 0;
  font-variant-numeric: tabular-nums;
}

.price-marker-price-compact {
  font-size: 11px;
  letter-spacing: -0.01em;
}

.price-marker-up .price-marker-label {
  color: #d1fae5;
  background: rgba(15, 118, 73, 0.94);
}

.price-marker-down .price-marker-label {
  color: #fee2e2;
  background: rgba(185, 28, 28, 0.94);
}

.time-scale {
  position: absolute;
  left: 6px;
  right: var(--price-scale-reserve);
  bottom: 28px;
  height: 14px;
  z-index: 4;
  pointer-events: none;
}

.time-tick {
  position: absolute;
  bottom: 0;
  transform: translateX(-50%);
  white-space: nowrap;
}

.time-tick-left {
  transform: translateX(0);
}

.time-tick-right {
  transform: translateX(-100%);
}

.time-tick-date {
  color: rgba(209, 213, 219, 0.96);
  font-weight: 700;
}

.signal-badge {
  display: inline-block;
  flex: 0 0 auto;
  padding: 2px 7px;
  border-radius: 999px;
  font-size: 9px;
  line-height: 1.2;
  font-weight: 700;
  border: 1px solid transparent;
  letter-spacing: 0.02em;
  white-space: nowrap;
}

.card-signal-corner {
  position: absolute;
  right: 10px;
  bottom: 16px;
  z-index: 6;
  transform: none;
  box-shadow: none;
  pointer-events: auto;
  max-width: calc(100% - 24px);
  overflow: hidden;
  text-overflow: ellipsis;
  opacity: 0.85;
}

.card-signal-corner.signal-badge {
  padding: 1px 6px;
  font-size: 8px;
  letter-spacing: 0.04em;
  border-color: rgba(148, 163, 184, 0.34);
}

.card-signal-corner.signal-up {
  background: rgba(22, 163, 74, 0.18);
}

.card-signal-corner.signal-down {
  background: rgba(220, 38, 38, 0.18);
}

.card-signal-corner.signal-neutral {
  background: rgba(71, 85, 105, 0.26);
}

.card-signal-corner[data-tooltip]::after {
  max-width: min(260px, calc(100vw - 32px));
  font-size: 10px;
  line-height: 1.35;
}

.card-signal-meta {
  position: absolute;
  left: 10px;
  bottom: 24px;
  z-index: 6;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  max-width: calc(100% - 92px);
  pointer-events: auto;
}

.signal-conviction-badge,
.signal-trade-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 7px;
  border-radius: 999px;
  border: 1px solid rgba(143, 155, 176, 0.24);
  background: rgba(5, 10, 20, 0.82);
  color: #edf4ff;
  font-size: 9px;
  line-height: 1;
  font-weight: 700;
  letter-spacing: 0.04em;
  white-space: nowrap;
}

.signal-conviction-badge[data-strong="true"] {
  border-color: rgba(34, 197, 94, 0.32);
  box-shadow: 0 0 0 1px rgba(34, 197, 94, 0.08);
}

.signal-conviction-score {
  font-variant-numeric: tabular-nums;
}

.signal-conviction-dots {
  display: inline-flex;
  align-items: center;
  gap: 3px;
}

.signal-conviction-dot {
  width: 5px;
  height: 5px;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.28);
}

.signal-conviction-dot.is-active {
  background: #22c55e;
  box-shadow: 0 0 8px rgba(34, 197, 94, 0.34);
}

.signal-trade-badge {
  cursor: help;
  border-color: rgba(34, 211, 238, 0.26);
  box-shadow: 0 0 0 1px rgba(34, 211, 238, 0.06);
}

.signal-trade-badge[data-tone="bullish"] {
  color: #bbf7d0;
  border-color: rgba(34, 197, 94, 0.28);
}

.signal-trade-badge[data-tone="bearish"] {
  color: #fecaca;
  border-color: rgba(239, 68, 68, 0.28);
}

.signal-conviction-badge[data-tooltip],
.signal-trade-badge[data-tooltip] {
  cursor: help;
}

.signal-conviction-badge[data-tooltip]::after,
.signal-trade-badge[data-tooltip]::after {
  content: attr(data-tooltip);
  position: absolute;
  left: 50%;
  bottom: calc(100% + 8px);
  transform: translateX(-50%) translateY(4px);
  min-width: 180px;
  max-width: min(280px, calc(100vw - 24px));
  padding: 7px 9px;
  border-radius: 8px;
  border: 1px solid rgba(51, 65, 85, 0.85);
  background: rgba(5, 10, 20, 0.96);
  box-shadow: 0 10px 28px rgba(3, 8, 18, 0.36);
  color: #dbe7ff;
  font-size: 11px;
  line-height: 1.38;
  white-space: normal;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 120ms linear, transform 120ms ease, visibility 120ms linear;
  z-index: 8;
}

.signal-conviction-badge[data-tooltip]::before,
.signal-trade-badge[data-tooltip]::before {
  content: "";
  position: absolute;
  left: 50%;
  bottom: calc(100% + 2px);
  transform: translateX(-50%) translateY(4px);
  border-width: 6px 5px 0 5px;
  border-style: solid;
  border-color: rgba(5, 10, 20, 0.96) transparent transparent transparent;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 120ms linear, transform 120ms ease, visibility 120ms linear;
  z-index: 8;
}

.signal-conviction-badge:hover::after,
.signal-conviction-badge:hover::before,
.signal-conviction-badge:focus-visible::after,
.signal-conviction-badge:focus-visible::before {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}

.signal-trade-badge:hover::after,
.signal-trade-badge:hover::before,
.signal-trade-badge:focus-visible::after,
.signal-trade-badge:focus-visible::before {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}

.signal-up {
  background: rgba(22, 163, 74, 0.24);
  border-color: rgba(22, 163, 74, 0.5);
  color: #bbf7d0;
}

.signal-neutral {
  background: rgba(202, 138, 4, 0.26);
  border-color: rgba(202, 138, 4, 0.5);
  color: #fef3c7;
}

.signal-down {
  background: rgba(220, 38, 38, 0.26);
  border-color: rgba(220, 38, 38, 0.5);
  color: #fecaca;
}

.metric-pill {
  display: inline-flex;
  align-items: center;
  padding: 2px 6px;
  border-radius: 999px;
  font-size: 10px;
  line-height: 1;
  font-weight: 700;
  border: 1px solid transparent;
  white-space: nowrap;
}

.metric-pill.price-change-up {
  color: #a7f3d0;
  background: rgba(15, 118, 73, 0.22);
  border-color: rgba(22, 163, 74, 0.38);
}

.metric-pill.price-change-down {
  color: #fecaca;
  background: rgba(185, 28, 28, 0.2);
  border-color: rgba(239, 68, 68, 0.34);
}

.metric-pill.price-change-neutral {
  color: var(--muted);
  background: rgba(15, 23, 42, 0.72);
  border-color: rgba(82, 94, 118, 0.32);
}

.metric-pill-hint {
  position: relative;
  cursor: help;
  pointer-events: auto;
}

.metric-pill-oi {
  color: var(--oi);
}

.metric-pill-liq {
  font-variant-numeric: tabular-nums;
}

.metric-pill-hint::after {
  content: attr(data-tooltip);
  position: absolute;
  left: 50%;
  top: calc(100% + 8px);
  transform: translateX(-50%) translateY(-4px);
  min-width: 180px;
  max-width: 240px;
  padding: 7px 9px;
  border-radius: 8px;
  border: 1px solid rgba(51, 65, 85, 0.85);
  background: rgba(5, 10, 20, 0.96);
  box-shadow: 0 10px 28px rgba(3, 8, 18, 0.36);
  color: #dbe7ff;
  font-size: 11px;
  line-height: 1.35;
  white-space: normal;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 120ms linear, transform 120ms ease, visibility 120ms linear;
  z-index: 8;
}

.metric-pill-hint::before {
  content: "";
  position: absolute;
  left: 50%;
  top: calc(100% + 2px);
  transform: translateX(-50%) translateY(-4px);
  border-width: 0 5px 6px 5px;
  border-style: solid;
  border-color: transparent transparent rgba(5, 10, 20, 0.96) transparent;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 120ms linear, transform 120ms ease, visibility 120ms linear;
  z-index: 8;
}

.metric-pill-hint:hover::after,
.metric-pill-hint:hover::before,
.metric-pill-hint:focus-visible::after,
.metric-pill-hint:focus-visible::before {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}

.signal-band {
  position: absolute;
  left: 10px;
  right: 10px;
  bottom: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 8px;
  padding: 0 8px;
  border-radius: 999px;
  overflow: visible;
  border: 1px solid rgba(71, 85, 105, 0.32);
  background: linear-gradient(
    90deg,
    rgba(185, 28, 28, 0.3) 0%,
    rgba(202, 138, 4, 0.18) 50%,
    rgba(15, 118, 73, 0.3) 100%
  );
  z-index: 3;
}

.signal-band[data-visual="muted"] {
  border-color: rgba(94, 104, 126, 0.26);
  background: linear-gradient(
    90deg,
    rgba(110, 116, 128, 0.22) 0%,
    rgba(136, 142, 154, 0.16) 50%,
    rgba(110, 116, 128, 0.22) 100%
  );
}

.signal-band[data-visual="soft"] {
  border-color: rgba(92, 104, 126, 0.28);
  background: linear-gradient(
    90deg,
    rgba(120, 27, 27, 0.18) 0%,
    rgba(108, 114, 126, 0.12) 50%,
    rgba(18, 98, 63, 0.18) 100%
  );
}

.signal-band[data-visual="bias"] {
  border-color: rgba(92, 104, 126, 0.22);
  background: linear-gradient(
    90deg,
    rgba(98, 104, 116, 0.14) 0%,
    rgba(98, 104, 116, 0.08) 50%,
    rgba(98, 104, 116, 0.14) 100%
  );
}

.signal-band[data-action="exit-long"],
.signal-band[data-action="exit-short"] {
  border-color: rgba(251, 191, 36, 0.5);
  background: linear-gradient(
    90deg,
    rgba(239, 68, 68, 0.24) 0%,
    rgba(245, 158, 11, 0.2) 50%,
    rgba(239, 68, 68, 0.24) 100%
  );
}

.signal-band[data-strong-conviction="true"][data-action="follow-long"],
.signal-band[data-strong-conviction="true"][data-action="watch-long"],
.signal-band[data-strong-conviction="true"][data-action="long-now"],
.signal-band[data-strong-conviction="true"][data-action="in-long"],
.signal-band[data-strong-conviction="true"][data-action="long-bias"] {
  border-color: rgba(74, 222, 128, 0.46);
  box-shadow: inset 0 0 0 1px rgba(34, 197, 94, 0.08), 0 0 10px rgba(34, 197, 94, 0.12);
}

.signal-band[data-strong-conviction="true"][data-action="follow-short"],
.signal-band[data-strong-conviction="true"][data-action="watch-short"],
.signal-band[data-strong-conviction="true"][data-action="short-now"],
.signal-band[data-strong-conviction="true"][data-action="in-short"],
.signal-band[data-strong-conviction="true"][data-action="short-bias"] {
  border-color: rgba(248, 113, 113, 0.52);
  box-shadow: inset 0 0 0 1px rgba(239, 68, 68, 0.1), 0 0 10px rgba(239, 68, 68, 0.12);
}

.signal-band[data-strong-conviction="true"][data-action="exit-long"],
.signal-band[data-strong-conviction="true"][data-action="exit-short"] {
  border-color: rgba(251, 191, 36, 0.56);
  box-shadow: inset 0 0 0 1px rgba(245, 158, 11, 0.1), 0 0 10px rgba(245, 158, 11, 0.12);
}

.signal-band[data-action="follow-long"],
.signal-band[data-action="long-now"],
.signal-band[data-action="in-long"] {
  border-color: rgba(74, 222, 128, 0.34);
}

.signal-band[data-action="follow-short"],
.signal-band[data-action="short-now"],
.signal-band[data-action="in-short"] {
  border-color: rgba(248, 113, 113, 0.38);
}

.signal-band[data-action="watch-long"],
.signal-band[data-action="watch-short"] {
  border-style: dashed;
}

.signal-band[data-action="follow-long"] .signal-band-copy,
.signal-band[data-action="long-now"] .signal-band-copy,
.signal-band[data-action="in-long"] .signal-band-copy,
.signal-band[data-action="follow-short"] .signal-band-copy,
.signal-band[data-action="short-now"] .signal-band-copy,
.signal-band[data-action="in-short"] .signal-band-copy {
  color: #f4f7fd;
  font-weight: 900;
}

.signal-band[data-tooltip],
.card-signal-corner[data-tooltip] {
  cursor: help;
}

.signal-band[data-tooltip]::after,
.card-signal-corner[data-tooltip]::after {
  content: attr(data-tooltip);
  position: absolute;
  left: 50%;
  bottom: calc(100% + 8px);
  transform: translateX(-50%) translateY(4px);
  min-width: 180px;
  max-width: min(320px, calc(100vw - 24px));
  padding: 7px 9px;
  border-radius: 8px;
  border: 1px solid rgba(51, 65, 85, 0.85);
  background: rgba(5, 10, 20, 0.96);
  box-shadow: 0 10px 28px rgba(3, 8, 18, 0.36);
  color: #dbe7ff;
  font-size: 11px;
  line-height: 1.42;
  white-space: normal;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 120ms linear, transform 120ms ease, visibility 120ms linear;
  z-index: 8;
}

.signal-band[data-tooltip]::before,
.card-signal-corner[data-tooltip]::before {
  content: "";
  position: absolute;
  left: 50%;
  bottom: calc(100% + 2px);
  transform: translateX(-50%) translateY(4px);
  border-width: 6px 5px 0 5px;
  border-style: solid;
  border-color: rgba(5, 10, 20, 0.96) transparent transparent transparent;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 120ms linear, transform 120ms ease, visibility 120ms linear;
  z-index: 8;
}

.signal-band:hover::after,
.signal-band:hover::before,
.signal-band:focus-visible::after,
.signal-band:focus-visible::before,
.card-signal-corner:hover::after,
.card-signal-corner:hover::before,
.card-signal-corner:focus-visible::after,
.card-signal-corner:focus-visible::before {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}

.signal-band-fill {
  position: absolute;
  top: 0;
  bottom: 0;
  height: 100%;
  border-radius: 999px;
  opacity: 0.9;
}

.signal-band[data-visual="muted"] .signal-band-fill {
  opacity: 0.44;
  filter: grayscale(1) saturate(0.08) brightness(0.92);
}

.signal-band[data-visual="soft"] .signal-band-fill {
  opacity: 0.52;
  filter: grayscale(0.68) saturate(0.36) brightness(0.94);
}

.signal-band[data-visual="bias"] .signal-band-fill {
  opacity: 0.34;
  filter: grayscale(0.94) saturate(0.12) brightness(0.92);
}

.signal-band-fill-up {
  background: linear-gradient(90deg, rgba(34, 197, 94, 0.18), rgba(34, 197, 94, 0.9));
}

.signal-band-fill-down {
  background: linear-gradient(90deg, rgba(239, 68, 68, 0.9), rgba(239, 68, 68, 0.18));
}

.signal-band-copy {
  position: relative;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: #edf4ff;
  font-size: 7.5px;
  line-height: 1;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  white-space: nowrap;
  text-shadow: 0 1px 0 rgba(3, 8, 18, 0.9);
}

.signal-band-label,
.signal-band-strength,
.signal-band-divider {
  display: inline-flex;
  align-items: center;
}

.signal-band-strength {
  font-variant-numeric: tabular-nums;
}

.signal-band-divider {
  opacity: 0.75;
}

.signal-band[data-visual="muted"] .signal-band-copy {
  color: rgba(237, 244, 255, 0.82);
}

.signal-band[data-visual="soft"] .signal-band-copy {
  color: rgba(237, 244, 255, 0.84);
}

.signal-band[data-visual="bias"] .signal-band-copy {
  color: rgba(237, 244, 255, 0.68);
  font-weight: 780;
}

.signal-band[data-action="exit-long"] .signal-band-copy,
.signal-band[data-action="exit-short"] .signal-band-copy {
  color: #fde68a;
}

.signal-band-marker {
  position: absolute;
  top: 50%;
  width: 6px;
  height: 6px;
  border-radius: 999px;
  transform: translate(-50%, -50%);
  border: 2px solid rgba(8, 15, 29, 0.9);
  box-shadow: 0 0 0 1px rgba(5, 10, 20, 0.52), 0 0 12px rgba(8, 15, 29, 0.28);
}

.signal-band[data-visual="muted"] .signal-band-marker {
  opacity: 0.62;
  filter: grayscale(1) saturate(0.08) brightness(0.94);
}

.signal-band[data-visual="soft"] .signal-band-marker {
  opacity: 0.7;
  filter: grayscale(0.66) saturate(0.34) brightness(0.95);
}

.signal-band[data-visual="bias"] .signal-band-marker {
  opacity: 0.46;
  filter: grayscale(0.96) saturate(0.08) brightness(0.9);
}

.signal-band-marker-up {
  background: #22c55e;
}

.signal-band-marker-down {
  background: #ef4444;
}

.signal-band-marker-neutral {
  background: #f59e0b;
}

.pending {
  position: absolute;
  inset: 56px 6px 28px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1px dashed rgba(143, 155, 176, 0.18);
  color: var(--muted);
  text-align: center;
  padding: 12px;
}

.pending-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--text);
}

.pending-empty .pending-title {
  color: #dff5ff;
}

.pending-empty .pending-note {
  max-width: 180px;
  text-align: center;
}

.pending-note {
  font-size: 11px;
}

.error-box {
  position: absolute;
  inset: 56px 6px 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 12px;
  text-align: center;
  color: #c8d1df;
  font-size: 11px;
}

.news-ribbon {
  display: grid;
  grid-template-columns: auto auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
  height: 32px;
  padding: 0 10px;
  border-top: 1px solid var(--line);
  background: #0b1220;
  font-family: var(--ui-sans);
}

.ribbon-tone {
  flex: 0 0 auto;
}

.ribbon-nav {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.ribbon-nav-btn {
  width: 24px;
  height: 24px;
  padding: 0;
  border: 1px solid rgba(143, 155, 176, 0.26);
  border-radius: 999px;
  background: rgba(7, 14, 26, 0.76);
  color: rgba(217, 226, 241, 0.88);
  font: inherit;
  font-size: 15px;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: color 160ms ease, border-color 160ms ease, background 160ms ease, opacity 160ms ease;
}

.ribbon-nav-btn:hover,
.ribbon-nav-btn:focus-visible {
  color: var(--yellow);
  border-color: rgba(244, 180, 0, 0.42);
  background: rgba(32, 25, 5, 0.84);
  outline: none;
}

.ribbon-nav-btn:disabled {
  opacity: 0.36;
  cursor: default;
}

.ribbon-story {
  min-width: 0;
  color: var(--text);
  text-decoration: none;
  line-height: 1;
  transition: color 180ms ease, opacity 180ms ease;
}

.ribbon-story[data-empty="true"] {
  cursor: default;
  pointer-events: none;
}

.ribbon-story:hover,
.ribbon-story:focus-visible {
  color: #f7fbff;
}

.ribbon-headline {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.01em;
  opacity: 0.95;
}

.ribbon-meta {
  display: inline-flex;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
  flex-wrap: wrap;
  justify-self: end;
  min-width: 0;
  font-size: 12px;
  color: rgba(200, 209, 223, 0.72);
  font-family: var(--ui-sans);
}

.ribbon-meta-source {
  white-space: nowrap;
}

.ribbon-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 2px 7px;
  border-radius: 999px;
  border: 1px solid rgba(143, 155, 176, 0.24);
  background: rgba(8, 15, 29, 0.74);
  font-size: 10px;
  line-height: 1;
  font-weight: 700;
  letter-spacing: 0.02em;
  white-space: nowrap;
}

.ribbon-badge-impact-high {
  color: #ffe2e2;
  border-color: rgba(239, 68, 68, 0.34);
  background: rgba(127, 29, 29, 0.3);
}

.ribbon-badge-impact-medium {
  color: #fde68a;
  border-color: rgba(244, 180, 0, 0.3);
  background: rgba(120, 82, 6, 0.24);
}

.ribbon-badge-impact-low {
  color: rgba(226, 232, 240, 0.84);
  border-color: rgba(148, 163, 184, 0.24);
}

.ribbon-badge-sentiment-bullish {
  color: #bbf7d0;
  border-color: rgba(34, 197, 94, 0.28);
}

.ribbon-badge-sentiment-bearish {
  color: #fecaca;
  border-color: rgba(239, 68, 68, 0.28);
}

.ribbon-badge-sentiment-neutral {
  color: rgba(217, 226, 241, 0.82);
}

.ribbon-badge-delta-new {
  color: #dff5ff;
  border-color: rgba(34, 211, 238, 0.28);
}

.ribbon-badge-delta-escalation {
  color: #f9d38c;
  border-color: rgba(251, 191, 36, 0.28);
}

.hidden {
  display: none !important;
}

.ticker-editor-overlay {
  position: fixed;
  inset: 0;
  z-index: 41;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 18px;
  background: rgba(3, 8, 18, 0.68);
  backdrop-filter: blur(12px);
}

.ticker-editor {
  width: min(520px, calc(100vw - 32px));
  border: 1px solid rgba(34, 211, 238, 0.18);
  border-radius: 16px;
  background: #0d1525;
  box-shadow: 0 24px 80px rgba(3, 8, 18, 0.55);
  overflow: hidden;
}

.ticker-editor-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 18px 12px;
  border-bottom: 1px solid var(--line);
}

.ticker-editor-kicker {
  color: #8fe8ff;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.ticker-editor-title {
  margin: 8px 0 0;
  font-size: 20px;
  line-height: 1.2;
}

.ticker-editor-close {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: #0d1525;
  color: #c8d1df;
  cursor: pointer;
}

.ticker-editor-close:hover {
  color: #f3f8ff;
}

.ticker-editor-body {
  padding: 16px 18px 12px;
  display: grid;
  gap: 14px;
  align-content: start;
}

.ticker-editor-searchbox {
  display: grid;
  gap: 8px;
}

.ticker-editor-options {
  order: -1;
}

.ticker-editor-input {
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #0b1220;
  color: var(--text);
  padding: 12px 14px;
  font-size: 16px;
}

.ticker-editor-meta {
  min-height: 36px;
  padding: 0 2px;
}

.ticker-editor-suggestions {
  position: static;
  top: auto;
  left: auto;
  right: auto;
}

.ticker-editor-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  padding: 12px 18px 18px;
  border-top: 1px solid var(--line);
}

.ticker-editor-options {
  display: grid;
  gap: 8px;
}

.settings-group {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid rgba(78, 92, 115, 0.42);
  border-radius: 12px;
  background: rgba(8, 16, 30, 0.52);
}

.settings-group-head {
  display: grid;
  gap: 4px;
}

.settings-group-title {
  color: #f3f8ff;
  font-size: 14px;
  font-weight: 800;
}

.settings-group-note {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.35;
}

.ticker-editor-alert-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.settings-toggle {
  display: grid;
  grid-template-columns: auto auto minmax(0, 1fr);
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border: 1px solid rgba(78, 92, 115, 0.42);
  border-radius: 12px;
  background: rgba(8, 16, 30, 0.52);
  cursor: pointer;
}

.settings-toggle-compact {
  min-width: 0;
  padding: 9px 10px;
  border-radius: 10px;
  background: rgba(9, 18, 32, 0.64);
}

.settings-toggle-auto-switch {
  grid-column: 1 / -1;
  margin-top: 2px;
}

.settings-toggle-input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.settings-toggle-box {
  position: relative;
  width: 18px;
  height: 18px;
  border-radius: 6px;
  border: 1px solid rgba(120, 140, 172, 0.5);
  background: rgba(7, 14, 26, 0.92);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03);
}

.settings-toggle-box::after {
  content: "";
  position: absolute;
  left: 5px;
  top: 1px;
  width: 5px;
  height: 10px;
  border-right: 2px solid transparent;
  border-bottom: 2px solid transparent;
  transform: rotate(40deg);
}

.settings-toggle-input:checked + .settings-toggle-box {
  border-color: rgba(34, 211, 238, 0.48);
  background: rgba(10, 30, 48, 0.96);
}

.settings-toggle-input:checked + .settings-toggle-box::after {
  border-color: #8fe8ff;
}

.settings-toggle-input:focus-visible + .settings-toggle-box {
  outline: 0;
  box-shadow: 0 0 0 2px rgba(34, 211, 238, 0.22);
}

.settings-toggle-copy {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.settings-toggle-title {
  color: #f3f8ff;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.2;
}

.settings-toggle-note {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.35;
}

.settings-toggle.is-disabled {
  opacity: 0.54;
  cursor: not-allowed;
}

@media (max-width: 700px) {
  .ticker-editor-alert-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.settings-cell-meta {
  min-height: 30px;
  padding: 0 4px;
}

.settings-cell-title {
  color: var(--text);
  font-size: 12px;
  line-height: 1.35;
}

.settings-cell-copy {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.35;
}

.settings-suggestions {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  right: 0;
  z-index: 12;
  display: grid;
  gap: 4px;
  max-height: 280px;
  overflow-y: auto;
  padding: 8px;
  border: 1px solid rgba(78, 92, 115, 0.65);
  border-radius: 12px;
  background: rgba(8, 16, 30, 0.98);
  box-shadow: 0 20px 40px rgba(2, 6, 23, 0.6);
}

.ticker-editor-searchbox .ticker-editor-suggestions {
  position: static;
  top: auto;
  left: auto;
  right: auto;
  z-index: auto;
  margin-top: 2px;
}

.settings-suggestion {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
  width: 100%;
  padding: 10px 12px;
  border: 1px solid transparent;
  border-radius: 10px;
  background: rgba(13, 21, 37, 0.92);
  color: var(--text);
  text-align: left;
  cursor: pointer;
}

.settings-suggestion:hover,
.settings-suggestion.is-active {
  border-color: rgba(34, 211, 238, 0.36);
  background: rgba(17, 29, 49, 0.98);
}

.settings-suggestion-main {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.settings-suggestion-symbol {
  font-size: 13px;
  font-weight: 700;
  color: #f3f8ff;
}

.settings-suggestion-title {
  min-width: 0;
  color: var(--muted);
  font-size: 12px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.settings-suggestion-meta {
  color: #8fe8ff;
  font-size: 11px;
  white-space: nowrap;
}

.settings-action {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #0d1525;
  color: var(--text);
  padding: 8px 12px;
  font-size: 13px;
  cursor: pointer;
}

@media (max-width: 1100px) {
  .topbar-main {
    grid-template-columns: auto minmax(0, 1fr);
  }

  .topbar-meta {
    grid-column: 1 / -1;
    justify-content: flex-start;
  }

  .brand {
    min-width: 0;
  }

  .brand-mark {
    font-size: 29px;
  }

  .brand-triangle {
    border-left-width: 5px;
    border-right-width: 5px;
  }

  .brand-mark[data-trend="up"] .brand-triangle,
  .brand-mark[data-trend="neutral"] .brand-triangle {
    border-bottom-width: 9px;
  }

  .brand-mark[data-trend="down"] .brand-triangle {
    border-top-width: 9px;
  }

  .timeframe-picker {
    padding: 0 8px;
    gap: 4px;
    height: 36px;
  }

  .dashboard-grid-control {
    min-height: 36px;
  }

  .tf-btn {
    font-size: 13px;
    min-height: 24px;
    padding: 4px 6px;
  }

}

@media (max-width: 700px) {
  .topbar {
    gap: 10px;
    padding-bottom: 12px;
  }

  .topbar-main {
    grid-template-columns: minmax(0, 1fr);
    align-items: stretch;
  }

  .brand {
    justify-content: flex-start;
  }

  .brand-mark {
    font-size: 24px;
  }

  .brand-triangle {
    border-left-width: 4px;
    border-right-width: 4px;
  }

  .brand-mark[data-trend="up"] .brand-triangle,
  .brand-mark[data-trend="neutral"] .brand-triangle {
    border-bottom-width: 8px;
  }

  .brand-mark[data-trend="down"] .brand-triangle {
    border-top-width: 8px;
  }

  .timeframe-picker {
    width: 100%;
    justify-content: flex-start;
    flex-wrap: wrap;
    gap: 4px;
    padding: 0;
    border-right: 0;
    border-left: 0;
    height: auto;
  }

  .tf-btn {
    font-size: 12px;
    min-height: 24px;
    padding: 4px 6px;
  }

  .topbar-controls {
    display: grid;
    gap: 8px;
  }

  .topbar-actions {
    width: 100%;
    justify-content: space-between;
    align-items: stretch;
  }

  .dashboard-switcher {
    flex: 1 1 auto;
    width: auto;
  }

  .dashboard-grid-control {
    width: 100%;
    justify-content: flex-end;
  }

  .topbar-meta {
    width: 100%;
    justify-content: flex-start;
    gap: 6px 10px;
  }

  .best-setup-pill,
  .sync-pill {
    order: 1;
  }

  .sync-pill {
    order: 2;
  }

  .best-setup-pill {
    max-width: 100%;
    width: 100%;
  }

  .best-setup-pill[data-compact="true"] {
    width: auto;
  }

  .dashboard-intel {
    padding: 8px 10px 10px;
    gap: 8px;
  }

  .dashboard-strip {
    grid-template-columns: 1fr;
    max-height: none;
    min-height: 0;
  }

  .dashboard-intel-head {
    align-items: flex-start;
    gap: 8px;
  }

  .dashboard-intel-title {
    font-size: 14px;
  }

  .trade-ideas-list {
    grid-auto-columns: minmax(168px, 82vw);
    gap: 8px;
  }

  .trade-signals-list {
    gap: 6px;
  }

  .trade-signal-card {
    min-width: 172px;
    max-width: 78vw;
  }

  .trade-idea-card {
    padding: 9px 10px;
  }

  .news-ribbon {
    grid-template-columns: auto auto 1fr;
    grid-template-areas:
      "tone nav meta"
      "story story story";
    gap: 6px 8px;
    height: auto;
    padding: 6px 10px 8px;
  }

  .ribbon-tone {
    grid-area: tone;
  }

  .ribbon-nav {
    grid-area: nav;
  }

  .ribbon-story {
    grid-area: story;
  }

  .ribbon-meta {
    grid-area: meta;
    justify-self: end;
    font-size: 11px;
  }

  .card-signal-meta {
    left: 8px;
    bottom: 24px;
    max-width: calc(100% - 82px);
    gap: 5px;
  }

  .signal-conviction-badge {
    padding: 3px 6px;
  }

  .card-live {
    --card-head-height: 0px;
  }

  .settings-suggestion {
    grid-template-columns: 1fr;
    gap: 4px;
  }

  .settings-suggestion-meta {
    white-space: normal;
  }
}
