I have a button in the main navigation. In mobile view it is coming along Customers link. I want to show it below Pricing link.
How I need it:
.nav-btn button {
background-color: white;
color: #000000;
border-radius: 5px;
outline: none;
font-size: 18px;
font-family: AktivGrotesk-Light;
height: 45px;
font-weight: 500;
transition: 0.4s ease-in-out;
}
<div class="collapse navbar-collapse navbar" id="navbarSupportedContent">
<ul class="navbar-nav m-auto mb-2 mb-lg-0 apri-nav">
<li class="nav-item">
<a class="nav-link active" aria-current="page" href="#">Platform</a>
</li>
<li class="nav-item">
<a class="nav-link" href="#">Apps</a>
</li>
<li class="nav-item">
<a class="nav-link" href="#">Customers</a>
</li>
<li class="nav-item">
<a class="nav-link" href="#">Pricing</a>
</li>
</ul>
<form class="d-flex nav-btn">
<button class="btn" type="submit">Request demo</button>
</form>
</div>
4
Answers
Run this snippet and see the result.
While I was checking the website link you posted it got banned, but from what I saw and checked in that litle time the issue is simple and you can tackle it by adding 1 line into your CSS, and from what I remember there is a .navbar class wrapping both UL and Button with a property of flex. So add this line to you css
In you CSS file there is already some styling used for this class just add this line there or in a new line.
The issue is with the way you arranged your HTML elements and Bootstrap CCS class used. You need to put the lists and the button form into a new div and pass row and col classes in Bootstrap media queries to them.
The code below should resolve this for both mobile and desktop. Let me know if there is more I can do to help.