/* ============================================================
   NeuralHire — Design System
   Aesthetic: Cyber-noir · Violet/Sky · Geometric Precision
   ============================================================ */

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

:root {
  --bg:           #02020a;
  --bg2:          #07071a;
  --bg3:          #0d0d20;
  --glass:        rgba(13, 13, 32, 0.75);
  --glass-border: rgba(167, 139, 250, 0.18);
  --glass-hi:     rgba(167, 139, 250, 0.06);

  --primary:      #a78bfa;
  --primary-dim:  rgba(167, 139, 250, 0.25);
  --primary-glow: rgba(167, 139, 250, 0.4);
  --accent:       #38bdf8;
  --accent-dim:   rgba(56, 189, 248, 0.2);
  --fuchsia:      #e879f9;
  --fuchsia-dim:  rgba(232, 121, 249, 0.2);

  --success:      #4ade80;
  --success-dim:  rgba(74, 222, 128, 0.15);
  --warning:      #fbbf24;
  --warning-dim:  rgba(251, 191, 36, 0.15);
  --danger:       #f87171;
  --danger-dim:   rgba(248, 113, 113, 0.15);

  --text:         #e2e8f0;
  --text2:        #94a3b8;
  --text3:        #475569;

  --font-display: 'Syncopate', sans-serif;
  --font-body:    'DM Sans', sans-serif;
  --font-mono:    'JetBrains Mono', monospace;

  --r-sm:   8px;
  --r-md:   14px;
  --r-lg:   20px;
  --r-xl:   28px;
  --r-full: 9999px;

  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  overflow-x: hidden;
  line-height: 1.6;
}

/* --- Background Layers --- */
#particle-canvas {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}

.grid-overlay {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(167, 139, 250, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(167, 139, 250, 0.04) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(ellipse 80% 60% at 50% 40%, black, transparent);
}

.vignette {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background: radial-gradient(ellipse at 50% 50%, transparent 40%, rgba(2,2,10,0.85) 100%);
}

/* --- Screen System --- */
.screen {
  position: fixed;
  inset: 0;
  z-index: 10;
  display: flex;
  flex-direction: column;
  opacity: 0;
  transform: translateY(12px);
  pointer-events: none;
  transition: opacity 0.5s cubic-bezier(0.4, 0, 0.2, 1),
              transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}
.screen.active {
  opacity: 1;
  transform: translateY(0);
  pointer-events: all;
}
.screen.hidden { display: none; }

/* --- Navbar --- */
.navbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 36px;
  border-bottom: 1px solid var(--glass-border);
  background: rgba(2, 2, 10, 0.6);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  position: relative;
  z-index: 20;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
}

.logo-text {
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: var(--text);
}

.nav-center { display: flex; align-items: center; }

.nav-pill {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.14em;
  color: var(--accent);
  background: rgba(56, 189, 248, 0.08);
  border: 1px solid rgba(56, 189, 248, 0.2);
  padding: 4px 12px;
  border-radius: var(--r-full);
}

.nav-status {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 12px;
  color: var(--text2);
  font-family: var(--font-mono);
}

.status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--success);
  box-shadow: 0 0 8px var(--success);
  animation: blink-dot 2s ease-in-out infinite;
}

@keyframes blink-dot {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

/* --- Upload Main --- */
.upload-main {
  flex: 1;
  padding: 40px 36px 32px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 36px;
  max-width: 1280px;
  margin: 0 auto;
  width: 100%;
}

/* --- Hero Section --- */
.hero-section { max-width: 680px; }

.hero-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.18em;
  color: var(--primary);
  margin-bottom: 18px;
}

.tag-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--fuchsia);
  box-shadow: 0 0 8px var(--fuchsia);
  animation: blink-dot 1.5s infinite;
}

.hero-title {
  font-family: var(--font-display);
  font-size: clamp(28px, 4vw, 50px);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.01em;
  margin-bottom: 14px;
}

