-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathstyle.css
More file actions
183 lines (160 loc) · 3.11 KB
/
Copy pathstyle.css
File metadata and controls
183 lines (160 loc) · 3.11 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
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
* {
margin: 0;
padding: 0;
box-sizing: border-box;
font-family: "Segoe UI", Tahoma, sans-serif;
}
body {
min-height: 100vh;
display: flex;
justify-content: center;
align-items: center;
/* Sky + grass background */
background: linear-gradient(
to bottom,
#5da9ff 0%,
#87cefa 45%,
#6bbf59 46%,
#4fa34a 100%
);
}
/* MAIN WRAPPER */
#wrapper {
width: 900px;
height: 600px;
position: relative;
}
/* LAYERS */
.layer {
position: absolute;
inset: 0;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
}
.hidden {
display: none;
}
/* MENU */
#menu-layer h1 {
font-size: 3rem;
color: #2d2d2d;
margin-bottom: 20px;
text-shadow: 2px 2px #ffffffaa;
}
#question {
font-size: 1.2rem;
margin-bottom: 10px;
}
#name-field {
padding: 10px 15px;
font-size: 1rem;
border-radius: 8px;
border: 2px solid #aaa;
margin-bottom: 15px;
width: 220px;
}
button {
padding: 12px 20px;
font-size: 1rem;
border-radius: 10px;
border: none;
cursor: pointer;
background: #ffcc00;
box-shadow: 0 4px #d4a800;
transition: transform 0.1s, box-shadow 0.1s;
}
button:hover {
transform: translateY(-2px);
box-shadow: 0 6px #d4a800;
}
button:active {
transform: translateY(2px);
box-shadow: 0 2px #d4a800;
}
/* GAME HUD */
.score {
position: absolute;
top: 15px;
font-size: 2.5rem;
font-weight: bold;
color: #222;
}
.countdown {
position: absolute;
top: 20px;
right: 20px;
font-size: 1.4rem;
font-weight: bold;
}
/* GAME GRID */
.game {
display: grid;
grid-template-columns: repeat(3, 1fr);
gap: 50px;
margin-top: 100px;
}
/* HOLES */
.hole {
width: 180px;
height: 140px;
position: relative;
overflow: hidden;
}
.hole:after{
background: #8b5a2b;
border-radius: 40px;
box-shadow: inset 0 10px #6e451f;
height: 50%;
width: 100%;
z-index: -1;
background-size: contain;
position: absolute;
content: "";
bottom: 0;
}
/* CAT */
.cat {
width: 100px;
height: 120px;
background-image: url("./cannyCat.png");
background-size: cover;
position: absolute;
left: 50%;
transform: translateX(-50%);
bottom: -120px;
transition: bottom 0.4s ease;
cursor: pointer;
}
.hole.up .cat {
bottom: 10px;
}
/* GAME OVER */
#game-over-layer .container {
background: #ffffffdd;
padding: 30px 40px;
border-radius: 20px;
text-align: center;
box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
}
#game-over-layer h1 {
margin-bottom: 15px;
}
.yourscore {
font-size: 1.4rem;
margin-bottom: 20px;
}
/* SCOREBOARD */
#scoreboard {
display: grid;
grid-template-columns: 1fr 1fr;
margin-top: 20px;
gap: 10px;
}
.column {
background: #f3f3f3;
padding: 10px;
border-radius: 10px;
min-height: 150px;
}