/* 导入 Google Fonts - 霞鹜文楷 + 马善政毛笔字 */
@import url('https://fonts.googleapis.com/css2?family=LXGW+WenKai:wght@300;400;700&family=Ma+Shan+Zheng&display=swap');

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

/* 字体变量定义 */
:root {
    --font-primary: 'LXGW WenKai', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'PingFang SC', 'Microsoft YaHei', sans-serif;
    --font-display: 'Ma Shan Zheng', cursive;
    --font-mono: 'SF Mono', 'Fira Code', 'Consolas', monospace;
    
    /* 字号规范 */
    --text-xs: 12px;
    --text-sm: 14px;
    --text-base: 16px;
    --text-lg: 18px;
    --text-xl: 20px;
    --text-2xl: 24px;
    --text-3xl: 32px;
    --text-4xl: 40px;
    --text-5xl: 48px;
    
    /* 字重规范 */
    --font-light: 300;
    --font-normal: 400;
    --font-medium: 500;
    --font-bold: 700;
    
    /* 行高规范 */
    --leading-tight: 1.25;
    --leading-normal: 1.6;
    --leading-relaxed: 1.75;
}

body {
    font-family: var(--font-primary);
    font-size: var(--text-base);
    font-weight: var(--font-normal);
    line-height: var(--leading-normal);
    color: #333;
    background-color: #f9f9f9;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* 标题字体规范 */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-primary);
    font-weight: var(--font-bold);
    line-height: var(--leading-tight);
    color: #2c3e50;
}

h1 { font-size: var(--text-5xl); }
h2 { font-size: var(--text-3xl); }
h3 { font-size: var(--text-2xl); }
h4 { font-size: var(--text-xl); }
h5 { font-size: var(--text-lg); }
h6 { font-size: var(--text-base); }

/* 段落文字 */
p {
    font-size: var(--text-base);
    line-height: var(--leading-relaxed);
}

/* 小字说明 */
small, .text-small {
    font-size: var(--text-sm);
}

/* 标签文字 */
.text-xs {
    font-size: var(--text-xs);
}

/* 装饰性文字（毛笔字） */
.font-display {
    font-family: var(--font-display);
}

/* 等宽字体（代码、数据） */
.font-mono {
    font-family: var(--font-mono);
}

/* 字重工具类 */
.font-light { font-weight: var(--font-light); }
.font-normal { font-weight: var(--font-normal); }
.font-medium { font-weight: var(--font-medium); }
.font-bold { font-weight: var(--font-bold); }

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

/* 导航栏 */
.navbar {
    background-color: #fff;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
}

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

.logo {
    font-size: var(--text-4xl);
    font-weight: var(--font-bold);
    color: #2c3e50;
    font-family: var(--font-primary);
    display: flex;
    align-items: baseline;
    gap: 10px;
    letter-spacing: -0.5px;
}

.logo-subtitle {
    font-size: var(--text-sm);
    font-weight: var(--font-normal);
    color: #666;
    line-height: 1;
}

.nav-links {
    display: flex;
    list-style: none;
}

.nav-links li {
    margin-left: 30px;
}

.nav-links a {
    text-decoration: none;
    color: #333;
    font-size: var(--text-base);
    font-weight: var(--font-medium);
    transition: color 0.3s ease;
    position: relative;
    letter-spacing: 0.3px;
}

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

/* 当前页面导航高亮 */
.nav-links a.active {
    color: #3498db;
}

.nav-links a.active::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    right: 0;
    height: 2px;
    background-color: #3498db;
}

/* 移动端菜单按钮 */
.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    font-size: var(--text-2xl);
    color: #333;
    cursor: pointer;
    padding: 8px;
    border-radius: 8px;
    transition: all 0.3s ease;
    z-index: 1001;
}

.mobile-menu-btn:hover {
    background-color: rgba(0,0,0,0.05);
}

.mobile-menu-btn:active {
    transform: scale(0.95);
}

