:root {
  --bg: #071019;
  --bg-deep: #040a11;
  --panel: #0c1823;
  --panel-2: #101f2c;
  --line: rgba(148, 176, 198, 0.16);
  --line-strong: rgba(148, 176, 198, 0.3);
  --text: #e9f1f7;
  --muted: #8da3b3;
  --dim: #657b8b;
  --cyan: #27d7e8;
  --blue: #55b9ff;
  --purple: #c084ff;
  --red: #ff6575;
  --orange: #ff9a55;
  --green: #51d69c;
  --gold: #e9c46a;
  --radius: 18px;
  --shadow: 0 20px 70px rgba(0, 0, 0, 0.28);
}

* {
  box-sizing: border-box;
}

html {
  background: var(--bg-deep);
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  color: var(--text);
  background:
    radial-gradient(circle at 12% -10%, rgba(39, 215, 232, 0.12), transparent 34rem),
    radial-gradient(circle at 88% 4%, rgba(192, 132, 255, 0.09), transparent 32rem),
    linear-gradient(180deg, #091520 0, var(--bg) 28rem, var(--bg-deep) 100%);
  font-family:
    "Microsoft YaHei UI",
    "PingFang SC",
    "Noto Sans CJK SC",
    system-ui,
    sans-serif;
  line-height: 1.55;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input {
  font: inherit;
}

.site-header {
  width: min(1440px, calc(100% - 28px));
  margin: 0 auto;
  padding: 24px 0 20px;
}

.header-main,
.stock-title-row,
.stock-meta,
.chart-toolbar,
.section-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  font-size: 19px;
  font-weight: 750;
  letter-spacing: 0.04em;
}

.brand-mark {
  width: 12px;
  height: 26px;
  border-radius: 4px;
  background: linear-gradient(180deg, var(--cyan), var(--purple));
  box-shadow: 0 0 24px rgba(39, 215, 232, 0.45);
  transform: skewX(-12deg);
}

.data-badge {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 7px 12px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  background: rgba(12, 24, 35, 0.72);
  font-size: 12px;
}

.data-badge strong {
  color: var(--text);
  font-variant-numeric: tabular-nums;
}

.compliance-line {
  margin: 16px 0 20px;
  color: var(--muted);
  font-size: 13px;
}

.search-shell {
  position: relative;
  max-width: 760px;
}

.search-shell > label {
  display: block;
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 12px;
  letter-spacing: 0.04em;
}

.search-input-wrap {
  position: relative;
}

.search-input-wrap input {
  width: 100%;
  min-height: 54px;
  padding: 0 48px 0 17px;
  color: var(--text);
  background: linear-gradient(180deg, rgba(17, 34, 48, 0.96), rgba(9, 22, 33, 0.96));
  border: 1px solid var(--line-strong);
  border-radius: 15px;
  outline: none;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.2);
  transition: border-color 160ms ease, box-shadow 160ms ease;
}

.search-input-wrap input:focus {
  border-color: rgba(39, 215, 232, 0.66);
  box-shadow: 0 0 0 4px rgba(39, 215, 232, 0.09);
}

.search-input-wrap input::placeholder {
  color: #607786;
}

.search-hint {
  position: absolute;
  right: 18px;
  top: 50%;
  color: var(--cyan);
  font-size: 26px;
  transform: translateY(-52%);
}

.search-results {
  position: absolute;
  z-index: 20;
  top: calc(100% + 8px);
  width: 100%;
  max-height: 370px;
  overflow: auto;
  padding: 7px;
  background: #0b1823;
  border: 1px solid var(--line-strong);
  border-radius: 14px;
  box-shadow: var(--shadow);
}

.search-result {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 11px 12px;
  border-radius: 10px;
}

.search-result:hover,
.search-result:focus {
  background: rgba(39, 215, 232, 0.09);
  outline: none;
}

.search-result small {
  color: var(--muted);
}

.page-shell {
  width: min(1440px, calc(100% - 28px));
  margin: 0 auto 50px;
}

.overview-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 28px;
}

.metric-card {
  min-height: 124px;
  padding: 17px;
  background:
    linear-gradient(135deg, rgba(19, 40, 55, 0.94), rgba(8, 20, 30, 0.94));
  border: 1px solid var(--line);
  border-radius: 16px;
}

.metric-card > span,
.metric-card small {
  display: block;
  color: var(--muted);
}

.metric-card > span {
  margin-bottom: 8px;
  font-size: 12px;
}

.metric-card strong {
  display: block;
  margin-bottom: 6px;
  font-size: clamp(24px, 4vw, 34px);
  line-height: 1.15;
  font-variant-numeric: tabular-nums;
}

.metric-card small {
  font-size: 11px;
}

.alert-card.purple {
  border-color: rgba(192, 132, 255, 0.28);
}

.alert-card.blue {
  border-color: rgba(85, 185, 255, 0.28);
}

.alert-card.red {
  border-color: rgba(255, 101, 117, 0.28);
}

.alert-card.orange {
  border-color: rgba(255, 154, 85, 0.28);
}

.radar-panel,
.chart-panel,
.detail-card,
.history-strip {
  margin-bottom: 18px;
  background: rgba(9, 21, 31, 0.84);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

.radar-panel,
.chart-panel,
.history-strip {
  padding: 18px;
}

.section-heading {
  align-items: flex-end;
  margin-bottom: 17px;
}

.section-heading.compact {
  margin-bottom: 12px;
}

.eyebrow {
  margin: 0 0 3px;
  color: var(--cyan);
  font-size: 10px;
  font-weight: 750;
  letter-spacing: 0.16em;
}

h1,
h2,
h3,
p {
  overflow-wrap: anywhere;
}

h1,
h2 {
  margin: 0;
}

.radar-panel h1 {
  font-size: clamp(22px, 3vw, 30px);
}

.section-heading h2 {
  font-size: 20px;
}

.section-note {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  text-align: right;
}

.tab-list {
  display: flex;
  gap: 7px;
  overflow-x: auto;
  padding: 1px 1px 11px;
  scrollbar-width: thin;
}

.tab-button {
  flex: 0 0 auto;
  min-height: 38px;
  padding: 0 13px;
  color: var(--muted);
  background: rgba(15, 31, 44, 0.9);
  border: 1px solid var(--line);
  border-radius: 999px;
  cursor: pointer;
}

.tab-button.active {
  color: #071019;
  background: var(--cyan);
  border-color: var(--cyan);
  font-weight: 750;
}

.radar-content {
  min-height: 170px;
}

.radar-list {
  display: grid;
  gap: 9px;
}

.radar-row {
  display: grid;
  grid-template-columns: minmax(130px, 1.1fr) minmax(88px, 0.55fr) minmax(0, 2.2fr);
  gap: 14px;
  align-items: center;
  padding: 14px;
  background: linear-gradient(120deg, rgba(15, 31, 44, 0.88), rgba(8, 19, 28, 0.73));
  border: 1px solid transparent;
  border-radius: 13px;
  transition: border-color 150ms ease, transform 150ms ease;
}

.radar-row:hover {
  border-color: rgba(39, 215, 232, 0.34);
  transform: translateY(-1px);
}

.stock-identity strong {
  display: block;
  font-size: 15px;
}

.stock-identity small,
.row-meta,
.row-copy small {
  color: var(--muted);
  font-size: 11px;
}

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

.quote-cell strong {
  display: block;
  font-size: 17px;
}

.positive {
  color: var(--red) !important;
}

.negative {
  color: var(--green) !important;
}

.row-copy p {
  display: -webkit-box;
  margin: 0 0 4px;
  overflow: hidden;
  color: #c8d8e3;
  font-size: 12px;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.empty-state {
  display: grid;
  min-height: 150px;
  place-items: center;
  padding: 22px;
  color: var(--muted);
  text-align: center;
  border: 1px dashed var(--line);
  border-radius: 13px;
}

.stock-header {
  padding-bottom: 18px;
}

.back-link {
  padding: 8px 12px;
  color: var(--muted);
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 12px;
}

.back-link:hover {
  color: var(--text);
  border-color: var(--line-strong);
}

.stock-title-row {
  align-items: flex-end;
  margin-top: 28px;
}

.stock-code {
  margin: 0 0 3px;
  color: var(--cyan);
  font-size: 12px;
  letter-spacing: 0.1em;
}

.stock-title-row h1 {
  font-size: clamp(26px, 5vw, 42px);
}

.price-block {
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.price-block strong {
  display: block;
  font-size: clamp(30px, 6vw, 46px);
  line-height: 1.1;
}

.price-block span {
  color: var(--muted);
}

.stock-meta {
  justify-content: flex-start;
  margin-top: 13px;
  color: var(--muted);
  font-size: 12px;
}

.stock-meta span {
  padding: 5px 9px;
  background: rgba(15, 31, 44, 0.7);
  border: 1px solid var(--line);
  border-radius: 999px;
}

.recent-five {
  display: grid;
  grid-auto-columns: minmax(156px, 1fr);
  grid-auto-flow: column;
  gap: 8px;
  overflow-x: auto;
  padding-bottom: 3px;
  scrollbar-width: thin;
}

.history-card {
  position: relative;
  min-height: 112px;
  padding: 12px;
  text-align: left;
  color: var(--text);
  background: linear-gradient(150deg, rgba(18, 38, 53, 0.98), rgba(8, 19, 29, 0.96));
  border: 1px solid var(--line);
  border-radius: 13px;
  cursor: pointer;
  transition: border-color 160ms ease, transform 160ms ease;
}

.history-card:hover,
.history-card:focus {
  border-color: rgba(39, 215, 232, 0.5);
  outline: none;
  transform: translateY(-1px);
}

.history-date {
  color: var(--muted);
  font-size: 11px;
}

.history-main {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
  margin-top: 4px;
}

.history-main strong {
  font-size: 15px;
}

.history-tag {
  display: inline-block;
  margin-top: 10px;
  padding: 3px 7px;
  color: #bcd0dd;
  background: rgba(255, 255, 255, 0.04);
  border-radius: 7px;
  font-size: 11px;
}

.history-icons {
  position: absolute;
  right: 10px;
  bottom: 9px;
  display: flex;
  gap: 4px;
}

.mini-icon {
  display: inline-grid;
  width: 13px;
  height: 13px;
  place-items: center;
  color: #061019;
  border-radius: 50%;
  font-size: 9px;
  font-style: normal;
  font-weight: 900;
}

.mini-icon.probe {
  background: var(--purple);
}

.mini-icon.short {
  background: var(--red);
}

.mini-icon.lure {
  color: var(--orange);
  background: transparent;
  font-size: 16px;
}

.chart-toolbar {
  flex-wrap: wrap;
  margin-bottom: 8px;
}

.legend-guide {
  display: flex;
  flex-wrap: wrap;
  gap: 7px 12px;
  color: var(--muted);
  font-size: 11px;
}

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

.legend-dot {
  display: inline-block;
  width: 9px;
  height: 9px;
  border-radius: 50%;
}

.legend-dot.purple {
  background: var(--purple);
  box-shadow: 0 0 9px var(--purple);
}

.legend-dot.blue {
  background: var(--blue);
  box-shadow: 0 0 7px var(--blue);
}

.legend-dot.red {
  width: 0;
  height: 0;
  border-right: 6px solid transparent;
  border-bottom: 10px solid var(--red);
  border-left: 6px solid transparent;
  border-radius: 0;
  transform: rotate(180deg);
}

.legend-cross {
  display: inline-flex;
  width: 12px;
  height: 12px;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: var(--orange);
  font-size: 16px;
  font-style: normal;
  font-weight: 800;
  line-height: 1;
}

.history-mobile-signal {
  display: none;
}

.legend-market {
  display: inline-block;
  width: 9px;
  height: 12px;
  background:
    linear-gradient(
      90deg,
      rgba(255, 138, 128, 0.28) 0 42%,
      transparent 42% 58%,
      rgba(38, 166, 154, 0.26) 58% 100%
    );
  border: 1px solid rgba(148, 176, 198, 0.24);
  border-radius: 2px;
}

.toggle-control {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--muted);
  font-size: 11px;
  cursor: pointer;
}

.toggle-control input {
  accent-color: var(--cyan);
}

.stock-chart {
  width: 100%;
  height: min(62vh, 640px);
  min-height: 470px;
}

.chart-tip {
  margin: 3px 0 0;
  color: var(--dim);
  font-size: 11px;
}

.detail-card {
  padding: 18px;
}

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

.detail-head h2 {
  margin-bottom: 4px;
  font-size: 22px;
}

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

.detail-pct {
  flex: 0 0 auto;
  font-size: 24px;
  font-weight: 750;
  font-variant-numeric: tabular-nums;
}

.detail-section {
  padding-top: 16px;
}

.detail-section h3 {
  margin: 0 0 9px;
  font-size: 14px;
}

.fact-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 7px;
  margin-bottom: 11px;
}

.fact-grid span {
  padding: 8px 10px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.025);
  border-radius: 8px;
  font-size: 11px;
}

