/* ==========================================================================
   Stips Pulse v8.0 — Studio-Grade Design System
   Inspired by Linear, Apple Human Interface Guidelines, Stripe & Notion.
   Full RTL Hebrew + Mixed LTR Support · Dark & Light Themes · Mobile-First
   ========================================================================== */

:root,
[data-theme="dark"] {
  /* Surface Hierarchy (Warm Obsidian Graphite) */
  --bg-canvas: #090a0d;
  --bg-sidebar: #0c0e13;
  --bg-surface: #10131a;
  --bg-elevated: #151922;
  --bg-hover: rgba(255, 255, 255, 0.04);
  --bg-active: rgba(255, 255, 255, 0.075);
  --bg-quote: rgba(255, 255, 255, 0.028);
  --bg-glass: rgba(12, 14, 19, 0.84);

  /* Hairline Borders */
  --border-subtle: rgba(255, 255, 255, 0.065);
  --border-default: rgba(255, 255, 255, 0.105);
  --border-strong: rgba(255, 255, 255, 0.18);

  /* Typography Colors */
  --text-primary: #f3f5f8;
  --text-secondary: #9ba3b4;
  --text-muted: #646d80;
  --text-on-accent: #ffffff;

  /* Semantic Signal Colors (Restrained, High-Contrast) */
  --emerald: #10b981;
  --emerald-soft: rgba(16, 185, 129, 0.12);
  --emerald-border: rgba(16, 185, 129, 0.28);

  --violet: #8b5cf6;
  --violet-soft: rgba(139, 92, 246, 0.12);
  --violet-border: rgba(139, 92, 246, 0.28);

  --cyan: #06b6d4;
  --cyan-soft: rgba(6, 182, 212, 0.12);
  --cyan-border: rgba(6, 182, 212, 0.28);

  --amber: #f59e0b;
  --amber-soft: rgba(245, 158, 11, 0.12);
  --amber-border: rgba(245, 158, 11, 0.28);

  --danger: #f43f5e;
  --danger-soft: rgba(244, 63, 94, 0.12);
  --danger-border: rgba(244, 63, 94, 0.28);

  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.35);
  --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.45);
  --shadow-lg: 0 20px 50px rgba(0, 0, 0, 0.65);
}

[data-theme="light"] {
  /* Surface Hierarchy (Warm Editorial Alabaster) */
  --bg-canvas: #f6f7f9;
  --bg-sidebar: #f0f2f5;
  --bg-surface: #ffffff;
  --bg-elevated: #f8fafc;
  --bg-hover: rgba(15, 23, 42, 0.04);
  --bg-active: rgba(15, 23, 42, 0.075);
  --bg-quote: #f8fafc;
  --bg-glass: rgba(255, 255, 255, 0.88);

  /* Hairline Borders */
  --border-subtle: rgba(15, 23, 42, 0.075);
  --border-default: rgba(15, 23, 42, 0.12);
  --border-strong: rgba(15, 23, 42, 0.22);

  /* Typography Colors */
  --text-primary: #0f172a;
  --text-secondary: #475569;
  --text-muted: #64748b;
  --text-on-accent: #ffffff;

  /* Semantic Signal Colors (Crisp Daylight) */
  --emerald: #059669;
  --emerald-soft: rgba(5, 150, 105, 0.09);
  --emerald-border: rgba(5, 150, 105, 0.25);

  --violet: #6d28d9;
  --violet-soft: rgba(109, 40, 217, 0.08);
  --violet-border: rgba(109, 40, 217, 0.24);

  --cyan: #0891b2;
  --cyan-soft: rgba(8, 145, 178, 0.09);
  --cyan-border: rgba(8, 145, 178, 0.25);

  --amber: #d97706;
  --amber-soft: rgba(217, 119, 6, 0.09);
  --amber-border: rgba(217, 119, 6, 0.25);

  --danger: #e11d48;
  --danger-soft: rgba(225, 29, 72, 0.08);
  --danger-border: rgba(225, 29, 72, 0.25);

  --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.05);
  --shadow-md: 0 8px 24px rgba(15, 23, 42, 0.08);
  --shadow-lg: 0 20px 50px rgba(15, 23, 42, 0.16);
}

:root {
  /* Typography & Geometry Tokens */
  --font-sans: "Heebo", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --font-mono: "JetBrains Mono", monospace;

  --radius-xs: 6px;
  --radius-sm: 8px;
  --radius-md: 11px;
  --radius-lg: 14px;
  --radius-pill: 999px;

  --sidebar-width: 272px;
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
}

/* ==========================================================================
   1. Base Reset & Typography
   ========================================================================== */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html,
