cssAudio - Activefile-genericCSS - ActiveGeneric - ActiveHTML - ActiveImage - ActiveJS - ActiveSVG - ActiveText - Activefile-genericVideo - ActiveLovehtmlicon-new-collectionicon-personicon-teamlog-outoctocatpop-outspinnerstartv

Pen Settings

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URL's added here will be added as <link>s in order, and before the CSS in the editor. If you link to another Pen, it will include the CSS from that Pen. If the preprocessor matches, it will attempt to combine them before processing.

+ add another resource

You're using npm packages, so we've auto-selected Babel for you here, which we require to process imports and make it all work. If you need to use a different JavaScript preprocessor, remove the packages in the npm tab.

Add External Scripts/Pens

Any URL's added here will be added as <script>s in order, and run before the JavaScript in the editor. You can use the URL of any other Pen and it will include the JavaScript from that Pen.

+ add another resource

Use npm Packages

We can make npm packages available for you to use in your JavaScript. We use webpack to prepare them and make them available to import. We'll also process your JavaScript with Babel.

⚠️ This feature can only be used by logged in users.

Code Indentation

     

Save Automatically?

If active, Pens will autosave every 30 seconds after being saved once.

Auto-Updating Preview

If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.

            
              <body>
<div class="wrapper">
	<div class="rudi">
		<div class="head"></div>
		<div class="eye-left"></div>
		<div class="eye-right"></div>
		<div class="ear-left"></div>
		<div class="ear-right"></div>
		<div class="antler-left"></div>
		<div class="antler-right"></div>
		<div class="arm-left"></div>
		<div class="arm-right"></div>
		<div class="leg-left"></div>
		<div class="leg-right"></div>
		<div class="pull-rope"></div>
		<div class="torso"></div>
		<div class="star1"></div>
		<div class="star2"></div>
		<div class="star3"></div>
		<div class="star4"></div>
	</div>
</div>
</body>

            
          
