var CP = CP || {};
CP.lpUI = CP.lpUI || {};

var temp =  (function() {
	return {
		test : "blah",
		page : (function(){
			var tvDiv;
			var logoLink;
			
			var header = DIV( {style : {height : "180px", width : "1003px"}},
						DIV({id : "cplogobutton", style : {left : "90px"}}, A({href : "http://www.circuspop.com"})),
						DIV({style : {position : "absolute", left : "510px", top : "90px"}},
								IMG({src : CP.util.staticURL("site/images/lp_tagline.png"), style : {height : "20px", width : "400px"}})),
						DIV({style : {position : "absolute", top : "150px", "z-index" : "20"}}, IMG({src : CP.util.staticURL("site/images/lp_topbar.png")}))
					);
			
			var body = DIV({style : {color : "#666666", font : "14px/15px Verdana, sans-serif", "margin" : "20px 0px 0px 25px", "float" : "left",
							position : "relative", "z-index" : "1"}},
						DIV({style : {width : "247px", height : "25px", "margin-left" : "15px"}}, 
							IMG({src : CP.util.staticURL("site/images/lp_title.png")})),
						DIV({style : {width : "600px", "margin-left" : "10px"}},
							P(CP.lang.lp_p1),
							P(CP.lang.lp_p2),
							P(CP.lang.lp_p3)),
						tvDiv = DIV({style : {width : "480px", height : "335px", overflow : "hidden", left : "97px", top : "179px",
									position : "absolute", "z-index" : "6", "background-color" : "black"}}),
						DIV({style : {position : "absolute", left : "10px", top : "150px", "z-index" : "5"}},
								IMG({src : CP.util.staticURL("site/images/lp_tvflatscreen clear.png"), style : {"z-index" : "5"}}))
					);
			
			tvDiv.html(CP.util.generateFlashEmbedHTML("http://www.youtube.com/v/jFenI-c0I-A&hl=en&fs=1&autoplay=1", 480, 344, "youtubevideo"));
			
			return {
				draw : function(){
					var signinFunc = function(){CP.controller.goToUnsecure({section : "signin"})};
					var regFunc = function(){CP.controller.goToUnsecure({section : "register"})};
					var recentDeals = DIV({style : {"float" : "right", "margin" : "27px 20px 0px 0px"}},
							DIV({style : {width : "230px", height : "115px", "margin-bottom" : "27px",
								background : "url(" + CP.util.staticURL("site/images/video-art-animated-larger.gif") + ") 0px 0px"}}),
							CP.unsecureUI.recentDealsPanel(signinFunc, regFunc).draw());
					
					var div = DIV({style : {width : "1003px", margin : "0 auto", position : "relative"}}, header, body, recentDeals);
					return div;
				},
				checkLocation : function(){
					
				}
			};
		})()
	};
})();

$.extend(CP.lpUI, CP.unsecureUI);
$.extend(CP.lpUI, temp);

