/* Sections — the few rules that are ours rather than the system's, on every page.
 *
 * Keep this small. Anything that belongs to the system belongs in fw/, unchanged.
 *
 * Rewritten 1 Nov 2026. Removing the masthead band left three byte-identical copies of the Menu
 * block and two `@media (min-width: 768px) {` that were never closed, which swallowed the rules
 * below them: the bar's "you are here" marker had been applying above 768px only, so on a phone
 * nothing said which page you were on. Every block here opens and closes, and nothing is pasted
 * twice. check-config.py counts the braces now.
 */

/* The sub-navigation's anchors are two words each where the system's own are one, and nothing
   stopped a label breaking in half: the bar is 64px and its list was running to 71. site.js
   steps the bar down by measuring the right edge of the last item (.sub--nosrch, --early,
   --tight), and a label that wraps keeps that edge inside, so the measure never fired. With the
   labels whole it fires, which is the behaviour the system already has. */
@media (min-width: 1024px) {
  .sub-links a { white-space: nowrap; }
}

/* A page with a view bar: the bar that sticks is the views.
 *
 * Scrolled, the sub-navigation went fixed at the top and the view bar stuck underneath it, both
 * at 0, so the controls sat behind the page's own anchors. Fred: "nav that sticks should be the
 * views". Fellowship's works index has no sub-navigation at all for this reason; here the
 * anchors stay, in flow at the top of the page, and give the top of the window to the controls
 * once you are into the grid. works.css already puts the bar at 0 when the header steps away.
 */
/* (14 Nov 2026: the bar is now the top bar on every page, as on Fellowship's /works, and only steps away going down:
   html.stuck.hd-off below; so the view bar takes the top on the way down, as there) */
/* ...and the bar has to be ABOVE the header's background, or it sticks to the top of the window
   and nothing shows there. The header is transparent; what fills it is .gc, a sticky paper panel
   inside .gcaps, and .gcaps is z-index 47 against the bar's 40, so the controls were painted over
   by the header's own backdrop while still answering a click. Fred saw a blank white strip.
   48 is above .gcaps and below the sub-navigation (49) and the header (50), which is the right
   order for the top of the page, where the header is still showing. */
html.sx-viewbar .wx-bar { z-index: 48; }

/* The Menu word, level with the links beside it.
 *
 * .hd-nav a carries padding-block: 8px, so its words sit in the middle of the 44px row; .hd-menu
 * is a 44px box with its words at the top, and the two read as misaligned. Fred saw it before I
 * did. This centres the word in the same box rather than changing the box.
 */
.hd-menu, .sub-menu { display: flex; align-items: center; justify-content: flex-end; }

/* Fellowship's own sections, under this project's, inside the Menu sheet.
 *
 * They were a second .mn-nav, which the system does not expect: .mn-nav is `order: 3;
 * margin-top: auto`, so two of them are pushed into the same place and draw on top of each
 * other. One nav, and these sit after it in their own block.
 *
 * The three lengths are the system's own steps (--s-4, --s-5, --s-2). They were written as 16px,
 * 24px and 8px, which is the same thing until the scale moves, and round3's has moved once.
 */
.sx-mn-out { padding-top: var(--s-4); }
/* .mn-body is a flex column on a phone and a GRID from 1024 up, so `order` alone put this block
   in a middle column of its own, one word per line. It sits under the nav in both. */
@media (min-width: 1024px) { .sx-mn-out { grid-column: 1 / span 5; grid-row: 2; align-self: end; } }
@media (max-width: 1023px) { .sx-mn-out { order: 4; } }
.sx-mn-out ul { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap;
  gap: var(--s-5); }
.sx-mn-out a { display: inline-block; padding-block: var(--s-2); color: var(--ink-2);
  transition: color var(--t-text) var(--ease); }
.sx-mn-out a:hover { color: var(--ink); }

/* The sub-navigation sits right above the first module on these pages, and --gap-section left
   232px of nothing between them. That gap is for a module following a module, not a bar; Fred
   called it a big wide gap and he is right.
 */
.sub-wrap + .mod { margin-top: var(--gap-head); }

/* Where you are, in the bar.
 *
 * build-chrome.py writes class="on" AND aria-current="page" on the current item, and the system
 * styles .on — but fw/site.js's scroll-spy rewrites these links and the class does not survive
 * it, so every item rendered in the same grey and the bar said nothing about where you were.
 * aria-current is written by the generator and nothing takes it away, so that is what is styled.
 *
 * Tone, and nothing else. system.css:1082 marks .sub-links a.on with colour and says so in its
 * own comment — "the section in view by tone, as the header marks its page (no underline)". The
 * underline here was a fourth way of saying "chosen" on a site that already had three.
 */