.gradient-text {
  background: linear-gradient(135deg, var(--primary) 0%, var(--fuchsia) 50%, var(--accent) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-sub {
  font-size: 15px;
  color: var(--text2);
  line-height: 1.7;
  font-weight: 300;
}

/* --- Glass Panel --- */
.glass-panel {
  background: var(--glass);
  border: 1px solid var(--glass-border);
  border-radius: var(--r-xl);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  transition: var(--transition);
}

.glass-panel:hover {
  border-color: rgba(167, 139, 250, 0.3);
  box-shadow: 0 0 30px rgba(167, 139, 250, 0.06);
}

/* --- Upload Grid --- */
.upload-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.upload-panel {
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-height: 360px;
}

.panel-header {
  display: flex;
  align-items: center;
  gap: 14px;
}

.panel-num {
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 700;
  color: var(--primary);
  background: var(--primary-dim);
  border: 1px solid var(--glass-border);
  width: 38px;
  height: 38px;
  border-radius: var(--r-md);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.panel-title { font-size: 15px; font-weight: 600; color: var(--text); display: block; }
.panel-hint { font-size: 11px; color: var(--text3); font-family: var(--font-mono); letter-spacing: 0.06em; }

/* --- Tab Bar --- */
.tab-bar {
  display: flex;
  gap: 4px;
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid var(--glass-border);
  border-radius: var(--r-md);
  padding: 4px;
}

.tab {
  flex: 1;
  background: transparent;
  border: none;
  border-radius: var(--r-sm);
  padding: 8px 12px;
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 500;
  color: var(--text3);
  cursor: pointer;
  transition: var(--transition);
}

.tab.active {
  background: var(--primary-dim);
  color: var(--primary);
  border: 1px solid var(--glass-border);
}

.tab-content { display: flex; flex-direction: column; flex: 1; }
.tab-content.hidden { display: none; }

/* --- Drop Zone --- */
.drop-zone {
  flex: 1;
  border: 1.5px dashed rgba(167, 139, 250, 0.3);
  border-radius: var(--r-lg);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  padding: 32px 20px;
  cursor: pointer;
  transition: var(--transition);
  background: rgba(167, 139, 250, 0.02);
  position: relative;
  overflow: hidden;
  min-height: 220px;
}

.drop-zone::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 50% 50%, rgba(167,139,250,0.06), transparent 60%);
  opacity: 0;
  transition: opacity 0.3s;
}

.drop-zone:hover, .drop-zone.dragover {
  border-color: var(--primary);
  background: rgba(167, 139, 250, 0.06);
}

.drop-zone:hover::before, .drop-zone.dragover::before { opacity: 1; }

.drop-anim { position: relative; display: flex; align-items: center; justify-content: center; }

.drop-icon {
  width: 52px;
  height: 52px;
  color: var(--primary);
  filter: drop-shadow(0 0 10px var(--primary-glow));
  animation: float-icon 3s ease-in-out infinite;
}

@keyframes float-icon {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-6px); }
}

.drop-ripple {
  position: absolute;
  width: 80px;
  height: 80px;
  border-radius: 50%;
  border: 1px solid var(--primary-dim);
  animation: ripple-out 2.5s ease-out infinite;
}

@keyframes ripple-out {
  0% { transform: scale(0.6); opacity: 0.7; }
  100% { transform: scale(1.6); opacity: 0; }
}

.drop-label {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  text-align: center;
}

.drop-label strong { font-size: 14px; color: var(--text); font-weight: 500; }
.drop-label span { font-size: 11px; color: var(--text3); font-family: var(--font-mono); }

/* --- File Preview --- */
.file-preview {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  background: rgba(74, 222, 128, 0.06);
  border: 1px solid rgba(74, 222, 128, 0.2);
  border-radius: var(--r-md);
  margin-top: 8px;
}

.file-preview.hidden { display: none; }

.file-icon-wrap { color: var(--primary); flex-shrink: 0; }

