/* Nexa Capital — public auth theme (vision/*). Palette mirrors dashboard-vela.css */
:root {
    --nx-acc: #d4af37;
    --nx-acc-2: #f2d27a;
    --nx-acc-3: #b8892b;
    --nx-acc-soft: rgba(212, 175, 55, 0.12);
    --nx-acc-line: rgba(212, 175, 55, 0.24);
    --nx-bg-0: #0a0a0a;
    --nx-bg-1: #0f0f0f;
    --nx-bg-2: #161616;
    --nx-bg-3: #1f1f1f;
    --nx-t0: #f5f2ea;
    --nx-t1: #a8a196;
    --nx-t2: #6e685d;
    --nx-line: rgba(255, 255, 255, 0.07);
    --nx-line-2: rgba(255, 255, 255, 0.13);
    --nx-ok: #33d493;
    --nx-bad: #f76d7d;
    --nx-radius: 22px;
    --nx-nav-h: 84px;
}

*, *::before, *::after { box-sizing: border-box; }

.trading-auth-theme {
    margin: 0;
    min-height: 100vh;
    background: var(--nx-bg-0);
    color: var(--nx-t0);
    font-family: "Plus Jakarta Sans", system-ui, -apple-system, sans-serif;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

/* ---------- Ambient background ---------- */
.nx-bg {
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
    overflow: hidden;
}
.nx-bg__grid {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(212, 175, 55, 0.045) 1px, transparent 1px),
        linear-gradient(90deg, rgba(212, 175, 55, 0.045) 1px, transparent 1px);
    background-size: 56px 56px;
    mask-image: radial-gradient(ellipse 70% 60% at 30% 40%, black 10%, transparent 75%);
    -webkit-mask-image: radial-gradient(ellipse 70% 60% at 30% 40%, black 10%, transparent 75%);
}
.nx-bg__glow {
    position: absolute;
    border-radius: 50%;
    filter: blur(120px);
}
.nx-bg__glow--a {
    width: 620px;
    height: 620px;
    top: -220px;
    left: -160px;
    background: rgba(212, 175, 55, 0.22);
}
.nx-bg__glow--b {
    width: 520px;
    height: 520px;
    bottom: -240px;
    right: -120px;
    background: rgba(242, 210, 122, 0.10);
}
.nx-bg__ring {
    position: absolute;
    top: 50%;
    left: 24%;
    width: 760px;
    height: 760px;
    border-radius: 50%;
    border: 1px solid rgba(212, 175, 55, 0.07);
    transform: translate(-50%, -50%);
}
.nx-bg__ring::after {
    content: "";
    position: absolute;
    inset: 110px;
    border-radius: 50%;
    border: 1px dashed rgba(212, 175, 55, 0.08);
    animation: nxSpin 90s linear infinite;
}

/* ---------- Navbar ---------- */
.nx-nav {
    position: sticky;
    top: 0;
    z-index: 100;
    padding: 14px 32px 0;
}
.nx-nav__bar {
    max-width: 1280px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 10px 12px 10px 20px;
    background: rgba(15, 15, 15, 0.72);
    border: 1px solid var(--nx-line);
    border-radius: 18px;
    backdrop-filter: blur(16px) saturate(140%);
    -webkit-backdrop-filter: blur(16px) saturate(140%);
    box-shadow: 0 18px 40px -24px rgba(0, 0, 0, 0.9);
}
.nx-nav__brand {
    display: flex;
    align-items: center;
    line-height: 0;
    text-decoration: none;
}
.nx-nav__logo {
    height: auto;
    width: auto;
    max-height: 48px;
    max-width: 120px;
    object-fit: contain;
    display: block;
}
.nx-nav__menu {
    display: flex;
    align-items: center;
    gap: 6px;
}
.nx-nav__link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 9px 16px;
    border-radius: 12px;
    color: var(--nx-t1);
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    border: 1px solid transparent;
    transition: color 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}
