:root {
  --ink: #1e2a38;
  --paper: #f7f4ee;
  --accent: #c8532b;
  --accent-dark: #a84322;
  --muted: #5c6672;
  --ok: #1f6f43;
  --ok-bg: #e3f2e8;
  --warn: #8a5a10;
  --warn-bg: #fbf0d9;
  --err: #9b2c2c;
  --err-bg: #fbe4e4;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  background: var(--paper);
  color: var(--ink);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 18px;
  line-height: 1.5;
}

.card {
  width: 100%;
  max-width: 30rem;
  background: #ffffff;
  border: 1px solid #e2ddd3;
  border-radius: 10px;
  padding: 2.5rem 2rem;
  box-shadow: 0 2px 12px rgba(30, 42, 56, 0.07);
}

h1 {
  font-size: 1.9rem;
  line-height: 1.2;
  margin: 0 0 0.5rem;
}

.lede {
  color: var(--muted);
  margin: 0 0 1.5rem;
}

form {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

label {
  font-family: system-ui, sans-serif;
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

input {
  font: inherit;
  padding: 0.7rem 0.85rem;
  border: 1px solid #c9c3b7;
  border-radius: 6px;
  background: #fff;
  color: var(--ink);
  width: 100%;
}

input:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

button {
  margin-top: 0.75rem;
  font: inherit;
  font-weight: 700;
  padding: 0.75rem 1rem;
  border: none;
  border-radius: 6px;
  background: var(--accent);
  color: #fff;
  cursor: pointer;
}

button:hover { background: var(--accent-dark); }

button:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 2px;
}

button:disabled { opacity: 0.6; cursor: wait; }

.message {
  margin: 1.25rem 0 0;
  padding: 0.75rem 1rem;
  border-radius: 6px;
  font-family: system-ui, sans-serif;
  font-size: 0.95rem;
}

.message.ok   { background: var(--ok-bg);   color: var(--ok); }
.message.dup  { background: var(--warn-bg); color: var(--warn); }
.message.err  { background: var(--err-bg);  color: var(--err); }

@media (max-width: 480px) {
  .card { padding: 1.75rem 1.25rem; }
  body { font-size: 16px; }
}
