/* AlephIQ Auth & Account screens
 * Builds on aleph.css (reuses tokens & buttons).
 * Each screen lives inside a 1280×800 artboard.
 */

/* ---------- Artboard frame (browser chrome optional) ---------- */
.au-frame {
  width: 1280px;
  height: 800px;
  background: var(--aleph-bg);
  color: var(--aleph-ink);
  font-family: var(--font-sans);
  display: flex;
  position: relative;
  overflow: hidden;
}

.au-link { color: var(--aleph-primary); font-weight: 600; }
.au-link:hover { color: var(--aleph-primary-deep); text-decoration: underline; }
.au-link-warn { color: var(--aleph-gold); font-weight: 600; }
.au-link-warn:hover { color: var(--aleph-gold-deep); }

/* ============================================================
   SPLIT LAYOUT — used for login / signup / pwd-reset / reset-from-key
   Left rail = brand + reassurance, Right = form
   ============================================================ */
.au-split { display: flex; width: 100%; height: 100%; }

.au-left {
  flex: 0 0 460px;
  background: var(--aleph-navy);
  color: #fff;
  position: relative;
  padding: 44px 44px 36px;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}
.au-left::before {
  /* glow */
  content: "";
  position: absolute; inset: 0;
  background:
    radial-gradient(700px 360px at 80% -10%, rgba(26,175,179,0.22), transparent 60%),
    radial-gradient(500px 320px at -10% 110%, rgba(201,164,92,0.16), transparent 60%);
  pointer-events: none;
}
.au-left::after {
  /* grid */
  content: "";
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.04) 1px, transparent 1px);
  background-size: 32px 32px;
  mask-image: radial-gradient(ellipse 600px 400px at 50% 60%, black 30%, transparent 80%);
  pointer-events: none;
}
.au-left > * { position: relative; z-index: 1; }

.au-brand {
  display: flex; align-items: center; gap: 12px;
}
.au-brand-mark {
  width: 36px; height: 36px;
  border-radius: 9px;
  background: linear-gradient(135deg, var(--aleph-teal) 0%, #0a8a8e 100%);
  display: grid; place-items: center;
  font-family: var(--font-display);
  font-weight: 800; font-size: 17px;
  letter-spacing: -0.05em;
  color: #fff;
}
.au-brand-name {
  font-weight: 800;
  font-size: 20px;
  letter-spacing: -0.01em;
}

.au-left-body {
  margin-top: auto;
  padding-top: 80px;
}
.au-eyebrow {
  font-size: 11px; font-weight: 700;
  letter-spacing: 0.22em; text-transform: uppercase;
  color: var(--aleph-teal);
}
.au-headline {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 40px;
  line-height: 1.04;
  letter-spacing: -0.02em;
  margin: 14px 0 16px;
  text-wrap: balance;
}
.au-headline em {
  font-style: italic;
  font-weight: 500;
  color: var(--aleph-gold);
}
.au-sub {
  color: rgba(255,255,255,0.72);
  font-size: 15px;
  line-height: 1.55;
  max-width: 360px;
}

/* Mini chart sparkline strip */
.au-spark {
  margin-top: 28px;
  display: flex; align-items: flex-end;
  gap: 4px;
  height: 64px;
}
.au-spark span {
  flex: 1;
  background: linear-gradient(to top, rgba(26,175,179,0.45), rgba(26,175,179,0.95));
  border-radius: 2px 2px 0 0;
}

/* Trust strip */
.au-trust {
  margin-top: 32px;
  display: flex; flex-wrap: wrap; gap: 8px 12px;
  border-top: 1px solid rgba(255,255,255,0.08);
  padding-top: 20px;
}
.au-trust-item {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 12px; font-weight: 600;
  color: rgba(255,255,255,0.78);
  letter-spacing: 0.02em;
}
.au-trust-item svg { width: 14px; height: 14px; }
.au-trust-dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--aleph-up);
  box-shadow: 0 0 0 4px rgba(22,163,110,0.15);
}

/* ---------- Right form panel ---------- */
.au-right {
  flex: 1;
  background: var(--aleph-bg);
  display: flex;
  flex-direction: column;
}
.au-right-top {
  display: flex; align-items: center; justify-content: flex-end;
  padding: 24px 44px;
  font-size: 13px;
  color: var(--aleph-ink-3);
}
.au-right-top a { margin-left: 6px; color: var(--aleph-ink); font-weight: 700; }
.au-right-top a:hover { color: var(--aleph-primary); }

