:root {
  --bg: #f4f5f7; --card: #ffffff; --text: #1d2330; --muted: #646b7a; --border: #d9dce3;
  --accent: #2456d6; --accent-text: #ffffff; --error: #b42318; --code: #eef0f4;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #14161b; --card: #1d2028; --text: #e6e8ee; --muted: #9aa1b0; --border: #333846;
    --accent: #6b93ff; --accent-text: #0d1117; --error: #ff8a80; --code: #282c36;
  }
}
* { box-sizing: border-box; }
body {
  margin: 0; min-height: 100vh; display: flex; align-items: flex-start; justify-content: center;
  background: var(--bg); color: var(--text); padding: 48px 16px;
  font: 15px/1.5 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}
.card { width: 100%; max-width: 400px; background: var(--card); border: 1px solid var(--border); border-radius: 10px; padding: 28px; }
.card.wide { max-width: 620px; }
header { margin-bottom: 18px; }
.brand { font-weight: 600; color: var(--muted); letter-spacing: .02em; }
h1 { font-size: 1.35rem; margin: 0 0 8px; }
h2 { font-size: 1.05rem; margin: 0 0 10px; }
section { border-top: 1px solid var(--border); margin-top: 22px; padding-top: 18px; }
label { display: block; margin: 12px 0; font-weight: 500; }
input {
  display: block; width: 100%; margin-top: 4px; padding: 9px 11px; font: inherit; color: var(--text);
  background: var(--bg); border: 1px solid var(--border); border-radius: 6px;
}
button {
  width: 100%; margin-top: 10px; padding: 10px 14px; font: inherit; font-weight: 600; cursor: pointer;
  color: var(--text); background: var(--card); border: 1px solid var(--border); border-radius: 6px;
}
button.primary { background: var(--accent); color: var(--accent-text); border-color: var(--accent); }
button.link { width: auto; margin: 0; border: 0; background: none; color: var(--accent); padding: 0; font-weight: 500; }
button:disabled { opacity: .55; cursor: default; }
a { color: var(--accent); }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.error { color: var(--error); }
.row { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
.inline { display: flex; gap: 8px; align-items: center; }
.inline input { margin: 0; }
.inline button { width: auto; margin: 0; white-space: nowrap; }
.choices { margin-top: 8px; align-items: stretch; }
.choices button { flex: 1; white-space: normal; display: flex; flex-direction: column; gap: 2px; font-weight: 600; }
.choices button span { font-weight: 400; }
.divider { display: flex; align-items: center; gap: 10px; color: var(--muted); margin: 18px 0 4px; font-size: 13px; }
.divider::before, .divider::after { content: ""; flex: 1; border-top: 1px solid var(--border); }
dl { display: grid; grid-template-columns: max-content 1fr; gap: 4px 16px; margin: 8px 0 0; }
dt { color: var(--muted); }
dd { margin: 0; overflow-wrap: anywhere; }
dl.keyinfo { margin: 6px 0 4px; padding: 10px 12px; border: 1px solid var(--border); border-radius: 6px; background: var(--bg); }
ul.plain { list-style: none; padding: 0; margin: 0 0 10px; }
ul.plain li { padding: 4px 0; }
pre.snippet {
  margin: 6px 0 0; padding: 12px 14px; background: var(--code); border: 1px solid var(--border); border-radius: 6px;
  font: 12px/1.45 ui-monospace, SFMono-Regular, Menlo, monospace; white-space: pre; overflow-x: auto;
  user-select: all; -webkit-user-select: all;
}
code { background: var(--code); padding: 1px 5px; border-radius: 4px; font-size: 13px; }
[hidden] { display: none !important; }
@media (max-width: 480px) { .card { padding: 20px; } .inline { flex-direction: column; align-items: stretch; } .inline button { width: 100%; } }
