/**
 * Base : variables de couleur, petits correctifs Elementor, classes utilitaires.
 * Chargé sur tout le site.
 *
 * (anciennement Elementor > Paramètres du site > CSS personnalisé)
 */

/* ==========================================================================
   Variables
   ========================================================================== */

:root {
    --ptc-pink: #ff0080;        /* survol / état actif du menu */
    --ptc-accent: #ff4f7b;      /* rose de la marque */
    --ptc-text-muted: #686868;  /* sous-titres */
}

/* ==========================================================================
   Correctifs Elementor
   ========================================================================== */

.elementor-widget-text-editor p:last-child {
    margin-bottom: 0;
}

/* ==========================================================================
   Utilitaires (à ajouter dans Avancé > Classes CSS d'un élément)
   ========================================================================== */

.text-accent {
    color: var(--ptc-accent);
}

.cursor-pointer {
    cursor: pointer;
}

.text-truncate {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Bouton contour : bordure claire au survol */
.btn-outline a:hover {
    border-color: #ececec !important;
}

/* Mobile uniquement : texte lisible sur image, variantes noir / rose */
@media (max-width: 767px) {
    .sm-text-overlay {
        background-color: rgb(255 255 255 / 0.8);
    }

    .sm-text-black,
    .sm-text-black h3 {
        color: #000 !important;
    }

    .sm-bg-pink,
    .sm-bg-pink a {
        background-color: var(--ptc-accent) !important;
        color: #fff !important;
    }
}

/* Dégradé rose qui s'estompe vers la droite */
.bg-fade-right {
    background: linear-gradient(to right,
        rgb(230 60 105 / 1) 0%,
        rgb(230 60 105 / 1) 80%,
        rgb(230 60 105 / 0.5) 95%,
        rgb(230 60 105 / 0) 100%
    ) !important;
}

/* Pied de page : voir assets/css/footer.css */

/* ==========================================================================
   Fil d'Ariane (boutique, fiches produit) : balisage : inc/woocommerce.php
   ========================================================================== */

.woocommerce-breadcrumb {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 6px;
    margin: 0;
    color: #8a8a8a !important;
    font-size: 13px !important;
    line-height: 1.4;
}

.woocommerce-breadcrumb a {
    color: #8a8a8a !important;
    text-decoration: none;
    transition: color 0.2s ease;
}

.woocommerce-breadcrumb a:hover {
    color: #e63c69 !important;
}

/* Étape en cours : en noir */
.woocommerce-breadcrumb .ptc-bc-item:last-child {
    color: #111;
    font-weight: 500;
}

/* Séparateur : petit chevron */
.ptc-bc-sep {
    width: 6px;
    height: 6px;
    margin: 0 2px;
    border-top: 1.5px solid #b5b5b5;
    border-right: 1.5px solid #b5b5b5;
    transform: rotate(45deg);
}

/* Mobile : un seul lien de retour vers l'étape parente, « ‹ T-shirts » */
@media (max-width: 767px) {
    .woocommerce-breadcrumb .ptc-bc-item,
    .woocommerce-breadcrumb .ptc-bc-sep {
        display: none;
    }

    .woocommerce-breadcrumb .ptc-bc-item:nth-last-child(3) {
        display: inline-flex;
        align-items: center;
        gap: 8px;
    }

    .woocommerce-breadcrumb .ptc-bc-item:nth-last-child(3)::before {
        content: "";
        width: 7px;
        height: 7px;
        border-bottom: 1.5px solid currentColor;
        border-left: 1.5px solid currentColor;
        transform: rotate(45deg);
    }

    .woocommerce-breadcrumb .ptc-bc-item:nth-last-child(3) a {
        color: #111 !important;
        font-weight: 500;
    }
}


/* ==========================================================================
   Carrousels Elementor (accueil : produits, avis) avant le démarrage de
   Swiper : cartes déjà à leur taille finale, sinon chaque carte prend toute
   la largeur puis rétrécit (la page sautait de près de 500 px).
   Nombre de cartes et écarts : réglages des widgets dans Elementor.
   ========================================================================== */

.elementor-widget-loop-carousel .swiper:not(.swiper-initialized) > .swiper-wrapper {
    display: flex;
    overflow: hidden;
}

.elementor-widget-loop-carousel .swiper:not(.swiper-initialized) .swiper-slide {
    flex-shrink: 0;
}

/* Produits : 3 cartes (2 sur tablette et mobile), 16 px d'écart */
.ptc-product-carousel .swiper:not(.swiper-initialized) .swiper-slide {
    width: calc((100% - 2 * 16px) / 3);
    margin-right: 16px;
}

/* Avis : 3 cartes, 2 sur tablette, 1 sur mobile, 25 px d'écart */
.elementor-widget-loop-carousel.reviews .swiper:not(.swiper-initialized) .swiper-slide {
    width: calc((100% - 2 * 25px) / 3);
    margin-right: 25px;
}

@media (max-width: 1024px) {
    .ptc-product-carousel .swiper:not(.swiper-initialized) .swiper-slide {
        width: calc((100% - 16px) / 2);
    }

    .elementor-widget-loop-carousel.reviews .swiper:not(.swiper-initialized) .swiper-slide {
        width: calc((100% - 25px) / 2);
    }
}

@media (max-width: 767px) {
    .elementor-widget-loop-carousel.reviews .swiper:not(.swiper-initialized) .swiper-slide {
        width: 100%;
    }
}
