-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathstyle.css
70 lines (60 loc) · 1.18 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
@import url('https://fonts.googleapis.com/css?family=Source+Sans+Pro:300,400,600,700,900&display=swap');
* {
margin: 0;
padding: 0;
box-sizing: border-box;
user-select: none;
}
body {
font-family: 'Source Sans Pro', sans-serif;
}
section {
position: relative;
width: 100%;
height: 100vh;
display: flex;
overflow: hidden;
}
section div {
position: relative;
width: 50%;
overflow: hidden;
}
.box-1 {
width: 50%;
background: url(img.jpg);
background-size: cover;
box-sizing: border-box;
}
.box-2 {
background: url(img.jpg);
background-size: cover;
transform: scale(-1, 1);
}
section div h2 {
position: absolute;
white-space: nowrap;
font-size: 12em;
line-height: 100vh;
}
section div:nth-child(1) h2 {
left: 100%;
animation: animat 15s linear infinite;
-webkit-text-stroke: 2px;
-webkit-text-stroke-color: #fff;
-webkit-text-fill-color: transparent;
}
section div:nth-child(2) h2 {
left: 100%;
color: #fff;
animation: animat 15s linear infinite;
}
@keyframes animat
{
0%{
transform: translateX(0);
}
100%{
transform: translateX(-100%);
}
}