body {
  height: 100%;
  background: var(--bg-canvas);
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 14px;
  line-height: 1.5;
  direction: rtl;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  transition: background-color 0.2s var(--ease-out), color 0.2s var(--ease-out);
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
select {
  font-family: inherit;
  font-size: inherit;
  color: inherit;
}

.hidden {
  display: none !important;
}

.clickable {
  cursor: pointer;
}

.num {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
}

.ic {
  width: 15px;
  height: 15px;
  flex-shrink: 0;
  vertical-align: middle;
}

/* Custom Subtle Scrollbars */
::-webkit-scrollbar {
  width: 5px;
  height: 5px;
}
::-webkit-scrollbar-track {
  background: transparent;
}
::-webkit-scrollbar-thumb {
  background: var(--border-default);
  border-radius: 99px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--border-strong);
}

/* ==========================================================================
   2. Password Gate
   ========================================================================== */
.auth-gate {
  position: fixed;
  inset: 0;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: var(--bg-canvas);
}

.auth-card {
  width: 100%;
  max-width: 380px;
  background: var(--bg-surface);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  padding: 28px 24px;
  text-align: center;
  box-shadow: var(--shadow-lg);
}

.auth-logo {
  width: 44px;
  height: 44px;
  margin: 0 auto 14px;
  border-radius: var(--radius-md);
  background: var(--emerald-soft);
  border: 1px solid var(--emerald-border);
  color: var(--emerald);
  display: flex;
  align-items: center;
  justify-content: center;
}

.auth-logo .ic {
  width: 22px;
  height: 22px;
}

.auth-card h1 {
  font-size: 19px;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 6px;
}

.auth-subtitle {
  font-size: 13px;
  color: var(--text-secondary);
  margin-bottom: 18px;
}

.auth-form {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.auth-form input {
  width: 100%;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-default);
  background: var(--bg-elevated);
  text-align: center;
  font-family: var(--font-mono);
  font-size: 15px;
  outline: none;
}

.auth-form input:focus {
  border-color: var(--violet);
}

.auth-error {
  font-size: 12.5px;
  color: var(--danger);
  font-weight: 600;
}

/* ==========================================================================
   3. Master Application Shell (Desktop Split-Pane + Mobile Adaptive)
   ========================================================================== */
.workstation-shell {
  display: grid;
  grid-template-columns: var(--sidebar-width) minmax(0, 1fr);
  height: 100vh;
  width: 100vw;
  overflow: hidden;
}

/* ==========================================================================
   4. Right Sidebar (Navigation, Monitored Subject & Related Circle)
   ========================================================================== */
.workstation-sidebar {
  background: var(--bg-sidebar);
  border-left: 1px solid var(--border-subtle);
  display: flex;
  flex-direction: column;
  height: 100vh;
  overflow: hidden;
  user-select: none;
}

.sidebar-top {
  padding: 14px 14px 11px;
  border-bottom: 1px solid var(--border-subtle);
}

.brand-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.brand-logo {
  width: 30px;
  height: 30px;
  border-radius: var(--radius-sm);
  background: var(--emerald-soft);
  border: 1px solid var(--emerald-border);
  color: var(--emerald);
  display: flex;
  align-items: center;
  justify-content: center;
}

.brand-name {
  font-size: 14px;
  font-weight: 800;
  letter-spacing: -0.01em;
  color: var(--text-primary);
}

.brand-sub {
  display: flex;
  align-items: center;
  gap: 5px;
  font-size: 11.5px;
  color: var(--text-secondary);
}

.live-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--emerald);
  box-shadow: 0 0 0 3px var(--emerald-soft);
  animation: pulseBreath 2.4s infinite ease-in-out;
}

@keyframes pulseBreath {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.55; transform: scale(0.92); }
}

.scan-meter-wrap {
  margin-top: 10px;
}

.scan-meter-labels {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  color: var(--text-muted);
  margin-bottom: 4px;
}

.scan-meter-track {
  height: 2px;
  width: 100%;
  background: var(--border-subtle);
  border-radius: 99px;
  overflow: hidden;
}

.scan-meter-fill {
  height: 100%;
  width: 25%;
  background: var(--emerald);
  border-radius: 99px;
  transition: width 0.45s linear;
}

.sidebar-section {
  padding: 10px 12px;
  border-bottom: 1px solid var(--border-subtle);
}

.sidebar-section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 11px;
  font-weight: 700;
  color: var(--text-muted);
  margin-bottom: 7px;
  padding: 0 2px;
}

/* Primary Monitored User Card in Sidebar */
.sidebar-profile-card {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-subtle);
  background: var(--bg-surface);
  cursor: pointer;
  transition: all 0.16s var(--ease-out);
}

.sidebar-profile-card:hover {
  border-color: var(--border-default);
  background: var(--bg-elevated);
}

.sidebar-profile-card.active {
  border-color: var(--emerald-border);
  background: var(--emerald-soft);
}

.sp-avatar-wrap {
  position: relative;
  width: 34px;
  height: 34px;
  flex-shrink: 0;
}

.sp-avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  object-fit: cover;
  border: 1px solid var(--border-default);
}

