I want to color the background of the text, but only its size.
Images are better than a thousand words, this is what I'm trying to achieve:

And this is what I achieve

I donβt want to do this programmatically, I would like the background to adapt to the text (because it can be dynamic)
Is there any way to do this without using javascript?
Update (HTML):
<div class="team-member-teaser-name">OSCAR</div>
CSS
.team-member-teaser-name { color: #4fb4d0; background: #135364; margin-top: 5px; margin-bottom: 5px; padding-left: 5px; font-size: 10px; }
Update (allowed based on @BoldClock answer):
.team-member-teaser-name { color: #4FB4D0; background: #135364; margin-top: 5px; padding-left: 5px; font-size: 10px; display: inline; float: left; padding-right: 9px; clear: both; }
I really donβt understand how clear the work is, but it is required to achieve results in the image.
source share