/* NORMAL SCREEN STYLE */
.receipt-print {
  font-family: 'Nunito Sans', -apple-system, sans-serif;
  max-width: 800px;
  margin: 20px auto;
  padding: 30px;
  border: 1px solid #ddd;
  background: white;
  box-shadow: 0 2px 10px rgba(0,0,0,0.1);
  max-height: none;
  overflow: visible;
}

.receipt-print .navyStrip {
  background: #1f376d;
  height: 30px;
  width: calc(100% + 60px);
  margin: -30px -30px 20px -30px;
}

.receipt-print .logoStyle {
  height: 60px;
  width: auto;
}

/* CORRECTED — SPACE WAS MISSING */
.receipt-print .titleLogoRow {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-top: 12px;
}

.receipt-print .logoRightBox {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 4px;
}

.receipt-print .receiptNoBox {
  background: white;
  border: 2px solid #1f376d;
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 16px;
  font-weight: bold;
  color: #1f376d;
  white-space: nowrap;
}

.receipt-print .receiptTitle {
  font-size: 32px;
  font-weight: bold;
  color: #1f376d;
}

.receipt-print .fieldLabel {
  font-weight: bold;
  display: inline-block;
  width: 250px;
  color: #333;
}

.receipt-print .amountBox {
  margin-top: 25px;
  display: flex;
  gap: 12px;
  align-items: center;
}

.receipt-print .amountLabel {
  font-size: 17px;
  font-weight: bold;
  color: #1f376d;
}

.receipt-print .amountValue {
  border: 2px solid #1f376d;
  padding: 10px 15px;
  border-radius: 20px;
  font-weight: bold;
  background: #f8f9ff;
  width: 160px;
  margin-top: 5px;
  text-align: center;
}

/* PRINT CLEAN — NO DUPLICATES */
@media print {
  @page { size: A4; margin: 10mm; }

  /* SHOW ONLY RECEIPT WHEN PRINTING */
  body * {
    visibility: hidden !important;
  }
  .receipt-print, .receipt-print * {
    visibility: visible !important;
  }

  /* CENTER RECEIPT ON PAGE */
  .receipt-print {
    position: absolute !important;
    left: 0;
    right: 0;
    margin: auto !important;
    top: 0;
    transform: scale(1) !important;
    width: 900px !important;
    padding: 30px !important;
    background: white !important;
    border: 1px solid #dcdcdc !important;
    box-shadow: none !important;
    page-break-inside: avoid !important;
  }

  /* KEEP FULL DESIGN COLORS */
  body {
    -webkit-print-color-adjust: exact !important;
    print-color-adjust: exact !important;
    background: white !important;
  }

  /* PREVENT COLLAPSE */
  .receipt-print * {
    page-break-before: avoid !important;
    page-break-after: avoid !important;
    page-break-inside: avoid !important;
  }

  /* KEEP LOGO + TITLE + RECEIPT NO EXACTLY SAME */
  .titleLogoRow {
    display: flex !important;
    justify-content: space-between !important;
    align-items: flex-start !important;
  }

  /* FIX SIGNATURE SIZE */
  .signatureStyle {
    width: 90px !important;
    height: auto !important;
    object-fit: contain !important;
  }

  /* TERMS TITLE NAVY STRIP MUST PRINT */
  .termsLine span {
    background: #1f376d !important;
    color: white !important;
    border-radius: 20px !important;
    padding: 6px 25px !important;
    font-weight: bold !important;
  }
  .termsLine::before,
  .termsLine::after {
    content: "" !important;
    flex: 1 !important;
    border-top: 2px solid #1f376d !important;
    margin: 0 12px !important;
  }
}
