cssAudio - Activefile-genericCSS - ActiveGeneric - ActiveHTML - ActiveImage - ActiveJS - ActiveSVG - ActiveText - Activefile-genericVideo - ActiveLovehtmlicon-new-collectionicon-personicon-teamlog-outoctocatpop-outspinnerstartv

Pen Settings

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

You're using npm packages, so we've auto-selected Babel for you here, which we require to process imports and make it all work. If you need to use a different JavaScript preprocessor, remove the packages in the npm tab.

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

Use npm Packages

We can make npm packages available for you to use in your JavaScript. We use webpack to prepare them and make them available to import. We'll also process your JavaScript with Babel.

⚠️ This feature can only be used by logged in users.

Code Indentation

     

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.

            
              <script src="https://cdn.freecodecamp.org/testable-projects-fcc/v1/bundle.js"></script>
  <header id="header" class="header">
    <a href="#features" class="logo-link">
      <img id="header-img" class="header-img" src="https://openclipart.org/download/232062/Logo-Logo-Grayscale.svg" alt="">
      <h1 class="header-title">Free Coding School</h1>
    </a>
    <nav id="nav-bar" class="nav-bar">
      <a class="nav-link" href="#features">Features</a>
      <a class="nav-link" href="#demo">Demo</a>
      <a class="nav-link" href="#newsletter">Newsletter</a>
    </nav>
  </header>
  <main class="main">
    <div class="features" id="features">
      <h2 class="page-title">Learn to code for free with us</h2>
      <p class="page-text">You can start to learn to programme with us for free right now. We offer you many courses which are continuously developing by our volunteers and there are always actual. Read more below and check out our demo video.
      </p>
      <ul class="page-list">
        <li>
          <h3 class="page-list-title">Lessons are easy to understand</h3>
          <p class="page-list-text">One of our goals is giving knowledge in a clear and easy way.</p>
        </li>
        <li>
          <h3 class="page-list-title">Video lessons</h3>
          <p class="page-list-text">Most of the lessons have a short video which shows you how new things works.</p>
        </li>
        <li>
          <h3 class="page-list-title">Many practical examples</h3>
          <p class="page-list-text">Carefully chosen examples are often very useful and ready to use in your projects.</p>
        </li>
        <li>
          <h3 class="page-list-title">A lot of exercises</h3>
          <p class="page-list-text">Each lesson has a lot of short exercises to practice which show you many possibilities.</p>
        </li>
        <li>
          <h3 class="page-list-title">Many projects to build</h3>
          <p class="page-list-text">Each module of lessons has at the end a smaller or bigger project to build.</p>
        </li>
      </ul>
    </div>

    <div class="demo" id="demo">
      <h2 class="page-title">Watch the video about us</h2>
      <iframe id="video" class="iframe" src="https://www.youtube.com/embed/PQ22pgaXog4" title="the demo video" allow="autoplay; encrypted-media" allowfullscreen>
      </iframe>
    </div>

    <div class="newsletter" id="newsletter">
      <h2 class="page-title">Subscribe to receive our lessons on your email</h2>

      <form id="form" class="form" action="https://www.freecodecamp.com/email-submit" method="post">
        <label class="form-label" for="email">Email:</label>
        <input type="email" id="email" class="input-email" name="email" placeholder="Enter your email here" required>
        <input type="submit" id="submit" class="input-submit" value="Subscribe">
      </form>
    </div>
  </main>
  <footer class="footer">
    <span>Created by <a class="footer-link" target="_blank" href="http://mybytes.pl/">Sebastian Sporek</a></span>
  </footer>
            
          
!
            
              html {
  font-size: 20px;
  font-family: 'Lato', sans-serif;
}

body {
  background-color: #f9f9eb;
  color: black;
  margin: 0;
  padding: 0;
  -webkit-box-sizing: border-box;
          box-sizing: border-box;
}

.header {
  border-bottom: 2px solid black;
  padding: 0px 10px;
  -webkit-box-sizing: border-box;
          box-sizing: border-box;
  display: -webkit-box;
  display: -ms-flexbox;
  display: flex;
  -ms-flex-wrap: wrap;
      flex-wrap: wrap;
  -webkit-box-pack: center;
      -ms-flex-pack: center;
          justify-content: center;
  -webkit-box-align: baseline;
      -ms-flex-align: baseline;
          align-items: baseline;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background-color: #f9f9eb;
}

