<link rel="stylesheet" href="footer.css">
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap-icons@1.10.0/font/bootstrap-icons.css">
<div class="footer">
    <div class="footer-container">
        <div class="left-footer">
            <div class="footer-info">
                <?php 
                $query = "SELECT * FROM deskripsi_sekolah";
                $result = mysqli_query($host,$query);
                $row = mysqli_fetch_assoc($result);
                $deskripsi = $row['paragraf_1'];

                $query_sekolah = "SELECT * FROM sekolah";
                $result_sekolah = mysqli_query($host,$query_sekolah);
                $row_sekolah = mysqli_fetch_assoc($result_sekolah);
                $nama_sekolah = $row_sekolah['nama_sekolah'];
                $slogan_sekolah = $row_sekolah['slogan_sekolah'];
                $logo_sekolah = $row_sekolah['logo_sekolah'];

                if ($row){
                ?>
            <h2 class="head" style="text-transform: uppercase;"><?php echo $nama_sekolah; ?></h2>
            <p class="deskripsi"><?php echo $deskripsi; ?></p>
            <div class="footer-button">
                <a href="#top">back to top</a>
            </div>
        </div>
        <?php } ?>
        </div>
        <div class="right-footer">
            <div class="contact-us">
                <h1>Contact Us</h1>
                <?php
                include 'koneksi.php';
                $query = "SELECT * FROM tb_alamat";
                $result = mysqli_query($host,$query);
                $row = mysqli_fetch_assoc($result);
                $alamat = $row['alamat'];
                $email = $row['email'];
                $sekolah = $row['nomor_sekolahh'];
                $yt = $row['link_youtube'];
                $ig = $row['link_instagram'];
                echo "<p class='info'> $alamat </p>";
                echo "<p class='info'> $email </p>";
                echo "<p class='info'> $sekolah </p>";
                echo "<div class='media-sosial'>";
                echo "<a href='$ig' target='_blank'><i class='bi bi-instagram'></i></a>";
                echo "<a href='$yt' target='_blank'><i class='bi bi-youtube'></i></a>";
                echo "</div>";
                ?>
            </div>
        </div>
    </div>
</div>
