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

              
                <body>
  <nav class="absolute z-50 text-black">
    <div class="fixed">
      <button id="section1Btn">Section 1</button>
      <button id="section2Btn">Section 2</button>
      <button id="section3Btn">Section 3</button>
  </nav>
  </div>

  <div id="container" class="content">
    <!-- <div class="relative w-full">
      <div class="fixed z-50 flex  w-full px-4 mx-auto bg-gray-300 bg-opacity-20 backdrop-blur-sm shadow-md">
        <div class="flex flex-row items-center justify-between p-4">
          <a href="/" class="z-50 text-2xl font-semibold tracking-widest text-blue-50 uppercase rounded-lg dark-mode:text-white focus:outline-none focus:shadow-outline">SATMAKA</a>
        </div>
        <nav  class="flex justify-end items-center">  
          <a class="px-6 py-3  text-sm font-semibold bg-transparent rounded duration-700  md:mt-0 md:ml-4 hover:text-gray-900 focus:text-gray-900 hover:bg-blue-50" href="#">Blog</a>
          <a class="px-6 py-3 text-sm font-semibold bg-transparent rounded duration-700  md:mt-0 md:ml-4 hover:text-gray-900 focus:text-gray-900 hover:bg-blue-50 mr-12" href="#">Login</a>
        </nav>
        
      </div>
    </div> -->

    <section id="section" class="description panel color-white p-12">
      <div class="absolute h-full top-0 w-full bg-blue-700"></div>
      <div class="w-8/12 m-0 p-0 text-left ">
        <h2 class="text-7xl drop-shadow-md">IT'S TIME FOR A TALENT REVOLUTION.</h2>
        <h5 class="text-white w-7/12 drop-shadow-md">Strip away bias and reveal human potential to revolutionize how you hire, grow, and retain talent with Satmaka Raharja.</h5>
        <div class="scroll-down">
          <div class="arrow drop-shadow"></div>
        </div>
      </div>
    </section>

    <section id="section1" class="panel bg-red-500 m-0 p-0 w-full h-auto">
      <div class="w-full h-auto">
        <div class="grid grid-cols-3 ">
          <div class="w-full h-[334px] bg-gray-100 border border-gray-500 bg2">
            <h2 class="opacity-0 hover:opacity-90 duration-700 flex items-center drop-shadow-lg scale-105 hover:scale-100 justify-center bg-blue-500 text-center bg-opacity-65 text-white w-full h-[334px]">ADRAWORLD</h2>
          </div>
          <div class="w-full h-[334px] bg-gray-100 border border-gray-500 bg3">
            <h2 class="opacity-0 hover:opacity-90 duration-700 flex items-center drop-shadow-lg scale-105 hover:scale-100 justify-center bg-blue-500 text-center bg-opacity-65 text-white w-full h-[334px]">EMI PERSERO</h2>
          </div>
          <div class="w-full h-[334px] bg-gray-100 border border-gray-500 bg4">
            <h2 class="opacity-0 hover:opacity-90 duration-700 flex items-center drop-shadow-lg scale-105 hover:scale-100 justify-center bg-blue-500 text-center bg-opacity-65 text-white w-full h-[334px]">DIAN PENCERAH INDONESIA</h2>
          </div>
          <div class="w-full h-[334px] bg-gray-100 border border-gray-500 bg5">
            <h2 class="opacity-0 hover:opacity-90 duration-700 flex items-center drop-shadow-lg scale-105 hover:scale-100 justify-center bg-blue-500 text-center bg-opacity-65 text-white w-full h-[334px]">ARAT DESIGN INTERNATIONAL</h2>
          </div>
          <div class="w-full h-[334px] bg-gray-100 border border-gray-500 bg6">
            <h2 class="opacity-0 hover:opacity-90 duration-700 flex items-center drop-shadow-lg scale-105 hover:scale-100 justify-center bg-blue-500 text-center bg-opacity-65 text-white w-full h-[334px]">SADASA ACADEMY</h2>
          </div>
          <div class="w-full h-[334px] bg-gray-100 border border-gray-500 bg7">
            <h2 class="opacity-0 hover:opacity-90 duration-700 flex items-center drop-shadow-lg scale-105 hover:scale-100 justify-center bg-blue-500 text-center bg-opacity-65 text-white w-full h-[334px]">KAMPUNG ARIDATU</h2>
          </div>
          <div class="w-full h-[334px] bg-gray-100 border border-gray-500 bg8">
            <h2 class="opacity-0 hover:opacity-90 duration-700 flex items-center drop-shadow-lg scale-105 hover:scale-100 justify-center bg-blue-500 text-center bg-opacity-65 text-white w-full h-[334px]">ADRAWORLD</h2>
          </div>
          <div class="w-full h-[334px] bg-gray-100 border border-gray-500 bg9">
            <h2 class="opacity-0 hover:opacity-90 duration-700 flex items-center drop-shadow-lg scale-105 hover:scale-100 justify-center bg-blue-500 text-center bg-opacity-65 text-white w-full h-[334px]">ADRAWORLD</h2>
          </div>
          <div class="w-full h-[334px] bg-gray-100 border border-gray-500 bg10">
            <h2 class="opacity-0 hover:opacity-90 duration-700 flex items-center drop-shadow-lg scale-105 hover:scale-100 justify-center bg-blue-500 text-center bg-opacity-65 text-white w-full h-[334px]">ADRAWORLD</h2>
          </div>
          <div class="w-full h-[334px] bg-gray-100 border border-gray-500 bg11">
            <h2 class="opacity-0 hover:opacity-90 duration-700 flex items-center drop-shadow-lg scale-105 hover:scale-100 justify-center bg-blue-500 text-center bg-opacity-65 text-white w-full h-[334px]">ADRAWORLD</h2>
          </div>
          <div class="w-full h-[334px] bg-gray-100 border border-gray-500 bg12">
            <h2 class="opacity-0 hover:opacity-90 duration-700 flex items-center drop-shadow-lg scale-105 hover:scale-100 justify-center bg-blue-500 text-center bg-opacity-65 text-white w-full h-[334px]">ADRAWORLD</h2>
          </div>
          <div class="w-full h-[334px] bg-gray-100 border border-gray-500 bg13">
            <h2 class="opacity-0 hover:opacity-90 duration-700 flex items-center drop-shadow-lg scale-105 hover:scale-100 justify-center bg-blue-500 text-center bg-opacity-65 text-white w-full h-[334px]">ADRAWORLD</h2>
          </div>

        </div>
      </div>
    </section>

    <section id="section2" class="panel bg-orange-500">
      <div>
        TWO
      </div>
    </section>

    <section id="section3" class="panel bg-violet-500">
      THREE
    </section>

  </div>

  <script src="https://cdn.tailwindcss.com"></script>
  <script src="https://cdnjs.cloudflare.com/ajax/libs/gsap/3.9.1/gsap.min.js"></script>
  <script src="https://cdnjs.cloudflare.com/ajax/libs/gsap/3.9.1/ScrollTrigger.min.js"></script>
  <script src="https://cdnjs.cloudflare.com/ajax/libs/gsap/3.9.1/ScrollToPlugin.min.js"></script>
  <script src='https://codepen.io/GreenSock/pen/7ba936b34824fefdccfe2c6d9f0b740b.js'></script>
  <script src="/src/js/script.js"></script>

