/* ============================================================
   The Panel — Pass 1 → 5 design system
   ============================================================ */

:root {
  /* Surfaces */
  --bg-base:      #0A0B0F;
  --bg-surface-1: #121317;
  --bg-surface-2: #16181D;
  --bg-surface-3: #1B1E24;

  /* Text */
  --text-primary:   #F5F4F2;
  --text-secondary: #9B9690;
  --text-tertiary:  #6B6862;

  /* Borders */
  --border-subtle: rgba(255, 255, 255, 0.05);
  --border-medium: rgba(255, 255, 255, 0.10);
  --border-strong: rgba(255, 255, 255, 0.18);

  /* Accent — warm gold, used for Observer + important moments */
  --accent-gold:        #C8A03D;
  --accent-gold-bright: #E8D967;
  --accent-gold-deep:   #B58F2A;
  --accent-gradient:    linear-gradient(135deg, #E8D967 0%, #C8A03D 100%);
  --accent-gradient-deep: linear-gradient(135deg, #D4A82E 0%, #B58F2A 100%);
  --accent-soft-bg:     rgba(232, 217, 103, 0.08);

  /* Decision colors */
  --vote-strong-hire:    #10B981;
  --vote-hire:           #C8A03D;
  --vote-no-hire:        #6B6862;
  --vote-strong-no-hire: #C9462E;

  /* Company tints (muted, not literal brand colors) */
  --co-google:    #7396B5;
  --co-meta:      #6E73B5;
  --co-amazon:    #C28249;
  --co-apple:     #B1B2B5;
  --co-microsoft: #5E8A98;
  --co-netflix:   #8E2A3F;

  /* Type */
  --font-serif: 'Fraunces', Georgia, 'Iowan Old Style', serif;
  --font-sans:  'Inter', -apple-system, BlinkMacSystemFont, 'Helvetica Neue', sans-serif;
  --font-mono:  'JetBrains Mono', 'SF Mono', Menlo, monospace;

  /* Motion */
  --ease-entrance:   cubic-bezier(0.16, 1, 0.3, 1);
  --ease-transition: cubic-bezier(0.4, 0, 0.2, 1);
  --ease-spring:     cubic-bezier(0.34, 1.56, 0.64, 1);
  --dur-fast: 200ms;
  --dur-base: 280ms;
  --dur-slow: 400ms;

  /* Legacy mapping (a few older selectors still read these) */
  --bg: var(--bg-base);
  --panel-bg: var(--bg-surface-1);
  --ink: var(--text-primary);
  --muted: var(--text-secondary);
  --line: var(--border-medium);
  --accent: var(--accent-gold);
  --accent-soft: var(--accent-soft-bg);
  --bubble-agent: var(--bg-surface-2);
  --serif: var(--font-serif);
  --sans: var(--font-sans);
  --radius: 8px;
  --maxw: 1280px;
}

/* Deliberation darkens the base subtly */
:root.deliberation {
  --bg-base: #07080B;
}

:root[data-theme="light"] {
  --bg-base:      #F5F1EA;
  --bg-surface-1: #FFFFFF;
  --bg-surface-2: #FAF7F1;
  --bg-surface-3: #F0EBE0;

  --text-primary:   #0F0E0C;
  --text-secondary: #5C5852;
  --text-tertiary:  #8A857D;

  --border-subtle: rgba(15, 14, 12, 0.06);
  --border-medium: rgba(15, 14, 12, 0.10);
  --border-strong: rgba(15, 14, 12, 0.18);

  --accent-soft-bg: rgba(200, 160, 60, 0.10);
}
:root[data-theme="light"].deliberation {
  --bg-base: #EDE7DA;
}

/* Theme transition envelope — only applied while toggling */
:root.theme-transitioning,
:root.theme-transitioning *:not(.bubble.dots-indicator .dot):not(.watching-dot)::before,
:root.theme-transitioning *:not(.bubble.dots-indicator .dot):not(.watching-dot)::after,
:root.theme-transitioning * {
  transition: background-color 300ms var(--ease-transition),
              background 300ms var(--ease-transition),
              color 300ms var(--ease-transition),
              border-color 300ms var(--ease-transition),
              fill 300ms var(--ease-transition),
              stroke 300ms var(--ease-transition) !important;
}

/* ---------- Reset + base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html, body {
  margin: 0; padding: 0;
  min-height: 100vh; width: 100%;
  background: var(--bg-base);
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 16px; line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
button {
  font: inherit; font-family: var(--font-sans);
  cursor: pointer; color: inherit;
}
::selection { background: var(--accent-gold); color: #0A0B0F; }

h1, h2, h3, h4 {
  font-family: var(--font-serif);
  font-weight: 400;
  letter-spacing: -0.015em;
  margin: 0;
}

/* ---------- Background mesh ---------- */
body::before {
  content: "";
  position: fixed; inset: 0;
  z-index: -1;
  background:
    radial-gradient(ellipse 75% 55% at 18% 16%, rgba(200, 160, 60, 0.07) 0%, transparent 55%),
    radial-gradient(ellipse 70% 60% at 82% 82%, rgba(110, 115, 181, 0.06) 0%, transparent 55%),
    radial-gradient(ellipse 100% 80% at 50% 50%, rgba(30, 32, 42, 0.55) 0%, transparent 75%);
  pointer-events: none;
  animation: mesh-drift 32s ease-in-out infinite alternate;
  transition: background 600ms var(--ease-transition);
}
:root[data-theme="light"] body::before {
  background:
    radial-gradient(ellipse 75% 55% at 18% 16%, rgba(200, 160, 60, 0.11) 0%, transparent 55%),
    radial-gradient(ellipse 70% 60% at 82% 82%, rgba(94, 138, 152, 0.08) 0%, transparent 55%),
    radial-gradient(ellipse 100% 80% at 50% 50%, rgba(240, 235, 224, 0.5) 0%, transparent 75%);
}
:root.deliberation body::before {
  background:
    radial-gradient(ellipse 70% 50% at 25% 20%, rgba(180, 120, 50, 0.09) 0%, transparent 55%),
    radial-gradient(ellipse 65% 55% at 75% 85%, rgba(130, 70, 90, 0.06) 0%, transparent 55%),
    radial-gradient(ellipse 110% 90% at 50% 50%, rgba(22, 24, 32, 0.7) 0%, transparent 80%);
}
:root[data-theme="light"].deliberation body::before {
  background:
    radial-gradient(ellipse 70% 50% at 25% 20%, rgba(180, 120, 50, 0.14) 0%, transparent 55%),
    radial-gradient(ellipse 65% 55% at 75% 85%, rgba(130, 80, 100, 0.10) 0%, transparent 55%),
    radial-gradient(ellipse 110% 90% at 50% 50%, rgba(230, 220, 200, 0.45) 0%, transparent 80%);
}
@keyframes mesh-drift {
  from { transform: translate3d(0%, 0%, 0) rotate(0deg); }
  to   { transform: translate3d(-2%, -1.2%, 0) rotate(0.5deg); }
}

/* ============================================================
   TOP NAV
   ============================================================ */
.top-nav {
  position: fixed; top: 0; left: 0; right: 0;
  z-index: 50;
  display: flex; align-items: center; justify-content: space-between;
  padding: 1.3rem 2rem;
  pointer-events: none;
}
.top-nav > * { pointer-events: auto; }

.wordmark {
  font-family: var(--font-serif);
  font-variation-settings: 'opsz' 24;
  font-size: 1.05rem; font-weight: 400;
  letter-spacing: -0.015em;
  color: var(--text-primary);
}
.wordmark em {
  font-style: italic;
  font-weight: 300;
}

.theme-toggle {
  width: 36px; height: 36px; padding: 0;
  background: rgba(255, 255, 255, 0.025);
  border: 1px solid var(--border-subtle);
  border-radius: 999px;
  color: var(--text-secondary);
  display: inline-flex; align-items: center; justify-content: center;
  transition: border-color var(--dur-fast) var(--ease-transition),
              background var(--dur-fast) var(--ease-transition),
              color var(--dur-fast) var(--ease-transition),
              transform var(--dur-fast) var(--ease-transition);
}
:root[data-theme="light"] .theme-toggle { background: rgba(15, 14, 12, 0.035); }
.theme-toggle:hover { border-color: var(--border-medium); color: var(--text-primary); }
.theme-toggle:active { transform: scale(0.96); }
.theme-toggle svg { width: 15px; height: 15px; }

/* ============================================================
   LANDING — Pass 1
   ============================================================ */
#intro-overlay {
  position: fixed; inset: 0; z-index: 10;
  background: var(--bg-base);
  display: flex; align-items: flex-start; justify-content: center;
  overflow-y: auto;
  padding: 7.5rem 2rem 4rem;
  transition: opacity var(--dur-base) var(--ease-transition),
              transform var(--dur-base) var(--ease-transition);
}
#intro-overlay.hidden { display: none; }
#intro-overlay.fading {
  opacity: 0;
  transform: translateY(-4px) scale(0.995);
  pointer-events: none;
}

.landing-card { max-width: 880px; width: 100%; }

.landing-eyebrow {
  font-family: var(--font-mono);
  font-size: 0.72rem; font-weight: 500;
  letter-spacing: 0.20em; text-transform: uppercase;
  color: var(--text-tertiary);
  margin: 0 0 1.5rem;
  opacity: 0; transform: translateY(8px);
  animation: enter var(--dur-slow) var(--ease-entrance) 50ms forwards;
}

.hero-title {
  font-family: var(--font-serif);
  font-variation-settings: 'opsz' 144;
  font-size: clamp(4.5rem, 11vw, 8.5rem);
  font-weight: 400;
  line-height: 0.93;
  letter-spacing: -0.055em;
  color: var(--text-primary);
  margin: 0 0 1.8rem;
  opacity: 0; transform: translateY(8px);
  animation: enter var(--dur-slow) var(--ease-entrance) 100ms forwards;
}
.hero-title em { font-style: italic; font-weight: 300; }

.hero-subtitle {
  font-family: var(--font-serif);
  font-variation-settings: 'opsz' 36;
  font-style: italic; font-weight: 300;
  font-size: clamp(1.35rem, 2.4vw, 1.7rem);
  line-height: 1.32;
  color: var(--text-secondary);
  margin: 0 0 2rem;
  max-width: 38ch;
  opacity: 0; transform: translateY(8px);
  animation: enter var(--dur-slow) var(--ease-entrance) 180ms forwards;
}

.hero-description {
  font-family: var(--font-sans);
  font-size: 1.02rem; font-weight: 400;
  line-height: 1.65;
  color: var(--text-secondary);
  margin: 0 0 3.5rem;
  max-width: 58ch;
  opacity: 0; transform: translateY(8px);
  animation: enter var(--dur-slow) var(--ease-entrance) 260ms forwards;
}
.hero-description strong { color: var(--text-primary); font-weight: 500; }

