/* ==========================================================
 * admin-mixins.scss
 * Our project mixins
 *
 * Author: Yann Gouffon, yann@antistatique.net
 * Date:   2014-04-28 17:17:40
 *
 * Copyright 2014 Federal Chancellery of Switzerland
 * Licensed under MIT
 =========================================================== */

/**
 * Mixin to generate the pseudo element for a checkbox or radio
 * $type:   radio/checkbox
 * $position:   left/right
 */
@mixin form-button($position) {
  margin: 0;
  top: 50%;
  transform: translateY(-55%);
  #{$position}: 0;
}

/**
 * Mixin to add a separator at the right of element. Can pass left or both as argument.
 * $color:      #ffffff;
 * $where:      left/right/both
 */
@mixin separator($color, $where:right) {
  $style: 1px solid $color;
  @if $where == 'both' {border-left: $style; border-right: $style;}
  @else {border-#{$where}: $style;}
}

@mixin gradient-menu {
  background: #e8e8e8;
  background: -moz-linear-gradient(top,#e8e8e8 0%,#f7f7f7 61%,#f7f7f7 89%,#f5f5f5 91%,#ececec 95%,#d7d7d7 100%);
  background: -webkit-gradient(linear,left top,left bottom,color-stop(0%,#e8e8e8),color-stop(61%,#f7f7f7),color-stop(89%,#f7f7f7),color-stop(91%,#f5f5f5),color-stop(95%,#ececec),color-stop(100%,#d7d7d7));
  background: -webkit-linear-gradient(top,#e8e8e8 0%,#f7f7f7 61%,#f7f7f7 89%,#f5f5f5 91%,#ececec 95%,#d7d7d7 100%);
  background: -o-linear-gradient(top,#e8e8e8 0%,#f7f7f7 61%,#f7f7f7 89%,#f5f5f5 91%,#ececec 95%,#d7d7d7 100%);
  background: linear-gradient(to bottom,#e8e8e8 0,#f7f7f7 61%,#f7f7f7 89%,#f5f5f5 91%,#ececec 95%,#d7d7d7 100%);
}

@mixin gradient-light {
  background: rgb(239,239,239);
  background: url(data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiA/Pgo8c3ZnIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgd2lkdGg9IjEwMCUiIGhlaWdodD0iMTAwJSIgdmlld0JveD0iMCAwIDEgMSIgcHJlc2VydmVBc3BlY3RSYXRpbz0ibm9uZSI+CiAgPGxpbmVhckdyYWRpZW50IGlkPSJncmFkLXVjZ2ctZ2VuZXJhdGVkIiBncmFkaWVudFVuaXRzPSJ1c2VyU3BhY2VPblVzZSIgeDE9IjAlIiB5MT0iMCUiIHgyPSIwJSIgeTI9IjEwMCUiPgogICAgPHN0b3Agb2Zmc2V0PSIwJSIgc3RvcC1jb2xvcj0iI2VmZWZlZiIgc3RvcC1vcGFjaXR5PSIxIi8+CiAgICA8c3RvcCBvZmZzZXQ9IjEwMCUiIHN0b3AtY29sb3I9IiNmN2Y3ZjciIHN0b3Atb3BhY2l0eT0iMSIvPgogIDwvbGluZWFyR3JhZGllbnQ+CiAgPHJlY3QgeD0iMCIgeT0iMCIgd2lkdGg9IjEiIGhlaWdodD0iMSIgZmlsbD0idXJsKCNncmFkLXVjZ2ctZ2VuZXJhdGVkKSIgLz4KPC9zdmc+);
  background: -moz-linear-gradient(top,  rgba(239,239,239,1) 0%, rgba(247,247,247,1) 100%);
  background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,rgba(239,239,239,1)), color-stop(100%,rgba(247,247,247,1)));
  background: -webkit-linear-gradient(top,  rgba(239,239,239,1) 0%,rgba(247,247,247,1) 100%);
  background: -o-linear-gradient(top,  rgba(239,239,239,1) 0%,rgba(247,247,247,1) 100%);
  background: -ms-linear-gradient(top,  rgba(239,239,239,1) 0%,rgba(247,247,247,1) 100%);
  background: linear-gradient(to bottom,  rgba(239,239,239,1) 0%,rgba(247,247,247,1) 100%);
  filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#efefef', endColorstr='#f7f7f7',GradientType=0 );

}
