:root {
  --bg: #f6f7f9;
  --panel: #ffffff;
  --text: #1c2128;
  --muted: #5d6673;
  --line: #d9dee5;
  --accent: #1f6feb;
  --accent-text: #ffffff;
  --error-bg: #fdecea;
  --error: #9b1c1c;
  --notice-bg: #e8f3ec;
  --notice: #1e5b34;
  --code-bg: #eef1f4;
  --brand: #000;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0f1216;
    --panel: #171b21;
    --text: #e3e7ec;
    --muted: #9aa4b1;
    --line: #2c333c;
    --accent: #4c8dff;
    --accent-text: #0b0e12;
    --error-bg: #3a1717;
    --error: #ffb4ab;
    --notice-bg: #16301f;
    --notice: #a8e0b9;
    --code-bg: #20262e;
    --brand: #fff;
    color-scheme: dark;
  }
}

* { box-sizing: border-box; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 15px/1.55 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
}
a { color: var(--accent); }
h1 { font-size: 1.6rem; margin: 0.2rem 0 0.8rem; }
h2 { font-size: 1.1rem; margin: 0 0 0.6rem; }

header.top {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.5rem 1rem;
  padding: 0.7rem 1.25rem; background: var(--panel); border-bottom: 1px solid var(--line);
}
.brand { display: inline-flex; align-items: center; gap: 0.55rem; font-weight: 700; font-size: 1.05rem;
  color: var(--brand); text-decoration: none; letter-spacing: 0.01em; }
.brand-mark { height: 1.5rem; width: auto; flex: none; }
header nav { display: flex; flex-wrap: wrap; align-items: center; gap: 1rem; }
header nav a { color: var(--text); text-decoration: none; }
header nav a:hover { color: var(--accent); }
header form { margin: 0; }

main { max-width: 64rem; margin: 0 auto; padding: 1.25rem 1.25rem 3rem; }

.panel {
  background: var(--panel); border: 1px solid var(--line); border-radius: 8px;
  padding: 1rem 1.25rem; margin: 0 0 1rem;
}
.panel.narrow { max-width: 24rem; margin: 3rem auto; }
.grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(18rem, 1fr)); gap: 1rem; margin-bottom: 1rem; }
.grid .panel { margin: 0; }

.muted, .hint { color: var(--muted); }
.hint { font-size: 0.88rem; }
.crumbs { margin: 0; color: var(--muted); font-size: 0.9rem; }
.error, .notice { padding: 0.7rem 1rem; border-radius: 6px; }
.error { background: var(--error-bg); color: var(--error); }
.notice { background: var(--notice-bg); color: var(--notice); }

.titlebar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 0.5rem; }

ul.plain, ul.history, ul.cards { list-style: none; padding: 0; margin: 0; }
ul.history li { padding: 0.3rem 0; border-bottom: 1px solid var(--line); }
ul.history li:last-child { border-bottom: 0; }
ul.history time { color: var(--muted); font-size: 0.88rem; margin-right: 0.5rem; }
ul.cards { display: grid; gap: 0.6rem; margin-bottom: 1.25rem; }
ul.cards a {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0.5rem;
  padding: 0.9rem 1.1rem; background: var(--panel); border: 1px solid var(--line); border-radius: 8px;
  color: var(--text); text-decoration: none;
}
ul.cards a:hover { border-color: var(--accent); }

form.stack { display: grid; gap: 0.8rem; max-width: 34rem; }
form.stack label { display: grid; gap: 0.25rem; }
form.stack button { justify-self: start; }
form.row, div.row { display: flex; flex-wrap: wrap; align-items: center; gap: 0.75rem; }
form.row input { flex: 1 1 16rem; }
label.check { display: flex !important; align-items: baseline; gap: 0.5rem; }
fieldset { border: 1px solid var(--line); border-radius: 6px; padding: 0.6rem 0.9rem 0.8rem; margin: 0; display: grid; gap: 0.4rem; }
legend { color: var(--muted); font-size: 0.9rem; padding: 0 0.3rem; }

