* {
    box-sizing: border-box;
}

html,
body {
    min-height: 100%;
}

.auth-body {
    margin: 0;
    color: var(--auth-text);
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    background: var(--auth-bg);
}

.auth-page {
    min-height: 100vh;
    width: 100%;
    padding: 22px;
    display: grid;
    place-items: center;
    position: relative;
    overflow-x: hidden;
}

.auth-page::before {
    content: "";
    position: fixed;
    inset: 0;
    background:
        radial-gradient(circle at 12% 12%, color-mix(in srgb, var(--auth-primary) 22%, transparent), transparent 30%),
        radial-gradient(circle at 88% 88%, color-mix(in srgb, var(--auth-accent) 22%, transparent), transparent 32%),
        linear-gradient(135deg, #ffffff, var(--auth-bg));
    z-index: 0;
}

.auth-page::after {
    content: "";
    position: fixed;
    inset: 0;
    background-image:
        linear-gradient(rgba(15, 23, 42, .045) 1px, transparent 1px),
        linear-gradient(90deg, rgba(15, 23, 42, .045) 1px, transparent 1px);
    background-size: 38px 38px;
    mask-image: linear-gradient(to bottom, rgba(0, 0, 0, .50), transparent 86%);
    z-index: 0;
}

.auth-single {
    position: relative;
    z-index: 1;
    width: min(100%, 520px);
}

.auth-login-single {
    width: min(100%, 500px);
}

.auth-card {
    width: 100%;
    border: 1px solid var(--auth-line);
    background: var(--auth-card);
    backdrop-filter: blur(22px);
    box-shadow: var(--auth-shadow);
    border-radius: 30px;
    padding: 28px;
}

.auth-login-card {
    padding-top: 26px;
}

.auth-brand-mark {
    width: 58px;
    height: 58px;
    display: grid;
    place-items: center;
    margin: 0 auto 14px;
    border-radius: 22px;
    color: #fff;
    font-size: 25px;
    background: linear-gradient(135deg, var(--auth-primary), var(--auth-secondary));
    box-shadow: 0 18px 36px color-mix(in srgb, var(--auth-primary) 28%, transparent);
}

.auth-brand-mark-gold {
    background: linear-gradient(135deg, var(--auth-accent), var(--auth-primary));
}

.auth-card-header {
    text-align: center;
}

.auth-card-header span {
    display: inline-flex;
    gap: 8px;
    align-items: center;
    padding: 7px 12px;
    border-radius: 999px;
    background: var(--auth-soft);
    color: var(--auth-secondary);
    font-weight: 950;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: .08em;
}

.auth-card-header h1 {
    margin: 12px 0 0;
    font-size: clamp(25px, 4vw, 34px);
    line-height: 1.08;
    font-weight: 950;
    letter-spacing: -.04em;
}

.auth-card-header p {
    margin: 7px 0 0;
    color: var(--auth-muted);
    line-height: 1.55;
}

.auth-form {
    margin-top: 22px;
    display: grid;
    gap: 14px;
}

.auth-form-compact {
    gap: 13px;
}

.auth-grid-login {
    display: grid;
    gap: 12px;
}

.auth-field {
    min-width: 0;
}

.auth-control {
    position: relative;
    width: 100%;
}

.auth-control>i {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--auth-primary);
    font-size: 16px;
    pointer-events: none;
}

.auth-control input,
.auth-control select,
.auth-control textarea {
    width: 100%;
    min-height: 48px;
    border: 1px solid var(--auth-line);
    border-radius: 16px;
    background: rgba(255, 255, 255, .86);
    color: var(--auth-text);
    outline: none;
    padding: 0 16px 0 44px;
    font-size: 14px;
    transition: .18s ease;
    box-shadow: 0 8px 22px rgba(15, 23, 42, .04);
}

.auth-control.no-icon input,
.auth-control.no-icon select,
.auth-control.no-icon textarea {
    padding-left: 15px;
}

.auth-control-password input {
    padding-right: 54px;
}

.auth-control textarea {
    padding-top: 13px;
    padding-bottom: 10px;
    resize: vertical;
}

.auth-control input:focus,
.auth-control select:focus,
.auth-control textarea:focus {
    border-color: color-mix(in srgb, var(--auth-primary) 72%, white);
    box-shadow: 0 0 0 4px color-mix(in srgb, var(--auth-primary) 15%, transparent);
    background: #fff;
}

