:root {
	--azul: #0069d9;
}
* {
	box-sizing: border-box;
	margin: 0;
	padding: 0;
}

html,
body {
	font-family: 'Open Sans', sans-serif;
	font-size: 1em;
	width: 100%;
}

body > p {
	margin: 10px;
}
.container {
	margin: 1em auto;
	max-width: 1000px;
	width: 90%;
}

.triptico {
	-ms-perspective: 2000px;
	perspective: 2000px;
	display: flex;
}

.izq,.cen,.der,
.izquierda,
.centro,
.derecha {
	height: 500px;
	background-color: #fff;
	width: calc(100% / 3);
	border: 1px solid;
	transition: 0.7s ease-in-out;
	margin: 0 auto;
}
.izquierda {
	position: absolute;
	transform: rotateY(180deg);
	transform-origin: 100% 50%;
	box-shadow: inset 300px 0 50px rgba(0, 0, 0, .5), 0 10px 20px rgba(0, 0, 0, .5);
}

.centro {
	box-shadow: inset 300px 0 50px rgba(0, 0, 0, .5), 0 10px 20px rgba(0, 0, 0, .5);
}

.derecha {
	position: absolute;
	transform: rotateY(-180deg);
	transform-origin: 0% 50%;
	top: 0;
	right: 0;
	visibility: hidden;
}

.izquierda.ver,
.derecha.ver {
	transform: rotateY(0deg);
	transition: 0.7s ease-in-out;
}

.izquierda.ver {
	box-shadow: inset 300px 0 50px rgba(0, 0, 0, .5), -10px 10px 20px rgba(0, 0, 0, .5);
}

.derecha.ver {
	visibility: visible;
	box-shadow: inset 300px 0 50px rgba(0, 0, 0, .5), 10px 10px 20px rgba(0, 0, 0, .5);
}

.adelante,
.atras {
	height: 100%;
	width: 100%;
	position: absolute;
	background-color: #fff;
	top: 0;
}

.adelante {
	transform: rotateY(180deg);
}

.atras {
	visibility: hidden;
}

.atras.ver {
	visibility: visible;
}

.izquierda .atras button {
	visibility: hidden;
}

.contenido {
	display: flex;
	flex-direction: column;
	align-items: center;
	height: 100%;
	width: 100%;
	padding: 10px;
	box-sizing: border-box;
	overflow: hidden;
	background-color: #fff;
}

.contenido p {
	max-height: 100px;
	overflow-y: auto;
	max-height: 100%;
	text-align: left;
}

h1 {
	font-size: 1.5em;
	color: var(--azul);
	padding-top: 10px;
}

hr {
	margin-bottom: 10px;
	border: 0px solid #fff;
	width: 100%;
	height: 1px;
	background-color: #fff;
}

.mostrar1 {
	position: absolute;
	border: 1px solid;
	background-color: transparent;
	padding: 5px;
	margin-bottom: auto;
	min-width: 120px;
	max-width: 150px;
	bottom: 15px;
	transition: 0.2s ease-in-out;
	cursor: pointer;
}

.mostrar1:hover {
	background-color: var(--azul);
	color: #fff;
	transition: 0.2s ease-in-out;
}

.cerrar1 {
	position: absolute;
	border: 1px solid;
	background-color: transparent;
	border-radius: 50%;
	width: 30px;
	height: 30px;
	font-size: 1em;
	cursor: pointer;
	top: 10px;
	right: 10px;
	display: none;
}

.cerrar1:hover {
	background-color: var(--azul);
	color: #fff;
	transition: 0.2s ease-in-out;
}

@media screen and (orientation: portrait) {
	.container {
		display: flex;
		justify-content: center;
		transition: all 1s ease;
		font-size: 0.8em;
	}

	.container.abierto {
		transform: translateY(100%);
		margin-bottom: 40em;
	}

	.triptico {
		-ms-perspective: 2000px;
		perspective: 2000px;
		width: 90%;
		margin: 0 auto;
	}

	.izquierda,
	.centro,
	.derecha {
		width: 100%;
		height: 250px;
	}

	.izquierda {
		transform: rotateX(0deg) rotateY(180deg);
		transform-origin: center top;
		box-shadow: inset 300px 0 50px rgba(0, 0, 0, .5), 0 10px 20px rgba(0, 0, 0, .5);
	}

	.derecha {
		transform: rotateX(0deg) rotateY(180deg);
		transform-origin: center bottom;
	}

	.izquierda.ver {
		transition: 0.7s ease-in-out;
		transform: rotateX(180deg) rotateY(180deg);
		box-shadow: inset 300px 0 50px rgba(0, 0, 0, .5), 0 10px 20px rgba(0, 0, 0, .5);
	}

	.derecha.ver {
		transition: 0.7s ease-in-out;
		transform: rotateX(-180deg) rotateY(180deg);
		box-shadow: inset 300px 0 50px rgba(0, 0, 0, .5), 0 -10px 20px rgba(0, 0, 0, .5);
	}


	.adelante {
		transform: rotateY(180deg);
	}
	
	.atras.ver {
		transform: rotate(180deg);
	}

	.izquierda .atras button {
		visibility: visible;
	}

	.derecha .contenido {
		transform: rotate(180deg);
	}

	.derecha button {
		visibility: hidden;
	}

	.izquierda .adelante .contenido p {
		max-height: 100px;
		overflow-y: auto;
		max-height: 50%;
		text-align: left;
	}
}
  
@media (max-width: 576px) {
	body {
		font-size: 1em;
	}
}
