.asb-d3-chart { width: 100%; height: 100%; & .tooltip { @color: white; @bg-color: rgba(0, 0, 0, .75); @arrow-size: 8px; width: 100%; height: 100%; font-size: 13px; color: @color; position: absolute; padding: 5px; border: none; border-radius: 2px; background-color: @bg-color; transition: opacity .1s ease-out; &::after { content: ' '; position: absolute; width: 0; height: 0; border: @arrow-size solid transparent; } &.top { margin-top: @arrow-size; height: 100% - @arrow-size; &::after { border-bottom-color: @bg-color; top: -@arrow-size*2; left: 50%; margin-left: -@arrow-size; } } &.bottom { margin-bottom: @arrow-size; height: 100% - @arrow-size; &::after { border-top-color: @bg-color; top: 100%; left: 50%; margin-left: -@arrow-size; } } &.left { margin-left: @arrow-size; width: 100% - @arrow-size; &::after { border-right-color: @bg-color; margin-top: -@arrow-size; top: 50%; right: 100%; } } &.right { margin-right: @arrow-size; width: 100% - @arrow-size; &::after { border-left-color: @bg-color; margin-top: -@arrow-size; top: 50%; left: 100%; } } & .tooltip-content { overflow: hidden; width: 100%; height: 100%; & .tooltip-group { display: flex; flex-direction: column; justify-content: stretch; align-items: flex-start; & .group-label { width: 200%; overflow: hidden; & span { font-weight: 600; margin-left: 5px; white-space: nowrap; } } } } } & .chart-empty { display: flex; justify-content: center; align-items: center; width: 100%; height: 100%; } & .adaptive-tooltip { left: 0; right: 0; margin: 0 auto; } } @media (max-width: 1830px) { .asb-d3-chart .adaptive-tooltip { max-width: 190px; font-size: 10px; } } @media (max-width: 1600px) { .asb-d3-chart .adaptive-tooltip { max-width: 160px; font-size: 8px; } } @media (max-width: 1420px) { .asb-d3-chart .adaptive-tooltip { max-width: 140px; font-size: 7px; padding: 0; } } @media (max-width: 1300px) { .asb-d3-chart .adaptive-tooltip { max-width: 125px; } } @media (max-width: 1200px) { .asb-d3-chart .adaptive-tooltip { max-width: 105px; font-size: 6px; } } @media (max-width: 1100px) { .asb-d3-chart .adaptive-tooltip { max-width: 90px; } }