.file-details { flex: 1; min-width: 0; }
.file-name-text { display: block; font-size: 13px; color: var(--text); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.file-size-text { display: block; font-size: 11px; color: var(--text3); font-family: var(--font-mono); }

.file-remove-btn {
  background: transparent;
  border: none;
  color: var(--text3);
  cursor: pointer;
  font-size: 14px;
  padding: 4px 8px;
  border-radius: var(--r-sm);
  transition: var(--transition);
  flex-shrink: 0;
}
.file-remove-btn:hover { color: var(--danger); background: var(--danger-dim); }

/* --- Textareas --- */
.text-area {
  flex: 1;
  width: 100%;
  min-height: 240px;
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid var(--glass-border);
  border-radius: var(--r-lg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 13.5px;
  line-height: 1.7;
  padding: 16px 18px;
  resize: none;
  outline: none;
  transition: var(--transition);
}

.text-area::placeholder { color: var(--text3); }
.text-area:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-dim);
}

.jd-area { min-height: 280px; }

.char-counter {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--text3);
  text-align: right;
  padding-top: 4px;
}

/* --- Analyze Button --- */
.analyze-footer {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.analyze-btn {
  position: relative;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 36px;
  background: linear-gradient(135deg, #7c3aed 0%, #a855f7 50%, #d946ef 100%);
  border: none;
  border-radius: var(--r-full);
  color: white;
  font-family: var(--font-display);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  cursor: pointer;
  overflow: hidden;
  transition: var(--transition);
  box-shadow: 0 4px 30px rgba(139, 92, 246, 0.4);
  min-width: 220px;
  justify-content: center;
}

.analyze-btn:disabled {
  background: linear-gradient(135deg, #3d3060 0%, #4a3070 100%);
  box-shadow: none;
  cursor: not-allowed;
  opacity: 0.5;
}

.analyze-btn:not(:disabled):hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 40px rgba(139, 92, 246, 0.6);
}

.analyze-btn:not(:disabled):active { transform: translateY(0); }

.btn-shine {
  position: absolute;
  top: -50%;
  left: -60%;
  width: 40%;
  height: 200%;
  background: rgba(255, 255, 255, 0.15);
  transform: skewX(-20deg);
  animation: shine-move 3s ease-in-out infinite;
  pointer-events: none;
}

@keyframes shine-move {
  0%, 70% { left: -60%; }
  85% { left: 130%; }
  100% { left: 130%; }
}

.btn-content { display: flex; align-items: center; gap: 8px; position: relative; z-index: 1; }
.btn-arrow { position: relative; z-index: 1; font-size: 16px; }

.footer-meta { font-size: 11px; color: var(--text3); font-family: var(--font-mono); letter-spacing: 0.06em; }

/* ============================================================
   SCREEN 2: PROCESSING
   ============================================================ */

.processing-wrap {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 32px;
  padding: 40px 20px;
}

/* Orbiting rings */
.orbit {
  position: absolute;
  border-radius: 50%;
  border: 1px solid rgba(167, 139, 250, 0.1);
  animation: orbit-spin linear infinite;
  pointer-events: none;
}

.orbit-1 {
  width: 380px;
  height: 380px;
  animation-duration: 20s;
  border-style: dashed;
}

.orbit-2 {
  width: 520px;
  height: 520px;
  animation-duration: 30s;
  animation-direction: reverse;
  border-color: rgba(56, 189, 248, 0.08);
}

.orbit-3 {
  width: 660px;
  height: 660px;
  animation-duration: 40s;
  border-color: rgba(232, 121, 249, 0.05);
}

@keyframes orbit-spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

/* Robot Stage */
.robot-stage {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.robot-glow {
  position: absolute;
  width: 220px;
  height: 220px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(167, 139, 250, 0.2) 0%, transparent 70%);
  animation: glow-pulse 2s ease-in-out infinite;
}

@keyframes glow-pulse {
  0%, 100% { transform: scale(1); opacity: 0.8; }
  50% { transform: scale(1.15); opacity: 1; }
}

.robot-svg {
  width: 200px;
  height: 300px;
  position: relative;
  z-index: 2;
  animation: robot-float 3s ease-in-out infinite;
  filter: drop-shadow(0 0 20px rgba(167, 139, 250, 0.4));
}

@keyframes robot-float {
  0%, 100% { transform: translateY(0px); }
  50% { transform: translateY(-10px); }
}

/* Robot sub-animations (defined on SVG elements via CSS) */
.antenna-orb { animation: orb-pulse 1.2s ease-in-out infinite; }
@keyframes orb-pulse {
  0%, 100% { filter: drop-shadow(0 0 4px #e879f9); opacity: 1; }
  50% { filter: drop-shadow(0 0 12px #e879f9); opacity: 0.7; }
}

.antenna-ring { animation: ring-expand 1.2s ease-out infinite; }
@keyframes ring-expand {
  0% { r: 8; opacity: 0.6; }
  100% { r: 18; opacity: 0; }
}

.pupil-l, .pupil-r {
  animation: blink-eyes 4s ease-in-out infinite;
  transform-origin: center;
  transform-box: fill-box;
}

@keyframes blink-eyes {
  0%, 90%, 100% { transform: scaleY(1); }
  95% { transform: scaleY(0.1); }
}

.scan-line {
  animation: scan-sweep 2s ease-in-out infinite;
  transform-origin: top;
  transform-box: fill-box;
}

@keyframes scan-sweep {
  0% { transform: translateY(0px); }
  50% { transform: translateY(79px); }
  100% { transform: translateY(0px); }
}

.mouth-seg {
  animation: mouth-animate 0.4s ease-in-out infinite alternate;
}
.mouth-seg:nth-child(odd) { animation-delay: 0.1s; }
.mouth-seg:nth-child(even) { animation-delay: 0.2s; }
@keyframes mouth-animate {
  from { opacity: 0.4; }
  to { opacity: 1; }
}

.arm-left {
  animation: arm-left-swing 3s ease-in-out infinite;
  transform-origin: top center;
  transform-box: fill-box;
}
@keyframes arm-left-swing {
  0%, 100% { transform: rotate(-5deg); }
  50% { transform: rotate(5deg); }
}

.arm-right {
  animation: arm-right-swing 3s ease-in-out infinite;
  transform-origin: top center;
  transform-box: fill-box;
}
@keyframes arm-right-swing {
  0%, 100% { transform: rotate(5deg); }
  50% { transform: rotate(-5deg); }
}

/* Keywords */
.kw-container {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}

.kw-bubble {
  position: absolute;
  font-family: var(--font-mono);
  font-size: 11px;
  padding: 5px 12px;
  border-radius: var(--r-full);
  white-space: nowrap;
  animation: kw-float-up 3.5s ease-out forwards;
  pointer-events: none;
}

.kw-bubble.type-skill {
  background: var(--primary-dim);
  border: 1px solid var(--glass-border);
  color: var(--primary);
}
.kw-bubble.type-tech {
  background: var(--accent-dim);
  border: 1px solid rgba(56, 189, 248, 0.3);
  color: var(--accent);
}
.kw-bubble.type-tool {
  background: var(--fuchsia-dim);
  border: 1px solid rgba(232, 121, 249, 0.3);
  color: var(--fuchsia);
}

@keyframes kw-float-up {
  0% { opacity: 0; transform: translateY(20px) scale(0.8); }
  20% { opacity: 1; transform: translateY(0) scale(1); }
  80% { opacity: 1; }
  100% { opacity: 0; transform: translateY(-80px) scale(0.9); }
}

/* Processing Status */
.proc-status-wrap {
  display: flex;
  align-items: center;
  gap: 12px;
  position: relative;
  z-index: 2;
}

.proc-spinner { display: flex; align-items: center; gap: 5px; }

.spinner-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--primary);
  animation: bounce-dot 1.2s ease-in-out infinite;
}
.spinner-dot:nth-child(2) { animation-delay: 0.15s; background: var(--fuchsia); }
.spinner-dot:nth-child(3) { animation-delay: 0.3s; background: var(--accent); }

@keyframes bounce-dot {
  0%, 80%, 100% { transform: scale(0.7); opacity: 0.5; }
  40% { transform: scale(1.2); opacity: 1; }
}

.proc-status-text {
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--text2);
  letter-spacing: 0.04em;
  min-width: 280px;
  text-align: center;
}

/* Progress Bar */
.proc-progress-wrap {
  width: min(480px, 90vw);
  display: flex;
  flex-direction: column;
  gap: 8px;
  position: relative;
  z-index: 2;
}

.proc-progress-track {
  height: 4px;
  background: rgba(167, 139, 250, 0.12);
  border-radius: var(--r-full);
  overflow: hidden;
  position: relative;
}

.proc-fill {
  height: 100%;
  width: 0%;
  border-radius: var(--r-full);
  background: linear-gradient(90deg, var(--primary), var(--fuchsia), var(--accent));
  box-shadow: 0 0 12px var(--primary-glow);
  transition: width 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
}

.proc-fill::after {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  width: 30px;
  height: 100%;
  background: rgba(255, 255, 255, 0.4);
  border-radius: var(--r-full);
  filter: blur(4px);
}

.proc-progress-meta {
  display: flex;
  justify-content: space-between;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text3);
}

#proc-pct { color: var(--primary); }

/* ============================================================
   SCREEN 3: RESULTS
   ============================================================ */

.results-outer {
  flex: 1;
  display: flex;
  flex-direction: column;
  padding: 28px 36px;
  overflow-y: auto;
  max-width: 1280px;
  margin: 0 auto;
  width: 100%;
}

.results-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 28px;
}

.back-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--glass);
  border: 1px solid var(--glass-border);
  border-radius: var(--r-full);
  color: var(--text2);
  font-family: var(--font-body);
  font-size: 13px;
  padding: 8px 18px;
  cursor: pointer;
  transition: var(--transition);
}
.back-btn:hover { border-color: var(--primary); color: var(--primary); }