.fact-grid strong {
  float: right;
  color: var(--text);
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

.plain-paragraph {
  margin: 0;
  color: #c8d8e3;
  font-size: 13px;
}

.alert-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 8px;
}

.alert-detail {
  padding: 12px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--line);
  border-radius: 10px;
}

.alert-detail strong {
  display: block;
  margin-bottom: 4px;
  font-size: 13px;
}

.alert-detail p {
  margin: 0;
  color: var(--muted);
  font-size: 11px;
}

.similar-grid {
  display: grid;
  gap: 8px;
}

.similar-card {
  width: 100%;
  padding: 12px;
  color: var(--text);
  text-align: left;
  background: rgba(15, 31, 44, 0.72);
  border: 1px solid var(--line);
  border-radius: 11px;
  cursor: pointer;
}

.similar-card:hover,
.similar-card:focus {
  border-color: rgba(85, 185, 255, 0.45);
  outline: none;
}

.similar-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 6px;
}

.similar-top strong {
  font-size: 13px;
}

.similar-top span {
  color: var(--cyan);
  font-size: 12px;
}

.similar-card p {
  margin: 4px 0;
  color: var(--muted);
  font-size: 11px;
}

.history-summary {
  margin: 10px 0 0;
  padding: 10px 12px;
  color: #d1e3ee;
  background: rgba(39, 215, 232, 0.06);
  border-left: 2px solid var(--cyan);
  font-size: 12px;
}

.site-footer {
  width: min(1440px, calc(100% - 28px));
  margin: 0 auto;
  padding: 18px 0 32px;
  color: var(--dim);
  border-top: 1px solid var(--line);
  font-size: 11px;
}

.site-footer p {
  margin: 4px 0;
}

@media (min-width: 760px) {
  .site-header,
  .page-shell,
  .site-footer {
    width: min(1440px, calc(100% - 44px));
  }

  .overview-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .radar-row {
    grid-template-columns: minmax(170px, 0.75fr) minmax(110px, 0.42fr) minmax(0, 2fr);
  }

  .recent-five {
    grid-auto-flow: initial;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    overflow: visible;
  }
}

@media (min-width: 1120px) {
  .site-header {
    display: grid;
    grid-template-columns: 1.1fr 1.8fr;
    column-gap: 42px;
    align-items: end;
  }

  .header-main,
  .compliance-line {
    grid-column: 1;
  }

  .search-shell {
    grid-column: 2;
    grid-row: 1 / span 2;
    align-self: end;
  }

  .overview-grid {
    grid-template-columns: repeat(6, minmax(0, 1fr));
  }

  .stock-header {
    display: block;
  }

  .detail-section.history {
    padding-bottom: 4px;
  }
}

@media (max-width: 640px) {
  .site-header,
  .page-shell,
  .site-footer {
    width: calc(100% - 20px);
  }

  .site-header {
    padding-top: 17px;
  }

  .header-main {
    gap: 8px;
  }

  .brand {
    font-size: 16px;
  }

  .data-badge {
    padding: 5px 9px;
  }

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

  .section-note {
    text-align: left;
  }

  .radar-panel,
  .chart-panel,
  .detail-card,
  .history-strip {
    padding: 13px;
    border-radius: 14px;
  }

  .radar-row {
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 8px;
  }

  .row-copy {
    grid-column: 1 / -1;
  }

  .stock-chart {
    height: 510px;
    min-height: 510px;
  }

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

  .detail-head {
    gap: 10px;
  }

  .detail-head h2 {
    font-size: 19px;
  }
}

/* Stock hologram immersive layout and rich tooltip */
body[data-page="stock"] .stock-header {
  width: 100%;
  max-width: none;
  padding: 10px 16px 8px;
}

body[data-page="stock"] .stock-shell {
  width: 100%;
  max-width: none;
  margin: 0 auto 24px;
  padding: 10px 16px;
}

body[data-page="stock"] .site-footer {
  width: 100%;
  max-width: none;
  padding: 12px 16px 24px;
}

body[data-page="stock"] .stock-title-row {
  margin-top: 2px;
}

body[data-page="stock"] .stock-title-row h1 {
  font-size: clamp(27px, 3vw, 38px);
}

body[data-page="stock"] .stock-meta {
  margin-top: 4px;
}

body[data-page="stock"] .history-strip {
  padding: 8px 10px;
  margin-bottom: 10px;
}

body[data-page="stock"] .section-heading {
  margin-bottom: 6px;
}

body[data-page="stock"] .history-strip .eyebrow {
  display: none;
}

body[data-page="stock"] .history-strip .section-heading h2 {
  font-size: 18px;
}

body[data-page="stock"] .chart-panel {
  padding: 10px 12px 8px;
  margin-bottom: 10px;
}

body[data-page="stock"] .chart-toolbar {
  margin-bottom: 0;
}

body[data-page="stock"] .legend-guide {
  gap: 6px 14px;
}

.chart-usage {
  color: var(--dim);
  font-size: 10px;
}

.legend-volume {
  display: inline-block;
  width: 7px;
  height: 13px;
  border-radius: 2px;
}

.legend-volume.green {
  background: #00e676;
  border: 1px solid #69f0ae;
  box-shadow: 0 0 7px rgba(0, 230, 118, 0.75);
}

.legend-volume.gold {
  background: #ffd700;
  border: 1px solid #ffe57f;
  box-shadow: 0 0 7px rgba(255, 215, 0, 0.75);
}

body[data-page="stock"] .stock-chart {
  height: calc(100vh - 235px);
  min-height: 600px;
}

body[data-page="stock"] .recent-five {
  display: grid;
  grid-auto-flow: initial;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  align-items: stretch;
  gap: 10px;
  overflow-x: auto;
  padding: 3px 3px 6px;
  margin: -3px -3px 0;
  scrollbar-width: thin;
}

body[data-page="stock"] .history-card {
  display: flex;
  height: 100%;
  position: relative;
  min-width: 0;
  min-height: 112px;
  flex-direction: column;
  justify-content: space-between;
  padding: 10px 12px 9px;
  overflow: visible;
  background:
    radial-gradient(circle at 100% 0, rgba(39, 215, 232, 0.08), transparent 9rem),
    linear-gradient(145deg, rgba(20, 42, 58, 0.98), rgba(8, 20, 30, 0.97));
  border-color: rgba(129, 164, 185, 0.18);
  border-radius: 13px;
  box-shadow: inset 0 1px rgba(255, 255, 255, 0.025);
}

body[data-page="stock"] .history-card.active {
  border-color: rgba(39, 215, 232, 0.68);
  box-shadow:
    inset 0 0 0 1px rgba(39, 215, 232, 0.6),
    0 0 0 2px rgba(39, 215, 232, 0.09);
}

