$ubuntu-font-path: '/static/fonts/ubuntu' !default;

@mixin ubuntu-font($type, $weight, $style: normal) {
	@font-face {
		font-family: 'Ubuntu';
		src: url('#{$ubuntu-font-path}/ubuntu-#{$type}-webfont.woff2') format('woff2'),
		url('#{$ubuntu-font-path}/ubuntu-#{$type}-webfont.woff') format('woff');
		font-weight: $weight;
		font-style: $style;
	}
}

@mixin ubuntu-font-pair($type, $weight) {
	@include ubuntu-font($type, $weight);
	@include ubuntu-font(#{$type}i, $weight, italic);
}

@include ubuntu-font-pair('l', 300);  // light
@include ubuntu-font-pair('r', 400);  // regular
@include ubuntu-font-pair('m', 500);  // medium
@include ubuntu-font-pair('b', 700);  // bold