.section-divider {
  height: 1px;
  background: linear-gradient(90deg, transparent 0%, var(--border-medium) 50%, transparent 100%);
  margin: 0 0 2.5rem;
  opacity: 0;
  animation: enter var(--dur-slow) var(--ease-entrance) 320ms forwards;
}

.section-label {
  font-family: var(--font-mono);
  font-size: 0.72rem; font-weight: 500;
  letter-spacing: 0.20em; text-transform: uppercase;
  color: var(--text-tertiary);
  margin: 0 0 1.25rem;
  opacity: 0; transform: translateY(8px);
  animation: enter var(--dur-slow) var(--ease-entrance) 360ms forwards;
}

.company-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.95rem;
  margin: 0 0 3rem;
}
@media (max-width: 760px) {
  .company-grid { grid-template-columns: repeat(2, 1fr); gap: 0.75rem; }
}
@media (max-width: 480px) {
  .company-grid { grid-template-columns: 1fr; }
}

.company-card {
  --card-accent: var(--text-tertiary);
  position: relative;
  display: flex; flex-direction: column;
  align-items: flex-start; text-align: left;
  padding: 1.45rem 1.4rem 1.35rem;
  background: var(--bg-surface-1);
  color: var(--text-primary);
  border: 1px solid var(--border-subtle);
  border-radius: 10px;
  overflow: hidden;
  opacity: 0; transform: translateY(8px);
  animation: enter var(--dur-slow) var(--ease-entrance) forwards;
  transition: transform   280ms var(--ease-entrance),
              border-color 280ms var(--ease-transition),
              background   280ms var(--ease-transition),
              box-shadow   280ms var(--ease-transition);
  will-change: transform;
}
.company-card:nth-of-type(1) { animation-delay: 420ms; }
.company-card:nth-of-type(2) { animation-delay: 470ms; }
.company-card:nth-of-type(3) { animation-delay: 520ms; }
.company-card:nth-of-type(4) { animation-delay: 570ms; }
.company-card:nth-of-type(5) { animation-delay: 620ms; }
.company-card:nth-of-type(6) { animation-delay: 670ms; }

.company-card::before {
  content: "";
  position: absolute; left: 0; right: 0; bottom: 0; height: 1px;
  background: var(--card-accent);
  opacity: 0;
  transition: opacity 280ms var(--ease-transition);
}
.company-card::after {
  content: "";
  position: absolute; inset: 0;
  background: radial-gradient(60% 80% at 50% 100%, var(--card-accent), transparent 60%);
  opacity: 0;
  transition: opacity 280ms var(--ease-transition);
  pointer-events: none;
  mix-blend-mode: overlay;
}

.company-card[data-company="google"]    { --card-accent: var(--co-google); }
.company-card[data-company="meta"]      { --card-accent: var(--co-meta); }
.company-card[data-company="amazon"]    { --card-accent: var(--co-amazon); }
.company-card[data-company="apple"]     { --card-accent: var(--co-apple); }
.company-card[data-company="microsoft"] { --card-accent: var(--co-microsoft); }
.company-card[data-company="netflix"]   { --card-accent: var(--co-netflix); }
.company-card[data-company="custom"]    { --card-accent: var(--vote-strong-no-hire); }

/* --- 'Other company' (custom JD) card --- */
.company-card-custom {
  /* Visually distinct from marquee solids: dashed border, no fill animation
     by default. Same hover lift + accent so it feels part of the family. */
  border: 1px dashed var(--border-strong);
  background: transparent;
}
:root[data-theme="light"] .company-card-custom { background: transparent; }
.company-card-custom .company-card-mono {
  font-family: var(--font-mono);
  font-size: 0.6rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--vote-strong-no-hire);
  margin: 0 0 0.5rem;
  opacity: 0.95;
}
.company-card-custom .company-name {
  display: inline-flex;
  align-items: baseline;
  gap: 0.45rem;
}
.company-card-custom .company-card-plus {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.4rem; height: 1.4rem;
  margin-left: 0.15rem;
  border: 1px solid var(--vote-strong-no-hire);
  border-radius: 50%;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--vote-strong-no-hire);
  background: transparent;
  line-height: 1;
  transform: translateY(-2px);
  transition: transform var(--dur-fast) var(--ease-transition),
              background var(--dur-fast) var(--ease-transition);
}
.company-card-custom:hover .company-card-plus,
.company-card-custom:focus-visible .company-card-plus {
  transform: translateY(-2px) rotate(90deg);
  background: rgba(201, 70, 46, 0.12);
}
.company-card:nth-of-type(7) { animation-delay: 720ms; }

.company-card:hover,
.company-card:focus-visible {
  transform: translateY(-2px);
  border-color: var(--card-accent);
  background: var(--bg-surface-2);
  box-shadow:
    0 1px 0 0 var(--card-accent),
    0 22px 50px -28px rgba(0, 0, 0, 0.8);
  outline: none;
}
.company-card:hover::before,
.company-card:focus-visible::before { opacity: 0.55; }
.company-card:hover::after,
.company-card:focus-visible::after  { opacity: 0.10; }

.company-card.clicking {
  transform: translateY(0) scale(0.985);
  animation: card-ring-pulse 420ms var(--ease-entrance) forwards;
}
@keyframes card-ring-pulse {
  0%   { box-shadow: 0 0 0 0px rgba(232, 217, 103, 0.55); }
  100% { box-shadow: 0 0 0 18px rgba(232, 217, 103, 0); }
}

.company-name {
  font-family: var(--font-serif);
  font-variation-settings: 'opsz' 36;
  font-size: 1.4rem; font-weight: 400;
  letter-spacing: -0.018em;
  color: var(--text-primary);
  margin: 0 0 0.5rem;
}
.company-tag {
  font-family: var(--font-mono);
  font-size: 0.7rem; font-weight: 400;
  letter-spacing: 0.04em;
  color: var(--text-tertiary);
  margin: 0;
  transition: color var(--dur-fast) var(--ease-transition);
}
.company-card:hover .company-tag,
.company-card:focus-visible .company-tag { color: var(--text-secondary); }

/* ----- Picker sections + industry cards ----- */
.picker-section {
  opacity: 0; transform: translateY(8px);
  animation: enter var(--dur-slow) var(--ease-entrance) 360ms forwards;
}
.picker-section + .picker-section {
  margin-top: 2.5rem;
}
.picker-divider {
  display: flex; align-items: center; justify-content: center;
  margin: 2.2rem 0 1.8rem;
  font-family: var(--font-mono);
  font-size: 0.66rem;
  letter-spacing: 0.20em;
  text-transform: uppercase;
  color: var(--text-tertiary);
  opacity: 0;
  animation: enter var(--dur-slow) var(--ease-entrance) 500ms forwards;
}
.picker-divider::before,
.picker-divider::after {
  content: "";
  flex: 1; height: 1px;
  background: linear-gradient(90deg, transparent, var(--border-medium), transparent);
}
.picker-divider span {
  padding: 0 0.9rem;
}

.industry-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 0.7rem;
  margin: 0 0 1.5rem;
}
@media (max-width: 840px) { .industry-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 480px) { .industry-grid { grid-template-columns: repeat(2, 1fr); } }

.industry-card {
  --card-accent: #6B8E5A;  /* muted sage — distinct from company accents */
  position: relative;
  display: flex; flex-direction: column;
  align-items: flex-start; text-align: left;
  padding: 1.1rem 1.1rem 1rem;
  background: var(--bg-surface-1);
  color: var(--text-primary);
  border: 1px solid var(--border-subtle);
  border-radius: 10px;
  overflow: hidden;
  transition: transform   240ms var(--ease-entrance),
              border-color 240ms var(--ease-transition),
              background   240ms var(--ease-transition),
              box-shadow   240ms var(--ease-transition);
}
.industry-card::before {
  content: "";
  position: absolute; left: 0; right: 0; bottom: 0; height: 1px;
  background: var(--card-accent);
  opacity: 0;
  transition: opacity 240ms var(--ease-transition);
}
.industry-card:hover,
.industry-card:focus-visible {
  transform: translateY(-2px);
  border-color: var(--card-accent);
  background: var(--bg-surface-2);
  box-shadow:
    0 1px 0 0 var(--card-accent),
    0 18px 40px -22px rgba(0, 0, 0, 0.75);
  outline: none;
}
.industry-card:hover::before,
.industry-card:focus-visible::before { opacity: 0.55; }

.industry-name {
  font-family: var(--font-serif);
  font-variation-settings: 'opsz' 36;
  font-size: 1.15rem; font-weight: 400;
  letter-spacing: -0.015em;
  color: var(--text-primary);
  margin: 0 0 0.4rem;
}
.industry-tag {
  font-family: var(--font-mono);
  font-size: 0.66rem; font-weight: 400;
  letter-spacing: 0.04em;
  color: var(--text-tertiary);
  margin: 0;
  transition: color var(--dur-fast) var(--ease-transition);
}
.industry-card:hover .industry-tag { color: var(--text-secondary); }

/* ----- Landing new-grad banner ----- */
.landing-banner {
  border-left: 2px solid var(--accent-gold);
  background: var(--accent-soft-bg);
  padding: 0.9rem 1.2rem;
  margin: 0 0 2.2rem;
  border-radius: 0 6px 6px 0;
  opacity: 0; transform: translateY(8px);
  animation: enter var(--dur-slow) var(--ease-entrance) 320ms forwards;
}
.landing-banner-text {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 300;
  font-size: 0.95rem;
  line-height: 1.55;
  color: var(--text-secondary);
  margin: 0 !important;
}

/* ----- Role-pick modal (replaces industry-pick) ----- */
.role-pick-card { max-width: 620px; }
.role-pick-title {
  font-family: var(--font-serif);
  font-size: 1.5rem;
  margin: 0 0 1rem !important;
}

.netflix-warning {
  border-left: 2px solid var(--vote-strong-no-hire);
  background: rgba(201, 70, 46, 0.06);
  padding: 0.85rem 1.1rem;
  margin: 0 0 1.4rem;
  border-radius: 0 6px 6px 0;
}
.netflix-warning-text {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 300;
  font-size: 0.92rem;
  line-height: 1.55;
  color: var(--text-primary);
  margin: 0 !important;
}

.industry-company-input { margin: 0 0 1.4rem; }
.company-input-label {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.66rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-tertiary);
  margin: 0 0 0.45rem;
}
.optional-tag {
  font-weight: 400;
  text-transform: lowercase;
  letter-spacing: 0.04em;
  color: var(--text-tertiary);
  opacity: 0.75;
}
.industry-company-input input,
.role-custom-wrap input {
  width: 100%;
  padding: 0.75rem 0.95rem;
  background: var(--bg-surface-1);
  border: 1px solid var(--border-medium);
  border-radius: 8px;
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 0.95rem;
  transition: border-color var(--dur-fast) var(--ease-transition),
              box-shadow var(--dur-fast) var(--ease-transition);
}
.industry-company-input input:focus,
.role-custom-wrap input:focus {
  outline: none;
  border-color: var(--accent-gold);
  box-shadow: 0 0 0 3px rgba(232, 217, 103, 0.16);
}
.industry-company-input input::placeholder,
.role-custom-wrap input::placeholder {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 300;
  color: var(--text-tertiary);
}
:root[data-theme="light"] .industry-company-input input:focus,
:root[data-theme="light"] .role-custom-wrap input:focus {
  box-shadow: 0 0 0 3px rgba(200, 160, 60, 0.20);
}

