body
{
font-family: "Source Sans Pro";
background: hsl(220, 10%, 5%);
color: #FFF;
margin: 0;
overflow: hidden;
}
#game
{
width: 100vmin;
height: 100vmin;
}
#gameWrapper
{
justify-content: center;
}
#ball
{
background-color: #FFF;
position: absolute;
height: 5%;
width: 5%;
border-radius: 100%;
}
<body>
<div id="gameWrapper" style="display: none">
<div id="game">
<div id="padTop"></div>
<div id="ball"></div>
<div id="padBottom"></div>
</div>
</div>
</div>
</body>
In the #game div, both height and width are set to 100% of the smallest of viewport units, so percentage should be a 1:1 aspect ratio. I honestly don't know why this is happening. Someone please help me.