/* SpillSafe design polish, restored 30 Nov 2026 on top of the live site. Loads after the CSS bundle and
   before the 18 Nov mobile stylesheets. Source: three-designs-2026-11-03/site-polish.css. */
/* Site polish, 11 Nov 2026 (Claude web design audit). Last-loaded layer on site/ routes.
   Fixes found in browser QA plus purposeful motion. Copy, colours and the approved layout are unchanged.
   Motion here explains progress or confirms an interaction; body text never moves while being read.
   Everything animated is switched off by reduced motion and the site's Pause Motion control. */

/* ---------- Service pages: How a call unfolds rail ----------
   The rail stuck under the header for the whole page, 100px narrower than the text column, so
   paragraphs showed beside it and it covered the call-to-action and FAQ. It now sits on a
   full-width band, tracks the three phase paragraphs and steps aside when they are read. */
@media (min-width:769px){
  html body[class] main>.phase-rail{background:var(--p-page,#F5F8F3)!important;box-shadow:0 0 0 100vmax var(--p-page,#F5F8F3);clip-path:inset(0 -100vmax);transition:opacity .28s ease,visibility .28s ease}
  html body[class] main>.phase-rail.rail-away{opacity:0;visibility:hidden}
}
html body[class] main>.phase-rail li.on{color:var(--p-heading,#213D30)!important}
html body[class] main>.phase-rail li.on span{background:var(--p-accent,#52D167)!important;border-color:var(--p-accent,#52D167)!important;color:#0b1c13!important}
html body[class] main>.phase-rail .pr-fill{background:var(--p-accent,#52D167)}

/* ---------- Footer contact: no mid-word email breaks on tablet ----------
   Between 601 and 1199px the third column was 217-295px wide, which split both email addresses
   mid-word. Contact now takes its own full-width row with its details side by side. */
@media (min-width:601px) and (max-width:1199px){
  html body[class] footer .footer-grid{grid-template-columns:minmax(0,.8fr) minmax(0,1.4fr)!important}
  html body[class] footer .footer-grid>.footer-col:nth-child(3){grid-column:1/-1}
  html body[class] footer .footer-grid>.footer-col:nth-child(3)>ul{display:grid!important;grid-template-columns:repeat(auto-fill,minmax(min(100%,320px),1fr));column-gap:32px}
}
@media (max-width:359px){
  html body[class] footer .footer-col a.detail-val[href^="mailto:"]{font-size:15px!important}
}

/* ---------- Touch targets ---------- */
@media (max-width:767px){
  html body[class] .dynamic-header .dynamic-call{min-height:44px!important}
  /* Breadcrumb links keep their exact look and position; an invisible extension gives a 44px tall hit area. */
  html body[class] :is(.crumbs,nav[aria-label="Breadcrumb"]) a{position:relative}
  html body[class] :is(.crumbs,nav[aria-label="Breadcrumb"]) a::after{content:"";position:absolute;left:-4px;right:-4px;top:50%;height:44px;translate:0 -50%}
}

/* ---------- Photo gallery number controls ----------
   Eight numbered buttons wrapped six-and-two on phones and tablets. They now form two even
   rows of four until there is room for all eight in one row. */
html body[class] .chapter-gallery .gallery-navigation{container-type:inline-size}
html body[class] .gallery-number-strip[data-count="8"]{display:grid!important;grid-template-columns:repeat(4,minmax(44px,1fr));gap:8px;width:100%;overflow:visible!important}
html body[class] .gallery-number-strip[data-count="8"]>button{width:auto!important;min-width:0!important}
@container (min-width:560px){
  html body[class] .gallery-number-strip[data-count="8"]{grid-template-columns:repeat(8,minmax(44px,1fr));width:auto;flex:1 1 auto}
}
@container (max-width:559px){
  html body[class] .chapter-gallery .gallery-navigation{flex-wrap:wrap!important;row-gap:12px}
}

/* ---------- Accessibility (axe, 11 Nov 2026) ----------
   Links inside running text were told apart by colour alone (1.15:1 and 1.26:1 against the
   surrounding text). They now carry an underline as well. */
html body[class] .emergency-note a[href],html body[class] main figure>figcaption a:not([class]){text-decoration:underline!important;text-decoration-thickness:1px!important;text-underline-offset:.2em!important}
/* Case study cards on charcoal: "Read the case study" was dark green on charcoal (1.7:1).
   It now uses the card title's mint (8.9:1). */
html body[class] .case-card .case-read{color:rgb(184,218,195)!important}
/* Service diagrams: the location label ("Storm drain") was 1.9:1 on the dark panel. It now uses
   the caption grey used on dark cards (8.2:1). The inactive step labels are dimmed in the diagram's
   own markup, at 55% opacity (5.1:1) instead of 35%. */
html body[class] .service-diagram-context{color:#b0bdb3!important}
/* Footer column headings are now h2 (they were h4, which skipped a level). The generic
   .restored-content h2 measure and balance do not apply to them, so they render exactly as before. */
html:root body[class][class][class] footer.unified-footer .footer-col>h2{font-size:17px!important;line-height:1.4!important;max-width:none!important;overflow-wrap:break-word!important;text-wrap:wrap!important}
/* The homepage sets large section headings with !important on .restored-content h2, and the footer
   carries that class, so its column headings grew to 53px there. The rule above pins them. */
/* 404: the content now sits in a <main> landmark. The page body is a centred flex column, so main
   repeats that layout and the page looks exactly as before. */
html body.family-recovery-page>main#main{display:flex;flex-direction:column;align-items:center;width:100%;margin:0;padding:0}
html body.family-recovery-page>main#main>.page-reading-tools{display:none!important}

/* Hero video control: icon only (Joe, 11 Nov 2026). A 48px square with the site button radius and a thin line
   play or pause icon; the spoken name ("Play video" / "Pause video") is on the button's aria-label. */
html:root body[class] .video-control.vc-icon-only{display:inline-grid!important;place-items:center!important;width:48px!important;min-width:48px!important;max-width:48px!important;height:48px!important;min-height:48px!important;padding:0!important;gap:0!important;line-height:0!important;font-size:0!important}
html:root body[class] .video-control.vc-icon-only svg{display:block;width:20px;height:20px;transition:transform .2s ease}
html:root body[class] .video-control.vc-icon-only:is(:hover,:focus-visible) svg{transform:scale(1.12)}
@media (prefers-reduced-motion:reduce){html:root body[class] .video-control.vc-icon-only svg{transition:none}html:root body[class] .video-control.vc-icon-only:is(:hover,:focus-visible) svg{transform:none}}



/* Green buttons: on hover the arrow sat on a dark tile in the same dark colour and vanished.
   The tile is now a light tint of the arrow colour, so the arrow stays visible. */
html:root body[class] .approved-button.approved-primary:hover .approved-arrow{background:rgba(11,28,19,.14)!important}

/* Emergency contact section: two columns from 1024px (Joe, 11 Nov 2026). The call to action sits
   on the left, centred vertically against the request form on the right. */
@media (min-width:1024px){
  html:root body[class] #contact-cta>.section-inner{display:grid!important;grid-template-columns:minmax(0,.85fr) minmax(0,1.15fr);grid-template-rows:1fr auto auto auto auto 1fr;column-gap:clamp(40px,5vw,80px);align-items:start}
  html:root body[class] #contact-cta>.section-inner>:nth-child(1){grid-row:2}
  html:root body[class] #contact-cta>.section-inner>h2{grid-row:3}
  html:root body[class] #contact-cta>.section-inner>.cta-sub{grid-row:4}
  html:root body[class] #contact-cta>.section-inner>.cta-buttons{grid-row:5}
  html:root body[class] #contact-cta>.section-inner>*{grid-column:1;min-width:0}
  html:root body[class] #contact-cta>.section-inner>details.mobile-home-detail{display:block!important;grid-column:2;grid-row:1/-1;margin:0!important;min-width:0}
  html:root body[class] #contact-cta>.section-inner>details.mobile-home-detail>summary{display:none!important}
  html:root body[class] #contact-cta>.section-inner .contact-form-wrap{margin-top:0!important;padding:clamp(28px,3vw,48px)!important}
  html:root body[class] #contact-cta>.section-inner>h2{font-size:clamp(34px,3.4vw,52px)!important;line-height:1.08!important;text-wrap:balance}
  html:root body[class] #contact-cta>.section-inner>.cta-buttons{flex-wrap:wrap}
}

/* ---------- Response Sequence scene (Joe, 11 Nov 2026) ----------
   Same isometric style and motion language as the Our Software trade scenes: shaded volumes on a
   site slab, a record card and a review card joined to the scene by flowing dashed links. The
   stage buttons drive it: 01 the record is read and the containment line is traced, 02 the hose
   draws the release into the tank, 03 the drums are staged and the review card is checked.
   Markup comes from build-tools/build_sequence_scene.py. */
html:root body[class] .sequence-diagram.sq{position:relative;max-width:none!important;width:100%!important;margin:16px 0 20px!important;aspect-ratio:600/330;border:1px solid #344c3d;border-radius:14px;overflow:hidden;background:radial-gradient(ellipse at 48% 66%,#2d3935 0%,#1b2221 45%,#111516 85%);color:#dcefe2}
html:root body[class] .sequence-diagram.sq svg.sq-scene{display:block;width:100%;height:100%;overflow:hidden}
html:root body[class] .sequence-diagram.sq .diagram-label{color:#b6d0bf!important;white-space:nowrap}
html:root body[class] .sequence-diagram.sq .label-scene{left:5.2%!important;right:auto!important;top:33%!important;bottom:auto!important}
html:root body[class] .sequence-diagram.sq .label-recovery{right:5.2%!important;left:auto!important;top:76%!important;bottom:auto!important}
.sq-scene .sq-ground-shadow{fill:#020707;opacity:.65;filter:blur(9px)}
.sq-scene .sq-top{fill:url(#sq-top-m);stroke:#bfd6cc;stroke-width:.85}
.sq-scene .sq-front{fill:url(#sq-front-m);stroke:#86a99a;stroke-width:.8}
.sq-scene .sq-side{fill:url(#sq-side-m);stroke:#638476;stroke-width:.8}
.sq-scene .sq-foundation .sq-top{fill:#3a4b44;stroke:#71877b}
.sq-scene .sq-foundation .sq-front{fill:#25352f;stroke:#52695d}
.sq-scene .sq-foundation .sq-side{fill:#192720;stroke:#40584b}
.sq-scene .sq-site{fill:#394b42}
.sq-scene .sq-site-rule{stroke:#6c8879;stroke-width:1;opacity:.45}
.sq-scene .sq-asphalt{fill:#283b32;stroke:#637f6d;stroke-width:.8}
.sq-scene .sq-lane{stroke:#9fb5a8;stroke-width:1.4;stroke-dasharray:9 9;opacity:.55}
.sq-scene .sq-contact{fill:#07100c;opacity:.5}
.sq-scene .sq-trunk{stroke:#9fb39a;stroke-width:4}
.sq-scene .sq-canopy{fill:url(#sq-canopy-m);stroke:#a3c6a1;stroke-width:1}
.sq-scene .sq-leaf{stroke:#bfddae;stroke-width:1.3;opacity:.5}
.sq-scene .sq-cone-base{fill:#1c3528;stroke:#8dba9c;stroke-width:.8}
.sq-scene .sq-cone{fill:#adc7aa;stroke:#d5e7cf;stroke-width:.8}
.sq-scene .sq-chassis .sq-top,.sq-scene .sq-chassis .sq-front{fill:#26372f;stroke:#7e9386}
.sq-scene .sq-chassis .sq-side{fill:#14271d;stroke:#789080}
.sq-scene .sq-tank .sq-top{fill:#c4d2ce}
.sq-scene .sq-tank .sq-front{fill:#809c92}
.sq-scene .sq-tank .sq-side{fill:#425e53}
.sq-scene .sq-tank-band{fill:#52d167;opacity:.35;transition:opacity .5s ease}
.sq-scene .sq-cab .sq-top,.sq-scene .sq-cab .sq-front{fill:#b3d7b7;stroke:#daf2da}
.sq-scene .sq-glass{fill:url(#sq-glass-m);stroke:#2a5346;stroke-width:.8}
.sq-scene .sq-pallet .sq-top{fill:#516f62;stroke:#8fae9d}
.sq-scene .sq-pallet .sq-front{fill:#33483f;stroke:#6c8879}
.sq-scene .sq-pallet .sq-side{fill:#24352e;stroke:#5a7466}
.sq-scene .sq-drum .sq-top{fill:#d0e1d8}
.sq-scene .sq-drum .sq-front{fill:#74b89c}
.sq-scene .sq-spill{transform-box:fill-box;transform-origin:center;transition:transform .7s cubic-bezier(.16,1,.3,1),opacity .5s ease}
.sq-scene .sq-pool{fill:url(#sq-pool-m);fill-opacity:.85;stroke:#b9f2c8;stroke-width:1.3}
.sq-scene .sq-sheen{fill:#d9ffe2;fill-opacity:.22}
.sq-scene .sq-boom{stroke:#c2dfcf;stroke-width:4;transition:opacity .5s ease}
.sq-scene .sq-trace{stroke:#74e59a;stroke-width:2.4;stroke-dasharray:16 84;stroke-dashoffset:100;opacity:0;transition:opacity .4s ease}
.sq-scene .sq-hose{stroke:#16241d;stroke-width:6}
.sq-scene .sq-flow{stroke:#8df0a4;stroke-width:2;stroke-dasharray:5 9}
.sq-scene .sq-recover,.sq-scene .sq-drums,.sq-scene .sq-clean{opacity:0;transition:opacity .5s ease}
.sq-scene .sq-clean-check{stroke:#bdf5cb;stroke-width:5;stroke-dasharray:1;stroke-dashoffset:1;transition:stroke-dashoffset .6s cubic-bezier(.65,0,.35,1) .15s}
.sq-scene .sq-card rect{fill:#1b2b25;stroke:#749783;stroke-width:1.2;transition:fill .4s ease,stroke .4s ease}
.sq-scene .sq-card path,.sq-scene .sq-card circle{stroke:#b1d6c2;stroke-width:2}
.sq-scene .sq-card{transition:opacity .4s ease}
.sq-scene .sq-link{stroke:#7ebd9a;stroke-width:1.4;stroke-dasharray:4 7;opacity:.35;transition:opacity .4s ease}
.sq-scene .sq-review-check{stroke:#8df0a4!important;stroke-width:3!important;stroke-dasharray:1;stroke-dashoffset:1;transition:stroke-dashoffset .5s cubic-bezier(.65,0,.35,1) .35s}
.sq-scene .sq-review-find{transition:opacity .3s ease}
@keyframes sq-link-flow{to{stroke-dashoffset:-66}}
@keyframes sq-trace-run{to{stroke-dashoffset:0}}
@keyframes sq-flow-run{to{stroke-dashoffset:-84}}
@keyframes sq-card-read{0%,100%{fill:#1b2b25;stroke:#749783}40%,60%{fill:#344b40;stroke:#bce8c9}}
@keyframes sq-pool-breathe{0%,100%{fill-opacity:.7}50%{fill-opacity:.95}}
/* 01 Assess & Contain */
html:root body[class] .process-experience[data-phase="0"] .sq-record rect{animation:sq-card-read 5s ease-in-out infinite}
html:root body[class] .process-experience[data-phase="0"] .sq-record-link{opacity:.8;animation:sq-link-flow 6s linear infinite}
html:root body[class] .process-experience[data-phase="0"] .sq-trace{opacity:.95;animation:sq-trace-run 5s linear infinite}
html:root body[class] .process-experience[data-phase="0"] .sq-pool{animation:sq-pool-breathe 5s ease-in-out infinite}
html:root body[class] .process-experience[data-phase="0"] .sq-review{opacity:.5}
/* 02 Recover & Clean */
html:root body[class] .process-experience[data-phase="1"] .sq-spill{transform:scale(.58)}
html:root body[class] .process-experience[data-phase="1"] .sq-recover{opacity:1}
html:root body[class] .process-experience[data-phase="1"] .sq-flow{animation:sq-flow-run 3.2s linear infinite}
html:root body[class] .process-experience[data-phase="1"] .sq-tank-band{opacity:1}
html:root body[class] .process-experience[data-phase="1"] .sq-review{opacity:.5}
/* 03 Coordinate Disposal */
html:root body[class] .process-experience[data-phase="2"] .sq-spill{transform:scale(.12);opacity:0}
html:root body[class] .process-experience[data-phase="2"] .sq-boom{opacity:.35}
html:root body[class] .process-experience[data-phase="2"] .sq-clean,html:root body[class] .process-experience[data-phase="2"] .sq-drums{opacity:1}
html:root body[class] .process-experience[data-phase="2"] .sq-clean-check,html:root body[class] .process-experience[data-phase="2"] .sq-review-check{stroke-dashoffset:0}
html:root body[class] .process-experience[data-phase="2"] .sq-review-find{opacity:0}
html:root body[class] .process-experience[data-phase="2"] .sq-review rect{fill:#344b40;stroke:#bce8c9}
html:root body[class] .process-experience[data-phase="2"] .sq-review-link{opacity:.8;animation:sq-link-flow 6s linear infinite}
@media (prefers-reduced-motion:reduce){.sq-scene *{animation:none!important;transition:none!important}}
body.motion-paused .sq-scene *{animation:none!important}
.sequence-diagram.sq:not(.art-visible) .sq-scene *{animation-play-state:paused}

/* ---------- Our Software radar graphic (Joe, 11 Nov 2026) ----------
   Range ticks, six signals that light as the sweep passes them, and two states tied to the
   existing tabs: Review joins the relevant signals to the centre and shows a record card,
   Follow Up draws one route and ticks its card. Markup: build-tools/build_radar_orbit.py. */
html:root body[class] #radar .radar-orbit-drawing.rx{--rx-t:8s;overflow:visible!important}
html:root body[class] #radar .radar-orbit-drawing.rx>:is(.orbit-ring,.orbit-axis,.orbit-point){display:none!important}
html:root body[class] #radar .radar-orbit-drawing.rx>.rx-layer{position:absolute;inset:0;width:100%;height:100%;overflow:visible;z-index:1}
html:root body[class] #radar .radar-orbit-drawing.rx>.orbit-sweep{inset:2.94%!important;border-radius:50%;background:conic-gradient(from 0deg,transparent 0deg,transparent 250deg,rgba(82,209,103,.05) 300deg,rgba(116,229,154,.34) 360deg)!important;animation:rx-sweep var(--rx-t) linear infinite!important;transition:opacity .5s ease}
html:root body[class] #radar .radar-orbit-drawing.rx>.orbit-sweep::after{content:"";position:absolute;left:calc(50% - 1px);top:0;width:2px;height:50%;border-radius:2px;background:linear-gradient(to top,rgba(141,240,164,0),#8df0a4);box-shadow:0 0 12px rgba(116,229,154,.7)}
html:root body[class] #radar .radar-orbit-drawing.rx>.orbit-center{z-index:3;transition:background .4s ease,border-color .4s ease,box-shadow .4s ease}
.rx-layer .rx-ring{stroke:rgba(150,200,165,.3);stroke-width:1}
.rx-layer .rx-ring-0{fill:rgba(82,209,103,.05)}
.rx-layer .rx-axis{stroke:rgba(150,200,165,.16);stroke-width:1}
.rx-layer .rx-tick{stroke:rgba(150,200,165,.3);stroke-width:1}
.rx-layer .rx-tick-major{stroke:rgba(170,225,185,.6);stroke-width:1.4}
.rx-layer .rx-blip{transition:opacity .5s ease}
.rx-layer .rx-dot{fill:#74e59a}
.rx-layer .rx-halo{fill:rgba(116,229,154,.12);stroke:rgba(116,229,154,.25);stroke-width:1;transition:fill .4s ease,stroke .4s ease}
.rx-layer .rx-ping{stroke:#8df0a4;stroke-width:1.2;opacity:0;transform-box:fill-box;transform-origin:center}
.rx-layer .rx-link{stroke:#7ebd9a;stroke-width:1.3;stroke-dasharray:4 6;opacity:0;transition:opacity .5s ease}
.rx-layer .rx-chip{opacity:0;transition:opacity .45s ease}
.rx-layer .rx-chip rect{fill:#1b2b25;stroke:#749783;stroke-width:1.2}
.rx-layer .rx-chip path{stroke:#b1d6c2;stroke-width:2}
.rx-layer .rx-chip .rx-leader{stroke:#7ebd9a;stroke-width:1.2;stroke-dasharray:3 5}
.rx-layer .rx-chip-check{stroke:#8df0a4!important;stroke-width:3!important;stroke-dasharray:1;stroke-dashoffset:1;transition:stroke-dashoffset .5s cubic-bezier(.65,0,.35,1) .3s}
@keyframes rx-sweep{to{transform:rotate(360deg)}}
@keyframes rx-lit{0%{opacity:1}12%{opacity:1}70%,100%{opacity:.38}}
@keyframes rx-ping{0%{opacity:.9;transform:scale(1)}30%,100%{opacity:0;transform:scale(4.2)}}
@keyframes rx-link-flow{to{stroke-dashoffset:-40}}
/* Monitor: every signal lights as the sweep reaches its bearing. */
html:root body[class] #radar .radar-visual[data-radar-step="0"] .rx-blip{opacity:.38;animation:rx-lit var(--rx-t) linear var(--rx-delay) infinite}
html:root body[class] #radar .radar-visual[data-radar-step="0"] .rx-ping{animation:rx-ping var(--rx-t) ease-out var(--rx-delay) infinite}
/* Review: the relevant signals join the centre, the rest step back. */
html:root body[class] #radar .radar-visual:is([data-radar-step="1"],[data-radar-step="2"]) .orbit-sweep{opacity:.3}
html:root body[class] #radar .radar-visual:is([data-radar-step="1"],[data-radar-step="2"]) .rx-blip:not(.rx-key){opacity:.22}
html:root body[class] #radar .radar-visual[data-radar-step="1"] .rx-key .rx-halo{fill:rgba(116,229,154,.2);stroke:#8df0a4}
html:root body[class] #radar .radar-visual[data-radar-step="1"] .rx-link{opacity:.85;animation:rx-link-flow 4s linear infinite}
html:root body[class] #radar .radar-visual[data-radar-step="1"] .rx-chip-review{opacity:1}
/* Follow Up: one signal is chosen, its route is solid and its card is ticked. */
html:root body[class] #radar .radar-visual[data-radar-step="2"] .rx-key:not(.rx-blip-b){opacity:.3}
html:root body[class] #radar .radar-visual[data-radar-step="2"] .rx-blip-b .rx-halo{fill:rgba(116,229,154,.28);stroke:#8df0a4;stroke-width:1.6}
html:root body[class] #radar .radar-visual[data-radar-step="2"] .rx-link-b{opacity:1;stroke-dasharray:none;stroke:#8df0a4;stroke-width:1.8}
html:root body[class] #radar .radar-visual[data-radar-step="2"] .rx-chip-action{opacity:1}
html:root body[class] #radar .radar-visual[data-radar-step="2"] .rx-chip-check{stroke-dashoffset:0}
html:root body[class] #radar .radar-visual[data-radar-step="2"] .rx>.orbit-center{border-color:#8df0a4!important;box-shadow:0 0 0 6px rgba(116,229,154,.12)!important}
@media (prefers-reduced-motion:reduce){html:root body[class] #radar .radar-orbit-drawing.rx>.orbit-sweep,.rx-layer *{animation:none!important;transition:none!important}html:root body[class] #radar .radar-visual[data-radar-step="0"] .rx-blip{opacity:.85}}
body.motion-paused #radar .rx>.orbit-sweep,body.motion-paused .rx-layer *{animation:none!important}
body.motion-paused #radar .radar-visual[data-radar-step="0"] .rx-blip{opacity:.85}
#radar .radar-visual.motion-offscreen .rx>.orbit-sweep,#radar .radar-visual.motion-offscreen .rx-layer *{animation-play-state:paused!important}

/* Preview row icons: the three text symbols rendered at different sizes (the house was small).
   They are now drawn icons at one size. */
html:root body[class] #radar .preview-source-icon>svg{display:block;width:20px;height:20px}

/* Radar graphic centring: its column starts at the frame edge, so the gap to the preview card made
   it sit left of centre, and the frame's 20px/10px padding put it 5px low. Both are corrected while
   the frame has two columns (above 1000px). */
@media (min-width:1001px){html:root body[class] #radar .radar-visual .radar-orbit{position:relative;left:calc(clamp(28px,4vw,64px)/2);top:-5px}}



/* Dots under the swipe row (phones only). The current card's dot is a short green bar. */
html:root body[class] #support-routes>.sp-dots{display:none}
@media (max-width:767px){
  html:root body[class] #support-routes>.sp-dots{display:flex;justify-content:center;align-items:center;gap:8px;margin:8px 0 20px}
  html:root body[class] #support-routes>.sp-dots>i{display:block;width:6px;height:6px;border-radius:3px;background:rgba(214,229,218,.35);transition:width .25s ease,background .25s ease}
  html:root body[class] #support-routes>.sp-dots>i.on{width:20px;background:var(--p-accent,#52D167)}
}
@media (prefers-reduced-motion:reduce){html:root body[class] #support-routes>.sp-dots>i{transition:none}}

/* ---------- Case study icons in looping motion (Joe, 11 Nov 2026) ----------
   Parts come from build-tools/build_case_icons.py. Each loop shows what the icon stands for and
   stays inside the icon box. The older trace overlay is switched off on these icons because it
   would stay still while the parts move. */
svg.ci{overflow:visible}
svg.ci :is(.case-drawing-trace,.case-icon-activity){display:none!important}
svg.ci .ci-p{transform-box:view-box;animation-duration:4s;animation-timing-function:ease-in-out;animation-iteration-count:infinite;animation-delay:var(--case-delay,0s)}
/* Crew: the lead nods while the two beside them lean in, one after the other. */
.ci-crew .ci-mid{animation-name:ci-bob}
.ci-crew .ci-left{animation-name:ci-lean-r}
.ci-crew .ci-right{animation-name:ci-lean-l}
@keyframes ci-bob{0%,100%{transform:translateY(0)}50%{transform:translateY(-1.6px)}}
@keyframes ci-lean-r{0%,55%,100%{transform:translateX(0);opacity:.55}20%,35%{transform:translateX(2px);opacity:1}}
@keyframes ci-lean-l{0%,45%,100%{transform:translateX(0);opacity:.55}65%,80%{transform:translateX(-2px);opacity:1}}
/* Excavator: the boom lowers, the bucket curls, then both lift. */
.ci-dig .ci-arm{transform-origin:36px 31px;animation-name:ci-arm;animation-duration:4.6s}
.ci-dig .ci-bucket{transform-origin:54px 18px;animation-name:ci-bucket;animation-duration:4.6s}
.ci-dig .ci-track{stroke-dasharray:5 4;animation-name:ci-track;animation-timing-function:linear;animation-duration:4.6s}
@keyframes ci-arm{0%,100%{transform:rotate(0)}40%,55%{transform:rotate(9deg)}}
@keyframes ci-bucket{0%,35%,100%{transform:rotate(0)}55%,75%{transform:rotate(-22deg)}}
@keyframes ci-track{to{stroke-dashoffset:-18}}
/* Drum: a drip falls in, the surface ripples and the fill bands rise. */
.ci-drum .ci-drip{animation-name:ci-drip;animation-timing-function:ease-in}
.ci-drum .ci-top{transform-origin:32px 13px;animation-name:ci-top}
.ci-drum .ci-band{animation-name:ci-band}
.ci-drum .ci-band-2{animation-delay:calc(var(--case-delay,0s) + .5s)}
@keyframes ci-drip{0%{transform:translateY(0);opacity:0}8%{opacity:1}30%{transform:translateY(13px);opacity:1}36%,100%{transform:translateY(14px);opacity:0}}
@keyframes ci-top{0%,30%,60%,100%{transform:scale(1)}40%{transform:scale(1.06,1.25)}}
@keyframes ci-band{0%,25%{transform:translateY(5px);opacity:.25}55%,85%{transform:translateY(0);opacity:1}100%{transform:translateY(5px);opacity:.25}}
/* Truck: the body rides on its wheels while the road runs underneath. */
.ci-truck .ci-body{animation-name:ci-ride;animation-duration:.9s}
.ci-truck .ci-road{stroke-dasharray:7 6;animation-name:ci-road;animation-duration:1.1s;animation-timing-function:linear}
@keyframes ci-ride{0%,100%{transform:translateY(0)}50%{transform:translateY(-1.1px)}}
@keyframes ci-road{to{stroke-dashoffset:13}}
/* Bin: the lid tips open, a pellet drops in, the lid closes. */
.ci-bin .ci-lid{transform-origin:55px 22px;animation-name:ci-lid}
.ci-bin .ci-pellet{animation-name:ci-pellet;animation-timing-function:ease-in}
.ci-bin .ci-bar{animation-name:ci-bar}
.ci-bin .ci-bar-2{animation-delay:calc(var(--case-delay,0s) + .15s)}
.ci-bin .ci-bar-3{animation-delay:calc(var(--case-delay,0s) + .3s)}
@keyframes ci-lid{0%,10%,70%,100%{transform:rotate(0)}25%,55%{transform:rotate(14deg)}}
@keyframes ci-pellet{0%,22%{transform:translateY(0);opacity:0}28%{opacity:1}50%{transform:translateY(20px);opacity:1}56%,100%{transform:translateY(22px);opacity:0}}
@keyframes ci-bar{0%,50%,100%{opacity:.45}62%,80%{opacity:1}}
/* Record: the three lines write in, hold, then clear. */
.ci-doc .ci-line{stroke-dasharray:1;animation-name:ci-write;animation-duration:5s}
.ci-doc .ci-line-2{animation-name:ci-write-2}
.ci-doc .ci-line-3{animation-name:ci-write-3}
@keyframes ci-write{0%{stroke-dashoffset:1;opacity:1}18%,85%{stroke-dashoffset:0;opacity:1}95%,100%{stroke-dashoffset:0;opacity:0}}
@keyframes ci-write-2{0%,18%{stroke-dashoffset:1;opacity:1}36%,85%{stroke-dashoffset:0;opacity:1}95%,100%{stroke-dashoffset:0;opacity:0}}
@keyframes ci-write-3{0%,36%{stroke-dashoffset:1;opacity:1}50%,85%{stroke-dashoffset:0;opacity:1}95%,100%{stroke-dashoffset:0;opacity:0}}
/* Night: the moon rocks slowly and the stars twinkle. */
.ci-night .ci-moon{transform-origin:31px 33px;animation-name:ci-rock;animation-duration:6s}
.ci-night .ci-star-1{transform-origin:51px 14px;animation-name:ci-twinkle;animation-duration:2.6s}
.ci-night .ci-star-2{transform-origin:58px 29px;animation-name:ci-twinkle;animation-duration:2.6s;animation-delay:calc(var(--case-delay,0s) + 1.3s)}
@keyframes ci-rock{0%,100%{transform:rotate(-4deg)}50%{transform:rotate(4deg)}}
@keyframes ci-twinkle{0%,100%{transform:scale(.55) rotate(0);opacity:.4}50%{transform:scale(1.1) rotate(45deg);opacity:1}}
/* Washer: the wand sweeps a little while the spray runs outward. */
.ci-wash .ci-wand{transform-origin:10px 16px;animation-name:ci-sweep;animation-duration:3.4s}
.ci-wash .ci-spray{stroke-dasharray:3 3.5;animation-name:ci-spray;animation-duration:.7s;animation-timing-function:linear}
.ci-wash .ci-spray-2{animation-duration:.85s}
.ci-wash .ci-spray-3{animation-duration:.6s}
@keyframes ci-sweep{0%,100%{transform:rotate(-2.5deg)}50%{transform:rotate(3deg)}}
@keyframes ci-spray{to{stroke-dashoffset:-13}}
/* Drop: the bead swells and settles, its highlight shimmers, a ripple spreads on the ground. */
.ci-drop .ci-bead{transform-origin:32px 55px;animation-name:ci-bead;animation-duration:3.4s}
.ci-drop .ci-shine{animation-name:ci-shine;animation-duration:3.4s}
.ci-drop .ci-ripple{transform-origin:32px 60px;animation-name:ci-ripple;animation-duration:3.4s}
@keyframes ci-bead{0%,100%{transform:scale(1) translateY(0)}45%{transform:scale(1.03,.96) translateY(1px)}70%{transform:scale(.98,1.03) translateY(-1.5px)}}
@keyframes ci-shine{0%,100%{opacity:.45}55%{opacity:1}}
@keyframes ci-ripple{0%,40%{transform:scaleX(.2);opacity:0}50%{opacity:.9}85%,100%{transform:scaleX(1.5);opacity:0}}
@media (prefers-reduced-motion:reduce){svg.ci .ci-p{animation:none!important}svg.ci :is(.ci-drip,.ci-pellet,.ci-ripple){opacity:0}}
body.motion-paused svg.ci .ci-p{animation:none!important}
body.motion-paused svg.ci :is(.ci-drip,.ci-pellet,.ci-ripple){opacity:0}
svg.ci.ci-off .ci-p{animation-play-state:paused}

/* ---------- Case study list (Joe, 11 Nov 2026) ----------
   The three cards were full-width rows with a tall photo and a mostly empty text column. They are
   now a grid: three across on desktop, two on tablet, one on phones. Photo on top at one shape,
   text below, the read link pinned to the bottom, and the whole card is the link. */
html:root body[class] .case-card-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,300px),1fr));gap:24px;margin:0 0 40px}
html:root body[class] .case-card-grid>.case-card{position:relative;display:flex!important;flex-direction:column;gap:0!important;margin:0!important;padding:0!important;overflow:hidden;height:100%;transition:border-color .2s ease,transform .2s ease}
html:root body[class] .case-card-grid>.case-card>.family-photo{margin:0!important;width:100%!important;max-width:none!important}
html:root body[class] .case-card-grid>.case-card>.family-photo>img{display:block;width:100%!important;height:auto!important;aspect-ratio:4/3;object-fit:cover;border-radius:0!important}
html:root body[class] .case-card-grid>.case-card>.family-photo>figcaption{padding:10px 24px 0!important;margin:0!important}
html:root body[class] .case-card-grid>.case-card>h2{margin:18px 24px 10px!important;max-width:none!important}
html:root body[class] .case-card-grid>.case-card>.body-copy{margin:0 24px 16px!important;max-width:none!important}
html:root body[class] .case-card-grid>.case-card>.body-copy:last-child{margin-top:auto!important;margin-bottom:24px!important}
html:root body[class] .case-card-grid>.case-card>h2>a::after{content:"";position:absolute;inset:0;z-index:1}
html:root body[class] .case-card-grid>.case-card:is(:hover,:focus-within){border-color:var(--p-accent,#52D167)!important}
html:root body[class] .case-card-grid>.case-card:is(:hover,:focus-within) .case-read{text-decoration:underline;text-underline-offset:.2em}
@media (hover:hover){html:root body[class] .case-card-grid>.case-card:hover{transform:translateY(-2px)}}
@media (prefers-reduced-motion:reduce){html:root body[class] .case-card-grid>.case-card{transition:none;transform:none!important}}

/* ---------- Step cards (Joe, 11 Nov 2026) ----------
   The icon sits beside the heading instead of above it, which removes a row from every card. */
html:root body[class] .family-sequence-node{display:grid!important;grid-template-columns:auto minmax(0,1fr);column-gap:16px;align-items:center;align-content:start}
html:root body[class] .family-sequence-node>*{grid-column:1/-1}
html:root body[class] .family-sequence-node>svg{grid-column:1;grid-row:2;width:44px!important;height:44px!important;margin:0!important}
html:root body[class] .family-sequence-node>svg+h3{grid-column:2;grid-row:2;margin:0!important}
html:root body[class] .family-sequence-node>svg+h3+p{margin-top:14px!important}
/* Step icons in motion (parts from build-tools/build_step_icons.py). */
.ci-find .ci-lens{animation-name:ci-scan;animation-duration:5s}
.ci-find .ci-plus{transform-origin:20px 20px;animation-name:ci-pulse;animation-duration:2.5s}
@keyframes ci-scan{0%,100%{transform:translate(0,0)}25%{transform:translate(3px,-1.5px)}50%{transform:translate(4px,2.5px)}75%{transform:translate(-1px,3px)}}
@keyframes ci-pulse{0%,100%{transform:scale(.8);opacity:.6}50%{transform:scale(1.08);opacity:1}}
.ci-shield .ci-guard{transform-origin:24px 24px;animation-name:ci-guard}
.ci-shield .ci-tick{stroke-dasharray:1;animation-name:ci-tick}
@keyframes ci-guard{0%,100%{transform:scale(1)}50%{transform:scale(1.035)}}
@keyframes ci-tick{0%,12%{stroke-dashoffset:1;opacity:1}38%,85%{stroke-dashoffset:0;opacity:1}96%,100%{stroke-dashoffset:0;opacity:0}}
.ci-kit .ci-handle{animation-name:ci-lift;animation-duration:3.2s}
.ci-kit .ci-cross{transform-origin:23px 28px;animation-name:ci-pulse;animation-duration:3.2s}
@keyframes ci-lift{0%,60%,100%{transform:translateY(0)}25%,40%{transform:translateY(-2.2px)}}
.ci-rig .ci-reach{transform-origin:26px 22px;animation-name:ci-reach;animation-duration:4.6s}
@keyframes ci-reach{0%,100%{transform:rotate(0)}40%,55%{transform:rotate(14deg)}}
.family-sequence-node>svg.ci.motion-art *{stroke-dasharray:none}
.ci-shield .ci-tick,.ci-doc .ci-line{stroke-dasharray:1!important}

/* Photo loops on the case study list: the clip covers the photo exactly and fades in. */
html:root body[class] .case-card-grid>.case-card>.family-photo{position:relative}
/* The photo keeps still under its clip (the older slow zoom would not line up with the clip). */
html:root body[class] .case-card-grid>.case-card>.family-photo>img[data-loop]{scale:1!important;transform:none!important;animation:none!important}
html:root body[class] .case-card-grid>.case-card>.family-photo>video.sp-loop{position:absolute;top:0;left:0;width:100%;height:auto;aspect-ratio:4/3;object-fit:cover;opacity:0;transition:opacity .7s ease;pointer-events:none}
html:root body[class] .case-card-grid>.case-card>.family-photo>video.sp-loop.on{opacity:1}

/* ---------- Purposeful motion ---------- */
/* Readiness checklist: each check draws in order the first time the list is seen. */
.sp-draw path{stroke-dasharray:1;stroke-dashoffset:1}
.sp-drawn .sp-draw path{stroke-dashoffset:0;transition:stroke-dashoffset .5s cubic-bezier(.65,0,.35,1);transition-delay:var(--sp-delay,0ms)}
/* Capability icons: the line drawing traces once, then rests. */
.sp-trace :is(path,circle,rect,line,polyline){stroke-dasharray:var(--sp-len,60);stroke-dashoffset:var(--sp-len,60)}
.sp-traced .sp-trace :is(path,circle,rect,line,polyline){stroke-dashoffset:0;transition:stroke-dashoffset .9s cubic-bezier(.65,0,.35,1);transition-delay:var(--sp-delay,0ms)}
/* Call actions use the phone icon rather than the signal dot (approved direction). The header
   Call button already did; hero, closing-band and page call buttons now match it. Other primary
   buttons keep the dot. */
html:root body[class] a.approved-button.approved-primary[href^="tel:"]:not(.dynamic-call)::before{content:""!important;display:block!important;width:16px!important;height:16px!important;min-width:16px!important;max-height:16px!important;flex:0 0 16px!important;border-radius:0!important;background:currentColor!important;box-shadow:none!important;animation:none!important;mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='none' stroke='black' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round' d='M22 16.92v3a2 2 0 0 1-2.18 2 19.79 19.79 0 0 1-8.63-3.07 19.5 19.5 0 0 1-6-6A19.79 19.79 0 0 1 2.12 4.18 2 2 0 0 1 4.11 2h3a2 2 0 0 1 2 1.72c.13.96.37 1.9.7 2.79a2 2 0 0 1-.45 2.11L8.09 9.89a16 16 0 0 0 6 6l1.27-1.27a2 2 0 0 1 2.11-.45c.9.33 1.83.57 2.79.7A2 2 0 0 1 22 16.92z'/%3E%3C/svg%3E") center/contain no-repeat!important;-webkit-mask:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='none' stroke='black' stroke-width='1.9' stroke-linecap='round' stroke-linejoin='round' d='M22 16.92v3a2 2 0 0 1-2.18 2 19.79 19.79 0 0 1-8.63-3.07 19.5 19.5 0 0 1-6-6A19.79 19.79 0 0 1 2.12 4.18 2 2 0 0 1 4.11 2h3a2 2 0 0 1 2 1.72c.13.96.37 1.9.7 2.79a2 2 0 0 1-.45 2.11L8.09 9.89a16 16 0 0 0 6 6l1.27-1.27a2 2 0 0 1 2.11-.45c.9.33 1.83.57 2.79.7A2 2 0 0 1 22 16.92z'/%3E%3C/svg%3E") center/contain no-repeat!important}
/* Call actions: the handset rings briefly on hover or keyboard focus. Uses the rotate property
   so it is not blocked by the transform:none rules on these icons. */
@keyframes sp-ring{0%,100%{rotate:0deg}20%{rotate:-14deg}40%{rotate:12deg}60%{rotate:-8deg}80%{rotate:5deg}}
html:root body[class] a.approved-button.approved-primary[href^="tel:"]:not(.dynamic-call):is(:hover,:focus-visible)::before,html:root body[class] a[href^="tel:"]:is(:hover,:focus-visible)::before,html:root body[class] a[href^="tel:"]:is(:hover,:focus-visible) svg{animation:sp-ring .6s ease-in-out 1!important;transform-origin:50% 50%}
/* Pressed state for every button-like control, so a tap is acknowledged. */
:is(.approved-button,.dynamic-call,.dynamic-menu,.gallery-toggle,.gallery-number-strip button,.finder-shortcuts a,.finder-shortcuts button,.county-map-choice,.atlas-focus,.atlas-reset):active{transform:scale(.98)!important;transition:transform .08s ease!important}

/* Motion off: reduced motion, the site Pause Motion control, or a hidden tab. */
@media (prefers-reduced-motion:reduce){
  .sp-draw path,.sp-trace :is(path,circle,rect,line,polyline){stroke-dashoffset:0!important;transition:none!important}
  html:root body[class] a.approved-button.approved-primary[href^="tel:"]:not(.dynamic-call):is(:hover,:focus-visible)::before,html:root body[class] a[href^="tel:"]:is(:hover,:focus-visible)::before,html:root body[class] a[href^="tel:"] svg{animation:none!important}
  :is(.approved-button,.dynamic-call,.dynamic-menu,.gallery-toggle,.gallery-number-strip button):active{transform:none!important}
  html body[class] main>.phase-rail{transition:none!important}
}
body.motion-paused :is(.sp-draw path,.sp-trace :is(path,circle,rect,line,polyline)){stroke-dashoffset:0!important;transition:none!important}
html:root body[class].motion-paused a.approved-button.approved-primary[href^="tel:"]:not(.dynamic-call):is(:hover,:focus-visible)::before,html:root body[class].motion-paused a[href^="tel:"]:is(:hover,:focus-visible)::before,html:root body[class].motion-paused a[href^="tel:"] svg{animation:none!important}

/* Ninth service (30 Nov 2026). Services page: with nine cards the call box no longer completes a 3x3, so it
   spans the row as it already does on narrower screens. Menu: nine rows take the height eight did. */
@media (min-width:1001px){html body.content-site .hub-grid>.service-grid-cta{grid-column:span 2;flex-direction:row;align-items:center;justify-content:space-between}html body.content-site .hub-grid>.service-grid-cta>div{width:auto;flex:1 1 0!important}}
@media (min-width:1024px) and (hover:hover) and (pointer:fine){html:root body[class] .dynamic-services li a{min-height:40px;padding-block:9px}}

/* ================= Audit fixes, 1 Dec 2026 ================= */

/* Motion 1: the homepage hero painted, vanished, then faded back in, because the intro animation started
   from opacity 0 only after a deferred script ran. The hero now stays as first painted. */
html:root body.response-control.motion-ready .hero-line-inner,
html:root body.motion-ready .hero-intro,html:root body.motion-ready .hero-actions,html:root body.motion-ready .hero-lead{animation:none!important;opacity:1!important;transform:none!important;filter:none!important}

/* Motion 9: the radar sweep kept running thousands of pixels off screen (its own !important outranked the
   off-screen rule). */
html:root body[class] .motion-offscreen .orbit-sweep,html:root body[class].sp-hero-off .production-scroll-cue .line,html:root body[class].sp-hero-off .scroll-cue-arrow{animation-play-state:paused!important}

/* Motion 10: the ticker jumped 20px at each loop. Two copies sit 40px apart, so one period is half the
   track plus half a gap. */
@keyframes option-ticker{to{transform:translateX(calc(-50% - 20px))}}

/* Motion 11: the header's size transition ignored reduced motion. */
@media (prefers-reduced-motion:reduce){html:root body[class] .dynamic-header,html:root body[class] .dynamic-header *{transition:none!important}
  html:root body[class] .motion-toggle{display:none!important}}

/* Motion 14: a tapped photo stayed zoomed on touch screens (:hover sticks after a tap). */
@media (hover:none){html:root body[class] .g-img:hover img,html:root body[class] .svc-img:hover,html:root body[class] .chapter-gallery img:hover{transform:none!important}}

/* Motion 8: on phones the phase rail is not sticky, so its "current step" highlight changed only after it had
   scrolled away. All three steps now read the same there. */
@media (max-width:768px){html:root body[class] .phase-rail .pr-fill{display:none}
  html:root body[class] .phase-rail li,html:root body[class] .phase-rail li.on{color:var(--p-heading,#213D30)}  /* was #fff: invisible on light pages (Lighthouse contrast 1.07, 2 Dec 2026) */
  html:root body[class] .phase-rail li span,html:root body[class] .phase-rail li.on span{background:transparent;border-color:var(--green,#31c950);color:var(--green,#31c950);box-shadow:none}}

/* Design 4: at tablet width the third gallery photo is hidden but the grid kept three columns. */
@media (max-width:768px){html:root body[class] .gallery{grid-template-columns:1fr 1fr!important}}
/* Design 5: two-photo galleries sat in a three-column grid with an empty column. */
@media (min-width:769px){html:root body[class] .gallery:has(> .g-img:nth-child(2):last-child){grid-template-columns:1fr 1fr!important}}

/* Design 15: single-word last lines in headings. */
html:root body[class] :is(h1,h2,h3){text-wrap:balance}
html:root body[class] :is(p.body-copy,p.intro,p.lead,.faq p,.full-faq-answer){text-wrap:pretty}

/* Design 10 / Motion 3: the Pause Motion strip sat below the fold of the open menu. It now stays pinned to
   the bottom edge of the menu panel. */
html:root body[class] .dynamic-navigation :is(.concept-strip,.page-utility){position:sticky;bottom:0;z-index:2}

/* Function 9: on the homepage the focused skip link sat half under the header. */
html:root body[class] a.skip:focus,html:root body[class] a.skip-link:focus{z-index:400}
/* Design 3: between phone and desktop widths the service diagram lost its step labels (the labels inside the
   drawing are hidden below 1200px and the caption only showed up to 640px), leaving three unlabelled dots. */
@media (min-width:641px) and (max-width:1199px){
  html:root body[class] .svc-anim .sa-ph,html:root body[class] .svc-anim .sa-lbl{display:none}
  html:root body[class] .svc-anim .sa-cap{display:grid!important;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px 16px;padding:4px 16px 18px;position:relative;font-size:13px;font-weight:600;color:#e8eaee}
  html:root body[class] .svc-anim .sa-cap span{display:flex;align-items:center;gap:10px}
  html:root body[class] .svc-anim .sa-cap b{width:22px;height:22px;border-radius:50%;background:var(--green,#31c950);color:var(--dark,#131316);display:grid;place-items:center;font-size:11px;font-weight:800;flex:none}
  html:root body[class] .svc-anim .sa-cap i{position:absolute;left:16px;right:16px;bottom:8px;height:3px;border-radius:2px;background:var(--green,#31c950);transform-origin:left}}

/* Design 6: orphaned grid items. Guides hub: four cards as 3 + 1. County pages: ten service links as 3/3/3/1.
   Inner-page footer: the fourth link group alone on a second row. */
@media (min-width:1200px){html body.content-site .hub-grid.cols4:has(> .hub-card:nth-child(4):last-child){grid-template-columns:repeat(4,minmax(0,1fr))!important}}
@media (min-width:761px) and (max-width:1199px){html body.content-site .hub-grid.cols4:has(> .hub-card:nth-child(4):last-child){grid-template-columns:repeat(2,minmax(0,1fr))!important}}
@media (min-width:769px){html:root body[class] ul.svc-grid:has(> li:nth-child(10):last-child){grid-template-columns:repeat(2,minmax(0,1fr))!important}}
@media (min-width:1100px){html:root body[class] .foot-extra:has(> details:nth-child(4)){grid-template-columns:.8fr 1.5fr 1.4fr 1fr!important}}

/* Design 7: on the case study index the intro ran straight into the next label, and the caption into the cards. */
html:root body[class] .family-page-lead>p.intro+section.family-visual{margin-top:36px}
html:root body[class] section.family-visual+.case-card-grid{margin-top:32px}

/* Design 8: guide pages. Step text ran 167 characters a line; the call band squeezed its heading into a
   narrow centred column. */
@media (min-width:1100px){html:root body[class] ol.family-guide-steps{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px;align-items:stretch}
  html:root body[class] ol.family-guide-steps>li{margin:0}}
html:root body[class] .cta-band:has(> h2){display:grid!important;grid-template-columns:minmax(0,1fr) auto;column-gap:32px;row-gap:6px;align-items:center;text-align:left!important;justify-items:start}
html:root body[class] .cta-band:has(> h2)>h2{grid-column:1;margin:0;max-width:none;width:auto;text-align:left}
html:root body[class] .cta-band:has(> h2)>p{grid-column:1;margin:0;max-width:60ch;text-align:left}
html:root body[class] .cta-band:has(> h2)>a{grid-column:2;grid-row:1/span 2}
@media (max-width:760px){html:root body[class] .cta-band:has(> h2){grid-template-columns:minmax(0,1fr)}
  html:root body[class] .cta-band:has(> h2)>a{grid-column:1;grid-row:auto;margin-top:10px}}

/* Design 11: the 404 page used pill buttons and bullet-separated link lists unlike the rest of the site. */
html:root body[class] .btns>a.primary,html:root body[class] .btns>a.secondary{border-radius:8px;min-height:48px;padding:12px 24px}
html:root body[class] .recover>div{display:flex;flex-wrap:wrap;justify-content:center;gap:0 22px}
html:root body[class] .recover>div>.lbl{flex-basis:100%}
html:root body[class] .recover>div>a{display:inline-flex;align-items:center;min-height:44px}

/* Design 16: small tap targets on phones. Hit areas grow; the layout does not move. */
@media (max-width:767px){
  html:root body[class] .footer-col li a{display:inline-block;padding-block:8px;margin-block:-8px}
  html:root body[class] .crumbs a{min-height:44px;padding-block:11px;margin-block:-6px}
  html:root body[class] .dynamic-header .dynamic-call{min-height:44px!important}}

/* Motion 5: on phones the "On This Page" control is added by a script and pushed the page down about 64px.
   Its row is now held open from the first paint (class set at build time, dropped when the script runs). */
@media (max-width:767px){html:root body.content-site .hero-ctas.sp-index:not(.unified-page-actions)::after{content:"";flex:0 0 100%;height:48px}}

/* Motion 7: with motion reduced, the steam cleaning and gas station diagram froze on a frame where the
   wand had left the picture. It now rests mid-pass. */
@media (prefers-reduced-motion:reduce){html:root body[class] .svc-anim:has(.sa2-wand) svg,html:root body[class] .svc-anim:has(.sa2-wand) svg *,html:root body[class] .svc-anim:has(.sa2-wand) .sa-cap *{animation-delay:-3.4s!important}}

/* Design 2: side panel beside the article on wide screens; questions in two columns.
   The panel is a zero-height block placed before the first paragraph, holding an absolutely placed track
   whose height (set by site-polish.js) ends at the call band; the card inside the track is sticky. The
   article's own blocks stay direct children of <main>, so no existing rule or script is disturbed. */
html:root body[class] main>.sp-rail{display:none}
@media (min-width:1400px){
  html:root body[class] main:has(>.sp-rail){position:relative}
  html:root body[class] main>.sp-rail{display:block;position:relative;height:0;margin:0;padding:0;max-width:none;width:auto}
  html:root body[class] main>.sp-rail>.sp-rail-track{position:absolute;top:0;right:0;width:320px;min-height:100px;pointer-events:none}
  html:root body[class] .sp-rail-card{position:sticky;top:116px;pointer-events:auto;display:grid;gap:12px;padding:24px;border:1px solid var(--p-border,#c9d8cd);border-radius:16px;background:var(--p-card,#fbfdf9)}
  html:root body[class] .sp-rail-kicker{margin:0 0 2px;font-size:13px;font-weight:600;letter-spacing:.02em;color:var(--p-muted,#4d6355);max-width:none}
  html:root body[class] .sp-rail-card>a.approved-button{display:flex;justify-content:space-between;width:100%;margin:0;box-sizing:border-box}
  html:root body[class] .sp-rail-nav{display:grid;margin-top:8px;padding-top:14px;border-top:1px solid var(--p-border,#c9d8cd)}
  html:root body[class] .sp-rail-nav>p{margin:0 0 4px;font-size:13px;font-weight:600;color:var(--p-muted,#4d6355);max-width:none}
  html:root body[class] .sp-rail-nav>a{display:flex;align-items:center;min-height:40px;padding:6px 0;font-size:15px;line-height:1.35;color:var(--p-heading,#1f3a2b);text-decoration:none;border-bottom:1px solid var(--p-border,#c9d8cd)}
  html:root body[class] .sp-rail-nav>a:last-child{border-bottom:0}
  html:root body[class] .sp-rail-nav>a:is(:hover,:focus-visible){text-decoration:underline;text-underline-offset:4px}
  /* wide blocks between the panel and the call band give it room */
  html:root body[class] main>.sp-rail~:is(section,figure,div,ul,ol):not(.cta-band,.cta-band~*){max-width:min(880px,calc(100% - 384px))!important}
  /* the hero's own "On This Page" control repeats the panel's list at this width */
  html:root body[class]:has(.sp-rail) .family-page-lead .page-section-index{display:none}
}
@media (min-width:1100px){
  html:root body[class] .sp-faq{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));column-gap:56px;align-items:start}
  html:root body[class] .sp-faq>.faq{max-width:none;width:auto}
  html:root body[class] .sp-faq>.faq:last-child:nth-child(odd){grid-column:1/-1;max-width:820px}
}

/* Layout shift fix (2 Dec 2026, seo_pass.py): reserve the On This Page control's slot in the hero. */
html:root body.content-site .hero-ctas.reserve-tools:not(:has(> .page-reading-tools))::after{content:"";display:block;flex:0 1 auto;width:162px;max-width:100%;height:48px}
/* Guides hub with seven guides: the first spans two cells so no card sits alone on a row. */
@media (min-width:1200px){html body.content-site .hub-grid:has(> a.hub-card[href^='/guides/']:nth-child(7):last-child){grid-template-columns:repeat(4,minmax(0,1fr))!important}}
@media (min-width:761px) and (max-width:1199px){html body.content-site .hub-grid:has(> a.hub-card[href^='/guides/']:nth-child(7):last-child){grid-template-columns:repeat(2,minmax(0,1fr))!important}}
@media (min-width:761px){html body.content-site .hub-grid:has(> a.hub-card[href^='/guides/']:nth-child(7):last-child)>.hub-card:first-child{grid-column:span 2}}
@media (min-width:761px){html body.content-site .hub-grid:has(> a.hub-card[href^='/guides/']:nth-child(7):last-child)>.hub-card:first-child h3{font-size:clamp(1.6rem,2.4vw,2.1rem)!important;line-height:1.15!important;max-width:16em}html body.content-site .hub-grid:has(> a.hub-card[href^='/guides/']:nth-child(7):last-child)>.hub-card:first-child p{font-size:1.08rem!important;max-width:30em}}

/* GEO pass (4 Dec 2026, geo_pass.py): the dated byline under each guide's heading. */
html body.content-site main .family-page-lead p.guide-updated{margin:.75rem 0 0!important;font-size:14px!important;line-height:1.4!important;letter-spacing:.01em;opacity:.75;max-width:none}
html body.content-site main .family-page-lead p.guide-updated time{font-weight:600}
/* Guides hub with eight guides: two full rows of four. */
@media (min-width:1200px){html body.content-site .hub-grid:has(> a.hub-card[href^='/guides/']:nth-child(8):last-child){grid-template-columns:repeat(4,minmax(0,1fr))!important}}
@media (min-width:761px) and (max-width:1199px){html body.content-site .hub-grid:has(> a.hub-card[href^='/guides/']:nth-child(8):last-child){grid-template-columns:repeat(2,minmax(0,1fr))!important}}

/* Design-phase palette link in the menu strip is hidden (30 Nov 2026 audit). */
html:root body[class] .concept-strip>a.palette-preview-link{display:none!important}
