.live-chat {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 14px 14px 16px;
    box-sizing: border-box;
    overflow-y: auto;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    -webkit-font-smoothing: antialiased;
}

.live-chat__row {
    display: flex;
    flex-direction: column;
    width: 100%;
}

.live-chat__row--me {
    align-items: flex-end;
}

.live-chat__row--them {
    align-items: flex-start;
}

.live-chat__msg {
    display: flex;
    flex-direction: column;
    max-width: 88%;
    opacity: 0;
    transform: scale(0.92) translateY(8px);
    animation: liveChatIn 0.65s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

.live-chat__time {
    font-size: 10px;
    color: #9ca3af;
    margin-bottom: 4px;
    font-weight: 500;
}

.live-chat__row--me .live-chat__time {
    padding-right: 4px;
    text-align: right;
}

.live-chat__row--them .live-chat__time {
    padding-left: 4px;
}

.live-chat__bubble {
    padding: 10px 13px;
    line-height: 1.4;
    font-size: 0.84rem;
    word-break: break-word;
}

.live-chat__bubble--me {
    color: #fff;
    background: linear-gradient(135deg, #6a0dad, #9d4edd);
    border-radius: 16px 16px 4px 16px;
    box-shadow: 0 2px 8px rgba(106, 13, 173, 0.2);
}

.live-chat__bubble--them {
    color: #1f2937;
    background: #f3f4f6;
    border-radius: 16px 16px 16px 4px;
}

.live-chat__typing {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 11px 14px;
    background: #f3f4f6;
    border-radius: 16px 16px 16px 4px;
    opacity: 0;
    animation: liveChatIn 0.65s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

.live-chat__dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #9ca3af;
    animation: liveChatDot 0.8s ease-in-out infinite;
}

.live-chat__dot:nth-child(2) {
    animation-delay: 0.15s;
}

.live-chat__dot:nth-child(3) {
    animation-delay: 0.3s;
}

@keyframes liveChatIn {
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

@keyframes liveChatDot {
    0%, 100% {
        transform: translateY(0);
        opacity: 0.4;
    }
    50% {
        transform: translateY(-4px);
        opacity: 1;
    }
}

@media (prefers-reduced-motion: reduce) {
    .live-chat__msg,
    .live-chat__typing {
        animation: none;
        opacity: 1;
        transform: none;
    }

    .live-chat__dot {
        animation: none;
    }
}
