Hello guys in this article we will create a simple animated Vodafone logo using html css.
Vodafone Logo Using HTML & CSS step by step guide
Step 1 — Creating a New Project
In this step, we need to create a new project folder and files(index.html, style.css) for creating Vodafone Logo. In the next step, you will start creating the structure of the webpage.
Step 2 — Setting Up the basic structure
In this step, we will add the HTML code to create the basic structure of the project.
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Vodafone logo HTML CSS</title>
<link rel="stylesheet" type="text/css" href="style.css">
</head>
<body>
</body>
</html>This is the base structure of most web pages that use HTML.
Add the following code inside the <body> tag:
<div class="logo_outer"> <div class="vodafone"> </div> </div>
Step 3 — Adding Styles for the Classes
In this step, we will add styles to the section class Inside style.css file
*{
margin: 0;
padding: 0;
--width: 100px;
--height: 100px;
}
body {
background: #f00;
height: 100vh;
width: 100vw;
display: flex;
align-items: center;
justify-content: center;
}
.logo_outer {
display: flex;
align-items: center;
justify-content: center;
width: var(--width);
height: var(--height);
background: #fff;
border-radius: 50%;
overflow: hidden;
position: relative;
animation: animate 2s linear forwards;
}
@keyframes animate {
from {
transform: rotate(0deg) scale(0);
}
to {
transform: rotate(360deg) scale(1);
}
}
.vodafone {
width: calc(var(--width) - 50px);
height: calc(var(--height) - 50px);
display: block;
background: #f00;
border-radius: 50%;
}
.vodafone:before, .vodafone:after {
content: "";
z-index: 0;
position: absolute;
background: #f00;
width: calc(var(--width) - 50px);
height: calc(var(--height) - 50px);
top: 5px;
left: 25px;
border-radius: 100% 8% 20%;
}
.vodafone:after {
width: 45px;
height: 45px;
background: rgba(51, 51, 51, 0.5);
background: #fff;
margin-left: 28px;
border-radius: 100%;
margin-top: 0px;
}
.logo_outer:before {
content: "";
display: block;
width: 50px;
height: 50px;
position: absolute;
background: #f00;
z-index: 9;
border-radius: 50%;
}

