CSS Product Card Hover Effect.Today in this blog , we gonna learn about CSS Product Card Hover Effect.
CSS Product Card Hover Effect
Hi Friends!
Today in this blog, we gonna learn about the CSS Product Card Hover Effect. Product Cards Hover Effects are best attractive and clickable part of the e-commerce website. I already uploaded the Product Card UI Design. if you're a beginner let's go and learn it.
This Product Card Hover Effect is nice to see on e-commerce websites. In the previous blog, we will learn about CSS Custom Glowing Button Effect if you're a beginner I will recommend learning that button effect first. If you learn that and this blog will help you to learn about Product Card Hover Effect. In this blog, I will give my video tutorial and source codes to download. if you have any doubts ask me in the comment section.
HTML file
[
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>css product card hover effect</title>
<link rel="stylesheet" type="text/css" href="index.css">
</head>
<body>
<div class="card">
<h1>Sport Shoe</h1>
<img src="shoe.png">
<div class="content">
<h3>Sizes</h3>
<div class="sizes">
<span>25</span>
<span>26</span>
<span>27</span>
<span>28</span>
</div>
<h2>$70.<small>99</small></h2>
</div>
<a href="#">Buy now</a>
</div>
</body>
</html>
]
You can copy this HTML file. and paste it into your HTML file. Now you will learn it clearly. and don't forget to save the file with an extension. HTML. This extension is more important for creating a website page.
CSS file
[
*{
margin: 0;
padding: 0;
box-sizing: border-box;
}
body{
display: flex;
justify-content: center;
align-items: center;
height: 100vh;
width: 100%;
background-color: #262626FF;
}
.card{
display: flex;
justify-content: space-around;
align-items: center;
position: relative;
height: 300px;
width: 500px;
font-size: 20px;
font-weight: bold;
font-family: sans-serif;
color: white;
box-shadow: 1px 1px 60px black;
border-radius: 10px;
cursor: pointer;
overflow: hidden;
}
img{
position: relative;
transition: 1s;
height: 250px;
width: 250px;
}
h1{
position: absolute;
top: 5%;
left: 5%;
}
.content{
display: flex;
flex-direction: column;
position: relative;
bottom: 10%;
text-align: center;
}
.sizes{
display: flex;
justify-content: space-around;
align-items: center;
}
.sizes span{
display: block;
background-color: white;
color: black;
padding: 3px;
margin: 10px;
}
.content h2{
position: relative;
margin-top: 30px;
}
a{
display: block;
position: absolute;
bottom: 3%;
right: 3%;
text-decoration: none;
padding: 5px 10px;
color: white;
border: 2px solid white;
}
.card::after{
content: '';
display: block;
position: absolute;
bottom: 80%;
left: 80%;
height: 200px;
width: 200px;
background-color: #1D4DE1FF;
transition: 0.5s;
filter: blur(5px);
border-radius: 50%;
box-shadow: 1px 1px 60px royalblue;
z-index: -1;
}
div:hover::after{
transition: 1s;
bottom: 0;
left: 0;
height: 100%;
width: 100%;
border-radius: 0;
}
img:hover{
transform: translateY(-20px);
}
.sizes span:hover{
transition: 0.5s;
background-color: transparent;
color: white;
}
a:hover{
background-color: white;
color: black;
}
]
Secondly, you can copy this CSS file. and paste it into your CSS file. and remember the file extension called. CSS. This will help you to design your webpage. If you want more clarity on this topic you can watch my video tutorial and If you have any doubts ask me in the comment section.
Video Tutorial
Watch this video fully and learn the all Product Card Hover Effects for developing your e-commerce websites. repeat the code for your practice this will help you to learn this Product Card Hover Effect more effectively and This video is also helpful to learn faster. colourful Product Card Hover Effects are an important part of e-commerce websites. I hope this tutorial will be helpful for learning the Product Card Hover Effect. I will give you Source Code and you can download it.
COMMENTS