// ==========================================================================
// Form extends
// ==========================================================================

%form-field {
	margin: 0;
	padding: 10px 12px;
	width: 100%;
	color: map-get($form-field, color);
	font-size: 15px;
	line-height: 1.4;
	border: 1px solid map-get($form-field, border-color);
	background: map-get($form-field, background);
	transition: all .15s ease-in-out;
	box-sizing: border-box;

	&::placeholder {
		color: map-get($form-field, placeholder-color);
	}
	&:hover {
		border-color: map-get($form-field, border-color--hover);
		background: map-get($form-field, background--hover);

		&::placeholder {
			color: map-get($form-field, placeholder-hover);
		}
	}
	&:focus {
		color: map-get($form-field, color--focus);
		border-color: map-get($form-field, border-color--focus);
		background: map-get($form-field, background--focus);
		outline: none;
		box-shadow: inset 0 1px 4px 0 rgba(0, 0, 0, 0.3);

		&::placeholder {
			color: map-get($form-field, placeholder-focus);
		}
	}
}

%textarea {
	overflow: auto; // Removes default vertical scrollbar in IE6/7/8/9
	vertical-align: top; // Improves readability and alignment in all browsers
	width: 100%;
	min-height: 150px;
}

// Checkbooms

%checkbooms {
	box-sizing: border-box;
	display: inline-block;
	margin: -4px 4px 0 0;
	padding: 0;
	min-width: 16px;
	width: 16px;
	height: 16px;
	border: 1px solid #bbb;
	outline: 0;
	background: #fff;
	line-height: 0;
	text-align: center;
	vertical-align: middle;
	-webkit-appearance: none;
	clear: none;
	cursor: pointer;

	&:disabled {
		opacity: .7
	}
	&:checked:before {
		float: left;
		display: inline-block;
		vertical-align: middle;
		width: 16px;
		font: 400 23px/1 Noticons;
		speak: none;
		-webkit-font-smoothing: antialiased;
		-moz-osx-font-smoothing: grayscale;
		color: $wordpress-blue;
		-webkit-animation: grow .2s ease-in-out;
		animation: grow .2s ease-in-out;
	}
}

%radio {
	border-radius: 50%;
	margin-right: 4px;
	line-height: 10px;

	&:checked:before {
		float: left;
		display: inline-block;
		content: '\2022';
		margin: 3px;
		width: 8px;
		height: 8px;
		text-indent: -9999px;
		background: $wordpress-blue;
		vertical-align: middle;
		border-radius: 50%;
		-webkit-animation: grow .2s ease-in-out;
		animation: grow .2s ease-in-out;
	}
}

%checkbox {
	&:checked:before {
		content: '\f418';
		margin: -4px 0 0 -5px;
	}
}
