:root {
    --tooltip-font-color: #FFFFFF !important;
    --tooltip-background-color: #73879C !important;
    --tooltip-box-shadow: 1px 1px 8px rgba(0, 0, 0, 0.2) !important;
}

span[data-tooltip].top:before, span[data-tooltip].top:after {
    transform: translateY(10px);
}
span[data-tooltip].top:hover:after, span[data-tooltip].top:hover:before {
    transform: translateY(0px);
}

span[data-tooltip].right:before, span[data-tooltip].right:after {
    transform: translateX(0px);
}
span[data-tooltip].right:hover:after, span[data-tooltip].right:hover:before {
    transform: translateX(10px);
}

span[data-tooltip].bottom:before, span[data-tooltip].bottom:after {
    transform: translateY(-10px);
}
span[data-tooltip].bottom:hover:after, span[data-tooltip].bottom:hover:before {
    transform: translateY(0px);
}

span[data-tooltip].left:before, span[data-tooltip].left:after {
    transform: translateX(0px);
}
span[data-tooltip].left:hover:after, span[data-tooltip].left:hover:before {
    transform: translateX(-10px);
}

span[data-tooltip] {
    position: relative;
    z-index: unset !important;
    display: inline-block;
    width: auto !important;
}
span[data-tooltip]:after, span[data-tooltip]:before {
    position: absolute;
    visibility: hidden;
    opacity: 0;
    transition: transform 400ms ease, opacity 400ms;
    box-shadow: var(--tooltip-box-shadow);
    z-index: 99;
    bottom: unset !important;
    margin-left: unset !important;
}
span[data-tooltip]:before {
    content: attr(data-tooltip);
    background: var(--tooltip-background-color);
    color: var(--tooltip-font-color);
    font-size: 10px;
    padding: 10px 15px;
    border-radius: 4px;
}
span[data-tooltip]:after {
    width: 0;
    height: 0;
    border: 6px solid transparent;
    content: '';
}
span[data-tooltip]:hover:after, span[data-tooltip]:hover:before {
    visibility: visible;
    opacity: 1;
    transform: translateY(0px);
}

span[data-tooltip][data-position="top"]:before {
    bottom: 100%;
    left: -130%;
    margin-bottom: 10px;
}

span[data-tooltip][data-position="top"]:after {
    border-top-color: var(--tooltip-background-color);
    border-bottom: none;
    bottom: 101%;
    left: calc(50% - 6px);
    margin-bottom: 4px;
    box-shadow: none;
}

span[data-tooltip][data-position="bottom"]:before {
    top: 100%;
    left: -50%;
    margin-top: 10px;
    min-width: 140px;
}

span[data-tooltip][data-position="bottom"]:after {
    border-bottom-color: var(--tooltip-background-color);
    border-top: none;
    top: 100%;
    left: 5px;
    margin-top: 4px;
    box-shadow: none;
}

span[data-tooltip][data-position="left"]:before {
    top: -60%;
    right: 100%;
    margin-right: 10px;
    min-width: 100px;
    left: unset;
}

span[data-tooltip][data-position="left"]:after {
    border-left-color: var(--tooltip-background-color);
    border-right: none;
    top: calc(50% - 3px);
    right: 100%;
    margin-top: -6px;
    margin-right: 4px;
    box-shadow: none;
    left: unset;
}

span[data-tooltip][data-position="right"]:before {
    top: -5%;
    left: 100%;
    margin-left: 10px;
}

span[data-tooltip][data-position="right"]:after {
    border-right-color: var(--tooltip-background-color);
    border-left: none;
    top: calc(50% - 6px);
    left: calc(100% + 4px);
    box-shadow: none;
}