/* Homepage PDF-only CTA */

.md-typeset .index-cover-cta {
  width: 100%;
  display: flex;
  justify-content: center;
  align-items: center;
}

.md-typeset .index-cover-cta a {
  margin: 0 auto;
}

/* Default: hidden online */
.md-typeset .index-cover-cta.pdf-only {
  display: none;
}

/* Print/PDF: visible and centered */
@media print {
  .md-typeset .index-cover-cta.pdf-only {
    display: flex !important;
    justify-content: center;
    align-items: center;
    width: 100%;
    margin-top: 1.2rem;
    margin-bottom: 0;
  }

  .md-typeset .index-cover-cta.pdf-only .map-cta {
    align-self: center;
    margin: 0 auto;
  }

  /* Keep headings as plain text blocks in browser-generated PDFs. */
  .md-typeset :is(h1, h2, h3, h4) {
    position: static !important;
    padding-right: 0 !important;
    overflow: visible !important;
    transform: none !important;
    filter: none !important;
    backdrop-filter: none !important;
    mix-blend-mode: normal !important;
    contain: none !important;
    will-change: auto !important;
  }

  .md-typeset :is(h1, h2, h3, h4) :is(.headerlink, a.headerlink) {
    display: none !important;
  }

  .md-typeset :is(h1, h2, h3, h4)::before,
  .md-typeset :is(h1, h2, h3, h4)::after {
    content: none !important;
  }

  /* Simplify admonition chrome so title and body remain selectable text in PDFs.
     Keep the index cover untouched because it is implemented as a cover admonition. */
  .md-typeset :is(.admonition, details):not(.cover) {
    display: block !important;
    overflow: visible !important;
    transform: none !important;
    filter: none !important;
    backdrop-filter: none !important;
    mix-blend-mode: normal !important;
    contain: none !important;
    will-change: auto !important;
    box-shadow: none !important;
  }

  .md-typeset :is(.admonition, details):not(.cover) > :is(.admonition-title, summary) {
    display: block !important;
    position: static !important;
    padding: 0 !important;
    margin: 0 0 0.5rem 0 !important;
    background: transparent !important;
    border: 0 !important;
    transform: none !important;
    filter: none !important;
    backdrop-filter: none !important;
    mix-blend-mode: normal !important;
    contain: none !important;
    will-change: auto !important;
  }

  .md-typeset :is(.admonition, details):not(.cover) > :is(.admonition-title, summary)::before,
  .md-typeset :is(.admonition, details):not(.cover) > :is(.admonition-title, summary)::after,
  .md-typeset details:not(.cover) > summary::-webkit-details-marker {
    content: none !important;
    display: none !important;
  }

  .md-typeset details:not(.cover) > summary {
    list-style: none !important;
  }

  /* Keep running text justified in print without changing cover or component chrome. */
  .md-typeset p {
    text-align: justify;
    text-justify: inter-word;
    hyphens: auto;
  }

  .md-typeset .cite-copy-btn {
    display: none !important;
  }
}