.nx-nav__link:hover {
    color: var(--nx-t0);
    background: rgba(255, 255, 255, 0.04);
}
.nx-nav__link.active {
    color: var(--nx-acc-2);
    background: var(--nx-acc-soft);
    border-color: var(--nx-acc-line);
}
.nx-nav__link--cta {
    color: var(--nx-bg-0);
    background: linear-gradient(135deg, var(--nx-acc-2) 0%, var(--nx-acc) 100%);
    box-shadow: 0 8px 22px -10px rgba(212, 175, 55, 0.8);
}
.nx-nav__link--cta:hover,
.nx-nav__link--cta.active {
    color: var(--nx-bg-0);
    background: linear-gradient(135deg, #f7dd92 0%, var(--nx-acc-2) 100%);
    border-color: transparent;
}
.nx-nav__link svg { flex-shrink: 0; }

/* ---------- Shell ---------- */
.nx-shell {
    position: relative;
    z-index: 1;
    max-width: 1280px;
    min-height: calc(100vh - var(--nx-nav-h));
    margin: 0 auto;
    padding: 40px 32px 32px;
    display: grid;
    grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr);
    gap: 56px;
    align-items: center;
}
.nx-shell--single {
    grid-template-columns: minmax(0, 1fr);
    justify-items: center;
}
.nx-stage {
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    min-width: 0;
}
.nx-copy {
    margin: 22px 0 0;
    color: var(--nx-t2);
    font-size: 12px;
    text-align: center;
}

/* ---------- Hero / brand panel ---------- */
.nx-hero {
    display: flex;
    flex-direction: column;
    gap: 28px;
    max-width: 560px;
}
.nx-eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    width: fit-content;
    padding: 6px 14px 6px 6px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--nx-line);
    color: var(--nx-t1);
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.3px;
}
.nx-eyebrow__tag {
    padding: 3px 10px;
    border-radius: 999px;
    background: var(--nx-acc);
    color: var(--nx-bg-0);
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 0.6px;
    text-transform: uppercase;
}
.nx-hero__title {
    margin: 0;
    color: var(--nx-t0);
    font-size: clamp(36px, 4.2vw, 56px);
    font-weight: 800;
    line-height: 1.05;
    letter-spacing: -0.035em;
}
.nx-hero__title span {
    background: linear-gradient(120deg, var(--nx-acc-2) 0%, var(--nx-acc) 55%, var(--nx-acc-3) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}
.nx-hero__text {
    margin: 0;
    max-width: 470px;
    color: var(--nx-t1);
    font-size: 16px;
    line-height: 1.65;
}
.nx-features {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
    margin: 0;
    padding: 0;
    list-style: none;
}
.nx-feature {
    padding: 16px;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.025);
    border: 1px solid var(--nx-line);
}
.nx-feature__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    margin-bottom: 12px;
    border-radius: 11px;
    color: var(--nx-acc-2);
    background: var(--nx-acc-soft);
    border: 1px solid var(--nx-acc-line);
}
.nx-feature strong {
    display: block;
    color: var(--nx-t0);
    font-size: 14px;
    font-weight: 700;
    margin-bottom: 4px;
}
.nx-feature span {
    display: block;
    color: var(--nx-t2);
    font-size: 12px;
    line-height: 1.5;
}

/* Market ticker */
.nx-ticker {
    border-radius: 20px;
    background: linear-gradient(180deg, rgba(31, 31, 31, 0.7) 0%, rgba(15, 15, 15, 0.85) 100%);
    border: 1px solid var(--nx-line);
    overflow: hidden;
    box-shadow: 0 30px 60px -36px rgba(0, 0, 0, 0.9);
}
.nx-ticker__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 18px;
    border-bottom: 1px solid var(--nx-line);
    color: var(--nx-t1);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}