.results-title-wrap {
  display: flex;
  align-items: center;
  gap: 8px;
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--success);
  letter-spacing: 0.08em;
}

.results-time {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text3);
}

/* Results Grid */
.results-grid {
  display: grid;
  grid-template-columns: 280px 1fr 1fr;
  grid-template-rows: auto auto;
  gap: 18px;
}

.result-card {
  padding: 26px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.card-label {
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.16em;
  color: var(--text3);
  text-transform: uppercase;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Score Card */
.score-card {
  grid-row: 1 / 3;
  align-items: center;
  text-align: center;
}

.score-ring-wrap {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 160px;
  height: 160px;
}

.score-svg { position: absolute; inset: 0; transform: rotate(-90deg); }

.ring-track {
  fill: none;
  stroke: rgba(167, 139, 250, 0.1);
  stroke-width: 10;
}

.ring-prog {
  fill: none;
  stroke-width: 10;
  stroke-linecap: round;
  stroke-dasharray: 352;
  stroke-dashoffset: 352;
  transition: stroke-dashoffset 1.5s cubic-bezier(0.4, 0, 0.2, 1),
              stroke 0.5s ease;
}

.score-inner {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: baseline;
  gap: 2px;
}

.score-num {
  font-family: var(--font-display);
  font-size: 42px;
  font-weight: 700;
  line-height: 1;
  transition: color 0.5s;
}

.score-pct-label {
  font-family: var(--font-mono);
  font-size: 16px;
  color: var(--text2);
}

.score-verdict {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.1em;
  padding: 5px 14px;
  border-radius: var(--r-full);
  font-weight: 700;
}

.verdict-good { background: var(--success-dim); color: var(--success); border: 1px solid rgba(74,222,128,0.3); }
.verdict-mid { background: var(--warning-dim); color: var(--warning); border: 1px solid rgba(251,191,36,0.3); }
.verdict-low { background: var(--danger-dim); color: var(--danger); border: 1px solid rgba(248,113,113,0.3); }

.candidate-chip {
  display: flex;
  align-items: center;
  gap: 7px;
  background: var(--primary-dim);
  border: 1px solid var(--glass-border);
  border-radius: var(--r-full);
  padding: 6px 14px;
  font-size: 13px;
  color: var(--text);
  font-weight: 500;
  max-width: 200px;
}

/* Skills Card */
.skills-card { grid-column: 2 / 3; }

.skills-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.skill-tag {
  font-family: var(--font-mono);
  font-size: 11px;
  padding: 5px 12px;
  border-radius: var(--r-full);
  background: var(--danger-dim);
  border: 1px solid rgba(248, 113, 113, 0.25);
  color: var(--danger);
  animation: tag-appear 0.3s ease-out both;
}

@keyframes tag-appear {
  from { opacity: 0; transform: scale(0.85) translateY(4px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}

.skills-note {
  font-size: 12px;
  color: var(--text3);
  font-style: italic;
  margin-top: 4px;
}

/* Summary Card */
.summary-card { grid-column: 3 / 4; }

.summary-body {
  flex: 1;
  font-size: 14px;
  line-height: 1.8;
  color: var(--text2);
  font-weight: 300;
}

.summary-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 12px;
  border-top: 1px solid var(--glass-border);
}

.model-badge {
  display: flex;
  align-items: center;
  gap: 6px;
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--accent);
  letter-spacing: 0.06em;
}

.timestamp {
  font-family: var(--font-mono);
  font-size: 10px;
  color: var(--text3);
}

/* Debug Card */
.debug-card { grid-column: 2 / 4; }

.debug-toggle {
  background: var(--primary-dim);
  border: 1px solid var(--glass-border);
  border-radius: var(--r-sm);
  color: var(--primary);
  font-family: var(--font-mono);
  font-size: 10px;
  padding: 3px 10px;
  cursor: pointer;
  transition: var(--transition);
}
.debug-toggle:hover { background: var(--glass-border); }

.debug-log {
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text3);
  background: rgba(0, 0, 0, 0.4);
  border: 1px solid var(--glass-border);
  border-radius: var(--r-md);
  padding: 14px;
  overflow-x: auto;
  white-space: pre-wrap;
  word-break: break-all;
  line-height: 1.6;
  max-height: 200px;
  overflow-y: auto;
}

.debug-log.hidden { display: none; }

/* ============================================================
   TOASTS
   ============================================================ */

#toast-container {
  position: fixed;
  top: 24px;
  right: 24px;
  z-index: 1000;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.toast {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 18px;
  border-radius: var(--r-md);
  background: var(--glass);
  backdrop-filter: blur(20px);
  border: 1px solid var(--glass-border);
  font-size: 13px;
  color: var(--text);
  min-width: 280px;
  max-width: 420px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
  animation: toast-in 0.35s cubic-bezier(0.34, 1.56, 0.64, 1) both;
}

.toast.removing { animation: toast-out 0.3s ease-in both; }

@keyframes toast-in {
  from { opacity: 0; transform: translateX(30px) scale(0.95); }
  to { opacity: 1; transform: translateX(0) scale(1); }
}
@keyframes toast-out {
  to { opacity: 0; transform: translateX(30px) scale(0.95); }
}

.toast-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}
.toast.success .toast-dot { background: var(--success); box-shadow: 0 0 8px var(--success); }
.toast.error .toast-dot { background: var(--danger); box-shadow: 0 0 8px var(--danger); }
.toast.info .toast-dot { background: var(--primary); box-shadow: 0 0 8px var(--primary); }
.toast.warning .toast-dot { background: var(--warning); box-shadow: 0 0 8px var(--warning); }

/* ============================================================
   RESPONSIVE
   ============================================================ */

@media (max-width: 900px) {
  .navbar { padding: 14px 20px; }
  .upload-main { padding: 24px 20px; }
  .upload-grid { grid-template-columns: 1fr; }
  .results-outer { padding: 20px; }
  .results-grid {
    grid-template-columns: 1fr 1fr;
    grid-template-rows: auto;
  }
  .score-card { grid-row: auto; grid-column: 1 / 3; }
  .skills-card { grid-column: 1 / 2; }
  .summary-card { grid-column: 2 / 3; }
  .debug-card { grid-column: 1 / 3; }
  .nav-center { display: none; }
  .orbit-2, .orbit-3 { display: none; }
}

@media (max-width: 600px) {
  .hero-title { font-size: 24px; }
  .results-grid { grid-template-columns: 1fr; }
  .score-card, .skills-card, .summary-card, .debug-card {
    grid-column: 1;
  }
  .orbit { display: none; }
  .results-topbar { flex-wrap: wrap; gap: 10px; }
}
