/* 基础样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f5f5f5;
}

.container {
    max-width: 1160px;
    margin: 0 auto;
    padding: 0 1rem;
}

/* 头部样式 - 优化版 */
.header {
    background: #fff;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.navbar {
    padding: 1rem 0;
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
}

.navbar-brand {
    display: flex;
    align-items: center;
    z-index: 1001;
}

.brand-link {
    display: flex;
    align-items: center;
    text-decoration: none;
    color: #333;
}

.brand-text {
    font-size: 1.5rem;
    font-weight: 700;
    color: #2c3e50;
}

/* 移动端菜单按钮 */
.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    gap: 4px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 8px;
    z-index: 1001;
}

.mobile-menu-toggle span {
    display: block;
    width: 25px;
    height: 3px;
    background: #2c3e50;
    border-radius: 3px;
    transition: all 0.3s ease;
}

.mobile-menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(6px, 6px);
}

.mobile-menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.mobile-menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(6px, -6px);
}

/* 导航菜单 */
.navbar-menu {
    display: flex;
    gap: 2rem;
    align-items: center;
}

.nav-link {
    text-decoration: none;
    color: #555;
    font-weight: 500;
    font-size: 0.95rem;
    transition: color 0.3s;
    white-space: nowrap;
}

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

/* 导航右侧操作区 */
.navbar-actions {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.header-search {
    display: flex;
    align-items: center;
    background: #f5f5f5;
    border-radius: 20px;
    padding: 0.4rem 1rem;
    transition: all 0.3s;
}

.header-search:focus-within {
    background: #e8e8e8;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.search-input {
    border: none;
    background: transparent;
    outline: none;
    padding: 0.3rem;
    width: 180px;
    font-size: 0.9rem;
}

.search-btn {
    border: none;
    background: transparent;
    cursor: pointer;
    font-size: 1rem;
    padding: 0;
}

.btn {
    padding: 0.6rem 1.5rem;
    border-radius: 25px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s;
    border: none;
    cursor: pointer;
    font-size: 0.9rem;
    white-space: nowrap;
}

.btn-primary {
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
    color: #fff;
}

.btn-primary:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(52, 152, 219, 0.3);
}

/* 平板设备 (768px - 1024px) */
@media (max-width: 1024px) {
    .navbar-menu {
        gap: 1.2rem;
    }

    .nav-link {
        font-size: 0.9rem;
    }

    .search-input {
        width: 140px;
    }
}

/* 移动端 (最大768px) */
@media (max-width: 768px) {
    .mobile-menu-toggle {
        display: flex;
    }

    .navbar .container {
        flex-wrap: nowrap;
    }

    /* 移动端菜单样式 */
    .navbar-menu {
        position: fixed;
        top: 0;
        right: -100%;
        width: 280px;
        height: 100vh;
        background: #fff;
        flex-direction: column;
        align-items: flex-start;
        gap: 0;
        padding: 80px 0 20px 0;
        box-shadow: -2px 0 10px rgba(0, 0, 0, 0.1);
        transition: right 0.3s ease;
        overflow-y: auto;
        z-index: 1000;
    }

    .navbar-menu.active {
        right: 0;
    }

    .nav-link {
        width: 100%;
        padding: 1rem 2rem;
        border-bottom: 1px solid #f0f0f0;
    }

    .navbar-actions {
        position: fixed;
        bottom: 0;
        right: -100%;
        width: 280px;
        background: #fff;
        flex-direction: column;
        gap: 0.8rem;
        padding: 1.5rem;
        border-top: 1px solid #f0f0f0;
        box-shadow: -2px 0 10px rgba(0, 0, 0, 0.1);
        transition: right 0.3s ease;
        z-index: 1000;
    }

    .navbar-actions.active {
        right: 0;
    }

    .header-search {
        width: 100%;
        border-radius: 12px;
    }

    .search-input {
        width: 100%;
    }

    .btn-primary {
        width: 100%;
        text-align: center;
        padding: 0.8rem 1.5rem;
    }

    /* 移动端遮罩层 */
    .navbar-menu.active::before,
    .navbar-actions.active::before {
        content: '';
        position: fixed;
        top: 0;
        left: 0;
        width: 100vw;
        height: 100vh;
        background: rgba(0, 0, 0, 0.5);
        z-index: -1;
    }
}

/* 小屏手机 (最大480px) */
@media (max-width: 480px) {
    .brand-text {
        font-size: 1.2rem;
    }

    .navbar-menu,
    .navbar-actions {
        width: 100%;
        right: -100%;
    }

    .navbar-menu.active,
    .navbar-actions.active {
        right: 0;
    }
}

/* 内容模块 */
.lead-paragraph {
    font-size: 1.05rem;
    margin-bottom: 1.5rem;
    color: #4a4a4a;
}

.info-card,
.tips-card {
    background: #fff;
    border-radius: 16px;
    padding: 1.8rem;
    margin-bottom: 1.5rem;
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.06);
}

.info-card h2,
.tips-card h2 {
    margin-bottom: 0.8rem;
    font-size: 1.3rem;
    color: #1f2d3d;
}

.key-points,
.tips-card ul,
.feature-list,
.sitemap-list {
    list-style: none;
    padding-left: 0;
    margin: 0;
}

.key-points li,
.tips-card li,
.feature-list li,
.sitemap-list li {
    position: relative;
    padding-left: 1.4rem;
    margin-bottom: 0.4rem;
    line-height: 1.6;
}

.key-points li::before,
.tips-card li::before,
.feature-list li::before {
    content: "•";
    position: absolute;
    left: 0;
    color: #3498db;
}

