Skip to content

Commit 7280bdd

Browse files
committed
instructions
1 parent 5227011 commit 7280bdd

2 files changed

Lines changed: 26 additions & 0 deletions

File tree

cyclists/css/style.css

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,3 +18,27 @@ canvas {
1818
top: 0;
1919
left: 0;
2020
}
21+
22+
#instructions {
23+
position: absolute;
24+
bottom: 25vh; /* ✅ Start at the bottom third of the screen */
25+
left: 50%;
26+
transform: translateX(-50%);
27+
color: white;
28+
font-weight: bold;
29+
padding: 10px 20px;
30+
border-radius: 5px;
31+
font-size: 24px;
32+
font-family: sans-serif;
33+
text-align: center;
34+
opacity: 1;
35+
animation: descendOut 15s ease-in-out 1s forwards; /* ✅ Waits 5s, then moves down over 10s */
36+
z-index: 1;
37+
}
38+
39+
@keyframes descendOut {
40+
to {
41+
opacity: 0;
42+
transform: translateX(-50%) translateY(200px); /* ✅ Moves down slowly */
43+
}
44+
}

cyclists/index.html

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,5 +28,7 @@
2828
<script src="js/cyclists.js" defer></script>
2929
</head>
3030
<body>
31+
<div id="instructions">Tap cyclists and save the forest.</div>
32+
</body>
3133
</body>
3234
</html>

0 commit comments

Comments
 (0)