.history-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.history-topline {
  color: #a8bac6;
  font-size: 12px;
}

.history-topline > span {
  color: #a8bac6;
}

.history-date-wrap {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}

.history-date {
  display: inline-flex;
  min-height: 27px;
  align-items: center;
  padding: 2px 8px;
  color: #f0f6f9;
  background: rgba(84, 119, 142, 0.18);
  border: 1px solid rgba(144, 178, 199, 0.13);
  border-radius: 7px;
  font-size: 17px;
  font-weight: 850;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.01em;
  white-space: nowrap;
}

.history-topline strong {
  font-size: 13px;
  font-variant-numeric: tabular-nums;
}

.history-title {
  display: block;
  margin: 10px 0 7px;
  overflow: hidden;
  color: #f0f6fa;
  font-size: 15px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.history-data {
  display: block;
  min-height: 28px;
  overflow: hidden;
  color: #e9c46a;
  font-size: 11px;
  font-weight: 650;
  line-height: 1.35;
  white-space: normal;
}

.story-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-top: 8px;
}

.story-pill {
  display: inline-flex;
  max-width: 100%;
  padding: 2px 6px;
  overflow: hidden;
  color: #afc9d8;
  background: rgba(85, 185, 255, 0.09);
  border: 1px solid rgba(85, 185, 255, 0.14);
  border-radius: 999px;
  font-size: 9px;
  font-style: normal;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.story-pill:nth-child(2n) {
  color: #dec88d;
  background: rgba(233, 196, 106, 0.08);
  border-color: rgba(233, 196, 106, 0.14);
}

.story-pill:nth-child(3n) {
  color: #c9b6ef;
  background: rgba(192, 132, 255, 0.08);
  border-color: rgba(192, 132, 255, 0.14);
}

body[data-page="stock"] .detail-card {
  padding: 16px;
}

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

.similar-section-head > div > span {
  color: var(--cyan);
  font-size: 9px;
  font-weight: 750;
  letter-spacing: 0.16em;
}

.similar-section-head h2 {
  margin-top: 2px;
  font-size: 20px;
}

.similar-section-head > p {
  margin: 0;
  color: var(--muted);
  font-size: 11px;
}

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

body[data-page="stock"] .similar-card {
  position: relative;
  display: block;
  min-width: 0;
  padding: 14px;
  overflow: hidden;
  background:
    radial-gradient(circle at 90% 0, rgba(39, 215, 232, 0.07), transparent 13rem),
    linear-gradient(150deg, rgba(18, 38, 53, 0.96), rgba(7, 18, 28, 0.97));
  border: 1px solid rgba(129, 164, 185, 0.18);
  border-radius: 14px;
}

body[data-page="stock"] .similar-card:hover {
  border-color: rgba(39, 215, 232, 0.52);
  transform: translateY(-2px);
}

.similar-header,
.similarity-caption,
.similar-day,
.tooltip-history-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.rank-badge {
  padding: 2px 8px;
  color: #07131c;
  background: linear-gradient(90deg, #27d7e8, #7fe7ef);
  border-radius: 999px;
  font-size: 10px;
  font-weight: 800;
}

.similar-header strong {
  color: #d8e6ef;
  font-size: 12px;
}

.similarity-line {
  height: 5px;
  margin: 13px 0 6px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.055);
  border-radius: 999px;
}

.similarity-line span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, #27d7e8, #83e9f1);
  border-radius: inherit;
  box-shadow: 0 0 12px rgba(39, 215, 232, 0.42);
}

.similarity-caption {
  color: var(--muted);
  font-size: 10px;
}

.similarity-caption b {
  color: var(--cyan);
  font-size: 12px;
}

.similar-day {
  justify-content: flex-start;
  margin: 14px 0 8px;
}

.similar-day strong {
  font-size: 25px;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

.similar-day span {
  color: #e5edf2;
  font-size: 13px;
  font-weight: 700;
}

.similar-summary {
  min-height: 36px;
  margin: 0 0 9px;
  color: var(--muted);
  font-size: 11px;
}

.similar-reasons {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  min-height: 25px;
  margin-bottom: 10px;
}

.similar-reasons span {
  padding: 2px 6px;
  color: #b9d7e5;
  background: rgba(85, 185, 255, 0.08);
  border: 1px solid rgba(85, 185, 255, 0.13);
  border-radius: 999px;
  font-size: 9px;
}

.after-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 5px;
}

.after-cell {
  padding: 7px 5px;
  text-align: center;
  background: rgba(255, 255, 255, 0.028);
  border: 1px solid rgba(255, 255, 255, 0.045);
  border-radius: 8px;
}

.after-cell small {
  display: block;
  margin-bottom: 2px;
  color: var(--muted);
  font-size: 9px;
}

.after-cell strong {
  font-size: 13px;
  font-variant-numeric: tabular-nums;
}

.locate-history {
  display: block;
  margin-top: 10px;
  color: var(--cyan);
  font-size: 10px;
  text-align: right;
}

.similar-summary-bar {
  margin-top: 10px;
  padding: 9px 12px;
  color: #b7cad7;
  background: rgba(39, 215, 232, 0.045);
  border: 1px solid rgba(39, 215, 232, 0.1);
  border-radius: 9px;
  font-size: 10px;
  text-align: center;
}

/* ECharts rich tooltip */
.tooltip-shell {
  width: min(470px, calc(100vw - 64px));
  max-height: min(700px, calc(100vh - 360px));
  overflow-x: hidden;
  overflow-y: auto;
  color: #e9f1f7;
  pointer-events: auto;
  overscroll-behavior: contain;
  scrollbar-color: rgba(39, 215, 232, 0.36) transparent;
  scrollbar-width: thin;
  white-space: normal;
}

.tooltip-shell::-webkit-scrollbar {
  width: 7px;
}

.tooltip-shell::-webkit-scrollbar-thumb {
  background: rgba(39, 215, 232, 0.34);
  border-radius: 999px;
}

.tooltip-head {
  position: sticky;
  z-index: 3;
  top: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 13px 15px 11px;
  background:
    linear-gradient(110deg, rgba(39, 215, 232, 0.14), rgba(192, 132, 255, 0.07)),
    rgba(8, 19, 29, 0.96);
  border-bottom: 1px solid rgba(129, 164, 185, 0.14);
  backdrop-filter: blur(18px);
}

.tooltip-head small {
  display: block;
  color: var(--muted);
  font-size: 9px;
  letter-spacing: 0.08em;
}

.tooltip-head strong {
  font-size: 16px;
}

.tooltip-head > div:last-child {
  text-align: right;
}

.tooltip-head > div:last-child span {
  display: block;
  color: var(--muted);
  font-size: 10px;
}

.tooltip-head > div:last-child b {
  font-size: 19px;
}

.tooltip-section {
  padding: 9px 15px 10px;
  border-bottom: 1px solid rgba(129, 164, 185, 0.11);
}

.tooltip-section:nth-of-type(2n) {
  background: rgba(255, 255, 255, 0.012);
}

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

.tooltip-section h4 {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 0 0 8px;
  color: #9df2f7;
  font-size: 10px;
  font-weight: 750;
  letter-spacing: 0.08em;
}

.tooltip-section h4::before {
  width: 3px;
  height: 11px;
  content: "";
  background: linear-gradient(180deg, var(--cyan), var(--purple));
  border-radius: 99px;
  box-shadow: 0 0 8px rgba(39, 215, 232, 0.4);
}

.tooltip-facts {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 5px;
}

.tooltip-facts > span {
  padding: 6px 8px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.032);
  border: 1px solid rgba(255, 255, 255, 0.045);
  border-radius: 7px;
  font-size: 9px;
}

.tooltip-facts b {
  float: right;
  color: #e9f1f7;
  font-size: 10px;
}

.tooltip-ignition {
  padding: 2px 6px;
  color: #061018;
  background: #00e676;
  border-radius: 999px;
  font-weight: 800;
}

.tooltip-support {
  display: grid;
  gap: 5px;
  margin-top: 8px;
}

.tooltip-support-row {
  display: grid;
  grid-template-columns: 102px minmax(0, 1fr);
  gap: 8px;
  align-items: center;
  padding: 5px 7px;
  background: rgba(255, 255, 255, 0.022);
  border: 1px solid rgba(255, 255, 255, 0.035);
  border-radius: 7px;
  font-size: 9px;
}

.tooltip-support-row span {
  color: #91a9b8;
}

.tooltip-support-row strong {
  color: #c8d9e4;
  font-weight: 500;
}

.tooltip-support-row.support-market {
  border-left: 2px solid #7da8c7;
}

.tooltip-support-row.support-flow {
  border-left: 2px solid #ff8a80;
}

.tooltip-support-row.support-active {
  border-left: 2px solid #55b9ff;
}

.tooltip-support-row.support-support {
  border-left: 2px solid #c084ff;
}

.tooltip-support-row.support-volume {
  border-left: 2px solid #e9c46a;
}

.tooltip-title {
  margin: 2px 0 5px;
  color: #f3f7fa;
  font-size: 14px;
  font-weight: 750;
}

.tooltip-summary {
  margin: 0;
  color: #b9cdd9;
  font-size: 10px;
  line-height: 1.5;
}

.tooltip-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-top: 7px;
}

.tooltip-pills span {
  padding: 2px 6px;
  color: #b9d8e5;
  background: rgba(85, 185, 255, 0.085);
  border: 1px solid rgba(85, 185, 255, 0.13);
  border-radius: 999px;
  font-size: 8px;
}

.tooltip-alert-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 5px;
}

.tooltip-alert {
  padding: 8px 9px;
  background: linear-gradient(120deg, rgba(255,255,255,.04), rgba(255,255,255,.018));
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-left-width: 3px;
  border-radius: 7px;
}

