The others are right, width: auto sets the width to fill all available space.
One solution would be to use display: inline-block, which should do what you want. For compatibility with IE6 it's best to apply that to an inline element like . And add display: -moz-inline-box for Firefox 2 and earlier.