/* ============================================================
   CineFocus — Charte graphique premium cinéma / photographie
   ============================================================ */

:root {
  /* Couleurs */
  --bg-void:       #0a0a0c;
  --bg-deep:       #0f0f12;
  --bg-panel:      #141418;
  --bg-card:       #1a1a20;
  --bg-elevated:   #1f1f28;
  --bg-hover:      #26262f;
  --border-subtle: rgba(255,255,255,0.06);
  --border-mid:    rgba(255,255,255,0.12);
  --border-strong: rgba(255,255,255,0.22);

  /* Accent */
  --accent:        #e8a030;
  --accent-dim:    rgba(232,160,48,0.15);
  --accent-hover:  #f0b040;
  --accent-glow:   rgba(232,160,48,0.3);
  --accent-blue:   #4d9ef5;
  --accent-green:  #4dbe80;
  --accent-red:    #e05050;

  /* Texte */
  --text-primary:  #f0f0f4;
  --text-secondary:#a0a0b0;
  --text-muted:    #606070;
  --text-accent:   #e8a030;

  /* Layout */
  --header-h:      52px;
  --panel-w:       320px;
  --radius-sm:     4px;
  --radius-md:     8px;
  --radius-lg:     12px;

  /* Typo */
  --font-ui:       'Inter', -apple-system, sans-serif;
  --font-mono:     'JetBrains Mono', 'Courier New', monospace;
  --font-size-xs:  11px;
  --font-size-sm:  12px;
  --font-size-md:  13px;
  --font-size-lg:  15px;

  /* Transitions */
  --transition:    0.18s ease;
}

/* RESET & BASE */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html, body { height: 100%; overflow: hidden; }
body {
  font-family: var(--font-ui);
  font-size: var(--font-size-md);
  background: var(--bg-void);
  color: var(--text-primary);
  -webkit-font-smoothing: antialiased;
  line-height: 1.5;
}
button { cursor: pointer; font-family: inherit; border: none; background: none; color: inherit; }
input, select { font-family: inherit; color: inherit; }
svg { display: block; width: 16px; height: 16px; fill: currentColor; flex-shrink: 0; }

/* ============================================================ LAYOUT */
#app { display: flex; flex-direction: column; height: 100vh; }

/* HEADER */
#app-header {
  display: flex;
  align-items: center;
  height: var(--header-h);
  background: var(--bg-panel);
  border-bottom: 1px solid var(--border-subtle);
  padding: 0 16px;
  gap: 16px;
  flex-shrink: 0;
  z-index: 100;
}
.header-left { display: flex; align-items: center; }
.logo { height: 32px; object-fit: contain; opacity: 0.95; }
.header-nav { display: flex; align-items: center; gap: 4px; margin-left: 12px; }
.nav-btn {
  display: flex; align-items: center; gap: 6px;
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  font-size: var(--font-size-sm);
  font-weight: 500;
  color: var(--text-secondary);
  transition: all var(--transition);
}
.nav-btn:hover { background: var(--bg-hover); color: var(--text-primary); }
.nav-btn.active { background: var(--accent-dim); color: var(--accent); }
.nav-btn svg { width: 14px; height: 14px; }
.header-right { display: flex; align-items: center; gap: 8px; margin-left: auto; }

/* MAIN */
#main-layout {
  display: flex;
  flex: 1;
  overflow: hidden;
  min-height: 0;
}

/* PANNEAU GAUCHE */
#params-panel {
  width: var(--panel-w);
  background: var(--bg-panel);
  border-right: 1px solid var(--border-subtle);
  overflow-y: auto;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
}
#params-panel::-webkit-scrollbar { width: 4px; }
#params-panel::-webkit-scrollbar-track { background: transparent; }
#params-panel::-webkit-scrollbar-thumb { background: var(--border-mid); border-radius: 2px; }

/* Sections */
.panel-section {
  border-bottom: 1px solid var(--border-subtle);
}
.section-header {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 16px;
  cursor: pointer;
  font-size: var(--font-size-sm);
  font-weight: 600;
  color: var(--text-secondary);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  transition: color var(--transition);
  user-select: none;
}
.section-header:hover { color: var(--text-primary); }
.section-header svg { width: 14px; height: 14px; opacity: 0.7; }
.section-toggle {
  margin-left: auto;
  font-size: 10px;
  opacity: 0.5;
  transition: transform var(--transition);
}
.section-toggle.collapsed { transform: rotate(-90deg); }
.section-body { padding: 0 16px 16px; }
.section-body.collapsed { display: none; }

