@import "compass/utilities/general/float";
@import "base";

@mixin layoutgala-liquid-right (
	$aside1-side: center,
	$aside1-width: 200px,
	$aside2-width: 200px,
	$margin-left: 0,
	$margin-center-left: 0,
	$margin-center-right: 0,
	$margin-right: 0,
	$content-padding-left: 0,
	$content-padding-right: $content-padding-left,
	$aside1-padding-left: $content-padding-left,
	$aside1-padding-right: $content-padding-left,
	$aside2-padding-left: $content-padding-left,
	$aside2-padding-right: $content-padding-left
) {
	$container-width: 100%;
	$content-width: ($container-width - $aside1-width - $aside2-width);
//	$aside2-side: #{opposite-position($aside1-side)};
	#{$layoutgala-wrapper-selector} {
		@include float(left);
		width: 100%;
	}
	#{$layoutgala-content-selector} {
		margin-left: ($aside1-width + $aside2-width);
	}
	#{$layoutgala-aside1-selector} {
		@include float(left);
		width: $aside1-width;
		@if $aside1-side == left {
			margin-left: -($content-width + $aside1-width);
		} @else {
			margin-left: -100%;
		}
	}
	#{$layoutgala-aside2-selector} {
		@include float(left);
		width: $aside2-width;
		@if $aside1-side != left {
//		@if $aside2-side == left {
			margin-left: - ($content-width + $aside2-width);
		} @else {
			margin-left: -100%;
		}
	}
	#{$layoutgala-footer-selector} {
		clear: left;
		width: 100%;
	}
}
