Tsallaka zuwa abun ciki
Justice Tech School

CSS and Accessibility

Use enough colour contrast, never remove focus outlines without replacing them, support zoom with relative units and respect prefers-reduced-motion. Good CSS helps everyone.

Example
<style>
button { background: #0f766e; color: #fff; padding: 8px 14px; border: 0 } button:focus-visible { outline: 3px solid #fbbf24; outline-offset: 2px }
</style>
<button>Tab to me</button>

Exercise

Keyboard focus style.

:focus-

Quiz Test

Minimum contrast for normal text?

These free lessons are for learning. Join a full course for projects, mentor feedback and a verified certificate.