<%@ page language="VB" autoeventwireup="false" inherits="Auth_ForgotPassword, MachSol.MachPanel.Web" %>

<!DOCTYPE html>
<html>
<head id="Head" runat="server">
    <title id="Title" runat="server">MachPanel&reg; - Login to Control Center</title>

    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=Edge">
    <meta content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no" name="viewport">

     <!-- Google Fonts -->

    <link rel="stylesheet" type='text/css' href='<%# "/css/google/material-icons.css?" + ProductVersion %>'/>

    <!-- Jquery base library -->
    <link rel="stylesheet" type='text/css' href='<%# "/plugins/jquery-ui-1.13.2/jquery-ui.min.css?" + ProductVersion %>'/>

    <!-- Bootstrap Core Css -->
    <link rel="stylesheet" type='text/css' href='<%# "/plugins/bootstrap/css/bootstrap.css?" + ProductVersion %>' />

    <!-- Bootstrap Select Css -->
    <link rel="stylesheet" type='text/css' href='<%# "/plugins/bootstrap-select/css/bootstrap-select.css?" + ProductVersion %>' />
    
    <!-- Waves Effect Css -->
    <link rel="stylesheet" type='text/css' href='<%# "/plugins/node-waves/waves.css?" + ProductVersion %>' />


    <!-- AdminBSB Themes -->
    <link rel="stylesheet" type='text/css' href='<%# "/css/themes/all-themes.css?" + ProductVersion %>' />


    <!-- font-glyphs css -->
    <link rel="stylesheet" type='text/css' href='<%# "/css/font-glyphs.css?" + ProductVersion %>' />

    <!-- Custom Css -->
    <link rel="stylesheet" type='text/css' href='<%# "/css/Style.css?" + ProductVersion %>' />
    
    <style type="text/css">
        .form-horizontal .form-group {
            margin-left: 0px;
            margin-right: 0px;
            margin-bottom: 5px;
        }
    </style>

    <!-- JQuery Framework References -->
    <script type="text/javascript" src='/plugins/jquery/jquery.min.js?<%# ProductVersion %>'></script>
    <script type="text/javascript" src='/plugins/jquery-ui-1.13.2/jquery-ui.min.js?<%# ProductVersion %>'></script>

    <script type="text/javascript" src='/JS/adal.js?<%# ProductVersion %>'></script>
    <script type="text/javascript" src='/JS/aad-login.js?<%# ProductVersion %>'></script>

    <script type="text/javascript" src='/JS/sweetalert/js/swl.js?<%# ProductVersion %>' defer></script>
    <link rel="stylesheet" type='text/css' href='<%# "/JS/sweetalert/css/swl.css?" + ProductVersion %>' />
    <script type="text/javascript" src='/JS/fido2/helpers.js?<%# ProductVersion %>' defer></script>
    <script type="text/javascript" src='/JS/fido2/passwordless.login.js?<%# ProductVersion %>' defer></script>

    <script type="text/javascript" src='/JS/Utility.js?<%# ProductVersion %>'></script>
    <script type="text/javascript" src='/JS/Duo/Duo-Web-v2.js?<%# ProductVersion %>'></script>
    <link rel="icon" href="" type="image/ico" sizes="16x16" id="link_favicon" runat="server">

   

