/* CrashTop verifier — flat terminal surface, ink on charcoal, amber action. */

:root {
  --bg: #101112;
  --bg-600: #16171a;
  --well: #1b1c1f;
  --line: #232427;
  --line-strong: #33353a;
  --text: #eceae4;
  --text-dim: #c9c7c1;
  --text-mute: #a3a29e;
  --text-faint: #77766f;
  --accent: #ff6515;
  --accent-ink: #1a0c04;
  --mint: #4ade80;
  --red: #f87171;
  --radius: 4px;
  --font: "IBM Plex Sans", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 14px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

.wrap {
  width: min(920px, 100% - 32px);
  margin: 0 auto;
  padding: 40px 0 64px;
}

/* ---------------- header ---------------- */

.head { margin-bottom: 24px; }

.brand { display: flex; align-items: center; gap: 10px; }

.mark {
  width: 12px;
  height: 12px;
  border-radius: 2px;
  background: var(--accent);
  box-shadow: 0 0 0 3px rgba(255, 101, 21, 0.14);
}

h1 {
  margin: 0;
  font-size: 22px;
  font-weight: 600;
  letter-spacing: -0.2px;
}

.lede {
  margin: 12px 0 0;
  max-width: 72ch;
  color: var(--text-mute);
  font-size: 13.5px;
}

/* ---------------- cards ---------------- */

.card {
  margin-bottom: 16px;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--bg-600);
}

.card h2 {
  margin: 0 0 10px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--text-dim);
}

.card-head { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; margin-bottom: 6px; }
.card-head h2 { margin: 0; }

.steps ol { margin: 0; padding-left: 20px; color: var(--text-mute); font-size: 13px; }
.steps li { margin: 6px 0; }
.steps strong { color: var(--text-dim); font-weight: 600; }

/* ---------------- form ---------------- */

.grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.field { display: flex; flex-direction: column; gap: 5px; min-width: 0; }
.field.span-2 { grid-column: 1 / -1; }

.field > span {
  color: var(--text-mute);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.02em;
  /* Normal case: a label reads "Round hash", never "ROUND HASH". */
  text-transform: none;
}

.field small { color: var(--text-faint); font-size: 11.5px; }

input, select {
  width: 100%;
  height: 40px;
  padding: 0 11px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius);
  background: var(--well);
  color: var(--text);
  font-family: var(--font-mono);
  font-size: 12.5px;
  outline: none;
}

input::placeholder { color: var(--text-faint); }
input:focus, select:focus { border-color: var(--accent); }

#hash, #seed, #salt, #terminal { letter-spacing: 0.01em; }

.advanced { margin-top: 16px; border-top: 1px solid var(--line); padding-top: 12px; }
.advanced summary {
  cursor: pointer;
  color: var(--text-mute);
  font-size: 12px;
  user-select: none;
}
.advanced summary:hover { color: var(--text-dim); }
.advanced .grid { margin-top: 14px; }

.actions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-top: 18px; }

button {
  font-family: var(--font);
  font-size: 13px;
  font-weight: 600;
  border-radius: var(--radius);
  cursor: pointer;
  transition: filter 0.15s, background 0.15s, border-color 0.15s, color 0.15s;
}

.primary {
  min-height: 40px;
  padding: 0 22px;
  border: 0;
  background: var(--accent);
  color: var(--accent-ink);
}
.primary:hover:not(:disabled) { filter: brightness(1.07); }
.primary:disabled { opacity: 0.55; cursor: default; }

.ghost {
  min-height: 40px;
  padding: 0 16px;
  border: 1px solid var(--line-strong);
  background: transparent;
  color: var(--text-dim);
}
.ghost:hover { color: var(--text); background: var(--well); }

.status { color: var(--text-faint); font-family: var(--font-mono); font-size: 11.5px; }

/* ---------------- verdict ---------------- */

.verdict { border-left: 3px solid var(--line-strong); }
.verdict.is-ok { border-left-color: var(--mint); }
.verdict.is-bad { border-left-color: var(--red); }

.verdict h2 { margin: 0 0 6px; font-size: 15px; font-weight: 600; color: var(--text); }
.verdict p { margin: 0; color: var(--text-mute); font-size: 13px; }
.verdict.is-ok h2 { color: var(--mint); }
.verdict.is-bad h2 { color: var(--red); }

/* ---------------- details ---------------- */

.facts {
  display: grid;
  grid-template-columns: 132px minmax(0, 1fr);
  gap: 6px 14px;
  margin: 0 0 14px;
  font-size: 12.5px;
}
.facts dt {
  color: var(--text-faint);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.02em;
  text-transform: none;
  padding-top: 2px;
}
.facts dd {
  margin: 0;
  color: var(--text-dim);
  font-family: var(--font-mono);
  font-size: 12px;
  overflow-wrap: anywhere;
}
.facts a { color: var(--accent); text-decoration: none; }
.facts a:hover { text-decoration: underline; }

.checks, .notes { margin: 0; padding: 0; list-style: none; }
.checks li, .notes li {
  position: relative;
  padding-left: 22px;
  margin: 5px 0;
  font-size: 12.5px;
  color: var(--text-mute);
}
.checks li::before {
  content: "";
  position: absolute;
  left: 3px;
  top: 7px;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--text-faint);
}
.checks li.ok::before { background: var(--mint); }
.checks li.bad::before { background: var(--red); }
.notes li { color: var(--text-faint); }
.notes li::before {
  content: "?";
  position: absolute;
  left: 2px;
  top: 0;
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--text-faint);
}

/* ---------------- table ---------------- */

.table-scroll { overflow-x: auto; margin: 0 -4px; padding: 0 4px; }

table { width: 100%; border-collapse: collapse; font-family: var(--font-mono); font-size: 12px; }

thead th {
  text-align: left;
  padding: 6px 8px;
  color: var(--text-faint);
  font-size: 10.5px;
  font-weight: 500;
  letter-spacing: 0.02em;
  text-transform: none;
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
}

tbody td {
  padding: 7px 8px;
  border-bottom: 1px solid var(--line);
  color: var(--text-dim);
  vertical-align: top;
}

tbody tr:last-child td { border-bottom: 0; }

td.hash { color: var(--text-mute); font-size: 11px; overflow-wrap: anywhere; }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; }
td.round { color: var(--text); }
td .win { color: var(--mint); }
td .hot { color: var(--accent); }

.muted { color: var(--text-faint); font-size: 11.5px; }

/* ---------------- footer ---------------- */

.foot { margin-top: 28px; color: var(--text-mute); font-size: 12px; }
.foot p { margin: 0 0 10px; max-width: 78ch; }
.foot .muted { color: var(--text-faint); }

/* ---------------- small screens ---------------- */

@media (max-width: 620px) {
  .wrap { width: 100%; padding: 24px 16px 48px; }
  .grid { grid-template-columns: minmax(0, 1fr); }
  .field.span-2, .field { grid-column: 1 / -1; }
  .facts { grid-template-columns: minmax(0, 1fr); gap: 2px; }
  .facts dt { padding-top: 6px; }
  h1 { font-size: 19px; }
  .card { padding: 16px; }
}

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; }
}
