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

:root {
    --primary: #4F46E5;
    --primary-dark: #4338CA;
    --primary-light: #818CF8;
    --secondary: #0EA5E9;
    --success: #22C55E;
    --warning: #EAB308;
    --danger: #EF4444;
    --gray-50: #F9FAFB;
    --gray-100: #F3F4F6;
    --gray-200: #E5E7EB;
    --gray-300: #D1D5DB;
    --gray-400: #9CA3AF;
    --gray-500: #6B7280;
    --gray-600: #4B5563;
    --gray-700: #374151;
    --gray-800: #1F2937;
    --gray-900: #111827;
    --radius: 8px;
    --shadow: 0 1px 3px rgba(0,0,0,0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.1);
    --transition: all 0.3s ease;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: var(--gray-50);
    color: var(--gray-800);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ========== 头部 ========== */
.header {
    background: white;
    border-bottom: 1px solid var(--gray-200);
    padding: 12px 0;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: var(--shadow);
}

.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo h1 {
    font-size: 20px;
    color: var(--primary);
}

.logo a {
    text-decoration: none;
}

.nav {
    display: flex;
    gap: 20px;
    align-items: center;
    flex-wrap: wrap;
}

.nav a {
    color: var(--gray-600);
    text-decoration: none;
    font-size: 14px;
    transition: var(--transition);
}

.nav a:hover {
    color: var(--primary);
}

.user-badge {
    background: var(--primary-light);
    color: white;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
}

/* ========== 按钮 ========== */
.btn {
    display: inline-block;
    padding: 10px 24px;
    border: none;
    border-radius: var(--radius);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
    text-align: center;
}

.btn-primary {
    background: var(--primary);
    color: white;
}

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
    box-shadow: var(--shadow-lg);
}

.btn-secondary {
    background: var(--gray-200);
    color: var(--gray-700);
}

.btn-secondary:hover {
    background: var(--gray-300);
}

.btn-success {
    background: var(--success);
    color: white;
}

.btn-danger {
    background: var(--danger);
    color: white;
}

.btn-warning {
    background: var(--warning);
    color: white;
}

.btn-sm {
    padding: 6px 14px;
    font-size: 12px;
}

.btn-lg {
    padding: 14px 32px;
    font-size: 16px;
}

.btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* ========== 卡片 ========== */
.card {
    background: white;
    border-radius: var(--radius);
    padding: 24px;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.card:hover {
    box-shadow: var(--shadow-lg);
}

.card-title {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 16px;
    color: var(--gray-800);
}

/* ========== 表单 ========== */
.form-group {
    margin-bottom: 16px;
}

.form-group label {
    display: block;
    font-weight: 500;
    margin-bottom: 6px;
    color: var(--gray-700);
    font-size: 14px;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 10px 14px;
    border: 1px solid var(--gray-300);
    border-radius: var(--radius);
    font-size: 14px;
    transition: var(--transition);
    background: white;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.1);
}

.form-group textarea {
    min-height: 120px;
    resize: vertical;
}

/* ========== 英雄区域 ========== */
.hero {
    padding: 80px 0;
    text-align: center;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white;
}

.hero h2 {
    font-size: 42px;
    font-weight: 800;
    margin-bottom: 16px;
}

.hero p {
    font-size: 18px;
    opacity: 0.9;
    max-width: 600px;
    margin: 0 auto 32px;
}

.hero-actions {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
}

.hero-actions .btn-secondary {
    background: rgba(255,255,255,0.2);
    color: white;
}

.hero-actions .btn-secondary:hover {
    background: rgba(255,255,255,0.3);
}

/* ========== 功能特点 ========== */
.features {
    padding: 60px 0;
    background: white;
}

.features h3 {
    text-align: center;
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 40px;
    color: var(--gray-800);
}

.feature-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
}

.feature-card {
    padding: 24px;
    background: var(--gray-50);
    border-radius: var(--radius);
    text-align: center;
    transition: var(--transition);
}

.feature-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.feature-card h4 {
    font-size: 18px;
    margin-bottom: 8px;
    color: var(--gray-800);
}

.feature-card p {
    color: var(--gray-500);
    font-size: 14px;
}

/* ========== 页脚 ========== */
.footer {
    background: var(--gray-800);
    color: var(--gray-400);
    padding: 24px 0;
    text-align: center;
    margin-top: auto;
}

.footer p {
    font-size: 14px;
}

/* ========== 进度条 ========== */
.progress-bar {
    width: 100%;
    height: 8px;
    background: var(--gray-200);
    border-radius: 4px;
    overflow: hidden;
    margin: 12px 0;
}

.progress-bar .progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary), var(--secondary));
    transition: width 0.5s ease;
    border-radius: 4px;
}

/* ========== 日志容器 ========== */
.log-container {
    background: var(--gray-900);
    color: #00ff41;
    padding: 16px;
    border-radius: var(--radius);
    font-family: 'Courier New', monospace;
    font-size: 13px;
    max-height: 400px;
    overflow-y: auto;
    white-space: pre-wrap;
    word-break: break-word;
}

.log-container .log-entry {
    padding: 2px 0;
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

.log-container .log-time {
    color: var(--gray-400);
    margin-right: 12px;
}

.log-container .log-step {
    color: var(--secondary);
}

.log-container .log-output {
    color: #00ff41;
}

/* ========== 状态徽章 ========== */
.badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
}

.badge-pending { background: var(--gray-200); color: var(--gray-600); }
.badge-processing { background: var(--warning); color: white; }
.badge-completed { background: var(--success); color: white; }
.badge-failed { background: var(--danger); color: white; }
.badge-cancelled { background: var(--gray-400); color: white; }

/* ========== 响应式 ========== */
@media (max-width: 768px) {
    .hero h2 {
        font-size: 28px;
    }
    
    .nav {
        gap: 12px;
    }
    
    .nav a {
        font-size: 12px;
    }
    
    .feature-grid {
        grid-template-columns: 1fr 1fr;
    }
    
    .container {
        padding: 0 12px;
    }
}

@media (max-width: 480px) {
    .feature-grid {
        grid-template-columns: 1fr;
    }
    
    .hero {
        padding: 40px 0;
    }
    
    .hero h2 {
        font-size: 22px;
    }
}

/* ========== 会员等级徽章增强 ========== */
.badge-free { 
    background: #D1D5DB; 
    color: #374151; 
    padding: 2px 12px;
    border-radius: 12px;
    font-size: 12px;
}
.badge-basic { 
    background: #60A5FA; 
    color: white;
    padding: 2px 12px;
    border-radius: 12px;
    font-size: 12px;
}
.badge-pro { 
    background: #A78BFA; 
    color: white;
    padding: 2px 12px;
    border-radius: 12px;
    font-size: 12px;
}
.badge-enterprise { 
    background: linear-gradient(135deg, #F59E0B, #D97706); 
    color: white;
    padding: 2px 12px;
    border-radius: 12px;
    font-size: 12px;
}

/* 会员等级标签（用于导航栏） */
.member-tag {
    display: inline-block;
    padding: 1px 10px;
    border-radius: 10px;
    font-size: 10px;
    font-weight: 600;
    margin-left: 4px;
}
.member-tag.member-free { background: #D1D5DB; color: #374151; }
.member-tag.member-basic { background: #60A5FA; color: white; }
.member-tag.member-pro { background: #A78BFA; color: white; }
.member-tag.member-enterprise { background: #F59E0B; color: white; }