.role-grid-label {
  font-family: var(--font-mono);
  font-size: 0.66rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-tertiary);
  margin: 0 0 0.8rem !important;
}

.role-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.55rem;
  margin: 0 0 1.4rem;
}
@media (max-width: 600px) {
  .role-grid { grid-template-columns: repeat(2, 1fr); }
}
.role-card {
  padding: 0.85rem 0.95rem;
  background: var(--bg-surface-1);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  color: var(--text-primary);
  text-align: left;
  font-family: var(--font-serif);
  font-variation-settings: 'opsz' 24;
  font-size: 0.92rem;
  line-height: 1.32;
  letter-spacing: -0.01em;
  cursor: pointer;
  transition: border-color 200ms var(--ease-transition),
              background 200ms var(--ease-transition),
              transform 200ms var(--ease-entrance);
}
.role-card:hover {
  border-color: var(--accent-gold);
  background: var(--bg-surface-2);
  transform: translateY(-1px);
}
.role-card.custom {
  font-style: italic;
  color: var(--text-secondary);
}
.role-card.custom:hover {
  color: var(--text-primary);
  border-color: var(--text-secondary);
  background: var(--bg-surface-2);
}

.role-custom-wrap {
  margin: 0 0 1.2rem;
  padding: 1rem 1.1rem;
  background: var(--bg-surface-2);
  border: 1px solid var(--border-medium);
  border-radius: 8px;
}
.role-custom-wrap input { margin-bottom: 0.8rem; }
.role-custom-wrap .primary-cta {
  display: inline-flex; align-items: center;
  height: 42px; padding: 0 1.4rem;
  font-size: 0.92rem;
}

#role-pick-cancel { margin-top: 0.5rem; }

/* ----- Resume upload screen (Step 3 of 3) ----- */
.resume-upload-card { max-width: 720px; }
.resume-upload-title {
  font-family: var(--font-serif);
  font-size: 1.75rem;
  margin: 0 0 0.8rem !important;
}
.resume-upload-subtitle {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 300;
  font-size: 1.05rem;
  line-height: 1.5;
  color: var(--text-secondary);
  margin: 0 0 1.6rem !important;
}

.resume-drop-zone {
  display: flex; align-items: center; justify-content: center;
  width: 100%;
  min-height: 220px;
  margin: 0 0 1rem;
  padding: 1.8rem;
  border: 2px dashed var(--border-medium);
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.015);
  cursor: pointer;
  transition: border-color 200ms var(--ease-transition),
              border-style 200ms var(--ease-transition),
              background 200ms var(--ease-transition);
}
.resume-drop-zone:hover,
.resume-drop-zone.drag-over,
.resume-drop-zone:focus-visible {
  border-color: var(--accent-gold);
  border-style: solid;
  background: var(--accent-soft-bg);
  outline: none;
}
:root[data-theme="light"] .resume-drop-zone {
  background: rgba(15, 14, 12, 0.02);
}

.resume-drop-content {
  text-align: center;
  width: 100%;
}
.resume-drop-icon {
  width: 36px; height: 36px;
  color: var(--text-tertiary);
  margin: 0 auto 0.8rem;
  display: block;
}
.resume-drop-text {
  font-family: var(--font-serif);
  font-size: 1.05rem;
  color: var(--text-primary);
  margin: 0 0 0.4rem !important;
}
.resume-drop-subtext {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.06em;
  color: var(--text-tertiary);
  margin: 0 !important;
}

.resume-selected {
  text-align: center;
}
.resume-selected-filename {
  font-family: var(--font-serif);
  font-size: 1.08rem;
  color: var(--text-primary);
  margin: 0 0 0.3rem !important;
  word-break: break-all;
}
.resume-selected-size {
  font-family: var(--font-mono);
  font-size: 0.74rem;
  letter-spacing: 0.04em;
  color: var(--text-tertiary);
  margin: 0 0 0.8rem !important;
}
.resume-remove {
  background: transparent;
  border: none;
  color: var(--text-tertiary);
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  cursor: pointer;
  padding: 0.3rem 0.6rem;
  border-radius: 4px;
  transition: color 180ms var(--ease-transition);
}
.resume-remove:hover { color: var(--vote-strong-no-hire); }

.resume-loading {
  text-align: center;
}
.resume-loading .resume-drop-text {
  font-style: italic;
  color: var(--text-secondary);
}
.resume-loading .resume-drop-text::after {
  content: ""; display: inline-block; width: 0.4em;
  animation: ellipsis 1.2s steps(4) infinite;
}

.resume-meta {
  font-family: var(--font-mono);
  font-size: 0.66rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-tertiary);
  margin: 0 0 1.1rem !important;
  text-align: center;
}

.resume-privacy {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 300;
  font-size: 0.86rem;
  line-height: 1.55;
  color: var(--text-tertiary);
  margin: 0 auto 1.4rem !important;
  max-width: 560px;
  text-align: center;
}

.resume-error {
  color: var(--vote-strong-no-hire);
  font-size: 0.88rem;
  margin: 0 0 1rem !important;
  text-align: center;
}

.resume-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}
.ghost-cta {
  background: transparent;
  border: none;
  color: var(--text-tertiary);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  cursor: pointer;
  padding: 0.55rem 0.85rem;
  border-radius: 4px;
  transition: color 180ms var(--ease-transition);
}
.ghost-cta:hover:not(:disabled) { color: var(--text-primary); }
.ghost-cta:disabled { opacity: 0.4; cursor: not-allowed; }

.resume-actions .primary-cta:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  background: var(--bg-surface-3);
  color: var(--text-tertiary);
}

/* ============================================================
   CUSTOM SETUP — paste a JD for non-marquee company
   ============================================================ */
.custom-setup-card {
  max-width: 720px;
  max-height: 92vh;
  overflow-y: auto;
}
.custom-setup-title {
  font-family: var(--font-serif);
  font-variation-settings: 'opsz' 72;
  font-size: clamp(1.7rem, 4vw, 2.3rem);
  font-weight: 400;
  letter-spacing: -0.02em;
  margin: 0 0 0.6rem !important;
  line-height: 1.1;
}
.custom-setup-subtitle {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 300;
  font-size: 1.15rem;
  line-height: 1.5;
  color: var(--text-secondary);
  margin: 0 0 1.8rem !important;
}
.custom-setup-form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}
.custom-field {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}
.custom-field-label {
  font-family: var(--font-mono);
  font-size: 0.66rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-tertiary);
}
.custom-field input[type="text"],
.custom-field select,
.custom-field textarea {
  width: 100%;
  background: var(--bg-surface-2);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  color: var(--text-primary);
  padding: 0.7rem 0.85rem;
  font-family: var(--font-sans);
  font-size: 0.95rem;
  transition: border-color var(--dur-fast) var(--ease-transition),
              background var(--dur-fast) var(--ease-transition);
}
.custom-field input[type="text"]:focus,
.custom-field select:focus,
.custom-field textarea:focus {
  outline: none;
  border-color: var(--accent-gold);
  background: var(--bg-surface-3);
}
.custom-field select {
  appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, var(--text-tertiary) 50%),
                    linear-gradient(135deg, var(--text-tertiary) 50%, transparent 50%);
  background-position: calc(100% - 18px) 50%, calc(100% - 13px) 50%;
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
  padding-right: 2rem;
  cursor: pointer;
}
.custom-field-help {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 0.82rem;
  color: var(--text-tertiary);
  line-height: 1.4;
}
.custom-field-jd textarea {
  min-height: 320px;
  font-family: var(--font-mono);
  font-size: 0.84rem;
  line-height: 1.55;
  resize: vertical;
}
.custom-jd-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
  margin-top: 0.2rem;
}
.custom-jd-warning {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.04em;
  color: var(--accent-gold);
  flex: 1 1 auto;
}
.custom-jd-warning[hidden] { display: none; }
.custom-jd-counter {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.04em;
  color: var(--text-tertiary);
  flex-shrink: 0;
}
.custom-jd-counter.over {
  color: var(--vote-strong-no-hire);
}

.custom-setup-privacy {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 300;
  font-size: 0.82rem;
  line-height: 1.55;
  color: var(--text-tertiary);
  margin: 0.6rem auto 0.5rem !important;
  max-width: 600px;
  text-align: center;
}
.custom-setup-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
  margin-top: 0.4rem;
}
.custom-setup-actions .primary-cta {
  display: inline-flex; align-items: center; gap: 0.55rem;
}
.custom-setup-actions .primary-cta:disabled {
  opacity: 0.4;
  cursor: not-allowed;
  background: var(--bg-surface-3);
  color: var(--text-tertiary);
  border-color: var(--border-subtle);
}
.custom-setup-actions .primary-cta .cta-arrow {
  display: inline-block;
  transition: transform var(--dur-fast) var(--ease-transition);
}
.custom-setup-actions .primary-cta:hover:not(:disabled) .cta-arrow {
  transform: translateX(3px);
}

.custom-setup-loading {
  display: flex !important;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  margin: 0.6rem 0 0 !important;
  font-family: var(--font-mono);
  font-size: 0.74rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent-gold);
}
.custom-setup-loading[hidden] { display: none !important; }
.custom-setup-loading-dots {
  display: inline-flex;
  gap: 0.32rem;
}
.custom-setup-loading-dots > span {
  width: 6px; height: 6px;
  background: var(--accent-gold);
  border-radius: 50%;
  display: inline-block;
  animation: input-thinking-pulse 1.2s ease-in-out infinite both;
}
.custom-setup-loading-dots > span:nth-child(2) { animation-delay: 0.15s; }
.custom-setup-loading-dots > span:nth-child(3) { animation-delay: 0.30s; }

/* ----- Dossier "FROM RESUME" section ----- */
.dossier-resume-section {
  background: var(--bg-surface-2);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  padding: 0.85rem 1rem;
  margin: 0 0 1.4rem;
  animation: enter var(--dur-base) var(--ease-entrance) both;
}
.dossier-resume-section[hidden] { display: none; }
.dossier-resume-label {
  font-family: var(--font-mono);
  font-size: 0.66rem;
  font-weight: 500;
  letter-spacing: 0.20em;
  text-transform: uppercase;
  color: var(--accent-gold);
  margin: 0 0 0.7rem;
}
.dossier-resume-fact {
  font-size: 0.84rem;
  line-height: 1.45;
  color: var(--text-secondary);
  margin: 0 0 0.32rem;
  display: flex;
  align-items: baseline;
  gap: 0.55rem;
}
.dossier-resume-fact:last-child { margin-bottom: 0; }
.dossier-resume-fact strong { color: var(--text-primary); font-weight: 500; }
.dossier-resume-key {
  font-family: var(--font-mono);
  font-size: 0.60rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-tertiary);
  flex-shrink: 0;
  min-width: 36px;
}
.dossier-resume-empty {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 300;
  font-size: 0.88rem;
  line-height: 1.45;
  color: var(--text-tertiary);
  margin: 0;
}

