Flat Preloader Icon
<div class="c-preloader">
	<div class="c-preloader__count"></div>
  <div class="c-preloader__progress"></div>
</div>
.bricks-is-frontend .c-preloader {
  position: fixed;
  top: 0;
  left: 0;
  background: #cc0000;
  width: 100%;
  height: 100vh;
  z-index: 10;
}
.bricks-is-frontend .c-preloader__count {
  color: white;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
font-size: clamp(4rem, 3.824vw + 2.776rem, 8rem);
  font-weight: 100;
  letter-spacing: -.5rem;
  z-index: 10;
}
.bricks-is-frontend .c-preloader__progress {
  background: black;
  height: 100%;
  width: 0%;
  position: absolute;
  top: 0;
  left: 0;
}
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.4.1/jquery.min.js"></script>

<script src="https://cdnjs.cloudflare.com/ajax/libs/gsap/2.1.3/TweenMax.min.js"></script>

<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery.imagesloaded/4.1.4/imagesloaded.pkgd.min.js"></script>

<script>
  
var imgLoad = imagesLoaded('img');

var progressBar = jQuery(".c-preloader__progress"),
    count = jQuery(".c-preloader__count"),
    images = jQuery("img").length,
    loadedCount = 0,
    loadingProgress = 0;
 
var tlProgress = new TimelineMax({
    paused: true,
    onUpdate: countPercent,
    onComplete: loadComplete
});

tlProgress.to(progressBar, 1, {width:"100%"});

imgLoad.on('progress', function(instance, image) {
    loadProgress();
});
 
function loadProgress() {
    loadedCount++;
    loadingProgress = (loadedCount / images);
    console.log(loadingProgress);

    TweenMax.to(tlProgress, 1, {progress: loadingProgress});
}

function countPercent() {
    var newPercent = (tlProgress.progress() * 100).toFixed();
    count.text(newPercent + "%");
}

function loadComplete() {
    var tlEnd = new TimelineMax();
    tlEnd
        .to(count, 0.5, {autoAlpha: 0})
        .to(".c-preloader", 0.5, {scaleX: 0, transformOrigin: "center right"});
}

</script>
/* Default state: transparent background */
#brx-header.sticky {
  position: sticky;
  top: 0;
  transition: opacity 0.5s ease, background-color 0.5s ease;
  opacity: 1;
  visibility: visible;
  background-color: transparent !important; /* Start with transparent background */
}

/* Hidden state when scrolling down */
#brx-header.sticky.nav-hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  background-color: transparent !important; /* Stay transparent when hidden */
}

/* Visible state when scrolling up: background becomes black */
#brx-header.sticky.nav-visible {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  background-color: rgba(0, 0, 0, 0.5) !important; /* Background becomes black when scrolling up */
}
document.addEventListener('DOMContentLoaded', function () {
  let lastScrollTop = 0;
  const nav = document.querySelector('#brx-header.sticky'); // Ensure this targets the correct header element
  let hasScrolledDown = false; // Track if the user has scrolled down

  // Listen for the scroll event on the window
  window.addEventListener('scroll', function () {
    let scrollTop = window.pageYOffset || document.documentElement.scrollTop;

    console.log('Scroll position:', scrollTop); // Check scroll position in console

    if (scrollTop > lastScrollTop) {
      // User is scrolling down
      console.log('Scrolling down');
      nav.classList.remove('nav-visible');
      nav.classList.add('nav-hidden');
      hasScrolledDown = true; // User has scrolled down
    } else if (scrollTop < lastScrollTop && hasScrolledDown) {
      // User is scrolling up and has already scrolled down
      console.log('Scrolling up');
      nav.classList.remove('nav-hidden');
      nav.classList.add('nav-visible');
    }

    // Update the last scroll position
    lastScrollTop = scrollTop;
  });
});

Gopal’s Path to Healing: Overcoming Tragedy with Courage and Care

Gopal Damai’s life was forever changed after a devastating road accident left him with a spinal cord injury, but through the unwavering support of his family and the expert care at Green Pastures Hospital, he found the strength to rebuild his life and hope for the future.

  • 1:26 min

  • 0 comments

Gopal Damai, a 27-year-old from Kaski, was pre­par­ing to embark on a new chapter of his life after return­ing from the Gulf to cel­eb­rate his recent mar­riage. But in a cruel twist of fate, a road acci­dent left him with a dev­ast­at­ing spinal cord injury just 15 days into his mar­riage, shat­ter­ing both his body and the dreams he and his wife had for their future.

Rushed to a pro­vin­cial hos­pital for emer­gency surgery, Gopal’s family was quickly over­whelmed by the mount­ing medical bills, espe­cially after the recent loss of his father, who had battled para­lysis for 15 years. With his father gone, the weight of sup­port­ing the family fell on Gopal’s mother. However, a glimmer of hope emerged when Gopal was referred to Green Pas­tures Hos­pital (GPH) for rehab­il­it­a­tion. At GPH, he was given the tools to regain his independence—starting with a wheel­chair that enabled him to move freely. With ded­ic­ated physio­ther­apy and occu­pa­tional therapy, Gopal gradu­ally regained strength, while peer coun­sel­ing helped him face the emo­tional chal­lenges of his new reality.

Through­out this journey, Gopal’s mother and wife stood by his side, provid­ing unwaver­ing love and support. Their encour­age­ment, coupled with GPH’s care, ignited hope in Gopal’s heart. Each small victory—whether a moment of phys­ical pro­gress or shared laughter—marked a step toward reclaim­ing his life.

Gopal’s story is a power­ful test­a­ment to the strength of the human spirit, showing that with the right care, support from loved ones, and sheer determ­in­a­tion, life after tragedy can still offer hope. In the past year alone, GPH treated 81 spinal cord injury cases and provided rehab­il­it­a­tion to 688 patients, under­scor­ing its vital role in offer­ing spe­cial­ized care to indi­vidu­als facing life-alter­ing challenges.

Share this post: