/* ═══════════════════════════════════════════════════════════════════
   "Clean" interface for the postcard builder.
   Everything is scoped to html.ui-clean (and light theme), so switching
   back to Classic in Settings removes it completely. No markup changes.
   ═══════════════════════════════════════════════════════════════════ */
html.ui-clean:not([data-theme="dark"]) {
  --navy: #111827;
  --gold: #2563eb;
  --gold-lt: #93c5fd;
  --slate: #4b5563;
  --card-shadow: 0 1px 3px rgba(17, 24, 39, .08);
  --ui-accent: #2563eb;
  --ui-accent-lo: #2563eb;
  --ui-accent-hi: #3b82f6;
}
html.ui-clean:not([data-theme="dark"]) .run-btn#run-btn { background: #2563eb !important; box-shadow: none !important; }
html.ui-clean:not([data-theme="dark"]) .run-btn#run-btn:hover:not(:disabled) { background: #1d4ed8 !important; transform: none; }
html.ui-clean:not([data-theme="dark"]) #sample-ai-btn { background: #374151 !important; box-shadow: none !important; }
html.ui-clean:not([data-theme="dark"]) #sample-raw-btn,
html.ui-clean:not([data-theme="dark"]) label.run-btn[for="upload-ai-house"] { box-shadow: none !important; }
html.ui-clean:not([data-theme="dark"]) .zb-val { color: #2563eb !important; }
html.ui-clean:not([data-theme="dark"]) body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background: #f5f6f8; color: #111827;
}

/* Header: white bar, dark text */
html.ui-clean:not([data-theme="dark"]) header {
  background: #ffffff !important; box-shadow: none !important; border-bottom: 1px solid #e5e7eb; padding: 10px 24px;
}
html.ui-clean:not([data-theme="dark"]) header button,
html.ui-clean:not([data-theme="dark"]) header > a,
html.ui-clean:not([data-theme="dark"]) header #settings-gear-btn {
  color: #374151 !important; border-color: #d1d5db !important; background: #fff !important;
}
html.ui-clean:not([data-theme="dark"]) header button:hover,
html.ui-clean:not([data-theme="dark"]) header > a:hover { background: #f3f4f6 !important; }
html.ui-clean:not([data-theme="dark"]) header .hlogo { border-radius: 6px; }
html.ui-clean:not([data-theme="dark"]) header #scout-link { color: #2563eb !important; border-color: #bfdbfe !important; background: #eff6ff !important; }

/* Page areas */
html.ui-clean:not([data-theme="dark"]) .controls-panel { background: #f5f6f8; border-right: 1px solid #e5e7eb; }
html.ui-clean:not([data-theme="dark"]) .preview-panel { background: #ffffff; }

/* Wizard steps */
html.ui-clean:not([data-theme="dark"]) #wizard-pills { background: #ffffff !important; border: 1px solid #e5e7eb; box-shadow: none; }
html.ui-clean:not([data-theme="dark"]) #wizard-pills .wpill { background: #f3f4f6 !important; color: #374151 !important; font-weight: 600 !important; }
html.ui-clean:not([data-theme="dark"]) #wizard-pills .wpill.active { background: #2563eb !important; color: #fff !important; }

/* Cards */
html.ui-clean:not([data-theme="dark"]) .accordion,
html.ui-clean:not([data-theme="dark"]) .research-panel,
html.ui-clean:not([data-theme="dark"]) .tpl-step,
html.ui-clean:not([data-theme="dark"]) .dl-bar,
html.ui-clean:not([data-theme="dark"]) .steps,
html.ui-clean:not([data-theme="dark"]) .card-wrap {
  border-radius: 8px; box-shadow: none; border: 1px solid #e5e7eb;
}
html.ui-clean:not([data-theme="dark"]) .accordion-body { border-top-color: #e5e7eb; }
html.ui-clean:not([data-theme="dark"]) .card-meta { background: #f9fafb; color: #111827; border-bottom: 1px solid #e5e7eb; }

/* Section labels: sentence-case gray instead of uppercase purple */
html.ui-clean:not([data-theme="dark"]) .sec-label,
html.ui-clean:not([data-theme="dark"]) .log-title,
html.ui-clean:not([data-theme="dark"]) .fp-group-label {
  color: #374151; text-transform: none; letter-spacing: 0; font-size: 13px; font-weight: 600;
}

/* Inputs */
html.ui-clean:not([data-theme="dark"]) input:not([type=checkbox]):not([type=radio]):not([type=range]):not([type=color]),
html.ui-clean:not([data-theme="dark"]) select,
html.ui-clean:not([data-theme="dark"]) textarea { border: 1px solid #d1d5db; border-radius: 6px; }
html.ui-clean:not([data-theme="dark"]) input:focus,
html.ui-clean:not([data-theme="dark"]) select:focus,
html.ui-clean:not([data-theme="dark"]) textarea:focus { border-color: #2563eb; box-shadow: 0 0 0 3px rgba(37, 99, 235, .15); }
html.ui-clean:not([data-theme="dark"]) input[type=checkbox],
html.ui-clean:not([data-theme="dark"]) input[type=range] { accent-color: #2563eb !important; }

/* Buttons */
html.ui-clean:not([data-theme="dark"]) .run-btn { background: #2563eb; border-radius: 8px; box-shadow: none; }
html.ui-clean:not([data-theme="dark"]) .run-btn:hover { background: #1d4ed8; }
html.ui-clean:not([data-theme="dark"]) .dl-btn { background: #2563eb; color: #fff; border-radius: 6px; }
html.ui-clean:not([data-theme="dark"]) .dl-btn.sec { background: #374151; }
html.ui-clean:not([data-theme="dark"]) .research-btn { background: #2563eb; border-radius: 6px; }
html.ui-clean:not([data-theme="dark"]) .mode-tabs { background: #f3f4f6; border: 1px solid #e5e7eb; }
html.ui-clean:not([data-theme="dark"]) .mode-tab.active { background: #2563eb; }
html.ui-clean:not([data-theme="dark"]) .tpl-step-num { background: #2563eb; }
html.ui-clean:not([data-theme="dark"]) .template-card.selected { border-color: #2563eb; background: #eff6ff; box-shadow: 0 0 0 3px rgba(37, 99, 235, .15); }
html.ui-clean:not([data-theme="dark"]) .text-style-btn.active,
html.ui-clean:not([data-theme="dark"]) .t4s-btn.on { background: #2563eb; border-color: #2563eb; }
html.ui-clean:not([data-theme="dark"]) .tpl-dropdown-btn { background: #ffffff; color: #111827; border: 1px solid #d1d5db; }
html.ui-clean:not([data-theme="dark"]) .tpl-dropdown-btn * { color: #111827 !important; }
html.ui-clean:not([data-theme="dark"]) .progress-bar { background: #2563eb; }

/* Common inline purple accents → standard blue */
html.ui-clean:not([data-theme="dark"]) [style*="background:#7c3aed"],
html.ui-clean:not([data-theme="dark"]) [style*="background: #7c3aed"],
html.ui-clean:not([data-theme="dark"]) [style*="background:#6d28d9"] { background: #2563eb !important; }
html.ui-clean:not([data-theme="dark"]) [style*="color:#7c3aed"],
html.ui-clean:not([data-theme="dark"]) [style*="color:#a855f7"],
html.ui-clean:not([data-theme="dark"]) [style*="color:#6d28d9"] { color: #2563eb !important; }

/* Pipeline log stays dark for readability, just squarer */
html.ui-clean:not([data-theme="dark"]) .log-panel { border-radius: 8px; background: #111827; }