.tooltip-alert.tone-probe {
  border-left-color: #c084ff;
}

.tooltip-alert.tone-short {
  border-left-color: #ff6575;
}

.tooltip-alert.tone-lure {
  border-left-color: #ff9a55;
}

.tooltip-alert.tone-ignition {
  border-left-color: #00e676;
}

.tooltip-alert strong {
  display: block;
  margin-bottom: 2px;
  font-size: 10px;
}

.tooltip-alert p {
  margin: 0;
  color: var(--muted);
  font-size: 8px;
  line-height: 1.5;
}

.tooltip-empty {
  margin: 0;
  color: var(--muted);
  font-size: 9px;
}

.tooltip-history-list {
  display: grid;
  gap: 5px;
}

.tooltip-history-row {
  padding: 7px 8px;
  background: rgba(255, 255, 255, 0.026);
  border: 1px solid rgba(255, 255, 255, 0.04);
  border-radius: 8px;
}

.tooltip-history-head strong {
  font-size: 10px;
}

.tooltip-history-head span {
  color: var(--cyan);
  font-size: 9px;
}

.tooltip-history-meta {
  display: flex;
  gap: 7px;
  margin: 2px 0;
  font-size: 9px;
}

.tooltip-history-row p {
  margin: 0 0 3px;
  overflow: hidden;
  color: var(--muted);
  font-size: 8px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.tooltip-horizon {
  display: flex;
  gap: 8px;
  font-size: 8px;
}

.tooltip-horizon b {
  margin-left: 3px;
}

.tooltip-note {
  margin: 6px 0 0;
  color: #728b9a;
  font-size: 8px;
}

@media (max-width: 760px) {
  body[data-page="stock"] .stock-header {
    padding: 9px 10px 7px;
  }

  body[data-page="stock"] .stock-shell {
    padding: 8px 10px 16px;
  }

  body[data-page="stock"] .history-strip {
    overflow: hidden;
  }

  body[data-page="stock"] .recent-five {
    display: flex;
    overflow-x: auto;
    gap: 24px;
  }

  body[data-page="stock"] .history-card {
    flex: 0 0 218px;
  }

  body[data-page="stock"] .stock-chart {
    height: 640px;
    min-height: 600px;
  }

  .similar-cards {
    grid-template-columns: 1fr;
  }

  .similar-section-head {
    align-items: flex-start;
    flex-direction: column;
    gap: 3px;
  }

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

  .tooltip-support-row {
    grid-template-columns: 88px minmax(0, 1fr);
  }
}

/* Three-card day panel and mobile workspace */
body[data-page="stock"] .hologram-workspace {
  grid-template-columns: minmax(0, 1fr) 370px;
}

body[data-page="stock"] .hologram-workspace .chart-panel {
  background: #060e16;
  border-color: rgba(72, 118, 145, 0.2);
}

body[data-page="stock"] .day-panel {
  display: flex;
  flex-direction: column;
  gap: 6px;
  overflow-x: hidden;
  overflow-y: auto;
  padding: 8px;
  background: #0e1d2b;
  border: 1px solid rgba(56, 189, 248, 0.22);
  box-shadow:
    -14px 0 34px rgba(1, 8, 14, 0.3),
    0 18px 50px rgba(0, 0, 0, 0.24);
  scrollbar-color: rgba(56, 189, 248, 0.32) transparent;
  scrollbar-width: thin;
  overscroll-behavior: contain;
}

.day-card {
  flex: 0 0 auto;
  min-height: 0;
  overflow: visible;
  padding: 9px 10px;
  background:
    linear-gradient(145deg, rgba(19, 40, 56, 0.94), rgba(10, 25, 38, 0.96));
  border: 1px solid rgba(129, 164, 185, 0.13);
  border-radius: 13px;
}

.day-overview-card {
  background:
    radial-gradient(circle at 100% 0, rgba(39, 215, 232, 0.1), transparent 14rem),
    linear-gradient(145deg, rgba(20, 43, 60, 0.96), rgba(10, 26, 39, 0.97));
}

.day-card-top,
.panel-date-wrap,
.panel-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.panel-date-wrap {
  justify-content: flex-start;
}

.panel-latest {
  padding: 2px 7px;
  color: #031018;
  background: #7ff4ff;
  border-radius: 999px;
  font-size: 10px;
  font-style: normal;
  font-weight: 900;
}

.panel-title-row {
  margin: 6px 0 5px;
}

.panel-title-row h2 {
  margin: 0;
  color: #f3f8fb;
  font-size: 18px;
  line-height: 1.3;
}

.panel-title-row > strong {
  flex: 0 0 auto;
  font-size: 24px;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

.panel-summary {
  display: -webkit-box;
  margin: 0;
  overflow: hidden;
  color: #c3d4df;
  font-size: 12px;
  line-height: 1.5;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.day-card h3 {
  display: flex;
  align-items: center;
  gap: 6px;
  margin: 0 0 8px;
  color: #9ceef4;
  font-size: 12px;
  letter-spacing: 0.04em;
}

.day-card h3::before {
  width: 3px;
  height: 11px;
  content: "";
  background: linear-gradient(180deg, var(--cyan), var(--purple));
  border-radius: 999px;
}

.panel-quote-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 8px;
  margin-bottom: 5px;
  color: #8da7b7;
  font-size: 11.5px;
  font-variant-numeric: tabular-nums;
}

.panel-quote-strip b {
  color: #e6f0f5;
}

.panel-matrix {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 5px;
}

.matrix-cell {
  min-width: 0;
  padding: 6px 8px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 9px;
}

.matrix-cell small {
  display: block;
  margin-bottom: 2px;
  color: #8298a7;
  font-size: 11.5px;
}

.matrix-cell strong {
  display: block;
  color: #ecf5f9;
  font-size: 17px;
  font-variant-numeric: tabular-nums;
}

.matrix-cell p {
  margin: 2px 0 0;
  color: #8198a7;
  font-size: 11px;
  line-height: 1.45;
}

.day-alert-card .panel-alerts {
  max-height: 100%;
}

.day-alert-card .panel-alert {
  padding: 7px 9px;
}

.day-alert-card .panel-alert p {
  display: block;
}

}

.similar-card {
  display: flex;
  height: 100%;
  flex-direction: column;
}

.similar-cards {
  align-items: stretch;
}

.similar-card .after-grid {
  margin-top: auto;
}

@media (max-width: 960px) {
  body[data-page="stock"] .stock-header {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 1px 10px;
    padding: 4px 10px 3px;
  }

  body[data-page="stock"] .stock-header .header-main {
    grid-column: 1 / -1;
    min-height: 18px;
  }

  body[data-page="stock"] .stock-header .brand {
    gap: 7px;
    font-size: 14px;
  }

  body[data-page="stock"] .stock-header .brand-mark {
    width: 8px;
    height: 17px;
  }

  body[data-page="stock"] .stock-header .back-link {
    padding: 3px 7px;
    font-size: 10px;
  }

  body[data-page="stock"] .stock-title-row {
    grid-column: 1;
    margin: 0;
  }

  body[data-page="stock"] .stock-title-row h1 {
    font-size: 22px;
    line-height: 1.15;
  }

  body[data-page="stock"] .stock-code {
    margin-bottom: 0;
    font-size: 9px;
  }

  body[data-page="stock"] .price-block {
    grid-column: 2;
    grid-row: 2;
  }

  body[data-page="stock"] .price-block strong {
    font-size: 22px;
  }

  body[data-page="stock"] .price-block span {
    font-size: 11px;
  }

  body[data-page="stock"] .stock-meta {
    display: none;
  }

  body[data-page="stock"] .stock-meta span {
    padding: 1px 6px;
  }

  body[data-page="stock"] .stock-shell {
    padding: 6px 10px 14px;
  }

  body[data-page="stock"] .history-strip {
    padding: 8px;
  }

  body[data-page="stock"] .recent-five {
    display: flex;
    gap: 9px;
    overflow-x: auto;
    padding-bottom: 4px;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }

  body[data-page="stock"] .recent-five::-webkit-scrollbar {
    display: none;
  }

  body[data-page="stock"] .history-card {
    flex: 0 0 clamp(62vw, 220px, 220px);
    min-height: 112px;
    scroll-snap-align: end;
  }

  body[data-page="stock"] .hologram-workspace {
    display: flex;
    height: auto;
    flex-direction: column;
  }

  body[data-page="stock"] .hologram-workspace .chart-panel {
    flex: none;
    height: 420px;
    min-height: 390px;
  }

  body[data-page="stock"] .hologram-workspace .stock-chart {
    height: auto;
    min-height: 0;
  }

  body[data-page="stock"] .day-panel {
    display: flex;
    height: auto;
    overflow: visible;
    flex-direction: column;
  }

  .day-card {
    overflow: visible;
  }

  .panel-summary {
    -webkit-line-clamp: unset;
  }

  .similar-cards {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }

  .similar-cards::-webkit-scrollbar {
    display: none;
  }

  body[data-page="stock"] .similar-card {
    flex: 0 0 84vw;
    scroll-snap-align: start;
  }
}

@media (min-width: 1100px) {
  body[data-page="stock"] .hologram-workspace {
    height: calc(100vh - 370px);
    min-height: 520px;
  }
}

@media (max-width: 760px) {
  .overview-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .search-input-wrap input {
    font-size: 16px;
  }

  .tab-list {
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }

  .tab-list::-webkit-scrollbar {
    display: none;
  }

  .radar-row {
    min-height: 54px;
  }
}

@media (max-width: 768px) {
  body[data-page="stock"] .recent-five {
    display: flex;
    flex-direction: column;
    gap: 6px;
    overflow: visible;
    padding-bottom: 0;
    scroll-snap-type: none;
    scrollbar-width: none;
  }

  body[data-page="stock"] .history-card {
    display: grid;
    width: 100%;
    height: auto;
    min-height: 0;
    flex: none;
    grid-template-columns: auto minmax(0, 1fr) auto;
    grid-template-rows: auto auto;
    gap: 2px 10px;
    align-content: center;
    align-items: center;
    padding: 9px 11px;
    scroll-snap-align: none;
  }

  body[data-page="stock"] .history-topline {
    display: contents;
  }

  body[data-page="stock"] .history-date-wrap {
    grid-column: 1;
    grid-row: 1 / span 2;
  }

  body[data-page="stock"] .history-date {
    min-height: 24px;
    padding: 1px 7px;
    font-size: 15px;
  }

  body[data-page="stock"] .latest-badge {
    padding: 2px 6px;
    font-size: 10px;
  }

  body[data-page="stock"] .history-mobile-signal {
    display: inline-grid;
    width: 19px;
    height: 19px;
    place-items: center;
    color: #071019;
    background: var(--cyan);
    border-radius: 50%;
    font-size: 11px;
    font-style: normal;
    font-weight: 900;
  }

  body[data-page="stock"] .history-mobile-signal.signal-probe {
    background: var(--purple);
  }

  body[data-page="stock"] .history-mobile-signal.signal-short {
    color: #fff;
    background: var(--red);
  }

  body[data-page="stock"] .history-mobile-signal.signal-lure {
    background: var(--orange);
  }

  body[data-page="stock"] .history-mobile-signal.signal-ignition {
    background: #69f0ae;
  }

  body[data-page="stock"] .history-topline > strong {
    grid-column: 3;
    grid-row: 1 / span 2;
    align-self: center;
    font-size: 15px;
  }

  body[data-page="stock"] .history-body {
    grid-column: 2;
    grid-row: 1;
    padding: 0;
  }

  body[data-page="stock"] .history-title {
    font-size: 14px;
  }

  body[data-page="stock"] .history-clue {
    display: none;
  }

  body[data-page="stock"] .story-pills {
    grid-column: 2;
    grid-row: 2;
    flex-wrap: nowrap;
    margin-top: 2px;
    overflow: hidden;
  }

  body[data-page="stock"] .story-pill.signal-probe,
  body[data-page="stock"] .story-pill.signal-short,
  body[data-page="stock"] .story-pill.signal-lure,
  body[data-page="stock"] .story-pill.signal-ignition,
  body[data-page="stock"] .story-pill:nth-child(n + 2) {
    display: none;
  }

  body[data-page="stock"] .story-pill {
    font-size: 10px;
  }
}

/* L1/L2 micro-observation workbench. */
@media (min-width: 1100px) {
  body[data-page="stock"] .hologram-workspace {
    grid-template-columns: minmax(0, 1fr) 430px;
    height: calc(100vh - 250px);
    min-height: 620px;
  }
}

body[data-page="stock"] .day-panel {
  gap: 8px;
  padding: 8px;
  background:
    radial-gradient(circle at 92% 3%, rgba(39, 215, 232, 0.08), transparent 15rem),
    linear-gradient(165deg, #102334 0%, #0b1926 58%, #091521 100%);
}

.quant-module-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 7px;
}

.quant-module-head span {
  display: block;
  margin-bottom: 2px;
  color: #59d7e4;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.14em;
}

.quant-module-head h3 {
  margin: 0;
  color: #edf7fb;
  font-size: 13.5px;
  line-height: 1.2;
}

.quant-module-head > i {
  flex: 0 0 auto;
  padding: 2px 6px;
  color: #82a2b5;
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid rgba(148, 176, 198, 0.13);
  border-radius: 999px;
  font-size: 9.5px;
  font-style: normal;
}

.quant-funding-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 7px;
}

