-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathapp.css
More file actions
179 lines (178 loc) · 4.01 KB
/
app.css
File metadata and controls
179 lines (178 loc) · 4.01 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
html {
user-select: none;
margin: 0;
padding: 0;
background: #000;
}
body {
margin: 0;
padding: 0;
position: relative;
overflow: hidden;
font-family: sans-serif;
}
#content {
position: absolute;
margin: 0;
padding: 0;
left: 0;
top: 0;
width: 100%;
height: 100%;
}
#loader {
font-size: 9vw;
color: #dcb9d4;
position: absolute;
top: 45vh;
width: 100%;
text-align: center;
filter: drop-shadow(0 0 0.75rem #aa2);
z-index: 5;
transition: opacity 1s linear;
pointer-events: none;
}
#splash {
position: absolute;
width: 100%;
text-align: center;
transition: opacity 1s linear, top 1s cubic-bezier(0.16, 1, 0.3, 1) /* https://easings.net/#easeOutExpo */;
font-family: Georgia;
pointer-events: none;
}
#splash.out {
transition: opacity 2.5s cubic-bezier(0.7, 0, 0.84, 0) /* https://easings.net/#easeInExpo */,
top 2.5s cubic-bezier(0.64, 0, 0.78, 0) /* https://easings.net/#easeInCirc */;
}
#splash span.logo {
font-size: min(12vw, 9.5em); /* To prevent larger title than play area */
color: white;
filter: drop-shadow(0 0 0.9rem #aa2) drop-shadow(0.1em 0.1em 0.2rem #000) drop-shadow(-0.1em 0.1em 0.2rem #444)
drop-shadow(10px 10px 0.3rem rgba(255, 0, 0, 0.3)) drop-shadow(-0.1em -0.1em 0.1rem rgba(40, 202, 25, 0.4))
drop-shadow(0.1em -0.1em 0.1rem rgba(90, 215, 200, 0.4));
}
#splash span.icon {
font-size: 3vw;
color: white;
margin: 2.5vw;
line-height: 2em;
transition: font-size 0.5s linear;
filter: drop-shadow(0 0 0.6rem yellow) drop-shadow(0 0 0.1rem #000);
}
#message {
font-size: 3vw;
color: #ddd;
position: absolute;
top: 45vh;
left: 0;
filter: drop-shadow(0 0 6rem #f66) drop-shadow(0 0 2rem #aa2);
width: 100%;
text-align: center;
background: #1f1f1f;
line-height: 4em;
z-index: 10;
}
#message a,
#message a:visited {
color: #fff;
}
#message button {
line-height: 1.5em;
vertical-align: middle;
font-size: 1.2em;
color: #000;
background: rgb(243 212 0);
border-radius: 1vw;
border: 2px solid #91730dbd;
padding: 0.1em 0.3em;
cursor: pointer;
}
#message button:hover {
background: rgb(255 242 40);
}
canvas {
opacity: 0;
transition: opacity 2.5s linear;
cursor: crosshair;
}
@keyframes health_damage {
0% {
border-color: red;
}
100% {
border-color: f0ff081f;
}
}
#health {
position: fixed;
left: 0.5em;
top: 0.5em;
border: 0.25vh solid #f0ff081f;
border-radius: 0.5vw;
height: 5vh;
transition: opacity 4s linear;
pointer-events: none;
}
#health.damage {
animation-name: health_damage;
animation-duration: 0.30s;
animation-timing-function: linear;
animation-iteration-count: 1;
}
#health span {
border-radius: 0.25vw;
display: block;
/* https://stackoverflow.com/a/63302468/72478
background: linear-gradient(
90deg,
rgba(255, 0, 0, 1) 0%,
rgba(255, 154, 0, 1) 10%,
rgba(208, 222, 33, 1) 20%,
rgba(79, 220, 74, 1) 30%,
rgba(63, 218, 216, 1) 40%,
rgba(47, 201, 226, 1) 50%,
rgba(28, 127, 238, 1) 60%,
rgba(95, 21, 242, 1) 70%,
rgba(186, 12, 248, 1) 80%,
rgba(251, 7, 217, 1) 90%,
rgba(255, 0, 0, 1) 100%
); */
/* https://cssgradient.io/ */
background: rgb(2, 0, 36);
background: linear-gradient(
0deg,
rgb(0, 0, 0) 0%,
rgb(230, 66, 110) 20%,
rgb(238, 147, 79) 80%,
rgb(255, 255, 255) 100%
);
height: calc(100% - 0.5vh);
max-width: calc(100% - 0.5vh);
margin: 0.25vh;
opacity: 0.8;
}
#score {
position: fixed;
right: 0.5em;
top: 0.5em;
transition: opacity 4s linear;
color: #e4ff00aa;
font-size: 5vh;
font-style: italic;
line-height: 0.5em;
filter: drop-shadow(2px 2px 1px #000) drop-shadow(0 0 0.2rem #aa2) drop-shadow(0.1em 0.1em 0.2rem #f00)
drop-shadow(-0.1em -0.1em 0.2rem #44ff4444) drop-shadow(-17px -5px 0.3rem rgba(255, 0, 0, 0.3));
pointer-events: none;
}
#fps {
position: fixed;
right: 0.5em;
bottom: 0.25em;
color: lime;
padding: 0.3em;
text-align: right;
transition: opacity 2s;
filter: drop-shadow(1px 1px 0 rgba(255, 255, 255, 0.5));
pointer-events: none;
opacity: 0.5;
}