oficina / equipo Public

Clone
git clone https://amadan.net/oficina/equipo

Plain git — no account needed to clone.

Download

Download this file

1<!DOCTYPE html>
2<html lang="en" data-theme="system" data-motion="full" data-live="off">
3<head>
4<meta charset="utf-8">
5<meta name="viewport" content="width=device-width, initial-scale=1">
6<title>Equipo inner screens: tasks, projects, needs you</title>
7<style>
8/* ── Theme tokens, copied from internal/equipo/static/theme.css and
9 tokens.css (day theme). Everything below uses only these. ───────── */
10:root {
11 color-scheme: light dark;
12 --rst-font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
13 --rst-radius: 6px; --rst-radius-sm: 4px; --rst-radius-pill: 999px;
14 --rst-bg: light-dark(#fbfbfc, #0c0d0f);
15 --rst-surface: light-dark(#ffffff, #141518);
16 --rst-surface-2: light-dark(#f3f3f5, #18191d);
17 --rst-line: light-dark(#e6e6ea, #26282e);
18 --rst-line-strong: light-dark(#868691, #71737c);
19 --rst-text: light-dark(#18181b, #ededf0);
20 --rst-text-muted: light-dark(#52525c, #a1a1aa);
21 --rst-text-faint: light-dark(#6b6b75, #8c8c96);
22 --rst-accent: light-dark(#1f56d6, #7aa2ff);
23 --rst-accent-strong: light-dark(color-mix(in srgb, var(--rst-accent) 80%, #000000), color-mix(in srgb, var(--rst-accent) 68.5%, #ffffff));
24 --rst-accent-soft: light-dark(#ecf1ff, #16234a);
25 --rst-on-accent: light-dark(#ffffff, #0c0d0f);
26 --rst-on-accent-fill: #ffffff;
27 --rst-accent-fill: light-dark(#2257df, #2f61e8);
28 --rst-accent-fill-hover: light-dark(#1d4dc8, #2956d0);
29 --rst-accent-fill-edge: light-dark(#153ca0, #1f43a6);
30 --rst-tone-neutral-fg: light-dark(#374151, #c3c9d1);
31 --rst-tone-neutral-bg: light-dark(#eef0f2, #262c34);
32 --rst-tone-positive-fg: light-dark(#166534, #6ee7a8);
33 --rst-tone-positive-bg: light-dark(#dcfce7, #10281c);
34 --rst-tone-warning-fg: light-dark(#854d0e, #f0c46a);
35 --rst-tone-warning-bg: light-dark(#fef3c7, #2c2110);
36 --rst-tone-negative-fg: light-dark(#b91c1c, #f79aa0);
37 --rst-tone-negative-bg: light-dark(#fee2e2, #331819);
38 --rst-shadow-pop: 0 2px 4px light-dark(rgba(16, 24, 40, 0.06), rgba(0, 0, 0, 0.35)), 0 8px 16px -4px light-dark(rgba(16, 24, 40, 0.1), rgba(0, 0, 0, 0.5));
39 --rst-shadow-lift: 0 1px 2px light-dark(rgba(16, 24, 40, 0.08), rgba(0, 0, 0, 0.3));
40 --rst-control-face: light-dark(#ffffff, #141518);
41 --rst-control-face-hover: light-dark(#f7f8fa, #1b1d22);
42 --rst-control-border: light-dark(#d0d4dc, #343843);
43 --rst-control-border-hover: light-dark(#8a8a95, #71737c);
44 --rst-tint-hover: light-dark(color-mix(in srgb, var(--rst-accent) 4.5%, var(--rst-surface)), color-mix(in srgb, var(--rst-accent) 10%, var(--rst-bg)));
45 --rst-tint-press: light-dark(color-mix(in srgb, var(--rst-accent) 8.5%, var(--rst-surface)), color-mix(in srgb, var(--rst-accent) 19%, #000000));
46 --rst-focus-edge: var(--rst-accent);
47 --rst-nav-current-bg: light-dark(#ffffff, #141518);
48 --rst-nav-current-fg: light-dark(#18181b, #ededf0);
49 --rst-title-size: 1.25rem; --rst-title-weight: 600; --rst-title-track: -0.012em;
50 --rst-fs-lg: 1.0625rem; --rst-fs-base: 0.875rem; --rst-fs-sm: 0.78125rem; --rst-fs-xs: 0.71875rem;
51 --rst-sp-1: 0.25rem; --rst-sp-2: 0.5rem; --rst-sp-3: 0.75rem; --rst-sp-4: 1rem; --rst-sp-5: 1.5rem; --rst-sp-6: 2.5rem;
52 --rst-target: 2rem; --rst-tap: 2.75rem;
53 --equipo-ease: cubic-bezier(.22, .8, .24, 1);
54 --equipo-warm: color-mix(in srgb, var(--rst-tone-warning-fg) 85%, var(--rst-tone-warning-bg));
55}
56:root[data-theme="light"] { color-scheme: light; }
57:root[data-theme="dark"] { color-scheme: dark; }
58
59/* ── The mockup page around the frames ───────────────────────────── */
60*, *::before, *::after { box-sizing: border-box; }
61html { background: var(--rst-bg); }
62body { margin: 0; color: var(--rst-text); font: var(--rst-fs-base)/1.5 var(--rst-font); -webkit-font-smoothing: antialiased; }
63a { color: var(--rst-accent); }
64:focus-visible { outline: 2px solid var(--rst-focus-edge); outline-offset: 2px; }
65.page { padding: var(--rst-sp-5) clamp(var(--rst-sp-3), 3vw, var(--rst-sp-6)) var(--rst-sp-6); }
66.intro { max-width: 52rem; margin-block-end: var(--rst-sp-4); }
67.intro h1 { font-size: var(--rst-title-size); font-weight: var(--rst-title-weight); letter-spacing: var(--rst-title-track); margin: 0 0 var(--rst-sp-2); }
68.intro p { margin: 0; color: var(--rst-text-muted); max-width: 70ch; }
69.controls { position: sticky; top: 0; z-index: 5; display: flex; flex-wrap: wrap; align-items: center; gap: var(--rst-sp-2) var(--rst-sp-5); margin: 0 calc(-1 * clamp(var(--rst-sp-3), 3vw, var(--rst-sp-6))) var(--rst-sp-5); padding: var(--rst-sp-2) clamp(var(--rst-sp-3), 3vw, var(--rst-sp-6)); background: color-mix(in srgb, var(--rst-bg) 88%, transparent); backdrop-filter: blur(8px); border-block-end: 1px solid var(--rst-line); }
70.control { display: flex; align-items: center; gap: var(--rst-sp-2); font-size: var(--rst-fs-sm); color: var(--rst-text-muted); }
71.seg { display: inline-flex; gap: 2px; padding: 2px; border: 1px solid var(--rst-control-border); border-radius: var(--rst-radius); background: var(--rst-control-face); }
72.seg button, .replay { font: inherit; font-size: var(--rst-fs-sm); color: var(--rst-text-muted); background: transparent; border: 0; border-radius: var(--rst-radius-sm); padding: .25rem .65rem; cursor: pointer; white-space: nowrap; }
73.seg button[aria-pressed="true"] { background: var(--rst-accent-soft); color: var(--rst-accent); }
74.replay { border: 1px solid var(--rst-control-border); background: var(--rst-control-face); color: var(--rst-text); border-radius: var(--rst-radius); padding: .3rem .8rem; }
75.band { margin-block-start: var(--rst-sp-6); }
76.band > h2 { font-size: var(--rst-fs-base); font-weight: 600; margin: 0 0 var(--rst-sp-1); }
77.band > p { margin: 0 0 var(--rst-sp-4); color: var(--rst-text-muted); font-size: var(--rst-fs-sm); max-width: 70ch; }
78.stage-wrap { position: relative; }
79.stage { inline-size: 1280px; block-size: 860px; transform-origin: 0 0; border: 1px solid var(--rst-line); border-radius: calc(2 * var(--rst-radius)); overflow: hidden; box-shadow: var(--rst-shadow-lift); background: var(--rst-bg); }
80.phones { display: flex; flex-wrap: wrap; gap: var(--rst-sp-5); align-items: flex-start; }
81.phone { inline-size: 390px; block-size: 800px; flex: none; display: flex; flex-direction: column; overflow: hidden; border: 1px solid var(--rst-line); border-radius: 2.25rem; box-shadow: var(--rst-shadow-pop); background: var(--rst-bg);
82 --rst-fs-lg: 1.1875rem; --rst-fs-base: 1rem; --rst-fs-sm: 0.875rem; --rst-fs-xs: 0.8125rem; font-size: var(--rst-fs-base); }
83.phone > .status { flex: none; display: flex; justify-content: space-between; padding: var(--rst-sp-3) var(--rst-sp-5) 0 1.75rem; background: var(--rst-surface); font-size: var(--rst-fs-xs); font-weight: 600; font-variant-numeric: tabular-nums; }
84.phone > header { position: relative; flex: none; display: flex; align-items: center; min-block-size: 2.75rem; padding: var(--rst-sp-2) var(--rst-sp-3); background: var(--rst-surface); border-block-end: 1px solid var(--rst-line); }
85.phone > header .back { display: inline-flex; align-items: center; gap: 2px; color: var(--rst-accent); text-decoration: none; font-size: var(--rst-fs-sm); }
86.phone > header .back svg { inline-size: 1.1em; block-size: 1.1em; transform: rotate(90deg); }
87.phone > header .ptitle { position: absolute; left: 50%; transform: translateX(-50%); font-weight: 600; font-size: var(--rst-fs-sm); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-inline-size: 55%; }
88.phone > .app { flex: 1; min-block-size: 0; overflow-y: auto; }
89.phone .main { padding: var(--rst-sp-4) var(--rst-sp-3) var(--rst-sp-6); }
90.caption { color: var(--rst-text-muted); font-size: var(--rst-fs-sm); margin: var(--rst-sp-2) 0 0; max-inline-size: 390px; }
91
92/* ── The shell: rail and main, as the sidebar shell draws them ───── */
93.shell { display: grid; grid-template-columns: 17rem minmax(0, 1fr); block-size: 100%; }
94.rail { padding: var(--rst-sp-4); border-inline-end: 1px solid var(--rst-line); background: var(--rst-bg); overflow-y: auto; font-size: var(--rst-fs-sm); }
95.brand { display: flex; align-items: center; gap: var(--rst-sp-2); font-weight: 600; margin: 0 0.55rem var(--rst-sp-4); color: var(--rst-text); text-decoration: none; }
96.brand .icon { inline-size: 1em; block-size: 1em; }
97.rail nav a, .rail .spec > summary { display: grid; grid-template-columns: auto minmax(0, 1fr) auto auto; align-items: center; column-gap: var(--rst-sp-2); padding: 0.35rem 0.55rem; border-radius: var(--rst-radius); color: var(--rst-text-muted); text-decoration: none; }
98.rail nav a .icon, .rail .spec .icon { inline-size: 1em; block-size: 1em; }
99.rail nav a > span, .rail .spec > summary > span { min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: var(--rst-text); }
100.rail nav a:hover, .rail .spec > summary:hover { background: var(--rst-tint-hover); }
101.rail nav a[aria-current="page"] { background: var(--rst-nav-current-bg); color: var(--rst-nav-current-fg); box-shadow: 0 0 0 1px var(--rst-line), var(--rst-shadow-lift); }
102.rail .count { font-size: var(--rst-fs-xs); color: var(--rst-text-muted); font-variant-numeric: tabular-nums; }
103.rail .count[data-attention] { color: var(--rst-tone-warning-fg); font-weight: 600; }
104.nav-group { color: var(--rst-text-muted); margin: var(--rst-sp-4) 0 var(--rst-sp-1); padding: 0 0.55rem; font-size: var(--rst-fs-xs); }
105.main { padding: var(--rst-sp-5) var(--rst-sp-6); overflow-y: auto; container: app / inline-size; }
106.stage .main { block-size: 100%; }
107.main h1 { font-size: var(--rst-title-size); font-weight: var(--rst-title-weight); letter-spacing: var(--rst-title-track); margin: 0; }
108.page-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: var(--rst-sp-2) var(--rst-sp-4); margin-block-end: var(--rst-sp-4); }
109.page-head p { margin: 0; color: var(--rst-text-muted); }
110.inner { max-inline-size: 66rem; }
111
112/* ── The living mark: Stardust, scaled to where it sits ──────────── */
113.mark { position: relative; flex: none; display: inline-block; inline-size: 1em; block-size: 1em; vertical-align: -.12em; }
114.mark svg { position: absolute; inset: 0; inline-size: 100%; block-size: 100%; overflow: visible; filter: drop-shadow(0 0 .22em color-mix(in srgb, var(--rst-accent) 55%, transparent)); }
115.mark path { fill: var(--rst-accent); transform-box: fill-box; transform-origin: center; animation: equipo-star 4.2s ease-in-out infinite; }
116.mark circle { fill: var(--rst-on-accent-fill); transform-box: fill-box; transform-origin: center; animation: equipo-glint 2.1s ease-in-out infinite; }
117@keyframes equipo-star { 0% { transform: rotate(0) scale(.8); } 50% { transform: rotate(45deg) scale(1.05); } 100% { transform: rotate(90deg) scale(.8); } }
118@keyframes equipo-glint { 0%, 100% { transform: scale(.75); opacity: .65; } 50% { transform: scale(1.1); opacity: 1; } }
119.mark i { position: absolute; inset-block-start: 50%; inset-inline-start: 50%; opacity: 0; }
120.mark [data-sat] { inset-block-start: auto; inset-inline-start: auto; inline-size: .44em; block-size: .44em; background: var(--rst-accent); clip-path: polygon(50% 0, 61% 39%, 100% 50%, 61% 61%, 50% 100%, 39% 61%, 0 50%, 39% 39%); transform: scale(0); animation: equipo-sat 2.7s ease-in-out .4s infinite; }
121.mark [data-sat="1"] { inset-block-start: -.32em; inset-inline-end: -.38em; }
122.mark [data-sat="2"] { inset-block-end: -.22em; inset-inline-start: -.36em; inline-size: .34em; block-size: .34em; background: color-mix(in srgb, var(--rst-accent) 45%, var(--rst-on-accent-fill)); animation-duration: 3.7s; animation-delay: 1.5s; }
123.mark [data-sat="3"] { inset-block-start: -.45em; inset-inline-start: -.05em; inline-size: .3em; block-size: .3em; animation-duration: 4.3s; animation-delay: 2.6s; }
124@keyframes equipo-sat { 0%, 24%, 100% { opacity: 0; transform: scale(0) rotate(0); } 10% { opacity: 1; transform: scale(1) rotate(45deg); } }
125.mark [data-mote] { inline-size: .26em; block-size: .26em; margin: -.13em; border-radius: 50%; background: var(--rst-accent); box-shadow: 0 0 .25em color-mix(in srgb, var(--rst-accent) 70%, transparent); }
126.mark [data-mote="light"] { background: color-mix(in srgb, var(--rst-accent) 40%, var(--rst-on-accent-fill)); }
127.mark[data-flourish] svg { animation: equipo-half .7s var(--equipo-ease); }
128.mark[data-flourish] [data-mote] { animation: equipo-dust 1.3s ease-out var(--d) both; }
129@keyframes equipo-half { 50% { transform: rotate(90deg) scale(1.28); } 100% { transform: rotate(180deg); } }
130@keyframes equipo-dust { 0% { opacity: 0; transform: translate(0, 0) scale(.6); } 15% { opacity: 1; transform: translate(calc(var(--dx) * .12), calc(var(--dy) * .12)) scale(1.2); } 100% { opacity: 0; transform: translate(var(--dx), var(--dy)) scale(.3); } }
131/* Smaller marks (the rail, a row's track) keep the star and lose the
132 motes, so they never shed dust over neighbouring text. */
133.mark[data-size="s"] { font-size: .85em; }
134.mark[data-size="s"] [data-mote] { display: none; }
135.elapsed { font-variant-numeric: tabular-nums; color: var(--rst-text-muted); }
136
137/* ── Rail: specialist rows with the living mark and a dropdown ───── */
138.spec { margin: 0; }
139.spec > summary { list-style: none; cursor: default; }
140.spec > summary::-webkit-details-marker { display: none; }
141.spec[data-state="working"] > summary { cursor: pointer; }
142.spec .state { display: inline-flex; align-items: center; gap: .4em; font-size: var(--rst-fs-xs); color: var(--rst-text-muted); white-space: nowrap; }
143.spec[data-state="idle"] .state { color: var(--rst-text-faint); }
144.spec .chev { inline-size: 1em; block-size: 1em; color: var(--rst-text-faint); transition: transform .25s var(--equipo-ease); }
145.spec[open] .chev { transform: rotate(180deg); }
146.spec[data-state="idle"] .chev { visibility: hidden; }
147.spec-panel { margin: var(--rst-sp-1) 0.55rem var(--rst-sp-2) calc(0.55rem + 1em + var(--rst-sp-2)); padding: var(--rst-sp-2) var(--rst-sp-3); border: 1px solid var(--rst-line); border-radius: var(--rst-radius); background: color-mix(in oklab, var(--rst-surface), var(--rst-accent-soft) 35%); font-size: var(--rst-fs-xs); color: var(--rst-text-muted); animation: equipo-open .25s var(--equipo-ease); }
148@keyframes equipo-open { from { opacity: 0; transform: translateY(-.25rem); } }
149.spec-panel a.task { display: block; color: var(--rst-text); font-size: var(--rst-fs-sm); font-weight: 500; text-decoration: none; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
150.spec-panel a.task:hover { text-decoration: underline; text-underline-offset: 2px; }
151.spec-panel .where { margin: 2px 0 var(--rst-sp-2); display: flex; flex-wrap: wrap; gap: 0 var(--rst-sp-2); }
152.spec-panel ol { margin: 0; padding: 0; list-style: none; display: grid; gap: 2px; }
153.spec-panel ol li { display: flex; gap: var(--rst-sp-2); align-items: baseline; min-width: 0; color: var(--rst-text-faint); }
154.spec-panel ol li > span:first-child { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
155.spec-panel ol li:last-child { color: var(--rst-text); }
156.spec-panel ol li:last-child > span:first-child { font-weight: 500; }
157.spec-panel ol li[data-new] { animation: equipo-rise .3s ease-out both; }
158@keyframes equipo-rise { from { opacity: 0; transform: translateY(.3em); } }
159.spec-panel .queue { margin: var(--rst-sp-2) 0 0; padding-block-start: var(--rst-sp-2); border-block-start: 1px solid var(--rst-line); }
160.spec-panel .queue a { color: var(--rst-text-muted); }
161
162/* ── Phone index (the rail as drill-down rows) ───────────────────── */
163.index { list-style: none; margin: 0 0 var(--rst-sp-4); padding: 0; border: 1px solid var(--rst-line); border-radius: calc(2 * var(--rst-radius)); background: var(--rst-surface); overflow: hidden; }
164.index li + li { border-block-start: 1px solid var(--rst-line); }
165.index a, .index .spec > summary { display: grid; grid-template-columns: auto minmax(0, 1fr) auto auto; align-items: center; column-gap: var(--rst-sp-3); padding: var(--rst-sp-3); color: var(--rst-text); text-decoration: none; border-radius: 0; }
166.index a:hover, .index .spec > summary:hover { background: var(--rst-tint-hover); }
167.index .icon { inline-size: 1.1em; block-size: 1.1em; color: var(--rst-accent); }
168.index .chev-r { inline-size: 1em; block-size: 1em; color: var(--rst-text-faint); transform: rotate(-90deg); }
169.index .spec-panel { margin: 0 var(--rst-sp-3) var(--rst-sp-3) calc(var(--rst-sp-3) + 1.1em + var(--rst-sp-3)); }
170
171/* ── People and projects ─────────────────────────────────────────── */
172.av { display: inline-grid; place-items: center; flex: none; inline-size: 1.25rem; block-size: 1.25rem; border-radius: 50%; font-size: .6rem; font-weight: 600; letter-spacing: 0; color: light-dark(oklch(0.35 0.08 var(--h)), oklch(0.9 0.06 var(--h))); background: light-dark(oklch(0.92 0.045 var(--h)), oklch(0.32 0.06 var(--h))); box-shadow: inset 0 0 0 1px light-dark(oklch(0.85 0.06 var(--h)), oklch(0.4 0.07 var(--h))); }
173.av[data-size="l"] { inline-size: 2rem; block-size: 2rem; font-size: .85rem; }
174.who { display: inline-flex; align-items: center; gap: .4em; white-space: nowrap; }
175.avs { display: inline-flex; }
176.avs .av + .av { margin-inline-start: -.3rem; box-shadow: 0 0 0 2px var(--rst-surface), inset 0 0 0 1px light-dark(oklch(0.85 0.06 var(--h)), oklch(0.4 0.07 var(--h))); }
177.mono { display: inline-grid; place-items: center; flex: none; inline-size: 1.75rem; block-size: 1.75rem; border-radius: var(--rst-radius); font-weight: 650; font-size: .85rem; color: light-dark(oklch(0.42 0.13 var(--h)), oklch(0.88 0.09 var(--h))); background: light-dark(oklch(0.955 0.03 var(--h)), oklch(0.3 0.06 var(--h))); box-shadow: inset 0 0 0 1px light-dark(oklch(0.9 0.05 var(--h)), oklch(0.38 0.07 var(--h))); }
178.mono[data-size="l"] { inline-size: 2.75rem; block-size: 2.75rem; font-size: 1.25rem; border-radius: calc(1.5 * var(--rst-radius)); }
179.mono[data-size="s"] { inline-size: 1.25rem; block-size: 1.25rem; font-size: .65rem; border-radius: var(--rst-radius-sm); }
180
181/* ── Lists: a bordered group of rows, the whole row clickable ────── */
182.group { margin-block: 0 var(--rst-sp-5); }
183.group > h2 { display: flex; align-items: baseline; gap: var(--rst-sp-2); font-size: var(--rst-fs-base); font-weight: 600; margin: 0 0 var(--rst-sp-2); }
184.group > h2 .n { color: var(--rst-text-muted); font-weight: 400; font-variant-numeric: tabular-nums; }
185.group > h2 .hint { color: var(--rst-text-muted); font-weight: 400; font-size: var(--rst-fs-sm); margin-inline-start: auto; }
186.rows { list-style: none; margin: 0; padding: 0; border: 1px solid var(--rst-line); border-radius: calc(2 * var(--rst-radius)); background: var(--rst-surface); overflow: hidden; }
187.row { position: relative; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; column-gap: var(--rst-sp-3); align-items: start; padding: var(--rst-sp-3) var(--rst-sp-4); transition: background .15s; }
188.row + .row { border-block-start: 1px solid var(--rst-line); }
189.row:hover { background: var(--rst-tint-hover); }
190.row:has(.row-link:focus-visible) { background: var(--rst-tint-hover); box-shadow: inset 0 0 0 2px var(--rst-focus-edge); }
191.row .row-link { color: var(--rst-text); text-decoration: none; font-weight: 500; }
192.row .row-link::after { content: ""; position: absolute; inset: 0; cursor: pointer; }
193.row .row-link:focus-visible { outline: none; }
194.row :is(.badge, .menu, .dup a, .chip a, .who a) { position: relative; z-index: 1; }
195.row > .mono { margin-block-start: .1rem; }
196.row .body { min-width: 0; display: grid; gap: .3rem; }
197.row .title { display: flex; align-items: baseline; gap: var(--rst-sp-2); min-width: 0; }
198.row .title .row-link { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
199.row .meta { display: flex; flex-wrap: wrap; align-items: center; gap: .3rem var(--rst-sp-3); font-size: var(--rst-fs-xs); color: var(--rst-text-muted); min-width: 0; }
200.row .meta .who { color: var(--rst-text-muted); }
201.row .meta .who a { color: inherit; text-decoration: none; }
202.row .meta .who a:hover { text-decoration: underline; text-underline-offset: 2px; }
203.row .side { display: grid; justify-items: end; gap: .35rem; font-size: var(--rst-fs-xs); color: var(--rst-text-muted); white-space: nowrap; }
204.row .side .top { display: inline-flex; align-items: center; gap: var(--rst-sp-2); min-block-size: 1.5rem; }
205.row .side .badges { display: flex; gap: var(--rst-sp-1); }
206.row .side .badges:empty { display: none; }
207.row .ago { font-variant-numeric: tabular-nums; }
208.row[data-stage="done"] .row-link, .row[data-stage="cancelled"] .row-link { color: var(--rst-text-muted); font-weight: 400; }
209.row[data-stage="done"] .track, .row[data-stage="cancelled"] .track { opacity: .6; }
210
211/* ── The stage track: six nodes on a hairline, the current one lit ── */
212.track { display: inline-flex; align-items: center; margin: 0; padding: 0; list-style: none; flex: none; }
213.track li { position: relative; display: grid; place-items: center; inline-size: .5rem; block-size: .5rem; }
214.track li + li { margin-inline-start: .85rem; }
215.track li + li::before { content: ""; position: absolute; inset-inline-end: 100%; inline-size: .85rem; block-size: 1px; background: var(--rst-line-strong); opacity: .45; }
216.track li::after { content: ""; inline-size: .4rem; block-size: .4rem; border-radius: 50%; border: 1px solid var(--rst-line-strong); background: var(--rst-surface); }
217.track li[data-s="done"]::after { background: var(--rst-line-strong); border-color: var(--rst-line-strong); }
218.track li[data-s="done"] + li::before { opacity: 1; }
219.track li[data-s="current"]::after { inline-size: .5rem; block-size: .5rem; background: var(--rst-accent); border-color: var(--rst-accent); box-shadow: 0 0 0 3px var(--rst-accent-soft); }
220.track li[data-s="current"][data-tone="negative"]::after { background: var(--rst-tone-negative-fg); border-color: var(--rst-tone-negative-fg); box-shadow: 0 0 0 3px var(--rst-tone-negative-bg); }
221.track li[data-s="current"][data-tone="positive"]::after { background: var(--rst-tone-positive-fg); border-color: var(--rst-tone-positive-fg); box-shadow: 0 0 0 3px var(--rst-tone-positive-bg); }
222.track li[data-s="current"][data-tone="attention"]::after { background: var(--rst-tone-warning-fg); border-color: var(--rst-tone-warning-fg); box-shadow: 0 0 0 3px var(--rst-tone-warning-bg); }
223.track li[data-live]::after { display: none; }
224.track li[data-live] .mark { font-size: 1rem; }
225.track-line { display: inline-flex; align-items: center; gap: var(--rst-sp-2); min-width: 0; }
226.track-line .stage-name { color: var(--rst-text); font-weight: 500; white-space: nowrap; }
227.track-line .stage-name[data-tone="negative"] { color: var(--rst-tone-negative-fg); }
228.track-line .stage-name[data-tone="attention"] { color: var(--rst-tone-warning-fg); }
229.chip { display: inline-flex; align-items: center; gap: .4em; white-space: nowrap; color: var(--rst-text-muted); }
230.chip .mark { font-size: .9em; }
231/* The full track with labels under each node, for the detail header. */
232.track-full { display: grid; grid-auto-flow: column; grid-auto-columns: 1fr; margin: var(--rst-sp-4) 0 0; padding: 0; list-style: none; font-size: var(--rst-fs-xs); color: var(--rst-text-muted); }
233.track-full li { position: relative; display: grid; justify-items: center; gap: .4rem; padding-block-start: .25rem; }
234.track-full li::before { content: ""; position: absolute; inset-block-start: calc(.25rem + .35rem); inset-inline: 50%; block-size: 1px; background: var(--rst-line-strong); opacity: .45; }
235.track-full li + li::before { inset-inline-start: -50%; inset-inline-end: 50%; }
236.track-full li:last-child::before { display: none; }
237.track-full li[data-s="done"] + li::before, .track-full li[data-s="current"]::before { opacity: 1; }
238.track-full li:last-child[data-s="current"]::before, .track-full li:last-child[data-s="done"]::before { display: none; }
239.track-full li .dot { position: relative; z-index: 1; display: grid; place-items: center; inline-size: .7rem; block-size: .7rem; }
240.track-full li .dot::after { content: ""; inline-size: .5rem; block-size: .5rem; border-radius: 50%; border: 1px solid var(--rst-line-strong); background: var(--rst-surface); }
241.track-full li[data-s="done"] .dot::after { background: var(--rst-line-strong); border-color: var(--rst-line-strong); }
242.track-full li[data-s="current"] .dot::after { inline-size: .7rem; block-size: .7rem; background: var(--rst-accent); border-color: var(--rst-accent); box-shadow: 0 0 0 4px var(--rst-accent-soft); }
243.track-full li[data-s="current"][data-tone="positive"] .dot::after { background: var(--rst-tone-positive-fg); border-color: var(--rst-tone-positive-fg); box-shadow: 0 0 0 4px var(--rst-tone-positive-bg); }
244.track-full li[data-s="current"][data-tone="negative"] .dot::after { background: var(--rst-tone-negative-fg); border-color: var(--rst-tone-negative-fg); box-shadow: 0 0 0 4px var(--rst-tone-negative-bg); }
245.track-full li[data-live] .dot::after { display: none; }
246.track-full li[data-live] .dot .mark { font-size: 1.2rem; }
247.track-full li[data-s="current"] > span { color: var(--rst-text); font-weight: 600; }
248.track-full li > span { text-align: center; white-space: nowrap; }
249.track-full li > small { color: var(--rst-text-faint); margin-block-start: -.3rem; }
250
251/* ── Badges for checks and review ────────────────────────────────── */
252.badge { display: inline-flex; align-items: center; gap: .35em; padding: .1rem .5rem .1rem .4rem; border-radius: var(--rst-radius-pill); font-size: var(--rst-fs-xs); white-space: nowrap; border: 1px solid transparent; color: var(--rst-tone-neutral-fg); background: var(--rst-tone-neutral-bg); cursor: default; }
253.badge .icon { inline-size: .95em; block-size: .95em; }
254.badge[data-tone="positive"] { color: var(--rst-tone-positive-fg); background: var(--rst-tone-positive-bg); }
255.badge[data-tone="negative"] { color: var(--rst-tone-negative-fg); background: var(--rst-tone-negative-bg); }
256.badge[data-tone="warning"] { color: var(--rst-tone-warning-fg); background: var(--rst-tone-warning-bg); }
257.badge[data-tone="live"] { color: var(--rst-accent); background: var(--rst-accent-soft); }
258.badge[data-tone="quiet"] { color: var(--rst-text-faint); background: transparent; border-color: var(--rst-line); }
259
260/* ── Quiet actions: ⋯ menu, hover-revealed links ─────────────────── */
261.menu { position: relative; }
262.menu > summary { list-style: none; display: inline-grid; place-items: center; inline-size: 1.5rem; block-size: 1.5rem; border-radius: var(--rst-radius-sm); color: var(--rst-text-muted); cursor: pointer; }
263.menu > summary::-webkit-details-marker { display: none; }
264.menu > summary:hover { background: var(--rst-tint-press); color: var(--rst-text); }
265.menu > summary .icon { inline-size: 1em; block-size: 1em; }
266.menu > div { position: absolute; inset-inline-end: 0; inset-block-start: calc(100% + 2px); z-index: 3; min-inline-size: 15rem; padding: var(--rst-sp-1); border: 1px solid var(--rst-line); border-radius: var(--rst-radius); background: var(--rst-surface); box-shadow: var(--rst-shadow-pop); font-size: var(--rst-fs-sm); }
267.menu > div a, .menu > div button { display: block; inline-size: 100%; text-align: start; font: inherit; color: var(--rst-text); background: none; border: 0; padding: .35rem .6rem; border-radius: var(--rst-radius-sm); text-decoration: none; cursor: pointer; }
268.menu > div a:hover, .menu > div button:hover { background: var(--rst-tint-hover); }
269.menu > div .danger { color: var(--rst-tone-negative-fg); }
270.menu > div small { display: block; color: var(--rst-text-muted); }
271.row .menu { opacity: 0; transition: opacity .15s; }
272.row:hover .menu, .row:focus-within .menu, .row .menu[open] { opacity: 1; }
273@media (hover: none) { .row .menu { opacity: 1; } }
274.dup { display: flex; align-items: center; gap: var(--rst-sp-2); font-size: var(--rst-fs-xs); color: var(--rst-text-muted); }
275.dup .icon { inline-size: 1em; block-size: 1em; color: var(--rst-tone-warning-fg); }
276.dup a { color: var(--rst-text-muted); }
277.quiet { color: var(--rst-text-muted); font-size: var(--rst-fs-xs); }
278.quiet a { color: inherit; }
279
280/* ── Filters: quiet text with a chevron, not a form ──────────────── */
281.filters { display: flex; flex-wrap: wrap; gap: var(--rst-sp-2) var(--rst-sp-4); margin: 0 0 var(--rst-sp-4); font-size: var(--rst-fs-sm); }
282.filter { position: relative; }
283.filter > summary { list-style: none; display: inline-flex; align-items: center; gap: .3em; color: var(--rst-text-muted); cursor: pointer; padding: .15rem .3rem; margin: 0 -.3rem; border-radius: var(--rst-radius-sm); }
284.filter > summary::-webkit-details-marker { display: none; }
285.filter > summary:hover { color: var(--rst-text); background: var(--rst-tint-hover); }
286.filter > summary .icon { inline-size: 1em; block-size: 1em; }
287.filter[data-active] > summary { color: var(--rst-text); font-weight: 500; }
288.filter > div { position: absolute; z-index: 3; inset-block-start: calc(100% + 4px); inset-inline-start: -.3rem; min-inline-size: 12rem; padding: var(--rst-sp-1); border: 1px solid var(--rst-line); border-radius: var(--rst-radius); background: var(--rst-surface); box-shadow: var(--rst-shadow-pop); }
289.filter button { display: flex; align-items: center; gap: var(--rst-sp-2); inline-size: 100%; text-align: start; font: inherit; font-size: var(--rst-fs-sm); color: var(--rst-text); background: none; border: 0; padding: .35rem .6rem; border-radius: var(--rst-radius-sm); cursor: pointer; }
290.filter button:hover { background: var(--rst-tint-hover); }
291.filter button[aria-pressed="true"] { background: var(--rst-accent-soft); color: var(--rst-accent); }
292
293/* ── Decision cards: the one place a prominent button appears ────── */
294.decision { display: grid; grid-template-columns: auto minmax(0, 1fr); column-gap: var(--rst-sp-3); row-gap: var(--rst-sp-2); padding: var(--rst-sp-3) var(--rst-sp-4); margin: 0 0 var(--rst-sp-3); border: 1px solid color-mix(in srgb, var(--rst-accent) 22%, var(--rst-line)); border-radius: calc(2 * var(--rst-radius)); background: color-mix(in oklab, var(--rst-surface), var(--rst-accent-soft) 45%); }
295.decision[data-tone="attention"] { border-color: color-mix(in srgb, var(--rst-tone-warning-fg) 25%, var(--rst-line)); background: color-mix(in srgb, var(--rst-tone-warning-bg) 45%, var(--rst-surface)); }
296.decision > .mono { grid-column: 1; grid-row: 1 / span 4; margin-block-start: .15rem; }
297.decision > :not(.mono) { grid-column: 2; }
298.decision:not(:has(> .mono)) { grid-template-columns: minmax(0, 1fr); }
299.decision:not(:has(> .mono)) > * { grid-column: 1; }
300.decision .d-title { display: flex; flex-wrap: wrap; align-items: baseline; gap: var(--rst-sp-2) var(--rst-sp-3); min-width: 0; }
301.decision .d-title a { color: var(--rst-text); font-weight: 500; text-decoration: none; }
302.decision .d-title a:hover { text-decoration: underline; text-underline-offset: 2px; }
303.decision .d-title .quiet { margin-inline-start: auto; }
304.decision .d-why { margin: 0; color: var(--rst-text-muted); font-size: var(--rst-fs-sm); max-inline-size: 64ch; }
305.decision .d-why strong { color: var(--rst-text); font-weight: 500; }
306.decision .d-ask { margin: 0; font-weight: 500; }
307.decision .d-actions { display: flex; flex-wrap: wrap; align-items: center; gap: var(--rst-sp-2) var(--rst-sp-3); }
308.btn { display: inline-flex; align-items: center; justify-content: center; gap: .4em; min-block-size: 2rem; padding: .3rem .85rem; font: inherit; font-size: var(--rst-fs-sm); font-weight: 500; border-radius: var(--rst-radius-sm); border: 1px solid var(--rst-control-border); background: var(--rst-control-face); color: var(--rst-text); cursor: pointer; text-decoration: none; }
309.btn:hover { background: var(--rst-control-face-hover); border-color: var(--rst-control-border-hover); }
310.btn[data-primary] { background: var(--rst-accent-fill); border-color: var(--rst-accent-fill-edge); color: var(--rst-on-accent-fill); }
311.btn[data-primary]:hover { background: var(--rst-accent-fill-hover); }
312.link { appearance: none; background: none; border: 0; padding: 0; font: inherit; font-size: var(--rst-fs-sm); color: var(--rst-text-muted); text-decoration: underline; text-underline-offset: 2px; cursor: pointer; }
313.link:hover { color: var(--rst-text); }
314.empty { color: var(--rst-text-muted); margin: 0; }
315
316/* ── Task detail ─────────────────────────────────────────────────── */
317.t-head { display: grid; grid-template-columns: auto minmax(0, 1fr); column-gap: var(--rst-sp-3); row-gap: .3rem; align-items: start; }
318.t-head .mono { margin-block-start: .2rem; }
319.t-head .crumbs { display: flex; flex-wrap: wrap; align-items: center; gap: .3rem var(--rst-sp-2); font-size: var(--rst-fs-sm); color: var(--rst-text-muted); }
320.t-head .crumbs a { color: var(--rst-text-muted); text-decoration: none; }
321.t-head .crumbs a:hover { text-decoration: underline; text-underline-offset: 2px; }
322.t-head h1 { margin: 0; }
323.t-head .filed { display: flex; flex-wrap: wrap; align-items: center; gap: .3rem var(--rst-sp-3); font-size: var(--rst-fs-sm); color: var(--rst-text-muted); }
324.t-head .filed a { color: inherit; }
325.t-head .track-full { grid-column: 1 / -1; }
326.t-summary { margin: var(--rst-sp-5) 0 var(--rst-sp-4); max-inline-size: 68ch; font-size: var(--rst-fs-lg); line-height: 1.45; }
327.t-summary .mark { margin-inline-end: .35em; }
328.t-cols { display: grid; grid-template-columns: minmax(0, 1fr) minmax(18rem, 24rem); gap: var(--rst-sp-6); align-items: start; margin-block-start: var(--rst-sp-4); }
329.t-cols > section > h2, .details > summary, .p-section > h2 { font-size: var(--rst-fs-base); font-weight: 600; margin: 0 0 var(--rst-sp-3); }
330/* The timeline: a sequence, so nodes and a line. */
331.tl { list-style: none; margin: 0; padding: 0; }
332.tl > li { position: relative; display: grid; grid-template-columns: 1.25rem minmax(0, 1fr); column-gap: var(--rst-sp-3); padding-block: 0 var(--rst-sp-4); }
333.tl > li::before { content: ""; position: absolute; inset-inline-start: calc(.625rem - .5px); inset-block-start: 1rem; inset-block-end: 0; inline-size: 1px; background: var(--rst-line); }
334.tl > li:last-child::before { display: none; }
335.tl .node { position: relative; z-index: 1; display: grid; place-items: center; inline-size: 1.25rem; block-size: 1.25rem; margin-block-start: .1rem; }
336.tl .node::after { content: ""; inline-size: .5rem; block-size: .5rem; border-radius: 50%; background: var(--rst-line-strong); }
337.tl > li[data-kind="finding"] .node::after, .tl > li[data-kind="noted"] .node::after { background: var(--rst-surface); border: 1px solid var(--rst-line-strong); }
338.tl > li[data-kind="stopped"] .node::after { background: var(--rst-tone-negative-fg); }
339.tl > li[data-kind="merged"] .node::after { background: var(--rst-tone-positive-fg); box-shadow: 0 0 0 3px var(--rst-tone-positive-bg); }
340.tl > li[data-kind="ready"] .node::after, .tl > li[data-kind="decision"] .node::after { background: var(--rst-accent); box-shadow: 0 0 0 3px var(--rst-accent-soft); }
341.tl > li[data-live] .node::after { display: none; }
342.tl > li[data-live] .node .mark { font-size: 1.2rem; }
343.tl > li[data-new] { animation: equipo-rise .35s ease-out both; }
344.tl .what { display: flex; flex-wrap: wrap; align-items: baseline; gap: .2rem var(--rst-sp-2); min-width: 0; }
345.tl .what b { font-weight: 500; }
346.tl .what time, .tl .what .elapsed { font-size: var(--rst-fs-xs); color: var(--rst-text-faint); font-variant-numeric: tabular-nums; }
347.tl .what .badge { margin-inline-start: .1rem; }
348.tl .detail { margin: .2rem 0 0; color: var(--rst-text-muted); font-size: var(--rst-fs-sm); max-inline-size: 64ch; }
349.tl .detail code, .md code, .attach code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: .92em; padding: .05em .3em; border-radius: var(--rst-radius-sm); background: var(--rst-surface-2); color: var(--rst-text); }
350.tl .receipt { display: inline-flex; flex-wrap: wrap; gap: 0 var(--rst-sp-3); font-size: var(--rst-fs-xs); color: var(--rst-text-faint); }
351.tl .receipt a { color: inherit; opacity: 0; transition: opacity .15s; }
352.tl > li:hover .receipt a, .tl > li:focus-within .receipt a { opacity: 1; }
353@media (hover: none) { .tl .receipt a { opacity: 1; } }
354.tl .live-line { display: inline-flex; align-items: center; gap: .5em; color: var(--rst-text); font-weight: 500; font-size: var(--rst-fs-sm); }
355.tl .live-line .elapsed { font-weight: 400; }
356.tl .findings { margin: .3rem 0 0; padding-inline-start: 1.1rem; color: var(--rst-text-muted); font-size: var(--rst-fs-sm); }
357.tl .findings small { display: block; color: var(--rst-text-faint); font-size: var(--rst-fs-xs); }
358.tl .decision { margin: var(--rst-sp-2) 0 0; grid-template-columns: minmax(0, 1fr); }
359/* Questions and notes: the task thread beside the timeline. */
360.thread { position: sticky; top: 0; display: flex; flex-direction: column; max-block-size: calc(860px - 8rem); }
361.feed { list-style: none; margin: 0 0 var(--rst-sp-3); padding: 0; display: flex; flex-direction: column; gap: var(--rst-sp-3); font-size: var(--rst-fs-sm); }
362.msg { max-inline-size: 92%; align-self: flex-start; }
363.msg[data-own] { align-self: flex-end; }
364.msg .m-meta { display: flex; align-items: baseline; gap: var(--rst-sp-2); color: var(--rst-text-muted); font-size: var(--rst-fs-xs); margin-block-end: .15rem; }
365.msg .m-meta .icon { inline-size: 1em; block-size: 1em; vertical-align: -.15em; margin-inline-end: .3em; }
366.msg .m-meta time { margin-inline-start: auto; }
367.msg[data-own] .m-meta { justify-content: flex-end; }
368.msg p { margin: 0; }
369.msg[data-own] .bubble { padding: var(--rst-sp-2) var(--rst-sp-3); border: 1px solid var(--rst-line); border-radius: calc(2 * var(--rst-radius)); background: var(--rst-accent-soft); }
370.sysnote { color: var(--rst-text-muted); font-size: var(--rst-fs-xs); }
371.composer { display: grid; gap: var(--rst-sp-2); padding: var(--rst-sp-3); border: 1px solid var(--rst-line); border-radius: calc(2 * var(--rst-radius)); background: var(--rst-surface); }
372.composer .ta { color: var(--rst-text-faint); font-size: var(--rst-fs-sm); min-block-size: 1.5rem; }
373.composer .tools { display: flex; align-items: center; gap: var(--rst-sp-2); font-size: var(--rst-fs-sm); color: var(--rst-text-muted); }
374.composer .tools .link { margin-inline-start: .2rem; }
375.composer .tools .btn { margin-inline-start: auto; min-block-size: 1.75rem; padding: .15rem .7rem; }
376/* Details: the brief, findings, step summaries and the branch, folded. */
377.details { margin-block-start: var(--rst-sp-5); border-block-start: 1px solid var(--rst-line); padding-block-start: var(--rst-sp-4); }
378.details > summary { list-style: none; display: inline-flex; align-items: center; gap: .4em; cursor: pointer; color: var(--rst-text); }
379.details > summary::-webkit-details-marker { display: none; }
380.details > summary .icon { inline-size: 1em; block-size: 1em; color: var(--rst-text-faint); transition: transform .25s var(--equipo-ease); }
381.details[open] > summary .icon { transform: rotate(180deg); }
382.details .d-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 22rem), 1fr)); gap: var(--rst-sp-5); margin-block-start: var(--rst-sp-3); }
383.details h3 { font-size: var(--rst-fs-sm); font-weight: 600; margin: 0 0 var(--rst-sp-2); color: var(--rst-text-muted); }
384.md { font-size: var(--rst-fs-sm); color: var(--rst-text); max-inline-size: 64ch; }
385.md p { margin: 0 0 var(--rst-sp-2); }
386.md ul { margin: 0 0 var(--rst-sp-2); padding-inline-start: 1.2rem; }
387.md > :last-child { margin-block-end: 0; }
388.kv { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: .3rem var(--rst-sp-3); font-size: var(--rst-fs-sm); margin: 0; }
389.kv dt { color: var(--rst-text-muted); }
390.kv dd { margin: 0; overflow-wrap: anywhere; }
391.kv dd a { color: var(--rst-text-muted); }
392
393/* ── Projects ────────────────────────────────────────────────────── */
394.prow { grid-template-columns: auto minmax(0, 1fr) auto; }
395.prow .desc { color: var(--rst-text-muted); font-size: var(--rst-fs-sm); margin: 0; max-inline-size: 64ch; }
396.prow .facts { display: flex; flex-wrap: wrap; gap: .3rem var(--rst-sp-4); font-size: var(--rst-fs-xs); color: var(--rst-text-muted); margin-block-start: .2rem; }
397.prow .facts span { display: inline-flex; align-items: center; gap: .35em; white-space: nowrap; }
398.prow .facts .icon { inline-size: 1em; block-size: 1em; color: var(--rst-text-faint); }
399.prow .facts [data-tone="positive"] .icon { color: var(--rst-tone-positive-fg); }
400.prow .facts [data-tone="warning"] .icon { color: var(--rst-tone-warning-fg); }
401.prow .side { gap: .5rem; }
402.spread { display: inline-flex; align-items: center; gap: var(--rst-sp-2); }
403.spread .bar { display: inline-flex; inline-size: 6rem; block-size: .4rem; border-radius: var(--rst-radius-pill); overflow: hidden; background: var(--rst-surface-2); }
404.spread .bar i { display: block; block-size: 100%; }
405.spread .bar i[data-k="needs"] { background: var(--rst-tone-warning-fg); }
406.spread .bar i[data-k="progress"] { background: var(--rst-accent); }
407.spread .bar i[data-k="ready"] { background: color-mix(in srgb, var(--rst-accent) 45%, var(--rst-surface)); }
408.spread .bar i[data-k="done"] { background: var(--rst-line-strong); opacity: .5; }
409.spread .n { font-variant-numeric: tabular-nums; }
410.legend { display: flex; flex-wrap: wrap; gap: .2rem var(--rst-sp-3); font-size: var(--rst-fs-xs); color: var(--rst-text-muted); }
411.legend span { display: inline-flex; align-items: center; gap: .35em; }
412.legend i { inline-size: .5rem; block-size: .5rem; border-radius: 2px; }
413.p-head { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; column-gap: var(--rst-sp-4); row-gap: .25rem; align-items: start; margin-block-end: var(--rst-sp-5); }
414.p-head p { margin: 0; color: var(--rst-text-muted); max-inline-size: 64ch; }
415.p-head .facts { display: flex; flex-wrap: wrap; gap: .3rem var(--rst-sp-4); font-size: var(--rst-fs-sm); color: var(--rst-text-muted); margin-block-start: .3rem; }
416.p-head .facts span { display: inline-flex; align-items: center; gap: .4em; }
417.p-head .facts .icon { inline-size: 1em; block-size: 1em; color: var(--rst-text-faint); }
418.p-head .facts [data-tone="positive"] .icon { color: var(--rst-tone-positive-fg); }
419.p-head .facts [data-tone="warning"] .icon { color: var(--rst-tone-warning-fg); }
420.p-head .people { display: grid; justify-items: end; gap: .25rem; font-size: var(--rst-fs-xs); color: var(--rst-text-muted); }
421.p-cols { display: grid; grid-template-columns: minmax(0, 1fr) minmax(16rem, 20rem); gap: var(--rst-sp-6); align-items: start; }
422.p-section { margin-block-end: var(--rst-sp-5); }
423.attach { list-style: none; margin: 0; padding: 0; border: 1px solid var(--rst-line); border-radius: calc(2 * var(--rst-radius)); background: var(--rst-surface); overflow: hidden; }
424.attach li { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; column-gap: var(--rst-sp-3); align-items: center; padding: var(--rst-sp-3) var(--rst-sp-4); font-size: var(--rst-fs-sm); }
425.attach li + li { border-block-start: 1px solid var(--rst-line); }
426.attach .icon { inline-size: 1.1em; block-size: 1.1em; color: var(--rst-text-faint); }
427.attach .name { font-weight: 500; }
428.attach .sub { color: var(--rst-text-muted); font-size: var(--rst-fs-xs); display: flex; flex-wrap: wrap; gap: 0 var(--rst-sp-3); }
429.attach .quiet a { opacity: 0; transition: opacity .15s; }
430.attach li:hover .quiet a, .attach li:focus-within .quiet a { opacity: 1; }
431@media (hover: none) { .attach .quiet a { opacity: 1; } }
432.activity { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--rst-sp-2); font-size: var(--rst-fs-sm); }
433.activity li { display: grid; grid-template-columns: 3.2rem minmax(0, 1fr); column-gap: var(--rst-sp-3); color: var(--rst-text); }
434.activity time { color: var(--rst-text-faint); font-size: var(--rst-fs-xs); font-variant-numeric: tabular-nums; padding-block-start: .15rem; }
435.activity a { color: inherit; text-decoration: none; }
436.activity a:hover { text-decoration: underline; text-underline-offset: 2px; }
437.activity .quiet { display: block; }
438.notes { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--rst-sp-3); }
439.note { padding: var(--rst-sp-3) var(--rst-sp-4); border: 1px solid var(--rst-line); border-radius: var(--rst-radius); background: color-mix(in oklab, var(--rst-surface), var(--rst-accent-soft) 16%); box-shadow: var(--rst-shadow-lift); font-size: var(--rst-fs-sm); }
440.note p { margin: 0; line-height: 1.5; }
441.note .cap { display: flex; justify-content: space-between; gap: var(--rst-sp-3); margin-block-start: var(--rst-sp-2); font-size: var(--rst-fs-xs); color: var(--rst-text-muted); }
442
443/* ── Phone-width stacking, by container, so both frames agree ────── */
444@container app (max-width: 600px) {
445 .main { padding: var(--rst-sp-4) var(--rst-sp-3) var(--rst-sp-6); }
446 .row { grid-template-columns: auto minmax(0, 1fr); row-gap: .4rem; }
447 .row .side { grid-column: 1 / -1; grid-template-columns: minmax(0, 1fr) auto; justify-items: start; align-items: center; }
448 .row .side .top { justify-self: end; grid-column: 2; grid-row: 1; }
449 .row .side .badges { grid-column: 1; grid-row: 1; flex-wrap: wrap; }
450 .row .title .row-link { white-space: normal; }
451 .row .meta { row-gap: .4rem; }
452 .track-full li > span { font-size: 0; }
453 .track-full li[data-s="current"] > span { font-size: var(--rst-fs-xs); }
454 .track-full li > small { display: none; }
455 .t-cols, .p-cols { grid-template-columns: minmax(0, 1fr); gap: var(--rst-sp-5); }
456 .thread { position: static; max-block-size: none; }
457 .t-summary { font-size: var(--rst-fs-base); }
458 .p-head { grid-template-columns: auto minmax(0, 1fr); }
459 .p-head .people { grid-column: 1 / -1; justify-items: start; }
460 .prow .side { grid-column: 1 / -1; justify-items: start; }
461 .decision { grid-template-columns: minmax(0, 1fr); }
462 .decision > .mono { display: none; }
463 .decision > :not(.mono) { grid-column: 1; }
464 .decision .d-actions .btn { flex: 1 1 auto; min-block-size: 2.75rem; }
465 .composer-dock { position: sticky; bottom: 0; padding-block-start: var(--rst-sp-2); background: var(--rst-bg); }
466}
467
468/* ── Reduced motion: everything still, nothing missing ───────────── */
469@media (prefers-reduced-motion: reduce) { :root:not([data-motion="full"]) { --still: 1; } }
470:root[data-motion="reduced"] { --still: 1; }
471:root[data-motion="reduced"] .mark svg, :root[data-motion="reduced"] .mark path, :root[data-motion="reduced"] .mark circle, :root[data-motion="reduced"] .mark i, :root[data-motion="reduced"] .spec-panel, :root[data-motion="reduced"] .tl > li, :root[data-motion="reduced"] .spec-panel ol li { animation: none !important; transition: none !important; }
472:root[data-motion="reduced"] .mark [data-sat="1"], :root[data-motion="reduced"] .mark [data-sat="2"] { opacity: .7; transform: scale(.8) rotate(45deg); }
473:root[data-motion="reduced"] .mark [data-mote] { display: none; }
474:root[data-motion="reduced"] .mark circle { transform: scale(.9); opacity: 1; }
475@media (prefers-reduced-motion: reduce) {
476 :root:not([data-motion="full"]) .mark svg, :root:not([data-motion="full"]) .mark path, :root:not([data-motion="full"]) .mark circle, :root:not([data-motion="full"]) .mark i, :root:not([data-motion="full"]) .spec-panel, :root:not([data-motion="full"]) .tl > li { animation: none !important; transition: none !important; }
477 :root:not([data-motion="full"]) .mark [data-sat="1"], :root:not([data-motion="full"]) .mark [data-sat="2"] { opacity: .7; transform: scale(.8) rotate(45deg); }
478 :root:not([data-motion="full"]) .mark [data-mote] { display: none; }
479}
480
481/* Calm Stardust (Paul, 2026-11-08: "more gentle and calming rather than
482 jittery"): a slow continuous turn, a soft sine breath, a slow glow,
483 satellites that fade, motes drifting out of step; the flourish is only
484 a soft brightening; marks in the rail and rows only breathe. */
485.mark svg { animation: m-calm-turn 16s linear infinite; }
486.mark path { animation: m-calm-breathe 3.6s cubic-bezier(.37, 0, .63, 1) infinite; }
487.mark circle { animation: m-calm-glow 4.8s cubic-bezier(.37, 0, .63, 1) infinite; }
488.mark [data-sat] { transform: scale(.85) rotate(45deg); animation: m-calm-sat 6.5s cubic-bezier(.37, 0, .63, 1) .4s infinite; }
489.mark [data-sat="2"] { animation-duration: 7.7s; animation-delay: 2.3s; }
490.mark [data-sat="3"] { animation-duration: 8.9s; animation-delay: 4.1s; }
491.mark[data-flourish] svg { animation: m-calm-turn 16s linear infinite; }
492.mark[data-flourish] path { animation: m-calm-breathe 3.6s cubic-bezier(.37, 0, .63, 1) infinite, m-calm-bright 1.6s cubic-bezier(.37, 0, .63, 1); }
493.mark [data-mote], .mark[data-flourish] [data-mote] { animation: m-calm-mote 5s cubic-bezier(.37, 0, .63, 1) var(--d, 0s) infinite both; }
494.mark [data-mote]:nth-of-type(5) { animation-duration: 5.7s; animation-delay: 1.9s; }
495.mark [data-mote]:nth-of-type(6) { animation-duration: 4.4s; animation-delay: 3.6s; }
496.mark [data-mote]:nth-of-type(n+7) { display: none; }
497.mark[data-size="s"] svg { animation: none; }
498.mark[data-size="s"] [data-sat] { animation: none; opacity: .55; }
499@keyframes m-calm-turn { to { transform: rotate(360deg); } }
500@keyframes m-calm-breathe { 0%, 100% { transform: scale(.96); } 50% { transform: scale(1.04); } }
501@keyframes m-calm-glow { 0%, 100% { opacity: .7; } 50% { opacity: 1; } }
502@keyframes m-calm-sat { 0%, 100% { opacity: 0; } 45%, 60% { opacity: .75; } }
503@keyframes m-calm-bright { 50% { filter: brightness(1.3); } }
504@keyframes m-calm-mote { 0% { opacity: 0; transform: translate(0, 0) scale(.7); } 35% { opacity: .65; } 70% { opacity: .5; } 100% { opacity: 0; transform: translate(calc(var(--dx) * .5), calc(var(--dy) * .5)) scale(.45); } }
505:root[data-motion="reduced"] .mark svg, :root[data-motion="reduced"] .mark path, :root[data-motion="reduced"] .mark circle, :root[data-motion="reduced"] .mark i { animation: none !important; }
506@media (prefers-reduced-motion: reduce) { :root:not([data-motion="full"]) .mark svg, :root:not([data-motion="full"]) .mark path, :root:not([data-motion="full"]) .mark circle, :root:not([data-motion="full"]) .mark i { animation: none !important; } }
507</style>
508</head>
509<body>
510<main class="page">
511 <section class="intro">
512 <h1>The inner screens: tasks, a task, projects, a project, needs you</h1>
513 <p>One mockup for the UX pass Paul asked for. The sidebar's specialists come alive with the Stardust mark and open to show what they are doing. Tasks are grouped by what matters, each with a stage track, badges and who filed it. The task page leads with a short summary and a timeline. Projects say what Equipo knows about them. Nothing asks the person to merge: the coordinator does, and asks once when checks could not run. Copy is placeholder.</p>
514 </section>
515
516 <div class="controls">
517 <div class="control">Screen <span class="seg" data-control="screen"><button data-value="tasks">Tasks</button><button data-value="task">A task</button><button data-value="projects">Projects</button><button data-value="project">A project</button><button data-value="needs">Needs you</button></span></div>
518 <div class="control">Theme <span class="seg" data-control="theme"><button data-value="system">System</button><button data-value="light">Light</button><button data-value="dark">Dark</button></span></div>
519 <div class="control">Motion <span class="seg" data-control="motion"><button data-value="full">Full</button><button data-value="reduced">Reduced</button></span></div>
520 <div class="control">Live <span class="seg" data-control="live"><button data-value="off">Still</button><button data-value="on">Simulate</button></span> <button class="replay" type="button" data-replay>Play again</button></div>
521 </div>
522
523 <section class="band" style="margin-block-start: 0">
524 <h2>Desktop, 1280</h2>
525 <p>Click any row to drill in, the chevron beside a working specialist to open it, and ⋯ on your own task for its quiet actions. Simulate runs a step through to Done so the mark, the dropdown and the timeline move.</p>
526 <div class="stage-wrap"><div class="stage" id="desk"></div></div>
527 </section>
528
529 <section class="band">
530 <h2>Phone, 390</h2>
531 <p>The same screen on a phone, and the team's index with the specialists, which is where the sidebar lives on a phone.</p>
532 <div class="phones">
533 <div><div class="phone" id="phone"></div><p class="caption">The screen chosen above.</p></div>
534 <div><div class="phone" id="phone-index"></div><p class="caption">The team index. Specialists open in place.</p></div>
535 </div>
536 </section>
537</main>
538
539<script>
540(function () {
541"use strict";
542
543/* ── Icons, from internal/equipo/icons/icons.go (same strokes) ───── */
544const I = {
545 users: '<path d="M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2"/><path d="M16 3.128a4 4 0 0 1 0 7.744"/><path d="M22 21v-2a4 4 0 0 0-3-3.87"/><circle cx="9" cy="7" r="4"/>',
546 "message-circle": '<path d="M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2z"/>',
547 inbox: '<path d="M22 12h-6l-2 3h-4l-2-3H2"/><path d="M5.45 5.11 2 12v6a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-6l-3.45-6.89A2 2 0 0 0 16.76 4H7.24a2 2 0 0 0-1.79 1.11z"/>',
548 folder: '<path d="M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z"/>',
549 code: '<path d="m16 18 6-6-6-6"/><path d="m8 6-6 6 6 6"/>',
550 "check-circle": '<circle cx="12" cy="12" r="10"/><path d="m9 12 2 2 4-4"/>',
551 check: '<path d="M20 6 9 17l-5-5"/>',
552 x: '<path d="M18 6 6 18"/><path d="m6 6 12 12"/>',
553 "chevron-down": '<path d="m6 9 6 6 6-6"/>',
554 "alert-triangle": '<path d="m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3Z"/><path d="M12 9v4"/><path d="M12 17h.01"/>',
555 "help-circle": '<circle cx="12" cy="12" r="10"/><path d="M9.09 9a3 3 0 0 1 5.83 1c0 2-3 3-3 3"/><path d="M12 17h.01"/>',
556 kebab: '<circle cx="12" cy="5" r="1"/><circle cx="12" cy="12" r="1"/><circle cx="12" cy="19" r="1"/>',
557 notebook: '<path d="M2 6h4"/><path d="M2 10h4"/><path d="M2 14h4"/><path d="M2 18h4"/><rect width="16" height="20" x="4" y="2" rx="2"/><path d="M16 2v20"/>',
558 shield: '<path d="M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z"/>',
559 plug: '<path d="M12 22v-5"/><path d="M9 8V2"/><path d="M15 8V2"/><path d="M18 8v5a4 4 0 0 1-4 4h-4a4 4 0 0 1-4-4V8Z"/>',
560 route: '<circle cx="6" cy="19" r="3"/><path d="M9 19h8.5a3.5 3.5 0 0 0 0-7h-11a3.5 3.5 0 0 1 0-7H15"/><circle cx="18" cy="5" r="3"/>',
561 git: '<circle cx="12" cy="18" r="3"/><circle cx="6" cy="6" r="3"/><circle cx="18" cy="6" r="3"/><path d="M18 9v2c0 .6-.4 1-1 1H7c-.6 0-1-.4-1-1V9"/><path d="M12 12v3"/>',
562 phone: '<rect width="14" height="20" x="5" y="2" rx="2" ry="2"/><path d="M12 18h.01"/>',
563 clock: '<circle cx="12" cy="12" r="10"/><polyline points="12 6 12 12 16 14"/>'
564};
565function icon(name) { return `<svg class="icon" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" aria-hidden="true" viewBox="0 0 24 24">${I[name]}</svg>`; }
566const STAR = '<svg viewBox="0 0 16 16" focusable="false"><path d="M8 0C8.6 4.6 11.4 7.4 16 8 11.4 8.6 8.6 11.4 8 16 7.4 11.4 4.6 8.6 0 8 4.6 7.4 7.4 4.6 8 0Z"/><circle cx="8" cy="8" r="1.7"/></svg><i data-sat="1"></i><i data-sat="2"></i><i data-sat="3"></i>';
567function mark(size) {
568 let motes = "";
569 if (size !== "s") for (let i = 0; i < 5; i++) {
570 const dx = 1.7 + (i * 1.37) % 3, dy = (i * 0.53) % 1.4 - 0.7;
571 motes += `<i data-mote="${i % 2 ? "light" : ""}" style="--dx:${dx.toFixed(2)}em;--dy:${dy.toFixed(2)}em;--d:${Math.round(i * 84)}ms"></i>`;
572 }
573 return `<span class="mark" aria-hidden="true"${size ? ` data-size="${size}"` : ""}>${STAR}${motes}</span>`;
574}
575
576/* ── Data: the team's people, projects and tasks ─────────────────── */
577const MIN = 60000, H = 60 * MIN, D = 24 * H;
578const now = Date.now();
579const PEOPLE = {
580 paul: { name: "Paul", address: "paul@keymail.dev", h: 250, me: true },
581 nora: { name: "Nora", address: "nora@keymail.dev", h: 30 },
582 coord: { name: "Coordinator" }
583};
584const PROJECTS = {
585 woodstar: { id: "p-woodstar", title: "Woodstar", h: 190, letter: "W",
586 desc: "An iOS app for reading and posting in a Twitter-style timeline without an account.",
587 stack: ["iOS", "Swift", "SwiftUI"], platform: "iOS",
588 checks: { here: false, reason: "needs macOS", note: "Checks need a Mac. No Mac runner is enrolled yet, so Review judges each commit and the coordinator asks before merging." },
589 repos: [
590 { name: "woodstar/woodstar", branch: "main", last: "Trim the compose sheet's bottom inset", at: now - 3 * H, sha: "9c1f3e2" },
591 { name: "woodstar/releases", branch: "main", last: "1.4 (112) to TestFlight", at: now - 2 * D, sha: "41ab77e" }
592 ],
593 people: ["paul", "nora"], activity: [],
594 notes: [
595 { text: "Panes are the app's own container: each tab is a pane with its own navigation stack, so system gestures have to be forwarded by hand.", from: "From the README, 2 Nov" },
596 { text: "Paul tests on his phone, not the simulator. Anything about gestures needs a device.", from: "From your conversation, 3 Nov" }
597 ] },
598 suite: { id: "p-suite", title: "Suite", h: 320, letter: "S",
599 desc: "The Oficina shared suite contract: what every Oficina app agrees to about accounts, teams and sign-in.",
600 stack: ["Markdown", "Go"], platform: "docs",
601 checks: { here: true, gate: "make ci", note: "Checks run here with make ci, about 40 seconds." },
602 repos: [
603 { name: "oficina/suite", branch: "main", last: "Replace em dash in README", at: now - 55 * MIN, sha: "3d9e0f1" }
604 ],
605 people: ["paul", "nora"], activity: [],
606 notes: [
607 { text: "The README is the contract. Wording changes go through it first, then the apps follow.", from: "From the README, 1 Nov" }
608 ] },
609 equipo: { id: "p-equipo", title: "Equipo", h: 250, letter: "E",
610 desc: "The team of agents you are talking to: a coordinator, Engineering and Review, in Go.",
611 stack: ["Go", "HTML"], platform: "web",
612 checks: { here: true, gate: ".amadan/ci", note: "Checks run here with .amadan/ci, about three minutes." },
613 repos: [
614 { name: "oficina/equipo", branch: "main", last: "SLICE4B-PROGRESS: the slice 4 merge and the index-pack fix", at: now - 6 * H, sha: "a0d418f" }
615 ],
616 people: ["paul"], activity: [],
617 notes: [
618 { text: "Paul reads this in Paseo on his phone as often as on the desk. Phone first for anything in the sidebar.", from: "From your conversation, 6 Nov" }
619 ] }
620};
621const STAGES = ["noted", "investigated", "in_progress", "in_review", "ready_to_merge", "done"];
622const STAGE_NAME = { noted: "Noted", investigated: "Looking into it", in_progress: "In progress", in_review: "In review", ready_to_merge: "Ready to merge", merging: "Merging…", done: "Done", cancelled: "Cancelled" };
623
624// Tasks. Each carries its steps; the timeline is built from them.
625const TASKS = [
626 { id: "tk-7f3a", project: "woodstar", title: "Swipe back from the edge doesn't work", creator: "paul", stage: "ready_to_merge", changed: now - 2 * H, created: now - 3 * H + 21 * MIN,
627 source: { time: "18:39", msg: "m-418", who: "paul" },
628 branch: "equipo/tk-7f3a-swipe-back-from-the-edge", base: "4e1f0a9", sha: "bc025ca",
629 brief: "On the Account pane, swiping in from the left edge should go back to the previous screen, as it does everywhere else in the app. It does nothing.\n\n- Happens on a device, every time\n- Other panes go back fine\n- Started after the panes refactor",
630 findings: [{ text: "The pane's gesture recogniser takes the edge swipe before the navigation stack sees it.", path: "ios/Woodstar/Navigation/AccountNavigationHost.swift", line: 15, at: now - 3 * H + 26 * MIN }],
631 steps: [
632 { specialist: "engineering", attempt: 1, state: "done", started: now - 3 * H + 28 * MIN, finished: now - 2 * H - 20 * MIN, pushed: true, sha: "bc025ca", family: "Claude",
633 summary: "Let the navigation stack's interactive pop gesture run alongside the pane's recogniser.\n\n- `AccountNavigationHost` now returns `true` from `gestureRecognizer(_:shouldRecognizeSimultaneouslyWith:)` for the edge swipe\n- Added a note on why the pane needs it\n\nNot run here: the Xcode tests need macOS." },
634 { specialist: "checks", state: "done", started: now - 2 * H - 20 * MIN, finished: now - 2 * H - 19 * MIN, checks: "cannot", reason: "needs macOS" },
635 { specialist: "review", state: "done", started: now - 2 * H - 19 * MIN, finished: now - 2 * H, verdict: "approve", label: "same family, same account", family: "Claude", findings: [] }
636 ],
637 needs: "merge_without_checks",
638 thread: [
639 { who: "paul", own: true, text: "Did you try it on the Home pane too?", at: "19:48" },
640 { who: "engineering", text: "Not as a test, since I can't run the app here. Home uses the same host class, so the change applies to it as well. The fix is in the shared `PaneNavigationHost`, not Account alone.", at: "19:49" }
641 ] },
642 { id: "tk-80b1", project: "woodstar", title: "Swipe from the edge to go back doesn't work", creator: "paul", stage: "in_progress", changed: now - 95 * MIN, created: now - 2 * H - 40 * MIN,
643 source: { time: "19:20", msg: "m-431", who: "paul" },
644 branch: "equipo/tk-80b1-swipe-from-the-edge", base: "4e1f0a9",
645 brief: "Swiping from the left edge to go back does nothing on the account screen.",
646 findings: [],
647 steps: [ { specialist: "engineering", attempt: 1, state: "failed", reason: "other", started: now - 2 * H - 30 * MIN, finished: now - 95 * MIN, family: "Claude" } ],
648 duplicateOf: "tk-7f3a", needs: "stopped",
649 thread: [] },
650 { id: "tk-91c4", project: "woodstar", title: "iOS edge swipe to go back doesn't work on panes", creator: "nora", stage: "ready_to_merge", changed: now - 50 * MIN, created: now - 2 * H - 10 * MIN,
651 source: { time: "19:52", msg: "m-77", who: "nora" },
652 branch: "equipo/tk-91c4-ios-edge-swipe-panes", base: "4e1f0a9", sha: "e71d20b",
653 brief: "Edge swipe to go back does nothing inside panes. Each pane has its own navigation stack.",
654 findings: [{ text: "Same cause as tk-7f3a: the pane host swallows the gesture.", path: "ios/Woodstar/Navigation/PaneNavigationHost.swift", line: 41, at: now - 2 * H }],
655 steps: [
656 { specialist: "engineering", attempt: 1, state: "done", started: now - 2 * H, finished: now - 70 * MIN, pushed: true, sha: "e71d20b", family: "GPT", summary: "Forward the edge swipe from `PaneNavigationHost` to the stack." },
657 { specialist: "checks", state: "done", started: now - 70 * MIN, finished: now - 69 * MIN, checks: "cannot", reason: "needs macOS" },
658 { specialist: "review", state: "done", started: now - 69 * MIN, finished: now - 50 * MIN, verdict: "approve", label: "another model family", family: "Claude", findings: [] }
659 ],
660 duplicateOf: "tk-7f3a", needs: "merge_without_checks",
661 thread: [] },
662 { id: "tk-a2d9", project: "suite", title: "Replace em dash in README", creator: "paul", stage: "ready_to_merge", changed: now - 12 * MIN, created: now - 58 * MIN,
663 source: { time: "20:41", msg: "m-452", who: "paul" },
664 branch: "equipo/tk-a2d9-replace-em-dash-readme", base: "7a0c1d3", sha: "3d9e0f1",
665 brief: "The README has one em dash left, in the sign-in section. Replace it with a full stop and a new sentence.",
666 findings: [],
667 steps: [
668 { specialist: "engineering", attempt: 1, state: "done", started: now - 55 * MIN, finished: now - 40 * MIN, pushed: true, sha: "3d9e0f1", family: "Claude", summary: "Split the sentence at the em dash in `README.md`." },
669 { specialist: "checks", state: "done", started: now - 40 * MIN, finished: now - 39 * MIN, checks: "passed", gate: "make ci" },
670 { specialist: "review", state: "done", started: now - 39 * MIN, finished: now - 12 * MIN, verdict: "approve", label: "another model family", family: "GPT", findings: [] }
671 ],
672 thread: [] },
673 { id: "tk-b3e0", project: "suite", title: "Fix line break in README", creator: "nora", stage: "ready_to_merge", changed: now - 25 * MIN, created: now - 70 * MIN,
674 source: { time: "20:29", msg: "m-81", who: "nora" },
675 branch: "equipo/tk-b3e0-fix-line-break-readme", base: "7a0c1d3", sha: "f04c8a7",
676 brief: "A hard line break in the teams section splits a sentence in two on the rendered page.",
677 findings: [],
678 steps: [
679 { specialist: "engineering", attempt: 1, state: "done", started: now - 68 * MIN, finished: now - 50 * MIN, pushed: true, sha: "f04c8a7", family: "Claude", summary: "Joined the two lines in `README.md`." },
680 { specialist: "checks", state: "done", started: now - 50 * MIN, finished: now - 49 * MIN, checks: "passed", gate: "make ci" },
681 { specialist: "review", state: "done", started: now - 49 * MIN, finished: now - 25 * MIN, verdict: "approve", label: "another model family", family: "GPT", findings: [] }
682 ],
683 thread: [] },
684 { id: "tk-c4f1", project: "equipo", title: "Task list loses its scroll position after a refresh", creator: "paul", stage: "in_progress", changed: now - 4 * MIN - 12000, created: now - 9 * MIN,
685 source: { time: "21:14", msg: "m-466", who: "paul" },
686 branch: "equipo/tk-c4f1-task-list-scroll-position", base: "a0d418f",
687 brief: "When the task list refreshes itself, the page jumps back to the top. I lose my place every minute or so.",
688 findings: [{ text: "The live swap replaces the whole list; the browser has nothing to anchor to.", path: "internal/equipo/static/live.js", line: 88, at: now - 6 * MIN }],
689 steps: [ { specialist: "engineering", attempt: 1, state: "running", started: now - 4 * MIN - 12000, family: "Claude",
690 activity: ["Reading internal/equipo/static/live.js", "Searching for the swap", "Reading nav-stream.js", "Editing live.js", "Running go test ./internal/equipo", "Committing", "Pushing to Amadan"], activityAt: 4 } ],
691 thread: [] },
692 { id: "tk-d5a2", project: "woodstar", title: "Timeline jumps when images load", creator: "paul", stage: "investigated", changed: now - 7 * MIN, created: now - 16 * MIN,
693 source: { time: "21:07", msg: "m-461", who: "paul" },
694 brief: "Scrolling the timeline, the list shifts under my thumb as images arrive.",
695 findings: [{ text: "Image cells size themselves after the image arrives; the list needs the size up front.", path: "ios/Woodstar/Timeline/ImageCell.swift", line: 22, at: now - 8 * MIN }],
696 steps: [],
697 question: { text: "Does it jump on the first load only, or every time you scroll back up?", options: ["First load only", "Every time"] }, needs: "question",
698 queued: true,
699 thread: [] },
700 { id: "tk-e6b3", project: "suite", title: "Rename the headings in CONTRIBUTING", creator: "paul", stage: "done", changed: now - 2 * D, created: now - 2 * D - 2 * H,
701 source: { time: "16:02", msg: "m-390", who: "paul" },
702 branch: "equipo/tk-e6b3-rename-contributing-headings", base: "5b2e9c0", sha: "9e1c2d4", merged: "c7d0a52",
703 brief: "The CONTRIBUTING headings still say 'Pull requests'. On Amadan they are branches.",
704 findings: [],
705 steps: [
706 { specialist: "engineering", attempt: 1, state: "done", started: now - 2 * D - 2 * H, finished: now - 2 * D - 80 * MIN, pushed: true, sha: "9e1c2d4", family: "Claude", summary: "Renamed four headings and the one sentence under each." },
707 { specialist: "checks", state: "done", started: now - 2 * D - 80 * MIN, finished: now - 2 * D - 79 * MIN, checks: "passed", gate: "make ci" },
708 { specialist: "review", state: "done", started: now - 2 * D - 79 * MIN, finished: now - 2 * D - 30 * MIN, verdict: "approve", label: "another model family", family: "GPT", findings: [] }
709 ],
710 mergedAt: now - 2 * D,
711 thread: [] }
712];
713const byId = id => TASKS.find(t => t.id === id);
714const SPECIALIST_NAME = { engineering: "Engineering", review: "Review", checks: "Checks", coordinator: "Coordinator" };
715
716/* ── Small helpers ───────────────────────────────────────────────── */
717function esc(s) { return String(s).replace(/[&<>"]/g, c => ({ "&": "&amp;", "<": "&lt;", ">": "&gt;", '"': "&quot;" }[c])); }
718function md(s) {
719 const blocks = String(s).split(/\n\s*\n/);
720 return blocks.map(b => {
721 const lines = b.split("\n");
722 if (lines.every(l => /^- /.test(l))) return "<ul>" + lines.map(l => "<li>" + inline(l.slice(2)) + "</li>").join("") + "</ul>";
723 return "<p>" + inline(lines.join(" ")) + "</p>";
724 }).join("");
725 function inline(t) { return esc(t).replace(/\*\*(.+?)\*\*/g, "<strong>$1</strong>").replace(/`([^`]+)`/g, "<code>$1</code>"); }
726}
727function ago(t) {
728 const d = now - t;
729 if (d < MIN) return "just now";
730 if (d < H) return Math.round(d / MIN) + " min ago";
731 if (d < D) return Math.round(d / H) + " h ago";
732 const n = Math.round(d / D); return n === 1 ? "yesterday" : n + " days ago";
733}
734function clock(t) { const x = new Date(t); return String(x.getHours()).padStart(2, "0") + ":" + String(x.getMinutes()).padStart(2, "0"); }
735function dur(ms) { const s = Math.max(0, Math.round(ms / 1000)); const m = Math.floor(s / 60); return m >= 60 ? Math.floor(m / 60) + " h " + (m % 60) + " min" : m + ":" + String(s % 60).padStart(2, "0"); }
736function span(ms) { const s = Math.max(0, Math.round(ms / 1000)); if (s < 60) return s + " s"; const m = Math.round(s / 60); return m < 60 ? m + " min" : Math.floor(m / 60) + " h " + (m % 60) + " min"; }
737function elapsed(started) { return `<span class="elapsed" data-since="${started}">${dur(Date.now() - started)}</span>`; }
738function av(key, size) { const p = PEOPLE[key]; if (!p || !p.h) return ""; return `<span class="av" style="--h:${p.h}" title="${esc(p.address)}"${size ? ` data-size="${size}"` : ""} aria-hidden="true">${p.name[0]}</span>`; }
739function who(key) { const p = PEOPLE[key]; return `<span class="who">${av(key)}<a href="#people" title="${esc(p.address)}">${p.me ? "You" : p.name}</a></span>`; }
740function mono(pk, size) { const p = PROJECTS[pk]; return `<span class="mono" style="--h:${p.h}"${size ? ` data-size="${size}"` : ""} title="${esc(p.title)}" aria-hidden="true">${p.letter}</span>`; }
741function pluralTasks(n) { return n === 1 ? "1 task" : n + " tasks"; }
742
743/* ── Derived state: what is running, what needs whom ─────────────── */
744function lastStep(t) { return t.steps[t.steps.length - 1]; }
745function running(t) { const s = lastStep(t); return s && (s.state === "running" || s.state === "queued") ? s : null; }
746function stopped(t) { const s = lastStep(t); return s && s.state === "failed" && t.stage !== "done" && t.stage !== "cancelled" ? s : null; }
747function checksOf(t) {
748 const r = running(t); if (r && r.specialist === "checks") return { state: "running" };
749 for (let i = t.steps.length - 1; i >= 0; i--) { const s = t.steps[i]; if (s.specialist === "checks" && s.state === "done") return { state: s.checks, reason: s.reason, gate: s.gate }; }
750 return null;
751}
752function reviewOf(t) {
753 const r = running(t); if (r && r.specialist === "review") return { state: "running" };
754 for (let i = t.steps.length - 1; i >= 0; i--) { const s = t.steps[i]; if (s.specialist === "review" && s.state === "done") return { state: s.verdict, label: s.label, family: s.family }; }
755 return null;
756}
757function bucket(t) {
758 if (t.stage === "done" || t.stage === "cancelled") return "done";
759 if (t.needs && PEOPLE[t.creator].me) return "needs";
760 if (t.stage === "ready_to_merge" || t.stage === "merging") return "ready";
761 return "progress";
762}
763const BUCKETS = [["needs", "Needs you", "Your decisions, in one tap."], ["progress", "In progress"], ["ready", "Ready to merge", "The coordinator merges these. It asks only when checks could not run."], ["done", "Done"]];
764function stageTone(t) { if (stopped(t)) return "negative"; if (t.stage === "done") return "positive"; if (t.needs && PEOPLE[t.creator].me) return "attention"; return ""; }
765function stageLabel(t) {
766 const s = stopped(t); if (s) return "Stopped: " + ({ other: "something went wrong", runner_restarted: "the runner restarted", step_timeout: "it ran out of time" }[s.reason] || "something went wrong");
767 return STAGE_NAME[t.stage];
768}
769function trackIndex(t) { return t.stage === "merging" ? 4 : t.stage === "cancelled" ? 0 : STAGES.indexOf(t.stage); }
770function liveMark(t) { return !!running(t) || t.stage === "merging" || (t.stage === "investigated" && t.coordLooking); }
771
772/* ── Pieces: track, badges, chips ────────────────────────────────── */
773function track(t) {
774 const cur = trackIndex(t), live = liveMark(t), tone = stageTone(t);
775 return `<ol class="track" aria-label="${esc(stageLabel(t))}">` + STAGES.map((s, i) => {
776 const st = i < cur ? "done" : i === cur ? "current" : "todo";
777 return `<li data-s="${st}"${i === cur && tone ? ` data-tone="${tone}"` : ""}${i === cur && live ? " data-live" : ""} title="${STAGE_NAME[s]}">${i === cur && live ? mark("s") : ""}</li>`;
778 }).join("") + "</ol>";
779}
780function trackFull(t) {
781 const cur = trackIndex(t), live = liveMark(t), tone = stageTone(t);
782 const when = { noted: t.created, investigated: t.findings[0] && t.findings[0].at, in_progress: t.steps[0] && t.steps[0].started, in_review: t.steps.find(s => s.specialist === "review") && t.steps.find(s => s.specialist === "review").started, ready_to_merge: t.stage === "ready_to_merge" || t.stage === "merging" || t.stage === "done" ? (t.steps.find(s => s.specialist === "review") || {}).finished : null, done: t.mergedAt };
783 return `<ol class="track-full">` + STAGES.map((s, i) => {
784 const st = i < cur ? "done" : i === cur ? "current" : "todo";
785 const label = i === cur && t.stage === "merging" ? "Merging…" : i === cur && stopped(t) ? "Stopped" : STAGE_NAME[s];
786 return `<li data-s="${st}"${i === cur && tone ? ` data-tone="${tone}"` : ""}${i === cur && live ? " data-live" : ""}><span class="dot">${i === cur && live ? mark("s") : ""}</span><span>${label}</span>${st !== "todo" && when[s] ? `<small>${clock(when[s])}</small>` : ""}</li>`;
787 }).join("") + "</ol>";
788}
789function checksBadge(c, pk) {
790 if (!c) return "";
791 if (c.state === "running") return `<span class="badge" data-tone="live" title="Running checks">${mark("s")} Checks</span>`;
792 if (c.state === "passed") return `<span class="badge" data-tone="positive" title="Checks passed (${esc(c.gate || "")})">${icon("check")} Checks passed</span>`;
793 if (c.state === "failed") return `<span class="badge" data-tone="negative" title="Checks failed (${esc(c.gate || "")})">${icon("x")} Checks failed</span>`;
794 return `<span class="badge" title="Checks can't run here (${esc(c.reason)}). ${esc(PROJECTS[pk].checks.note)}">${icon("help-circle")} Checks: ${esc(c.reason)}</span>`;
795}
796function reviewBadge(r) {
797 if (!r) return "";
798 if (r.state === "running") return `<span class="badge" data-tone="live" title="Reviewing">${mark("s")} Review</span>`;
799 const fam = r.label === "same family, same account" ? "Reviewed by the same model family and the same account as Engineering" : r.label === "same family" ? "Reviewed by the same model family as Engineering" : "Reviewed by another model family (" + esc(r.family) + ")";
800 if (r.state === "approve") return `<span class="badge" data-tone="positive" title="${fam}">${icon("check-circle")} Approved</span>`;
801 return `<span class="badge" data-tone="warning" title="${fam}">${icon("alert-triangle")} Changes requested</span>`;
802}
803function workingChip(t) {
804 const r = running(t);
805 if (r) {
806 const name = SPECIALIST_NAME[r.specialist];
807 return `<span class="chip">${mark("s")} ${name} working ${elapsed(r.started)}</span>`;
808 }
809 if (t.stage === "merging") return `<span class="chip">${mark("s")} Coordinator merging ${elapsed(t.mergingSince)}</span>`;
810 if (t.coordLooking) return `<span class="chip">${mark("s")} Coordinator looking ${elapsed(t.coordLooking)}</span>`;
811 if (t.queued) return `<span class="chip">${icon("clock")} Waiting for Engineering</span>`;
812 if (t.needs && !PEOPLE[t.creator].me) return `<span class="chip">Waiting for ${PEOPLE[t.creator].name}</span>`;
813 if (t.needs && PEOPLE[t.creator].me) return `<span class="chip">Waiting for you</span>`;
814 return "";
815}
816function sourceLine(t) {
817 const mine = PEOPLE[t.source.who].me;
818 return `<a href="#conversation/${t.source.msg}" title="Opens the conversation at that message">${mine ? "From your conversation" : "From " + PEOPLE[t.source.who].name + "'s conversation"}, ${clock(t.created)}</a>`;
819}
820
821/* ── A task row ──────────────────────────────────────────────────── */
822function taskRow(t, opts) {
823 opts = opts || {};
824 const mine = PEOPLE[t.creator].me, dup = t.duplicateOf && byId(t.duplicateOf);
825 let menu = "";
826 if (mine && t.stage !== "done" && t.stage !== "cancelled") {
827 const items = [];
828 if (dup) items.push(`<button type="button">Merge into "${esc(dup.title)}"<small>Keeps that task; this one is closed as a duplicate</small></button>`);
829 if (stopped(t)) items.push(`<button type="button">Retry</button>`);
830 items.push(`<button type="button" class="danger">Cancel</button>`);
831 menu = `<details class="menu"><summary aria-label="More">${icon("kebab")}</summary><div>${items.join("")}</div></details>`;
832 }
833 return `<li class="row" data-task="${t.id}" data-stage="${t.stage}">
834 ${mono(t.project)}
835 <div class="body">
836 <div class="title"><a class="row-link" href="#task/${t.id}" data-go="task" data-id="${t.id}">${esc(t.title)}</a></div>
837 <div class="meta">
838 <span class="track-line">${track(t)}<span class="stage-name"${stageTone(t) ? ` data-tone="${stageTone(t)}"` : ""}>${esc(stageLabel(t))}</span></span>
839 ${workingChip(t)}
840 <span class="who">${av(t.creator)}<a href="#people">${mine ? "You" : PEOPLE[t.creator].name}</a></span>
841 <span>${sourceLine(t)}</span>
842 </div>
843 ${dup ? `<div class="dup">${icon("alert-triangle")}<span>Possible duplicate of <a href="#task/${dup.id}" data-go="task" data-id="${dup.id}">${esc(dup.title)}</a>${mine ? "" : ` (${PEOPLE[t.creator].name} decides)`}</span></div>` : ""}
844 </div>
845 <div class="side">
846 <span class="top">${menu}<span class="ago" title="${new Date(t.changed).toLocaleString()}">${ago(t.changed)}</span></span>
847 <span class="badges">${t.stage === "done" ? `<span class="badge" data-tone="quiet" title="Merged into main at ${t.merged}">Merged</span>` : checksBadge(checksOf(t), t.project) + reviewBadge(reviewOf(t))}</span>
848 </div>
849 </li>`;
850}
851
852/* ── Screens ─────────────────────────────────────────────────────── */
853const state = { screen: "tasks", taskId: "tk-7f3a", projectId: "woodstar", project: "", person: "", openSpec: {} };
854
855function filtered() { return TASKS.filter(t => (!state.project || t.project === state.project) && (!state.person || t.creator === state.person)); }
856function screenTasks(opts) {
857 opts = opts || {};
858 const list = opts.tasks || filtered();
859 const groups = BUCKETS.map(([k, name, hint]) => {
860 const ts = list.filter(t => bucket(t) === k).sort((a, b) => b.changed - a.changed);
861 if (!ts.length) return "";
862 return `<section class="group"><h2>${name} <span class="n">${ts.length}</span>${hint && !opts.compact ? `<span class="hint">${hint}</span>` : ""}</h2><ol class="rows">${ts.map(taskRow).join("")}</ol></section>`;
863 }).join("");
864 const projOpts = [["", "All projects"]].concat(Object.keys(PROJECTS).map(k => [k, PROJECTS[k].title]));
865 const peopleOpts = [["", "Anyone"], ["paul", "You"], ["nora", "Nora"]];
866 const filters = opts.compact ? "" : `<div class="filters">
867 <details class="filter"${state.project ? " data-active" : ""}><summary>${state.project ? PROJECTS[state.project].title : "All projects"} ${icon("chevron-down")}</summary><div>${projOpts.map(([v, l]) => `<button type="button" data-filter="project" data-value="${v}" aria-pressed="${state.project === v}">${v ? mono(v, "s") : ""}${l}</button>`).join("")}</div></details>
868 <details class="filter"${state.person ? " data-active" : ""}><summary>${state.person ? (PEOPLE[state.person].me ? "Filed by you" : "Filed by " + PEOPLE[state.person].name) : "Anyone"} ${icon("chevron-down")}</summary><div>${peopleOpts.map(([v, l]) => `<button type="button" data-filter="person" data-value="${v}" aria-pressed="${state.person === v}">${v ? av(v) : ""}${l}</button>`).join("")}</div></details>
869 </div>`;
870 return `<div class="inner"><div class="page-head"><h1>Tasks</h1><p>${pluralTasks(list.length)} across ${Object.keys(PROJECTS).length} projects</p></div>${filters}${groups || `<p class="empty">No tasks here. Tell the coordinator what needs doing.</p>`}</div>`;
871}
872
873function decisionCard(t, where) {
874 const mine = PEOPLE[t.creator].me; if (!t.needs || !mine) return "";
875 const title = where === "needs" ? `<div class="d-title"><a href="#task/${t.id}" data-go="task" data-id="${t.id}">${esc(t.title)}</a><span class="quiet">${PROJECTS[t.project].title} · ${sourceLine(t)}</span></div>` : "";
876 if (t.needs === "merge_without_checks") {
877 const r = reviewOf(t);
878 return `<div class="decision">${where === "needs" ? mono(t.project) : ""}${title}
879 <p class="d-why">Review <strong>approved</strong> the fix at <code>${t.sha}</code>. Checks could not run here: <strong>${esc(checksOf(t).reason)}</strong>, and no Mac runner is enrolled yet.</p>
880 <p class="d-ask">Merge without checks?</p>
881 <div class="d-actions"><button class="btn" data-primary type="button">Merge</button><button class="btn" type="button">Wait for checks</button><span class="quiet">Waiting leaves it ready until a Mac runner joins.</span></div></div>`;
882 }
883 if (t.needs === "stopped") {
884 const dup = t.duplicateOf && byId(t.duplicateOf);
885 return `<div class="decision" data-tone="attention">${where === "needs" ? mono(t.project) : ""}${title}
886 <p class="d-why">Engineering <strong>stopped</strong>: something went wrong on attempt 1.${dup ? ` This looks like a duplicate of <a href="#task/${dup.id}" data-go="task" data-id="${dup.id}">${esc(dup.title)}</a>, which is ${dup.stage === "ready_to_merge" ? "ready to merge" : STAGE_NAME[dup.stage].toLowerCase()}.` : ""}</p>
887 <p class="d-ask">${dup ? "Fold it into that task?" : "Try again?"}</p>
888 <div class="d-actions">${dup ? `<button class="btn" data-primary type="button">Merge into that task</button><button class="link" type="button">Retry</button>` : `<button class="btn" data-primary type="button">Retry</button>`}<button class="link" type="button">Cancel this task</button></div></div>`;
889 }
890 if (t.needs === "question") {
891 return `<div class="decision">${where === "needs" ? mono(t.project) : ""}${title}
892 <p class="d-why">The coordinator found that <strong>image cells size themselves after the image arrives</strong> and wants to know how far the fix should reach.</p>
893 <p class="d-ask">${esc(t.question.text)}</p>
894 <div class="d-actions">${t.question.options.map(o => `<button class="btn" type="button">${esc(o)}</button>`).join("")}<button class="link" type="button">Reply in the conversation</button></div></div>`;
895 }
896 return "";
897}
898
899function timeline(t) {
900 const items = [];
901 const mine = PEOPLE[t.creator].me;
902 items.push({ kind: "noted", at: t.created, what: `<b>Noted</b> by ${mine ? "you" : PEOPLE[t.creator].name}`, detail: `${sourceLine(t)}` });
903 if (t.findings.length) items.push({ kind: "finding", at: t.findings[0].at, what: `<b>Coordinator</b> looked into it`, detail: t.findings.map(f => `${esc(f.text)}<br><small class="quiet"><code>${esc(f.path)}:${f.line}</code></small>`).join("<br>") });
904 if (t.coordLooking) items.push({ kind: "live", live: true, at: t.coordLooking, what: `<span class="live-line">Coordinator looking into it ${elapsed(t.coordLooking)}</span>` });
905 if (t.question && t.needs === "question") items.push({ kind: "decision", at: t.changed, what: `<b>Coordinator</b> asked you`, detail: `${esc(t.question.text)}`, card: decisionCard(t, "task") });
906 if (t.queued) items.push({ kind: "queued", at: t.changed, what: `<b>Waiting for Engineering</b>`, detail: `Behind ${esc(byId("tk-c4f1").title)}.` });
907 t.steps.forEach(s => {
908 const name = SPECIALIST_NAME[s.specialist];
909 if (s.state === "running") {
910 const lines = s.activity ? s.activity.slice(0, s.activityAt + 1) : [];
911 const cur = lines[lines.length - 1] || "Working";
912 items.push({ kind: "step", live: true, at: s.started, what: `<span class="live-line">${name}${s.attempt ? ", attempt " + s.attempt : ""} ${elapsed(s.started)}</span>`, detail: `${esc(cur)}` });
913 return;
914 }
915 if (s.state === "failed") { items.push({ kind: "stopped", at: s.finished, what: `<b>${name}, attempt ${s.attempt}</b> stopped`, detail: stageLabel(t).replace("Stopped: ", "") + "." }); return; }
916 if (s.specialist === "engineering") {
917 items.push({ kind: "step", at: s.finished, what: `<b>Engineering, attempt ${s.attempt}</b>${s.round ? ` (fix round ${s.round})` : ""} <time>${span(s.finished - s.started)}</time>`, detail: `<div class="md">${md(s.summary || "")}</div>`,
918 receipt: s.pushed ? `<span>Pushed <code>${s.sha}</code></span><a href="#amadan" target="_blank" rel="noopener">Open on Amadan</a>` : "" });
919 } else if (s.specialist === "checks") {
920 const c = { state: s.checks, reason: s.reason, gate: s.gate };
921 items.push({ kind: "step", at: s.finished, what: `<b>Checks</b> on <code>${t.sha}</code> ${checksBadge(c, t.project)}`, detail: s.checks === "cannot" ? esc(PROJECTS[t.project].checks.note) : s.checks === "passed" ? `${esc(s.gate)} passed in ${span(s.finished - s.started)}.` : "" });
922 } else if (s.specialist === "review") {
923 items.push({ kind: "step", at: s.finished, what: `<b>Review</b> on <code>${t.sha}</code> ${reviewBadge({ state: s.verdict, label: s.label, family: s.family })} <time>${span(s.finished - s.started)}</time>`, detail: s.findings && s.findings.length ? `<ul class="findings">${s.findings.map(f => `<li>${esc(f.text)}<small><code>${esc(f.path)}:${f.line}</code></small></li>`).join("")}</ul>` : (s.verdict === "approve" ? "No findings." : "") });
924 }
925 });
926 if (t.stage === "ready_to_merge" || t.stage === "merging" || t.stage === "done") {
927 const rv = t.steps.filter(s => s.specialist === "review" && s.state === "done").pop();
928 if (rv) items.push({ kind: "ready", at: rv.finished, what: `<b>Ready to merge</b>`, detail: t.needs === "merge_without_checks" ? "" : "The coordinator merges it next." , card: t.stage === "ready_to_merge" ? decisionCard(t, "task") : "" });
929 }
930 if (t.stage === "merging") items.push({ kind: "merging", live: true, at: t.mergingSince, what: `<span class="live-line">Coordinator merging into main ${elapsed(t.mergingSince)}</span>` });
931 if (t.stage === "done") items.push({ kind: "merged", at: t.mergedAt, what: `<b>Merged</b> into main`, detail: `<code>${t.merged}</code>. The coordinator told ${mine ? "you" : PEOPLE[t.creator].name} in the conversation.`, receipt: `<a href="#amadan" target="_blank" rel="noopener">Open on Amadan</a>` });
932 return `<ol class="tl">${items.map(it => `<li data-kind="${it.kind}"${it.live ? " data-live" : ""}${it.fresh ? " data-new" : ""}><span class="node">${it.live ? mark() : ""}</span><div><div class="what">${it.what}${it.at && !it.live ? ` <time title="${new Date(it.at).toLocaleString()}">${clock(it.at)}</time>` : ""}</div>${it.detail ? `<div class="detail">${it.detail}</div>` : ""}${it.receipt ? `<div class="receipt">${it.receipt}</div>` : ""}${it.card || ""}</div></li>`).join("")}</ol>`;
933}
934
935function summaryOf(t) {
936 const r = running(t), mine = PEOPLE[t.creator].me;
937 if (t.stage === "done") return `Merged into main yesterday. Engineering made the change in one attempt, checks passed and Review approved it.`;
938 if (stopped(t)) return `Engineering stopped on attempt 1: something went wrong.${t.duplicateOf ? " This looks like the same bug as another task that is already fixed." : ""} ${mine ? "Your call below." : PEOPLE[t.creator].name + " decides what happens next."}`;
939 if (t.stage === "merging") return `${mark()}Review approved it and checks passed. The coordinator is merging it into main now.`;
940 if (t.needs === "merge_without_checks") return `Engineering fixed it in one attempt and Review approved the fix. Checks need a Mac, which the team does not have yet, so ${mine ? "it waits on you" : "it waits on " + PEOPLE[t.creator].name}.`;
941 if (t.stage === "ready_to_merge") return `Fixed, checked and approved. The coordinator merges it next.`;
942 if (r) { const cur = r.activity ? r.activity[r.activityAt] : "working"; return `${mark()}${SPECIALIST_NAME[r.specialist]} is on it now: ${esc(cur.toLowerCase())}. ${r.attempt ? "Attempt " + r.attempt + ", " : ""}${span(Date.now() - r.started)} so far.`; }
943 if (t.needs === "question") return `The coordinator has a question before handing it to Engineering.`;
944 if (t.queued) return `Looked into. Engineering picks it up when it finishes its current task.`;
945 return STAGE_NAME[t.stage] + ".";
946}
947
948function screenTask(id) {
949 const t = byId(id), p = PROJECTS[t.project], mine = PEOPLE[t.creator].me;
950 const steps = t.steps.filter(s => s.specialist === "engineering" && s.summary);
951 const thread = `<section class="thread"><h2>Questions and notes</h2>
952 <ol class="feed">${t.thread.length ? t.thread.map(m => m.own ? `<li class="msg" data-own><div class="m-meta"><time>${m.at}</time></div><div class="bubble"><p>${esc(m.text)}</p></div></li>` : `<li class="msg"><div class="m-meta"><span>${icon("message-circle")}${SPECIALIST_NAME[m.who]}</span><time>${m.at}</time></div><div class="bubble"><p>${md(m.text).replace(/^<p>|<\/p>$/g, "")}</p></div></li>`).join("") : `<li class="sysnote">No questions or notes yet.</li>`}</ol>
953 <div class="composer-dock"><div class="composer"><div class="ta">Ask Engineering about this work</div><div class="tools"><span>Asking Engineering</span><button class="link" type="button">change</button><button class="btn" type="button">Send</button></div></div></div>
954 </section>`;
955 return `<div class="inner">
956 <header class="t-head">${mono(t.project, "l")}
957 <div>
958 <div class="crumbs"><a href="#tasks" data-go="tasks">Tasks</a><span>›</span><a href="#project/${t.project}" data-go="project" data-id="${t.project}">${p.title}</a></div>
959 <h1>${esc(t.title)}</h1>
960 <div class="filed">${who(t.creator)}<span>${sourceLine(t)}</span><span class="ago">Changed ${ago(t.changed)}</span></div>
961 </div>
962 ${trackFull(t)}
963 </header>
964 <p class="t-summary">${summaryOf(t)}</p>
965 ${t.stage !== "done" && !stopped(t) && !t.question && t.needs && mine ? "" : ""}
966 <div class="t-cols">
967 <section><h2>What happened</h2>${timeline(t)}
968 <details class="details"><summary>${icon("chevron-down")} Details</summary>
969 <div class="d-grid">
970 <div><h3>The brief</h3><div class="md">${md(t.brief)}</div></div>
971 ${t.findings.length ? `<div><h3>Findings</h3><ul class="findings md">${t.findings.map(f => `<li>${esc(f.text)}<br><small class="quiet"><code>${esc(f.path)}:${f.line}</code></small></li>`).join("")}</ul></div>` : ""}
972 ${steps.map(s => `<div><h3>Engineering, attempt ${s.attempt}</h3><div class="md">${md(s.summary)}</div></div>`).join("")}
973 <div><h3>Where it lives</h3><dl class="kv">${t.branch ? `<dt>Branch</dt><dd><code>${esc(t.branch)}</code></dd>` : ""}${t.sha ? `<dt>Commit</dt><dd><code>${t.sha}</code> on <code>${t.base}</code></dd>` : ""}${t.merged ? `<dt>Merged as</dt><dd><code>${t.merged}</code></dd>` : ""}<dt>Task</dt><dd><code>${t.id}</code></dd>${t.branch ? `<dt></dt><dd><a href="#amadan" target="_blank" rel="noopener">Open on Amadan</a></dd>` : ""}</dl></div>
974 </div>
975 </details>
976 </section>
977 ${thread}
978 </div>
979 </div>`;
980}
981
982function spread(pk) {
983 const ts = TASKS.filter(t => t.project === pk), n = { needs: 0, progress: 0, ready: 0, done: 0 };
984 ts.forEach(t => { const b = t.needs && !(t.stage === "done") ? "needs" : bucket(t); n[b]++; });
985 const total = ts.length || 1;
986 const bar = ["needs", "progress", "ready", "done"].map(k => n[k] ? `<i data-k="${k}" style="inline-size:${(n[k] / total * 100).toFixed(1)}%" title="${n[k]} ${k === "needs" ? "waiting on someone" : k === "progress" ? "in progress" : k === "ready" ? "ready to merge" : "done"}"></i>` : "").join("");
987 const words = [];
988 if (n.needs) words.push(`${n.needs} waiting on someone`); if (n.progress) words.push(`${n.progress} in progress`); if (n.ready) words.push(`${n.ready} ready`); if (n.done) words.push(`${n.done} done`);
989 return { html: `<span class="spread"><span class="bar">${bar}</span><span class="n">${pluralTasks(ts.length)}</span></span>`, words: words.join(", "), n };
990}
991function projectFacts(p, long) {
992 return `<span>${icon(p.platform === "iOS" ? "phone" : "code")} ${p.stack.join(", ")}</span>
993 <span>${icon("git")} ${p.repos.length === 1 ? "1 repository" : p.repos.length + " repositories"}</span>
994 <span data-tone="${p.checks.here ? "positive" : "warning"}">${icon(p.checks.here ? "check-circle" : "help-circle")} ${p.checks.here ? "Checks run here" + (long ? " (" + p.checks.gate + ")" : "") : "Checks need a Mac"}</span>`;
995}
996function screenProjects() {
997 const rows = Object.keys(PROJECTS).map(pk => {
998 const p = PROJECTS[pk], s = spread(pk), last = TASKS.filter(t => t.project === pk).sort((a, b) => b.changed - a.changed)[0];
999 return `<li class="row prow" data-project="${pk}">
1000 ${mono(pk, "l")}
1001 <div class="body">
1002 <div class="title"><a class="row-link" href="#project/${pk}" data-go="project" data-id="${pk}">${p.title}</a></div>
1003 <p class="desc">${esc(p.desc)}</p>
1004 <div class="facts">${projectFacts(p)}<span class="avs" title="${p.people.map(k => PEOPLE[k].address).join(", ")}">${p.people.map(k => av(k)).join("")}</span></div>
1005 </div>
1006 <div class="side"><span class="ago">${last ? ago(last.changed) : ""}</span>${s.html}<span class="quiet">${s.words}</span></div>
1007 </li>`;
1008 }).join("");
1009 return `<div class="inner"><div class="page-head"><h1>Projects</h1><p>What the coordinator knows about each one. It adds projects as you mention them.</p></div>
1010 <section class="group"><ol class="rows">${rows}</ol></section>
1011 <div class="legend"><span><i style="background: var(--rst-tone-warning-fg)"></i>waiting on someone</span><span><i style="background: var(--rst-accent)"></i>in progress</span><span><i style="background: color-mix(in srgb, var(--rst-accent) 45%, var(--rst-surface))"></i>ready to merge</span><span><i style="background: var(--rst-line-strong); opacity: .5"></i>done</span></div>
1012 </div>`;
1013}
1014function projectActivity(pk) {
1015 const ev = [];
1016 TASKS.filter(t => t.project === pk).forEach(t => {
1017 ev.push({ at: t.created, text: `${PEOPLE[t.creator].me ? "You" : PEOPLE[t.creator].name} noted <a href="#task/${t.id}" data-go="task" data-id="${t.id}">${esc(t.title)}</a>` });
1018 t.steps.forEach(s => {
1019 if (s.finished && s.specialist === "engineering" && s.state === "done") ev.push({ at: s.finished, text: `Engineering pushed a fix for <a href="#task/${t.id}" data-go="task" data-id="${t.id}">${esc(t.title)}</a>` });
1020 if (s.finished && s.specialist === "review") ev.push({ at: s.finished, text: `Review ${s.verdict === "approve" ? "approved" : "asked for changes to"} <a href="#task/${t.id}" data-go="task" data-id="${t.id}">${esc(t.title)}</a>` });
1021 if (s.state === "failed") ev.push({ at: s.finished, text: `Engineering stopped on <a href="#task/${t.id}" data-go="task" data-id="${t.id}">${esc(t.title)}</a>` });
1022 });
1023 if (t.stage === "done") ev.push({ at: t.mergedAt, text: `Merged <a href="#task/${t.id}" data-go="task" data-id="${t.id}">${esc(t.title)}</a> into main` });
1024 });
1025 return ev.sort((a, b) => b.at - a.at).slice(0, 7);
1026}
1027function screenProject(pk) {
1028 const p = PROJECTS[pk], s = spread(pk), ts = TASKS.filter(t => t.project === pk);
1029 return `<div class="inner">
1030 <div class="crumbs quiet" style="margin-block-end: var(--rst-sp-2)"><a href="#projects" data-go="projects">Projects</a></div>
1031 <header class="p-head">${mono(pk, "l")}
1032 <div><h1>${p.title}</h1><p>${esc(p.desc)}</p><div class="facts">${projectFacts(p, true)}</div></div>
1033 <div class="people"><span class="avs">${p.people.map(k => av(k, "l")).join("")}</span><span>${p.people.map(k => PEOPLE[k].me ? "You" : PEOPLE[k].name).join(" and ")}</span></div>
1034 </header>
1035 <div class="p-cols">
1036 <div>
1037 <section class="p-section"><h2>Tasks <span class="quiet">${s.words}</span></h2>${screenTasks({ tasks: ts, compact: true }).replace(/^<div class="inner">.*?<\/div>/, "").replace(/<\/div>$/, "")}</section>
1038 </div>
1039 <aside>
1040 <section class="p-section"><h2>Attachments</h2><ul class="attach">${p.repos.map(r => `<li>${icon("git")}<div><div class="name">${esc(r.name)}</div><div class="sub"><span>${r.branch}</span><span>${esc(r.last)}</span><span>${ago(r.at)}</span></div></div><span class="quiet"><a href="#amadan" target="_blank" rel="noopener">Open on Amadan</a></span></li>`).join("")}</ul>
1041 <p class="quiet" style="margin: var(--rst-sp-2) 0 0">${esc(p.checks.note)}</p></section>
1042 <section class="p-section"><h2>Recently</h2><ol class="activity">${projectActivity(pk).map(e => `<li><time>${ago(e.at).replace(" ago", "")}</time><span>${e.text}</span></li>`).join("")}</ol></section>
1043 <section class="p-section"><h2>Coordinator's notes</h2><ul class="notes">${p.notes.map(n => `<li class="note"><p>${esc(n.text)}</p><div class="cap"><span>${esc(n.from)}</span></div></li>`).join("")}</ul></section>
1044 </aside>
1045 </div>
1046 </div>`;
1047}
1048function screenNeeds() {
1049 const mine = TASKS.filter(t => t.needs && PEOPLE[t.creator].me && t.stage !== "done").sort((a, b) => b.changed - a.changed);
1050 const others = TASKS.filter(t => t.needs && !PEOPLE[t.creator].me && t.stage !== "done");
1051 return `<div class="inner"><div class="page-head"><h1>Needs you</h1><p>${mine.length ? `${mine.length === 1 ? "One decision" : mine.length + " decisions"}, each in one tap.` : "Nothing needs you right now."}</p></div>
1052 ${mine.map(t => decisionCard(t, "needs")).join("")}
1053 ${others.length ? `<section class="group" style="margin-block-start: var(--rst-sp-6)"><h2>Waiting on others <span class="n">${others.length}</span><span class="hint">Only the person who filed a task decides for it.</span></h2><ol class="rows">${others.map(taskRow).join("")}</ol></section>` : ""}
1054 </div>`;
1055}
1056
1057/* ── The rail and the phone index ────────────────────────────────── */
1058function specialists() {
1059 const out = [];
1060 ["engineering", "review", "checks"].forEach(k => {
1061 const t = TASKS.find(x => { const r = running(x); return r && r.specialist === k; });
1062 const queue = k === "engineering" ? TASKS.filter(x => x.queued) : [];
1063 out.push({ key: k, icon: k === "engineering" ? "code" : k === "review" ? "check-circle" : "shield", name: SPECIALIST_NAME[k], task: t, step: t && running(t), queue });
1064 });
1065 return out;
1066}
1067function specRow(s, where) {
1068 const working = !!s.task;
1069 let panel = "";
1070 if (working) {
1071 const st = s.step, lines = st.activity ? st.activity.slice(Math.max(0, st.activityAt - 2), st.activityAt + 1) : ["Working"];
1072 panel = `<div class="spec-panel">
1073 <a class="task" href="#task/${s.task.id}" data-go="task" data-id="${s.task.id}">${esc(s.task.title)}</a>
1074 <div class="where"><span>${PROJECTS[s.task.project].title}</span><span>${STAGE_NAME[s.task.stage]}</span>${st.attempt ? `<span>attempt ${st.attempt}</span>` : ""}<span>${elapsed(st.started)}</span></div>
1075 <ol>${lines.map((l, i) => `<li${i === lines.length - 1 && st.fresh ? " data-new" : ""}><span>${esc(l)}</span><span>${i === lines.length - 1 ? "now" : ""}</span></li>`).join("")}</ol>
1076 ${s.queue.length ? `<div class="queue">${s.queue.length === 1 ? "1 waiting" : s.queue.length + " waiting"}: <a href="#task/${s.queue[0].id}" data-go="task" data-id="${s.queue[0].id}">${esc(s.queue[0].title)}</a></div>` : ""}
1077 </div>`;
1078 }
1079 const open = working && state.openSpec[where + s.key];
1080 const stateHtml = working ? `<span class="state">${mark("s")} ${elapsed(s.step.started)}</span>` : `<span class="state">idle</span>`;
1081 const chev = where === "index" ? (working ? icon("chevron-down").replace('class="icon"', 'class="icon chev"') : icon("chevron-down").replace('class="icon"', 'class="icon chev-r"')) : icon("chevron-down").replace('class="icon"', 'class="icon chev"');
1082 return `<details class="spec" data-spec="${where + s.key}" data-state="${working ? "working" : "idle"}"${open ? " open" : ""}><summary${working ? "" : ' tabindex="-1"'}>${icon(s.icon)}<span>${s.name}</span>${stateHtml}${chev}</summary>${panel}</details>`;
1083}
1084function navItems() {
1085 const open = TASKS.filter(t => t.stage !== "done" && t.stage !== "cancelled").length;
1086 const needs = TASKS.filter(t => t.needs && PEOPLE[t.creator].me && t.stage !== "done").length;
1087 return [
1088 { key: "conversation", icon: "message-circle", name: "Conversation", count: "" },
1089 { key: "projects", icon: "folder", name: "Projects", count: Object.keys(PROJECTS).length },
1090 { key: "tasks", icon: "check-circle", name: "Tasks", count: open },
1091 { key: "needs", icon: "inbox", name: "Needs you", count: needs, attention: needs > 0 }
1092 ];
1093}
1094function rail() {
1095 const cur = state.screen === "task" ? "tasks" : state.screen === "project" ? "projects" : state.screen;
1096 return `<aside class="rail"><a class="brand" href="#">${icon("users")}Oficina</a><nav>
1097 ${navItems().map(n => `<a href="#${n.key}" data-go="${n.key}"${cur === n.key ? ' aria-current="page"' : ""}>${icon(n.icon)}<span>${n.name}</span>${n.count ? `<span class="count"${n.attention ? " data-attention" : ""}>${n.count}</span>` : ""}</a>`).join("")}
1098 <p class="nav-group">Specialists</p>
1099 ${specialists().map(s => specRow(s, "rail")).join("")}
1100 <p class="nav-group">Team</p>
1101 <a href="#people">${icon("users")}<span>People</span><span class="count">2</span></a>
1102 <a href="#notebook">${icon("notebook")}<span>Notebook</span></a>
1103 </nav></aside>`;
1104}
1105function phoneIndex() {
1106 return `<div class="main"><div class="page-head" style="margin-block-end: var(--rst-sp-3)"><h1>Oficina</h1></div>
1107 <ul class="index">${navItems().map(n => `<li><a href="#${n.key}" data-go="${n.key}">${icon(n.icon)}<span>${n.name}</span><span class="count"${n.attention ? " data-attention" : ""}>${n.count || ""}</span>${icon("chevron-down").replace('class="icon"', 'class="icon chev-r"')}</a></li>`).join("")}</ul>
1108 <p class="nav-group">Specialists</p>
1109 <ul class="index">${specialists().map(s => `<li>${specRow(s, "index")}</li>`).join("")}</ul>
1110 <p class="nav-group">Team</p>
1111 <ul class="index"><li><a href="#people">${icon("users")}<span>People</span><span class="count">2</span>${icon("chevron-down").replace('class="icon"', 'class="icon chev-r"')}</a></li><li><a href="#notebook">${icon("notebook")}<span>Notebook</span><span class="count"></span>${icon("chevron-down").replace('class="icon"', 'class="icon chev-r"')}</a></li></ul>
1112 </div>`;
1113}
1114
1115/* ── Render ──────────────────────────────────────────────────────── */
1116function screen() {
1117 switch (state.screen) {
1118 case "task": return screenTask(state.taskId);
1119 case "projects": return screenProjects();
1120 case "project": return screenProject(state.projectId);
1121 case "needs": return screenNeeds();
1122 default: return screenTasks();
1123 }
1124}
1125function phoneBack() {
1126 switch (state.screen) {
1127 case "task": return ["Tasks", "tasks"];
1128 case "project": return ["Projects", "projects"];
1129 default: return ["Oficina", "index"];
1130 }
1131}
1132function phoneTitle() {
1133 switch (state.screen) {
1134 case "task": return byId(state.taskId).title;
1135 case "project": return PROJECTS[state.projectId].title;
1136 case "projects": return "Projects";
1137 case "needs": return "Needs you";
1138 default: return "Tasks";
1139 }
1140}
1141function render() {
1142 const desk = document.getElementById("desk"), phone = document.getElementById("phone"), index = document.getElementById("phone-index");
1143 const scrollMain = desk.querySelector(".main") ? desk.querySelector(".main").scrollTop : 0;
1144 const scrollPhone = phone.querySelector(".app") ? phone.querySelector(".app").scrollTop : 0;
1145 desk.innerHTML = `<div class="shell">${rail()}<div class="main">${screen()}</div></div>`;
1146 const [backLabel, backTo] = phoneBack();
1147 phone.innerHTML = `<div class="status"><span>21:18</span><span>5G</span></div><header><a class="back" href="#${backTo}" data-go="${backTo}">${icon("chevron-down")}${backLabel}</a><span class="ptitle">${esc(phoneTitle())}</span></header><div class="app" style="container: app / inline-size"><div class="main">${screen()}</div></div>`;
1148 index.innerHTML = `<div class="status"><span>21:18</span><span>5G</span></div><header><span class="ptitle">Oficina</span></header><div class="app" style="container: app / inline-size">${phoneIndex()}</div>`;
1149 desk.querySelector(".main").scrollTop = scrollMain;
1150 phone.querySelector(".app").scrollTop = scrollPhone;
1151 document.querySelectorAll('[data-control="screen"] button').forEach(b => b.setAttribute("aria-pressed", String(b.dataset.value === state.screen)));
1152 tickElapsed();
1153}
1154function go(where, id) {
1155 if (where === "index") { state.screen = "tasks"; }
1156 else if (["tasks", "projects", "needs", "task", "project", "conversation"].includes(where)) {
1157 if (where === "conversation") return;
1158 state.screen = where;
1159 if (where === "task" && id) state.taskId = id;
1160 if (where === "project" && id) state.projectId = id;
1161 }
1162 render();
1163}
1164document.addEventListener("click", e => {
1165 const a = e.target.closest("[data-go]");
1166 if (a) { e.preventDefault(); go(a.dataset.go, a.dataset.id); return; }
1167 const f = e.target.closest("[data-filter]");
1168 if (f) { state[f.dataset.filter] = f.dataset.value; render(); return; }
1169 const c = e.target.closest("[data-control] button");
1170 if (c) { setControl(c.closest("[data-control]").dataset.control, c.dataset.value); return; }
1171 if (e.target.closest("[data-replay]")) { resetSim(); if (document.documentElement.dataset.live === "on") startSim(); return; }
1172 if (e.target.closest(".btn, .link, .menu button")) { e.preventDefault(); const b = e.target.closest(".btn, .link, .menu button"); flash(b); return; }
1173 if (e.target.closest("a[href^='#']") && !e.target.closest("[data-go]")) e.preventDefault();
1174});
1175document.addEventListener("toggle", e => {
1176 const d = e.target;
1177 if (d.classList && d.classList.contains("spec")) state.openSpec[d.dataset.spec] = d.open;
1178}, true);
1179function flash(b) { b.style.transition = "opacity .15s"; b.style.opacity = ".5"; setTimeout(() => { b.style.opacity = ""; }, 200); }
1180
1181/* ── Controls ────────────────────────────────────────────────────── */
1182function setControl(name, value) {
1183 const root = document.documentElement;
1184 if (name === "screen") { go(value); }
1185 else if (name === "theme") root.dataset.theme = value;
1186 else if (name === "motion") root.dataset.motion = value;
1187 else if (name === "live") { root.dataset.live = value; if (value === "on") startSim(); else stopSim(); }
1188 document.querySelectorAll(`[data-control="${name}"] button`).forEach(b => b.setAttribute("aria-pressed", String(b.dataset.value === value)));
1189 const q = new URLSearchParams(location.search); q.set(name, value); history.replaceState(null, "", "?" + q);
1190}
1191
1192/* ── Clocks and flourishes ───────────────────────────────────────── */
1193function tickElapsed() {
1194 document.querySelectorAll("[data-since]").forEach(el => { el.textContent = dur(Date.now() - Number(el.dataset.since)); });
1195}
1196setInterval(tickElapsed, 1000);
1197setInterval(() => {
1198 if (document.documentElement.dataset.motion === "reduced") return;
1199 document.querySelectorAll('.mark:not([data-size="s"])').forEach(m => { m.removeAttribute("data-flourish"); void m.offsetWidth; m.setAttribute("data-flourish", ""); });
1200}, 3600);
1201
1202/* ── The simulation: one task runs through to Done ───────────────── */
1203let simTimer = null, simStep = 0, simStart = 0;
1204const SIM = [
1205 [3, () => { const s = running(byId("tk-c4f1")); s.activityAt = 5; s.fresh = true; }],
1206 [7, () => { const s = running(byId("tk-c4f1")); s.activityAt = 6; }],
1207 [8, () => { const t = byId("tk-a2d9"); t.stage = "merging"; t.mergingSince = Date.now(); t.changed = Date.now(); }],
1208 [12, () => { const t = byId("tk-c4f1"); const s = running(t); s.state = "done"; s.finished = Date.now(); s.pushed = true; s.sha = "a7c41e2"; t.sha = "a7c41e2"; s.summary = "Keep the scroll position across a live swap.\n\n- `live.js` now records the first visible row before the swap and restores it after\n- The list is swapped in place rather than replaced"; t.steps.push({ specialist: "checks", state: "running", started: Date.now(), activity: ["Running .amadan/ci"], activityAt: 0 }); t.stage = "in_review"; t.changed = Date.now(); }],
1209 [16, () => { const t = byId("tk-a2d9"); t.stage = "done"; t.merged = "c0ffee1"; t.mergedAt = Date.now(); t.changed = Date.now(); }],
1210 [20, () => { const t = byId("tk-c4f1"); const s = running(t); s.state = "done"; s.finished = Date.now(); s.checks = "passed"; s.gate = ".amadan/ci"; t.steps.push({ specialist: "review", state: "running", started: Date.now(), family: "GPT", activity: ["Reading the diff", "Comparing with main", "Writing the verdict"], activityAt: 0 }); t.changed = Date.now(); }],
1211 [25, () => { const s = running(byId("tk-c4f1")); s.activityAt = 1; s.fresh = true; }],
1212 [30, () => { const s = running(byId("tk-c4f1")); s.activityAt = 2; }],
1213 [34, () => { const t = byId("tk-c4f1"); const s = running(t); s.state = "done"; s.finished = Date.now(); s.verdict = "approve"; s.label = "another model family"; s.findings = []; t.stage = "ready_to_merge"; t.changed = Date.now(); }],
1214 [37, () => { const t = byId("tk-c4f1"); t.stage = "merging"; t.mergingSince = Date.now(); t.changed = Date.now(); }],
1215 [38, () => { const q = byId("tk-d5a2"); q.queued = false; q.question = null; q.needs = null; q.stage = "in_progress"; q.branch = "equipo/tk-d5a2-timeline-jumps"; q.base = "9c1f3e2"; q.steps.push({ specialist: "engineering", attempt: 1, state: "running", started: Date.now(), family: "Claude", activity: ["Reading ImageCell.swift", "Reading the timeline layout", "Editing ImageCell.swift"], activityAt: 0 }); q.changed = Date.now(); }],
1216 [43, () => { const t = byId("tk-c4f1"); t.stage = "done"; t.merged = "3d9e0f1"; t.mergedAt = Date.now(); t.changed = Date.now(); }],
1217 [46, () => { const s = running(byId("tk-d5a2")); s.activityAt = 1; s.fresh = true; }],
1218 [52, () => { const s = running(byId("tk-d5a2")); s.activityAt = 2; }]
1219];
1220const SNAPSHOT = JSON.stringify(TASKS);
1221function resetSim() {
1222 stopSim();
1223 const fresh = JSON.parse(SNAPSHOT);
1224 TASKS.length = 0; fresh.forEach(t => TASKS.push(t));
1225 const s = running(byId("tk-c4f1")); s.started = Date.now() - 4 * MIN - 12000;
1226 simStep = 0; render();
1227}
1228function startSim() {
1229 stopSim(); simStart = Date.now();
1230 simTimer = setInterval(() => {
1231 const t = (Date.now() - simStart) / 1000;
1232 let changed = false;
1233 while (simStep < SIM.length && SIM[simStep][0] <= t) { SIM[simStep][1](); simStep++; changed = true; }
1234 if (changed) render();
1235 if (simStep >= SIM.length) stopSim();
1236 }, 250);
1237}
1238function stopSim() { if (simTimer) clearInterval(simTimer); simTimer = null; }
1239
1240/* ── Fit the desktop frame to the viewport ───────────────────────── */
1241function fit() {
1242 const wrap = document.querySelector(".stage-wrap"), stage = document.getElementById("desk");
1243 const w = wrap.clientWidth, k = Math.min(1, w / 1280);
1244 stage.style.transform = `scale(${k})`; wrap.style.blockSize = (860 * k) + "px";
1245}
1246addEventListener("resize", fit);
1247
1248/* ── Start ───────────────────────────────────────────────────────── */
1249const q = new URLSearchParams(location.search);
1250["theme", "motion", "live"].forEach(k => { if (q.get(k)) document.documentElement.dataset[k] = q.get(k); });
1251if (q.get("screen")) state.screen = q.get("screen");
1252if (q.get("task")) state.taskId = q.get("task");
1253state.openSpec["railengineering"] = true;
1254state.openSpec["indexengineering"] = true;
1255["theme", "motion", "live", "screen"].forEach(k => { const v = k === "screen" ? state.screen : document.documentElement.dataset[k]; document.querySelectorAll(`[data-control="${k}"] button`).forEach(b => b.setAttribute("aria-pressed", String(b.dataset.value === v))); });
1256render(); fit();
1257if (document.documentElement.dataset.live === "on") startSim();
1258})();
1259</script>
1260</body>
1261</html>
1262