@import url('https://fonts.googleapis.com/icon?family=Material+Icons');
@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+JP:wght@400;500&display=swap');

body {
	user-select: none;
}

::-webkit-scrollbar {
	width: 0;
	height: 0;
	opacity: 0;
}

::-webkit-scrollbar-thumb {
	opacity: 0;
	border-radius: 0;
}

::-webkit-scrollbar-corner {
	opacity: 0;
}

html {
	font-size: 3.47vh;
	font-family: 'Noto Sans JP', sans-serif;
}

body:is([vista="previa"], [vista="espera"]) :is(#logo, #mpmart) {
	display: none
}

body:not(:is([vista="previa"], [vista="espera"])) :is(#logosi, #mpinmob) {
	display: none
}

body[espejo] #player {
	transform: scale(-1, 1);
}

#player {
	height: 100%;
	width: 100%;
	top: 0;
	right: 0;
}

body[vista="video"]:not([cam*="1"]) #player {
	opacity: 0;
}

#background {
	opacity: 0;
}

/* body:not([cam*="1"]) #background,body.terreno #background{opacity: 1;} */
#player video {
	width: 100%;
	height: 100%;
	position: absolute;
	top: 0;
	left: 0;
	object-fit: cover;
	transition: 1s;
}

#banner {
	top: 4vh;
	left: 4vh;
	height: 5em;
	right: 4vh;
}

#banner #contacto {
	padding: 0.1em 1em;
	width: max-content;
	display: flex;
	flex-direction: column;
	justify-content: space-between;
	font-size: 0.9em;
}

body[vista="detalle"] #player {
	width: 66vh;
	height: 37vh;
	top: 42.2vh;
	right: 0;
}

body:is([vista="inicial"], [vista="video"]:not([cam="video"]), [vista="previa"]:not([cam="video"])) #galeria,
body:is([vista="inicial"], [vista="video"]:not([cam="video"]), [vista="previa"]:not([cam="video"])) #terrenos {
	height: 0;
	top: 0;
	width: 0;
	right: 0;
	opacity: 0;
}

body[vista="video"][cam="video"] #galeria {
	height: 100%;
	top: 0;
	width: 100%;
	right: 0;
	opacity: 1;
}

body:is([vista="inicial"], .terreno) #datos {
	opacity: 0;
}

#datos {
	top: 25vh;
	left: 7vh;
	filter: drop-shadow(0 0 .1rem white);
}

#galeria {
	height: 76.5vh;
	top: 23.5vh;
	width: 73.5vh;
	right: 0;
	overflow: hidden;
}

body[vista="detalle"] #galeria {
	height: 100vh;
	top: 0;
	width: 100vw;
	right: 0;
}

body,
#background {
	width: 100.2vw;
	height: 100vh;
	overflow: hidden;
	position: relative;
}

body[vista="previa"] #background {
	filter: invert(0.8);
	background: white;
}

body {
	/* background-color: white; */
	font-family: Helvetica, Arial, sans-serif;
	color: black;
	margin: 0;
	--bordes: hsl(0deg 0% 70%);
	--rojo: #bd322d;
}

body>*:not(#background),
#terrenos div > * {
	z-index: 1;
	transition: 1s;
	position: absolute;
}

#player,
#segundaCam,
#tercerCam {
	object-fit: cover;
}

#banner {
	display: flex;
	justify-content: space-between;
	flex-wrap: wrap;
	gap: 4vh;
	z-index: 10 !important;
}

#banner>* {
	display: block;
	height: inherit;
	box-sizing: border-box;
	line-height: 1.2em;
}

#contacto,
body[vista="detalle"] #player {
	border-radius: .4vh;
	border: solid .05rem var(--bordes);
	background: white;
	overflow: hidden;
}

body[cam="12"] #player,
body[cam="13"] #player {
	right: 25%;
}

body:not([vista="detalle"])[cam="12"] #segundaCam,
body:not([vista="detalle"])[cam="13"] #tercerCam,
body:not([vista="detalle"])[cam="23"] #tercerCam {
	width: 320px;
	left: 50%;
	border-left: white solid 5px;
}

