/*
 * Step 7 — Checkout / Pay redesign
 * Approved mobile-first direction for Checkout and Manual UPI Pay.
 * Scoped to Store checkout/pay templates so purchase logic remains untouched.
 */

.pt-checkout-wrap,
.pt-pay-wrap {
    font-family: var(--pt-store-font, "Noto Sans Devanagari", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif);
    color: var(--pt-store-text, #334155);
}

/* ========================================================================== 
   CHECKOUT
   ========================================================================== */

.pt-checkout-wrap {
    max-width: 1080px;
    padding: 28px 20px 60px;
}

.pt-checkout-wrap .pt-breadcrumbs {
    margin-bottom: 14px;
    color: var(--pt-store-muted, #64748b);
    font-size: 13px;
}

.pt-checkout-wrap .pt-breadcrumbs a {
    color: var(--pt-store-muted, #64748b);
}

.pt-checkout-wrap .pt-breadcrumbs a:hover {
    color: var(--pt-store-brand-hover, #1d4ed8);
}

.pt-checkout-intro {
    margin-bottom: 22px;
}

.pt-checkout-heading {
    margin: 0 0 5px;
    color: var(--pt-store-ink, #0f172a);
    font-size: 28px;
    line-height: 1.25;
    font-weight: 800;
}

.pt-checkout-subtitle {
    margin: 0;
    color: var(--pt-store-muted, #64748b);
    font-size: 14px;
    line-height: 1.6;
}

.pt-checkout-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.18fr) minmax(300px, .82fr);
    gap: 22px;
    align-items: start;
}

.pt-checkout-form-section,
.pt-checkout-summary {
    background: var(--pt-store-surface, #fff);
    border: 1px solid var(--pt-store-line, #e2e8f0);
    border-radius: var(--pt-store-radius-lg, 18px);
    box-shadow: var(--pt-store-shadow-shell, 0 12px 34px rgba(15, 23, 42, .08));
}

.pt-checkout-form-section {
    padding: 24px;
    min-width: 0;
}

.pt-checkout-form {
    gap: 0;
}

.pt-checkout-section {
    padding: 0;
    border: 0;
    border-radius: 0;
    background: transparent;
}

.pt-checkout-section + .pt-checkout-section {
    margin-top: 22px;
    padding-top: 22px;
    border-top: 1px solid var(--pt-store-line, #e2e8f0);
}

.pt-checkout-section-title {
    gap: 8px;
    margin: 0 0 14px;
    color: var(--pt-store-ink, #0f172a);
    font-size: 17px;
    line-height: 1.35;
    font-weight: 800;
}

.pt-checkout-section-title svg {
    color: var(--pt-store-brand, #2563eb);
}

.pt-checkout-login-hint {
    margin-bottom: 14px;
    padding: 10px 12px;
    color: var(--pt-store-text, #334155);
    background: var(--pt-store-brand-soft, #eff6ff);
    border: 1px solid var(--pt-store-brand-soft-border, #bfdbfe);
    border-radius: var(--pt-store-radius, 12px);
    font-size: 13px;
}

.pt-checkout-login-hint a {
    color: var(--pt-store-brand, #2563eb);
    font-weight: 800;
}

.pt-checkout-fields {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.pt-checkout-fields .pt-form-group {
    margin: 0;
}

.pt-checkout-fields .pt-form-group--full {
    grid-column: 1 / -1;
}

.pt-checkout-wrap .pt-form-group label {
    color: var(--pt-store-text, #334155);
    font-size: 13px;
    font-weight: 800;
}

.pt-checkout-wrap .pt-form-group input[type="text"],
.pt-checkout-wrap .pt-form-group input[type="email"],
.pt-checkout-wrap .pt-form-group input[type="tel"] {
    min-height: 46px;
    padding: 10px 12px;
    color: var(--pt-store-ink, #0f172a);
    background: #fff;
    border: 1px solid #cbd5e1;
    border-radius: 11px;
    font-size: 16px;
}

.pt-checkout-wrap .pt-form-group input:focus {
    border-color: var(--pt-store-brand, #2563eb);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, .12);
}

.pt-checkout-wrap .pt-form-group input[readonly] {
    background: var(--pt-store-page, #f8fafc);
}

.pt-checkout-wrap .pt-form-group small {
    color: var(--pt-store-muted, #64748b);
}

.pt-checkout-gateways {
    gap: 10px;
}

.pt-checkout-gateway-option {
    min-height: 62px;
}

.pt-checkout-gateway-card {
    min-height: 62px;
    gap: 12px;
    padding: 13px;
    border: 1px solid var(--pt-store-line, #e2e8f0);
    border-radius: 13px;
}

.pt-checkout-gateway-option input:checked + .pt-checkout-gateway-card {
    border-color: var(--pt-store-brand, #2563eb);
    background: var(--pt-store-brand-soft, #eff6ff);
}

.pt-checkout-gateway-card:hover {
    border-color: var(--pt-store-brand-soft-border, #bfdbfe);
}

.pt-checkout-gateway-info {
    min-width: 0;
    flex: 1;
}

.pt-checkout-gateway-info strong {
    color: var(--pt-store-ink, #0f172a);
    font-size: 14px;
    font-weight: 800;
}

.pt-checkout-gateway-info span {
    color: var(--pt-store-muted, #64748b);
    font-size: 12px;
    line-height: 1.45;
}

.pt-checkout-wrap .pt-gw-badge {
    flex: 0 0 auto;
    border-radius: 999px;
    padding: 5px 8px;
    font-size: 11px;
    letter-spacing: 0;
    text-transform: none;
}

.pt-checkout-wrap .pt-gw-badge-instant {
    color: var(--pt-store-success, #15803d);
    background: var(--pt-store-success-soft, #f0fdf4);
}

.pt-checkout-wrap .pt-gw-badge-manual {
    color: var(--pt-store-warning, #b45309);
    background: #fffbeb;
}

.pt-checkout-submit-btn {
    width: 100%;
    min-height: 48px;
    margin-top: 20px;
    padding: 13px 18px;
    border-radius: var(--pt-store-radius, 12px);
    background: var(--pt-store-brand, #2563eb);
    box-shadow: none;
    font-size: 15px;
    font-weight: 800;
}

.pt-checkout-submit-btn:hover {
    background: var(--pt-store-brand-hover, #1d4ed8);
    box-shadow: none;
}

.pt-checkout-trust {
    display: flex;
    gap: 8px;
    align-items: flex-start;
    margin: 10px 2px 0;
    color: var(--pt-store-muted, #64748b);
    font-size: 12px;
    line-height: 1.5;
}

.pt-checkout-trust svg {
    flex: 0 0 auto;
    margin-top: 1px;
    color: var(--pt-store-brand, #2563eb);
}

.pt-checkout-summary-section {
    position: sticky;
    top: 24px;
}

.pt-checkout-summary {
    overflow: hidden;
}

.pt-checkout-summary-title {
    margin: 0;
    padding: 18px 20px 14px;
    color: var(--pt-store-ink, #0f172a);
    background: transparent;
    border: 0;
    font-size: 17px;
    font-weight: 800;
}

.pt-checkout-product {
    padding: 0 20px 16px;
    border-bottom: 1px solid var(--pt-store-line, #e2e8f0);
}

.pt-checkout-cart-item + .pt-checkout-cart-item {
    padding-top: 14px;
}

.pt-checkout-product-badges {
    gap: 6px;
    margin-bottom: 8px;
}

.pt-checkout-wrap .pt-product-badge {
    border-radius: 999px;
    padding: 4px 7px;
    font-size: 10px;
    font-weight: 800;
}

.pt-checkout-product-title {
    margin: 0 0 8px;
    color: var(--pt-store-ink, #0f172a);
    font-size: 15px;
    line-height: 1.4;
    font-weight: 800;
}

.pt-checkout-product-meta {
    gap: 7px 12px;
    color: var(--pt-store-muted, #64748b);
    font-size: 12px;
}

.pt-checkout-cart-item-row {
    gap: 12px;
}

.pt-checkout-cart-item-price {
    color: var(--pt-store-ink, #0f172a);
    font-weight: 800;
    white-space: nowrap;
}

.pt-checkout-summary-row {
    padding: 8px 20px;
    color: var(--pt-store-text, #334155);
    font-size: 13px;
}

.pt-checkout-summary-total {
    margin-top: 6px;
    padding-top: 14px;
    padding-bottom: 14px;
    border-top: 1px solid var(--pt-store-line, #e2e8f0);
    color: var(--pt-store-ink, #0f172a);
    font-size: 17px;
    font-weight: 900;
}

.pt-checkout-summary-price {
    gap: 8px;
}

.pt-checkout-discount-badge {
    display: inline-block;
    margin: 0 20px 10px;
    padding: 6px 9px;
    color: var(--pt-store-success, #15803d);
    background: var(--pt-store-success-soft, #f0fdf4);
    border-radius: 999px;
    font-size: 12px;
    font-weight: 800;
}

.pt-checkout-tax-note {
    margin: 0 20px 10px;
    color: var(--pt-store-muted, #64748b);
    font-size: 11px;
}

.pt-checkout-secure-note {
    justify-content: flex-start;
    gap: 7px;
    padding: 12px 20px 16px;
    color: var(--pt-store-muted, #64748b);
    background: transparent;
    border-top: 0;
    font-size: 11px;
    line-height: 1.45;
}

.pt-checkout-secure-note svg {
    color: var(--pt-store-brand, #2563eb);
}

/* Existing error/empty states get the Step 7 language without changing logic. */
.pt-checkout-wrap .pt-product-not-found {
    max-width: 620px;
    margin: 28px auto;
    padding: 28px 22px;
    background: var(--pt-store-surface, #fff);
    border: 1px solid var(--pt-store-line, #e2e8f0);
    border-radius: var(--pt-store-radius-lg, 18px);
    box-shadow: var(--pt-store-shadow-shell, 0 12px 34px rgba(15, 23, 42, .08));
}

/* ========================================================================== 
   MANUAL UPI PAY
   ========================================================================== */

.pt-pay-wrap {
    max-width: 720px;
    padding: 28px 16px 56px;
}

.pt-pay-page-intro {
    margin-bottom: 18px;
}

.pt-pay-page-kicker {
    margin: 0 0 4px;
    color: var(--pt-store-brand, #2563eb);
    font-size: 12px;
    font-weight: 800;
}

.pt-pay-page-title {
    margin: 0 0 5px;
    color: var(--pt-store-ink, #0f172a);
    font-size: 27px;
    line-height: 1.25;
    font-weight: 800;
}

.pt-pay-page-subtitle {
    margin: 0;
    color: var(--pt-store-muted, #64748b);
    font-size: 14px;
    line-height: 1.55;
}

.pt-pay-card {
    padding: 24px;
    background: var(--pt-store-surface, #fff);
    border: 1px solid var(--pt-store-line, #e2e8f0);
    border-radius: var(--pt-store-radius-lg, 18px);
    box-shadow: var(--pt-store-shadow-shell, 0 12px 34px rgba(15, 23, 42, .08));
}

.pt-pay-head {
    display: flex;
    justify-content: space-between;
    gap: 16px;
    align-items: flex-start;
    padding: 0 0 18px;
    border-bottom: 1px solid var(--pt-store-line, #e2e8f0);
}

.pt-pay-title {
    margin: 0;
    color: var(--pt-store-ink, #0f172a);
    font-size: 20px;
    line-height: 1.4;
    font-weight: 800;
}

.pt-pay-amount {
    flex: 0 0 auto;
    color: var(--pt-store-ink, #0f172a);
    font-size: 22px;
    line-height: 1.2;
    font-weight: 900;
}

.pt-pay-steps {
    counter-reset: pt-step;
    display: grid;
    gap: 10px;
    margin: 18px 0 22px;
    padding: 0;
}

.pt-pay-steps li {
    list-style: none;
    display: grid;
    grid-template-columns: 28px minmax(0, 1fr);
    gap: 10px;
    align-items: start;
    margin: 0;
    padding: 0;
    color: var(--pt-store-text, #334155);
    font-size: 13px;
    line-height: 1.5;
}

.pt-pay-steps li::before {
    counter-increment: pt-step;
    content: counter(pt-step);
    width: 28px;
    height: 28px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    color: var(--pt-store-brand, #2563eb);
    background: var(--pt-store-brand-soft, #eff6ff);
    font-weight: 900;
}

.pt-pay-steps li span {
    color: var(--pt-store-muted, #64748b);
}

.pt-pay-block {
    margin: 0;
    padding: 18px 0;
    border: 0;
    border-top: 1px solid var(--pt-store-line, #e2e8f0);
    background: transparent;
    border-radius: 0;
}

.pt-pay-block-label {
    margin-bottom: 12px;
    color: var(--pt-store-ink, #0f172a);
    font-size: 15px;
    font-weight: 900;
}

.pt-pay-block-label > span {
    width: 26px;
    height: 26px;
    margin-right: 6px;
    display: inline-grid;
    place-items: center;
    border-radius: 50%;
    color: var(--pt-store-brand, #2563eb);
    background: var(--pt-store-brand-soft, #eff6ff);
    font-size: 12px;
}

.pt-pay-qr {
    margin: 0 auto 14px;
    padding: 10px;
    width: min(210px, 100%);
    background: #fff;
    border: 1px solid var(--pt-store-line, #e2e8f0);
    border-radius: 14px;
}

.pt-pay-qr img {
    display: block;
    width: 100%;
    height: auto;
}

.pt-pay-upi-open {
    width: 100%;
    min-height: 46px;
    margin-bottom: 12px;
    border-radius: var(--pt-store-radius, 12px);
    background: var(--pt-store-brand, #2563eb);
    box-shadow: none;
    font-weight: 800;
}

.pt-pay-upi-open:hover {
    background: var(--pt-store-brand-hover, #1d4ed8);
}

.pt-pay-upi-id {
    margin: 0;
    padding: 0;
    background: transparent;
    border: 0;
}

.pt-pay-upi-id > span {
    display: block;
    margin-bottom: 7px;
    color: var(--pt-store-muted, #64748b);
    font-size: 12px;
}

.pt-pay-copy-row {
    min-height: 44px;
    padding: 7px 8px 7px 12px;
    border: 1px solid var(--pt-store-line, #e2e8f0);
    border-radius: 11px;
    background: #fff;
}

/* store.css styles this `code` as a flex item -- padding, fill and border. Step 7
   wrapped the label and value in one <span>, so `code` is inline now and that
   vertical padding overflows upward over its own <small> label. The row draws the
   box; the value inside it is plain text. */
.pt-pay-copy-row code {
    display: block;
    padding: 0;
    background: none;
    border: 0;
    border-radius: 0;
    overflow-wrap: anywhere;
    color: var(--pt-store-text, #334155);
    font-size: 13px;
}

.pt-pay-copy-row .pt-copy-btn {
    min-height: 34px;
    min-width: 62px;
    border-color: var(--pt-store-brand, #2563eb);
    color: var(--pt-store-brand, #2563eb);
}

.pt-pay-extra-note,
.pt-pay-hint,
.pt-pay-foot {
    color: var(--pt-store-muted, #64748b);
    font-size: 12px;
    line-height: 1.55;
}

.pt-pay-file {
    min-height: 94px;
    display: grid;
    place-items: center;
    gap: 7px;
    padding: 16px;
    color: var(--pt-store-text, #334155);
    background: #fff;
    border: 1.5px dashed #94a3b8;
    border-radius: 14px;
    text-align: center;
}

.pt-pay-file:hover,
.pt-pay-file--chosen {
    border-color: var(--pt-store-brand, #2563eb);
    background: var(--pt-store-brand-soft, #eff6ff);
}

.pt-pay-file svg {
    color: var(--pt-store-brand, #2563eb);
}

.pt-pay-field {
    margin-bottom: 0;
}

.pt-pay-field > span {
    display: block;
    margin-bottom: 6px;
    color: var(--pt-store-text, #334155);
    font-size: 13px;
    font-weight: 800;
}

.pt-pay-field input {
    min-height: 46px;
    width: 100%;
    padding: 10px 12px;
    color: var(--pt-store-ink, #0f172a);
    background: #fff;
    border: 1px solid #cbd5e1;
    border-radius: 11px;
    font-size: 16px;
    box-sizing: border-box;
}

.pt-pay-field input:focus {
    outline: none;
    border-color: var(--pt-store-brand, #2563eb);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, .12);
}

.pt-pay-or {
    margin: 9px 0;
    color: var(--pt-store-muted, #64748b);
    font-size: 12px;
}

.pt-pay-error {
    margin: 14px 0 0;
    padding: 11px 12px;
    color: #991b1b;
    background: #fef2f2;
    border: 1px solid #fecaca;
    border-radius: 11px;
    font-size: 13px;
}

.pt-pay-submit {
    width: 100%;
    min-height: 48px;
    margin-top: 18px;
    border-radius: var(--pt-store-radius, 12px);
    background: var(--pt-store-brand, #2563eb);
    box-shadow: none;
    font-size: 15px;
    font-weight: 800;
}

.pt-pay-submit:hover {
    background: var(--pt-store-brand-hover, #1d4ed8);
    box-shadow: none;
}

.pt-pay-foot {
    margin: 10px 0 0;
    text-align: center;
}

.pt-pay-next {
    margin: 14px 0 0;
    padding: 15px;
    color: var(--pt-store-text, #334155);
    background: var(--pt-store-page, #f8fafc);
    border: 1px solid var(--pt-store-line, #e2e8f0);
    border-radius: 14px;
    text-align: left;
}

.pt-pay-next--ready,
.pt-pay-next--tg {
    background: var(--pt-store-brand-soft, #eff6ff);
    border-color: var(--pt-store-brand-soft-border, #bfdbfe);
}

.pt-pay-next-title {
    margin: 0 0 6px;
    color: var(--pt-store-ink, #0f172a);
    font-size: 14px;
    font-weight: 900;
}

.pt-pay-next--tg .pt-btn-tg {
    width: 100%;
    min-height: 48px;
    margin-top: 10px;
}

.pt-pay-next-body,
.pt-pay-next-note,
.pt-pay-next-steps {
    color: var(--pt-store-text, #334155);
    font-size: 13px;
    line-height: 1.55;
}

.pt-pay-next .pt-btn {
    min-height: 44px;
    margin-top: 8px;
    border-radius: 11px;
}

.pt-pay-patience {
    margin-top: 14px;
    padding: 12px 14px;
    color: var(--pt-store-muted, #64748b);
    background: #fffbeb;
    border: 1px solid #fde68a;
    border-radius: 12px;
    font-size: 12px;
    line-height: 1.55;
    text-align: left;
}

.pt-pay-back {
    display: inline-block;
    margin-top: 16px;
    color: var(--pt-store-brand, #2563eb);
    font-size: 13px;
    font-weight: 800;
}

.pt-pay-blocked {
    text-align: center;
}

.pt-pay-blocked .pt-btn {
    min-height: 44px;
}

@media (max-width: 900px) {
    .pt-checkout-layout {
        grid-template-columns: 1fr;
        gap: 14px;
    }

    .pt-checkout-summary-section {
        position: static;
        order: -1;
    }
}

@media (max-width: 640px) {
    .pt-checkout-wrap {
        padding: 20px 12px 44px;
    }

    .pt-checkout-heading,
    .pt-pay-page-title {
        font-size: 23px;
    }

    .pt-checkout-subtitle,
    .pt-pay-page-subtitle {
        font-size: 13px;
    }

    .pt-checkout-form-section,
    .pt-checkout-summary,
    .pt-pay-card {
        border-radius: 15px;
        box-shadow: none;
    }

    .pt-checkout-form-section,
    .pt-pay-card {
        padding: 16px;
    }

    .pt-checkout-fields {
        grid-template-columns: 1fr;
    }

    .pt-checkout-fields .pt-form-group--full {
        grid-column: auto;
    }

    .pt-checkout-gateway-card {
        padding: 12px;
    }

    .pt-checkout-summary-title {
        padding: 16px 16px 12px;
    }

    .pt-checkout-product {
        padding-left: 16px;
        padding-right: 16px;
    }

    .pt-checkout-summary-row {
        padding-left: 16px;
        padding-right: 16px;
    }

    .pt-checkout-discount-badge,
    .pt-checkout-tax-note {
        margin-left: 16px;
        margin-right: 16px;
    }

    .pt-checkout-secure-note {
        padding-left: 16px;
        padding-right: 16px;
    }

    .pt-pay-wrap {
        padding: 18px 10px 40px;
    }

    .pt-pay-head {
        display: block;
    }

    .pt-pay-amount {
        margin-top: 8px;
    }
}

@media (max-width: 350px) {
    .pt-checkout-wrap,
    .pt-pay-wrap {
        padding-left: 8px;
        padding-right: 8px;
    }

    .pt-checkout-form-section,
    .pt-pay-card {
        padding: 14px;
    }

    .pt-checkout-heading,
    .pt-pay-page-title {
        font-size: 21px;
    }

    .pt-checkout-gateway-card {
        align-items: flex-start;
    }

    .pt-checkout-wrap .pt-gw-badge {
        font-size: 10px;
    }
}


.pt-pay-choice-hint {
    display: flex;
    align-items: center;
    gap: 5px;
    margin: -2px 0 9px 36px;
    color: var(--pt-store-muted, #64748b);
    font-size: 11px;
    font-weight: 700;
    line-height: 1.3;
}

.pt-pay-choice-hint svg {
    width: 14px;
    height: 14px;
    flex: 0 0 auto;
    color: var(--pt-store-brand, #2563eb);
}


/* PR 2 — single Access Method inline verification. */
.pt-pay-access-copy {
    margin: 0 0 10px;
    color: var(--pt-muted, #64748b);
    font-size: 14px;
    line-height: 1.5;
}
.pt-pay-access-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 8px;
    align-items: center;
    margin-top: 8px;
}
.pt-pay-access-row input {
    width: 100%;
    min-width: 0;
    border: 1px solid #cbd5e1;
    border-radius: 10px;
    padding: 11px 12px;
    background: #fff;
}
.pt-pay-access-row .pt-btn {
    white-space: nowrap;
}
.pt-pay-access-status {
    margin: 9px 0 0;
    font-size: 13px;
    line-height: 1.45;
}
.pt-pay-access-status.is-ready {
    color: #166534;
    font-weight: 700;
}
.pt-pay-access-status.is-error {
    color: #b91c1c;
}
.pt-pay-access-email,
.pt-pay-access-telegram {
    margin-top: 10px;
}
@media (max-width: 560px) {
    .pt-pay-access-row {
        grid-template-columns: 1fr;
    }
    .pt-pay-access-row .pt-btn {
        width: 100%;
    }
}
