How can I get the responsive image style id from a FileFieldItemList I am trying to get the machine name of the responsive image style attached to a field. I am not able to get this from the settings attached; it seems it is not accessible from the object in any way.

How can I get the responsive image style ID from a FileFieldItemList?
This setting is not a field setting. Because a field can be part of different displays. You have to look for this setting in a view mode. For example if you configure the image field of the article with a responsive image style, your view mode would contain something like this:

core.entity_view_display.node.article.default:
  content:
    field_image:
      type: responsive_image
      weight: 0
      settings:
        responsive_image_style: *responsive_image_style_id*