/**
 * 青绿平台 · 认证页（无卡片居中 + 标题右对齐动效）
 */
:root {
    --st-auth-accent: #24a66a;
    --st-auth-accent-h: #168855;
    --st-auth-accent-bg: #eefbf4;
    --st-auth-fg: #1a1a2e;
    --st-auth-fg2: #555770;
    --st-auth-fg3: #8b8da3;
    --st-auth-border: #d8e8df;
}

.st-auth-body {
    margin: 0;
    min-height: 100vh;
    font-family: 'Segoe UI', system-ui, sans-serif;
    color: var(--st-auth-fg);
    background: #f2f7f4;
}

@media (prefers-reduced-motion: reduce) {
    .st-auth *, .st-auth *::before, .st-auth *::after {
        animation-duration: 0.01ms !important;
        transition-duration: 0.01ms !important;
    }
}

/* v13.26.35：标题不再使用脉冲动画，keyframes 保留无引用亦可删 */
@keyframes stAuthTitlePulse {
    0%, 100% { opacity: 1; letter-spacing: 0.02em; }
    50% { opacity: 0.88; letter-spacing: 0.06em; }
}

@keyframes stAuthFadeIn {
    from { opacity: 0; transform: translateY(12px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes stAuthShake {
    0%, 100% { transform: translateX(0); }
    20%, 60% { transform: translateX(-5px); }
    40%, 80% { transform: translateX(5px); }
}

@keyframes stAuthSpin {
    to { transform: rotate(360deg); }
}

@keyframes stAuthOrb {
    0%, 100% { transform: translate(0, 0) scale(1); }
    50% { transform: translate(12px, -18px) scale(1.05); }
}

.st-auth {
    position: relative;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 32px 20px;
    box-sizing: border-box;
    overflow: hidden;
}

.st-auth__bg {
    position: absolute;
    inset: 0;
    background: linear-gradient(145deg, #e8f5ee 0%, #f5f8f6 45%, #dcefe4 100%);
    z-index: 0;
}

.st-auth__orb {
    position: absolute;
    border-radius: 50%;
    filter: blur(40px);
    animation: stAuthOrb 10s ease-in-out infinite;
}

.st-auth__orb--1 {
    width: 320px;
    height: 320px;
    top: -80px;
    right: -60px;
    background: rgba(36, 166, 106, 0.35);
}

.st-auth__orb--2 {
    width: 260px;
    height: 260px;
    bottom: -60px;
    left: -40px;
    background: rgba(72, 193, 134, 0.28);
    animation-delay: -4s;
}

.st-auth__center {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 400px;
    animation: stAuthFadeIn 0.5s ease both;
}

.st-auth__form {
    width: 100%;
}

.st-auth__form.is-shake {
    animation: stAuthShake 0.38s ease;
}

.st-auth__title {
    margin: 0 0 8px;
    text-align: right;
    font-size: clamp(26px, 6vw, 34px);
    font-weight: 800;
    color: var(--st-auth-accent-h);
    /* v13.26.35：标题静止，禁止呼吸/字距脉冲（难看） */
    animation: none;
    letter-spacing: 0.02em;
    line-height: 1.2;
}

.st-auth__sub {
    margin: 0 0 24px;
    text-align: right;
    font-size: 13px;
    color: var(--st-auth-fg3);
    line-height: 1.5;
}

.st-auth__field {
    margin-bottom: 16px;
}

.st-auth__field label {
    display: block;
    font-size: 13px;
    font-weight: 500;
    margin-bottom: 6px;
    color: var(--st-auth-fg2);
}

.st-auth__input {
    width: 100%;
    box-sizing: border-box;
    height: 46px;
    padding: 0 14px;
    border: none;
    border-bottom: 2px solid var(--st-auth-border);
    border-radius: 0;
    font-size: 15px;
    outline: none;
    background: transparent;
    color: var(--st-auth-fg);
    transition: border-color 0.25s, background 0.25s;
}

.st-auth__input::placeholder {
    color: var(--st-auth-fg3);
}

.st-auth__input:focus {
    border-bottom-color: var(--st-auth-accent);
    background: rgba(255, 255, 255, 0.45);
}

.st-auth__input:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.st-auth__group {
    display: flex;
    align-items: flex-end;
    gap: 10px;
}

.st-auth__group .st-auth__input {
    flex: 1;
    min-width: 0;
}

.st-auth__code-btn {
    flex-shrink: 0;
    height: 46px;
    min-width: 100px;
    max-width: 112px;
    padding: 0 10px;
    border: 0;
    border-bottom: 2px solid var(--st-auth-accent);
    border-radius: 0;
    background: transparent;
    color: var(--st-auth-accent);
    font-size: 12px;
    font-weight: 700;
    white-space: nowrap;
    cursor: pointer;
    transition: color 0.15s, border-color 0.15s, background 0.15s;
}

.st-auth__code-btn:hover:not(:disabled) {
    color: var(--st-auth-accent-h);
    background: rgba(36, 166, 106, 0.08);
}

.st-auth__code-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.st-auth__pw-wrap {
    position: relative;
}

.st-auth__pw-wrap .st-auth__input {
    padding-right: 48px;
}

.st-auth__pw-toggle {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    z-index: 2;
    border: 0;
    background: transparent;
    color: var(--st-auth-fg3);
    cursor: pointer;
    padding: 4px;
    line-height: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.st-auth__pw-toggle:hover {
    color: var(--st-auth-accent);
}

.st-auth__pw-toggle svg {
    width: 20px;
    height: 20px;
    pointer-events: none;
    display: block;
}

.st-auth__row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 8px;
    margin: 6px 0 20px;
    font-size: 13px;
    color: var(--st-auth-fg2);
    min-width: 0;
    position: relative;
    z-index: 2;
}

.st-auth__row label {
    min-width: 0;
}

.st-auth__row a {
    color: var(--st-auth-accent);
    text-decoration: none;
    font-weight: 500;
    white-space: nowrap;
    flex-shrink: 0;
}

.st-auth__row a:hover {
    text-decoration: underline;
}

.st-auth__submit {
    position: relative;
    width: 100%;
    height: 48px;
    border: 0;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--st-auth-accent) 0%, var(--st-auth-accent-h) 100%);
    color: #fff;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    overflow: hidden;
    transition: transform 0.15s, box-shadow 0.2s;
    box-shadow: 0 4px 16px rgba(36, 166, 106, 0.3);
}

.st-auth__submit:hover:not(:disabled) {
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(36, 166, 106, 0.38);
}

.st-auth__submit:active:not(:disabled) {
    transform: translateY(0);
}

.st-auth__submit:disabled,
.st-auth__submit.is-loading {
    opacity: 0.7;
    cursor: not-allowed;
}

.st-auth__submit.is-loading {
    color: transparent;
}

.st-auth__submit.is-loading::before {
    content: '';
    position: absolute;
    width: 18px;
    height: 18px;
    top: 50%;
    left: 50%;
    margin: -9px 0 0 -9px;
    border: 2px solid rgba(255,255,255,0.35);
    border-top-color: #fff;
    border-radius: 50%;
    animation: stAuthSpin 0.7s linear infinite;
}

.st-auth__msg {
    padding: 10px 12px;
    border-radius: 8px;
    font-size: 13px;
    margin-bottom: 14px;
    line-height: 1.5;
}

.st-auth__msg--error {
    background: rgba(254, 242, 242, 0.9);
    color: #b91c1c;
}

.st-auth__msg--success {
    background: rgba(238, 251, 244, 0.95);
    color: var(--st-auth-accent-h);
}

.st-auth__msg--info {
    background: rgba(240, 249, 255, 0.95);
    color: #0369a1;
}

.st-auth__msg--info a {
    color: var(--st-auth-accent);
}

.st-auth__oauth {
    margin-top: 22px;
    padding-top: 18px;
    border-top: 1px solid var(--st-auth-border);
    text-align: center;
}

.st-auth__oauth-label {
    font-size: 12px;
    color: var(--st-auth-fg3);
    margin-bottom: 12px;
}

.st-auth__oauth-icons {
    display: flex;
    justify-content: center;
    gap: 14px;
}

.st-auth__oauth-icons a {
    display: inline-flex;
    width: 42px;
    height: 42px;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.6);
    transition: transform 0.15s, box-shadow 0.15s;
}

.st-auth__oauth-icons a:hover {
    transform: scale(1.08);
    box-shadow: 0 4px 12px rgba(36, 166, 106, 0.15);
}

.st-auth__foot {
    margin-top: 20px;
    text-align: center;
    font-size: 13px;
    color: var(--st-auth-fg3);
}

.st-auth__foot a {
    color: var(--st-auth-accent);
    font-weight: 600;
    text-decoration: none;
}

@media (min-width: 901px) {
    .st-auth__center {
        max-width: 420px;
    }
}

@media (max-width: 380px) {
    .st-auth__code-btn {
        min-width: 88px;
        font-size: 11px;
    }
}

.st-auth__label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: var(--st-auth-fg2);
    margin-bottom: 8px;
}

