/* ========================================
   AI 问卷助手 - 首页样式
   专业级高端设计
   ======================================== */

:root {
    --bg-dark: #0A0A0A;
    --bg-dark-secondary: #111827;
    --bg-dark-tertiary: #1F2937;
    --text-primary: #FFFFFF;
    --text-secondary: #E5E7EB;
    --text-muted: #9CA3AF;
    --brand-primary: #6366F1;
    --brand-primary-light: #818CF8;
    --brand-primary-dark: #4F46E5;
    --brand-gradient: linear-gradient(135deg, #6366F1 0%, #8B5CF6 100%);
    --brand-gradient-vertical: linear-gradient(180deg, #6366F1 0%, #8B5CF6 100%);
    --success-gradient: linear-gradient(135deg, #10B981 0%, #059669 100%);
    --accent-purple: #8B5CF6;
    --accent-green: #10B981;
    --accent-blue: #3B82F6;
    --shadow-glow: 0 0 40px rgba(99, 102, 139, 0.3);
    --shadow-lg: 0 20px 60px rgba(0, 0, 0, 0.5);
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Inter', 'SF Pro Display', 'Microsoft YaHei', sans-serif;
    color: var(--text-primary);
    background: var(--bg-dark);
    line-height: 1.6;
    overflow-x: hidden;
}

/* ========================================
   导航栏
   ======================================== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    padding: 20px 60px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    z-index: 1000;
    background: rgba(10, 10, 10, 0.8);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    transition: all 0.3s ease;
}

.navbar.scrolled {
    background: rgba(10, 10, 10, 0.95);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.5);
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    text-decoration: none;
    transition: transform 0.3s ease;
}

.logo:hover {
    transform: scale(1.05);
}

.logo-icon {
    font-size: 2rem;
    background: var(--brand-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav-links {
    display: flex;
    gap: 40px;
    list-style: none;
    align-items: center;
}

.nav-links a {
    color: var(--text-secondary);
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    position: relative;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--brand-gradient);
    transition: width 0.3s ease;
}

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

.nav-links a:hover::after {
    width: 100%;
}

.nav-user-btn {
    background: var(--brand-gradient);
    color: white !important;
    padding: 10px 24px !important;
    border-radius: 12px;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(99, 102, 241, 0.3);
}

.nav-user-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(99, 102, 241, 0.5);
}

.nav-user-btn::after {
    display: none;
}

/* ========================================
   Hero 区域
   ======================================== */
.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 120px 60px 80px;
    position: relative;
    overflow: hidden;
    background: var(--bg-dark);
}

/* 动态网格背景 */
.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: 
        linear-gradient(rgba(99, 102, 241, 0.1) 1px, transparent 1px),
        linear-gradient(90deg, rgba(99, 102, 241, 0.1) 1px, transparent 1px);
    background-size: 60px 60px;
    opacity: 0.3;
    animation: gridMove 20s linear infinite;
}

@keyframes gridMove {
    0% { transform: translate(0, 0); }
    100% { transform: translate(60px, 60px); }
}

/* 渐变光晕效果 */
.hero::after {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(99, 102, 241, 0.15) 0%, transparent 70%);
    animation: rotate 30s linear infinite;
    pointer-events: none;
}

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

.hero-content {
    max-width: 1400px;
    width: 100%;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: center;
    position: relative;
    z-index: 1;
}

.hero-text {
    animation: fadeInLeft 1s ease-out;
}

@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.hero-badge {
    display: inline-block;
    background: rgba(99, 102, 241, 0.15);
    color: var(--brand-primary-light);
    padding: 8px 18px;
    border-radius: 50px;
    font-size: 0.85rem;
    font-weight: 600;
    margin-bottom: 24px;
    margin-right: 12px;
    border: 1px solid rgba(99, 102, 241, 0.3);
    backdrop-filter: blur(10px);
    opacity: 0;
    transform: translateY(20px);
    animation: badgeFadeIn 0.6s ease forwards;
    animation-delay: var(--delay, 0s);
}

.hero-badge:nth-child(1) { --delay: 0.2s; }
.hero-badge:nth-child(2) { --delay: 0.4s; }
.hero-badge:nth-child(3) { --delay: 0.6s; }

