/* Waypoint Nautical Experience */

#launchOverlay[hidden] {
  display: none !important;
  pointer-events: none !important;
  visibility: hidden !important;
  opacity: 0 !important;
}

#launchOverlay:not([hidden]) {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  background: var(--wtc-navy-deep);
  overflow: hidden;
}

.launch-skip-btn {
  position: relative;
  z-index: 3;
  margin-top: 28px;
  padding: 10px 20px;
  border: 1px solid var(--gold);
  border-radius: 999px;
  background: rgba(10, 25, 33, 0.7);
  color: var(--gold-highlight);
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  cursor: pointer;
}

.launch-skip-btn:hover {
  background: var(--gold-dim);
}

.module-error {
  color: #f0a060;
  font-family: var(--font-display);
  font-size: 0.85rem;
  letter-spacing: 0.06em;
  margin: 0 0 6px;
}

.module-error-detail {
  font-size: 0.75rem;
}

.analysis-warning-card {
  margin-bottom: 12px;
  padding: 10px 12px;
  border: 1px solid rgba(240, 160, 96, 0.45);
  border-radius: 8px;
  background: rgba(240, 160, 96, 0.08);
  color: #f0c090;
  font-size: 0.82rem;
}

.command-deck-layout.deck-ready {
  visibility: visible;
  opacity: 1;
  pointer-events: auto;
}

.launch-ocean-light {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 55% 40% at 50% 75%, rgba(197, 160, 89, 0.08), transparent 70%),
    radial-gradient(ellipse 80% 50% at 50% 0%, rgba(19, 35, 55, 0.6), transparent);
  animation: oceanDrift 4s ease-in-out infinite alternate;
}

@keyframes oceanDrift {
  from { opacity: 0.4; transform: translateY(0); }
  to { opacity: 0.7; transform: translateY(-8px); }
}

.brand-lockup--launch {
  opacity: 0;
  animation: emblemResolve 1.2s ease forwards 0.3s;
  position: relative;
  z-index: 2;
}

.launch-gold-line {
  width: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold-highlight), var(--gold), transparent);
  margin: 24px 0;
  animation: lineSweep 0.8s ease forwards 1s;
  position: relative;
  z-index: 2;
}

@keyframes emblemResolve {
  from { opacity: 0; transform: scale(0.92); }
  to { opacity: 1; transform: scale(1); }
}

@keyframes lineSweep {
  to { width: min(400px, 70vw); }
}

.launch-title {
  font-family: var(--font-display);
  font-size: 1.6rem;
  letter-spacing: 0.2em;
  color: var(--gold-highlight);
  opacity: 0;
  animation: fadeUp 0.6s ease forwards 1.4s;
  position: relative;
  z-index: 2;
}

.launch-tagline {
  font-size: 0.85rem;
  color: var(--text-muted);
  letter-spacing: 0.12em;
  margin-top: 8px;
  opacity: 0;
  animation: fadeUp 0.6s ease forwards 1.8s;
  position: relative;
  z-index: 2;
}

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

.launch-fade-out {
  animation: launchOut 0.5s ease forwards;
}

@keyframes launchOut {
  to { opacity: 0; pointer-events: none; }
}

@media (prefers-reduced-motion: reduce) {
  .launch-ocean-light, .brand-lockup--launch, .launch-gold-line, .launch-title, .launch-tagline {
    animation: none !important;
    opacity: 1 !important;
  }
  .launch-gold-line { width: min(400px, 70vw); }
}

/* Persistent deck shell — avatar + instrument rail stay mounted across views */
.deck-persistent-shell {
  display: grid;
  grid-template-columns: minmax(260px, 0.85fr) minmax(360px, 1.4fr) minmax(280px, 0.95fr);
  grid-template-rows: 1fr auto;
  gap: var(--shell-gap, 16px);
  padding: var(--shell-pad-y, 16px) var(--shell-pad-x, 20px) calc(var(--shell-pad-y, 16px) + 8px);
  width: 100%;
  max-width: var(--shell-max, 1680px);
  margin: 0 auto;
  align-items: start;
  box-sizing: border-box;
}

.deck-workspace {
  min-height: 420px;
}

.deck-bottom {
  grid-column: 1 / -1;
  display: grid;
  gap: 16px;
}

.panel-avatar {
  position: relative;
  top: auto;
  z-index: 1;
  align-self: start;
  max-height: calc(100vh - 96px);
  overflow-y: auto;
  overflow-x: hidden;
  scrollbar-gutter: stable;
}

.trading-hub-widget {
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid var(--border);
}

body:not(.helm-mode):not(.trade-log-mode) #tradingHubWidget {
  display: none !important;
}

.hub-widget-stats {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
  margin-bottom: 10px;
}

.hub-widget-stat {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
  padding: 8px 10px;
  border: 1px solid var(--border);
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.18);
}

.hub-widget-stat .label {
  font-size: 0.62rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.hub-widget-stat strong {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--gold-soft);
}

.hub-widget-stat strong.pnl-pos { color: var(--green); }
.hub-widget-stat strong.pnl-neg { color: var(--red); }

.hub-widget-position {
  font-size: 0.78rem;
  margin: 0 0 10px;
  line-height: 1.4;
}

.hub-widget-actions {
  margin: 8px 0;
  gap: 6px;
}

.hub-widget-actions .btn {
  flex: 1 1 auto;
  min-width: 0;
}

.trading-hub-widget .btn-block {
  width: 100%;
}

.avatar-error {
  color: #f0a060;
  font-size: 0.78rem;
  margin: 8px 0;
}

.btn-retry-video {
  margin-top: 8px;
}

.empty-state {
  font-family: var(--font-display);
  font-size: 0.95rem;
  letter-spacing: 0.06em;
  color: var(--gold-soft);
  margin: 0 0 6px;
}

.zone-input-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin: 10px 0;
}

.zone-input-grid .full-width {
  grid-column: 1 / -1;
}

.briefing-events-panel {
  margin: 16px 0;
  padding: 16px;
}

body.legacy-mode .panel-rail {
  display: none;
}

body.legacy-mode .deck-persistent-shell {
  grid-template-columns: minmax(260px, 0.85fr) 1fr;
}

@media (max-width: 820px) {
  .deck-persistent-shell {
    grid-template-columns: 1fr;
  }
  .panel-avatar {
    max-height: none;
    overflow-y: visible;
  }
}

.bloomberg-toggle-on {
  border-color: var(--amber);
  color: var(--gold-soft);
  background: rgba(212, 162, 76, 0.15);
}

#bloombergToggleHeaderBtn {
  flex-shrink: 0;
  white-space: nowrap;
}

.desk-header-meta .desk-status-cluster {
  min-width: 0;
  flex-shrink: 1;
}

body.waypoint-no-bloomberg .bloomberg-toggle,
body.waypoint-no-bloomberg #bloombergDock {
  display: none !important;
}

.bloomberg-dock {
  position: fixed;
  left: 0;
  bottom: 0;
  z-index: 180;
  width: 200px;
  border: 1px solid var(--border-strong);
  border-radius: 0 12px 0 0;
  background: rgba(7, 16, 24, 0.96);
  box-shadow: var(--shadow);
  overflow: hidden;
  transition: width 0.22s ease;
}

.bloomberg-dock[hidden] {
  display: none !important;
}

.bloomberg-dock:not([hidden]) {
  display: flex;
  flex-direction: column;
}

.bloomberg-dock.bloomberg-dock-scale-1 { width: 200px; }
.bloomberg-dock.bloomberg-dock-scale-2 { width: 360px; }
.bloomberg-dock.bloomberg-dock-scale-3 { width: 520px; }
.bloomberg-dock.bloomberg-dock-scale-4 { width: 680px; }

.bloomberg-dock .bloomberg-scale-btn.is-active {
  color: var(--gold-soft);
  border-color: rgba(201, 162, 39, 0.65);
  background: rgba(201, 162, 39, 0.16);
}

.bloomberg-stream-status {
  position: absolute;
  inset: auto 4px 4px 4px;
  z-index: 3;
  padding: 4px 6px;
  font-size: 0.55rem;
  line-height: 1.25;
  color: #f0e6c8;
  background: rgba(0, 0, 0, 0.72);
  border-radius: 4px;
  pointer-events: none;
}

.bloomberg-dock.bloomberg-dock-expanded {
  width: 360px;
}

.bloomberg-dock.bloomberg-dock-scale-2.bloomberg-dock-expanded,
.bloomberg-dock.bloomberg-dock-scale-2 {
  width: 360px;
}

.bloomberg-dock-header {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 4px;
  padding: 4px 6px;
  border-bottom: 1px solid var(--border);
  background: rgba(0, 0, 0, 0.25);
}

.bloomberg-dock-title {
  display: none;
  font-size: 0.58rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gold-soft);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-right: auto;
}

.bloomberg-dock-actions {
  display: flex;
  gap: 3px;
  flex-shrink: 0;
  flex-wrap: wrap;
  justify-content: flex-end;
  max-width: 100%;
}

.bloomberg-dock-actions .btn-sm {
  padding: 2px 5px;
  font-size: 0.62rem;
  min-height: 0;
  line-height: 1.2;
}

.bloomberg-video-wrap {
  position: relative;
  width: 100%;
  flex: 0 0 auto;
  aspect-ratio: 16 / 9;
  height: auto;
  min-height: calc((var(--waypoint-bloomberg-dock-width, 200px) * 9) / 16);
  background: #000;
}

.bloomberg-player-host,
.bloomberg-player-mount,
.bloomberg-video-wrap iframe,
.bloomberg-player-host iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

.bloomberg-player-host {
  display: block;
}

.bloomberg-dock.bloomberg-audio-only .bloomberg-video-wrap {
  display: none;
}

.bloomberg-dock.bloomberg-dock-scale-2 .bloomberg-dock-title,
.bloomberg-dock.bloomberg-dock-scale-3 .bloomberg-dock-title,
.bloomberg-dock.bloomberg-dock-scale-4 .bloomberg-dock-title,
.bloomberg-dock.bloomberg-dock-expanded .bloomberg-dock-title {
  display: block;
  font-size: 0.72rem;
  letter-spacing: 0.14em;
}

.bloomberg-dock.bloomberg-dock-scale-2 .bloomberg-dock-header,
.bloomberg-dock.bloomberg-dock-scale-3 .bloomberg-dock-header,
.bloomberg-dock.bloomberg-dock-scale-4 .bloomberg-dock-header,
.bloomberg-dock.bloomberg-dock-expanded .bloomberg-dock-header {
  justify-content: space-between;
  gap: 8px;
  padding: 8px 10px;
}

.bloomberg-dock.bloomberg-dock-scale-2 .bloomberg-dock-actions .btn-sm,
.bloomberg-dock.bloomberg-dock-scale-3 .bloomberg-dock-actions .btn-sm,
.bloomberg-dock.bloomberg-dock-scale-4 .bloomberg-dock-actions .btn-sm,
.bloomberg-dock.bloomberg-dock-expanded .bloomberg-dock-actions .btn-sm {
  padding: 4px 10px;
  font-size: 0.75rem;
}

@media (max-width: 720px) {
  .bloomberg-dock {
    width: min(188px, 52vw);
  }

  .bloomberg-dock.bloomberg-dock-expanded {
    width: min(320px, 92vw);
  }
}

/* Command deck layout */
.command-deck-layout {
  display: grid;
  grid-template-columns: var(--nav-rail-w, 80px) 1fr;
  gap: 0;
  min-height: calc(100vh - 80px);
}

.nav-rail {
  background: linear-gradient(180deg, rgba(12, 28, 38, 0.98) 0%, rgba(8, 18, 28, 0.99) 100%);
  border-right: 1px solid rgba(201, 162, 39, 0.12);
  padding: 14px 10px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  align-items: center;
  min-height: 100vh;
  box-shadow: inset -1px 0 0 rgba(255, 255, 255, 0.04);
}

.nav-rail-enhanced .nav-rail-emblem {
  --brand-emblem-size: 36px;
}

.nav-rail-brand {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 4px;
  text-decoration: none;
  padding: 6px;
  border-radius: 14px;
  transition: background 0.2s, transform 0.18s ease, box-shadow 0.2s;
}

.nav-rail-brand:hover {
  background: var(--gold-dim);
  transform: translateY(-1px);
}

.nav-rail-emblem {
  --brand-emblem-size: 32px;
  opacity: 0.92;
}

.nav-rail-btn {
  width: 56px;
  min-height: 56px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.02);
  color: var(--text-muted);
  font-size: 0.65rem;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  position: relative;
  overflow: hidden;
  transition:
    border-color 0.22s ease,
    color 0.22s ease,
    background 0.22s ease,
    transform 0.16s ease,
    box-shadow 0.22s ease;
}

.nav-rail-btn[hidden] {
  display: none !important;
}

.nav-rail-btn::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: radial-gradient(circle at 50% 35%, rgba(201, 162, 39, 0.22), transparent 62%);
  opacity: 0;
  transition: opacity 0.22s ease;
  pointer-events: none;
}

.nav-rail-btn:hover,
.nav-rail-btn.active {
  border-color: rgba(201, 162, 39, 0.45);
  color: var(--gold-soft);
  background: rgba(201, 162, 39, 0.1);
  transform: translateY(-2px);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.35), 0 0 0 1px rgba(201, 162, 39, 0.08);
}

.nav-rail-btn:hover::before,
.nav-rail-btn.active::before {
  opacity: 1;
}

.nav-rail-btn.nav-rail-pressed {
  transform: scale(0.9) translateY(0);
  box-shadow: inset 0 2px 10px rgba(0, 0, 0, 0.45);
  transition: transform 0.1s ease, box-shadow 0.1s ease;
}

.nav-rail-btn.nav-rail-pressed::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: rgba(201, 162, 39, 0.18);
  animation: nav-rail-flash 0.28s ease-out;
  pointer-events: none;
}

@keyframes nav-rail-flash {
  from { opacity: 0.85; transform: scale(0.85); }
  to { opacity: 0; transform: scale(1.15); }
}

@keyframes nav-icon-pop {
  0% { transform: scale(1); }
  35% { transform: scale(1.24) rotate(-5deg); }
  65% { transform: scale(0.94) rotate(2deg); }
  100% { transform: scale(1) rotate(0deg); }
}

.nav-rail-icon-pop {
  animation: nav-icon-pop 0.34s cubic-bezier(0.34, 1.45, 0.64, 1);
}

.nav-rail-link {
  text-decoration: none;
  font-size: 1rem;
}

.nav-rail-svg,
.nav-rail-art {
  width: 28px;
  height: 28px;
  display: block;
  flex-shrink: 0;
  overflow: visible;
  color: #c5a059;
  transition: transform 0.22s cubic-bezier(0.34, 1.45, 0.64, 1), filter 0.22s ease;
  filter: drop-shadow(0 2px 5px rgba(0, 0, 0, 0.4));
}

.nav-rail-art:not(.nav-rail-pete-art):not(.nav-rail-pete-photo) {
  min-width: 28px;
  min-height: 28px;
}

.nav-rail-btn-enhanced:hover .nav-rail-art:not(.nav-rail-pete-art),
.nav-rail-btn-enhanced.active .nav-rail-art:not(.nav-rail-pete-art) {
  transform: scale(1.14);
  filter: drop-shadow(0 3px 8px rgba(0, 0, 0, 0.45)) drop-shadow(0 0 6px rgba(197, 160, 89, 0.35));
}

.nav-rail-btn-icon {
  padding-top: 4px;
  font-size: 0;
  line-height: 0;
}

.nav-rail-spacer {
  flex: 1 1 auto;
  min-height: 8px;
}

@media (prefers-reduced-motion: reduce) {
  .nav-rail-btn,
  .nav-rail-brand,
  .nav-rail-icon,
  .nav-rail-art {
    transition: none !important;
    animation: none !important;
  }
  .nav-rail-btn-pirate,
  .nav-rail-btn-pirate .nav-rail-pete-art {
    animation: none !important;
  }
  .nav-rail-btn.nav-rail-pressed::after {
    animation: none !important;
  }
  .nav-rail-icon-pop {
    animation: none !important;
  }
  .nav-rail-btn-admin[data-admin-nav-link]:not([hidden]) {
    animation: none !important;
  }
}

.deck-view { min-width: 0; }
.deck-view[hidden] {
  display: none !important;
}

/* Morning briefing */
.briefing-shell {
  max-width: 720px;
  margin: 0 auto;
  padding: 24px;
}

.briefing-progress {
  display: flex;
  justify-content: space-between;
  margin-bottom: 32px;
  position: relative;
}

.briefing-progress::before {
  content: "";
  position: absolute;
  top: 8px;
  left: 5%;
  right: 5%;
  height: 1px;
  background: var(--border);
  z-index: 0;
}

