/* Parker Eco Pest Control: shared design system. One dark ground everywhere; page stylesheets add only their set piece. */

/* Tokens: palette, type scale, spacing, scallop size (--s) and the 350 ms wipe; use these, never raw values */
:root{
  --ground:#00292a; --ink:#f2f8eb; --pink:#ff66b8; --cedar:#174846; --sage:#83a59c;
  --display:'Poiret One','Century Gothic','Avenir Next',sans-serif;
  --text:'IM Fell English','Iowan Old Style',Georgia,serif;
  --fs-h1:clamp(2.875rem,1.9rem + 3.4vw,4rem);
  --fs-h2:clamp(2.375rem,1.7rem + 2.4vw,3.25rem);
  --fs-h3:1.5rem; --fs-body:1.125rem; --fs-note:1rem; --fs-index:1.875rem;
  --inset:1.25rem; --gap:1.5rem; --band:clamp(2.5rem,9vh,6.5rem); --chrome:4.5rem;
  --s:.75rem; --bw:.1rem; --wipe:.35s;
  color-scheme:dark;
}
@media (min-width:48rem){
  :root{--fs-body:1.1875rem;--fs-index:clamp(2.25rem,3.8vw,3.25rem);--inset:clamp(2rem,4.5vw,4.5rem);--gap:clamp(2rem,4vw,4rem)}
}

/* Base reset */
*,*::before,*::after{box-sizing:border-box}
html{-webkit-text-size-adjust:100%;background:var(--ground)}
body{margin:0;min-height:100vh;background:var(--ground);color:var(--ink);font:400 var(--fs-body)/1.55 var(--text);font-synthesis:none}
img,video,svg{display:block;max-width:100%;height:auto}
h1,h2,h3,p,ul,ol,dl,dd,figure{margin:0}
ul,ol{padding:0;list-style:none}
button{font:inherit;color:inherit}
[hidden]{display:none!important}
main{display:block;padding-top:var(--chrome)}
main:focus{outline:none}

/* Headings: Poiret One, thin, mixed case, natural tracking; h1/.h1 for page heads, h2/.h2 for section heads, h3/.h3 in IM Fell */
h1,h2,.h1,.h2{font-family:var(--display);font-weight:400;line-height:1.12;letter-spacing:0;text-wrap:balance;overflow-wrap:break-word}
h1,.h1{font-size:var(--fs-h1)}
h2,.h2{font-size:var(--fs-h2)}
h3,.h3{font:400 var(--fs-h3)/1.25 var(--text)}

/* Text links: unboxed, underlined, pink underline on hover; .text-btn makes a button read as a text link (Previous, Next, explain) */
a{color:inherit;text-decoration:underline;text-decoration-thickness:.06em;text-underline-offset:.22em}
a:hover,.text-btn:hover{text-decoration-color:var(--pink);text-decoration-thickness:.12em}
.text-btn{display:inline-flex;align-items:center;min-height:2.75rem;padding:0;border:0;background:none;cursor:pointer;text-align:left;text-decoration:underline;text-decoration-thickness:.06em;text-underline-offset:.22em}
.text-btn[disabled]{color:var(--sage);text-decoration:none;cursor:default}

/* Focus: hot pink everywhere */
:focus-visible{outline:.15rem solid var(--pink);outline-offset:.2rem}

/* Skip link: .skip */
.skip{position:fixed;left:.5rem;top:.5rem;z-index:100;padding:.7rem 1rem;background:var(--pink);color:var(--ground);transform:translateY(-200%)}
.skip:focus{transform:none}

/* Visually hidden text: .vh */
.vh{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap}

/* Layout helpers: .wrap (page inset), .section (vertical band), .measure (reading width), .pair (note + picture, add .pair--flip to put the picture first on desktop) */
.wrap{width:100%;max-width:90rem;margin-inline:auto;padding-inline:var(--inset)}
.section{padding-block:var(--band)}
.measure{max-width:36rem}
.pair{display:grid;gap:var(--gap);align-items:center}
@media (min-width:56rem){
  .pair{grid-template-columns:minmax(0,5fr) minmax(0,7fr)}
  .pair--flip{grid-template-columns:minmax(0,7fr) minmax(0,5fr)}
  .pair--flip>:first-child{order:2}
}

