

Lets you set the color of the corresponding side of the element's border. border-left-color, border-right-color, border-top-color, and border-bottom-color Specifies a single color to use for every side of the element's border. You can use the border shorthand property, which lets you configure everything about the border in one shot (including non-color features of borders, such as its width, style (solid, dashed, etc.), and so forth. See Box properties in The box model to learn about the relationship between elements and their borders, and the article Styling borders using CSS to learn more about applying styles to borders. A basic element border is a line drawn around the edges of the element's content.

BoxesĪny element can have a border drawn around it. This is only useful in elements that are editable, such as and or elements whose HTML contenteditable attribute is set. The color to use when drawing the caret (sometimes referred to as the text input cursor) within the element. This is used primarily when drawing text for East Asian languages. The color to use when drawing emphasis symbols adjacent to each character in the text. However, you can override that behavior and use a different color for them with the text-decoration-color property. text-decoration-colorīy default, text decorations (such as underlines, strikethroughs, etc) use the color property as their colors.

See Text drop shadows in Fundamental text and font styling to learn more. Among the options for the shadow is the shadow's base color (which is then blurred and blended with the background based on the other parameters). background-colorĬonfigures a shadow effect to apply to text. The color to use when drawing the text and any text decorations (such as the addition of under- or overlines, strike-through lines, and so forth. Whenever an element is rendered, these properties are used to determine the color of the text, its background, and any decorations on the text.