.sub-links a[aria-current="page"] { color: var(--ink); }
/* ...and below 1024px there has to be something to be darker than. The system's whole .sub-links
   component — `color: var(--ink-2)` on the list, ink on the current item — lives inside
   `@media (min-width: 1024px)` (system.css:1081), because round3 hides the bar on a phone and
   navigates from the Menu. Our bar is four items and stays, so the same two tones are said again
   for the widths the system does not reach. */
@media (max-width: 1023px) {
  .sub-links { color: var(--ink-2); }
}

/* A tile that is a control rather than a link.
 *
 * system.css:654 zooms a picture on hover through `a:hover .fr > img`, scoped to anchors. The
 * collection's tiles are anchors and get it for nothing; the held works on /holdings are the
 * same .sx-cell.fr markup inside a div with role="button", because picking a default view is not
 * a navigation — so the identical tile sat still under the cursor in one place and moved in the
 * other. Same rule, said again for the button. */
.sx-cellw:hover .fr > img, .sx-cellw:focus-visible .fr > img {
  transform: scale(1.04);
  transition-duration: var(--t-zoom-in);
}

/* The credit line, one clause per line on a phone.
 *
 * "Grant Yun · 1,300 works · November 2026" is the line everyone reads before the drop, and as
 * one plain string it broke wherever the measure ran out — between 1,300 and works, or between
 * November and 2026. The system's exhibition pages wrap each clause in .nw (system.css:140,
 * already vendored) and drop the separators below 768px. Same here. */
.sx-dot { padding: 0 1px; }
/* (14 Nov 2026: one clause a line took four lines of a phone's first screen; the clauses now wrap as whole words on one
   or two lines, as Fellowship's own Sections page sets its line) */

/* The browser's own clear button on a search field: a blue circle with a cross, the only blue on
   the page, on all four search fields (census number or seed, census filter, Collection's go-to
   and trait finder). round3 removes it on its own search field, .srch-q (system.css:458); this is
   the same rule for every search field here. Escape still clears, and so does selecting the text. */
input[type="search"]::-webkit-search-cancel-button { -webkit-appearance: none; appearance: none; }

/* The size stepper on a phone. works.css hides `.wx-row--b > .wx-size` below 768px because round3
   moves it into its Filter sheet (.wx-size--f); the Collection here has no Filter sheet, so on a
   phone the grid had no size control at all. It stays in its row, which has room for it. */
@media (max-width: 767px) {
  html.sx-viewbar .wx-row--b > .wx-size { display: inline-flex; margin-left: auto; }
  html.sx-viewbar .sx-goto input { width: 5.5em; }
}

/* The sub-navigation, on the left.
 *
 * round3 sets its bar's links in columns 6 to 11 (system.css, .sub-links), the text column, and
 * on the pages it was made for that is where the eye already is: John Gerrard's opens on a hero
 * picture filling those columns, and the bar sits under it. These pages have no hero. The links
 * floated in the middle of the page under a title set on the left, joined to nothing (Fred: "the
 * current position is weird most of the time"). They start at the margin now, under the title
 * they belong to.
 *
 * And they stay there when the bar sticks. round3 brings "Fellowship | Sections" in on the left
 * at that moment; with the links on the left as well, they would have jumped 250px sideways to
 * make room. The stuck bar is the four links and Menu. Below 1024px none of this applies: the
 * system shows the brand and Menu there and the links live in the Menu sheet. */
/* Superseded 14 Nov 2026 (Fred: "sub nav always position the same, like .../works"): the bar is Fellowship's own
   Sections page's, the top bar from the first paint on every page, "Fellowship | Sections" on the left, the links where
   the system sets them (columns 6 to 11), Menu on the right; going down it steps away, going up it comes back. Their
   sections.css does it for the wall the same way: the row's wrapper fixed at the top with no height, so site.js finds it
   at 0 and holds the page "stuck" from the start. */
@media (min-width: 1024px) {
  #subw { position: fixed; top: 0; left: 0; right: 0; height: 0; margin: 0; z-index: 49; }
  .sub { transition: transform var(--t-ui) var(--ease); }
  html.stuck.hd-off .sub { transform: translateY(-100%); }
  /* A page Chrome had prerendered (speculation rules, on hovering a bar link) opened with the header's slide-away
     transition frozen at its first frame: the header sat over the bar, unseen behind nothing, and took the clicks
     meant for Explore and the rest (Fred, 14 Nov 2026: "explore page takes clicks to open"). With the bar on top
     from the first paint the header never has to slide: it is simply away, and lets clicks through. */
  html.stuck .hd { transition: none; }
  html.stuck .hd:not(:focus-within) { pointer-events: none; }
}
/* the census page has a .sub of its own (grey type) that greyed the whole bar; and with the bar always on top on a
   computer, a view bar's own Menu only repeats it */
