See https://www.npmjs.com/package/rollup-plugin-keep-css-imports. Compare index.mjs with index.original.mjs to see the patch.