:root {
    --cpx-gift-accent-color: var(--e-global-color-secondary, #577068);
    --cpx-gift-background-color: var(--cpx-gift-surface-color);
    --cpx-gift-border-color: var(--e-global-color-a0fa980, #ddd3c7);
    --cpx-gift-muted-color: #766f6a;
    --cpx-gift-success-color: var(--e-global-color-secondary, #577068);
    --cpx-gift-surface-color: #fff;
    --cpx-gift-text-color: var(--e-global-color-text, #3c3c3b);
    --cpx-gift-border-radius: 12px;
    --cpx-gift-gap: 12px;
}

.cpx-gift-progress {
    width: 100%;
    margin: 0 0 20px;
    padding: 16px;
    color: var(--cpx-gift-text-color);
    background: var(--cpx-gift-background-color);
    border: 1px solid var(--cpx-gift-border-color);
    border-radius: var(--cpx-gift-border-radius);
}

.cpx-gift-progress__headline {
    margin: 0 0 14px;
    font-size: 16px;
    font-weight: 600;
    line-height: 1.35;
    text-wrap: balance;
}

.cpx-gift-progress__track {
    width: 100%;
    height: 5px;
    margin: 0 0 14px;
    overflow: hidden;
    background: color-mix(in srgb, var(--cpx-gift-border-color) 65%, var(--cpx-gift-surface-color));
    border-radius: 999px;
}

.cpx-gift-progress__fill {
    display: block;
    width: 0;
    height: 100%;
    background: var(--cpx-gift-accent-color);
    border-radius: inherit;
    transition: width 220ms ease;
}

.cpx-gift-progress__actions {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: var(--cpx-gift-gap);
    margin: 0;
    padding: 0;
    list-style: none;
}

.cpx-gift-progress__action {
    display: grid;
    position: relative;
    grid-template-columns: 32px 1fr;
    align-items: center;
    gap: 8px;
    min-width: 0;
    padding: 10px;
    opacity: 0.68;
    background: var(--cpx-gift-surface-color);
    border: 1px solid var(--cpx-gift-border-color);
    border-radius: calc(var(--cpx-gift-border-radius) * 0.75);
}

.cpx-gift-progress__action--selected {
    opacity: 1;
    border-color: var(--cpx-gift-success-color);
}

.cpx-gift-progress__marker {
    display: flex;
    position: absolute;
    top: -7px;
    right: -7px;
    align-items: center;
    justify-content: center;
    width: 22px;
    height: 22px;
    color: var(--cpx-gift-surface-color);
    font-size: 13px;
    background: var(--cpx-gift-muted-color);
    border-radius: 50%;
}

.cpx-gift-progress__action--selected .cpx-gift-progress__marker {
    background: var(--cpx-gift-success-color);
}

.cpx-gift-progress__image {
    display: block;
    width: 32px;
    height: 32px;
}

.cpx-gift-progress__image img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.cpx-gift-progress__content,
.cpx-gift-progress__name {
    display: block;
    min-width: 0;
}

.cpx-gift-progress__amount {
    display: block;
    margin-bottom: 2px;
    font-size: 13px;
    line-height: 1.2;
}

.cpx-gift-progress__name {
    color: var(--cpx-gift-muted-color);
    font-size: 12px;
    line-height: 1.25;
}

.cpx-gift-label {
    display: inline-block;
    margin-top: 5px;
    padding: 3px 7px;
    color: var(--cpx-gift-surface-color);
    font-size: 11px;
    font-weight: 600;
    line-height: 1.2;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    background: var(--cpx-gift-success-color);
    border-radius: 999px;
}

.elementor-widget.elementor-widget-woocommerce-cart .woocommerce-cart-form__cart-item.cpx-gift-cart-item td.product-name > span.cpx-gift-label,
.woocommerce-cart .woocommerce-cart-form__cart-item.cpx-gift-cart-item td.product-name > span.cpx-gift-label {
    display: inline-block !important;
    width: auto !important;
    height: auto !important;
    max-width: 100%;
    margin: 0 0 0 8px !important;
    padding: 4px 7px !important;
    color: var(--cpx-gift-surface-color) !important;
    font-size: 10px !important;
    font-weight: 600 !important;
    line-height: 1.15 !important;
    white-space: nowrap;
    background-color: var(--cpx-gift-success-color) !important;
    border-radius: 999px !important;
}

.cpx-gift-price {
    display: inline-flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 6px;
}

.cpx-gift-price del {
    color: var(--cpx-gift-muted-color);
    opacity: 0.75;
}

.cpx-gift-price ins {
    color: var(--cpx-gift-success-color);
    font-weight: 700;
    text-decoration: none;
}

.cpx-gift-quantity {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    min-height: 40px;
    border: 1px solid var(--cpx-gift-border-color);
    border-radius: calc(var(--cpx-gift-border-radius) * 0.5);
}

.elementor-menu-cart__main .woocommerce-mini-cart-item.cpx-gift-cart-item > a.remove,
.woocommerce-mini-cart .woocommerce-mini-cart-item.cpx-gift-cart-item > a.remove {
    display: none !important;
}

.elementor-widget.elementor-widget-woocommerce-cart .woocommerce-cart-form__cart-item.cpx-gift-cart-item td.product-remove,
.woocommerce-cart .woocommerce-cart-form__cart-item.cpx-gift-cart-item td.product-remove {
    display: table-cell !important;
}

.elementor-widget.elementor-widget-woocommerce-cart .woocommerce-cart-form__cart-item.cpx-gift-cart-item td.product-remove > a,
.elementor-widget.elementor-widget-woocommerce-cart .woocommerce-cart-form__cart-item.cpx-gift-cart-item td.product-remove > button,
.woocommerce-cart .woocommerce-cart-form__cart-item.cpx-gift-cart-item td.product-remove > a,
.woocommerce-cart .woocommerce-cart-form__cart-item.cpx-gift-cart-item td.product-remove > button {
    display: none !important;
}

.elementor-menu-cart__main .cpx-gift-progress--mini_cart {
    margin: 0;
    padding: 16px 0 14px;
    background: var(--cpx-gift-surface-color);
    border-top: 0;
    border-right: 0;
    border-bottom: 1px solid var(--cpx-gift-border-color);
    border-left: 0;
    border-radius: 0;
}

.elementor-menu-cart__main .cpx-gift-progress--mini_cart .cpx-gift-progress__headline {
    margin-bottom: 8px;
    font-size: 14px;
    line-height: 1.3;
}

.elementor-menu-cart__main .cpx-gift-progress--mini_cart .cpx-gift-progress__track {
    height: 4px;
    margin-bottom: 8px;
}

.elementor-menu-cart__main .cpx-gift-progress--mini_cart .cpx-gift-progress__actions {
    display: grid;
    grid-auto-columns: minmax(0, 1fr);
    grid-auto-flow: column;
    grid-template-columns: none;
    gap: 4px;
}

.elementor-menu-cart__main .cpx-gift-progress--mini_cart .cpx-gift-progress__action {
    display: block;
    min-width: 0;
    padding: 0;
    text-align: center;
    opacity: 1;
    background: transparent;
    border: 0;
    border-radius: 0;
}

.elementor-menu-cart__main .cpx-gift-progress--mini_cart .cpx-gift-progress__marker,
.elementor-menu-cart__main .cpx-gift-progress--mini_cart .cpx-gift-progress__image,
.elementor-menu-cart__main .cpx-gift-progress--mini_cart .cpx-gift-progress__name {
    display: none;
}

.elementor-menu-cart__main .cpx-gift-progress--mini_cart .cpx-gift-progress__amount {
    margin: 0;
    color: var(--cpx-gift-muted-color);
    font-size: 11px;
    font-weight: 500;
    line-height: 1.2;
    white-space: nowrap;
}

.elementor-menu-cart__main .cpx-gift-progress--mini_cart .cpx-gift-progress__action--selected .cpx-gift-progress__amount {
    color: var(--cpx-gift-success-color);
    font-weight: 700;
}

.elementor-menu-cart__main .cpx-gift-progress--mini_cart .cpx-gift-progress__action--selected .cpx-gift-progress__amount::before {
    content: "\2713\00a0";
}

.elementor-menu-cart__main .woocommerce-mini-cart-item.cpx-gift-cart-item .quantity {
    display: flex;
    align-items: baseline;
    gap: 4px;
}

.elementor-menu-cart__main .woocommerce-mini-cart-item.cpx-gift-cart-item span.cpx-gift-label,
.elementor-menu-cart__main .elementor-menu-cart__product.cpx-gift-cart-item span.cpx-gift-label {
    display: block !important;
    width: max-content !important;
    max-width: 100%;
    margin: 8px 0 0 !important;
}

.elementor-menu-cart__product {
    padding-top: var(--product-divider-gap, 20px);
}

@media (min-width: 768px) {
    .elementor-widget.elementor-widget-woocommerce-menu-cart .elementor-menu-cart__main {
        width: 450px;
    }
}

@media (max-width: 767px) {
    .cpx-gift-progress {
        margin-bottom: 14px;
        padding: 12px;
    }

    .cpx-gift-progress__actions {
        display: flex;
        gap: 8px;
        padding: 10px 8px 6px 2px;
        overflow-x: auto;
        scroll-snap-type: x proximity;
    }

    .cpx-gift-progress__action {
        flex: 0 0 132px;
        scroll-snap-align: start;
    }

    .elementor-menu-cart__main .cpx-gift-progress--mini_cart .cpx-gift-progress__actions {
        display: grid;
        gap: 4px;
        padding: 0;
        overflow: visible;
    }
}
