Graded A+
How do you change the font of an element using CSS?
✔✔The font of an element can be changed using the `font-family` property.
What property is used to adjust the space between the content and the border of an element?
✔✔The `padding` property is used to adjust the space between the content and the border of an
element.
What does the `margin` property do in CSS?
✔✔The `margin` property creates space outside of an element's border, separating it from other
elements.
How can you create a hover effect for a button in CSS?
✔✔A hover effect can be created using the `:hover` pseudo-class in CSS to change styles when
the mouse is over the element.
What is the purpose of the `float` property in CSS?
1
, ✔✔The `float` property is used to position an element to the left or right, allowing text and inline
elements to wrap around it.
How do you center an element horizontally using CSS?
✔✔An element can be centered horizontally by setting its left and right margins to `auto` and
defining a width.
What is the primary purpose of CSS?
✔✔The primary purpose of CSS is to style and layout web pages, controlling the presentation of
HTML elements.
How can you apply CSS styles to an HTML document?
✔✔CSS styles can be applied using inline styles, internal styles (within a `<style>` tag), or
external stylesheets linked with a `<link>` tag.
What is a CSS selector?
✔✔A CSS selector is a pattern used to select elements in the HTML document that you want to
style.
2