/*============================================*/
/* Cart page: woocommerce/cart/cart.php */

.peptix-cart {
    --pc-blue: #3B82F6;
    --pc-blue-dark: #2563EB;
    --pc-blue-soft: rgba(59, 130, 246, 0.08);
    --pc-blue-line: rgba(59, 130, 246, 0.25);
    --pc-ink: #0F172A;
    --pc-text: #4B5563;
    --pc-muted: #757575;
    --pc-line: #D8E6FD;
    font-family: "Outfit", sans-serif;
    color: var(--pc-ink);
}

/* Heading */
.peptix-cart-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: clamp(20px, 17.57px + 0.65vw, 30px);
}

.peptix-cart .peptix-cart-title {
    margin: 0;
    font-family: "Instrument Serif", serif;
    font-weight: 400;
    font-size: clamp(34px, 30.6px + 0.91vw, 48px);
    line-height: 1.1;
    color: var(--pc-ink);
}

.peptix-cart .peptix-cart-continue-link {
    font-size: clamp(16px, 15.51px + 0.13vw, 18px);
    color: var(--pc-blue);
    text-decoration: underline;
    text-underline-offset: 4px;
}

.peptix-cart .peptix-cart-continue-link:hover {
    color: var(--pc-ink);
}

/* Table */
.woocommerce .peptix-cart table.peptix-cart-table {
    width: 100%;
    margin: 0;
    border: 0;
    border-collapse: collapse;
    border-radius: 0;
}

.woocommerce .peptix-cart table.peptix-cart-table th,
.woocommerce .peptix-cart table.peptix-cart-table td {
    padding: 24px 16px;
    border: 0;
    border-bottom: 1px solid var(--pc-line);
    background: transparent;
    vertical-align: middle;
    text-align: left;
}

.woocommerce .peptix-cart table.peptix-cart-table th:first-child,
.woocommerce .peptix-cart table.peptix-cart-table td:first-child {
    padding-left: 0;
}

.woocommerce .peptix-cart table.peptix-cart-table th:last-child,
.woocommerce .peptix-cart table.peptix-cart-table td:last-child {
    padding-right: 0;
    text-align: right;
}

.woocommerce .peptix-cart table.peptix-cart-table thead th {
    padding-top: 0;
    padding-bottom: 16px;
    font-weight: 400;
    font-size: 15px;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--pc-muted);
}

.woocommerce .peptix-cart table.peptix-cart-table th.product-name {
    width: 46%;
}

/* Product cell */
.peptix-cart-product {
    display: flex;
    align-items: center;
    gap: clamp(16px, 14.06px + 0.52vw, 24px);
}

.woocommerce .peptix-cart .product-thumbnail {
    flex: 0 0 120px;
    width: 120px;
    padding: clamp(6px, 5.03px + 0.26vw, 10px);
    border: 1px solid var(--pc-line);
    border-radius: 8px;
    background: #fff;
}

.woocommerce .peptix-cart .product-thumbnail a {
    display: block;
}

.woocommerce .peptix-cart .product-thumbnail img {
    display: block;
    width: 100%;
    max-width: none;
    height: auto;
    aspect-ratio: 1 / 1;
    object-fit: contain;
    margin: 0;
    box-shadow: none;
}

.peptix-cart-product-info {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
    min-width: 0;
}

.peptix-cart-product-info .product-purity {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin: 0;
    padding: 3px 12px 3px 3px;
    border: 1px solid var(--pc-blue-line);
    border-radius: 50px;
    background: var(--pc-blue-soft);
    font-size: 14px;
    line-height: 1.4;
    color: var(--pc-ink);
}

.peptix-cart-product-info .product-purity .icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: #FFFFFF;
}

.peptix-cart-product-info .product-purity .icon svg,
.peptix-cart-product-info .product-purity .icon img {
    width: 14px;
    height: 14px;
}

.peptix-cart .peptix-cart-product-name {
    font-size: clamp(17px, 16.27px + 0.19vw, 20px);
    line-height: 1.3;
    color: var(--pc-ink);
    text-decoration: none;
}

.peptix-cart a.peptix-cart-product-name:hover {
    color: var(--pc-blue);
}

.peptix-cart-product-info dl.variation {
    margin: 0;
    font-size: 14px;
    color: var(--pc-text);
}

/* Prices */
.woocommerce .peptix-cart td.product-price,
.woocommerce .peptix-cart td.product-subtotal {
    font-size: 18px;
    white-space: nowrap;
}

