/* Online Status Indicators */
.online-status-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.85rem;
}

.status-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    display: inline-block;
    animation: pulse 2s infinite;
    box-shadow: 0 0 0 0 rgba(40, 167, 69, 0.7);
}

.online-status-badge[data-status="online"] .status-dot {
    background-color: #28a745;
    animation: pulse-online 2s infinite;
}

.online-status-badge[data-status="away"] .status-dot {
    background-color: #ffc107;
    animation: pulse-away 2s infinite;
}

.online-status-badge[data-status="offline"] .status-dot {
    background-color: #6c757d;
    animation: none;
}

@keyframes pulse-online {
    0% {
        box-shadow: 0 0 0 0 rgba(40, 167, 69, 0.7);
    }
    70% {
        box-shadow: 0 0 0 6px rgba(40, 167, 69, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(40, 167, 69, 0);
    }
}

@keyframes pulse-away {
    0% {
        box-shadow: 0 0 0 0 rgba(255, 193, 7, 0.7);
    }
    70% {
        box-shadow: 0 0 0 6px rgba(255, 193, 7, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(255, 193, 7, 0);
    }
}

.status-text {
    color: #6c757d;
    font-size: 0.8rem;
}

/* Small status dot for avatars */
.avatar-wrapper {
    position: relative;
    display: inline-block;
}

.avatar-wrapper .status-dot-small {
    position: absolute;
    bottom: 2px;
    right: 2px;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    border: 2px solid #fff;
    box-shadow: 0 0 4px rgba(0, 0, 0, 0.3);
}

.avatar-wrapper .status-dot-small.online {
    background-color: #28a745;
}

.avatar-wrapper .status-dot-small.away {
    background-color: #ffc107;
}

.avatar-wrapper .status-dot-small.offline {
    background-color: #6c757d;
}

/* Typing Indicator */
.typing-indicator {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 8px 12px;
    background-color: #f1f3f5;
    border-radius: 18px;
    margin: 5px 0;
}

.typing-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: #6c757d;
    animation: typing-bounce 1.4s infinite ease-in-out both;
}

.typing-dot:nth-child(1) {
    animation-delay: -0.32s;
}

.typing-dot:nth-child(2) {
    animation-delay: -0.16s;
}

.typing-text {
    font-size: 0.8rem;
    color: #6c757d;
    margin-left: 4px;
}

@keyframes typing-bounce {
    0%, 80%, 100% {
        transform: scale(0);
        opacity: 0.5;
    }
    40% {
        transform: scale(1);
        opacity: 1;
    }
}

/* Online status in chat list */
.conversation-item .online-status-badge {
    font-size: 0.75rem;
}

.conversation-item .status-dot {
    width: 8px;
    height: 8px;
}

/* Profile page online status */
.profile-header .online-status-badge {
    margin-left: 10px;
    padding: 4px 10px;
    background-color: rgba(255, 255, 255, 0.9);
    border-radius: 20px;
}

/* Message chat header status */
.chat-header .online-status-badge {
    margin-left: auto;
}