.nav-point {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  z-index: 1;
  flex: 1;
}

.nav-point-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: 1px solid var(--border-strong);
  background: var(--bg-deep);
}

.nav-point.active .nav-point-dot {
  background: var(--gold);
  box-shadow: 0 0 12px rgba(201, 169, 98, 0.4);
}

.nav-point.done .nav-point-dot {
  background: var(--gold-dim);
}

.nav-point-label {
  font-size: 0.58rem;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  text-align: center;
}

.nav-point.active .nav-point-label { color: var(--gold-soft); }

.zone-review {
  margin: 20px 0;
  padding: 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: rgba(12, 21, 36, 0.6);
}

.zone-compare {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin: 12px 0;
}

.evidence-list {
  list-style: none;
  padding: 0;
  margin: 12px 0;
  font-size: 0.85rem;
}

.evidence-support { color: var(--green); }
.evidence-caution { color: var(--amber); }

.nav-plan-title {
  font-family: var(--font-display);
  font-size: 1.1rem;
  color: var(--gold-soft);
  margin-bottom: 12px;
}

.nav-zone-block {
  margin: 12px 0;
  padding: 12px 0;
  border-bottom: 1px solid rgba(255,255,255,0.05);
}

.course-plotted-banner {
  text-align: center;
  padding: 12px;
  color: var(--gold);
  font-family: var(--font-display);
  letter-spacing: 0.15em;
  animation: fadeUp 0.5s ease;
}

.course-plotted-banner.hidden { display: none; }

/* Thesis / Live Confidence analog gauges */
.confidence-compass-pair {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  align-items: start;
}

/* Pete Watch OFF: the frozen last-analysis dial leads. */
.confidence-compass-pair[data-primary="analysis"] #thesisCompass .confidence-gauge { --gauge-size: 128px; }
.confidence-compass-pair[data-primary="analysis"] #liveConfidenceCompass .confidence-gauge { --gauge-size: 92px; }

/* Pete Watch ON: live confidence becomes the predominant dial. */
.confidence-compass-pair[data-primary="live"] {
  grid-template-columns: minmax(0, 1fr);
}

.confidence-compass-pair[data-primary="live"] #liveConfidenceCompass { order: 1; }
.confidence-compass-pair[data-primary="live"] #thesisCompass { order: 2; }
.confidence-compass-pair[data-primary="live"] #liveConfidenceCompass .confidence-gauge { --gauge-size: 172px; }
.confidence-compass-pair[data-primary="live"] #thesisCompass .confidence-gauge { --gauge-size: 74px; }
.confidence-compass-pair[data-primary="live"] #thesisCompass .compass-factors { display: none; }

.confidence-compass {
  min-width: 0;
  padding: 6px;
  border: 1px solid rgba(201, 169, 98, 0.18);
  border-radius: 10px;
  background: rgba(4, 10, 17, 0.42);
}

.confidence-gauge { --gauge-size: 118px; }

.gauge-dial {
  position: relative;
  width: var(--gauge-size);
  height: var(--gauge-size);
  margin: 8px auto 2px;
}

.gauge-face {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: visible;
}

.gauge-plate {
  fill: rgba(4, 10, 17, 0.55);
  stroke: rgba(201, 169, 98, 0.16);
  stroke-width: 1;
}

.gauge-band {
  fill: none;
  stroke-width: 13;
  transition: stroke 0.4s ease, stroke-width 0.4s ease;
}

.gauge-band[data-band="neutral"] { stroke: rgba(196, 185, 156, 0.26); }

/* LONG side: green dimmer turns up T3 -> T2 -> T1 */
.gauge-band[data-band="long-t3"] { stroke: rgba(58, 150, 96, 0.30); }
.gauge-band[data-band="long-t2"] { stroke: rgba(62, 198, 122, 0.58); }
.gauge-band[data-band="long-t1"] { stroke: rgba(78, 248, 152, 0.92); }

/* SHORT side: red dimmer turns up T3 -> T2 -> T1 */
.gauge-band[data-band="short-t3"] { stroke: rgba(168, 56, 70, 0.30); }
.gauge-band[data-band="short-t2"] { stroke: rgba(220, 62, 84, 0.58); }
.gauge-band[data-band="short-t1"] { stroke: rgba(255, 74, 98, 0.92); }

.gauge-band[data-active="true"] { stroke-width: 16; }

.gauge-band[data-band^="long"][data-active="true"] {
  filter: drop-shadow(0 0 6px rgba(78, 248, 152, 0.55));
}

.gauge-band[data-band^="short"][data-active="true"] {
  filter: drop-shadow(0 0 6px rgba(255, 74, 98, 0.55));
}

.gauge-tier-label {
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.06em;
  fill: rgba(224, 213, 180, 0.6);
}

.gauge-zone-label {
  position: absolute;
  font-size: calc(var(--gauge-size) * 0.072);
  letter-spacing: 0.12em;
  color: rgba(224, 213, 180, 0.62);
  pointer-events: none;
}

.gauge-zone-label.is-neutral {
  top: 9%;
  left: 50%;
  transform: translateX(-50%);
}

.gauge-zone-label.is-short {
  left: 0;
  bottom: 0;
  color: rgba(255, 120, 138, 0.78);
}

.gauge-zone-label.is-long {
  right: 0;
  bottom: 0;
  color: rgba(110, 224, 160, 0.82);
}

.gauge-needle {
  position: absolute;
  left: 50%;
  bottom: 50%;
  width: 2px;
  height: 37%;
  border-radius: 2px;
  transform-origin: 50% 100%;
  transform: translateX(-50%) rotate(var(--gauge-angle, 0deg));
  transition: transform 900ms cubic-bezier(0.22, 1, 0.36, 1);
  background: linear-gradient(to top, rgba(201, 169, 98, 0.12), var(--gold));
}

.confidence-gauge[data-direction="long"] .gauge-needle {
  background: linear-gradient(to top, rgba(62, 198, 122, 0.12), #5df0a0);
}

.confidence-gauge[data-direction="short"] .gauge-needle {
  background: linear-gradient(to top, rgba(220, 62, 84, 0.12), #ff6b82);
}

.gauge-hub {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 9px;
  height: 9px;
  margin: -4.5px 0 0 -4.5px;
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 8px rgba(201, 169, 98, 0.45);
}

.gauge-value {
  margin: 0;
  text-align: center;
  font-size: 0.72rem;
  font-variant-numeric: tabular-nums;
  color: var(--gold-soft);
}

#liveConfidenceCompass.is-blue-opportunity .confidence-compass {
  border-color: rgba(55, 155, 255, 0.75);
  box-shadow: 0 0 16px rgba(55, 155, 255, 0.32);
}

.live-compass-delta {
  margin: 3px 0;
  font-size: 0.62rem;
  text-align: center;
}

.live-compass-delta.is-up { color: #6ed6a0; }
.live-compass-delta.is-down { color: #f0a6bd; }

.live-compass-reason {
  font-size: 0.6rem;
  line-height: 1.3;
  color: var(--text-muted);
}

.live-compass-reason ul {
  margin: 3px 0 0;
  padding-left: 14px;
}

.compass-label {
  text-align: center;
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  color: var(--gold);
  margin: 0;
}

.compass-strength {
  text-align: center;
  font-family: var(--font-display);
  font-size: 0.82rem;
  letter-spacing: 0.04em;
  margin: 2px 0 8px;
}

.compass-meta {
  font-size: 0.72rem;
  margin: 2px 0 4px;
  color: var(--gold-soft);
}

.compass-time {
  font-size: 0.7rem;
  margin: 0 0 6px;
  color: var(--text-muted);
}

.compass-news {
  color: var(--gold-bright, #e8c547);
}

.compass-factors {
  font-size: 0.78rem;
  list-style: none;
  padding: 0;
  margin: 0;
}

/* What Changed */
.what-changed-panel {
  margin-top: 16px;
}

.what-changed-panel ul {
  list-style: none;
  padding: 0;
  margin: 0;
  max-height: 140px;
  overflow-y: auto;
}

.what-changed-panel li {
  padding: 6px 0;
  font-size: 0.82rem;
  border-bottom: 1px solid rgba(255,255,255,0.04);
}

.what-changed-panel time {
  color: var(--gold);
  font-variant-numeric: tabular-nums;
  margin-right: 8px;
  font-size: 0.75rem;
}

/* Daily Harbor */
#dailyHarborOverlay[hidden] {
  display: none !important;
  pointer-events: none !important;
  visibility: hidden !important;
  opacity: 0 !important;
}

#dailyHarborOverlay:not([hidden]) {
  position: fixed;
  inset: 0;
  z-index: 900;
  background: rgba(3, 8, 16, 0.92);
  display: flex;
  align-items: center;
  justify-content: center;
}

body.harbor-modal-open {
  overflow: hidden;
}

.harbor-card {
  text-align: center;
  padding: 48px;
  max-width: 480px;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius);
  background: linear-gradient(165deg, var(--wtc-navy-panel), var(--wtc-navy-steel));
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.55);
}

.harbor-title {
  font-family: var(--font-display);
  font-size: 1.8rem;
  letter-spacing: 0.15em;
  color: var(--gold-soft);
  margin-bottom: 24px;
}

/* Chart overlay side panel */
.chart-overlay-panel {
  margin-top: 12px;
  padding: 12px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: rgba(5, 10, 18, 0.5);
  position: relative;
  min-height: 80px;
}

.overlay-band {
  position: absolute;
  height: 8px;
  border-radius: 4px;
  opacity: 0.35;
}

.overlay-band.long { background: var(--green); }
.overlay-band.short { background: var(--red); }
.overlay-band.neutral { background: var(--text-muted); }

.nav-check-status {
  font-size: 0.82rem;
  padding: 8px 12px;
  border-radius: 8px;
  margin-top: 8px;
  text-align: center;
}

.nav-check-ready { background: rgba(92, 184, 138, 0.12); color: var(--green); }
.nav-check-waiting { background: var(--gold-dim); color: var(--gold-soft); }
.nav-check-blocked { background: rgba(212, 107, 107, 0.12); color: var(--red); }

body.experience-off .nav-rail {
  display: flex !important;
}

body.experience-off .briefing-shell,
body.experience-off #dailyHarborOverlay {
  display: block !important;
}

body.experience-off #launchOverlay {
  display: none !important;
}

body.experience-off .command-deck-layout {
  grid-template-columns: 1fr;
}

/* Market Event Radar — full-width news hub (no Pete / instrument rail) */
body.event-radar-mode .command-deck-layout {
  min-height: 0;
  max-width: 100vw;
  overflow: hidden;
  height: 100vh;
  height: 100dvh;
}

body.event-radar-mode .deck-persistent-shell {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) !important;
  grid-template-rows: minmax(0, 1fr) !important;
  max-width: none !important;
  width: 100% !important;
  height: calc(100vh - var(--desk-header-h, 64px)) !important;
  height: calc(100dvh - var(--desk-header-h, 64px)) !important;
  max-height: calc(100vh - var(--desk-header-h, 64px)) !important;
  max-height: calc(100dvh - var(--desk-header-h, 64px)) !important;
  padding: 8px 12px 10px !important;
  align-items: stretch !important;
  gap: 0 !important;
  min-width: 0;
  overflow: hidden !important;
  box-sizing: border-box;
  margin: 0 !important;
}

body.event-radar-mode #instrumentRail,
body.event-radar-mode .deck-bottom,
body.event-radar-mode .panel-avatar,
body.event-radar-mode #peteAvatarPanel,
body.event-radar-mode #tradingHubWidget {
  display: none !important;
}

body.event-radar-mode .deck-workspace {
  grid-row: 1 !important;
  grid-column: 1 !important;
  min-height: 0 !important;
  min-width: 0 !important;
  height: 100% !important;
  max-height: 100% !important;
  overflow: hidden !important;
  display: flex !important;
  flex-direction: column !important;
}

body.event-radar-mode .event-radar-shell,
body.event-radar-mode .deck-workspace > .event-radar-shell:not([hidden]) {
  max-width: none !important;
  width: 100% !important;
  margin: 0 !important;
  padding: 8px 10px 10px;
  flex: 1 1 auto;
  min-height: 0;
  height: 100%;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  font-size: 0.74rem;
  box-sizing: border-box;
}

body.event-radar-mode .event-radar-header {
  margin-bottom: 10px;
}

body.event-radar-mode .event-radar-header .eyebrow {
  font-size: 0.62rem;
  margin-bottom: 2px;
}

body.event-radar-mode .event-radar-subtitle {
  font-size: 0.68rem;
}

body.event-radar-mode .event-radar-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 10px;
  margin-bottom: 10px;
}

body.event-radar-mode .event-radar-today-panel,
body.event-radar-mode .event-radar-week-panel,
body.event-radar-mode .event-radar-news-panel {
  padding: 10px 12px;
  margin: 0;
}

body.event-radar-mode .event-radar-timeline-compact .radar-route {
  padding-left: 16px;
  border-left-width: 1px;
}

body.event-radar-mode .radar-event {
  margin-bottom: 10px;
  padding-left: 8px;
}

body.event-radar-mode .radar-event-marker {
  left: -21px;
  width: 7px;
  height: 7px;
  top: 5px;
}

body.event-radar-mode .radar-event h4 {
  font-size: 0.78rem;
  font-weight: 600;
  line-height: 1.3;
  margin: 2px 0;
}

body.event-radar-mode .radar-event time {
  font-size: 0.64rem;
}

body.event-radar-mode .radar-event-meta,
body.event-radar-mode .radar-event-data,
body.event-radar-mode .radar-event-impact {
  font-size: 0.66rem;
  line-height: 1.35;
  margin: 0;
}

body.event-radar-mode .radar-event-surprise {
  font-size: 0.6rem;
  margin: 3px 0 0;
}

body.event-radar-mode .radar-now-marker {
  font-size: 0.64rem;
  margin-bottom: 8px;
}

body.event-radar-mode .week-at-glance-grid {
  grid-template-columns: 1fr;
  gap: 6px;
}

body.event-radar-mode .event-radar-week-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 6px;
}

body.event-radar-mode .event-radar-week-heading {
  min-width: 0;
}

body.event-radar-mode .event-radar-week-range {
  font-size: 0.62rem;
  margin: 2px 0 0;
}

body.event-radar-mode .event-radar-week-nav {
  display: flex;
  flex-shrink: 0;
  align-items: center;
  gap: 6px;
}

body.event-radar-mode .event-radar-week-btn {
  appearance: none;
  border-radius: 9999px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  background: rgba(255, 255, 255, 0.04);
  color: rgba(255, 255, 255, 0.88);
  font-size: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  line-height: 1;
  padding: 5px 10px;
  cursor: pointer;
  white-space: nowrap;
}

body.event-radar-mode .event-radar-week-btn:hover {
  border-color: rgba(212, 175, 55, 0.55);
  color: #f5e6b8;
}

body.event-radar-mode .event-radar-week-btn.is-active {
  border-color: rgba(212, 175, 55, 0.75);
  color: #f5e6b8;
  box-shadow: inset 0 0 0 1px rgba(212, 175, 55, 0.18);
}

body.event-radar-mode .event-radar-week-btn:disabled {
  opacity: 0.55;
  cursor: default;
}

body.event-radar-mode .week-day-card {
  padding: 6px 8px;
  font-size: 0.66rem;
}

body.event-radar-mode .week-day-card header strong {
  font-size: 0.72rem;
}

body.event-radar-mode .breaking-news-compact .news-item {
  padding: 6px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

body.event-radar-mode .breaking-news-compact .news-item time {
  font-size: 0.62rem;
}

body.event-radar-mode .news-geo-event time {
  font-size: 0.62rem;
  color: var(--gold-soft, #e8d5a3);
}

body.event-radar-mode .breaking-news-compact .news-headline-link,
body.event-radar-mode .breaking-news-compact .news-headline {
  font-size: 0.72rem;
  line-height: 1.35;
  margin: 2px 0;
}

body.event-radar-mode .breaking-news-compact .news-summary {
  font-size: 0.62rem;
  line-height: 1.25;
  margin: 2px 0;
}

body.event-radar-mode .breaking-news-compact .news-meta {
  font-size: 0.58rem;
}

body.event-radar-mode .breaking-news-compact .muted,
body.event-radar-mode .breaking-news-compact .news-symbols {
  font-size: 0.62rem;
}

@media (max-width: 1100px) {
  body.event-radar-mode .event-radar-grid {
    grid-template-columns: 1fr;
  }

  body.event-radar-mode .deck-persistent-shell {
    grid-template-columns: minmax(0, 1fr) !important;
    grid-template-rows: minmax(0, 1fr) !important;
  }

  body.event-radar-mode .panel-avatar,
  body.event-radar-mode #peteAvatarPanel,
  body.event-radar-mode #tradingHubWidget {
    display: none !important;
  }
}

/* Market Event Radar */
.event-radar-shell {
  max-width: none;
  width: 100%;
  margin: 0;
  padding: 16px 12px 20px;
  box-sizing: border-box;
}

.event-radar-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 20px;
}

