*,
*::before,
*::after {
  box-sizing: border-box;
}

:root {
  color-scheme: dark;
  --bg: #0a0a0a;
  --surface: #161616;
  --border: #2a2a2a;
  --text: #f2f2f2;
  --muted: #8a8a8a;
  --accent: #5b8def;
  --danger: #e85d5d;
  --ok: #5dce8a;
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", system-ui, sans-serif;
}

html,
body {
  margin: 0;
  min-height: 100%;
  background: var(--bg);
  color: var(--text);
}

body {
  padding: max(16px, env(safe-area-inset-top)) 16px max(24px, env(safe-area-inset-bottom));
}

.wrap {
  max-width: 420px;
  margin: 0 auto;
}

h1 {
  font-size: 1.35rem;
  font-weight: 600;
  margin: 0 0 6px;
}

.lead {
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.45;
  margin: 0 0 20px;
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 16px;
  margin-bottom: 14px;
}

.card h2 {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  margin: 0 0 12px;
  font-weight: 600;
}

.status {
  font-size: 0.85rem;
  line-height: 1.4;
  padding: 10px 12px;
  border-radius: 10px;
  background: #111;
  border: 1px solid var(--border);
  margin-bottom: 16px;
}

.status[data-kind="error"] {
  border-color: var(--danger);
  color: #ffb4b4;
}

.status[data-kind="done"] {
  border-color: var(--ok);
  color: #b8f0d0;
}

.status[data-kind="active"] {
  border-color: var(--accent);
  color: #b8d4ff;
}

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

.btn {
  appearance: none;
  border: none;
  border-radius: 10px;
  padding: 12px 16px;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  background: var(--accent);
  color: #fff;
  flex: 1;
  min-width: 120px;
}

.btn:active {
  opacity: 0.85;
}

.btn-secondary {
  background: #2a2a2a;
  color: var(--text);
}

.btn-ghost {
  background: #1e1e1e;
  color: var(--text);
  border: 1px solid var(--border);
  font-weight: 500;
  font-size: 0.8rem;
  text-align: left;
  flex: 1 1 100%;
}

select,
.field input,
.field textarea {
  width: 100%;
  padding: 12px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: #111;
  color: var(--text);
  font-size: 0.95rem;
}

select {
  margin-bottom: 10px;
}

.form {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.field-label {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--muted);
  font-weight: 600;
}

.field-hint {
  font-size: 0.75rem;
  color: var(--muted);
  line-height: 1.4;
}

.field textarea {
  resize: vertical;
  min-height: 72px;
  font-family: inherit;
  line-height: 1.4;
}

.queue-list {
  margin: 12px 0 0;
  padding-left: 1.1rem;
  font-size: 0.8rem;
  color: var(--muted);
  line-height: 1.5;
}

.queue-list li {
  margin-bottom: 4px;
}

.steps {
  margin: 0;
  padding-left: 1.1rem;
  color: var(--muted);
  font-size: 0.85rem;
  line-height: 1.55;
}

.steps li {
  margin-bottom: 6px;
}

.steps strong {
  color: var(--text);
  font-weight: 600;
}

#quick-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.disclaimer {
  font-size: 0.75rem;
  color: var(--muted);
  margin-top: 20px;
  line-height: 1.4;
}
