/* ==========================================================================
   Moboplus Theme 2026 — checkout (cart / payment / invoice)
   ========================================================================== */

/* the old progress stylesheet paints the body; keep the theme background */
html body.mp-checkout-page,
html body { background-color: var(--mp-bg); }

/* ---------- Checkout header ---------- */
.mp-checkout-head {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 20px;
    margin-top: 14px;
    padding: 14px 24px;
    border-radius: var(--mp-radius-lg);
    background: var(--mp-surface);
    box-shadow: var(--mp-shadow-sm);
}
.mp-checkout-head__logo img { height: 44px; width: auto; display: block; }
.mp-checkout-head__back {
    justify-self: end;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    height: 42px;
    padding: 0 16px;
    border: 1.5px solid var(--mp-border);
    border-radius: 14px;
    color: var(--mp-text-2) !important;
    font-size: 13px;
    text-decoration: none !important;
    transition: border-color .2s, color .2s;
}
.mp-checkout-head__back:hover { border-color: var(--mp-primary); color: var(--mp-primary) !important; }

/* steps */
.mp-steps { display: flex; align-items: center; gap: 8px; }
.mp-steps__item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    min-width: 92px;
    color: var(--mp-text-3) !important;
    font-size: 12.5px;
    text-decoration: none !important;
}
.mp-steps__dot {
    width: 42px;
    height: 42px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--mp-surface-2);
    color: var(--mp-text-3);
    font-size: 15px;
    transition: all .3s var(--mp-ease);
}
.mp-steps__item.is-done { color: var(--mp-text) !important; }
.mp-steps__item.is-done .mp-steps__dot { background: var(--mp-primary-50); color: var(--mp-primary); }
.mp-steps__item.is-current .mp-steps__dot {
    background: var(--mp-grad);
    color: #fff;
    box-shadow: 0 10px 20px -8px rgba(91, 61, 245, .8);
}
.mp-steps__item.is-current { font-weight: 600; color: var(--mp-primary) !important; }
.mp-steps__line {
    width: 70px;
    height: 3px;
    margin-bottom: 26px;
    border-radius: 3px;
    background: var(--mp-border);
    position: relative;
    overflow: hidden;
}
.mp-steps__line.is-done { background: var(--mp-grad); }

/* ---------- Cart layout ---------- */
.mp-cart-page { padding-top: 22px; }
.mp-cart {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 360px;
    gap: 22px;
    align-items: start;
}
.mp-cart__items {
    padding: 22px;
    border-radius: var(--mp-radius-xl);
    background: var(--mp-surface);
    box-shadow: var(--mp-shadow-sm);
}
.mp-cart__head { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; }
.mp-cart__head h1 {
    position: relative;
    margin: 0;
    padding-right: 16px;
    font-size: 21px;
    font-weight: 600;
    color: var(--mp-text);
}
.mp-cart__head h1:before {
    content: "";
    position: absolute;
    right: 0;
    top: 50%;
    width: 6px;
    height: 22px;
    margin-top: -11px;
    border-radius: 6px;
    background: var(--mp-grad);
}
.mp-cart__count {
    padding: 3px 12px;
    border-radius: 999px;
    background: var(--mp-primary-50);
    color: var(--mp-primary);
    font-size: 12.5px;
    font-weight: 600;
}

