/* ============================================================================
   assets/css/cetak.css
   Gaya dokumen resmi MQK (bukti pendaftaran, surat, laporan).

   Berkas ini adalah SATU-SATUNYA sumber gaya dokumen cetak, dipakai bersama
   oleh:
     - tampilan layar : cetak.php, template_surat.php
     - berkas PDF     : includes/pdf.php (fungsi pdf_dokumen)

   Catatan: mPDF tidak mendukung flexbox/grid maupun variabel CSS. Karena itu
   semua aturan di bawah hanya memakai properti yang aman untuk mPDF. Nama font
   'freesans'/'freeserif' dikenali mPDF; browser mengabaikannya lalu memakai
   font berikutnya pada daftar (system-ui / Georgia).
   ============================================================================ */

body {
  margin: 0;
  font-family: 'freesans', system-ui, -apple-system, 'Segoe UI', Arial, sans-serif;
  font-size: 10pt;
  line-height: 1.5;
  color: #16202a;
}
.serif { font-family: 'freeserif', Georgia, 'Times New Roman', serif; }

/* ------------------------------- Kop surat -------------------------------- */
/* Garis dobel dibuat dua lapis (tebal + tipis tipis) agar tetap aman di mPDF
   yang tidak mendukung border-bottom-style: double. */
.kop {
  color: #16202a;
  border-bottom: 1.6pt solid #16202a;
  padding-bottom: 6px;
  margin-bottom: 14px;
}
.kop-garis { border-bottom: 0.5pt solid #16202a; height: 0; margin-top: 2px; }

/* --------------------------------- Tabel ---------------------------------- */
table { border-collapse: collapse; }
.tabel { width: 100%; }
.tabel th, .tabel td { border: 0.4pt solid #bcc7cf; padding: 4pt 6pt; vertical-align: top; }
.tabel thead th { background: #eaf2ee; color: #0a4d31; font-weight: bold; }
.tabel tbody tr { page-break-inside: avoid; }
.tabel.mini { font-size: 8.5pt; }

/* Tabel kunci–nilai (tanpa garis) — dipakai di bukti pendaftaran. */
.tabel-kop th { width: 34%; text-align: left; border: none; padding: 3pt 0; font-weight: bold; color: #33414f; }
.tabel-kop td { border: none; padding: 3pt 0; }

/* ----------------------------- Judul dokumen ------------------------------ */
.judul-dok {
  font-weight: bold;
  text-align: center;
  font-size: 11.5pt;
  text-decoration: underline;
  letter-spacing: 0.2px;
  margin: 12px 0 3px;
}
.sub-judul { text-align: center; font-size: 9pt; color: #55636e; margin-bottom: 14px; }

/* ------------------------------ Tanda tangan ------------------------------ */
/* Ruang tanda tangan. PENTING: mPDF MENGABAIKAN `height` pada <div> kosong
   (menghasilkan 0 mm), jadi ruang harus berupa SEL TABEL bertinggi tetap agar
   jarak tanda tangan tampil sama di layar maupun di berkas PDF. */
.ttd { width: 100%; border-collapse: collapse; }
.ttd td { height: 90px; }
.ttd-blok { width: 50%; vertical-align: top; text-align: center; font-size: 9.5pt; padding-top: 4px; }


/* ------------------------------ Kotak & misc ------------------------------ */
.kotak { border: 0.5pt solid #9fb0ba; background: #f6f9f8; padding: 6pt 8pt; font-size: 9pt; }
.garis { border-bottom: 0.4pt dotted #333; }
.kecil { font-size: 8.5pt; color: #5b6b7c; }
.kanan { text-align: right; }
.tengah { text-align: center; }
.tebal { font-weight: bold; }
.mono { font-family: 'freesans', Consolas, 'Courier New', monospace; letter-spacing: 0.3px; }
.halaman { page-break-after: always; }
.tanpa-spasi { margin: 0; padding: 0; }

/* ---------------- Kartu finalis LITE (cadangan mPDF, tanpa flexbox) ----------------
   Chrome memakai assets/css/kartu.css (flexbox). mPDF hanya memuat berkas ini,
   jadi tata letak di sini memakai float/block yang aman untuk mPDF. */
.kf-lite {
    display: block; box-sizing: border-box;
    width: 105mm; height: 148mm; padding: 2.6mm;
    background: #ffffff; color: #1f1f1f;
    border: 0.4mm solid #1f7c3f; border-radius: 3mm;
    page-break-inside: avoid;
    font-family: 'freeserif', 'Times New Roman', serif;
}
.kf-inner-lite {
    display: block; box-sizing: border-box; height: 100%;
    padding: 3.4mm 4mm 3mm; border: 0.3mm solid #d4af37; border-radius: 2mm;
}
.kf-head-lite { display: block; padding-bottom: 2mm; border-bottom: 0.25mm solid #d4af37; }
.kf-head-lite .kf-emblem { float: left; width: 12mm; text-align: center; }
.kf-head-lite .kf-emblem + .kf-title + .kf-emblem { float: right; }
.kf-head-lite .kf-title { margin: 0 13mm; text-align: center; line-height: 1.12; }
.kf-head-lite::after { content: ""; display: block; clear: both; }
.kf-photo-wrap { display: block; margin-top: 3mm; text-align: center; }
.kf-photo-pos { position: relative; display: inline-block; width: 31mm; height: 39mm; text-align: left; }
.kf-photo-lite { width: 31mm; height: 39mm; overflow: hidden; border: 0.6mm solid #1f7c3f; background: #f5f5f5; border-radius: 15.5mm; }
.kf-oval-img { width: 31mm; height: 39mm; display: block; }
.kf-name-block { display: block; text-align: center; margin-top: 3mm; }
.kf-info-lite { display: block; margin-top: 2.8mm; padding-top: 2mm; border-top: 0.25mm solid #e5e5e5; }
.kf-info-row { display: block; margin-bottom: 1.8mm; }
.kf-info-row::after { content: ""; display: block; clear: both; }
.kf-info-cell { float: left; width: 48%; }
.kf-info-cell + .kf-info-cell { float: right; }
.kf-info-full { float: none; width: 100%; }
.kf-qr-lite { display: block; margin-top: 3mm; padding: 2mm 2.6mm; border: 0.3mm solid #d4af37; background: #ffffff; }
.kf-qr-box { float: left; width: 22mm; height: 22mm; margin-right: 3mm; padding: 1mm; background: #ffffff; }
.kf-qr-box svg, .kf-qr-box barcode { width: 20mm; height: 20mm; display: block; }
.kf-qr-text { margin-left: 26mm; }
.kf-qr-lite::after { content: ""; display: block; clear: both; }
.kf-foot-lite { display: block; margin-top: 2mm; padding-top: 1.5mm; border-top: 0.25mm solid #d4af37; font-size: 5.2pt; }
.kf-foot-l { float: left; width: 48%; text-align: left; }
.kf-foot-r { float: right; width: 50%; text-align: right; }
.kf-foot-lite::after { content: ""; display: block; clear: both; }