#sub { color: var(--ink); }
@media (min-width: 1024px) { .sx-bar-menu { display: none; } }
@media (min-width: 1024px) and (prefers-reduced-motion: reduce) {
  .sub { transition: opacity 150ms linear; }
  html.stuck.hd-off .sub { transform: none; opacity: 0; pointer-events: none; }
}

/* ── a view bar that owns the top of the window carries its own Menu ───────────────────────────
 *
 * On Collection and Structures the page's views take the top once you are into the page, and the
 * sub-navigation steps aside (html.sx-viewbar, above). The header has gone too — round3's stuck
 * model hides it for as long as the bar is stuck — so scrolled down, neither page had a Menu
 * anywhere, and on a phone the menu is the navigation. round3's own bars end in Menu (John
 * Gerrard's, stuck: "Biography Works … Bibliography   Menu"). These do now, from the moment they
 * stick: at rest the header's Menu is on screen and a second one would only repeat it. */
.sx-bar-menu { margin-left: auto; justify-self: end; transition: opacity var(--t-ui) var(--ease); }
@starting-style { .sx-bar-menu { opacity: 0; } }
/* Out of the layout until then, not just invisible: holding its place left a 71px gap after the
   census search and Collection's size stepper, so neither met the right margin the panel and the
   grid below them keep. When the bar sticks it comes in where the header's Menu just was, and the
   search or the stepper moves over for it in the same moment the header leaves. */
html:not(.stuck) .sx-bar-menu { display: none; }

/* Collection's bar on a phone. works.css stacks every control group full width, one to a line,
   because round3 shows them inside its Filter sheet on a phone (.wx-bar.sheet). This bar has no
   sheet: it showed the sheet's layout in the page, 208px stuck at the top — a quarter of the
   screen. Angles and Night share a line, Trait and Menu the next. */
@media (max-width: 1023px) {
  html.sx-viewbar .wx-row--a { display: flex; flex-wrap: wrap; align-items: center;
    column-gap: var(--s-5); row-gap: 0; }
  html.sx-viewbar .wx-row--a > .wx-grp { width: auto; margin-bottom: 0; }
  html.sx-viewbar .wx-row--a > .wx-dds { width: auto; }
}
/* Collection's Menu has two homes because its bar has two layouts (works.css:132): stacked below
   1024px, where it ends the first group, and a single row from 1024, where it ends the bar, past
   the size stepper. One is shown at a time. */
.sx-bar-menu--row { display: none; }
@media (min-width: 1024px) {
  .sx-bar-menu--stack { display: none; }
  .sx-bar-menu--row { display: flex; }
}

/* The footer's line is one sentence ending in its links: "Sections by Grant Yun · published by Fellowship". The
   system's phone rule lifts .ft-legal's links onto a line of their own above the copyright (system.css, .ft-legal a
   { order: -1 }), which put "Fellowship" in front of "published by". It stays one sentence on a phone. */
@media (max-width: 767px) {
  .ft-legal { display: block; }
  .ft-legal a { order: 0; margin-right: 0; }
}

/* Your works, in the bar for the team only (build-chrome ADMIN_JS): a reader sees it greyed and cannot follow it */
/* Your works, grey until the sale opens (ADMIN_JS adds is-open), but a link: its page says when */
.sx-team:not(.is-open) a:not([aria-current]) { opacity: .4; }

/* The footer of Fellowship's own Sections page (14 Nov 2026, "match theirs"): Contact from the margin, Follow at column 6,
   as their sections.css sets it */
@media (min-width: 1024px) { .ft-g .ft-contact { grid-column: 1 / span 5; } .ft-g .ft-follow { grid-column: 6 / span 3; } }

/* A live drawing on a touch screen (js/shield.js): the clear layer that lets the page scroll, its tip, and Done */
.sx-shield { position: absolute; inset: 0; z-index: 6; margin: 0; padding: 0; border: 0; background: transparent;
  touch-action: pan-y pinch-zoom; -webkit-tap-highlight-color: transparent; cursor: pointer; }
.sx-shield[hidden], .sx-shield-done[hidden] { display: none; }
.sx-shield-tip { position: absolute; left: 50%; bottom: 12px; transform: translateX(-50%); white-space: nowrap;
  font: inherit; font-size: var(--t-meta-size); line-height: 1; color: var(--paper); background: rgb(25 25 25 / 0.72);
  padding: 8px 12px; border-radius: 999px; pointer-events: none; }