.event-radar-subtitle {
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  color: var(--text-muted);
  margin-top: 4px;
}

.event-feed-status {
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  padding: 4px 10px;
  border-radius: 999px;
  border: 1px solid var(--border);
}

.status-live { color: var(--green); border-color: rgba(92,184,138,0.3); }
.status-limited { color: var(--gold-soft); }
.status-stale, .status-disconnected { color: var(--red); }

.radar-now-marker {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 16px;
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  color: var(--gold-soft);
}

.radar-now-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 10px rgba(201,169,98,0.5);
}

.radar-route {
  position: relative;
  padding-left: 24px;
  border-left: 1px solid rgba(201,169,98,0.25);
}

.radar-event {
  position: relative;
  margin-bottom: 20px;
  padding-left: 12px;
}

.radar-event-marker {
  position: absolute;
  left: -29px;
  top: 6px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: 1px solid var(--border-strong);
  background: var(--bg-deep);
}

.radar-event.approaching .radar-event-marker {
  background: var(--gold);
  box-shadow: 0 0 12px rgba(201,169,98,0.45);
  animation: radarPulse 2s ease infinite;
}

.radar-event.critical .radar-event-marker { border-color: var(--red); }
.radar-event.completed .radar-event-marker { opacity: 0.45; background: var(--text-muted); }

@keyframes radarPulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.15); opacity: 0.85; }
}

.radar-event time {
  font-size: 0.72rem;
  color: var(--gold);
  font-variant-numeric: tabular-nums;
}

.radar-event h4 {
  margin: 4px 0;
  font-family: var(--font-display);
  font-size: 1rem;
}

.radar-event-meta { font-size: 0.78rem; margin: 0; }

.radar-event-surprise {
  margin: 4px 0 0;
  font-size: 0.68rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 700;
}

.radar-event-surprise.better { color: var(--green); }
.radar-event-surprise.worse { color: var(--red); }
.radar-event-surprise.in-line { color: var(--gold-soft); }

.radar-event-impact {
  margin: 2px 0 0;
  font-size: 0.72rem;
  line-height: 1.35;
  color: var(--gold-soft);
}

.importance-critical { color: var(--red); }
.importance-high { color: var(--amber); }
.importance-moderate { color: var(--gold-soft); }
.importance-low, .importance-informational { color: var(--text-muted); }

.helm-rithmic-accounts {
  margin: 8px 0;
  display: grid;
  gap: 6px;
}

.helm-rithmic-account-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: 0.78rem;
}

.hub-rithmic-broker-card .helm-form-grid {
  margin: 6px 0 8px;
}

#nextMarketEvent {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid rgba(255,255,255,0.05);
}

.radar-next-title {
  font-family: var(--font-display);
  font-size: 1.05rem;
  margin: 4px 0;
}

.radar-next-time {
  font-variant-numeric: tabular-nums;
  color: var(--gold-soft);
  font-size: 0.85rem;
}

.radar-exposure {
  font-size: 0.78rem;
  color: var(--amber);
  margin-top: 8px;
  line-height: 1.4;
}

.radar-clear {
  font-family: var(--font-display);
  letter-spacing: 0.12em;
  color: var(--gold-soft);
}

.briefing-event-list {
  list-style: none;
  padding: 0;
  margin: 12px 0;
}

.briefing-event-list li {
  display: grid;
  grid-template-columns: 100px 1fr auto;
  gap: 8px;
  padding: 8px 0;
  border-bottom: 1px solid rgba(255,255,255,0.04);
  font-size: 0.82rem;
  align-items: baseline;
}

.event-window-list {
  list-style: none;
  padding: 0;
  margin: 8px 0;
  font-size: 0.78rem;
}

.event-window-list li {
  padding: 4px 0;
  color: var(--text-muted);
}

#breakingNewsFeed {
  max-height: 200px;
  overflow-y: auto;
}

.news-item {
  padding: 8px 0;
  border-bottom: 1px solid rgba(255,255,255,0.04);
  font-size: 0.8rem;
}

.news-headline { margin: 4px 0; }
.news-symbols { font-size: 0.72rem; color: var(--gold-soft); }

@media (prefers-reduced-motion: reduce) {
  .radar-event.approaching .radar-event-marker { animation: none; }
}

/* Pete Takes the Helm — compact viewport dashboard */
body.helm-mode .command-deck-layout {
  min-height: 100vh;
  max-width: 100vw;
  overflow: hidden;
  height: 100vh;
}

body.helm-mode .deck-persistent-shell {
  grid-template-columns: minmax(0, 1fr) !important;
  grid-template-rows: minmax(0, 1fr) !important;
  max-width: 100%;
  width: 100%;
  height: calc(100vh - var(--desk-header-h, 64px));
  max-height: calc(100vh - var(--desk-header-h, 64px));
  padding: 6px 14px 8px;
  align-items: stretch;
  gap: 0;
  min-width: 0;
  overflow: hidden;
  box-sizing: border-box;
}

body.helm-mode #peteAvatarPanel {
  display: none !important;
}

body.helm-mode .deck-bottom,
body.helm-mode #instrumentRail {
  display: none !important;
}

body.helm-mode .deck-workspace {
  grid-row: 1;
  grid-column: 1;
  min-height: 0;
  min-width: 0;
  height: 100%;
  max-height: 100%;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

body.helm-mode .deck-workspace > .deck-view:not([hidden]) {
  flex: 1 1 auto;
  min-height: 0;
  overflow: hidden;
}

/* Mission-control layout — Trading Hub full viewport (no Pete rail, no analysis sidebar) */
body.trade-log-mode #instrumentRail,
body.trade-log-mode .deck-bottom,
body.trade-log-mode #peteAvatarPanel {
  display: none !important;
}

body.trade-log-mode .command-deck-layout {
  min-height: 0;
  max-width: 100vw;
  overflow: hidden;
  height: 100vh;
  height: 100dvh;
}

body.helm-mode .command-deck-layout {
  min-height: 0;
  max-width: 100vw;
  overflow: hidden;
  height: 100vh;
  height: 100dvh;
}

body.trade-log-mode .deck-persistent-shell {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) !important;
  grid-template-rows: minmax(0, 1fr) !important;
  max-width: 100% !important;
  width: 100% !important;
  height: calc(100vh - var(--desk-header-h, 64px)) !important;
  height: calc(100dvh - var(--desk-header-h, 64px)) !important;
  max-height: calc(100vh - var(--desk-header-h, 64px)) !important;
  max-height: calc(100dvh - var(--desk-header-h, 64px)) !important;
  min-height: 0 !important;
  padding: 8px 16px 10px !important;
  align-items: stretch !important;
  gap: 0 !important;
  min-width: 0;
  overflow: hidden;
  box-sizing: border-box;
  margin: 0 !important;
}

body.trade-log-mode .deck-workspace {
  grid-row: 1;
  grid-column: 1;
  min-height: 0;
  min-width: 0;
  height: 100%;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

body.trade-log-mode .deck-workspace > .deck-view:not([hidden]) {
  flex: 1 1 auto;
  min-height: 0;
  overflow: hidden;
}

body.trade-log-mode .trade-hub-shell {
  height: 100%;
  max-height: 100%;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  padding: 0;
  min-width: 0;
  max-width: 100%;
}

body.trade-log-mode .trade-hub-command-bar {
  flex-shrink: 0;
  display: flex;
  flex-wrap: nowrap;
  align-items: stretch;
  justify-content: flex-start;
  gap: 10px;
  padding: 4px 8px;
  margin-bottom: 2px;
  border: 1px solid rgba(197, 160, 89, 0.22);
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.28);
}

body.trade-log-mode .trade-hub-command-brand {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 6px;
  flex: 0 0 auto;
  width: 240px;
  max-width: min(260px, 28vw);
  min-width: 180px;
}

body.trade-log-mode .trade-hub-mission-zones {
  display: flex;
  flex-direction: column;
  flex-wrap: nowrap;
  gap: 4px;
  flex: 0 1 auto;
  width: max-content;
  max-width: min(640px, 52vw);
  min-width: 0;
  align-items: stretch;
}

body.trade-log-mode .trade-hub-mission-zone {
  flex: 0 0 auto;
  min-width: 0;
  border: 1px solid rgba(197, 160, 89, 0.18);
  border-radius: 6px;
  padding: 3px 7px;
  background: rgba(8, 12, 18, 0.45);
  cursor: pointer;
  pointer-events: auto;
  position: relative;
  z-index: 4;
}

body.trade-log-mode .trade-hub-mission-zone:hover,
body.trade-log-mode .trade-hub-mission-zone:focus-visible {
  filter: brightness(1.08);
  outline: none;
}

body.trade-log-mode .trade-hub-mission-zone.is-active {
  box-shadow: inset 0 0 0 1px rgba(58, 208, 232, 0.45);
}

body.trade-log-mode .trade-hub-mission-longterm {
  border-color: rgba(120, 180, 255, 0.28);
  background: rgba(20, 40, 70, 0.35);
}

body.trade-log-mode .trade-hub-mission-shortterm {
  border-color: rgba(197, 160, 89, 0.28);
}

body.trade-log-mode .trade-hub-mission-zone-label {
  margin: 0 0 2px;
  font-size: 0.52rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gold-soft);
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

body.trade-log-mode .trade-hub-mission-longterm .trade-hub-mission-zone-label {
  color: #9ec5ff;
}

body.trade-log-mode .trade-hub-zone-stats {
  gap: 2px 8px;
  flex-wrap: nowrap;
  font-size: 0.64rem;
}

body.trade-log-mode .trade-hub-zone-stats .trade-hub-cmd-stat {
  gap: 3px;
}

body.trade-log-mode .trade-hub-zone-stats .trade-hub-cmd-stat-hero strong {
  font-size: 0.72rem;
}

body.trade-log-mode .trade-hub-zone-stats em {
  font-size: 0.52rem;
  letter-spacing: 0.04em;
}

@media (max-width: 1100px) {
  body.trade-log-mode .trade-hub-mission-zones {
    flex-wrap: nowrap;
  }
  body.trade-log-mode .trade-hub-mission-zone {
    flex: 0 0 auto;
  }
  body.trade-log-mode .trade-hub-zone-stats {
    flex-wrap: wrap;
  }
}

body.trade-log-mode .paper-horizon-folder-wrap {
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
  min-height: 0;
  gap: 0;
  margin-top: 2px;
}

body.trade-log-mode #tradeHubPaperPanel.mission-control-deck {
  gap: 4px;
}

body.trade-log-mode .paper-hub-analysis-bar,
body.trade-log-mode .trade-hub-news-panel,
body.trade-log-mode .paper-hub-status-banner {
  display: none !important;
}

body.trade-log-mode .paper-horizon-tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin: 0;
  padding: 0 2px 0;
  border: none;
  border-radius: 0;
  background: transparent;
  position: relative;
  z-index: 20;
  isolation: isolate;
  pointer-events: auto;
}

body.trade-log-mode .paper-horizon-tab {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
  padding: 11px 14px;
  border: 2px solid rgba(255, 255, 255, 0.12);
  border-radius: 12px 12px 0 0;
  background: rgba(8, 12, 18, 0.55);
  color: #8a9bb0;
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s, color 0.15s;
  margin-bottom: -2px;
  position: relative;
  z-index: 21;
  pointer-events: auto !important;
}

body.trade-log-mode .paper-horizon-tab-short,
body.trade-log-mode .paper-horizon-tab[data-paper-horizon="short"] {
  border-color: rgba(155, 120, 255, 0.42);
  color: #d8ccff;
  background: linear-gradient(180deg, rgba(120, 85, 210, 0.2), rgba(18, 14, 32, 0.85));
}

body.trade-log-mode .paper-horizon-tab-long,
body.trade-log-mode .paper-horizon-tab[data-paper-horizon="long"] {
  border-color: rgba(197, 160, 89, 0.42);
  color: #f0dfb8;
  background: linear-gradient(180deg, rgba(197, 160, 89, 0.18), rgba(22, 16, 10, 0.85));
}

body.trade-log-mode .paper-horizon-tab:hover {
  color: #f2f0ea;
  filter: brightness(1.08);
}

body.trade-log-mode .paper-horizon-tab:not(.active) {
  opacity: 0.82;
  border-bottom-color: transparent;
}

body.trade-log-mode .paper-horizon-tab.active[data-paper-horizon="short"] {
  border-color: rgba(175, 140, 255, 0.9);
  border-bottom-color: rgba(14, 12, 28, 0.98);
  color: #f5f0ff;
  background: linear-gradient(180deg, rgba(140, 100, 240, 0.4), rgba(14, 12, 28, 0.98));
  box-shadow: none;
  opacity: 1;
  z-index: 4;
  position: relative;
}

body.trade-log-mode .paper-horizon-tab.active[data-paper-horizon="long"] {
  border-color: rgba(220, 180, 100, 0.9);
  border-bottom-color: rgba(18, 14, 10, 0.98);
  color: #fff4d8;
  background: linear-gradient(180deg, rgba(210, 170, 95, 0.38), rgba(18, 14, 10, 0.98));
  box-shadow: none;
  opacity: 1;
  z-index: 4;
  position: relative;
}

body.trade-log-mode .paper-horizon-folder {
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 8px 8px 10px;
  position: relative;
  z-index: 1;
  border: 2px solid rgba(155, 120, 255, 0.55);
  border-radius: 0 12px 12px 12px;
  background:
    linear-gradient(180deg, rgba(40, 28, 80, 0.2), rgba(8, 12, 18, 0.4)),
    rgba(10, 12, 22, 0.55);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

body.trade-log-mode .paper-horizon-folder[data-horizon="short"] {
  border-color: rgba(155, 120, 255, 0.55);
  border-radius: 0 12px 12px 12px;
}

body.trade-log-mode .paper-horizon-folder[data-horizon="long"] {
  border-color: rgba(197, 160, 89, 0.55);
  border-radius: 12px 0 12px 12px;
  background:
    linear-gradient(180deg, rgba(80, 60, 24, 0.2), rgba(8, 12, 18, 0.4)),
    rgba(14, 12, 10, 0.55);
}

body.trade-log-mode .paper-horizon-folder-banner {
  flex: 0 0 auto;
  margin: 0 0 2px;
  padding: 7px 12px;
  border-radius: 8px;
  font-size: 0.78rem;
  letter-spacing: 0.04em;
  color: #ddd0ff;
  background: rgba(120, 80, 220, 0.16);
  border: 1px solid rgba(155, 120, 255, 0.35);
}

body.trade-log-mode .paper-horizon-folder-banner strong {
  color: #f0e8ff;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.72rem;
}

body.trade-log-mode .paper-horizon-folder[data-horizon="long"] .paper-horizon-folder-banner {
  color: #f0e0c0;
  background: rgba(197, 160, 89, 0.14);
  border-color: rgba(197, 160, 89, 0.4);
}

body.trade-log-mode .paper-horizon-folder[data-horizon="long"] .paper-horizon-folder-banner strong {
  color: #ffe7b0;
}

body.trade-log-mode .paper-horizon-401k {
  margin-left: 2px;
}

body.trade-log-mode .paper-horizon-desc {
  margin: 0 0 4px;
  font-size: 0.78rem;
  color: #c5a059;
  font-style: italic;
}

body.trade-log-mode .paper-401k-badge {
  display: inline-block;
  margin-left: 6px;
  padding: 1px 6px;
  border-radius: 4px;
  font-size: 0.62rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  background: rgba(155, 120, 255, 0.22);
  color: #ddd0ff;
  border: 1px solid rgba(155, 120, 255, 0.45);
  vertical-align: middle;
}

body.trade-log-mode .paper-401k-badge[hidden],
.paper-401k-badge[hidden] {
  display: none !important;
}

body.trade-log-mode .paper-ticker-journal-btn {
  margin-left: 0;
}

body.trade-log-mode .paper-platform-tab-stats[hidden],
.paper-platform-tab-stats[hidden] {
  display: none !important;
}

body.trade-log-mode .journal-account-tabs {
  flex-wrap: wrap;
}

body.trade-log-mode .journal-account-tabs .journal-platform-tab {
  font-size: 0.72rem;
  padding: 6px 10px;
}

body.trade-log-mode .trade-hub-command-brand .eyebrow {
  font-size: 0.58rem;
  margin: 0;
}

body.trade-log-mode .trade-hub-command-title {
  font-size: 0.82rem;
  letter-spacing: 0.04em;
  color: var(--gold-soft);
}

body.trade-log-mode .trade-hub-command-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-top: 4px;
  max-width: none;
  width: 100%;
}

