When viewing the site on a mobile device, clicking on the breadcrumb causes the header text and button to shift down, extending beyond the header image. Is there a way to keep the button and text in a fixed position without moving the navigation outside of the header? This issue does not occur when the navigation is placed outside of the header. Visit this link for reference
<!doctype html>
<html lang="en">
<head>
<!-- Required meta tags -->
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
<!-- Bootstrap CSS -->
<link rel="stylesheet" href="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/css/bootstrap.min.css" integrity="sha384-MCw98/SFnGE8fJT3GXwEOngsV7Zt27NXFoaoApmYm81iuXoPkFOJwJ8ERdknLPMO" crossorigin="anonymous">
<style type="text/css">
.row {
margin-right: 0px;
margin-left: 0px;
}
.navbar-custom {
background: transparent; !important;
z-index: 9999;
}
header {
background-image: url("https://i.imgur.com/w8jxzG4.jpg");
height: 80vh;
background-size: cover;
background-position: center;
background-attachment: fixed;
position: absolute;
width: 100%;
top: 0;
}
.navbar-custom {
background: transparent !important;
}
header h1{
color: #fff;
}
.header-content{
padding-top: 14rem;
padding-bottom: 10rem;
}
</style>
<title></title>
</head>
<body>
<header>
<nav class="navbar navbar-custom navbar-expand-sm navbar-dark bg-dark">
<a class="navbar-brand" href="#">Space</a>
<button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="collapse navbar-collapse" id="navbarSupportedContent">
<ul class="navbar-nav mr-auto">
<li class="nav-item">
<a class="nav-link" href="#">Home</a>
</li>
<li class="nav-item">
<a class="nav-link" href="#">Explore</a>
</li>
<li class="nav-item dropdown">
<a class="nav-link dropdown-toggle" href="#" id="navbarDropdown" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
Shop
</a>
<div class="dropdown-menu" aria-labelledby="navbarDropdown">
<a class="dropdown-item" href="#">Action</a>
<a class="dropdown-item" href="#">Another action</a>
<div class="dropdown-divider"></div>
<a class="dropdown-item" href="#">Something else here</a>
</div>
</li>
</ul>
<ul class="navbar-nav ml-auto"> <!-- margin-right auto -->
<li>
<a class="nav-link" href="#">Login</a>
</li>
<li>
<a class="nav-link" href="#">Register</a>
</li>
</ul>
</div>
</nav>
<div class="header-content">
<div class="row">
<div class="col-sm-10 mx-auto">
<h1>Welcome To The Space</h1>
</div>
</div>
<div class="row">
<div class="col-sm-10 mx-auto">
<button class="btn">Register for a trip</button>
</div>
</div>
</div>
</header>
<br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br><br>
<!-- Optional JavaScript -->
<!-- jQuery first, then Popper.js, then Bootstrap JS -->
<script src="https://code.jquery.com/jquery-3.3.1.slim.min.js" integrity="sha384-q8i/X+965DzO0rT7abK41JStQIAqVgRVzpbzo5smXKp4YfRvH+8abtTE1Pi6jizo" crossorigin="anonymous"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.3/umd/popper.min.js" integrity="sha384-ZMP7rVo3mIykV+2+9J3UJ46jBk0WLaUAdn689aCwoqbBJiSnjAK/l8WvCWPIPm49" crossorigin="anonymous"></script>
<script src="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/js/bootstrap.min.js" integrity="sha384-ChfqqxuZUCnJSK3+MXmPNIyE6ZbWh2IMqE241rYiqJxyMiZ6OW/JmZQ5stwEULTy" crossorigin="anonymous"></script>
</body>
</html>