-
Notifications
You must be signed in to change notification settings - Fork 76
/
anim.css
145 lines (140 loc) · 3.34 KB
/
anim.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
html,body{
height: 100%;
min-width: 552px;
}
#shapes {
position: absolute;
/*border: 1px solid black;*/
left: 25vw;
top: 15vh;
width: 685px;
height: 437px;
}
#circle{
position:absolute;
border: 1px solid yellow;
width:250px; /*will go to 400*/
height:250px; /*will go to 400*/
left:40%;
top:4%;/*will come from -82*/
background-color: yellow;
opacity:0.9;
border-radius: 50%;
transition: width 1s,height 1s,z-index ease;
animation-name: forC,zoomC;
animation-delay:0s,2s;
animation-iteration-count: 1,2;
animation-direction: normal,alternate;
animation-duration: 2s,1s;
animation-timing-function: ease;
z-index:0;
}
#circle:hover{
width:350px;
height:350px;
z-index: 4;
}
@keyframes forC{
from {top: -82%;transform:rotateY(0deg)}
to {top: 4%;transform:rotateY(360deg)}
}
@keyframes zoomC {
from {width:250px;height:250px;z-index:4;transform:rotateX(0deg)}
to {width: 350px;height:350px;z-index:4;transform: rotateX(360deg)}
}
#triangle{
position:absolute;
border: 130px solid;
border-top-width: 0;
border-color: transparent transparent black transparent;
width:0;
height:0;
top:40%; /*from 130*/
left:41%; /*from 130*/
opacity:0.5;
z-index:1;
animation-name: forT,zoomT;
animation-delay: 0s,4s;
animation-duration: 2s,1s;
-moz-animation-iteration-count: 1,2;
animation-direction: normal,alternate;
animation-timing-function: ease;
transition: border 1s,border-top-width 1s,border-color 1s,z-index,opacity 1s ease;
}
#triangle:hover{
border: 200px solid;
border-top-width:0px ;
border-color: transparent transparent black transparent;
z-index: 4;
opacity: 0.9;
}
@keyframes forT {
from {top:130%;left:130%;transform: rotate(0deg)}
to{top:40%;left:41%;transform: rotate(360deg)}
}
@keyframes zoomT {
from{
border: 130px solid;
border-top-width: 0;
border-color: transparent transparent black transparent;
z-index: 4;
opacity:0.9;
transform:rotateY(0deg);
}
to{
border: 200px solid;
border-top-width: 0;
border-color: transparent transparent black transparent;
z-index: 4;
opacity:0.9;
transform:rotateY(360deg)
}
}
#square{
position:absolute;
background-color: red;
opacity:0.5;
width:250px;
height:250px;
left:160px;/*will come from -600*/
top:130px;/*will come from 640*/
animation-name: forS,zoomS;
animation-delay: 0s,6s;
animation-duration: 2s,1s;
-moz-animation-iteration-count: 1,2;
animation-direction: normal,alternate;
animation-timing-function: ease;
z-index: 2;
transition: width 1s,height 1s,z-index,opacity 1s ease;
}
#square:hover{
width:320px;
height:320px;
z-index:4;
opacity:0.9;
}
@keyframes forS {
from{left: -600px; top: 640px;transform: rotate(0deg)}
to{left: 160px;top:130px; transform: rotate(360deg);}
}
@keyframes zoomS {
from{
width:250px;
height:250px;
z-index: 4;
opacity:0.9;
transform:rotateX(0deg);
}
to{
width:320px;
height:320px;
z-index: 4;
opacity:0.9;
transform:rotateX(360deg)
}
}
@media only screen and (max-width:777px){
#shapes{
left:1vw;
}
}