/* Champs */
.field-group { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; }
.field-group:last-child { margin-bottom: 0; }
.field-row { display: flex; gap: 10px; }
.field-row .field-group { flex: 1; }
label {
  font-size: var(--font-size-xs);
  font-weight: 500;
  color: var(--text-secondary);
  letter-spacing: 0.02em;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.field-value {
  font-family: var(--font-mono);
  font-size: var(--font-size-xs);
  color: var(--accent);
  font-weight: 600;
}
.hint {
  font-weight: 400;
  color: var(--text-muted);
  font-size: var(--font-size-xs);
}
.field-unit {
  font-size: var(--font-size-xs);
  color: var(--text-muted);
  align-self: center;
  margin-left: 4px;
}

/* Inputs */
.cf-input {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 7px 10px;
  font-size: var(--font-size-sm);
  color: var(--text-primary);
  width: 100%;
  transition: border-color var(--transition);
  outline: none;
}
.cf-input:focus { border-color: var(--accent); }
.cf-input--sm { padding: 5px 8px; font-size: var(--font-size-xs); }
.cf-select {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  padding: 7px 10px;
  font-size: var(--font-size-sm);
  color: var(--text-primary);
  width: 100%;
  outline: none;
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 10 6'%3E%3Cpath d='M0 0l5 6 5-6z' fill='%23606070'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
  background-size: 8px;
  padding-right: 28px;
}
.cf-select:focus { border-color: var(--accent); }

/* Range */
.cf-range {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 4px;
  background: var(--bg-elevated);
  border-radius: 2px;
  outline: none;
  cursor: pointer;
}
.cf-range::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 14px; height: 14px;
  border-radius: 50%;
  background: var(--accent);
  cursor: pointer;
  box-shadow: 0 0 0 3px var(--accent-dim);
  transition: box-shadow var(--transition);
}
.cf-range::-webkit-slider-thumb:hover { box-shadow: 0 0 0 5px var(--accent-glow); }

/* Focus shortcuts */
.focus-shortcuts { display: flex; gap: 6px; }
.focus-shortcut {
  flex: 1;
  padding: 4px 6px;
  font-size: 10px;
  font-weight: 500;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  color: var(--text-muted);
  background: var(--bg-card);
  transition: all var(--transition);
  text-align: center;
}
.focus-shortcut:hover { border-color: var(--accent); color: var(--accent); }
.focus-shortcut.active { background: var(--accent-dim); border-color: var(--accent); color: var(--accent); }

/* Distance mode toggle */
.distance-mode-toggle { display: flex; gap: 0; margin-bottom: 14px; border-radius: var(--radius-sm); overflow: hidden; border: 1px solid var(--border-subtle); }
.dm-btn { flex: 1; padding: 6px; font-size: var(--font-size-xs); font-weight: 500; color: var(--text-muted); background: var(--bg-card); transition: all var(--transition); }
.dm-btn:not(:last-child) { border-right: 1px solid var(--border-subtle); }
.dm-btn.active { background: var(--accent-dim); color: var(--accent); }

/* CoC hint */
.coc-auto-hint { font-size: var(--font-size-xs); color: var(--text-muted); margin-top: -4px; }

/* Layer cards */
.layer-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  overflow: hidden;
  margin-bottom: 10px;
  transition: border-color var(--transition);
  display: flex;
  flex-direction: row;
}
.layer-card-body {
  flex: 1;
  min-width: 0;
}
.layer-sliders {
  display: none;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px 6px;
  border-left: 1px solid var(--border-subtle);
  min-width: 54px;
}
.layer-card.has-image .layer-sliders { display: flex; }
.layer-slider-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
}
.slider-label {
  font-size: 9px;
  color: var(--text-muted);
  user-select: none;
  line-height: 1;
}
.layer-slider-v {
  writing-mode: vertical-lr;
  direction: rtl;
  -webkit-appearance: slider-vertical;
  appearance: auto;
  height: 70px;
  width: 20px;
  cursor: ns-resize;
  accent-color: var(--accent);
  padding: 0;
}
.layer-card:hover { border-color: var(--border-mid); }
.layer-card.drag-over { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 8%, var(--bg-card)); }
.layer-remove-btn { display: none; background: none; border: none; cursor: pointer; color: var(--text-muted); padding: 2px 4px; border-radius: 3px; line-height: 1; font-size: 14px; }
.layer-remove-btn:hover { color: #e05; background: rgba(220,0,50,.1); }
.layer-card.has-image .layer-remove-btn { display: flex; align-items: center; }
.layer-header {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  border-bottom: 1px solid var(--border-subtle);
}
.layer-icon {
  width: 22px; height: 22px;
  border-radius: 4px;
  display: flex; align-items: center; justify-content: center;
  font-size: 11px; font-weight: 700;
  flex-shrink: 0;
}
.layer-icon--bg  { background: rgba(77,158,245,0.2);  color: var(--accent-blue);  }
.layer-icon--sub { background: rgba(232,160,48,0.2);  color: var(--accent);       }
.layer-icon--fg  { background: rgba(77,190,128,0.2);  color: var(--accent-green); }
.layer-name { font-size: var(--font-size-sm); font-weight: 500; flex: 1; }
.layer-upload-btn {
  cursor: pointer;
  padding: 4px 8px;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-sm);
  font-size: var(--font-size-xs);
  display: flex; align-items: center; gap: 4px;
  transition: all var(--transition);
  color: var(--text-secondary);
}
.layer-upload-btn:hover { border-color: var(--accent); color: var(--accent); }
.layer-upload-btn input { display: none; }
.layer-upload-btn svg { width: 12px; height: 12px; }
.layer-preview {
  height: 72px;
  display: flex; align-items: center; justify-content: center;
  background: var(--bg-elevated);
  position: relative;
  overflow: hidden;
}
.layer-preview img { max-height: 100%; max-width: 100%; object-fit: contain; }
.layer-empty { font-size: var(--font-size-xs); color: var(--text-muted); text-align: center; padding: 8px; }
.layer-dims { padding: 10px 12px 10px; }

