/**
 * HIGHCREW Trade Pilot v2 — Chart Shell stylesheet
 * Pixel-matched dark terminal shell. All colors via CSS variables.
 */

:root {
  --hc-bg: #02050a;
  --hc-bg-deep: #010308;
  --hc-panel: #050d16;
  --hc-panel-2: #07131e;
  --hc-panel-3: #0a1624;
  --hc-border: rgba(27, 220, 255, 0.28);
  --hc-border-dim: rgba(29, 64, 92, 0.55);
  --hc-border-glow: rgba(27, 220, 255, 0.45);
  --hc-text: #eaf6ff;
  --hc-muted: #7fb8d0;
  --hc-cyan: #1bdcff;
  --hc-green: #39ff5a;
  --hc-red: #ff4d4d;
  --hc-yellow: #ffd22e;
  --hc-orange: #ff8a00;
  --hc-blue: #3d7eff;
  --hc-purple: #a944ff;
  --hc-grid: rgba(29, 64, 92, 0.35);
  --hc-session-pre: rgba(27, 220, 255, 0.03);
  --hc-session-open: rgba(57, 255, 90, 0.05);
  --hc-session-mid: rgba(255, 210, 46, 0.03);
  --hc-session-power: rgba(255, 138, 0, 0.05);
  --hc-session-close: rgba(169, 68, 255, 0.04);
  --hc-terminal-w: clamp(260px, 18vw, 310px);
  --hc-gap: clamp(4px, 0.45vw, 8px);
  --hc-pad: clamp(4px, 0.4vw, 8px);
  --hc-fs-xs: clamp(7px, 0.55vw, 9px);
  --hc-fs-sm: clamp(8px, 0.65vw, 10px);
  --hc-fs-md: clamp(10px, 0.8vw, 12px);
  --hc-fs-lg: clamp(12px, 1vw, 15px);
  --hc-fs-xl: clamp(13px, 1.1vw, 17px);
  --hc-radius: 3px;
  --hc-glow-cyan: 0 0 8px rgba(27, 220, 255, 0.25);
  --hc-glow-green: 0 0 8px rgba(57, 255, 90, 0.22);
  --hc-glow-purple: 0 0 8px rgba(169, 68, 255, 0.28);
  --hc-glow-orange: 0 0 8px rgba(255, 138, 0, 0.22);
  --hc-glow-red: 0 0 8px rgba(255, 77, 77, 0.22);
}

/* Hide legacy plain charts chrome when shell is active */
body.charts-shell-active .charts-cc-legacy {
  display: none !important;
}

#chartsTab.hc-shell-mode,
#chartsTab.hc-shell-mode .hc-shell-host {
  height: 100%;
  min-height: 0;
}

.hc-shell-host {
  display: flex;
  flex-direction: column;
  height: calc(100vh - 118px);
  max-height: calc(100vh - 118px);
  min-height: 640px;
  /* Allow scrolling down to the always-visible AI feed under the chart. */
  overflow-x: hidden;
  overflow-y: auto;
  background: var(--hc-bg);
  scrollbar-width: thin;
  scrollbar-color: rgba(27, 220, 255, 0.45) transparent;
}

body.charts-focus .hc-shell-host {
  height: calc(100vh - 16px);
  max-height: calc(100vh - 16px);
}

.hc-shell-root {
  display: grid;
  /* Named areas so hidden auto children cannot steal the 1fr chart track and
     paint intel (Order Flow / Trade Plan / …) into the chart row. */
  grid-template-areas:
    "header"
    "flowlab"
    "power"
    "extras"
    "banner"
    "econ"
    "signal"
    "chart"
    "intel"
    "bottom"
    "score";
  grid-template-columns: minmax(0, 1fr);
  grid-template-rows: auto auto auto auto auto auto auto auto auto auto auto;
  align-content: start;
  gap: var(--hc-gap);
  height: auto;
  min-height: 100%;
  padding: var(--hc-pad);
  background:
    radial-gradient(ellipse at 20% 0%, rgba(27, 220, 255, 0.08), transparent 42%),
    radial-gradient(ellipse at 80% 100%, rgba(169, 68, 255, 0.06), transparent 40%),
    var(--hc-bg-deep);
  color: var(--hc-text);
  font-family: "Segoe UI", "DIN Alternate", "Arial Narrow", Arial, Helvetica, sans-serif;
  letter-spacing: 0.02em;
}
.hc-shell-header { grid-area: header; }
.hc-flowlab-strip { grid-area: flowlab; }
.hc-scalp-power-strip { grid-area: power; }
.hc-ws-status-extras { grid-area: extras; }
.hc-shell-status-banner { grid-area: banner; }
.hc-econ-panel { grid-area: econ; }
.hc-shell-signal-alert-host { grid-area: signal; }
.hc-shell-main { grid-area: chart; }
#hcWsBelowStack { grid-area: intel; }
.hc-shell-bottom-panels { grid-area: bottom; }
.hc-shell-score-strip { grid-area: score; }

/* ─── HEADER ─── */
.hc-shell-header {
  display: grid;
  grid-template-columns: minmax(180px, 260px) minmax(0, 1fr);
  gap: var(--hc-gap);
  align-items: stretch;
  flex: 0 0 auto;
  background: linear-gradient(180deg, rgba(8, 18, 30, 0.98), rgba(4, 10, 18, 0.98));
  border: 1px solid var(--hc-border);
  border-radius: var(--hc-radius);
  box-shadow: var(--hc-glow-cyan);
  padding: clamp(5px, 0.5vw, 8px);
}

.hc-shell-header-right {
  display: flex;
  flex-direction: column;
  gap: var(--hc-gap);
  min-width: 0;
}

/* Symbol + timeframe controls (Polygon live chart engine) */
.hc-shell-controls {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 10px;
  min-width: 0;
}

.hc-shell-control-label {
  font-size: var(--hc-fs-xs);
  letter-spacing: 0.12em;
  color: var(--hc-muted);
  font-weight: 700;
}

.hc-shell-symbol-select {
  appearance: none;
  background: var(--hc-panel-2);
  color: var(--hc-cyan);
  border: 1px solid var(--hc-border);
  border-radius: var(--hc-radius);
  padding: 4px 22px 4px 8px;
  font-size: var(--hc-fs-sm);
  font-weight: 700;
  letter-spacing: 0.08em;
  cursor: pointer;
  min-height: 28px;
  background-image: linear-gradient(45deg, transparent 50%, var(--hc-cyan) 50%),
    linear-gradient(135deg, var(--hc-cyan) 50%, transparent 50%);
  background-position: calc(100% - 12px) 50%, calc(100% - 7px) 50%;
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
}

.hc-shell-symbol-select:focus {
  outline: none;
  border-color: var(--hc-cyan);
  box-shadow: var(--hc-glow-cyan);
}

.hc-shell-tf-group {
  display: flex;
  flex-wrap: wrap;
  gap: 3px;
}

.hc-shell-tf-btn {
  appearance: none;
  background: var(--hc-panel-3);
  color: var(--hc-muted);
  border: 1px solid var(--hc-border-dim);
  border-radius: var(--hc-radius);
  padding: 4px 8px;
  font-size: var(--hc-fs-xs);
  font-weight: 700;
  letter-spacing: 0.06em;
  cursor: pointer;
  min-height: 28px;
  min-width: 36px;
  touch-action: manipulation;
}

.hc-shell-tf-btn:hover {
  border-color: var(--hc-cyan);
  color: var(--hc-cyan);
}

.hc-shell-tf-btn.active {
  border-color: var(--hc-cyan);
  color: var(--hc-bg);
  background: var(--hc-cyan);
  box-shadow: var(--hc-glow-cyan);
}

/* Status strip: Polygon live + mock engine */
.hc-shell-status-banner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px 10px;
  padding: 5px 8px;
  background: linear-gradient(90deg, rgba(27, 220, 255, 0.08), rgba(169, 68, 255, 0.06));
  border: 1px solid var(--hc-border-dim);
  border-radius: var(--hc-radius);
  font-size: var(--hc-fs-xs);
  letter-spacing: 0.1em;
  font-weight: 700;
  color: var(--hc-muted);
}

.hc-shell-status-ds {
  color: var(--hc-cyan);
}

.hc-shell-status-eng {
  color: var(--hc-orange);
}

.hc-shell-status-sep {
  opacity: 0.45;
}

.hc-shell-status-meta {
  color: var(--hc-muted);
  margin-left: auto;
}

.hc-shell-status-err {
  color: var(--hc-red);
  letter-spacing: 0.04em;
  font-weight: 600;
}

