/* Applied only when printing / "Save as PDF". Keeps output to just the
   resume document — no header, form, toolbar, or drawer. */

/* @page size is injected dynamically by app.js (setPageSizeStyle) so it can
   follow the A4/Letter toggle. A default is set at load time either way. */

body * { visibility: hidden; }

#resume-preview, #resume-preview * { visibility: visible; }

#resume-preview {
  position: absolute;
  top: 0;
  left: 0;
  box-shadow: none !important;
  margin: 0 !important;
}

/* Guards against a real edge case the mobile Edit/Preview toggle
   introduces: on a phone, printing/"Save as PDF" often renders at the
   same narrow width as the screen rather than a separate wide "print
   viewport" the way desktop browsers usually do — meaning the regular
   screen media query that hides .preview-panel while the mobile
   toggle is on "Edit" could still be in effect here too. visibility
   above doesn't help with that; an element with display: none stays
   removed from the render tree regardless of its visibility value.
   Forcing it back on specifically for print guarantees the actual
   resume is always what gets exported, independent of which mobile
   tab happened to be open when Download was tapped. */
.preview-panel { display: flex !important; }

.no-print, .no-print * { display: none !important; }

/* Ask the browser to keep background colors/accents in the printed PDF. */
* {
  -webkit-print-color-adjust: exact;
  print-color-adjust: exact;
}