[hidden] { display: none !important; }
input:not([type=checkbox]):not([type=radio]), textarea {
  font: inherit; color: var(--text); background: var(--bg);
  border: 1px solid var(--line); border-radius: 6px; padding: 0.45rem 0.6rem; width: 100%;
}
input:focus, textarea:focus { outline: 2px solid var(--accent); outline-offset: -1px; }
button, a.button {
  font: inherit; display: inline-block; cursor: pointer; text-decoration: none;
  background: var(--accent); color: var(--accent-text); border: 0; border-radius: 6px; padding: 0.45rem 1rem;
}
button.link { background: none; color: var(--text); padding: 0; }
a.button.secondary, button.secondary { background: none; color: var(--text); border: 1px solid var(--line); }
a.button.secondary:hover, button.secondary:hover { border-color: var(--accent); }
form.spaced { margin-top: 0.8rem; }
.panel.danger { border-color: var(--error); }
button.danger { background: var(--error); color: var(--panel); }
button.link:hover { color: var(--accent); }

.editor textarea {
  min-height: 70vh; resize: vertical; margin-bottom: 0.8rem;
  font: 14px/1.5 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

.scroll { overflow-x: auto; margin-bottom: 1rem; }
table.list { width: 100%; border-collapse: collapse; background: var(--panel); border: 1px solid var(--line); border-radius: 8px; }
table.list th, table.list td { text-align: left; padding: 0.55rem 0.8rem; border-bottom: 1px solid var(--line); }
table.list th { color: var(--muted); font-weight: 600; font-size: 0.88rem; }
table.list tr.disabled td { color: var(--muted); }

details summary { cursor: pointer; color: var(--muted); }
details[open] summary { margin-bottom: 0.6rem; }

.markdown { padding: 1.25rem 1.75rem; }
.markdown h1 { font-size: 1.7rem; border-bottom: 1px solid var(--line); padding-bottom: 0.4rem; }
.markdown h2 { font-size: 1.3rem; margin-top: 1.6rem; border-bottom: 1px solid var(--line); padding-bottom: 0.3rem; }
.markdown h3 { font-size: 1.1rem; margin-top: 1.3rem; }
.markdown code { background: var(--code-bg); padding: 0.1rem 0.35rem; border-radius: 4px; font-size: 0.9em; }
.markdown pre { background: var(--code-bg); padding: 0.8rem 1rem; border-radius: 6px; overflow-x: auto; }
.markdown pre code { padding: 0; background: none; }
.markdown table { border-collapse: collapse; display: block; overflow-x: auto; }
.markdown th, .markdown td { border: 1px solid var(--line); padding: 0.35rem 0.7rem; }
.markdown blockquote { margin-left: 0; padding-left: 1rem; border-left: 3px solid var(--line); color: var(--muted); }
.markdown img { max-width: 100%; }

.dot { display: inline-block; width: 0.6rem; height: 0.6rem; border-radius: 50%; margin: 0 0.2rem 0 0.4rem; vertical-align: middle; }
.dot.on { background: #2ea043; }
.dot.busy { background: #d29922; }
.dot.off { background: var(--muted); }
.dot.wait { background: transparent; box-shadow: inset 0 0 0 2px #d29922; }
ul.machines li { padding: 0.3rem 0; }
.state { font-size: 0.8rem; font-weight: 600; padding: 0.1rem 0.5rem; border-radius: 1rem; border: 1px solid var(--line); vertical-align: middle; }
.state.passed { color: #2ea043; border-color: #2ea043; }
.state.failed, .state.error { color: var(--error); border-color: var(--error); }
.state.running, .state.queued { color: #d29922; border-color: #d29922; }
pre { background: var(--code-bg); padding: 0.8rem 1rem; border-radius: 6px; overflow-x: auto; font: 13px/1.45 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }
pre.output { max-height: none; white-space: pre-wrap; word-break: break-all; }
pre.secret { user-select: all; font-size: 0.95rem; }
textarea.code { font: 13px/1.45 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }
form.stack.wide { max-width: none; }
form.stack .row label { flex: 1 1 10rem; }
button[disabled] { opacity: 0.5; cursor: not-allowed; }
fieldset.models { max-height: 22rem; overflow-y: auto; align-content: start; }
select {
  font: inherit; color: var(--text); background: var(--bg);
  border: 1px solid var(--line); border-radius: 6px; padding: 0.45rem 0.6rem; width: 100%;
}
select:focus { outline: 2px solid var(--accent); outline-offset: -1px; }

details.more { margin-top: 0.4rem; }
.scrollbox { max-height: 22rem; overflow-y: auto; border: 1px solid var(--line); border-radius: 6px; padding: 0 0.8rem; }
table.dense th, table.dense td { padding: 0.3rem 0.7rem; font-size: 0.9rem; }
/* Runs: two lines a run, the title across the width and the details under it. */
table.runs th, table.runs td { padding: 0.15rem 0.5rem; font-size: 0.86rem; line-height: 1.35; }
table.runs th { white-space: nowrap; }
ul.runlist { list-style: none; margin: 0; padding: 0; background: var(--panel); border: 1px solid var(--line); border-radius: 8px; }
ul.runlist li { padding: 0.3rem 0.7rem; border-bottom: 1px solid var(--line); }
ul.runlist li:last-child { border-bottom: 0; }
ul.runlist .l1 { display: flex; gap: 0.4rem; align-items: baseline; }
ul.runlist .l1 .title { flex: 1; min-width: 0; }
ul.runlist .l1 .end { margin-left: auto; padding-left: 0.6rem; white-space: nowrap; }
ul.runlist .l1 .end > a { margin-left: 0.5rem; }
ul.runlist .l1 .end form { display: inline; margin-left: 0.5rem; }
ul.runlist .l1 .end button.link { color: var(--accent); font-size: inherit; }
ul.runlist .l2 { font-size: 0.82rem; }
ul.runlist .tag { font-size: 0.75rem; color: var(--muted); border: 1px solid var(--line); border-radius: 4px; padding: 0 0.3rem; }
table.cases td:nth-child(2) { width: 100%; } /* the title takes the spare width */
table.members { width: auto; min-width: min(100%, 28rem); }
table.members td, table.members th { white-space: nowrap; padding-right: 2rem; }
a.plainlink { color: var(--text); text-decoration: none; }
a.plainlink:hover { color: var(--accent); }
form.search { margin-bottom: 0.6rem; }
form.search input { flex: 1 1 20rem; }

td.nowrap, .nowrap { white-space: nowrap; }
p.names { line-height: 1.7; }

ul.models li { display: flex; align-items: baseline; gap: 0.4rem; min-width: 0; }
ul.models .model { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* An (i) whose note shows at once on hover or focus: CSS only, no delay, normal cursor. */
.info { position: relative; color: var(--muted); cursor: default; font-size: 0.85em; flex: none; }
.info:hover, .info:focus { color: var(--text); outline: none; }
.info::after {
  content: attr(data-tip); position: absolute; right: 0; bottom: calc(100% + 0.35rem);
  white-space: nowrap; padding: 0.25rem 0.55rem; border-radius: 5px; font-size: 0.8rem;
  background: var(--text); color: var(--bg); pointer-events: none; opacity: 0; z-index: 10;
}
.info:hover::after, .info:focus::after { opacity: 1; }
/* In a modal the note opens below its (i), wrapped and at most as wide as the dialog leaves room for, so it is
   never cut at the dialog's edge (workflow.js sets --tip-max and --tip-left from where the icon is, and
   tip-above where there is no room below). */
.modal .info::after { left: var(--tip-left, 0); right: auto; top: calc(100% + 0.35rem); bottom: auto;
  width: max-content; max-width: var(--tip-max, 18rem); white-space: normal; line-height: 1.35; }
.modal .info.tip-above::after { top: auto; bottom: calc(100% + 0.35rem); }

/* A card that opens its full page when clicked anywhere; links and (i)s inside stay their own. */
.panel.tile { position: relative; transition: border-color 0.15s; }
.panel.tile:hover { border-color: var(--accent); }
.panel.tile .tile-link { all: unset; cursor: pointer; }
.panel.tile .tile-link::after { content: ""; position: absolute; inset: 0; border-radius: 8px; }
.panel.tile .tile-link:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
p.status { font-size: 1.05rem; margin: 0.3rem 0; }
p.status .dot { margin-left: 0; }

/* Modals: the browser's popover, dismissed by Esc, a click outside, or the close button. */
.modal { inset: 0; margin: auto; width: fit-content; height: fit-content;
  min-width: min(92vw, 26rem); max-width: min(92vw, 52rem); max-height: 80vh; overflow: auto;
  padding: 1rem 1.25rem; background: var(--panel); color: var(--text);
  border: 1px solid var(--line); border-radius: 10px; box-shadow: 0 12px 40px rgb(0 0 0 / 0.45); }
.modal::backdrop { background: rgb(0 0 0 / 0.6); backdrop-filter: blur(2px); }
.modal .scroll { margin-bottom: 0.6rem; }
.modal table.list { width: 100%; min-width: 0; }
.modal-head { display: flex; align-items: center; justify-content: space-between; gap: 1rem; margin-bottom: 0.6rem; }
.modal-head h2 { margin: 0; }
button.close { background: none; color: var(--muted); padding: 0.1rem 0.5rem; font-size: 1.1rem; }
button.close:hover { color: var(--text); }
.panel.tile a:not(.tile-link), .panel.tile .info { position: relative; z-index: 1; }

ul.recent li { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* ---- the workflow page: full width, a tab per kind, and the canvas ---- */
main.wide { max-width: none; padding-bottom: 1rem; }
.wf-top { display: flex; flex-wrap: wrap; align-items: center; gap: 0.4rem 0.75rem; margin-bottom: 0.6rem; }
.wf-top .crumbs { margin: 0; }
nav.tabs { display: flex; gap: 0.25rem; }
nav.tabs a { padding: 0.3rem 0.7rem; border-radius: 6px; color: var(--muted); text-decoration: none; border: 1px solid transparent; }
nav.tabs a:hover { color: var(--text); }
nav.tabs a.on { color: var(--text); border-color: var(--line); background: var(--panel); }
.wf-live { display: flex; align-items: center; gap: 0.5rem; margin: 0; font-size: 0.88rem; }
.wf-live button { margin: 0; }
.wf-on { font-weight: 600; }
.wf-recent { margin: 0.4rem 0 0; padding-left: 1.2rem; font-size: 0.88rem; }
.wf-status { flex: 1 1 0; min-width: 0; text-align: right; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 0.88rem; color: var(--muted); }
.wf-status.bad { color: var(--error); }
.wf-canvas { position: relative; height: calc(100vh - 11.5rem); min-height: 24rem; border: 1px solid var(--line); border-radius: 8px;
  background-color: var(--bg); background-image: radial-gradient(var(--line) 1px, transparent 1px); background-size: 22px 22px; overflow: hidden; }
.wf-hint { margin: 0.5rem 0 0; }
.wf-canvas .drawflow .drawflow-node { background: var(--panel); border: 1px solid var(--line); border-radius: 8px; color: var(--text);
  width: 15rem; padding: 0.7rem 0.9rem; box-shadow: 0 2px 8px rgb(0 0 0 / 0.25); }
.wf-canvas .drawflow .drawflow-node:hover { border-color: var(--accent); cursor: pointer; }
.wf-canvas .drawflow .drawflow-node.selected { background: var(--panel); border-color: var(--accent); }
.wf-canvas .drawflow .drawflow-node .input, .wf-canvas .drawflow .drawflow-node .output { background: var(--panel); border: 2px solid var(--accent); width: 14px; height: 14px; }
.wf-canvas .drawflow .connection .main-path { stroke: var(--accent); stroke-width: 3px; }
.wf-canvas .drawflow-delete { display: none; }
.wf-node .wf-title { font-weight: 600; }
.wf-node .wf-sub { color: var(--muted); font-size: 0.82rem; margin-top: 0.2rem; }
/* A block that continues another's conversation: a dashed border, and a line saying whose. */
.wf-canvas .drawflow .drawflow-node.wf-reference { border-style: dashed; border-width: 2px; }
.wf-node .wf-ref { color: var(--accent); font-size: 0.82rem; margin-top: 0.2rem; }
.wf-node .wf-ref:empty { display: none; }
/* A block whose templates use a tag the rules do not allow: a red border and the reason, in red. */
.wf-canvas .drawflow .drawflow-node.wf-problem { border-color: var(--error); border-width: 2px; }
.wf-canvas .wf-problem .wf-sub { color: var(--error); font-weight: 600; }
.wf-pr_ready, .wf-pr_draft, .wf-pr_activity, .wf-pr_backlog, .wf-issue_opened, .wf-issue_backlog, .wf-discord_mention, .wf-lfa_kickoff { border-left: 4px solid #2ea043 !important; }
.wf-pages-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem; margin: 0.45rem 0 0.55rem; }
.wf-pages-bar .wf-pages { display: flex; flex-wrap: wrap; gap: 0.35rem; }
.wf-page-pop { position: relative; }
.wf-page-pop summary { list-style: none; cursor: pointer; font-size: 0.85rem; padding: 0.3rem 0.65rem; }
.wf-page-pop summary::-webkit-details-marker { display: none; }
.wf-page-pop .wf-page-form { position: absolute; left: 0; top: calc(100% + 0.35rem); z-index: 30; width: min(24rem, 85vw); box-shadow: 0 8px 24px rgb(0 0 0 / 0.45); }
.wf-lib-pop .wf-page-form { left: auto; right: 0; width: min(30rem, 92vw); max-height: 75vh; overflow-y: auto; }
.wf-lib-sep { border: 0; border-top: 1px solid var(--line); margin: 0.25rem 0; }
.wf-lib-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 0.65rem; }
.wf-lib-item { display: flex; justify-content: space-between; align-items: flex-start; gap: 0.75rem; padding-bottom: 0.55rem; border-bottom: 1px solid var(--line); }
.wf-lib-item:last-child { border-bottom: 0; padding-bottom: 0; }
.wf-lib-meta { font-size: 0.85rem; min-width: 0; }
.wf-lib-desc { font-size: 0.8rem; margin-top: 0.15rem; }
.wf-lib-actions { flex-shrink: 0; gap: 0.35rem; }
.wf-lib-actions button { font-size: 0.8rem; padding: 0.25rem 0.55rem; }
.wf-lib-empty { margin: 0; }
.wf-pop-end { align-self: flex-end; }
.wf-page-desc { font-size: 0.85rem; margin-left: 0.25rem; }
.wf-menu { position: fixed; z-index: 50; display: grid; min-width: 11rem; max-height: calc(100vh - 16px); overflow-y: auto; padding: 0.3rem; background: var(--panel);
  border: 1px solid var(--line); border-radius: 8px; box-shadow: 0 8px 24px rgb(0 0 0 / 0.4); }
.wf-menu button { all: unset; padding: 0.4rem 0.7rem; border-radius: 5px; cursor: pointer; color: var(--text); }
.wf-menu button:hover, .wf-menu button:focus { background: var(--bg); }
.wf-ghost { position: fixed; z-index: 40; pointer-events: none; transform: translate(8px, 8px); padding: 0.5rem 0.8rem;
  background: var(--panel); border: 1px dashed var(--accent); border-radius: 8px; color: var(--text); opacity: 0.9; }
.node-form fieldset { gap: 0.3rem; }

/* A node's name sits just above it on the canvas. */
.wf-node { position: relative; }
.wf-node .wf-name { position: absolute; left: -0.95rem; bottom: calc(100% + 0.85rem); white-space: nowrap; font-size: 0.85rem;
  font-weight: 600; color: var(--text); max-width: 20rem; overflow: hidden; text-overflow: ellipsis; }
.wf-node .wf-title { font-size: 0.8rem; font-weight: 500; color: var(--muted); text-transform: uppercase; letter-spacing: 0.04em; }

form.routes { gap: 1rem; align-items: center; margin-top: 0.8rem; }
form.routes .dot { margin-left: 0; }
ol.results { padding-left: 1.2rem; }
ol.results li { margin: 0.6rem 0; overflow-wrap: anywhere; }
.wf-wrap { position: relative; }
.wf-fit { position: absolute; top: 0.6rem; right: 0.6rem; z-index: 3; padding: 0.3rem 0.8rem; }
.step-form { width: min(46rem, 88vw); }
.step-form textarea { width: 100%; }
details.tags summary { cursor: pointer; color: var(--muted); font-size: 0.9rem; }
details.tags dl { display: grid; grid-template-columns: max-content 1fr; gap: 0.15rem 0.8rem; margin: 0.4rem 0 0; font-size: 0.88rem; }
details.tags dd { margin: 0; color: var(--muted); }
details.tags dt.field { padding-left: 1.4rem; }
details.tags .auto { font-size: 0.72rem; border: 1px solid var(--line); border-radius: 4px; padding: 0 0.3rem; margin-right: 0.2rem; cursor: help; }
.wf-canvas .drawflow .drawflow-node .output[data-label]::after { content: attr(data-label); position: absolute; left: 18px; top: -3px;
  font-size: 0.75rem; color: var(--muted); white-space: nowrap; pointer-events: none; }
.lbl { display: flex; align-items: baseline; gap: 0.35rem; }
pre.entry { white-space: pre-wrap; background: var(--bg); border: 1px solid var(--line); border-radius: 6px; padding: 0.6rem; max-height: 16rem; overflow: auto; }
.answer { margin-bottom: 0.8rem; }
ol.transcript { list-style: none; padding: 0; margin: 0; display: grid; gap: 0.5rem; }
ol.transcript li { border-left: 3px solid var(--line); padding: 0.2rem 0 0.2rem 0.7rem; }
ol.transcript li.assistant { border-color: var(--accent); }
ol.transcript li.user { border-color: #d29922; }
ol.transcript pre { white-space: pre-wrap; overflow-wrap: anywhere; margin: 0.2rem 0; font-size: 0.85rem; max-height: 24rem; overflow: auto; }
ol.transcript .who { font-size: 0.8rem; color: var(--muted); }
ol.transcript summary { cursor: pointer; color: var(--muted); font-size: 0.85rem; overflow-wrap: anywhere; }
ol.subs { list-style: none; padding: 0; margin: 0; }
ol.pad { list-style: none; padding: 0; margin: 0; display: grid; gap: 0.4rem; }
ol.pad li { border-left: 3px solid var(--line); padding: 0.2rem 0 0.2rem 0.7rem; }
ol.pad li.high { border-color: var(--accent); }
ol.pad pre { white-space: pre-wrap; overflow-wrap: anywhere; margin: 0.2rem 0; font-size: 0.85rem; max-height: 24rem; overflow: auto; }
ol.pad summary { cursor: pointer; overflow-wrap: anywhere; }
ol.transcript .call { font-size: 0.85rem; overflow-wrap: anywhere; }
ul.plan { padding-left: 1.2rem; margin: 0; }
ul.plan li.done, ul.plan li.dropped { color: var(--muted); }
ul.plan li.done::marker { content: "✓ "; }
ul.plan li.dropped { text-decoration: line-through; }
pre.verdict { white-space: pre-wrap; margin: 0; }
ol.steps { list-style: none; padding: 0; margin: 0; display: grid; gap: 0.6rem; }
ol.steps li { border-left: 3px solid var(--line); padding: 0.2rem 0 0.2rem 0.7rem; }
ol.steps li.done { border-color: #2ea043; }
ol.steps li.running { border-color: #d29922; }
ol.steps li.failed { border-color: var(--error); }
ol.steps li.skipped { opacity: 0.6; }
ol.steps .step-head { display: flex; gap: 0.5rem; align-items: baseline; flex-wrap: wrap; }
ol.steps .step-head .dot { margin: 0; }
ol.steps pre { white-space: pre-wrap; overflow-wrap: anywhere; font-size: 0.85rem; max-height: 24rem; overflow: auto; margin: 0.3rem 0 0; }
ol.steps summary { cursor: pointer; color: var(--muted); font-size: 0.85rem; }
fieldset.rules { display: grid; gap: 0.45rem; }
fieldset.rules .rule { display: flex; gap: 0.6rem; align-items: center; flex-wrap: wrap; }
fieldset.rules .rule label.check { min-width: 15rem; }
fieldset.rules .rule input:not([type=checkbox]), fieldset.rules .rule select { flex: 1 1 10rem; width: auto; }
blockquote.request { margin: 0.4rem 0; padding: 0.4rem 0.8rem; border-left: 3px solid #d29922; white-space: pre-wrap; }
ol.steps li.waiting { border-color: #d29922; }
textarea[readonly] { opacity: 0.75; cursor: default; }
.check.sub { margin-left: 1.5rem; }

/* The Pull requests page: its title takes the spare width, and a row's Run opens a small form beside it. */
table.items td.title { width: 100%; min-width: 12rem; }
form.items-filter select { flex: none; width: auto; }
form.items-filter input[type=checkbox] { flex: none; }
form.items-filter label.check { flex: none; white-space: nowrap; }
table.items td.labels { max-width: 14rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
details.runform { position: relative; }
details.runform summary { color: var(--accent); cursor: pointer; }
/* The Run form floats beside its row, so it never squeezes the table. */
form.runform-body { position: absolute; right: 0; top: 1.6rem; z-index: 20; display: flex; align-items: center; gap: 0.6rem;
  white-space: nowrap; padding: 0.6rem 0.8rem; background: var(--panel, #161b22); border: 1px solid var(--line); border-radius: 8px;
  box-shadow: 0 6px 18px rgba(0,0,0,0.35); }
form.runform-body select { width: auto; flex: none; }
