/* ==========================================================================
   TasteOps — Autonomous Spatial Curation Design System
   Theme: ORGANIC INTELLIGENCE • "Technology that understands human taste"
   Palette: Forest Green, Muted Sage, Warm Ivory, Soft Cream, Terracotta
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=DM+Serif+Display:ital@0;1&family=Inter:wght@300;400;500;600;700&family=JetBrains+Mono:wght@400;500;600&display=swap');

:root {
  /* Primary Brand Colors */
  --forest-green: #102A22;
  --forest-green-hover: #0a1c17;
  --deep-botanical: #24483B;
  --muted-sage: #8D9881;
  --sage-light: #E7EBE4;
  --sage-tint: rgba(141, 152, 129, 0.18);

  /* Background Surfaces */
  --warm-ivory: #F7F4EC;
  --soft-cream: #EEE9DC;
  --warm-stone: #D5CDBD;
  --border-stone: #E3DED3;
  --border-subtle: #E8E3D8;
  --white: #FFFFFF;

  /* Design System Surface Aliases */
  --bg-surface: var(--white);
  --bg-surface-elevated: #FAF8F5;
  --bg-deep: #F0ECE3;
  --bg-card: var(--white);
  --bg-card-elevated: #FAF8F5;

  /* Primary Action Tokens & Aliases */
  --primary: var(--forest-green);
  --primary-hover: var(--forest-green-hover);
  --accent: var(--terracotta);
  --accent-hover: var(--terracotta-hover);

  /* Semantic Intelligence Tokens */
  --cyan: #0E7490;
  --cyan-tint: rgba(14, 116, 144, 0.08);
  --cyan-border: rgba(14, 116, 144, 0.25);
  --amber: #B45309;
  --amber-tint: rgba(180, 83, 9, 0.08);
  --amber-border: rgba(180, 83, 9, 0.25);
  --emerald: #047857;
  --emerald-tint: rgba(4, 120, 87, 0.08);
  --emerald-border: rgba(4, 120, 87, 0.25);
  --rose: #BE123C;
  --rose-tint: rgba(190, 18, 60, 0.08);
  --rose-border: rgba(190, 18, 60, 0.25);

  /* Accent Colors */
  --terracotta: #C96842;
  --terracotta-hover: #b55a36;
  --soft-clay: #D99572;
  --clay-tint: rgba(201, 104, 66, 0.12);

  /* Text & Ink */
  --ink: #18201D;
  --text-primary: #18201D;
  --text-secondary: #48544F;
  --text-muted: #66706A;
  --text-subtle: #8A948F;
  --text-light: #FFFFFF;

  /* Semantic State Colors */
  --state-running: #5278D9;
  --state-completed: #4E8B70;
  --state-waiting: #C59B48;
  --state-error: #B84A3A;

  /* Typography Families & Aliases */
  --font-serif: 'DM Serif Display', Georgia, 'Times New Roman', serif;
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: 'JetBrains Mono', SFMono-Regular, Consolas, monospace;
  --font-heading: var(--font-serif);

  /* Layout & Geometry */
  --sidebar-width: 240px;
  --container-max: 1440px;
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 18px;
  --radius-xl: 24px;
  --radius-full: 9999px;
  --radius-arch: 120px 120px 0 0;
  --radius-arch-sm: 40px 40px 0 0;
  --focus-ring: 0 0 0 3px rgba(36, 72, 59, 0.25);

  /* Shadows */
  --shadow-subtle: 0 2px 8px rgba(24, 32, 29, 0.04), 0 1px 2px rgba(24, 32, 29, 0.03);
  --shadow-card: 0 4px 16px rgba(24, 32, 29, 0.05), 0 1px 3px rgba(24, 32, 29, 0.03);
  --shadow-elevated: 0 12px 32px rgba(24, 32, 29, 0.08), 0 2px 6px rgba(24, 32, 29, 0.04);
  --shadow-input: 0 2px 10px rgba(16, 42, 34, 0.05);

  /* Transitions */
  --transition-fast: 0.15s ease;
  --transition-normal: 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  --transition-smooth: 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

/* ==========================================================================
   CSS Reset & Base
   ========================================================================== */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  background-color: var(--warm-ivory);
}

body {
  font-family: var(--font-sans);
  color: var(--text-primary);
  background-color: var(--warm-ivory);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  min-height: 100vh;
  display: flex;
  overflow-x: hidden;
}

/* Headings */
h1, h2, h3, .serif-heading {
  font-family: var(--font-serif);
  font-weight: 400;
  color: var(--ink);
  letter-spacing: -0.01em;
}

p, span, label, input, button, table {
  font-family: var(--font-sans);
}

a {
  color: inherit;
  text-decoration: none;
  transition: color var(--transition-fast);
}

/* Arch Motif Utilities */
.arch-frame {
  border-radius: var(--radius-arch);
  overflow: hidden;
}

.arch-header {
  border-radius: var(--radius-arch-sm);
}

/* ==========================================================================
   Application Shell Layout (Sidebar + Main)
   ========================================================================== */
#app-nav {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  width: var(--sidebar-width);
  z-index: 100;
  transition: transform var(--transition-normal);
}

#app-nav.hidden-nav {
  display: none !important;
}

.main-wrapper {
  margin-left: var(--sidebar-width);
  flex: 1;
  min-height: 100vh;
  background-color: var(--warm-ivory);
  padding: 2.25rem 2.5rem 5rem 2.5rem;
  max-width: calc(100vw - var(--sidebar-width));
  transition: margin var(--transition-normal);
}

.main-wrapper.full-width {
  margin-left: 0 !important;
  max-width: 100vw !important;
  padding: 0 !important;
}

/* ==========================================================================
   Sidebar Navigation Component
   ========================================================================== */
.sidebar {
  width: var(--sidebar-width);
  height: 100vh;
  background-color: var(--warm-ivory);
  border-right: 1px solid var(--border-stone);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 1.75rem 1.25rem 1.5rem 1.25rem;
  user-select: none;
}

.sidebar-brand {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  padding: 0 0.5rem 1.5rem 0.5rem;
  border-bottom: 1px solid var(--border-stone);
  text-decoration: none;
}

.brand-logo-lockup {
  display: flex;
  align-items: center;
  gap: 0.65rem;
}

.brand-arch-icon {
  width: 24px;
  height: 28px;
  background: var(--forest-green);
  border-radius: 12px 12px 0 0;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding-bottom: 4px;
}

.brand-arch-inner {
  width: 10px;
  height: 14px;
  background: var(--warm-ivory);
  border-radius: 5px 5px 0 0;
}

.brand-name {
  font-family: var(--font-serif);
  font-size: 1.5rem;
  font-weight: 400;
  color: var(--forest-green);
  line-height: 1;
}

.brand-tagline {
  font-size: 0.625rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted-text);
  margin-left: 0.1rem;
}

/* Navigation List */
.sidebar-nav {
  margin-top: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  list-style: none;
  flex: 1;
}

.sidebar-nav-item a {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 0.65rem 0.85rem;
  border-radius: var(--radius-sm);
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-secondary);
  transition: all var(--transition-fast);
}

.sidebar-nav-item a:hover {
  background-color: var(--soft-cream);
  color: var(--forest-green);
}

