/* 8xQuant — premium login page */

/* ---------- home-matched typography (login only) ----------
   Same roles as About/Pricing/Contact: Georgia serif headlines in natural
   case, system-sans paragraphs. Scoped to .account-page:not([data-billing-page])
   so the billing pages keep their current typography. Panel titles, note
   labels and figures keep their designed Doto/mono treatments. */
.account-page:not([data-billing-page]) h1.manrope-heading,
.account-page:not([data-billing-page]) h2.manrope-heading {
  font-family: Georgia, "Times New Roman", Times, serif;
  font-weight: 400;
  letter-spacing: -.01em;
  text-transform: none;
  text-wrap: balance;
}
.account-page:not([data-billing-page]) .tape-hero h1 { font-size: clamp(44px, 6.4vw, 88px); line-height: .98; }
.account-page:not([data-billing-page]) .account-context h2 { font-size: clamp(32px, 4.4vw, 58px); line-height: 1.04; }
.account-page:not([data-billing-page]) .tape-hero-copy > p,
.account-page:not([data-billing-page]) .account-hero-aside p,
.account-page:not([data-billing-page]) .account-context > p,
.account-page:not([data-billing-page]) .account-note-row p,
.account-page:not([data-billing-page]) .account-note-foot p,
.account-page:not([data-billing-page]) .login-panel-title p {
  font-family: -apple-system, BlinkMacSystemFont, "Inter", sans-serif;
}

.account-page {
  --ink: var(--text);
  --quiet: #77746e;
}
.account-page main { padding-bottom: 76px; }
.account-page .btn { border-radius: 7px; }
.account-page .btn.primary { background: var(--ember); }
.account-page .section-index {
  color: var(--ember);
  font-size: 10px;
  letter-spacing: 1.8px;
  text-transform: uppercase;
}
.account-page h2 span,
.account-page h3 span { color: var(--ember); }

/* ---------- hero ---------- */
.account-page .tape-hero { padding-bottom: 88px; }
.account-page .tape-hero-copy > p { max-width: 600px; }
.account-hero-aside {
  max-width: 260px;
  flex-direction: column;
  align-items: flex-start;
  gap: 18px;
  padding: 0 0 5px 22px;
  border-left: 1px dashed var(--line2);
}
.account-signal {
  color: var(--ink);
  font-size: 10px;
  letter-spacing: 1.8px;
  text-transform: uppercase;
}
.account-signal .status-dot { margin-right: 8px; }
.account-hero-aside p {
  color: var(--muted);
  font-size: 11px;
  line-height: 1.7;
}

/* ---------- account workspace ---------- */
.account-workspace {
  display: grid;
  grid-template-columns: minmax(0, .78fr) minmax(430px, 1.22fr);
  gap: clamp(42px, 7vw, 100px);
  padding: 90px 0 104px;
  border-top: 1px solid var(--line);
}
.account-context h2 {
  margin-top: 20px;
  color: var(--ink);
  font-family: var(--dot);
  font-size: clamp(30px, 4.2vw, 58px);
  font-weight: 400;
  letter-spacing: 2.5px;
  line-height: 1.02;
  text-transform: uppercase;
}
.account-context > p {
  max-width: 440px;
  margin-top: 24px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.75;
}
.account-notes {
  list-style: none;
  margin-top: 42px;
  border-top: 1px solid var(--line);
}
.account-note-row {
  display: grid;
  grid-template-columns: 52px minmax(0, 1fr);
  gap: 18px;
  padding: 20px 0 22px;
  border-bottom: 1px dashed var(--line);
}
.account-note-row > span {
  color: var(--ember);
  font-family: var(--dot);
  font-size: 27px;
  line-height: .95;
}
.account-note-row h3 {
  color: var(--ink);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 1.5px;
  text-transform: uppercase;
}
.account-note-row p {
  margin-top: 7px;
  color: var(--muted);
  font-size: 11.5px;
  line-height: 1.6;
}
.account-note-row a {
  color: var(--ember);
  text-decoration: none;
}
.account-note-row a:hover { color: var(--ink); }
.account-note-foot {
  margin-top: 34px;
  padding-top: 23px;
  border-top: 1px solid var(--line);
}
.account-note-label,
.form-meta {
  color: var(--quiet);
  font-size: 9px;
  letter-spacing: 1.7px;
  text-transform: uppercase;
}
.account-note-foot p {
  max-width: 430px;
  margin: 10px 0 12px;
  color: var(--muted);
  font-size: 11.5px;
  line-height: 1.65;
}
.inline-link {
  color: var(--ember);
  font-size: 10px;
  letter-spacing: 1.4px;
  text-decoration: none;
  text-transform: uppercase;
}
.inline-link:hover { color: var(--ink); }

