/* Container box to set the sides relative to */
.cube {
	width: 90%;
	text-align: center;
	margin: 20px auto;
	height: 200px;

	-webkit-transition: -webkit-transform .33s;
	transition: transform .33s; /* Animate the transform properties */

	-webkit-transform-style: preserve-3d;
	transform-style: preserve-3d; /* <-NB */
}

/* The two faces of the cube */
.flippety,.flop {
	background: rgb(247, 247, 247);
	border: 1px solid rgba(147, 184, 189, .8);
    display: table;
	-webkit-border-radius: 5px;
	border-radius: 5px;

	-webkit-box-shadow: 0 5px 20px rgba(105, 108, 109, .3), 0 0 8px 5px rgba(208, 223, 226, .4) inset;
	box-shadow: 0 5px 20px rgba(105, 108, 109, .3), 0 0 8px 5px rgba(208, 223, 226, .4) inset;
	height: 200px;
}

/* Position the faces */
.flippety {
	-webkit-transform: translateZ(100px);
	transform: translateZ(100px);
}

.flop {
	-webkit-transform: rotateX(-90deg) translateZ(-100px);
	transform: rotateX(-90deg) translateZ(-100px);
}

/* Rotate the cube */
.cube:hover {
	-webkit-transform: rotateX(90deg);
	transform: rotateX(90deg); /* Text bleed at 90º */
}

.cube p {
    display: table-cell;
	vertical-align: middle;
}

.flippety img {
	object-fit: cover;
}

.cubeproject-grid {
    display: grid;
	grid-template-columns: auto;
	grid-gap: 0px;
    padding: 0px;
    margin:auto;
    width:auto;
}

.cubeproject-grid-text {
    width: 80%;
	margin: auto;
}

@media only screen and (max-width: 1000px) {
	.cube p {
		font-size:12px!important;}
	.cube {
		height:100px;
	}
	.flippety {
		-webkit-transform: translateZ(50px);
	    transform: translateZ(50px);
		height: 100px;
	}
		.flop {
		-webkit-transform: rotateX(-90deg) translateZ(-50px);
	    transform: rotateX(-90deg) translateZ(-50px);
		height: 100px;
	}
		
}
