forked from Anuragcoderealy/Codenewhacktober
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathimagehover.css
48 lines (44 loc) · 904 Bytes
/
imagehover.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
body{
background-color: #131313;
margin: 0;
height: 100vh;
display: flex;
justify-content: center;
align-items: center;
}
.wrapper{
display: flex;
gap: 60px;
}
.img-container{
width: 250px;
height: 350px;
display: flex;
justify-content: center;
position: relative;
filter: grayscale(100%);
background-color: #363636;
transition: all 0.3s;
}
.img-container img{
height: 90%;
position: absolute;
bottom: 0;
transform-origin: bottom;
transition: transform 0.3s;
}
.img-container:hover img{
transform: scale(1.4);
}
.img-container:hover {
filter: grayscale(0);
}
.img-container:first-child:hover{
background-color: #f6b911;
}
.img-container:nth-child(2):hover{
background-color: #b0b1b4;
}
.img-container:last-child:hover{
background-color: #355cb1;
}