/* Lakou web pages, direction A (Tom, 2026-09-30): status tiles, The Neue Black headings,
   Atkinson Hyperlegible Next for text and Mono for job numbers and file names, all served
   from /static (no font service). Blackberry Studios purple as ink and primary; yellow only
   as a fill behind purple content; light theme always. Sizes are in rem so the pages follow
   the browser's text size up to 200 percent; nothing is under 14 px (0.875rem) at 100. Tap
   targets 48 px, primary buttons 56 px. Colour names match the Android tokens
   (android/.../ui/theme/Tokens.kt) and the mockups (docs/lakou2/phase-1/mockups).
   The Neue Black is drawn with its ligatures off everywhere (contract 2.22): body turns them
   off and every element inherits it, and no rule sets that face through the font shorthand,
   which would turn them back on. tests/test_web_faces.py runs shared/tools/face_check.py on
   this file. */

/* Digits in the face (contract 2.22, decided 2026-10-02): The Neue Black draws its zero as its
   capital O, so "1600 Schley St" in a project header read "16OO Schley St". The family is two
   rules: the face's own file for every character but 0 to 9, and Atkinson Hyperlegible Next's
   file for 0 to 9 alone, at its heaviest weight, 800, so the browser picks the face per
   character and the digits sit with the letters at the same size. Both rules carry one weight,
   800, and the same style: Chrome 153 took a rule left at 100 900 as a second face and drew
   the digits in Arial Black, and with both at 100 900 drew them at each element's weight. Every
   line in the face keeps a set line height (body's 1.45 or its own), since Atkinson Hyperlegible
   Next stands taller than the face. The font files are not changed. */
@font-face {
  font-family: "The Neue Black";
  src: url("/static/fonts/the-neue-black/TheNeue-Black.woff2") format("woff2");
  font-weight: 800;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0000-002F, U+003A-10FFFF;
}
@font-face {
  font-family: "The Neue Black";
  src: url("/static/fonts/atkinson-hyperlegible-next/AtkinsonHyperlegibleNext-wght.ttf") format("truetype");
  font-weight: 800;
  font-style: normal;
  font-display: swap;
  unicode-range: U+0030-0039;
}
@font-face {
  font-family: "Atkinson Hyperlegible Next";
  src: url("/static/fonts/atkinson-hyperlegible-next/AtkinsonHyperlegibleNext-wght.ttf") format("truetype");
  font-weight: 200 800;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Atkinson Hyperlegible Mono";
  src: url("/static/fonts/atkinson-hyperlegible-mono/AtkinsonHyperlegibleMono-wght.ttf") format("truetype");
  font-weight: 200 800;
  font-style: normal;
  font-display: swap;
}

:root {
  --purple: #2b1a46;
  --yellow: #ffe80a;
  --ink: #2b1a46;
  --muted: #5b4a7a;
  --bg: #f7f5fa;
  --surface: #ffffff;
  --raised: #f1eef6;
  --selected: #efeaf7;
  --outline: #6e6387;
  --hairline: #e4dfec;
  --on-purple: #ffffff;
  --on-purple-muted: #cfc4e3;
  --display: "The Neue Black", "Arial Black", system-ui, sans-serif;
  --body: "Atkinson Hyperlegible Next", system-ui, sans-serif;
  --mono: "Atkinson Hyperlegible Mono", ui-monospace, "Cascadia Mono", monospace;
  /* The phone tab bar's height: its padding, the 32 px pill, the gap and one line of 0.875rem
     words, so it grows with the text size (67 px at 100 percent). The pages clear it by the
     same amount. It was 76 px at the least until the fourth finishing review, which found it
     and the Add files bar over a sixth of a 390 by 844 window. */
  --tabbar: calc(50px + 1.05rem);
  /* The side margin on a phone: 16 px at any text size, as Android's 16 dp, so large text
     gets the width (the second finishing review: at 200 percent a 32 px margin left the
     project title and the folder question too little room to grow). */
  --gutter: 16px;
  color-scheme: light;
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { background: var(--bg); }
/* The strip and the page share the window's height, so a short page fits the window. */
body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--body);
  font-size: 1.0625rem;
  line-height: 1.45;
  -webkit-font-smoothing: antialiased;
  overflow-wrap: break-word;
  /* The Neue Black joins c and k, s and t and more when its ligatures are on; Chrome drew them
     on tile names and dropped them on the letter-spaced headings, so one word looked two ways
     (the third finishing review). Off here, so every element inherits it. */
  font-variant-ligatures: none;
}
h1, h2, h3 {
  font-family: var(--display);
  font-weight: 400;
  font-synthesis: none;
  letter-spacing: 0.005em;
  line-height: 1.1;
  margin: 0;
}
/* A heading breaks only between words: break-word breaks inside a word only when that word
   is wider than the whole line, and each page sizes its large headings to their box so a
   real word never is. */
h1 { font-size: 2.25rem; min-width: 0; overflow-wrap: break-word; word-break: normal; hyphens: none; }
h2 { font-size: 1.375rem; margin: 1.75rem 0 0.75rem; }
.job, .mono {
  font-family: var(--mono);
  font-weight: 700;
  letter-spacing: 0.01em;
}
a { color: inherit; }
img { display: block; }
p { margin: 0; }
:focus-visible { outline: 3px solid var(--purple); outline-offset: 2px; }
/* On the purple band the ring is white, so it shows against the purple behind it. */
.tband :focus-visible { outline-color: var(--on-purple); }

/* icons from /static/icons.svg, drawn in the text colour */
.i { flex: none; display: block; }
.status, .line, .who, .notice, .act, .btn, .working { display: flex; align-items: center; gap: 0.5rem; }

/* the strip saying the layout is not final, until Tom approves the built screens */
.not-final {
  margin: 0;
  padding: 0.5rem var(--gutter);
  background: var(--yellow);
  color: var(--purple);
  font-size: 0.875rem;
  font-weight: 700;
  line-height: 1.35;
}

/* ---------- shell: bottom tab bar under 900 px, left rail at 900 px and wider ---------- */
.shell { display: flex; flex-direction: column; flex: 1 0 auto; }
.out #main { flex: 1 0 auto; }
.rail { display: contents; }
.brand {
  order: 1;
  display: flex;
  align-items: center;
  gap: 0.625rem;
  min-height: 3.5rem;
  padding: 0.5rem var(--gutter);
  text-decoration: none;
  color: var(--ink);
}
.brand-name { font-family: var(--display); font-size: 1.5rem; }
.appicon {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 0.75rem;
  background: var(--purple);
  display: grid;
  place-items: center;
  flex: none;
}
.appicon img { width: 1.75rem; height: 1.75rem; }
#main { order: 2; flex: 1; padding: 0.25rem var(--gutter) 1.5rem; min-width: 0; }
.out #main { padding: 0 0 2rem; }
.me {
  order: 3;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem 1rem;
  /* clear the tab bar at the bottom of a phone screen, the one thing fixed there */
  padding: 1rem var(--gutter) calc(var(--tabbar) + 1rem);
  border-top: 1px solid var(--hairline);
  font-size: 0.9375rem;
}
.who { gap: 0.625rem; }
.tabs {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 5;
  display: flex;
  min-height: var(--tabbar);
  background: var(--surface);
  border-top: 1px solid var(--hairline);
  overflow-x: auto;
}
/* Five tabs share the phone's width, their words at the person's text size. When the five
   no longer fit side by side, app.js sets .compact: the open tab keeps its word and the
   others show their icons alone, each named by its aria-label, as Android's tab bar does at
   a large font. A window too narrow even for that scrolls the bar, and app.js brings the
   open tab into view. */
