/* Allied Decorations Co · site.css — chrome first, then the shared pieces, then the bare elements. Desk first: narrower screens take things away in max-width queries (rem). */
:root {
  --claret: #6A1322;
  --twill: #7A1B2C;
  --crate: #4A0C17;
  --chalk: #F1E6D2;
  --brass: #C8A04A;
  --fir: #24453A;
  --stencil: "Big Shoulders Stencil Display", "Arial Narrow", sans-serif;
  --packing-slip: "Martian Mono", ui-monospace, "Courier New", monospace;
  --hairline: .0625rem;
  --frame-inset: .875rem;
  --frame-inside: calc(var(--frame-inset) + .625rem);
  --rail-width: 22vw;
  --crate-gap: 1.5rem;
  --first-screen: calc(100svh - 2 * var(--frame-inside));
  --slip: var(--crate);
  --twill-weave: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='6' height='6'%3E%3Cpath d='M-1 1l2-2M0 6l6-6M5 7l2-2' stroke='%237A1B2C' stroke-width='1'/%3E%3C/svg%3E");
}

/* ================= CHROME ================= */

/* allsk — skip link, shown on focus */
.allsk {
  position: fixed; top: 2.5rem; left: 2.5rem; z-index: 60;
  padding: .75rem 1rem; background: var(--crate); color: var(--chalk);
  transform: translateY(-300%);
}
.allsk:focus { transform: none; }

/* allfr — the fixed brass double rule round the window (3 outer, 6 apart, 1 inner) */
.allfr {
  position: fixed; inset: var(--frame-inset); z-index: 40; pointer-events: none;
  border: .1875rem solid var(--brass);
}
.allfr::after {
  content: ""; position: absolute; inset: .375rem;
  border: var(--hairline) solid var(--brass);
}

/* allfm — the panel-coloured strip under the bottom frame rule: the page passes behind it and is masked, never struck through */
.allfm {
  position: fixed; z-index: 39; pointer-events: none;
  left: 0; right: 0; bottom: 0; height: var(--frame-inside);
  background: var(--crate);
}

/* allcn — a corner caption on its own plate, breaking the frame line; allnw allne allsw allse place it */
.allcn {
  position: fixed; z-index: 45; margin: 0;
  padding: .4rem .65rem; background: var(--crate); color: var(--chalk);
  font: 400 .9rem/1 var(--packing-slip); white-space: nowrap;
}
.allnw { top: calc(var(--frame-inset) - .75rem); left: calc(var(--frame-inset) + 1.75rem); }
.allne { top: calc(var(--frame-inset) - .75rem); right: calc(var(--frame-inset) + 1.75rem); }
.allsw { bottom: calc(var(--frame-inset) - .75rem); left: calc(var(--frame-inset) + 1.75rem); }
.allse { bottom: calc(var(--frame-inset) - .75rem); right: calc(var(--frame-inset) + 1.75rem); }

/* allhd — the question rail: a tall panel inside the left edge of the first screen, ending at the inner frame line */
.allhd {
  position: absolute; z-index: 20; box-sizing: border-box;
  top: var(--frame-inside); left: var(--frame-inside);
  width: var(--rail-width); height: var(--first-screen);
  padding: 2.75rem 1.5rem 1.5rem; overflow-y: auto;
  display: flex; flex-direction: column; gap: 1.75rem;
}

/* allmk — the logo mark and name at the top of the rail */
.allmk {
  display: inline-flex; align-items: center; gap: .75rem;
  color: var(--chalk); text-decoration: none; font: 400 .9rem/1.3 var(--packing-slip);
}
.allmk svg { width: 2.5rem; height: 2.5rem; flex: none; }

/* allqs — the numbered questions in stencil, one per line */
.allqs { list-style: none; margin: 0; padding: 0; display: grid; gap: .55rem; }
.allqs a {
  display: block; color: var(--chalk); text-decoration: none;
  font: 700 clamp(1.6rem, 2.45vw, 2.4rem)/1.04 var(--stencil);
}
.allqs a:hover, .allqs a:focus-visible { text-decoration: underline double var(--brass); text-underline-offset: .15em; }
.allqs a[aria-current="page"] { color: var(--brass); }

