title: How to align button right in a flex container?
body: <p>I don't know how to float my button right and I hope someone can help me out here.</p>
  <p><a href="https://i.stack.imgur.com/qbWpT.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/qbWpT.png" alt="enter image description here" /></a></p>
  <p>The yellow color shows the background of the div. The width of the div is set to 50%.</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>.faq {
    width: 100%;
    padding: 12px 20px;
    display: block;
    box-sizing: border-box;
    width: 50%;
    margin: auto;
    margin-top: 30px;
  }
  
  .outerDiv {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    margin-top: 20px;
    background-color: yellow;
  }
  
  .save {
    float: right;
    background-color: red;
  }</code></pre>
  <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;div class="outerDiv"&gt;
    &lt;h2&gt;New FAQ&lt;/h2&gt;
    &lt;input type="text" class="faq"&gt;
    &lt;br&gt;
    &lt;button class="save" mat-raised-button color="primary"&gt;Primary&lt;/button&gt;
  &lt;/div&gt;</code></pre>
  </div>
  </div>
  </p>
  <p>What am I doing wrong?</p>