Threadbourne commited on
Commit
1195a7f
Β·
verified Β·
1 Parent(s): b74727b

Upload custom.css

Browse files
Files changed (1) hide show
  1. src/custom.css +381 -0
src/custom.css ADDED
@@ -0,0 +1,381 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ /* uglytool.dev β€” Clean Room theme (v1)
2
+ * See README.md for drop-in instructions for Gradio + Streamlit.
3
+ * You bought this file. Modify whatever you want β€” tweak the blue,
4
+ * swap the font, remove the credit. It's yours now.
5
+ */
6
+
7
+ @import url('https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700&family=JetBrains+Mono:wght@400;500&display=swap');
8
+
9
+ /* ============================================================
10
+ * Part 1 β€” Theme variables
11
+ * ============================================================ */
12
+
13
+ :root,
14
+ :root.dark,
15
+ .gradio-container,
16
+ .gradio-container.dark,
17
+ body.dark {
18
+ --cr-bg: #ffffff;
19
+ --cr-surface: #f7f8fa;
20
+ --cr-surface-2: #eceef1;
21
+ --cr-border: rgba(17, 24, 39, 0.1);
22
+ --cr-border-soft: rgba(17, 24, 39, 0.05);
23
+ --cr-border-focus: #2563a8;
24
+ --cr-blue: #2563a8;
25
+ --cr-blue-soft: rgba(37, 99, 168, 0.08);
26
+ --cr-blue-dim: rgba(37, 99, 168, 0.25);
27
+ --cr-ink: #111827;
28
+ --cr-muted: #6b7280;
29
+ --cr-dim: #9ca3af;
30
+
31
+ --body-background-fill: var(--cr-bg);
32
+ --background-fill-primary: var(--cr-surface);
33
+ --background-fill-secondary: var(--cr-surface-2);
34
+ --body-text-color: var(--cr-ink);
35
+ --body-text-color-subdued: var(--cr-muted);
36
+ --color-accent: var(--cr-blue);
37
+ --color-accent-soft: var(--cr-blue-soft);
38
+ --border-color-primary: var(--cr-border);
39
+ --border-color-accent: var(--cr-blue);
40
+
41
+ --block-background-fill: var(--cr-surface);
42
+ --block-border-color: var(--cr-border);
43
+ --block-border-width: 1px;
44
+ --block-radius: 3px;
45
+ --block-shadow: none;
46
+
47
+ --block-title-background-fill: transparent;
48
+ --block-title-border-color: transparent;
49
+ --block-title-text-color: var(--cr-ink);
50
+ --block-title-text-size: 0.78rem;
51
+ --block-title-text-weight: 600;
52
+ --block-label-background-fill: transparent;
53
+ --block-label-border-color: transparent;
54
+ --block-label-text-color: var(--cr-ink);
55
+ --block-label-text-size: 0.75rem;
56
+ --block-label-text-weight: 600;
57
+
58
+ --input-background-fill: var(--cr-bg);
59
+ --input-background-fill-focus: var(--cr-bg);
60
+ --input-border-color: var(--cr-border);
61
+ --input-border-color-focus: var(--cr-blue);
62
+ --input-text-size: 0.92rem;
63
+ --input-radius: 3px;
64
+
65
+ --button-primary-background-fill: var(--cr-blue);
66
+ --button-primary-background-fill-hover: #1f5596;
67
+ --button-primary-text-color: var(--cr-bg);
68
+ --button-primary-text-color-hover: var(--cr-bg);
69
+ --button-primary-border-color: var(--cr-blue);
70
+ --button-secondary-background-fill: var(--cr-bg);
71
+ --button-secondary-background-fill-hover: var(--cr-blue-soft);
72
+ --button-secondary-text-color: var(--cr-blue);
73
+ --button-secondary-text-color-hover: var(--cr-blue);
74
+ --button-secondary-border-color: var(--cr-border);
75
+ --button-large-text-size: 0.82rem;
76
+ --button-large-text-weight: 600;
77
+ --button-large-radius: 3px;
78
+
79
+ --slider-color: var(--cr-blue);
80
+
81
+ --font: 'Plus Jakarta Sans', ui-sans-serif, system-ui, sans-serif;
82
+ --font-mono: 'JetBrains Mono', ui-monospace, monospace;
83
+
84
+ --radius-xxs: 1px;
85
+ --radius-xs: 2px;
86
+ --radius-sm: 3px;
87
+ --radius-md: 4px;
88
+ --radius-lg: 6px;
89
+ }
90
+
91
+ /* ============================================================
92
+ * Part 2 β€” Root containers
93
+ * ============================================================ */
94
+
95
+ html body,
96
+ html body.dark,
97
+ html body .gradio-container,
98
+ html body .gradio-container.dark,
99
+ html body .stApp,
100
+ html body .stApp > div,
101
+ html body [data-testid="stAppViewContainer"] {
102
+ background: var(--cr-bg) !important;
103
+ color: var(--cr-ink) !important;
104
+ font-family: 'Plus Jakarta Sans', ui-sans-serif, system-ui, sans-serif !important;
105
+ -webkit-font-smoothing: antialiased !important;
106
+ }
107
+
108
+ html body .main .block-container,
109
+ html body .stApp [data-testid="stVerticalBlock"] {
110
+ background: var(--cr-bg) !important;
111
+ }
112
+
113
+ /* ============================================================
114
+ * Part 3 β€” Typography
115
+ * Headings: Plus Jakarta bold, ink color.
116
+ * Labels: all-caps Plus Jakarta at 0.75rem, ink color, 0.1em tracking.
117
+ * Blue is reserved for indices, focus states, buttons.
118
+ * ============================================================ */
119
+
120
+ html body h1, html body h2, html body h3, html body h4, html body h5, html body h6,
121
+ html body .gradio-container h1, html body .gradio-container h2, html body .gradio-container h3,
122
+ html body .gradio-container h4, html body .gradio-container h5, html body .gradio-container h6,
123
+ html body .gradio-container h1 *, html body .gradio-container h2 *, html body .gradio-container h3 *,
124
+ html body .prose h1, html body .prose h2, html body .prose h3, html body .prose h4,
125
+ html body .prose h1 *, html body .prose h2 *, html body .prose h3 *,
126
+ html body .markdown h1, html body .markdown h2, html body .markdown h3,
127
+ html body .markdown h1 *, html body .markdown h2 *, html body .markdown h3 *,
128
+ html body .gr-markdown h1, html body .gr-markdown h2, html body .gr-markdown h3,
129
+ html body .gr-markdown h1 *, html body .gr-markdown h2 *, html body .gr-markdown h3 *,
130
+ html body .stApp h1, html body .stApp h2, html body .stApp h3,
131
+ html body [data-testid="stMarkdownContainer"] h1,
132
+ html body [data-testid="stMarkdownContainer"] h2,
133
+ html body [data-testid="stMarkdownContainer"] h3,
134
+ html body [data-testid="stMarkdownContainer"] h1 *,
135
+ html body [data-testid="stMarkdownContainer"] h2 *,
136
+ html body [data-testid="stMarkdownContainer"] h3 * {
137
+ font-family: 'Plus Jakarta Sans', ui-sans-serif, sans-serif !important;
138
+ font-weight: 700 !important;
139
+ letter-spacing: -0.02em !important;
140
+ color: var(--cr-ink) !important;
141
+ -webkit-text-fill-color: var(--cr-ink) !important;
142
+ background-image: none !important;
143
+ background-clip: unset !important;
144
+ -webkit-background-clip: unset !important;
145
+ line-height: 1.15 !important;
146
+ }
147
+
148
+ /* Labels β€” all-caps Plus Jakarta, ink, narrow tracking. */
149
+ html body .gradio-container .block-label,
150
+ html body .gradio-container .block-label *,
151
+ html body .gradio-container label,
152
+ html body .gradio-container label > *,
153
+ html body .gradio-container [class*="label-wrap"],
154
+ html body .gradio-container [class*="label-wrap"] *,
155
+ html body .gradio-container [data-testid*="label"],
156
+ html body .gradio-container .wrap > label,
157
+ html body .stApp label,
158
+ html body .stApp [data-testid="stWidgetLabel"],
159
+ html body .stApp [data-testid="stWidgetLabel"] > *,
160
+ html body .stApp [data-testid="stWidgetLabel"] p {
161
+ font-family: 'Plus Jakarta Sans', ui-sans-serif, sans-serif !important;
162
+ font-size: 0.75rem !important;
163
+ color: var(--cr-ink) !important;
164
+ letter-spacing: 0.1em !important;
165
+ text-transform: uppercase !important;
166
+ font-weight: 600 !important;
167
+ background: transparent !important;
168
+ }
169
+
170
+ /* ============================================================
171
+ * Part 4 β€” Blocks / cards
172
+ * ============================================================ */
173
+
174
+ html body .gradio-container .block,
175
+ html body .gradio-container .gr-block,
176
+ html body .gradio-container .gr-padded,
177
+ html body .gradio-container .gr-form,
178
+ html body .gradio-container .gr-box,
179
+ html body .gradio-container .wrap,
180
+ html body .stApp [data-testid="stForm"],
181
+ html body .stApp [data-testid="stExpander"] {
182
+ background: var(--cr-surface) !important;
183
+ border: 1px solid var(--cr-border) !important;
184
+ border-radius: 3px !important;
185
+ }
186
+
187
+ /* ============================================================
188
+ * Part 5 β€” Inputs
189
+ * ============================================================ */
190
+
191
+ html body .gradio-container input[type="text"],
192
+ html body .gradio-container input[type="number"],
193
+ html body .gradio-container input[type="email"],
194
+ html body .gradio-container input[type="password"],
195
+ html body .gradio-container input[type="search"],
196
+ html body .gradio-container textarea,
197
+ html body .gradio-container select,
198
+ html body .gradio-container .gr-textbox,
199
+ html body .gradio-container .gr-textbox textarea,
200
+ html body .gradio-container .gr-textbox input,
201
+ html body .stApp input[type="text"],
202
+ html body .stApp input[type="number"],
203
+ html body .stApp textarea,
204
+ html body .stApp [data-baseweb="select"] > div,
205
+ html body .stApp [data-baseweb="input"] {
206
+ background: var(--cr-bg) !important;
207
+ border: 1px solid var(--cr-border) !important;
208
+ border-radius: 3px !important;
209
+ color: var(--cr-ink) !important;
210
+ font-family: 'Plus Jakarta Sans', ui-sans-serif, sans-serif !important;
211
+ font-size: 0.92rem !important;
212
+ caret-color: var(--cr-blue) !important;
213
+ padding: 10px 12px !important;
214
+ line-height: 1.5 !important;
215
+ }
216
+
217
+ html body .gradio-container textarea,
218
+ html body .stApp textarea {
219
+ min-height: 130px !important;
220
+ background: var(--cr-surface) !important;
221
+ }
222
+
223
+ html body .gradio-container input:focus,
224
+ html body .gradio-container textarea:focus,
225
+ html body .gradio-container select:focus,
226
+ html body .stApp input:focus,
227
+ html body .stApp textarea:focus {
228
+ border-color: var(--cr-blue) !important;
229
+ outline: none !important;
230
+ box-shadow: 0 0 0 3px var(--cr-blue-soft) !important;
231
+ }
232
+
233
+ html body .gradio-container ::placeholder,
234
+ html body .stApp ::placeholder {
235
+ color: var(--cr-dim) !important;
236
+ }
237
+
238
+ /* ============================================================
239
+ * Part 6 β€” Buttons (blue, uppercase Plus Jakarta, small radius)
240
+ * ============================================================ */
241
+
242
+ html body .gradio-container button,
243
+ html body .gradio-container .gr-button,
244
+ html body .gradio-container [class*="gr-button"],
245
+ html body .gradio-container button.primary,
246
+ html body .gradio-container .primary,
247
+ html body .stApp .stButton > button,
248
+ html body .stApp button[kind="primary"] {
249
+ background: var(--cr-blue) !important;
250
+ color: var(--cr-bg) !important;
251
+ font-family: 'Plus Jakarta Sans', ui-sans-serif, sans-serif !important;
252
+ font-weight: 600 !important;
253
+ font-size: 0.82rem !important;
254
+ letter-spacing: 0.12em !important;
255
+ text-transform: uppercase !important;
256
+ border: 1px solid var(--cr-blue) !important;
257
+ border-radius: 3px !important;
258
+ padding: 12px 20px !important;
259
+ cursor: pointer !important;
260
+ transition: background 150ms, transform 100ms !important;
261
+ }
262
+
263
+ html body .gradio-container button:hover,
264
+ html body .gradio-container .gr-button:hover,
265
+ html body .stApp .stButton > button:hover {
266
+ background: #1f5596 !important;
267
+ border-color: #1f5596 !important;
268
+ color: var(--cr-bg) !important;
269
+ }
270
+
271
+ html body .gradio-container button:active,
272
+ html body .stApp .stButton > button:active {
273
+ transform: scale(0.996) !important;
274
+ }
275
+
276
+ html body .gradio-container button.secondary,
277
+ html body .gradio-container .secondary,
278
+ html body .stApp button[kind="secondary"] {
279
+ background: var(--cr-bg) !important;
280
+ color: var(--cr-blue) !important;
281
+ border: 1px solid var(--cr-border) !important;
282
+ }
283
+
284
+ /* ============================================================
285
+ * Part 7 β€” Sliders, checkboxes, radios
286
+ * ============================================================ */
287
+
288
+ html body input[type="range"] { accent-color: var(--cr-blue) !important; }
289
+ html body input[type="range"]::-webkit-slider-thumb {
290
+ background: var(--cr-blue) !important;
291
+ border: 2px solid var(--cr-bg) !important;
292
+ box-shadow: 0 0 0 1px var(--cr-blue-dim) !important;
293
+ }
294
+ html body input[type="range"]::-moz-range-thumb {
295
+ background: var(--cr-blue) !important;
296
+ border: 2px solid var(--cr-bg) !important;
297
+ }
298
+ html body input[type="checkbox"],
299
+ html body input[type="radio"] {
300
+ accent-color: var(--cr-blue) !important;
301
+ }
302
+
303
+ /* ============================================================
304
+ * Part 8 β€” File uploads
305
+ * ============================================================ */
306
+
307
+ html body .gradio-container .gr-file-upload,
308
+ html body .gradio-container input[type="file"],
309
+ html body .stApp [data-testid="stFileUploader"],
310
+ html body .stApp [data-testid="stFileUploaderDropzone"] {
311
+ background: var(--cr-surface) !important;
312
+ border: 1px dashed var(--cr-border) !important;
313
+ border-radius: 3px !important;
314
+ color: var(--cr-ink) !important;
315
+ }
316
+
317
+ html body input[type="file"]::file-selector-button {
318
+ background: var(--cr-bg) !important;
319
+ color: var(--cr-blue) !important;
320
+ border: 1px solid var(--cr-border) !important;
321
+ border-radius: 3px !important;
322
+ padding: 5px 12px !important;
323
+ margin-right: 12px !important;
324
+ font-family: 'Plus Jakarta Sans', ui-sans-serif, sans-serif !important;
325
+ font-weight: 500 !important;
326
+ font-size: 0.78rem !important;
327
+ text-transform: uppercase !important;
328
+ letter-spacing: 0.08em !important;
329
+ cursor: pointer !important;
330
+ }
331
+
332
+ /* ============================================================
333
+ * Part 9 β€” Markdown, code, links
334
+ * ============================================================ */
335
+
336
+ html body .gradio-container .markdown,
337
+ html body .gradio-container .gr-markdown,
338
+ html body .gradio-container .prose,
339
+ html body .stApp [data-testid="stMarkdownContainer"] {
340
+ color: var(--cr-ink) !important;
341
+ font-family: 'Plus Jakarta Sans', ui-sans-serif, sans-serif !important;
342
+ line-height: 1.55 !important;
343
+ }
344
+
345
+ html body .gradio-container a,
346
+ html body .stApp a {
347
+ color: var(--cr-blue) !important;
348
+ }
349
+
350
+ html body code,
351
+ html body .gradio-container code,
352
+ html body .stApp code {
353
+ background: var(--cr-blue-soft) !important;
354
+ color: var(--cr-blue) !important;
355
+ font-family: 'JetBrains Mono', ui-monospace, monospace !important;
356
+ padding: 2px 6px !important;
357
+ border-radius: 2px !important;
358
+ }
359
+
360
+ /* ============================================================
361
+ * Part 10 β€” Scrollbars + Streamlit chrome
362
+ * ============================================================ */
363
+
364
+ html body ::-webkit-scrollbar { width: 8px; height: 8px; }
365
+ html body ::-webkit-scrollbar-track { background: var(--cr-bg); }
366
+ html body ::-webkit-scrollbar-thumb {
367
+ background: var(--cr-border);
368
+ border-radius: 3px;
369
+ }
370
+ html body ::-webkit-scrollbar-thumb:hover {
371
+ background: var(--cr-blue-dim);
372
+ }
373
+
374
+ html body .stApp header[data-testid="stHeader"] {
375
+ background: var(--cr-bg) !important;
376
+ border-bottom: 1px solid var(--cr-border) !important;
377
+ }
378
+ html body .stApp [data-testid="stSidebar"] {
379
+ background: var(--cr-surface) !important;
380
+ border-right: 1px solid var(--cr-border) !important;
381
+ }