/* =========================================================================
   Global Variables & Base Setup (Signal-to-Noise Palette)
   ========================================================================= */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=Lora:ital,wght@0,400;0,500;0,600;1,400;1,500&display=swap');

:root {
  /* Signal-to-Noise Color Palette */
  --bg-color: #FAFAF8;
  /* Clean warm white */
  --surface-light: #FFFFFF;
  /* Pure white for cards */
  --text-primary: #1A1A1A;
  /* Near-black for maximum signal */
  --text-secondary: #525252;
  /* Softer gray */

  --accent-primary: #D97706;
  /* Ochre/Amber - "The Signal" */
  --accent-secondary: #4338CA;
  /* Indigo - "The Structure" */
  --accent-tertiary: #059669;
  /* Emerald - "The Success" */

  /* Legacy aliases for backward compatibility */
  --accent-blue: #D97706;
  --accent-teal: #4338CA;

  --border-color: #E5E5E0;
  /* Clean taupe */

  /* Ambient, diffused shadows */
  --shadow-sm: 0 4px 12px rgba(26, 26, 26, 0.04);
  --shadow-md: 0 10px 24px rgba(26, 26, 26, 0.06);
  --shadow-lg: 0 20px 40px rgba(26, 26, 26, 0.08);

  /* CS4 Dark Mode - Deep Signal Theme */
  --dark-bg: #0F0F12;
  --dark-surface: #1A1A1E;
  --dark-text: #F5F5F5;
  --dark-text-sec: #A3A3A3;
  --dark-border: #2A2A2E;
  --dark-accent: #F59E0B;

  /* Typography System */
  --font-main: 'Inter', system-ui, -apple-system, sans-serif;
  --font-serif: 'Lora', Georgia, serif;

  --max-width: 1280px;
  --section-pad-y: 6rem;
}

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

body {
  font-family: var(--font-main);
  background-color: var(--bg-color);
  color: var(--text-primary);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

h1,
h2,
h3,
h4 {
  font-family: var(--font-serif);
  font-weight: 500;
  line-height: 1.3;
  letter-spacing: -0.01em;
  margin-bottom: 1rem;
  color: var(--text-primary);
  overflow-wrap: break-word;
}

h2 {
  font-size: 2.25rem;
}

p {
  font-family: var(--font-main);
  color: var(--text-secondary);
  font-size: 1.125rem;
  line-height: 1.8;
  letter-spacing: 0.01em;
  margin-bottom: 1.5rem;
}

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 2rem;
}

section {
  padding: var(--section-pad-y) 0;
}

.section-spacer {
  height: 4rem;
  background: linear-gradient(180deg, var(--bg-color) 0%, var(--surface-light) 50%, var(--bg-color) 100%);
  border-top: 1px solid var(--border-color);
  border-bottom: 1px solid var(--border-color);
}

/* =========================================================================
   Layout Patterns & Components
   ========================================================================= */

/* Hero Glassmorphism */
.hero-wrapper {
  position: relative;
  padding: 10rem 0 6rem;
  text-align: center;
  overflow: hidden;
}

/* Hero Eyebrow & Badges */
.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
  justify-content: center;
}

.hero-badge {
  padding: 0.5rem 1rem;
  background: rgba(217, 119, 6, 0.1);
  border: 1px solid rgba(217, 119, 6, 0.2);
  border-radius: 50px;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--accent-primary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.hero-badge.secondary {
  background: rgba(67, 56, 202, 0.1);
  border-color: rgba(67, 56, 202, 0.2);
  color: var(--accent-secondary);
}

.hero-divider {
  color: var(--border-color);
  font-size: 1.2rem;
}

/* Hero Typography */
.hero-glass-card h1 {
  font-size: 3.5rem;
  line-height: 1.15;
  margin-bottom: 1.5rem;
}

.text-human {
  color: var(--accent-primary);
  position: relative;
}

.text-tech {
  color: var(--accent-secondary);
  position: relative;
}

.hero-subtitle {
  font-size: 1.25rem;
  line-height: 1.7;
  color: var(--text-secondary);
  max-width: 700px;
  margin: 0 auto 2rem;
}

/* Hero Value Props */
.hero-value-props {
  display: flex;
  justify-content: center;
  gap: 2rem;
  margin-top: 2rem;
  flex-wrap: wrap;
}

.value-prop {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.875rem 1.25rem;
  background: var(--surface-light);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  box-shadow: var(--shadow-sm);
}

.vp-number {
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--accent-primary);
  font-family: var(--font-main);
}

.vp-text {
  font-size: 0.95rem;
  color: var(--text-primary);
  font-weight: 500;
}

.hero-glow {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(166, 93, 71, 0.1) 0%, transparent 70%);
  /* Terracotta glow */
  filter: blur(80px);
  z-index: 0;
  pointer-events: none;
}

.hero-glass-card {
  position: relative;
  z-index: 1;
  max-width: 900px;
  margin: 0 auto;
  padding: 4rem 3rem;
  background: rgba(255, 255, 255, 0.85);
  /* Clean white card */
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid var(--border-color);
  /* taupe border */
  border-radius: 20px;
  /* softer corners */
  box-shadow: var(--shadow-lg);
  transition: all 0.5s ease-in-out;
}

.hero-glass-card h1 {
  font-size: 3rem;
  margin-bottom: 1.5rem;
  line-height: 1.1;
  color: var(--text-primary);
}

.hero-glass-card p {
  font-size: 1.25rem;
  color: var(--text-primary);
  opacity: 0.9;
  line-height: 1.7;
}

/* Two-Column Split Screen */
.split-screen {
  display: grid;
  grid-template-columns: 1fr;
  gap: 4rem;
  align-items: center;
}

@media (min-width: 1024px) {
  .split-screen {
    grid-template-columns: 1fr 1fr;
    gap: 6rem;
  }
}

/* Alternating Layout Support */
@media (min-width: 1024px) {
  .split-screen.reverse .content-col {
    order: 2;
  }

  .split-screen.reverse .visual-col {
    order: 1;
  }
}

/* =========================================================================
   CS3: Crucible App Visualizations
   ========================================================================= */

/* Stage 1: CSV Raw Data Preview */
.cs3-csv-preview {
  margin-top: 1rem;
  background: #f8f9fa;
  border: 1px solid var(--border-color);
  border-radius: 8px;
  overflow: hidden;
}

.csv-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 0.75rem;
  background: var(--surface-light);
  border-bottom: 1px solid var(--border-color);
  font-size: 0.75rem;
  color: var(--text-secondary);
}

.csv-data {
  padding: 0.75rem;
  font-family: 'SF Mono', 'Monaco', 'Inconsolata', monospace;
  font-size: 0.7rem;
  line-height: 1.6;
}

.csv-row {
  color: var(--text-secondary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.csv-row.header {
  color: var(--accent-secondary);
  font-weight: 600;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 0.25rem;
  margin-bottom: 0.25rem;
}

.csv-row.noise {
  color: #9ca3af;
  font-style: italic;
  margin-top: 0.25rem;
}

/* Stage 2: Crucible Engine */
.cs3-crucible-engine {
  margin-top: 1rem;
  background: linear-gradient(135deg, #f8f9fa 0%, #e5e7eb 100%);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 1rem;
}

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

.crucible-title {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-primary);
}

.crucible-badge {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  font-size: 0.65rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 0.25rem 0.5rem;
  background: rgba(5, 150, 105, 0.1);
  color: #059669;
  border-radius: 50px;
}

.crucible-flow {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
}

.flow-input,
.flow-output {
  width: 100%;
  text-align: center;
}

.flow-row {
  font-size: 0.75rem;
  padding: 0.375rem 0.75rem;
  background: var(--surface-light);
  border: 1px solid var(--border-color);
  border-radius: 6px;
  margin-bottom: 0.375rem;
}

.flow-row.raw {
  color: var(--text-secondary);
}

.flow-card {
  display: inline-block;
  font-size: 0.7rem;
  padding: 0.375rem 0.625rem;
  background: rgba(217, 119, 6, 0.1);
  border: 1px solid rgba(217, 119, 6, 0.3);
  border-radius: 6px;
  color: var(--accent-primary);
  margin: 0 0.25rem;
}

.flow-arrow {
  font-size: 1rem;
  color: var(--border-color);
  animation: flowPulse 1.5s ease-in-out infinite;
}

@keyframes flowPulse {

  0%,
  100% {
    opacity: 0.4;
    transform: translateY(0);
  }

  50% {
    opacity: 1;
    transform: translateY(2px);
  }
}

.crucible-core {
  position: relative;
  width: 80px;
  height: 80px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.core-ring {
  position: absolute;
  border-radius: 50%;
  border: 2px solid var(--accent-secondary);
}

.ring-1 {
  width: 60px;
  height: 60px;
  animation: crucibleSpin 3s linear infinite;
  border-top-color: transparent;
}

.ring-2 {
  width: 40px;
  height: 40px;
  animation: crucibleSpin 2s linear infinite reverse;
  border-bottom-color: transparent;
}

@keyframes crucibleSpin {
  from {
    transform: rotate(0deg);
  }

  to {
    transform: rotate(360deg);
  }
}

.core-label {
  font-size: 0.65rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  color: var(--accent-secondary);
}

/* Stage 3: PDF Preview */
.cs3-pdf-preview {
  margin-top: 1rem;
  background: var(--surface-light);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.pdf-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.625rem 0.875rem;
  background: rgba(217, 119, 6, 0.1);
  border-bottom: 1px solid var(--border-color);
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--text-primary);
}

.pdf-body {
  padding: 1rem;
}

.pdf-section {
  margin-bottom: 1rem;
}

.pdf-section:last-child {
  margin-bottom: 0;
}

.pdf-label {
  font-size: 0.75rem;
  color: var(--text-secondary);
  margin-bottom: 0.5rem;
}

.pdf-progress {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.progress-bar {
  flex: 1;
  height: 8px;
  background: var(--border-color);
  border-radius: 4px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--accent-primary), #f59e0b);
  border-radius: 4px;
  transition: width 0.5s ease;
}

.progress-value {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-primary);
}

.pdf-metric {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--accent-primary);
}

.pdf-alert {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.625rem 0.875rem;
  background: rgba(239, 68, 68, 0.08);
  border: 1px solid rgba(239, 68, 68, 0.2);
  border-radius: 6px;
  font-size: 0.8rem;
  color: #dc2626;
}

.pdf-alert svg {
  flex-shrink: 0;
}





/* Glow for urgent case weights */
.glow-urgent {
  animation: urgentPulse 1.5s ease-in-out infinite;
}

@keyframes urgentPulse {

  0%,
  100% {
    box-shadow: 0 0 5px rgba(239, 68, 68, 0.4);
    border-color: rgba(239, 68, 68, 0.6);
  }

  50% {
    box-shadow: 0 0 20px rgba(239, 68, 68, 0.6);
    border-color: rgba(239, 68, 68, 1);
  }
}

/* =========================================================================
   CS1: Sticky Text Column & ROI Callout
   ========================================================================= */

.cs1-split {
  align-items: flex-start;
}

.cs1-sticky {
  position: sticky;
  top: 100px;
  align-self: flex-start;
}

.cs1-roi-callout {
  background: linear-gradient(135deg, var(--accent-primary) 0%, #b45309 100%);
  border-radius: 12px;
  padding: 1.5rem;
  margin-top: 2rem;
  text-align: center;
  box-shadow: 0 10px 30px rgba(217, 119, 6, 0.25);
}

.cs1-roi-callout .roi-arrow {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  margin-bottom: 0.5rem;
}

.cs1-roi-callout .roi-from {
  font-size: 1.1rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.7);
  text-decoration: line-through;
}

