Regarding your question about overflow
, this is happening because you restricted the size (both height and width) of the container
that you're using, and text is trying to squeeze until there is no more space available and it overflows. Remove this constraint on either width or height, and allow the div to grow with the content. Next focus on the size of the content so that it allows you to match the preview. U can read a more detailed explanation at developer.mozilla.org - sizing items
But as I see it, once you do the above, you're container will no longer align in the center, this is because of how you're centering the div instead of top: 0, left: 0, right: 0, bottom: 0, and height: 60vh
, maybe try one of these cool methods w3schools - css align.
Good luck!