body:not([vista="detalle"])[cam="23"] #segundaCam {
	width: 320px;
	left: 0%;
}

body:not([vista="detalle"])[cam="12"] #segundaCam iframe,
body:not([vista="detalle"])[cam="23"] #segundaCam iframe,
body:not([vista="detalle"])[cam="13"] #tercerCam iframe,
body:not([vista="detalle"])[cam="23"] #tercerCam iframe {
	left: -160px;
}

#fechahora {
	text-align: center;
}

#banner p {
	margin: auto 0;
}

#background {
	z-index: 0;
	background-color: white;
}

#background div {
	position: absolute;
	border-radius: 100%;
	transform: translate(-50%, -50%);
	animation: cuadradosFondo var(--lt) ease infinite;
	background-color: hsl(var(--c) 100% 90% / .7);
	z-index: var(--z);
}

@keyframes cuadradosFondo {
	0% {
		width: var(--ti);
		height: var(--ti);
		top: var(--yi);
		left: var(--xi);
	}

	100% {
		width: var(--tf);
		height: var(--tf);
		top: var(--yf);
		left: var(--xf);
	}
}

.textoLogo {
	min-width: 7.5em;
	color: white;
	font-weight: bold;
}

.textoLogo>* {
	position: relative;
	line-height: 1.5em;
	height: 1.5em;
}

.textoLogo> :first-child {
	padding-right: 1em;
}

.textoLogo> :last-child {
	text-align: right;
	width: fit-content;
	min-width: 4em;
	margin-left: auto;
	padding-left: 1em;
}

.textoLogo>*::after {
	content: "";
	display: block;
	position: absolute;
	top: 7%;
	height: 85%;
	background: #b1302b;
	z-index: -1;
	transform: skew(28deg);
	width: 100%;
}

.textoLogo :first-child::after {
	left: -.4em;
}

.textoLogo :last-child::after {
	right: -.4em;
}

#galeria>div {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	display: flex;
	flex-direction: row;
	justify-content: center;
	opacity: 1;
	transition: .5s;
	align-items: center;
}

#galeria :is(img, video) {
	width: min(calc(95% * var(--ar)), 95%);
	height: min(calc(95% / var(--ar)), 95%);
	object-fit: cover;
	margin: auto;
	border-radius: .4vh;
	border: solid .05rem var(--bordes);
	transition: opacity 0.5s;
	aspect-ratio: var(--ar);
}

body[vista="previa"] #galeria video {
	position: absolute;
	max-width: 100%;
	max-height: 100%;
	border-radius: 0;
	border: none;
}

body[vista="video"] #galeria :is(img, video) {
	width: 100%;
	height: 100%;
	max-width: 100%;
	max-height: 100%;
	background: none;
	border: none;
}

body[vista="detalle"] #galeria :is(img, video) {
	max-width: 100%;
	max-height: 100%;
	height: 100%;
	background: none;
	border: none;
	object-fit: contain;
}

body[vista="detalle"] #galeria :is(img, video):not(.activo) {
	display: none;
}

body:is([vista="mixto"], [vista="detalle"]) #galeria :is(img, video) {
	position: absolute;
}

body:is([vista="mixto"], [vista="video"]) #galeria :is(img, video):not(.activo),
body:is([vista="inicial"], [vista="data"], [vista="video"]:not([cam="video"])) #galeria :is(img, video) {
	opacity: 0;
	width: 0
}

body:is([vista="mixto"], [vista="video"], [vista="detalle"]) #galeria.activo div.activo img.activo {
	animation: paseFoto 10s ease infinite;
}

body:not([vista="previa"]) #galeria>div:not(.activo) {
	opacity: 0;
}

@keyframes paseFoto {
	0% {
		transform: translate(50%);
		opacity: 0
	}

	3%,
	95% {
		transform: translate(0);
		opacity: 1
	}

	100% {
		transform: translate(-50%);
		opacity: 0
	}
}

body[vista="inicial"] #adjudicado {
	display: none
}

body:not([vista="inicial"]):not([adjudicado="si"]) #adjudicado {
	display: block;
	opacity: 0;
	width: 100vh;
	top: 0;
	left: 0;
	transform: rotate(450deg);
}

