/* =============================================================
   Pardes Family Handbook 5787 / 2026-2027
   Self-contained handbook stylesheet. Reuses the sitewide
   editorial tokens (navy + forest green + gold, Montserrat /
   Lora / Frank Ruhl Libre) and adds a "designed in pages" book:
   a scroll document, a page-flip book view, and clean print.
   House rules honored: no em dashes, green <strong> highlights,
   tight whitespace, warm not corporate.
   ============================================================= */

:root {
  --navy: #343e85;
  --navy-deep: #1c2350;
  --green: #10653c;
  --green-deep: #0a4a2b;
  --green-br: #1c8a55;
  --brown: #7a5230;
  --gold: #b88a3a;
  --gold-deep: #9a6a00;
  --alert: #b3261e;
  --alert-tint: #fbeceb;

  --paper: #ffffff;
  --off: #f8f4ed;
  --cream: #f8f4ed;
  --ink: #23263e;
  --body: #474b63;
  --muted: #7c809a;
  --line: #e7e8f1;
  --navy-tint: #edeefb;
  --green-tint: #e7f1ea;
  --gold-tint: #f6efe1;

  --deskbg: #e8eaf1;      /* neutral backdrop so white sheets read as pages */
  --sheet-w: 850px;
  --radius: 16px;
  --shadow-soft: 0 16px 40px rgba(16, 22, 52, 0.10);
  --shadow-card: 0 6px 18px rgba(16, 22, 52, 0.06);
  --shadow-sheet: 0 24px 60px rgba(16, 22, 52, 0.16);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
:root { color-scheme: light; }
/* jump targets clear the sticky toolbar */
[id] { scroll-margin-top: 74px; }
/* skip link for keyboard and screen-reader users */
.skip-link { position: absolute; left: -999px; top: 0; z-index: 100; background: var(--navy); color: #fff;
  padding: 10px 16px; border-radius: 0 0 10px 0; font-family: 'Montserrat', sans-serif; font-weight: 700; font-size: 13px; }
.skip-link:focus { left: 0; }
::selection { background: #d9eae0; color: var(--green-deep); }
a:focus-visible, button:focus-visible, summary:focus-visible {
  outline: 2px solid var(--green); outline-offset: 3px; border-radius: 4px;
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--deskbg);
  color: var(--body);
  font-family: 'Lora', Georgia, serif;
  font-size: 17px;
  line-height: 1.62;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; display: block; }
.mont { font-family: 'Montserrat', Arial, sans-serif; }
.heb { font-family: 'Frank Ruhl Libre', serif; }
a { color: var(--green); text-decoration: none; }
p { margin: 0 0 15px; }
strong { color: var(--green-deep); }

/* -------- typography niceties: no awkward line breaks -------- */
a[href^="tel:"] { white-space: nowrap; }                 /* phone numbers stay whole */
.hb-page p, .hb-page li, .callout p, .lead { text-wrap: pretty; } /* fewer widows/orphans */
.hb-page a[href^="mailto:"], .hb-page a[href^="http"] { overflow-wrap: anywhere; } /* long addresses never overflow */
.nb { white-space: nowrap; }                              /* explicit "keep together" hook */

/* =========================================================
   TOP BAR (site-like chrome)
   ========================================================= */
.hb-bar {
  position: sticky; top: 0; z-index: 60;
  background: #fff; border-bottom: 1px solid var(--line);
}
.hb-bar__accent { height: 4px; background: linear-gradient(90deg, var(--navy) 0%, var(--green) 55%, var(--gold) 100%); }
.hb-bar__inner {
  max-width: 1180px; margin: 0 auto; padding: 10px 20px;
  display: flex; align-items: center; gap: 16px; justify-content: space-between;
}
.hb-brand { display: flex; align-items: center; gap: 11px; min-width: 0; text-decoration: none; }
.hb-brand img { height: 38px; width: auto; }
.hb-brand .bt { display: flex; flex-direction: column; line-height: 1.05; min-width: 0; }
.hb-brand .b1 { font-family: 'Montserrat', sans-serif; font-weight: 800; color: var(--navy); font-size: 15px; letter-spacing: -0.01em; }
.hb-brand .b1 .sl { color: var(--green); }
.hb-brand .b2 { font-family: 'Montserrat', sans-serif; font-weight: 600; color: var(--muted); font-size: 8px; letter-spacing: 0.16em; text-transform: uppercase; margin-top: 3px; }
.hb-tools { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.hb-btn {
  display: inline-flex; align-items: center; gap: 7px; cursor: pointer;
  font-family: 'Montserrat', sans-serif; font-weight: 700; font-size: 13px;
  padding: 9px 14px; border-radius: 10px; border: 1.5px solid var(--line);
  background: #fff; color: var(--navy); transition: background .15s, border-color .15s, color .15s;
  white-space: nowrap;
}
.hb-btn:hover { background: var(--navy-tint); border-color: #c9ccec; }
.hb-btn svg { width: 15px; height: 15px; }
.hb-btn--primary { background: var(--green); border-color: var(--green); color: #fff; box-shadow: 0 8px 20px rgba(16,101,60,.22); }
.hb-btn--primary:hover { background: var(--green-deep); border-color: var(--green-deep); color: #fff; }
.hb-btn[hidden] { display: none; }
.hb-tools .lbl-2 { display: none; }

/* =========================================================
   READING AREA + PAGE SHEETS
   ========================================================= */
.hb-doc { max-width: calc(var(--sheet-w) + 80px); margin: 0 auto; padding: 34px 20px 80px; }
.hb-page {
  position: relative; background: #fff; width: 100%; max-width: var(--sheet-w);
  margin: 0 auto 30px; border-radius: 14px; box-shadow: var(--shadow-sheet);
  border: 1px solid var(--line);
  padding: 58px 62px 72px; overflow: hidden;
}
.hb-page__folio {
  position: absolute; left: 66px; right: 66px; bottom: 26px;
  display: flex; align-items: center; justify-content: space-between;
  font-family: 'Montserrat', sans-serif; font-size: 10px; letter-spacing: .12em;
  text-transform: uppercase; color: #565b76; border-top: 1px solid var(--line);
  padding-top: 12px;
}
.hb-page__folio .n { font-weight: 700; color: var(--navy); }

/* section header with big faint chapter numeral */
.hb-head { position: relative; margin-bottom: 22px; }
.hb-head__num {
  position: absolute; right: -6px; top: -26px; font-family: 'Montserrat', sans-serif;
  font-weight: 800; font-size: 96px; line-height: 1; color: var(--green);
  opacity: .07; letter-spacing: -0.03em; pointer-events: none; user-select: none;
}
.eyebrow {
  font-family: 'Montserrat', sans-serif; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.16em; font-size: 11px; color: var(--green); margin: 0 0 11px;
  display: inline-flex; align-items: center; gap: 9px;
}
.eyebrow .sqs { display: inline-flex; gap: 3px; }
.eyebrow .sqs i { width: 8px; height: 8px; border-radius: 2px; display: block; }
.eyebrow .sqs i:nth-child(1) { background: var(--navy); }
.eyebrow .sqs i:nth-child(2) { background: var(--green); }
.eyebrow .sqs i:nth-child(3) { background: var(--gold); }
.hb-head h1, .hb-head h2.sh {
  font-family: 'Montserrat', sans-serif; font-weight: 800; color: var(--navy);
  font-size: clamp(27px, 3.4vw, 36px); line-height: 1.1; letter-spacing: -0.02em;
  margin: 0; text-wrap: balance;
}
.hb-head h1 em, .hb-head h2.sh em { font-family: 'Lora', serif; font-style: italic; font-weight: 500; color: var(--green); }
.rule { width: 46px; height: 3px; border-radius: 3px; background: var(--green); margin: 15px 0 0; }

/* body typography inside a page */
.hb-page h2 { font-family: 'Montserrat', sans-serif; font-weight: 800; color: var(--navy); font-size: 20px; margin: 30px 0 10px; letter-spacing: -0.01em; }
.hb-page h3 { font-family: 'Montserrat', sans-serif; font-weight: 700; color: var(--ink); font-size: 16px; margin: 20px 0 6px; }
.lead { font-size: 18.5px; color: var(--ink); line-height: 1.55; }
.prose p { margin: 0 0 13px; }
.muted { color: var(--muted); }
.tiny { font-size: 13px; }
/* Shown only in the printed / PDF version (e.g. the signature page) */
.print-only { display: none !important; }

/* label chip (health topics, section tags) */
.chip {
  display: inline-block; font-family: 'Montserrat', sans-serif; font-weight: 700;
  font-size: 12px; letter-spacing: .04em; color: #fff; background: var(--green);
  padding: 5px 12px; border-radius: 8px; margin: 0 0 8px;
}
.chip--navy { background: var(--navy); }
.chip--gold { background: var(--gold-deep); }
/* chip used as a real subsection heading (h3) so the document outline is correct */
h3.chip { display: inline-block; font-family: 'Montserrat', sans-serif; font-weight: 700; font-size: 12px;
  letter-spacing: .04em; color: #fff; background: var(--green); padding: 5px 12px; border-radius: 8px;
  margin: 16px 0 8px; line-height: 1.3; }
h3.chip.chip--navy { background: var(--navy); }
h3.chip.chip--gold { background: var(--gold-deep); }

/* pull quote */
.pull {
  font-family: 'Lora', serif; font-style: italic; font-size: clamp(18px, 2.2vw, 22px);
  line-height: 1.4; color: var(--navy); border-left: 3px solid var(--green);
  padding: 2px 0 2px 20px; margin: 20px 0;
}

/* =========================================================
   CALLOUT BOXES
   ========================================================= */
.callout {
  border-radius: 14px; padding: 19px 24px; margin: 20px 0; background: var(--off);
}
.callout__t {
  font-family: 'Montserrat', sans-serif; font-weight: 800; font-size: 12.5px;
  letter-spacing: .07em; text-transform: uppercase; color: var(--green-deep);
  margin: 0 0 9px; display: flex; align-items: center; gap: 9px;
}
.callout__t svg { width: 17px; height: 17px; flex: 0 0 auto; color: var(--green); }
.callout p { margin: 0 0 8px; font-size: 15.5px; }
.callout p:last-child { margin-bottom: 0; }
.callout ul { margin: 6px 0 0; padding-left: 18px; }
.callout--info { background: var(--green-tint); }
.callout--info .callout__t, .callout--info .callout__t svg { color: var(--green-deep); }
.callout--important { background: var(--gold-tint); }
.callout--important .callout__t, .callout--important .callout__t svg { color: var(--gold-deep); }
.callout--alert { background: var(--alert-tint); }
.callout--alert .callout__t, .callout--alert .callout__t svg { color: var(--alert); }
.callout--navy { background: var(--navy-tint); }
.callout--navy .callout__t, .callout--navy .callout__t svg { color: var(--navy); }

/* section body lists + draft placeholders (used by the staff handbook) */
.hb-page ul.hb-ul { margin: 8px 0 14px; padding-left: 22px; }
.hb-page ul.hb-ul li { margin-bottom: 6px; font-size: 15.5px; }
.hb-page ol.hb-ol { margin: 8px 0 14px; padding-left: 24px; }
.hb-page ol.hb-ol li { margin-bottom: 7px; font-size: 15.5px; padding-left: 3px; }
.flagnote { display: block; background: var(--gold-tint); border-radius: 10px; padding: 10px 14px; margin: 12px 0; font-family: 'Montserrat', sans-serif; font-size: 12.5px; line-height: 1.45; color: var(--gold-deep); }
.flagnote b { font-weight: 800; letter-spacing: .05em; text-transform: uppercase; font-size: 10.5px; display: block; margin-bottom: 3px; }
.todo { background: #fdefc7; border-radius: 4px; padding: 0 5px; color: #7a5a12; font-style: normal; }

/* =========================================================
   QUICK-FACT GRID + CHIPS
   ========================================================= */
.facts { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; margin: 18px 0; }
.fact {
  background: var(--off); border: 1px solid var(--line); border-radius: 12px;
  padding: 14px 16px; display: flex; align-items: center; gap: 13px;
}
.fact__ic { flex: 0 0 auto; width: 34px; height: 34px; border-radius: 9px; background: #fff; border: 1px solid var(--line);
  display: flex; align-items: center; justify-content: center; color: var(--green); }
.fact__ic svg { width: 18px; height: 18px; }
.fact > span:last-child { display: block; min-width: 0; }
.fact__k { display: block; font-family: 'Montserrat', sans-serif; font-size: 10.5px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.fact__v { display: block; font-family: 'Montserrat', sans-serif; font-size: 16px; font-weight: 800; color: var(--navy); line-height: 1.2; margin-top: 2px; }
.fact__v small { font-weight: 600; font-size: 12.5px; color: var(--body); }

/* =========================================================
   MINI CARDS + TWO-COLUMN LISTS
   ========================================================= */
.cards { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; margin: 18px 0; }
.card {
  background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 18px 20px;
  box-shadow: var(--shadow-card);
}
.card .lab { font-family: 'Montserrat', sans-serif; font-weight: 700; font-size: 10.5px; letter-spacing: .12em; text-transform: uppercase; color: var(--gold-deep); margin-bottom: 7px; display: block; }
.card h3 { font-family: 'Montserrat', sans-serif; font-weight: 800; color: var(--navy); font-size: 17px; margin: 0 0 6px; }
.card p { font-size: 15px; margin: 0; }

.two { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin: 18px 0; }
.col-h {
  font-family: 'Montserrat', sans-serif; font-weight: 800; font-size: 13px; color: #fff;
  background: var(--green); padding: 8px 14px; border-radius: 9px; display: inline-block; margin-bottom: 12px;
}
.col-h--navy { background: var(--navy); }
.ticks { list-style: none; margin: 0; padding: 0; }
.ticks li { position: relative; padding: 0 0 9px 26px; font-size: 15.5px; color: var(--body); }
.ticks li::before {
  content: ""; position: absolute; left: 2px; top: 8px; width: 8px; height: 4px;
  border-left: 2px solid var(--green); border-bottom: 2px solid var(--green);
  transform: rotate(-45deg);
}

/* illness / topic rows: bold chip + text */
.rows { margin: 16px 0; }
.row { padding: 14px 0; border-bottom: 1px solid var(--line); display: grid; grid-template-columns: 150px 1fr; gap: 18px; align-items: start; }
.row:last-child { border-bottom: none; }
.row__k { font-family: 'Montserrat', sans-serif; font-weight: 800; font-size: 13.5px; color: var(--green-deep); letter-spacing: .02em; padding-top: 1px; }
.row__v { font-size: 15px; }
.row__v p { margin: 0 0 7px; }
.row__v p:last-child { margin: 0; }
.row__v ul { margin: 4px 0 0; padding-left: 18px; }
.row__v li { margin-bottom: 4px; }

/* numbered steps */
.steps { display: grid; gap: 10px; margin: 16px 0; }
ol.steps { list-style: none; padding: 0; }
.step { display: flex; gap: 14px; align-items: flex-start; background: var(--off); border: 1px solid var(--line); border-radius: 12px; padding: 13px 16px; }
.step .no { flex: 0 0 auto; width: 30px; height: 30px; border-radius: 9px; background: var(--green-tint); color: var(--green-deep); font-family: 'Montserrat', sans-serif; font-weight: 800; font-size: 14px; display: flex; align-items: center; justify-content: center; }
.step p { margin: 3px 0 0; font-size: 15px; }

/* tuition table */
.ttable { width: 100%; border-collapse: collapse; margin: 6px 0 4px; }
.ttable thead th { text-align: left; padding: 8px 10px 8px 0; font-family: 'Montserrat', sans-serif; font-weight: 800; font-size: 10.5px; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); border-bottom: 1px solid var(--line); }
.ttable thead th:last-child { text-align: right; }
.ttable th[scope="row"] { text-align: left; padding: 11px 14px 11px 0; font-family: 'Lora', Georgia, serif; font-weight: 400; font-size: 15px; color: var(--body); border-bottom: 1px solid var(--line); vertical-align: top; }
.ttable td { padding: 11px 0; font-size: 15px; color: var(--body); border-bottom: 1px solid var(--line); vertical-align: top; }
.ttable td:last-child { text-align: right; font-family: 'Montserrat', sans-serif; font-weight: 700; color: var(--navy); }
.ttable tr:last-child td, .ttable tr:last-child th[scope="row"] { border-bottom: none; }

/* =========================================================
   PHOTOS
   ========================================================= */
.photo { border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow-soft); position: relative; margin: 18px 0; }
.photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.photo--wide { aspect-ratio: 16 / 8; }
.photo--tall { aspect-ratio: 3 / 4; }
.photo--sq { aspect-ratio: 1 / 1; }
.photo .cap {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 26px 16px 12px;
  font-family: 'Montserrat', sans-serif; font-weight: 600; font-size: 12px; color: #fff;
  background: linear-gradient(to top, rgba(10,14,34,.82), transparent);
}
.photo .tagchip {
  position: absolute; left: 14px; top: 14px; font-family: 'Montserrat', sans-serif; font-weight: 700;
  font-size: 10.5px; letter-spacing: .06em; text-transform: uppercase; color: #fff;
  background: rgba(16,101,60,.92); padding: 6px 12px; border-radius: 8px;
}
.duo { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin: 18px 0; }
.duo .photo { margin: 0; }
figure { margin: 0; }

/* =========================================================
   COVER + BACK COVER
   ========================================================= */
.hb-page--cover, .hb-page--back {
  min-height: min(78vh, 900px); display: flex; flex-direction: column;
  align-items: center; justify-content: center; text-align: center; padding: 64px 56px;
}
.hb-page--cover { background: radial-gradient(120% 90% at 50% 0%, #ffffff 60%, #f4f6fb 100%); }
.cover-bsd { position: absolute; top: 22px; right: 26px; font-family: 'Frank Ruhl Libre', serif; font-size: 15px; color: var(--muted); }
.cover-logo { width: 190px; margin: 0 auto 6px; }
.cover-kicker { font-family: 'Montserrat', sans-serif; font-weight: 700; letter-spacing: .22em; text-transform: uppercase; font-size: 12px; color: var(--green); margin: 20px 0 6px; text-wrap: balance; }
.cover-kicker .nb { white-space: nowrap; }
.cover-title { font-family: 'Montserrat', sans-serif; font-weight: 800; color: var(--navy); font-size: clamp(40px, 7vw, 66px); line-height: .98; letter-spacing: -0.03em; margin: 4px 0 18px; }
.cover-rule { width: 66px; height: 4px; border-radius: 4px; background: linear-gradient(90deg, var(--green), var(--gold)); margin: 0 auto 20px; }
.cover-tag { font-family: 'Lora', serif; font-style: italic; font-size: 19px; color: var(--body); max-width: 34ch; margin: 0 auto 26px; line-height: 1.5; }
.cover-year { font-family: 'Montserrat', sans-serif; font-weight: 800; letter-spacing: .06em; color: var(--green-deep); font-size: 17px; }
.cover-year .heb { color: var(--gold-deep); }

.hb-page--back { background: var(--navy-deep); color: #c7ccef; }
.hb-page--back .back-logo { width: 116px; margin: 0 auto 24px; background: #fff; padding: 15px; border-radius: 20px; box-shadow: 0 12px 34px rgba(0,0,0,.28); }
.hb-page--back .back-logo img { width: 100%; height: auto; display: block; }
.hb-page--back h2 { color: #fff; font-size: 24px; margin: 0 0 8px; letter-spacing: -0.01em; }
.hb-page--back .back-line { font-family: 'Lora', serif; font-style: italic; font-size: 17px; color: #aab0e0; margin: 0 auto 28px; max-width: 40ch; }
.back-contact { display: grid; gap: 11px; font-family: 'Montserrat', sans-serif; font-size: 14px; color: #dfe2f6; line-height: 1.4; }
.back-contact strong { color: #8fe0b4; font-weight: 700; margin-right: 6px; }
.back-contact a { color: #cfe0ff; }
.back-campus { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; margin: 20px auto 0; max-width: 480px; }
.back-campus div { background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.12); border-radius: 12px; padding: 14px; text-align: left; }
.back-campus .cn { font-family: 'Montserrat', sans-serif; font-weight: 800; font-size: 12px; letter-spacing: .08em; text-transform: uppercase; color: #8fe0b4; margin-bottom: 5px; }
.back-campus .ca { font-size: 13px; color: #c7ccef; line-height: 1.5; }

/* =========================================================
   CONTENTS PAGE
   ========================================================= */
.hb-toc { list-style: none; margin: 22px 0 0; padding: 0; column-count: 2; column-gap: 40px; }
.hb-toc li { break-inside: avoid; margin-bottom: 2px; }
.hb-toc a {
  display: flex; align-items: baseline; gap: 12px; padding: 9px 6px; border-radius: 8px;
  color: var(--ink); transition: background .14s;
}
.hb-toc a:hover { background: var(--green-tint); }
.hb-toc .tn { font-family: 'Montserrat', sans-serif; font-weight: 800; font-size: 13px; color: var(--green); width: 24px; flex: 0 0 auto; }
.hb-toc .tt { font-family: 'Montserrat', sans-serif; font-weight: 600; font-size: 14.5px; letter-spacing: .01em; }
.hb-toc .tdot { flex: 1; border-bottom: 1px dotted #cfd2e6; transform: translateY(-3px); }

/* acknowledgment / signature page */
.sig { margin-top: 18px; }
.sig-line { display: grid; grid-template-columns: 1fr 150px; gap: 24px; margin-top: 26px; }
.sig-field { border-bottom: 1.5px solid var(--navy); height: 34px; }
.sig-cap { font-family: 'Montserrat', sans-serif; font-size: 11px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin-top: 6px; }
.ack-list { margin: 14px 0; padding: 0; list-style: none; }
.ack-list li { position: relative; padding: 8px 0 8px 30px; border-bottom: 1px solid var(--line); font-size: 15px; }
.ack-list li::before { content: ""; position: absolute; left: 3px; top: 12px; width: 14px; height: 14px; border: 1.5px solid var(--green); border-radius: 4px; }

/* =========================================================
   REVEAL
   ========================================================= */
/* Reveal is now a no-op: policy content is never hidden, so a long contents
   jump can never land on blank or faint text. Class kept as a harmless hook. */
.reveal { }

/* =========================================================
   RESPONSIVE
   ========================================================= */
@media (max-width: 760px) {
  body { font-size: 16px; }
  .cover-kicker { letter-spacing: .12em; font-size: 10.5px; }
  .hb-page { padding: 34px 22px 60px; border-radius: 10px; }
  .hb-page__folio { left: 22px; right: 22px; }
  .hb-head__num { font-size: 66px; top: -16px; right: -2px; }
  .facts, .cards, .two, .duo, .sig-line, .back-campus { grid-template-columns: 1fr; }
  .row { grid-template-columns: 1fr; gap: 4px; }
  .row__k { color: var(--green-deep); }
  .hb-toc { column-count: 1; }
  .hb-tools .lbl-1 { display: none; }
  .hb-tools .lbl-2 { display: inline; }
  .hb-brand .b2 { display: none; }
}
@media (max-width: 420px) {
  .hb-brand .b1 { font-size: 13px; }
  .hb-btn { padding: 8px 11px; font-size: 12px; }
}

/* =========================================================
   PRINT  ->  clean paginated PDF
   ========================================================= */
@media print {
  @page { size: Letter; margin: 15mm 16mm; }
  html { scroll-behavior: auto; }
  body { background: #fff; color: #1a1c2b; font-size: 10.8pt; line-height: 1.48; }
  .hb-bar, .no-print { display: none !important; }
  .print-only { display: block !important; }
  .hb-doc { max-width: none; margin: 0; padding: 0; }

  /* Flatten the on-screen "sheets" into ONE continuous flowing document.
     The old rule forced a page break after every sheet, so each short sheet
     ate a whole page and the PDF was mostly white space. Now content flows and
     fills each page; page breaks happen naturally, blocks below stay whole. */
  .hb-page {
    position: static; box-shadow: none; border: 0; border-radius: 0;
    margin: 0; padding: 0 0 3mm; max-width: none; width: 100%;
    overflow: visible; min-height: 0;
    break-before: auto; break-after: auto; break-inside: auto;
  }
  .hb-head__num { display: none; }     /* decorative chapter numeral */
  .hb-page__folio { display: none; }   /* per-sheet page numbers are wrong once flowing */

  /* "Continued" sheets rejoin their section: drop the repeated header. */
  .hb-page--cont { padding-top: 0; }
  .hb-page--cont > .hb-head { display: none; }

  /* Only the cover, back, and signature pages own a full page. The contents
     flows straight into section 1 so no half-empty page is wasted after it. */
  .hb-page--cover { min-height: 234mm; break-after: page; padding: 0; }
  .hb-page--back { min-height: 234mm; break-before: page; padding: 0; background: var(--navy-deep) !important; }
  .hb-page.print-only { break-before: page; }
  /* keep the table of contents compact and 2-up so it doesn't run long */
  .hb-toc { column-count: 2; column-gap: 12mm; margin-top: 3mm; }
  .hb-toc a { padding: 2.4mm 2mm; }
  .hb-toc .tt { font-size: 10.5pt; }

  /* section headers: tighter, sized in pt, kept with their following content */
  .hb-head { margin: 3mm 0 2.5mm; break-inside: avoid; break-after: avoid; }
  .hb-head h1, .hb-head h2.sh { font-size: 17pt; }
  .hb-page h2 { font-size: 12.5pt; margin: 4.5mm 0 1.5mm; }
  .hb-page h3 { font-size: 11pt; }
  h1, h2, h3, h4 { break-after: avoid; break-inside: avoid; }

  /* photos never balloon in the PDF */
  .photo { aspect-ratio: auto !important; max-height: 60mm; margin: 3mm 0; }
  .photo img { width: 100%; height: 60mm; object-fit: cover; }
  .photo--sq, .photo--tall, .duo .photo { max-height: 56mm; }
  .photo--sq img, .photo--tall img, .duo .photo img { height: 56mm; }

  /* color fidelity for the tinted panels, chips, cover, back */
  .hb-page--cover, .hb-page--back, .callout, .fact, .card, .step, .chip, h3.chip,
  .col-h, .photo, .photo .cap, .tagchip, .back-campus div, .rule, .cover-rule {
    -webkit-print-color-adjust: exact; print-color-adjust: exact;
  }

  a { color: var(--ink); text-decoration: none; }
  .reveal { opacity: 1 !important; transform: none !important; }
  p { orphans: 3; widows: 3; margin: 0 0 2.4mm; }
  .callout { margin: 3mm 0; padding: 3.5mm 5mm; }
  .callout p { font-size: 10.4pt; }
  .hb-page ul.hb-ul, .hb-page ol.hb-ol { margin: 2mm 0 3mm; }
  .hb-page ul.hb-ul li, .hb-page ol.hb-ol li { font-size: 10.6pt; margin-bottom: 1.6mm; }

  /* keep atomic blocks from splitting mid-way across a page break */
  .callout, .photo, figure, .fact, .card, .row, .step, .pull,
  ul.hb-ul li, ol.hb-ol li, .ticks li, .ack-list li,
  .sig-line, .hb-toc li { break-inside: avoid; }
  .ttable tr { break-inside: avoid; }
  thead { display: table-header-group; }
}
