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

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f8f9fa;
}

/* 容器样式 */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 导航栏样式 */
.navbar {
    background-color: white;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
}

.logo h1 {
    font-size: 1.8em;
    color: #2c3e50;
    font-weight: 600;
}

.nav-links {
    display: flex;
    gap: 25px;
}

.nav-link {
    text-decoration: none;
    color: #555;
    font-weight: 500;
    transition: color 0.3s ease;
}

.nav-link:hover {
    color: #3498db;
}

.nav-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
}

.bar {
    display: block;
    width: 25px;
    height: 3px;
    background-color: #333;
    margin: 5px 0;
    transition: all 0.3s ease;
}

/* 英雄区域样式 */
.hero {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 100px 0;
    text-align: center;
}

.hero-content h2 {
    font-size: 2.5em;
    margin-bottom: 20px;
    font-weight: 600;
}

.hero-content p {
    font-size: 1.2em;
    margin-bottom: 30px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
    opacity: 0.9;
}

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

.primary-btn,
.secondary-btn {
    padding: 12px 30px;
    border: none;
    border-radius: 50px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
}

.primary-btn {
    background-color: white;
    color: #667eea;
}

.primary-btn:hover {
    background-color: #f8f9fa;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.secondary-btn {
    background-color: transparent;
    color: white;
    border: 2px solid white;
}

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

/* 上传区域样式 */
.upload-section {
    padding: 80px 0;
}

.upload-container {
    background-color: white;
    border-radius: 15px;
    padding: 40px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.05);
    max-width: 800px;
    margin: 0 auto;
}

.upload-header {
    text-align: center;
    margin-bottom: 30px;
}

.upload-header h3 {
    font-size: 1.8em;
    color: #2c3e50;
    margin-bottom: 10px;
}

.upload-header p {
    color: #7f8c8d;
}

.drop-area {
    border: 2px dashed #ddd;
    border-radius: 10px;
    padding: 40px 20px;
    text-align: center;
    transition: all 0.3s ease;
    cursor: pointer;
    margin-bottom: 30px;
}

.drop-area:hover,
.drop-area.drag-over {
    border-color: #3498db;
    background-color: #f8f9fa;
}

.upload-icon {
    font-size: 48px;
    margin-bottom: 15px;
}

.browse-text {
    color: #3498db;
    font-weight: 500;
    cursor: pointer;
}

#fileInput {
    display: none;
}

/* 文件列表样式 */
.file-list {
    margin-bottom: 30px;
}

.file-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px;
    background-color: #f8f9fa;
    border-radius: 8px;
    margin-bottom: 10px;
}

.file-info {
    display: flex;
    align-items: center;
    gap: 10px;
}

.file-icon {
    font-size: 20px;
}

.file-name {
    font-weight: 500;
    color: #2c3e50;
}

.file-size {
    font-size: 0.9em;
    color: #7f8c8d;
}

.remove-file {
    background: none;
    border: none;
    color: #e74c3c;
    cursor: pointer;
    font-size: 18px;
    transition: color 0.3s ease;
}

.remove-file:hover {
    color: #c0392b;
}

/* 转换选项样式 */
.conversion-options {
    margin-bottom: 30px;
}

.conversion-options h4 {
    font-size: 1.2em;
    color: #2c3e50;
    margin-bottom: 20px;
}

.option-group {
    margin-bottom: 15px;
}

.option-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 500;
    color: #555;
}

.option-group input[type="text"],
.option-group select {
    width: 100%;
    padding: 10px 15px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 16px;
    transition: all 0.3s ease;
}

.option-group input[type="text"]:focus,
.option-group select:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

.option-group input[type="checkbox"] {
    margin-right: 8px;
}

.option-group input[type="checkbox"] + label {
    display: inline-block;
    margin-right: 15px;
    font-weight: normal;
}

/* 生成按钮样式 */
.generate-btn {
    width: 100%;
    padding: 15px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.generate-btn:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
}

