<style>
.footer {
    margin: 4px;
    margin-bottom: 0px;
    border-radius: 5px 5px 0px 0px;
    padding: 7px 4px 2px;
    background: #40599b;
    color: #fff;
    box-shadow: rgba(0, 0, 0, 0.16) 0px 1px 4px;
}
</style>
<footer id="footer" class="footer d-none d-lg-block">
    <div class="container">
        <div class="copyright">
            <div class="">
                &copy; Copyright <strong>PIMS - All Rights Reserved</strong> & Developed by <a
                    href="https://digix.in">DiGi X</a>
            </div>
            <div class="">
                <a href="t&c.php" class="text-white text-decoration-none">Terms & Conditions</a>
            </div>
        </div>
    </div>
</footer>

<div class="m-5 d-block p-1 d-lg-none"></div>
<?php
    $admin_sql = mysqli_query($con, "SELECT * FROM users WHERE utype = 'master_admin' ");
    if ($admin_row = mysqli_fetch_assoc($admin_sql)) {
        $contact = $admin_row["ucontact"];
        $whatsapp = $admin_row["uwhatsapp"];
        $whatsappMessage = urlencode("Hello, I need assistance."); // Encode message for URL
    }
?>

<footer id="footer footer-mob" class="footer d-block d-lg-none">
    <div class="container">
        <div class="row justify-content-between">
            <div class="col text-center">
                <a href="https://wa.me/<?php echo $whatsapp; ?>?text=<?php echo $whatsappMessage; ?>"
                    class="text-white text-center" style="text-decoration:none;" target="_blank">
                    <i class="fab fa-whatsapp footer-icon-mob" aria-hidden="true"></i>
                    <p class="m-0 footer-text-mob">WhatsApp</p>
                </a>
            </div>

            <div class="col text-center">
                <a href="tel:<?php echo $contact; ?>" class="text-white text-center" style="text-decoration:none;">
                    <i class="fa fa-phone footer-icon-mob"></i>
                    <p class="m-0 footer-text-mob">Call</p>
                </a>
            </div>
            <div class="col text-center">
                <a href="t&c.php" class="text-white text-decoration-none">
                    <i class="fa fa-file-contract footer-icon-mob fs-4"></i>
                    <p class="m-0 footer-text-mob">T & C</p>
                </a>
            </div>
        </div>
    </div>
</footer>