/* ============================================================
   Cart page (/cart) — scoped under .sc-page.
   The PaymentSummary component is shared with checkout pages, so it is
   only restyled here via .sc-summary (its markup is untouched).
   ============================================================ */

.sc-page {
    --sc-navy: #173a75;
    --sc-navy-2: #214687;
    --sc-blue: #3066be;
    --sc-light: #f0f5ff;
    --sc-chip: #dae7ff;
    --sc-yellow: #ffd812;
    --sc-green: #0bb17a;
    --sc-text: #2b3a55;
    --sc-muted: #5f6f8c;
    --sc-border: #e1e8f5;

    padding: 28px 0 56px;
    color: var(--sc-text);
    background: var(--sc-light);
    overflow-x: hidden;
}

.sc-page.is-busy {
    cursor: progress;
}

.sc-page.is-busy .sc-items {
    opacity: .6;
    pointer-events: none;
}

/* ---------- Head ---------- */
.sc-page .sc-crumbs {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-start;
    width: auto;
    gap: 8px;
    margin-bottom: 10px;
    font-size: 13px;
    color: var(--sc-muted);
}

.sc-crumbs a {
    color: var(--sc-blue);
    text-decoration: none;
}

.sc-crumbs .fa-chevron-right {
    font-size: 10px;
    opacity: .6;
}

.sc-top {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 22px;
}

.sc-top h1 {
    margin: 0;
    font-size: 34px;
    font-weight: 700;
    color: var(--sc-navy);
}

.sc-top h1 span {
    color: var(--sc-blue);
}

.sc-steps {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.sc-steps li {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    font-weight: 600;
    color: var(--sc-muted);
}

.sc-steps li + li::before {
    content: "";
    width: 28px;
    height: 2px;
    margin-right: 2px;
    background: #c9d5ea;
}

.sc-steps li span {
    width: 28px;
    height: 28px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-size: 13px;
    color: var(--sc-muted);
    background: #fff;
    border: 1.5px solid #c9d5ea;
}

.sc-steps li.active {
    color: var(--sc-navy);
}

.sc-steps li.active span {
    color: var(--sc-navy);
    border-color: var(--sc-yellow);
    background: var(--sc-yellow);
}

/* ---------- Items card ---------- */
.sc-card {
    border: 1px solid var(--sc-border);
    border-radius: 22px;
    background: #fff;
    overflow: hidden;
}

.sc-card-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    padding: 20px 24px;
    border-bottom: 1px solid #eef2f9;
}

.sc-card-head h2,
.sc-summary h2 {
    margin: 0;
    font-size: 20px;
    font-weight: 700;
    color: var(--sc-navy);
}

.sc-card-head span {
    font-size: 14px;
    color: var(--sc-muted);
}

.sc-items {
    margin: 0;
    padding: 0;
    list-style: none;
    transition: opacity .2s;
}

.sc-item {
    display: grid;
    grid-template-columns: 96px minmax(0, 1fr) auto;
    align-items: center;
    gap: 18px;
    padding: 18px 24px;
    border-bottom: 1px solid #eef2f9;
    transition: opacity .2s;
}

.sc-item:last-child {
    border-bottom: 0;
}

.sc-item.is-removing {
    opacity: .4;
}

.sc-img {
    width: 96px;
    height: 96px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    border: 1px solid var(--sc-border);
    border-radius: 16px;
    background: #fff;
}

.sc-img img {
    width: 100%;
    height: 100%;
    padding: 6px;
    object-fit: contain;
}

.sc-name {
    margin: 0 0 6px;
    font-size: 16px;
    font-weight: 700;
    line-height: 1.35;
    color: var(--sc-navy);
}

.sc-attrs {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 8px;
}

.sc-attrs span {
    padding: 3px 10px;
    border-radius: 999px;
    font-size: 12.5px;
    color: var(--sc-muted);
    background: var(--sc-light);
}

