:root {
    --accent: #2fd67a;
    --accent-strong: #20b866;
    --accent-soft: rgba(47, 214, 122, 0.10);
    --accent-muted: rgba(47, 214, 122, 0.22);

    --bg-main: #0b0f14;
    --bg-left: #0d1218;
    --bg-right: #101720;
    --bg-panel: rgba(13, 18, 25, 0.74);
    --bg-field: #151c25;
    --bg-field-hover: #17202a;

    --border-soft: rgba(255, 255, 255, 0.07);
    --border-strong: rgba(255, 255, 255, 0.12);

    --text-main: #f4f7fb;
    --text-soft: #b6c0ce;
    --text-muted: #8d98a8;
    --text-faint: #657286;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html,
body {
    min-height: 100%;
}

body {
    background: var(--bg-main);
    overflow-x: hidden;
    overflow-y: auto;
    font-feature-settings: "cv02", "cv03", "cv04", "cv11";
}

.auth-page {
    width: 100%;
    min-height: 100vh;
    display: grid;
    grid-template-columns: 45% 55%;
    position: relative;
    overflow: hidden;
    background:
            radial-gradient(circle at 18% 14%, rgba(47, 214, 122, 0.055), transparent 24%),
            radial-gradient(circle at 90% 88%, rgba(47, 214, 122, 0.045), transparent 30%),
            linear-gradient(90deg, var(--bg-left) 0%, var(--bg-left) 45%, var(--bg-right) 45%, var(--bg-right) 100%);
}

.auth-page::before {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    opacity: 0.45;
    background-image:
            linear-gradient(rgba(255,255,255,0.025) 1px, transparent 1px),
            linear-gradient(90deg, rgba(255,255,255,0.025) 1px, transparent 1px);
    background-size: 72px 72px;
    mask-image: radial-gradient(circle at 50% 50%, black, transparent 72%);
}

.auth-left {
    min-height: 100vh;
    padding: 64px 34px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    z-index: 1;
}

.left-inner {
    width: 100%;
    max-width: 560px;
    text-align: center;
    margin-block-end: auto;
}

.hero-image-place {
    width: 226px;
    height: 226px;
    margin: 0 auto 32px;
    position: relative;
}

.hero-image-place::before {
    content: "";
    position: absolute;
    inset: 18px;
    border-radius: 999px;
    background: rgba(47, 214, 122, 0.08);
    filter: blur(32px);
}

.hero-image-place img {
    position: relative;
    width: 100%;
    height: 100%;
    object-fit: contain;
    opacity: 0.94;
    filter: saturate(0.88) contrast(1.04);
}

.hero-eyebrow,
.form-kicker {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--accent);
    font-size: 11px;
    font-weight: 700;
    line-height: 1;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    margin-bottom: 16px;
}

.left-inner h1 {
    font-size: clamp(34px, 3vw, 46px);
    line-height: 1.06;
    font-weight: 760;
    letter-spacing: -0.05em;
    color: var(--text-main);
    margin-bottom: 20px;
}

.hero-subtitle {
    max-width: 510px;
    margin: 0 auto 30px;
    font-size: 16px;
    line-height: 1.72;
    color: var(--text-soft);
    font-weight: 500;
}

.trust-stack {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin: 0 auto;
    width: 100%;
    max-width: 520px;
}

.trust-card {
    min-height: 82px;
    border-radius: 18px;
    border: 1px solid var(--border-soft);
    background:
            linear-gradient(180deg, rgba(255,255,255,0.034), rgba(255,255,255,0.012)),
            rgba(255, 255, 255, 0.018);
    display: grid;
    grid-template-columns: 48px 1fr;
    align-items: flex-start;
    gap: 16px;
    padding: 18px 20px;
    text-align: left;
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.035);
}

.trust-card.is-primary {
    border-color: rgba(47, 214, 122, 0.18);
    background:
            linear-gradient(180deg, rgba(47, 214, 122, 0.065), rgba(255,255,255,0.014)),
            rgba(255, 255, 255, 0.018);
}

.trust-index {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(255,255,255,0.045);
    border: 1px solid rgba(255,255,255,0.07);
    color: var(--accent);
    font-size: 11px;
    font-weight: 760;
    letter-spacing: -0.02em;
}

.trust-card strong {
    display: block;
    color: #edf3fb;
    font-size: 15px;
    line-height: 1.25;
    font-weight: 680;
    margin-bottom: 6px;
}

.trust-card p {
    color: var(--text-muted);
    font-size: 13px;
    line-height: 1.5;
    font-weight: 500;
}

.stats {
    width: 100%;
    max-width: 520px;
    margin: 40px auto 0;
    padding-top: 28px;
    border-top: 1px solid var(--border-soft);
    display: flex;
    justify-content: center;
    gap: 54px;
}

