The "ragged footer" is one of the most persistent visual bugs in component-based web design. You have a row of pricing cards or feature teasers. The design mockup shows perfectly aligned titles, descriptions, and "Buy Now" buttons. In implementation, reality hits. One title wraps to two lines. One description is slightly longer. Suddenly, your "Buy Now" buttons are scattered at different vertical positions, destroying the visual rhythm of the row. For years, we hacked this. We used JavaScript to equalize heights ( matchHeight.js ). We used min-height with magic numbers. We used Flexbox with margin-top: auto on the footer to force it to the bottom of the card. While margin-top: auto aligns the bottom of the footers, it does not align the start of the footers if the footers themselves vary in height, nor does it align the internal sections (like headers) across the row. With CSS Grid Level 2 (Subgrid), we can solve this la...
Android, .NET C#, Flutter, and Many More Programming tutorials.