:root {
  --bg: #f4f6f8;
  --panel: #ffffff;
  --ink: #18212f;
  --muted: #6d7888;
  --line: #dbe2ea;
  --red: #cf3434;
  --green: #16805a;
  --blue: #2563eb;
  --amber: #9a6700;
  --accent: #e6b450;
  --shadow: 0 10px 30px rgba(21, 35, 52, 0.08);
}

/* Company latest updates in the unified stock card. */
.company-updates-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 10px;
  color: #64748b;
  font-size: 12px;
}

.company-updates-meta strong { color: #0f766e; }

.company-updates-meta a,
.company-updates-list a {
  color: #1769aa;
  text-decoration: none;
}

.company-updates-list {
  display: grid;
  gap: 8px;
}

.company-updates-list article {
  display: grid;
  grid-template-columns: 88px minmax(0, 1fr) auto;
  gap: 10px;
  align-items: start;
  padding: 10px 12px;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  background: #f8fafc;
}

.company-updates-list time {
  color: #64748b;
  font-variant-numeric: tabular-nums;
}

.company-updates-list article strong { color: #1e3a5f; }

.company-updates-list article p {
  margin: 3px 0 0;
  color: #334155;
  line-height: 1.55;
  overflow-wrap: anywhere;
}

.company-updates-boundary {
  margin: 10px 0 0;
  color: #7c5a13;
  font-size: 12px;
  line-height: 1.5;
}

@media (max-width: 640px) {
  .company-updates-list article { grid-template-columns: 1fr auto; }
  .company-updates-list time { grid-column: 1 / -1; }
}

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

.quant-review-panel {
  padding: 20px;
  background:
    radial-gradient(circle at 92% 2%, rgba(44, 103, 190, 0.12), transparent 28%),
    linear-gradient(180deg, #f8fbff 0%, #f2f5f9 100%);
}

.quant-review-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 18px;
  padding: 18px 20px;
  border: 1px solid #d7e1ee;
  border-radius: 14px;
  background: #101827;
  color: #f8fafc;
  box-shadow: 0 12px 28px rgba(15, 23, 42, 0.12);
}

.quant-review-head span {
  color: #8fb8f7;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.06em;
}

.quant-review-head h2 {
  margin: 5px 0 4px;
  font-size: 28px;
}

.quant-review-head p {
  margin: 0;
  color: #b9c6d8;
  font-size: 13px;
}

.quant-review-head .quant-safety-badge {
  flex: 0 0 auto;
  padding: 8px 11px;
  border: 1px solid rgba(230, 180, 80, 0.55);
  border-radius: 999px;
  background: rgba(230, 180, 80, 0.12);
  color: #f3c866;
  letter-spacing: 0;
}

.quant-manual {
  margin: 0 0 16px;
  overflow: hidden;
  border: 1px solid #cfdbea;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.96);
}

.quant-manual summary {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 13px 16px;
  color: #20324b;
  cursor: pointer;
  list-style: none;
  user-select: none;
}

.quant-manual summary::-webkit-details-marker {
  display: none;
}

.quant-manual summary::after {
  content: "展开";
  margin-left: auto;
  padding: 4px 9px;
  border-radius: 999px;
  background: #edf4fd;
  color: #2462a8;
  font-size: 11px;
  font-weight: 800;
}

.quant-manual[open] summary::after {
  content: "收起";
}

.quant-manual summary span,
.quant-manual summary small {
  display: block;
}

.quant-manual summary span {
  font-size: 14px;
  font-weight: 900;
}

.quant-manual summary small {
  color: #718096;
  font-size: 11px;
}

.quant-manual-body {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  padding: 0 16px 16px;
  border-top: 1px solid #e3e9f1;
}

.quant-manual-body section {
  min-width: 0;
  margin-top: 14px;
  padding: 13px;
  border-radius: 9px;
  background: #f6f9fd;
  color: #4b5b71;
  font-size: 11px;
  line-height: 1.65;
}

.quant-manual-body h3 {
  margin: 0 0 8px;
  color: #1c3150;
  font-size: 13px;
}

.quant-manual-body p,
.quant-manual-body ol,
.quant-manual-body ul,
.quant-manual-body dl {
  margin: 0;
}

.quant-manual-body ol,
.quant-manual-body ul {
  padding-left: 18px;
}

.quant-manual-body li + li {
  margin-top: 5px;
}

.quant-manual-body dl {
  display: grid;
  gap: 7px;
}

.quant-manual-body dl div {
  display: grid;
  grid-template-columns: 78px minmax(0, 1fr);
  gap: 8px;
}

.quant-manual-body dt {
  color: #253d5f;
  font-weight: 900;
}

.quant-manual-body dd {
  margin: 0;
}

.quant-review-layout {
  display: grid;
  grid-template-columns: minmax(440px, 1.15fr) minmax(360px, 0.85fr);
  gap: 16px;
}

.quant-config-card,
.quant-rule-card,
.quant-result-card {
  border: 1px solid #dce4ee;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.95);
  box-shadow: 0 6px 18px rgba(15, 23, 42, 0.05);
}

.quant-config-card,
.quant-rule-card {
  padding: 16px;
}

.quant-card-title {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 14px;
}

.quant-card-title > span {
  display: grid;
  width: 30px;
  height: 30px;
  place-items: center;
  border-radius: 8px;
  background: #1f5fae;
  color: #fff;
  font-size: 11px;
  font-weight: 900;
}

.quant-card-title strong,
.quant-card-title small {
  display: block;
}

.quant-card-title strong {
  color: #172033;
  font-size: 15px;
}

.quant-card-title small {
  margin-top: 2px;
  color: #758297;
  font-size: 11px;
}

.quant-form-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.quant-form-grid label {
  display: grid;
  gap: 5px;
  min-width: 0;
  color: #5a6679;
  font-size: 11px;
  font-weight: 800;
}

.quant-form-grid input,
.quant-form-grid select {
  width: 100%;
  min-height: 38px;
  padding: 7px 9px;
  border: 1px solid #cdd7e4;
  border-radius: 7px;
  background: #fbfdff;
  color: #182235;
  font-variant-numeric: tabular-nums;
}

.quant-checkboxes {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 18px;
  margin-top: 13px;
  color: #425066;
  font-size: 12px;
  font-weight: 700;
}

.quant-checkboxes label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.quant-run-button {
  width: 100%;
  min-height: 42px;
  margin-top: 14px;
  border: 0;
  border-radius: 8px;
  background: linear-gradient(135deg, #1c61b9, #174981);
  color: #fff;
  font-weight: 900;
  cursor: pointer;
}

.quant-run-button:disabled {
  cursor: wait;
  opacity: 0.65;
}

.quant-cost-note {
  margin: 8px 0 0;
  color: #7c8798;
  font-size: 10px;
  line-height: 1.45;
}

.quant-rule-card ol {
  margin: 12px 0 0;
  padding-left: 20px;
  color: #4f5d72;
  font-size: 12px;
  line-height: 1.7;
}

.quant-rule-summary {
  display: grid;
  gap: 7px;
}

.quant-rule-summary span {
  display: block;
  padding: 8px 10px;
  border-left: 3px solid #3a79c7;
  border-radius: 4px;
  background: #f2f7fd;
  color: #35445b;
  font-size: 12px;
}

.quant-data-quality {
  margin-top: 12px;
  padding: 10px 12px;
  border-radius: 7px;
  background: #eef2f7;
  color: #5a687c;
  font-size: 11px;
  line-height: 1.55;
}

.quant-data-quality.verified {
  background: #e8f7f0;
  color: #17654e;
}

.quant-data-quality.warning {
  background: #fff4dc;
  color: #80560a;
}

.quant-review-status {
  margin: 16px 0;
  padding: 11px 14px;
  border: 1px solid #d7e0eb;
  border-radius: 8px;
  background: #fff;
  color: #58677b;
  font-size: 12px;
}

.quant-review-status.loading {
  border-color: #b7cdeb;
  background: #edf5ff;
  color: #235b9c;
}

.quant-review-status.error {
  border-color: #f0c5c5;
  background: #fff0f0;
  color: #a22f2f;
}

.quant-review-results {
  display: grid;
  gap: 16px;
}

.quant-verdict {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 14px;
  padding: 16px 18px;
  border: 1px solid #d8e1ed;
  border-radius: 12px;
  background: #fff;
}

.quant-verdict-score {
  display: grid;
  width: 58px;
  height: 58px;
  place-items: center;
  border-radius: 50%;
  background: #17243a;
  color: #fff;
  font-size: 20px;
  font-weight: 900;
}

.quant-verdict-score.quant-stage-mark {
  background: linear-gradient(145deg, #0f8f82, #1463b8);
  font-size: 24px;
}

.quant-strategy-sample {
  border-color: rgba(20, 143, 130, 0.34);
  background: linear-gradient(135deg, rgba(235, 250, 247, 0.94), rgba(241, 247, 255, 0.96));
}

.quant-sample-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  margin-bottom: 14px;
}

.quant-sample-head h3,
.quant-sample-head p {
  margin: 0;
}

.quant-sample-head p {
  margin-top: 6px;
  color: #65758b;
  font-size: 13px;
}

.quant-sample-head > strong {
  flex: 0 0 auto;
  padding: 8px 13px;
  border-radius: 999px;
  color: #087265;
  background: #d8f4ec;
  font-size: 14px;
}

.quant-verdict strong,
.quant-verdict p {
  display: block;
  margin: 0;
}

.quant-verdict strong {
  color: #192438;
  font-size: 17px;
}

.quant-verdict p {
  margin-top: 4px;
  color: #647187;
  font-size: 12px;
}

.quant-verdict-action {
  max-width: 270px;
  padding: 8px 10px;
  border-radius: 7px;
  background: #f2f5f9;
  color: #3c4b61;
  font-size: 11px;
  font-weight: 800;
}

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

.quant-metric {
  min-width: 0;
  padding: 12px;
  border: 1px solid #dfe6ef;
  border-radius: 9px;
  background: #fff;
}

.quant-metric span,
.quant-metric strong,
.quant-metric small {
  display: block;
}

.quant-metric span {
  color: #788499;
  font-size: 10px;
}

.quant-metric strong {
  margin: 4px 0;
  color: #172033;
  font-size: 19px;
  font-variant-numeric: tabular-nums;
}

.quant-metric small {
  color: #8a95a6;
  font-size: 9px;
}

.quant-result-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(360px, 0.75fr);
  gap: 16px;
}

.quant-result-card {
  min-width: 0;
  padding: 15px;
}

.quant-result-card h3 {
  margin: 0 0 10px;
  color: #1c273a;
  font-size: 14px;
}

.quant-equity-chart {
  display: block;
  width: 100%;
  height: 220px;
  border-radius: 8px;
  background: #101827;
}

.quant-split-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.quant-split-card {
  padding: 12px;
  border-radius: 8px;
  background: #f3f6fa;
}

.quant-split-card span,
.quant-split-card strong,
.quant-split-card small {
  display: block;
}

.quant-split-card span {
  color: #6f7c90;
  font-size: 10px;
}

.quant-split-card strong {
  margin: 4px 0;
  font-size: 18px;
  color: #1c293d;
}

.quant-split-card small {
  color: #7a8799;
  font-size: 10px;
}

.quant-current-gate {
  margin-top: 12px;
  padding: 12px;
  border-radius: 8px;
  background: #fff6df;
  color: #79570d;
  font-size: 11px;
  line-height: 1.6;
}

.quant-current-gate.pass {
  background: #e8f7f0;
  color: #17654e;
}

.quant-year-bars {
  display: grid;
  gap: 7px;
}

.quant-year-row {
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr) 62px;
  align-items: center;
  gap: 8px;
  color: #5f6d80;
  font-size: 11px;
}

.quant-funnel-row {
  grid-template-columns: minmax(170px, 0.45fr) minmax(160px, 1fr) 62px;
}

.quant-year-track {
  height: 7px;
  overflow: hidden;
  border-radius: 999px;
  background: #e8edf3;
}

.quant-year-fill {
  height: 100%;
  border-radius: inherit;
  background: #2e73c4;
}

.quant-year-fill.negative {
  background: #3aa879;
}

.quant-trade-table {
  width: 100%;
  min-width: 760px;
  border-collapse: collapse;
}

.quant-trade-table th,
.quant-trade-table td {
  padding: 8px 9px;
  border-bottom: 1px solid #e7ebf1;
  font-size: 10px;
  text-align: left;
  white-space: nowrap;
}

.quant-trade-table th {
  color: #738096;
  background: #f6f8fb;
}

.quant-trade-table td {
  color: #344158;
}

.quant-result-note {
  padding: 12px 14px;
  border-left: 4px solid #d5a735;
  background: #fff9ea;
  color: #66521b;
  font-size: 11px;
  line-height: 1.6;
}

@media (max-width: 1180px) {
  .quant-review-layout,
  .quant-result-grid {
    grid-template-columns: 1fr;
  }

  .quant-manual-body {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

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

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

@media (max-width: 720px) {
  .quant-review-panel {
    padding: 10px;
  }

  .quant-review-head,
  .quant-verdict {
    grid-template-columns: 1fr;
  }

  .quant-review-head {
    display: grid;
  }

  .quant-manual summary {
    align-items: flex-start;
    flex-wrap: wrap;
  }

  .quant-manual summary small {
    width: 100%;
  }

  .quant-manual-body {
    grid-template-columns: 1fr;
  }

  .quant-review-head .quant-safety-badge {
    justify-self: start;
  }

  .quant-review-layout {
    grid-template-columns: minmax(0, 1fr);
  }

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

  .quant-verdict {
    justify-items: start;
  }

  .quant-verdict-action {
    max-width: none;
  }

  .quant-sample-head {
    display: block;
  }

  .quant-sample-head > strong {
    display: inline-block;
    margin-top: 10px;
  }
}

.position-track-button {
  margin-top: 8px;
  padding: 6px 10px;
  border: 1px solid rgba(78, 161, 255, 0.55);
  border-radius: 8px;
  background: rgba(78, 161, 255, 0.12);
  color: #b9dcff;
  font-size: 12px;
  cursor: pointer;
}

.position-track-button:hover { background: rgba(78, 161, 255, 0.22); }
.position-track-button.tracked { border-color: rgba(86, 211, 154, 0.55); background: rgba(86, 211, 154, 0.12); color: #a8efcf; }

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background: var(--bg);
  font-family: "Microsoft YaHei", "PingFang SC", Arial, sans-serif;
}

.access-gate {
  position: fixed;
  z-index: 20;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(15, 23, 42, 0.62);
}

.access-gate[hidden] { display: none; }

.access-card {
  display: grid;
  gap: 12px;
  width: min(360px, 100%);
  padding: 22px;
  border-radius: 8px;
  background: #ffffff;
  box-shadow: 0 18px 48px rgba(0,0,0,0.22);
}

.access-card h2 {
  font-size: 18px;
}

.access-card input {
  min-height: 42px;
  padding: 0 10px;
}

.access-card button {
  min-height: 40px;
  border: 0;
  border-radius: 6px;
  background: var(--blue);
  color: #ffffff;
  font-weight: 800;
  cursor: pointer;
}

.access-card small {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.55;
}

.access-card p {
  min-height: 18px;
  color: var(--red);
  font-size: 13px;
}

button, input, textarea {
  font: inherit;
}

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

.app-shell.left-collapsed {
  grid-template-columns: 72px minmax(0, 1fr);
}

.side-panel {
  background: #111827;
  color: #eef2f7;
  padding: 12px;
  overflow-y: auto;
}

.brand-block {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-bottom: 18px;
  border-bottom: 1px solid rgba(255,255,255,0.14);
}

.brand-copy {
  min-width: 0;
  flex: 1;
}

.sidebar-toggle {
  display: grid;
  width: 30px;
  height: 30px;
  place-items: center;
  flex: 0 0 30px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #ffffff;
  color: #344154;
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
}

.sidebar-toggle:hover {
  border-color: #9db7ee;
  background: #edf4ff;
  color: var(--blue);
}

.side-panel.left-collapsed {
  padding: 12px 8px;
  overflow: hidden;
}

.side-panel.left-collapsed .brand-block {
  justify-content: center;
  gap: 6px;
  padding-bottom: 0;
  border-bottom: 0;
}

.side-panel.left-collapsed .brand-copy,
.side-panel.left-collapsed .panel-section {
  display: none;
}

.brand-mark {
  width: 42px;
  height: 42px;
  border-radius: 8px;
  display: grid;
  place-items: center;
  background: #e6b450;
  color: #101827;
  font-weight: 900;
}

h1 {
  margin: 0 0 4px;
  font-size: 18px;
  line-height: 1.3;
  letter-spacing: 0;
}

h2 {
  margin: 0;
  font-size: 15px;
  letter-spacing: 0;
}

p { margin: 0; color: #aab4c3; }

.panel-section {
  padding: 14px 0;
  border-bottom: 1px solid rgba(255,255,255,0.12);
}

.panel-section h2 {
  margin-bottom: 10px;
  color: #ffffff;
}

.status-panel {
  padding: 0;
}

.status-panel summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 12px;
  color: #eef2f7;
  cursor: pointer;
  font-size: 13px;
  font-weight: 800;
  list-style: none;
}

.status-panel summary::-webkit-details-marker { display: none; }
.status-panel summary::after { content: "▾"; color: #94a3b8; }
.status-panel[open] summary::after { content: "▴"; }
.status-panel summary small { color: #94a3b8; font-size: 10px; font-weight: 600; }
.status-panel[open] summary small { display: none; }
.status-panel .source-box { margin: 0 10px 10px; }

.focus-core-filter {
  margin-top: 10px;
  border: 1px solid rgba(255,255,255,0.14);
  border-radius: 8px;
  background: rgba(255,255,255,0.04);
}

.focus-core-filter summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 10px;
  color: #eef2f7;
  cursor: pointer;
  font-size: 12px;
  font-weight: 800;
  list-style: none;
}

.focus-core-filter summary::-webkit-details-marker { display: none; }
.focus-core-filter summary::after { content: "▾"; color: #94a3b8; }
.focus-core-filter[open] summary::after { content: "▴"; }
.focus-core-filter summary small { color: #94a3b8; font-size: 10px; font-weight: 600; }
.focus-core-filter[open] summary small { display: none; }

.core-filter-body {
  display: grid;
  gap: 2px;
  padding: 0 10px 10px;
}

.core-filter-body label { min-height: 32px; font-size: 12px; }
.core-filter-body label input[type="number"] { width: 58px; padding: 5px 6px; }

.market-index-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
}

.market-index-head h2 { margin-bottom: 10px; }

.market-index-head span,
.market-index-hint { color: #94a3b8; font-size: 10px; }

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

.market-index-card {
  display: grid;
  gap: 3px;
  min-width: 0;
  padding: 8px;
  border: 1px solid rgba(255,255,255,0.14);
  border-radius: 8px;
  background: rgba(255,255,255,0.055);
  color: #eef2f7;
  text-align: left;
  cursor: pointer;
}

.market-index-card:hover,
.market-index-card:focus-visible {
  border-color: rgba(230,180,80,0.7);
  background: rgba(230,180,80,0.1);
  outline: none;
}

.market-index-card span {
  overflow: hidden;
  color: #aab4c3;
  font-size: 10px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.market-index-card strong { font-size: 14px; }
.market-index-card em { font-size: 11px; font-style: normal; font-weight: 800; }
.market-index-card .market-up { color: #ff7b78; }
.market-index-card .market-down { color: #56d39a; }
.market-index-card .market-flat { color: #cbd5e1; }
.market-index-hint { margin-top: 8px; line-height: 1.45; }

.holder-query-status {
  min-height: 16px;
  margin: 6px 0 0;
  color: #94a3b8;
  font-size: 11px;
  line-height: 1.4;
}

.holder-query-summary {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  border: 1px solid #f0cf82;
  border-radius: 8px;
  background: #fff9e8;
}

.holder-query-summary[hidden] { display: none; }
.holder-query-summary > div { display: grid; gap: 4px; }
.holder-query-summary strong { color: #6f4b00; font-size: 14px; }
.holder-query-summary span { color: #5f6b7a; font-size: 12px; line-height: 1.45; }
.holder-query-summary .holder-identity-warning { color: #9a6700; }
.holder-query-summary button {
  flex: 0 0 auto;
  min-height: 34px;
  padding: 0 11px;
  border: 1px solid #d9b764;
  border-radius: 7px;
  background: #ffffff;
  color: #765000;
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
}

.holder-identity-inline { color: #9a6700; }

.filter-subhead {
  margin: 14px 0 6px;
  color: #aab4c3;
  font-size: 12px;
  font-weight: 700;
}

label {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 36px;
  color: #dce4ef;
  font-size: 14px;
}

input, textarea {
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #ffffff;
  color: var(--ink);
  outline: none;
}

input:focus, textarea:focus {
  border-color: #5b8def;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.14);
}

label input[type="number"] {
  width: 72px;
  padding: 6px 7px;
}

input[type="checkbox"] {
  width: 16px;
  height: 16px;
  accent-color: #e6b450;
}

.switch-line {
  align-items: center;
  flex-wrap: wrap;
}

textarea {
  width: 100%;
  min-height: 150px;
  padding: 10px;
  resize: vertical;
  line-height: 1.55;
}

.compact-keywords {
  min-height: 92px;
  max-height: 128px;
  font-size: 13px;
}

.side-action {
  width: 100%;
  min-height: 38px;
  margin-top: 10px;
  border: 1px solid rgba(255,255,255,0.22);
  border-radius: 8px;
  background: #e6b450;
  color: #101827;
  font-weight: 800;
  cursor: pointer;
}

.focus-add,
.holder-add {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 38px;
  gap: 8px;
}

.focus-add input,
.holder-add input {
  min-width: 0;
  min-height: 38px;
}

.focus-add-button {
  border: 0;
  border-radius: 6px;
  background: var(--accent);
  color: #fff;
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
}

.focus-add-button:hover {
  background: #d69b21;
}

.focus-remove-button {
  width: max-content;
  min-width: 42px;
  height: 26px;
  margin-left: auto;
  padding: 0 8px;
  border: 0;
  border-radius: 5px;
  background: #fce5e5;
  color: #b42318;
  font-size: 11px;
  font-weight: 800;
  line-height: 1;
  cursor: pointer;
  vertical-align: middle;
}

.focus-remove-button:hover {
  background: #f7caca;
}

.keyword-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 10px;
}

.keyword-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-height: 28px;
  padding: 4px 5px 4px 9px;
  border: 1px solid rgba(230, 180, 80, 0.45);
  border-radius: 6px;
  background: rgba(230, 180, 80, 0.14);
  color: #f5ddb0;
  font-size: 12px;
}

.keyword-chip button {
  width: 18px;
  height: 18px;
  padding: 0;
  border: 0;
  border-radius: 4px;
  background: transparent;
  color: #f5ddb0;
  font-size: 16px;
  line-height: 1;
  cursor: pointer;
}

.keyword-chip button:hover {
  background: rgba(255,255,255,0.16);
}

.compact-action {
  min-height: 34px;
  margin-top: 8px;
  background: #ffffff;
  color: #172033;
}

.source-box {
  padding: 10px;
  border-radius: 8px;
  background: rgba(255,255,255,0.08);
  color: #dce4ef;
  font-size: 13px;
  line-height: 1.55;
  word-break: break-all;
}

.source-pools {
  margin-top: 8px;
  color: #aab4c3;
}

.position-entry-copy,
.position-notification-hint {
  color: #aab4c3;
  font-size: 12px;
  line-height: 1.5;
}

.position-add-action {
  margin-top: 10px;
}

.position-dialog {
  width: min(760px, calc(100vw - 28px));
  max-height: calc(100vh - 32px);
  padding: 0;
  overflow: auto;
  border: 0;
  border-radius: 12px;
  color: var(--ink);
  background: #ffffff;
  box-shadow: 0 24px 70px rgba(15, 23, 42, 0.28);
}

.position-dialog::backdrop {
  background: rgba(15, 23, 42, 0.62);
}

.position-form {
  display: grid;
  gap: 16px;
  padding: 22px;
}

.position-dialog-head,
.position-form-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.position-dialog-head span {
  color: var(--blue);
  font-size: 12px;
  font-weight: 800;
}

.position-dialog-head h2 {
  margin-top: 3px;
  font-size: 20px;
}

.dialog-close {
  width: 36px;
  height: 36px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #ffffff;
  color: var(--muted);
  font-size: 24px;
  cursor: pointer;
}

.position-form-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.position-form label {
  display: grid;
  align-items: start;
  gap: 6px;
  color: #344154;
  font-size: 13px;
  font-weight: 700;
}

.position-form input,
.position-form textarea {
  width: 100%;
  min-height: 40px;
  padding: 9px 10px;
  font-weight: 400;
}

.position-form label input[type="number"] {
  width: 100%;
}

.position-form textarea {
  min-height: 86px;
}

.position-wide-field {
  min-height: 0;
}

.position-form-message {
  min-height: 18px;
  color: var(--red);
  font-size: 13px;
}

.position-form-actions {
  justify-content: flex-end;
}

.position-form-actions button,
.position-inline-actions button {
  min-height: 36px;
  padding: 0 14px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #ffffff;
  color: #344154;
  font-weight: 800;
  cursor: pointer;
}

.position-form-actions .primary {
  border-color: var(--blue);
  background: var(--blue);
  color: #ffffff;
}

.position-disclaimer {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
}

.market-index-dialog-card {
  display: grid;
  gap: 16px;
  padding: 22px;
}

.market-index-dialog-body {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.market-index-detail {
  display: grid;
  gap: 5px;
  min-height: 70px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f8fafc;
}

.market-index-detail span { color: var(--muted); font-size: 12px; }
.market-index-detail strong { color: var(--ink); font-size: 17px; }
.market-index-detail strong.market-up { color: var(--red); }
.market-index-detail strong.market-down { color: var(--green); }
.market-index-detail strong.market-flat { color: var(--ink); }
.market-index-detail.market-index-wide { grid-column: 1 / -1; min-height: 0; }

.daily-stock-dialog {
  width: min(980px, calc(100vw - 24px));
}

.daily-stock-dialog-card {
  display: grid;
  gap: 14px;
  padding: 20px;
}

.daily-stock-dialog-body {
  display: grid;
  gap: 12px;
}

.daily-stock-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 12px;
  padding: 12px;
  border: 1px solid #dce6f2;
  border-radius: 9px;
  background: #f8fbff;
}

.daily-stock-hero > div:first-child {
  display: grid;
  gap: 3px;
}

.daily-stock-hero > div:first-child span {
  color: #1e3b61;
  font-weight: 900;
}

.daily-stock-hero small {
  color: #6d7e92;
  line-height: 1.4;
}

.daily-stock-live-price {
  display: grid;
  min-width: 86px;
  text-align: right;
}

.daily-stock-live-price strong {
  color: #172033;
  font-size: 22px;
}

.daily-stock-live-price em {
  font-style: normal;
  font-weight: 800;
}

.daily-stock-live-price .up { color: var(--red); }
.daily-stock-live-price .down { color: var(--green); }

.daily-stock-indicator-stack {
  display: grid;
  gap: 9px;
}

.daily-stock-indicator-block {
  display: grid;
  gap: 7px;
  padding: 10px;
  border: 1px solid #dfe7f1;
  border-radius: 9px;
  background: #f8fbff;
}

.daily-stock-indicator-block.boll-block {
  background: #f7fbf8;
}

.daily-stock-indicator-block > header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
  color: #17324f;
}

.daily-stock-indicator-block > header span {
  color: #718096;
  font-size: 11px;
}

.daily-stock-metric-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
}

.daily-stock-metric-grid > div {
  display: grid;
  gap: 3px;
  min-height: 76px;
  padding: 10px;
  border: 1px solid #e0e8f2;
  border-radius: 8px;
  background: #ffffff;
}

.daily-stock-metric-grid span,
.daily-stock-metric-grid small {
  color: #718096;
  font-size: 11px;
}

.daily-stock-metric-grid strong {
  color: #17324f;
  font-size: 19px;
}

.daily-stock-metric-grid.boll-grid strong {
  font-size: 13px;
  line-height: 1.4;
}

.daily-stock-section {
  display: grid;
  gap: 9px;
  padding: 12px;
  border: 1px solid #dfe7f1;
  border-radius: 9px;
  background: #ffffff;
}

.daily-stock-section > header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.daily-stock-section > header strong {
  color: #1d3554;
  font-size: 14px;
}

.daily-stock-section > header span {
  color: #748398;
  font-size: 11px;
}

.daily-stock-dialog .position-dialog-head {
  position: sticky;
  top: 0;
  z-index: 12;
  padding: 4px 0 10px;
  background: rgba(255, 255, 255, .96);
  backdrop-filter: blur(10px);
}

.daily-stock-at-glance {
  display: grid;
  grid-template-columns: 1.25fr .85fr 1fr 1fr 1fr;
  gap: 8px;
}

.daily-stock-at-glance article {
  display: grid;
  align-content: start;
  gap: 5px;
  min-width: 0;
  padding: 11px;
  border: 1px solid #dce6f1;
  border-radius: 9px;
  background: #f8fafc;
}

.daily-stock-at-glance article.primary {
  border-color: #a9d8cc;
  background: #eefaf6;
}

.daily-stock-at-glance article.risk {
  border-color: #f1d2c6;
  background: #fff8f4;
}

.daily-stock-at-glance span {
  color: #718096;
  font-size: 11px;
  font-weight: 800;
}

.daily-stock-at-glance strong {
  color: #173653;
  font-size: 13px;
  line-height: 1.45;
  overflow-wrap: anywhere;
}

.daily-stock-at-glance p {
  margin: 0;
  color: #64768b;
  font-size: 11px;
  line-height: 1.45;
}

.daily-stock-ai-research {
  display: grid;
  gap: 9px;
  padding: 12px;
  border: 1px solid #cfe0ee;
  border-radius: 12px;
  background: linear-gradient(135deg, #f4f9ff, #f7fcfa);
}

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

.ai-research-head > div { display: grid; gap: 2px; }
.ai-research-head span { color: #174b70; font-size: 13px; font-weight: 900; }
.ai-research-head small { color: #718398; font-size: 11px; }
.ai-research-head button {
  flex: 0 0 auto;
  min-height: 32px;
  padding: 6px 10px;
  border: 1px solid #237b6a;
  border-radius: 8px;
  color: #fff;
  background: #177b69;
  font: inherit;
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
}
.ai-research-head button:disabled { cursor: wait; opacity: .65; }

.ai-phase-banner {
  display: grid;
  grid-template-columns: minmax(220px, .72fr) minmax(0, 1.4fr);
  align-items: center;
  gap: 14px;
  padding: 11px 13px;
  border: 1px solid #d8e4ee;
  border-left: 6px solid #7b8d9e;
  border-radius: 10px;
  background: #fff;
}

.ai-phase-banner.left { border-left-color: #3975b7; background: #f3f8fe; }
.ai-phase-banner.transition { border-left-color: #c58a18; background: #fffaf0; }
.ai-phase-banner.right { border-left-color: #16806a; background: #eff9f5; }
.ai-phase-banner.neutral { border-left-color: #b77d12; background: #fffaf0; }
.ai-phase-banner.neutral.risk { border-left-color: #a64534; background: #fff6f3; }
.ai-phase-current { display: grid; gap: 2px; }
.ai-phase-current span { color: #6b7e91; font-size: 10px; font-weight: 900; }
.ai-phase-current strong { color: #173f60; font-size: 19px; line-height: 1.25; }
.ai-phase-banner.left .ai-phase-current strong { color: #2f68a6; }
.ai-phase-banner.transition .ai-phase-current strong { color: #936512; }
.ai-phase-banner.right .ai-phase-current strong { color: #126f5d; }
.ai-phase-banner.neutral .ai-phase-current strong { color: #8b6414; }
.ai-phase-banner.neutral.risk .ai-phase-current strong { color: #a04432; }
.ai-phase-current p { margin: 0; color: #60758a; font-size: 11px; line-height: 1.45; }
.ai-phase-track { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 5px; }
.ai-phase-track div {
  display: grid;
  justify-items: center;
  gap: 4px;
  min-width: 0;
  padding: 7px 4px;
  border-radius: 8px;
  color: #8292a2;
  background: #eef3f7;
}
.ai-phase-track i { width: 8px; height: 8px; border-radius: 50%; background: #aab7c3; }
.ai-phase-track span { font-size: 10px; font-weight: 900; text-align: center; }
.ai-phase-track .active { color: #fff; background: #184a70; box-shadow: 0 5px 12px rgba(24, 74, 112, .16); }
.ai-phase-banner.left .ai-phase-track .active { background: #3975b7; }
.ai-phase-banner.transition .ai-phase-track .active { background: #b77d12; }
.ai-phase-banner.right .ai-phase-track .active { background: #16806a; }
.ai-phase-banner.neutral .ai-phase-track .active { background: #b77d12; }
.ai-phase-banner.neutral.risk .ai-phase-track .active { background: #a64534; }
.ai-phase-track .active i { background: #fff; }

.ai-decision-summary {
  display: grid;
  grid-template-columns: .78fr 1.1fr 1.25fr;
  gap: 7px;
}

.ai-decision-summary article {
  display: grid;
  align-content: start;
  gap: 4px;
  min-width: 0;
  padding: 10px;
  border: 1px solid #dce7f1;
  border-radius: 9px;
  background: rgba(255, 255, 255, .88);
}

.ai-decision-summary span,
.ai-price-plan span { color: #718398; font-size: 10px; font-weight: 800; }
.ai-decision-summary strong { color: #1c405f; font-size: 12px; line-height: 1.5; overflow-wrap: anywhere; }
.ai-decision-summary p { margin: 0; color: #718398; font-size: 10px; line-height: 1.4; }
.ai-decision-summary.ready .ai-decision-verdict { border-color: #9fd3c5; background: #edf9f4; }
.ai-decision-summary.ready .ai-decision-verdict strong { color: #10705d; font-size: 16px; }
.ai-decision-summary.risk .ai-decision-verdict { border-color: #efb9ad; background: #fff5f1; }
.ai-decision-summary.risk .ai-decision-verdict strong,
.ai-decision-risk strong { color: #9e3e2e; }
.ai-decision-summary.near .ai-decision-verdict { border-color: #ebd7a3; background: #fffaf0; }
.ai-decision-summary.near .ai-decision-verdict strong { color: #8b6414; font-size: 16px; }
.ai-decision-summary.holding .ai-decision-verdict { border-color: #b7cfeb; background: #f1f7fd; }
.ai-decision-summary.holding .ai-decision-verdict strong { color: #1c5f94; font-size: 16px; }

.ai-decision-summary:has(.ai-blocker-list) {
  grid-template-columns: .72fr 1.55fr 1.05fr;
}

.ai-decision-summary .ai-decision-risk:has(.ai-blocker-list) {
  gap: 7px;
  border-color: #e7b8ad;
  background: rgba(255, 247, 244, .94);
}

.ai-blocker-list { display: grid; gap: 6px; }

.ai-blocker-item {
  display: grid;
  gap: 4px;
  padding: 8px;
  border: 1px solid #ead0c9;
  border-left: 4px solid #b54a38;
  border-radius: 8px;
  background: rgba(255, 255, 255, .82);
}

.ai-blocker-item > div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.ai-blocker-item b { color: #873527; font-size: 11px; }
.ai-blocker-item em {
  flex: 0 0 auto;
  padding: 2px 6px;
  border-radius: 999px;
  background: #f6ded8;
  color: #9c3d2d;
  font-size: 9px;
  font-style: normal;
  font-weight: 900;
}
.ai-blocker-item strong { color: #823528; font-size: 11px; }
.ai-blocker-item small { display: grid; grid-template-columns: 30px 1fr; gap: 5px; color: #627589; font-size: 9px; line-height: 1.45; }
.ai-blocker-item small i { color: #8e4a3e; font-style: normal; font-weight: 900; }
.ai-blocker-item.finance { border-left-color: #c5871e; }
.ai-blocker-item.finance b,
.ai-blocker-item.finance strong { color: #805914; }
.ai-blocker-item.finance em { background: #f9edc8; color: #856114; }
.ai-blocker-item.data { border-left-color: #3a78b8; }
.ai-blocker-item.data b,
.ai-blocker-item.data strong { color: #285f94; }
.ai-blocker-item.data em { background: #dfeefa; color: #2a6398; }
.ai-blocker-item.event { border-left-color: #8a3b65; }
.ai-blocker-item.event b,
.ai-blocker-item.event strong { color: #743052; }

.ai-operation-plan {
  display: grid;
  grid-template-columns: .72fr 1.35fr .9fr 1.25fr;
  gap: 7px;
}

.ai-operation-plan div {
  display: grid;
  grid-template-columns: auto 1fr;
  align-content: start;
  gap: 3px 7px;
  min-width: 0;
  padding: 9px 10px;
  border-radius: 9px;
  background: #173f60;
}
.ai-operation-plan b {
  grid-row: 1 / span 2;
  display: grid;
  place-items: center;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  color: #173f60;
  background: #fff;
  font-size: 10px;
}
.ai-operation-plan span { color: #b9cddd; font-size: 9px; font-weight: 800; }
.ai-operation-plan strong { color: #fff; font-size: 11px; line-height: 1.45; overflow-wrap: anywhere; }

.ai-entry-routes {
  display: grid;
  gap: 9px;
  padding: 12px;
  border: 1px solid #bcd4e7;
  border-radius: 10px;
  background: linear-gradient(180deg, #f6fbff 0%, #fff 100%);
}

.ai-entry-routes > header {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 14px;
}

.ai-entry-routes > header div { display: grid; gap: 2px; }
.ai-entry-routes > header span { color: #6e8296; font-size: 10px; font-weight: 900; }
.ai-entry-routes > header strong { color: #173f60; font-size: 15px; }
.ai-entry-routes > header small { color: #718398; font-size: 10px; text-align: right; }
.ai-entry-route-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.ai-entry-route-grid:has(> article:nth-child(3)) { grid-template-columns: repeat(3, minmax(0, 1fr)); }

.ai-entry-route-grid article {
  display: grid;
  align-content: start;
  gap: 7px;
  min-width: 0;
  padding: 11px;
  border: 1px solid #d8e4ee;
  border-top: 4px solid #7894aa;
  border-radius: 9px;
  background: #fff;
}

.ai-entry-route-grid article.ready { border-top-color: #16806a; background: #f1faf6; }
.ai-entry-route-grid article.near { border-top-color: #c58a18; background: #fffbf2; }
.ai-entry-route-grid article.locked { border-top-color: #a64534; background: #fff6f3; }
.ai-entry-route-title { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.ai-entry-route-title strong { color: #173f60; font-size: 13px; }
.ai-entry-route-title em {
  flex: 0 0 auto;
  padding: 2px 7px;
  border-radius: 999px;
  color: #526b81;
  background: #eaf1f6;
  font-size: 9px;
  font-style: normal;
  font-weight: 900;
}
.ai-entry-route-grid article.ready .ai-entry-route-title em { color: #126f5d; background: #dff3ea; }
.ai-entry-route-grid article.near .ai-entry-route-title em { color: #8b6414; background: #f9edc8; }
.ai-entry-route-grid article.locked .ai-entry-route-title em { color: #9e3e2e; background: #f8ddd6; }
.ai-entry-route-grid p { margin: 0; color: #173f60; font-size: 12px; font-weight: 900; line-height: 1.45; }
.ai-entry-route-grid ul { display: grid; gap: 4px; margin: 0; padding-left: 17px; color: #5f7488; font-size: 10px; line-height: 1.45; }
.ai-entry-route-grid footer { display: grid; gap: 2px; padding-top: 7px; border-top: 1px dashed #ccd9e4; }
.ai-entry-route-grid footer span { color: #7890a4; font-size: 9px; font-weight: 900; }
.ai-entry-route-grid footer strong { color: #804135; font-size: 10px; line-height: 1.45; }

.daily-stock-plan-panel {
  padding: 2px;
  border-radius: 12px;
  background: linear-gradient(180deg, #f7fbff 0%, #ffffff 100%);
}

.trade-capital-plan {
  display: grid;
  gap: 10px;
  padding: 13px;
  border: 1px solid #bcd4e7;
  border-radius: 10px;
  background: #fff;
  box-shadow: 0 8px 20px rgba(23, 63, 96, .07);
}

.trade-capital-plan > header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
}

.trade-capital-plan > header div { display: grid; gap: 2px; }
.trade-capital-plan > header span { color: #5d7388; font-size: 10px; font-weight: 900; }
.trade-capital-plan > header strong { color: #173f60; font-size: 17px; }
.trade-capital-plan > header small { color: #728497; font-size: 10px; }

#dailyTradePlanForm {
  display: grid;
  grid-template-columns: repeat(2, minmax(150px, 1fr)) auto auto;
  align-items: end;
  gap: 8px;
  padding: 10px;
  border-radius: 8px;
  background: #f1f6fa;
}

#dailyTradePlanForm label {
  display: grid;
  gap: 5px;
  color: #516a80;
  font-size: 10px;
  font-weight: 900;
}

#dailyTradePlanForm input {
  width: 100%;
  min-height: 38px;
  padding: 7px 9px;
  border: 1px solid #b8cad9;
  border-radius: 7px;
  background: #fff;
  color: #173f60;
  font: inherit;
  font-size: 13px;
}

#dailyTradePlanForm button,
.trade-plan-actions button {
  min-height: 38px;
  padding: 7px 13px;
  border: 1px solid #8aa7be;
  border-radius: 7px;
  background: #fff;
  color: #294f6c;
  font-weight: 900;
  cursor: pointer;
}

#dailyTradePlanForm button.primary { border-color: #167866; background: #167866; color: #fff; }

.trade-capital-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, .72fr)) minmax(220px, 1.35fr);
  gap: 8px;
}

.trade-capital-summary article {
  display: grid;
  gap: 3px;
  min-height: 82px;
  padding: 10px;
  border: 1px solid #d9e4ed;
  border-radius: 8px;
  background: #fbfdff;
}

.trade-capital-summary article.current { border-color: #a9cbbf; background: #f1faf7; }
.trade-capital-summary span { color: #6b7e91; font-size: 9px; font-weight: 900; }
.trade-capital-summary strong { color: #173f60; font-size: 15px; line-height: 1.25; }
.trade-capital-summary small { color: #667b8e; font-size: 10px; line-height: 1.45; }

.actual-purchase-ledger {
  display: grid;
  gap: 9px;
  padding: 12px;
  border: 1px solid #9fc8bd;
  border-radius: 9px;
  background: linear-gradient(180deg, #f3fbf8 0%, #ffffff 100%);
}

.actual-purchase-ledger > header {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
}

.actual-purchase-ledger > header div { display: grid; gap: 3px; }
.actual-purchase-ledger > header span { color: #267361; font-size: 10px; font-weight: 900; }
.actual-purchase-ledger > header strong { color: #123f36; font-size: 16px; line-height: 1.3; }
.actual-purchase-ledger > header small { color: #66877e; font-size: 10px; text-align: right; }

.actual-purchase-lot-list { display: grid; gap: 6px; }

.actual-purchase-lot {
  display: grid;
  grid-template-columns: minmax(110px, .8fr) minmax(180px, 1.25fr) minmax(90px, .6fr) auto;
  align-items: center;
  gap: 8px;
  padding: 8px 9px;
  border: 1px solid #d3e5df;
  border-radius: 7px;
  background: #fff;
}

.actual-purchase-lot div { display: grid; gap: 1px; }
.actual-purchase-lot span { color: #246654; font-size: 11px; font-weight: 900; }
.actual-purchase-lot small { color: #7a8f89; font-size: 9px; }
.actual-purchase-lot strong { color: #173f60; font-size: 12px; }
.actual-purchase-lot em { color: #516a80; font-size: 11px; font-style: normal; font-weight: 800; }
.actual-purchase-lot button { min-height: 28px; padding: 4px 9px; border-color: #d8b5ad; color: #a34435; }
.actual-purchase-lot button:disabled { cursor: not-allowed; opacity: .45; }

.actual-purchase-empty {
  padding: 10px;
  border: 1px dashed #a9cbbf;
  border-radius: 7px;
  color: #58756d;
  font-size: 11px;
  line-height: 1.55;
}

#actualPurchaseLotForm {
  display: grid;
  grid-template-columns: .8fr 1fr 1fr 1fr auto;
  align-items: end;
  gap: 7px;
  padding: 9px;
  border-radius: 8px;
  background: #eaf6f2;
}

#actualPurchaseLotForm label { display: grid; gap: 4px; color: #4f7268; font-size: 10px; font-weight: 800; }
#actualPurchaseLotForm input,
#actualPurchaseLotForm select { width: 100%; min-height: 35px; padding: 7px 8px; border: 1px solid #b9d3cb; border-radius: 6px; background: #fff; color: #173f60; }
#actualPurchaseLotForm button { min-height: 35px; border-color: #167866; background: #167866; color: #fff; }

.actual-position-node-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 7px;
}

.actual-position-node-grid article { display: grid; gap: 3px; padding: 9px; border: 1px solid #d3e2eb; border-radius: 7px; background: #fbfdff; }
.actual-position-node-grid article.risk { border-color: #edc4bc; background: #fff7f5; }
.actual-position-node-grid span { color: #687f92; font-size: 9px; font-weight: 900; }
.actual-position-node-grid strong { color: #173f60; font-size: 14px; }
.actual-position-node-grid article.risk strong { color: #a84030; }
.actual-position-node-grid small { color: #637a8d; font-size: 10px; line-height: 1.45; }

#actualPurchaseMessage { min-height: 17px; margin: 0; color: #267361; font-size: 10px; }

.trade-plan-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.trade-plan-actions p { min-height: 18px; margin: 0; color: #167866; font-size: 11px; }
.trade-plan-actions button { border-color: #3975b7; color: #2f68a6; }

.ai-price-plan {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 7px;
}

.ai-price-plan div {
  display: grid;
  gap: 4px;
  padding: 8px 10px;
  border-radius: 8px;
  background: #fff;
  box-shadow: inset 0 0 0 1px #e0e9f2;
}

.ai-price-plan strong { color: #173f60; font-size: 13px; }
.ai-price-plan small { color: #7b8b9b; font-size: 9px; line-height: 1.4; overflow-wrap: anywhere; }

.ai-decision-dimensions {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 6px;
}

.ai-decision-dimensions article {
  display: grid;
  align-content: start;
  gap: 6px;
  min-width: 0;
  padding: 8px;
  border: 1px solid #dde7ef;
  border-radius: 8px;
  background: rgba(255, 255, 255, .76);
}

.ai-decision-dimensions article > div { display: flex; justify-content: space-between; gap: 6px; }
.ai-decision-dimensions span { color: #566f86; font-size: 10px; font-weight: 900; }
.ai-decision-dimensions em { padding: 1px 5px; border-radius: 999px; font-size: 9px; font-style: normal; font-weight: 900; }
.ai-decision-dimensions strong { color: #61758a; font-size: 10px; line-height: 1.45; overflow-wrap: anywhere; }
.ai-decision-dimensions .pass em { color: #0c6c58; background: #dff5ec; }
.ai-decision-dimensions .near em { color: #8b6414; background: #fff0c9; }
.ai-decision-dimensions .fail em { color: #a33e2f; background: #fee8e3; }
.ai-decision-dimensions .unknown em { color: #66788a; background: #eaf0f5; }

.ai-research-grid {
  display: grid;
  grid-template-columns: .78fr 1.3fr 1.2fr 1.35fr;
  gap: 7px;
}

.ai-research-grid article {
  display: grid;
  align-content: start;
  gap: 4px;
  min-width: 0;
  padding: 9px 10px;
  border-radius: 8px;
  background: rgba(255, 255, 255, .82);
}

.ai-research-grid span { color: #718398; font-size: 10px; font-weight: 800; }
.ai-research-grid strong { color: #1c405f; font-size: 12px; line-height: 1.5; overflow-wrap: anywhere; }
.ai-research-grid.risk article:first-child { background: #fff5f1; }
.ai-research-grid.risk article:first-child strong,
.ai-research-grid article.risk strong { color: #9e3e2e; }
.ai-research-grid.ready article:first-child { background: #edf9f4; }
.ai-research-grid.ready article:first-child strong { color: #10705d; }

.daily-stock-detail-tabs {
  position: sticky;
  top: 66px;
  z-index: 11;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 4px;
  padding: 5px;
  border: 1px solid #d9e3ef;
  border-radius: 10px;
  background: rgba(244, 248, 252, .96);
  backdrop-filter: blur(10px);
}

.daily-stock-detail-tabs button {
  min-height: 40px;
  padding: 7px 8px;
  border: 0;
  border-radius: 7px;
  color: #536980;
  background: transparent;
  font-weight: 900;
  cursor: pointer;
}

.daily-stock-detail-tabs button.active {
  color: #0f6b5d;
  background: #ffffff;
  box-shadow: 0 2px 8px rgba(15, 43, 71, .12);
}

.daily-stock-tab-panels,
.daily-stock-tab-panel {
  display: grid;
  gap: 10px;
}

.daily-stock-tab-panel[hidden] { display: none !important; }

.company-profile-lead {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.company-profile-lead article,
.company-profile-context article {
  display: grid;
  align-content: start;
  gap: 7px;
  padding: 14px;
  border: 1px solid #dce6f1;
  border-radius: 10px;
  background: #f8fbff;
}

.company-profile-lead span,
.company-profile-context span,
.company-profile-secondary span,
.company-profile-group-grid span {
  color: #6b7d91;
  font-size: 11px;
}

.company-profile-lead strong,
.company-profile-context strong {
  color: #193b5e;
  font-size: 13px;
  line-height: 1.6;
}

.company-profile-context {
  display: grid;
  grid-template-columns: .55fr 1.45fr;
  gap: 12px;
}

.company-profile-secondary {
  display: flex;
  align-items: baseline;
  gap: 10px;
  min-width: 0;
  padding: 9px 12px;
  border: 1px solid #e2eaf2;
  border-radius: 9px;
  background: #fbfcfe;
}

.company-profile-secondary strong {
  flex: 0 0 auto;
  color: #193b5e;
  font-size: 12px;
}

.company-profile-secondary small {
  min-width: 0;
  color: #77879a;
  line-height: 1.5;
  overflow-wrap: anywhere;
}

.company-profile-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.company-profile-tags b {
  padding: 4px 7px;
  border-radius: 999px;
  color: #1e5d78;
  background: #eaf4fa;
  font-size: 11px;
}

.company-profile-tags em { color: #7b8795; font-style: normal; }

.company-profile-groups {
  display: grid;
  grid-template-columns: .9fr 1.1fr 1fr;
  gap: 12px;
}

.company-profile-group {
  min-width: 0;
  padding: 12px;
  border: 1px solid #e0e8f0;
  border-radius: 10px;
  background: #fbfcfe;
}

.company-profile-group h4 {
  margin: 0 0 9px;
  color: #1d4e73;
  font-size: 12px;
}

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

.company-profile-group-grid > div {
  display: grid;
  gap: 4px;
  min-width: 0;
  padding: 9px;
  border-radius: 7px;
  background: #f2f6fa;
}

.company-profile-group-grid strong {
  color: #173653;
  font-size: 13px;
  overflow-wrap: anywhere;
}

.company-profile-source,
.company-profile-warning {
  margin: 0;
  color: #6d7e91;
  font-size: 11px;
  line-height: 1.5;
}

.company-profile-warning { color: #a16207; }
.company-profile-source a { color: #176b8a; font-weight: 800; }
.company-profile-section .is-refreshing { opacity: .82; }

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

.daily-stock-check {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 3px 8px;
  padding: 8px 9px;
  border-radius: 7px;
  background: #f6f8fb;
}

.daily-stock-check span {
  color: #33475f;
  font-size: 12px;
  font-weight: 800;
}

.daily-stock-check b {
  font-size: 11px;
}

.daily-stock-check small {
  grid-column: 1 / -1;
  color: #738297;
  font-size: 11px;
}

.daily-stock-check.pass b { color: #12805d; }
.daily-stock-check.fail b { color: #c2413a; }
.daily-stock-check.pending b { color: #8b6b21; }

.daily-stock-holder-meta {
  color: #65768b;
  font-size: 11px;
}

.daily-stock-holder-list {
  display: grid;
  gap: 5px;
}

.daily-stock-holder-row {
  display: grid;
  grid-template-columns: 54px minmax(160px, 1fr) minmax(160px, auto) minmax(110px, auto);
  align-items: center;
  gap: 8px;
  padding: 7px 8px;
  border-radius: 7px;
  background: #f7f9fc;
  color: #53657c;
  font-size: 11px;
}

.daily-stock-holder-row .holder-rank {
  color: #2c5c99;
  font-weight: 900;
}

.daily-stock-holder-row strong {
  color: #26384f;
  font-size: 12px;
}

.daily-stock-holder-row small {
  color: #76869a;
  text-align: right;
}

.daily-stock-holder-empty {
  padding: 12px;
  border-radius: 7px;
  background: #f5f7fa;
  color: #6d7e92;
  font-size: 12px;
  text-align: center;
}

.daily-stock-kline {
  min-height: 242px;
}

.daily-stock-kline-tabs {
  display: inline-flex;
  gap: 3px;
  margin-bottom: 7px;
  padding: 3px;
  border: 1px solid #dfe6ef;
  border-radius: 8px;
  background: #f2f5f9;
}

.daily-stock-kline-tabs button {
  min-width: 54px;
  padding: 5px 12px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: #52667d;
  font-size: 12px;
  font-weight: 800;
}

.daily-stock-kline-tabs button[aria-selected="true"] {
  background: #ffffff;
  color: #1f5fbf;
  box-shadow: 0 1px 4px rgba(32, 58, 92, 0.14);
}

.daily-stock-kline-canvas {
  display: block;
  width: 100%;
  height: 240px;
  border: 1px solid #e3e9f1;
  border-radius: 8px;
  background: #fbfcfe;
}

.daily-stock-kline-meta {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  margin-top: 6px;
  color: #718096;
  font-size: 11px;
}

.daily-stock-ma-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(90px, 1fr));
  gap: 5px;
  margin-top: 7px;
}

.daily-stock-ma-grid > span {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  min-width: 0;
  padding: 5px 7px;
  border: 1px solid #e4e9f0;
  border-left: 3px solid var(--ma-color);
  border-radius: 6px;
  background: #fafbfd;
}

.daily-stock-ma-grid small {
  color: #718096;
  font-size: 10px;
  font-weight: 800;
}

.daily-stock-ma-grid b {
  overflow: hidden;
  color: #26384f;
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.daily-stock-ma-grid > span.shortage {
  grid-column: span 2;
  border-color: #efd79b;
  border-left-color: #d6a32c;
  background: #fffaf0;
}

.daily-stock-ma-grid > span.shortage b {
  color: #8a620e;
  text-align: right;
  text-overflow: clip;
  white-space: normal;
}

.daily-stock-ma-forecast-section {
  border-color: #cfe1f8;
  background: #f8fbff;
}

.daily-ma-forecast-summary {
  display: grid;
  gap: 4px;
  padding: 10px 12px;
  border-left: 4px solid #2f72d6;
  border-radius: 7px;
  background: #eef5ff;
}

.daily-ma-forecast-summary.aligned {
  border-left-color: #16906b;
  background: #eaf8f2;
}

.daily-ma-forecast-summary strong { color: #17324f; font-size: 13px; }
.daily-ma-forecast-summary span { color: #62758c; font-size: 11px; line-height: 1.45; }

.daily-ma-current-values {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 5px;
  margin-top: 8px;
}

.daily-ma-current-values span {
  display: grid;
  gap: 2px;
  padding: 6px;
  border: 1px solid #dfe7f1;
  border-radius: 6px;
  background: #fff;
  text-align: center;
}

.daily-ma-current-values small { color: #718096; font-size: 10px; }
.daily-ma-current-values b { color: #26384f; font-size: 12px; }

.daily-ma-pair-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 5px;
  margin-top: 7px;
}

.daily-ma-pair-grid span {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  padding: 6px 8px;
  border-radius: 6px;
  background: #f2f5f9;
}

.daily-ma-pair-grid span.pass { background: #e6f7f1; }
.daily-ma-pair-grid span.waiting { background: #fff6dc; }
.daily-ma-pair-grid b { color: #40546d; font-size: 10px; }
.daily-ma-pair-grid small { color: #66788e; font-size: 10px; }

.daily-ma-scenarios {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
  margin-top: 7px;
}

.daily-ma-scenarios > div {
  display: grid;
  gap: 3px;
  padding: 7px 8px;
  border: 1px solid #e1e7ef;
  border-radius: 7px;
  background: #fff;
}

.daily-ma-scenarios > div.base { border-color: #78a8eb; background: #f2f7ff; }
.daily-ma-scenarios span { color: #718096; font-size: 10px; }
.daily-ma-scenarios strong { color: #26384f; font-size: 12px; }

.daily-ma-forecast-note {
  margin: 7px 0 0;
  color: #718096;
  font-size: 10px;
  line-height: 1.5;
}

.daily-stock-finance-section #dailyStockFinanceDetail.is-refreshing {
  opacity: 0.72;
}

.daily-stock-dialog-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding-top: 2px;
}

.daily-stock-dialog-actions span {
  color: #718096;
  font-size: 11px;
}

.position-plan-card {
  border-left: 4px solid var(--blue);
  background: #f5f8ff;
}

.position-alert-card {
  border-left: 4px solid var(--red);
  background: #fff5f5;
}

.intraday-primary-card {
  border-left: 4px solid #2563eb;
  background: #f6f9ff;
}

.intraday-primary-card p strong {
  font-size: 16px;
}

.intraday-chart-wrap {
  margin-top: 10px;
  padding: 8px 8px 4px;
  border: 1px solid #dce6f7;
  border-radius: 8px;
  background: #ffffff;
}

.intraday-chart {
  display: block;
  width: 100%;
  height: 126px;
}

.intraday-grid-line {
  stroke: #dfe6ef;
  stroke-width: 1;
  stroke-dasharray: 4 4;
}

.intraday-price-line {
  fill: none;
  stroke-width: 2.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.intraday-price-line.up { stroke: var(--red); }
.intraday-price-line.down { stroke: var(--green); }

.intraday-axis {
  display: flex;
  justify-content: space-between;
  color: var(--muted);
  font-size: 11px;
}

.intraday-meta {
  margin-top: 8px;
  color: var(--muted) !important;
  font-size: 12px;
}

.intraday-empty {
  margin-top: 10px;
  padding: 12px;
  border: 1px dashed #b9c9e7;
  border-radius: 8px;
  color: var(--muted);
  background: #ffffff;
  font-size: 12px;
  line-height: 1.6;
}

.position-inline-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 10px;
}

.position-inline-actions .danger {
  border-color: #f0c4c4;
  color: #b42318;
  background: #fff7f7;
}

.main-panel {
  min-width: 0;
  padding: 18px;
}

.mobile-app-bar,
.mobile-sidebar-backdrop {
  display: none;
}

.top-strip {
  display: block;
  position: sticky;
  z-index: 20;
  top: 8px;
  margin-bottom: 12px;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.close-workspace-tools {
  display: block;
  margin: 7px 4px 0 auto;
  padding: 5px 10px;
  border: 1px solid #cad6e3;
  border-radius: 7px;
  background: #fff;
  color: #5d7085;
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
}
.close-workspace-tools[hidden] { display: none !important; }

/* v164: treat the TOP strategy board and stock tools as separate visual pages. */
body.workspace-open .top-strip {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 10px;
}

body.workspace-open .top-strip .source-tabs {
  min-width: 0;
}

body.workspace-open .close-workspace-tools {
  margin: 0;
  min-height: 42px;
  padding: 8px 14px;
  border-color: rgba(25, 156, 169, .46);
  border-radius: 10px;
  background: linear-gradient(135deg, rgba(255, 248, 247, .92), rgba(222, 248, 249, .86));
  color: #0d6470;
  box-shadow: 0 6px 16px rgba(20, 115, 126, .12), inset 0 1px 0 rgba(255, 255, 255, .9);
  white-space: nowrap;
  font-size: 13px;
}

body.workspace-open .close-workspace-tools:hover {
  border-color: #199ca9;
  color: #084b55;
  transform: translateY(-1px);
}

@media (max-width: 760px) {
  .top-strip { position: static; }
  body.workspace-open .top-strip {
    display: flex;
    flex-direction: column;
    align-items: stretch;
  }
  body.workspace-open .close-workspace-tools {
    order: -1;
    width: 100%;
  }
}

.daily-standards-panel {
  margin-bottom: 12px;
  padding: 14px;
  border: 1px solid #cfdcf0;
  border-left: 4px solid #2563eb;
  border-radius: 10px;
  background: linear-gradient(135deg, #ffffff 0%, #f5f9ff 100%);
  box-shadow: var(--shadow);
}

.daily-standards-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
}

.daily-standards-head span {
  color: #59708f;
  font-size: 12px;
  font-weight: 800;
}

.daily-standards-head h2 {
  margin: 3px 0 0;
  color: #162844;
  font-size: 20px;
}

.daily-standards-summary {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 6px 10px;
  color: #64748b;
  font-size: 12px;
}

.daily-standards-summary strong {
  color: #165c49;
  font-size: 14px;
}

.daily-standards-summary time {
  color: #7b8797;
}

.daily-ranking-tabs {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 7px;
  margin: 11px 0 8px;
  padding: 5px;
  border: 1px solid #d8e4f4;
  border-radius: 10px;
  background: #edf3fb;
}

.daily-ranking-tabs button {
  min-width: 0;
  padding: 8px 10px;
  border: 1px solid transparent;
  border-radius: 7px;
  background: transparent;
  color: #4b607c;
  font-size: 12px;
  font-weight: 900;
  cursor: pointer;
}

.daily-ranking-tabs button:hover,
.daily-ranking-tabs button:focus-visible {
  border-color: #a9c2ec;
  background: #f8fbff;
  outline: none;
}

.daily-ranking-tabs button.active {
  border-color: #87aef0;
  background: #ffffff;
  color: #1757c5;
  box-shadow: 0 3px 10px rgba(37, 99, 235, 0.12);
}

.daily-standards-rule {
  margin: 0;
  color: #5f6f84;
  font-size: 12px;
  line-height: 1.55;
}

.daily-standards-meta {
  margin: 8px 0 10px;
  border: 1px solid #d9e4f1;
  border-radius: 8px;
  background: rgba(247, 250, 255, 0.9);
}

.daily-standards-meta > summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 7px 10px;
  color: #315273;
  font-size: 11px;
  font-weight: 800;
  cursor: pointer;
  list-style: none;
}

.daily-standards-meta > summary::-webkit-details-marker { display: none; }
.daily-standards-meta > summary span::before { content: "＋"; margin-right: 5px; color: #2563eb; }
.daily-standards-meta[open] > summary span::before { content: "－"; }

.daily-standards-meta > summary em {
  overflow: hidden;
  color: #708197;
  font-style: normal;
  font-weight: 600;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.daily-standards-meta-body {
  display: grid;
  gap: 9px;
  padding: 9px 10px 10px;
  border-top: 1px solid #dfe8f3;
}

.daily-standards-pool-breakdown {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0;
  color: #64748b;
  font-size: 11px;
}

.daily-pool-chip {
  padding: 4px 7px;
  border: 1px solid #d7e2f2;
  border-radius: 999px;
  background: #ffffff;
  color: #51647e;
  font-weight: 800;
}

.daily-pool-chip.total {
  border-color: #9bb9ee;
  background: #eef5ff;
  color: #2055a8;
}

.daily-pool-chip.innovation {
  border-color: #9fcbbd;
  background: #ecfaf5;
  color: #0f6a54;
}

.daily-pool-chip.broad {
  border-color: #dcc5a1;
  background: #fff9ed;
  color: #855813;
}

.daily-standards-list {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
}

.daily-top-pool {
  min-width: 0;
  padding: 10px;
  border: 1px solid #d8e3f1;
  border-radius: 9px;
  background: rgba(255, 255, 255, 0.72);
  container-type: inline-size;
}

.daily-top-pool.innovation {
  border-left: 4px solid #16876c;
  background: linear-gradient(135deg, #f7fffc 0%, #eefaf6 100%);
}

.daily-top-pool.broad {
  border-left: 4px solid #bd7a16;
  background: linear-gradient(135deg, #fffefb 0%, #fff8ea 100%);
}

.daily-top-pool.technical {
  border-left: 4px solid #2563eb;
  background: linear-gradient(135deg, #f8fbff 0%, #edf4ff 100%);
}

.daily-top-pool.comprehensive {
  border-left: 4px solid #7c3aed;
  background: linear-gradient(135deg, #fbf9ff 0%, #f3efff 100%);
}

.daily-top-pool.growth {
  border-left: 4px solid #0f8a73;
  background: linear-gradient(135deg, #f7fffc 0%, #eaf8f3 100%);
}

.daily-top-pool-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 8px;
}

.daily-top-pool-head > div {
  display: grid;
  gap: 3px;
}

.daily-top-pool-head strong {
  color: #20334d;
  font-size: 15px;
}

.daily-top-pool-head span {
  max-width: 1100px;
  color: #68788e;
  font-size: 11px;
  line-height: 1.5;
}

.daily-top-pool-head > b {
  flex: 0 0 auto;
  min-width: 48px;
  padding: 4px 8px;
  border-radius: 999px;
  background: #eaf1ff;
  color: #1f5bc6;
  font-size: 12px;
  text-align: center;
}

.daily-top-pool.innovation .daily-top-pool-head > b {
  background: #dff5ed;
  color: #116d55;
}

.daily-top-pool.broad .daily-top-pool-head > b {
  background: #fff0cd;
  color: #8b5b06;
}

.daily-top-pool.technical .daily-top-pool-head > b {
  background: #dfebff;
  color: #2159bd;
}

.daily-top-pool.comprehensive .daily-top-pool-head > b {
  background: #ebe1ff;
  color: #6d2fc2;
}

.daily-top-pool.growth .daily-top-pool-head > b {
  background: #d8f3e9;
  color: #08715d;
}

.daily-top-pool-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.daily-standard-card {
  display: grid;
  grid-template-areas: "rank stock price k status";
  grid-template-columns: 30px minmax(130px, 1.05fr) 70px minmax(135px, 0.9fr) minmax(112px, 0.75fr);
  align-items: center;
  gap: 9px;
  min-width: 0;
  min-height: 76px;
  padding: 8px 10px;
  border: 1px solid #dce5f1;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.92);
  color: #263549;
  text-align: left;
  cursor: pointer;
}

.daily-standard-card.innovation {
  border-color: #cfe8df;
}

.daily-standard-card.broad {
  border-color: #eadfcb;
}

.daily-standard-card.technical {
  border-color: #cfddf5;
}

.daily-standard-card.comprehensive {
  border-color: #ddd0f5;
}

.daily-standard-card.growth {
  border-color: #c6e8dc;
}

.daily-standard-card.growth .daily-standard-k > small {
  background: #e6f7f1;
  color: #08715d;
}

.growth-research-section {
  border-left: 4px solid #0f8a73;
  background: #f7fffc;
}

.growth-research-section.pending {
  border-left-color: #b7791f;
  background: #fffdf5;
}

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

.growth-research-breakdown > div {
  padding: 10px;
  border: 1px solid #d8e8e2;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.9);
}

.growth-research-breakdown span,
.growth-research-breakdown p {
  display: block;
  margin: 0;
  color: #6d7888;
  font-size: 11px;
  line-height: 1.55;
}

.growth-research-breakdown strong {
  display: block;
  margin: 4px 0;
  color: #173f38;
  font-size: 13px;
}

.growth-research-note {
  margin: 9px 0 0;
  color: #617386;
  font-size: 11px;
  line-height: 1.6;
}

@media (max-width: 760px) {
  .growth-research-breakdown { grid-template-columns: 1fr; }
}

.daily-standard-card:hover,
.daily-standard-card:focus-visible {
  border-color: #77a4ee;
  background: #ffffff;
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.12);
  outline: none;
}

.daily-standard-rank {
  grid-area: rank;
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: #eaf1ff;
  color: #1e5ac8;
  font-size: 12px;
  font-weight: 900;
  align-self: center;
}

.daily-standard-stock,
.daily-standard-price,
.daily-standard-k {
  min-width: 0;
}

.daily-standard-stock {
  grid-area: stock;
  display: grid;
  gap: 2px;
}

.daily-standard-price {
  grid-area: price;
  display: grid;
  gap: 2px;
}

.daily-standard-k {
  grid-area: k;
  display: grid;
  gap: 2px;
}

.daily-standard-stock strong,
.daily-standard-k b {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.daily-standard-card small {
  color: #718096;
  font-size: 11px;
  font-weight: 600;
}

.daily-standard-price strong {
  color: #172033;
  font-size: 14px;
}

.daily-standard-price .up {
  color: var(--red);
}

.daily-standard-price .down {
  color: var(--green);
}

.daily-standard-k > small {
  width: fit-content;
  max-width: 100%;
  padding: 2px 5px;
  border-radius: 4px;
  background: #e7f7f1;
  color: #13735a;
  line-height: 1.35;
  white-space: normal;
}

.daily-standard-k b {
  font-size: 12px;
}

.daily-standard-status {
  grid-area: status;
  justify-self: end;
  width: fit-content;
  max-width: 145px;
  padding: 5px 7px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 900;
  line-height: 1.35;
  text-align: center;
  white-space: normal;
}

@container (max-width: 900px) {
  .daily-top-pool-grid {
    grid-template-columns: 1fr;
  }
}

@container (max-width: 720px) {
  .daily-standard-card {
    grid-template-areas:
      "rank stock price"
      "rank k k"
      "rank status status";
    grid-template-columns: 28px minmax(0, 1fr) 74px;
    gap: 6px 8px;
  }

  .daily-standard-rank {
    align-self: start;
  }

  .daily-standard-status {
    justify-self: start;
    max-width: none;
  }
}

.daily-standard-status.strong {
  background: #dff7ec;
  color: #116b50;
}

.daily-standard-status.near {
  background: #fff0c2;
  color: #8a5b00;
}

.daily-standard-status.watch {
  background: #edf1f6;
  color: #536175;
}

.daily-standards-empty {
  grid-column: 1 / -1;
  display: grid;
  gap: 4px;
  padding: 18px;
  border: 1px dashed #bfcde0;
  border-radius: 8px;
  color: #64748b;
  text-align: center;
}

.metric-tile, .search-box, .table-zone, .insight-zone {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.metric-tile {
  min-height: 72px;
  padding: 12px;
  color: var(--ink);
  text-align: left;
  cursor: pointer;
}

.metric-tile:hover,
.metric-tile.active {
  border-color: #8eace8;
  background: #f3f7ff;
}

.metric-tile span {
  display: block;
  color: var(--muted);
  font-size: 13px;
}

.metric-tile strong {
  display: block;
  margin-top: 6px;
  font-size: 26px;
  line-height: 1;
}

.search-box {
  display: flex;
  align-items: center;
  padding: 12px;
}

.search-box input {
  width: 100%;
  min-height: 44px;
  padding: 0 12px;
}

.market-regime-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 72px;
  margin: 0;
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-left: 4px solid #8b98a9;
  background: #ffffff;
  color: #344154;
  font-size: 13px;
}

.market-temperature-section .market-regime-bar {
  min-height: 0;
  padding: 9px 10px;
  flex-wrap: wrap;
  border-radius: 7px;
  background: #f8fafc;
  line-height: 1.5;
}

.market-temperature-section .regime-detail {
  width: 100%;
}

.seasonal-entry-tracker {
  margin-top: 10px;
  padding: 10px;
  border: 1px solid #d8e2ee;
  border-radius: 7px;
  background: #fff;
  color: #43536a;
  font-size: 12px;
  line-height: 1.55;
}

.seasonal-entry-tracker p { margin: 4px 0; }
.seasonal-entry-tracker ol { margin: 6px 0 0 18px; padding: 0; }
.seasonal-tracker-head { display: flex; justify-content: space-between; align-items: center; gap: 6px; color: #1e3657; }
.seasonal-phase, .sector-entry-status { display: inline-flex; align-items: center; border-radius: 999px; padding: 1px 7px; font-weight: 700; }
.seasonal-phase.active, .sector-entry-status.ready { background: #dff5e9; color: #08714c; }
.seasonal-phase.prepare, .sector-entry-status.prepare { background: #fff0c7; color: #8a5a00; }
.seasonal-phase.conditional, .sector-entry-status.conditional { background: #f3e8ff; color: #7e22ce; }
.seasonal-phase.off, .sector-entry-status.off { background: #edf1f6; color: #607086; }
.window-state-chip,
.window-action-chip {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  border-radius: 999px;
  padding: 2px 8px;
  font-size: 12px;
  font-weight: 750;
  line-height: 1.45;
}
.window-state-chip.confirmed { background: #dff5e9; color: #08714c; }
.window-state-chip.warming { background: #fff0c7; color: #8a5a00; }
.window-state-chip.fading { background: #ffe6d5; color: #a04413; }
.window-state-chip.closed { background: #edf1f6; color: #607086; }
.window-action-chip { background: #edf4ff; color: #245aa8; }
.window-action-chip.avoid { background: #f0f2f5; color: #5d6878; }
.window-action-chip.entry,
.window-action-chip.breakout { background: #dcf7eb; color: #08714c; }
.window-action-chip.pullback { background: #fff1c9; color: #8a5a00; }
.window-action-chip.position { background: #efe7ff; color: #6f35b5; }
.stock-window-state,
.window-action-line {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 6px;
}
.window-action-line { margin: 0 0 7px; }
.window-action-line b { color: #1f334d; font-size: 13px; }
.window-fusion-card { border-left: 4px solid #d3a11b; }
.window-fusion-card.confirmed { border-left-color: #16805a; background: #f3fbf7; }
.window-fusion-card.fading { border-left-color: #d2692e; background: #fff8f1; }
.window-fusion-card.closed { border-left-color: #7d8999; background: #f7f9fb; }
.seasonal-pool-summary {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 7px;
  padding: 8px 10px;
  border: 1px solid #dce5f0;
  border-radius: 8px;
  background: #f8fbff;
  color: #52637a;
  font-size: 12px;
}
.seasonal-pool-summary[hidden] { display: none; }
.seasonal-pool-summary strong { color: #1f334d; }
.seasonal-pool-summary span {
  padding: 2px 7px;
  border-radius: 999px;
  background: #ffffff;
  box-shadow: inset 0 0 0 1px #e5ebf2;
}
.seasonal-pool-summary button {
  min-height: 28px;
  padding: 4px 10px;
  border: 1px solid #d7e0ec;
  border-radius: 999px;
  background: #ffffff;
  color: #40536d;
  font: inherit;
  cursor: pointer;
  box-shadow: 0 1px 2px rgba(31, 51, 77, 0.05);
}
.seasonal-pool-summary button:hover,
.seasonal-pool-summary button:focus-visible {
  border-color: #5c88c7;
  background: #eef5ff;
  color: #174f9c;
  outline: none;
}
.seasonal-pool-summary button.active {
  border-color: #2c6ecb;
  background: #e8f1ff;
  color: #174f9c;
  font-weight: 700;
}
.sector-entry-status.wait { background: #e6efff; color: #2563c8; }
.seasonal-history { display: grid; gap: 2px; margin: 7px 0; padding: 7px; border-radius: 6px; background: #f4f7fb; color: #53657d; font-size: 11px; }
.seasonal-disclaimer { color: #748197; font-size: 11px; }

.seasonal-window-hero {
  margin-bottom: 12px;
  overflow: hidden;
  border: 1px solid #d6b45e;
  border-radius: 10px;
  background: linear-gradient(135deg, #fffdf6 0%, #fff8e7 48%, #f5f9ff 100%);
  box-shadow: 0 10px 28px rgba(86, 61, 8, 0.09);
}

.seasonal-window-hero .seasonal-entry-tracker {
  display: grid;
  grid-template-columns: minmax(230px, 0.8fr) minmax(440px, 2fr);
  gap: 8px 24px;
  margin: 0;
  padding: 18px 22px;
  border: 0;
  background: transparent;
  font-size: 14px;
  line-height: 1.65;
}

.seasonal-window-hero .seasonal-tracker-head {
  grid-column: 1 / -1;
  justify-content: flex-start;
  gap: 12px;
}

.seasonal-window-hero .seasonal-tracker-head strong {
  color: #172a46;
  font-size: 21px;
}

.seasonal-current-market {
  display: grid;
  grid-template-columns: minmax(190px, 0.65fr) minmax(260px, 0.9fr) minmax(360px, 1.5fr);
  grid-column: 1 / -1;
  align-items: center;
  gap: 14px 22px;
  padding: 15px 17px;
  border: 1px solid #e1bd61;
  border-left: 6px solid #9a6700;
  border-radius: 9px;
  background: #fff;
  box-shadow: 0 6px 18px rgba(86, 61, 8, 0.08);
}

.seasonal-current-market.confirmed { border-left-color: #16805a; background: #f3fbf7; }
.seasonal-current-market.open { border-left-color: #2563eb; background: #f5f8ff; }
.seasonal-current-market.conditional { border-left-color: #7e22ce; background: #fbf7ff; }
.seasonal-current-market.blocked { border-left-color: #cf3434; background: #fff6f6; }
.seasonal-current-market.fading { border-left-color: #d2692e; background: #fff8f1; }
.seasonal-current-market.prepare { border-left-color: #b7791f; background: #fffdf5; }
.seasonal-current-market.off { border-left-color: #7d8999; background: #f7f9fb; }

.annual-low-node-list {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-top: 8px;
}

.annual-low-node-list span {
  display: flex;
  gap: 6px;
  padding: 8px 10px;
  border: 1px solid #ead9b4;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.82);
  color: #596578;
}

.annual-low-node-list b { color: #8b5a12; white-space: nowrap; }

.seasonal-current-title {
  display: grid;
  gap: 2px;
}

.seasonal-current-title span {
  color: #7c6020;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.seasonal-current-title strong {
  color: #172a46;
  font-size: 22px;
}

.seasonal-current-facts {
  display: grid;
  gap: 3px;
  color: #56657a;
  font-size: 13px;
}

.seasonal-current-facts span:last-child {
  color: #8a5a00;
  font-weight: 800;
}

.seasonal-current-verdict b {
  color: #172a46;
  font-size: 16px;
}

.seasonal-current-verdict p { margin: 3px 0; }
.seasonal-current-verdict small { color: #6d7888; }

.seasonal-window-hero .seasonal-history {
  grid-column: 1 / -1;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin: 4px 0;
  padding: 10px;
  border: 1px solid rgba(214, 180, 94, 0.35);
  background: rgba(255, 255, 255, 0.72);
  font-size: 13px;
}

.seasonal-window-hero .seasonal-history span {
  padding: 3px 8px;
  border-left: 3px solid #d6b45e;
}

.seasonal-window-hero .seasonal-entry-tracker ol {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  grid-column: 1 / -1;
  gap: 10px 28px;
  margin: 3px 0 3px 22px;
}

.seasonal-window-hero .seasonal-disclaimer {
  grid-column: 1 / -1;
  font-size: 12px;
}

.seasonal-window-hero {
  overflow: visible;
  border: 0;
  background: transparent;
  box-shadow: none;
}

.seasonal-window-hero .seasonal-entry-tracker {
  display: block;
  padding: 0;
}

.seasonal-window-summary-card {
  display: grid;
  grid-template-columns: minmax(220px, 0.8fr) minmax(280px, 1.2fr) 34px;
  align-items: center;
  gap: 14px;
  width: 100%;
  min-height: 86px;
  padding: 12px 14px;
  border: 1px solid #d6b45e;
  border-left: 6px solid #9a6700;
  border-radius: 10px;
  background: linear-gradient(135deg, #fffdf7 0%, #fff9eb 60%, #f7faff 100%);
  color: #2b3c54;
  text-align: left;
  cursor: pointer;
  box-shadow: 0 6px 18px rgba(86, 61, 8, 0.07);
}

.seasonal-window-summary-card.confirmed { border-left-color: #16805a; background: #f3fbf7; }
.seasonal-window-summary-card.open { border-left-color: #2563eb; background: #f5f8ff; }
.seasonal-window-summary-card.conditional { border-left-color: #7e22ce; background: #fbf7ff; }
.seasonal-window-summary-card.blocked { border-left-color: #cf3434; background: #fff6f6; }
.seasonal-window-summary-card.fading { border-left-color: #d2692e; background: #fff8f1; }
.seasonal-window-summary-card.off { border-left-color: #7d8999; background: #f7f9fb; }

.seasonal-window-summary-card:hover,
.seasonal-window-summary-card:focus-visible {
  border-color: #8f6a15;
  background: #ffffff;
  outline: 2px solid rgba(37, 99, 235, 0.16);
  outline-offset: 2px;
}

.seasonal-window-summary-copy,
.seasonal-window-summary-status {
  display: grid;
  gap: 3px;
  min-width: 0;
}

.seasonal-window-summary-copy small {
  color: #7c6020;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.06em;
}

.seasonal-window-summary-copy strong {
  overflow: hidden;
  color: #172a46;
  font-size: 20px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.seasonal-window-summary-copy em {
  overflow: hidden;
  color: #64748b;
  font-size: 12px;
  font-style: normal;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.seasonal-window-summary-status {
  grid-template-columns: auto minmax(0, 1fr);
  align-items: center;
}

.seasonal-window-summary-status b {
  color: #213752;
  font-size: 14px;
}

.seasonal-window-summary-status small {
  grid-column: 1 / -1;
  overflow: hidden;
  color: #6d7b8d;
  font-size: 11px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.seasonal-window-summary-arrow {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border: 1px solid #d4deeb;
  border-radius: 8px;
  background: #ffffff;
  color: #2c5c99;
  font-size: 19px;
}

.seasonal-window-dialog {
  width: min(1040px, calc(100vw - 24px));
}

.seasonal-window-dialog-card,
.seasonal-window-dialog-body {
  display: grid;
  gap: 14px;
}

.seasonal-window-dialog-card {
  padding: 20px;
}

.seasonal-window-dialog-body .seasonal-tracker-head {
  justify-content: flex-start;
  gap: 10px;
}

.seasonal-window-dialog-body .seasonal-history {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin: 0;
  padding: 10px;
  border: 1px solid #e2e8f0;
  background: #f8fafc;
}

.seasonal-window-dialog-body .seasonal-history span {
  padding: 4px 7px;
  border-left: 3px solid #d6b45e;
}

.seasonal-window-dialog-body ol {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px 24px;
  margin: 0 0 0 20px;
  padding: 0;
  color: #40516a;
  font-size: 12px;
  line-height: 1.55;
}

.seasonal-window-dialog-body .seasonal-disclaimer {
  margin: 0;
  padding: 9px 10px;
  border-radius: 7px;
  background: #f8fafc;
  color: #748197;
  font-size: 11px;
  line-height: 1.55;
}

.seasonal-stock-context {
  margin-bottom: 7px;
  padding-bottom: 7px;
  border-bottom: 1px dashed #d9e1eb;
}

.seasonal-stock-context > strong {
  margin-left: 6px;
}

.decision-bars {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-bottom: 12px;
}

.market-regime-bar strong {
  color: var(--ink);
  font-size: 14px;
}

.market-regime-bar .regime-label {
  padding: 3px 7px;
  border-radius: 5px;
  background: #eef2f6;
  color: #445064;
  font-weight: 800;
}

.market-regime-bar.panic { border-left-color: var(--red); }
.market-regime-bar.weak { border-left-color: var(--amber); }
.market-regime-bar.active { border-left-color: var(--green); }
.market-regime-bar .regime-detail { color: var(--muted); }

.right-side-decision-bar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 18px;
  min-height: 82px;
  margin: 0;
  padding: 12px 14px;
  border: 1px solid #e7c46d;
  border-left: 6px solid var(--red);
  background: #fffaf0;
  box-shadow: 0 8px 24px rgba(86, 61, 8, 0.08);
}

.left-side-decision-bar {
  border-color: #a8d5c6;
  border-left-color: #1f6d5a;
  background: #f3fbf7;
  box-shadow: 0 8px 24px rgba(31, 109, 90, 0.08);
}

.left-side-decision-bar .right-side-eyebrow,
.left-side-decision-bar .right-side-count strong {
  color: #155a49;
}

.right-side-decision-copy {
  display: grid;
  min-width: 0;
  gap: 4px;
}

.right-side-eyebrow {
  color: #8b1d1d;
  font-size: 12px;
  font-weight: 800;
}

.right-side-decision-copy strong {
  font-size: 20px;
  line-height: 1.35;
}

.right-side-decision-copy > span:last-child {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.5;
}

.right-side-decision-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.right-side-count {
  display: grid;
  min-width: 72px;
  gap: 3px;
  text-align: center;
}

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

.right-side-count strong {
  color: #8b1d1d;
  font-size: 24px;
}

#openRightSideButton {
  min-height: 38px;
  padding: 0 13px;
  border: 0;
  border-radius: 6px;
  background: #8b1d1d;
  color: #ffffff;
  font-weight: 800;
  cursor: pointer;
}

#openLeftSideButton {
  min-height: 38px;
  padding: 0 13px;
  border: 0;
  border-radius: 6px;
  background: #1f6d5a;
  color: #ffffff;
  font-weight: 800;
  cursor: pointer;
}

.workspace-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 16px;
}

.workspace-grid.insight-collapsed {
  grid-template-columns: minmax(0, 1fr) 48px;
}

.table-zone, .insight-zone {
  min-width: 0;
  overflow: hidden;
}

.zone-head {
  min-height: 58px;
  padding: 12px 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-bottom: 1px solid var(--line);
}

.zone-head.stacked {
  align-items: stretch;
  flex-direction: column;
}

.workspace-tabs {
  display: inline-flex;
  align-self: flex-start;
  gap: 4px;
  padding: 4px;
  background: #e8edf3;
  border-radius: 8px;
}

.workspace-tabs button {
  min-height: 34px;
  padding: 0 12px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: #445064;
  font-weight: 800;
  cursor: pointer;
}

.workspace-tabs button.active {
  background: #ffffff;
  color: var(--ink);
  box-shadow: 0 1px 4px rgba(0,0,0,0.12);
}

.workspace-tabs button[data-workspace="rightSide"].active {
  background: #8b1d1d;
  color: #ffffff;
}

.workspace-tabs button[data-workspace="leftSide"].active {
  background: #1f6d5a;
  color: #ffffff;
}

.right-side-filters,
.left-side-filters,
#rightStockCodeLocator,
#leftStockCodeLocator,
#headFilters,
#individualQualityFilters {
  display: none;
}

.individual-quality-filters {
  border-left: 3px solid #b8871b;
  background: #fff9eb;
}

.individual-quality-filters .filter-row-title {
  color: #76540c;
}

.stock-code-locator {
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  padding: 10px 12px;
  border: 1px solid #dce3eb;
  border-radius: 8px;
  background: #f8fafc;
}

.stock-code-locator label {
  color: #344154;
  font-size: 13px;
  font-weight: 800;
}

.stock-code-locator input {
  width: 180px;
  min-height: 36px;
  padding: 0 10px;
  font-variant-numeric: tabular-nums;
}

.stock-code-locator button {
  min-height: 36px;
  padding: 0 12px;
}

.stock-code-locator button.secondary {
  border-color: #cfd7e2;
  background: #ffffff;
  color: #445064;
}

.stock-code-locator span {
  color: var(--muted);
  font-size: 12px;
}

.precise-stock-kline-panel {
  margin-top: 10px;
  padding: 12px;
  border: 1px solid #d8e2ef;
  border-radius: 10px;
  background: #ffffff;
  box-shadow: 0 5px 16px rgba(33, 57, 87, 0.07);
}

.precise-stock-kline-panel[hidden] {
  display: none;
}

.precise-stock-kline-head {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 9px;
}

.precise-stock-kline-head div {
  display: grid;
  gap: 2px;
}

.precise-stock-kline-head small,
.precise-stock-kline-head span {
  color: #728299;
  font-size: 11px;
}

.precise-stock-kline-head strong {
  color: #1e2d42;
  font-size: 17px;
}

.precise-stock-kline-metrics {
  display: grid;
  gap: 8px;
  margin-bottom: 10px;
}

.precise-metric-row {
  display: grid;
  gap: 8px;
}

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

.precise-metric-row.boll-row {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.precise-metric-card {
  display: grid;
  gap: 3px;
  padding: 9px 10px;
  border-radius: 8px;
  background: #f5f8fc;
}

.precise-stock-kline-metrics small,
.precise-stock-kline-metrics span {
  color: #718096;
  font-size: 11px;
}

.precise-stock-kline-metrics strong {
  color: #1f5f8f;
  font-size: 16px;
  font-variant-numeric: tabular-nums;
}

.precise-metric-card.boll strong {
  color: #15715b;
  font-size: 13px;
  line-height: 1.4;
}

.zone-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.source-tabs {
  display: inline-flex;
  width: 100%;
  gap: 8px;
  padding: 4px;
  background: #eef2f6;
  border-radius: 8px;
}

.top-strip .source-tab-group {
  flex: 1 1 0;
}

.top-strip .source-tab-group > span {
  color: #344154;
  font-size: 13px;
}

.top-strip .source-tab-group > div {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(112px, 1fr));
}

.top-strip .source-tabs button {
  min-height: 40px;
  font-size: 14px;
  font-weight: 800;
}

.top-strip .entry-nav-group {
  border-color: #e7c46d;
  background: #fffaf0;
}

.top-strip .entry-nav-group button.active {
  background: #8b1d1d;
  color: #fff;
}

.entry-action-plan {
  display: grid;
  gap: 5px;
}

.action-plan-step {
  display: grid;
  grid-template-columns: 20px minmax(0, 1fr);
  gap: 6px;
  align-items: start;
  line-height: 1.45;
}

.action-plan-step b {
  display: grid;
  place-items: center;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #eef2f6;
  color: #344154;
  font-size: 11px;
}

.source-tab-group {
  display: grid;
  gap: 3px;
  padding: 4px;
  border: 1px solid #d8e0e9;
  border-radius: 7px;
  background: rgba(255,255,255,0.5);
}

.source-tab-group > span {
  padding: 0 7px;
  color: #7a8595;
  font-size: 10px;
  font-weight: 800;
}

.source-tab-group > div { display: flex; gap: 3px; }

.source-tabs button {
  border: 0;
  min-height: 34px;
  padding: 0 12px;
  border-radius: 6px;
  color: #445064;
  background: transparent;
  cursor: pointer;
  font-weight: 700;
}

.source-tabs button.active {
  background: #ffffff;
  color: var(--ink);
  box-shadow: 0 1px 4px rgba(0,0,0,0.12);
}

.holder-person-filters {
  width: 100%;
  max-width: 100%;
  justify-content: flex-start;
  gap: 6px;
  overflow-x: auto;
  overscroll-behavior-inline: contain;
  scrollbar-width: thin;
  padding: 7px;
  background: linear-gradient(90deg, rgba(255, 248, 248, .82), rgba(236, 252, 253, .76));
  border: 1px solid rgba(181, 49, 65, .16);
}

.holder-person-filters button {
  flex: 0 0 auto;
  min-width: 92px;
  white-space: nowrap;
}

.holder-person-filters button small {
  margin-left: 4px;
  font-size: .76em;
  font-weight: 600;
  opacity: .72;
}

.power-chain-evidence p {
  margin: 5px 0;
  line-height: 1.55;
}

.power-chain-evidence a {
  color: #087784;
  font-weight: 700;
  text-decoration: none;
}

.power-chain-evidence a:hover { text-decoration: underline; }

.power-evidence-head {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 6px;
}

.power-evidence-head small { color: #718198; }

.power-tier {
  display: inline-flex;
  align-items: center;
  min-height: 23px;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
}

.power-tier.core {
  color: #08745f;
  border: 1px solid rgba(20, 149, 117, .25);
  background: rgba(215, 247, 236, .84);
}

.power-tier.watch {
  color: #9a6300;
  border: 1px solid rgba(197, 137, 24, .25);
  background: rgba(255, 244, 207, .86);
}

.power-chain-evidence .performance-line {
  padding: 6px 8px;
  border-left: 3px solid rgba(20, 126, 138, .58);
  border-radius: 0 7px 7px 0;
  background: rgba(232, 248, 249, .68);
  color: #244c62;
  font-weight: 700;
}

.segmented {
  display: inline-flex;
  gap: 4px;
  padding: 4px;
  background: #eef2f6;
  border-radius: 8px;
}

.segmented button {
  border: 0;
  min-height: 32px;
  padding: 0 12px;
  border-radius: 6px;
  color: #445064;
  background: transparent;
  cursor: pointer;
}

.segmented button.active {
  background: #ffffff;
  color: var(--ink);
  box-shadow: 0 1px 4px rgba(0,0,0,0.12);
}

.filter-row-title {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 0 10px 0 6px;
  border-right: 1px solid #d8e0ea;
  color: #34475f;
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
}

.observation-filters {
  display: flex;
  width: 100%;
  max-width: 100%;
  border-left: 3px solid #2563eb;
  background: #f5f8ff;
}

.observation-tech-category-filters {
  display: flex;
  width: calc(100% - 18px);
  max-width: calc(100% - 18px);
  align-items: center;
  gap: 2px;
  margin-left: 18px;
  padding: 3px;
  border-left: 2px solid #6957c8;
  background: #f7f5ff;
  overflow-x: auto;
  overflow-y: hidden;
  scrollbar-width: thin;
  scrollbar-color: #c7c1e8 transparent;
}

.observation-tech-category-filters .filter-row-title {
  position: sticky;
  left: 0;
  z-index: 1;
  min-height: 28px;
  padding: 0 8px 0 5px;
  background: #f7f5ff;
  font-size: 11px;
}

.observation-tech-category-filters button {
  flex: 0 0 auto;
  min-width: max-content;
  min-height: 28px;
  padding: 0 8px;
  font-size: 11px;
  line-height: 1.2;
  white-space: nowrap;
}

.observation-tech-category-filters[hidden] {
  display: none;
}

.observation-entry-filters {
  display: flex;
  flex-wrap: wrap;
  border-left: 3px solid #0f766e;
  background: #effcf8;
}

.metric-ready-help {
  align-self: center;
  margin-left: auto;
  padding: 0 8px;
  color: #617286;
  font-size: 11px;
  white-space: nowrap;
}

.observation-stage-panel {
  display: grid;
  gap: 5px;
  width: calc(100% - 36px);
  margin-left: 36px;
  padding: 4px;
  border: 1px solid #cfe3df;
  border-radius: 9px;
  background: #f6fcfa;
}

.observation-stage-panel > .segmented {
  width: 100%;
  max-width: 100%;
}

.observation-window-filters {
  border-left: 3px solid #b7791f;
  background: #fff9ec;
}

.observation-window-submenu {
  width: calc(100% - 26px) !important;
  margin-left: 26px;
  border-left-width: 2px;
  background: #fffaf0;
  transform: scale(0.97);
  transform-origin: left top;
}

.observation-filter-path {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  width: calc(100% - 72px);
  margin-left: 72px;
  padding: 7px 10px;
  border: 1px solid #bfd3ee;
  border-radius: 8px;
  background: #f3f8ff;
  color: #40536d;
  font-size: 12px;
}

.observation-filter-path[hidden] { display: none; }
.observation-filter-path strong { color: #174f9c; white-space: nowrap; }
.observation-filter-path span { color: #253b57; }
.observation-filter-path b { color: #6d84a2; }
.observation-filter-path em { color: #6d7d92; font-style: normal; }

.observation-structure strong,
.observation-score strong {
  color: #172033;
}

.individual-observation-metrics {
  display: grid;
  gap: 7px;
  min-width: 220px;
}

.detail-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  min-width: 0;
}

.detail-section-head small {
  color: #6b7b91;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .04em;
}

.detail-section-head > strong {
  color: #173b6d;
  font-size: 12px;
  line-height: 1.35;
  text-align: right;
}

.k-data-basis {
  color: #6c7c91;
  font-size: 10px;
  line-height: 1.35;
}

.k-data-basis.completed {
  color: #08745b;
  font-weight: 800;
}

.k-data-basis.pending { color: #9a6b0b; }
.k-data-basis.intraday { color: #6f7f95; }

.metric-source-line {
  display: grid;
  gap: 2px;
  padding-top: 5px;
  border-top: 1px dashed #dce4ed;
  color: #718096;
  font-size: 10px;
  line-height: 1.4;
}

.metric-source-line .k-data-basis {
  margin: 0;
}

.price-k-priority {
  width: max-content;
  max-width: 100%;
  padding: 3px 8px;
  border: 1px solid #9bdcc5;
  border-radius: 999px;
  background: #dff7ec;
  color: #08745b;
  font-size: 11px;
  font-weight: 800;
  line-height: 1.3;
}

.k-priority-band {
  width: max-content;
  max-width: 100%;
  padding: 3px 8px;
  border-radius: 999px;
  background: #eef2f7;
  color: #65758b;
  font-size: 11px;
  font-weight: 700;
  line-height: 1.3;
}

.k-priority-band.first {
  background: #dff7ec;
  color: #08745b;
}

.k-priority-band.second {
  background: #fff1c8;
  color: #895d00;
}

.k-priority-band.pending {
  background: #edf0f4;
  color: #77859a;
}

.indicator-k-row,
.indicator-boll-row,
.indicator-chip-row {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.indicator-boll {
  display: grid;
  grid-template-columns: auto auto;
  align-items: baseline;
  gap: 2px 5px;
  min-width: 128px;
  padding: 5px 7px;
  border: 1px solid #dce4ed;
  border-radius: 7px;
  background: #f7fafc;
  font-variant-numeric: tabular-nums;
}

.indicator-boll small {
  color: #718096;
  font-size: 10px;
}

.indicator-boll strong {
  font-size: 12px;
}

.indicator-boll em {
  grid-column: 1 / -1;
  color: #718096;
  font-size: 10px;
  font-style: normal;
}

.indicator-k {
  display: grid;
  grid-template-columns: auto auto;
  align-items: baseline;
  gap: 5px;
  min-width: 60px;
  padding: 5px 7px;
  border: 1px solid #dce4ed;
  border-radius: 7px;
  background: #f7f9fc;
  color: #344154;
  font-variant-numeric: tabular-nums;
}

.indicator-k small {
  color: #718096;
  font-size: 10px;
}

.indicator-k strong {
  font-size: 13px;
}

.indicator-chip {
  display: inline-flex;
  align-items: center;
  min-height: 21px;
  padding: 2px 6px;
  border-radius: 999px;
  background: #edf1f6;
  color: #566174;
  font-size: 10px;
  line-height: 1.35;
}

.indicator-k.target,
.indicator-boll.target,
.indicator-chip.target {
  border-color: #a9d9c6;
  background: #e3f7ef;
  color: #07634c;
}

.indicator-k.low,
.indicator-boll.low,
.indicator-chip.low {
  border-color: #c9d7eb;
  background: #edf4ff;
  color: #255b9d;
}

.indicator-k.high,
.indicator-boll.high,
.indicator-chip.high {
  border-color: #edb8b8;
  background: #fff0f0;
  color: #a32727;
}

.indicator-k.pending,
.indicator-boll.pending,
.indicator-chip.pending {
  border-style: dashed;
  background: #f5f6f8;
  color: #8791a0;
}

.workspace-grid.individual-observation-workspace:not(.right-side-workspace) .table-wrap table {
  min-width: 1680px;
  table-layout: fixed;
}

.workspace-grid.individual-observation-workspace:not(.right-side-workspace) th:nth-child(1) { width: 135px; }
.workspace-grid.individual-observation-workspace:not(.right-side-workspace) th:nth-child(2) { width: 92px; }
.workspace-grid.individual-observation-workspace:not(.right-side-workspace) th:nth-child(3) { width: 92px; }
.workspace-grid.individual-observation-workspace:not(.right-side-workspace) th:nth-child(4) { width: 105px; }
.workspace-grid.individual-observation-workspace:not(.right-side-workspace) th:nth-child(5) { width: 275px; }
.workspace-grid.individual-observation-workspace:not(.right-side-workspace) th:nth-child(6) { width: 245px; }
.workspace-grid.individual-observation-workspace:not(.right-side-workspace) th:nth-child(7) { width: 300px; }
.workspace-grid.individual-observation-workspace:not(.right-side-workspace) th:nth-child(8) { width: 300px; }
.workspace-grid.individual-observation-workspace:not(.right-side-workspace) th:nth-child(9) { width: 155px; }

.workspace-grid.individual-observation-workspace:not(.right-side-workspace) td {
  white-space: normal;
  overflow-wrap: anywhere;
  vertical-align: top;
}

.entry-decision-cell {
  display: grid;
  gap: 5px;
  min-width: 260px;
}

.entry-decision-emphasis {
  padding: 9px 10px;
  border: 1px solid #d9e3ef;
  border-left: 4px solid #7395bf;
  border-radius: 9px;
  background: #fbfdff;
}

.entry-decision-emphasis.strong { border-left-color: #12926f; background: #f3fcf8; }
.entry-decision-emphasis.near { border-left-color: #d29b18; background: #fffbf1; }
.entry-decision-emphasis.risk { border-left-color: #ce4b4b; background: #fff7f7; }
.entry-decision-emphasis.pending { border-left-color: #8a97a8; background: #f7f9fb; }

.decision-focus,
.action-focus {
  display: grid;
  grid-template-columns: 60px minmax(0, 1fr);
  gap: 7px;
  align-items: start;
  padding: 6px 7px;
  border-radius: 7px;
  background: #f1f5f9;
  font-size: 11px;
  line-height: 1.45;
}

.decision-focus b,
.action-focus b {
  color: #48627f;
  white-space: nowrap;
}

.decision-focus.next,
.action-focus.primary { background: #edf7ff; }
.decision-focus.next b,
.action-focus.primary b { color: #17629b; }
.decision-focus.risk,
.action-focus.risk { background: #fff0f0; }
.decision-focus.risk b,
.action-focus.risk b { color: #a62d2d; }

.entry-action-summary,
.individual-quality-cell {
  display: grid;
  gap: 7px;
}

.finance-gate-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 7px 9px;
  border-radius: 8px;
  background: #eef2f7;
}

.finance-gate-head small { color: #617087; font-weight: 800; }
.finance-gate-head strong { font-size: 12px; }
.finance-gate-head.pass { color: #08745b; background: #e3f7ef; }
.finance-gate-head.fail { color: #a32727; background: #fff0f0; }
.finance-gate-head.pending { color: #7a6535; background: #fff7df; }

.finance-gate-grid {
  display: grid;
  gap: 5px;
}

.finance-gate-item {
  display: grid;
  grid-template-columns: 62px minmax(0, 1fr);
  gap: 7px;
  align-items: start;
  padding-left: 7px;
  border-left: 3px solid #bdc7d3;
  font-size: 11px;
  line-height: 1.4;
}

.finance-gate-item b { color: #41536a; }
.finance-gate-item.pass { border-left-color: #2aa47f; }
.finance-gate-item.fail { border-left-color: #d34d4d; }
.finance-gate-item.fail b,
.finance-gate-item.fail span { color: #a32727; }
.finance-gate-item.pending { border-left-color: #d2a037; }
.finance-report-date { color: #7b8798; font-size: 10px; }

.valuation-divider {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #6c7c91;
  font-size: 10px;
  font-weight: 800;
}

.valuation-divider::after {
  content: "";
  flex: 1;
  border-top: 1px solid #e0e6ee;
}

.entry-time {
  color: #172033;
  font-size: 12px;
  line-height: 1.5;
}

.entry-invalidation,
.entry-primary-risk {
  color: #9b2525 !important;
}

.entry-order-rank {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 8px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
}

.entry-order-rank.rank-1 {
  color: #8b1d1d;
  background: #ffe5e5;
}

.entry-order-rank.rank-2 {
  color: #785000;
  background: #fff0bf;
}

.entry-order-rank.rank-3 {
  color: #075f46;
  background: #dff7ec;
}

.entry-order-rank.rank-4,
.entry-order-rank.rank-5 {
  color: #4f5664;
  background: #e9edf3;
}

.entry-proximity-score {
  display: flex;
  align-items: baseline;
  gap: 3px;
  margin-top: 7px;
  color: #344154;
}

.entry-proximity-score strong {
  color: #174f9c;
  font-size: 22px;
  line-height: 1;
}

.entry-proximity-score span {
  font-size: 11px;
  white-space: nowrap;
}

.entry-primary-card {
  border-left: 4px solid #64748b;
  background: #f8fafc;
}

.entry-primary-card.strong {
  border-left-color: #c62828;
  background: #fff7f7;
}

.entry-primary-card.near {
  border-left-color: #d18b00;
  background: #fffaf0;
}

.entry-primary-card.watch {
  border-left-color: #168064;
  background: #f3fbf7;
}

.entry-primary-time {
  color: #172033 !important;
  font-size: 15px !important;
  font-weight: 800;
}

.theme-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-bottom: 4px;
}

.theme-chip {
  display: inline-flex;
  align-items: center;
  padding: 2px 6px;
  border-radius: 999px;
  color: #1d4ed8;
  background: #dbeafe;
  font-size: 11px;
  line-height: 1.4;
}

.leader-evidence {
  color: #8a5a00;
}

.table-scroll-controls {
  display: flex;
  justify-content: flex-end;
  gap: 6px;
}

.table-scroll-controls button {
  width: 34px;
  height: 30px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #ffffff;
  color: #344154;
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
}

.table-scroll-controls button:hover:not(:disabled) {
  border-color: #9db7ee;
  background: #edf4ff;
  color: var(--blue);
}

.table-scroll-controls button:disabled {
  cursor: default;
  opacity: 0.35;
}

.table-wrap {
  max-height: calc(100vh - 160px);
  overflow: auto;
  scroll-behavior: auto;
  overscroll-behavior: contain;
}

table {
  width: 100%;
  min-width: 1280px;
  border-collapse: collapse;
  font-size: 13px;
}

th, td {
  padding: 11px 10px;
  text-align: left;
  border-bottom: 1px solid #edf1f5;
  vertical-align: middle;
  white-space: nowrap;
}

th {
  position: sticky;
  top: 0;
  z-index: 1;
  color: var(--muted);
  background: #fafbfd;
  font-weight: 600;
}

.th-sort {
  border: 0;
  padding: 0;
  color: inherit;
  background: transparent;
  cursor: pointer;
  font-weight: 700;
}

.th-sort.active {
  color: var(--blue);
}

.kdj-sort-button {
  display: block;
  width: max-content;
  margin-top: 5px;
  padding: 3px 7px;
  border: 1px solid #cbd8ea;
  border-radius: 999px;
  background: #fff;
  color: #52647a;
  font-size: 11px;
  line-height: 1.2;
  white-space: nowrap;
}

.kdj-sort-button.active {
  border-color: #2f6fff;
  background: #edf4ff;
  color: #1955cc;
}

.kdj-sort-button[hidden] {
  display: none;
}

tbody tr {
  cursor: pointer;
}

tbody tr:hover, tbody tr.selected {
  background: #f1f6ff;
}

tbody tr.right-side-ready-row {
  box-shadow: inset 4px 0 0 #cf3434;
}

tbody tr.left-side-ready-row {
  box-shadow: inset 4px 0 0 #1f6d5a;
}

tbody tr.trade-transition-row {
  box-shadow: inset 4px 0 0 #5d55c7;
}

.stock-name {
  display: grid;
  gap: 3px;
}

.stock-name-title {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-items: start;
  gap: 5px;
  min-width: 0;
}

.stock-name-title > strong {
  overflow: visible;
  line-height: 1.35;
  overflow-wrap: break-word;
  text-overflow: clip;
  white-space: normal;
}

.stock-name strong {
  font-size: 14px;
}

.stock-name span, .subline {
  color: var(--muted);
  font-size: 12px;
}

.stock-industry {
  width: max-content;
  max-width: 150px;
  overflow: hidden;
  padding: 3px 7px;
  border-radius: 999px;
  background: #edf4ff;
  color: #315f9e;
  font-size: 11px;
  font-style: normal;
  line-height: 1.3;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.stock-kline-button {
  width: max-content;
  border: 1px solid #9fc3f5;
  border-radius: 999px;
  background: #f5f9ff;
  color: #1f5fae;
  padding: 3px 9px;
  font: inherit;
  font-size: 11px;
  line-height: 1.3;
  cursor: pointer;
}

.stock-kline-button:hover,
.stock-kline-button:focus-visible {
  border-color: #2876dd;
  background: #eaf3ff;
}

.tag {
  display: inline-flex;
  align-items: center;
  min-height: 22px;
  padding: 0 7px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 700;
}

.tag.strong { color: #8b1d1d; background: #ffe5e5; }
.tag.near { color: #785000; background: #fff0bf; }
.tag.watch { color: #075f46; background: #dff7ec; }
.tag.risk { color: #4f5664; background: #e9edf3; }

.strategy-label.strong { color: #8b1d1d; }
.strategy-label.near { color: #785000; }
.strategy-label.watch { color: #075f46; }
.strategy-label.risk { color: #4f5664; }

.right-side-primary-card {
  border-left: 4px solid var(--red);
  background: #fff8f0;
}

.left-side-primary-card {
  border-left: 4px solid #1f6d5a;
  background: #f3fbf7;
}

.left-side-primary-card p strong {
  color: #155a49;
  font-size: 16px;
}

.trade-lifecycle-card {
  border-left: 4px solid #5d55c7;
  background: #f7f6ff;
}

.trade-lifecycle-card p strong {
  color: #4338a8;
  font-size: 16px;
}

.right-side-primary-card p strong {
  color: #8b1d1d;
  font-size: 16px;
}

.red { color: var(--red); }
.green { color: var(--green); }
.blue { color: var(--blue); }
.amber { color: var(--amber); }

.score {
  font-weight: 800;
}

.insight-zone {
  display: flex;
  flex-direction: column;
  max-height: calc(100vh - 34px);
  align-self: start;
  overflow-x: hidden;
  overflow-y: auto;
  position: sticky;
  top: 12px;
}

.workspace-grid.insight-collapsed .insight-zone {
  min-height: 460px;
}

.workspace-grid.insight-collapsed .insight-zone .zone-head {
  justify-content: center;
  min-height: 100%;
  padding: 10px 8px;
  border-bottom: 0;
}

.workspace-grid.insight-collapsed .insight-zone h2,
.workspace-grid.insight-collapsed .insight-zone #selectedTag,
.workspace-grid.insight-collapsed .insight-zone .insight-body,
.workspace-grid.insight-collapsed .insight-zone .sector-board {
  display: none;
}

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

#selectedTag {
  color: var(--muted);
  font-size: 13px;
}

.insight-body {
  flex: 0 0 auto;
  padding: 14px;
  display: grid;
  gap: 12px;
  overflow: visible;
}

.insight-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
  background: #fbfcfe;
}

.insight-card h3 {
  margin: 0 0 8px;
  font-size: 14px;
}

.insight-card p {
  color: #344154;
  line-height: 1.65;
  font-size: 13px;
}

.workspace-grid.right-side-workspace {
  grid-template-columns: minmax(0, 1fr) 380px;
}

.workspace-grid.right-side-workspace.insight-collapsed {
  grid-template-columns: minmax(0, 1fr) 48px;
}

/* Entry decisions contain multi-line action plans.  Fixed column budgets keep
   the rank badge, trigger text and plan in their own cells instead of letting
   long text paint over the next column when the table is scrolled. */
.workspace-grid.right-side-workspace .table-wrap table {
  min-width: 1760px;
  table-layout: fixed;
}

.workspace-grid.right-side-workspace th:nth-child(1) { width: 132px; }
.workspace-grid.right-side-workspace th:nth-child(2) { width: 92px; }
.workspace-grid.right-side-workspace th:nth-child(3) { width: 96px; }
.workspace-grid.right-side-workspace th:nth-child(4) { width: 105px; }
.workspace-grid.right-side-workspace th:nth-child(5) { width: 285px; }
.workspace-grid.right-side-workspace th:nth-child(6) { width: 235px; }
.workspace-grid.right-side-workspace th:nth-child(7) { width: 285px; }
.workspace-grid.right-side-workspace th:nth-child(8) { width: 310px; }
.workspace-grid.right-side-workspace th:nth-child(9) { width: 160px; }

.workspace-grid.right-side-workspace td {
  white-space: normal;
  overflow-wrap: anywhere;
  vertical-align: top;
}

.workspace-grid.right-side-workspace .entry-order-rank {
  width: max-content;
  max-width: 100%;
  white-space: nowrap;
}

.workspace-grid.right-side-workspace .action-plan-step span {
  min-width: 0;
  overflow-wrap: anywhere;
}

.right-side-cell-reason {
  margin-top: 6px;
  color: #344154;
  font-size: 12px;
  line-height: 1.5;
}

.right-side-level {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
  min-width: 112px;
  padding: 3px 0;
}

.right-side-level span {
  color: var(--muted);
  font-size: 11px;
}

.right-side-level.entry strong { color: #9f2020; }
.right-side-level.stop strong,
.right-side-risk-text { color: #b42318; }

.right-side-next-action {
  max-width: 280px;
  color: #26364a;
  font-weight: 700;
  line-height: 1.5;
}

.right-side-decision-hero {
  overflow: hidden;
  border: 1px solid #e6c5c5;
  border-radius: 10px;
  background: #fff8f7;
  box-shadow: 0 8px 24px rgba(115, 31, 31, 0.08);
}

.right-side-decision-hero.ready { border-color: #d8a448; background: #fffaf0; }
.right-side-decision-hero.breakout { border-color: #98b5e7; background: #f6f9ff; }
.right-side-decision-hero.wash { border-color: #9bcbb9; background: #f4fbf8; }
.right-side-decision-hero.anchor { border-color: #d7dde6; background: #f8fafc; }
.right-side-decision-hero.risk { border-color: #e5aaaa; background: #fff5f5; }

.right-side-hero-top {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 9px;
  padding: 13px 14px 0;
}

.right-side-hero-top span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 800;
}

.right-side-hero-top strong {
  font-size: 18px;
  line-height: 1.3;
}

.right-side-hero-top b {
  padding: 4px 7px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.85);
  color: #8b1d1d;
  font-size: 12px;
}

.right-side-action {
  margin: 10px 14px 0;
  color: #1c2b3d;
  font-size: 15px;
  font-weight: 800;
  line-height: 1.5;
}

.right-side-reason {
  margin: 5px 14px 12px;
  color: #5f6b7a;
  font-size: 12px;
  line-height: 1.55;
}

.right-side-price-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border-top: 1px solid rgba(117, 94, 94, 0.13);
  border-bottom: 1px solid rgba(117, 94, 94, 0.13);
  background: rgba(255, 255, 255, 0.72);
}

.right-side-price-grid > div {
  min-width: 0;
  padding: 11px 12px;
  border-right: 1px solid rgba(117, 94, 94, 0.13);
}

.right-side-price-grid > div:last-child { border-right: 0; }
.right-side-price-grid span { display: block; color: var(--muted); font-size: 10px; }
.right-side-price-grid strong { display: block; margin-top: 4px; font-size: 18px; }
.right-side-price-grid .stop strong { color: #b42318; }

.right-side-next-trigger {
  padding: 10px 14px;
  color: #344154;
  font-size: 12px;
  font-weight: 700;
  line-height: 1.5;
}

.right-side-process {
  padding: 13px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #ffffff;
}

.right-side-process > h3 {
  margin: 0 0 10px;
  font-size: 14px;
}

.right-side-step {
  position: relative;
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) auto;
  align-items: center;
  gap: 9px;
  min-height: 62px;
  padding: 9px 0;
}

.right-side-step + .right-side-step { border-top: 1px solid #edf0f4; }

.step-number {
  display: grid;
  width: 27px;
  height: 27px;
  place-items: center;
  border-radius: 50%;
  background: #e9edf3;
  color: #536073;
  font-size: 12px;
  font-weight: 900;
}

.right-side-step.complete .step-number { background: #dff5ea; color: #126247; }
.right-side-step.active .step-number { background: #ffe5e5; color: #9f2020; }
.right-side-step.failed .step-number { background: #fee4e2; color: #b42318; }
.right-side-step.locked { opacity: 0.58; }

.right-side-step strong { font-size: 13px; }
.right-side-step p { margin-top: 3px; color: var(--muted); font-size: 11px; line-height: 1.45; }
.right-side-step em { color: #5f6b7a; font-size: 11px; font-style: normal; font-weight: 800; }
.right-side-step.complete em { color: #126247; }
.right-side-step.active em,
.right-side-step.failed em { color: #9f2020; }

.right-side-checklist {
  display: grid;
  gap: 8px;
}

.right-side-checklist > div {
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-left-width: 4px;
  border-radius: 8px;
  background: #ffffff;
}

.right-side-checklist .passed { border-left-color: #25815f; }
.right-side-checklist .waiting { border-left-color: #d1a037; }
.right-side-checklist .risk { border-left-color: #c83c3c; }
.right-side-checklist h3 { margin: 0 0 4px; font-size: 12px; }
.right-side-checklist p { color: #4b5869; font-size: 12px; line-height: 1.5; }

.right-side-details {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fbfcfe;
}

.right-side-details summary {
  padding: 11px 12px;
  color: #344154;
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
}

.right-side-detail-grid {
  display: grid;
  gap: 8px;
  padding: 0 10px 10px;
}

.right-side-detail-grid > div {
  padding: 9px 10px;
  border: 1px solid #e7ebf0;
  border-radius: 7px;
  background: #ffffff;
}

.right-side-detail-grid span { display: block; color: var(--muted); font-size: 10px; }
.right-side-detail-grid strong { display: block; margin-top: 3px; font-size: 12px; }
.right-side-detail-grid p { margin-top: 4px; color: #5f6b7a; font-size: 11px; line-height: 1.5; }

.right-side-disclaimer {
  padding: 0 2px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.5;
}

.sector-board {
  flex: 0 0 auto;
  margin-top: 0;
  padding: 14px;
  border-top: 1px solid var(--line);
}

.sector-board h2 {
  margin-bottom: 10px;
}

.sector-item {
  display: grid;
  grid-template-columns: minmax(125px, 1.3fr) minmax(80px, 1fr) auto;
  align-items: center;
  gap: 8px;
  min-height: 30px;
  font-size: 13px;
}

.sector-item strong {
  min-width: 0;
  line-height: 1.4;
  overflow-wrap: normal;
  word-break: keep-all;
}

.sector-entry-summary { margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--line); }
.sector-entry-summary h3 { margin: 0 0 8px; font-size: 13px; color: #1e3657; }
.seasonal-sector-item { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 3px 6px; padding: 8px 0; border-bottom: 1px dashed #e2e8f0; font-size: 12px; }
.seasonal-sector-item:last-child { border-bottom: 0; }
.seasonal-sector-item small, .seasonal-sector-item p { grid-column: 1 / -1; margin: 0; color: #6b778b; line-height: 1.45; }

.heat-bar {
  height: 8px;
  overflow: hidden;
  border-radius: 8px;
  background: #e8edf3;
}

.heat-bar span {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, #16805a, #e6b450, #cf3434);
}

@media (max-width: 1100px) {
  .app-shell {
    grid-template-columns: 1fr;
  }
  .app-shell.left-collapsed {
    grid-template-columns: 1fr;
  }
  .side-panel {
    max-height: none;
  }
  .workspace-grid {
    grid-template-columns: 1fr;
  }
  .top-strip .source-tabs { flex-direction: column; }
  .daily-top-pool-grid {
    grid-template-columns: 1fr;
  }
  .daily-standard-card {
    grid-template-columns: 30px minmax(130px, 1.05fr) 70px minmax(135px, 0.9fr) minmax(112px, 0.75fr);
  }
  .decision-bars {
    grid-template-columns: 1fr;
  }
  .workspace-grid.right-side-workspace {
    grid-template-columns: 1fr;
  }
  .workspace-grid.insight-collapsed {
    grid-template-columns: 1fr;
  }
  .workspace-grid.insight-collapsed .insight-zone {
    min-height: 48px;
  }
  .workspace-grid.insight-collapsed .insight-zone .zone-head {
    min-height: 48px;
    justify-content: flex-end;
  }
  .table-wrap, .insight-zone {
    max-height: none;
  }
  .zone-title-row, .source-tabs {
    align-items: stretch;
    flex-direction: column;
  }
  .source-tabs button {
    width: 100%;
  }
  .market-regime-bar {
    align-items: flex-start;
    flex-wrap: wrap;
  }
  .right-side-decision-bar {
    grid-template-columns: 1fr;
  }
  .right-side-decision-actions {
    justify-content: flex-start;
  }
  .seasonal-window-hero .seasonal-entry-tracker {
    grid-template-columns: 1fr;
  }
  .seasonal-current-market {
    grid-template-columns: 1fr 1fr;
  }
  .seasonal-current-verdict {
    grid-column: 1 / -1;
  }
}

@media (max-width: 760px) {
  body {
    overflow-x: hidden;
  }

  .daily-standards-panel {
    padding: 11px;
  }

  .daily-standards-head {
    align-items: flex-start;
    flex-direction: column;
    gap: 8px;
  }

  .daily-standards-summary {
    justify-content: flex-start;
  }

  .daily-ranking-tabs {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x proximity;
    scrollbar-width: none;
  }

  .daily-ranking-tabs::-webkit-scrollbar {
    display: none;
  }

  .daily-ranking-tabs button {
    flex: 0 0 auto;
    min-width: 126px;
    scroll-snap-align: start;
  }

  .daily-top-pool {
    padding: 8px;
  }

  .daily-top-pool-head {
    align-items: center;
    flex-direction: row;
    gap: 8px;
    margin-bottom: 6px;
  }

  .daily-top-pool-head > b {
    width: auto;
    min-width: 40px;
  }

  .daily-top-pool-head span {
    display: none;
  }

  .daily-top-pool-head strong {
    font-size: 13px;
  }

  .daily-standards-meta > summary em {
    display: none;
  }

  .daily-standard-card {
    grid-template-areas:
      "rank stock price"
      "rank k k"
      "rank status status";
    grid-template-columns: 28px minmax(0, 1fr) 72px;
    gap: 6px 8px;
  }

  .daily-standard-rank {
    align-self: start;
  }

  .daily-standard-price {
    text-align: right;
  }

  .daily-standard-status {
    justify-self: start;
    max-width: none;
  }

  .daily-stock-dialog-card {
    gap: 10px;
    padding: 14px;
  }

  .daily-stock-dialog {
    width: 100vw;
    max-width: 100vw;
    max-height: 100dvh;
    height: 100dvh;
    margin: 0;
    border-radius: 0;
  }

  .daily-stock-dialog .position-dialog-head {
    top: 0;
  }

  .daily-stock-at-glance {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .daily-stock-at-glance article.primary,
  .daily-stock-at-glance article:last-child {
    grid-column: 1 / -1;
  }

  .ai-research-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ai-phase-banner { grid-template-columns: 1fr; }
  .ai-operation-plan { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ai-entry-route-grid,
  .ai-entry-route-grid:has(> article:nth-child(3)) { grid-template-columns: 1fr; }
  .ai-decision-summary { grid-template-columns: 1fr; }
  .ai-price-plan { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ai-decision-dimensions { grid-template-columns: repeat(3, minmax(0, 1fr)); }

  .daily-stock-detail-tabs {
    top: 64px;
    display: flex;
    overflow-x: auto;
    scrollbar-width: none;
  }

  .daily-stock-detail-tabs::-webkit-scrollbar { display: none; }

  .daily-stock-detail-tabs button {
    flex: 0 0 auto;
    min-width: 94px;
    font-size: 12px;
  }

  .company-profile-lead,
  .company-profile-context,
  .company-profile-groups {
    grid-template-columns: 1fr;
  }

  .company-profile-secondary {
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 4px 9px;
  }

  .company-profile-secondary small {
    flex-basis: 100%;
  }

  .daily-stock-hero {
    grid-template-columns: minmax(0, 1fr) auto;
  }

  .ai-research-head { align-items: start; }
  .ai-research-head button { min-height: 34px; }
  .ai-phase-track { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ai-operation-plan { grid-template-columns: 1fr; }
  .ai-entry-routes > header { align-items: flex-start; flex-direction: column; }
  .ai-entry-routes > header small { text-align: left; }
  .ai-decision-dimensions { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .trade-capital-plan > header,
  .actual-purchase-ledger > header,
  .trade-plan-actions { align-items: flex-start; flex-direction: column; }
  #dailyTradePlanForm { grid-template-columns: 1fr; }
  .trade-capital-summary { grid-template-columns: 1fr; }
  #actualPurchaseLotForm,
  .actual-position-node-grid { grid-template-columns: 1fr; }
  .actual-purchase-lot { grid-template-columns: 1fr auto; }
  .actual-purchase-lot > div,
  .actual-purchase-lot > strong { grid-column: 1; }
  .actual-purchase-lot > em { grid-column: 1; }
  .actual-purchase-lot > button { grid-column: 2; grid-row: 1 / span 3; }
  #dailyTradePlanForm button,
  #actualPurchaseLotForm button,
  .trade-plan-actions button { width: 100%; }

  .daily-stock-hero > .daily-standard-status {
    grid-column: 1 / -1;
    justify-self: start;
  }

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

  .daily-ma-current-values {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .daily-ma-pair-grid,
  .daily-ma-scenarios {
    grid-template-columns: 1fr;
  }

  .daily-ma-pair-grid span {
    min-height: 34px;
  }

  .daily-stock-check-grid {
    grid-template-columns: 1fr;
  }

  .daily-stock-holder-row {
    grid-template-columns: 44px minmax(0, 1fr) auto;
  }

  .daily-stock-holder-row small {
    grid-column: 2 / -1;
    text-align: left;
  }

  .daily-stock-dialog-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .daily-stock-dialog-actions button {
    width: 100%;
  }

  body.mobile-sidebar-open {
    overflow: hidden;
  }

  .observation-filters,
  .observation-tech-category-filters,
  .observation-stage-panel,
  .observation-window-submenu,
  .observation-filter-path {
    width: 100% !important;
    max-width: 100%;
    margin-left: 0;
  }

  .market-index-dialog-body { grid-template-columns: repeat(2, minmax(0, 1fr)); }

  .app-shell,
  .app-shell.left-collapsed {
    display: block;
    min-height: 100vh;
  }

  .main-panel {
    padding: 10px;
    padding-bottom: max(16px, env(safe-area-inset-bottom));
  }

  .mobile-app-bar {
    position: sticky;
    z-index: 12;
    top: 0;
    display: flex;
    align-items: center;
    gap: 10px;
    min-height: 58px;
    margin: -10px -10px 10px;
    padding: 8px 10px;
    padding-top: max(8px, env(safe-area-inset-top));
    border-bottom: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.96);
    box-shadow: 0 4px 14px rgba(21, 35, 52, 0.08);
  }

  .seasonal-window-hero .seasonal-entry-tracker {
    padding: 14px;
    font-size: 13px;
  }

  .seasonal-window-hero .seasonal-history,
  .seasonal-window-hero .seasonal-entry-tracker ol {
    grid-template-columns: 1fr;
  }

  .seasonal-current-market {
    grid-template-columns: 1fr;
    padding: 12px;
  }

  .seasonal-current-verdict {
    grid-column: auto;
  }

  .seasonal-window-summary-card {
    grid-template-columns: minmax(0, 1fr) 32px;
    gap: 8px 10px;
    min-height: 0;
    padding: 10px 11px;
  }

  .seasonal-window-hero .seasonal-entry-tracker {
    padding: 0;
  }

  .seasonal-window-summary-copy strong {
    font-size: 18px;
  }

  .seasonal-window-summary-status {
    grid-column: 1 / -1;
    grid-row: 2;
  }

  .seasonal-window-summary-status small {
    display: none;
  }

  .seasonal-window-summary-arrow {
    grid-column: 2;
    grid-row: 1;
  }

  .seasonal-window-dialog-card {
    gap: 10px;
    padding: 14px;
  }

  .seasonal-window-dialog-body .seasonal-history,
  .seasonal-window-dialog-body ol {
    grid-template-columns: 1fr;
  }

  .seasonal-window-dialog-body .seasonal-current-market {
    grid-template-columns: 1fr;
  }

  .seasonal-window-dialog-body .seasonal-current-verdict {
    grid-column: auto;
  }

  .mobile-drawer-button {
    width: 42px;
    height: 42px;
    flex: 0 0 42px;
    padding: 0;
    border: 1px solid var(--line);
    border-radius: 6px;
    background: #ffffff;
    color: var(--ink);
    font-size: 23px;
    line-height: 1;
    cursor: pointer;
  }

  .mobile-app-title {
    display: grid;
    min-width: 0;
    gap: 2px;
  }

  .mobile-app-title strong {
    overflow: hidden;
    font-size: 15px;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .mobile-app-title span {
    color: var(--muted);
    font-size: 11px;
  }

  .side-panel,
  .side-panel.left-collapsed {
    position: fixed;
    z-index: 30;
    inset: 0 auto 0 0;
    width: min(88vw, 360px);
    max-height: none;
    padding: max(14px, env(safe-area-inset-top)) 14px max(18px, env(safe-area-inset-bottom));
    overflow-x: hidden;
    overflow-y: auto;
    box-shadow: 18px 0 42px rgba(0, 0, 0, 0.28);
    transform: translateX(-105%);
    transition: transform 180ms ease;
  }

  .side-panel.mobile-open,
  .side-panel.left-collapsed.mobile-open {
    transform: translateX(0);
  }

  .side-panel.left-collapsed .brand-block {
    justify-content: flex-start;
    gap: 12px;
    padding-bottom: 18px;
    border-bottom: 1px solid rgba(255,255,255,0.14);
  }

  .side-panel.left-collapsed .brand-copy,
  .side-panel.left-collapsed .panel-section {
    display: block;
  }

  .side-panel .left-toggle {
    font-size: 22px;
  }

  .mobile-sidebar-backdrop {
    position: fixed;
    z-index: 25;
    inset: 0;
    width: 100%;
    height: 100%;
    padding: 0;
    border: 0;
    background: rgba(15, 23, 42, 0.52);
  }

  .mobile-sidebar-backdrop.visible {
    display: block;
  }

  .top-strip {
    gap: 8px;
    margin-bottom: 10px;
  }

  .metric-tile {
    min-height: 60px;
    padding: 9px 10px;
  }

  .metric-tile span {
    font-size: 11px;
  }

  .metric-tile strong {
    margin-top: 5px;
    font-size: 21px;
  }

  .search-box {
    grid-column: 1 / -1;
    padding: 8px;
  }

  .search-box input {
    min-height: 42px;
  }

  .market-regime-bar {
    margin: 0;
    padding: 9px 10px;
    font-size: 12px;
  }

  .right-side-decision-bar {
    gap: 12px;
    margin: 0;
    padding: 12px;
  }

  .right-side-decision-copy strong {
    font-size: 17px;
  }

  .right-side-decision-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    width: 100%;
  }

  .right-side-count {
    min-width: 0;
    padding: 7px;
    border: 1px solid #eadfbf;
    background: #ffffff;
  }

  #openRightSideButton {
    grid-column: 1 / -1;
    width: 100%;
  }

  .workspace-grid,
  .workspace-grid.insight-collapsed {
    gap: 10px;
  }

  .zone-head,
  .zone-head.stacked {
    gap: 9px;
    padding: 10px;
  }

  .zone-title-row {
    align-items: stretch;
    flex-direction: column;
  }

  .zone-title-row h2 {
    font-size: 14px;
  }

  .workspace-tabs,
  .source-tabs,
  .segmented {
    display: flex;
    width: 100%;
    max-width: 100%;
    align-items: stretch;
    flex-direction: row;
    overflow-x: auto;
    overscroll-behavior-inline: contain;
    scrollbar-width: none;
  }

  .workspace-tabs::-webkit-scrollbar,
  .source-tabs::-webkit-scrollbar,
  .segmented::-webkit-scrollbar {
    display: none;
  }

  .workspace-tabs button,
  .source-tabs button,
  .segmented button {
    width: auto;
    min-width: max-content;
    flex: 0 0 auto;
    padding-right: 11px;
    padding-left: 11px;
    font-size: 13px;
  }

  .source-tab-group { min-width: max-content; }

  .table-scroll-controls {
    display: none;
  }

  .table-wrap {
    max-height: none;
    overflow: visible;
    background: var(--bg);
  }

  table {
    display: block;
    width: 100%;
    min-width: 0;
    font-size: 13px;
  }

  thead {
    display: none;
  }

  tbody {
    display: grid;
    gap: 9px;
    padding: 9px;
  }

  tbody tr {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #ffffff;
    box-shadow: 0 3px 12px rgba(21, 35, 52, 0.05);
  }

  tbody tr.selected {
    border-color: #8fb2f2;
    background: #ffffff;
    box-shadow: 0 0 0 2px rgba(37, 99, 235, 0.10);
  }

  tbody td {
    display: block;
    min-width: 0;
    padding: 9px 10px;
    border-bottom: 1px solid #edf1f5;
    white-space: normal;
    overflow-wrap: anywhere;
  }

  tbody td::before {
    content: attr(data-label);
    display: block;
    margin-bottom: 4px;
    color: var(--muted);
    font-size: 10px;
    font-weight: 700;
  }

  tbody td:nth-child(1),
  tbody td:nth-child(5),
  tbody td:nth-child(6),
  tbody td:nth-child(7),
  tbody td:nth-child(8) {
    grid-column: 1 / -1;
  }

  tbody td:nth-child(1) { order: 1; }
  tbody td:nth-child(2) { order: 2; }
  tbody td:nth-child(4) { order: 3; }
  tbody td:nth-child(5) { order: 4; }
  tbody td:nth-child(6) { order: 5; }
  tbody td:nth-child(7) { order: 6; }
  tbody td:nth-child(8) { order: 7; }
  tbody td:nth-child(3) { order: 8; }
  tbody td:nth-child(9) { order: 9; }

  tbody td:nth-child(2),
  tbody td:nth-child(4),
  tbody td:nth-child(3),
  tbody td:nth-child(9) {
    min-height: 82px;
  }

  tbody td:nth-child(1) {
    padding: 11px 10px;
    background: #f8fafc;
  }

  tbody td:nth-child(1)::before {
    display: none;
  }

  tbody td:nth-child(5) {
    background: #fbfcfe;
  }

  .entry-decision-cell,
  .individual-observation-metrics {
    min-width: 0;
  }

  tbody tr:not([data-code]) {
    display: block;
  }

  tbody tr:not([data-code]) td {
    border: 0;
  }

  .stock-name strong {
    font-size: 16px;
  }

  .daily-stock-kline {
    min-height: 202px;
  }

  .daily-stock-kline-canvas {
    height: 200px;
  }

  .daily-stock-kline-meta {
    align-items: flex-start;
    flex-direction: column;
    gap: 2px;
  }

  .daily-stock-ma-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .daily-stock-kline-tabs {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    width: 100%;
  }

  .precise-stock-kline-head {
    align-items: flex-start;
    flex-direction: column;
    gap: 3px;
  }

  .precise-stock-kline-metrics {
    grid-template-columns: 1fr;
  }

  .precise-metric-row.kdj-row,
  .precise-metric-row.boll-row {
    grid-template-columns: 1fr;
  }

  .subline {
    line-height: 1.45;
  }

  .focus-remove-button {
    float: right;
  }

  .insight-zone {
    max-height: none;
  }

  .insight-body,
  .sector-board {
    padding: 10px;
  }

  .insight-card {
    padding: 10px;
  }

  .workspace-grid.insight-collapsed .insight-zone {
    min-height: 48px;
  }

  .access-gate {
    padding: 14px;
  }

  .access-card {
    padding: 18px;
  }

  .position-form {
    padding: 16px;
  }

  .position-form-grid {
    grid-template-columns: 1fr;
  }
}
.unified-lifecycle-panel {
  margin: 10px 14px 12px;
  padding: 12px 14px;
  border: 1px solid #cfdbea;
  border-left: 4px solid #2563eb;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 4px 16px rgba(31, 56, 88, .06);
}

.unified-lifecycle-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}

.unified-lifecycle-heading div {
  display: grid;
  gap: 2px;
}

.unified-lifecycle-heading small,
.unified-lifecycle-panel > p {
  color: #66768c;
}

.unified-lifecycle-heading strong {
  color: #14233a;
  font-size: 16px;
}

.unified-lifecycle-heading > span {
  padding: 5px 10px;
  border-radius: 999px;
  color: #164e63;
  background: #ecfeff;
  white-space: nowrap;
  font-weight: 700;
}

.unified-lifecycle-flow {
  display: grid;
  grid-template-columns: repeat(4, minmax(120px, 1fr) 18px) minmax(120px, 1fr);
  align-items: stretch;
  gap: 6px;
}

.unified-lifecycle-flow > div {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 2px 8px;
  min-width: 0;
  padding: 8px 10px;
  border: 1px solid #d8e0ea;
  border-radius: 10px;
  background: #f8fafc;
}

.unified-lifecycle-flow > div span,
.unified-lifecycle-flow > div b {
  font-weight: 800;
}

.unified-lifecycle-flow > div small {
  grid-column: 1 / -1;
  color: #718096;
  line-height: 1.3;
}

.unified-lifecycle-flow > i {
  display: grid;
  place-items: center;
  color: #8ba0b8;
  font-style: normal;
}

.unified-lifecycle-flow > div.excluded { border-color: #fecaca; background: #fff7f7; color: #a61b1b; }
.unified-lifecycle-flow > div.watch { border-color: #dbe4ef; background: #f8fafc; color: #475569; }
.unified-lifecycle-flow > div.near { border-color: #fde68a; background: #fffbeb; color: #925d00; }
.unified-lifecycle-flow > div.review { border-color: #a7f3d0; background: #ecfdf5; color: #086b4b; }
.unified-lifecycle-flow > div.holding { border-color: #bfdbfe; background: #eff6ff; color: #1d4ed8; }

.unified-lifecycle-panel > p {
  margin: 9px 0 0;
  font-size: 12px;
}

.unified-stage-chip {
  display: inline-flex;
  align-items: center;
  width: max-content;
  margin-top: 5px;
  padding: 3px 7px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
}

.unified-stage-chip.strong { color: #076447; background: #dcfce7; }
.unified-stage-chip.near { color: #8a5700; background: #fef3c7; }
.unified-stage-chip.watch { color: #475569; background: #e9eef5; }
.unified-stage-chip.risk { color: #a61b1b; background: #fee2e2; }
.unified-stage-chip.holding { color: #1d4ed8; background: #dbeafe; }

.unified-stage-action {
  margin-top: 4px;
  color: #5f6f84;
  font-size: 12px;
  line-height: 1.4;
}

@media (max-width: 900px) {
  .unified-lifecycle-panel { margin: 8px 8px 10px; padding: 10px; }
  .unified-lifecycle-heading { align-items: flex-start; }
  .unified-lifecycle-heading strong { font-size: 14px; }
  .unified-lifecycle-flow {
    grid-template-columns: repeat(4, minmax(132px, 1fr) 14px) minmax(132px, 1fr);
    overflow-x: auto;
    padding-bottom: 4px;
  }
}

.unified-dialog-stage {
  border-left: 4px solid #94a3b8;
}
.unified-dialog-stage.strong { border-left-color: #10b981; background: #f0fdf4; }
.unified-dialog-stage.near { border-left-color: #f59e0b; background: #fffbeb; }
.unified-dialog-stage.risk { border-left-color: #ef4444; background: #fff7f7; }
.unified-dialog-stage.holding { border-left-color: #3b82f6; background: #eff6ff; }
.unified-dialog-stage p { margin: 6px 0 0; line-height: 1.55; color: #46566c; }
.decision-workflow-panel {
  margin: 14px 20px 12px;
  padding: 16px;
  border: 1px solid #cbd8e8;
  border-left: 5px solid #153f71;
  border-radius: 16px;
  background: linear-gradient(135deg, #fbfdff 0%, #f1f6fc 100%);
  box-shadow: 0 8px 26px rgba(20, 48, 80, 0.08);
}

/* Homepage task order: current workflow, filtered stocks, then auxiliary context. */
.main-panel {
  display: flex;
  flex-direction: column;
}

.main-panel > .mobile-app-bar { order: 0; }
.main-panel > .seasonal-window-hero { order: 1; }
.main-panel > .decision-workflow-panel { order: 2; }
.main-panel > .top-strip { order: 3; }
.main-panel > .workspace-grid { order: 4; }
.main-panel > .daily-standards-panel { order: 5; }

/* v189: blocker-rich stock details must remain a readable single-column flow on phones. */
@media (max-width: 760px) {
  .daily-stock-dialog .ai-decision-summary,
  .daily-stock-dialog .ai-decision-summary:has(.ai-blocker-list) {
    grid-template-columns: minmax(0, 1fr);
    gap: 9px;
  }

  .daily-stock-dialog .ai-decision-summary article,
  .daily-stock-dialog .ai-blocker-list,
  .daily-stock-dialog .ai-blocker-item {
    width: 100%;
    min-width: 0;
  }

  .daily-stock-dialog .ai-decision-summary article {
    padding: 12px;
  }

  .daily-stock-dialog .ai-decision-summary strong,
  .daily-stock-dialog .ai-decision-summary p,
  .daily-stock-dialog .ai-blocker-item small,
  .daily-stock-dialog .ai-decision-next strong {
    word-break: normal;
    overflow-wrap: break-word;
    writing-mode: horizontal-tb;
  }

  .daily-stock-dialog .ai-blocker-item > div {
    align-items: flex-start;
    flex-wrap: wrap;
  }

  .daily-stock-dialog .ai-blocker-item small {
    grid-template-columns: 38px minmax(0, 1fr);
  }
}

/* v188: balanced workspace navigation; power-chain subboards belong to 热门板块. */
.top-strip .source-tabs {
  display: grid;
  grid-template-columns:
    minmax(230px, 1fr)
    minmax(660px, 2.8fr)
    minmax(145px, .62fr)
    minmax(185px, .78fr);
  width: 100%;
  align-items: stretch;
  gap: 7px;
  overflow: visible;
}

.top-strip .source-tab-group {
  min-width: 0;
}

.top-strip .source-tab-group > div {
  display: flex;
  grid-template-columns: none;
  gap: 4px;
}

.top-strip .source-tabs button {
  min-width: 92px;
  min-height: 38px;
  padding: 0 14px;
  white-space: nowrap;
}

.top-strip .observation-nav-group { min-width: 0; }
.top-strip .observation-nav-group > div > button { flex: 1 1 0; }
.top-strip .observation-nav-group .hot-board-primary { display: flex; }
.top-strip .power-chain-secondary {
  display: flex;
  gap: 4px;
  margin-top: 3px;
  padding-top: 4px;
  border-top: 1px dashed rgba(179, 48, 65, .22);
  background: linear-gradient(90deg, rgba(255,245,246,.72), rgba(235,250,251,.68));
}
.top-strip .power-chain-secondary[hidden] { display: none !important; }
.top-strip #powerChainMenuToggle span { display: inline-block; transition: transform .18s ease; }
.top-strip #powerChainMenuToggle[aria-expanded="true"] span { transform: rotate(180deg); }
.top-strip .entry-nav-group { min-width: 0; }

.power-chain-top-filters {
  width: 100%;
  justify-content: flex-start;
  gap: 6px;
  background: linear-gradient(90deg, rgba(255,248,248,.84), rgba(236,252,253,.78));
}

@media (max-width: 1500px) and (min-width: 761px) {
  .top-strip .source-tabs {
    grid-template-columns: minmax(230px, 1fr) minmax(150px, .62fr) minmax(190px, .78fr);
  }
  .top-strip .position-nav-group { grid-column: 1; grid-row: 1; }
  .top-strip .institution-nav-group { grid-column: 2; grid-row: 1; }
  .top-strip .entry-nav-group { grid-column: 3; grid-row: 1; }
  .top-strip .observation-nav-group { grid-column: 1 / -1; grid-row: 2; }
}

@media (max-width: 760px) {
  .top-strip .source-tabs {
    display: flex;
    padding-bottom: 7px;
    overflow-x: auto;
    overscroll-behavior-inline: contain;
    scrollbar-width: thin;
  }
  .top-strip .source-tab-group,
  .top-strip .observation-nav-group,
  .top-strip .entry-nav-group { min-width: max-content; }
  .top-strip .source-tabs button { min-width: 78px; min-height: 34px; padding: 0 10px; font-size: 12px; }
}

/* v188 mobile: keep the home page menu collapsed to one line until requested. */
@media (max-width: 760px) {
  .top-strip {
    position: sticky;
    top: 66px;
    z-index: 90;
    padding: 5px 6px;
  }

  .top-strip .workspace-compact-nav {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    min-height: 42px;
    gap: 6px;
  }

  .top-strip > .source-tabs,
  body.workspace-open .top-strip > .source-tabs { display: none; }

  body.workspace-nav-expanded .top-strip > .source-tabs,
  body.workspace-open.workspace-nav-expanded .top-strip > .source-tabs {
    display: grid;
    grid-template-columns: 1fr;
    max-height: 56vh;
    margin-top: 6px;
    overflow-x: hidden;
    overflow-y: auto;
  }

  .top-strip .source-tab-group,
  .top-strip .observation-nav-group,
  .top-strip .institution-nav-group,
  .top-strip .entry-nav-group {
    min-width: 0;
  }

  .top-strip .source-tab-group > div {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .top-strip .observation-nav-group > div {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .top-strip .observation-nav-group .power-chain-secondary {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .top-strip .source-tabs button {
    width: 100%;
    min-width: 0;
    min-height: 34px;
    padding: 0 6px;
    font-size: 12px;
  }
}

/* v180: the anti-sentiment market cycle is the primary top signal. */
.market-cycle-stage-strip {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 7px;
  min-width: 0;
}

.market-cycle-stage-strip > span {
  display: grid;
  gap: 2px;
  min-width: 0;
  padding: 6px 8px;
  border: 1px solid rgba(126, 139, 157, .24);
  border-radius: 8px;
  background: rgba(255, 255, 255, .62);
  color: #66788b;
  text-align: center;
}

.market-cycle-stage-strip > span.active {
  border-color: #b62d3d;
  background: linear-gradient(135deg, #b3293a, #d34a57);
  color: #fff;
  box-shadow: 0 4px 12px rgba(157, 30, 46, .18);
}

.market-cycle-stage-strip b { font-size: 12px; }
.market-cycle-stage-strip small { overflow: hidden; font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }

.seasonal-support-details {
  border: 1px solid #ead9b4;
  border-radius: 10px;
  background: rgba(255, 253, 246, .74);
}

.seasonal-support-details > summary {
  padding: 10px 12px;
  color: #7c6020;
  font-weight: 800;
  cursor: pointer;
}

.seasonal-support-details > div {
  display: grid;
  gap: 10px;
  padding: 0 10px 10px;
}

/* Keep long growth-gate sentences horizontal inside fixed-width stock columns. */
.individual-observation-metrics .growth-gate-inline {
  grid-template-columns: minmax(0, 1fr);
  align-items: start;
  gap: 5px;
  min-width: 0;
}

.individual-observation-metrics .growth-gate-inline > b,
.individual-observation-metrics .growth-gate-inline > span,
.individual-observation-metrics .growth-gate-inline > em {
  display: block;
  min-width: 0;
  max-width: 100%;
  line-height: 1.45;
  writing-mode: horizontal-tb;
  text-orientation: mixed;
  white-space: normal;
  word-break: normal;
  overflow-wrap: break-word;
}

@media (max-width: 620px) {
  .seasonal-window-summary-card { grid-template-columns: minmax(0, 1fr) 32px; }
  .market-cycle-stage-strip { grid-template-columns: repeat(4, minmax(62px, 1fr)); overflow-x: auto; }
  .market-cycle-stage-strip small { white-space: normal; }
}

/* v176: keep the SEC 13F workbench independent from the A-share stock table. */
.institution-13f-workbench {
  display: grid;
  gap: 16px;
  margin: 14px 0;
  padding: 20px;
  border: 1px solid rgba(51, 153, 168, .34);
  border-left: 5px solid #a82d42;
  border-radius: 18px;
  background: linear-gradient(135deg, rgba(255, 250, 249, .90), rgba(238, 251, 252, .86));
  box-shadow: 0 16px 34px rgba(71, 31, 43, .10), inset 0 1px 0 rgba(255,255,255,.88);
  backdrop-filter: blur(14px);
}

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

.institution-13f-workbench[hidden] { display: none; }

.institution-13f-workbench > header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
}

.institution-13f-workbench > header small { color: #a12c40; font-weight: 800; }
.institution-13f-workbench > header h3 { margin: 4px 0 6px; font-size: 24px; color: #172d47; }
.institution-13f-workbench > header p { max-width: 900px; margin: 0; color: #5b6e80; line-height: 1.65; }
.institution-13f-workbench > header > span {
  flex: 0 0 auto;
  padding: 8px 12px;
  border: 1px solid rgba(190, 58, 74, .24);
  border-radius: 999px;
  background: rgba(255, 237, 238, .78);
  color: #9f2a3c;
  font-weight: 800;
}

.institution-13f-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.institution-13f-grid article {
  display: grid;
  gap: 5px;
  min-width: 0;
  padding: 14px;
  border: 1px solid rgba(106, 154, 173, .25);
  border-radius: 13px;
  background: rgba(255,255,255,.62);
}

.institution-13f-grid small { color: #9b3041; font-weight: 800; }
.institution-13f-grid strong { color: #173957; font-size: 18px; }
.institution-13f-grid span,
.institution-13f-grid em { color: #65788b; font-style: normal; overflow-wrap: anywhere; }
.institution-13f-grid b { margin-top: 5px; color: #9b6b16; font-size: 12px; }

.institution-13f-note {
  padding: 14px 16px;
  border-left: 4px solid #1a9aa6;
  border-radius: 11px;
  background: rgba(234, 250, 250, .74);
}

.institution-13f-note strong { color: #146b74; }
.institution-13f-note p { margin: 5px 0 0; color: #536c7b; line-height: 1.65; }

@media (max-width: 760px) {
  .institution-13f-workbench { padding: 14px; border-radius: 14px; }
  .institution-13f-workbench > header { display: grid; }
  .institution-13f-workbench > header > span { justify-self: start; }
  .institution-13f-grid { grid-template-columns: 1fr; }
}

/* v178: live SEC 13F filing status, quarter comparison and source actions. */
.institution-13f-actions {
  display: grid;
  justify-items: end;
  gap: 8px;
  flex: 0 0 auto;
}

.institution-13f-actions > span {
  padding: 7px 11px;
  border: 1px solid rgba(190, 58, 74, .24);
  border-radius: 999px;
  background: rgba(255, 237, 238, .78);
  color: #9f2a3c;
  font-size: 12px;
  font-weight: 800;
}

.institution-13f-actions button {
  min-height: 40px;
  padding: 0 15px;
  border: 1px solid rgba(22, 126, 141, .34);
  border-radius: 11px;
  background: linear-gradient(135deg, #156b7b, #1b90a0);
  color: #fff;
  font: inherit;
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 8px 18px rgba(18, 112, 126, .18);
}

.institution-13f-actions button:disabled { cursor: wait; opacity: .64; }

.institution-13f-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 7px 14px;
  padding: 9px 12px;
  border: 1px solid rgba(82, 133, 155, .20);
  border-radius: 10px;
  background: rgba(241, 248, 250, .72);
  color: #607387;
  font-size: 12px;
}

.institution-13f-meta b { color: #a66a13; }

.institution-13f-status {
  display: grid;
  gap: 4px;
  padding: 16px;
  border: 1px dashed rgba(55, 137, 153, .34);
  border-radius: 12px;
  background: rgba(235, 249, 250, .66);
}

.institution-13f-status strong { color: #126a76; }
.institution-13f-status span { color: #607387; }
.institution-13f-status.error { border-color: rgba(190, 58, 74, .32); background: rgba(255, 238, 239, .75); }
.institution-13f-status.error strong { color: #a42d40; }

.institution-13f-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.institution-13f-card-head > div { display: grid; gap: 2px; min-width: 0; }
.institution-13f-card-head > em { flex: 0 0 auto; font-size: 11px; }

.institution-13f-report {
  display: grid;
  gap: 3px;
  padding: 9px 10px;
  border-radius: 9px;
  background: rgba(233, 246, 249, .74);
}

.institution-13f-report b { margin: 0; color: #126a76; font-size: 14px; }
.institution-13f-report span { font-size: 12px; }

.institution-13f-counts {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 4px;
}

.institution-13f-counts span {
  padding: 5px 3px;
  border-radius: 7px;
  background: rgba(244, 246, 249, .90);
  text-align: center;
  font-size: 11px;
  font-weight: 700;
}

.institution-13f-changes { display: grid; gap: 5px; }
.institution-13f-changes > div {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) auto;
  align-items: center;
  gap: 7px;
  padding: 6px 8px;
  border-left: 3px solid #7b8b9c;
  border-radius: 7px;
  background: rgba(247, 248, 250, .82);
}

.institution-13f-changes > div.new,
.institution-13f-changes > div.increased { border-left-color: #159178; }
.institution-13f-changes > div.reduced,
.institution-13f-changes > div.exited { border-left-color: #c84454; }
.institution-13f-changes b { margin: 0; color: #344e66; font-size: 11px; }
.institution-13f-changes span { min-width: 0; color: #253e56; font-size: 12px; font-weight: 700; }
.institution-13f-changes em { font-size: 11px; white-space: nowrap; }
.institution-13f-changes p { margin: 0; color: #687b8e; font-size: 12px; }

.institution-13f-card > a {
  justify-self: start;
  color: #147887;
  font-size: 12px;
  font-weight: 800;
  text-decoration: none;
}

.institution-13f-card.error { border-color: rgba(191, 68, 82, .30); background: rgba(255, 241, 242, .68); }
.institution-13f-card.error b { color: #a42d40; }

.institution-13f-open-detail {
  width: 100%;
  margin-top: 5px;
  padding: 10px 12px;
  border: 1px solid rgba(20, 120, 135, .28);
  border-radius: 10px;
  background: linear-gradient(135deg, rgba(238, 251, 251, .94), rgba(255, 246, 246, .92));
  color: #126f7c;
  font-size: 12px;
  font-weight: 900;
  cursor: pointer;
}
.institution-13f-open-detail:hover { border-color: #17889a; transform: translateY(-1px); }
.institution-13f-dialog { width: min(1380px, calc(100vw - 36px)); max-width: none; }
.institution-13f-dialog-card { max-height: calc(100vh - 38px); overflow: auto; padding: 18px; border-radius: 18px; background: rgba(255, 252, 252, .97); }
.institution-13f-dialog-body { display: grid; gap: 14px; }
.institution-13f-dialog-summary { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.institution-13f-dialog-summary span { padding: 9px 11px; border: 1px solid rgba(74, 126, 148, .18); border-radius: 10px; background: rgba(242, 248, 250, .86); color: #66798d; font-size: 11px; }
.institution-13f-dialog-summary b { display: block; margin-top: 3px; color: #193f59; font-size: 13px; }
.institution-13f-detail-body { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; padding-top: 10px; }
.institution-13f-detail-body section { min-width: 0; padding: 10px; border: 1px solid rgba(74, 126, 148, .18); border-radius: 11px; background: rgba(249, 252, 253, .82); }
.institution-13f-detail-body section > header { display: flex; justify-content: space-between; gap: 8px; margin-bottom: 8px; }
.institution-13f-detail-body section > header strong { font-size: 14px; }
.institution-13f-detail-body section > header span { font-size: 11px; text-align: right; }
.institution-13f-detail-row { display: grid; grid-template-columns: 24px minmax(0, 1fr) 86px 112px; align-items: center; gap: 7px; padding: 7px 5px; border-top: 1px dashed rgba(74, 126, 148, .16); }
.institution-13f-detail-row > div { display: grid; gap: 2px; min-width: 0; }
.institution-13f-detail-row > div strong { overflow: hidden; font-size: 12px; text-overflow: ellipsis; white-space: nowrap; }
.institution-13f-detail-row > div small, .institution-13f-detail-row > span small, .institution-13f-detail-row > em small { display: block; color: #7a8998; font-size: 10px; }
.institution-13f-detail-row > span, .institution-13f-detail-row > em { color: #344e66; font-size: 11px; text-align: right; }
.institution-13f-detail-rank { display: grid; place-items: center; width: 22px; height: 22px; border-radius: 50%; background: #edf5f7; color: #347080 !important; text-align: center !important; }
.institution-13f-detail-body aside { grid-column: 1 / -1; display: flex; align-items: center; gap: 8px 14px; padding: 9px 11px; border-left: 3px solid #d09a32; background: rgba(255, 249, 232, .72); }
.institution-13f-detail-body aside b { margin: 0; white-space: nowrap; }
.institution-13f-detail-body aside span { flex: 1; font-size: 11px; }
.institution-13f-detail-body aside a { color: #147887; font-size: 11px; font-weight: 800; white-space: nowrap; }

@media (max-width: 760px) {
  .institution-13f-actions { justify-items: start; }
  .institution-13f-actions button { width: 100%; }
  .institution-13f-card-head { display: grid; }
  .institution-13f-counts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .institution-13f-detail-body { grid-template-columns: 1fr; }
  .institution-13f-detail-body aside { grid-column: auto; display: grid; }
  .institution-13f-detail-row { grid-template-columns: 22px minmax(0, 1fr) 72px; }
  .institution-13f-detail-row > em { grid-column: 2 / -1; text-align: left; }
  .institution-13f-dialog { width: calc(100vw - 12px); }
  .institution-13f-dialog-card { max-height: calc(100vh - 12px); padding: 12px; }
  .institution-13f-dialog-summary { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

/* v176: long-term dividend compounding, final-review gate and compact board navigation. */
body.workspace-scrolled .top-strip {
  position: sticky;
  top: 0;
  z-index: 90;
  padding: 6px 10px;
  backdrop-filter: blur(18px) saturate(125%);
  box-shadow: 0 9px 24px rgba(61, 20, 31, .13);
}

body.workspace-scrolled .top-strip > .source-tabs { display: none; }
body.workspace-scrolled.workspace-nav-expanded .top-strip > .source-tabs { display: inline-flex; }

.dividend-reinvest-ledger {
  margin-top: 18px;
  padding: 18px;
  border: 1px solid rgba(24, 132, 103, .24);
  border-left: 5px solid #168563;
  border-radius: 18px;
  background: linear-gradient(135deg, rgba(239, 252, 247, .90), rgba(255, 250, 244, .86));
}

.dividend-reinvest-ledger > header {
  display: flex;
  align-items: start;
  justify-content: space-between;
  gap: 16px;
}

.dividend-reinvest-ledger h3 { margin: 3px 0 5px; font-size: 22px; }
.dividend-reinvest-ledger p { margin: 0; color: #5d7081; }
.dividend-reinvest-ledger > header > span {
  padding: 7px 12px;
  border-radius: 999px;
  background: #d9f5e9;
  color: #0f7254;
  font-weight: 850;
  white-space: nowrap;
}

.reinvest-summary-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin: 15px 0;
}

.reinvest-summary-grid > span {
  display: grid;
  gap: 4px;
  padding: 12px;
  border: 1px solid rgba(25, 131, 99, .14);
  border-radius: 12px;
  background: rgba(255, 255, 255, .75);
}
.reinvest-summary-grid small { color: #718292; }
.reinvest-summary-grid b { color: #0e664d; font-size: 17px; }

.reinvest-entry-form {
  display: grid;
  grid-template-columns: repeat(4, minmax(145px, 1fr));
  gap: 10px;
  padding: 14px;
  border-radius: 14px;
  background: rgba(255, 255, 255, .74);
}
.reinvest-entry-form label { display: grid; gap: 5px; color: #526678; font-size: 12px; font-weight: 750; }
.reinvest-entry-form input { width: 100%; min-width: 0; min-height: 38px; }
.reinvest-entry-form .reinvest-note { grid-column: span 3; }
.reinvest-entry-form button { align-self: end; min-height: 40px; border-radius: 10px; background: #166f57; color: #fff; font-weight: 850; }

.reinvest-record-list { display: grid; gap: 8px; margin-top: 12px; }
.reinvest-record-list article {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  border: 1px solid rgba(32, 118, 91, .15);
  border-radius: 12px;
  background: rgba(255, 255, 255, .67);
}
.reinvest-record-list article > div { display: flex; flex-wrap: wrap; align-items: center; gap: 7px 14px; min-width: 0; }
.reinvest-record-list article strong { color: #173a30; }
.reinvest-record-list article span, .reinvest-record-list article small { color: #607a70; }
.reinvest-record-list article button { flex: 0 0 auto; color: #a12438; }
.reinvest-empty { padding: 8px 2px; }

.quant-final-verdict {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 4px 16px;
  align-items: center;
  margin-bottom: 12px;
  padding: 14px 16px;
  border: 1px solid #cfdae5;
  border-left: 5px solid #718096;
  border-radius: 14px;
  background: #f7f9fb;
}
.quant-final-verdict small { grid-row: 1 / 3; font-weight: 800; }
.quant-final-verdict strong { font-size: 22px; }
.quant-final-verdict p { margin: 0; color: #596b7e; }
.quant-final-verdict.pass { border-left-color: #14825f; background: #f1fbf7; }
.quant-final-verdict.risk { border-left-color: #c73643; background: #fff5f5; }
.quant-final-verdict.wait { border-left-color: #d19122; background: #fff9ec; }
.quant-final-verdict.watch { border-left-color: #4677ae; background: #f3f7fc; }

.seasonal-bottom-stage {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(260px, .9fr);
  gap: 14px;
  margin-top: 14px;
  padding: 16px;
  border: 1px solid rgba(132, 80, 159, .22);
  border-left: 5px solid #8b3fc2;
  border-radius: 14px;
  background: rgba(250, 246, 255, .88);
}
.seasonal-bottom-stage small, .seasonal-bottom-stage strong, .seasonal-bottom-stage p { display: block; }
.seasonal-bottom-stage strong { margin: 3px 0; font-size: 21px; }
.seasonal-bottom-stage p { margin: 0; color: #647184; }
.seasonal-bottom-stage ol { margin: 0; padding-left: 22px; color: #4e5f72; }
.seasonal-bottom-stage.review-ready { border-left-color: #13805e; background: #f0fbf6; }
.seasonal-bottom-stage.not-bottom { border-left-color: #c23343; background: #fff5f5; }

.market-cycle-action {
  margin-top: 14px;
  padding: 16px;
  border: 1px solid rgba(28, 103, 128, .22);
  border-left: 5px solid #1b8294;
  border-radius: 14px;
  background: rgba(241, 250, 252, .90);
}
.market-cycle-action.declining { border-left-color: #c43c4b; background: rgba(255, 244, 245, .92); }
.market-cycle-action.recovery { border-left-color: #b8831e; background: rgba(255, 250, 237, .92); }
.market-cycle-action.rising { border-left-color: #16825f; background: rgba(241, 251, 247, .92); }
.market-cycle-action.cooling { border-left-color: #7a5aa8; background: rgba(248, 245, 253, .92); }
.market-cycle-action > header { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.market-cycle-action > header div { display: grid; gap: 3px; }
.market-cycle-action > header small { color: #68788b; font-weight: 800; }
.market-cycle-action > header strong { color: #18344e; font-size: 22px; }
.market-cycle-action > header > b { padding: 7px 11px; border-radius: 999px; background: rgba(255,255,255,.72); color: #244e64; white-space: nowrap; }
.market-cycle-action-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 12px; }
.market-cycle-action-grid p { margin: 0; padding: 10px; border-radius: 9px; background: rgba(255,255,255,.68); color: #485e72; line-height: 1.55; }
.market-cycle-action-grid p span { display: block; margin-bottom: 3px; color: #1d5269; font-size: 11px; font-weight: 900; }
.market-cycle-action footer { display: grid; grid-template-columns: auto 1fr; gap: 4px 9px; margin-top: 10px; padding-top: 9px; border-top: 1px dashed rgba(48, 101, 121, .24); }
.market-cycle-action footer b { color: #a13c48; }
.market-cycle-action footer span { color: #5f4850; }
.market-cycle-action footer em { grid-column: 1 / -1; color: #728092; font-size: 11px; font-style: normal; }

@media (max-width: 900px) {
  .reinvest-summary-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .reinvest-entry-form { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .reinvest-entry-form .reinvest-note { grid-column: span 2; }
}

@media (max-width: 620px) {
  body.workspace-scrolled .top-strip { top: 62px; }
  .reinvest-summary-grid, .reinvest-entry-form, .seasonal-bottom-stage { grid-template-columns: 1fr; }
  .reinvest-entry-form .reinvest-note { grid-column: auto; }
  .reinvest-record-list article { align-items: flex-start; }
  .quant-final-verdict { grid-template-columns: 1fr; }
  .quant-final-verdict small { grid-row: auto; }
  .market-cycle-action-grid { grid-template-columns: 1fr; }
  .market-cycle-action > header { align-items: flex-start; }
}
.main-panel > [hidden] { display: none !important; }

body[data-workflow-view="preopen"] .main-panel > .daily-standards-panel,
body[data-workflow-view="review"] .main-panel > .daily-standards-panel { order: 2; }
body[data-workflow-view="preopen"] .main-panel > .top-strip,
body[data-workflow-view="review"] .main-panel > .top-strip { order: 3; }
body[data-workflow-view="preopen"] .main-panel > .workspace-grid,
body[data-workflow-view="review"] .main-panel > .workspace-grid { order: 4; }
body[data-workflow-view="preopen"] .main-panel > .unified-lifecycle-panel,
body[data-workflow-view="review"] .main-panel > .unified-lifecycle-panel { order: 5; }

.decision-workflow-result-count {
  display: inline-flex;
  margin-top: 9px;
  padding: 5px 10px;
  border-radius: 999px;
  background: #e8f5ef;
  color: #08735e;
  font-size: 13px;
}

.market-cycle-k,
.growth-gate-inline {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 6px 10px;
  margin: 7px 0;
  padding: 7px 9px;
  border-radius: 9px;
  background: #eef5ff;
  color: #244b72;
  font-size: 12px;
}
.market-cycle-k em,
.growth-gate-inline em { font-style: normal; color: #60758c; }
.growth-gate-inline.pass { background: #e9f8f1; color: #08745d; }
.growth-gate-inline.near { background: #fff5d9; color: #87620b; }
.growth-gate-inline.fail { background: #f3f5f7; color: #667789; }

@media (max-width: 620px) {
  .market-cycle-k,
  .growth-gate-inline { grid-template-columns: 1fr; }
}

.decision-workflow-head,
.decision-workflow-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.decision-workflow-head small,
.decision-workflow-summary small {
  color: #56718f;
  font-weight: 800;
  letter-spacing: 0.04em;
}

.decision-workflow-head h2,
.decision-workflow-summary h3 {
  margin: 3px 0 0;
  color: #12283f;
}

.decision-workflow-head > span {
  flex: 0 0 auto;
  padding: 7px 12px;
  border-radius: 999px;
  background: #dce9f7;
  color: #204e7b;
  font-weight: 800;
}

.decision-strategy-groups {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-top: 14px;
  padding: 5px;
  border-radius: 12px;
  background: #dfe8f2;
}
.decision-strategy-groups button {
  min-height: 44px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: #435d77;
  font-size: 16px;
  font-weight: 900;
  cursor: pointer;
}
.decision-strategy-groups button.active {
  background: #153f71;
  color: #fff;
  box-shadow: 0 4px 12px rgba(21, 63, 113, .2);
}

.decision-workflow-tabs {
  display: flex;
  gap: 7px;
  margin-top: 8px;
  padding: 5px;
  border-radius: 12px;
  background: #e8eef5;
  overflow-x: auto;
}

.decision-workflow-tabs button {
  flex: 1 0 112px;
  min-height: 42px;
  padding: 8px 10px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: #425b73;
  font-weight: 800;
  white-space: nowrap;
  cursor: pointer;
}

.decision-workflow-tabs button.active {
  background: #153f71;
  color: #fff;
  box-shadow: 0 4px 12px rgba(21, 63, 113, 0.22);
}

.decision-workflow-body {
  margin-top: 12px;
  padding: 14px;
  border-radius: 13px;
  background: #fff;
  border: 1px solid #dce5ef;
}

.strategy-page-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}
.strategy-page-head small { color: #56718f; font-weight: 800; }
.strategy-page-head h3 { margin: 3px 0 5px; color: #12283f; }
.strategy-page-head p { margin: 0; color: #5d6f82; line-height: 1.55; }
.strategy-page-head button {
  flex: 0 0 auto;
  min-height: 38px;
  padding: 8px 14px;
  border: 0;
  border-radius: 9px;
  background: #153f71;
  color: #fff;
  font-weight: 800;
  cursor: pointer;
}
.strategy-page-head button:disabled { opacity: .58; cursor: wait; }
.strategy-filter-details {
  margin-top: 12px;
  border: 1px solid #d9e4ef;
  border-radius: 10px;
  background: #f8fafc;
  overflow: hidden;
}
.strategy-filter-details summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 12px;
  color: #284a6c;
  font-weight: 800;
  cursor: pointer;
  list-style: none;
}
.strategy-filter-details summary::-webkit-details-marker { display: none; }
.strategy-filter-details summary small { color: #72859a; font-weight: 700; }
.strategy-filter-details[open] summary { border-bottom: 1px solid #d9e4ef; background: #eef4fa; }
.strategy-filter-details .strategy-rules { margin: 10px; }
.strategy-filter-details .strategy-action { margin: 0 10px 10px; }
.strategy-scan-details {
  margin-top: 9px;
  border-radius: 9px;
  background: #f2f5f8;
  color: #607286;
}
.strategy-scan-details summary {
  padding: 8px 10px;
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
}
.strategy-scan-details .strategy-scan-status { margin: 0; padding-top: 2px; }
.strategy-direction-strip {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-top: 10px;
  padding: 9px 10px;
  border-radius: 9px;
  background: #eef8f4;
  color: #176b59;
  overflow-x: auto;
}
.strategy-direction-strip strong,
.strategy-direction-strip span { flex: 0 0 auto; }
.strategy-direction-strip span {
  padding: 4px 8px;
  border: 1px solid #bee4d8;
  border-radius: 999px;
  background: #fff;
  font-size: 12px;
}
.strategy-rules {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin-top: 13px;
}
.strategy-rules span {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 9px 10px;
  border: 1px solid #d9e4ef;
  border-radius: 10px;
  background: #f7fafc;
  color: #425970;
  line-height: 1.45;
}
.strategy-rules b {
  display: inline-grid;
  place-items: center;
  flex: 0 0 22px;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: #e1edf9;
  color: #153f71;
}
.strategy-action,
.strategy-scan-status {
  margin: 11px 0 0;
  padding: 9px 11px;
  border-radius: 9px;
  line-height: 1.5;
}
.strategy-action { background: #eef8f4; color: #176b59; }
.strategy-scan-status { background: #f2f5f8; color: #607286; }
.strategy-stock-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 12px;
}
.strategy-stock-card {
  display: flex;
  min-width: 0;
  flex-direction: column;
  gap: 6px;
  padding: 12px;
  text-align: left;
  border: 1px solid #d9e4ef;
  border-radius: 11px;
  background: #fff;
  color: #41576d;
  cursor: pointer;
}
.strategy-stock-card:hover { border-color: #6c9aca; box-shadow: 0 5px 15px rgba(22, 62, 103, .1); }
.strategy-stock-card strong { min-width: 0; color: #152b42; font-size: 16px; white-space: nowrap; word-break: keep-all; }
.strategy-stock-card-head {
  display: grid;
  grid-template-columns: auto auto minmax(0, 1fr) auto;
  align-items: baseline;
  gap: 8px;
  width: 100%;
  min-width: 0;
}
.strategy-stock-rank {
  display: inline-grid;
  place-items: center;
  width: 24px;
  height: 24px;
  border: 1px solid rgba(184, 45, 63, .25);
  border-radius: 50%;
  background: rgba(184, 45, 63, .09);
  color: #9b2638;
  font-size: 12px;
  font-weight: 900;
  line-height: 1;
}
.strategy-stock-code { color: #5e7288; font-weight: 800; }
.strategy-stock-price { color: #173b61; font-weight: 800; white-space: nowrap; }
.strategy-stock-tech { color: #344f69; font-variant-numeric: tabular-nums; }
.strategy-card-growth {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 10px;
  padding: 7px 9px;
  margin-top: 3px;
  border-radius: 8px;
  background: #fff4d7;
  color: #7d4d00;
}
.strategy-card-growth b { font-size: 14px; color: #9b4f00; }
.strategy-card-growth small { color: #77644b; text-align: right; }
.strategy-card-growth.leader {
  flex-wrap: wrap;
  background: #eaf7f2;
  color: #155d4d;
}
.strategy-card-growth.leader b { color: #08745d; }
.strategy-card-growth.leader small:last-child { flex-basis: 100%; text-align: left; }

.leader-snapshot-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  margin: 10px 0;
}

.leader-snapshot-card {
  display: grid;
  gap: 3px;
  padding: 10px 12px;
  border: 1px solid #d7e2ee;
  border-radius: 12px;
  background: #f8fbff;
}

.leader-snapshot-card small,
.leader-snapshot-card span { color: #65758b; font-size: 12px; line-height: 1.35; }
.leader-snapshot-card strong { color: #16243a; }
.leader-snapshot-card.fresh { border-color: #bde6d7; background: #f2fbf7; }
.leader-snapshot-card.refreshing { border-color: #f0d39a; background: #fff9ed; }
.strategy-auto-refresh-note { margin: -2px 0 10px; color: #53647b; font-size: 12px; }
.leader-detail-priority { grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; }
.leader-detail-priority > div { min-height: 0; align-self: start; }
.leader-detail-priority .leader-stage-card,
.leader-detail-priority .leader-evidence-card { grid-column: 1 / -1; }
.leader-evidence-matrix {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-top: 8px;
}
.leader-evidence-matrix article {
  padding: 9px;
  border: 1px solid #dce5ef;
  border-radius: 9px;
  background: #f8fafc;
}
.leader-evidence-matrix article.pass { border-color: #a9dfca; background: #effaf6; }
.leader-evidence-matrix article.fail { border-color: #f1b9b1; background: #fff4f2; }
.leader-evidence-matrix article.unknown { border-color: #e7d29c; background: #fff9ea; }
.leader-evidence-matrix article em { float: right; font-size: 12px; font-style: normal; }
.leader-evidence-matrix article.pass em { color: #08745d; }
.leader-evidence-matrix article.fail em { color: #b3352d; }
.leader-evidence-matrix article.unknown em { color: #946d09; }
.leader-evidence-matrix article p { margin: 5px 0; }
.leader-evidence-matrix article small { color: #68788c; line-height: 1.4; }
.leader-coverage-audit { border: 1px solid #d5e4f2; background: #f7fbff; }
.leader-coverage-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  padding: 0 10px 10px;
}
.leader-coverage-grid span { display: grid; gap: 3px; padding: 9px; border-radius: 8px; background: #fff; color: #5e7288; }
.leader-coverage-grid b { color: #173b61; }
.leader-coverage-audit p { margin: 0; padding: 0 10px 10px; color: #65758b; line-height: 1.55; }

@media (max-width: 760px) {
  .leader-snapshot-grid,
  .leader-detail-priority,
  .leader-evidence-matrix { grid-template-columns: 1fr; }
  .leader-coverage-grid { grid-template-columns: 1fr; }
}
.strategy-stock-card small { color: #687b8e; line-height: 1.45; }
.strategy-stock-card em { color: #0f6b5d; font-style: normal; font-size: 12px; }
.strategy-card-hit { color: #176b59; font-weight: 800; }
.strategy-empty { grid-column: 1 / -1; padding: 20px; text-align: center; color: #65788c; }

.daily-stock-dialog-head-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}
.daily-stock-focus-button {
  min-height: 36px;
  padding: 7px 13px;
  border: 1px solid #91c9ba;
  border-radius: 8px;
  background: #eaf8f3;
  color: #0f6b5d;
  font-weight: 900;
  cursor: pointer;
}
.daily-stock-focus-button:disabled { cursor: default; opacity: .72; }

.position-remove-button {
  flex: 0 0 auto;
  margin-left: 8px;
  padding: 4px 8px;
  border: 1px solid #efb4b4;
  border-radius: 7px;
  background: #fff1f1;
  color: #b42323;
  font-weight: 800;
  cursor: pointer;
}
.position-remove-button:hover { background: #ffe2e2; }

.decision-workflow-summary p {
  margin: 6px 0 0;
  color: #5d6f82;
}

.decision-workflow-summary button {
  flex: 0 0 auto;
  min-height: 40px;
  padding: 9px 15px;
  border: 0;
  border-radius: 9px;
  background: #0f6b5d;
  color: #fff;
  font-weight: 800;
  cursor: pointer;
}

.decision-workflow-checks,
.unified-decision-gates {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-top: 12px;
}

.workflow-check,
.unified-decision-gate {
  padding: 12px;
  border: 1px solid #dce5ef;
  border-radius: 11px;
  background: #f8fafc;
}

.workflow-check small,
.unified-decision-gate span {
  display: block;
  color: #6b7c8f;
  font-weight: 700;
}

.workflow-check strong,
.unified-decision-gate strong {
  display: block;
  margin-top: 3px;
  color: #16334f;
}

.workflow-check p,
.unified-decision-gate small {
  display: block;
  margin: 6px 0 0;
  color: #607286;
  line-height: 1.55;
}

.workflow-check.pass,
.unified-decision-gate.pass { border-left: 4px solid #159471; background: #f1fbf7; }
.workflow-check.near,
.unified-decision-gate.pending { border-left: 4px solid #d59a1b; background: #fff9ec; }
.workflow-check.risk,
.unified-decision-gate.fail { border-left: 4px solid #c94848; background: #fff4f4; }
.workflow-check.watch { border-left: 4px solid #6d8094; }

.unified-decision-hero {
  border-left: 5px solid #6d8094;
}

.unified-decision-hero.strong,
.unified-action-card.strong { border-left-color: #159471; background: #f1fbf7; }
.unified-decision-hero.near,
.unified-action-card.near { border-left-color: #d59a1b; background: #fff9ec; }
.unified-decision-hero.risk,
.unified-action-card.risk { border-left-color: #c94848; background: #fff4f4; }
.unified-decision-hero.holding,
.unified-action-card.holding { border-left-color: #3469b0; background: #f1f6fd; }

.unified-decision-gates {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

@media (max-width: 900px) {
  .decision-workflow-panel { margin: 10px 10px 8px; padding: 12px; }
  .decision-workflow-checks { grid-template-columns: 1fr; }
  .strategy-rules { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .decision-workflow-head,
  .decision-workflow-summary { align-items: flex-start; }
}

@media (max-width: 560px) {
  .decision-workflow-panel { margin: 8px 0; padding: 10px; }
  .decision-workflow-body { padding: 10px; }
  .decision-workflow-head,
  .decision-workflow-summary { display: grid; grid-template-columns: 1fr; }
  .decision-workflow-head > span,
  .decision-workflow-summary button { justify-self: start; }
  .unified-decision-gates { grid-template-columns: 1fr; }
  .strategy-page-head { display: grid; grid-template-columns: 1fr; }
  .strategy-rules,
  .strategy-stock-grid { grid-template-columns: 1fr; }
  .strategy-stock-card { padding: 11px; }
  .strategy-stock-card-head { grid-template-columns: auto auto minmax(0, 1fr) auto; gap: 7px; }
  .strategy-stock-card-head strong { overflow: visible; text-overflow: clip; }
  .strategy-card-growth { display: grid; grid-template-columns: 1fr; gap: 4px; }
  .strategy-card-growth small { text-align: left; }
}

/* v204: one holdings workspace, with buy/sell as two short, touch-friendly pages. */
:root { color-scheme: only light; }
body.holdings-open .arsa-workspace-head,
body.holdings-open .arsa-tabs { display: none; }
body.holdings-open .arsa-workspace-body { border-radius: 16px; }
.holding-workspace-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 14px;
  border: 1px solid #dfc8cd;
  border-radius: 13px;
  background: #fff9f8;
}
.holding-workspace-top small { color: #8c3d4a; font-weight: 800; }
.holding-workspace-top h2 { margin: 3px 0; color: #342e35; font-size: 1.15rem; }
.holding-workspace-top p { margin: 0; color: #687079; }
.holding-workspace-top button {
  flex: 0 0 auto;
  min-height: 42px;
  padding: 8px 13px;
  border: 1px solid #a63142;
  border-radius: 9px;
  color: #fff;
  background: #a63142;
  font: inherit;
  font-weight: 800;
  cursor: pointer;
}
.holding-stock-tabs { display: flex; gap: 8px; margin: 12px 0; overflow-x: auto; padding: 2px 1px 6px; }
.holding-stock-tabs button {
  display: grid;
  gap: 2px;
  flex: 0 0 auto;
  min-width: 145px;
  padding: 10px 13px;
  border: 1px solid #dfc8cd;
  border-radius: 11px;
  color: #483e43;
  background: #fff;
  text-align: left;
  font: inherit;
  cursor: pointer;
}
.holding-stock-tabs button.active { border-color: #a63142; background: #fff0f1; box-shadow: inset 0 0 0 1px #a63142; }
.holding-stock-tabs small { color: #786c71; }
.arsa-position-key-facts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.arsa-position-key-facts span { min-width: 0; padding: 10px; border-radius: 9px; background: #f6f4f2; color: #685b60; }
.arsa-position-key-facts b { color: #672832; }
.holding-action-strip { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; padding: 11px; border-radius: 10px; background: #eaf4f5; }
.holding-action-strip.risk { background: #fae7e9; }
.holding-action-strip.profit { background: #fff1d9; }
.holding-action-strip.add { background: #e6f5ef; }
.holding-action-strip > div { display: grid; gap: 2px; min-width: 0; }
.holding-action-strip small { color: #67757b; font-weight: 800; }
.holding-action-strip strong { color: #333e42; overflow-wrap: anywhere; }
.holding-action-strip details { flex: 0 0 auto; }
.holding-action-strip summary { color: #6e3440; cursor: pointer; font-size: .85rem; font-weight: 800; }
.holding-action-strip p { max-width: 28rem; margin: 5px 0 0; color: #4a5054; line-height: 1.5; }
.arsa-trade-entry {
  display: grid;
  gap: 10px;
  padding: 14px;
  border: 1px solid #cda2aa;
  border-radius: 12px;
  background: #fffaf9;
}
.arsa-trade-entry > header { display: grid; gap: 2px; }
.arsa-trade-entry > header strong { color: #632530; font-size: 1rem; }
.arsa-trade-entry > header small { color: #72676a; line-height: 1.4; }
.arsa-trade-entry-tabs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.arsa-trade-entry-tabs button {
  min-height: 44px;
  border: 1px solid #d8c3c7;
  border-radius: 9px;
  color: #684a51;
  background: #fff;
  font: inherit;
  font-weight: 800;
  cursor: pointer;
}
.arsa-trade-entry-tabs button.active { border-color: #a63142; color: #fff; background: #a63142; }
.arsa-trade-entry-card { min-width: 0; padding: 12px; border: 1px solid #eadcde; border-radius: 10px; background: #fff; }
.arsa-buy-form,
.arsa-trade-entry-card .arsa-sale-form { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)) auto; gap: 8px; align-items: end; margin: 0; }
.arsa-buy-form label { display: grid; gap: 4px; min-width: 0; color: #71545a; font-size: .82rem; font-weight: 800; }
.arsa-buy-form input { width: 100%; min-width: 0; min-height: 42px; padding: 8px; border: 1px solid #d8c7ca; border-radius: 8px; background: #fff; color: #342e35; font: inherit; }
.arsa-trade-entry-card .arsa-sale-form input,
.arsa-trade-entry-card .arsa-sale-form select { min-height: 42px; }
.arsa-buy-form button,
.arsa-trade-entry-card .arsa-sale-form button { min-height: 42px; padding: 8px 13px; border: 1px solid #a63142; border-radius: 8px; color: #fff; background: #a63142; font: inherit; font-weight: 800; cursor: pointer; }
.arsa-position-diagnostics,
.holding-portfolio-details { padding: 11px; border: 1px solid #e3d5d7; border-radius: 11px; background: #fff; }
.arsa-position-diagnostics summary,
.holding-portfolio-details summary { color: #6f1f2e; font-weight: 800; cursor: pointer; }
.arsa-position-diagnostics .arsa-position-metrics,
.arsa-position-diagnostics .arsa-exit-ladder { margin-top: 12px; }
.holding-portfolio-details { margin-top: 12px; }
.holding-portfolio-details .arsa-disclosure { margin-bottom: 0; }
@media (max-width: 760px) {
  .system-view-tabs { display: flex; width: calc(100% - 20px); overflow-x: auto; border-radius: 13px; }
  .system-view-tabs button { flex: 0 0 auto; min-height: 42px; white-space: nowrap; }
  .holding-workspace-top { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 8px; padding: 9px 11px; }
  .holding-workspace-top h2, .holding-workspace-top p { display: none; }
  .holding-workspace-top button { width: auto; min-height: 40px; padding: 7px 10px; font-size: .86rem; }
  .holding-stock-tabs { margin: 7px 0; }
  .arsa-workspace-body { padding: 10px; }
  .arsa-position-card.detailed { gap: 10px; padding: 11px; min-width: 0; }
  .arsa-position-key-facts { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 5px; }
  .arsa-position-key-facts span { padding: 7px 5px; font-size: .8rem; text-align: center; }
  .arsa-position-key-facts span:last-child { grid-column: auto; }
  .holding-action-strip { display: grid; }
  .arsa-buy-form,
  .arsa-trade-entry-card .arsa-sale-form { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .arsa-buy-form button,
  .arsa-trade-entry-card .arsa-sale-form button { grid-column: 1 / -1; }
  .arsa-buy-form input,
  .arsa-trade-entry-card input,
  .arsa-trade-entry-card select { font-size: 16px; }
}

@media (max-width: 390px) {
  .strategy-stock-card-head { grid-template-columns: auto auto minmax(0, 1fr); }
  .strategy-stock-price { grid-column: 2 / -1; justify-self: start; }
}

/* Local preview v155: full cyber bull artwork + layered data glass. */
body {
  background-color: #fdf7f6;
  background-image:
    linear-gradient(90deg, rgba(255, 252, 251, 0.76) 0%, rgba(255, 247, 246, 0.52) 42%, rgba(255, 244, 243, 0.16) 100%),
    url("./assets/cyber-bull-background-v1.webp");
  background-position: center top;
  background-size: cover;
  background-repeat: no-repeat;
  background-attachment: fixed;
}

.app-shell {
  background: linear-gradient(90deg, rgba(255, 247, 246, 0.10), rgba(255,255,255,0.02));
}

.main-panel {
  background: linear-gradient(90deg, rgba(255, 250, 249, 0.18), rgba(255,255,255,0.03));
}

.side-panel {
  background:
    radial-gradient(circle at 18% 0%, rgba(236, 74, 91, 0.28), transparent 17rem),
    linear-gradient(180deg, rgba(42, 17, 23, 0.94), rgba(20, 12, 16, 0.91) 60%, rgba(36, 16, 22, 0.94));
  backdrop-filter: blur(18px) saturate(118%);
}

.brand-mark {
  font-size: 20px;
  box-shadow:
    0 0 0 3px rgba(218, 55, 72, 0.13),
    0 0 22px rgba(219, 50, 70, 0.24),
    0 0 28px rgba(22, 140, 158, 0.14);
}

.access-gate {
  background: linear-gradient(135deg, rgba(54, 14, 23, 0.50), rgba(255, 244, 242, 0.20));
  backdrop-filter: blur(10px);
}

.access-card,
.position-dialog,
.daily-stock-dialog,
.market-index-dialog {
  border: 1px solid rgba(206, 103, 113, 0.34);
  background: rgba(255, 252, 251, 0.90);
  box-shadow: 0 24px 70px rgba(88, 22, 32, 0.24), inset 0 1px 0 rgba(255,255,255,.94);
  backdrop-filter: blur(22px) saturate(120%);
}

.top-strip,
.mobile-app-bar,
.decision-workflow-panel,
.daily-standards-panel,
.metric-tile,
.search-box,
.table-zone,
.insight-zone,
.seasonal-window-summary-card,
.seasonal-current-market {
  background-color: rgba(255, 252, 251, 0.77);
  box-shadow:
    0 12px 32px rgba(104, 26, 37, 0.10),
    inset 0 1px 0 rgba(255,255,255,.94),
    inset 0 0 28px rgba(255, 235, 235, 0.13);
  backdrop-filter: blur(18px) saturate(118%);
}

.top-strip,
.decision-workflow-panel,
.daily-standards-panel,
.seasonal-window-summary-card {
  border-color: rgba(194, 67, 80, 0.36);
}

.top-strip::before,
.decision-workflow-panel::before,
.daily-standards-panel::before {
  content: "";
  display: block;
  height: 1px;
  margin: -1px 10px 8px;
  background: linear-gradient(90deg, transparent, rgba(204, 45, 63, 0.68), rgba(28, 160, 170, 0.52), transparent);
  box-shadow: 0 0 10px rgba(204, 45, 63, 0.22);
  pointer-events: none;
}

.decision-workflow-panel {
  background-image: linear-gradient(135deg, rgba(255,253,252,.86), rgba(255,239,239,.70) 62%, rgba(235,250,250,.68));
}

.decision-workflow-body,
.daily-top-pool,
.daily-standard-card,
.strategy-stock-card,
.company-profile-lead article,
.company-profile-context article,
.company-profile-group,
.company-profile-secondary,
.workflow-check,
.unified-decision-gate,
.leader-snapshot-card {
  background-color: rgba(255, 253, 252, 0.74);
  backdrop-filter: blur(12px) saturate(115%);
}

.daily-top-pool.innovation,
.daily-top-pool.broad,
.daily-top-pool.technical,
.daily-top-pool.comprehensive,
.daily-top-pool.growth {
  background-image: linear-gradient(135deg, rgba(255,253,252,.78), rgba(255,239,239,.58) 68%, rgba(235,250,250,.52));
}

.source-tabs,
.workspace-tabs,
.daily-ranking-tabs,
.decision-strategy-groups,
.decision-workflow-tabs {
  background: linear-gradient(135deg, rgba(249, 229, 229, 0.74), rgba(246, 239, 239, 0.68) 72%, rgba(233, 249, 249, 0.70));
  backdrop-filter: blur(12px);
}

.source-tabs button.active,
.workspace-tabs button.active,
.workspace-tabs button[data-workspace="rightSide"].active,
.workspace-tabs button[data-workspace="leftSide"].active,
.top-strip .entry-nav-group button.active,
.daily-ranking-tabs button.active,
.decision-strategy-groups button.active,
.decision-workflow-tabs button.active {
  background:
    linear-gradient(135deg, rgba(124, 23, 38, .98), rgba(196, 53, 69, .94)),
    linear-gradient(90deg, transparent, rgba(35, 187, 197, .20));
  box-shadow:
    0 5px 17px rgba(149, 31, 46, 0.25),
    inset 0 0 0 1px rgba(255,255,255,.18),
    0 0 14px rgba(29, 158, 168, 0.08);
}

.metric-tile:hover,
.metric-tile.active,
.daily-standard-card:hover,
.daily-standard-card:focus-visible,
.strategy-stock-card:hover,
.strategy-stock-card:focus-visible {
  background: rgba(255, 253, 252, 0.90);
  border-color: #64b8bf;
  box-shadow: 0 8px 22px rgba(22, 140, 158, 0.14), inset 3px 0 0 #b3293b;
}

@media (max-width: 760px) {
  body {
    background-image:
      linear-gradient(180deg, rgba(255, 250, 249, 0.64), rgba(255, 247, 246, 0.34)),
      url("./assets/cyber-bull-background-v1.webp");
    background-position: 68% top;
    background-size: auto 100vh;
    background-repeat: no-repeat;
    background-attachment: fixed;
  }

  .top-strip,
  .mobile-app-bar,
  .decision-workflow-panel,
  .daily-standards-panel,
  .metric-tile,
  .search-box,
  .table-zone,
  .insight-zone {
    background-color: rgba(255, 252, 251, 0.84);
    backdrop-filter: blur(16px) saturate(112%);
  }
}

/* Light crimson cyber theme: decoration stays separate from rise/fall semantics. */
:root {
  --bg: #fff9f8;
  --panel: #fffdfc;
  --ink: #2d2024;
  --muted: #78676c;
  --line: #ead4d5;
  --red: #d33140;
  --blue: #a72b3a;
  --accent: #b52e3d;
  --shadow: 0 10px 30px rgba(113, 31, 41, 0.09);
}

body {
  background-color: #fff9f8;
  background-image:
    radial-gradient(circle at 94% 4%, rgba(20, 139, 155, 0.07), transparent 23rem),
    radial-gradient(circle at 12% 0%, rgba(190, 49, 65, 0.10), transparent 28rem),
    linear-gradient(rgba(164, 42, 57, 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(164, 42, 57, 0.025) 1px, transparent 1px),
    linear-gradient(145deg, #fffdfc 0%, #fff6f5 58%, #f8fcfc 100%);
  background-size: auto, auto, 28px 28px, 28px 28px, auto;
  background-attachment: fixed;
}

.side-panel {
  border-right: 1px solid rgba(217, 86, 100, 0.38);
  background:
    radial-gradient(circle at 20% 0%, rgba(215, 67, 84, 0.22), transparent 16rem),
    linear-gradient(180deg, #2a1117 0%, #160e12 58%, #211016 100%);
  box-shadow: 8px 0 26px rgba(82, 22, 30, 0.13);
}

.brand-block,
.panel-section {
  border-color: rgba(255, 190, 197, 0.16);
}

.brand-mark {
  border: 1px solid rgba(255, 214, 217, 0.76);
  background: linear-gradient(145deg, #f8c8c9, #e58b91);
  color: #671522;
  box-shadow: 0 0 0 3px rgba(213, 56, 73, 0.10), 0 0 18px rgba(22, 140, 158, 0.14);
}

.sidebar-toggle {
  border-color: #ecc4c7;
  background: #fff9f8;
  color: #8f2634;
}

.sidebar-toggle:hover,
.sidebar-toggle:focus-visible {
  border-color: #58aeb7;
  background: #f2fbfb;
  color: #167d89;
  box-shadow: 0 0 0 3px rgba(22, 140, 158, 0.12);
  outline: none;
}

.focus-core-filter,
.market-index-card,
.source-box {
  border-color: rgba(255, 196, 202, 0.17);
  background: rgba(255, 239, 241, 0.055);
}

.market-index-card:hover,
.market-index-card:focus-visible {
  border-color: rgba(91, 194, 203, 0.64);
  background: rgba(32, 145, 156, 0.10);
}

.side-action,
.focus-add-button {
  border-color: rgba(255, 210, 214, 0.42);
  background: linear-gradient(135deg, #8f2030, #c33d4a);
  color: #fff;
  box-shadow: 0 6px 16px rgba(151, 35, 49, 0.22);
}

.side-action:hover,
.focus-add-button:hover {
  background: linear-gradient(135deg, #7d1b29, #af303f);
}

.keyword-chip {
  border-color: rgba(238, 144, 154, 0.42);
  background: rgba(203, 61, 77, 0.13);
  color: #ffd9dc;
}

.keyword-chip button { color: #ffd9dc; }

.top-strip,
.mobile-app-bar {
  border-color: rgba(204, 91, 103, 0.33);
  background: rgba(255, 251, 250, 0.92);
  box-shadow: 0 10px 28px rgba(117, 31, 41, 0.10), inset 0 1px 0 rgba(255,255,255,.92);
  backdrop-filter: blur(14px);
}

.source-tabs,
.workspace-tabs,
.daily-ranking-tabs,
.decision-strategy-groups,
.decision-workflow-tabs {
  border: 1px solid #efd4d5;
  background: linear-gradient(135deg, #f9e9e8, #f7eeee 70%, #eef9f9);
}

.source-tabs button,
.workspace-tabs button,
.daily-ranking-tabs button,
.decision-strategy-groups button,
.decision-workflow-tabs button {
  color: #67474e;
}

.source-tabs button.active,
.workspace-tabs button.active,
.workspace-tabs button[data-workspace="rightSide"].active,
.workspace-tabs button[data-workspace="leftSide"].active,
.top-strip .entry-nav-group button.active,
.daily-ranking-tabs button.active,
.decision-strategy-groups button.active,
.decision-workflow-tabs button.active {
  border-color: #c84c59;
  background: linear-gradient(135deg, #8e1f2e, #c43e4b);
  color: #fff;
  box-shadow: 0 5px 14px rgba(156, 35, 49, 0.22), inset 0 0 0 1px rgba(255,255,255,.16);
}

.source-tabs button:hover,
.workspace-tabs button:hover,
.daily-ranking-tabs button:hover,
.decision-strategy-groups button:hover,
.decision-workflow-tabs button:hover {
  border-color: #8dc8cd;
  background: #f3fbfb;
  color: #176f79;
}

.top-strip .entry-nav-group {
  border-color: #e8b6bb;
  background: linear-gradient(135deg, #fff5f4, #fae8e8);
}

.decision-workflow-panel {
  border-color: #e6c3c5;
  border-left-color: #a82c3b;
  background: linear-gradient(135deg, rgba(255,253,252,.98), rgba(255,244,243,.95) 64%, rgba(241,250,250,.96));
  box-shadow: 0 10px 30px rgba(118, 31, 41, 0.09), inset 0 1px 0 #fff;
}

.decision-workflow-head small,
.strategy-page-head small {
  color: #9c3f4a;
}

.decision-workflow-head h2,
.decision-workflow-summary h3,
.strategy-page-head h3 {
  color: #4f1d26;
}

.decision-workflow-head > span {
  border: 1px solid #e7b8bc;
  background: #fbe6e6;
  color: #8f2634;
}

.decision-workflow-body,
.daily-standards-panel,
.metric-tile,
.search-box,
.table-zone,
.insight-zone {
  border-color: #ead5d6;
  background-color: rgba(255, 253, 252, 0.96);
  box-shadow: var(--shadow), inset 0 1px 0 rgba(255,255,255,.9);
}

.daily-standards-panel {
  border-left-color: #ad2c3b;
  background: linear-gradient(135deg, rgba(255,253,252,.98), rgba(255,244,243,.95) 72%, rgba(242,250,250,.95));
}

.daily-standards-head span,
.daily-standard-card small,
.daily-standards-rule {
  color: #77676c;
}

.daily-standards-head h2,
.daily-top-pool-head strong,
.daily-standard-price strong {
  color: #38252a;
}

.daily-top-pool,
.daily-standard-card,
.strategy-stock-card,
.company-profile-lead article,
.company-profile-context article,
.company-profile-group,
.company-profile-secondary {
  border-color: #ead6d7;
  background: rgba(255, 253, 252, 0.92);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.92);
}

.daily-standard-card:hover,
.daily-standard-card:focus-visible,
.strategy-stock-card:hover,
.strategy-stock-card:focus-visible {
  border-color: #61b5bd;
  box-shadow: 0 5px 16px rgba(22, 140, 158, 0.12), inset 3px 0 0 #ad2c3b;
  outline: none;
}

.daily-standard-rank,
.daily-top-pool-head > b {
  background: #f8dddd;
  color: #982a37;
}

.company-profile-tags b {
  border: 1px solid rgba(22, 140, 158, 0.15);
  background: #edf8f8;
  color: #176f79;
}

.company-profile-group h4,
.company-profile-lead strong,
.company-profile-context strong,
.company-profile-group-grid strong {
  color: #4b2028;
}

.company-profile-group-grid > div {
  border: 1px solid #f0dfe0;
  background: #fff8f7;
}

input:focus,
textarea:focus {
  border-color: #4aa7b0;
  box-shadow: 0 0 0 3px rgba(22, 140, 158, 0.13);
}

.main-panel a { color: #147b88; }

* {
  scrollbar-color: #d48b92 #f8ebea;
}

@media (max-width: 760px) {
  body {
    background-image:
      radial-gradient(circle at 100% 0%, rgba(22, 140, 158, 0.06), transparent 15rem),
      linear-gradient(155deg, #fffdfc, #fff5f4);
    background-attachment: scroll;
  }

  .mobile-app-bar {
    border-bottom-color: #e8c5c7;
    background: rgba(255, 249, 248, 0.96);
  }
}

/* Preview priority layer: keep the artwork above the base color theme. */
body {
  background-color: #fdf7f6;
  background-image:
    linear-gradient(90deg, rgba(255, 252, 251, 0.76) 0%, rgba(255, 247, 246, 0.52) 42%, rgba(255, 244, 243, 0.16) 100%),
    url("./assets/cyber-bull-background-v1.webp");
  background-position: center top;
  background-size: cover;
  background-repeat: no-repeat;
  background-attachment: fixed;
}

.side-panel {
  background:
    radial-gradient(circle at 18% 0%, rgba(236, 74, 91, 0.28), transparent 17rem),
    linear-gradient(180deg, rgba(42, 17, 23, 0.94), rgba(20, 12, 16, 0.91) 60%, rgba(36, 16, 22, 0.94));
  backdrop-filter: blur(18px) saturate(118%);
}

.access-card,
.position-dialog,
.daily-stock-dialog,
.market-index-dialog,
.top-strip,
.mobile-app-bar,
.decision-workflow-panel,
.daily-standards-panel,
.metric-tile,
.search-box,
.table-zone,
.insight-zone,
.seasonal-window-summary-card,
.seasonal-current-market {
  background-color: rgba(255, 252, 251, 0.78);
  box-shadow: 0 12px 32px rgba(104, 26, 37, 0.10), inset 0 1px 0 rgba(255,255,255,.94);
  backdrop-filter: blur(18px) saturate(118%);
}

.decision-workflow-body,
.daily-top-pool,
.daily-standard-card,
.strategy-stock-card,
.company-profile-lead article,
.company-profile-context article,
.company-profile-group,
.company-profile-secondary,
.workflow-check,
.unified-decision-gate,
.leader-snapshot-card {
  background-color: rgba(255, 253, 252, 0.76);
  backdrop-filter: blur(12px) saturate(115%);
}

.source-tabs,
.workspace-tabs,
.daily-ranking-tabs,
.decision-strategy-groups,
.decision-workflow-tabs {
  background: linear-gradient(135deg, rgba(249, 229, 229, 0.76), rgba(246, 239, 239, 0.70) 72%, rgba(233, 249, 249, 0.72));
  backdrop-filter: blur(12px);
}

@media (max-width: 760px) {
  body {
    background-image:
      linear-gradient(180deg, rgba(255, 250, 249, 0.66), rgba(255, 247, 246, 0.36)),
      url("./assets/cyber-bull-background-v1.webp");
    background-position: 68% top;
    background-size: auto 100vh;
    background-repeat: no-repeat;
    background-attachment: fixed;
  }

  .top-strip,
  .mobile-app-bar,
  .decision-workflow-panel,
  .daily-standards-panel,
  .metric-tile,
  .search-box,
  .table-zone,
  .insight-zone {
    background-color: rgba(255, 252, 251, 0.85);
    backdrop-filter: blur(16px) saturate(112%);
  }
}

/* Local preview v156: permanent bull window + bull strip in every stock detail card. */
:root { --cyber-bull-rail-width: clamp(230px, 17vw, 340px); }

.app-shell {
  position: relative;
  z-index: 1;
  padding-right: var(--cyber-bull-rail-width);
}

.cyber-bull-showcase {
  position: fixed;
  z-index: 8;
  top: 0;
  right: 0;
  bottom: 0;
  width: var(--cyber-bull-rail-width);
  border-left: 1px solid rgba(192, 54, 70, 0.38);
  background-image:
    linear-gradient(180deg, rgba(255, 249, 248, 0.18), rgba(84, 12, 26, 0.08)),
    url("./assets/cyber-bull-background-v1.webp");
  background-repeat: no-repeat;
  background-position: center, 70% center;
  background-size: cover, 880px auto;
  box-shadow: inset 18px 0 34px rgba(255, 247, 246, 0.54), -10px 0 28px rgba(111, 26, 38, 0.10);
  pointer-events: none;
}

.cyber-bull-showcase::before,
.cyber-bull-showcase::after {
  content: "";
  position: absolute;
  left: 9%;
  right: 9%;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(201, 42, 61, .82), rgba(31, 180, 190, .58), transparent);
  box-shadow: 0 0 12px rgba(201, 42, 61, .48);
}

.cyber-bull-showcase::before { top: 12%; }
.cyber-bull-showcase::after { bottom: 12%; }

.daily-stock-bull-banner {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 270px;
  align-items: stretch;
  min-height: 138px;
  overflow: hidden;
  border: 1px solid rgba(194, 67, 80, 0.38);
  border-left: 5px solid #a62839;
  border-radius: 12px;
  background:
    radial-gradient(circle at 20% 50%, rgba(197, 47, 65, .16), transparent 13rem),
    linear-gradient(110deg, rgba(255, 250, 249, .96), rgba(255, 232, 232, .78) 58%, rgba(232, 248, 249, .74));
  box-shadow: 0 8px 24px rgba(112, 26, 39, 0.10), inset 0 1px 0 rgba(255,255,255,.9);
}

.daily-stock-bull-banner img {
  grid-column: 2;
  width: 100%;
  height: 138px;
  object-fit: contain;
  object-position: right center;
  filter: saturate(1.12) contrast(1.02);
}

.daily-stock-bull-energy {
  position: absolute;
  z-index: 1;
  left: 4%;
  top: 50%;
  width: 58%;
  height: 2px;
  background: linear-gradient(90deg, transparent, rgba(196, 44, 62, .82), rgba(20, 155, 166, .65), transparent);
  box-shadow: 0 0 14px rgba(196, 44, 62, .38);
  transform: skewY(-7deg);
}

.daily-stock-bull-banner::before,
.daily-stock-bull-banner::after {
  content: "";
  position: absolute;
  left: 5%;
  width: 42%;
  height: 28px;
  border-top: 1px solid rgba(174, 47, 62, .20);
  border-bottom: 1px solid rgba(27, 151, 162, .18);
  transform: skewY(-7deg);
}

.daily-stock-bull-banner::before { top: 28%; }
.daily-stock-bull-banner::after { bottom: 16%; }

@media (max-width: 1180px) {
  :root { --cyber-bull-rail-width: 0px; }
  .app-shell { padding-right: 0; }

  .cyber-bull-showcase {
    top: 72px;
    right: 12px;
    bottom: auto;
    width: 112px;
    height: 150px;
    overflow: hidden;
    border: 1px solid rgba(190, 60, 75, .42);
    border-radius: 16px;
    background-position: center, 70% center;
    background-size: cover, 360px auto;
    box-shadow: 0 10px 28px rgba(88, 19, 31, .20), inset 0 0 18px rgba(255,255,255,.46);
  }
}

@media (max-width: 760px) {
  .cyber-bull-showcase {
    top: 70px;
    right: 8px;
    width: 88px;
    height: 118px;
    border-radius: 13px;
    background-size: cover, 285px auto;
    opacity: .92;
  }

  .daily-stock-bull-banner {
    grid-template-columns: minmax(0, 1fr) 170px;
    min-height: 102px;
  }

  .daily-stock-bull-banner img { height: 102px; }
}

/* Local preview v157: trading workbench order + layered cyber glass. */
:root { --cyber-bull-rail-width: 0px; }

.app-shell { padding-right: 0; }
.cyber-bull-showcase { display: none; }

body {
  background-color: #f7eeee;
  background-image:
    linear-gradient(90deg, rgba(255, 250, 249, .56) 0%, rgba(255, 247, 246, .28) 38%, rgba(255, 242, 241, .05) 100%),
    repeating-linear-gradient(0deg, rgba(185, 42, 59, .035) 0, rgba(185, 42, 59, .035) 1px, transparent 1px, transparent 34px),
    repeating-linear-gradient(90deg, rgba(23, 155, 167, .032) 0, rgba(23, 155, 167, .032) 1px, transparent 1px, transparent 34px),
    url("./assets/cyber-bull-background-v1.webp");
  background-position: center, center, center, 68% center;
  background-size: auto, 34px 34px, 34px 34px, cover;
  background-repeat: no-repeat, repeat, repeat, no-repeat;
  background-attachment: fixed;
}

.main-panel { background: transparent; }

/* Keep the frequently used holding workspace before the long strategy list. */
.main-panel > .mobile-app-bar { order: 0; }
.main-panel > .top-strip { order: 1; }
.main-panel > .workspace-grid { order: 2; }
.main-panel > .seasonal-window-hero { order: 3; }
.main-panel > .decision-workflow-panel { order: 4; }
.main-panel > .daily-standards-panel { order: 5; }

.top-strip {
  position: sticky;
  top: 0;
  z-index: 24;
  background: rgba(255, 248, 247, .66);
  border-color: rgba(188, 46, 64, .38);
  box-shadow: 0 9px 26px rgba(77, 18, 30, .12), inset 0 1px 0 rgba(255,255,255,.78);
  backdrop-filter: blur(15px) saturate(125%);
}

.seasonal-window-hero,
.decision-workflow-panel,
.daily-standards-panel,
.workspace-grid .table-zone,
.workspace-grid .insight-zone {
  background-color: rgba(255, 249, 248, .58);
  background-image: linear-gradient(135deg, rgba(255,255,255,.46), rgba(255,232,233,.24) 68%, rgba(226,248,249,.22));
  border-color: rgba(183, 45, 62, .34);
  box-shadow: 0 12px 30px rgba(83, 19, 31, .10), inset 0 1px 0 rgba(255,255,255,.72);
  backdrop-filter: blur(13px) saturate(120%);
}

.decision-workflow-body {
  background: rgba(255, 250, 249, .58);
  border-color: rgba(186, 67, 80, .27);
  backdrop-filter: blur(10px) saturate(112%);
}

.strategy-filter-details,
.strategy-scan-details,
.strategy-stock-card,
.daily-standard-card,
.metric-tile,
.search-box,
.company-profile-lead article,
.company-profile-context article,
.company-profile-group,
.company-profile-secondary {
  background-color: rgba(255, 253, 252, .82);
  border-color: rgba(191, 92, 102, .27);
  backdrop-filter: none;
}

.strategy-results-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  margin-top: 12px;
  padding: 10px 12px;
  border: 1px solid rgba(186, 65, 78, .28);
  border-radius: 10px;
  background: linear-gradient(90deg, rgba(255, 244, 243, .78), rgba(235, 249, 249, .68));
}

.strategy-results-toolbar > div {
  display: flex;
  align-items: baseline;
  gap: 10px;
  min-width: 0;
}

.strategy-results-toolbar strong { color: #742332; }
.strategy-results-toolbar small { color: #718093; }
.strategy-results-toolbar button {
  flex: 0 0 auto;
  min-height: 34px;
  padding: 7px 13px;
  border: 1px solid rgba(29, 156, 168, .42);
  border-radius: 999px;
  background: rgba(244, 253, 253, .88);
  color: #126d77;
  font-weight: 800;
  cursor: pointer;
}

.strategy-stock-grid.is-collapsed .strategy-stock-card:nth-child(n + 7) { display: none; }

/* Sidebar gets its own dark cyber identity instead of a flat burgundy fill. */
.side-panel {
  isolation: isolate;
  border-right: 1px solid rgba(38, 203, 214, .46);
  background-color: rgba(21, 8, 14, .88);
  background-image:
    radial-gradient(circle at 22% 2%, rgba(225, 48, 70, .36), transparent 16rem),
    linear-gradient(118deg, transparent 0 47%, rgba(29, 187, 198, .10) 48%, transparent 49% 100%),
    repeating-linear-gradient(0deg, rgba(255, 103, 119, .055) 0, rgba(255, 103, 119, .055) 1px, transparent 1px, transparent 27px),
    repeating-linear-gradient(90deg, rgba(45, 200, 211, .045) 0, rgba(45, 200, 211, .045) 1px, transparent 1px, transparent 27px),
    linear-gradient(180deg, rgba(43, 14, 23, .94), rgba(15, 9, 15, .91) 58%, rgba(34, 13, 22, .94));
  background-size: auto, auto, 27px 27px, 27px 27px, auto;
  box-shadow: 9px 0 30px rgba(55, 9, 19, .24), inset -1px 0 0 rgba(228, 57, 76, .34);
  backdrop-filter: blur(14px) saturate(126%);
}

.side-panel::before,
.side-panel::after {
  content: "";
  position: absolute;
  z-index: 0;
  left: 8%;
  right: 8%;
  height: 1px;
  pointer-events: none;
}

.side-panel::before {
  top: 82px;
  background: linear-gradient(90deg, transparent, #ef5367, #31c6cf, transparent);
  box-shadow: 0 0 13px rgba(238, 62, 84, .72);
}

.side-panel::after {
  bottom: 24px;
  background: linear-gradient(90deg, transparent, rgba(43, 197, 207, .72), rgba(230, 56, 78, .64), transparent);
  box-shadow: 0 0 12px rgba(42, 193, 203, .40);
}

.side-panel > * { position: relative; z-index: 1; }
.brand-block { background: linear-gradient(90deg, rgba(189, 41, 60, .12), rgba(26, 169, 181, .06)); }
.brand-mark {
  border-color: rgba(255, 126, 139, .78);
  box-shadow: 0 0 0 2px rgba(226, 55, 75, .12), 0 0 18px rgba(230, 55, 77, .48), 0 0 28px rgba(35, 191, 201, .18);
}
.panel-section {
  border-bottom-color: rgba(255, 115, 130, .18);
  background: linear-gradient(90deg, rgba(219, 55, 75, .035), transparent 65%, rgba(30, 177, 188, .035));
}
.panel-section h2 { text-shadow: 0 0 11px rgba(243, 76, 96, .22); }

@media (max-width: 760px) {
  body {
    background-image:
      linear-gradient(180deg, rgba(255, 249, 248, .57), rgba(255, 246, 245, .24)),
      repeating-linear-gradient(0deg, rgba(185, 42, 59, .03) 0, rgba(185, 42, 59, .03) 1px, transparent 1px, transparent 30px),
      url("./assets/cyber-bull-background-v1.webp");
    background-position: center, center, 70% top;
    background-size: auto, 30px 30px, auto 100vh;
    background-repeat: no-repeat, repeat, no-repeat;
    background-attachment: fixed;
  }

  .top-strip { top: 68px; }
  .strategy-results-toolbar,
  .strategy-results-toolbar > div { align-items: stretch; flex-direction: column; }
  .strategy-results-toolbar button { width: 100%; }
}

/* v160: stock detail title bar becomes a compact cyber-glass command header. */
.daily-stock-dialog .position-dialog-head {
  position: sticky;
  top: 0;
  z-index: 20;
  min-height: 66px;
  margin: 0;
  padding: 11px 14px;
  overflow: hidden;
  border: 1px solid rgba(183, 54, 70, .34);
  border-radius: 14px;
  background:
    linear-gradient(102deg, rgba(255, 248, 247, .84), rgba(255, 232, 233, .67) 58%, rgba(226, 248, 249, .64));
  box-shadow:
    0 9px 24px rgba(89, 20, 32, .12),
    inset 0 1px 0 rgba(255,255,255,.88);
  backdrop-filter: blur(16px) saturate(126%);
}

.daily-stock-dialog .position-dialog-head::before {
  content: "";
  position: absolute;
  left: 14px;
  right: 14px;
  bottom: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(202, 46, 65, .86), rgba(29, 177, 188, .64), transparent);
  box-shadow: 0 0 11px rgba(202, 46, 65, .44);
  pointer-events: none;
}

.daily-stock-dialog .position-dialog-head > div:first-child {
  display: grid;
  gap: 2px;
  min-width: 0;
}

.daily-stock-dialog .position-dialog-head span {
  color: #a1293a;
  letter-spacing: .035em;
}

.daily-stock-dialog .position-dialog-head h2 {
  margin: 0;
  color: #2f2025;
  font-size: 22px;
  line-height: 1.2;
}

.daily-stock-dialog-head-actions {
  position: relative;
  z-index: 1;
}

.daily-stock-dialog .daily-stock-focus-button {
  border-color: rgba(27, 160, 170, .42);
  background: rgba(235, 251, 249, .76);
  color: #15717a;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.84), 0 0 13px rgba(29, 171, 181, .10);
}

.daily-stock-dialog .dialog-close {
  border-color: rgba(185, 66, 79, .32);
  background: rgba(255, 249, 248, .60);
  color: #7e5860;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.78);
}

.daily-stock-dialog .dialog-close:hover,
.daily-stock-dialog .dialog-close:focus-visible {
  border-color: rgba(194, 46, 65, .58);
  background: rgba(255, 233, 234, .88);
  color: #a32437;
  outline: none;
}

@media (max-width: 760px) {
  .daily-stock-dialog .position-dialog-head {
    min-height: 60px;
    padding: 9px 10px;
    border-radius: 11px;
  }

  .daily-stock-dialog .position-dialog-head h2 { font-size: 19px; }
  .daily-stock-dialog .daily-stock-focus-button { min-height: 34px; padding: 6px 10px; }
  .daily-stock-dialog .dialog-close { width: 34px; height: 34px; }
}

/* v166: compact one-line workspace navigation; expand the full menu only on demand. */
.workspace-compact-nav { display: none; }

body.workspace-open .top-strip {
  display: block;
  top: 8px;
  padding: 6px 8px;
  border-color: rgba(189, 55, 72, .28);
  border-radius: 13px;
  background: linear-gradient(110deg, rgba(255, 248, 247, .88), rgba(244, 252, 252, .82));
  box-shadow: 0 7px 22px rgba(84, 22, 32, .10), inset 0 1px 0 rgba(255,255,255,.92);
}

body.workspace-open .workspace-compact-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: 48px;
}

.workspace-current-view {
  display: flex;
  align-items: baseline;
  gap: 9px;
  min-width: 0;
  padding-left: 8px;
}

.workspace-current-view small {
  flex: 0 0 auto;
  color: #8c6970;
  font-size: 11px;
  font-weight: 800;
}

.workspace-current-view strong {
  overflow: hidden;
  color: #2c303c;
  font-size: 17px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.workspace-compact-actions {
  display: flex;
  align-items: center;
  gap: 7px;
  flex: 0 0 auto;
}

.toggle-workspace-nav,
body.workspace-open .close-workspace-tools {
  min-height: 36px;
  margin: 0;
  padding: 7px 12px;
  border-radius: 9px;
  font-size: 12px;
  font-weight: 800;
  white-space: nowrap;
  cursor: pointer;
}

.toggle-workspace-nav {
  border: 1px solid rgba(185, 54, 72, .30);
  background: rgba(255, 244, 244, .78);
  color: #8c2a3a;
}

.toggle-workspace-nav span { display: inline-block; transition: transform .18s ease; }
body.workspace-nav-expanded .toggle-workspace-nav span { transform: rotate(180deg); }

body.workspace-open .close-workspace-tools {
  border-color: rgba(26, 154, 166, .36);
  background: rgba(237, 251, 251, .80);
  color: #126d77;
  box-shadow: none;
}

body.workspace-open .top-strip > .source-tabs { display: none; }
body.workspace-open.workspace-nav-expanded .top-strip > .source-tabs {
  display: grid;
  margin-top: 7px;
  animation: workspace-nav-reveal .16s ease-out;
}

@keyframes workspace-nav-reveal {
  from { opacity: 0; transform: translateY(-4px); }
  to { opacity: 1; transform: translateY(0); }
}

@media (max-width: 760px) {
  body.workspace-open .top-strip {
    position: sticky;
    top: 66px;
    padding: 5px 6px;
  }

  body.workspace-open .workspace-compact-nav {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    min-height: 44px;
    gap: 6px;
  }

  .workspace-current-view {
    display: grid;
    gap: 0;
    padding-left: 5px;
  }

  .workspace-current-view strong { font-size: 15px; }
  .workspace-compact-actions { gap: 4px; }
  .toggle-workspace-nav,
  body.workspace-open .close-workspace-tools {
    width: auto;
    min-height: 34px;
    padding: 6px 8px;
    font-size: 11px;
  }

  body.workspace-open.workspace-nav-expanded .top-strip > .source-tabs {
    display: flex;
    overflow-x: auto;
    overscroll-behavior-x: contain;
    scrollbar-width: thin;
  }
}

/* v167: keep stock-detail text in reading order instead of squeezing Chinese into vertical glyphs. */
.individual-observation-metrics .market-cycle-k {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
  column-gap: 10px;
  row-gap: 5px;
}

.individual-observation-metrics .market-cycle-k > b {
  grid-column: 1;
  grid-row: 1;
  min-width: 0;
  word-break: keep-all;
}

.individual-observation-metrics .market-cycle-k > em {
  grid-column: 2;
  grid-row: 1;
  text-align: right;
  white-space: nowrap;
}

.individual-observation-metrics .market-cycle-k > span {
  grid-column: 1 / -1;
  grid-row: 2;
  min-width: 0;
  line-height: 1.45;
  word-break: normal;
  overflow-wrap: break-word;
}

.individual-observation-metrics .detail-section-head > strong,
.individual-observation-metrics .indicator-chip,
.individual-observation-metrics .indicator-k,
.individual-observation-metrics .indicator-boll {
  word-break: keep-all;
}

@media (max-width: 620px) {
  .individual-observation-metrics .market-cycle-k {
    grid-template-columns: minmax(0, 1fr) auto;
  }
}

@media (max-width: 760px) {
  .workspace-grid.individual-observation-workspace:not(.right-side-workspace) .table-wrap table {
    width: 100%;
    min-width: 0;
    table-layout: auto;
  }

  .workspace-grid.individual-observation-workspace:not(.right-side-workspace) td {
    word-break: normal;
    overflow-wrap: break-word;
  }
}

/* v173: keep the current market window at the top of the main workspace. */
.main-panel > .mobile-app-bar { order: 0; }
.main-panel > .seasonal-window-hero { order: 1; }
.main-panel > .top-strip { order: 2; }
.main-panel > .workspace-grid { order: 3; }
.main-panel > .decision-workflow-panel { order: 4; }
.main-panel > .daily-standards-panel { order: 5; }


/* Local portfolio-plan candidate: report-window allocation and audited ETF DCA evidence. */
.portfolio-plan-v1 {
  margin: 18px 0;
  padding: 18px;
  border: 1px solid rgba(79, 129, 255, .28);
  border-radius: 18px;
  background: linear-gradient(145deg, rgba(27, 42, 72, .96), rgba(18, 28, 49, .98));
  color: #eef4ff;
}
.portfolio-plan-v1 > header,
.portfolio-plan-v1 > footer {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: flex-start;
}
.portfolio-plan-v1 > header small,
.portfolio-plan-v1 article span,
.portfolio-plan-v1 > footer b { color: #8fb3ff; }
.portfolio-plan-v1 > header strong { display: block; margin-top: 4px; font-size: 1.08rem; }
.portfolio-plan-v1 > header > b { color: #ffd788; text-align: right; }
.portfolio-plan-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin: 16px 0;
}
.portfolio-plan-grid article {
  padding: 13px;
  border-radius: 13px;
  background: rgba(255, 255, 255, .055);
  border: 1px solid rgba(255, 255, 255, .08);
}
.portfolio-plan-grid article strong { display: block; margin: 4px 0 7px; color: #fff; }
.portfolio-plan-grid article p,
.portfolio-plan-v1 > footer span { margin: 0; color: #c9d5e9; line-height: 1.65; }
.portfolio-plan-v1 > footer { padding-top: 13px; border-top: 1px solid rgba(255, 255, 255, .1); }
@media (max-width: 860px) {
  .portfolio-plan-grid { grid-template-columns: 1fr; }
  .portfolio-plan-v1 > header,
  .portfolio-plan-v1 > footer { display: block; }
  .portfolio-plan-v1 > header > b { display: block; margin-top: 8px; text-align: left; }
  .portfolio-plan-v1 > footer b { display: block; margin-bottom: 7px; }
}

/* v191: ARSA is a top-level risk and permission controller, not another stock pool. */
.system-view-tabs {
  display: inline-flex;
  align-self: flex-start;
  gap: 6px;
  margin: 0 20px 8px;
  padding: 5px;
  border: 1px solid rgba(168, 44, 59, .2);
  border-radius: 999px;
  background: rgba(255, 250, 249, .88);
  box-shadow: 0 8px 24px rgba(92, 29, 39, .08);
}
.system-view-tabs button,
.arsa-tabs button {
  border: 0;
  border-radius: 999px;
  padding: 9px 16px;
  color: #694c52;
  background: transparent;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}
.system-view-tabs button.active,
.arsa-tabs button.active {
  color: #fff;
  background: linear-gradient(135deg, #a82c3b, #c84f59);
  box-shadow: 0 6px 16px rgba(168, 44, 59, .22);
}
.main-panel > .system-view-tabs { order: 0; }
.main-panel > .arsa-workspace { order: 1; }
.arsa-workspace {
  margin: 8px 20px 20px;
  color: #292f3a;
}
.arsa-workspace-head {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  padding: 22px;
  border: 1px solid rgba(168, 44, 59, .24);
  border-radius: 20px 20px 0 0;
  color: #fff;
  background:
    radial-gradient(circle at 90% 10%, rgba(65, 203, 190, .28), transparent 17rem),
    linear-gradient(135deg, #321a23, #6a2030 62%, #203f48);
}
.arsa-workspace-head small,
.arsa-workspace-head p { color: #eadce0; }
.arsa-workspace-head h1 { margin: 5px 0; font-size: clamp(1.5rem, 3vw, 2.25rem); }
.arsa-workspace-head p { margin: 0; line-height: 1.6; }
.arsa-data-badge {
  align-self: flex-start;
  flex: 0 0 auto;
  padding: 8px 12px;
  border: 1px solid rgba(255,255,255,.22);
  border-radius: 999px;
  color: #d9fffa;
  background: rgba(15, 77, 79, .5);
  font-size: .86rem;
  font-weight: 800;
}
.arsa-data-badge.stale { color: #ffe2bd; background: rgba(112, 53, 18, .52); }
.arsa-tabs {
  display: flex;
  gap: 4px;
  overflow-x: auto;
  padding: 10px 12px;
  border: solid rgba(168, 44, 59, .18);
  border-width: 0 1px;
  background: rgba(255, 248, 247, .94);
  scrollbar-width: thin;
}
.arsa-tabs button { flex: 0 0 auto; padding: 8px 14px; }
.arsa-workspace-body {
  min-height: 420px;
  padding: 18px;
  border: 1px solid rgba(168, 44, 59, .18);
  border-radius: 0 0 20px 20px;
  background: linear-gradient(145deg, rgba(255,255,255,.97), rgba(255,245,244,.95) 65%, rgba(239,251,250,.96));
  box-shadow: 0 18px 40px rgba(83, 19, 31, .1);
}
.arsa-command-card {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: center;
  padding: 20px;
  border-radius: 16px;
  color: #fff;
  background: linear-gradient(135deg, #55202c, #8e2e3e 65%, #23646a);
}
.arsa-command-card.compact { padding: 16px 18px; }
.arsa-command-card small { color: #f0c8ce; font-weight: 800; letter-spacing: .04em; }
.arsa-command-card h2 { margin: 5px 0; font-size: 1.15rem; line-height: 1.45; }
.arsa-command-card p { margin: 0; color: #f1e3e5; line-height: 1.6; }
.arsa-command-card > span,
.arsa-command-card > button {
  flex: 0 0 auto;
  padding: 9px 12px;
  border: 1px solid rgba(255,255,255,.25);
  border-radius: 999px;
  font: inherit;
  font-weight: 800;
}
.arsa-command-card > button { color: #fff; background: rgba(255,255,255,.12); cursor: pointer; }
.arsa-command-card .fresh { color: #d7fff3; background: rgba(15, 91, 72, .38); }
.arsa-command-card .stale { color: #ffe0ba; background: rgba(119, 58, 20, .45); }
.arsa-score-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-top: 14px;
}
.arsa-metric-card,
.arsa-permission,
.arsa-position-card,
.arsa-etf-card,
.arsa-evidence-grid article {
  padding: 15px;
  border: 1px solid rgba(126, 82, 89, .14);
  border-radius: 14px;
  background: rgba(255,255,255,.78);
}
.arsa-metric-card > span,
.arsa-etf-card > small,
.arsa-evidence-grid small { color: #876169; font-weight: 800; }
.arsa-metric-card > strong { display: block; margin: 5px 0; color: #6f1f2e; font-size: 1.35rem; }
.arsa-metric-card p,
.arsa-permission p,
.arsa-etf-card p,
.arsa-evidence-grid p { margin: 0; color: #59616b; line-height: 1.55; }
.arsa-transition-card,
.arsa-section,
.arsa-state-map {
  margin-top: 14px;
  padding: 17px;
  border: 1px solid rgba(49, 125, 129, .18);
  border-radius: 15px;
  background: rgba(244, 251, 250, .74);
}
.arsa-transition-card header,
.arsa-section > header,
.arsa-permission header,
.arsa-position-card header {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: flex-start;
}
.arsa-transition-card h3,
.arsa-section h2 { margin: 4px 0 0; }
.arsa-transition-card p { margin-bottom: 0; line-height: 1.6; }
.arsa-transition-card header > b { color: #187783; }
.arsa-permission-grid,
.arsa-position-grid,
.arsa-etf-grid,
.arsa-evidence-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 12px;
}
.arsa-permission { border-left: 5px solid #9097a0; }
.arsa-permission.on { border-left-color: #168563; }
.arsa-permission.probe { border-left-color: #ce7d20; }
.arsa-permission.watch { border-left-color: #1a7e8b; }
.arsa-permission.off { border-left-color: #a82c3b; opacity: .82; }
.arsa-permission header b { color: #7a2834; }
.arsa-permission small { color: #7d5d63; font-weight: 800; }
.arsa-state-map summary { cursor: pointer; color: #6f1f2e; font-weight: 800; }
.arsa-state-map ol { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; padding: 0; list-style: none; }
.arsa-state-map li { display: grid; gap: 3px; padding: 10px; border-radius: 10px; background: #fff; }
.arsa-state-map li.active { color: #fff; background: linear-gradient(135deg, #a82c3b, #287780); }
.arsa-state-map li small { opacity: .8; }
.arsa-table-wrap { margin-top: 12px; overflow-x: auto; }
.arsa-table { width: 100%; border-collapse: collapse; min-width: 850px; }
.arsa-table th,
.arsa-table td { padding: 11px 9px; border-bottom: 1px solid #eadcde; text-align: left; vertical-align: top; }
.arsa-table th { color: #76545a; font-size: .86rem; }
.arsa-table td { line-height: 1.5; }
.arsa-table td button { padding: 0; border: 0; color: #6f1f2e; background: transparent; text-align: left; cursor: pointer; }
.arsa-table td button strong,
.arsa-table td button small { display: block; }
.arsa-row-status { display: inline-block; padding: 3px 7px; border-radius: 999px; font-size: .82rem; font-weight: 800; }
.arsa-row-status.pass { color: #126752; background: #e1f5ee; }
.arsa-row-status.block { color: #8f2d38; background: #fae7e9; }
.arsa-disclosure { color: #765f63; font-size: .88rem; line-height: 1.6; }
.arsa-position-card header b { color: #a82c3b; }
.arsa-position-card p { color: #5d626a; }
.arsa-position-card > span { color: #6f1f2e; font-weight: 800; }
.arsa-position-summary {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-top: 14px;
}
.arsa-position-summary article {
  display: grid;
  gap: 5px;
  padding: 14px;
  border: 1px solid rgba(126, 82, 89, .14);
  border-radius: 13px;
  background: rgba(255,255,255,.82);
}
.arsa-position-summary span,
.arsa-position-summary small { color: #78666a; }
.arsa-position-summary strong { color: #6f1f2e; font-size: 1.08rem; }
.arsa-position-grid.detailed { grid-template-columns: 1fr; }
.arsa-position-card.detailed { display: grid; gap: 12px; border-left: 5px solid #78838b; }
.arsa-position-card.detailed.add { border-left-color: #168563; }
.arsa-position-card.detailed.profit { border-left-color: #c08018; }
.arsa-position-card.detailed.risk { border-left-color: #a82c3b; }
.arsa-position-card.detailed.pending,
.arsa-position-card.detailed.review { border-left-color: #1a7e8b; }
.arsa-position-name {
  display: grid;
  gap: 2px;
  padding: 0;
  border: 0;
  color: #6f1f2e;
  background: transparent;
  text-align: left;
  cursor: pointer;
}
.arsa-position-name strong { font-size: 1.05rem; }
.arsa-position-name small { color: #7b686c; }
.arsa-position-action { display: grid; gap: 4px; padding: 12px; border-radius: 11px; background: #f3f5f4; }
.arsa-position-action strong { color: #303e45; font-size: 1.04rem; }
.arsa-position-action p { margin: 0; }
.arsa-position-action.add { background: #e6f5ef; }
.arsa-position-action.profit { background: #fff1d9; }
.arsa-position-action.risk { background: #fae7e9; }
.arsa-position-action.pending,
.arsa-position-action.review { background: #e7f3f4; }
.arsa-position-metrics,
.arsa-exit-ladder {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}
.arsa-position-metrics > span,
.arsa-exit-ladder article { display: grid; gap: 4px; padding: 10px; border-radius: 10px; background: #f7f5f2; }
.arsa-position-metrics small,
.arsa-position-metrics em,
.arsa-exit-ladder small { color: #746d6f; font-size: .8rem; font-style: normal; }
.arsa-position-metrics b,
.arsa-exit-ladder strong { color: #633039; }
.arsa-exit-ladder article.hit { background: #fae7e9; outline: 1px solid #d99ba4; }
.arsa-exit-ladder article.done { background: #e7f4ec; opacity: .82; }
.arsa-exit-ladder article.active { background: #fff2d9; outline: 1px solid #dfba72; }
.arsa-tranche-note { margin: 0; color: #5c6971; font-size: .86rem; line-height: 1.55; overflow-wrap: anywhere; }
.arsa-add-decision { padding: 11px; border-radius: 10px; background: #edf6f4; }
.arsa-add-decision p { margin: 4px 0 0; }
.arsa-execution-ledger { padding: 11px; border: 1px solid #e3d5d7; border-radius: 11px; background: #fff; }
.arsa-execution-ledger summary { color: #6f1f2e; font-weight: 800; cursor: pointer; }
.arsa-execution-ledger ul { display: grid; gap: 6px; margin: 12px 0; padding: 0; list-style: none; }
.arsa-execution-ledger li { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 8px; border-radius: 8px; background: #f7f5f2; }
.arsa-execution-ledger li.empty { grid-template-columns: 1fr; color: #766b6d; }
.arsa-fee-form { display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-column: 1; gap: 6px; align-items: end; min-width: 0; }
.arsa-fee-form label { display: grid; gap: 4px; min-width: 0; font-size: .8rem; }
.arsa-fee-form input { width: 100%; min-width: 0; padding: 7px; border: 1px solid #d8c7ca; border-radius: 8px; }
.arsa-execution-ledger li > button { grid-column: 2; }
.arsa-cost-note { margin: 6px 0 12px; color: #775d62; font-size: .78rem; line-height: 1.5; overflow-wrap: anywhere; }
.arsa-trade-entry-card .arsa-fee-field { grid-column: 1 / -1; }
.arsa-execution-ledger li button,
.arsa-fee-form button,
.arsa-sale-form button,
.arsa-position-settings button { padding: 7px 10px; border: 1px solid #8a4c58; border-radius: 8px; color: #6f1f2e; background: #fff; font: inherit; font-weight: 800; cursor: pointer; }
.arsa-sale-form,
.arsa-position-settings { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)) auto; gap: 8px; align-items: end; margin-top: 10px; }
.arsa-position-settings { grid-template-columns: repeat(2, minmax(0, 1fr)) auto; padding-top: 10px; border-top: 1px dashed #ddcfd1; }
.arsa-sale-form label,
.arsa-position-settings label { display: grid; gap: 4px; color: #71545a; font-size: .82rem; font-weight: 800; }
.arsa-sale-form input,
.arsa-sale-form select,
.arsa-position-settings input,
.arsa-position-settings select { width: 100%; min-width: 0; padding: 8px; border: 1px solid #d8c7ca; border-radius: 8px; background: #fff; font: inherit; }
.arsa-position-message { margin: 9px 0 0; font-size: .84rem; }
.arsa-risk-grid,
.arsa-event-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}
.arsa-risk-grid span,
.arsa-event-strip span { padding: 8px 10px; border-radius: 9px; color: #6c3e47; background: #f8e9e9; font-weight: 700; }
.arsa-etf-card h2 { margin: 5px 0 10px; color: #6f1f2e; }
.arsa-etf-card.detailed { display: grid; gap: 12px; border-top: 5px solid #72808a; }
.arsa-etf-card.detailed.ready,
.arsa-etf-card.detailed.month_end_ready,
.arsa-etf-card.detailed.done { border-top-color: #168563; }
.arsa-etf-card.detailed.intraday_watch { border-top-color: #1a7e8b; }
.arsa-etf-card.detailed.block { border-top-color: #a82c3b; }
.arsa-etf-card.detailed > header,
.arsa-etf-card.detailed > footer { display: flex; justify-content: space-between; gap: 12px; align-items: flex-start; }
.arsa-etf-card.detailed > header h2 { margin-bottom: 2px; }
.arsa-etf-status { padding: 5px 9px; border-radius: 999px; color: #6f1f2e; background: #f7e6e9; font-weight: 800; white-space: nowrap; }
.arsa-etf-metrics { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.arsa-etf-metrics > span { display: grid; gap: 2px; padding: 9px; border-radius: 10px; background: #f7f5f2; }
.arsa-etf-metrics small { color: #7b6267; font-weight: 800; }
.arsa-etf-metrics b { color: #6f1f2e; }
.arsa-etf-metrics em { color: #70777f; font-size: .78rem; font-style: normal; }
.arsa-etf-action { padding: 10px; border-radius: 10px; background: #edf7f5; }
.arsa-etf-card.detailed > footer small { max-width: 70%; color: #78666a; line-height: 1.45; }
.arsa-etf-card.detailed > footer button { padding: 7px 10px; border: 1px solid #8a4c58; border-radius: 9px; color: #6f1f2e; background: #fff; font: inherit; font-weight: 800; cursor: pointer; }
.arsa-checklist,
.arsa-limitations { margin-bottom: 0; padding-left: 22px; line-height: 1.75; }
.arsa-evidence-grid article strong { display: block; margin: 5px 0; color: #a82c3b; font-size: 1.7rem; }
.arsa-section.warning { border-color: rgba(180, 111, 28, .3); background: #fff8ed; }
.arsa-empty { padding: 36px 20px; color: #765f63; text-align: center; }
.arsa-candidate-section > header > div { min-width: 0; }
.arsa-candidate-section > header p { max-width: 1120px; overflow-wrap: anywhere; }
.arsa-candidate-section > header > b { flex: 0 0 auto; padding: 5px 9px; border-radius: 999px; color: #6f1f2e; background: #f7e8ea; white-space: nowrap; }
.arsa-candidate-section .arsa-table-wrap { overflow: visible; }
.arsa-candidate-table { display: block; min-width: 0; border-collapse: separate; }
.arsa-candidate-table thead { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.arsa-candidate-table tbody { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.arsa-candidate-table tr { display: grid; grid-template-columns: minmax(130px, 1.15fr) minmax(90px, .72fr) minmax(90px, .72fr); grid-template-areas: "stock week day" "signal signal signal" "quality turn conclusion" "actions actions actions"; gap: 9px 10px; min-width: 0; padding: 14px; border: 1px solid #e5cfd2; border-left: 5px solid #b93245; border-radius: 13px; background: rgba(255,255,255,.86); box-shadow: 0 7px 20px rgba(98,28,41,.05); }
.arsa-candidate-table td { min-width: 0; padding: 0; border: 0; white-space: normal; word-break: normal; overflow-wrap: anywhere; }
.arsa-candidate-table td:nth-child(1) { grid-area: stock; }
.arsa-candidate-table td:nth-child(2) { grid-area: week; }
.arsa-candidate-table td:nth-child(3) { grid-area: day; }
.arsa-candidate-table td:nth-child(4) { grid-area: signal; padding: 9px 10px; border-radius: 9px; background: #f4f6f5; }
.arsa-candidate-table td:nth-child(5) { grid-area: quality; }
.arsa-candidate-table td:nth-child(6) { grid-area: turn; }
.arsa-candidate-table td:nth-child(7) { grid-area: conclusion; }
.arsa-candidate-table td:nth-child(8) { grid-area: actions; padding-top: 9px; border-top: 1px dashed #dfcfd2; }
.arsa-candidate-table td:nth-child(2),
.arsa-candidate-table td:nth-child(3),
.arsa-candidate-table td:nth-child(5),
.arsa-candidate-table td:nth-child(6),
.arsa-candidate-table td:nth-child(7) { padding: 8px 9px; border-radius: 9px; background: rgba(245,244,242,.9); }
.arsa-candidate-table td:nth-child(2)::before,
.arsa-candidate-table td:nth-child(3)::before,
.arsa-candidate-table td:nth-child(4)::before,
.arsa-candidate-table td:nth-child(5)::before,
.arsa-candidate-table td:nth-child(6)::before,
.arsa-candidate-table td:nth-child(7)::before { display: block; margin-bottom: 3px; color: #876c71; font-size: .72rem; font-weight: 800; }
.arsa-candidate-table td:nth-child(2)::before { content: "周K · 正式收盘"; }
.arsa-candidate-table td:nth-child(3)::before { content: "日K · 正式收盘"; }
.arsa-candidate-table td:nth-child(4)::before { content: "信号 · 日期 · 来源"; }
.arsa-candidate-table td:nth-child(5)::before { content: "财务与换手排序"; }
.arsa-candidate-table td:nth-child(6)::before { content: "下一可交易日高开"; }
.arsa-candidate-table td:nth-child(7)::before { content: "当前结论"; }
.arsa-candidate-table td:nth-child(4) small { display: block; margin-top: 2px; color: #6f6870; font-size: .78rem; line-height: 1.4; }
.arsa-candidate-table td:nth-child(1) button { display: grid; gap: 2px; width: 100%; }
.low-k-result-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 12px; }
.low-k-result-grid article { padding: 12px; border: 1px solid #dfcdd1; border-radius: 12px; }
.low-k-summary p, .arsa-candidate-table td small { white-space: normal; overflow-wrap: anywhere; }
.low-k-summary p, .arsa-candidate-section header p { color: #455568; line-height: 1.6; }
.low-k-summary > summary { display: flex; align-items: center; justify-content: space-between; gap: 12px; cursor: pointer; color: #71343f; }
.low-k-summary > summary span { flex: 0 0 auto; font-size: .8rem; }
.low-k-disclosure-body { margin-top: 14px; }
.low-k-coverage-details { margin-top: 8px; color: #455568; }
.low-k-coverage-details > summary { cursor: pointer; font-size: .85rem; }
.arsa-candidate-table td small { display: block; }
@media (max-width: 560px) { .low-k-result-grid { grid-template-columns: 1fr; } }
.arsa-candidate-table td:nth-child(1) button strong:first-child { font-size: 1.05rem; }
.arsa-candidate-actions { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 6px; min-width: 0; }
.arsa-candidate-table .arsa-candidate-actions button,
.arsa-tracked-card footer button { padding: 7px 9px; border: 1px solid #d7a3ab; border-radius: 8px; color: #6f1f2e; background: #fff; font: inherit; font-weight: 800; cursor: pointer; }
.arsa-candidate-table .arsa-candidate-actions button:disabled,
.arsa-tracked-card footer button:disabled { cursor: not-allowed; opacity: .55; }
.arsa-candidate-profile { grid-column: 1 / -1; color: #6f6870; line-height: 1.45; }
.arsa-tracked-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin-top: 14px; }
.arsa-tracked-card { display: grid; gap: 11px; padding: 14px; border: 1px solid #e4cdd1; border-left: 5px solid #7c8d96; border-radius: 13px; background: rgba(255,255,255,.88); box-shadow: 0 8px 22px rgba(91,31,43,.06); }
.arsa-tracked-card > header { display: flex; justify-content: space-between; gap: 10px; align-items: flex-start; }
.arsa-tracked-card > header button { padding: 0; border: 0; color: #552632; background: transparent; text-align: left; cursor: pointer; }
.arsa-tracked-card > header button strong,
.arsa-tracked-card > header button small { display: block; }
.arsa-tracked-card > header button strong { font-size: 1.05rem; }
.arsa-tracked-card > header button small { color: #77656a; }
.arsa-tracked-card > header > span { padding: 5px 9px; border-radius: 999px; color: #fff; background: #7c8d96; font-size: .82rem; font-weight: 800; white-space: nowrap; }
.arsa-source-chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 0; }
.arsa-source-chips i { padding: 3px 7px; border-radius: 999px; color: #176d75; background: #e9f6f6; font-size: .78rem; font-style: normal; font-weight: 800; }
.arsa-tracked-metrics { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.arsa-tracked-metrics > span { display: grid; gap: 3px; min-width: 0; padding: 9px; border-radius: 9px; background: #f7f5f2; }
.arsa-tracked-metrics small,
.arsa-tracked-metrics em { color: #756a6d; font-size: .78rem; font-style: normal; overflow-wrap: anywhere; }
.arsa-tracked-metrics b { color: #65303b; overflow-wrap: anywhere; }
.arsa-tracked-action { display: grid; gap: 4px; padding: 10px; border-radius: 10px; background: #edf6f4; }
.arsa-tracked-action strong { color: #155f52; }
.arsa-tracked-action em { color: #71666a; font-size: .8rem; font-style: normal; line-height: 1.45; }
.arsa-tracked-card footer { display: flex; flex-wrap: wrap; gap: 7px; }
.arsa-tracked-card.允许买入复核 { border-left-color: #168563; }
.arsa-tracked-card.已持仓,
.arsa-tracked-card.分批止盈中 { border-left-color: #bd7d19; }
.arsa-tracked-card.已退出 { opacity: .82; }
.arsa-execution-ledger h4 { margin: 12px 0 5px; color: #6f1f2e; }

@media (max-width: 860px) {
  .system-view-tabs,
  .arsa-workspace { margin-left: 10px; margin-right: 10px; }
  .arsa-workspace-head,
  .arsa-command-card { display: grid; }
  .arsa-data-badge,
  .arsa-command-card > span,
  .arsa-command-card > button { justify-self: start; }
  .arsa-score-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .arsa-position-summary,
  .arsa-position-metrics,
  .arsa-exit-ladder { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .arsa-sale-form { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .arsa-position-settings { grid-template-columns: 1fr 1fr; }
  .arsa-tracked-grid { grid-template-columns: 1fr; }
  .arsa-state-map ol { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .arsa-candidate-table tbody { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
  .system-view-tabs { width: calc(100% - 20px); }
  .system-view-tabs button { flex: 1 1 50%; padding: 9px 10px; }
  .arsa-workspace { margin-top: 4px; }
  .arsa-workspace-head { padding: 16px; border-radius: 15px 15px 0 0; }
  .arsa-workspace-body { padding: 10px; min-height: 360px; }
  .arsa-score-grid,
  .arsa-permission-grid,
  .arsa-position-grid,
  .arsa-etf-grid,
  .arsa-evidence-grid { grid-template-columns: 1fr; }
  .arsa-position-summary,
  .arsa-position-metrics,
  .arsa-exit-ladder,
  .arsa-sale-form,
  .arsa-position-settings { grid-template-columns: 1fr; }
  .arsa-execution-ledger li { grid-template-columns: minmax(0, 1fr) auto; }
  .arsa-tracked-metrics { grid-template-columns: 1fr; }
  .arsa-tracked-card footer { display: grid; grid-template-columns: 1fr 1fr; }
  .arsa-state-map ol { grid-template-columns: 1fr; }
  .arsa-transition-card header,
  .arsa-section > header,
  .arsa-permission header,
  .arsa-position-card header,
  .arsa-etf-card.detailed > header,
  .arsa-etf-card.detailed > footer { display: grid; }
  .arsa-etf-metrics { grid-template-columns: 1fr; }
  .arsa-etf-card.detailed > footer small { max-width: none; }
  .arsa-candidate-section { padding: 12px; }
  .arsa-candidate-section > header > b { justify-self: start; }
  .arsa-candidate-table tr { grid-template-columns: repeat(2, minmax(0, 1fr)); grid-template-areas: "stock stock" "week day" "signal signal" "quality quality" "turn conclusion" "actions actions"; padding: 12px; }
  .arsa-candidate-actions { grid-template-columns: 1fr; }
}
/* Historical display never feeds the current signal fields. */
.historical-metric-notice { display: block; grid-column: 1 / -1; min-width: 0; padding: 12px; margin: 8px 0; border: 1px solid #d9b97a; border-radius: 10px; background: #fff8e9; color: #74521a; font-size: 13px; line-height: 1.65; overflow-wrap: anywhere; }
.historical-metric-notice > * { display: block; white-space: normal; }

@media (max-width: 760px) {
  .system-view-tabs { display: flex; overflow-x: auto; }
  .system-view-tabs button { flex: 0 0 auto; white-space: nowrap; }
  .arsa-trade-entry-card .arsa-sale-form,
  .arsa-trade-entry-card .arsa-buy-form { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .arsa-trade-entry-card .arsa-sale-form button,
  .arsa-trade-entry-card .arsa-buy-form button { grid-column: 1 / -1; }
}
