/**
 * File: basic/_background.scss
 * Type: SASS partial
 * Author: Chris Humboldt
 */

// Table of contents
// Variables
// General
// Background images
// Deprecated - will be deleted

// Variables
$images-root: "" !default;

// General
@mixin background-attachment($attachment: scroll) {
	background-attachment: $attachment;
}
@mixin background-clip($clip: border-box) {
	background-clip: $clip;
}
@mixin background-colour($colour) {
	background-color: $colour;
}
@mixin background-color($colour) {
	@include background-colour($colour);
}
@mixin background-contain() {
	@include background-position(center);
	@include background-repeat(no-repeat);
	@include background-size(contain);
}
@mixin background-cover() {
	@include background-position(center);
	@include background-repeat(no-repeat);
	@include background-size(cover);
}
@mixin background-origin($origin: padding-box) {
	background-origin: $origin;
}
@mixin background-position($position: center) {
	background-position: $position;
}
@mixin background-repeat($repeat: repeat) {
	background-repeat: $repeat;
}
@mixin background-size($size: auto) {
	background-size: $size;
}
@mixin background-single() {
	@include background-position(center);
	@include background-repeat(no-repeat);
}

// Background images
@mixin background-image($image, $position: top left) {
	background-image: url("#{$images-root}/#{$image}");
	@include background-position($position);
}
@mixin background-image-contain($image, $position: center) {
	@include background-image($image, $position);
	@include background-repeat(no-repeat);
	@include background-size(contain);
}
@mixin background-image-cover($image, $position: center) {
	@include background-image($image, $position);
	@include background-repeat(no-repeat);
	@include background-size(cover);
}
@mixin background-image-parallax($image, $position: center) {
	@include background-image($image, $position);
	@include background-attachment(fixed);
	@include background-size(cover);
}
@mixin background-image-single($image, $position: center) {
	@include background-image($image, $position);
	@include background-repeat(no-repeat);
}
