-
Notifications
You must be signed in to change notification settings - Fork 0
/
style.css
441 lines (383 loc) · 7.11 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
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
:root {
--sizing: 0px;
--progress: 0%;
}
.element > *::selection,
#scoresheet *::selection,
#start-menu *::selection {
color: none;
background-color: transparent;
}
*,
::after,
::before {
box-sizing: border-box;
margin: 0;
padding: 0;
}
body {
padding-right: 1vw;
padding-left: 1vw;
background-color: #192e2e;
color: #dee6ed;
font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", sans-serif;
display: flex;
flex-direction: column;
}
#start-menu {
width: 100vw;
height: 100vh;
position: fixed;
left: 50%;
top: 50%;
transform: translate(-50%, -50%);
z-index: 1;
display: flex;
flex-direction: column;
justify-content: center;
gap: 1.5vw;
align-items: center;
background-color: #192e2ef8;
}
#lang-mode {
text-transform: uppercase;
border: none;
padding: 0.8vw 0;
font-size: 1.6vw;
font-weight: 700;
width: 12vw;
mix-blend-mode: lighten;
color: #192e2e;
opacity: 0.8;
cursor: pointer;
}
.french {
background: linear-gradient(
to right,
blue 33%,
white 33%,
white 66%,
red 66%
);
}
.english {
background-image: linear-gradient(0deg, #3c3b6e, #3c3b6e),
repeating-linear-gradient(
180deg,
#b22234,
#b22234 7.7%,
white 7.7%,
white 15.4%
);
background-size: 40% 53.85%, 100% 100%;
background-repeat: no-repeat;
background-position: top left;
}
.title {
font-size: 8vw;
}
.intro {
font-size: 2vw;
}
.description {
font-size: 2vw;
}
.title,
.description,
.intro {
display: grid;
place-content: center;
padding: 1vw;
text-transform: uppercase;
}
#table {
max-width: 100%;
margin: 0 auto;
display: grid;
grid-template-columns: repeat(18, auto);
gap: 0.2vw;
padding: 1.5vh 0;
}
.cell-2 {
grid-column-start: -2;
}
#element-summary {
visibility: visible;
grid-column: span 10;
grid-row: span 2;
max-width: 51.8vw;
max-height: 10vw;
color: #dee6ed;
font-weight: 300;
font-size: 1.2vw;
line-height: 1.6;
padding: 0 0.1rem;
}
.cell-58,
.cell-90 {
grid-column-start: 3;
}
.element,
.fake-element {
width: 5vw;
aspect-ratio: 1;
border: solid 1px #dee6ed;
padding: 0.2rem;
color: #dee6ed;
background: transparent;
display: flex;
flex-direction: column;
justify-content: space-between;
align-items: center;
}
.elm-hover:hover,
.elm-hover:focus,
#hint-btn:hover,
#hint-btn:focus,
.link:hover,
.link:focus,
#reset-bnt:hover,
#reset-btn:focus {
background-color: #dc143c;
cursor: pointer;
}
.fake-element:hover,
.fake-element:focus {
animation: flash 0.1s ease-in 1 backwards;
}
.fake-element {
width: 12vw;
opacity: 1;
animation: flash 2s ease-in-out 20 alternate;
text-transform: uppercase;
}
.fake-element .name {
font-size: 1.2vw;
text-transform: uppercase;
}
.fake-element .symbol {
font-size: 2.5vw;
}
.fake-element .number {
font-size: 1.5vw;
}
.element .name {
font-size: 0.55vw;
visibility: hidden;
}
.element .show-name {
visibility: visible;
text-transform: uppercase;
}
.element .symbol {
font-size: 1.4vw;
}
.element .number {
font-size: 0.8vw;
}
#close-dialog {
position: absolute;
left: 0;
top: 0;
background: none;
border: none;
color: #dee6ed;
padding: 10px;
cursor: pointer;
font-size: 10px;
}
.dialog-style {
position: fixed;
top: 40%;
left: 50%;
transform: translate(-50%, -50%);
z-index: 1;
padding: 2rem;
margin: auto;
background-color: #192e2e;
width: 35%;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
gap: 2rem;
border-radius: 6px;
border: #dc143c70 1px solid;
outline: #192e2eaa 100vw solid;
}
.wrong-enter {
box-shadow: 0px 0px var(--sizing) var(--sizing) #dc143c inset;
}
#form {
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
text-align: center;
gap: 2rem;
}
#input {
max-width: 30ch;
text-align: center;
text-transform: capitalize;
font-size: 1.2vw;
}
#input::placeholder {
opacity: 0.5;
}
#input:focus {
border: none;
outline: none;
}
#hint-btn {
font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", sans-serif;
font-weight: 200;
font-size: 1vw;
border: #dee6ed 1px solid;
padding: 0.2em 0.4em;
background-color: #dc143c;
color: #dee6ed;
cursor: pointer;
text-transform: uppercase;
}
.good-answer {
background-color: #65961c;
transition: background-color 0.5s ease-out;
cursor: grab;
}
.block-background {
pointer-events: none;
cursor: none;
}
#scoresheet {
text-align: center;
margin-right: 3vw;
padding: 0.5vw 0;
font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
Oxygen, Ubuntu, Cantarell, "Open Sans", "Helvetica Neue", sans-serif;
font-size: 4.5vw;
font-weight: 900;
display: flex;
align-items: center;
justify-content: flex-end;
gap: 0.3em;
cursor: default;
}
.subcontainer {
display: flex;
flex-direction: column-reverse;
gap: 0.5vw;
}
#hints,
#ratio {
font-size: 1vw;
opacity: 0.5;
text-transform: uppercase;
}
#reset-btn,
#reveal-btn {
padding: 0.5em 0;
max-width: 18ch;
text-align: center;
text-transform: uppercase;
background-color: #dc143c;
color: #dee6ed;
border: none;
cursor: pointer;
font-size: 0.8vw;
font-weight: 100;
}
#reveal-btn {
background-color: #65961c;
}
footer {
color: #dee6ed;
font-size: 1.4svh;
position: fixed;
inset: auto 1px 1px;
background: #65961c;
background: linear-gradient(
90deg,
#65961c var(--progress),
#65961c00 var(--progress),
#65961c00 100%
);
}
#reminder {
z-index: -1;
font-size: 2.5vw;
text-transform: capitalize;
color: #65961c;
position: absolute;
top: 5%;
left: 25%;
transform: translateX(-50%);
animation: flash 3s ease-in-out 10 backwards;
}
.link {
color: #65961c;
mix-blend-mode: color-dodge;
text-decoration: none;
}
.hide {
display: none;
}
@keyframes flash {
from {
opacity: 0;
}
to {
opacity: 1;
}
}
/* Existing CSS Code */
/* Responsive Media Query Starts */
@media (max-width: 768px) {
/* Start Menu */
#start-menu {
gap: 10px; /* Reduced gap */
}
/* Lang mode */
#lang-mode {
font-size: 5px; /* Changed from vw */
padding: 10px 0;
}
/* Text Elements */
.title {
font-size: 2.5em; /* Changed from vw */
}
.intro, .description {
font-size: 1em; /* Changed from vw */
}
/* Grid Layout */
.fake-element .symbol, .fake-element .number,
.element .name, .element .symbol, .element .number {
font-size: 4px; /* Changed from vw */
}
.element .name {
display: hidden !important;
}
/* Buttons */
#hint-btn, #reset-btn, #reveal-btn {
font-size: 7px; /* Changed from vw */
}
/* Scoresheet */
#scoresheet {
font-size: 2em; /* Changed from vw */
}
#hints, #ratio {
font-size: 12px; /* Changed from vw */
}
/* Footer */
footer {
font-size: 14px; /* Changed from svh */
}
/* Reminder */
#reminder {
font-size: 1em;
mix-blend-mode: difference;
}
}
/* Responsive Media Query Ends */