/* Sign-in and auth-callback pages. Requires theme.css and ds.css. */
.lead { margin: 0; font-size: 1.15rem; line-height: 1.6; color: var(--text-muted); max-width: 460px; text-wrap: pretty; }
.glass-panel { border-radius: 28px; padding: clamp(22px, 3vw, 36px); background: rgba(255,255,255,.62); border: 1px solid var(--border-subtle); box-shadow: var(--shadow-panel); -webkit-backdrop-filter: blur(18px); backdrop-filter: blur(18px); }

.auth-layout { padding: clamp(48px, 8vw, 104px) 0 clamp(64px, 9vw, 112px); display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 400px), 1fr)); gap: clamp(28px, 6vw, 96px); align-items: center; }
.auth-intro { display: grid; gap: 24px; align-self: center; }
.auth-panel { width: 100%; max-width: 480px; justify-self: end; display: grid; gap: 22px; }
.auth-tabs { display: grid; grid-template-columns: 1fr 1fr; gap: 4px; padding: 4px; border-radius: 999px; background: rgba(21,23,22,.06); }
.auth-tab { min-height: 40px; border: 0; border-radius: 999px; background: transparent; color: var(--text-muted); font-size: .88rem; font-weight: 720; cursor: pointer; transition: background .15s ease, color .15s ease; }
.auth-tab[aria-selected="true"] { background: #fff; color: var(--text-strong); box-shadow: 0 4px 14px rgba(31,34,28,.08); }
.google-mark { width: 18px; height: 18px; flex: none; }
.auth-divider { display: flex; align-items: center; gap: 14px; margin: 20px 0 0; color: var(--text-subtle); font-size: .78rem; }
.auth-divider::before, .auth-divider::after { content: ""; flex: 1; height: 1px; background: var(--border-subtle); }
.auth-form { display: grid; gap: 20px; }
.auth-form .field-meta { align-items: baseline; }
.text-button { padding: 0; border: 0; background: none; color: var(--text-strong); font-size: .8rem; font-weight: 650; text-decoration: underline; text-decoration-color: var(--border-hover); text-underline-offset: 3px; cursor: pointer; justify-self: center; }
.text-button:hover { color: var(--accent-text); }
.auth-message { margin: 0; padding: 12px 14px; border-radius: 14px; background: var(--paper-200); font-size: .86rem; line-height: 1.5; }
.auth-message.is-error { background: var(--clay-100); color: var(--clay-700); }
.auth-message.is-success { background: var(--lime-200); color: var(--lime-900); }
.auth-fine { margin: 0; color: var(--text-subtle); font-size: .73rem; line-height: 1.5; }
.btn[aria-busy="true"] { cursor: progress; opacity: .7; }

.callback-panel { max-width: 520px; margin: clamp(48px, 10vw, 120px) auto; display: grid; gap: 20px; }
.callback-panel h1 { font-size: var(--text-display-m); line-height: 1.05; letter-spacing: -.045em; }
.callback-panel p { margin: 0; }

@media (max-width: 860px) {
  .auth-panel { justify-self: stretch; max-width: none; }
}

/* Local preview demo accounts (temporary) */
.demo-accounts { margin-top: 22px; padding: 18px; border-radius: 18px; border: 1px dashed var(--border-hover); background: rgba(255,255,255,.35); display: grid; gap: 8px; }
.demo-list { display: grid; gap: 8px; margin-top: 4px; }
.demo-list button { display: grid; gap: 2px; text-align: left; padding: 12px 14px; border-radius: 14px; border: 1px solid var(--border-subtle); background: #fff; cursor: pointer; font: inherit; }
.demo-list button:hover { border-color: var(--border-strong); }
.demo-list strong { font-size: .92rem; }
.demo-list span { font-size: .78rem; color: var(--text-muted); line-height: 1.4; }
/* Sign-up steps (adapted from the ip-b account forms) */
.signup-steps { display: grid; gap: 18px; }
.signup-step { border: 0; padding: 0; margin: 0; display: grid; gap: 12px; min-width: 0; }
.signup-step legend { margin-bottom: 4px; padding: 0; }
.signup-heading { margin: 4px 0 -6px; }
.role-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.role-card { position: relative; display: grid; gap: 4px; align-content: start; padding: 14px; border-radius: 16px; border: 1px solid var(--border-subtle); background: rgba(255,255,255,.5); cursor: pointer; text-align: left; transition: all .15s ease; }
.role-card:hover { border-color: var(--border-hover); }
.role-card[aria-checked="true"] { border-color: var(--border-strong); background: #fff; box-shadow: var(--shadow-selected); }
.role-card strong { font-family: var(--font-display); font-weight: 500; font-size: 1.15rem; letter-spacing: -.02em; }
.role-card span { color: var(--text-muted); font-size: .74rem; line-height: 1.4; }
.pw { position: relative; display: block; }
.pw .control { padding-right: 76px; }
.pw-toggle { position: absolute; right: 8px; top: 50%; transform: translateY(-50%); min-height: 32px; padding: 0 12px; border-radius: 999px; border: 1px solid var(--border-subtle); background: rgba(255,255,255,.8); font-size: .78rem; font-weight: 700; cursor: pointer; }
.check-row { display: inline-flex; align-items: flex-start; gap: 9px; font-size: .86rem; line-height: 1.45; cursor: pointer; }
.check-row input { width: 18px; height: 18px; margin-top: 1px; accent-color: var(--ink-900); flex: none; }
@media (max-width: 520px) { .role-cards { grid-template-columns: 1fr; } }
