File size: 8,197 Bytes
67fb03c
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
/* ===== Base Styles ===== */
body {
	padding: 2rem;
	font-family: -apple-system, BlinkMacSystemFont, "Arial", sans-serif;
}

h1 {
	font-size: 16px;
	margin-top: 0;
}

p {
	color: rgb(107, 114, 128);
	font-size: 15px;
	margin: 0;
}

.card {
	max-width: 620px;
	margin: 0 auto;
	padding: 0;
	border: 1px solid lightgray;
	border-radius: 16px;
}

/* ===== Gradio UI Spacing Fixes ===== */

/* Remove spacing between Input Geometry title and upload button */
.gradio-container .panel h3 {
	margin-bottom: 0 !important;
	padding-bottom: 0 !important;
}

/* File upload component spacing */
#geom_file {
	margin-top: 0 !important;
	padding-top: 0 !important;
}

#geom_file .wrap,
#geom_file .border,
#geom_file .upload-box {
	margin-top: 0 !important;
	padding-top: 0 !important;
}

#geom_file label,
#geom_file input[type="file"] {
	margin: 0 !important;
}

/* ===== Fixed Height for Upload Panel ===== */

/* Maintain fixed height for the Input Geometry panel */
.gradio-container .panel:has(#geom_file) {
	min-height: 500px !important;
	height: 500px !important;
}

/* Ensure the file upload area maintains height during upload */
#geom_file {
	height: 500px !important;
	min-height: 500px !important;
}

/* Keep the Model3D viewer container at fixed height even when hidden */
.gradio-container .model3d-container {
	height: 500px !important;
	min-height: 500px !important;
}

/* Ensure the panel doesn't shrink during upload */
.gradio-container .panel .gr-block {
	min-height: 500px !important;
}

/* ===== Example Geometry Buttons ===== */

/* Style the example geometry buttons */
.gradio-container .panel button[data-testid*="example"] {
	background: #F3F4F6 !important;
	border: 1px solid #E5E7EB !important;
	color: #374151 !important;
	border-radius: 8px !important;
	padding: 8px 16px !important;
	font-weight: 500 !important;
	transition: all 0.2s ease !important;
}

.gradio-container .panel button[data-testid*="example"]:hover {
	background: #8B5CF6 !important;
	border-color: #8B5CF6 !important;
	color: white !important;
	transform: translateY(-1px) !important;
}

/* Example geometry section styling */
.gradio-container .panel h3:contains("Examples") {
	margin-bottom: 16px !important;
}

/* Example card styling */
.example-card {
	background: white !important;
	border: 1px solid #E5E7EB !important;
	border-radius: 12px !important;
	padding: 16px !important;
	margin: 8px !important;
	transition: all 0.2s ease !important;
	text-align: center !important;
}

.example-card:hover {
	border-color: #8B5CF6 !important;
	box-shadow: 0 4px 12px rgba(139, 92, 246, 0.1) !important;
}

.example-card .card-label {
	background: #8B5CF6 !important;
	color: white !important;
	padding: 4px 8px !important;
	border-radius: 12px !important;
	font-size: 12px !important;
	font-weight: 500 !important;
	display: inline-block !important;
	margin-bottom: 12px !important;
}

/* Example card buttons */
.example-card button {
	width: 100% !important;
	background: #F3F4F6 !important;
	border: 1px solid #E5E7EB !important;
	color: #374151 !important;
	border-radius: 8px !important;
	padding: 8px 16px !important;
	font-weight: 500 !important;
	transition: all 0.2s ease !important;
}

.example-card button:hover {
	background: #8B5CF6 !important;
	border-color: #8B5CF6 !important;
	color: white !important;
	transform: translateY(-1px) !important;
}

/* Example card Model3D preview styling */
.example-card .model3d-container {
	border-radius: 8px !important;
	margin: 8px !important;
	overflow: hidden !important;
}

.example-card .model3d-container canvas {
	border-radius: 8px !important;
}

.colorbar-no-controls img {
    height: 100% !important;
    width: auto !important;
    object-fit: contain !important;
}
.prediction-stats {
    margin-top: 10px;
    padding: 10px;
    background-color: rgba(0, 0, 0, 0.05);
    border-radius: 5px;
    border-left: 3px solid #007acc;
}
.prediction-stats h3, .prediction-stats h4 {
    margin: 5px 0;
}
.prediction-stats ul {
    margin: 5px 0;
    padding-left: 20px;
}
.prediction-stats li {
    margin: 2px 0;
    font-size: 14px;
}

