// Lightning Design System 2.264.0-beta.1
// Copyright (c) 2015-present, salesforce.com, inc. All rights reserved
// Licensed under BSD 3-Clause - see LICENSE.txt or git.io/sfdc-license


/**
  * @summary Variant for number input with increment and decrement buttons
  *
  * @name base
  * @selector .slds-input_counter
  * @restrict .slds-input
  * @variant
*/
.slds-input_counter {
  text-align: center;
  padding: 0 $spacing-xx-large;

  &[type='number'] {
    // stylelint-disable property-no-vendor-prefix
    -moz-appearance: textfield; // FF needs 'textfield' to remove counter UA styling; -webkit-appearance in .slds-input removes for other browsers
    // stylelint-enable property-no-vendor-prefix
  }

  &::-webkit-inner-spin-button {
    @include appearance(none);
    margin: 0;
  }
}

/**
 * @summary Positions decrement button within counter input field
 *
 * @selector .slds-input__button_decrement
 * @restrict  .slds-button
 */
.slds-input__button_decrement {
  @include vertical-center;
  left: 0.75rem;
}

/**
 * @summary Positions increment button within counter input field
 *
 * @selector .slds-input__button_increment
 * @restrict .slds-button
 */
.slds-input__button_increment {
  @include vertical-center;
  right: 0.75rem;
}