.sp-status-dot {
  position: absolute;
  bottom: -1px;
  left: -1px;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--text-muted);
  border: 2px solid var(--bg-sidebar);
}

.sp-status-dot.online {
  background: var(--emerald);
}

.sp-info {
  min-width: 0;
  flex: 1;
}

.sp-name {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sp-sub {
  font-size: 11px;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 4px;
}

/* Navigation Views */
.sidebar-nav {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.nav-item {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 7px 9px;
  border: none;
  border-radius: var(--radius-xs);
  background: transparent;
  color: var(--text-secondary);
  font-size: 12.5px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.14s var(--ease-out);
  text-align: right;
}

.nav-item:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
}

.nav-item.active {
  background: var(--bg-active);
  color: var(--text-primary);
  font-weight: 700;
}

.nav-item-label {
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.nav-badge {
  font-size: 11px;
  padding: 1px 6px;
  border-radius: var(--radius-pill);
  background: var(--bg-hover);
  color: var(--text-secondary);
}

.nav-badge.badge-live {
  background: var(--emerald-soft);
  color: var(--emerald);
  font-weight: 700;
}

/* Sidebar Related Profiles Explorer */
.sidebar-related-section {
  flex: 1;
  min-height: 0;
  display: flex;
  flex-direction: column;
  border-bottom: none;
}

.sidebar-search-form {
  margin-bottom: 7px;
}

.search-input-wrap {
  position: relative;
  display: flex;
  align-items: center;
}

.search-ic {
  position: absolute;
  right: 9px;
  width: 13px;
  height: 13px;
  color: var(--text-muted);
  pointer-events: none;
}

.search-input-wrap input {
  width: 100%;
  padding: 6px 28px 6px 8px;
  font-size: 12px;
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xs);
  outline: none;
  transition: border-color 0.15s;
}

.search-input-wrap input:focus {
  border-color: var(--violet);
}

.suggestions-dropdown {
  position: absolute;
  top: calc(100% + 4px);
  right: 0;
  left: 0;
  z-index: 60;
  background: var(--bg-elevated);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-md);
  max-height: 210px;
  overflow-y: auto;
}

.suggestion-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 7px 10px;
  font-size: 12px;
  cursor: pointer;
  border-bottom: 1px solid var(--border-subtle);
}

.suggestion-item:hover {
  background: var(--bg-hover);
}

.sidebar-related-scroll {
  flex: 1;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding-left: 2px;
}

.sidebar-rel-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 5px 8px;
  border-radius: var(--radius-xs);
  cursor: pointer;
  transition: background 0.14s var(--ease-out);
}

.sidebar-rel-item:hover {
  background: var(--bg-hover);
}

.sidebar-rel-item.active {
  background: var(--violet-soft);
  border: 1px solid var(--violet-border);
}

.sidebar-rel-avatar {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
}

.sidebar-rel-meta {
  flex: 1;
  min-width: 0;
}

.sidebar-rel-name {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sidebar-rel-reason {
  font-size: 10.5px;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.status-dot-sm {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--text-muted);
  opacity: 0.45;
  flex-shrink: 0;
}

.status-dot-sm.online {
  background: var(--emerald);
  opacity: 1;
  box-shadow: 0 0 0 3px var(--emerald-soft);
}

/* Sidebar Footer */
.sidebar-footer {
  padding: 10px 12px;
  border-top: 1px solid var(--border-subtle);
  background: var(--bg-sidebar);
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.tg-connection-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 6px 9px;
  border-radius: var(--radius-xs);
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  font-size: 11.5px;
  color: var(--text-secondary);
}

.tg-bar-left {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sidebar-footer-actions {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 6px;
}

/* ==========================================================================
   5. Main Stage, Top Utility Bar & Mobile Profile Strip
   ========================================================================== */
.workstation-stage {
  display: flex;
  flex-direction: column;
  height: 100vh;
  overflow-y: auto;
  overflow-x: hidden;
  background: var(--bg-canvas);
}

.stage-topbar {
  position: sticky;
  top: 0;
  z-index: 40;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 22px;
  background: var(--bg-glass);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-subtle);
}

.stage-topbar-right {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.hebrew-date-pill {
  font-size: 12px;
  font-weight: 500;
  color: var(--text-secondary);
  white-space: nowrap;
}

.stage-topbar-center {
  flex: 1;
  max-width: 420px;
}

.spotlight-trigger-btn {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 6px 11px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-subtle);
  background: var(--bg-surface);
  color: var(--text-muted);
  font-size: 12px;
  cursor: pointer;
  transition: all 0.15s var(--ease-out);
}

.spotlight-trigger-btn:hover {
  border-color: var(--border-default);
  color: var(--text-secondary);
}

.kbd-hint {
  font-family: var(--font-mono);
  font-size: 10.5px;
  padding: 1px 6px;
  border-radius: 4px;
  background: var(--bg-hover);
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
  white-space: nowrap;
  flex-shrink: 0;
}

.stage-topbar-actions {
  display: flex;
  align-items: center;
  gap: 6px;
}

/* Mobile Profile Strip (Hidden on Desktop, Shown on Tablet/Mobile) */
.mobile-profile-strip {
  display: none;
  align-items: center;
  gap: 7px;
  padding: 8px 14px;
  overflow-x: auto;
  border-bottom: 1px solid var(--border-subtle);
  background: var(--bg-sidebar);
  scrollbar-width: none;
}
.mobile-profile-strip::-webkit-scrollbar {
  display: none;
}

.mob-prof-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 10px 5px 8px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--border-subtle);
  background: var(--bg-surface);
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
  flex-shrink: 0;
  cursor: pointer;
}

