/**
 * aw_pictoproduct — Styles front (fiche produit)
 * @author Alexandre MERY - ACMP-WEB
 */

/* ── Wrapper ── */
.aw-pictoproduct-wrapper {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: flex-start;
    padding: 12px 0;
}

/* ── Chaque item ── */
.aw-picto-item {
    position: relative;
    display: inline-flex;
    flex-direction: column;
    align-items: center;
    cursor: default;
}

/* ── Cercle image ── */
.aw-picto-circle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 64px;
    height: 64px;
    border-radius: 50%;
    overflow: hidden;
    transition: box-shadow 0.2s ease;
}

.aw-picto-circle img {
    width: 60px;
    height: 60px;
    object-fit: contain;
}

.aw-picto-item:hover .aw-picto-circle {
    box-shadow: 0 0 0 2px rgba(0,0,0,.12);
}

/* ── Tooltip (affiché au survol) ── */
.aw-picto-tooltip {
    display: none;
    position: absolute;
    bottom: calc(100% + 8px);
    left: 50%;
    transform: translateX(-50%);
    z-index: 100;

    background: #333;
    color: #fff;
    font-size: 12px;
    line-height: 1.4;
    padding: 6px 10px;
    border-radius: 4px;
    white-space: normal;
    width: max-content;
    max-width: 180px;
    text-align: center;
    pointer-events: none;

    /* Flèche */
    box-shadow: 0 2px 8px rgba(0,0,0,.2);
}

/* Flèche bas du tooltip */
.aw-picto-tooltip::after {
    content: '';
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 5px solid transparent;
    border-top-color: #333;
}

/* Affichage au survol */
.aw-picto-item:hover .aw-picto-tooltip,
.aw-picto-item:focus-within .aw-picto-tooltip {
    display: block;
}

/* ── Responsive ── */
@media (max-width: 575px) {
    .aw-pictoproduct-wrapper {
        gap: 6px;
    }
    .aw-picto-circle {
        width: 52px;
        height: 52px;
    }
    .aw-picto-circle img {
        width: 48px;
        height: 48px;
    }
}
