.buddylist_item {
    display: flex;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    width: 15vw;
    height: 5vh;
    border: solid 1px;
    border-color: gray;
    border-radius: 0 2.5vh 2.5vh 0;
    position: relative;
}

.buddylist_item:has(.buddylist_statusmsg_wrapper:hover) {
    z-index: 100;
}

@media (hover: hover) {
    .buddylist_item:hover {
        background-color: rgba(73, 73, 73, 0.5);
        cursor: pointer;
    }
}

.buddylist_item_status {
    width: 1vw;
    height: 100%;
    background-color: gray;
}

.buddylist_item_left {
    flex: 1;
    min-width: 0;
    max-width: calc(100% - 5.5vw);
    height: 100%;
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: flex-start;
    padding-left: 0.5vw;
    font-size: 1.4vh;
    gap: 0.3vw;
    overflow: hidden;
}

.buddylist_name_container {
    overflow: hidden;
    flex: 1;
    min-width: 0;
}

.buddylist_name {
    display: inline-block;
    white-space: nowrap;
}

.buddylist_name.scrolling {
    animation: buddylist_scroll 4s ease-in-out infinite alternate;
}

@keyframes buddylist_scroll {
    0%, 10% {
        transform: translateX(0);
    }
    90%, 100% {
        transform: translateX(var(--scroll-distance, -50%));
    }
}

.buddylist_statusmsg_wrapper {
    position: relative;
    display: inline-flex;
    align-items: center;
    flex-shrink: 0;
}

.buddylist_statusmsg_icon {
    height: min(2vh, 1.5vw);
    width: min(2vh, 1.5vw);
    cursor: pointer;
    flex-shrink: 0;
}

.buddylist_statusmsg_tooltip {
    display: none;
    position: fixed;
    background-color: rgba(30, 30, 30, 0.95);
    color: white;
    font-size: 1.2vh;
    padding: calc(0.8vh + 10px) calc(1vw + 10px);
    border-radius: 0.5vh;
    white-space: pre-wrap;
    min-width: 20vw;
    max-width: 35vw;
    z-index: 200;
    box-shadow: 0 2px 8px rgba(0,0,0,0.3);
}


.buddylist_item_right {
    display: flex;
    justify-content:flex-end;
    align-items: center;
    height: 100%;
    width: min(3.5vw, 5vh);
    flex-shrink: 0;
}

.buddylist_icon_container {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.buddylist_item_icon {
    width: 4vh;
    height: 4vh;
    border-radius: 20vw;
    margin: 0.5vh;
    border: solid 1px;
    border-color: gray;
    height: 3vh;
    width: 3vh;
    min-width: 3vh;
}

.buddylist_cmd_icon {
    width: min(2vh, 1.5vw);
    height: min(2vh, 1.5vw);
    margin: 0.1vh;
    border-radius: 50%;
    border: solid 1px;
    border-color: transparent;
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: center;
}

@media (hover: hover) {
    .buddylist_cmd_icon:hover {
        border-color: gray;
        background-color: rgba(200, 200, 200, 0.2);
        cursor: pointer;
    }
}

.bl_status_red {
    background-color: red;
}

.bl_status_green {
    background-color: green;
}

.bl_offline {
    background-color: gray;
}

.bl_busy {
    background-color: red;
}

.bl_idle {
    background-color: green;
}

.bl_ring {
     animation: blinker 1s linear infinite;
}

.bl_avoid {
    background-color: blue;
}


.bi_offline {
    background-color: rgba(128, 128, 128, 0.3);
}

.bi_busy {
    background-color: rgba(255, 70, 70, 0.5);
}

.bi_idle {
    background-color: transparent;
}

.bi_ring {
    background-color: rgba(255, 70, 70, 0.5);
}

@keyframes blinker {
    from,
    49.9% {
          background-color: red;
    }
    50%,
    to {
          background-color: transparent;
    }
}

.bl_status_bubble {
    position: absolute;
    bottom: -2px;
    width: 1.5vh;
    height: 1.5vh;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: solid 1px rgba(0, 0, 0, 0.3);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

.bl_status_bubble svg {
    width: 1vh;
    height: 1vh;
}

.bl_status_uml {
    background-color: #2196F3;
}

.bl_status_uml_left {
    right: 1.3vh;
}

.bl_status_uml_right {
    right: -2px;
}

.bl_status_dnd {
    background-color: #f44336;
    right: -2px;
}

