/* Amachains ID — telas hospedadas. Design sóbrio, foco em legibilidade e acessibilidade. */

:root {
  --teal-600: #0f766e;
  --teal-700: #115e59;
  --teal-50: #f0fdfa;
  --slate-900: #0f172a;
  --slate-700: #334155;
  --slate-500: #64748b;
  --slate-400: #94a3b8;
  --slate-300: #cbd5e1;
  --slate-200: #e2e8f0;
  --slate-100: #f1f5f9;
  --slate-50: #f8fafc;
  --red-600: #dc2626;
  --red-50: #fef2f2;
  --amber-500: #f59e0b;
  --green-600: #16a34a;
  --white: #fff;
  --radius: 10px;
  --shadow: 0 1px 2px rgb(15 23 42 / 4%), 0 8px 32px rgb(15 23 42 / 8%);
}

@media (prefers-color-scheme: dark) {
  :root {
    --white: #0f172a;
    --slate-900: #f1f5f9;
    --slate-700: #cbd5e1;
    --slate-500: #94a3b8;
    --slate-400: #64748b;
    --slate-300: #334155;
    --slate-200: #1e293b;
    --slate-100: #1e293b;
    --slate-50: #020617;
    --teal-50: #042f2e;
    --red-50: #450a0a;
    --shadow: 0 1px 2px rgb(0 0 0 / 30%), 0 8px 32px rgb(0 0 0 / 40%);
  }
}

*, *::before, *::after { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 24px 16px;
  background: var(--slate-50);
  color: var(--slate-900);
  font: 400 16px/1.55 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
}

.card {
  width: 100%;
  max-width: 420px;
  background: var(--white);
  border: 1px solid var(--slate-200);
  border-radius: 16px;
  box-shadow: var(--shadow);
  padding: 36px 32px;
}

.card--wide { max-width: 520px; }

.brand {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--teal-600);
  margin-bottom: 22px;
}

h1 {
  margin: 0 0 6px;
  font-size: 24px;
  font-weight: 650;
  letter-spacing: -0.015em;
  line-height: 1.25;
}

.subtitle { margin: 0 0 26px; color: var(--slate-500); font-size: 15px; }

label {
  display: block;
  font-size: 13.5px;
  font-weight: 550;
  color: var(--slate-700);
  margin-bottom: 6px;
}

input[type="text"], input[type="email"], input[type="password"], input[type="tel"], select {
  width: 100%;
  padding: 11px 13px;
  font-size: 15px;
  font-family: inherit;
  color: var(--slate-900);
  background: var(--white);
  border: 1px solid var(--slate-300);
  border-radius: var(--radius);
  transition: border-color 0.12s, box-shadow 0.12s;
}

input:focus, select:focus, button:focus-visible, a:focus-visible {
  outline: none;
  border-color: var(--teal-600);
  box-shadow: 0 0 0 3px rgb(15 118 110 / 15%);
}

input[inputmode="numeric"] {
  letter-spacing: 0.5em;
  text-align: center;
  font-size: 22px;
  font-variant-numeric: tabular-nums;
}

.field { margin-bottom: 16px; }

.hint { font-size: 12.5px; color: var(--slate-500); margin-top: 6px; }

button, .btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: 100%;
  padding: 12px 18px;
  font: inherit;
  font-size: 15px;
  font-weight: 600;
  color: #fff;
  background: var(--teal-600);
  border: 1px solid transparent;
  border-radius: var(--radius);
  cursor: pointer;
  text-decoration: none;
  transition: background 0.12s;
}

button:hover, .btn:hover { background: var(--teal-700); }
button:disabled { opacity: 0.6; cursor: not-allowed; }

.btn--secondary {
  color: var(--slate-700);
  background: var(--white);
  border-color: var(--slate-300);
}
.btn--secondary:hover { background: var(--slate-100); }

.btn--danger { background: var(--red-600); }
.btn--danger:hover { background: #b91c1c; }

.actions { display: flex; gap: 10px; margin-top: 22px; }

.alert {
  padding: 11px 14px;
  border-radius: var(--radius);
  font-size: 14px;
  margin-bottom: 20px;
  border: 1px solid transparent;
}
.alert--error { background: var(--red-50); color: var(--red-600); border-color: currentcolor; }
.alert--notice { background: var(--teal-50); color: var(--teal-700); border-color: currentcolor; }

.meta { margin-top: 24px; font-size: 14px; color: var(--slate-500); text-align: center; }
.meta a, .link { color: var(--teal-600); font-weight: 550; text-decoration: none; }
.meta a:hover, .link:hover { text-decoration: underline; }

.row-between { display: flex; justify-content: space-between; align-items: baseline; }

.divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 22px 0;
  color: var(--slate-400);
  font-size: 13px;
}
.divider::before, .divider::after { content: ""; flex: 1; height: 1px; background: var(--slate-200); }

.strength { display: flex; gap: 4px; margin-top: 8px; }
.strength span { flex: 1; height: 4px; border-radius: 2px; background: var(--slate-200); transition: background 0.2s; }
.strength[data-score="1"] span:nth-child(-n+1) { background: var(--red-600); }
.strength[data-score="2"] span:nth-child(-n+2) { background: var(--amber-500); }
.strength[data-score="3"] span:nth-child(-n+3) { background: var(--amber-500); }
.strength[data-score="4"] span { background: var(--green-600); }

.scopes { list-style: none; padding: 0; margin: 0 0 8px; }
.scopes li {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  padding: 10px 0;
  border-bottom: 1px solid var(--slate-200);
  font-size: 14.5px;
  color: var(--slate-700);
}
.scopes li:last-child { border-bottom: none; }
.scopes li::before { content: "✓"; color: var(--teal-600); font-weight: 700; }

.qr { display: block; margin: 18px auto; border-radius: 8px; background: #fff; padding: 10px; }
.secret {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 13px;
  word-break: break-all;
  background: var(--slate-100);
  padding: 10px;
  border-radius: 8px;
  text-align: center;
}

.footer { margin-top: 28px; font-size: 12.5px; color: var(--slate-400); text-align: center; }
.footer a { color: var(--slate-500); }

.lang { position: fixed; top: 16px; right: 16px; font-size: 13px; }
.lang a { color: var(--slate-500); text-decoration: none; padding: 4px 8px; border-radius: 6px; }
.lang a[aria-current="true"] { background: var(--slate-200); color: var(--slate-900); font-weight: 600; }

.codes { list-style: none; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 16px 0; }
.codes li {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 14px;
  background: var(--slate-100);
  padding: 8px;
  border-radius: 6px;
  text-align: center;
  letter-spacing: 0.05em;
}

@media (max-width: 480px) {
  .card { padding: 28px 22px; border-radius: 12px; }
  .actions { flex-direction: column-reverse; }
}
