/* TSE inner pages on the Concept D design (loaded after d.css on every layout-d page).
   Tokens come from d.css :root. Mobile first. Each block below is a different way to present content,
   so a page can vary its sections (Dan's rule: no section type twice on one page). */

/* ---------- page hero: photo, scrim, breadcrumb, H1, lead, actions, fact ledger ---------- */
.phero { position: relative; isolation: isolate; overflow: hidden; background: var(--em-950); color: #fff; }
.phero__bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 50%; z-index: -2; }
.phero__scrim { position: absolute; inset: 0; z-index: -1;
  background: linear-gradient(180deg, rgba(var(--scrim), .72) 0%, rgba(var(--scrim), .78) 40%, rgba(var(--scrim), .93) 100%); }
.phero__inner { position: relative; max-width: calc(var(--max) + var(--gutter) * 2); margin-inline: auto;
  padding: calc(var(--hdr-h) + 28px) var(--gutter) calc(var(--roof-h) + 44px); display: grid; gap: var(--s5); }
.phero__title { font-size: clamp(2.3rem, 1.3rem + 4vw, 4.4rem); line-height: 1; letter-spacing: -.026em; color: #fff; max-width: 18ch; text-wrap: balance; }
.phero__lead { font-size: var(--fs-lg); color: #e3ece5; max-width: 44rem; }
.phero__actions { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s4) var(--s6); margin-top: var(--s2); }
.phero__roof { position: absolute; left: 0; right: 0; bottom: -1px; --roof-color: var(--next, #fff); }
.phero--short .phero__inner { padding-bottom: calc(var(--roof-h) + 28px); }

/* breadcrumb on the dark hero */
.crumbs__list { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 0; font-size: .88rem; color: var(--on-dark-muted); }
.crumbs__item + .crumbs__item::before { content: "/"; margin: 0 10px; color: rgba(255, 255, 255, .4); }
.crumbs a { color: var(--gold-200); text-decoration: none; }
.crumbs a:hover { color: #fff; text-decoration: underline; }
.crumbs [aria-current] { color: #fff; }

/* fact ledger: typeset facts between gold hairlines (not pills) */
.ledgerline { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); margin-top: var(--s4); border-top: 1px solid rgba(216, 156, 48, .55); max-width: 52rem; }
.ledgerline > div { padding: 14px 16px 2px 0; }
.ledgerline dt { font: 700 .72rem/1.2 var(--font-body); letter-spacing: .14em; text-transform: uppercase; color: var(--gold-200); }
.ledgerline dd { margin: 6px 0 0; font: 600 1.15rem/1.25 var(--font-display); color: #fff; font-variant-numeric: tabular-nums; }
@media (min-width: 768px) {
  .ledgerline { grid-template-columns: repeat(var(--cols, 4), minmax(0, 1fr)); }
  .ledgerline > div + div { padding-left: 18px; border-left: 1px solid rgba(255, 255, 255, .14); }
}
@media (max-width: 767px) { .ledgerline > div:nth-child(even) { padding-left: 14px; border-left: 1px solid rgba(255, 255, 255, .14); } }

/* ---------- section shells ---------- */
.sec { position: relative; padding-block: var(--section); }
.sec--soft { background: var(--bg-soft); }
.sec--mint { background: var(--bg-mint); }
.sec--dark { background: var(--em-800); color: var(--on-dark-muted); }
.sec--dark h2, .sec--dark h3 { color: #fff; }
.sec--dark a:not(.btn) { color: var(--gold-200); }
.sec--dark a:not(.btn):hover { color: #fff; }
.sec--roof { padding-bottom: calc(var(--section) + var(--roof-h)); }
.sec__roof { position: absolute; left: 0; right: 0; bottom: -1px; --roof-color: var(--next, #fff); }
.sec__head { display: grid; gap: var(--s4); margin-bottom: var(--s6); max-width: 46rem; }
.sec__head > p { font-size: var(--fs-lg); color: var(--muted); }
.sec--dark .sec__head > p { color: var(--on-dark-muted); }
.sec__foot { margin-top: var(--s6); display: grid; gap: var(--s2); }
.sec--dark .source, .sec--dark .disclaimer { color: var(--on-dark-muted); }

/* ---------- prose column (explainers) ---------- */
.prose { max-width: 66ch; }
.prose > * + * { margin-top: var(--s4); }
.prose h2 { margin-top: var(--s7); }
.prose h3 { margin-top: var(--s6); }
.prose ul { display: grid; gap: var(--s2); }
.prose ul > li { position: relative; padding-left: 22px; }
.prose ul > li::before { content: ""; position: absolute; left: 4px; top: .7em; width: 7px; height: 7px; border-radius: 50%; background: var(--gold-400); }
.prose strong { color: var(--em-900); }

/* explainer with a sticky "on this page" index on wide screens */
.doc { display: grid; gap: var(--s6); }
.doc__toc { padding: var(--s5); border-radius: var(--r-lg); background: var(--bg-soft); }
.doc__toc p { font: 700 1.05rem/1.2 var(--font-display); color: var(--em-900); }
.doc__toc ol { margin-top: var(--s3); display: grid; gap: 2px; counter-reset: toc; }
.doc__toc li { counter-increment: toc; }
.doc__toc a { display: flex; gap: 10px; padding: 8px 10px; border-radius: var(--r-xs); text-decoration: none; font-weight: 600; color: var(--ink); }
.doc__toc a::before { content: counter(toc); color: var(--gold-ink); font-variant-numeric: tabular-nums; }
.doc__toc a:hover { background: #fff; color: var(--em-900); }
.doc__toc a { position: relative; transition: background-color var(--t-fast, .15s), color var(--t-fast, .15s); }
.doc__toc a::before { display: inline-grid; place-items: center; flex: none; width: 24px; height: 24px; border-radius: 50%; font-size: .85rem; transition: background-color var(--t-fast, .15s), color var(--t-fast, .15s); }
.doc__toc a[aria-current] { background: #fff; color: var(--em-900); box-shadow: var(--sh-1); }
.doc__toc a[aria-current]::before { background: var(--em-700); color: #fff; }
@media (min-width: 1100px) {
  .doc { grid-template-columns: 280px minmax(0, 1fr); gap: var(--s8); align-items: start; }
  .doc__toc { position: sticky; top: calc(var(--hdr-h) + 32px); }
}

/* ---------- split: copy beside a photo (use once per page) ---------- */
.split { display: grid; gap: var(--s6); align-items: center; }
.split__media { position: relative; border-radius: var(--r-xl); overflow: hidden; box-shadow: var(--sh-3); aspect-ratio: 4 / 3; background: var(--em-900); }
.split__media img { width: 100%; height: 100%; object-fit: cover; }
.split__copy > * + * { margin-top: var(--s4); }
.split__copy .btn { margin-top: var(--s5); }
@media (min-width: 1100px) {
  .split { grid-template-columns: 6fr 5fr; gap: var(--s8); }
  .split--flip .split__media { order: -1; }
}

/* ---------- mosaic: unequal linked panels (one large, the rest smaller) ---------- */
.mosaic { display: grid; gap: var(--s4); }
.tile { position: relative; isolation: isolate; overflow: hidden; display: grid; align-content: end; min-height: 220px; padding: var(--s5); border-radius: var(--r-lg); background: var(--em-900); color: var(--on-dark-muted); text-decoration: none; box-shadow: var(--sh-2); }
.tile img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; transition: transform var(--t-slow) var(--ease); }
.tile::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(180deg, rgba(var(--scrim), .1) 0%, rgba(var(--scrim), .55) 45%, rgba(var(--scrim), .94) 100%); }
.tile h3 { color: #fff; font-size: 1.45rem; }
.tile p { margin-top: 6px; color: #dfe9e2; max-width: 40ch; }
.tile__go { margin-top: var(--s3); color: var(--gold-200); font-weight: 700; }
.tile:hover { color: var(--on-dark-muted); }
.tile:hover img { transform: scale(1.04); }
.tile:hover .tile__go { color: #fff; text-decoration: underline; }
.tile--plain { background: #fff; color: var(--ink); box-shadow: var(--sh-1); border: 1px solid var(--line); align-content: start; }
.tile--plain::after { display: none; }
.tile--plain h3 { color: var(--em-900); }
.tile--plain p { color: var(--muted); }
.tile--plain .tile__go { color: var(--em-700); }
.tile--plain:hover { color: var(--ink); box-shadow: var(--sh-2); }
.tile--plain:hover .tile__go { color: var(--em-900); }
@media (min-width: 768px) {
  .mosaic { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .tile--lg { grid-column: 1 / -1; min-height: 320px; }
}
@media (min-width: 1100px) {
  .mosaic { grid-template-columns: repeat(3, minmax(0, 1fr)); grid-auto-rows: minmax(230px, auto); }
  .tile--lg { grid-column: span 2; grid-row: span 2; min-height: 0; }
  .tile--lg h3 { font-size: 2rem; }
}

/* ---------- price ledger: a paper price sheet (paper objects get the paper shadow) ---------- */
.pricesheet { position: relative; background: #fff; border-radius: var(--r-md); box-shadow: var(--sh-paper); overflow: hidden; }
.pricesheet__head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 6px var(--s4); padding: var(--s4) var(--s5); background: var(--em-900); color: var(--on-dark-muted); font-size: .88rem; }
.pricesheet__head strong { font: 700 1.15rem/1.2 var(--font-display); color: #fff; }
.pricesheet table { width: 100%; border-collapse: collapse; }
.pricesheet th, .pricesheet td { padding: 14px var(--s5); text-align: left; border-bottom: 1px solid var(--line); vertical-align: baseline; }
.pricesheet thead th { font-size: .8rem; color: var(--muted); font-weight: 600; background: var(--bg-soft); }
.pricesheet tbody th { font-weight: 600; color: var(--ink); }
.pricesheet td.price { text-align: right; white-space: nowrap; font: 700 1.35rem/1 var(--font-display); color: var(--em-900); font-variant-numeric: tabular-nums; }
.pricesheet td.price small { display: block; margin-bottom: 3px; font: 600 .74rem/1 var(--font-body); color: var(--muted); }
.pricesheet td.price--quote { font: 600 1rem/1.3 var(--font-body); color: var(--em-700); }
.pricesheet tbody tr:last-child th, .pricesheet tbody tr:last-child td { border-bottom: 0; }
.pricesheet__foot { padding: var(--s4) var(--s5); background: var(--gold-wash); font-size: var(--fs-sm); color: var(--ink); }

/* ---------- timeline: only for a real sequence ---------- */
.tl { display: grid; counter-reset: tl; }
.tl > li { position: relative; padding: 0 0 var(--s6) 64px; counter-increment: tl; }
.tl > li::before { content: counter(tl); position: absolute; left: 0; top: -4px; width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center; background: var(--em-700); color: #fff; font: 700 1.1rem/1 var(--font-display); box-shadow: 0 0 0 6px var(--bg, #fff); z-index: 1; }
.tl > li::after { content: ""; position: absolute; left: 21px; top: 40px; bottom: 0; width: 2px; background: repeating-linear-gradient(180deg, var(--em-tint-2) 0 6px, transparent 6px 11px); }
.tl > li:last-child { padding-bottom: 0; }
.tl > li:last-child::after { display: none; }
.tl h3 { font-size: 1.3rem; }
.tl p { margin-top: 6px; color: var(--muted); max-width: 60ch; }
.tl .tl__meta { display: inline-block; margin-top: 10px; padding: 4px 12px; border-radius: var(--r-pill); background: var(--em-tint); color: var(--em-900); font-size: .85rem; font-weight: 600; }
.sec--soft .tl > li::before { box-shadow: 0 0 0 6px var(--bg-soft); }
@media (min-width: 1100px) {
  .tl--wide { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--s5); }
  .tl--wide > li { padding: 64px var(--s4) 0 0; }
  .tl--wide > li::before { top: 0; }
  .tl--wide > li::after { left: 50px; right: 0; top: 21px; bottom: auto; width: auto; height: 2px; background: repeating-linear-gradient(90deg, var(--em-tint-2) 0 6px, transparent 6px 11px); }
  .tl--wide > li:last-child::after { display: none; }
}

/* ---------- printable checklist: a paper sheet with real checkboxes ---------- */
.sheet { position: relative; background: #fff; border-radius: var(--r-sm); box-shadow: var(--sh-paper); padding: var(--s6) var(--s5) var(--s5); }
.sheet::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 6px; border-radius: var(--r-sm) var(--r-sm) 0 0; background: repeating-linear-gradient(90deg, var(--em-700) 0 40px, var(--gold-400) 40px 52px); }
.sheet h3 { font-size: 1.35rem; }
.sheet__list { margin-top: var(--s4); display: grid; }
.sheet__list li + li { border-top: 1px dashed var(--line); }
.sheet__list label { display: flex; gap: 14px; align-items: flex-start; padding: 12px 0; cursor: pointer; }
.sheet__list input { flex: none; width: 22px; height: 22px; margin-top: 2px; accent-color: var(--em-700); }
.sheet__list input:checked + span { color: var(--muted); text-decoration: line-through; text-decoration-color: var(--gold-500); }
.sheet__actions { margin-top: var(--s4); display: flex; flex-wrap: wrap; gap: var(--s3); align-items: center; }
@media (min-width: 768px) { .sheet { padding: var(--s7) var(--s7) var(--s6); } }

/* ---------- comparison table ---------- */
.tbl { overflow-x: auto; border-radius: var(--r-lg); background: #fff; box-shadow: var(--sh-2); }
.tbl table { width: 100%; min-width: 560px; border-collapse: collapse; }
.tbl th, .tbl td { padding: 16px var(--s5); text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); }
.tbl thead th { background: var(--em-900); color: #fff; font: 700 1.05rem/1.2 var(--font-display); }
.tbl thead th:nth-child(2) { background: var(--em-700); }
.tbl tbody th { width: 26%; font-weight: 600; color: var(--em-900); background: var(--bg-soft); }
.tbl tbody tr:last-child th, .tbl tbody tr:last-child td { border-bottom: 0; }
.tbl .yes { font-weight: 700; color: var(--pass); }

/* ---------- note: a tinted aside (no colored side border) ---------- */
.note { display: grid; grid-template-columns: auto 1fr; gap: var(--s4); align-items: start; padding: var(--s5); border-radius: var(--r-lg); background: var(--gold-wash); box-shadow: inset 0 0 0 1px rgba(192, 132, 24, .25); }
.note__ico { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; background: var(--gold-400); color: var(--em-950); }
.note h3 { font-size: 1.15rem; }
.note p { margin-top: 4px; }
.note--em { background: var(--em-tint); box-shadow: inset 0 0 0 1px var(--em-tint-2); }
.note--em .note__ico { background: var(--em-700); color: #fff; }

/* ---------- call band: a dark statement with call + quote, mid-page ---------- */
.callband { position: relative; overflow: hidden; display: grid; gap: var(--s5); padding: var(--s6) var(--s5); border-radius: var(--r-xl); background: var(--em-900); color: var(--on-dark-muted); box-shadow: var(--sh-3); }
.callband::after { content: ""; position: absolute; right: -80px; bottom: -120px; width: 320px; height: 320px; border-radius: 50%; border: 1.5px solid rgba(216, 156, 48, .3); pointer-events: none; }
.callband h2, .callband h3 { color: #fff; font-size: clamp(1.6rem, 1.2rem + 1.6vw, 2.3rem); max-width: 22ch; }
.callband p { max-width: 50ch; }
.callband__btns { position: relative; z-index: 1; display: flex; flex-wrap: wrap; gap: var(--s3) var(--s4); align-items: center; }
@media (min-width: 900px) { .callband { grid-template-columns: 1fr auto; align-items: center; padding: var(--s7); } }

/* ---------- facts strip: big sourced figures in a row (sourced numbers only) ---------- */
.figs { display: grid; gap: var(--s4); grid-template-columns: repeat(2, minmax(0, 1fr)); }
.fig { padding: var(--s5) var(--s4); border-radius: var(--r-lg); background: #fff; box-shadow: var(--sh-1); }
.fig__n { font: 700 clamp(2rem, 1.5rem + 2vw, 2.8rem)/1 var(--font-display); color: var(--em-900); letter-spacing: -.02em; }
.fig__n small { font-size: .45em; letter-spacing: 0; margin-left: 4px; color: var(--gold-ink); }
.fig__l { margin-top: 8px; font-weight: 600; color: var(--ink); line-height: 1.35; }
.fig .source { margin-top: 6px; }
@media (min-width: 1100px) { .figs { grid-template-columns: repeat(var(--cols, 4), minmax(0, 1fr)); } }

/* ---------- contact cards (contact page) ---------- */
.reach { display: grid; gap: var(--s4); }
.reach__item { display: grid; gap: 6px; padding: var(--s5); border-radius: var(--r-lg); background: #fff; box-shadow: var(--sh-2); }
.reach__k { font-size: .85rem; font-weight: 600; color: var(--muted); }
.reach__v { font: 700 1.35rem/1.25 var(--font-display); color: var(--em-900); overflow-wrap: anywhere; }
.reach__v a { color: inherit; text-decoration: none; }
.reach__v a:hover { text-decoration: underline; }
.reach__item--dark { background: var(--em-900); color: var(--on-dark-muted); }
.reach__item--dark .reach__k { color: var(--gold-200); }
.reach__item--dark .reach__v { color: #fff; }
@media (min-width: 768px) { .reach { grid-template-columns: repeat(3, minmax(0, 1fr)); } }

/* ---------- small helpers ---------- */
.lede { font-size: var(--fs-lg); }
.muted { color: var(--muted); }
.stack > * + * { margin-top: var(--s4); }
.btnrow { display: flex; flex-wrap: wrap; gap: var(--s3) var(--s5); align-items: center; margin-top: var(--s5); }
.sec--dark .phone-link { color: #fff; }

/* ---------- homepage map: home-area badge (Cheltenham and Elkins Park) ---------- */
.place__badge--home { background: var(--gold-400); color: var(--em-950); }
.place__badge--home .place__yrs { display: grid; place-items: center; color: var(--em-950); }
.place__badge--home .place__unit { color: var(--em-950); }
@media (max-width: 767px) { .place__badge--home .place__yrs svg { width: 18px; height: 18px; } .place__badge--home { align-items: center; } }
[hidden] { display: none !important; }

/* ===== MFIT shared (phones): inner-page components. Tokens are in d.css :root.
   Breakpoints: P max-width 767, P-wide 360 to 767, P-small max-width 359, P-short max-height 560. ===== */
@media (max-width: 767px) {
  /* every lead: size from --fs-lg, one line-height. Page CSS never sets a lead line-height. */
  .hero__lead, .phero__lead, .sec__head > p, .lede, .atlas__head p, .scope__after, .area__skytext p,
  .decide__intro p, .towns__intro p, .mu-fact__side p:first-child, .awhen__lead, .bways__head p, .thanks__side,
  .post__body h2 + p, .hoods__lead, .faqgroup__head p { line-height: var(--lh-lead); }

  /* inner-page hero */
  /* minmax(0, 1fr): the one-line breadcrumb must not widen the hero column past the screen */
  .phero__inner { padding: calc(var(--hdr-h) + 14px) var(--gutter) calc(var(--roof-h) + 24px); gap: 14px; grid-template-columns: minmax(0, 1fr); }
  .phero--short .phero__inner { padding-bottom: calc(var(--roof-h) + 20px); }
  .phero__title { font-size: var(--fs-h1p); line-height: 1.04; max-width: none; }
  .phero__actions { margin-top: 2px; gap: 10px 20px; }
  .phero__actions .btn--lg { min-height: 50px; padding: 12px 24px; }
  .crumbs__list { flex-wrap: nowrap; font-size: var(--fs-meta); }
  .crumbs__item { flex: none; white-space: nowrap; }
  .crumbs__item:last-child { flex: 0 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
  .crumbs a { position: relative; }
  .crumbs a::after { content: ""; position: absolute; inset: -14px -6px; }   /* 17px inline box + 28 = 45 */

  /* fact ledger */
  .ledgerline { margin-top: 6px; }
  .ledgerline > div { padding: 10px 12px 2px 0; }
  .ledgerline dt { font-size: var(--fs-meta); letter-spacing: .08em; }
  .ledgerline dd { font-size: var(--fs-body-sm); margin-top: 4px; }
  .ledgerline > div:last-child:nth-child(odd) { grid-column: 1 / -1; }
  .ledgerline > .ledgerline__wide { grid-column: 1 / -1; padding-left: 0; border-left: 0; }
  /* a wide cell in an odd position shifts the two cells after it to the other column */
  .ledgerline > .ledgerline__wide:nth-child(odd) + div { padding-left: 0; border-left: 0; }
  .ledgerline > .ledgerline__wide:nth-child(odd) + div + div:not(.ledgerline__wide) { padding-left: 14px; border-left: 1px solid rgba(255, 255, 255, .14); }

  /* sections */
  .sec__head { gap: 10px; margin-bottom: var(--gap-head); }
  .sec__foot { margin-top: var(--gap-head); }
  .sec__foot > p + p { margin-top: 0; }   /* source then disclaimer: the foot's own 8px gap, not gap + paragraph margin */
  .split { gap: var(--gap-block); }
  .split__media { aspect-ratio: var(--ar-media); }
  .split__copy .btn { margin-top: 16px; }

  /* mosaic tiles and the snap carousel */
  .mosaic { gap: var(--gap-stack); }
  .tile { min-height: 148px; padding: var(--card-pad); }
  .tile--lg { min-height: 180px; }
  .tile--plain { min-height: 0; }
  .tile h3 { font-size: var(--fs-h3); }
  .snap { display: flex; gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none;
    padding: 12px var(--gutter) 72px;                 /* bottom is bigger than blur 40 + offset 20 of --sh-2 */
    margin: -12px calc(var(--gutter) * -1) -48px;     /* full bleed, cancels the extra space */
    scroll-padding-inline: var(--gutter); }
  .snap::-webkit-scrollbar { display: none; }
  .snap > * { flex: 0 0 82%; scroll-snap-align: start; }
  .snap > .tile { min-height: 200px; }

  /* price sheet */
  .pricesheet__head, .pricesheet__foot { padding: 12px 16px; }
  .pricesheet th, .pricesheet td { padding: 10px 16px; }
  .pricesheet thead th { font-size: var(--fs-meta); }
  .pricesheet tbody th { white-space: normal; }
  .pricesheet td.price { font-size: var(--fs-h3); }
  .pricesheet td.price small { display: inline; margin: 0 6px 0 0; font-size: var(--fs-meta); }
  .pricesheet td.price--quote { white-space: normal; font-size: var(--fs-compact); }
  .pricesheet td.price--quote a { display: inline-flex; align-items: center; min-height: 44px; }

  /* timeline: number disc on the title row, text full width. With data-fold it is the numbered accordion. */
  .tl > li { padding: 0; }
  .tl > li::before { width: var(--num); height: var(--num); top: 10px; font-size: var(--fs-meta); box-shadow: none; }
  .sec--soft .tl > li::before { box-shadow: none; }
  .tl > li::after { display: none; }
  .tl h3 { font-size: var(--fs-h4); }
  .tl:not(.fold-on) > li { padding-bottom: 14px; }
  .tl:not(.fold-on) h3 { display: flex; align-items: center; min-height: 48px; padding-left: 40px; }
  .tl:not(.fold-on) p { margin-top: 0; max-width: none; font-size: var(--fs-body-sm); }
  .fold-on.tl .fold__btn { padding-left: 40px; }
  .tl .fold__body { font-size: var(--fs-body-sm); max-width: none; margin-top: 0; }
  .tl .fold__body + .fold__body { margin-top: 8px; }
  .tl .tl__meta, .tl .tl__meta.fold__body { font-size: var(--fs-meta); margin-top: 8px; }
  .tl > li > .fold__body:last-child { padding-bottom: 14px; }
  .tl > li > .tl__meta.fold__body:last-child { padding-bottom: 4px; margin-bottom: 14px; }   /* the pill keeps its own padding */
  .fold-on.tl > li.is-open > :last-child:not(.fold__body) { padding-bottom: 14px; }   /* bodies nested in a wrapper */

  /* checklist sheet: Print sits on the title row */
  .sheet { display: grid; grid-template-columns: minmax(0, 1fr) auto; column-gap: 12px; padding: 20px var(--card-pad-sm) var(--card-pad-sm); }
  .sheet > * { grid-column: 1 / -1; }
  .sheet > :is(h2, h3):first-of-type { grid-column: 1; grid-row: 1; align-self: center; font-size: var(--fs-h3); }
  .sheet > .sheet__actions { grid-column: 2; grid-row: 1; margin: 0; }
  .sheet__list { margin-top: 10px; }
  .sheet__list label { padding: 6px 0; gap: 12px; min-height: 44px; align-items: center; font-size: var(--fs-body-sm); line-height: 1.4; }
  .sheet > .muted { font-size: var(--fs-compact); }

  /* tables: no forced width; pick tbl--pair, tbl--stack or data-colswitch per table */
  .tbl table { min-width: 0; }
  .tbl th, .tbl td { padding: 10px 12px; font-size: var(--fs-compact); line-height: 1.45; }
  .tbl--pair thead, .tbl--stack thead, .tbl[data-col] thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
  .tbl--pair table, .tbl--pair tbody, .tbl--stack table, .tbl--stack tbody, .tbl--stack tr, .tbl--stack tbody th, .tbl--stack td { display: block; }
  .tbl--pair tr { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .tbl--pair tbody th { grid-column: 1 / -1; width: auto; border-bottom: 0; padding-block: 8px; }
  .tbl--pair td + td { border-left: 1px solid var(--line); }
  .tbl--pair td[data-label]::before, .tbl--stack td[data-label]::before { content: attr(data-label); display: block; margin-bottom: 2px; font-size: var(--fs-meta); font-weight: 700; color: var(--muted); }
  .tbl--stack tbody th { width: auto; border-bottom: 0; }
  .tbl--stack td { border-bottom: 0; padding-block: 8px 0; }
  .tbl--stack tr { padding-bottom: 12px; border-bottom: 1px solid var(--line); }
  .tbl--stack tbody tr:last-child { border-bottom: 0; }
  .tbl--stack .fold__head, .tbl--stack tbody th:has(> .fold__head) { padding-block: 0; }
  /* folded rows: the cell that stays visible in a closed row carries its label inline */
  .tbl--stack .fold-on td:not(.fold__body) { padding-top: 6px; }
  .tbl--stack .fold-on td:not(.fold__body)[data-label]::before { display: inline; margin: 0 8px 0 0; }
  .tbl--stack .fold-on tr:not(.is-open) { padding-bottom: 0; }
  .tblswitch { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; padding: 10px; background: var(--bg-soft); }
  .tblswitch__btn { min-height: 44px; padding: 6px 10px; border: 1.5px solid var(--line); border-radius: var(--r-sm); background: #fff; font-weight: 600; font-size: var(--fs-compact); line-height: 1.15; color: var(--ink); }
  .tblswitch__btn:last-child:nth-child(odd) { grid-column: 1 / -1; }
  .tblswitch__btn[aria-pressed="true"] { background: var(--em-700); border-color: var(--em-700); color: #fff; }
  .tbl[data-col] tbody th { width: 36%; }
  .tbl[data-col] tbody td { display: none; }
  .tbl[data-col="1"] tbody td:nth-of-type(1), .tbl[data-col="2"] tbody td:nth-of-type(2),
  .tbl[data-col="3"] tbody td:nth-of-type(3), .tbl[data-col="4"] tbody td:nth-of-type(4) { display: table-cell; }

  /* note: icon on the title row, text full width */
  .note { display: block; padding: var(--card-pad); }
  .note__ico { float: left; width: var(--num); height: var(--num); margin: 0 10px 2px 0; }
  .note__ico svg { width: 16px; height: 16px; }
  .note h3 { min-height: var(--num); display: flex; align-items: center; font-size: var(--fs-h4); }
  .note p { clear: left; font-size: var(--fs-body-sm); }

  /* figures: always 2 by 2 */
  .figs { gap: 10px; }
  .fig { padding: 16px 14px; }
  .fig__n { font-size: 1.75rem; }
  .fig__n small { font-size: var(--fs-meta); }
  .fig__l { font-size: var(--fs-compact); margin-top: 6px; }

  /* call band */
  .callband { padding: var(--card-pad); gap: 14px; }
  .callband h2, .callband h3 { font-size: var(--fs-band); }
  .callband p { font-size: var(--fs-body-sm); }

  /* contact cards */
  .reach { gap: 10px; }
  .reach__item { padding: 14px 16px; gap: 4px; }
  .reach__v { font-size: var(--fs-h4); }
  .reach__item > :not(.reach__k):not(.reach__v) { font-size: var(--fs-compact); line-height: 1.4; }

  /* on-this-page index */
  .doc__toc { padding: var(--card-pad-sm); }
  .doc__toc ol { grid-template-columns: 1fr 1fr; gap: 2px 8px; }
  .doc__toc a { min-height: 44px; align-items: center; padding: 6px 8px; font-size: var(--fs-compact); }

  /* helpers */
  .btnrow { margin-top: 16px; gap: 8px 16px; }
  .btnrow .phone-link, .btnrow .text-link { display: inline-flex; align-items: center; min-height: 44px; }
  .srclist a { font-size: 1rem; font-weight: 600; }
  .srclist p, .srclist li, .srclist td { font-size: var(--fs-compact); line-height: 1.45; }
}
@media (max-width: 499px) {
  .phero__actions:not(:has(> :not(.hero__call))) { display: none; }
}
@media (min-width: 360px) and (max-width: 767px) {
  /* two buttons on one row; flex (not equal columns) so the phone number never wraps */
  .callband__btns { display: flex; flex-wrap: wrap; gap: 8px; }
  .callband__btns .btn { flex: 1 1 auto; min-height: 48px; padding-inline: 10px; font-size: var(--fs-compact); white-space: nowrap; }
  .callband__btns > :not(.btn) { flex: 1 0 100%; }
  .callband__btns > :not(.btn) { display: inline-flex; align-items: center; min-height: 44px; }
}
@media (max-width: 359px) {
  .tbl[data-col] tbody th { width: 30%; }
  .callband__btns { display: grid; grid-template-columns: 1fr; gap: 8px; }
  .callband__btns > :not(.btn) { display: inline-flex; align-items: center; min-height: 44px; }
  .reach__v { font-size: var(--fs-body-sm); }
}


/* ================= booking hero (.fhero): light, address box, photo with technician card ================= */
.fhero { position: relative; background: linear-gradient(180deg, var(--bg-soft) 0%, #fff 100%); padding: calc(var(--hdr-h) + 20px) 0 var(--s7); overflow: hidden; }
.fhero::before { content: ""; position: absolute; right: -8%; top: -10%; width: 55%; aspect-ratio: 1; border-radius: 50%; background: radial-gradient(closest-side, var(--em-tint), transparent); pointer-events: none; }
.fhero__grid { position: relative; display: grid; gap: var(--s5); }
.fhero__copy { min-width: 0; }
.fhero .crumbs { margin-bottom: var(--s4); }
.fhero .crumbs__list { color: var(--muted, #4d5a51); }
.fhero .crumbs__item + .crumbs__item::before { color: var(--line); }
.fhero .crumbs a { color: var(--em-700); }
.fhero .crumbs a:hover { color: var(--em-900); }
.fhero .crumbs [aria-current] { color: var(--ink); }
.fhero__title { font-size: clamp(1.75rem, 1.1rem + 2.4vw, 2.75rem); line-height: 1.08; max-width: 18ch; }
.fhero__lead { margin-top: var(--s4); font-size: var(--fs-lg); line-height: 1.55; color: #3b463f; max-width: 54ch; }

.fhero__stage { position: relative; min-width: 0; }
.fhero__photo { margin: 0; border-radius: var(--r-lg); overflow: hidden; aspect-ratio: 2 / 1; box-shadow: var(--sh-2); }
.fhero__photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.fhero__card { position: relative; margin: -28px 10px 0; background: #fff; border-radius: var(--r-lg); box-shadow: var(--sh-3); padding: 18px; }
.fhero__facts { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 20px; margin: 0; }
.fhero__facts div { min-width: 0; }
.fhero__facts dt { font-size: .82rem; font-weight: 600; color: var(--gold-ink); }
.fhero__facts dd { margin: 2px 0 0; font: 700 1.05rem/1.25 var(--font-display); color: var(--em-900); }
.fhero__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 20px; margin-top: 0; padding-top: 14px; }
.fhero__call { color: var(--em-900); text-decoration: none; font: 700 1.15rem/1 var(--font-display); font-variant-numeric: tabular-nums; white-space: nowrap; border-bottom: 2px solid var(--gold-400); padding: 10px 0 5px; }
.fhero__call span { font: 500 .95rem/1 var(--font-body); color: #4d5a51; margin-right: 4px; }
.fhero__call:hover { color: var(--em-700); border-color: var(--em-700); }

@media (max-width: 767px) {
  .fhero { padding-top: calc(var(--hdr-h) + 14px); padding-bottom: var(--s6); }
  .fhero .crumbs { margin-bottom: 10px; }
  .fhero__lead { margin-top: 10px; }
  .fhero__facts { gap: 10px 16px; }
  .fhero__facts dd { font-size: 1rem; }
}
@media (min-width: 768px) {
  .fhero { padding-bottom: var(--s8); }
  .fhero__photo { aspect-ratio: 16 / 9; }
  .fhero__card { margin: -72px 32px 0; padding: var(--s6); }
  .fhero__facts { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
@media (min-width: 1100px) {
  .fhero { padding: calc(var(--hdr-h) + 48px) 0 64px; }
  .fhero__grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); gap: 64px; align-items: center; }
  .fhero__photo { aspect-ratio: 5 / 4; border-radius: var(--r-xl); }
  .fhero__copy { padding-bottom: 40px; }
  .fhero__card { position: absolute; left: -64px; right: auto; bottom: -40px; margin: 0; width: min(440px, 80%); }
  .fhero__facts { grid-template-columns: 1fr 1fr; gap: 18px 28px; }
  .fhero__facts dd { font-size: 1.15rem; }
  .fhero__stage { margin-bottom: 40px; }
}
@media (prefers-reduced-motion: no-preference) {
  .fhero__card { animation: fhero-in .6s var(--ease, ease) .15s both; }
  @keyframes fhero-in { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
}

/* final light hero (version A): plain rounded photo, tag card with technician */
.fhero__copy, .fhero__stage { position: relative; z-index: 1; }
.fhero__photo { border-radius: var(--r-lg); box-shadow: none; }
.fhero__stage::before { content: ""; position: absolute; inset: 18px -14px -14px 18px; border-radius: var(--r-lg); background: repeating-linear-gradient(135deg, var(--em-tint) 0 2px, transparent 2px 10px); z-index: -1; }
.fhero__hole { position: absolute; top: 14px; right: 16px; width: 14px; height: 14px; border-radius: 50%; background: var(--bg-soft); box-shadow: inset 0 1px 2px rgba(0, 40, 14, .25); }
.fhero__perf { margin: 16px -18px 0; height: 0; border-top: 2px dashed var(--line); position: relative; }
.fhero__perf::before, .fhero__perf::after { content: ""; position: absolute; top: -9px; width: 16px; height: 16px; border-radius: 50%; background: #f6f8f5; }
.fhero__perf::before { left: -8px; } .fhero__perf::after { right: -8px; }
@media (max-width: 767px) { .fhero__stage { margin-top: 18px; } .fhero__stage::before { inset: 14px -8px -8px 14px; } }
@media (min-width: 768px) { .fhero__perf { margin-inline: calc(var(--s6) * -1); } }
@media (min-width: 1100px) { .fhero__photo { border-radius: var(--r-xl); } }



/* A: address first, technician on the card */
.fhero__addr { margin-top: var(--s5); max-width: 520px; }
.fhero__addr label { display: block; font-weight: 700; color: var(--em-900); margin-bottom: 8px; }
.fhero__addr-row { display: flex; gap: 8px; background: #fff; border: 1.5px solid var(--line); border-radius: var(--r-pill); padding: 6px; box-shadow: var(--sh-1); }
.fhero__addr-row:focus-within { border-color: var(--em-700); }
.fhero__addr input { flex: 1; min-width: 0; border: 0; background: none; font: inherit; padding: 0 14px; color: var(--ink); outline: none; min-height: 44px; }
.fhero__addr .btn { flex: none; }
.fhero__addr-note { margin-top: 10px; font-size: .95rem; color: #4d5a51; }
.fhero__tech { margin: -4px 0 16px; padding-bottom: 14px; border-bottom: 1px solid var(--line); }
.fhero__tech { display: flex; align-items: center; gap: 12px; }
.fhero__tech img { width: 52px; height: 52px; border-radius: 50%; object-fit: cover; object-position: 50% 20%; flex: none; box-shadow: 0 0 0 3px #fff, 0 0 0 5px var(--gold-300); }
.fhero__tech p { margin: 0; line-height: 1.25; }
.fhero__tech span { display: block; font-size: 13px; font-weight: 600; color: var(--gold-ink); }
.fhero__tech b { display: block; font: 700 1.05rem/1.2 var(--font-display); color: var(--em-900); }
.fhero__tech small { display: block; font-size: 13px; color: #4d5a51; }
.fhero__actions .btn { display: none; }

@media (max-width: 767px) {
  .fhero__addr { margin-top: 16px; }
  .fhero__addr label { margin-bottom: 6px; }
  .fhero__addr-row { padding: 4px; }
  .fhero__addr input { padding: 0 10px; font-size: 16px; }
  .fhero__addr .btn { padding-inline: 16px; min-height: 44px; }
  .fhero__addr-note { display: none; }
  .fhero__photo { aspect-ratio: 5 / 2; }
  .fhero__tech { margin-bottom: 12px; padding-bottom: 12px; }
  .fhero__tech img { width: 44px; height: 44px; }
  .fhero__card { padding: 16px; }
  .fhero__perf { margin-inline: -16px; margin-top: 12px; }
  .fhero__actions { padding-top: 12px; }
}

/* ================= panorama hero (.xhero): title and lead side by side, wide photo, facts bar ================= */
.xhero { position: relative; background: #fff; padding: calc(var(--hdr-h) + 20px) 0 var(--s7); overflow: hidden; }
.xhero__grid { display: grid; gap: 14px; grid-template-columns: minmax(0, 1fr); }  /* minmax: a long breadcrumb must not widen the column */
.xhero__crumbs .crumbs__list { color: #4d5a51; }
.xhero__crumbs .crumbs__item + .crumbs__item::before { color: var(--line); }
.xhero__crumbs .crumbs a { color: var(--em-700); }
.xhero__crumbs .crumbs [aria-current] { color: var(--ink); }
.xhero__title { font-size: clamp(1.75rem, 1.1rem + 2.6vw, 3rem); line-height: 1.06; }
.xhero__lead { font-size: var(--fs-lg); line-height: 1.55; color: #3b463f; max-width: 60ch; margin: 0; }
.xhero__actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 22px; }
.xhero__call { color: var(--em-900); text-decoration: none; font: 700 1.15rem/1 var(--font-display); white-space: nowrap; border-bottom: 2px solid var(--gold-400); padding: 10px 0 5px; }
.xhero__call span { font: 500 .95rem/1 var(--font-body); color: #4d5a51; margin-right: 4px; }
.xhero__facts { margin: 0; display: grid; grid-template-columns: 1fr 1fr; }
.xhero__facts dt { font-size: 13px; font-weight: 600; color: var(--gold-ink); }
.xhero__facts dd { margin: 2px 0 0; font: 700 1.05rem/1.25 var(--font-display); color: var(--em-900); }
.xhero__photo { margin: 0; overflow: hidden; }
.xhero__photo img { display: block; width: 100%; height: 100%; object-fit: cover; }

/* ---- 1: panorama. Title and lead side by side, a wide street strip, facts as a bar riding its bottom edge ---- */
.xhero { padding-bottom: var(--s6); }
.xhero .xhero__facts { position: relative; z-index: 2; margin: -44px 12px 0; background: #fff; border-radius: var(--r-md); box-shadow: var(--sh-3); padding: 14px 16px; gap: 12px 16px; order: 9; }
.xhero .xhero__photo { order: 8; border-radius: var(--r-lg); aspect-ratio: 16 / 7; }
.xhero .xhero__photo img { object-position: 50% 62%; }



@media (min-width: 1100px) {
  .xhero { padding: calc(var(--hdr-h) + 40px) 0 72px; }
  .xhero .xhero__grid { grid-template-columns: 1.1fr 1fr; grid-template-areas: "crumbs crumbs" "title lead" "actions lead" "photo photo" "facts facts"; column-gap: 72px; row-gap: 20px; align-items: start; }
  .xhero .xhero__crumbs { grid-area: crumbs; } .xhero .xhero__title { grid-area: title; }
  .xhero .xhero__lead { grid-area: lead; padding-top: 8px; } .xhero .xhero__actions { grid-area: actions; }
  .xhero .xhero__photo { grid-area: photo; aspect-ratio: 21 / 6; margin-top: 12px; border-radius: var(--r-xl); }
  .xhero .xhero__facts { grid-area: facts; grid-template-columns: repeat(4, 1fr); margin: -64px 48px 0; padding: 22px 32px; }
  .xhero .xhero__facts div + div { border-left: 1px solid var(--line); padding-left: 24px; }


}
@media (max-width: 767px) {
  .xhero { padding-top: calc(var(--hdr-h) + 12px); }
  .xhero__grid { gap: 12px; }
}

/* slim panorama hero (no photo): thank-you, 404 */
.xhero--slim { padding-bottom: var(--s6); background: linear-gradient(180deg, var(--bg-soft) 0%, #fff 100%); }
.xhero--slim .xhero__leadbox { min-width: 0; }
.xhero--slim .xhero__facts { margin: 6px 0 0; order: 0; }
.xhero--slim .xhero__facts--3 { grid-template-columns: 1fr 1fr; }
.xhero--slim .xhero__facts--3 div:last-child { grid-column: 1 / -1; }
@media (min-width: 768px) {
  .xhero--slim .xhero__facts--3 { grid-template-columns: repeat(3, 1fr); }
  .xhero--slim .xhero__facts--3 div:last-child { grid-column: auto; }
  .xhero--slim .xhero__facts div + div { border-left: 1px solid var(--line); padding-left: 20px; }
}
@media (min-width: 1100px) {
  .xhero.xhero--slim { padding-bottom: 64px; }
  .xhero.xhero--slim .xhero__grid { grid-template-areas: "crumbs crumbs" "title lead" "actions lead" "facts facts"; }
  .xhero.xhero--slim .xhero__crumbs { grid-area: crumbs; }
  .xhero.xhero--slim .xhero__leadbox { grid-area: lead; padding-top: 8px; }
  .xhero.xhero--slim .xhero__facts { grid-area: facts; grid-template-columns: repeat(3, 1fr); margin: 24px 0 0; padding: 22px 32px; }
}

/* print one checklist (js/pages-d/print-sheet.js): everything else is hidden while it prints */
.print-head { display: none; }
@media print {
  html.is-printing body *:not([data-printing]):not([data-printing] *):not(:has([data-printing])) { display: none !important; }
  html.is-printing body *:has([data-printing]) { margin: 0 !important; padding: 0 !important; border: 0 !important; background: none !important; box-shadow: none !important; min-height: 0 !important; display: block !important; position: static !important; transform: none !important; }
  html.is-printing [data-printing] { margin: 0 !important; box-shadow: none !important; transform: none !important; background: #fff !important; padding: 0 !important; width: auto !important; max-width: none !important; }
  html.is-printing [data-printing] .sheet__actions, html.is-printing [data-printing] [data-print] { display: none !important; }
  html.is-printing [data-printing] { break-inside: auto; }
  html.is-printing [data-printing] li, html.is-printing [data-printing] p { break-inside: avoid; }
  html.is-printing [data-printing] .print-head { display: block; margin: 0 0 14px; padding-bottom: 8px; border-bottom: 1px solid #999; font: 600 11pt/1.3 Arial, sans-serif; color: #000; }
  html.is-printing [data-printing] input[type="checkbox"] { -webkit-appearance: checkbox; appearance: auto; width: 14px; height: 14px; }
  html.is-printing [data-printing] .ph { outline: 0 !important; background: none !important; }
  html.is-printing .hdr, html.is-printing .abar, html.is-printing .totop { display: none !important; }
  html.is-printing body::before, html.is-printing body::after, html.is-printing main::before, html.is-printing main::after { display: none !important; }
  @page { margin: 0.6in; }
  html.is-printing [data-printing]::before, html.is-printing [data-printing]::after { display: none !important; }
}
