File size: 28,164 Bytes
a6c5d0a
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>CodeGuard | AI-Powered Code Review & Security Analysis</title>
    <script src="https://cdn.tailwindcss.com"></script>
    <link href="https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&family=JetBrains+Mono:wght@400;500&display=swap" rel="stylesheet">
    <style>
        body {
            font-family: 'Inter', sans-serif;
            background-color: #22272E;
            color: #ADBAC7;
        }
        .code-font {
            font-family: 'JetBrains Mono', monospace;
        }
        .sidebar {
            scrollbar-width: thin;
            scrollbar-color: #2D333B #22272E;
        }
        .sidebar::-webkit-scrollbar {
            width: 6px;
        }
        .sidebar::-webkit-scrollbar-track {
            background: #22272E;
        }
        .sidebar::-webkit-scrollbar-thumb {
            background-color: #2D333B;
            border-radius: 3px;
        }
        .code-editor {
            background-color: #1C2128;
        }
        .cm-editor {
            height: 100%;
        }
        .security-critical {
            border-left: 3px solid #CF222E;
        }
        .security-high {
            border-left: 3px solid #E16F24;
        }
        .security-medium {
            border-left: 3px solid #D4A017;
        }
        .security-low {
            border-left: 3px solid #347D39;
        }
        .tab-active {
            border-bottom: 2px solid #347D39;
            color: white;
        }
        .resizer {
            background-color: #2D333B;
        }
        .resizer:hover {
            background-color: #347D39;
        }
    </style>
