Cambio
HTML + CSSRadio buttons

Automatic gear selector radio

An automatic gear lever slides along the P, R, N, D gate and the chosen letter lights up in amber.

Settings

16px
1x

Code

<fieldset class="uvq04-gear"><legend>Gear</legend><div class="pn"><span class="gt" aria-hidden="true"><i class="kb"></i></span><div class="ls"><label><input type="radio" name="uvq04-gear" checked><b>P</b><span>Park</span></label><label><input type="radio" name="uvq04-gear"><b>R</b><span>Reverse</span></label><label><input type="radio" name="uvq04-gear"><b>N</b><span>Neutral</span></label><label><input type="radio" name="uvq04-gear"><b>D</b><span>Drive</span></label></div></div></fieldset>

Prompt for AI

Paste it into ChatGPT, Claude or Cursor and it will adapt the block to your project with these settings, even if you don’t use React.

Markdown version with all the code, for AI assistants

More in Radio buttons

See all Radio buttons

Where to use it

This radio group borrows the shifter from an automatic car: four real radio inputs sit next to a dark gate, and a round knob slides to the chosen position while its letter glows like a dashboard backlight. It is plain CSS driven by :has, so it suits car configurators, driving apps, playful settings panels and any mode switch with a fixed order.

Change the amber glow with the main color and the console tone with the secondary one. Rename the four modes to fit your product, such as eco, comfort, sport and track, and keep labels short so the rows stay aligned.