.hc-shell-news-alert-debug {
  flex: 1 1 100%;
  margin-top: 2px;
  padding-top: 3px;
  border-top: 1px solid rgba(27, 220, 255, 0.12);
  color: var(--hc-muted);
  font-size: 9px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: none;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.hc-shell-news-alert-debug[data-alert-rendered="true"] {
  color: var(--hc-yellow);
}

.hc-shell-live-status {
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px 8px;
}

.hc-shell-live-chip {
  display: inline-block;
  padding: 1px 0;
  color: var(--hc-muted);
  letter-spacing: 0.08em;
  font-weight: 700;
  white-space: nowrap;
}

.hc-shell-live-chip + .hc-shell-live-chip::before {
  content: "·";
  margin-right: 8px;
  opacity: 0.45;
}

.hc-shell-live-chip.is-live {
  color: #39ff5a;
}

.hc-shell-live-chip.is-down {
  color: var(--hc-orange);
}

.hc-shell-live-chip.is-fallback {
  color: var(--hc-orange);
}

.hc-shell-live-chip.is-stale {
  color: #ff4d4d;
}

.hc-shell-brand-block {
  display: flex;
  align-items: center;
  gap: clamp(6px, 0.6vw, 10px);
  min-width: 0;
}

.hc-shell-logo {
  flex: 0 0 auto;
  width: clamp(34px, 2.6vw, 42px);
  height: clamp(34px, 2.6vw, 42px);
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(145deg, #061525, #02080f);
  border: 1px solid var(--hc-cyan);
  border-radius: 2px;
  color: var(--hc-cyan);
  font-weight: 900;
  font-size: var(--hc-fs-md);
  letter-spacing: 0.08em;
  box-shadow: inset 0 0 12px rgba(27, 220, 255, 0.18), var(--hc-glow-cyan);
  text-shadow: 0 0 8px rgba(27, 220, 255, 0.55);
}

.hc-shell-titles {
  min-width: 0;
}

.hc-shell-title {
  font-size: var(--hc-fs-xl);
  font-weight: 900;
  color: var(--hc-cyan);
  letter-spacing: 0.12em;
  line-height: 1.1;
  text-transform: uppercase;
  white-space: nowrap;
  text-shadow: 0 0 10px rgba(27, 220, 255, 0.35);
}

.hc-shell-subtitle {
  margin-top: 2px;
  font-size: var(--hc-fs-xs);
  color: var(--hc-orange);
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.hc-shell-top-cards {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: clamp(4px, 0.4vw, 7px);
  min-width: 0;
}

.hc-shell-card {
  background: var(--hc-panel);
  border: 1px solid var(--hc-border-dim);
  border-radius: var(--hc-radius);
  padding: clamp(5px, 0.45vw, 8px) clamp(6px, 0.5vw, 9px);
  min-width: 0;
  box-shadow: inset 0 0 14px rgba(0, 0, 0, 0.35);
}

.hc-shell-card.hc-tone-bull {
  border-color: rgba(57, 255, 90, 0.5);
  box-shadow: var(--hc-glow-green), inset 0 0 14px rgba(0, 0, 0, 0.35);
}
.hc-shell-card.hc-tone-bear {
  border-color: rgba(255, 77, 77, 0.5);
  box-shadow: var(--hc-glow-red), inset 0 0 14px rgba(0, 0, 0, 0.35);
}
.hc-shell-card.hc-tone-warn {
  border-color: rgba(255, 210, 46, 0.5);
}
.hc-shell-card.hc-tone-cyan {
  border-color: rgba(27, 220, 255, 0.55);
  box-shadow: var(--hc-glow-cyan), inset 0 0 14px rgba(0, 0, 0, 0.35);
}
.hc-shell-card.hc-tone-purple {
  border-color: rgba(169, 68, 255, 0.55);
  box-shadow: var(--hc-glow-purple), inset 0 0 14px rgba(0, 0, 0, 0.35);
}

.hc-shell-card-lbl {
  font-size: var(--hc-fs-xs);
  color: var(--hc-muted);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-weight: 800;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.hc-shell-card-val {
  margin-top: 3px;
  font-size: var(--hc-fs-md);
  font-weight: 900;
  color: var(--hc-cyan);
  line-height: 1.15;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-transform: uppercase;
}

.hc-shell-card.hc-tone-bull .hc-shell-card-val { color: var(--hc-green); }
.hc-shell-card.hc-tone-bear .hc-shell-card-val { color: var(--hc-red); }
.hc-shell-card.hc-tone-warn .hc-shell-card-val { color: var(--hc-yellow); }
.hc-shell-card.hc-tone-cyan .hc-shell-card-val { color: var(--hc-cyan); }
.hc-shell-card.hc-tone-purple .hc-shell-card-val { color: var(--hc-purple); }

/* ─── MAIN: left workspace + chart + terminal ─── */
.hc-shell-main {
  display: grid;
  grid-template-columns: minmax(168px, 200px) minmax(0, 1fr) var(--hc-terminal-w);
  gap: var(--hc-gap);
  min-height: 0;
  /* height:auto so this row cannot overflow the next grid area (intel). */
  height: auto;
  position: relative;
  z-index: 0;
  overflow: hidden;
  isolation: isolate;
  background: var(--hc-bg-deep);
}

/* Scalp workspace: chart owns center; right rail is MAG-7 / scalp only (coach is under chart).
   Chart row fills most of the viewport (left rail down through DATA QUALITY);
   AI coach / AI talk sit below and are reached by scrolling the host. */
.hc-shell-main.hc-scalp-main {
  grid-template-columns: minmax(148px, 168px) minmax(0, 1fr) minmax(168px, 210px);
  flex: 0 0 auto;
  min-height: max(640px, calc(100vh - 165px));
  height: auto;
  max-height: none;
  align-items: stretch;
}
.hc-shell-root.hc-aic-rail-collapsed .hc-shell-main.hc-scalp-main,
.hc-shell-root.hc-aic-dock-collapsed .hc-shell-main.hc-scalp-main {
  grid-template-columns: minmax(148px, 168px) minmax(0, 1fr) minmax(168px, 210px);
}

.hc-scalp-mode .hc-shell-left-rail,
.hc-scalp-mode .hc-shell-terminal.hc-scalp-terminal {
  min-height: 0;
  height: 100%;
  max-height: none;
  overflow: auto;
}

.hc-scalp-mode .hc-shell-chart-pane {
  flex: 1 1 auto;
  min-height: 420px;
  height: 100%;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.hc-scalp-mode .hc-shell-chart-stage {
  /* Was 0 — collapsed LW host to clientHeight=0 (blank canvas) when parent % height unresolved */
  min-height: 420px;
  flex: 1 1 auto;
  height: 100%;
}

body.charts-focus .hc-shell-main.hc-scalp-main {
  /* Nearly full viewport so AI coach starts below the fold */
  min-height: max(740px, calc(100vh - 96px));
  height: auto;
}

.hc-scalp-mode .hc-shell-entry-builder,
.hc-scalp-mode #hcShellEntryBuilder {
  display: none !important;
}

.hc-scalp-mode .hc-shell-bottom-panels.is-hidden,
.hc-scalp-mode .hc-shell-score-strip.is-hidden {
  display: none !important;
  height: 0;
  margin: 0;
  padding: 0;
  border: 0;
  overflow: hidden;
}

.hc-scalp-power-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 8px;
  padding: 6px 8px;
  border: 1px solid var(--hc-border-dim);
  border-radius: var(--hc-radius);
  background: linear-gradient(90deg, rgba(4, 12, 22, 0.96), rgba(6, 18, 30, 0.94));
  align-items: center;
  z-index: 4;
}

.hc-scalp-chip {
  display: flex;
  flex-direction: column;
  gap: 1px;
  min-width: 64px;
  padding: 2px 6px;
  border-left: 2px solid rgba(27, 220, 255, 0.35);
}

.hc-scalp-chip .k {
  font-size: var(--hc-fs-xs);
  letter-spacing: 0.08em;
  color: var(--hc-muted);
}

.hc-scalp-chip .v {
  font-size: var(--hc-fs-sm);
  font-weight: 700;
  color: var(--hc-text);
  font-variant-numeric: tabular-nums;
}

.hc-scalp-chip.hc-tone-bull .v { color: var(--hc-green); }
.hc-scalp-chip.hc-tone-bear .v { color: var(--hc-red); }
.hc-scalp-chip.hc-tone-warn .v { color: var(--hc-yellow); }

/* Delta strength meter — far right of the scalp power strip, beside FRESH. */
.hc-delta-meter {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 2px;
  margin-left: auto;
  min-width: 148px;
  max-width: 220px;
  flex: 1 1 168px;
  padding: 1px 4px 2px;
}
.hc-delta-meter-k {
  font-size: var(--hc-fs-xs);
  letter-spacing: 0.1em;
  color: var(--hc-muted);
  font-weight: 700;
}
.hc-delta-meter-track {
  position: relative;
  height: 8px;
  border-radius: 2px;
  background: rgba(29, 64, 92, 0.42);
  overflow: hidden;
}
.hc-delta-meter-zero {
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 0;
  width: 1px;
  background: rgba(127, 184, 208, 0.85);
  transform: translateX(-50%);
  z-index: 2;
}
.hc-delta-meter-fill {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 0;
  z-index: 1;
}
.hc-delta-meter-fill-buy {
  left: 50%;
  background: linear-gradient(90deg, rgba(57, 255, 90, 0.35), #39ff5a);
  box-shadow: 0 0 8px rgba(57, 255, 90, 0.28);
}
.hc-delta-meter-fill-sell {
  right: 50%;
  background: linear-gradient(270deg, rgba(255, 77, 77, 0.35), #ff4d4d);
  box-shadow: 0 0 8px rgba(255, 77, 77, 0.28);
}
.hc-delta-meter-fill-flat {
  left: 50%;
  background: rgba(127, 184, 208, 0.25);
}
.hc-delta-meter-readout {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0;
  font-size: var(--hc-fs-xs);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.04em;
  color: var(--hc-text);
}
.hc-delta-meter-accel {
  font-size: var(--hc-fs-sm);
  line-height: 1.15;
}
.hc-delta-meter[data-side="buy"] .hc-delta-meter-accel,
.hc-delta-meter[data-side="buy"] .hc-delta-meter-rate {
  color: var(--hc-green);
}
.hc-delta-meter[data-side="sell"] .hc-delta-meter-accel,
.hc-delta-meter[data-side="sell"] .hc-delta-meter-rate {
  color: var(--hc-red);
}
.hc-delta-meter.is-flip .hc-delta-meter-track {
  animation: hc-delta-flip 0.7s ease;
}
@keyframes hc-delta-flip {
  0%, 100% { box-shadow: none; filter: none; }
  35% { box-shadow: 0 0 14px rgba(255, 210, 46, 0.85); filter: brightness(1.55); }
}

.hc-shell-scalp-badge {
  position: absolute;
  top: 8px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 6;
  padding: 7px 12px 8px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
  pointer-events: none;
  background: rgba(4, 10, 18, 0.92);
  border: 1px solid rgba(27, 220, 255, 0.4);
  color: var(--hc-cyan);
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 5px;
  min-width: min(720px, calc(100% - 24px));
  max-width: calc(100% - 16px);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.35);
}
.hc-shell-scalp-badge-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 8px 10px;
}
.hc-shell-scalp-badge-main {
  font-size: 12px;
  letter-spacing: 0.14em;
  white-space: nowrap;
  padding-right: 4px;
  border-right: 1px solid rgba(27, 220, 255, 0.28);
  margin-right: 2px;
}
.hc-shell-mode-strip {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 4px;
}
.hc-shell-mode-chip {
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.08em;
  padding: 3px 7px;
  border-radius: 3px;
  border: 1px solid rgba(148, 163, 184, 0.28);
  color: rgba(203, 213, 225, 0.55);
  background: rgba(15, 23, 42, 0.55);
  white-space: nowrap;
}
.hc-shell-mode-chip.is-active {
  color: #041018;
  background: var(--hc-cyan);
  border-color: var(--hc-cyan);
  box-shadow: 0 0 0 1px rgba(27, 220, 255, 0.35);
}
.hc-shell-hunt-chip {
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.06em;
  padding: 3px 8px;
  border-radius: 3px;
  border: 1px solid rgba(245, 166, 35, 0.4);
  color: #ffe08a;
  background: rgba(15, 23, 42, 0.55);
  white-space: nowrap;
}
.hc-shell-mode-blurb {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-align: center;
  color: rgba(226, 232, 240, 0.82);
  line-height: 1.25;
  text-transform: none;
}
.hc-shell-scalp-badge-mode {
  font-size: 10px;
  letter-spacing: 0.16em;
  opacity: 0.95;
  color: inherit;
}

.hc-shell-scalp-badge.hc-tone-bull {
  color: var(--hc-green);
  border-color: rgba(57, 255, 90, 0.5);
}
.hc-shell-scalp-badge.hc-tone-bull .hc-shell-mode-chip.is-active {
  background: var(--hc-green);
  border-color: var(--hc-green);
  color: #041018;
}

.hc-shell-scalp-badge.hc-tone-bear {
  color: var(--hc-red);
  border-color: rgba(255, 77, 77, 0.5);
}
.hc-shell-scalp-badge.hc-tone-bear .hc-shell-mode-chip.is-active {
  background: var(--hc-red);
  border-color: var(--hc-red);
  color: #041018;
}

.hc-shell-scalp-badge.hc-tone-warn {
  color: var(--hc-yellow);
  border-color: rgba(255, 210, 46, 0.5);
}
.hc-shell-scalp-badge.hc-tone-warn .hc-shell-mode-chip.is-active {
  background: var(--hc-yellow);
  border-color: var(--hc-yellow);
  color: #041018;
}

@media (max-width: 720px) {
  .hc-shell-scalp-badge {
    min-width: calc(100% - 12px);
    padding: 6px 8px 7px;
  }
  .hc-shell-scalp-badge-main {
    border-right: none;
    margin-right: 0;
    padding-right: 0;
    width: 100%;
    text-align: center;
  }
  .hc-shell-mode-chip {
    font-size: 8px;
    padding: 2px 5px;
  }
}

.hc-scalp-state-badge {
  text-align: center;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.1em;
  padding: 8px 6px;
  margin-bottom: 6px;
  border: 1px solid var(--hc-border-dim);
  border-radius: var(--hc-radius);
  background: rgba(0, 0, 0, 0.25);
}

.hc-scalp-state-badge.hc-tone-bull { color: var(--hc-green); border-color: rgba(57, 255, 90, 0.45); }
.hc-scalp-state-badge.hc-tone-bear { color: var(--hc-red); border-color: rgba(255, 77, 77, 0.45); }
.hc-scalp-state-badge.hc-tone-warn { color: var(--hc-yellow); border-color: rgba(255, 210, 46, 0.45); }

.hc-ws-scalp-explain {
  max-height: min(72vh, 820px);
  overflow-y: auto;
  overflow-x: hidden;
  -webkit-overflow-scrolling: touch;
}

.hc-scalp-meters {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 8px 0 10px;
}

.hc-scalp-meter-block {
  border: 1px solid var(--hc-border-dim);
  border-radius: var(--hc-radius);
  background: rgba(0, 0, 0, 0.22);
  padding: 7px 8px;
}

[data-voice-panel].is-voice-spoken {
  outline: 2px solid rgba(255, 243, 106, 0.95);
  outline-offset: 1px;
  box-shadow: 0 0 0 1px rgba(255, 210, 46, 0.35), 0 0 22px rgba(255, 210, 46, 0.45);
  animation: hc-voice-spoken-pulse 0.85s ease-in-out 4;
  z-index: 3;
  position: relative;
}
@keyframes hc-voice-spoken-pulse {
  0%, 100% {
    box-shadow: 0 0 0 1px rgba(255, 210, 46, 0.3), 0 0 14px rgba(255, 210, 46, 0.35);
  }
  50% {
    box-shadow: 0 0 0 2px rgba(255, 243, 106, 0.95), 0 0 28px rgba(255, 210, 46, 0.6);
  }
}

.hc-scalp-meter-title {
  font-size: 10px;
  letter-spacing: 0.08em;
  font-weight: 700;
  color: var(--hc-muted, #8a93a3);
  margin-bottom: 4px;
}

.hc-scalp-meter-score {
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.02em;
  margin-bottom: 5px;
}

.hc-scalp-meter-score.hc-tone-bull { color: var(--hc-green); }
.hc-scalp-meter-score.hc-tone-bear { color: var(--hc-red); }
.hc-scalp-meter-score.hc-tone-warn { color: var(--hc-yellow); }
.hc-scalp-meter-score.hc-tone-muted { color: var(--hc-muted, #8a93a3); }

.hc-scalp-meter-bar {
  height: 5px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  overflow: hidden;
  margin-bottom: 6px;
}

.hc-scalp-meter-bar > i {
  display: block;
  height: 100%;
  background: linear-gradient(90deg, #3d8bfd, #39ff5a);
  border-radius: inherit;
}

.hc-scalp-level-list {
  display: flex;
  flex-direction: column;
  gap: 3px;
  margin-top: 4px;
}

.hc-scalp-level-row {
  display: grid;
  grid-template-columns: 72px 1fr auto;
  gap: 6px;
  align-items: baseline;
  font-size: 11px;
}

.hc-scalp-level-name {
  color: var(--hc-muted, #8a93a3);
  font-weight: 600;
}

.hc-scalp-level-px {
  color: var(--hc-text, #e8edf5);
  font-variant-numeric: tabular-nums;
}

.hc-scalp-level-st {
  color: var(--hc-muted, #8a93a3);
  font-size: 10px;
  text-align: right;
}

.hc-scalp-level-row.is-break .hc-scalp-level-st,
.hc-scalp-level-row.is-break .hc-scalp-level-px {
  color: var(--hc-yellow);
}

.hc-scalp-level-row.is-at .hc-scalp-level-st {
  color: var(--hc-green);
}

.hc-scalp-level-row.is-wait .hc-scalp-level-st,
.hc-scalp-level-row.is-wait .hc-scalp-level-px {
  color: var(--hc-muted, #8a93a3);
}

.hc-scalp-exit-why b {
  color: var(--hc-yellow);
}

.hc-ws-below-compact {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.hc-shell-live-rsi-table tr.hc-tone-strong-green td:nth-child(2) b,
.hc-shell-live-rsi-table tr.hc-tone-strong-green td:nth-child(3),
.hc-shell-live-rsi-table tr.hc-tone-strong-green td:nth-child(4),
.hc-shell-live-rsi-table tr.hc-tone-strong-green td:nth-child(5) {
  color: #39ff5a;
  text-shadow: 0 0 6px rgba(57, 255, 90, 0.35);
}

.hc-shell-live-rsi-table tr.hc-tone-strong-red td:nth-child(2) b,
.hc-shell-live-rsi-table tr.hc-tone-strong-red td:nth-child(3),
.hc-shell-live-rsi-table tr.hc-tone-strong-red td:nth-child(4),
.hc-shell-live-rsi-table tr.hc-tone-strong-red td:nth-child(5) {
  color: #ff4d4d;
  text-shadow: 0 0 6px rgba(255, 77, 77, 0.35);
}

.hc-tone-strong-green { color: #39ff5a; }
.hc-tone-strong-red { color: #ff4d4d; }

/* Legacy page-top news slot stayed relative; chart flash is absolute on stage. */
.hc-scalp-mode .hc-shell-signal-alert-host {
  position: relative;
  z-index: 5;
}
.hc-scalp-mode .hc-shell-news-flash-host {
  z-index: 36;
}

.hc-scalp-mode .hc-shell-controls-wrap,
.hc-scalp-mode .hc-shell-header {
  position: relative;
  z-index: 6;
}

.hc-shell-left-rail {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
  min-height: 0;
  overflow: auto;
  border: 1px solid var(--hc-border-dim);
  border-radius: var(--hc-radius);
  background: linear-gradient(180deg, rgba(6, 14, 24, 0.98), rgba(3, 8, 14, 0.98));
  padding: 6px;
}

/* Fill the blank under Data Quality with News Impact + AI Trade Prob. */
.hc-ws-left-fill {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  gap: 5px;
  overflow: hidden;
}
.hc-ws-left-fill > .hc-ws-panel {
  flex: 1 1 0;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  padding: 5px;
}
.hc-ws-left-fill .hc-ws-panel-title {
  margin-bottom: 4px;
  font-size: 9px;
  letter-spacing: 0.1em;
}
.hc-ws-compact-miss {
  font-size: 9px;
  color: rgba(148, 163, 184, 0.85);
  line-height: 1.3;
}
.hc-ws-radar {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 3px;
  flex: 1;
  align-content: start;
  min-height: 0;
  overflow: auto;
}
.hc-ws-radar-axis {
  background: rgba(6, 15, 26, 0.9);
  border: 1px solid rgba(29, 64, 92, 0.45);
  border-radius: 4px;
  padding: 3px 4px 4px;
  text-align: center;
  min-width: 0;
}
.hc-ws-radar-lbl {
  font-size: 8px;
  letter-spacing: 0.06em;
  color: rgba(148, 163, 184, 0.9);
  font-weight: 700;
}
.hc-ws-radar-bar {
  height: 4px;
  background: rgba(13, 30, 42, 0.95);
  border-radius: 3px;
  margin: 4px 0 3px;
  overflow: hidden;
}
.hc-ws-radar-fill {
  height: 100%;
  border-radius: 3px;
  background: var(--hc-yellow);
}
.hc-ws-radar-axis.hc-tone-bull .hc-ws-radar-fill {
  background: var(--hc-green);
}
.hc-ws-radar-axis.hc-tone-bear .hc-ws-radar-fill {
  background: var(--hc-red);
}
.hc-ws-radar-axis.hc-tone-neut .hc-ws-radar-fill {
  background: var(--hc-yellow);
}
.hc-ws-radar-val {
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.02em;
}
.hc-ws-radar-axis.hc-tone-bull .hc-ws-radar-val {
  color: var(--hc-green);
}
.hc-ws-radar-axis.hc-tone-bear .hc-ws-radar-val {
  color: var(--hc-red);
}
.hc-ws-radar-axis.hc-tone-neut .hc-ws-radar-val {
  color: var(--hc-yellow);
}
.hc-ws-prob-rings {
  display: flex;
  justify-content: space-between;
  gap: 2px;
  margin-top: 2px;
}
.hc-ws-prob-ring {
  flex: 1;
  text-align: center;
  min-width: 0;
}
.hc-ws-prob-ring svg {
  display: block;
  margin: 0 auto;
}
.hc-ws-prob-ring-lbl {
  font-size: 8px;
  font-weight: 700;
  letter-spacing: 0.04em;
  color: rgba(148, 163, 184, 0.9);
  margin-top: 2px;
}
.hc-ws-prob-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 4px;
  margin-top: 5px;
  font-size: 9px;
  font-weight: 700;
}
.hc-ws-prob-bias {
  padding: 2px 5px;
  border-radius: 3px;
  border: 1px solid rgba(148, 163, 184, 0.35);
  color: rgba(226, 232, 240, 0.9);
}
.hc-ws-prob-bias.is-long {
  color: var(--hc-green);
  border-color: rgba(57, 255, 90, 0.45);
  background: rgba(57, 255, 90, 0.08);
}
.hc-ws-prob-bias.is-short {
  color: var(--hc-red);
  border-color: rgba(255, 77, 77, 0.45);
  background: rgba(255, 77, 77, 0.08);
}
.hc-ws-prob-bias.is-wait {
  color: var(--hc-yellow);
  border-color: rgba(255, 210, 46, 0.4);
  background: rgba(255, 210, 46, 0.08);
}
.hc-ws-prob-grade {
  color: rgba(167, 139, 250, 0.95);
}

.hc-ws-panel {
  border: 1px solid var(--hc-border-dim);
  border-radius: var(--hc-radius);
  background: var(--hc-panel);
  padding: 6px;
}

.hc-ws-panel-title {
  font-size: var(--hc-fs-xs);
  letter-spacing: 0.12em;
  color: var(--hc-cyan);
  font-weight: 700;
  margin-bottom: 6px;
}

.hc-ws-power-bars {
  display: flex;
  flex-direction: column;
  gap: 5px;
  margin-bottom: 6px;
}

.hc-ws-power-row {
  display: grid;
  grid-template-columns: 34px 1fr 28px;
  gap: 4px;
  align-items: center;
  opacity: 0.72;
}

.hc-ws-power-row.is-dominant {
  opacity: 1;
}

.hc-ws-power-lbl {
  font-size: var(--hc-fs-xs);
  font-weight: 700;
  letter-spacing: 0.08em;
}

.hc-ws-power-row.is-dominant .hc-ws-power-lbl {
  color: var(--hc-green);
}

.hc-ws-power-row.is-dominant:last-child .hc-ws-power-lbl,
.hc-ws-power-row.is-dominant .hc-ws-power-lbl {
  /* buy/sell colored via fill; dominant label uses side color below */
}

.hc-ws-power-bars .hc-ws-power-row:first-child.is-dominant .hc-ws-power-lbl {
  color: var(--hc-green);
}

.hc-ws-power-bars .hc-ws-power-row:last-child.is-dominant .hc-ws-power-lbl {
  color: var(--hc-red);
}

.hc-ws-power-track {
  height: 8px;
  background: rgba(29, 64, 92, 0.45);
  border-radius: 2px;
  overflow: hidden;
}

.hc-ws-power-fill {
  height: 100%;
  transition: width 0.35s ease;
}

.hc-ws-power-fill.buy {
  background: linear-gradient(90deg, rgba(57, 255, 90, 0.35), var(--hc-green));
}

.hc-ws-power-fill.sell {
  background: linear-gradient(90deg, rgba(255, 77, 77, 0.35), var(--hc-red));
}

.hc-ws-power-val {
  font-size: var(--hc-fs-xs);
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.hc-ws-kv {
  display: flex;
  justify-content: space-between;
  gap: 6px;
  font-size: var(--hc-fs-xs);
  padding: 2px 0;
  border-top: 1px solid rgba(29, 64, 92, 0.35);
}

.hc-ws-kv span {
  color: var(--hc-muted);
  letter-spacing: 0.06em;
}

.hc-ws-kv b {
  color: var(--hc-text);
  font-weight: 700;
}

/* Aggressive-volume pressure tones — scoped to delta / volspeed / power-strip only. */
.hc-ws-delta .hc-av-pressure-label,
.hc-ws-volspeed .hc-av-pressure-label {
  margin-left: 6px;
  font-size: 8px;
  letter-spacing: 0.08em;
  font-weight: 700;
  vertical-align: middle;
}
.hc-ws-delta.hc-av-tone-purple,
.hc-ws-volspeed.hc-av-tone-purple {
  border-color: rgba(169, 68, 255, 0.65) !important;
  box-shadow: 0 0 12px rgba(169, 68, 255, 0.35), inset 0 0 10px rgba(169, 68, 255, 0.08);
}
.hc-ws-delta.hc-av-tone-red,
.hc-ws-volspeed.hc-av-tone-red {
  border-color: rgba(255, 77, 77, 0.5) !important;
  box-shadow: 0 0 8px rgba(255, 77, 77, 0.18);
}
.hc-ws-delta.hc-av-tone-yellow,
.hc-ws-volspeed.hc-av-tone-yellow {
  border-color: rgba(255, 210, 46, 0.4) !important;
}
.hc-ws-delta.hc-av-tone-green,
.hc-ws-volspeed.hc-av-tone-green {
  border-color: rgba(57, 255, 90, 0.5) !important;
  box-shadow: 0 0 8px rgba(57, 255, 90, 0.18);
}
.hc-ws-delta.hc-av-tone-blue,
.hc-ws-volspeed.hc-av-tone-blue {
  border-color: rgba(61, 126, 255, 0.7) !important;
  box-shadow: 0 0 14px rgba(61, 126, 255, 0.4), inset 0 0 10px rgba(61, 126, 255, 0.1);
}
.hc-ws-delta.hc-av-tone-muted,
.hc-ws-volspeed.hc-av-tone-muted {
  border-color: var(--hc-border-dim) !important;
  box-shadow: none;
  opacity: 0.85;
}
.hc-ws-delta.hc-av-tone-purple .hc-ws-kv b,
.hc-ws-delta.hc-av-tone-purple .hc-av-pressure-label,
.hc-ws-volspeed.hc-av-tone-purple .hc-ws-kv b,
.hc-scalp-power-strip .hc-scalp-chip.hc-av-tone-purple .v {
  color: var(--hc-purple) !important;
  text-shadow: 0 0 8px rgba(169, 68, 255, 0.55);
}
.hc-ws-delta.hc-av-tone-red .hc-ws-kv b,
.hc-ws-delta.hc-av-tone-red .hc-av-pressure-label,
.hc-ws-volspeed.hc-av-tone-red .hc-ws-kv b,
.hc-scalp-power-strip .hc-scalp-chip.hc-av-tone-red .v {
  color: var(--hc-red) !important;
}
.hc-ws-delta.hc-av-tone-yellow .hc-ws-kv b,
.hc-ws-delta.hc-av-tone-yellow .hc-av-pressure-label,
.hc-ws-volspeed.hc-av-tone-yellow .hc-ws-kv b,
.hc-scalp-power-strip .hc-scalp-chip.hc-av-tone-yellow .v {
  color: var(--hc-yellow) !important;
}
.hc-ws-delta.hc-av-tone-green .hc-ws-kv b,
.hc-ws-delta.hc-av-tone-green .hc-av-pressure-label,
.hc-ws-volspeed.hc-av-tone-green .hc-ws-kv b,
.hc-scalp-power-strip .hc-scalp-chip.hc-av-tone-green .v {
  color: var(--hc-green) !important;
}
.hc-ws-delta.hc-av-tone-blue .hc-ws-kv b,
.hc-ws-delta.hc-av-tone-blue .hc-av-pressure-label,
.hc-ws-volspeed.hc-av-tone-blue .hc-ws-kv b,
.hc-scalp-power-strip .hc-scalp-chip.hc-av-tone-blue .v {
  color: var(--hc-blue) !important;
  text-shadow: 0 0 8px rgba(61, 126, 255, 0.55);
}
.hc-ws-delta.hc-av-tone-muted .hc-ws-kv b,
.hc-ws-volspeed.hc-av-tone-muted .hc-ws-kv b,
.hc-scalp-power-strip .hc-scalp-chip.hc-av-tone-muted .v {
  color: var(--hc-muted) !important;
  text-shadow: none;
}
.hc-scalp-power-strip .hc-scalp-chip.hc-av-tone-blue {
  box-shadow: 0 0 10px rgba(61, 126, 255, 0.35);
}
.hc-scalp-power-strip .hc-scalp-chip.hc-av-tone-purple {
  box-shadow: 0 0 10px rgba(169, 68, 255, 0.35);
}

.hc-ws-mag7-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2px 6px;
  margin-top: 4px;
}

.hc-ws-mag7-t {
  display: flex;
  justify-content: space-between;
  font-size: var(--hc-fs-xs);
  color: var(--hc-muted);
  padding: 2px 4px;
  border-radius: 3px;
  border: 1px solid transparent;
}

.hc-ws-mag7-t b {
  color: var(--hc-text);
}

.hc-ws-mag7-t.hc-tone-green b { color: var(--hc-green) !important; }
.hc-ws-mag7-t.hc-tone-red b { color: var(--hc-red) !important; }
.hc-ws-mag7-t.hc-tone-yellow b { color: var(--hc-yellow) !important; }
.hc-ws-mag7-t.is-heavy span { color: var(--hc-text); font-weight: 700; }
.hc-ws-mag7-t.is-synced {
  border-color: rgba(57, 255, 90, 0.35);
  background: rgba(57, 255, 90, 0.06);
}
.hc-ws-mag7-t.hc-tone-red.is-synced {
  border-color: rgba(255, 77, 77, 0.35);
  background: rgba(255, 77, 77, 0.06);
}

/* MAC-7 box sync lighting — breadth + heavy-hitter weight. */
.hc-ws-mag7 .hc-mag7-sync-label {
  margin-left: 6px;
  font-size: 8px;
  letter-spacing: 0.08em;
  font-weight: 700;
}
.hc-ws-mag7.hc-mag7-sync-green {
  border-color: rgba(57, 255, 90, 0.55) !important;
  box-shadow: 0 0 10px rgba(57, 255, 90, 0.22);
}
.hc-ws-mag7.hc-mag7-sync-red {
  border-color: rgba(255, 77, 77, 0.55) !important;
  box-shadow: 0 0 10px rgba(255, 77, 77, 0.22);
}
.hc-ws-mag7.hc-mag7-sync-blue {
  border-color: rgba(61, 126, 255, 0.75) !important;
  box-shadow: 0 0 16px rgba(61, 126, 255, 0.42), inset 0 0 12px rgba(61, 126, 255, 0.1);
}
.hc-ws-mag7.hc-mag7-sync-purple {
  border-color: rgba(169, 68, 255, 0.75) !important;
  box-shadow: 0 0 16px rgba(169, 68, 255, 0.4), inset 0 0 12px rgba(169, 68, 255, 0.1);
}
.hc-ws-mag7.hc-mag7-sync-yellow {
  border-color: rgba(255, 210, 46, 0.4) !important;
}
.hc-ws-mag7.hc-mag7-sync-muted {
  border-color: var(--hc-border-dim) !important;
  box-shadow: none;
  opacity: 0.85;
}
.hc-ws-mag7.hc-mag7-sync-blue .hc-mag7-sync-label,
.hc-ws-mag7.hc-mag7-sync-blue .hc-ws-kv b.hc-tone-blue {
  color: var(--hc-blue) !important;
  text-shadow: 0 0 8px rgba(61, 126, 255, 0.5);
}
.hc-ws-mag7.hc-mag7-sync-purple .hc-mag7-sync-label,
.hc-ws-mag7.hc-mag7-sync-purple .hc-ws-kv b.hc-tone-purple {
  color: var(--hc-purple) !important;
  text-shadow: 0 0 8px rgba(169, 68, 255, 0.5);
}

.hc-ws-status-extras {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 4px 6px;
  border: 1px solid var(--hc-border-dim);
  border-radius: var(--hc-radius);
  background: rgba(4, 10, 18, 0.9);
}

.hc-ws-chip {
  font-size: var(--hc-fs-xs);
  letter-spacing: 0.08em;
  color: var(--hc-muted);
}

.hc-ws-chip b {
  color: var(--hc-text);
  margin-left: 4px;
}

/* Scalp timing strip — snapback / fast / CAM / tape */
.hc-scalp-timing-strip {
  margin: 4px 0 6px;
  gap: 8px;
}
.hc-scalp-timing-strip .hc-ws-chip {
  padding: 3px 7px;
  border: 1px solid var(--hc-border-dim);
  border-radius: 4px;
  background: rgba(4, 10, 18, 0.92);
}
.hc-scalp-timing-strip .hc-ws-chip.hc-tone-green {
  border-color: rgba(57, 255, 90, 0.45);
}
.hc-scalp-timing-strip .hc-ws-chip.hc-tone-green b { color: var(--hc-green) !important; }
.hc-scalp-timing-strip .hc-ws-chip.hc-tone-red {
  border-color: rgba(255, 77, 77, 0.45);
}
.hc-scalp-timing-strip .hc-ws-chip.hc-tone-red b { color: var(--hc-red) !important; }
.hc-scalp-timing-strip .hc-ws-chip.hc-tone-yellow {
  border-color: rgba(255, 210, 46, 0.4);
}
.hc-scalp-timing-strip .hc-ws-chip.hc-tone-yellow b { color: var(--hc-yellow) !important; }
.hc-scalp-timing-strip .hc-ws-chip.hc-tone-blue,
.hc-scalp-timing-strip .hc-ws-chip.is-cam-unlocked.hc-tone-blue {
  border-color: rgba(61, 126, 255, 0.7);
  box-shadow: 0 0 10px rgba(61, 126, 255, 0.35);
}
.hc-scalp-timing-strip .hc-ws-chip.hc-tone-blue b { color: var(--hc-blue) !important; text-shadow: 0 0 6px rgba(61, 126, 255, 0.45); }
.hc-scalp-timing-strip .hc-ws-chip.hc-tone-purple,
.hc-scalp-timing-strip .hc-ws-chip.is-cam-unlocked.hc-tone-purple {
  border-color: rgba(169, 68, 255, 0.7);
  box-shadow: 0 0 10px rgba(169, 68, 255, 0.35);
}
.hc-scalp-timing-strip .hc-ws-chip.hc-tone-purple b { color: var(--hc-purple) !important; text-shadow: 0 0 6px rgba(169, 68, 255, 0.45); }
.hc-ws-mag7 .hc-mag7-cam-unlocked {
  text-shadow: 0 0 8px rgba(61, 126, 255, 0.45);
}

.hc-ws-below {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 4px;
  padding: 4px;
  border: 1px solid var(--hc-border-dim);
  border-radius: var(--hc-radius);
  background: rgba(4, 10, 18, 0.92);
}

.hc-ws-below-item {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
  padding: 4px 6px;
  border-left: 2px solid rgba(27, 220, 255, 0.25);
}

.hc-ws-below-item span {
  font-size: var(--hc-fs-xs);
  color: var(--hc-muted);
  letter-spacing: 0.08em;
}

.hc-ws-below-item b {
  font-size: var(--hc-fs-sm);
  color: var(--hc-text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.hc-shell-vis-bar{
  display:flex;
  flex-wrap:wrap;
  gap:4px;
  margin-top:6px;
  padding:4px 0;
}
.hc-shell-vis-btn{
  border:1px solid rgba(62,207,255,.25);
  background:rgba(8,16,28,.9);
  color:#8fa3b8;
  font-size:9px;
  letter-spacing:.3px;
  text-transform:uppercase;
  padding:3px 6px;
  border-radius:4px;
  cursor:pointer;
}
.hc-shell-vis-btn.is-on{
  color:#e7f3ff;
  border-color:rgba(62,207,255,.55);
  background:rgba(62,207,255,.12);
}
.hc-ws-diagnostics {
  border: 1px solid var(--hc-border-dim);
  border-radius: var(--hc-radius);
  background: rgba(2, 8, 14, 0.95);
  padding: 4px 8px;
  font-size: var(--hc-fs-xs);
  color: var(--hc-muted);
}

.hc-ws-diagnostics summary {
  cursor: pointer;
  color: var(--hc-cyan);
  letter-spacing: 0.1em;
  font-weight: 700;
  list-style: none;
}

.hc-ws-diagnostics summary::-webkit-details-marker {
  display: none;
}

.hc-ws-diag-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 4px 10px;
  margin-top: 6px;
  max-height: 180px;
  overflow: auto;
}

.hc-ws-diag-grid b {
  color: var(--hc-text);
}

.hc-shell-chart-pane {
  min-width: 0;
  min-height: 0;
  height: 100%;
  display: flex;
  flex-direction: column;
  background: var(--hc-bg);
  border: 1px solid var(--hc-border);
  border-radius: var(--hc-radius);
  box-shadow: var(--hc-glow-cyan);
  overflow: hidden;
}

.hc-shell-chart-stage {
  position: relative;
  flex: 1 1 auto;
  min-height: 420px;
  height: 100%;
  background:
    linear-gradient(180deg, rgba(2, 8, 16, 0.2), transparent 30%),
    var(--hc-bg);
  overflow: hidden;
}

.hc-shell-grid {
  position: absolute;
  inset: 0 52px 22px 0;
  background-image:
    linear-gradient(to right, var(--hc-grid) 1px, transparent 1px),
    linear-gradient(to bottom, var(--hc-grid) 1px, transparent 1px);
  background-size: 48px 36px;
  opacity: 0.7;
  pointer-events: none;
  z-index: 1;
}

.hc-shell-sessions {
  position: absolute;
  inset: 0 52px 22px 0;
  pointer-events: none;
  z-index: 2;
}

.hc-shell-session-band {
  position: absolute;
  top: 0;
  bottom: 0;
}
.hc-session-pre { background: var(--hc-session-pre); }
.hc-session-open { background: var(--hc-session-open); border-left: 1px solid rgba(57, 255, 90, 0.15); }
.hc-session-mid { background: var(--hc-session-mid); }
.hc-session-power { background: var(--hc-session-power); border-left: 1px solid rgba(255, 138, 0, 0.18); }
.hc-session-close { background: var(--hc-session-close); }

.hc-shell-rail-channels {
  position: absolute;
  inset: 0 52px 22px 0;
  pointer-events: none;
  z-index: 3;
}

.hc-shell-rail-line {
  position: absolute;
  left: 0;
  right: 0;
  height: 0;
  border-top-width: 1px;
  border-top-style: solid;
  opacity: 0.75;
}
.hc-shell-rail-line.hc-rail-cyan { border-top-color: var(--hc-cyan); box-shadow: 0 0 4px rgba(27, 220, 255, 0.35); }
.hc-shell-rail-line.hc-rail-green { border-top-color: var(--hc-green); box-shadow: 0 0 4px rgba(57, 255, 90, 0.3); }
.hc-shell-rail-line.hc-rail-orange { border-top-color: var(--hc-orange); box-shadow: 0 0 4px rgba(255, 138, 0, 0.3); }
.hc-shell-rail-line.hc-rail-blue { border-top-color: var(--hc-blue); box-shadow: 0 0 4px rgba(61, 126, 255, 0.35); }
.hc-shell-rail-line.hc-rail-purple { border-top-color: var(--hc-purple); box-shadow: 0 0 4px rgba(169, 68, 255, 0.35); }
.hc-shell-rail-line.hc-style-dashed { border-top-style: dashed; }
.hc-shell-rail-line.hc-style-dotted { border-top-style: dotted; }

.hc-shell-candles {
  position: absolute;
  inset: 8px 58px 26px 8px;
  display: flex;
  align-items: stretch;
  gap: 2px;
  z-index: 4;
  pointer-events: none;
}
.hc-shell-candles.is-hidden { opacity: 0; }

.hc-shell-candle {
  position: relative;
  flex: 1 1 0;
  min-width: 0;
  height: 100%;
}
.hc-shell-candle .wick {
  position: absolute;
  left: 50%;
  width: 1px;
  transform: translateX(-50%);
  background: currentColor;
  opacity: 0.85;
}
.hc-shell-candle .body {
  position: absolute;
  left: 15%;
  right: 15%;
  border-radius: 1px;
  background: currentColor;
  box-shadow: 0 0 4px currentColor;
}
.hc-shell-candle.up { color: var(--hc-green); }
.hc-shell-candle.down { color: var(--hc-red); }

.hc-shell-lw-host {
  position: absolute;
  inset: 0 0 0 0;
  z-index: 5;
  opacity: 0;
  pointer-events: none;
  /* Touch-friendly chart surface */
  touch-action: none;
  -webkit-user-select: none;
  user-select: none;
}
.hc-shell-lw-host.is-active {
  opacity: 1;
  pointer-events: auto;
}
.hc-shell-lw-host.is-loading {
  opacity: 0;
  pointer-events: none;
}
/* is-active always wins: never hide candle bodies behind a loading veil. */
.hc-shell-lw-host.is-active.is-loading {
  opacity: 1;
  pointer-events: auto;
}
.hc-shell-lw-host.is-active + .hc-shell-overlays {
  /* Live LW chart owns trade price-lines — hide CSS duplicates. */
  display: none;
  pointer-events: none;
}

.hc-shell-candle-loading {
  position: absolute;
  inset: 0;
  z-index: 40;
  display: none;
  align-items: center;
  justify-content: center;
  pointer-events: none;
  background: linear-gradient(
    180deg,
    rgba(2, 5, 10, 0.55) 0%,
    rgba(2, 5, 10, 0.72) 100%
  );
}
.hc-shell-candle-loading.is-visible {
  display: flex;
}
.hc-shell-candle-loading-inner {
  font-family: "IBM Plex Mono", "Consolas", monospace;
  font-size: var(--hc-fs-md);
  letter-spacing: 0.04em;
  color: var(--hc-cyan);
  text-transform: none;
  padding: 10px 14px;
  border: 1px solid var(--hc-border-dim);
  background: rgba(5, 13, 22, 0.92);
}
.hc-shell-status-loading {
  color: var(--hc-cyan);
  margin-left: 8px;
}

/* When live LW chart is mounted, hide decorative CSS scales (LW has its own) */
.hc-shell-chart-stage.hc-live-chart .hc-shell-price-scale,
.hc-shell-chart-stage.hc-live-chart .hc-shell-time-scale,
.hc-shell-chart-stage.hc-live-chart .hc-shell-grid {
  opacity: 0;
}
.hc-shell-chart-stage.hc-live-chart .hc-shell-sessions,
.hc-shell-chart-stage.hc-live-chart .hc-shell-rail-channels {
  opacity: 0.35;
}

.hc-shell-overlays {
  position: absolute;
  inset: 0 52px 22px 0;
  z-index: 6;
  pointer-events: none;
}

.hc-shell-level {
  position: absolute;
  left: 0;
  right: 0;
  height: 0;
  display: flex;
  align-items: center;
  justify-content: flex-end;
}

.hc-shell-level-line {
  position: absolute;
  left: 0;
  right: 0;
  border-top: 1px dashed currentColor;
  opacity: 0.85;
}

.hc-shell-level-tag {
  position: relative;
  z-index: 1;
  margin-right: 4px;
  padding: 1px 5px;
  font-size: var(--hc-fs-xs);
  font-weight: 900;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  background: rgba(2, 5, 10, 0.88);
  border: 1px solid currentColor;
  border-radius: 2px;
  white-space: nowrap;
  box-shadow: 0 0 6px currentColor;
}

.hc-shell-level.lvl-t { color: var(--hc-green); }
.hc-shell-level.lvl-entry { color: var(--hc-cyan); }
.hc-shell-level.lvl-aps { color: var(--hc-orange); }
.hc-shell-level.lvl-pressure { color: var(--hc-purple); }
.hc-shell-level.lvl-hard { color: var(--hc-red); }
.hc-shell-level.lvl-price { color: var(--hc-yellow); }
.hc-shell-level.lvl-price .hc-shell-level-line {
  border-top-style: dashed;
  border-top-width: 1px;
}

.hc-shell-t1-hit {
  position: absolute;
  z-index: 7;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 2px 7px;
  font-size: var(--hc-fs-xs);
  font-weight: 900;
  letter-spacing: 0.08em;
  color: var(--hc-green);
  background: rgba(2, 5, 10, 0.9);
  border: 1px solid var(--hc-green);
  border-radius: 2px;
  box-shadow: var(--hc-glow-green);
  text-transform: uppercase;
  transform: translate(-50%, -100%);
}
.hc-shell-t1-hit .dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--hc-green);
  box-shadow: 0 0 8px var(--hc-green);
}

/* Rails legend — off the candle pane. Horizontal rail lines stay. */
.hc-shell-rails-legend,
#hcShellRailsLegend {
  display: none !important;
  visibility: hidden !important;
  pointer-events: none !important;
  opacity: 0 !important;
  width: 0 !important;
  height: 0 !important;
  min-width: 0 !important;
  padding: 0 !important;
  margin: 0 !important;
  overflow: hidden !important;
  border: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

.hc-shell-rails-title {
  font-size: var(--hc-fs-xs);
  font-weight: 900;
  color: var(--hc-cyan);
  letter-spacing: 0.12em;
  margin-bottom: 4px;
  text-transform: uppercase;
}

.hc-shell-rail-item {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: var(--hc-fs-xs);
  font-weight: 700;
  color: var(--hc-text);
  padding: 1px 0;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.hc-shell-rail-item .swatch {
  width: 14px;
  height: 2px;
  border-radius: 1px;
  box-shadow: 0 0 4px currentColor;
  background: currentColor;
}
.hc-shell-rail-item.hc-rail-cyan { color: var(--hc-cyan); }
.hc-shell-rail-item.hc-rail-green { color: var(--hc-green); }
.hc-shell-rail-item.hc-rail-orange { color: var(--hc-orange); }
.hc-shell-rail-item.hc-rail-blue { color: var(--hc-blue); }
.hc-shell-rail-item.hc-rail-purple { color: var(--hc-purple); }

.hc-shell-rail-meta {
  opacity: 0.75;
  font-weight: 600;
  letter-spacing: 0.04em;
}

.hc-shell-rails-bias {
  margin-top: 5px;
  padding-top: 4px;
  border-top: 1px solid rgba(27, 220, 255, 0.18);
  font-size: var(--hc-fs-xs);
  font-weight: 900;
  color: var(--hc-cyan);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hc-shell-session-badge {
  display: inline-flex;
  align-items: center;
  margin-top: 3px;
  padding: 2px 7px;
  font-size: var(--hc-fs-xs);
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  border: 1px solid currentColor;
  border-radius: var(--hc-radius);
  background: rgba(2, 5, 10, 0.75);
  width: fit-content;
}
.hc-shell-session-badge.hc-tone-bull { color: var(--hc-green); box-shadow: var(--hc-glow-green); }
.hc-shell-session-badge.hc-tone-warn { color: var(--hc-yellow); }
.hc-shell-session-badge.hc-tone-purple { color: var(--hc-orange); box-shadow: var(--hc-glow-orange); }
.hc-shell-session-badge.hc-tone-bear { color: var(--hc-purple); box-shadow: var(--hc-glow-purple); }

/* TradingView-style next-candle timer — pinned to right price-scale area */
.hc-shell-countdown {
  position: absolute;
  top: 10px;
  right: 8px;
  z-index: 12;
  display: inline-flex;
  align-items: baseline;
  gap: 6px;
  min-width: 0;
  padding: 5px 8px;
  background: rgba(4, 11, 20, 0.92);
  border: 1px solid rgba(27, 220, 255, 0.35);
  border-radius: var(--hc-radius);
  box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.35), 0 0 12px rgba(27, 220, 255, 0.12);
  pointer-events: none;
  text-align: left;
}
.hc-shell-chart-stage.hc-live-chart .hc-shell-countdown {
  /* Sit just left of the LW right price scale (~55–70px) */
  right: 58px;
}
.hc-shell-countdown-lbl {
  font-size: 8px;
  font-weight: 900;
  letter-spacing: 0.14em;
  color: var(--hc-muted);
  line-height: 1;
}
.hc-shell-countdown-val {
  font-size: var(--hc-fs-md);
  font-weight: 900;
  color: var(--hc-cyan);
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.06em;
  line-height: 1;
}

.hc-shell-follow-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-left: 8px;
  padding: 4px 9px;
  border: 1px solid rgba(27, 220, 255, 0.35);
  border-radius: var(--hc-radius);
  background: rgba(4, 11, 20, 0.85);
  color: var(--hc-muted);
  font-size: var(--hc-fs-xs);
  font-weight: 900;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor: pointer;
  transition: color 0.2s ease, border-color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}
.hc-shell-follow-btn:hover {
  border-color: rgba(27, 220, 255, 0.65);
  color: var(--hc-text);
}
.hc-shell-follow-btn.is-on {
  color: var(--hc-cyan);
  border-color: rgba(27, 220, 255, 0.7);
  box-shadow: 0 0 10px rgba(27, 220, 255, 0.18);
}
.hc-shell-follow-btn.is-off {
  color: var(--hc-muted);
  opacity: 0.85;
}
.hc-shell-follow-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: currentColor;
  box-shadow: 0 0 6px currentColor;
  flex: 0 0 auto;
}
.hc-shell-follow-btn.is-on .hc-shell-follow-dot {
  animation: hc-follow-pulse 1.6s ease-in-out infinite;
}
.hc-shell-follow-lbl {
  white-space: nowrap;
}
.hc-shell-follow-state {
  min-width: 1.6em;
}
.hc-shell-heat-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-left: 8px;
  padding: 4px 9px;
  border: 1px solid rgba(232, 128, 180, 0.35);
  border-radius: var(--hc-radius);
  background: rgba(4, 11, 20, 0.85);
  color: var(--hc-muted);
  font-size: var(--hc-fs-xs);
  font-weight: 900;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor: pointer;
  transition: color 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}
.hc-shell-heat-btn:hover {
  border-color: rgba(232, 128, 180, 0.65);
  color: var(--hc-text);
}
.hc-shell-heat-btn.is-on {
  color: #e880b4;
  border-color: rgba(232, 128, 180, 0.7);
}
.hc-shell-heat-btn.is-off {
  color: var(--hc-muted);
  opacity: 0.85;
}
.hc-shell-heat-state {
  min-width: 1.6em;
  color: inherit;
  opacity: 0.9;
}
@keyframes hc-follow-pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.45; transform: scale(0.85); }
}

.hc-shell-box-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-left: 8px;
  padding: 4px 9px;
  border: 1px solid rgba(27, 220, 255, 0.35);
  border-radius: var(--hc-radius);
  background: rgba(4, 11, 20, 0.85);
  color: var(--hc-muted);
  font-size: var(--hc-fs-xs);
  font-weight: 900;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor: pointer;
  transition: color 0.2s ease, border-color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
}
.hc-shell-box-btn:hover {
  border-color: rgba(27, 220, 255, 0.65);
  color: var(--hc-text);
}
.hc-shell-box-btn.is-on {
  color: var(--hc-cyan);
  border-color: rgba(27, 220, 255, 0.7);
  box-shadow: 0 0 10px rgba(27, 220, 255, 0.18);
}
.hc-shell-box-btn.is-off,
.hc-shell-box-btn.is-clear {
  color: var(--hc-muted);
  opacity: 0.9;
}
.hc-shell-box-lbl {
  white-space: nowrap;
}
.hc-shell-box-hud {
  display: inline-flex;
  align-items: flex-start;
  margin-left: 8px;
  max-width: min(420px, 46vw);
  pointer-events: none;
}
.hc-shell-box-hud:empty {
  display: none;
}
.hc-drawn-box-hud.is-chip {
  position: static;
  pointer-events: none;
  min-width: 168px;
  padding: 6px 8px;
  background: rgba(7, 12, 18, 0.92);
  border: 1px solid #2a3542;
  border-radius: 8px;
  color: #eaf4ff;
  font: 11px/1.35 Inter, Arial, sans-serif;
  letter-spacing: 0.04em;
}
.hc-chart-guide-ladder {
  position: absolute;
  right: 10px;
  top: 8px;
  z-index: 26;
  pointer-events: none;
  min-width: 128px;
  max-width: 188px;
  padding: 6px 8px;
  background: rgba(7, 12, 18, 0.92);
  border: 1px solid #2a3542;
  border-radius: 8px;
  color: #eaf4ff;
  font: 10px/1.35 Inter, Arial, sans-serif;
  letter-spacing: 0.03em;
}
.hc-chart-guide-ladder [data-hc-ladder] {
  margin-top: 6px;
  color: #c8d2dc;
}
.hc-chart-guide-ladder [data-hc-decision] {
  color: #ffe08a;
  font-weight: 700;
  letter-spacing: 0.04em;
  margin-bottom: 4px;
}
.hc-chart-guide-ladder [data-hc-guide-foot] {
  margin-top: 6px;
  color: #9ecfff;
}
.hc-chart-guide-ladder.is-off {
  display: none !important;
}
.hc-decision-dock {
  position: absolute;
  left: 10px;
  bottom: 28px;
  z-index: 24;
  pointer-events: auto;
  width: 460px;
  max-width: 520px;
  min-height: 44px;
  max-height: 44px;
  overflow: hidden;
  padding: 6px 10px 8px;
  background: rgba(7, 12, 18, 0.92);
  border: 1px solid #2a3542;
  border-left: 2px solid #f5a623;
  border-radius: 8px;
  color: #eaf4ff;
  font: 11px/1.35 Inter, Arial, sans-serif;
  letter-spacing: 0.03em;
}
.hc-decision-dock:hover,
.hc-decision-dock.is-open {
  max-height: 120px;
}
.hc-decision-dock[data-stale="1"] {
  max-height: 36px;
  border-left-color: #8b95a5;
  color: #8b95a5;
}
.hc-decision-dock [data-hc-decision] {
  color: #ffe08a;
  font-weight: 700;
  letter-spacing: 0.04em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.hc-decision-dock [data-hc-decision-expand] {
  margin-top: 6px;
  color: #c8d2dc;
  font-weight: 400;
}
.hc-decision-dock [data-hc-decision-foot] {
  margin-top: 4px;
  color: #9ecfff;
}

/* Sound / voice alerts toggle (visual/manual only — no broker orders) */
.hc-shell-controls-wrap {
  position: relative;
  display: inline-flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
}
.hc-shell-sound-wrap {
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.hc-shell-sound-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 10px;
  border-radius: var(--hc-radius);
  border: 1px solid var(--hc-border-dim);
  background: rgba(8, 14, 24, 0.85);
  color: var(--hc-muted);
  font-size: var(--hc-fs-xs);
  font-weight: 700;
  letter-spacing: 0.08em;
  cursor: pointer;
  transition: color 0.2s ease, border-color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
  max-width: 220px;
}
.hc-shell-sound-btn:hover {
  border-color: rgba(57, 255, 168, 0.55);
  color: var(--hc-text);
}
.hc-shell-sound-btn.is-on,
.hc-shell-sound-btn.is-ready {
  color: #39ffa8;
  border-color: rgba(57, 255, 168, 0.7);
  box-shadow: 0 0 10px rgba(57, 255, 168, 0.16);
}
.hc-shell-sound-btn.is-off {
  color: var(--hc-muted);
  opacity: 0.85;
}
.hc-shell-sound-btn.is-unlocking {
  color: #f0c14b;
  border-color: rgba(240, 193, 75, 0.65);
}
.hc-shell-sound-btn.is-error {
  color: #ff6b6b;
  border-color: rgba(255, 107, 107, 0.7);
}
.hc-shell-sound-btn.is-paused {
  color: #f0c14b;
  border-color: rgba(240, 193, 75, 0.7);
  animation: hc-voice-paused-pulse 1.4s ease-in-out infinite;
}
@keyframes hc-voice-paused-pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.55; }
}
.hc-shell-sound-icon {
  font-size: 11px;
  line-height: 1;
  min-width: 0.9em;
  text-align: center;
}
.hc-shell-sound-lbl {
  white-space: nowrap;
}
.hc-shell-sound-state {
  min-width: 1.6em;
  color: inherit;
  opacity: 0.95;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  font-size: 10px;
  letter-spacing: 0.06em;
}
.hc-shell-voice-gear,
.hc-shell-voice-test-open {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 5px 8px;
  border-radius: var(--hc-radius);
  border: 1px solid var(--hc-border-dim);
  background: rgba(8, 14, 24, 0.85);
  color: var(--hc-muted);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.08em;
  cursor: pointer;
}
.hc-shell-voice-gear:hover,
.hc-shell-voice-test-open:hover {
  color: var(--hc-text);
  border-color: rgba(57, 255, 168, 0.45);
}
.hc-voice-settings,
.hc-voice-test-panel {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  z-index: 40;
  min-width: 260px;
  max-width: min(360px, 92vw);
  padding: 12px;
  border-radius: 8px;
  border: 1px solid rgba(57, 255, 168, 0.28);
  background: rgba(6, 12, 22, 0.96);
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.45);
  color: var(--hc-text);
  font-size: 11px;
}
.hc-voice-test-panel {
  min-width: 300px;
  right: 0;
}
.hc-voice-settings-hd,
.hc-voice-test-hd {
  font-weight: 800;
  letter-spacing: 0.12em;
  margin-bottom: 10px;
  color: #39ffa8;
}
.hc-voice-test-admin {
  color: #f0c14b;
  font-size: 9px;
  margin-left: 6px;
}
.hc-voice-set-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 6px 0;
  color: var(--hc-muted);
}
.hc-voice-set-note {
  margin: 8px 0 10px;
  color: #7fb8d0;
  line-height: 1.4;
}
.hc-voice-set-row input[type="range"],
.hc-voice-set-row select {
  flex: 1;
  min-width: 0;
}
.hc-voice-set-close {
  margin-top: 10px;
  width: 100%;
  padding: 6px 8px;
  border-radius: 6px;
  border: 1px solid var(--hc-border-dim);
  background: rgba(20, 28, 40, 0.9);
  color: var(--hc-text);
  cursor: pointer;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.08em;
}
.hc-voice-test-btns {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  margin-bottom: 10px;
}
.hc-voice-test-btn {
  padding: 7px 8px;
  border-radius: 6px;
  border: 1px solid rgba(57, 255, 168, 0.28);
  background: rgba(12, 22, 34, 0.95);
  color: var(--hc-text);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.04em;
  cursor: pointer;
  text-align: left;
}
.hc-voice-test-btn:hover {
  border-color: rgba(57, 255, 168, 0.65);
  color: #39ffa8;
}
.hc-voice-test-diag {
  display: grid;
  gap: 3px;
  color: var(--hc-muted);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 10px;
  line-height: 1.35;
  padding: 8px;
  border-radius: 6px;
  background: rgba(0, 0, 0, 0.28);
  margin-bottom: 4px;
}
.hc-voice-latency {
  color: #39ffa8 !important;
}

/* Transient signal flash banners */
.hc-shell-signal-alert-host {
  position: relative;
  z-index: 40;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  pointer-events: none;
  min-height: 0;
  margin: 0;
  padding: 0 8px;
}
.hc-shell-signal-flash {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  max-width: min(520px, 92vw);
  padding: 8px 14px;
  border-radius: var(--hc-radius);
  border: 1px solid var(--hc-border-dim);
  background: rgba(8, 14, 24, 0.94);
  font-size: clamp(11px, 1.1vw, 13px);
  font-weight: 800;
  letter-spacing: 0.12em;
  color: var(--hc-text);
  opacity: 0;
  transform: translateY(-8px) scale(0.98);
  transition: opacity 0.22s ease, transform 0.22s ease;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
}
.hc-shell-signal-flash.is-visible {
  opacity: 1;
  transform: translateY(0) scale(1);
  animation: hc-signal-flash-pulse 0.55s ease-out 1;
}
.hc-shell-signal-flash.is-leaving {
  opacity: 0;
  transform: translateY(-6px);
}
.hc-shell-signal-flash-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: currentColor;
  box-shadow: 0 0 8px currentColor;
  flex: 0 0 auto;
}
.hc-shell-signal-flash-lbl {
  white-space: nowrap;
}
.hc-shell-signal-flash.hc-flash-bull {
  color: #39ffa8;
  border-color: rgba(57, 255, 168, 0.55);
  background: linear-gradient(90deg, rgba(57, 255, 168, 0.16), rgba(8, 14, 24, 0.94));
}
.hc-shell-signal-flash.hc-flash-bear {
  color: #ff5c7a;
  border-color: rgba(255, 92, 122, 0.55);
  background: linear-gradient(90deg, rgba(255, 92, 122, 0.18), rgba(8, 14, 24, 0.94));
}
.hc-shell-signal-flash.hc-flash-cyan {
  color: var(--hc-cyan);
  border-color: rgba(27, 220, 255, 0.55);
  background: linear-gradient(90deg, rgba(27, 220, 255, 0.16), rgba(8, 14, 24, 0.94));
}
.hc-shell-signal-flash.hc-flash-warn,
.hc-shell-signal-flash.hc-flash-yellow {
  color: var(--hc-yellow);
  border-color: rgba(255, 210, 46, 0.55);
  background: linear-gradient(90deg, rgba(255, 210, 46, 0.16), rgba(8, 14, 24, 0.94));
}
.hc-shell-signal-flash.hc-flash-group-danger {
  letter-spacing: 0.14em;
}
.hc-shell-macro-flash {
  max-width: min(640px, 94vw);
  align-items: flex-start;
  padding: 10px 14px;
  letter-spacing: 0.04em;
  font-weight: 700;
}
.hc-shell-macro-flash-body {
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}
.hc-shell-macro-flash-top {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  font-size: clamp(10px, 1vw, 12px);
  letter-spacing: 0.1em;
  font-weight: 900;
}
.hc-shell-macro-flash-tag {
  letter-spacing: 0.14em;
}
.hc-shell-macro-flash-bias,
.hc-shell-macro-flash-score {
  opacity: 0.95;
}
.hc-shell-macro-flash-headline {
  font-size: clamp(11px, 1.15vw, 14px);
  font-weight: 800;
  letter-spacing: 0.02em;
  line-height: 1.35;
  white-space: normal;
  color: var(--hc-text);
}
.hc-shell-macro-flash-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  font-size: clamp(9px, 0.85vw, 11px);
  letter-spacing: 0.06em;
  color: var(--hc-muted);
  font-weight: 700;
}
@keyframes hc-signal-flash-pulse {
  0% { filter: brightness(1.35); }
  100% { filter: brightness(1); }
}


.hc-shell-meter {
  margin: 3px 0 5px;
}
.hc-shell-meter-head {
  display: flex;
  justify-content: space-between;
  gap: 6px;
  font-size: var(--hc-fs-xs);
  font-weight: 800;
  letter-spacing: 0.08em;
  margin-bottom: 2px;
}
.hc-shell-meter-head .k { color: var(--hc-muted); }
.hc-shell-meter-head .v { color: var(--hc-text); }
.hc-shell-meter-track {
  height: 4px;
  background: rgba(29, 64, 92, 0.55);
  border-radius: 2px;
  overflow: hidden;
}
.hc-shell-meter-fill {
  height: 100%;
  width: 0;
  background: var(--hc-cyan);
  box-shadow: 0 0 6px rgba(27, 220, 255, 0.35);
  transition: width 0.35s ease;
}
.hc-shell-meter.hc-tone-bull .hc-shell-meter-fill { background: var(--hc-green); box-shadow: 0 0 6px rgba(57, 255, 90, 0.35); }
.hc-shell-meter.hc-tone-warn .hc-shell-meter-fill { background: var(--hc-yellow); box-shadow: 0 0 6px rgba(255, 210, 46, 0.3); }
.hc-shell-meter.hc-tone-purple .hc-shell-meter-fill { background: var(--hc-purple); }

.hc-shell-chart-stage.hc-live-chart .hc-shell-rail-channels {
  opacity: 0;
  pointer-events: none;
}

/* Entry Builder floating panel — bottom-center of chart (trade prep + macro flash) */
.hc-shell-entry-builder {
  position: absolute;
  left: 50%;
  bottom: 30px;
  transform: translateX(-50%);
  z-index: 9;
  width: min(300px, 48%);
  padding: 6px 8px;
  background: rgba(4, 11, 20, 0.94);
  border: 1px solid rgba(27, 220, 255, 0.45);
  border-radius: var(--hc-radius);
  box-shadow: var(--hc-glow-cyan), 0 8px 24px rgba(0, 0, 0, 0.45);
  pointer-events: none;
  transition: border-color 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
}

.hc-shell-entry-builder-alert {
  border-color: rgba(255, 210, 46, 0.7);
  box-shadow: 0 0 18px rgba(255, 210, 46, 0.28), 0 8px 24px rgba(0, 0, 0, 0.5);
  animation: hc-eb-alert-pulse 0.9s ease-out 2;
}

.hc-shell-entry-builder-alert.hc-tone-bull {
  border-color: rgba(57, 255, 90, 0.7);
  box-shadow: 0 0 18px rgba(57, 255, 90, 0.28), 0 8px 24px rgba(0, 0, 0, 0.5);
}

.hc-shell-entry-builder-alert.hc-tone-bear {
  border-color: rgba(255, 74, 74, 0.7);
  box-shadow: 0 0 18px rgba(255, 74, 74, 0.28), 0 8px 24px rgba(0, 0, 0, 0.5);
}

.hc-shell-entry-builder-alert.hc-tone-warn {
  border-color: rgba(255, 210, 46, 0.7);
  box-shadow: 0 0 18px rgba(255, 210, 46, 0.28), 0 8px 24px rgba(0, 0, 0, 0.5);
}

.hc-shell-entry-builder-alert .hc-shell-eb-title {
  color: var(--hc-yellow);
  letter-spacing: 0.16em;
}

.hc-shell-entry-builder-alert.hc-tone-bull .hc-shell-eb-title {
  color: var(--hc-green);
}

.hc-shell-entry-builder-alert.hc-tone-bear .hc-shell-eb-title {
  color: var(--hc-red);
}

@keyframes hc-eb-alert-pulse {
  0% { filter: brightness(1.35); }
  100% { filter: brightness(1); }
}

.hc-shell-eb-title {
  font-size: var(--hc-fs-xs);
  font-weight: 900;
  color: var(--hc-cyan);
  letter-spacing: 0.14em;
  text-align: center;
  margin-bottom: 4px;
  text-transform: uppercase;
  border-bottom: 1px solid rgba(27, 220, 255, 0.2);
  padding-bottom: 3px;
}

.hc-shell-eb-rows {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.hc-shell-price-scale {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 22px;
  width: 52px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 6px 4px;
  background: linear-gradient(90deg, transparent, rgba(2, 5, 10, 0.85));
  border-left: 1px solid var(--hc-border-dim);
  z-index: 7;
  pointer-events: none;
}

.hc-shell-price-tick {
  font-size: var(--hc-fs-xs);
  color: var(--hc-muted);
  text-align: right;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.hc-shell-time-scale {
  position: absolute;
  left: 0;
  right: 52px;
  bottom: 0;
  height: 22px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 8px;
  background: rgba(2, 5, 10, 0.92);
  border-top: 1px solid var(--hc-border-dim);
  z-index: 7;
  pointer-events: none;
}

.hc-shell-time-tick {
  font-size: var(--hc-fs-xs);
  color: var(--hc-muted);
  font-weight: 700;
  letter-spacing: 0.04em;
}

/* ─── RIGHT TERMINAL ─── */
.hc-shell-terminal {
  display: flex;
  flex-direction: column;
  gap: clamp(4px, 0.4vw, 6px);
  height: 100%;
  min-height: 0;
  /* Terminal itself does not page-scroll — AI Coach body owns vertical scroll. */
  overflow: hidden;
  padding: clamp(4px, 0.4vw, 6px);
  background: linear-gradient(180deg, rgba(6, 14, 24, 0.98), rgba(3, 8, 14, 0.98));
  border: 1px solid var(--hc-border);
  border-radius: var(--hc-radius);
  box-shadow: var(--hc-glow-cyan);
  scrollbar-width: thin;
  scrollbar-color: rgba(27, 220, 255, 0.35) transparent;
}
.hc-shell-terminal > .hc-ws-panel {
  flex: 1 1 auto;
  max-height: none;
  min-height: 0;
  overflow: auto;
  overscroll-behavior: contain;
}

/* ─── CHART AI COACH — always-visible feed under chart / rails ───
   Single owner: #hcWsBelowStack. Child cards (Order Flow, Trade Plan, …)
   stay in normal flow. Only .hc-intel-quickview on that parent is overlay. */
.hc-ws-below-stack,
#hcWsBelowStack {
  display: grid;
  gap: 8px;
  min-width: 0;
  position: static;
  inset: auto;
  z-index: auto;
  transform: none;
  overflow: visible;
  float: none;
  max-height: none;
}
#hcWsBelowStack:not(.hc-intel-quickview) {
  contain: layout paint;
}
.hc-aic-feed-host,
.hc-aic-dock-host,
#hcAiCoachDockHost {
  flex: 0 0 auto;
  min-height: 0;
  position: static;
  inset: auto;
  z-index: auto;
  max-height: none;
  overflow: visible;
  transform: none;
}
/* Child intel panels never self-position — parent owns placement. */
#hcWsBelowStack .hc-ws-below,
#hcWsBelowStack .hc-aic-feed-host,
#hcWsBelowStack .hc-aic-feed,
#hcWsBelowStack .hc-aic-feed-card,
#hcWsBelowStack .hc-aic-feed-talk,
#hcWsBelowStack .hc-aic-talk-grid,
#hcWsBelowStack .hc-aic-feed-grid {
  position: static;
  inset: auto;
  z-index: auto;
  transform: none;
  float: none;
}
#hcWsBelowStack.hc-intel-quickview {
  position: fixed;
  left: 14px;
  right: 14px;
  top: 96px;
  bottom: 62px;
  max-height: none;
  overflow: auto;
  z-index: 2147482999;
  background: rgba(2, 8, 14, 0.985);
  border: 1px solid rgba(27, 220, 255, 0.72);
  border-radius: 10px;
  box-shadow: 0 0 30px rgba(27, 220, 255, 0.28), 0 12px 40px rgba(0, 0, 0, 0.72);
  padding: 4px;
  -webkit-overflow-scrolling: touch;
}
#hcVoiceTestButton,
.hc-voice-test-btn {
  position: fixed;
  right: 14px;
  bottom: 58px;
  z-index: 2147483001;
  max-width: 168px;
  padding: 10px 14px;
  border: 1px solid #22d3ee;
  border-radius: 8px;
  background: rgba(3, 15, 24, 0.94);
  color: #7ee8fa;
  font: 700 12px/1.2 system-ui, -apple-system, sans-serif;
  letter-spacing: 0.08em;
  box-shadow: 0 0 18px rgba(34, 211, 238, 0.22);
  cursor: pointer;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
#hcVoiceTestButton.is-bad,
.hc-voice-test-btn.is-bad {
  border-color: #ff5964;
  color: #ff8b94;
}
#hcUnderChartIntelToggle {
  position: fixed;
  right: 132px;
  bottom: 14px;
  z-index: 2147483000;
  padding: 10px 14px;
  border: 1px solid rgba(27, 220, 255, 0.72);
  border-radius: 8px;
  background: rgba(3, 15, 24, 0.94);
  color: #7ee8fa;
  font: 800 11px/1.2 system-ui, -apple-system, sans-serif;
  letter-spacing: 0.07em;
  box-shadow: 0 0 16px rgba(27, 220, 255, 0.2);
  cursor: pointer;
  touch-action: manipulation;
}

