The first-child pseudo-class
<!DOCTYPE html> <html> <head> <title></title> <style type="text/css"> body { font-family: sans-serif; } a { text-decoration: none; } /* don't underline links */ li { float: left; /* horizontal list */ padding: .25em; margin-right: 5px; border: 2px black outset; /* shaded buttons */ list-style-type: none; } li:first-child { background-color: black; } li:first-child a { color: white; } </style> </head> <body> <ul> <li><a href="home.html">Home</a></li> <li><a href="about.html">About</a></li> <li><a href="contact.html">Contact Us</a></li> </ul> </body> </html>