body:not([vista="inicial"], .terreno)[adjudicado="si"] #adjudicado {
	display: block;
	opacity: 1;
	position: fixed;
	top: 77vh;
	left: 18vh;
	width: 70vh;
	transform: rotate(-12deg);
	border-radius: 1rem;
}

body:is([vista="mixto"], [vista="data"])[adjudicado="si"] #adjudicado {
	left: 106vh !important;
}

body:not([vista="destacado"]) #propDestacado {
	opacity: 0;
	transform: scale(0) rotate(600deg)
}

body[vista="destacado"] #propDestacado {
	top: 0;
	left: 0;
	height: 100%;
	width: 100%;
	z-index: 5;
	background-color: var(--rojo);
	font-size: 3rem;
	color: white;
	text-align: center;
	padding-top: 41.5vh;
}

body[vista="destacado"] #propDestacado::after {
	top: 65vh;
	left: 89vh;
	background-color: inherit;
	white-space: nowrap;
	transform: translate(-50%, 0) rotate(0deg);
	animation: destacado 2s ease infinite;
}

@keyframes destacado {

	40%,
	60% {
		transform: translate(-50%, 0) scale(1.6) rotate(-15deg)
	}
}

body:not(:is([vista="previa"], [vista="inicial"], [vista="destacado"]))[destacado="si"]::after,
body[vista="destacado"] #propDestacado::after {
	content: "Lote Destacado";
	display: block;
	text-transform: uppercase;
	position: absolute;
	font-weight: bold;
	font-size: 2.3rem;
	border: 0.25rem solid;
	padding: 0.25rem 1rem;
	border-radius: 0.5em;
	mask-image: url(https://s3-us-west-2.amazonaws.com/s.cdpn.io/8399/grunge.png);
	mask-size: 100vw;
	-webkit-mask-image: url(https://s3-us-west-2.amazonaws.com/s.cdpn.io/8399/grunge.png);
	-webkit-mask-size: 100vw;
	color: #0A9928;
	z-index: 10;
	transition: 1s;
}

body:is([vista="mixto"], [vista="data"])[destacado="si"]::after {
	bottom: .4vh;
	right: .4vh;
	transform: rotate(-25deg);
	font-size: 1.2rem;
	background: hsl(0 0% 100% / 0.2);
	transform-origin: bottom left;
}

body:is([vista="video"], [vista="detalle"])[destacado="si"]::after {
	bottom: .4vh;
	right: .4vh;
	transform: rotate(-22deg);
	transform-origin: bottom left;
	font-size: 2.6rem;
	background: hsl(0 0% 100% / 0.2);
}

#segundaCam,
#tercerCam {
	top: 0;
	left: 0;
	height: 360px;
	width: 640px;
	overflow: hidden;
	transform-origin: top left;
	transition: opacity 1s !important;
	transform: scale(var(--scale));
}

#segundaCam iframe,
#tercerCam iframe {
	position: absolute;
	top: -60px;
	left: 0;
	border: 0;
	transform-origin: bottom left;
}

#previa,
body[vista="previa"] #galeria {
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
}

body[vista="previa"] #galeria img {
	opacity: 0;
}

body[vista="previa"] #galeria video[propio] {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	max-width: unset;
	max-height: unset;
	background: none;
}

body[vista="previa"] #galeria video:not(.activo),
body[vista="inicial"] #galeria video {
	opacity: 0;
}

#previa img {
	width: 100%;
	height: 100%;
	object-fit: contain;
	background-image: linear-gradient(to bottom, white 50%, black 50%);
}

#videos,
#props {
	top: -1px;
	right: 0;
	height: 101%;
	width: 101%;
}

body:not([vista="prop"]) #props {
	display: none;
}

body[vista="previa"] #videos {
	background: black;
}

#videos video,
#props video {
	position: absolute;
	top: 0;
	left: 0;
	width: 101%;
	height: 101%;
	object-fit: contain;
	transition: 1s;
}

#props video[reproducido] {
	opacity: 0;
}

#previa>* {
	display: block;
	position: absolute;
	z-index: 100;
	text-align: center;
	color: white;
	line-height: 1.5;
	text-shadow: 0 0 .2rem black, 0 0 .2rem black, 0 0 .2rem black, 0 0 .2rem black;
}