/* ---------- account access panel ---------- */
.login-panel {
  min-width: 0;
  padding: 30px;
  background: rgba(255, 255, 255, .04);
  -webkit-backdrop-filter: blur(12px) saturate(140%);
  backdrop-filter: blur(12px) saturate(140%);
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: 0 20px 44px rgba(0, 0, 0, .28), inset 0 1px 0 rgba(255, 255, 255, .035);
}
.login-panel-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 18px;
  padding-bottom: 20px;
  border-bottom: 1px dashed var(--line);
}
.login-panel-title { padding: 26px 0 25px; }
.login-panel-title h2 {
  color: var(--ink);
  font-family: var(--dot);
  font-size: clamp(24px, 3vw, 36px);
  font-weight: 400;
  letter-spacing: 2px;
  line-height: 1.1;
  text-transform: uppercase;
}
.login-panel-title p {
  max-width: 520px;
  margin-top: 12px;
  color: var(--muted);
  font-size: 11.5px;
  line-height: 1.65;
}
.login-panel-title strong { color: var(--ink); font-weight: 500; }
.auth-mode-toggle {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
  margin-top: 24px;
  padding: 4px;
  background: rgba(255, 255, 255, .025);
  border: 1px solid var(--line);
  border-radius: 7px;
}
.auth-mode-btn {
  min-height: 38px;
  padding: 8px 12px;
  border: 1px dashed var(--line2);
  border-radius: 5px;
  background: transparent;
  color: var(--muted);
  font: 10px var(--mono);
  letter-spacing: 1.4px;
  text-transform: uppercase;
  cursor: pointer;
}
.auth-mode-btn:hover,
.auth-mode-btn:focus-visible { color: var(--ink); border-color: var(--ember); }
.auth-mode-btn:focus-visible { outline: 2px solid var(--ember); outline-offset: 2px; }
.auth-mode-btn.is-active {
  background: var(--ember);
  border-color: var(--ember);
  color: #000;
  font-weight: 800;
}
.auth-mode-note {
  margin-top: 20px;
  color: var(--muted);
  font-size: 10.5px;
  line-height: 1.6;
}
.auth-mode-link {
  padding: 0;
  border: 0;
  background: transparent;
  font: 10px var(--mono);
  cursor: pointer;
}
.auth-mode-link:hover { background: transparent; }
.account-page #loginForm { gap: 18px; }
.account-page #signupForm { gap: 18px; }
.account-page .field { min-width: 0; }
.account-page label { display: block; margin: 0 0 8px; font-size: 9px; letter-spacing: 1.7px; }
.account-page input {
  width: 100%;
  min-height: 46px;
  background: #0d0b09;
  border-color: var(--line);
  border-radius: 6px;
  font-size: 12px;
}
.account-page input:focus { border-color: var(--ember); }
.account-page .fielderr { margin-top: 0; }
.totp-reauth-note {
  margin-top: 8px;
  color: var(--quiet);
  font-size: 10.5px;
  line-height: 1.5;
}
.account-page .btn.full { margin-top: 0; min-height: 48px; border-radius: 6px; }
.account-note-actions { margin-top: 16px; }
.signed-actions { margin-top: 30px; }
.signed-actions .btn { min-height: 46px; }
.verification-actions { margin-top: 30px; }
.verification-actions .btn { flex: 1 1 180px; min-height: 46px; text-align: center; }

