/**
 * Checkout page UX — EX-20260811-062 / EX-086 / EX-092 customer-facing
 */

.checkout-page__sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.checkout-page__container {
    max-width: 960px;
    overflow-x: hidden;
}

.checkout-page__note {
    max-width: 42rem;
}

.checkout-page__table-wrap {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.checkout-page__table {
    min-width: 520px;
}

.checkout-page__product {
    overflow-wrap: anywhere;
    word-break: break-word;
    min-width: 8rem;
}

.checkout-page__qty {
    display: inline-flex;
    align-items: center;
    border: 1px solid rgba(0, 0, 0, 0.15);
    border-radius: 0.5rem;
    overflow: hidden;
}

.checkout-page__qty-btn {
    min-width: 2.25rem;
    min-height: 2.25rem;
    border: 0;
    background: #fff;
    font-size: 1.05rem;
    line-height: 1;
    cursor: pointer;
}

.checkout-page__qty-btn:focus {
    outline: none;
    box-shadow: none;
}

.checkout-page__qty-btn:hover,
.checkout-page__qty-btn:focus-visible {
    background: #f8f0f0;
}

.checkout-page__qty-btn:focus-visible {
    outline: 1px solid #873e3f;
    outline-offset: -2px;
}

.checkout-page__qty-btn:disabled,
.checkout-page__qty-btn[aria-disabled="true"] {
    opacity: 0.45;
    cursor: not-allowed;
}

.checkout-page__qty-value {
    min-width: 1.75rem;
    text-align: center;
    font-weight: 600;
    padding: 0 0.2rem;
}

.checkout-page__estimate {
    font-size: 1.05rem;
}

.checkout-page .btn:focus,
.checkout-form .btn:focus,
.checkout-form .form-control:focus,
.checkout-form .form-select:focus {
    outline: none;
    box-shadow: none;
}

.checkout-page .btn:focus-visible,
.checkout-form .btn:focus-visible,
.checkout-empty .btn:focus-visible,
.checkout-success .btn:focus-visible,
.checkout-form .form-control:focus-visible,
.checkout-form .form-select:focus-visible,
.checkout-error:focus-visible,
.checkout-success:focus-visible {
    outline: 1px solid #873e3f;
    outline-offset: 2px;
}

.checkout-error:focus,
.checkout-success:focus {
    outline: 1px solid #873e3f;
    outline-offset: 2px;
}

@media (max-width: 767.98px) {
    .checkout-page__actions {
        flex-direction: column;
        align-items: stretch !important;
    }

    .checkout-page__actions .btn {
        width: 100%;
    }

    .checkout-page__estimate {
        text-align: start !important;
    }
}

@media (max-width: 379.98px) {
    .checkout-page__table {
        min-width: 0;
        font-size: 0.9rem;
    }
}

html[dir="ltr"] .checkout-page__estimate {
    text-align: end;
}

/* EX-086 multi-step */
.checkout-steps {
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem 1rem;
    margin: 0 0 1.5rem;
    padding: 0;
}

.checkout-steps__item {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    opacity: 0.55;
    font-size: 0.92rem;
}

.checkout-steps__item.is-current,
.checkout-steps__item.is-done {
    opacity: 1;
}

.checkout-steps__item.is-current .checkout-steps__label {
    font-weight: 700;
    color: #873e3f;
}

.checkout-steps__index {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.6rem;
    height: 1.6rem;
    border-radius: 999px;
    background: #eee;
    font-size: 0.8rem;
    font-weight: 700;
}

.checkout-steps__item.is-current .checkout-steps__index,
.checkout-steps__item.is-done .checkout-steps__index {
    background: #873e3f;
    color: #fff;
}

/* EX-092 — selected address card */
.checkout-address-selected {
    border: 1px solid rgba(135, 62, 63, 0.35);
    border-radius: 0.75rem;
    box-shadow: 0 0 0 1px rgba(135, 62, 63, 0.08);
    background: #fff;
}

.checkout-address-selected .btn:focus {
    outline: none;
    box-shadow: none;
}

.checkout-address-selected .btn:focus-visible {
    outline: 1px solid #873e3f;
    outline-offset: 2px;
}

.checkout-day-rail {
    display: flex;
    gap: 0.65rem;
    overflow-x: auto;
    padding-bottom: 0.35rem;
    -webkit-overflow-scrolling: touch;
}

.checkout-day-card {
    position: relative;
    flex: 0 0 auto;
    min-width: 5.75rem;
    border: 1px solid rgba(0, 0, 0, 0.12);
    border-radius: 0.65rem;
    padding: 0.55rem 0.45rem;
    text-align: center;
    cursor: pointer;
    background: #fff;
}

.checkout-day-card input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.checkout-day-card.is-selected,
.checkout-day-card:has(input:checked) {
    border-color: #873e3f;
    box-shadow: 0 0 0 1px #873e3f;
}

.checkout-day-card:has(input:focus-visible) {
    outline: 1px solid #873e3f;
    outline-offset: 2px;
}

.checkout-day-card__weekday {
    display: block;
    font-size: 0.75rem;
    color: #666;
}

.checkout-day-card__day {
    display: block;
    font-size: 1.25rem;
    font-weight: 700;
    line-height: 1.2;
}

.checkout-day-card__month {
    display: block;
    font-size: 0.8rem;
}

.checkout-day-card__fee {
    display: block;
    margin-top: 0.35rem;
    font-size: 0.78rem;
}

.checkout-price-old {
    display: block;
    text-decoration: line-through;
    opacity: 0.55;
    font-size: 0.9em;
    margin-bottom: 0.1rem;
}

.checkout-price-now {
    display: block;
    font-weight: 700;
}

.checkout-currency {
    font-size: 0.55em;
    font-weight: 500;
    opacity: 0.85;
    margin-inline-start: 0.12em;
}

/* EX-092 — RTL option cards (slot + payment) */
.checkout-option-list {
    display: flex;
    flex-direction: column;
    gap: 0.55rem;
}

.checkout-option-card {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    width: 100%;
    margin: 0;
    padding: 0.75rem 0.9rem;
    border: 1px solid rgba(0, 0, 0, 0.12);
    border-radius: 0.65rem;
    background: #fff;
    cursor: pointer;
}

.checkout-option-card__input {
    flex: 0 0 auto;
    width: 1.1rem;
    height: 1.1rem;
    margin: 0 !important;
    float: none;
    position: static;
    accent-color: #873e3f;
}

.checkout-option-card__input:focus {
    outline: none;
    box-shadow: none;
}

.checkout-option-card__input:focus-visible {
    outline: 1px solid #873e3f;
    outline-offset: 2px;
}

.checkout-option-card__text {
    flex: 1 1 auto;
    min-width: 0;
    line-height: 1.4;
}

.checkout-option-card.is-selected,
.checkout-option-card:has(input:checked) {
    border-color: #873e3f;
    box-shadow: 0 0 0 1px rgba(135, 62, 63, 0.25);
}

.checkout-option-card.is-disabled,
.checkout-option-card[aria-disabled="true"] {
    opacity: 0.7;
    cursor: not-allowed;
    background: #f8f8f8;
}

.checkout-shipping-summary {
    border-top: 1px solid rgba(0, 0, 0, 0.08);
    padding-top: 1rem;
}

.checkout-shipping-summary dt {
    font-weight: 600;
    margin: 0;
}

.checkout-shipping-summary dd {
    margin: 0;
}

.checkout-shipping-summary-card {
    border: 1px solid rgba(135, 62, 63, 0.18);
    border-radius: 0.75rem;
    padding: 1rem 1.1rem 1.15rem;
    background: #fff;
}

.checkout-shipping-summary__title {
    font-size: 1.15rem;
    font-weight: 700;
    color: #5c2a2b;
    margin: 0 0 0.85rem;
    padding-bottom: 0.55rem;
    border-bottom: 2px solid rgba(135, 62, 63, 0.35);
}

.checkout-shipping-summary__group-title {
    font-size: 0.92rem;
    font-weight: 700;
    color: #333;
    margin: 0 0 0.55rem;
}

.checkout-shipping-summary__primary {
    margin-bottom: 0.85rem;
}

.checkout-shipping-summary__experimental {
    padding-top: 0.75rem;
    border-top: 1px dashed rgba(0, 0, 0, 0.12);
}

.checkout-shipping-summary__list {
    margin: 0;
}

.checkout-shipping-summary__row {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 0.4rem 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

.checkout-shipping-summary__row:last-child {
    border-bottom: 0;
}

.checkout-shipping-summary__row dt {
    color: #666;
    font-weight: 600;
    flex: 0 1 42%;
}

.checkout-shipping-summary__row dd {
    flex: 1 1 auto;
    text-align: end;
    color: #222;
}

.checkout-shipping-summary__row--amount dt,
.checkout-shipping-summary__row--amount dd {
    font-size: 1.05rem;
    color: #5c2a2b;
}

.checkout-shipping-summary__row--amount .checkout-money {
    font-weight: 700;
}

.checkout-shipping-summary__list--meta .checkout-shipping-summary__row {
    padding: 0.28rem 0;
}

.checkout-shipping-summary__hint {
    font-size: 0.82rem;
    line-height: 1.65;
    color: #555;
    margin: 0.45rem 0 0;
}

.checkout-g2-details {
    margin-top: 0.85rem;
}

.checkout-g2-details > summary {
    cursor: pointer;
    font-weight: 600;
    color: #5c2a2b;
}

.checkout-g2-compare-title {
    font-size: 0.95rem;
    font-weight: 700;
    margin: 0.75rem 0 0.5rem;
}

.checkout-g2-origin-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.65rem;
}

@media (min-width: 768px) {
    .checkout-g2-origin-grid {
        grid-template-columns: 1fr 1fr;
    }
}

.checkout-g2-origin-card {
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 0.6rem;
    padding: 0.7rem 0.8rem;
    background: #fafafa;
}

.checkout-g2-origin-card.is-proposed {
    border-color: rgba(135, 62, 63, 0.45);
    background: #fbf6f6;
    box-shadow: 0 0 0 1px rgba(135, 62, 63, 0.12);
}

.checkout-g2-origin-card__head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 0.5rem;
    margin-bottom: 0.4rem;
}

