Pen Settings

HTML

CSS

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

JavaScript

Babel is required to process package imports. If you need a different preprocessor remove all packages first.

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

Behavior

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.

Format on Save

If enabled, your code will be formatted when you actively save your Pen. Note: your code becomes un-folded during formatting.

Editor Settings

Code Indentation

Want to change your Syntax Highlighting theme, Fonts and more?

Visit your global Editor Settings.

HTML

              
                <div class="camera-body"></div>
              
            
!

CSS

              
                $teal: #39a4a1;
$brown: #736260;
$darkbrown: #5e4b45;
$yellow: #f3ad4d;
$beige: #f3efda;
$red: #ff5b45;
$grey: #ececec;

body {
  background-color: #e8d5b3;
}

.camera-body::before{
  content:"";
  position: absolute;
  left:348px;
  top: -150px;
  z-index: -1;
  padding:50px;
  width:30px;
  height:30px;
  border-radius: 50%;
  background:
    radial-gradient(circle, transparent 35%, 
      $teal 35%, $teal 40%, 
      $beige 40%, $beige 45%,
      $brown 45% ),
    radial-gradient($grey 40%, transparent 40%),
radial-gradient(white, white);
  background-position: 0 0, 10px 10px, 00;
}

.camera-body{
  position: relative;
  z-index: 1;
  width:500px;
  height:300px;
  margin:190px auto 50px;
  background: 
    radial-gradient(circle, transparent 35%, $grey 35%, $grey 37%, $yellow 37%, $yellow 45%, $darkbrown 45%, $darkbrown 51%, transparent 51%),
 radial-gradient( circle, $grey 35%, transparent 35%),
     radial-gradient(circle, white 35%, transparent 35%),
    linear-gradient($teal 25%, $beige 25%, $beige 35%, $red 35%, $red 45%, $yellow 45%, $yellow 55%, $brown 55%, $brown 65%, $beige 65%, $beige 75%, $teal 75%);
  background-position: 0 0, 20px 30px, 0 0, 0 0;
    border-radius:25px;
    box-shadow: 
      -45px -160px 0px -140px #e8d5b3,
      -100px -160px 0px -140px $darkbrown,
      30px -165px 0px -135px #e8d5b3,
      65px -165px 0px -135px $grey,
      
      ;
}

.camera-body::after{
  content:"";
  padding: 17px 32px;
  border-radius: 10%;
  border:3px solid $brown;
  position: absolute;
  top: 15px;
  right: 25px;
  background: linear-gradient( $beige     9%, 
    $brown 9%, $brown 18%,
    $beige 18%, $beige 27%,
    $brown 27%, $brown 36%,
    $beige 36%, $beige 45%,
    $brown 45%, $brown 54%,
    $beige 54%, $beige 63%,
    $brown 63%, $brown 72%,
    $beige 72%, $beige 81%,
    $brown 81%, $brown 90%,
    $beige 90% );
}

              
            
!

JS

              
                
              
            
!
999px

Console