/* ============================================
   PRINT
   ============================================
   Enqueued as media="print" (functions.php), so nothing here needs an
   @media print wrapper — the whole file only ever applies on paper.

   This is the ONLY print stylesheet in the theme. It replaces three older,
   uncoordinated @media print blocks that lived in play.css, skit.css and
   theme.css; because each only knew about the chrome that existed when it
   was written, the floating Donate widget printed on every page and the
   nav/hero/footer were never hidden anywhere except on plays and skits.
   Add new chrome to the one list below.

   House style: .play-* and .skit-* are parallel families that share no
   class, so every rule that touches one needs its twin.
   ============================================ */

@page {
    size: letter;
    margin: 18mm 16mm 20mm;
}

/* --------------------------------------------
   1. Site chrome — nothing here belongs on paper
   -------------------------------------------- */
.nav,
.nav-hamburger,
.nav-links,
.nav-right,
.nav-search-toggle,
.nav-search-form,
.hero,
.footer,
.donate-widget,
.next-steps-home,
.next-steps-bar,
.play-toolbar,
.skit-toolbar,
.guide-toolbar,
.drive-audio-embed,
.section-label-toggle,
dialog,
.cj-guide-modal,
.mentor-modal,
/* WordPress core ships no print rule for its own toolbar, so a logged-in
   editor printing a script gets the black admin bar across the top of
   page one. Hide it here; nothing else will. */
#wpadminbar {
    display: none !important;
}

/* Core reserves room for that toolbar with a scroll-padding custom property
   and a body offset; with the bar hidden the gap would print as blank space. */
html.wp-toolbar {
    padding-top: 0 !important;
}

/* The ?labels dev tool draws its badges with a pseudo-element, so hiding
   .section-label-toggle alone would still leave the badges on the page. */
body.show-section-labels [data-section-label]::before {
    display: none !important;
}

/* --------------------------------------------
   2. The page shell
   -------------------------------------------- */
body {
    background: #fff;
    color: #000;
}

/* .content-body is a floating card that overlaps the hero by -180px.
   With the hero gone that margin would drag the content off the top of
   the first sheet. */
.content-body,
.content-body.no-hero {
    position: static;
    max-width: none;
    margin: 0;
    padding: 0;
    background: none;
    border-radius: 0;
    box-shadow: none;
}

a {
    color: #000;
    text-decoration: none;
}

/* --------------------------------------------
   3. Ink-frugal: no panel fills or tints
   --------------------------------------------
   Every one of these is a #f7f5f2 / #faf8f5 filled box on screen. On a
   mono printer the tints come out as muddy grey and on a colour one they
   are simply expensive, so each panel keeps its shape via a hairline rule
   instead of a fill. */
.play-quick-facts,
.skit-quick-facts,
.play-prep-card,
.skit-prep-card,
.play-tag,
.skit-tag {
    background: none !important;
    border: 0;
    border-radius: 0;
    padding: 0;
}

.play-quick-facts,
.skit-quick-facts {
    padding: 0.5rem 0;
    border-top: 1px solid #999;
    border-bottom: 1px solid #999;
}

.play-prep-card,
.skit-prep-card {
    padding-top: 0.5rem;
    border-top: 1px solid #ccc;
}

.play-classification,
.skit-classification {
    gap: 1rem;
}

.play-tag,
.skit-tag {
    margin-right: 1rem;
}

.play-prayer blockquote,
.skit-prayer blockquote {
    background: none;
    border-left: 2px solid #999;
}

.entry-content .wp-block-separator,
.single-cj_play .content-body .wp-block-separator,
.single-cj_skit .content-body .wp-block-separator {
    border-top-color: #999;
}

/* --------------------------------------------
   4. Pagination
   --------------------------------------------
   The theme had no break control at all before this, so a cast list or a
   props card could be cut in half by a page boundary. */
h1, h2, h3, h4, h5, h6 {
    page-break-after: avoid;
    break-after: avoid;
}

p, li, blockquote {
    orphans: 3;
    widows: 3;
}

.play-quick-facts,
.skit-quick-facts,
.play-prep-card,
.skit-prep-card,
.play-prayer,
.skit-prayer,
.play-dialogue,
.play-characters li,
.skit-characters li,
.play-questions li,
.skit-questions li {
    page-break-inside: avoid;
    break-inside: avoid;
}

/* --------------------------------------------
   5. Light-on-dark panels
   --------------------------------------------
   Browsers do not print background colours unless the reader ticks
   "Background graphics", which is off by default. Any panel that gets its
   contrast from a dark fill therefore prints as near-white text on white
   paper — blank, not merely ugly. Force those back to ink on white.

   This is a legibility floor, not a restyle: the rest of each block keeps
   its screen design. Only .play-*/.skit-* get the full ink-frugal treatment
   above, because those are the pages people actually print. */
.crisis-strip,
.crisis-strip h2,
.crisis-strip .crisis-eyebrow,
.harvard-callout,
.harvard-callout blockquote,
.respond-top,
.respond-top h2,
.versus-card--serving,
.stats-strip {
    background: none !important;
    color: #000 !important;
    border: 0;
}

/* Their descendants inherit the light colour explicitly, so reset those too. */
.crisis-strip *,
.harvard-callout *,
.respond-top *,
.versus-card--serving *,
.stats-strip * {
    color: #000 !important;
}