.cs1-roi-callout .roi-to {
  font-size: 1.5rem;
  font-weight: 700;
  color: white;
}

.cs1-roi-callout .roi-arrow svg {
  color: rgba(255, 255, 255, 0.8);
}

.cs1-roi-callout .roi-label {
  font-size: 0.875rem;
  color: rgba(255, 255, 255, 0.9);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-weight: 500;
}

@media (max-width: 1023px) {
  .cs1-sticky {
    position: relative;
    top: 0;
  }
}

/* CS2 & CS3 Sticky Positioning */
.cs2-split,
.cs3-split {
  align-items: flex-start;
}

.cs2-sticky,
.cs3-sticky {
  position: sticky;
  top: 100px;
  align-self: flex-start;
}

@media (max-width: 1023px) {

  .cs2-sticky,
  .cs3-sticky {
    position: relative;
    top: 0;
  }
}

/* CS2 ROI Variant */
.cs2-roi {
  background: linear-gradient(135deg, var(--accent-secondary) 0%, #3730a3 100%);
  box-shadow: 0 10px 30px rgba(67, 56, 202, 0.25);
}

/* CS3 ROI Variant */
.cs3-roi {
  background: linear-gradient(135deg, #059669 0%, #047857 100%);
  box-shadow: 0 10px 30px rgba(5, 150, 105, 0.25);
}

/* CS2 Launch Tool Button */
.cs2-launch-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  width: 100%;
  margin-top: 1rem;
  padding: 0.75rem 1rem;
  background: rgba(67, 56, 202, 0.1);
  border: 1px solid rgba(67, 56, 202, 0.3);
  border-radius: 8px;
  color: var(--accent-secondary);
  font-size: 0.85rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
}

.cs2-launch-btn:hover {
  background: rgba(67, 56, 202, 0.2);
  border-color: rgba(67, 56, 202, 0.5);
}

/* =========================================================================
   Master Narrative Section
   ========================================================================= */

#master-narrative {
  padding: 5rem 0;
  border-bottom: 1px solid var(--border-color);
}

.narrative-intro {
  text-align: center;
  max-width: 700px;
  margin: 0 auto 3rem;
}

.narrative-intro h2 {
  font-size: 2.5rem;
  margin-bottom: 1rem;
}

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

@media (max-width: 1024px) {
  .narrative-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 640px) {
  .narrative-grid {
    grid-template-columns: 1fr;
  }
}

.narrative-card {
  position: relative;
  background: var(--surface-light);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 1.5rem;
  box-shadow: var(--shadow-sm);
  transition: all 0.3s ease;
}

.narrative-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: var(--accent-primary);
}

.phase-number {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--accent-primary);
  margin-bottom: 0.75rem;
}

.narrative-card h3 {
  font-size: 1.15rem;
  margin-bottom: 0.75rem;
  color: var(--text-primary);
}

.narrative-card p {
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.6;
  margin: 0;
}

.phase-arrow {
  position: absolute;
  right: -1.25rem;
  top: 50%;
  transform: translateY(-50%);
  width: 2rem;
  height: 2rem;
  background: var(--accent-primary);
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  z-index: 1;
}

@media (max-width: 1024px) {
  .phase-arrow {
    display: none;
  }
}

/* Executive Summary */
.executive-summary {
  background: linear-gradient(135deg, rgba(217, 119, 6, 0.05) 0%, rgba(67, 56, 202, 0.05) 100%);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 2rem;
  max-width: 1000px;
  margin: 0 auto;
}

.es-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1rem;
  color: var(--accent-primary);
}

.es-header h4 {
  font-size: 1.1rem;
  margin: 0;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.es-body {
  font-size: 1.05rem;
  line-height: 1.8;
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
}

.es-metrics {
  display: flex;
  gap: 2rem;
  justify-content: center;
  flex-wrap: wrap;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border-color);
}

.es-metric {
  text-align: center;
}

.es-value {
  display: block;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--accent-primary);
  font-family: var(--font-main);
}

.es-label {
  font-size: 0.85rem;
  color: var(--text-secondary);
}

/* =========================================================================
   Case Study Layout Components
   ========================================================================= */

.story-block {
  margin-bottom: 1.5rem;
}

.story-block h4 {
  font-size: 0.9rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--accent-primary);
  margin-bottom: 0.5rem;
}

.story-block p {
  font-size: 1rem;
  line-height: 1.7;
  color: var(--text-secondary);
  margin: 0;
}

.story-block em {
  color: var(--text-primary);
  font-style: normal;
  font-weight: 500;
}

.roi-block {
  margin-top: 2rem;
  padding: 1.25rem;
  background: rgba(217, 119, 6, 0.05);
  border: 1px solid rgba(217, 119, 6, 0.2);
  border-left: 4px solid var(--accent-primary);
  border-radius: 12px;
}

.roi-block.secondary {
  background: rgba(67, 56, 202, 0.05);
  border-color: rgba(67, 56, 202, 0.2);
  border-left-color: var(--accent-secondary);
}

.roi-block.secondary .roi-header {
  color: var(--accent-secondary);
}

.roi-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--accent-primary);
  margin-bottom: 0.5rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.roi-block p {
  font-size: 0.95rem;
  line-height: 1.6;
  color: var(--text-primary);
  margin: 0;
}

.visual-title {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--border-color);
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-primary);
}

.visual-title svg {
  color: var(--accent-primary);
}

/* =========================================================================
   CS1: Before/After Comparison & Horizontal Timeline
   ========================================================================= */

.before-after-comparison {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.before-state,
.after-state {
  background: var(--surface-light);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 1.25rem;
}

.before-state {
  border-left: 4px solid #ef4444;
}

.after-state {
  border-left: 4px solid #22c55e;
}

.state-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1rem;
}

.state-label {
  padding: 0.25rem 0.625rem;
  border-radius: 4px;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.state-label.before {
  background: #fee2e2;
  color: #dc2626;
}

.state-label.after {
  background: #dcfce7;
  color: #16a34a;
}

.state-title {
  font-weight: 600;
  color: var(--text-primary);
  font-size: 0.95rem;
}

/* Chaos Visual - Before State */
.chaos-visual {
  position: relative;
}

.doc-pile {
  position: relative;
  height: 100px;
  margin-bottom: 1rem;
}

.chaos-doc {
  position: absolute;
  padding: 0.5rem 0.875rem;
  background: var(--surface-light);
  border: 1px solid var(--border-color);
  border-radius: 6px;
  font-size: 0.8rem;
  color: var(--text-secondary);
  box-shadow: var(--shadow-sm);
}

.chaos-doc.missing {
  background: #fee2e2;
  border-color: #fecaca;
  color: #dc2626;
  font-weight: 600;
}

.confusion-indicators {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.confusion-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  color: var(--text-secondary);
}

/* Transition Arrow */
.transition-arrow {
  display: flex;
  justify-content: center;
  color: var(--accent-primary);
}

/* Horizontal Timeline - After State */
.horizontal-timeline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1rem;
  padding: 0.5rem 0;
}

.ht-phase {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.375rem;
}

.ht-dot {
  width: 12px;
  height: 12px;
  background: var(--border-color);
  border-radius: 50%;
  transition: all 0.3s ease;
}

.ht-dot.active {
  background: var(--accent-primary);
  box-shadow: 0 0 0 4px rgba(217, 119, 6, 0.2);
}

.ht-label {
  font-size: 0.7rem;
  color: var(--text-secondary);
  font-weight: 500;
}

.ht-line {
  flex: 1;
  height: 2px;
  background: var(--border-color);
  margin: 0 0.25rem;
  margin-bottom: 1rem;
}

/* Improvement Indicators */
.improvement-indicators {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.improvement-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  color: var(--text-secondary);
}

/* =========================================================================
   CS1: Vertical Knowledge Stepper (Lifecycle Thread)
   ========================================================================= */

.lifecycle-stepper {
  display: flex;
  flex-direction: column;
  gap: 0;
  position: relative;
}

.stepper-item {
  display: flex;
  gap: 1rem;
  position: relative;
}

.stepper-marker {
  display: flex;
  flex-direction: column;
  align-items: center;
  flex-shrink: 0;
  width: 32px;
}

.stepper-dot {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--surface-light);
  border: 2px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-secondary);
  transition: all 0.3s ease;
  z-index: 2;
}

.stepper-item.active .stepper-dot,
.stepper-item:hover .stepper-dot {
  background: var(--accent-primary);
  border-color: var(--accent-primary);
  color: white;
}

.stepper-line {
  width: 2px;
  flex: 1;
  min-height: 40px;
  background: var(--border-color);
  margin: 0.5rem 0;
}

.stepper-item:last-child .stepper-line {
  display: none;
}

.stepper-card {
  flex: 1;
  background: var(--surface-light);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  margin-bottom: 1rem;
  overflow: hidden;
  transition: all 0.3s ease;
}

.stepper-item.decision-hub .stepper-card {
  border-color: rgba(67, 56, 202, 0.3);
  box-shadow: 0 0 0 1px rgba(67, 56, 202, 0.1);
}

.stepper-item.decision-hub.active .stepper-card,
.stepper-item.decision-hub:hover .stepper-card {
  border-color: rgba(67, 56, 202, 0.5);
  box-shadow: 0 0 20px rgba(67, 56, 202, 0.15), 0 0 0 1px rgba(67, 56, 202, 0.2);
}

.stepper-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem 1.25rem;
  cursor: pointer;
  user-select: none;
  transition: all 0.2s ease;
}

.stepper-header:hover {
  background: rgba(217, 119, 6, 0.03);
}

.stepper-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: rgba(217, 119, 6, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent-primary);
  flex-shrink: 0;
}

.stepper-item.decision-hub .stepper-icon {
  background: rgba(67, 56, 202, 0.1);
  color: var(--accent-secondary);
}

.stepper-title {
  flex: 1;
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--text-primary);
}

.hub-badge {
  display: inline-block;
  font-size: 0.65rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 0.25rem 0.5rem;
  background: rgba(67, 56, 202, 0.1);
  color: var(--accent-secondary);
  border-radius: 50px;
  margin-left: 0.5rem;
}

.stepper-chevron {
  color: var(--text-secondary);
  transition: transform 0.3s ease;
  flex-shrink: 0;
}

.stepper-item.active .stepper-chevron {
  transform: rotate(180deg);
}

.stepper-content {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease, padding 0.3s ease;
}

.stepper-item.active .stepper-content {
  max-height: 500px;
  padding: 0 1.25rem 1.25rem;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--border-color) transparent;
}

.stepper-item.active .stepper-content::-webkit-scrollbar {
  width: 4px;
}

.stepper-item.active .stepper-content::-webkit-scrollbar-track {
  background: transparent;
}

.stepper-item.active .stepper-content::-webkit-scrollbar-thumb {
  background: var(--border-color);
  border-radius: 2px;
}

.variance-list {
  display: flex;
  flex-direction: column;
  gap: 0.625rem;
  padding-top: 0.75rem;
  border-top: 1px solid var(--border-color);
}

.variance-item {
  display: flex;
  align-items: flex-start;
  gap: 0.625rem;
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

.variance-bullet {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent-primary);
  margin-top: 0.5rem;
  flex-shrink: 0;
}

.stepper-item.decision-hub .variance-bullet {
  background: var(--accent-secondary);
}

