Spaces:
Running on Zero

File size: 26,657 Bytes
5a19b4e
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
cef8d49
 
5a19b4e
 
cef8d49
 
 
5a19b4e
cef8d49
 
 
 
 
 
5a19b4e
 
 
 
 
 
cef8d49
5a19b4e
 
 
 
 
 
 
1763916
 
cef8d49
 
1763916
 
 
 
 
 
 
cef8d49
1763916
5a19b4e
 
 
1763916
5a19b4e
1763916
 
 
5a19b4e
1763916
5a19b4e
1763916
5a19b4e
 
cef8d49
 
 
 
5a19b4e
 
 
 
 
 
 
 
 
 
 
 
cef8d49
 
5a19b4e
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1763916
 
 
5a19b4e
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
cef8d49
5a19b4e
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
cef8d49
 
 
 
 
5a19b4e
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
5c58a52
 
 
5a19b4e
 
 
 
 
 
 
 
 
 
 
 
 
cef8d49
 
 
5a19b4e
cef8d49
 
5a19b4e
cef8d49
 
5a19b4e
cef8d49
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
5a19b4e
 
 
 
cef8d49
 
5a19b4e
 
 
 
 
 
 
 
 
 
 
cc06acc
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
/* Tempora-27b Space. Ambient palette and type (ambient-website styles.css), drawn square: hairline frames, mono
   bracket labels, uppercase display headings. Light only. */
