<?php $this->load->view('web/layout/header'); ?>

<body class="bg-primary">

    <div class="authentication-page hero-1 py-5">
        <!-- bg-overlay-img -->
        <div class="bg-overlay overflow-hidden bg-transparent">
            <div class="hero-1-bg"></div>
        </div>

        <div class="container">
            <div class="row justify-content-center  mt-sm-5">
                <div class="col-md-8 col-lg-6 col-xl-5">
                    <div>
                        <div class="text-center mb-5">
                            <a href="index-1.html" class="mb-3 d-block auth-logo">
                                <img src="<?php echo base_url('public/assets/web/images/logo-light.png'); ?>" alt="" height="65" class="logo">
                            </a>
                        </div>

                        <div class="card">
                            <div class="card-body p-4">
                                <div class="text-center mt-2">
                                    <h5>Seja bem-vindo!</h5>
                                    <p>Digite suas credenciais para fazer login.</p>

                                </div>

                                <!-- Error Alert -->
                                <?php if ($message = $this->session->flashdata('error_message')) : ?>
                                    <div class="alert alert-danger alert-dismissible fade show">
                                        <strong>Ops!</strong> <?php echo $message; ?>
                                        <button type="button" class="btn-close" data-bs-dismiss="alert"></button>
                                    </div>
                                <?php endif; ?>
                                <!--  -->

                                <div class="p-2 mt-4">

                                    <?php echo form_open('restricted/auth/login'); ?>
                                    <div class="mb-3">
                                        <label class="form-label" for="email">Email</label>
                                        <input type="text" class="form-control" id="email" name="email" placeholder="Digite seu email...">
                                    </div>

                                    <div class="mb-3">
                                        <label class="form-label" for="password">Senha</label>
                                        <input type="password" class="form-control" id="password" name="password" placeholder="Digite sua senha...">
                                    </div>

                                    <div class="form-check">
                                        <input type="checkbox" class="form-check-input" id="remember">
                                        <label class="form-check-label" name="remember" for="remember">Manter-se conectado</label>
                                    </div>

                                    <div class="mt-3 d-grid">
                                        <button class="btn btn-info" type="submit">Entrar</button>
                                    </div>


                                    <div class="mt-4 text-center">
                                        <a href="#" class="text-body"><i class="mdi mdi-lock mr-1"></i> Esqueçeu sua senha ?</a>
                                    </div>
                                    <?php echo form_close(); ?>
                                    <!-- end-form -->

                                </div>
                            </div>
                        </div>

                        <div class="mt-5 mb-5 text-center text-white-50">
                            <p>Ainda não tem uma conta ? <a href="<?php echo base_url('restricted/auth/create_account'); ?>" class="font-weight-semibold text-white"> Criar conta </a> </p>
                        </div>

                    </div>
                </div>
            </div>
            <!-- end row -->
        </div>
        <!-- end container -->
    </div>


    <!-- Javascript -->
    <script src="<?php echo base_url('public/assets/web/js/bootstrap.bundle.min.js'); ?>" async defer></script>
    <script src="<?php echo base_url('public/assets/restricted/vendor/sweetalert/sweetalert.min.js'); ?>"></script>
    <!-- unicon -->
    <script src="https://unicons.iconscout.com/release/v2.1.11/script/monochrome/bundle.js"></script>
    <?php if ($this->session->flashdata('success_message') != ""):?>]
        <script>
            swal({
            title: "Perfeito",
            text:  "Parabéns sua conta foi criada com sucesso!",
            icon: "success",
            button: "OK",
            }).then((confirmed) => {
            })
        </script>
    <?php endif;?>


</body>

</html>