<?php
$config = include 'config.php';

$weblink = $config['weblink'];
$brandname = $config['brandname'];
$visione = $config['visione'];
$footerstatu = $config['footerstatu'];
$email = $config['email'];
$whatsapp = $config['whatsapp'];
?>

<div class="modal fade" id="confirm-delete" tabindex="-1" aria-labelledby="confirmDeleteLabel" aria-hidden="true">
    <div class="modal-dialog modal-dialog-centered">
        <div class="modal-content bg-gray-900 border border-gray-700 rounded-xl shadow-xl">
            <div class="modal-header border-b border-gray-700 p-4">
                <h4 class="text-xl font-semibold text-white" id="confirmDeleteLabel">Confirmar Exclusão</h4>
                <button type="button" class="text-gray-400 hover:text-white transition-colors" data-bs-dismiss="modal" aria-label="Close">
                    <i class="fas fa-times"></i>
                </button>
            </div>
            <div class="modal-body p-4 text-gray-300">
                <div class="flex items-center space-x-3">
                    <i class="fas fa-exclamation-triangle text-blue-600 text-lg"></i>
                    <p>Tem certeza de que deseja excluir este item? Esta ação é irreversível.</p>
                </div>
            </div>
            <div class="modal-footer border-t border-gray-700 p-4">
                <button type="button" class="px-4 py-2 bg-gray-700 text-gray-200 rounded-lg hover:bg-gray-600 transition-colors" data-bs-dismiss="modal">Cancelar</button>
                <a class="btn-ok px-4 py-2 bg-blue-800 text-white rounded-lg hover:bg-blue-700 transition-colors">Excluir</a>
            </div>
        </div>
    </div>
</div>

<?php if ($footerstatu == 'enable') { ?>
<div class="container-fluid pt-5 px-4 bg-gray-900">
    <div class="bg-gray-800 rounded-xl p-6 shadow-lg">
        <div class="row flex flex-wrap items-center">
            <div class="col-12 col-lg-6 mb-4 lg:mb-0">
                <div class="flex flex-col items-center lg:items-start text-center lg:text-left">
                    <div class="flex items-center space-x-3">
                        <div class="w-12 h-12 bg-blue-800 rounded-lg flex items-center justify-center text-white text-xl">
                            <i class="fas fa-cube"></i>
                        </div>
                        <div>
                            <h3 class="text-2xl font-bold text-blue-400"><?php echo $brandname; ?></h3>
                            <p class="text-gray-400 text-sm mt-1 font-['Inter',_sans-serif]"><?php echo $visione; ?></p>
                        </div>
                    </div>
                    <div class="flex flex-wrap gap-3 mt-4 justify-center lg:justify-start">
                        <span class="px-3 py-1 bg-blue-900 text-blue-300 rounded-full text-sm font-medium">Seguro</span>
                        <span class="px-3 py-1 bg-blue-900 text-blue-300 rounded-full text-sm font-medium">Rápido</span>
                        <span class="px-3 py-1 bg-blue-900 text-blue-300 rounded-full text-sm font-medium">Confiável</span>
                    </div>
                </div>
            </div>
            <div class="col-12 col-lg-6 flex justify-center lg:justify-end">
                <div class="flex flex-col items-center lg:items-end">
                    <h5 class="text-blue-400 font-semibold mb-2">Conecte-se Conosco</h5>
                    <div class="flex gap-3">
                        <a href="<?php echo $weblink; ?>" class="w-10 h-10 flex items-center justify-center bg-blue-600 text-white rounded-lg hover:bg-blue-500 transition-colors" title="Telegram">
                            <i class="fab fa-telegram-plane"></i>
                        </a>
                        <a href="<?php echo $whatsapp; ?>" class="w-10 h-10 flex items-center justify-center bg-green-500 text-white rounded-lg hover:bg-green-400 transition-colors" title="WhatsApp">
                            <i class="fab fa-whatsapp"></i>
                        </a>
                        <a href="mailto:<?php echo $email; ?>?subject=Olá%20<?php echo urlencode($brandname); ?>&body=Tenho%20interesse%20em%20seus%20serviços." class="w-10 h-10 flex items-center justify-center bg-gray-400 text-white rounded-lg hover:bg-gray-300 transition-colors" title="Email">
                            <i class="fas fa-envelope"></i>
                        </a>
                    </div>
                </div>
            </div>
        </div>
        <div class="mt-6 pt-4 border-t border-gray-700 flex flex-col lg:flex-row justify-between items-center text-gray-400 text-sm">
            <p>© <?php echo date('Y'); ?> <?php echo $brandname; ?>. Todos os direitos reservados.</p>
            <p>Desenvolvido por <span class="text-blue-400">Play Develop</span></p>
        </div>
    </div>
</div>
<?php } ?>

<style>
.version {
    font-size: 0.75rem;
    color: #6b7280;
    vertical-align: bottom;
    position: relative;
    top: 6px;
}

.bytx {
    font-family: 'Inter', sans-serif;
    font-size: 0.9rem;
    color: #60A5FA;
    vertical-align: middle;
    font-weight: 500;
}

@media (max-width: 576px) {
    .footer-column-center {
        align-items: center !important;
        text-align: center !important;
    }
}
</style>

<script src="https://code.jquery.com/jquery-3.6.0.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.0/dist/js/bootstrap.bundle.min.js"></script>
<script src="lib/chart/chart.min.js"></script>
<script src="lib/easing/easing.min.js"></script>
<script src="lib/waypoints/waypoints.min.js"></script>
<script src="lib/owlcarousel/owl.carousel.min.js"></script>
<script src="lib/tempusdominus/js/moment.min.js"></script>
<script src="lib/tempusdominus/js/moment-timezone.min.js"></script>
<script src="lib/tempusdominus/js/tempusdominus-bootstrap-4.min.js"></script>

<script src="https://cdn.tailwindcss.com"></script>

<script src="js/main.js"></script>

<script>
$(document).ready(function() {
    $('#confirm-delete').on('show.bs.modal', function(e) {
        $(this).find('.btn-ok').attr('href', $(e.relatedTarget).data('href'));
    });

    var tooltipTriggerList = [].slice.call(document.querySelectorAll('[title]'));
    var tooltipList = tooltipTriggerList.map(function (tooltipTriggerEl) {
        return new bootstrap.Tooltip(tooltipTriggerEl, {
            placement: 'top',
            trigger: 'hover'
        });
    });
});
</script>