.sc-attrs b {
    color: var(--sc-navy);
}

.sc-unit {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    gap: 6px 10px;
    font-size: 14px;
}

.sc-unit b {
    font-size: 16px;
    color: var(--sc-navy);
}

.sc-unit s {
    color: #9aa4b8;
}

.sc-off {
    font-size: 12.5px;
    font-weight: 700;
    color: var(--sc-green);
}

.sc-bv {
    padding: 2px 8px;
    border-radius: 6px;
    font-size: 11.5px;
    font-weight: 700;
    color: var(--sc-navy);
    background: var(--sc-chip);
}

.sc-actions {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 10px;
}

.sc-qty {
    display: inline-flex;
    align-items: center;
    height: 40px;
    border: 1.5px solid var(--sc-border);
    border-radius: 999px;
    background: #fff;
}

.sc-qty-btn {
    width: 36px;
    height: 100%;
    border: 0;
    font-size: 12px;
    color: var(--sc-navy);
    background: transparent;
    cursor: pointer;
}

.sc-qty-btn:disabled {
    color: #c3cad8;
    cursor: not-allowed;
}

.sc-qty-val {
    min-width: 28px;
    font-size: 15px;
    font-weight: 700;
    text-align: center;
    color: var(--sc-navy);
}

.sc-line-total {
    font-size: 18px;
    font-weight: 800;
    color: var(--sc-navy);
}

.sc-remove {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 0;
    border: 0;
    font-size: 13px;
    font-weight: 600;
    color: #b42318;
    background: transparent;
    cursor: pointer;
}

.sc-remove:hover {
    text-decoration: underline;
}

.sc-card-foot {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 16px 24px;
    border-top: 1px solid #eef2f9;
    background: #fbfcff;
}

.sc-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    font-weight: 700;
    color: var(--sc-blue);
    text-decoration: none;
}

.sc-link:hover {
    text-decoration: underline;
}

.sc-note {
    font-size: 13.5px;
    color: #b42318;
}

/* ---------- Summary (restyles the shared PaymentSummary markup) ---------- */
.sc-summary {
    position: sticky;
    top: 20px;
    padding: 22px 22px 18px;
    border: 1px solid var(--sc-border);
    border-radius: 22px;
    background: #fff;
}

.sc-summary h2 {
    margin-bottom: 14px;
}

.sc-summary .price-details {
    margin: 0;
    padding: 0;
    border: 0;
    background: transparent;
    box-shadow: none;
}

.sc-summary .priceDetail-base-row {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
    padding: 7px 0;
    font-size: 14.5px;
    color: var(--sc-muted);
}

.sc-summary .priceDetail-base-row label {
    margin: 0;
    font-weight: 500;
}

.sc-summary .priceDetail-base-row label b {
    font-weight: 500;
}

.sc-summary .priceDetail-base-row span {
    font-weight: 700;
    color: var(--sc-text);
    white-space: nowrap;
}

.sc-summary hr {
    margin: 10px 0;
    border: 0;
    border-top: 1px dashed #c9d5ea;
    opacity: 1;
}

/* payable amount = row right after the divider */
.sc-summary hr + .priceDetail-base-row {
    padding: 10px 0 4px;
}

.sc-summary hr + .priceDetail-base-row label,
.sc-summary hr + .priceDetail-base-row label b {
    font-weight: 700;
    color: var(--sc-navy);
}

.sc-summary hr + .priceDetail-base-row span {
    font-size: 22px;
    font-weight: 800;
    color: var(--sc-navy);
}

.sc-summary .Checkoutdiv,
.sc-summary .addtocart {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 16px;
}

.sc-summary .addtocart br {
    display: none;
}

