@media print {
  /* ==========================================================================
     1. Page Setup & Running Headers/Footers
     ========================================================================== */
  @page {
    size: letter;
    margin: 0.8in 0.6in 0.8in 0.6in;
    
    /* Native CSS Paged Media headers and footers */
    @top-left {
      content: "Twelve Tribes — twelvetribes.org";
      font-family: 'Cormorant', 'Cormorant Garamond', serif;
      font-size: 9pt;
      color: #444;
      border-bottom: 0.5pt solid #ccc;
      padding-bottom: 3px;
    }
    @top-right {
      /* Dynamic print date generation where supported by browser engine */
      content: date(today); 
      font-family: 'Charter', serif;
      font-size: 9pt;
      color: #666;
      border-bottom: 0.5pt solid #ccc;
      padding-bottom: 3px;
    }
    @bottom-left {
      content: "Source: " url();
      font-family: 'Charter', serif;
      font-size: 8pt;
      color: #666;
    }
    @bottom-right {
      content: "Page " counter(page) " of " counter(pages);
      font-family: 'Charter', serif;
      font-size: 9pt;
      color: #444;
    }
  }

  /* ==========================================================================
     2. Global Structural Erasures & Layout
     ========================================================================== */
  /* Hide all generic theme architecture, images, and backgrounds */
  header, 
  footer, 
  nav, 
  aside, 
  .region-sidebar-first, 
  .region-sidebar-second,
  .breadcrumb, 
  .tabs, 
  .action-links,
  img, 
  svg, 
  picture, 
  figure, 
  video, 
  audio,
  .banner, 
  .slider {
    display: none !important;
    background: transparent !important;
  }

  /* Force background resets globally */
  * {
    background: transparent !important;
    color: #000 !important;
    box-shadow: none !important;
    text-shadow: none !important;
  }

  /* Centered, optimized reading pane (6.5 inches / ~60-70 characters per line) */
  body {
    background: #fff !important;
    margin: 0 auto !important;
    padding: 0 !important;
    width: 6.5in !important;
    max-width: 6.5in !important;
    float: none !important;
  }

  main, 
  #main-content, 
  .main-container, 
  article {
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    display: block !important;
    float: none !important;
  }

  /* ==========================================================================
     3. Global Typography & Justification
     ========================================================================== */
  body, p, li, td, th, span, div {
    font-family: 'Charter', 'Bitstream Charter', serif;
    font-size: 13pt;
    line-height: 1.6;
    text-align: left !important; /* Left justified */
  }

  /* Page Titles using Cormorant */
  h1, .page-title {
    font-family: 'cormorant', 'Cormorant Garamond', serif;
    font-size: 28pt;
    line-height: 1.2;
    margin-top: 0;
    margin-bottom: 18pt;
    text-align: left !important;
  }

  /* Heading modifications of the base Charter font */
  h2 {
    font-family: 'Charter', serif;
    font-size: 18pt;
    line-height: 1.3;
    margin-top: 24pt;
    margin-bottom: 12pt;
    page-break-after: avoid;
  }

  h3 {
    font-family: 'Charter', serif;
    font-size: 15pt;
    line-height: 1.3;
    margin-top: 18pt;
    margin-bottom: 8pt;
    page-break-after: avoid;
  }

  /* Base Lead-in styling across content-types */
  .field--name-field-leadin, 
  .field--name-field-lead-in, 
  .lead-in, 
  .leadin {
    font-family: 'Charter', serif;
    font-size: 15pt;
    line-height: 1.5;
    font-style: italic;
    margin-bottom: 18pt;
  }

  /* Append explicit URLs to body links so prints are useful */
  a[href]:not([href^="#"]):after {
    content: " (" attr(href) ")";
    font-size: 10pt;
    color: #444;
  }

  /* ==========================================================================
     4. Drupal 11 Content Type Specific Overrides
     ========================================================================== */
  
  /* --- ARTICLE / PAGE / WEBPAGE ---
     Hide: word count, read time, main image. Show: title, leadin, body. */
  .node--type-article,
  .node--type-page,
  .node--type-webpage {
    /* Hide specific meta-elements */
    .word-count,
    .reading-time,
    .field--name-field-word-count,
    .field--name-field-reading-time,
    .field--name-field-image,
    .field--name-field-main-image,
    .main-image-wrapper {
      display: none !important;
    }
    /* Ensure required components remain visible */
    .field--name-field-leadin,
    .field--name-body,
    h1 {
      display: block !important;
    }
  }

  /* --- COMMUNITY ---
     Show: address, phone, map. Hide: photo, wall. */
  .node--type-community {
    /* Ensure address fields, maps, and phone numbers print */
    .field--name-field-address,
    .field--name-field-phone,
    .field--name-field-map,
    .map-wrapper,
    .address-details {
      display: block !important;
    }
    /* Hide the visual community elements */
    .field--name-field-photo,
    .field--name-field-photos,
    .community-photos,
    .field--name-field-wall,
    .community-wall,
    .comments-wrapper {
      display: none !important;
    }
  }

  /* --- PUBLICATION ---
     Show: cover image, title, leadin. Override global image rule for covers. */
  .node--type-publication {
    /* Force the cover image to show up despite global img exclusions */
    img.field--name-field-cover-image,
    img.publication-cover,
    .field--name-field-cover-image img {
      display: block !important;
      max-width: 2.5in !important; /* Elegant shelf-size width for printed records */
      margin-bottom: 15pt;
    }
    .field--name-field-leadin,
    h1 {
      display: block !important;
    }
    /* Hide body or supplementary field elements */
    .field--name-body,
    .publication-body,
    .download-links {
      display: none !important;
    }
  }

  /* --- MEDIA, INTRODUCER, CTA, MUSIC, PODCAST ---
     Show only: title, leadin, url. Hide all else. */
  .node--type-media,
  .node--type-introducer,
  .node--type-cta,
  .node--type-music,
  .node--type-podcast {
    /* Hide all typical components, bodies, players, forms */
    .field--name-body,
    .field--name-field-file,
    .audio-player,
    .media-player,
    .cta-button,
    form,
    .field {
      display: none !important;
    }
    /* Re-expose explicitly allowed targets */
    h1,
    .field--name-field-leadin,
    .field--name-field-lead-in,
    .field--name-field-url,
    .field--name-field-link a {
      display: block !important;
    }
  }
}