/* =========================================================
   Trade Xorax — Auth pages (dark)
   Matches the landing page palette: navy + sky + blush
   ========================================================= */

:root {
  --a-bg: #060d18;
  --a-panel: #0a1626;
  --a-panel-2: #0f2036;
  --a-field: #0b1a2d;
  --a-field-focus: #0e2138;
  --a-line: rgba(255, 255, 255, 0.08);
  --a-line-2: rgba(255, 255, 255, 0.14);
  --a-text: #eaf2fb;
  --a-muted: #93a4ba;
  --a-dim: #64768e;

  --sky-300: #7dd3fc;
  --sky-400: #38bdf8;
  --sky-500: #0ea5e9;
  --sky-ink: #05263d;
  --blush: #ffc6d5;
  --blush-500: #f07c9c;

  --ok: #34d399;
  --err: #fb7185;
  --warn: #fbbf24;

  --font: "Inter", system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  --display: "Space Grotesk", "Inter", sans-serif;
  --mono: "JetBrains Mono", ui-monospace, monospace;
  --ease: cubic-bezier(.2, .7, .2, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html, body { height: 100%; }
body.nxa {
  margin: 0; background: var(--a-bg); color: var(--a-text);
  font: 400 15.5px/1.6 var(--font); -webkit-font-smoothing: antialiased;
}
.nxa img { max-width: 100%; display: block; }
.nxa a { color: inherit; }
.hide { display: none !important; }

/* ---------- Shell ---------- */
.nxa-shell { display: grid; grid-template-columns: minmax(380px, 46%) 1fr; min-height: 100vh; }

/* ---------- Brand panel ---------- */
.nxa-side {
  position: sticky; top: 0; height: 100vh; overflow: hidden; isolation: isolate;
  display: flex; flex-direction: column; justify-content: space-between;
  padding: 40px 56px;
  background: linear-gradient(160deg, #0b1a2e 0%, #081321 55%, #060d18 100%);
  border-right: 1px solid var(--a-line);
}
.nxa-side__net { position: absolute; inset: 0; width: 100%; height: 100%; z-index: -2; opacity: .7; }
.nxa-side__glow { position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(520px 380px at 90% 5%, rgba(56,189,248,.22), transparent 70%),
    radial-gradient(420px 320px at 0% 95%, rgba(240,124,156,.16), transparent 70%); }

.nxa-brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; }
.nxa-brand img { width: 36px; height: 36px; border-radius: 9px; object-fit: cover; }
.nxa-brand span { font: 700 19px/1 var(--display); letter-spacing: -.02em; color: #fff; }
.nxa-brand b { color: var(--sky-300); font-weight: 700; margin-left: 1px; }
.nxa-brand--mobile { display: none; }

.nxa-side__copy { max-width: 460px; }
.nxa-eyebrow { display: inline-flex; align-items: center; gap: 10px; padding: 7px 14px 7px 12px; border-radius: 999px;
  border: 1px solid var(--a-line-2); background: rgba(255,255,255,.03); font: 500 12.5px var(--mono); color: var(--a-muted); }
.nxa-eyebrow i { width: 7px; height: 7px; border-radius: 50%; background: var(--sky-400);
  box-shadow: 0 0 0 4px rgba(56,189,248,.2); animation: nxa-pulse 2s infinite; }
@keyframes nxa-pulse { 50% { box-shadow: 0 0 0 8px rgba(56,189,248,0); } }

.nxa-side h2 { font: 700 clamp(30px, 3.2vw, 44px)/1.08 var(--display); letter-spacing: -.03em; margin: 22px 0 16px; color: #fff; }
.nxa-side h2 em { font-style: normal; color: transparent;
  background: linear-gradient(100deg, var(--sky-300), var(--blush)); -webkit-background-clip: text; background-clip: text; }
.nxa-side__copy > p { color: var(--a-muted); margin: 0 0 32px; }

.nxa-points { list-style: none; padding: 0; margin: 0; display: grid; gap: 14px; }
.nxa-points li { display: flex; gap: 14px; align-items: flex-start; padding: 14px 16px; border-radius: 14px;
  background: rgba(255,255,255,.025); border: 1px solid var(--a-line); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }
.nxa-points li > span { flex: none; width: 34px; height: 34px; border-radius: 10px; display: grid; place-items: center;
  background: rgba(56,189,248,.12); color: var(--sky-300); }
.nxa-points li:nth-child(2) > span { background: rgba(240,124,156,.14); color: var(--blush); }
.nxa-points b { display: block; font: 600 15px var(--display); color: #fff; }
.nxa-points small { color: var(--a-muted); font-size: 13.5px; }

.nxa-side__foot { display: flex; gap: 18px; font-size: 13px; color: var(--a-dim); }
.nxa-side__foot a { text-decoration: none; }
.nxa-side__foot a:hover { color: var(--sky-300); }

/* ---------- Form panel ---------- */
.nxa-main { position: relative; display: flex; flex-direction: column; min-height: 100vh; padding: 28px 40px;
  background: radial-gradient(700px 400px at 100% 0%, rgba(56,189,248,.07), transparent 70%), var(--a-bg); }
.nxa-top { display: flex; align-items: center; justify-content: flex-end; gap: 16px; }
.nxa-back { display: inline-flex; align-items: center; gap: 8px; padding: 8px 14px; border-radius: 999px; text-decoration: none;
  border: 1px solid var(--a-line-2); font-size: 13.5px; color: var(--a-muted); transition: color .2s, border-color .2s; }
.nxa-back:hover { color: #fff; border-color: rgba(125,211,252,.45); }

.nxa-content { flex: 1; display: flex; align-items: center; justify-content: center; padding: 32px 0; }
.nxa-bottom { display: none; justify-content: space-between; gap: 12px; font-size: 13px; color: var(--a-dim); }
.nxa-bottom__links { display: flex; gap: 16px; }
.nxa-bottom a { text-decoration: none; }

/* ---------- Card ---------- */
.nxa-card { width: 100%; max-width: 440px; animation: nxa-rise .55s var(--ease) both; }
.nxa-card--wide { max-width: 560px; }
@keyframes nxa-rise { from { opacity: 0; transform: translateY(14px); } }

.nxa-card__head { margin-bottom: 30px; }
.nxa-card__icon { width: 52px; height: 52px; border-radius: 14px; display: grid; place-items: center; margin-bottom: 22px;
  color: var(--sky-ink); background: linear-gradient(135deg, var(--sky-300), var(--sky-400));
  box-shadow: 0 12px 30px -12px rgba(14,165,233,.7); }
.nxa-card__head h1 { font: 700 clamp(26px, 3vw, 32px)/1.15 var(--display); letter-spacing: -.025em; margin: 0 0 8px; color: #fff; }
.nxa-card__head p { margin: 0; color: var(--a-muted); }
.nxa-card__foot { margin: 28px 0 0; padding-top: 22px; border-top: 1px solid var(--a-line); text-align: center; color: var(--a-muted); font-size: 14.5px; }

/* ---------- Form ---------- */
.nxa-form { display: grid; gap: 18px; }
.nxa-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.nxa-field { display: grid; gap: 8px; }
.nxa-field label, .nxa label.requiredField { font: 500 13.5px var(--font); color: #c9d6e6; }
.nxa-field__row { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }

.nxa-input { position: relative; display: flex; align-items: center; }
.nxa-input__icon { position: absolute; left: 14px; color: var(--a-dim); pointer-events: none; transition: color .2s; }
.nxa-input input, .nxa-input select,
.nxa .form-control, .nxa .dark-input {
  width: 100%; height: 50px; padding: 0 16px; border-radius: 12px;
  background: var(--a-field); border: 1px solid var(--a-line-2); color: var(--a-text);
  font: 400 15px var(--font); outline: none; -webkit-appearance: none; appearance: none;
  transition: border-color .2s, background .2s, box-shadow .2s;
}
.nxa-input .nxa-input__icon ~ input, .nxa-input .nxa-input__icon ~ select { padding-left: 42px; }
.nxa-input input::placeholder, .nxa .form-control::placeholder { color: var(--a-dim); }
.nxa-input input:hover, .nxa-input select:hover { border-color: rgba(255,255,255,.22); }
.nxa-input input:focus, .nxa-input select:focus, .nxa .form-control:focus {
  border-color: var(--sky-400); background: var(--a-field-focus); box-shadow: 0 0 0 4px rgba(56,189,248,.15);
}
.nxa-input:focus-within .nxa-input__icon { color: var(--sky-300); }
.nxa-input input[readonly] { color: var(--a-muted); cursor: not-allowed; }
.nxa-input input:-webkit-autofill { -webkit-box-shadow: 0 0 0 40px var(--a-field) inset; -webkit-text-fill-color: var(--a-text); caret-color: var(--a-text); }

/* select chevron */
.nxa-input--select::after { content: ""; position: absolute; right: 16px; width: 10px; height: 10px; pointer-events: none;
  border-right: 2px solid var(--a-muted); border-bottom: 2px solid var(--a-muted); transform: translateY(-3px) rotate(45deg); }
.nxa .nxa-input--select select { padding-right: 42px; cursor: pointer; }
.nxa-input select option { background: var(--a-panel); color: var(--a-text); }

/* password eye */
.nxa-input .nxa-eye ~ input, .nxa-input input:has(+ .nxa-eye) { padding-right: 46px; }
.nxa-eye { position: absolute; right: 6px; width: 38px; height: 38px; border-radius: 9px; border: 0; background: transparent;
  color: var(--a-dim); display: grid; place-items: center; cursor: pointer; transition: color .2s, background .2s; }
.nxa-eye:hover { color: var(--sky-300); background: rgba(255,255,255,.04); }
.nxa-eye__off { display: none; }
.nxa-eye.is-on .nxa-eye__on { display: none; }
.nxa-eye.is-on .nxa-eye__off { display: block; }

.nxa-hint { margin: -6px 0 0; min-height: 0; font-size: 13px; color: var(--a-muted); }
.nxa-hint.is-ok { color: var(--ok); }
.nxa-hint.is-bad { color: var(--err); }

/* referral toggle */
.nxa-ref-toggle { justify-self: start; display: inline-flex; align-items: center; gap: 8px; padding: 0; border: 0; background: none;
  color: var(--a-muted); font: 400 14px var(--font); cursor: pointer; }
.nxa-ref-toggle span { color: var(--sky-300); text-decoration: underline; text-underline-offset: 3px; }
.nxa-ref-toggle svg { color: var(--blush); }

/* checkbox */
.nxa-check { position: relative; display: flex; gap: 12px; align-items: flex-start; font-size: 14px; color: var(--a-muted); cursor: pointer; line-height: 1.55; }
.nxa-check input { position: absolute; opacity: 0; width: 1px; height: 1px; }
.nxa-check__box { flex: none; width: 20px; height: 20px; margin-top: 1px; border-radius: 6px; border: 1px solid var(--a-line-2);
  background: var(--a-field); transition: all .2s; }
.nxa-check input:checked + .nxa-check__box {
  border-color: var(--sky-400);
  background: var(--sky-400) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2305263d' stroke-width='3.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12l5 5L20 7'/%3E%3C/svg%3E") center / 13px no-repeat; }
.nxa-check input:focus-visible + .nxa-check__box { box-shadow: 0 0 0 4px rgba(56,189,248,.2); }

/* ---------- Buttons & links ---------- */
.nxa-btn, .nxa .Btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 52px; padding: 0 24px; border-radius: 999px; border: 0; cursor: pointer; text-decoration: none;
  font: 600 15.5px var(--font); white-space: nowrap;
  transition: transform .2s var(--ease), box-shadow .25s, background .25s, color .2s;
}
.nxa-btn--primary, .nxa .Btn {
  background: linear-gradient(135deg, var(--sky-300) 0%, var(--sky-400) 55%, #4fb4f5 100%) !important;
  color: var(--sky-ink);
  box-shadow: 0 10px 26px -10px rgba(14,165,233,.75), inset 0 1px 0 rgba(255,255,255,.45);
}
.nxa-btn--primary:hover, .nxa .Btn:hover {
  transform: translateY(-1px); color: #fff;
  background: linear-gradient(135deg, var(--sky-400), var(--sky-500)) !important;
  box-shadow: 0 16px 34px -12px rgba(14,165,233,.85);
}
.nxa-btn--primary:disabled { opacity: .7; cursor: progress; transform: none; }
.nxa-btn--block, .nxa .Btn { width: 100%; margin-top: 6px; }

.nxa-link, .nxa .site-yellow { color: var(--sky-300); text-decoration: none; font-weight: 600; }
.nxa-link:hover, .nxa .site-yellow:hover { text-decoration: underline; text-underline-offset: 3px; }
.nxa-link--sm { font-size: 13px; font-weight: 500; }

/* ---------- Alerts & toasts ---------- */
.nxa-alert, .nxa .errorlist, .nxa .alert {
  list-style: none; margin: 0; padding: 12px 14px; border-radius: 12px; font-size: 14px;
  background: rgba(251,113,133,.1); border: 1px solid rgba(251,113,133,.3); color: #fecdd3; }
.nxa .invalid-feedback, .nxa .help-block, .nxa .form-text { display: block; margin-top: 6px; font-size: 13px; color: var(--err); }
.nxa .is-invalid { border-color: var(--err) !important; }

.nxa-toasts { position: fixed; top: 20px; right: 20px; z-index: 200; display: grid; gap: 10px; width: min(380px, calc(100vw - 32px)); }
.nxa-toast { display: flex; align-items: flex-start; gap: 12px; padding: 14px 14px 14px 16px; border-radius: 14px;
  background: rgba(15,32,54,.95); border: 1px solid var(--a-line-2); color: var(--a-text); font-size: 14px;
  box-shadow: 0 20px 40px -18px rgba(0,0,0,.8); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  border-left: 3px solid var(--sky-400); animation: nxa-toast .4s var(--ease) both; }
.nxa-toast span { flex: 1; }
.nxa-toast--success { border-left-color: var(--ok); }
.nxa-toast--error, .nxa-toast--danger { border-left-color: var(--err); }
.nxa-toast--warning { border-left-color: var(--warn); }
.nxa-toast__x { border: 0; background: none; color: var(--a-muted); font-size: 20px; line-height: 1; cursor: pointer; padding: 0 2px; }
.nxa-toast__x:hover { color: #fff; }
.nxa-toast.is-out { opacity: 0; transform: translateX(16px); transition: all .3s; }
@keyframes nxa-toast { from { opacity: 0; transform: translateY(-10px); } }

/* ---------- Loader overlay (login) ---------- */
.nxa-loader { position: fixed; inset: 0; z-index: 300; background: rgba(4,10,20,.82);
  backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }
.nxa-loader__box { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
  display: flex; flex-direction: column; align-items: center; gap: 16px; text-align: center; color: var(--a-muted); }
.nxa-loader__box small { font: 500 13px var(--mono); letter-spacing: .04em; }
.nxa-loader__msg { padding: 22px 28px; border-radius: 16px; background: var(--a-panel-2); border: 1px solid var(--a-line-2); color: var(--a-text); max-width: min(420px, 90vw); }
.nxa-spinner { width: 54px; height: 54px; border-radius: 50%; position: relative; }
.nxa-spinner::before, .nxa-spinner::after { content: ""; position: absolute; inset: 0; border-radius: 50%; border: 3px solid transparent; }
.nxa-spinner::before { border-top-color: var(--sky-400); border-bottom-color: var(--sky-400); animation: nxa-spin 1s linear infinite; }
.nxa-spinner::after { inset: 9px; border-left-color: var(--blush-500); border-right-color: var(--blush-500); animation: nxa-spin .8s linear infinite reverse; }
@keyframes nxa-spin { to { transform: rotate(360deg); } }

/* ---------- Status screens (reset sent / done / expired) ---------- */
.nxa-card--center { text-align: center; }
.nxa-card--center .nxa-card__icon { margin-left: auto; margin-right: auto; }
.nxa-state { position: relative; width: 84px; height: 84px; margin: 0 auto 26px; border-radius: 50%; display: grid; place-items: center; }
.nxa-state::before { content: ""; position: absolute; inset: -10px; border-radius: 50%; border: 1px dashed rgba(125,211,252,.25); animation: nxa-spin 18s linear infinite; }
.nxa-state--ok { background: rgba(52,211,153,.1); border: 1px solid rgba(52,211,153,.3); color: var(--ok); }
.nxa-state--mail { background: rgba(56,189,248,.1); border: 1px solid rgba(56,189,248,.3); color: var(--sky-300); }
.nxa-state--warn { background: rgba(251,113,133,.1); border: 1px solid rgba(251,113,133,.3); color: var(--err); }
.nxa-state--ok::before { border-color: rgba(52,211,153,.25); }
.nxa-state--warn::before { border-color: rgba(251,113,133,.25); }
.nxa-check-anim { width: 40px; height: 40px; }
.nxa-check-anim circle { stroke: currentColor; stroke-width: 2; stroke-dasharray: 166; stroke-dashoffset: 166; animation: nxa-draw .7s var(--ease) forwards; }
.nxa-check-anim path { stroke: currentColor; stroke-width: 3.5; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 48; stroke-dashoffset: 48; animation: nxa-draw .4s .55s var(--ease) forwards; }
@keyframes nxa-draw { to { stroke-dashoffset: 0; } }

.nxa-btn--ghost { background: transparent; color: var(--a-text); border: 1px solid var(--a-line-2); }
.nxa-btn--ghost:hover { border-color: rgba(125,211,252,.45); color: #fff; background: rgba(255,255,255,.03); }
.nxa-btn--sm { height: 44px; padding: 0 18px; font-size: 14px; }
.nxa-btnrow { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }

.nxa-note { margin: 22px 0 0; padding: 14px 16px; border-radius: 12px; background: rgba(255,255,255,.025); border: 1px solid var(--a-line);
  font-size: 13.5px; color: var(--a-muted); text-align: left; }
.nxa-note b { color: var(--a-text); font-weight: 600; }

.nxa-rules { list-style: none; margin: -4px 0 0; padding: 0; display: grid; gap: 6px; font-size: 13px; color: var(--a-muted); }
.nxa-rules li { display: flex; gap: 8px; align-items: center; }
.nxa-rules li::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--a-dim); transition: background .2s; }
.nxa-rules li.is-met { color: var(--ok); }
.nxa-rules li.is-met::before { background: var(--ok); }

.nxa-field .nxa-err { margin: 0; font-size: 13px; color: var(--err); }
.nxa-field.has-error input { border-color: var(--err); }

/* =========================================================
   Legacy compatibility — keeps older auth templates
   (password reset, verification, etc.) looking right
   ========================================================= */
.nxa .post-form { width: 100%; max-width: 480px; margin: 0 auto; padding: 36px; border-radius: 20px;
  background: var(--a-panel); border: 1px solid var(--a-line); box-shadow: 0 30px 60px -30px rgba(0,0,0,.8); }
.nxa .post-form h1, .nxa .post-form h2, .nxa .post-form h3, .nxa .post-form h4, .nxa .post-form h5 { font-family: var(--display); color: #fff; letter-spacing: -.01em; }
.nxa .form-group { margin-bottom: 18px; }
.nxa .form-group label { display: block; margin-bottom: 8px; font-size: 13.5px; color: #c9d6e6; }
.nxa .greyWhite { color: var(--a-text); }
.nxa .textColor, .nxa .textColor2 { color: var(--a-muted); }
.nxa .boldText { font-weight: 600; }
.nxa .align-center { text-align: center; }
.nxa .align-right { text-align: right; }
.nxa .mx-auto { margin-left: auto; margin-right: auto; }
.nxa .mt-2 { margin-top: 8px; } .nxa .mt-3 { margin-top: 16px; } .nxa .mt-4 { margin-top: 24px; } .nxa .mt-5 { margin-top: 40px; }
.nxa .mt-30 { margin-top: 30px; } .nxa .mt-50 { margin-top: 50px; } .nxa .mb-4 { margin-bottom: 24px; }
.nxa .row { display: flex; flex-wrap: wrap; margin: 0 -8px; }
.nxa .row > [class*="col"] { padding: 0 8px; flex: 0 0 100%; max-width: 100%; }
.nxa .row > .col-6 { flex-basis: 50%; max-width: 50%; }
@media (min-width: 768px) { .nxa .row > .col-md-6 { flex-basis: 50%; max-width: 50%; } }
.nxa .floating-icon-div { width: 52px; height: 52px; border-radius: 14px; display: grid; place-items: center;
  background: linear-gradient(135deg, var(--sky-300), var(--sky-400)); }
.nxa .floating-icon-div img { filter: brightness(0) saturate(100%) invert(10%); }
.nxa center { display: block; text-align: center; }
.nxa .floating-icon-div { margin: 0 auto; }

/* ---------- Responsive ---------- */
@media (max-width: 980px) {
  .nxa-shell { grid-template-columns: 1fr; }
  .nxa-side { display: none; }
  .nxa-main { padding: 20px 20px 24px;
    background:
      radial-gradient(500px 300px at 100% 0%, rgba(56,189,248,.14), transparent 70%),
      radial-gradient(400px 260px at 0% 100%, rgba(240,124,156,.1), transparent 70%), var(--a-bg); }
  .nxa-top { justify-content: space-between; }
  .nxa-brand--mobile { display: inline-flex; }
  .nxa-bottom { display: flex; }
  .nxa-content { padding: 36px 0 28px; align-items: flex-start; }
}

@media (max-width: 520px) {
  .nxa-back { padding: 8px 10px; font-size: 0; gap: 0; }
  .nxa-back svg { width: 16px; height: 16px; }
  .nxa-grid { grid-template-columns: 1fr; }
  .nxa .post-form { padding: 24px 20px; }
  .nxa-bottom { flex-direction: column; align-items: center; }
}

@media (prefers-reduced-motion: reduce) {
  .nxa *, .nxa *::before, .nxa *::after { animation: none !important; transition: none !important; }
}