.auth-control input::placeholder,
.auth-control textarea::placeholder {
    color: #94a3b8;
}

.auth-control select option {
    color: #0f172a;
}

.auth-help {
    display: block;
    margin-top: 6px;
    color: var(--auth-muted);
    font-size: 11px;
}

.auth-eye {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    width: 38px;
    height: 38px;
    display: grid;
    place-items: center;
    border: 0;
    border-radius: 13px;
    background: transparent;
    color: var(--auth-muted);
    font-size: 17px;
    cursor: pointer;
}

.auth-eye:hover {
    color: var(--auth-primary);
    background: var(--auth-soft);
}

.auth-submit,
.auth-mini-btn {
    border: 0;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 9px;
    font-weight: 950;
    transition: .18s ease;
}

.auth-submit {
    width: 100%;
    min-height: 50px;
    border-radius: 16px;
    color: #fff;
    font-size: 14px;
    background: linear-gradient(135deg, var(--auth-primary), var(--auth-secondary));
    box-shadow: 0 16px 32px color-mix(in srgb, var(--auth-primary) 25%, transparent);
}

.auth-submit:hover,
.auth-mini-btn:hover {
    transform: translateY(-1px);
}

.auth-submit:disabled,
.auth-mini-btn:disabled {
    opacity: .65;
    cursor: not-allowed;
    transform: none;
}

.auth-note {
    margin-top: 14px;
    border: 1px solid color-mix(in srgb, var(--auth-accent) 28%, transparent);
    background: color-mix(in srgb, var(--auth-accent) 10%, white);
    border-radius: 16px;
    padding: 12px 14px;
    color: var(--auth-dark);
    font-size: 12px;
    text-align: center;
}

.auth-switch {
    text-align: center;
    color: var(--auth-muted);
    margin: 16px 0 0;
    font-size: 14px;
}

.auth-switch a {
    color: var(--auth-primary);
    font-weight: 950;
    text-decoration: none;
}

.auth-switch a:hover {
    text-decoration: underline;
}

.auth-hidden {
    display: none !important;
}

.is-loading {
    position: relative;
    pointer-events: none;
}

.auth-error-list {
    text-align: left;
    margin: 0;
    padding-left: 18px;
}

.auth-error-list li {
    margin: 5px 0;
}

.auth-result p {
    margin: 0 0 8px;
    color: #64748b;
}

.auth-result strong {
    font-size: 20px;
    color: var(--auth-primary);
}

@media (max-width: 640px) {
    .auth-page {
        padding: 14px;
        align-items: start;
        padding-top: 22px;
    }

    .auth-card {
        padding: 22px 16px;
        border-radius: 24px;
    }

    .auth-brand-mark {
        width: 52px;
        height: 52px;
        border-radius: 19px;
        font-size: 23px;
    }

    .auth-theme-picker {
        width: 100%;
        justify-content: center;
    }

    .auth-theme-picker button {
        flex: 1;
    }
}

.auth-captcha-mini{display:grid;grid-template-columns:1fr 46px;gap:8px;margin-bottom:8px}.auth-captcha-mini .auth-captcha-question{min-height:44px}.auth-refresh-btn.mini{min-height:44px;padding:0}.auth-otp-box{text-align:center;border:1px solid color-mix(in srgb,var(--auth-primary) 22%,transparent);border-radius:18px;background:linear-gradient(135deg,color-mix(in srgb,var(--auth-primary) 8%,white),rgba(255,255,255,.82));padding:16px 14px;margin-bottom:12px}.auth-otp-icon{width:48px;height:48px;border-radius:18px;margin:0 auto 8px;display:grid;place-items:center;background:#fff;color:var(--auth-primary);box-shadow:0 12px 24px rgba(15,23,42,.08);font-size:22px}.auth-otp-box h2{font-size:20px;line-height:1.1;margin:0 0 6px;color:var(--auth-dark);font-weight:950}.auth-otp-box p{margin:0;color:var(--auth-muted);font-size:13px}.auth-link-btn{border:0;background:transparent;color:var(--auth-primary);font-weight:900;cursor:pointer;margin:8px auto 0;display:inline-flex;align-items:center;gap:7px}.auth-login-step{display:grid;gap:12px}