.generate-btn:disabled {
    background-color: #bdc3c7;
    cursor: not-allowed;
}

/* 进度条样式 */
.progress-container {
    margin-top: 20px;
}

.progress-bar {
    width: 100%;
    height: 10px;
    background-color: #ecf0f1;
    border-radius: 5px;
    overflow: hidden;
    margin-bottom: 10px;
}

.progress-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
    transition: width 0.3s ease;
}

.progress-text {
    text-align: center;
    color: #7f8c8d;
}

/* 下载容器样式 */
.download-container {
    margin-top: 20px;
    text-align: center;
}

.success-message {
    color: #27ae60;
    font-size: 1.1em;
    font-weight: 600;
    margin-bottom: 15px;
}

.download-link {
    display: inline-block;
    padding: 12px 30px;
    background-color: #27ae60;
    color: white;
    text-decoration: none;
    border-radius: 50px;
    font-weight: 600;
    transition: all 0.3s ease;
    margin-bottom: 15px;
}

.download-link:hover {
    background-color: #229954;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(39, 174, 96, 0.3);
}

.new-generation-btn {
    padding: 10px 25px;
    background-color: transparent;
    color: #3498db;
    border: 2px solid #3498db;
    border-radius: 50px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.new-generation-btn:hover {
    background-color: #3498db;
    color: white;
}

/* 功能特点样式 */
.features {
    padding: 80px 0;
    background-color: #f8f9fa;
}

.features h2 {
    text-align: center;
    font-size: 2.2em;
    color: #2c3e50;
    margin-bottom: 50px;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.feature-card {
    background-color: white;
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
    text-align: center;
}

.feature-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
}

.feature-icon {
    font-size: 48px;
    margin-bottom: 20px;
}

.feature-card h3 {
    font-size: 1.4em;
    color: #2c3e50;
    margin-bottom: 15px;
}

.feature-card p {
    color: #7f8c8d;
    line-height: 1.7;
}

/* 使用方法样式 */
.how-it-works {
    padding: 80px 0;
}

.how-it-works h2 {
    text-align: center;
    font-size: 2.2em;
    color: #2c3e50;
    margin-bottom: 50px;
}

.steps-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
    position: relative;
}

.step {
    background-color: white;
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    width: 220px;
    text-align: center;
    position: relative;
    z-index: 1;
}

.step-number {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5em;
    font-weight: 600;
    margin: 0 auto 20px;
}

.step h3 {
    font-size: 1.2em;
    color: #2c3e50;
    margin-bottom: 10px;
}

.step p {
    color: #7f8c8d;
    font-size: 0.95em;
}

.step-divider {
    width: 20px;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #7f8c8d;
    font-size: 1.5em;
    display: none;
}

/* 模板展示样式 */
.templates {
    padding: 80px 0;
    background-color: #f8f9fa;
}

.templates h2 {
    text-align: center;
    font-size: 2.2em;
    color: #2c3e50;
    margin-bottom: 15px;
}

.templates p {
    text-align: center;
    color: #7f8c8d;
    margin-bottom: 50px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.templates-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.template-card {
    background-color: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
}

.template-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
}

.template-preview {
    height: 150px;
    background-color: #f8f9fa;
    display: flex;
    align-items: center;
    justify-content: center;
}

.template-icon {
    font-size: 64px;
}

.template-card h3 {
    padding: 20px 20px 10px;
    color: #2c3e50;
}

.template-card p {
    padding: 0 20px 20px;
    margin: 0;
    text-align: left;
    font-size: 0.95em;
}

.template-btn {
    margin: 0 20px 20px;
    padding: 10px 20px;
    background-color: transparent;
    color: #3498db;
    border: 1px solid #3498db;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.template-btn:hover {
    background-color: #3498db;
    color: white;
}

/* 数据统计样式 */
.statistics {
    padding: 80px 0;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    text-align: center;
}