/* Thin RSI intel strip sits in chart-pane flow ABOVE candles — never overlays them. */
.hc-rsi-intel-strip {
  position: relative;
  z-index: 2;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
  width: 100%;
  max-width: 100%;
  margin: 0 0 4px;
  padding: 4px 6px;
  border: 1px solid rgba(27, 220, 255, 0.4);
  border-radius: 7px;
  background: rgba(2, 8, 14, 0.92);
  font: 800 9px/1.15 system-ui, -apple-system, sans-serif;
  letter-spacing: 0.04em;
  color: #dff7ff;
  pointer-events: none;
}
.hc-rsi-intel-strip .hc-ri-chip {
  padding: 3px 6px;
  border: 1px solid rgba(127, 184, 208, 0.25);
  border-radius: 999px;
  background: rgba(7, 19, 30, 0.82);
}
.hc-rsi-intel-strip .hc-ri-reason {
  min-width: 0;
  flex: 1 1 220px;
  overflow: hidden;
  text-overflow: ellipsis;
  color: #9fc8d8;
  font-weight: 650;
}
.hc-rsi-intel-strip.is-ready { border-color: rgba(57, 255, 90, 0.65); }
.hc-rsi-intel-strip.is-absorb { border-color: rgba(255, 210, 46, 0.68); }
.hc-rsi-intel-strip.is-danger { border-color: rgba(255, 77, 77, 0.72); }
.hc-rsi-intel-strip .is-long { color: #39ff5a; }
.hc-rsi-intel-strip .is-short { color: #ff6868; }
.hc-rsi-intel-strip .is-x-bull-extreme { color: #3b82f6; border-color: rgba(59, 130, 246, 0.55); }
.hc-rsi-intel-strip .is-x-bear-extreme { color: #a855f7; border-color: rgba(168, 85, 247, 0.55); }
.hc-rsi-intel-strip .is-warn { color: #ffd22e; }
.hc-rsi-intel-strip .is-ready { color: #39ff5a; }
@media (max-width: 900px) {
  #hcWsBelowStack.hc-intel-quickview {
    left: 8px;
    right: 8px;
    top: 86px;
    bottom: 58px;
  }
  #hcVoiceTestButton,
  .hc-voice-test-btn {
    right: 12px;
    bottom: 54px;
    max-width: 150px;
    padding: 9px 10px;
  }
  #hcUnderChartIntelToggle {
    right: 128px;
    bottom: 14px;
    padding: 9px 10px;
  }
  .hc-rsi-intel-strip {
    gap: 4px;
    padding: 4px 6px;
    font-size: 8px;
  }
}
.hc-aic-feed {
  display: grid;
  gap: 10px;
  padding: 10px 12px 14px;
  border: 1px solid rgba(27, 220, 255, 0.35);
  border-radius: 8px;
  background:
    linear-gradient(180deg, rgba(6, 16, 28, 0.98), rgba(3, 9, 16, 0.98));
  box-shadow: inset 0 0 18px rgba(27, 220, 255, 0.05);
}
.hc-aic-feed.is-stale {
  border-color: rgba(255, 210, 46, 0.45);
}
.hc-aic-feed.hc-stance-xbull {
  border-color: rgba(57, 255, 90, 0.65);
  box-shadow: inset 0 0 22px rgba(57, 255, 90, 0.08);
}
.hc-aic-feed.hc-stance-bull {
  border-color: rgba(57, 255, 90, 0.4);
}
.hc-aic-feed.hc-stance-bear {
  border-color: rgba(255, 77, 77, 0.4);
}
.hc-aic-feed.hc-stance-xbear {
  border-color: rgba(255, 77, 77, 0.7);
  box-shadow: inset 0 0 22px rgba(255, 77, 77, 0.1);
}
.hc-aic-feed.hc-stance-neutral {
  border-color: rgba(255, 210, 46, 0.35);
}
.hc-aic-feed-head {
  display: grid;
  gap: 4px;
}
.hc-aic-feed-kicker {
  font-size: 9px;
  letter-spacing: 0.12em;
  font-weight: 900;
  color: var(--hc-muted);
}
.hc-aic-stance-pill {
  display: inline-flex;
  width: fit-content;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.08em;
  border: 1px solid transparent;
}
.hc-aic-stance-pill.hc-stance-xbull,
.hc-aic-feed-card.hc-stance-xbull h3,
.hc-aic-feed-row.hc-stance-bull b,
.hc-stance-xbull .hc-aic-feed-call {
  color: #39ff5a;
}
.hc-aic-stance-pill.hc-stance-xbull {
  background: rgba(57, 255, 90, 0.14);
  border-color: rgba(57, 255, 90, 0.55);
  text-shadow: 0 0 10px rgba(57, 255, 90, 0.35);
}
.hc-aic-stance-pill.hc-stance-bull,
.hc-aic-feed-card.hc-stance-bull h3,
.hc-stance-bull .hc-aic-feed-call {
  color: #6dff88;
}
.hc-aic-stance-pill.hc-stance-bull {
  background: rgba(57, 255, 90, 0.08);
  border-color: rgba(57, 255, 90, 0.35);
}
.hc-aic-stance-pill.hc-stance-bear,
.hc-aic-feed-card.hc-stance-bear h3,
.hc-aic-feed-row.hc-stance-bear b,
.hc-stance-bear .hc-aic-feed-call {
  color: #ff6b6b;
}
.hc-aic-stance-pill.hc-stance-bear {
  background: rgba(255, 77, 77, 0.08);
  border-color: rgba(255, 77, 77, 0.35);
}
.hc-aic-stance-pill.hc-stance-xbear,
.hc-aic-feed-card.hc-stance-xbear h3,
.hc-stance-xbear .hc-aic-feed-call {
  color: #ff4d4d;
}
.hc-aic-stance-pill.hc-stance-xbear {
  background: rgba(255, 77, 77, 0.16);
  border-color: rgba(255, 77, 77, 0.6);
  text-shadow: 0 0 10px rgba(255, 77, 77, 0.35);
}
.hc-aic-stance-pill.hc-stance-neutral,
.hc-stance-neutral .hc-aic-feed-call {
  color: #ffd22e;
}
.hc-aic-stance-pill.hc-stance-neutral {
  background: rgba(255, 210, 46, 0.08);
  border-color: rgba(255, 210, 46, 0.35);
}
.hc-aic-feed-call {
  font-size: 15px;
  font-weight: 900;
  letter-spacing: 0.04em;
}
.hc-aic-feed-guide {
  font-size: 11px;
  line-height: 1.4;
  color: var(--hc-text);
}
.hc-aic-feed-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}
.hc-aic-feed-card {
  min-width: 0;
  padding: 8px 9px;
  border: 1px solid rgba(29, 64, 92, 0.6);
  border-radius: 7px;
  background: rgba(4, 12, 22, 0.72);
}
.hc-aic-feed-card h3 {
  margin: 0 0 6px;
  font-size: 10px;
  letter-spacing: 0.08em;
  color: var(--hc-cyan);
}
.hc-aic-feed-text {
  margin: 0 0 6px;
  font-size: 11px;
  line-height: 1.4;
  color: var(--hc-text);
}
.hc-aic-feed-muted {
  margin: 6px 0 0;
  font-size: 10px;
  line-height: 1.35;
  color: var(--hc-muted);
}
.hc-aic-feed-row {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  font-size: 10px;
  line-height: 1.45;
  border-top: 1px solid rgba(29, 64, 92, 0.45);
  padding-top: 3px;
  margin-top: 3px;
}
.hc-aic-feed-row span {
  color: var(--hc-muted);
  letter-spacing: 0.04em;
}
.hc-aic-feed-row b {
  color: var(--hc-text);
  text-align: right;
  font-weight: 800;
}
.hc-aic-feed-talk {
  padding: 10px 11px;
  border: 1px solid rgba(29, 64, 92, 0.65);
  border-radius: 7px;
  background: rgba(2, 8, 14, 0.88);
}
.hc-aic-feed-talk h3 {
  margin: 0 0 8px;
  font-size: 10px;
  letter-spacing: 0.08em;
  color: var(--hc-cyan);
}
.hc-aic-talk-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}
.hc-aic-feed-talk .hc-aic-feed-card {
  background: rgba(4, 12, 22, 0.78);
}
/* Legacy pre dump kept hidden — AI talk uses card grid now */
.hc-aic-feed-pre {
  display: none !important;
}
.hc-aic-fab,
.hc-aic-drawer,
.hc-aic-drawer-backdrop,
.hc-aic-drawer-panel,
.hc-ws-ai-coach.hc-aic-dock,
.hc-aic-resize {
  display: none !important;
  position: static !important;
  inset: auto !important;
}
.hc-ws-ai-coach.is-stale {
  border-color: rgba(255, 210, 46, 0.45) !important;
}
.hc-aic-bias {
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.05em;
  line-height: 1.25;
  white-space: nowrap;
}
.hc-aic-bias-section .hc-aic-read {
  font-weight: 700;
}
.hc-aic-bias-reasons,
.hc-aic-headlines {
  margin-top: 4px;
  color: var(--hc-muted);
  font-size: 9px;
  line-height: 1.35;
}
.hc-aic-head {
  display: grid;
  gap: 4px;
  margin-bottom: 4px;
  flex: 0 0 auto;
}
.hc-aic-dock .hc-aic-head {
  margin-bottom: 2px;
  padding: 2px 4px 0;
}
.hc-aic-head-actions {
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
}
.hc-aic-dock-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
  min-height: 0;
}
.hc-aic-col {
  min-width: 0;
  padding: 4px 6px;
  border: 1px solid rgba(29, 64, 92, 0.55);
  border-radius: 6px;
  background: rgba(4, 12, 22, 0.55);
  overflow: auto;
}
.hc-aic-col .hc-aic-h {
  margin-top: 0;
}
.hc-aic-expand-inline {
  width: auto !important;
  margin-top: 0 !important;
  padding: 4px 8px !important;
  font-size: 9px !important;
}
.hc-aic-open-full {
  border: 1px solid rgba(27, 220, 255, 0.45);
  background: rgba(7, 19, 30, 0.95);
  color: var(--hc-cyan);
  font-size: 9px;
  font-weight: 900;
  letter-spacing: 0.06em;
  border-radius: 5px;
  padding: 4px 7px;
  cursor: pointer;
  white-space: nowrap;
}
.hc-aic-open-full:hover {
  border-color: var(--hc-cyan);
  background: rgba(27, 220, 255, 0.1);
}
.hc-aic-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  width: 100%;
  background: transparent;
  border: 0;
  padding: 0;
  cursor: pointer;
  color: inherit;
  text-align: left;
}
.hc-aic-chevron {
  color: var(--hc-cyan);
  font-size: 11px;
}
.hc-aic-call {
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.04em;
  line-height: 1.25;
}
.hc-aic-body {
  overflow-x: hidden;
  overflow-y: auto !important;
  min-height: 0;
  flex: 1 1 auto;
  padding-right: 4px;
  scrollbar-width: thin;
  scrollbar-color: rgba(27, 220, 255, 0.55) rgba(0, 0, 0, 0.2);
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
  touch-action: pan-y;
}
.hc-aic-section {
  margin-top: 6px;
  padding-top: 6px;
  border-top: 1px solid rgba(29, 64, 92, 0.55);
}
.hc-aic-section:first-child {
  margin-top: 0;
  padding-top: 0;
  border-top: 0;
}
.hc-aic-h {
  font-size: 9px;
  letter-spacing: 0.7px;
  font-weight: 900;
  color: var(--hc-cyan);
  margin-bottom: 4px;
}
.hc-aic-read {
  font-size: 10px;
  line-height: 1.4;
  color: var(--hc-text);
  white-space: pre-wrap;
}
.hc-aic-unavailable {
  font-size: 10px;
  line-height: 1.35;
  color: var(--hc-yellow);
  background: rgba(255, 210, 46, 0.08);
  border: 1px solid rgba(255, 210, 46, 0.28);
  border-radius: 6px;
  padding: 6px 7px;
}
.hc-aic-play .hc-ws-kv b {
  max-width: 70%;
  text-align: right;
  word-break: break-word;
}
.hc-aic-expand-btn {
  margin-top: 8px;
  width: 100%;
  border: 1px solid rgba(27, 220, 255, 0.4);
  background: rgba(7, 19, 30, 0.95);
  color: var(--hc-cyan);
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.06em;
  border-radius: 6px;
  padding: 7px 8px;
  cursor: pointer;
}
.hc-aic-dock .hc-aic-body {
  padding: 0 4px 4px;
}
.hc-aic-dock .hc-aic-section {
  margin-top: 0;
  padding-top: 0;
  border-top: 0;
}
.hc-aic-dock .hc-ws-kv {
  font-size: 9px;
}
.hc-aic-dock .hc-aic-read {
  font-size: 9px;
  line-height: 1.3;
}
.hc-aic-expand-btn:hover {
  border-color: var(--hc-cyan);
  background: rgba(27, 220, 255, 0.08);
}
.hc-aic-expanded {
  margin-top: 8px;
  max-height: 240px;
  overflow: auto;
}
.hc-aic-expanded .hc-aic-read {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 9px;
  color: #c9e9f5;
}