.bottom-link {
  font-family: var(--font-mono);
  font-size: 0.78rem; font-weight: 400;
  letter-spacing: 0.02em;
  color: var(--text-tertiary);
  text-decoration: none;
  display: inline-flex; align-items: center; gap: 0.4rem;
  margin-top: 2.5rem;
  opacity: 0; transform: translateY(8px);
  animation: enter var(--dur-slow) var(--ease-entrance) 760ms forwards;
  transition: color var(--dur-fast) var(--ease-transition);
}
.bottom-link:hover { color: var(--text-secondary); }
.bottom-link .arrow { display: inline-block; transition: transform var(--dur-fast) var(--ease-transition); }
.bottom-link:hover .arrow { transform: translateX(3px); }

@keyframes enter {
  to { opacity: 1; transform: none; }
}

/* ============================================================
   APP / CHAT — Pass 2
   ============================================================ */
#app {
  display: flex; flex-direction: column;
  min-height: 100vh; max-width: var(--maxw);
  margin: 0 auto;
}

#app > header {
  display: flex; align-items: flex-start; justify-content: flex-end;
  padding: 5.5rem 2.5rem 1.5rem;
  border-bottom: 1px solid var(--border-subtle);
  min-height: 6.5rem;
}

#round-indicator {
  display: flex; flex-direction: column;
  align-items: flex-end;
  gap: 0.2rem; text-align: right;
  overflow: hidden;
}
#round-indicator:empty { display: none; }
.round-tag {
  font-family: var(--font-mono);
  font-size: 0.68rem; font-weight: 500;
  letter-spacing: 0.20em; text-transform: uppercase;
  color: var(--text-tertiary);
  animation: enter var(--dur-base) var(--ease-entrance) both;
}
.round-role {
  font-family: var(--font-serif);
  font-variation-settings: 'opsz' 24;
  font-size: 1.15rem; font-weight: 400;
  letter-spacing: -0.015em;
  color: var(--text-primary);
  animation: enter var(--dur-base) var(--ease-entrance) 60ms both;
}
.round-role em { font-style: italic; font-weight: 300; }

main {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(340px, 35%);
  flex: 1; min-height: 0;
}

#right-column {
  display: flex;
  flex-direction: column;
  min-height: 0;
  border-left: 1px solid var(--border-subtle);
}

#chat-area {
  display: flex; flex-direction: column; min-height: 0;
  padding: 2rem 2.5rem 1.75rem;
  border-right: 1px solid var(--border-subtle);
  position: relative;
}

/* ============================================================
   Toast / inline error banner — editorial, no native alerts
   ============================================================ */
.toast-region {
  position: absolute;
  top: 0.6rem; left: 1rem; right: 1rem;
  display: flex; flex-direction: column;
  gap: 0.5rem;
  pointer-events: none;
  z-index: 50;
}
.toast {
  pointer-events: auto;
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 0.8rem;
  padding: 0.85rem 1rem 0.85rem 1.1rem;
  background: var(--bg-surface-2);
  border: 1px solid var(--border-subtle);
  border-left: 3px solid var(--vote-strong-no-hire);  /* terracotta */
  border-radius: 6px;
  box-shadow: 0 12px 32px -16px rgba(0, 0, 0, 0.45);
  animation: toast-in 220ms var(--ease-entrance) both;
  cursor: pointer;
}
.toast.exiting { animation: toast-out 180ms var(--ease-transition) forwards; }
.toast-body { min-width: 0; }
.toast-label {
  display: block;
  font-family: var(--font-mono);
  font-size: 0.66rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--vote-strong-no-hire);
  margin: 0 0 0.2rem;
}
.toast-message {
  margin: 0;
  font-family: var(--font-sans);
  font-size: 0.92rem;
  line-height: 1.45;
  color: var(--text-primary);
  word-break: break-word;
}
.toast-action {
  background: transparent;
  border: 1px solid var(--border-medium);
  color: var(--text-primary);
  padding: 0.4rem 0.85rem;
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  cursor: pointer;
  transition: border-color var(--dur-fast) var(--ease-transition),
              background var(--dur-fast) var(--ease-transition);
}
.toast-action:hover {
  border-color: var(--border-strong);
  background: rgba(255, 255, 255, 0.04);
}
:root[data-theme="light"] .toast-action:hover { background: rgba(15, 14, 12, 0.04); }
@keyframes toast-in  {
  from { opacity: 0; transform: translateY(-8px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes toast-out {
  to { opacity: 0; transform: translateY(-6px); }
}

/* ============================================================
   Inline 'Agent is thinking…' indicator (below the input)
   ============================================================ */
.input-thinking {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin: 0.55rem 0 0 0.2rem;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-tertiary);
}
.input-thinking[hidden] { display: none; }
.input-thinking-dot {
  width: 5px; height: 5px;
  background: var(--accent-gold);
  border-radius: 50%;
  display: inline-block;
  animation: input-thinking-pulse 1.2s ease-in-out infinite both;
}
.input-thinking-dot:nth-child(2) { animation-delay: 0.15s; }
.input-thinking-dot:nth-child(3) { animation-delay: 0.30s; }
.input-thinking-label { margin-left: 0.25rem; }
@keyframes input-thinking-pulse {
  0%, 80%, 100% { transform: scale(0.6); opacity: 0.35; }
  40%           { transform: scale(1);   opacity: 1; }
}
#messages {
  flex: 1; min-height: 0; overflow-y: auto;
  padding-right: 0.5rem;
  display: flex; flex-direction: column; gap: 1.3rem;
  scroll-behavior: smooth;
  overscroll-behavior: contain;
}
#messages::-webkit-scrollbar { width: 8px; }
#messages::-webkit-scrollbar-track { background: transparent; }
#messages::-webkit-scrollbar-thumb { background: var(--border-subtle); border-radius: 4px; }
#messages::-webkit-scrollbar-thumb:hover { background: var(--border-medium); }

.message {
  display: flex; flex-direction: column;
  max-width: 76%;
  animation: msg-enter 320ms var(--ease-entrance) both;
  transform-origin: bottom left;
  transition: opacity var(--dur-slow) var(--ease-transition);
}
@keyframes msg-enter {
  from { opacity: 0; transform: translateY(4px) scale(0.96); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}
.message.from-agent { align-self: flex-start; }
.message.from-user  {
  align-self: flex-end;
  align-items: flex-end;
  transform-origin: bottom right;
}

.message.from-agent .who {
  font-family: var(--font-mono);
  font-size: 0.68rem; font-weight: 500;
  letter-spacing: 0.20em; text-transform: uppercase;
  color: var(--accent-gold);
  margin: 0 0 0.5rem 0.05rem;
}
.message.from-user .who { display: none; }

.message .bubble {
  padding: 0.95rem 1.15rem;
  border-radius: 14px;
  background: var(--bg-surface-1);
  color: var(--text-primary);
  white-space: pre-wrap; word-wrap: break-word;
  line-height: 1.6;
  border: 1px solid var(--border-subtle);
  font-size: 0.985rem;
}
.message.from-user .bubble {
  background: var(--bg-surface-3);
  border-color: var(--border-medium);
}
:root[data-theme="light"] .message.from-user .bubble {
  background: var(--accent-gold-deep);
  color: #0A0B0F;
  border-color: transparent;
  font-weight: 450;
}

.message.thinking .bubble { background: var(--bg-surface-1); }
.thinking-context {
  font-family: var(--font-mono);
  font-size: 0.66rem;
  letter-spacing: 0.10em;
  color: var(--text-tertiary);
  margin: 0.55rem 0 0 0.05rem;
  transition: opacity var(--dur-fast) var(--ease-transition);
}

/* 3-dot indicator */
.bubble.dots-indicator {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 0.9rem 1.1rem;
}
.bubble.dots-indicator .dot {
  width: 6px; height: 6px;
  background: var(--accent-gold);
  border-radius: 50%;
  opacity: 0.35;
  animation: dot-bounce 1.4s ease-in-out infinite both;
}
.bubble.dots-indicator .dot:nth-child(1) { animation-delay: 0ms; }
.bubble.dots-indicator .dot:nth-child(2) { animation-delay: 200ms; }
.bubble.dots-indicator .dot:nth-child(3) { animation-delay: 400ms; }
@keyframes dot-bounce {
  0%, 60%, 100% { opacity: 0.35; transform: translateY(0) scale(1); }
  30% { opacity: 1; transform: translateY(-2px) scale(1.15); }
}
.bubble.dots-indicator.patient .dot { background: var(--accent-gold-deep); }

/* ----- Input area — glass touch ----- */
#answer-form[hidden] { display: none; }
#answer-form {
  display: flex; align-items: flex-end;
  gap: 0.6rem;
  margin-top: 1.5rem;
  padding: 0.55rem 0.55rem 0.55rem 1.1rem;
  background: rgba(255, 255, 255, 0.025);
  border: 1px solid var(--border-subtle);
  border-radius: 16px;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow:
    inset 0 1px 0 0 rgba(255, 255, 255, 0.04),
    0 1px 2px 0 rgba(0, 0, 0, 0.25);
  transition: border-color var(--dur-fast) var(--ease-transition),
              background var(--dur-fast) var(--ease-transition),
              box-shadow var(--dur-fast) var(--ease-transition);
}
#answer-form:focus-within {
  border-color: var(--border-medium);
  background: rgba(255, 255, 255, 0.04);
  box-shadow:
    inset 0 1px 0 0 rgba(255, 255, 255, 0.06),
    0 0 0 3px rgba(232, 217, 103, 0.10);
}
:root[data-theme="light"] #answer-form {
  background: rgba(255, 255, 255, 0.55);
  box-shadow:
    inset 0 1px 0 0 rgba(255, 255, 255, 0.6),
    0 1px 2px 0 rgba(15, 14, 12, 0.06);
}
:root[data-theme="light"] #answer-form:focus-within {
  background: rgba(255, 255, 255, 0.85);
  border-color: var(--border-strong);
  box-shadow:
    inset 0 1px 0 0 rgba(255, 255, 255, 0.7),
    0 0 0 3px rgba(200, 160, 60, 0.18);
}

#answer-input {
  flex: 1; resize: none;
  font: inherit;
  font-family: var(--font-sans);
  font-size: 0.98rem;
  line-height: 1.55;
  padding: 0.55rem 0;
  border: none; outline: none;
  background: transparent;
  color: var(--text-primary);
  min-height: 1.55rem; max-height: 9rem;
}
#answer-input::placeholder {
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 300;
  color: var(--text-tertiary);
  opacity: 0.85;
}