.mob-prof-chip.active {
  border-color: var(--emerald-border);
  background: var(--emerald-soft);
  color: var(--emerald);
}

.mob-prof-chip img {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  object-fit: cover;
}

/* ==========================================================================
   6. Focused Subject Pulse Header + 24h Spark-Strip + 4 Priority Signals
   ========================================================================== */
.focused-profile-header {
  padding: 18px 22px 16px;
  border-bottom: 1px solid var(--border-subtle);
  background: var(--bg-surface);
}

.fp-top-bar {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.fp-identity {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
}

.fp-avatar {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--border-default);
  flex-shrink: 0;
}

.fp-avatar.is-online {
  border-color: var(--emerald);
  box-shadow: 0 0 0 4px var(--emerald-soft);
}

.fp-title-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.fp-name {
  font-size: 20px;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text-primary);
}

.fp-id-badge {
  font-size: 11.5px;
  padding: 2px 7px;
  border-radius: var(--radius-xs);
  background: var(--bg-hover);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
}

.fp-status-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 700;
  padding: 2px 10px;
  border-radius: var(--radius-pill);
}

.fp-status-badge.online {
  background: var(--emerald-soft);
  border: 1px solid var(--emerald-border);
  color: var(--emerald);
}

.fp-status-badge.offline {
  background: var(--bg-hover);
  border: 1px solid var(--border-subtle);
  color: var(--text-secondary);
}

.fp-meta-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 4px;
  font-size: 12px;
  color: var(--text-secondary);
}

.fp-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

/* Bio & 24-Hour Presence Spark-Strip Row */
.fp-sub-bar {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 16px;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--border-subtle);
}

.fp-bio-quote {
  font-size: 12.5px;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 8px;
  min-width: 0;
}

.fp-bio-label {
  font-weight: 700;
  color: var(--text-primary);
  white-space: nowrap;
}

.fp-bio-text {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* 24-Hour Activity Sparkline Strip */
.hourly-spark-wrap {
  display: flex;
  align-items: center;
  gap: 10px;
}

.hourly-spark-label {
  font-size: 11px;
  color: var(--text-muted);
  white-space: nowrap;
}

.hourly-spark-bars {
  display: flex;
  align-items: flex-end;
  gap: 2px;
  height: 22px;
  padding: 2px 6px;
  border-radius: var(--radius-xs);
  background: var(--bg-canvas);
  border: 1px solid var(--border-subtle);
  direction: ltr;
}

.h-bar {
  width: 4px;
  border-radius: 2px;
  background: var(--border-default);
  transition: height 0.2s var(--ease-out), background-color 0.2s;
}

.h-bar.lvl-1 {
  background: rgba(16, 185, 129, 0.45);
}
.h-bar.lvl-2 {
  background: rgba(16, 185, 129, 0.75);
}
.h-bar.lvl-3 {
  background: var(--emerald);
}

/* 4 Priority Signals Strip (Scannable in 3 Seconds) */
.fp-situation-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-top: 14px;
}

.sit-card {
  padding: 12px 14px;
  border-radius: var(--radius-md);
  background: var(--bg-canvas);
  border: 1px solid var(--border-subtle);
  transition: transform 0.16s var(--ease-out), border-color 0.16s var(--ease-out);
  display: flex;
  flex-direction: column;
  gap: 4px;
  min-width: 0;
}

.sit-card:hover {
  transform: translateY(-1px);
  border-color: var(--border-default);
}

.sit-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 11.5px;
  font-weight: 600;
  color: var(--text-secondary);
}

.sit-value {
  font-size: 15px;
  font-weight: 800;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sit-sub {
  font-size: 11.5px;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ==========================================================================
   7. Main Stage Content & Asymmetric 2-Zone Editorial Workspace
   ========================================================================== */
.stage-content {
  padding: 18px 22px 48px;
  flex: 1;
}

.tab-view {
  display: none;
  animation: fadeSlideIn 0.2s var(--ease-out);
}

.tab-view.active {
  display: block;
}

@keyframes fadeSlideIn {
  from { opacity: 0; transform: translateY(4px); }
  to { opacity: 1; transform: translateY(0); }
}

.editorial-workspace-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(320px, 1fr);
  gap: 18px;
  align-items: start;
}

/* Primary Editorial Column */
.editorial-main-column {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  overflow: hidden;
}

.section-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 18px 10px;
}

