Align to right in Flexbox - HTML CSS CSS Layout

HTML CSS examples for CSS Layout:Flex Align

Description

Align to right in Flexbox

Demo Code

ResultView the demo in separate window

<html lang="en">
 <head> 
  <style>
.container {<!--   w  ww.  j a v  a  2 s  .co  m-->
   display:-webkit-flex;
   display:-ms-flexbox;
   display:flex;
   -webkit-align-items:center;
   -ms-flex-align:center;
   align-items:center;
}

.nav-logo {
   margin-right:auto;
   width:100px;
   height:51px;
   background:Chartreuse;
}
</style> 
 </head> 
 <body translate="no"> 
  <header> 
   <div class="container"> 
    <a class="nav-logo" href=""></a> 
    <a class="nav-toggle" href="#">Menu</a> 
   </div> 
  </header>  
 </body>
</html>

Related Tutorials