Reference a field name relatedTo(category)
Not sure I totally get your problem, but you can use bracket style notation to use variables for field handles, i.e.

{{ variable[someVariableHandle].topLeftStyles }}


or even something like

{{ variable[someVariableHandle][someVariableProperty] }}


As for actually outputting the fields in a sane manner, you'll need to map the variable field handles to your entries in some way – one way to do it is to simply use a naming convention for the field handles where you use some unique property on the entries (e.g. the entry ID) as part of the handle:

...
{% set fieldHandle = 'fieldname-'~entry.id' %}
{% if variable[fieldHandle] is defined %}
    {{ variable[fieldHandle].topLeftStyles }}
{% endif %}
...


Another way is to manually set up a map in your template – here's an example using entry IDs for keys, and the field handles for values:

{% set fieldHandles = {
    35: 'someFieldHandle',
    464: 'anotherFieldHandle'
} %}
...
{% for variable in sitemap.relatedTo(category) %}
    {% set fieldHandle = fieldHandles[variable.id] ?? null %}
    {% if fieldHandle and variable[fieldHandle] is defined %}
        &lt;span class="placeinphoto__dot" style="{{ variable[fieldHandle].topLeftStyles }}"&gt;{{ variable.title }}&lt;/span&gt;
    {% endif %}
{% endfor %}