try this...
<style type="text/css">
.ItemA
{
background-color:Orange;
color:Black;
}
.ItemB
{
background-color:White;
color:Black;
}
.ItemC
{
background-color:Green;
color:Black;
}
</style>
<script type="text/javascript">
$(function () {
$("#Menu1 ul li").each(function () {
$(this).addClass($(this).text());
})
});
</script>