.sidebar-nav-item a.active {
  background-color: var(--sage-light);
  color: var(--forest-green);
  font-weight: 600;
}

.sidebar-nav-item a.active .nav-icon {
  color: var(--forest-green);
}

.nav-icon {
  width: 18px;
  height: 18px;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

/* User Profile Badge at Bottom of Sidebar */
.sidebar-user {
  padding-top: 1.25rem;
  border-top: 1px solid var(--border-stone);
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.user-avatar {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-full);
  background: var(--forest-green);
  color: var(--white);
  font-weight: 600;
  font-size: 0.875rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.user-meta {
  display: flex;
  flex-direction: column;
  line-height: 1.25;
}

.user-name {
  font-size: 0.825rem;
  font-weight: 600;
  color: var(--text-primary);
}

.user-role {
  font-size: 0.725rem;
  color: var(--text-muted);
}

/* ==========================================================================
   Opening / Splash Screen View (/)
   ========================================================================== */
.splash-container {
  min-height: 100vh;
  width: 100%;
  background-color: var(--warm-ivory);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  position: relative;
  overflow: hidden;
  padding: 3rem 4rem;
}

.splash-top-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  z-index: 2;
}

.splash-center {
  max-width: 640px;
  margin: 0 auto;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  z-index: 2;
  padding: 2rem 0;
}

.splash-logo-arch {
  width: 64px;
  height: 76px;
  background: var(--forest-green);
  border-radius: 32px 32px 0 0;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  padding-bottom: 12px;
  margin-bottom: 1.75rem;
  box-shadow: 0 10px 25px rgba(16, 42, 34, 0.12);
}

.splash-logo-inner {
  width: 26px;
  height: 36px;
  background: var(--warm-ivory);
  border-radius: 13px 13px 0 0;
}

.splash-title {
  font-family: var(--font-serif);
  font-size: 3.5rem;
  color: var(--forest-green);
  line-height: 1;
  margin-bottom: 0.5rem;
}

.splash-subtitle {
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--muted-sage);
  margin-bottom: 2rem;
}

.splash-philosophy {
  font-family: var(--font-serif);
  font-size: 1.85rem;
  font-style: italic;
  color: var(--ink);
  margin-bottom: 1.5rem;
}

.splash-divider {
  width: 80px;
  height: 1px;
  background-color: var(--warm-stone);
  margin: 0 auto 1.5rem auto;
}

.splash-workflow {
  font-size: 0.875rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-secondary);
  margin-bottom: 2.5rem;
}

.splash-cta {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  background: var(--forest-green);
  color: var(--white);
  padding: 0.95rem 2rem;
  border-radius: var(--radius-full);
  font-size: 0.95rem;
  font-weight: 500;
  border: none;
  cursor: pointer;
  transition: all var(--transition-normal);
  box-shadow: 0 6px 20px rgba(16, 42, 34, 0.18);
}

.splash-cta:hover {
  background: var(--forest-green-hover);
  transform: translateY(-2px);
  box-shadow: 0 10px 28px rgba(16, 42, 34, 0.25);
}

.splash-botanical-corner {
  position: absolute;
  bottom: -40px;
  left: -40px;
  width: 420px;
  height: 380px;
  border-radius: var(--radius-arch);
  overflow: hidden;
  box-shadow: 0 20px 40px rgba(24, 32, 29, 0.08);
  border: 4px solid var(--white);
  z-index: 1;
}

.splash-botanical-corner img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: saturate(0.95);
}

/* ==========================================================================
   Main Dashboard — Hero Area
   ========================================================================== */
.hero-editorial {
  display: grid;
  grid-template-columns: 1fr 420px;
  gap: 2.5rem;
  align-items: center;
  background: var(--white);
  border: 1px solid var(--border-stone);
  border-radius: var(--radius-lg);
  padding: 2.5rem 3rem;
  box-shadow: var(--shadow-subtle);
  margin-bottom: 2rem;
  position: relative;
  overflow: hidden;
}

.hero-eyebrow {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--terracotta);
  margin-bottom: 0.75rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.hero-headline {
  font-size: 3rem;
  line-height: 1.12;
  color: var(--forest-green);
  margin-bottom: 1.25rem;
  max-width: 580px;
}

.hero-supporting {
  font-size: 1.05rem;
  color: var(--text-secondary);
  line-height: 1.6;
  max-width: 540px;
}

.hero-image-arch {
  height: 280px;
  border-radius: var(--radius-arch);
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(16, 42, 34, 0.1);
  border: 1px solid var(--border-stone);
  position: relative;
}

.hero-image-arch img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* ==========================================================================
   Primary Input & Space Filters
   ========================================================================== */
.primary-input-card {
  background: var(--white);
  border: 1px solid var(--border-stone);
  border-radius: var(--radius-lg);
  padding: 1.5rem 1.75rem;
  box-shadow: var(--shadow-subtle);
  margin-bottom: 2rem;
}

.primary-input-row {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  background: var(--warm-ivory);
  border: 1px solid var(--warm-stone);
  border-radius: 16px;
  padding: 0.4rem 0.5rem 0.4rem 1.25rem;
  box-shadow: var(--shadow-input);
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.primary-input-row:focus-within {
  border-color: var(--forest-green);
  box-shadow: 0 0 0 3px rgba(16, 42, 34, 0.08);
}

.sparkle-icon {
  color: var(--terracotta);
  font-size: 1.25rem;
  display: flex;
  align-items: center;
  flex-shrink: 0;
}

.primary-text-input {
  flex: 1;
  border: none;
  background: transparent;
  font-size: 1.05rem;
  color: var(--ink);
  outline: none;
  font-family: var(--font-sans);
}

.primary-text-input::placeholder {
  color: var(--text-muted);
}

.primary-submit-btn {
  background: var(--forest-green);
  color: var(--white);
  border: none;
  width: 46px;
  height: 46px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  cursor: pointer;
  transition: all var(--transition-fast);
  flex-shrink: 0;
}

.primary-submit-btn:hover {
  background: var(--forest-green-hover);
  transform: translateX(2px);
}

/* Filters & Selectors */
.filters-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1.25rem;
  margin-top: 1.25rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--border-stone);
}

