Chapter 7. Resolving Classic Problems

As a frontend developer, you are always dealing with classic CSS problems. The most known and repeatable issues are centering elements in both axes and opacity. With current CSS, you can do it pretty simple, but you need to have a foundation to know how to do it. Knowledge about fallbacks of previous versions of browsers can be used in some other further techniques. That's why they are added to this chapter.

In this chapter, we will:

  • Learn how to center elements in both axes
  • Learn how to deal with opacity
  • Gather both the preceding tricks and create an effect similar to the trendy lightbox effect

Centering elements

Centering elements is an aspect known since the first CSS versions. There were always some element/elements ...

Get Professional CSS3 now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.