.nx-ticker__live {
    display: inline-flex;
    align-items: center;
    gap: 8px;
}
.nx-ticker__clock {
    color: var(--nx-acc);
    font-variant-numeric: tabular-nums;
    letter-spacing: 0.4px;
}
.nx-ticker__rows {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
}
.nx-pair {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 18px;
    border-bottom: 1px solid var(--nx-line);
    transition: background 0.35s ease;
}
.nx-pair:nth-child(odd) { border-right: 1px solid var(--nx-line); }
.nx-pair:nth-last-child(-n+2) { border-bottom: none; }
.nx-pair.flash-up { background: rgba(51, 212, 147, 0.07); }
.nx-pair.flash-down { background: rgba(247, 109, 125, 0.07); }
.nx-pair__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    flex-shrink: 0;
    border-radius: 10px;
    background: var(--nx-acc-soft);
    border: 1px solid var(--nx-acc-line);
    color: var(--nx-acc-2);
    font-size: 11px;
    font-weight: 800;
}
.nx-pair__meta {
    flex: 1;
    min-width: 0;
}
.nx-pair__meta strong {
    display: block;
    color: var(--nx-t0);
    font-size: 13px;
    font-weight: 700;
}
.nx-pair__meta small {
    color: var(--nx-t2);
    font-size: 11px;
}
.nx-pair__price {
    text-align: right;
    color: var(--nx-t0);
    font-size: 14px;
    font-weight: 700;
    font-variant-numeric: tabular-nums;
}
.nx-pair__change {
    display: block;
    font-size: 11px;
    font-weight: 700;
}
.nx-pair__change.up { color: var(--nx-ok); }
.nx-pair__change.down { color: var(--nx-bad); }

.nx-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: var(--nx-ok);
    box-shadow: 0 0 10px rgba(51, 212, 147, 0.85);
    animation: nxPulse 1.4s ease-in-out infinite;
}

/* ---------- Auth card ---------- */
.auth-card {
    position: relative;
    width: 100%;
    max-width: 460px;
    padding: 40px;
    border-radius: var(--nx-radius);
    background: linear-gradient(180deg, rgba(31, 31, 31, 0.82) 0%, rgba(15, 15, 15, 0.94) 100%);
    border: 1px solid var(--nx-line);
    box-shadow:
        0 40px 80px -40px rgba(0, 0, 0, 0.95),
        inset 0 1px 0 rgba(255, 255, 255, 0.04);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
}
.auth-card::before {
    content: "";
    position: absolute;
    top: -1px;
    left: 12%;
    right: 12%;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--nx-acc), transparent);
}
.auth-card--wide { max-width: 560px; }

.nx-card-head {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 28px;
}
.nx-card-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    flex-shrink: 0;
    border-radius: 14px;
    color: var(--nx-bg-0);
    background: linear-gradient(135deg, var(--nx-acc-2) 0%, var(--nx-acc) 100%);
    box-shadow: 0 10px 24px -10px rgba(212, 175, 55, 0.85);
}
.auth-title {
    margin: 0;
    color: var(--nx-t0);
    font-size: 26px;
    font-weight: 800;
    letter-spacing: -0.025em;
    line-height: 1.2;
}
.auth-subtitle {
    margin: 4px 0 0;
    color: var(--nx-t1);
    font-size: 14px;
    line-height: 1.55;
}
.nx-card-intro {
    margin: -12px 0 24px;
    color: var(--nx-t1);
    font-size: 14px;
    line-height: 1.6;
}

/* Form */
.auth-form .form-group { margin-bottom: 18px; }
.auth-form label {
    display: block;
    margin-bottom: 8px;
    color: var(--nx-t1);
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 0.4px;
    text-transform: uppercase;
}
.nx-grid-2 {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 14px;
}
.nx-field {
    position: relative;
    display: flex;
    align-items: center;
}
.nx-field__icon {
    position: absolute;
    left: 15px;
    width: 18px;
    height: 18px;
    color: var(--nx-t2);
    pointer-events: none;
    transition: color 0.2s ease;
}
.nx-field:focus-within .nx-field__icon { color: var(--nx-acc); }
.auth-form .form-input,
.auth-form .form-control {
    width: 100%;
    height: 52px;
    margin: 0;
    padding: 0 16px 0 46px;
    border: 1px solid var(--nx-line-2);
    border-radius: 14px;
    background: rgba(10, 10, 10, 0.6);
    color: var(--nx-t0);
    font-family: inherit;
    font-size: 15px;
    font-weight: 500;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}
