/* ============================================================
   commercesvu.css
   Identité visuelle : sobre, "récemment vus"
   Structure miroir de commerceslocaux.css
   ============================================================ */

/* ── Conteneur global ── */
.container-commerces-vus-carousel .commerces-vus-carousel {
    width: 100%;
    overflow: hidden;
}

#commerces-vus-carousel {
    display: flex;
    justify-content: flex-start;
    align-items: center;
}

/* ── Carte individuelle ── */
#commerces-vus-carousel .commercesvu {
    background-color: #fff;
    border: 1px solid #ddd;
    border-radius: 5px;
    margin: 2px;
    position: relative;
    overflow: hidden;
    width: 100px;
    height: 80px;
    text-align: center;
    cursor: pointer;
}

/* ── Image ── */
#commerces-vus-carousel .commercesvu img {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease-in-out;
    z-index: 0;
}

#commerces-vus-carousel .commercesvu:hover img {
    transform: scale(1.1);
}

/* ── Nom — haut gauche ── */
#commerces-vus-carousel .commercesvu h4 {
    font-size: 11px;
    font-weight: bold;
    color: #fff;
    text-shadow: 0 1px 3px rgba(0,0,0,0.7);
    padding: 2px 5px;
    margin: 0;
    position: absolute;
    top: 0; left: 0;
    max-width: 75%;
    box-sizing: border-box;
    background-color: rgba(0, 0, 0, 0.32);
    border-radius: 5px 0 4px 0;
    z-index: 2;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* ── Ville — bas droite ── */
#commerces-vus-carousel .commercesvu p {
    font-size: 10px;
    font-weight: bold;
    color: #fff;
    text-shadow: 0 1px 3px rgba(0,0,0,0.7);
    padding: 2px 5px;
    margin: 0;
    position: absolute;
    bottom: 0; right: 0;
    max-width: 75%;
    box-sizing: border-box;
    background-color: rgba(0, 0, 0, 0.32);
    border-radius: 4px 0 5px 0;
    z-index: 2;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* ── Note — bas gauche, disparaît au survol ── */
#commerces-vus-carousel .commercesvu .note {
    font-size: 11px;
    position: absolute;
    bottom: -1px; left: 1px;
    z-index: 2;
    opacity: 1;
    transition: opacity 0.3s ease;
}

#commerces-vus-carousel .commercesvu:hover .note {
    opacity: 0;
}

/* ── Bouton favori — haut droite, apparaît au survol ── */
#commerces-vus-carousel .commercesvu .favori-button {
    position: absolute;
    top: 2px; right: 2px;
    z-index: 3;
    background: none;
    border: none;
    cursor: pointer;
    opacity: 0;
    overflow: visible;
    transition: opacity 0.3s ease;
    padding: 0;
    line-height: 1;
}

#commerces-vus-carousel .commercesvu:hover .favori-button {
    opacity: 1;
}

#commerces-vus-carousel .commercesvu .favori-button i {
    font-size: 15px;
    color: #fff;
    text-shadow: 0 1px 4px rgba(0,0,0,0.6);
    transition: color 0.2s ease;
}

#commerces-vus-carousel .commercesvu .favori-button i.fas {
    color: #ff4500;
}

#commerces-vus-carousel .commercesvu .favori-button:hover i {
    color: #dc143c;
}

#commerces-vus-carousel .commercesvu .favori-button.active i {
    color: red;
    animation: popHeartVu .3s ease;
}

@keyframes popHeartVu {
    0%   { transform: scale(1); }
    50%  { transform: scale(1.5); }
    100% { transform: scale(1); }
}

#commerces-vus-carousel .commercesvu .mini-coeur {
    position: absolute;
    color: red;
    font-size: 14px;
    pointer-events: none;
    animation: envolCoeurVu .8s ease-out forwards;
}

@keyframes envolCoeurVu {
    from {
        transform: translate(-50%, -50%) scale(1);
        opacity: 1;
    }
    to {
        transform: translate(calc(-50% + var(--x)), calc(-50% + var(--y))) scale(0.2);
        opacity: 0;
    }
}

/* ── Bouton site web — bas gauche, apparaît au survol ── */
#commerces-vus-carousel .commercesvu .site-web-button {
    position: absolute;
    bottom: 3px; left: 3px;
    font-size: 10px;
    background-color: rgba(0, 51, 204, 0.85);
    color: #fff;
    padding: 2px 6px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    opacity: 0;
    z-index: 3;
    transition: opacity 0.3s ease, background-color 0.2s ease;
    text-decoration: none;
    display: flex;
    align-items: center;
}

#commerces-vus-carousel .commercesvu:hover .site-web-button {
    opacity: 1;
}

#commerces-vus-carousel .commercesvu .site-web-button:hover {
    background-color: rgba(0, 64, 128, 0.95);
}

/* --- slick --- */
#coup-de-coeur-carousel .slick-track,
#commerces-recent-carousel .slick-track {
    display: flex !important;
    flex-direction: row !important;
    align-items: stretch;
}

/* ── Flèches de navigation ── */
#commerces-vus-carousel .slick-commerces-locaux-prev,
#commerces-vus-carousel .slick-commerces-locaux-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 28px;
    height: 28px;
    background: rgba(0, 0, 0, 0.45);
    border: none;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 10;
    opacity: 0.6;
    transition: opacity 0.2s ease, background 0.2s ease;
    padding: 0;
}

/* Fix conflit Slick float vs flex — à ajouter à la fin de commerceslocaux.css */
#container-commerces-locaux-carousel.slick-initialized { display: block;}

#container-commerces-locaux-carousel .slick-list {overflow: hidden;}



#commerces-vus-carousel .slick-commerces-locaux-prev { left: 4px; }
#commerces-vus-carousel .slick-commerces-locaux-next { right: 4px; }

#commerces-vus-carousel .slick-commerces-locaux-prev:hover,
#commerces-vus-carousel .slick-commerces-locaux-next:hover {
    opacity: 1;
    background: rgba(0, 0, 0, 0.72);
}

#commerces-vus-carousel .slick-commerces-locaux-prev i,
#commerces-vus-carousel .slick-commerces-locaux-next i {
    font-size: 12px;
    color: #fff;
}

#commerces-vus-carousel .slick-commerces-locaux-prev::before,
#commerces-vus-carousel .slick-commerces-locaux-next::before {
    content: none;
}




















/* ── Message vide ── */
#commerces-vus-carousel p.message-vide {
    font-size: 13px;
    color: #888;
    padding: 20px;
    text-align: center;
}