<div class="container">
<input placeholder='Search...' class='js-search' type="text">
<i class="fa fa-search"></i>
</div>
<div class="social">
<a href="https://twitter.com/StefCharle" target="_blank">
<img src="https://s3-us-west-2.amazonaws.com/s.cdpn.io/149103/twitter.svg" alt="">
</a>
</div>
*{ box-sizing: border-box; }
body{
position: relative;
width: 100vw;
height: 100vh;
background: linear-gradient(to bottom right, #274B74 0%, #8233C5 50%, #E963FD 100%);
font-family: "Montserrat", sans-serif;
overflow: hidden;
}
.container{
width: 100%;
height: 100%;
display: flex;
justify-content: center;
align-items: center;
}
input[type=text]{
position: relative;
padding: 15px 40px 15px 20px;
width: 20px;
color: #525252;
text-transform: uppercase;
font-size: 16px;
font-weight: 100;
letter-spacing: 2px;
border: none;
border-radius: 5px;
background: linear-gradient(to right, #FFFFFF 0%,#464747 #F9F9F9 100%);
transition: width 0.4s ease;
outline: none;
&:focus{ width: 300px; }
}
i{
position: relative;
left: -37px;
color: #8233C5;
}
.social{
position: absolute;
right: 35px;
bottom: 35px;
img{
display: block;
width: 32px;
}
}
View Compiled
This Pen doesn't use any external JavaScript resources.