// Mixins
// --------------------------------------------------

// Utilities
@import "mixins/hide-text.less";
@import "mixins/opacity.less";
@import "mixins/image.less";
@import "mixins/labels.less";
@import "mixins/reset-filter.less";
@import "mixins/resize.less";
@import "mixins/responsive-visibility.less";
@import "mixins/size.less";
@import "mixins/tab-focus.less";
@import "mixins/text-emphasis.less";
@import "mixins/text-overflow.less";
@import "mixins/vendor-prefixes.less";

// Components
@import "mixins/alerts.less";
@import "mixins/buttons.less";
@import "mixins/panels.less";
@import "mixins/pagination.less";
@import "mixins/list-group.less";
@import "mixins/nav-divider.less";
@import "mixins/forms.less";
@import "mixins/progress-bar.less";
@import "mixins/table-row.less";

// Skins
@import "mixins/background-variant.less";
@import "mixins/border-radius.less";
@import "mixins/gradients.less";

// Layout
@import "mixins/clearfix.less";
@import "mixins/center-block.less";
@import "mixins/nav-vertical-align.less";
@import "mixins/grid-framework.less";
@import "mixins/grid.less";

// =============================================================================
// Grid
// =============================================================================

// Container Width
.container-width( @width: @container-width )
{
	width: @width;
}

// Container Max Width
.container-max-width(@max-width: @container-max-width)
{
	max-width: @max-width;
}

// =============================================================================
// CSS3
// =============================================================================

// Drop shadows 
//
// Add it here because bootstrap is going to deprecated it.
.box-shadow(@shadow) {
  -webkit-box-shadow: @shadow; // iOS <4.3 & Android <4.1
          box-shadow: @shadow;
}
.border-radius(@radius:4px) {
	-webkit-border-radius:@radius;
	border-radius:@radius;
}
.background-cover( @background-cover ) when ( @background-cover = true ) {
	-webkit-background-size: cover;
	   -moz-background-size: cover;
	     -o-background-size: cover;
	        background-size: cover;
}
.calc-width(@width,@calc){
	width: @width;
	width: ~"-webkit-calc("@calc~")"; /** Safari 6, Chrome 19-25 **/
	width: ~"-moz-calc("@calc~")"; /** FF 4-15  **/
	width: ~"calc("@calc~")"; /** FF 16+, IE 9+, Opera 15, Chrome 26+, Safari 7 and future other browsers **/
}

// Icons
.add-icon(@content: "")  {
	content: @content;
	position: relative;
	display: inline-block;
	font-family: @icon-font-family;
	font-style: normal;
	font-weight: normal;
	line-height: 1;
	text-decoration: inherit;
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
	speak: none;
}

.add-icon-before(@content: "", @padding: @icon-padding-base, @opacity: @icon-opacity-base) {
	&:before {
		.add-icon(@content);
		padding-right: @padding;
		.opacity( @opacity );
	}
}

.add-icon-after(@content: "", @padding: @icon-padding-base, @opacity: @icon-opacity-base) {
	&:after {
		.add-icon(@content);
		padding-left: @padding;
		.opacity( @opacity );
	}
}

.bg-cover (){
    -webkit-background-size: cover !important;
    -moz-background-size: cover !important;
    -o-background-size: cover !important;
    background-size: cover !important;
}

// Tags ( used in Tags Cloud )
.tag() {
	&:extend(.btn);
	&:extend(.btn-default);
	margin: 0 0px 3px 0;
	color:#ffffff;
	background: #555555;
	border-color: #555555;
	font-size: @font-size-base !important;
	font-weight: @font-weight-base;
	line-height: 1;
	&:hover{
		background:@link-color;
		border-color: @link-color;
		color: #ffffff;
	}
}

.btn(){
  display: inline-block;
  margin-bottom: 0; // For input.btn
  font-weight: @btn-font-weight;
  text-align: center;
  vertical-align: middle;
  cursor: pointer;
  background-image: none; // Reset unusual Firefox-on-Android default style; see https://github.com/necolas/normalize.css/issues/214
  border: 0 solid transparent;
  white-space: nowrap;
  font-family: @headings-font-family;
  border-radius: @border-radius-base;
  .button-size(@padding-large-vertical; @padding-large-horizontal; @font-size-base; @line-height-base; @border-radius-base);
  .user-select(none);
  .transition(border-color color 0.2s ease);
  &,
  &:active,
  &.active {
    &:focus {
      .tab-focus();
    }
  }

  &:hover,
  &:focus {
    color: @btn-default-color;
    text-decoration: none;
  }

  &:active,
  &.active {
    outline: 0;
    background-image: none;
    .box-shadow(inset 0 3px 5px rgba(0,0,0,.125));
  }

  &.disabled,
  &[disabled],
  fieldset[disabled] & {
    cursor: not-allowed;
    pointer-events: none; // Future-proof disabling of clicks
    .opacity(.65);
    .box-shadow(none);
  }


  &.square {
    border-radius: 0;
  }
  &.pill {
    border-radius: 100em;
  }
  &.rounded {
    border-radius: 0.225em;
  }
  &.btn-white {
    background-color: transparent;
    border: 1px solid #ffffff;
    color: #ffffff;
    .transition(all 0.2 ease); 
    &:hover {
      background-color: rgba(255, 255, 255, 0.6);
      border-color: rgba(255, 255, 255, 0.6);
      opacity: 1;
      color: #57666e;
      > i {
        color: #57666e !important;
      }
    }
  }
  &.btn-black {
    background: none repeat scroll 0 0 #333333;
    color: white;
    &:hover {
      background-color: darken(#444444, 10%);
    }
  }
  i {
    padding-right: 10px;
  }
  &.icon-right i {
    padding-left: 10px;
    padding-right: 0px;
  }
}
.form-control() {
  display: block;
  width: 100%;
  height: @input-height-base; // Make inputs at least the height of their button counterpart (base line-height + padding + border)
  padding: @padding-base-vertical (@padding-base-horizontal*1.5);
  font-size: @font-size-base;
  line-height: @line-height-base;
  color: @input-color;
  background-color: @input-bg;
  background-image: none; // Reset unusual Firefox-on-Android default style; see https://github.com/necolas/normalize.css/issues/214
  border: 1px solid @input-border;
  border-radius: @input-border-radius;
  letter-spacing: 0.5px;
  //.box-shadow(inset 0 1px 1px rgba(0,0,0,.075));
  .transition(~"border-color ease-in-out .15s, box-shadow ease-in-out .15s");

  // Customize the `:focus` state to imitate native WebKit styles.
  .form-control-focus();

  // Placeholder
  .placeholder();

  // Disabled and read-only inputs
  //
  // HTML5 says that controls under a fieldset > legend:first-child won't be
  // disabled if the fieldset is disabled. Due to implementation difficulty, we
  // don't honor that edge case; we style them as disabled anyway.
  &[disabled],
  &[readonly],
  fieldset[disabled] & {
    cursor: not-allowed;
    background-color: @input-bg-disabled;
    opacity: 1; // iOS fix for unreadable disabled content
  }

  // Reset height for `textarea`s
  textarea& {
    height: auto;
  }
}
