forked from Dezenix/frontend-html-css-js
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathstyle.css
101 lines (86 loc) · 1.65 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
/* ======================== */
/*
Ignore the following styles. They are not important to achieve the effect.
I'm only using them for looks (overall page background/font styles/centering content).
*/
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300&display=swap');
* {
margin: 0;
padding: 0;
box-sizing: border-box;
}
body {
font-family: 'Poppins', sans-serif;
background-color: #090221;
display: grid;
place-content: center;
height: 100vh;
padding: 5px;
color: #fff;
}
/* ======================== */
.scene {
width: 230px;
height: 200px;
background-color: #4695ea;
border-radius: 4px;
position: relative;
overflow: hidden;
}
.scene img {
position: absolute;
}
.city {
bottom: -3px;
width: 100%;
height: 50%;
object-fit: cover;
}
.plane {
top: 50px;
left: -50px;
width: 45%;
animation: plane-move 15s linear forwards;
}
.cloud {
animation: clouds-move 22s linear forwards;
}
.cloud-1 {
width: 70px;
top: 0;
left: 30px;
}
.cloud-2 {
width: 35px;
top: 20px;
left: 125px;
}
.cloud-3 {
width: 45px;
top: 55px;
left: 145px;
}
.boat {
width: 30%;
bottom: 0;
right: -50px;
animation: boat-move 20s linear forwards;
}
@keyframes plane-move {
to {
transform:
translate(300px, -100px);
}
}
@keyframes clouds-move {
to {
transform:
translateX(-25px);
}
}
@keyframes boat-move {
to {
transform:
translateX(-300px);
}
}