.space-pills {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.filter-pill {
  background: var(--soft-cream);
  color: var(--text-secondary);
  border: 1px solid var(--border-stone);
  border-radius: var(--radius-full);
  padding: 0.35rem 0.85rem;
  font-size: 0.8rem;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.filter-pill:hover, .filter-pill.active {
  background: var(--forest-green);
  color: var(--white);
  border-color: var(--forest-green);
}

.compact-selectors {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.compact-select {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  background: var(--white);
  border: 1px solid var(--border-stone);
  border-radius: var(--radius-sm);
  padding: 0.4rem 0.75rem;
  font-size: 0.775rem;
  color: var(--text-primary);
  font-weight: 500;
}

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

/* ==========================================================================
   13-State Deterministic Workflow Timeline Tracker
   ========================================================================== */
.workflow-tracker-card {
  background: var(--white);
  border: 1px solid var(--border-stone);
  border-radius: var(--radius-lg);
  padding: 1.25rem 1.5rem;
  box-shadow: var(--shadow-subtle);
  margin-bottom: 2rem;
  overflow-x: auto;
}

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

.workflow-title-wrap {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.workflow-title {
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.workflow-status-badge {
  font-size: 0.7rem;
  font-weight: 600;
  padding: 0.2rem 0.5rem;
  border-radius: var(--radius-full);
  background: var(--sage-light);
  color: var(--forest-green);
}

.workflow-timeline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: relative;
  min-width: 820px;
  padding: 0.5rem 0;
}

.workflow-timeline::before {
  content: '';
  position: absolute;
  top: 14px;
  left: 20px;
  right: 20px;
  height: 2px;
  background: var(--warm-stone);
  z-index: 1;
}

.wf-step {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.4rem;
  z-index: 2;
  position: relative;
  cursor: pointer;
}

.wf-node {
  width: 28px;
  height: 28px;
  border-radius: var(--radius-full);
  background: var(--white);
  border: 2px solid var(--warm-stone);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--text-muted);
  transition: all var(--transition-fast);
}

.wf-step.completed .wf-node {
  background: var(--forest-green);
  border-color: var(--forest-green);
  color: var(--white);
}

.wf-step.active .wf-node {
  background: var(--terracotta);
  border-color: var(--terracotta);
  color: var(--white);
  box-shadow: 0 0 0 4px var(--clay-tint);
}

.wf-label {
  font-size: 0.675rem;
  font-weight: 500;
  color: var(--text-muted);
  white-space: nowrap;
}

.wf-step.completed .wf-label {
  color: var(--forest-green);
  font-weight: 600;
}

.wf-step.active .wf-label {
  color: var(--terracotta);
  font-weight: 700;
}

/* ==========================================================================
   TasteOps Responsive 5-Milestone Workflow Progress Component
   ========================================================================== */
.tasteops-workflow-progress {
  background: var(--white);
  border: 1px solid var(--border-stone);
  border-radius: var(--radius-md);
  padding: 1.5rem 1.75rem;
  box-shadow: var(--shadow-subtle);
  margin-bottom: 2rem;
  transition: all var(--transition-normal);
}

.workflow-progress-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1.5rem;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
}

.workflow-progress-title-block {
  flex: 1;
  min-width: 280px;
}

.workflow-progress-stage {
  font-family: var(--font-heading, var(--font-serif));
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--forest-green);
  line-height: 1.3;
}

.workflow-progress-action {
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.5;
  margin-top: 0.35rem;
}

.workflow-progress-action strong {
  color: var(--forest-green);
}

.workflow-progress-badge-wrap {
  flex-shrink: 0;
}

/* 5-Milestone Horizontal Stepper Track */
.workflow-stepper {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.5rem 0 1rem;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
}

.stepper-step {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex: 1;
  min-width: 170px;
  position: relative;
  user-select: none;
}

.stepper-circle {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  font-weight: 700;
  font-family: var(--font-mono);
  flex-shrink: 0;
  transition: all var(--transition-normal);
}

.stepper-step.completed .stepper-circle {
  background: var(--forest-green);
  color: var(--white);
  border: 2px solid var(--forest-green);
}

.stepper-step.active .stepper-circle {
  background: var(--terracotta);
  color: var(--white);
  border: 2px solid var(--terracotta);
  box-shadow: 0 0 0 4px var(--clay-tint);
  animation: pulse-ring 2s infinite ease-in-out;
}

.stepper-step.failed .stepper-circle {
  background: var(--state-error);
  color: var(--white);
  border: 2px solid var(--state-error);
}

.stepper-step.upcoming .stepper-circle {
  background: var(--warm-ivory);
  color: var(--text-muted);
  border: 2px solid var(--warm-stone);
}

.stepper-meta {
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.stepper-num {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
}

.stepper-label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-primary);
  white-space: nowrap;
  text-overflow: ellipsis;
  overflow: hidden;
}

.stepper-step.completed .stepper-label {
  color: var(--forest-green);
}

.stepper-step.active .stepper-label {
  color: var(--terracotta);
  font-weight: 700;
}

.stepper-step.failed .stepper-label {
  color: var(--state-error);
}

.stepper-sublabel {
  font-size: 0.72rem;
  color: var(--text-muted);
  white-space: nowrap;
  text-overflow: ellipsis;
  overflow: hidden;
}

.stepper-connector {
  flex: 0 0 28px;
  height: 2px;
  background: var(--warm-stone);
  margin: 0 0.25rem;
  transition: background var(--transition-normal);
}

.stepper-connector.completed {
  background: var(--forest-green);
}

@keyframes pulse-ring {
  0% { box-shadow: 0 0 0 0 var(--clay-tint); }
  70% { box-shadow: 0 0 0 8px rgba(201, 104, 66, 0); }
  100% { box-shadow: 0 0 0 0 rgba(201, 104, 66, 0); }
}

/* Collapsible Technical Diagnostics Drawer */
.pipeline-diagnostics-drawer {
  margin-top: 1rem;
  border-top: 1px solid var(--border-stone);
  padding-top: 0.75rem;
}

.diagnostics-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  user-select: none;
  font-family: var(--font-mono);
  font-size: 0.775rem;
  color: var(--text-muted);
  padding: 0.35rem 0;
  transition: color var(--transition-fast);
}

.diagnostics-summary:hover {
  color: var(--text-primary);
}

.diagnostics-summary-hint {
  font-size: 0.72rem;
}

.diagnostics-summary-hint code {
  background: rgba(0, 0, 0, 0.05);
  padding: 0.15rem 0.4rem;
  border-radius: 4px;
  color: var(--forest-green);
}

.diagnostics-body {
  margin-top: 0.75rem;
  padding: 1rem 1.25rem;
  background: var(--warm-ivory);
  border: 1px solid var(--border-stone);
  border-radius: var(--radius-sm);
  font-size: 0.775rem;
}

.diagnostics-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 0.85rem;
}

