/* SkillCraft SaaS v2.0 - Royal Precision Print & PDF Stylesheet (A4, A4-Wide, 3.3x2.2in, A5) */
@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,600;0,700;1,700&family=Inter:wght@400;500;600;700;800&family=Playfair+Display:ital,wght@0,700;0,800;1,700&display=swap');

* { box-sizing: border-box; }
body { margin: 0; background: #cbd5e1; color: #0f172a; font-family: 'Inter', system-ui, sans-serif; padding: 20px; }

.print-toolbar { max-width: 1080px; margin: 0 auto 20px; background: linear-gradient(135deg, #070b14, #0f295c); color: #fff; padding: 13px 20px; border-radius: 14px; display: flex; align-items: center; justify-content: space-between; gap: 12px; box-shadow: 0 14px 30px rgba(15,23,42,0.28); }
.print-toolbar .btn { padding: 9px 18px; border-radius: 9px; border: none; font-weight: 600; cursor: pointer; text-decoration: none; font-size: 0.87rem; display: inline-flex; align-items: center; gap: 6px; }
.btn-print { background: linear-gradient(135deg, #d97706, #b91c1c); color: #fff; }
.btn-back  { background: rgba(255,255,255,0.14); color: #fff; }

.sheet-a4 { width: 210mm; min-height: 297mm; margin: 0 auto; background: #fff; padding: 0; position: relative; overflow: hidden; box-shadow: 0 24px 60px rgba(15,23,42,0.28); }
.sheet-a4-landscape { width: 297mm; min-height: 210mm; margin: 0 auto; background: #fff; padding: 0; position: relative; overflow: hidden; box-shadow: 0 24px 60px rgba(15,23,42,0.28); }
.sheet-a5 { width: 148mm; min-height: 210mm; margin: 0 auto; background: #fff; padding: 0; position: relative; overflow: hidden; box-shadow: 0 24px 60px rgba(15,23,42,0.28); }

.royal-shell { position: relative; width: 100%; height: 100%; padding: 9mm 10mm; overflow: hidden; }
.royal-inner { position: relative; z-index: 2; width: 100%; height: 100%; border: 2px solid #cbd5e1; background: rgba(255,255,255,0.92); padding: 7mm 10mm; display: flex; flex-direction: column; justify-content: space-between; overflow: hidden; }
.tiled-watermark { position: absolute; inset: 0; z-index: 0; pointer-events: none; background-repeat: repeat; }
.center-crest-wm { position: absolute; inset: 0; z-index: 0; pointer-events: none; display: grid; place-items: center; }

.royal-script-title { font-family: 'Playfair Display', 'Cormorant Garamond', Georgia, serif; font-style: italic; font-weight: 800; line-height: 1.08; letter-spacing: 0.5px; }
.cert-line { font-size: 14.5px; line-height: 2.05; color: #1e3a8a; text-align: left; }
.cert-fill { display: inline-block; border-bottom: 1.5px dashed #1e40af; color: #0f172a; font-weight: 800; padding: 0 12px 1px; text-align: center; min-width: 120px; line-height: 1.25; }
.trust-pill { display: inline-flex; align-items: center; gap: 5px; padding: 4px 9px; border-radius: 6px; font-size: 9.5px; font-weight: 800; border: 1px solid #cbd5e1; background: #fff; color: #0f172a; }

.mks-table { width: 100%; border-collapse: collapse; margin: 10px 0; font-size: 12px; position: relative; z-index: 2; }
.mks-table th, .mks-table td { border: 1.2px solid #1e3a8a; padding: 6.5px 8px; }
.mks-table th { color: #fff; text-align: center; font-weight: 700; font-size: 11.5px; }
.mks-table tbody tr:nth-child(even) { background: rgba(239, 246, 255, 0.45); }

/* Exact ID Card Size: 3.3 inch wide x 2.2 inch height */
.id-card-stage { display: flex; justify-content: center; gap: 28px; flex-wrap: wrap; padding: 20px 0; }
.id-card { width: 3.3in; height: 2.2in; background: #fff; border-radius: 9px; overflow: hidden; box-shadow: 0 14px 32px rgba(15,23,42,0.22); border: 1px solid #cbd5e1; position: relative; display: flex; flex-direction: column; }
.qr-box { display: inline-block; background: #fff; padding: 4px; border: 1.5px solid #0f295c; border-radius: 6px; }

@media print {
    body { background: #fff; padding: 0; margin: 0; }
    .no-print { display: none !important; }
    .sheet-a4, .sheet-a4-landscape, .sheet-a5 { box-shadow: none; margin: 0; }
    .id-card-stage { display: block; padding: 0; gap: 0; }
    .id-card { box-shadow: none; border-radius: 0; border: none; break-inside: avoid; page-break-after: always; }
    .id-card:last-child { page-break-after: auto; }
    * { -webkit-print-color-adjust: exact !important; print-color-adjust: exact !important; }
}
