/* Container must be relative so the bubble can be positioned absolutely */
.dp-field-tooltip {
    position: relative;
    cursor: help;
}

/* The Bubble itself */
.dp-field-tooltip::after {
    content: attr(data-infobubble); /* Pulls text from the data attribute */
    position: absolute;
    bottom: 125%; /* Position above the element */
    left: 50%;
    transform: translateX(-50%);
    
    /* Styling */
    background-color: #333;
    color: #fff;
    padding: 8px 12px;
    border-radius: 4px;
    font-size: 13px;
    white-space: nowrap;
    z-index: 1000;
    
    /* Hidden by default */
    visibility: hidden;
    opacity: 0;
    transition: opacity 0.2s ease;
    pointer-events: none; /* Prevents the bubble from interfering with mouse clicks */
    box-shadow: 0 2px 10px rgba(0,0,0,0.2);
}

/* The small arrow at the bottom of the bubble */
.dp-field-tooltip::before {
    content: "";
    position: absolute;
    bottom: 115%;
    left: 50%;
    transform: translateX(-50%);
    border-width: 5px;
    border-style: solid;
    border-color: #333 transparent transparent transparent;
    
    visibility: hidden;
    opacity: 0;
    transition: opacity 0.2s ease;
}

/* Show on hover */
.dp-field-tooltip:hover::after,
.dp-field-tooltip:hover::before {
    visibility: visible;
    opacity: 1;
}