.vxcp {
    font-family: var(--vx-font-family);
    color: var(--vx-text);
    background: var(--vx-bg-body);
}
.vxcp-wrap { max-width: 1050px; margin: 0 auto; padding: 0 var(--vx-pad-x); }

.vxcp-head { margin-bottom: 1.6rem; }
.vxcp-title { font-size: clamp(1.6rem,4vw,2.3rem); margin: 0 0 .3rem; font-weight: 700; }
.vxcp-sub { color: var(--vx-text-3); font-size: .95rem; }

.vxcp-layout {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: var(--vx-gap);
    align-items: start;
}

.vxcp-item {
    display: flex; gap: 1rem;
    padding: 1rem;
    background: var(--vx-bg-card);
    border: 1px solid var(--vx-border);
    border-radius: var(--vx-radius);
    margin-bottom: var(--vx-gap);
}
.vxcp-item.is-removing { opacity: 0; transform: translateX(20px); transition: .25s ease; }
.vxcp-item-img {
    width: 90px; height: 90px; flex: 0 0 auto;
    object-fit: cover; border-radius: var(--vx-radius);
    background: var(--vx-bg-hover);
}
.vxcp-item-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: .3rem; }
.vxcp-item-brand {
    font-size: .72rem; text-transform: uppercase; letter-spacing: .08em;
    color: var(--vx-text-3);
}
.vxcp-item-name {
    font-size: 1rem; font-weight: 500; color: var(--vx-text); text-decoration: none;
}
.vxcp-item-name:hover { color: var(--vx-primary); }
.vxcp-item-sku, .vxcp-item-opts { font-size: .8rem; color: var(--vx-text-3); }
.vxcp-item-each { font-size: .85rem; color: var(--vx-text-2); margin-top: .2rem; }

.vxcp-item-side {
    display: flex; flex-direction: column; align-items: flex-end;
    justify-content: space-between; gap: .6rem;
}
.vxcp-item-total { font-size: 1.1rem; font-weight: 700; }

.vxcp-qty {
    display: inline-flex; align-items: center;
    border: 1px solid var(--vx-border); border-radius: var(--vx-radius);
}
.vxcp-qty button {
    width: 30px; height: 30px; border: 0; background: none;
    color: var(--vx-text-2); cursor: pointer; font-size: 1.05rem; line-height: 1;
}
.vxcp-qty button:hover { background: var(--vx-bg-hover); }
.vxcp-qty input {
    width: 44px; height: 30px; border: 0;
    border-left: 1px solid var(--vx-border); border-right: 1px solid var(--vx-border);
    text-align: center; font-size: .85rem;
    background: var(--vx-bg-input); color: var(--vx-text);
    -moz-appearance: textfield;
}
.vxcp-qty input::-webkit-outer-spin-button,
.vxcp-qty input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }

.vxcp-item-remove {
    border: 0; background: none; color: var(--vx-text-3);
    cursor: pointer; font-size: .82rem; display: inline-flex; align-items: center; gap: .25rem;
}
.vxcp-item-remove:hover { color: var(--vx-danger); }

.vxcp-summary {
    background: var(--vx-bg-card);
    border: 1px solid var(--vx-border);
    border-radius: var(--vx-radius);
    padding: 1.3rem;
    position: sticky; top: 1rem;
}
.vxcp-summary-title { font-size: 1.1rem; margin: 0 0 1rem; font-weight: 600; }
.vxcp-summary-row {
    display: flex; justify-content: space-between; align-items: baseline;
    padding: .5rem 0;
}
.vxcp-summary-row strong { font-size: 1.25rem; }
.vxcp-summary-note {
    font-size: .78rem; color: var(--vx-text-3);
    margin: .3rem 0 1rem; line-height: 1.4;
}
.vxcp-checkout { display: block; text-align: center; width: 100%; }
.vxcp-clear {
    display: block; width: 100%; margin-top: .6rem;
    border: 0; background: none; cursor: pointer;
    font-size: .82rem; color: var(--vx-text-3); padding: .4rem;
}
.vxcp-clear:hover { color: var(--vx-danger); }
.vxcp-continue {
    display: block; text-align: center; margin-top: .5rem;
    font-size: .85rem; color: var(--vx-text-2);
}

.vxcp-empty { text-align: center; padding: 3rem 1rem; color: var(--vx-text-3); }
.vxcp-empty svg { color: var(--vx-border); margin-bottom: .8rem; }
.vxcp-empty p { font-size: 1rem; margin: 0 0 1.2rem; }
.vxcp-loading { text-align: center; padding: 3rem 1rem; color: var(--vx-text-3); }

