title: Bootstrap 4 .nav-link padding
body: <p>I want to remove the padding-left of the first <code>.nav-link</code> in <code>.navbar-nav</code>.</p>
  
  <p>Here's an <a href="https://i.stack.imgur.com/m3XK7.png" rel="nofollow noreferrer">example</a>.</p>
  
  <p>In bootstrap 4 I created a nav and gave padding to <code>.nav-link</code>: </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-css lang-css prettyprint-override"><code>.navbar-dark .navbar-nav .nav-link {
      color: #fff;
      padding-left: 1rem;
      padding-right: 1rem;
  }
      </code></pre>
  <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"&gt;&lt;/script&gt;
  &lt;script src="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/js/bootstrap.min.js" integrity="sha384-JZR6Spejh4U02d8jOt6vLEHfe/JQGiRRSQQxSfFWpi1MquVdAyjUar5+76PVCmYl" crossorigin="anonymous"&gt;&lt;/script&gt;
  
  &lt;link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/css/bootstrap.min.css" integrity="sha384-Gn5384xqQ1aoWXA+058RXPxPg6fy4IWvTNh0E263XmFcJlSAwiGgFAW/dAiS6JXm" crossorigin="anonymous"&gt;
  &lt;section class="navigation container-fluid"&gt;
    &lt;nav class="container navbar navbar-expand-lg navbar-dark"&gt;
      &lt;button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#mainNavbar" aria-controls="mainNavbar" aria-expanded="false" aria-label="Toggle navigation"&gt;
        &lt;span class="navbar-toggler-icon"&gt;&lt;/span&gt;
      &lt;/button&gt;
      &lt;div class="collapse navbar-collapse" id="mainNavbar"&gt;
        &lt;ul class="navbar-nav"&gt;
          &lt;li class="nav-item"&gt;
            &lt;a class="nav-link" href="http://www.flakneconstructionllc.com"&gt;Home &lt;span class="sr-only"&gt;(current)&lt;/span&gt;&lt;/a&gt;
          &lt;/li&gt;
          &lt;li class="nav-item"&gt;
            &lt;a class="nav-link" href="about"&gt;About Us&lt;/a&gt;
          &lt;/li&gt;
          &lt;li class="nav-item"&gt;
            &lt;a class="nav-link" href="services"&gt;Services&lt;/a&gt;
          &lt;/li&gt;
          &lt;li class="nav-item"&gt;
            &lt;a class="nav-link" href="gallery"&gt;Gallery&lt;/a&gt;
          &lt;/li&gt;
          &lt;li class="nav-item"&gt;
            &lt;a class="nav-link" href="contact"&gt;Contact Us&lt;/a&gt;
          &lt;/li&gt;
        &lt;/ul&gt;
      &lt;/div&gt;
    &lt;/nav&gt;
  &lt;/section&gt;</code></pre>
  </div>
  </div>
  </p>
  
  <p>But it's not working because there is a <code>.nav-item</code> between the <code>.navbar-nav</code> &amp; <code>.nav-link</code>.</p>
  
  <p>Do you guys have any solution?</p>
  
  <p>How can I select first item in this case?</p>