.quant-funding-cell {
  min-width: 0;
  min-height: 92px;
  padding: 8px 9px;
  background:
    linear-gradient(145deg, rgba(52, 106, 132, 0.12), rgba(255, 255, 255, 0.018));
  border: 1px solid rgba(111, 159, 183, 0.14);
  border-radius: 9px;
}

.quant-funding-cell.metric-main {
  border-color: rgba(39, 215, 232, 0.22);
}

.quant-funding-cell.metric-active {
  border-color: rgba(85, 185, 255, 0.19);
}

.quant-funding-top {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
}

.quant-funding-top span {
  color: #9ab1c0;
  font-size: 10.5px;
  line-height: 1.25;
}

.quant-funding-top strong {
  flex: 0 0 auto;
  color: #eef8fb;
  font-size: 15.5px;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.quant-funding-detail {
  margin-top: 4px;
  color: #87a1b1;
  font-size: 9.8px;
  line-height: 1.35;
}

.quant-funding-cell p {
  margin: 5px 0 0;
  color: #c9d8e1;
  font-size: 10.5px;
  font-weight: 650;
  line-height: 1.35;
}

.quant-observation-card {
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.quant-observation-group + .quant-observation-group {
  padding-top: 7px;
  border-top: 1px solid rgba(148, 176, 198, 0.11);
}

.quant-group-title {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 5px;
}

.quant-group-title b {
  color: #dfeaf0;
  font-size: 11.5px;
}

.quant-group-title span {
  color: #718b9b;
  font-size: 9.5px;
}

.quant-observation-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
}

.quant-observation-item {
  min-width: 0;
  padding: 7px 8px;
  background: rgba(255, 255, 255, 0.024);
  border: 1px solid rgba(148, 176, 198, 0.105);
  border-radius: 8px;
}

.quant-observation-item.is-strong {
  background: rgba(39, 215, 232, 0.055);
  border-color: rgba(39, 215, 232, 0.21);
}

.quant-observation-item.is-safe {
  background: rgba(81, 214, 156, 0.05);
  border-color: rgba(81, 214, 156, 0.2);
}

.quant-observation-item.is-warning {
  background: rgba(255, 101, 117, 0.06);
  border-color: rgba(255, 101, 117, 0.24);
}

.quant-observation-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  align-items: baseline;
  gap: 5px;
}

.quant-observation-head span {
  overflow: hidden;
  color: #9fb5c3;
  font-size: 9.8px;
  line-height: 1.25;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.quant-observation-head strong {
  color: #edf7fb;
  font-size: 13px;
  font-variant-numeric: tabular-nums;
}

.quant-observation-head i {
  padding: 1px 4px;
  color: #a8bdc9;
  background: rgba(255, 255, 255, 0.045);
  border-radius: 999px;
  font-size: 8.5px;
  font-style: normal;
  white-space: nowrap;
}

.quant-observation-item.is-strong .quant-observation-head i {
  color: #7ceefa;
}

.quant-observation-item.is-safe .quant-observation-head i {
  color: #79e8b4;
}

.quant-observation-item.is-warning .quant-observation-head i {
  color: #ff99a4;
}

.quant-strength-track {
  height: 3px;
  margin: 5px 0 4px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.055);
  border-radius: 999px;
}

.quant-strength-track > span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, #3c7c94, #46d4e2);
  border-radius: inherit;
}