@keyframes badgeFadeIn {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hero h1 {
    font-size: 4.5rem;
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 24px;
    background: linear-gradient(135deg, #FFFFFF 0%, #E5E7EB 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero h1 .cursor {
    display: inline-block;
    width: 4px;
    height: 1em;
    background: var(--brand-primary);
    margin-left: 8px;
    vertical-align: text-bottom;
    animation: blink 1s infinite;
}

@keyframes blink {
    0%, 50% { opacity: 1; }
    51%, 100% { opacity: 0; }
}

.hero .subtitle {
    font-size: 1.3rem;
    color: var(--text-secondary);
    margin-bottom: 40px;
    line-height: 1.7;
    max-width: 600px;
}

.hero-buttons {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 16px 32px;
    border-radius: 12px;
    font-size: 1.1rem;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    cursor: pointer;
    border: none;
    position: relative;
    overflow: hidden;
}

.btn-primary {
    background: var(--brand-gradient);
    color: white;
    box-shadow: 0 8px 30px rgba(99, 102, 241, 0.4);
}

.btn-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s ease;
}

.btn-primary:hover::before {
    left: 100%;
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 40px rgba(99, 102, 241, 0.6);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-primary);
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.2);
    transform: translateY(-3px);
}

/* Hero 右侧 - 可视化区域 */
.hero-visual {
    position: relative;
    animation: fadeInRight 1s ease-out;
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(50px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.hero-visual-content {
    background: rgba(31, 41, 55, 0.6);
    border-radius: 24px;
    padding: 40px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(20px);
    box-shadow: var(--shadow-lg);
    position: relative;
    overflow: hidden;
}

.hero-visual-content::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--brand-gradient);
}

/* 模拟产品界面预览 */
.product-preview {
    background: var(--bg-dark-secondary);
    border-radius: 16px;
    padding: 24px;
    margin-top: 20px;
}

.preview-header {
    display: flex;
    gap: 8px;
    margin-bottom: 16px;
}

.preview-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
}

.preview-content {
    background: var(--bg-dark);
    border-radius: 8px;
    padding: 20px;
    min-height: 300px;
}

.preview-charts {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
    height: 100%;
}

.preview-chart-item {
    position: relative;
    height: 130px;
    background: rgba(99, 102, 241, 0.05);
    border-radius: 8px;
    padding: 12px;
    border: 1px solid rgba(99, 102, 241, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
}

.preview-chart-item canvas {
    max-width: 100% !important;
    max-height: 100% !important;
}

.preview-chart-item:nth-child(3) {
    grid-column: 1 / -1;
    height: 100px;
}

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

.preview-chart-item {
    animation: fadeIn 0.6s ease forwards;
}

.preview-chart-item:nth-child(1) { animation-delay: 0.2s; }
.preview-chart-item:nth-child(2) { animation-delay: 0.4s; }
.preview-chart-item:nth-child(3) { animation-delay: 0.6s; }

/* 信任元素 */
.hero-stats {
    display: flex;
    gap: 40px;
    margin-top: 60px;
    padding-top: 40px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.stat-item {
    text-align: left;
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 800;
    background: var(--brand-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    display: block;
}

.stat-label {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-top: 4px;
}

/* ========================================
   功能特性
   ======================================== */
.features {
    padding: 120px 60px;
    background: var(--bg-dark-secondary);
    position: relative;
}

.section-header {
    text-align: center;
    margin-bottom: 80px;
    opacity: 0;
    animation: fadeInUp 1s ease-out forwards;
}

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

.section-header h2 {
    font-size: 3rem;
    font-weight: 800;
    margin-bottom: 16px;
    background: linear-gradient(135deg, #FFFFFF 0%, #E5E7EB 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.section-header p {
    font-size: 1.2rem;
    color: var(--text-muted);
    max-width: 600px;
    margin: 0 auto;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    max-width: 1400px;
    margin: 0 auto;
}

.feature-card {
    background: rgba(31, 41, 55, 0.6);
    border-radius: 20px;
    padding: 40px;
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: all 0.4s ease;
    position: relative;
    overflow: hidden;
    opacity: 0;
    animation: fadeInUp 0.8s ease forwards;
    animation-delay: calc(var(--index) * 0.1s);
}

.feature-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--brand-gradient);
    transform: scaleX(0);
    transition: transform 0.4s ease;
}

.feature-card:hover::before {
    transform: scaleX(1);
}

.feature-card:hover {
    transform: translateY(-10px);
    border-color: rgba(99, 102, 241, 0.3);
    box-shadow: 0 20px 60px rgba(99, 102, 241, 0.2);
    background: rgba(31, 41, 55, 0.8);
}

.feature-icon {
    width: 70px;
    height: 70px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    margin-bottom: 24px;
    position: relative;
    transition: transform 0.4s ease;
}

.feature-icon::before {
    content: '';
    position: absolute;
    inset: -2px;
    border-radius: 16px;
    background: var(--brand-gradient);
    opacity: 0;
    transition: opacity 0.4s ease;
    z-index: -1;
}

.feature-card:hover .feature-icon {
    transform: scale(1.1);
}

.feature-card:hover .feature-icon::before {
    opacity: 0.2;
}

.feature-icon.purple { background: linear-gradient(135deg, rgba(99, 102, 241, 0.2) 0%, rgba(139, 92, 246, 0.2) 100%); }
.feature-icon.green { background: linear-gradient(135deg, rgba(16, 185, 129, 0.2) 0%, rgba(5, 150, 105, 0.2) 100%); }
.feature-icon.blue { background: linear-gradient(135deg, rgba(59, 130, 246, 0.2) 0%, rgba(37, 99, 235, 0.2) 100%); }
.feature-icon.orange { background: linear-gradient(135deg, rgba(245, 158, 11, 0.2) 0%, rgba(251, 191, 36, 0.2) 100%); }
.feature-icon.pink { background: linear-gradient(135deg, rgba(236, 72, 153, 0.2) 0%, rgba(244, 114, 182, 0.2) 100%); }
.feature-icon.teal { background: linear-gradient(135deg, rgba(20, 184, 166, 0.2) 0%, rgba(45, 212, 191, 0.2) 100%); }

.feature-card h3 {
    font-size: 1.5rem;
    margin-bottom: 12px;
    color: var(--text-primary);
    font-weight: 700;
}

.feature-card p {
    color: var(--text-secondary);
    line-height: 1.7;
    font-size: 1rem;
}

/* ========================================
   产品展示
   ======================================== */
.products {
    padding: 120px 60px;
    background: var(--bg-dark);
    position: relative;
}

.products-wrapper {
    max-width: 1400px;
    margin: 0 auto;
}

.product-cards {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 40px;
    margin-top: 60px;
}

.product-card {
    background: rgba(31, 41, 55, 0.6);
    border-radius: 24px;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: all 0.4s ease;
    opacity: 0;
    animation: fadeInUp 0.8s ease forwards;
    animation-delay: calc(var(--index) * 0.2s);
}

.product-card:hover {
    transform: translateY(-10px);
    border-color: rgba(99, 102, 241, 0.3);
    box-shadow: 0 30px 80px rgba(99, 102, 241, 0.3);
}

.product-header {
    padding: 50px 40px;
    color: white;
    position: relative;
    overflow: hidden;
}

.product-header::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.1) 0%, transparent 70%);
    animation: rotate 20s linear infinite;
}