</head>
<body id="Bdy" runat="server">

    <%If MachSol.MachPanel.DBCore.SystemSettings.IsDMP() Then %>
        <link rel="stylesheet" type='text/css' href='/css/sar-customizations.css?<%# ProductVersion %>' /> 
    <%End If%>

    <!-- Page Loader -->
    <div class="page-loader-wrapper">
        <div class="sk-cube-grid">
            <div class="sk-cube sk-cube1"></div>
            <div class="sk-cube sk-cube2"></div>
            <div class="sk-cube sk-cube3"></div>
            <div class="sk-cube sk-cube4"></div>
            <div class="sk-cube sk-cube5"></div>
            <div class="sk-cube sk-cube6"></div>
            <div class="sk-cube sk-cube7"></div>
            <div class="sk-cube sk-cube8"></div>
            <div class="sk-cube sk-cube9"></div>
        </div>
    </div>
    <div class="auth-container">
        <div class="row">
            <div class="col-xs-12 col-lg-offset-2 col-lg-8">
                <div class="card">
                    <div class="body">
                        <form id="form1" runat="server" autocomplete="off" class="form-horizontal">
                            <%--fake fields are a workaround for chrome autofill getting the wrong fields--%>
                            <input style="display: none" type="text" name="fakeusernameremembered" />
                            <input style="display: none" type="password" name="fakepasswordremembered" />
                            <asp:Panel ID="Pnl_Step1" runat="server" DefaultButton="Btn_Submit">
                                <div class="m-t-20 m-b-20 p-l-10 p-r-10">
                                    <asp:Image ID="Img_Logo" runat="server" ImageUrl="~/App_Themes/Default/Images/icons/logo.png" />
                                    <hr />
                                </div>
                                <div class="p-l-10 p-r-10">
                                    <h4>
                                        <asp:Literal ID="Ltl_System" runat="server" Text="<%$ Resources:Content,SPT002014%>"></asp:Literal>
                                    </h4>
                                </div>
                                <div id="Div_Step1" runat="server">

                                    <div style="display: none" id="Div_AuthError" runat="server" class="row">
                                        <div class="col-xs-12">
                                            <div class="form-group p-l-10 p-r-10">
                                                <span class="text-danger">
                                                    <asp:Literal ID="Literal1" runat="server" EnableViewState="false" Text="<%$ Resources:Content,SPT002015%>"></asp:Literal>
                                                    <asp:Literal ID="Literal2" runat="server" EnableViewState="false" Text="<%$ Resources:Content,SPT002017%>"></asp:Literal>
                                                </span>
                                            </div>
                                        </div>
                                    </div>
                                    <div class="row">
                                        <div class="col-xs-12">
                                            <div class="form-group p-l-10 p-r-10">
                                                <h4>
                                                    <asp:Literal ID="Literal3" runat="server" Text="<%$ Resources:Content,SPT002018%>"
                                                        EnableViewState="false"></asp:Literal>
                                                </h4>
                                                <asp:Literal ID="Literal4" runat="server" EnableViewState="false" Text="<%$ Resources:Content,SPT002019%>"></asp:Literal>
                                                <br />
                                                <br />
                                            </div>
                                        </div>
                                    </div>
                                    <div class="row">
                                        <div class="col-xs-12">
                                            <div class="form-group form-float p-l-10 p-r-10">
                                                <div class="form-line">
                                                    <asp:TextBox ID="TxBx_UserName" runat="server" CssClass="form-control"></asp:TextBox>
                                                    <asp:Label ID="Literal5" runat="server" Text="<%$ Resources:Content,SPT002013%>" CssClass="form-label"></asp:Label>
                                                </div>
                                            </div>
                                        </div>
                                    </div>
                                    <div class="row">
                                        <div class="col-xs-12">
                                            <div class="form-group p-l-10 p-r-10">
                                                <span class="pull-right">
                                                    <asp:Button ID="Btn_Submit" CssClass="btn btn-primary" runat="server" Text="<%$ Resources:Content,GN0000710%>" />&nbsp;&nbsp;&nbsp;
                                            <asp:Button ID="Btn_Cancel" CssClass="btn btn-primary" runat="server" Text="<%$ Resources:Content,GN0000572%>" />

                                                </span>
                                            </div>
                                        </div>
                                    </div>
                                </div>
                            </asp:Panel>

                            <asp:Panel ID="Pnl_Step2" runat="server" DefaultButton="Btn_Submit2">
                                <div id="Div_Step2" style="display: none" runat="server">
                                    <div class="row">
                                        <div class="col-xs-12">
                                            <div class="form-group p-l-10 p-r-10">
                                                <h4>
                                                    <asp:Literal ID="Literal7" runat="server" EnableViewState="false" Text="<%$ Resources:Content,SPT002021%>"></asp:Literal>
                                                </h4>
                                            </div>
                                        </div>
                                    </div>
                                    <div style="display: none" id="Div_Error" runat="server" class="row">
                                        <div class="col-xs-12">
                                            <div class="form-group p-l-10 p-r-10">
                                                <span class="text-danger">
                                                    <asp:Literal ID="Literal6" EnableViewState="false" runat="server" Text="<%$ Resources:Content,SPT002015%>"></asp:Literal>
                                                    <asp:Literal ID="Ltl_Reason" runat="server"></asp:Literal>
                                                </span>
                                            </div>
                                        </div>
                                    </div>
                                    <div class="row">
                                        <div class="col-xs-12">
                                            <div class="form-group p-l-10 p-r-10">
                                                <asp:Literal ID="Literal8" runat="server" EnableViewState="false" Text="<%$ Resources:Content,SPT002022%>"></asp:Literal>
                                                <div class="clearfix"></div>
                                                <asp:Literal ID="Literal9" runat="server" EnableViewState="false" Text="<%$ Resources:Content,SPT002023%>"></asp:Literal>
                                            </div>
                                        </div>
                                    </div>
                                    <div class="row" runat="server" id="divSecretKey">
                                        <div class="col-xs-12">
                                            <div class="form-group form-float p-l-10 p-r-10">
                                                <div class="form-line">
                                                    <asp:Label ID="Literal10" runat="server" Text="<%$ Resources:Content,SPT002024%>" CssClass="form-label"></asp:Label>
                                                    <asp:TextBox ID="TxBx_Secret" runat="server" CssClass="form-control"></asp:TextBox>
                                                </div>
                                            </div>
                                        </div>
                                    </div>

                                    <div class="row" runat="server" id="DivQuestion1" visible="false">
                                        <div class="col-xs-2 col-xs-12 row-label">
                                            <asp:Label ID="Label4" runat="server" EnableViewState="false" Text="<%$ Resources:Content,strQuestion %>"></asp:Label>:
                                        </div>
                                        <div class="col-xs-10 col-xs-12">
                                            <asp:DropDownList ID="DDL_Questions1" runat="server">
                                            </asp:DropDownList>
                                        </div>
                                    </div>
                                    <div class="row" runat="server" id="DivAnswer1" visible="false">
                                        <div class="col-xs-12">
                                            <div class="form-group form-float p-l-10 p-r-10">
                                                <div class="form-line">
                                                    <asp:Label ID="Label1" runat="server" Text="<%$ Resources:Content,strAnswer%>" CssClass="form-label"></asp:Label>
                                                    <asp:TextBox ID="TxBx_Answer1" runat="server" CssClass="form-control"></asp:TextBox>
                                                </div>
                                            </div>
                                        </div>
                                    </div>
                                    <div class="row" runat="server" id="DivQuestion2" visible="false">
                                        <div class="col-xs-2 col-xs-12 row-label">
                                            <asp:Label ID="Label2" runat="server" EnableViewState="false" Text="<%$ Resources:Content,strQuestion %>"></asp:Label>:
                                        </div>
                                        <div class="col-xs-10 col-xs-12">
                                            <asp:DropDownList ID="DDL_Questions2" runat="server">
                                            </asp:DropDownList>
                                        </div>
                                    </div>
                                    <div class="row" runat="server" id="DivAnswer2" visible="false">
                                        <div class="col-xs-12">
                                            <div class="form-group form-float p-l-10 p-r-10">
                                                <div class="form-line">
                                                    <asp:Label ID="Label3" runat="server" Text="<%$ Resources:Content,strAnswer%>" CssClass="form-label"></asp:Label>
                                                    <asp:TextBox ID="TxBx_Answer2" runat="server" CssClass="form-control"></asp:TextBox>
                                                </div>
                                            </div>
                                        </div>
                                    </div>
                                    <div class="row" runat="server" id="DivQuestion3" visible="false">
                                        <div class="col-xs-2 col-xs-12 row-label">
                                            <asp:Label ID="Label5" runat="server" EnableViewState="false" Text="<%$ Resources:Content,strQuestion %>"></asp:Label>:
                                        </div>
                                        <div class="col-xs-10 col-xs-12">
                                            <asp:DropDownList ID="DDL_Questions3" runat="server">
                                            </asp:DropDownList>
                                        </div>
                                    </div>
                                    <div class="row" runat="server" id="DivAnswer3" visible="false">
                                        <div class="col-xs-12">
                                            <div class="form-group form-float p-l-10 p-r-10">
                                                <div class="form-line">
                                                    <asp:Label ID="Label6" runat="server" Text="<%$ Resources:Content,strAnswer%>" CssClass="form-label"></asp:Label>
                                                    <asp:TextBox ID="TxBx_Answer3" runat="server" CssClass="form-control"></asp:TextBox>
                                                </div>
                                            </div>
                                        </div>
                                    </div>

                                    <!-- Password Options -->
                                    <div id="Div_PasswordReset" runat="server">
                                        <div class="row">
                                            <div class="col-xs-12">
                                                <div class="form-group form-float p-l-10 p-r-10">
                                                    <div class="form-line">
                                                        <asp:TextBox ID="TxBx_Password" TextMode="Password" runat="server" CssClass="form-control"></asp:TextBox>
                                                        <asp:Label ID="Literal11" runat="server" CssClass="form-label" Text="<%$ Resources:Content,DGN1110554%>"></asp:Label>
                                                    </div>
                                                </div>
                                                <div class="form-group p-l-10 p-r-10">
                                                    <div id="Div_PasswordPolicy" runat="server" class="help-text sm"></div>
                                                </div>
                                            </div>
                                        </div>
                                        <div class="row">
                                            <div class="col-xs-12">
                                                <div class="form-group form-float p-l-10 p-r-10">
                                                    <div class="form-line">
                                                        <asp:TextBox ID="TxBx_ConfirmPassword" TextMode="Password" runat="server" CssClass="form-control"></asp:TextBox>
                                                        <asp:Label ID="Literal12" runat="server" CssClass="form-label" Text="<%$ Resources:Content,GN0001196%>"></asp:Label>
                                                    </div>
                                                </div>
                                            </div>
                                        </div>
                                    </div>

                                    <div class="row">
                                        <div class="col-xs-12">
                                            <div class="form-group p-l-10 p-r-10">
                                                <span class="pull-right">
                                                    <asp:Button ID="Btn_Submit2" runat="server" CssClass="btn btn-primary" Text="<%$ Resources:Content,GN0000710%>" />&nbsp;&nbsp;
                                                    <asp:Button ID="Btn_Cancel2" runat="server" CssClass="btn btn-primary" Text="<%$ Resources:Content,GN0000572%>" /></span>
                                            </div>
                                        </div>
                                    </div>
                                </div>
                            </asp:Panel>

                            <br />
                            <div class="row">
                                <div class="col-xs-12 align-center m-t--15">
                                    <asp:Label ID="Ltl_CopyRight" runat="server" CssClass="hide d-none btn-dummy"></asp:Label>&nbsp;
                                    <asp:LinkButton ID="LB_CompanyLink" runat="server"></asp:LinkButton>
                                </div>
                            </div>
                        </form>
                    </div>
                </div>
            </div>
        </div>
    </div>

    <!-- Bootstrap Core Js -->
    <script type="text/javascript" src='/plugins/bootstrap/js/bootstrap.js?<%# ProductVersion %>'></script>

    <!-- Waves Effect Plugin Js -->
    <script type="text/javascript" src='/plugins/node-waves/waves.js?<%# ProductVersion %>'></script>

    <%--Bootstrap Select Plugin--%>
    <script type="text/javascript" src='/plugins/bootstrap-select/js/bootstrap-select.js?<%# ProductVersion %>'></script>


    <!-- Slimscroll Plugin Js -->
    <script type="text/javascript" src='/plugins/jquery-slimscroll/jquery.slimscroll.js?<%# ProductVersion %>'></script>

    <script type="text/javascript" src='/JS/admin.js?<%# ProductVersion %>'></script>


    <script type="text/javascript">
        $(function () {
            $('input[type=text], input[type=password]').first().focus();
            $('input[type=text], input[type=password]').first().closest('.form-line').addClass('focused');

            $('.form-line').each(function () {
                $this = $(this);
                if ($this.find('input[type=text]').val() && $this.find('input[type=text]').val() != '')
                    $this.addClass("focused");
            });

            $('input[type = checkbox]').addClass("filled-in");
            $('input[type = radio]').addClass("with-gap");
            $('input[type = text]').addClass("form-control");
            $('input[type = password]').addClass("form-control form-password");

            $('.form-control.form-password').on('keyup change blur focus', function () {
                if ($(this).val().indexOf('<') != -1 || $(this).val().indexOf('>') != -1) {
                    $(this).val('');
                    $(this).focus();
                    alert('greater then ">" and less then "<" symbols are not allwoed in passwords.');
                }
                //e.preventDefault();
            });

            jQuery("input[type=text], textarea").keyup(function (event) {
                //skip freetextbox htmleditor control
                var str = $(this)[0].className;
                if (!(str.match(/_HtmlBox/g) || str.match(/allowhtml/g))) {
                    txtValue = $(this).val();
                    txtValue = txtValue.replace(/[\<\>]+/g, '');
                    if (txtValue != $(this).val()) {
                        $(this).val(txtValue);
                    }
                }

            });
        });
    </script>

      <!--Custom JS File-->
    <script type="text/javascript" src='/JS/custom-fixes-rcc.js?<%# ProductVersion %>'></script>
</body>
</html>
