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

              
                <!DOCTYPE html>
<html lang="en-US">
    <head>
        <meta charset="utf-8">
        <title>Bird Watching</title>
        <meta name="author" content="Abhinav Juyal">
        <meta name="description" content="This one of the assignments provided by MDN Web Docs : Learn Web Development">
        <link rel="stylesheet" href="styles/style.css">
        <link href="https://fonts.googleapis.com/css?family=Cinzel+Decorative|Roboto+Condensed&display=swap" rel="stylesheet">
    </head>
    <body>
        <header> 
            <h1>Bird Watching</h1>
            <img src="images/dove.png">
            <nav>
                <ul>
                    <li><a href="#">HOME</a></li>
                    <li><a href="#">GET STARTED</a></li>
                    <li><a href="#">PHOTOS</a></li>
                    <li><a href="#">GEAR</a></li>
                    <li><a href="#">FORUM</a></li>
                </ul>
            </nav>
        </header>
        <main>
            <section>
                 <h2>WELCOME</h2>
                    <p>Welcome to our fake birdwatching site. If this were a real site, it would be the 
                     ideal place to come to learn about birdwatching, whether you are a 
                     beginner looking to learn how to get into birding, or an expert wanting to share
                     ideas, tips, and photos with other like-minded people.
                    </p>
                    <p>So don't waste time! Get what you need, then turn off that ciomputer and get out into the great outdoors!</p>
            </section>
            <aside>
                <h2>FAVOURITE PHOTOS</h2>
                    <a href="images/favorite-1_th.jpg"><img src="images/favorite-1.jpg"></a>
                    <a href="images/favorite-1_th.jpg"><img src="images/favorite-2.jpg"></a>
                    <a href="images/favorite-1_th.jpg"><img src="images/favorite-3.jpg"></a>
                    <a href="images/favorite-1_th.jpg"><img src="images/favorite-4.jpg"></a>
            </aside>
    </main>
    <footer>
        <p>This fake website example is CC) - any part of this code may be reused in any way you wish. Original example written 
            Chris Mills, 2016.
        </p>
        <p><a href="#">Dove icon</a> by Lorc.</p>
    </footer>
    </body>
</html>
              
            
!

CSS

              
                /* || General setup */

html, body {
  margin: 0;
  padding: 0;
}

html {
  font-size: 10px;
  background-color: #a9a9a9;
}

body {
  width: 70%;
  min-width: 800px;
  margin: 0 auto;
}

/* || typography */

h1, h2, h3 {
  font-family: 'Cinzel Decorative', cursive;
  color: #2a2a2a;
}

p, input, li {
  font-family: 'Roboto Condensed', sans-serif;
  color: #2a2a2a;
}

h1 {
  font-size: 4rem;
  text-align: center;
  text-shadow: 2px 2px 10px black;
}

h2 {
  font-size: 3rem;
  text-align: center;
}

h3 {
  font-size: 2.2rem;
}

p, li {
  font-size: 1.6rem;
  line-height: 1.5;
}

/* || header layout */

header {
  margin-bottom: 10px;
  display: flex;
  flex-flow: row wrap;
}

body > * {
  background-color: red;
  padding: 1%;
}

main, header, nav, article, aside, footer, section {
  background-color: rgba(0,255,0,0.5);
  padding: 1%;
}

h1 {
  flex: 5;
  text-transform: uppercase;
}

header img {
  display: block;
  height: 60px;
  padding-top: 20.15px;
}

nav {
  height: 50px;
  flex: 100%;
  display: flex;
}

nav ul {
  padding: 0;
  list-style-type: none;
  flex: 2;
  display: flex;
}

nav li {
  display: inline;
  text-align: center;
  flex: 1;
}

nav a, nav span {
  display: inline-block;
  font-size: 2rem;
  height: 3rem;
  line-height: 1.7;
  text-transform: uppercase;
  text-decoration: none;
  color: black;

}

/* || main layout */

main {
  display: flex;
}

article, section {
  flex: 4;
}

aside {
  flex: 1;
  margin-left: 10px;
  padding: 1%;
}

aside a {
  display: block;
  float: left;
  width: 50%;
}

aside img {
  max-width: 100%;
}

footer {
  margin-top: 10px;
}

              
            
!

JS

              
                    
              
            
!
999px

Console