Grumpy cat says "NO!" ( at least with pure CSS)
So I take what you are trying to do is 'copyfit' on the web. Think of it this way: in CSS the content determines the size of the container, but not the other way around. This would be no different in text ( which essentially is an anonymous content shell that by definition cannot contain anything itself) . BESIDES the biggest sin in web design is to take control of text size from the viewer.
Am afraid thsi just not possible with plain CSS, nor is it something that would be considered as a property n future CSS.
Than begin said .js can do it in convoluted ways (ON WINDOW RE SIZE: counting characters, and obtaining container size, then setting the CSS ..etc) and keep in mind that this wont be perfect either as not all letters are the same size anyway ( you always need humans for true copy fitting)