Pen Settings

HTML

CSS

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URLs added here will be added as <link>s in order, and before the CSS in the editor. You can use the CSS from another Pen by using its URL and the proper URL extension.

+ add another resource

JavaScript

Babel includes JSX processing.

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

Packages

Add Packages

Search for and use JavaScript packages from npm here. By selecting a package, an import statement will be added to the top of the JavaScript editor for this package.

Behavior

Auto Save

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

              
                <!DOCTYPE html>
<html>
<head>
    <title></title>
    <link href="https://fonts.googleapis.com/css?family=Coustard:900" rel="stylesheet">
   
</head>
<body>
    
    <div class="backg">
        <div class="sand">
           
        </div>
        <div class="tower">
            <div class="s1"></div>
            <div class="s2"></div>
            <div class="door1"></div>
            <div class="door2"></div>
            <div class="balcony">
                <div class="b1"></div>
                <div class="b2"></div>
                <div class="b3"></div>
                <div class="b4"></div>
                <div class="b5"></div>
                <div class="b6"></div>
                <div class="b7"></div>
                <div class="b8"></div>
                <div class="b9"></div>
            </div>
            <div class="s3"></div>
            <div class="s4"></div>
            <div class="dome"></div>
            <div class="glass"></div>
            <div class="s5"></div>
            <div class="light"></div>
            <div class="sand1"></div>
            <div class="sand2"></div>
           
        </div>
    </div>
</body>
</html>
              
            
!

CSS

              
                body{
         background-color: #99ddff;
         overflow-x:hidden;
    
    }
        .backg{
           height: 510px;
           width: 350px;
           margin: auto;
           left:0;
           right: 0;
          top:0;
          bottom:0;
           position: absolute;
        }
        .sand{
            background-color: #ffc34d;
            height:100px;
            width: 350px;
            border-radius:175px 175px 0px 0px; 
            position: relative; 
            top:410px;
        }
        a{
            position:relative;
            font-size:20px;
           top:60px;
            left:90px;
            z-index:5;
            color:black;
        }
        .tower{
            height: 0px;
            width: 120px;
            border-bottom: 300px solid white;
            border-left: 20px solid transparent;
            border-right: 20px solid transparent;
            position: relative;
            left:95px;
            top:70px;
        }
        .s1{
            position: relative;
            top: 190px;
            right: 16px;
            height: 0px;
             width: 147px;
            border-bottom: 25px solid tomato;
            border-left: 2px solid transparent;
            border-right: 2px solid transparent;
        }
        .s2{
            position: relative;
            top: 10px;
            right: 5px;
            height: 0px;
             width: 126px;
            border-bottom: 25px solid tomato;
            border-left: 2px solid transparent;
            border-right: 2px solid transparent;
        }
        .door1,.door2{
            width: 60px;
            height:70px;
            border-radius:35px 35px 0px 0px;
            background-color: #006781;  
            position: relative;
            left:30px;
        }
        .door1{
            top:180px;
        }
        .door2{

            bottom: 25px;
        }
        .balcony{
            background-color: transparent;
            height:25px;
            width: 180px;
            border:5px solid #006781;
            position: relative; 
            right:35px;
            bottom: 55px; 
        }
        .b1,.b2,.b3,.b4,.b5,.b6,.b7,.b8{
            height: 25px;
            width:5px;
            background-color: #006781;
            position: relative;
            
        }
        .b1{
            left:15px;
        }
        .b2{
            left:30px;
            bottom: 25px;
        }
        .b3{
            left:45px;
            bottom: 50px;
        }
        .b4{
            left:60px;
            bottom: 75px;
        }
        .b5{
            left:115px;
            bottom: 100px;
        }
        .b6{
            left:135px;
            bottom: 125px;
        }
        .b7{
            left:150px;
            bottom: 150px;
        }
        .b8{
            left:165px;
            bottom: 175px;
        }
        .b9{
            left:180px;
            bottom: 200px;
        }
        .s3{
            background-color: #006781;
            height: 30px;
            width: 170px;
            position: relative;
            bottom: 220px;
            right: 25px;
        }
        .s4{
            background-color: #006781;
            height: 30px;
            width: 120px;
            position: relative;
            bottom: 270px;
            right: 1px;
        }
        .dome{
            height:60px;
            width: 120px;
            border-radius: 60px 60px 0px 0px; 
            background-color: white;
            position: relative;
            bottom: 390px;
            right: 1px;

        }
        .glass{
            background-color: rgba(255,255,255,0.5);
            width:120px;
            height: 35px;
            position: relative; 
            bottom: 390px;
            right: 1px;
        }
        .s5{
            width: 120px;
            height: 8px;
            background-color: white;
            position: relative;
            bottom: 395px;
            right: 1px;
        }
        .light{
            width: 120px;
            border-right: 250px solid rgba(255, 255, 51,0.7);
            border-top: 40px solid transparent;
            border-bottom:40px solid transparent;
            position: relative;
            bottom: 455px;
            right: 0px;
            animation:search 4s infinite;

        }
        @keyframes search{
            50%{
                transform: translateX(-250px) rotateY(180deg);
            }
        }
        .sand1{
            height: 50px;
            width: 70px;
            background-color: #ffc34d;
            border-radius: 50%;
            position: relative;
            bottom: 195px;
            right: 40px;
        }
        .sand2{
            height: 30px;
            width: 30px;
            background-color: #ffc34d;
            border-radius: 50%;
            position: relative;
            bottom: 230px;
            margin-left: 25px;
        }
        h1,h2{
            color:#006781;
            text-align: center;
        }
        h1{
            font-size:50px; 

        }
        h2{
            font-family: 'Coustard', serif;
            font-size: 30px;
        }
              
            
!

JS

              
                
              
            
!
999px

Console