@media print {
  /* Hide everything except the receipt */
  body * { visibility: hidden; }
  .receipt-print, .receipt-print * { visibility: visible; }
  .receipt-print {
    position: absolute; left: 0; top: 0;
  }
  @page { margin: 0; padding: 0; }
}

.receipt-print {
  font-family: 'Courier New', monospace;
  color: #000;
  background: #fff;
  padding: 8px;
  line-height: 1.4;
}

.receipt-print.width-58mm { width: 48mm; font-size: 11px; }
.receipt-print.width-80mm { width: 72mm; font-size: 12px; }

/* Header */
.receipt-header { text-align: center; margin-bottom: 8px; }
.receipt-header .resto-name { font-size: 16px; font-weight: bold; }
.receipt-header .resto-address { font-size: 10px; }

/* Divider */
.receipt-divider { border-top: 1px dashed #000; margin: 6px 0; }

/* Items */
.receipt-items { width: 100%; }
.receipt-items td { padding: 2px 0; vertical-align: top; }
.receipt-items .item-name { }
.receipt-items .item-qty { text-align: center; width: 30px; }
.receipt-items .item-price { text-align: right; }

/* Summary */
.receipt-summary { margin-top: 6px; }
.receipt-summary-row { display: flex; justify-content: space-between; padding: 1px 0; }
.receipt-summary-row.total { font-weight: bold; font-size: 14px; border-top: 1px dashed #000; padding-top: 4px; margin-top: 4px; }

/* Footer */
.receipt-footer { text-align: center; margin-top: 10px; font-size: 10px; }
.receipt-footer .powered-by { font-size: 9px; opacity: 0.6; margin-top: 4px; }
