input[type="text"],
input[type="number"],
input[type="email"] {
	width: 100%;
	max-width: 480px;
	border: 1px solid $alex-orange;
	padding: 0 0.25rem 0 0.75em;
	display: inline-block;
	font-weight: 500;

	margin-bottom: $inner-margin;
	border-radius: 7px;
	height: 50px;
	outline: none;

	&:active,
	&:focus {
		outline: none;
		border: 1px solid $alex-blue;
	}
}

textarea {
	width: 100%;
	max-width: 480px;
	height: 120px;
	border: 1px solid $alex-orange;
	border-radius: 7px;
	outline: none;
	padding: 0.5em;
	font-size: 1em;
	font-weight: 300;
	resize: vertical;
	margin-bottom: 0.75em;

	@include small-screen {
		height: 170px;
	}
}

input[type=number]::-webkit-inner-spin-button,
input[type=number]::-webkit-outer-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

input[type="number"] {
	max-width: 320px;
	font-size: 1.35em;
	-moz-appearance: textfield;

	&[maxlength="2"],
	&[maxlength="3"],
	&[maxlength="4"] {
		float: left;
		width: 80px;
	}
}

input[type="text"]{
	font-size: 1.25em;

	&::placeholder {
		font-size: 80%;
	}
}
select {
	appearance: none;
	-webkit-appearance: none;
	border: 2px solid $alex-orange;
	height: 50px;
	font-size: 1.25em;
	font-weight: 500;
	padding: 0 45px 0 10px;
	margin-bottom: $inner-margin;
	position: relative;
	width: 100%;
	max-width: 480px;
	// arrow
	background: $alex-white url('../img/arrow.png') no-repeat right center;
	background-size: 40px;
}

input[type="submit"] {
	@extend %button-primary;

	&:empty {
		// overriding empty button fix because submit buttons are apparently empty! who knew
		display: block;
	}
}

form {

	.fib-multi,
	.fib-single {
		@include clearfix;

		label {
			position: relative;
			top: 0;
			left: 12px;
			height: 50px;
			display: inline-flex;
			line-height: 1.2;
			align-items: center;
			max-width: 100px;
			float: left;

			&:empty {
				display: none;
			}

			@include small-screen {
				max-width: none;
				left: 22px;
			}
		}
	}

	.fib-single {
		margin-bottom: 1em;
	}

	label {
		font-size: 1.25em;
		color: $alex-text;
	}

	.error {
		margin-bottom: 1em;
		clear: both;
	}

	button,
	input[type="submit"] {
		@extend %button-primary;
		outline: none;

		&:hover {
			outline: none;
		}
	}
}


.checkbox-input {
	@extend %custom-input;
	border-radius: 4px;

	label {
		border-radius: 2px;

	// the inside check
	&:after {
		width: 16px;
		height: 8px;
		position: absolute;
		top: 5px;
		left: 4px;
		border: 5px solid $alex-blue;
		border-top: none;
		border-right: none;
		background: transparent;
		transform: rotate(-45deg);
	}
}
}

.radiobutton-input {
	@extend %custom-input;
	border-radius: 32px;

	label {
		border-radius: 25px;

	// the inside dot
	&:after {
		width: 12px;
		height: 12px;
		border-radius: 20px;
		position: absolute;
		top: 8px;
		left: 8px;
		border: none;
		background: $alex-blue;
	}
}
}

// partial for radios and checkboxes

%custom-input {
	width: 32px;
	height: 32px;
	position: relative;
	background: $alex-blue;
	margin-bottom: $outer-margin;

	label {
		width: 28px;
		height: 28px;
		cursor: pointer;
		position: absolute;
		left: 2px;
		top: 2px;
		background: #fff;

		&:after {
			content: '';
			opacity: 0;
		}

		&:hover::after {
			opacity: 0.3;
		}
	}

	input[type=checkbox],
	input[type=radio] {
		visibility: hidden;

		&:checked + label:after {
			opacity: 1;
		}

		&:checked ~ span {
			font-weight: 700;
		}
	}

	span {
		position: absolute;
		left: 54px;
		top: 3px;
		font-size: 1.25em;
		color: $alex-text;
		width: 200px;
	}
}