body.trade-log-mode .trade-hub-mc-btn,
body.trade-log-mode .trade-hub-main-journal-btn {
  margin-top: 0;
  width: auto;
  max-width: none;
  flex: 1 1 auto;
  font-size: 0.58rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  padding: 4px 8px;
  white-space: nowrap;
}

body.trade-log-mode .trade-hub-mc-btn-news {
  border-color: rgba(90, 160, 210, 0.45);
  color: #b8daf5;
  background: rgba(50, 110, 160, 0.22);
}

body.trade-log-mode .trade-hub-mc-btn-pete {
  border-color: rgba(197, 160, 89, 0.45);
  color: #f0e0c0;
  background: rgba(197, 160, 89, 0.16);
}

body.trade-log-mode .trade-hub-command-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 18px;
  font-size: 0.82rem;
  font-variant-numeric: tabular-nums;
  align-items: baseline;
}

body.trade-log-mode .trade-hub-cmd-stat-hero strong {
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.01em;
}

body.trade-log-mode .trade-hub-command-stats span {
  display: inline-flex;
  align-items: baseline;
  gap: 6px;
}

body.trade-log-mode .trade-hub-command-stats em {
  font-style: normal;
  color: var(--text-muted);
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

body.trade-log-mode .paper-platform-ticker-stat strong {
  font-size: 1rem;
  font-weight: 700;
}

body.trade-log-mode .paper-platform-ticker-stat em {
  font-size: 0.64rem;
}

body.trade-log-mode .paper-shared-open-panel .eyebrow {
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  margin-bottom: 6px;
  font-weight: 700;
  color: #e8eef5;
}

body.trade-log-mode .paper-shared-open-panel .trade-table {
  font-size: 0.78rem;
}

body.trade-log-mode .paper-shared-open-panel .trade-table th {
  font-size: 0.72rem;
  padding: 6px 5px;
  color: #c8d4e4;
}

body.trade-log-mode .paper-shared-open-panel .trade-table td {
  font-size: 0.78rem;
  padding: 7px 6px;
  font-weight: 500;
}

body.trade-log-mode .paper-shared-open-panel .btn-sm {
  font-size: 0.78rem;
  padding: 4px 10px;
}

body.trade-log-mode .journal-cal-pnl {
  font-size: 0.72rem;
  font-weight: 700;
}

body.trade-log-mode .trade-hub-command-stats strong.pnl-pos,
body.trade-log-mode .trade-hub-command-stats strong.helm-pnl-win,
body.trade-log-mode .hub-venue-stats strong.pnl-pos,
body.trade-log-mode .hub-venue-stats strong.helm-pnl-win,
body.trade-log-mode .member-paper-price-stats strong.pnl-pos,
body.trade-log-mode .member-paper-price-stats strong.helm-pnl-win,
body.trade-log-mode .paper-platform-ticker-stat strong.pnl-pos,
body.trade-log-mode .trade-table .pnl-pos,
body.trade-log-mode .trade-table td.pnl-pos {
  color: #5cb88a;
}

body.trade-log-mode .trade-hub-command-stats strong.pnl-neg,
body.trade-log-mode .trade-hub-command-stats strong.helm-pnl-loss,
body.trade-log-mode .hub-venue-stats strong.pnl-neg,
body.trade-log-mode .hub-venue-stats strong.helm-pnl-loss,
body.trade-log-mode .member-paper-price-stats strong.pnl-neg,
body.trade-log-mode .member-paper-price-stats strong.helm-pnl-loss,
body.trade-log-mode .paper-platform-ticker-stat strong.pnl-neg,
body.trade-log-mode .trade-table .pnl-neg,
body.trade-log-mode .trade-table td.pnl-neg {
  color: #e07070;
}

body.trade-log-mode .journal-stat strong.pnl-win,
body.trade-log-mode .member-journal-table .pnl-win {
  color: #5cb88a;
}

body.trade-log-mode .journal-stat strong.pnl-loss,
body.trade-log-mode .member-journal-table .pnl-loss {
  color: #e07070;
}

body.trade-log-mode .trade-hub-tabs-inline {
  margin: 0;
  flex-shrink: 0;
}

body.trade-log-mode .trade-hub-tabs-stacked {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: stretch;
  gap: 4px;
  width: 100%;
}

body.trade-log-mode .trade-hub-tabs-stacked .trade-hub-tab {
  width: 100%;
  justify-content: center;
  white-space: nowrap;
}

body.trade-log-mode .trade-hub-tab {
  font-size: 0.64rem;
  padding: 3px 8px;
}

body.trade-log-mode .member-paper-hub-dashboard.mission-control-deck {
  flex: 1 1 auto;
  min-height: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding-bottom: 4px;
}

body.trade-log-mode .trade-hub-news-panel {
  flex: 0 0 auto;
  order: -2;
  margin-bottom: 4px;
  padding: 6px 8px;
}

body.trade-log-mode .paper-horizon-tabs {
  flex: 0 0 auto;
  order: -1;
}

body.trade-log-mode .paper-platform-tabs {
  flex: 0 0 auto;
}

body.trade-log-mode .trade-hub-news-panel .eyebrow {
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  margin-bottom: 4px;
  color: #d8e4ef;
}

.trade-hub-release-impact {
  display: none;
}

.trade-hub-release-impact:not([hidden]) {
  display: block;
  font-size: 0.74rem;
  line-height: 1.35;
  padding: 6px 8px;
  margin: 0 0 6px;
  border-radius: 6px;
  border: 1px solid rgba(201, 169, 98, 0.32);
  background: rgba(201, 169, 98, 0.08);
  color: var(--gold-soft);
}

.trade-hub-release-impact.positive {
  border-color: rgba(92, 184, 138, 0.45);
  background: rgba(92, 184, 138, 0.1);
  color: var(--green);
}

.trade-hub-release-impact.negative {
  border-color: rgba(220, 90, 90, 0.45);
  background: rgba(220, 90, 90, 0.1);
  color: var(--red);
}

body.trade-log-mode .trade-hub-release-impact:not([hidden]) {
  font-size: 0.7rem;
  padding: 5px 7px;
  margin-bottom: 4px;
}

body.trade-log-mode .trade-hub-news-feed {
  max-height: 88px;
  overflow-y: auto;
}

body.trade-log-mode .trade-hub-news-feed .news-item {
  padding: 4px 0;
  font-size: 0.74rem;
}

body.trade-log-mode .trade-hub-news-feed .news-headline-link,
body.trade-log-mode .trade-hub-news-feed .news-headline {
  font-size: 0.76rem;
  line-height: 1.35;
  color: #e8eef5;
}

body.trade-log-mode .trade-hub-news-feed time {
  font-size: 0.62rem;
  color: #9eb0c8;
}

.paper-platform-window {
  display: flex;
  flex-direction: column;
  gap: 0;
  margin: 0 0 8px;
  border: 1px solid rgba(197, 160, 89, 0.22);
  border-radius: 10px;
  background: rgba(8, 12, 18, 0.55);
  overflow: visible;
}

body.trade-log-mode .paper-platform-window .paper-platform-tabs {
  margin: 0;
  border: none;
  border-radius: 0;
  background: rgba(0, 0, 0, 0.2);
}

body.trade-log-mode .paper-ticker-journal-btn {
  margin-left: 0;
}

body.trade-log-mode .paper-platform-tab-stats[hidden],
.paper-platform-tab-stats[hidden] {
  display: none !important;
}

.paper-platform-panel[hidden] {
  display: none !important;
}

body.trade-log-mode #paperFuturesPanel:not([hidden]) {
  flex: 1 1 auto;
  min-height: 0;
  overflow: hidden;
  display: grid;
  grid-template-rows: minmax(0, auto) minmax(220px, 0.46fr) minmax(0, 0.34fr);
  gap: 4px;
}

body.trade-log-mode #paperOptionsPanel:not([hidden]) {
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
  display: block;
}

.journal-platform-tabs {
  display: flex;
  gap: 8px;
  margin: 0 0 12px;
}

.journal-platform-tab {
  flex: 1;
  border: 1px solid rgba(201, 162, 39, 0.2);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.02);
  color: var(--text-muted);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  padding: 8px 10px;
  cursor: pointer;
}

.journal-platform-tab.active {
  color: var(--gold-soft);
  border-color: rgba(201, 162, 39, 0.4);
  background: rgba(201, 162, 39, 0.1);
}

body.trade-log-mode .mc-row-venue {
  display: block;
  min-height: 0;
  overflow: hidden;
}

body.trade-log-mode .mc-row-venue .member-paper-hub-broker {
  height: 100%;
}

body.trade-log-mode .mc-row-ticket-pos {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 4px;
  align-items: stretch;
  min-height: 0;
  overflow: visible;
}

body.trade-log-mode .mc-row-tables-2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

body.trade-log-mode .mc-row-tables-single {
  grid-template-columns: 1fr;
}

/* Futures desk: two compact rows under Futures/Options tabs */
body.trade-log-mode .mc-paper-futures-deck {
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-height: 0;
  flex: 1 1 auto;
}

body.trade-log-mode .mc-row-positions-orders {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: 6px;
  align-items: stretch;
  min-height: 0;
  flex: 0 0 auto;
}

body.trade-log-mode .mc-row-positions-orders.is-options-mode {
  grid-template-columns: 1fr;
}

body.trade-log-mode .mc-row-positions-orders.is-options-mode [data-futures-only] {
  display: none !important;
}

body.trade-log-mode .mc-row-venue-ticket {
  display: grid;
  grid-template-columns: minmax(240px, 0.85fr) minmax(320px, 1.15fr);
  gap: 6px;
  align-items: stretch;
  min-height: 0;
  flex: 1 1 auto;
}

body.trade-log-mode .mc-row-venue-ticket > .panel {
  min-height: 0;
  max-height: min(42vh, 420px);
  overflow: auto;
}

body.trade-log-mode .paper-open-side .trade-table-wrap {
  flex: 1 1 auto;
  min-height: 120px;
  max-height: min(22vh, 200px);
  overflow: auto;
}

body.trade-log-mode .paper-shared-open-panel {
  flex: 1 1 auto;
  min-height: 0;
  margin-bottom: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  max-height: min(26vh, 230px);
}

body.trade-log-mode .paper-shared-open-panel .trade-table-wrap {
  min-height: 100px;
  max-height: none;
  flex: 1 1 auto;
  overflow: auto;
}

body.trade-log-mode .paper-working-side {
  display: flex;
  flex-direction: column;
  min-height: 0;
  max-height: min(26vh, 230px);
  overflow: hidden;
}

body.trade-log-mode .paper-working-side .trade-table-wrap {
  flex: 1 1 auto;
  min-height: 100px;
  overflow: auto;
}

body.trade-log-mode .mc-row-top {
  display: grid;
  grid-template-columns: minmax(220px, 0.9fr) minmax(280px, 1.1fr);
  gap: 4px;
  align-items: stretch;
  min-height: 0;
  overflow: hidden;
}

body.trade-log-mode .hub-venue-cards {
  display: grid;
  grid-template-columns: 1fr;
  gap: 4px;
}

body.trade-log-mode .hub-venue-cards .helm-broker-card {
  padding: 5px 6px;
  min-height: 0;
}

body.trade-log-mode .hub-venue-cards h3 {
  font-size: 0.72rem;
  margin: 0;
}

body.trade-log-mode .hub-venue-blurb {
  display: none;
}

body.trade-log-mode .hub-venue-stats {
  grid-template-columns: repeat(2, 1fr);
  gap: 2px 6px;
  font-size: 0.64rem;
}

body.trade-log-mode .hub-venue-meta {
  font-size: 0.6rem;
  margin: 2px 0 0;
}

body.trade-log-mode .hub-venue-actions .btn,
body.trade-log-mode .hub-venue-secondary .btn {
  font-size: 0.62rem;
  padding: 2px 6px;
}

body.trade-log-mode .hub-venue-secondary {
  margin-top: 4px;
  display: flex;
  gap: 4px;
}

body.trade-log-mode .mc-row-tables {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 4px;
  min-height: 0;
  overflow: hidden;
}