.tab {
  flex: 1 0 0;
  min-width: max-content;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 4px;
  min-height: 48px;
  padding: 6px 4px;
  color: var(--muted);
  font-size: 0.875rem;
  font-weight: 600;
  line-height: 1.2;
  text-decoration: none;
  text-align: center;
  white-space: nowrap;
}
.tab .pill { width: 60px; height: 32px; border-radius: 16px; display: grid; place-items: center; }
.tab.on { color: var(--ink); font-weight: 800; }
.tab.on .pill { background: var(--selected); }
.tabs.compact .tab:not(.on) { flex: 0 0 auto; min-width: 48px; padding: 6px 2px; }
.tabs.compact .tab:not(.on) .pill { width: 48px; }
.tabs.compact .tab:not(.on) .lab { display: none; }

@media (min-width: 900px) {
  :root { --gutter: 2rem; }
  .shell { display: grid; grid-template-columns: min(15rem, 30vw) minmax(0, 1fr); align-items: start; }
  /* The rail fills the window under the strip on a short page, and the window on a long one,
     where it stays in place as the page scrolls. */
  .rail {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    position: sticky;
    top: 0;
    min-height: min(100%, 100vh);
    padding: 1.25rem 0.875rem;
    background: var(--surface);
    border-right: 1px solid var(--hairline);
  }
  .brand { order: 0; padding: 0 0.5rem 1rem; }
  .brand-name { font-size: 1.625rem; }
  .tabs {
    position: static;
    flex-direction: column;
    gap: 0.25rem;
    min-height: 0;
    border: 0;
    overflow: visible;
    background: transparent;
  }
  .tab {
    flex: none;
    min-width: 0;
    flex-direction: row;
    justify-content: flex-start;
    gap: 0.875rem;
    min-height: 3rem;
    padding: 0 0.875rem;
    border-radius: 1.5rem;
    font-size: 1rem;
    white-space: normal;
    text-align: left;
  }
  .tab .pill { width: auto; height: auto; }
  .tab.on { background: var(--selected); }
  .tab.on .pill { background: transparent; }
  .me { margin-top: auto; padding: 1rem 0.5rem 0; border-top: 0; flex-direction: column; align-items: flex-start; }
  #main { padding: 1.5rem var(--gutter) 3rem; }
}

/* ---------- shared bits ---------- */
.badge {
  display: inline-flex;
  align-items: center;
  background: var(--yellow);
  color: var(--purple);
  border-radius: 0.375rem;
  padding: 0.125rem 0.5rem;
  font-size: 0.9375rem;
  line-height: 1.4;
  white-space: nowrap;
}
.nonum { font-size: 0.875rem; font-weight: 700; color: var(--muted); }
/* A job number or house numbers inside a line of words stay whole: Chrome breaks "24AC-01"
   and "51-59" after the hyphen when the line is short (routes.whole_numbers). */
.whole { white-space: nowrap; }
/* A job number never breaks either, and inside a heading-face line it is the line's number in
   the mono face (contract 2.22): "Folders not made for 26017." read "26O17" in The Neue Black. */
.job { white-space: nowrap; }
.quiet, .val, .place, .sub { color: var(--muted); }
/* An icon's circle keeps its size at any text size, as Android's dp circles do: the icon
   inside does not grow, and a circle that doubled with the text took the room its words
   needed (the third finishing review: a speck in an 88 px circle at 200 percent). */
.glyph {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--selected);
  color: var(--purple);
  flex: none;
}
.glyph.y { background: var(--yellow); }
.glyph.sm { width: 40px; height: 40px; }
.glyph.big { width: 72px; height: 72px; }
.line { gap: 0.625rem; margin: 0.75rem 0; font-size: 1rem; }
.line .i { align-self: flex-start; margin-top: 0.125rem; }
.btn {
  justify-content: center;
  gap: 0.625rem;
  min-height: 3rem;
  min-width: 3rem;
  padding: 0 1.375rem;
  border-radius: 1.75rem;
  border: 0;
  font: 700 1rem/1.25 var(--body);
  color: var(--ink);
  background: transparent;
  cursor: pointer;
  text-decoration: none;
}
.btn.primary { background: var(--purple); color: var(--on-purple); min-height: 3.5rem; }
.btn.outline { background: var(--surface); box-shadow: inset 0 0 0 1.5px var(--outline); }
.btn.block { width: 100%; }
.btn:disabled { cursor: default; background: var(--raised); color: var(--muted); box-shadow: none; }
/* A status line: its icon, then its words (app.js sets both). The line stays in the page as a
   live region; while it has no words it takes no room and its icon does not show. */
.status { min-height: 1.5rem; font-size: 0.9375rem; }
.status:empty, .status:has(> span:empty) { min-height: 0; }
.status:has(> span:empty) > .i { display: none; }
.status > .i { align-self: flex-start; margin-top: 0.0625rem; }
label { font-weight: 700; }
input[type="text"], input[type="search"], select {
  width: 100%;
  min-height: 3rem;
  padding: 0.5rem 0.75rem;
  border: 1.5px solid var(--outline);
  border-radius: 0.75rem;
  font: inherit;
  color: var(--ink);
  background: var(--surface);
}
::placeholder { color: var(--muted); opacity: 1; }

/* ---------- sign in: the lockup's yellow letters stay on purple ---------- */
.hero {
  background: var(--purple);
  color: var(--on-purple);
  /* the sides stay narrow at a large text size, so Lakou keeps to one line */
  padding: 1.75rem min(1.5rem, 6vw) 2.25rem;
}
.hero .lockup { width: 14.5rem; max-width: 100%; height: auto; }
.hero .appname { font-size: min(5rem, 20vw); line-height: 1; margin: 2.25rem 0 0.875rem; }
.hero .intro { font-size: 1.3125rem; line-height: 1.4; max-width: 24rem; }
/* The sign-in column keeps the 16 px gutter at any text size, as the other pages and Android's
   16 dp do, so large text gets the width (the sixth finishing review: 1.5rem sides, 48 px each
   at 200 percent, and the indent broke cloud.blackberry.studio inside its word). The first-time
   line starts under the lock line's words (the 24 px icon and the line's gap), as on Android,
   while the column holds 20rem of text; at a larger text size it takes the column's whole
   width (the indent drops to 0 once 100cqi is under 20rem). The button's sides stay 16 px, so
   its words get the width too. */
.signin { max-width: 32rem; padding: 1.5rem var(--gutter); display: flex; flex-direction: column; gap: 0.75rem; container-type: inline-size; }
.signin .line { font-size: 1.125rem; margin: 0; }
.signin .indent { padding-left: max(0px, min(calc(24px + 0.625rem), calc((100cqi - 20rem) * 100))); font-size: 1rem; }
.signin .btn { margin-top: 1.5rem; padding: 0.5rem 16px; }
/* A web address in a line (routes.domain_breaks): one inline block no wider than the line, so it
   goes onto the next line whole, and breaks after a dot only when wider than a whole line. */
.addr { display: inline-block; max-width: 100%; }
@media (min-width: 900px) {
  .hero { padding: 3rem max(1.5rem, calc(50% - 20rem)); }
  .signin { margin: 0 auto; max-width: 40rem; }
}

/* ---------- tabs not built yet ---------- */
.empty { max-width: 36rem; margin: 3rem auto; text-align: center; display: flex; flex-direction: column; align-items: center; gap: 1rem; }
.empty h1 { font-size: 2rem; }
.empty p { font-size: 1.125rem; }

