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

              
                <div id="menu">
  <div class="menu-right">
    <ul>
      <li><a href="#home">Home</a></li>
      <li><a href="#about">About</a></li>
      <li><a href="#feedback">Feedback</a></li>
    </ul>
    <div class="menu-marker">
      <input type="checkbox">
      <ul>
        <li class="first-bar"></li>
        <li class="second-bar"></li>
        <li class="third-bar"></li>
      </ul>
    </div>
  </div>
</div>
<section id="home" class="section1">
  <div>
    <h1 class="line-1 anim-typewriter">Welcome to the World Of Choices.</h1>
    <h3 data-aos="zoom-out" data-aos-delay="3000" data-aos-duration="1000" data-aos-easing="ease-in-cubic" style="color: #ffa069">Here you will find what you seek.</h3>
  </div>
</section>
<div class="section2-before"></div>
<section id="about" class="section2">
  <div>
    <div data-aos="fade-up" style="font-size:12px;margin:auto 0;">
      <h1 style="color:#090057">This is a new Section</h1>
      <h4>So now you must be familiar with parallax scrolling.</h4>
    </div>
    <div data-aos="fade-up" style="font-size:20px">
      <h1 style="color:#090057">If you like the pen</h1>
      <h4>Make Sure you hit the ❤<br>That would really help a lot.</h4>
    </div>
  </div>
</section>
<div class="section3-before"></div>
<section id="feedback" class="section3">
  <div>
    <div data-aos="fade-up" style="font-size:20px;">
      <h1 style="color:#090057">I am a freelancer</h1>
      <h4>You can hire me sending me a mail at <span style="color:#090057">jewelbarman998@gmail.com</span<</h4>
    </div>
    <div data-aos="fade-up" style="font-size:14px;margin:auto 0;">
      <h1 style="color:#090057">If you <span style="color:red">❤</span> this pen</h1>
      <h4>Make sure to checkout my other pens, click <a href="https://codepen.io/jewel998/">here 😍</a></h4>
    </div>
  </div>
</section>
              
            
!

CSS

              
                html{
  --size:40px;
  --t-1:9.5px;
  --t-3:-9.5px;
  --c-box: 4;
  font-family: "Source Code Pro", sans-serif;
  color: white;
  scroll-behavior: smooth;
}
body{  margin:0;padding:0; }
section, div[class^="section"]{height:100vh;width:100%;position:sticky;padding:0;margin:0;}
.section1{top:0;background: #090057;color:white;text-align: center;}
.section2-before{
  height: 25vh !important;
  background: linear-gradient(354deg,#c400c6 50%,rgba(0,0,0,0) 50%);
  z-index:2;
}
.section2{top:0;background:#c400c6 ;z-index:2}
.section3-before{
  height: 25vh !important;
  background: linear-gradient(6deg,#ffa069 50%,rgba(0,0,0,0) 50%);
  z-index:2;
}
.section3{top:0;background: #ffa069;z-index:3}

a{color:white;text-decoration:none;}
#menu{
  position:fixed;
  top:5px;
  width:80%;
  margin: auto;
  padding: 10px;
  z-index:99;
}
div.menu-right{
  width:100%;
  height:40px;
  padding: 0;
  margin:0;
}
div.menu-right{text-align:right}
div.menu-right > ul{
  display:inline-block;
  list-style-type:none;
  padding: 0;
  margin:0;
  min-width:40%;
  text-align: center;
  font-weight: 700;
  overflow: hidden;
  color: white;
}
div.menu-right > ul > li{
  padding: 10px 16px;
  display:inline-block;
  margin:0;
  overflow:hidden;
  vertical-align:middle;
}
.menu-marker{
  display:inline-block;
  position: relative;
  width:var(--size);
  height:var(--size);
  padding:0 !important;
  transform: translate(0,-20%);
}
.menu-marker > input[type=checkbox]{
  position:absolute;
  top:15px;
  left:15px;
  transform: scale(var(--c-box));
  opacity:0;
  z-index:2;
  cursor: pointer;
}
.menu-marker ul{
  list-style-type: none;
  padding: 0;
  text-align: left;
  z-index:1;
  vertical-align:middle;
}
.menu-marker li{
  background: white;
  border:white solid 1px;
  margin:calc(var(--size)/5) 0;
  transition: ease-in-out 0.5s all;
}
li.first-bar{
  width:80%;
  height:var(--size)/20;
}
li.second-bar{
  width:100%;
  height:var(--size)/20;
}
li.third-bar{
  width:60%;
  height:var(--size)/20;
}
.menu-marker > input[type=checkbox]:checked ~ ul li.first-bar, .menu-marker > input[type=checkbox]:checked ~ ul li.third-bar{
  width:100%;
}
.menu-marker > input[type=checkbox]:checked ~ ul li.second-bar{
  opacity: 0;
}
.menu-marker > input[type=checkbox]:checked ~ ul  li.first-bar{
  transform: translateY(var(--t-1)) rotate(225deg);
}
.menu-marker > input[type=checkbox]:checked ~ ul  li.third-bar{
  transform: translateY(var(--t-3)) rotate(315deg);
}
.menu-right > ul{transform: translateX(5%);}
.menu-right > ul{
  opacity: 0;
  transition: ease-in-out 0.5s all;
}
.menu-active{
  transform: translateX(0%) !important;
  opacity: 1 !important;
}

section > div{
  position:absolute;
  top:50%;
  left:50%;
  justify-content: center;
  transform: translate(-50%,-50%);
}
section.section2 > div,section.section3 > div{
  display: flex;
}
section.section2 > div > div,section.section3 > div > div{
  width:100%;
  padding: 0 20px;
}


.line-1{
    position: relative;
    top: 50%;
    width: 15em;
    margin: 0 auto;
    border-right: 2px solid rgba(255,255,255,1);
    font-size: 250%;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    transform: translateY(-50%);
}

/* Animation */
.anim-typewriter{
  animation: typewriter 3s steps(40) 1s 1 normal both,
             blinkTextCursor 500ms steps(20) infinite normal;
}
@keyframes typewriter{
  from{width: 0;}
  to{width: 19.5em;}
}
@keyframes blinkTextCursor{
  from{border-right-color: rgba(0,0,0,0);}
  to{border-right-color: rgba(255,255,255,1);}
}
              
            
!

JS

              
                $('.menu-right .menu-marker > input[type=checkbox]').on("click",function(){
  if($(this).is(":checked")){
    $('.menu-right > ul').addClass(" menu-active");
  }
  else{
    $('.menu-right > ul').removeClass(" menu-active");
  }
});

AOS.init();
              
            
!
999px

Console