<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>Delivery Receipt</title>
    <style>
      body {
        font-family: Arial, sans-serif;
        margin: 0;
        padding: 0;
        font-size: 10px;
        line-height: 1.3;
      }

      .receipt-container {
        width: 800px;
        margin-left: 0; /* pushes it to the right */
        margin-right: auto; /* make sure it's flush with the right */
      }

      .header {
        text-align: center;
        opacity: 0;
        margin-bottom: 1rem;
      }

      .header h1 {
        font-size: 18px;
        margin: 5px 0;
        font-weight: bold;
      }

      .header p {
        margin: 3px 0;
        font-size: 11px;
      }

      .document-title {
        opacity: 0;
        text-align: center;
        font-size: 16px;
        font-weight: bold;
        margin: 10px 0;
        text-decoration: underline;
      }

      .details-table {
        width: 100%;
        margin-left: 2rem;
        border-collapse: collapse;
      }

      .details-table td {
        padding: 4px 5px;
        vertical-align: top;
      }

      .detail-label {
        opacity: 0;
        font-weight: bold;
        white-space: nowrap;
      }

      .detail-value {
        /* border-bottom: 1px solid black; */
        width: 100%;
        padding-bottom: 2px;
        font-size: 8px;
      }

      .items-table {
        width: 100%;
        border-collapse: collapse;
        margin: 10px 0;
      }
      .items-table thead {
        opacity: 0;
      }

      .items-table th,
      .items-table td {
        /* border: 1px solid black; */
        padding: 5px;
      }

      .items-table th {
        font-weight: bold;
        text-align: center;
      }

      .signatures-table {
        opacity: 0;
        width: 100%;
        margin-top: 20px;
        border-collapse: collapse;
      }

      .signatures-table td {
        vertical-align: top;
        padding: 0 5px;
        width: 33%;
      }

      .signature-line {
        border-top: 1px solid black;
        margin-top: 25px;
        padding-top: 3px;
        font-size: 10px;
      }

      .footer {
        opacity: 0;
        margin-top: 30px;
        font-size: 10px;
        text-align: center;
      }

      .footer-note {
        font-weight: bold;
        margin-top: 5px;
      }

      @media print {
        body {
          padding: 0;
          margin: 0;
        }

        .receipt-container {
          padding: 10px;
        }
      }
    </style>
  </head>
  <body>
    <div class="receipt-container">
      <div class="header"></div>

      <div class="document-title">DELIVERY RECEIPT</div>

      <table class="details-table">
        <tr>
          <td style="width: 38%">
            <table>
              <tr>
               <td class="detail-value">{{customerName}}</td>
              </tr>
              <tr>
                 <td class="detail-value">{{tinNumber}}</td>
              </tr>
              <tr>
                
                 <td class="detail-value">{{address}}</td>
              </tr>
            </table>
          </td>
          <td style="width: 60%">
            <table>
              <tr>
                 <td class="detail-value">{{dateNTime}}</td>
              </tr>
              <tr>
                <td class="detail-value">{{terms}}</td>
              </tr>
              <tr>
                 <td class="detail-value">{{ordNumber}}</td>
              </tr>
            </table>
          </td>
        </tr>
      </table>

      <table class="items-table">
       
        <tbody>
           {{#each orderDetails}}
          <tr>
           <td style="width: 3rem">{{this.qty}}</td>
            <td>{{this.unit}}</td>
            <td>{{this.description}}</td>
          </tr>
         
           {{/each}}
        </tbody>
      </table>

      <table class="signatures-table">
        <tr>
          <td>
            <div>Issued by:</div>
            <div class="signature-line">SIGNATURE OVER PRINTED NAME</div>
          </td>
          <td>
            <div>Delivered by:</div>
            <div class="signature-line">SIGNATURE OVER PRINTED NAME</div>
          </td>
          <td>
            <div>
              Received the above items in complete and good condition By:
            </div>
            <div class="signature-line">SIGNATURE OVER PRINTED NAME</div>
          </td>
        </tr>
      </table>

      <div class="footer">
        <div>This is computer-generated form.</div>
        <div class="footer-note">
          THIS DOCUMENT IS NOT VALID FOR CLAIM OF INPUT TAX
        </div>
      </div>
    </div>
  </body>
</html>
