.image{
transform: rotateY(180deg);
}
img{
transform: rotateY(180deg);
}
/* entire container, keeps perspective */
.flip-container {
perspective: 1000px;
}
/* flip the pane when hovered */
.flip-container:hover .flipper, .flip-container.hover .flipper {
transform: rotateY(180deg);
}
.flip-container, .front, .back {
width: 320px;
height: 480px;
}
/* flip speed goes here */
.flipper {
transition: 0.6s;
transform-style: preserve-3d;
position: relative;
}
/* hide back of pane during swap */
.front, .back {
backface-visibility: hidden;
position: absolute;
top: 0;
left: 0;
}
/* front pane, placed above back */
.front {
z-index: 2;
/* for firefox 31 */
transform: rotateY(0deg);
}
/* back, initially hidden pane */
.back {
transform: rotateY(180deg);
}
.flipping-card-item-side-back{
color: #000;
transform: rotateY(180deg);
}
.flipping-card-item-wrapper:hover .flipping-card-item-side-front{
transform: rotateY(-180deg);
}
.flipping-card-item-wrapper:hover .flipping-card-item-side-back{
transform: rotateY(0);
}
.flipping-card-item-img{
width: 100%;
height: 100%;
background-size: cover;
background-blend-mode: color;
}
.flipping-card-back-wrapper{
font-weight: 200;
position: relative;
top: 25%;
left: 0;
margin: 2rem;
text-align: center;
}
.flipping-card-back-wrapper__btn {
margin-top: 2rem;
padding: .7rem;
text-align: center;
color: #ffffff;
border: 0;
background-image: linear-gradient(to right bottom, #ffa41b, #ff5151);
transition: all .5s;
}
.flipping-card-back-wrapper__btn:hover {
background-image: none;
color: #ffa41b;
border: 1px solid #ffa41b;
}
<div class="flip">
<div class="flip-content">
<div class="flip-front">
<img src="https://www.fillmurray.com/150/150" />
</div>
<div class="flip-back">
<strong>BILL MURRAY</strong>
</div>
</div>
</div>
.flip {
width: 100%;
}
.flip-content {
transition: transform 0.4s;
transform-style: preserve-3d;
}
.flip:hover .flip-content {
transform: rotateY(180deg);
transition: transform 0.3s;
}
.flip-front, .flip-back {
backface-visibility: hidden;
}
.flip-back {
transform: rotateY(180deg);
}