/* ---------- projects list ---------- */
.whead { display: flex; flex-wrap: wrap; align-items: center; gap: 0.75rem 1.125rem; margin: 0.5rem 0 1rem; }
.whead h1 { font-size: min(2.5rem, 14vw); }
.chips { display: flex; flex-wrap: wrap; gap: 0 0.5rem; }
.chip { min-height: 3rem; display: inline-flex; align-items: center; text-decoration: none; color: var(--ink); }
.chip span {
  min-height: 2.25rem;
  padding: 0.25rem 0.875rem;
  border-radius: 1.125rem;
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  box-shadow: inset 0 0 0 1.5px var(--outline);
  background: var(--surface);
  font-weight: 600;
  font-size: 0.9375rem;
}
.chip.on span { background: var(--purple); color: var(--on-purple); box-shadow: none; }
/* Find a project: at the top of the list, under the chips on a phone and at the right of the
   header row on a desk (mockup 10a), scrolling away with the page, so nothing fixed covers the
   tiles or rows at any text size. Its name is visible words beside the field, never a
   placeholder that a narrow field cuts; when the words and the field do not fit on one line
   (large text), the field goes under. On a desk it shrinks to stay in the header row. */
.find {
  flex: 1 1 100%;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0 0.75rem;
  min-height: 3.5rem;
  padding: 0.25rem 1.25rem;
  border-radius: 1.75rem;
  background: var(--surface);
  box-shadow: inset 0 0 0 1.5px var(--outline);
  color: var(--ink);
}
.find-label { flex: none; display: flex; align-items: center; gap: 0.5rem; font-weight: 700; line-height: 1.3; }
.find input {
  flex: 1 1 8rem;
  min-width: 8rem;
  min-height: 2.5rem;
  padding: 0 0.125rem;
  border: 0;
  border-bottom: 1.5px solid var(--outline);
  border-radius: 0;
  background: transparent;
}
.find input:focus-visible { outline: none; border-bottom: 3px solid var(--purple); }
.find:focus-within { box-shadow: inset 0 0 0 3px var(--purple); }
@media (min-width: 900px) {
  .find { flex: 1 1 13rem; max-width: 24rem; margin-left: auto; padding: 0.25rem 1rem; }
  .find input { flex-basis: 4rem; min-width: 4rem; }
}
/* the heading over the chosen chip's list (contract 2.13) */
.lhead { font-size: 1.375rem; margin: 0.25rem 0 0.75rem; }
.notice {
  gap: 0.75rem;
  flex-wrap: wrap;
  min-height: 3.5rem;
  padding: 0.75rem 1rem;
  margin: 0 0 1rem;
  border-radius: 1.25rem;
  text-decoration: none;
}
.notice.accent { background: var(--yellow); color: var(--purple); box-shadow: inset 0 0 0 2px var(--purple); }
/* The to-check line is drawn whole in the body face at 700, as Android draws it (contract 2.22,
   never_in_display): its count of 10 read "1O" in The Neue Black. */
.notice .lab { font-family: var(--body); font-weight: 700; font-size: 1.25rem; line-height: 1.3; }
.notice .go { margin-left: auto; font-weight: 800; text-decoration: underline; text-underline-offset: 3px; }

/* Pinned projects as status tiles (mockup 10a, contracts 2.14 and 2.16): building icon and job
   number, the short name in large type, the town, then the ring or the status line with the
   day of the last file, and the yellow folder question chip. Purple while a file uploads or a
   folder question waits, quiet grey when paused, finished, cancelled or not won, else white. Two tiles
   side by side on a phone, four on a desk at 1280 px, one when the text is large.
   A street name breaks only between words: the tiles sit in lines that wrap, and a tile is
   never narrower than the longest word of its name (a flex item is at least as wide as its
   longest word), so a tile whose word does not fit one column takes the room it needs, up to
   the whole line, and the tiles after it move along ("Brunswick", "Highlander" on a phone).
   The name's size is held to the line: a word 8 em wide in The Neue Black fits the whole line
   at any text size ("Pennsylvania" is 7.9 em), so only a longer word may break, rather than
   run out of its tile. The empty spacers at the end keep the last line's tiles as wide as the
   others. */
.pinned { margin: 0 0 1.25rem; }
.phead2 { display: flex; align-items: center; gap: 0.5rem; }
.ptiles { display: flex; flex-wrap: wrap; column-gap: 0.625rem; container-type: inline-size; }
.tile, .tile-fill { flex: 1 1 10rem; }
@media (min-width: 900px) { .ptiles { column-gap: 0.875rem; } .tile, .tile-fill { flex-basis: 13rem; } }
.tile-fill { height: 0; }
.tile {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  max-width: 100%;
  margin-bottom: 0.625rem;
  min-height: 11rem;
  padding: 0.875rem 0.875rem 0.75rem;
  border-radius: 1.5rem;
  background: var(--surface);
  color: var(--ink);
  box-shadow: inset 0 0 0 1px var(--hairline);
  text-decoration: none;
}
.tile.purple { background: var(--purple); color: var(--on-purple); box-shadow: none; }
.tile.grey { background: var(--raised); box-shadow: none; }
.ttop { display: flex; justify-content: space-between; align-items: flex-start; gap: 0.5rem; margin-bottom: 0.25rem; }
.tile.grey .glyph { background: var(--surface); }
.tile.purple .glyph.y { background: var(--yellow); color: var(--purple); }
.tnum { font-size: 1rem; text-align: right; min-width: 0; }
.tile.purple .nonum { color: var(--on-purple-muted); }
.tshort {
  font-family: var(--display);
  font-size: 1.5rem;
  font-size: min(1.5rem, calc((100cqi - 1.75rem) / 8));
  line-height: 1.1;
  overflow-wrap: break-word;
  word-break: normal;
  hyphens: none;
}
.tplace, .tmeta { color: var(--muted); font-size: 0.9375rem; line-height: 1.35; }
.tile.purple .tplace, .tile.purple .tmeta { color: var(--on-purple-muted); }
/* A tile's and a row's scope of work: a line of its own under the town (contract 2.24, places tile
   and row), doc beside it as folder sits beside the team folder, so it reads as the scope and not as
   another place (the review of 2026-10-05); a scope longer than the room wraps beside the icon,
   never cut, as no text on a page is. The folder question's project row shows it the same way. */
.tscope, .pscope { display: flex; align-items: flex-start; gap: 0.25rem; min-width: 0; max-width: 100%; color: var(--muted); font-size: 0.9375rem; line-height: 1.35; }
.tscope > svg, .pscope > svg { flex: none; margin-top: calc((1.35em - 18px) / 2); }
.tscope > span, .pscope > span { min-width: 0; overflow-wrap: anywhere; }
.tile.purple .tscope { color: var(--on-purple-muted); }
.tstate { margin-top: auto; padding-top: 0.5rem; display: flex; flex-direction: column; align-items: flex-start; gap: 0.25rem; }
.tile .status { font-weight: 700; font-size: 0.9375rem; line-height: 1.3; }
/* Uploading goes under the ring when the two do not fit side by side. */
.tile .status.ringline { flex-wrap: wrap; }
.tile .status .i { align-self: flex-start; }
.tile.purple .ring-track { stroke: var(--muted); }
.tile.purple .ring-fill { stroke: var(--on-purple); }
.qchip {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  margin-top: 0.25rem;
  padding: 0.25rem 0.625rem 0.25rem 0.5rem;
  border-radius: 0.75rem;
  background: var(--yellow);
  color: var(--purple);
  font-weight: 700;
  font-size: 0.875rem;
  line-height: 1.35;
}

/* The projects list as rows (mockup 10a, Android's ProjectRow): building icon, job number and
   title, town and team folder, then the status line, an icon with its words and no colour.
   One column on a phone; as many 17.5rem columns as fit on a desk, three at 1280 px as mockup
   10a draws them. */
