/* ============ HEADER BADGE ============ */
#cart .cart-toggle {
    background: transparent;
    border: 0;
    position: relative;
    display: flex;
    align-items: center;
    cursor: pointer;
    padding: 6px 8px;
}

#cart .cart-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    margin-left: 6px;
    font-size: 12px;
    font-weight: 700;
    line-height: 1;
    color: #fff;
    background: #94a3b8;
    border-radius: 999px;
    transition: background .25s ease, transform .25s ease;
}

#cart .cart-badge.has-items {
    background: #dc2626;
}

#cart .cart-badge.cart-bump {
    animation: cart-bump .4s ease;
}

@keyframes cart-bump {
    0% {
        transform: scale(1);
    }
    30% {
        transform: scale(1.35);
    }
    60% {
        transform: scale(.9);
    }
    100% {
        transform: scale(1);
    }
}

/* ============ DROPDOWN ============ */
#cart .cart-menu {
    width: 340px;
    max-width: 92vw;
    padding: 0;
    border: 0;
    border-radius: 14px;
    box-shadow: 0 18px 45px rgba(15, 23, 42, .16);
    overflow: hidden;
    margin-top: 10px;
}

.mini-cart-empty {
    padding: 30px 20px;
    text-align: center;
    color: #64748b;
}

.mini-cart-empty i {
    font-size: 34px;
    color: #cbd5e1;
    margin-bottom: 10px;
    display: block;
}

.mini-cart-empty p {
    margin: 0;
    font-size: 14px;
}

.mini-cart-list {
    list-style: none;
    margin: 0;
    padding: 6px;
    max-height: 340px;
    overflow-y: auto;
}

.mini-cart-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px;
    border-radius: 10px;
    transition: background .2s ease;
    position: relative;
}

.mini-cart-item:hover {
    background: #f8fafc;
}

.mini-cart-item__img img {
    width: 54px;
    height: 54px;
    object-fit: cover;
    border-radius: 8px;
    border: 1px solid #eef2f7;
}

.mini-cart-item__body {
    flex: 1 1 auto;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.mini-cart-item__name {
    font-size: 13px;
    font-weight: 600;
    color: #0f172a !important;
    text-decoration: none;
    line-height: 1.3;
}

.mini-cart-item__name:hover {
    color: #dc2626 !important;
}

.mini-cart-item__sku {
    font-size: 11px;
    color: #94a3b8;
}

.mini-cart-item__meta {
    font-size: 12px;
    color: #475569;
    font-weight: 500;
}

.mini-cart-item__remove {
    background: transparent;
    border: 0;
    color: #cbd5e1;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    cursor: pointer;
    flex: 0 0 auto;
    transition: all .2s ease;
}

.mini-cart-item__remove:hover {
    background: #fee2e2;
    color: #dc2626;
}

.mini-cart-summary {
    padding: 12px 16px;
    border-top: 1px solid #eef2f7;
    list-style: none;
}

.mini-cart-summary__row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 14px;
    color: #334155;
}

.mini-cart-summary__row strong {
    font-size: 15px;
    color: #0f172a;
}

.mini-cart-actions {
    display: flex;
    gap: 8px;
    padding: 12px 16px 16px;
    list-style: none;
}

.mini-cart-btn {
    flex: 1 1 0;
    text-align: center;
    padding: 10px 12px;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    transition: all .2s ease;
}

.mini-cart-btn--light {
    background: #f1f5f9;
    color: #0f172a !important;
}

.mini-cart-btn--light:hover {
    background: #e2e8f0;
}

.mini-cart-btn--primary {
    background: #dc2626;
    color: #fff !important;
}

.mini-cart-btn--primary:hover {
    background: #b91c1c;
}

/* ============ CART PAGE ============ */
.pz-cart-wrap {
    padding: 40px 0;
}

.pz-cart-title {
    font-size: 26px;
    font-weight: 700;
    color: #0f172a;
    margin: 0 0 24px;
}

.pz-cart-grid {
    display: flex;
    gap: 24px;
    align-items: flex-start;
    flex-wrap: wrap;
}

.pz-cart-main {
    flex: 1 1 560px;
    min-width: 300px;
}

.pz-cart-side {
    flex: 0 0 340px;
    max-width: 100%;
}

.pz-cart-card {
    background: #fff;
    border: 1px solid #eef2f7;
    border-radius: 16px;
    overflow: hidden;
}

.pz-cart-row {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 18px;
    border-bottom: 1px solid #f1f5f9;
    transition: background .2s ease;
}

.pz-cart-row:last-child {
    border-bottom: 0;
}

.pz-cart-row.is-unavailable {
    background: #fff7ed;
}

.pz-cart-row__img img {
    width: 84px;
    height: 84px;
    object-fit: cover;
    border-radius: 12px;
    border: 1px solid #eef2f7;
}

