/* Header cart widget between logo and contacts. */
.af-header-cart-widget {
    margin-top: 0px;
    display: flex;
    justify-content: center;
}

.af-header-cart-link {
    position: relative;
    width: 52px;
    height: 52px;
    border-radius: 999px;
    border: 2px solid #d65982;
    background: #fff;
    color: #d65982;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    transition:
        transform 0.2s ease,
        box-shadow 0.2s ease;
}

.af-header-cart-link:hover {
    text-decoration: none;
    transform: translateY(-1px);
    box-shadow: 0 8px 16px rgba(214, 89, 130, 0.24);
}

.af-header-cart-link i {
    font-size: 2rem;
}

/* Shared cart counter badge used in desktop header and mobile floating button. */
.af-cart-badge {
    position: absolute;
    top: -8px;
    right: -6px;
    min-width: 22px;
    height: 22px;
    border-radius: 999px;
    padding: 0 6px;
    background: #d65982;
    color: #fff;
    border: 2px solid #fff;
    font-size: 1.15rem;
    font-weight: 700;
    line-height: 18px;
    text-align: center;
}

/* Mobile cart floating quick access button. */
.af-mobile-cart-fab {
    position: fixed;
    left: 20px;
    bottom: 20px;
    width: 60px;
    height: 60px;
    border-radius: 999px;
    border: 0;
    background: linear-gradient(135deg, #d65982, #b8446a);
    color: #fff;
    z-index: 12000;
    display: none;
    align-items: center;
    justify-content: center;
    box-shadow: 0 12px 30px rgba(214, 89, 130, 0.34);
}

.af-mobile-cart-fab[hidden] {
    display: none !important;
}

.af-mobile-cart-fab i {
    font-size: 2.2rem;
}

/* Tiny pulse after add-to-cart animation reaches the cart icon. */
.af-cart-target--pulse {
    animation: afCartPulse 0.32s ease;
}

@keyframes afCartPulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.09);
    }
    100% {
        transform: scale(1);
    }
}

/* Product page actions replace legacy popup buttons. */
.af-product-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-top: 12px;
}

.af-product-action-btn {
    border: 1px solid #d65982;
    border-radius: 8px;
    background: #fff;
    color: #d65982;
    font-size: 1.7rem;
    font-weight: 600;
    line-height: 1.2;
    text-align: center;
    padding: 12px 10px;
    transition:
        transform 0.18s ease,
        box-shadow 0.18s ease,
        background 0.18s ease,
        color 0.18s ease,
        border-color 0.18s ease;
}

.af-product-action-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 8px 18px rgba(214, 89, 130, 0.2);
}

.af-product-action-btn--buy {
    background: #d65982;
    color: #fff;
}

.af-product-action-btn--add.is-in-cart {
    background: #e8f7ee;
    border-color: #22a45d;
    color: #1e8a4f;
}

.af-product-actions--single {
    grid-template-columns: 1fr;
}

@media (max-width: 767px) {
    .af-header-cart-widget {
        display: none;
    }

    .af-mobile-cart-fab {
        display: inline-flex;
    }

    .af-product-actions {
        grid-template-columns: 1fr;
    }
}