.hc-shell-side-panel {
  background: var(--hc-panel);
  border: 1px solid var(--hc-border-dim);
  border-radius: var(--hc-radius);
  padding: clamp(5px, 0.4vw, 7px);
  flex: 0 0 auto;
}

.hc-shell-side-panel.hc-tone-purple,
.hc-shell-side-panel.hc-panel-pressure,
.hc-shell-side-panel.hc-panel-nexus {
  border-color: rgba(169, 68, 255, 0.5);
  box-shadow: inset 0 0 12px rgba(169, 68, 255, 0.08);
}
.hc-shell-side-panel.hc-panel-target,
.hc-shell-side-panel.hc-tone-bull {
  border-color: rgba(57, 255, 90, 0.4);
}
.hc-shell-side-panel.hc-panel-reentry,
.hc-shell-side-panel.hc-tone-warn {
  border-color: rgba(255, 210, 46, 0.4);
}
.hc-shell-side-panel.hc-panel-tower,
.hc-shell-side-panel.hc-tone-cyan {
  border-color: rgba(27, 220, 255, 0.4);
}

.hc-shell-side-title {
  font-size: var(--hc-fs-xs);
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--hc-cyan);
  margin-bottom: 4px;
  padding-bottom: 3px;
  border-bottom: 1px solid rgba(27, 220, 255, 0.18);
}

