The logo in the navigation bar fails to respond on a specific webpage with a background animation in progress

I've encountered an issue with a clickable logo on my website's navigation bar. The logo works fine on every page except the final page of my javascript quiz, where there's a background animation playing. I've tried adjusting the z-index of both the animation and the logo, but to no avail. I can't seem to figure out what else might be causing the problem. It's probably something obvious that I'm overlooking?

<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>SPLANETS</title>
    <meta content="" name="description">
    <meta content="" name="keywords">
    <!-- Favicons -->
    <link href="assets/img/splanets.ico" rel="icon">
    <!-- Main Bootstrap Css-->
    <link href="https://cdn.jsdelivr.net/npm/<a href="/cdn-cgi/l/email-protection" class="__cf_email__" data-cfemail="ddbfb2b2a9aea9afbcad9de8f3eef3edf0bcb1adb5bcec">[email protected]</a>/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-GLhlTQ8iRABdZLl6O3oVMWSktQOp6b7In1Zl3/Jr59b6EGGoI1aFkw7cmDA6j6gD" crossorigin="anonymous">
    <!-- Main CSS File -->
    <link href="assets/css/style.css" rel="stylesheet">
    <!--Icons-->
    <script src="https://kit.fontawesome.com/128d236a07.js" crossorigin="anonymous"></script>
</head>
<body id="">
  <!-- === Header === -->
  <header>
    <nav class="navbar">
      <div class="container-fluid">
        <a class="navbar-brand mx-auto" href="index.html"><img src="assets/img/splanetslogo1.png" alt="Splanets Logo" class="img-fluid logo rocket-logo"></a>
      </div>
    </nav>
  </header>
  <!--End of Header-->
    <div class="rocket-overlay"></div>
    <video class="fullscreen-video" id="myVideo" autoplay="autoplay" muted >
        <source src="assets/img/rocketlaunch.mp4">
        Your browser does not support the video tag.
    </video>
    <section>
        <div class="card retrycard" style="width: 18rem;">
          <div class="card-body">
            <h5 class="card-title">Woohooo! Blast Off!!</h5>
            <h6 class="card-subtitle mb-2 text-muted"></h6>
            <p class="card-text">10/10! <br> Enter your name below to claim your spot on our leaderboard;
            </p>
            <a href="index.html" class="btn rewatch-btn" role="button"><i class="fa-solid fa-play"></i> Watch the video again</a>
            <br>
            <a href="game.html" class="btn replay-btn" role="button"><i class="fa-solid fa-rocket"></i> Restart Quiz</a>
          </div>
        </div>
      </section>
<script src="https://cdn.jsdelivr.net/npm/<a href="/cdn-cgi/l/email-protection" class="__cf_email__" data-cfemail="e5878a8a919691978495a5d0cbd6cbd5c88489958d84d4">[email protected]</a>/dist/js/bootstrap.bundle.min.js" integrity="sha384-w76AqPfDkMBDXo30jS1Sgez6pr3x5MlQ1ZAGC+nuZB+EYdgRZgiwxhTBTkF7CXvN" crossorigin="anonymous"></script>
<script src="/assets/js/script.js"></script>
</body>
</html>
Winner Rocket Luanch
--------------------------------*/
.fullscreen-video {
    position: fixed;
    overflow: hidden;
    top: 50%;
    left: 50%;
    min-width: 100%;
    min-height: 100%;
    width: auto;
    height: auto;
    transform: translateX(-50%) translateY(-50%);
    z-index: -3;
}

.rocket-overlay {
    position: fixed;
    top: 0;
    right: 0;
    left: 0;
    bottom: 0;
}

.logo .rocket-logo {
    transform: translate(-40px);
    max-height: 130px;
    z-index: -4;
}

Answer №1

To ensure the logo is displayed above the video and overlay, adjust the z-index values accordingly:

.fullscreen-video {
    z-index: -1;
}

.rocket-overlay {
    z-index: -2;
}

.logo .rocket-logo {
    z-index: 1;
}

Similar questions

If you have not found the answer to your question or you are interested in this topic, then look at other similar questions below or use the search

Navigating a Bootstrap modal using arrow keys for scrolling - up and down

I attempted to address this issue by using the following code: // here, 'this' represents the modal $(this).focus(); Despite trying the above solution and even attempting to trigger a click event on it, I was unable to get it to work! UPDATE ...

Using Jquery to encase an element in a div while scrolling down and removing it while scrolling up

After some experimentation, I've managed to wrap an element inside a div using jQuery. My next challenge is to wrap it as you scroll down and unwrap it as you scroll up. Do you think this is achievable? Although I have succeeded in wrapping it while ...