.woocommerce .peptix-cart td.product-price .amount {
    color: var(--pc-blue);
}

.woocommerce .peptix-cart td.product-subtotal .amount {
    color: var(--pc-ink);
}

/* Quantity: blue outlined pill with − 3 + and the delete icon beside it. */
.peptix-cart-qty {
    display: inline-flex;
    align-items: center;
    gap: 2px;
}

.peptix-qty-stepper {
    display: inline-flex;
    align-items: center;
    gap: 0;
    padding: 0 6px;
    border: 1px solid var(--pc-blue);
    border-radius: 50px;
    background: #FFFFFF;
}

.peptix-cart .peptix-cart-qty-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 40px;
    padding: 0;
    border: 0;
    border-radius: 50px;
    background: transparent;
    color: var(--pc-blue);
    cursor: pointer;
    transition: color 0.2s ease, background 0.2s ease;
}

.peptix-cart .peptix-cart-qty-btn svg path {
    stroke-width: 2.6;
}

.peptix-cart .peptix-cart-qty-btn:hover,
.peptix-cart .peptix-cart-qty-btn:focus {
    background: transparent;
    color: var(--pc-blue-dark);
}

.peptix-cart .peptix-cart-qty-btn:focus-visible {
    outline: 2px solid var(--pc-blue);
    outline-offset: -2px;
}

.peptix-cart .peptix-qty-stepper .quantity {
    margin: 0;
}

.woocommerce .peptix-cart .peptix-qty-stepper .quantity .qty {
    width: 40px;
    height: 40px;
    padding: 0;
    border: 0;
    background: transparent;
    box-shadow: none;
    font-family: inherit;
    font-weight: 500;
    font-size: 17px;
    text-align: center;
    color: var(--pc-blue);
    -moz-appearance: textfield;
    appearance: textfield;
}
.peptix-qty-stepper .qty::-webkit-outer-spin-button,
.peptix-qty-stepper .qty::-webkit-inner-spin-button {
    margin: 0;
    -webkit-appearance: none;
}

.woocommerce .peptix-cart .product-remove a.remove.peptix-cart-remove {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    font-size: 0;
    color: var(--pc-blue) !important;
    background: transparent;
    transition: background 0.2s ease;
}

.woocommerce .peptix-cart .product-remove a.remove.peptix-cart-remove:hover {
    background: var(--pc-blue-soft);
    color: var(--pc-blue-dark) !important;
}

/* Hidden update row: the quantity buttons submit it. Other plugins' cart actions still show. */
.woocommerce .peptix-cart table.peptix-cart-table tr.peptix-cart-actions-row td {
    padding: 0;
    border: 0;
}

.woocommerce .peptix-cart table.peptix-cart-table td.actions .peptix-cart-update {
    display: none;
}

/* Summary */
.peptix-cart-summary {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    width: 100%;
    max-width: 520px;
    margin: 40px 0 0 auto;
    text-align: right;
}

.peptix-cart-summary p {
    margin: 0;
}

.peptix-cart-subtotal {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    justify-content: flex-end;
    gap: 10px;
    font-size: clamp(21px, 20.27px + 0.19vw, 24px);
    line-height: 1.3;
}

.peptix-cart-subtotal del {
    font-size: 18px;
    color: var(--pc-muted);
}

.peptix-cart-subtotal-amount .amount {
    color: var(--pc-blue);
}

.peptix-cart-saving {
    margin-top: 4px !important;
    font-size: 16px;
    color: #15803D;
}

.peptix-cart-note {
    margin-top: 8px !important;
    font-size: 15px;
    color: var(--pc-muted);
}

.peptix-cart-buttons {
    display: flex;
    flex-direction: column;
    gap: 14px;
    width: 100%;
    margin-top: 24px;
}

.woocommerce .peptix-cart a.peptix-cart-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    min-height: 58px;
    margin: 0;
    padding: 10px 20px;
    border: 1px solid var(--pc-blue);
    border-radius: 8px;
    font-family: inherit;
    font-weight: 500;
    font-size: 20px;
    line-height: 30px;
    text-decoration: none;
    transition: background 0.25s ease, color 0.25s ease;
}

.peptix-cart .peptix-cart-btn svg {
    transition: transform 0.25s ease;
}

.peptix-cart .peptix-cart-btn:hover svg {
    transform: rotate(45deg);
}

.woocommerce .peptix-cart a.peptix-cart-btn--primary {
    background: var(--pc-blue);
    color: #FFFFFF;
}