/* Mobile Responsiveness */
@media (max-width: 640px) {
  .stepper-card {
    margin-bottom: 0.75rem;
  }

  .stepper-header {
    padding: 0.875rem 1rem;
  }

  .stepper-title {
    font-size: 0.9rem;
  }

  .hub-badge {
    display: none;
  }

  .stepper-item.active .stepper-content {
    max-height: 400px;
    padding: 0 1rem 1rem;
  }

  /* CS3 Mobile Adjustments */
  .cs3-csv-preview,
  .cs3-crucible-engine,
  .cs3-pdf-preview {
    margin-top: 0.75rem;
  }

  .crucible-core {
    width: 60px;
    height: 60px;
  }

  .ring-1 {
    width: 50px;
    height: 50px;
  }

  .ring-2 {
    width: 35px;
    height: 35px;
  }
}

/* =========================================================================
   CS1: Interactive Sandbox (Accordion Timeline)
   ========================================================================= */
.cs-sandbox-wrapper {
  background: var(--surface-light);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 2rem;
  box-shadow: var(--shadow-sm);
}

.accordion-item {
  border-top: 1px solid var(--border-color);
  transition: all 0.4s ease-in-out;
}

.accordion-header {
  padding: 1.25rem 0;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: var(--font-serif);
  font-weight: 600;
  font-size: 1.15rem;
  color: var(--text-primary);
  transition: color 0.3s ease;
}

.accordion-header:hover {
  color: var(--accent-primary);
  /* Terracotta */
}

.accordion-content {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.6s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.6s ease-in-out;
  opacity: 0;
}

.accordion-content.active {
  max-height: 500px;
  opacity: 1;
  padding-bottom: 1.5rem;
}

/* =========================================================================
   CS4 Server Rack Architecture
   ========================================================================= */

.server-rack-container {
  max-width: 800px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
  padding: 3rem;
  background: var(--dark-bg);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  box-shadow: var(--shadow-md);
  position: relative;
}

/* Subtle vent styling on the rack background */
.server-rack-container::before {
  content: '';
  position: absolute;
  top: 0;
  left: 1rem;
  right: 1rem;
  bottom: 0;
  background-image: repeating-linear-gradient(90deg, transparent, transparent 10px, rgba(255, 255, 255, 0.02) 10px, rgba(255, 255, 255, 0.02) 12px);
  pointer-events: none;
  z-index: 0;
}

.rack-module {
  display: flex;
  align-items: center;
  background: var(--dark-surface);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 1.5rem 2rem;
  position: relative;
  z-index: 1;
  box-shadow: var(--shadow-sm);
  transition: transform 0.5s ease-in-out, border-color 0.5s ease-in-out, box-shadow 0.5s ease-in-out;
  cursor: default;
}

.rack-module:hover {
  transform: translateX(6px);
  border-color: var(--accent-secondary);
  /* Forest Green */
  box-shadow: var(--shadow-md);
}

.module-status {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--border-color);
  margin-right: 1.5rem;
  transition: background 0.5s ease-in-out;
}

.rack-module:hover .module-status {
  background: var(--accent-secondary);
}

.module-status.active {
  background: var(--accent-secondary);
}

.module-status.core-active {
  background: var(--accent-primary);
  /* Terracotta */
  box-shadow: 0 0 15px var(--accent-primary);
  animation: pulse-blue 2s infinite;
}

.module-label {
  font-family: var(--font-main);
  font-size: 1.1rem;
  font-weight: 500;
  color: var(--text-primary);
  letter-spacing: 0.02em;
}

.rack-module.base-record {
  margin-top: 2rem;
  border: 1px solid var(--accent-primary);
  background: var(--surface-light);
  padding: 2.25rem;
  box-shadow: var(--shadow-md);
}

.rack-module.base-record::before {
  content: '';
  position: absolute;
  top: -2.5rem;
  left: 2.45rem;
  width: 2px;
  height: 2.5rem;
  background: var(--border-color);
}

@keyframes pulse-blue {
  0% {
    box-shadow: 0 0 0 0 rgba(88, 166, 255, 0.4);
  }

  70% {
    box-shadow: 0 0 0 15px rgba(88, 166, 255, 0);
  }

  100% {
    box-shadow: 0 0 0 0 rgba(88, 166, 255, 0);
  }
}

/* =========================================================================
   VISUAL ENHANCEMENTS: Animated Patterns & Personality
   ========================================================================= */

/* Animated grain texture overlay for organic warmth */
.grain-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 9999;
  opacity: 0.03;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
}

/* Floating animation for visual elements */
@keyframes float {

  0%,
  100% {
    transform: translateY(0px);
  }

  50% {
    transform: translateY(-10px);
  }
}

.float-animation {
  animation: float 6s ease-in-out infinite;
}

/* Subtle breathing glow */
@keyframes breathe {

  0%,
  100% {
    opacity: 0.4;
    transform: scale(1);
  }

  50% {
    opacity: 0.6;
    transform: scale(1.05);
  }
}

.breathe-glow {
  animation: breathe 8s ease-in-out infinite;
}

/* =========================================================================
   CS1: Timeline Visualization
   ========================================================================= */

.timeline-flow {
  position: relative;
  padding: 2rem 0;
}

.timeline-flow::before {
  content: '';
  position: absolute;
  left: 20px;
  top: 0;
  bottom: 0;
  width: 3px;
  background: linear-gradient(180deg, var(--accent-primary) 0%, var(--accent-secondary) 50%, var(--border-color) 100%);
  border-radius: 3px;
}

.timeline-node {
  display: flex;
  align-items: flex-start;
  gap: 1.5rem;
  margin-bottom: 1.5rem;
  position: relative;
}

.timeline-dot {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--surface-light);
  border: 3px solid var(--accent-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--accent-primary);
  flex-shrink: 0;
  box-shadow: var(--shadow-sm);
  z-index: 1;
}

.timeline-node.active .timeline-dot {
  background: var(--accent-primary);
  color: white;
  box-shadow: 0 0 20px rgba(166, 93, 71, 0.4);
}

.timeline-content {
  flex: 1;
  padding-top: 0.5rem;
}

.timeline-content h4 {
  font-size: 1rem;
  margin-bottom: 0.25rem;
  color: var(--text-primary);
}

.timeline-content p {
  font-size: 0.9rem;
  color: var(--text-secondary);
  margin: 0;
}

/* Workflow Timeline with Decision Points */
.workflow-timeline .timeline-node {
  margin-bottom: 0.5rem;
}

/* Decision Boxes */
.decision-box {
  margin-top: 0.5rem;
  padding: 0.625rem;
  background: rgba(46, 64, 49, 0.05);
  border: 1px solid rgba(46, 64, 49, 0.15);
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  gap: 0.375rem;
}

.decision-item {
  padding: 0.375rem 0.625rem;
  background: var(--surface-light);
  border: 1px solid var(--border-color);
  border-radius: 6px;
  font-size: 0.8rem;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.decision-item::before {
  content: '→';
  color: var(--accent-secondary);
  font-weight: bold;
}

.decision-item.primary {
  background: rgba(166, 93, 71, 0.1);
  border-color: rgba(166, 93, 71, 0.2);
  color: var(--text-primary);
}

.decision-item.primary::before {
  content: '*';
  color: var(--accent-primary);
}

/* Resolution Options */
.resolution-options {
  margin-top: 0.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.375rem;
}

.resolution-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 0.75rem;
  background: var(--surface-light);
  border: 1px solid var(--border-color);
  border-radius: 6px;
  font-size: 0.8rem;
  color: var(--text-secondary);
}

.res-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}

.resolution-item.pushback .res-dot {
  background: #6b7280;
}

.resolution-item.defect .res-dot {
  background: #ef4444;
}

.resolution-item.enhancement .res-dot {
  background: #22c55e;
}

/* Escalation Branch Indicator */
.escalation-branch {
  position: relative;
  margin-left: 20px;
  padding-left: 1.5rem;
  margin-bottom: 0.5rem;
}

.escalation-line {
  position: absolute;
  left: 0;
  top: 50%;
  width: 24px;
  height: 2px;
  background: linear-gradient(90deg, var(--border-color), #eab308);
}

.escalation-line::before {
  content: '';
  position: absolute;
  left: -6px;
  top: -3px;
  width: 8px;
  height: 8px;
  background: var(--border-color);
  border-radius: 50%;
}

.escalation-line::after {
  content: '';
  position: absolute;
  right: -4px;
  top: -4px;
  width: 0;
  height: 0;
  border-top: 5px solid transparent;
  border-bottom: 5px solid transparent;
  border-left: 6px solid #eab308;
}

.escalation-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.375rem 0.75rem;
  background: rgba(234, 179, 8, 0.1);
  border: 1px dashed rgba(234, 179, 8, 0.4);
  border-radius: 50px;
  font-size: 0.75rem;
  color: #eab308;
}

.escalation-badge svg {
  flex-shrink: 0;
}

/* Learning Curve Badges */
.learning-curve-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.375rem 0.75rem;
  background: var(--surface-light);
  border: 1px solid var(--border-color);
  border-radius: 50px;
  font-size: 0.8rem;
  color: var(--text-primary);
}

/* =========================================================================
   CS2: Case Weight Calculator Tool
   ========================================================================= */

.workload-visual {
  background: linear-gradient(135deg, var(--surface-light) 0%, var(--bg-color) 100%);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 1.5rem;
  position: relative;
  overflow: hidden;
}

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

.cwc-badge {
  padding: 0.375rem 0.875rem;
  background: rgba(67, 56, 202, 0.1);
  border: 1px solid rgba(67, 56, 202, 0.2);
  border-radius: 50px;
  font-size: 0.75rem;
  color: var(--accent-secondary);
  font-weight: 500;
}

/* Calculator Interface */
.calculator-interface {
  background: var(--bg-color);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 1.25rem;
  margin-bottom: 1.5rem;
}

.calc-inputs {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
}

.calc-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}

.calc-row label {
  font-size: 0.85rem;
  color: var(--text-secondary);
  font-weight: 500;
}

.calc-select {
  padding: 0.5rem 0.75rem;
  background: var(--surface-light);
  border: 1px solid var(--border-color);
  border-radius: 6px;
  font-size: 0.8rem;
  color: var(--text-primary);
  min-width: 180px;
}

/* Calculation Result */
.calc-result {
  padding: 1rem;
  background: var(--surface-light);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  text-align: center;
}

.calc-formula {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
  font-family: monospace;
  font-size: 0.9rem;
  flex-wrap: wrap;
}

.formula-base {
  color: var(--accent-primary);
  font-weight: 700;
}

.formula-op {
  color: var(--text-secondary);
}

.formula-mult {
  color: var(--accent-secondary);
}

.formula-eq {
  color: var(--text-secondary);
  font-weight: bold;
}

.calc-score {
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 0.5rem;
}

.score-value {
  font-size: 2.5rem;
  font-weight: 800;
  color: var(--accent-primary);
  line-height: 1;
}

.score-label {
  font-size: 0.9rem;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.calc-weight {
  font-size: 0.75rem;
  color: var(--accent-primary);
  font-weight: 600;
  margin-left: 0.5rem;
}

.turn-order-display {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border-color);
}

.to-label {
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.to-slot {
  font-size: 1rem;
  font-weight: 700;
  color: var(--accent-secondary);
  font-family: 'JetBrains Mono', monospace;
}

/* Turn Order Queue */
.turn-order-queue {
  background: var(--surface-light);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  overflow: hidden;
}

.toq-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.875rem 1rem;
  background: var(--bg-color);
  border-bottom: 1px solid var(--border-color);
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-primary);
}

.toq-count {
  font-size: 0.75rem;
  color: var(--text-secondary);
  font-weight: 500;
}

.toq-list {
  display: flex;
  flex-direction: column;
}