.hc-panel-pressure .hc-shell-side-title,
.hc-panel-nexus .hc-shell-side-title,
.hc-tone-purple .hc-shell-side-title {
  color: var(--hc-purple);
}
.hc-panel-target .hc-shell-side-title,
.hc-tone-bull .hc-shell-side-title {
  color: var(--hc-green);
}
.hc-panel-reentry .hc-shell-side-title,
.hc-tone-warn .hc-shell-side-title {
  color: var(--hc-yellow);
}

.hc-shell-side-body {
  font-size: var(--hc-fs-sm);
  font-weight: 700;
  line-height: 1.35;
  color: var(--hc-text);
}

.hc-shell-side-detail {
  margin-top: 3px;
  font-size: var(--hc-fs-xs);
  color: var(--hc-muted);
  line-height: 1.3;
  font-weight: 600;
}

.hc-shell-side-rows,
.hc-shell-kv {
  display: flex;
  flex-direction: column;
}

.hc-shell-kv {
  flex-direction: row;
  justify-content: space-between;
  align-items: baseline;
  gap: 6px;
  padding: 2px 0;
  border-bottom: 1px solid rgba(29, 64, 92, 0.28);
  font-size: var(--hc-fs-sm);
}

.hc-shell-kv .k {
  color: var(--hc-muted);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-weight: 700;
  font-size: var(--hc-fs-xs);
}