.quant-observation-item.is-warning .quant-strength-track > span {
  background: linear-gradient(90deg, #b45a69, #ff7787);
}

.quant-observation-item.is-safe .quant-strength-track > span {
  background: linear-gradient(90deg, #337c63, #62dfaa);
}

.quant-observation-item p {
  display: -webkit-box;
  min-height: 25px;
  margin: 0;
  overflow: hidden;
  color: #c5d5de;
  font-size: 9.6px;
  line-height: 1.3;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.quant-observation-item small {
  display: block;
  margin-top: 3px;
  overflow: hidden;
  color: #718b9b;
  font-size: 9px;
  line-height: 1.25;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.compact-empty {
  grid-column: 1 / -1;
  min-height: 70px;
}

@media (max-width: 768px) {
  body[data-page="stock"] .day-panel {
    gap: 7px;
    padding: 7px;
  }

  .quant-funding-grid,
  .quant-observation-grid {
    gap: 6px;
  }

  .quant-funding-cell {
    min-height: 88px;
    padding: 7px;
  }

  .quant-funding-top {
    align-items: flex-start;
    flex-direction: column;
    gap: 1px;
  }

  .quant-funding-top strong {
    font-size: 15px;
  }

  .quant-observation-item {
    padding: 7px;
  }

  .quant-observation-head {
    grid-template-columns: minmax(0, 1fr) auto;
  }

  .quant-observation-head i {
    grid-column: 1 / -1;
    justify-self: start;
  }
}

@media (min-width: 769px) {
  body[data-page="stock"] .history-strip {
    padding: 8px 12px;
    margin-bottom: 8px;
  }

  body[data-page="stock"] .history-strip .section-heading {
    margin-bottom: 6px;
  }

  body[data-page="stock"] .recent-five {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    align-items: stretch;
    gap: 10px;
    overflow: visible;
    padding: 3px 2px 4px;
    margin: -3px -2px 0;
  }

  body[data-page="stock"] .history-card {
    display: flex;
    height: 100%;
    min-height: 0;
    flex-direction: column;
    gap: 4px;
    justify-content: flex-start;
    padding: 8px 11px;
  }

  body[data-page="stock"] .history-date {
    min-height: 0;
    padding: 0;
    color: #f3f8fb;
    background: transparent;
    border: 0;
    border-radius: 0;
    font-size: 15px;
  }

  body[data-page="stock"] .latest-badge {
    padding: 1px 5px;
    font-size: 9px;
  }

  body[data-page="stock"] .history-topline strong {
    font-size: 15px;
  }

  body[data-page="stock"] .history-body {
    gap: 1px;
    padding: 1px 0;
  }

  body[data-page="stock"] .history-title {
    font-size: 13.5px;
  }

  body[data-page="stock"] .history-clue {
    font-size: 11px;
  }

  body[data-page="stock"] .story-pills {
    gap: 3px;
    margin-top: auto;
    padding-top: 2px;
  }

  body[data-page="stock"] .story-pill {
    padding: 1px 6px;
    font-size: 10px;
  }
}

/* Final high-density panel overrides. */
@media (min-width: 1100px) {
  body[data-page="stock"] .hologram-workspace {
    grid-template-columns: minmax(0, 1fr) 440px;
    height: calc(100vh - 250px);
    min-height: 620px;
  }
}

.quant-funding-top span {
  font-size: 11px;
}

.quant-funding-detail {
  font-size: 10.1px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.quant-funding-cell p {
  font-size: 10.8px;
}

.quant-guide {
  margin: -1px 0 7px;
  color: #7f98a8;
  font-size: 9.8px;
  line-height: 1.45;
}

.quant-observation-head span {
  font-size: 10.2px;
}

.quant-observation-head strong {
  font-size: 13.5px;
}

.quant-observation-item p {
  font-size: 10.1px;
}

.quant-observation-item small {
  font-size: 9.5px;
}

@media (max-width: 768px) {
  body[data-page="stock"] .history-strip {
    padding: 7px 12px;
    margin-bottom: 8px;
  }

  body[data-page="stock"] .history-strip .section-heading {
    margin-bottom: 5px;
  }

  body[data-page="stock"] .recent-five {
    flex-direction: column;
    gap: 5px;
    overflow: visible;
    padding: 2px 0 3px;
    margin: 0;
  }

  body[data-page="stock"] .history-card {
    width: 100%;
    height: auto;
    min-height: 0;
    flex: 0 0 auto;
    padding: 6px 9px;
  }

  body[data-page="stock"] .history-date {
    font-size: 14.5px;
  }

  body[data-page="stock"] .history-topline strong {
    font-size: 14.5px;
  }

  body[data-page="stock"] .history-title {
    font-size: 13.5px;
  }

  body[data-page="stock"] .story-pill {
    padding: 1px 5px;
    font-size: 9.5px;
  }
}

@media (min-width: 769px) {
  body[data-page="stock"] .history-card {
    gap: 4px;
    padding: 5px 10px;
  }

  body[data-page="stock"] .history-body {
    gap: 0;
    padding: 0;
  }

  body[data-page="stock"] .history-title {
    font-size: 13px;
    line-height: 1.2;
  }

  body[data-page="stock"] .history-clue {
    font-size: 11px;
    line-height: 1.15;
  }

  body[data-page="stock"] .story-pills {
    padding-top: 0;
  }
}

@media (min-width: 1100px) {
  body[data-page="stock"] .hologram-workspace {
    height: calc(100vh - 325px);
    min-height: 540px;
  }
}

/* Professional dual-pane workspace */
.hologram-workspace {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 10px;
  min-height: 600px;
  height: calc(100vh - 235px);
  margin-bottom: 10px;
}

.hologram-workspace .chart-panel {
  display: flex;
  min-width: 0;
  min-height: 0;
  margin: 0;
  flex-direction: column;
}

body[data-page="stock"] .hologram-workspace .stock-chart {
  flex: 1 1 auto;
  height: auto;
  min-height: 0;
}

.day-panel {
  height: 100%;
  min-height: 0;
  overflow-x: hidden;
  overflow-y: auto;
  padding: 0 15px 15px;
  background:
    radial-gradient(circle at 100% 0, rgba(39, 215, 232, 0.095), transparent 18rem),
    linear-gradient(160deg, rgba(15, 33, 46, 0.97), rgba(7, 18, 28, 0.98));
  border: 1px solid rgba(129, 164, 185, 0.18);
  border-radius: 16px;
  box-shadow: var(--shadow);
  scrollbar-color: rgba(39, 215, 232, 0.34) transparent;
  scrollbar-width: thin;
}

.day-panel-head {
  position: sticky;
  z-index: 4;
  top: 0;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin: 0 -15px;
  padding: 14px 15px 12px;
  background:
    linear-gradient(120deg, rgba(39, 215, 232, 0.13), rgba(192, 132, 255, 0.06)),
    rgba(9, 21, 31, 0.97);
  border-bottom: 1px solid rgba(129, 164, 185, 0.14);
  backdrop-filter: blur(14px);
}

.day-panel-head h2 {
  margin: 3px 0 0;
  font-size: 16px;
}

.panel-date {
  color: var(--cyan);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.panel-date i {
  display: inline-flex;
  margin-left: 6px;
  padding: 1px 6px;
  color: #06121b;
  background: var(--cyan);
  border-radius: 999px;
  font-size: 9px;
  font-style: normal;
}

.latest-day-button {
  flex: 0 0 auto;
  padding: 6px 9px;
  color: #aee8ef;
  background: rgba(39, 215, 232, 0.08);
  border: 1px solid rgba(39, 215, 232, 0.22);
  border-radius: 999px;
  cursor: pointer;
  font-size: 10px;
}

.latest-day-button:disabled {
  opacity: 0.35;
  cursor: default;
}

.panel-quote {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  padding: 13px 0 11px;
  border-bottom: 1px solid rgba(129, 164, 185, 0.12);
}

.panel-quote strong {
  font-size: 28px;
  line-height: 1;
  font-variant-numeric: tabular-nums;
}

.panel-quote span {
  color: var(--muted);
  font-size: 12px;
}

.panel-block {
  padding: 13px 0 3px;
}

.panel-block + .panel-block {
  border-top: 1px solid rgba(129, 164, 185, 0.12);
}

.panel-block h3 {
  display: flex;
  align-items: center;
  gap: 7px;
  margin: 0 0 9px;
  color: #a7f0f4;
  font-size: 11px;
  letter-spacing: 0.05em;
}

.panel-block h3::before {
  width: 3px;
  height: 12px;
  content: "";
  background: linear-gradient(180deg, var(--cyan), var(--purple));
  border-radius: 99px;
}

.panel-facts {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 5px;
}

.panel-facts span {
  padding: 8px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.033);
  border: 1px solid rgba(255, 255, 255, 0.045);
  border-radius: 8px;
  font-size: 12px;
}

.panel-facts b {
  float: right;
  color: var(--text);
  font-size: 13px;
  font-variant-numeric: tabular-nums;
}

.panel-support {
  display: grid;
  gap: 5px;
  margin-top: 8px;
}

.panel-support-row {
  padding: 8px 9px;
  background: rgba(255, 255, 255, 0.025);
  border: 1px solid rgba(255, 255, 255, 0.04);
  border-left: 3px solid #7d95a5;
  border-radius: 8px;
}

.panel-support-row span {
  display: block;
  margin-bottom: 3px;
  color: var(--muted);
  font-size: 11px;
}

.panel-support-row p {
  margin: 0;
  color: #d0dfe8;
  font-size: 12px;
  line-height: 1.55;
}

.panel-support-row.support-flow {
  border-left-color: #ff8a80;
}

.panel-support-row.support-active {
  border-left-color: #55b9ff;
}

.panel-support-row.support-support {
  border-left-color: #c084ff;
}

.panel-support-row.support-volume {
  border-left-color: #e9c46a;
}

.panel-block h4 {
  margin: 0 0 6px;
  font-size: 16px;
}

.panel-block > p {
  margin: 0;
  color: #bed0db;
  font-size: 13px;
  line-height: 1.7;
}

.panel-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 9px;
}

.panel-pills span {
  padding: 4px 7px;
  color: #b9d9e7;
  background: rgba(85, 185, 255, 0.09);
  border: 1px solid rgba(85, 185, 255, 0.14);
  border-radius: 999px;
  font-size: 11px;
}

.panel-alerts {
  display: grid;
  gap: 6px;
}

.panel-alert {
  padding: 9px 10px;
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-left: 3px solid #8da3b3;
  border-radius: 8px;
}

.panel-alert.alert-probe {
  border-left-color: var(--purple);
}

.panel-alert.alert-short {
  border-left-color: var(--red);
}

.panel-alert.alert-lure {
  border-left-color: var(--orange);
}

.panel-alert.alert-ignition {
  border-left-color: #00e676;
}

.panel-alert strong {
  display: block;
  margin-bottom: 3px;
  font-size: 12px;
}

.panel-alert p,
.panel-empty {
  margin: 0;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.6;
}

/* Compact chart-only tooltip */
.chart-light-tooltip {
  width: 306px;
  padding: 10px 12px;
  box-sizing: border-box;
  color: #e9f1f7;
  font-size: 12px;
}

.light-tooltip-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 7px;
  font-size: 12px;
}

.light-tooltip-head strong {
  font-size: 13px;
}

.light-tooltip-date {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 7px;
  padding-bottom: 6px;
  border-bottom: 1px solid rgba(129, 164, 185, 0.13);
}

.light-tooltip-date span {
  color: var(--muted);
  font-size: 10px;
  letter-spacing: 0.05em;
}

.light-tooltip-date strong {
  color: #eff8fc;
  font-size: 14px;
  font-variant-numeric: tabular-nums;
}

.light-tooltip-metrics {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-bottom: 8px;
}

.light-tooltip-metrics span {
  padding: 4px 7px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.035);
  border: 1px solid rgba(255, 255, 255, 0.045);
  border-radius: 6px;
  font-size: 11px;
}

.light-tooltip-metrics b {
  margin-left: 3px;
  color: #edf4f7;
  font-variant-numeric: tabular-nums;
}

.light-tooltip-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 4px;
}

.light-tooltip-grid span {
  padding: 4px 6px;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.035);
  border-radius: 5px;
}

.light-tooltip-grid b {
  float: right;
  color: var(--text);
}

.light-tooltip-summary {
  margin-bottom: 7px;
  color: #e6f0f5;
  font-size: 14px;
  font-weight: 750;
}

.light-tooltip-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-top: 5px;
}

