/* 登录页面样式 */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Microsoft YaHei', sans-serif;
    background: #f5f5f5;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.login-container {
    width: 100%;
    max-width: 400px;
}

.login-card {
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    padding: 40px 35px;
    border: 1px solid #e0e0e0;
}

.login-header {
    text-align: center;
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 2px solid #f0f0f0;
}

.logo-icon {
    width: 40px;
    height: 40px;
    color: #10b981;
    margin-bottom: 12px;
}

.login-header h1 {
    font-size: 22px;
    color: #212121;
    margin-bottom: 6px;
    font-weight: 600;
}

.subtitle {
    color: #757575;
    font-size: 14px;
}

.login-form {
    margin-bottom: 20px;
}

.form-group {
    margin-bottom: 18px;
}

.form-group label {
    display: block;
    margin-bottom: 6px;
    color: #424242;
    font-size: 14px;
    font-weight: 500;
}

.form-group input[type="text"],
.form-group input[type="password"] {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #d0d0d0;
    border-radius: 4px;
    font-size: 14px;
    transition: border-color 0.2s;
    background: white;
}

.form-group input:focus {
    outline: none;
    border-color: #10b981;
}

.captcha-group {
    display: flex;
    gap: 12px;
    align-items: flex-start;
}

.captcha-input-wrapper {
    flex: 1;
}

.captcha-input-wrapper input {
    text-transform: uppercase;
}

.captcha-image-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    margin-top: 26px;
}

.captcha-image {
    width: 120px;
    height: 40px;
    border: 1px solid #d0d0d0;
    border-radius: 4px;
    cursor: pointer;
    transition: opacity 0.2s;
    user-select: none;
}

.captcha-image:hover {
    opacity: 0.8;
}

.captcha-hint {
    font-size: 11px;
    color: #a0aec0;
    text-align: center;
    user-select: none;
}

.checkbox-group {
    margin-bottom: 20px;
}

.checkbox-label {
    display: flex;
    align-items: center;
    cursor: pointer;
    user-select: none;
}

.checkbox-label input[type="checkbox"] {
    width: 16px;
    height: 16px;
    margin-right: 8px;
    cursor: pointer;
    accent-color: #10b981;
}

.checkbox-label span {
    color: #616161;
    font-size: 13px;
}

.error-message {
    background: #fef2f2;
    color: #dc2626;
    padding: 10px 14px;
    border-radius: 4px;
    margin-bottom: 14px;
    font-size: 13px;
    border-left: 3px solid #dc2626;
}

.info-message {
    background: #eff6ff;
    color: #2563eb;
    padding: 10px 14px;
    border-radius: 4px;
    margin-bottom: 14px;
    font-size: 13px;
    border-left: 3px solid #2563eb;
}

.login-btn {
    width: 100%;
    padding: 12px;
    background: #10b981;
    color: white;
    border: none;
    border-radius: 4px;
    font-size: 15px;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.2s;
}

.login-btn:hover:not(:disabled) {
    background: #059669;
}

.login-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.btn-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.spinner {
    width: 20px;
    height: 20px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.login-footer {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid #e0e0e0;
}

.login-footer p {
    color: #9e9e9e;
    font-size: 12px;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .login-card {
        padding: 30px 24px;
    }

    .login-header h1 {
        font-size: 20px;
    }

    .captcha-group {
        flex-direction: column;
        align-items: stretch;
    }

    .captcha-image-wrapper {
        flex-direction: row;
        justify-content: space-between;
    }
}

@media (max-width: 480px) {
    body {
        padding: 10px;
    }

    .login-card {
        padding: 24px 20px;
    }

    .login-header h1 {
        font-size: 18px;
    }

    .logo-icon {
        width: 40px;
        height: 40px;
    }
}
