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 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
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
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
1001
1002
1003
1004
1005
1006
1007
1008
1009
1010
1011
1012
1013
1014
1015
1016
1017
1018
1019
1020
1021
1022
1023
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>AI STEM Lab</title>
    <style>
        :root {
            /* Dark Mode Variables */
            --bg-color: #121212;
            --card-bg: #1e1e1e;
            --accent-color: #0a84ff; /* Apple-style vibrant blue */
            --accent-hover: #409cff;
            --text-main: #f5f5f7;
            --text-secondary: #a1a1a6;
            
            /* Window Colors */
            --mac-window-bg: #2c2c2e;
            --mac-header-bg: #3a3a3c;
            --mac-border: rgba(0, 0, 0, 0.5);
        }

        body {
            font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
            background-color: var(--bg-color);
            color: var(--text-main);
            margin: 0;
            display: flex;
            flex-direction: column;
            align-items: center;
            justify-content: center;
            min-height: 100vh;
            padding: 20px;
        }

        /* Playground Header */
        header {
            margin-bottom: 50px;
            text-align: center;
            max-width: 800px;
        }

        h1 {
            color: var(--text-main);
            font-weight: 800;
            font-size: 3rem;
            margin: 0 0 15px 0;
            letter-spacing: -0.03em;
            background: linear-gradient(90deg, #fff, #a1a1a6);
            -webkit-background-clip: text;
            -webkit-text-fill-color: transparent;
        }

        p.subtitle {
            color: var(--text-secondary);
            font-size: 1.3rem;
            line-height: 1.5;
        }

        /* Card Container */
        .playground-grid {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(360px, 1fr));
            gap: 30px;
            width: 95%;
            max-width: 1400px;
        }

        /* Lab Cards */
        .card {
            background: var(--card-bg);
            border-radius: 24px;
            padding: 40px;
            box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
            transition: transform 0.3s cubic-bezier(0.25, 0.8, 0.25, 1), box-shadow 0.3s ease;
            display: flex;
            flex-direction: column;
            align-items: flex-start;
            border: 1px solid rgba(255,255,255,0.08);
            position: relative;
            overflow: hidden;
        }

        .card:hover {
            transform: translateY(-8px);
            box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5);
            border-color: rgba(255,255,255,0.2);
        }

        .card::before {
            content: '';
            position: absolute;
            top: 0;
            left: 0;
            width: 100%;
            height: 6px;
            background: linear-gradient(90deg, var(--accent-color), #bc52ff);
            opacity: 0.7;
        }

        .icon-box {
            width: 64px;
            height: 64px;
            background: rgba(255, 255, 255, 0.1);
            border-radius: 16px;
            display: flex;
            align-items: center;
            justify-content: center;
            font-size: 32px;
            margin-bottom: 25px;
        }

        .card h2 {
            margin: 0 0 15px 0;
            font-size: 1.8rem;
            font-weight: 700;
            color: var(--text-main);
        }

        .card p {
            margin: 0 0 30px 0;
            color: var(--text-secondary);
            line-height: 1.6;
            font-size: 1.1rem;
            flex-grow: 1;
        }
        
        .card strong {
            color: #fff;
            font-weight: 600;
        }

        .launch-btn {
            background-color: var(--accent-color);
            color: white;
            border: none;
            padding: 14px 28px;
            border-radius: 30px;
            font-weight: 600;
            font-size: 1.1rem;
            cursor: pointer;
            transition: all 0.2s ease;
            width: 100%;
            text-align: center;
        }

        .launch-btn:hover {
            background-color: var(--accent-hover);
            transform: scale(1.02);
        }

        /* Modal Overlay */
        .modal-overlay {
            position: fixed;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            background: rgba(0, 0, 0, 0.75);
            backdrop-filter: blur(8px);
            z-index: 1000;
            display: none; /* Changed from visibility hidden to display none for stricter reset */
            align-items: center;
            justify-content: center;
            opacity: 0;
            transition: opacity 0.3s ease;
        }

        .modal-overlay.active {
            display: flex;
            opacity: 1;
        }

        /* macOS Window Styling */
        .mac-window {
            width: 85%;
            max-width: 1000px;
            height: 85vh;
            background: var(--mac-window-bg);
            border-radius: 12px;
            box-shadow: 0 50px 100px rgba(0, 0, 0, 0.6);
            display: flex;
            flex-direction: column;
            overflow: hidden;
            border: 1px solid rgba(255,255,255,0.1);
            transform: scale(0.95);
            transition: transform 0.3s cubic-bezier(0.19, 1, 0.22, 1);
            position: relative;
        }

        .modal-overlay.active .mac-window {
            transform: scale(1);
        }

        /* Window Header */
        .window-header {
            height: 44px;
            background: var(--mac-header-bg);
            border-bottom: 1px solid #1c1c1e;
            display: flex;
            align-items: center;
            padding-left: 16px;
            cursor: default;
        }

        /* The Red Button */
        .traffic-light {
            width: 14px;
            height: 14px;
            border-radius: 50%;
            background-color: #ff453a;
            border: none;
            cursor: pointer;
            position: relative;
            display: flex;
            align-items: center;
            justify-content: center;
            box-shadow: inset 0 1px 2px rgba(0,0,0,0.2);
        }

        .traffic-light:hover::after {
            content: "Γ—";
            color: #3b0000;
            font-size: 11px;
            font-weight: 900;
            margin-top: -1px;
        }

        .window-title {
            position: absolute;
            left: 50%;
            transform: translateX(-50%);
            font-size: 14px;
            color: #cfcfcf;
            font-weight: 500;
        }

        /* Window Content */
        .window-content {
            flex: 1;
            background: #000;
            position: relative;
        }

        iframe {
            width: 100%;
            height: 100%;
            border: none;
            background: #121212;
        }

    </style>
</head>
<body>

    <header>
        <h1>AI Model Laboratory</h1>
        <p class="subtitle">Welcome to the hands-on section! Based on the slideshow we just watched, choose an experiment below to test how computers "see" the world.</p>
    </header>

<div class="playground-grid">
  <!-- Option 1: Pose Estimation -->
  <div class="card">
    <div class="icon-box">🧘</div>
    <h2>Pose Estimation</h2>
    <p>
      <strong>Remember the slide about skeletons?</strong><br><br>
      In this experiment, the AI will try to find your joints (like elbows, knees, and shoulders) and connect them with lines.
      <br><br>
      <em>Try this: Try to do some movements with yout hands and face. Does the AI follow your movement?</em>
    </p>
    <button class="launch-btn" onclick="openWindow('Pose Estimation', 'pose.html')">Launch Experiment</button>
  </div>

  <!-- Option 2: Object Recognition -->
  <div class="card">
    <div class="icon-box">πŸ”</div>
    <h2>Object Recognition</h2>
    <p>
      <strong>How does a self-driving car see?</strong><br><br>
      This model is trained to recognize thousands of everyday items. It draws a box around what it sees and gives it a label.
      <br><br>
      <em>Try this: Hold up a pen, a water bottle, or your shoe. Can it guess them all correctly?</em>
    </p>
<center>
        <button id="dev-trigger-btn">Wondering what objects this model can detect? Click here to find out!</button>
</center>
<br>
    <button class="launch-btn" onclick="openWindow('Object Recognition', 'Object-Detection.html')">Launch Experiment</button>
  </div>

  <!-- Option 3: Face Expression -->
  <div class="card">
    <div class="icon-box">😊</div>
    <h2>Face Expression</h2>
    <p>
      <strong>Can computers understand feelings?</strong><br><br>
      This AI looks at the geometry of your faceβ€”how much your mouth curves or your eyebrows liftβ€”to guess your emotion.
      <br><br>
      <em>Try this: Make a super happy face, then a sad face. See if the "Confidence Score" changes!</em>
    </p>
    <button class="launch-btn" onclick="openWindow('Face Expression', 'Face-Expresion.html')">Launch Experiment</button>
  </div>
</div>

<h1 style="text-align:center; margin:60px 0 30px;">
  Here are some extra ones that you might like....
</h1>

<div class="playground-grid">
  <!-- Extra Option 1 -->
  <div class="card">
    <div class="icon-box">πŸƒ</div>
<h2>JS WebCam Motion Detection</h2>
<p>
  <strong>Can a computer actually β€œsee” movement?</strong><br><br>
  This project watches your webcam and compares each frame to the one before it. 
  When something movesβ€”even a tiny bitβ€”the computer highlights the change so you can 
  spot motion glowing on the screen.<br><br>
  <em>Try this: Wave your hand slowly, then quickly. Notice how the motion pattern changes!</em>
</p>
    <button class="launch-btn" onclick="openWindow('Movement Detection', 'movement-detection.html')">Launch Experiment</button>
  </div>

  <!-- Extra Option 2 -->
  <div class="card">
    <div class="icon-box">πŸ‘οΈ</div>
    <h2>Object Detection with TensorFlow.js</h2>
    <p>
    <strong>How can a computer tell what's in a picture?</strong><br><br>
    This project uses a pre‑trained AI model that can look at an imageβ€”or even your
    webcamβ€”and point out objects it recognizes. It doesn’t just guess the object,
    it also shows *where* it is in the picture by drawing a box around it.<br><br>
    <em>Try this: Hold up different objects (like a pencil, cup, or book) and see
    which ones the AI can detect!</em>
    </p>
        <button class="launch-btn" onclick="openWindow('Object Detection with TensorFlow.js', 'live-feed-object-detection.html')">Launch Experiment</button>
  </div>
    <!-- Extra Option 2 -->
  <div class="card">
    <div class="icon-box">πŸ‘οΈ</div>
<h2>Want to make your own model?</h2>
<p>
  <strong>How about making your own AI model that detects the objects <em>you</em> care about?</strong><br><br>
  You can try this experiment to build your own custom model using TensorFlow.js and the Teachable Machine Algorithm.<br><br>
  <br>
  <em>Tip:</em> Try choosing 2 objects around you (like a water bottle, pencil, pair of headphones, or even yourself) and gather at least 30 images of each from different angles. The more variety you include, the smarter your model becomes.<br><br>
 
</p>
    </p>
        <button class="launch-btn" onclick="openWindow('build your own custom model using TensorFlow.js and the Teachable Machine Algorithm', 'make-model.html')">Launch Experiment</button>
  </div>
</div>




<!-- Modal Overlay -->
<div class="modal-overlay" id="modalOverlay">
  <div class="mac-window" id="macWindow">
    <div class="window-header">
      <div class="traffic-light" id="closeBtn"></div>
      <div class="window-title" id="windowTitle">Terminal</div>
    </div>
    <div class="window-content">
      <iframe id="labFrame" src=""></iframe>
    </div>
  </div>




</div>


    <script>
        // Wait for DOM to load to prevent "not defined" errors
        document.addEventListener('DOMContentLoaded', function() {
            
            const overlay = document.getElementById('modalOverlay');
            const macWindow = document.getElementById('macWindow');
            const labFrame = document.getElementById('labFrame');
            const windowTitle = document.getElementById('windowTitle');
            const closeBtn = document.getElementById('closeBtn');

            // Global function to be called by buttons
            window.openWindow = function(title, fileName) {
                if (windowTitle) windowTitle.textContent = "Running: " + title;
                if (overlay) overlay.classList.add('active');
                
                // Set the iframe SRC to the actual file link
                if (labFrame) labFrame.src = fileName; 
            };

            function closeWindow() {
                if (overlay) overlay.classList.remove('active');
                // Clear iframe src to stop the page from running in background
                setTimeout(() => {
                    if (labFrame) labFrame.src = "";
                }, 300);
            }

            // Close button listener
            if (closeBtn) {
                closeBtn.addEventListener('click', closeWindow);
            }

            // Click outside to close Logic
            if (overlay) {
                overlay.addEventListener('click', function(event) {
                    if (event.target === overlay) {
                        closeWindow();
                    }
                });
            }

            // Prevent clicks inside the window from closing it
            if (macWindow) {
                macWindow.addEventListener('click', function(event) {
                    event.stopPropagation();
                });
            }
        });
    </script>

</body>
</html>

















































































































































































































































































































































































































































































































<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <style>


        /* The Trigger Button */
        #dev-trigger-btn {
            background-color: #007AFF;
            color: white;
            border: none;
            padding: 12px 24px;
            font-size: 16px;
            font-weight: 600;
            border-radius: 8px;
            cursor: pointer;
            box-shadow: 0 4px 6px rgba(0,0,0,0.1);
            transition: transform 0.1s ease;
        }

        #dev-trigger-btn:active {
            transform: scale(0.96);
        }

        /* Modal Overlay (Background) */
        #modal-overlay {
            display: none; /* Hidden by default */
            position: fixed;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            background: rgba(0, 0, 0, 0.4);
            backdrop-filter: blur(5px);
            z-index: 1000;
            justify-content: center;
            align-items: center;
            opacity: 0;
            transition: opacity 0.3s ease;
        }

        /* The Dark MacOS Window */
        #macos-window {
            width: 80%;
            max-width: 900px;
            height: 70%;
            background-color: #1e1e1e; /* Dark Mode Background */
            border-radius: 12px;
            box-shadow: 0 20px 50px rgba(0,0,0,0.5), 0 0 0 1px rgba(255,255,255,0.1);
            display: flex;
            flex-direction: column;
            overflow: hidden;
            transform: scale(0.95);
            transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
        }

        /* Window Title Bar */
        .window-header {
            height: 38px;
            background: linear-gradient(to bottom, #3a3a3a, #2b2b2b);
            border-bottom: 1px solid #000;
            display: flex;
            align-items: center;
            padding: 0 16px;
            flex-shrink: 0;
        }

        /* Traffic Light Buttons */
        .window-controls {
            display: flex;
            gap: 8px;
        }

        .control-dot {
            width: 12px;
            height: 12px;
            border-radius: 50%;
            border: 1px solid rgba(0,0,0,0.2);
        }

        .close-dot { background-color: #ff5f56; cursor: pointer; }
        .close-dot:hover { background-color: #ff3b30; } /* Brightens on hover */
        .minimize-dot { background-color: #ffbd2e; }
        .expand-dot { background-color: #27c93f; }

        .window-title {
            color: #d1d1d1;
            font-size: 13px;
            font-weight: 500;
            margin-left: 20px;
            flex-grow: 1;
            text-align: center;
            padding-right: 60px; /* Balance the title */
        }

        /* Content Area */
        .window-content {
            padding: 20px;
            overflow-y: auto;
            color: #fff;
        }

        /* Grid for Tiles */
        .tiles-grid {
            display: grid;
            grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
            gap: 16px;
        }

        /* Individual Tile Style */
        .tile {
            background-color: #2c2c2e;
            border: 1px solid #3a3a3c;
            border-radius: 8px;
            padding: 16px;
            display: flex;
            flex-direction: column;
            gap: 8px;
            transition: background-color 0.2s;
        }

        .tile:hover {
            background-color: #3a3a3c;
        }

        .tile-icon {
            font-size: 32px;
        }

        .tile-name {
            font-size: 16px;
            font-weight: 700;
            color: #fff;
            text-transform: capitalize;
        }

        .tile-desc {
            font-size: 13px;
            line-height: 1.4;
            color: #a1a1a6;
        }

        /* Scrollbar Styling */
        .window-content::-webkit-scrollbar {
            width: 8px;
        }
        .window-content::-webkit-scrollbar-track {
            background: #1e1e1e;
        }
        .window-content::-webkit-scrollbar-thumb {
            background: #48484a;
            border-radius: 4px;
        }

        /* Animation States */
        #modal-overlay.active {
            display: flex;
            opacity: 1;
        }
        
        #modal-overlay.active #macos-window {
            transform: scale(1);
        }
    </style>
</head>
<body>

    <!-- 1. The Trigger Button -->

    <!-- 2. The Modal Structure -->
    <div id="modal-overlay">
        <div id="macos-window">
            <!-- Header with Red Button -->
            <div class="window-header">
<div class="window-controls">
    <div class="control-dot close-dot" id="close-btn" title="Close"></div>
</div>

                <div class="window-title">COCO Dataset Classes (80 Objects)</div>
            </div>
            
            <!-- Content -->
            <div class="window-content">
                <div style="margin-bottom: 20px; color: #a1a1a6; font-size: 14px;">
                    This AI model is trained to see the world like you do. Below are the 80 different things it can instantly recognize in a photo.
                </div>
                <div class="tiles-grid" id="tiles-container">
                    <!-- Tiles injected via JS -->
                </div>
            </div>
        </div>
    </div>

    <script>
        // Data: 80 COCO Classes with Emojis and Kid-Friendly Explanations
        const cocoData = [
            { name: "person", emoji: "πŸ‘€", desc: "A human being, like you, your friends, or your teacher." },
            { name: "bicycle", emoji: "🚲", desc: "A two-wheeled vehicle that you pedal to ride." },
            { name: "car", emoji: "πŸš—", desc: "A vehicle with four wheels used to drive on roads." },
            { name: "motorcycle", emoji: "🏍️", desc: "Like a bicycle, but with a fast engine and heavier wheels." },
            { name: "airplane", emoji: "✈️", desc: "A flying machine with wings that carries passengers across the sky." },
            { name: "bus", emoji: "🚌", desc: "A large vehicle that carries many people along a set route." },
            { name: "train", emoji: "πŸš†", desc: "A series of connected cars that run on a metal track." },
            { name: "truck", emoji: "🚚", desc: "A large, heavy vehicle used for carrying cargo or big loads." },
            { name: "boat", emoji: "β›΅", desc: "A vehicle designed to float and travel on water." },
            { name: "traffic light", emoji: "🚦", desc: "A signal with red, yellow, and green lights to control cars." },
            { name: "fire hydrant", emoji: "πŸš’", desc: "A pipe on the street that firefighters use to get water." },
            { name: "stop sign", emoji: "πŸ›‘", desc: "A red octagon sign that tells drivers to stop moving." },
            { name: "parking meter", emoji: "πŸ…ΏοΈ", desc: "A machine where you pay money to park your car on the street." },
            { name: "bench", emoji: "πŸͺ‘", desc: "A long seat for several people, usually found in parks." },
            { name: "bird", emoji: "🐦", desc: "An animal with feathers and wings that can usually fly." },
            { name: "cat", emoji: "🐈", desc: "A small, furry pet that purrs and catches mice." },
            { name: "dog", emoji: "πŸ•", desc: "A loyal pet with four legs that barks and loves to play." },
            { name: "horse", emoji: "🐎", desc: "A large, strong animal that people can ride." },
            { name: "sheep", emoji: "πŸ‘", desc: "A fluffy farm animal that gives us wool for clothes." },
            { name: "cow", emoji: "πŸ„", desc: "A large farm animal that gives us milk." },
            { name: "elephant", emoji: "🐘", desc: "A huge animal with big ears and a long trunk." },
            { name: "bear", emoji: "🐻", desc: "A large, strong wild animal with thick fur." },
            { name: "zebra", emoji: "πŸ¦“", desc: "A wild horse-like animal with black and white stripes." },
            { name: "giraffe", emoji: "πŸ¦’", desc: "The tallest animal, with a very long neck to eat tree leaves." },
            { name: "backpack", emoji: "πŸŽ’", desc: "A bag you carry on your back to hold books and supplies." },
            { name: "umbrella", emoji: "β˜‚οΈ", desc: "A tool you hold over your head to stay dry in the rain." },
            { name: "handbag", emoji: "πŸ‘œ", desc: "A small bag used to carry personal items like a wallet." },
            { name: "tie", emoji: "πŸ‘”", desc: "A long piece of cloth worn around the neck with a suit." },
            { name: "suitcase", emoji: "🧳", desc: "A large bag used for packing clothes when traveling." },
            { name: "frisbee", emoji: "πŸ₯", desc: "A plastic disc you throw to a friend or dog." },
            { name: "skis", emoji: "⛷️", desc: "Long, flat runners you attach to boots to glide on snow." },
            { name: "snowboard", emoji: "πŸ‚", desc: "A single wide board you stand on to surf down snowy hills." },
            { name: "sports ball", emoji: "⚽", desc: "Any round object used in games like soccer, basketball, or tennis." },
            { name: "kite", emoji: "πŸͺ", desc: "A light frame with paper or cloth that flies in the wind." },
            { name: "baseball bat", emoji: "⚾", desc: "A smooth wooden or metal stick used to hit a baseball." },
            { name: "baseball glove", emoji: "🧀", desc: "A leather mitt worn to catch a baseball safely." },
            { name: "skateboard", emoji: "πŸ›Ή", desc: "A short board with wheels that you stand on and ride." },
            { name: "surfboard", emoji: "πŸ„", desc: "A long board used to ride ocean waves." },
            { name: "tennis racket", emoji: "🎾", desc: "A bat with a net mesh used to hit a tennis ball." },
            { name: "bottle", emoji: "🍾", desc: "A container with a narrow neck for holding liquids." },
            { name: "wine glass", emoji: "🍷", desc: "A fancy glass with a stem, used for special drinks." },
            { name: "cup", emoji: "β˜•", desc: "A small open container for drinking tea or coffee." },
            { name: "fork", emoji: "🍴", desc: "A tool with prongs used to pick up food." },
            { name: "knife", emoji: "πŸ”ͺ", desc: "A tool with a sharp edge used for cutting food." },
            { name: "spoon", emoji: "πŸ₯„", desc: "A tool with a small scoop for eating soup or cereal." },
            { name: "bowl", emoji: "πŸ₯£", desc: "A round, deep dish used for soup or cereal." },
            { name: "banana", emoji: "🍌", desc: "A long, curved yellow fruit that you peel to eat." },
            { name: "apple", emoji: "🍎", desc: "A round red or green fruit that is crunchy and sweet." },
            { name: "sandwich", emoji: "πŸ₯ͺ", desc: "Two slices of bread with meat, cheese, or veggies inside." },
            { name: "orange", emoji: "🍊", desc: "A round citrus fruit with a thick skin and juicy inside." },
            { name: "broccoli", emoji: "πŸ₯¦", desc: "A green vegetable that looks like a little tree." },
            { name: "carrot", emoji: "πŸ₯•", desc: "A crunchy orange vegetable that grows underground." },
            { name: "hot dog", emoji: "🌭", desc: "A cooked sausage served in a long, soft bun." },
            { name: "pizza", emoji: "πŸ•", desc: "A round dough base topped with tomato sauce and cheese." },
            { name: "donut", emoji: "🍩", desc: "A sweet, fried ring of dough, often with frosting." },
            { name: "cake", emoji: "πŸŽ‚", desc: "A sweet baked dessert often eaten at birthday parties." },
            { name: "chair", emoji: "πŸͺ‘", desc: "A piece of furniture designed for one person to sit on." },
            { name: "couch", emoji: "πŸ›‹οΈ", desc: "A soft, long seat where multiple people can relax." },
            { name: "potted plant", emoji: "πŸͺ΄", desc: "A plant grown inside a container for decoration." },
            { name: "bed", emoji: "πŸ›οΈ", desc: "A piece of furniture with a mattress for sleeping." },
            { name: "dining table", emoji: "🍽️", desc: "A large table where families sit to eat meals." },
            { name: "toilet", emoji: "🚽", desc: "A bathroom fixture used for getting rid of waste." },
            { name: "tv", emoji: "πŸ“Ί", desc: "An electronic screen for watching shows and movies." },
            { name: "laptop", emoji: "πŸ’»", desc: "A portable computer that you can use on your lap." },
            { name: "mouse", emoji: "πŸ–±οΈ", desc: "A handheld device used to move the cursor on a computer." },
            { name: "remote", emoji: "πŸ“‘", desc: "A controller used to change channels on a TV from afar." },
            { name: "keyboard", emoji: "⌨️", desc: "A board with buttons for typing letters into a computer." },
            { name: "cell phone", emoji: "πŸ“±", desc: "A small phone you can carry in your pocket." },
            { name: "microwave", emoji: "​​​​​​⏲️", desc: "An oven that heats food very quickly." },
            { name: "oven", emoji: "πŸ₯˜", desc: "A kitchen appliance used for baking and roasting food." },
            { name: "toaster", emoji: "🍞", desc: "A machine that browns bread slices." },
            { name: "sink", emoji: "🚰", desc: "A basin with a faucet for washing hands or dishes." },
            { name: "refrigerator", emoji: "❄️", desc: "A cold closet that keeps food fresh." },
            { name: "book", emoji: "πŸ“–", desc: "A set of pages with writing or pictures to read." },
            { name: "clock", emoji: "⏰", desc: "A device that tells you what time it is." },
            { name: "vase", emoji: "🏺", desc: "A decorative container used for holding flowers." },
            { name: "scissors", emoji: "βœ‚οΈ", desc: "A tool with two blades used for cutting paper." },
            { name: "teddy bear", emoji: "🧸", desc: "A soft toy bear that is cuddly and cute." },
            { name: "hair drier", emoji: "πŸ’¨", desc: "A machine that blows hot air to dry wet hair." },
            { name: "toothbrush", emoji: "πŸͺ₯", desc: "A small brush used to clean your teeth." }
        ];

        // DOM Elements
        const triggerBtn = document.getElementById('dev-trigger-btn');
        const modal = document.getElementById('modal-overlay');
        const closeBtn = document.getElementById('close-btn');
        const tilesContainer = document.getElementById('tiles-container');
        const macosWindow = document.getElementById('macos-window');

        // 1. Populate the Grid
        function renderTiles() {
            tilesContainer.innerHTML = cocoData.map(item => `
                <div class="tile">
                    <div class="tile-icon">${item.emoji}</div>
                    <div class="tile-name">${item.name}</div>
                    <div class="tile-desc">${item.desc}</div>
                </div>
            `).join('');
        }

        // 2. Open Modal Function
        triggerBtn.addEventListener('click', () => {
            renderTiles(); // Render content on open
            modal.classList.add('active'); // Show modal
        });

        // 3. Close Modal Function
        function closeModal() {
            modal.classList.remove('active');
        }

        // Event: Click the Red Dot
        closeBtn.addEventListener('click', closeModal);

        // Event: Click Outside the Window
        modal.addEventListener('click', (e) => {
            // If the user clicks the dark background (modal), close it.
            // If they click INSIDE the window, do nothing.
            if (e.target === modal) {
                closeModal();
            }
        });

    </script>
</body>
</html>