Nitish commited on
Commit
0d83deb
·
1 Parent(s): d76dc97

style: shift to nvidia hf space theme

Browse files
Files changed (2) hide show
  1. static/index.html +5 -5
  2. static/style.css +103 -80
static/index.html CHANGED
@@ -16,16 +16,16 @@
16
  <div id="particle-overlay"></div>
17
 
18
  <main class="container">
19
- <header class="glass-panel">
20
  <h1>Code Security RL Environment</h1>
21
  <p>Interactive baseline evaluation for AI Agents.</p>
22
  </header>
23
 
24
  <div class="dashboard">
25
  <!-- Left Column: Environment Observation -->
26
- <section class="glass-panel observation-panel" id="observation-section">
27
  <div class="panel-header">
28
- <h2><span class="icon">👁️</span> Environment State</h2>
29
  <div class="badge-row">
30
  <span id="badge-difficulty" class="badge">Loading...</span>
31
  <span id="badge-step" class="badge">Step 0/0</span>
@@ -49,9 +49,9 @@
49
  </section>
50
 
51
  <!-- Right Column: Agent Action Form -->
52
- <section class="glass-panel action-panel" id="action-section">
53
  <div class="panel-header">
54
- <h2><span class="icon">🛠️</span> Agent Action</h2>
55
  </div>
56
 
57
  <form id="action-form">
 
16
  <div id="particle-overlay"></div>
17
 
18
  <main class="container">
19
+ <header>
20
  <h1>Code Security RL Environment</h1>
21
  <p>Interactive baseline evaluation for AI Agents.</p>
22
  </header>
23
 
24
  <div class="dashboard">
25
  <!-- Left Column: Environment Observation -->
26
+ <section class="panel observation-panel" id="observation-section">
27
  <div class="panel-header">
28
+ <h2>Environment State</h2>
29
  <div class="badge-row">
30
  <span id="badge-difficulty" class="badge">Loading...</span>
31
  <span id="badge-step" class="badge">Step 0/0</span>
 
49
  </section>
50
 
51
  <!-- Right Column: Agent Action Form -->
52
+ <section class="panel action-panel" id="action-section">
53
  <div class="panel-header">
54
+ <h2>Agent Action</h2>
55
  </div>
56
 
57
  <form id="action-form">
static/style.css CHANGED
@@ -1,14 +1,18 @@
1
  :root {
2
- --bg-primary: #0a0a0f;
3
- --bg-card: rgba(20, 20, 30, 0.6);
4
- --bg-glass: rgba(255, 255, 255, 0.03);
5
- --border-glass: rgba(255, 255, 255, 0.08);
6
- --accent-primary: #7c3aed;
7
- --accent-glow: rgba(124, 58, 237, 0.5);
8
- --accent-secondary: #0ea5e9;
9
- --text-main: #f8fafc;
10
- --text-muted: #94a3b8;
11
- --success: #10b981;
 
 
 
 
12
  --error: #ef4444;
13
  }
14
 
@@ -19,7 +23,7 @@
19
  }
20
 
21
  body {
22
- font-family: 'Outfit', sans-serif;
23
  color: var(--text-main);
24
  background-color: var(--bg-primary);
25
  min-height: 100vh;
@@ -28,22 +32,15 @@ body {
28
  overflow-x: hidden;
29
  }
30
 
31
- /* Background Gradients & Animation */
32
  #app-background {
33
  position: fixed;
34
  top: 0;
35
  left: 0;
36
  width: 100%;
37
  height: 100%;
38
- background: radial-gradient(circle at 15% 50%, rgba(124, 58, 237, 0.15), transparent 25%),
39
- radial-gradient(circle at 85% 30%, rgba(14, 165, 233, 0.15), transparent 25%);
40
  z-index: -2;
41
- animation: pulseBg 10s ease-in-out infinite alternate;
42
- }
43
-
44
- @keyframes pulseBg {
45
- 0% { transform: scale(1); }
46
- 100% { transform: scale(1.1); }
47
  }
48
 