/* allqo — pages without a job number: small packing-slip type under a double rule, below the last question */
.allqo {
  list-style: none; margin: 1.1rem 0 0; padding: .6rem 0 0;
  border-top: .25rem double var(--brass);
  display: flex; flex-wrap: wrap; gap: 0 1.25rem;
}
.allqo a {
  display: inline-flex; align-items: center; min-height: 2.75rem;
  color: var(--chalk); text-decoration: none; font: 400 .9rem/1.3 var(--packing-slip);
}
.allqo a:hover, .allqo a:focus-visible { text-decoration: underline double var(--brass); text-underline-offset: .2em; }
.allqo a[aria-current="page"] { color: var(--brass); }

/* allcm — the compact question line, pinned under the name once the first screen is passed; html.folded shows it */
.allcm {
  display: none; position: fixed; z-index: 44;
  top: calc(var(--frame-inset) + 1.35rem); left: calc(var(--frame-inside) + .5rem);
  max-width: min(62vw, 54rem); padding: .55rem .9rem;
  font: 400 .9rem/1.6 var(--packing-slip);
}
.folded .allcm { display: block; }
.allcm ul { list-style: none; margin: 0; padding: 0; }
.allcm li { display: inline; }
.allcm li + li::before { content: " / "; color: var(--brass); }
.allcm a { color: var(--chalk); text-decoration: none; }
.allcm a:hover, .allcm a:focus-visible { text-decoration: underline double var(--brass); }
.allcm a[aria-current="page"] { color: var(--brass); }
/* allqb — the "Questions" button that opens the compact list on a phone */
.allqb { display: none; }

/* allft — the last screen: empty weave with one business card in the middle */
.allft {
  display: grid; place-items: center; min-height: 72svh;
  margin-top: var(--crate-gap); padding-block: clamp(2.5rem, 9vh, 6.5rem);
}
/* allcd — the business card (1.75:1, grows if it must); allcdn name, allcdt trade line, allcdr phone/email, allcda address, allcdl number links, allcdc copyright */
.allcd {
  width: min(38rem, 100%); aspect-ratio: 1.75;
  padding: 1.75rem 2rem 1rem; display: flex; flex-direction: column; gap: .5rem;
  font-size: .9rem; line-height: 1.5;
}
.allcd p, .allcd address { margin: 0; font-style: normal; }
.allcdn { font: 800 2.25rem/1 var(--stencil); }
.allcdr { display: flex; flex-wrap: wrap; gap: .25rem 1.25rem; font-size: 1rem; }
.allcdl { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 0 1rem; }
.allcdl a, .allcdb { display: inline-flex; align-items: center; min-height: 2.75rem; }
.allcdp { border-top: .25rem double var(--brass); }
.allcdb {
  padding: 0; border: 0; background: none; color: var(--chalk); cursor: pointer;
  font: inherit; text-decoration: underline; text-decoration-color: rgba(241, 230, 210, .45);
}
.allcdb:hover { text-decoration-style: double; text-decoration-color: var(--brass); }
.allcdc { margin-top: auto !important; padding-top: .5rem; }

/* allcs — the consent plate: fir green, lower left just above "THIS WAY UP"; allcx — the words a phone strip leaves out */
.allcs {
  --slip: var(--fir);
  position: fixed; z-index: 46;
  left: calc(var(--frame-inside) + .75rem); bottom: calc(var(--frame-inset) + 1.75rem);
  width: 20rem; padding: 1.1rem; display: grid; gap: .55rem;
  background: var(--fir); color: var(--chalk); font: 400 .9rem/1.5 var(--packing-slip);
  border: var(--hairline) solid var(--brass);
  box-shadow: inset 0 0 0 .25rem var(--fir), inset 0 0 0 .3125rem var(--brass);
}
.allcs[hidden] { display: none; }
.allcs p { margin: 0 0 .25rem; }
/* the link in the sentence lies above the words beside it, so the whole of it can be pressed */
.allcs a { position: relative; z-index: 2; }
.allcs .allbt { width: 100%; font-size: 1.2rem; min-height: 2.75rem; padding-block: .6rem; }
.allcx { display: inline-block; white-space: nowrap; }

/* allsm — the offer stamp: a round brass stamp at -8°, pressed on the first screen's photograph at its upper right, over the frame line.
   It belongs to the page (it scrolls away with the photograph); the script sets it on the picture's own corner. allst is the drawing. */
.allsm {
  position: absolute; z-index: 41;
  top: calc(var(--frame-inset) + 2.1rem); right: .25rem;
  display: block; width: 8.25rem; height: 8.25rem; border-radius: 50%;
  background: var(--crate); transform: rotate(-8deg);
  transition: transform .12s steps(2, end);
}
.allsm:hover, .allsm:focus-visible { transform: none; }
.allsm.stowed { display: none; }
.allst { display: block; width: 100%; height: 100%; border-radius: 50%; }
.allsr { font: 400 9.5px var(--packing-slip); fill: var(--brass); }
.allsc { font: 800 17px var(--stencil); fill: var(--chalk); }

