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. You can use the CSS from another Pen by using it's URL and the proper URL extention.

+ 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

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

              
                <link
  rel="stylesheet"
  href="https://use.fontawesome.com/releases/v5.8.1/css/all.css"
  integrity="sha384-50oBUHEmvpQ+1lW4y57PTFmhCaXp0ML5d60M1M7uH2+nqUivzIebhndOJK28anvf"
  crossorigin="anonymous"
/>
<script src="https://cdn.freecodecamp.org/testable-projects-fcc/v1/bundle.js"></script>
<div id="main-page">
  <header id="header">
    <div>
      
      
      <img id="header-img" src="https://lh3.googleusercontent.com/zDicHL6AhZhh3r4tGM_TAFkOPKKvrHiwB3IK_K2DehBUVKxUobFjBfgS9WIwXpfCmrK0GKp8M29WGgUBxgDRm5192iX9R67nvJQ8zqcCujIbGl-NOo7W7FlHRQ0V5rDKjb3tNbnE=w2400"
alt="headphone image">
</div>
    <nav id="nav-bar">
      <ul>
        <li id="li1"><a class="nav-link" href="#products"><b>Products</b></a></li>
        <li id="li2"><a class="nav-link" href="#how-it-works"><b>How it works</b></a></li>
        <li id="li3"><a class="nav-link" href="#shipping"><b>Shipping</b></a></li>
      </ul>
    </nav>
      
  </header>
  <div class="container"></div>
  <section id="sectin">
    <h1>Quality headphones for every style</h1>
    <form id="form"  action="https://www.freecodecamp.com/email-submit">
      <input id="email"
      name="email"
      type="email"
      placeholder="Enter your email"
      required
             ></input>
    <input id="submit" type="submit" value="Get Started" class="button"></input>
  </form>
    </section>
<div class="container">
  <section id="features">
    <div class="grid">
      <div class="icon"><i 
      class="fa fa-3x fa-fire"></i></div>
      <h2>Premium Materials</h2>
      <p>Our headphone drivers are selected carefully for for customer's confort like its other parts. This will increase its life.</p>
    </div>
    <div class="grid">
      <div class="icon"><i 
      class="fa fa-3x fa-truck"></i></div>
      <div class="desc" id="shipping"><br>
        <h2>Fast Shipping</h2>
        <p>Thanks to our hard-working employers and deliveries, we can ship our products in no time. We also provide free returns if you are not satisfied.</p>
    </div>
    <div class="grid"><br>
      <div class="icon"><i 
      class="fa fa-3x fa-battery-full"></i></div>
      <div class="desc"><br>
        <h2>Quality Assurance</h2>
        <p> For every purchase you make, we will ensure there are no damages or
            faults and we will check and test the pitch of your headphone.</p>
      </div>
    </div>
  </section>
    <section id="how-it-works">
        <iframe id="video" width="560" height="315" src="https://www.youtube.com/embed/z6Aa-o6tAUA" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>           
    </section>
    <section id="products">
      <div id="over-ear" class="product">
        <div class="level">Over-ear Headphone
        
        <ol>
          <li>Less sound leaking than others</li>
          <li>Strong bass system</li>
          <li>High-quality drivers</li>
          <li>Nice and confortable earholders</li>
        </ol>
          <h2>49.99$</h2>
          <button class="btn">Select</button></div>
      </div>
      <div class="product" id="On-ear">
        <div class="level"><p>On-ear Headphone</p>
        
        <ol>
          <li>Excellent sound flow</li>
          <li>Pure confort</li>
          <li>Long battery life</li>
        </ol>
        <h2>38.99$</h2>
        <button class="btn">Select</button>
      </div>
      </div>
    </section>

</div>
      <footer>
      <ul>
        <li><a href="#">Privacy</a></li>
        <li><a href="#">Terms</a></li>
        <li><a href="#">Contact</a></li>
      </ul>
      <span>Copyright 2016, Original Headphones</span>
    </footer>
</div>
              
            
!

CSS

              
                
@import 'https://fonts.googleapis.com/css?family=Lato:400,700';

#header-img {
  width:200px;
  height: 200px;
  background: transparent;
  position: relative;
}

* {
  margin: 0px;
  padding: 0px;
  box-sizing: border-box;
  background-color: #52FFEE;
}

body {
  font-family: 'Lato', sans-serif;
}

#page-wrapper {
  position: relative;
}

.container {
  max-width: 1000px;
  width: 100%;
  margin: 0 auto;
}

.btn {
  margin: 0 auto;
  height: 40px;
  width: 100px;
  border: 3px #DCFFFD solid;
  box-shadow: 1px 1.5px 1px 1.5px;
  border-radius: 2px;
  margin-top: 10px;
  margin-bottom: 15px;
  transition: 2s;
}

.btn:hover {
  background-color: green;
  color: darkorange;
  cursor: pointer;
}

.grid {
  display: flex;
}

header {
  justify-content: space-around;
  align-items: center;
  display: flex;
  padding: 0px 20px;
} 

#nav-bar > ul {
  list-style: none;
  width: 35vw;
  display: flex;
  flex-direction: row;
  justify-content: space-around;
}

#submit {
  border-color: transparent;
  cursor: pointer;
  margin-top: 20px;
  transition: 1s;
}

#submit:hover {
  color: #F40076;
  padding: 10px;
  width: 120px;
}

#email {
  transition: 1s;
}

#email:hover {
  padding: 10px;
  width: 220px;
}

a {
  text-decoration: none;
  display: inline-block;
  color: #002A32;
}

a:hover {
  cursor: pointer;
  color: #F40076;
}

a:visited {
  color: #002A32;
}

#email, #submit {
  border-radius: 5px;
}

nav li {
  padding-bottom: 5px;
}

nav > ul {
  flex-direction: row;
}

#sectin {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  height: 50px;
  margin-top: 20px;
  margin-bottom: 30px;
}

#features .icon {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 125px;
  width: 20vw;
}

iframe {
  position: relative;
  justify-content: center;
  display: flex;
  margin: auto;
}

.level {
  border: 2px solid darkgreen;
  text-align: center;
  display: flex;
  max-width: auto;
  height: 150px;
  padding: 10px;
  box-shadow: 0.5px 1.5px 1.5px 1.5px;
  border-radius: 5px;
  margin-top: 30px;
  margin-bottom: 30px;
}
h2 {
  padding: 5px;
  padding-right: 10px;
}

ol li {
  list-style: none;
}

.grid {
  margin: auto;
  position: relative;
  padding: auto;
}

footer {
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
  justify-content: center;
}

@media (max-width: 800px) {
  body {
    background-color: lightblue;
  }
}

ul {
  list-style: none;
  display: flex;
  flex-direction: row;
  flex-wrap: wrap;
}

.nav-link {
  display: flex;
  width: 50px;
}

#lmao {
  display: flex;
  width: 30px;
}

#products {
  display: flex;
  flex-direction: row;
  align-items: center;
  width: 100%;
}

#over-ear {
  margin-right: 30px
}

#On-ear {
  margin-left: 30px;
}

#nav-bar {
  position: fixed;  
  top: 20px;
  right: 20px;
}

#header {
  position: relative;
  top: 1px;
}
              
            
!

JS

              
                <script>https://cdn.freecodecamp.org/testable-projects-fcc/v1/bundle.js</script>

              
            
!
999px

Console