.product-header.generator {
    background: var(--success-gradient);
}

.product-header.analyzer {
    background: linear-gradient(135deg, #3B82F6 0%, #2563EB 100%);
}

.product-header h3 {
    font-size: 2rem;
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 12px;
    position: relative;
    z-index: 1;
}

.product-header p {
    opacity: 0.95;
    font-size: 1.1rem;
    position: relative;
    z-index: 1;
}

.product-body {
    padding: 40px;
    background: rgba(31, 41, 55, 0.4);
}

.product-features {
    list-style: none;
    margin-bottom: 30px;
}

.product-features li {
    padding: 12px 0;
    display: flex;
    align-items: center;
    gap: 12px;
    color: var(--text-secondary);
    font-size: 1rem;
}

.product-features li::before {
    content: '✓';
    display: flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    background: var(--success-gradient);
    color: white;
    border-radius: 50%;
    font-size: 0.8rem;
    font-weight: bold;
    flex-shrink: 0;
}

.product-btn {
    width: 100%;
    padding: 18px;
    border-radius: 12px;
    font-size: 1.1rem;
    font-weight: 600;
    text-align: center;
    text-decoration: none;
    display: block;
    transition: all 0.3s ease;
    color: white;
}

.product-btn.generator {
    background: var(--success-gradient);
    box-shadow: 0 8px 30px rgba(16, 185, 129, 0.3);
}

.product-btn.analyzer {
    background: linear-gradient(135deg, #3B82F6 0%, #2563EB 100%);
    box-shadow: 0 8px 30px rgba(59, 130, 246, 0.3);
}

.product-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 40px rgba(99, 102, 241, 0.5);
}

/* ========================================
   工作流程
   ======================================== */
.workflow {
    padding: 120px 60px;
    background: var(--bg-dark-secondary);
    position: relative;
}

.workflow-steps {
    display: flex;
    justify-content: center;
    gap: 40px;
    flex-wrap: wrap;
    max-width: 1400px;
    margin: 0 auto;
    position: relative;
}

.workflow-step {
    flex: 1;
    min-width: 220px;
    max-width: 280px;
    text-align: center;
    padding: 40px 30px;
    position: relative;
    opacity: 0;
    animation: fadeInUp 0.8s ease forwards;
    animation-delay: calc(var(--index) * 0.15s);
}

.step-number {
    width: 70px;
    height: 70px;
    background: var(--brand-gradient);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    font-weight: 800;
    margin: 0 auto 24px;
    box-shadow: 0 8px 30px rgba(99, 102, 241, 0.4);
    position: relative;
    transition: transform 0.4s ease;
}

.step-number::after {
    content: '';
    position: absolute;
    inset: -4px;
    border-radius: 50%;
    border: 2px solid var(--brand-primary);
    opacity: 0;
    transition: opacity 0.4s ease;
}

.workflow-step:hover .step-number {
    transform: scale(1.1);
}

.workflow-step:hover .step-number::after {
    opacity: 0.5;
}

.workflow-step h4 {
    font-size: 1.3rem;
    margin-bottom: 12px;
    color: var(--text-primary);
    font-weight: 700;
}

.workflow-step p {
    font-size: 1rem;
    color: var(--text-secondary);
    line-height: 1.6;
}

.workflow-arrow {
    position: absolute;
    right: -20px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 2rem;
    color: var(--brand-primary);
    opacity: 0.5;
}

.workflow-step:last-child .workflow-arrow {
    display: none;
}

/* ========================================
   CTA 区域
   ======================================== */
.cta-section {
    padding: 120px 60px;
    background: var(--bg-dark);
    position: relative;
    overflow: hidden;
}

.cta-section::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(99, 102, 241, 0.1) 0%, transparent 70%);
    animation: rotate 25s linear infinite;
}