body.trade-log-mode .mission-control-deck .helm-panel,
body.trade-log-mode .mission-control-deck .panel {
  padding: 4px 6px;
  margin: 0;
  min-height: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

body.trade-log-mode .mission-control-deck .eyebrow {
  font-size: 0.58rem;
  margin-bottom: 2px;
}

body.trade-log-mode .mission-control-deck .paper-shared-open-panel .eyebrow {
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  margin-bottom: 6px;
  font-weight: 700;
  color: #e8eef5;
}

body.trade-log-mode .mission-control-deck .paper-shared-open-panel .trade-table th {
  font-size: 0.72rem;
  padding: 6px 5px;
  color: #c8d4e4;
}

body.trade-log-mode .mission-control-deck .paper-shared-open-panel .trade-table td {
  font-size: 0.78rem;
  padding: 7px 6px;
  font-weight: 500;
}

body.trade-log-mode .mission-control-deck .muted,
body.trade-log-mode .mission-control-deck .helm-meta {
  font-size: 0.62rem;
  line-height: 1.2;
}

body.trade-log-mode .mission-control-deck .paper-order-ticket-exec .eyebrow {
  font-size: 0.72rem;
  margin-bottom: 2px;
}

body.trade-log-mode .paper-order-ticket-exec {
  padding: 8px 10px !important;
  display: flex !important;
  flex-direction: column;
  min-height: 0;
  overflow: hidden;
}

body.trade-log-mode .paper-order-ticket-exec .paper-ticket-header {
  flex-shrink: 0;
  margin-bottom: 8px;
  padding-bottom: 8px;
}

body.trade-log-mode .paper-order-ticket-exec .paper-ticket-core {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  margin-bottom: 0;
}

body.trade-log-mode .paper-order-ticket-exec .paper-ticket-actions {
  flex-shrink: 0;
  margin-top: auto;
  padding-top: 10px;
  border-top: 1px solid rgba(201, 162, 39, 0.22);
  background: linear-gradient(180deg, rgba(10, 14, 24, 0.4), rgba(10, 14, 24, 0.98));
}

body.trade-log-mode .paper-order-ticket-exec .paper-ticket-actions .btn-ticket-execute {
  min-width: 160px;
  padding: 8px 18px !important;
  font-size: 0.82rem !important;
}

body.trade-log-mode .paper-order-ticket-exec .paper-ticket-title {
  font-size: 1rem;
}

body.trade-log-mode .paper-order-ticket-exec .paper-ticket-label {
  font-size: 0.68rem;
}

body.trade-log-mode .paper-order-ticket-exec .paper-ticket-control,
body.trade-log-mode .paper-order-ticket-exec .paper-side-seg {
  font-size: 0.82rem;
  padding: 6px 8px;
}

body.trade-log-mode .paper-order-ticket-exec .paper-ticket-live {
  font-size: 0.72rem;
}

body.trade-log-mode .paper-order-ticket-exec .paper-ticket-row-primary {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

body.trade-log-mode .paper-order-ticket-exec .paper-ticket-row-bracket {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

body.trade-log-mode .paper-order-ticket-exec .paper-ticket-field-wide {
  grid-column: 1 / -1;
}

body.trade-log-mode .paper-order-ticket-exec .paper-ticket-side-field {
  grid-column: 1 / -1;
}

body.trade-log-mode .paper-order-ticket-exec .paper-ticket-actions .btn {
  font-size: 0.74rem;
  padding: 5px 12px;
}

body.trade-log-mode .paper-order-ticket .paper-order-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 3px 6px;
}

body.trade-log-mode .paper-order-ticket label {
  font-size: 0.58rem;
}

body.trade-log-mode .paper-order-ticket input,
body.trade-log-mode .paper-order-ticket select {
  font-size: 0.68rem;
  padding: 2px 4px;
}

body.trade-log-mode .paper-order-ticket .button-row .btn {
  font-size: 0.64rem;
  padding: 3px 8px;
}

body.trade-log-mode .paper-table-compact .paper-pending-note {
  display: none;
}

body.trade-log-mode .paper-table-compact .trade-table-wrap {
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
}

body.trade-log-mode .paper-table-compact .trade-table {
  font-size: 0.62rem;
}

body.trade-log-mode .paper-table-compact .trade-table th,
body.trade-log-mode .paper-table-compact .trade-table td {
  padding: 2px 4px;
}

body.trade-log-mode .paper-table-panel {
  min-height: 0;
}

body.trade-log-mode .paper-event-guard-banner {
  font-size: 0.62rem;
  padding: 4px 8px;
  margin-bottom: 4px;
}

body.trade-log-mode #tradeHubBrokerPanel {
  flex: 1 1 auto;
  min-height: 0;
  overflow: auto;
}

/* Legacy trade-log header removed — keep rules harmless */
body.trade-log-mode .trade-log-header {
  display: none;
}

body.trade-log-mode .panel-avatar {
  display: none !important;
}

body.trade-log-mode .member-paper-hub-broker .helm-broker-card p.muted:not(.hub-venue-blurb) {
  display: none;
}

body.trade-log-mode .member-paper-hub-broker .hub-venue-cards.helm-broker-cards {
  grid-template-columns: 1fr 1fr;
}

body.trade-log-mode .helm-paper-stats {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 4px 8px;
  font-size: 0.68rem;
}

body.trade-log-mode .helm-paper-stats strong {
  font-size: 0.82rem;
}

body.trade-log-mode .member-paper-hub-dashboard.mission-control-deck {
  overflow: hidden;
  padding-bottom: 4px;
  flex: 1 1 auto;
  min-height: 0;
  overscroll-behavior: contain;
}

body.trade-log-mode .member-paper-hub-broker .helm-broker-card {
  max-width: none;
}

body.trade-log-mode .paper-table-panel .trade-table-wrap {
  padding: 0;
  overflow-x: auto;
}

body.trade-log-mode .paper-table-compact {
  display: flex;
  flex-direction: column;
  min-height: 0;
  overflow: hidden;
}

body.helm-mode .panel-avatar .panel-title {
  display: none;
}

.helm-petes-plan-dock {
  display: none;
}

body.helm-mode .helm-petes-plan-dock {
  display: flex;
  flex: 0 0 auto;
  flex-direction: column;
  min-height: 0;
  max-height: 108px;
  overflow: hidden;
  padding: 4px 10px;
  margin: 0;
  border: 1px solid rgba(197,160,89,0.28);
  border-radius: 8px;
  background: rgba(0,0,0,0.28);
}

body.helm-mode .helm-petes-plan-dock .helm-plan-compact {
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 2px 8px;
  max-height: none;
}

body.helm-mode .helm-petes-plan-dock .helm-panel-head {
  margin-bottom: 2px;
}

body.helm-mode .helm-petes-plan-dock .helm-plan-sub,
body.helm-mode .helm-petes-plan-dock .helm-plan-rationale-line {
  font-size: 0.62rem;
  line-height: 1.2;
  margin: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  grid-column: 1 / -1;
}

body.helm-mode .helm-petes-plan-dock .helm-daily-line {
  margin: 0 0 2px;
  font-size: 0.62rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

body.helm-mode .panel-avatar .avatar-wrap {
  grid-area: video;
  margin: 0;
  width: 100%;
  max-width: 280px;
  min-width: 0;
}

body.helm-mode .panel-avatar .avatar-view {
  display: block;
  width: 100%;
  min-height: 124px;
  max-height: 156px;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  border-radius: 8px;
  background: #000;
}

.helm-live-line.helm-live-active {
  color: #6fdc8c;
  font-weight: 600;
}

body.helm-mode .panel-avatar .eyebrow {
  display: none;
}

body.helm-mode .panel-avatar .pete-status {
  grid-area: status;
  margin: 0;
  padding: 2px 8px;
  font-size: 0.64rem;
  align-self: start;
}

body.helm-mode .panel-avatar .avatar-error {
  grid-column: 1 / -1;
  margin: 0;
  font-size: 0.66rem;
}

body.helm-mode .panel-avatar .btn-retry-video {
  grid-area: video;
  justify-self: start;
  align-self: end;
  margin: 0;
  z-index: 1;
}

body.helm-mode .panel-avatar .button-row {
  grid-area: actions;
  gap: 4px;
  margin: 0;
  flex: none;
  flex-wrap: wrap;
  justify-content: flex-end;
  align-content: center;
  min-width: 0;
  max-width: 220px;
}

body.helm-mode .panel-avatar .mode-chips {
  display: none;
}

body.helm-mode .panel-avatar .button-row .btn {
  padding: 4px 8px;
  font-size: 0.68rem;
  white-space: nowrap;
}

.helm-shell {
  padding: 0;
  max-width: 100%;
  width: 100%;
  height: 100%;
  max-height: 100%;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  gap: 6px;
  min-width: 0;
}

.helm-topbar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr) minmax(0, auto);
  gap: 8px;
  align-items: center;
  flex-shrink: 0;
  min-width: 0;
}
.helm-topbar-brand {
  min-width: 0;
}
.helm-topbar-brand h2 {
  margin: 0;
  font-size: 1rem;
  line-height: 1.15;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.helm-topbar-brand .eyebrow {
  margin: 0 0 2px;
  font-size: 0.58rem;
}
.helm-topbar-analysis {
  font-size: 0.72rem;
  line-height: 1.3;
  padding: 5px 8px;
  border-radius: 8px;
  background: rgba(0,0,0,0.22);
  border: 1px solid rgba(197,160,89,0.15);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  min-width: 0;
}
.helm-topbar-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  justify-content: flex-end;
  min-width: 0;
}

.helm-broker-quick {
  display: inline-flex;
  gap: 4px;
  padding: 2px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(0, 0, 0, 0.25);
}

.helm-broker-quick-btn {
  border-radius: 999px !important;
  border: 1px solid transparent !important;
  background: transparent !important;
  color: var(--text-muted) !important;
}

.helm-broker-quick-btn.active {
  border-color: rgba(201, 162, 39, 0.45) !important;
  background: var(--gold-dim) !important;
  color: var(--gold-soft) !important;
}

.helm-open-positions-panel {
  margin-top: 10px;
}

.helm-open-pos-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.helm-open-table-wrap {
  max-height: 260px; /* ~5 open position rows */
  min-height: 180px;
  overflow: auto;
}

.helm-open-positions-table td,
.helm-open-positions-table th {
  font-size: 0.72rem;
  white-space: nowrap;
}

.helm-pos-open-row td {
  background: rgba(201, 162, 39, 0.06);
}
.helm-topbar-actions .btn-sm {
  padding: 4px 8px;
  font-size: 0.68rem;
}
.helm-topbar-actions .helm-switch-label {
  font-size: 0.72rem;
  gap: 6px;
}
.helm-topbar-actions .helm-switch-ui {
  width: 38px;
  height: 20px;
}
.helm-topbar-actions .helm-switch-ui::after {
  width: 14px;
  height: 14px;
  top: 3px;
  left: 3px;
}
.helm-topbar-actions .helm-switch-label input:checked + .helm-switch-ui::after {
  transform: translateX(18px);
}

.helm-dashboard {
  flex: 1 1 auto;
  min-height: 0;
  min-width: 0;
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr);
  grid-template-rows: minmax(0, 1fr) auto minmax(0, 0.34fr) minmax(0, 0.22fr);
  gap: 5px;
  align-content: stretch;
  overflow: hidden;
  padding-bottom: 4px;
  font-size: 11px;
}
.helm-chart-eye { grid-column: 1; grid-row: 1; min-height: 0; max-height: none; z-index: 1; }
.helm-side-stack { grid-column: 2; grid-row: 1 / span 2; min-height: 0; overflow: hidden; z-index: 1; }
.helm-command-bar { grid-column: 1; grid-row: 2; z-index: 2; }
.helm-broker-panel { grid-column: 1 / -1; grid-row: 3; min-height: 0; overflow: auto; max-height: 100%; z-index: 1; }
.helm-sms-panel { display: none !important; }
.helm-options-paper-section { display: none !important; }
.helm-journal-panel { grid-column: 1 / -1; grid-row: 4; min-height: 0; overflow: hidden; max-height: 100%; z-index: 1; }
.helm-journal-panel:not([open]) { max-height: 2rem; }
.helm-governance-panel { display: none !important; }
.helm-details-panel { display: none !important; }

body.helm-mode .helm-shell {
  font-size: 11px;
}

body.helm-mode .helm-topbar {
  padding: 4px 8px;
  margin-bottom: 4px;
}

body.helm-mode .helm-topbar h2 {
  font-size: 1.05rem;
  margin: 0;
}

body.helm-mode .helm-topbar-actions .btn-sm {
  padding: 3px 7px;
  font-size: 0.66rem;
}

body.helm-mode .helm-risk-grid label,
body.helm-mode .helm-form-grid label {
  font-size: 0.66rem;
}

body.helm-mode .helm-risk-grid input,
body.helm-mode .helm-form-grid input,
body.helm-mode .helm-form-grid select {
  padding: 3px 6px;
  font-size: 0.72rem;
}

body.helm-mode .helm-side-stack > section {
  padding: 4px 6px;
}

body.helm-mode .helm-broker-panel .helm-broker-card p.muted {
  display: none;
}

body.helm-mode .helm-broker-cards {
  grid-template-columns: minmax(0, 1fr);
  gap: 6px;
}

body.helm-mode .helm-broker-cards.helm-broker-cards-single {
  grid-template-columns: minmax(0, 1fr);
}

body.helm-mode .helm-broker-panel-paper .helm-broker-card:not([data-broker="waypoint_paper"]),
body.helm-mode .helm-broker-panel-live .helm-broker-card:not([data-broker="tradovate"]) {
  display: none !important;
}

body.helm-mode .helm-paper-sidebar {
  padding: 4px 0 6px;
  border-bottom: 1px solid rgba(197, 160, 89, 0.18);
  margin-bottom: 4px;
}

body.helm-mode .helm-paper-stats-compact {
  gap: 4px;
}

body.helm-mode .helm-paper-stats-compact div {
  padding: 3px 5px;
}

body.helm-mode .helm-broker-card {
  padding: 6px 8px;
}

body.helm-mode .helm-journal-table {
  font-size: 0.68rem;
}

body.helm-mode .helm-journal-table th,
body.helm-mode .helm-journal-table td {
  padding: 3px 5px;
}

.helm-panel {
  padding: 10px 12px;
  margin: 0;
  min-height: auto;
  overflow: visible;
  display: flex;
  flex-direction: column;
}

/* Top dashboard row only — internal scroll; lower panels stack naturally */
.helm-chart-eye,
.helm-side-stack {
  min-height: 0;
  overflow: hidden;
}
.helm-panel-head {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 6px;
  flex-shrink: 0;
}
.helm-panel-head .eyebrow { margin: 0; font-size: 0.65rem; }
.helm-panel-head-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  align-items: center;
  justify-content: flex-end;
  min-width: 0;
}
.helm-panel-head-actions .btn-sm {
  padding: 3px 7px;
  font-size: 0.64rem;
  white-space: nowrap;
}

.helm-chart-eye {
  border-color: rgba(197,160,89,0.22);
  min-width: 0;
  min-height: 260px;
}
.helm-screen-preview-wrap {
  flex: 1;
  min-height: 0;
  position: relative;
  border-radius: 8px;
  overflow: hidden;
  background: rgba(0,0,0,0.35);
  border: 1px solid rgba(197,160,89,0.12);
}
body.helm-mode .helm-screen-preview-wrap {
  flex: 1 1 auto;
  min-height: 200px;
  max-height: none;
}

.helm-screen-preview {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}
.helm-screen-preview-placeholder {
  position: absolute;
  inset: 0;
  height: auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  padding: 6px;
  text-align: center;
  font-size: 0.68rem;
  color: var(--text-muted);
}
.helm-pirate-placeholder { width: 32px; height: 32px; opacity: 0.85; }

