What I am trying to do is create default css styles that when I combine multiple classes together I want to override some of the default styles from another class. Here is an example of what I am trying to do.
style.css
.navBar {
position:absolute;
left:0px;
right:0px;
width:100%;
height:50px;
background-color: #333333;
}
.fixed {
position: fixed;
}
.top {
top:0px;
}
.left {
float:left;
left:0px;
}
.navBar .left {
width: 50px;
height:100%;
}
In my html if I have <div class="navBar">
then it will just use the styles in .navBar but when I try to do <div class="navBar left">
I want it to override the width and height of .navBar but keep everything else from .navBar and .left
I dont want to put the height and width inside .left because I want to keep it as universal as possible.