.hc-shell-kv .v {
  font-weight: 800;
  text-align: right;
  color: var(--hc-text);
  min-width: 0;
}

.hc-tone-bull { color: var(--hc-green) !important; }
.hc-tone-bear { color: var(--hc-red) !important; }
.hc-tone-warn { color: var(--hc-yellow) !important; }
.hc-tone-cyan { color: var(--hc-cyan) !important; }
.hc-tone-purple { color: var(--hc-purple) !important; }
.hc-tone-orange { color: var(--hc-orange) !important; }
.hc-tone-muted { color: var(--hc-muted) !important; }

/* ─── BOTTOM PANELS ─── */
/* Single non-wrapping row: chart height stays primary; overflow scrolls. */
.hc-shell-bottom-panels {
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  align-items: stretch;
  gap: var(--hc-gap);
  flex: 0 0 auto;
  min-height: 0;
  max-height: clamp(96px, 18vh, 160px);
  overflow-x: auto;
  overflow-y: hidden;
  scrollbar-width: thin;
  scrollbar-color: rgba(27, 220, 255, 0.35) transparent;
}

.hc-shell-bottom-panel {
  background: linear-gradient(180deg, rgba(6, 14, 24, 0.98), rgba(3, 8, 14, 0.98));
  border: 1px solid var(--hc-border);
  border-radius: var(--hc-radius);
  padding: clamp(5px, 0.4vw, 7px);
  flex: 1 0 0;
  min-width: 120px;
  max-height: 100%;
  overflow: hidden;
  box-shadow: inset 0 0 12px rgba(0, 0, 0, 0.3);
}

