/*
button {
    @include padding(10px, 15px, 10px, 15px);

    border:none;

    background:var(--primary-color, #256ec1);
    color:var(--secondary-text-color, white);

    text-align: center;
}
*/
:host {
  /**
     * @prop --background: Background of the button
     * @prop --background-activated: Background of the button when activated
     * @prop --background-focused: Background of the button when focused
     * @prop --background-hover: Background of the button when hovered
     * @prop --background-hover-clear: Background of the clear button when hovered
     * @prop --background-hover-outline: Background of the outline button when hovered
     *
     * @prop --color: Text color of the button
     * @prop --color-activated: Text color of the button when activated
     * @prop --color-focused: Text color of the button when focused
     * @prop --color-hover-outline: Text color of the outline button when hovered
     *
     * @prop --transition: Transition of the button
     *
     * @prop --border-radius: Border radius of the button
     * @prop --border-width: Border width of the button
     * @prop --border-style: Border style of the button
     * @prop --border-color: Border color of the button
     * @prop --border-focus-color: Border color when focused
     *
     * @prop --box-shadow: Box shadow of the button
     * @prop --opacity: Opacity of the button
     *

     * @prop --button-height: Button Height
     * @prop --button-padding-top: Padding top of the button
     * @prop --button-padding-end: Padding end of the button
     * @prop --button-padding-bottom: Padding bottom of the button
     * @prop --button-padding-start: Padding start of the button
     * @prop --button-text-transformation: How to transform the text
     */
  --overflow: hidden;
  --border-width: initial;
  --border-color: initial;
  --border-style: initial;
  --box-shadow: none;
  --border-radius: 2px;
  --transition: box-shadow 280ms cubic-bezier(0.4, 0, 0.2, 1),
    background-color 15ms linear, color 15ms linear;
  --button-text-transformation: capitalize;
  margin: 4px 2px;
  display: inline-block;
  width: auto;
  height: var(--button-height, 54px);
  color: var(--color);
  font-family: var(--lu-font-family, inherit);
  font-size: 14px;
  font-weight: 400;
  letter-spacing: 0.01em;
  text-align: center;
  text-decoration: none;
  text-overflow: ellipsis;
  text-transform: var(--button-text-transformation);
  white-space: nowrap;
  user-select: none;
  vertical-align: top;
  vertical-align: -webkit-baseline-middle;
  pointer-events: auto;
  font-kerning: none;
}

:host(.button-disabled) {
  pointer-events: none;
}

