<style> INPUT:checked + label {color: #00F;} </style> <input id="theId" type="checkbox"><label for="theId"> The cat is here</label> <fieldset style="width:fit-content"><legend>Where is the Cat?</legend> <input id="cat_garden" name="cat_where" type="radio"><label for="cat_garden"> Garden</label> <input id="cat_bed" name="cat_where" type="radio"><label for="cat_bed"> Bed</label> <input id="cat_cushion" name="cat_where" type="radio"><label for="cat_cushion"> Cushion</label> </fieldset>