/* ACAPRS Research Manager 2.5.0 — academy-style cards. */
:root { --acaprs-purple: #4B2C5F; --acaprs-gold: #EFD9A4; }
.acaprs-rm25-dashboard { max-width: 1100px; margin: 0 auto; }
.acaprs-rm25-stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-bottom: 20px; }
.acaprs-rm25-stat { background: #fff; border: 1px solid #e5e0ea; border-top: 4px solid var(--acaprs-purple); border-radius: 16px; padding: 16px; text-align: center; }
.acaprs-rm25-stat strong { display: block; font-size: 28px; color: var(--acaprs-purple); }
.acaprs-rm25-tabs { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 20px; }
.acaprs-rm-tab-btn { display: inline-block; padding: 10px 18px; border-radius: 999px; border: 1px solid var(--acaprs-purple); color: var(--acaprs-purple); text-decoration: none; }
.acaprs-rm-tab-btn.active { background: var(--acaprs-purple); color: #fff; }
.acaprs-rm25-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 16px; }
.acaprs-rm25-card { background: #fff; border: 1px solid #e5e0ea; border-top: 4px solid var(--acaprs-purple); border-radius: 16px; padding: 18px; box-shadow: 0 2px 8px rgba(75,44,95,.08); }
.acaprs-rm25-card h3 { margin-top: 0; }
.acaprs-rm25-form label { display: block; margin-bottom: 12px; font-weight: 600; }
.acaprs-rm25-form input[type="text"], .acaprs-rm25-form input[type="email"], .acaprs-rm25-form input[type="tel"], .acaprs-rm25-form input[type="password"], .acaprs-rm25-form select, .acaprs-rm25-form textarea { display: block; width: 100%; margin-top: 6px; padding: 10px; border: 1px solid #ccc; border-radius: 8px; box-sizing: border-box; }
.acaprs-rm25-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.acaprs-rm25-btn { background: var(--acaprs-purple); color: #fff; border: 0; border-radius: 999px; padding: 12px 26px; cursor: pointer; }
.acaprs-rm25-error { background: #fdecea; border: 1px solid #e57373; border-radius: 12px; padding: 12px 16px; }
.acaprs-rm25-success { background: #e8f5e9; border: 1px solid #81c784; border-radius: 12px; padding: 12px 16px; }
.acaprs-rm25-progress { height: 10px; background: #eee; border-radius: 999px; overflow: hidden; }
.acaprs-rm25-progress div { height: 100%; background: var(--acaprs-purple); }
.acaprs-rm25-stages { list-style: none; padding: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.acaprs-rm25-stages li { padding: 4px 10px; border-radius: 999px; background: #f0edf3; font-size: 13px; }
.acaprs-rm25-stages li.done { background: var(--acaprs-gold); }
.acaprs-rm25-badge-red { background: #c62828; color: #fff; padding: 4px 12px; border-radius: 999px; }
.acaprs-rm25-certificate { border: 3px double var(--acaprs-purple); border-radius: 16px; padding: 32px; text-align: center; background: #fff; }
.acaprs-rm25-cert-sign { display: flex; justify-content: space-around; margin-top: 24px; }
.acaprs-rm25-hint { color: #666; font-size: 13px; }
/* RTL in Arabic, LTR in English — driven by html[dir]. */
html[dir="rtl"] .acaprs-rm25-dashboard { direction: rtl; text-align: right; }
html[dir="ltr"] .acaprs-rm25-dashboard { direction: ltr; text-align: left; }
@media (max-width: 600px) {
  .acaprs-rm25-stats { grid-template-columns: 1fr; }
  .acaprs-rm25-row { grid-template-columns: 1fr; }
  .acaprs-rm25-cards { grid-template-columns: 1fr; }
}

/* 2.5.1 — author repeater + distinguished bilingual certificate (print to PDF). */
.acaprs-rm25-authors { border: 1px solid #EFD9A4; border-radius: 16px; padding: 16px; margin: 16px 0; background: #fff; }
.acaprs-rm25-author-row { border-top: 1px solid #eee; padding-top: 12px; margin-top: 12px; }
.acaprs-rm25-author-row:first-child { border-top: none; margin-top: 0; padding-top: 0; }
.acaprs-rm25-author-title { font-weight: 700; color: #4B2C5F; }
.acaprs-rm25-remove-author { background: transparent; border: none; color: #8a2b2b; cursor: pointer; text-decoration: underline; }
/* Certificate print view — A4 LANDSCAPE (owner's binding rule: scientific
   certificates are landscape, عرضي). On-screen preview uses the same
   landscape proportions (wide container, generous side margins) so the
   preview matches the printed page. */
.acaprs-rm25-certificate-print { max-width: 1020px; margin: 0 auto; font-family: Cairo, "Segoe UI", Tahoma, sans-serif; }
.acaprs-rm25-cert-frame { border: 3px double #4B2C5F; outline: 1px solid #EFD9A4; outline-offset: 6px; padding: 36px 64px; background: #fff; text-align: center; line-height: 1.9; box-sizing: border-box; }
.acaprs-rm25-cert-journal-en { color: #4B2C5F; font-weight: 800; letter-spacing: 2px; margin: 0; }
.acaprs-rm25-cert-journal-ar { color: #4B2C5F; font-weight: 800; font-size: 1.3em; margin: 0; }
.acaprs-rm25-cert-sub { color: #666; margin: 0 0 4px; }
.acaprs-rm25-cert-title { color: #4B2C5F; border-top: 2px solid #EFD9A4; border-bottom: 2px solid #EFD9A4; padding: 8px 0; margin: 20px 0 4px; }
.acaprs-rm25-cert-title-en { color: #4B2C5F; margin: 0 0 16px; }
.acaprs-rm25-cert-ref { font-weight: 700; }
.acaprs-rm25-cert-paper { font-size: 1.1em; margin: 16px 0; }
.acaprs-rm25-cert-coauthors-list { text-align: right; display: inline-block; }
.acaprs-rm25-cert-sign { display: flex; justify-content: space-between; align-items: flex-end; gap: 32px; margin-top: 28px; border-top: 1px solid #EFD9A4; padding-top: 16px; }
.acaprs-rm25-cert-sign-block, .acaprs-rm25-cert-stamp-block { flex: 1 1 0; text-align: center; }
.acaprs-rm25-cert-sign img { max-height: 90px; }
.acaprs-rm25-cert-download { font-size: 17px; font-weight: 800; padding: 14px 34px; margin-top: 22px; }
@media print {
  .acaprs-rm25-no-print, .acaprs-rm25-btn { display: none !important; }
  .acaprs-rm25-certificate-print { max-width: none; width: 100%; }
  .acaprs-rm25-cert-frame { border: 3px double #4B2C5F; padding: 10mm 18mm; page-break-inside: avoid; }
  @page { size: A4 landscape; margin: 8mm; }
}

/* 2.5.1 visual fixes (live audit of 2.5.0) — no functional change. Statistics cards untouched. */
/* (a) Tab bar: own background/separator, wider gaps, larger buttons, so six tabs stop floating on plain background. */
.acaprs-rm25-tabs { gap: 14px; background: #f0edf3; border-bottom: 3px solid #EFD9A4; border-radius: 12px 12px 0 0; padding: 12px 14px; }
.acaprs-rm-tab-btn { padding: 14px 24px; font-weight: 700; background: #fff; }
.acaprs-rm-tab-btn.active { background: #4B2C5F; color: #fff; border-color: #4B2C5F; }
/* (b) File-upload rows: label ABOVE the file control (required * stays with the label text), generous row spacing. */
.acaprs-rm25-form input[type="file"] { display: block; margin-top: 8px; }
.acaprs-rm25-uploads label { margin-bottom: 22px; }
/* (c) Profile photo row: same label-above treatment (covered by the file-input rule above). */
.acaprs-rm25-form label input[type="file"] { margin-top: 8px; }
/* (d) Support form: constrained width instead of full-page stretch; related-submission select gap normalised. */
.acaprs-rm25-form-narrow { max-width: 640px; }
.acaprs-rm25-form-narrow label { margin-bottom: 16px; }
.acaprs-rm25-form-narrow select { display: block; width: 100%; margin-top: 6px; }
/* Dated journal stamp: relative container, certificate date overlaid centred on the stamp's lower DATE zone. */
.acaprs-rm25-cert-stamp { position: relative; display: inline-block; line-height: 0; }
.acaprs-rm25-cert-stamp img { width: 150px; max-width: 150px; max-height: none; height: auto; }
.acaprs-rm25-cert-stamp-date { position: absolute; left: 50%; bottom: 12%; transform: translateX(-50%); color: #4B2C5F; font-weight: 800; font-size: 13px; line-height: 1; white-space: nowrap; -webkit-print-color-adjust: exact; print-color-adjust: exact; }

/* 2.5.4 — status chips, compact cards, rows, pagination, chat, profiles, print. */
.acaprs-rm25-chip { display: inline-block; padding: 4px 12px; border-radius: 999px; font-size: 13px; font-weight: 700; }
.acaprs-rm25-chip.chip-type { background: #EFD9A4; color: #4B2C5F; }
.acaprs-rm25-chip.chip-open { background: #e3f2fd; color: #1565c0; }
.acaprs-rm25-chip.chip-answered { background: #e8f5e9; color: #2e7d32; }
.acaprs-rm25-chip.chip-closed { background: #f0edf3; color: #555; }
.acaprs-rm25-chip.chip-rejected { background: #c62828; color: #fff; }
.acaprs-rm25-stages li.current { background: #4B2C5F; color: #fff; font-weight: 700; }
.acaprs-rm25-stages li.upcoming { background: #f0edf3; color: #888; }
.acaprs-rm25-card-compact { font-size: 14px; padding: 14px 16px; }
.acaprs-rm25-card-compact h3 { font-size: 15px; margin-bottom: 6px; }
.acaprs-rm25-view-toggle { display: flex; gap: 8px; margin: 12px 0; }
.acaprs-rm25-view-toggle a { padding: 8px 18px; border-radius: 999px; border: 1px solid #4B2C5F; color: #4B2C5F; text-decoration: none; font-weight: 700; }
.acaprs-rm25-view-toggle a.active { background: #4B2C5F; color: #fff; }
.acaprs-rm25-row-item { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; align-items: center; padding: 14px 4px; border-bottom: 1px solid #e5e0ea; font-size: 14px; }
.acaprs-rm25-row-item h3 { font-size: 15px; margin: 0 0 4px; }
.acaprs-rm25-row-meta { color: #555; margin: 0; }
.acaprs-rm25-row-actions { margin: 0; white-space: nowrap; }
.acaprs-rm25-perpage { margin: 14px 0 6px; font-size: 14px; }
.acaprs-rm25-perpage select { padding: 6px 10px; border-radius: 8px; }
.acaprs-rm25-pager { display: flex; flex-wrap: wrap; gap: 8px; margin: 10px 0 20px; font-size: 14px; }
.acaprs-rm25-pager a { padding: 6px 12px; border: 1px solid #4B2C5F; border-radius: 999px; color: #4B2C5F; text-decoration: none; }
.acaprs-rm25-pager strong { padding: 6px 12px; background: #4B2C5F; color: #fff; border-radius: 999px; }
.acaprs-rm25-photo-center { text-align: center; margin: 12px 0 18px; }
.acaprs-rm25-photo-center img { width: 140px; height: 140px; object-fit: cover; border-radius: 50%; border: 3px solid #EFD9A4; }
.acaprs-rm25-member-box { background: #f8f5fb; border: 1px solid #EFD9A4; border-radius: 12px; padding: 12px 16px; margin-bottom: 16px; font-size: 14px; }
.acaprs-rm25-copy-btn { padding: 6px 16px; font-size: 13px; }
.acaprs-rm25-chat { display: flex; flex-direction: column; gap: 10px; margin-top: 12px; }
.acaprs-rm25-bubble { max-width: 85%; padding: 10px 14px; border-radius: 14px; font-size: 14px; }
.acaprs-rm25-bubble p { margin: 0; }
.acaprs-rm25-bubble-meta { font-size: 12px; color: #666; margin-bottom: 4px !important; }
.acaprs-rm25-bubble.bubble-sender { background: #f0edf3; align-self: flex-start; border-bottom-right-radius: 4px; }
.acaprs-rm25-bubble.bubble-reply { background: #4B2C5F; color: #fff; align-self: flex-end; border-bottom-left-radius: 4px; }
.acaprs-rm25-bubble.bubble-reply .acaprs-rm25-bubble-meta { color: #EFD9A4; }
.acaprs-rm25-public-profile { max-width: 760px; margin: 0 auto; padding: 24px 16px; text-align: center; font-family: Cairo, "Segoe UI", Tahoma, sans-serif; }
.acaprs-rm25-public-profile h1 { color: #4B2C5F; margin-bottom: 4px; }
.acaprs-rm25-public-no { color: #888; letter-spacing: 1px; }
.acaprs-rm25-public-profile .acaprs-rm25-cards { text-align: right; }
.acaprs-rm25-cert-logo { max-height: 80px; max-width: 260px; height: auto; margin-bottom: 8px; }
/* Clean print: dashboard pages print content only; certificate pages print
   ONLY the certificate frame at A4 landscape. */
@media print {
  body.acaprs-rm25-dashboard-page header, body.acaprs-rm25-dashboard-page footer, body.acaprs-rm25-dashboard-page nav,
  body.acaprs-rm25-dashboard-page .site-header, body.acaprs-rm25-dashboard-page .site-footer, body.acaprs-rm25-dashboard-page .main-navigation,
  body.acaprs-rm25-dashboard-page .acaprs-rm25-tabs, body.acaprs-rm25-dashboard-page .acaprs-rm25-stats,
  body.acaprs-rm25-dashboard-page .acaprs-rm25-no-print, body.acaprs-rm25-dashboard-page .acaprs-rm25-view-toggle,
  body.acaprs-rm25-dashboard-page .acaprs-rm25-perpage, body.acaprs-rm25-dashboard-page .acaprs-rm25-pager { display: none !important; }
  /* 2.5.6.8 — the stale .acaprs-rm25-panel-content selector never existed
     in the markup (panels are .acaprs-rm25-tab-panel, see the dashboard
     render): the old rules hid everything on a certificate print page,
     including the certificate itself. Corrected to .acaprs-rm25-tab-panel,
     Page 2 is gone in 2.5.6.22 (the certificate is one page), so no
     page-2 exemption remains. */
  body.acaprs-rm25-cert-page .acaprs-rm25-dashboard > *:not(.acaprs-rm25-tab-panel) { display: none !important; }
  /* 2.5.6.8 (item 8) — .acaprs-rm25-cert-dual is the new direct child of
     the tab panel (it wraps the two language versions); exempt it like
     the certificate itself, or the certificate would never print. The
     hidden language version inside stays hidden via the
     .acaprs-rm25-cert-lang[hidden] rule below. */
  body.acaprs-rm25-cert-page .acaprs-rm25-tab-panel > *:not(.acaprs-rm25-certificate-print):not(.acaprs-rm25-cert-dual) { display: none !important; }
  .acaprs-rm25-certificate-print { max-width: none; width: 100%; }
  .acaprs-rm25-cert-frame { page-break-inside: avoid; }
  @page { size: A4 landscape; margin: 8mm; }
}

/* 2.5.5 — publication grade, no-reload tabs, tracking cards, certificate
   landscape polish, ORCID-style public profile, support full width. */
/* Submit / profile save buttons never touch the frame above them. */
.acaprs-rm25-form .acaprs-rm25-submit-btn { margin-top: 32px; }
.acaprs-rm25-uploads { margin-bottom: 32px; }
/* No-reload tab panels: only the active panel is visible (JS toggles). */
.acaprs-rm25-tab-panel { animation: none; }
/* Tracking vertical cards (no rows view on tracking by design). */
.acaprs-rm25-track-cards { display: grid; grid-template-columns: 1fr; gap: 18px; }
.acaprs-rm25-track-card { background: #fff; border: 1px solid #e5e0ea; border-top: 4px solid #4B2C5F; border-radius: 16px; padding: 20px 22px; box-shadow: 0 2px 8px rgba(75,44,95,.08); }
.acaprs-rm25-track-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; }
.acaprs-rm25-track-head h3 { margin: 0; color: #4B2C5F; font-size: 17px; line-height: 1.6; }
.acaprs-rm25-track-head .acaprs-rm25-chip { flex-shrink: 0; }
.acaprs-rm25-track-meta { color: #666; font-size: 13px; margin: 8px 0 12px; }
.acaprs-rm25-track-card .acaprs-rm25-panel { background: #f8f5fb; border: 1px solid #eee6f3; border-radius: 12px; padding: 12px 16px; margin-top: 14px; }
.acaprs-rm25-track-card .acaprs-rm25-panel h4 { margin: 0 0 6px; color: #4B2C5F; }
.acaprs-rm25-track-card .acaprs-rm25-form { margin-top: 16px; }
/* Certificate landscape polish: balanced header, breathing room, one baseline for sign + stamp. */
.acaprs-rm25-cert-frame { padding: 40px 72px; line-height: 2.0; }
.acaprs-rm25-cert-logo { max-height: 76px; max-width: 280px; height: auto; margin: 0 auto 10px; display: block; }
.acaprs-rm25-cert-sign { align-items: flex-end; border-top: 2px solid #EFD9A4; padding-top: 20px; margin-top: 32px; }
.acaprs-rm25-cert-paper { font-size: 1.15em; margin: 18px 0; }
/* Support: full-width form (narrow constraint removed for support only). */
.acaprs-rm25-form.acaprs-rm25-support-form { max-width: none; width: 100%; }
/* My tickets: own separated section inside the Support tab. */
.acaprs-rm25-my-tickets { margin-top: 32px; padding-top: 22px; border-top: 2px solid #EFD9A4; }
.acaprs-rm25-my-tickets-title { margin: 0 0 16px; color: #4B2C5F; }
/* Public profile (ORCID-style): full site width, small equal side margins, RTL. */
.acaprs-rm25-public-profile { max-width: 1100px; margin: 0 auto; padding: 24px 16px; text-align: right; box-sizing: border-box; }
.acaprs-rm25-pp-identity { display: flex; gap: 24px; align-items: flex-start; background: #fff; border: 1px solid #e5e0ea; border-top: 4px solid #4B2C5F; border-radius: 16px; padding: 24px; box-shadow: 0 2px 8px rgba(75,44,95,.08); }
.acaprs-rm25-pp-photo img { width: 140px; height: 140px; object-fit: cover; border-radius: 50%; border: 3px solid #EFD9A4; }
.acaprs-rm25-pp-initial { width: 140px; height: 140px; border-radius: 50%; border: 3px solid #EFD9A4; background: #4B2C5F; color: #fff; display: flex; align-items: center; justify-content: center; font-size: 56px; font-weight: 800; flex-shrink: 0; }
.acaprs-rm25-pp-details h1 { margin: 0 0 4px; color: #4B2C5F; }
.acaprs-rm25-pp-details p { margin: 6px 0; }
.acaprs-rm25-pp-bio { background: #fff; border: 1px solid #e5e0ea; border-radius: 16px; padding: 18px 22px; margin-top: 18px; }
.acaprs-rm25-pp-bio h2, .acaprs-rm25-public-profile > h2 { color: #4B2C5F; }
@media (max-width: 600px) {
  .acaprs-rm25-pp-identity { flex-direction: column; align-items: center; text-align: center; }
  .acaprs-rm25-cert-frame { padding: 24px 20px; }
  .acaprs-rm25-track-head { flex-direction: column; }
}

/* 2.5.6 — screenshot-matched tracking, 3-per-row cards, cert page 2, profile. */
/* (A) Stats: colored numbers — total blue, pending gold, accepted green, published blue. */
.acaprs-rm25-stat:nth-child(1) strong { color: #1D6FA5; }
.acaprs-rm25-stat:nth-child(2) strong { color: #C9A24B; }
.acaprs-rm25-stat:nth-child(3) strong { color: #16A34A; }
.acaprs-rm25-stat:nth-child(4) strong { color: #1D6FA5; }
/* (A) Tracking card: 3 info boxes + green/grey stage pills + RTL timeline. */
.acaprs-rm25-track-card { background: #fff; border: 1px solid #e5e0ea; border-top: 4px solid #4B2C5F; border-radius: 16px; padding: 20px; margin-bottom: 20px; box-shadow: 0 2px 8px rgba(75,44,95,.08); }
.acaprs-rm25-track-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; }
.acaprs-rm25-track-head h3 { margin: 0; }
.acaprs-rm25-chip.chip-pending { background: #EFD9A4; color: #4B2C5F; }
.acaprs-rm25-track-info { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin: 16px 0; }
.acaprs-rm25-track-box { background: #f7f5f9; border-radius: 10px; padding: 10px 14px; text-align: center; }
.acaprs-rm25-track-box span { display: block; font-size: 12px; color: #888; }
.acaprs-rm25-track-box strong { display: block; margin-top: 2px; }
.acaprs-rm25-stage-pills li.reached { background: #16A34A; color: #fff; font-weight: 700; }
.acaprs-rm25-stage-pills li.upcoming { background: #eee; color: #888; }
.acaprs-rm25-timeline2 { list-style: none; margin: 0; padding: 0; position: relative; }
.acaprs-rm25-timeline2::before { content: ""; position: absolute; top: 8px; bottom: 8px; inset-inline-start: 9px; width: 2px; background: #ddd; }
.acaprs-rm25-tl-item { position: relative; padding-inline-start: 32px; margin-bottom: 16px; }
.acaprs-rm25-tl-dot { position: absolute; inset-inline-start: 2px; top: 6px; width: 16px; height: 16px; border-radius: 50%; border: 3px solid #fff; box-shadow: 0 0 0 1px #ddd; }
.acaprs-rm25-tl-item.newest .acaprs-rm25-tl-dot { background: #C9A24B; }
.acaprs-rm25-tl-item.older .acaprs-rm25-tl-dot { background: #999; }
.acaprs-rm25-tl-card { background: #f7f5f9; border-radius: 12px; padding: 12px 16px; }
.acaprs-rm25-tl-head { margin: 0 0 6px; display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.acaprs-rm25-tl-note { background: #fff; border: 1px solid #EFD9A4; border-inline-start: 4px solid #C9A24B; border-radius: 8px; padding: 8px 12px; margin: 0; }
/* (B) 3-per-row card grid (desktop 3, tablet 2, mobile 1); centered gold titles. */
.acaprs-rm25-grid3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.acaprs-rm25-grid3.acaprs-rm25-view-rows { grid-template-columns: 1fr; }
.acaprs-rm25-card3 { text-align: center; }
.acaprs-rm25-card3 h3 { color: #C9A24B; font-size: 16px; line-height: 1.5; }
.acaprs-rm25-card3 h3 a { color: #C9A24B; text-decoration: none; }
.acaprs-rm25-card3 .acaprs-rm25-card-date, .acaprs-rm25-card3 .acaprs-rm25-card-doi { text-align: center; }
.acaprs-rm25-view-rows .acaprs-rm25-card3 { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 20px; text-align: start; }
.acaprs-rm25-view-rows .acaprs-rm25-card3 h3 { flex: 1 1 280px; text-align: start; }
.acaprs-rm25-view-toggle button { padding: 8px 18px; border-radius: 999px; border: 1px solid #4B2C5F; color: #4B2C5F; background: #fff; font-weight: 700; cursor: pointer; }
.acaprs-rm25-view-toggle button.active { background: #4B2C5F; color: #fff; }
@media (max-width: 1024px) { .acaprs-rm25-grid3 { grid-template-columns: repeat(2, 1fr); } .acaprs-rm25-track-info { grid-template-columns: 1fr 1fr; } }
@media (max-width: 600px) { .acaprs-rm25-grid3 { grid-template-columns: 1fr; } .acaprs-rm25-track-info { grid-template-columns: 1fr; } .acaprs-rm25-track-head { flex-direction: column; } }
/* (C) Certificate: 2.5.6.22 — the stacked bottom (stamp block, signature
   beneath, verify box) and page 2 are deleted; see the bottom-row rules
   below (.acaprs-rm25-cert-bottom-row). */
.acaprs-rm25-cert-verify { font-size: 13px; text-align: center; }
/* (E) Certificate verification page (2.5.6.4) — academy classic look:
   purple frame, gold outline, paper card, Cairo, RTL, centered. */
.acaprs-rm25-cert-verify-page { max-width: 780px; margin: 0 auto; padding: 24px 16px; line-height: 1.9; font-family: "Cairo", "Segoe UI", Tahoma, sans-serif; text-align: center; color: #23272F; }
.acaprs-rm25-verify-frame { background: linear-gradient(135deg, #4B2C5F 0%, #2E1A3C 100%); border-radius: 20px; padding: clamp(10px, 1.8vw, 18px); box-shadow: 0 24px 60px rgba(46, 26, 60, .30); }
.acaprs-rm25-verify-card { background: radial-gradient(ellipse at 50% 0%, #F3EDF7 0%, transparent 55%), #FFFDF6; border: 2px solid #EFD9A4; outline: 1px solid #C9A24B; outline-offset: 5px; border-radius: 10px; padding: clamp(26px, 4.5vw, 48px) clamp(20px, 5vw, 56px); }
.acaprs-rm25-verify-eyebrow { color: #C9A24B; font-weight: 800; font-size: .92rem; margin: 0 0 6px; letter-spacing: .5px; }
.acaprs-rm25-cert-verify-page h1 { color: #4B2C5F; font-size: clamp(1.5rem, 3.2vw, 2.1rem); font-weight: 900; margin: 0 0 16px; }
.acaprs-rm25-verify-badge { display: inline-block; font-weight: 800; font-size: 1.05rem; border-radius: 999px; padding: 9px 26px; margin: 4px 0 20px; }
.acaprs-rm25-verify-badge.is-valid { background: #E8F7EE; color: #157347; border: 1.5px solid #16A34A; }
.acaprs-rm25-verify-badge.is-invalid { background: #FEF3F2; color: #B42318; border: 1.5px solid #E57373; }
.acaprs-rm25-verify-details { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin: 6px 0 8px; text-align: start; }
.acaprs-rm25-verify-detail { background: #F3EDF7; border-top: 3px solid #4B2C5F; border-radius: 12px; padding: 14px 16px; margin: 0; min-width: 0; }
.acaprs-rm25-verify-detail.is-wide { grid-column: 1 / -1; }
.acaprs-rm25-verify-detail dt { color: #6B7280; font-size: .85rem; font-weight: 700; }
.acaprs-rm25-verify-detail dd { margin: 2px 0 0; color: #23272F; font-size: 1.1rem; font-weight: 800; overflow-wrap: anywhere; }
.acaprs-rm25-verify-ref { font-family: "Courier New", monospace; letter-spacing: 1px; color: #4B2C5F; }
.acaprs-rm25-verify-types-label { color: #6B7280; font-weight: 700; margin: 18px 0 8px; }
.acaprs-rm25-verify-types { list-style: none; margin: 0 0 8px; padding: 0; display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; }
.acaprs-rm25-verify-types li { background: #F3EDF7; border: 1px solid #EFD9A4; color: #4B2C5F; font-weight: 800; border-radius: 999px; padding: 7px 18px; }
.acaprs-rm25-verify-doi { margin: 16px 0 4px; overflow-wrap: anywhere; }
.acaprs-rm25-verify-doi a { font-family: "Courier New", monospace; font-weight: 700; color: #4B2C5F; }
.acaprs-rm25-verify-actions { margin: 20px 0 6px; }
.acaprs-rm25-verify-btn { display: inline-block; background: #4B2C5F; color: #fff !important; font-weight: 800; font-size: .95rem; border: 0; border-radius: 999px; padding: 11px 28px; cursor: pointer; text-decoration: none; font-family: inherit; }
.acaprs-rm25-verify-btn:hover { background: #2E1A3C; }
.acaprs-rm25-verify-form { margin: 18px 0 0; display: flex; flex-wrap: wrap; gap: 10px; align-items: center; justify-content: center; border-top: 1px dashed #D9CFE2; padding-top: 18px; }
.acaprs-rm25-verify-form label { font-weight: 700; color: #4B2C5F; display: flex; flex-wrap: wrap; gap: 10px; align-items: center; justify-content: center; }
.acaprs-rm25-verify-form input[type="text"] { font-family: "Courier New", monospace; font-weight: 700; font-size: 1rem; letter-spacing: 1px; color: #23272F; border: 2px solid #EFD9A4; border-radius: 999px; padding: 9px 18px; min-width: 200px; background: #fff; }
.acaprs-rm25-verify-form input[type="text"]:focus { outline: none; border-color: #4B2C5F; }
@media (max-width: 640px) { .acaprs-rm25-verify-details { grid-template-columns: 1fr; } .acaprs-rm25-verify-form { flex-direction: column; } }
@media print { .acaprs-rm25-verify-frame { box-shadow: none; padding: 10px; border-radius: 12px; } .acaprs-rm25-verify-form, .acaprs-rm25-verify-actions { display: none !important; } }
/* (D) Profile form sections + public profile width. */
.acaprs-rm25-profile-form .acaprs-rm25-form-section { border: 1px solid #e5e0ea; border-radius: 16px; padding: 18px; margin-bottom: 20px; background: #fff; }
.acaprs-rm25-profile-form .acaprs-rm25-form-section legend { font-weight: 800; color: #4B2C5F; padding: 0 8px; }
.acaprs-rm25-profile-form .acaprs-rm25-row { gap: 18px; }
.acaprs-rm25-public-profile { max-width: 1100px; margin: 0 auto; padding: 0 16px; }
.acaprs-rm25-pp-identity { display: flex; gap: 20px; align-items: flex-start; background: #fff; border: 1px solid #e5e0ea; border-top: 4px solid #4B2C5F; border-radius: 16px; padding: 20px; margin-bottom: 20px; }
/* 2.5.6.22 — page 2 is deleted; the rule above it is gone with it. */

/* 2.5.6.5 — Published tab: cards + rows polish (presentation only).
   All rules are scoped to .acaprs-rm25-published-list so the certificates
   tab and the public profile, which reuse .acaprs-rm25-grid3 /
   .acaprs-rm25-card3, keep their 2.5.6 look. Principles applied:
   - one clear hierarchy: type badge (eyebrow) -> centred gold title ->
     muted DOI -> muted meta -> stat strip -> actions;
   - centred Arabic text stays centred (cards); rows align to the start;
   - equal-height cards with actions pinned to the bottom (margin-top:auto);
   - calm hover lift on cards only; rows get a quiet background hover;
   - grid stays 3 / 2 / 1 (desktop / tablet / mobile) per the 2.5.6 rules. */
.acaprs-rm25-published-list.acaprs-rm25-grid3 { gap: 20px; }
.acaprs-rm25-published-list .acaprs-rm25-card3 { display: flex; flex-direction: column; text-align: center; padding: 22px 20px; transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease; }
.acaprs-rm25-published-list .acaprs-rm25-card3:hover { transform: translateY(-3px); box-shadow: 0 10px 24px rgba(75,44,95,.14); border-color: #d9cfe2; }
.acaprs-rm25-published-list .acaprs-rm25-card3-head { display: flex; flex-direction: column; align-items: center; gap: 10px; margin-bottom: 10px; }
.acaprs-rm25-published-list .acaprs-rm25-card3 h3 { color: #C9A24B; font-size: 18px; font-weight: 800; line-height: 1.6; margin: 0; }
.acaprs-rm25-published-list .acaprs-rm25-card-doi { margin: 0 0 8px; font-size: 13px; color: #6B7280; overflow-wrap: anywhere; }
.acaprs-rm25-published-list .acaprs-rm25-card-doi a { color: #4B2C5F; font-weight: 700; text-decoration: none; }
.acaprs-rm25-published-list .acaprs-rm25-card-doi a:hover { text-decoration: underline; }
.acaprs-rm25-published-list .acaprs-rm25-card-meta { margin: 0 0 14px; font-size: 13px; color: #6B7280; }
.acaprs-rm25-published-list .acaprs-rm25-card-stats { display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid #eee6f3; border-bottom: 1px solid #eee6f3; padding: 10px 0; margin: 0 0 16px; }
.acaprs-rm25-published-list .acaprs-rm25-card-stats > div { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.acaprs-rm25-published-list .acaprs-rm25-card-stats > div + div { border-inline-start: 1px solid #eee6f3; }
.acaprs-rm25-published-list .acaprs-rm25-card-stats strong { font-size: 18px; font-weight: 800; color: #4B2C5F; line-height: 1.2; }
.acaprs-rm25-published-list .acaprs-rm25-card-stats span { font-size: 12px; color: #888; }
.acaprs-rm25-published-list .acaprs-rm25-card-links { margin: auto 0 0; display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 8px 16px; font-size: 13px; }
.acaprs-rm25-published-list .acaprs-rm25-card-links a:not(.acaprs-rm25-btn) { color: #4B2C5F; text-decoration: none; font-weight: 700; }
.acaprs-rm25-published-list .acaprs-rm25-card-links a:not(.acaprs-rm25-btn):hover { text-decoration: underline; }
.acaprs-rm25-published-list .acaprs-rm25-card-btn { display: inline-block; padding: 10px 22px; font-size: 14px; text-decoration: none; }
/* Empty state: polite dashed panel instead of a bare paragraph. */
.acaprs-rm25-empty { text-align: center; color: #6B7280; background: #faf8fc; border: 1px dashed #d9cfe2; border-radius: 16px; padding: 28px 20px; margin: 12px 0; }
/* Rows: one bordered list with fixed columns, light separators, calm hover. */
.acaprs-rm25-published-list.acaprs-rm25-view-rows { gap: 0; background: #fff; border: 1px solid #e5e0ea; border-radius: 16px; overflow: hidden; }
.acaprs-rm25-published-list.acaprs-rm25-view-rows .acaprs-rm25-card3 { display: grid; grid-template-columns: minmax(0, 1fr) 200px 168px; grid-template-areas: "head stats actions" "doi stats actions" "meta stats actions"; column-gap: 24px; row-gap: 2px; align-items: center; text-align: start; padding: 16px 20px; border: 0; border-radius: 0; box-shadow: none; border-bottom: 1px solid #eee6f3; }
.acaprs-rm25-published-list.acaprs-rm25-view-rows .acaprs-rm25-card3:last-child { border-bottom: 0; }
.acaprs-rm25-published-list.acaprs-rm25-view-rows .acaprs-rm25-card3:hover { transform: none; box-shadow: none; background: #faf8fc; border-color: #eee6f3; }
.acaprs-rm25-published-list.acaprs-rm25-view-rows .acaprs-rm25-card3-head { grid-area: head; align-items: flex-start; margin-bottom: 0; text-align: start; }
.acaprs-rm25-published-list.acaprs-rm25-view-rows .acaprs-rm25-card3 h3 { text-align: start; font-size: 17px; }
.acaprs-rm25-published-list.acaprs-rm25-view-rows .acaprs-rm25-card-doi { grid-area: doi; margin: 0; text-align: start; }
.acaprs-rm25-published-list.acaprs-rm25-view-rows .acaprs-rm25-card-meta { grid-area: meta; margin: 0; text-align: start; }
.acaprs-rm25-published-list.acaprs-rm25-view-rows .acaprs-rm25-card-stats { grid-area: stats; margin: 0; padding: 0; border: 0; }
.acaprs-rm25-published-list.acaprs-rm25-view-rows .acaprs-rm25-card-stats strong { font-size: 16px; }
.acaprs-rm25-published-list.acaprs-rm25-view-rows .acaprs-rm25-card-stats span { font-size: 11px; }
.acaprs-rm25-published-list.acaprs-rm25-view-rows .acaprs-rm25-card-links { grid-area: actions; margin: 0; flex-direction: column; align-items: flex-start; justify-content: center; gap: 6px; }
@media (max-width: 900px) {
  .acaprs-rm25-published-list.acaprs-rm25-view-rows .acaprs-rm25-card3 { grid-template-columns: minmax(0, 1fr) 150px; grid-template-areas: "head stats" "doi stats" "meta stats" "actions actions"; }
  .acaprs-rm25-published-list.acaprs-rm25-view-rows .acaprs-rm25-card-links { flex-direction: row; flex-wrap: wrap; }
}
@media (max-width: 600px) {
  .acaprs-rm25-published-list.acaprs-rm25-view-rows .acaprs-rm25-card3 { grid-template-columns: minmax(0, 1fr); grid-template-areas: "head" "doi" "meta" "stats" "actions"; row-gap: 8px; }
  .acaprs-rm25-published-list.acaprs-rm25-view-rows .acaprs-rm25-card-stats { border-top: 1px solid #eee6f3; border-bottom: 1px solid #eee6f3; padding: 8px 0; }
}
@media (prefers-reduced-motion: reduce) {
  .acaprs-rm25-published-list .acaprs-rm25-card3 { transition: none; }
  .acaprs-rm25-published-list .acaprs-rm25-card3:hover { transform: none; }
}

/* (F) 2.5.6.6 — "شهاداتي" list: gold type badges removed by the owner's
   order (the type now shows only as calm text in the action links below,
   never as a pill). Cards and rows polished to best practice. All rules are
   scoped to .acaprs-rm25-cert-list so published/tracking lists are untouched. */
.acaprs-rm25-cert-list .acaprs-rm25-cert-card { display: flex; flex-direction: column; padding: 22px 22px 20px; transition: transform .18s ease, box-shadow .18s ease; }
.acaprs-rm25-cert-list .acaprs-rm25-cert-card:hover { transform: translateY(-2px); box-shadow: 0 8px 22px rgba(75,44,95,.14); }
.acaprs-rm25-cert-list .acaprs-rm25-cert-card h3 { margin: 0 0 4px; padding-bottom: 12px; border-bottom: 1px solid #f0e9f3; }
.acaprs-rm25-cert-who { margin: 12px 0 0; display: flex; flex-direction: column; align-items: center; gap: 6px; }
.acaprs-rm25-cert-who strong { color: #2E1A3C; font-size: 15px; }
.acaprs-rm25-cert-ref { font-family: "Courier New", monospace; font-size: 12px; font-weight: 700; letter-spacing: 1px; color: #4B2C5F; background: #f7f5f9; border: 1px solid #e5e0ea; border-radius: 6px; padding: 3px 10px; }
.acaprs-rm25-cert-dates { margin: 10px 0 0; display: flex; flex-wrap: wrap; justify-content: center; gap: 4px 16px; color: #666; font-size: 13px; }
.acaprs-rm25-cert-list .acaprs-rm25-card-doi { margin: 8px 0 0; color: #666; font-size: 12.5px; overflow-wrap: anywhere; }
.acaprs-rm25-cert-list .acaprs-rm25-card-doi span[dir="ltr"] { font-family: "Courier New", monospace; }
.acaprs-rm25-cert-list .acaprs-rm25-card-links { margin: auto 0 0; padding-top: 16px; display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; }
.acaprs-rm25-cert-action { display: inline-block; padding: 8px 18px; border-radius: 999px; border: 1.5px solid #4B2C5F; color: #4B2C5F; background: #fff; font-weight: 700; font-size: 13.5px; text-decoration: none; transition: background .15s ease, color .15s ease; }
.acaprs-rm25-cert-action:hover { background: #4B2C5F; color: #fff; }
.acaprs-rm25-cert-action-admin { border-style: dashed; }
.acaprs-rm25-cert-unavailable { display: block; width: 100%; color: #888; font-size: 12.5px; }
/* Rows view: one horizontal row per certificate — title first, meta cluster,
   actions pinned to the end; calm hover tint instead of lift. */
.acaprs-rm25-view-rows .acaprs-rm25-cert-list .acaprs-rm25-cert-card { flex-direction: row; flex-wrap: wrap; align-items: center; gap: 6px 20px; text-align: start; padding: 16px 20px; }
.acaprs-rm25-view-rows .acaprs-rm25-cert-list .acaprs-rm25-cert-card:hover { transform: none; box-shadow: 0 2px 8px rgba(75,44,95,.08); background: #fbf9fd; }
.acaprs-rm25-view-rows .acaprs-rm25-cert-list .acaprs-rm25-cert-card h3 { flex: 1 1 260px; margin: 0; padding: 0; border-bottom: none; text-align: start; }
.acaprs-rm25-view-rows .acaprs-rm25-cert-who { flex-direction: row; flex-wrap: wrap; align-items: center; margin: 0; gap: 4px 10px; }
.acaprs-rm25-view-rows .acaprs-rm25-cert-dates { margin: 0; justify-content: flex-start; }
.acaprs-rm25-view-rows .acaprs-rm25-cert-list .acaprs-rm25-card-doi { margin: 0; }
.acaprs-rm25-view-rows .acaprs-rm25-cert-list .acaprs-rm25-card-links { margin: 0 0 0 auto; padding: 0; flex-wrap: nowrap; }
@media (max-width: 600px) {
  .acaprs-rm25-view-rows .acaprs-rm25-cert-list .acaprs-rm25-cert-card { flex-direction: column; align-items: stretch; text-align: center; }
  .acaprs-rm25-view-rows .acaprs-rm25-cert-list .acaprs-rm25-cert-card h3 { text-align: center; }
  .acaprs-rm25-view-rows .acaprs-rm25-cert-who { flex-direction: column; }
  .acaprs-rm25-view-rows .acaprs-rm25-cert-list .acaprs-rm25-card-links { margin: 8px 0 0; justify-content: center; }
}

/* (F) 2.5.6.7 — Public profile rebuilt ORCID-style: quiet sidebar for
   identity + main column with sections; works as a clean collapsible
   list instead of oversized cards. Small type, generous whitespace. */
.acaprs-rm25-pp { display: grid; grid-template-columns: 280px 1fr; gap: 36px; max-width: 1080px; margin: 0 auto; padding: 28px 16px; font-size: 15px; line-height: 1.8; color: #23272F; box-sizing: border-box; }
.acaprs-rm25-pp-side { border-inline-end: 1px solid #e5e0ea; padding-inline-end: 28px; }
.acaprs-rm25-pp-avatar { width: 96px; height: 96px; margin-bottom: 14px; }
.acaprs-rm25-pp-avatar img { width: 96px; height: 96px; object-fit: cover; border-radius: 50%; border: 2px solid #EFD9A4; display: block; }
.acaprs-rm25-pp-avatar.acaprs-rm25-pp-initial { border-radius: 50%; border: 2px solid #EFD9A4; background: #4B2C5F; color: #fff; display: flex; align-items: center; justify-content: center; font-size: 38px; font-weight: 800; }
.acaprs-rm25-pp-side h1 { margin: 0 0 2px; color: #4B2C5F; font-size: 1.35rem; line-height: 1.4; font-weight: 800; }
.acaprs-rm25-pp-no { margin: 0 0 10px; color: #888; font-size: 13px; letter-spacing: 1px; }
.acaprs-rm25-pp-orcid { margin: 0 0 8px; font-size: 13px; }
.acaprs-rm25-pp-orcid-dot { display: inline-block; background: #A6CE39; color: #fff; font-size: 11px; font-weight: 800; border-radius: 50%; width: 20px; height: 20px; line-height: 20px; text-align: center; margin-inline-end: 6px; }
.acaprs-rm25-pp-orcid a { color: #4B2C5F; }
.acaprs-rm25-pp-country, .acaprs-rm25-pp-job { margin: 4px 0; font-size: 13px; color: #555; }
.acaprs-rm25-pp-main { min-width: 0; }
.acaprs-rm25-pp-section { margin-bottom: 32px; }
.acaprs-rm25-pp-section h2 { margin: 0 0 12px; padding-bottom: 8px; border-bottom: 1px solid #e5e0ea; color: #4B2C5F; font-size: 1.05rem; font-weight: 800; }
.acaprs-rm25-pp-section p { margin: 0 0 8px; }
.acaprs-rm25-pp-facts { margin: 0; }
.acaprs-rm25-pp-facts div { display: flex; gap: 10px; padding: 8px 0; border-bottom: 1px solid #f0edf3; font-size: 14px; }
.acaprs-rm25-pp-facts div:last-child { border-bottom: 0; }
.acaprs-rm25-pp-facts dt { color: #888; flex-shrink: 0; }
.acaprs-rm25-pp-facts dd { margin: 0; }
.acaprs-rm25-pp-empty { color: #888; font-size: 14px; }
.acaprs-rm25-pp-works { list-style: none; margin: 0; padding: 0; }
.acaprs-rm25-pp-work { display: flex; gap: 16px; padding: 14px 0; border-bottom: 1px solid #f0edf3; }
.acaprs-rm25-pp-work:last-child { border-bottom: 0; }
.acaprs-rm25-pp-year { flex-shrink: 0; width: 52px; color: #888; font-size: 13px; padding-top: 2px; }
.acaprs-rm25-pp-work-body { min-width: 0; }
.acaprs-rm25-pp-work-title { color: #4B2C5F; font-weight: 700; font-size: 15px; line-height: 1.6; text-decoration: none; }
.acaprs-rm25-pp-work-title:hover { text-decoration: underline; }
.acaprs-rm25-pp-type { display: inline-block; background: #F3EDF7; color: #4B2C5F; font-size: 11px; font-weight: 700; border-radius: 999px; padding: 2px 10px; margin-inline-start: 8px; vertical-align: middle; }
.acaprs-rm25-pp-doi { margin: 4px 0 0; font-size: 13px; color: #666; }
.acaprs-rm25-pp-doi a { color: #4B2C5F; }
.acaprs-rm25-pp-more { margin-top: 6px; font-size: 13px; }
.acaprs-rm25-pp-more summary { color: #4B2C5F; cursor: pointer; font-weight: 700; }
.acaprs-rm25-pp-more p { margin: 6px 0 0; color: #555; }
@media (max-width: 800px) {
  .acaprs-rm25-pp { grid-template-columns: 1fr; gap: 24px; }
  .acaprs-rm25-pp-side { border-inline-end: 0; padding-inline-end: 0; padding-bottom: 20px; border-bottom: 1px solid #e5e0ea; }
  .acaprs-rm25-pp-year { width: 44px; }
}

/* 2.5.6.8 — Classic certificate restoration (merge item 5, display only).
   Values copied from the approved artifact (ts-spaces/tsmym-shhdt-lmjl):
   purple gradient border #4B2C5F -> #2E1A3C, radius 20px; paper #FFFDF6
   with a soft top glow, 2px gold border + 1px gold outline (offset 5px).
   Scoped to .acaprs-rm25-cert-classic (page 1 wrapper and page 2 wrapper)
   so no other tab is touched. Centered text stays centered: the frame is
   text-align:center; only the info table is text-align:start. */
.acaprs-rm25-cert-classic, .acaprs-rm25-cert-classic * { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
.acaprs-rm25-cert-classic .acaprs-rm25-cert-border { background: radial-gradient(circle at 12% 18%, rgba(239,217,164,.10) 0 2px, transparent 3px), radial-gradient(circle at 88% 82%, rgba(239,217,164,.10) 0 2px, transparent 3px), radial-gradient(circle at 82% 14%, rgba(239,217,164,.07) 0 2px, transparent 3px), radial-gradient(circle at 18% 86%, rgba(239,217,164,.07) 0 2px, transparent 3px), repeating-linear-gradient(45deg, rgba(255,255,255,.022) 0 2px, transparent 2px 14px), linear-gradient(135deg, #4B2C5F 0%, #2E1A3C 100%); border-radius: 20px; padding: clamp(10px, 1.8vw, 20px); box-shadow: 0 24px 60px rgba(46,26,60,.30); }
.acaprs-rm25-cert-classic .acaprs-rm25-cert-frame { position: relative; background: radial-gradient(ellipse at 50% 0%, #F3EDF7 0%, transparent 55%), #FFFDF6; border: 2px solid #EFD9A4; outline: 1px solid #C9A24B; outline-offset: 5px; border-radius: 10px; padding: clamp(18px, 2.6vw, 30px) clamp(20px, 4.5vw, 58px); text-align: center; overflow: hidden; line-height: 1.9; color: #23272F; }
.acaprs-rm25-cert-corner { position: absolute; top: 12px; color: #C9A24B; font-size: 1.1rem; opacity: .9; }
.acaprs-rm25-cert-corner-s { inset-inline-start: 20px; }
.acaprs-rm25-cert-corner-e { inset-inline-end: 20px; }
.acaprs-rm25-cert-head { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-bottom: 8px; text-align: start; }
.acaprs-rm25-cert-brand { display: flex; align-items: center; gap: 14px; min-width: 0; }
.acaprs-rm25-cert-medal { width: 64px; height: 64px; border-radius: 50%; background: #fff; border: 2px solid #C9A24B; box-shadow: 0 6px 16px rgba(46,26,60,.25); flex-shrink: 0; padding: 8px; display: inline-flex; align-items: center; justify-content: center; box-sizing: border-box; }
.acaprs-rm25-cert-medal img { width: 100%; height: 100%; object-fit: contain; display: block; }
.acaprs-rm25-cert-medal > span { color: #4B2C5F; font-size: 30px; font-weight: 900; line-height: 1; }
.acaprs-rm25-cert-brand-text { display: flex; flex-direction: column; gap: 5px; text-align: start; line-height: 1.35; }
.acaprs-rm25-cert-brand-text strong { color: #4B2C5F; font-size: 1.22rem; font-weight: 800; }
.acaprs-rm25-cert-brand-text span { color: #6B7280; font-size: .7rem; font-weight: 700; letter-spacing: 2.2px; }
.acaprs-rm25-cert-pill { color: #8a6d1f; font-weight: 800; font-size: .9rem; border: 1.5px solid #EFD9A4; border-radius: 999px; padding: 7px 18px; background: rgba(239,217,164,.14); white-space: nowrap; text-align: center; }
.acaprs-rm25-cert-pill small { display: block; font-size: .68rem; color: #6B7280; letter-spacing: 1.5px; font-weight: 700; }
.acaprs-rm25-cert-ribbon { display: inline-flex; align-items: center; gap: 10px; background: #4B2C5F; color: #fff; font-weight: 800; font-size: .98rem; border-radius: 999px; padding: 8px 24px; margin: 8px 0 0; box-shadow: 0 8px 20px rgba(75,44,95,.35); }
.acaprs-rm25-cert-classic .acaprs-rm25-cert-title { color: #4B2C5F; font-size: clamp(1.5rem, 3vw, 2.15rem); font-weight: 900; margin: 8px 0; border: none; padding: 0; }
.acaprs-rm25-cert-pre { color: #6B7280; font-size: 1rem; margin: 4px 0 0; }
.acaprs-rm25-cert-classic .acaprs-rm25-cert-paper { color: #4B2C5F; font-size: clamp(1.15rem, 2.4vw, 1.6rem); font-weight: 800; margin: 4px auto 2px; max-width: 820px; line-height: 1.7; }
.acaprs-rm25-cert-author-name { color: #2E1A3C; font-size: clamp(1.4rem, 2.9vw, 1.95rem); font-weight: 900; margin: 6px 0 2px; display: inline-block; border-bottom: 3px double #C9A24B; padding: 0 24px 5px; }
.acaprs-rm25-cert-author-meta { color: #6B7280; font-size: .95rem; font-weight: 600; margin: 2px 0 0; }
.acaprs-rm25-cert-author-meta a { color: #4B2C5F; }
.acaprs-rm25-cert-body { color: #3c4048; font-size: .99rem; line-height: 1.9; max-width: 860px; margin: 10px auto 2px; }
.acaprs-rm25-cert-coauthors { color: #6B7280; font-weight: 700; margin: 12px 0 2px; }
.acaprs-rm25-cert-classic .acaprs-rm25-cert-coauthors-list { text-align: start; display: inline-block; margin: 4px auto; color: #3c4048; }
.acaprs-rm25-cert-details { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin: 16px auto 2px; max-width: 760px; }
.acaprs-rm25-cert-detail { background: #F3EDF7; border-top: 3px solid #4B2C5F; border-radius: 12px; padding: 8px 10px; display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.acaprs-rm25-cert-detail span { color: #6B7280; font-size: .75rem; font-weight: 600; }
.acaprs-rm25-cert-detail strong { color: #23272F; font-size: .98rem; font-weight: 800; overflow-wrap: anywhere; }
/* 2.5.6.10 — LTR values (reference / DOI) at .98rem, as in the approved artifact. */
.acaprs-rm25-cert-classic .acaprs-rm25-cert-detail strong[dir="ltr"] { font-size: .9rem; }
/* 2.5.6.22 — bottom row: ONE centered horizontal row — signature on
   the right of the stamp, QR on its left, both spaced from the stamp
   (DOM order sign, stamp, QR; in RTL the first item sits at the visual
   right). The old stacked layout (stamp block, signature beneath,
   verify box) is gone, with it the repeated EIC title and the admin
   eic_notice hint. The QR figure keeps its Academy card
   (.acaprs-rm25-cert-qr) and now also carries the reference code below
   the 'Scan to verify' caption; the full verification link and the hint
   live in .acaprs-rm25-cert-verify-line, one standalone line directly
   above the supervision (HBECS) line. */
.acaprs-rm25-cert-bottom-row { display: flex; justify-content: center; align-items: flex-start; gap: 56px; margin-top: 20px; }
.acaprs-rm25-cert-sign-col { text-align: center; min-width: 0; }
.acaprs-rm25-cert-sign-col img { max-height: 90px; }
.acaprs-rm25-cert-eic-line { margin: 6px 0 0; font-size: .95rem; color: #23272F; font-weight: 600; }
.acaprs-rm25-cert-eic-line strong { font-weight: 800; }
.acaprs-rm25-cert-stamp-col { flex-shrink: 0; text-align: center; }
.acaprs-rm25-cert-stamp-col img { width: 170px; max-width: 170px; height: auto; }
.acaprs-rm25-cert-bottom-row .acaprs-rm25-cert-qr { flex-shrink: 0; }
.acaprs-rm25-cert-qr .acaprs-rm25-cert-verify-code { font-size: .85rem; margin-top: 2px; }
.acaprs-rm25-cert-verify-code { font-weight: 900; color: #2E1A3C; font-size: 1.05rem; }
.acaprs-rm25-cert-verify-line { text-align: center; margin: 12px auto 0; font-size: .82rem; color: #6B7280; font-weight: 600; overflow-wrap: anywhere; }
.acaprs-rm25-cert-verify-line a { color: #4B2C5F; font-weight: 700; }
/* 2.5.6.9 — verification QR (Academy certificates 1.2.10: 104px desktop,
   84px mobile, caption 'Scan to verify'). 2.5.6.10 — the figure now wears
   the Academy card: white background, 2px gold border, radius 12px. */
.acaprs-rm25-cert-qr { margin: 0; flex-shrink: 0; text-align: center; background: #fff; border: 2px solid #C9A24B; border-radius: 12px; padding: 8px 8px 6px; }
.acaprs-rm25-cert-qr img { width: 104px; height: 104px; display: block; margin: 0 auto; }
.acaprs-rm25-cert-qr figcaption { color: #4B2C5F; font-size: .72rem; font-weight: 800; margin-top: 4px; text-align: center; }
@media (max-width: 600px) { .acaprs-rm25-cert-qr img { width: 84px; height: 84px; } .acaprs-rm25-cert-bottom-row { flex-wrap: wrap; gap: 24px; } }
.acaprs-rm25-cert-supervision { margin-top: 16px; padding-top: 10px; border-top: 1px solid #EFD9A4; color: #6B7280; font-size: .82rem; font-weight: 600; text-align: center; }
/* 2.5.6.22 — page 2 is deleted; its screen rules are gone with it. */
@media (max-width: 600px) {
  .acaprs-rm25-cert-details { grid-template-columns: 1fr; }
  .acaprs-rm25-cert-head { flex-direction: column; }
}
@media print {
  .acaprs-rm25-cert-border { box-shadow: none; }
}

/* 2.5.6.8 (items 7–8) — tracking accordion + no-reload certificate
   language switch. Presentation only; no other tab is touched.
   Centered text stays centered: the tracking title keeps text-align:start
   (as the old h3 did in the RTL dashboard) and the certificate frame keeps
   its own text-align:center — this section sets no text-align on it. */

/* (7) Tracking accordion: the header is a full-width button (reset to
   inherit the card's type); the title span replaces the old h3 visually
   (same purple, size and weight) because a heading may not sit inside a
   <button>. The arrow rotates when the card opens; the body is collapsed
   by the `hidden` attribute. */
.acaprs-rm25-track-toggle { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; flex-wrap: wrap; width: 100%; background: none; border: 0; padding: 0; margin: 0; cursor: pointer; font: inherit; color: inherit; text-align: start; }
.acaprs-rm25-track-title { margin: 0; color: #4B2C5F; font-size: 17px; line-height: 1.6; font-weight: 700; flex: 1 1 auto; text-align: start; }
.acaprs-rm25-track-toggle .acaprs-rm25-chip { flex-shrink: 0; }
.acaprs-rm25-track-arrow { flex-shrink: 0; color: #4B2C5F; font-size: 16px; line-height: 1.6; transition: transform .2s ease; }
.acaprs-rm25-track-card.is-open .acaprs-rm25-track-arrow { transform: rotate(180deg); }
.acaprs-rm25-track-body[hidden] { display: none; }
@media (prefers-reduced-motion: reduce) {
  .acaprs-rm25-track-arrow { transition: none; }
}
/* Print: open every tracking card so the list never prints empty. */
@media print {
  .acaprs-rm25-track-body[hidden] { display: block !important; }
}

/* (8) Certificate language versions: only the active one shows, on
   screen and in print (the hidden version must never print). The
   switcher itself is .acaprs-rm25-no-print, so it never prints. */
.acaprs-rm25-cert-lang[hidden] { display: none; }
@media print {
  .acaprs-rm25-cert-lang[hidden] { display: none !important; }
}

/* 2.5.6.16 — (1) Rows-view distortion fix (owner's report 2026-11-05):
   a single paper/certificate in rows view stretched its elements across
   the full width — the title flexed to fill (flex: 1 1 280px) while the
   actions were pushed to the far end (margin-left: auto) and the stats
   sat in fixed 200px/168px columns — leaving vast empty spaces. The
   fix is compact auto-sized columns: title takes the remaining space,
   stats and actions size to their content, no spread, no auto margins.
   Cards view is untouched. */
.acaprs-rm25-view-rows .acaprs-rm25-card3 h3 { flex: 0 1 auto; }
/* Published rows: stats and actions size to content (was 200px/168px
   fixed); stats become one compact horizontal strip (number + label
   inline) instead of a squeezed 3-column grid; actions become a
   horizontal row aligned to the end. */
.acaprs-rm25-published-list.acaprs-rm25-view-rows .acaprs-rm25-card3 { grid-template-columns: minmax(0, 1fr) auto auto; column-gap: 16px; padding: 14px 18px; }
.acaprs-rm25-published-list.acaprs-rm25-view-rows .acaprs-rm25-card-stats { display: flex; gap: 14px; white-space: nowrap; }
.acaprs-rm25-published-list.acaprs-rm25-view-rows .acaprs-rm25-card-stats > div { display: flex; flex-direction: row; align-items: baseline; gap: 5px; }
.acaprs-rm25-published-list.acaprs-rm25-view-rows .acaprs-rm25-card-stats > div + div { border-inline-start: 1px solid #eee6f3; padding-inline-start: 14px; }
.acaprs-rm25-published-list.acaprs-rm25-view-rows .acaprs-rm25-card-stats strong { font-size: 15px; }
.acaprs-rm25-published-list.acaprs-rm25-view-rows .acaprs-rm25-card-stats span { font-size: 11px; }
.acaprs-rm25-published-list.acaprs-rm25-view-rows .acaprs-rm25-card-links { flex-direction: row; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 6px 12px; }
@media (max-width: 900px) {
  .acaprs-rm25-published-list.acaprs-rm25-view-rows .acaprs-rm25-card3 { grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "head stats" "doi stats" "meta stats" "actions actions"; }
  .acaprs-rm25-published-list.acaprs-rm25-view-rows .acaprs-rm25-card-links { justify-content: flex-start; }
}
@media (max-width: 600px) {
  .acaprs-rm25-published-list.acaprs-rm25-view-rows .acaprs-rm25-card-stats { border-top: 1px solid #eee6f3; border-bottom: 1px solid #eee6f3; padding: 8px 0; }
}
/* Certificates rows: compact two-column grid (title/meta | actions)
   instead of a flex row that spread title and actions to opposite
   ends; the auto-sized actions column ends the vast gaps. */
.acaprs-rm25-view-rows .acaprs-rm25-cert-list .acaprs-rm25-cert-card { display: grid; grid-template-columns: minmax(0, 1fr) auto; grid-template-areas: "title actions" "who actions" "dates actions" "doi actions"; column-gap: 16px; row-gap: 2px; align-items: center; text-align: start; padding: 14px 18px; }
.acaprs-rm25-view-rows .acaprs-rm25-cert-list .acaprs-rm25-cert-card h3 { grid-area: title; flex: none; margin: 0; padding: 0; border-bottom: none; text-align: start; }
.acaprs-rm25-view-rows .acaprs-rm25-cert-who { grid-area: who; flex-direction: row; flex-wrap: wrap; align-items: center; margin: 0; gap: 4px 10px; }
.acaprs-rm25-view-rows .acaprs-rm25-cert-dates { grid-area: dates; margin: 0; justify-content: flex-start; }
.acaprs-rm25-view-rows .acaprs-rm25-cert-list .acaprs-rm25-card-doi { grid-area: doi; margin: 0; }
.acaprs-rm25-view-rows .acaprs-rm25-cert-list .acaprs-rm25-card-links { grid-area: actions; margin: 0; padding: 0; flex-wrap: wrap; justify-content: flex-end; white-space: nowrap; }
@media (max-width: 600px) {
  .acaprs-rm25-view-rows .acaprs-rm25-cert-list .acaprs-rm25-cert-card { grid-template-columns: minmax(0, 1fr); grid-template-areas: "title" "who" "dates" "doi" "actions"; row-gap: 6px; text-align: center; }
  .acaprs-rm25-view-rows .acaprs-rm25-cert-list .acaprs-rm25-cert-card h3 { text-align: center; }
  .acaprs-rm25-view-rows .acaprs-rm25-cert-who { flex-direction: column; justify-content: center; }
  .acaprs-rm25-view-rows .acaprs-rm25-cert-dates { justify-content: center; }
  .acaprs-rm25-view-rows .acaprs-rm25-cert-list .acaprs-rm25-card-links { margin: 6px 0 0; justify-content: center; }
}

/* 2.5.6.16 — (2) Public profile: works in the left column ONLY, everything
   else (identity, bio, facts) in the right column. In RTL the first grid
   track is the right side, so the side column (first in DOM) sits right
   in Arabic and the works column sits left; in LTR the layout mirrors.
   Explicit direction rules so Arabic is always RTL/right-aligned even
   when the theme does not set html[dir]. */
.acaprs-rm25-pp { grid-template-columns: 320px minmax(0, 1fr); }
html[dir="rtl"] .acaprs-rm25-pp { direction: rtl; text-align: right; }
html[dir="ltr"] .acaprs-rm25-pp { direction: ltr; text-align: left; }
.acaprs-rm25-pp-side { min-width: 0; }
.acaprs-rm25-pp-side-section { margin-top: 24px; }
.acaprs-rm25-pp-side-section h2 { margin: 0 0 10px; padding-bottom: 8px; border-bottom: 1px solid #e5e0ea; color: #4B2C5F; font-size: 1.05rem; font-weight: 800; }
.acaprs-rm25-pp-stat { margin: 14px 0 0; padding: 10px 14px; background: #f8f5fb; border: 1px solid #EFD9A4; border-radius: 12px; font-size: 14px; }
.acaprs-rm25-pp-stat strong { color: #4B2C5F; font-size: 18px; }

/* 2.5.6.16 — (3) Tracking info strip: four boxes now (status, version,
   submission date, issue / publication type). */
.acaprs-rm25-track-info { grid-template-columns: repeat(4, 1fr); }

/* 2.5.6.16 — (4) Transparent stamp: the new default stamp PNG carries
   its own alpha channel (white background removed); the certificate
   frame is paper #FFFDF6, so the stamp must never sit on a white box.
   Belt-and-braces: no background anywhere on the stamp image. */
.acaprs-rm25-cert-stamp-col img { background: transparent; }
.acaprs-rm25-cert-stamp img { background: transparent; }

/* 2.5.6.17 — CSS-only certificate language switcher (no-JS base mechanism).
   Root cause (proven by three live waves 273/274/275 + local proof): no
   switcher script executes in the dashboard context — enqueued footer
   file (2.5.6.8), inline binding (2.5.6.14), delegated listener
   (2.5.6.15) — although each is provably correct in isolation
   (node --check + jsdom simulation of the exact printed markup). The
   only inline scripts verified to run live are the literal multi-line
   blocks printed via ob_start() in the submit form (add/remove author
   rows); every failing script is a single-line string concatenated
   into $out — but the mangling step itself is not provable from local
   code, so the switch no longer depends on ANY script executing.
   Mechanism: the switcher is two hidden radio inputs + two <label>
   buttons, printed INSIDE .acaprs-rm25-cert-dual before the two
   language versions. Clicking a label checks its radio; the :checked
   sibling rules below show the matching version and hide the other —
   in place, with no navigation and no JS. The `checked` radio always
   matches the server-rendered visible version (from ?cert_lang=), and
   the `hidden` attribute stays on the non-requested version as the
   no-CSS fallback. The show rules carry !important so they beat the
   .acaprs-rm25-cert-lang[hidden] rules, including the print one — so
   the selected version is also the one that prints. The active label
   and the keyboard focus ring follow the radio state in pure CSS too.
   The inline scripts only sync the URL (?cert_lang= via replaceState)
   and the wrapper's lang/dir when a radio changes; if they never run,
   the switch still works. Each version div carries its own lang/dir,
   so text direction follows the version itself. */
.acaprs-rm25-cert-dual .acaprs-rm25-cert-lang-radio { position: absolute; width: 1px; height: 1px; margin: 0; padding: 0; opacity: 0; pointer-events: none; }
/* Labels look exactly like the old switcher links (same pill style as
   .acaprs-rm25-view-toggle a / button). */
.acaprs-rm25-view-toggle label { padding: 8px 18px; border-radius: 999px; border: 1px solid #4B2C5F; color: #4B2C5F; background: #fff; font-weight: 700; cursor: pointer; }
/* Active label follows the checked radio (pure CSS). */
.acaprs-rm25-cert-dual > input.acaprs-rm25-cert-lang-radio[value="ar"]:checked ~ .acaprs-rm25-cert-lang-switcher label[data-acaprs-cert-lang="ar"],
.acaprs-rm25-cert-dual > input.acaprs-rm25-cert-lang-radio[value="en"]:checked ~ .acaprs-rm25-cert-lang-switcher label[data-acaprs-cert-lang="en"] { background: #4B2C5F; color: #fff; }
/* Keyboard focus: outline the label that belongs to the focused radio. */
.acaprs-rm25-cert-dual > input.acaprs-rm25-cert-lang-radio[value="ar"]:focus-visible ~ .acaprs-rm25-cert-lang-switcher label[data-acaprs-cert-lang="ar"],
.acaprs-rm25-cert-dual > input.acaprs-rm25-cert-lang-radio[value="en"]:focus-visible ~ .acaprs-rm25-cert-lang-switcher label[data-acaprs-cert-lang="en"] { outline: 2px solid #4B2C5F; outline-offset: 2px; }
/* The swap itself — hide the version whose radio is NOT checked, show
   the one whose radio IS checked. !important on all four so the show
   rules beat .acaprs-rm25-cert-lang[hidden] (including its print
   !important rule) and the hide rules beat any theme display rule. */
.acaprs-rm25-cert-dual > input.acaprs-rm25-cert-lang-radio[value="ar"]:checked ~ .acaprs-rm25-cert-lang[data-acaprs-cert-lang="en"] { display: none !important; }
.acaprs-rm25-cert-dual > input.acaprs-rm25-cert-lang-radio[value="en"]:checked ~ .acaprs-rm25-cert-lang[data-acaprs-cert-lang="ar"] { display: none !important; }
.acaprs-rm25-cert-dual > input.acaprs-rm25-cert-lang-radio[value="ar"]:checked ~ .acaprs-rm25-cert-lang[data-acaprs-cert-lang="ar"] { display: block !important; }
.acaprs-rm25-cert-dual > input.acaprs-rm25-cert-lang-radio[value="en"]:checked ~ .acaprs-rm25-cert-lang[data-acaprs-cert-lang="en"] { display: block !important; }

/* 2.5.6.19 — certificate print fit (owner's report 2026-11-06): the
   downloaded/printed PDF spilled — page 1 overflowed onto a second
   page (and a publication certificate ran to three pages instead of
   two). Root cause, measured from this stylesheet at the print
   viewport (A4 landscape 297mm wide, printable 281mm = 1062px at
   8mm margins, 16px base):
   - Page-1 content is ~1420px tall at screen proportions (frame
     line-height 1.9, author name ~31px at line-height 1.9, 170px
     stamp, 104px QR, generous paddings) against a 734px printable
     height — about 2x the budget. So `page-break-inside: avoid` on
     the frame (CSS lines 64, 148) could never be honoured: a
     browser ignores it when the content is taller than one page
     and breaks mid-frame — the stamp / signature / verify box /
     supervision line landed on page 2, and the intended page 2
     (break-before: always) was pushed to page 3.
   - Aggravator: the print `padding: 10mm 18mm` rule never applied
     at all — the classic (0,2,0) frame rule (line 422) beats the
     (0,1,0) print rule (line 64) — and nothing anywhere
     constrained page-1 height to the printable area.
   Fix (print only — the on-screen certificate is untouched):
   @page A4 landscape with 5mm margins (printable 287x200mm);
   page 1 is a fixed 200mm sheet with overflow:hidden (the hard
   guard — it can never spill); the border is scaled with
   transform: scale(0.78) at width 368mm (= 287/0.78) and height
   256mm (= 200/0.78), transform-origin: top left, so its visual
   box is exactly the 287x200mm sheet (2.5.6.22: zoom:0.78 was
   dropped — zoom is non-standard and Chrome's print pipeline
   mishandles it, see the 2.5.6.22 note) over print-compacted
   content (~875px natural -> ~680px rendered, typical cases incl.
   3 co-authors / 3-line titles still fit; pathological cases clip
   the supervision line instead of spilling, by design); the frame
   fills the sheet (height:100%), so any slack is plain paper at
   the bottom. Critical blocks also carry break-inside:avoid.
   Non-cert content was already hidden in print (no-print /
   buttons / tabs / header / footer rules); body and wrapper
   margins are zeroed on cert pages so no stray offset can push
   the sheet past the page. Page 2 is deleted in 2.5.6.22. */
@page { size: A4 landscape; margin: 5mm; }
@media print {
  @page { size: A4 landscape; margin: 5mm; }
  body.acaprs-rm25-cert-page { margin: 0 !important; padding: 0 !important; }
  body.acaprs-rm25-cert-page .acaprs-rm25-dashboard,
  body.acaprs-rm25-cert-page .acaprs-rm25-tab-panel,
  .acaprs-rm25-cert-dual, .acaprs-rm25-cert-lang { margin: 0 !important; padding: 0 !important; }
  /* Page 1 sheet: exactly the printable height; the hard guard. */
  .acaprs-rm25-certificate-print { box-sizing: border-box; height: 200mm; overflow: hidden; }
  .acaprs-rm25-certificate-print .acaprs-rm25-cert-border { box-sizing: border-box; width: 368mm; height: 256mm; margin: 0; padding: 6px; transform: scale(0.78); transform-origin: top left; }
  .acaprs-rm25-certificate-print .acaprs-rm25-cert-frame { box-sizing: border-box; height: 100%; line-height: 1.45; padding: 6px 40px; }
  .acaprs-rm25-certificate-print p { margin-top: 2px; margin-bottom: 2px; }
  .acaprs-rm25-certificate-print .acaprs-rm25-cert-head { margin-bottom: 4px; gap: 10px; }
  .acaprs-rm25-certificate-print .acaprs-rm25-cert-medal { width: 36px; height: 36px; padding: 4px; }
  .acaprs-rm25-certificate-print .acaprs-rm25-cert-medal > span { font-size: 20px; }
  .acaprs-rm25-certificate-print .acaprs-rm25-cert-brand-text strong { font-size: 1rem; }
  .acaprs-rm25-certificate-print .acaprs-rm25-cert-brand-text span { font-size: .62rem; }
  .acaprs-rm25-certificate-print .acaprs-rm25-cert-pill { font-size: .8rem; padding: 4px 12px; }
  .acaprs-rm25-certificate-print .acaprs-rm25-cert-pill small { font-size: .6rem; }
  .acaprs-rm25-certificate-print .acaprs-rm25-cert-ribbon { font-size: .85rem; padding: 5px 18px; margin-top: 6px; }
  .acaprs-rm25-certificate-print .acaprs-rm25-cert-title { font-size: 1.4rem; margin: 4px 0; }
  .acaprs-rm25-certificate-print .acaprs-rm25-cert-pre { font-size: .85rem; margin-top: 2px; }
  .acaprs-rm25-certificate-print .acaprs-rm25-cert-paper { font-size: 1.2rem; line-height: 1.5; margin: 2px auto; max-width: 940px; }
  .acaprs-rm25-certificate-print .acaprs-rm25-cert-author-name { font-size: 1.5rem; margin: 2px 0; padding-bottom: 4px; }
  .acaprs-rm25-certificate-print .acaprs-rm25-cert-author-meta { font-size: .8rem; margin-top: 0; }
  .acaprs-rm25-certificate-print .acaprs-rm25-cert-body { font-size: .85rem; line-height: 1.5; margin: 6px auto 2px; max-width: 940px; }
  .acaprs-rm25-certificate-print .acaprs-rm25-cert-coauthors { margin: 6px 0 2px; }
  .acaprs-rm25-certificate-print .acaprs-rm25-cert-coauthors-list { margin: 2px auto; }
  .acaprs-rm25-certificate-print .acaprs-rm25-cert-details { margin: 8px auto 2px; gap: 8px; }
  .acaprs-rm25-certificate-print .acaprs-rm25-cert-detail { padding: 4px 6px; gap: 2px; }
  .acaprs-rm25-certificate-print .acaprs-rm25-cert-detail span { font-size: .7rem; }
  .acaprs-rm25-certificate-print .acaprs-rm25-cert-detail strong { font-size: .85rem; }
  .acaprs-rm25-certificate-print .acaprs-rm25-cert-detail strong[dir="ltr"] { font-size: .78rem; }
  .acaprs-rm25-certificate-print .acaprs-rm25-cert-bottom-row { margin-top: 8px; gap: 40px; }
  .acaprs-rm25-certificate-print .acaprs-rm25-cert-stamp-col img { width: 80px; max-width: 80px; }
  .acaprs-rm25-certificate-print .acaprs-rm25-cert-sign-col img { max-height: 40px; }
  .acaprs-rm25-certificate-print .acaprs-rm25-cert-eic-line { font-size: .8rem; margin: 2px 0 0; }
  .acaprs-rm25-certificate-print .acaprs-rm25-cert-qr { padding: 6px 6px 4px; }
  .acaprs-rm25-certificate-print .acaprs-rm25-cert-qr img { width: 52px; height: 52px; }
  .acaprs-rm25-certificate-print .acaprs-rm25-cert-qr figcaption { font-size: .65rem; margin-top: 2px; }
  .acaprs-rm25-certificate-print .acaprs-rm25-cert-qr .acaprs-rm25-cert-verify-code { font-size: .8rem; }
  .acaprs-rm25-certificate-print .acaprs-rm25-cert-verify-line { font-size: .72rem; margin-top: 6px; }
  .acaprs-rm25-certificate-print .acaprs-rm25-cert-supervision { margin-top: 6px; padding-top: 4px; font-size: .72rem; }
  .acaprs-rm25-certificate-print .acaprs-rm25-cert-corner { font-size: .9rem; top: 6px; }
  .acaprs-rm25-certificate-print .acaprs-rm25-cert-bottom-row,
  .acaprs-rm25-certificate-print .acaprs-rm25-cert-verify-line,
  .acaprs-rm25-certificate-print .acaprs-rm25-cert-details { break-inside: avoid; page-break-inside: avoid; }
  /* 2.5.6.22 — page 2 is deleted; its print rules are gone with it. */
}

/* 2.5.6.21 — print polish (owner's report, wave 278, 2026-11-06):
   (1) Two floating buttons printed in the certificate PDFs although
   they are site chrome, not certificate: the green WhatsApp circle
   (bottom-right) and User Switching's blue "switch back" button
   (bottom-left, «تحويل إلى Hassan Albaiti»). Both are rendered by
   the theme / other plugins straight into <body>, outside
   .acaprs-rm25-dashboard, so none of the existing in-dashboard
   print rules could reach them — the old "print is clean" claim in
   2.5.6.19 was wrong for anything outside the dashboard container.
   - The switch-back button is User Switching's wp_footer link, an
     exact hook: <p id="user_switching_switch_on"
     style="position: fixed; bottom: 40px; left: 10px; z-index: 99999">
     (verified against the plugin source, user-switching.php
     action_wp_footer; the live 1.12.2 keeps the same id — the
     GitHub audit #266 quotes the same lines). #user_switching is
     the same plugin's admin notice id, hidden too for completeness.
     #wpadminbar is belt-and-braces.
   - The WhatsApp button's plugin is not identifiable from the
     local code (theme/plugin, not RM), so it is hidden by the
     known floating-chat plugin hooks (Click to Chat, Joinchat,
     WP WhatsApp Chat, Chaty, GetButton) plus href/class catch-alls
     (wa.me / api.whatsapp.com / any class or id containing
     "whatsapp" or "wa-chat", case-insensitive). No certificate
     element matches any of these (the QR verify box is
     .acaprs-rm25-cert-qr; the certificate carries no wa.me link).
   Scoped to body.acaprs-rm25-cert-page, print only — nothing on
   screen changes, and printing any other page is untouched.
   (2) Empty space: page 1's frame is a fixed 200mm sheet whose
   content is ~17mm short, so the slack pooled below the HBECS
   line; page 2's card sat at the top of its page. Print only:
   - Page 1 frame becomes a column flex with
     justify-content: space-between — the slack spreads evenly
     between the blocks, first block flush top, HBECS line flush
     bottom. Overflow safety is preserved BY CONSTRUCTION:
     space-between behaves exactly like flex-start when the
     content is taller than the frame (no free space to
     distribute), so a pathological over-long certificate still
     clips only at the bottom under the sheet's overflow:hidden
     guard — never at the top. The two inline-level children
     (ribbon, coauthors list) get align-self:center so they keep
     their centred screen look instead of stretching full width.
     Corners are position:absolute (frame is position:relative),
     so flex does not move them.
   - (2.5.6.22: page 2 is deleted, so the centring rule below is
     removed with it — the certificate is one page.) */
@media print {
  body.acaprs-rm25-cert-page #user_switching_switch_on,
  body.acaprs-rm25-cert-page #user_switching,
  body.acaprs-rm25-cert-page #wpadminbar,
  body.acaprs-rm25-cert-page #ht-ctc-chat,
  body.acaprs-rm25-cert-page .ht-ctc-chat,
  body.acaprs-rm25-cert-page .joinchat,
  body.acaprs-rm25-cert-page #joinchat,
  body.acaprs-rm25-cert-page .qlwapp,
  body.acaprs-rm25-cert-page #qlwapp,
  body.acaprs-rm25-cert-page .chaty,
  body.acaprs-rm25-cert-page #chaty,
  body.acaprs-rm25-cert-page .getbutton,
  body.acaprs-rm25-cert-page #getbutton,
  body.acaprs-rm25-cert-page [class*="whatsapp" i],
  body.acaprs-rm25-cert-page [id*="whatsapp" i],
  body.acaprs-rm25-cert-page [class*="wa-chat" i],
  body.acaprs-rm25-cert-page [id*="wa-chat" i],
  body.acaprs-rm25-cert-page a[href*="wa.me" i],
  body.acaprs-rm25-cert-page a[href*="api.whatsapp.com" i] { display: none !important; }
  /* Page 1: spread the ~17mm slack through the frame instead of
     pooling it below the HBECS line. */
  .acaprs-rm25-certificate-print .acaprs-rm25-cert-frame { display: flex; flex-direction: column; justify-content: space-between; }
  .acaprs-rm25-certificate-print .acaprs-rm25-cert-ribbon,
  .acaprs-rm25-certificate-print .acaprs-rm25-cert-coauthors-list { align-self: center; }
  /* 2.5.6.22 — page 2 is deleted; no page-2 rule remains. */
}
