You can define different CSS classes that will be used to assign to the 'cls' property for the message dialog. Please try this code:
<style type="text/css">
.cls1,.cls1:hover,.cls1>.panel-header{
border-color: red;
background: red;
}
.cls1>.panel-body{
border-color: red;
background: red;
}
.cls1>.dialog-toolbar,.cls1>.dialog-button{
border-color: red;
background: red;
}
</style>
Apply this 'cls1' CSS class to the message dialog.
$.messager.alert({
title: 'My Title',
msg: 'Here is a error message!',
icon: 'error',
cls: 'cls1'
});