.software-grid {
    margin-bottom: 2rem;
}

.software-grid h2 {
    margin-bottom: 1rem;
}

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

.software-item {
    background: linear-gradient(180deg, #ffffff 0%, #f9fbff 100%);
    border-radius: 16px;
    padding: 1.2rem;
    border: 1px solid #e6ecf3;
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
}

.software-item h3 {
    font-size: 1.1rem;
    color: #1f2d3d;
}

.software-item .download-btn {
    margin-top: auto;
}

.sitemap-list {
    columns: 2;
    column-gap: 2rem;
}

.keyword-cloud {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    align-items: center;
    margin-top: 1rem;
}

.keyword-cloud strong {
    font-size: 0.95rem;
    color: #6b7280;
    margin-right: 0.5rem;
}

.keyword-tag {
    background: rgba(52, 152, 219, 0.12);
    color: #1d4ed8;
    padding: 0.2rem 0.85rem;
    border-radius: 999px;
    font-size: 0.85rem;
    border: 1px solid rgba(52, 152, 219, 0.2);
}

/* 页面头部 */
.page-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: #fff;
    padding: 4rem 0 3rem;
    text-align: center;
}

.page-header h1 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.page-subtitle {
    font-size: 1.2rem;
    opacity: 0.9;
}

/* 主要内容 */
.main {
    padding: 3rem 0;
}

.page-content {
    background: #fff;
    border-radius: 12px;
    padding: 3rem;
    margin: 2rem auto;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
}

/* 下载页面样式 */
.download-page {
    max-width: 1160px;
    margin: 0 auto;
    line-height: 1.7;
}

.download-page h1 {
    color: #2c3e50;
    font-size: 2rem;
    margin-bottom: 1rem;
    text-align: center;
}

.download-page h2 {
    color: #34495e;
    font-size: 1.4rem;
    margin: 2.5rem 0 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid #3498db;
}

.download-page h3 {
    color: #2c3e50;
    font-size: 1.1rem;
    margin: 1rem 0 0.5rem;
}

.version-item {
    background: #fff;
    border-radius: 12px;
    padding: 2.5rem;
    margin: 3rem 0;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    border-left: 5px solid #27ae60;
    line-height: 1.6;
}

.version-item.current {
    border-left-color: #27ae60;
    background: #f8fff8;
}

.version-item.history {
    border-left-color: #3498db;
}

.version-item.old {
    border-left-color: #95a5a6;
    background: #fafafa;
}

.download-buttons {
    margin: 1.5rem 0;
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.download-btn {
    display: flex;
    align-items: center;
    padding: 1.5rem 2rem;
    border-radius: 12px;
    text-decoration: none;
    font-weight: 700;
    transition: all 0.3s;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
    border: 2px solid transparent;
}

.download-btn.official {
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    color: #fff;
}

.download-btn.green {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: #fff;
}

.download-btn:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.2);
    color: #fff;
}

.download-btn .btn-icon {
    font-size: 1.5rem;
    margin-right: 1rem;
}

.download-btn .btn-text {
    font-size: 1.1rem;
    font-weight: 700;
}

.download-btn.disabled {
    background: #bdc3c7;
    color: #7f8c8d;
    cursor: not-allowed;
}

.download-btn.disabled:hover {
    transform: none;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
}

.update-notes {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 1.5rem;
    margin: 1.5rem 0;
}

.update-notes ol {
    margin: 0;
    padding-left: 1.5rem;
}

.update-notes li {
    margin: 0.8rem 0;
    line-height: 1.7;
}

.info-section {
    background: #e8f4fd;
    border-radius: 10px;
    padding: 2rem;
    margin: 3rem 0;
    border-left: 5px solid #2196f3;
    line-height: 1.7;
}

.info-section h2 {
    border-bottom: none;
    margin-top: 1.5rem;
}

.info-section h2:first-child {
    margin-top: 0;
}

.info-section ul {
    margin: 1rem 0;
    padding-left: 2rem;
}

.info-section li {
    margin: 0.5rem 0;
}

/* 页脚样式 */
.footer {
    background: #2c3e50;
    color: #ecf0f1;
    padding: 3rem 0 1rem;
    margin-top: 4rem;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-section h3,
.footer-section h4 {
    color: #fff;
    margin-bottom: 1rem;
}

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

.footer-section li {
    margin: 0.5rem 0;
}

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

.footer-section a:hover {
    color: #3498db;
}

.footer-bottom {
    border-top: 1px solid #34495e;
    padding-top: 1.5rem;
    text-align: center;
    color: #95a5a6;
}

.footer-links {
    margin-top: 1rem;
}

.footer-links a {
    color: #95a5a6;
    text-decoration: none;
    transition: color 0.3s;
}

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

.separator {
    margin: 0 1rem;
    color: #7f8c8d;
}

/* 移动端优化 */
@media (max-width: 768px) {
    .container {
        padding: 0 1.2rem;
    }

    .software-list {
        grid-template-columns: 1fr;
    }

    .sitemap-list {
        columns: 1;
    }

    .page-header {
        padding: 3rem 0 2rem;
    }

    .page-header h1 {
        font-size: 1.8rem;
    }

    .page-subtitle {
        font-size: 1rem;
    }

    .page-content {
        padding: 1.5rem;
    }

    .download-buttons {
        flex-direction: column;
    }

    .download-btn {
        width: 100%;
        justify-content: center;
    }

    .footer-content {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .page-header h1 {
        font-size: 1.5rem;
    }

    .version-item {
        padding: 1.5rem;
    }

    .download-btn {
        padding: 1.2rem 1.5rem;
    }
}
