/* 简化登录页面样式 */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

#app {
    width: 100%;
    max-width: 400px;
}

.login-container {
    background: white;
    border-radius: 20px;
    padding: 40px 30px;
    text-align: center;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: slideUp 0.4s ease-out;
}

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

/* 网盘图标 */
.driver-logo {
    width: 80px;
    height: 80px;
    margin: 0 auto 20px;
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f0f0f0;
}

.driver-logo img {
    width: 50px;
    height: 50px;
    object-fit: contain;
}

/* 标题 */
h2 {
    color: #333;
    font-size: 24px;
    font-weight: 600;
    margin-bottom: 8px;
}

.login-hint {
    color: #888;
    font-size: 14px;
    margin-bottom: 30px;
}

/* 二维码容器 */
.qr-container {
    width: 220px;
    height: 220px;
    margin: 0 auto 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fafafa;
    border-radius: 16px;
    border: 2px dashed #e0e0e0;
}

.qr-code {
    width: 200px;
    height: 200px;
    border-radius: 8px;
}

/* 跳转登录容器 */
.redirect-container {
    width: 120px;
    height: 120px;
    margin: 30px auto;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* 状态文本 */
.status-text {
    font-size: 14px;
    margin-bottom: 30px;
    min-height: 20px;
    transition: color 0.3s;
}

.status-waiting {
    color: #666;
}

.status-scaned {
    color: #2196F3;
    font-weight: 500;
}

.status-success {
    color: #4CAF50;
    font-weight: 500;
}

.status-error {
    color: #f44336;
}

/* 按钮组 */
.button-group {
    display: flex;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
}

.btn {
    padding: 12px 28px;
    border-radius: 10px;
    font-size: 15px;
    font-weight: 500;
    cursor: pointer;
    border: none;
    transition: all 0.2s ease;
    min-width: 100px;
}

.btn:active {
    transform: scale(0.98);
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
}

.btn-primary:hover {
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.5);
}

.btn-outline {
    background: transparent;
    border: 2px solid #e0e0e0;
    color: #666;
}

.btn-outline:hover {
    background: #f5f5f5;
    border-color: #ccc;
}

/* 加载动画 */
.loading-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid #f0f0f0;
    border-top: 3px solid #667eea;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

.loading-spinner.large {
    width: 60px;
    height: 60px;
    border-width: 4px;
    margin: 20px auto;
}

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

/* 成功/错误图标 */
.success-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 20px;
    background: linear-gradient(135deg, #4CAF50 0%, #45a049 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 40px;
    color: white;
    box-shadow: 0 4px 20px rgba(76, 175, 80, 0.4);
}

.error-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 20px;
    background: linear-gradient(135deg, #f44336 0%, #d32f2f 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 40px;
    color: white;
    box-shadow: 0 4px 20px rgba(244, 67, 54, 0.4);
}

/* 响应式 */
@media (max-width: 480px) {
    .login-container {
        padding: 30px 20px;
    }

    .qr-container {
        width: 200px;
        height: 200px;
    }

    .qr-code {
        width: 180px;
        height: 180px;
    }

    h2 {
        font-size: 20px;
    }

    .btn {
        padding: 10px 20px;
        font-size: 14px;
    }
}

/* 深色模式支持 */
@media (prefers-color-scheme: dark) {
    body {
        background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    }

    .login-container {
        background: #1e1e2e;
        box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    }

    h2 {
        color: #fff;
    }

    .login-hint {
        color: #aaa;
    }

    .qr-container {
        background: #2a2a3e;
        border-color: #3a3a4e;
    }

    .status-waiting {
        color: #aaa;
    }

    .btn-outline {
        border-color: #3a3a4e;
        color: #aaa;
    }

    .btn-outline:hover {
        background: #2a2a3e;
        border-color: #4a4a5e;
    }
}
