cssAudio - Activefile-genericCSS - ActiveGeneric - ActiveHTML - ActiveImage - ActiveJS - ActiveSVG - ActiveText - Activefile-genericVideo - Activehtmlicon-personicon-teamoctocatpop-outspinnerstartv

Pen Settings

CSS Base

Vendor Prefixing

Add External CSS

These stylesheets will be added in this order and before the code you write in the CSS editor. You can also add another Pen here, and it will pull the CSS from it. Try typing "font" or "ribbon" below.

Quick-add: + add another resource

Add External JavaScript

These scripts will run in this order and before the code in the JavaScript editor. You can also link to another Pen here, and it will run the JavaScript from it. Also try typing the name of any popular library.

Quick-add: + add another resource

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.

            
              .container
  .circle
    div
    div
    div
    div
  .circle
    div
    div
    div
    div
            
          
!
            
              $body-back-color: #f4e8c1
$back-color: #a0c1b9


body
  background: $body-back-color
  
  .container
    position: relative
    height: 200px
    width: 230px
    //border: 1px solid red
    margin: 100px auto 50px auto
    
    .circle
      position: absolute
      height: 100px
      width: 100px
      background: $back-color
      border-radius: 50%
      animation: rotate 6s linear infinite
      
      &:nth-child(1)
        top: 10px
        left: 10px
      
      &:nth-child(2)
        top: 75px
        left: 110px
        animation-direction: reverse
      
      &::after
        content: ""
        position: absolute
        top: 50%
        left: 50%
        transform: translate(-50%, -50%)
        height: 50px
        width: 50px
        background: $body-back-color
        border-radius: 50%
      
      div
        position: absolute
        top: -10px
        left: 30px
        height: 120px
        width: 40px
        
        &:nth-child(2)
          transform: rotate(45deg)
        &:nth-child(3)
          transform: rotate(90deg)
        &:nth-child(4)
          transform: rotate(-45deg)
        
        
        &::after, &::before
          content: ""
          position: absolute
          width: 40px
          box-sizing: border-box
        
        &::before
          border-bottom: 60px solid $back-color
          border-left: 10px solid transparent
          border-right: 10px solid transparent
        
        &::after
          top: 60px
          border-top: 60px solid $back-color
          border-left: 10px solid transparent
          border-right: 10px solid transparent
        
    @keyframes rotate
      100%
        transform: rotate(1turn)
            
          
!
999px
Close

Asset uploading is a PRO feature.

As a PRO member, you can drag-and-drop upload files here to use as resources. Images, Libraries, JSON data... anything you want. You can even edit them anytime, like any other code on CodePen.

Go PRO

Loading ..................

Console