:root {
    color-scheme: light;
    --ink: #132238;
    --muted: #6b7a90;
    --line: #dce5ef;
    --brand: #126c8f;
    --brand-deep: #0b4f6c;
    --danger: #c93636;
    --paper: #ffffff;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    min-height: 100vh;
    font-family: "Microsoft YaHei", "PingFang SC", Arial, sans-serif;
    color: var(--ink);
    background:
        radial-gradient(circle at 15% 15%, rgba(52, 160, 190, 0.18), transparent 34%),
        radial-gradient(circle at 85% 82%, rgba(47, 110, 161, 0.14), transparent 32%),
        linear-gradient(145deg, #edf6fa 0%, #f7fafc 48%, #edf2f7 100%);
}

.login-shell {
    min-height: 100vh;
    display: grid;
    place-items: center;
    padding: 32px 20px;
}

.login-card {
    width: min(100%, 430px);
    padding: 38px 40px 28px;
    border: 1px solid rgba(255, 255, 255, 0.75);
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.94);
    box-shadow: 0 24px 70px rgba(25, 56, 82, 0.18);
    backdrop-filter: blur(10px);
}

.login-header {
    text-align: center;
    margin-bottom: 30px;
}

.login-kicker {
    color: var(--brand);
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.12em;
}

.login-header h1 {
    margin: 12px 0 8px;
    font-size: 30px;
    letter-spacing: 0.04em;
}

.login-header p {
    margin: 0;
    color: var(--muted);
    font-size: 14px;
    line-height: 1.7;
}

.login-form {
    display: grid;
    gap: 18px;
}

.login-field {
    display: grid;
    gap: 8px;
    color: #31435a;
    font-size: 14px;
    font-weight: 700;
}

.login-field input {
    width: 100%;
    height: 48px;
    padding: 0 14px;
    border: 1px solid var(--line);
    border-radius: 10px;
    background: #fbfdff;
    color: var(--ink);
    font: inherit;
    outline: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.login-field input:focus {
    border-color: #3a94b5;
    background: #ffffff;
    box-shadow: 0 0 0 4px rgba(18, 108, 143, 0.12);
}

.login-error {
    min-height: 20px;
    margin: -4px 0 0;
    color: var(--danger);
    font-size: 13px;
    line-height: 1.5;
}

.login-button {
    height: 50px;
    border: 0;
    border-radius: 10px;
    background: linear-gradient(135deg, var(--brand), var(--brand-deep));
    color: #ffffff;
    font: inherit;
    font-size: 16px;
    font-weight: 700;
    letter-spacing: 0.08em;
    cursor: pointer;
    box-shadow: 0 10px 24px rgba(18, 108, 143, 0.24);
    transition: transform 0.18s ease, box-shadow 0.18s ease, opacity 0.18s ease;
}

.login-button:hover:not(:disabled) {
    transform: translateY(-1px);
    box-shadow: 0 14px 28px rgba(18, 108, 143, 0.3);
}

.login-button:disabled {
    cursor: wait;
    opacity: 0.68;
}

.login-footer {
    margin-top: 24px;
    padding-top: 17px;
    border-top: 1px solid #edf2f6;
    color: #8996a7;
    text-align: center;
    font-size: 12px;
    line-height: 1.6;
}

.register-switch { margin-top: 18px; text-align: center; }
.register-switch button { padding: 4px 8px; border: 0; background: transparent; color: #1d61c2; font: inherit; font-size: 14px; cursor: pointer; }
.register-switch button:hover { text-decoration: underline; }
.register-form { margin-top: 18px; }
.login-form[hidden] { display: none !important; }

@media (max-width: 520px) {
    .login-card {
        padding: 30px 24px 24px;
        border-radius: 16px;
    }

    .login-header h1 {
        font-size: 26px;
    }
}
