/* Checkout / Shipping / Payment — تکمیل استایل فرانت */

.zp-checkout-page .zp-cart-breadcrumb {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: #808080;
}

.zp-checkout-page .zp-cart-breadcrumb__home {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: inherit;
    text-decoration: none;
}

.zp-checkout-flow .stepper a.step {
    text-decoration: none;
    color: inherit;
}

.zp-checkout-flow .stepper a.step.inactive .circle {
    cursor: pointer;
}

.zp-payment-review-items .border-b:last-child {
    border-bottom: none;
}

.zp-checkout-page .zp-select-wrap {
    position: relative;
}

.zp-checkout-page .zp-select-chevron {
    position: absolute;
    left: 18px;
    top: 50%;
    transform: translateY(-50%);
    margin-top: 4px;
    pointer-events: none;
}

.zp-checkout-page .zp-iran-select:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    background-color: #fafafa !important;
}

/* روش‌های ارسال — مطابق Figma */
.zp-shipping-empty-msg {
    color: #666;
    font-size: 14px;
    padding: 16px 0;
    margin: 0;
}

.zp-shipping-options {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.zp-shipping-rate {
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 22px 20px 22px 16px;
    border: 1px solid #e6e6e6;
    border-radius: 12px;
    background: #fff;
    cursor: pointer;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
    text-align: right;
    direction: rtl;
}

.zp-shipping-rate:hover {
    border-color: #c5c5c5;
}

.zp-shipping-rate.is-selected {
    border: 2px solid #1b3a9f;
    padding: 21px 19px 21px 15px;
}

.zp-shipping-rate__radio-wrap {
    flex-shrink: 0;
    position: relative;
    width: 28px;
    height: 28px;
}

.zp-shipping-rate__radio-wrap .shipping-radio {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
    pointer-events: none;
}

.zp-shipping-rate__radio {
    display: block;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    border: 2px solid #d1d5db;
    background: #fff;
    box-sizing: border-box;
}

.zp-shipping-rate.is-selected .zp-shipping-rate__radio {
    border-color: #1b3a9f;
    background: #1b3a9f;
    box-shadow: inset 0 0 0 4px #fff;
}

.zp-shipping-rate__body {
    flex: 1;
    min-width: 0;
}

.zp-shipping-rate__title-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-start;
    gap: 8px;
}

.zp-shipping-rate__title {
    font-weight: 700;
    font-size: 16px;
    line-height: 24px;
    color: #1a1a1a;
}

.zp-shipping-rate__badge {
    font-size: 13px;
    line-height: 20px;
    color: #112360;
    background: #e9ecf7;
    border-radius: 999px;
    padding: 2px 12px;
    white-space: nowrap;
}

.zp-shipping-rate__hint {
    margin: 8px 0 0;
    font-size: 14px;
    line-height: 20px;
    color: #666;
}

.zp-shipping-rate__meta {
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    min-width: 72px;
    color: #808080;
}

.zp-shipping-rate.is-selected .zp-shipping-rate__meta {
    color: #1b3a9f;
}

.zp-shipping-rate__icon {
    display: flex;
    align-items: center;
    justify-content: center;
}

.zp-shipping-rate__price {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    font-weight: 700;
    font-size: 16px;
    line-height: 24px;
    color: #333;
}

.zp-shipping-rate__price-unit {
    font-size: 13px;
    font-weight: 500;
    color: #808080;
}

@media (max-width: 576px) {
    .zp-shipping-rate {
        flex-wrap: wrap;
        padding: 16px;
    }

    .zp-shipping-rate.is-selected {
        padding: 15px;
    }

    .zp-shipping-rate__meta {
        flex-direction: row;
        width: 100%;
        justify-content: flex-end;
        order: 3;
    }
}

.zp-coupon-field--checkout {
    display: flex;
    flex-direction: row;
    align-items: stretch;
    direction: rtl;
    gap: 6px;
    background: #f7f7f7;
    border-radius: 12px;
    padding: 6px;
}

