/* 
 * Exact On-Screen & Printable Replica of Printed Invoice
 * Matches invoice.jpeg visual layout and typography
 */

.invoice-sheet-container {
  background: #525659;
  padding: 24px 12px;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  min-height: 100%;
  overflow-y: auto;
}

.invoice-sheet {
  background: #ffffff;
  width: 210mm;
  min-height: 297mm;
  padding: 10mm 10mm 10mm 10mm;
  box-shadow: 0 4px 14px rgba(0,0,0,0.25);
  font-family: Arial, "Helvetica Neue", Helvetica, sans-serif;
  color: #111111;
  position: relative;
  box-sizing: border-box;
}

/* Outer Border framing the entire document matching the photo */
.invoice-outer-frame {
  border: 1.5px solid #222222;
  height: 275mm;
  padding: 8px 10px 10px 10px;
  position: relative;
  box-sizing: border-box;
}

/* Header Section */
.invoice-header-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  padding-bottom: 6px;
  border-bottom: 1.2px solid #222222;
}

.inv-header-left {
  width: 28%;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.inv-logo-img {
  width: 64px;
  height: 64px;
  object-fit: contain;
  margin-bottom: 2px;
}

.inv-regd-no {
  font-size: 10px;
  font-weight: bold;
  color: #111111;
}

.inv-header-center {
  width: 44%;
  text-align: center;
  padding-top: 2px;
}

.inv-company-title {
  font-size: 15px;
  font-weight: 800;
  color: #0b192e;
  letter-spacing: -0.2px;
  line-height: 1.2;
  margin-bottom: 2px;
}

.inv-company-address {
  font-size: 11.5px;
  font-weight: 600;
  color: #333333;
}

.inv-company-province {
  font-size: 11px;
  font-weight: 500;
  color: #444444;
}

.inv-header-right {
  width: 28%;
  text-align: right;
  padding-top: 6px;
  font-size: 10.5px;
  line-height: 1.4;
}

.inv-contact-item {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 4px;
  color: #222222;
}

/* Project & Metadata Section */
.invoice-meta-section {
  padding: 6px 2px;
  font-size: 11px;
  line-height: 1.45;
}

.inv-meta-row {
  display: flex;
  justify-content: space-between;
  margin-bottom: 2px;
}

.inv-meta-full {
  margin-bottom: 2px;
}

.inv-meta-label {
  font-weight: bold;
  color: #111111;
}

.inv-meta-value {
  color: #222222;
}

/* "INVOICE" Title Box */
.invoice-title-bar {
  border: 1.2px solid #222222;
  text-align: center;
  font-weight: 800;
  font-size: 13px;
  padding: 3px;
  margin: 4px 0 0 0;
  letter-spacing: 1.5px;
  background-color: #ffffff;
}

/* Printable Invoice Table */
.print-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
  font-size: 10.5px;
  margin-top: -1px;
}

.print-table th, .print-table td {
  border: 1px solid #222222;
  padding: 3px 5px;
  vertical-align: middle;
  box-sizing: border-box;
}

.print-table th {
  text-align: center;
  font-weight: bold;
  background-color: #ffffff;
  padding: 4px 3px;
}

.print-table tr.sub-header-row th {
  font-weight: normal;
  font-size: 9.5px;
  padding: 1px 3px;
}

.print-table td.text-center { text-align: center; }
.print-table td.text-left { text-align: left; }
.print-table td.text-right { text-align: right; font-variant-numeric: tabular-nums; }

.print-table tr.empty-pad-row td {
  height: 22px;
}

.print-table tr.table-summary-row {
  display: table-row !important;
}

.print-table tr.table-summary-row td {
  display: table-cell !important;
  font-weight: bold;
  background-color: #ffffff;
  border: 1px solid #222222;
  padding: 3.5px 5px;
}

.print-table tr.grand-total-row td {
  font-weight: 900;
  font-size: 11.5px;
  border-top: 1.5px solid #222222;
}

/* Footer Section - Docked cleanly at bottom */
.invoice-print-footer {
  position: absolute;
  bottom: 8px;
  left: 10px;
  right: 10px;
}

.inv-words-row {
  font-size: 11px;
  margin-bottom: 16px;
  padding-left: 2px;
}

.inv-words-row strong {
  font-weight: bold;
}

.inv-signature-block {
  display: flex;
  justify-content: flex-end;
  padding-right: 6px;
}

.inv-signature-box {
  text-align: right;
  font-size: 10.5px;
  line-height: 1.35;
  display: inline-block;
}

.inv-signature-dots {
  letter-spacing: 2px;
  margin-bottom: 2px;
}

.inv-signature-company {
  font-weight: bold;
}

.inv-signature-role {
  font-size: 9.5px;
  color: #444444;
}
