```python
def selector_hits(values: list, selector: str) -> int:
    """
    Counts how many values match at least one term in the selector.
    A value matches if it is in any of the ranges or equals any of the terms.
    """
    if not isinstance(values, list) or not all(isinstance(x, int) for x in values):
        raise ValueError("values must be a list of integers")
    if not isinstance(selector, str) or not selector:
        raise ValueError("selector must be a non-empty string")
    
    def parse_term(term: str) -> tuple:
        if '-' in term:
            low, high = map(int, term.split('-'))
            if low > high:
                raise ValueError("range low end cannot exceed high end")
            return (low, high)
        else:
            return (int(term), int(term))
    
    def matches(value: int, term: tuple) -> bool:
        low, high = term
        return low <= value <= high
    
    terms = [parse_term(term) for term in selector.split(',')]
    hits = sum(1 for value in values if any(matches(value, term) for term in terms))
    return hits
```