HTML CSS examples for CSS Layout:Responsive Layout
overlay text on top of a responsive image responsively
<html> <head> <meta name="viewport" content="width=device-width, initial-scale=1"> <style id="compiled-css" type="text/css"> #thisbanner {<!-- www . ja v a 2 s .c o m--> max-width:701px; } h1 { position:absolute; display:block; width:81%; margin-top:-13%; max-width:611px; font-size:5vw; font-family:'Roboto Slab', Rockwell, Serif; font-weight:bold; color:Chartreuse; text-shadow:0 .126em .126em yellow; padding:.7em 2em .7em 2.8em; } </style> </head> <body> <div id="thisbanner"> <div class="interior-header img"> <div class="headerimage"> <img src="https://www.java2s.com/style/demo/Firefox.png" width="630" height="240" alt="Traffic Control"> <h1>Lorem ipsum dol</h1> </div> </div> </div> </body> </html>