/* Resolon home, band 2: the moving workflow piece (flow lane; round 2 of the drawing, notes _sw3/flow/NOTES-R2.md).
   Scoped to .hf* inside .hs. ONE piece of work followed through six states, drawn as flat real artefacts in html:
   a request document, three source records, the draft on the document, the approval slip, the log, the filed item.
   Night ground; panels one step lighter with hairline edges; Steel and Glass for what is written; the ONE accent (teal)
   only on the live item and on the approval mark. No icon, no glow, no shadow, no gradient, nothing sliding along a line.
   The page carries the FINISHED state (what you see with no script or with reduced motion); home-flow.js adds .is-live,
   takes the parts out and brings each one in at its step ([data-s]) as the page is scrolled.
   Every measure is in --u: one unit of the collage's 730 x 700 box (it scales with the box), 1.08 px in the phone stack. */

.hf { position: relative; color: var(--c-steel); font-family: var(--font); font-stretch: 100%; font-weight: 420; text-align: left;
  --hf-panel: color-mix(in srgb, var(--c-dusk) 36%, var(--c-night)); --hf-panel-2: color-mix(in srgb, var(--c-dusk) 62%, var(--c-night));
  --hf-edge: rgb(230 237 240 / .22); --hf-hair: rgb(230 237 240 / .13); --hf-bar: rgb(147 163 171 / .27); }
.hf-in { --u: 1px; }
.hf i, .hf b { font: inherit; display: block; }

/* type: Archivo, tabular figures for times; nothing under 11 px */
.hf-c { font-size: max(11px, calc(11.5 * var(--u))); line-height: 1.4; letter-spacing: .012em; color: var(--c-steel); white-space: nowrap; }
.hf-strong { font-size: max(12px, calc(15 * var(--u))); line-height: 1.3; font-weight: 560; font-stretch: 106%; letter-spacing: -.006em; color: var(--c-glass); }
.hf-num, .hf-lr { font-variant-numeric: tabular-nums; }
.hf-bar { height: calc(5 * var(--u)); min-height: 3px; background: var(--hf-bar); border-radius: 1px; }
.hf-bars { display: grid; gap: calc(7 * var(--u)); align-content: start; }

/* the artefacts: paper-like panels a step lighter than the ground, hairline edges */
.hf-a { box-sizing: border-box; }
.hf-doc, .hf-src, .hf-ok, .hf-log, .hf-out, .hf-next { background: var(--hf-panel); border: 1px solid var(--hf-edge); border-radius: 2px; }
.hf-hd { display: flex; justify-content: space-between; align-items: baseline; gap: calc(12 * var(--u)); }
.hf .hf-live { display: inline-block; width: calc(7 * var(--u)); height: calc(7 * var(--u)); margin-right: calc(8 * var(--u)); background: var(--c-steel); transition: background .6s var(--ease); }

/* 1 + 2 + 3 the piece of work: the request (head), the attached sources (strip), the draft (body) */
.hf-sec { padding: calc(14 * var(--u)) calc(16 * var(--u)); }
.hf-sec + .hf-sec { border-top: 1px solid var(--hf-hair); }
.hf-kv { display: grid; grid-template-columns: calc(58 * var(--u)) 1fr; align-items: baseline; margin-top: calc(9 * var(--u)); }
.hf-kv .hf-bars { align-self: center; }
.hf-body { margin-top: calc(13 * var(--u)); }
.hf-att { display: flex; align-items: center; gap: calc(10 * var(--u)); padding-block: calc(10 * var(--u)); }
.hf-clips { display: flex; gap: calc(3 * var(--u)); }
.hf-clips i { width: calc(9 * var(--u)); height: calc(12 * var(--u)); border: 1px solid var(--c-steel); border-radius: 1px; box-sizing: border-box; }
.hf-rec { margin: calc(5 * var(--u)) 0 calc(12 * var(--u)); }
.hf-f { display: flex; justify-content: space-between; align-items: baseline; gap: calc(10 * var(--u)); padding: calc(6.5 * var(--u)) 0;
  border-top: 1px solid var(--hf-hair); font-size: max(11.5px, calc(13 * var(--u))); line-height: 1.35; color: var(--c-glass); white-space: nowrap; }
