/* A4 report sheets — used both for on-screen preview and printing */
/* keep cell colours when printing (otherwise Chromium/WebView2 drops background colours by default) */
.sheet, .sheet * { -webkit-print-color-adjust: exact !important; print-color-adjust: exact !important; color-adjust: exact !important; }
.sheet { width: 210mm; height: 297mm; overflow: hidden; background: #fff; color: #000; padding: 10mm 10mm 14mm; font: 7.6pt/1.25 Arial, "Segoe UI", sans-serif; position: relative; }
.sheet * { box-sizing: border-box; }
.sheet .rhead { display: flex; justify-content: space-between; align-items: flex-end; margin-bottom: 2mm; }
.sheet .logos { display: flex; align-items: flex-end; gap: 4mm; }
.sheet .logos .mark { height: 13mm; }
.sheet .logos .wordmark { height: 13mm; }
.sheet .rhead-right { display: flex; flex-direction: column; align-items: flex-end; gap: 2mm; }
.sheet .formno, .sheet .tagbox { border-collapse: collapse; }
.sheet .formno td { border: 0.6pt solid #808080; padding: 1mm 2mm; min-width: 22mm; }
.sheet .formno td.lab { background: #D9E1F2; font-weight: bold; }
.sheet .tagbox td { border: 0.6pt solid #808080; padding: 1.4mm 3mm; font-size: 9pt; font-weight: bold; }
.sheet .tagbox td.lab { background: #D9E1F2; min-width: 40mm; text-align: center; }
.sheet .tagbox td.tagv { background: #9DC3E6; min-width: 30mm; text-align: center; font-size: 10.5pt; }
.sheet .client-copy { background: #C00000; color: #fff; font-weight: bold; font-size: 10pt; padding: 2mm 8mm; letter-spacing: .5pt; }
.sheet .confid { color: #C00000; font-style: italic; font-size: 7pt; margin-bottom: 1.5mm; }

table.rt { width: 100%; border-collapse: collapse; table-layout: fixed; }
table.rt td { border: 0.6pt solid #A6A6A6; padding: 0.7mm 1.2mm; height: 4.6mm; overflow: hidden; vertical-align: middle; word-wrap: break-word; }
table.rt td.sec { background: #1F3864; color: #fff; font-weight: bold; font-size: 8.6pt; text-transform: uppercase; padding: 1mm 1.5mm; border-color: #1F3864; }
table.rt td.subsec { background: #B4C6E7; font-weight: bold; }
table.rt td.lab { background: #D9E1F2; font-weight: bold; }
table.rt td.mlab { background: #fff; }
table.rt td.val { text-align: center; }
table.rt td.val.left { text-align: left; }
table.rt td.val.strong { font-weight: bold; }
table.rt td.val.pre { white-space: pre-wrap; vertical-align: top; }
table.rt td.blank { border: 0; }
table.rt td.restricted { color: #8C8C8C; font-style: italic; background: #F2F2F2; }
table.rt tr.th td { background: #D9E1F2; font-weight: bold; text-align: center; }
table.rt td.item { text-align: left; }
table.rt td.rmk { text-align: left; }
table.rt td.cond { text-align: center; }
table.rt td.cond.good { background: #C6EFCE; }
table.rt td.cond.fair { background: #FFEB9C; }
table.rt td.cond.poor { background: #FFC7CE; }
table.rt td.cond.na { background: #F2F2F2; }
table.rt td.crit-C1 { background: #FF0000; color: #fff; font-weight: bold; }
table.rt td.crit-C2 { background: #FFC000; font-weight: bold; }
table.rt td.crit-C3 { background: #00B050; color: #fff; font-weight: bold; }
table.rt tr.tall td { height: 9mm; }
table.rt td.notice { background: #FFF2CC; font-style: italic; font-size: 7pt; }
table.rt td.muted { color: #8C8C8C; font-style: italic; }
table.rt td.photo { height: 46mm; padding: 1mm; text-align: center; background: #F7F7F7; }
table.rt td.photo img { max-width: 100%; max-height: 44mm; object-fit: contain; display: block; margin: auto; }
table.rt td.photo span { color: #A6A6A6; font-style: italic; }
table.rt td.cap { height: 4.6mm; }
table.photos-t { margin-top: 2mm; page-break-inside: avoid; break-inside: avoid; }
.sheet .rfoot { position: absolute; left: 10mm; right: 10mm; bottom: 6mm; display: flex; justify-content: space-between; font-size: 6.5pt; color: #7F7F7F; border-top: 0.5pt solid #BFBFBF; padding-top: 1mm; }

/* checklist */
.sheet.checklist { font-size: 7.4pt; }
.sheet.checklist .ck-head { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 2mm; }
.sheet.checklist .ck-head b { font-size: 10.5pt; color: #1F3864; }
.sheet.checklist .ck-head .small { font-size: 6.8pt; font-style: italic; color: #404040; margin-top: 1mm; }
.sheet.checklist .pgno { font-size: 7pt; color: #595959; }
table.rt.ck tr.w td { height: 6.6mm; }
table.rt.ck td.lab { font-weight: normal; background: #EEF2F9; }
table.rt.ck td.opts { color: #808080; font-size: 6.4pt; text-align: center; line-height: 1.15; }
table.rt.ck td.chk { border: 0; border-bottom: 0.4pt solid #D9D9D9; height: 5mm; }
table.rt.ck td.hint { border: 0; font-size: 6.4pt; font-style: italic; color: #595959; }
table.rt.ck tr.tall2 td { height: 13mm; }

/* screen preview of sheets */
@media screen { .sheet { margin: 0 auto; } }
@media print {
  .sheet { box-shadow: none !important; margin: 0 !important; page-break-after: always; break-after: page; }
  .sheet:last-child { page-break-after: auto; break-after: auto; }
}
