:root {
  --bg-deep: #070d1f;
  --bg-card: #101935;
  --bg-input: #0a1126;
  --border: #23325b;
  --gold: #d4af37;
  --gold-bright: #f3c623;
  --text: #eef2ff;
  --muted: #9aa7c7;
  --ok: #22c55e;
  --err: #ef4444;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  background: var(--bg-deep);
  color: var(--text);
  line-height: 1.5;
  padding: 16px;
}

.container {
  max-width: 720px;
  margin: 0 auto;
}

header {
  border-bottom: 1px solid var(--border);
  padding-bottom: 14px;
  margin-bottom: 20px;
}

.brand {
  color: var(--gold-bright);
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

h1 {
  margin: 4px 0 6px;
  font-size: 1.5rem;
}

.subtitle {
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
}

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

.field {
  margin-bottom: 14px;
}

label {
  display: block;
  font-weight: 600;
  margin-bottom: 6px;
  font-size: 0.92rem;
}

input, select {
  width: 100%;
  padding: 10px 12px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: var(--bg-input);
  color: var(--text);
  font-size: 1rem;
}

input:focus, select:focus {
  outline: 2px solid var(--gold);
  border-color: var(--gold);
}

.hint {
  color: var(--muted);
  font-size: 0.8rem;
  margin-top: 4px;
}

.status {
  padding: 10px 12px;
  border-radius: 8px;
  font-size: 0.9rem;
  font-weight: 600;
  margin-bottom: 12px;
}

.status.ok {
  background: rgba(34, 197, 94, 0.14);
  border: 1px solid var(--ok);
  color: #86efac;
}

.status.err {
  background: rgba(239, 68, 68, 0.14);
  border: 1px solid var(--err);
  color: #fca5a5;
}

pre {
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 14px;
  overflow-x: auto;
  font-size: 0.9rem;
  color: #f8fafc;
  direction: ltr;
  text-align: left;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 12px;
}

button {
  flex: 1 1 140px;
  padding: 11px 14px;
  border-radius: 8px;
  border: 1px solid var(--gold);
  background: var(--gold);
  color: #070d1f;
  font-weight: 700;
  font-size: 0.95rem;
  cursor: pointer;
}

button.secondary {
  background: transparent;
  color: var(--gold-bright);
}

button:disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.history-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.history-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  padding: 8px 0;
  border-bottom: 1px solid var(--border);
  font-size: 0.88rem;
}

.history-item:last-child { border-bottom: none; }

footer {
  text-align: center;
  color: var(--muted);
  font-size: 0.78rem;
  margin-top: 18px;
}
