/* =============================================
   YSFCart — Responsive Breakpoints
   All media queries in one place.
   ============================================= */

/* ---------- Large tablets (≤ 1024px) ---------- */
@media only screen and (max-width: 1024px) {
    .latest {
        padding: 50px 30px;
    }

    .trends {
        padding: 50px 40px;
    }

    .card-container .card {
        flex: 0 1 200px;
    }

    .trends .swiper-slide {
        width: 300px;
        height: 300px;
    }

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

/* ---------- Tablets (≤ 768px) ---------- */
@media only screen and (max-width: 768px) {
    /* Show hamburger, hide main nav */
    #menubar {
        display: block;
    }

    #sidenav {
        display: block;
    }

    .nav3 {
        display: none;
    }

    /* Nav 1 */
    .nav1 {
        padding: 0 16px;
        flex-wrap: wrap;
        height: auto;
        padding: 8px 16px;
    }

    .nav1 .left,
    .nav1 .right {
        flex-basis: 100%;
        text-align: center;
        justify-content: center;
    }

    /* Nav 2 */
    .nav2 {
        flex-direction: column;
        height: auto;
        padding: 12px 16px;
        text-align: center;
        gap: 4px;
    }

    .nav2 .nav2-left,
    .nav2 .nav2-right {
        display: none;
    }

    .nav2 .nav2-center h1 {
        font-size: 1.6rem;
        letter-spacing: 3px;
    }

    /* Featured */
    .featured {
        height: 50vh;
        min-height: 280px;
    }

    .featured-text h2 {
        font-size: 1.6rem;
        letter-spacing: 2px;
    }

    /* Products */
    .latest {
        padding: 40px 20px;
    }

    .card-container {
        gap: 16px;
    }

    .card-container .card {
        flex: 0 1 calc(50% - 16px);
    }

    /* Trends */
    .trends {
        padding: 40px 20px;
    }

    .trends .swiper-slide {
        width: 260px;
        height: 260px;
    }

    /* Footer */
    footer {
        flex-direction: column;
        align-items: center;
        padding: 2rem 1rem;
    }

    footer .footer-col {
        min-width: unset;
        width: 100%;
    }

    /* Page layouts */
    .page-content {
        padding: 40px 20px;
    }

    .cart-table th:nth-child(3),
    .cart-table td:nth-child(3) {
        display: none;
    }
}

/* ---------- Mobile phones (≤ 576px) ---------- */
@media only screen and (max-width: 576px) {
    .nav1 .left span {
        display: none;
    }

    .nav2 .nav2-center h1 {
        font-size: 1.3rem;
        letter-spacing: 2px;
    }

    .nav2 .nav2-center p {
        font-size: 0.72rem;
    }

    /* Featured */
    .featured {
        height: 42vh;
        min-height: 240px;
    }

    .featured-text {
        margin-left: 5%;
    }

    .featured-text h2 {
        font-size: 1.25rem;
        letter-spacing: 1px;
    }

    .featured-text button {
        padding: 10px 20px;
        font-size: 0.82rem;
    }

    /* Products */
    .latest {
        padding: 30px 12px;
    }

    .product-intro h1 {
        font-size: 1.5rem;
    }

    .card-container .card {
        flex: 0 1 100%;
    }

    /* Trends */
    .trends {
        padding: 30px 10px;
    }

    .trends .swiper-slide {
        width: 100%;
        height: auto;
        aspect-ratio: 1 / 1;
    }

    /* Footer */
    footer h2 {
        font-size: 1.1rem;
        letter-spacing: 0.2rem;
    }

    /* Auth pages */
    .auth-card {
        padding: 30px 20px;
    }

    /* Cart page */
    .cart-table th:nth-child(4),
    .cart-table td:nth-child(4) {
        display: none;
    }

    .page-hero h1 {
        font-size: 1.6rem;
    }
}

/* ---------- Very small devices (≤ 380px) ---------- */
@media only screen and (max-width: 380px) {
    .nav2 .nav2-center h1 {
        font-size: 1.1rem;
    }

    .featured-text h2 {
        font-size: 1rem;
    }

    .product-intro h1 {
        font-size: 1.2rem;
    }
}
