@font-face {
  font-family: 'Certificate Signature';
  src: url('/certificate-signature.ttf') format('truetype');
  font-style: normal;
  font-weight: 400;
  font-display: block;
}
.certificates-page { max-width: 1300px; }
.certificate-toolbar { display: flex; align-items: end; gap: 16px; margin-bottom: 16px; }
.certificate-toolbar label { flex: 1; }
.certificate-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; margin: 20px 0; }
.certificate-actions label, .certificate-name { display: flex; align-items: center; gap: 10px; }
.certificate-actions input, .certificate-name input { width: 19px; height: 19px; flex-shrink: 0; }
.certificate-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 360px), 1fr)); gap: 20px; }
.certificate-card { min-width: 0; border: 1px solid #5b7f92; border-radius: 8px; padding: 14px; background: #1d3544; }
.certificate-name { font-weight: 700; font-size: 18px; margin-bottom: 14px; color: #ffcf62; }
.certificate-thumbnail { display: block; width: 100%; padding: 0; background: white; color: #133c54; border: 0; cursor: pointer; }
.certificate-thumbnail img { width: 100%; height: auto; display: block; }
.certificate-thumbnail img[hidden] { display: none; }
.certificate-thumbnail span { display: block; padding: 8px; }
.certificate-card .actionrow { margin-top: 12px; display: flex; flex-wrap: wrap; gap: 8px; }
.certificate-preview { width: min(1200px, 95vw); max-width: 95vw; max-height: 95vh; overflow: auto; background: #1d3544; color: #eef7fc; border: 1px solid #6e98ac; padding: 16px; }
.certificate-preview::backdrop { background: #000b; }
.certificate-preview .actionrow { display: flex; justify-content: space-between; align-items: center; gap: 12px; }
.certificate-preview img { display: block; width: 100%; height: auto; }
.certificate-print-frame { position: fixed; width: 1px; height: 1px; bottom: 0; left: 0; border: 0; }
@media (max-width: 600px) { .certificate-toolbar { align-items: stretch; flex-direction: column; } .certificate-actions .btn { width: 100%; } }
