Rosa’s garden website is laid out for a desktop screen, but most of its visitors check the work-day times on their phones. On a 320-pixel phone, the menu runs off the right edge and the page scrolls sideways. Rosa coordinates the volunteers of the Elm Street Community Garden, and she wants the site to work on every screen. In this course, you’ll make it work.
If you’ve ever shrunk a browser window and watched a page fall apart, this course shows you how to build it from the small screen up. You’ll check each page in DevTools’ device mode at three widths and at 200% zoom. You’ll learn how to:
- Write mobile-first media queries, with breakpoints where the content breaks.
- Let grids, type, and spacing adapt by themselves with
auto-fit,minmax(), andclamp(). - Make a card change its layout from the width of its container.
- Serve images at the right size and in modern formats with
srcset,sizes, and the picture element. - Use
:is(),:where(),:has(), and nesting, after checking each feature’s Baseline status.
Each section mixes text lessons and short videos with exercises you write in the browser, where automated tests check your code. In the project, you make the garden’s whole site responsive: a mobile-first layout, a hero photo in modern formats, a volunteer card that fits any slot, and plot rows that find their own badges. Then you explain your site to the AI mentor and take a quiz.
This course is for programmers who know JavaScript basics, or the equivalent in another language. You should know flexbox and grid, the cascade and its layers, custom properties, and DevTools’ Styles and Computed panes. You’ll need a current Chrome or Edge and an editor with a live preview. It’s the fifth of seven courses on the HTML and CSS Foundations path. Starting here? The first lesson gives you the garden’s files.
What’s Included:
- 24 Lessons
- Video Subtitles and Full Transcripts
- Translated Subtitles in 8 Languages
- 2 Downloadable Resources
- Interactive Quiz to Check Your Progress
- 7 Hands-On Coding Exercises
- Q&A With JavaScript Experts: Ask a Question
- Certificate of Completion
Downloadable Resources:
Related Learning Paths: