```python
def line_up(links: dict[str, str], start: str) -> list[str]:
    """Follow a name up through a book of links and return the line from start to the top."""
    if start not in links:
        raise ValueError(f"Start name '{start}' not found in links")
    
    line = []
    current = start
    visited = set()
    
    while True:
        if current in visited:
            raise ValueError("Circular link detected")
        visited.add(current)
        line.append(current)
        
        if current not in links:
            break
        
        next_name = links[current]
        current = next_name
    
    return line
```