While working with Bootstrap, I created a small footer with a tab. However, whenever I click on the second value, the entire div shifts to the left. How can I keep it in place?
Below is my code along with two images depicting how the first tab aligns correctly and how the second one moves to the left.
<footer class="navbar navbar-dark bg-dark text-light">
<div class="container mt-5">
<div class="row">
<div class="col-6">
<span class="navbar-brand m-2 h1 text-white">My Blog</span>
</div>
<div class="col-6">
<ul class="nav nav-tabs" id="myTab" role="tablist">
<li class="nav-item" role="presentation">
<a class="nav-link active" aria-current="page" href="#" id="about-tab" data-bs-toggle="tab" data-bs-target="#pills-about">About Me</a>
</li>
<li class="nav-item" role="presentation">
<a class="nav-link" aria-current="page" href="#" id="contact-tab" data-bs-toggle="tab" data-bs-target="#pills-contact">Contact</a>
</li>
</ul>
<div class="tab-content" id="pills-tabContent">
<div class="tab-pane fade show active text-white" id="pills-about" role="tabpanel" aria-labelledby="pills-about-tab" tabindex="0"><p>I am an IT professional, tech enthusiast, and coach at Bit Academy. Through this background, I strive to educate as many people as possible about technology.</p></div>
<div class="tab-pane fade text-white" id="pills-contact" role="tabpanel" aria-labelledby="pills-contact-tab" tabindex="0"><p>Email: <a href="mailto:<a href="/cdn-cgi/l/email-protection" class="__cf_email__" data-cfemail="e38a8d858ca3818a97ce82808287868e9acd8d8f">[email protected]</a>"><a href="/cdn-cgi/l/email-protection" class="__cf_email__" data-cfemail="f59c9b939ab5979c81d89496949190988cdb9b99">[email protected]</a></a></p><p>Address: Koningin Wilhelminaplein 1, Amsterdam</p></div>
</div>
</div>
</div>
</div>
</footer>
Screenshot of Tab 1 Screenshot of Tab 2
I have experimented with various positioning options in Bootstrap, but so far, I have been unable to determine why it instantly shifts to the left when switching tabs.