#previa #texto1 {
	bottom: 25vh;
	right: 0;
	width: 60%;
	font-size: 0.8rem;
}

#previa #texto2 {
	top: 25vh;
	width: 60%;
	right: 0;
	font-size: 1rem;
}

body:not([vista="previa"]):not([vista="espera"]) #videos video:not(.activo) {
	opacity: 0;
	display: none;
}

body:not([vista="previa"]) :is(#previa, #videos),
body[vista="previa"]> :not(#galeria, #banner, #previa, #background) {
	opacity: 0
}

body[vista="previa"]:not([cam="video"]) #videos {
	opacity: 0;
}

body[vista="previa"][cam="secundaria"] #proximos,
body.terreno #terrenos {
	opacity: 1 !important
}

body[vista="espera"]> :not(#background, #terrenos, #banner, #mensajes),
body:not([vista="espera"])>#proximos,
body[vista="espera"] #fechahora {
	opacity: 0;
	display: none;
}

#proximos,
#terrenos {
	display: flex;
	justify-content: center;
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	overflow: hidden;
}

/* body:is([vista="inicial"],[vista="mixto"],[vista="data"],[vista="detalle"],[vista="video"]) :is(#proximos,#terrenos){display:none;opacity: 0;} */
body:not(.terreno) :is(#proximos, #terrenos) {
	display: none;
	opacity: 0;
}

body.terreno #terrenos.activo>div.activo img.activo {
	animation: proximos 10s infinite;
	height: 100%;
	object-fit: contain;
}

#terrenos video {
	height: 100% !important;
	opacity: 0;
	width: 100% !important;
	transition: 1s;
	object-fit: cover;
}

body.terreno #terrenos video.activo {
	height: 100%;
	opacity: 1;
}

#terrenos,
#terrenos div.activo{
	width: 100%;
	height: 100%;
	position: relative;
}

#terrenos div.activo > div {
	position: absolute;
	height: 76.5vh;
    top: 23.5vh;
    width: 73.5vh;
    right: 0;
    overflow: hidden;
	border-top-left-radius: 1em;
}

body[vista="detalle"] #terrenos div.activo > div {
	top: 0;
    height: 100%;
    width: 100%;
	border-top-left-radius: 0;
}

#terrenos p {
	position: absolute;
	right: 1em;
	left: 1em;
	margin: 0;
	bottom: 1em;
	z-index: 2;
	background: hsl(0 0% 100%);
	padding: 1em;
	border-radius: 1em;
	text-shadow: 0 0 5px white;
}

body[vista="previa"] #terrenos p {
	right: 28em;
	font-size: 0.8em;
	top: 30em;
}

#terrenos .activo span:first-of-type {
	animation: textoTerreno 10s ease infinite;
}

@keyframes textoTerreno {

	0%,
	100% {
		opacity: 0
	}

	5%,
	95% {
		opacity: 1
	}
}

#terrenos span:not(:first-of-type) {
	display: none;
}

#terrenos h1 {
	position: absolute;
	top: 0.5em;
	left: 4.75em;
	color: white;
	z-index: 2;
	text-shadow: 0 0 0.2em black, 0 0 0.2em black;
	font-size: 1.5em;
	width: 17em;
}

body[vista="previa"] #terrenos h1 {
	font-size: 1em;
	left: 7em;
	width: 25em;
}

body[vista="espera"][cam="video"] #videos,
body[vista="espera"][cam="secundaria"] #proximos {
	opacity: 1;
}

body:is([vista="inicial"], [vista="data"]) #terrenos div.activo div,
body:is([vista="inicial"], [vista="data"], [vista="mixto"]) #terrenos div.activo p {
	opacity: 0;
	width: 0
}

#terrenos>div:not(.activo),
#terrenos>div:not(.activo) video,
#terrenos div :is(img, video):not(.activo),
body[vista="espera"] #terrenos {
	opacity: 0;
	width: 0;
	height: 100%;
}

