:root {
  color-scheme: light dark;
  --bg: #0f1115;
  --card: #171a21;
  --border: #2a2f3a;
  --text: #e8eaed;
  --muted: #8b93a1;
  --accent: #4f8cff;
  --accent-hover: #6ea0ff;
  --ok: #35c46b;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: var(--bg);
  color: var(--text);
}

.card {
  width: 100%;
  max-width: 420px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 28px 24px;
}

h1 {
  margin: 0 0 4px;
  font-size: 1.4rem;
}

.hint {
  margin: 0 0 20px;
  color: var(--muted);
  font-size: 0.9rem;
}

form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

input[type="email"], input[type="text"] {
  width: 100%;
  font-size: 1rem;
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: #0f1115;
  color: var(--text);
}

input[type="email"]:focus, input[type="text"]:focus {
  outline: 2px solid var(--accent);
  outline-offset: 1px;
}

button {
  font-size: 1rem;
  font-weight: 600;
  padding: 12px 16px;
  border-radius: 10px;
  border: none;
  cursor: pointer;
  background: var(--accent);
  color: #fff;
  transition: background 0.15s ease;
}

button:hover { background: var(--accent-hover); }
button:active { transform: scale(0.98); }
button:disabled { opacity: 0.6; cursor: not-allowed; }

.result {
  margin-top: 20px;
}

.result label {
  display: block;
  font-size: 0.85rem;
  color: var(--muted);
  margin-bottom: 6px;
}

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

#hash-output {
  flex: 1;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.9rem;
  overflow: hidden;
  text-overflow: ellipsis;
}

#copy-btn {
  flex-shrink: 0;
  padding: 12px 18px;
}

#copy-btn.copied { background: var(--ok); }

.error {
  margin-top: 16px;
  color: #ff6b6b;
  font-size: 0.9rem;
}

@media (max-width: 400px) {
  .card { padding: 22px 18px; }
}