/* allpr — the offer's sentence on a tag, pinned under the stamp at the upper right; allpx ×, allpt tag.
   It is pinned to the window, so the whole of it stands on its own opaque crate plate and the page passes beneath. */
.allpr {
  position: fixed; z-index: 43; box-sizing: border-box;
  top: calc(var(--frame-inset) + 10.85rem); right: .25rem;
  width: 17.5rem; padding: .5rem;
  display: flex; flex-direction: row-reverse; align-items: flex-start; gap: .4rem;
  background: var(--crate); border: var(--hairline) solid var(--brass);
  opacity: 0; transform: translateX(calc(100% + 1rem));
  transition: opacity .12s steps(2, end), transform .12s steps(2, end);
}
.allpr.is-in { opacity: 1; transform: none; }
.allpr[hidden] { display: none; }
.allpx {
  flex: none; width: 2.75rem; height: 2.75rem; border: var(--hairline) solid var(--brass);
  background: var(--crate); color: var(--chalk); font: 400 1.1rem/1 var(--packing-slip); cursor: pointer;
}
.allpt {
  margin: 0; flex: 1; min-width: 0; padding: .8rem .9rem;
  background: var(--crate); color: var(--chalk); font: 400 .9rem/1.5 var(--packing-slip);
  border: var(--hairline) solid var(--brass);
  box-shadow: inset 0 0 0 .25rem var(--crate), inset 0 0 0 .3125rem var(--brass);
}
.allpt a { display: inline-block; margin-top: .3rem; color: var(--brass); }

/* ================= SHARED PIECES ================= */

/* allop — the opening of every page: the first child of <main>, set right of the rail and a first screen tall */
.allop {
  margin-left: calc(var(--rail-width) + var(--crate-gap));
  min-height: var(--first-screen);
  display: flex; flex-direction: column; gap: var(--crate-gap);
}
/* stacking: every block in <main> is a slip, 1.5rem of weave between slips */
#main > * + * { margin-top: var(--crate-gap); }

/* allg — the 8-column grid inside the frame; children set their own grid-column */
.allg { display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); gap: var(--crate-gap); }

/* allp — a solid claret panel with the brass double rule (1 px outer, 1 px inner 4 px inside) */
.allp {
  --slip: var(--crate);
  background: var(--crate); color: var(--chalk);
  border: var(--hairline) solid var(--brass);
  box-shadow: inset 0 0 0 .25rem var(--crate), inset 0 0 0 .3125rem var(--brass);
}
/* allpd — standard panel padding, for panels that hold reading */
.allpd { padding: clamp(1.5rem, 3vw, 2.5rem); }

/* allhl — a page head sentence, first words in <b> at 800, the rest 300; allhs — the same at panel-head size */
.allhl, .allhs { margin: 0; font-family: var(--stencil); font-weight: 300; line-height: 1.06; color: var(--chalk); text-wrap: balance; }
.allhl { font-size: clamp(1.875rem, 3.2vw, 2.75rem); }
.allhs { font-size: clamp(1.375rem, 1.9vw, 1.625rem); }
.allhl b, .allhs b { font-weight: 800; }

/* alltx — running text set as a packing slip */
.alltx { max-width: 64ch; font-size: 1.0625rem; line-height: 1.68; }
.alltx p { margin: 0 0 1em; }
.alltx p:last-child { margin-bottom: 0; }

/* allrl — the divider: always two brass hairlines 3 px apart */
.allrl {
  height: .3125rem; margin: 1.25rem 0; border: 0;
  border-top: var(--hairline) solid var(--brass); border-bottom: var(--hairline) solid var(--brass);
}

/* allbt — the double-ruled stencil button (a or button); outer and inner lines swap on hover. allbn = the brass number inside it */
.allbt {
  display: inline-flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: .2rem .9rem;
  min-height: 3rem; padding: .85rem 1.5rem; border: 0; cursor: pointer;
  background: var(--slip); color: var(--chalk); font: 700 1.375rem/1.1 var(--stencil); text-decoration: none;
  box-shadow: inset 0 0 0 .1875rem var(--brass), inset 0 0 0 .4375rem var(--slip), inset 0 0 0 .5rem var(--brass);
  transition: box-shadow .12s linear;
}
.allbt:hover, .allbt:focus-visible {
  box-shadow: inset 0 0 0 .0625rem var(--brass), inset 0 0 0 .3125rem var(--slip), inset 0 0 0 .5rem var(--brass);
}
.allbn { font: 400 .95rem/1.2 var(--packing-slip); color: var(--brass); }

