/* Auth pages (sign in, password reset, etc.) */
.auth-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(160deg, var(--teal-light) 0%, var(--white) 60%);
  padding: 2rem;
}

.auth-card {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 8px;
  border-top: 3px solid var(--teal);
  padding: 2.5rem;
  width: 100%;
  max-width: 400px;
  box-shadow: 0 2px 16px rgba(0,0,0,0.06);
}

.auth-logo {
  display: block;
  margin: 0 auto 2rem;
  width: 200px;
}

.auth-logo img {
  width: 100%;
  height: auto;
}

.auth-heading {
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--gray-dark);
  text-align: center;
  margin-bottom: 0.5rem;
}

.auth-hint {
  font-size: 0.88rem;
  color: var(--gray-mid);
  text-align: center;
  margin-bottom: 1.5rem;
}

.auth-card #error_explanation {
  background: var(--danger-bg);
  border: 1px solid var(--danger-border);
  color: var(--danger);
  border-radius: 4px;
  padding: 0.65rem 0.9rem;
  font-size: 0.88rem;
}

.auth-card #error_explanation h2 {
  font-size: 0.88rem;
  font-weight: 600;
  margin-bottom: 0.35rem;
}

.auth-card #error_explanation ul {
  margin: 0;
  padding-left: 1.1rem;
}

/* Devise wraps invalid fields in div.field_with_errors, which breaks the
   .auth-field flex stretch — flatten the wrapper out of the layout. */
.auth-field .field_with_errors {
  display: contents;
}

.auth-alert {
  background: var(--danger-bg);
  border: 1px solid var(--danger-border);
  color: var(--danger);
  border-radius: 4px;
  padding: 0.65rem 0.9rem;
  font-size: 0.88rem;
  margin-bottom: 1.25rem;
}

.auth-form {
  display: flex;
  flex-direction: column;
  gap: 1.1rem;
}

.auth-field {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.auth-field label {
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--gray-dark);
}

.auth-field input {
  padding: 0.6rem 0.75rem;
  border: 1px solid var(--border-input);
  border-radius: 4px;
  font-size: 0.95rem;
  color: var(--gray-dark);
  transition: border-color 0.15s, box-shadow 0.15s;
  outline: none;
}

.auth-field input:focus {
  border-color: var(--teal);
  box-shadow: 0 0 0 3px rgba(0,154,149,0.12);
}

.auth-field-hint {
  font-size: 0.8rem;
  color: var(--gray-mid);
}

.auth-remember {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.88rem;
  color: var(--gray-mid);
}

.auth-microsoft {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.65rem;
  padding: 0.75rem;
  font-size: 0.95rem;
  background: var(--white);
  color: var(--gray-dark);
  border: 1.5px solid var(--border-input);
  box-shadow: 0 1px 3px rgba(0,0,0,0.06);
}

.auth-microsoft-hint {
  margin-top: 0.6rem;
  margin-bottom: 0;
}

.auth-microsoft-hint strong,
.auth-hint strong {
  font-weight: 600;
  color: var(--gray-dark);
}

.auth-microsoft:hover {
  background: var(--gray-light);
  border-color: var(--text-faint);
}

.auth-divider {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin: 1.5rem 0 1.25rem;
  font-size: 0.85rem;
  color: var(--gray-mid);
}

.auth-divider::before,
.auth-divider::after {
  content: "";
  flex: 1;
  border-top: 1px solid var(--divider);
}

.auth-submit {
  width: 100%;
  padding: 0.7rem;
  font-size: 0.95rem;
  margin-top: 0.25rem;
  text-align: center;
}

/* Connect-Claude consent: Deny left, Allow right. */
.auth-actions {
  display: flex;
  justify-content: flex-end;
  gap: 0.75rem;
}

.auth-links {
  margin-top: 1.25rem;
  text-align: center;
  font-size: 0.88rem;
}

.auth-links a {
  color: var(--teal);
  text-decoration: none;
}

.auth-links a:hover {
  text-decoration: underline;
}

