 /* 基础样式重置和变量定义 */
:root {
    --primary-color: #0c63e4;
    --secondary-color: #667eea;
    --accent-color: #764ba2;
    --text-color: #1d1d1f;
    --text-secondary: #86868b;
    --bg-color: #ffffff;
    --bg-secondary: #f8f9fa;
    --bg-dark: #1a1a1a;
    --border-color: #e5e7eb;
    --border-dark: #374151;
    --success-color: #10b981;
    --warning-color: #f59e0b;
    --error-color: #ef4444;
    --shadow-light: 0 1px 3px rgba(0, 0, 0, 0.1);
    --shadow-medium: 0 4px 6px rgba(0, 0, 0, 0.1);
    --shadow-heavy: 0 10px 25px rgba(0, 0, 0, 0.15);
    --transition: all 0.3s ease;
    --border-radius: 12px;
    --border-radius-sm: 8px;
}

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

html {
    font-size: 16px;
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', 'Noto Sans SC', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--bg-color);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    /* Firefox编码兼容性 */
    -moz-font-feature-settings: "kern" 1;
    font-feature-settings: "kern" 1;
    text-rendering: optimizeLegibility;
}

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

/* 通用样式 */
.section-header {
    text-align: center;
    margin-bottom: 60px;
}

.section-header h2 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 16px;
    color: var(--text-color);
}

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

/* Hero Section */
.hero {
    text-align: center;
    padding: 80px 20px;
    background: linear-gradient(135deg, var(--secondary-color) 0%, var(--accent-color) 100%);
    color: white;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at 30% 50%, rgba(255, 255, 255, 0.1) 0%, rgba(255, 255, 255, 0) 60%);
    z-index: 1;
}

.hero > * {
    position: relative;
    z-index: 2;
}

.hero h1 {
    font-size: 3.5rem;
    font-weight: 800;
    margin-bottom: 24px;
    line-height: 1.2;
}

.hero-gradient-text {
    background: linear-gradient(135deg, #38bdf8 0%, #a78bfa 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    /* text-fill-color is not a standard property, using -webkit-text-fill-color only */
}

.hero p {
    font-size: 1.25rem;
    margin-bottom: 40px;
    max-width: 800px;
    margin-left: auto;
    margin-right: auto;
    opacity: 0.9;
}

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

.signup-btn, .login-btn {
    padding: 16px 32px;
    border-radius: var(--border-radius-sm);
    font-weight: 600;
    text-decoration: none;
    transition: var(--transition);
    display: inline-block;
}

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

.signup-btn:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-medium);
}

.login-btn {
    background-color: transparent;
    color: white;
    border: 2px solid rgba(255, 255, 255, 0.3);
}

.login-btn:hover {
    background-color: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.5);
}

/* Features Section */
.features-section {
    padding: 80px 0;
    background-color: var(--bg-secondary);
}

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

.feature-card {
    background: white;
    padding: 32px;
    border-radius: var(--border-radius);
    border: 1px solid var(--border-color);
    transition: var(--transition);
    box-shadow: var(--shadow-light);
}

.feature-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-heavy);
    border-color: var(--primary-color);
}

.feature-icon {
    width: 64px;
    height: 64px;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    border-radius: var(--border-radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 24px;
}

.feature-icon svg {
    width: 32px;
    height: 32px;
    color: white;
}

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

.feature-card p {
    color: var(--text-secondary);
    line-height: 1.6;
}

/* Models Section */
.models-section {
    padding: 80px 0;
    background-color: var(--bg-color);
}

.models-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 24px;
    padding: 20px;
}

.models-grid img {
    height: 48px;
    max-width: 200px;
    flex-shrink: 0;
    transition: var(--transition);
}

.models-grid img:hover {
    transform: scale(1.05);
}

.more-models {
    color: var(--text-secondary);
    font-weight: 600;
    font-size: 1.125rem;
}

/* How It Works Section */
.how-it-works-section {
    padding: 80px 0;
    background-color: var(--bg-dark);
    color: white;
}

.how-it-works-section .section-header h2,
.how-it-works-section .section-header p {
    color: white;
}

