/* print.css */
@media print {

  /* Hide WP admin bar */
  #wpadminbar { display: none !important; }

  /* Hide global header & footer (block themes + classic themes) */
  header, footer,
  .site-header, .site-footer,
  .wp-block-template-part, /* generic template parts */
  .footer-widgets, .site-info,
  nav, .site-navigation,
  .widget-area, .sidebar,
  .comments, #comments { 
    display: none !important; 
  }

  /* Optional: hide breadcrumbs and other common bits */
  .breadcrumbs, .yoast-breadcrumbs,
  .page-title, .entry-meta, .post-meta {
    display: none !important;
  }

  /* Make main content full-width */
  main, .site-main, .wp-site-blocks, .entry-content, .hentry, .post, .page {
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    box-shadow: none !important;
    background: transparent !important;
  }

  /* Tidy typography for print */
  body {
    color: #000 !important;
    background: #fff !important;
    font-size: 12pt !important;
    line-height: 1.4 !important;
  }

  /* Remove non-essential UI */
  .button, .buttons, .site-footer__cta, .screen-reader-text { 
    display: none !important; 
  }

  /* Images scale nicely */
  img, svg, video, figure { 
    max-width: 100% !important; 
    height: auto !important; 
  }

  /* Avoid splitting key blocks across pages */
  h1, h2, h3, h4, h5, h6, 
  figure, table, pre, code, blockquote, ul, ol, p {
    page-break-inside: avoid;
  }

  /* Add some margins to the printed page */
  @page { 
    margin: 12mm; /* users can still override in dialog */
  }
}