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 class="fixed-content main-content">
        <div class="strength-title">
          <h1>Strength. Endurance. Recovery.</h1>
        </div>
        <div class="free-session-title">
          <h1>Get your FREE Session today.</h1>
        </div>
      </div>
      <div class="fixed-content col-lg-7 photobio-title">
        <h1>Whole-body Photobiomodulation</h1>
        <p class="col-lg-10 ml-auto mr-auto">NovoTHOR® is a whole body light therapy device that uses red and near-infrared light to treat injuries, reduce pain, relax muscles/joints, and increase blood circulation. The therapy is called
          photobiomodulation or PBM.</p>
      </div>

      <div id="fullPage">
        <section class="black-bg main section">
        </section>
        <section class="red-bg glow section">
        </section>
        <section class="black-bg angle1 glow section">
        </section>
      </div>
              
            
!

CSS

              
                body {
  background: radial-gradient(#333333, #000000);
  color: white;
  margin: 0;
}
.line,
.line-wrapper {
  overflow: hidden;
}
.strength-title {
  overflow: hidden;

  h1 {
    font-size: 52px;
    font-weight: 500;
    line-height: 70px;
    text-align: center;
  }
}

.free-session-title {
  margin-top: -5px;
  overflow: hidden;

  h1 {
    font-size: $font-60;
    text-transform: uppercase;
    font-weight: bold;
    line-height: 70px;
    text-align: center;
  }
}

.photobio-title {
  display: block;
  margin-left: auto;
  margin-right: auto;
  top: 15%;
  overflow: hidden;
  z-index: -1;
  // margin-top: -20px;
  h1 {
    font-size: $font-44;
    font-weight: bold;
    line-height: 50px;
    text-align: center;
  }

  p {
    font-size: $font-22;
    font-weight: 100;
    margin-top: 5px;
    line-height: 32px;
    text-align: center;
  }
}

              
            
!

JS

              
                $(document).ready(function() {
  $("#fullPage").fullpage({
    scrollOverflow: true,
    autoScrolling: true,
    navigation: true,
    scrollingSpeed: 500,
    afterLoad: function(origin, destination, direction) {
      setTimeout(function() {
        onMouseWheel();
      }, 50);
    }
  });
  function onMouseWheel() {
    var mainTitles = new SplitText(
        ".strength-title h1, .free-session-title h1",
        {
          type: "lines",
          linesClass: "line line++"
        }
      ),
      phototitle = new SplitText(".photobio-title h1", {
        type: "lines",
        linesClass: "line line++"
      });
    $(
      ".strength-title h1 .line , .free-session-title h1 .line, .photobio-title h1 .line"
    ).wrap('<div class="line-wrapper">');
    //main
    if ($(".main").hasClass("fp-completely")) {
      //tweenmax
      TweenMax.staggerFrom(
        mainTitles.lines,
        2,
        {
          yPercent: 100,
          ease: Power4.easeOut,
          delay: 1
        },
        0.25,
        splitRevert
      );
      TweenMax.staggerFromTo(
        phototitle.lines,
        2,
        {
          opacity: 1,
          yPercent: 0,
          ease: Power4.easeOut
        },
        {
          opacity: 1,
          yPercent: 100,
          ease: Power4.easeOut
        },
        0.25
      );
      $(".strength-title h1, .free-session-title h1").css(
        "visibility",
        "visible"
      );

      var tp = gsap.timeline(),
        mySplitText = new SplitText(".photobio-title p", {
          type: "lines,words"
        }),
        chars = mySplitText.lines; //an array of all the divs that wrap each character

      tp.fromTo(
        chars,
        1.5,
        {
          opacity: 1,
          y: 0,
          ease: Power4.easeOut,
          stagger: 0.15
        },
        {
          opacity: 0,
          y: 100,
          ease: Power4.easeOut,
          stagger: 0
        },
        "+=0"
      );

      function splitRevert() {
        $(
          ".strength-title h1 .line , .free-session-title h1 .line , .photobio-title h1 .line"
        ).unwrap();
        mainTitles.revert();
        $(".photobio-title h1").css("visibility", "hidden");
        phototitle.revert();
        $(".photobio-title p").css("visibility", "hidden");
        mySplitText.revert();
      }
    }
    //red-bg
    if ($(".red-bg").hasClass("fp-completely")) {
      //fade tweenmax
      TweenMax.staggerFromTo(
        mainTitles.lines,
        2,
        {
          yPercent: 0,
          ease: Power4.easeOut
        },
        {
          yPercent: -100,
          ease: Power4.easeOut
        },
        0.25,
        splitRevert
      );
      TweenMax.staggerFrom(
        phototitle.lines,
        2,
        {
          opacity: 1,
          yPercent: 100,
          ease: Power4.easeOut,
          delay: 1
        },
        0.25,
        splitRevert
      );
      $(".photobio-title h1, .photobio-title p").css("opacity", "1");
      $(".photobio-title h1, .photobio-title p").css("visibility", "visible");
      var tp = gsap.timeline(),
        mySplitText = new SplitText(".photobio-title p", {
          type: "lines,words"
        }),
        chars = mySplitText.lines;
      tp.fromTo(
        chars,
        2,
        {
          opacity: 0,
          y: 100,
          ease: Power4.easeOut,
          stagger: 0.15,
          delay: 1
        },
        {
          opacity: 1,
          y: 0,
          ease: Power4.easeOut,
          stagger: 0.15,
          delay: 1
        },
        "+=0"
      );

      var p1 = gsap.timeline(),
        mySplitText1 = new SplitText(".pain1 .pain-description", {
          type: "lines,words"
        }),
        chars1 = mySplitText1.lines;
      p1.fromTo(
        chars1,
        2,
        {
          opacity: 1,
          y: 0,
          ease: Power4.easeOut,
          stagger: 0.15
        },
        {
          opacity: 0,
          y: 100,
          ease: Power4.easeOut,
          stagger: 0.15
        },
        "+=0"
      );

      function splitRevert() {
        $(
          ".strength-title h1 .line , .free-session-title h1 .line, .photobio-title h1 .line"
        ).unwrap();
        mainTitles.revert();
        phototitle.revert();
        $(".strength-title h1 , .free-session-title h1").css(
          "visibility",
          "hidden"
        );
        mySplitText.revert();
        mySplitText1.revert();
        $(".pain1 .pain-description").css("visibility", "hidden");
      }
    }
  }
});

              
            
!
999px

Console