.toq-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.875rem 1rem;
  border-bottom: 1px solid var(--border-color);
  transition: background 0.2s ease;
}

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

.toq-item.active {
  background: rgba(217, 119, 6, 0.05);
}

.toq-rank {
  width: 32px;
  height: 32px;
  background: var(--bg-color);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--text-secondary);
  flex-shrink: 0;
}

.toq-item.active .toq-rank {
  background: var(--accent-primary);
  border-color: var(--accent-primary);
  color: white;
}

.toq-case {
  flex: 1;
  min-width: 0;
}

.toq-id {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.125rem;
}

.toq-meta {
  font-size: 0.75rem;
  color: var(--text-secondary);
}

.toq-weight {
  padding: 0.375rem 0.75rem;
  background: var(--bg-color);
  border-radius: 6px;
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--accent-primary);
  font-family: monospace;
  flex-shrink: 0;
}

.toq-assignee {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--accent-secondary);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 600;
  flex-shrink: 0;
}

/* Turn Order Queue */
.turn-order-queue {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-bottom: 1.5rem;
}

.turn-case {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.875rem;
  background: var(--surface-light);
  border: 1px solid var(--border-color);
  border-radius: 10px;
  box-shadow: var(--shadow-sm);
  transition: all 0.3s ease;
}

.turn-case:hover {
  border-color: var(--accent-primary);
  transform: translateX(4px);
}

.turn-case.waiting {
  opacity: 0.6;
}

.turn-badge {
  width: 36px;
  height: 36px;
  background: var(--accent-primary);
  color: white;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700;
  flex-shrink: 0;
}

.turn-badge.waiting {
  background: var(--border-color);
  color: var(--text-secondary);
}

.turn-details {
  flex: 1;
  min-width: 0;
}

.turn-id {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.25rem;
}

.turn-calc {
  font-size: 0.75rem;
  font-family: monospace;
  display: flex;
  align-items: center;
  gap: 0.375rem;
  flex-wrap: wrap;
}

.calc-severity {
  color: #ef4444;
}

.calc-tier {
  color: #3b82f6;
}

.calc-urgency {
  color: #f59e0b;
}

.calc-op {
  color: var(--text-secondary);
}

.calc-equals {
  color: var(--text-secondary);
  font-weight: bold;
}

.calc-total {
  color: var(--accent-primary);
  font-weight: 700;
  font-size: 0.85rem;
}

.turn-assignee {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--border-color);
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 600;
  flex-shrink: 0;
}

.turn-assignee.assigned {
  background: var(--accent-secondary);
  color: white;
}

/* Bystander Effect Demo */
.bystander-demo {
  padding: 1rem;
  background: rgba(0, 0, 0, 0.03);
  border-radius: 10px;
}

.bd-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.75rem;
}

.bd-content {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.bd-before,
.bd-after {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.bd-label {
  font-size: 0.7rem;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.bd-status {
  font-size: 0.85rem;
  font-weight: 500;
}

.bd-status.bad {
  color: #ef4444;
}

.bd-status.good {
  color: #22c55e;
}

.bd-arrow {
  color: var(--accent-primary);
  font-size: 1.25rem;
}

.workload-visual::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle at 30% 30%, rgba(166, 93, 71, 0.05) 0%, transparent 50%),
    radial-gradient(circle at 70% 70%, rgba(46, 64, 49, 0.05) 0%, transparent 50%);
  animation: rotate 30s linear infinite;
}

@keyframes rotate {
  from {
    transform: rotate(0deg);
  }

  to {
    transform: rotate(360deg);
  }
}

.case-card {
  background: var(--surface-light);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 1.25rem;
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  position: relative;
  z-index: 1;
  transition: all 0.3s ease;
  box-shadow: var(--shadow-sm);
}

.case-card:hover {
  transform: translateX(8px);
  border-color: var(--accent-primary);
  box-shadow: var(--shadow-md);
}

.case-priority {
  width: 48px;
  height: 48px;
  border-radius: 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.75rem;
  flex-shrink: 0;
}

.case-priority.critical {
  background: linear-gradient(135deg, #fee2e2 0%, #fecaca 100%);
  color: #991b1b;
  border: 1px solid #fca5a5;
}

.case-priority.high {
  background: linear-gradient(135deg, #ffedd5 0%, #fed7aa 100%);
  color: #9a3412;
  border: 1px solid #fdba74;
}

.case-priority.medium {
  background: linear-gradient(135deg, #fef3c7 0%, #fde68a 100%);
  color: #92400e;
  border: 1px solid #fcd34d;
}

.priority-score {
  font-size: 1.1rem;
  font-weight: 800;
}

.case-info {
  flex: 1;
}

.case-id {
  font-family: var(--font-main);
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--text-primary);
  margin-bottom: 0.25rem;
}

.case-meta {
  font-size: 0.8rem;
  color: var(--text-secondary);
}

.case-assignee {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent-secondary) 0%, #3d5a47 100%);
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: 0.85rem;
  flex-shrink: 0;
}

/* Processing animation for workload */
.processing-bar {
  position: absolute;
  bottom: 0;
  left: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--accent-primary), var(--accent-secondary));
  border-radius: 0 0 0 12px;
  animation: processWidth 3s ease-in-out infinite;
}

@keyframes processWidth {
  0% {
    width: 0%;
    opacity: 1;
  }

  50% {
    width: 100%;
    opacity: 1;
  }

  100% {
    width: 100%;
    opacity: 0;
  }
}

/* =========================================================================
   CS3: Real-time Data Visualization
   ========================================================================= */

.metrics-pulse {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(46, 64, 49, 0.1);
  padding: 0.25rem 0.75rem;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--accent-secondary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.live-indicator {
  width: 8px;
  height: 8px;
  background: #22c55e;
  border-radius: 50%;
  animation: pulse-live 2s ease-in-out infinite;
}

@keyframes pulse-live {

  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }

  50% {
    opacity: 0.5;
    transform: scale(0.8);
  }
}

.progress-bar-animated {
  position: relative;
  overflow: hidden;
}

.progress-bar-animated::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
  animation: shimmer 2s infinite;
}

@keyframes shimmer {
  0% {
    transform: translateX(-100%);
  }

  100% {
    transform: translateX(100%);
  }
}

/* =========================================================================
   CS4: Enhanced Server Rack
   ========================================================================= */

.rack-connection {
  position: absolute;
  left: 2.45rem;
  top: -2.5rem;
  width: 2px;
  height: 2.5rem;
  background: linear-gradient(180deg, var(--border-color) 0%, var(--accent-secondary) 100%);
}

.data-stream {
  position: absolute;
  width: 4px;
  height: 4px;
  background: var(--accent-secondary);
  border-radius: 50%;
  left: 2.4rem;
  animation: dataFlow 2s linear infinite;
  opacity: 0;
}

@keyframes dataFlow {
  0% {
    top: -2.5rem;
    opacity: 0;
  }

  10% {
    opacity: 1;
  }

  90% {
    opacity: 1;
  }

  100% {
    top: 0;
    opacity: 0;
  }
}

.rack-module:nth-child(1) .data-stream {
  animation-delay: 0s;
}

.rack-module:nth-child(2) .data-stream {
  animation-delay: 0.5s;
}

.rack-module:nth-child(3) .data-stream {
  animation-delay: 1s;
}

.rack-module:nth-child(4) .data-stream {
  animation-delay: 1.5s;
}

/* =========================================================================
   Typography Enhancements
   ========================================================================= */

.accent-line {
  width: 60px;
  height: 4px;
  background: linear-gradient(90deg, var(--accent-primary), var(--accent-secondary));
  border-radius: 2px;
  margin: 1rem 0 2rem;
}

.section-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--accent-primary);
  margin-bottom: 1rem;
}

.section-tag::before {
  content: '';
  width: 20px;
  height: 2px;
  background: var(--accent-primary);
}

/* =========================================================================
   CS3: Simplified Comparison
   ========================================================================= */

.simple-comparison {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.5rem;
  padding: 1.5rem;
  background: var(--bg-color);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  margin-bottom: 1.5rem;
}

@media (max-width: 480px) {
  .simple-comparison {
    flex-direction: column;
    gap: 1rem;
  }

  .sc-arrow {
    transform: rotate(90deg);
  }
}

.sc-item {
  text-align: center;
  flex: 1;
}

.sc-item.old {
  opacity: 0.6;
}

.sc-label {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-secondary);
  margin-bottom: 0.5rem;
}

.sc-metric {
  font-size: 2rem;
  font-weight: 800;
  color: var(--text-primary);
  line-height: 1;
  margin-bottom: 0.25rem;
}

.sc-item.new .sc-metric {
  color: var(--accent-tertiary);
}

.sc-desc {
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.sc-arrow {
  font-size: 1.5rem;
  color: var(--accent-primary);
  font-weight: bold;
}

/* =========================================================================
   CS3: Weekly Review Tasks Dashboard
   ========================================================================= */

.review-dashboard {
  background: var(--surface-light);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 1.5rem;
  box-shadow: var(--shadow-sm);
}

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

.rd-title {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.rd-title h4 {
  margin: 0;
  font-size: 1.1rem;
  color: var(--text-primary);
}

.rd-title svg {
  color: var(--accent-tertiary);
}

/* Review Categories */
.review-categories {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
  margin-bottom: 1.5rem;
}

@media (max-width: 640px) {
  .review-categories {
    grid-template-columns: 1fr;
  }
}

.review-cat {
  display: flex;
  align-items: flex-start;
  gap: 0.875rem;
  padding: 1rem;
  background: var(--bg-color);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  transition: all 0.2s ease;
}

.review-cat:hover {
  border-color: var(--accent-primary);
  transform: translateX(4px);
}

.review-cat.time-resolve {
  border-left: 4px solid #3b82f6;
}

.review-cat.defect-priority {
  border-left: 4px solid #ef4444;
}

.review-cat.csat-exclusions {
  border-left: 4px solid #f59e0b;
}

.review-cat.escalation-cause {
  border-left: 4px solid #8b5cf6;
}

.rc-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.review-cat.time-resolve .rc-icon {
  background: rgba(59, 130, 246, 0.1);
  color: #3b82f6;
}

.review-cat.defect-priority .rc-icon {
  background: rgba(239, 68, 68, 0.1);
  color: #ef4444;
}

.review-cat.csat-exclusions .rc-icon {
  background: rgba(245, 158, 11, 0.1);
  color: #f59e0b;
}

.review-cat.escalation-cause .rc-icon {
  background: rgba(139, 92, 246, 0.1);
  color: #8b5cf6;
}

.rc-content {
  flex: 1;
  min-width: 0;
}

.rc-title {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.25rem;
}

.rc-count {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--accent-primary);
  margin-bottom: 0.25rem;
}

.rc-desc {
  font-size: 0.8rem;
  color: var(--text-secondary);
  line-height: 1.4;
}

.rc-action {
  padding: 0.5rem 1rem;
  background: var(--surface-light);
  border: 1px solid var(--border-color);
  border-radius: 6px;
  font-size: 0.8rem;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.rc-action:hover {
  border-color: var(--accent-primary);
  color: var(--accent-primary);
}

/* QTD Tracker */
.qtd-tracker {
  padding: 1.25rem;
  background: var(--bg-color);
  border-radius: 12px;
}

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

.qtd-title {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-primary);
}

.qtd-week {
  font-size: 0.8rem;
  color: var(--accent-primary);
  font-weight: 500;
}

.qtd-bar {
  height: 8px;
  background: var(--border-color);
  border-radius: 4px;
  overflow: hidden;
  margin-bottom: 0.5rem;
}

.qtd-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--accent-primary), var(--accent-tertiary));
  border-radius: 4px;
  transition: width 0.5s ease;
}