.hf-f > span:first-child { color: var(--c-steel); }
/* the one line marked for attention: a Glass rule down its left edge, its value boxed. No warm colour. */
.hf-flag { margin-inline: calc(-16 * var(--u)); padding-inline: calc(13 * var(--u)) calc(16 * var(--u)); border-left: calc(3 * var(--u)) solid var(--c-glass); background: rgb(230 237 240 / .055); }
.hf-flag > span:first-child { color: var(--c-glass); }
.hf-flag > span:last-child { padding: 0 calc(6 * var(--u)); border: 1px solid rgb(230 237 240 / .6); border-radius: 1px; }

/* 2 the three sources: a table, a form, a page of terms. Three shapes, placed by percent of their own box. */
.hf-srcs { position: relative; aspect-ratio: 316 / 226; }
.hf-src { position: absolute; box-sizing: border-box; overflow: hidden; padding: calc(9 * var(--u)) calc(10 * var(--u)); }
.hf-src > .hf-c { display: block; margin-bottom: calc(7 * var(--u)); }
.hf-src--t { left: 0; top: 0; width: 66.5%; height: 54.9%; }
.hf-src--f { left: 11.4%; top: 46.9%; width: 51.9%; height: 53.1%; }
.hf-src--p { left: 57%; top: 13.3%; width: 43%; height: 77.9%; }
.hf-tb > div { display: grid; grid-template-columns: 1.5fr 1fr 1fr .8fr; gap: calc(9 * var(--u)); align-items: center; height: calc(14.5 * var(--u)); border-top: 1px solid var(--hf-hair); }
.hf-tb > div:first-child { border-top-color: var(--hf-edge); }
.hf-tb > div:first-child .hf-bar { background: rgb(147 163 171 / .5); }
.hf-fm { display: grid; grid-template-columns: 1fr 1fr; gap: calc(8 * var(--u)) calc(10 * var(--u)); }
.hf-fm b { height: calc(15 * var(--u)); margin-top: calc(4 * var(--u)); border: 1px solid var(--hf-edge); border-radius: 1px; box-sizing: border-box; }
.hf-ck { display: grid; grid-template-columns: auto 1fr; gap: calc(7 * var(--u)); align-items: center; margin-top: calc(9 * var(--u)); }
.hf-ck b { width: calc(9 * var(--u)); height: calc(9 * var(--u)); border: 1px solid var(--c-steel); box-sizing: border-box; }
.hf-pg { display: grid; gap: calc(12 * var(--u)); margin-top: calc(3 * var(--u)); }
.hf-pg > div { display: grid; grid-template-columns: auto 1fr; gap: calc(7 * var(--u)); align-items: start; }
.hf-pg b { width: calc(5 * var(--u)); height: calc(5 * var(--u)); background: rgb(147 163 171 / .6); }

/* 4 the approval: a role, a signature line, a switch. The largest moment of the piece. */
.hf-ok { background: var(--hf-panel-2); border-color: rgb(230 237 240 / .3); padding: calc(15 * var(--u)) calc(20 * var(--u)) calc(16 * var(--u)); }
.hf-st { display: grid; justify-items: end; }
.hf-st > * { grid-area: 1 / 1; transition: opacity .3s var(--ease), transform .35s var(--quart); }
.hf-st-ok { color: var(--c-teal); font-size: max(11.5px, calc(13 * var(--u))); font-weight: 560; }
.hf-st-w { opacity: 0; }
.hf-ok-row { display: grid; grid-template-columns: 1fr 1.45fr auto; gap: calc(24 * var(--u)); align-items: end; margin-top: calc(20 * var(--u)); }
.hf-fld { display: grid; }
.hf-fld > .hf-c { padding-top: calc(6 * var(--u)); border-top: 1px solid rgb(230 237 240 / .42); }
.hf-role { font-size: max(13px, calc(19 * var(--u))); line-height: 1.2; font-weight: 580; font-stretch: 110%; letter-spacing: -.012em; color: var(--c-glass);
  height: calc(52 * var(--u)); display: flex; align-items: flex-end; padding-bottom: calc(8 * var(--u)); box-sizing: border-box; }
