/*------------------------------------------------------------------------------------------------*/
/*- CSS parameters -------------------------------------------------------------------------------*/
/*------------------------------------------------------------------------------------------------*/

@params {
	screen_x:0;
	screen_y:0;
	screen_w:width;
	screen_h:height; /* 800 - 38 (hdpi status bar height) */
	
	fontsize_inputfield: (tall_screen ? 24 : undef);
	localmenu_y: (wide_screen ? 411 : undef);
	localmenu_w:(min(480 - 2 * 14, int(screen_w * 92%))); /* nem nyulik ki tovabb mint 740 px */
	
	header_h: (header_h // 34);
	mapheader_h:92;
	mapheader_tmc_h: 125;
	mapheader_trip_h:(int(screen_h * 32%));	
	
	footer_h:(footer_h // 72);
	footer_w:screen_w;
	footer_w_33: (footer_w / 3);
	footer_w_16: (footer_w / 6);
	footer_w_8: (footer_w / 12);
	footer_y:( screen_h - footer_h);

	margin_top:0;
	margin_bottom:8;
	margin_left:6;
	margin_right:6;
	
	margin_simulate:0;
	
	mapmargin_top:13;
	mapmargin_bottom:13;
	
	main_x:( screen_x + margin_left );
	main_y:( screen_y + header_h + margin_top );
	main_w:( screen_w - margin_left - margin_right);
	main_h:( screen_h - header_h - margin_top - footer_h - margin_bottom);
	main_h_full:( screen_h - header_h - margin_top - margin_bottom);
	
	messagebox_panel_margin: 12;
	
	dialog_y: 269;		/*56%*/
	dialog_icon_w: 100;	/*eg: width of ico_Delete_mid.bmp*/
	dialog_h: 94;		/*eg: height of ico_Delete_mid.bmp + padding*/
	dialog_w: (main_w - 2 * messagebox_panel_margin);
	dialog_w_50: ((dialog_w) / 2);
	dialog_w_33: ((dialog_w) / 3);
	dialog_x_1: (margin_left + messagebox_panel_margin);
	dialog_x_2: (screen_w / 2);
	dialog_x_3_2: (dialog_x_1 + dialog_w_33);
	dialog_x_3_3: (dialog_x_1 + 2 * dialog_w_33);
	dialog_panel_margin: 9;
		
	margin_ext_top:margin_top;
	margin_ext_bottom:margin_bottom;
	margin_ext_left:margin_left;
	margin_ext_right:margin_right;

	main_ext_x:( screen_x + margin_ext_left );
	main_ext_y:( screen_y + header_h + margin_ext_top );
	main_ext_w:( screen_w - margin_ext_left - margin_ext_right);
	main_ext_h:( screen_h - header_h - margin_ext_top - footer_h - margin_ext_bottom);
	main_ext_h_full:( screen_h - header_h - margin_ext_top - margin_ext_bottom);
	
	map_h: (screen_h - footer_h);
	mapmain_y: (screen_y + mapheader_h + mapmargin_top);
	mapmain_h: (screen_h - mapheader_h - footer_h - mapmargin_top - mapmargin_bottom);
	mapmain_tmc_h: (screen_h - mapheader_tmc_h - footer_h - mapmargin_top - mapmargin_bottom);
	mapmain_trip_h: (screen_h - mapheader_trip_h -  mapmargin_top - mapmargin_bottom);	

	title_h: header_h;
	
	mainmenu_top: title_h;
	mainmenu_bottom: (footer_h + margin_bottom);
	mainmenu_left:margin_left;
	mainmenu_right:margin_right;
	
	mainmenu_x:( screen_x + mainmenu_left );
	mainmenu_y:( screen_y + mainmenu_top );
	mainmenu_w:( screen_w - mainmenu_left - mainmenu_right);
	mainmenu_h:( screen_h - mainmenu_top - mainmenu_bottom);
	
	panel_margin: 6;

	panel_x: (main_x + panel_margin);
	panel_y: (main_y + panel_margin);
	panel_w: (main_w - panel_margin - panel_margin);
	panel_h: (main_h - panel_margin - panel_margin);
	
	panel_header_h: 40;
	
	panel_side_x: 0;
	panel_side_w: (screen_w - panel_side_x);
	panel_side_h: (screen_h > (854 - 38) ? int(screen_h * 50%) : int(screen_h * 60%));
	panel_side_small_w: screen_w;
	panel_side_small_h: (int(screen_h * 35%));
	panel_side_header_h: 42;
	
	panel_unit_keys_w: 288; /* w osztható 3-al*/ 
	panel_unit_keys_h: 284; /* h osztható 4-el*/
	
	listpos_w: 0;
	listscroll_w: 6;
	listscroll_map_msgbox_w: 0;
	hsmartscroll_h: 70;
	hsmartscroll_smallh: 48;
	
	list_x: (main_ext_x + panel_margin );
	list_y: (main_ext_y + panel_margin );
	list_w: (main_ext_w - listscroll_w - listpos_w - panel_margin - panel_margin );
	list_h: (main_ext_h - panel_margin - panel_margin);
	
	listpos_x: (main_x + main_w - listscroll_w - listpos_w);
	listpos_y: (main_y);
	
	listscroll_x: (main_x + main_w - listscroll_w);
	listscroll_h: (main_h / 2);
	listscroll_y_up: (main_y);
	listscroll_y_down: (main_y + listscroll_h);
	
	listcontrol_right: (listscroll_w + listpos_w + panel_margin);
	listcontrol_local_right: (listscroll_w + listpos_w );
	listcontrol_map_msgbox_right: (listscroll_map_msgbox_w + listpos_w + panel_margin);
	
	listitem_w: (list_w);
	listitem_h: (list_h / 4) ;
	
	button_padding: 25; /* (int(screen_w * 5%)) */
	text_padding: 10; /* (int(screen_w * 2%)) */
	text_padding_small: 5; /* (int(screen_w * 1%)) */
	button_vpadding_showmap:44;
	text_vpadding: 16;
	text_vpadding_small: 10;
	
	showmap_margin:15;
	showmap_text_h:99;
	
	chk_radio_icon_padding_right: "RIGHT-16" ; /* value should be same as button_padding */
	chk_radio_text_padding_right: 76;
	
	chk_radio_icon_padding_right_small: "RIGHT-16" ; /* value should be same as text_padding */
	chk_radio_text_padding_right_small: 56;
	
	slider_valign: "BOTTOM-30";
	
	localmenu_x: 14; /*(int(screen_w * 16%) );*/
	localmenu_y: (localmenu_y // 351); /*(int(screen_h * 16%) );*/
	
	footer_icon_w: 54;
	
	map_messagebox_w: 528;
	map_messagebox_h:182;
	map_messafebox_x_1:165;
	map_messafebox_x_2:176;
	
	vr_mode_w: 96;
	vr_mode_y: (screen_y + header_h + margin_top + panel_margin);
	vr_mode_h: (screen_h - header_h - margin_top - footer_h - margin_bottom);
		
	vr_main_x: (screen_x + vr_mode_w + panel_margin);
	vr_main_w: (screen_w - vr_mode_w - panel_margin - panel_margin);

	vr_list_x: const(list_x + vr_mode_w);
	vr_list_y: const(list_y + margin_bottom / 2);
	vr_list_w: const(list_w - vr_mode_w);
	vr_list_h: const(list_h); 
	
	fontsize_double: 52;
	fontsize_title: 36;
	fontsize_main_large: 30;
	fontsize_main: 28;
	fontsize_sec:  24;
	fontsize_sec_twoline:  20;
	fontsize_info: 18;
	fontsize_inputfield: (fontsize_inputfield // 22);
	fontsize_inputfieldvalue: (fontsize_inputfieldvalue // fontsize_inputfield);
	fontsize_popup: 65;
	fontsize_keyboard: 28;
	fontsize_main_poi: 24;
	fontsize_main_poi_twoline: 20;
	fontsize_sec_poi: 20;
	fontsize_sec_poi_twoline: 18;
	
	highlight_inputfield: 42;
	
	xhtml_content_left: 0;
	xhtml_content_top: 0;
	xhtml_content_right: 0;
	xhtml_content_bottom: 0;

	
	key_popup_w: 123;
	key_popup_h: 157;
	
	map_counter_tmc_h: 85;
	
	map_infofield_h: 210;
	
	/*Icon index*/
	da_icon_index: 2;	/*DA Icon size (low:0 ; mid:2 ; high:4)*/
	
	poi_provider_icon_index: 4;	/*POI Provider Icon Size (low:3 ; mid:4 ; high:5)*/
	poi_provider_overlay_icon_index: 1;	/*POI Provider Overlay Icon Size (low:0 ; mid:1 ; high:2)*/
	
	provider_icon_index: 1;	/*Provider Icon Size (low:0 ; mid:1 ; high:2)*/
	
	country_flag_icon_index: 1; /*Country Flags Size (low:0 ; mid:1 ; high:2)*/
	
	tmc_icon_index: 2;	/*TMC Icon Size (low:0 ; mid:2 ; high:4)*/

	keyb_12_x: 20;
	keyb_12_w: 756;
	
	gpsstatus_margin: 20;
	gpsstatus_text_margin: 10;
	gpsstatus_radius: 160;
	gpsstatusbar_margin_left: 24;
	gpsstatusbar_margin_right: 24;
	gpsstatusbar_margin_bottom: 24;

	speedcamlimit_top: 67%;
	speedcamlimit_w: 42%;
	speedcamlimit_h: 13%;
	speedcamlimit_text_left: 2%;
	speedcamlimit_text_bottom: 8%;
	speedlimit_w: 100%;
	
	custominfoarrow_w:139;
	custominfoarrow_h:188;
	
	routerecalcanim_w:370;
	routerecalcanim_h:52;	
	
	tripbar_w: 28;
	
	hwy_panel_element_h: 76;
	next_maneuver_h: (int(screen_h * 8%));
	
	map_panel_h: (%screen.msgbox.is_onscreen ? (int(screen_h * 30%)) : (%lua.HwyPoiListIsVisible ? (hwy_panel_element_h * min(max(%ui.hwyList_filtered.size,1),3)) : 0));
	
	sunlightmap_w:480;
	sunlightmap_h:272;
	sunrisesunset_offset:262;
	
	box_margin: 3;
	
	default_wcorrection:(480 - screen_w);
	default_hcorrection:(762 - screen_h);
	cockpit_wcorrection:default_wcorrection;
	cockpit_hcorrection:default_hcorrection;
	cockpit_w:(screen_w + cockpit_wcorrection);
	cockpit_h:(screen_h + cockpit_hcorrection);
	map_w:cockpit_w;
	map_h:(screen_h - footer_h + cockpit_hcorrection);
	mapmain_w:cockpit_w;
	mapmain_h:(map_h -mapheader_h - mapmargin_top - mapmargin_bottom);
}

@import "~/common/ui/params.css";

DIV.cockpit{
	w:cockpit_w;
	h:cockpit_h;
}

DIV.map {
	w: map_w;
	h: map_h;
}

DIV.mapmain {
	y: const(mapmain_y - cockpit_hcorrection/2);
	w: mapmain_w;
	h: mapmain_h;
}

DIV.mapmain.right{
	x: const(-cockpit_wcorrection)
	y: const(mapmain_y - cockpit_hcorrection/2);
}

DIV.mapmain.tmc {
	y: (screen_y + mapheader_tmc_h + mapmargin_top - cockpit_hcorrection/2);
	h: (mapmain_tmc_h + cockpit_hcorrection/2);
}

DIV.mapmain.tracklog {
	y: const(mapheader_trip_h + mapmargin_top - cockpit_hcorrection/2);
	h: const(mapmain_trip_h + cockpit_hcorrection/2);
}

LAYER.map_tmc_controls{
	x: (screen_x - cockpit_wcorrection);
	y: (screen_y + mapheader_tmc_h + mapmargin_top - cockpit_hcorrection/2 );
	w: (screen_w + cockpit_wcorrection);
	h: ( mapmain_tmc_h + cockpit_hcorrection/2 );
}