/* Perception Signals™ - Modern Dark UI Styles */
:root {
  --bg-main: #f7f8f3;
  --bg-card: #ffffff;
  --bg-card-hover: #f1f5e8;
  --bg-input: #ffffff;
  --border-color: #e3e8dc;
  --border-highlight: #cbd5be;
  
  --accent: #c8ee71;
  --accent-glow: rgba(200, 238, 113, 0.18);
  --text-main: #253126;
  --text-muted: #687568;
  --text-dim: #849083;
  
  --color-success: #10b981;
  --color-success-bg: rgba(16, 185, 129, 0.12);
  --color-warning: #f59e0b;
  --color-warning-bg: rgba(245, 158, 11, 0.12);
  --color-danger: #f43f5e;
  --color-danger-bg: rgba(244, 63, 94, 0.12);
  --color-blue: #38bdf8;
  --color-blue-bg: rgba(56, 189, 248, 0.12);

  --font-main: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  background-color: var(--bg-main);
  color: var(--text-main);
  font-family: var(--font-main);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}

.app-layout {
  max-width: 1560px;
  margin: 0 auto;
  padding: 1.5rem 2rem 3rem 2rem;
}

/* Header */
.header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--border-color);
  margin-bottom: 2rem;
}

.brand-area {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.logo-mark {
  background: var(--accent);
  color: #000;
  font-size: 1.5rem;
  font-weight: 900;
  width: 44px;
  height: 44px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 20px var(--accent-glow);
}

.brand-text h1 {
  font-size: 1.35rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.trademark {
  color: var(--accent);
  font-size: 0.8rem;
  vertical-align: super;
}

.subtitle {
  font-size: 0.8rem;
  color: var(--text-muted);
  font-weight: 400;
}

.header-badges {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.35rem 0.75rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 600;
}

.dpdp-badge {
  background: var(--color-success-bg);
  color: var(--color-success);
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.flag-badge {
  background: var(--bg-card);
  color: var(--accent);
  border: 1px solid var(--border-color);
  font-family: var(--font-mono);
  font-size: 0.72rem;
}

.pulse-dot {
  width: 7px;
  height: 7px;
  background-color: var(--color-success);
  border-radius: 50%;
  animation: pulse 1.8s infinite;
}

@keyframes pulse {
  0% { transform: scale(0.95); opacity: 0.6; }
  50% { transform: scale(1.3); opacity: 1; }
  100% { transform: scale(0.95); opacity: 0.6; }
}

/* KPIs */
.kpi-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 1rem;
  margin-bottom: 2rem;
}

.kpi-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 1.15rem 1.25rem;
  position: relative;
  overflow: hidden;
}

.kpi-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--border-highlight);
}

.kpi-card.compliant::before { background: var(--color-success); }
.kpi-card.blocked::before { background: var(--color-danger); }
.kpi-card.studio::before { background: var(--accent); }
.kpi-card.intent::before { background: var(--color-blue); }

.kpi-label {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-muted);
  font-weight: 600;
}

.kpi-value {
  font-size: 1.8rem;
  font-weight: 800;
  color: var(--text-main);
  margin: 0.25rem 0;
  font-family: var(--font-mono);
}

.kpi-sub {
  font-size: 0.72rem;
  color: var(--text-dim);
}

/* Main Grid */
.content-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 1.75rem;
}

/* Signal Inbox Section */
.signal-inbox-section {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 14px;
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
}

.section-header {
  margin-bottom: 1.25rem;
}

.title-with-count {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin-bottom: 1rem;
}

.title-with-count h2 {
  font-size: 1.2rem;
  font-weight: 700;
}

.inbox-count {
  background: var(--bg-input);
  color: var(--accent);
  padding: 0.15rem 0.55rem;
  border-radius: 6px;
  font-size: 0.75rem;
  font-family: var(--font-mono);
  font-weight: 700;
  border: 1px solid var(--border-highlight);
}

.filter-controls {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 0.6rem;
}

.search-box input, .select-box, textarea {
  width: 100%;
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  color: var(--text-main);
  font-family: var(--font-main);
  padding: 0.55rem 0.8rem;
  font-size: 0.82rem;
  outline: none;
  transition: border-color 0.15s ease;
}

.search-box input:focus, .select-box:focus, textarea:focus {
  border-color: var(--accent);
}

.signals-list {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  max-height: 800px;
  overflow-y: auto;
  padding-right: 0.4rem;
}

/* Signal Card */
.signal-item {
  background: #151c25;
  border: 1px solid var(--border-color);
  border-radius: 10px;
  padding: 1.1rem 1.25rem;
  transition: all 0.2s ease;
  position: relative;
  cursor: pointer;
}

.signal-item:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-highlight);
  transform: translateY(-1px);
}

.signal-item.selected {
  border-color: var(--accent);
  box-shadow: 0 0 16px rgba(200, 238, 113, 0.15);
}

.signal-item-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 0.6rem;
}

.company-title-wrap {
  display: flex;
  flex-direction: column;
}

.company-name {
  font-size: 1rem;
  font-weight: 700;
  color: #fff;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.company-domain {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--text-dim);
}

.signal-scores {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.score-badge {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.2rem 0.55rem;
  border-radius: 6px;
}

.score-intent {
  background: var(--color-blue-bg);
  color: var(--color-blue);
  border: 1px solid rgba(56, 189, 248, 0.3);
}

.score-icp {
  background: var(--accent-glow);
  color: var(--accent);
  border: 1px solid rgba(200, 238, 113, 0.3);
}

.signal-tags-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem;
  margin-bottom: 0.7rem;
}