/* Running copy: .note (a short working note, spaced), .lede (first sentence under a head), .said (the owner's own sentence, set larger), .prose (long text and legal pages) */
.note>*+*,.prose>*+*{margin-top:1rem}
.lede{font-size:1.3125rem;line-height:1.45}
.said{font-size:clamp(1.375rem,1.1rem + 1vw,1.75rem);line-height:1.35}
.prose{max-width:40rem}
.prose h2{margin-top:2.5rem;font-size:clamp(1.75rem,1.4rem + 1.2vw,2.375rem)}
.prose h3{margin-top:1.75rem}
.prose ul{list-style:square;padding-left:1.25em}
.prose li+li{margin-top:.4rem}

/* Scallop: the service-stub edge. Applied to .mount, .ticket, .btn, .stub, the chrome plates and #promo; add .scallop to any other solid block; set --s to .375rem on small things */
.mount,.ticket,.ticket::before,.btn::before,.stub::before,.chrome .index-btn::before,.chrome .plate::before,#promo,.scallop{
  --m:radial-gradient(circle at calc(var(--s) * -.12) 50%,#0000 calc(var(--s) * .5),#000 calc(var(--s) * .5 + .03rem)) 0 0/51% calc(var(--s) * 1.6) no-repeat round,
      radial-gradient(circle at calc(100% + var(--s) * .12) 50%,#0000 calc(var(--s) * .5),#000 calc(var(--s) * .5 + .03rem)) 100% 0/51% calc(var(--s) * 1.6) no-repeat round;
  -webkit-mask:var(--m);mask:var(--m);
}

/* Ticket: the bordered scallop-edged service stub; .ticket (add .ticket--cedar for the darker surface), .ticket__foot pins the action to the bottom */
.ticket{position:relative;isolation:isolate;display:flex;flex-direction:column;gap:1.25rem;padding:clamp(1.5rem,3.2vw,2.75rem) clamp(1.5rem,3.4vw,3rem);background:var(--ink)}
.ticket::before{content:"";position:absolute;inset:0 var(--bw);z-index:-1;
  background:linear-gradient(var(--ink),var(--ink)) top/100% var(--bw) no-repeat,linear-gradient(var(--ink),var(--ink)) bottom/100% var(--bw) no-repeat,var(--ticket-bg,var(--ground))}
.ticket--cedar{--ticket-bg:var(--cedar)}
.ticket__foot{margin-top:auto;padding-top:.5rem}

/* Ruled rows: stout rules for ticket facts and product specs; <dl class="rows"><div><dt>Label</dt><dd>Value</dd></div></dl> */
.rows{border-bottom:.15rem solid var(--ink)}
.rows>div{display:grid;grid-template-columns:minmax(5.5rem,30%) 1fr;gap:.25rem 1rem;padding:.7rem 0;border-top:.15rem solid var(--ink);font-size:1.0625rem;line-height:1.35}
.rows dt{color:var(--sage)}
.ticket--cedar .rows dt{color:var(--ink)}

/* Picture mount: scallop-edged frame that crops its painting; .mount (4:3), .mount--wide (16:9), .mount--tall (4:5); works for img or video */
.mount{position:relative;overflow:hidden;aspect-ratio:4/3;background:var(--cedar)}
.mount--wide{aspect-ratio:16/9}
.mount--tall{aspect-ratio:4/5}
.mount img,.mount video{width:100%;height:100%;object-fit:cover}

/* Figure and caption: <figure class="figure"><div class="mount">...</div><figcaption class="caption">...</figcaption></figure>; sage text only on the teal ground */
.caption{margin-top:.6rem;font-size:var(--fs-note);line-height:1.4;color:var(--sage)}

/* Page opening: ticket at the left, painting beside it, stacked on phones (ticket first); <section class="opening wrap"> with a .ticket and a .mount */
.opening{display:grid;gap:var(--gap);padding-block:1rem var(--band)}
@media (min-width:56rem){
  .opening{grid-template-columns:minmax(0,5fr) minmax(0,7fr);align-items:stretch}
  .opening .mount{aspect-ratio:auto;min-height:20rem;max-height:calc(100vh - 8rem)}
}

/* Solid controls: .btn (hot pink call action), .btn--ink (pale, for equal-weight choices), .stub (cedar toggle; aria-pressed="true" turns it pink) */
.btn,.stub{--s:.375rem;--btn-bg:var(--pink);--btn-fg:var(--ground);position:relative;isolation:isolate;display:inline-flex;align-items:center;justify-content:center;flex:none;min-height:3rem;padding:.6rem 1.6rem;border:0;background:none;color:var(--btn-fg);font:inherit;font-size:1.0625rem;line-height:1.2;text-decoration:none;cursor:pointer}
.btn::before,.stub::before{content:"";position:absolute;inset:0;z-index:-1;background:var(--btn-bg)}
.btn:hover{--btn-bg:var(--ink)}
.btn--ink{--btn-bg:var(--ink)}
.btn--ink:hover{--btn-bg:var(--sage)}
.stub{--btn-bg:var(--cedar);--btn-fg:var(--ink)}
.stub:hover{text-decoration:underline;text-decoration-color:var(--pink);text-decoration-thickness:.12em;text-underline-offset:.22em}
.stub[aria-pressed="true"],.stub[aria-selected="true"]{--btn-bg:var(--pink);--btn-fg:var(--ground)}

/* Row of stubs: one tidy line that scrolls sideways in its own box on phones; .stub-row */
.stub-row{display:flex;gap:.6rem;overflow-x:auto;padding:.4rem;margin-inline:-.4rem;scrollbar-width:thin;scrollbar-color:var(--sage) var(--ground)}

/* Chapter count and small labels at reading size: .count */
.count{font-size:var(--fs-note);color:var(--sage)}

/* Inspection mark, the recurring device: <span class="mark" aria-hidden="true"></span>, one per scene, beside the detail and never on it; .mark--lg for headline size */
.mark{display:inline-block;flex:none;width:.55rem;height:1.7rem;background:var(--pink);transform:rotate(20deg);clip-path:polygon(18% 0,82% 4%,100% 30%,92% 62%,100% 96%,30% 100%,0 70%,10% 38%)}
.mark--lg{width:.8rem;height:2.6rem}

/* Travelling mark: [data-mark-track] holds one .mark.mark--travel and several [data-mark-row]; site.js moves the mark beside the row in focus (.is-marked) and fires "markmove" */
[data-mark-track]{position:relative;padding-left:2rem}
.mark--travel{position:absolute;left:.35rem;top:var(--mark-y,0);margin-top:.35rem;transition:top var(--wipe) cubic-bezier(.7,0,.3,1)}

/* Mark explainer: <button class="text-btn" data-mark-explain aria-expanded="false" aria-controls="id"> opens <p class="mark-note" id="id" hidden> */
.mark-note{margin-top:.5rem;padding-left:1rem;border-left:.15rem solid var(--ink);max-width:34rem}

/* Curtain reveal: add .curtain to a .mount below the first screen; a hard-edged teal curtain slides off to the right once (site.js adds .is-seen) */
.curtain{position:relative;overflow:hidden}
.js .curtain::after{content:"";position:absolute;inset:0;background:var(--ground);transition:transform var(--wipe) linear}
.js .curtain.is-seen::after{transform:translateX(101%)}

/* Hand-off: the designed ending before the footer; .handoff with a heading and .handoff__links (large text links) beside a .btn */
.handoff{display:grid;gap:var(--gap);align-items:end;padding-block:var(--band)}
.handoff__links a{display:inline-block;padding-block:.35rem;font-size:var(--fs-h3);line-height:1.25}
@media (min-width:56rem){.handoff{grid-template-columns:minmax(0,7fr) minmax(0,5fr)}}

/* Chrome: no bar on a desk screen. .index-btn floats upper left, .plate (pink inspection mark + name) upper right, each a cedar plate with the same 6 px scallop cut on every page.
   The plate's surface and its cut are stated here in full and held with !important, so no page stylesheet can flatten them into a plain rectangle. */
.chrome{position:fixed;inset:0 0 auto 0;z-index:60;display:flex;justify-content:space-between;align-items:flex-start;gap:.5rem;padding:.75rem var(--inset);pointer-events:none}
.chrome>*{pointer-events:auto}
.chrome .index-btn,.chrome .plate{--s:.375rem;position:relative;isolation:isolate;background:none!important;border:0!important;border-radius:0!important;box-shadow:none!important;-webkit-mask:none!important;mask:none!important;clip-path:none!important}
.chrome .index-btn::before,.chrome .plate::before{
  --s:.375rem;
  --plate-cut:radial-gradient(circle at -.045rem 50%,#0000 .1875rem,#000 .2175rem) 0 0/51% .6rem no-repeat round,
      radial-gradient(circle at calc(100% + .045rem) 50%,#0000 .1875rem,#000 .2175rem) 100% 0/51% .6rem no-repeat round;
  content:""!important;display:block!important;position:absolute!important;inset:0!important;z-index:-1!important;width:auto!important;height:auto!important;margin:0!important;border:0!important;border-radius:0!important;transform:none!important;clip-path:none!important;opacity:1!important;
  background:var(--cedar)!important;
  -webkit-mask:var(--plate-cut)!important;mask:var(--plate-cut)!important;
}
.index-btn{min-height:2.75rem;padding-inline:1.2rem;font-size:1rem}
html:not(.js) .index-btn{display:none}
.plate{display:inline-flex;align-items:center;gap:.5rem;min-width:0;min-height:2.75rem;padding:.3rem 1rem .3rem .9rem;color:var(--ink);font-size:1rem;line-height:1.1;text-decoration:none}
.plate__mark{width:.45rem;height:1.35rem;margin-inline:.2rem}

/* Index: the full-window dark list of pages opened by .index-btn; the current page carries the pink mark */
.index{position:fixed;inset:0;z-index:-1;overflow-y:auto;padding:calc(var(--chrome) + 1.5rem) var(--inset) 3rem;background:var(--ground)}
.index ol{margin-left:clamp(0rem,8vw,9rem)}
.index ol,.foot-stack{padding-left:1.75rem}
.index a,.foot-stack a{position:relative;display:inline-flex;align-items:center;min-height:2.75rem;padding-block:.1em;font-size:var(--fs-index);line-height:1.2;text-decoration:none}
.index a:hover,.foot-stack a:hover{text-decoration:underline;text-decoration-color:var(--pink);text-decoration-thickness:.06em;text-underline-offset:.18em}
.index a[aria-current="page"]::before,.foot-stack a[aria-current="page"]::before{content:"";position:absolute;left:-1.4rem;top:50%;width:.5rem;height:.8em;margin-top:-.4em;background:var(--pink);transform:rotate(20deg);clip-path:polygon(18% 0,82% 4%,100% 30%,92% 62%,100% 96%,30% 100%,0 70%,10% 38%)}
.index-open{overflow:hidden}

/* Footer: same teal, one column starting near the right-hand third: a stack of oversized page links, then one small line and one quieter line (.foot-quiet) at the same inset beneath; .site-foot, .foot-stack, .foot-small */
.site-foot{padding:var(--band) var(--inset) 6rem}
.foot-small{margin-top:2rem;padding-left:1.75rem;font-size:var(--fs-note);line-height:1.5}
.foot-small a,.foot-small .text-btn{display:inline-block;min-height:0;padding-block:.6rem}
.foot-quiet{color:var(--sage)}
.foot-quiet>span{display:inline-block;white-space:nowrap}
@media (min-width:48rem){
  .site-foot{padding-bottom:var(--band)}
  .site-foot>nav,.site-foot>.foot-small{margin-left:56%}
}

/* Home only: body_class "sideways" turns .shell (main + footer) into the native horizontal snap track; each direct child of main is a .strip, the footer becomes the last full-width strip */
.sideways .shell{display:flex;min-height:100vh;overflow-x:auto;scroll-snap-type:x mandatory;overscroll-behavior-x:contain;scrollbar-width:thin;scrollbar-color:var(--sage) var(--ground)}
.sideways main{display:flex;flex:none}
.strip{flex:none;width:94vw;scroll-snap-align:start}
.sideways .site-foot{flex:none;width:100%;scroll-snap-align:start;display:flex;flex-direction:column;justify-content:center;padding-top:calc(var(--chrome) + 1.5rem)}
@media (min-width:48rem){.strip{width:90vw}}
@media (prefers-reduced-motion:no-preference){.sideways .shell{scroll-behavior:smooth}}

/* Consent: a slim band docked at the foot of the window, one sentence and two equal choices; #consent, .consent__choices */
.consent{position:fixed;inset:auto 0 0 0;z-index:50;display:flex;flex-wrap:wrap;align-items:center;gap:.4rem 1.25rem;padding:.5rem var(--inset);background:var(--ground);border-top:.1rem solid var(--ink);font-size:var(--fs-note);line-height:1.35}
.consent p{flex:1 1 16rem}
.consent__choices{display:flex;gap:.6rem}
.consent .btn{min-height:2.75rem;padding-block:.4rem;font-size:1rem}

/* Phone call dock: one pinned pink call control at the lower right on phones; it waits until the consent band is dismissed, and the home track keeps a clear strip for it */
.call-dock{position:fixed;right:.75rem;bottom:.75rem;z-index:40}
#consent:not([hidden]) ~ .call-dock{display:none}
@media (min-width:48rem){.call-dock{display:none}}

/* Offer tag: a pink scalloped tag that drops once from under the name plate (only when site.promo is set); #promo, #promo.is-in */
#promo{position:fixed;top:4.25rem;right:var(--inset);z-index:45;width:min(19rem,calc(100vw - 2.5rem));padding:.8rem 1.5rem .5rem;background:var(--pink);color:var(--ground);font-size:var(--fs-note);line-height:1.35;transform:translateY(-140%);opacity:0;transition:transform var(--wipe) cubic-bezier(.2,.8,.2,1),opacity .1s linear}
#promo.is-in{transform:none;opacity:1}
#promo::before{content:"";display:block;width:.7rem;height:.7rem;margin:0 auto .5rem;border-radius:50%;background:var(--ground)}
#promo a{display:inline-block;padding-block:.5rem}
#promo :focus-visible{outline-color:var(--ground)}

/* Reduced motion: no curtain, no travelling, instant navigation */
@media (prefers-reduced-motion:reduce){
  *,*::before,*::after{transition-duration:.01ms!important;animation-duration:.01ms!important;scroll-behavior:auto!important}
  .js .curtain::after{display:none}
  #promo{transition:none}
}

/* A page never scrolls sideways. */
html, body { overflow-x: clip; }
/* Past a full-HD window the whole page grows with the window - type, gaps and pictures
   together - so a very wide screen (or a page zoomed far out) shows the same composition,
   not a small column of text lost in an enormous picture. */
@media (min-width: 1921px) { html { font-size: calc(100vw / 120); } }
/* What can be pressed in the chrome lies above the page: a huge headline's line box reaching
   into the navigation must not swallow the clicks meant for the links. */
header a, header button, nav a, nav button { position: relative; z-index: 2; }
/* A visitor who asked the system for less motion gets none, whatever a page forgot. */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important;
    transition-duration: .01ms !important; scroll-behavior: auto !important; }
}

/* Phone: the chrome keeps a band of its own in the flow of the page - opaque ground behind the
   Index toggle and the plate - so a page's first line, whatever its own stylesheet does, begins
   below it and never under it. The controls stay small; the band stays slim. */
@media (max-width:47.99rem){
  .chrome{position:sticky;top:0;align-items:center;gap:.4rem;padding-block:.5rem;background:var(--ground);z-index:70}
  main#main{padding-top:0}
  .index-btn{min-height:2.75rem;padding-inline:.9rem;font-size:1rem}
  .plate{padding:.3rem .8rem .3rem .7rem;font-size:1rem;min-height:2.75rem}
  .sideways .shell{min-height:calc(100vh - 4rem)}
  /* the home track ends above the strip where the consent band, then the call dock, sits */
  .sideways .shell--dock{padding-bottom:4.5rem}
  .index{padding-top:4.5rem}
  /* consent: the sentence and both choices on one row, small padding */
  .consent{flex-wrap:nowrap;gap:.75rem;padding-block:.4rem}
  .consent p{flex:1 1 0;min-width:0}
  .consent__choices{flex:none;gap:.4rem}
  .consent .btn{padding-inline:.9rem}
}