/* Info grid */
.info-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.info-item {
  background: var(--bg-card);
  border-radius: var(--radius-sm);
  padding: 8px 10px;
  display: flex; flex-direction: column; gap: 3px;
}
.info-label { font-size: 10px; color: var(--text-muted); letter-spacing: 0.03em; }
.info-val { font-family: var(--font-mono); font-size: var(--font-size-sm); color: var(--text-primary); font-weight: 500; }

/* ============================================================ CANVAS AREA */
#canvas-area {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: var(--bg-deep);
  position: relative;
}

/* Render toolbar */
#render-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 44px;
  padding: 0 12px;
  background: var(--bg-panel);
  border-bottom: 1px solid var(--border-subtle);
  flex-shrink: 0;
  gap: 12px;
}
.toolbar-left, .toolbar-right { display: flex; align-items: center; gap: 6px; }
.toolbar-sep { width: 1px; height: 20px; background: var(--border-subtle); margin: 0 4px; }
.toolbar-label { font-size: var(--font-size-xs); color: var(--text-muted); }
.tool-btn {
  width: 30px; height: 30px;
  display: flex; align-items: center; justify-content: center;
  border-radius: var(--radius-sm);
  color: var(--text-secondary);
  transition: all var(--transition);
}
.tool-btn:hover { background: var(--bg-hover); color: var(--text-primary); }
.tool-btn.active { background: var(--accent-dim); color: var(--accent); }
.view-btn {
  padding: 4px 10px;
  font-size: var(--font-size-xs);
  font-weight: 500;
  color: var(--text-muted);
  border-radius: var(--radius-sm);
  transition: all var(--transition);
}
.view-btn:hover { color: var(--text-primary); }
.view-btn.active { background: var(--accent-dim); color: var(--accent); }

/* Canvas wrapper */
#canvas-wrapper {
  flex: 1;
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
}
#canvas-render-container,
#canvas-schematic-container {
  position: absolute;
  top: 0; bottom: 0; left: 0; right: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: left 0.2s ease, right 0.2s ease;
}
/* Split view */
#canvas-wrapper.split-view #canvas-render-container {
  right: 50%;
}
#canvas-wrapper.split-view #canvas-schematic-container {
  left: 50%;
  border-left: 1px solid var(--border-subtle);
}
#render-canvas, #schematic-canvas {
  max-width: 100%;
  max-height: 100%;
  display: block;
  background: #0a0a0c;
}

/* Empty state */
#canvas-empty-state {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10;
}
.empty-state-content {
  text-align: center;
  max-width: 360px;
  padding: 40px 20px;
}
.empty-icon {
  width: 80px; height: 80px;
  margin: 0 auto 24px;
  color: var(--text-muted);
}
.empty-state-content h2 { font-size: 20px; font-weight: 600; margin-bottom: 12px; color: var(--text-primary); }
.empty-state-content p { color: var(--text-secondary); font-size: var(--font-size-md); margin-bottom: 24px; line-height: 1.6; }