!
            
              body{
	background-image: linear-gradient(#000033, black)
}

.wrapper{
	height: 1500px;
}

.head, .arm-left, .arm-right, .leg-left, .leg-right, .torso, .pull-rope, .eye-left, .eye-right, .ear-left, .ear-right, .antler-left, .antler-right, .star1, .star2, .star3, .star4{
background: url(https://mensch-mesch.com/wp-content/uploads/2017/06/Rudi-the-rednosed-reindeer-separated.png) 0 0 no-repeat;	
width: 200px;
height: 200px;
/*border: 1px dotted red;*/
}

.rudi, .head, .arm-left, .arm-right, .leg-left, .leg-right, .eye-left, .eye-right, .ear-left, .ear-right, .antler-left, .antler-right, .torso, .star1, .star2, .star3, .star4, pull-rope {
	background-size: 800px;
	position: absolute;
	display: block;
	/*border: 1px dotted yellow;*/
}

.rudi{
	width: 850px;
	height: 1400px;
	left: 50%;
	top: 40px;
	/*border: 1px dotted blue;*/
	margin-left: -425px;
}

.torso{
	position: absolute;
	background-position: -6px -14px;
	display: block;
	top: 330px;
	left: 200px;
	width: 461px;
	height: 510px;
}

.head{
	position: absolute;
	display: block;
	background-position: -534px -214px;
	top: 207px;
	left: 337px;
	width: 191px;
	height: 296px;
	z-index: 1;
	transform-origin: 155px 500px;
	animation: swing-head 3s ease-in-out 0s infinite alternate;
}

.eye-left{
	position: absolute;
	display: block;
	background-position: -578px -12px;
	top: 290px;
	left: 380px;
	width: 39px;
	height: 63px;
	z-index: 10;
	transform-origin: 29px 49px;
	animation: swing-left-eye 3s ease-in-out 0s infinite alternate;
}

.eye-right{
	position: absolute;
	display: block;
	background-position: -628px -3px;
	top: 280px;
	left: 430px;
	width: 45px;
	height: 68px;
	z-index: 10;
	transform-origin: 20px 58px;
	animation: swing-right-eye 3s ease-in-out 0s infinite alternate;
}


.ear-left{
	position: absolute;
	display: block;
	background-position: -436px -795px;
	top: 210px;
	left: 430px;
	width: 156px;
	height: 72px;
	z-index: -1;
	transform-origin: 10px 20px;
	animation: swing-left-ear 3s ease-in-out 0s infinite alternate;
}

.ear-right{
	position: absolute;
	display: block;
	background-position: -213px -790px;
	top: 210px;
	left: 289px;
	width: 132px;
	height: 77px;
	z-index: -1;
	transform-origin: 149px 30px;
	animation: swing-right-ear 3s ease-in-out 0s infinite alternate;
}

.antler-left{
	position: absolute;
	display: block;
	background-position: -228px -892px;
	top: 12px;
	left: 290px;
	width: 134px;
	height: 219px;
	z-index: 1;
	transform-origin: 129px 214px;
	animation: swing-left-antler 3s ease-in-out 0s infinite alternate;
}

.antler-right{
	position: absolute;
	display: block;
	background-position: -439px -887px;
	top: 8px;
	left: 443px;
	width: 140px;
	height: 257px;
	z-index: 1;
	transform-origin: 5px 257px;
	animation: swing-right-antler 3s ease-in-out 0s infinite alternate;
	
}


.arm-left{
	position: absolute;
	display: block;
	background-position: -50px -562px;
	top: 445px;
	left: 85px;
	width: 276px;
	height: 140px;
	z-index: 0;
	transform-origin: 240px 20px;
	animation: swing-left-arm 3s ease-in-out 0s infinite alternate;
}


.arm-right{
	position: absolute;
	display: block;
	background-position: -466px -562px;
	top: 450px;
	left: 501px;
	width: 276px;
	height: 150px;
	z-index: 0;
	transform-origin: 40px 20px;
	animation: swing-right-arm 3s ease-in-out 0s infinite alternate;
}

.leg-left{
	position: absolute;
	display: block;
	background-position: -610px -769px;
	top: 730px;
	left: 230px;
	width: 178px;
	height: 324px;
	z-index: 0;
	transform-origin: 90px 70px;
	animation: swing-left-leg 3s ease-in-out 0s infinite alternate;
}

.leg-right{
	position: absolute;
	display: block;
	background-position: -14px -769px;
	top: 733px;
	left: 445px;
	width: 178px;
	height: 324px;
	z-index: 0;
	transform-origin: 70px 40px;
	animation: swing-right-leg 3s ease-in-out 0s infinite alternate;
}

.pull-rope{
	position: absolute;
	display: block;
	background-position: -583px -1080px;
	top: 672px;
	left: 389px;
	width: 74px;
	height: 566px;
	z-index: 0;
	/*opacity: 1;*/
	animation: pull-the-rope 3s ease-in-out 0s infinite alternate;
}

@keyframes swing-right-leg {
	0%{transform: rotateZ(0deg);}
	25%{transform: rotateZ(-55deg);}
	50%{transform: rotateZ(-45deg);}
	100%{transform: rotateZ(0deg);}
}

@keyframes swing-left-leg {
	0%{transform: rotateZ(0deg);}
	25%{transform: rotateZ(55deg);}
	50%{transform: rotateZ(45deg);}
	100%{transform: rotateZ(0deg);}
}

@keyframes swing-right-arm {
	0%{transform: rotateZ(0deg);}
	25%{transform: rotateZ(-85deg);}
	50%{transform: rotateZ(-80deg);}
	100%{transform: rotateZ(0deg);}
}

@keyframes swing-left-arm {
	0%{transform: rotateZ(0deg);}
	25%{transform: rotateZ(85deg);}
	50%{transform: rotateZ(80deg);}
	100%{transform: rotateZ(0deg);}
}

@keyframes pull-the-rope {
	0%{transform: translateY(0px);}
	25%{transform: translateY(70px);}
	50%{transform: translateY(60px);}
	100%{transform: translateY(0px);}
}

@keyframes swing-head {
	0%{transform: translateY(0px) rotateZ(0deg);}
	25%{transform: translateY(3px) rotateZ(-1deg);}
	50%{transform: translateY(1px) rotateZ(2deg);}
	100%{transform: translateY(0px) rotateZ(0deg);}
}

@keyframes swing-right-antler {
	0%{transform: translateX(0px) translateY(0px) rotateZ(0deg);}
	25%{transform: translateX(-5px) translateY(3px) rotateZ(-1deg);}
	50%{transform: translateX(15px) translateY(1px) rotateZ(2deg);}
	100%{transform: translateX(0px) translateY(0px) rotateZ(0deg);}
}

@keyframes swing-left-antler {
	0%{transform: translateX(0px) translateY(0px) rotateZ(0deg);}
	25%{transform: translateX(-5px) translateY(6px) rotateZ(2deg);}
	50%{transform: translateX(15px) translateY(2px) rotateZ(-1deg);}
	100%{transform: translateX(0px) translateY(0px) rotateZ(0deg);}
}

@keyframes swing-right-ear {
	0%{transform: translateX(0px) translateY(0px) rotateZ(0deg);}
	25%{transform: translateX(-5px) translateY(3px) rotateZ(20deg);}
	50%{transform: translateX(15px) translateY(1px) rotateZ(10deg);}
	100%{transform: translateX(0px) translateY(0px) rotateZ(0deg);}
}

@keyframes swing-left-ear {
	0%{transform: translateX(0px) translateY(0px) rotateZ(0deg);}
	25%{transform: translateX(-5px) translateY(6px) rotateZ(-20deg);}
	50%{transform: translateX(15px) translateY(2px) rotateZ(-10deg);}
	100%{transform: translateX(0px) translateY(0px) rotateZ(0deg);}
}

@keyframes swing-right-eye {
	0%{transform: translateX(0px) translateY(0px) rotateZ(0deg);}
	25%{transform: translateX(-5px) translateY(-3px) rotateZ(15deg);}
	50%{transform: translateX(15px) translateY(-1px) rotateZ(5deg);}
	100%{transform: translateX(0px) translateY(0px) rotateZ(0deg);}
}

@keyframes swing-left-eye {
	0%{transform: translateX(0px) translateY(0px) rotateZ(0deg);}
	25%{transform: translateX(-5px) translateY(-3px) rotateZ(15deg);}
	50%{transform: translateX(15px) translateY(-1px) rotateZ(5deg);}
	100%{transform: translateX(0px) translateY(0px) rotateZ(0deg);}
}

.star1{
	position: absolute;
	background-position: -356px -608px;
	display: block;
	top: 0px;
	left: -100px;
	width: 89px;
	height: 80px;
	animation: mr-star1 25s both 0s infinite;
}

.star2{
	position: absolute;
	background-position: -356px -608px;
	display: block;
	top: -130px;
	left: 500px;
	width: 89px;
	height: 80px;
	z-index: 2;
	animation: mr-star2 30s both 0s infinite;
}

.star3{
	position: absolute;
	background-position: -372px -532px;
	display: block;
	top: -230px;
	left: 180px;
	width: 58px;
	height: 67px;
	z-index: -2;
	animation: mr-star3 30s both 0s infinite;
}

.star4{
	position: absolute;
	background-position: -372px -532px;
	display: block;
	top: -530px;
	left: 750px;
	width: 58px;
	height: 67px;
	animation: mr-star4 22s both 0s infinite;	
}

@keyframes mr-star1 {
	from{ transform: translateX(-20px) translateY(-200px) rotateZ(0deg);}
	to{ transform: translateX(50px) translateY(2000px) rotateZ(360deg);}
}
@keyframes mr-star2 {
	from{ transform: translateX(-20px) translateY(-200px) rotateZ(0deg);}
	to{ transform: translateX(50px) translateY(2000px) rotateZ(-400deg);}
}
@keyframes mr-star3 {
	from{ transform: translateX(-20px) translateY(-200px) rotateZ(0deg);}
	to{ transform: translateX(50px) translateY(2000px) rotateZ(-360deg);}
}
@keyframes mr-star4 {
	from{ transform: translateX(-50px) translateY(-200px) rotateZ(0deg);}
	to{ transform: translateX(80px) translateY(2000px) rotateZ(360deg);}
}

            
          
!
999px
🕑 One or more of the npm packages you are using needs to be built. You're the first person to ever need it! We're building it right now and your preview will start updating again when it's ready.
Loading ..................

Console