.section-heading {
  font-size: 15px;
  font-weight: 800;
  color: var(--text-primary);
}

.section-sub {
  font-size: 12px;
  color: var(--text-secondary);
}

.input-compact {
  padding: 6px 10px;
  border-radius: var(--radius-xs);
  border: 1px solid var(--border-subtle);
  background: var(--bg-canvas);
  font-size: 12px;
  width: 170px;
  outline: none;
}

.input-compact:focus {
  border-color: var(--violet);
}

/* Filter Pills Row */
.filter-pills-row {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 0 18px 12px;
  border-bottom: 1px solid var(--border-subtle);
  overflow-x: auto;
  scrollbar-width: none;
}
.filter-pills-row::-webkit-scrollbar {
  display: none;
}

.pill-tab {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 9px;
  border-radius: var(--radius-pill);
  border: 1px solid var(--border-subtle);
  background: var(--bg-canvas);
  color: var(--text-secondary);
  font-size: 11.5px;
  font-weight: 600;
  white-space: nowrap;
  cursor: pointer;
  transition: all 0.14s var(--ease-out);
}

.pill-tab:hover {
  border-color: var(--border-default);
  color: var(--text-primary);
}

.pill-tab.active {
  background: var(--text-primary);
  color: var(--bg-canvas);
  border-color: var(--text-primary);
}

.pill-cnt {
  font-size: 10.5px;
  opacity: 0.8;
}

/* Editorial Feed Rows (Clean Hairline Dividers, Zero Nested Box Clutter) */
.editorial-feed-list {
  display: flex;
  flex-direction: column;
  max-height: 760px;
  overflow-y: auto;
}

.ed-row {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 12px;
  padding: 13px 18px;
  border-bottom: 1px solid var(--border-subtle);
  transition: background-color 0.14s var(--ease-out);
  cursor: pointer;
}

.ed-row:last-child {
  border-bottom: none;
}

.ed-row:hover {
  background: var(--bg-hover);
}

.ed-icon-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding-top: 2px;
}

.ed-glyph {
  width: 30px;
  height: 30px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border-subtle);
  background: var(--bg-canvas);
  color: var(--text-secondary);
}

.ed-glyph.emerald {
  background: var(--emerald-soft);
  border-color: var(--emerald-border);
  color: var(--emerald);
}
.ed-glyph.violet {
  background: var(--violet-soft);
  border-color: var(--violet-border);
  color: var(--violet);
}
.ed-glyph.cyan {
  background: var(--cyan-soft);
  border-color: var(--cyan-border);
  color: var(--cyan);
}
.ed-glyph.amber {
  background: var(--amber-soft);
  border-color: var(--amber-border);
  color: var(--amber);
}
.ed-glyph.danger {
  background: var(--danger-soft);
  border-color: var(--danger-border);
  color: var(--danger);
}

.ed-main {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.ed-top-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
}

.ed-title-group {
  display: flex;
  align-items: center;
  gap: 7px;
  min-width: 0;
  flex-wrap: wrap;
}

.ed-kind-badge {
  font-size: 11px;
  font-weight: 700;
  padding: 1px 7px;
  border-radius: var(--radius-xs);
}

.ed-title {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--text-primary);
}

.ed-time-group {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11.5px;
  color: var(--text-muted);
}

.ed-rel-time {
  font-weight: 600;
  color: var(--text-secondary);
}

.ed-quote {
  font-size: 13px;
  line-height: 1.55;
  color: var(--text-primary);
  padding-right: 10px;
  border-right: 2px solid var(--border-strong);
  margin-top: 2px;
  white-space: pre-wrap;
  word-break: break-word;
}

.ed-quote.emerald { border-right-color: var(--emerald); }
.ed-quote.violet { border-right-color: var(--violet); }
.ed-quote.cyan { border-right-color: var(--cyan); }
.ed-quote.amber { border-right-color: var(--amber); }

.ed-footer-line {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-top: 2px;
  font-size: 11.5px;
  color: var(--text-muted);
}

/* Secondary Insights Column (Right/Left 38%) */
.editorial-side-column {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.insight-module {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 14px 16px;
}

.module-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
}

.module-title {
  font-size: 13.5px;
  font-weight: 800;
  color: var(--text-primary);
}

.module-sub {
  font-size: 11.5px;
  color: var(--text-secondary);
}

.seg-mini {
  display: inline-flex;
  background: var(--bg-canvas);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-xs);
  padding: 2px;
}

.seg-mini-btn {
  border: none;
  background: transparent;
  padding: 3px 8px;
  font-size: 11px;
  font-weight: 600;
  color: var(--text-secondary);
  border-radius: 4px;
  cursor: pointer;
}

.seg-mini-btn.active {
  background: var(--bg-surface);
  color: var(--text-primary);
  box-shadow: var(--shadow-sm);
}