.sc-summary .submit_btn {
    display: flex !important;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100% !important;
    height: 50px;
    margin: 0 !important;
    padding: 0 18px !important;
    border: 2px solid var(--sc-navy) !important;
    border-radius: 999px !important;
    font-size: 15px !important;
    font-weight: 700 !important;
    text-transform: none;
    color: var(--sc-navy) !important;
    background: #fff !important;
    box-shadow: none !important;
    text-decoration: none;
    transition: background .2s, color .2s;
}

.sc-summary .submit_btn:hover {
    color: #fff !important;
    background: var(--sc-navy) !important;
}

/* primary action (first button) in yellow */
.sc-summary .Checkoutdiv .submit_btn,
.sc-summary .addtocart .submit_btn:first-child {
    color: #1c2430 !important;
    border-color: var(--sc-yellow) !important;
    background: var(--sc-yellow) !important;
}

.sc-summary .Checkoutdiv .submit_btn:hover,
.sc-summary .addtocart .submit_btn:first-child:hover {
    color: #1c2430 !important;
    border-color: #ffe04a !important;
    background: #ffe04a !important;
}

.sc-trust {
    display: grid;
    gap: 8px;
    margin: 18px 0 0;
    padding: 16px 0 0;
    border-top: 1px solid #eef2f9;
    list-style: none;
}

.sc-trust li {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 13px;
    color: var(--sc-muted);
}

.sc-trust i {
    width: 18px;
    color: var(--sc-blue);
}

/* ---------- Empty state ---------- */
.sc-empty {
    max-width: 560px;
    margin: 10px auto;
    padding: 48px 28px;
    border: 1px solid var(--sc-border);
    border-radius: 24px;
    text-align: center;
    background: #fff;
}

.sc-empty-icon {
    width: 84px;
    height: 84px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 16px;
    border-radius: 50%;
    font-size: 34px;
    color: var(--sc-navy);
    background: var(--sc-chip);
}

.sc-empty h2 {
    margin: 0 0 8px;
    font-size: 24px;
    font-weight: 700;
    color: var(--sc-navy);
}

.sc-empty p {
    margin: 0 0 22px;
    color: var(--sc-muted);
}

.sc-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 13px 30px;
    border-radius: 999px;
    font-size: 15px;
    font-weight: 700;
    color: #1c2430;
    background: var(--sc-yellow);
    text-decoration: none;
}

.sc-btn:hover {
    color: #1c2430;
    background: #ffe04a;
    text-decoration: none;
}

/* ---------- Responsive ---------- */
@media (max-width: 991px) {
    .sc-summary {
        position: static;
    }
}

@media (max-width: 767px) {
    .sc-page {
        padding: 20px 0 40px;
    }

    .sc-page .container {
        padding-left: 16px;
        padding-right: 16px;
    }

    .sc-top {
        gap: 12px;
        margin-bottom: 16px;
    }

    .sc-top h1 {
        font-size: 26px;
    }

    .sc-steps li {
        font-size: 12.5px;
        gap: 6px;
    }

    .sc-steps li span {
        width: 24px;
        height: 24px;
        font-size: 12px;
    }

    .sc-steps li + li::before {
        width: 14px;
    }

    .sc-card,
    .sc-summary {
        border-radius: 18px;
    }

    .sc-card-head {
        padding: 16px;
    }

    /* item: image + info on top row, actions underneath */
    .sc-item {
        grid-template-columns: 78px minmax(0, 1fr);
        gap: 12px 14px;
        padding: 16px;
    }

    .sc-img {
        width: 78px;
        height: 78px;
        border-radius: 12px;
    }

    .sc-name {
        font-size: 15px;
    }

    .sc-actions {
        grid-column: 1 / -1;
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
    }

    .sc-line-total {
        margin-left: auto;
        font-size: 17px;
    }

    .sc-remove {
        order: 3;
        margin-left: 12px;
        font-size: 0;
    }

    .sc-remove i {
        font-size: 16px;
    }

    .sc-card-foot {
        padding: 14px 16px;
    }

    .sc-summary {
        padding: 18px 16px 16px;
    }
}
