CSS Question

Permalink
I have bult the following CSS code. It creates a menu with rounded corners when links are hovered over. However when it hovers the hover background with rounded corners does not go with width of the container box it is in. It is driving my crazy! Any suggestions would be very welcome. If you want to see this in action, go tohttp://www.healthydrybasements.com/our-solutions... - it is only on that page for now, it is the left upper nav.

.rs-vertical
        {
        background-color: #a3d6ff;
        border-radius: 15px;
        -moz-border-radius: 14px;
        border: solid black 1px;
        padding-top:10px;
        padding-left:5px;
        padding-right:5px;
        padding-bottom:10px;
        margin-bottom: 20px;}
.rs-vertical li {
        width:  10em;
        max-width:250px;
        padding-top:10px;

globalnerds
 
tallacman replied on at Permalink Reply
tallacman
I think you want something like this:

/* @overridehttp://www.healthydrybasements.com/index.php/tools/css/themes/healt... */
/*** adding rs-vertical in addition to sf-menu creates a vertical menu ***/
.rs-vertical
   {
   background-color: #a3d6ff;
        border-radius: 15px;
        -moz-border-radius: 14px;
   border: solid black 1px;
   padding-top:10px;
   padding-left:5px;
   padding-right:5px;
   padding-bottom:10px;
   margin-bottom: 20px;}
.rs-vertical li {
   width:   10em;


display the a as a block so it fills the li.
since you have h3's in there I've zeroed out their inherited padding and margins.
you have a lot of redundant code in there as well and conflicting min-widths on the same object.


steve
tallacman replied on at Permalink Reply
tallacman
I think you want something like this:

/* @overridehttp://www.healthydrybasements.com/index.php/tools/css/themes/healt... */
/*** adding rs-vertical in addition to sf-menu creates a vertical menu ***/
.rs-vertical
   {
   background-color: #a3d6ff;
        border-radius: 15px;
        -moz-border-radius: 14px;
   border: solid black 1px;
   padding-top:10px;
   padding-left:5px;
   padding-right:5px;
   padding-bottom:10px;
   margin-bottom: 20px;}
.rs-vertical li {
   width:   10em;


display the a as a block so it fills the li.
since you have h3's in there I've zeroed out their inherited padding and margins.
you have a lot of redundant code in there as well and conflicting min-widths on the same object.


steve