.sx-shield-done { position: absolute; top: 10px; right: 10px; z-index: 7; font: inherit; font-size: var(--t-meta-size);
  line-height: 1; color: var(--paper); background: var(--ink); border: 0; border-radius: 999px; padding: 10px 14px; }
/* the words that only a keyboard and mouse can follow, and their touch twin */
.sx-tch { display: none; }
@media (pointer: coarse) { .sx-kb { display: none; } .sx-tch { display: inline; } }
/* Explore's key list means nothing to a finger; the drawing's own tip says what to do */
@media (pointer: coarse) { .explore .hint { display: none; } }
/* the plat and the grids set touch-action: none on the stage itself, and a child cannot ask for more than its parent */
@media (pointer: coarse) { [data-shielded]:not(.sx-live) { touch-action: pan-y pinch-zoom !important; } }

/* "← Sections" above each page's name, as on Fellowship's own wall (their sections.css .sx-back) */
.intro-t .sx-back { margin: 0 0 var(--s-4); }
.intro-t .sx-back .alink { color: var(--ink-2); }

/* ── Explore (the census) in the house style (14 Nov 2026, Fred: "take the lead ... respecting the design installed by the
   new version"). The census was drawn as its own app: rounded cards, grey pills, shadows, uppercase labels and its own
   palette. Here it takes the system's: paper and band, ink and ink-2, hairlines, square corners, sentence-case meta. Its
   category colours stay: they are the data's. html:has(.explore) outranks the census's own :root and class rules. */
html:has(.explore) {
  --bg: var(--paper); --bg2: var(--band); --bg3: var(--paper); --ink2: var(--ink-2); --sub: var(--ink-2); --sub2: var(--ink-2);
  --line: var(--hair); --line2: var(--hair); --track: var(--hair); --blue: var(--ink); --blue-ink: var(--ink);
  --shadow: none; --r: 0;
}
html:has(.explore) .stage, html:has(.explore) .card, html:has(.explore) .panel2, html:has(.explore) .tblwrap,
html:has(.explore) .th, html:has(.explore) .lead .th, html:has(.explore) td .th, html:has(.explore) .label,
html:has(.explore) .survey, html:has(.explore) .survey button, html:has(.explore) .pinchip { border-radius: 0; box-shadow: none; }
html:has(.explore) .stage { background: var(--paper); outline: 1px solid var(--hair); outline-offset: -1px; }
html:has(.explore) .stage iframe { background: var(--paper); }
html:has(.explore) .cap, html:has(.explore) .attr .k { text-transform: none; letter-spacing: 0; font-weight: 400; color: var(--ink-2); }
html:has(.explore) .sec h2, html:has(.explore) .card h3, html:has(.explore) .row .no, html:has(.explore) .stats3 b,
html:has(.explore) .head h1, html:has(.explore) .wrap > h1, html:has(.explore) .about h1, html:has(.explore) .about h3 { font-weight: 400; letter-spacing: 0; }
/* fields: the system's underline, not a grey pill */
html:has(.explore) .select, html:has(.explore) .search input, html:has(.explore) .tools2 input {
  border-radius: 0; background-color: transparent; border-bottom: 1px solid var(--field-line); }
/* buttons: hairline boxes; the one dark one stays dark */
html:has(.explore) .mini { background: none; border-radius: 0; padding: 0; gap: 0; }
html:has(.explore) .pinall,
html:has(.explore) .metricbar button { border-radius: 0; box-shadow: none; background: none; border: 1px solid var(--hair); font-weight: 400; }
/* Most / Least: words, as the tabs above them, the current one ink and underlined */
html:has(.explore) .mini button { border: 0; background: none; box-shadow: none; border-radius: 0; padding: 4px 6px; color: var(--ink-2); }
html:has(.explore) .mini button[aria-pressed="true"] { color: var(--ink); text-decoration: underline; text-underline-offset: 4px; background: none; box-shadow: none; }
html:has(.explore) .shuffle { border-radius: 0; }
html:has(.explore) .round { border-radius: 0; background: none; border: 1px solid var(--hair); }
html:has(.explore) .chip, html:has(.explore) .chip button, html:has(.explore) .catpin, html:has(.explore) .pinchip .x { border-radius: 0; }
html:has(.explore) .row[aria-current="true"], html:has(.explore) .kr[aria-pressed="true"] { background: var(--band); }
html:has(.explore) .srow { border-radius: 0; }
html:has(.explore) .srow[aria-pressed="true"] { background: var(--band); }
html:has(.explore) .attr .bar, html:has(.explore) .attr .bar i { border-radius: 0; }
html:has(.explore) :focus-visible { outline-color: var(--focus); border-radius: 0; }
html:has(.explore) body::before { background: rgb(249 248 244 / 0.85); }
