/* Dedicated Bill Pay check styles — exact duplicate of bank bill payment format */
.billpay-check {
  position: relative;
  box-sizing: border-box;
  width: 100%;
  height: auto;
  aspect-ratio: 8.5 / 3.5;
  padding: calc(0.20 * var(--inch)) calc(0.42 * var(--inch)) 0 calc(0.42 * var(--inch));
  background: #fff;
  color: #000;
  font-family: 'Times New Roman', Times, Georgia, serif;
  line-height: 1.2;
  overflow: hidden;
  border-bottom: 0 !important;
}
.billpay-check [data-drag-key]:not(.sheet-logo):not(.billpay-micr) {
  position: static;
}

/* Header row: Account ... PLEASE POST THIS PAYMENT ... and $Amount */
.billpay-header-row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  width: 100%;
  color: #000;
}
.billpay-header-left {
  display: flex;
  align-items: baseline;
  min-width: 0;
  font-family: 'Times New Roman', Times, Georgia, serif;
  color: #000;
  white-space: nowrap;
}
.billpay-account-heading {
  flex: none;
  font-size: calc(0.22 * var(--inch));
  font-weight: 400;
}
.billpay-posting-instruction {
  min-width: 0;
  margin-left: calc(0.04 * var(--inch));
  font-size: calc(0.14 * var(--inch));
  font-weight: 500;
}
.billpay-header-left .print-payment-reference {
  font-weight: inherit;
}
.billpay-header-right {
  font-family: 'Times New Roman', Times, Georgia, serif;
  font-size: calc(0.14 * var(--inch));
  font-weight: 400;
  color: #000;
  white-space: nowrap;
}
.billpay-header-right .print-amount {
  font-weight: inherit;
}
.billpay-top-divider {
  width: calc(100% + 0.84 * var(--inch));
  margin-left: calc(-0.42 * var(--inch));
  height: 1px;
  background: #000;
  margin-top: calc(0.04 * var(--inch));
}

/* Sub-header 3 columns: Payer (left), Questions (center), Check info (right) */
.billpay-sub-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-top: calc(0.07 * var(--inch));
  width: 100%;
}
.billpay-payer-col {
  width: calc(2.8 * var(--inch));
  font-family: 'Times New Roman', Times, Georgia, serif;
  color: #000;
}
.billpay-payer-col strong.print-payer {
  display: block;
  font-size: calc(0.19 * var(--inch)) !important;
  font-weight: 700;
  text-transform: uppercase;
  color: #000;
  line-height: 1.2;
}
.billpay-payer-col .print-address {
  display: block;
  font-size: calc(0.18 * var(--inch)) !important;
  font-weight: 700;
  text-transform: uppercase;
  color: #000;
  white-space: pre-line;
  line-height: 1.25;
  margin-top: calc(0.02 * var(--inch));
}
.billpay-enquiries-col {
  width: calc(2.5 * var(--inch));
  margin-left: calc(0.25 * var(--inch));
  font-family: 'Times New Roman', Times, Georgia, serif;
  font-size: calc(0.14 * var(--inch));
  line-height: 1.25;
  color: #000;
}
.billpay-enquiries-label {
  font-size: inherit;
  color: inherit;
}
.billpay-enquiries-col .print-contact-phone {
  font-size: inherit;
  color: inherit;
}
.billpay-enquiries-col .print-contact-name {
  font-size: inherit;
  color: inherit;
}
.billpay-checkinfo-col {
  width: calc(2.0 * var(--inch));
  text-align: right;
  font-family: 'Times New Roman', Times, Georgia, serif;
  font-size: calc(0.19 * var(--inch));
  line-height: 1.25;
  color: #000;
}
.billpay-checkinfo-col .billpay-info-row {
  white-space: nowrap;
  line-height: 1.35;
}
.billpay-checkinfo-col strong.print-number {
  font-weight: 400;
  font-size: inherit;
  color: inherit;
}
.billpay-checkinfo-col .fractional-routing {
  font-size: inherit !important;
  font-weight: 400;
  color: inherit;
}
.billpay-checkinfo-col strong.print-date {
  font-weight: 400;
  font-size: inherit;
  color: inherit;
}

/* Bank name line above Dollars */
.billpay-bank-row {
  display: flex;
  justify-content: flex-end;
  margin-top: calc(0.19 * var(--inch));
  width: 100%;
}
.billpay-bank-row strong.print-bank {
  font-family: 'Times New Roman', Times, Georgia, serif;
  font-size: calc(0.15 * var(--inch));
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: #000;
}

/* Amount in words row: Pay ... *** Dollars */
.billpay-words-row {
  display: flex;
  align-items: baseline;
  width: 100%;
  margin-top: calc(0.045 * var(--inch));
  padding-bottom: calc(0.025 * var(--inch));
  font-family: 'Times New Roman', Times, Georgia, serif;
  font-size: calc(0.19 * var(--inch));
  color: #000;
}
.billpay-check .billpay-words-row[data-drag-key] {
  position: relative;
}
.billpay-words-row::after {
  position: absolute;
  right: 0;
  bottom: 0;
  left: calc(0.58 * var(--inch));
  border-bottom: 1.5px solid #000;
  content: '';
}
.billpay-check .billpay-words-row[data-drag-key] > .billpay-pay-label {
  font-size: calc(0.19 * var(--inch)) !important;
  font-weight: 700 !important;
  margin-right: calc(0.08 * var(--inch));
  color: #000;
}
.billpay-words-row strong.print-words {
  font-size: inherit;
  font-weight: 400;
  white-space: nowrap;
  color: #000;
}
.billpay-check .billpay-words-row[data-drag-key] > .billpay-words-filler {
  flex: 1;
  overflow: hidden;
  white-space: nowrap;
  margin: 0 calc(0.03 * var(--inch));
  letter-spacing: 0.5px;
  color: #000;
  font-size: calc(0.21 * var(--inch)) !important;
}
.billpay-words-filler::after {
  content: '************************************************************************************************************************';
}
.billpay-check .billpay-words-row[data-drag-key] > .billpay-dollars-label {
  font-size: calc(0.18 * var(--inch)) !important;
  font-weight: 400;
  margin-left: calc(0.03 * var(--inch));
  color: #000;
}