.helm-petes-plan { border-color: rgba(197,160,89,0.35); }
.helm-plan-compact {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px 10px;
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  align-content: start;
}
.helm-plan-cell {
  display: flex;
  flex-direction: column;
  gap: 1px;
  font-size: 0.78rem;
}
.helm-plan-cell span {
  font-size: 0.62rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
}
.helm-plan-cell strong { font-size: 0.82rem; line-height: 1.25; }
.helm-plan-wide { grid-column: 1 / -1; }
.helm-plan-sub {
  font-size: 0.72rem;
  color: var(--text-muted);
  margin: 0;
  line-height: 1.3;
}
.helm-plan-rationale-line {
  font-size: 0.72rem;
  margin: 0;
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.helm-daily-line { margin: 0 0 4px; font-size: 0.72rem; }
.helm-plan-tp { color: #6fdc8c; }
.helm-plan-stop { color: #f08080; }

.helm-side-stack {
  display: flex;
  flex-direction: column;
  gap: 6px;
  border: none;
  background: transparent;
  padding: 0;
  min-width: 0;
  overflow: hidden;
}
.helm-side-stack > section {
  padding: 8px 10px;
  border-radius: var(--radius, 12px);
  background: var(--panel-bg, rgba(12,12,18,0.92));
  border: 1px solid rgba(197,160,89,0.18);
  flex-shrink: 0;
  min-width: 0;
}
.helm-side-stack .helm-live-panel {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.helm-risk-strip { border-color: rgba(197,160,89,0.28); }
.helm-risk-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  margin-top: 4px;
}
.helm-risk-grid label {
  display: flex;
  flex-direction: column;
  gap: 3px;
  font-size: 0.68rem;
  color: var(--text-muted);
}
.helm-risk-grid input {
  padding: 4px 6px;
  border-radius: 6px;
  border: 1px solid rgba(197,160,89,0.25);
  background: rgba(0,0,0,0.25);
  color: var(--text-primary);
  font-size: 0.78rem;
  width: 100%;
  min-width: 0;
  box-sizing: border-box;
}

.helm-toggle-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 8px;
  margin: 2px 0;
}
.helm-check-inline {
  margin: 0;
  font-size: 0.66rem;
  gap: 4px;
  line-height: 1.2;
}
.helm-form-grid-compact {
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  margin: 4px 0;
}
.helm-form-grid-compact label { font-size: 0.68rem; gap: 3px; }
.helm-form-grid-compact input { padding: 5px 8px; font-size: 0.82rem; }
.helm-live-line { margin: 4px 0 0; font-size: 0.72rem; line-height: 1.3; }
.helm-market-vision { margin: 2px 0 0; font-size: 0.68rem; line-height: 1.35; letter-spacing: 0.02em; }
.helm-order-list {
  list-style: none;
  padding: 0;
  margin: 4px 0 0;
  font-size: 0.68rem;
  flex: 1;
  min-height: 0;
  overflow-y: auto;
}
.helm-order-list li { padding: 2px 0; border-bottom: 1px solid rgba(255,255,255,0.05); }

.helm-command-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  justify-content: space-between;
  padding: 5px 8px;
  border-radius: 10px;
  background: rgba(0,0,0,0.22);
  border: 1px solid rgba(197,160,89,0.15);
  flex-shrink: 0;
  min-width: 0;
}
.helm-status-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  flex: 1;
  min-width: 0;
  overflow: visible;
}
.helm-stat {
  padding: 3px 6px;
  border-radius: 6px;
  background: rgba(0,0,0,0.28);
  border: 1px solid rgba(197,160,89,0.12);
  white-space: nowrap;
  max-width: 100%;
}
.helm-stat-priority {
  border-color: rgba(197,160,89,0.35);
  background: rgba(197,160,89,0.12);
}
.helm-priority-pnl {
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 6px;
  margin: 0 0 10px;
  padding: 8px 10px;
  border-radius: 10px;
  border: 1px solid rgba(197,160,89,0.28);
  background: rgba(8, 14, 24, 0.92);
}
.helm-priority-cell {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.helm-priority-cell span {
  font-size: 0.58rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-muted);
}
.helm-priority-cell strong {
  font-size: 0.86rem;
  color: #f0e6c8;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.helm-priority-pnl-day strong,
.helm-priority-pnl-open strong {
  font-variant-numeric: tabular-nums;
}
@media (max-width: 900px) {
  .helm-priority-pnl {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .helm-priority-pnl-day,
  .helm-priority-pnl-open {
    grid-column: span 1;
  }
}
@media (max-width: 560px) {
  .helm-priority-pnl {
    grid-template-columns: 1fr 1fr;
  }
}
.helm-stat span {
  display: inline;
  font-size: 0.54rem;
  margin-right: 3px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-muted);
}
.helm-stat strong {
  font-size: 0.72rem;
  font-weight: 600;
}
.helm-stat strong.helm-on { color: #6fdc8c; }
.helm-actions-inline { margin: 0; flex-shrink: 0; }

.helm-details-panel { padding: 0; overflow: visible; flex-shrink: 0; }
.helm-details-summary {
  cursor: pointer;
  padding: 8px 12px;
  font-weight: 600;
  font-size: 0.75rem;
  letter-spacing: 0.04em;
  list-style: none;
  user-select: none;
}
.helm-details-summary::-webkit-details-marker { display: none; }
.helm-details-body { padding: 0 12px 12px; border-top: 1px solid rgba(255,255,255,0.06); }
.helm-details-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}
.helm-details-section {
  margin-top: 10px;
  padding-top: 0;
  border-top: none;
}
.helm-details-section .eyebrow { font-size: 0.62rem; margin-bottom: 6px; }
.helm-event-log {
  list-style: none;
  padding: 0;
  margin: 0;
  max-height: 140px;
  overflow: auto;
  font-size: 0.72rem;
}

.helm-journal-panel { padding: 0; }
.helm-journal-panel[open] { padding-bottom: 8px; }
.helm-journal-summary-line { font-weight: 400; font-size: 0.72rem; }
.helm-journal-body { padding: 0 12px 4px; display: flex; flex-direction: column; gap: 8px; min-height: 0; max-height: min(28vh, 240px); overflow: auto; }
.helm-journal-stats-grid {
  display: grid;
  grid-template-columns: 1fr 1fr minmax(140px, 0.75fr);
  gap: 8px 12px;
}
.helm-journal-stats-block .eyebrow { font-size: 0.62rem; margin: 0 0 4px; }
.helm-journal-stat-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}
.helm-journal-pill {
  display: inline-flex;
  flex-direction: column;
  gap: 1px;
  padding: 4px 8px;
  border-radius: 6px;
  background: rgba(0,0,0,0.22);
  border: 1px solid rgba(197,160,89,0.12);
  font-size: 0.68rem;
  min-width: 52px;
}
.helm-journal-pill span {
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  font-size: 0.58rem;
}
.helm-journal-pill strong { font-size: 0.78rem; line-height: 1.2; }
.helm-journal-empty { font-size: 0.72rem; }
.helm-journal-exit-list {
  list-style: none;
  margin: 0;
  padding: 0;
  font-size: 0.72rem;
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.helm-journal-exit-list li {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  padding: 2px 0;
  border-bottom: 1px solid rgba(255,255,255,0.05);
}
.helm-journal-exit-label { color: var(--text-primary); }
.helm-journal-exit-count { color: var(--text-muted); white-space: nowrap; }
.helm-journal-table-wrap {
  max-height: 160px;
  overflow: auto;
  border: 1px solid rgba(197,160,89,0.12);
  border-radius: 6px;
}

.helm-governance-panel { grid-column: 1 / -1; padding: 0; }
.helm-governance-body { padding: 0 12px 10px; display: flex; flex-direction: column; gap: 10px; }
.helm-governance-proposals { display: flex; flex-direction: column; gap: 10px; }
.helm-governance-card {
  border: 1px solid rgba(197,160,89,0.18);
  border-radius: 8px;
  padding: 10px 12px;
  background: rgba(0,0,0,0.15);
}
.helm-governance-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 8px;
}
.helm-governance-card-head h4 { margin: 0; font-size: 0.85rem; }
.helm-governance-badge {
  font-size: 0.62rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--accent-gold, #c5a059);
  border: 1px solid rgba(197,160,89,0.35);
  border-radius: 999px;
  padding: 2px 8px;
}
.helm-governance-change {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-bottom: 8px;
  font-size: 0.75rem;
}
.helm-governance-change span { display: block; font-size: 0.62rem; margin-bottom: 2px; }
.helm-governance-proposed { color: var(--accent-gold, #c5a059); }
.helm-governance-rationale { font-size: 0.75rem; margin: 0 0 8px; line-height: 1.4; }
.helm-governance-section { margin-bottom: 8px; }
.helm-governance-section .eyebrow { margin-bottom: 4px; font-size: 0.62rem; }
.helm-governance-trades {
  margin: 0;
  padding-left: 16px;
  font-size: 0.72rem;
  color: var(--text-muted);
}
.helm-governance-risk { font-size: 0.72rem; margin: 0; }
.helm-governance-risk-high { color: #e8a060; }
.helm-governance-actions { display: flex; flex-wrap: wrap; gap: 6px; }
.helm-governance-versions summary { cursor: pointer; font-size: 0.72rem; margin-bottom: 6px; }
.helm-governance-version-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 0.72rem;
}
.helm-governance-version-list li {
  display: flex;
  align-items: center;
  gap: 8px;
  justify-content: space-between;
}
.helm-governance-paper-note { margin-bottom: 8px; }

.helm-tradovate-badge {
  font-size: 0.62rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  border-radius: 999px;
  padding: 2px 8px;
  border: 1px solid rgba(197,160,89,0.35);
  color: var(--text-muted);
}
.helm-tradovate-badge[data-status="CONNECTED"],
.helm-tradovate-badge[data-status="LIVE_DATA_ACTIVE"] {
  color: #7ec89a;
  border-color: rgba(126,200,154,0.4);
}
.helm-tradovate-badge[data-status="AUTH_FAILED"] {
  color: #e07070;
  border-color: rgba(224,112,112,0.4);
}
.helm-tradovate-badge[data-status="TOKEN_REFRESHING"] {
  color: var(--accent-gold, #c5a059);
}
.helm-tradovate-badge[data-status="MARKET_DATA_UNAVAILABLE"] {
  color: #e8a060;
}
.helm-tradovate-warning {
  font-size: 0.72rem;
  color: #e8a060;
  margin: 6px 0 0;
  line-height: 1.4;
}
.helm-tradovate-manual { margin: 8px 0; font-size: 0.75rem; }
.helm-panel-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }

.helm-journal-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.72rem;
}
.helm-journal-table th,
.helm-journal-table td {
  padding: 5px 8px;
  text-align: left;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  white-space: nowrap;
}
.helm-journal-table th {
  position: sticky;
  top: 0;
  background: rgba(12,18,28,0.95);
  color: var(--text-muted);
  font-size: 0.62rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  z-index: 1;
}
.helm-journal-table td:last-child {
  max-width: 140px;
  overflow: hidden;
  text-overflow: ellipsis;
}
.helm-journal-empty-row { text-align: center; padding: 12px !important; }
.helm-journal-dir-long { color: #6ecf8a; }
.helm-journal-dir-short { color: #f08080; }
.helm-pnl-win { color: #6ecf8a; }
.helm-pnl-loss { color: #f08080; }

.helm-header { display: flex; flex-wrap: wrap; gap: 20px; justify-content: space-between; align-items: flex-start; margin-bottom: 16px; }
.helm-layout { display: flex; flex-direction: column; gap: 14px; }

body.helm-mode .panel-rail,
body.helm-mode #instrumentRail { display: none !important; }
body.helm-mode #tradingHubWidget,
body.helm-mode .trading-hub-widget {
  display: none !important;
  visibility: hidden !important;
  height: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
  overflow: hidden !important;
  border: none !important;
}

/* Live Deck — restore full sidebar; never bleed helm compact rules (Hub uses trade-log-mode) */
.training-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 12px;
}

.store-grid {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.store-category-block {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.store-category-title {
  margin: 0;
  font-size: 0.82rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold-soft);
  padding-bottom: 4px;
  border-bottom: 1px solid rgba(197, 160, 89, 0.22);
}

.store-category-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 12px;
}

.store-progress-strip {
  grid-column: 1 / -1;
}

/* Swagger Store — store only (no Pete, no analysis rail) */
body.store-mode #peteAvatarPanel,
body.store-mode #instrumentRail,
body.store-mode .deck-bottom {
  display: none !important;
}

/* Waypoint Social — dedicated social destination (hide trading/Pete side panels) */
body.social-mode #peteAvatarPanel,
body.social-mode #instrumentRail,
body.social-mode .deck-bottom {
  display: none !important;
}

body.social-mode .command-deck-layout {
  min-height: 0;
  max-width: 100vw;
  overflow: hidden;
  height: 100vh;
  height: 100dvh;
}

body.social-mode .deck-persistent-shell {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) !important;
  grid-template-rows: minmax(0, 1fr) !important;
  max-width: 100% !important;
  width: 100% !important;
  height: calc(100vh - var(--desk-header-h, 64px)) !important;
  height: calc(100dvh - var(--desk-header-h, 64px)) !important;
  max-height: calc(100vh - var(--desk-header-h, 64px)) !important;
  max-height: calc(100dvh - var(--desk-header-h, 64px)) !important;
  min-height: 0 !important;
  padding: 0 !important;
  align-items: stretch !important;
  gap: 0 !important;
  min-width: 0;
  overflow: hidden;
  box-sizing: border-box;
  margin: 0 !important;
}

body.social-mode .deck-workspace {
  grid-row: 1 !important;
  grid-column: 1 !important;
  min-height: 0 !important;
  min-width: 0 !important;
  height: 100% !important;
  max-height: 100% !important;
  overflow: hidden !important;
  display: flex !important;
  flex-direction: column !important;
  background:
    radial-gradient(1200px 600px at 12% -10%, rgba(30, 155, 255, 0.12), transparent 55%),
    radial-gradient(900px 500px at 88% 0%, rgba(30, 155, 255, 0.06), transparent 50%),
    linear-gradient(180deg, #070b12 0%, #080d14 45%, #05080e 100%);
}

body.social-mode .deck-workspace > .deck-view:not([hidden]) {
  flex: 1 1 auto;
  min-height: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

body.social-mode .social-shell {
  flex: 1 1 auto;
  min-height: 0;
  max-width: none;
  width: 100%;
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

body.store-mode .deck-persistent-shell {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) !important;
  grid-template-rows: minmax(0, 1fr) !important;
  max-width: 100% !important;
  width: 100% !important;
  height: calc(100vh - 52px) !important;
  max-height: calc(100vh - 52px) !important;
  padding: 8px 12px !important;
  margin: 0 !important;
  gap: 0 !important;
  overflow: hidden;
}

body.store-mode .deck-workspace {
  grid-column: 1 !important;
  grid-row: 1 !important;
  min-height: 0 !important;
  height: 100% !important;
  overflow: auto !important;
}

body.store-mode .store-only-view {
  max-width: 1280px;
  margin: 0 auto;
  padding: 8px 16px 24px;
}

body.store-mode .store-only-header .muted {
  display: none;
}

/* Training Portal — full workspace command screen */
body.training-portal-mode #peteAvatarPanel,
body.training-portal-mode #instrumentRail,
body.training-portal-mode .deck-bottom {
  display: none !important;
}

body.training-portal-mode .command-deck-layout {
  min-height: 0;
  height: 100vh;
  overflow: hidden;
}

body.training-portal-mode .deck-persistent-shell {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) !important;
  grid-template-rows: minmax(0, 1fr) !important;
  height: calc(100vh - var(--desk-header-h, 64px)) !important;
  max-height: calc(100vh - var(--desk-header-h, 64px)) !important;
  padding: 8px 14px 10px !important;
  margin: 0 !important;
  gap: 0 !important;
  overflow: hidden;
}

body.training-portal-mode .deck-workspace {
  grid-column: 1 !important;
  grid-row: 1 !important;
  min-height: 0 !important;
  height: 100% !important;
  overflow: hidden !important;
}

body.training-portal-mode .portal-view {
  height: 100%;
  max-height: 100%;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  min-height: 0;
}

body.training-portal-mode .portal-view-header {
  flex-shrink: 0;
}

body.training-portal-mode .training-grid {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
}

/* Competitive Intel — full workspace command screen */
body.competitive-intel-mode #peteAvatarPanel,
body.competitive-intel-mode #instrumentRail,
body.competitive-intel-mode .deck-bottom {
  display: none !important;
}

body.competitive-intel-mode .command-deck-layout {
  min-height: 0;
  height: 100vh;
  height: 100dvh;
  overflow: hidden;
}

body.competitive-intel-mode .deck-persistent-shell {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) !important;
  grid-template-rows: minmax(0, 1fr) !important;
  height: calc(100vh - var(--desk-header-h, 64px)) !important;
  height: calc(100dvh - var(--desk-header-h, 64px)) !important;
  max-height: calc(100dvh - var(--desk-header-h, 64px)) !important;
  padding: 6px 12px 8px !important;
  margin: 0 !important;
  gap: 0 !important;
  overflow: hidden;
}

body.competitive-intel-mode .deck-workspace {
  grid-column: 1 !important;
  grid-row: 1 !important;
  min-height: 0 !important;
  height: 100% !important;
  overflow: hidden !important;
}

/* One scroll surface for the whole portal — no nested “tiny box” on the card grid */
body.competitive-intel-mode .competitive-intel-view {
  height: 100%;
  max-height: 100%;
  overflow-x: hidden;
  overflow-y: auto;
  overscroll-behavior: contain;
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: 0;
  max-width: min(1280px, 100%);
  margin: 0 auto;
  width: 100%;
  padding: 4px 4px 16px;
  box-sizing: border-box;
}

body.competitive-intel-mode .portal-view-header {
  flex-shrink: 0;
  margin-bottom: 4px;
  padding-bottom: 8px;
}

body.competitive-intel-mode .ci-toolbar {
  flex-shrink: 0;
  margin-bottom: 4px;
  position: sticky;
  top: 0;
  z-index: 5;
  padding: 8px 8px 10px;
  border-radius: 10px;
  background: rgba(7, 14, 22, 0.94);
  border: 1px solid rgba(201, 162, 39, 0.16);
  backdrop-filter: blur(8px);
}

body.competitive-intel-mode .ci-grid {
  flex: 0 0 auto;
  min-height: 0;
  overflow: visible;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 12px;
  padding-bottom: 4px;
}

body.competitive-intel-mode .ci-companies {
  flex-shrink: 0;
  margin-top: 4px;
}

/* Development portal — full workspace R&D screen */
body.development-mode #peteAvatarPanel,
body.development-mode #instrumentRail,
body.development-mode .deck-bottom {
  display: none !important;
}

body.development-mode .command-deck-layout {
  min-height: 0;
  height: 100vh;
  height: 100dvh;
  overflow: hidden;
}

body.development-mode .deck-persistent-shell {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) !important;
  grid-template-rows: minmax(0, 1fr) !important;
  height: calc(100vh - var(--desk-header-h, 64px)) !important;
  height: calc(100dvh - var(--desk-header-h, 64px)) !important;
  max-height: calc(100dvh - var(--desk-header-h, 64px)) !important;
  padding: 6px 12px 8px !important;
  margin: 0 !important;
  gap: 0 !important;
  overflow: hidden;
}

body.development-mode .deck-workspace {
  grid-column: 1 !important;
  grid-row: 1 !important;
  min-height: 0 !important;
  height: 100% !important;
  overflow: hidden !important;
}

body.development-mode .development-view {
  height: 100%;
  min-height: 0;
  overflow-y: auto;
  overflow-x: hidden;
}

/* Admin Hub embedded in Live Deck */
body.admin-hub-mode #peteAvatarPanel,
body.admin-hub-mode #instrumentRail,
body.admin-hub-mode .deck-bottom,
body.admin-hub-mode #tradingHubWidget {
  display: none !important;
}

body.admin-hub-mode .command-deck-layout {
  min-height: 0;
  max-width: 100vw;
  overflow: hidden;
  height: 100vh;
  height: 100dvh;
}

body.admin-hub-mode .deck-persistent-shell {
  display: grid !important;
  grid-template-columns: minmax(0, 1fr) !important;
  grid-template-rows: minmax(0, 1fr) !important;
  max-width: none !important;
  width: 100% !important;
  height: calc(100vh - var(--desk-header-h, 64px)) !important;
  height: calc(100dvh - var(--desk-header-h, 64px)) !important;
  max-height: calc(100vh - var(--desk-header-h, 64px)) !important;
  max-height: calc(100dvh - var(--desk-header-h, 64px)) !important;
  padding: 6px 10px 8px !important;
  margin: 0 !important;
  gap: 0 !important;
  overflow: hidden !important;
  align-items: stretch !important;
  box-sizing: border-box;
}

body.admin-hub-mode .deck-workspace {
  grid-column: 1 !important;
  grid-row: 1 !important;
  min-height: 0 !important;
  min-width: 0 !important;
  height: 100% !important;
  max-height: 100% !important;
  overflow: hidden !important;
  display: flex !important;
  flex-direction: column !important;
}

body.admin-hub-mode .admin-hub-shell,
body.admin-hub-mode .deck-workspace > .admin-hub-shell:not([hidden]) {
  flex: 1 1 auto;
  min-height: 0;
  height: 100%;
  width: 100%;
  max-width: none !important;
  margin: 0 !important;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

body.admin-hub-mode .admin-app-embedded {
  flex: 1 1 auto;
  min-height: 0;
  height: 100%;
  width: 100%;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

body.admin-hub-mode .admin-app-embedded .admin-layout {
  flex: 1 1 auto;
  min-height: 0;
}

body:not(.helm-mode):not(.trade-log-mode):not(.store-mode):not(.training-portal-mode):not(.competitive-intel-mode):not(.development-mode):not(.admin-hub-mode):not(.social-mode) .deck-persistent-shell {
  display: grid !important;
  grid-template-columns: minmax(260px, 0.85fr) minmax(360px, 1.4fr) minmax(280px, 0.95fr);
  grid-template-rows: 1fr auto;
  height: auto;
  max-height: none;
  padding: 16px 20px 24px;
  gap: 16px;
}

body:not(.helm-mode):not(.trade-log-mode):not(.store-mode):not(.training-portal-mode):not(.competitive-intel-mode):not(.development-mode):not(.admin-hub-mode):not(.social-mode) .deck-workspace {
  grid-row: auto;
  min-height: 420px;
  height: auto;
  max-height: none;
  overflow: visible;
}

body:not(.helm-mode):not(.trade-log-mode):not(.store-mode):not(.training-portal-mode):not(.competitive-intel-mode):not(.development-mode):not(.admin-hub-mode):not(.social-mode) .panel-avatar {
  display: block !important;
  position: relative;
  top: auto;
  max-height: calc(100vh - 96px);
  overflow-y: auto;
  overflow-x: hidden;
  width: auto;
  padding: inherit;
  grid-template-columns: none;
  grid-template-areas: none;
  align-items: stretch;
  gap: normal;
  border: none;
  background: transparent;
  border-radius: 0;
}

body:not(.helm-mode):not(.trade-log-mode):not(.store-mode):not(.training-portal-mode):not(.competitive-intel-mode):not(.development-mode):not(.admin-hub-mode):not(.social-mode) .panel-avatar .eyebrow {
  display: block;
}

body:not(.helm-mode):not(.trade-log-mode):not(.store-mode):not(.training-portal-mode):not(.competitive-intel-mode):not(.development-mode):not(.admin-hub-mode):not(.social-mode) .pete-mini-brainscan-frame {
  height: min(268px, 34vh);
  max-height: 300px;
  min-height: 220px;
}

body:not(.helm-mode):not(.trade-log-mode):not(.store-mode):not(.training-portal-mode):not(.competitive-intel-mode):not(.development-mode):not(.admin-hub-mode):not(.social-mode) .panel-avatar .panel-title {
  margin: inherit;
  font-size: inherit;
  line-height: inherit;
}

body:not(.helm-mode):not(.trade-log-mode):not(.store-mode):not(.training-portal-mode):not(.competitive-intel-mode):not(.development-mode):not(.admin-hub-mode):not(.social-mode) .panel-avatar .avatar-wrap {
  width: 100%;
  flex: none;
  margin-bottom: 0;
  grid-area: auto;
  max-width: none;
  min-width: 0;
}

body:not(.helm-mode):not(.trade-log-mode):not(.store-mode):not(.training-portal-mode):not(.competitive-intel-mode):not(.development-mode):not(.admin-hub-mode):not(.social-mode) .panel-avatar .avatar-view {
  min-height: 180px;
  max-height: none;
  aspect-ratio: 16 / 10;
  object-fit: contain;
  border-radius: 0;
}

body:not(.helm-mode):not(.trade-log-mode):not(.store-mode):not(.training-portal-mode):not(.competitive-intel-mode):not(.development-mode):not(.admin-hub-mode):not(.social-mode) .panel-avatar .panel-title,
body:not(.helm-mode):not(.trade-log-mode):not(.store-mode):not(.training-portal-mode):not(.competitive-intel-mode):not(.development-mode):not(.admin-hub-mode):not(.social-mode) .panel-avatar .pete-status,
body:not(.helm-mode):not(.trade-log-mode):not(.store-mode):not(.training-portal-mode):not(.competitive-intel-mode):not(.development-mode):not(.admin-hub-mode):not(.social-mode) .panel-avatar .button-row {
  grid-area: auto;
  align-self: auto;
  max-width: none;
}

body:not(.helm-mode):not(.trade-log-mode):not(.store-mode):not(.training-portal-mode):not(.competitive-intel-mode):not(.development-mode):not(.admin-hub-mode):not(.social-mode) .panel-avatar .mode-chips {
  display: flex;
}

body:not(.helm-mode):not(.trade-log-mode):not(.store-mode):not(.training-portal-mode):not(.competitive-intel-mode):not(.development-mode):not(.admin-hub-mode):not(.social-mode) .panel-avatar .button-row {
  flex-wrap: wrap;
  justify-content: flex-start;
  margin-top: inherit;
}

body:not(.helm-mode):not(.trade-log-mode):not(.store-mode):not(.training-portal-mode):not(.competitive-intel-mode):not(.development-mode):not(.admin-hub-mode):not(.social-mode) .panel-avatar .button-row .btn {
  padding: inherit;
  font-size: inherit;
  white-space: normal;
}

body:not(.helm-mode) #viewHelm {
  display: none !important;
}

body:not(.helm-mode):not(.trade-log-mode):not(.store-mode):not(.training-portal-mode):not(.competitive-intel-mode):not(.development-mode):not(.admin-hub-mode):not(.social-mode) .deck-bottom {
  display: grid;
}

body:not(.helm-mode):not(.trade-log-mode):not(.store-mode):not(.training-portal-mode):not(.competitive-intel-mode):not(.development-mode):not(.admin-hub-mode):not(.social-mode) #tradingHubWidget {
  display: none !important;
  visibility: hidden !important;
  height: 0 !important;
  overflow: hidden !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
}

#peteAvatarPanel #tradingHubWidget,
#tradingHubWidget[hidden] {
  display: none !important;
  visibility: hidden !important;
  height: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 0 !important;
}