/* Interactive SVG Chart Box */
.interactive-chart-box {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.svg-chart-wrap {
  width: 100%;
  background: var(--bg-canvas);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 12px 12px 8px;
}

.chart-legend-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 11.5px;
  color: var(--text-secondary);
}

/* Partner Balance Rows inside Top Relations Module */
.partner-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 8px 6px;
  border-bottom: 1px solid var(--border-subtle);
  cursor: pointer;
  border-radius: var(--radius-xs);
  transition: background 0.14s;
}

.partner-row:last-child {
  border-bottom: none;
}

.partner-row:hover {
  background: var(--bg-hover);
}

.partner-left {
  display: flex;
  align-items: center;
  gap: 9px;
  min-width: 0;
}

.partner-bar-wrap {
  width: 78px;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 3px;
}

.partner-dual-bar {
  width: 100%;
  height: 5px;
  border-radius: 99px;
  background: var(--border-subtle);
  display: flex;
  overflow: hidden;
}

/* ==========================================================================
   8. Secondary Views, Diffs, Tags & Buttons
   ========================================================================== */
.two-col-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.stream-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.stream-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.stream-title-row {
  display: flex;
  align-items: center;
  gap: 10px;
}

.stream-icon {
  width: 30px;
  height: 30px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-hover);
  border: 1px solid var(--border-subtle);
}
.stream-icon.emerald { background: var(--emerald-soft); border-color: var(--emerald-border); color: var(--emerald); }
.stream-icon.violet { background: var(--violet-soft); border-color: var(--violet-border); color: var(--violet); }
.stream-icon.cyan { background: var(--cyan-soft); border-color: var(--cyan-border); color: var(--cyan); }
.stream-icon.amber { background: var(--amber-soft); border-color: var(--amber-border); color: var(--amber); }

.stream-title {
  font-size: 14px;
  font-weight: 800;
}

.stream-sub,
.panel-subtitle {
  font-size: 12px;
  color: var(--text-secondary);
}

.stream-spotlight {
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  background: var(--bg-canvas);
  border: 1px solid var(--border-subtle);
}

.spot-row-between {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
}

.spot-title {
  font-size: 12.5px;
  font-weight: 700;
}

.spot-desc {
  font-size: 11.5px;
  color: var(--text-secondary);
}

.stream-body {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.tall-scroll {
  max-height: 680px;
  overflow-y: auto;
  padding-left: 4px;
}

.feed-card {
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  background: var(--bg-canvas);
  border: 1px solid var(--border-subtle);
  display: flex;
  flex-direction: column;
  gap: 6px;
  transition: border-color 0.14s;
}

.feed-card:hover {
  border-color: var(--border-default);
}

.card-top,
.card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  flex-wrap: wrap;
}

.card-author {
  display: flex;
  align-items: center;
  gap: 8px;
}

.avatar-sm {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  object-fit: cover;
}

.author-name {
  font-size: 12.5px;
  font-weight: 700;
}

.mono-id {
  font-size: 11px;
  color: var(--text-muted);
}

.card-headline {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-primary);
}

.quote-block {
  font-size: 12.5px;
  line-height: 1.55;
  padding: 8px 11px;
  border-radius: var(--radius-xs);
  background: var(--bg-quote);
  border-right: 2px solid var(--border-strong);
  white-space: pre-wrap;
  word-break: break-word;
}

/* Before / After Edit Diff Grid */
.diff-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-top: 2px;
}

.diff-before,
.diff-after {
  padding: 8px 10px;
  border-radius: var(--radius-xs);
  font-size: 12px;
  line-height: 1.5;
  white-space: pre-wrap;
  word-break: break-word;
}

.diff-before {
  background: var(--danger-soft);
  border: 1px solid var(--danger-border);
}

.diff-after {
  background: var(--emerald-soft);
  border: 1px solid var(--emerald-border);
}

.diff-label {
  display: block;
  font-size: 10.5px;
  font-weight: 700;
  margin-bottom: 3px;
  opacity: 0.9;
}

/* Candidate Question Rows */
.candidate-q-list {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-top: 6px;
}

.candidate-q-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 7px 10px;
  border-radius: var(--radius-xs);
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
}

/* Semantic Chips & Pills */
.tag-chip,
.tag-pill {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  font-weight: 700;
  padding: 2px 7px;
  border-radius: var(--radius-xs);
  background: var(--bg-hover);
  color: var(--text-secondary);
}

.tag-online,
.tag-emerald {
  background: var(--emerald-soft);
  color: var(--emerald);
  border: 1px solid var(--emerald-border);
}

.tag-outbound,
.tag-violet {
  background: var(--violet-soft);
  color: var(--violet);
  border: 1px solid var(--violet-border);
}

.tag-inbound,
.tag-cyan {
  background: var(--cyan-soft);
  color: var(--cyan);
  border: 1px solid var(--cyan-border);
}