.hf-sig svg { display: block; width: 100%; height: calc(52 * var(--u)); overflow: visible; }
.hf-ink { fill: none; stroke: var(--c-teal); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; vector-effect: non-scaling-stroke;
  stroke-dasharray: 1; stroke-dashoffset: 0; }
.hf-sw { position: relative; box-sizing: border-box; width: calc(60 * var(--u)); height: calc(32 * var(--u)); margin-bottom: calc(24 * var(--u));
  border: 1px solid var(--c-teal); border-radius: calc(16 * var(--u)); background: rgb(118 190 205 / .16); transition: border-color .3s var(--ease), background .3s var(--ease); }
.hf-sw i { position: absolute; left: calc(4 * var(--u)); top: 50%; width: calc(22 * var(--u)); height: calc(22 * var(--u)); margin-top: calc(-11 * var(--u)); border-radius: 50%;
  background: var(--c-teal); transform: translate3d(calc(28 * var(--u)), 0, 0); transition: transform .4s var(--quart), background .3s var(--ease); }

/* 5 the log: times and steps; the approval is one of its rows */
.hf-log { padding: calc(10 * var(--u)) calc(13 * var(--u)) calc(8 * var(--u)); }
.hf-log > .hf-c { display: block; margin-bottom: calc(5 * var(--u)); }
.hf-lr { display: grid; grid-template-columns: auto 1fr auto; gap: calc(11 * var(--u)); align-items: center; height: calc(19 * var(--u)); min-height: 15px;
  border-top: 1px solid var(--hf-hair); font-size: max(11px, calc(12 * var(--u))); line-height: 1; color: rgb(230 237 240 / .82); white-space: nowrap; overflow: hidden; }
.hf-lr > .hf-num { color: var(--c-steel); }
.hf-lr--ok { color: var(--c-glass); }
.hf-tick { width: calc(12 * var(--u)); height: calc(10 * var(--u)); overflow: visible; }
.hf-tick path { fill: none; stroke: var(--c-teal); stroke-width: 1.8; vector-effect: non-scaling-stroke; }

