
/* 重置样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    min-height: 100vh;
    background-color: #fafafa;
    display: flex;
    flex-direction:column;
    justify-content: center;
    align-items: center;
    padding: 20px;
    color: #333;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* 简约背景 */
.minimal-bg {
    position: fixed;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    z-index: -1;
    background:
            linear-gradient(135deg, #f5f7fa 0%, #f0f2f5 100%);
}

/* 简约装饰线条 */
.line-decoration {
    position: fixed;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    pointer-events: none;
    z-index: -1;
    overflow: hidden;
}

.line {
    position: absolute;
    background: rgba(0, 0, 0, 0.03);
}

.line-1 {
    width: 1px;
    height: 100%;
    left: 20%;
}

.line-2 {
    width: 1px;
    height: 100%;
    right: 20%;
}

.line-3 {
    width: 100%;
    height: 1px;
    top: 30%;
}

.line-4 {
    width: 100%;
    height: 1px;
    bottom: 30%;
}

/* 主登录容器 */
.login-container {
    width: 100%;
    max-width: 420px;
    background: white;
    border-radius: 16px;
    padding: 48px 40px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.04);
    position: relative;
    z-index: 10;
}

/* 移除默认焦点样式，使用自定义 */
*:focus {
    outline: none;
}

/* 登录标题区域 */
.login-header {
    text-align: center;
    margin-bottom: 40px;
}

.logo {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 24px;
}

.logo-icon {
    width: 48px;
    height: 48px;
    background: #333;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    font-size: 20px;
    margin-right: 12px;
}

.logo-text {
    font-size: 24px;
    font-weight: 600;
    color: #333;
    letter-spacing: -0.5px;
}

.login-header h1 {
    font-size: 28px;
    font-weight: 500;
    color: #333;
    margin-bottom: 8px;
    letter-spacing: -0.3px;
}

.login-header p {
    font-size: 15px;
    color: #666;
    font-weight: 400;
}

/* 表单样式 */
.login-form {
    width: 100%;
}

.form-group {
    margin-bottom: 24px;
    position: relative;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-size: 14px;
    font-weight: 500;
    color: #555;
}

.input-container {
    position: relative;
}

.form-control {
    width: 100%;
    padding: 16px 20px;
    background: #f9f9f9;
    border: 1px solid #e1e1e1;
    border-radius: 10px;
    font-size: 16px;
    color: #333;
    transition: all 0.2s ease;
    font-family: 'Inter', sans-serif;
    font-weight: 400;
}

.form-control:hover {
    border-color: #ccc;
    background: #f5f5f5;
}

.form-control:focus {
    border-color: #333;
    background: white;
    box-shadow: 0 0 0 2px rgba(0, 0, 0, 0.05);
}

/* 密码显示/隐藏按钮 */
.password-toggle {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #999;
    cursor: pointer;
    font-size: 16px;
    padding: 4px;
    transition: color 0.2s;
}

.password-toggle:hover {
    color: #666;
}

/* 表单选项 */
.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 32px;
    font-size: 14px;
}

.remember-me {
    display: flex;
    align-items: center;
}

.remember-me input {
    margin-right: 8px;
    width: 16px;
    height: 16px;
    border: 1px solid #ddd;
    border-radius: 3px;
    appearance: none;
    -webkit-appearance: none;
    cursor: pointer;
    position: relative;
    transition: all 0.2s;
}

.remember-me input:checked {
    background: #333;
    border-color: #333;
}

