I'm trying to get the border of a <p> element to only take up the space occupied by text. Here's the relevant part of my html:
<h2 style="font-weight: normal;">
<style>
.border {
border-style: solid;
border-color: black;
</style>
Plate number:
<br>
<p class="border" style="">5649JSN</p>
</h2>
And here's how it looks:
How can I fix this? Thanks in advance
Edit: I can't know beforehand how much space the plate number will take