:host(.button-solid) {
  --background: var(--lu-color-primary_light, #256EC1);
  --background-focused: var(--lu-color-primary_light-shade, #2161aa);
  --background-activated: var(--background);
  --background-hover: var(--lu-color-primary_light-shade, #2161aa);
  --box-shadow: none;
  --color: var(--lu-color-primary_light-contrast, #fff);
  --color-activated: var(--lu-color-primary_light-contrast, #fff);
  --color-focused: var(--lu-color-primary_light-contrast, #fff);
}

:host(.button-solid.activated) {
  --box-shadow: 0 5px 5px -3px rgba(0, 0, 0, 0.2), 0 8px 10px 1px rgba(0, 0, 0, 0.14), 0 3px 14px 2px rgba(0, 0, 0, 0.12);
}

:host(.button-solid.lu-color) .button-native {
  background: var(--lu-color-base);
  color: var(--lu-color-contrast);
}

:host(.button-solid.lu-color.focused) .button-native {
  background: var(--lu-color-shade);
}

:host(.button-round) {
  --border-radius: 64px;
  --button-padding-top: 0;
  --button-padding-start: 26px;
  --button-padding-end: 26px;
  --button-padding-bottom: 0;
}

:host(.button-outline) {
  --border-color: var(--lu-color-neutral_lighter, #C6C7C9);
  --background: transparent;
  --background-activated: transparent;
  --background-focused: rgba(var(--lu-color-primary_light-rgb, 37, 110, 193), 1);
  --background-hover-outline: rgba(var(--lu-color-primary_light-rgb, 37, 110, 193), 1);
  --border-width: 1px;
  --border-style: solid;
  --box-shadow: none;
  --color: var(--lu-color-primary_light, #256EC1);
  --color-focused: white;
  --color-activated: var(--lu-color-primary_light, #256EC1);
  --color-hover-outline: white;
}

:host(.button-outline.activated.lu-color) .button-native {
  background: transparent;
}

:host(.button-outline.lu-color) .button-native {
  border-color: var(--lu-color-base);
  background: transparent;
  color: var(--lu-color-base);
}

:host(.button-outline.focused.lu-color) .button-native {
  background: rgba(var(--lu-color-base-rgb), 0.1);
  color: var(--lu-color-base);
}

:host(.button-clear) {
  --background-activated: transparent;
  --background-focused: rgba(var(--lu-color-primary_light-rgb, 37, 110, 193), 0.1);
  --background-hover-clear: rgba(var(--lu-color-primary_light-rgb, 37, 110, 193), 0.04);
  --background: transparent;
  --border-width: 0;
  --color-activated: var(--lu-color-primary_light, #256EC1);
  --color-focused: var(--lu-color-primary_light, #256EC1);
  --color: var(--lu-color-primary_light, #256EC1);
  --opacity: 1;
}

:host(.button-clear.lu-color) .button-native {
  background: transparent;
  color: var(--lu-color-base);
}

:host(.button-clear.focused.lu-color) .button-native {
  border: 1px solid var(--border-focused-color, var(--lu-color-base));
  background: var(--background-focused, rgba(var(--lu-color-base-rgb), 0.1));
  color: var(--color-focused, var(--lu-color-base));
}

:host(.button-clear.activated.lu-color) .button-native {
  background: transparent;
}

:host(.button-large) {
  --button-padding-top: 0;
  --button-padding-start: 1em;
  --button-padding-end: 1em;
  --button-padding-bottom: 0;
  height: 2.8em;
  font-size: 20px;
}

:host(.button-small) {
  --button-padding-top: 0;
  --button-padding-start: 0.9em;
  --button-padding-end: 0.9em;
  --button-padding-bottom: 0;
  height: 2.1em;
  font-size: 13px;
}

:host(.button-strong) {
  font-weight: bold;
}

:host(.button-block) {
  display: block;
}

:host(.button-block) .button-native {
  margin-left: 0;
  margin-right: 0;
  display: block;
  width: 100%;
  clear: both;
  contain: content;
}

:host(.button-block) .button-native::after {
  clear: both;
}

:host(.button-full) {
  display: block;
}

:host(.button-full) .button-native {
  margin-left: 0;
  margin-right: 0;
  display: block;
  width: 100%;
  contain: content;
}

:host(.button-full:not(.button-round)) .button-native {
  border-radius: 0;
}

.button-native {
  border-radius: var(--border-radius);
  -moz-osx-font-smoothing: grayscale;
  -webkit-font-smoothing: antialiased;
  margin: 0;
  padding: var(--button-padding-top, 0) var(--button-padding-end, 48px) var(--button-padding-bottom, 0) var(--button-padding-start, 48px);
  font-family: inherit;
  font-size: inherit;
  font-style: inherit;
  font-weight: inherit;
  letter-spacing: inherit;
  text-decoration: inherit;
  text-overflow: inherit;
  text-transform: inherit;
  text-align: inherit;
  white-space: inherit;
  color: inherit;
  display: block;
  position: relative;
  width: 100%;
  height: 100%;
  transition: var(--transition);
  border-width: var(--border-width);
  border-style: var(--border-style);
  border-color: var(--border-color);
  outline: none;
  background: var(--background);
  line-height: 1;
  box-shadow: var(--box-shadow);
  contain: layout style;
  cursor: pointer;
  opacity: var(--opacity);
  overflow: var(--overflow);
  z-index: 0;
  box-sizing: border-box;
  appearance: none;
}

.button-native[disabled] {
  cursor: default;
  opacity: 0.5;
  pointer-events: none;
}

:host(.focused) .button-native {
  background: var(--background-focused);
  color: var(--color-focused);
}

:host(.activated) .button-native {
  background: var(--background-activated);
  color: var(--color-activated);
}

.button-inner {
  display: flex;
  flex-flow: row nowrap;
  flex-shrink: 0;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
}

::slotted(lu-icon) {
  font-size: 1.4em;
  pointer-events: none;
}

::slotted(lu-icon[slot=start]) {
  margin: 0 0.3em 0 -0.3em;
}

::slotted(lu-icon[slot=end]) {
  margin: 0 -0.2em 0 0.3em;
}

::slotted(lu-icon[slot=icon-only]) {
  padding: 0;
  font-size: 1.8em;
}

@media (any-hover: hover) {
  :host(.button-outline:hover) .button-native {
    background: var(--background-hover-outline);
    color: var(--color-hover-outline);
  }

  :host(.button-outline.lu-color:hover) .button-native {
    background: rgba(var(--lu-color-base-rgb), 1);
    color: white;
  }

  :host(.button-clear:hover) .button-native {
    background: var(--background-hover-clear);
  }

  :host(.button-clear.lu-color:hover) .button-native {
    background: rgba(var(--lu-color-base-rgb), 0.04);
  }

  :host(.button-solid:hover) .button-native {
    background: var(--background-hover);
  }

  :host(.button-solid.lu-color:hover) .button-native {
    background: var(--lu-color-shade);
  }
}