.diagnostics-item {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

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

.diagnostics-val {
  font-family: var(--font-mono);
  color: var(--text-primary);
}

/* Progressive Disclosure Evidence Accordion */
.evidence-accordion {
  margin-top: 0.75rem;
  border: 1px solid var(--border-stone);
  border-radius: var(--radius-sm);
  background: var(--white);
  overflow: hidden;
}

.evidence-accordion summary {
  padding: 0.6rem 0.85rem;
  background: var(--warm-ivory);
  font-size: 0.775rem;
  font-weight: 600;
  color: var(--text-secondary);
  cursor: pointer;
  user-select: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition: background var(--transition-fast);
}

.evidence-accordion summary:hover {
  background: var(--soft-cream);
  color: var(--text-primary);
}

.evidence-accordion[open] summary {
  border-bottom: 1px solid var(--border-stone);
}

.evidence-accordion-content {
  padding: 0.85rem;
}

/* Responsive Stepper Adjustments for Mobile / Tablet */
@media (max-width: 900px) {
  .workflow-stepper {
    flex-direction: column;
    align-items: stretch;
    gap: 0.85rem;
  }
  .stepper-connector {
    display: none;
  }
  .stepper-step {
    min-width: 100%;
    padding: 0.5rem;
    border-radius: var(--radius-sm);
    background: var(--warm-ivory);
  }
}

/* ==========================================================================
   Centerpiece Split Grid: Cultural Twin (Left) + Agents & Live Preview (Right)
   ========================================================================== */
.curation-workspace-grid {
  display: grid;
  grid-template-columns: 1.15fr 0.95fr;
  gap: 2rem;
  margin-bottom: 2rem;
}

/* Card Foundations */
.card-editorial {
  background: var(--white);
  border: 1px solid var(--border-stone);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  box-shadow: var(--shadow-subtle);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.card-header-editorial {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 1.25rem;
}

.card-title-editorial {
  font-family: var(--font-serif);
  font-size: 1.5rem;
  color: var(--forest-green);
  line-height: 1.2;
}

.card-subtitle-editorial {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: 0.25rem;
}

/* ==========================================================================
   Cultural Twin Radial Visualization
   ========================================================================== */
.cultural-twin-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 1.5rem 0;
  position: relative;
}

.cultural-radial-vis {
  width: 320px;
  height: 320px;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.radial-ring {
  position: absolute;
  border-radius: var(--radius-full);
  border: 1px dashed var(--warm-stone);
  transition: all var(--transition-normal);
}

.ring-outer {
  width: 310px;
  height: 310px;
  border-color: rgba(141, 152, 129, 0.4);
}

.ring-mid {
  width: 230px;
  height: 230px;
  border-color: rgba(201, 104, 66, 0.35);
}

.ring-inner {
  width: 150px;
  height: 150px;
  border-color: rgba(16, 42, 34, 0.25);
}

.radial-center-badge {
  width: 104px;
  height: 104px;
  border-radius: var(--radius-full);
  background: var(--forest-green);
  color: var(--white);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 5;
  box-shadow: 0 6px 20px rgba(16, 42, 34, 0.2);
  text-align: center;
}

.radial-affinity-score {
  font-family: var(--font-serif);
  font-size: 2rem;
  line-height: 1;
}

.radial-affinity-label {
  font-size: 0.65rem;
  font-weight: 500;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--sage-light);
  margin-top: 0.2rem;
}

/* Category Satellites around the center */
.affinity-satellite {
  position: absolute;
  background: var(--white);
  border: 1px solid var(--border-stone);
  border-radius: var(--radius-full);
  padding: 0.35rem 0.75rem;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  box-shadow: var(--shadow-subtle);
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--ink);
  z-index: 6;
  white-space: nowrap;
  transition: transform var(--transition-fast);
}

.affinity-satellite:hover {
  transform: scale(1.06);
  border-color: var(--forest-green);
}

.satellite-music { top: 12px; left: 50%; transform: translateX(-50%); }
.satellite-books { top: 70px; right: -10px; }
.satellite-brands { bottom: 65px; right: -15px; }
.satellite-lifestyle { bottom: 12px; left: 50%; transform: translateX(-50%); }
.satellite-interests { top: 120px; left: -20px; }

.sat-dot {
  width: 8px;
  height: 8px;
  border-radius: var(--radius-full);
}
.sat-dot.music { background: var(--terracotta); }
.sat-dot.books { background: var(--forest-green); }
.sat-dot.brands { background: var(--state-running); }
.sat-dot.lifestyle { background: var(--muted-sage); }
.sat-dot.interests { background: var(--state-completed); }

/* Cultural Twin Entity Pills underneath */
.cultural-entities-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1.5rem;
  justify-content: center;
}

.entity-pill {
  background: var(--warm-ivory);
  border: 1px solid var(--border-stone);
  border-radius: var(--radius-full);
  padding: 0.35rem 0.75rem;
  font-size: 0.75rem;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.entity-pill strong {
  color: var(--forest-green);
}

/* ==========================================================================
   Specialized Agents Panel & Cards
   ========================================================================== */
.agents-panel-editorial {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.agent-card-editorial {
  background: var(--warm-ivory);
  border: 1px solid var(--border-stone);
  border-radius: var(--radius-md);
  padding: 1.15rem 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.agent-card-editorial:hover {
  border-color: var(--muted-sage);
  box-shadow: var(--shadow-subtle);
}

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

.agent-meta-wrap {
  display: flex;
  align-items: center;
  gap: 0.65rem;
}

.agent-icon-badge {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-sm);
  background: var(--white);
  border: 1px solid var(--border-stone);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
}

.agent-title {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--forest-green);
}

.agent-status-tag {
  font-size: 0.7rem;
  font-weight: 600;
  padding: 0.2rem 0.55rem;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  gap: 0.3rem;
}

.agent-status-tag.running {
  background: rgba(82, 120, 217, 0.12);
  color: var(--state-running);
}

.agent-status-tag.completed {
  background: rgba(78, 139, 112, 0.12);
  color: var(--state-completed);
}

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

/* Audio Waveform Animation */
.waveform-box {
  display: flex;
  align-items: center;
  gap: 3px;
  height: 22px;
  padding: 0 4px;
}

.wave-bar {
  width: 3px;
  background: var(--terracotta);
  border-radius: 2px;
  animation: wavePulse 1.2s ease-in-out infinite alternate;
}

.wave-bar:nth-child(1) { height: 6px; animation-delay: 0.1s; }
.wave-bar:nth-child(2) { height: 16px; animation-delay: 0.3s; }
.wave-bar:nth-child(3) { height: 22px; animation-delay: 0.2s; }
.wave-bar:nth-child(4) { height: 12px; animation-delay: 0.4s; }
.wave-bar:nth-child(5) { height: 18px; animation-delay: 0.15s; }
.wave-bar:nth-child(6) { height: 8px; animation-delay: 0.35s; }

@keyframes wavePulse {
  0% { transform: scaleY(0.4); }
  100% { transform: scaleY(1.1); }
}

/* ==========================================================================
   Live Preview Panel (Dark Contrast Treatment)
   ========================================================================== */
.live-preview-card {
  background: var(--forest-green);
  color: var(--white);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  box-shadow: var(--shadow-card);
  margin-top: 1.5rem;
}

.live-preview-tabs {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  padding-bottom: 0.75rem;
  margin-bottom: 1.25rem;
}

.preview-tab {
  background: transparent;
  border: none;
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.85rem;
  font-weight: 500;
  padding: 0.35rem 0.85rem;
  border-radius: var(--radius-full);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.preview-tab:hover {
  color: var(--white);
}

.preview-tab.active {
  background: rgba(255, 255, 255, 0.15);
  color: var(--white);
  font-weight: 600;
}

.spotify-playlist-wrap {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

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

.playlist-title-main {
  font-family: var(--font-serif);
  font-size: 1.35rem;
  color: var(--white);
}

.playlist-sub-meta {
  font-size: 0.75rem;
  color: var(--muted-sage);
}

.playlist-tracks {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.track-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.45rem 0.65rem;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.04);
  font-size: 0.825rem;
  transition: background var(--transition-fast);
}

.track-row:hover {
  background: rgba(255, 255, 255, 0.08);
}

.track-title {
  color: var(--white);
  font-weight: 500;
}

.track-duration {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.5);
}

/* ==========================================================================
   Execution Plan & Governance Section
   ========================================================================== */
.execution-section {
  background: var(--white);
  border: 1px solid var(--border-stone);
  border-radius: var(--radius-lg);
  padding: 2rem 2.25rem;
  box-shadow: var(--shadow-subtle);
  margin-bottom: 2.5rem;
}

.execution-cards-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.25rem;
  margin: 1.5rem 0;
}