/* ===== Boundary Conditions Styling ===== */

/* Style the boundary conditions group to match dropdown theme */
.gradio-container .gr-group {
    background: transparent !important;
    border: none !important;
    border-radius: 0 !important;
    padding: 0 !important;
    margin: 8px 0 !important;
}

/* Style the boundary conditions title to match sub application purple theme */
.gradio-container .gr-group h3 {
    color: #8B5CF6 !important;
    font-weight: 600 !important;
    margin-bottom: 12px !important;
}

/* More specific selector for boundary conditions title */
.gradio-container .gr-group .gr-markdown h3 {
    color: #8B5CF6 !important;
    font-weight: 600 !important;
}

/* Even more specific for markdown content */
.gradio-container .gr-group .gr-markdown {
    color: #8B5CF6 !important;
}

.gradio-container .gr-group .gr-markdown h3,
.gradio-container .gr-group .gr-markdown h3 * {
    color: #8B5CF6 !important;
}

/* Specific styling for boundary conditions title */
.boundary-conditions-title h3 {
    color: #8B5CF6 !important;
    font-weight: 600 !important;
}

.boundary-conditions-title {
    color: #8B5CF6 !important;
}

/* More aggressive targeting for boundary conditions title */
.gradio-container .boundary-conditions-title,
.gradio-container .boundary-conditions-title *,
.gradio-container .boundary-conditions-title h3,
.gradio-container .boundary-conditions-title h3 *,
.gradio-container .boundary-conditions-title .gr-markdown,
.gradio-container .boundary-conditions-title .gr-markdown * {
    color: #8B5CF6 !important;
}

/* Target the markdown content directly */
.gradio-container .gr-group .boundary-conditions-title .gr-markdown h3 {
    color: #8B5CF6 !important;
    font-weight: 600 !important;
}

/* Style the boundary conditions markdown content */
.boundary-conditions {
    background: transparent !important;
    border: none !important;
    border-radius: 0 !important;
    padding: 0 !important;
    margin-top: 8px !important;
    font-size: 14px !important;
    line-height: 1.6 !important;
}

/* Style the velocity slider container */
.slider-container {
    margin-bottom: 12px !important;
}

/* Ensure consistent spacing in boundary conditions */
.boundary-conditions ul {
    margin: 0 !important;
    padding-left: 16px !important;
}

.boundary-conditions li {
    margin: 8px 0 !important;
    padding: 4px 0 !important;
    line-height: 1.8 !important;
}

/* More aggressive spacing for boundary conditions */
.boundary-conditions p {
    margin: 8px 0 !important;
    line-height: 1.8 !important;
}

.boundary-conditions {
    line-height: 1.8 !important;
}

/* Target the markdown content more specifically */
.gradio-container .boundary-conditions * {
    margin: 6px 0 !important;
    line-height: 1.8 !important;
}

/* Add gap between boundary conditions title and content */
.gradio-container .gr-group .dropdown {
    margin-bottom: 20px !important;
}

/* Add gap after the boundary conditions title */
.gradio-container .gr-group .dropdown h3 {
    margin-bottom: 20px !important;
}

/* Force transparent background for all boundary conditions elements */
.gradio-container .gr-group,
.gradio-container .gr-group *,
.gradio-container .gr-group .gr-markdown,
.gradio-container .gr-group .gr-markdown *,
.gradio-container .gr-group .dropdown,
.gradio-container .gr-group .dropdown *,
.gradio-container .gr-group .boundary-conditions,
.gradio-container .gr-group .boundary-conditions * {
    background: transparent !important;
    background-color: transparent !important;
}

/* Remove any borders from boundary conditions */
.gradio-container .gr-group,
.gradio-container .gr-group .gr-markdown,
.gradio-container .gr-group .dropdown,
.gradio-container .gr-group .boundary-conditions {
    border: none !important;
    border-color: transparent !important;
    box-shadow: none !important;
}

#bc_box {
    background-color: transparent !important;
    box-shadow: none !important;
    border: none !important;
}

#bc_group {
    background-color: #8B5CF6  !important;
    box-shadow: none !important;
    border: none !important;
}