Put this code behind the summary sheet:

Private Sub Worksheet_Change(ByVal Target As Range)

If Not Intersect(Target, Range("K1")) Is Nothing Then
    Set Rng = Range("A7:A" & Range("A50000").End(xlUp).Row & "")
    
    For Each x In Rng.Cells
        If x.Value = "----------" Then
            Rows(x.Row).Hidden = True
        Else
            Rows(x.Row).Hidden = False
        End If
    Next x
End If

End Sub

The If Not Intersect line is optional but it means the code will only run if a cell (or cells) within a defined range is changed (in this case cell K1). Otherwise it will run if any cell on the sheet is changed.