:root {
  color-scheme: dark;
  --paper: #14120f;
  --card: #221e18;
  --line: rgba(244, 239, 230, 0.14);
  --ink: #f4efe6;
  --muted: #a39888;
  --accent: #e2a15a;
  --ok: #9dcb96;
  --bad: #e08a78;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100svh;
  background:
    radial-gradient(900px 420px at 50% -10%, rgba(226, 161, 90, 0.16), transparent 60%),
    var(--paper);
  color: var(--ink);
  font-family: "Segoe UI", sans-serif;
  font-weight: 380;
}

.stage {
  width: min(560px, calc(100% - 40px));
  margin: 0 auto;
  padding: 12vh 0 64px;
}

.mark {
  margin: 0 0 18px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  font-size: 12px;
  color: var(--accent);
}

h1 {
  margin: 0;
  font-family: Palatino, "Iowan Old Style", "Palatino Linotype", serif;
  font-weight: 560;
  font-size: clamp(44px, 7vw, 72px);
  letter-spacing: -0.03em;
  line-height: 0.95;
}

.lede {
  max-width: 38ch;
  margin: 18px 0 32px;
  color: var(--muted);
  font-size: 17px;
  line-height: 1.45;
}

label {
  display: block;
  margin-bottom: 8px;
  font-size: 13px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
}

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

input, button {
  font: inherit;
  border-radius: 14px;
}

input {
  flex: 1;
  min-width: 0;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.03);
  color: var(--ink);
  padding: 16px 18px;
  outline: none;
}

input:focus {
  border-color: rgba(226, 161, 90, 0.8);
}

button, .copy {
  border: 0;
  background: var(--accent);
  color: #23180d;
  font-weight: 560;
  cursor: pointer;
  transition: transform 120ms ease-out, background 120ms ease-out;
}

button { padding: 0 18px; }
button:active, .copy:active { transform: scale(0.97); }

.error {
  min-height: 1.2em;
  margin: 10px 0 0;
  color: var(--bad);
}

.result {
  margin-top: 28px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 22px;
  background: var(--card);
}

.status {
  display: flex;
  gap: 12px;
  align-items: center;
}

.status strong { display: block; font-weight: 560; }
.status p { margin: 2px 0 0; color: var(--muted); font-size: 14px; }

.dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--muted);
}
.dot.ok { background: var(--ok); }
.dot.bad { background: var(--bad); }

.links {
  list-style: none;
  margin: 18px 0 0;
  padding: 0;
  display: grid;
  gap: 10px;
}

.links li {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px 12px;
  align-items: center;
  padding-top: 10px;
  border-top: 1px solid var(--line);
}

.links span { display: block; color: var(--muted); font-size: 13px; }
.links strong { font-weight: 560; }
.copy { border-radius: 12px; padding: 10px 14px; }

@media (max-width: 640px) {
  .row, .links li { grid-template-columns: 1fr; display: grid; }
  .row { display: grid; }
  button, .copy { min-height: 48px; }
}

@media (prefers-reduced-motion: reduce) {
  button, .copy { transition: none; }
}
