HTML CSS examples for CSS Layout:Responsive Layout
Create 3 Responsive DIV Boxes Side by Side
<html> <head> <meta name="viewport" content="width=device-width, initial-scale=1"> <style id="compiled-css" type="text/css"> .box {<!-- w w w . ja v a 2 s . c om--> background-color:Chartreuse; width:31%; display:inline-block; margin:11px 0; border-radius:6px; } .text { padding:11px 0; color:yellow; font-weight:bold; text-align:center; } #container { white-space:nowrap; text-align:center; } </style> </head> <body> <div id="container"> <div class="box"> <div class="text"> Text </div> </div> <div class="box"> <div class="text"> Text </div> </div> <div class="box"> <div class="text"> Text </div> </div> </div> </body> </html>