/* Main Body Row: Payee (left) & Amount Box + Authorization (right) */
.billpay-body-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  min-height: calc(1.02 * var(--inch));
  margin-top: calc(0.06 * var(--inch));
  width: 100%;
}
.billpay-recipient-block {
  display: flex;
  align-items: flex-start;
  gap: calc(0.12 * var(--inch));
  width: calc(4.8 * var(--inch));
}
.billpay-order-label {
  display: flex;
  flex-direction: column;
  font-family: 'Times New Roman', Times, Georgia, serif;
  font-weight: 700;
  font-size: calc(0.12 * var(--inch));
  line-height: 1.15;
  letter-spacing: 0.5px;
  width: calc(0.55 * var(--inch));
  color: #000;
  padding-top: calc(0.015 * var(--inch));
}
.billpay-recipient-details {
  font-family: 'Times New Roman', Times, Georgia, serif;
  color: #000;
  flex: 1;
}
.billpay-recipient-details strong.print-payee {
  display: block;
  font-size: calc(0.16 * var(--inch));
  font-weight: 400;
  line-height: 1.25;
  color: #000;
}
.billpay-recipient-details .print-recipient-address {
  font-size: calc(0.15 * var(--inch));
  font-weight: 400;
  white-space: pre-line;
  line-height: 1.25;
  margin-top: calc(0.02 * var(--inch));
  color: #000;
}
.billpay-barcode-container {
  margin-top: calc(0.05 * var(--inch));
}
.billpay-barcode-container .postal-barcode {
  display: block;
  width: calc(2.5 * var(--inch));
  height: calc(0.16 * var(--inch));
  object-fit: fill;
}

/* Right block: Amount box & Authorization notice */
.billpay-right-block {
  width: calc(1.85 * var(--inch));
  display: flex;
  flex-direction: column;
  align-items: center;
}
.billpay-amount-row {
  display: flex;
  align-items: center;
  width: 100%;
}
.billpay-amount-box {
  box-sizing: border-box;
  flex: 1;
  height: calc(0.38 * var(--inch));
  border: calc(0.03 * var(--inch)) solid #000;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  padding: 0 calc(0.08 * var(--inch));
  background: #fff;
}
.billpay-check .billpay-amount-row > .billpay-box-currency {
  font-family: 'Times New Roman', Times, Georgia, serif;
  font-size: calc(0.18 * var(--inch)) !important;
  font-weight: 400;
  margin-right: calc(0.04 * var(--inch));
  color: #000;
}
.billpay-box-stars {
  font-family: 'Times New Roman', Times, Georgia, serif;
  font-size: calc(0.19 * var(--inch));
  font-weight: 600;
  letter-spacing: 0.5px;
  color: #000;
}
.billpay-amount-box strong.print-amount {
  font-family: 'Times New Roman', Times, Georgia, serif;
  font-size: calc(0.19 * var(--inch));
  font-weight: 600;
  color: #000;
}
.billpay-auth-block {
  margin-top: calc(0.16 * var(--inch));
  text-align: center;
  font-family: 'Times New Roman', Times, Georgia, serif;
  color: #000;
  width: 100%;
}
.billpay-auth-condition {
  font-size: calc(0.105 * var(--inch));
  line-height: 1.25;
  margin-bottom: calc(0.015 * var(--inch));
  color: #000;
}
.billpay-auth-line {
  font-size: calc(0.105 * var(--inch));
  line-height: 1.25;
  color: #000;
}

/* MICR Divider and MICR Line */
.billpay-micr-divider {
  position: absolute;
  left: 0;
  right: 0;
  width: 100%;
  bottom: calc(0.60 * var(--inch));
  height: 1px;
  background: #000;
  margin: 0;
}
.billpay-check .sheet-micr.billpay-micr {
  position: absolute !important;
  inset: auto !important;
  left: 0 !important;
  right: 0 !important;
  width: 100% !important;
  bottom: calc(0.18 * var(--inch)) !important;
  height: calc(0.34 * var(--inch)) !important;
  padding-bottom: 10px !important;
  box-sizing: border-box !important;
  margin: 0 !important;
  display: flex !important;
  align-items: center !important;
  justify-content: var(--field-align, center) !important;
  text-align: var(--field-align, center) !important;
  font-family: "Checkethical MICR", "Nimra", monospace !important;
  font-size: calc(0.16 * var(--inch)) !important;
  line-height: 1 !important;
  letter-spacing: 0 !important;
  color: #000 !important;
}

/* Bottom Perforation Line */
.billpay-perforation-line {
  position: absolute;
  left: 0;
  right: 0;
  width: 100%;
  bottom: calc(0.08 * var(--inch));
  height: calc(0.06 * var(--inch));
  border-top: 1px solid #777;
  border-bottom: 1px solid #777;
}

@media print {
  .billpay-check {
    width: 8.5in !important;
    height: 3.5in !important;
    border: 0 !important;
    outline: 0 !important;
  }
}
