/* 登录页面样式 */

.login-body {
    margin: 0;
    padding: 0;
    min-height: 100vh;
    background: var(--theme-bg-gradient);
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Microsoft YaHei', Arial, sans-serif;
    overflow: hidden;
}

.login-container {
    display: flex;
    width: 100%;
    max-width: 1200px;
    min-height: 600px;
    background: white;
    border-radius: 20px;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.2);
    overflow: hidden;
    animation: fadeIn 0.6s ease-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: scale(0.95);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

/* 左侧宣传区域 */
.promo-section {
    flex: 1.2;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.promo-content {
    position: relative;
    z-index: 10;
    text-align: center;
    color: white;
    padding: 40px;
}

.promo-logo {
    width: 120px;
    height: 120px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 30px;
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
        box-shadow: 0 0 0 0 rgba(255, 255, 255, 0.4);
    }
    50% {
        transform: scale(1.05);
        box-shadow: 0 0 0 20px rgba(255, 255, 255, 0);
    }
}

.promo-logo i {
    font-size: 60px;
    color: white;
}

.promo-title {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 10px;
    letter-spacing: 2px;
}

.promo-subtitle {
    font-size: 20px;
    font-weight: 300;
    margin-bottom: 15px;
    opacity: 0.95;
}

.promo-slogan {
    font-size: 18px;
    font-weight: 400;
    margin-bottom: 40px;
    opacity: 0.9;
    letter-spacing: 1px;
}

.promo-features {
    display: flex;
    justify-content: center;
    gap: 30px;
    flex-wrap: wrap;
}

.feature-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    opacity: 0.9;
}

.feature-item i {
    font-size: 28px;
    opacity: 0.9;
}

.feature-item span {
    font-size: 14px;
    font-weight: 500;
}

/* 装饰元素 */
.promo-decoration {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
}

.circle {
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
}

.circle-1 {
    width: 300px;
    height: 300px;
    top: -100px;
    left: -100px;
    animation: float 6s ease-in-out infinite;
}

.circle-2 {
    width: 200px;
    height: 200px;
    bottom: -50px;
    right: -50px;
    animation: float 8s ease-in-out infinite reverse;
}

.circle-3 {
    width: 150px;
    height: 150px;
    top: 50%;
    right: 20%;
    animation: float 7s ease-in-out infinite;
}

@keyframes float {
    0%, 100% {
        transform: translateY(0) rotate(0deg);
    }
    50% {
        transform: translateY(-30px) rotate(10deg);
    }
}

/* 右侧登录区域 */
.login-section {
    flex: 0.8;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 40px;
}

.login-card {
    width: 100%;
    max-width: 400px;
    background: white;
    animation: slideInRight 0.5s ease-out;
}

@keyframes slideInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.login-header {
    text-align: center;
    margin-bottom: 30px;
}

.login-header h1 {
    color: #333;
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 8px;
}

.login-header p {
    color: #666;
    font-size: 14px;
    margin: 0;
}

.login-form {
    margin-bottom: 20px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    color: #333;
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 8px;
}

.form-group input {
    width: 100%;
    padding: 14px 16px;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    font-size: 15px;
    transition: border-color 0.3s, box-shadow 0.3s;
    box-sizing: border-box;
}

.form-group input:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 4px rgba(102, 126, 234, 0.1);
}

.form-group input:invalid {
    border-color: #ff6b6b;
}

.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    font-size: 14px;
}

.checkbox-label {
    display: flex;
    align-items: center;
    cursor: pointer;
    color: #666;
}

.checkbox-label input {
    position: absolute;
    opacity: 0;
    cursor: pointer;
    height: 0;
    width: 0;
}

.checkmark {
    width: 18px;
    height: 18px;
    border: 2px solid #ddd;
    border-radius: 4px;
    margin-right: 8px;
    position: relative;
    transition: all 0.3s;
}

.checkbox-label input:checked + .checkmark {
    background-color: #667eea;
    border-color: #667eea;
}

.checkbox-label input:checked + .checkmark::after {
    content: '✓';
    color: white;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 12px;
}

.login-mode {
    display: flex;
    align-items: center;
}

.mode-toggle {
    color: #667eea;
    cursor: pointer;
    font-weight: 500;
    transition: color 0.3s;
}

.mode-toggle:hover {
    color: #5a6fd8;
    text-decoration: underline;
}

.login-btn {
    width: 100%;
    padding: 15px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    position: relative;
    overflow: hidden;
}

.login-btn:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(102, 126, 234, 0.4);
}

.login-btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

.loading-spinner {
    display: inline-block;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.error-message {
    background: #ffe6e6;
    color: #d63031;
    padding: 14px 16px;
    border-radius: 10px;
    margin-bottom: 20px;
    font-size: 14px;
    border-left: 4px solid #d63031;
}

.login-footer {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid #f0f0f0;
}

.login-footer p {
    color: #999;
    font-size: 12px;
    margin: 0;
}

/* 管理员模式样式 */
.admin-mode .form-group:first-child input {
    background-color: #f8f9fa;
    color: #666;
    cursor: not-allowed;
}

.admin-mode .login-btn {
    background: linear-gradient(135deg, #ff6b6b 0%, #ee5a52 100%);
}

.admin-mode .login-btn:hover:not(:disabled) {
    box-shadow: 0 10px 30px rgba(255, 107, 107, 0.4);
}

/* 响应式设计 */
@media (max-width: 900px) {
    .login-container {
        flex-direction: column;
        max-width: 100%;
        min-height: 100vh;
        border-radius: 0;
    }
    
    .promo-section {
        flex: none;
        min-height: 300px;
    }
    
    .promo-content {
        padding: 30px;
    }
    
    .promo-title {
        font-size: 26px;
    }
    
    .promo-subtitle {
        font-size: 18px;
    }
    
    .promo-slogan {
        font-size: 16px;
    }
    
    .login-section {
        flex: none;
        padding: 30px 20px;
    }
}

@media (max-width: 480px) {
    .promo-features {
        flex-direction: column;
        gap: 20px;
    }
    
    .form-options {
        flex-direction: column;
        gap: 15px;
        align-items: flex-start;
    }
    
    .login-mode {
        align-self: flex-end;
    }
}