.tag {
  font-size: 0.68rem;
  padding: 0.15rem 0.45rem;
  border-radius: 4px;
  background: var(--bg-input);
  color: var(--text-muted);
}

.tag.provider-tag {
  color: #fff;
  font-weight: 600;
  border: 1px solid var(--border-highlight);
}

.tag.status-approved {
  background: var(--color-success-bg);
  color: var(--color-success);
}

.tag.status-sanitized {
  background: var(--color-warning-bg);
  color: var(--color-warning);
}

.tag.status-blocked {
  background: var(--color-danger-bg);
  color: var(--color-danger);
}

.signal-summary {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 0.8rem;
  line-height: 1.4;
}

.signal-actions-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 0.6rem;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.signal-time {
  font-size: 0.7rem;
  color: var(--text-dim);
  font-family: var(--font-mono);
}

.action-buttons {
  display: flex;
  gap: 0.4rem;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  padding: 0.45rem 0.85rem;
  border-radius: 6px;
  font-size: 0.75rem;
  font-weight: 700;
  cursor: pointer;
  border: none;
  transition: all 0.15s ease;
  font-family: var(--font-main);
}

.btn-primary {
  background: var(--accent);
  color: #000;
}
.btn-primary:hover {
  background: #d9f99d;
  box-shadow: 0 0 12px var(--accent-glow);
}

.btn-secondary {
  background: var(--bg-input);
  color: var(--text-main);
  border: 1px solid var(--border-color);
}
.btn-secondary:hover {
  background: var(--border-highlight);
}

.btn-sm {
  padding: 0.25rem 0.55rem;
  font-size: 0.7rem;
}

.btn-studio {
  background: #1e293b;
  color: var(--accent);
  border: 1px solid rgba(200, 238, 113, 0.4);
}
.btn-studio:hover {
  background: var(--accent);
  color: #000;
}

.btn-preset {
  background: var(--bg-input);
  color: var(--text-main);
  border: 1px solid var(--border-color);
  padding: 0.45rem 0.65rem;
  font-size: 0.72rem;
  border-radius: 6px;
  text-align: left;
}
.btn-preset:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.btn-danger {
  color: var(--color-danger);
  border-color: rgba(244, 63, 94, 0.3);
}
.btn-danger:hover {
  background: var(--color-danger-bg);
  border-color: var(--color-danger);
  color: #fff;
}

.btn-block {
  width: 100%;
}

/* Right Side Panel */
.side-panel {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.panel-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 14px;
  padding: 1.4rem;
}

.panel-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.5rem;
}

.panel-header h3 {
  font-size: 1.05rem;
  font-weight: 700;
}

.card-pill {
  font-size: 0.7rem;
  font-weight: 600;
  padding: 0.2rem 0.5rem;
  border-radius: 9999px;
  background: var(--bg-input);
  color: var(--text-muted);
  border: 1px solid var(--border-color);
}

.panel-desc {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-bottom: 1rem;
}

.simulator-buttons {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem;
  margin-bottom: 1.1rem;
}

.webhook-editor-area {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
}

.editor-header {
  display: flex;
  justify-content: space-between;
  font-size: 0.75rem;
}

.endpoint-url {
  font-family: var(--font-mono);
  color: var(--accent);
  font-weight: 600;
}

textarea#payloadEditor {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  resize: vertical;
  line-height: 1.4;
  white-space: pre;
}

/* Brief Drawer Content */
.brief-preview-empty {
  padding: 3rem 1.5rem;
  text-align: center;
  color: var(--text-dim);
  font-size: 0.85rem;
  border: 1px dashed var(--border-color);
  border-radius: 8px;
}

.brief-container {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.brief-card-header {
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 0.8rem;
}

.brief-card-header h4 {
  font-size: 1.1rem;
  color: #fff;
  font-weight: 800;
}

.brief-meta-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.6rem;
  font-size: 0.78rem;
}

.brief-meta-item {
  background: var(--bg-input);
  padding: 0.5rem 0.7rem;
  border-radius: 6px;
}

.brief-meta-item strong {
  display: block;
  font-size: 0.7rem;
  color: var(--text-dim);
  text-transform: uppercase;
}

.brief-box {
  background: #0d1217;
  border-left: 3px solid var(--accent);
  padding: 0.8rem 1rem;
  border-radius: 0 8px 8px 0;
  font-size: 0.82rem;
  line-height: 1.5;
}

.brief-box p {
  color: var(--text-main);
}

.brief-actions {
  display: flex;
  gap: 0.6rem;
  margin-top: 0.5rem;
}

/* Modal */
.modal {
  display: none;
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(4px);
  z-index: 1000;
  align-items: center;
  justify-content: center;
}

.modal.active {
  display: flex;
}

.modal-content {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  width: 90%;
  max-width: 760px;
  max-height: 85vh;
  overflow-y: auto;
  padding: 1.5rem;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
}

.modal-close {
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 1.4rem;
  cursor: pointer;
}

pre {
  background: #080b0f;
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: 1rem;
  overflow-x: auto;
  font-family: var(--font-mono);
  font-size: 0.74rem;
  color: #a5f3fc;
}

.receipt-box {
  background: #0d151e;
  border: 1px solid var(--border-highlight);
  border-radius: 8px;
  padding: 1rem;
  margin-bottom: 1rem;
  font-size: 0.8rem;
}