.artifact-card {
  background: var(--warm-ivory);
  border: 1px solid var(--border-stone);
  border-radius: var(--radius-md);
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 140px;
  transition: transform var(--transition-fast), border-color var(--transition-fast);
}

.artifact-card:hover {
  transform: translateY(-2px);
  border-color: var(--forest-green);
}

.artifact-name {
  font-family: var(--font-serif);
  font-size: 1.15rem;
  color: var(--forest-green);
  margin-bottom: 0.25rem;
}

.artifact-desc {
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* Governance & Approval Action Footer */
.governance-footer-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border-stone);
}

.governance-checklist {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  flex-wrap: wrap;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--text-secondary);
}

.gov-check-item {
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.gov-check-item span.check-icon {
  color: var(--state-completed);
  font-weight: 700;
}

.btn-approve-execute {
  background: var(--forest-green);
  color: var(--white);
  border: none;
  border-radius: var(--radius-full);
  padding: 1rem 2.25rem;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  transition: all var(--transition-normal);
  box-shadow: 0 4px 16px rgba(16, 42, 34, 0.2);
}

.btn-approve-execute:hover {
  background: var(--forest-green-hover);
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(16, 42, 34, 0.28);
}

/* ==========================================================================
   Results / Space Activated View
   ========================================================================== */
.results-activated-banner {
  background: var(--forest-green);
  color: var(--white);
  border-radius: var(--radius-lg);
  padding: 2.5rem;
  text-align: center;
  margin-bottom: 2rem;
  box-shadow: var(--shadow-card);
}

.activated-title {
  font-family: var(--font-serif);
  font-size: 2.75rem;
  color: var(--white);
  margin-bottom: 0.5rem;
}

.activated-checks {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 2rem;
  flex-wrap: wrap;
  margin-top: 1.25rem;
  font-size: 0.9rem;
  color: var(--sage-light);
}

/* ==========================================================================
   Shared Form Controls & Buttons
   ========================================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.6rem 1.25rem;
  font-size: 0.875rem;
  font-weight: 500;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  cursor: pointer;
  transition: all var(--transition-fast);
  text-decoration: none;
  line-height: 1.4;
  user-select: none;
}

.btn:focus-visible {
  outline: none;
  box-shadow: var(--focus-ring);
}

.btn:disabled, .btn[disabled] {
  opacity: 0.55;
  cursor: not-allowed;
  pointer-events: none;
}

.btn-primary {
  background: var(--forest-green);
  color: var(--white);
  border-color: var(--forest-green);
}

.btn-primary:hover {
  background: var(--forest-green-hover);
  border-color: var(--forest-green-hover);
  color: var(--white);
}

.btn-secondary {
  background: var(--white);
  border-color: var(--border-stone);
  color: var(--text-primary);
}

.btn-secondary:hover {
  background: var(--soft-cream);
  border-color: var(--warm-stone);
  color: var(--forest-green);
}

.btn-success {
  background: var(--deep-botanical);
  color: var(--white);
  border-color: var(--deep-botanical);
}

.btn-success:hover {
  background: #19382d;
  border-color: #19382d;
  color: var(--white);
}

.btn-danger {
  background: #b91c1c;
  color: var(--white);
  border-color: #b91c1c;
}

.btn-danger:hover {
  background: #991b1b;
  border-color: #991b1b;
}

.btn-terracotta {
  background: var(--terracotta);
  color: var(--white);
  border-color: var(--terracotta);
}

.btn-terracotta:hover {
  background: var(--terracotta-hover);
  border-color: var(--terracotta-hover);
}

.btn-sm {
  padding: 0.4rem 0.85rem;
  font-size: 0.8rem;
  border-radius: 6px;
}

.btn-lg {
  padding: 0.85rem 1.65rem;
  font-size: 0.95rem;
  font-weight: 600;
  border-radius: var(--radius-md);
}

/* Form Architecture */
.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  margin-bottom: 1.15rem;
}

.form-label {
  font-size: 0.825rem;
  font-weight: 600;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 0.35rem;
}

.form-input, .form-textarea, .form-select {
  width: 100%;
  padding: 0.65rem 0.9rem;
  font-size: 0.9rem;
  font-family: var(--font-sans);
  color: var(--ink);
  background: var(--white);
  border: 1px solid var(--border-stone);
  border-radius: var(--radius-sm);
  outline: none;
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.form-input:focus, .form-textarea:focus, .form-select:focus {
  border-color: var(--forest-green);
  box-shadow: 0 0 0 3px rgba(16, 42, 34, 0.08);
}

.form-textarea {
  min-height: 100px;
  resize: vertical;
  line-height: 1.5;
}

.form-grid-2 {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.25rem;
}

/* Card System */
.card {
  background: var(--white);
  border: 1px solid var(--border-stone);
  border-radius: var(--radius-md);
  padding: 1.5rem;
  box-shadow: var(--shadow-subtle);
  transition: box-shadow var(--transition-fast), border-color var(--transition-fast);
}

.card.elevated {
  box-shadow: var(--shadow-card);
}

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

.card-title {
  font-family: var(--font-heading);
  font-size: 1.2rem;
  font-weight: 500;
  color: var(--ink);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.card-subtitle {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-top: 0.2rem;
}

/* Page Header & Navigation Layout */
.page-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1.5rem;
  margin-bottom: 1.75rem;
}

.page-title-group {
  max-width: 820px;
}

.page-breadcrumbs {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.825rem;
  color: var(--text-muted);
  margin-bottom: 0.65rem;
}

.breadcrumb-separator {
  color: var(--warm-stone);
}

.page-title {
  font-family: var(--font-serif);
  font-size: 2.15rem;
  font-weight: 400;
  color: var(--forest-green);
  line-height: 1.2;
  margin-bottom: 0.45rem;
}

.page-subtitle {
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.55;
}

/* ==========================================================================
   Segmented Session Navigation Bar
   6 Destinations: Overview, Agent Activity, Blueprint, Approval Gate, Execution, Ledger
   ========================================================================== */
.session-nav-bar, .tabs-nav {
  margin-bottom: 2rem;
  width: 100%;
}

.session-tabs-container, .tabs-nav {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  background: var(--soft-cream);
  border: 1px solid var(--border-stone);
  border-radius: var(--radius-md);
  padding: 0.35rem;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: thin;
}

.session-tabs-container::-webkit-scrollbar, .tabs-nav::-webkit-scrollbar {
  height: 4px;
}

.session-tabs-container::-webkit-scrollbar-thumb, .tabs-nav::-webkit-scrollbar-thumb {
  background: var(--warm-stone);
  border-radius: 4px;
}

.session-tab-item, .tab-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.65rem 1.15rem;
  border-radius: var(--radius-sm);
  font-family: var(--font-sans);
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-secondary);
  background: transparent;
  border: none;
  cursor: pointer;
  text-decoration: none;
  white-space: nowrap;
  transition: all var(--transition-fast);
  outline: none;
}

.session-tab-item:hover, .tab-btn:hover {
  color: var(--forest-green);
  background: rgba(16, 42, 34, 0.06);
}

