title: creating a Bootstrap 4 two row navbar custom design
body: <p>I am trying to create a custom navigation, that I have found to not have been duplicated anywhere else on the internet. I have searched high and low for some sample solution, but to no avail, so was hoping someone could help me in achieving this in Bootstrap 4 here.</p>
  
  <p>The image attached below, displays how I am trying to recreate in Bootstrap, however its proving more difficult to apply.</p>
  
  <p>It a two row navbar in desktop.</p>
  
  <ul>
  <li>top nav has links to the far-left and to the far-right</li>
  <li>bottom nav has a search to the far-left, brand in the center, and the user avatar dropdown to the far-right.</li>
  <li>when the navbar collapses in mobile, it should only display the hamburger icon in the far-left, the brand in the center, and the search icon to the far-right, which will collapse the search (a second issue for me to work out myself later on).</li>
  <li>when the hamburger is clicked, it should show the avatar dropdown first, then list the following nav items from the top navbar.</li>
  </ul>
  
  <p>The thing is, is that to have two navbars you have to have two collapses. I have tried using one navbar with two navbar-navs inside it (which my snippet shows), but positioning them accordingly to my image does not work.</p>
  
  <p>The attached snippet of my code is not that great, since I am not properly understanding how to utilize flexbox into it, but nothing is sitting correctly as you see.</p>
  
  <p><a href="https://i.stack.imgur.com/2nmEo.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/2nmEo.jpg" alt="enter image description here"></a>
  A link to my codepen: 
  <a href="https://codepen.io/krystyna93/pen/PLyMPr?editors=1100" rel="nofollow noreferrer">https://codepen.io/krystyna93/pen/PLyMPr?editors=1100</a></p>
  
  <p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
  <div class="snippet-code">
  <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;link href="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/css/bootstrap.min.css" rel="stylesheet" /&gt;
  
  &lt;script src="https://code.jquery.com/jquery-3.3.1.slim.min.js"&gt;&lt;/script&gt;
  
  &lt;script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.7/umd/popper.min.js"&gt;&lt;/script&gt;
  
  &lt;script src="https://stackpath.bootstrapcdn.com/bootstrap/4.3.1/js/bootstrap.min.js"&gt;&lt;/script&gt;
  
  
  &lt;div class="navbar navbar-light bg-light navbar-expand-md"&gt;
  
    &lt;button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbar" aria-controls="navbar" aria-expanded="false" aria-label="Toggle navigation"&gt;
      &lt;span class="navbar-toggler-icon"&gt;&lt;/span&gt;
    &lt;/button&gt;
    &lt;a class="navbar-brand" href="#"&gt;Logo/Brand&lt;/a&gt;
  
    &lt;div id="navbar" class="navbar-collapse collapse flex-column w-100"&gt;
      &lt;ul class="navbar-nav flex-lg-column w-100"&gt;
        &lt;li class="nav-item"&gt;&lt;a class="nav-link" href="#"&gt;LinkA&lt;/a&gt;&lt;/li&gt;
        &lt;li class="nav-item"&gt;&lt;a class="nav-link" href="#"&gt;LinkB&lt;/a&gt;&lt;/li&gt;
        &lt;li class="nav-item"&gt;&lt;a class="nav-link" href="#"&gt;LinkC&lt;/a&gt;&lt;/li&gt;
        &lt;li class="nav-item"&gt;&lt;a class="nav-link" href="#"&gt;LinkD&lt;/a&gt;&lt;/li&gt;
        &lt;li class="nav-item"&gt;&lt;a class="nav-link" href="#"&gt;LinkE&lt;/a&gt;&lt;/li&gt;
      &lt;/ul&gt;
      &lt;ul class="navbar-nav flex-lg-column w-100"&gt;
        &lt;li class="nav-item"&gt;&lt;a class="nav-link" href="#"&gt;Link1&lt;/a&gt;&lt;/li&gt;
        &lt;li class="nav-item"&gt;&lt;a class="nav-link" href="#"&gt;Link2&lt;/a&gt;&lt;/li&gt;
        &lt;li class="nav-item"&gt;&lt;a class="nav-link" href="#"&gt;Link3&lt;/a&gt;&lt;/li&gt;
      &lt;/ul&gt;
    &lt;/div&gt;
    &lt;!--/.nav-collapse --&gt;
  &lt;/div&gt;</code></pre>
  </div>
  </div>
  </p>
  
  <p>There must be a way of doing this, but I am struggling with it quite a bit and keep hitting a brick wall every time I get close.</p>
  
  <p>I am also trying not to double up on list items for desktop and for mobile, because that is too redundant.</p>
  
  <p>Any help will be much appreciated.
  Thanks</p>