#send-btn {
  flex-shrink: 0;
  width: 38px; height: 38px; padding: 0;
  background: var(--bg-surface-3);
  color: var(--text-primary);
  border: 1px solid var(--border-medium);
  border-radius: 999px;
  display: inline-flex; align-items: center; justify-content: center;
  transition: background var(--dur-fast) var(--ease-transition),
              border-color var(--dur-fast) var(--ease-transition),
              color var(--dur-fast) var(--ease-transition),
              transform var(--dur-fast) var(--ease-transition),
              opacity var(--dur-fast) var(--ease-transition);
}
#send-btn svg { width: 16px; height: 16px; }
#send-btn:hover:not(:disabled) {
  background: var(--accent-gradient);
  border-color: var(--accent-gold);
  color: #0A0B0F;
}
#send-btn:active:not(:disabled) { transform: scale(0.95); }
#send-btn:disabled { opacity: 0.35; cursor: not-allowed; }

/* ============================================================
   DOSSIER PANEL — Pass 2
   ============================================================ */
#dossier-panel {
  background: var(--bg-surface-1);
  padding: 2rem 1.75rem 2rem;
  overflow-y: auto; min-width: 0;
  overscroll-behavior: contain;
}
#dossier-panel::-webkit-scrollbar { width: 6px; }
#dossier-panel::-webkit-scrollbar-thumb { background: var(--border-subtle); border-radius: 3px; }

.dossier-header {
  margin-bottom: 1.75rem;
  padding-bottom: 1.1rem;
  border-bottom: 1px solid var(--border-subtle);
}
.dossier-title {
  font-family: var(--font-serif);
  font-variation-settings: 'opsz' 36;
  font-size: 1.35rem; font-weight: 400;
  letter-spacing: -0.015em;
  color: var(--text-primary);
  margin: 0 0 0.55rem;
}
.dossier-title em { font-style: italic; font-weight: 300; }

.watching-indicator {
  display: inline-flex; align-items: center;
  gap: 0.55rem;
}
.watching-dot {
  position: relative;
  width: 7px; height: 7px;
  background: var(--accent-gold);
  border-radius: 50%;
  box-shadow: 0 0 10px 0 rgba(232, 217, 103, 0.5);
  flex-shrink: 0;
}
.watching-dot::after {
  content: "";
  position: absolute; inset: -3px;
  border-radius: 50%;
  border: 1px solid var(--accent-gold-bright);
  animation: watch-ring 2.2s cubic-bezier(0.16, 1, 0.3, 1) infinite;
  pointer-events: none;
}
@keyframes watch-ring {
  0%   { transform: scale(0.7); opacity: 0.85; }
  100% { transform: scale(3.2); opacity: 0; }
}
.watching-label {
  font-family: var(--font-mono);
  font-size: 0.68rem; font-weight: 500;
  letter-spacing: 0.22em; text-transform: uppercase;
  color: var(--accent-gold);
  opacity: 0.9;
}

/* ----- Summary strip ----- */
.dossier-summary {
  font-family: var(--font-mono);
  font-size: 0.66rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-tertiary);
  margin: 0 0 1.4rem;
  line-height: 1.5;
  display: flex; flex-wrap: wrap;
  gap: 0.4rem 0.5rem;
}
.dossier-summary[hidden] { display: none; }
.dossier-summary strong {
  color: var(--accent-gold);
  font-weight: 500;
  margin-right: 0.25rem;
}
.dossier-summary .sep {
  color: var(--text-tertiary);
  opacity: 0.5;
}

/* ----- Sections (accordion) ----- */
.dossier-section {
  display: grid;
  grid-template-rows: auto 0fr;
  transition: grid-template-rows 240ms cubic-bezier(0.16, 1, 0.3, 1);
  border-top: 1px solid var(--border-subtle);
  animation: enter var(--dur-base) var(--ease-entrance) both;
}
.dossier-section[data-expanded="true"] {
  grid-template-rows: auto 1fr;
}
.dossier-section:last-of-type {
  border-bottom: 1px solid var(--border-subtle);
}

.dossier-section-header {
  display: flex; align-items: center;
  gap: 0.55rem;
  width: 100%;
  padding: 0.75rem 0;
  background: transparent;
  border: none;
  text-align: left;
  cursor: pointer;
  position: relative;
  transition: background var(--dur-fast) var(--ease-transition);
}
.dossier-section-header:hover {
  background: rgba(255, 255, 255, 0.015);
}
:root[data-theme="light"] .dossier-section-header:hover {
  background: rgba(15, 14, 12, 0.02);
}
.dossier-section-header.pulse {
  animation: dossier-header-pulse 1200ms ease-out;
}
@keyframes dossier-header-pulse {
  0%   { background: transparent; }
  18%  { background: rgba(232, 217, 103, 0.14); }
  100% { background: transparent; }
}

.dossier-icon {
  display: inline-flex; align-items: center; justify-content: center;
  width: 14px; height: 14px;
  color: var(--text-tertiary);
  flex-shrink: 0;
}
.dossier-icon svg { width: 14px; height: 14px; }
.dossier-section h3 {
  font-family: var(--font-mono);
  font-size: 0.68rem; font-weight: 500;
  letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--text-tertiary);
  margin: 0; flex: 1;
  transition: color var(--dur-fast) var(--ease-transition);
}
.dossier-section[data-expanded="true"] h3 {
  color: var(--text-secondary);
}
.dossier-count {
  font-family: var(--font-mono);
  font-size: 0.66rem;
  color: var(--text-tertiary);
  opacity: 0.75;
  padding: 0.05rem 0.45rem;
  border: 1px solid var(--border-subtle);
  border-radius: 999px;
  transition: color 600ms var(--ease-transition),
              border-color 600ms var(--ease-transition),
              opacity 600ms var(--ease-transition);
}
.dossier-count.fresh-count {
  color: var(--accent-gold);
  border-color: var(--accent-gold);
  opacity: 1;
}
.dossier-chevron {
  display: inline-flex; align-items: center; justify-content: center;
  width: 14px; height: 14px;
  color: var(--text-tertiary);
  font-family: var(--font-mono);
  font-size: 0.95rem;
  line-height: 1;
  transition: transform 240ms var(--ease-entrance);
}
.dossier-section[data-expanded="true"] .dossier-chevron {
  transform: rotate(90deg);
}

.dossier-section-body {
  overflow: hidden;
  min-height: 0;
}
.dossier-section-body-inner {
  padding: 0.2rem 0 0.85rem;
}

.dossier-list { margin: 0; padding: 0; list-style: none; }
.dossier-list li {
  position: relative;
  font-size: 14px;
  line-height: 1.4;
  color: var(--text-primary);
  padding: 0.32rem 0.55rem 0.32rem 0.95rem;
  margin: 0 -0.55rem;
  border-radius: 5px;
}
:root[data-theme="light"] .dossier-list li {
  font-size: 13.5px;
}
.dossier-list li::before {
  content: "";
  position: absolute;
  left: 0.55rem; top: 0.72rem;
  width: 3px; height: 3px;
  border-radius: 50%;
  background: var(--text-tertiary);
}

/* Arrival animation (1.8s) + lingering border (10s) combined into one 12s keyframe */
.dossier-list li.fresh {
  animation: dossier-item-arrival 12s var(--ease-transition) both;
}
@keyframes dossier-item-arrival {
  0% {
    opacity: 0;
    transform: translateX(-4px);
    background: rgba(232, 217, 103, 0.16);
    box-shadow: inset 2px 0 0 0 var(--accent-gold);
  }
  5% {
    opacity: 1; transform: none;
    background: rgba(232, 217, 103, 0.16);
    box-shadow: inset 2px 0 0 0 var(--accent-gold);
  }
  15% {
    background: transparent;
    box-shadow: inset 1px 0 0 0 var(--accent-gold);
  }
  88% {
    box-shadow: inset 1px 0 0 0 var(--accent-gold);
  }
  100% {
    box-shadow: inset 0 0 0 0 transparent;
  }
}

.dossier-more {
  margin: 0.3rem -0.55rem 0;
  padding: 0.35rem 0.55rem;
  background: transparent;
  border: none;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.04em;
  color: var(--text-tertiary);
  text-align: left;
  cursor: pointer;
  border-radius: 4px;
  transition: color var(--dur-fast) var(--ease-transition),
              background var(--dur-fast) var(--ease-transition);
}
.dossier-more:hover {
  color: var(--text-secondary);
  background: rgba(255, 255, 255, 0.02);
}

.dossier-section[data-section="probes"] .dossier-icon,
.dossier-section[data-section="probes"] h3 { color: var(--accent-gold); }
.dossier-section[data-section="probes"] .dossier-list li {
  font-style: italic; color: var(--text-secondary);
}
.dossier-section[data-section="probes"] .dossier-list li::before {
  background: var(--accent-gold); opacity: 0.7;
}

.empty {
  color: var(--text-tertiary);
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 0.95rem;
  margin: 0;
}

/* ============================================================
   OVERLAYS (shared) — Pass 3 refines handoff specifically
   ============================================================ */
.overlay {
  position: fixed; inset: 0;
  background: rgba(8, 9, 12, 0.65);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  display: flex; align-items: center; justify-content: center;
  z-index: 100; padding: 2rem;
  animation: backdrop-in var(--dur-base) var(--ease-entrance) both;
}
:root[data-theme="light"] .overlay {
  background: rgba(240, 235, 224, 0.72);
}
@keyframes backdrop-in {
  from { opacity: 0; }
  to   { opacity: 1; }
}
.overlay.hidden { display: none; }
.overlay .card {
  background: var(--bg-surface-2);
  border: 1px solid var(--border-medium);
  max-width: 620px; width: 100%;
  padding: 2.5rem 2.5rem 2rem;
  border-radius: 14px;
  box-shadow:
    0 50px 100px -30px rgba(0, 0, 0, 0.75),
    inset 0 1px 0 0 rgba(255, 255, 255, 0.04);
  animation: card-in var(--dur-slow) var(--ease-entrance) both;
}
:root[data-theme="light"] .overlay .card {
  background: var(--bg-surface-1);
  box-shadow:
    0 40px 80px -30px rgba(15, 14, 12, 0.25),
    inset 0 1px 0 0 rgba(255, 255, 255, 0.5);
}
@keyframes card-in {
  from { opacity: 0; transform: translateY(12px); }
  to   { opacity: 1; transform: none; }
}
.overlay h2 { margin-bottom: 0.9rem; }
.overlay p  { margin: 0 0 1rem; color: var(--text-secondary); }
.overlay-eyebrow {
  font-family: var(--font-mono); font-size: 0.72rem;
  font-weight: 500; letter-spacing: 0.22em; text-transform: uppercase;
  color: var(--accent-gold); margin: 0 0 0.5rem;
}

/* ============================================================
   HANDOFF — Pass 3
   ============================================================ */
