/*
* TODO: IMPLEMENT NEW TOKENS
* When new alert-colors are defined, update the following styles accordingly.
*/

.md-info-tag {
  display: flex;
  justify-content: flex-start;
  align-items: center;
  max-width: fit-content;
  z-index: 2;
  background-color: var(--md-color-surface-info-primary);
  color: var(--md-color-text-primary);
  padding: 0.25rem 0.75rem 0.25rem 0.75rem;
  border-radius: var(--md-size-1);
  font-family: var(--md-typography-family-body);
  text-align: left;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  border: none;
}

.md-info-tag--button:hover {
  outline: var(--md-size-3) solid var(--md-color-border-tertiary);
  outline-offset: var(--md-size-3);
  text-decoration: underline;
  cursor: pointer;
}

.md-info-tag--secondary {
  background-color: var(--md-color-surface-info-secondary);
}
.md-info-tag--warning {
  background-color: transparent;
}
.md-info-tag--warning.md-info-tag--button:hover {
  outline: var(--md-size-3) solid var(--md-color-attention-warning-primary);
  outline-offset: var(--md-size-3);
}

.md-info-tag--danger {
  background-color: var(--md-color-attention-error-primary);
  color: #fff;
}
.md-info-tag--success {
  background-color: var(--md-color-primary-60);
}

.md-info-tag--outline {
  /*
  outline: var(--md-size-3) var(--md-color-focus-outer) solid;
  outline-offset: var(--md-size-3);
  box-shadow: 0 0 0 var(--md-size-3) var(--md-color-focus-inner);   
  transition: box-shadow 150ms ease-in-out, outline 150ms ease-in-out;
  */
  border: var(--md-size-1) solid var(--md-color-focus-outer);
  transition: border 150ms ease-in-out;
}

.md-info-tag__label {
  display: flex;
  max-width: 0;
  overflow: hidden;
  justify-content: center;
  align-items: center;
  font-size: var(--md-typography-size-14);
  line-height: var(--md-typography-line-height-small);
  color: var(--md-color-text-primary);
}
.md-info-tag:hover .md-info-tag__label {
  max-width: 100%;
  padding-right: 1rem;
  transition: max-width 0.3s ease-in;
  white-space: nowrap;
}

.md-info-tag__label--show {
  max-width: 100%;
  padding-right: 1rem;
  transition: max-width 0.3s ease-in;
  white-space: nowrap;
}

.md-info-tag__icon {
  height: var(--md-size-20);
  width: var(--md-size-20);
}