.st-auth__field--role-segment {
    margin-bottom: 2px;
}

.st-role-segment {
    width: 100%;
}

.st-role-segment__track {
    position: relative;
    display: grid;
    grid-template-columns: 1fr 1fr;
    width: 100%;
    height: 44px;
    padding: 3px;
    border: 1px solid var(--st-auth-border);
    border-radius: 12px;
    background: rgba(15, 23, 42, 0.04);
}

.st-role-segment__thumb {
    position: absolute;
    top: 3px;
    bottom: 3px;
    left: 3px;
    width: calc(50% - 3px);
    border-radius: 9px;
    background: rgba(255, 255, 255, 0.92);
    box-shadow: 0 1px 3px rgba(15, 23, 42, 0.1), 0 0 0 1px rgba(15, 23, 42, 0.05);
    transition: left 0.28s cubic-bezier(0.4, 0, 0.2, 1);
    pointer-events: none;
}

.st-role-segment__track[data-role="developer"] .st-role-segment__thumb {
    left: calc(50%);
}

.st-role-segment__btn {
    position: relative;
    z-index: 1;
    border: none;
    background: transparent;
    font-size: 14px;
    font-weight: 600;
    color: var(--st-auth-fg3);
    cursor: pointer;
    transition: color 0.2s ease;
    border-radius: 9px;
}

.st-role-segment__btn.is-active {
    color: var(--st-auth-fg);
}

.st-role-segment__btn:focus-visible {
    outline: 2px solid var(--st-auth-accent);
    outline-offset: 2px;
}

.st-role-segment__btn:disabled {
    cursor: not-allowed;
    opacity: 0.55;
}
