/* Colors are variables so the dark theme (html[data-theme=dark]) only swaps the palette. */
:root {
  color-scheme: light;
  --bg: #fbfcfd; --surface: #fff; --surface-2: #f7f9fb; --surface-3: #f3f5f7; --hover: #f5f7fa;
  --border: #e4e7eb; --border-strong: #cbd2d9; --border-dash: #9fb3c8;
  --text: #1f2933; --text-2: #3e4c59; --text-3: #52606d; --muted: #616e7c; --faint: #7b8794; --ghost: #9aa5b1;
  --primary: #2f80ed; --primary-text: #fff; --primary-soft: #f0f7ff; --primary-soft-2: #e3efff; --focus: #b9d6fb; --sel-ring: #d6e7fd;
  --ok-bg: #e6f4ea; --ok-fg: #1e6b34; --ok-soft: #f0faf3; --ok-line: #a8d5b5; --ok-strong: #1a7f37;
  --info-bg: #e3efff; --info-fg: #1a5fc4; --info-soft: #f3f8fe; --info-line: #a9c8f5;
  --warn-bg: #fff1d6; --warn-fg: #8a5a00; --warn-soft: #fff8e6; --warn-line: #f2a900; --warn-border: #f0d08a; --warn-text: #7a5200;
  --bad-bg: #fde8e7; --bad-fg: #a3201c; --bad-soft: #fdf3f3; --bad-line: #c5221f; --bad-border: #f1c4c3; --bad-text: #8a1c1a; --bad-input: #fffafa;
  --purple-bg: #efe7fb; --purple-fg: #5b34a8; --purple-soft: #f8f4fe; --purple-line: #cdb8f0;
  --neutral-bg: #eef1f4; --neutral-fg: #52606d; --chip: #eef2f7;
  --amber: #b7791f; --prod-bg: #fde8e8; --prod-fg: #b42318;
  --tip-bg: #e8f0fe; --tooltip-bg: #1f2937; --tooltip-fg: #fff;
  --log-bg: #1f2933; --log-fg: #e4e7eb; --toast-bg: #1f2933; --toast-fg: #fff;
  --shadow: rgba(0, 0, 0, .18);
}
html[data-theme=dark] {
  color-scheme: dark;
  --bg: #111418; --surface: #1a1f25; --surface-2: #20262d; --surface-3: #262d35; --hover: #232a32;
  --border: #2e3640; --border-strong: #3d4752; --border-dash: #4a5a6c;
  --text: #e3e8ee; --text-2: #c8d0d9; --text-3: #aab4bf; --muted: #95a0ac; --faint: #84909c; --ghost: #6c7783;
  --primary: #5b9cf5; --primary-text: #0d1117; --primary-soft: #18263a; --primary-soft-2: #1c2f4a; --focus: #2c4a73; --sel-ring: #2a4670;
  --ok-bg: #173523; --ok-fg: #7ed69a; --ok-soft: #142a1c; --ok-line: #2f6a43; --ok-strong: #6fcf8c;
  --info-bg: #1b2f4d; --info-fg: #8dbcff; --info-soft: #162238; --info-line: #335c96;
  --warn-bg: #3a2c10; --warn-fg: #f1c56a; --warn-soft: #2c230f; --warn-line: #c98f12; --warn-border: #6b5220; --warn-text: #f1c56a;
  --bad-bg: #3d1a1a; --bad-fg: #ff9a94; --bad-soft: #2d1616; --bad-line: #e0524d; --bad-border: #6b2a28; --bad-text: #ffaaa5; --bad-input: #2a1717;
  --purple-bg: #2c2245; --purple-fg: #c3a8f5; --purple-soft: #221b36; --purple-line: #54428a;
  --neutral-bg: #2a3139; --neutral-fg: #b3bdc8; --chip: #2a3139;
  --amber: #e0a845; --prod-bg: #3d1a1a; --prod-fg: #ff9a94;
  --tip-bg: #1f3352; --tooltip-bg: #333c47; --tooltip-fg: #f1f4f7;
  --log-bg: #0b0e12; --log-fg: #d7dde4; --toast-bg: #e3e8ee; --toast-fg: #111418;
  --shadow: rgba(0, 0, 0, .5);
}
html[data-theme=dark] .brand img, html[data-theme=dark] .login-logo { filter: brightness(1.15); }