.plist { display: grid; grid-template-columns: minmax(0, 1fr); gap: 0.625rem; }
@media (min-width: 900px) { .plist { grid-template-columns: repeat(auto-fill, minmax(min(100%, 17.5rem), 1fr)); gap: 0.75rem; } }
/* At a large text size the words go under the icon rather than squeeze beside it. */
.prow {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 0.875rem;
  min-height: 4rem;
  padding: 0.75rem 0.875rem;
  border-radius: 1.25rem;
  background: var(--surface);
  box-shadow: inset 0 0 0 1px var(--hairline);
  text-decoration: none;
  color: var(--ink);
}
.pmain { flex: 1 1 12rem; min-width: 0; display: flex; flex-direction: column; gap: 0.125rem; }
.phead { font-weight: 700; font-size: 1.0625rem; line-height: 1.3; overflow-wrap: break-word; }
/* One space between the number and the name, the literal one in the markup: a margin beside it
   read as two spaces, and indented a name that went under its number (the seventh finishing
   review). */
.pnum { white-space: nowrap; }
.pplace { display: flex; flex-wrap: wrap; align-items: center; gap: 0.125rem 0.75rem; color: var(--muted); font-size: 0.9375rem; line-height: 1.35; }
.pteam { display: inline-flex; align-items: center; gap: 0.25rem; }
.prow .status { font-weight: 700; font-size: 0.9375rem; line-height: 1.3; margin-top: 0.25rem; }
.prow .status .i { align-self: flex-start; }

/* upload ring: done of total, on two lines at every text size and every count, "2 of" over
   "3" as mockups 04a, 05a and 10a draw it (contract 2.14 step 4, ring_count). The server draws
   the two lines, broken at the count's last space, each a block that does not wrap, and the
   count holds no width of its own, so the ring grows to its wider line ("10 of", "100 of")
   and nothing splits a line further (the seventh finishing review: a box of 3.15 em split "10
   of" from "12" into three lines, since "10 of" is 3.16 em in the mono face). The padding
   (1 em of the count's size) keeps the words' corners inside the ring's inner edge (the r=25
   circle with a 5 unit stroke in its 56 unit box) for counts up to four digits; 0.875 em let
   "100 of" over "120" reach past it at 200 percent text. While the first line holds four
   characters ("9 of"), the 4rem minimum sets the ring's size, as before. The count is set in
   the mono face at 700, as job numbers are, never in The Neue Black, whose zero and capital O
   are the same shape, so "0 of 2" read "O of 2" (contract 2.14 step 4, 2.22). */
.ring {
  position: relative;
  display: inline-grid;
  place-items: center;
  flex: none;
  aspect-ratio: 1;
  min-width: 4rem;
  padding: 1em;
  font-family: var(--mono);
  font-weight: 700;
  font-size: 0.875rem;
  line-height: 1;
}
.ring svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.ring-track { fill: none; stroke: var(--hairline); stroke-width: 5; }
.ring-fill { fill: none; stroke: var(--purple); stroke-width: 5; stroke-linecap: round; }
.ring-text { position: relative; text-align: center; }
.ring-line { display: block; white-space: nowrap; }

/* ---------- project page ---------- */
.tband {
  background: var(--purple);
  color: var(--on-purple);
  padding: 1rem var(--gutter) 1.25rem;
  margin: 0 calc(-1 * var(--gutter));
  container-type: inline-size;
}
@media (min-width: 900px) { .tband { margin: 0; border-radius: 1.5rem; padding: 1.25rem 1.5rem 1.5rem; } }
.tband-top { display: flex; justify-content: space-between; align-items: center; gap: 0.75rem; }
.tband-top .badge { font-size: 1.125rem; }
/* Every job number, main first, each on its own badge (contract 2.18). */
.tnums { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 0.5rem; min-width: 0; }
.tband .nonum { color: var(--on-purple-muted); }
/* The title sized to the band: a word 8 em wide fits its whole width at any text size, so a
   street name breaks only between words ("79-81 Brunswick St" at 200 percent). The town under
   it is three quarters of the title's size at most, so the title is never the smaller of the
   two (the second finishing review: at 200 percent "Newark" was larger than "51-59 16th Ave"). */
.tband { --title: min(2.75rem, 12.5cqi); }
.tband h1 { font-size: min(2.75rem, 12vw); font-size: var(--title); margin: 0.75rem 0 0.25rem; }
.tband .town { font-size: min(1.375rem, calc(var(--title) * 0.75)); color: var(--on-purple-muted); font-weight: 700; }
/* A note the title carries after its town ("Ret Wall"), on its own line under the town (contract
   2.14, the review of 2026-10-03), smaller than the town, never under 14 px. */
.tband .note { font-size: max(0.875rem, min(1.125rem, calc(var(--title) * 0.6))); color: var(--on-purple-muted); font-weight: 700; margin-top: 0.125rem; }
.facts { display: flex; flex-wrap: wrap; align-items: center; gap: 0.25rem 1.25rem; margin: 0.875rem 0 0; font-size: 1rem; }
.facts dt { display: inline; font-weight: 800; color: var(--on-purple); }
.facts dd { display: inline; margin: 0; color: var(--on-purple-muted); }
/* The Status fact: the status's icon beside its word, in the fact's own ink (contract 2.13). */
.facts dd.fact { display: inline-flex; align-items: center; gap: 0.375rem; vertical-align: top; }
/* The Status fact is the status control's button (contract 2.13, 2026-10-03): the fact's icon and
   words in the fact's ink, then the chevron that opens the control, at least 48 px tall. Open, its
   choices sit on a white panel under the facts, as the building type's do, then the reason field
   and its button for Paused; under them the line of what was saved, then Undo under it, all
   before Team folder, as Android draws them (the review of 2026-10-03: at 390 px Team folder sat
   between the Status button and its choices). */
.facts .statusfact { display: inline-flex; flex-wrap: wrap; align-items: center; column-gap: 0.375rem; }
.factpick { display: inline-flex; align-items: center; gap: 0.375rem; min-height: 3rem; padding: 0 0.25rem; margin: 0; border: 0; border-radius: 0.75rem; background: none; color: inherit; font: inherit; cursor: pointer; text-align: left; }
.factpick > .i:last-child { flex: none; color: var(--on-purple); }
.factpick[aria-expanded="true"] > .i:last-child { transform: rotate(180deg); }
.factpick:focus-visible { outline: 3px solid var(--on-purple); outline-offset: 2px; }
.statuspanel { margin-top: 0.75rem; max-width: 36rem; background: var(--surface); color: var(--ink); border-radius: 1.25rem; padding: 0.5rem; }
.statuspanel .typelist { margin: 0; }
.statuspanel :focus-visible { outline-color: var(--purple); }
.pausebox { display: flex; flex-direction: column; gap: 0.5rem; margin: 0.75rem 0.25rem 0.25rem; }
.pausebox .lab { font-weight: 700; }
.pausebox textarea { min-height: 3rem; padding: 0.625rem 0.75rem; border-radius: 0.75rem; border: 1.5px solid var(--outline); font: inherit; line-height: 1.35; color: var(--ink); background: var(--surface); width: 100%; box-sizing: border-box; resize: none; field-sizing: content; overflow-wrap: anywhere; }
.pausebox textarea:focus-visible { outline: 3px solid var(--purple); outline-offset: 2px; }
.pausebox .btn { align-self: flex-start; }
.statusline { display: block; margin-top: 0.5rem; }
.statusline .btn { min-height: 3rem; margin-top: 0.5rem; }
/* With nothing to say yet, the line takes no room, and Team folder sits under Status as the facts
   of one row do. */
