//Helpers
@import 'breakpoints';

// layouts
@import 'grids';

/**
 * _mixins.scss
 * EverestForms Mixins
 */
@mixin clearfix() {
	*zoom: 1;

	&::before,
	&::after {
		content: ' ';
		display: table;
	}

	&::after {
		clear: both;
	}
}

/**
 * Objects
 */
@mixin menu() {
	@include clearfix();

	li {
		display: inline-block;
	}
}

@mixin mediaright() {
	@include clearfix();

	img {
		float: right;
		height: auto;
	}
}

@mixin medialeft() {
	@include clearfix();

	img {
		float: right;
		height: auto;
	}
}

@mixin ir() {
	display: block;
	text-indent: -9999px;
	position: relative;
	height: 1em;
	width: 1em;
}

@mixin icon( $glyph: '\e001' ) {
	font-family: 'EverestForms';
	speak: none;
	font-weight: normal;
	font-variant: normal;
	text-transform: none;
	line-height: 1;
	margin: 0;
	text-indent: 0;
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	text-align: center;
	content: $glyph;
}

@mixin icon_dashicons( $glyph: '\f333' ) {
	font-family: 'Dashicons';
	speak: none;
	font-weight: normal;
	font-variant: normal;
	text-transform: none;
	line-height: 1;
	margin: 0;
	text-indent: 0;
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	text-align: center;
	content: $glyph;
}

@mixin iconbefore( $glyph: '\e001' ) {
	font-family: 'EverestForms';
	speak: none;
	font-weight: normal;
	font-variant: normal;
	text-transform: none;
	line-height: 1;
	-webkit-font-smoothing: antialiased;
	margin-right: 0.618em;
	content: $glyph;
	text-decoration: none;
}

@mixin iconbeforedashicons( $glyph: '\f333' ) {
	font-family: 'Dashicons';
	speak: none;
	font-weight: normal;
	font-variant: normal;
	text-transform: none;
	line-height: 1;
	content: $glyph;
	text-decoration: none;
}

@mixin loader() {
	&::before {
		height: 1em;
		width: 1em;
		display: block;
		position: absolute;
		top: 50%;
		left: 50%;
		content: '';
		animation: spin 1s ease-in-out infinite;
		background: url('../images/icons/loader.svg') center center;
		background-size: cover;
		background-repeat: no-repeat;
		line-height: 1;
		text-align: center;
		font-size: 2em;
		color: rgba(#000, 0.75);
	}
}
