/* =============================================================================
   SIGN UP PAGE STYLES
   ============================================================================= */

/* Render immediately with device fonts; do not fade the whole form on every navigation. */
.auth-container-modern {
  --font: system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --mono: ui-monospace, 'SF Mono', Menlo, monospace;
}

/* Keep the last field-to-Next gap equal to the spacing between field groups. */
#signup-form .auth-btn-outside {
  display: flex;
  margin-top: 0;
}

/* Theme-adaptive Google button matching light and dark themes */
.btn-google {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  height: 48px;
  border-radius: 12px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  color: var(--text);
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
  user-select: none;
  text-decoration: none;
  margin-bottom: 0;
}

.btn-google:hover:not(:disabled) {
  background: var(--bg-hover);
  border-color: var(--border-strong);
}

.btn-google:active:not(:disabled) {
  transform: scale(0.99);
}

.btn-google:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* "or" separator divider between primary and secondary sign-in actions */
.auth-separator {
  display: flex;
  align-items: center;
  text-align: center;
  width: 100%;
  margin: 18px 0 14px;
}

.auth-separator::before,
.auth-separator::after {
  content: '';
  flex: 1;
  border-bottom: 1px solid var(--border);
}

.auth-separator span {
  padding: 0 12px;
  font-size: 12px;
  font-weight: 500;
  color: var(--text-muted);
  text-transform: lowercase;
}

/* Match Sign In's inline recovery row without adding another primary-button gap. */
.auth-optional-action {
  margin: 0 0 var(--auth-field-gap, 12px);
}

#signup-optional-toggle {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 24px;
  padding: 0;
  border: 0;
  background: transparent;
  font: inherit;
  font-size: 12.5px;
  font-weight: 700;
  line-height: 1.55;
  letter-spacing: 0.02em;
  color: var(--text-muted);
  cursor: pointer;
}

#signup-optional-toggle:hover { color: var(--accent); }
#signup-optional-toggle:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 4px; }
#signup-optional-toggle[aria-expanded="true"] .optional-chevron { transform: rotate(180deg); }

/* Keep the form anchored when disclosure content crosses the viewport height. */
html { scroll-behavior: auto; scrollbar-gutter: stable; }
.auth-wrap { align-items: flex-start; }

@media (max-width: 600px) {
  /* iOS zooms focused inputs below 16px. Keep pinch zoom enabled. */
  #signup-form .btn-field-box .input { font-size: 16px; }
}

/* A single 48px birthday control, divided internally rather than three separate boxes. */
#signup-form .birthday-box { display: grid; grid-template-columns: 1fr 1fr 1fr; padding: 0; overflow: hidden; }
#signup-form .birthday-box .input { width: 100%; min-width: 0; height: 100%; padding: 0 8px; border-radius: 0; text-align: center; }
#signup-form .birthday-box .input + .input { border-left: 1px solid var(--border); }
