/**
 * CBC Cart Count Badge — global styles
 * Loaded on every page so the badge works site-wide
 */

/* Wrapper must be relative — JS sets this automatically for static elements */
.cbc-cart-count-badge {
    position: relative;
    display: inline-block;
}

/* The red bubble */
.cbc-badge-count {
    position: absolute;
    top: -8px;
    right: -8px;
    min-width: 22px;
    height: 22px;
    padding: 0 5px;
    background: #BE2D3E;
    color: #fff;
    font-family: "Montserrat", Arial, sans-serif;
    font-size: 12px;
    font-weight: 700;
    line-height: 22px;
    text-align: center;
    border-radius: 50%;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.25);
    pointer-events: none;
    z-index: 9999;
    transition: transform 0.2s ease, opacity 0.2s ease;
    box-sizing: content-box;
}

/* Hidden state (count = 0) */
.cbc-badge-count.cbc-badge-hidden {
    opacity: 0;
    transform: scale(0);
}

/* Pop animation when count changes */
@keyframes cbc-badge-pop {
    0%   { transform: scale(1); }
    40%  { transform: scale(1.4); }
    100% { transform: scale(1); }
}

.cbc-badge-count.cbc-badge-pop {
    animation: cbc-badge-pop 0.3s ease forwards;
}