.light-tooltip-badges:empty {
  display: none;
}

.light-tooltip-badges span {
  padding: 2px 5px;
  color: #b7d5e3;
  background: rgba(85, 185, 255, 0.09);
  border-radius: 999px;
  font-size: 10px;
}

.light-tooltip-special {
  display: grid;
  gap: 5px;
  margin-top: 8px;
}

.light-special-alert {
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr);
  gap: 7px;
  align-items: center;
  padding: 10px 12px;
  background: rgba(255, 255, 255, 0.045);
  border: 1px solid rgba(255, 255, 255, 0.09);
  border-radius: 9px;
}

.special-icon {
  display: grid;
  width: 27px;
  height: 27px;
  place-items: center;
  color: #06131d;
  background: var(--cyan);
  border-radius: 50%;
  font-size: 15px;
  font-weight: 900;
  box-shadow: 0 0 12px rgba(39, 215, 232, 0.45);
}

.light-special-alert strong {
  display: block;
  font-size: 11px;
}

.light-special-alert p {
  display: -webkit-box;
  margin: 2px 0 0;
  overflow: hidden;
  color: #9fb5c2;
  font-size: 10px;
  line-height: 1.45;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.rank-index {
  display: inline-grid;
  width: 28px;
  height: 24px;
  place-items: center;
  color: var(--cyan);
  background: rgba(39, 215, 232, 0.08);
  border: 1px solid rgba(39, 215, 232, 0.2);
  border-radius: 7px;
  font-size: 11px;
  font-weight: 800;
}

.gene-card-title {
  color: #dce9f0 !important;
  font-size: 13px !important;
}

.similar-header time {
  margin-left: auto;
  color: #d7e5ed;
  font-size: 15px;
  font-weight: 750;
  font-variant-numeric: tabular-nums;
}

.gene-score-wrap {
  display: grid;
  place-items: center;
  padding: 12px 0 8px;
}

.gene-score-ring {
  position: relative;
  display: grid;
  width: 94px;
  height: 94px;
  place-items: center;
  background:
    conic-gradient(
      from -90deg,
      #27d7e8 calc(var(--score) * 1%),
      rgba(255, 255, 255, 0.065) 0
    );
  border-radius: 50%;
  box-shadow: 0 0 24px rgba(39, 215, 232, 0.13);
}

.gene-score-ring::before {
  position: absolute;
  inset: 7px;
  content: "";
  background: #0a1a25;
  border: 1px solid rgba(255, 255, 255, 0.055);
  border-radius: 50%;
}

.gene-score-ring > div {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: baseline;
  color: #f2fbfd;
  font-variant-numeric: tabular-nums;
}

.gene-score-ring strong {
  font-size: 28px;
  line-height: 1;
}

.gene-score-ring small {
  margin-left: 2px;
  color: var(--cyan);
  font-size: 12px;
  font-weight: 750;
}

.gene-data-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 3px 0 6px;
  color: var(--muted);
  font-size: 10px;
}

.gene-data-head b {
  color: #a9c3d1;
  font-weight: 600;
}

.gene-data-list {
  display: grid;
  grid-template-rows: repeat(3, minmax(0, 1fr));
  gap: 4px;
  height: 86px;
  margin-bottom: 11px;
}

.gene-data-list span {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 5px 7px;
  color: #bcd5e2;
  background: rgba(39, 215, 232, 0.045);
  border: 1px solid rgba(39, 215, 232, 0.08);
  border-radius: 7px;
  font-size: 11px;
  line-height: 1.35;
  overflow: hidden;
}

.gene-data-list i {
  display: inline-grid;
  flex: 0 0 15px;
  width: 15px;
  height: 15px;
  place-items: center;
  color: #06131c;
  background: var(--cyan);
  border-radius: 50%;
  font-size: 9px;
  font-style: normal;
  font-weight: 900;
  white-space: nowrap;
}

.light-special-alert.special-probe {
  background: linear-gradient(120deg, rgba(192, 132, 255, 0.15), rgba(85, 185, 255, 0.04));
  border-color: rgba(192, 132, 255, 0.35);
}

.light-special-alert.special-probe .special-icon {
  background: var(--purple);
  box-shadow: 0 0 16px rgba(192, 132, 255, 0.7);
}

.light-special-alert.special-short {
  background: linear-gradient(120deg, rgba(255, 101, 117, 0.15), rgba(255, 101, 117, 0.035));
  border-color: rgba(255, 101, 117, 0.34);
}

.light-special-alert.special-short .special-icon {
  color: #fff;
  background: var(--red);
  box-shadow: 0 0 16px rgba(255, 101, 117, 0.65);
}

.light-special-alert.special-lure {
  background: linear-gradient(120deg, rgba(255, 154, 85, 0.15), rgba(255, 154, 85, 0.035));
  border-color: rgba(255, 154, 85, 0.34);
}

.light-special-alert.special-lure .special-icon {
  color: #1b0b00;
  background: var(--orange);
  box-shadow: 0 0 16px rgba(255, 154, 85, 0.65);
}

.light-special-alert.special-ignition {
  background: linear-gradient(120deg, rgba(0, 230, 118, 0.15), rgba(255, 215, 0, 0.055));
  border-color: rgba(0, 230, 118, 0.36);
}

.light-special-alert.special-ignition .special-icon {
  color: #02140a;
  background: #69f0ae;
  box-shadow: 0 0 18px rgba(0, 230, 118, 0.75);
}

.light-special-alert.special-tier-ignition_refuel {
  background: linear-gradient(120deg, rgba(255, 215, 0, 0.15), rgba(255, 161, 0, 0.04));
  border-color: rgba(255, 193, 7, 0.38);
}

.light-special-alert.special-tier-ignition_refuel .special-icon {
  background: #ffe57f;
  box-shadow: 0 0 18px rgba(255, 193, 7, 0.72);
}

body[data-page="stock"] .recent-five {
  gap: 10px;
}

body[data-page="stock"] .history-card {
  min-height: 112px;
  padding: 10px 11px;
}

.history-topline > span {
  font-size: 16px;
  line-height: 1.15;
}

.latest-badge {
  padding: 3px 7px;
  color: #031018;
  background: #7ff4ff;
  border: 1px solid #c9fbff;
  border-radius: 999px;
  box-shadow: 0 0 12px rgba(39, 215, 232, 0.55);
  font-size: 11px;
  font-style: normal;
  font-weight: 900;
}

body[data-page="stock"] .history-card.is-latest {
  border-color: rgba(93, 232, 244, 0.82);
  box-shadow:
    inset 0 0 0 1px rgba(93, 232, 244, 0.76),
    0 0 0 2px rgba(39, 215, 232, 0.11),
    0 0 24px rgba(39, 215, 232, 0.12);
}

.history-topline strong {
  color: inherit;
  font-size: 16px;
  font-weight: 800;
}

.history-title {
  margin: 0;
  color: #f1f7fa;
  font-size: 15px;
  font-weight: 800;
  line-height: 1.35;
}

.history-body {
  display: flex;
  min-width: 0;
  flex-direction: column;
  gap: 3px;
  padding: 8px 0 7px;
}