@keyframes proximos {

	10%,
	90% {
		width: 100%;
		opacity: 1;
		border-radius: 0;
		margin: 0;
	}

	0% {
		width: 0;
		opacity: 0;
		border-radius: 2vw;
		margin-right: 100%;
	}

	100% {
		width: 0;
		opacity: 0;
		border-radius: 2vw;
		margin-left: 100%
	}
}

body[vista="detalle"]:not([cam="2"]) #segundaCam,
body[vista="detalle"]:not([cam="3"]) #tercerCam {
	top: 42.2vh;
	right: 0;
	transform-origin: top right;
	left: unset;
	transform: scale(calc(var(--scale)/2.68));
}

body[vista="detalle"] #videos {
	width: 66vh;
	height: 37vh;
	top: 42.2vh;
	right: 4vh;
}

body:is([vista="mixto"], [vista="data"])[cam="video"] #videos {
	opacity: 1;
}

body[vista="detalle"][cam="video"] #videos {
	opacity: 1;
}

body[vista="video"][cam="video"] #videos {
	opacity: 1;
}

body:not([cam*="2"]) #segundaCam,
body:not([cam*="3"]) #tercerCam{
	opacity: 0;
}

#previa #logobollo {
	padding: 1em 2em;
	display: flex;
	bottom: 0;
	right: 0;
	box-sizing: border-box;
	justify-content: space-between;
}

#logobollo div {
	display: flex;
	flex-direction: column;
	height: 100%;
	justify-content: space-between;
	font-size: .8em;
	align-items: start;
	margin: auto 0;
}

#logobollo p {
	margin: auto;
}

#logobollo p+p {
	margin-top: 0.5em;
}

#logobollo svg+p {
	margin-top: -0.7em;
	padding-left: 3.6em;
	font-size: .9em;
}

#mensajes {
	bottom: 0;
	height: 60vh;
	width: 50vw;
	left: 5vw;
	display: flex;
	flex-direction: column;
	justify-content: flex-end;
	overflow: hidden;
	padding-bottom: 0.3em;
}

body[vista="espera"] #mensajes {
	bottom: 5rem;
}

#mensajes>div[modelo] {
	display: none
}

#mensajes [msj-id] {
	--fondo: white;
	position: relative;
	width: 90%;
	margin: .2em 0.5em .2em 1em;
	margin-right: auto;
	background-color: white;
	padding: 1em .5em .5em;
	border-radius: 0.4em;
	font-size: 1.1rem;
	border: .1em solid var(--fondo);
	opacity: 0;
	transform-origin: bottom;
}

@keyframes msjes {
	0% {
		transform: scaleY(0);
		font-size: 0;
	}

	5% {
		transform: none;
		font-size: 1rem;
	}

	0%,
	95% {
		opacity: 1
	}

	100% {
		opacity: 0;
		font-size: 1rem;
	}
}

#mensajes [msj-id]:nth-last-child(-n+4) {
	animation: msjes 10s ease forwards;
}

#mensajes [jc] {
	--fondo: red
}

#mensajes [msj-id]::before {
	content: '';
	width: 0;
	height: 0;
	border-right: 0.3em solid transparent;
	border-left: 0.3em solid transparent;
	border-top: 0.4em solid var(--fondo);
	position: absolute;
	top: -0.09em;
	left: -0.38em;
}

#mensajes [msj-id] :is(.nombre, .hora) {
	position: absolute;
	top: .15em;
	font-size: 0.7em;
}

#mensajes [msj-id] .nombre {
	left: .5em
}

#mensajes [msj-id] .lote {
	display: none;
}

#mensajes [msj-id] .hora {
	right: .5em
}

#mensajes [msj-id] .lote {
	position: absolute;
	bottom: -0.3rem;
	left: -1.1rem;
	border-radius: 1rem;
	background: red;
	color: white;
	font-size: .8rem;
	width: 1.6rem;
	height: 1.6rem;
	line-height: 2;
	text-align: center;
	font-weight: bold;
}

#mensajes [msj-id] .lote.saludo {
	display: none
}

#mensajes [msj-id] .lote.material-icons {
	font-size: 1.1rem;
	line-height: 1.4;
}

body[vista="prop"]>*:not(#props, #background) {
	opacity: 0
}