/* allte — the phone number: brass, its rule thickens on hover */
.allte {
  color: var(--brass); text-decoration: underline var(--brass);
  text-decoration-thickness: var(--hairline); text-underline-offset: .25em;
  transition: text-decoration-thickness .12s linear;
}
.allte:hover, .allte:focus-visible { text-decoration-thickness: .1875rem; text-decoration-style: solid; }

/* allph — a photograph in a 6 px chalk mat with a brass double rule outside; img fills it; allpc — the caption written on the mat */
.allph {
  margin: 0; padding: .375rem; background: var(--chalk);
  box-shadow: 0 0 0 .0625rem var(--brass), 0 0 0 .3125rem var(--crate), 0 0 0 .375rem var(--brass);
  display: flex; flex-direction: column;
}
.allph img { display: block; width: 100%; height: 100%; min-height: 0; flex: 1; object-fit: cover; }
.allpc { padding: .5rem .25rem .15rem; color: var(--crate); font: 400 .9rem/1.45 var(--packing-slip); }

/* alllb — the crate label (the recurring device): <div class="alllb allp allpd"> with .allno, a heading and .allds */
.alllb { display: grid; grid-template-columns: auto 1fr; gap: 1rem 1.75rem; align-items: start; }
/* allno — the job number on a label: "No. 03" */
.allno { margin: 0; font: 800 clamp(2.5rem, 5vw, 4.25rem)/.9 var(--stencil); color: var(--brass); }
/* allds — the up-by / down-by lines: <dl class="allds"><div><dt>Up by</dt><dd>…</dd></div><div class="alldw">…</div></dl> */
.allds { grid-column: 1 / -1; display: grid; grid-template-columns: 1fr 1fr; gap: var(--crate-gap); margin: 0; }
.allds > div {
  padding: .8rem 1rem;
  box-shadow: inset 0 0 0 .0625rem var(--brass), inset 0 0 0 .3125rem var(--slip), inset 0 0 0 .375rem var(--brass);
}
.allds dt { font: 400 .9rem/1.3 var(--packing-slip); }
.allds dd {
  margin: .35rem 0 0; min-height: 2rem;
  font: 700 1.5rem/1.2 var(--stencil); border-bottom: .125rem dotted rgba(241, 230, 210, .6);
}
/* alldw — the down-by line: the single fir-green thing on its screen */
.alldw { --slip: var(--fir); background: var(--fir); }

/* allsp — numbered steps, each ending in its result: <ol class="allsp"><li><b>Call us.</b><span class="allrs">A walk-round is booked.</span></li></ol> */
.allsp { list-style: none; margin: 0; padding: 0; counter-reset: allsp; }
.allsp li {
  counter-increment: allsp; display: grid; grid-template-columns: 3.75rem 1fr; gap: .3rem 1rem;
  padding: 1.1rem 0; border-top: .25rem double var(--brass); font-size: 1.0625rem; line-height: 1.6;
}
.allsp li::before { content: counter(allsp, decimal-leading-zero); grid-row: span 2; font: 800 2rem/1 var(--stencil); color: var(--brass); }
.allsp li > * { grid-column: 2; }
.allrs { display: block; }
.allrs::before { content: "→ "; color: var(--brass); }

/* allrv — reveal-on-scroll, in this site's still manner: nothing moves or hides; a read slip gains .arrived and a brass check bar on its left */
.allrv { border-left: .1875rem solid transparent; padding-left: .75rem; }
.allrv.arrived { border-left-color: var(--brass); }

/* allol — the live open/closed line the script writes beside printed hours */
.allol { display: block; margin-top: .4rem; color: var(--brass); font: 400 .95rem/1.4 var(--packing-slip); }

