:root {
  color-scheme: dark;
  --bg: #0b1020;
  --panel: #121935;
  --panel-2: #0f1530;
  --border: #2a3464;
  --text: #e8edff;
  --muted: #9cabd9;
  --accent: #5aa9ff;
  --accent-2: #7ef0c2;
  --danger: #ff7a7a;
}

* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: linear-gradient(180deg, #0b1020 0%, #0d1330 100%);
  color: var(--text);
}
.container { max-width: 1280px; margin: 0 auto; padding: 24px; }
header { margin-bottom: 20px; }
header h1 { margin: 0 0 8px; }
header p { margin: 0; color: var(--muted); }
.grid { display: grid; grid-template-columns: 420px 1fr; gap: 20px; }
.panel {
  background: rgba(18, 25, 53, 0.95);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 18px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.25);
}
.field { margin-bottom: 14px; }
.field.row { display: grid; grid-template-columns: 1fr 140px; gap: 12px; }
label { display: block; margin-bottom: 6px; color: var(--muted); font-size: 14px; }
input, select, textarea, button {
  width: 100%;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--panel-2);
  color: var(--text);
  padding: 12px 14px;
  font: inherit;
}
textarea { resize: vertical; }
.checkbox-row { display: flex; gap: 18px; flex-wrap: wrap; }
.checkbox-row label, .inline-actions { display: flex; align-items: center; gap: 8px; }
.checkbox-row label { margin: 0; }
.checkbox-row input { width: auto; padding: 0; }
.actions { display: flex; gap: 12px; }
.actions.wrap { flex-wrap: wrap; }
.inline-actions { width: 100%; }
.inline-actions select { flex: 1; }
.inline-actions button { width: auto; white-space: nowrap; }
button { cursor: pointer; transition: 0.15s ease; }
button:hover { transform: translateY(-1px); border-color: var(--accent); }
button.primary { background: linear-gradient(135deg, var(--accent), #7c8cff); border: none; }
button.danger { border-color: #7b3030; color: #ffd4d4; }
.hint { margin-top: 14px; color: var(--muted); font-size: 13px; line-height: 1.5; }
.result-panel { display: grid; gap: 14px; }
.result-block h2 { margin: 0 0 10px; font-size: 16px; }
pre {
  margin: 0;
  background: #0a0f22;
  border: 1px solid #1e2853;
  border-radius: 12px;
  padding: 14px;
  min-height: 120px;
  max-height: 320px;
  overflow: auto;
  white-space: pre-wrap;
  word-break: break-word;
}
@media (max-width: 960px) {
  .grid { grid-template-columns: 1fr; }
}
