/* Anakalypsis workspace — auth form styling.
   Inherits the same palette as the main site: deep panel + gold accent.
   Used by /signin, /signup, /confirm, /forgot, /reset. */

:root {
  --bg: #0f1115;
  --panel: #161a22;
  --panel-2: #1c2030;
  --text: #e7e9ee;
  --text-muted: #9aa3b2;
  --text-dim: #6b7383;
  --accent: #d9b16a;
  --accent-hover: #e7c084;
  --border: #262c38;
  --error: #e07a7a;
  --ok: #7ad6a0;
  --shadow: 0 18px 40px rgba(0,0,0,0.45);
}

* { box-sizing: border-box; }
html, body {
  margin: 0; padding: 0;
  background:
    radial-gradient(900px 600px at 20% -10%, rgba(217,177,106,0.07), transparent 60%),
    radial-gradient(700px 500px at 110% 110%, rgba(217,177,106,0.04), transparent 60%),
    var(--bg);
  background-attachment: fixed;
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, system-ui, sans-serif;
  min-height: 100vh;
}

a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-hover); text-decoration: underline; }

.auth-shell {
  display: grid;
  place-items: center;
  min-height: 100vh;
  padding: 32px 20px;
}

.auth-card {
  width: 100%;
  max-width: 420px;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 36px 36px 28px;
  box-shadow: var(--shadow);
}

.auth-brand {
  text-align: center;
  margin-bottom: 26px;
}
.auth-brand .mark {
  font-family: "Cormorant Garamond", "Adobe Garamond Pro", Garamond, Georgia, serif;
  font-weight: 500;
  font-size: 1.95rem;
  letter-spacing: 0.02em;
  color: var(--text);
  margin: 0;
  line-height: 1.05;
}
.auth-brand .mark .accent { color: var(--accent); }
.auth-brand .sub {
  margin-top: 6px;
  font-size: 0.82rem;
  color: var(--text-dim);
  letter-spacing: 0.18em;
  text-transform: uppercase;
}

.auth-title {
  font-family: "Cormorant Garamond", "Adobe Garamond Pro", Garamond, Georgia, serif;
  font-weight: 500;
  font-size: 1.5rem;
  text-align: center;
  margin: 0 0 4px;
  color: var(--text);
}
.auth-hint {
  text-align: center;
  font-size: 0.9rem;
  color: var(--text-muted);
  margin: 0 0 22px;
}
.auth-hint strong { color: var(--text); font-weight: 500; }

form.auth-form { display: flex; flex-direction: column; gap: 14px; }
.field { display: flex; flex-direction: column; gap: 6px; }
.field label {
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
  font-weight: 500;
}
.field input {
  background: var(--panel-2);
  border: 1px solid var(--border);
  border-radius: 7px;
  padding: 11px 13px;
  color: var(--text);
  font-size: 1rem;
  font-family: inherit;
  transition: border-color 120ms ease, background 120ms ease;
}
.field input::placeholder { color: var(--text-dim); }
.field input:focus {
  outline: none;
  border-color: var(--accent);
  background: #1f2331;
}
.field .help {
  font-size: 0.78rem;
  color: var(--text-dim);
  margin-top: 2px;
}
.field .help.error { color: var(--error); }

.field-row {
  display: flex;
  justify-content: flex-end;
  font-size: 0.85rem;
  margin-top: -4px;
}
.field-row a { color: var(--text-muted); }
.field-row a:hover { color: var(--accent); text-decoration: none; }

.btn-primary {
  background: var(--accent);
  color: #1a1410;
  border: 0;
  border-radius: 7px;
  padding: 12px 16px;
  font-size: 0.98rem;
  font-weight: 600;
  font-family: inherit;
  letter-spacing: 0.02em;
  cursor: pointer;
  transition: background 120ms ease, transform 80ms ease;
  margin-top: 8px;
}
.btn-primary:hover:not(:disabled) { background: var(--accent-hover); }
.btn-primary:active:not(:disabled) { transform: translateY(1px); }
.btn-primary:disabled { opacity: 0.55; cursor: progress; }

.auth-error {
  background: rgba(224,122,122,0.10);
  border: 1px solid rgba(224,122,122,0.35);
  color: #f0b6b6;
  padding: 10px 12px;
  border-radius: 6px;
  font-size: 0.88rem;
  display: none;
}
.auth-error.show { display: block; }

.auth-ok {
  background: rgba(122,214,160,0.10);
  border: 1px solid rgba(122,214,160,0.35);
  color: #b6f0c8;
  padding: 10px 12px;
  border-radius: 6px;
  font-size: 0.88rem;
  display: none;
}
.auth-ok.show { display: block; }

.auth-foot {
  margin-top: 22px;
  padding-top: 18px;
  border-top: 1px solid var(--border);
  text-align: center;
  font-size: 0.9rem;
  color: var(--text-muted);
}
.auth-foot a { color: var(--text); font-weight: 500; }
.auth-foot a:hover { color: var(--accent); text-decoration: none; }

.auth-trailer {
  text-align: center;
  margin-top: 18px;
  font-size: 0.8rem;
  color: var(--text-dim);
}
.auth-trailer a { color: var(--text-dim); text-decoration: underline; text-underline-offset: 2px; }
.auth-trailer a:hover { color: var(--text-muted); }

/* Verification-code input: monospace, wide-letter-spaced for legibility. */
.field input.code {
  font-family: "JetBrains Mono", Menlo, Consolas, monospace;
  letter-spacing: 0.42em;
  text-align: center;
  font-size: 1.15rem;
  padding-left: 24px; /* compensate for letter-spacing visual lean */
}

@media (max-width: 480px) {
  .auth-card { padding: 28px 22px 22px; border-radius: 10px; }
  .auth-brand .mark { font-size: 1.7rem; }
}