* { box-sizing: border-box; }
[hidden] { display: none !important; }
.req { color: var(--bad-line); margin-left: 2px; font-weight: 700; }
.invalid { border-color: var(--bad-line) !important; background: var(--bad-input) !important; }
.missing { background: var(--bad-soft); border: 1px solid var(--bad-border); border-radius: 6px; padding: 8px 12px; margin: 8px 0; font-size: 13px; color: var(--bad-text); }
.missing ul { margin: 4px 0 0 18px; padding: 0; }
.missing a { color: var(--bad-text); text-decoration: underline; cursor: pointer; }
body { font-family: "Segoe UI", Arial, sans-serif; color: var(--text); margin: 0; background: var(--bg); line-height: 1.45; }
a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }
.top { display: flex; align-items: center; justify-content: space-between; padding: 12px 28px; background: var(--surface); border-bottom: 1px solid var(--border); position: sticky; top: 0; z-index: 5; }
.brandrow { display: flex; align-items: center; gap: 8px; }
.brand { font-weight: 700; color: var(--text); font-size: 18px; display: flex; align-items: center; gap: 8px; }
.brandrow .icon { display: flex; align-items: center; color: var(--text-3); }
.brandrow .icon:hover { color: var(--primary); text-decoration: none; }
.brand:hover { text-decoration: none; }
.brand img { height: 26px; width: auto; }
.brand span { font-weight: 400; color: var(--text-3); }
nav { display: flex; align-items: center; }
nav a, nav button { margin-left: 18px; font-size: 15px; }
nav .me { display: flex; align-items: center; gap: 7px; color: var(--text-2); }
nav .bell { position: relative; color: var(--text-3); display: flex; }
nav .bell .count { position: absolute; top: -7px; right: -10px; background: var(--bad-line); color: #fff; font-size: 11px; border-radius: 9px; padding: 0 5px; line-height: 17px; }
.avatar { display: inline-flex; align-items: center; justify-content: center; border-radius: 50%; color: #fff; font-weight: 600; object-fit: cover; flex: none; vertical-align: middle; }
.profile .pic { display: flex; align-items: center; gap: 18px; margin-bottom: 6px; }
.small-btn { padding: 5px 12px; font-size: 14px; }
label.check { display: flex; align-items: center; gap: 8px; font-weight: 400; }
label.link { display: inline; font-weight: 400; color: var(--primary); cursor: pointer; margin: 0; font-size: inherit; }
input[type=email] { width: 100%; padding: 8px 10px; border: 1px solid var(--border-strong); border-radius: 6px; font: inherit; background: var(--surface); color: var(--text); }
.login-logo { display: block; height: 54px; margin: 4px auto 14px; }
.btn.ms { display: flex; align-items: center; justify-content: center; gap: 10px; background: var(--surface); color: var(--text); border-color: var(--border-strong); margin: 14px 0 4px; }
.btn.ms:hover { text-decoration: none; background: var(--hover); }
.login .or { text-align: center; color: var(--faint); font-size: 13px; margin: 10px 0 0; }
.watch { margin-right: 14px; font-size: 14px; color: var(--faint) !important; font-weight: 400; }
.watch.on { color: var(--amber) !important; }
h2 .watch { margin-left: 10px; }
.checkres { display: flex; gap: 8px; align-items: baseline; font-size: 13px; padding: 5px 9px; margin: 4px 0; border-radius: 6px; background: var(--ok-soft); color: var(--ok-fg); }
.checkres .i { flex: none; width: 14px; text-align: center; }
.checkres button.link { margin-left: 8px; font-size: inherit; white-space: nowrap; }
.checkres.lv-warn { background: var(--warn-soft); color: var(--warn-text); }
.checkres.lv-fail { background: var(--bad-bg); color: var(--bad-text); }
.groupcheck { float: right; margin: -4px 0 6px 12px; max-width: 55%; text-align: right; }
.groupcheck .out { text-align: left; }
.ai-check { display: flex; flex-wrap: wrap; align-items: flex-start; gap: 8px; margin: -2px 0 16px; }
.ai-check[hidden] { display: none; }
.ai-check .out { flex: 1; min-width: 240px; }
h3.ai-sub { margin: 22px 0 10px; padding-bottom: 7px; border-bottom: 1px solid var(--border); font-size: 13px; color: var(--text-2); text-transform: uppercase; letter-spacing: .04em; }
h3.ai-sub:first-of-type { margin-top: 6px; }
h3.ai-sub[hidden] { display: none; }
#preflight:empty { display: none; }
.choices.kind { margin: 18px 0 22px; }
.addrepo { border: 1px dashed var(--border-dash); border-radius: 8px; padding: 4px 14px 2px; margin: 14px 0; background: var(--surface-2); }
.addrepo h3 { margin-top: 10px; }
.toolbar.small { gap: 8px; margin: 10px 0; }
.notes { display: flex; flex-direction: column; gap: 6px; }
.note { display: flex; align-items: flex-start; gap: 10px; background: var(--surface); border: 1px solid var(--border); border-left: 4px solid var(--border-strong); border-radius: 6px; padding: 10px 14px; color: inherit; }
.note .notelink { flex: 1; color: inherit; }
.note:hover { background: var(--hover); }
.note .notelink:hover { text-decoration: none; }
.note input { margin-top: 3px; }
.note.unread { border-left-color: var(--primary); background: var(--info-soft); }
.note.unread .notelink b::after { content: ""; display: inline-block; width: 7px; height: 7px; margin-left: 7px;
  border-radius: 50%; background: currentColor; vertical-align: 2px; opacity: .7; }
.note.waiting { border-left-color: var(--warn-line); }
.note.waiting.unread { background: var(--warn-soft); }
.note.done, .note.delivered { border-left-color: var(--ok-strong); }
.note.done.unread, .note.delivered.unread { background: var(--ok-soft); }
.note.failed { border-left-color: var(--bad-line); }
.note.failed.unread { background: var(--bad-soft); }
.note.production { border-left-color: var(--amber); }
.note.production.unread { background: var(--warn-soft); }
main { max-width: 1400px; margin: 28px auto; padding: 0 24px 60px; }
h1 { font-size: 26px; margin: 0 0 4px; }
/* Field labels, column titles, stat captions and choice names title-case every word. */
th, .stat > span, label:not(.check), label.check > b, summary > b, .choice > b, .choicename { text-transform: capitalize; }
th.nocap { text-transform: none; }
h2 { font-size: 19px; margin: 30px 0 10px; border-bottom: 2px solid var(--border); padding-bottom: 6px; }
.homefoot { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.homefoot #hcount { flex: 1; }
.homefoot label.check { margin: 0; font-weight: 400; }
.homefoot .group-actions button.link { font-size: inherit; }
.sessionlist th.center, .sessionlist td.center { text-align: center; }
details.project-group { margin: 22px 0 4px; }
details.project-group > summary { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; cursor: default;
  font-size: 19px; font-weight: 700; border-bottom: 2px solid var(--border); padding: 8px 2px; list-style: none; }
details.project-group > summary::-webkit-details-marker { display: none; }
details.project-group > summary .twist { display: inline-flex; align-items: center; justify-content: center;
  width: 28px; height: 28px; margin: -4px 2px -4px -4px; padding: 0; border: 0; background: none; border-radius: 4px; cursor: pointer; flex: none; }
details.project-group > summary .twist:hover { background: var(--surface-2); }
details.project-group > summary .twist::before { content: ""; width: 0; height: 0;
  border-left: 6px solid var(--text-3); border-top: 5px solid transparent; border-bottom: 5px solid transparent; }
details.project-group[open] > summary .twist::before { border-left: 5px solid transparent; border-right: 5px solid transparent;
  border-top: 6px solid var(--text-3); border-bottom: 0; }
details.project-group > summary .pname { color: var(--text); }
details.project-group > summary a.openproj { display: inline-flex; align-items: center; color: var(--text-3); padding: 3px 4px; border-radius: 4px; line-height: 0; }
details.project-group > summary a.openproj:hover { color: var(--primary); background: var(--surface); }
details.project-group > summary .muted, details.project-group > summary .watch { font-weight: 400; font-size: 14px; }
details.project-group .sessionlist { margin-top: 8px; }
details.project-group > summary a.newinproj { margin-left: auto; display: inline-flex; align-items: center; justify-content: center;
  width: 26px; height: 26px; border-radius: 6px; font-size: 20px; font-weight: 400; line-height: 1; color: var(--text-3); text-decoration: none; }
details.project-group > summary a.newinproj:hover { color: var(--primary); background: var(--surface-2); }
h3 { font-size: 16px; margin: 20px 0 8px; }
.sub, .muted { color: var(--muted); }
.crumbs { font-size: 13px; font-weight: 400; margin: 0 0 4px; }
.crumbs a { color: var(--text-3); }
.crumbs a:hover { color: var(--primary); }
.crumbs .sep { margin: 0 7px; color: var(--ghost); }
.listbar { margin: 8px 0; }
.listbar input[type="search"] { max-width: 360px; }
.listpage { display: flex; justify-content: center; align-items: center; gap: 14px; flex-wrap: wrap; margin: 10px 0 18px; font-size: 13px; color: var(--muted); }
.listpage .page { font-size: 18px; line-height: 1; min-width: 1.2em; }
.listpage .sizes { display: inline-flex; align-items: center; gap: 6px; }
.listpage .sizes b { color: var(--text); }
.listpage .sep { color: var(--ghost); }
tr[hidden] { display: none; }
.muted { font-size: 14px; }
.card { background: var(--surface); border: 1px solid var(--border); border-radius: 8px; padding: 16px 18px; margin: 12px 0; }
.row { display: flex; gap: 16px; flex-wrap: wrap; }
.row > * { flex: 1 1 260px; }
label { display: block; font-weight: 600; font-size: 14px; margin: 12px 0 4px; }
label .muted { font-weight: 400; }
input[type=text], input[type=search], input[type=password], input[type=number], input[type=url], select, textarea {
  width: 100%; padding: 8px 10px; border: 1px solid var(--border-strong); border-radius: 6px; font: inherit; background: var(--surface); color: var(--text); }
textarea { min-height: 70px; font-family: Consolas, monospace; font-size: 13px; }
input:focus, select:focus, textarea:focus { outline: 2px solid var(--focus); border-color: var(--primary); }
/* Browser autofill and password styling must not hide the typed text, dots or caret on the dark theme. */
input { caret-color: var(--text); -webkit-text-fill-color: var(--text); }
input::placeholder { -webkit-text-fill-color: var(--muted); color: var(--muted); }
input[type=password] { letter-spacing: .12em; }
input:-webkit-autofill, input:-webkit-autofill:hover, input:-webkit-autofill:focus {
  -webkit-text-fill-color: var(--text); caret-color: var(--text);
  -webkit-box-shadow: 0 0 0 1000px var(--surface) inset; box-shadow: 0 0 0 1000px var(--surface) inset;
  transition: background-color 9999s ease-out 0s; }
input::-ms-reveal, input::-ms-clear { display: none; }
#shortcode, #setcode { text-transform: uppercase; letter-spacing: .06em; }
#srcbranch[readonly], #tgtbranch[readonly] { cursor: text; }
input.locked { background: var(--surface-3); }
.help { color: var(--muted); font-size: 13px; margin-top: 3px; }
button, .btn { font: inherit; padding: 8px 16px; border-radius: 6px; border: 1px solid var(--primary); background: var(--primary); color: var(--primary-text); cursor: pointer; }
button.secondary, .btn.secondary { background: var(--surface); color: var(--primary); }
button.danger { background: var(--surface); color: var(--bad-line); border-color: var(--bad-border); }
button.link { background: none; border: none; color: var(--primary); padding: 0; }
button:disabled, input:disabled, select:disabled { opacity: .5; cursor: default; }
.choices { display: flex; gap: 10px; flex-wrap: wrap; }
.choice { flex: 1 1 200px; border: 1px solid var(--border-strong); border-radius: 8px; padding: 10px 12px; cursor: pointer; background: var(--surface); }
.choice.on { border-color: var(--primary); background: var(--primary-soft); }
.choice b { display: block; }
.choice span { font-size: 13px; color: var(--text-3); }
table { border-collapse: collapse; width: 100%; font-size: 14px; background: var(--surface); }
th, td { text-align: left; padding: 7px 9px; border-bottom: 1px solid var(--border); vertical-align: top; }
th { background: var(--surface-2); position: sticky; top: 57px; z-index: 1; }
th.sortable { cursor: pointer; user-select: none; }
th.sortable:hover { color: var(--primary); }
th.sort-asc::after { content: " \25B2"; font-size: 9px; }
th.sort-desc::after { content: " \25BC"; font-size: 9px; }
td.num, th.num { text-align: right; white-space: nowrap; }
#anatable tbody tr:hover td { background: var(--hover); }
#anatable tbody tr.sel td { background: var(--primary-soft); }
.pill { display: inline-block; font-size: 12px; font-weight: 600; padding: 1px 8px; border-radius: 10px; background: var(--neutral-bg); color: var(--text-2); white-space: nowrap; }
.pill.done { background: var(--ok-bg); color: var(--ok-fg); }
.pill.running { background: var(--info-bg); color: var(--info-fg); }
.pill.queued { background: var(--neutral-bg); color: var(--neutral-fg); }
.pill.waiting { background: var(--warn-bg); color: var(--warn-fg); }
.pill.failed { background: var(--bad-bg); color: var(--bad-fg); }
.pill.stopped { background: var(--warn-bg); color: var(--warn-fg); }
.pill.future, .pill.pending { background: var(--hover); color: var(--ghost); }
.pill.ai { background: var(--ok-bg); color: var(--ok-fg); }
.steps { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 8px; margin: 14px 0; }
.step { border: 1px solid var(--border); border-left-width: 4px; border-radius: 8px; padding: 9px 11px; background: var(--surface); cursor: pointer; }
.step.sel { box-shadow: 0 0 0 2px var(--sel-ring); }
.step.future, .step.locked { opacity: .55; cursor: default; }
.step .t { font-weight: 600; font-size: 14px; }
/* The whole step card takes its status color; the stronger left edge keeps it readable at a glance. */
.step.st-done { background: var(--ok-soft); border-color: var(--ok-line); border-left-color: var(--ok-fg); }
.step.st-running { background: var(--info-soft); border-color: var(--info-line); border-left-color: var(--info-fg); }
.step.st-queued { background: var(--surface-2); border-color: var(--border-strong); border-left-color: var(--neutral-fg); }
.step.st-waiting { background: var(--warn-soft); border-color: var(--warn-border); border-left-color: var(--warn-line); }
.step.st-failed { background: var(--bad-soft); border-color: var(--bad-border); border-left-color: var(--bad-line); }
.step.st-pending, .step.st-skipped, .step.st-future, .step.st-superseded { background: var(--surface); border-left-color: var(--border-strong); }
.step.st-done .pill.done, .step.st-waiting .pill.waiting, .step.st-failed .pill.failed, .step.st-running .pill.running { background: var(--surface); }
.step.sel.st-done { box-shadow: 0 0 0 2px var(--ok-line); }
.step.sel.st-waiting { box-shadow: 0 0 0 2px var(--warn-line); }
.step.sel.st-failed { box-shadow: 0 0 0 2px var(--bad-line); }
.step.sel.st-running { box-shadow: 0 0 0 2px var(--info-line); }
.logwrap { position: relative; margin-bottom: 8px; }
.log { background: var(--log-bg); color: var(--log-fg); font-family: Consolas, monospace; font-size: 12.5px; padding: 12px 14px 18px; border-radius: 8px; height: 480px; overflow: auto; white-space: pre-wrap; }
.logresize { position: absolute; left: 0; right: 16px; bottom: 0; height: 18px; cursor: ns-resize; touch-action: none; }
.logresize::after { content: ""; display: block; width: 46px; height: 4px; margin: 8px auto 0; border-radius: 4px; background: var(--border-strong); }
.logresize:hover::after, .logresize:focus-visible::after { background: var(--primary); }
.notice { background: var(--primary-soft); border-left: 5px solid var(--primary); padding: 12px 16px; border-radius: 4px; margin: 12px 0; }
.warn { background: var(--warn-soft); border-left: 5px solid var(--warn-line); padding: 12px 16px; border-radius: 4px; margin: 12px 0; }
.error { background: var(--bad-bg); border-left: 5px solid var(--bad-line); padding: 12px 16px; border-radius: 4px; margin: 12px 0; }
.stats { display: flex; flex-wrap: wrap; gap: 12px; margin: 12px 0; }
.stat { flex: 1 1 140px; background: var(--surface); border: 1px solid var(--border); border-radius: 6px; padding: 10px 12px; }
.stat b { display: block; font-size: 22px; color: var(--primary); }
.stat span { color: var(--text-3); font-size: 13px; }
.tabs { display: flex; gap: 4px; flex-wrap: wrap; border-bottom: 1px solid var(--border); margin: 16px 0; }
.tabs a { padding: 8px 14px; border-radius: 6px 6px 0 0; color: var(--text-3); }
.tabs a.on { background: var(--surface); border: 1px solid var(--border); border-bottom-color: var(--surface); margin-bottom: -1px; color: var(--text); font-weight: 600; }
.filters { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin: 10px 0; }
.filters input, .filters select { width: auto; }
.toolbar { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin: 12px 0; }
.sessionlist td { vertical-align: middle; }
.table-scroll { width: 100%; overflow-x: auto; }
.table-scroll table { min-width: 700px; }
.table-scroll th { position: static; }
.homefilters { padding: 12px 14px; }
.homefilters .filters { margin: 10px 0 6px; }
.homefilters .filters label { margin: 0; font-weight: 400; }
.filters .sortpair, .filters details.more { display: inline-flex; align-items: center; gap: 8px; margin-left: auto; }
h2 .small { font-weight: 400; }
.bar { height: 8px; background: var(--border); border-radius: 4px; overflow: hidden; margin-top: 6px; }
.bar div { height: 100%; background: var(--primary); }
#toast { position: fixed; bottom: 42px; right: 20px; background: var(--toast-bg); color: var(--toast-fg); padding: 10px 16px; border-radius: 6px; display: none; max-width: 420px; z-index: 10; }
#app-version { position: fixed; right: 10px; bottom: 7px; z-index: 9; padding: 2px 6px;
  color: var(--text-3); background: color-mix(in srgb, var(--surface) 88%, transparent);
  border-radius: 4px; font-size: 10px; text-decoration: none; opacity: .72; }
#app-version:hover { color: var(--primary); opacity: 1; }
.edited { color: var(--warn-fg); font-size: 12px; }
.tip { display: inline-flex; align-items: center; justify-content: center; width: 16px; height: 16px; margin-left: 5px;
  border-radius: 50%; background: var(--tip-bg); color: var(--primary); font-size: 11px; font-weight: 700; cursor: help;
  position: relative; vertical-align: middle; }
.tip:hover::after, .tip:focus::after { content: attr(data-tip); position: absolute; left: 50%; top: 22px; transform: translateX(-50%);
  width: 300px; padding: 8px 10px; border-radius: 6px; background: var(--tooltip-bg); color: var(--tooltip-fg); font-size: 12px; font-weight: 400;
  line-height: 1.45; white-space: pre-line; text-align: left; z-index: 50; box-shadow: 0 4px 14px var(--shadow); }
.field { margin-bottom: 14px; }
.timechart { display: flex; height: 32px; border-radius: 6px; overflow: hidden; margin: 4px 0 10px; background: var(--surface-2); }
.timechunk { display: flex; align-items: center; justify-content: center; min-width: 4px; overflow: hidden; color: #fff; font-size: 11px; font-weight: 600; }
.timechunk span { padding: 0 6px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.timechunk.c1, .timelegend i.c1 { background: #3d7ec8; }
.timechunk.c2, .timelegend i.c2 { background: #2f9e6b; }
.timechunk.c3, .timelegend i.c3 { background: #c9842a; }
.timechunk.c4, .timelegend i.c4 { background: #7b6cc4; }
.timechunk.c5, .timelegend i.c5 { background: #c45b7a; }
.timechunk.c6, .timelegend i.c6 { background: #3aa0b8; }
.timelegend { display: flex; flex-wrap: wrap; gap: 6px 16px; align-items: baseline; margin: 0 0 12px; font-size: 13px; }
.timelegend i { display: inline-block; width: 10px; height: 10px; border-radius: 2px; margin-right: 6px; vertical-align: -1px; }
.timelegend .timetotal { margin-left: auto; }
dialog.rundetails { overflow: auto; }
.card.handover > h3 { margin-bottom: 4px; }
.hrow { display: grid; grid-template-columns: 150px 1fr; gap: 16px; padding: 12px 0; border-top: 1px solid var(--border); }
.card.handover > h3 + .hrow { border-top: 0; }
.hrow-title { font-weight: 600; font-size: 14px; padding-top: 7px; color: var(--text-2); }
.hrow-body > * { margin: 0 0 6px; }
.hrow-body > :last-child { margin-bottom: 0; }
.hrow-line { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; }
.hrow-line .btn, .hrow-line button { margin: 0; }
.hrow-history { border-top: 1px solid var(--border); padding-top: 10px; margin-top: 2px; }
.hrow-history summary { cursor: pointer; color: var(--text-3); }
button.link.danger-link { color: var(--bad-fg); }
@media (max-width: 700px) { .hrow { grid-template-columns: 1fr; gap: 6px; } .hrow-title { padding-top: 0; } }
dialog.rundetails section + section { margin-top: 22px; padding-top: 14px; border-top: 1px solid var(--border); }
dialog.rundetails h3 { margin: 0 0 12px; }
#timing tfoot td { font-weight: 700; border-top: 2px solid var(--border); }
.with-action { display: flex; align-items: center; gap: 10px; }
.with-action > input, .with-action > select { flex: 1; width: auto; min-width: 0; }
.with-action > button { flex: none; white-space: nowrap; }
dialog.pricing { width: min(480px, calc(100vw - 32px)); }
.help.warnline { color: var(--warn-text); }
.connected-row { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin: 10px 0 4px; }
.connected-row .grow { flex: 1; }
#cmodelwrap { margin-top: 10px; }
/* Session AI: a side panel docked on the right that the page makes room for */
:root { --aiw: 420px; }
body.aion { padding-right: var(--aiw); }
body.aion #helppanel { right: var(--aiw); }
#aipanel { position: fixed; top: 0; right: 0; bottom: 0; width: var(--aiw); max-width: 92vw; z-index: 21;
  background: var(--surface); border-left: 1px solid var(--border); display: flex; flex-direction: column; }
#aipanel[hidden] { display: none; }
.aihead { display: flex; align-items: center; gap: 8px; padding: 12px 14px; border-bottom: 1px solid var(--border); }
.aihead b { font-size: 16px; }
.aihead .aisub { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.aihead button { font-size: 18px; color: var(--text-3); }
#aipanel .assistant-turns { flex: 1; max-height: none; padding: 4px 12px; }
.aifoot { border-top: 1px solid var(--border); padding: 8px 12px 10px; }
.aifoot .assistant-modes { margin-top: 0; }
.aifoot textarea { width: 100%; min-height: 74px; margin: 8px 0 6px; resize: vertical; box-sizing: border-box; }
.aifoot .airow { display: flex; align-items: center; gap: 8px; }
.aifoot .airow .grow { flex: 1; }
.aifoot label.aiproj { display: flex; align-items: center; gap: 6px; margin-top: 8px; }
.aifoot label.aiproj input { width: auto; margin: 0; }
.ai-resize { position: absolute; left: -3px; top: 0; bottom: 0; width: 6px; cursor: col-resize; z-index: 1; }
.ai-resize:hover, .ai-resize.drag { background: var(--primary); opacity: .45; }
.assistant-turns { max-height: min(52vh, 520px); overflow: auto; padding: 4px 2px; }
.assistant-user, .assistant-ai { padding: 10px 12px; margin: 8px 0; border-radius: 8px; }
.assistant-user { margin-left: 12%; background: var(--primary-soft); }
.assistant-ai { margin-right: 6%; background: var(--surface-2); border: 1px solid var(--border); }
.assistant-user p, .assistant-ai p { margin: 4px 0; }
.assistant-modes { display: flex; gap: 7px; margin-top: 12px; }
.assistant-modes button.on { background: var(--primary); color: var(--primary-text); }
.assistant-script { margin: 10px 0 2px; padding-top: 9px; border-top: 1px solid var(--border); }
.assistant-script pre { max-height: 220px; overflow: auto; white-space: pre-wrap; }
.assistant-script .ai-save { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.ai-how { padding: 4px 2px; }
.ai-how ol { margin: 4px 0 6px; padding-left: 20px; }
.ai-how li { margin: 3px 0; }
.validation-causes details { padding: 7px 0; border-top: 1px solid var(--border); }
.settings-heading { display: flex; gap: 14px; align-items: center; justify-content: space-between; margin: 22px 0 14px; }
dialog.modal { width: min(760px, calc(100vw - 32px)); max-height: calc(100vh - 48px); padding: 18px 20px 8px; border: 1px solid var(--border); border-radius: 10px; background: var(--surface); color: var(--text); box-shadow: 0 16px 50px var(--shadow); }
dialog.modal::backdrop { background: rgba(0, 0, 0, .55); }
dialog.modal .modal-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
dialog.modal .modal-head h2 { margin: 0; }
dialog.modal .modal-close { background: none; border: 0; color: var(--text-3); font-size: 24px; line-height: 1; padding: 0 4px; cursor: pointer; }
dialog.modal .modal-close:hover { color: var(--text); }
dialog.readme-modal { width: min(960px, calc(100vw - 32px)); }
dialog.readme-modal pre { max-height: calc(100vh - 170px); margin: 10px 0 16px; padding: 14px; overflow: auto;
  border: 1px solid var(--border); border-radius: 6px; background: var(--surface-2); color: var(--text);
  white-space: pre-wrap; overflow-wrap: anywhere; font: 13px/1.5 ui-monospace, SFMono-Regular, Consolas, monospace; }
dialog.release-modal { width: min(760px, calc(100vw - 32px)); }
.release-scroll { max-height: calc(100vh - 190px); overflow: auto; padding-right: 8px; }
.release-note { padding: 4px 0 14px; }
.release-note + .release-note { border-top: 1px solid var(--border); padding-top: 14px; }
.release-note h2 { margin-top: 4px; }
.release-note h3 { margin: 18px 0 6px; }
.release-note p, .release-note li { line-height: 1.55; }
.release-history { max-width: 860px; }
.settings-heading h2 { margin: 0; }
.settings-heading .groupcheck { display: flex; gap: 7px; align-items: center; flex: none; }
.settings-check-out { display: grid; gap: 4px; margin-bottom: 14px; }
.settings-check-out:empty { display: none; margin: 0; }
.checkres span { min-width: 0; overflow-wrap: anywhere; }
.refresh-bar { margin-top: 6px; max-width: 480px; }
.refresh-bar .bar { margin-top: 0; }
.bar.busy div { width: 35%; animation: refresh-slide 1.1s ease-in-out infinite; }
.spinner { display: inline-block; width: 11px; height: 11px; margin-right: 6px; vertical-align: -1px;
  border: 2px solid var(--border); border-top-color: var(--primary); border-radius: 50%; animation: spin 0.9s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .spinner { animation-duration: 3s; } }
@keyframes refresh-slide { from { transform: translateX(-120%); } to { transform: translateX(320%); } }
@media (prefers-reduced-motion: reduce) { .bar.busy div { animation: none; width: 100%; opacity: .5; } }
.settings-intro { margin: 8px 0 12px; color: var(--text-2); }
.settings-sections { display: grid; grid-template-columns: 1fr; gap: 14px; }
.settings-section { margin: 0; min-width: 0; }
.settings-section[hidden] { display: none; }
.settings-section h3 { margin: 0 0 15px; padding-bottom: 9px; border-bottom: 1px solid var(--border); font-size: 15px; color: var(--text-2); }
#https-card { margin-top: 18px; padding-top: 12px; border-top: 1px solid var(--border); }
#https-card h4 { margin: 0 0 10px; font-size: 14px; color: var(--text-2); }
.settings-section .field:last-child { margin-bottom: 0; }
.field[hidden] { display: none; }
.help div + div { margin-top: 2px; }
.choice-help { margin: 6px 0 0; padding-left: 18px; font-size: 12px; color: var(--muted); }
.choice-help li.on { color: var(--text); }
.choice-help li.on b::after { content: " (selected)"; font-weight: 400; color: var(--primary); }
.auto-note { color: var(--primary); }
label.check { font-weight: 600; display: flex; gap: 6px; align-items: center; }
.chips { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.chip { display: inline-flex; gap: 4px; align-items: center; background: var(--chip); border-radius: 12px; padding: 3px 4px 3px 10px; font-size: 13px; }
.chip button { padding: 0 6px; font-size: 14px; }
.chip-add { width: 160px !important; }
.areas { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 4px 16px; margin-top: 8px; }
.areas[hidden] { display: none; }
details.card summary { cursor: pointer; }
.setup-list { display: grid; grid-template-columns: 130px 1fr; gap: 8px 16px; margin: 0; font-size: 13px; }
.setup-list dt { color: var(--text-3); font-weight: 600; }
.setup-list dd { margin: 0; color: var(--text-2); overflow-wrap: anywhere; }
.next-action { display: flex; align-items: center; gap: 18px; justify-content: space-between; padding: 13px 16px;
  margin: 12px 0; border: 1px solid var(--border-strong); border-left: 5px solid var(--primary); border-radius: 7px; background: var(--surface); }
.next-action > div { min-width: 0; }
.next-action b, .next-action span { display: block; }
.next-action span { color: var(--text-3); font-size: 13px; margin-top: 2px; }
.next-action.waiting { background: var(--warn-soft); border-color: var(--warn-border); border-left-color: var(--warn-line); }
.next-action.failed { background: var(--bad-soft); border-color: var(--bad-border); border-left-color: var(--bad-line); }
.next-action.running { background: var(--info-soft); border-color: var(--info-line); border-left-color: var(--info-fg); }
.next-action.done { background: var(--ok-soft); border-color: var(--ok-line); border-left-color: var(--ok-fg); }
details.more { position: relative; }
details.more > summary { list-style: none; }
details.more > summary::-webkit-details-marker { display: none; }
details.more .menu { position: absolute; right: 0; top: calc(100% + 5px); z-index: 8; min-width: 210px; padding: 8px;
  background: var(--surface); border: 1px solid var(--border-strong); border-radius: 7px; }
details.more .menu button { width: 100%; margin: 3px 0; text-align: left; }
.roles { font-size: 12px; color: var(--muted); }
.logbar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-top: 18px; }
.logbar h3 { margin: 0; }
.logbar input[type=text] { width: 200px; padding: 4px 8px; font-size: 12px; }
.logbar label { font-weight: 400; margin: 0; }
.live { color: var(--ok-strong); }
.live::before { content: "● "; }
.pill.prod { background: var(--prod-bg); color: var(--prod-fg); }
.stat.click { cursor: pointer; }
.stat.click.on { outline: 2px solid var(--primary); }
.provide { display: grid; gap: 4px; margin-top: 6px; }
.provide input { font-size: 12px; padding: 4px 6px; }
.small { font-size: 12.5px; }
code { font-family: Consolas, monospace; font-size: 13px; background: var(--surface-3); padding: 1px 4px; border-radius: 3px; }
pre { background: var(--surface-3); padding: 8px 10px; border-radius: 6px; overflow: auto; }
#ainotes pre { white-space: pre-wrap; }
.pill.analysis { background: var(--purple-bg); color: var(--purple-fg); }
.pill.skipped { background: var(--hover); color: var(--ghost); }
a.plain { color: inherit; }
a.plain:hover { color: var(--primary); }
.carried { font-size: 12px; color: var(--text-2); }
.cleanrules { margin-top: 8px; display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 4px 18px; }
.cleanrule label { margin: 6px 0 0; font-weight: 400; }
.cleanrule .help { margin: 0 0 0 22px; }
input.cleanyears { width: 4.5em !important; padding: 2px 6px; display: inline-block; }
table.scripts td { vertical-align: top; }
td.nowrap { white-space: nowrap; }
textarea.scriptbody { min-height: 320px; margin-top: 10px; tab-size: 4; white-space: pre; }

/* A person: picture (when set) to the left of "First Last" */
.person { display: inline-flex; align-items: center; gap: 5px; vertical-align: middle; white-space: nowrap; }
.person .avatar { font-size: 9px; }

/* Top bar icons and the help side panel */
nav .icon { display: flex; align-items: center; color: var(--text-3); }
nav .icon:hover, nav .icon.on { color: var(--primary); text-decoration: none; }
nav button.icon { padding: 0; }
#helppanel { position: fixed; top: 57px; right: 0; bottom: 0; width: 390px; max-width: 92vw; z-index: 20;
  background: var(--surface); border-left: 1px solid var(--border); box-shadow: -6px 0 18px var(--shadow);
  display: flex; flex-direction: column; transform: translateX(105%); transition: transform .22s ease; visibility: hidden; }
#helppanel.open { transform: none; visibility: visible; }
.helphead { display: flex; align-items: center; justify-content: space-between; padding: 14px 18px; border-bottom: 1px solid var(--border); font-size: 17px; }
.helphead button { font-size: 18px; color: var(--text-3); }
.helpbody { padding: 6px 18px 14px; overflow-y: auto; flex: 1; font-size: 14px; }
.helpbody h3 { font-size: 15px; margin: 18px 0 6px; }
.helpbody ul, .helpbody ol { padding-left: 20px; margin: 6px 0; }
.helpbody li { margin: 4px 0; }
.helpbody .pill { font-size: 11px; }
.helpsteps dt { font-weight: 600; margin-top: 10px; }
.helpsteps dd { margin: 2px 0 0 0; color: var(--text-2); }
.helpfoot { padding: 10px 18px; border-top: 1px solid var(--border); }
@media (max-width: 800px) {
  #app table:not(.sessionlist) { display: block; overflow-x: auto; }
  .next-action { align-items: stretch; flex-direction: column; gap: 10px; }
  .next-action button { width: 100%; }
}
@media (prefers-reduced-motion: reduce) { #helppanel { transition: none; } }
@media (max-width: 900px) { body.aion { padding-right: 0; } body.aion #helppanel { right: 0; z-index: 22; } }

/* Theme choice on the profile page */
.themes { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 6px; }
.themes .choice { flex: 0 1 180px; display: flex; align-items: center; gap: 10px; }
.swatch { width: 34px; height: 24px; border-radius: 5px; border: 1px solid var(--border-strong); flex: none; }
.swatch.light { background: linear-gradient(135deg, #fff 50%, #e3efff 50%); }
.swatch.dark { background: linear-gradient(135deg, #1a1f25 50%, #1c2f4a 50%); }
.swatch.system { background: linear-gradient(135deg, #fff 50%, #1a1f25 50%); }

/* Server page */
.gauges { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 12px; margin: 12px 0; }
.gauge { background: var(--surface); border: 1px solid var(--border); border-radius: 8px; padding: 12px 14px; }
.gauge .v { font-size: 24px; font-weight: 700; }
.gauge .l { color: var(--text-3); font-size: 13px; }
.gauge .d { color: var(--muted); font-size: 12px; margin-top: 2px; }
.gauge .bar { height: 7px; }
/* Health gauges take a status color like the step cards: green fine, amber getting full, red at the limit. */
.gauge.ok { background: var(--ok-soft); border-color: var(--ok-line); border-left: 4px solid var(--ok-fg); }
.gauge.warm { background: var(--warn-soft); border-color: var(--warn-border); border-left: 4px solid var(--warn-line); }
.gauge.hot { background: var(--bad-soft); border-color: var(--bad-border); border-left: 4px solid var(--bad-line); }
.gauge.ok .v { color: var(--ok-fg); }
.gauge.warm .v { color: var(--warn-fg); }
.gauge.hot .v { color: var(--bad-fg); }
.gauge.ok .bar div, .meter.ok div { background: var(--ok-fg); }
.gauge.hot .bar div, .meter.hot div { background: var(--bad-line); }
.gauge.warm .bar div, .meter.warm div { background: var(--warn-line); }
.gauge.ok svg polyline { stroke: var(--ok-fg); }
.gauge.ok svg polygon { fill: var(--ok-bg); }
.gauge.warm svg polyline { stroke: var(--warn-line); }
.gauge.warm svg polygon { fill: var(--warn-bg); }
.gauge.hot svg polyline { stroke: var(--bad-line); }
.gauge.hot svg polygon { fill: var(--bad-bg); }
.gauge svg { display: block; width: 100%; height: 38px; margin-top: 8px; }
.gauge svg polyline { fill: none; stroke: var(--primary); stroke-width: 1.5; vector-effect: non-scaling-stroke; }
.gauge svg polygon { fill: var(--primary-soft-2); stroke: none; }
.meter { height: 6px; background: var(--border); border-radius: 3px; overflow: hidden; min-width: 70px; margin-top: 3px; }
.meter div { height: 100%; background: var(--primary); }
table.server td { vertical-align: middle; }
tr.hot td { background: var(--bad-soft); }
tr.warm td { background: var(--warn-soft); }
tr.dim td { color: var(--ghost); }
.role { font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: .04em; color: var(--text-3); }

/* end of a session */
.folds { margin: 12px 0; }
details.fold { background: var(--surface); border: 1px solid var(--border); border-radius: 8px; margin: 8px 0; }
details.fold > summary { cursor: pointer; padding: 10px 14px; display: flex; gap: 10px; align-items: center; }
details.fold > summary .pill { margin-left: auto; }
details.fold[open] > summary { border-bottom: 1px solid var(--border); }
.foldbody { padding: 4px 16px 10px; }
.card .foldbody { padding: 4px 0 6px; }
.card details.fold { border: none; background: none; margin: 4px 0; }
.card details.fold > summary { padding: 6px 0; color: var(--primary); }
.card details.fold[open] > summary { border-bottom: none; }
.card h3 { margin-top: 0; }
.card h4 { font-size: 14px; margin: 18px 0 6px; color: var(--text-2); text-transform: uppercase; letter-spacing: .04em; }
.card h4:first-of-type { margin-top: 6px; }
.finish-ok { border-left: 4px solid var(--ok-fg); background: var(--ok-soft); }
.creds { background: var(--surface-2); border: 1px solid var(--border); border-radius: 6px; padding: 8px 12px; display: inline-flex; flex-wrap: wrap; gap: 6px 22px; font-size: 14px; }
.creds > span { display: inline-flex; align-items: center; gap: 6px; }
button.copy, button.eye, button.rowicon { background: none; border: 1px solid transparent; color: var(--text-3); padding: 3px 4px; line-height: 0; border-radius: 4px; vertical-align: middle; }
button.copy:hover, button.eye:hover, button.eye.on, button.rowicon:hover { color: var(--primary); border-color: var(--border); background: var(--surface); }
button.rowicon.del:hover { color: var(--bad-line); border-color: var(--bad-border); }
button.rowicon + button.rowicon { margin-left: 2px; }
.pwrow { display: flex; gap: 8px; align-items: center; }
.pwrow .secret { flex: 1; }
.pwrow > button { flex: none; }
.secret { position: relative; display: block; }
.secret > button.eye { position: absolute; right: 6px; top: 50%; transform: translateY(-50%); border-color: transparent; background: none; }
.secret > button.eye:hover, .secret > button.eye.on { background: var(--surface-2); }
.secret input { padding-right: 34px; }
a.btn { display: inline-block; text-decoration: none; }
a.btn:hover { text-decoration: none; filter: brightness(1.05); }
table.valtable th, table.mini th { position: static; }
table.valtable td { vertical-align: top; }
table.valtable .ask-cell { text-align: right; white-space: nowrap; width: 1%; text-transform: none; }
table.mini { font-size: 13px; margin: 6px 0 4px; }
table.mini td, table.mini th { padding: 4px 8px; }
.nowrap { white-space: nowrap; }
details > summary.small, .valtable details > summary { cursor: pointer; color: var(--primary); }
table.hide-est .estcol { display: none; }
/* Code changes, laid out like a GitHub pull request */
.gh-changes > summary { cursor: pointer; }
.foldbody > .gh-changes { margin: 4px 0 6px; padding: 0; border-radius: 8px; background: var(--surface-2, transparent); }
.foldbody > .gh-changes > summary { padding: 9px 12px; }
.foldbody > .gh-changes[open] > summary { border-bottom: 1px solid var(--border); }
.foldbody > .gh-changes > :not(summary) { margin-left: 12px; margin-right: 12px; }
.foldbody > .gh-changes > :last-child { margin-bottom: 12px; }
.gh-toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 10px 0; }
.gh-toolbar .gh-filter { width: 240px; margin: 0; }
.gh-toolbar .gh-note-sum { flex: 1; min-width: 160px; }
.gh-layout { display: grid; grid-template-columns: var(--gh-tree, 280px) 12px minmax(0, 1fr); height: var(--gh-h, 75vh); min-height: 240px; }
.gh-tree, .gh-files { height: 100%; overflow: auto; box-sizing: border-box; }
.gh-vresize { cursor: col-resize; position: relative; }
.gh-vresize::after { content: ""; position: absolute; left: 5px; top: 0; bottom: 0; width: 2px; border-radius: 2px; }
.gh-vresize:hover::after, .gh-vresize.drag::after { background: var(--primary); }
.gh-hresize { height: 10px; margin-top: 4px; cursor: row-resize; position: relative; }
.gh-hresize::after { content: ""; position: absolute; left: 50%; top: 3px; width: 46px; height: 4px; margin-left: -23px; border-radius: 3px; background: var(--border); }
.gh-hresize:hover::after, .gh-hresize.drag::after { background: var(--primary); left: 0; width: 100%; margin-left: 0; }
.gh-popout { display: inline-flex; align-items: center; gap: 5px; }
.gh-full { margin-top: 12px; }
.gh-full > summary { pointer-events: none; }
.gh-gitbar:empty { display: none; }
.gh-gitbar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 10px 0 0; padding: 8px 10px; border: 1px solid var(--border); border-radius: 6px; background: var(--surface-2); font-size: 13px; }
.gh-gitbar .gh-gitinfo { flex: 1; min-width: 220px; }
.gh-gitbar code { font-size: 12px; }
dialog.publish-modal { width: min(820px, calc(100vw - 32px)); }
.publish-modal #pub-title, .publish-modal textarea { width: 100%; box-sizing: border-box; }
.publish-modal textarea.pr-body { min-height: 300px; font-family: ui-monospace, Consolas, monospace; font-size: 12.5px; }
.publish-modal textarea.commit-msg { min-height: 130px; font-family: ui-monospace, Consolas, monospace; font-size: 12.5px; }
.publish-modal .pubsteps { margin: 6px 0 0; padding-left: 20px; }
.publish-modal label.inline { display: flex; align-items: center; gap: 7px; margin: 8px 0; }
.publish-modal label.inline input { width: auto; margin: 0; }
.gh-tree { border: 1px solid var(--border); border-radius: 6px; background: var(--surface); padding: 4px 0; font-size: 13px; }
.gh-row { display: flex; align-items: center; gap: 6px; width: 100%; text-align: left; background: none; color: var(--text); border: 0; border-radius: 0; padding: 4px 8px; font-size: 13px; font-weight: 400; line-height: 1.4; }
.gh-row:hover { background: var(--hover); }
.gh-row.on { background: var(--primary-soft); box-shadow: inset 2px 0 0 var(--primary); }
.gh-chev { flex: none; display: inline-flex; width: 12px; color: var(--muted); transition: transform .12s; }
.gh-chev.blank { visibility: hidden; }
.gh-dir.shut > .gh-row .gh-chev { transform: rotate(-90deg); }
.gh-dir.shut > .gh-children { display: none; }
.gh-ico { flex: none; display: inline-flex; color: var(--muted); }
.gh-ico.dir { color: var(--info-fg); }
.gh-label { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gh-tfile.viewed .gh-label { color: var(--muted); }
.gh-tfile.viewed .gh-ico { color: var(--ok-strong); }
.gh-st { flex: none; display: inline-flex; align-items: center; justify-content: center; min-width: 16px; height: 16px; border-radius: 3px; font-size: 10px; font-weight: 700; color: var(--neutral-fg); background: var(--neutral-bg); }
.gh-st.st-A { color: var(--ok-fg); background: var(--ok-bg); }
.gh-st.st-D { color: var(--bad-fg); background: var(--bad-bg); }
.gh-st.st-M, .gh-st.st-R { color: var(--warn-fg); background: var(--warn-bg); }
.gh-files { display: flex; flex-direction: column; gap: 12px; padding-right: 2px; }
.gh-card { border: 1px solid var(--border); border-radius: 6px; background: var(--surface); transition: box-shadow .3s; }
.gh-card.flash { box-shadow: 0 0 0 2px var(--focus); }
.gh-head { position: sticky; top: 0; z-index: 1; display: flex; align-items: center; gap: 8px; padding: 6px 10px; background: var(--surface-2); border-bottom: 1px solid var(--border); border-radius: 6px 6px 0 0; font-size: 13px; }
.gh-card.shut .gh-head { border-bottom: 0; border-radius: 6px; }
.gh-fold { flex: none; display: inline-flex; padding: 2px; background: none; border: 0; color: var(--muted); }
.gh-fold svg { transition: transform .12s; }
.gh-card.shut .gh-fold svg { transform: rotate(-90deg); }
.gh-path { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: 12px; cursor: pointer; }
.gh-copy { flex: none; display: inline-flex; padding: 2px; background: none; border: 0; color: var(--muted); }
.gh-copy:hover, .gh-fold:hover { color: var(--text); }
.gh-counts { flex: none; display: inline-flex; align-items: center; gap: 4px; font-size: 12px; font-weight: 600; }
.gh-counts .a { color: var(--ok-strong); }
.gh-counts .d { color: var(--bad-line); }
.gh-blocks { display: inline-flex; gap: 1px; margin-left: 4px; }
.gh-blocks i { width: 8px; height: 8px; border-radius: 1px; background: var(--bad-line); }
.gh-blocks i.a { background: var(--ok-strong); }
.gh-viewed { flex: none; display: inline-flex; align-items: center; gap: 4px; margin: 0; padding: 2px 8px; border: 1px solid var(--border-strong); border-radius: 6px; font-size: 12px; font-weight: 500; cursor: pointer; }
.gh-card.viewed .gh-viewed { background: var(--primary-soft); border-color: var(--info-line); }
.gh-viewed input { margin: 0; }
.gh-card.shut .gh-body { display: none; }
.gh-body { overflow-x: auto; }
.gh-empty { margin: 0; padding: 12px; color: var(--muted); font-size: 13px; }
.gh-preview { display: flex; flex-wrap: wrap; gap: 16px; padding: 12px; }
.gh-preview figure { margin: 0; }
.gh-preview figcaption { margin-bottom: 4px; color: var(--muted); font-size: 12px; }
.gh-preview img { display: block; max-width: min(420px, 100%); max-height: 320px; border: 1px solid var(--border); border-radius: 4px;
  background: repeating-conic-gradient(#8882 0% 25%, transparent 0% 50%) 0 0 / 16px 16px; }
.gh-table { width: 100%; border-collapse: collapse; font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: 12px; line-height: 20px; }
.gh-table td { padding: 0; border: 0; vertical-align: top; }
.gh-table td.ln { width: 1%; min-width: 44px; padding: 0 8px; text-align: right; color: var(--faint); user-select: none; white-space: nowrap; }
.gh-table td.code { padding-right: 12px; white-space: pre; }
.gh-table .sign { display: inline-block; width: 18px; padding-left: 6px; user-select: none; }
.gh-table tr.gh-add td { background: var(--ok-soft); }
.gh-table tr.gh-add td.ln { background: var(--ok-bg); }
.gh-table tr.gh-del td { background: var(--bad-soft); }
.gh-table tr.gh-del td.ln { background: var(--bad-bg); }
.gh-table tr.gh-hunk td { background: var(--info-soft); color: var(--info-fg); padding-top: 2px; padding-bottom: 2px; }
.gh-table tr.gh-note td { color: var(--muted); font-style: italic; }
details.more .menu label.small { display: block; padding: 6px 12px; font-weight: 400; }
@media (max-width: 800px) { .gh-layout { grid-template-columns: 1fr; height: auto; } .gh-vresize, .gh-hresize { display: none; } .gh-tree { height: 240px; } .gh-files { height: 70vh; } }

/* One plain answer to "is this migration good?" at the top of Sign Off */
.verdict { margin: 0 0 14px; padding: 14px 16px; border-radius: 8px; border: 1px solid var(--border); border-left-width: 5px; }
.verdict h3 { margin: 0 0 4px; }
.verdict p { margin: 4px 0; }
.verdict ul { margin: 4px 0 6px; padding-left: 20px; }
.verdict .verdict-sub { margin-top: 10px; }
.verdict-blocked { background: var(--bad-soft); border-color: var(--bad-border); border-left-color: var(--bad-line); }
.verdict-blocked h3 { color: var(--bad-text); }
.verdict-review { background: var(--warn-soft); border-color: var(--warn-border); border-left-color: var(--warn-line); }
.verdict-review h3 { color: var(--warn-text); }
.verdict-ready { background: var(--ok-soft); border-color: var(--ok-line); border-left-color: var(--ok-strong); }
.verdict-ready h3 { color: var(--ok-fg); }