.statusline:has(> #status-saved > span:empty):has(> #status-undo[hidden]) { margin-top: 0; }
.statusline:has(> #status-saved > span:empty):has(> #status-undo[hidden]) + dl.facts { margin-top: 0.25rem; }
.also { margin-top: 0.375rem; color: var(--on-purple-muted); font-size: 1rem; }
/* The scope of work (contract 2.24, 2026-10-04): a fact under the heading and its town, in the
   place of the note a title carries, its words in the fact's ink, then the chevron that opens the
   field, at least 48 px tall, as the Status fact's. Open, the field sits on a white panel, a box
   that grows with its words, so a long scope wraps at 200 percent text and none is cut off; its
   button under it; then the line of what was saved and Undo under it. */
.facts.scopefacts { margin-top: 0.5rem; }
.facts .scopefact { display: inline-flex; flex-wrap: wrap; align-items: center; column-gap: 0.375rem; min-width: 0; }
.scopefact [data-scope-words] { overflow-wrap: anywhere; }
.scopepanel { display: flex; flex-direction: column; gap: 0.5rem; margin-top: 0.75rem; max-width: 36rem; background: var(--surface); color: var(--ink); border-radius: 1.25rem; padding: 0.75rem; }
.scopepanel .lab { font-weight: 700; }
.scopepanel textarea { min-height: 3rem; padding: 0.625rem 0.75rem; border-radius: 0.75rem; border: 1.5px solid var(--outline); font: inherit; line-height: 1.35; color: var(--ink); background: var(--surface); width: 100%; box-sizing: border-box; resize: none; field-sizing: content; overflow-wrap: anywhere; }
.scopepanel textarea:focus-visible { outline: 3px solid var(--purple); outline-offset: 2px; }
.scopepanel .btn { align-self: flex-start; }
.scopepanel :focus-visible { outline-color: var(--purple); }
.scopeline:has(> #scope-saved > span:empty):has(> #scope-undo[hidden]) { margin-top: 0; }
/* A building type the scope names (contract 2.24): why, beside info, then one tap to take it. */
.suggest { display: flex; flex-direction: column; align-items: flex-start; gap: 0.25rem; margin-top: 0.5rem; max-width: 36rem; }
.suggest .line { margin: 0; }
.suggest .btn { min-height: 3rem; max-width: 100%; }
.suggest .btn span { overflow-wrap: anywhere; }
.tband .suggest .line { color: var(--on-purple); }
/* The building type control in the header, after its facts and above Pin (contract 2.12), as
   Android draws it: the building icon on the yellow fill, Building type over the type's word in
   white, the chevron. Open, its choices sit on a white panel inside the band, each a box of its
   own, with the purple focus ring a white panel needs. */
.tband .typepick { margin-top: 0.875rem; max-width: 36rem; }
.tband .typepick summary { min-height: 3.5rem; }
.tband .typepick .lab { color: var(--on-purple-muted); }
.tband .typepick summary .val { color: var(--on-purple); font-weight: 700; font-size: 1.0625rem; }
.tband .typelist { background: var(--surface); color: var(--ink); border-radius: 1.25rem; padding: 0.5rem; }
.tband .typelist :focus-visible { outline-color: var(--purple); }
.tband #building-status { margin-top: 0.5rem; }
/* Pin or Unpin: a light button on the purple band, its pin icon beside its word, and the
   line saying what was saved. */
.tband-acts { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem 1rem; margin-top: 1rem; }
.btn.onpurple { background: var(--surface); color: var(--purple); }
.tband .status { color: var(--on-purple); font-weight: 700; }

/* The folder answer's line on the project page, on the load after the answer. */
.answered { margin: 0.75rem 0 0; font-weight: 700; }
.answered:has(> span:empty) { margin: 0; }
.stiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 10rem), 1fr)); gap: 0.625rem; margin: 1rem 0 0.25rem; }
@media (min-width: 900px) { .stiles { grid-template-columns: repeat(auto-fill, minmax(min(100%, 14rem), 1fr)); } }
.stile {
  border-radius: 1.25rem;
  background: var(--surface);
  padding: 0.75rem 0.875rem;
  min-height: 7rem;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  text-decoration: none;
  color: var(--ink);
  box-shadow: inset 0 0 0 1px var(--hairline);
}
.stile.accent { background: var(--yellow); color: var(--purple); box-shadow: inset 0 0 0 2px var(--purple); }
.stile.accent .val { color: var(--purple); }
.stile .lab { font-family: var(--display); font-size: 1.125rem; line-height: 1.2; margin-top: 0.25rem; }
.stile .val { font-size: 0.9375rem; line-height: 1.35; overflow-wrap: break-word; }
.stile .team { font-weight: 700; overflow-wrap: break-word; }
.stile .ring { align-self: flex-start; }
/* Why each file was not filed, under the not filed line, each beside info (contract 2.14 step
   6): a page has no Sync screen to say it. */
.stile .line.reason { margin: 0.375rem 0 0; font-size: 0.9375rem; line-height: 1.35; }

/* The building type picker (Android's BuildingTypePicker as radio rows): a summary line with
   the type's icon and word, opening to the ten types and "No building type yet.". Each
   choice is a box of its own, a hairline round it and the boxes 0.5rem apart, more than the
   space inside one: its radio first, then the type's icon, then its word, beside them while
   the word's longest part fits there and under them, in the same box, when it does not. So
   the radio stays on its own choice's first line at any text size (the fifth finishing review:
   at 200 percent the radio, last in its row, went onto a line of its own halfway between its
   word and the next choice's icon), and the open picker is never wider than the window. Add
   files' folder choices are the same boxes. */
.typepick { min-width: 0; }
.typepick summary {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  min-height: 3rem;
  cursor: pointer;
  list-style: none;
  border-radius: 0.75rem;
}
.typepick summary::-webkit-details-marker { display: none; }
.typepick summary > .i:last-child { margin-left: auto; }
.typepick[open] summary > .i:last-child { transform: rotate(180deg); }
.pick-icon { flex: none; }
.pick-words { display: flex; flex-direction: column; min-width: 0; }
.typepick .lab { font-weight: 700; }
.typelist { margin: 0.5rem 0 0; padding: 0; border: 0; min-width: 0; display: grid; grid-template-columns: minmax(0, 1fr); gap: 0.5rem; }
.typeopt {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  align-content: center;
  gap: 0.25rem 0.75rem;
  min-height: 3.5rem;
  padding: 0.375rem 0.625rem;
  border-radius: 1rem;
  box-shadow: inset 0 0 0 1px var(--hairline);
  font-weight: 600;
  cursor: pointer;
}
/* Never narrower than its longest word while that fits the box, so the word goes under the
   radio and the icon rather than break inside. The radio, the icon and the word's first line
   share one centre line, which the taller of the radio and the 40 px icon sets, so a word of
   several lines beside them starts level with its radio, never below it. */
.typeopt .tname { flex: 1 1 0%; min-width: auto; max-width: 100%; overflow-wrap: break-word; }
.typeopt input { flex: none; width: 1.5rem; height: 1.5rem; margin: max(0px, calc((40px - 1.5rem) / 2)) 0 0; accent-color: var(--purple); }
.typeopt .glyph { margin-top: max(0px, calc((1.5rem - 40px) / 2)); }
.typeopt > .tname, .typeopt > .pick-words { padding-top: max(0px, calc((max(40px, 1.5rem) - 1lh) / 2)); }
.typeopt:has(input:checked) { background: var(--selected); }
.typeopt:has(input:focus-visible) { outline: 3px solid var(--purple); outline-offset: 2px; }
/* A status word stays whole (the review of 2026-10-04): at 390 px and 200 percent text "Not won"
   stayed beside its icon and broke between its words, "Not" over "won", while Android reads it on
   one line; a status word that does not fit beside the radio and the icon goes under them whole,
   as Finished does. */
