/* 全局样式重置和变量 */
:root {
    /* 主色调 */
    --primary-color: #0052CC;
    --accent-color: #36B37E;
    
    /* 文字颜色系统 */
    --text-primary: #1A1A1A;        /* 主要文字 */
    --text-secondary: #666666;      /* 次要文字 */
    --text-tertiary: #999999;       /* 辅助文字 */
    --text-white: #FFFFFF;          /* 白色文字 */
    
    /* 背景色系统 */
    --background: #F8F9FA;
    --card-bg: #FFFFFF;
    --background-light: #F4F5F7;
    
    /* 边框和阴影 */
    --border-color: #E8E8E8;
    --card-shadow: 0 1px 3px rgba(0,0,0,0.08);
    --hover-shadow: 0 4px 12px rgba(0,0,0,0.1);
    
    /* 字体系统 */
    --font-family: -apple-system, BlinkMacSystemFont, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "微软雅黑", sans-serif;
    --font-size-base: 16px;
    --font-size-sm: 14px;
    --font-size-xs: 12px;
    --font-size-lg: 18px;
    --font-size-xl: 20px;
    --font-size-2xl: 24px;
    
    /* 行高 */
    --line-height-base: 1.6;
    --line-height-tight: 1.4;
    
    /* 间距 */
    --spacing-unit: 8px;
    --border-radius: 4px;
    --transition-speed: 0.3s;
}

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