.hc-shell-bp-title {
  font-size: var(--hc-fs-xs);
  font-weight: 900;
  color: var(--hc-cyan);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 4px;
  padding-bottom: 3px;
  border-bottom: 1px solid rgba(27, 220, 255, 0.18);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.hc-shell-bp-row {
  display: flex;
  justify-content: space-between;
  gap: 6px;
  padding: 1px 0;
  font-size: var(--hc-fs-xs);
}

.hc-shell-bp-row .k {
  color: var(--hc-muted);
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.hc-shell-bp-row .v {
  color: var(--hc-text);
  font-weight: 800;
  text-align: right;
  text-transform: uppercase;
}

.hc-shell-bottom-panel[data-key="nexusBurstBottom"],
.hc-shell-bottom-panel[data-key="burstStack"] {
  border-color: rgba(169, 68, 255, 0.45);
}
.hc-shell-bottom-panel[data-key="nexusBurstBottom"] .hc-shell-bp-title,
.hc-shell-bottom-panel[data-key="burstStack"] .hc-shell-bp-title {
  color: var(--hc-purple);
}
.hc-shell-bottom-panel[data-key="riskReward"] {
  border-color: rgba(57, 255, 90, 0.35);
}
.hc-shell-bottom-panel[data-key="signalQuality"],
.hc-shell-bottom-panel[data-key="confidence"] {
  border-color: rgba(255, 210, 46, 0.3);
}
.hc-shell-bottom-panel[data-key="authority"] {
  border-color: rgba(169, 68, 255, 0.4);
}
.hc-shell-bottom-panel[data-key="tradeCall"] {
  border-color: rgba(27, 220, 255, 0.4);
}
.hc-shell-bottom-panel[data-key="nextAction"] {
  border-color: rgba(255, 210, 46, 0.35);
}
.hc-shell-bottom-panel[data-key="marketState"] {
  border-color: rgba(27, 220, 255, 0.5);
}
.hc-shell-bottom-panel[data-key="marketState"] .hc-shell-bp-title {
  color: var(--hc-cyan);
}
.hc-shell-bottom-panel[data-key="memoryMatch"] {
  border-color: rgba(255, 210, 46, 0.4);
}
.hc-shell-bottom-panel[data-key="memoryMatch"] .hc-shell-bp-title {
  color: var(--hc-gold, #ffd22e);
}
.hc-shell-side-panel.hc-panel-trade-terminal {
  border-color: rgba(27, 220, 255, 0.55);
  box-shadow: inset 0 0 16px rgba(27, 220, 255, 0.1);
  order: -1;
}
.hc-shell-side-panel.hc-panel-trade-terminal .hc-shell-side-title {
  color: var(--hc-cyan);
  letter-spacing: 0.14em;
}

.hc-shell-intel-stack {
  display: flex;
  flex-direction: column;
  gap: clamp(4px, 0.4vw, 6px);
  margin-top: 2px;
}

.hc-shell-collapsible .hc-shell-collapse-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  gap: 8px;
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  letter-spacing: inherit;
  text-align: left;
  cursor: pointer;
}
.hc-shell-collapsible .hc-shell-collapse-chevron {
  color: var(--hc-muted);
  font-size: var(--hc-fs-sm);
  line-height: 1;
}
.hc-shell-collapsible.is-collapsed {
  opacity: 0.92;
}
.hc-shell-collapsible.is-collapsed .hc-shell-collapse-body {
  display: none;
}

.hc-shell-side-panel.hc-panel-market-intel {
  border-color: rgba(27, 220, 255, 0.55);
  box-shadow: inset 0 0 14px rgba(27, 220, 255, 0.08);
}
.hc-panel-market-intel .hc-shell-side-title,
.hc-panel-market-intel .hc-shell-collapse-label {
  color: var(--hc-cyan);
}
.hc-shell-bottom-panel[data-key="rsiStack"] {
  border-color: rgba(27, 220, 255, 0.35);
}
.hc-shell-bottom-panel[data-key="readiness"] {
  border-color: rgba(27, 220, 255, 0.3);
}
.hc-shell-bottom-panel[data-key="participation"] {
  border-color: rgba(255, 210, 46, 0.3);
}

.hc-shell-phase-badge {
  position: absolute;
  top: 10px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 8;
  padding: 4px 12px;
  border: 1px solid var(--hc-border);
  border-radius: 2px;
  background: rgba(4, 10, 18, 0.92);
  font-size: var(--hc-fs-xs);
  font-weight: 900;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--hc-cyan);
  pointer-events: none;
}
.hc-shell-phase-badge.hc-tone-bull { color: var(--hc-green); border-color: rgba(57, 255, 90, 0.45); }
.hc-shell-phase-badge.hc-tone-warn { color: var(--hc-yellow); border-color: rgba(255, 210, 46, 0.45); }
.hc-shell-phase-badge.hc-tone-bear { color: var(--hc-red); border-color: rgba(255, 77, 77, 0.45); }
.hc-shell-phase-badge.hc-tone-purple { color: var(--hc-purple); border-color: rgba(169, 68, 255, 0.45); }

.hc-shell-rails-status {
  font-size: clamp(7px, 0.55vw, 9px);
  color: var(--hc-muted);
  margin-top: 2px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.hc-shell-rail-item.is-inactive { opacity: 0.45; }
.hc-shell-rail-item.is-active { opacity: 1; }

/* ─── SCORE STRIP ─── */
.hc-shell-score-strip {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: clamp(3px, 0.35vw, 5px);
  flex: 0 0 auto;
  background: linear-gradient(180deg, rgba(6, 14, 24, 0.98), rgba(3, 8, 14, 0.98));
  border: 1px solid var(--hc-border);
  border-radius: var(--hc-radius);
  padding: clamp(4px, 0.4vw, 6px);
  box-shadow: var(--hc-glow-cyan);
}

.hc-shell-score-item {
  background: var(--hc-panel);
  border: 1px solid var(--hc-border-dim);
  border-radius: 2px;
  padding: 4px 5px;
  min-width: 0;
  text-align: center;
}

.hc-shell-score-item.hc-tone-bull { border-color: rgba(57, 255, 90, 0.4); }
.hc-shell-score-item.hc-tone-warn { border-color: rgba(255, 210, 46, 0.4); }
.hc-shell-score-item.hc-tone-cyan { border-color: rgba(27, 220, 255, 0.4); }
.hc-shell-score-item.hc-tone-purple { border-color: rgba(169, 68, 255, 0.45); }
.hc-shell-score-item.hc-tone-bear { border-color: rgba(255, 77, 77, 0.4); }

.hc-shell-score-lbl {
  font-size: clamp(6px, 0.5vw, 8px);
  color: var(--hc-muted);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-weight: 800;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.hc-shell-score-val {
  margin-top: 2px;
  font-size: var(--hc-fs-sm);
  font-weight: 900;
  color: var(--hc-text);
  line-height: 1.15;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-transform: uppercase;
}

.hc-shell-score-item.hc-tone-bull .hc-shell-score-val { color: var(--hc-green); }
.hc-shell-score-item.hc-tone-warn .hc-shell-score-val { color: var(--hc-yellow); }
.hc-shell-score-item.hc-tone-cyan .hc-shell-score-val { color: var(--hc-cyan); }
.hc-shell-score-item.hc-tone-purple .hc-shell-score-val { color: var(--hc-purple); }
.hc-shell-score-item.hc-tone-bear .hc-shell-score-val { color: var(--hc-red); }

/* ─── RESPONSIVE ─── */
@media (max-width: 1280px) {
  .hc-shell-header {
    grid-template-columns: 1fr;
  }
  .hc-shell-top-cards {
    grid-template-columns: repeat(6, minmax(0, 1fr));
  }
  .hc-shell-main {
    grid-template-columns: minmax(150px, 180px) minmax(0, 1fr) clamp(240px, 22vw, 280px);
  }
  .hc-ws-below {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .hc-shell-status-meta {
    margin-left: 0;
  }
}

@media (max-width: 1100px) {
  .hc-shell-host {
    height: auto;
    max-height: none;
    min-height: 0;
    overflow: visible;
  }
  .hc-shell-root {
    height: auto;
    overflow: visible;
  }
  .hc-shell-main {
    grid-template-columns: 1fr;
  }
  .hc-shell-main.hc-scalp-main {
    grid-template-columns: 1fr;
  }
  .hc-shell-left-rail {
    max-height: 360px;
  }
  .hc-shell-chart-stage {
    min-height: 420px;
    height: 48vh;
  }
  .hc-shell-terminal {
    max-height: min(520px, 55vh);
    height: min(520px, 55vh);
    overflow: hidden;
  }
  .hc-aic-feed-grid,
  .hc-aic-talk-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .hc-shell-bottom-panels {
    max-height: clamp(88px, 16vh, 140px);
    overflow-x: auto;
    overflow-y: hidden;
  }
  .hc-shell-score-strip {
    grid-template-columns: repeat(6, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .hc-aic-feed-grid,
  .hc-aic-talk-grid {
    grid-template-columns: minmax(0, 1fr);
  }
  .hc-shell-top-cards {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .hc-shell-bottom-panels {
    max-height: clamp(80px, 15vh, 130px);
    overflow-x: auto;
    overflow-y: hidden;
  }
  .hc-shell-bottom-panel {
    min-width: 100px;
  }
  .hc-shell-score-strip {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .hc-shell-entry-builder {
    width: min(240px, 70%);
  }
  .hc-shell-controls {
    width: 100%;
  }
  .hc-shell-tf-btn {
    min-width: 40px;
    min-height: 32px;
    padding: 6px 10px;
  }
  .hc-shell-symbol-select {
    min-height: 32px;
    font-size: var(--hc-fs-md);
  }
  .hc-shell-chart-stage {
    min-height: 360px;
    height: 52vh;
  }
  .hc-shell-status-banner {
    font-size: 7px;
    gap: 4px 8px;
  }
}

/* iPad landscape / tablet landscape — keep 3-col chart, never overlay intel. */
@media (min-width: 900px) and (max-width: 1366px) and (orientation: landscape) {
  .hc-shell-host {
    height: calc(100vh - 16px);
    max-height: calc(100vh - 16px);
    overflow-x: hidden;
    overflow-y: auto;
  }
  .hc-shell-root {
    height: auto;
    min-height: 100%;
    grid-template-rows: auto auto auto auto auto auto auto auto auto auto;
  }
  .hc-shell-main {
    grid-template-columns: minmax(150px, 170px) minmax(0, 1fr) clamp(250px, 22vw, 290px);
    height: auto;
    z-index: 0;
  }
  .hc-shell-main.hc-scalp-main {
    grid-template-columns: minmax(140px, 160px) minmax(0, 1fr) minmax(160px, 190px);
    min-height: max(620px, calc(100vh - 140px));
    height: auto;
    max-height: none;
  }
  body.charts-focus .hc-shell-main.hc-scalp-main {
    min-height: max(720px, calc(100vh - 90px));
    height: auto;
  }
  #hcWsBelowStack {
    position: static;
    z-index: auto;
  }
  .hc-shell-card-val {
    font-size: clamp(9px, 0.9vw, 11px);
  }
}

/* Desktop scalp: keep chart dominant — fill viewport before AI scroll */
@media (min-width: 1367px) {
  .hc-shell-main.hc-scalp-main {
    grid-template-columns: minmax(156px, 172px) minmax(0, 1fr) minmax(176px, 210px);
    min-height: max(720px, calc(100vh - 150px));
    height: auto;
  }
  body.charts-focus .hc-shell-main.hc-scalp-main {
    min-height: max(800px, calc(100vh - 90px));
    height: auto;
  }
}

/* ─── LIVE RSI BY TIMEFRAME ─── */
.hc-shell-live-rsi,
.hc-ws-live-rsi-wrap {
  flex: 0 0 auto;
  background: linear-gradient(180deg, rgba(6, 14, 24, 0.98), rgba(3, 8, 14, 0.98));
  border: 1px solid var(--hc-border-dim);
  border-radius: var(--hc-radius);
  padding: 6px 8px 8px;
  min-height: 0;
  overflow-x: auto;
}
.hc-shell-live-rsi-title {
  font-size: var(--hc-fs-xs);
  color: var(--hc-muted);
  letter-spacing: 0.08em;
  margin-bottom: 4px;
  text-transform: uppercase;
}
.hc-shell-rsi-stamp {
  font-size: var(--hc-fs-xs);
  color: var(--hc-text);
  letter-spacing: 0.03em;
  margin: -2px 0 6px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}
.hc-shell-live-rsi-table {
  width: 100%;
  border-collapse: collapse;
  font-variant-numeric: tabular-nums;
  font-size: var(--hc-fs-xs);
}
.hc-shell-live-rsi-table th {
  text-align: left;
  color: var(--hc-muted);
  letter-spacing: 0.06em;
  padding: 3px 4px;
  border-bottom: 1px solid var(--hc-border-dim);
  font-weight: 700;
}
.hc-shell-live-rsi-table td {
  padding: 4px;
  border-bottom: 1px solid rgba(80, 140, 170, 0.12);
  color: var(--hc-text);
  vertical-align: top;
}
.hc-shell-live-rsi-table td b {
  font-size: var(--hc-fs-md);
  font-weight: 700;
}
/* RSI Matrix numeric zone colors — scoped to this table only. */
.hc-shell-live-rsi-table tr.hc-tone-purple td:nth-child(2),
.hc-shell-live-rsi-table tr.hc-tone-purple td:nth-child(2) b,
.hc-shell-live-rsi-table tr.hc-tone-purple td:nth-child(3),
.hc-shell-live-rsi-table tr.hc-tone-purple td:nth-child(3) b {
  color: var(--hc-purple) !important;
  text-shadow: 0 0 7px rgba(169, 68, 255, 0.5);
}
.hc-shell-live-rsi-table tr.hc-tone-red td:nth-child(2),
.hc-shell-live-rsi-table tr.hc-tone-red td:nth-child(2) b,
.hc-shell-live-rsi-table tr.hc-tone-red td:nth-child(3),
.hc-shell-live-rsi-table tr.hc-tone-red td:nth-child(3) b {
  color: var(--hc-red) !important;
}
.hc-shell-live-rsi-table tr.hc-tone-yellow td:nth-child(2),
.hc-shell-live-rsi-table tr.hc-tone-yellow td:nth-child(2) b,
.hc-shell-live-rsi-table tr.hc-tone-yellow td:nth-child(3),
.hc-shell-live-rsi-table tr.hc-tone-yellow td:nth-child(3) b {
  color: var(--hc-yellow) !important;
}
.hc-shell-live-rsi-table tr.hc-tone-green td:nth-child(2),
.hc-shell-live-rsi-table tr.hc-tone-green td:nth-child(2) b,
.hc-shell-live-rsi-table tr.hc-tone-green td:nth-child(3),
.hc-shell-live-rsi-table tr.hc-tone-green td:nth-child(3) b {
  color: var(--hc-green) !important;
}
.hc-shell-live-rsi-table tr.hc-tone-blue td:nth-child(2),
.hc-shell-live-rsi-table tr.hc-tone-blue td:nth-child(2) b,
.hc-shell-live-rsi-table tr.hc-tone-blue td:nth-child(3),
.hc-shell-live-rsi-table tr.hc-tone-blue td:nth-child(3) b {
  color: var(--hc-blue) !important;
  text-shadow: 0 0 7px rgba(61, 126, 255, 0.5);
}
.hc-shell-live-rsi-table tr.hc-tone-muted td:nth-child(2),
.hc-shell-live-rsi-table tr.hc-tone-muted td:nth-child(2) b,
.hc-shell-live-rsi-table tr.hc-tone-muted td:nth-child(3),
.hc-shell-live-rsi-table tr.hc-tone-muted td:nth-child(3) b {
  color: var(--hc-muted) !important;
}
.hc-shell-live-rsi-debug {
  margin-top: 2px;
  font-size: 7px;
  line-height: 1.3;
  color: var(--hc-muted);
  font-weight: 500;
  white-space: normal;
}
.hc-shell-rsi-meta {
  margin-top: 6px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3px 8px;
  font-size: 9px;
  line-height: 1.25;
  color: var(--hc-muted);
}
.hc-shell-rsi-meta span {
  display: block;
  font-size: 8px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  opacity: 0.8;
}
.hc-shell-rsi-meta b {
  color: var(--hc-text);
  font-weight: 650;
  font-size: 10px;
}

/* ─── CHART NEWS FLASH — pops on the live chart, not the clipped page top ─── */
.hc-shell-news-flash-host {
  position: absolute;
  inset: 0;
  z-index: 36;
  pointer-events: none;
  overflow: visible;
}
.hc-shell-news-flash-host[data-has-news="false"] {
  visibility: hidden;
}
.hc-news-chart-flash {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  padding: 14px 16px 0;
  pointer-events: none;
  animation: hcNewsChartPop 0.32s ease-out;
}
.hc-news-chart-flash.is-flashing::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(
    ellipse at 50% 0%,
    rgba(255, 255, 255, 0.07),
    transparent 55%
  );
  pointer-events: none;
}
@keyframes hcNewsChartPop {
  0% { opacity: 0; transform: translateY(-12px) scale(0.98); }
  100% { opacity: 1; transform: translateY(0) scale(1); }
}
.hc-news-banner {
  position: relative;
  flex: 0 0 auto;
  width: min(920px, 94%);
  border: 2px solid var(--hc-border);
  border-radius: var(--hc-radius);
  background: linear-gradient(180deg, rgba(12, 22, 36, 0.97), rgba(6, 12, 20, 0.96));
  padding: 10px 14px;
  margin: 0;
  overflow: hidden;
  z-index: 2;
  pointer-events: auto;
  backdrop-filter: blur(4px);
}
.hc-news-banner.hc-tone-green,
.hc-news-banner.is-bull { border-color: rgba(57, 255, 90, 0.75); box-shadow: var(--hc-glow-green); background: linear-gradient(180deg, rgba(8, 36, 18, 0.98), rgba(4, 14, 10, 0.98)); }
.hc-news-banner.hc-tone-red,
.hc-news-banner.is-bear { border-color: rgba(255, 77, 77, 0.75); box-shadow: var(--hc-glow-red); background: linear-gradient(180deg, rgba(40, 10, 14, 0.98), rgba(14, 4, 8, 0.98)); }
.hc-news-banner.hc-tone-yellow,
.hc-news-banner.hc-tone-warn,
.hc-news-banner.is-neutral { border-color: rgba(255, 210, 46, 0.7); box-shadow: 0 0 18px rgba(255, 210, 46, 0.25); }
.hc-news-banner.hc-tone-purple { border-color: rgba(169, 68, 255, 0.55); box-shadow: var(--hc-glow-purple); }
.hc-news-banner.hc-tone-blue { border-color: rgba(61, 126, 255, 0.55); }
.hc-news-banner-flash {
  animation: hcNewsFlash 0.55s ease-in-out 0s 10;
}
@keyframes hcNewsFlash {
  0%, 100% { opacity: 1; filter: brightness(1); transform: translateY(0); }
  50% { opacity: 0.82; filter: brightness(1.45); transform: translateY(-1px); }
}
.hc-news-flash-storm {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
  z-index: 1;
}
.hc-news-flash-bar {
  position: absolute;
  left: -35%;
  height: 4px;
  width: 55%;
  border-radius: 2px;
  opacity: 0;
  animation: hcNewsStormSweep 1.05s ease-out forwards;
}
.hc-news-flash-storm.hc-tone-green .hc-news-flash-bar,
.hc-news-flash-storm.is-bull .hc-news-flash-bar {
  background: linear-gradient(90deg, transparent, rgba(57, 255, 90, 0.95), transparent);
  box-shadow: 0 0 10px rgba(57, 255, 90, 0.8);
}
.hc-news-flash-storm.hc-tone-red .hc-news-flash-bar,
.hc-news-flash-storm.is-bear .hc-news-flash-bar {
  background: linear-gradient(90deg, transparent, rgba(255, 77, 77, 0.95), transparent);
  box-shadow: 0 0 10px rgba(255, 77, 77, 0.8);
}
.hc-news-flash-storm.hc-tone-yellow .hc-news-flash-bar,
.hc-news-flash-storm.is-neutral .hc-news-flash-bar {
  background: linear-gradient(90deg, transparent, rgba(255, 210, 46, 0.95), transparent);
  box-shadow: 0 0 10px rgba(255, 210, 46, 0.75);
}
@keyframes hcNewsStormSweep {
  0% { opacity: 0; transform: translateX(0); }
  12% { opacity: 1; }
  100% { opacity: 0; transform: translateX(260%); }
}
.hc-news-banner-main {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  min-width: 0;
}
.hc-news-banner-tag {
  font-size: 11px;
  letter-spacing: 0.14em;
  font-weight: 800;
  color: var(--hc-yellow);
  text-transform: uppercase;
}
.hc-news-banner-bias {
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.hc-news-banner.hc-tone-green .hc-news-banner-bias,
.hc-news-banner.is-bull .hc-news-banner-bias { color: var(--hc-green); }
.hc-news-banner.hc-tone-red .hc-news-banner-bias,
.hc-news-banner.is-bear .hc-news-banner-bias { color: var(--hc-red); }
.hc-news-banner.hc-tone-yellow .hc-news-banner-bias,
.hc-news-banner.is-neutral .hc-news-banner-bias { color: var(--hc-yellow); }
.hc-news-banner-headline {
  flex: 1 1 220px;
  font-size: 15px;
  font-weight: 700;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.hc-news-banner-meta {
  font-size: var(--hc-fs-xs);
  color: var(--hc-muted);
}
.hc-news-banner-queue {
  font-size: var(--hc-fs-xs);
  color: var(--hc-cyan);
  letter-spacing: 0.06em;
}
.hc-news-banner-ack {
  font-size: var(--hc-fs-xs);
  letter-spacing: 0.08em;
  background: rgba(255, 210, 46, 0.12);
  border: 1px solid rgba(255, 210, 46, 0.45);
  color: var(--hc-yellow);
  border-radius: var(--hc-radius);
  padding: 2px 8px;
  cursor: pointer;
}
.hc-news-banner-econ {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 4px;
  font-size: var(--hc-fs-xs);
  color: var(--hc-muted);
}
.hc-news-econ-event { color: var(--hc-cyan); font-weight: 700; letter-spacing: 0.06em; }
.hc-news-econ-interp { color: var(--hc-yellow); font-weight: 600; }

.hc-econ-panel {
  flex: 0 0 auto;
  border: 1px solid var(--hc-border-dim);
  border-radius: var(--hc-radius);
  background: rgba(6, 14, 24, 0.95);
  padding: 5px 8px;
}
.hc-econ-title {
  font-size: var(--hc-fs-xs);
  letter-spacing: 0.1em;
  color: var(--hc-cyan);
  font-weight: 700;
  margin-bottom: 3px;
}
.hc-econ-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 4px;
}
.hc-econ-cell .k {
  display: block;
  font-size: 7px;
  color: var(--hc-muted);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}
.hc-econ-cell .v {
  font-size: var(--hc-fs-md);
  font-weight: 700;
}
.hc-econ-interp {
  margin-top: 3px;
  font-size: var(--hc-fs-xs);
  color: var(--hc-yellow);
  letter-spacing: 0.06em;
  font-weight: 600;
}

.hc-pressure-confirm {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  font-size: var(--hc-fs-xs);
  letter-spacing: 0.05em;
  padding: 3px 8px;
  border: 1px solid var(--hc-border-dim);
  border-radius: var(--hc-radius);
  background: rgba(5, 12, 20, 0.9);
}
.hc-pc-label { font-weight: 700; color: var(--hc-cyan); }
.hc-pressure-confirm.hc-tone-green .hc-pc-label { color: var(--hc-green); }
.hc-pressure-confirm.hc-tone-yellow .hc-pc-label { color: var(--hc-yellow); }
.hc-pc-item { color: var(--hc-muted); }

.hc-tone-green { color: var(--hc-green) !important; }
.hc-tone-red { color: var(--hc-red) !important; }
.hc-tone-yellow { color: var(--hc-yellow) !important; }
.hc-tone-blue { color: var(--hc-blue) !important; }

/* Compact chart badges — command + lifecycle only (no raw tables) */
.hc-shell-chart-badges {
  position: absolute;
  top: 8px;
  left: 8px;
  z-index: 6;
  display: flex;
  gap: 6px;
  pointer-events: none;
}
.hc-shell-badge {
  font-size: var(--hc-fs-xs);
  letter-spacing: 0.06em;
  padding: 2px 7px;
  border-radius: var(--hc-radius);
  border: 1px solid var(--hc-border-dim);
  background: rgba(2, 8, 14, 0.82);
  color: var(--hc-text);
}
.hc-shell-badge-command.hc-tone-bull {
  border-color: rgba(57, 255, 90, 0.45);
  color: var(--hc-green);
}
.hc-shell-badge-command.hc-tone-bear {
  border-color: rgba(255, 77, 77, 0.45);
  color: var(--hc-red);
}
.hc-shell-badge-command.hc-tone-warn {
  border-color: rgba(255, 210, 46, 0.45);
  color: var(--hc-yellow);
}
.hc-shell-badge-life {
  color: var(--hc-cyan);
  border-color: rgba(27, 220, 255, 0.35);
}

.hc-shell-shadow-badge {
  position: absolute;
  top: 8px;
  left: 10px;
  z-index: 7;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
  max-width: min(280px, calc(50% - 24px));
  padding: 5px 8px 6px;
  border-radius: 5px;
  pointer-events: none;
  background: rgba(4, 10, 18, 0.88);
  border: 1px solid rgba(251, 191, 36, 0.45);
  color: #fbbf24;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.35);
}
.hc-shell-shadow-name {
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.08em;
  line-height: 1.2;
  color: #e8eef7;
  text-transform: uppercase;
}
.hc-shell-shadow-badge-main {
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.08em;
  line-height: 1.25;
}
.hc-shell-shadow-meta {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.06em;
  color: #9ec5d8;
}