.auth-form .nx-field--toggle .form-input,
.auth-form .nx-field--toggle .form-control { padding-right: 50px; }
.auth-form .form-input::placeholder,
.auth-form .form-control::placeholder { color: var(--nx-t2); }
.auth-form .form-input:hover,
.auth-form .form-control:hover { border-color: rgba(212, 175, 55, 0.28); }
.auth-form .form-input:focus,
.auth-form .form-control:focus {
    outline: none;
    color: var(--nx-t0);
    background: rgba(10, 10, 10, 0.85);
    border-color: var(--nx-acc);
    box-shadow: 0 0 0 4px rgba(212, 175, 55, 0.14);
}
.auth-form select.form-control {
    appearance: none;
    -webkit-appearance: none;
    padding-right: 44px;
    cursor: pointer;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12' fill='none'%3E%3Cpath d='M2.5 4.5L6 8l3.5-3.5' stroke='%23d4af37' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 16px center;
}
.auth-form select.form-control option {
    background: var(--nx-bg-2);
    color: var(--nx-t0);
}
.nx-field__toggle {
    position: absolute;
    right: 8px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    padding: 0;
    border: 0;
    border-radius: 10px;
    background: transparent;
    color: var(--nx-t2);
    cursor: pointer;
    transition: color 0.2s ease, background 0.2s ease;
}
.nx-field__toggle:hover {
    color: var(--nx-acc-2);
    background: var(--nx-acc-soft);
}
.nx-field__toggle .nx-eye-off { display: none; }
.nx-field__toggle.is-visible .nx-eye { display: none; }
.nx-field__toggle.is-visible .nx-eye-off { display: block; }

.auth-options {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin: 4px 0 26px;
}
.remember-me,
.auth-form .remember-me {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin: 0;
    cursor: pointer;
    text-transform: none;
    letter-spacing: 0;
}
.remember-me span {
    color: var(--nx-t1);
    font-size: 14px;
    font-weight: 500;
}
.remember-me input[type="checkbox"],
.terms-checkbox input[type="checkbox"] {
    appearance: none;
    -webkit-appearance: none;
    width: 20px;
    height: 20px;
    margin: 0;
    flex-shrink: 0;
    border: 1px solid var(--nx-line-2);
    border-radius: 6px;
    background: rgba(10, 10, 10, 0.6);
    cursor: pointer;
    transition: background 0.2s ease, border-color 0.2s ease;
}
.remember-me input[type="checkbox"]:checked,
.terms-checkbox input[type="checkbox"]:checked {
    border-color: var(--nx-acc);
    background: var(--nx-acc) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12' fill='none'%3E%3Cpath d='M2.5 6.2L5 8.5l4.5-5' stroke='%230a0a0a' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 12px no-repeat;
}
.remember-me input[type="checkbox"]:focus-visible,
.terms-checkbox input[type="checkbox"]:focus-visible {
    outline: none;
    box-shadow: 0 0 0 4px rgba(212, 175, 55, 0.18);
}
.forgot-password {
    color: var(--nx-acc-2);
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
}
.forgot-password:hover { color: var(--nx-acc); }

.terms-checkbox {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    margin: 6px 0 24px;
    padding: 14px 16px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--nx-line);
}
.auth-form .terms-checkbox label {
    margin: 0;
    color: var(--nx-t1);
    font-size: 13px;
    font-weight: 500;
    line-height: 1.55;
    letter-spacing: 0;
    text-transform: none;
}
.terms-checkbox a {
    color: var(--nx-acc-2);
    text-decoration: none;
    font-weight: 600;
}
.terms-checkbox a:hover { text-decoration: underline; }

