Home
CSS
CSS Templates
Tryit: Template 3
Run ❯
Get your
own
website
Result Size:
625 x 534
×
Change Orientation
Save Code
Change Theme, Dark/Light
Go to Spaces
<!DOCTYPE html> <html lang="en"> <head> <title>CSS Template</title> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1"> <style> * { box-sizing: border-box; font-family: Arial, Helvetica, sans-serif; } body { margin: 0; font-family: Arial, Helvetica, sans-serif; } /* Style the top navigation bar */ .topnav { overflow: hidden; background-color: #333; } /* Style the topnav links */ .topnav a { float: left; display: block; color: #f2f2f2; text-align: center; padding: 14px 16px; text-decoration: none; } /* Change color on hover */ .topnav a:hover { background-color: #ddd; color: black; } /* Style the content */ .content { background-color: #ddd; padding: 10px; height: 200px; /* Should be removed. Only for demonstration */ } /* Style the footer */ .footer { background-color: #f1f1f1; padding: 10px; } </style> </head> <body> <div class="topnav"> <a href="#">Link</a> <a href="#">Link</a> <a href="#">Link</a> </div> <div class="content"> <h2>CSS Template</h2> <p>A topnav, content and a footer.</p> </div> <div class="footer"> <p>Footer</p> </div> </body> </html>