.tag-flower,
.tag-amber {
  background: var(--amber-soft);
  color: var(--amber);
  border: 1px solid var(--amber-border);
}

.tag-deleted {
  background: var(--danger-soft);
  color: var(--danger);
  border: 1px solid var(--danger-border);
}

.dual-time {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 11px;
  color: var(--text-muted);
}

.action-link {
  font-size: 11.5px;
  font-weight: 600;
  color: var(--text-secondary);
  cursor: pointer;
}
.action-link:hover {
  color: var(--text-primary);
  text-decoration: underline;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border-radius: var(--radius-sm);
  font-weight: 600;
  cursor: pointer;
  transition: all 0.14s var(--ease-out);
  border: 1px solid transparent;
  white-space: nowrap;
}

.btn-xs { padding: 4px 8px; font-size: 11.5px; border-radius: var(--radius-xs); }
.btn-sm { padding: 6px 11px; font-size: 12px; }
.btn-block { width: 100%; padding: 10px 14px; font-size: 14px; }

.btn-primary {
  background: var(--text-primary);
  color: var(--bg-canvas);
}
.btn-primary:hover {
  opacity: 0.9;
}

.btn-subtle {
  background: var(--bg-surface);
  border-color: var(--border-default);
  color: var(--text-primary);
}
.btn-subtle:hover {
  background: var(--bg-hover);
  border-color: var(--border-strong);
}

.btn-ghost {
  background: transparent;
  color: var(--text-secondary);
}
.btn-ghost:hover {
  background: var(--bg-hover);
  color: var(--text-primary);
}

.btn.muted {
  opacity: 0.55;
}

.btn-row {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

/* Filter Bars & Inputs */
.filter-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.input-select,
.input-search {
  padding: 7px 10px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-default);
  background: var(--bg-canvas);
  font-size: 12.5px;
  outline: none;
}

.input-search {
  flex: 1;
  min-width: 180px;
}

.related-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 10px;
}

/* Settings & Matrix Table */
.settings-section-box {
  padding: 12px 14px;
  border-radius: var(--radius-sm);
  background: var(--bg-canvas);
  border: 1px solid var(--border-subtle);
}

.settings-section-box h3 {
  font-size: 13px;
  font-weight: 800;
}

.toggles-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
}

.toggle-tile {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  background: var(--bg-surface);
  border: 1px solid var(--border-subtle);
  cursor: pointer;
}

.toggle-tile.is-on {
  border-color: var(--emerald-border);
}

.toggle-tile-title {
  font-size: 12.5px;
  font-weight: 700;
}

.toggle-tile-sub {
  font-size: 11px;
  color: var(--text-secondary);
}

.toggle-state-pill {
  font-size: 11px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: var(--radius-pill);
}

.toggle-state-pill.on {
  background: var(--emerald-soft);
  color: var(--emerald);
}

.toggle-state-pill.off {
  background: var(--bg-hover);
  color: var(--text-muted);
}

.two-col-inputs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.field-group {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 11.5px;
  color: var(--text-secondary);
}

.field-group input {
  padding: 6px 9px;
  border-radius: var(--radius-xs);
  border: 1px solid var(--border-default);
  background: var(--bg-surface);
  font-family: var(--font-mono);
  font-size: 12px;
}

.joined-input {
  display: flex;
  gap: 6px;
}
.joined-input input {
  flex: 1;
}

.table-wrap {
  overflow-x: auto;
}

.prefs-table {
  width: 100%;
  border-collapse: collapse;
}

.prefs-table th,
.prefs-table td {
  padding: 10px 10px;
  border-bottom: 1px solid var(--border-subtle);
  text-align: right;
}

.prefs-table th {
  font-size: 11.5px;
  color: var(--text-muted);
  font-weight: 700;
}

.center-col {
  text-align: center !important;
}

.matrix-toggle-btn {
  padding: 5px 11px;
  border-radius: var(--radius-pill);
  font-size: 11.5px;
  font-weight: 700;
  cursor: pointer;
  border: 1px solid var(--border-subtle);
}

.matrix-toggle-btn.on {
  background: var(--emerald-soft);
  border-color: var(--emerald-border);
  color: var(--emerald);
}

.matrix-toggle-btn.off {
  background: var(--bg-hover);
  color: var(--text-muted);
}

.status-banner {
  margin-top: 8px;
  padding: 8px 11px;
  border-radius: var(--radius-xs);
  background: var(--emerald-soft);
  border: 1px solid var(--emerald-border);
  color: var(--emerald);
  font-size: 12px;
  font-weight: 600;
}

.status-banner.error {
  background: var(--danger-soft);
  border-color: var(--danger-border);
  color: var(--danger);
}

/* ==========================================================================
   9. Slide-Over Detail Drawer, Spotlight Command Modal & Settings Modal
   ========================================================================== */
.drawer-backdrop,
.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 900;
  background: rgba(0, 0, 0, 0.58);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 18px;
}