</body>
              
            
!

CSS

              
                @import url("http://fonts.cdnfonts.com/css/proxima-nova-2");

* {
  margin: 0;
  padding: 0;
  color: #fff;
}
body {
  scroll-behavior: smooth;
  font-family: "Proxima Nova", sans-serif;
  width: 100vw;
}

#container {
  width: 100%;
  height: 100%;
  position: absolute;
  top: 0;
  left: 0;
  overflow: hidden;
}

.panel {
  position: absolute;
  will-change: transform;
}

.bg1 {
  background-image: url("/src/img/hero.webp");
  /* background-image: url("https://picsum.photos/id/594/2509/1673"); */
  /* background-image: url("http://satmaka.com/wp-content/uploads/2021/12/psychological-workoshops-P8XR442.jpg"); */
  /* background-color: #041c2b; */
  max-height: 100%;
  width: 100%;
  background-attachment: fixed;
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
}

.bg2 {
  background-image: url("/src/img/adraworld.png");
  /* background-image: url("https://picsum.photos/id/594/2509/1673"); */
  /* background-image: url("http://satmaka.com/wp-content/uploads/2021/12/psychological-workoshops-P8XR442.jpg"); */
  /* background-color: #041c2b; */
  max-height: 100%;
  width: 100%;
  background-attachment: local;
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
}
.bg3 {
  background-image: url("/src/img/EMI.png");
  /* background-image: url("https://picsum.photos/id/594/2509/1673"); */
  /* background-image: url("http://satmaka.com/wp-content/uploads/2021/12/psychological-workoshops-P8XR442.jpg"); */
  /* background-color: #041c2b; */
  max-height: 100%;
  width: 100%;
  background-attachment: local;
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
}

