html, body { margin: 0; padding: 0; overflow: hidden; } html { position: relative; width: 100%; height: 100%; max-width: 48rem; max-height: 32rem; } body { position: absolute; top: 0; right: 0; bottom: 0; left: 0; } canvas { outline: none; }