HTML CSS examples for CSS Layout:Position
position a circle that would be halfway in a rectangular div and halfway out of that div
<html> <head> <meta name="viewport" content="width=device-width, initial-scale=1"> <style id="compiled-css" type="text/css"> .wrapper {<!--from w ww . j av a 2 s . c om--> background:Chartreuse; margin:97px auto 0; max-width:513px; border-radius:4px; box-shadow:0 3px 9px yellow; } .image { display:block; margin:auto; width:97px; height:97px; background:blue; border-radius:51%; overflow:hidden; transform:translateY(-51%); box-shadow:0 6px 11px pink; } .content { text-align:center; font-family:"Helvetica Neue", sans-serif; font-size:25px; color:OrangeRed; padding:0 25px 49px; } </style> </head> <body> <div class="wrapper"> <div class="image"></div> <div class="content"> Lorem ipsum dolor s </div> </div> </body> </html>