/* allvh — visually hidden, still read aloud */
.allvh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ================= NARROWER: tablets and phones take the rail away ================= */
@media (max-width: 56rem) {
  :root { --frame-inset: .5rem; --rail-width: 0; }
  body { padding-top: 2.75rem; padding-bottom: 3.75rem; }
  /* the name sits just below in the panel, so the left caption goes and the job number stands alone */
  .allnw { display: none; }
  .allne { top: .2rem; }
  .allsw, .allse { bottom: .2rem; min-height: 2.75rem; display: inline-flex; align-items: center; }
  .allss { display: none; }
  .allhd { position: static; width: auto; height: auto; padding: 1.25rem; gap: 1.1rem; }
  .allqs a { font-size: 1.625rem; }
  .allqo { margin-top: .9rem; padding-top: .35rem; }
  .allop { margin-left: 0; min-height: 0; }
  .allg { grid-template-columns: minmax(0, 1fr); }
  .allg > * { grid-column: 1 / -1; }
  .allcm { top: 2.35rem; left: var(--frame-inside); right: var(--frame-inside); max-width: none; padding: .35rem .6rem; }
  .allqb {
    display: block; min-height: 2.75rem; padding: 0 .4rem; border: 0; background: none; cursor: pointer;
    color: var(--chalk); font: 400 .95rem/1 var(--packing-slip); text-decoration: underline double var(--brass);
  }
  .allcm ul { display: none; max-height: 60svh; overflow-y: auto; padding: .5rem .4rem; }
  .allcm.opened ul { display: grid; gap: .4rem; }
  .allcm li + li::before { content: none; }
  .allcm.opened a { font: 700 1.625rem/1.1 var(--stencil); }
  /* the unnumbered pages stay small and apart at the foot of the opened list */
  .allcm.opened .allqx { margin-top: .3rem; border-top: .25rem double var(--brass); }
  .allcm.opened .allqx + .allqx { margin-top: 0; border-top: 0; }
  .allcm.opened .allqx a {
    display: inline-flex; align-items: center; min-height: 2.75rem;
    font: 400 .95rem/1.2 var(--packing-slip);
  }
  /* the consent plate becomes one strip: the sentence, then the two choices beside it */
  .allcs {
    left: var(--frame-inside); right: var(--frame-inside); bottom: 3.25rem; width: auto;
    grid-template-columns: minmax(0, 1fr) auto auto; align-items: center;
    padding: .5rem .6rem; gap: .4rem; line-height: 1.35;
  }
  .allcs p { margin: 0; }
  .allcx { display: none; }
  .allcs .allbt { width: auto; font-size: 1.05rem; min-height: 2.75rem; padding: .6rem .85rem; }
  /* the offer is the 96 px stamp alone: no text bar. The script sets it on the photograph's upper right corner; where that corner
     would leave it half under the bottom plates and the cookie strip, it goes down the picture's right edge, out of the first window.
     Until then, or with no picture tall enough, it rests in the clear lower right of the question panel. */
  .allpr { display: none; }
  .allsm { top: 15.125rem; right: calc(var(--frame-inside) + .5rem); width: 6rem; height: 6rem; }
  .allsm.stowed { display: block; }
  .allft { min-height: 0; }
  .allcd { aspect-ratio: auto; padding: 1.25rem 1.1rem .75rem; }
  .allcdn { font-size: 1.875rem; }
  .alllb, .allds { grid-template-columns: 1fr; }
  .allsp li { grid-template-columns: 2.75rem 1fr; }
  .alltx, .allsp li { font-size: 1rem; }
}

/* ================= BARE ELEMENTS ================= */
html {
  background: var(--claret) var(--twill-weave); color: var(--chalk);
  font-family: var(--packing-slip); font-size: 100%;
  -webkit-text-size-adjust: 100%; scroll-padding-top: 5rem;
}
body { position: relative; margin: 0; padding: var(--frame-inside); min-height: 100svh; line-height: 1.6; }
img, svg, video { max-width: 100%; }
img { height: auto; }
h1, h2, h3 { margin: 0; font-family: var(--stencil); font-weight: 300; }
p { margin: 0 0 1em; }
a {
  color: inherit; text-decoration: underline; text-decoration-color: rgba(241, 230, 210, .45);
  text-underline-offset: .2em; transition: text-decoration-color .12s linear;
}
a:hover { text-decoration-style: double; text-decoration-color: var(--brass); }
button { font: inherit; }
:focus-visible { outline: .1875rem solid var(--brass); outline-offset: .1875rem; }
::selection { background: var(--brass); color: var(--crate); }
@media (prefers-reduced-motion: reduce) {
  .allpr, .allsm, .allbt, .allte, a { transition: none; }
}

@media (min-width: 1921px) { html { font-size: calc(100vw / 120); } }
nav a, nav button, header a, header button {
  position: relative;
  z-index: 2;
}
html, body { overflow-x: clip; }
@media (prefers-reduced-motion: reduce) {
  *,
  *::after,
  *::before {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}
