-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathCSS-bg-text-img-clip.html
45 lines (43 loc) · 1.19 KB
/
CSS-bg-text-img-clip.html
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
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Background Image in a Text</title>
<link href="https://fonts.googleapis.com/css2?family=Bangers&display=swap" rel="stylesheet">
<style>
*{
margin: 0;
padding: 0;
box-sizing: border-box;
font-family: 'Bangers', cursive;
}
.text{
width: 100vw;
height: 100vh;
display: grid;
place-items: center;
font-size: 2rem;
background-color: rgb(103, 168, 230);
}
h1{
color: transparent;
background-image: url(img/crowd.jpg);
background-size:100% 100%;
background-clip: text;
-webkit-background-clip: text;
-moz-background-clip: text;
}
h1:hover{
filter: drop-shadow(2px 3px 2px yellow);
transform: scale(1.5);
/* transform: rotate(45deg); */
}
</style>
</head>
<body>
<div class="text">
<h1>Rakib Rahman</h1>
</div>
</body>
</html>