/* ---------- authenticator setup ---------- */
.totp-account-status {
  margin-top: 2px;
  padding: 13px 15px;
  border: 1px dashed var(--line2);
  border-radius: 7px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.65;
}
.totp-account-status.is-ready {
  border-color: rgba(67, 214, 124, .35);
  color: #9ff0bf;
}
.totp-account-status.is-needed {
  border-color: rgba(236,1,28, .45);
  color: var(--ink);
}
.totp-start-over {
  display: block;
  margin-top: 22px;
  padding: 0;
  border: 0;
  background: transparent;
  font: 10px var(--mono);
  cursor: pointer;
}
.totp-start-over:hover { background: transparent; }
.totp-setup-details[hidden] { display: none; }
.totp-setup-grid {
  display: grid;
  grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr);
  gap: 14px;
  margin-bottom: 24px;
}
.totp-qr-card,
.totp-secret-card {
  min-width: 0;
  padding: 14px;
  background: rgba(255, 255, 255, .025);
  border: 1px solid var(--line);
  border-radius: 7px;
}
.totp-qr-label {
  margin-bottom: 12px;
  color: var(--quiet);
  font-size: 9px;
  letter-spacing: 1.3px;
  line-height: 1.45;
  text-transform: uppercase;
}
.totp-qr-card canvas {
  display: block;
  width: min(100%, 220px);
  height: auto;
  margin: 0 auto;
  background: #f2f0ea;
  border-radius: 3px;
}
.totp-qr-fallback[hidden] { display: none; }
.totp-qr-fallback {
  margin-top: 10px;
  color: var(--muted);
  font-size: 10px;
  line-height: 1.5;
}
.totp-secret-card code {
  display: block;
  padding: 10px;
  overflow-wrap: anywhere;
  background: #0d0b09;
  border: 1px solid var(--line);
  border-radius: 5px;
  color: var(--ink);
  font: 12px/1.55 var(--mono);
  letter-spacing: 1px;
  word-break: break-word;
}
.totp-secret-card p {
  margin-top: 12px;
  color: var(--muted);
  font-size: 10.5px;
  line-height: 1.6;
}

/* ---------- responsive ---------- */
@media (max-width: 980px) {
  .account-workspace { grid-template-columns: 1fr; gap: 64px; }
  .account-context > p { max-width: 620px; }
  .account-hero-aside { max-width: 380px; }
}

@media (max-width: 700px) {
  .account-page main { padding-bottom: 54px; }
  .account-page .tape-hero { padding-bottom: 70px; }
  .account-workspace { padding: 68px 0 78px; }
  .account-context h2 { font-size: clamp(32px, 10vw, 48px); }
  .login-panel { padding: 23px; }
  .login-panel-head { align-items: flex-start; flex-direction: column; gap: 10px; }
  .signed-actions { flex-direction: column; }
  .signed-actions .btn { width: 100%; text-align: center; }
  .account-hero-aside { padding-left: 16px; }
  .totp-setup-grid { grid-template-columns: 1fr; }
}

/* ---------- scroll reveal (same gate as home: home-reveal.js adds .js-reveal
   + .is-shown; content stays fully visible without JS, observers, or motion) ---------- */
.js-reveal .reveal { opacity: 0; translate: 0 22px; }
.js-reveal .reveal.is-shown { animation: reveal-in .7s cubic-bezier(.22,.61,.36,1) both; }
.js-reveal .account-notes .account-note-row:nth-child(2).is-shown { animation-delay: .08s; }
.js-reveal .account-note-foot.is-shown { animation-delay: .16s; }
@keyframes reveal-in {
  from { opacity: 0; translate: 0 22px; }
  to { opacity: 1; translate: none; }
}

@media (prefers-reduced-motion: reduce) {
  .account-page .status-dot { box-shadow: none; }
  .js-reveal .reveal { opacity: 1; translate: none; }
  .js-reveal .reveal.is-shown { animation: none; }
}
