CSS Text Align
The text-align
property in CSS determines the horizontal alignment of text within its container. It's used to adjust the positioning of text elements.
Basic Usage of the text-align
Property
The text-align
property can take several values:
text-align: left;
: Aligns text to the left of the container.text-align: right;
: Aligns text to the right of the container.text-align: center;
: Centers text horizontally within the container.text-align: justify;
: Justifies the text, creating even spacing between words to align both the left and right edges.