This repository has been archived by the owner on May 28, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathstyle.css
385 lines (325 loc) · 6.46 KB
/
style.css
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
/* Courier prime font import */
@import url("https://fonts.googleapis.com/css2?family=Courier+Prime&display=swap");
/* Roboto Condensed font import */
@import url("https://fonts.googleapis.com/css2?family=Roboto+Condensed:wght@300&display=swap");
/* VT323 font import */
@import url("https://fonts.googleapis.com/css2?family=VT323&display=swap");
/* Variables */
:root {
--green: #59ff20;
--alt-green: #92ff6d;
--black: black;
--white: white;
--button-border: #404040;
--alt-button-border: #7f7f7f;
--grid-color: #404040;
--alt-grid-color: #595959;
--dead-hover: #252626;
--cell-size: 2vw;
--settings-button-size: 3.5vw;
--settings-text: white;
--settings-time: 1s;
}
/* Misc HTML page stuff */
* {
margin: 0px;
padding: 0px;
background-color: var(--black);
}
@keyframes fadeBodyIn {
from {
opacity: 0;
}
to {
opacity: 1;
}
}
body {
font-size: 62.5%;
animation: fadeBodyIn 1s ease-in;
height: 200vh;
overflow-y: hidden;
overflow-x: hidden;
}
.hide {
display: none;
}
.show {
display: initial;
}
/* Decide on transition timing here */
#pageWrapper {
transition: filter calc(var(--settings-time) * 0.8) ease-in-out;
}
/* Game of life div and game table styling */
#gameOfLife {
position: absolute;
top: 0;
left: 0;
width: 95vw;
height: 100vh;
}
#gameTable {
position: absolute;
left: 5vw;
border-collapse: collapse;
}
#gameTable td {
border: 0.1rem solid var(--grid-color);
width: var(--cell-size);
height: var(--cell-size);
}
#gameTable td:nth-of-type(8n) {
border-right: 0.2rem solid var(--alt-grid-color);
}
#gameTable td:first-of-type {
border-left: 0.2rem solid var(--alt-grid-color);
}
#gameTable tr:nth-of-type(8n) {
border-bottom: 0.2rem solid var(--alt-grid-color);
}
#gameTable tr:first-of-type {
border-top: 0.2rem solid var(--alt-grid-color);
}
/* Button and button div styling */
#buttonWrapper {
position: absolute;
top: 0;
right: 0;
width: 5vw;
height: 25vh;
}
.button {
padding: 0.25vw;
border: 0.2vw solid var(--button-border);
border-radius: 0.5vw;
background-color: var(--green);
color: black;
font-family: "Courier Prime", monospace;
font-size: 1.2vw;
text-align: center;
transition: all 0.15s ease-in;
}
.button:hover {
background-color: var(--alt-green);
border-color: var(--alt-button-border);
}
#settingsButton {
position: absolute;
padding: 0;
top: 1vw;
right: 0.72vw;
width: var(--settings-button-size);
height: var(--settings-button-size);
z-index: 2;
}
#cogImg {
display: block;
margin-left: auto;
margin-right: auto;
width: calc(var(--settings-button-size) * 0.8);
height: calc(var(--settings-button-size) * 0.8);
background-color: transparent;
transition: transform 0.75s ease-in-out 0.1s;
}
#cogImg:hover {
transform: rotate(360deg);
}
#stepButton {
position: relative;
top: 5.5vw;
right: 0.72vw;
float: right;
width: var(--settings-button-size);
height: 2vw;
}
#clearButton {
position: relative;
top: 5.75vw;
right: 0.72vw;
float: right;
clear: right;
width: var(--settings-button-size);
height: 2vw;
}
/* Settings area styling */
#settingsWrapper {
position: absolute;
width: 100%;
height: 100%;
margin-left: auto;
margin-right: auto;
transition: all var(--settings-time) ease-out;
}
#settingsWrapper.open {
background-color: rgba(50, 50, 50, 0.3);
top: 0;
right: 0;
}
#settingsWrapper.closed {
background-color: rgba(50, 50, 50, 0);
opacity: 0;
width: 0;
height: 0;
top: 0;
right: 0;
}
#optionsContainer {
height: 60%;
margin-top: 1vw;
margin-right: 8%;
margin-left: 6%;
border: 0.3vw solid var(--button-border);
border-radius: 0.5vw;
background-color: rgba(100, 100, 100, 0.3);
}
#settingsWrapper form {
position: relative;
width: 30%;
height: 100%;
font-family: "Roboto Condensed", sans-serif;
background-color: transparent;
}
#settingsWrapper h1,
p {
text-align: center;
background-color: transparent;
}
#settingsWrapper h1 {
font-size: 3vw;
margin-bottom: 2vw;
margin-top: 2vw;
}
#sizeAdjust {
float: left;
left: 2.5%;
}
#autoStep {
float: left;
left: 5%;
}
#seedOptions {
float: left;
left: 7.5%;
}
#settingsWrapper input,
label {
float: left;
margin-right: 25%;
margin-left: 10%;
}
#settingsWrapper label,
p {
font-size: 1.6vw;
background-color: transparent;
}
#settingsWrapper input {
margin-top: 1%;
margin-bottom: 3%;
width: 12vw;
}
#settingsWrapper input[type="text"] {
width: 6vw;
height: 2vw;
padding-left: 0.25vw;
padding-right: 0.25vw;
padding-top: 0.4vw;
padding-bottom: 0.1vw;
text-indent: 0.5vw;
border: 0.2vw solid var(--button-border);
border-radius: 0.5vw;
background-color: var(--green);
font-size: 1.5vw;
font-family: "Courier Prime", monospace;
color: black;
transition: all 0.15s ease-in;
}
#settingsWrapper input[type="text"]:hover {
background-color: var(--alt-green);
border-color: var(--alt-button-border);
}
.blur {
filter: blur(6px);
}
/* Credits area and game title styling */
#personalCredits {
position: absolute;
width: 5vw;
height: 75vh;
bottom: 0;
right: 0;
}
#personalCredits span,
p {
padding-top: 1vh;
background-color: transparent;
}
#personalCredits span {
font-family: "VT323", monospace;
color: var(--green);
font-size: 2vw;
line-height: 3vh;
width: 1vw;
float: left;
word-break: break-all;
padding-bottom: 5vh;
}
span.left {
padding-left: 1.25vw;
padding-right: 0.5vw;
}
#personalCredits p,
a {
text-align: center;
display: block;
font-family: "Courier Prime", monospace;
font-size: 0.6vw;
color: white;
}
#personalCredits a {
position: absolute;
width: 5vw;
top: 33vh;
text-decoration: none;
transition: all 0.15s ease-in-out;
}
#personalCredits a:hover {
text-decoration: underline;
color: var(--green);
}
#gameName {
position: absolute;
width: 5vw;
height: 100vh;
top: 0;
left: 0;
text-align: center;
}
#gameName span {
font-family: "VT323", monospace;
color: var(--green);
font-size: 6.8vw;
line-height: 4.2vw;
width: 2vw;
margin-top: 1vw;
margin-left: 1.2vw;
float: left;
background-color: transparent;
word-break: break-all;
padding-bottom: 1vw;
}
/* Game of life cell styling */
.dead {
background-color: var(--black);
transition: background-color 0.1s ease-out;
}
.dead:hover {
background-color: var(--dead-hover);
}
.alive {
background-color: var(--green);
transition: background-color 0.1s ease-out;
}
.alive:hover {
background-color: var(--alt-green);
}