.helm-broker-grid {
  grid-template-columns: 1fr;
}

.helm-paper-banner {
  grid-column: 1 / -1;
  background: linear-gradient(90deg, #1a3a2a 0%, #142820 100%);
  border: 1px solid #3a6a4a;
  border-radius: 8px;
  padding: 0.75rem 1rem;
  margin: 0 0 0.75rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
  align-items: center;
  color: #b8e8c8;
  font-size: 0.85rem;
}

.helm-testing-notice {
  grid-column: 1 / -1;
  margin: 0 0 0.75rem;
  padding: 0.75rem 1rem;
  border-radius: 8px;
  border: 1px solid rgba(197, 160, 89, 0.45);
  background: linear-gradient(90deg, rgba(60, 42, 18, 0.9), rgba(28, 22, 14, 0.95));
  color: #f0d9a8;
  font-size: 0.88rem;
  line-height: 1.4;
}

.helm-paper-banner strong {
  color: #7fd4a0;
  letter-spacing: 0.05em;
}

.helm-broker-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1rem;
  padding: 0.5rem 0;
}

.helm-broker-card {
  background: #14100c;
  border: 1px solid #2a2218;
  border-radius: 8px;
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.helm-broker-card-selected {
  border-color: #c5a059;
  box-shadow: 0 0 0 1px rgba(197, 160, 89, 0.35);
}

.helm-broker-card-disabled {
  opacity: 0.55;
}

.helm-broker-card-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.5rem;
}

.helm-broker-card-head h3 {
  margin: 0;
  font-size: 1rem;
  color: #e8dcc8;
}

.helm-broker-status {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #c5a059;
}

.helm-broker-selected-badge {
  font-size: 0.75rem;
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
  background: #2a2218;
  color: #c5a059;
}

.helm-paper-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem;
  font-size: 0.85rem;
}

.helm-paper-stats div {
  background: #0f0c08;
  border-radius: 4px;
  padding: 0.4rem 0.5rem;
}

.helm-paper-stats span {
  display: block;
  font-size: 0.65rem;
  color: #a89878;
  text-transform: uppercase;
}

.helm-broker-card-paper.helm-broker-card-selected {
  border-color: #3a6a4a;
  box-shadow: 0 0 0 1px rgba(127, 212, 160, 0.25);
}

.helm-live-position-panel {
  margin-top: 0.75rem;
  padding-top: 0.75rem;
  border-top: 1px solid #2a2218;
}

.helm-live-position-body {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
  gap: 0.5rem;
  font-size: 0.85rem;
  margin: 0.5rem 0;
}

.helm-live-position-body .helm-pos-cell {
  background: #0f0c08;
  border-radius: 4px;
  padding: 0.4rem 0.5rem;
}

.helm-live-position-body .helm-pos-cell span {
  display: block;
  font-size: 0.65rem;
  color: #a89878;
  text-transform: uppercase;
}

.helm-live-position-body.helm-pos-open {
  color: #e8dcc8;
}

.helm-pete-performance {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-top: 0.5rem;
}

.helm-perf-pill {
  font-size: 0.72rem;
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
  background: #1a1510;
  border: 1px solid #2a2218;
}

.helm-perf-pill strong {
  color: #c5a059;
  margin-left: 0.25rem;
}

.helm-journal-broker-label {
  color: #c5a059;
  font-weight: 600;
}

.helm-broker-panel,
.helm-sms-panel,
.helm-journal-panel,
.helm-details-panel,
.helm-options-paper-section,
.helm-governance-panel {
  min-height: 0;
  overflow: hidden;
  align-self: stretch;
  width: 100%;
  position: relative;
  isolation: isolate;
}

.helm-command-bar {
  flex-shrink: 0;
}

.helm-sms-panel .helm-details-section,
.helm-broker-panel .helm-details-body {
  overflow: visible;
}

.helm-form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 6px 0; }
.helm-form-grid label { display: flex; flex-direction: column; gap: 4px; font-size: 0.72rem; color: var(--text-muted); }
.helm-form-grid input, .helm-form-grid select { padding: 6px 8px; border-radius: 6px; border: 1px solid rgba(197,160,89,0.25); background: rgba(0,0,0,0.25); color: var(--text-primary); font-size: 0.82rem; }
.helm-actions { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 6px; }
.helm-meta { margin-top: 4px; font-size: 0.72rem; }
.helm-switch-label { display: inline-flex; align-items: center; gap: 8px; cursor: pointer; font-weight: 600; font-size: 0.78rem; }
.helm-switch-label input { position: absolute; opacity: 0; width: 0; height: 0; }
.helm-switch-ui { width: 44px; height: 24px; border-radius: 999px; background: rgba(255,255,255,0.12); position: relative; transition: background 0.2s; flex-shrink: 0; }
.helm-switch-ui::after { content: ""; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; transition: transform 0.2s; }
.helm-switch-label input:checked + .helm-switch-ui { background: var(--wtc-gold, #c5a059); }
.helm-switch-label input:checked + .helm-switch-ui::after { transform: translateX(20px); }
.helm-status-line { margin: 2px 0 0; font-size: 0.72rem; line-height: 1.3; max-width: none; }
.helm-check { display: flex; gap: 6px; align-items: center; font-size: 0.78rem; }
.helm-event-log li { padding: 4px 0; border-bottom: 1px solid rgba(255,255,255,0.06); }
.helm-event-type { color: var(--wtc-gold, #c5a059); font-size: 0.68rem; margin-right: 4px; }

@media (max-width: 1200px) {
  .helm-topbar {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    grid-template-rows: auto auto;
  }
  .helm-topbar-brand { grid-column: 1; }
  .helm-topbar-actions { grid-column: 2; grid-row: 1; }
  .helm-topbar-analysis { grid-column: 1 / -1; grid-row: 2; white-space: normal; }
  .helm-dashboard {
    grid-template-columns: minmax(0, 1fr);
    grid-template-rows: minmax(0, 34vh) auto minmax(0, auto) minmax(0, auto);
    align-content: stretch;
    overflow: hidden;
  }
  .helm-chart-eye { grid-column: 1; grid-row: 1; }
  .helm-side-stack { grid-column: 1; grid-row: 2; flex-direction: row; max-height: 28vh; overflow: auto; }
  .helm-side-stack > section { flex: 1; min-width: 0; }
  .helm-command-bar { grid-row: 3; }
  .helm-broker-panel { grid-row: 4; }
  .helm-journal-panel { grid-row: 5; }
  .helm-sms-panel,
  .helm-options-paper-section,
  .helm-governance-panel,
  .helm-details-panel { display: none !important; }
  .helm-details-grid { grid-template-columns: 1fr; }
}
@media (max-width: 900px) {
  body.helm-mode .deck-persistent-shell { grid-template-columns: 1fr; }
  body.helm-mode .panel-avatar {
    grid-template-columns: minmax(0, 1fr);
    grid-template-areas:
      "video"
      "plan"
      "status"
      "actions";
    row-gap: 8px;
  }
  body.helm-mode .helm-petes-plan-dock .helm-plan-compact {
    max-height: none;
  }
  body.helm-mode .panel-avatar .avatar-wrap {
    max-width: none;
  }
  body.helm-mode .panel-avatar .avatar-view {
    min-height: 140px;
    max-height: 180px;
  }
  body.helm-mode .panel-avatar .button-row {
    justify-content: flex-start;
    max-width: none;
  }
  .helm-journal-stats-grid { grid-template-columns: 1fr; }
  .helm-dashboard {
    grid-template-columns: 1fr;
    grid-template-rows: minmax(0, 30vh) auto minmax(0, auto) minmax(0, auto);
    align-content: stretch;
    overflow: hidden;
  }
  .helm-chart-eye { grid-column: 1; grid-row: 1; }
  .helm-side-stack { grid-column: 1; grid-row: 2; flex-direction: column; max-height: 26vh; overflow: auto; }
  .helm-command-bar { grid-row: 3; }
  .helm-broker-panel { grid-row: 4; }
  .helm-journal-panel { grid-row: 5; }
  .helm-sms-panel,
  .helm-options-paper-section,
  .helm-governance-panel,
  .helm-details-panel { display: none !important; }
}

.nav-rail-btn-helm { color: var(--wtc-gold, #c5a059) !important; }

.nav-rail-btn-pirate {
  width: 58px;
  min-height: 66px;
  gap: 3px;
  padding: 8px 4px 6px;
  border: 1px solid rgba(232, 192, 104, 0.45) !important;
  background: linear-gradient(165deg, rgba(197, 160, 89, 0.12) 0%, rgba(8, 6, 4, 0.88) 100%) !important;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.35);
}

.nav-rail-pete-art,
.nav-rail-pete-photo,
.nav-rail-pirate-svg {
  width: 34px;
  height: 34px;
  display: block;
  object-fit: cover;
  border-radius: 8px;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.45));
}

.nav-rail-pete-photo {
  border: 1px solid rgba(232, 192, 104, 0.45);
}

.nav-rail-social-art {
  width: 34px;
  height: 34px;
  display: block;
  object-fit: contain;
  border-radius: 8px;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.45));
  background: transparent;
  /* Canonical orientation — upright blue W only (no rotate/flip) */
  transform: none;
  rotate: none;
  scale: none;
}

.nav-rail-btn-social {
  position: relative;
}
.nav-rail-social-badge {
  position: absolute;
  top: 4px;
  right: 6px;
  min-width: 16px;
  height: 16px;
  padding: 0 4px;
  border-radius: 999px;
  background: #d1242f;
  color: #fff;
  font-size: 0.58rem;
  font-weight: 800;
  line-height: 16px;
  text-align: center;
  z-index: 2;
  box-shadow: 0 0 0 2px #071018;
}
.nav-rail-social-badge[hidden] { display: none !important; }

.nav-rail-btn-social:hover .nav-rail-social-art,
.nav-rail-btn-social.active .nav-rail-social-art,
.nav-rail-btn-social.nav-rail-pressed .nav-rail-social-art {
  transform: scale(1.08);
  filter: drop-shadow(0 3px 8px rgba(0, 0, 0, 0.5)) drop-shadow(0 0 8px rgba(30, 155, 255, 0.55));
}

.nav-rail-pirate-label {
  font-size: 0.56rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #f0d080;
  line-height: 1;
}

.nav-rail-btn-pirate:hover,
.nav-rail-btn-pirate.active {
  transform: translateY(-2px);
  border-color: rgba(232, 192, 104, 0.65) !important;
}

.nav-rail-btn-pirate:hover .nav-rail-pete-art,
.nav-rail-btn-pirate:hover .nav-rail-pete-photo,
.nav-rail-btn-pirate.active .nav-rail-pete-art,
.nav-rail-btn-pirate.active .nav-rail-pete-photo,
.nav-rail-btn-pirate.nav-rail-pressed .nav-rail-pete-art,
.nav-rail-btn-pirate.nav-rail-pressed .nav-rail-pete-photo {
  transform: scale(1.04);
  transition: transform 0.15s ease;
}

/* Pete Takes the Helm — full scene framed (8s), ~50% pull-back so desk + UI text stay visible */
.helm-takeover-overlay {
  --helm-takeover-duration: 8s;
  --helm-scene-width: min(1080px, 62vw, calc(56vh * 4 / 3));
  position: fixed;
  inset: 0;
  z-index: 12000;
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
  overflow: hidden;
  background: #04080c;
}

.helm-takeover-overlay:not(.helm-takeover-active) {
  display: none !important;
  pointer-events: none !important;
}

.helm-takeover-overlay[hidden] {
  display: none !important;
}

.helm-takeover-overlay.helm-takeover-active {
  opacity: 1;
  visibility: visible;
  animation: helmTakeoverFade var(--helm-takeover-duration) ease forwards;
}

.helm-takeover-backdrop {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 70% 55% at 50% 42%, rgba(197, 160, 89, 0.08) 0%, transparent 62%),
    radial-gradient(ellipse 100% 100% at 50% 50%, rgba(10, 25, 33, 0.35) 0%, rgba(4, 8, 12, 0.98) 100%);
}