.woocommerce .peptix-cart a.peptix-cart-btn--primary:hover {
    background: var(--pc-blue-dark);
    color: #FFFFFF;
}

.woocommerce .peptix-cart a.peptix-cart-btn--outline {
    background: #FFFFFF;
    color: var(--pc-blue);
}

.woocommerce .peptix-cart a.peptix-cart-btn--outline:hover {
    background: var(--pc-blue);
    color: #FFFFFF;
}

.peptix-cart .peptix-cart-payments {
    display: block;
    width: 329px;
    max-width: 100%;
    height: auto;
    margin-top: 24px;
}

/* Updating (WooCommerce blocks the form while it reloads the cart). */
.peptix-cart.processing {
    opacity: 0.6;
}

/* Empty cart */
.woocommerce .cart-empty.woocommerce-info {
    margin-bottom: 24px;
    font-family: "Outfit", sans-serif;
}

.woocommerce-cart .return-to-shop .button.wc-backward {
    display: inline-flex;
    align-items: center;
    min-height: 54px;
    padding: 10px 28px;
    border-radius: 8px;
    background: #3B82F6;
    font-family: "Outfit", sans-serif;
    font-weight: 400;
    font-size: 18px;
    color: #FFFFFF;
}

.woocommerce-cart .return-to-shop .button.wc-backward:hover {
    background: #2563EB;
    color: #FFFFFF;
}

/* Tablet */
@media (max-width: 1024px) {

    .woocommerce .peptix-cart .product-thumbnail { flex-basis: 96px; width: 96px; }

}
@media (max-width: 991px) {

   .peptix-cart-summary { max-width: 390px; }

}
/* Mobile: one card per product */
@media (max-width: 768px) {
    .woocommerce .peptix-cart a.peptix-cart-btn {
        font-size: 18px;
    }

    /* Heading: title, then the link, centred */
    .peptix-cart-head {
        flex-direction: column;
        gap: 12px;
        text-align: center;
    }

    /* Each product: labelled rows (Product / Price / Quantity / Total) */
    .woocommerce .peptix-cart table.peptix-cart-table thead {
        display: none;
    }

    .woocommerce .peptix-cart table.peptix-cart-table tr.cart_item {
        display: flex;
        flex-direction: column;
        gap: 16px;
        padding: 24px 0;
        border-bottom: 1px solid var(--pc-line);
    }

    .woocommerce .peptix-cart table.peptix-cart-table tr.cart_item td {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 12px;
        padding: 0;
        border: 0;
        background: transparent;
        text-align: right !important;
        max-width: 320px !important;
    }

    .woocommerce .peptix-cart table.peptix-cart-table tr.cart_item td::before {
        content: attr(data-title);
        float: none;
        flex: 0 0 auto;
        font-weight: 400;
        font-size: 16px;
        text-transform: uppercase;
        color: var(--pc-muted);
        min-width: 100px;
        text-align: left;
    }

    .woocommerce .peptix-cart table.peptix-cart-table tr.cart_item td.product-name {
        flex-direction: column;
        align-items: flex-start;
        text-align: left !important;
    }

    .woocommerce .peptix-cart .peptix-cart-product .product-thumbnail { display: block; }
    .woocommerce .peptix-cart .product-thumbnail { flex-basis: auto; width: 100px; }

    .woocommerce .peptix-cart td.product-price,
    .woocommerce .peptix-cart td.product-subtotal {
        font-size: 18px;
    }

    .woocommerce .peptix-cart table.peptix-cart-table tr.peptix-cart-actions-row,
    .woocommerce .peptix-cart table.peptix-cart-table tr.peptix-cart-actions-row td {
        display: block;
    }

    /* Summary: "Sub Total :" left, prices right; note centred */
    .peptix-cart-summary {
        align-items: stretch;
        max-width: none;
        margin-top: 24px;
    }

    .peptix-cart-subtotal {
        justify-content: flex-end;
        font-size: 18px;
    }

    .peptix-cart-subtotal-label {
        margin-right: auto;
        color: var(--pc-text);
    }

    .peptix-cart-subtotal-amount {
        order: 1;
    }

    .peptix-cart-subtotal del {
        order: 2;
        font-size: 16px;
    }

    .peptix-cart-saving {
        font-size: 15px;
    }

    .peptix-cart-note {
        margin-top: 16px !important;
        text-align: center;
    }

    .peptix-cart-payments {
        margin-right: auto;
        margin-left: auto;
    }
}
@media(max-width:420px){
    .woocommerce .peptix-cart .peptix-cart-product {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
}