.drawer-backdrop {
  justify-content: flex-end;
  padding: 0;
}

.detail-drawer {
  width: 100%;
  max-width: 480px;
  height: 100vh;
  background: var(--bg-surface);
  border-right: 1px solid var(--border-default);
  box-shadow: var(--shadow-lg);
  display: flex;
  flex-direction: column;
  animation: slideDrawerIn 0.22s var(--ease-out);
}

@keyframes slideDrawerIn {
  from { transform: translateX(-30px); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}

.drawer-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
  border-bottom: 1px solid var(--border-subtle);
}

.drawer-body {
  padding: 20px;
  overflow-y: auto;
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

/* Spotlight Search Dialog */
.spotlight-dialog {
  width: 100%;
  max-width: 620px;
  background: var(--bg-surface);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  align-self: flex-start;
  margin-top: 8vh;
}

.spotlight-search-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--border-subtle);
}

.spotlight-search-bar input {
  flex: 1;
  border: none;
  background: transparent;
  font-size: 14.5px;
  outline: none;
}

.spotlight-results {
  max-height: 420px;
  overflow-y: auto;
  padding: 8px;
}

/* Settings Modal Dialog */
.modal-dialog {
  width: 100%;
  max-width: 820px;
  max-height: 88vh;
  background: var(--bg-surface);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px;
  border-bottom: 1px solid var(--border-subtle);
}

.modal-body {
  padding: 16px 18px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

/* Toast Notifications */
.toast-container {
  position: fixed;
  bottom: 20px;
  left: 20px;
  z-index: 1000;
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-width: 360px;
}

.toast {
  background: var(--bg-surface);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-md);
  padding: 12px 14px;
  box-shadow: var(--shadow-lg);
}

/* ==========================================================================
   10. Mobile-First Navigation & Responsive Breakpoints
   ========================================================================== */
.mobile-bottom-nav {
  display: none;
}

@media (max-width: 1120px) {
  .fp-situation-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .editorial-workspace-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 900px) {
  .workstation-shell {
    grid-template-columns: 1fr;
    height: auto;
    min-height: 100vh;
    overflow: visible;
  }

  .workstation-sidebar {
    display: none;
  }

  .workstation-stage {
    height: auto;
    min-height: 100vh;
    padding-bottom: 76px;
  }

  .mobile-profile-strip {
    display: flex;
  }

  .mobile-bottom-nav {
    position: fixed;
    bottom: 0;
    right: 0;
    left: 0;
    z-index: 500;
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    background: var(--bg-glass);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-top: 1px solid var(--border-default);
    padding: 4px 4px calc(4px + env(safe-area-inset-bottom));
  }

  .mob-nav-btn {
    border: none;
    background: transparent;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 3px;
    padding: 6px 2px;
    color: var(--text-muted);
    font-size: 10.5px;
    font-weight: 600;
    border-radius: var(--radius-xs);
    cursor: pointer;
  }

  .mob-nav-btn.active {
    color: var(--emerald);
    font-weight: 800;
  }

  .two-col-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .hide-on-mobile {
    display: none !important;
  }

  .stage-topbar {
    padding: 8px 12px;
    gap: 8px;
  }

  .hebrew-date-pill {
    font-size: 11px;
    max-width: 140px;
    overflow: hidden;
    text-overflow: ellipsis;
  }

  .spotlight-trigger-btn span {
    max-width: 120px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .kbd-hint {
    display: none;
  }

  .focused-profile-header {
    padding: 14px 12px;
  }

  .fp-sub-bar {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .fp-situation-grid {
    grid-template-columns: 1fr 1fr;
    gap: 8px;
  }

  .sit-card {
    padding: 10px 11px;
  }

  .sit-value {
    font-size: 13.5px;
  }

  .stage-content {
    padding: 12px 12px 84px;
  }

  .section-bar {
    flex-direction: column;
    align-items: stretch;
    padding: 12px 14px 8px;
  }

  .input-compact {
    width: 100%;
  }

  .filter-pills-row {
    padding: 0 14px 10px;
  }

  .ed-row {
    padding: 11px 12px;
    gap: 10px;
  }

  .diff-grid,
  .toggles-grid,
  .two-col-inputs {
    grid-template-columns: 1fr;
  }

  .detail-drawer {
    max-width: 100%;
    height: 88vh;
    align-self: flex-end;
    border-radius: var(--radius-lg) var(--radius-lg) 0 0;
    border-right: none;
    border-top: 1px solid var(--border-default);
  }
}
.hosting-controls { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin: 12px 20px; padding: 14px; border: 1px solid var(--border-default); border-radius: 12px; }
.hosting-controls p { margin: 4px 0 0; font-size: 13px; }
.hosting-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-inline-start: auto; }
#hosting-feedback { flex-basis: 100%; }
@media (max-width: 600px) { .hosting-controls { margin: 10px; } .hosting-actions { margin-inline-start: 0; } }