.auth-btn,
.trading-auth-theme .btn-warning {
    display: block;
    width: 100%;
    height: 54px;
    margin: 0;
    padding: 0 20px;
    border: 0;
    border-radius: 14px;
    background: linear-gradient(135deg, var(--nx-acc-2) 0%, var(--nx-acc) 55%, var(--nx-acc-3) 100%);
    background-size: 160% 100%;
    background-position: 0% 0%;
    color: var(--nx-bg-0);
    font-family: inherit;
    font-size: 15px;
    font-weight: 800;
    letter-spacing: 0.2px;
    cursor: pointer;
    box-shadow: 0 14px 30px -14px rgba(212, 175, 55, 0.9), inset 0 1px 0 rgba(255, 255, 255, 0.35);
    transition: transform 0.2s ease, box-shadow 0.2s ease, background-position 0.4s ease;
}
.auth-btn:hover,
.trading-auth-theme .btn-warning:hover {
    color: var(--nx-bg-0);
    background-position: 100% 0%;
    transform: translateY(-1px);
    box-shadow: 0 20px 36px -16px rgba(212, 175, 55, 0.95), inset 0 1px 0 rgba(255, 255, 255, 0.35);
}
.auth-btn:active { transform: translateY(0); }
.auth-btn:disabled {
    cursor: not-allowed;
    opacity: 0.7;
    transform: none;
}
a.auth-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
}

.auth-footer {
    margin-top: 26px;
    padding-top: 22px;
    border-top: 1px solid var(--nx-line);
    color: var(--nx-t1);
    font-size: 14px;
    text-align: center;
}
.auth-footer p { margin: 0; }
.auth-link {
    color: var(--nx-acc-2);
    font-weight: 700;
    text-decoration: none;
}
.auth-link:hover { color: var(--nx-acc); text-decoration: underline; }

/* Alerts / validation */
.nx-alert {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin-bottom: 20px;
    padding: 12px 14px;
    border-radius: 12px;
    font-size: 13px;
    font-weight: 600;
    line-height: 1.5;
    color: var(--nx-bad);
    background: rgba(247, 109, 125, 0.08);
    border: 1px solid rgba(247, 109, 125, 0.24);
}
.nx-alert:empty { display: none; }
.nx-hint {
    margin-top: 8px;
    color: var(--nx-ok);
    font-size: 12px;
    font-weight: 600;
}
.nx-hint:empty { display: none; }

/* Steps (2FA) */
.nx-steps {
    display: flex;
    flex-direction: column;
    gap: 14px;
    margin: 0 0 24px;
    padding: 0;
    list-style: none;
    counter-reset: nxstep;
}
.nx-steps li {
    position: relative;
    padding: 14px 16px 14px 56px;
    border-radius: 14px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--nx-line);
    color: var(--nx-t1);
    font-size: 13px;
    line-height: 1.55;
    counter-increment: nxstep;
}
.nx-steps li::before {
    content: counter(nxstep);
    position: absolute;
    left: 14px;
    top: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 9px;
    background: var(--nx-acc-soft);
    border: 1px solid var(--nx-acc-line);
    color: var(--nx-acc-2);
    font-size: 12px;
    font-weight: 800;
}
.nx-steps strong {
    display: block;
    color: var(--nx-t0);
    font-size: 14px;
    margin-bottom: 2px;
}
.nx-qr {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
    margin-bottom: 24px;
}
.nx-qr__frame {
    position: relative;
    padding: 16px;
    border-radius: 18px;
    background: #ffffff;
    box-shadow: 0 0 0 1px var(--nx-acc-line), 0 0 0 8px rgba(212, 175, 55, 0.06), 0 24px 48px -24px rgba(212, 175, 55, 0.6);
}
.nx-qr__frame canvas {
    display: block;
    width: 184px;
    height: 184px;
}
.nx-qr__code {
    max-width: 100%;
    padding: 8px 14px;
    border-radius: 10px;
    background: rgba(10, 10, 10, 0.6);
    border: 1px dashed var(--nx-acc-line);
    color: var(--nx-acc-2);
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
    font-size: 13px;
    letter-spacing: 0.08em;
    word-break: break-all;
    text-align: center;
}
.nx-stores {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    margin-top: 10px;
}
.nx-store {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    border-radius: 12px;
    background: rgba(10, 10, 10, 0.6);
    border: 1px solid var(--nx-line-2);
    color: var(--nx-t0);
    text-decoration: none;
    transition: border-color 0.2s ease, transform 0.2s ease;
}
.nx-store:hover {
    color: var(--nx-t0);
    border-color: var(--nx-acc);
    transform: translateY(-1px);
}
.nx-store svg { flex-shrink: 0; color: var(--nx-acc); }
.nx-store small {
    display: block;
    color: var(--nx-t2);
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.4px;
}
.nx-store strong {
    display: block;
    font-size: 14px;
    line-height: 1.2;
}

