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

              
                <head>
  <link href="https://fonts.googleapis.com/css?family=Open+Sans" rel="stylesheet">
  <meta name="viewport" content="width=device-width, initial-scale=1"> 
</head>
<div id="wrapper">
<header>
  <span>Gene Roddenberry</span>
  <a href="https://en.wikipedia.org/wiki/Gene_Roddenberry" target="blank"><button class="btn btn-primary">Read more</button></a>
</header>
<div id="body">
  <figure>
    <img src="http://media.liveauctiongroup.net/i/8790/10015084_1.jpg?v=8CD562C9E496D70" caption="1921-1991"></img>
  <figcaption>1921-1991</figcaption>
  </figure>
  <div id="content">
  <h1>The man who made Star Trek</h1>
  <p>On September 8th 1966 Gene Roddenberry launched a television phenomenon that would forever change the face of science fiction. Star Trek: The Original Series followed the 23rd-century, interstellar adventures of Captain James T. Kirk and his crew of the Federation Starship, Enterprise. 21 years after its first airing of The Original Series, Gene Roddenberry amazed audiences by re-launching the franchise with its most successful series to date: Star Trek: The Next Generation. Fifty years after its initial airing, the Star Trek franchise includes five live-action television shows, one animated series and thirteen feature-length films.</p>
<p>Source:</p>
<p><a href="http://www.roddenberry.com/entertainment/#star-trek">http://www.roddenberry.com/entertainment/#star-trek</a></p>
    <q>We must question the story logic of having an all-knowing all-powerful God, who creates faulty Humans, and then blames them for his own mistakes.</q>
</div>
</div>
<div id="footer">
  <span>Created by Michael Coffey</span>
</div>
</div>
              
            
!

CSS

              
                /*header*/
header{
  height: 45px;
  border-bottom: 1px solid black;
  text-align:center;
}
header span{
  display:inline-block;
  font: bold 25px 'Open Sans', sans-serif;
  margin-top: 4px;
}
button{
  float: right;
  margin-top: 6px;
  margin-right: 10px;
}
/*body*/
#body{
  margin: 20px 20px;
}
figure{
  float: right;
  margin-top: 20px;
  margin-right: 20px;
}
img{
  height:300px;
  border-radius: 20px;
}
figcaption{
  font-family: 'Open Sans';
  text-align: center;
}
q{
  font: italic 20px serif;
  color: gray;
}
q:hover{
  color: black;
}
#content{
  width: 70%;
  font-size: 110%
}
#wrapper{
  min-height: 100%;
}
#footer{
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 40px;
  border-top: 1px solid black;
  text-align: center;
}
#footer span{
  display: inline-block;
  font-family: 'Open Sans';
  margin-top: 8px;
}
@media only screen and (max-width: 700px) {
  figure{
    display: block;
    float: none;
    width: 100%;
    text-align: center;
  }
  #content{
    width: 100%;
  }
  #footer{
    position: relative;
  }
}
@media only screen and (max-width: 600px) {
  header span{
    font-size: 20px;
    margin-top: 10px;
  }
}
              
            
!

JS

              
                
              
            
!
999px

Console