/* \Sentra.Designs\BasicDesigner\modules\searchform\style-searchform.css */

@sbut_{{formID}}marginleft:3px;

.FORMPOS_{{formID}}(@sform_align, @MODE) when (@sform_align = left) {
	.sformpos {
		float:left;
		width: 	{{sform_inpwidth}}px;
		margin-left: {{sinp_padding}}px;
	}
}
.sform_margin_{{formID}}(@sform_vmargin, @sform_hmargin) when (@sform_vmargin > 0) and (@sform_hmargin > 0) {
		margin: {{sform_vmargin}}px {{sform_hmargin}}px;
}
.sform_margin_{{formID}}(@sform_vmargin, @sform_hmargin) when (@sform_vmargin = 0) and (@sform_hmargin > 0) {
		margin: 0 {{sform_hmargin}}px;
}
.sform_margin_{{formID}}(@sform_vmargin, @sform_hmargin) when (@sform_vmargin > 0) and (@sform_hmargin = 0) {
		margin: {{sform_vmargin}}px 0;
}
.sform_margin_{{formID}}(@sform_vmargin, @sform_hmargin) when (@sform_vmargin = 0) and (@sform_hmargin = 0) {
		margin: 0;
}
.FORMPOS_{{formID}}(@sform_align, @MODE) when (@sform_align = center) {
	.sformpos {
		height:{{sbuttonheight}}px;
		width: 	{{sform_inpwidth}}px;
		margin: 0 floor(({{ST_Width}}px - {{sform_inpwidth}}px) * 0.5);
	}
}
.FORMPOS_{{formID}}(@sform_align, @MODE) when (@sform_align = center) and (@MODE = '.topicbar') {
	.sformpos {
		height:{{sbuttonheight}}px + 2 * {{sbut_vmargin}}px;
		width: 	{{sform_inpwidth}}px;
		margin: 10px floor(({{ST_Width}}px - {{sform_inpwidth}}px) * 0.5);
	}
}
.FORMPOS_{{formID}}(@sform_align, @MODE) when (@sform_align = center) and (@MODE = '.sidebar') {
	.sformpos {
		height:{{sbuttonheight}}px + 2 * {{sbut_vmargin}}px;
		width: 	{{sform_inpwidth}}px;
		margin: 10px floor(({{ST_Width}}px - {{sform_inpwidth}}px) * 0.5);
	}
}
.FORMPOS_{{formID}}(@sform_align, @MODE) when (@sform_align = right) {
	.sformpos {
		float:right;
		width: 	{{sform_inpwidth}}px;
		margin-right: {{sinp_padding}}px;
	}
}
.sform_inputbackground_{{formID}}(@form_inputlens_file) when not (@form_inputlens_file = 'none.png') {
	background: {{inp_bg_color}} url(./{{template_images}}/{{form_inputlens_file}}) no-repeat scroll {{sinp_padding}}px center;
	width: {{sform_inpwidth}}px  - 2 * {{search_borderwidth}}px - {{sformbuttonwidth}}px - {{sformbuttonwidth}}px - {{sinp_padding}}px - {{sinp_padding}}px - @sbut_{{formID}}marginleft;
}
.sform_inputbackground_{{formID}}(@form_inputlens_file) when  (@form_inputlens_file = 'none.png') {
	background: {{inp_bg_color}};
	padding-left: @sinp_padding!important;
	width: {{sform_inpwidth}}px + {{lenswidth}}px  - 2 * {{search_borderwidth}}px - {{sformbuttonwidth}}px - {{sformbuttonwidth}}px - {{sinp_padding}}px - {{sinp_padding}}px - @sbut_{{formID}}marginleft;
}
.sform_{{formID}}_input_width_bg(@form_inputlens_file) when not (@form_inputlens_file = 'none.png') {
	width: {{sform_inpwidth}}px - {{sformbuttonwidth}}px - 2 * @sinp_padding - {{lenswidth}}px - @sbutmarginleft - {{search_borderwidth}}px * 2;
	height: {{sinpheight}}px;
	padding: @sinp_padding;
	background: {{inp_bg_color}} url(./{{template_images}}/{{form_inputlens_file}}) no-repeat scroll {{sformlens_posx}} center;
}
.sform_{{formID}}_input_width_bg(@form_inputlens_file) when (@form_inputlens_file = 'none.png') {
	width: {{sform_inpwidth}} - {{sformbuttonwidth}}px - @sinp_padding - 2 * @sinp_padding - {{lenswidth}}px - @sbutmarginleft - {{search_borderwidth}}px * 2;
	height: {{sinpheight}}px;
	padding: @sinp_padding!important;
	background: {{inp_bg_color}};
}
.sform_{{formID}}_align(@sform_align) when (@sform_align = left) {
	float:left;
}
.sform_{{formID}}_align(@sform_align) when (@sform_align = center) {
	float:left;
}
.sform_{{formID}}_align(@sform_align) when (@sform_align = right) {
	float:right;
}
{{MODE}} {
	.FORMPOS_{{formID}}({{sform_align}}, '{{MODE}}');

	.sform {
		.sform_margin_{{formID}}({{sform_vmargin}}, {{sform_hmargin}});
		width: {{sform_inpwidth}}px;
		.sform_{{formID}}_align({{sform_align}});/* float:right; */

		.auto-suggest-page_{{formID}} {
			float:left;
			position:relative;
			width: 100%;
			z-index:201!important;
			input[type="image"] {
				height: {{sformbuttonheight}}px + {{sinp_padding}}px + {{sinp_padding}}px;
				width: {{sformbuttonwidth}}px;
			}
			input[type="text"] {
				color: {{inp_color}};
				font-size: {{sform_inp_fontsize}}px;
				font-weight:bold;
				color: {{inp_color}};
				.sform_{{formID}}_input_width_bg('{{form_inputlens_file}}');
				margin: {{inp_vmargin}}px 0;
			}
			input[type="submit"] {					/* submit button */
				float:left;
			}
		}
	}

	*+html { /* Ie7 hack */
		.sform {
			.auto-suggest-page_{{formID}} {
				z-index:201!important;
			}
		}
	}
}
