Background properties do not inherit, but the parent element's background will shine through by default because of the initial 'transparent' value on 'background-color'.
HTML content:
<div style="background-color: gray; color: red">
Text outside the list
<ul>
<li>
Text in the list
</li>
</ul>
</div>
The result when exported to DOCX/PDF:
Workaround: set the style directly to the <ul> element:
<div style="background-color: gray; color: red">
Text outside the list
<ul style="background-color: gray;">
<li>
Text in the list
</li>
</ul>
</div>