.zp-coupon-field--checkout .zp-coupon-field__input,
.zp-coupon-field--checkout input {
    flex: 1;
    min-width: 0;
    border: none !important;
    background: transparent !important;
    padding: 12px 14px !important;
    font-size: 14px;
    text-align: right;
}

.zp-coupon-field--checkout .zp-apply-coupon-btn {
    position: static;
    transform: none;
    flex-shrink: 0;
    align-self: center;
    background: #fff;
    color: #ccc;
    border: none;
    border-radius: 8px;
    padding: 8px 20px;
    font-weight: 700;
    font-size: 13px;
    cursor: pointer;
}

/* انتخاب درگاه پرداخت — مطابق Figma */
.zp-payment-empty-msg {
    color: #666;
    font-size: 14px;
    padding: 16px 0;
    margin: 0;
}

.zp-payment-methods {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.zp-payment-method {
    display: flex;
    flex-direction: row;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 20px 18px;
    border: 1px solid #e6e6e6;
    border-radius: 12px;
    background: #fff;
    cursor: pointer;
    transition: border-color 0.15s ease;
    text-align: right;
    direction: rtl;
}

.zp-payment-method:hover {
    border-color: #c5c5c5;
}

.zp-payment-method.is-selected {
    border: 2px solid #1b3a9f;
    padding: 19px 17px;
}

.zp-payment-method__radio-wrap {
    flex-shrink: 0;
    position: relative;
    width: 28px;
    height: 28px;
    order: 1;
}

.zp-payment-method__radio-wrap .zp-payment-method-radio {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
    pointer-events: none;
}

.zp-payment-method__radio {
    display: block;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    border: 2px solid #d1d5db;
    background: #fff;
    box-sizing: border-box;
}

.zp-payment-method.is-selected .zp-payment-method__radio {
    border-color: #1b3a9f;
    background: #1b3a9f;
    box-shadow: inset 0 0 0 4px #fff;
}

.zp-payment-method__body {
    flex: 1;
    min-width: 0;
    order: 2;
}

.zp-payment-method__title-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-start;
    gap: 12px;
}

.zp-payment-method__title {
    font-weight: 700;
    font-size: 16px;
    line-height: 24px;
    color: #1a1a1a;
    margin: 0;
    cursor: pointer;
}

.zp-payment-method__brand {
    display: flex;
    align-items: center;
    max-height: 32px;
}

.zp-payment-method__brand img {
    max-height: 28px;
    width: auto;
    max-width: 80px;
    object-fit: contain;
    display: block;
}

.zp-payment-method__meta {
    flex-shrink: 0;
    order: 3;
    color: #808080;
}

.zp-payment-method.is-selected .zp-payment-method__meta {
    color: #1b3a9f;
}

.zp-payment-method__card-icon {
    display: flex;
    align-items: center;
    justify-content: center;
}

.zp-payment-method .payment_box {
    flex: 0 0 100%;
    width: 100%;
    order: 4;
    margin: 8px 0 0;
    padding: 12px 14px;
    background: #f7f7f7;
    border-radius: 10px;
    font-size: 14px;
    color: #666;
}

.zp-payment-method .payment_box p {
    margin: 0 0 8px;
}

.zp-payment-method .payment_box input,
.zp-payment-method .payment_box select {
    width: 100%;
    max-width: 100%;
}

.zp-place-order-hidden {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

.zp-payment-checkout-extras .woocommerce-terms-and-conditions-wrapper {
    margin-top: 16px;
    font-size: 14px;
    color: #666;
}

.zp-payment-box .woocommerce-checkout-payment {
    background: transparent;
}

#cart-loading {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(255, 255, 255, 0.75);
    backdrop-filter: blur(4px);
    z-index: 99999;
    align-items: center;
    justify-content: center;
}

#cart-loading p {
    font-size: 18px;
    font-weight: 600;
    margin: 0;
}

@media (max-width: 576px) {
    .zp-coupon-field--checkout {
        flex-wrap: nowrap;
    }

    .zp-coupon-field--checkout .zp-apply-coupon-btn {
        padding: 8px 12px;
        font-size: 12px;
    }
}