.history-clue {
  overflow: hidden;
  color: #8da3b3;
  font-size: 11px;
  line-height: 1.35;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.history-metrics {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 11px;
  font-weight: 650;
}

.history-metrics i {
  display: inline-flex;
  align-items: baseline;
  gap: 3px;
  font-style: normal;
}

.history-metrics small {
  color: #d6bd78;
  font-size: 10px;
}

.history-metrics b {
  color: #e9c46a;
  font-size: 11px;
  font-variant-numeric: tabular-nums;
}

.history-metrics i:last-child b {
  color: #edf4f7;
}

.history-metrics i:last-child {
  color: #e9c46a;
}

.story-pill {
  font-size: 11px;
}

.story-pill.signal-probe,
.story-pill.signal-short,
.story-pill.signal-lure,
.story-pill.signal-ignition {
  color: #e8f7ff;
  background: rgba(85, 185, 255, 0.12);
  border-color: rgba(85, 185, 255, 0.32);
}

.story-pill.signal-probe {
  background: rgba(192, 132, 255, 0.13);
  border-color: rgba(192, 132, 255, 0.36);
}

.story-pill.signal-short {
  background: rgba(255, 101, 117, 0.13);
  border-color: rgba(255, 101, 117, 0.34);
}

.story-pill.signal-lure {
  background: rgba(255, 154, 85, 0.13);
  border-color: rgba(255, 154, 85, 0.34);
}

.story-pill.signal-ignition {
  background: rgba(0, 230, 118, 0.11);
  border-color: rgba(0, 230, 118, 0.3);
}

.story-pill.neutral-badge {
  color: #8499a7;
  background: rgba(132, 153, 167, 0.07);
  border-color: rgba(132, 153, 167, 0.13);
}

.after-cell.after-up {
  background: rgba(255, 101, 117, 0.085);
  border-color: rgba(255, 101, 117, 0.13);
}

.after-cell.after-down {
  background: rgba(81, 214, 156, 0.08);
  border-color: rgba(81, 214, 156, 0.13);
}

@media (max-width: 1099px) {
  .hologram-workspace {
    grid-template-columns: minmax(0, 1fr);
    height: auto;
    min-height: 0;
  }

  .hologram-workspace .chart-panel {
    height: calc(100vh - 235px);
    min-height: 600px;
  }

  .day-panel {
    height: auto;
    max-height: none;
  }
}

@media (max-width: 760px) {
  .hologram-workspace .chart-panel {
    height: 640px;
    min-height: 600px;
  }

  body[data-page="stock"] .recent-five {
    gap: 10px;
  }

  body[data-page="stock"] .history-card {
    height: auto;
    min-height: 0;
    flex: 0 0 auto;
    padding: 7px 10px;
  }

  body[data-page="stock"] .hologram-workspace .stock-chart {
    height: auto;
    min-height: 0;
  }
}

/* Final intent-strip density and day-panel typography overrides. */
body[data-page="stock"] .history-strip {
  padding: 8px 12px;
  margin-bottom: 8px;
}

body[data-page="stock"] .history-strip .section-heading {
  margin-bottom: 6px;
}

body[data-page="stock"] .recent-five {
  gap: 10px;
  padding: 3px 2px 4px;
  margin: -3px -2px 0;
}

body[data-page="stock"] .history-card {
  display: flex;
  height: 100%;
  min-height: 0;
  flex-direction: column;
  gap: 4px;
  justify-content: flex-start;
  padding: 8px 11px;
}

body[data-page="stock"] .history-date {
  min-height: 0;
  padding: 0;
  color: #f3f8fb;
  background: transparent;
  border: 0;
  border-radius: 0;
  font-size: 15px;
}

body[data-page="stock"] .latest-badge {
  padding: 1px 5px;
  font-size: 9px;
}

body[data-page="stock"] .history-topline strong {
  font-size: 15px;
}

body[data-page="stock"] .history-body {
  gap: 1px;
  padding: 1px 0;
}

body[data-page="stock"] .history-title {
  font-size: 13.5px;
}

body[data-page="stock"] .story-pills {
  gap: 3px;
  margin-top: auto;
  padding-top: 2px;
}

body[data-page="stock"] .story-pill {
  padding: 1px 6px;
  font-size: 10px;
}

body[data-page="stock"] .day-panel {
  gap: 6px;
  padding: 8px;
  overflow-x: hidden;
  overflow-y: auto;
}

body[data-page="stock"] .day-card {
  flex: 0 0 auto;
  padding: 9px 10px;
  overflow: visible;
}

.panel-summary {
  overflow: hidden;
  font-size: 12px;
  line-height: 1.5;
  -webkit-line-clamp: 2;
}

.panel-title-row {
  margin: 6px 0 5px;
}

.day-card h3 {
  font-size: 12px;
}

.panel-quote-strip {
  margin-bottom: 5px;
  font-size: 11.5px;
}

.panel-matrix {
  gap: 5px;
}

.matrix-cell {
  padding: 6px 8px;
}

.matrix-cell small {
  font-size: 11.5px;
}

.matrix-cell strong {
  font-size: 17px;
}

.matrix-cell p {
  overflow: visible;
  font-size: 11px;
  line-height: 1.45;
  white-space: normal;
}

@media (min-width: 1100px) {
  body[data-page="stock"] .hologram-workspace {
    align-items: stretch;
    height: calc(100vh - 350px);
    min-height: 540px;
  }
}

@media (max-width: 768px) {
  body[data-page="stock"] .recent-five {
    display: flex;
    flex-direction: column;
    gap: 5px;
    overflow: visible;
    padding: 2px 0 3px;
    margin: 0;
    scroll-snap-type: none;
  }

  body[data-page="stock"] .history-card {
    display: grid;
    width: 100%;
    height: auto;
    min-height: 0;
    flex: 0 0 auto;
    grid-template-columns: auto minmax(0, 1fr) auto;
    grid-template-rows: auto auto;
    gap: 2px 10px;
    align-items: center;
    padding: 6px 9px;
    scroll-snap-align: none;
  }

  body[data-page="stock"] .history-topline {
    display: contents;
  }

  body[data-page="stock"] .history-date-wrap {
    grid-column: 1;
    grid-row: 1 / span 2;
  }

  body[data-page="stock"] .history-date {
    font-size: 14.5px;
  }

  body[data-page="stock"] .latest-badge {
    padding: 1px 5px;
    font-size: 9px;
  }

  body[data-page="stock"] .history-topline > strong {
    grid-column: 3;
    grid-row: 1 / span 2;
    align-self: center;
    font-size: 14.5px;
  }

  body[data-page="stock"] .history-body {
    grid-column: 2;
    grid-row: 1;
    padding: 0;
  }

  body[data-page="stock"] .history-title {
    font-size: 13.5px;
  }

  body[data-page="stock"] .history-clue {
    display: none;
  }

  body[data-page="stock"] .story-pills {
    grid-column: 2;
    grid-row: 2;
    flex-wrap: nowrap;
    margin-top: 0;
    overflow: hidden;
    padding-top: 0;
  }

  body[data-page="stock"] .story-pill.signal-probe,
  body[data-page="stock"] .story-pill.signal-short,
  body[data-page="stock"] .story-pill.signal-lure,
  body[data-page="stock"] .story-pill.signal-ignition,
  body[data-page="stock"] .story-pill:nth-child(n + 2) {
    display: none;
  }

  body[data-page="stock"] .story-pill {
    padding: 1px 5px;
    font-size: 9.5px;
  }
}

@media (min-width: 769px) {
  body[data-page="stock"] .history-card {
    gap: 4px;
    padding: 5px 10px;
  }

  body[data-page="stock"] .history-body {
    gap: 0;
    padding: 0;
  }

  body[data-page="stock"] .history-title {
    font-size: 13px;
    line-height: 1.2;
  }

  body[data-page="stock"] .history-clue {
    font-size: 11px;
    line-height: 1.15;
  }

  body[data-page="stock"] .story-pills {
    padding-top: 0;
  }
}

@media (min-width: 1100px) {
  body[data-page="stock"] .hologram-workspace {
    grid-template-columns: minmax(0, 1fr) 440px;
    height: calc(100vh - 250px);
    min-height: 620px;
  }
}

.panel-matrix {
  grid-template-columns: 1fr;
  gap: 8px;
}

.matrix-cell {
  padding: 9px 12px;
}

.matrix-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.matrix-cell small {
  margin: 0;
  font-size: 12px;
}

.matrix-cell strong {
  font-size: 17px;
  white-space: nowrap;
}

.matrix-detail {
  margin: 4px 0 0;
  color: #91a7b5;
  font-size: 11.5px;
  line-height: 1.45;
  white-space: normal;
}

@media (min-width: 769px) {
  body[data-page="stock"] .history-strip {
    padding: 8px 12px;
    margin-bottom: 8px;
  }

  body[data-page="stock"] .history-strip .section-heading {
    margin-bottom: 6px;
  }

  body[data-page="stock"] .recent-five {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    align-items: stretch;
    gap: 10px;
    overflow: visible;
    padding: 2px 2px 3px;
    margin: -2px -2px 0;
  }

  body[data-page="stock"] .history-card {
    display: flex;
    height: 100%;
    min-height: 0;
    flex-direction: column;
    justify-content: flex-start;
    gap: 8px;
    padding: 10px 13px;
  }

  body[data-page="stock"] .history-date {
    min-height: 0;
    padding: 0;
    color: #f3f8fb;
    background: transparent;
    border: 0;
    border-radius: 0;
    font-size: 15.5px;
  }

  body[data-page="stock"] .latest-badge {
    padding: 1px 5px;
    font-size: 10px;
  }

  body[data-page="stock"] .history-topline strong {
    font-size: 15.5px;
  }

  body[data-page="stock"] .history-body {
    gap: 0;
    padding: 0;
  }

  body[data-page="stock"] .history-title {
    font-size: 15.5px;
    line-height: 1.35;
  }

  body[data-page="stock"] .history-clue {
    display: none;
  }

  body[data-page="stock"] .story-pills {
    gap: 6px;
    margin-top: auto;
    padding-top: 2px;
  }

  body[data-page="stock"] .story-pill {
    padding: 3px 8px;
    font-size: 11px;
  }
}

@media (max-width: 768px) {
  body[data-page="stock"] .history-strip {
    padding: 7px 12px;
    margin-bottom: 8px;
  }

  body[data-page="stock"] .history-strip .section-heading {
    margin-bottom: 5px;
  }

  body[data-page="stock"] .recent-five {
    display: flex;
    flex-direction: column;
    gap: 5px;
    overflow: visible;
    padding: 2px 0 3px;
    margin: 0;
    scroll-snap-type: none;
  }

  body[data-page="stock"] .history-card {
    display: grid;
    width: 100%;
    height: auto;
    min-height: 0;
    flex: 0 0 auto;
    grid-template-columns: auto minmax(0, 1fr) auto;
    grid-template-rows: auto auto;
    gap: 2px 10px;
    align-items: center;
    padding: 8px 11px;
    scroll-snap-align: none;
  }

  body[data-page="stock"] .history-topline {
    display: contents;
  }

  body[data-page="stock"] .history-date-wrap {
    grid-column: 1;
    grid-row: 1 / span 2;
  }

  body[data-page="stock"] .history-date {
    font-size: 15px;
  }

  body[data-page="stock"] .latest-badge {
    padding: 1px 5px;
    font-size: 9.5px;
  }

  body[data-page="stock"] .history-topline > strong {
    grid-column: 3;
    grid-row: 1 / span 2;
    align-self: center;
    font-size: 15px;
  }

  body[data-page="stock"] .history-body {
    grid-column: 2;
    grid-row: 1;
    padding: 0;
  }

  body[data-page="stock"] .history-title {
    font-size: 14.5px;
  }

  body[data-page="stock"] .history-clue {
    display: none;
  }

  body[data-page="stock"] .story-pills {
    grid-column: 2;
    grid-row: 2;
    flex-wrap: nowrap;
    margin-top: 0;
    overflow: hidden;
    padding-top: 0;
  }

  body[data-page="stock"] .story-pill.signal-probe,
  body[data-page="stock"] .story-pill.signal-short,
  body[data-page="stock"] .story-pill.signal-lure,
  body[data-page="stock"] .story-pill.signal-ignition,
  body[data-page="stock"] .story-pill:nth-child(n + 2) {
    display: none;
  }

  body[data-page="stock"] .story-pill {
    padding: 1px 6px;
    font-size: 10px;
  }
}
