I attempted to center my navbar-toggler element, but was only successful in centering the navbar-contend using Bootstrap. I then took it a step further by trying to center the navbar-toggler icon with custom CSS, however, it now shifts to the left when clicked. I'm unable to figure out the reason behind this issue.
I have
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>My resumé</title;
<link href="https://cdn.jsdelivr.net/npm/<a href="/cdn-cgi/l/email-protection" class="__cf_email__" data-cfemail="a0c2cfcfd4d3d4d2c1d0e0958e938e90">[email protected]</a>/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-9ndCyUaIbzAi2FUVXJi0CjmCapSmO7SnpJef0486qhLnuZ2cdeRhO02iuK6FUUVM" crossorigin="anonymous">
<link href="https://fonts.googleapis.com/css2?family=Anonymous+Pro&family=Lato&display=swap" rel="stylesheet">
<script src="https://kit.fontawesome.com/c4df5125eb.js" crossorigin="anonymous"></script>
<style>
#navbar-center {
display: flex;
justify-content: center;
align-items: center;
}
.card {
margin: 2vh 1rem;
}
footer {
position: fixed;
top: 0;
padding-left: 90vw;
}
</style>
</head>
<body>
</header>
<div id="navbar-center">
<nav id="navbar" class="navbar navbar-expand-lg">
<div class="container-fluid">
<div class="d-flex justify-content-center">
<!-- Center the toggler icon -->
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
</div>
<div class="collapse navbar-collapse justify-content-center" id="navbarSupportedContent">
<ul class="navbar-nav me-auto mb-2 mb-lg-0">
<li class="nav-item">
<a class="nav-link btn btn-primary" href="#executive-summary">Executive Summary</a>
</li>
<li class="nav-item">
<a class="nav-link btn btn-primary" href="#technical-skillset">Skillset</a>
</li>
</ul>
</div>
</div>
</nav>
</div>
<div id="executive-summary"></div>
<div id="technical-skillset"></div>
<script src="https://cdn.jsdelivr.net/npm/<a href="/cdn-cgi/l/email-protection" class="__cf_email__" data-cfemail="33515c5c47404741524373061d001d03">[email protected]</a>/dist/js/bootstrap.bundle.min.js" integrity="sha384-geWF76RCwLtnZ8qwWowPQNguL3RmwHVBC9FhGdlKrxdiJJigb/j/68SIy3Te4Bkz" crossorigin="anonymous"></script>
</body>
</html>
I attempted experimenting on my own, searched on Google, Stack Overflow, and even consulted GPT chat. Unfortunately, the last one turned out to be unhelpful.