/**
 * Auth Pages — login / register / forgot-password
 * Focused full-height centered layout, CAMS2 card anatomy.
 * All values ride design tokens (var(--…)) — no raw colors here;
 * dark mode follows automatically via the semantic token flips.
 *
 * @author Amit Haridas, ConcreteInfo
 */

/* Card column — single 400px card on the gray canvas */
.auth-shell {
  width: 100%;
  max-width: 25rem; /* 400px */
}

/* The auth card */
.auth-panel {
  background-color: var(--bg-elevated);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-1);
  padding: var(--spacing-6); /* 24px */
}

/* Brand lockup (logo mark + wordmark) inside the card */
.auth-brand {
  display: flex;
  align-items: center;
  gap: var(--spacing-3);
  margin-bottom: var(--spacing-5);
}

.auth-brand-logo {
  width: 32px;
  height: 32px;
  object-fit: contain;
  flex-shrink: 0;
}

.auth-brand-name {
  font-size: var(--font-size-base);
  font-weight: var(--font-weight-bold);
  line-height: var(--line-height-tight);
  color: var(--text-primary);
}

.auth-brand-by {
  font-size: var(--font-size-xs);
  line-height: var(--line-height-tight);
  color: var(--muted);
}

/* Heading + one-line subcopy */
.auth-title {
  margin: 0;
  font-size: var(--font-size-lg);
  font-weight: var(--font-weight-semibold);
  color: var(--text-primary);
}

.auth-sub {
  margin-top: var(--spacing-1);
  margin-bottom: var(--spacing-5);
  font-size: var(--font-size-sm);
  color: var(--muted);
}

/* Footer link under the card */
.auth-footnote {
  margin-top: var(--spacing-6);
  text-align: center;
  font-size: var(--font-size-sm);
  color: var(--text-secondary);
}

/* "Or continue with" divider chip — rides the card surface in both modes */
.auth-divider-chip {
  background-color: var(--bg-elevated);
}

/* Flash (error/success) on auth pages — subtle card-width box.
   Tailwind handles spacing (mx-4 mt-6); this file owns width + centering. */
.auth-flash {
  max-width: 25rem; /* 400px — matches the card column */
  border-radius: var(--radius-xl);
}

@media (min-width: 640px) {
  .auth-flash {
    margin-left: auto;
    margin-right: auto;
  }
}

/* Invite-only notice modal on register.php — CAMS2 panel anatomy
   (bespoke inline modal on that page; same chrome as components/modal.css) */
.auth-modal-panel {
  background-color: var(--bg-elevated);
  border: 1px solid var(--border-default);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-xl);
}

.auth-modal-close {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  min-height: auto; /* override base.css 44px touch target */
  padding: 0;
  background: transparent;
  border: 0;
  border-radius: var(--radius-md);
  color: var(--muted);
  cursor: pointer;
  transition: background-color var(--transition-fast), color var(--transition-fast);
}

.auth-modal-close:hover {
  background-color: var(--bg-tertiary);
  color: var(--text-secondary);
}