.logo-link {
  text-decoration: none;
  display: block;
}

.header-img {
  width: auto;
  height: 20px;
  display: inline-block;
  margin-top: 10px;
}

.header-title {
  display: inline-block;
  font-size: 1.20rem;
  line-height: 1.25rem;
  margin: 0;
  color: #004d00;
  margin-top: 10px;
}

.nav-bar {
  display: block;
  margin-top: 10px;
}

.nav-link:nth-child(2) {
  margin-left: 8px;
  margin-right: 8px;
}

.nav-link {
  display: inline-block;
  margin-bottom: 10px;
  text-decoration: none;
  font-size: 1rem;
  color: #004d00;
}

.nav-link:hover {
  -webkit-box-shadow: 0 2px 0px 0px #004d00;
          box-shadow: 0 2px 0px 0px #004d00;
}

.features {
  -webkit-box-sizing: border-box;
          box-sizing: border-box;
  padding: 80px 10px 0px;
  background-color: #f9f9eb;
}

.page-title {
  font-size: 1.15rem;
  text-align: center;
  margin-bottom: 1.5rem;
}

.page-text {
  text-align: justify;
  font-size: 1rem;
  line-height: 1.2em;
}

.page-list {
  list-style: none;
  padding: 0;
  max-width: 800px;
  margin: 0 auto;
}

.page-list li:before {
  content: "\2714";
  font-size: 1.1rem;
  line-height: 1.5rem;
  margin-right: 0.5rem;
  display: inline;
  color: #004d00;
}

.page-list-title {
  font-size: 1.1rem;
  line-height: 1.5rem;
  display: inline;
  margin: 0;
  font-weight: normal;
}

.page-list-text {
  margin: 0 0 1rem 30px;
}

.demo {
  padding: 80px 10px 0px;
}

.iframe {
  display: block;
  width: 100%;
  height: calc((480 / 853) * (100vw - 20px));
  max-width: 853px;
  max-height: 480px;
  margin: 0 auto;
  border: 0;
}

.newsletter {
  padding-top: 80px;
}

.form {
  -webkit-box-sizing: border-box;
          box-sizing: border-box;
  width: 100%;
  padding: 10px;
  padding-bottom: 50px;
}

.form-label{
  margin-left: 10px;
}

.input-email {
  display: block;
  -webkit-box-sizing: border-box;
          box-sizing: border-box;
  width: calc(100% - 20px);
  margin: 0.5rem auto 1.5rem;
  padding: 0.5rem;
  background-color: #f9f9eb;
  color: black;
  font-size: 1rem;
  outline: 0;
}

.input-email:required {
  border: 2px solid #004d00;
}

.input-email:invalid:focus {
  border: 2px solid red;
}

.input-email:valid {
  border: 2px solid #004d00;
  background-color: #f9f9eb;
}

.input-submit {
  display: block;
  margin: 0 auto 1rem;
  font-size: 1.25rem;
  color: white;
  padding: 0.5rem 1rem;
  letter-spacing: .1em;
  background-color: #004d00;
  border: 2px solid #004d00;
}

.input-submit:hover {
  cursor: pointer;
  -webkit-box-shadow: 0px 0px 0px 2px #004d00 inset, 0px 0px 0px 4px white inset;
          box-shadow: 0px 0px 0px 2px #004d00 inset, 0px 0px 0px 4px white inset;
}

.footer {
  border-top: 2px solid black;
  text-align: center;
  font-style: italic;
  font-size: 0.75rem;
  padding: 1rem;
  letter-spacing: 1px;
}

.footer-link:visited, .footer-link:active, .footer-link:link {
  color: black;
}

@media (min-width: 700px) {
  .header {
    -webkit-box-pack: start;
        -ms-flex-pack: start;
            justify-content: flex-start;
    padding: 0px 20px 0px 50px;
  }
  .nav-bar {
    margin-left: auto;
  }
  .nav-link {
    margin: 0px 10px 10px;
  }
  .features {
    padding-left: 1rem;
    padding-right: 1rem;
  }
  .form {
    max-width: 700px;
    margin: 0 auto;
  }
}

@media (min-width: 1000px) {
  .main {
    max-width: 1000px;
    margin: 0 auto;
  }
}

            
          
!
999px
🕑 One or more of the npm packages you are using needs to be built. You're the first person to ever need it! We're building it right now and your preview will start updating again when it's ready.
Loading ..................

Console