.qtd-legend {
  display: flex;
  justify-content: space-between;
  font-size: 0.75rem;
  color: var(--text-secondary);
}

/* =========================================================================
   CS3: Coaching Timeline Comparison
   ========================================================================= */

.coaching-timeline-comparison {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 2rem;
  align-items: center;
  background: var(--surface-light);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 2rem;
}

@media (max-width: 768px) {
  .coaching-timeline-comparison {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .vs-divider {
    transform: rotate(90deg);
  }
}

.timeline-old,
.timeline-new {
  text-align: center;
}

.timo-header {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
}

.timeline-old .timo-header {
  color: #ef4444;
}

.timeline-new .timo-header {
  color: #22c55e;
}

.timo-header h4 {
  margin: 0;
  font-size: 1.1rem;
}

.timo-track {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.75rem;
}

.timo-event {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1.25rem;
  border-radius: 50px;
  font-size: 0.9rem;
  font-weight: 500;
}

.timo-event.bad {
  background: #fee2e2;
  color: #991b1b;
}

.timo-event.good {
  background: #dcfce7;
  color: #166534;
}

.timo-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

.timo-event.bad .timo-dot {
  background: #ef4444;
}

.timo-event.good .timo-dot {
  background: #22c55e;
}

.timo-wait {
  padding: 0.5rem 1rem;
  background: var(--bg-color);
  border-radius: 50px;
  font-size: 0.8rem;
  color: var(--text-secondary);
  font-style: italic;
}

.timo-wait.sub {
  font-size: 0.75rem;
  padding: 0.375rem 0.875rem;
  opacity: 0.8;
}

.timo-outcome {
  margin-top: 0.5rem;
  padding: 0.625rem 1.25rem;
  border-radius: 8px;
  font-size: 0.95rem;
  font-weight: 600;
}

.timo-outcome.fail {
  background: #fee2e2;
  color: #dc2626;
}

.timo-outcome.success {
  background: #dcfce7;
  color: #16a34a;
}

.vs-divider {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

/* =========================================================================
   CS3: Performance Snapshot PDF Generator
   ========================================================================= */
.cs3-intro {
  text-align: center;
  max-width: 800px;
  margin: 0 auto 4rem;
}

.ui-showcase-full {
  width: 100%;
  max-width: 1440px;
  margin: 0 auto;
  background: linear-gradient(135deg, #161b22 0%, #0d1117 100%);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 4rem 2rem;
  display: flex;
  justify-content: center;
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.5);
}

.pdf-glass-card {
  background: rgba(22, 27, 34, 0.85);
  /* Slate transparent */
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 12px;
  padding: 2rem;
  box-shadow: var(--shadow-lg);
  max-width: 800px;
  width: 100%;
}

/* =========================================================================
   CS4: The AI-Native Future (Dark Mode Shift & SVG Diagram)
   ========================================================================= */
.dark-section {
  background: #0d1117;
  color: var(--dark-text);
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.dark-section h2,
.dark-section h3 {
  color: var(--dark-text);
}

.dark-section p {
  color: var(--dark-text-sec);
}

.cs4-intro {
  text-align: center;
  max-width: 800px;
  margin: 0 auto 4rem;
}

.svg-container {
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 2rem 0;
}

/* SVG Node Animations */
.node-hub {
  filter: drop-shadow(0 0 25px rgba(88, 166, 255, 0.4));
}

.hub-core {
  transition: filter 0.3s ease;
}

.node-hub:hover .hub-core {
  filter: drop-shadow(0 0 35px rgba(88, 166, 255, 0.8));
}

.pulse-ring {
  animation: pulseOut 4s cubic-bezier(0.215, 0.61, 0.355, 1) infinite;
  transform-origin: center;
}

@keyframes pulseOut {
  0% {
    transform: scale(0.95);
    opacity: 0.8;
    stroke-width: 3;
  }

  100% {
    transform: scale(1.6);
    opacity: 0;
    stroke-width: 1;
  }
}

.node-circle.interactive {
  transition: transform 0.3s ease, filter 0.3s ease;
  transform-origin: center;
  cursor: pointer;
}

.node-circle.interactive:hover {
  transform: scale(1.1);
  filter: drop-shadow(0 0 15px rgba(255, 255, 255, 0.2));
}

.node-circle.interactive:hover .satellite-bg {
  stroke: var(--accent-primary);
}

.connection-line {
  stroke-dasharray: 4 8;
  animation: dashStream 2s linear infinite;
  opacity: 0.4;
}

@keyframes dashStream {
  to {
    stroke-dashoffset: -24;
  }
}

.data-packet {
  filter: drop-shadow(0 0 6px currentColor);
}

/* =========================================================================
   About Me: Discipline Grid & Manifesto
   ========================================================================= */

.about-header {
  text-align: center;
  max-width: 600px;
  margin: 0 auto 3rem;
}

.about-intro {
  font-size: 1.15rem;
  line-height: 1.8;
  color: var(--text-secondary);
}

.about-intro em {
  color: var(--accent-primary);
  font-style: normal;
  font-weight: 500;
}

/* Discipline Grid */
.discipline-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  margin-bottom: 3rem;
}

@media (max-width: 768px) {
  .discipline-grid {
    grid-template-columns: 1fr;
  }
}

.discipline-card {
  background: var(--surface-light);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 1.5rem;
  position: relative;
  overflow: hidden;
  transition: all 0.3s ease;
}

.discipline-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.discipline-card.climbing {
  border-top: 4px solid #f59e0b;
}

.discipline-card.diving {
  border-top: 4px solid #3b82f6;
}

.discipline-card.drones {
  border-top: 4px solid #8b5cf6;
}

.discipline-icon {
  width: 56px;
  height: 56px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1rem;
}

.discipline-card.climbing .discipline-icon {
  background: rgba(245, 158, 11, 0.1);
  color: #f59e0b;
}

.discipline-card.diving .discipline-icon {
  background: rgba(59, 130, 246, 0.1);
  color: #3b82f6;
}

.discipline-card.drones .discipline-icon {
  background: rgba(139, 92, 246, 0.1);
  color: #8b5cf6;
}

.discipline-card h4 {
  font-size: 1.1rem;
  margin-bottom: 0.75rem;
  color: var(--text-primary);
}

.discipline-card p {
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 1rem;
}

.discipline-parallel {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding-top: 1rem;
  border-top: 1px solid var(--border-color);
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.parallel-arrow {
  color: var(--accent-primary);
  font-weight: bold;
}

/* Manifesto Card */
.manifesto-card {
  background: linear-gradient(135deg, rgba(217, 119, 6, 0.05) 0%, rgba(67, 56, 202, 0.05) 100%);
  border: 1px solid var(--border-color);
  border-radius: 20px;
  padding: 3rem;
  text-align: center;
  max-width: 800px;
  margin: 0 auto;
  position: relative;
}

.manifesto-icon {
  width: 72px;
  height: 72px;
  background: var(--surface-light);
  border: 1px solid var(--border-color);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.5rem;
  color: var(--accent-primary);
}

.manifesto-card h3 {
  font-size: 1.5rem;
  margin-bottom: 1.5rem;
  color: var(--text-primary);
}

.manifesto-card blockquote {
  font-size: 1.25rem;
  line-height: 1.8;
  color: var(--text-secondary);
  font-family: var(--font-serif);
  font-style: italic;
  margin: 0 0 1.5rem;
  padding: 0;
  border: none;
}

.manifesto-signature {
  font-size: 0.9rem;
  color: var(--accent-primary);
  font-weight: 600;
  letter-spacing: 0.05em;
}

/* =========================================================================
   The Toolkit Matrix
   ========================================================================= */

.toolkit-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
  max-width: 1000px;
  margin: 0 auto;
}

.toolkit-column {
  background: var(--surface-light);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 1.5rem;
  transition: all 0.3s ease;
}

.toolkit-column:hover {
  box-shadow: var(--shadow-md);
}

.toolkit-header {
  display: flex;
  align-items: center;
  gap: 0.625rem;
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 1.25rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--border-color);
}

.toolkit-header svg {
  color: var(--accent-primary);
}

.toolkit-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.toolkit-item {
  padding: 0.625rem 0;
  font-size: 0.95rem;
  color: var(--text-secondary);
  border-bottom: 1px solid rgba(0, 0, 0, 0.03);
  transition: all 0.2s ease;
  cursor: default;
}

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

.toolkit-item:hover {
  color: var(--accent-secondary);
  text-shadow: 0 0 20px rgba(67, 56, 202, 0.15);
  transform: translateX(4px);
}

.toolkit-subhead {
  padding: 1rem 0 0.25rem 0;
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-primary);
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  margin-top: 0.5rem;
  cursor: default;
}

.toolkit-subhead:first-child {
  padding-top: 0.25rem;
  margin-top: 0;
}

.toolkit-subitem {
  position: relative;
  padding: 0.4rem 0 0.4rem 1.25rem;
  font-size: 0.9rem;
  color: var(--text-secondary);
  transition: all 0.2s ease;
  cursor: default;
}

.toolkit-subitem::before {
  content: "↳";
  position: absolute;
  left: 0;
  top: 0.4rem;
  color: var(--accent-secondary);
  font-family: 'JetBrains Mono', monospace;
  opacity: 0.6;
}

.toolkit-subitem:hover {
  color: var(--accent-secondary);
  text-shadow: 0 0 15px rgba(67, 56, 202, 0.15);
  transform: translateX(4px);
}

@media (max-width: 768px) {
  .toolkit-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .toolkit-column {
    padding: 1.25rem;
  }
}

/* =========================================================================
   Discipline Cards v2
   ========================================================================= */

.discipline-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
  max-width: 1200px;
  margin: 0 auto;
}

.discipline-card-v2 {
  background: var(--surface-light);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  overflow: hidden;
  transition: all 0.3s ease;
}

.discipline-card-v2:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.discipline-image {
  position: relative;
  height: 200px;
  overflow: hidden;
  background: linear-gradient(135deg, var(--border-color) 0%, #e5e5e0 100%);
}

.discipline-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.discipline-card-v2:hover .discipline-image img {
  transform: scale(1.05);
}

.discipline-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.4) 0%, transparent 50%);
}

.discipline-content {
  padding: 1.5rem;
}

.discipline-content h4 {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.75rem;
}

.discipline-content p {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.6;
  margin: 0;
}

@media (max-width: 768px) {
  .discipline-cards {
    grid-template-columns: 1fr;
  }

  .discipline-image {
    height: 180px;
  }
}

/* =========================================================================
   Global Footer (Redesigned)
   ========================================================================= */

.footer-cta {
  text-align: center;
  padding: 4rem 0 3rem;
  border-top: 1px solid var(--border-color);
  border-bottom: 1px solid var(--border-color);
}

.footer-cta h3 {
  font-size: 1.75rem;
  color: var(--text-primary);
  margin-bottom: 1.5rem;
}

