I don’t have time to dig into this now so, the best approach is changing the default php to 8.4.
Note: If your sites are using the default PHP version instead of an specific PHP version, change the backend template of those websites to use the right PHP version they need.
v-add-web-php 8.4
v-change-sys-php 8.4
sed -i 's/1\.7\.6/1.7.5/' /var/lib/roundcube/program/include/iniset.php
v-add-sys-roundcube