.cta-content {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
    position: relative;
    z-index: 1;
}

.cta-content h2 {
    font-size: 3.5rem;
    font-weight: 800;
    margin-bottom: 24px;
    background: var(--brand-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.cta-content p {
    font-size: 1.3rem;
    color: var(--text-secondary);
    margin-bottom: 40px;
}

.cta-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap;
}

/* ========================================
   Footer
   ======================================== */
.footer {
    background: var(--bg-dark-secondary);
    color: var(--text-muted);
    padding: 80px 60px 40px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.footer-content {
    max-width: 1400px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 60px;
    margin-bottom: 60px;
}

.footer-brand h3 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.footer-brand p {
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 20px;
}

.footer-links h4 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 20px;
}

.footer-links ul {
    list-style: none;
}

.footer-links li {
    margin-bottom: 12px;
}

.footer-links a {
    color: var(--text-muted);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: var(--brand-primary-light);
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    padding-top: 40px;
    text-align: center;
    color: var(--text-muted);
    font-size: 0.9rem;
}

/* ========================================
   响应式设计
   ======================================== */
@media (max-width: 1200px) {
    .hero-content {
        grid-template-columns: 1fr;
        gap: 60px;
        text-align: center;
    }
    
    .hero h1 {
        font-size: 3.5rem;
    }
    
    .features-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .product-cards {
        grid-template-columns: 1fr;
    }
    
    .footer-content {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 768px) {
    .navbar {
        padding: 16px 24px;
    }
    
    .nav-links {
        display: none;
    }
    
    .hero {
        padding: 100px 24px 60px;
    }
    
    .hero h1 {
        font-size: 2.5rem;
    }
    
    .hero .subtitle {
        font-size: 1.1rem;
    }
    
    .features,
    .products,
    .workflow,
    .cta-section {
        padding: 80px 24px;
    }
    
    .section-header h2 {
        font-size: 2rem;
    }
    
    .features-grid {
        grid-template-columns: 1fr;
    }
    
    .workflow-step {
        max-width: 100%;
    }
    
    .workflow-arrow {
        display: none;
    }
    
    .cta-content h2 {
        font-size: 2.5rem;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .hero-stats {
        flex-direction: row;
        flex-wrap: wrap;
        gap: 20px;
        justify-content: center;
    }
    
    .stat-item {
        flex: 1;
        min-width: 100px;
        text-align: center;
    }
    
    .stat-number {
        font-size: 2rem;
    }
    
    .stat-label {
        font-size: 0.8rem;
    }
    
    .hero-buttons {
        flex-direction: column;
    }
    
    .btn {
        width: 100%;
        justify-content: center;
    }
}