body {
    font-family: var(--font-family);
    font-size: var(--font-size-base);
    line-height: var(--line-height-base);
    color: var(--text-primary);
    background: var(--background);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

/* 标题样式 */
h1 {
    font-size: var(--font-size-2xl);
    font-weight: 600;
    line-height: var(--line-height-tight);
    color: var(--text-primary);
    margin-bottom: 1rem;
}

h2 {
    font-size: var(--font-size-xl);
    font-weight: 600;
    line-height: var(--line-height-tight);
    color: var(--text-primary);
    margin-bottom: 0.875rem;
}

h3 {
    font-size: var(--font-size-lg);
    font-weight: 500;
    line-height: var(--line-height-tight);
    color: var(--text-primary);
    margin-bottom: 0.75rem;
}

h4 {
    font-size: var(--font-size-base);
    font-weight: 500;
    line-height: var(--line-height-tight);
    color: var(--text-primary);
    margin-bottom: 0.625rem;
}

h5 {
    font-size: var(--font-size-sm);
    font-weight: 500;
    line-height: var(--line-height-tight);
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

h6 {
    font-size: var(--font-size-xs);
    font-weight: 500;
    line-height: var(--line-height-tight);
    color: var(--text-tertiary);
    margin-bottom: 0.5rem;
}

/* 正文样式 */
p {
    font-size: var(--font-size-base);
    line-height: var(--line-height-base);
    color: var(--text-secondary);
}

/* 导航栏样式 */
header {
    background-color: var(--card-bg);
    box-shadow: var(--card-shadow);
    padding: 1rem 0;
    width: 100%;
    position: fixed;
    top: 0;
    left: 0;
    z-index: 1000;
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

.logo {
    display: flex;
    align-items: center;
}

.logo-link {
    display: flex;
    align-items: center;
    text-decoration: none;
    color: var(--primary-color);
}

.logo-image {
    width: 40px;
    height: 40px;
    margin-right: 0.5rem;
}

.logo-text {
    color: var(--primary-color);
    font-size: var(--font-size-xl);
    font-weight: 600;
}

.logo h1 {
    color: var(--primary-color);
    font-size: var(--font-size-xl);
    font-weight: 600;
    margin: 0;
}

/* 桌面端导航菜单 */
.nav-links {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
    gap: 0.5rem;
    flex-wrap: nowrap;
}

.nav-links li {
    white-space: nowrap;
    margin: 0;
    padding: 0;
}

.nav-links a {
    color: var(--text-primary);
    text-decoration: none;
    font-size: 0.8rem;
    font-weight: 500;
    transition: color 0.3s ease;
    padding: 0.5rem 0.3rem;
    position: relative;
    white-space: nowrap;
    display: block;
}

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

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

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

.nav-links a.active-nav {
    color: var(--primary-color);
    font-weight: 600;
}

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

/* 主要内容样式 */
main {
    margin-top: 80px; /* 导航栏高度 */
    padding: 1rem;
}

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

.tool-section {
    margin-bottom: 2rem;
}

.section-tip {
    background: #f0f7ff;
    border-left: 4px solid var(--primary-color);
    padding: 0.75rem 1rem;
    margin-bottom: 1rem;
    border-radius: 4px;
}

.section-tip p {
    color: var(--primary-color);
    font-size: var(--font-size-sm);
    margin: 0;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.tool-section h2 {
    font-size: 1.25rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.tool-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1rem;
}

.tool-item {
    display: flex;
    align-items: center;
    padding: 0.75rem;
    background: var(--card-bg);
    border-radius: 6px;
    text-decoration: none;
    color: var(--text-primary);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.tool-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.tool-logo {
    width: 32px;
    height: 32px;
    margin-right: 0.75rem;
    flex-shrink: 0;
}

.tool-logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.tool-info h3 {
    font-size: var(--font-size-base);
    font-weight: 500;
    color: var(--text-primary);
    margin-bottom: 0.25rem;
}

.tool-info p {
    font-size: var(--font-size-sm);
    color: var(--text-secondary);
}

/* 页脚样式 */
footer {
    background: var(--card-bg);
    padding: 1rem;
    text-align: center;
    margin-top: 2rem;
}

.footer-content p {
    font-size: var(--font-size-sm);
    color: var(--text-tertiary);
}

/* 响应式设计 */
@media (max-width: 768px) {
    nav {
        padding: 0 1rem;
        flex-wrap: wrap;
    }
    
    .logo-image {
        width: 36px;
        height: 36px;
    }
    
    .logo-text {
        font-size: var(--font-size-lg);
    }

    .tool-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    }

    h1 {
        font-size: calc(var(--font-size-2xl) - 2px);
    }
    h2 {
        font-size: calc(var(--font-size-xl) - 2px);
    }
    h3 {
        font-size: calc(var(--font-size-lg) - 1px);
    }
    h4 {
        font-size: calc(var(--font-size-base) - 1px);
    }
    h5 {
        font-size: calc(var(--font-size-sm) - 1px);
    }
    h6 {
        font-size: calc(var(--font-size-xs) - 1px);
    }
}

@media (max-width: 480px) {
    h1 {
        font-size: calc(var(--font-size-2xl) - 4px);
    }
    h2 {
        font-size: calc(var(--font-size-xl) - 4px);
    }
    h3 {
        font-size: calc(var(--font-size-lg) - 2px);
    }
    h4 {
        font-size: calc(var(--font-size-base) - 2px);
    }
    h5 {
        font-size: calc(var(--font-size-sm) - 2px);
    }
    h6 {
        font-size: calc(var(--font-size-xs) - 2px);
    }

    .tool-grid {
        grid-template-columns: 1fr;
    }

    .news-date,
    .update-date {
        font-size: 0.75rem;
    }

    .news-title,
    .update-title {
        font-size: 0.85rem;
    }
}

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

.card {
    animation: fadeInUp 0.6s ease-out;
}

/* 评分样式 */
.card-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: calc(var(--spacing-unit) * 3);
}

.rating {
    display: flex;
    align-items: center;
    gap: calc(var(--spacing-unit));
}

.rating i {
    color: #FFB400;
    font-size: 0.875rem;
}

.rating span {
    color: var(--text-secondary);
    font-size: 0.875rem;
    font-weight: 500;
}

/* 社交媒体链接样式 */
.social-links {
    display: flex;
    gap: calc(var(--spacing-unit) * 2);
    margin-top: calc(var(--spacing-unit) * 3);
}

.social-links a {
    color: rgba(255,255,255,0.7);
    font-size: 1.25rem;
    transition: all var(--transition-speed) ease;
}

.social-links a:hover {
    color: white;
    transform: translateY(-2px);
}

/* 网格布局优化 */
.grid-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 0.75rem;
    padding: 0.5rem;
    max-width: 1400px;
    margin: 0 auto;
}

.grid-section {
    background: var(--card-bg);
    border-radius: 6px;
    padding: 0.75rem;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.grid-section h2 {
    font-size: 1.25rem;
    margin-bottom: 0.75rem;
    color: var(--text-primary);
    text-align: center;
}

.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 0.5rem;
}

/* 紧凑型卡片样式优化 */
.card.compact {
    padding: 0.5rem;
    margin: 0;
    background: var(--background-white);
    border-radius: 4px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.card.compact .card-logo {
    width: 24px;
    height: 24px;
    margin-bottom: 0.25rem;
}

.card.compact .card-logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.card.compact h3 {
    font-size: 0.9rem;
    margin-bottom: 0.25rem;
    color: var(--text-primary);
}

.card.compact p {
    font-size: 0.8rem;
    margin-bottom: 0.5rem;
    color: var(--text-secondary);
}

.card.compact .card-footer {
    margin-top: 0.25rem;
    padding-top: 0.25rem;
    border-top: 1px solid rgba(0, 0, 0, 0.05);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.card.compact .btn {
    padding: 0.25rem 0.5rem;
    font-size: 0.8rem;
}

.card.compact .rating {
    font-size: 0.75rem;
}

.card.compact .rating i {
    font-size: 0.75rem;
    color: #FFB400;
}

/* 响应式优化 */
@media (max-width: 768px) {
    .grid-container {
        grid-template-columns: 1fr;
        padding: 0.25rem;
    }

    .grid-section {
        padding: 0.5rem;
    }

    .card-grid {
        grid-template-columns: 1fr;
    }

    .card.compact {
        padding: 0.5rem;
    }
}

/* FAQ样式 */
.faq-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

.faq-item {
    background: var(--card-bg);
    border-radius: 8px;
    margin-bottom: 0.5rem;
    padding: 1rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.faq-item:hover {
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.15);
    transform: translateY(-1px);
}

.faq-item h3 {
    font-size: var(--font-size-base);
    font-weight: 500;
    color: var(--text-primary);
    margin: 0;
    padding: 0;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.faq-item h3::after {
    content: '+';
    font-size: 1.2rem;
    color: var(--text-primary);
}

.faq-item.active h3::after {
    content: '-';
}

.faq-answer {
    color: var(--text-secondary);
    line-height: 1.5;
    font-size: var(--font-size-sm);
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
    margin-top: 0;
}

.faq-item.active .faq-answer {
    max-height: 1000px;
    margin-top: 0.75rem;
}

.faq-answer p {
    margin-bottom: 0.75rem;
}

.faq-answer ul {
    margin: 0.25rem 0 0.75rem 1.25rem;
    padding: 0;
}

.faq-answer li {
    margin-bottom: 0.25rem;
    list-style-type: disc;
    font-size: var(--font-size-sm);
    color: var(--text-secondary);
}

@media (max-width: 768px) {
    .faq-item {
        padding: 0.75rem;
    }
    
    .faq-item h3 {
        font-size: 0.95rem;
    }
}

/* 新增功能板块样式 */
.content-section {
    padding: 2rem 0;
}

.news-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
    margin-top: 1rem;
}

.news-item {
    background: var(--card-bg);
    border-radius: 8px;
    padding: 1.5rem;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.news-item h3 {
    color: var(--primary-color);
    margin-bottom: 1rem;
    font-size: 1.2rem;
}

.news-list, .updates-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.news-list li, .updates-list li {
    margin-bottom: 0.75rem;
}

.news-list a, .updates-list a {
    display: flex;
    flex-direction: column;
    color: var(--text-primary);
    text-decoration: none;
    transition: color 0.3s ease;
}

.news-list a:hover, .updates-list a:hover {
    color: var(--primary-color);
}

.news-date, .update-date {
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin-bottom: 0.25rem;
}

.news-title, .update-title {
    font-size: 0.95rem;
}

.tutorial-section {
    margin: 2rem 0;
    padding: 2rem 0;
}

.tutorial-section h2 {
    font-size: var(--font-size-xl);
    color: var(--text-primary);
    margin-bottom: 1.5rem;
    text-align: center;
}

.tutorial-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
    padding: 0 1rem;
}

.tutorial-item {
    background: var(--card-bg);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    box-shadow: var(--card-shadow);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.tutorial-item:hover {
    transform: translateY(-2px);
    box-shadow: var(--hover-shadow);
}

.tutorial-item h3 {
    font-size: var(--font-size-lg);
    color: var(--text-primary);
    margin-bottom: 1rem;
    font-weight: 600;
}

.tutorial-item ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.tutorial-item li {
    margin-bottom: 0.75rem;
    position: relative;
    padding-left: 1.5rem;
}

.tutorial-item li::before {
    content: '•';
    position: absolute;
    left: 0;
    color: var(--primary-color);
}

.tutorial-item a {
    color: var(--text-primary);
    text-decoration: none;
    font-size: var(--font-size-base);
    transition: color 0.3s ease;
    display: block;
}

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

.more-link {
    display: inline-flex;
    align-items: center;
    color: var(--primary-color);
    text-decoration: none;
    font-size: var(--font-size-sm);
    margin-top: 1rem;
    transition: color 0.3s ease;
}

.more-link i {
    margin-left: 0.5rem;
    transition: transform 0.3s ease;
}

.more-link:hover {
    color: var(--accent-color);
}

.more-link:hover i {
    transform: translateX(4px);
}

/* 移动端导航栏优化 */
.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--primary-color);
    cursor: pointer;
    padding: 0.5rem;
    transition: all 0.3s ease;
}

.mobile-menu-btn i {
    transition: transform 0.3s ease;
}

.menu-icon {
    display: inline-block;
    transition: all 0.3s ease;
}

.fa-times {
    transform: rotate(90deg);
}

.mobile-menu-btn:focus {
    outline: none;
}

@media (max-width: 768px) {
    .mobile-menu-btn {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 40px;
        height: 40px;
        border-radius: 50%;
        background-color: rgba(0, 82, 204, 0.1);
        transition: all 0.3s ease;
    }
    
    .mobile-menu-btn:active {
        background-color: rgba(0, 82, 204, 0.2);
        transform: scale(0.95);
    }

    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--card-bg);
        border-radius: 0 0 12px 12px;
        padding: 0;
        box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
        flex-direction: column;
        max-height: 80vh;
        overflow-y: auto;
        transform: translateY(-10px);
        opacity: 0;
        transition: all 0.3s ease;
        z-index: 9999;
        gap: 0;
    }

    .nav-links li {
        margin: 0;
        padding: 0;
        display: block;
        width: 100%;
        border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    }
    
    .nav-links li:last-child {
        border-bottom: none;
    }

    .nav-links.active {
        display: flex;
        transform: translateY(0);
        opacity: 1;
        animation: slideDown 0.3s forwards;
    }
    
    @keyframes slideDown {
        0% {
            transform: translateY(-15px);
            opacity: 0;
        }
        100% {
            transform: translateY(0);
            opacity: 1;
        }
    }

    .nav-links a {
        padding: 0.75rem 1rem;
        width: 100%;
        text-align: left;
        border-radius: 0;
        margin: 0;
        font-weight: 500;
        color: var(--text-primary);
        position: relative;
        display: block;
        align-items: center;
        transition: all 0.2s ease;
        transform: translateX(0);
        line-height: 1.3;
    }
    
    .nav-links a::before {
        content: '';
        display: inline-block;
        width: 6px;
        height: 6px;
        background-color: var(--primary-color);
        border-radius: 50%;
        margin-right: 12px;
        opacity: 0.6;
    }
    
    .nav-links a:hover, .nav-links a:active, .nav-links a.active-nav {
        background-color: rgba(0, 82, 204, 0.08);
        color: var(--primary-color);
        transform: translateX(5px);
    }
    
    .nav-links a.active-nav {
        background-color: rgba(0, 82, 204, 0.15);
        font-weight: 600;
    }
    
    .nav-links a.active-nav::before {
        opacity: 1;
        background-color: var(--primary-color);
        width: 8px;
        height: 8px;
    }

    .nav-links a::after {
        display: none;
    }

    .tutorial-grid {
        grid-template-columns: 1fr;
    }

    .tutorial-item {
        padding: 1.25rem;
    }
}

@media (max-width: 480px) {
    .tutorial-item h3 {
        font-size: var(--font-size-base);
    }

    .tutorial-item a {
        font-size: var(--font-size-sm);
    }
}

/* 响应式调整 */
@media (max-width: 768px) {
    :root {
        --font-size-base: 15px;
        --font-size-sm: 13px;
        --font-size-xs: 11px;
        --font-size-lg: 17px;
        --font-size-xl: 19px;
        --font-size-2xl: 22px;
    }
}

@media (max-width: 480px) {
    :root {
        --font-size-base: 14px;
        --font-size-sm: 12px;
        --font-size-xs: 10px;
        --font-size-lg: 16px;
        --font-size-xl: 18px;
        --font-size-2xl: 20px;
    }
}

/* 导航链接点击后的滚动位置调整 */
html {
    scroll-padding-top: 80px; /* 导航栏高度 */
    scroll-behavior: smooth;
}

/* 移动端导航栏高度调整 */
@media (max-width: 768px) {
    header {
        padding: 0.5rem 0;
    }
    
    main {
        margin-top: 60px; /* 移动端导航栏高度 */
    }
    
    html {
        scroll-padding-top: 60px; /* 移动端导航栏高度 */
    }
} 