.session-tab-item:focus-visible, .tab-btn:focus-visible {
  box-shadow: var(--focus-ring);
}

.session-tab-item.active, .tab-btn.active {
  background: var(--forest-green) !important;
  color: var(--white) !important;
  font-weight: 600;
  box-shadow: 0 2px 8px rgba(16, 42, 34, 0.15);
}

.session-tab-icon {
  font-size: 1rem;
  line-height: 1;
}

.session-tab-label {
  letter-spacing: -0.01em;
}

/* Badges & Hash Pills */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.25rem 0.65rem;
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.hash-pill {
  font-family: var(--font-mono);
  font-size: 0.775rem;
  background: var(--soft-cream);
  color: var(--forest-green);
  padding: 0.25rem 0.55rem;
  border-radius: 6px;
  border: 1px solid var(--border-stone);
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

/* ==========================================================================
   Curatorial Certificate & Authoritative Approval Components
   ========================================================================== */
.curatorial-certificate {
  background: #FCFBF7;
  border: 2px solid var(--border-stone);
  outline: 1px dashed var(--warm-stone);
  outline-offset: -6px;
  border-radius: var(--radius-lg);
  padding: 2.25rem 2.5rem;
  position: relative;
  box-shadow: var(--shadow-card);
  margin-bottom: 2rem;
}

.curatorial-certificate::before {
  content: 'AUTHORIZED';
  position: absolute;
  top: 1.5rem;
  right: 2rem;
  font-family: var(--font-sans);
  font-size: 0.75rem;
  font-weight: 800;
  letter-spacing: 0.18em;
  color: var(--deep-botanical);
  background: rgba(36, 72, 59, 0.1);
  border: 1px solid var(--deep-botanical);
  padding: 0.35rem 0.85rem;
  border-radius: 4px;
  transform: rotate(2deg);
}

.certificate-header {
  margin-bottom: 1.75rem;
  padding-bottom: 1.25rem;
  border-bottom: 1px solid var(--border-stone);
}

.certificate-title {
  font-family: var(--font-serif);
  font-size: 1.75rem;
  color: var(--forest-green);
  margin-bottom: 0.35rem;
}

.certificate-meta-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.25rem;
  margin-bottom: 1.75rem;
}

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

.certificate-meta-label {
  font-size: 0.725rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  font-weight: 600;
}

.certificate-meta-value {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--ink);
}

.crypto-hash-box {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  background: var(--white);
  border: 1px solid var(--border-stone);
  border-radius: var(--radius-sm);
  padding: 0.6rem 0.85rem;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--text-primary);
  word-break: break-all;
}

.copy-hash-btn {
  background: var(--soft-cream);
  border: 1px solid var(--border-stone);
  color: var(--forest-green);
  border-radius: 4px;
  padding: 0.3rem 0.6rem;
  font-size: 0.725rem;
  font-weight: 600;
  cursor: pointer;
  flex-shrink: 0;
  transition: all var(--transition-fast);
}

.copy-hash-btn:hover {
  background: var(--forest-green);
  color: var(--white);
}

/* Governance Checklist Rows */
.governance-checklist {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.checklist-row {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  padding: 1rem 1.25rem;
  background: var(--white);
  border: 1px solid var(--border-stone);
  border-radius: var(--radius-md);
  transition: border-color var(--transition-fast);
}

.checklist-row.status-passed {
  border-left: 4px solid var(--deep-botanical);
}

.checklist-row.status-warning {
  border-left: 4px solid var(--amber);
}

.checklist-row.status-failed {
  border-left: 4px solid #b91c1c;
}

.checklist-status-badge {
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  font-weight: 700;
}

.checklist-status-badge.pass {
  background: rgba(36, 72, 59, 0.12);
  color: var(--deep-botanical);
}

.checklist-status-badge.warn {
  background: var(--amber-tint);
  color: var(--amber);
}

.checklist-status-badge.fail {
  background: rgba(185, 28, 28, 0.1);
  color: #b91c1c;
}

.checklist-content {
  flex: 1;
}

.checklist-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-bottom: 0.35rem;
}

.checklist-title {
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--ink);
}

.checklist-result {
  font-size: 0.85rem;
  color: var(--text-secondary);
  line-height: 1.45;
  margin-bottom: 0.4rem;
}

.checklist-matters {
  font-size: 0.775rem;
  color: var(--text-muted);
  background: var(--bg-surface-elevated);
  padding: 0.35rem 0.6rem;
  border-radius: 4px;
  display: inline-block;
}

/* ==========================================================================
   Centralized Activity Capsule & Toast Telemetry System
   Rule: Max 1 visible capsule, bottom-right, Organic Intelligence aesthetic
   ========================================================================== */
.toast-container {
  position: fixed;
  bottom: 1.75rem;
  right: 1.75rem;
  z-index: 9999;
  pointer-events: none;
  display: flex;
  justify-content: flex-end;
}

.toast-capsule {
  pointer-events: auto;
  width: 360px;
  max-width: calc(100vw - 3rem);
  background: var(--warm-ivory);
  border: 1px solid var(--border-stone);
  border-radius: 14px;
  padding: 0.85rem 1.15rem;
  box-shadow: 0 12px 32px rgba(16, 42, 34, 0.12), 0 2px 6px rgba(16, 42, 34, 0.05);
  display: flex;
  align-items: flex-start;
  gap: 0.85rem;
  transform: translateY(0);
  opacity: 1;
  transition: opacity 0.3s cubic-bezier(0.16, 1, 0.3, 1), transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.toast-capsule.entering {
  opacity: 0;
  transform: translateY(14px) scale(0.97);
}

.toast-capsule.exiting {
  opacity: 0;
  transform: translateY(10px) scale(0.97);
}

.toast-capsule-icon {
  flex-shrink: 0;
  width: 22px;
  height: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 2px;
}

.toast-capsule-icon .telemetry-spinner {
  width: 14px;
  height: 14px;
  border: 2px solid var(--border-stone);
  border-top-color: var(--forest-green);
  border-radius: 50%;
  animation: toastSpin 0.75s linear infinite;
}

@keyframes toastSpin {
  to { transform: rotate(360deg); }
}

.toast-capsule-icon .telemetry-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  display: inline-block;
}

.toast-capsule-icon .telemetry-dot.dot-success {
  background: var(--state-completed);
  box-shadow: 0 0 0 3px rgba(78, 139, 112, 0.2);
}

.toast-capsule-icon .telemetry-dot.dot-error {
  background: var(--terracotta);
  box-shadow: 0 0 0 3px rgba(201, 104, 66, 0.2);
}

.toast-capsule-icon .telemetry-dot.dot-warning {
  background: var(--state-waiting);
  box-shadow: 0 0 0 3px rgba(197, 155, 72, 0.2);
}

.toast-capsule-icon .telemetry-dot.dot-info {
  background: var(--muted-sage);
  box-shadow: 0 0 0 3px rgba(141, 152, 129, 0.2);
}

.toast-capsule-body {
  flex: 1;
  min-width: 0;
}

.toast-capsule-title {
  font-family: var(--font-sans);
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--forest-green);
  line-height: 1.3;
}