.statuslist .tname { white-space: nowrap; }
.typelist:disabled .typeopt { cursor: default; }
.group .typepick { margin-top: 0.5rem; max-width: 30rem; }
a.stile .lab { text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 3px; }

/* Folders: tiles in lines that wrap. A tile is never narrower than the widest part of its
   name (contract 2.15): a flex item is at least as wide as its longest word, up to the whole
   line, so a long name takes the room it needs and the tiles after it move along. Names
   break only at a space or after a hyphen or an underscore (the page puts <wbr> after each
   part); only a part wider than the whole line, which no real folder name has, may break
   between letters. The empty spacers at the end keep the last line's tiles as wide as the
   others. */
.fgrid { display: flex; flex-wrap: wrap; column-gap: 0.625rem; }
.fslot, .fslot-fill { flex: 1 1 8.5rem; }
@media (min-width: 900px) { .fslot, .fslot-fill { flex-basis: 10rem; } }
.fslot-fill { height: 0; }
.fslot {
  max-width: 100%;
  margin-bottom: 0.625rem;
  background: var(--surface);
  border-radius: 1.125rem;
  padding: 0.75rem 0.625rem 0.625rem;
  min-height: 7rem;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  text-decoration: none;
  color: var(--ink);
  box-shadow: inset 0 0 0 1px var(--hairline);
}
.fslot .ic { width: 2.75rem; height: 2.75rem; border-radius: 0.75rem; background: var(--selected); display: grid; place-items: center; margin-bottom: 0.25rem; color: var(--purple); }
.fslot .no { font-family: var(--mono); font-weight: 700; font-size: 0.875rem; color: var(--muted); }
.fslot .nm { font-weight: 700; font-size: 0.9375rem; line-height: 1.25; overflow-wrap: break-word; word-break: normal; hyphens: none; }
.fslot.missing { background: var(--bg); box-shadow: none; border: 2px dashed var(--outline); }
.fslot.missing .ic { background: var(--yellow); }
.fslot.missing .nm::first-letter { text-transform: uppercase; }
.fslot .val { font-size: 0.875rem; }

.flist { list-style: none; margin: 0; padding: 0; display: grid; gap: 0.5rem; }
@media (min-width: 900px) { .flist { grid-template-columns: repeat(auto-fill, minmax(min(100%, 22rem), 1fr)); } }
.frow { display: flex; align-items: center; gap: 0.75rem; min-height: 4rem; padding: 0.625rem 0.75rem; border-radius: 1rem; background: var(--surface); box-shadow: inset 0 0 0 1px var(--hairline); text-decoration: none; color: var(--ink); }
.frow .main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 0.125rem; }
/* A file name breaks only at a space, after a hyphen or an underscore, or before the dot of
   its kind (the page puts <wbr> there, contract 2.19); only a part wider than the whole line
   may break between letters. */
.frow .fname { font-size: 0.9375rem; font-weight: 600; overflow-wrap: break-word; word-break: normal; hyphens: none; }
.frow .sub { font-size: 0.875rem; display: flex; align-items: center; gap: 0.5rem; }
.kind { background: var(--purple); color: var(--on-purple); font-family: var(--mono); font-weight: 700; font-size: 0.875rem; padding: 0 0.375rem; border-radius: 0.375rem; }

/* Add files (contract 2.21): the yellow 64 px button (64 px at any text size, so the bar stays
   low at 200 percent) with its icon and word, at the end of a solid bar across the page, as
   Android's bar under the list. The bar stays at the bottom of the window, on the tab bar,
   while the page scrolls, and after the page's last line at its end: text scrolls behind the
   bar's fill, never shows under the button (the second finishing review found file names
   passing under a clear bar). The bar's padding is 4 px on a phone, so it and the tab bar take
   139.8 px at 100 percent text, 21.2 percent of Safari's 393 by 659 window; while they take 30
   percent of an upright window or less at normal text, or a sixth otherwise (contract 2.23,
   app.js barsFit), the bar stays fixed; when they would take more (a larger text size, a
   short window), app.js sets .loose and the bar sits after the page's last line. The picker
   covers the button unseen. Picking files
   opens the panel above it: the files, the folder question when it comes first, the folder,
   File to. */
.addbar {
  position: sticky;
  bottom: var(--tabbar);
  z-index: 3;
  display: flex;
  justify-content: flex-end;
  margin: 1.5rem calc(-1 * var(--gutter)) 0;
  padding: 4px var(--gutter);
  background: var(--bg);
  border-top: 1px solid var(--hairline);
}
@media (min-width: 900px) { .addbar { bottom: 0; padding: 0.625rem var(--gutter); } }
.addbar.loose, .actionbar.loose { position: static; }
.btn.add {
  position: relative;
  min-height: 64px;
  min-width: 64px;
  padding: 0.25rem 1.5rem 0.25rem 1.25rem;
  border-radius: 1.25rem;
  background: var(--yellow);
  color: var(--purple);
  box-shadow: inset 0 0 0 2px var(--purple), 0 0.375rem 1rem rgba(43, 26, 70, 0.18);
  font-size: 1.125rem;
}
.btn.add .pickfile { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: pointer; font-size: 1rem; }
.btn.add:has(.pickfile:focus-visible) { outline: 3px solid var(--purple); outline-offset: 2px; }
.btn.add:has(.pickfile:disabled) { background: var(--raised); color: var(--muted); }
/* The panel's sides stay narrow at a large text size, so a folder's name keeps its words. */
.addpanel { margin-top: 1.5rem; display: flex; flex-direction: column; gap: 0.5rem; padding: 1rem min(1rem, 3vw); border-radius: 1.25rem; background: var(--surface); box-shadow: inset 0 0 0 1px var(--hairline); }
.addpanel h2 { margin: 0; }
/* The folder question in the panel: its button beside folder-missing, then its choices. */
.addpanel .qopts { margin: 0.25rem 0; }
.addpanel .qopt.ask { max-width: 40rem; }
.addlist { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 0.25rem; font-size: 0.9375rem; overflow-wrap: break-word; }
.slotlist legend { padding: 0; margin-bottom: 0.25rem; font-weight: 700; }
/* No folder offered yet: the folder question alone, with no empty Folder heading under it. */
.slotlist:not(:has(label.typeopt:not([hidden]))) { display: none; }
/* A folder choice, as Android's ChoiceRow: the radio first, then the folder's icon and its
   name, and Not found under the name of a missing one, in a box of its own as the building
   types are. When the name's longest word does not fit beside the radio and the icon (a large
   text size), the name goes under them, inside the same box. */
.slotlist .typeopt { padding: 0.375rem min(0.625rem, 3vw); }
.slotlist .pick-words { flex: 1 1 0%; min-width: auto; max-width: 100%; }
.slotlist .tname::first-letter { text-transform: uppercase; }
.slotlist .val { font-size: 0.875rem; }
.typeopt.missing { box-shadow: inset 0 0 0 2px var(--outline); }

/* ---------- the folder question (mockup 07) ---------- */
.qproject { display: flex; align-items: center; gap: 0.875rem; min-height: 3.5rem; margin: 0.25rem 0 1rem; padding: 0.5rem 0.875rem; border-radius: 1.25rem; background: var(--surface); box-shadow: inset 0 0 0 1px var(--hairline); text-decoration: none; color: var(--ink); }
/* The question's words may be long ("correspondence." is 10.4 em in The Neue Black): the
   heading is held to its box so it breaks only between words, and the question under it is
   never larger than the heading (the second finishing review: at 200 percent the heading was
   31 px over a 34 px question). */
