HTML CSS examples for CSS Layout:Responsive Layout
Align two responsive divs, side by side within its container div element
<html lang="en"> <head> <title> Sebastian Graz</title> <style> div {<!-- www .jav a 2 s . c om--> min-height:201px; display:block; width:100%; background:Chartreuse; border:2px solid yellow; } .wrapper { margin-top:13px; display:flex; box-sizing:border-box; padding:33px 17px; } .wrapper>div { box-sizing:border-box; width:calc(51% - 33px); float:left; margin:0 17px; } body { max-width:601px; margin:0 auto; color:blue; } </style> </head> <body translate="no"> <div></div> <div class="wrapper"> <div> box 1 </div> <div> Lots of content here Lots of content hereLots of content hereLots of content here Lots of content hereLots of content hereLots of content here Lots of content hereLots of content hereLots of content hereLots of content hereLots of content hereLots of content here Lots of content hereLots of content here Lots of content here Lots of content hereLots of content hereLots of content here Lots of content hereLots of content hereLots of content here Lots of content hereLots of content hereLots of content hereLots of content hereLots of content hereLots of content here Lots of content hereLots of content here </div> </div> </body> </html>