/**
 * Message Status Styles
 * Delivery indicators and timestamps
 */

.message-status-indicator {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    margin-top: 4px;
    gap: 6px;
}

.status-icon {
    font-size: 11px;
    display: flex;
    align-items: center;
    gap: 4px;
    transition: all 0.2s;
}

.status-sending {
    color: #9ca3af;
    animation: pulse 1.5s ease-in-out infinite;
}

.status-sent {
    color: #9ca3af;
}

.status-delivered {
    color: #3b82f6;
}

.status-read {
    color: #10b981;
}

.status-error {
    color: #ef4444;
}

.message-timestamp {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.7);
    margin-top: 4px;
    text-align: right;
    opacity: 0;
    transition: opacity 0.2s;
}

.user-message:hover .message-timestamp,
.ai-message:hover .message-timestamp {
    opacity: 1;
}

/* Typing Status Indicator */
.typing-status-indicator {
    display: flex;
    justify-content: flex-start;
    margin: 16px 0;
    animation: fadeIn 0.3s ease-out;
}

.typing-status-content {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    background: var(--bg-secondary, #f8f9fa);
    border-radius: 12px;
    border: 1px solid var(--border-primary, #e2e8f0);
}

.typing-avatar {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.typing-avatar img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.typing-text {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    color: var(--text-tertiary, #718096);
}

.typing-dots {
    display: flex;
    gap: 4px;
}

.typing-dots span {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--text-tertiary, #718096);
    animation: typingBounce 1.4s ease-in-out infinite;
}

.typing-dots span:nth-child(1) {
    animation-delay: 0s;
}

.typing-dots span:nth-child(2) {
    animation-delay: 0.2s;
}

.typing-dots span:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes typingBounce {
    0%, 60%, 100% {
        transform: translateY(0);
    }
    30% {
        transform: translateY(-8px);
    }
}

@keyframes pulse {
    0%, 100% {
        opacity: 0.5;
    }
    50% {
        opacity: 1;
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Dark mode */
html.dark-mode .status-sending,
html.dark-mode .status-sent {
    color: #6b7280;
}

html.dark-mode .status-delivered {
    color: #60a5fa;
}

html.dark-mode .status-read {
    color: #34d399;
}

html.dark-mode .status-error {
    color: #f87171;
}

html.dark-mode .typing-status-content {
    background: #1f2937;
    border-color: #374151;
}

html.dark-mode .typing-text {
    color: #9ca3af;
}

html.dark-mode .typing-dots span {
    background: #9ca3af;
}

/* Mobile responsive */
@media (max-width: 640px) {
    .typing-status-content {
        padding: 10px 12px;
    }

    .typing-text {
        font-size: 12px;
    }
}
