/* ================================================
   RESPONSIVE DESIGN
   ================================================ */
@media (max-width: 1024px) {
    .pg-home-presets-track .pg-featured-card {
        flex: 0 0 calc((100% - 32px) / 3);
    }

    .hero-container {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .hero-content {
        text-align: center;
    }

    .hero-content h1 {
        font-size: 3.5rem;
    }

    .products-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .pg-featured-card {
        flex: 0 0 calc((100% - 48px) / 4);
    }
}

@media (max-width: 768px) {
    .pg-home-presets {
        padding: 0 5% 60px;
    }

    .pg-home-presets .section-header {
        padding-top: 60px;
    }

    .pg-home-presets-track .pg-featured-card {
        flex: 0 0 calc((100% - 32px) / 3);
    }

    .hero {
        padding: 60px 5% 40px;
        min-height: auto;
    }

    .hero-content h1 {
        font-size: 2.5rem;
    }

    .hero-content .tagline {
        font-size: 1.1rem;
    }

    .hero-image-placeholder {
        height: 350px;
    }

    .section-header h2 {
        font-size: 2rem;
    }

    .products-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .pg-featured-section {
        padding: 60px 5%;
    }

    .pg-featured-container > h2 {
        font-size: 1.5rem;
        margin-bottom: 32px;
    }

    .pg-featured-card {
        flex: 0 0 calc((100% - 32px) / 3);
    }

    .pg-featured-row {
        margin-bottom: 36px;
    }

    .trust-container h2 {
        font-size: 1.5rem;
    }

    .trust-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 32px;
    }
}

@media (max-width: 540px) {
    .pg-home-presets-track .pg-featured-card {
        flex: 0 0 calc((100% - 16px) / 2);
    }

    .pg-featured-card {
        flex: 0 0 calc((100% - 16px) / 2);
    }

    .pg-featured-row-header h3 {
        font-size: 1rem;
    }

    .pg-featured-cat-icon {
        width: 20px;
        height: 20px;
    }

    /* Surface tactile plus confortable pour les flèches du carrousel sur mobile. */
    .pg-featured-btn {
        width: 40px;
        height: 40px;
    }
}

@media (max-width: 480px) {
    /* ---- Homepage presets section ---- */

    /* Section heading + tagline : taille lisible à 320-480px */
    .pg-home-presets .section-header {
        padding-top: 48px;
        margin-bottom: 24px;
    }
    .pg-home-presets .section-header h2 {
        font-size: 1.5rem;
    }
    .pg-home-presets-tagline {
        font-size: 0.875rem;
    }

    /* Preset rail : passe en scroll horizontal tactile au lieu du carrousel JS */
    .pg-home-presets .pg-featured-track-wrapper {
        overflow-x: auto;
        overflow-y: hidden;
        scroll-snap-type: x proximity;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
    }
    .pg-home-presets .pg-featured-track-wrapper::-webkit-scrollbar {
        display: none;
    }
    /* Empêche translateX du JS de s'appliquer sur mobile — le scroll natif prend le relais */
    .pg-home-presets .pg-featured-track {
        transform: none !important;
        transition: none;
    }
    /* Cartes plus larges pour faciliter le scroll (≈ 2 cartes visibles + amorce) */
    .pg-home-presets-track .pg-featured-card {
        flex: 0 0 min(160px, 42vw);
        scroll-snap-align: start;
    }
    /* Masque les flèches JS du carousel (inutiles avec scroll natif) */
    .pg-home-presets .pg-featured-nav {
        display: none;
    }

    /* "Voir toutes les raquettes" : bouton pleine largeur, tap target ≥ 44px */
    .pg-home-presets-container > .pg-featured-see-all {
        display: flex;
        justify-content: center;
        width: 100%;
        min-height: 44px;
        padding: 10px 16px;
        box-sizing: border-box;
        margin-top: 16px;
    }

    /* ---- Trust grid ---- */
    .trust-grid {
        grid-template-columns: 1fr;
        gap: 28px;
    }
}

@media (max-width: 375px) {
    /* Cartes encore un peu plus étroites sur 320px pour éviter tout overflow */
    .pg-home-presets-track .pg-featured-card {
        flex: 0 0 min(140px, 40vw);
    }

    /* Réduire le padding horizontal de la section sur très petits écrans */
    .pg-home-presets {
        padding: 0 4% 48px;
    }
}
