﻿@font-face{font-family:Vazir;src:url('/fonts/Vazir/Vazir-FD.woff2') format('woff2');font-weight:400;font-display:swap}
@font-face{font-family:Vazir;src:url('/fonts/Vazir/Vazir-Bold-FD.woff2') format('woff2');font-weight:700;font-display:swap}

:root{--bg:#f3f8fc;--ink:#14325b;--muted:#657a94;--blue:#003088;--line:#dbe8f4;--soft:#eaf4fc;--red:#b63f3e}
*{box-sizing:border-box}
body{margin:0;background:var(--bg);color:var(--ink);font-family:Vazir,Tahoma,sans-serif;font-size:14px;line-height:1.8}
a{color:inherit;text-decoration:none}
button,input,textarea,select{font:inherit}
button,a,input,textarea,select{touch-action:manipulation}
button{cursor:pointer}
a:focus-visible,button:focus-visible{outline:3px solid #9eceef;outline-offset:4px}
button:disabled{opacity:.6;cursor:wait}
h1,h2,p{margin-top:0}
h1{font-size:26px;font-weight:700;letter-spacing:0;margin-bottom:0}
h2{font-size:19px;letter-spacing:0}
.site-header{max-width:1120px;margin:auto;padding:12px 24px;display:flex;justify-content:space-between;align-items:center}
.brand{display:flex;align-items:center;gap:12px}
.brand img{width:42px;height:42px;object-fit:contain}
.brand strong{font-size:22px;display:block;line-height:1.4}
.brand small{font-size:11px;color:var(--muted)}
.header-label{color:var(--muted);display:flex;align-items:center;gap:8px;font-size:12px}
.status-dot{width:6px;height:6px;background:#3c9ddf;border-radius:50%;display:inline-block}
.page{max-width:1072px;margin:12px auto 0;padding:0 24px}
.intro{display:flex;justify-content:space-between;align-items:center;margin-bottom:18px}
.eyebrow{font-size:11px;letter-spacing:0;color:var(--muted);display:block;margin-bottom:6px}
.steps{display:flex;align-items:center;gap:14px;color:#8e9fb3}
.steps>span{font-size:12px;display:flex;gap:8px;align-items:center}
.steps small{font-size:11px}
.steps .active{color:var(--blue)}
.steps i{width:34px;height:1px;background:#cbddec}
.payment-grid{display:grid;grid-template-columns:280px minmax(0,1fr);gap:18px;align-items:stretch}
.merchant-panel{display:flex;flex-direction:column;border-radius:20px;padding:24px;background:#003088;color:#f4faff;position:relative;overflow:hidden}
.merchant-panel:before{content:'';width:250px;height:250px;border-radius:50%;border:1px solid #3c70ba;position:absolute;top:-150px;left:-130px;pointer-events:none}
.merchant-panel .eyebrow{color:#9eceef}
.merchant-top{display:grid;grid-template-columns:60px minmax(0,1fr);gap:5px 12px;align-items:center}
.merchant-top>.eyebrow{grid-column:1/-1}
.merchant-top h2{font-size:20px;margin-bottom:3px}
.merchant-top p{font-size:11px;color:#badcf5;margin-bottom:0}
.merchant-avatar{grid-column:1;grid-row:2/5;width:60px;height:60px;background:#fff;border-radius:20px;margin:0;padding:10px;display:grid;place-items:center}
.merchant-avatar img{max-width:100%;max-height:100%;object-fit:contain}
.merchant-chip{width:max-content;max-width:100%;display:inline-flex;align-items:center;gap:7px;font-size:9px;background:#174b99;border:1px solid #3c70ba;border-radius:100px;padding:5px 10px}
.merchant-about{white-space:pre-line;color:#d8ecf9;font-size:12px;line-height:2.1;margin:18px 0}
.merchant-info{margin:0;border-top:1px solid #2b5dab;padding:15px 0}
.merchant-info>div{margin-bottom:12px}
.merchant-info>div:last-child{margin:0}
.merchant-info dt{font-size:10px;color:#9eceef}
.merchant-info dd{margin:4px 0 0;font-size:12px;overflow-wrap:anywhere}
.merchant-info dd[dir=ltr]{text-align:right}
.merchant-bottom{display:flex;gap:12px;border-top:1px solid #2b5dab;padding-top:16px;margin-top:auto}
.merchant-bottom p{font-size:10px;color:#d8ecf9;margin:0;line-height:2}
.outline-shield{width:26px;height:30px;display:grid;place-items:center;border:1px solid #6095cf;border-radius:6px 6px 14px 14px;flex-shrink:0;color:#d8ecf9}
.card{background:#fff;border:1px solid var(--line);border-radius:20px;box-shadow:0 8px 40px #0030880b}
.payment-card{padding:24px}
.card-heading{display:flex;justify-content:space-between;gap:20px;align-items:center;margin-bottom:16px}
.card-heading h2{margin-bottom:0;font-size:18px}
.heading-icon{font-family:sans-serif;font-size:25px;background:var(--soft);width:38px;height:38px;display:grid;place-items:center;border-radius:13px;color:var(--blue)}
.invoice-note{background:#edf6fd;border:1px solid #d3e7f7;color:#265988;padding:10px 13px;border-radius:10px;font-size:11px;margin:0 0 14px}
.amount-area{background:#f0f7fd;border-radius:15px;padding:10px 15px;margin-bottom:14px;border:1px solid #dcecf8}
.amount-label{display:flex;align-items:center;justify-content:space-between;font-size:12px}
.amount-label>span{color:var(--muted);font-size:10px}
.amount-input-wrap{display:flex;align-items:center;gap:14px}
.amount-input-wrap input{background:none;border:0;min-width:0;width:100%;font-size:30px;letter-spacing:-1px;color:var(--ink);padding:5px 0;height:44px;direction:ltr;text-align:right;outline:none;font-weight:700}
.amount-input-wrap>span{color:#6f8eae;font-size:12px}
.amount-input-wrap input::placeholder{color:#9ab4ce}
.amount-input-wrap input:focus{border-bottom:1px solid #3c9ddf}
.amount-help{font-size:10px;color:#617f9e;min-height:18px}
.fields-grid{display:grid;grid-template-columns:1fr 1fr;gap:12px 14px}
.field{min-width:0}
.field.wide{grid-column:auto}
.field label{font-size:11px;color:#4b6480;display:block;margin-bottom:5px}
.field input,.field textarea,.field select{width:100%;border:1px solid #d5e2ef;border-radius:10px;background:#fff;padding:9px 12px;color:var(--ink);outline:none;transition:border-color .15s,box-shadow .15s}
.field input,.field select{height:40px}
.field textarea{resize:vertical;min-height:60px}
.field input::placeholder,.field textarea::placeholder{color:#98a9bc;font-size:11px}
.field input:focus,.field textarea:focus,.field select:focus{border-color:#3c9ddf;box-shadow:0 0 0 3px #e2f1fc}
.field.locked input,.field.locked textarea{background:#f3f7fc;border-style:dashed;color:#58718b}
.locked-label{float:left;font-size:9px;color:#6c87a3}
.required{color:#3c9ddf;padding:0 2px}
.ltr{direction:ltr;text-align:right}
.field-error{display:block;color:var(--red);font-size:10px;margin-top:3px}
.field-error:empty{display:none}
.field input[aria-invalid=true]{border-color:var(--red)}
.payment-summary{border-top:1px solid var(--line);padding-top:8px;margin-top:12px;font-size:12px}
.payment-summary>div{display:flex;justify-content:space-between;margin-bottom:2px}
.payment-summary>div[hidden]{display:none}
.payment-summary span{color:var(--muted)}
.payment-summary strong{font-size:14px}
.primary,.secondary{display:inline-flex;align-items:center;justify-content:center;border:0;border-radius:10px;padding:12px 20px;font-size:12px;font-weight:700;text-align:center;line-height:1.7;gap:8px}
.primary{background:var(--blue);color:#fff}
.primary:hover{background:#002770}
.secondary{border:1px solid var(--line);background:#fff;color:var(--ink)}
.secondary:hover{background:var(--soft)}
.pay-button{width:100%;margin-top:10px;justify-content:space-between;font-size:14px;padding:12px 18px}
.pay-button>span:last-child{font-family:sans-serif;font-size:22px;line-height:1;font-weight:400}
.payment-hint{font-size:10px;text-align:center;color:#7b91aa;margin:10px 0 0}
.support-links{display:flex;justify-content:center;gap:24px;border-top:1px solid var(--line);padding-top:10px;margin-top:12px;font-size:10px;color:var(--muted)}
.support-links form{margin:0}
.text-button{border:0;background:none;color:inherit;padding:0;font:inherit}
.site-footer{max-width:1072px;margin:14px auto 16px;padding:0 24px;display:flex;justify-content:center;gap:25px;color:#8296ac;font-size:10px}
.demo-banner{max-width:1024px;margin:0 auto;padding:7px 16px;border-radius:9px;background:#fff5db;color:#8f732c;font-size:11px;display:flex;justify-content:space-between}
.demo-banner a{text-decoration:underline}
.invoice-details{margin-bottom:20px;border:1px solid var(--line);border-radius:12px;padding:12px}
.invoice-details summary{display:flex;justify-content:space-between;font-size:11px;cursor:pointer}
.invoice-details summary>span{color:var(--muted)}
.table-scroll{overflow-x:auto}
table{border-collapse:collapse;width:100%;font-size:10px;margin-top:12px}
td,th{text-align:right;border-bottom:1px solid var(--line);padding:9px}
th{color:var(--muted);font-weight:400;white-space:nowrap}
.totals{font-size:10px}
.totals>div{display:flex;justify-content:space-between}
.totals dd{margin:0}
.social-links{display:flex;flex-wrap:wrap;gap:9px;margin:16px 0 20px}
.social-links:empty{display:none}
.social-links a,.social-demo{display:flex;align-items:center;justify-content:space-between;gap:10px;width:100%;padding:10px 12px;border:1px solid #77b6e5;border-radius:10px;background:#d8ecf9;color:#003088;font-size:12px;font-weight:700}
.social-links a:hover{background:#fff;border-color:#fff}
.social-links strong{font-size:13px;font-weight:700}
.social-link-state{display:inline-flex;align-items:center;gap:5px;font-size:10px;font-weight:700;margin-right:auto}
.social-link-state .status-dot{width:5px;height:5px;background:#003088}
.merchant-panel details{font-size:11px}
.merchant-panel details p{color:#d8ecf9;white-space:pre-line}
.standalone{max-width:630px;margin:45px auto;padding:40px;text-align:center}
.standalone h1{font-size:25px;margin-bottom:12px}
.standalone form{display:flex;justify-content:center;gap:12px;margin-top:22px}
.muted{color:var(--muted);font-size:12px}
.large-amount{font-size:34px;font-weight:700;margin:24px 0}
.large-amount small{font-size:12px;font-weight:400;color:var(--muted)}
.result-icon{width:65px;height:65px;border-radius:50%;display:grid;place-items:center;font-family:sans-serif;font-size:30px;margin:0 auto 20px}
.result-icon.success{background:#eaf4fc;color:var(--blue)}
.result-icon.failure{background:#fbecea;color:var(--red)}
.receipt-info{text-align:right;margin:25px 0}
.receipt-info>div{display:flex;justify-content:space-between;border-bottom:1px dashed var(--line);padding:11px 0;gap:20px;font-size:12px}
.receipt-info dt{color:var(--muted);flex-shrink:0}
.receipt-info dd{margin:0;text-align:left;overflow-wrap:anywhere}
.receipt-actions{display:flex;gap:8px;justify-content:center;flex-wrap:wrap}
.alert{background:#fff0ed;color:#a23e2e;border:1px solid #f1d5cd;padding:12px 15px;border-radius:10px;font-size:12px;margin:14px 0}
.alert[hidden]{display:none}

@media(max-width:800px){.payment-grid{grid-template-columns:245px minmax(0,1fr);gap:16px}
.merchant-panel{padding:24px 20px}
.payment-card{padding:24px}
.fields-grid{grid-template-columns:1fr}
.steps{display:none}
h1{font-size:23px}
.demo-banner{margin:0 24px}
}

@media(max-width:620px){.site-header{padding:18px 20px}
.header-label{font-size:10px}
.brand img{width:34px;height:34px}
.brand strong{font-size:19px}
.brand small{font-size:9px}
.page{padding:0 16px;margin-top:20px}
.intro{margin-bottom:18px}
h1{font-size:21px}
.payment-grid{display:flex;flex-direction:column;gap:16px}
.merchant-panel{width:100%;padding:18px;border-radius:18px}
.merchant-top{display:grid;grid-template-columns:60px 1fr;column-gap:14px;align-items:center}
.merchant-top>.eyebrow{display:none}
.merchant-avatar{grid-column:1;grid-row:1/4;width:60px;height:60px;margin:0;border-radius:16px}
.merchant-top h2{font-size:18px;margin:0}
.merchant-top p{margin:0;font-size:10px}
.merchant-chip{width:max-content;margin-top:4px;font-size:9px;padding:2px 8px}
.merchant-about{margin:12px 0 0;font-size:11px}
.merchant-info,.merchant-bottom{display:none}
.merchant-panel details{margin-top:10px}
.social-links{margin:12px 0 0;display:grid;grid-template-columns:1fr 1fr}
.social-links a,.social-demo{padding:8px 10px;gap:6px}
.social-links strong{font-size:12px}
.payment-card{width:100%;padding:20px 18px;border-radius:18px}
.card-heading{margin-bottom:18px}
.card-heading h2{font-size:16px}
.fields-grid{grid-template-columns:1fr 1fr;gap:12px 10px}
.field label{font-size:10px}
.locked-label{float:none;display:block}
.field input{padding:10px;font-size:12px}
.amount-area{padding:16px}
.amount-input-wrap input{font-size:29px}
.site-footer{gap:12px;font-size:9px;margin-top:20px}
.standalone{padding:25px 20px;margin-top:20px}
.demo-banner{margin:0 16px;font-size:10px;gap:14px}
.large-amount{font-size:29px}
.receipt-info>div{font-size:11px}
}

@media(max-width:380px){.fields-grid{grid-template-columns:1fr}
.header-label{display:none}
}

@media(prefers-reduced-motion:reduce){*{transition:none!important;scroll-behavior:auto!important}
}

@media print{body{background:white}
.site-header,.site-footer,.demo-banner,.receipt-actions{display:none}
.page{max-width:none;padding:0}
.receipt{border:0;box-shadow:none;max-width:100%;margin:0}
.receipt-info{break-inside:avoid}
}

/* Hybrid Sizpay design: balanced payment cards, focused receipt and error card. */
.site-header{max-width:1072px;border-bottom:1px solid var(--line);padding:18px 24px}
.page{margin-top:24px}
.payment-grid{grid-template-columns:250px minmax(0,1fr);gap:18px}
.merchant-panel{padding:22px;border-radius:20px;background:#003088}
.merchant-panel:before{display:none}
.merchant-avatar{width:52px;height:52px;padding:7px;border-radius:14px}
.merchant-top{grid-template-columns:52px minmax(0,1fr)}
.merchant-chip{font-size:11px}
.merchant-about,.merchant-info dt,.merchant-bottom p,.payment-hint,.field-error,.locked-label,.amount-help,.site-footer,.support-links{font-size:11px}
.field label{font-size:12px}
.field input,.field select{height:42px}
.card-heading{margin-bottom:18px}
.heading-icon{display:none}
.social-links strong{font-size:14px}
.standalone.receipt,.error-card{max-width:600px;text-align:center;padding:0 28px 28px;overflow:hidden;margin:32px auto}
.outcome-head{background:#d8ecf9;margin:0 -28px;padding:28px 26px 22px}
.outcome-head h1{font-size:24px;margin:0 0 9px}
.outcome-head p{margin:0;line-height:2}
.result-icon{width:50px;height:50px;margin:0 auto 12px;font-size:25px;background:white!important}
.result-icon.success{color:#22715e}
.receipt-merchant{display:flex;justify-content:space-between;gap:15px;padding:12px 0;border-bottom:1px solid var(--line);font-size:12px}
.receipt-merchant>span{color:var(--muted)}
.large-amount{margin:22px 0 12px;font-size:32px;letter-spacing:0}
.toman-amount{display:block;color:var(--muted);font-size:11px;font-weight:400;margin-top:6px}
.receipt-info{margin:12px 0 22px}
.receipt-info>div{border-bottom:1px solid var(--line);padding:9px 0;font-size:12px}
.trace-info{display:flex;justify-content:space-between;gap:14px;font-size:11px;color:var(--muted);padding:20px 0;overflow-wrap:anywhere}
.trace-info code{color:var(--blue);font-size:11px}
@media(max-width:800px){.payment-grid{grid-template-columns:215px minmax(0,1fr)}.fields-grid{grid-template-columns:1fr 1fr}.merchant-panel,.payment-card{padding:18px}}
@media(max-width:620px){.site-header{padding:15px 18px}.page{margin-top:18px}.payment-grid{display:grid;grid-template-columns:1fr;gap:14px}.merchant-panel{padding:18px}.merchant-chip{font-size:11px}.merchant-about{font-size:12px}.merchant-panel details{font-size:12px}.field input,.field textarea,.field select{font-size:16px}.field input::placeholder,.field textarea::placeholder{font-size:11px}.locked-label{float:none}.standalone.receipt,.error-card{padding:0 18px 24px;margin:18px auto}.outcome-head{margin:0 -18px;padding:23px 18px}.outcome-head h1{font-size:21px}.receipt-actions .primary,.receipt-actions .secondary{min-height:44px}.social-links a,.social-demo{min-height:44px}.site-footer{flex-wrap:wrap}.trace-info{flex-direction:column;gap:4px}}
@media(max-width:380px){.fields-grid{grid-template-columns:1fr}.merchant-top h2{font-size:18px}.large-amount{font-size:29px}}
@media print{.outcome-head{background:white}.receipt-actions{display:none}.receipt{padding:0!important;margin:0!important}}
.merchant-top h2{grid-column:2;grid-row:2}
.merchant-top>p{grid-column:2;grid-row:3}
.merchant-top>.merchant-chip{grid-column:2;grid-row:4}
.field textarea{min-height:42px;height:42px}
@media(max-width:620px){.merchant-top h2{grid-row:1}.merchant-top>p{grid-row:2}.merchant-top>.merchant-chip{grid-row:3}}

/* Compact checkout and matching report form. */
.site-header{padding-top:12px;padding-bottom:12px}
.page{margin-top:16px}
.merchant-top h1{grid-column:2;grid-row:2;font-size:20px;line-height:1.65;margin:0;overflow-wrap:anywhere}
.merchant-avatar{grid-row:2/4}
.merchant-codes{border-top:1px solid #2b5dab;padding-top:12px;margin:14px 0 0;display:grid;grid-template-columns:1fr 1fr;gap:10px}
.merchant-codes dt{font-size:11px;color:#badcf5}
.merchant-codes dd{margin:3px 0 0;font-size:13px;font-weight:700;text-align:right;overflow-wrap:anywhere}
.merchant-about{margin:12px 0;line-height:1.85}
.merchant-info{padding:10px 0}
.merchant-info>div{margin-bottom:8px}
.social-links{margin:12px 0 16px}
.payment-card{padding:20px 22px}
.card-heading{margin-bottom:12px}
.fields-grid{gap:10px 14px}
.field input,.field select{height:44px}
.payment-notice{margin:12px 0 0;padding:10px 12px;background:#eaf4fc;border:1px solid #d3e7f7;border-radius:10px;color:#315580;font-size:12px;line-height:1.9;text-align:right}
.payment-notice p{margin:0}
.payment-notice p+p{margin-top:3px}
.summary-total{border-top:1px dashed var(--line);padding-top:5px;margin-top:5px}
.invoice-lookup{padding:14px;border:1px solid var(--line);border-radius:12px;background:#f7fbff}
.invoice-lookup p{font-size:13px;margin-bottom:12px}
.lookup-actions,.report-actions{display:flex;gap:10px;flex-wrap:wrap;margin-top:16px}
.text-button{min-height:44px}
.result-icon.cancelled{color:#8c671e}
.standalone.report-card{max-width:600px;text-align:right;padding:0 28px 26px;margin:24px auto;overflow:hidden}
.report-card .outcome-head{text-align:center}
.report-card form{display:block;margin-top:18px}
.report-merchant{display:flex;gap:24px;font-size:12px;padding-top:14px;margin:0}
.report-merchant>div{display:flex;gap:8px;min-width:0}
.report-merchant dt{color:var(--muted)}
.report-merchant dd{margin:0;overflow-wrap:anywhere}
.report-description{margin-top:14px}
.report-description textarea{min-height:120px;height:auto}
.report-success{background:#eaf4fc;border-color:#d3e7f7;color:#003088}
.report-card .payment-hint{text-align:right}
[hidden]{display:none!important}
@media(max-width:800px){.merchant-panel,.payment-card{padding:18px}.merchant-top h1{font-size:18px}}
@media(max-width:620px){.site-header{padding:12px 16px}.page{margin-top:12px}.merchant-top h1{grid-row:1;font-size:18px}.merchant-avatar{grid-row:1/3}.merchant-codes{margin-top:10px;padding-top:8px}.merchant-codes dd{font-size:12px}.merchant-about{margin-top:10px;margin-bottom:0}.payment-card{padding:18px}.card-heading{margin-bottom:12px}.amount-area{padding:10px 12px}.payment-notice{font-size:12px}.standalone.report-card{padding:0 18px 22px;margin:18px auto}.report-merchant{gap:12px;flex-wrap:wrap}.report-actions .primary,.report-actions .secondary,.lookup-actions .primary,.lookup-actions .secondary{min-height:44px}}

/* Receipt matches the legacy fields: one amount and compact combined information rows. */
.compact-receipt{margin:20px auto!important;padding-bottom:20px!important}
.compact-receipt .outcome-head{padding:18px 22px 14px}
.compact-receipt .result-icon{width:36px;height:36px;font-size:20px;margin-bottom:8px}
.compact-receipt .outcome-head h1{font-size:21px;margin-bottom:5px}
.compact-receipt .outcome-head p{font-size:11px}
.compact-receipt .large-amount{font-size:28px;margin:14px 0 8px}
.compact-receipt .receipt-info{margin:8px 0 14px}
.compact-receipt .receipt-info>div{padding:7px 0;gap:14px;font-size:12px}
.compact-receipt .receipt-info dt{flex-shrink:1;max-width:50%}
.card-number {
    font-family: inherit;
    font-size: inherit;
    white-space: nowrap;
    direction: ltr;
}

/*.merchant-top {
    grid-template-columns: 48px minmax(0, 1fr);
    column-gap: 6px;
}

.merchant-avatar {
    width: 48px;
    height: 48px;
    padding: 0px;*/
    /*background: #fff;*/
    /*background: transparent;*/
/*    border: 0px solid #e3e8ef;
    border-radius: 12px;
*/    /*box-shadow: none;
    overflow: hidden;
}

    .merchant-avatar img {
        display: block;
        width: 100%;
        height: 100%;
        max-width: 100%;
        max-height: 100%;
        object-fit: contain;
        object-position: center;
        background: transparent;
        filter: none;
        opacity: 1;
    }*/
.merchant-avatar {
    background: transparent;
    border: 0;
    padding: 0;
    border-radius: 0;
    box-shadow: none;
}

    .merchant-avatar img {
        display: block;
        width: 100%;
        height: 100%;
        object-fit: contain;
        background: transparent;
    }

.amount-area.amount-editable {
    background: transparent;
    border: 0;
    padding: 0;
}

.amount-editable .amount-label {
    margin-bottom: 6px;
    font-size: 13px;
    font-weight: 700;
}

.amount-editable .amount-input-wrap {
    background: #fff;
    border: 1px solid #8aaed3;
    border-radius: 10px;
    padding: 0 12px;
    min-height: 52px;
    gap: 10px;
    transition: border-color .15s, box-shadow .15s;
}

    .amount-editable .amount-input-wrap:focus-within {
        border-color: #003088;
        box-shadow: 0 0 0 3px #eaf1fc;
    }

    .amount-editable .amount-input-wrap input {
        height: 50px;
        padding: 6px 0;
        border: 0;
        outline: none;
        box-shadow: none;
        font-size: 24px;
        letter-spacing: normal;
        cursor: text;
    }

        .amount-editable .amount-input-wrap input:focus {
            border: 0;
        }

        .amount-editable .amount-input-wrap input::placeholder {
            font-size: 16px;
            font-weight: 400;
            color: #8798ad;
        }

    .amount-editable .amount-input-wrap > span {
        color: #526b89;
        font-size: 13px;
    }

.amount-editable .amount-help {
    margin-top: 4px;
}

/* مبلغ ثابت: حفظ ظاهر نمایشی */
.amount-fixed .amount-input-wrap input {
    cursor: default;
}

    .amount-fixed .amount-input-wrap input:focus {
        border: 0;
    }

@media (min-width: 801px) {
    .payment-grid {
        grid-template-columns: 320px minmax(0, 1fr);
    }

    .merchant-top {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 6px;
        text-align: center;
    }

        .merchant-top .merchant-avatar {
            width: 96px;
            height: 96px;
            margin: 0 0 4px;
        }

        .merchant-top h1 {
            width: 100%;
            min-width: 0;
            margin: 0;
            font-size: 20px;
            line-height: 1.7;
            white-space: normal;
            overflow-wrap: anywhere;
        }

        .merchant-top > p {
            width: 100%;
            margin: 0;
            white-space: normal;
            overflow-wrap: anywhere;
        }
}


@media (max-width: 620px) {
    .merchant-top {
        grid-template-columns: 76px minmax(0, 1fr);
    }

    .merchant-avatar {
        width: 76px;
        height: 76px;
    }
}
.receipt-signature{border-top:1px dashed var(--line);padding-top:9px;margin:10px 0 16px}
.receipt-signature span{display:block;color:var(--muted);font-size:10px;margin-bottom:4px}
.receipt-signature code{display:block;color:var(--ink);font:11px/1.6 ui-monospace,monospace;overflow-wrap:anywhere;white-space:normal}
.receipt-warning{background:#fff7e6;border:1px solid #e8d6aa;color:#795921;border-radius:9px;padding:10px 12px;text-align:right;font-size:12px;line-height:1.8;margin:10px 0}
@media(max-width:620px){.compact-receipt .outcome-head{padding:16px 16px 12px}.compact-receipt .outcome-head h1{font-size:19px}.compact-receipt .receipt-info>div{font-size:11px;gap:10px}.compact-receipt .large-amount{font-size:26px}.card-number{font-size:12px}}
@media print{
    @page{size:A4 portrait;margin:12mm}
    html,body{margin:0;padding:0;background:white}
    .page{margin:0!important;padding:0!important;max-width:none}
    .compact-receipt{width:150mm;max-width:100%!important;margin:0 auto!important;padding:0!important;border:0;box-shadow:none;overflow:visible;break-inside:avoid;page-break-inside:avoid}
    .compact-receipt .outcome-head{margin:0!important;padding:8px 0 10px;background:white}
    .compact-receipt .outcome-head h1{font-size:18px}
    .compact-receipt .large-amount{font-size:24px;margin:10px 0}
    .compact-receipt .receipt-info>div{font-size:11px;padding:6px 0}
    .receipt-signature,.receipt-warning{break-inside:avoid;page-break-inside:avoid}
    .receipt-actions,#receipt-save-error,.file-delivery{display:none!important}
    .receipt-signature code{font-size:10px}
}
