-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
152 lines (137 loc) · 3.66 KB
/
index.html
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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>THC as in Treasure Hunt Challenge</title>
<style>
* {
box-sizing: border-box;
}
body {
--border: calc(1vmin / 4);
--sine-ease: cubic-bezier(0.37, 0, 0.63, 1);
--dur: 4s;
--size: 40vmin;
--gap: 4vmin;
background-color: #fcecc9;
margin: 0;
min-height: 100vh;
display: flex;
align-items: center;
justify-content: center;
transform: translate3d(0, 0, 0);
overflow: hidden;
}
.grid div {
text-align: center;
}
.grid {
position: relative;
display: grid;
grid-template:
"c y" auto
"x b" auto
/ auto auto;
gap: var(--gap);
animation: var(--dur) var(--sine-ease) calc(-0.5 * var(--dur)) infinite
alternate x,
var(--dur) var(--sine-ease) infinite alternate y,
calc(var(--dur) * 2) linear infinite rot;
}
.xy-wave {
grid-area: b;
left: 0;
background-blend-mode: color-burn;
background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 2 1' preserveAspectRatio='none'><path fill='rgb(249, 57, 67)' d='M 0 1 C .37 1, .63 0, 1 0 C 1.37 0, 1.63 1, 2 1 Z'></path></svg>"),
url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 2 1' preserveAspectRatio='none'><path fill='rgb(126, 178, 221)' d='M 0 1 C .37 1, .63 0, 1 0 C 1.37 0, 1.63 1, 2 1 Z'></path></svg>");
background-size: 200% 100%;
background-repeat: repeat-x;
background-position: center left calc(var(--rot) * 2 * var(--size)),
center left calc(var(--size) * 0.5 + (var(--rot) * 2 * var(--size)));
border-radius: calc(var(--size) * 0.125);
}
.x-wave,
.y-wave,
.xy-wave {
position: relative;
width: var(--size);
height: var(--size);
}
.circle,
.x-bar,
.y-bar {
position: relative;
&:before {
content: "";
position: absolute;
top: var(--top);
left: var(--left);
height: calc(var(--size) / 32);
width: calc(var(--size) / 32);
background-color: #fcecc9;
border: var(--border) solid var(--color);
border-radius: 50%;
transform: translate(-50%, -50%);
z-index: 1;
}
&:after {
content: "";
position: absolute;
}
}
.x-bar,
.y-bar {
--length: calc(var(--gap) + ((1 - var(--dim)) * var(--size)));
--width: var(--border);
&:after {
background-color: var(--color);
}
}
@keyframes x {
from {
--x: 0;
}
to {
--x: 1;
}
}
@keyframes y {
from {
--y: 0;
}
to {
--y: 1;
}
}
@keyframes rot {
from {
--rot: 0;
}
to {
--rot: 1;
}
}
@property --x {
syntax: "<number>";
inherits: true;
initial-value: 0.5;
}
@property --y {
syntax: "<number>";
inherits: true;
initial-value: 0;
}
@property --rot {
syntax: "<number>";
inherits: true;
initial-value: 0;
}
</style>
</head>
<body>
<div class="grid">
<div class="xy-wave">We're setting up.<br />Check back soon.</div>
</div>
</body>
</html>