@media (max-width: 768px) {
    .mobile-menu-btn {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 44px;
        height: 44px;
    }
    
    .nav-links {
        position: fixed;
        top: 70px;
        left: 0;
        right: 0;
        background-color: white;
        flex-direction: column;
        align-items: center;
        padding: 20px 0;
        box-shadow: 0 4px 12px rgba(0,0,0,0.15);
        transform: translateY(-150%);
        opacity: 0;
        pointer-events: none;
        transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
        z-index: 999;
        border-radius: 0 0 20px 20px;
    }
    
    .nav-links.active {
        transform: translateY(0);
        opacity: 1;
        pointer-events: all;
    }
    
    .nav-links li {
        margin: 8px 0;
        width: 100%;
        text-align: center;
    }
    
    .nav-links a {
        display: block;
        padding: 12px 20px;
        font-size: var(--text-lg);
        font-weight: var(--font-medium);
        transition: all 0.3s ease;
    }
    
    .nav-links a:hover {
        background-color: rgba(52, 152, 219, 0.1);
        color: #3498db;
    }
    
    .nav-links a.active {
        background-color: rgba(52, 152, 219, 0.15);
    }
    
    .nav-links a.active::after {
        display: none;
    }
}

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

.hero h1 {
    font-size: var(--text-5xl);
    font-weight: var(--font-bold);
    margin-bottom: 10px;
    letter-spacing: -0.5px;
}

.hero h2 {
    font-size: var(--text-3xl);
    font-weight: var(--font-bold);
    margin-bottom: 15px;
}

.hero p {
    font-size: var(--text-xl);
    font-weight: var(--font-normal);
    margin-bottom: 30px;
    opacity: 0.9;
    line-height: var(--leading-relaxed);
}

/* 首页Hero区域图片样式 */
.hero-image-container {
    margin-top: 40px;
    text-align: center;
}

.hero-image {
    width: 100%;
    max-width: 600px;
    height: auto;
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.15);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hero-image:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 32px rgba(0,0,0,0.2);
}

/* 海报展示区域样式 */
.poster-section {
    padding: 60px 0;
    background-color: #f8f9fa;
}

.poster-section-dark {
    padding: 60px 0;
    background-color: #1a1a2e;
}

.poster-container {
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}

.poster-image {
    width: 100%;
    max-width: 500px;
    height: auto;
    border-radius: 16px;
    box-shadow: 0 8px 32px rgba(0,0,0,0.2);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.poster-image:hover {
    transform: scale(1.02);
    box-shadow: 0 12px 40px rgba(0,0,0,0.3);
}

.btn {
    display: inline-block;
    background-color: white;
    color: #667eea;
    padding: 12px 30px;
    border-radius: 50px;
    text-decoration: none;
    font-size: var(--text-base);
    font-weight: var(--font-medium);
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
}

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

/* 通用 section 样式 */
.section {
    padding: 80px 0;
}

.section h2 {
    text-align: center;
    margin-bottom: 40px;
    font-size: var(--text-3xl);
    font-weight: var(--font-bold);
    color: #2c3e50;
    position: relative;
    letter-spacing: -0.3px;
}

.section h2::after {
    content: '';
    display: block;
    width: 80px;
    height: 3px;
    background-color: #3498db;
    margin: 15px auto 0;
}

.content {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
}

.content p {
    font-size: var(--text-lg);
    line-height: var(--leading-relaxed);
    color: #555;
}

/* 浅色背景 */
.bg-light {
    background-color: #f8f9fa;
}

/* 软件特点 */
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    margin-top: 50px;
}

.feature-item {
    background-color: white;
    padding: 40px 20px;
    border-radius: 10px;
    text-align: center;
    box-shadow: 0 4px 6px rgba(0,0,0,0.05);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.feature-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
}

.icon {
    font-size: 48px;
    color: #3498db;
    margin-bottom: 20px;
}

.feature-item h3 {
    font-size: var(--text-xl);
    font-weight: var(--font-bold);
    margin-bottom: 15px;
    color: #2c3e50;
}

.feature-item p {
    font-size: var(--text-base);
    color: #666;
    line-height: var(--leading-relaxed);
}

/* 联系我们 */
.email {
    font-size: var(--text-lg);
    font-weight: var(--font-medium);
    margin-top: 15px;
    color: #3498db;
}

/* 页脚 */
.footer {
    background-color: #2c3e50;
    color: white;
    text-align: center;
    padding: 30px 0;
}

.footer p {
    margin: 0;
    font-size: var(--text-base);
    font-weight: var(--font-normal);
}

.footer a {
    color: #3498db;
    text-decoration: none;
}

.footer a:hover {
    text-decoration: underline;
}

/* 返回顶部按钮 */
#back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background-color: #3498db;
    color: white;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    font-size: 20px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 999;
}

#back-to-top.visible {
    opacity: 1;
    visibility: visible;
}

#back-to-top:hover {
    background-color: #2980b9;
    transform: translateY(-3px);
    box-shadow: 0 6px 16px rgba(0,0,0,0.2);
}