/* Alerts bar */
#alerts-bar {
  min-height: 0;
  flex-shrink: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 0 12px;
  transition: padding var(--transition);
}
#alerts-bar:not(:empty) { padding: 8px 12px; border-top: 1px solid var(--border-subtle); }
.alert-item {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 5px 10px;
  border-radius: var(--radius-sm);
  font-size: var(--font-size-xs);
  font-weight: 500;
}
.alert-item--warn { background: rgba(240,176,64,0.12); color: #f0b040; border: 1px solid rgba(240,176,64,0.25); }
.alert-item--error { background: rgba(224,80,80,0.12); color: #e05050; border: 1px solid rgba(224,80,80,0.25); }
.alert-item--info { background: rgba(77,158,245,0.12); color: var(--accent-blue); border: 1px solid rgba(77,158,245,0.25); }
.alert-item svg { width: 12px; height: 12px; }

/* ============================================================ BUTTONS */
.btn-primary {
  display: flex; align-items: center; gap: 6px;
  padding: 7px 14px;
  background: var(--accent);
  color: #111;
  border-radius: var(--radius-sm);
  font-size: var(--font-size-sm);
  font-weight: 600;
  transition: all var(--transition);
  white-space: nowrap;
}
.btn-primary:hover { background: var(--accent-hover); box-shadow: 0 0 12px var(--accent-glow); }
.btn-primary svg { width: 14px; height: 14px; }
.btn-primary.btn-lg { padding: 10px 20px; font-size: var(--font-size-md); }
.btn-secondary {
  padding: 7px 14px;
  border: 1px solid var(--border-mid);
  border-radius: var(--radius-sm);
  font-size: var(--font-size-sm);
  font-weight: 500;
  color: var(--text-secondary);
  transition: all var(--transition);
}
.btn-secondary:hover { border-color: var(--border-strong); color: var(--text-primary); }
.btn-icon {
  width: 32px; height: 32px;
  display: flex; align-items: center; justify-content: center;
  border-radius: var(--radius-sm);
  color: var(--text-secondary);
  transition: all var(--transition);
}
.btn-icon:hover { background: var(--bg-hover); color: var(--text-primary); }

/* ============================================================ MODALES */
.modal-overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,0.7);
  backdrop-filter: blur(4px);
  z-index: 200;
  display: flex; align-items: center; justify-content: center;
}
.modal-overlay.hidden { display: none; }
.modal {
  background: var(--bg-panel);
  border: 1px solid var(--border-mid);
  border-radius: var(--radius-lg);
  width: 420px;
  max-width: 95vw;
  max-height: 90vh;
  display: flex; flex-direction: column;
  box-shadow: 0 24px 60px rgba(0,0,0,0.6);
}
.modal.hidden { display: none; }
.modal--wide { width: 680px; }
.modal-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px 20px;
  border-bottom: 1px solid var(--border-subtle);
}
.modal-header h3 { font-size: var(--font-size-lg); font-weight: 600; }
.modal-close {
  width: 28px; height: 28px;
  display: flex; align-items: center; justify-content: center;
  border-radius: var(--radius-sm);
  font-size: 16px;
  color: var(--text-muted);
  transition: all var(--transition);
}
.modal-close:hover { background: var(--bg-hover); color: var(--text-primary); }
.modal-body { padding: 20px; overflow-y: auto; flex: 1; }
.modal-footer {
  display: flex; justify-content: flex-end; gap: 10px;
  padding: 14px 20px;
  border-top: 1px solid var(--border-subtle);
}

/* Export options */
.export-options { display: flex; flex-direction: column; gap: 8px; }
.export-option { display: flex; align-items: center; gap: 12px; cursor: pointer; }
.export-option input { display: none; }
.export-option-label {
  flex: 1;
  display: flex; align-items: center; gap: 12px;
  padding: 12px 14px;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  transition: all var(--transition);
}
.export-option input:checked + .export-option-label {
  border-color: var(--accent);
  background: var(--accent-dim);
}
.export-option-label svg { width: 20px; height: 20px; opacity: 0.7; }
.export-option-label span { font-size: var(--font-size-md); font-weight: 500; flex: 1; }
.export-option-label small { font-size: var(--font-size-xs); color: var(--text-muted); }

