/* Validation and error messages are always red (success messages stay green). Loaded after every other stylesheet.
   js/validation-red.js adds the class "bad" to messages that report a problem, so form messages that are written by scripts are covered too. */
:root{--vr-red:#C0392B}
/* field messages under inputs: always red */
html body .field .em,html body .field.err .em,html body .field.ok .em,html body #trainForm .field .em,html body #trainForm .field.err .em,html body #trainForm .field.ok .em,
html body form .em,html body .em{color:var(--vr-red)!important}
html body #trainForm .field.ok .em::before{background:var(--vr-red)!important}
/* messages marked as a problem by the page or by js/validation-red.js */
html body .bad,html body .msg.bad,html body .up-msg.bad,html body .hd-msg.bad,html body .dn-msg.bad,html body .scp-inline.bad,html body .scp-bad,html body .flash.bad,html body .ok-no,
html body [role="alert"].bad,html body #toast.bad{color:var(--vr-red)!important}
html body .scp-bad,html body .flash.bad,html body .msg.bad{background:#FFF4E5!important;border-color:#E8C9A0!important}
html body #toast.bad{background:#FFF4E5!important;border:1px solid #E8C9A0}
/* the red asterisk of required fields and red borders on invalid fields */
html body .field label .req,html body label .req{color:var(--vr-red)!important}
html body .field.err input,html body .field.err select,html body .field.err textarea,html body input.bad,html body select.bad,html body textarea.bad,
html body input[aria-invalid="true"],html body select[aria-invalid="true"],html body textarea[aria-invalid="true"]{border-color:var(--vr-red)!important}
/* 14 Nov 2026: every error message is red, on every page (job application, Student Management System, e-Signatures, desks, sign-in pages) */
html body #jbErr,html body .ecx-msg.bad,html body .scx-flash.bad,html body .cs-err,html body .pp-err,html body .failbox,html body .vbad,
html body p.err,html body div.err,html body span.err,html body .error,html body .err-msg,html body .alert-error,html body .notice.err,html body .notice.bad,
html body .rec.bad,html body .now.bad,html body .msg.err,html body .ecx-msg.err{color:var(--vr-red)!important}
html body .ecx-msg.bad,html body .notice.bad,html body .notice.err{background:#FDECEA!important;border-color:#F1B0A8!important}
/* buttons, tags and badges marked "bad" keep their own colours */
html body .btn.bad,html body button.bad,html body .eq-btn.bad{color:#fff!important}
