-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathstyle.css
82 lines (72 loc) · 1.31 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
@import url('https://fonts.googleapis.com/css2?family=Iceland&display=swap');
body{
margin: 0;
padding: 0;
height: 100vh;
display: flex;
align-items: center;
justify-content: center;
background: #8ed2ffdc;
}
.pic{
width: 950px;
height: 300px;
background: url(pic.jpg) no-repeat transparent;
background-size: cover;
cursor: pointer;
position: relative;
overflow: hidden;
display: flex;
}
.pic::before{
content: "";
position: absolute;
width: 100%;
height: 100%;
background: url(pic.jpg) no-repeat;
background-size: cover;
filter: sepia(50%);
opacity: 0;
display: flex;
opacity: .5;
animation: glitch 1.0s infinite linear;
}
.pic:hover:before{
opacity: .4;
animation: glitch .8s infinite linear;
}
.text{
position: absolute;
align-content: center;
justify-content: center;
font-size: 60px;
font-family: 'Iceland', cursive;
margin-top: 35%;
color: rgb(0, 5, 75);
}
@keyframes glitch {
0%{
top: 0;
background-position: 12px 0;
}
20%{
top: 80px;
background-position: -10px -80px;
}
40%{
top: 160px;
background-position: 6px -160px;
}
60%{
top: 240px;
background-position: -6px -240px;
}
80%{
top: 320px;
background-position: 10px -320px;
}
100%{
top: 400px;
background-position: -12px -400px;
}
}