/* Library */
#library-grid { display: grid; grid-template-columns: repeat(3,1fr); gap: 10px; }
.library-card {
  background: var(--bg-card);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius-md);
  overflow: hidden;
  cursor: pointer;
  transition: all var(--transition);
}
.library-card:hover { border-color: var(--accent); transform: translateY(-2px); }
.library-card-thumb { height: 90px; background: var(--bg-elevated); overflow: hidden; }
.library-card-thumb img { width: 100%; height: 100%; object-fit: cover; }
.library-card-info { padding: 8px 10px; }
.library-card-name { font-size: var(--font-size-sm); font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.library-card-date { font-size: var(--font-size-xs); color: var(--text-muted); }
.library-empty { text-align: center; padding: 40px; color: var(--text-muted); }

/* ============================================================ TOAST */
#toast-container {
  position: fixed;
  bottom: 24px; right: 24px;
  z-index: 300;
  display: flex; flex-direction: column; gap: 8px;
  pointer-events: none;
}
.toast {
  padding: 10px 16px;
  border-radius: var(--radius-md);
  font-size: var(--font-size-sm);
  font-weight: 500;
  box-shadow: 0 8px 24px rgba(0,0,0,0.4);
  pointer-events: auto;
  animation: toast-in 0.25s ease;
  max-width: 320px;
}
.toast--success { background: var(--accent); color: #111; }
.toast--error   { background: var(--accent-red); color: #fff; }
.toast--info    { background: var(--bg-elevated); color: var(--text-primary); border: 1px solid var(--border-mid); }
@keyframes toast-in { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

/* ============================================================ DRAG OVERLAY */
.canvas-drag-handle {
  position: absolute;
  cursor: grab;
  border: 2px solid transparent;
  border-radius: 4px;
  transition: border-color 0.15s;
}
.canvas-drag-handle:hover { border-color: var(--accent); }
.canvas-drag-handle:active { cursor: grabbing; }
.canvas-drag-handle.selected { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent-glow); }

/* ============================================================ SCROLLBAR GLOBAL */
::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--border-mid); border-radius: 3px; }

/* ============================================================ RESPONSIVE */
@media (max-width: 900px) {
  :root { --panel-w: 260px; }
  #info-grid { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  #params-panel { display: none; }
  .header-nav .nav-btn span { display: none; }
}

/* field-group--toggle */
.field-group--toggle { flex-direction: row; align-items: center; gap: 8px; }
.field-group--toggle label { flex: 1; margin: 0; }
.field-group--toggle .cf-input--sm { width: 60px; flex-shrink: 0; }

/* ============================================================ COMPARAISON */
#compare-panel {
  flex: 1;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: var(--bg-deep);
}
#compare-panel.hidden { display: none; }
.compare-layout {
  flex: 1;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  overflow: hidden;
}
.compare-col {
  display: flex;
  flex-direction: column;
  border-right: 1px solid var(--border-subtle);
  overflow: hidden;
}
.compare-col:last-child { border-right: none; }
.compare-col-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  background: var(--bg-panel);
  border-bottom: 1px solid var(--border-subtle);
  font-size: var(--font-size-sm);
  font-weight: 600;
  flex-shrink: 0;
}
.compare-col-header span { color: var(--accent); }
.compare-canvas-wrap {
  flex: 1;
  position: relative;
  overflow: hidden;
  display: flex; align-items: center; justify-content: center;
  background: var(--bg-deep);
}
.compare-canvas-wrap canvas { max-width: 100%; max-height: 100%; display: block; }
.compare-params {
  padding: 10px 14px;
  border-top: 1px solid var(--border-subtle);
  background: var(--bg-panel);
  font-size: var(--font-size-xs);
  color: var(--text-secondary);
  display: flex; flex-wrap: wrap; gap: 8px;
  flex-shrink: 0;
}
.compare-param { display: flex; gap: 4px; }
.compare-param b { color: var(--text-primary); }
.compare-diff-bar {
  padding: 8px 14px;
  background: var(--bg-panel);
  border-top: 1px solid var(--border-subtle);
  display: flex; gap: 16px; align-items: center;
  font-size: var(--font-size-xs);
  color: var(--text-secondary);
  flex-shrink: 0;
}
.compare-diff-item { display: flex; gap: 6px; align-items: center; }
.compare-diff-item b { color: var(--text-primary); font-family: var(--font-mono); }
.compare-diff-item .arrow-up   { color: var(--accent-green); }
.compare-diff-item .arrow-down { color: var(--accent-red); }
.compare-toolbar {
  display: flex; align-items: center; gap: 10px;
  padding: 8px 14px;
  background: var(--bg-panel);
  border-bottom: 1px solid var(--border-subtle);
  flex-shrink: 0;
}
.compare-toolbar .toolbar-label { margin-right: auto; font-size: var(--font-size-sm); font-weight: 500; }

/* Help modal */
#modal-help { width: 460px; }
.help-section { margin-bottom: 16px; }
.help-section h4 { font-size: var(--font-size-sm); font-weight: 600; color: var(--accent); margin-bottom: 8px; }
.help-section p, .help-section li { font-size: var(--font-size-sm); color: var(--text-secondary); line-height: 1.6; }
.help-section ul { padding-left: 16px; }
