<%@ Master Language="C#" Inherits="Bitrix.UI.BXMasterPage" %>
<%@ Import Namespace="Bitrix.IO" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head runat="server">
<meta http-equiv="X-UA-Compatible" content="IE=7" />
<meta name="keywords" content="<%= Encode(Keywords["keywords"]) %>" /> 
<meta name="description" content="<%= Encode(Keywords["description"]) %>" /> 
<title></title>
<link rel="shortcut icon" href="<%= VirtualPathUtility.ToAbsolute("~/favicon.ico") %>" type="image/x-icon"/> 
<link rel="stylesheet" type="text/css" media="print" href="<%= ResolveUrl("print.css") %>" />
<link rel="alternate stylesheet" type="text/css" media="screen,projection" href="<%= ResolveUrl("print.css") %>" title="print" />
<!--[if lt IE 6]><style type="text/css">#main-page{width:100%;}</style><![endif]-->
<!--[if lt IE 7]><style type="text/css">#main-column{overflow-x:hidden;} </style><![endif]-->
<!--[if IE]><style type="text/css">table.data-table { border-collapse: collapse; }</style><![endif]-->
</head>
<body>
	<form id="form" runat="server">
		<div id="panel"><bx:TemplateRequisite runat="server" ID="Requisite"/></div>
		
		<div id="page-container">
			<div id="header">
				<div id="company-info">
					<div id="company-logo"></div>
					<div id="company-name">
						<bx:IncludeComponent ID="CompanyName" runat="server" ComponentName="bitrix:includeArea" Template=".default" Mode="File" RecursiveFileSearch="True" FilePath="~/bitrix/templates/portal/company.html" FileName="" FileNameSuffix=""/>
					</div>
				</div>
				<div id="auth">
					<div id="auth-align-bottom">
					<bx:IncludeComponent runat="server" ID="Auth" ComponentName="bitrix:system.login" Template="portal" RegisterPath="~/Auth.aspx?auth_page=register" ProfilePath="~/profile/profile.aspx" PasswordRecoveryPath="~/Auth.aspx?auth_page=recovery" PasswordRecoveryCodePath="" LoginRedirectPath="" />
					</div>
				</div>
			</div>
			<div id="top-menu-section">
				<div id="top-menu">
					<bx:IncludeComponent runat="server" ID="MainMenu" ComponentName="bitrix:system.PublicMenu" Depth="4" Template="primary" MenuName="top" SubMenuName="left" />
				</div>
				<div id="search">
					<bx:IncludeComponent runat="server" ID="SearchForm" ComponentName="bitrix:search.form" Template="portal" SearchUrlTemplate="~/search/?q=#QUERY#" />
				</div>
			</div>
			<%	
				string show = Keywords["ShowLeftColumn"].ToLowerInvariant();
				bool showLeft = show != "n" && show != "false";
			%>
			<div id="breadcumb-section">
				<div id="navigation">
					<bx:IncludeComponent runat="server" ID="Navigation" ComponentName="bitrix:system.PublicBreadCrumb" Template="portal" RootItemTitle="Home" ShowOnIndexPage="False" />
				</div>
				<div id="site-icons">
					<a href="" onclick="return AddToBookmark()" class="favourite-icon" title="Add to favourites"></a>
					<a href="#print" rel="nofollow" target="_blank" class="print-icon" title="Print Version"></a>
					<a href="<%= VirtualPathUtility.ToAbsolute("~/search/map.aspx") %>" class="sitemap-icon" title="Site map"></a>
				</div>
			</div>
			<div id="page-content">
				<% if (showLeft) { %>
				<div id="left-column">
					<bx:IncludeComponent runat="server" ID="LeftMenu" ComponentName="bitrix:system.PublicMenu" Template="secondary" Depth="1" MenuName="left" SubMenuName="left" />
					<div align="center" style="margin-top: 20px" class="banner"><bx:IncludeComponent runat="server" ID="banner1" ComponentName="bitrix:advertising.banner" Template=".default" Space="LEFT" /></div>
					&nbsp;
				</div>
				<% } %>
				<div id="<%= showLeft ? "main-column" : "main-page" %>">
					<h1><%= TitleHtml %></h1>
					<asp:ContentPlaceHolder ID="BXContent" runat="server" />
				</div>
				<% if (showLeft) { %>
				<div style="clear:both"></div>
				<% } %>
			</div>
			<div align="center" style="margin-top: 50px" class="banner"><bx:IncludeComponent runat="server" ID="banner2" ComponentName="bitrix:advertising.banner" Template=".default" Space="BOTTOM" /></div>
			<div id="space-for-footer"></div>
		</div>
		<div id="footer">
			<div id="footer-separator"></div>
			<div id="copyright">Powered by Bitrix Site Manager ASP.NET. Copyright &copy 2001-2009 Bitrix, Inc.</div>
			<div id="footer-links">
				<a href="<%= VirtualPathUtility.ToAbsolute("~/search/") %>">Search</a>&nbsp;&nbsp;
				<a href="<%= VirtualPathUtility.ToAbsolute("~/search/map.aspx") %>">Site map</a>
			</div>
		</div>
	</form>
</body>
</html>
<script runat="server">
	protected override void OnPreRender(EventArgs e)
	{
		base.OnPreRender(e);
		BXPage.RegisterScriptInclude(BXPath.Combine(AppRelativeTemplateSourceDirectory, "script.js"));
	}
</script>