.remember-me input:checked::after {
    content: '';
    position: absolute;
    left: 5px;
    top: 2px;
    width: 4px;
    height: 8px;
    border: solid white;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

.remember-me label {
    color: #666;
    cursor: pointer;
}

.forgot-password {
    color: #666;
    text-decoration: none;
    transition: color 0.2s;
}

.forgot-password:hover {
    color: #333;
}

/* 登录按钮 */
.login-button {
    width: 100%;
    padding: 16px;
    background: #333;
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    margin-bottom: 32px;
    font-family: 'Inter', sans-serif;
}

.login-button:hover {
    background: #444;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.login-button:active {
    transform: translateY(0);
}

.login-button:disabled {
    background: #ddd;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* 分割线 */
.divider {
    display: flex;
    align-items: center;
    margin: 32px 0;
    color: #999;
    font-size: 14px;
}

.divider::before, .divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: #eee;
}

.divider span {
    padding: 0 16px;
}

/* 社交登录 */
.social-login {
    display: flex;
    justify-content: center;
    gap: 16px;
    margin-bottom: 32px;
}

.social-button {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 1px solid #e1e1e1;
    background: white;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #666;
    font-size: 18px;
    cursor: pointer;
    transition: all 0.2s;
}

.social-button:hover {
    border-color: #ccc;
    background: #f9f9f9;
    transform: translateY(-2px);
}

/* 注册链接 */
.register-link {
    text-align: center;
    color: #666;
    font-size: 15px;
}

.register-link a {
    color: #333;
    text-decoration: none;
    font-weight: 500;
    margin-left: 4px;
    transition: color 0.2s;
}

.register-link a:hover {
    text-decoration: underline;
}

/* 错误提示 */
.error-message {
    color: #e74c3c;
    font-size: 13px;
    margin-top: 8px;
    display: none;
}

.error {
    border-color: #e74c3c !important;
}

.success {
    border-color: #2ecc71 !important;
}

/* 简约加载动画 */
.loading-dots {
    display: inline-block;
    position: relative;
    width: 20px;
    height: 20px;
}

.loading-dots div {
    position: absolute;
    top: 8px;
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: white;
    animation-timing-function: cubic-bezier(0, 1, 1, 0);
}

.loading-dots div:nth-child(1) {
    left: 4px;
    animation: loading-dots1 0.6s infinite;
}

.loading-dots div:nth-child(2) {
    left: 4px;
    animation: loading-dots2 0.6s infinite;
}

.loading-dots div:nth-child(3) {
    left: 12px;
    animation: loading-dots2 0.6s infinite;
}

.loading-dots div:nth-child(4) {
    left: 20px;
    animation: loading-dots3 0.6s infinite;
}

@keyframes loading-dots1 {
    0% {
        transform: scale(0);
    }
    100% {
        transform: scale(1);
    }
}

@keyframes loading-dots3 {
    0% {
        transform: scale(1);
    }
    100% {
        transform: scale(0);
    }
}

@keyframes loading-dots2 {
    0% {
        transform: translate(0, 0);
    }
    100% {
        transform: translate(8px, 0);
    }
}

/* 响应式设计 */
@media (max-width: 480px) {
    .login-container {
        padding: 40px 24px;
        max-width: 100%;
        border-radius: 12px;
    }

    .line-decoration {
        display: none;
    }

    .login-header h1 {
        font-size: 24px;
    }

    .logo-icon {
        width: 40px;
        height: 40px;
        font-size: 18px;
    }

    .logo-text {
        font-size: 20px;
    }
}

/* 暗色模式支持 */
@media (prefers-color-scheme: dark) {
    body {
        background-color: #121212;
        color: #e0e0e0;
    }

    .minimal-bg {
        background:
                linear-gradient(135deg, #1a1a1a 0%, #121212 100%);
    }

    .line {
        background: rgba(255, 255, 255, 0.05);
    }

    .login-container {
        background: #1e1e1e;
        box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
    }

    .logo-icon {
        background: #444;
    }

    .logo-text, .login-header h1 {
        color: #e0e0e0;
    }

    .login-header p {
        color: #aaa;
    }

    .form-group label {
        color: #bbb;
    }

    .form-control {
        background: #2a2a2a;
        border-color: #3a3a3a;
        color: #e0e0e0;
    }

    .form-control:hover {
        background: #333;
        border-color: #444;
    }

    .form-control:focus {
        border-color: #666;
        background: #2a2a2a;
        box-shadow: 0 0 0 2px rgba(100, 100, 100, 0.2);
    }

    .password-toggle {
        color: #777;
    }

    .password-toggle:hover {
        color: #aaa;
    }

    .remember-me label, .forgot-password, .register-link {
        color: #aaa;
    }

    .forgot-password:hover {
        color: #e0e0e0;
    }

    .login-button {
        background: #444;
    }

    .login-button:hover {
        background: #555;
    }

    .login-button:disabled {
        background: #333;
        color: #666;
    }

    .divider {
        color: #666;
    }

    .divider::before, .divider::after {
        background: #333;
    }

    .social-button {
        background: #2a2a2a;
        border-color: #3a3a3a;
        color: #aaa;
    }

    .social-button:hover {
        background: #333;
        border-color: #444;
    }

    .register-link a {
        color: #e0e0e0;
    }

    .error {
        border-color: #e74c3c !important;
    }

    .success {
        border-color: #2ecc71 !important;
    }
}

/* 简约动画效果 */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.login-container {
    animation: fadeIn 0.4s ease-out;
}

.form-group {
    animation: fadeIn 0.4s ease-out;
    animation-fill-mode: both;
}

.form-group:nth-child(1) {
    animation-delay: 0.1s;
}

.form-group:nth-child(2) {
    animation-delay: 0.2s;
}

.form-options {
    animation: fadeIn 0.4s ease-out 0.3s both;
}

.login-button {
    animation: fadeIn 0.4s ease-out 0.4s both;
}

.divider {
    animation: fadeIn 0.4s ease-out 0.5s both;
}

.social-login {
    animation: fadeIn 0.4s ease-out 0.6s both;
}

.register-link {
    animation: fadeIn 0.4s ease-out 0.7s both;
}