.handoff-card {
  max-width: 640px;
  padding: 2.5rem 2.5rem 2rem;
  animation: handoff-card-spring 520ms 100ms cubic-bezier(0.16, 1, 0.3, 1) both;
  box-shadow:
    0 60px 120px -40px rgba(0, 0, 0, 0.85),
    inset 0 1px 0 0 rgba(255, 255, 255, 0.05);
}
@keyframes handoff-card-spring {
  0%   { opacity: 0; transform: translateY(20px) scale(0.92); }
  62%  { opacity: 1; transform: translateY(-2px) scale(1.02); }
  100% { opacity: 1; transform: translateY(0) scale(1.0); }
}

#handoff-overlay.exiting {
  animation: backdrop-out var(--dur-base) var(--ease-transition) forwards;
}
#handoff-overlay.exiting .handoff-card {
  animation: handoff-card-exit var(--dur-base) var(--ease-transition) forwards;
}
@keyframes backdrop-out {
  to { opacity: 0; }
}
@keyframes handoff-card-exit {
  to { opacity: 0; transform: translateY(0) scale(0.96); }
}

.handoff-eyebrow { margin: 0 0 1.1rem; }

.handoff-title-block {
  display: flex; align-items: center;
  gap: 1.1rem;
  font-family: var(--font-serif);
  font-variation-settings: 'opsz' 72;
  font-size: clamp(1.7rem, 4vw, 2.4rem);
  font-weight: 400;
  letter-spacing: -0.025em;
  color: var(--text-primary);
  margin: 0 0 1rem;
  flex-wrap: wrap;
  line-height: 1.1;
}
.handoff-role { white-space: nowrap; }

.handoff-arrow {
  width: 64px; height: 24px;
  color: var(--accent-gold);
  flex-shrink: 0;
}
.handoff-arrow .line,
.handoff-arrow .head {
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.handoff-arrow .line {
  stroke-dasharray: 56;
  stroke-dashoffset: 56;
  animation: arrow-line 320ms 520ms cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
.handoff-arrow .head {
  stroke-dasharray: 24;
  stroke-dashoffset: 24;
  animation: arrow-head 220ms 800ms cubic-bezier(0.16, 1, 0.3, 1) forwards;
}
@keyframes arrow-line { to { stroke-dashoffset: 0; } }
@keyframes arrow-head { to { stroke-dashoffset: 0; } }

.handoff-round-info {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-tertiary);
  margin: 0 0 1.6rem !important;
}

#handoff-overlay blockquote {
  margin: 0 0 1.8rem;
  padding: 1.1rem 1.4rem;
  border-left: 3px solid var(--accent-gold);
  background: var(--accent-soft-bg);
  border-radius: 0 8px 8px 0;
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 300;
  font-variation-settings: 'opsz' 24;
  font-size: 1.08rem;
  line-height: 1.6;
  color: var(--text-primary);
}

.primary-cta {
  height: 52px;
  padding: 0 2rem;
  background: var(--bg-surface-3);
  color: var(--text-primary);
  border: 1px solid var(--border-medium);
  border-radius: 12px;
  font-family: var(--font-sans);
  font-size: 0.97rem;
  font-weight: 500;
  position: relative;
  overflow: hidden;
  transition: background var(--dur-fast) var(--ease-transition),
              border-color var(--dur-fast) var(--ease-transition),
              color var(--dur-fast) var(--ease-transition),
              transform var(--dur-fast) var(--ease-transition);
}
.primary-cta::before {
  content: "";
  position: absolute; top: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.18), transparent);
  pointer-events: none;
}
.primary-cta:hover {
  background: var(--accent-gradient-deep);
  border-color: var(--accent-gold);
  color: #0A0B0F;
}
.primary-cta:hover::before {
  background: linear-gradient(90deg, transparent, rgba(255,255,255,0.4), transparent);
}
.primary-cta:active { transform: scale(0.97); }

/* ============================================================
   DELIBERATION MODE — Pass 4
   ============================================================ */
.mode-deliberation .message:not(.committee):not(.thinking) {
  opacity: 0.32;
}

.committee-transition {
  align-self: center;
  font-family: var(--font-serif);
  font-variation-settings: 'opsz' 36;
  font-size: 1.2rem;
  font-style: italic;
  color: var(--text-secondary);
  padding: 2rem 0 1rem;
  animation: enter var(--dur-slow) var(--ease-entrance) both;
}
.committee-transition::after {
  content: ""; display: inline-block; width: 0.4em;
  animation: ellipsis 1.2s steps(4) infinite;
}
@keyframes ellipsis {
  0%   { content: ""; }
  25%  { content: "."; }
  50%  { content: ".."; }
  75%  { content: "..."; }
  100% { content: ""; }
}

.message.committee {
  max-width: 82%;
}
.message.committee .who {
  font-family: var(--font-mono);
  font-size: 0.68rem; font-weight: 500;
  letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--text-secondary);
}
.message.committee .bubble {
  background: var(--bg-surface-2);
  border-color: var(--border-medium);
  border-left: 2px solid var(--text-tertiary);
}
.message.committee[data-speaker="recruiter"] .who      { color: #B8C0CC; }
.message.committee[data-speaker="hiring-manager"] .who { color: var(--co-meta); }
.message.committee[data-speaker="domain-expert"] .who  { color: var(--co-microsoft); }
.message.committee[data-speaker="bar-raiser"] .who     { color: var(--accent-gold); }

.message.committee[data-speaker="bar-raiser"] .bubble {
  border-left: 3px solid var(--accent-gold);
  background: var(--bg-surface-2);
  box-shadow:
    0 0 28px -10px rgba(232, 217, 103, 0.20),
    inset 0 1px 0 0 rgba(255, 255, 255, 0.03);
}

/* ============================================================
   DECISION CARD — Pass 4
   ============================================================ */
.final-card { max-width: 760px; max-height: 86vh; overflow-y: auto; }
.decision-card {
  max-width: 760px;
  padding: 2.75rem 2.5rem 2rem;
  animation: decision-slide-up 520ms var(--ease-entrance) both;
}
@keyframes decision-slide-up {
  from { opacity: 0; transform: translateY(40px); }
  to   { opacity: 1; transform: none; }
}

.decision-vote-block {
  margin: 0.5rem 0 2.1rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--border-subtle);
}
.decision-vote {
  display: block;
  font-family: var(--font-serif);
  font-variation-settings: 'opsz' 96;
  font-size: clamp(3.4rem, 7vw, 5.4rem);
  font-weight: 400;
  line-height: 1;
  letter-spacing: -0.035em;
  margin: 0 0 0.6rem;
}
.decision-vote.vote-strong-hire    { color: var(--vote-strong-hire); }
.decision-vote.vote-hire           { color: var(--accent-gold); }
.decision-vote.vote-no-hire        { color: var(--text-secondary); }
.decision-vote.vote-strong-no-hire { color: var(--vote-strong-no-hire); }

.decision-summary {
  font-family: var(--font-serif);
  font-variation-settings: 'opsz' 36;
  font-style: italic;
  font-weight: 300;
  font-size: 1.12rem;
  line-height: 1.5;
  color: var(--text-secondary);
  margin: 0 !important;
}

.decision-section { margin-bottom: 1.5rem; }
.decision-section:last-of-type { margin-bottom: 2rem; }
.decision-section-header {
  display: flex; align-items: center;
  gap: 0.55rem;
  margin-bottom: 0.65rem;
}
.decision-icon {
  display: inline-flex; align-items: center; justify-content: center;
  width: 14px; height: 14px;
  color: var(--text-tertiary);
  flex-shrink: 0;
}
.decision-icon svg { width: 14px; height: 14px; }
.decision-section[data-section="strengths"] .decision-icon  { color: var(--vote-strong-hire); opacity: 0.85; }
.decision-section[data-section="concerns"] .decision-icon   { color: var(--vote-strong-no-hire); opacity: 0.85; }
.decision-section[data-section="next_steps"] .decision-icon { color: var(--accent-gold); }
.decision-section h3 {
  font-family: var(--font-mono);
  font-size: 0.68rem; font-weight: 500;
  letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--text-tertiary);
  margin: 0;
}

.decision-list { margin: 0; padding-left: 1.3rem; list-style: decimal; }
.decision-list.plain { list-style: disc; }
.decision-list li { margin-bottom: 0.7rem; color: var(--text-primary); font-size: 0.95rem; }
.decision-list .point { margin: 0; }
.decision-list .evidence {
  margin: 0.22rem 0 0;
  color: var(--text-secondary);
  font-size: 0.88rem; font-style: italic;
}

.secondary-cta {
  padding: 0.65rem 1.4rem;
  background: transparent;
  color: var(--text-secondary);
  border: 1px solid var(--border-medium);
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  transition: color var(--dur-fast) var(--ease-transition),
              border-color var(--dur-fast) var(--ease-transition),
              background var(--dur-fast) var(--ease-transition),
              transform var(--dur-fast) var(--ease-transition);
}
.secondary-cta:hover {
  color: var(--text-primary);
  border-color: var(--border-strong);
  background: rgba(255, 255, 255, 0.02);
}
:root[data-theme="light"] .secondary-cta:hover { background: rgba(15, 14, 12, 0.03); }
.secondary-cta:active { transform: scale(0.97); }

/* ============================================================
   VERDICT CARD FOOTER — Coach handoff CTAs
   ============================================================ */
.final-actions {
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
  align-items: stretch;
  margin-top: 0.5rem;
}
.final-actions .primary-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  width: 100%;
}
.final-actions .primary-cta .cta-label { letter-spacing: 0.04em; }
.final-actions .primary-cta .cta-arrow {
  display: inline-block;
  transition: transform var(--dur-fast) var(--ease-transition);
}
.final-actions .primary-cta:hover .cta-arrow { transform: translateX(3px); }
.final-actions .secondary-cta { align-self: center; }
.final-report-hint {
  margin: 0.8rem 0 0 !important;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-tertiary);
  text-align: center;
  opacity: 0;
  transition: opacity var(--dur-base) var(--ease-transition);
}
.final-report-hint.visible { opacity: 1; }
.final-report-hint.ready    { color: var(--accent-gold); }

/* ============================================================
   COACH REPORT — Detailed post-session feedback
   ============================================================ */
.coach-report-card {
  max-width: 920px;
  max-height: 92vh;
  padding: 0;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.coach-report-header {
  padding: 2rem 2.4rem 1.4rem;
  border-bottom: 1px solid var(--border-subtle);
  background: var(--bg-surface-1);
}
.coach-report-eyebrow-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.6rem;
}
.coach-report-eyebrow-row .overlay-eyebrow { margin: 0; }
.coach-close-btn {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  padding: 0.35rem 0.6rem 0.35rem 0;
}
.coach-report-title {
  font-family: var(--font-serif);
  font-variation-settings: 'opsz' 72;
  font-size: clamp(1.7rem, 4vw, 2.3rem);
  font-weight: 400;
  letter-spacing: -0.02em;
  color: var(--text-primary);
  margin: 0 0 0.35rem !important;
  line-height: 1.1;
}
.coach-report-title em {
  font-style: italic;
  color: var(--accent-gold);
  font-variation-settings: 'opsz' 72;
}
.coach-report-meta {
  margin: 0 !important;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-tertiary);
}

