*{
box-sizing:border-box;
margin:0;
padding:0;
font-family:Tahoma, Arial, sans-serif;
}

html{
width:100%;
overflow-x:hidden;
}

body{
min-height:100vh;
background:linear-gradient(135deg,#eef4fb,#dfe9f7);
padding:18px;
color:#1455a0;
overflow-x:hidden;
}

.container{
width:min(100%,980px);
margin-inline:auto;
background:#fff;
border-radius:22px;
padding:28px;
box-shadow:0 15px 40px rgba(0,0,0,0.1);
}

h1{
margin-bottom:24px;
font-size:28px;
text-align:right;
color:#1455a0;
font-weight:800;
letter-spacing:0;
}

.form-grid{
width:100%;
display:grid;
direction:rtl;
grid-template-columns:minmax(0,1fr) minmax(0,1fr);
grid-template-areas:
"company date"
"beneficiary sender"
"currency currency"
"amount commission"
"total total"
"notes notes";
gap:18px;
}

.field{
min-width:0;
display:flex;
flex-direction:column;
text-align:right;
}

.field-company{grid-area:company;}
.field-date{grid-area:date;}
.field-beneficiary{grid-area:beneficiary;}
.field-sender{grid-area:sender;}
.field-currency{grid-area:currency;}
.field-amount{grid-area:amount;}
.field-commission{grid-area:commission;}
.field-total{grid-area:total;}
.field-notes{grid-area:notes;}

.field label{
margin-bottom:8px;
font-weight:700;
font-size:16px;
color:#1455a0;
}

.field input,
.field select,
.field textarea{
width:100%;
height:52px;
min-height:52px;
padding:0 14px;
border-radius:12px;
border:1px solid #cfd8e6;
font-size:17px;
font-weight:600;
background:#fff;
color:#1455a0;
outline:none;
box-shadow:none;
}

.field input[readonly]{
background:#f4f7fb;
cursor:not-allowed;
}

.date-display-input{
direction:ltr;
text-align:right;
font-variant-numeric:tabular-nums;
}

.field textarea{
height:100px;
min-height:100px;
padding:14px;
resize:vertical;
line-height:1.55;
}

.field input:focus,
.field select:focus,
.field textarea:focus{
border-color:#1455a0;
box-shadow:0 0 0 3px rgba(20,85,160,0.15);
background:#fff;
}

.money-input{
background:#f8fbff !important;
font-weight:700 !important;
font-size:18px !important;
color:#1455a0 !important;
direction:ltr;
text-align:right;
font-variant-numeric:tabular-nums;
}

.money-input:focus{
background:#eef5ff !important;
border-color:#1455a0 !important;
box-shadow:0 0 0 3px rgba(20,85,160,0.15) !important;
}

.total-input{
background:#eef5ff !important;
color:#0f3f7a !important;
cursor:default !important;
}

.alert{
margin-bottom:15px;
padding:12px;
border-radius:12px;
font-weight:bold;
text-align:center;
}

.success{
background:#dcfce7;
color:#166534;
}

.error{
background:#fee2e2;
color:#991b1b;
}

.actions{
margin-top:24px;
display:grid;
grid-template-columns:1fr;
gap:10px;
}

.btn{
width:100%;
min-height:48px;
padding:13px 18px;
border:none;
border-radius:12px;
font-size:16px;
cursor:pointer;
font-weight:bold;
text-decoration:none;
display:inline-flex;
align-items:center;
justify-content:center;
text-align:center;
}

.save{
background:#16a34a;
color:#fff;
}

.show{
background:#1455a0;
color:#fff;
}

.back{
background:#d8e0ea;
color:#1455a0;
}

.save-image{
background:#2d7fe0;
color:#fff;
}

.btn:hover{
opacity:.9;
}

.btn:focus-visible{
outline:3px solid rgba(20,85,160,.25);
outline-offset:2px;
}

/* Select2 */
.select2-container{
width:100% !important;
min-width:0 !important;
}

.select2-container .select2-selection--single{
height:52px !important;
border-radius:12px !important;
border:1px solid #cfd8e6 !important;
background:#fff !important;
display:flex !important;
align-items:center !important;
outline:none !important;
}

.select2-container--default.select2-container--focus .select2-selection--single,
.select2-container--default.select2-container--open .select2-selection--single{
border-color:#1455a0 !important;
box-shadow:0 0 0 3px rgba(20,85,160,0.15) !important;
}

.select2-container--default .select2-selection--single .select2-selection__rendered{
color:#1455a0 !important;
font-size:17px !important;
font-weight:600 !important;
line-height:52px !important;
padding-right:14px !important;
padding-left:35px !important;
width:100%;
text-align:right;
}

.select2-container--default .select2-selection--single .select2-selection__placeholder{
color:#6f86a6 !important;
}

.select2-container--default .select2-selection--single .select2-selection__clear{
float:left !important;
margin-left:22px !important;
margin-right:0 !important;
font-size:20px !important;
line-height:48px !important;
color:#8aa0bc !important;
}

.select2-container--default .select2-selection--single .select2-selection__arrow{
height:52px !important;
left:10px !important;
right:auto !important;
}

.select2-dropdown{
border:1px solid #cfd8e6 !important;
border-radius:12px !important;
overflow:hidden;
direction:rtl;
}

.select2-search__field{
height:40px !important;
font-size:15px !important;
border-radius:8px !important;
padding:8px !important;
text-align:right;
}

.select2-results__option{
font-size:15px;
font-weight:700;
text-align:right;
}

.incoming-receipt-section{
margin-bottom:24px;
}

.receipt-actions{
margin-bottom:10px;
display:grid;
grid-template-columns:1fr;
gap:8px;
}

.incoming-receipt-card{
background:#fff;
border:2px solid #e3bd78;
border-radius:20px;
padding:18px 22px 22px;
box-shadow:0 12px 28px rgba(7,28,61,.11);
color:#071c3d;
}

.receipt-brand{
min-height:64px;
border:1px solid #e3bd78;
border-radius:13px;
background:#f8fbff;
display:flex;
flex-direction:column;
align-items:center;
justify-content:center;
gap:3px;
}

.receipt-brand strong{
font-size:28px;
font-weight:900;
color:#071c3d;
letter-spacing:0;
}

.receipt-brand span{
font-size:20px;
font-weight:900;
color:#0f766e;
}

.receipt-meta{
margin:14px 0 12px;
padding:12px 14px;
border:1px solid #e3bd78;
border-radius:13px;
background:#fffdf8;
text-align:right;
}

.date-line,
.receipt-number{
display:flex;
align-items:center;
justify-content:flex-start;
gap:10px;
direction:rtl;
}

.date-line{
padding-bottom:9px;
border-bottom:1px solid #ead2a6;
}

.receipt-number{
padding-top:9px;
}

.receipt-meta span,
.wide-card span,
.info-card span,
.receipt-total span,
.transaction-notes span{
display:block;
width:100%;
margin-bottom:5px;
text-align:right;
font-size:15px;
font-weight:900;
color:#0b4a7a;
}

.date-line span,
.receipt-number span{
width:auto;
margin-bottom:0;
}

.receipt-meta strong{
display:inline-block;
font-size:19px;
font-weight:900;
color:#071c3d;
text-align:right;
}

.date-line strong[dir="ltr"],
.receipt-number strong[dir="ltr"]{
direction:ltr;
unicode-bidi:embed;
}

.date-line em{
font-style:normal;
font-size:18px;
font-weight:900;
color:#d8ad65;
}

.wide-card,
.info-card,
.transaction-notes,
.receipt-notes{
border:2px solid #e3bd78;
border-radius:13px;
background:#fff;
}

.wide-card{
margin-top:12px;
min-height:78px;
padding:13px 18px;
display:flex;
flex-direction:column;
justify-content:center;
text-align:center;
}

.wide-card strong{
display:block;
font-size:22px;
font-weight:900;
line-height:1.35;
color:#071c3d;
text-align:center;
word-break:break-word;
}

.receipt-name-grid,
.amount-grid{
margin-top:10px;
display:grid;
grid-template-columns:1fr 1fr;
gap:10px;
}

.info-card{
min-height:78px;
padding:13px 16px;
display:flex;
flex-direction:column;
justify-content:center;
}

.info-card strong{
display:block;
font-size:20px;
font-weight:900;
line-height:1.35;
color:#071c3d;
text-align:center;
word-break:break-word;
}

.info-card strong[dir="ltr"]{
font-variant-numeric:tabular-nums;
}

.receipt-total{
margin-top:10px;
min-height:130px;
padding:16px 20px;
border-radius:13px;
background:linear-gradient(135deg,#0f766e,#12a38c);
box-shadow:0 10px 22px rgba(15,118,110,.2);
color:#fff;
display:flex;
flex-direction:column;
align-items:center;
justify-content:center;
text-align:center;
}

.receipt-total span{
color:#fff;
font-size:23px;
margin-bottom:10px;
text-align:center;
}

.receipt-total strong{
display:block;
font-size:34px;
font-weight:900;
line-height:1.35;
color:#fff;
direction:ltr;
text-align:center;
letter-spacing:0;
font-variant-numeric:tabular-nums;
}

.transaction-notes{
margin-top:10px;
min-height:68px;
padding:12px 16px;
text-align:right;
display:flex;
flex-direction:column;
justify-content:center;
}

.transaction-notes strong{
display:block;
font-size:19px;
font-weight:900;
line-height:1.45;
color:#071c3d;
word-break:break-word;
}

.receipt-notes{
margin-top:10px;
min-height:72px;
padding:12px 16px;
text-align:right;
}

.receipt-notes p{
font-size:15px;
font-weight:800;
line-height:1.65;
color:#071c3d;
}

@supports (-webkit-touch-callout:none){
.field input,
.field select,
.field textarea{
font-size:16px;
}

}

@media (max-width:760px){
body{
padding:8px;
}

.container{
padding:16px;
border-radius:18px;
}

h1{
font-size:23px;
margin-bottom:18px;
}

.form-grid{
grid-template-columns:1fr;
grid-template-areas:
"company"
"date"
"beneficiary"
"sender"
"currency"
"amount"
"commission"
"total"
"notes";
gap:14px;
}

.field label{
font-size:14px;
margin-bottom:7px;
}

.field input,
.field select,
.field textarea{
height:48px;
min-height:48px;
font-size:16px;
padding:0 12px;
border-radius:10px;
}

.field textarea{
height:92px;
min-height:92px;
padding:12px;
}

.money-input{
font-size:16px !important;
}

.select2-container .select2-selection--single{
height:48px !important;
border-radius:10px !important;
}

.select2-container--default .select2-selection--single .select2-selection__rendered{
line-height:48px !important;
font-size:16px !important;
padding-right:12px !important;
}

.select2-container--default .select2-selection--single .select2-selection__arrow{
height:48px !important;
}

.select2-container--default .select2-selection--single .select2-selection__clear{
line-height:44px !important;
}

.actions{
margin-top:18px;
gap:8px;
}

.btn{
min-height:46px;
font-size:15px;
border-radius:10px;
}

.incoming-receipt-section{
margin-bottom:18px;
}

.incoming-receipt-card{
padding:10px;
border-radius:16px;
}

.receipt-brand{
min-height:52px;
border-radius:11px;
}

.receipt-brand strong{
font-size:22px;
}

.receipt-brand span{
font-size:16px;
}

.receipt-meta{
margin:10px 0;
padding:9px 10px;
border-radius:10px;
}

.date-line{
gap:6px;
padding-bottom:7px;
flex-wrap:wrap;
}

.receipt-number{
padding-top:7px;
gap:6px;
}

.receipt-meta span,
.wide-card span,
.info-card span,
.receipt-total span,
.transaction-notes span{
font-size:11px;
margin-bottom:3px;
}

.date-line span,
.receipt-number span{
margin-bottom:0;
}

.receipt-meta strong{
font-size:14px;
}

.wide-card{
margin-top:8px;
min-height:58px;
padding:9px 10px;
border-radius:10px;
}

.wide-card strong{
font-size:15px;
line-height:1.3;
}

.receipt-name-grid,
.amount-grid{
grid-template-columns:1fr;
gap:8px;
margin-top:8px;
}

.info-card{
min-height:58px;
padding:9px 10px;
border-radius:10px;
}

.info-card strong{
font-size:15px;
line-height:1.3;
}

.receipt-total{
margin-top:8px;
min-height:100px;
padding:10px 12px;
border-radius:10px;
}

.receipt-total span{
font-size:16px;
}

.receipt-total strong{
font-size:clamp(20px,6vw,28px);
}

.transaction-notes{
margin-top:8px;
min-height:58px;
padding:9px 10px;
border-radius:10px;
}

.transaction-notes strong{
font-size:14px;
}

.receipt-notes{
margin-top:8px;
min-height:64px;
padding:9px 10px;
border-radius:10px;
}

.receipt-notes p{
font-size:10.5px;
line-height:1.55;
}
}

@media (min-width:761px) and (max-width:1024px){
body{
padding:14px;
}

.container{
width:min(100%,920px);
padding:22px;
border-radius:20px;
}

.form-grid{
gap:16px;
}
}

@media (max-width:380px){
.container{
padding:14px;
}

h1{
font-size:21px;
}

.field label{
font-size:13px;
}

.btn{
font-size:14px;
}
}