@media (max-width: 760px) {
    .vxcp-layout { grid-template-columns: 1fr; }
    .vxcp-summary { position: static; }
}
/* ═══ checkbox custom (seleziona) ═══ */
.vxcp-check {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    user-select: none;
}
.vxcp-check input { position: absolute; opacity: 0; width: 0; height: 0; }
.vxcp-check-box {
    width: 20px;
    height: 20px;
    border: 2px solid var(--vx-border);
    border-radius: var(--vx-radius-sm);
    background: var(--vx-bg-card);
    flex-shrink: 0;
    position: relative;
    transition: all var(--vx-transition);
}
.vxcp-check input:checked + .vxcp-check-box {
    background: var(--vx-primary);
    border-color: var(--vx-primary);
}
.vxcp-check input:checked + .vxcp-check-box::after {
    content: '';
    position: absolute;
    left: 6px; top: 2px;
    width: 5px; height: 10px;
    border: solid var(--vx-text-inv);
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}
.vxcp-check input:indeterminate + .vxcp-check-box {
    background: var(--vx-primary);
    border-color: var(--vx-primary);
}
.vxcp-check input:indeterminate + .vxcp-check-box::after {
    content: '';
    position: absolute;
    left: 4px; top: 8px;
    width: 10px; height: 2px;
    background: var(--vx-text-inv);
}
.vxcp-check-label { font-size: .85rem; font-weight: 600; color: var(--vx-text-2); }

/* barra seleziona tutto */
.vxcp-selbar {
    padding: .8rem 1rem;
    background: var(--vx-bg-card);
    border: 1px solid var(--vx-border);
    border-radius: var(--vx-radius);
    margin-bottom: var(--vx-gap);
}

/* checkbox dentro la riga */
.vxcp-item-check { align-self: center; }

/* articolo deselezionato → annebbiato */
.vxcp-item-off { opacity: .45; }
.vxcp-item-off .vxcp-item-img,
.vxcp-item-off .vxcp-item-main,
.vxcp-item-off .vxcp-item-total { filter: grayscale(.6); }

/* ═══ barra spedizione gratis ═══ */
.vxcp-freebar {
    margin-bottom: 1rem;
    padding: .8rem;
    background: var(--vx-bg-hover);
    border-radius: var(--vx-radius-sm);
}
.vxcp-freebar-msg { font-size: .82rem; color: var(--vx-text-2); margin-bottom: .5rem; }
.vxcp-freebar-msg b { color: var(--vx-text); }
.vxcp-free-ok { color: var(--vx-success); font-weight: 700; }
.vxcp-freebar-track {
    height: 8px;
    background: var(--vx-bg-active);
    border-radius: 999px;
    overflow: hidden;
}
.vxcp-freebar-fill {
    height: 100%;
    width: 0;
    background: var(--vx-accent);
    border-radius: 999px;
    transition: width .4s ease, background .3s ease;
}
.vxcp-freebar-fill.is-full { background: var(--vx-success); }

/* riga spedizione nel riepilogo */
.vxcp-summary-ship {
    font-size: .9rem;
    color: var(--vx-text-2);
    border-top: 1px solid var(--vx-border);
    margin-top: .3rem;
}

/* ═══ coupon (disattivato) ═══ */
.vxcp-coupon {
    display: flex;
    gap: 6px;
    margin: 1rem 0 .3rem;
}
.vxcp-coupon-in { flex: 1; opacity: .6; }
.vxcp-coupon-btn { white-space: nowrap; opacity: .6; cursor: not-allowed; }
.vxcp-coupon-note {
    font-size: .72rem;
    color: var(--vx-text-3);
    margin-bottom: 1rem;
    font-style: italic;
}

/* ═══ trust badges ═══ */
.vxcp-trust {
    margin-top: 1.2rem;
    padding-top: 1rem;
    border-top: 1px solid var(--vx-border);
    display: flex;
    flex-direction: column;
    gap: .7rem;
}
.vxcp-trust-item {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: .82rem;
    color: var(--vx-text-2);
}
.vxcp-trust-item svg { color: var(--vx-text-3); flex-shrink: 0; }

/* checkout disabilitato */
.vxcp-disabled {
    opacity: .5;
    pointer-events: auto;
    cursor: not-allowed;
}

/* la riga ora ha il checkbox come primo figlio: allineo */
.vxcp-item { align-items: flex-start; }
/* ═══ popup custom carrello ═══ */
.vxcp-pop-overlay {
    position: fixed;
    inset: 0;
    background: var(--vx-overlay);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    padding: 20px;
}
.vxcp-pop-overlay.open { display: flex; }
.vxcp-pop {
    background: var(--vx-bg-card);
    border: 1px solid var(--vx-border);
    border-radius: var(--vx-radius);
    max-width: 400px;
    width: 100%;
    padding: 1.6rem;
    box-shadow: var(--vx-shadow-lg);
    text-align: center;
}
.vxcp-pop-text {
    font-size: 1rem;
    color: var(--vx-text);
    margin: 0 0 1.4rem;
    line-height: 1.5;
}
.vxcp-pop-actions {
    display: flex;
    gap: 10px;
    justify-content: center;
}