/* Responsive */
@media (max-width: 1080px) {
  .kpi-grid { grid-template-columns: repeat(2, 1fr); }
  .content-grid { grid-template-columns: 1fr; }
}

/* Stage Switcher Tabs */
.stage-nav {
  display: flex;
  gap: 0.75rem;
  margin-bottom: 1.75rem;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 0.75rem;
}

.stage-btn {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  color: var(--text-muted);
  font-family: var(--font-main);
  font-size: 0.85rem;
  font-weight: 700;
  padding: 0.75rem 1.4rem;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.stage-btn:hover {
  background: var(--bg-card-hover);
  color: #fff;
  border-color: var(--border-highlight);
}

.stage-btn.active {
  background: #141c24;
  color: var(--accent);
  border-color: var(--accent);
  box-shadow: 0 0 16px rgba(200, 238, 113, 0.15);
}

/* Stage 1 Synthesizer Layout */
.synthesis-grid {
  display: grid;
  grid-template-columns: 0.95fr 1.05fr;
  gap: 1.75rem;
  margin-bottom: 2rem;
}

.synthesis-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 14px;
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.five-q-box {
  background: #0d131a;
  border: 1px solid var(--border-highlight);
  border-radius: 10px;
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.q-item {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.q-label {
  font-size: 0.72rem;
  color: var(--accent);
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.q-val {
  font-size: 0.84rem;
  color: var(--text-main);
  line-height: 1.45;
}

.archetype-pill {
  background: var(--accent-glow);
  color: var(--accent);
  border: 1px solid rgba(200, 238, 113, 0.4);
  padding: 0.25rem 0.65rem;
  border-radius: 6px;
  font-weight: 800;
  font-size: 0.75rem;
  display: inline-block;
  margin-bottom: 0.4rem;
}

.stage-view {
  display: none;
}

.stage-view.active {
  display: block;
}

.stage-tag {
  background: var(--accent);
  color: #000;
  font-size: 0.68rem;
  font-weight: 900;
  padding: 0.15rem 0.45rem;
  border-radius: 4px;
  letter-spacing: 0.05em;
}

.stage-header-banner {
  background: #0f151e;
  border: 1px solid var(--border-color);
  border-left: 4px solid var(--accent);
  border-radius: 10px;
  padding: 1rem 1.25rem;
  margin-bottom: 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.banner-text h3 {
  font-size: 0.95rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 0.2rem;
}

.banner-text p {
  font-size: 0.78rem;
  color: var(--text-muted);
}

.synthesis-form {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}

.form-group label {
  font-size: 0.73rem;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.form-group input,
.form-group textarea,
.form-group select {
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  color: var(--text-main);
  padding: 0.6rem 0.8rem;
  border-radius: 6px;
  font-family: var(--font-main);
  font-size: 0.82rem;
  outline: none;
  transition: border-color 0.15s;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
  border-color: var(--accent);
}

.preset-chip-group {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
}

.preset-chip {
  background: #101620;
  border: 1px solid var(--border-highlight);
  color: var(--text-muted);
  padding: 0.45rem 0.75rem;
  border-radius: 6px;
  font-size: 0.74rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s ease;
}

.preset-chip:hover,
.preset-chip.active {
  background: rgba(200, 238, 113, 0.12);
  color: var(--accent);
  border-color: var(--accent);
}

.brain-knowledge-box {
  background: #090e15;
  border: 1px solid #1e2836;
  border-radius: 8px;
  padding: 0.9rem;
  margin-top: 0.75rem;
}

.brain-item {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  padding: 0.4rem 0;
  border-bottom: 1px dashed #17202d;
  font-size: 0.75rem;
}

.brain-item:last-child {
  border-bottom: none;
}

.brain-icon {
  color: var(--accent);
  font-size: 0.85rem;
}

.dpdp-stage2-banner {
  background: rgba(16, 185, 129, 0.06);
  border: 1px solid rgba(16, 185, 129, 0.25);
  border-radius: 8px;
  padding: 0.8rem 1rem;
  margin-bottom: 1.5rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.78rem;
  color: #a7f3d0;
}

/* Drawer Navigation Tabs */
.drawer-tabs {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 0.85rem;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 0.5rem;
}

.drawer-tab {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  color: var(--text-muted);
  font-family: var(--font-main);
  font-size: 0.76rem;
  font-weight: 700;
  padding: 0.45rem 0.85rem;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.drawer-tab:hover {
  background: var(--bg-card-hover);
  color: #fff;
}

.drawer-tab.active {
  background: #141c24;
  color: var(--accent);
  border-color: var(--accent);
}

/* Signal-to-Pitch Sales Kit Styling */
.pitch-kit-container {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

.pitch-metric-badge {
  background: rgba(200, 238, 113, 0.08);
  border: 1px solid rgba(200, 238, 113, 0.3);
  border-radius: 8px;
  padding: 0.65rem 0.85rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.74rem;
}

.pitch-metric-title {
  color: var(--accent);
  font-weight: 800;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.pitch-status-pill {
  font-size: 0.68rem;
  font-weight: 800;
  padding: 0.2rem 0.55rem;
  border-radius: 4px;
  text-transform: uppercase;
  font-family: var(--font-mono);
}

.pitch-status-pending {
  background: rgba(245, 158, 11, 0.2);
  color: #f59e0b;
  border: 1px solid rgba(245, 158, 11, 0.4);
}

.pitch-status-sent {
  background: rgba(16, 185, 129, 0.2);
  color: #10b981;
  border: 1px solid rgba(16, 185, 129, 0.4);
}

.pitch-asset-card {
  background: #0d1219;
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: 0.85rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.pitch-asset-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  padding-bottom: 0.4rem;
}

.pitch-asset-title {
  font-size: 0.78rem;
  font-weight: 800;
  color: #fff;
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.pitch-asset-badge {
  font-size: 0.68rem;
  color: var(--accent);
  font-family: var(--font-mono);
}

.pitch-asset-content {
  font-size: 0.74rem;
  color: var(--text-muted);
  line-height: 1.45;
}

.pitch-script-block {
  background: #080c10;
  border-left: 3px solid var(--accent);
  padding: 0.4rem 0.6rem;
  border-radius: 0 4px 4px 0;
  font-size: 0.72rem;
  margin-top: 0.3rem;
  color: #e2e8f0;
}

.pitch-script-label {
  font-size: 0.65rem;
  font-weight: 700;
  color: var(--accent);
  text-transform: uppercase;
  margin-bottom: 0.15rem;
}

.pitch-bullet-list {
  margin: 0.3rem 0 0 1.1rem;
  font-size: 0.72rem;
  color: var(--text-muted);
  line-height: 1.45;
}

.pitch-crm-actions {
  display: flex;
  gap: 0.6rem;
  margin-top: 0.5rem;
}

/* =========================================================================
   Signal-to-Content Intelligence Pilot Styles (Vendor-Independent Core)
   ========================================================================= */

.intel-summary-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.intel-kpi-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  padding: 1rem 1.15rem;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.intel-kpi-label {
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.intel-kpi-val {
  font-size: 1.6rem;
  font-weight: 800;
  color: #fff;
  font-family: var(--font-mono);
}

.intel-kpi-sub {
  font-size: 0.7rem;
  color: var(--text-dim);
}

.intel-flow-card {
  background: #0c121a;
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 1.25rem;
  margin-bottom: 1.75rem;
}

.intel-flow-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 0.75rem;
  margin-top: 0.85rem;
}

.intel-flow-step {
  background: #080c12;
  border: 1px solid #1a2330;
  border-radius: 8px;
  padding: 0.75rem;
  font-size: 0.73rem;
}

.intel-flow-num {
  font-size: 0.65rem;
  font-weight: 800;
  color: var(--accent);
  font-family: var(--font-mono);
  display: block;
  margin-bottom: 0.2rem;
}

.intel-flow-title {
  font-weight: 700;
  color: #fff;
  margin-bottom: 0.25rem;
}

.intel-flow-desc {
  color: var(--text-muted);
  line-height: 1.4;
}

/* Intelligence Feed Cards */
.intel-cards-list {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.intel-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 1.25rem 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  transition: border-color 0.15s ease;
}

.intel-card:hover {
  border-color: var(--border-highlight);
}

.intel-card-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  padding-bottom: 0.75rem;
}

.intel-entity-title {
  font-size: 1.05rem;
  font-weight: 800;
  color: #fff;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.intel-anonymous-badge {
  background: rgba(148, 163, 184, 0.12);
  color: #cbd5e1;
  border: 1px dashed rgba(148, 163, 184, 0.35);
  font-size: 0.68rem;
  font-weight: 600;
  padding: 0.15rem 0.5rem;
  border-radius: 4px;
}

.intel-verified-badge {
  background: rgba(16, 185, 129, 0.15);
  color: #10b981;
  border: 1px solid rgba(16, 185, 129, 0.3);
  font-size: 0.68rem;
  font-weight: 700;
  padding: 0.15rem 0.5rem;
  border-radius: 4px;
}

.intel-sections-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.intel-box {
  border-radius: 8px;
  padding: 0.85rem 1rem;
  font-size: 0.78rem;
  line-height: 1.45;
}

.intel-box-title {
  font-size: 0.68rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-bottom: 0.35rem;
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.intel-box-evidence {
  background: #090d14;
  border: 1px solid #1a2332;
  color: #e2e8f0;
}

.intel-box-evidence .intel-box-title {
  color: var(--color-blue);
}

.intel-box-hypothesis {
  background: #111218;
  border: 1px solid #282436;
  color: #f3e8ff;
}

.intel-box-hypothesis .intel-box-title {
  color: #c084fc;
}

.intel-action-row {
  background: rgba(200, 238, 113, 0.06);
  border: 1px solid rgba(200, 238, 113, 0.25);
  border-radius: 8px;
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.intel-action-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.tier-pill {
  font-size: 0.7rem;
  font-weight: 800;
  padding: 0.2rem 0.6rem;
  border-radius: 4px;
  text-transform: uppercase;
  font-family: var(--font-mono);
}

.tier-existing { background: rgba(16, 185, 129, 0.2); color: #10b981; }
.tier-page-update { background: rgba(56, 189, 248, 0.2); color: #38bdf8; }
.tier-one-pager { background: rgba(200, 238, 113, 0.2); color: #c8ee71; }
.tier-creative-test { background: rgba(245, 158, 11, 0.2); color: #f59e0b; }
.tier-new-brief { background: rgba(244, 63, 94, 0.2); color: #f43f5e; }

.intel-brain-proof-pill {
  font-size: 0.72rem;
  color: var(--accent);
  background: #0a0f16;
  border: 1px dashed rgba(200, 238, 113, 0.35);
  padding: 0.35rem 0.6rem;
  border-radius: 6px;
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.intel-footer-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  padding-top: 0.75rem;
  font-size: 0.74rem;
}

.intel-review-group {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.intel-learning-card {
  background: #09121c;
  border-left: 3px solid var(--accent);
  padding: 0.65rem 0.85rem;
  border-radius: 0 6px 6px 0;
  font-size: 0.74rem;
  color: #d1fae5;
  margin-top: 0.4rem;
}

/* =========================================================================
   Desktop Prototype: 6-Area Navigation, Header & Central 5-Question UI
   ========================================================================= */

/* Persistent Illustrative Demo Notice */
.demo-banner-persistent {
  background: rgba(245, 158, 11, 0.12);
  border: 1px solid rgba(245, 158, 11, 0.4);
  color: #fde68a;
  border-radius: 8px;
  padding: 0.5rem 1rem;
  font-size: 0.75rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1.25rem;
  cursor: pointer;
  transition: all 0.2s ease;
}
.demo-banner-persistent:hover {
  background: rgba(245, 158, 11, 0.18);
  border-color: #f59e0b;
}

/* Header Enhancements */
.workspace-badge {
  background: #151e2b;
  color: #93c5fd;
  border: 1px solid #2563eb;
  padding: 0.35rem 0.75rem;
  border-radius: 6px;
  font-size: 0.74rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-family: var(--font-mono);
}

.role-switcher {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: #111722;
  border: 1px solid var(--border-color);
  padding: 0.3rem 0.6rem;
  border-radius: 8px;
}

.role-select {
  background: transparent;
  border: none;
  color: var(--accent);
  font-weight: 700;
  font-size: 0.78rem;
  font-family: var(--font-main);
  outline: none;
  cursor: pointer;
}
.role-select option {
  background: #111722;
  color: #fff;
}

/* 6-Screen Desktop Navigation */
.desktop-nav {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 1.75rem;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 0.75rem;
  overflow-x: auto;
}

.nav-tab {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  color: var(--text-muted);
  font-family: var(--font-main);
  font-size: 0.82rem;
  font-weight: 700;
  padding: 0.65rem 1.15rem;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.15s ease;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  white-space: nowrap;
}

.nav-tab:hover {
  background: var(--bg-card-hover);
  color: #fff;
  border-color: var(--border-highlight);
}

.nav-tab.active {
  background: #131b26;
  color: var(--accent);
  border-color: var(--accent);
  box-shadow: 0 0 16px rgba(200, 238, 113, 0.15);
}

.tab-badge {
  background: #1e293b;
  color: #e2e8f0;
  font-size: 0.68rem;
  padding: 0.1rem 0.45rem;
  border-radius: 999px;
  font-family: var(--font-mono);
}

/* Section Container Visibility */
.screen-view {
  display: none;
}
.screen-view.active {
  display: block;
}

/* Lightweight customer-facing welcome and guided workflow */
.welcome-hero { display:grid; grid-template-columns:1.05fr .95fr; gap:clamp(1.5rem,4vw,4rem); align-items:center; padding:clamp(1.5rem,4vw,3.5rem); margin:1.5rem 0; border:1px solid var(--border-color); border-radius:24px; background:linear-gradient(115deg,#fff 35%,#f0f5e7); }
.welcome-hero[hidden], .how-it-works[hidden] { display:none; }
.eyebrow { color:#58742d; text-transform:uppercase; font-size:.72rem; font-weight:800; letter-spacing:.11em; }
.welcome-copy h2,.how-it-works h2 { font-size:clamp(2rem,4vw,3.25rem); line-height:1.08; letter-spacing:-.045em; margin:.75rem 0; }
.welcome-copy h2 em { color:#718b37; font-style:normal; }
.welcome-copy>p { color:#59665a; max-width:610px; font-size:1.02rem; }
.welcome-actions { display:flex; align-items:center; gap:1.2rem; margin:1.4rem 0; flex-wrap:wrap; }
.text-button,.walkthrough-next { background:none; border:0; color:#496329; font:inherit; font-weight:700; cursor:pointer; }
.trust-note { color:#677467; font-size:.78rem; }
.trust-note span { color:#60852d; font-weight:900; }
.explainer-card { background:#fff; padding:.65rem; border:1px solid var(--border-color); border-radius:18px; box-shadow:0 14px 40px #31401a12; }
.video-frame { min-height:280px; position:relative; overflow:hidden; border-radius:13px; cursor:pointer; background:radial-gradient(ellipse at 55% 30%,#f2d6ba 0 12%,transparent 12.5%),linear-gradient(135deg,#dce9c9,#b8cf91 55%,#e9efdd); }
.video-person { position:absolute; left:50%; top:20px; width:150px; height:210px; transform:translateX(-50%); }
.person-face { position:absolute; top:22px; left:47px; width:58px; height:72px; border-radius:48% 48% 45% 45%; background:#bd805d; z-index:2; }
.person-hair { position:absolute; top:9px; left:41px; width:70px; height:52px; border-radius:50% 50% 25% 30%; background:#392a25; z-index:3; }
.person-face i { position:absolute; top:35px; left:13px; width:5px; height:4px; border-radius:50%; background:#30231d; }
.person-face i:nth-child(2) { left:39px; }.person-face b { position:absolute; top:52px; left:24px; width:12px; height:5px; border-bottom:2px solid #713c38; border-radius:50%; }
.person-body { position:absolute; top:83px; left:15px; width:122px; height:140px; border-radius:55px 55px 0 0; background:#536945; }
.play-button { position:absolute; z-index:4; left:50%; top:43%; transform:translate(-50%,-50%); width:58px; height:58px; border:0; border-radius:50%; background:#fff; color:#607c31; font-size:1.2rem; box-shadow:0 5px 18px #0002; cursor:pointer; }
.video-caption { position:absolute; z-index:4; left:1rem; right:1rem; bottom:1rem; display:grid; gap:.25rem; color:#fff; text-shadow:0 1px 8px #18220e; }
.video-caption small { font-size:.65rem; letter-spacing:.1em; font-weight:800; }.video-caption strong { font-size:1.1rem; max-width:440px; }
.video-duration { position:absolute; right:.7rem; top:.7rem; background:#fffC; color:#34422d; padding:.15rem .45rem; border-radius:5px; font-size:.7rem; font-weight:700; }
.video-note { padding:.7rem .4rem .25rem; color:#59665a; font-size:.78rem; }.video-note span { color:#82907c; }.video-note .walkthrough-live { color:#54732c; font-weight:800; }
.how-it-works { padding:1.5rem 0 2rem; }.how-it-works h2 { font-size:1.8rem; max-width:720px; }
.journey-steps { display:grid; grid-template-columns:repeat(4,1fr); gap:.8rem; margin-top:1rem; }
.journey-steps article { padding:1rem; border:1px solid var(--border-color); border-radius:12px; background:#fff; }.journey-steps b { color:#77923e; font:700 .75rem var(--font-mono); }.journey-steps h3 { margin:.45rem 0; font-size:.94rem; }.journey-steps p { color:var(--text-muted); font-size:.8rem; }
@media(max-width:850px) { .welcome-hero { grid-template-columns:1fr; }.journey-steps { grid-template-columns:repeat(2,1fr); } }
@media(max-width:480px) { .journey-steps { grid-template-columns:1fr; }.video-frame { min-height:230px; } }

/* Central 5-Question Detail View */
.detail-5q-container {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  margin-bottom: 2rem;
}

.detail-top-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 1rem;
}

.detail-back-btn {
  background: transparent;
  border: 1px solid var(--border-color);
  color: var(--text-muted);
  font-size: 0.76rem;
  padding: 0.35rem 0.75rem;
  border-radius: 6px;
  cursor: pointer;
  font-weight: 600;
  margin-bottom: 0.5rem;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}
.detail-back-btn:hover {
  color: #fff;
  border-color: var(--accent);
}

.five-questions-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
}

.question-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.question-card.highlight {
  border-color: rgba(200, 238, 113, 0.4);
  background: linear-gradient(180deg, #121822 0%, #0e141c 100%);
}

.q-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  padding-bottom: 0.75rem;
}

.q-title {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 1rem;
  font-weight: 800;
  color: #fff;
}

.q-num-badge {
  background: var(--accent);
  color: #000;
  font-size: 0.7rem;
  font-weight: 900;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.q-subtitle {
  font-size: 0.75rem;
  color: var(--text-dim);
}

.evidence-fact-box {
  background: #090e16;
  border: 1px solid #1c2738;
  border-left: 4px solid var(--color-blue);
  border-radius: 6px;
  padding: 1rem 1.25rem;
  font-size: 0.88rem;
  line-height: 1.5;
  color: #f1f5f9;
}

.hypothesis-box {
  background: #12101a;
  border: 1px solid #32254a;
  border-left: 4px solid #c084fc;
  border-radius: 6px;
  padding: 1rem 1.25rem;
  font-size: 0.88rem;
  line-height: 1.5;
  color: #f5f3ff;
}

.hypothesis-warning-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  background: rgba(192, 132, 252, 0.15);
  color: #d8b4fe;
  border: 1px solid rgba(192, 132, 252, 0.3);
  font-size: 0.7rem;
  font-weight: 800;
  padding: 0.2rem 0.5rem;
  border-radius: 4px;
  text-transform: uppercase;
  margin-bottom: 0.5rem;
  letter-spacing: 0.04em;
}

.missing-info-card {
  background: rgba(245, 158, 11, 0.06);
  border: 1px dashed rgba(245, 158, 11, 0.35);
  border-radius: 6px;
  padding: 0.75rem 1rem;
  font-size: 0.78rem;
  color: #fde68a;
  margin-top: 0.6rem;
}

.two-col-evidence-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
}

.evidence-subcard {
  background: #0a0f16;
  border: 1px solid #1a2433;
  border-radius: 8px;
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.evidence-subcard h5 {
  font-size: 0.8rem;
  font-weight: 800;
  color: #fff;
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.research-item {
  background: #0f1724;
  border-radius: 6px;
  padding: 0.75rem;
  border: 1px solid #1e293b;
  font-size: 0.76rem;
  line-height: 1.45;
}

.research-source {
  font-weight: 700;
  color: var(--accent);
  margin-bottom: 0.25rem;
}

.research-caveat {
  font-size: 0.7rem;
  color: #f59e0b;
  margin-top: 0.35rem;
  font-style: italic;
}

.brand-proof-item {
  background: #0f1724;
  border-radius: 6px;
  padding: 0.75rem;
  border: 1px solid #1e293b;
  font-size: 0.76rem;
}

.brand-proof-title {
  font-weight: 700;
  color: #fff;
  margin-bottom: 0.25rem;
}

.brand-proof-rights {
  font-size: 0.68rem;
  color: #10b981;
  font-weight: 700;
}

/* Action & Dual Approval Box */
.action-prescription-box {
  background: rgba(200, 238, 113, 0.08);
  border: 1px solid rgba(200, 238, 113, 0.35);
  border-radius: 8px;
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.action-title-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.dual-approval-panel {
  background: #0b1118;
  border: 1px solid #1e2a3a;
  border-radius: 8px;
  padding: 1rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 0.5rem;
}

.approval-role-badge {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.78rem;
}

.approval-status-pill {
  font-size: 0.68rem;
  font-weight: 800;
  padding: 0.2rem 0.55rem;
  border-radius: 4px;
  font-family: var(--font-mono);
  text-transform: uppercase;
}

.approval-status-approved {
  background: rgba(16, 185, 129, 0.2);
  color: #10b981;
  border: 1px solid rgba(16, 185, 129, 0.4);
}

.approval-status-pending {
  background: rgba(245, 158, 11, 0.2);
  color: #f59e0b;
  border: 1px solid rgba(245, 158, 11, 0.4);
}

/* Outcome Measurement Box */
.outcome-measurement-box {
  background: #090e16;
  border: 1px solid #1d2737;
  border-radius: 8px;
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.awaiting-measurement-badge {
  background: rgba(245, 158, 11, 0.15);
  color: #fbbf24;
  border: 1px solid rgba(245, 158, 11, 0.4);
  font-size: 0.75rem;
  font-weight: 800;
  padding: 0.25rem 0.75rem;
  border-radius: 6px;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}

/* Recommendations 6-Tier Grid */
.recommendations-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
  margin-bottom: 2rem;
}

.rec-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 1rem;
  transition: all 0.2s ease;
}
.rec-card:hover {
  border-color: var(--border-highlight);
  transform: translateY(-2px);
}

/* 4-Tier Learning Taxonomy Grid */
.taxonomy-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
  margin-bottom: 2rem;
}

.taxonomy-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  padding: 1.15rem;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.taxonomy-card.active {
  border-color: var(--accent);
  background: #111a24;
}

.taxonomy-num {
  font-size: 0.68rem;
  font-weight: 800;
  color: var(--accent);
  font-family: var(--font-mono);
}

.taxonomy-title {
  font-size: 0.92rem;
  font-weight: 800;
  color: #fff;
}

.taxonomy-desc {
  font-size: 0.75rem;
  color: var(--text-muted);
  line-height: 1.45;
}

/* Connections Guided Cards */
.connections-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
  margin-bottom: 2rem;
}

.connector-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 1rem;
}

.connector-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}

.perm-pill {
  font-size: 0.68rem;
  font-weight: 800;
  padding: 0.15rem 0.5rem;
  border-radius: 4px;
  font-family: var(--font-mono);
  text-transform: uppercase;
}

.perm-readonly {
  background: rgba(56, 189, 248, 0.15);
  color: #38bdf8;
  border: 1px solid rgba(56, 189, 248, 0.35);
}

.perm-publish {
  background: rgba(200, 238, 113, 0.15);
  color: var(--accent);
  border: 1px solid rgba(200, 238, 113, 0.35);
}

.inscope-tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-top: 0.4rem;
}

.inscope-tag {
  background: #0d141e;
  color: #94a3b8;
  font-size: 0.68rem;
  padding: 0.15rem 0.45rem;
  border-radius: 4px;
  border: 1px solid #1e293b;
  font-family: var(--font-mono);
}

/* Responsive Overrides */
@media (max-width: 1280px) {
  .recommendations-grid { grid-template-columns: repeat(2, 1fr); }
  .connections-grid { grid-template-columns: repeat(2, 1fr); }
  .taxonomy-grid { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 900px) {
  .recommendations-grid { grid-template-columns: 1fr; }
  .connections-grid { grid-template-columns: 1fr; }
  .taxonomy-grid { grid-template-columns: 1fr; }
  .two-col-evidence-grid { grid-template-columns: 1fr; }
}

/* =========================================================================
   ROLE PERMISSIONS MATRIX TABLE & LINEAGE CHAIN STYLES
   ========================================================================= */

.role-matrix-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.76rem;
  margin-top: 1rem;
}

.role-matrix-table th, .role-matrix-table td {
  padding: 0.65rem 0.85rem;
  text-align: left;
  border-bottom: 1px solid #1e293b;
}

.role-matrix-table th {
  background: #0f1622;
  color: #fff;
  font-weight: 700;
  text-transform: uppercase;
  font-size: 0.7rem;
  letter-spacing: 0.03em;
}

.role-matrix-table tr:hover {
  background: #111a28;
}

.perm-check {
  color: #10b981;
  font-weight: 700;
}

.perm-cross {
  color: #64748b;
  font-weight: 500;
}

.perm-view {
  color: #38bdf8;
  font-weight: 600;
  font-size: 0.7rem;
}

/* Traceable Lineage Flow */
.lineage-chain-container {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  position: relative;
  padding: 0.5rem 0 1rem 0;
}

.lineage-step {
  display: flex;
  gap: 1.25rem;
  background: #0c1219;
  border: 1px solid #1a2536;
  border-radius: 8px;
  padding: 1rem;
  position: relative;
}

.lineage-step:hover {
  border-color: rgba(200, 238, 113, 0.4);
}

.lineage-num-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 32px;
}

.lineage-num-circle {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: #1e293b;
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.8rem;
  font-family: var(--font-mono);
  border: 1px solid rgba(200, 238, 113, 0.4);
}

.lineage-content-col {
  flex: 1;
}

.lineage-step-title {
  font-size: 0.88rem;
  font-weight: 800;
  color: #fff;
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.35rem;
}

.lineage-step-detail {
  font-size: 0.76rem;
  color: #94a3b8;
  line-height: 1.45;
}

/* Data Quality Breakdown Grid */
.dq-breakdown-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.5rem;
  margin-top: 0.6rem;
}

.dq-factor-card {
  background: #0b1119;
  border: 1px solid #192334;
  border-radius: 6px;
  padding: 0.5rem 0.6rem;
}

.dq-factor-title {
  font-size: 0.68rem;
  color: var(--text-dim);
  text-transform: uppercase;
  font-weight: 700;
}

.dq-factor-val {
  font-size: 0.95rem;
  font-weight: 800;
  color: var(--accent);
  font-family: var(--font-mono);
  margin-top: 0.15rem;
}

.dq-factor-weight {
  font-size: 0.65rem;
  color: var(--text-muted);
}

/* Diagnostic Gates Box */
.diagnostic-gate-container {
  background: #0a111a;
  border: 1px solid #1d2a3d;
  border-radius: 8px;
  padding: 0.85rem;
  margin-top: 0.75rem;
}

.gate-item {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  font-size: 0.76rem;
  padding: 0.4rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.gate-item:last-child {
  border-bottom: none;
}

.gate-badge-pass {
  background: rgba(16, 185, 129, 0.2);
  color: #10b981;
  font-size: 0.65rem;
  font-weight: 800;
  padding: 0.1rem 0.4rem;
  border-radius: 3px;
  font-family: var(--font-mono);
  text-transform: uppercase;
}

/* Alternative Hypotheses Grid */
.alt-hypotheses-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.6rem;
  margin-top: 0.6rem;
}

.alt-hypo-card {
  background: #0a0e14;
  border: 1px solid #1b2432;
  border-radius: 6px;
  padding: 0.6rem 0.75rem;
  font-size: 0.74rem;
}

.alt-hypo-title {
  font-weight: 700;
  color: #e2e8f0;
  display: flex;
  justify-content: space-between;
  margin-bottom: 0.25rem;
}

.alt-hypo-desc {
  color: #94a3b8;
  line-height: 1.35;
}

/* Unified Advertising & Attribution Layer Styles */
.perm-tier-row {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 0.75rem;
  background: #0a0e14;
  border: 1px solid #1e293b;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.15s ease;
}

.perm-tier-row:hover {
  background: #0f1724;
  border-color: #334155;
}

.perm-tier-row input[type="checkbox"] {
  margin-top: 0.2rem;
  accent-color: var(--accent);
  cursor: pointer;
  width: 16px;
  height: 16px;
}

.commercial-truth-banner {
  background: linear-gradient(135deg, rgba(200, 238, 113, 0.08), rgba(56, 189, 248, 0.08));
  border: 1px solid rgba(200, 238, 113, 0.3);
  border-radius: 6px;
  padding: 0.85rem 1rem;
  font-size: 0.78rem;
  color: #e2e8f0;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.ad-comparison-card {
  background: #0a0e14;
  border: 1px solid #1e293b;
  border-radius: 8px;
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.ad-comparison-card.vanity {
  border-left: 3px solid #ef4444;
}

.ad-comparison-card.commercial {
  border-left: 3px solid var(--accent);
}

.ad-metric-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.5rem;
  background: #06090e;
  padding: 0.6rem;
  border-radius: 6px;
}

.ad-metric-item {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.ad-metric-label {
  font-size: 0.65rem;
  color: var(--text-muted);
  text-transform: uppercase;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.ad-metric-val {
  font-size: 0.95rem;
  font-weight: 800;
  font-family: var(--font-mono);
}

.diagnostic-matrix-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.75rem;
  margin-top: 0.5rem;
}

.diagnostic-matrix-table th {
  background: #090e15;
  color: #94a3b8;
  text-align: left;
  padding: 0.6rem 0.75rem;
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  border-bottom: 1px solid #1e293b;
}

.diagnostic-matrix-table td {
  padding: 0.75rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
  vertical-align: top;
  line-height: 1.4;
}

.diagnostic-matrix-table tr:hover td {
  background: rgba(255, 255, 255, 0.02);
}

.diag-status-badge {
  display: inline-block;
  padding: 0.15rem 0.5rem;
  border-radius: 3px;
  font-weight: 800;
  font-size: 0.65rem;
  font-family: var(--font-mono);
  text-transform: uppercase;
}

.diag-status-critical {
  background: rgba(239, 68, 68, 0.2);
  color: #f87171;
  border: 1px solid rgba(239, 68, 68, 0.4);
}

.diag-status-normal {
  background: rgba(16, 185, 129, 0.15);
  color: #34d399;
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.diag-status-high {
  background: rgba(245, 158, 11, 0.15);
  color: #fbbf24;
  border: 1px solid rgba(245, 158, 11, 0.3);
}

.attribution-metric-box {
  background: #080c12;
  border: 1px solid #1e293b;
  border-radius: 6px;
  padding: 0.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.attribution-metric-box .label {
  font-size: 0.68rem;
  color: var(--text-muted);
  text-transform: uppercase;
  font-weight: 700;
}

.attribution-metric-box .value {
  font-size: 1.15rem;
  font-weight: 800;
  font-family: var(--font-mono);
  color: #fff;
}

.attribution-metric-box .sub {
  font-size: 0.68rem;
  color: var(--text-dim);
}