/* free shipping meter */
.mp-freeship {
    margin-bottom: 16px;
    padding: 12px 16px;
    border-radius: var(--mp-radius);
    background: linear-gradient(135deg, var(--mp-primary-50), #fff5ec);
}
.mp-freeship__text { display: flex; align-items: center; gap: 8px; font-size: 13px; color: var(--mp-text-2); }
.mp-freeship__text i { color: var(--mp-primary); }
.mp-freeship__text b { color: var(--mp-primary); font-weight: 600; }
.mp-freeship__bar {
    height: 6px;
    margin-top: 10px;
    border-radius: 6px;
    background: rgba(91, 61, 245, .12);
    overflow: hidden;
}
.mp-freeship__bar span {
    display: block;
    height: 100%;
    width: 0;
    border-radius: 6px;
    background: var(--mp-grad);
    transition: width .6s var(--mp-ease);
}
.mp-freeship.is-done { background: linear-gradient(135deg, #e7f8f1, #f1fbf7); }
.mp-freeship.is-done .mp-freeship__text i,
.mp-freeship.is-done .mp-freeship__text b { color: #0b8a5f; }
.mp-freeship.is-done .mp-freeship__bar span { background: linear-gradient(90deg, #20c997, #12b886); }

/* items */
.mp-cart__list { display: flex; flex-direction: column; gap: 12px; }
.mp-cart-item {
    position: relative;
    display: grid;
    grid-template-columns: 104px minmax(0, 1fr) auto;
    gap: 16px;
    align-items: center;
    padding: 14px;
    border: 1px solid var(--mp-border);
    border-radius: var(--mp-radius-lg);
    background: #fff;
    transition: box-shadow .3s, border-color .3s;
}
.mp-cart-item:hover { border-color: transparent; box-shadow: 0 18px 36px -22px rgba(15, 16, 32, .35); }
.mp-cart-item__img {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 104px;
    height: 104px;
    padding: 8px;
    border-radius: 18px;
    background: var(--mp-surface-2);
}
.mp-cart-item__img img { max-width: 100%; max-height: 100%; object-fit: contain; mix-blend-mode: multiply; }
.mp-cart-item__info { min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.mp-cart-item__name {
    color: var(--mp-text) !important;
    font-size: 14px;
    font-weight: 600;
    line-height: 1.8;
    text-decoration: none !important;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.mp-cart-item__name:hover { color: var(--mp-primary) !important; }
.mp-cart-item__variant {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    align-self: flex-start;
    padding: 2px 10px;
    border-radius: 999px;
    background: var(--mp-surface-2);
    color: var(--mp-text-2);
    font-size: 12px;
}
.mp-cart-item__variant i { color: var(--mp-primary); font-size: 11px; }
.mp-cart-item__unit { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 8px; font-size: 13px; color: var(--mp-text-2); }
.mp-cart-item__unit .offered { font-size: 12px; color: var(--mp-text-3); text-decoration: line-through; }
.mp-cart-item__unit .off { margin: 0; font-size: 13px !important; color: var(--mp-hot) !important; font-weight: 600; }
.mp-cart-item__unit small { color: var(--mp-text-3); font-size: 11px; }
.mp-cart-item__side { display: flex; flex-direction: column; align-items: flex-end; gap: 10px; }
.mp-cart-item__total { font-size: 16px; font-weight: 600; color: var(--mp-text); white-space: nowrap; }
.mp-cart-item__controls { display: flex; align-items: center; gap: 8px; }
.mp-cart-item__remove {
    flex: 0 0 44px;
    width: 44px;
    height: 44px;
    border: 1.5px solid var(--mp-border);
    border-radius: 14px;
    background: var(--mp-surface-2);
    color: var(--mp-text-3);
    font-size: 14px;
    cursor: pointer;
    transition: background .2s, color .2s, border-color .2s;
}
.mp-cart-item__remove:hover { background: #ffeef2; border-color: #ffd0dc; color: var(--mp-hot); }

/* quantity stepper */
.mp-cart-page .mp-stepper.select_number {
    display: flex;
    align-items: center;
    width: auto;
    height: 44px;
    margin: 0;
    padding: 4px;
    border: 1.5px solid var(--mp-border);
    border-radius: 14px;
    background: #fff;
}
.mp-cart-page .mp-stepper.select_number button {
    width: 32px;
    height: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0;
    border-radius: 10px !important;
    background: var(--mp-surface-2) !important;
    color: var(--mp-primary) !important;
    font-size: 11px;
    box-shadow: none !important;
}
.mp-cart-page .mp-stepper.select_number button:hover { background: var(--mp-primary-50) !important; }
.mp-cart-page .mp-stepper.select_number input {
    width: 40px !important;
    height: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    background: transparent !important;
    text-align: center;
    font-size: 15px;
    font-weight: 600;
    color: var(--mp-text);
}
.mp-cart-page .mp-stepper.select_number input:focus { outline: 0; }

/* ---------- Summary ---------- */
.mp-cart__summary {
    position: sticky;
    top: 24px;
    display: flex;
    flex-direction: column;
    gap: 14px;
}
.mp-summary.checkout-summary {
    margin: 0;
    padding: 20px;
    border: 0;
    border-radius: var(--mp-radius-xl);
    background: var(--mp-surface);
    box-shadow: var(--mp-shadow-sm);
}
.mp-summary__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 14px;
    margin-bottom: 6px;
    border-bottom: 1px solid var(--mp-border);
    font-size: 15px;
    font-weight: 600;
    color: var(--mp-text);
}
.mp-summary__tag {
    padding: 3px 10px;
    border-radius: 999px;
    background: #fff5e6;
    color: #a35a00;
    font-size: 11.5px;
}
.mp-summary__list { margin: 0; padding: 0; list-style: none; }
.mp-summary__list li {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 10px 0;
    font-size: 13.5px;
    color: var(--mp-text-2);
}
.mp-summary__list li span:last-child { color: var(--mp-text); font-weight: 600; white-space: nowrap; }
.mp-summary__list li i { color: var(--mp-primary); margin-left: 4px; }
.mp-summary__discount span:last-child { color: var(--mp-hot) !important; }
.mp-summary__payable {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin: 8px 0 16px;
    padding: 14px 16px;
    border-radius: var(--mp-radius);
    background: var(--mp-surface-2);
    font-size: 13.5px;
    color: var(--mp-text-2);
}
.mp-summary__payable span:last-child { font-size: 19px; font-weight: 600; color: var(--mp-text); }
.mp-summary__cta.mp-btn { height: 54px; font-size: 15px; border-radius: 16px; }
.mp-summary__note {
    display: flex;
    gap: 8px;
    margin: 14px 0 0;
    font-size: 11.5px;
    line-height: 1.9;
    color: var(--mp-text-3);
}
.mp-summary__note i { margin-top: 4px; }
.mp-summary__perks {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin: 0;
    padding: 16px 20px;
    border-radius: var(--mp-radius-lg);
    background: var(--mp-surface);
    box-shadow: var(--mp-shadow-sm);
    list-style: none;
    font-size: 12.5px;
    color: var(--mp-text-2);
}
.mp-summary__perks i { width: 22px; color: var(--mp-mint); }

/* ---------- Empty cart ---------- */
.mp-cart-empty {
    max-width: 640px;
    margin: 20px auto 0;
    padding: 48px 24px;
    border-radius: var(--mp-radius-xl);
    background: var(--mp-surface);
    box-shadow: var(--mp-shadow-sm);
    text-align: center;
}
.mp-cart-empty__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 96px;
    height: 96px;
    margin-bottom: 18px;
    border-radius: 30px;
    background: var(--mp-grad);
    color: #fff;
    font-size: 38px;
    box-shadow: var(--mp-shadow-lg);
}
.mp-cart-empty h2 { margin: 0 0 8px; font-size: 19px; font-weight: 600; color: var(--mp-text); }
.mp-cart-empty p { margin: 0 0 24px; color: var(--mp-text-3); }
.mp-cart-empty__actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }
.mp-cart-empty .mp-btn--ghost {
    display: inline-flex !important;
    padding: 0 22px;
    box-shadow: none;
}

/* ---------- Mobile checkout bar ---------- */
.mp-cartbar { display: none; }

/* ==========================================================================
   Payment page
   ========================================================================== */
.mp-pay-alert {
    display: flex;
    gap: 14px;
    margin-bottom: 18px;
    padding: 16px 18px;
    border-radius: var(--mp-radius-lg);
    background: #fff0f3;
    border: 1px solid #ffd0dc;
    color: #a3123d;
    font-size: 13.5px;
}
.mp-pay-alert__icon {
    flex: 0 0 40px;
    height: 40px;
    border-radius: 13px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    color: var(--mp-hot);
}
.mp-pay-alert ul { margin: 6px 0 0; padding-right: 18px; line-height: 2; }

.mp-pay__main {
    display: flex;
    flex-direction: column;
    gap: 16px;
    min-width: 0;
}
.mp-pay__main .mp-cart__head { margin: 0; }
.mp-pay-card {
    padding: 22px;
    border-radius: var(--mp-radius-xl);
    background: var(--mp-surface);
    box-shadow: var(--mp-shadow-sm);
}
.mp-pay-card__title {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0 0 18px;
    font-size: 16px;
    font-weight: 600;
    color: var(--mp-text);
}
.mp-pay-card__title small { font-size: 12px; font-weight: 400; color: var(--mp-text-3); }
.mp-pay-card__num {
    width: 30px;
    height: 30px;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: var(--mp-grad);
    color: #fff;
    font-size: 13px;
}

/* fields */
.mp-fields {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}
.mp-field { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.mp-field--full { grid-column: 1 / -1; }
.mp-field label { margin: 0; font-size: 13px; font-weight: 600; color: var(--mp-text-2); }
.mp-input { position: relative; }
.mp-input > i {
    position: absolute;
    right: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--mp-text-3);
    font-size: 14px;
    pointer-events: none;
    transition: color .2s;
}
.mp-input:focus-within > i { color: var(--mp-primary); }
.mp-input .form-control { padding-right: 42px; }
.mp-pay .form-control {
    height: 50px;
    padding-left: 14px;
    border: 1.5px solid var(--mp-border);
    border-radius: 14px;
    background: var(--mp-surface-2);
    color: var(--mp-text);
    font-size: 14px;
    box-shadow: none;
    transition: border-color .2s, background .2s, box-shadow .2s;
}
.mp-pay .form-control[dir="ltr"] { text-align: right; }
.mp-pay .form-control[dir="ltr"]:not(:placeholder-shown) { text-align: left; }
.mp-pay textarea.form-control { height: auto; min-height: 96px; padding-top: 12px; resize: vertical; line-height: 1.9; }
.mp-pay .form-control:focus {
    border-color: var(--mp-primary);
    background: #fff;
    box-shadow: 0 0 0 4px var(--mp-primary-50);
    outline: 0;
}
.mp-pay .form-control::placeholder { color: var(--mp-text-3); }

/* select2 */
.mp-pay .select2-container { width: 100% !important; }
.mp-pay .select2-container .select2-selection--single {
    height: 50px;
    border: 1.5px solid var(--mp-border);
    border-radius: 14px;
    background: var(--mp-surface-2);
    transition: border-color .2s, box-shadow .2s;
}
.mp-pay .select2-container--open .select2-selection--single,
.mp-pay .select2-container--focus .select2-selection--single {
    border-color: var(--mp-primary);
    background: #fff;
    box-shadow: 0 0 0 4px var(--mp-primary-50);
}
.mp-pay .select2-container .select2-selection--single .select2-selection__rendered {
    line-height: 47px;
    padding-right: 16px;
    padding-left: 36px;
    color: var(--mp-text);
    font-size: 14px;
}
.mp-pay .select2-container .select2-selection--single .select2-selection__arrow { height: 47px; left: 10px; right: auto; }
.select2-dropdown {
    border: 1px solid var(--mp-border) !important;
    border-radius: 14px !important;
    overflow: hidden;
    box-shadow: 0 20px 40px -18px rgba(15, 16, 32, .3);
    font-family: YekanFa, Tahoma, sans-serif;
}
.select2-search--dropdown .select2-search__field { height: 38px; border-radius: 10px; border: 1.5px solid var(--mp-border) !important; padding: 0 10px; }
.select2-results__option { padding: 8px 14px; font-size: 13.5px; }
.select2-container--default .select2-results__option--highlighted[aria-selected] { background: var(--mp-primary); }

/* order items mini list */
.mp-pay-items__edit {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    font-weight: 400;
    color: var(--mp-primary) !important;
}
.mp-pay-items__edit i { font-size: 10px; }
.mp-pay-items__list {
    display: flex;
    flex-direction: column;
    gap: 10px;
    max-height: 260px;
    margin: 6px 0 0;
    padding: 0;
    overflow-y: auto;
    list-style: none;
}
.mp-pay-items__list li { display: flex; align-items: center; gap: 12px; font-size: 12.5px; }
.mp-pay-items__img {
    position: relative;
    flex: 0 0 52px;
    width: 52px;
    height: 52px;
    padding: 4px;
    border-radius: 14px;
    background: var(--mp-surface-2);
    display: flex;
    align-items: center;
    justify-content: center;
}
.mp-pay-items__img img { max-width: 100%; max-height: 100%; object-fit: contain; mix-blend-mode: multiply; }
.mp-pay-items__qty {
    position: absolute;
    top: -6px;
    left: -6px;
    min-width: 20px;
    height: 20px;
    padding: 0 5px;
    border-radius: 999px;
    border: 2px solid #fff;
    background: var(--mp-ink);
    color: #fff;
    font-size: 10px;
    line-height: 16px;
    text-align: center;
}
.mp-pay-items__name {
    flex: 1;
    min-width: 0;
    color: var(--mp-text);
    line-height: 1.7;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.mp-pay-items__price { font-weight: 600; color: var(--mp-text); white-space: nowrap; }

/* gateways */
.mp-gateways { display: flex; flex-direction: column; gap: 8px; margin: 6px 0 10px; }
.mp-gateway.payment-item {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 0;
    padding: 12px;
    border: 1.5px solid var(--mp-border);
    border-radius: 16px;
    background: #fff;
    font-weight: 400;
    cursor: pointer;
    transition: border-color .2s, box-shadow .2s;
}
.mp-gateway .radio-input { position: absolute; opacity: 0; pointer-events: none; }
.mp-gateway__check {
    flex: 0 0 24px;
    height: 24px;
    border: 2px solid #cfd0dd;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 10px;
    transition: all .2s var(--mp-ease);
}
.mp-gateway__check i { transform: scale(0); transition: transform .2s var(--mp-ease); }
.mp-gateway:has(.radio-input:checked) { border-color: var(--mp-primary); box-shadow: 0 0 0 4px var(--mp-primary-50); }
.mp-gateway .radio-input:checked ~ .mp-gateway__check { border-color: transparent; background: var(--mp-grad); }
.mp-gateway .radio-input:checked ~ .mp-gateway__check i { transform: scale(1); }
.mp-gateway__text { flex: 1; display: flex; flex-direction: column; line-height: 1.6; }
.mp-gateway__text strong { font-size: 13.5px; font-weight: 600; color: var(--mp-text); }
.mp-gateway__text small { font-size: 11.5px; color: var(--mp-text-3); }
.mp-gateway__logo {
    flex: 0 0 52px;
    width: 52px;
    height: 52px;
    padding: 4px;
    border-radius: 12px;
    background: var(--mp-surface-2);
    display: flex;
    align-items: center;
    justify-content: center;
}
.mp-gateway__logo img { max-width: 100%; max-height: 100%; }

.mp-pay__back {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 10px;
    padding: 8px;
    color: var(--mp-text-2) !important;
    font-size: 13px;
    text-decoration: none !important;
}
.mp-pay__back:hover { color: var(--mp-primary) !important; }
.mp-summary__cta[disabled] { opacity: .5; cursor: not-allowed; transform: none; }

/* ==========================================================================
   Invoice / payment result page
   ========================================================================== */
.mp-result {
    position: relative;
    overflow: hidden;
    margin-bottom: 22px;
    padding: 40px 24px 30px;
    border-radius: var(--mp-radius-xl);
    background: var(--mp-surface);
    box-shadow: var(--mp-shadow-sm);
    text-align: center;
}
.mp-result--success { background: linear-gradient(180deg, #ecfbf5 0%, #fff 55%); }
.mp-result--success:before,
.mp-result--success:after {
    content: "";
    position: absolute;
    border-radius: 50%;
    pointer-events: none;
}
.mp-result--success:before { width: 320px; height: 320px; top: -170px; right: -60px; background: radial-gradient(closest-side, rgba(18, 184, 134, .18), transparent); }
.mp-result--success:after { width: 280px; height: 280px; top: -140px; left: -40px; background: radial-gradient(closest-side, rgba(124, 77, 255, .14), transparent); }
.mp-result--error { max-width: 680px; margin: 0 auto; background: linear-gradient(180deg, #fff0f3 0%, #fff 55%); }
.mp-result > * { position: relative; z-index: 1; }
.mp-result__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 84px;
    height: 84px;
    margin-bottom: 16px;
    border-radius: 50%;
    color: #fff;
    font-size: 34px;
    animation: mpPop .6s var(--mp-ease) both;
}
.mp-result--success .mp-result__icon {
    background: linear-gradient(135deg, #20c997, #0ea672);
    box-shadow: 0 0 0 10px rgba(18, 184, 134, .12), 0 18px 36px -12px rgba(18, 184, 134, .7);
}
.mp-result--error .mp-result__icon {
    background: linear-gradient(135deg, #ff5c8a, #f0346a);
    box-shadow: 0 0 0 10px rgba(240, 52, 106, .1), 0 18px 36px -12px rgba(240, 52, 106, .6);
}
.mp-result--error .mp-result__icon--muted {
    background: var(--mp-grad);
    box-shadow: 0 0 0 10px var(--mp-primary-50), var(--mp-shadow-lg);
}
@keyframes mpPop {
    0% { transform: scale(.4); opacity: 0; }
    70% { transform: scale(1.08); opacity: 1; }
    100% { transform: scale(1); }
}
.mp-result h1 { margin: 0 0 6px; font-size: 22px; font-weight: 600; color: var(--mp-text); }
.mp-result__msg { margin: 0; font-size: 14.5px; color: var(--mp-text-2); }
.mp-result--success .mp-result__msg { color: #0b8a5f; font-weight: 600; }
.mp-result--error .mp-result__msg { color: #c0154a; font-weight: 600; }
.mp-result__hint { max-width: 460px; margin: 10px auto 0; font-size: 13px; line-height: 2; color: var(--mp-text-3); }
.mp-result__actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-top: 24px; }
.mp-result__actions .mp-btn--ghost { display: inline-flex !important; padding: 0 22px; }

/* order code chip */
.mp-invoice-code {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    margin-top: 20px;
    padding: 8px 8px 8px 8px;
    padding-right: 18px;
    border: 1.5px dashed #b8ead8;
    border-radius: 18px;
    background: #fff;
}
.mp-invoice-code span { font-size: 12.5px; color: var(--mp-text-3); }
.mp-invoice-code strong { font-size: 19px; font-weight: 600; letter-spacing: 1.5px; color: var(--mp-text); direction: ltr; }
.mp-invoice-code__copy {
    width: 38px;
    height: 38px;
    border: 0;
    border-radius: 12px;
    background: var(--mp-surface-2);
    color: var(--mp-text-2);
    cursor: pointer;
    transition: background .2s, color .2s;
}
.mp-invoice-code__copy:hover { background: var(--mp-primary-50); color: var(--mp-primary); }

/* order progress timeline */
.mp-track {
    display: flex;
    justify-content: center;
    max-width: 640px;
    margin: 28px auto 0;
    padding: 0;
    list-style: none;
}
.mp-track li {
    position: relative;
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    color: var(--mp-text-3);
}
.mp-track li span {
    position: relative;
    z-index: 1;
    width: 40px;
    height: 40px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--mp-surface-2);
    color: var(--mp-text-3);
    font-size: 14px;
}
.mp-track li + li:before {
    content: "";
    position: absolute;
    top: 19px;
    /* RTL: the previous step sits to the right */
    right: calc(-50% + 26px);
    left: calc(50% + 26px);
    height: 3px;
    border-radius: 3px;
    background: var(--mp-border);
}
.mp-track li.is-done { color: var(--mp-text); font-weight: 600; }
.mp-track li.is-done span { background: linear-gradient(135deg, #20c997, #0ea672); color: #fff; }
.mp-track li.is-done + li:before { background: linear-gradient(90deg, #20c997, #12b886); }
.mp-track li.is-current { color: var(--mp-primary); font-weight: 600; }
.mp-track li.is-current span { background: var(--mp-grad); color: #fff; box-shadow: 0 8px 18px -8px rgba(91, 61, 245, .8); }

/* invoice body */
.mp-invoice__title {
    position: relative;
    margin: 0;
    padding-right: 16px;
    font-size: 18px;
    font-weight: 600;
    color: var(--mp-text);
}
.mp-invoice__title:before {
    content: "";
    position: absolute;
    right: 0;
    top: 50%;
    width: 6px;
    height: 20px;
    margin-top: -10px;
    border-radius: 6px;
    background: var(--mp-grad);
}
.mp-invoice__items { max-height: none !important; gap: 0 !important; }
.mp-invoice__item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 12px 0;
    border-bottom: 1px solid var(--mp-border);
    font-size: 13.5px;
}
.mp-invoice__item:last-child { border-bottom: 0; }
.mp-invoice__item .mp-pay-items__img { flex-basis: 64px; width: 64px; height: 64px; }
.mp-invoice__item-info { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.mp-invoice__item-info small { color: var(--mp-text-3); font-size: 12px; }
.mp-invoice__totals {
    margin-top: 14px;
    padding-top: 6px;
    border-top: 1px dashed var(--mp-border);
}
.mp-invoice__totals .mp-summary__payable { margin-bottom: 0; background: #ecfbf5; }
.mp-invoice__totals .mp-summary__payable span:last-child { color: #0b8a5f; }
.mp-summary__tag--ok { background: #e7f8f1 !important; color: #0b8a5f !important; }

.mp-invoice__meta { margin: 4px 0 16px; }
.mp-invoice__meta > div {
    display: flex;
    justify-content: space-between;
    gap: 14px;
    padding: 10px 0;
    border-bottom: 1px solid var(--mp-border);
    font-size: 13px;
}
.mp-invoice__meta > div:last-child { border-bottom: 0; }
.mp-invoice__meta dt { flex: 0 0 auto; font-weight: 400; color: var(--mp-text-3); }
.mp-invoice__meta dd { margin: 0; font-weight: 600; color: var(--mp-text); text-align: left; }
.mp-invoice__meta-full { flex-direction: column; gap: 4px !important; }
.mp-invoice__meta-full dd { text-align: right; font-weight: 400; line-height: 1.9; }
.mp-invoice__meta-full small { color: var(--mp-text-3); }
.mp-invoice__status {
    padding: 3px 10px;
    border-radius: 999px;
    background: #fff5e6;
    color: #a35a00;
    font-size: 12px;
}
.mp-invoice__actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 10px; }
.mp-invoice__actions .mp-btn { height: 44px; padding: 0 10px; font-size: 13px; border-radius: 14px; }

/* print: just the invoice */
@media print {
    html body { max-width: none !important; padding: 0 !important; background: #fff !important; }
    .mp-checkout-head, .mp-footer, .mp-tabbar, .mp-search-sheet, .my_whatsapp,
    .mp-invoice__actions, .mp-summary__cta, .mp-invoice-code__copy, .mp-track, .mp-result__icon { display: none !important; }
    .mp-result, .mp-cart__items, .mp-summary { box-shadow: none !important; border: 1px solid #ddd !important; background: #fff !important; }
    .mp-cart { grid-template-columns: 1fr 1fr !important; }
}

/* ==========================================================================
   Order tracking page
   ========================================================================== */
.mp-track-page { padding-top: 18px; }
.mp-track-hero {
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    gap: 18px;
    margin-bottom: 22px;
    padding: 26px 30px;
    border-radius: var(--mp-radius-xl);
    background: var(--mp-grad);
    color: #fff;
    box-shadow: var(--mp-shadow-lg);
}
.mp-track-hero:after {
    content: "";
    position: absolute;
    width: 320px;
    height: 320px;
    top: -170px;
    left: -40px;
    border-radius: 50%;
    background: radial-gradient(closest-side, rgba(255, 255, 255, .25), transparent);
    pointer-events: none;
}
.mp-track-hero__icon {
    flex: 0 0 64px;
    height: 64px;
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, .18);
    -webkit-backdrop-filter: blur(8px);
    backdrop-filter: blur(8px);
    font-size: 26px;
}
.mp-track-hero h1 { margin: 0 0 4px; font-size: 25px; font-weight: 600; color: #fff; }
.mp-track-hero p { margin: 0; font-size: 13.5px; color: rgba(255, 255, 255, .85); }

.mp-track-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 340px;
    gap: 22px;
    align-items: start;
}
.mp-track-form__hint { margin: -6px 0 18px; font-size: 13.5px; line-height: 2; color: var(--mp-text-2); }
.mp-track-form .mp-pay-alert { margin-bottom: 16px; padding: 12px 14px; }
.mp-track-form .mp-pay-alert ul { margin: 0; padding-right: 16px; }
.mp-track-form .error_label { font-size: 13px; color: #a3123d; }
.mp-track-form__submit.mp-btn { margin-top: 20px; height: 52px; padding: 0 30px; font-size: 14.5px; border-radius: 16px; }
.mp-track-form .mp-pay-card__num i { font-size: 12px; }

.mp-track-help {
    padding: 22px;
    border-radius: var(--mp-radius-xl);
    background: var(--mp-surface);
    box-shadow: var(--mp-shadow-sm);
}
.mp-track-help ul { margin: 0 0 18px; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 12px; }
.mp-track-help li { display: flex; align-items: center; gap: 12px; font-size: 13px; line-height: 1.8; color: var(--mp-text-2); }
.mp-track-help li span {
    flex: 0 0 38px;
    height: 38px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--mp-primary-50);
    color: var(--mp-primary);
}
.mp-track-help .mp-btn--ghost { height: 46px; display: flex !important; }

/* result */
.mp-track-result { padding: 24px; text-align: right; }
.mp-track-result__top {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}
.mp-track-result .mp-invoice-code { margin: 0; border-color: var(--mp-primary-100); }
.mp-track-status {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    border-radius: 999px;
    font-size: 13.5px;
    font-weight: 600;
}
.mp-track-status i { font-size: 8px; }
.mp-track-status--warning { background: #fff5e6; color: #a35a00; }
.mp-track-status--info { background: var(--mp-primary-50); color: var(--mp-primary); }
.mp-track-status--success { background: #e7f8f1; color: #0b8a5f; }
.mp-track-status--danger { background: #ffeef2; color: #d81b4f; }
.mp-track-result .mp-track { max-width: 720px; margin-top: 34px; }
.mp-track-canceled { margin: 20px 0 0; }

.mp-track-post {
    display: flex;
    align-items: center;
    gap: 14px;
    max-width: 720px;
    margin: 28px auto 0;
    padding: 14px 16px;
    border: 1.5px dashed var(--mp-primary-100);
    border-radius: var(--mp-radius-lg);
    background: var(--mp-surface-2);
    text-decoration: none !important;
    transition: border-color .2s, background .2s;
}
.mp-track-post:hover { border-color: var(--mp-primary); background: var(--mp-primary-50); }
.mp-track-post__icon {
    flex: 0 0 46px;
    height: 46px;
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--mp-grad);
    color: #fff;
    font-size: 18px;
}
.mp-track-post__text { flex: 1; display: flex; flex-direction: column; text-align: right; }
.mp-track-post__text small { font-size: 12px; color: var(--mp-text-3); }
.mp-track-post__text strong { font-size: 17px; font-weight: 600; letter-spacing: 1px; color: var(--mp-text); text-align: right; }
.mp-track-post__go { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 600; color: var(--mp-primary); }
.mp-track-post__go i { font-size: 11px; }
.mp-track-meta small { font-weight: 400; color: var(--mp-text-3); }
.mp-tracking-page .mp-cart__summary { top: calc(var(--mp-sticky-top) + 100px); }
.mp-tracking-page .mp-cart__summary > .mp-btn--ghost { height: 48px; display: flex !important; }

/* ==========================================================================
   Responsive
   ========================================================================== */
@media (max-width: 1199px) {
    .mp-cart { grid-template-columns: minmax(0, 1fr) 320px; }
}
@media (max-width: 991px) {
    .mp-track-layout { grid-template-columns: minmax(0, 1fr); }
    .mp-cart { grid-template-columns: minmax(0, 1fr); }
    .mp-cart__summary { position: static; }
    .mp-checkout-head { grid-template-columns: auto 1fr; }
    .mp-checkout-head .mp-steps { grid-column: 1 / -1; grid-row: 2; justify-content: center; }
}
@media (max-width: 767px) {
    .mp-checkout-head { margin-top: 10px; padding: 12px 14px; gap: 12px; border-radius: 20px; }
    .mp-checkout-head__logo img { height: 34px; }
    .mp-checkout-head__back { height: 38px; padding: 0 12px; font-size: 12px; }
    .mp-checkout-head__back span { display: none; }
    .mp-steps { gap: 4px; }
    .mp-steps__item { min-width: 70px; font-size: 11px; }
    .mp-steps__dot { width: 36px; height: 36px; border-radius: 12px; font-size: 13px; }
    .mp-steps__line { width: 32px; margin-bottom: 22px; }

    .mp-cart-page { padding-top: 14px; }
    .mp-cart__items { padding: 14px; border-radius: 24px; }
    .mp-cart__head h1 { font-size: 18px; }
    .mp-cart-item {
        grid-template-columns: 84px minmax(0, 1fr);
        gap: 12px;
        padding: 12px;
    }
    .mp-cart-item__img { width: 84px; height: 84px; border-radius: 16px; }
    .mp-cart-item__name { font-size: 13px; }
    .mp-cart-item__side {
        grid-column: 1 / -1;
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        padding-top: 10px;
        border-top: 1px dashed var(--mp-border);
    }
    .mp-cart-item__total { font-size: 15px; }
    .mp-cart-item__remove { flex-basis: 42px; width: 42px; height: 42px; }
    .mp-cart-page .mp-stepper.select_number { height: 42px; }
    .mp-summary.checkout-summary { padding: 16px; border-radius: 24px; }
    .mp-summary__cta { display: none !important; }

    .mp-cart-page { padding-bottom: 80px; }
    .mp-cartbar {
        position: fixed;
        right: 10px;
        left: 10px;
        bottom: calc(82px + env(safe-area-inset-bottom));
        z-index: 99999;
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 10px;
        padding: 8px 16px 8px 8px;
        border: 1px solid rgba(255, 255, 255, .9);
        border-radius: 20px;
        background: rgba(255, 255, 255, .9);
        -webkit-backdrop-filter: blur(16px) saturate(160%);
        backdrop-filter: blur(16px) saturate(160%);
        box-shadow: 0 18px 40px -14px rgba(15, 16, 32, .35);
    }
    .mp-cartbar__sum { display: flex; flex-direction: column; line-height: 1.5; }
    .mp-cartbar__sum small { font-size: 11px; color: var(--mp-text-3); }
    .mp-cartbar__sum strong { font-size: 15px; font-weight: 600; color: var(--mp-text); }
    .mp-cartbar .mp-btn { height: 46px; padding: 0 18px; font-size: 13.5px; border-radius: 14px; }
    .mp-checkout-page .my_whatsapp { bottom: 160px; }

    .mp-fields { grid-template-columns: minmax(0, 1fr); gap: 14px; }
    .mp-pay-card { padding: 16px 14px; border-radius: 24px; }
    .mp-pay-card__title { font-size: 15px; margin-bottom: 14px; }
    .mp-pay .mp-pay-items__list { max-height: none; }
    .mp-pay__back { display: none; }

    .mp-result { padding: 30px 16px 24px; border-radius: 24px; }
    .mp-result__icon { width: 70px; height: 70px; font-size: 28px; }
    .mp-result h1 { font-size: 19px; }
    .mp-invoice-code strong { font-size: 16px; }
    .mp-track li { font-size: 10.5px; }
    .mp-track li span { width: 34px; height: 34px; border-radius: 12px; font-size: 12px; }
    .mp-track li + li:before { top: 16px; right: calc(-50% + 22px); left: calc(50% + 22px); }
    .mp-invoice .mp-summary__cta { display: flex !important; }
    .mp-invoice-page { padding-bottom: 20px; }

    .mp-track-page { padding-top: 12px; }
    .mp-track-hero { padding: 18px; gap: 14px; border-radius: 24px; }
    .mp-track-hero__icon { flex-basis: 52px; height: 52px; border-radius: 16px; font-size: 21px; }
    .mp-track-hero h1 { font-size: 20px; }
    .mp-track-hero p { font-size: 12.5px; }
    .mp-track-help { padding: 16px; border-radius: 24px; }
    .mp-track-form__submit.mp-btn { width: 100%; }
    .mp-track-result { padding: 18px 14px; }
    .mp-track-result__top { justify-content: center; }
    .mp-track-post { flex-wrap: wrap; }
    .mp-track-post__go { width: 100%; justify-content: center; padding-top: 10px; border-top: 1px dashed var(--mp-border); }
}

/* order items card on the payment page shares the summary card look */
.mp-summary.mp-pay-items {
    padding: 18px 20px;
    border-radius: var(--mp-radius-xl);
    background: var(--mp-surface);
    box-shadow: var(--mp-shadow-sm);
}
@media (max-width: 767px) {
    .mp-summary.mp-pay-items { padding: 16px; border-radius: 24px; }
}

.mp-result .mp-result__msg,
.mp-result .mp-result__hint { text-align: center; }