.helm-takeover-stage {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: clamp(12px, 2vh, 20px);
  padding: clamp(12px, 2vh, 24px);
  box-sizing: border-box;
}

.helm-takeover-scene-frame {
  margin: 0;
  width: var(--helm-scene-width);
  max-height: 56vh;
  aspect-ratio: 4 / 3;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid rgba(197, 160, 89, 0.22);
  box-shadow:
    0 20px 60px rgba(0, 0, 0, 0.55),
    0 0 0 1px rgba(255, 255, 255, 0.04) inset;
  opacity: 0;
  transform: scale(0.94);
}

.helm-takeover-overlay.helm-takeover-active .helm-takeover-scene-frame {
  animation: helmFrameReveal var(--helm-takeover-duration) cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

.helm-takeover-scene-art {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center center;
  display: block;
  transform: scale(1);
  filter: brightness(0.92) saturate(1.05);
}

.helm-takeover-overlay.helm-takeover-active .helm-takeover-scene-art {
  animation: helmSceneKenBurns var(--helm-takeover-duration) ease forwards;
}

.helm-takeover-caption {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 0 16px;
  text-align: center;
  pointer-events: none;
  max-width: var(--helm-scene-width);
}

.helm-takeover-line {
  margin: 0;
  padding: 8px 18px;
  border-radius: 12px;
  font-family: var(--font-display, Georgia, serif);
  font-size: clamp(0.88rem, 1.6vw, 1.15rem);
  font-weight: 700;
  color: #1a1208;
  letter-spacing: 0.02em;
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.96) 0%, rgba(245, 235, 210, 0.94) 100%);
  border: 1px solid rgba(197, 160, 89, 0.75);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
  transform: translateY(8px);
  opacity: 0;
}

.helm-takeover-overlay.helm-takeover-active .helm-takeover-line {
  animation: helmLinePop var(--helm-takeover-duration) cubic-bezier(0.34, 1.4, 0.64, 1) forwards;
}

.helm-takeover-tagline {
  margin: 0;
  font-size: clamp(0.58rem, 1.1vw, 0.68rem);
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: rgba(232, 200, 120, 0.92);
  text-shadow: 0 1px 10px rgba(0, 0, 0, 0.75);
  transform: translateY(6px);
  opacity: 0;
}

.helm-takeover-overlay.helm-takeover-active .helm-takeover-tagline {
  animation: helmTaglineFade var(--helm-takeover-duration) ease forwards;
}

@media (max-width: 900px) {
  .helm-takeover-overlay {
    --helm-scene-width: min(94vw, calc(42vh * 4 / 3));
  }
}

@media (min-width: 2200px) {
  .helm-takeover-overlay {
    --helm-scene-width: min(1280px, 58vw, calc(62vh * 4 / 3));
  }

  .helm-takeover-scene-frame {
    max-height: 62vh;
  }
}

@keyframes helmTakeoverFade {
  0% { opacity: 0; }
  4% { opacity: 1; }
  92% { opacity: 1; }
  100% { opacity: 0; visibility: hidden; }
}

@keyframes helmFrameReveal {
  0% { opacity: 0; transform: scale(0.9); }
  8% { opacity: 1; transform: scale(0.98); }
  88% { opacity: 1; transform: scale(1); }
  100% { opacity: 0; transform: scale(0.98); }
}

@keyframes helmSceneKenBurns {
  0%, 100% { transform: scale(1); filter: brightness(0.88) saturate(1.02); }
  12%, 88% { transform: scale(1); filter: brightness(1) saturate(1.06); }
}

@keyframes helmLinePop {
  0%, 10% { opacity: 0; transform: translateY(12px) scale(0.94); }
  18% { opacity: 1; transform: translateY(0) scale(1); }
  88% { opacity: 1; transform: translateY(0) scale(1); }
  100% { opacity: 0; transform: translateY(-4px) scale(0.98); }
}

@keyframes helmTaglineFade {
  0%, 14% { opacity: 0; transform: translateY(6px); }
  22% { opacity: 1; transform: translateY(0); }
  88% { opacity: 1; }
  100% { opacity: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .helm-takeover-overlay.helm-takeover-active,
  .helm-takeover-overlay.helm-takeover-active .helm-takeover-scene-frame,
  .helm-takeover-overlay.helm-takeover-active .helm-takeover-scene-art,
  .helm-takeover-overlay.helm-takeover-active .helm-takeover-line,
  .helm-takeover-overlay.helm-takeover-active .helm-takeover-tagline {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}

/* Week at a glance + live news */
.week-at-glance-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
}

.week-at-glance-vertical {
  grid-template-columns: 1fr;
}

.week-day-card {
  min-width: 0;
  padding: 8px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.02);
  font-size: 0.72rem;
}

.week-day-card.is-today {
  border-color: rgba(201, 162, 39, 0.45);
  background: rgba(201, 162, 39, 0.06);
}

.week-day-card header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 4px;
  margin-bottom: 6px;
}

.week-today-tag {
  font-size: 0.58rem;
  letter-spacing: 0.08em;
  color: var(--gold);
}

.week-day-card ul {
  margin: 0;
  padding-left: 14px;
}

.week-day-card li {
  margin-bottom: 4px;
  line-height: 1.35;
}

.week-day-card time {
  color: var(--gold-soft);
  margin-right: 4px;
}

.week-glance-compact {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  font-size: 0.72rem;
}

.radar-live-news {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.radar-news-list {
  margin: 6px 0 0;
  padding-left: 16px;
  font-size: 0.72rem;
}

.radar-news-list a {
  color: var(--gold-soft);
  text-decoration: none;
}

.radar-news-list a:hover {
  text-decoration: underline;
}

.news-headline-link {
  color: var(--gold-soft);
  text-decoration: none;
  font-weight: 600;
}

.news-headline-link:hover {
  text-decoration: underline;
}

@media (max-width: 1100px) {
  .week-at-glance-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* Prevent overlapping deck layers */
.deck-workspace > .deck-view:not([hidden]) {
  position: relative;
  isolation: isolate;
  contain: layout style;
}

.panel-avatar {
  min-height: 0;
  overflow: hidden;
}

#commandDeck .chart-workspace {
  position: relative;
  min-height: 0;
  overflow: hidden;
}

.bloomberg-dock {
  z-index: 2400;
}

.bloomberg-dock.bloomberg-dock-soft-muted {
  opacity: 0.92;
  outline: 1px solid rgba(201, 162, 39, 0.35);
  overflow: visible;
}

.bloomberg-dock.bloomberg-dock-soft-muted::after {
  content: "Muted while Pete speaks";
  position: absolute;
  left: 6px;
  bottom: 6px;
  z-index: 2;
  padding: 2px 6px;
  font-size: 0.55rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #f0e6c8;
  background: rgba(0, 0, 0, 0.65);
  border-radius: 4px;
  pointer-events: none;
}

#alertOverlay {
  z-index: 2500;
}

/* Executive nav rail labels */
.nav-rail-btn-labeled {
  flex-direction: column;
  gap: 4px;
  padding: 10px 6px 8px;
  min-height: 62px;
}

.nav-rail-caption {
  font-size: 0.58rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
  line-height: 1;
  font-weight: 600;
}

.nav-rail-btn-labeled.active .nav-rail-caption,
.nav-rail-btn-labeled:hover .nav-rail-caption {
  color: var(--gold-soft);
}

.nav-rail-icon {
  font-size: 1.38rem;
  line-height: 1;
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.4));
  transition: transform 0.18s ease;
}

.nav-rail-btn-labeled:hover .nav-rail-icon,
.nav-rail-btn-labeled.active .nav-rail-icon {
  transform: scale(1.08);
}

.nav-rail-icon-admin {
  font-size: 1.22rem;
}

.nav-rail-btn-admin[data-admin-nav-link]:not([hidden]) {
  animation: nav-admin-reveal 0.45s ease-out;
}

@keyframes nav-admin-reveal {
  from {
    opacity: 0;
    transform: translateY(8px) scale(0.92);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* Executive portal surfaces */
.portal-view {
  padding: 16px 20px 24px;
  max-width: 1200px;
  margin: 0 auto;
}

.portal-view-header {
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

/* Competitive Intel portal */
.ci-toolbar {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 14px;
}

.ci-toolbar-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}

.ci-region-toggle {
  display: inline-flex;
  gap: 4px;
  padding: 3px;
  border-radius: 8px;
  border: 1px solid rgba(201, 162, 39, 0.28);
  background: rgba(0, 0, 0, 0.25);
}

.ci-region-btn.active,
.ci-focus-btn.active {
  border-color: var(--amber, #c5a059);
  color: var(--gold-soft, #e8d5a3);
  background: rgba(212, 162, 76, 0.18);
}

.ci-past-toggle {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.78rem;
  color: rgba(230, 236, 242, 0.78);
  cursor: pointer;
}

.ci-focus-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.ci-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 12px;
  padding-bottom: 12px;
}

.ci-card {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 12px 14px;
  border: 1px solid rgba(201, 162, 39, 0.2);
  border-radius: 12px;
  background: linear-gradient(165deg, rgba(14, 28, 40, 0.96), rgba(8, 16, 24, 0.98));
  min-height: 0;
}

.ci-card-past {
  opacity: 0.72;
}

.ci-card-live {
  border-color: rgba(92, 184, 138, 0.55);
  box-shadow: 0 0 0 1px rgba(92, 184, 138, 0.18);
}

.ci-card-header {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.ci-card-title-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
}

.ci-card-title {
  margin: 0;
  font-size: 0.95rem;
  line-height: 1.25;
  color: #f2e6c8;
}

.ci-priority {
  margin: 0;
  font-size: 0.68rem;
  letter-spacing: 0.04em;
  color: #d4a24c;
}

.ci-summary {
  margin: 0;
  font-size: 0.78rem;
  line-height: 1.4;
  color: rgba(220, 228, 236, 0.88);
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.ci-meta {
  display: grid;
  gap: 6px;
  margin: 0;
}

.ci-meta > div {
  display: grid;
  grid-template-columns: 96px 1fr;
  gap: 8px;
  font-size: 0.78rem;
}

.ci-meta dt {
  margin: 0;
  color: rgba(201, 162, 39, 0.85);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-size: 0.62rem;
}

.ci-meta dd {
  margin: 0;
  color: rgba(230, 236, 242, 0.9);
}

.ci-focus-row {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.ci-chip {
  padding: 2px 7px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  font-size: 0.62rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: rgba(210, 220, 230, 0.85);
  background: rgba(255, 255, 255, 0.04);
}

.ci-status {
  flex-shrink: 0;
  padding: 2px 7px;
  border-radius: 999px;
  font-size: 0.62rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.ci-status-upcoming {
  color: #d4a24c;
  background: rgba(212, 162, 76, 0.14);
}

.ci-status-live {
  color: #8fd6b0;
  background: rgba(92, 184, 138, 0.18);
}

.ci-status-past {
  color: rgba(180, 190, 200, 0.8);
  background: rgba(255, 255, 255, 0.06);
}

.ci-card-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-top: auto;
  padding-top: 4px;
}

.ci-source {
  font-size: 0.68rem;
}

.ci-companies {
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.ci-section-header h3 {
  margin: 0 0 4px;
  font-size: 0.95rem;
  color: #f2e6c8;
}

.ci-section-header .muted {
  margin: 0 0 12px;
}

.ci-company-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 10px;
}

.ci-company-group {
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(0, 0, 0, 0.22);
}

.ci-company-group h4 {
  margin: 0 0 6px;
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(201, 162, 39, 0.9);
}

.ci-company-group p {
  margin: 0;
  font-size: 0.78rem;
  line-height: 1.4;
  color: rgba(220, 228, 236, 0.88);
}

.portal-progress-strip {
  grid-column: 1 / -1;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 14px;
  margin-bottom: 12px;
  border: 1px solid rgba(201, 162, 39, 0.22);
  border-radius: 10px;
  background: rgba(201, 162, 39, 0.05);
}

.executive-panel {
  padding: 16px 18px;
}

.briefing-autofill-hint {
  font-size: 0.72rem;
  margin: 0 0 10px;
  padding: 8px 10px;
  border-left: 2px solid var(--gold);
  background: rgba(201, 162, 39, 0.06);
}

.briefing-shell .zone-input-grid {
  gap: 8px;
}

.paper-event-guard-banner {
  grid-column: 1 / -1;
  padding: 8px 12px;
  margin-bottom: 8px;
  border-radius: 8px;
  border: 1px solid rgba(201, 162, 39, 0.35);
  background: rgba(201, 162, 39, 0.08);
  font-size: 0.72rem;
  color: var(--gold-soft);
}

.paper-event-guard-banner.event-guard-critical {
  border-color: rgba(220, 80, 80, 0.45);
  background: rgba(220, 80, 80, 0.1);
  color: #ffb4b4;
}

.training-card-done {
  border-color: rgba(92, 184, 138, 0.35);
}

.store-card-waitlisted .store-waitlist-btn {
  opacity: 0.85;
}

.executive-modal {
  border: none;
  padding: 0;
  background: transparent;
  max-width: min(560px, 92vw);
}

.executive-modal::backdrop {
  background: rgba(0, 0, 0, 0.72);
}

.pete-chart-needs-modal {
  max-width: min(480px, 92vw);
}

.pete-chart-needs-card {
  padding: 20px 22px;
  border-radius: 12px;
  border: 1px solid rgba(201, 162, 39, 0.28);
  background: rgba(8, 12, 22, 0.98);
  color: var(--text-primary, #e8ecf4);
}

.pete-chart-needs-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}

.pete-chart-needs-head h3 {
  margin: 4px 0 0;
  font-family: var(--font-display);
  font-size: 1.15rem;
}

.pete-chart-needs-lead {
  font-size: 0.82rem;
  line-height: 1.5;
  margin: 0 0 14px;
}

.pete-chart-grid-preview {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: 1fr 1fr;
  gap: 6px;
  aspect-ratio: 16 / 10;
  margin-bottom: 16px;
  padding: 6px;
  border-radius: 10px;
  border: 1px solid rgba(201, 162, 39, 0.22);
  background: rgba(0, 0, 0, 0.35);
}

.pete-chart-grid-cell {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  border-radius: 6px;
  border: 1px solid rgba(201, 162, 39, 0.18);
  background: linear-gradient(145deg, rgba(18, 24, 38, 0.95), rgba(10, 14, 24, 0.98));
  text-align: center;
  padding: 8px 6px;
}

.pete-chart-grid-tf {
  font-family: var(--font-display);
  font-size: 0.95rem;
  color: var(--gold-soft, #d4b85a);
  letter-spacing: 0.02em;
}

.pete-chart-grid-role {
  font-size: 0.68rem;
  color: var(--text-muted, #8a94a8);
  line-height: 1.3;
}

.pete-chart-needs-indicators-label {
  margin: 0 0 8px;
}

.pete-chart-needs-list {
  margin: 0 0 12px;
  padding-left: 18px;
  font-size: 0.82rem;
  line-height: 1.55;
}

.pete-chart-needs-foot {
  font-size: 0.75rem;
  margin: 0 0 14px;
}

.chart-prompt-actions {
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}

.training-lesson-card {
  padding: 18px 20px;
  border-radius: 12px;
  border: 1px solid rgba(201, 162, 39, 0.28);
  background: rgba(8, 12, 22, 0.96);
}

.training-lesson-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 10px;
}

.training-lesson-head h3 {
  margin: 4px 0 0;
  flex: 1 1 100%;
  font-family: var(--font-display);
}

.training-lesson-bullets {
  margin: 12px 0;
  padding-left: 18px;
  font-size: 0.82rem;
  line-height: 1.5;
}

.training-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 12px;
}

.store-grid {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.store-category-block {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.store-category-title {
  margin: 0;
  font-size: 0.82rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold-soft);
  padding-bottom: 4px;
  border-bottom: 1px solid rgba(197, 160, 89, 0.22);
}

.store-category-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 12px;
}

.store-progress-strip {
  grid-column: 1 / -1;
}

.legal-disclaimer .legal-entity-line { margin-top: 8px; font-size: 0.78rem; letter-spacing: 0.04em; color: #9eb0c8; }

