/* Atlas account access and member management. */
[hidden] { display: none !important; }
.sidebar nav { min-height: 0; overflow-y: auto; }
.sidebar .workspace-switch, .sidebar .sidebar-footer { flex-shrink: 0; }
.account-top-summary { display: none; border: 0; background: transparent; padding: 0; font: inherit; color: var(--muted); max-width: 160px; font-size: 10px; text-align: right; cursor: pointer; }
.account-top-summary span { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.auth-screen { position: fixed; inset: 0; z-index: 200; display: grid; grid-template-columns: minmax(360px, .95fr) minmax(420px, 1.05fr); background: var(--surface-page); overflow: auto; }
.auth-locked > :not(.auth-screen):not(script) { display: none !important; }
.auth-locked { overflow: auto !important; }
.auth-brand { background: var(--brand-navy); color: white; padding: clamp(36px, 6vw, 96px); display: flex; flex-direction: column; justify-content: space-between; gap: 70px; min-height: 100vh; position: relative; overflow: hidden; }
.auth-brand::after { content: ''; position: absolute; width: 480px; height: 480px; border: 85px solid var(--brand-purple); border-radius: 50%; right: -280px; bottom: -220px; opacity: .45; pointer-events: none; }
.auth-brand > img { width: 176px; max-width: 70%; }
.auth-brand .eyebrow { color: var(--brand-light-cyan); font-size: 11px; letter-spacing: .18em; }
.auth-brand h1 { color: white; font-size: clamp(30px, 3.2vw, 48px); line-height: 1.5; margin: 22px 0; letter-spacing: .01em; }
.auth-brand p { color: var(--brand-pale-blue); line-height: 1.8; }
.auth-brand-foot { color: var(--brand-lavender); font-size: 12px; position: relative; z-index: 1; }
.auth-entry { display: flex; justify-content: center; align-items: center; padding: 44px 32px; }
.auth-card { width: 100%; max-width: 430px; }
.auth-card h2 { font-size: 30px; margin: 15px 0 12px; }
.auth-card > p { color: var(--muted); line-height: 1.8; margin-bottom: 28px; }
.auth-card .error-banner { margin-bottom: 20px; }
.auth-card label, .account-password-form label { display: block; font-size: 13px; font-weight: 700; margin: 19px 0 9px; }
.auth-card input, .account-password-form input, #account-form input:not([type=checkbox]), #account-form select { width: 100%; min-height: 47px; border: 1px solid var(--border-strong); border-radius: 9px; background: white; padding: 11px 13px; color: var(--text); font: inherit; }
.auth-card input:focus, .account-password-form input:focus { border-color: var(--brand-purple); outline: 3px solid var(--primary-soft); }
.auth-card form > .button { width: 100%; margin-top: 28px; justify-content: center; }
.auth-card .auth-footnote { margin-top: 30px; font-size: 12px; color: var(--muted); }
.auth-mobile-logo { display: none; width: 130px; margin-bottom: 30px; }
.auth-remember-options { margin-top: 22px; padding: 14px 16px; border: 1px solid var(--border); background: var(--surface-soft); border-radius: 10px; }
.auth-card .auth-remember-choice { display: flex; align-items: center; gap: 10px; min-height: 36px; margin: 0; cursor: pointer; font-size: 14px; }
.auth-card .auth-remember-choice input { width: 18px; height: 18px; min-height: 18px; margin: 0; padding: 0; flex-shrink: 0; accent-color: var(--brand-purple); }
.auth-remember-choice > span { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.auth-remember-period { color: var(--brand-deep-purple); background: var(--primary-soft); border-radius: 5px; padding: 3px 7px; font-size: 11px; font-weight: 500; }
.auth-remember-options p { font-size: 12px; color: var(--muted); line-height: 1.8; margin: 7px 0 0; }
.auth-remember-options .auth-password-help { padding-top: 7px; border-top: 1px solid var(--border); }
.auth-remember-options .auth-remember-notice { color: var(--warning-text); }
.account-sidebar { gap: 10px; }
.account-sidebar-copy { min-width: 0; flex: 1; }
.account-sidebar-copy strong { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 175px; font-size: 11px; }
.account-sidebar-copy small { display: block; margin-top: 5px; }
.account-logout { color: var(--brand-light-cyan); border: 0; background: transparent; font: inherit; font-size: 12px; padding: 7px 0 7px 6px; cursor: pointer; white-space: nowrap; }
.account-logout:hover { color: white; }
.account-intro { display: flex; gap: 24px; justify-content: space-between; align-items: center; margin: 0 0 24px; }
.account-intro p, .account-help { color: var(--muted); font-size: 13px; line-height: 1.85; }
.account-intro .button { flex-shrink: 0; }
.accounts-table { min-width: 650px; }
.accounts-table td:first-child { min-width: 220px; }
.accounts-table td:first-child strong { overflow-wrap: anywhere; }
.accounts-table td:first-child .badge { display: inline-flex; margin: 7px 0 0 9px; }
.my-account-panel { padding: 32px; display: grid; grid-template-columns: 1fr 1fr; gap: 40px; }
.account-identity h2 { font-size: 22px; margin: 16px 0; overflow-wrap: anywhere; }
.account-identity p { max-width: 320px; color: var(--muted); line-height: 1.9; margin-top: 18px; font-size: 13px; }
.account-password-form { max-width: 430px; border-left: 1px solid var(--border); padding-left: 36px; }
.account-password-form h3 { margin-top: 0; }
.account-password-form .button { margin-top: 16px; }
#account-dialog { width: min(540px, calc(100vw - 32px)); }
#account-form .account-active-field { display: flex; align-items: center; gap: 10px; padding: 12px 0; }
#account-form .account-active-field input { width: 17px; height: 17px; accent-color: var(--brand-purple); }
body[data-role="editor"] [data-admin-only], body[data-role="editor"] #sync-button, body[data-role="editor"] #add-button, body[data-role="editor"] #export-button, body[data-role="editor"] #archive-question, body[data-role="editor"] [data-tab="source"] { display: none !important; }
@media (max-width: 760px) {
  .auth-screen { grid-template-columns: 1fr; }
  .auth-brand { display: none; }
  .auth-entry { min-height: 100dvh; padding: 36px 24px; }
  .auth-mobile-logo { display: block; }
  .auth-card h2 { font-size: 27px; }
  .account-intro { align-items: flex-start; flex-direction: column; gap: 12px; }
  .my-account-panel { grid-template-columns: 1fr; gap: 28px; padding: 24px; }
  .account-password-form { border-left: 0; border-top: 1px solid var(--border); padding: 25px 0 0; max-width: none; }
}
@media (max-width: 720px) {
  .sidebar .account-sidebar { display: flex; flex-direction: column; padding: 14px 0; width: 100%; border-top: 1px solid rgba(255,255,255,.15); }
  .sidebar .account-sidebar-copy { display: none; }
  .account-logout { padding: 5px 0; font-size: 11px; }
  .account-top-summary { display: block; max-width: 125px; }
  .topbar-right .local-chip, .topbar-right .top-avatar { display: none; }
}