.toast-capsule-text {
  font-family: var(--font-sans);
  font-size: 0.775rem;
  color: var(--text-secondary);
  line-height: 1.4;
  margin-top: 0.2rem;
  word-break: break-word;
}

.toast-capsule-action {
  display: inline-block;
  margin-top: 0.4rem;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--terracotta);
  text-decoration: none;
  cursor: pointer;
  transition: color var(--transition-fast);
}

.toast-capsule-action:hover {
  color: var(--terracotta-hover);
  text-decoration: underline;
}

.toast-capsule-close {
  flex-shrink: 0;
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 1.1rem;
  line-height: 1;
  cursor: pointer;
  padding: 0 0.15rem;
  transition: color var(--transition-fast);
}

.toast-capsule-close:hover {
  color: var(--forest-green);
}

/* ==========================================================================
   Space Brief & Vibe Check Redesign (/spaces/new)
   Editorial layout, tactile chips, progressive disclosure
   ========================================================================== */
.space-brief-container {
  max-width: 860px;
  margin: 0 auto;
  padding-bottom: 5rem;
}

.space-brief-hero {
  margin-bottom: 2.75rem;
}

.space-brief-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--terracotta);
  margin-bottom: 0.65rem;
}

.space-brief-headline {
  font-family: var(--font-serif);
  font-size: 2.85rem;
  line-height: 1.15;
  color: var(--forest-green);
  margin-bottom: 0.75rem;
  letter-spacing: -0.015em;
}

.space-brief-subtext {
  font-size: 1.05rem;
  color: var(--text-secondary);
  max-width: 620px;
  line-height: 1.5;
}

.space-brief-card {
  background: var(--white);
  border: 1px solid var(--border-stone);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-subtle);
  padding: 2.25rem;
  margin-bottom: 2rem;
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.space-brief-card:focus-within {
  border-color: var(--muted-sage);
  box-shadow: var(--shadow-card);
}

.brief-section-header {
  margin-bottom: 1.5rem;
}

.brief-section-eyebrow {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted-sage);
  margin-bottom: 0.25rem;
}

.brief-section-title {
  font-family: var(--font-serif);
  font-size: 1.45rem;
  color: var(--forest-green);
  letter-spacing: -0.01em;
}

.brief-section-hint {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-top: 0.25rem;
}

/* Large Editorial Textarea */
.brief-textarea-large {
  width: 100%;
  min-height: 120px;
  background: var(--warm-ivory);
  border: 1px solid var(--border-stone);
  border-radius: var(--radius-md);
  padding: 1.25rem 1.35rem;
  font-family: var(--font-sans);
  font-size: 1.05rem;
  line-height: 1.6;
  color: var(--forest-green);
  resize: vertical;
  transition: border-color var(--transition-fast), background-color var(--transition-fast), box-shadow var(--transition-fast);
}

.brief-textarea-large:focus {
  outline: none;
  border-color: var(--forest-green);
  background: var(--white);
  box-shadow: var(--shadow-input);
}

.brief-textarea-large::placeholder {
  color: #9da69e;
  font-style: italic;
  font-weight: 300;
}

/* Tactile Chips & Multi-Select Tags */
.brief-chip-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
}

.brief-chip {
  appearance: none;
  border: 1px solid var(--border-stone);
  background: var(--warm-ivory);
  color: var(--forest-green);
  padding: 0.55rem 1.1rem;
  border-radius: var(--radius-full);
  font-family: var(--font-sans);
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  transition: all var(--transition-fast);
  user-select: none;
}

.brief-chip:hover {
  border-color: var(--muted-sage);
  background: var(--sage-light);
  transform: translateY(-1px);
}

.brief-chip.active {
  border-color: var(--forest-green);
  background: var(--forest-green);
  color: var(--white);
  box-shadow: 0 3px 10px rgba(16, 42, 34, 0.18);
}

.brief-chip .chip-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--muted-sage);
  transition: background-color var(--transition-fast);
}

.brief-chip.active .chip-dot {
  background: var(--soft-clay);
}

/* Compact Inputs Grid */
.brief-input-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.25rem;
}

.brief-field-group {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.brief-field-label {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-primary);
  letter-spacing: 0.02em;
}

.brief-input {
  width: 100%;
  padding: 0.75rem 1rem;
  background: var(--warm-ivory);
  border: 1px solid var(--border-stone);
  border-radius: var(--radius-sm);
  font-family: var(--font-sans);
  font-size: 0.925rem;
  color: var(--forest-green);
  transition: border-color var(--transition-fast), background-color var(--transition-fast);
}

.brief-input:focus {
  outline: none;
  border-color: var(--forest-green);
  background: var(--white);
}

.brief-input::placeholder {
  color: var(--text-muted);
}

/* Progressive Disclosure Drawer */
.brief-disclosure-btn {
  background: transparent;
  border: 1px dashed var(--border-stone);
  border-radius: var(--radius-md);
  padding: 1rem 1.5rem;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-family: var(--font-sans);
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all var(--transition-fast);
}

.brief-disclosure-btn:hover {
  border-color: var(--forest-green);
  color: var(--forest-green);
  background: rgba(16, 42, 34, 0.02);
}

.brief-disclosure-content {
  border-top: 1px solid var(--border-subtle);
  padding-top: 1.5rem;
  margin-top: 1.25rem;
}

/* Primary Action Bar */
.brief-action-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border-stone);
}

.btn-brief-primary {
  background: var(--forest-green);
  color: var(--white);
  border: 1px solid var(--forest-green);
  border-radius: var(--radius-full);
  padding: 0.85rem 2rem;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  box-shadow: 0 4px 14px rgba(16, 42, 34, 0.2);
  transition: all var(--transition-fast);
}

.btn-brief-primary:hover:not(:disabled) {
  background: var(--forest-green-hover);
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(16, 42, 34, 0.28);
}

.btn-brief-primary:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.btn-brief-secondary {
  background: transparent;
  color: var(--text-secondary);
  border: 1px solid var(--border-stone);
  border-radius: var(--radius-full);
  padding: 0.85rem 1.5rem;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.btn-brief-secondary:hover {
  border-color: var(--forest-green);
  color: var(--forest-green);
  background: var(--sage-light);
}

/* ==========================================================================
   Dedicated View Component Classes (Cultural Twin, Agents, Execution, Results)
   ========================================================================== */
.card {
  background: var(--white);
  border: 1px solid var(--border-stone);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-subtle);
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.25rem 0.65rem;
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  font-weight: 600;
  line-height: 1;
}

.status-badge.status-running {
  background: rgba(82, 120, 217, 0.12);
  color: var(--state-running);
}

.status-badge.status-completed {
  background: rgba(78, 139, 112, 0.12);
  color: var(--state-completed);
}

.status-badge.status-waiting {
  background: rgba(197, 155, 72, 0.15);
  color: var(--state-waiting);
}

.status-badge.status-error {
  background: rgba(184, 74, 58, 0.15);
  color: var(--state-error);
}

