Repository navigation
Expand file tree
/
Copy pathflappy.css
More file actions
108 lines (97 loc) · 1.73 KB
/
Copy pathflappy.css
File metadata and controls
108 lines (97 loc) · 1.73 KB
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
body {
margin: 0;
padding: 0;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
height: 100vh;
background-color: #70c5ce;
font-family: Arial, sans-serif;
overflow: hidden;
}
nav ul {
list-style-type: none;
padding: 0;
margin: 0;
background: #333;
display: flex;
justify-content: center;
width: 100%;
position: fixed;
top: 0;
left: 0;
}
nav ul li {
margin: 0 15px;
padding: 10px;
}
nav ul li a {
color: white;
text-decoration: none;
font-size: 18px;
}
#game-container {
position: relative;
width: 400px;
height: 600px;
background-color: #fff;
overflow: hidden;
border: 2px solid #000;
margin-top: 50px;
}
#bird {
position: absolute;
width: 30px;
height: 30px;
background-color: #ff0;
top: 50%;
left: 50px;
transform: translateY(-50%);
}
.pipe {
position: absolute;
width: 50px;
background-color: #4caf50;
bottom: 0;
}
.pipe.upper {
top: 0;
bottom: unset;
}
#score {
position: absolute;
top: 10px;
left: 10px;
font-size: 18px;
color: #000;
z-index: 10;
}
#game-over {
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
text-align: center;
background-color: rgba(255, 255, 255, 0.9);
padding: 20px;
border: 2px solid #000;
border-radius: 10px;
display: flex;
flex-direction: column;
align-items: center;
z-index: 20;
}
.hidden {
display: none;
}
#restart-btn {
margin-top: 10px;
padding: 10px 20px;
font-size: 16px;
cursor: pointer;
border: none;
background-color: #4caf50;
color: white;
border-radius: 5px;
}