.stat-item {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.stat-item strong {
    color: var(--text-main);
    font-size: 28px;
    line-height: 1;
    font-weight: 760;
    letter-spacing: -0.045em;
}

.stat-item span {
    color: var(--text-muted);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.13em;
}

.auth-right {
    min-height: 100vh;
    padding: 84px 32px 70px;
    display: flex;
    justify-content: center;
    align-items: flex-start;
    position: relative;
    z-index: 2;
}

.auth-form {
    width: 100%;
    max-width: 520px;
    margin-left: 40px;
    padding: 36px;
    border: 1px solid var(--border-soft);
    border-radius: 24px;
    background:
            linear-gradient(180deg, rgba(255,255,255,0.045), rgba(255,255,255,0.018)),
            var(--bg-panel);
    box-shadow:
            0 32px 90px rgba(0,0,0,0.32),
            inset 0 1px 0 rgba(255,255,255,0.05);
    backdrop-filter: blur(18px);
}

.mobile-auth-intro {
    display: none;
}

.form-heading {
    margin-bottom: 12px;
}

.form-kicker {
    margin-bottom: 12px;
}

.auth-form h2 {
    font-size: 32px;
    line-height: 1.12;
    font-weight: 760;
    letter-spacing: -0.045em;
    color: var(--text-main);
}

.signin-text {
    color: var(--text-muted);
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 26px;
}

a {
    color: var(--accent);
    text-decoration: none;
    font-weight: 700;
}


.field {
    width: 100%;
    height: 60px;
    border-radius: 12px;
    background: var(--bg-field);
    border: 1px solid rgba(255,255,255,0.08);
    margin-bottom: 18px;
    position: relative;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.field:hover,
.field:focus-within {
    background: var(--bg-field-hover);
    border-color: rgba(47, 214, 122, 0.42);
    box-shadow: 0 0 0 4px rgba(47, 214, 122, 0.055);
}

.field input {
    width: 100%;
    height: 100%;
    border: none;
    outline: none;
    background: transparent;
    color: #dce6f3;
    font-size: 15px;
    font-weight: 560;
    padding: 0 18px;
}

.field input::placeholder {
    color: #647184;
}

.password-field input {
    padding-right: 58px;
}

.toggle-password {
    position: absolute;
    right: 15px;
    top: 50%;
    width: 32px;
    height: 32px;
    transform: translateY(-50%);
    border: none;
    border-radius: 9px;
    background: transparent;
    color: #94a1b2;
    cursor: pointer;
    font-size: 19px;
    transition: 0.18s ease;
}

.toggle-password:hover {
    background: rgba(255,255,255,0.045);
    color: var(--text-main);
}

.toggle-password .eye-closed {
    display: none;
}

.toggle-password.is-visible .eye-open {
    display: none;
}

.toggle-password.is-visible .eye-closed {
    display: inline;
}

.password-rules {
    margin-top: -8px;
    margin-bottom: 18px;
    min-height: 38px;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    border: 1px solid rgba(255,255,255,0.055);
    border-radius: 10px;
    overflow: hidden;
    background: rgba(8, 12, 17, 0.28);
}

.password-rules div {
    padding: 0 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #838fa1;
    font-size: 11px;
    line-height: 1.25;
    font-weight: 650;
    text-align: center;
    border-right: 1px solid rgba(255,255,255,0.045);
}

.password-rules div:last-child {
    border-right: none;
}

.optional-btn {
    width: 100%;
    min-height: 42px;
    display: flex;
    align-items: center;
    gap: 8px;
    background: transparent;
    border: none;
    border-bottom: 1px solid rgba(255,255,255,0.055);
    color: var(--text-soft);
    font-size: 13px;
    font-weight: 650;
    cursor: pointer;
    margin-bottom: 6px;
    padding: 0 2px;
    transition: 0.18s ease;
}

.optional-btn span {
    color: var(--text-faint);
    font-size: 12px;
    font-weight: 600;
}

.optional-btn i {
    margin-left: auto;
    color: #778397;
    font-size: 19px;
}

.optional-btn:hover {
    color: var(--accent);
    border-bottom-color: rgba(47, 214, 122, 0.22);
}

.fake-captcha,
.security-check {
    width: 100%;
    min-height: 76px;
    margin: 18px 0 22px;
    border-radius: 16px;
    border: 1px solid rgba(255,255,255,0.085);
    background:
            linear-gradient(135deg, rgba(255,255,255,0.035), rgba(255,255,255,0.012)),
            #121922;
    display: grid;
    grid-template-columns: 46px 1fr auto;
    align-items: center;
    gap: 16px;
    padding: 16px;
    cursor: pointer;
    user-select: none;
    transition: border-color 0.22s ease, box-shadow 0.22s ease, background 0.22s ease;
}

.fake-captcha:hover {
    border-color: rgba(47, 214, 122, 0.36);
    box-shadow: 0 0 0 4px rgba(47, 214, 122, 0.05);
}

.captcha-check {
    width: 34px;
    height: 34px;
    border-radius: 10px;
    border: 1px solid rgba(255,255,255,0.15);
    background: #0f151d;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.captcha-loader {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    border: 2px solid rgba(47, 214, 122, 0.25);
    border-top-color: var(--accent);
    display: none;
    animation: spin 0.7s linear infinite;
}

.captcha-mark {
    display: none;
    color: #06110a;
    font-weight: 800;
}

.captcha-text {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.captcha-text strong {
    color: #eaf1fa;
    font-size: 14px;
    font-weight: 700;
}

.captcha-text span {
    color: var(--text-muted);
    font-size: 12px;
    font-weight: 500;
}

.captcha-brand {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
    color: #748197;
    font-size: 10px;
    font-weight: 700;
    font-style: normal;
}

.captcha-brand span {
    font-size: 26px;
    color: rgba(47, 214, 122, 0.72);
}

.captcha-brand em {
    font-style: normal;
}

.fake-captcha.is-loading .captcha-loader {
    display: block;
}

.fake-captcha.is-loading .captcha-check {
    border-color: rgba(47, 214, 122, 0.42);
}

.fake-captcha.is-verified {
    border-color: rgba(47, 214, 122, 0.48);
    background:
            linear-gradient(135deg, rgba(47, 214, 122, 0.075), rgba(255,255,255,0.014)),
            #121922;
}

.fake-captcha.is-verified .captcha-check {
    background: var(--accent);
    border-color: var(--accent);
}

.fake-captcha.is-verified .captcha-loader {
    display: none;
}

.fake-captcha.is-verified .captcha-mark {
    display: block;
}

.check-row {
    display: flex;
    align-items: flex-start;
    gap: 11px;
    margin-bottom: 16px;
    color: #909bad;
    font-size: 12px;
    line-height: 1.58;
    font-weight: 560;
    cursor: pointer;
}

.check-row input {
    appearance: none;
    width: 22px;
    height: 22px;
    min-width: 22px;
    border-radius: 6px;
    border: 1px solid rgba(255,255,255,0.14);
    background: #151d27;
    cursor: pointer;
    position: relative;
    transition: 0.18s ease;
}

.check-row input:hover {
    border-color: rgba(47, 214, 122, 0.42);
}

.check-row input:checked {
    background: var(--accent);
    border-color: var(--accent);
}

.check-row input:checked::after {
    content: "✓";
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #06110a;
    font-weight: 800;
    font-size: 14px;
}

.check-row:first-of-type input {
    border-color: rgba(47, 214, 122, 0.5);
}

.check-row.muted {
    color: var(--text-faint);
    margin-bottom: 28px;
}

.submit-btn {
    width: 100%;
    height: 54px;
    border-radius: 12px;
    border: none;
    background: linear-gradient(180deg, #39df86 0%, var(--accent-strong) 100%);
    color: #03120a;
    font-size: 15px;
    font-weight: 760;
    letter-spacing: -0.01em;
    cursor: pointer;
    box-shadow:
            0 12px 28px rgba(32, 184, 102, 0.18),
            inset 0 1px 0 rgba(255,255,255,0.35);
    transition: transform 0.22s ease, box-shadow 0.22s ease, filter 0.22s ease;
}

.submit-btn:hover {
    transform: translateY(-1px);
    box-shadow:
            0 18px 42px rgba(32, 184, 102, 0.24),
            inset 0 1px 0 rgba(255,255,255,0.4);
    filter: saturate(1.04);
}

.green-orb {
    position: fixed;
    right: -260px;
    bottom: -340px;
    width: 760px;
    height: 760px;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(47, 214, 122, 0.055), rgba(20, 29, 44, 0.42) 48%, transparent 72%);
    pointer-events: none;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

@media (max-width: 1180px) {
    .auth-page {
        grid-template-columns: 48% 52%;
    }

    .auth-form {
        margin-left: 16px;
    }

    .left-inner h1 {
        font-size: 34px;
    }

    .trust-card {
        grid-template-columns: 42px 1fr;
        padding: 16px;
    }

    .stats {
        gap: 34px;
    }
}

@media (max-width: 900px) {
    .auth-page {
        display: block;
        min-height: 100vh;
        background:
                radial-gradient(circle at 50% -10%, rgba(47, 214, 122, 0.10), transparent 34%),
                var(--bg-right);
    }

    .auth-left {
        display: none;
    }

    .auth-right {
        min-height: 100vh;
        padding: 34px 18px 44px;
        align-items: center;
    }

    .auth-form {
        margin-left: 0;
        max-width: 480px;
        padding: 28px;
        border-radius: 22px;
    }

    .mobile-auth-intro {
        display: block;
        margin-bottom: 30px;
        text-align: center;
    }

    .mobile-auth-intro .hero-eyebrow {
        margin-bottom: 12px;
    }

    .mobile-auth-intro h1 {
        color: var(--text-main);
        font-size: 29px;
        line-height: 1.08;
        font-weight: 760;
        letter-spacing: -0.045em;
    }

    .mobile-auth-intro p {
        max-width: 360px;
        margin: 12px auto 0;
        color: var(--text-muted);
        font-size: 14px;
        line-height: 1.6;
        font-weight: 500;
    }

    .form-heading,
    .signin-text {
        text-align: center;
    }

    .auth-form h2 {
        font-size: 27px;
    }

    .field {
        height: 58px;
    }

    .password-rules {
        grid-template-columns: 1fr;
        margin-top: -8px;
    }

    .password-rules div {
        min-height: 30px;
        border-right: none;
        border-bottom: 1px solid rgba(255,255,255,0.045);
    }

    .password-rules div:last-child {
        border-bottom: none;
    }

    .fake-captcha {
        grid-template-columns: 42px 1fr;
    }

    .captcha-brand {
        display: none;
    }

    .green-orb {
        width: 520px;
        height: 520px;
        right: -260px;
        bottom: -260px;
    }
}

@media (max-width: 420px) {
    .auth-right {
        padding: 22px 14px 34px;
    }

    .auth-form {
        padding: 22px 18px;
        border-radius: 20px;
    }

    .mobile-auth-intro h1 {
        font-size: 26px;
    }

    .auth-form h2 {
        font-size: 24px;
    }

    .signin-text {
        font-size: 14px;
    }

    .field {
        height: 56px;
        border-radius: 11px;
    }

    .field input {
        font-size: 14px;
    }

    .fake-captcha {
        padding: 14px;
        gap: 12px;
    }

    .captcha-text strong {
        font-size: 14px;
    }

    .submit-btn {
        height: 50px;
    }
}

/* Backend-connected form states */
.field.error {
    border-color: rgba(248, 113, 113, 0.68);
    box-shadow: 0 0 0 4px rgba(248, 113, 113, 0.075);
}

.password-rules {
    grid-template-columns: repeat(5, 1fr);
}

.password-rules div {
    position: relative;
    padding-left: 22px;
}

.password-rules div::before {
    content: "";
    position: absolute;
    left: 9px;
    top: 50%;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    transform: translateY(-50%);
    background: #566274;
}

.password-rules div.valid {
    color: #a7f3c8;
}

.password-rules div.valid::before {
    background: var(--accent);
    box-shadow: 0 0 12px rgba(47, 214, 122, 0.28);
}

.password-rules div.invalid {
    color: #7f8a9a;
}

.optional-panel {
    display: grid;
    grid-template-rows: 0fr;
    overflow: hidden;
    transition: grid-template-rows 0.22s ease, margin 0.22s ease;
}

.optional-panel.open {
    grid-template-rows: 1fr;
    margin-bottom: 16px;
}

.optional-panel > .field {
    min-height: 0;
}

.compact-field {
    height: 52px;
    margin-bottom: 0;
    border-radius: 10px;
}

.submit-btn:disabled {
    cursor: not-allowed;
    opacity: 0.48;
    transform: none;
    box-shadow: none;
}

.submit-btn.active {
    opacity: 1;
}

.spinner {
    width: 20px;
    height: 20px;
    display: inline-block;
    border-radius: 50%;
    border: 2px solid rgba(3, 18, 10, 0.25);
    border-top-color: #03120a;
    animation: spin 0.7s linear infinite;
}

@media (max-width: 900px) {
    .password-rules {
        grid-template-columns: 1fr;
    }
}

/* Polished validation, optional panels and submit loading states */
.field {
    overflow: visible;
}

.field-status {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%) scale(0.86);
    opacity: 0;
    pointer-events: none;
    font-size: 19px;
    transition: opacity 0.18s ease, transform 0.18s ease, color 0.18s ease;
}

.field.success .field-status,
.field.error .field-status {
    opacity: 1;
    transform: translateY(-50%) scale(1);
}

.field.success .field-status {
    color: var(--accent);
}

.field.error .field-status {
    color: #fb7185;
}

.field.success {
    border-color: rgba(47, 214, 122, 0.46);
    box-shadow: 0 0 0 4px rgba(47, 214, 122, 0.055);
}

.field.error {
    border-color: rgba(251, 113, 133, 0.72);
    box-shadow: 0 0 0 4px rgba(251, 113, 133, 0.08);
}

.field:not(.password-field) input {
    padding-right: 48px;
}

.password-field .field-status {
    right: 54px;
}

.field-feedback {
    display: none;
    margin: -10px 0 16px;
    color: #fb7185;
    font-size: 12px;
    line-height: 1.45;
    font-weight: 600;
}

.field-feedback.visible {
    display: block;
    animation: feedbackIn 0.18s ease both;
}

.password-rules {
    gap: 0;
}

.password-rules div {
    transition: color 0.18s ease, background 0.18s ease;
}

.password-rules div.valid {
    color: #b9f8d4;
    background: rgba(47, 214, 122, 0.045);
}

.password-rules div.invalid {
    color: #7f8a9a;
}

.password-rules div.valid::before {
    width: 7px;
    height: 7px;
    background: var(--accent);
    box-shadow: 0 0 14px rgba(47, 214, 122, 0.35);
}

.password-rules div.invalid::before {
    background: #566274;
}

.optional-btn {
    border-radius: 12px;
    padding: 0 12px;
    border: 1px solid transparent;
    background: rgba(255,255,255,0.012);
    margin-bottom: 8px;
}

.optional-btn:hover {
    background: rgba(255,255,255,0.028);
    border-color: rgba(47, 214, 122, 0.16);
}

.optional-btn[aria-expanded="true"] {
    color: var(--accent);
    border-color: rgba(47, 214, 122, 0.18);
    background: rgba(47, 214, 122, 0.045);
}

.optional-btn i {
    transition: transform 0.22s ease, color 0.22s ease;
}

.optional-btn[aria-expanded="true"] i {
    color: var(--accent);
}

.optional-panel {
    display: block;
    max-height: 0;
    opacity: 0;
    overflow: hidden;
    transform: translateY(-6px);
    pointer-events: none;
    margin-bottom: 0;
    transition:
            max-height 0.32s cubic-bezier(.2,.8,.2,1),
            opacity 0.22s ease,
            transform 0.32s cubic-bezier(.2,.8,.2,1),
            margin-bottom 0.22s ease;
}

.optional-panel.open {
    max-height: 86px;
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
    margin-bottom: 14px;
}

.optional-panel-inner {
    padding-top: 4px;
}

.optional-panel .field {
    margin-bottom: 0;
}

.security-check.error {
    border-color: rgba(251, 113, 133, 0.72);
    box-shadow: 0 0 0 4px rgba(251, 113, 133, 0.08);
}

.security-check.is-verified {
    box-shadow: 0 0 0 4px rgba(47, 214, 122, 0.055);
}

.check-row {
    padding: 10px 10px;
    margin-left: -10px;
    margin-right: -10px;
    border-radius: 12px;
    transition: background 0.18s ease, color 0.18s ease;
}

.check-row.error {
    background: rgba(251, 113, 133, 0.055);
    color: #fda4af;
}

.check-row.error input {
    border-color: rgba(251, 113, 133, 0.72);
    box-shadow: 0 0 0 4px rgba(251, 113, 133, 0.075);
}

.check-row.success {
    background: rgba(47, 214, 122, 0.035);
}

.submit-hint {
    margin: 0 0 12px;
    color: #778397;
    font-size: 12px;
    line-height: 1.45;
    font-weight: 600;
    text-align: center;
    transition: color 0.18s ease;
}

.submit-hint.ready {
    color: #a7f3c8;
}

.submit-btn {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    overflow: hidden;
}

.submit-btn:disabled {
    cursor: not-allowed;
    opacity: 1;
    color: rgba(195, 205, 218, 0.62);
    background: linear-gradient(180deg, rgba(70, 82, 96, 0.62), rgba(43, 52, 64, 0.62));
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.08);
    filter: saturate(0.55);
}

.submit-btn:disabled:hover {
    transform: none;
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.08);
}

.submit-btn.active {
    color: #03120a;
    background: linear-gradient(180deg, #39df86 0%, var(--accent-strong) 100%);
    box-shadow:
            0 12px 28px rgba(32, 184, 102, 0.18),
            inset 0 1px 0 rgba(255,255,255,0.35);
    filter: none;
}

.submit-btn .spinner {
    display: none;
    width: 19px;
    height: 19px;
    border-radius: 50%;
    border: 2px solid rgba(3, 18, 10, 0.24);
    border-top-color: #03120a;
    animation: spin 0.7s linear infinite;
}

.submit-btn.is-loading {
    cursor: wait;
    opacity: 1;
    color: #03120a;
    background: linear-gradient(180deg, #39df86 0%, var(--accent-strong) 100%);
    filter: none;
}

.submit-btn.is-loading .btn-label {
    opacity: 0.72;
}

.submit-btn.is-loading .spinner {
    display: inline-block;
}

@keyframes feedbackIn {
    from {
        opacity: 0;
        transform: translateY(-3px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (max-width: 900px) {
    .optional-panel.open {
        max-height: 92px;
    }
}


/* Toast notifications */
.toast-root {
    position: fixed;
    top: 22px;
    right: 22px;
    z-index: 9999;
    width: min(390px, calc(100vw - 32px));
    display: flex;
    flex-direction: column;
    gap: 12px;
    pointer-events: none;
}

.toast {
    position: relative;
    display: grid;
    grid-template-columns: 42px 1fr 34px;
    align-items: start;
    gap: 12px;
    min-height: 76px;
    padding: 16px 14px 15px 16px;
    border-radius: 18px;
    border: 1px solid rgba(255,255,255,0.09);
    background:
            linear-gradient(145deg, rgba(255,255,255,0.075), rgba(255,255,255,0.026)),
            rgba(12, 17, 24, 0.92);
    box-shadow:
            0 24px 70px rgba(0,0,0,0.34),
            inset 0 1px 0 rgba(255,255,255,0.07);
    backdrop-filter: blur(18px);
    overflow: hidden;
    pointer-events: auto;
    opacity: 0;
    transform: translateX(24px) translateY(-6px) scale(0.985);
    transition:
            opacity 0.28s ease,
            transform 0.34s cubic-bezier(.2,.8,.2,1);
}

.toast.show {
    opacity: 1;
    transform: translateX(0) translateY(0) scale(1);
}

.toast.hide {
    opacity: 0;
    transform: translateX(24px) translateY(-4px) scale(0.985);
}

.toast::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background: #8ea0b5;
}

.toast-icon {
    width: 40px;
    height: 40px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255,255,255,0.045);
    color: #b7c3d4;
    font-size: 22px;
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.05);
}

.toast-content {
    min-width: 0;
    padding-top: 1px;
}

.toast-content strong {
    display: block;
    color: #f3f7fc;
    font-size: 14px;
    line-height: 1.25;
    font-weight: 760;
    letter-spacing: -0.01em;
    margin-bottom: 5px;
}

.toast-content span {
    display: block;
    color: #9da9ba;
    font-size: 13px;
    line-height: 1.42;
    font-weight: 550;
}

.toast-close {
    width: 30px;
    height: 30px;
    border-radius: 10px;
    border: none;
    background: transparent;
    color: #748095;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 17px;
    transition: background 0.18s ease, color 0.18s ease;
}

.toast-close:hover {
    color: #eef3fb;
    background: rgba(255,255,255,0.07);
}

.toast-progress {
    position: absolute;
    left: 0;
    bottom: 0;
    height: 2px;
    width: 100%;
    transform-origin: left;
    background: rgba(142,160,181,0.55);
    animation: toastProgress 4.2s linear forwards;
}

.toast-error .toast-progress {
    animation-duration: 5.6s;
}

.toast-success::before,
.toast-success .toast-progress {
    background: linear-gradient(90deg, var(--accent), #6ee7a5);
}

.toast-success .toast-icon {
    color: #9cf5bf;
    background: rgba(47, 214, 122, 0.105);
}

.toast-error::before,
.toast-error .toast-progress {
    background: linear-gradient(90deg, #fb7185, #fecdd3);
}

.toast-error .toast-icon {
    color: #fda4af;
    background: rgba(251, 113, 133, 0.105);
}

.toast-info::before,
.toast-info .toast-progress {
    background: linear-gradient(90deg, #8ea0b5, #d7dee9);
}

.toast-info .toast-icon {
    color: #c7d2e2;
}

@keyframes toastProgress {
    from { transform: scaleX(1); }
    to { transform: scaleX(0); }
}

@media (max-width: 640px) {
    .toast-root {
        top: auto;
        right: 14px;
        left: 14px;
        bottom: 16px;
        width: auto;
    }

    .toast {
        grid-template-columns: 38px 1fr 32px;
        min-height: 72px;
        border-radius: 16px;
        transform: translateY(18px) scale(0.985);
    }

    .toast.show {
        transform: translateY(0) scale(1);
    }

    .toast.hide {
        transform: translateY(18px) scale(0.985);
    }

    .toast-icon {
        width: 36px;
        height: 36px;
        border-radius: 12px;
        font-size: 20px;
    }
}

/* Minimal password-rules badge style */
.password-rules {
    display: flex !important;
    flex-wrap: wrap;
    align-items: center;
    gap: 5px;
    margin: -8px 0 16px;
    padding: 0;
    min-height: 0;
    background: transparent !important;
    border: 0 !important;
    overflow: visible;
}

.password-rules .rule-pill,
.password-rules div {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    gap: 4px;
    width: auto;
    min-width: 0;
    height: 22px;
    min-height: 22px;
    padding: 0 7px;
    border-radius: 5px;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    background: #2b2d31 !important;
    color: #f2f4f7;
    font-size: 11px;
    line-height: 1;
    font-weight: 700;
    letter-spacing: -0.01em;
    white-space: nowrap;
    box-shadow:
            inset 0 1px 0 rgba(255, 255, 255, 0.06),
            0 1px 2px rgba(0, 0, 0, 0.18);
    transition:
            color 0.18s ease,
            background 0.18s ease,
            border-color 0.18s ease,
            opacity 0.18s ease;
}

.password-rules .rule-pill::before,
.password-rules .rule-pill::after,
.password-rules div::before,
.password-rules div::after {
    content: none !important;
}

.password-rules .rule-info {
    font-size: 13px;
    line-height: 1;
    color: #c8ced8;
    opacity: 0.9;
}

.password-rules .rule-pill.invalid,
.password-rules div.invalid {
    background: #2b2d31 !important;
    border-color: rgba(255, 255, 255, 0.08) !important;
    color: #f2f4f7;
    opacity: 0.72;
}

.password-rules .rule-pill.valid,
.password-rules div.valid {
    background: rgba(47, 214, 122, 0.14) !important;
    border-color: rgba(47, 214, 122, 0.34) !important;
    color: #dfffea;
    opacity: 1;
}

.password-rules .rule-pill.valid .rule-info {
    color: #dfffea;
}

@media (max-width: 420px) {
    .password-rules {
        gap: 4px;
        margin: -7px 0 14px;
    }

    .password-rules .rule-pill,
    .password-rules div {
        height: 21px;
        min-height: 21px;
        padding: 0 6px;
        font-size: 10.5px;
        border-radius: 5px;
    }
}

/* Light theme
   Synced with other pages via:
   <html data-theme="light">
*/
html[data-theme="light"] {
    --accent: #16b765;
    --accent-strong: #0d9f54;
    --accent-soft: rgba(22, 183, 101, 0.10);
    --accent-muted: rgba(22, 183, 101, 0.20);

    --bg-main: #f4f7fb;
    --bg-left: #f7fafc;
    --bg-right: #eef3f8;
    --bg-panel: rgba(255, 255, 255, 0.82);
    --bg-field: #f7fafc;
    --bg-field-hover: #ffffff;

    --border-soft: rgba(20, 31, 46, 0.10);
    --border-strong: rgba(20, 31, 46, 0.16);

    --text-main: #202121;
    --text-soft: #46566a;
    --text-muted: #687789;
    --text-faint: #8a96a8;
}

html[data-theme="light"] body {
    background: var(--bg-main);
}

html[data-theme="light"] .auth-page {
    background:
            radial-gradient(circle at 18% 14%, rgba(22, 183, 101, 0.095), transparent 24%),
            radial-gradient(circle at 90% 88%, rgba(22, 183, 101, 0.075), transparent 30%),
            linear-gradient(90deg, var(--bg-left) 0%, var(--bg-left) 45%, var(--bg-right) 45%, var(--bg-right) 100%);
}

html[data-theme="light"] .auth-page::before {
    opacity: 0.64;
    background-image:
            linear-gradient(rgba(20, 31, 46, 0.045) 1px, transparent 1px),
            linear-gradient(90deg, rgba(20, 31, 46, 0.045) 1px, transparent 1px);
}

html[data-theme="light"] .hero-image-place::before {
    background: rgba(22, 183, 101, 0.13);
}

html[data-theme="light"] .hero-image-place img {
    opacity: 0.98;
    filter: saturate(0.96) contrast(1.02);
}

html[data-theme="light"] .trust-card {
    background:
            linear-gradient(180deg, rgba(255,255,255,0.92), rgba(255,255,255,0.66)),
            rgba(255, 255, 255, 0.72);
    box-shadow:
            0 18px 48px rgba(15, 23, 36, 0.055),
            inset 0 1px 0 rgba(255,255,255,0.9);
}

html[data-theme="light"] .trust-card.is-primary {
    border-color: rgba(22, 183, 101, 0.24);
    background:
            linear-gradient(180deg, rgba(22, 183, 101, 0.10), rgba(255,255,255,0.74)),
            rgba(255, 255, 255, 0.84);
}

html[data-theme="light"] .trust-index {
    background: rgba(22, 183, 101, 0.08);
    border-color: rgba(22, 183, 101, 0.16);
}

html[data-theme="light"] .trust-card strong,
html[data-theme="light"] .captcha-text strong,
html[data-theme="light"] .toast-content strong {
    color: var(--text-main);
}

html[data-theme="light"] .auth-form {
    background:
            linear-gradient(180deg, rgba(255,255,255,0.96), rgba(255,255,255,0.78)),
            var(--bg-panel);
    box-shadow:
            0 32px 90px rgba(15, 23, 36, 0.10),
            inset 0 1px 0 rgba(255,255,255,0.95);
}



html[data-theme="light"] .field {
    border-color: rgba(20,31,46,0.10);
    background: var(--bg-field);
}

html[data-theme="light"] .field:hover,
html[data-theme="light"] .field:focus-within {
    background: var(--bg-field-hover);
    border-color: rgba(22, 183, 101, 0.42);
    box-shadow: 0 0 0 4px rgba(22, 183, 101, 0.08);
}

html[data-theme="light"] .field input {
    color: #152033;
}

html[data-theme="light"] .field input::placeholder {
    color: #8a96a8;
}

html[data-theme="light"] .toggle-password {
    color: #778397;
}

html[data-theme="light"] .toggle-password:hover {
    background: rgba(20,31,46,0.055);
    color: var(--text-main);
}

html[data-theme="light"] .password-rules .rule-pill,
html[data-theme="light"] .password-rules div {
    background: #eef2f7 !important;
    border-color: rgba(20, 31, 46, 0.10) !important;
    color: #344256;
    box-shadow:
            inset 0 1px 0 rgba(255, 255, 255, 0.95),
            0 1px 2px rgba(15, 23, 36, 0.04);
}

html[data-theme="light"] .password-rules .rule-info {
    color: #687789;
}

html[data-theme="light"] .password-rules .rule-pill.invalid,
html[data-theme="light"] .password-rules div.invalid {
    background: #eef2f7 !important;
    border-color: rgba(20, 31, 46, 0.10) !important;
    color: #445267;
    opacity: 0.78;
}

html[data-theme="light"] .password-rules .rule-pill.valid,
html[data-theme="light"] .password-rules div.valid {
    background: rgba(22, 183, 101, 0.12) !important;
    border-color: rgba(22, 183, 101, 0.30) !important;
    color: #0a7f42;
}

html[data-theme="light"] .password-rules .rule-pill.valid .rule-info {
    color: #0a7f42;
}

html[data-theme="light"] .optional-btn {
    background: rgba(20,31,46,0.025);
    color: var(--text-soft);
}

html[data-theme="light"] .optional-btn span,
html[data-theme="light"] .optional-btn i {
    color: var(--text-faint);
}

html[data-theme="light"] .optional-btn:hover {
    background: rgba(22, 183, 101, 0.055);
    border-color: rgba(22, 183, 101, 0.18);
}

html[data-theme="light"] .optional-btn[aria-expanded="true"] {
    background: rgba(22, 183, 101, 0.09);
    border-color: rgba(22, 183, 101, 0.22);
}

html[data-theme="light"] .fake-captcha,
html[data-theme="light"] .security-check {
    border-color: rgba(20,31,46,0.10);
    background:
            linear-gradient(135deg, rgba(255,255,255,0.92), rgba(255,255,255,0.70)),
            #f7fafc;
}

html[data-theme="light"] .fake-captcha:hover {
    border-color: rgba(22, 183, 101, 0.34);
    box-shadow: 0 0 0 4px rgba(22, 183, 101, 0.07);
}

html[data-theme="light"] .captcha-check {
    border-color: rgba(20,31,46,0.16);
    background: #ffffff;
}

html[data-theme="light"] .captcha-mark,
html[data-theme="light"] .check-row input:checked::after,
html[data-theme="light"] .submit-btn,
html[data-theme="light"] .submit-btn.active,
html[data-theme="light"] .submit-btn.is-loading {
    color: #03120a;
}

html[data-theme="light"] .captcha-brand {
    color: #8793a4;
}

html[data-theme="light"] .fake-captcha.is-verified {
    background:
            linear-gradient(135deg, rgba(22, 183, 101, 0.105), rgba(255,255,255,0.76)),
            #f7fafc;
}

html[data-theme="light"] .check-row {
    color: var(--text-soft);
}

html[data-theme="light"] .check-row input {
    border-color: rgba(20,31,46,0.16);
    background: #ffffff;
}

html[data-theme="light"] .check-row.muted {
    color: var(--text-muted);
}

html[data-theme="light"] .check-row.error {
    background: rgba(251, 113, 133, 0.075);
    color: #be123c;
}

html[data-theme="light"] .check-row.success {
    background: rgba(22, 183, 101, 0.07);
}

html[data-theme="light"] .submit-hint {
    color: #7b8797;
}

html[data-theme="light"] .submit-hint.ready {
    color: #0a7f42;
}

html[data-theme="light"] .submit-btn:disabled {
    color: rgba(70, 82, 96, 0.66);
    background: linear-gradient(180deg, rgba(224, 230, 238, 0.92), rgba(205, 214, 225, 0.92));
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.85);
}

html[data-theme="light"] .spinner,
html[data-theme="light"] .submit-btn .spinner {
    border-color: rgba(3, 18, 10, 0.20);
    border-top-color: #03120a;
}

html[data-theme="light"] .green-orb {
    background: radial-gradient(circle, rgba(22, 183, 101, 0.12), rgba(204, 239, 221, 0.42) 48%, transparent 72%);
}

html[data-theme="light"] .toast {
    border-color: rgba(20,31,46,0.10);
    background:
            linear-gradient(145deg, rgba(255,255,255,0.96), rgba(255,255,255,0.78)),
            rgba(255, 255, 255, 0.92);
    box-shadow:
            0 24px 70px rgba(15, 23, 36, 0.12),
            inset 0 1px 0 rgba(255,255,255,0.9);
}

html[data-theme="light"] .toast-content span {
    color: var(--text-muted);
}

html[data-theme="light"] .toast-icon {
    background: rgba(20,31,46,0.055);
    color: #5f6d80;
}

html[data-theme="light"] .toast-close {
    color: #7b8797;
}

html[data-theme="light"] .toast-close:hover {
    background: rgba(20,31,46,0.07);
    color: var(--text-main);
}

@media (max-width: 900px) {
    html[data-theme="light"] .auth-page {
        background:
                radial-gradient(circle at 50% -10%, rgba(22, 183, 101, 0.13), transparent 34%),
                var(--bg-right);
    }
}

