← Back to CSS
11

CSS Lists: bullets, numbering and modern styles

Customize lists without losing semantics: clear bullets, continuous numbering and modern layouts.

📘 Theory

Reset and controlled spacing

Start by removing browser styles to define your own rhythm.

Lists come with default margin and padding. If you do not control them, the layout looks misaligned.

Use padding-inline-start to define indentation and list-style-position to choose where the bullet falls.

If there are titles or icons, align the list with the rest of the content using the same vertical rhythm.

  • Remove margin-top/bottom to avoid jumps between sections.
  • Define padding-inline-start in rem so it scales with typography.
  • Try list-style-position: inside when lines are long.

Modern bullets with ::marker

::marker allows styling the bullet without hacks.

With ::marker you can change color, weight and content of the bullet while keeping semantics.

If you need complex icons, combine list-style: none with ::before.

Avoid heavy images: simple bullets scale better in modern UIs.

  • Use ::marker for color and weight without breaking the layout.
  • list-style: none removes bullets when designing a card list.
  • Do not use large images: it affects readability and performance.

Continuous numbering with counters

Ideal when you separate steps into blocks but want continuous numbering.

1

Counters let you control numbering without depending on HTML.

2

Define the counter on the container and increment on each li.

3

If you need to continue in another list, you can reset the counter with an initial value.

Lists as modern layout

A list can be a menu, tags or a light grid.

1

With flex or grid you can turn a list into a row of tags or cards.

2

Remove bullets, define gap and control wrapping for responsiveness.

3

You keep the list semantics but with a modern UI appearance.

🧪 Learn by doing

Example Bullets with color A highlighted bullet without losing semantics.
Example Numbered steps Custom numbering without depending on HTML.
Example Tag list Transform a list into a set of tags.

🏁 Challenges

Challenge Challenge: numbering with counter Set up a counter to display numbers in the marker.

🧰 Resources

What is this?

I'm Cristian Eslava and I sometimes build websites so both you and I can learn and experiment. culTest

I made this in February 2026 to make learning easier for my students. The idea is to learn web development by practicing and to keep expanding the project with new topics, tests and challenges.

It draws inspiration from MDN, W3Schools, CodePen, Manz and many other web development references. I wanted to combine useful theory, runnable examples, challenges and the testing system I had already built for culTest. culTest

If you liked it, if you didn't, or if you want to get in touch, write to me at cristianeslava@gmail.com