:root {
  --bg: #0b1220;
  --surface: #121a2b;
  --surface-2: #1c2740;
  --text: #e6edf3;
  --muted: #94a3b8;
  --primary: #4f80ff;
  --accent: #22c55e;
  --border: #25345b;
}

* { box-sizing: border-box; }
html, body { height: 100%; }
body {
  margin: 0; font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial;
  background: linear-gradient(180deg, var(--bg), #0e1627 40%);
  color: var(--text);
}
header, footer { padding: 16px; max-width: 1600px; margin: 0 auto; text-align: center; }
header h1 { margin: 12px 0 6px; }
header p { margin: 0; color: var(--muted); }

main { width: 100%; max-width: none; margin: 0; padding: 16px; }
.wizard { max-width: 1600px; margin: 0 auto; }
.toolbar {
  position: sticky; top: 0; z-index: 1000;
  display: flex; align-items: center; justify-content: space-between;
  background: rgba(18,26,43,0.9);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 10px;
  backdrop-filter: blur(6px);
  margin-bottom: 12px;
}
.toolbar-left { min-height: 24px; display: flex; align-items: center; }
.toolbar-actions { display: flex; gap: 8px; align-items: center; flex-wrap: nowrap; }
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 16px;
  box-shadow: 0 1px 0 rgba(255,255,255,0.05) inset, 0 10px 30px rgba(0,0,0,0.25);
  margin-bottom: 16px;
}
.results-card { min-height: 70vh; }
.hidden { display: none !important; }
.muted { color: var(--muted); }

.dropzone {
  border: 2px dashed var(--border);
  border-radius: 12px;
  padding: 24px;
  text-align: center;
  color: var(--muted);
}
.dropzone.hover { border-color: var(--primary); background: rgba(79,128,255,0.08); }

button {
  background: var(--primary); color: white; border: none; border-radius: 8px;
  padding: 8px 14px; cursor: pointer; font-weight: 600;
}
button:disabled { opacity: 0.6; cursor: not-allowed; }
button.secondary { background: transparent; color: var(--text); border: 1px solid var(--border); }

textarea {
  width: 100%; border-radius: 8px; border: 1px solid var(--border);
  background: var(--surface-2); color: var(--text);
  padding: 12px; resize: vertical;
}

.actions { display: flex; gap: 8px; align-items: center; margin-top: 8px; flex-wrap: nowrap; }
.actions.split { justify-content: space-between; }
.actions.split .btns { display: flex; gap: 8px; align-items: center; flex-wrap: nowrap; }

table { width: 100%; border-collapse: collapse; }
th, td { border-bottom: 1px solid var(--border); padding: 8px; text-align: left; }
th { color: var(--muted); font-weight: 600; }
.val { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }

.code {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 12px;
  overflow: auto;
  max-height: 75vh;
}

footer { color: var(--muted); }

.overlay {
  position: fixed; inset: 0; display: flex; align-items: center; justify-content: center;
  background: rgba(0,0,0,0.35); color: white; font-weight: 700; font-size: 18px; z-index: 9999;
}

/* Stepper */
.stepper { display: flex; gap: 8px; margin: 8px 0 16px; flex-wrap: wrap; }
.stepper .step {
  background: transparent; color: var(--text); border: 1px solid var(--border);
  padding: 6px 10px; border-radius: 999px; cursor: pointer;
}
.stepper .step[disabled] { opacity: 0.5; cursor: not-allowed; }
.stepper .step.active { border-color: var(--primary); box-shadow: 0 0 0 2px rgba(79,128,255,0.25) inset; }
.step-actions { display: flex; gap: 8px; margin-top: 10px; flex-wrap: nowrap; justify-content: flex-end; }