.checkout-g2-origin-card__title {
    font-size: 0.95rem;
    font-weight: 700;
    margin: 0;
}

.checkout-g2-badge {
    display: inline-block;
    flex: 0 0 auto;
    font-size: 0.72rem;
    font-weight: 700;
    line-height: 1.3;
    color: #fff;
    background: #873e3f;
    border-radius: 999px;
    padding: 0.15rem 0.5rem;
    white-space: nowrap;
}

.checkout-g2-origin-card__line {
    font-size: 0.85rem;
    margin: 0 0 0.25rem;
}

.checkout-map-callout {
    border: 1px solid rgba(135, 62, 63, 0.28);
    background: #f8f3f3;
    border-radius: 0.6rem;
    padding: 0.75rem 0.85rem;
}

.checkout-map-callout__text {
    margin: 0;
    font-size: 0.9rem;
    line-height: 1.65;
    color: #3d2425;
    font-weight: 600;
}

.checkout-bank-list {
    display: grid;
    gap: 0.75rem;
}

.checkout-bank-card {
    display: flex;
    gap: 0.75rem;
    align-items: flex-start;
    border: 1px solid #e3d5d5;
    border-radius: 0.6rem;
    padding: 0.75rem;
    background: #fff;
}

.checkout-bank-card.is-disabled {
    opacity: 0.65;
}

.checkout-copy-btn {
    border: 1px dashed #c21a1a;
    background: #fff;
    color: inherit;
    border-radius: 0.4rem;
    padding: 0.15rem 0.45rem;
    font-family: inherit;
    font-size: inherit;
    cursor: pointer;
}
.checkout-copy-btn:hover,
.checkout-copy-btn:focus-visible {
    background: rgba(194, 26, 26, 0.08);
    outline: 2px solid #c21a1a;
    outline-offset: 1px;
}

.checkout-price-now--pending {
    font-size: 0.78rem;
    font-weight: 600;
    color: #873e3f;
}

@media (max-width: 576px) {
    .checkout-bank-card {
        flex-direction: column;
    }
}

/* 028 — policy-driven Checkout Auth UX (optional offer / required messaging) */
.checkout-auth-ux {
    border: 1px solid rgba(0, 0, 0, 0.08);
}

.checkout-auth-ux__copy {
    max-width: 40rem;
}

.checkout-auth-ux__actions .btn-link {
    text-decoration: underline;
    padding-inline: 0.25rem;
}

.checkout-auth-ux__status {
    font-size: 0.95rem;
}