Display icons within each table cell row

Objective: I want to implement a feature where icons appear when the cursor is inside a td row, allowing users to click on them. These icons will contain links. When the cursor moves to a new td row, the previous row should return to its default state a ...

Safari iOS does not properly support responsive images when using srcset and sizes

I am facing an issue with the following code snippet: <img src="/img/footer/logo_white.png?v=2.0" srcset="/img/footer/logo_white.png?v=2.0 1x, /img/footer/logo_white2x.png?v=2.0 2x" > This ...

Having trouble with the scrolling feature on a read-only text area within a form

My form allows users to input their data, but once submitted, the form becomes read-only. However, I'm facing an issue where the data in the text area is not scrollable even though it should be. I need assistance in figuring out why the content in th ...

The items in the footer are not all aligned on a single line

Trying to create a footer with two linked images, I used justify-content: center, but it seems to be centering the images from the start rather than their actual centers. This causes them to appear slightly off to the left. Additionally, the images are sta ...

Resetting the quiz by utilizing the reset button

Hello everyone, I'm new to this platform called Stack Overflow. I need some help with my quiz reset button. It doesn't seem to be working as intended. According to my code, when the reset button is clicked at the end of the quiz, it should bring ...

Is there a way to make a specific panel the active one when the Bootstrap 5 accordion loads on a page?

Just starting out with Bootstrap, and I've configured my accordion with the last item set to class="accordion-collapse collapse show" Although the item opens when the page loads, the first panel is automatically selected. Is there a way to change thi ...

Is it possible to include pseudo element elements in the configuration of a custom theme in Material UI?

Within my file themeConfig.js, I have defined several theme variables that are utilized to style different components throughout my application. Among these variables, there is a need for implementing the -webkit scrollbar styles for certain components. Du ...

Manipulating elements with JavaScript to remove them, while ensuring that the empty space is automatically filled

Recently, I decided to enhance my understanding of JavaScript by experimenting with it on various websites. My goal was to use JavaScript to remove the right bar from a webpage and have the remaining body text automatically fill in the space left behind. ...

Setting maximum and minimum zoom limits for an element ID using JavaScript or jQuery

My application features a DIV element with the unique identifier of mainDiv. The issue I am facing is related to zooming functionality, as it currently lacks any set limits - both for scaling up and scaling down. I have been searching on Google for a sol ...

Ways to eliminate the excess space surrounding an Image border

I am looking to position the image at the top right corner of the screen. body{ font-family: 'Roboto', sans-serif; font-weight: 300; background: #822B2B; color: #ffffff; overflow: hidden; } #showcase{ display: flex; justify-content: center; al ...

Stylesheet failing to respond to CSS Media queries

I have looked at other questions with similar issues and it appears that what's missing in their code is: <meta name="viewport" content="width=device-width, initial-scale=1"> However, I already have this code implemented but still facing probl ...

Show random images of different sizes by employing jquery

I am seeking a solution for my webpage which currently loads a random image from an array and centers it using negative margins in CSS. While this method works fine with images of the same size, I am looking to modify the code so that it can handle images ...

arrangement of form labels in material-ui

Is there a way to configure the labels in Material-ui + react forms to be displayed beside input fields for better readability? For example: name [input] title [input] instead of name [input] title [input] I have looked through the documentation b ...

Stopping an HTML5 range input at a specific number: Tips and tricks

Does anyone have suggestions on how to use angularjs to stop a range slider at 75? I attempted it but it doesn't seem like the best approach. Any guidance would be appreciated. [EDIT for clarification after max=75 answer] Just to clarify, I want to di ...

Difficulty encountered with altering background color of table row in Firefox using CSS

I'm facing an issue with styling table rows that have alternating classes - I want to highlight the row that is being hovered on using CSS. Below is the CSS code I have implemented: .gridrowclass1 { background-color : #bbb00b } .gridrowclass1:h ...

CSS - Utilize floating divs to dynamically populate empty spaces

I am currently working on creating a grid layout on my website, . Despite using multiple divs (images) with the float: left; property, I am noticing empty spaces and gaps that are not being filled by the floating divs. Thank you in advance for any assist ...

CSS Color-Range Conditional Styling

I am interested in creating a simple chart using divs and spans, with the goal of implementing conditional formatting on each column based on its value to determine height. I have been struggling with figuring out how to make it work similar to Excel' ...

What is the best way to assign a CSS class to the jqGrid height property when using setGridHeight?

Our objective is to implement a media query css class. Currently, the code is utilizing $(window).height() to determine the height. $('#list').jqGrid('setGridHeight', $(window).height() - 380); Instead of relying on $(window).height( ...