.statistics h2 {
    font-size: 2.2em;
    margin-bottom: 50px;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
}

.stat-item {
    padding: 20px;
}

.stat-number {
    font-size: 2.5em;
    font-weight: 600;
    margin-bottom: 10px;
}

.stat-item p {
    font-size: 1.1em;
    opacity: 0.9;
}

/* 常见问题样式 */
.faq {
    padding: 80px 0;
}

.faq h2 {
    text-align: center;
    font-size: 2.2em;
    color: #2c3e50;
    margin-bottom: 50px;
}

.faq-items {
    max-width: 800px;
    margin: 0 auto;
}

.faq-item {
    margin-bottom: 20px;
    border-bottom: 1px solid #ecf0f1;
}

.faq-question {
    width: 100%;
    padding: 20px 0;
    background: none;
    border: none;
    text-align: left;
    font-size: 1.1em;
    font-weight: 600;
    color: #2c3e50;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    padding-right: 30px;
}

.faq-question:hover {
    color: #3498db;
}

.faq-question::after {
    content: '▶';
    position: absolute;
    right: 0;
    transition: transform 0.3s ease;
}

.faq-question.active::after {
    transform: rotate(90deg);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
}

.faq-answer p {
    padding: 0 0 20px;
    color: #7f8c8d;
    line-height: 1.7;
}

/* 页脚样式 */
footer {
    background-color: #2c3e50;
    color: white;
    padding: 50px 0 20px;
}

.footer-content {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 30px;
    margin-bottom: 30px;
}

.footer-info h3 {
    font-size: 1.5em;
    margin-bottom: 10px;
}

.footer-info p {
    color: #bdc3c7;
}

.footer-links {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.footer-link {
    color: #bdc3c7;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-link:hover {
    color: white;
}

.footer-social {
    display: flex;
    gap: 15px;
}

.social-icon {
    color: #bdc3c7;
    text-decoration: none;
    transition: color 0.3s ease;
}

.social-icon:hover {
    color: white;
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid #34495e;
    color: #95a5a6;
    font-size: 0.9em;
}

/* 回到顶部按钮 */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    border-radius: 50%;
    font-size: 24px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    z-index: 999;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.back-to-top:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
}

/* 响应式设计 */
@media (max-width: 768px) {
    .nav-links {
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background-color: white;
        flex-direction: column;
        padding: 20px;
        box-shadow: 0 5px 10px rgba(0, 0, 0, 0.1);
        display: none;
        gap: 15px;
    }
    
    .nav-links.active {
        display: flex;
    }
    
    .nav-toggle {
        display: block;
    }
    
    .hero-content h2 {
        font-size: 2em;
    }
    
    .upload-container {
        padding: 30px 20px;
    }
    
    .steps-container {
        flex-direction: column;
        align-items: center;
    }
    
    .step {
        width: 100%;
        max-width: 300px;
    }
    
    .step-divider {
        display: flex;
        width: 100%;
        max-width: 300px;
        height: 20px;
    }
    
    .footer-content {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .hero-content h2 {
        font-size: 1.8em;
    }
    
    .features-grid,
    .templates-grid,
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .upload-header h3 {
        font-size: 1.5em;
    }
    
    .step {
        padding: 20px;
    }
}

/* 动画效果 */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.feature-card,
.template-card,
.step {
    animation: fadeIn 0.5s ease forwards;
}

.feature-card:nth-child(1),
.template-card:nth-child(1),
.step:nth-child(1) {
    animation-delay: 0.1s;
}

.feature-card:nth-child(2),
.template-card:nth-child(2),
.step:nth-child(2) {
    animation-delay: 0.2s;
}

.feature-card:nth-child(3),
.template-card:nth-child(3),
.step:nth-child(3) {
    animation-delay: 0.3s;
}

.feature-card:nth-child(4),
.step:nth-child(4) {
    animation-delay: 0.4s;
}