-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmain.css
86 lines (76 loc) · 1.52 KB
/
main.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
@import url(https://fonts.googleapis.com/css?family=Raleway:400,800);
figure.photo {
position: relative;
overflow: hidden;
margin: 10px;
width: 280px;
height: 280px;
background: #000000;
color: #ffffff;
text-align: center;
box-shadow: 0 0 5px rgba(0, 0, 0, 0.15);
}
figure.photo * {
-webkit-box-sizing: border-box;
box-sizing: border-box;
-webkit-transition: all 0.4s ease-in-out;
transition: all 0.4s ease-in-out;
}
figure.photo img {
max-width: 150%;
position: relative;
opacity: 0.8;
}
figure.photo figcaption {
position: absolute;
top: 0;
left: 0;
bottom: 0;
right: 0;
}
figure.photo h2 {
position: absolute;
left: 20%;
right: 20%;
display: inline-block;
background: #000000;
padding: 5% 5%;
margin: 0;
top: 40%;
font-weight: normal;
font-size: 20px;
}
figure.photo:before {
height: 100%;
width: 100%;
top: 0;
left: 0;
content: '';
background: #ffffff;
position: absolute;
-webkit-transition: all 0.3s ease-in-out;
transition: all 0.3s ease-in-out;
}
figure.photo a {
left: 0;
right: 0;
top: 0;
bottom: 0;
position: absolute;
z-index: 1;
}
figure.photo:hover img,
figure.photo.hover img {
opacity: 1;
-webkit-transform: scale(1.1);
transform: scale(1.1);
}
figure.photo:hover h2,
figure.photo.hover h2 {
-webkit-transform: translateY(20%);
transform: translateY(20%);
opacity: 0
}
body {
font-family: 'Raleway', Arial, sans-serif;
}