:root {
    --primary: #6366f1; --primary-dark: #4f46e5; --success: #10b981;
    --warning: #f59e0b; --danger: #ef4444; --gray-50: #f9fafb;
    --gray-100: #f3f4f6; --gray-200: #e5e7eb; --gray-300: #d1d5db;
    --gray-600: #4b5563; --gray-700: #374151; --gray-800: #1f2937; --gray-900: #111827;
}

* { box-sizing: border-box; }

body {
    background: #f8f9fa;
    min-height: 100vh;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    margin: 0;
    padding: 0;
}

/* 侧边栏导航 */
.nav-pills .nav-link {
    color: var(--gray-700);
    border-radius: 8px;
    padding: 12px 16px;
    margin-bottom: 4px;
    transition: all 0.2s;
    font-weight: 500;
}

.nav-pills .nav-link:hover {
    background: var(--gray-200);
}

.nav-pills .nav-link.active {
    background: var(--primary);
    color: white;
}

.nav-pills .nav-link:focus-visible {
    outline: 3px solid rgba(99, 102, 241, 0.3);
    outline-offset: 2px;
}

/* 内容区域 */
.content-section {
    display: none;
}

.content-section.active {
    display: block;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* 卡片样式 */
.card {
    transition: all 0.2s;
}

.card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1) !important;
}

/* 表单控件 */
.form-control, .form-select {
    border-radius: 8px;
    border: 2px solid var(--gray-200);
    padding: 10px 14px;
    transition: all 0.2s;
}

.form-control:focus, .form-select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
    outline: none;
}

/* 按钮 */
.btn {
    border-radius: 8px;
    padding: 10px 20px;
    font-weight: 500;
    transition: all 0.2s;
}

.btn:focus-visible {
    outline: 3px solid rgba(99, 102, 241, 0.3);
    outline-offset: 2px;
}

.btn-primary {
    background: var(--primary);
    border-color: var(--primary);
}

.btn-primary:hover {
    background: var(--primary-dark);
    border-color: var(--primary-dark);
    transform: translateY(-1px);
}

/* Toast */
.toast {
    background: white;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    border-radius: 8px;
}

/* 模态框 */
.modal-content {
    border-radius: 16px;
    border: none;
}

.modal-header {
    border-bottom: 1px solid var(--gray-200);
    padding: 20px 24px;
}

.modal-body {
    padding: 24px;
}

.modal-footer {
    border-top: 1px solid var(--gray-200);
    padding: 16px 24px;
}

/* 响应式 */
@media (max-width: 768px) {
    .navbar-brand {
        font-size: 1.2rem !important;
    }
}
.wizard-container {
    max-width: 800px; margin: 0 auto; background: white;
    border-radius: 24px; box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25); overflow: hidden;
}
.wizard-header {
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    color: white; padding: 30px 40px; text-align: center;
}
.wizard-header h1 { font-size: 2rem; font-weight: 700; margin: 0 0 10px; }
.wizard-header p { opacity: 0.9; margin: 0; }
.steps-indicator {
    display: flex; justify-content: center; padding: 30px 40px;
    background: var(--gray-50); border-bottom: 1px solid var(--gray-200);
}
.step-item { display: flex; align-items: center; position: relative; }
.step-circle {
    width: 40px; height: 40px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-weight: 600; font-size: 1rem;
    background: var(--gray-200); color: var(--gray-600); transition: all 0.3s;
}
.step-item.active .step-circle {
    background: var(--primary); color: white; box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.2);
}
.step-item.completed .step-circle { background: var(--success); color: white; }
.step-label { margin-left: 10px; font-size: 0.875rem; font-weight: 500; color: var(--gray-600); }
.step-item.active .step-label { color: var(--primary); font-weight: 600; }
.step-item.completed .step-label { color: var(--success); }
.step-connector { width: 60px; height: 2px; background: var(--gray-300); margin: 0 15px; }
.step-item.completed + .step-connector { background: var(--success); }
.wizard-body { padding: 40px; min-height: 350px; }
.step-content { display: none; animation: fadeIn 0.3s ease; }
.step-content.active { display: block; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }
.step-title { font-size: 1.5rem; font-weight: 700; color: var(--gray-900); margin-bottom: 10px; }
.step-description { color: var(--gray-600); margin-bottom: 30px; }
.form-section { background: var(--gray-50); border-radius: 16px; padding: 24px; margin-bottom: 20px; }
.form-section-title {
    font-size: 1.1rem; font-weight: 600; color: var(--gray-800);
    margin-bottom: 20px; display: flex; align-items: center; gap: 10px;
}
.form-section-title i { color: var(--primary); }
.form-control, .form-select {
    border-radius: 12px; border: 2px solid var(--gray-200);
    padding: 12px 16px; font-size: 0.95rem; transition: all 0.2s;
}
.form-control:focus, .form-select:focus {
    border-color: var(--primary); box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.1); outline: none;
}
.form-control:focus-visible, .form-select:focus-visible {
    outline: 3px solid rgba(99, 102, 241, 0.3); outline-offset: 2px;
}
.form-label { font-weight: 500; color: var(--gray-700); margin-bottom: 8px; }
.form-text { color: var(--gray-600); font-size: 0.85rem; }

/* 配置向导样式 */
.wizard-step {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--gray-600);
    transition: all 0.3s;
}

.wizard-step.active {
    color: var(--primary);
    font-weight: 600;
}

.wizard-step.completed {
    color: var(--success);
}

.account-item {
    background: white;
    border: 2px solid var(--gray-200);
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 16px;
    transition: all 0.2s;
}

.account-item:hover {
    border-color: var(--primary);
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.1);
    transform: translateY(-2px);
}

.model-card {
    background: white;
    border: 2px solid var(--gray-200);
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 12px;
    cursor: pointer;
    transition: all 0.2s;
}

.model-card:hover {
    border-color: var(--primary);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.15);
}

.model-card.selected {
    border-color: var(--primary);
    background: rgba(99, 102, 241, 0.05);
}

.model-card input[type="checkbox"] {
    width: 20px;
    height: 20px;
    cursor: pointer;
}

.test-result {
    background: var(--gray-50);
    border-radius: 12px;
    padding: 20px;
    margin-top: 20px;
}

.test-result.success {
    background: rgba(16, 185, 129, 0.1);
    border: 2px solid var(--success);
}

.test-result.error {
    background: rgba(239, 68, 68, 0.1);
    border: 2px solid var(--danger);
}

.wizard-actions {
    display: flex;
    justify-content: space-between;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 2px solid var(--gray-200);
}

.service-status {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border-radius: 20px;
    font-weight: 500;
    font-size: 0.875rem;
}

.service-status.running {
    background: rgba(16, 185, 129, 0.1);
    color: var(--success);
}

.service-status.stopped {
    background: rgba(239, 68, 68, 0.1);
    color: var(--danger);
}

.service-status i {
    font-size: 1rem;
}