.coach-report-body {
  padding: 1.6rem 2.4rem 1.6rem;
  overflow-y: auto;
  flex: 1 1 auto;
}

/* Loading state */
.coach-report-loading {
  padding: 3rem 1rem 3.5rem;
  text-align: center;
}
.coach-loading-stage {
  display: inline-flex;
  gap: 0.55rem;
  margin-bottom: 1.2rem;
}
.coach-loading-dot {
  width: 8px; height: 8px;
  background: var(--accent-gold);
  border-radius: 50%;
  display: inline-block;
  animation: coach-pulse 1.4s ease-in-out infinite both;
}
.coach-loading-dot:nth-child(2) { animation-delay: 0.18s; }
.coach-loading-dot:nth-child(3) { animation-delay: 0.36s; }
@keyframes coach-pulse {
  0%, 80%, 100% { transform: scale(0.6); opacity: 0.4; }
  40%           { transform: scale(1.0); opacity: 1; }
}
.coach-loading-text {
  font-family: var(--font-serif);
  font-variation-settings: 'opsz' 24;
  font-size: 1.2rem;
  color: var(--text-primary);
  margin: 0 0 0.4rem !important;
}
.coach-loading-sub {
  color: var(--text-tertiary);
  font-size: 0.88rem;
  max-width: 28rem;
  margin: 0 auto !important;
}

/* Failed state */
.coach-report-failed {
  padding: 2rem 1rem 2.5rem;
  text-align: center;
}
.coach-failed-text {
  color: var(--text-secondary);
  margin: 0 0 1.2rem !important;
}

/* Content sections */
.coach-section { margin-bottom: 2.2rem; }
.coach-section:last-child { margin-bottom: 0.4rem; }
.coach-section-title {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--accent-gold);
  margin: 0 0 1rem;
}

.coach-verdict-line {
  margin: 0 0 1.6rem;
  padding: 1.1rem 1.4rem;
  border-left: 3px solid var(--accent-gold);
  background: var(--accent-soft-bg);
  border-radius: 0 8px 8px 0;
  font-family: var(--font-serif);
  font-style: italic;
  font-variation-settings: 'opsz' 24;
  font-size: 1.05rem;
  line-height: 1.55;
  color: var(--text-primary);
}
.coach-overall-body {
  color: var(--text-primary);
  font-size: 0.98rem;
  line-height: 1.65;
  margin: 0 !important;
}

/* Round-by-round */
.coach-rounds {
  display: flex;
  flex-direction: column;
  gap: 1.3rem;
}
.coach-round {
  padding: 1.1rem 1.3rem 1.2rem;
  background: var(--bg-surface-2);
  border: 1px solid var(--border-subtle);
  border-radius: 10px;
}
.coach-round-head {
  display: flex;
  align-items: baseline;
  gap: 0.6rem;
  margin-bottom: 0.7rem;
  padding-bottom: 0.55rem;
  border-bottom: 1px dashed var(--border-subtle);
}
.coach-round-num {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--accent-gold);
}
.coach-round-name {
  font-family: var(--font-serif);
  font-variation-settings: 'opsz' 24;
  font-size: 1.15rem;
  color: var(--text-primary);
}
.coach-round-block { margin-bottom: 0.85rem; }
.coach-round-block:last-child { margin-bottom: 0; }
.coach-round-label {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--text-tertiary);
  margin: 0 0 0.3rem;
}
.coach-round-text {
  margin: 0 !important;
  color: var(--text-primary);
  font-size: 0.93rem;
  line-height: 1.6;
}
.coach-quote {
  margin: 0.35rem 0 0.4rem;
  padding: 0.6rem 1rem;
  border-left: 2px solid var(--border-strong);
  background: var(--bg-surface-3);
  border-radius: 0 6px 6px 0;
  font-family: var(--font-serif);
  font-style: italic;
  font-variation-settings: 'opsz' 24;
  font-size: 0.95rem;
  line-height: 1.55;
  color: var(--text-primary);
}
.coach-quote-attrib {
  margin: 0.3rem 0 0;
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-tertiary);
}
.coach-redirect {
  margin: 0.4rem 0 0 !important;
  color: var(--text-secondary);
  font-size: 0.88rem;
  font-style: italic;
  line-height: 1.5;
}
.coach-redirect strong {
  font-style: normal;
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent-gold);
  margin-right: 0.4rem;
}

/* Strengths / Improvements / Actions lists */
.coach-strengths-list,
.coach-improvements-list,
.coach-actions-list {
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: coach-item;
}
.coach-strengths-list li,
.coach-improvements-list li {
  position: relative;
  padding: 0.9rem 1.1rem 1rem 3rem;
  background: var(--bg-surface-2);
  border: 1px solid var(--border-subtle);
  border-radius: 10px;
  margin-bottom: 0.7rem;
  counter-increment: coach-item;
}
.coach-strengths-list li::before,
.coach-improvements-list li::before {
  content: counter(coach-item);
  position: absolute;
  top: 0.85rem; left: 1.1rem;
  width: 24px; height: 24px;
  border-radius: 50%;
  background: var(--accent-soft-bg);
  color: var(--accent-gold);
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.coach-item-head {
  font-family: var(--font-serif);
  font-variation-settings: 'opsz' 24;
  font-size: 1.05rem;
  color: var(--text-primary);
  margin: 0 0 0.35rem;
  line-height: 1.35;
}
.coach-item-body {
  margin: 0 !important;
  color: var(--text-secondary);
  font-size: 0.9rem;
  line-height: 1.55;
}
.coach-item-aside {
  margin: 0.4rem 0 0 !important;
  color: var(--text-tertiary);
  font-size: 0.82rem;
  font-style: italic;
  line-height: 1.5;
}
.coach-item-aside strong {
  font-style: normal;
  font-family: var(--font-mono);
  font-size: 0.64rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--accent-gold);
  margin-right: 0.4rem;
}
.coach-improvements-list .coach-quote { margin-top: 0.5rem; }

.coach-actions-list { counter-reset: coach-action; }
.coach-actions-list li {
  position: relative;
  padding: 0.7rem 1rem 0.7rem 2.6rem;
  border-bottom: 1px solid var(--border-subtle);
  counter-increment: coach-action;
}
.coach-actions-list li:last-child { border-bottom: none; }
.coach-actions-list li::before {
  content: counter(coach-action);
  position: absolute;
  top: 0.85rem; left: 0.6rem;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-tertiary);
  width: 1.4rem;
  text-align: right;
}
.coach-action-row {
  display: flex;
  align-items: baseline;
  gap: 0.6rem;
  flex-wrap: wrap;
}
.coach-action-priority {
  font-family: var(--font-mono);
  font-size: 0.6rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  padding: 0.15rem 0.5rem;
  border-radius: 999px;
  border: 1px solid var(--border-medium);
  color: var(--text-tertiary);
  flex-shrink: 0;
}
.coach-action-priority.priority-high {
  color: var(--accent-gold);
  border-color: var(--accent-gold);
}
.coach-action-priority.priority-medium {
  color: var(--text-secondary);
  border-color: var(--border-strong);
}
.coach-action-item {
  flex: 1 1 16rem;
  color: var(--text-primary);
  font-size: 0.93rem;
  line-height: 1.5;
}
.coach-action-time {
  flex-shrink: 0;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--text-tertiary);
  letter-spacing: 0.04em;
}

.coach-closing-body {
  margin: 0 !important;
  padding: 1.1rem 1.4rem;
  background: var(--bg-surface-2);
  border-radius: 10px;
  font-family: var(--font-serif);
  font-style: italic;
  font-variation-settings: 'opsz' 24;
  font-size: 1.02rem;
  line-height: 1.65;
  color: var(--text-primary);
}

.coach-report-footer {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  padding: 1.4rem 2.4rem 1.6rem;
  border-top: 1px solid var(--border-subtle);
  background: var(--bg-surface-1);
}

/* Two-column download row */
.coach-download-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.4rem;
  align-items: start;
}
.coach-download-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.55rem;
}
.coach-download-btn {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  width: 100%;
  max-width: 260px;
}
/* Primary (PDF) — terracotta filled, default action */
.coach-report-footer .primary-cta.coach-download-btn {
  background: var(--vote-strong-no-hire);
  border-color: var(--vote-strong-no-hire);
  color: #faf6ef;
}
.coach-report-footer .primary-cta.coach-download-btn::before { display: none; }
.coach-report-footer .primary-cta.coach-download-btn:hover {
  background: #b1462f;
  border-color: #b1462f;
}
/* Secondary (Markdown) — ghost outline */
.coach-report-footer .secondary-cta.coach-download-btn {
  padding: 0 1.4rem;
  height: 52px;
  border-radius: 999px;
}
.coach-download-caption {
  margin: 0 !important;
  max-width: 280px;
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 0.82rem;
  line-height: 1.5;
  color: var(--text-tertiary);
}

/* TIP block — subtle paper tint, terracotta accent label */
.coach-tip {
  margin: 0.6rem auto 0;
  max-width: 540px;
  padding: 0.85rem 1.2rem 1rem;
  background: var(--bg-surface-2);
  border-radius: 8px;
  border-left: 2px solid var(--vote-strong-no-hire);
}
.coach-tip-label {
  margin: 0 0 0.35rem !important;
  font-family: var(--font-mono);
  font-size: 0.62rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--vote-strong-no-hire);
}
.coach-tip-body {
  margin: 0 !important;
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 0.92rem;
  line-height: 1.55;
  color: var(--text-secondary);
}

/* ============================================================
   SWITCHER MODAL — Pass 5 (Cmd+K)
   ============================================================ */
.switcher-card { max-width: 480px; }
.switcher-title {
  font-family: var(--font-serif);
  font-size: 1.4rem;
  margin: 0 0 0.6rem !important;
}
.switcher-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.5rem;
  margin: 1.3rem 0 1.5rem;
}
.switcher-grid button {
  padding: 0.8rem 1rem;
  text-align: left;
  background: var(--bg-surface-1);
  color: var(--text-primary);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  font-family: var(--font-serif);
  font-variation-settings: 'opsz' 24;
  font-size: 1rem;
  transition: all var(--dur-fast) var(--ease-transition);
}
.switcher-grid button:hover {
  border-color: var(--accent-gold);
  background: var(--bg-surface-2);
}

/* ============================================================
   KEYBOARD HINT — Pass 5
   ============================================================ */
