/* 全局样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Microsoft YaHei', sans-serif;
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    background-image: url('/static/background-pattern.svg');
    background-size: 200px;
    color: #333;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* 登录容器 */
.login-container {
    width: 100%;
    max-width: 420px;
    padding: 20px;
    margin: 0 auto;
}

/* 登录卡片 */
.login-card {
    background-color: white;
    border-radius: 16px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    padding: 40px 30px;
    position: relative;
    overflow: hidden;
    animation: fadeInUp 0.5s ease;
}

/* Logo容器 */
.logo-container {
    text-align: center;
    margin-bottom: 20px;
}

.logo {
    width: 80px;
    height: 80px;
    transition: transform 0.3s ease;
}

.logo:hover {
    transform: scale(1.05);
}

/* 标题样式 */
h1 {
    color: #2c3e50;
    text-align: center;
    font-size: 24px;
    margin-bottom: 10px;
    font-weight: 600;
}

.subtitle {
    color: #7f8c8d;
    text-align: center;
    font-size: 14px;
    margin-bottom: 30px;
}

/* 表单样式 */
#loginForm {
    margin-bottom: 20px;
}

.input-group {
    position: relative;
    margin-bottom: 20px;
}

.input-icon-wrapper {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: #3498db;
    width: 20px;
    text-align: center;
}

input {
    width: 100%;
    padding: 15px 15px 15px 45px;
    border: 1px solid #e0e0e0;
    border-radius: 30px;
    font-size: 15px;
    transition: all 0.3s ease;
    background-color: #f9f9f9;
}

input:focus {
    outline: none;
    border-color: #3498db;
    background-color: #fff;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

input::placeholder {
    color: #aaa;
}

/* 登录按钮 */
.login-btn {
    width: 100%;
    padding: 15px;
    background-color: #3498db;
    color: white;
    border: none;
    border-radius: 30px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 10px;
    box-shadow: 0 4px 6px rgba(52, 152, 219, 0.2);
}

.login-btn:hover {
    background-color: #2980b9;
    transform: translateY(-2px);
    box-shadow: 0 6px 8px rgba(52, 152, 219, 0.3);
}

.login-btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 4px rgba(52, 152, 219, 0.2);
}

/* 状态消息 */
.status-message {
    margin-top: 20px;
    padding: 12px 15px;
    border-radius: 8px;
    font-size: 14px;
    display: none;
    animation: fadeIn 0.3s ease;
    text-align: center;
}

.success {
    background-color: #d4edda;
    color: #155724;
    border-left: 4px solid #28a745;
}

.error {
    background-color: #f8d7da;
    color: #721c24;
    border-left: 4px solid #dc3545;
}

/* 加载动画 */
.loading-overlay {
    display: none;
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(255, 255, 255, 0.95);
    justify-content: center;
    align-items: center;
    flex-direction: column;
    z-index: 10;
    border-radius: 16px;
}

.loading-overlay.active {
    display: flex;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid rgba(52, 152, 219, 0.1);
    border-radius: 50%;
    border-left-color: #3498db;
    animation: spin 1s linear infinite;
    margin-bottom: 15px;
}

/* 页脚 */
.footer {
    text-align: center;
    margin-top: 30px;
    font-size: 12px;
    color: #95a5a6;
}

/* 动画 */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

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

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* 响应式设计 */
@media (max-width: 480px) {
    .login-container {
        padding: 10px;
    }
    
    .login-card {
        padding: 30px 20px;
    }
    
    .logo {
        width: 70px;
        height: 70px;
    }
    
    h1 {
        font-size: 22px;
    }
    
    input {
        padding: 12px 12px 12px 40px;
        font-size: 14px;
    }
    
    .login-btn {
        padding: 12px;
        font-size: 15px;
    }
}