:root {
  --bg: #fdf6f1;
  --bg-2: #f8ece4;
  --panel: #ffffff;
  --panel-2: #fbf1ea;
  --ink: #1a110d;
  --ink-panel: #1c100b;
  --muted: #6b5850;
  --faint: #9a877e;
  --hair: rgba(58, 28, 12, 0.16);
  --hair-2: rgba(58, 28, 12, 0.08);
  --accent: #ff5a14;
  --accent-2: #ff7a2e;
  --accent-soft: #ffe5d8;
  --on-ink: #fbeee6;
  --font-display: "Inter Tight", "Inter", system-ui, sans-serif;
  --font-body: "Inter", system-ui, -apple-system, sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, monospace;
  --maxw: 1240px;
  color-scheme: light;
}
* { box-sizing: border-box; border-radius: 0 !important; }
html { scroll-behavior: smooth; }
body {
  margin: 0; background: var(--bg); color: var(--ink); font: 15px/1.55 var(--font-body);
  -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
/* page rules, nested under the page root so they outrank Gradio's base styles */
#tempora-root {
  a { color: inherit; }
  b { font-weight: 600; }
  .mono { font-family: var(--font-mono); font-size: 0.72rem; letter-spacing: 0.02em; }
  .dim { color: var(--faint); }
  .frame { max-width: var(--maxw); margin: 0 auto; padding: 0 28px; border-left: 1px solid var(--hair-2); border-right: 1px solid var(--hair-2); }

  /* labels, tags, buttons */
  .label { font-family: var(--font-mono); font-size: 0.7rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); }
  .tag { display: inline-flex; align-items: center; height: 22px; padding: 0 8px; font: 600 0.66rem/1 var(--font-mono); letter-spacing: 0.1em; text-transform: uppercase; }
  .tag-solid { background: var(--ink); color: var(--on-ink); }
  .tag-solid::before { content: ""; width: 7px; height: 7px; background: var(--accent); margin-right: 7px; }
  .tag-plain { border: 1px solid var(--hair); color: var(--muted); border-left: none; }
  .tag-line { border: 1px solid var(--hair); color: var(--muted); }
  .btn {
    display: inline-flex; align-items: center; gap: 6px; height: 40px; padding: 0 18px; border: 1px solid var(--ink);
    font: 600 0.72rem/1 var(--font-mono); letter-spacing: 0.1em; text-transform: uppercase; text-decoration: none;
    cursor: pointer; background: transparent; color: var(--ink); transition: background .15s, color .15s;
  }
  .btn-sm { height: 30px; padding: 0 12px; font-size: 0.66rem; }
  .btn-accent { background: var(--accent); border-color: var(--accent); color: #fff; }
  .btn-accent:hover { background: #e84c09; border-color: #e84c09; }
  .btn-accent:disabled { background: var(--faint); border-color: var(--faint); cursor: progress; }
  .btn-ink { background: var(--ink); color: var(--on-ink); }
  .btn-ink:hover { background: #33221a; }
  .btn-line:hover { background: var(--ink); color: var(--on-ink); }

  /* nav */
  .nav { position: sticky; top: 0; z-index: 20; background: rgba(253, 246, 241, 0.92); backdrop-filter: blur(8px); border-bottom: 1px solid var(--hair); }
  .nav-in { display: flex; align-items: center; gap: 28px; height: 56px; }
  .brand { display: flex; align-items: center; gap: 10px; text-decoration: none; }
  .brand-mark { display: grid; grid-template-columns: repeat(3, 6px); gap: 2px; }
  .brand-mark i { width: 6px; height: 6px; background: var(--ink); }
  .brand-mark i:nth-child(1), .brand-mark i:nth-child(5), .brand-mark i:nth-child(9) { background: var(--accent); }
  .brand-mark i:nth-child(3), .brand-mark i:nth-child(7) { opacity: .25; }
  .brand-name { font: 800 1rem/1 var(--font-display); letter-spacing: 0.02em; }
  .brand-name .dim { color: var(--accent); }
  .nav-links { display: flex; gap: 22px; }
  .nav-links a { font: 500 0.7rem/1 var(--font-mono); letter-spacing: 0.1em; text-transform: uppercase; text-decoration: none; color: var(--muted); }
  .nav-links a:hover { color: var(--ink); }
  .nav-right { margin-left: auto; display: flex; align-items: center; gap: 10px; }

  /* intro: one compact band, so the clip picker and player are on the first screen */
  .intro { position: relative; border-bottom: 1px solid var(--hair); overflow: hidden;
    background-image: linear-gradient(var(--hair-2) 1px, transparent 1px), linear-gradient(90deg, var(--hair-2) 1px, transparent 1px);
    background-size: 48px 48px; background-position: center top; }
  .intro-in { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) 340px; gap: 36px; align-items: end; padding-top: 30px; padding-bottom: 26px; }
  h1 { font: 800 clamp(1.7rem, 3.3vw, 2.7rem)/0.95 var(--font-display); letter-spacing: -0.03em; text-transform: uppercase; margin: 0 0 14px; max-width: 18ch; }
  .lede { max-width: 640px; margin: 0; color: var(--muted); font-size: 0.95rem; }
  .lede b { color: var(--ink); }
  .claim { margin: 0; padding: 14px 16px; background: var(--panel); border: 1px solid var(--hair); border-left: 3px solid var(--accent);
    font: 700 1rem/1.35 var(--font-display); letter-spacing: -0.005em; color: var(--ink); }
  .claim b { color: #c2410c; font-weight: 800; }
  .claim a { display: inline-block; margin-top: 6px; font: 600 0.66rem/1 var(--font-mono); letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); text-decoration: none; }
  .claim a:hover { color: var(--ink); }
  .pixels { position: absolute; top: 0; width: 300px; height: 200px; overflow: hidden; display: grid; grid-template-columns: repeat(25, 12px); grid-auto-rows: 12px; pointer-events: none; }
  .pixels-r { right: 0; direction: rtl; }
  .pixels i { width: 12px; height: 12px; }

  /* sections */
  .sec { border-bottom: 1px solid var(--hair); }
  .sec > .frame { padding-top: 64px; padding-bottom: 72px; }
  .demo > .frame { padding-top: 18px; padding-bottom: 40px; }
  .sec-head { display: grid; grid-template-columns: 1.1fr 1fr; gap: 40px; align-items: end; margin-bottom: 34px; }
  h2 { font: 800 clamp(2rem, 4.2vw, 3.3rem)/0.95 var(--font-display); letter-spacing: -0.03em; text-transform: uppercase; margin: 14px 0 0; }
  h3 { font: 700 1rem/1.25 var(--font-display); margin: 16px 0 6px; }
  .sec-note { margin: 0; color: var(--muted); font-size: 0.92rem; max-width: 470px; justify-self: end; }
  .panel { background: var(--panel); border: 1px solid var(--hair); }
  .panel-bar { display: flex; justify-content: space-between; align-items: center; gap: 10px; height: 38px; padding: 0 14px; border-bottom: 1px solid var(--hair-2); background: var(--panel-2); }

  /* clip picker: one compact row above the workbench */
  .picker { margin-bottom: 14px; }
  .gallery::-webkit-scrollbar { height: 6px; }
  .gallery::-webkit-scrollbar-thumb { background: var(--hair); }
  .picker .panel-bar { height: auto; min-height: 42px; flex-wrap: wrap; padding: 6px 14px; }
  .flow-n { display: inline-grid; place-items: center; width: 18px; height: 18px; margin-right: 8px; border-radius: 50%; background: var(--accent); color: #fff; font: 700 0.66rem/1 var(--font-mono); letter-spacing: 0; vertical-align: 1px; }
  .filters { display: flex; gap: 4px; flex-wrap: wrap; }
  .filter { height: 26px; padding: 0 10px; border: 1px solid var(--hair); background: var(--panel); color: var(--muted); font: 500 0.68rem/1 var(--font-mono); letter-spacing: 0.04em; cursor: pointer; }
  .filter:hover { color: var(--ink); border-color: var(--ink); }
  .filter.on { background: var(--ink); border-color: var(--ink); color: #fff; }
  .gallery { display: flex; gap: 10px; overflow-x: auto; padding: 12px 14px 14px; scroll-snap-type: x proximity; scrollbar-width: thin; }
  .card { position: relative; flex: 0 0 168px; scroll-snap-align: start; display: flex; flex-direction: column; background: var(--panel); border: 1px solid var(--hair); cursor: pointer; text-align: left; padding: 0; font: inherit; color: inherit; transition: border-color .15s; }
  .card[hidden] { display: none; }
  .card:hover { border-color: var(--ink); }
  .card.on { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
  .card img { display: block; width: 100%; aspect-ratio: 16 / 9; object-fit: cover; background: var(--bg-2); border-bottom: 1px solid var(--hair-2); }
  .card .tag { position: absolute; top: 6px; left: 6px; background: var(--panel); border: 1px solid var(--hair); height: 18px; font-size: 0.56rem; }
  .card.on .tag { background: var(--accent); color: #fff; border-color: var(--accent); }
  .card-title { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; padding: 8px 10px 3px; font: 600 0.76rem/1.3 var(--font-display); }
  .card-meta { display: block; padding: 0 10px 10px; font: 0.62rem/1 var(--font-mono); color: var(--faint); letter-spacing: 0.04em; }
  .upload { order: -1; justify-content: center; align-items: center; text-align: center; border-style: dashed; background: transparent; }
  .upload .card-title, .upload .card-meta { padding-left: 0; padding-right: 0; }
  .upload-plus { font: 300 2rem/1 var(--font-display); color: var(--accent); }
  .upload.drag { border-color: var(--accent); background: var(--accent-soft); }
  .tabs-step { display: inline-flex; align-items: center; padding: 0 14px 0 2px; margin-right: 6px; border-right: 1px solid var(--hair-2); }

  /* workbench */
  .bench { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, 1fr); grid-template-areas: "player form" "results results"; gap: 14px; }
  .player-panel { grid-area: player; }
  .prompt-panel { grid-area: form; }
  .results { grid-area: results; }
  .video-wrap { background: var(--ink-panel); aspect-ratio: 16 / 9; display: flex; }
  video { width: 100%; height: 100%; object-fit: contain; display: block; }
  .timeline { position: relative; margin: 14px 14px 0; }
  .track { position: relative; height: 44px; background: var(--panel-2); border: 1px solid var(--hair); cursor: pointer; overflow: hidden; }
  .seg { position: absolute; top: 0; bottom: 0; border-right: 1px solid var(--panel); background: #ead3c5; color: var(--ink);
    font: 500 0.6rem/1.2 var(--font-mono); padding: 5px 5px 0; overflow: hidden; white-space: nowrap; text-overflow: ellipsis; transition: background .12s; }
  .seg:nth-child(even) { background: #f2e1d6; }
  .seg:hover { background: #dcbca9; }
  .seg.on { background: var(--accent) !important; color: #fff !important; }
  .seg.dark { color: var(--on-ink); }
  .ruler { position: relative; height: 22px; }
  .ruler span { position: absolute; top: 0; font: 0.6rem/1 var(--font-mono); color: var(--faint); transform: translateX(-50%); padding-top: 7px; }
  .ruler span:first-child { transform: none; }
  .ruler span:first-child::before { left: 0; }
  .ruler span::before { content: ""; position: absolute; top: 0; left: 50%; width: 1px; height: 5px; background: var(--hair); }
  .playhead { position: absolute; top: -4px; height: 52px; width: 2px; background: var(--ink); pointer-events: none; left: 0; }
  .playhead::before { content: ""; position: absolute; top: 0; left: -3px; width: 8px; height: 8px; background: var(--ink); }
  .legend { display: flex; flex-wrap: wrap; gap: 6px 14px; padding: 0 14px; min-height: 4px; }
  .legend span { display: inline-flex; align-items: center; gap: 6px; font: 0.64rem/1.6 var(--font-mono); color: var(--muted); }
  .legend i { width: 9px; height: 9px; display: inline-block; }
  .now { margin: 12px 14px 0; border: 1px solid var(--hair); border-left: 3px solid var(--accent); padding: 12px 14px; min-height: 92px; background: var(--panel); }
  .now-head { display: flex; justify-content: space-between; color: var(--faint); text-transform: uppercase; letter-spacing: 0.08em; }
  .now-label { font: 700 1.12rem/1.3 var(--font-display); margin: 6px 0 2px; }
  .now-meta { display: grid; grid-template-columns: max-content 1fr; gap: 3px 14px; margin: 8px 0 0; }
  .now-meta dt { font: 0.64rem/1.6 var(--font-mono); color: var(--faint); text-transform: uppercase; letter-spacing: 0.06em; }
  .now-meta dd { margin: 0; font-size: 0.84rem; }
  .credit { margin: 10px 14px 14px; color: var(--faint); font-size: 0.64rem; }

  /* prompt form */
  .prompt-panel { display: flex; flex-direction: column; }
  .field { padding: 14px 14px 0; }
  .field > label:not(.switch), .switch > span:last-child { display: block; font: 600 0.72rem/1.3 var(--font-mono); letter-spacing: 0.06em; text-transform: uppercase; margin-bottom: 7px; }
  .field em, .switch em { font-style: normal; font-weight: 400; color: var(--faint); text-transform: none; letter-spacing: 0; margin-left: 4px; }
  textarea, input[type=text] { width: 100%; border: 1px solid var(--hair); background: #fff; padding: 9px 10px; font: 0.88rem/1.45 var(--font-body); color: var(--ink); resize: vertical; }
  textarea:focus, input[type=text]:focus { outline: none; border-color: var(--ink); background: #fff; }
  textarea::placeholder, input[type=text]::placeholder { color: var(--faint); opacity: 1; }
  .fields { display: flex; flex-direction: column; gap: 6px; margin-bottom: 8px; }
  .frow { display: grid; grid-template-columns: 0.8fr 1.2fr 30px; gap: 6px; }
  .frow input { font-size: 0.8rem; padding: 7px 8px; }
  .frow input:first-child { font-family: var(--font-mono); }
  .frow button { border: 1px solid var(--hair); background: transparent; cursor: pointer; color: var(--muted); font-size: 0.9rem; }
  .frow button:hover { border-color: var(--ink); color: var(--ink); }
  .switch, .field > label.switch { display: flex; align-items: center; gap: 10px; cursor: pointer; margin: 0; }
  .switch > span:last-child { margin: 0; }
  .switch input { position: absolute; opacity: 0; }
  .switch-box { position: relative; width: 36px; height: 20px; border: 1px solid var(--ink); background: var(--bg); flex: none; }
  .switch-box::after { content: ""; position: absolute; top: 3px; left: 3px; width: 12px; height: 12px; background: var(--ink); transition: left .15s; }
  .switch input:checked + .switch-box { background: var(--accent); border-color: var(--accent); }
  .switch input:checked + .switch-box::after { left: 19px; background: #fff; }
  .switch input:focus-visible + .switch-box { outline: 2px solid var(--ink); outline-offset: 2px; }
  .preview { margin: 14px 14px 0; border: 1px solid var(--hair-2); background: var(--panel-2); }
  .preview summary { cursor: pointer; padding: 8px 10px; list-style: none; }
  .preview summary::before { content: "▸ "; }
  .preview[open] summary::before { content: "▾ "; }
  .preview pre { margin: 0; padding: 0 10px 10px; font: 0.68rem/1.55 var(--font-mono); white-space: pre-wrap; word-break: break-word; color: var(--ink); }
  .run-help { margin: 14px 14px 0; color: var(--muted); font-size: 0.78rem; line-height: 1.45; }
  .run-row { display: flex; align-items: center; gap: 12px; padding: 14px; margin-top: auto; flex-wrap: wrap; }
  .run-note { font-size: 0.66rem; max-width: 260px; }
  .log { margin: 0 14px 14px; padding: 10px 12px; list-style: none; background: var(--ink-panel); color: var(--on-ink); font-size: 0.68rem; line-height: 1.7; }
  .log li { display: flex; gap: 10px; }
  .log li time { color: var(--accent-2); min-width: 46px; }
  .log li.err { color: #ffb199; }
  .log li.live::after { content: "▮"; color: var(--accent); animation: blink 1s steps(2) infinite; }
  @keyframes blink { 50% { opacity: 0; } }

  /* results */
  .tabs { display: flex; align-items: stretch; border-bottom: 1px solid var(--hair); background: var(--panel-2); }
  .tab { border: none; border-right: 1px solid var(--hair-2); background: transparent; padding: 0 16px; height: 40px; cursor: pointer;
    font: 600 0.68rem/1 var(--font-mono); letter-spacing: 0.1em; text-transform: uppercase; color: var(--muted); }
  .tab.on { background: var(--panel); color: var(--ink); box-shadow: inset 0 -2px 0 var(--accent); }
  .count { color: var(--accent); margin-left: 4px; }
  .tabs-right { margin-left: auto; align-self: center; padding: 0 14px; font-size: 0.64rem; text-align: right; }
  .tab-body pre { margin: 0; padding: 16px; max-height: 480px; overflow: auto; font: 0.72rem/1.6 var(--font-mono); white-space: pre-wrap; word-break: break-word; }
  .table-wrap { position: relative; overflow-x: auto; max-height: 520px; overflow-y: auto; }
  .tab-edit { display: none; }
  .ask { display: none; }
  .more > summary { display: none; }
  .more > summary::-webkit-details-marker { display: none; }
  table { width: 100%; border-collapse: collapse; font-size: 0.84rem; font-variant-numeric: tabular-nums; }
  th { position: sticky; top: 0; background: var(--panel); text-align: left; font: 500 0.64rem/1 var(--font-mono); letter-spacing: 0.08em; text-transform: uppercase; color: var(--faint); padding: 11px 12px; border-bottom: 1px solid var(--hair); white-space: nowrap; }
  td { padding: 9px 12px; border-bottom: 1px solid var(--hair-2); vertical-align: top; }
  td.t { font-family: var(--font-mono); font-size: 0.72rem; color: var(--muted); white-space: nowrap; }
  #table tbody tr { cursor: pointer; }
  #table tbody tr:hover { background: var(--panel-2); }
  #table tbody tr.on { background: var(--accent-soft); }
  #table tbody tr.on td:first-child { box-shadow: inset 3px 0 0 var(--accent); }
  .empty { padding: 26px 16px; color: var(--faint); font: 0.74rem var(--font-mono); }

  /* how */
  .steps { display: grid; grid-template-columns: repeat(3, 1fr); border: 1px solid var(--hair); background: var(--panel); }
  .step { padding: 22px; }
  .step + .step { border-left: 1px solid var(--hair); }
  .step-n { color: var(--accent); text-transform: uppercase; letter-spacing: 0.1em; }
  .step p { margin: 0; color: var(--muted); font-size: 0.88rem; }
  .code { margin: 14px 0 0; padding: 12px; background: var(--ink-panel); color: var(--on-ink); font: 0.68rem/1.6 var(--font-mono); white-space: pre-wrap; min-height: 118px; }
  .frames { margin-top: 14px; display: grid; grid-template-columns: repeat(8, 1fr); gap: 4px; min-height: 118px; align-content: center; padding: 12px; background: var(--ink-panel); }
  .frames i { aspect-ratio: 3 / 4; background: linear-gradient(160deg, #6b4a3a, #2a170e); position: relative; }
  .frames i:nth-child(3n) { background: linear-gradient(160deg, var(--accent), #8a2d05); }
  .frames i::after { content: attr(data-t); position: absolute; left: 2px; bottom: 2px; font: 0.5rem/1 var(--font-mono); color: var(--on-ink); }

  /* benchmark */
  #bench .table-wrap { max-height: none; }
  .bench-table td:first-child { min-width: 170px; }
  .bench-table tr.grp td { background: var(--bg-2); font: 600 0.62rem/1 var(--font-mono); letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); padding-top: 10px; padding-bottom: 10px; }
  .bench-table td.num { font-family: var(--font-mono); font-size: 0.78rem; white-space: nowrap; }
  .bench-table tr.ours td { background: var(--accent-soft); font-weight: 600; }
  .bench-table tr.ours td:first-child { box-shadow: inset 3px 0 0 var(--accent); }
  .bar { display: flex; align-items: center; gap: 8px; min-width: 150px; }
  .bar i { display: block; height: 8px; background: var(--ink); }
  .bar.e2e i { background: var(--accent); }
  .footnote { color: var(--faint); margin: 12px 0 0; font-size: 0.64rem; line-height: 1.6; }

  /* footer */
  .foot-in { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding-top: 26px; padding-bottom: 40px; flex-wrap: wrap; }

  /* responsive */
  @media (max-width: 1080px) {
    .bench { grid-template-columns: minmax(0, 1fr); grid-template-areas: "player" "results" "form"; }
    .intro-in { grid-template-columns: minmax(0, 1fr); gap: 14px; }
    .claim { max-width: 640px; }
  }
  /* phones: one compact screen. Clip strip, video + timeline, then tabs (Chunks / JSON / Reasoning / Edit & run);
     only one panel is open at a time, so nothing long stacks up. */
  @media (max-width: 760px) {
    .frame { padding: 0 8px; border-left: none; border-right: none; }
    .nav-in { gap: 12px; height: 48px; }
    .nav-links, .nav-right .tag { display: none; }
    .pixels { display: none; }
    .intro-in { padding-top: 14px; padding-bottom: 12px; gap: 10px; }
    h1 { font-size: 1.45rem; margin-bottom: 0; max-width: none; }
    .lede { display: none; }
    .claim { padding: 8px 10px; font-size: 0.8rem; line-height: 1.3; }
    .claim a { display: none; }
    .demo > .frame { padding-top: 8px; padding-bottom: 24px; }
    .sec:not(.demo) > .frame { padding-top: 40px; padding-bottom: 44px; }
    .panel-bar .label { white-space: nowrap; flex: none; }

    /* clip strip: smaller cards, no filter row (each card carries its tag) */
    .picker { margin-bottom: 8px; }
    .picker .panel-bar { min-height: 0; height: 32px; padding: 0 10px; }
    .filters { display: none; }
    .gallery { padding: 8px; gap: 6px; }
    .card { flex-basis: 122px; }
    .card .tag { height: 16px; font-size: 0.5rem; padding: 0 5px; top: 4px; left: 4px; }
    .card-title { padding: 5px 7px 2px; font-size: 0.7rem; }
    .card-meta { padding: 0 7px 7px; font-size: 0.56rem; }
    .upload-tip { display: none; }
    .upload-plus { font-size: 1.5rem; }

    /* player: no header bar or "now" box; the highlighted row in the list does that job */
    .bench { gap: 8px; }
    .player-panel > .panel-bar, .now { display: none; }
    .timeline { margin: 8px 8px 0; }
    .track { height: 36px; }
    .playhead { height: 44px; }
    .legend { padding: 0 8px; }
    .credit { margin: 6px 8px 8px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; cursor: pointer; }
    .credit.open { display: block; }

    /* tabs: output views plus "Edit & run" */
    .tabs { overflow-x: auto; scrollbar-width: none; position: sticky; top: 48px; z-index: 5; }
    .tabs::-webkit-scrollbar { display: none; }
    .tabs-step, .tabs-right { display: none; }
    .tab { flex: none; padding: 0 11px; height: 40px; font-size: 0.62rem; }
    .tab-edit { display: block; margin-left: auto; border-right: none; border-left: 1px solid var(--hair-2); background: var(--accent); color: #fff; }
    .tab-edit.on { background: var(--ink); color: #fff; box-shadow: none; }
    &[data-mtab=edit] .results .tab-body { display: none; }
    &:not([data-mtab=edit]) #form { display: none; }
    #form { margin-top: -9px; border-top: none; }
    #form > .panel-bar { display: none; }
    .ask { display: block; padding: 10px 12px; border-bottom: 1px solid var(--hair); border-left: 3px solid var(--accent); background: var(--panel); }
    .ask-head { display: flex; justify-content: space-between; align-items: center; }
    .ask-edit { border: 1px solid var(--hair); background: transparent; color: var(--ink); height: 26px; padding: 0 10px; font: 600 0.62rem/1 var(--font-mono); letter-spacing: 0.08em; text-transform: uppercase; cursor: pointer; }
    .ask-text { margin: 5px 0 0; font: 600 0.95rem/1.35 var(--font-display); color: var(--ink); }
    .ask-meta { margin: 4px 0 0; color: var(--muted); font-size: 0.64rem; line-height: 1.5; }
    .ask-meta:empty { display: none; }
    &[data-mtab=edit] .ask { display: none; }
    .tab-body pre { max-height: 55vh; padding: 12px; }

    /* chunk list: one line per chunk (start time + label); fields only under the current chunk */
    .table-wrap { max-height: 46vh; }
    #table thead { display: none; }
    #table tbody tr[data-i] { display: grid; grid-template-columns: 60px minmax(0, 1fr); column-gap: 8px; padding: 8px 10px; border-bottom: 1px solid var(--hair-2); }
    #table tbody tr[data-i] td { padding: 0; border: none; }
    #table tbody tr[data-i] td:nth-child(1), #table tbody tr[data-i] td:nth-child(3) { display: none; }
    #table td.lab { font-weight: 600; font-size: 0.86rem; line-height: 1.3; }
    #table td.m { grid-column: 1 / -1; margin-top: 3px; font-size: 0.78rem; color: var(--muted); }
    #table tbody tr[data-i]:not(.on) td.m { display: none; }
    #table td.m::before { content: attr(data-k) "  "; font: 0.58rem/1 var(--font-mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--faint); }
    #table tbody tr.on td:first-child { box-shadow: none; }
    #table tbody tr.on { box-shadow: inset 3px 0 0 var(--accent); }

    /* form (inside "Edit & run"): instruction + Run up front, the rest folded */
    .field { padding: 10px 10px 0; }
    textarea, input[type=text] { font-size: 16px; }   /* stops iOS zooming into the field */
    .more, .preview { margin: 10px 10px 0; border: 1px solid var(--hair-2); background: var(--panel-2); }
    .more > summary { display: block; cursor: pointer; padding: 9px 10px; list-style: none; }
    .more > summary::before { content: "▸ "; }
    .more[open] > summary::before { content: "▾ "; }
    .more .field { padding: 0 10px 10px; background: var(--panel); }
    .more .field:first-of-type { padding-top: 10px; }
    .frow { grid-template-columns: minmax(0, 1fr) 36px; grid-template-areas: "n x" "d d"; padding-bottom: 6px; border-bottom: 1px dashed var(--hair-2); }
    .frow input:first-child { grid-area: n; }
    .frow input:nth-child(2) { grid-area: d; }
    .frow button { grid-area: x; }
    .run-help { margin: 10px 10px 0; font-size: 0.74rem; }
    .run-row { padding: 10px; }
    #run { width: 100%; justify-content: center; height: 46px; }
    #form .run-row { order: 1; margin-top: 0; } #form .log { order: 2; } #form .more { order: 3; } #form .preview { order: 4; } #form .run-help { order: 5; margin-bottom: 12px; }   /* Run right under the instruction */
    .run-note { max-width: none; }
    .log { margin: 0 10px 10px; }

    .sec-head { grid-template-columns: 1fr; gap: 16px; }
    .sec-note { justify-self: start; }
    .steps { grid-template-columns: 1fr; }
    .step + .step { border-left: none; border-top: 1px solid var(--hair); }
    .bench-table td:first-child { min-width: 130px; }
    .foot-in { padding-left: 10px; padding-right: 10px; }
  }
}

/* hosted inside Gradio: drop its chrome and paddings, keep our page edge to edge */
html, body, gradio-app, .gradio-container, .main, .wrap, .contain, .app { background: var(--bg) !important; }
.gradio-container { max-width: none !important; width: 100% !important; padding: 0 !important; margin: 0 !important; }
.gradio-container > .main, .gradio-container .contain, .gradio-container .column, #tempora-host { padding: 0 !important; gap: 0 !important; }
footer:not(.foot) { display: none !important; }
#tempora-root { font: 15px/1.55 var(--font-body); color: var(--ink); text-align: left; }
#tempora-root h1, #tempora-root h2, #tempora-root h3, #tempora-root p, #tempora-root pre { color: inherit; }
#tempora-root img { max-width: 100%; }

.upload-tip { font-size: 0.72rem; line-height: 1.3; margin-top: 4px; padding: 0 10px; }