/* Cultural Twin Dedicated Screen Visualizer */
.twin-visual-container {
  width: 340px;
  height: 340px;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.twin-ring {
  position: absolute;
  border-radius: var(--radius-full);
  border: 1px dashed var(--warm-stone);
  pointer-events: none;
}

.twin-ring-3 {
  width: 320px;
  height: 320px;
  border-color: rgba(141, 152, 129, 0.4);
}

.twin-ring-2 {
  width: 240px;
  height: 240px;
  border-color: rgba(201, 104, 66, 0.35);
}

.twin-ring-1 {
  width: 160px;
  height: 160px;
  border-color: rgba(16, 42, 34, 0.25);
}

.twin-core {
  width: 110px;
  height: 110px;
  border-radius: var(--radius-full);
  background: var(--forest-green);
  color: var(--white);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 5;
  box-shadow: 0 8px 24px rgba(16, 42, 34, 0.22);
  text-align: center;
}

.twin-core-val {
  font-family: var(--font-serif);
  font-size: 2.15rem;
  line-height: 1;
}

.twin-core-lbl {
  font-size: 0.65rem;
  font-weight: 500;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--sage-light);
  margin-top: 0.2rem;
}

.twin-satellite {
  position: absolute;
  background: var(--white);
  border: 1px solid var(--border-stone);
  border-radius: var(--radius-full);
  padding: 0.4rem 0.85rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  box-shadow: var(--shadow-subtle);
  z-index: 6;
  cursor: default;
  transition: transform var(--transition-fast), border-color var(--transition-fast);
}

.twin-satellite:hover {
  transform: scale(1.08);
  border-color: var(--forest-green);
}

.twin-sat-music { top: 8px; left: 50%; transform: translateX(-50%); }
.twin-sat-books { top: 60px; right: -15px; }
.twin-sat-brands { bottom: 60px; right: -20px; }
.twin-sat-lifestyle { bottom: 8px; left: 50%; transform: translateX(-50%); }
.twin-sat-interests { top: 120px; left: -25px; }

.sat-val {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--forest-green);
  line-height: 1.1;
}

.sat-lbl {
  font-size: 0.65rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
}

/* Agents Screen Grid */
.agents-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.agent-card {
  background: var(--white);
  border: 1px solid var(--border-stone);
  border-radius: var(--radius-lg);
  padding: 1.75rem;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-subtle);
  transition: transform var(--transition-fast), border-color var(--transition-fast);
}

.agent-card:hover {
  transform: translateY(-2px);
  border-color: var(--forest-green);
  box-shadow: var(--shadow-card);
}

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

.agent-avatar {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-sm);
  background: var(--warm-ivory);
  border: 1px solid var(--border-stone);
  color: var(--forest-green);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.agent-name {
  font-family: var(--font-serif);
  font-size: 1.2rem;
  color: var(--forest-green);
  line-height: 1.2;
}

.waveform-anim {
  display: flex;
  align-items: center;
  gap: 3px;
  height: 24px;
  background: var(--warm-ivory);
  padding: 0 0.5rem;
  border-radius: var(--radius-sm);
}

/* Artifacts Grid for Execution & Results */
.artifacts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
}

.artifact-title {
  font-family: var(--font-serif);
  font-size: 1.25rem;
  color: var(--forest-green);
  margin: 0.5rem 0 0.4rem 0;
}

.artifact-meta {
  font-size: 0.825rem;
  color: var(--text-muted);
  line-height: 1.5;
}

.artifact-badge {
  font-size: 0.7rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--terracotta);
}

/* ==========================================================================
   Accessibility & Focus-Visible Styles
   ========================================================================== */
button:focus-visible,
a:focus-visible,
input:focus-visible,
[tabindex]:focus-visible {
  outline: 2px solid var(--forest-green);
  outline-offset: 3px;
}

.btn:focus-visible {
  outline: 2px solid var(--terracotta);
  outline-offset: 3px;
}

/* ==========================================================================
   Comprehensive Responsive Adaptations
   Breakpoints: 1440px | 1280px | 1024px | 768px | 390px
   ========================================================================== */
@media (max-width: 1280px) {
  .hero-headline {
    font-size: 2.5rem;
  }
  .agents-grid {
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  }
}

@media (max-width: 1024px) {
  .hero-editorial {
    grid-template-columns: 1fr;
    gap: 1.5rem;
    padding: 2rem;
  }
  .hero-image-arch {
    height: 220px;
    width: 100%;
  }
  .curation-workspace-grid {
    grid-template-columns: 1fr;
  }
  .execution-cards-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  /* Mobile Bottom Navigation Bar */
  #app-nav {
    display: block !important;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    top: auto;
    width: 100vw;
    height: 62px;
    z-index: 1000;
    background: var(--warm-ivory);
    border-top: 1px solid var(--border-stone);
    border-right: none;
    box-shadow: 0 -4px 16px rgba(24, 32, 29, 0.06);
  }

  #app-nav.hidden-nav {
    display: none !important;
  }

  .sidebar {
    width: 100%;
    height: 100%;
    flex-direction: row;
    align-items: center;
    justify-content: space-around;
    padding: 0 0.5rem;
    border-right: none;
  }

  .sidebar-brand,
  .sidebar-user {
    display: none !important;
  }

  .sidebar-nav {
    flex-direction: row;
    margin: 0;
    gap: 0.25rem;
    justify-content: space-around;
    width: 100%;
    list-style: none;
  }

  .sidebar-nav-item a {
    flex-direction: column;
    padding: 0.35rem 0.5rem;
    font-size: 0.65rem;
    gap: 0.15rem;
    border-radius: var(--radius-sm);
  }

  .sidebar-nav-item a span:last-child {
    display: none;
  }

  .nav-icon {
    width: 22px;
    height: 22px;
  }

  /* Main Wrapper padding for mobile bottom bar */
  .main-wrapper {
    margin-left: 0 !important;
    max-width: 100vw !important;
    padding: 1.25rem 1rem 80px 1rem !important;
  }

  .agents-grid {
    grid-template-columns: 1fr;
  }

  .execution-cards-grid {
    grid-template-columns: 1fr;
  }

  .governance-footer-row {
    flex-direction: column;
    align-items: stretch;
  }

  .btn-approve-execute {
    width: 100%;
    justify-content: center;
  }

  .splash-container {
    padding: 2rem 1.5rem;
  }

  .splash-title {
    font-size: 2.75rem;
  }

  .splash-botanical-corner {
    width: 260px;
    height: 240px;
    bottom: -20px;
    left: -20px;
    opacity: 0.7;
  }
}

@media (max-width: 480px) {
  /* 390x844 Mobile Viewport Scaling */
  .hero-headline {
    font-size: 2rem;
  }

  .hero-editorial {
    padding: 1.5rem;
  }

  .primary-input-card {
    padding: 1rem;
  }

  .primary-input-row {
    padding: 0.3rem 0.4rem 0.3rem 0.85rem;
  }

  .primary-text-input {
    font-size: 0.9rem;
  }

  .primary-submit-btn {
    width: 40px;
    height: 40px;
  }

  .compact-selectors {
    flex-direction: column;
    align-items: stretch;
    width: 100%;
  }

  .compact-select {
    justify-content: space-between;
  }

  .cultural-twin-container {
    transform: scale(0.85);
    margin: -1rem auto;
  }

  .twin-visual-container {
    transform: scale(0.85);
    margin: -1rem auto;
  }

  .splash-title {
    font-size: 2.25rem;
  }

  .splash-philosophy {
    font-size: 1.35rem;
  }
}

