/* 响应式布局 - 移动端优先 */

/* 平板设备 (768px及以上) */
@media (max-width: 768px) {
    /* 导航栏 */
    .nav-menu {
        position: fixed;
        top: 70px;
        left: -100%;
        width: 100%;
        background: var(--bg-white);
        flex-direction: column;
        gap: 0;
        padding: 20px 0;
        box-shadow: var(--shadow);
        transition: left 0.3s;
    }

    .nav-menu.active {
        left: 0;
    }

    .nav-menu li {
        border-bottom: 1px solid var(--border-color);
    }

    .nav-menu a {
        display: block;
        padding: 15px 20px;
    }

    .nav-toggle {
        display: flex;
    }

    /* Hero区域 */
    .hero-title {
        font-size: 2rem;
    }

    .hero-subtitle {
        font-size: 1.1rem;
    }

    .hero-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .hero-actions .btn {
        width: 100%;
        text-align: center;
    }

    /* Section */
    .section {
        padding: 50px 0;
    }

    .section-title {
        font-size: 1.8rem;
    }

    /* 功能卡片 */
    .feature-grid {
        grid-template-columns: 1fr;
    }

    /* 下载卡片 */
    .download-grid {
        grid-template-columns: 1fr;
    }

    /* 二维码图片移动端优化 */
    .qrcode-image {
        width: 160px;
        height: 160px;
    }

    /* 步骤 */
    .step-item {
        flex-direction: column;
        text-align: center;
    }

    .step-number {
        margin: 0 auto;
    }

    /* 手风琴 */
    .accordion-header {
        padding: 20px;
    }

    .accordion-header h3 {
        font-size: 1.1rem;
    }

    .tutorial-list {
        padding-left: 30px;
    }

    /* 图片布局 */
    .step-images.multi {
        grid-template-columns: 1fr;
    }

    /* 灯箱 */
    .lightbox-prev {
        left: 10px;
    }

    .lightbox-next {
        right: 10px;
    }

    .lightbox-close {
        right: 20px;
        font-size: 2.5rem;
    }

    /* 页脚 */
    .footer-content {
        grid-template-columns: 1fr;
        gap: 30px;
    }

    /* 返回顶部 */
    .back-to-top {
        bottom: 20px;
        right: 20px;
        width: 45px;
        height: 45px;
    }
}

/* 小屏手机 (480px及以下) */
@media (max-width: 480px) {
    .hero {
        padding: 50px 0;
    }

    .hero-title {
        font-size: 1.6rem;
    }

    .hero-subtitle {
        font-size: 1rem;
    }

    .section-title {
        font-size: 1.5rem;
    }

    .feature-card,
    .download-card {
        padding: 25px 20px;
    }

    /* 小屏二维码 */
    .qrcode-image {
        width: 140px;
        height: 140px;
    }

    .step-item {
        padding: 20px;
    }

    .accordion-content > * {
        padding: 0 20px 20px;
    }

    .tutorial-list {
        padding-left: 20px;
        font-size: 0.95rem;
    }
}

/* 大屏幕 (1200px及以上) */
@media (min-width: 1200px) {
    .container {
        max-width: 1400px;
    }

    .hero-title {
        font-size: 3.5rem;
    }

    .section-title {
        font-size: 3rem;
    }
}

/* 触摸设备优化 */
@media (hover: none) and (pointer: coarse) {
    .btn,
    .preview-image,
    .accordion-header {
        -webkit-tap-highlight-color: transparent;
    }

    .preview-image:active {
        transform: scale(0.98);
    }

    .btn:active {
        transform: scale(0.97);
    }
}

/* 打印样式 */
@media print {
    .navbar,
    .hero-actions,
    .back-to-top,
    .lightbox {
        display: none !important;
    }

    .section {
        page-break-inside: avoid;
    }

    .accordion-content {
        max-height: none !important;
    }
}
