How to change the background color on a input checkbox with css? [duplicate]
问题 This question already has answers here : How to style a checkbox using CSS (31 answers) CSS ''background-color" attribute not working on checkbox inside <div> (8 answers) Closed 3 years ago . Hello Friends all I'm trying to do is change the background color of a checkbox. I tired many things but nothing works. Can some one help? input[type="checkbox"] { background: #3d404e; border: #7f83a2 1px solid; } 回答1: I always use pseudo elements :before and :after for changing the appearance of