.qhead { --heading: min(1.75rem, calc(100cqi / 10.5)); display: flex; flex-direction: column; align-items: flex-start; gap: 0.75rem; margin-bottom: 0.5rem; container-type: inline-size; }
.qhead h1 { font-size: 1.75rem; font-size: var(--heading); line-height: 1.15; }
.qask { font-size: min(1.0625rem, var(--heading)); }
.qopts { display: flex; flex-direction: column; gap: 0.625rem; margin: 1rem 0; max-width: 40rem; }
/* A choice: its icon's circle, then its words, which go under the circle when their longest
   word (or a path's longest part, which may break after a slash) does not fit beside it, so
   at 200 percent text a word never breaks inside. The circle, the gap and the sides keep their
   size, as Android's do, so the words get the width. */
.qopt {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 16px;
  min-height: 4rem;
  padding: 10px 16px;
  border: 0;
  border-radius: 1.25rem;
  background: var(--surface);
  box-shadow: inset 0 0 0 1.5px var(--outline);
  color: var(--ink);
  font: 700 1.0625rem/1.3 var(--body);
  text-align: left;
  cursor: pointer;
}
.qopt:disabled { cursor: default; color: var(--muted); }
/* The words are never narrower than their longest word (min-width auto) while it fits the
   button, so they go under the circle rather than break; max-width keeps that minimum to the
   button's width, so only a word wider than the whole button may break inside. */
.qwords { flex: 1 1 0%; min-width: auto; max-width: 100%; overflow-wrap: break-word; }

/* ---------- confirm found projects ---------- */
.chead { margin: 0.5rem 0 0.75rem; }
.chead h1 { font-size: min(2.25rem, 11vw); }
.chead .quiet { margin-top: 0.375rem; }
.done { font-weight: 700; }
#confirm-form { display: flex; flex-direction: column; gap: 0.875rem; }
.group { margin: 0; border: 0; padding: 0.875rem 1rem 1rem; border-radius: 1.25rem; background: var(--surface); box-shadow: inset 0 0 0 1px var(--hairline); min-width: 0; }
.gtitle { float: left; width: 100%; padding: 0; margin-bottom: 0.25rem; font-weight: 700; font-size: 1.0625rem; display: flex; align-items: center; gap: 0.5rem; }
.gtitle + * { clear: both; }
.gwords { flex: 1 1 0%; min-width: 0; }
/* A note the suggested title carries after its town, on a line of its own (contract 2.5.5, the
   review of 2026-10-03: the card read "1000-1002 Monroe Ave, Elizabeth_Ret Wall"). */
.gnote { display: block; color: var(--muted); font-size: 0.9375rem; }
/* The scope line under a group's name, drawn as on a tile or a row (.pscope: doc, then the words),
   in the body weight as theirs (the second review of 2026-10-05). */
.gscope { font-weight: 400; margin-top: 0.125rem; }
/* A group with one folder starts with its tick box (contract 2.5.5, mockup 03): 48 px square,
   its state an icon, box-checked while ticked and box while cleared, never a fill alone; the
   checkbox covers it unseen, so a tap, the keyboard and a screen reader reach it, as the
   choice chips' radios do. */
.tick { position: relative; flex: none; display: grid; place-items: center; width: 48px; height: 48px; border-radius: 0.75rem; cursor: pointer; color: var(--purple); }
.tick input.pick { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: pointer; }
.tick .mark { display: flex; }
.tick input:checked ~ .mark.off, .tick input:not(:checked) ~ .mark.on { display: none; }
.tick:has(input:focus-visible) { outline: 3px solid var(--purple); outline-offset: 2px; }
.group .val { font-size: 0.9375rem; }
.pair { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 13rem), 1fr)); gap: 0.75rem; margin: 0.5rem 0; }
.copy { display: flex; flex-direction: column; gap: 0.25rem; padding: 0.75rem; border-radius: 1rem; box-shadow: inset 0 0 0 1.5px var(--outline); font-weight: 400; cursor: pointer; }
.copy:has(input:checked) { box-shadow: inset 0 0 0 3px var(--purple); }
.copy input { width: 1.5rem; height: 1.5rem; margin: 0 0 0.25rem; accent-color: var(--purple); }
.copy-name { font-family: var(--display); font-size: min(1.25rem, 7vw); }
.copy .working { align-self: flex-start; background: var(--yellow); color: var(--purple); border-radius: 0.5rem; padding: 0.125rem 0.5rem; font-weight: 700; font-size: 0.9375rem; }
.copy input:not(:checked) ~ .working, .copy input:checked ~ .other { display: none; }
/* A copy's address, when the copies' addresses differ (mockup 03). */
.copy .where { font-weight: 700; font-size: 1rem; line-height: 1.3; }
/* These are different projects: each copy reads Separate project, in place of Working copy and
   Other copy, and none is picked as the working one (mockup 03, Android's CopyCard). */
.copy .separate { align-self: flex-start; background: var(--selected); color: var(--ink); border-radius: 0.5rem; padding: 0.125rem 0.5rem; font-weight: 700; font-size: 0.9375rem; }
.group:not(:has(input[value="separate"]:checked)) .copy .separate { display: none; }
.group:has(input[value="separate"]:checked) .copy .working,
.group:has(input[value="separate"]:checked) .copy .other { display: none; }
.group:has(input[value="separate"]:checked) .copy { box-shadow: inset 0 0 0 3px var(--purple); cursor: default; }
.group:has(input[value="separate"]:checked) .copy input { display: none; }
.acts { display: flex; flex-wrap: wrap; gap: 0.5rem; margin: 0.75rem 0 0.5rem; }
/* A group's choices on two lines (contract 2.5.5, row lines; the review of 2026-10-04): Active,
   Finished and Not won, then Not now and Not a job folder on a line of their own, so Not won never
   sits beside Not now. A line whose choices are all hidden (a group kept apart hides its own
   Active, Finished and Not won) takes no room. */
