title: Vertically center bootstrap right-aligned button in a panel
body: <p>I have a bootstrap panel and need a button right-aligned and vertically-centered in the panel - I'm stumped. I'm working in Laravel 5.5 PHP on XAMPP.</p>
  
  <p>I can right-align it but it sticks to off the bottom right corner. I have tried many suggestions here to vertically align it, but anytime I succeed with the vertical alignment I lose the right-alignment. I have tried <code>text-align:right</code> instead of <code>float:right</code>, I've tried <code>display:inline-block</code>, <code>display:flex</code> and <code>align-self:center</code>, all to no avail. </p>
  
  <p>Here's my code that right-aligns, but the button is placed to the bottom and partially outside of the panel.</p>
  
  <pre><code> &lt;div class="col-md-6"&gt;
      &lt;div class="panel panel-default" &gt;
          &lt;div class="panel-heading" style="background-color:#f37735;color:white"&gt;&lt;h3&gt;&lt;b&gt;Employment History&lt;/b&gt;&lt;/h3&gt;
          &lt;button class="btn btn-primary" type="button" style="float:right;" data-toggle="collapse" data-target="#collapseEmployment" aria-expanded="false" aria-controls="collapseEmployment"&gt;
              Show Items
          &lt;/button&gt;
          &lt;/div&gt; .....
  </code></pre>
  
  <p>Here's a pic of what I have. The red arrow is where I need to place the button.
  <a href="https://i.stack.imgur.com/aeaH4.png" rel="nofollow noreferrer">button placement</a>
  Any and all suggestions are most welcome - thanks.</p>