A Quick Primer on 11th Amendment and Why sheriffs (and counties) Aren't Immune from 1983 Suits in Federal Court
The 11th amendment (well, a very old and very bad US Supreme Court case interpreting it) bars citizens from suing their states in federal court. But certain agencies of the state do not benefit from that "immunity" (you can still raise the federal claims in state court).
This opinion from the 11th Circuit does a good job of laying out the history and function of the rule and how to apply it to sheriffs (the result: in most functions Florida sheriffs do not benefit from 11th amendment protections). It also has a straightforward suitable statement that counties aren't immune as they are treated like municipalities.