.pz-cart-row__info {
    flex: 1 1 auto;
    min-width: 0;
}

.pz-cart-row__name {
    font-size: 15px;
    font-weight: 600;
    color: #0f172a !important;
    text-decoration: none;
    display: block;
    margin-bottom: 4px;
}

.pz-cart-row__name:hover {
    color: #dc2626 !important;
}

.pz-cart-row__sku {
    font-size: 12px;
    color: #94a3b8;
}

.pz-cart-row__warn {
    display: inline-block;
    margin-top: 6px;
    font-size: 12px;
    color: #c2410c;
    font-weight: 600;
}

.pz-cart-row__price {
    font-size: 14px;
    color: #475569;
    white-space: nowrap;
}

.pz-qty {
    display: inline-flex;
    align-items: center;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    overflow: hidden;
}

.pz-qty button {
    width: 34px;
    height: 38px;
    border: 0;
    background: #f8fafc;
    color: #334155;
    font-size: 16px;
    cursor: pointer;
    transition: background .2s ease;
}

.pz-qty button:hover {
    background: #e2e8f0;
}

.pz-qty button:disabled {
    opacity: .4;
    cursor: not-allowed;
}

.pz-qty input {
    width: 46px;
    height: 38px;
    border: 0;
    text-align: center;
    font-size: 14px;
    font-weight: 600;
    color: #0f172a;
    -moz-appearance: textfield;
}

.pz-qty input::-webkit-outer-spin-button,
.pz-qty input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.pz-cart-row__total {
    font-size: 16px;
    font-weight: 700;
    color: #0f172a;
    white-space: nowrap;
    min-width: 90px;
    text-align: right;
}

.pz-cart-row__remove {
    background: transparent;
    border: 0;
    color: #cbd5e1;
    width: 36px;
    height: 36px;
    border-radius: 10px;
    cursor: pointer;
    flex: 0 0 auto;
    transition: all .2s ease;
}

.pz-cart-row__remove:hover {
    background: #fee2e2;
    color: #dc2626;
}

.pz-cart-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 16px;
    flex-wrap: wrap;
    gap: 12px;
}

.pz-cart-link {
    color: #475569 !important;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.pz-cart-link:hover {
    color: #0f172a !important;
}

.pz-cart-clear {
    background: transparent;
    border: 0;
    color: #dc2626;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.pz-cart-clear:hover {
    text-decoration: underline;
}

/* summary side */
.pz-summary-card {
    background: #fff;
    border: 1px solid #eef2f7;
    border-radius: 16px;
    padding: 22px;
    position: sticky;
    top: 20px;
}

.pz-summary-title {
    font-size: 18px;
    font-weight: 700;
    color: #0f172a;
    margin: 0 0 18px;
}

.pz-summary-row {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    font-size: 14px;
    color: #475569;
}

.pz-summary-total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 0 6px;
    margin-top: 8px;
    border-top: 1px solid #eef2f7;
}

.pz-summary-total span {
    font-size: 15px;
    font-weight: 600;
    color: #0f172a;
}

.pz-summary-total strong {
    font-size: 22px;
    color: #0f172a;
}

.pz-coupon {
    display: flex;
    gap: 8px;
    margin: 16px 0;
}

.pz-coupon input {
    flex: 1 1 auto;
    height: 44px;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 0 12px;
    font-size: 14px;
}

.pz-coupon button {
    height: 44px;
    padding: 0 16px;
    border: 0;
    border-radius: 10px;
    background: #f1f5f9;
    color: #334155;
    font-weight: 600;
    cursor: pointer;
}

.pz-coupon button:hover {
    background: #e2e8f0;
}

.pz-checkout-btn {
    display: block;
    width: 100%;
    text-align: center;
    padding: 15px;
    border: 0;
    border-radius: 12px;
    background: #dc2626;
    color: #fff !important;
    font-size: 16px;
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
    margin-top: 10px;
    transition: background .2s ease;
}

.pz-checkout-btn:hover {
    background: #b91c1c;
}

.pz-cart-empty {
    text-align: center;
    padding: 80px 20px;
    background: #fff;
    border: 1px solid #eef2f7;
    border-radius: 16px;
}

.pz-cart-empty i {
    font-size: 60px;
    color: #cbd5e1;
    margin-bottom: 18px;
}

.pz-cart-empty h3 {
    font-size: 20px;
    color: #0f172a;
    margin: 0 0 8px;
}

.pz-cart-empty p {
    color: #64748b;
    margin: 0 0 22px;
}

@media (max-width: 767px) {
    .pz-cart-row {
        flex-wrap: wrap;
    }

    .pz-cart-row__total {
        min-width: auto;
    }

    .pz-summary-card {
        position: static;
    }
}
