@import "../../../themes/ionic.globals";

// Buttons
// --------------------------------------------------

// deprecated
$button-round-padding: null !default;

/// @prop - Padding top of the round button
$button-round-padding-top: 0 !default;

/// @prop - Padding end of the round button
$button-round-padding-end: 26px !default;

/// @prop - Padding bottom of the round button
$button-round-padding-bottom: $button-round-padding-top !default;

/// @prop - Padding start of the round button
$button-round-padding-start: $button-round-padding-end !default;

/// @prop - Border radius of the round button
$button-round-border-radius: 64px !default;

.button {
  position: relative;
  z-index: 0;
  display: inline-block;
  text-overflow: ellipsis;
  text-transform: none;
  white-space: nowrap;
  vertical-align: top; // the better option for most scenarios
  vertical-align: -webkit-baseline-middle; // the best for those that support it
  cursor: pointer;
  user-select: none;
  transition: background-color, opacity 100ms linear;
  font-kerning: none;
  contain: content;
  
  @include text-align(center);
  @include appearance(none);
}

.button-inner {
  display: flex;
  width: 100%;
  height: 100%;
  flex-flow: row nowrap;
  flex-shrink: 0;
  align-items: center;
  justify-content: center;
}

.ion-button {
  text-decoration: none;
}

a[disabled],
button[disabled],
.ion-button[disabled] {
  pointer-events: none;
  cursor: default;
  opacity: 0.4;
}

// Block Button
// --------------------------------------------------

.button-block {
  display: block;
  width: 100%;
  clear: both;
  contain: strict;
}

.button-block::after {
  clear: both;
}

// Full Button
// --------------------------------------------------

.button-full {
  display: block;
  width: 100%;
  contain: strict;
}

// Full Outline Button
// --------------------------------------------------

.button-full.button-outline {
  border-right-width: 0;
  border-left-width: 0;
  
  @include border-radius(0);
}