/* ---------- 404 ---------- */
.nx-404 {
    width: 100%;
    max-width: 760px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}
.nx-404__mark {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    margin: 8px 0 22px;
}
.nx-404__digits,
.nx-404__ghost {
    font-size: clamp(120px, 20vw, 220px);
    font-weight: 800;
    line-height: 0.9;
    letter-spacing: -0.06em;
}
.nx-404__digits {
    position: relative;
    z-index: 2;
    background: linear-gradient(170deg, #fbe7a6 0%, var(--nx-acc-2) 30%, var(--nx-acc) 65%, var(--nx-acc-3) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(0 18px 40px rgba(212, 175, 55, 0.25));
}
.nx-404__ghost {
    position: absolute;
    z-index: 1;
    color: transparent;
    -webkit-text-stroke: 1px rgba(212, 175, 55, 0.22);
    transform: translate(14px, 14px);
}
.nx-404__orbit {
    position: absolute;
    z-index: 3;
    inset: 50% auto auto 50%;
    width: min(620px, 118%);
    transform: translate(-50%, -50%);
    pointer-events: none;
    overflow: visible;
}
.nx-404__title {
    margin: 18px 0 12px;
    color: var(--nx-t0);
    font-size: clamp(28px, 3.6vw, 40px);
    font-weight: 800;
    line-height: 1.12;
    letter-spacing: -0.03em;
}
.nx-404__title span {
    background: linear-gradient(120deg, var(--nx-acc-2) 0%, var(--nx-acc) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}
.nx-404__text {
    max-width: 480px;
    margin: 0 0 28px;
    color: var(--nx-t1);
    font-size: 16px;
    line-height: 1.65;
}
.nx-404__actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px;
    margin-bottom: 40px;
}
.nx-404__actions .auth-btn,
.nx-404__actions .nx-btn-ghost {
    width: auto;
    min-width: 180px;
    height: 52px;
    padding: 0 26px;
}
.nx-404__links {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
    width: 100%;
}
.nx-404__link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px;
    border-radius: 16px;
    background: linear-gradient(180deg, rgba(31, 31, 31, 0.7) 0%, rgba(15, 15, 15, 0.85) 100%);
    border: 1px solid var(--nx-line);
    color: var(--nx-t0);
    text-align: left;
    text-decoration: none;
    transition: border-color 0.2s ease, transform 0.2s ease;
}
.nx-404__link:hover {
    color: var(--nx-t0);
    border-color: var(--nx-acc-line);
    transform: translateY(-2px);
}
.nx-404__link .nx-feature__icon { margin: 0; flex-shrink: 0; }
.nx-404__link strong {
    display: block;
    font-size: 14px;
    font-weight: 700;
}
.nx-404__link small {
    display: block;
    color: var(--nx-t2);
    font-size: 12px;
}
.nx-404__link > svg:last-child {
    margin-left: auto;
    flex-shrink: 0;
    color: var(--nx-t2);
    transition: color 0.2s ease, transform 0.2s ease;
}
.nx-404__link:hover > svg:last-child {
    color: var(--nx-acc);
    transform: translateX(3px);
}
.nx-btn-ghost {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    height: 48px;
    border-radius: 14px;
    border: 1px solid var(--nx-line-2);
    background: rgba(255, 255, 255, 0.03);
    color: var(--nx-t0);
    font-size: 14px;
    font-weight: 700;
    text-decoration: none;
    transition: border-color 0.2s ease, color 0.2s ease, background 0.2s ease;
}
.nx-btn-ghost:hover {
    color: var(--nx-acc-2);
    border-color: var(--nx-acc-line);
    background: var(--nx-acc-soft);
}

