:root {
  color-scheme: dark;
  --bg: #0b0d10;
  --fg: #f4f1ea;
  --muted: #9aa3ad;
  --accent: #e8c547;
  --error: #ff6b6b;
  --ok: #7dce82;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
  background: var(--bg);
  color: var(--fg);
  font-family: system-ui, -apple-system, "Segoe UI", sans-serif;
}

body {
  display: flex;
  justify-content: center;
  padding: 12px;
}

main {
  width: 100%;
  max-width: 420px;
}

h1 {
  margin: 0 0 8px;
  font-size: 28px;
  letter-spacing: 0.08em;
}

h2 {
  margin: 0 0 8px;
  font-size: 14px;
  letter-spacing: 0.14em;
  color: var(--muted);
}

label {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}

.status {
  margin: 0 0 16px;
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.12em;
}

.status.ready {
  color: var(--ok);
}

.status.thinking {
  color: var(--accent);
}

.status.error {
  color: var(--error);
}

form {
  display: grid;
  gap: 10px;
}

textarea,
button {
  width: 100%;
  font: inherit;
  border-radius: 12px;
}

textarea {
  min-height: 72px;
  padding: 12px;
  border: 1px solid #2a313a;
  background: #14181d;
  color: var(--fg);
  resize: none;
}

button {
  min-height: 48px;
  border: 0;
  background: var(--accent);
  color: #111;
  font-weight: 800;
  letter-spacing: 0.12em;
}

button:disabled {
  opacity: 0.6;
}

#answer-box {
  margin-top: 18px;
}

#answer {
  margin: 0;
  font-size: 20px;
  line-height: 1.35;
  word-break: break-word;
}
