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.

HTML Settings

Here you can Sed posuere consectetur est at lobortis. Donec ullamcorper nulla non metus auctor fringilla. Maecenas sed diam eget risus varius blandit sit amet non magna. Donec id elit non mi porta gravida at eget metus. Praesent commodo cursus magna, vel scelerisque nisl consectetur et.

            
              .container
  .content
    .satellite-wrap
      .satellite
    .planet
      .ring
    .sides
  .distant-planet1
  .distant-planet2
            
          
!
            
              // Z-INDEXes
$z-background: -1;

// COLOR VRIABLES
$snow: #ffffff;
$tar: #000000;
$background: #0e2875;

// MIXINS
@mixin Object($w,$h,$b,$l,$z,$bg) {
  position: absolute;
  content: "";
  width: $w;
  height: $h;
  bottom: $b;
  left: $l;
  z-index: $z;
  background: $bg;
}

@mixin Transform($transforms) {
	   -moz-transform: $transforms;
	     -o-transform: $transforms;
	    -ms-transform: $transforms;
	-webkit-transform: $transforms;
          transform: $transforms;
}

@mixin Keyframes($name) {
  @-webkit-keyframes #{$name} {
    @content; 
  }
  @-moz-keyframes #{$name} {
    @content;
  }
  @-ms-keyframes #{$name} {
    @content;
  }
  @keyframes #{$name} {
    @content;
  } 
}

@mixin Animation($content){
  -webkit-animation: $content;
	-moz-animation: $content;
	animation: $content;
}

// FONTS

@import url(https://fonts.googleapis.com/css?family=Eczar:700);

// boilerplate CSS

body {
  height: 100vh;
  background: $snow;
  display: flex;
  justify-content: center;
  align-items: center;
}
.container {
  position: relative;
  z-index: -1;
  width: 720px;
  height: 500px;
  background: $background;
  border: 4px solid $tar;
  overflow: hidden;
  
  background-color:#0e2875;
background-image:
radial-gradient(white, rgba(255,255,255,.2) 2px, transparent 40px),
radial-gradient(white, rgba(255,255,255,.15) 1px, transparent 30px),
radial-gradient(white, rgba(255,255,255,.1) 2px, transparent 40px),
radial-gradient(rgba(255,255,255,.4), rgba(255,255,255,.1) 2px, transparent 30px);
background-size: 550px 550px, 350px 350px, 250px 250px, 150px 150px; 
background-position: 0 0, 40px 60px, 130px 270px, 70px 100px;
}

// GET SET ART //

/* content */
.content{}

.planet{
  @include Object(200px,200px,20%,40%,10,#f4242d);
  border-radius: 100%;
  perspective: 1000px;
  transform-style: preserve-3d;
  background: #CB356B;  
background: -webkit-linear-gradient(to right, #f4242d, #CB356B); 
background: linear-gradient(to right, #f4242d, #CB356B);

}

.sides{
  @include Object(220px,220px,17.5%,38.5%,10,transparent);
  border-radius: 100%;
    border: 3px solid #f4242d;
    -webkit-clip-path: polygon(49% 0, 89% 0, 88% 100%, 72% 100%);
clip-path: polygon(49% 0, 89% 0, 88% 100%, 72% 100%);
  }

.ring{
  @include Object(400px,400px,-50%,-55%,50,transparent);
  border: 15px solid #ffffff;
  border-radius: 100%;
  transform: rotate3d(.8,0, 0, 75deg);
    animation: ring 1s 0s infinite ease-out;
}

.satellite-wrap{
  @include Object(30px,241px,24%,52%,50,transparent);
transform-origin: bottom;
  animation: satellite 1s 0s infinite linear;
}
.satellite{
  @include Object(30px,30px,88%,2%,50,#87e6b6);
  border-radius: 100%;
}

.distant-planet1{
  @include Object(10px,10px,85%,11%,50,#4d64c1);
  border-radius: 100%;
  &:before{ @include Object(110px,50px,-22px,-53px,50,transparent);
    border: 2px solid #4d64c1;
  border-radius: 100%;
    transform: rotate3d(.8,0.4,0.2, 35deg);
  }
  &:after{
    @include Object(6px,6px,10px,40px,55,#4d64c1);
    border-radius: 100%;
    box-shadow: -60px 10px 0 -1px #4d64c1;
  }
}


.distant-planet2{
  @include Object(10px,10px,12%,88%,50,#4d64c1);
  border-radius: 100%;
   &:before{ @include Object(60px,20px,-8px,-25px,50,transparent);
    border: 2px solid #4d64c1;
  border-radius: 100%;
    transform: rotate3d(.8,0.9,0.2, 35deg);
  }
}
@keyframes satellite{
  0%{
    transform: rotateZ(65deg);
  }
  50%{
    transform: rotateZ(-65deg);
  }
  100%{
    transform: rotateZ(65deg);
  }
}

@keyframes ring{
  0%{
transform: rotate3d(.8,-0.05, 0, 75deg);
  }
  10%{
transform: rotate3d(.8,-0.04,0,75deg);
  }
  20%{
transform: rotate3d(.8,-0.03,0,75deg);
  }
  30%{
transform: rotate3d(.8,-0.02,0,75deg);
  }
  40%{
transform: rotate3d(.8,-0.01,0,75deg);
  }
  50%{
transform: rotate3d(.8,-0.00,0,75deg);
  }
  60%{
transform: rotate3d(.8,-0.01,0,75deg);
  }
  70%{
transform: rotate3d(.8,-0.02,0,75deg);
  }
  80%{
transform: rotate3d(.8,-0.03,0,75deg);
  }
  90%{
transform: rotate3d(.8,-0.04,0,75deg);
  }
  100%{
transform: rotate3d(.8,-0.05,0,75deg);
  }
}
            
          
!
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.

Console