/* ---------- Toastr ---------- */
.trading-auth-theme #toast-container > div {
    border-radius: 14px;
    box-shadow: 0 16px 30px rgba(0, 0, 0, 0.35);
    opacity: 1;
}
.trading-auth-theme .toast-success { color: var(--nx-bg-0) !important; }
.trading-auth-theme .toast-error { background-color: #c43c4c !important; }

/* ---------- Motion ---------- */
.nx-rise { animation: nxRise 0.6s cubic-bezier(0.2, 0.7, 0.2, 1) both; }
.nx-rise--2 { animation-delay: 0.08s; }
.nx-rise--3 { animation-delay: 0.16s; }
.nx-rise--4 { animation-delay: 0.24s; }

@keyframes nxRise {
    from { opacity: 0; transform: translateY(14px); }
    to { opacity: 1; transform: none; }
}
@keyframes nxPulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.55; transform: scale(0.85); }
}
@keyframes nxSpin { to { transform: rotate(360deg); } }

@media (prefers-reduced-motion: reduce) {
    .nx-rise, .nx-dot, .nx-bg__ring::after { animation: none; }
    .nx-404__orbit .nx-orbit-dot { display: none; }
}

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
    .nx-features { grid-template-columns: minmax(0, 1fr); }
    .nx-feature { display: flex; align-items: center; gap: 14px; padding: 12px 14px; }
    .nx-feature__icon { margin-bottom: 0; flex-shrink: 0; }
}
@media (max-width: 991px) {
    :root { --nx-nav-h: 74px; }
    .nx-shell {
        grid-template-columns: minmax(0, 1fr);
        gap: 0;
        padding: 28px 16px 28px;
        align-items: start;
    }
    .nx-hero { display: none; }
    .nx-bg__ring { left: 50%; top: 30%; }
}
@media (max-width: 640px) {
    .nx-nav { padding: 10px 12px 0; }
    .nx-nav__bar { padding: 8px 8px 8px 14px; border-radius: 16px; }
    .nx-nav__logo { max-height: 40px; max-width: 96px; }
    .nx-nav__link { padding: 9px 11px; }
    .nx-nav__link span { display: none; }
    .nx-nav__link--cta span { display: inline; }
    .auth-card { padding: 28px 20px; border-radius: 20px; }
    .nx-card-head { margin-bottom: 22px; }
    .nx-card-icon { width: 44px; height: 44px; border-radius: 13px; }
    .auth-title { font-size: 22px; }
    .nx-grid-2 { grid-template-columns: minmax(0, 1fr); }
    .auth-options { flex-wrap: wrap; }
    .nx-404__links { grid-template-columns: minmax(0, 1fr); }
    .nx-404__actions { width: 100%; flex-direction: column; }
    .nx-404__actions .auth-btn,
    .nx-404__actions .nx-btn-ghost { width: 100%; }
    .nx-404__ghost { transform: translate(8px, 8px); }
}
@media (max-width: 380px) {
    .nx-nav__link--cta span { display: none; }
}
