@use 'styles/variables.scss' as *;
@use './theme.scss' as *;

$root: 'tooltip';

.#{$root} {
  @include tooltip-theme-modifiers();

  &[data-popper-reference-hidden] {
    visibility: hidden;
  }

  &__content {
    background-color: tooltip-theme-color('background');
    box-shadow: 0 5px 20px 0 tooltip-theme-color('shadow');
    color: tooltip-theme-color('text');
    border-radius: 5px;
    padding: 8px 0;
    max-width: none;
  }

  &__arrow {
    &::before {
      background-color: tooltip-theme-color('background');
      border-radius: 2px;
    }
  }

  &__body {
    max-width: 400px;
    max-height: 312px;
    padding: 0 10px;
    overflow-wrap: break-word;
    overflow-x: hidden;
    overflow-y: auto;
  }
}

$trigger: 'tooltip-trigger';

.#{$trigger} {
  max-width: 100%;
  width: fit-content;
}