</head>
<body class="h-screen flex flex-col overflow-hidden">
    <!-- Header -->
    <header class="bg-[#2D333B] border-b border-[#444C56] px-6 py-3 flex items-center justify-between">
        <div class="flex items-center space-x-4">
            <div class="flex items-center">
                <svg xmlns="http://www.w3.org/2000/svg" class="h-8 w-8 text-[#347D39]" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
                    <path d="M12 2L2 7l10 5 10-5-10-5zM2 17l10 5 10-5M2 12l10 5 10-5"></path>
                </svg>
                <span class="ml-2 text-xl font-bold">CodeGuard</span>
            </div>
            <nav class="hidden md:flex space-x-6">
                <a href="#" class="hover:text-white">Dashboard</a>
                <a href="#" class="hover:text-white">Code Review</a>
                <a href="#" class="hover:text-white">Security Scan</a>
                <a href="#" class="hover:text-white">Reports</a>
                <a href="#" class="hover:text-white">Settings</a>
            </nav>
        </div>
        <div class="flex items-center space-x-4">
            <button class="bg-[#347D39] hover:bg-[#46954A] text-white px-4 py-1.5 rounded-md text-sm font-medium">
                New Scan
            </button>
            <div class="relative">
                <div class="h-8 w-8 rounded-full bg-[#444C56] flex items-center justify-center cursor-pointer">
                    <span class="text-sm">JS</span>
                </div>
            </div>
        </div>
    </header>

    <!-- Main Content -->
    <div class="flex flex-1 overflow-hidden">
        <!-- Sidebar -->
        <div class="sidebar w-64 bg-[#2D333B] border-r border-[#444C56] overflow-y-auto flex flex-col">
            <div class="p-4 border-b border-[#444C56]">
                <h2 class="font-semibold text-lg mb-2">Recent Projects</h2>
                <div class="space-y-2">
                    <div class="flex items-center p-2 rounded hover:bg-[#373E47] cursor-pointer">
                        <svg xmlns="http://www.w3.org/2000/svg" class="h-5 w-5 text-[#ADBAC7]" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
                            <path d="M22 19a2 2 0 0 1-2 2H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h5l2 2h5a2 2 0 0 1 2 2z"></path>
                        </svg>
                        <span class="ml-2">web-app-frontend</span>
                    </div>
                    <div class="flex items-center p-2 rounded hover:bg-[#373E47] cursor-pointer">
                        <svg xmlns="http://www.w3.org/2000/svg" class="h-5 w-5 text-[#ADBAC7]" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
                            <path d="M22 19a2 2 0 0 1-2 2H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h5l2 2h5a2 2 0 0 1 2 2z"></path>
                        </svg>
                        <span class="ml-2">api-service</span>
                    </div>
                    <div class="flex items-center p-2 rounded hover:bg-[#373E47] cursor-pointer">
                        <svg xmlns="http://www.w3.org/2000/svg" class="h-5 w-5 text-[#ADBAC7]" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
                            <path d="M22 19a2 2 0 0 1-2 2H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h5l2 2h5a2 2 0 0 1 2 2z"></path>
                        </svg>
                        <span class="ml-2">mobile-app</span>
                    </div>
                </div>
            </div>
            <div class="p-4 border-b border-[#444C56]">
                <h2 class="font-semibold text-lg mb-2">Security Scans</h2>
                <div class="space-y-2">
                    <div class="flex items-center p-2 rounded hover:bg-[#373E47] cursor-pointer">
                        <div class="h-2 w-2 rounded-full bg-[#347D39]"></div>
                        <span class="ml-2 text-sm">Completed 2 min ago</span>
                    </div>
                    <div class="flex items-center p-2 rounded hover:bg-[#373E47] cursor-pointer">
                        <div class="h-2 w-2 rounded-full bg-[#E16F24]"></div>
                        <span class="ml-2 text-sm">Running (45%)</span>
                    </div>
                    <div class="flex items-center p-2 rounded hover:bg-[#373E47] cursor-pointer">
                        <div class="h-2 w-2 rounded-full bg-[#CF222E]"></div>
                        <span class="ml-2 text-sm">Failed</span>
                    </div>
                </div>
            </div>
            <div class="p-4">
                <h2 class="font-semibold text-lg mb-2">Quick Actions</h2>
                <div class="space-y-2">
                    <button class="w-full flex items-center p-2 rounded hover:bg-[#373E47] cursor-pointer text-left">
                        <svg xmlns="http://www.w3.org/2000/svg" class="h-5 w-5 text-[#ADBAC7]" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
                            <path d="M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z"></path>
                            <polyline points="14 2 14 8 20 8"></polyline>
                            <line x1="16" y1="13" x2="8" y2="13"></line>
                            <line x1="16" y1="17" x2="8" y2="17"></line>
                            <polyline points="10 9 9 9 8 9"></polyline>
                        </svg>
                        <span class="ml-2">New Code Review</span>
                    </button>
                    <button class="w-full flex items-center p-2 rounded hover:bg-[#373E47] cursor-pointer text-left">
                        <svg xmlns="http://www.w3.org/2000/svg" class="h-5 w-5 text-[#ADBAC7]" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
                            <circle cx="12" cy="12" r="10"></circle>
                            <line x1="12" y1="8" x2="12" y2="12"></line>
                            <line x1="12" y1="16" x2="12.01" y2="16"></line>
                        </svg>
                        <span class="ml-2">Vulnerability Scan</span>
                    </button>
                    <button class="w-full flex items-center p-2 rounded hover:bg-[#373E47] cursor-pointer text-left">
                        <svg xmlns="http://www.w3.org/2000/svg" class="h-5 w-5 text-[#ADBAC7]" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
                            <path d="M12 20h9"></path>
                            <path d="M16.5 3.5a2.121 2.121 0 0 1 3 3L7 19l-4 1 1-4L16.5 3.5z"></path>
                        </svg>
                        <span class="ml-2">Penetration Test</span>
                    </button>
                </div>
            </div>
        </div>

        <!-- Main Panel -->
        <div class="flex-1 flex flex-col overflow-hidden">
            <!-- Tabs -->
            <div class="border-b border-[#444C56] flex">
                <div class="px-4 py-3 font-medium tab-active">Code Review</div>
                <div class="px-4 py-3 font-medium text-[#768390] hover:text-white cursor-pointer">Security Analysis</div>
                <div class="px-4 py-3 font-medium text-[#768390] hover:text-white cursor-pointer">Red Team Tools</div>
                <div class="px-4 py-3 font-medium text-[#768390] hover:text-white cursor-pointer">Blue Team Tools</div>
            </div>

            <!-- Split View Container -->
            <div class="flex-1 flex overflow-hidden">
                <!-- Code Editor Panel -->
                <div class="flex-1 flex flex-col overflow-hidden border-r border-[#444C56]">
                    <div class="p-3 border-b border-[#444C56] flex justify-between items-center">
                        <div class="flex items-center">
                            <span class="text-sm font-medium">app/components/AuthForm.js</span>
                            <span class="ml-2 text-xs px-2 py-0.5 bg-[#444C56] rounded">JavaScript</span>
                        </div>
                        <div class="flex space-x-2">
                            <button class="p-1 rounded hover:bg-[#373E47]">
                                <svg xmlns="http://www.w3.org/2000/svg" class="h-4 w-4" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
                                    <path d="M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2z"></path>
                                </svg>
                            </button>
                            <button class="p-1 rounded hover:bg-[#373E47]">
                                <svg xmlns="http://www.w3.org/2000/svg" class="h-4 w-4" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
                                    <path d="M11 4H4a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2v-7"></path>
                                    <path d="M18.5 2.5a2.121 2.121 0 0 1 3 3L12 15l-4 1 1-4 9.5-9.5z"></path>
                                </svg>
                            </button>
                            <button class="p-1 rounded hover:bg-[#373E47]">
                                <svg xmlns="http://www.w3.org/2000/svg" class="h-4 w-4" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
                                    <circle cx="12" cy="12" r="1"></circle>
                                    <circle cx="12" cy="5" r="1"></circle>
                                    <circle cx="12" cy="19" r="1"></circle>
                                </svg>
                            </button>
                        </div>
                    </div>
                    <div class="code-editor flex-1 overflow-auto p-4 code-font">
                        <div class="relative">
                            <div class="absolute left-0 top-0 w-8 text-right pr-2 text-[#768390] select-none">
                                <div>1</div>
                                <div>2</div>
                                <div>3</div>
                                <div>4</div>
                                <div>5</div>
                                <div>6</div>
                                <div>7</div>
                                <div>8</div>
                                <div>9</div>
                                <div>10</div>
                                <div>11</div>
                                <div>12</div>
                                <div>13</div>
                                <div>14</div>
                                <div>15</div>
                                <div>16</div>
                                <div>17</div>
                                <div>18</div>
                                <div>19</div>
                                <div>20</div>
                            </div>
                            <div class="ml-10">
                                <div><span class="text-[#6CB6FF]">import</span> React <span class="text-[#6CB6FF]">from</span> <span class="text-[#96D0FF]">'react'</span>;</div>
                                <div><span class="text-[#6CB6FF]">import</span> { useState } <span class="text-[#6CB6FF]">from</span> <span class="text-[#96D0FF]">'react'</span>;</div>
                                <div><span class="text-[#6CB6FF]">import</span> axios <span class="text-[#6CB6FF]">from</span> <span class="text-[#96D0FF]">'axios'</span>;</div>
                                <div><br></div>
                                <div><span class="text-[#6CB6FF]">const</span> <span class="text-[#DCBDFB]">AuthForm</span> = () <span class="text-[#6CB6FF]">=></span> {</div>
                                <div>  <span class="text-[#6CB6FF]">const</span> [email, setEmail] = <span class="text-[#DCBDFB]">useState</span>(<span class="text-[#96D0FF]">''</span>);</div>
                                <div>  <span class="text-[#6CB6FF]">const</span> [password, setPassword] = <span class="text-[#DCBDFB]">useState</span>(<span class="text-[#96D0FF]">''</span>);</div>
                                <div><br></div>
                                <div>  <span class="text-[#6CB6FF]">const</span> <span class="text-[#DCBDFB]">handleSubmit</span> = <span class="text-[#6CB6FF]">async</span> (e) <span class="text-[#6CB6FF]">=></span> {</div>
                                <div>    e.<span class="text-[#DCBDFB]">preventDefault</span>();</div>
                                <div>    <span class="text-[#6CB6FF]">try</span> {</div>
                                <div>      <span class="text-[#6CB6FF]">const</span> response = <span class="text-[#6CB6FF]">await</span> axios.<span class="text-[#DCBDFB]">post</span>(<span class="text-[#96D0FF]">'/api/auth'</span>, { email, password });</div>
                                <div>      console.<span class="text-[#DCBDFB]">log</span>(response.<span class="text-[#DCBDFB]">data</span>);</div>
                                <div>    } <span class="text-[#6CB6FF]">catch</span> (error) {</div>
                                <div>      console.<span class="text-[#DCBDFB]">error</span>(error.<span class="text-[#DCBDFB]">response</span>.<span class="text-[#DCBDFB]">data</span>);</div>
                                <div>    }</div>
                                <div>  };</div>
                                <div><br></div>
                                <div>  <span class="text-[#6CB6FF]">return</span> (</div>
                                <div>    &lt;form onSubmit={<span class="text-[#DCBDFB]">handleSubmit</span>}&gt;</div>
                                <div>      &lt;input type=<span class="text-[#96D0FF]">"email"</span> value={<span class="text-[#DCBDFB]">email</span>} onChange={(e) <span class="text-[#6CB6FF]">=></span> <span class="text-[#DCBDFB]">setEmail</span>(e.<span class="text-[#DCBDFB]">target</span>.<span class="text-[#DCBDFB]">value</span>)} /&gt;</div>
                                <div>      &lt;input type=<span class="text-[#96D0FF]">"password"</span> value={<span class="text-[#DCBDFB]">password</span>} onChange={(e) <span class="text-[#6CB6FF]">=></span> <span class="text-[#DCBDFB]">setPassword</span>(e.<span class="text-[#DCBDFB]">target</span>.<span class="text-[#DCBDFB]">value</span>)} /&gt;</div>
                                <div>      &lt;button type=<span class="text-[#96D0FF]">"submit"</span>&gt;Login&lt;/button&gt;</div>
                                <div>    &lt;/form&gt;</div>
                                <div>  );</div>
                                <div>};</div>
                                <div><br></div>
                                <div><span class="text-[#6CB6FF]">export</span> <span class="text-[#6CB6FF]">default</span> <span class="text-[#DCBDFB]">AuthForm</span>;</div>
                            </div>
                        </div>
                    </div>
                </div>

                <!-- Analysis Panel -->
                <div class="w-96 flex flex-col border-l border-[#444C56]">
                    <div class="p-3 border-b border-[#444C56] flex justify-between items-center">
                        <div class="flex items-center">
                            <span class="text-sm font-medium">Analysis Results</span>
                            <span class="ml-2 text-xs px-2 py-0.5 bg-[#444C56] rounded">3 issues</span>
                        </div>
                        <div class="flex space-x-2">
                            <button class="p-1 rounded hover:bg-[#373E47]">
                                <svg xmlns="http://www.w3.org/2000/svg" class="h-4 w-4" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
                                    <polyline points="3 6 5 6 21 6"></polyline>
                                    <path d="M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6m3 0V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2"></path>
                                </svg>
                            </button>
                            <button class="p-1 rounded hover:bg-[#373E47]">
                                <svg xmlns="http://www.w3.org/2000/svg" class="h-4 w-4" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
                                    <circle cx="12" cy="12" r="1"></circle>
                                    <circle cx="12" cy="5" r="1"></circle>
                                    <circle cx="12" cy="19" r="1"></circle>
                                </svg>
                            </button>
                        </div>
                    </div>
                    <div class="flex-1 overflow-auto p-4">
                        <div class="space-y-4">
                            <!-- Critical Issue -->
                            <div class="security-critical p-3 rounded bg-[#2D333B]">
                                <div class="flex items-start">
                                    <div class="flex-shrink-0 mt-1">
                                        <svg xmlns="http://www.w3.org/2000/svg" class="h-5 w-5 text-[#CF222E]" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
                                            <circle cx="12" cy="12" r="10"></circle>
                                            <line x1="12" y1="8" x2="12" y2="12"></line>
                                            <line x1="12" y1="16" x2="12.01" y2="16"></line>
                                        </svg>
                                    </div>
                                    <div class="ml-3">
                                        <h3 class="text-sm font-medium">Sensitive Data Exposure</h3>
                                        <div class="mt-1 text-sm">
                                            <p>Passwords are being transmitted in plaintext. Use HTTPS and implement proper password hashing.</p>
                                        </div>
                                        <div class="mt-2 flex items-center text-xs text-[#768390]">
                                            <span>Line 9</span>
                                            <span class="mx-2"></span>
                                            <span>Critical</span>
                                        </div>
                                    </div>
                                </div>
                            </div>
                            
                            <!-- High Issue -->
                            <div class="security-high p-3 rounded bg-[#2D333B]">
                                <div class="flex items-start">
                                    <div class="flex-shrink-0 mt-1">
                                        <svg xmlns="http://www.w3.org/2000/svg" class="h-5 w-5 text-[#E16F24]" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
                                            <circle cx="12" cy="12" r="10"></circle>
                                            <line x1="12" y1="8" x2="12" y2="12"></line>
                                            <line x1="12" y1="16" x2="12.01" y2="16"></line>
                                        </svg>
                                    </div>
                                    <div class="ml-3">
                                        <h3 class="text-sm font-medium">Insecure Direct Object Reference</h3>
                                        <div class="mt-1 text-sm">
                                            <p>The authentication endpoint doesn't implement rate limiting, making it vulnerable to brute force attacks.</p>
                                        </div>
                                        <div class="mt-2 flex items-center text-xs text-[#768390]">
                                            <span>Line 9</span>
                                            <span class="mx-2"></span>
                                            <span>High</span>
                                        </div>
                                    </div>
                                </div>
                            </div>
                            
                            <!-- Medium Issue -->
                            <div class="security-medium p-3 rounded bg-[#2D333B]">
                                <div class="flex items-start">
                                    <div class="flex-shrink-0 mt-1">
                                        <svg xmlns="http://www.w3.org/2000/svg" class="h-5 w-5 text-[#D4A017]" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round">
                                            <circle cx="12" cy="12" r="10"></circle>
                                            <line x1="12" y1="8" x2="12" y2="12"></line>
                                            <line x1="12" y1="16" x2="12.01" y2="16"></line>
                                        </svg>
                                    </div>
                                    <div class="ml-3">
                                        <h3 class="text-sm font-medium">Debug Information Exposure</h3>
                                        <div class="mt-1 text-sm">
                                            <p>Console logging of sensitive information in production code. Remove or implement proper logging.</p>
                                        </div>
                                        <div class="mt-2 flex items-center text-xs text-[#768390]">
                                            <span>Lines 10, 12</span>
                                            <span class="mx-2"></span>
                                            <span>Medium</span>
                                        </div>
                                    </div>
                                </div>
                            </div>
                        </div>
                        
                        <div class="mt-6">
                            <h3 class="text-sm font-medium mb-2">Suggested Fixes</h3>
                            <div class="bg-[#1C2128] p-3 rounded code-font text-sm">
                                <div>1. Implement HTTPS for all authentication requests</div>
                                <div>2. Use bcrypt or Argon2 for password hashing</div>
                                <div>3. Add rate limiting to the auth endpoint</div>
                                <div>4. Remove console.log statements in production</div>
                            </div>
                        </div>
                        
                        <div class="mt-6">
                            <button class="w-full bg-[#347D39] hover:bg-[#46954A] text-white px-4 py-2 rounded-md text-sm font-medium">
                                Apply Auto-Fixes
                            </button>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>

    <script>
        // Simple demo functionality
        document.addEventListener('DOMContentLoaded', function() {
            // Tab switching
            const tabs = document.querySelectorAll('.flex.border-b div[class*="px-4"]');
            tabs.forEach(tab => {
                tab.addEventListener('click', function() {
                    tabs.forEach(t => t.classList.remove('tab-active', 'text-white'));
                    tabs.forEach(t => t.classList.add('text-[#768390]'));
                    this.classList.add('tab-active', 'text-white');
                    this.classList.remove('text-[#768390]');
                });
            });
            
            // Simulate analysis loading
            setTimeout(() => {
                const analysisPanel = document.querySelector('.w-96');
                if (analysisPanel) {
                    const loadingIndicator = document.createElement('div');
                    loadingIndicator.className = 'absolute inset-0 flex items-center justify-center bg-[#22272E] bg-opacity-80';
                    loadingIndicator.innerHTML = `
                        <div class="flex flex-col items-center">
                            <svg class="animate-spin h-8 w-8 text-[#347D39]" xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 24 24">
                                <circle class="opacity-25" cx="12" cy="12" r="10" stroke="currentColor" stroke-width="4"></circle>
                                <path class="opacity-75" fill="currentColor" d="M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z"></path>
                            </svg>
                            <span class="mt-2 text-sm">Analyzing code...</span>
                        </div>
                    `;
                    analysisPanel.appendChild(loadingIndicator);
                    
                    setTimeout(() => {
                        loadingIndicator.remove();
                    }, 1500);
                }
            }, 500);
        });
    </script>
<p style="border-radius: 8px; text-align: center; font-size: 12px; color: #fff; margin-top: 16px;position: fixed; left: 8px; bottom: 8px; z-index: 10; background: rgba(0, 0, 0, 0.8); padding: 4px 8px;">Made with <img src="https://enzostvs-deepsite.hf.space/logo.svg" alt="DeepSite Logo" style="width: 16px; height: 16px; vertical-align: middle;display:inline-block;margin-right:3px;filter:brightness(0) invert(1);"><a href="https://enzostvs-deepsite.hf.space" style="color: #fff;text-decoration: underline;" target="_blank" >DeepSite</a> - 🧬 <a href="https://enzostvs-deepsite.hf.space?remix=S-Dreamer/codeguard" style="color: #fff;text-decoration: underline;" target="_blank" >Remix</a></p></body>
</html>