Files
jobboard/app/static/app.css
T
WolfandClaude 4ae5e845ee Push filters onto the history, link company names to their roles, and star a company from the feed
A filter set in the rail is now a history entry, so back takes it off;
the search box and typed fields replace, and the agent and order replace
and are left alone by back and forward. popstate reads the address into
the filter and reloads. Each pushed entry carries the address under it,
which replaces pushedReader, so closing the reader and taking a company
off are history.back() only when the entry under is that list.

A company's name in a row and in the reader links to ?company_keys=,
keeping agent and order; a plain click filters in place and pushes. With
one company filtered, a strip over the feed names it, counts its roles,
links its careers page and carries its affinity control, and reloads the
feed once the score it queued has run. On a phone the name takes taps
from a band around it without making the row taller, and with a filter
on the header no longer runs past 390px.

Co-Authored-By: Claude <noreply@anthropic.com>
2026-09-29 22:08:04 +02:00

1407 lines
58 KiB
CSS
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
/* The whole stylesheet: the boilerplate's, with roledesk's palette in the
* custom properties (a quiet UI face and newsdesk's teal signal colour), the
* frame (a top bar of three tabs and a cog, the settings rail), roledesk's
* own pages, and at the bottom the phone: a width query for the layout and a
* pointer query for the sizes, after newsdesk and health. No build step.
*
* The `--desk-jobs-*` block is how `<desk-jobs>`, `<desk-schedules>`,
* `<desk-queue>` and `<auth-account>` are themed. Each keeps to a shadow
* root and reads those properties, so an app skins it without forking it --
* which is the deal that lets the queue ship its own UI and still look like
* it belongs here -- and the app cannot lay it out beyond that.
*/
:root {
color-scheme: light dark;
--bg: #eceff1;
--panel: #ffffff;
--fg: #1a2027;
--dim: #505c67;
--line: #d6dbdf;
--accent: #14655b;
--accent-fg: #ffffff;
--good: #15803d;
--warn: #b45309;
--error: #b91c1c;
--faint: #6d7883;
--accent-weak: #a9c4bf;
/* How tall the header is, and every sticky offset on the Roles page is
measured from it: the rail, the reader, the scrim. static/roles.js
measures the header and writes the answer here; this is only the value
before the first measurement lands. */
--chrome: 3.4rem;
--radius: 10px;
--gap: 1rem;
--font: "Segoe UI Variable Text", "Segoe UI", system-ui, -apple-system, Roboto,
"Helvetica Neue", Arial, sans-serif;
--mono: ui-monospace, "Cascadia Mono", Consolas, monospace;
/* newsdesk's second face: what is read -- a title, an excerpt, a posting --
runs in a serif with a big x-height, which is what makes a wall of text
scannable; the chrome stays in the UI face. */
--read: Charter, "Bitstream Charter", "Iowan Old Style", "Source Serif 4",
Georgia, Cambria, "Palatino Linotype", serif;
}
@media (prefers-color-scheme: dark) {
:root {
--bg: #14181c;
--panel: #1b2126;
--fg: #e3e7ea;
--dim: #a8b2ba;
--faint: #8b959d;
--line: #2a3238;
--accent: #4fb3a3;
--accent-fg: #14181c;
--accent-weak: #35544f;
--good: #4ade80;
--warn: #fbbf24;
--error: #f87171;
}
}
* { box-sizing: border-box; }
/* `hidden` has to win over any class that sets `display`, such as `.check`. */
[hidden] { display: none !important; }
body {
margin: 0;
background: var(--bg);
color: var(--fg);
font: 16px/1.55 var(--font);
}
code, pre { font-family: var(--mono); font-size: 0.9em; }
pre { overflow-x: auto; white-space: pre-wrap; word-break: break-word; }
a { color: var(--accent); }
/* -- the frame ------------------------------------------------------------ */
.top {
display: flex;
align-items: center;
gap: var(--gap);
flex-wrap: wrap;
padding: 0.75rem 1.25rem;
/* Standalone on a phone with a notch: the bar clears the status area. */
padding-top: calc(0.75rem + env(safe-area-inset-top));
background: var(--panel);
border-bottom: 1px solid var(--line);
position: sticky;
top: 0;
z-index: 5;
}
.brand span { color: var(--accent); }
.brand {
font-weight: 700;
letter-spacing: 0.02em;
text-decoration: none;
color: var(--fg);
}
.top nav { display: flex; gap: 0.25rem; flex-wrap: wrap; align-items: center; }
.top nav a {
padding: 0.35rem 0.7rem;
border-radius: var(--radius);
text-decoration: none;
color: var(--dim);
}
/* The cog: an SVG, centred in a box the height of a word. */
.top nav a.icon { display: inline-flex; align-items: center; padding-block: 0.45rem; }
/* Hover needs a pointer to hover with, and a phone has none: it fakes one on
the element last touched and leaves it there, so a tapped tab would keep a
tint it has no reason to have (newsdesk's app.css says the same). Every
`:hover` in this file is inside one of these. */
@media (hover: hover) {
.top nav a:hover { background: color-mix(in srgb, var(--accent) 12%, transparent); }
}
.top nav a.active { background: var(--accent); color: var(--accent-fg); }
/* == settings shell ======================================================= */
/* The rail beside every page under the cog (settings/_rail.html), in the
Roles rail's look: a small-caps heading, quiet rows, the current one tinted
with a bar down its edge. Rules of its own rather than `#rail`'s, because
that rail turns into an overlay when narrow and this one into a strip.
Sticky under the header, with its own scroll if it outgrows the screen, so
it stays beside a Company boards list sixty companies long. */
.settings-shell {
display: grid;
grid-template-columns: 13rem minmax(0, 1fr);
gap: 1.6rem;
max-width: 76rem; margin: 0 auto; padding: 0 1.1rem;
}
.settings-shell > main {
max-width: none; min-width: 0; margin: 0;
padding: 1.5rem 0 calc(4rem + env(safe-area-inset-bottom));
}
.settings-rail {
position: sticky; top: var(--chrome); align-self: start;
max-height: calc(100vh - var(--chrome)); overflow-y: auto;
padding: 1.75rem 0 2rem;
}
.settings-rail h3 {
margin: 0 0 .45rem; padding: 0 .5rem;
font-size: .76rem; font-weight: 650; letter-spacing: .06em;
text-transform: uppercase; color: var(--faint);
}
.settings-rail nav, .rail-group { display: flex; flex-direction: column; gap: .1rem; }
.rail-link {
display: block; padding: .3rem .5rem; border-radius: 3px;
font-size: .9rem; color: var(--dim); text-decoration: none;
white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
/* A page's sections, indented under it. */
.rail-link.sub { padding-left: 1.5rem; font-size: .86rem; }
@media (hover: hover) {
.rail-link:hover { color: var(--fg); background: var(--panel); }
}
/* The current page, or on Sources the current section. The page a section
is on is only named in the accent, so one row at a time has the bar. */
.rail-link[aria-current] {
background: color-mix(in srgb, var(--accent) 14%, transparent);
color: var(--accent); font-weight: 600;
box-shadow: inset 3px 0 0 var(--accent);
}
.rail-link.parent[aria-current] { background: none; box-shadow: none; }
/* A section landed on by its fragment clears the header. */
section[id] { scroll-margin-top: calc(var(--chrome) + .5rem); }
.card h3 { font-size: 1rem; margin: 1.25rem 0 .5rem; }
/* Narrow: one column, and the rail is a strip of chips across the top of the
content, pinned under the header and scrolled sideways, so a phone jumps
between sections without scrolling back up. Only the current page's
sections are in it, after a › on their page. */
@media (max-width: 60rem) {
.settings-shell { display: block; padding: 0; }
.settings-shell > main { padding-inline: 1.1rem; }
.settings-rail {
top: var(--chrome); z-index: 4;
max-height: none; overflow: auto hidden;
padding: .4rem .6rem;
background: var(--panel); border-bottom: 1px solid var(--line);
scrollbar-width: none;
}
.settings-rail::-webkit-scrollbar { display: none; }
.settings-rail h3 { display: none; }
.settings-rail nav { flex-direction: row; gap: .25rem; width: max-content; }
.rail-group { display: contents; }
.rail-group:not([data-current]) .sub { display: none; }
.rail-link, .rail-link.sub { padding: .3rem .75rem; border-radius: 999px; overflow: visible; }
.rail-link[aria-current] { box-shadow: none; }
.rail-link.parent[aria-current]::after { content: " ›"; color: var(--faint); }
section[id] { scroll-margin-top: calc(var(--chrome) + 3.25rem); }
}
@media (max-width: 640px) {
.settings-shell > main { padding: 10px 10px calc(3rem + env(safe-area-inset-bottom)); }
}
@media (pointer: coarse) {
.rail-link { display: inline-flex; align-items: center; min-height: 2.75rem; }
}
/* == end of settings shell ================================================ */
main {
max-width: 62rem;
margin: 0 auto;
padding: 1.5rem 1.25rem 4rem;
padding-bottom: calc(4rem + env(safe-area-inset-bottom));
}
h1 { font-size: 1.6rem; margin: 0 0 0.5rem; }
h2 { font-size: 1.1rem; margin: 0 0 0.75rem; }
.lede { color: var(--dim); max-width: 46rem; }
.muted { color: var(--dim); }
.small { font-size: 0.85rem; }
.note {
background: color-mix(in srgb, var(--accent) 8%, var(--panel));
border: 1px solid color-mix(in srgb, var(--accent) 35%, var(--line));
border-radius: var(--radius);
padding: 0.9rem 1rem;
max-width: 46rem;
}
.card {
background: var(--panel);
border: 1px solid var(--line);
border-radius: var(--radius);
padding: 1rem 1.15rem;
margin: 1.25rem 0;
}
.row-between {
display: flex;
align-items: baseline;
justify-content: space-between;
gap: var(--gap);
}
.summary { display: grid; grid-template-columns: max-content 1fr; gap: 0.4rem 1rem; margin: 0; }
.summary dt { color: var(--dim); }
.summary dd { margin: 0; }
.buttons { display: flex; flex-wrap: wrap; gap: 0.5rem; }
button {
font: inherit;
padding: 0.4rem 0.9rem;
border-radius: var(--radius);
border: 1px solid transparent;
background: var(--accent);
color: var(--accent-fg);
cursor: pointer;
}
button:disabled { opacity: 0.55; cursor: progress; }
button.secondary {
background: transparent;
color: var(--fg);
border-color: var(--line);
}
.badge {
display: inline-block;
padding: 0 0.4rem;
border-radius: 999px;
background: var(--line);
color: var(--dim);
font-size: 0.8rem;
}
/* -- the notice log ------------------------------------------------------- */
.notice {
border: 1px solid var(--line);
border-left: 3px solid var(--dim);
border-radius: var(--radius);
padding: 0.6rem 0.8rem;
margin: 0.5rem 0;
}
.notice.error { border-left-color: var(--error); }
.notice.warning { border-left-color: var(--warn); }
.notice.good { border-left-color: var(--good); }
.notice-head { display: flex; justify-content: space-between; gap: var(--gap); align-items: start; }
.notice-text { font-weight: 600; }
/* -- toasts --------------------------------------------------------------- */
.toasts {
position: fixed;
right: 1rem;
bottom: 1rem;
width: min(26rem, calc(100vw - 2rem));
display: flex;
flex-direction: column;
gap: 0.5rem;
/* A popover brings its own box; this is a container, not a card. */
border: 0;
background: transparent;
padding: 0;
margin: 0;
inset: auto 1rem 1rem auto;
}
.toast {
display: flex;
gap: 0.5rem;
align-items: start;
background: var(--panel);
color: var(--fg);
border: 1px solid var(--line);
border-left: 3px solid var(--dim);
border-radius: var(--radius);
padding: 0.6rem 0.75rem;
box-shadow: 0 8px 24px rgb(0 0 0 / 18%);
animation: toast-in 160ms ease-out;
}
.toast.error { border-left-color: var(--error); }
.toast.warning { border-left-color: var(--warn); }
.toast.good { border-left-color: var(--good); }
.toast.out { opacity: 0; transition: opacity 180ms ease-in; }
.toast-body { flex: 1; min-width: 0; }
.toast-count { color: var(--dim); }
.toast-fix { color: var(--dim); }
.toast-actions { display: flex; gap: 0.5rem; align-items: center; }
.toast-actions:empty { display: none; }
.toast-close {
background: transparent;
color: var(--dim);
border: 0;
padding: 0 0.25rem;
line-height: 1;
}
@keyframes toast-in {
from { transform: translateY(6px); opacity: 0; }
to { transform: none; opacity: 1; }
}
/* -- the modules' elements ------------------------------------------------ */
/* `<desk-jobs>`, `<desk-schedules>` and the top bar's `<desk-queue>` from the
* queue, `<auth-account>` from auth: all four read these, so they look like
* one application and none of them is forked to get it. An element the app
* has not got yet simply matches nothing. */
desk-jobs, desk-schedules, desk-queue, auth-account {
display: block;
--desk-jobs-bg: var(--panel);
--desk-jobs-fg: var(--fg);
--desk-jobs-dim: var(--dim);
--desk-jobs-accent: var(--accent);
--desk-jobs-error: var(--error);
--desk-jobs-font: var(--font);
--desk-jobs-gap: var(--gap);
--desk-jobs-radius: var(--radius);
}
/* -- roledesk's tabs ------------------------------------------------------ */
/* Roles, Applications, Agents and Companies, drawn by static/roles.js. */
input, select, textarea { font: inherit; color: inherit; min-width: 0; max-width: 100%; }
.filters {
display: flex; flex-wrap: wrap; gap: .5rem; align-items: center;
padding: .75rem; margin-bottom: .5rem;
background: var(--panel);
border: 1px solid var(--line); border-radius: var(--radius);
}
.filters input[type="search"], .filters input[type="text"], .filters select {
padding: .4rem .55rem;
border: 1px solid var(--line); border-radius: .3rem;
background: var(--bg); min-width: 0;
}
.filters input[type="search"] { flex: 1 1 12rem; }
.filters input[type="text"] { flex: 1 1 8rem; }
.check {
display: flex; align-items: center; gap: .35rem;
color: var(--dim); font-size: .9rem; white-space: nowrap;
}
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible,
textarea:focus-visible {
outline: 2px solid var(--accent); outline-offset: 1px;
}
.count { color: var(--dim); font-size: .85rem; margin: .75rem 0 .5rem; }
/* == roles: the rail, the feed and the reader ============================ */
/* newsdesk's feed and reader (`newsdesk/web/static/app.css` in ../news),
* ported with its comments: the shell grid, the rail, the `.row` with its
* score gutter, the reader as a third column, and at the end of this section
* the phone and touch rules for all of it. newsdesk's names for the colours
* map onto this file's: `--ink` is `--fg`, `--muted` is `--dim`, `--rule` is
* `--line`, `--signal` is `--accent`, `--down` is `--error`. Drawn by
* static/roles.js and static/judge.js. */
/* -- the header, on the Roles page -- */
/* The tabs and the cog sit at the right on every page, where newsdesk keeps
its own controls, so they do not move when the Roles page puts its burger
and search box between them and the brand. */
.top nav { margin-left: auto; }
#search {
flex: 0 1 22rem; min-width: 12rem;
font: inherit; font-size: .88rem;
padding: .3rem .55rem;
color: var(--fg); background: var(--bg);
border: 1px solid var(--line); border-radius: 3px;
}
/* With the rail shut and the pill row gone -- which is every narrow screen --
this button is the only thing left that can say a filter is on. So it says
how many, in words.
It was a number in a filled circle, which is the badge every application
uses for unread mail: it reads as "two new things" on the one control that
means two things are being left out. "2 filters" cannot be read the wrong
way round, and it costs four characters on the narrowest screen there is. */
#rail-toggle {
display: inline-flex; align-items: center; gap: .4em;
padding: .3rem .6rem; font-size: .88rem;
color: var(--dim); background: none;
border: 1px solid transparent; border-radius: 3px;
}
@media (hover: hover) {
#rail-toggle:hover { color: var(--fg); background: var(--bg); }
}
.rail-toggle-label { white-space: nowrap; }
#rail-toggle[aria-label*="filter"] .rail-toggle-label {
color: var(--accent); font-weight: 600;
}
/* Three lines, drawn rather than typed: the hamburger is the one glyph a
phone user does not have to read to recognise, and at this size an emoji
or a box-drawing character lands differently in every font. */
.burger {
display: block; position: relative;
width: 1em; height: 2px; background: currentColor; border-radius: 2px;
}
.burger::before, .burger::after {
content: ''; position: absolute; left: 0;
width: 100%; height: 2px; background: currentColor; border-radius: 2px;
}
.burger::before { top: -5px; }
.burger::after { top: 5px; }
/* Behind the rail when the rail is an overlay, never otherwise. Dimming
`main` said "this is in front of that" but left the feed holding the tap
that means "put it away"; a scrim does both jobs. */
#scrim {
display: none;
position: fixed; inset: var(--chrome) 0 0 0; z-index: 8;
background: color-mix(in srgb, var(--fg) 36%, transparent);
}
/* -- the shell -- */
/* Two columns: a filter rail that collapses to nothing, and the feed. */
.shell {
display: grid;
grid-template-columns: 15rem minmax(0, 1fr);
gap: 1.6rem;
max-width: 76rem; margin: 0 auto; padding: 0 1.1rem;
}
/* One column when the rail is hidden -- not a zero-width first column, which
would leave `main` sitting in it once the aside stops being a grid item. */
body[data-rail="shut"] .shell { grid-template-columns: minmax(0, 1fr); gap: 0; }
body[data-rail="shut"] #rail { display: none; }
/* Reading opens a third column and the shell goes full width: the list keeps
a narrow lane on the left, the role takes the rest. */
body[data-reader="open"] .shell {
grid-template-columns: 15rem 29rem minmax(0, 1fr);
max-width: none; gap: 1.2rem;
}
body[data-reader="open"][data-rail="shut"] .shell {
grid-template-columns: 29rem minmax(0, 1fr);
}
/* -- the rail -- */
#rail {
position: sticky; top: var(--chrome); align-self: start;
max-height: calc(100vh - var(--chrome)); overflow-y: auto;
padding: 1rem 0 3rem;
}
#rail section + section { margin-top: 1.4rem; }
#rail h3 {
display: flex; align-items: baseline; justify-content: space-between;
margin: 0 0 .45rem; padding: 0 .3rem;
font-size: .76rem; font-weight: 650; letter-spacing: .06em;
text-transform: uppercase; color: var(--faint);
}
/* The rail's buttons are quiet: every one of them is a filter, and filters
are quiet by definition. */
#rail button:not(.linky) {
font: inherit; font-size: .88rem;
color: var(--dim); background: none;
border: 1px solid transparent; border-radius: 3px;
padding: .28rem .6rem;
}
@media (hover: hover) {
#rail button:not(.linky):hover { color: var(--fg); background: var(--panel); }
}
#rail .count { color: var(--faint); font-size: .8rem; margin: 0 0 0 .3em; }
.rail-row {
display: flex; align-items: baseline; gap: .35rem;
width: 100%; text-align: left;
}
#rail .rail-row { padding: .26rem .4rem; }
.rail-row > span:nth-last-child(2) { flex: 1; min-width: 0;
overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rail-row .count { margin-left: auto; white-space: nowrap; }
/* Tinted with the accent rather than `--bg`: on desktop the rail sits on `--bg`,
so a selected row in that colour was invisible. */
#rail .rail-row[aria-pressed="true"] {
background: color-mix(in srgb, var(--accent) 14%, transparent);
color: var(--accent); font-weight: 600;
box-shadow: inset 3px 0 0 var(--accent);
}
.rail-row[aria-pressed="true"] .count { color: var(--accent); }
/* Tags are chips, not rows: they're multi-select, and seeing them wrap into a
block makes the "pick two" affordance obvious. */
#tags { display: flex; flex-wrap: wrap; gap: .25rem; padding: 0 .3rem; }
.tag, #rail .tag {
font: inherit; cursor: pointer;
color: var(--dim); background: none;
border: 1px solid var(--line); border-radius: 999px;
padding: .14rem .6rem; font-size: .82rem;
}
.tag[aria-pressed="true"], #rail .tag[aria-pressed="true"] {
color: var(--panel); background: var(--accent); border-color: var(--accent);
}
#rail .tag[aria-pressed="true"] .count { color: var(--accent-weak); }
.tag.mini {
padding: 0 .42rem; font-size: .76rem; line-height: 1.5;
color: var(--faint); border-color: var(--line);
}
.tag.mini[aria-pressed="true"] { color: var(--panel); }
.rail-note {
margin: .6rem .3rem 0; font-size: .8rem; color: var(--faint);
line-height: 1.45;
}
.rail-stats {
margin: 1.4rem 0 0; padding: .7rem .3rem 0; border-top: 1px solid var(--line);
font-size: .8rem; color: var(--faint); font-variant-numeric: tabular-nums;
}
.rail-keys {
margin: .6rem .3rem 0; font-size: .74rem; line-height: 1.9; color: var(--faint);
}
kbd {
font: inherit; font-size: .74rem;
border: 1px solid var(--line); border-bottom-width: 2px;
border-radius: 3px; padding: 0 .3em; margin-right: .1em; color: var(--dim);
}
/* Order, and the period under it. `.seg` is a block on its own here and the
two halves split the width, so the choice is one target each rather than
two words pushed against the edge. */
.seg { display: flex; }
#sort { padding: 0 .3rem; }
#rail .seg button {
flex: 1; text-align: center;
font-size: .8rem; padding: .18rem .55rem;
border: 1px solid var(--line);
}
/* Square everything first; only the ends are ends. Every cell but the first
eats its neighbour's border, so the joins are one rule wide rather than two. */
.seg > * { border-radius: 0; }
#rail .seg > :first-child { border-radius: 3px 0 0 3px; }
#rail .seg > :last-child { border-radius: 0 3px 3px 0; }
.seg > :not(:first-child) { margin-left: -1px; }
#rail .seg button[aria-pressed="true"] {
color: var(--panel); background: var(--accent); border-color: var(--accent);
}
/* Still pressable, so the title can be found; greyed, since it does nothing. */
#rail .seg [aria-disabled="true"] { cursor: default; opacity: .55; }
.rail-field {
display: block; margin: .7rem .3rem .25rem;
font-size: .78rem; color: var(--faint);
}
/* Sized by `min-height`, never by padding around one line. Chrome draws a
select's text at `line-height: normal` whatever the stylesheet says and
clips it to the content box, so a select that was padding around one line
box cut off the "g" wherever the face's glyphs reach below its own line
metrics, as Segoe UI Variable's do on Windows. A box taller than the line,
with the text centred in it, has room under the baseline in any face and
at any zoom. The text fields are set the same way so the column lines up. */
.rail-select, .rail-fields input[type="text"], .rail-fields select {
width: calc(100% - .6rem); margin: 0 .3rem;
min-height: 2rem; padding: .15rem .45rem;
font-size: .84rem; line-height: normal;
border: 1px solid var(--line); border-radius: 3px;
background: var(--panel); color: var(--fg);
}
/* Viewing as: the first thing in the rail, since it decides whose answer
every other control gets. The agent's name in the bold face, larger than
the filters, the full width, and ruled off from them. */
#rail .rail-viewing { padding-bottom: 1rem; border-bottom: 1px solid var(--line); }
#rail .agent-pick {
display: block; width: calc(100% - .6rem); margin: 0 .3rem;
font-size: 1rem; font-weight: 650; color: var(--fg);
}
#rail select.agent-pick {
min-height: 2.6rem; padding: .2rem .5rem;
border-color: color-mix(in srgb, var(--accent) 55%, var(--line));
}
.rail-viewing .rail-note { margin-top: 0; }
/* A link in a heading ("agents", "clear") is a word, not a second heading. */
#rail h3 .linky { text-transform: none; letter-spacing: 0; font-weight: 400; }
/* The filters that are not the everyday ones: folded, with a count on the
summary so a closed fold still says the list is narrowed. */
.rail-more > summary {
cursor: pointer; list-style: none;
padding: 0 .3rem;
font-size: .76rem; font-weight: 650; letter-spacing: .06em;
text-transform: uppercase; color: var(--faint);
}
.rail-more > summary::-webkit-details-marker { display: none; }
.rail-more > summary::before { content: "▸ "; }
.rail-more[open] > summary::before { content: "▾ "; }
@media (hover: hover) {
.rail-more > summary:hover { color: var(--fg); }
}
.filter-active { color: var(--accent); }
.rail-fields { display: flex; flex-direction: column; gap: .45rem; padding-top: .6rem; }
.rail-fields input[type="text"], .rail-fields select { width: auto; }
.rail-fields .check { padding: 0 .3rem; white-space: normal; }
/* -- the feed -- */
.shell > #list {
max-width: none; margin: 0; min-width: 0;
padding: 0 0 calc(5rem + env(safe-area-inset-bottom));
}
/* Reading mode: the list becomes a compact index. Score, excerpt and vote
buttons all go -- the buttons because they now live in the reader bar, next
to the text being judged. */
body[data-reader="open"] #list {
position: sticky; top: var(--chrome); align-self: start;
max-height: calc(100vh - var(--chrome)); overflow-y: auto;
padding: 0 .2rem 1rem 0;
}
body[data-reader="open"] .row { grid-template-columns: 3px minmax(0, 1fr); gap: .6rem; }
body[data-reader="open"] #list[data-sort="time"] .row { grid-template-columns: minmax(0, 1fr); }
body[data-reader="open"] .score,
body[data-reader="open"] .excerpt,
body[data-reader="open"] .actions,
body[data-reader="open"] .row .tag { display: none; }
body[data-reader="open"] .headline { font-size: .96rem; }
body[data-reader="open"] .row[data-open="true"] {
background: color-mix(in srgb, var(--accent) 10%, transparent);
}
.row {
display: grid;
grid-template-columns: 4px 2.6rem minmax(0, 1fr) auto;
align-items: start; gap: .85rem;
padding: .8rem 0 .85rem;
border-bottom: 1px solid var(--line);
/* So j/k never scrolls the selected row under the sticky header. */
scroll-margin-top: calc(var(--chrome) + .5rem);
}
.row[data-current="true"] { background: color-mix(in srgb, var(--accent) 7%, transparent); }
/* A vote is not a state of the role. The vote belongs on the button that took
it, and that is the only place it is shown; a pass dims the text instead,
below, since a passed role is one you meant to leave behind. */
/* The signature element: a gutter bar sized by the ranking's score. */
.gutter {
align-self: stretch; min-height: 1.9rem;
background: var(--line); border-radius: 1px;
position: relative; overflow: hidden;
}
.gutter i {
position: absolute; inset: auto 0 0 0;
background: var(--accent);
display: block;
}
.score {
font-size: .82rem; color: var(--dim);
padding-top: .2rem; text-align: right;
font-variant-numeric: tabular-nums;
}
/* Newest first hides the score, because in that order it is not what put the
row where it is. Done here rather than in the row template so the markup is
the same either way and only the stylesheet knows about the order -- the
gutter goes with it, since a bar with no number beside it is a measurement
of nothing. The columns go with them, or the text would land in the
gutter's 4px. */
#list[data-sort="time"] .gutter,
#list[data-sort="time"] .score { display: none; }
#list[data-sort="time"] .row { grid-template-columns: minmax(0, 1fr) auto; }
.body { min-width: 0; }
.headline {
font-family: var(--read);
color: var(--fg); text-decoration: none;
font-size: 1.12rem; font-weight: 500; line-height: 1.4;
display: block; max-width: 60ch;
overflow-wrap: anywhere;
}
@media (hover: hover) {
.headline:hover { text-decoration: underline; text-underline-offset: 2px; }
}
.row[data-read="true"] .headline { color: var(--dim); }
.meta, .reader-meta {
margin-top: .28rem;
font-size: .82rem; color: var(--faint);
display: flex; gap: .2rem .55rem; flex-wrap: wrap; align-items: baseline;
}
/* The company is the second thing you read after the title -- it is how you
decide whether to read on. It gets weight and full ink, not grey. */
.meta b { font-weight: 650; color: var(--fg); }
/* The company's name is also a link to its roles (roles.js `companyName`),
and still reads as the name: same weight and ink, underlined only under
a pointer. */
.meta .company { font-weight: 650; color: var(--fg); text-decoration: none; }
@media (hover: hover) {
.meta .company:hover, .reader-meta .company:hover {
text-decoration: underline; text-underline-offset: 2px;
}
}
.meta .badge, .reader-meta .badge {
background: none; color: var(--dim);
border: 1px solid var(--line); border-radius: 999px;
padding: 0 .45rem; font-size: .76rem; line-height: 1.5;
}
.meta .badge.closed, .reader-meta .badge.closed { color: var(--error); border-color: var(--error); }
.meta .gated { color: var(--error); }
.excerpt {
font-family: var(--read);
margin: .4rem 0 0; max-width: 68ch;
font-size: .95rem; line-height: 1.55; color: var(--dim);
}
.actions { display: flex; gap: .15rem; }
/* A pass and a hidden company are dimmed and stay: a stray tap has to be
visible to be undone. The buttons keep full contrast, so the undo does. */
.row.muted .body, .row.passed .body { opacity: .55; }
.row.gated .body { opacity: .7; }
/* The Companies table dims a hidden company's row the same way. */
tr.muted { opacity: .55; }
/* The end of the list, which says which end it is. A list that has run out
and a list that is still loading look identical otherwise, and the first
one is the answer to "is that everything?". */
.feed-end {
padding: 1.1rem .4rem 2rem; text-align: center;
font-size: .84rem; color: var(--faint);
}
/* The company filtered to (roles.js `renderStrip`), in the reader summary's
band: a note about the list rather than a row of it. Gone while a role is
open, where the list is an index and the company is in the reader. */
.company-strip {
margin: .7rem 0 .2rem; padding: .6rem .9rem;
background: color-mix(in srgb, var(--accent) 7%, var(--panel));
border-left: 3px solid var(--accent); border-radius: .3rem;
}
body[data-reader="open"] .company-strip { display: none; }
.strip-head { display: flex; flex-wrap: wrap; align-items: center; gap: .3rem .75rem; }
.strip-name { font-size: 1.05rem; font-weight: 650; overflow-wrap: anywhere; }
.strip-count, .company-strip .reader-careers { font-size: .85rem; color: var(--dim); }
.company-strip .affinity { font-size: .85rem; }
.strip-drop { margin-left: auto; }
.strip-note, .strip-status { margin: .35rem 0 0; font-size: .8rem; line-height: 1.45; color: var(--dim); }
.strip-status:empty { display: none; }
.empty { padding: 4rem 0; max-width: 34rem; color: var(--dim); }
.empty h2 { font-size: 1.2rem; font-weight: 600; color: var(--fg); margin: 0 0 .4rem; }
/* ▲ ● ▼ ★, on a row and in the reader's bar (static/judge.js). */
.judge { display: flex; gap: .15rem; align-items: center; }
.judge button {
padding: .2rem .45rem; font-size: 1rem; line-height: 1;
color: var(--dim); background: none;
border: 1px solid transparent; border-radius: 3px;
}
@media (hover: hover) {
.judge button:hover { color: var(--fg); background: var(--bg); }
}
/* A cast vote is filled, not tinted, and the same button still takes it back.
Solid ground under a reversed glyph reads at arm's length where a tint does
not. The glyph is `--panel` because it is the opposite end of the scale from
every fill in both schemes. */
.judge .up[aria-pressed="true"] {
color: var(--panel); background: var(--accent); border-color: var(--accent);
}
.judge .down[aria-pressed="true"] {
color: var(--panel); background: var(--error); border-color: var(--error);
}
/* Neither way is an answer and must be as loud as the other two, or it
cannot be told from unjudged; grey, since it is no direction. */
.judge .mid[aria-pressed="true"] {
color: var(--panel); background: var(--faint); border-color: var(--faint);
}
/* Saved is a different question from judging: amber, and set apart. */
.judge .star[aria-pressed="true"] {
color: var(--panel); background: var(--warn); border-color: var(--warn);
}
.judge .star { margin-left: .35rem; }
/* -- the reader -- */
/* An author `display` beats the UA's [hidden] rule, so restate it. */
#reader[hidden] { display: none; }
#reader {
position: sticky; top: var(--chrome);
display: flex; flex-direction: column;
height: calc(100vh - var(--chrome) - 1rem);
margin-top: .5rem;
background: var(--panel);
border: 1px solid var(--line); border-radius: 4px;
overflow: hidden;
}
/* Pinned, so the keys you actually press stay put however far you scroll. */
.reader-bar {
flex: none;
display: flex; align-items: center; gap: .2rem;
padding: .35rem .6rem;
border-bottom: 1px solid var(--line);
}
.reader-bar .judge button { font-size: 1rem; line-height: 1; padding: .25rem .5rem; }
/* ↗ and ✕ keep to the right, by an auto margin rather than a spacer: when
the bar wraps, an auto margin takes the slack on whichever line it lands on. */
.reader-external {
display: inline-flex; align-items: center; justify-content: center;
min-width: 2.1rem; margin-left: auto;
padding: .2rem .45rem; font-size: .95rem; line-height: 1;
color: var(--dim); text-decoration: none;
border: 1px solid var(--line); border-radius: 3px;
}
.reader-bar .close {
font: inherit; font-size: 1rem; line-height: 1; padding: .25rem .5rem;
color: var(--faint); background: none; border: 1px solid transparent; border-radius: 3px;
}
.reader-external + .close { margin-left: .2rem; }
.reader-bar .judge + .close { margin-left: auto; }
@media (hover: hover) {
.reader-external:hover, .reader-bar .close:hover { color: var(--fg); background: var(--bg); }
}
.reader-body {
flex: 1; min-height: 0; overflow-y: auto;
padding: 1.6rem 2rem 4rem;
overflow-wrap: anywhere;
}
/* ~90 characters a line at the reading size: newsdesk's 36rem wrapped a
posting's short lines and lists too early. */
.reader-body > * { max-width: 48rem; margin-inline: auto; }
.reader-meta { margin-top: 0; }
.reader-meta b, .reader-meta .company { font-weight: 600; color: var(--dim); }
.reader-meta .company { text-decoration: none; }
.reader-meta .reader-careers { color: var(--dim); }
.reader-meta .affinity { font-size: .85rem; }
.reader-meta .affinity:empty { display: none; }
#reader h1 {
font-family: var(--read);
margin: .6rem auto .15rem;
font-size: 1.6rem; font-weight: 600; line-height: 1.25;
letter-spacing: -.005em;
}
.reader-salary { margin: .5rem auto 0; font-weight: 600; }
.reader-summary {
margin-top: 1.1rem; padding: .7rem .9rem;
background: color-mix(in srgb, var(--accent) 7%, var(--panel));
border-left: 3px solid var(--accent); border-radius: .3rem;
}
.reader-summary p { margin: 0; font-family: var(--read); line-height: 1.6; }
/* A label over a block rather than the posting's own heading. */
.reader-label {
margin: 0 0 .3rem; font-size: .72rem; font-weight: 600;
letter-spacing: .08em; text-transform: uppercase; color: var(--faint);
}
.reader-tools { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; margin-top: 1rem; }
.reader-tools > :empty { display: none; }
.reader-tools:not(:has(> :not(:empty))) { display: none; }
.reader-note {
color: var(--dim); font-size: .9rem; line-height: 1.55;
padding: .75rem .95rem; border-left: 2px solid var(--line); background: var(--bg);
}
.prose {
font-family: var(--read);
margin-top: 1.3rem; font-size: 1.06rem; line-height: 1.7;
}
.prose p { margin: 0 0 1.05rem; }
.reader-out { margin-top: 1.5rem; padding-top: 1rem; border-top: 1px solid var(--line); }
/* The step through the list, for the pointer that has no `j` and `k`. At the
foot of the pane because that is where a thumb already is. Shown only by
the narrow and `pointer: coarse` blocks below. */
.reader-foot {
flex: none; display: none; gap: .5rem;
padding: .5rem .6rem calc(.5rem + env(safe-area-inset-bottom));
border-top: 1px solid var(--line); background: var(--panel);
}
.reader-foot button {
flex: 1; min-height: 2.75rem;
color: var(--fg); background: none;
border: 1px solid var(--line); border-radius: .4rem;
}
.reader-foot button:disabled { color: var(--faint); opacity: .55; cursor: default; }
/* Applications: the table is the shared `table.list`. */
table.applications td[data-label="Saved"] { white-space: nowrap; color: var(--dim); }
/* -------------------------------------------------- narrow, and touched
Two axes, and deliberately not the same one.
*Width* decides the layout: how many of the three panes -- filters, list,
role -- fit at once. Above 60rem they sit side by side. Below it there is
room for exactly one, so the rail becomes an overlay and the role replaces
the list.
*Pointer* decides the sizes. A finger needs a 44px target and a mouse does
not, and that has nothing to do with how wide the window is: a tablet is
wide and touched, a half-screen laptop window is narrow and moused. Size by
width and each ends up in the other's clothes -- fat buttons for the mouse,
a 26px vote arrow for the thumb. So every touch rule is in `pointer:
coarse` and none of them is in a width query.
Keeping the two apart is also what keeps them out of each other's way:
nothing below this line changes what a wide, moused window renders. */
@media (max-width: 60rem) {
/* Narrow: the rail becomes an overlay so the feed keeps the full width. */
.shell { grid-template-columns: minmax(0, 1fr); gap: 0; padding-inline: .5rem; }
#rail {
position: fixed; inset: var(--chrome) auto 0 0; z-index: 9;
width: min(19rem, 92vw); max-height: none;
padding: .75rem .5rem calc(3rem + env(safe-area-inset-bottom));
background: var(--panel); border-right: 1px solid var(--line);
/* Not cosmetic: `align-self: start` keeps the sidebar from stretching to
the row when it is a grid item, and it is still in force here, where
the rail is out of flow. Chrome then self-aligns the box instead of
honouring `top` and `bottom` -- the panel lands at the top of the page,
behind the header, at its full content height, and scrolls off the
bottom of the screen with no way back to what it has run past. */
align-self: auto;
}
/* Before the script has said which, the overlay stays shut: a phone must
not open on a panel covering the list. */
body:not([data-rail="open"]) #rail { display: none; }
body[data-rail="open"] #scrim { display: block; }
#rail section + section { margin-top: .9rem; }
/* The header holds one row, and has to keep holding one: the rail and the
reader are measured from its height, so a second row costs a row of the
list on every screen. The search field is allowed to shrink rather than
push the tabs off the right-hand edge. */
#search { min-width: 0; flex: 1 1 6rem; }
.top:has(#search) nav { flex: 0 1 auto; margin-left: 0; }
/* No room for two panes: the role replaces the list rather than squeezing
next to it. `esc` brings the list back. Both selectors are restated
because the `[data-rail="shut"]` rule above out-specifies a media query,
which does nothing for specificity on its own. */
body[data-reader="open"] .shell,
body[data-reader="open"][data-rail="shut"] .shell {
grid-template-columns: minmax(0, 1fr);
}
body[data-reader="open"] #list { display: none; }
body[data-reader="open"] { overflow: hidden; }
body[data-reader="open"] .shell { padding: 0; }
body[data-reader="open"] #reader {
position: fixed; inset: var(--chrome) 0 0;
width: 100%; height: auto; margin: 0;
border: 0; border-radius: 0;
}
.reader-body { padding: .9rem .9rem 1.5rem; }
.reader-bar { gap: .1rem; padding: .2rem .35rem; flex-wrap: wrap; }
.reader-foot { display: flex; padding: .3rem .5rem calc(.3rem + env(safe-area-inset-bottom)); gap: .4rem; }
.reader-foot button { min-height: 36px; padding: .2rem; }
}
@media (max-width: 40rem) {
.row { grid-template-columns: 4px minmax(0, 1fr) auto; }
.score { display: none; }
/* The brand goes on the Roles page. On a phone this is the only page open
and you know which one it is; the width it was using is the difference
between a usable search field and a token one. The burger keeps its word
only while it has a count to say. */
.top:has(#search) .brand { display: none; }
#rail-toggle:not([aria-label*="filter"]) .rail-toggle-label { display: none; }
#reader h1 { font-size: 1.3rem; }
}
@media (max-width: 640px) {
.row { grid-template-columns: 4px minmax(0, 1fr); gap: .5rem; padding-inline: .25rem; }
.row .actions { grid-column: 2; justify-content: flex-end; gap: .4rem; }
#list[data-sort="time"] .row { grid-template-columns: minmax(0, 1fr); }
#list[data-sort="time"] .row .actions { grid-column: 1; }
/* Two filled blocks side by side need a gap between them or they read as
one control, and the arrow inside needs to be big enough to see which
way it points at arm's length. */
.actions button { padding: .25rem .75rem; min-height: 32px; font-size: 1.2rem; }
}
/* Sizes for a finger. 2.75rem is 44px at the default root size -- the
smallest target a thumb hits without aiming -- and nothing in here is
conditional on width, for the reason given at the top of the section. */
@media (pointer: coarse) {
#rail-toggle { min-height: 2.75rem; }
.actions button { padding: .5rem .7rem; font-size: 1.15rem; }
#rail .rail-row { align-items: center; min-height: 2.75rem; }
#rail .tag { padding: .45rem .8rem; }
#rail .seg button { min-height: 2.75rem; }
.rail-select, .rail-fields input[type="text"], .rail-fields select,
#rail select.agent-pick { min-height: 2.75rem; }
.rail-more > summary { padding-block: .7rem; }
.reader-bar { padding: .3rem .5rem; }
.reader-bar .judge button, .reader-bar .close, .reader-external { min-height: 2.75rem; min-width: 2.75rem; }
.reader-foot { display: flex; }
.reader-foot button { min-height: 2.75rem; }
/* A tag on a row or in the reader's meta line stays the size of the words
around it: the phone section's 44px floor for every button would make
each one a line of its own. The rail's chips are the tag targets sized
for a thumb. */
.meta .tag.mini, .reader-meta .tag.mini { min-height: 0; }
/* A company's name takes taps from a band around it, padding a thumb can
hit given back by a negative margin, so the row is no taller. On top of
the lines above and below, which it overlaps by a few pixels. */
.meta .company, .reader-meta .company {
position: relative; padding: .55rem .35rem; margin: -.55rem -.35rem;
}
/* No keys on a touch screen, so no key hints. */
.rail-keys { display: none; }
}
@media (prefers-reduced-motion: reduce) {
* { transition: none !important; animation: none !important; }
}
/* == end of roles ========================================================= */
.affinity { display: inline-flex; gap: .15rem; }
.affinity button {
background: none; border: 1px solid var(--line); border-radius: .3rem;
padding: .1rem .4rem; color: var(--dim); font-size: 1rem; line-height: 1.4;
}
/* One colour per stance, filled rather than tinted so "pressed" reads at a
glance (news's own reasoning for its vote buttons, app.css 1906-1930):
gold for favourite, the app's own accent for like, the error red for
hidden, since hiding a company is the one stance that keeps its roles out
of the list entirely. */
.affinity button[data-value="2"][aria-pressed="true"] {
color: var(--accent-fg); background: var(--warn); border-color: var(--warn);
}
.affinity button[data-value="1"][aria-pressed="true"] {
color: var(--accent-fg); background: var(--accent); border-color: var(--accent);
}
.affinity button[data-value="-1"][aria-pressed="true"] {
color: var(--accent-fg); background: var(--error); border-color: var(--error);
}
/* agents */
/* The Search agents page: a card per agent (static/agents.js). What it looks
for is the card's body, in the reading face, since it is what fit is
measured against; the weights are a small line under it. */
.agents-head { display: flex; align-items: center; justify-content: space-between; gap: var(--gap); }
.agent-cards { display: flex; flex-direction: column; gap: .9rem; margin: .5rem 0 2rem; }
.agent-card {
background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
padding: 1rem 1.25rem;
}
.agent-card.editing { border-color: var(--accent); box-shadow: 0 0 0 1px var(--accent); }
/* One line however long the name: the name wraps inside its own box, and the
badge and the switch keep their width, level with its first line. */
.agent-card-head { display: flex; align-items: baseline; gap: .6rem; }
.agent-name { flex: 0 1 auto; min-width: 0; font-size: 1.2rem; font-weight: 700; margin: 0; overflow-wrap: anywhere; }
.agent-card-head .badge { flex: none; }
/* The switch keeps to the right, by an auto margin rather than a spacer. */
.agent-card-head .switch { flex: none; margin-left: auto; }
.agent-intent {
margin: .6rem 0 .4rem; max-width: 44rem;
font-family: var(--read); font-size: 1.02rem; line-height: 1.55;
white-space: pre-line; overflow-wrap: anywhere;
}
.agent-intent.empty { font-family: inherit; font-size: .9rem; color: var(--dim); font-style: italic; }
/* A prompt's name is a small heading over its text, so three prompts read as
three kinds of role rather than one long paragraph. */
.agent-prompt-name { margin: .7rem 0 0; font-size: .8rem; font-weight: 600; color: var(--dim); }
.agent-prompt-name + .agent-intent { margin-top: .2rem; }
.agent-rules { margin: 0 0 .3rem; font-size: .9rem; color: var(--dim); overflow-wrap: anywhere; }
.agent-weights, .agent-limits { margin: 0; font-size: .8rem; color: var(--faint); font-variant-numeric: tabular-nums; }
.agent-card-actions { display: flex; align-items: center; flex-wrap: wrap; gap: .5rem 1rem; margin-top: .8rem; }
.agent-card-actions a { font-size: .9rem; font-weight: 600; text-decoration: none; }
@media (hover: hover) {
.agent-card-actions a:hover { text-decoration: underline; }
}
.agent-card-actions .linky { margin-left: auto; }
.agent-card .agent-status { margin: .5rem 0 0; }
.agent-card .agent-status:empty { display: none; }
/* An agent that is off: the card stays readable, only quieter. */
.agent-card[data-off="true"] .agent-name,
.agent-card[data-off="true"] .agent-intent { color: var(--dim); }
/* In a card the form is the card's body, not a panel of its own. */
.agent-card .agent-form {
max-width: none; margin: 0; padding: 0;
background: none; border: 0; border-radius: 0;
}
.agent-card .agent-form h2 { font-size: 1.2rem; }
/* On and Off, said in words beside a track: a bare checkbox did not say what
it switched. The checkbox is still the control, only drawn over. */
.switch {
position: relative; display: inline-flex; align-items: center; gap: .45rem;
cursor: pointer; font-size: .85rem; font-weight: 600; color: var(--dim);
user-select: none;
}
.switch input { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: pointer; }
.switch-track {
position: relative; flex: none; width: 2.2rem; height: 1.25rem;
border-radius: 999px; background: var(--line); transition: background 120ms;
}
.switch-track::after {
content: ""; position: absolute; top: .15rem; left: .15rem;
width: .95rem; height: .95rem; border-radius: 50%;
background: var(--panel); box-shadow: 0 1px 2px rgb(0 0 0 / .25);
transition: transform 120ms;
}
.switch input:checked + .switch-track { background: var(--accent); }
.switch input:checked + .switch-track::after { transform: translateX(.95rem); }
.switch input:checked ~ .switch-label { color: var(--accent); }
.switch input:focus-visible + .switch-track { outline: 2px solid var(--accent); outline-offset: 2px; }
.switch input:disabled ~ * { opacity: .55; }
@media (pointer: coarse) {
.switch { min-height: 2.75rem; padding-left: .5rem; }
}
.agent-form {
display: flex; flex-direction: column; gap: .6rem; max-width: 44rem;
background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
padding: .75rem 1rem;
}
.agent-form h2, .agent-form h3 { font-size: 1rem; margin: 0; }
.agent-form label { display: flex; flex-direction: column; gap: .2rem; font-size: .9rem; }
.agent-form label.inline { flex-direction: row; align-items: center; gap: .4rem; }
.agent-form input[type="text"], .agent-form textarea, .agent-form input[type="number"],
.agent-form input[type="url"] {
background: var(--bg); border: 1px solid var(--line);
border-radius: .3rem; padding: .35rem .5rem; width: 100%;
}
/* Prose in a textarea is read in the page face; JSON is in the mono one. */
.agent-form textarea.code { font-family: var(--mono); font-size: .85rem; }
.agent-form .hint { color: var(--dim); font-size: .8rem; overflow-wrap: anywhere; }
.weights { display: flex; gap: .75rem; flex-wrap: wrap; border: 1px solid var(--line); border-radius: .3rem; }
/* A label that wraps to two lines pushes its box down; the boxes stay in line. */
.weights label { flex: 1 1 6rem; justify-content: space-between; }
/* The limits are a pair per stage, count then score, so two to a row. */
.weights.limits label { flex: 1 1 40%; }
.agent-form fieldset + .hint { margin-top: -.3rem; }
.agent-actions { display: flex; gap: .5rem; flex-wrap: wrap; }
.agent-form select {
background: var(--bg); border: 1px solid var(--line);
border-radius: .3rem; padding: .35rem .5rem;
}
/* The fieldsets that hold rows: a column, the Add button under the rows. */
.agent-form fieldset.prompts, .agent-form fieldset.where, .agent-form fieldset.rules {
display: flex; flex-direction: column; align-items: stretch; gap: .5rem; min-width: 0;
border: 1px solid var(--line); border-radius: .3rem;
}
.agent-form fieldset > button { align-self: flex-start; }
/* A prompt or a rule as a row of a list, after `.crow`: the name and Remove
on line one, the text spanning the row under them. A rule row wraps like
`.crow .board-edit`, so a phone takes it in two lines rather than scrolling. */
.prompt-row {
display: grid; grid-template-columns: 1fr auto; align-items: center;
column-gap: .6rem; row-gap: .3rem; padding-bottom: .6rem; border-bottom: 1px solid var(--line);
}
.prompt-row textarea { grid-column: 1 / -1; }
.rule-row {
display: flex; flex-wrap: wrap; align-items: center; gap: .4rem;
padding-bottom: .5rem; border-bottom: 1px solid var(--line);
}
.rule-rows:empty, .prompt-rows:empty { display: none; }
.agent-form .rule-row input[type="text"] { flex: 1 1 8rem; width: auto; min-width: 0; }
.agent-form .rule-row input[type="number"], .agent-form .where input[type="number"] { width: 5rem; flex: none; }
/* A Where line: its words, then its chips, which wrap under them on a phone.
The words share one width, so the chips of every line start level. */
.where-line { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem; font-size: .9rem; }
.where-line > span, .where-line > label { flex: none; min-width: 9rem; }
.where-line .chips { flex: 1 1 12rem; }
/* Hybrid ranks rather than filters, so it stands apart from the lines, and
the sentence under it says the whole block. */
.agent-form .where-rank { margin-top: .4rem; }
.agent-form .where-sum { margin: 0; padding-top: .5rem; border-top: 1px solid var(--line); font-size: .9rem; }
/* Values as the rail's tags, each removed by its ×; the box to add one takes
the rest of the line. */
.chips { display: flex; flex-wrap: wrap; align-items: center; gap: .25rem; min-width: 0; }
.agent-form .chips input[type="text"] { flex: 1 1 6rem; width: auto; min-width: 0; }
.agent-form .chips select { flex: 0 1 12rem; min-width: 0; max-width: 100%; }
.chips .tag span { color: var(--faint); }
.agent-form details summary { cursor: pointer; color: var(--dim); font-size: .9rem; }
.agent-form details[open] summary { margin-bottom: .5rem; }
.agent-form .advanced-body { display: flex; flex-direction: column; gap: .6rem; }
/* ================================================================ */
/* companies and sources — the Sources page's sections, */
/* static/companies.js and static/sources.js. Package B2's own */
/* section; the rest of the file is not reflowed for it. */
/* ================================================================ */
.section { margin: 1.5rem 0 2rem; }
.section > h2 { margin-bottom: .25rem; }
.source-form { margin-top: 1rem; max-width: none; }
/* The agent select on the filter row: a label beside its box, not above. */
.filters label.inline { display: flex; align-items: center; gap: .4rem; font-size: .9rem; color: var(--dim); }
.filters label.inline select { color: var(--fg); }
/* `auto-fit` rather than a fixed count of columns: a row with fewer fields
(Jobindex's Area, say, where Adzuna also needs Country and Place) simply
leaves the boxes it does have at the same width instead of stretching one
to fill the gap, which is what made the boxes disagree with each other's
width before. */
.form-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(9rem, 1fr)); gap: .75rem; align-items: start; }
.source-form select {
background: var(--bg); border: 1px solid var(--line);
border-radius: .3rem; padding: .35rem .5rem;
}
.source-form input[type="number"] { max-width: 6rem; }
.sample { margin: 0; padding-left: 1.25rem; font-size: .9rem; }
.sample li { margin: .15rem 0; }
.mono { font-family: var(--mono); overflow-wrap: anywhere; }
/* A row of a list that is not a table: Companies and Searches, after news's
`.srow` (app.css 659-665 and 783-787 there). Line one is the name and
whatever switch or controls belong beside it; `.sub`, muted and full width,
wraps onto its own line rather than sharing a column with them, which is
what keeps a long query or board name from crowding the switch at any
width — a table's fixed columns needed a breakpoint to do the same, a grid
with one column spanning the row does not. */
.srows, .crows { display: flex; flex-direction: column; margin: .5rem 0 1.5rem; }
.srow, .crow {
display: grid; grid-template-columns: 1fr auto auto;
align-items: center; column-gap: .6rem; row-gap: .15rem;
padding: .5rem 0; border-bottom: 1px solid var(--line);
}
.srow .name, .crow .name {
grid-column: 1; display: flex; align-items: center; gap: .4rem;
font-size: .96rem; text-decoration: none; color: inherit;
}
.crow .name { font-weight: 600; }
/* Only a name that is a link: the Watchlist draws one without a page to
open as text, which must not look as if it led somewhere. */
@media (hover: hover) {
.crow a.name:hover { text-decoration: underline; }
}
.srow .sub, .crow .sub {
grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: center;
gap: .4rem; font-size: .8rem; color: var(--dim);
}
.srow[data-muted="true"], .crow[data-hidden="true"] { opacity: .6; }
/* A company row's Set board / Change editor: its own line under `.sub`,
wrapping like `.sub` does, the boxes styled as `.source-form`'s. */
.crow .board-edit {
grid-column: 1 / -1; display: flex; flex-wrap: wrap; align-items: center;
gap: .4rem; padding-top: .25rem;
}
.crow .board-edit select, .crow .board-edit input {
background: var(--bg); border: 1px solid var(--line);
border-radius: .3rem; padding: .35rem .5rem;
}
.crow .board-edit input { flex: 1 1 8rem; min-width: 0; }
.crow .sub .failing { color: var(--warn); }
/* A Watchlist row's note, a line of its own: the owner's line breaks kept,
and a pasted URL broken rather than widening a phone's page. */
.crow .sub.notes { white-space: pre-line; overflow-wrap: anywhere; }
.linky {
padding: 0; border: 0; background: none; font-size: .8rem;
color: var(--dim); text-decoration: underline; text-underline-offset: 2px;
}
@media (hover: hover) {
.linky:hover { color: var(--fg); background: none; }
}
/* The prune tool: folded under the list, since switching a board off by
region is an occasional errand and not what the page is for. */
.prune > summary { cursor: pointer; color: var(--dim); font-weight: 600; }
.prune[open] > summary { margin-bottom: .75rem; }
/* applications and companies */
table.list { width: 100%; border-collapse: collapse; background: var(--panel); }
table.list th, table.list td {
text-align: left; padding: .5rem .6rem; border-bottom: 1px solid var(--line);
font-size: .9rem;
}
table.list .num { text-align: right; font-variant-numeric: tabular-nums; }
table.list select { padding: .25rem .4rem; }
/* Below tablet width a table stops being a table: each row becomes a card,
its cells stacked, so nothing scrolls sideways to be read. */
@media (max-width: 640px) {
table.list thead { display: none; }
table.list, table.list tbody, table.list tr, table.list td { display: block; width: 100%; }
table.list tr { margin-bottom: .6rem; border: 1px solid var(--line); border-radius: .4rem; }
table.list td { border-bottom: none; }
table.list .num { text-align: left; }
table.list td::before {
content: attr(data-label);
display: block; font-size: .72rem; color: var(--dim); margin-bottom: .1rem;
}
}
/* -- the phone ------------------------------------------------------------ */
/* Two axes, and deliberately not the same one, as in newsdesk: width decides
the layout, pointer decides the sizes. A tablet is wide and touched, a
half-screen laptop window is narrow and moused, and sizing either by width
puts it in the other's clothes. */
@media (max-width: 640px) {
main { padding: 10px 10px calc(3rem + env(safe-area-inset-bottom)); }
h1 { font-size: 1.25rem; }
/* The bar stays one row: the brand keeps its word, the two tabs share what
is left, and the cog keeps its own width rather than a share. */
.top { flex-wrap: nowrap; gap: .5rem; padding: calc(4px + env(safe-area-inset-top)) .6rem 4px; }
.top nav { flex: 1; flex-wrap: nowrap; gap: .15rem; min-width: 0; }
.top nav a { flex: 1 1 auto; text-align: center; padding: .6rem .4rem; white-space: nowrap; }
.top nav a.icon { flex: 0 0 auto; justify-content: center; padding-inline: .7rem; }
/* A panel runs to both edges of the screen: no side margin, border or
rounded corner, so the content keeps all but its own 10 pixels of the
width. The page background between two panels reads as a band. */
.card, .filters, .agent-form, .agent-card, .note {
margin-inline: -10px; border-radius: 0; border-inline: 0;
}
.card, .agent-card { padding: .8rem 10px; }
.agent-card.editing { box-shadow: none; }
.row-between { flex-wrap: wrap; }
}
/* The band between two full-width panels needs more contrast than the light
page background gives a white panel; the dark one is already distinct. */
@media (max-width: 640px) and (prefers-color-scheme: light) {
:root { --bg: #e1e5e8; }
}
/* Sizes for a finger. 2.75rem is 44px at the default root size, the smallest
target a thumb hits without aiming. */
@media (pointer: coarse) {
/* Under 16px, iOS Safari zooms the page when a field takes focus, and does
not zoom back out when it loses it. */
input, select, textarea { font-size: 16px; }
button, .top nav a { min-height: 2.75rem; }
.top nav a { display: inline-flex; align-items: center; justify-content: center; }
.filters input[type="search"], .filters input[type="text"], .filters select,
.agent-form input:not([type="checkbox"]), .agent-form select, .source-form select,
.crow .board-edit input, .crow .board-edit select { min-height: 2.75rem; }
.affinity button { min-width: 2.75rem; }
.check input { width: 1.25rem; height: 1.25rem; }
}
/* Three tabs and the cog, at 390px: the phone block's padding and size leave
the bar 37px too wide, and a nowrap bar that is too wide scrolls the whole
page sideways. Tighter tabs, still touch-high (see the coarse block). */
@media (max-width: 640px) {
.top { gap: .4rem; }
.top nav a { padding-inline: .25rem; font-size: .9rem; }
.top nav a.icon { padding-inline: .55rem; }
}
/* On Roles the search field is what gives way, not the tabs: the nav keeps
the width its tabs need and the field takes what is left. */
@media (max-width: 640px) {
.top:has(#search) nav { flex: 0 0 auto; }
.top:has(#search) nav a:not(.icon) { padding-inline: .2rem; }
/* Which leaves the field a few letters wide, so while it is typed in it
takes the bar and the tabs step aside; they are back when it is left. */
.top:has(#search:focus) nav a:not(.icon), .top:has(#search:focus) desk-queue { display: none; }
/* With a filter on, the burger says how many in words, which at 390px
made the bar 30 to 50px wider than the screen, and a phone widens the
page to fit, the reader's ✕ with it. The queue steps aside, as it does
for the search, and so do the burger's three lines, since its words say
what it opens. */
.top:has(#rail-toggle[aria-label*="filter"]) desk-queue,
#rail-toggle[aria-label*="filter"] .burger { display: none; }
}