.auth-page { min-height: 100dvh; display: flex; flex-direction: column; background: #f8fafb; }
.auth-page .site-header { background: #fff; }
.auth-back { color: var(--muted); font-size: .875rem; text-decoration: none; }
.auth-back:hover { color: var(--blue); text-decoration: underline; }
.auth-main { width: min(100% - 40px, 460px); margin: 36px auto 28px; }
.auth-main h1 { font-size: 1.7rem; text-align: center; }
.auth-main > .intro { text-align: center; margin: 12px 0 26px; }
.auth-steps { display:flex; justify-content:center; gap:28px; color:var(--muted); font-size:.875rem; margin-bottom:20px; }
.auth-steps [aria-current] { color:var(--blue); font-weight:600; }
.auth-plus-summary { padding:16px 20px; margin:0 0 20px; border:1px solid #bfd9ca; border-radius:10px; background:#eaf4ee; }
.auth-plus-summary > div { display:flex; justify-content:space-between; gap:12px; color:#214d3e; font-size:1rem; }
.auth-plus-summary small { display:block; margin-top:8px; font-size:.875rem; color:#405d50; }
.auth-modes { display:flex; gap:4px; margin:0 0 12px; padding:4px; background:#e9eef2; border-radius:8px; }
.auth-modes a { flex:1; text-align:center; padding:10px 8px; border-radius:5px; font-size:.9375rem; color:var(--muted); text-decoration:none; }
.auth-modes a[aria-current] { background:#fff; color:var(--blue); box-shadow:0 1px 4px #192b3b14; font-weight:600; }
.auth-modes a:focus-visible { outline:3px solid #72b7e9; }
#auth-manage-account { display:inline-block; margin:18px 0 0 16px; }
.auth-panel { min-height: 280px; border: 1px solid var(--line); border-radius: 12px; background: #fff; box-shadow: 0 4px 16px #192b3b06; overflow: hidden; }
.auth-loading { min-height: 280px; display: flex; gap: 14px; align-items: center; justify-content: center; color: var(--muted); }
.auth-spinner { width: 20px; height: 20px; border: 2px solid var(--line); border-top-color: var(--blue); border-radius: 50%; animation: auth-spin .8s linear infinite; }
@keyframes auth-spin { to { transform: rotate(360deg); } }
.auth-error { padding: 28px; color: var(--ink); }
.auth-error button { margin-top: 18px; }
.auth-panel:has(.auth-error:not([hidden])) { min-height: 0; }
.auth-note { color: var(--muted); font-size: .875rem; text-align: center; margin: 20px auto 0; max-width: 400px; }
.auth-footer { display: flex; justify-content: center; gap: 24px; padding: 20px 20px 28px; margin-top: auto; font-size: .8125rem; }
.auth-footer a { color: var(--muted); }
/* Scope overrides to the embedded form; shared calculator styles target forms. */
#auth-form form { background: transparent; border: 0; padding: 0; border-radius: 0; }
#auth-form, #auth-form .cl-rootBox, #auth-form .cl-cardBox { width: 100%; max-width: 100%; }
#auth-form .cl-cardBox { box-shadow: none; border: 0; border-radius: 0; }
#auth-form .cl-card { padding: 28px; box-shadow: none; gap: 24px; }
#auth-form .cl-headerTitle { font-size: 1.125rem; letter-spacing: -.02em; }
#auth-form .cl-formFieldInput { font-size: 16px; min-height: 46px; }
#auth-form .cl-formButtonPrimary { min-height: 46px; background: var(--blue); box-shadow: none; }
#auth-form .cl-formButtonPrimary:hover { background: #124e7e; }
#auth-form .cl-formButtonPrimary::after { background: none; box-shadow: none; }
#auth-form .cl-footer { background: #f6f9fb; }
.auth-page [hidden] { display: none !important; }
@media (max-width: 650px) {
  .auth-page .header-inner { min-height: 72px; flex-wrap: nowrap; gap: 16px; padding: 16px 20px; }
  .auth-page .brand { gap: 10px; font-size: .875rem; }
  .auth-back { font-size: .8125rem; text-align: right; }
  .auth-main { margin-top: 24px; }
  .auth-main h1 { font-size: 1.5rem; }
  #auth-form .cl-card { padding: 24px; }
}
@media (prefers-reduced-motion: reduce) { .auth-spinner { animation: none; } }