.au-right-body {
  flex: 1;
  display: flex; align-items: center; justify-content: center;
  padding: 0 44px 44px;
}
.au-form-wrap {
  width: 100%;
  max-width: 420px;
}
.au-form-title {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 32px;
  letter-spacing: -0.02em;
  margin: 0 0 8px;
  color: var(--aleph-ink);
}
.au-form-sub {
  font-size: 14.5px;
  color: var(--aleph-ink-2);
  margin: 0 0 28px;
  line-height: 1.55;
}

/* Social providers */
.au-social {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 22px;
}
.au-social-btn {
  display: flex; align-items: center; justify-content: center;
  gap: 10px;
  height: 46px;
  border: 1px solid var(--aleph-line);
  border-radius: 10px;
  background: #fff;
  font-weight: 600; font-size: 14px;
  color: var(--aleph-ink);
  transition: border-color .15s, background .15s;
}
.au-social-btn:hover { border-color: var(--aleph-ink); background: var(--aleph-bg-tint); }
.au-social-btn svg { width: 18px; height: 18px; }

.au-divider {
  display: flex; align-items: center;
  gap: 12px;
  margin: 18px 0 22px;
  font-size: 11px; font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--aleph-ink-3);
}
.au-divider::before, .au-divider::after {
  content: ""; flex: 1; height: 1px; background: var(--aleph-line);
}

/* Form field */
.au-field { margin-bottom: 14px; }
.au-label {
  display: block;
  font-size: 12px; font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--aleph-ink-2);
  margin-bottom: 6px;
}
.au-input {
  display: block;
  width: 100%;
  height: 48px;
  padding: 0 16px;
  border: 1.5px solid var(--aleph-line);
  border-radius: 10px;
  background: #fff;
  color: var(--aleph-ink);
  font-family: inherit;
  font-size: 15px;
  outline: none;
  transition: border-color .15s, box-shadow .15s;
}
.au-input::placeholder { color: var(--aleph-ink-3); }
.au-input:focus {
  border-color: var(--aleph-primary);
  box-shadow: 0 0 0 4px rgba(26,175,179,0.12);
}
.au-input.has-icon { padding-left: 44px; }

.au-input-wrap { position: relative; }
.au-input-icon {
  position: absolute; left: 14px; top: 50%;
  transform: translateY(-50%);
  width: 18px; height: 18px;
  color: var(--aleph-ink-3);
  pointer-events: none;
}
.au-input-trail {
  position: absolute; right: 12px; top: 50%;
  transform: translateY(-50%);
  font-size: 12px; font-weight: 700;
  color: var(--aleph-ink-3);
  letter-spacing: 0.06em;
  background: none; border: 0; padding: 4px 6px;
  cursor: pointer;
}
.au-input-trail:hover { color: var(--aleph-primary); }

.au-help {
  display: flex; align-items: center; justify-content: space-between;
  margin: 4px 0 22px;
  font-size: 13px;
}
.au-help a { color: var(--aleph-primary); font-weight: 600; }
.au-checkbox { display: inline-flex; align-items: center; gap: 8px; color: var(--aleph-ink-2); }
.au-checkbox input { width: 16px; height: 16px; accent-color: var(--aleph-primary); }

.au-submit {
  display: flex; align-items: center; justify-content: center;
  gap: 8px;
  width: 100%;
  height: 50px;
  border: 0;
  background: var(--aleph-navy);
  color: #fff;
  font-weight: 700;
  font-size: 15px;
  border-radius: 10px;
  cursor: pointer;
  transition: background .15s, transform .12s;
}
.au-submit:hover { background: var(--aleph-navy-2); }
.au-submit.is-primary { background: var(--aleph-primary); }
.au-submit.is-primary:hover { background: var(--aleph-primary-deep); }
.au-submit:active { transform: scale(.99); }

.au-foot {
  margin-top: 22px;
  font-size: 13px;
  color: var(--aleph-ink-3);
  text-align: center;
  line-height: 1.6;
}
.au-foot a { color: var(--aleph-ink); font-weight: 700; }
.au-foot a:hover { color: var(--aleph-primary); }

/* Tiny legal microcopy bottom of right pane */
.au-right-foot {
  padding: 0 44px 24px;
  display: flex; justify-content: space-between;
  font-size: 12px; color: var(--aleph-ink-3);
}
.au-right-foot a:hover { color: var(--aleph-ink); }

/* Password strength bar */
.au-strength {
  display: flex; gap: 4px; margin-top: 8px;
}
.au-strength span {
  flex: 1; height: 4px; border-radius: 2px;
  background: var(--aleph-line);
}
.au-strength span.on { background: var(--aleph-primary); }
.au-strength-label {
  font-size: 11px; font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--aleph-ink-3);
  margin-top: 6px;
  text-transform: uppercase;
}

