Command Palette

Search for a command to run...

Hectal
Phase 1: Selectors
CSS · Exercise 2 of 5 PreviousNext
Beginner

Style a nested menu with combinators

Without changing the HTML or adding classes:

Make only the top-level menu items bold (the nested ones must stay normal weight). Make only the paragraph directly after the h2 italic. Give every top-level item except the first a 1px solid border on top.

What Check tests

  1. Top-level items are bold
  2. Nested items are not bold
  3. Only the paragraph right after the h2 is italic
  4. The first item has no top border
  5. The other top-level items have a 1px top border
  6. Nested items have no top border

Stuck? One hint at a time

The solution unlocks after your first Check. Try first: that is where the learning happens.

Runs in your browser. Your code is saved here.

Your page

Press Run to see the page.

Console

Nothing logged yet.