@using OurUmbraco.Our.Controllers
@using reCAPTCHA.MVC
@inherits UmbracoViewPage<Umbraco.Web.Models.LoginModel>
@{
    Html.EnableClientValidation(true);
    Html.EnableUnobtrusiveJavaScript(true);
}

@if (Request.QueryString["success"] == null)
{
    <div class="form simpleForm" id="registrationForm">
        @using (Html.BeginUmbracoForm<LoginController>("ForgotPassword"))
        {
            @Html.ValidationSummary(true)
            @Html.AntiForgeryToken()
        
            <fieldset>
                <p>
                    @Html.LabelFor(m => m.Username, new { @cless = "inputLabel" })<br />
                    @Html.ValidationMessageFor(m => m.Username)

                    @Html.TextBoxFor(m => m.Username, new { @class = "email title" })
                </p>
            </fieldset>

            <fieldset>
                <p>
                    @Html.Recaptcha()
                    @Html.ValidationMessage("ReCaptcha")
                </p>
            </fieldset>
            <input class="button green" type="submit" value="Retrieve password">
        }
    </div>
}
else
{
    <p>If an account with that email exists you have just been sent instructions to reset your password.</p>
}

<style type="text/css">
    .field-validation-error, .validation-summary-errors {
        color: red;
    }

    .input-validation-error {
        border-color: red !important;
    }
</style>