@media (max-width: 768px) {
    #back-to-top {
        width: 45px;
        height: 45px;
        font-size: 18px;
        bottom: 20px;
        right: 20px;
    }
}

#back-to-top:hover {
    background-color: #2980b9;
    transform: translateY(-3px);
    box-shadow: 0 6px 16px rgba(0,0,0,0.2);
}

/* 弹窗样式 */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0,0,0,0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    padding: 20px;
}

.modal.visible {
    opacity: 1;
    visibility: visible;
}

.modal-content {
    background-color: white;
    border-radius: 12px;
    max-width: 500px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    transform: scale(0.9);
    transition: transform 0.3s ease;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
}

.modal.visible .modal-content {
    transform: scale(1);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 25px;
    border-bottom: 1px solid #eee;
}

.modal-header h3 {
    margin: 0;
    color: #2c3e50;
    font-size: 20px;
}

.modal-close {
    background: none;
    border: none;
    font-size: 28px;
    color: #999;
    cursor: pointer;
    line-height: 1;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.modal-close:hover {
    background-color: #f5f5f5;
    color: #333;
}

.modal-body {
    padding: 25px;
}

.modal-price {
    font-size: var(--text-2xl);
    font-weight: var(--font-bold);
    color: #e74c3c;
    margin-bottom: 15px;
}

/* 表单样式 */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    color: #333;
    font-weight: 500;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 16px;
    transition: border-color 0.3s ease;
    font-family: inherit;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

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

.form-actions {
    display: flex;
    gap: 15px;
    margin-top: 25px;
}

.form-actions button {
    flex: 1;
    padding: 12px 20px;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-primary {
    background-color: #3498db;
    color: white;
    border: none;
}

.btn-primary:hover {
    background-color: #2980b9;
}

.btn-secondary {
    background-color: #f8f9fa;
    color: #666;
    border: 1px solid #ddd;
}

.btn-secondary:hover {
    background-color: #e9ecef;
}

.contact-info {
    margin-top: 25px;
    padding-top: 20px;
    border-top: 1px solid #eee;
    color: #666;
}

.contact-info p {
    margin: 8px 0;
}

.contact-info i {
    color: #3498db;
    margin-right: 8px;
    width: 20px;
}

/* Toast提示 */
.toast {
    position: fixed;
    top: 100px;
    left: 50%;
    transform: translateX(-50%) translateY(-20px);
    background-color: #27ae60;
    color: white;
    padding: 15px 30px;
    border-radius: 50px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    z-index: 3000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 10px;
}

.toast.visible {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

.toast i {
    font-size: 20px;
}

/* 滚动动画 */
.fade-in {
    animation: fadeIn 0.6s ease forwards;
}

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

/* 页面加载动画 */
body.loaded .hero {
    animation: heroFadeIn 0.8s ease forwards;
}

@keyframes heroFadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* 响应式优化 */
@media (max-width: 768px) {
    :root {
        --text-5xl: 36px;
        --text-4xl: 32px;
        --text-3xl: 28px;
        --text-2xl: 22px;
        --text-xl: 18px;
    }
    
    .logo {
        font-size: var(--text-3xl);
    }
    
    .hero {
        padding: 120px 0 80px;
    }
    
    .hero h1 {
        font-size: var(--text-4xl);
    }
    
    .hero p {
        font-size: var(--text-lg);
    }
    
    .hero-image {
        max-width: 90%;
    }
    
    .poster-image {
        max-width: 90%;
    }
    
    .poster-section,
    .poster-section-dark {
        padding: 40px 0;
    }
    
    .section {
        padding: 60px 0;
    }
    
    .section h2 {
        font-size: var(--text-2xl);
    }
    
    .features-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .modal-content {
        margin: 10px;
        max-height: 95vh;
    }
    
    .form-actions {
        flex-direction: column;
    }
    
    #back-to-top {
        width: 45px;
        height: 45px;
        font-size: 18px;
        bottom: 20px;
        right: 20px;
    }
}

@media (max-width: 480px) {
    :root {
        --text-5xl: 28px;
        --text-4xl: 26px;
        --text-3xl: 24px;
        --text-2xl: 20px;
        --text-xl: 16px;
        --text-base: 15px;
    }
    
    .logo {
        font-size: var(--text-2xl);
    }
    
    .nav-links li {
        margin-left: 20px;
    }
    
    .hero h1 {
        font-size: var(--text-3xl);
    }
    
    .section h2 {
        font-size: var(--text-xl);
    }
}
