/*
 * auth-ux.css — auth page polish (templates/login.php + templates/signup.php).
 *
 * Uses the design-system tokens only: deep culinary teal accents, neutral
 * ink/paper surfaces, system type. Loaded from the auth templates.
 */

/* Password field with an in-field visibility toggle.
   The button is `hidden` in the markup and only enabled by auth-ux.js, so
   no-JS pages show nothing extra. */
.auth-pw-wrap {
  position: relative;
}

.auth-pw-wrap .auth-input {
  padding-right: 3.25rem; /* room for the reveal button */
  margin-bottom: 0;
}

.auth-pw-toggle {
  position: absolute;
  top: 2px;
  right: 2px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: var(--radius-md);
  background: transparent;
  color: var(--text-muted);
  cursor: pointer;
  transition: color var(--transition-fast), background var(--transition-fast);
}

.auth-pw-toggle:hover {
  color: var(--accent);
  background: var(--bg-hover);
}

.auth-pw-toggle:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: -2px;
}

.auth-pw-toggle[hidden] {
  display: none;
}

.auth-pw-toggle-icon {
  width: 20px;
  height: 20px;
  pointer-events: none;
}

/* Live summary of the signup password checklist ("3 of 6 requirements met").
   Announced only when the met-count changes (see inline signup script). */
.auth-pw-summary {
  margin: var(--space-1) 0 0;
  font-size: var(--font-size-xs);
  color: var(--text-secondary);
}

.auth-pw-summary[hidden] {
  display: none;
}

/* Keep the checklist text legible on the white auth card. */
.auth-field .auth-pw-reqs {
  margin: 0 0 var(--space-3);
}

/* The requirements list is revealed on focus/typing; never overlap with the
   field below it on short viewports. */
@media (max-width: 420px) {
  .auth-card {
    padding-left: var(--space-5);
    padding-right: var(--space-5);
  }
}