.kbd-hint-btn {
  position: fixed;
  bottom: 1.2rem; right: 1.2rem;
  width: 28px; height: 28px;
  padding: 0;
  background: rgba(255, 255, 255, 0.025);
  border: 1px solid var(--border-subtle);
  border-radius: 999px;
  color: var(--text-tertiary);
  font-family: var(--font-mono);
  font-size: 0.78rem;
  z-index: 60;
  display: inline-flex; align-items: center; justify-content: center;
  transition: color var(--dur-fast) var(--ease-transition),
              border-color var(--dur-fast) var(--ease-transition),
              background var(--dur-fast) var(--ease-transition);
}
:root[data-theme="light"] .kbd-hint-btn { background: rgba(15, 14, 12, 0.04); }
.kbd-hint-btn:hover {
  color: var(--text-primary);
  border-color: var(--border-medium);
}

.kbd-panel {
  position: fixed;
  bottom: 4rem; right: 1.2rem;
  background: var(--bg-surface-2);
  border: 1px solid var(--border-medium);
  border-radius: 10px;
  padding: 1rem 1.25rem;
  z-index: 60;
  width: 240px;
  box-shadow: 0 20px 40px -20px rgba(0, 0, 0, 0.5);
  animation: kbd-in 220ms var(--ease-entrance) both;
}
@keyframes kbd-in {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: none; }
}
.kbd-panel.hidden { display: none; }
.kbd-panel h4 {
  font-family: var(--font-mono);
  font-size: 0.66rem;
  letter-spacing: 0.20em;
  text-transform: uppercase;
  color: var(--text-tertiary);
  margin: 0 0 0.7rem;
}
.kbd-panel dl {
  margin: 0;
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.45rem 0.7rem;
}
.kbd-panel dt { margin: 0; }
.kbd-panel kbd {
  background: var(--bg-surface-3);
  border: 1px solid var(--border-medium);
  border-radius: 4px;
  padding: 0.08rem 0.4rem;
  font-family: var(--font-mono);
  font-size: 0.66rem;
  color: var(--text-secondary);
  white-space: nowrap;
}
.kbd-panel dd {
  margin: 0;
  color: var(--text-secondary);
  font-size: 0.78rem;
  line-height: 1.4;
}

/* ============================================================
   AGENT NETWORK — live multi-agent visualization
   Sits above the dossier, same right column.
   ============================================================ */

#network-panel {
  flex-shrink: 0;
  background: var(--bg-surface-1);
  border-bottom: 1px solid var(--border-subtle);
  padding: 1.1rem 1.2rem 0.95rem;
}

.agent-network {
  width: 100%;
  height: auto;
  display: block;
  color: var(--text-secondary);
}

/* hide the Domain Expert node, label, status, and edges to it (3-round panel) */
.agent-network .node[data-role="domain-expert"],
.agent-network .label[data-role="domain-expert"],
.agent-network .status-text[data-role="domain-expert"],
.agent-network .coord-edge[data-role="domain-expert"],
.agent-network .net-edge[data-edge="hm-de"],
.agent-network .net-edge[data-edge="de-br"] {
  display: none;
}

/* edges */
.agent-network .net-edge {
  stroke: var(--text-tertiary);
  stroke-width: 0.6;
  stroke-opacity: 0.3;
  fill: none;
  transition: stroke 240ms var(--ease-transition),
              stroke-opacity 240ms var(--ease-transition),
              stroke-width 240ms var(--ease-transition);
}
.agent-network .coord-edge {
  stroke: var(--text-tertiary);
  stroke-width: 1;
  stroke-opacity: 0.45;
  fill: none;
  transition: stroke 240ms var(--ease-transition),
              stroke-opacity 240ms var(--ease-transition),
              stroke-width 240ms var(--ease-transition);
}
.agent-network .user-edge {
  stroke: var(--text-tertiary);
  stroke-width: 1;
  stroke-opacity: 0.35;
  stroke-dasharray: 2 3;
  fill: none;
  transition: stroke-opacity 240ms var(--ease-transition);
}

/* default node rings */
.agent-network .node .ring {
  fill: none;
  stroke: var(--text-secondary);
  stroke-width: 1.2;
  stroke-opacity: 0.7;
  transition: fill 240ms var(--ease-transition),
              stroke 240ms var(--ease-transition),
              stroke-opacity 240ms var(--ease-transition),
              fill-opacity 240ms var(--ease-transition);
}

/* observer-specific (hexagon ring + sonar) */
.agent-network .node.observer .ring {
  stroke-width: 1.4;
  animation: observer-breath 3s ease-in-out infinite;
}
@keyframes observer-breath {
  0%, 100% { stroke-opacity: 0.7; }
  50% { stroke-opacity: 1; }
}
.agent-network .sonar {
  fill: none;
  stroke: var(--accent-gold);
  stroke-width: 1;
  stroke-opacity: 0;
  transform-box: fill-box;
  transform-origin: center;
  animation: observer-sonar 3s ease-out infinite;
}
@keyframes observer-sonar {
  0%   { transform: scale(1);   stroke-opacity: 0; }
  20%  { transform: scale(1.1); stroke-opacity: 0.45; }
  100% { transform: scale(2.5); stroke-opacity: 0; }
}

/* user dot */
.agent-network .user-dot {
  fill: var(--text-tertiary);
  fill-opacity: 0.6;
  transition: fill-opacity 240ms var(--ease-transition);
}

/* labels */
.agent-network .label {
  font-family: var(--font-mono);
  font-size: 8px;
  font-weight: 500;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  fill: var(--text-tertiary);
  text-anchor: middle;
  pointer-events: none;
}
.agent-network .observer-label { fill: var(--text-secondary); }
.agent-network .user-label { text-anchor: start; }

/* status text (per-node + network-level) */
.agent-network .status-text {
  font-family: var(--font-mono);
  font-size: 7px;
  letter-spacing: 0.10em;
  text-transform: uppercase;
  fill: var(--accent-gold);
  text-anchor: middle;
  opacity: 0;
  transition: opacity 240ms var(--ease-transition);
  pointer-events: none;
}
.agent-network .status-text.visible { opacity: 0.95; }
.agent-network .net-status {
  font-family: var(--font-mono);
  font-size: 7.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  fill: var(--accent-gold);
  text-anchor: middle;
  opacity: 0;
  transition: opacity 240ms var(--ease-transition);
  pointer-events: none;
}
.agent-network .net-status.visible { opacity: 0.9; }

/* active interviewer */
.agent-network .node.interviewer.active .ring {
  fill: var(--accent-gold);
  fill-opacity: 0.18;
  stroke: var(--accent-gold);
  stroke-opacity: 1;
  transform-box: fill-box;
  transform-origin: center;
  animation: node-active-breath 2s ease-in-out infinite;
}
@keyframes node-active-breath {
  0%, 100% { transform: scale(1); }
  50%      { transform: scale(1.05); }
}

/* muted (not the active interviewer) */
.agent-network .node.interviewer.muted .ring {
  stroke-opacity: 0.4;
}

/* coord-edge active (data flow from Observer outward) */
.agent-network .coord-edge.active {
  stroke: var(--accent-gold);
  stroke-opacity: 0.8;
  stroke-width: 1.3;
  stroke-dasharray: 4 3;
  animation: coord-flow 1.2s linear infinite;
}
@keyframes coord-flow {
  to { stroke-dashoffset: -14; }
}

/* observer flash (on answer received) */
.agent-network .node.observer.flash .ring {
  fill: var(--accent-gold);
  fill-opacity: 0.35;
  stroke: var(--accent-gold-bright);
}

/* observer ripple (one-off, JS-inserted) */
.observer-ripple {
  fill: none;
  stroke: var(--accent-gold);
  stroke-width: 1.4;
  stroke-opacity: 0.7;
  transform-box: fill-box;
  transform-origin: center;
  animation: observer-ripple-grow 800ms cubic-bezier(0.16, 1, 0.3, 1) forwards;
  pointer-events: none;
}
@keyframes observer-ripple-grow {
  0%   { transform: scale(1);   stroke-opacity: 0.8; }
  100% { transform: scale(2.6); stroke-opacity: 0; }
}

/* flow-dot (JS-inserted, animated via rAF) */
.flow-dot {
  fill: var(--accent-gold);
  pointer-events: none;
}

/* watching-dot synced pulse (linked to observer ripple) */
.watching-dot.synced-pulse {
  animation: watching-synced-pulse 800ms cubic-bezier(0.16, 1, 0.3, 1);
}
@keyframes watching-synced-pulse {
  0%   { box-shadow: 0 0 10px 0 rgba(232, 217, 103, 0.5); transform: scale(1); }
  35%  { box-shadow: 0 0 16px 4px rgba(232, 217, 103, 0.9); transform: scale(1.45); }
  100% { box-shadow: 0 0 10px 0 rgba(232, 217, 103, 0.5); transform: scale(1); }
}

/* committee deliberation — hide YOU, all interviewers low-glow */
body.mode-deliberation .agent-network .node.user,
body.mode-deliberation .agent-network .user-edge,
body.mode-deliberation .agent-network .user-label {
  opacity: 0.15;
  transition: opacity 400ms var(--ease-transition);
}
body.mode-deliberation .agent-network .node.interviewer .ring {
  stroke: var(--accent-gold);
  stroke-opacity: 0.55;
  fill: var(--accent-gold);
  fill-opacity: 0.05;
}
body.mode-deliberation .agent-network .node.interviewer.muted .ring {
  stroke-opacity: 0.55;
}
body.mode-deliberation .agent-network .node.interviewer.speaking .ring {
  stroke-opacity: 1;
  fill-opacity: 0.22;
  transform-box: fill-box;
  transform-origin: center;
  animation: node-active-breath 1.6s ease-in-out infinite;
}
body.mode-deliberation .agent-network .net-edge.active {
  stroke: var(--accent-gold);
  stroke-opacity: 0.6;
  stroke-width: 1;
  stroke-dasharray: 4 3;
  animation: coord-flow 1.5s linear infinite;
}

/* telemetry */
.network-telemetry {
  margin: 0.4rem 0 0;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.06em;
  color: var(--text-tertiary);
  text-align: center;
  line-height: 1.4;
}

/* ----- light-mode tweaks ----- */
:root[data-theme="light"] .agent-network .net-edge,
:root[data-theme="light"] .agent-network .coord-edge,
:root[data-theme="light"] .agent-network .user-edge {
  stroke: var(--text-secondary);
}
:root[data-theme="light"] .agent-network .node.interviewer.active .ring {
  fill: var(--accent-gold);
  fill-opacity: 0.22;
  stroke: var(--accent-gold-deep);
}
:root[data-theme="light"] .agent-network .status-text,
:root[data-theme="light"] .agent-network .net-status {
  fill: var(--accent-gold-deep);
}

/* ----- mobile / narrow viewport ----- */
@media (max-width: 760px) {
  #right-column { border-left: none; border-top: 1px solid var(--border-subtle); }
  #network-panel { padding: 0.7rem 1rem 0.6rem; }
  .agent-network {
    /* compress vertically — labels still readable since we keep aspect */
    max-height: 220px;
  }
}

/* ============================================================
   Reduced motion
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  body::before { animation: none; }
}
