:root {
  --nf-bg: #070c19;
  --nf-surface: #111b2f;
  --nf-surface2: #1a2740;
  --nf-border: #2b3a56;
  --nf-text: #e5e7eb;
  --nf-muted: #9ca3af;
  --nf-blue: #60a5fa;
  --nf-green: #22c55e;
  --nf-red: #ef4444;
  --nf-yellow: #f59e0b;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; height: 100%; }
body { background: var(--nf-bg); color: var(--nf-text); font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif; }

.app-shell { min-height: 100vh; display: flex; flex-direction: column; }
.app-header {
  height: 56px;
  padding: 0 16px;
  border-bottom: 1px solid var(--nf-border);
  background: var(--nf-surface);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.brand { display: flex; gap: 10px; align-items: center; }
.brand img { width: 24px; height: 24px; object-fit: contain; }
.subtitle { color: var(--nf-muted); font-size: 12px; }

.header-controls { display: flex; align-items: center; gap: 10px; }
.btn {
  border: 1px solid var(--nf-border);
  border-radius: 8px;
  background: var(--nf-surface2);
  color: var(--nf-text);
  padding: 8px 12px;
  cursor: pointer;
}
.btn i { width: 14px; height: 14px; margin-right: 6px; vertical-align: middle; }
.btn-primary { border-color: #1d4ed8; background: #1d4ed8; }
.btn-success { border-color: #15803d; background: #15803d; }
.btn-danger { border-color: #b91c1c; background: #b91c1c; }
.btn-secondary { border-color: #475569; background: #334155; }

.tabs {
  display: flex;
  gap: 8px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--nf-border);
  background: rgba(17, 27, 47, 0.6);
}
.tab {
  border: 1px solid var(--nf-border);
  background: var(--nf-surface);
  color: var(--nf-muted);
  padding: 8px 12px;
  border-radius: 8px;
  cursor: pointer;
}

.drops-intro {
  color: var(--nf-muted);
  font-size: 13px;
  line-height: 1.45;
  margin: 0 0 12px;
}

.drop-row {
  border: 1px solid var(--nf-border);
  border-radius: 10px;
  padding: 12px 14px;
  background: var(--nf-surface2);
  margin-bottom: 10px;
}

.drop-row h4 {
  margin: 0 0 8px;
  font-size: 15px;
  font-weight: 600;
}

.drop-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  font-size: 12px;
  color: var(--nf-muted);
  margin-bottom: 8px;
}

.drop-meta code {
  font-size: 11px;
  background: var(--nf-bg);
  padding: 2px 6px;
  border-radius: 4px;
  color: var(--nf-yellow);
}

.drop-detail {
  font-size: 12px;
  color: var(--nf-text);
  white-space: pre-wrap;
  word-break: break-word;
  max-height: 120px;
  overflow: auto;
  margin: 0;
  padding: 8px;
  background: var(--nf-bg);
  border-radius: 6px;
  border: 1px solid var(--nf-border);
}

.drop-explain {
  margin: 0 0 12px;
  font-size: 13px;
  line-height: 1.5;
  color: var(--nf-text);
}

.drop-explain p {
  margin: 0 0 8px;
}

.drop-explain__when {
  color: var(--nf-muted);
  font-size: 12px;
}

.drop-explain__extra {
  margin-top: 8px;
}

.drop-detail-list {
  margin: 6px 0 0;
  padding-left: 18px;
  color: var(--nf-muted);
  font-size: 12px;
}

.drop-codes {
  display: inline-block;
}

.drop-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 14px;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--nf-border);
}

.drop-actions-hint {
  font-size: 12px;
  color: var(--nf-muted);
  max-width: 420px;
  line-height: 1.4;
}
.tab.active { color: var(--nf-blue); border-color: var(--nf-blue); }

.ingestion-banner {
  margin: 0 18px;
  padding: 10px 14px;
  border-radius: 8px;
  border: 1px solid var(--nf-border);
  font-size: 13px;
  line-height: 1.45;
  color: var(--nf-text);
  background: var(--nf-surface2);
}
.ingestion-banner--info { border-color: var(--nf-blue); color: #dbeafe; }
.ingestion-banner--success { border-color: var(--nf-green); color: #bbf7d0; }
.ingestion-banner--error { border-color: var(--nf-red); color: #fecaca; }
.ingestion-banner--warn { border-color: var(--nf-yellow); color: #fde68a; }

.app-body { padding: 18px; display: flex; flex-direction: column; gap: 16px; }
.view { display: none; }
.view.active { display: block; }

.status-card, .card {
  background: var(--nf-surface);
  border: 1px solid var(--nf-border);
  border-radius: 12px;
  padding: 14px;
  margin-bottom: 14px;
}
.card-title { font-size: 14px; font-weight: 600; margin-bottom: 10px; }

.source-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 10px;
  margin-bottom: 14px;
}
.source-card {
  border: 1px solid var(--nf-border);
  background: var(--nf-surface2);
  border-radius: 10px;
  padding: 10px;
}
.source-card .source-name { font-size: 13px; font-weight: 600; }
.source-card .source-meta { font-size: 12px; color: var(--nf-muted); margin-top: 6px; }

.list-stack { display: flex; flex-direction: column; gap: 10px; }
.news-item {
  border: 1px solid var(--nf-border);
  border-radius: 10px;
  background: #0d1424;
  padding: 12px;
}
.news-item h4 { margin: 0 0 8px 0; font-size: 16px; }
.news-meta { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin-bottom: 8px; font-size: 12px; color: var(--nf-muted); }
.badge {
  padding: 2px 8px;
  border-radius: 999px;
  border: 1px solid var(--nf-border);
  font-size: 11px;
}
.rank-5, .rank-4 { color: var(--nf-green); border-color: rgba(34, 197, 94, 0.5); }
.rank-3 { color: var(--nf-yellow); border-color: rgba(245, 158, 11, 0.5); }
.rank-2, .rank-1 { color: var(--nf-red); border-color: rgba(239, 68, 68, 0.5); }

.cat-rumour { color: var(--nf-yellow); border-color: rgba(245, 158, 11, 0.5); }
.cat-financial_signal { color: var(--nf-blue); border-color: rgba(96, 165, 250, 0.5); }
.research-ok { color: var(--nf-green); border-color: rgba(34, 197, 94, 0.5); }
.research-fail { color: var(--nf-red); border-color: rgba(239, 68, 68, 0.5); }
.region-us, .region-eu, .region-apac, .region-mena, .region-latam, .region-oce, .region-global {
  color: var(--nf-muted);
  border-color: var(--nf-border);
}

.itemtype { color: var(--nf-text); border-color: rgba(148, 163, 184, 0.45); }
.itemtype-regulatory { color: var(--nf-blue); border-color: rgba(96, 165, 250, 0.5); }
.itemtype-defense_procurement { color: var(--nf-red); border-color: rgba(239, 68, 68, 0.5); }
.itemtype-launch_ops { color: var(--nf-yellow); border-color: rgba(245, 158, 11, 0.5); }
.itemtype-capital_markets { color: var(--nf-green); border-color: rgba(34, 197, 94, 0.5); }
.itemtype-m_and_a { color: var(--nf-blue); border-color: rgba(96, 165, 250, 0.5); }
.itemtype-technology { color: var(--nf-text); border-color: rgba(148, 163, 184, 0.45); }
.itemtype-geopolitical { color: var(--nf-red); border-color: rgba(239, 68, 68, 0.5); }
.itemtype-corporate { color: var(--nf-text); border-color: rgba(148, 163, 184, 0.45); }

.event-status--scheduled { color: var(--nf-blue); border-color: rgba(96, 165, 250, 0.5); }
.event-status--attempted { color: var(--nf-yellow); border-color: rgba(245, 158, 11, 0.6); }
.event-status--failed { color: var(--nf-red); border-color: rgba(239, 68, 68, 0.6); }
.event-status--pending { color: var(--nf-muted); border-color: var(--nf-border); }

.window-adjacent {
  color: var(--nf-yellow);
  border-color: rgba(245, 158, 11, 0.6);
  background: rgba(245, 158, 11, 0.08);
}

.news-meta__regid,
.news-meta__eventdate {
  font-size: 11px;
  color: var(--nf-muted);
}
.news-meta__regid {
  font-family: ui-monospace, "SF Mono", Menlo, monospace;
}
.news-meta__regid-label {
  color: var(--nf-text);
  font-family: var(--nf-font-sans, inherit);
  margin-right: 4px;
}

.actions { display: flex; gap: 8px; margin-top: 10px; }
.actions .btn { padding: 6px 10px; font-size: 12px; }

.news-image {
  width: 100%;
  max-height: 260px;
  object-fit: cover;
  border: 1px solid var(--nf-border);
  border-radius: 8px;
  background: #0a101d;
  margin: 8px 0 10px;
}
.news-image--empty {
  width: 100%;
  border: 1px dashed var(--nf-border);
  border-radius: 8px;
  padding: 10px;
  margin: 8px 0 10px;
  font-size: 12px;
  color: var(--nf-muted);
  text-align: center;
}

.prepublish-editor {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 10px;
  padding-bottom: 10px;
  border-bottom: 1px dashed var(--nf-border);
}
.prepublish-field {
  display: flex;
  flex-direction: column;
  gap: 4px;
  font-size: 11px;
  color: var(--nf-muted);
}
.prepublish-input,
.prepublish-textarea {
  width: 100%;
  border: 1px solid var(--nf-border);
  border-radius: 8px;
  background: #0b1323;
  color: var(--nf-text);
  padding: 8px 10px;
  font-size: 13px;
  font-family: inherit;
}
.prepublish-input--title {
  font-size: 15px;
  font-weight: 600;
}
.prepublish-textarea { resize: vertical; min-height: 72px; line-height: 1.45; }
.prepublish-editor-hint {
  margin: 0;
  font-size: 11px;
  color: var(--nf-muted);
  line-height: 1.4;
}
.prepublish-editor-hint code {
  font-size: 10px;
  background: var(--nf-surface2);
  padding: 1px 4px;
  border-radius: 4px;
}

.prepublish-controls {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px dashed var(--nf-border);
}
.prepublish-meta {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-bottom: 8px;
}
.upload-dropzone {
  margin-top: 8px;
  border: 1px dashed var(--nf-border);
  border-radius: 8px;
  padding: 10px;
  font-size: 12px;
  color: var(--nf-muted);
}
.upload-dropzone--over {
  border-color: var(--nf-blue);
  background: rgba(29, 78, 216, 0.12);
  color: #dbeafe;
}
.hidden-upload-input { display: none; }

.manual-form { display: flex; flex-direction: column; gap: 10px; }
.manual-form label { display: flex; flex-direction: column; gap: 4px; font-size: 12px; color: var(--nf-muted); }
.manual-form input, .manual-form textarea {
  border: 1px solid var(--nf-border);
  border-radius: 8px;
  background: #0b1323;
  color: var(--nf-text);
  padding: 8px;
}

a { color: #93c5fd; }

.source-link-wrap { display: inline-flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.source-url-line {
  width: 100%;
  font-size: 11px;
  color: var(--nf-muted);
  word-break: break-all;
  margin-top: 4px;
}
.url-badge {
  font-size: 10px;
  padding: 2px 6px;
  border-radius: 6px;
  border: 1px solid var(--nf-border);
}
.url-badge-ok { border-color: rgba(34, 197, 94, 0.5); color: var(--nf-green); }
.source-broken { color: var(--nf-red); font-size: 12px; }

.ontology-panel {
  margin: 10px 0 8px;
  padding: 10px 12px;
  border-radius: 8px;
  border: 1px solid var(--nf-border);
  background: rgba(26, 39, 64, 0.6);
  font-size: 12px;
}
.ontology-panel.lite { opacity: 0.95; }
.ontology-label { font-size: 10px; text-transform: uppercase; letter-spacing: 0.04em; color: var(--nf-muted); margin-bottom: 6px; }
.ontology-entity { font-weight: 600; color: var(--nf-blue); margin-bottom: 6px; }
.ontology-claim { margin: 0; color: var(--nf-text); line-height: 1.45; }
.ontology-kw { margin-top: 6px; color: var(--nf-muted); font-size: 11px; }
.ontology-meta { margin-top: 6px; color: var(--nf-muted); font-size: 11px; }
.ontology-pending { margin: 10px 0 8px; font-size: 12px; color: var(--nf-muted); font-style: italic; }

/* Epistemic validation block + agents tab */
.validation {
  margin-top: 10px;
  border: 1px solid var(--nf-border);
  border-radius: 8px;
  background: rgba(13, 20, 36, 0.7);
  padding: 8px 10px;
  font-size: 12px;
}
.validation--error { border-color: rgba(239, 68, 68, 0.4); }
.validation-head {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  cursor: pointer;
}
.validation-pill {
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 999px;
  border: 1px solid var(--nf-border);
}
.validation-pill--clean { color: var(--nf-green); border-color: rgba(34, 197, 94, 0.5); }
.validation-pill--issues { color: var(--nf-yellow); border-color: rgba(245, 158, 11, 0.5); }
.validation-pill--rejected { color: var(--nf-red); border-color: rgba(239, 68, 68, 0.5); }
.validation-pill--error { color: var(--nf-red); border-color: rgba(239, 68, 68, 0.5); }
.validation-headline { color: var(--nf-text); }
.validation-meta, .validation-ranat { color: var(--nf-muted); font-size: 11px; }
.validation-toggle { margin-left: auto; color: var(--nf-blue); font-size: 11px; }
.validation-spinner { color: var(--nf-yellow); font-size: 11px; }
.validation-body { margin-top: 8px; display: flex; flex-direction: column; gap: 8px; }
.validation-body--error { color: var(--nf-red); }
.validation-url, .validation-greeks { margin: 0; }
.validation-finding {
  border-left: 3px solid var(--nf-border);
  padding: 6px 8px;
  background: rgba(26, 39, 64, 0.5);
  border-radius: 4px;
}
.validation-finding--must_fix { border-left-color: var(--nf-red); }
.validation-finding--should_fix { border-left-color: var(--nf-yellow); }
.validation-finding--soft { border-left-color: var(--nf-blue); }
.validation-finding--verified_clean { border-left-color: var(--nf-green); }
.validation-finding__head { display: flex; gap: 8px; margin-bottom: 4px; }
.validation-finding__sev { font-weight: 600; text-transform: capitalize; }
.validation-finding__claim, .validation-finding__issue, .validation-fix { margin: 4px 0; }
.validation-evidence {
  list-style: none;
  padding: 0;
  margin: 4px 0 0 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
  font-size: 11px;
}
.validation-evidence li { word-break: break-all; }
.validation-evidence .evidence-meta { color: var(--nf-muted); margin-left: 6px; }
.validation-clean ul {
  margin: 4px 0 0 16px;
  padding: 0;
}
.validation-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 4px;
}
.validation-actions__hint {
  color: var(--nf-muted);
  font-size: 11px;
}
.validation-empty { color: var(--nf-muted); margin: 0; }
.prepublish-validate {
  display: flex;
  gap: 10px;
  align-items: center;
  margin-top: 10px;
}
.prepublish-validate__hint { color: var(--nf-muted); font-size: 11px; }

.agents-intro { color: var(--nf-muted); font-size: 12px; margin: 0 0 10px 0; }
.agents-loading { color: var(--nf-muted); font-style: italic; }

/* Editorial performance ledger panel (lives at the top of the Agents tab). */
.performance-panel { display: flex; flex-direction: column; gap: 14px; }
.perf-totals {
  display: flex; flex-wrap: wrap; gap: 10px;
  padding: 10px 12px;
  background: rgba(15, 23, 42, 0.4);
  border: 1px solid var(--nf-border);
  border-radius: 8px;
  font-size: 12px;
}
.perf-stat { color: var(--nf-text); }
.perf-stat__num { color: var(--nf-blue); font-weight: 600; margin-right: 4px; }
.perf-stat--dim { color: var(--nf-muted); margin-left: auto; }

.perf-section {
  border: 1px solid var(--nf-border);
  border-radius: 8px;
  padding: 10px 12px;
  background: rgba(15, 23, 42, 0.25);
}
.perf-section__title {
  font-weight: 600;
  font-size: 13px;
  color: var(--nf-text);
  margin-bottom: 6px;
}

.perf-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
}
.perf-table th, .perf-table td {
  padding: 4px 8px;
  text-align: left;
  border-bottom: 1px solid rgba(148, 163, 184, 0.15);
}
.perf-table th { color: var(--nf-muted); font-weight: 500; }
.perf-cell--right { text-align: right; font-variant-numeric: tabular-nums; }
.perf-pct { font-weight: 600; }
.perf-row--up .perf-pct { color: var(--nf-green); }
.perf-row--down .perf-pct { color: var(--nf-red); }
.perf-row--flat .perf-pct { color: var(--nf-yellow); }

.perf-rejection-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 6px; }
.perf-rejection {
  border: 1px solid var(--nf-border);
  border-radius: 6px;
  padding: 6px 8px;
  background: rgba(15, 23, 42, 0.35);
}
.perf-rejection__head {
  display: flex; align-items: center; gap: 8px; flex-wrap: wrap;
  font-size: 11px; color: var(--nf-muted);
}
.perf-rejection__source { color: var(--nf-text); font-weight: 500; }
.perf-rejection__rank { font-variant-numeric: tabular-nums; }
.perf-rejection__date { margin-left: auto; }
.perf-rejection__headline { color: var(--nf-text); font-size: 12px; margin-top: 4px; }
.agent-card {
  border: 1px solid var(--nf-border);
  border-radius: 10px;
  background: #0d1424;
  padding: 12px;
}
.agent-head { display: flex; gap: 12px; align-items: flex-start; cursor: pointer; }
.agent-head__main { flex: 1; }
.agent-name { margin: 0; font-size: 15px; }
.agent-purpose { margin: 6px 0; color: var(--nf-text); line-height: 1.45; font-size: 13px; }
.agent-meta { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; font-size: 11px; color: var(--nf-muted); }
.agent-pill { padding: 2px 8px; border-radius: 999px; border: 1px solid var(--nf-border); font-size: 11px; }
.agent-pill--aligned { color: var(--nf-blue); border-color: rgba(96, 165, 250, 0.5); }
.agent-pill--cross-cutting { color: var(--nf-yellow); border-color: rgba(245, 158, 11, 0.5); }
.agent-pill--coordinating { color: var(--nf-green); border-color: rgba(34, 197, 94, 0.5); }
.agent-pill--active { color: var(--nf-green); border-color: rgba(34, 197, 94, 0.5); }
.agent-pill--disabled { color: var(--nf-muted); }
.agent-aligned { color: var(--nf-muted); }
.agent-greeks { display: inline-flex; gap: 4px; }
.agent-greek {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 10px;
  border: 1px solid var(--nf-border);
  border-radius: 4px;
  padding: 0 4px;
}
.agent-source { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 11px; }
.agent-toggle { padding: 4px 10px; font-size: 11px; align-self: flex-start; }
.agent-body { margin-top: 12px; display: flex; flex-direction: column; gap: 12px; }
.agent-section { background: rgba(26, 39, 64, 0.6); border-radius: 8px; padding: 8px 10px; }
.agent-section__title {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--nf-muted);
  margin-bottom: 4px;
}
.agent-section__body {
  margin: 0;
  white-space: pre-wrap;
  word-wrap: break-word;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 12px;
  line-height: 1.45;
  color: var(--nf-text);
  max-height: 360px;
  overflow: auto;
}
.agent-settings {
  width: 100%;
  font-size: 12px;
  border-collapse: collapse;
}
.agent-settings td { padding: 3px 6px; border-bottom: 1px solid var(--nf-border); vertical-align: top; }
.agent-settings td:first-child { color: var(--nf-muted); width: 40%; font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 11px; }
.agent-section--io { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.agent-section--io ul { margin: 4px 0 0 16px; padding: 0; font-size: 12px; }

/* Image editing zone (Unsplash / article / upload) */
.image-zone {
  border: 1px solid var(--nf-border);
  border-radius: 10px;
  background: rgba(13, 20, 36, 0.5);
  padding: 12px;
  margin-top: 10px;
}
.image-zone__head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
}
.image-zone__title { font-weight: 600; font-size: 13px; }
.image-zone__current { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; font-size: 11px; }
.image-zone__credit { color: var(--nf-muted); }
.image-zone__credit a { color: #93c5fd; }
.badge-unsplash { color: var(--nf-blue); border-color: rgba(96, 165, 250, 0.5); }
.badge-upload { color: var(--nf-yellow); border-color: rgba(245, 158, 11, 0.5); }
.badge-article { color: var(--nf-green); border-color: rgba(34, 197, 94, 0.5); }
.image-zone__tabs {
  display: flex;
  gap: 4px;
  border-bottom: 1px solid var(--nf-border);
  margin-bottom: 10px;
  flex-wrap: wrap;
}
.image-zone__tab {
  background: transparent;
  border: 1px solid transparent;
  border-bottom: none;
  color: var(--nf-muted);
  padding: 6px 12px;
  border-radius: 6px 6px 0 0;
  font-size: 12px;
  cursor: pointer;
}
.image-zone__tab:hover { color: var(--nf-text); }
.image-zone__tab.is-active {
  color: var(--nf-text);
  background: #0d1424;
  border-color: var(--nf-border);
  border-bottom-color: #0d1424;
  position: relative;
  top: 1px;
}
.image-zone__panel { padding: 4px 0 0 0; }

/* Unsplash panel */
.unsplash-search-form { display: flex; gap: 8px; align-items: center; margin-bottom: 10px; }
.unsplash-search-input {
  flex: 1;
  border: 1px solid var(--nf-border);
  border-radius: 8px;
  background: #0b1323;
  color: var(--nf-text);
  padding: 8px 10px;
  font-size: 13px;
}
.unsplash-search-input:focus { outline: 2px solid #1d4ed8; outline-offset: 1px; }
.unsplash-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 8px;
  min-height: 100px;
}
.unsplash-tile {
  position: relative;
  border: 2px solid var(--nf-border);
  background: #0b1323;
  padding: 0;
  cursor: pointer;
  border-radius: 8px;
  overflow: hidden;
  display: block;
  transition: border-color 120ms ease, transform 120ms ease;
}
.unsplash-tile:hover { border-color: #1d4ed8; transform: translateY(-1px); }
.unsplash-tile img { width: 100%; height: 110px; object-fit: cover; display: block; }
.unsplash-tile__credit {
  position: absolute;
  left: 0;
  bottom: 0;
  right: 0;
  font-size: 10px;
  padding: 3px 6px;
  background: linear-gradient(180deg, rgba(0,0,0,0) 0%, rgba(0,0,0,0.75) 100%);
  color: #e5e7eb;
  text-align: left;
  pointer-events: none;
}
.unsplash-tile__overlay {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(13, 20, 36, 0.75);
  color: var(--nf-yellow);
  font-size: 12px;
  font-weight: 600;
}
.unsplash-tile--picking { border-color: var(--nf-yellow); }
.unsplash-loading, .unsplash-empty { color: var(--nf-muted); font-size: 12px; padding: 12px; text-align: center; }
.unsplash-error {
  color: var(--nf-red);
  font-size: 12px;
  padding: 8px;
  border-left: 3px solid var(--nf-red);
  background: rgba(239, 68, 68, 0.08);
  margin-bottom: 8px;
  border-radius: 0 6px 6px 0;
}
.unsplash-license { font-size: 11px; color: var(--nf-muted); margin: 8px 0 0 0; }
.unsplash-license a { color: #93c5fd; }

/* Article-source panel */
.source-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: 6px;
  margin-bottom: 8px;
}
.source-tile {
  position: relative;
  border: 2px solid var(--nf-border);
  background: #0b1323;
  border-radius: 6px;
  overflow: hidden;
  padding: 0;
  cursor: pointer;
}
.source-tile:hover { border-color: #1d4ed8; }
.source-tile img { width: 100%; height: 80px; object-fit: cover; display: block; }
.source-tile--active { border-color: var(--nf-green); }
.source-tile__index {
  position: absolute;
  top: 4px;
  left: 4px;
  font-size: 10px;
  padding: 1px 5px;
  background: rgba(0,0,0,0.7);
  color: #e5e7eb;
  border-radius: 4px;
}
.source-empty { color: var(--nf-muted); font-size: 12px; }

/* Upload panel */
.upload-panel .upload-dropzone { padding: 16px; text-align: center; }
.upload-hint { font-size: 11px; color: var(--nf-muted); margin: 8px 0 0 0; }

.prepublish-publish-row { justify-content: flex-end; margin-top: 6px; }

