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

html { font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif; }

/* ── Dark mode ── */
html { background: #f3f4f6; color: #111827; }
html.dark { background: #0f1117; color: #f3f4f6; }

/* ── Layout ── */
.auth-body {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
}

/* ── Card ── */
.auth-card {
  width: 100%;
  max-width: 420px;
  background: #fff;
  border-radius: 1rem;
  box-shadow: 0 4px 32px rgba(0,0,0,.08);
  padding: 2.25rem 2rem;
}
html.dark .auth-card {
  background: #1a1d27;
  box-shadow: 0 4px 32px rgba(0,0,0,.4);
}

/* ── Headings ── */
.auth-card h1 {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: .25rem;
  color: #111827;
}
html.dark .auth-card h1 { color: #f9fafb; }

.auth-sub {
  font-size: .9rem;
  color: #6b7280;
  margin-bottom: 1.5rem;
}
html.dark .auth-sub { color: #9ca3af; }

/* ── Labels & Inputs ── */
label {
  display: block;
  font-size: .75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .04em;
  color: #6b7280;
  margin-bottom: .35rem;
  margin-top: 1rem;
}
html.dark label { color: #9ca3af; }

input[type="text"],
input[type="email"],
input[type="password"] {
  width: 100%;
  padding: .65rem .85rem;
  font-size: .9rem;
  border-radius: .55rem;
  border: 1.5px solid #e5e7eb;
  background: #f9fafb;
  color: #111827;
  outline: none;
  transition: border-color .15s, box-shadow .15s;
}
html.dark input[type="text"],
html.dark input[type="email"],
html.dark input[type="password"] {
  background: #13151f;
  border-color: #374151;
  color: #f3f4f6;
}
input:focus {
  border-color: #6c63ff;
  box-shadow: 0 0 0 3px rgba(108,99,255,.15);
}

/* ── Hint ── */
.hint {
  font-size: .7rem;
  font-weight: 400;
  color: #9ca3af;
  text-transform: none;
  letter-spacing: 0;
}

/* ── Alerts ── */
.alert {
  border-radius: .55rem;
  padding: .65rem .9rem;
  font-size: .85rem;
  margin-bottom: 1rem;
}
.alert-success { background: rgba(34,197,94,.1); color: #16a34a; border: 1px solid rgba(34,197,94,.25); }
.alert-error   { background: rgba(239,68,68,.1);  color: #dc2626; border: 1px solid rgba(239,68,68,.25); }
html.dark .alert-success { color: #4ade80; }
html.dark .alert-error   { color: #f87171; }

/* ── Buttons ── */
.btn-primary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: .65rem 1.25rem;
  border-radius: .55rem;
  font-size: .9rem;
  font-weight: 600;
  background: #6c63ff;
  color: #fff;
  border: none;
  cursor: pointer;
  transition: background .15s, opacity .15s;
  text-decoration: none;
}
.btn-primary:hover { background: #5a52d5; }
.btn-full { width: 100%; margin-top: 1.5rem; }

/* ── Switch link ── */
.auth-switch {
  text-align: center;
  font-size: .85rem;
  color: #6b7280;
  margin-top: 1.25rem;
}
html.dark .auth-switch { color: #9ca3af; }
.auth-switch a { color: #6c63ff; text-decoration: none; font-weight: 600; }
.auth-switch a:hover { text-decoration: underline; }
