/* Account pages (round 31): /login /signup /verify /forgot /reset /account (auth.html + auth.js) and /brokers.
   Linked after /pub/site.css; uses its tokens so dark and light follow the shell. Rules are scoped to body.ax. */
:root { --dim: var(--sx-dim); --text: var(--sx-text); --line: var(--sx-line2); --accent: var(--sx-accent); --err: var(--sx-red); --ok: var(--sx-green);
  --ax-field: #0f0f0f; --ax-field-line: #3d3d3d; --ax-panel: #0c0c0c; --ax-hover: rgba(255,255,255,.06); --ax-on: rgba(255,255,255,.1); }
@media (prefers-color-scheme: light) {
  :root { --ax-field: #ffffff; --ax-field-line: #d1d4dc; --ax-panel: #ffffff; --ax-hover: rgba(0,0,0,.04); --ax-on: rgba(0,0,0,.07); }
}
.ax { font-size: 15px; line-height: 1.5; }
.ax a { color: var(--sx-accent); }
.ax a:hover { text-decoration: underline; }
.ax .sx-top .sx-brand, .ax .sx-foot .sx-brand { color: var(--sx-text); }
.ax .sx-foot .sx-brand { display: flex; padding: 0; margin-bottom: 12px; }
.ax .sx-top a:hover, .ax .sx-foot a:hover, .ax a.sx-btn:hover { text-decoration: none; }
.ax .sx-top .sx-nav a, .ax .sx-top .sx-ghost { color: var(--sx-text); }
.ax .sx-top .sx-act a.sx-btn:not(.sx-ghost) { color: var(--sx-btn-text); }
.ax .sx-foot { margin-top: 0; }
.ax .sx-foot a:not(.sx-brand) { color: var(--sx-body); }
.ax .sx-foot a:hover { color: var(--sx-text); }

/* split: art panel left, form right (the sign-in look) */
.ax-split { display: grid; grid-template-columns: minmax(0, 700px) minmax(0, 1fr); gap: 16px; min-height: calc(100vh - 64px); padding: 8px 8px 48px; }
.ax-art { position: relative; overflow: hidden; border-radius: 16px; min-height: 560px; padding: 72px 48px 0; text-align: center; color: #fff;
  background: radial-gradient(700px 420px at 50% 72%, rgba(41,98,255,.55), rgba(120,60,255,.22) 45%, transparent 75%),
              radial-gradient(500px 300px at 85% 10%, rgba(120,60,255,.25), transparent 70%), linear-gradient(180deg, #05060c 0%, #0b1030 100%); }
.ax-art-title { margin: 0; font-size: clamp(34px, 3.4vw, 48px); line-height: 1.1; color: #fff; }
.ax-art-sub { margin: 18px auto 0; max-width: 420px; color: rgba(255,255,255,.72); font-size: 17px; }
.ax-art-chart { position: absolute; left: 0; right: 0; bottom: 0; width: 100%; height: 58%; }
.ax-bars rect { fill: #22ab94; opacity: .55; }
.ax-bars rect.dn { fill: #f23645; }
.ax-main { display: flex; align-items: center; justify-content: center; padding: 40px 16px; min-width: 0; }

/* the card */
.ax-card { width: 100%; max-width: 400px; }
.ax-card h1 { font: 600 32px/1.2 var(--sx-display); letter-spacing: -.02em; text-align: center; margin: 0 0 8px; }
.ax .sub { color: var(--sx-body); margin: 0 0 24px; text-align: center; }
.ax .sub b { color: var(--sx-text); font-weight: 600; }
.ax label { display: block; color: var(--sx-text); font-size: 14px; font-weight: 500; margin: 16px 0 6px; }
.ax input, .ax select, .ax textarea { width: 100%; height: 44px; padding: 0 14px; border-radius: 8px; border: 1px solid var(--ax-field-line); background: var(--ax-field);
  color: var(--sx-text); font: 16px var(--sx-ui); outline: none; transition: border-color .15s, box-shadow .15s; }
.ax select { padding: 0 10px; cursor: pointer; }
.ax textarea { height: auto; padding: 10px 12px; font: 12px/17px Consolas, "SF Mono", monospace; resize: none; }
.ax input:hover, .ax select:hover { border-color: var(--sx-dim); }
.ax input:focus, .ax select:focus, .ax textarea:focus { border-color: var(--sx-accent); box-shadow: 0 0 0 3px rgba(41,98,255,.22); }
.ax input[readonly] { color: var(--sx-body); }
.ax input[type=radio], .ax input[type=checkbox] { width: auto; height: auto; accent-color: var(--sx-accent); margin: 0 8px 0 0; box-shadow: none; }
.ax input.code { font: 600 28px var(--sx-ui); letter-spacing: 12px; text-align: center; height: 60px; }
.ax .pw { position: relative; }
.ax .pw input { padding-right: 72px; }
.ax .pw button { position: absolute; right: 6px; top: 6px; height: 32px; padding: 0 12px; border: 0; border-radius: 6px; background: var(--ax-on); color: var(--sx-text);
  cursor: pointer; font: 500 13px var(--sx-ui); }
.ax .pw button:hover { background: var(--ax-hover); outline: 1px solid var(--ax-field-line); }
.ax .hint { color: var(--sx-dim); font-size: 13px; line-height: 1.5; margin: 6px 0 0; }
.ax .hint.good { color: var(--sx-green); }
.ax .hint.bad { color: var(--sx-red); }
.ax .meter { height: 4px; border-radius: 2px; background: var(--sx-line); margin-top: 8px; overflow: hidden; }
.ax .meter i { display: block; height: 100%; width: 0; background: var(--sx-red); transition: width .15s, background .15s; }
.ax .opts { display: flex; flex-wrap: wrap; gap: 6px; margin: 8px 0 0; }
.ax .opts:empty { display: none; }
.ax .opt { font: 500 13px var(--sx-ui); color: var(--sx-text); background: transparent; border: 1px solid var(--ax-field-line); border-radius: 40px; padding: 5px 12px; cursor: pointer; }
.ax .opt:hover { background: var(--ax-hover); }
.ax .opt.on { border-color: var(--sx-green); color: var(--sx-green); }
.ax .msg { min-height: 20px; color: var(--sx-red); margin: 14px 0 6px; font-size: 14px; }
.ax .msg.ok { color: var(--sx-green); }
.ax .msg:empty { margin: 8px 0 0; }

/* primary = the shell's filled button (light on dark, dark on light), 48 tall; ghost = outline */
.ax .go { display: flex; align-items: center; justify-content: center; width: 100%; height: 48px; margin-top: 8px; border-radius: 8px; border: 1px solid var(--sx-btn);
  background: var(--sx-btn); color: var(--sx-btn-text); font: 600 16px var(--sx-ui); cursor: pointer; transition: background .15s, border-color .15s; }
.ax .go:hover { background: var(--sx-btn-hover); border-color: var(--sx-btn-hover); text-decoration: none; }
.ax .go:disabled { opacity: .55; cursor: default; }
.ax .go.ghost { background: transparent; border-color: var(--ax-field-line); color: var(--sx-text); margin-top: 10px; font-weight: 500; height: auto; min-height: 44px; padding: 8px 18px; text-align: center; line-height: 1.35; }
.ax .go.ghost:hover { background: var(--ax-hover); }
.ax a.go { color: var(--sx-btn-text); }
.ax a.go.ghost { color: var(--sx-text); }
.ax .row { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-top: 12px; font-size: 14px; }
.ax .foot { color: var(--sx-body); font-size: 14px; margin: 28px 0 0; padding-top: 22px; text-align: center; border-top: 1px solid var(--sx-line); }
.ax .linkbtn { background: none; border: 0; padding: 0; color: var(--sx-accent); cursor: pointer; font: inherit; }
.ax .linkbtn:hover { text-decoration: underline; }
.ax .linkbtn:disabled { color: var(--sx-dim); cursor: default; text-decoration: none; }
.ax .done { width: 56px; height: 56px; border-radius: 28px; background: rgba(34,171,148,.15); display: flex; align-items: center; justify-content: center; margin: 8px auto 18px; }
.ax .done::after { content: ""; width: 20px; height: 10px; border-left: 3px solid var(--sx-green); border-bottom: 3px solid var(--sx-green); transform: rotate(-45deg) translate(2px,-2px); }

/* key / value rows (account, brokers) */
.ax .kv { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 16px 0; border-bottom: 1px solid var(--sx-line); min-width: 0; }
.ax .kv > span:first-child { color: var(--sx-dim); flex: none; }
.ax .kv > span:last-child { color: var(--sx-text); text-align: right; min-width: 0; overflow-wrap: anywhere; }
.ax .kv:last-child { border-bottom: 0; }

/* settings layout: /account and /brokers (left list, right panel) */
.ax-wide .ax-split { display: block; min-height: 0; padding: 0; }
.ax-wide .ax-art { display: none; }
.ax-wide .ax-main { display: block; padding: 0; }
.ax-wide .ax-card { max-width: none; }
.ax-set { max-width: 1120px; margin: 0 auto; padding: 48px 40px 96px; }
.ax-set > h1, .ax-wide .ax-card .ax-set > h1 { font: 600 40px/1.15 var(--sx-display); letter-spacing: -.03em; text-align: left; margin: 0 0 32px; }
.ax-cols { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 40px; align-items: start; }
.ax-side { position: sticky; top: 88px; display: flex; flex-direction: column; gap: 2px; }
.ax-side a, .ax-side button { display: flex; align-items: center; gap: 12px; height: 44px; padding: 0 14px; border: 0; border-radius: 8px; background: transparent;
  color: var(--sx-text); font: 500 15px var(--sx-ui); text-align: left; cursor: pointer; }
.ax .ax-side a { color: var(--sx-text); }
.ax-side a:hover, .ax-side button:hover { background: var(--ax-hover); text-decoration: none; }
.ax-side a.on { background: var(--ax-on); }
.ax-side svg { width: 20px; height: 20px; flex: none; stroke: currentColor; fill: none; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; opacity: .85; }
.ax-side hr { border: 0; border-top: 1px solid var(--sx-line); margin: 10px 0; width: 100%; }
.ax-side .ax-out { color: var(--sx-red); }
.ax-panel { min-width: 0; }
.ax-sec { background: var(--ax-panel); border: 1px solid var(--sx-line); border-radius: 16px; padding: 28px 32px; margin: 0 0 16px; }
.ax-sec[hidden] { display: none; }
.ax-sec h2 { font: 600 24px/1.25 var(--sx-display); letter-spacing: -.02em; margin: 0 0 6px; }
.ax-sec > .lede { color: var(--sx-body); margin: 0 0 18px; }
.ax-sec form, .ax-sec .ax-narrow { max-width: 460px; }
.ax-sec .go { width: auto; padding: 0 24px; }
.ax-sec .go.ghost { display: inline-flex; margin-right: 8px; }
.ax-sec ol.hint { padding-left: 20px; margin: 12px 0 4px; }
.ax-sec ol.hint li { margin: 3px 0; }
.ax-sec .kv b { color: var(--sx-text); }
.ax-modes { display: flex; flex-wrap: wrap; gap: 10px; }
.ax-modes label { display: flex; align-items: center; margin: 0; padding: 12px 16px; border: 1px solid var(--ax-field-line); border-radius: 8px; cursor: pointer; font-weight: 400; }
.ax-modes label:has(input:checked) { border-color: var(--sx-accent); background: rgba(41,98,255,.08); }
.ax-note { color: var(--sx-dim); font-size: 13px; margin: 8px 0 0; }

@media (max-width: 960px) {
  .ax-split { grid-template-columns: 1fr; padding: 0; min-height: 0; }
  .ax-art { display: none; }
  .ax-main { padding: 40px 16px 56px; }
  .ax-set { padding: 28px 16px 64px; }
  .ax-set > h1, .ax-wide .ax-card .ax-set > h1 { font-size: 30px; margin-bottom: 20px; }
  .ax-cols { grid-template-columns: 1fr; gap: 20px; }
  .ax-side { position: static; flex-direction: row; flex-wrap: wrap; gap: 6px; }
  .ax-side a, .ax-side button { height: 36px; padding: 0 14px; border: 1px solid var(--sx-line2); border-radius: 40px; font-size: 14px; }
  .ax-side svg, .ax-side hr { display: none; }
  .ax-sec { padding: 22px 18px; }
  .ax-sec .go { width: 100%; }
  .ax-sec .go.ghost { display: flex; margin-right: 0; }
  .ax .kv { flex-wrap: wrap; }
  .ax .kv > span:last-child { text-align: left; }
}
@media (max-width: 400px) { .ax-card h1 { font-size: 28px; } }
.ax-wide .sub { text-align: left; }
.ax-intro { margin: 0 0 16px; }
/* the shared top bar is 18px too wide at 390 (brand + two buttons); tighten it on these pages only */
@media (max-width: 440px) { .ax .sx-top { gap: 8px; } .ax .sx-act { gap: 6px; } .ax .sx-top .sx-btn { padding: 0 12px; font-size: 14px; height: 36px; } .ax .sx-brand { font-size: 17px; } .ax .sx-brand svg { width: 26px; height: 26px; } }

/* 'Continue with Google' (auth.js social()): Google's sign-in button look, white with the four-colour G in both themes */
.ax .gbtn { display: flex; align-items: center; justify-content: center; gap: 12px; width: 100%; height: 48px; margin-top: 4px; border-radius: 8px;
  background: #fff; color: #1f1f1f; border: 1px solid #747775; font: 500 15px/1 var(--sx-font, inherit); }
.ax .gbtn svg { width: 20px; height: 20px; flex: none; }
.ax a.gbtn:hover { text-decoration: none; background: #f2f2f2; }
.ax .gbtn:focus-visible { outline: 2px solid var(--sx-accent); outline-offset: 2px; }
.ax .or { display: flex; align-items: center; gap: 12px; margin: 20px 0 4px; color: var(--sx-dim); font-size: 13px; }
.ax .or::before, .ax .or::after { content: ''; flex: 1; height: 1px; background: var(--sx-line); }
.ax .steps { margin: 0 0 12px; padding-left: 20px; color: var(--sx-body); }
.ax .steps li { margin: 6px 0; }
