/* APBP Store Features — badge on personalisable products.
   Colours come from inline custom properties set by PHP, so the shop's chosen
   colour and a readable text colour travel with each badge. */

.apbp-badge {
    --apbp-badge-bg: #0d404f;
    --apbp-badge-fg: #fff;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    max-width: 100%;
    box-sizing: border-box;
    margin: 0;
    padding: 5px 11px;
    border-radius: 999px;
    background: var(--apbp-badge-bg);
    color: var(--apbp-badge-fg);
    font-size: 13px;
    font-weight: 700;
    line-height: 1.25;
    letter-spacing: .01em;
    text-transform: none;
    white-space: nowrap;
    vertical-align: middle;
}

.apbp-badge svg {
    flex: 0 0 auto;
    width: 14px;
    height: 14px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2.2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.apbp-badge-text {
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Under the product name (shop lists) and under the title (product page). */
.apbp-badge-row {
    margin: 6px 0 8px;
    line-height: 1;
}

.apbp-badge-row.is-single {
    margin: 0 0 14px;
}

/* Over the image, next to BeTheme's «Em promoção» label: same size and shape.
   The theme's badge area is a stretching flex column; keep the badge its own width. */
.mfn-product-badges .apbp-badge {
    align-self: flex-start;
    padding: 3px 8px;
    border-radius: 3px;
    font-size: 12px;
    line-height: 18px;
}

.mfn-product-badges-right .mfn-product-badges .apbp-badge {
    align-self: flex-end;
}

.mfn-product-badges .apbp-badge svg {
    width: 12px;
    height: 12px;
}

/* Over the image: created by badge.js when the theme has no badge area. */
.apbp-badges {
    position: absolute;
    top: 10px;
    left: 10px;
    z-index: 5;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 6px;
    pointer-events: none;
}