.cta-actions {
  display: flex;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.btn-resume {
  display: inline-flex;
  align-items: center;
  gap: 0.625rem;
  padding: 0.875rem 1.75rem;
  background: var(--text-primary);
  color: var(--bg-color);
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  transition: all 0.2s ease;
}

.btn-resume:hover {
  background: var(--accent-primary);
  color: white;
  transform: translateY(-2px);
  box-shadow: 0 10px 20px rgba(217, 119, 6, 0.2);
}

.btn-linkedin {
  display: inline-flex;
  align-items: center;
  gap: 0.625rem;
  padding: 0.875rem 1.75rem;
  background: transparent;
  color: var(--text-primary);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  transition: all 0.2s ease;
}

.btn-linkedin:hover {
  border-color: var(--accent-secondary);
  color: var(--accent-secondary);
  background: rgba(67, 56, 202, 0.05);
}

.footer-security {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 1.5rem 0;
  font-size: 0.85rem;
  font-style: italic;
  color: var(--text-secondary);
  border-bottom: 1px solid var(--border-color);
}

.footer-security svg {
  color: var(--accent-secondary);
  flex-shrink: 0;
}

.footer-copyright {
  text-align: center;
  padding: 1.5rem 0;
  font-size: 0.85rem;
  color: var(--text-secondary);
}

@media (max-width: 640px) {
  .footer-cta h3 {
    font-size: 1.4rem;
  }

  .cta-actions {
    flex-direction: column;
    align-items: center;
  }

  .btn-resume,
  .btn-linkedin {
    width: 100%;
    max-width: 280px;
    justify-content: center;
  }
}

/* =========================================================================
   Legacy Footer Styles (Skills Matrix & Contact block)
   ========================================================================= */
.global-footer {
  background-color: var(--bg-color);
  border-top: 1px solid var(--border-color);
  padding: 4rem 0;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 3rem;
}

@media (min-width: 768px) {
  .footer-grid {
    grid-template-columns: 2fr 1fr;
  }
}

.skills-matrix {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1.5rem;
}

.skill-category h4 {
  font-size: 1rem;
  color: var(--text-primary);
  margin-bottom: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.skill-category ul {
  list-style: none;
}

.skill-category li {
  color: var(--text-secondary);
  font-size: 0.95rem;
  margin-bottom: 0.5rem;
  display: flex;
  align-items: center;
}

.skill-category li::before {
  content: "→";
  margin-right: 0.5rem;
  color: var(--accent-primary);
}

.contact-block {
  background: var(--surface-light);
  padding: 2rem;
  border-radius: 12px;
  text-align: center;
}

.btn-primary {
  display: inline-block;
  background-color: var(--accent-primary);
  color: #fff;
  padding: 0.75rem 1.5rem;
  border-radius: 6px;
  text-decoration: none;
  font-weight: 500;
  transition: background-color 0.2s ease, transform 0.1s ease;
  margin-top: 1rem;
}

.btn-primary:hover {
  background-color: #8a4d3a;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(166, 93, 71, 0.3);
}

/* Security Disclaimer Styling */
.security-disclaimer {
  font-size: 0.85rem;
  color: var(--text-secondary);
  font-style: italic;
  padding: 1rem;
  background: rgba(46, 64, 49, 0.03);
  border-radius: 8px;
  border: 1px dashed var(--border-color);
}

/* Video Wrapper Enhancement */
.video-wrapper {
  border-radius: 12px;
  overflow: hidden;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border-color);
  background: var(--surface-light);
}

/* Smooth scroll behavior */
html {
  scroll-behavior: smooth;
}

/* Selection color */
::selection {
  background: rgba(166, 93, 71, 0.2);
  color: var(--text-primary);
}

/* =========================================================================
   CS4: System Blueprint Modal
   ========================================================================= */

.cs4-blueprint-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.625rem;
  padding: 1rem 2rem;
  background: rgba(67, 56, 202, 0.15);
  border: 1px solid rgba(67, 56, 202, 0.4);
  border-radius: 50px;
  color: #c9d1d9;
  font-size: 1rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s ease-in-out;
  margin-bottom: 2rem;
  box-shadow: 0 0 15px rgba(67, 56, 202, 0.2);
}

.cs4-blueprint-btn:hover {
  background: rgba(67, 56, 202, 0.3);
  border-color: rgba(67, 56, 202, 0.6);
  box-shadow: 0 0 25px rgba(67, 56, 202, 0.4);
  transform: translateY(-2px);
  color: white;
}

.cs4-blueprint-btn svg {
  color: var(--accent-secondary);
}

.cs4-blueprint-modal .cmd-modal-content {
  max-width: 900px;
  max-height: 90vh;
  overflow-y: auto;
}

.cs4-blueprint-body {
  padding: 1.5rem;
}

.blueprint-narrative {
  background: rgba(67, 56, 202, 0.1);
  border: 1px solid rgba(67, 56, 202, 0.2);
  border-radius: 12px;
  padding: 1.25rem;
  margin-bottom: 1.5rem;
}

.narrative-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--accent-secondary);
  margin-bottom: 0.75rem;
}

.blueprint-narrative p {
  font-size: 0.95rem;
  color: #a3a3a3;
  line-height: 1.6;
  margin: 0;
}

.blueprint-diagram {
  background: #0d1117;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
  overflow-x: auto;
}

.blueprint-diagram svg {
  min-width: 600px;
  display: block;
  margin: 0 auto;
}

/* Connection Lines */
.connection-lines .conn-line {
  fill: none;
  stroke: rgba(255, 255, 255, 0.2);
  stroke-width: 2;
  stroke-dasharray: 5, 5;
}

.connection-lines .conn-line.secure {
  stroke: rgba(239, 68, 68, 0.4);
  stroke-width: 3;
}

.pulse-dot {
  fill: #D97706;
  opacity: 0.8;
}

.pulse-dot.secure {
  fill: #ef4444;
}

/* Node Animations */
.hub-pulse {
  animation: hubPulse 3s ease-in-out infinite;
}

@keyframes hubPulse {

  0%,
  100% {
    opacity: 0.3;
    transform: scale(1);
  }

  50% {
    opacity: 0.6;
    transform: scale(1.05);
  }
}

/* Legend */
.blueprint-legend {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1.5rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.legend-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  color: #888;
}

.legend-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
}

.legend-dot.hub {
  background: #D97706;
}

.legend-dot.security {
  background: #ef4444;
}

.legend-dot.processing {
  background: #4338CA;
}

.legend-dot.terminal {
  background: #059669;
}

/* Mobile Responsive */
@media (max-width: 768px) {
  .cs4-blueprint-modal .cmd-modal-content {
    max-width: 95vw;
    margin: 1rem;
  }

  .blueprint-diagram {
    padding: 1rem;
  }

  .blueprint-diagram svg {
    min-width: 500px;
  }

  .blueprint-legend {
    gap: 1rem;
  }

  .legend-item {
    font-size: 0.8rem;
  }
}

/* =========================================================================
   CS4: Command Center Interface (NotebookLM Style)
   ========================================================================= */

.command-center-container {
  max-width: 1400px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 220px 1fr 260px;
  gap: 1px;
  background: #0d1117;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5);
  min-height: 600px;
}

