/* Separate print candidate for the existing tribe_events archive. */
@media print {
  body.sat-visual-events #sat-main {
    inline-size: auto;
    max-inline-size: 100%;
    color: #000;
    background: #fff;
    font-size: 11pt;
    line-height: 1.45;
  }
  body.sat-visual-events #sat-main .sat-events-heading h1,
  body.sat-visual-events #sat-main .tribe-events-calendar-latest-past__heading {
    color: #000;
    break-after: avoid;
  }
  body.sat-visual-events #sat-main .tribe-events-calendar-latest-past__event-row {
    display: block;
    margin-inline: 0;
    padding-block: 12pt;
    border-top: 1px solid #aaa;
    break-inside: auto;
  }
  body.sat-visual-events #sat-main .tribe-events-calendar-latest-past__event-date-tag {
    inline-size: auto;
    padding: 4pt 0;
    border: 0;
    background: #fff;
    color: #000;
    text-align: start;
    break-inside: avoid;
    break-after: avoid;
  }
  body.sat-visual-events #sat-main .tribe-events-calendar-latest-past__event-date-tag-datetime {
    display: block;
  }
  body.sat-visual-events #sat-main .tribe-events-calendar-latest-past__event-wrapper {
    inline-size: auto;
    min-inline-size: 0;
    padding-inline: 0;
  }
  body.sat-visual-events #sat-main .tribe-events-calendar-latest-past__event,
  body.sat-visual-events #sat-main .tribe-events-calendar-latest-past__event.has-post-thumbnail {
    display: block;
    margin: 0;
    padding: 0;
    border: 0;
    border-radius: 0;
    background: #fff;
  }
  body.sat-visual-events #sat-main .tribe-events-calendar-latest-past__event-featured-image {
    display: block;
    max-inline-size: 100%;
    inline-size: auto;
    block-size: auto;
    object-fit: contain;
    break-inside: avoid;
  }
  body.sat-visual-events #sat-main .tribe-events-calendar-latest-past__event-title {
    margin-block: 6pt;
    color: #000;
    font-size: 14pt;
    line-height: 1.25;
    overflow-wrap: anywhere;
    break-after: avoid;
  }
  body.sat-visual-events #sat-main .tribe-events-calendar-latest-past__event-title-link {
    display: inline;
    min-block-size: 0;
    color: #000;
    text-decoration: underline;
  }
  body.sat-visual-events #sat-main .tribe-events-calendar-latest-past__event-details,
  body.sat-visual-events #sat-main .tribe-events-calendar-latest-past__event-datetime-wrapper,
  body.sat-visual-events #sat-main .tribe-events-calendar-latest-past__event-cost,
  body.sat-visual-events #sat-main .tribe-events-calendar-latest-past__event-venue {
    color: #000;
    orphans: 3;
    widows: 3;
  }
}

/* Calendar print: remove on-screen controls without changing consent. */
@media print {
  body.sat-visual-events #cookie-notice,
  body.sat-visual-events .sat-header .sat-mobile-toggle,
  body.sat-visual-events .sat-header #sat-primary-navigation,
  body.sat-visual-events .sat-header .sat-header-cta {
    display: none !important;
  }
}

/* Root: actual owner calendar PDF was A3 and split an event card. */
@media print {
  @page { size: A4 portrait; margin: 14mm; }
  body.sat-visual-events { min-width: 0 !important; margin: 0 !important; }
  body.sat-visual-events .sat-container { min-width: 0 !important; width: auto; max-width: none; padding-inline: 0; }
  body.sat-visual-events .sat-header { position: static !important; }
  body.sat-visual-events .sat-header-inner { padding-block: 0 4mm; }
  body.sat-visual-events .sat-brand img { width: 65mm; height: auto; }
  body.sat-visual-events .sat-events-heading { padding-block: 3mm; }
  body.sat-visual-events #sat-main .sat-events-content { padding: 0; border: 0; }
  body.sat-visual-events #sat-main .tribe-events { padding: 0; }
  body.sat-visual-events #sat-main .tribe-events-l-container { padding: 0; min-height: 0; }
  body.sat-visual-events #sat-main .tribe-events-calendar-latest-past__event-row { break-inside: avoid-page; page-break-inside: avoid; padding-block: 3mm; margin-block: 0 3mm; }
  body.sat-visual-events #sat-main .tribe-events-calendar-latest-past__event-featured-image { max-inline-size: 75mm; max-block-size: 35mm; inline-size: auto; block-size: auto; }
  body.sat-visual-events #sat-main .tribe-events-calendar-latest-past__event-featured-image-wrapper { inline-size: auto; block-size: auto; max-inline-size: 75mm; margin-block: 0 2mm; }
  body.sat-visual-events #sat-main .tribe-events-calendar-latest-past__event-description p { break-inside: avoid-page; }
  body.sat-visual-events .cn-revoke-cookie, body.sat-visual-events .grecaptcha-badge { display: none !important; }
  body.sat-visual-events #sat-main img[data-src="https://santeautravail.ch/wp-content/uploads/2021/11/Hotel-National-Bern-e1636101851774.jpg"] { content: url("https://santeautravail.ch/wp-content/uploads/2021/11/Hotel-National-Bern-e1636101851774.jpg"); }
  body.sat-visual-events #sat-main img[data-src="https://santeautravail.ch/wp-content/uploads/2023/02/banner_1265029411.jpg"] { content: url("https://santeautravail.ch/wp-content/uploads/2023/02/banner_1265029411.jpg"); }
  body.sat-visual-events .sat-footer { padding-block: 4mm; margin-top: 4mm; font-size: 9pt; break-inside: avoid-page; }
  body.sat-visual-events .sat-footer-grid { gap: 3mm 6mm; padding-block: 0; }
  body.sat-visual-events .sat-footer-bottom { padding-block: 3mm 0; margin-top: 3mm; }
}

/* Root: compact the complete footer to avoid its observed isolated third page. */
@media print {
  body.sat-visual-events .sat-footer { padding-block: 2mm; margin-top: 2mm; }
  body.sat-visual-events .sat-footer-grid { display: grid; grid-template-columns: 1fr 1fr 1.1fr; gap: 4mm; }
  body.sat-visual-events .sat-footer-grid > div { grid-column: auto; grid-row: auto; min-width: 0; }
  body.sat-visual-events .sat-footer :is(p,li,a,span) { font-size: 9pt !important; line-height: 1.3 !important; }
  body.sat-visual-events .sat-footer :is(p,ul) { margin-block: 0 2mm; padding: 0; }
  body.sat-visual-events .sat-footer h2 { font-size: 10pt !important; line-height: 1.3 !important; margin-block: 0 2mm; }
  body.sat-visual-events .sat-footer li { margin: 0 0 1mm; }
  body.sat-visual-events .sat-footer-bottom { display: flex; justify-content: space-between; gap: 3mm; padding-block: 2mm 0; margin-top: 2mm; }
}

/* Root: the responsive shell spans its first footer item across all columns. */
@media print {
  body.sat-visual-events .sat-footer-grid > :first-child { grid-column: auto !important; grid-row: auto !important; }
}
