include ../mixins/flashMessages

doctype html
html
	head
		meta(charset="utf-8")
		meta(name="viewport", content="initial-scale=1.0,user-scalable=no,maximum-scale=1,width=device-width")
		title Sign into #{brand ? brand : 'Keystone'}
		link(rel="stylesheet", href="/keystone/styles/auth.min.css")
		link(rel="shortcut icon", href="/favicon.ico", type="image/x-icon")
		block css
			
	body: .auth-wrapper
		
		+flash-messages(messages)
		if !messages
			.alert.alert-placeholder &nbsp;
		.auth-body(class=messages && messages.error.length ? 'has-errors' : null)
			block content
		
		block footer
			.auth-footer
				| Powered by 
				a(href='http://keystonejs.com', target='_blank', title='The Node.js CMS and web application platform (new window)') KeystoneJS
		
		//- Page Scripts
		block js
		
		//- Google Analytics
		if env == 'production' && ga.property && ga.domain
			script.
				(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
				(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
				m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
				})(window,document,'script','//www.google-analytics.com/analytics.js','ga');
				ga('create', '#{ga.property}', '#{ga.domain}');
				ga('send', 'pageview');
