// ==========================================================================
// Button mixins
// ==========================================================================

@mixin button--base() {
	padding: 4px 32px;
	border: 1px solid $color__link;
	cursor: pointer; // Improves usability and consistency of cursor style between image-type 'input' and others
	appearance: button; // Corrects inability to style clickable 'input' types in iOS
}

// Example button mixin that sets colors
@mixin button( $button-color, $text-color: white ) {
	background: $button-color;
	border-color: darken( $button-color, 10% );
	color: $text-color;

	&:hover,
	&:focus {
		background: darken( $button-color, 5% );
		border-color: darken( $button-color, 15% );
		color: $text-color;
	}

	&:active {
		background: darken( $button-color, 10% );
		border-color: darken( $button-color, 15% );
		color: $text-color;
	}

	&[disabled],
	&:disabled,
	&.button-primary-disabled {
		color: hsl( hue( $button-color ), 10%, 80% ) !important;
		background: darken( $button-color, 8% ) !important;
		border-color: darken( $button-color, 15% ) !important;
	}
}
