/* .deepseek-chat-container {
    max-width: 800px;
    margin: 20px auto;
    border: 1px solid #e1e8ed;
    border-radius: 12px;
    background: #fff;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    cursor: default;
} */

.deepseek-chat-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
    padding: 20px;
    border-radius: 12px 12px 0 0;
    position: relative;
    z-index: 100;
}

.deepseek-chat-header h3 {
    margin: 0;
    font-size: 1.3em;
}

.deepseek-prompt-selector {
    background: rgba(255,255,255,0.9);
    border: 1px solid rgba(255,255,255,0.3);
    border-radius: 6px;
    padding: 8px 12px;
    color: #333;
    min-width: 200px;
    cursor: pointer;
    z-index: 1000;
    position: relative;
}


.deepseek-message {
    margin-bottom: 16px;
    padding: 16px 20px;
    border-radius: 12px;
    line-height: 1.5;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.deepseek-user-message {
    background: linear-gradient(135deg, #4facfe, #00f2fe);
    color: white;
    margin-left: 60px;
    border-left: 4px solid #1890ff;
    cursor: default;
}

.deepseek-ai-message {
    background: white;
    color: #333;
    margin-right: 60px;
    border: 1px solid #e1e8ed;
    border-left: 4px solid #667eea;
    user-select: text;
    -webkit-user-select: text;
    -moz-user-select: text;
    -ms-user-select: text;
    cursor: text;
}

.deepseek-welcome-message {
    background: linear-gradient(135deg, #48bb78, #38a169);
    color: white;
    padding: 20px;
    border-radius: 10px;
    text-align: center;
    margin-bottom: 20px;
}

/* .deepseek-chat-input {
    padding: 20px;
    background: #f8f9fa;
    border-top: 1px solid #e1e8ed;
} */

.deepseek-chat-input textarea {
    width: 100%;
    padding: 16px;
    border: 2px solid #e1e8ed;
    border-radius: 8px;
    resize: vertical;
    font-family: inherit;
    font-size: 15px;
    min-height: 80px;
    max-height: 200px;
    transition: border-color 0.3s;
}

.deepseek-chat-input textarea:focus {
    outline: none;
    border-color: #667eea;
}

.deepseek-input-actions {
    display: flex;
    gap: 12px;
    margin-top: 15px;
}

.deepseek-chat-input button {
    padding: 12px 24px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 15px;
    font-weight: 500;
    transition: all 0.3s;
}

.deepseek-send-btn {
    background: #667eea;
    color: white;
}

.deepseek-send-btn:hover:not(:disabled) {
    background: #5a6fd8;
    transform: translateY(-1px);
}

.deepseek-send-btn:disabled {
    background: #ccc;
    cursor: not-allowed;
    transform: none;
}

.deepseek-clear-btn {
    background: #e53e3e;
    color: white;
}

.deepseek-clear-btn:hover {
    background: #c53030;
}

.deepseek-chat-status {
    padding: 10px;
    color: #666;
    font-size: 14px;
    min-height: 20px;
}

.deepseek-typing {
    color: #667eea;
    font-style: italic;
}

.deepseek-typing::after {
    content: '...';
    animation: typing 1.5s infinite;
}

@keyframes typing {
    0%, 20% { content: '.'; }
    40% { content: '..'; }
    60%, 100% { content: '...'; }
}

/* Анимация "ИИ думает" */
.deepseek-thinking-animation {
    background: white;
    margin: 10px 60px 10px 0px;
    padding: 20px;
    border-radius: 12px;
    border: 1px solid #e1e8ed;
    border-left: 4px solid #667eea;
    text-align: center;
}

.thinking-content {
    display: flex;
    align-items: center;
    /* justify-content: center; */
    gap: 15px;
}

.thinking-dots {
    display: flex;
    gap: 4px;
}

.thinking-dots span {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #667eea;
    animation: thinking-bounce 1.4s infinite ease-in-out;
}

.thinking-dots span:nth-child(1) { animation-delay: -0.32s; }
.thinking-dots span:nth-child(2) { animation-delay: -0.16s; }


@keyframes thinking-bounce {
    0%, 80%, 100% {
        transform: scale(0.8);
        opacity: 0.5;
    }
    40% {
        transform: scale(1);
        opacity: 1;
    }
}

/* Инлайновый код */
.deepseek-inline-code {
    background: #edf2f7;
    color: #c53030;
    padding: 2px 6px;
    border-radius: 4px;
    font-family: 'Courier New', Monaco, monospace;
    font-size: 0.9em;
}

/* Форматирование текста */
.deepseek-ai-message h1,
.deepseek-ai-message h2,
.deepseek-ai-message h3 {
    margin: 20px 0 15px 0;
    color: #2d3748;
    font-weight: 600;
}

.deepseek-ai-message h1 { 
    font-size: 1.5em; 
    border-bottom: 2px solid #667eea; 
    padding-bottom: 8px; 
}

.deepseek-ai-message h2 { 
    font-size: 1.3em; 
    border-left: 4px solid #667eea; 
    padding-left: 12px; 
    margin-top: 25px;
}

.deepseek-ai-message h3 { 
    font-size: 1.1em; 
    color: #4a5568; 
    margin-top: 20px;
}

.deepseek-ai-message strong { 
    font-weight: 600; 
    /* color: #2d3748;  */
}

.deepseek-ai-message em { 
    font-style: italic; 
    color: #718096; 
}

.deepseek-ai-message ul,
.deepseek-ai-message ol {
    margin: 15px 0;
    padding-left: 24px;
}

.deepseek-ai-message li {
    margin: 8px 0;
    line-height: 1.5;
}

.deepseek-ai-message p {
    margin: 12px 0;
    line-height: 1.6;
}

.deepseek-ai-message p:first-child {
    margin-top: 0;
}

.deepseek-ai-message p:last-child {
    margin-bottom: 0;
}

/* Стили для pre и code */
.deepseek-ai-message pre {
    background: #1a202c;
    color: #e2e8f0;
    padding: 16px;
    border-radius: 8px;
    overflow-x: auto;
    margin: 15px 0;
    white-space: normal;
    /* border-left: 4px solid #667eea; */
}

.deepseek-ai-message pre code {
    background: none;
    color: inherit;
    padding: 0;
    font-family: 'Courier New', Monaco, monospace;
    font-size: 0.9em;
    line-height: 1.4;
}

.deepseek-ai-message code {
    font-family: 'Courier New', Monaco, monospace;
}

/* Стили для статуса лимитов */
.deepseek-limits-status {
    margin-top: 5px;
    font-size: 13px;
    font-weight: 500;
}

/* Анимация появления текста */
.deepseek-streaming-text {
    animation: textAppear 0.1s ease-in;
}

@keyframes textAppear {
    from {
        opacity: 0.7;
        transform: translateY(2px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Адаптивность */
@media (max-width: 768px) {
    .deepseek-chat-container {
        /* margin: 10px; */
        border-radius: 8px;
    }
    
    .deepseek-chat-header {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
    
    .deepseek-prompt-selector {
        min-width: 100%;
        margin-top: 10px;
    }
    
    .deepseek-user-message {
        margin-left: 20px;
    }
    
    .deepseek-ai-message {
        margin-right: 0px;
    }
    
    .deepseek-thinking-animation {
        margin: 10px 20px 10px 0px;
    }
    
    /* .deepseek-input-actions {
        flex-direction: column;
    } */
    
    .deepseek-chat-input button {
        width: 100%;
    }
}

/* Уникальные идентификаторы для нескольких чатов */
.deepseek-chat-container {
    margin-bottom: 30px;
}

.deepseek-chat-container:last-child {
    margin-bottom: 0;
}

.deepseek-limits-status {
    transition: all 0.3s ease;
}

.deepseek-limits-status.limits-critical {
    color: #e53e3e;
    font-weight: bold;
}

.deepseek-limits-status.limits-warning {
    color: #ed8936;
}

.deepseek-limits-status.limits-normal {
    color: #38a169;
}

/* Стили для выделенного текста в потоковом режиме */
.deepseek-ai-message .message-content {
    min-height: 20px;
}



.deepseek-chat-header, .deepseek-welcome-message {
    display: none;
}

.post-618 .entry-content p {
    max-width: 100%;
}