/* 响应式布局 */
@media screen and (max-width: 64rem) {
    .product-grid {
        grid-template-columns: repeat(auto-fill, minmax(14rem, 1fr));
    }
}

@media screen and (max-width: 48rem) {
    :root {
        font-size: 15px;
    }

    .nav-container {
        flex-direction: column;
        padding: 0.5rem;
    }

    .logo {
        margin-bottom: 0.5rem;
    }

    .main-menu {
        gap: 1rem;
        flex-wrap: nowrap;
        justify-content: flex-start;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        -ms-overflow-style: none;
        padding: 0.5rem 1rem;
        scroll-behavior: smooth;
        scroll-snap-type: x proximity;
        margin: 0 -1rem;
    }

    .main-menu::-webkit-scrollbar {
        display: none;
    }

    .menu-item {
        scroll-snap-align: start;
        padding: 0 0.5rem;
    }

    .menu-item a {
        white-space: nowrap;
        padding: 0.5rem 0.75rem;
    }

    .sub-menu {
        display: none;
    }

    .menu-item:hover .sub-menu {
        display: none;
    }

    .main-content {
        margin-top: 6rem;
        padding: 1rem;
    }

    .product-grid {
        grid-template-columns: repeat(auto-fill, minmax(12rem, 1fr));
        gap: 1rem;
    }
}

@media screen and (max-width: 30rem) {
    :root {
        font-size: 14px;
    }

    .logo {
        display: none;
    }

    .nav-container {
        padding: 0.25rem 0;
    }

    .main-menu {
        width: 100%;
        padding: 0.5rem;
        white-space: nowrap;
    }

    .menu-item {
        display: inline-block;
        margin: 0 0.5rem;
    }

    .menu-item a {
        padding: 0.5rem 0.75rem;
    }

    .main-content {
        margin-top: 4rem;
    }

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

    .product-meta {
        justify-content: center;
    }
}