/* ============================================================
   APP-SHELL LAYOUT — used for /account/email and /account/password/change
   Logged-in user; sidebar nav with section list
   ============================================================ */
.au-shell { display: flex; flex-direction: column; width: 100%; height: 100%; background: var(--aleph-bg-tint); }

.au-topbar {
  display: flex; align-items: center; justify-content: space-between;
  height: 64px;
  background: var(--aleph-navy);
  color: #fff;
  padding: 0 32px;
  flex: 0 0 64px;
}
.au-topbar .au-brand-name { font-size: 18px; }
.au-topbar-links { display: flex; align-items: center; gap: 4px; font-size: 13.5px; }
.au-topbar-links a { padding: 8px 12px; color: rgba(255,255,255,0.72); border-radius: 6px; }
.au-topbar-links a:hover { color: #fff; background: rgba(255,255,255,0.06); }
.au-topbar-links a.active { color: #fff; background: rgba(255,255,255,0.08); }
.au-avatar {
  width: 36px; height: 36px; border-radius: 50%;
  background: linear-gradient(135deg, var(--aleph-teal), var(--aleph-gold));
  display: grid; place-items: center;
  font-weight: 800; color: #fff; font-size: 13px;
  margin-left: 14px;
}
.au-portfolio-pill {
  display: inline-flex; align-items: center; gap: 8px;
  background: rgba(255,255,255,0.07);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 999px;
  padding: 6px 12px;
  font-size: 12px;
  margin-left: 8px;
  font-family: var(--font-mono);
  color: #fff;
}
.au-portfolio-pill .up { color: var(--aleph-up); font-weight: 700; }

.au-shell-body { flex: 1; display: flex; min-height: 0; }
.au-side {
  flex: 0 0 240px;
  background: #fff;
  border-right: 1px solid var(--aleph-line);
  padding: 28px 14px;
  display: flex; flex-direction: column;
  gap: 2px;
}
.au-side-section {
  font-size: 11px; font-weight: 800;
  letter-spacing: 0.18em;
  color: var(--aleph-ink-3);
  text-transform: uppercase;
  padding: 14px 14px 6px;
}
.au-side-link {
  display: flex; align-items: center; gap: 12px;
  padding: 9px 14px;
  border-radius: 8px;
  font-size: 14px; font-weight: 500;
  color: var(--aleph-ink-2);
}
.au-side-link svg { width: 16px; height: 16px; opacity: .7; }
.au-side-link:hover { background: var(--aleph-bg-tint); color: var(--aleph-ink); }
.au-side-link.active {
  background: var(--aleph-bg-tint);
  color: var(--aleph-ink);
  font-weight: 700;
  position: relative;
}
.au-side-link.active::before {
  content: ""; position: absolute; left: -14px; top: 8px; bottom: 8px;
  width: 3px; background: var(--aleph-primary); border-radius: 0 3px 3px 0;
}

.au-shell-main {
  flex: 1;
  padding: 40px 56px;
  overflow: auto;
}
.au-page-eyebrow {
  font-size: 11px; font-weight: 800;
  letter-spacing: 0.22em; text-transform: uppercase;
  color: var(--aleph-primary);
  margin-bottom: 8px;
}
.au-page-title {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 32px;
  letter-spacing: -0.02em;
  margin: 0 0 10px;
  color: var(--aleph-ink);
}
.au-page-sub {
  color: var(--aleph-ink-2);
  font-size: 15px;
  margin: 0 0 28px;
  max-width: 600px;
}

.au-card {
  background: #fff;
  border: 1px solid var(--aleph-line);
  border-radius: 14px;
  padding: 28px;
}
.au-card + .au-card { margin-top: 18px; }
.au-card-title {
  font-weight: 800;
  font-size: 18px;
  margin: 0 0 8px;
  color: var(--aleph-ink);
}
.au-card-sub {
  color: var(--aleph-ink-2);
  font-size: 14px;
  margin: 0 0 20px;
}

/* Email list rows */
.au-email-row {
  display: flex; align-items: center; gap: 12px;
  padding: 14px 0;
  border-bottom: 1px solid var(--aleph-line-soft);
}
.au-email-row:last-child { border-bottom: 0; }
.au-radio {
  width: 18px; height: 18px;
  border: 2px solid var(--aleph-line); border-radius: 50%;
  position: relative; flex: 0 0 18px;
}
.au-radio.on { border-color: var(--aleph-primary); }
.au-radio.on::after {
  content: ""; position: absolute; inset: 3px;
  border-radius: 50%; background: var(--aleph-primary);
}
.au-email-addr { flex: 1; font-weight: 600; }
.au-pill {
  display: inline-flex; align-items: center; gap: 5px;
  height: 22px; padding: 0 10px;
  border-radius: 999px;
  font-size: 11px; font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.au-pill.verified { background: var(--aleph-up-soft); color: var(--aleph-up); }
.au-pill.unverified { background: var(--aleph-down-soft); color: var(--aleph-down); }
.au-pill.primary { background: rgba(201,164,92,0.16); color: var(--aleph-gold-deep); }

.au-row-actions { display: flex; gap: 8px; margin-top: 16px; }
.au-mini-btn {
  height: 36px;
  padding: 0 14px;
  border: 1px solid var(--aleph-line);
  background: #fff;
  border-radius: 8px;
  font-weight: 700;
  font-size: 13px;
  color: var(--aleph-ink);
  display: inline-flex; align-items: center; gap: 6px;
  cursor: pointer;
}
.au-mini-btn:hover { border-color: var(--aleph-ink); }
.au-mini-btn.danger { border-color: var(--aleph-down); color: var(--aleph-down); }
.au-mini-btn.danger:hover { background: var(--aleph-down-soft); }

/* ============================================================
   NOTICE LAYOUT — centered card on tinted bg
   used for: verification_sent, verified_email_required,
            password_reset_done, password_reset_from_key_done,
            email_confirm, account_inactive, signup_closed, logout
   ============================================================ */
.au-notice {
  width: 100%;
  height: 100%;
  display: flex; flex-direction: column;
  background: var(--aleph-bg-tint);
}
.au-notice-top {
  height: 64px;
  background: var(--aleph-navy);
  color: #fff;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 32px;
  flex: 0 0 64px;
}
.au-notice-body {
  flex: 1;
  display: grid; place-items: center;
  padding: 40px;
}
.au-notice-card {
  width: 540px;
  max-width: 100%;
  background: #fff;
  border-radius: 18px;
  padding: 44px 44px 36px;
  border: 1px solid var(--aleph-line);
  box-shadow: 0 30px 60px -30px rgba(10,26,44,0.18);
  text-align: center;
}
.au-notice-icon {
  width: 64px; height: 64px;
  border-radius: 16px;
  background: var(--aleph-bg-tint);
  display: grid; place-items: center;
  margin: 0 auto 22px;
  color: var(--aleph-primary);
}
.au-notice-icon.success { background: var(--aleph-up-soft); color: var(--aleph-up); }
.au-notice-icon.warn { background: rgba(201,164,92,0.16); color: var(--aleph-gold-deep); }
.au-notice-icon.danger { background: var(--aleph-down-soft); color: var(--aleph-down); }
.au-notice-icon svg { width: 30px; height: 30px; }

.au-notice-title {
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 28px;
  letter-spacing: -0.02em;
  margin: 0 0 10px;
  text-wrap: balance;
}
.au-notice-text {
  color: var(--aleph-ink-2);
  font-size: 15px;
  line-height: 1.55;
  margin: 0 0 24px;
  text-wrap: pretty;
}
.au-notice-text code {
  font-family: var(--font-mono);
  background: var(--aleph-bg-tint);
  padding: 2px 8px; border-radius: 6px;
  font-size: 13px;
  color: var(--aleph-ink);
}
.au-notice-actions {
  display: flex; gap: 10px; justify-content: center;
}
.au-notice-secondary {
  margin-top: 22px;
  font-size: 13px;
  color: var(--aleph-ink-3);
  border-top: 1px solid var(--aleph-line-soft);
  padding-top: 20px;
}

/* misc */
.au-callout {
  display: flex; gap: 12px;
  background: var(--aleph-bg-tint);
  border-radius: 10px;
  padding: 14px 16px;
  font-size: 13px;
  color: var(--aleph-ink-2);
  line-height: 1.5;
  margin-top: 16px;
}
.au-callout svg { flex: 0 0 18px; width: 18px; height: 18px; color: var(--aleph-primary); margin-top: 2px; }

.au-error {
  display: flex; gap: 10px; align-items: flex-start;
  background: var(--aleph-down-soft);
  border: 1px solid rgba(224,79,79,0.25);
  border-radius: 10px;
  padding: 12px 14px;
  margin-bottom: 18px;
  color: #8a2929;
  font-size: 13.5px;
  line-height: 1.45;
}
.au-error svg { flex: 0 0 18px; width: 18px; height: 18px; color: var(--aleph-down); margin-top: 2px; }
