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

              
                <link href="//netdna.bootstrapcdn.com/font-awesome/4.0.3/css/font-awesome.css" rel="stylesheet">
<link rel="stylesheet" type="text/css" href="https://www.google.com/fonts#QuickUsePlace:quickUse/Family:Droid+Sans">

<div class="wrapper">
  <div class="weather">
    <div class="city"><h1>Toronto, On, Canada</h1></div>
          <div class="clearfix"></div>

    <div class="cont">
      <div class="icon">
        <i class="fa fa-sun-o spin glow"></i>
        <i class="fa fa-cloud wind"></i>
        <i class="fa fa-cloud two"></i>
      </div>
      <div class="temp">
        <div class="current">
          18&deg;
        </div>
        <div class="high">
          High: 20&deg;
        </div>
        <div class="low">
          Low: 5&deg;
        </div>
      </div>
      <div class="clearfix"></div>
      <div class="left"><i class="fa fa-angle-left"></i></div>
      <div class="date"><p>06/21/2013</p></div>
      <div class="right"><i class="fa fa-angle-right"></i></div>
    </div>
  </div> <!-- weather -->
</div> <!-- wrapper -->
              
            
!

CSS

              
                *{
  box-sizing: border-box;
  font-family: 'Droid Sans', sans-serif;
}
html,body,.wrapper{
  height:100%;
  width: 100%;
  padding: 0;
  margin: 0 auto;
}
.wrapper::before{
  content: "";
  background: rgba(0,0,0,0.2);
  position: absolute;
  top:0;
  left:0;
  height:100%;
  width: 100%;
}
.wrapper{
  background: url('https://s3-us-west-2.amazonaws.com/s.cdpn.io/45816/IMG_00000159_hdr.jpg');
  background-size: cover;
  background-attachment: fixed; 
  position: absolute;
}
.weather{
  position: relative;
  height: 275px;
  width: 400px;
background: #7abcff; /* Old browsers */
background: -moz-radial-gradient(center, ellipse cover,  #7abcff 0%, #60abf8 44%, #4096ee 100%); /* FF3.6+ */
background: -webkit-gradient(radial, center center, 0px, center center, 100%, color-stop(0%,#7abcff), color-stop(44%,#60abf8), color-stop(100%,#4096ee)); /* Chrome,Safari4+ */
background: -webkit-radial-gradient(center, ellipse cover,  #7abcff 0%,#60abf8 44%,#4096ee 100%); /* Chrome10+,Safari5.1+ */
background: -o-radial-gradient(center, ellipse cover,  #7abcff 0%,#60abf8 44%,#4096ee 100%); /* Opera 12+ */
background: -ms-radial-gradient(center, ellipse cover,  #7abcff 0%,#60abf8 44%,#4096ee 100%); /* IE10+ */
background: radial-gradient(ellipse at center,  #7abcff 0%,#60abf8 44%,#4096ee 100%); /* W3C */
filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#7abcff', endColorstr='#4096ee',GradientType=1 ); /* IE6-9 fallback on horizontal gradient */

  border-radius: 10px;
  top:calc(50% - 125px);
  left: calc(50% - 200px);
  border: 3px solid #FFFFFF;
  padding: 10px 20px;
}
.weather::after{
  width: 400px;
  height: 5px;
  background: red;
  position:absolute;
  top:15px;
}
.city h1{
  padding: 0;
  margin: 5px 0px;
  text-align: center;
  font-size: 11pt;
  text-transform: uppercase;
  color: #FFFFFF;
  font-weight: normal;
}
.icon{
  width: 50%;
  height:auto;
  float: left;
  padding: 10px;
  color: gold;
  margin: 10px 0;
  position: relative;
}
.icon .fa-sun-o{
  font-size: 88pt;
  position: absolute;
  text-shadow: 0 0 20px #fff;
}
.icon .fa-cloud{
  font-size: 58pt;
  position: absolute;
  top: 25px;
  right: 25px;
  color: rgba(255,255,255,0.90);
}
.icon .fa-cloud + .two{
  top: 15px;
  right: 5px;
  font-size: 48pt;
  color: #fff;
}
.temp{
  width: 50%;
  float: left;
  padding: 10px;
  color: #FFFFFF;
  margin: 5px 0;
}
.current{
  font-size: 68pt;
  text-align: center;
  font-weight: lighter;
}
.clearfix{
  clear:both;
  width: 100%;
  border-top: 3px solid #FFFFFF;

}
.left,.date,.right{
  float: left;
  width: 33%;
  height: 35px;
  margin: 0 auto;
  padding: 0;
}
.left i, .right i{
  font-size: 38pt;
  color: #FFFFFF;
  position: relative;
  top: -5px;
}
.date{
  text-align: center;
  position: relative;
  top: -15px;
  color: #FFFFFF;
  font-size: 18pt;
  
}
.right{
  text-align: right;
  
}
.spin {
  animation: spin 60s linear infinite,
    glow 10s linear infinite;
}
@keyframes spin{
  100%{
    transform: rotate(360deg);
  }
}
.wind{
  animation: wind 7.5s ease-in-out infinite;
}
@keyframes wind{
  50%{
     top: 30px;
     right: 15px;
  }
}
.glow{
  animation: ;
}
@keyframes glow{
  50%{
     text-shadow: 0 0 5px #fff; 
  }
}
              
            
!

JS

              
                
              
            
!
999px

Console