.acts.lines { flex-direction: column; flex-wrap: nowrap; }
.actline { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.actline:not(:has(> label:not([hidden]))) { display: none; }
/* A choice chip: its state is an icon (radio-on when chosen, radio-off when not) beside its
   own icon and word, never the fill alone. The radio covers the chip unseen, so a tap, the
   keyboard and a screen reader still reach it. */
.act { position: relative; min-height: 3rem; padding: 0 0.875rem 0 0.625rem; border-radius: 1.5rem; box-shadow: inset 0 0 0 1.5px var(--outline); font-weight: 700; font-size: 0.9375rem; cursor: pointer; background: var(--surface); }
.act input.pick { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: pointer; }
.act .mark { display: flex; }
.act input:checked ~ .mark.off, .act input:not(:checked) ~ .mark.on { display: none; }
.act:has(input:checked) { background: var(--purple); color: var(--on-purple); box-shadow: none; }
.act:has(input:focus-visible) { outline: 3px solid var(--purple); outline-offset: 2px; }
/* A duplicate's These are different projects (contract 2.5.5, 2026-10-02): a tick box of its own
   under the five choices, its box, then folder-copy, then its word; app.js hides it while Not
   now or Not a job folder is chosen. */
.act.sep { display: inline-flex; margin: 0 0 0.5rem; }
/* While a batch is being sent every control of every group is off (contract 2.5.5, sending): app.js
   turns them off, and a tap on one does nothing. */
.act:has(input:disabled), .tick:has(input:disabled), .group .copy:has(input:disabled) { cursor: default; }
/* A duplicate kept apart (contract 2.5.5, 2026-10-03): the line in the duplicate line's place
   clears the group's head, as the duplicate line does; one row per folder, each a box of its own
   as a copy is, its folder's name in the mono face, its lines, its three choices and its building
   type control. */
.group > p.apartline { clear: both; }
/* The rows clear the group's floated head on their own too: a group that holds projects keeps its
   rows in sight while it is left for later or set to Not now, when the line over them is hidden, and
   a grid beside the float was squeezed into a column a few letters wide (found on 2026-10-03 by the
   Not won shots, confirm-not-won, with 26AC-02 left for later). */
.apart { display: grid; gap: 0.75rem; margin: 0.25rem 0 0.5rem; clear: both; }
.apartrow { display: flex; flex-direction: column; gap: 0.25rem; padding: 0.75rem; border-radius: 1rem; box-shadow: inset 0 0 0 3px var(--purple); min-width: 0; }
.apartrow .rowname { font-weight: 700; font-size: 1rem; line-height: 1.35; }
.apartrow p.val { margin: 0; }
.apartrow .acts { margin: 0.5rem 0 0.25rem; }
.apartrow .typepick { margin-top: 0.25rem; max-width: 30rem; }
/* A folder that is a project already (apart made, the review of 2026-10-03): its box drawn as a
   copy's, not a row's, and the project's status beside its icon, with no choice. */
.apartrow.made { box-shadow: inset 0 0 0 1.5px var(--outline); }
.apartrow .madeline { margin: 0.5rem 0 0.25rem; font-weight: 700; }
/* Add to {title} on a row of a group that holds projects (contract 2.5.5, round 3 of the review of
   2026-10-03): a project's title is long, so the choice wraps inside its pill at 390 px and 200 percent.
   The pill itself shrinks to the row: round 4 found it as wide as its longest word plus its marks,
   about 30 px past the row's frame at 390 px and 200 percent (break-word lowers no min-content width,
   and a flex item keeps min-width auto). Where the column beside the radio and the icon is narrower
   than 8 em the words go under them, the full width of the pill, so a word breaks only where it is
   longer than the pill ("Brunswi" over "ck" read badly). */
.act.join { min-width: 0; max-width: 100%; flex-wrap: wrap; row-gap: 0.25rem; padding-top: 0.5rem; padding-bottom: 0.5rem; }
.act.join > span:last-child { flex: 1 1 8em; min-width: 0; overflow-wrap: anywhere; }
/* While kept apart: the line over the group's own Not now and Not a job folder. */
.group > p.apartgroup { margin: 0.5rem 0 0; }
/* Left for later: the line under a group whose tick box is cleared (row left). */
.group p.line.left { margin: 0.25rem 0 0.5rem; }
/* What each choice means, under the heading, and the year filter: All years, the years, No job
   number, each its radio mark, its word and its count (contract 2.5.5). */
#confirm-meaning { max-width: 46rem; }
/* Show the next found projects (contract 2.5.5, the third review of 2026-10-02): after the last
   group, as wide as the page on a phone, its words wrapping whole at 200 percent text. */
#confirm-next { margin: 1rem 0 1.25rem; }
#confirm-next .btn { width: 100%; max-width: 30rem; padding: 0.5rem 1.375rem; text-align: center; }
.yearpick { margin: 0.25rem 0 1rem; }
.yearpick .lab { margin: 0 0 0.125rem; font-weight: 700; }
.chips.years .chip span .i { flex: none; }
/* A year's count in a badge of its own (contract 2.5.5, year_filter count_in; the second review of
   2026-10-02): a count right after a year's four digits read as part of the year at 200 percent text
   ("2021 1" as 20211). Solid purple with white digits; white with purple digits on the chosen chip;
   on a chip that is off, the muted ink with white digits. */
.chips.years .chip .n { display: inline-block; min-width: 1.5rem; padding: 0 0.4375rem; border-radius: 0.75rem; background: var(--purple); color: var(--on-purple); text-align: center; font-weight: 700; line-height: 1.5; }
.chips.years .chip.on .n { background: var(--on-purple); color: var(--purple); }
.chips.years .chip.held .n { background: var(--muted); color: var(--on-purple); }
/* The chip chosen links nowhere. While a choice on the page is not confirmed, or a batch is being
   sent, every chip is off (contract 2.5.5, the review of 2026-10-02: a chip dropped the choices
   not confirmed, Mark all's included): app.js takes its link away, and it is drawn as a button
   that is off, as .btn:disabled is, with the line under the chips saying why. */
.chips.years .chip:not([href]) { cursor: default; }
.chips.years .chip.held span { background: var(--raised); color: var(--muted); }
#year-held { margin: 0.25rem 0 0; }
/* A copy of a duplicate set to Not now or Not a job folder cannot be picked as the working copy:
   picking one never changes the group's choice (contract 2.5.5). */
.group:has(input[name^="action-"][value="not_now"]:checked) .copy,
.group:has(input[name^="action-"][value="not_a_project"]:checked) .copy { cursor: default; }
/* In the form, what the last batch did makes no gap while it says nothing. */
#confirm-form > .batch:not(:has(> p.line:not([hidden]))) { display: none; }
#confirm-form > #confirm-meaning, #confirm-form > .yearpick { margin: 0; }
/* Confirm's bar (contract 2.5.5 and 2.23). On a phone, a solid bar across the page on the tab
   bar, as the Add files bar and Android's bar under the list: 4 px round the 56 px button and
   a 1 px rule, 65 px, so with the tab bar 131.8 px at 100 percent text, 20 percent of Safari's
   393 by 659 window. While the two take what app.js barsFit allows (30 percent of an upright
   window at normal text, else a sixth), the bar stays fixed; otherwise app.js sets .loose and
   the bar sits after the form's last group. The status line takes a row of its own, above the button,
   only once it has words; empty, it takes no width, so it makes no row (the fifth finishing
   review: the empty line's row and the 12 px gap above the button made the bar 84 px, and it
   never pinned on a 390 by 844 window). At desk width, a card 1rem above the window's foot. */
.actionbar {
  position: sticky;
  bottom: var(--tabbar);
  z-index: 3;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 0.75rem;
  margin: 0 calc(-1 * var(--gutter));
  padding: 4px var(--gutter);
  background: var(--bg);
  border-top: 1px solid var(--hairline);
}
.actionbar .status { flex: 1 1 14rem; }
.actionbar .status:has(> span:empty) { flex-basis: 0; }
/* Two buttons on the confirm page (contract 2.5.5, 2026-10-02): Mark all on this page Finished,
   then Confirm. On a phone each takes the bar's width, Confirm under it, nearer the thumb, each
   on one line: side by side, Mark all's words took three lines and the bar grew past what 2.23
   lets a bar fixed on Safari's 393 by 659 window take, its button under the tab bar's top.
   Stacked, with the tab bar they take 29 percent of that window at normal text. At desk width
   side by side. A line with words takes a row of its own above them. */
.actionbar:has(#confirm-mark-all) { row-gap: 0.5rem; }
.actionbar .btn { flex: 1 1 100%; min-width: 0; }
.actionbar .btn.outline { min-height: 3rem; }
.actionbar .status:not(:has(> span:empty)) { flex-basis: 100%; }
/* Empty, the line keeps its place for a screen reader but makes no row: a row of its own, even
   empty, put a gap above the two buttons. */
.actionbar:has(#confirm-mark-all) .status:has(> span:empty) { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
@media (min-width: 900px) { .actionbar .btn { flex: 0 1 auto; } }
@media (min-width: 900px) {
  .actionbar {
    bottom: 1rem;
    margin: 0;
    padding: 0.75rem;
    border-top: 0;
    border-radius: 1.25rem;
    background: var(--surface);
    box-shadow: inset 0 0 0 1px var(--hairline), 0 0.375rem 1rem rgba(43, 26, 70, 0.12);
  }
}

/* htmx indicator styles, shipped here because includeIndicatorStyles is off under the CSP */
.htmx-indicator { opacity: 0; }
.htmx-request .htmx-indicator, .htmx-request.htmx-indicator { opacity: 1; transition: opacity 200ms ease-in; }
