-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathstyle.css
131 lines (111 loc) · 2.6 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
* {margin: 0px; padding: 0px; box-sizing: border-box;}
html, body{
width: 100%;
height: 100%;
}
.container{
width: 260px;
height: 213px;
position: relative;
left: 30%;
top: 30%;
transition: translate(-50%, -50%);
/* background-color: grey; */
perspective: 600px;
}
.butterfly{
width: 100%;
height: 100%;
position: absolute;
transform-style: preserve-3d;
transform: rotate3d(2,1,-1, 45deg);
}
.f-part{
position: absolute;
background-size: 100% 100%;
}
.butterfly .body{
width: 26%;
height: 80%;
left: 50%;
transform: translateX(-50%);
bottom: 15%;
background-image: url('body.png');
}
.butterfly .l-wing{
width: calc(50% - 4px);
height: 100%;
left: 0px;
animation: lwingAnimate 5s ease-in-out infinite;
transform-origin: right;
background-image: url('l-wing.png');
}
.butterfly .r-wing{
width: calc(50% - 4px);
height: 100%;
right: 0px;
animation: rwingAnimate 5s ease-in-out infinite;
transform-origin: left;
background-image: url('r-wing.png');
}
@keyframes lwingAnimate {
0% { transform: rotate3d(0,1,0, 80deg);}
50% {transform: rotate3d(0,1,0, 20deg);}
100% {transform: rotate3d(0,1,0, 80deg);}
}
@keyframes rwingAnimate {
0% { transform: rotate3d(0,1,0, -80deg);}
50% {transform: rotate3d(0,1,0, -20deg);}
100% {transform: rotate3d(0,1,0, -80deg);}
}
.shadow-left{
width: 100%;
height: 100%;
position: absolute;
transform: translateX(-5%);
transform: rotate(-30deg);
}
.l-shadow{
width: 40%;
height: 80%;
left: 8%;
/* transform: translateX(-5%);
transform: rotate(-30deg); */
bottom: 8%;
background-image: url('l-wing-shadow.png');
animation: lwingShadowAnimate 5s ease-in-out infinite;
transform-origin: right;
filter: blur(4px);
opacity: 0.7;
}
@keyframes lwingShadowAnimate {
0% { transform: scaleX(0.08);}
20% { transform: scaleX(0.5);}
45% {transform: scaleX(1.2);}
100% {transform: scaleX(0.08);}
}
.shadow-right{
width: 100%;
height: 100%;
position: absolute;
transform: translateY(0%);
transform: rotate(-35deg);
/* perspective: 100px; */
}
.r-shadow{
width: 40%;
height: 70%;
left: 45%;
bottom: -1%;
background-image: url('r-wing-shadow.png');
animation: rwingShadowAnimate 5s ease-in-out infinite;
transform-origin: left;
filter: blur(4px);
opacity: 0.7;
}
@keyframes rwingShadowAnimate {
0% { transform: scale(0.75);}
25% { transform: scale(1);}
45% {transform: scale(1.2);}
100% {transform: scale(0.75);}
}