How to add CSS to text located in submit.php file

A contact form forms part of a single-page website. It is situated at the bottom of the page. When the form is completed successfully by a user a ‘success’ message is generated and displayed immediately above the contact form. I wish to add CSS to the text of that message. Specifically, centering the text and changing the colour.

The form is controlled by contact.php and submit.php. The actual text is contained in an ‘echo’ statement in submit.php.

contact form code

<div class="container">
     <div id="responseMessage"></div>
    <div class="wrapper">
        <div class="form-inner-cnt" id="contact-page">
            <!--  -->
            <!-- <form action="" method="post" class="cnt-form"> -->
             <form id="contactForm" method="post" class="cnt-form">
                
                <!-- Status message -->
                                
                <!-- Form fields -->
                <div class="form-input">
                    <input type="text" name="name" id="name" placeholder="Name" value="" required="">
                </div>
                <div class="form-input">
                    <input type="email" name="email" id="email" placeholder="Email" value="" required="">
                </div>
                <div class="form-input">
                    <textarea name="message" id="message" placeholder="Message" required=""></textarea>
                </div>
                </div>
                <input type="submit" name="submit" class="btn" value="SEND">
            </form>
        </div>
    </div>

Part of submit.php

        // Send email
                // @mail($toEmail, $emailSubject, $htmlContent, $headers);

                //   echo json_encode(['status' => 'success', 'message' => 'Thank you for your message. We will respond as soon as possible.']);


            if (mail($toEmail, $emailSubject, $htmlContent, $headers)) {

                echo json_encode(['status' => 'success', 'message' => 'THANK YOU FOR YOUR MESSAGE. WE WILL RESPOND AS SOON AS POSSIBLE.']);
            } else {
                echo json_encode(['status' => 'error', 'message' => 'Failed to send your message.']);
            }
} 
?>

Any assistance would be much appreciated