/* Left Sidebar */
.cmd-sidebar {
  background: #161b22;
  padding: 1.5rem 1rem;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

/* Email Preview in Sidebar (Latest Communication) */
.cmd-email-preview-compact {
  background: #0d1117;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  padding: 1rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.cmd-email-preview-compact:hover {
  border-color: rgba(166, 93, 71, 0.3);
  background: rgba(166, 93, 71, 0.05);
}

@media (max-width: 1200px) {
  .cmd-email-sender {
    gap: 0.5rem;
  }

  .cmd-email-time-small {
    font-size: 0.7rem;
  }

  .cmd-email-preview-compact {
    padding: 0.75rem;
  }
}

.cmd-email-sender {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
}

.cmd-email-avatar {
  width: 36px;
  height: 36px;
  background: linear-gradient(135deg, var(--accent-primary), #d97a5c);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  font-weight: 600;
  color: white;
  flex-shrink: 0;
}

.cmd-email-info {
  flex: 1;
  min-width: 0;
}

.cmd-email-name {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--dark-text);
  margin-bottom: 0.25rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.cmd-email-subject {
  font-size: 0.8rem;
  color: #888;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.cmd-email-time-small {
  font-size: 0.75rem;
  color: #666;
  flex-shrink: 0;
}

.cmd-email-snippet {
  font-size: 0.85rem;
  color: #888;
  line-height: 1.5;
  margin-bottom: 0.75rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.cmd-email-actions-row {
  display: flex;
  gap: 0.5rem;
}

.cmd-email-action-btn {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.5rem 0.875rem;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 6px;
  color: #888;
  font-size: 0.8rem;
  cursor: pointer;
  transition: all 0.2s ease;
  flex: 1;
  justify-content: center;
}

.cmd-email-action-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #c9d1d9;
}

.cmd-email-action-btn.primary {
  background: rgba(166, 93, 71, 0.2);
  border-color: rgba(166, 93, 71, 0.3);
  color: #c9d1d9;
}

.cmd-email-action-btn.primary:hover {
  background: rgba(166, 93, 71, 0.3);
}

.cmd-email-action-btn.icon-only {
  padding: 0.5rem;
  justify-content: center;
  position: relative;
}

/* Tooltip for icon buttons */
.cmd-email-action-btn[data-tooltip]::before {
  content: attr(data-tooltip);
  position: absolute;
  bottom: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%) scale(0.95);
  padding: 0.375rem 0.625rem;
  background: #0d1117;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 6px;
  color: #c9d1d9;
  font-size: 0.75rem;
  white-space: nowrap;
  opacity: 0;
  visibility: hidden;
  transition: all 0.15s ease;
  pointer-events: none;
  z-index: 1000;
  z-index: 100;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.cmd-email-action-btn[data-tooltip]::after {
  content: '';
  position: absolute;
  bottom: calc(100% + 3px);
  left: 50%;
  transform: translateX(-50%);
  width: 0;
  height: 0;
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
  border-top: 5px solid rgba(255, 255, 255, 0.15);
  opacity: 0;
  visibility: hidden;
  transition: all 0.15s ease;
  pointer-events: none;
  z-index: 1000;
}

.cmd-email-action-btn[data-tooltip]:hover::before,
.cmd-email-action-btn[data-tooltip]:hover::after {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) scale(1);
}

.cmd-case-header {
  padding-bottom: 1rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.cmd-priority-badge {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  border-radius: 50px;
  font-size: 0.75rem;
  font-weight: 600;
  margin-top: 0.5rem;
}

.cmd-priority-badge.critical {
  background: rgba(239, 68, 68, 0.2);
  color: #ef4444;
  border: 1px solid rgba(239, 68, 68, 0.3);
}

.cmd-section-title {
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: #888;
  margin-bottom: 0.75rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.5rem;
  overflow: hidden;
}

.cmd-section-title span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.cmd-tools-section {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.cmd-tool-btn {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.625rem 0.875rem;
  background: transparent;
  border: none;
  border-radius: 8px;
  color: #c9d1d9;
  font-size: 0.9rem;
  cursor: pointer;
  transition: all 0.2s ease;
  text-align: left;
}

.cmd-tool-btn:hover {
  background: rgba(255, 255, 255, 0.05);
  color: #fff;
}

.cmd-tool-btn.active {
  background: rgba(166, 93, 71, 0.2);
  color: #fff;
}

.cmd-tool-btn svg {
  flex-shrink: 0;
}

.cmd-action-btn {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 0.75rem;
  background: rgba(46, 64, 49, 0.3);
  border: 1px solid rgba(46, 64, 49, 0.5);
  border-radius: 6px;
  color: #c9d1d9;
  font-size: 0.8rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.cmd-action-btn:hover {
  background: rgba(46, 64, 49, 0.5);
  border-color: var(--accent-secondary);
}

/* Tooltips for Action Buttons */
.cmd-action-btn {
  position: relative;
}

.cmd-action-btn[data-tooltip]::before {
  content: attr(data-tooltip);
  position: absolute;
  bottom: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%) scale(0.95);
  padding: 0.375rem 0.625rem;
  background: #0d1117;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 6px;
  color: #c9d1d9;
  font-size: 0.75rem;
  white-space: nowrap;
  opacity: 0;
  visibility: hidden;
  transition: all 0.15s ease;
  pointer-events: none;
  z-index: 1000;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.cmd-action-btn[data-tooltip]::after {
  content: '';
  position: absolute;
  bottom: calc(100% + 3px);
  left: 50%;
  transform: translateX(-50%);
  width: 0;
  height: 0;
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
  border-top: 5px solid rgba(255, 255, 255, 0.15);
  opacity: 0;
  visibility: hidden;
  transition: all 0.15s ease;
  pointer-events: none;
  z-index: 1000;
}

.cmd-action-btn[data-tooltip]:hover::before,
.cmd-action-btn[data-tooltip]:hover::after {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) scale(1);
}

/* Center Workspace */
.cmd-workspace {
  background: #0d1117;
  display: flex;
  flex-direction: column;
  min-height: 500px;
}

.cmd-view {
  display: none;
  flex-direction: column;
  height: 100%;
  animation: fadeIn 0.3s ease;
}

.cmd-view.active {
  display: flex;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

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

.cmd-ai-avatar {
  width: 36px;
  height: 36px;
  background: linear-gradient(135deg, var(--accent-primary), #d97a5c);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700;
  color: white;
}

.cmd-context-pills {
  display: flex;
  gap: 0.5rem;
}

.cmd-pill {
  padding: 0.25rem 0.625rem;
  background: rgba(46, 64, 49, 0.3);
  border: 1px solid rgba(46, 64, 49, 0.5);
  border-radius: 50px;
  font-size: 0.75rem;
  color: #888;
}

/* Chat Interface */
.cmd-chat-messages {
  flex: 1;
  padding: 1.5rem;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.cmd-message {
  display: flex;
  gap: 0.75rem;
  max-width: 90%;
}

.cmd-message.ai {
  align-self: flex-start;
}

.cmd-message.user {
  align-self: flex-end;
  flex-direction: row-reverse;
}

.cmd-message-content {
  background: #161b22;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 1rem;
  font-size: 0.9rem;
  line-height: 1.6;
  color: #c9d1d9;
}

.cmd-message.user .cmd-message-content {
  background: rgba(166, 93, 71, 0.2);
  border-color: rgba(166, 93, 71, 0.3);
}

.cmd-suggested-actions {
  display: flex;
  gap: 0.5rem;
  margin-top: 0.75rem;
}

.cmd-suggest-btn {
  padding: 0.5rem 0.875rem;
  background: rgba(46, 64, 49, 0.3);
  border: 1px solid rgba(46, 64, 49, 0.5);
  border-radius: 6px;
  color: #c9d1d9;
  font-size: 0.8rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.cmd-suggest-btn:hover {
  background: rgba(46, 64, 49, 0.5);
}

.cmd-chat-input {
  display: flex;
  gap: 0.75rem;
  padding: 1rem 1.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.cmd-chat-input input {
  flex: 1;
  padding: 0.75rem 1rem;
  background: #161b22;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  color: #c9d1d9;
  font-size: 0.9rem;
}

.cmd-chat-input input::placeholder {
  color: #666;
}

.cmd-send-btn {
  width: 40px;
  height: 40px;
  background: var(--accent-primary);
  border: none;
  border-radius: 8px;
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
}

.cmd-send-btn:hover {
  background: #8a4d3a;
}

/* Checklist View */
.cmd-checklist {
  flex: 1;
  padding: 1.5rem;
  overflow-y: auto;
}

.cmd-checklist-item {
  display: flex;
  align-items: flex-start;
  gap: 0.875rem;
  padding: 1rem;
  background: #161b22;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  margin-bottom: 0.75rem;
  transition: all 0.2s ease;
}

.cmd-checklist-item.completed {
  opacity: 0.6;
}

.cmd-checklist-item.active {
  border-color: var(--accent-primary);
  background: rgba(166, 93, 71, 0.1);
}

.cmd-checkbox {
  width: 20px;
  height: 20px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-radius: 5px;
  flex-shrink: 0;
  margin-top: 0.1rem;
}

.cmd-checkbox.checked {
  background: var(--accent-secondary);
  border-color: var(--accent-secondary);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3'%3E%3Cpolyline points='20 6 9 17 4 12'/%3E%3C/svg%3E");
  background-size: 14px;
  background-position: center;
  background-repeat: no-repeat;
}

.cmd-checklist-content {
  flex: 1;
}

.cmd-checklist-title {
  font-size: 0.95rem;
  color: #c9d1d9;
  margin-bottom: 0.25rem;
}

.cmd-checklist-item.completed .cmd-checklist-title {
  text-decoration: line-through;
  color: #888;
}

.cmd-checklist-meta {
  font-size: 0.8rem;
  color: #666;
}

.cmd-journal-btn {
  padding: 0.375rem 0.75rem;
  background: rgba(46, 64, 49, 0.3);
  border: 1px solid rgba(46, 64, 49, 0.5);
  border-radius: 6px;
  color: #888;
  font-size: 0.75rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.cmd-journal-btn:hover {
  background: rgba(46, 64, 49, 0.5);
  color: #c9d1d9;
}

.cmd-checklist-insight {
  margin: 0 1.5rem 1.5rem;
  padding: 1rem;
  background: rgba(166, 93, 71, 0.1);
  border: 1px solid rgba(166, 93, 71, 0.2);
  border-radius: 10px;
}

/* Journal View */
.cmd-journal-entries {
  flex: 1;
  padding: 1.5rem;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.cmd-journal-entry {
  display: flex;
  gap: 1rem;
  padding: 1rem;
  background: #161b22;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
}

.cmd-journal-time {
  font-size: 0.75rem;
  color: #666;
  font-weight: 600;
  white-space: nowrap;
  padding-top: 0.25rem;
}

.cmd-journal-content {
  flex: 1;
}

.cmd-journal-tags {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
}

.cmd-tag {
  padding: 0.125rem 0.5rem;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 4px;
  font-size: 0.7rem;
  color: #888;
}

.cmd-tag.technical {
  background: rgba(46, 64, 49, 0.3);
  color: var(--accent-secondary);
}

.cmd-tag.account {
  background: rgba(166, 93, 71, 0.2);
  color: var(--accent-primary);
}

.cmd-journal-content p {
  font-size: 0.9rem;
  color: #c9d1d9;
  line-height: 1.6;
  margin: 0;
}

.cmd-journal-attachment {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 0.75rem;
  padding: 0.5rem 0.75rem;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 6px;
  font-size: 0.8rem;
  color: #888;
}

.cmd-journal-input {
  padding: 1rem 1.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.cmd-journal-input textarea {
  width: 100%;
  height: 80px;
  padding: 0.75rem;
  background: #161b22;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  color: #c9d1d9;
  font-size: 0.9rem;
  resize: none;
}

.cmd-journal-action {
  padding: 0.5rem 1rem;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 6px;
  color: #888;
  font-size: 0.8rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.cmd-journal-action:hover {
  border-color: var(--accent-secondary);
  color: #c9d1d9;
}

.cmd-journal-action.primary {
  background: var(--accent-secondary);
  border-color: var(--accent-secondary);
  color: white;
}

.cmd-journal-action.primary:hover {
  background: #3d5a47;
}

/* Script Check View */
.cmd-script-comparison {
  flex: 1;
  padding: 1.5rem;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 1rem;
  align-items: center;
}

.cmd-script-panel {
  background: #161b22;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  overflow: hidden;
}

.cmd-script-header {
  padding: 0.75rem 1rem;
  background: rgba(255, 255, 255, 0.05);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  font-size: 0.8rem;
  font-weight: 600;
  color: #888;
}

.cmd-code-block {
  padding: 1rem;
  margin: 0;
  font-family: 'SF Mono', Monaco, monospace;
  font-size: 0.8rem;
  line-height: 1.6;
  color: #c9d1d9;
  overflow-x: auto;
}

.cmd-script-arrow {
  display: flex;
  align-items: center;
  justify-content: center;
}

.cmd-script-analysis {
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.cmd-analysis-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
}

.cmd-analysis-item.success {
  color: #22c55e;
}

.cmd-analysis-item.warning {
  color: #eab308;
}

.cmd-analysis-item.info {
  color: #3b82f6;
}

/* Right Dashboard */
.cmd-dashboard {
  background: #161b22;
  padding: 1.5rem 1rem;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.cmd-dash-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.9rem;
  font-weight: 600;
  color: #c9d1d9;
  padding-bottom: 1rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.cmd-dash-section {
  padding-bottom: 1rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.cmd-dash-label {
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #888;
  margin-bottom: 0.75rem;
}

/* Unified Case Health Box */
.cmd-health-box {
  background: #0d1117;
  border-radius: 8px;
  padding: 1rem;
}

.cmd-sentiment-meter {
  padding-bottom: 0.75rem;
}

.cmd-sentiment-bar {
  height: 8px;
  background: rgba(255, 255, 255, 0.1);
  border-radius: 4px;
  overflow: hidden;
}

.cmd-sentiment-fill {
  height: 100%;
  border-radius: 4px;
  transition: width 0.5s ease;
}

.cmd-sentiment-labels {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.25rem;
  margin-top: 0.5rem;
  font-size: 0.65rem;
  color: #666;
}

.cmd-metric-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.5rem 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.cmd-metric-row:last-child {
  border-bottom: none;
}

.cmd-metric-name {
  font-size: 0.85rem;
  color: #888;
}

.cmd-metric-value {
  font-size: 0.8rem;
  font-weight: 600;
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
}

.cmd-metric-value.good {
  color: #22c55e;
  background: rgba(34, 197, 94, 0.1);
}

.cmd-metric-value.warning {
  color: #eab308;
  background: rgba(234, 179, 8, 0.1);
}

.cmd-risk-indicator {
  padding-top: 0.75rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  margin-top: 0.75rem;
}

.cmd-risk-badge {
  display: inline-block;
  padding: 0.375rem 0.875rem;
  background: rgba(234, 179, 8, 0.2);
  border: 1px solid rgba(234, 179, 8, 0.3);
  border-radius: 50px;
  font-size: 0.85rem;
  font-weight: 600;
  color: #eab308;
}

.cmd-timeline-mini {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 0.5rem;
}

.cmd-tl-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.2);
}

.cmd-tl-dot.active {
  background: var(--accent-secondary);
}

.cmd-tl-dot.current {
  background: var(--accent-primary);
  box-shadow: 0 0 0 3px rgba(166, 93, 71, 0.3);
}

.cmd-tl-line {
  flex: 1;
  height: 2px;
  background: var(--accent-secondary);
  margin: 0 0.25rem;
}

.cmd-tl-line.pending {
  background: rgba(255, 255, 255, 0.1);
}

.cmd-dash-alert {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 1rem;
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.2);
  border-radius: 8px;
  color: #ef4444;
}

/* Compact Email Preview in Dashboard */
.cmd-email-preview-compact {
  background: #0d1117;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  padding: 1rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.cmd-email-preview-compact:hover {
  border-color: rgba(166, 93, 71, 0.3);
  background: rgba(166, 93, 71, 0.05);
}

.cmd-email-sender {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
}

.cmd-email-avatar {
  width: 36px;
  height: 36px;
  background: linear-gradient(135deg, var(--accent-primary), #d97a5c);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  font-weight: 600;
  color: white;
  flex-shrink: 0;
}

.cmd-email-info {
  flex: 1;
  min-width: 0;
}

.cmd-email-name {
  font-size: 0.9rem;
  font-weight: 600;
  color: #c9d1d9;
  margin-bottom: 0.25rem;
}

.cmd-email-subject {
  font-size: 0.8rem;
  color: #888;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.cmd-email-time-small {
  font-size: 0.75rem;
  color: #666;
  flex-shrink: 0;
}

.cmd-email-snippet {
  font-size: 0.85rem;
  color: #888;
  line-height: 1.5;
  margin-bottom: 0.75rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.cmd-email-actions-row {
  display: flex;
  gap: 0.5rem;
}

.cmd-email-action-btn {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.5rem 0.875rem;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 6px;
  color: #888;
  font-size: 0.8rem;
  cursor: pointer;
  transition: all 0.2s ease;
  flex: 1;
  justify-content: center;
}

.cmd-email-action-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #c9d1d9;
}

.cmd-email-action-btn.primary {
  background: rgba(166, 93, 71, 0.2);
  border-color: rgba(166, 93, 71, 0.3);
  color: #c9d1d9;
}

.cmd-email-action-btn.primary:hover {
  background: rgba(166, 93, 71, 0.3);
}

.cmd-email-action-btn.icon-only {
  padding: 0.5rem;
  flex: 0 0 auto;
  position: relative;
}

/* Tooltip for icon buttons */
.cmd-email-action-btn[data-tooltip]::before {
  content: attr(data-tooltip);
  position: absolute;
  bottom: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%) scale(0.95);
  padding: 0.375rem 0.625rem;
  background: #0d1117;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 6px;
  color: #c9d1d9;
  font-size: 0.75rem;
  white-space: nowrap;
  opacity: 0;
  visibility: hidden;
  transition: all 0.15s ease;
  pointer-events: none;
  z-index: 1000;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.cmd-email-action-btn[data-tooltip]::after {
  content: '';
  position: absolute;
  bottom: calc(100% + 3px);
  left: 50%;
  transform: translateX(-50%);
  width: 0;
  height: 0;
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
  border-top: 5px solid rgba(255, 255, 255, 0.15);
  opacity: 0;
  visibility: hidden;
  transition: all 0.15s ease;
  pointer-events: none;
  z-index: 1000;
}

.cmd-email-action-btn[data-tooltip]:hover::before,
.cmd-email-action-btn[data-tooltip]:hover::after {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) scale(1);
}

/* Email Modal */
.cmd-modal {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
}

.cmd-modal.active {
  opacity: 1;
  visibility: visible;
}

.cmd-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(4px);
}

.cmd-modal-content {
  position: relative;
  width: 90%;
  max-width: 700px;
  max-height: 85vh;
  background: #161b22;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transform: scale(0.95);
  transition: transform 0.3s ease;
}

.cmd-modal.active .cmd-modal-content {
  transform: scale(1);
}

.cmd-modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 1.5rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  background: #0d1117;
}

.cmd-modal-header h3 {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin: 0;
  font-size: 1rem;
  color: #c9d1d9;
}

.cmd-modal-close {
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.05);
  border: none;
  border-radius: 8px;
  color: #888;
  cursor: pointer;
  transition: all 0.2s ease;
}

.cmd-modal-close:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #c9d1d9;
}

.cmd-modal-body {
  flex: 1;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
}

/* Modal Email Thread */
.cmd-modal-thread {
  padding: 1.5rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.cmd-modal-email {
  padding: 1rem;
  background: #0d1117;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  margin-bottom: 1rem;
}

.cmd-modal-email:last-child {
  margin-bottom: 0;
}

.cmd-modal-email.internal {
  border-left: 3px solid var(--accent-secondary);
  background: rgba(46, 64, 49, 0.1);
}

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

.cmd-modal-email-meta {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.cmd-modal-from {
  font-size: 0.9rem;
  font-weight: 600;
  color: #c9d1d9;
}

.cmd-modal-to {
  font-size: 0.8rem;
  color: #666;
}

.cmd-modal-timestamp {
  font-size: 0.8rem;
  color: #666;
  flex-shrink: 0;
}

.cmd-modal-email-body {
  font-size: 0.9rem;
  color: #c9d1d9;
  line-height: 1.7;
}

.cmd-modal-email-body p {
  margin: 0 0 0.75rem;
}

.cmd-modal-email-body p:last-child {
  margin-bottom: 0;
}

/* Modal Composer */
.cmd-modal-composer {
  padding: 1.5rem;
  background: #161b22;
}

.cmd-modal-tabs {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 1rem;
}

.cmd-modal-tab {
  padding: 0.5rem 1rem;
  background: transparent;
  border: none;
  border-radius: 6px;
  color: #888;
  font-size: 0.85rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.cmd-modal-tab:hover {
  color: #c9d1d9;
  background: rgba(255, 255, 255, 0.05);
}

.cmd-modal-tab.active {
  color: #fff;
  background: rgba(166, 93, 71, 0.2);
}

.cmd-modal-to-field {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem;
  background: #0d1117;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  margin-bottom: 0.75rem;
  font-size: 0.9rem;
}

.cmd-modal-to-field span:first-child {
  color: #666;
}

.cmd-modal-recipient {
  color: #c9d1d9;
}

.cmd-modal-textarea {
  width: 100%;
  min-height: 120px;
  padding: 1rem;
  background: #0d1117;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  color: #c9d1d9;
  font-size: 0.95rem;
  line-height: 1.7;
  resize: vertical;
  margin-bottom: 0.75rem;
}

.cmd-modal-textarea::placeholder {
  color: #666;
}

/* Toolbar */
.cmd-modal-toolbar {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem;
  background: #0d1117;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  margin-bottom: 0.75rem;
  flex-wrap: wrap;
}

.cmd-toolbar-group {
  display: flex;
  gap: 0.5rem;
}

.cmd-toolbar-btn {
  display: flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.5rem 0.875rem;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 6px;
  color: #888;
  font-size: 0.8rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.cmd-toolbar-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #c9d1d9;
}

.cmd-toolbar-btn.highlight {
  background: rgba(166, 93, 71, 0.2);
  border-color: rgba(166, 93, 71, 0.3);
  color: #c9d1d9;
}

.cmd-toolbar-btn.highlight:hover {
  background: rgba(166, 93, 71, 0.3);
}

.cmd-toolbar-divider {
  width: 1px;
  height: 24px;
  background: rgba(255, 255, 255, 0.1);
}

/* Generated Update in Modal */
.cmd-modal-generated {
  padding: 1rem;
  background: rgba(46, 64, 49, 0.1);
  border: 1px solid rgba(46, 64, 49, 0.3);
  border-radius: 10px;
  margin-bottom: 0.75rem;
}

.cmd-generated-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.8rem;
  color: var(--accent-secondary);
  margin-bottom: 0.75rem;
}

.cmd-generated-body {
  font-size: 0.9rem;
  color: #c9d1d9;
  line-height: 1.7;
  white-space: pre-line;
  padding: 1rem;
  background: #0d1117;
  border-radius: 8px;
  margin-bottom: 0.75rem;
  max-height: 200px;
  overflow-y: auto;
}

.cmd-generated-actions {
  display: flex;
  gap: 0.5rem;
  justify-content: flex-end;
}

.cmd-gen-btn {
  padding: 0.5rem 1rem;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 6px;
  color: #888;
  font-size: 0.85rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.cmd-gen-btn:hover {
  border-color: var(--accent-secondary);
  color: #c9d1d9;
}

.cmd-gen-btn.primary {
  background: var(--accent-secondary);
  border-color: var(--accent-secondary);
  color: white;
}

.cmd-gen-btn.primary:hover {
  background: #3d5a47;
}

/* Modal Footer */
.cmd-modal-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.cmd-filter-checkbox {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  color: #888;
  cursor: pointer;
}

.cmd-filter-checkbox input {
  accent-color: var(--accent-secondary);
}

.cmd-modal-actions {
  display: flex;
  gap: 0.5rem;
}

.cmd-modal-btn {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.625rem 1.25rem;
  border-radius: 8px;
  font-size: 0.9rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
}

.cmd-modal-btn.secondary {
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #888;
}

.cmd-modal-btn.secondary:hover {
  border-color: var(--accent-secondary);
  color: #c9d1d9;
}

.cmd-modal-btn.primary {
  background: var(--accent-secondary);
  border: none;
  color: white;
}

.cmd-modal-btn.primary:hover {
  background: #3d5a47;
}

/* Responsive Adjustments */
@media (max-width: 1200px) {
  .command-center-container {
    grid-template-columns: 280px 1fr 260px;
  }

  .cmd-timeline-mini+div,
  .cmd-sentiment-labels {
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
  }
}

@media (max-width: 1024px) {
  .command-center-container {
    grid-template-columns: 220px 1fr 250px;
  }
}

@media (max-width: 768px) {
  .command-center-container {
    grid-template-columns: 1fr;
    grid-template-rows: auto 1fr auto;
  }

  .cmd-sidebar {
    flex-direction: row;
    flex-wrap: wrap;
    padding: 1rem;
  }

  .cmd-case-header {
    flex: 1;
    min-width: 150px;
    border-bottom: none;
    border-right: 1px solid rgba(255, 255, 255, 0.1);
    padding-bottom: 0;
    padding-right: 1rem;
  }

  .cmd-script-comparison {
    grid-template-columns: 1fr;
  }

  .cmd-script-arrow {
    transform: rotate(90deg);
  }
}

/* Base Mobile Adjustments (< 480px) */
@media (max-width: 480px) {
  .container {
    padding: 0 1rem;
  }

  .cs1-roi-callout .roi-arrow {
    flex-direction: column;
    gap: 0.25rem;
  }

  .hub-badge {
    white-space: normal;
    display: inline;
  }
}
/* =========================================================================
   The Operator's Dossier (Footer Override)
   ========================================================================= */

.dossier-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  margin-top: 2rem;
  align-items: center;
}

.dossier-identity {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  border-right: 1px solid var(--border-color);
  padding-right: 2rem;
}

.dossier-name {
  font-size: 2rem;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: -0.02em;
}

.dossier-role {
  font-size: 1.1rem;
  color: var(--accent-primary);
  font-weight: 500;
}

.dossier-location {
  font-size: 0.95rem;
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
}

.dossier-links {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.dossier-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text-secondary);
  text-decoration: none;
  transition: color 0.2s ease;
}

.dossier-link:hover {
  color: var(--accent-secondary);
}

.dossier-assets {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.dossier-blurb {
  font-size: 1.05rem;
  line-height: 1.6;
  color: var(--text-secondary);
}

.dossier-cta-group {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  align-items: flex-start;
  margin-top: 1rem;
}

.btn-dossier-primary {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 1rem 1.5rem;
  background: var(--surface-light);
  border: 1px solid rgba(217, 119, 6, 0.4);
  border-radius: 8px;
  color: var(--accent-primary);
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  transition: all 0.3s ease;
  box-shadow: 0 0 15px rgba(217, 119, 6, 0.15);
}

.btn-dossier-primary:hover {
  background: rgba(217, 119, 6, 0.05);
  border-color: var(--accent-primary);
  box-shadow: 0 0 25px rgba(217, 119, 6, 0.3);
  transform: translateY(-1px);
}

.link-dossier-secondary {
  font-size: 0.85rem;
  color: #888;
  text-decoration: underline;
  text-underline-offset: 4px;
  transition: color 0.2s ease;
  margin-left: 0.5rem;
}

.link-dossier-secondary:hover {
  color: var(--text-primary);
}

@media (max-width: 768px) {
  .dossier-grid {
    grid-template-columns: 1fr;
    gap: 2.5rem;
  }
  
  .dossier-identity {
    border-right: none;
    border-bottom: 1px solid var(--border-color);
    padding-right: 0;
    padding-bottom: 2rem;
  }
}
