/* Auth pages (login/register/2FA/account) — standalone, centered-card
   layout. Reuses the color variables from style.css but none of the
   whiteboard chrome (topbar/toolbar/canvas), so it's a self-contained sheet. */

body.auth-body {
  overflow-y: auto;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100%;
  padding: 24px;
}

.auth-card {
  width: 100%;
  max-width: 380px;
  background: var(--toolbar-bg);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 28px;
  box-shadow: 0 4px 20px rgba(0,0,0,0.06);
}

.auth-card h1 {
  margin: 0 0 4px;
  font-size: 20px;
}

.auth-card .auth-subtitle {
  margin: 0 0 22px;
  font-size: 13px;
  color: #6b7280;
}

.auth-field {
  margin-bottom: 14px;
}

.auth-field label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  margin-bottom: 5px;
  color: var(--text);
}

.auth-field input[type="text"],
.auth-field input[type="email"],
.auth-field input[type="password"] {
  width: 100%;
  padding: 9px 10px;
  border: 1px solid var(--border);
  border-radius: 8px;
  font-size: 14px;
  font-family: inherit;
  color: var(--text);
  background: #fff;
}

.auth-field input:focus {
  outline: none;
  border-color: var(--accent);
}

.auth-field-error {
  margin-top: 4px;
  font-size: 12px;
  color: var(--danger);
}

.auth-checkbox-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
  font-size: 13px;
  color: var(--text);
}

.auth-message {
  padding: 10px 12px;
  border-radius: 8px;
  font-size: 13px;
  margin-bottom: 16px;
  line-height: 1.4;
}
.auth-message.error { background: #fdecec; color: var(--danger); border: 1px solid #f6c6c7; }
.auth-message.info { background: #eef1ff; color: var(--accent); border: 1px solid #d6dcff; }
.auth-message.success { background: #e9f9ee; color: #1b8a45; border: 1px solid #c3ecd1; }

.auth-btn {
  width: 100%;
  padding: 10px 12px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  border: none;
}
.auth-btn.primary { background: var(--accent); color: #fff; }
.auth-btn.primary:hover { background: #324fd6; }
.auth-btn.danger { background: var(--danger); color: #fff; }
.auth-btn.danger:hover { background: #c53f43; }
.auth-btn.secondary { background: none; color: var(--text); border: 1px solid var(--border); margin-top: 8px; }
.auth-btn.secondary:hover { background: var(--bg); }
.auth-btn:disabled { opacity: 0.6; cursor: default; }

.auth-footer {
  text-align: center;
  font-size: 13px;
  color: #6b7280;
  margin-top: 18px;
}
.auth-footer a { color: var(--accent); font-weight: 600; text-decoration: none; }
.auth-footer a:hover { text-decoration: underline; }

.auth-row {
  display: flex;
  gap: 10px;
}
.auth-row .auth-btn { flex: 1; }

.auth-account-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 0;
  border-top: 1px solid var(--border);
  font-size: 13px;
}
.auth-account-row:first-of-type { border-top: none; }
.auth-account-row .auth-label { color: #6b7280; }
.auth-account-row .auth-value { font-weight: 600; }

.auth-qr {
  display: block;
  margin: 0 auto 14px;
  width: 180px;
  height: 180px;
  border: 1px solid var(--border);
  border-radius: 10px;
}

.auth-secret {
  font-family: "Courier New", monospace;
  font-size: 13px;
  background: var(--bg);
  border-radius: 6px;
  padding: 8px 10px;
  text-align: center;
  letter-spacing: 1px;
  margin-bottom: 16px;
  word-break: break-all;
}

.auth-badge {
  display: inline-block;
  font-size: 11px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 999px;
}
.auth-badge.on { background: #e9f9ee; color: #1b8a45; }
.auth-badge.off { background: #f1f2f4; color: #6b7280; }
