/* Clean print-like look faithful to the sample layout */
@page { size: A4; margin: 12mm; }
*{ box-sizing: border-box; }
body{ font-family: Arial, Helvetica, sans-serif; color:#000; margin:0; }
.wrapper{ width: 210mm; margin:0 auto; background:#fff; }
.header{
  display:flex; align-items:center; border-bottom:2px solid #d8e6f7; padding:8px 8px 6px 8px;
}
.header .logo{ display:flex; align-items:center; gap:10px; }
.header img.logo-img{ width:54px; height:54px; }
.header .brand{ line-height:1; }
.header .brand .didam{ font-size:34px; font-weight:700; letter-spacing:1px; color:#2f7fb7; }
.header .brand .cctv{ font-size:24px; font-weight:800; color:#3a3a3a; letter-spacing:3px; }

.header .address{
  margin-left:auto; text-align:right; font-size:14px; font-weight:600;
}

.subhead{ display:flex; justify-content:space-between; padding:8px 8px; font-size:13px; }
.grid-2{ display:grid; grid-template-columns:1fr 1fr; gap:12px; }

.badge-table{ width:100%; border-collapse:collapse; font-size:13px; }
.badge-table td{ padding:3px 6px; border:1px solid #a7c4df; background:#f0f6fc; }

.meta{ display:flex; justify-content:space-between; padding:0 8px 8px 8px; font-size:12px; color:#222; }
.meta .right{ text-align:right; }

.items{ width:100%; border-collapse:collapse; font-size:13px; }
.items th, .items td{ border:1px solid #6ea3cf; padding:6px 6px; }
.items thead th{ background:#8db7dd; color:#000; font-weight:700; text-align:center; }
.items td:nth-child(1){ width:28px; text-align:center; }
.items td:nth-child(2){ width:auto; }
.items td:nth-child(3){ width:180px; }
.items td:nth-child(4){ width:48px; text-align:center; }
.items td:nth-child(5){ width:90px; text-align:center; }
.items td:nth-child(6){ width:110px; text-align:center; }

.total-words{ background:#8db7dd; padding:8px; font-weight:600; text-align:left; font-size:14px; }
.summary-row{ display:grid; grid-template-columns:80px 1fr 120px 110px; gap:6px; align-items:center; }
.summary-row .label{ text-align:right; font-weight:600; }
.summary-row .value{ text-align:right; }

.footer{
  margin-top:10px; background:#8db7dd; padding:14px 10px 30px 10px; position:relative;
}
.footer .thanks{
  position:absolute; left:0; right:0; bottom:8px; background:#0e0e0e; color:#fff;
  font-weight:600; margin:0 10px; padding:8px 16px; text-align:center; border-radius:20px;
}
.footer .right-block{
  position:absolute; right:12px; bottom:52px; text-align:right; font-size:14px; line-height:1.6;
}
.footer .right-block .phones{ margin-top:6px; }

.print-btn{ display:inline-block; padding:8px 12px; border:1px solid #ccc; margin:10px 0; text-decoration:none; }
.only-screen{ display:block; }
@media print {
  .only-screen{ display:none; }
  body{ margin:0; }
  .wrapper{ box-shadow:none; }
}
