HTML: Dropdown of a select field should have the same width

I need a method to give the options (the dropdown) of a native select element the same width as the select field.

So if I give a select field the width 8rem using css (select { width: 8rem}) then I want all elements in my dropdown to be 8rem wide as well. If the text of an option is longer, it should wrap.

Is this somehow possible with a native select? I am not allowed to use/build a custom select field for accessibility reasons. I know select fields are hard to style but maybe there is a good workaround im not aware of.

I can use javascript, css and html.