.bg4 {
  background-image: url("/src/img/dian.png");
  /* background-image: url("https://picsum.photos/id/594/2509/1673"); */
  /* background-image: url("http://satmaka.com/wp-content/uploads/2021/12/psychological-workoshops-P8XR442.jpg"); */
  /* background-color: #041c2b; */
  max-height: 100%;
  width: 100%;
  background-attachment: local;
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
}
.bg5 {
  background-image: url("/src/img/arat.png");
  /* background-image: url("https://picsum.photos/id/594/2509/1673"); */
  /* background-image: url("http://satmaka.com/wp-content/uploads/2021/12/psychological-workoshops-P8XR442.jpg"); */
  /* background-color: #041c2b; */
  max-height: 100%;
  width: 100%;
  background-attachment: local;
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
}
.bg6 {
  background-image: url("/src/img/sadasa.png");
  /* background-image: url("https://picsum.photos/id/594/2509/1673"); */
  /* background-image: url("http://satmaka.com/wp-content/uploads/2021/12/psychological-workoshops-P8XR442.jpg"); */
  /* background-color: #041c2b; */
  max-height: 100%;
  width: 100%;
  background-attachment: local;
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
}
.bg7 {
  background-image: url("/src/img/kampung.png");
  /* background-image: url("https://picsum.photos/id/594/2509/1673"); */
  /* background-image: url("http://satmaka.com/wp-content/uploads/2021/12/psychological-workoshops-P8XR442.jpg"); */
  /* background-color: #041c2b; */
  max-height: 100%;
  width: 100%;
  background-attachment: local;
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
}
.bg8 {
  background-image: url("/src/img/adraworld.png");
  /* background-image: url("https://picsum.photos/id/594/2509/1673"); */
  /* background-image: url("http://satmaka.com/wp-content/uploads/2021/12/psychological-workoshops-P8XR442.jpg"); */
  /* background-color: #041c2b; */
  max-height: 100%;
  width: 100%;
  background-attachment: local;
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
}
.bg9 {
  background-image: url("/src/img/adraworld.png");
  /* background-image: url("https://picsum.photos/id/594/2509/1673"); */
  /* background-image: url("http://satmaka.com/wp-content/uploads/2021/12/psychological-workoshops-P8XR442.jpg"); */
  /* background-color: #041c2b; */
  max-height: 100%;
  width: 100%;
  background-attachment: local;
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
}
.bg10 {
  background-image: url("/src/img/adraworld.png");
  /* background-image: url("https://picsum.photos/id/594/2509/1673"); */
  /* background-image: url("http://satmaka.com/wp-content/uploads/2021/12/psychological-workoshops-P8XR442.jpg"); */
  /* background-color: #041c2b; */
  max-height: 100%;
  width: 100%;
  background-attachment: local;
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
}
.bg11 {
  background-image: url("/src/img/adraworld.png");
  /* background-image: url("https://picsum.photos/id/594/2509/1673"); */
  /* background-image: url("http://satmaka.com/wp-content/uploads/2021/12/psychological-workoshops-P8XR442.jpg"); */
  /* background-color: #041c2b; */
  max-height: 100%;
  width: 100%;
  background-attachment: local;
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
}
.bg12 {
  background-image: url("/src/img/adraworld.png");
  /* background-image: url("https://picsum.photos/id/594/2509/1673"); */
  /* background-image: url("http://satmaka.com/wp-content/uploads/2021/12/psychological-workoshops-P8XR442.jpg"); */
  /* background-color: #041c2b; */
  max-height: 100%;
  width: 100%;
  background-attachment: local;
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
}
.bg13 {
  background-image: url("/src/img/adraworld.png");
  /* background-image: url("https://picsum.photos/id/594/2509/1673"); */
  /* background-image: url("http://satmaka.com/wp-content/uploads/2021/12/psychological-workoshops-P8XR442.jpg"); */
  /* background-color: #041c2b; */
  max-height: 100%;
  width: 100%;
  background-attachment: local;
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
}

p {
  color: #fff;
}

.arrow {
  color: #fff;
}

              
            
!

JS

              
                gsap.registerPlugin(ScrollTrigger, ScrollToPlugin);

gsap.to(".panel:not(:last-child)", {
  yPercent: -100,
  ease: "none",
  stagger: 0.5,
  scrollTrigger: {
    trigger: "#container",
    start: "top top",
    end: "+=300%",
    scrub: true,
    markers: false,
    pin: true
  }
});

gsap.set(".panel", { zIndex: (i, target, targets) => targets.length - i });

document.querySelectorAll("nav button").forEach((btn, index) => {
  btn.addEventListener("click", () => {
    gsap.to(window, {
      duration: 1,
      scrollTo: { y: "#section" + (index + 1), offsetY: -660 }
    });
  });
});

//smooth-scroll

// Tell ScrollTrigger to use these proxy getter/setter methods for the "body" element:
ScrollTrigger.scrollerProxy(document.body, {
  scrollTop(value) {
    if (arguments.length) {
      bodyScrollBar.scrollTop = value; // setter
    }
    return bodyScrollBar.scrollTop; // getter
  },
  getBoundingClientRect() {
    return {
      top: 0,
      left: 0,
      width: window.innerWidth,
      height: window.innerHeight
    };
  }
});

// when the smooth scroller updates, tell ScrollTrigger to update() too:
bodyScrollBar.addListener(ScrollTrigger.update);

              
            
!
999px

Console