How to vertically center text in a div
This is a neat way of centering text in a div. Live demo here. <html> <head> <title>Vertical text center demo</title> </head> <body> <style> .textbox { height: 200px; width: 300px; text-align: center; font-size: 14px; font-weight: bold; background-color: blue; } .textbox p { height: 100%; display: flex; /* vertically center text */ justify-content: center; align-content: center; […]