<div class="container page-wrapper">
<div class="page-inner">
<div class="row">
<div class="el-wrapper">
<div class="box-up">
<img class="img" src="http://code.slicecrowd.com/labs/4/images/t-shirt.png" alt="">
<div class="img-info">
<div class="info-inner">
<span class="p-name">I feel like Pablo</span>
<span class="p-company">Yeezy</span>
</div>
<div class="a-size">Available sizes : <span class="size">S , M , L , XL</span></div>
</div>
</div>
<div class="box-down">
<div class="h-bg">
<div class="h-bg-inner"></div>
</div>
<a class="cart" href="#">
<span class="price">$120</span>
<span class="add-to-cart">
<span class="txt">Add in cart</span>
</span>
</a>
</div>
</div>
</div>
</div>
</div>
body,
html {
height: 100%;
}
.d-flex {
display: box;
display: flexbox;
display: flex;
}
.align-center {
box-align: center;
flex-align: center;
align-items: center;
}
.flex-centerY-centerX {
justify-content: center;
box-pack: center;
flex-pack: center;
justify-content: center;
box-align: center;
flex-align: center;
align-items: center;
}
body {
background-color: #f7f7f7;
}
.page-wrapper {
height: 100%;
display: table;
}
.page-wrapper .page-inner {
display: table-cell;
vertical-align: middle;
}
.el-wrapper {
width: 360px;
padding: 15px;
margin: 15px auto;
background-color: #fff;
}
@media (max-width: 991px) {
.el-wrapper {
width: 345px;
}
}
@media (max-width: 767px) {
.el-wrapper {
width: 290px;
margin: 30px auto;
}
}
.el-wrapper:hover .h-bg {
left: 0px;
}
.el-wrapper:hover .price {
left: 20px;
transform: translateY(-50%);
transform: translateY(-50%);
transform: translateY(-50%);
transform: translateY(-50%);
color: #818181;
}
.el-wrapper:hover .add-to-cart {
left: 50%;
}
.el-wrapper:hover .img {
webkit-filter: blur(7px);
filter: blur(7px);
filter: blur(7px);
filter: blur(7px);
filter: progid:DXImageTransform.Microsoft.Blur(pixelradius='7', shadowopacity='0.0');
opacity: 0.4;
}
.el-wrapper:hover .info-inner {
bottom: 155px;
}
.el-wrapper:hover .a-size {
transition-delay: 300ms;
transition-delay: 300ms;
transition-delay: 300ms;
bottom: 50px;
opacity: 1;
}
.el-wrapper .box-down {
width: 100%;
height: 60px;
position: relative;
overflow: hidden;
}
.el-wrapper .box-up {
width: 100%;
height: 300px;
position: relative;
overflow: hidden;
text-align: center;
}
.el-wrapper .img {
padding: 20px 0;
transition: all 800ms cubic-bezier(0, 0, 0.18, 1);
transition: all 800ms cubic-bezier(0, 0, 0.18, 1);
transition: all 800ms cubic-bezier(0, 0, 0.18, 1);
transition: all 800ms cubic-bezier(0, 0, 0.18, 1);
/* ease-out */
transition-timing-function: cubic-bezier(0, 0, 0.18, 1);
transition-timing-function: cubic-bezier(0, 0, 0.18, 1);
transition-timing-function: cubic-bezier(0, 0, 0.18, 1);
transition-timing-function: cubic-bezier(0, 0, 0.18, 1);
/* ease-out */
}
.h-bg {
transition: all 800ms cubic-bezier(0, 0, 0.18, 1);
transition: all 800ms cubic-bezier(0, 0, 0.18, 1);
transition: all 800ms cubic-bezier(0, 0, 0.18, 1);
transition: all 800ms cubic-bezier(0, 0, 0.18, 1);
/* ease-out */
transition-timing-function: cubic-bezier(0, 0, 0.18, 1);
transition-timing-function: cubic-bezier(0, 0, 0.18, 1);
transition-timing-function: cubic-bezier(0, 0, 0.18, 1);
transition-timing-function: cubic-bezier(0, 0, 0.18, 1);
/* ease-out */
width: 660px;
height: 100%;
background-color: #3f96cd;
position: absolute;
left: -659px;
}
.h-bg .h-bg-inner {
width: 50%;
height: 100%;
background-color: #464646;
}
.info-inner {
transition: all 400ms cubic-bezier(0, 0, 0.18, 1);
transition: all 400ms cubic-bezier(0, 0, 0.18, 1);
transition: all 400ms cubic-bezier(0, 0, 0.18, 1);
transition: all 400ms cubic-bezier(0, 0, 0.18, 1);
/* ease-out */
transition-timing-function: cubic-bezier(0, 0, 0.18, 1);
transition-timing-function: cubic-bezier(0, 0, 0.18, 1);
transition-timing-function: cubic-bezier(0, 0, 0.18, 1);
transition-timing-function: cubic-bezier(0, 0, 0.18, 1);
/* ease-out */
position: absolute;
width: 100%;
bottom: 25px;
}
.info-inner .p-name,
.info-inner .p-company {
display: block;
}
.info-inner .p-name {
font-family: 'PT Sans', sans-serif;
font-size: 18px;
color: #252525;
}
.info-inner .p-company {
font-family: 'Lato', sans-serif;
font-size: 12px;
text-transform: uppercase;
color: #8c8c8c;
}
.a-size {
transition: all 300ms cubic-bezier(0, 0, 0.18, 1);
transition: all 300ms cubic-bezier(0, 0, 0.18, 1);
transition: all 300ms cubic-bezier(0, 0, 0.18, 1);
transition: all 300ms cubic-bezier(0, 0, 0.18, 1);
/* ease-out */
transition-timing-function: cubic-bezier(0, 0, 0.18, 1);
transition-timing-function: cubic-bezier(0, 0, 0.18, 1);
transition-timing-function: cubic-bezier(0, 0, 0.18, 1);
transition-timing-function: cubic-bezier(0, 0, 0.18, 1);
/* ease-out */
position: absolute;
width: 100%;
bottom: -20px;
font-family: 'PT Sans', sans-serif;
color: #828282;
opacity: 0;
}
.a-size .size {
color: #252525;
}
.cart {
display: block;
position: absolute;
width: 100%;
height: 100%;
top: 0;
left: 0;
font-family: 'Lato', sans-serif;
font-weight: 700;
}
.cart .price {
transition: all 600ms cubic-bezier(0, 0, 0.18, 1);
transition: all 600ms cubic-bezier(0, 0, 0.18, 1);
transition: all 600ms cubic-bezier(0, 0, 0.18, 1);
transition: all 600ms cubic-bezier(0, 0, 0.18, 1);
/* ease-out */
transition-timing-function: cubic-bezier(0, 0, 0.18, 1);
transition-timing-function: cubic-bezier(0, 0, 0.18, 1);
transition-timing-function: cubic-bezier(0, 0, 0.18, 1);
transition-timing-function: cubic-bezier(0, 0, 0.18, 1);
/* ease-out */
transition-delay: 100ms;
transition-delay: 100ms;
transition-delay: 100ms;
display: block;
position: absolute;
top: 50%;
left: 50%;
transform: translate(-50%, -50%);
transform: translate(-50%, -50%);
transform: translate(-50%, -50%);
transform: translate(-50%, -50%);
font-size: 16px;
color: #252525;
}
.cart .add-to-cart {
transition: all 600ms cubic-bezier(0, 0, 0.18, 1);
transition: all 600ms cubic-bezier(0, 0, 0.18, 1);
transition: all 600ms cubic-bezier(0, 0, 0.18, 1);
transition: all 600ms cubic-bezier(0, 0, 0.18, 1);
/* ease-out */
transition-timing-function: cubic-bezier(0, 0, 0.18, 1);
transition-timing-function: cubic-bezier(0, 0, 0.18, 1);
transition-timing-function: cubic-bezier(0, 0, 0.18, 1);
transition-timing-function: cubic-bezier(0, 0, 0.18, 1);
/* ease-out */
transition-delay: 100ms;
transition-delay: 100ms;
transition-delay: 100ms;
display: block;
position: absolute;
top: 50%;
left: 110%;
transform: translate(-50%, -50%);
transform: translate(-50%, -50%);
transform: translate(-50%, -50%);
transform: translate(-50%, -50%);
}
.cart .add-to-cart .txt {
font-size: 12px;
color: #fff;
letter-spacing: 0.045em;
text-transform: uppercase;
white-space: nowrap;
}
This Pen doesn't use any external JavaScript resources.