49
  .container {
@@ -52,32 +49,42 @@ body {
52
  }
53
 
54
  header {
55
- margin-bottom: 2rem;
56
  text-align: center;
57
- padding: 2rem;
 
58
  }
59
 
60
  h1 {
61
- font-size: 2.5rem;
62
- background: linear-gradient(to right, #a855f7, #38bdf8);
63
- -webkit-background-clip: text;
64
- background-clip: text;
65
- -webkit-text-fill-color: transparent;
66
  margin-bottom: 0.5rem;
67
  }
68
 
 
 
 
 
 
 
 
 
 
 
 
69
  p {
70
  color: var(--text-muted);
 
71
  }
72
 
73
- .glass-panel {
74
- background: var(--bg-glass);
75
- backdrop-filter: blur(16px);
76
- -webkit-backdrop-filter: blur(16px);
77
- border: 1px solid var(--border-glass);
78
- border-radius: 16px;
79
- padding: 1.5rem;
80
- box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.3);
81
  }
82
 
83
  .dashboard {
@@ -98,9 +105,9 @@ p {
98
  display: flex;
99
  justify-content: space-between;
100
  align-items: center;
101
- border-bottom: 1px solid var(--border-glass);
102
  padding-bottom: 1rem;
103
- margin-bottom: 1rem;
104
  }
105
 
106
  h2 {
@@ -109,6 +116,11 @@ h2 {
109
  display: flex;
110
  align-items: center;
111
  gap: 0.5rem;
 
 
 
 
 
112
  }
113
 
114
  .badge-row {
@@ -117,26 +129,30 @@ h2 {
117
  }
118
 
119
  .badge {
120
- background: rgba(255, 255, 255, 0.1);
 
121
  padding: 0.25rem 0.75rem;
122
- border-radius: 9999px;
123
  font-size: 0.75rem;
124
  font-weight: 600;
125
  letter-spacing: 0.05em;
126
  text-transform: uppercase;
 
127
  }
128
 
129
  /* Observation Panel */
130
  .task-info {
131
- margin-bottom: 1rem;
132
- font-size: 1rem;
133
- line-height: 1.5;
 
134
  }
135
 
136
  .feedback-info {
137
  background: rgba(239, 68, 68, 0.1);
138
  border: 1px solid rgba(239, 68, 68, 0.2);
139
- border-radius: 8px;
 
140
  padding: 1rem;
141
  margin-bottom: 1rem;
142
  font-size: 0.9rem;
@@ -147,18 +163,18 @@ h2 {
147
  }
148
 
149
  .code-container {
150
- background: #1a1b26;
151
- border-radius: 8px;
152
  overflow: hidden;
153
- border: 1px solid var(--border-glass);
154
  }
155
 
156
  .code-header {
157
- background: #16161e;
158
  padding: 0.5rem 1rem;
159
  font-size: 0.75rem;
160
  color: var(--text-muted);
161
- border-bottom: 1px solid #292e42;
162
  display: flex;
163
  justify-content: flex-end;
164
  }
@@ -166,8 +182,8 @@ h2 {
166
  pre {
167
  margin: 0;
168
  padding: 1rem;
169
- font-family: 'Roboto Mono', monospace;
170
- font-size: 0.9rem;
171
  overflow-x: auto;
172
  }
173
 
@@ -179,27 +195,27 @@ pre {
179
  label {
180
  display: block;
181
  font-size: 0.85rem;
182
- font-weight: 500;
183
- color: var(--text-muted);
184
- margin-bottom: 0.5rem;
185
  }
186
 
187
  input, select, textarea {
188
  width: 100%;
189
- background: rgba(0, 0, 0, 0.2);
190
- border: 1px solid var(--border-glass);
191
- border-radius: 8px;
192
  color: var(--text-main);
193
- padding: 0.75rem 1rem;
194
  font-family: inherit;
195
  font-size: 0.95rem;
196
- transition: all 0.2s;
197
  }
198
 
199
  input:focus, select:focus, textarea:focus {
200
  outline: none;
201
  border-color: var(--accent-primary);
202
- box-shadow: 0 0 0 2px var(--accent-glow);
203
  }
204
 
205
  select option {
@@ -209,36 +225,37 @@ select option {
209
 
210
  button {
211
  width: 100%;
212
- padding: 0.875rem;
213
  border: none;
214
- border-radius: 8px;
215
  font-family: inherit;
216
  font-weight: 600;
217
- font-size: 1rem;
218
  cursor: pointer;
219
  transition: all 0.2s;
220
  margin-bottom: 1rem;
 
 
221
  }
222
 
223
  .primary-btn {
224
- background: linear-gradient(to right, var(--accent-primary), var(--accent-secondary));
225
- color: white;
226
- box-shadow: 0 4px 15px var(--accent-glow);
227
  }
228
 
229
  .primary-btn:hover {
230
- transform: translateY(-2px);
231
- box-shadow: 0 6px 20px var(--accent-glow);
232
  }
233
 
234
  .secondary-btn {
235
  background: transparent;
236
- border: 1px solid var(--border-glass);
237
  color: var(--text-main);
238
  }
239
 
240
  .secondary-btn:hover {
241
- background: rgba(255, 255, 255, 0.05);
 
242
  }
243
 
244
  /* Toast */
@@ -246,19 +263,20 @@ button {
246
  position: fixed;
247
  bottom: 2rem;
248
  right: 2rem;
249
- background: rgba(20, 20, 30, 0.9);
250
- border: 1px solid var(--border-glass);
251
- padding: 1rem;
252
- border-radius: 8px;
 
253
  display: flex;
254
  justify-content: space-between;
255
  align-items: center;
256
- box-shadow: 0 10px 25px rgba(0,0,0,0.5);
257
  transform: translateY(100px);
258
  opacity: 0;
259
- animation: slideUp 0.4s forwards;
260
  z-index: 100;
261
- min-width: 300px;
262
  }
263
 
264
  @keyframes slideUp {
@@ -275,18 +293,19 @@ button {
275
  }
276
 
277
  .toast-icon {
278
- font-size: 1.5rem;
279
  }
280
 
281
  #toast-title {
282
- font-size: 0.9rem;
283
  margin-bottom: 0.2rem;
 
284
  }
285
 
286
  #toast-message {
287
  font-size: 1.1rem;
288
  font-weight: 600;
289
- color: var(--success);
290
  }
291
 
292
  #toast-close {
@@ -300,7 +319,11 @@ button {
300
  margin: 0;
301
  }
302
 
 
 
 
 
303
  .environment-done {
304
  border-color: var(--success);
305
- box-shadow: 0 0 20px rgba(16, 185, 129, 0.2);
306
  }
 
1
  :root {
2
+ --bg-primary: #000000;
3
+ --bg-card: #151515;
4
+ --bg-input: #1f1f1f;
5
+ --border-card: #2e2e2e;
6
+ --border-input: #3e3e3e;
7
+
8
+ /* NVIDIA Green */
9
+ --accent-primary: #76b900;
10
+ --accent-hover: #88d400;
11
+ --accent-glow: rgba(118, 185, 0, 0.2);
12
+
13
+ --text-main: #ffffff;
14
+ --text-muted: #a1a1aa;
15
+ --success: #76b900;
16
  --error: #ef4444;
17
  }
18
 
 
23
  }
24
 
25
  body {
26
+ font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
27
  color: var(--text-main);
28
  background-color: var(--bg-primary);
29
  min-height: 100vh;
 
32
  overflow-x: hidden;
33
  }
34
 
35
+ /* Background Subtle Glow */
36
  #app-background {
37
  position: fixed;
38
  top: 0;
39
  left: 0;
40
  width: 100%;
41
  height: 100%;
42
+ background: radial-gradient(circle at 50% 0%, rgba(118, 185, 0, 0.1), transparent 50%);
 
43
  z-index: -2;
 
 
 
 
 
 
44
  }
45
 
46
  .container {
 
49
  }
50
 
51
  header {
52
+ margin-bottom: 2.5rem;
53
  text-align: center;
54
+ padding: 2rem 0;
55
+ border-bottom: 1px solid var(--border-card);
56
  }
57
 
58
  h1 {
59
+ font-size: 2.25rem;
60
+ font-weight: 700;
61
+ letter-spacing: -0.02em;
62
+ color: var(--text-main);
 
63
  margin-bottom: 0.5rem;
64
  }
65
 
66
+ /* Add a subtle green underline to h1 */
67
+ h1::after {
68
+ content: '';
69
+ display: block;
70
+ width: 60px;
71
+ height: 4px;
72
+ background: var(--accent-primary);
73
+ margin: 1rem auto 0;
74
+ border-radius: 2px;
75
+ }
76
+
77
  p {
78
  color: var(--text-muted);
79
+ font-size: 1.1rem;
80
  }
81
 
82
+ .panel {
83
+ background: var(--bg-card);
84
+ border: 1px solid var(--border-card);
85
+ border-radius: 8px;
86
+ padding: 1.75rem;
87
+ box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.5), 0 2px 4px -1px rgba(0, 0, 0, 0.3);
 
 
88
  }
89
 
90
  .dashboard {
 
105
  display: flex;
106
  justify-content: space-between;
107
  align-items: center;
108
+ border-bottom: 1px solid var(--border-card);
109
  padding-bottom: 1rem;
110
+ margin-bottom: 1.25rem;
111
  }
112
 
113
  h2 {
 
116
  display: flex;
117
  align-items: center;
118
  gap: 0.5rem;
119
+ color: var(--text-main);
120
+ }
121
+
122
+ .icon {
123
+ color: var(--accent-primary);
124
  }
125
 
126
  .badge-row {
 
129
  }
130
 
131
  .badge {
132
+ background: var(--bg-input);
133
+ border: 1px solid var(--border-input);
134
  padding: 0.25rem 0.75rem;
135
+ border-radius: 4px;
136
  font-size: 0.75rem;
137
  font-weight: 600;
138
  letter-spacing: 0.05em;
139
  text-transform: uppercase;
140
+ color: var(--accent-primary);
141
  }
142
 
143
  /* Observation Panel */
144
  .task-info {
145
+ margin-bottom: 1.25rem;
146
+ font-size: 0.95rem;
147
+ line-height: 1.6;
148
+ color: #e4e4e7;
149
  }
150
 
151
  .feedback-info {
152
  background: rgba(239, 68, 68, 0.1);
153
  border: 1px solid rgba(239, 68, 68, 0.2);
154
+ border-left: 3px solid var(--error);
155
+ border-radius: 4px;
156
  padding: 1rem;
157
  margin-bottom: 1rem;
158
  font-size: 0.9rem;
 
163
  }
164
 
165
  .code-container {
166
+ background: #09090b;
167
+ border-radius: 6px;
168
  overflow: hidden;
169
+ border: 1px solid var(--border-card);
170
  }
171
 
172
  .code-header {
173
+ background: #18181b;
174
  padding: 0.5rem 1rem;
175
  font-size: 0.75rem;
176
  color: var(--text-muted);
177
+ border-bottom: 1px solid var(--border-card);
178
  display: flex;
179
  justify-content: flex-end;
180
  }
 
182
  pre {
183
  margin: 0;
184
  padding: 1rem;
185
+ font-family: 'JetBrains Mono', 'Roboto Mono', monospace;
186
+ font-size: 0.85rem;
187
  overflow-x: auto;
188
  }
189
 
 
195
  label {
196
  display: block;
197
  font-size: 0.85rem;
198
+ font-weight: 600;
199
+ color: #d4d4d8;
200
+ margin-bottom: 0.4rem;
201
  }
202
 
203
  input, select, textarea {
204
  width: 100%;
205
+ background: var(--bg-input);
206
+ border: 1px solid var(--border-input);
207
+ border-radius: 4px;
208
  color: var(--text-main);
209
+ padding: 0.65rem 0.875rem;
210
  font-family: inherit;
211
  font-size: 0.95rem;
212
+ transition: border-color 0.15s, box-shadow 0.15s;
213
  }
214
 
215
  input:focus, select:focus, textarea:focus {
216
  outline: none;
217
  border-color: var(--accent-primary);
218
+ box-shadow: 0 0 0 1px var(--accent-primary);
219
  }
220
 
221
  select option {
 
225
 
226
  button {
227
  width: 100%;
228
+ padding: 0.75rem;
229
  border: none;
230
+ border-radius: 4px;
231
  font-family: inherit;
232
  font-weight: 600;
233
+ font-size: 0.95rem;
234
  cursor: pointer;
235
  transition: all 0.2s;
236
  margin-bottom: 1rem;
237
+ text-transform: uppercase;
238
+ letter-spacing: 0.02em;
239
  }
240
 
241
  .primary-btn {
242
+ background: var(--accent-primary);
243
+ color: #000000;
 
244
  }
245
 
246
  .primary-btn:hover {
247
+ background: var(--accent-hover);
 
248
  }
249
 
250
  .secondary-btn {
251
  background: transparent;
252
+ border: 1px solid var(--border-input);
253
  color: var(--text-main);
254
  }
255
 
256
  .secondary-btn:hover {
257
+ background: var(--bg-input);
258
+ border-color: #52525b;
259
  }
260
 
261
  /* Toast */
 
263
  position: fixed;
264
  bottom: 2rem;
265
  right: 2rem;
266
+ background: #18181b;
267
+ border: 1px solid var(--accent-primary);
268
+ border-left: 4px solid var(--accent-primary);
269
+ padding: 1rem 1.25rem;
270
+ border-radius: 4px;
271
  display: flex;
272
  justify-content: space-between;
273
  align-items: center;
274
+ box-shadow: 0 10px 25px rgba(0,0,0,0.5), 0 0 15px var(--accent-glow);
275
  transform: translateY(100px);
276
  opacity: 0;
277
+ animation: slideUp 0.3s cubic-bezier(0.16, 1, 0.3, 1) forwards;
278
  z-index: 100;
279
+ min-width: 320px;
280
  }
281
 
282
  @keyframes slideUp {
 
293
  }
294
 
295
  .toast-icon {
296
+ font-size: 1.25rem;
297
  }
298
 
299
  #toast-title {
300
+ font-size: 0.85rem;
301
  margin-bottom: 0.2rem;
302
+ color: var(--text-muted);
303
  }
304
 
305
  #toast-message {
306
  font-size: 1.1rem;
307
  font-weight: 600;
308
+ color: var(--text-main);
309
  }
310
 
311
  #toast-close {
 
319
  margin: 0;
320
  }
321
 
322
+ #toast-close:hover {
323
+ color: var(--text-main);
324
+ }
325
+
326
  .environment-done {
327
  border-color: var(--success);
328
+ box-shadow: 0 0 15px var(--accent-glow);
329
  }