/* 6 the item, closed and filed (compact); and the next request, the live one now */
.hf-out { display: grid; grid-template-columns: 1fr auto; gap: calc(3 * var(--u)) calc(12 * var(--u)); align-items: baseline; padding: calc(10 * var(--u)) calc(14 * var(--u)); }
.hf-out > .hf-strong { grid-column: 1 / -1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hf-out-k { color: var(--c-glass); }
.hf-next { border-color: var(--c-teal); padding: calc(5 * var(--u)) calc(11 * var(--u)) calc(10 * var(--u)); }
.hf-next .hf-live { background: var(--c-teal); }
.hf-next .hf-bars { margin-top: calc(9 * var(--u)); width: 60%; }

/* the six names: the page's own type, a small figure before each; the station the work is at reads in Glass */
.hf-n { font-size: 1.0625rem; line-height: 1.25; font-stretch: 104%; font-weight: 440; letter-spacing: -0.005em; color: var(--c-steel); white-space: nowrap; transition: color .5s var(--ease); }
.hf-n b { display: inline-block; min-width: 1.15em; font-size: .76em; font-weight: 520; font-variant-numeric: tabular-nums; color: var(--c-steel); }
.hf-n.is-at { color: var(--c-glass); }
.hf-rules { display: none; }
.hf-rules path { fill: none; stroke: rgb(147 163 171 / .55); stroke-width: 1; vector-effect: non-scaling-stroke; }

/* ---- the running figure (home-flow.js): parts are out until their step, then come in, settle and wait ---- */
.hf.is-live [data-s] { opacity: 0; transition: opacity .22s linear, transform .22s var(--ease); }
.hf.is-live [data-s].is-in { opacity: 1; transform: none; transition: opacity .42s var(--ease), transform .72s var(--quart); }
.hf.is-live .hf-a[data-s]:not(.is-in) { transform: translate3d(0, calc(18 * var(--u)), 0); }
.hf.is-live .hf-src:not(.is-in) { transform: translate3d(calc(30 * var(--u)), calc(-12 * var(--u)), 0) scale(.955); }
.hf.is-live .hf-f:not(.is-in), .hf.is-live .hf-lr:not(.is-in) { transform: translate3d(0, calc(7 * var(--u)), 0); }
.hf.is-live .hf-next:not(.is-in) { transform: translate3d(calc(-14 * var(--u)), calc(-14 * var(--u)), 0); }
/* the live item wears the accent until it is filed */
.hf-doc, .hf-sec { transition: border-color .6s var(--ease); }
.hf.is-live:not(.is-rest) .hf-doc { border-color: var(--c-teal); }
.hf.is-live:not(.is-rest) .hf-doc .hf-live { background: var(--c-teal); }
/* the wait: the slip is in, nothing is signed, the switch is off. Then (.is-ok) the stroke, the switch, the time, in that order. */
.hf.is-live:not(.is-ok) .hf-ink { stroke-dashoffset: 1; transition: stroke-dashoffset .2s linear; }
.hf.is-live.is-ok .hf-ink { transition: stroke-dashoffset .62s var(--ease-io); }
.hf.is-live:not(.is-ok) .hf-sw { border-color: var(--c-steel); background: transparent; }
.hf.is-live:not(.is-ok) .hf-sw i { background: var(--c-steel); transform: none; }
.hf.is-live.is-ok .hf-sw, .hf.is-live.is-ok .hf-sw i { transition-delay: .56s; }
.hf.is-live:not(.is-ok) .hf-st-w { opacity: 1; }
.hf.is-live:not(.is-ok) .hf-st-ok { opacity: 0; transform: scale(1.05); }
.hf.is-live.is-ok .hf-st-w { transition-delay: .78s; }
.hf.is-live.is-ok .hf-st-ok { transition-delay: .86s; }

/* ---- the band and its words (moved here from home.css 2026-11-12, so the piece can stand on a sub page) ---- */
.hs { background: var(--c-night); color: var(--c-glass); overflow: clip; isolation: isolate; }
.hs-txt { position: relative; z-index: 1; padding-block: 22svh 22svh; }
.hs-txt .statement { font-size: clamp(2.3rem, 1.2rem + 3.8vw, 5.4rem); max-width: 18ch; }
.hs-paras { margin: 26svh 0 0; width: min(100%, 34rem); }
.hs-paras p { font-size: clamp(1.3rem, 1rem + 1vw, 1.95rem); line-height: 1.32; font-stretch: 104%; font-weight: 420; letter-spacing: -0.01em; color: var(--c-glass); }
.hs-paras p + p { margin-top: 16svh; }
@media (min-width: 64rem) {
  /* the words keep to the left 40 %; the drawing is held in the right 55 %. One paragraph is read at a
     time, so the drawing can keep step with it: stations 1-3, the approval, the record. */
  .hs-txt { padding-block: 30svh 58svh; }
  .hs-txt .statement { font-size: clamp(2.3rem, .9rem + 2.9vw, 4.4rem); max-width: 40%; }
  .hs-paras { margin-top: 34svh; width: 40%; max-width: 34rem; }
  .hs-paras p + p { margin-top: 38svh; }
}
/* the line under the figure (flow_band on a sub page): what the reader is watching. Desktop: held under the figure. */
.hf-note { margin-top: 1.75rem; max-width: 40rem; font-size: var(--t-small); line-height: 1.5; color: var(--c-steel); }
@media (min-width: 64rem) {
  .hs--note .hf-wrap { align-content: center; row-gap: 1.25rem; }
  .hs--note .hf, .hs--note .hf-note { width: min(55%, (100svh - var(--hd) - 8rem) * 1.0429); }
  .hs--note .hf-note { margin: 0; max-width: none; }
}

/* ---- phones: the words, then the figure below them as a stack, in the flow of the page (nothing pinned) ---- */
@media (max-width: 47.99rem) {
  .hs { display: flex; flex-direction: column; }
  .hs-txt { padding-bottom: 0; }
  .hf-stage { order: 2; padding-block: clamp(3.5rem, 11svh, 6rem) 22svh; }
  .hf-in { --u: 1.08px; display: flex; flex-direction: column; }
  .hf-names, .hf-doc { display: contents; }
  .hf-sec { background: var(--hf-panel); border: 1px solid var(--hf-edge); border-radius: 2px; }
  .hf-sec + .hf-sec { border-top: 1px solid var(--hf-edge); }
  .hf.is-live:not(.is-rest) .hf-sec.is-in { border-color: var(--c-teal); }
  .hf.is-live .hf-sec:not(.is-in) { transform: translate3d(0, 18px, 0); }
  .hf-n { margin: 2.8rem 0 .75rem; position: relative; align-self: flex-start; }
  .hf-n::before { content: ''; position: absolute; left: .3rem; bottom: calc(100% + .55rem); width: 1px; height: 1.6rem; background: rgb(147 163 171 / .55); }
  .hf-n[data-st="1"] { order: 10; margin-top: 0; } .hf-n[data-st="1"]::before { content: none; }
  .hf-req { order: 11; }
  .hf-n[data-st="2"] { order: 20; } .hf-srcs { order: 21; width: 100%; } .hf-att { order: 22; margin-top: .75rem; }
  .hf-n[data-st="3"] { order: 30; } .hf-draft { order: 31; }
  .hf-n[data-st="4"] { order: 40; } .hf-ok { order: 41; }
  .hf-n[data-st="5"] { order: 50; } .hf-log { order: 51; }
  .hf-n[data-st="6"] { order: 60; } .hf-out { order: 61; } .hf-next { order: 62; margin: .75rem 0 0 1.5rem; }
  .hf-ok-row { grid-template-columns: auto 1fr auto; gap: 16px; }
  .hf-role { font-size: 17px; }
}

/* ---- tablets and desktop: the collage. A box of 730 x 700 units; everything in it scales with the box. ---- */
@media (min-width: 48rem) {
  .hf { container-type: inline-size; aspect-ratio: 730 / 700; }
  .hf-in { position: absolute; inset: 0; --u: calc(100cqw / 730); }
  .hf-a, .hf-n { position: absolute; }
  .hf-n { left: var(--x); top: var(--y); }
  .hf-rules { display: block; position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
  .hf-next { left: 0; top: 4.857%; width: 45.2%; height: 16%; z-index: 1; }
  .hf-srcs { left: 58.36%; top: 6.286%; width: 43.29%; z-index: 2; }
  .hf-doc { left: 3.562%; top: 8.571%; width: 48.63%; min-height: 65.4%; z-index: 3; }
  .hf-log { left: 0; top: 79.43%; width: 36.44%; z-index: 4; }
  .hf-out { left: 55.07%; top: 90.29%; width: 44.93%; z-index: 4; }
  .hf-ok { left: 39.73%; top: 63.43%; width: 65.75%; z-index: 5; }
  .hf-names { position: absolute; inset: 0; z-index: 6; pointer-events: none; }
  .hf-n { font-size: clamp(1rem, .64rem + .56vw, 1.1875rem); }
}
/* a small collage (the box under 656 px: 1024 to about 1300 px wide screens, short screens, tablets): type has reached its
   11 px floor and takes more of the box, so the request loses its grey body lines and the slip sits tighter. Keeps the
   marked line of the draft clear of the slip. */
@container (max-width: 41rem) {
  .hf-req .hf-body { display: none; }
  .hf-ok-row { margin-top: calc(12 * var(--u)); }
  .hf-ck { margin-top: calc(6 * var(--u)); }
}
@media (min-width: 48rem) and (max-width: 63.99rem) {
  /* tablets: the words, then the collage below them, still in the flow of the page */
  .hs { display: flex; flex-direction: column; }
  .hs-txt { padding-bottom: 0; }
  .hf-stage { order: 2; padding-block: clamp(4rem, 12svh, 7rem) 20svh; }
  .hf { width: min(100% - 3.5rem, 50rem); }
}
@media (min-width: 64rem) {
  /* desktop: the collage is held in the right 55 % while the words scroll past on the left */
  .hf-stage { position: sticky; top: 0; height: 100svh; margin-bottom: -100svh; z-index: 0; pointer-events: none; }
  .hf-wrap { height: 100%; display: grid; justify-items: end; align-items: center; padding-top: var(--hd); }
  .hf { width: min(55%, (100svh - var(--hd) - 3rem) * 1.0429); transform-origin: 50% 50%; }
}
@media (min-width: 64rem) and (prefers-reduced-motion: no-preference) {
  /* the band's roll-up exit: the held figure shrinks a little and dims as the next panel rises over it (--out, home.js) */
  .js .hs .hf { transform: scale(calc(1 - .06 * var(--out, 0))); opacity: calc(1 - .62 * var(--out, 0)); }
}

/* reduced motion: nothing is held and nothing moves. The words in one block, the finished figure beside them. */
@media (min-width: 64rem) and (prefers-reduced-motion: reduce) {
  .hf-stage { position: absolute; inset: 0; height: auto; margin: 0; }
  .hs-txt { padding-block: calc(var(--hd) + 5rem) 6rem; min-height: 52rem; }
  .hs-paras { margin-top: 3rem; }
  .hs-paras p + p { margin-top: 1.75rem; }
}
@media (prefers-reduced-motion: reduce) { .hf *, .hf-n { transition: none !important; } }

/* ---------- THE LIGHT GROUND (home.py FIRST_LIGHT, owner 2026-11-11: "the first transition should move to the light
   version"): the same piece drawn on Paper. Its colour words are re-pointed (Glass -> Ink, Steel -> ink at 62 %, Teal -> the
   deeper Teal of the Paper ground) and its panels are a whisper lighter than the ground with ink hairlines; the few fixed
   colours of the dark drawing are restated in ink. Nothing else of the piece changes. ---------- */
.hs.hs-light { background: var(--bg); color: var(--fg); }
.hs-light { --c-glass: var(--c-ink); --c-steel: color-mix(in srgb, var(--c-ink) 62%, var(--c-paper)); --c-teal: var(--c-teal-l); }
.hs-light .hf { --hf-panel: color-mix(in srgb, #fff 55%, var(--c-paper)); --hf-panel-2: #fff;
  --hf-edge: rgb(15 27 34 / .2); --hf-hair: rgb(15 27 34 / .11); --hf-bar: rgb(15 27 34 / .15); }
.hs-light .hf-flag { background: rgb(15 27 34 / .045); }
.hs-light .hf-flag > span:last-child { border-color: rgb(15 27 34 / .55); }
.hs-light .hf-tb > div:first-child .hf-bar { background: rgb(15 27 34 / .32); }
.hs-light .hf-pg b { background: rgb(15 27 34 / .35); }
.hs-light .hf-ok { border-color: rgb(15 27 34 / .26); }
.hs-light .hf-fld > .hf-c { border-top-color: rgb(15 27 34 / .38); }
.hs-light .hf-sw { background: rgb(8 87 98 / .12); }
.hs-light .hf-lr { color: rgb(15 27 34 / .82); }
.hs-light .hf-rules path { stroke: rgb(15 27 34 / .4); }
.hs-light .hf-n::before { background: rgb(15 27 34 / .4); }
