I want to create a unique design for a circle with a centered number and partially colored border like this:
https://i.sstatic.net/rOzWA.png
My goal is to highlight the circle based on a number ranging from 0-100.
Here is my current code for creating the circle:
#circle {
border-color: lightgray;
border-radius: 50%;
border-style: solid;
border-width: 5px;
box-sizing: border-box;
height: 100px;
position: relative;
width: 100px;
}
<div id="circle">
37
</div>
However, I am struggling to dynamically change the border color based on the number and center the text within the circle.
Here's what it looks like currently: https://i.sstatic.net/3bD1J.png