:root {
  --bg: #ffffff;
  --text: #000000;
  --border: #000000;
  --hover: #f5f5f5;
  --active: #e0e0e0;
  --input-bg: #ffffff;
  --error: #cc0000;
}
body.dark,
html.dark body {
  --bg: #121212;
  --text: #e0e0e0;
  --border: #555555;
  --hover: #1e1e1e;
  --active: #2a2a2a;
  --input-bg: #1e1e1e;
  --error: #ff4444;
}

* { box-sizing: border-box; }

body {
  font-family: monospace;
  background: var(--bg);
  color: var(--text);
  margin: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100vh;
}

.box {
  border: 1px solid var(--border);
  padding: 32px;
  width: 320px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.box h1 {
  margin: 0;
  font-size: 15px;
  font-weight: bold;
}
.box input {
  width: 100%;
  border: 1px solid var(--border);
  background: var(--input-bg);
  color: var(--text);
  padding: 8px;
  font-family: monospace;
  font-size: 14px;
  outline: none;
}
.box input:focus {
  background: var(--active);
}

.btn {
  border: 1px solid var(--border);
  background: var(--text);
  color: var(--bg);
  padding: 8px;
  cursor: pointer;
  font-family: monospace;
  font-size: 14px;
  width: 100%;
}
.btn:hover { opacity: 0.85; }
.btn:disabled { opacity: 0.4; cursor: not-allowed; }

.error {
  color: var(--error);
  font-size: 12px;
  min-height: 16px;
}
.hint {
  font-size: 11px;
  opacity: 0.5;
}