/* ============================================================
 * Dispatch AI — auth.css
 *
 * Styles login, signup, forgot, reset pages.
 * Loaded AFTER styles.css to override / fill gaps.
 *
 * Matches the marketing site at dispatch-cs.com — same indigo
 * brand color, same warm off-white background, same Inter stack.
 * ============================================================ */

:root {
  --bg: #fafaf9;
  --surface: #ffffff;
  --border: #e8e5df;
  --text: #1a1d29;
  --text-muted: #6b7180;
  --brand: #4f46e5;
  --brand-dark: #4338ca;
  --brand-soft: #eef2ff;
  --danger: #dc2626;
  --danger-soft: #fee2e2;
  --success: #059669;
  --success-soft: #d1fae5;
  --radius: 12px;
  --radius-sm: 8px;
  --shadow-lg: 0 20px 40px rgba(16, 24, 40, 0.08), 0 6px 12px rgba(16, 24, 40, 0.05);
}

* { box-sizing: border-box; }

body.auth-body {
  margin: 0;
  background: linear-gradient(180deg, var(--bg) 0%, #f4f3f0 100%);
  font-family: -apple-system, BlinkMacSystemFont, "Inter", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color: var(--text);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

.auth-shell {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
  padding: 56px 20px 40px;
  gap: 32px;
}

.brand-link {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--text);
  font-weight: 700;
  font-size: 16px;
}
.brand-link:hover { color: var(--text); text-decoration: none; }
.brand-mark {
  width: 30px;
  height: 30px;
  background: var(--brand);
  color: #fff;
  border-radius: 7px;
  display: grid;
  place-items: center;
  font-weight: 800;
  font-size: 17px;
}
.brand-name { font-weight: 700; }

.auth-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 40px 36px;
  box-shadow: var(--shadow-lg);
  width: 100%;
  max-width: 440px;
}
.auth-card h1 {
  margin: 0 0 10px;
  font-size: 28px;
  font-weight: 700;
  letter-spacing: -0.02em;
}
.auth-card > p { margin: 0 0 24px; }

.muted { color: var(--text-muted); }
.small { font-size: 13px; }

.auth-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.auth-form label {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text);
}
.auth-form input {
  padding: 11px 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-family: inherit;
  font-size: 15px;
  background: #fff;
  color: var(--text);
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.auth-form input:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.15);
}
.auth-form .muted { font-weight: 400; }

.forgot-link {
  font-size: 12px;
  align-self: flex-end;
  margin-top: -4px;
  color: var(--text-muted);
  text-decoration: none;
}
.forgot-link:hover { color: var(--brand); text-decoration: underline; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 11px 18px;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  font-family: inherit;
  font-weight: 600;
  font-size: 15px;
  cursor: pointer;
  transition: all 0.15s ease;
  text-decoration: none;
}
.btn-lg { padding: 13px 20px; font-size: 16px; }
.btn-primary {
  background: var(--brand);
  color: #fff;
  border-color: var(--brand);
}
.btn-primary:hover { background: var(--brand-dark); border-color: var(--brand-dark); }
.btn-primary:disabled { opacity: 0.55; cursor: not-allowed; }
.btn-secondary {
  background: #fff;
  color: var(--text);
  border-color: var(--border);
}
.btn-secondary:hover { background: #f6f5f1; border-color: #d4d0c8; }
.btn-secondary:disabled { opacity: 0.55; cursor: not-allowed; }

.auth-divider {
  display: flex;
  align-items: center;
  text-align: center;
  margin: 22px 0 14px;
  color: var(--text-muted);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}
.auth-divider::before,
.auth-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--border);
}
.auth-divider::before { margin-right: 12px; }
.auth-divider::after  { margin-left: 12px; }

.auth-error {
  padding: 10px 12px;
  background: var(--danger-soft);
  color: #991b1b;
  border-radius: var(--radius-sm);
  font-size: 13.5px;
  font-weight: 500;
}
.auth-success {
  padding: 14px 16px;
  background: var(--success-soft);
  color: #065f46;
  border-radius: var(--radius-sm);
  font-size: 14.5px;
}
.auth-success strong { display: block; margin-bottom: 4px; font-size: 15px; }
.auth-success p { margin: 6px 0 0; }
.auth-success p:last-child { margin-bottom: 0; }
.auth-success a { color: #065f46; text-decoration: underline; }

.auth-foot {
  margin: 24px 0 0;
  text-align: center;
  font-size: 13.5px;
}
.auth-foot a { color: var(--brand); font-weight: 500; }
.auth-foot a:hover { color: var(--brand-dark); }

.auth-fine {
  margin: 12px 0 0;
  text-align: center;
  font-size: 12px;
  line-height: 1.5;
}

@media (max-width: 520px) {
  .auth-shell { padding: 32px 16px; gap: 20px; }
  .auth-card { padding: 28px 22px; }
  .auth-card h1 { font-size: 24px; }
}