.works-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 60px;
    align-items: start;
}

.steps-container {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.step-card {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: var(--border-radius);
    padding: 24px;
    transition: var(--transition);
    display: flex;
    align-items: flex-start;
    gap: 20px;
}

.step-card:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.2);
    transform: translateX(8px);
}

.step-number {
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.25rem;
    color: white;
    flex-shrink: 0;
}

.step-content h3 {
    font-size: 1.25rem;
    font-weight: 600;
    margin-bottom: 8px;
    color: white;
}

.step-content p {
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.6;
}

/* Code Container */
.code-container {
    background: #1e1e1e;
    border-radius: var(--border-radius);
    border: 1px solid rgba(255, 255, 255, 0.1);
    overflow: hidden;
    box-shadow: var(--shadow-heavy);
}

.code-header {
    background: #2d2d2d;
    padding: 16px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.code-title {
    color: rgba(255, 255, 255, 0.8);
    font-size: 0.875rem;
    font-weight: 500;
}

.code-controls {
    display: flex;
    gap: 8px;
}

.control-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
}

.control-red { background-color: #ff5f56; }
.control-yellow { background-color: #ffbd2e; }
.control-green { background-color: #27ca3f; }

.code-block {
    padding: 24px;
    margin: 0;
    overflow-x: auto;
    font-family: 'Fira Code', 'Consolas', 'Monaco', monospace;
    font-size: 0.875rem;
    line-height: 1.6;
    color: #e6e6e6;
    background: #1e1e1e;
}

.code-block code {
    color: inherit;
    background: none;
    padding: 0;
    border-radius: 0;
}

/* Pricing Section */
.pricing-section {
    padding: 80px 0;
    background-color: var(--bg-secondary);
}

.pricing-card {
    background: white;
    border-radius: var(--border-radius);
    padding: 48px;
    text-align: center;
    box-shadow: var(--shadow-medium);
    border: 1px solid var(--border-color);
    max-width: 500px;
    margin: 0 auto;
    transition: var(--transition);
}

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

.pricing-card h3 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 16px;
    color: var(--text-color);
}

.price {
    font-size: 3rem;
    font-weight: 800;
    margin: 24px 0;
    background: linear-gradient(135deg, var(--secondary-color) 0%, var(--accent-color) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    /* text-fill-color is not a standard property, using -webkit-text-fill-color only */
}

.price-description {
    color: var(--text-secondary);
    margin-bottom: 32px;
}

.pricing-features {
    list-style: none;
    text-align: left;
    margin-bottom: 32px;
}

.pricing-features li {
    display: flex;
    align-items: center;
    margin-bottom: 16px;
    color: var(--text-color);
}

.check-icon {
    color: var(--success-color);
    font-weight: bold;
    margin-right: 12px;
    font-size: 1.125rem;
}

.pricing-btn {
    display: inline-block;
    padding: 16px 32px;
    background-color: var(--primary-color);
    color: white;
    text-decoration: none;
    border-radius: var(--border-radius-sm);
    font-weight: 600;
    transition: var(--transition);
}

.pricing-btn:hover {
    background-color: #0a51c0;
    transform: translateY(-2px);
    box-shadow: var(--shadow-medium);
}

/* CTA Section */
.cta-section {
    padding: 80px 0;
    background: linear-gradient(135deg, var(--bg-dark) 0%, #2d2d2d 100%);
    color: white;
    text-align: center;
}

.cta-section h2 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 16px;
}

.cta-section p {
    font-size: 1.125rem;
    margin-bottom: 40px;
    opacity: 0.8;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.cta-btn {
    display: inline-block;
    padding: 20px 40px;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: white;
    text-decoration: none;
    border-radius: var(--border-radius-sm);
    font-weight: 600;
    font-size: 1.125rem;
    transition: var(--transition);
    box-shadow: var(--shadow-medium);
}

.cta-btn:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-heavy);
}

/* 响应式设计 */
@media (max-width: 1024px) {
    .works-container {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .features-grid {
        grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    }
}

@media (max-width: 768px) {
    .container {
        padding: 0 16px;
    }
    
    .hero h1 {
        font-size: 2.5rem;
    }
    
    .hero p {
        font-size: 1.125rem;
    }
    
    .section-header h2 {
        font-size: 2rem;
    }
    
    .hero-buttons {
        flex-direction: column;
        align-items: center;
    }
    
    .signup-btn, .login-btn {
        width: 100%;
        max-width: 300px;
        text-align: center;
    }
    
    .features-grid {
        grid-template-columns: 1fr;
    }
    
    .models-grid {
        gap: 16px;
    }
    
    .models-grid img {
        height: 40px;
        max-width: 160px;
    }
    
    .step-card {
        flex-direction: column;
        text-align: center;
    }
    
    .step-number {
        align-self: center;
    }
    
    .pricing-card {
        padding: 32px 24px;
    }
    
    .price {
        font-size: 2.5rem;
    }
}

@media (max-width: 480px) {
    .hero {
        padding: 60px 16px;
    }
    
    .hero h1 {
        font-size: 2rem;
    }
    
    .section-header h2 {
        font-size: 1.75rem;
    }
    
    .feature-card {
        padding: 24px;
    }
    
    .step-card {
        padding: 20px;
    }
    
    .code-block {
        padding: 16px;
        font-size: 0.8rem;
    }
    
    .pricing-card {
        padding: 24px 16px;
    }
}

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

.feature-card,
.step-card,
.pricing-card {
    animation: fadeInUp 0.6s ease-out;
}

/* 浏览器兼容性 */
@supports (-ms-ime-align: auto) {
    .hero-gradient-text {
        background: transparent;
        -webkit-text-fill-color: initial;
        color: #38bdf8;
    }
    
    .price {
        background: transparent;
        -webkit-text-fill-color: initial;
        color: var(--primary-color);
    }
}

/* Firefox特定修复 */
@-moz-document url-prefix() {
    body {
        font-family: 'Noto Sans SC', 'Microsoft YaHei', 'PingFang SC', 'Hiragino Sans GB', 'WenQuanYi Micro Hei', sans-serif;
    }
    
    .hero h1, .hero p, h2, h3, h4, p, li, span, div {
        font-family: 'Noto Sans SC', 'Microsoft YaHei', 'PingFang SC', 'Hiragino Sans GB', 'WenQuanYi Micro Hei', sans-serif;
    }
    
    /* 特别修复渐变文字在Firefox中的显示问题 */
    .hero-gradient-text {
        background: transparent !important;
        -webkit-background-clip: initial !important;
        -webkit-text-fill-color: initial !important;
        background-clip: initial !important;
        color: #38bdf8 !important;
        font-family: 'Noto Sans SC', 'Microsoft YaHei', 'PingFang SC', 'Hiragino Sans GB', 'WenQuanYi Micro Hei', sans-serif !important;
        -moz-font-feature-settings: "kern" 1, "liga" 1, "calt" 1;
        font-feature-settings: "kern" 1, "liga" 1, "calt" 1;
        text-rendering: optimizeLegibility;
    }
    
    /* 修复价格文字在Firefox中的显示问题 */
    .price {
        background: transparent !important;
        -webkit-background-clip: initial !important;
        -webkit-text-fill-color: initial !important;
        background-clip: initial !important;
        color: var(--primary-color) !important;
        font-family: 'Noto Sans SC', 'Microsoft YaHei', 'PingFang SC', 'Hiragino Sans GB', 'WenQuanYi Micro Hei', sans-serif !important;
        -moz-font-feature-settings: "kern" 1, "liga" 1, "calt" 1;
        font-feature-settings: "kern" 1, "liga" 1, "calt" 1;
        text-rendering: optimizeLegibility;
    }
    
    /* 确保中文字符正确显示 */
    * {
        -moz-font-feature-settings: "kern" 1, "liga" 1, "calt" 1;
        font-feature-settings: "kern" 1, "liga" 1, "calt" 1;
        text-rendering: optimizeLegibility;
    }
}

/* 打印样式 */
@media print {
    .hero {
        background: white !important;
        color: black !important;
    }
    
    .hero-gradient-text {
        color: var(--primary-color) !important;
    }
}