/* Halaman sertifikat: tampilan layar dan cetak A4 mendatar. */
.cert-page { max-width: 1040px; margin: 0 auto; padding: 28px 16px 60px; }
.cert-check { max-width: 520px; margin: 8vh auto 0; display: flex; flex-direction: column; gap: 14px; }
.cert-check form { flex-wrap: nowrap; }
.cert-actions { display: flex; justify-content: space-between; align-items: center; margin-bottom: 14px; gap: 12px; flex-wrap: wrap; }
.cert-valid { color: var(--accent-2); font-weight: 600; margin: 0 0 14px; }

.certificate {
  position: relative; overflow: hidden; aspect-ratio: 297 / 210; padding: 5.5% 7%;
  --text: #15171a; --muted: #5a5f66;
  background: #fbfaf5; color: #15171a; border-radius: 10px; display: flex; flex-direction: column; align-items: center; text-align: center;
  box-shadow: 0 20px 60px rgba(0, 0, 0, .35);
}
.certificate .cert-band { position: absolute; inset: 0 0 auto 0; height: 2.2%; background: linear-gradient(90deg, var(--accent-2), var(--accent)); }
.certificate::after { content: ''; position: absolute; inset: 3.2%; border: 2px solid color-mix(in srgb, var(--accent-2) 55%, transparent); border-radius: 6px; pointer-events: none; }
.certificate header { width: 100%; display: flex; justify-content: space-between; align-items: center; }
.certificate header .lockup { color: #15171a; }
.certificate header .lockup img:not([data-fixed]) { filter: invert(1) hue-rotate(180deg) saturate(1.4); }
.cert-org { font-weight: 700; letter-spacing: .04em; }
.cert-kicker { margin: 4% 0 0; font-size: clamp(14px, 2.4vw, 26px); font-weight: 800; letter-spacing: .28em; text-transform: uppercase; color: #0066CC; }
.cert-small { display: block; font-size: clamp(10px, 1.3vw, 14px); color: #5a5f66; }
.cert-name { margin: 1.2% 0; font-size: clamp(24px, 5vw, 54px); font-weight: 800; border-bottom: 2px solid #e2e0d5; padding: 0 4% 1%; }
.cert-title { margin: 1% 0 3%; font-size: clamp(14px, 2.4vw, 26px); font-weight: 600; max-width: 85%; }
.cert-scores { display: flex; gap: 6%; justify-content: center; width: 100%; }
.cert-scores div { display: flex; flex-direction: column; min-width: 18%; }
.cert-scores strong { font-size: clamp(16px, 2.6vw, 30px); color: #0066CC; }
.cert-scores span { font-size: clamp(10px, 1.2vw, 13px); color: #5a5f66; }
.certificate footer { margin-top: auto; width: 100%; display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 3%; align-items: end; font-size: clamp(10px, 1.3vw, 14px); }
.certificate footer > div { display: flex; flex-direction: column; gap: 2px; }
.certificate footer > div:first-child { text-align: left; }
.certificate footer > div:last-child { text-align: right; }
.cert-sign .line { display: block; height: 1px; background: #15171a; margin: 0 15% 4px; }
.cert-sign strong { border-bottom: 1px solid #15171a; padding-bottom: 2px; }
.verify { word-break: break-all; }
.certificate.revoked { filter: grayscale(1); opacity: .75; }
.cert-void { position: absolute; top: 45%; left: 50%; transform: translate(-50%, -50%) rotate(-18deg); font-size: clamp(40px, 9vw, 110px); font-weight: 900; color: rgba(200, 30, 30, .35); border: 6px solid rgba(200, 30, 30, .35); padding: 0 4%; }

@media print {
  @page { size: A4 landscape; margin: 0; }
  body { background: #fff; }
  .no-print { display: none !important; }
  .cert-page { max-width: none; padding: 0; }
  .certificate { width: 297mm; height: 210mm; aspect-ratio: auto; border-radius: 0; box-shadow: none; -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}
