/* 
   PDFjin AI Studio Design System 
   Premium effects and styles for AI-powered document tools.
*/

:root {
    --ai-primary: #8b5cf6;
    --ai-secondary: #d946ef;
    --ai-bg: linear-gradient(135deg, rgba(139, 92, 246, 0.05) 0%, rgba(217, 70, 239, 0.05) 100%);
    --ai-glow: 0 0 20px rgba(139, 92, 246, 0.4);
}

/* AI Service Card Glow */
.service-card.cat-ai {
    border: 1px solid rgba(139, 92, 246, 0.2);
    position: relative;
    overflow: hidden;
}

.service-card.cat-ai .card-icon-wrap {
    background: var(--ai-bg);
}

/* AI Badge */
.ai-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    background: linear-gradient(90deg, var(--ai-primary), var(--ai-secondary));
    color: white;
    font-size: 0.7rem;
    font-weight: 800;
    padding: 2px 8px;
    border-radius: 20px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

/* Chat Interface Styles */
.ai-chat-container {
    display: flex;
    flex-direction: column;
    height: 600px;
    background: white;
    border-radius: 16px;
    border: 1px solid #e2e8f0;
    box-shadow: 0 10px 25px rgba(0,0,0,0.05);
    overflow: hidden;
}

.ai-chat-messages {
    flex: 1;
    padding: 20px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 15px;
    background: #f8fafc;
}

.message {
    max-width: 80%;
    padding: 12px 18px;
    border-radius: 14px;
    font-size: 0.95rem;
    line-height: 1.6;
}

.message.user {
    align-self: flex-end;
    background: var(--ai-primary);
    color: white;
    border-bottom-right-radius: 2px;
}

.message.ai {
    align-self: flex-start;
    background: white;
    color: #1e293b;
    border-bottom-left-radius: 2px;
    border: 1px solid #e2e8f0;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.02);
}

.ai-chat-input-area {
    padding: 15px 20px;
    background: white;
    border-top: 1px solid #e2e8f0;
    display: flex;
    gap: 12px;
    align-items: center;
}

.ai-chat-input {
    flex: 1;
    padding: 12px 16px;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    outline: none;
    font-size: 0.95rem;
    transition: all 0.2s;
}

.ai-chat-input:focus {
    border-color: var(--ai-primary);
    box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.1);
}

.ai-send-btn {
    background: var(--ai-primary);
    color: white;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    cursor: pointer;
    transition: all 0.2s;
}

.ai-send-btn:hover {
    background: #7c3aed;
    transform: scale(1.05);
}

/* Extraction UI */
.extraction-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
}

.data-preview-card {
    background: #1e293b;
    color: #f8fafc;
    padding: 25px;
    border-radius: 12px;
    border: 1px solid #334155;
    font-family: 'Fira Code', 'Monaco', 'Consolas', monospace;
    font-size: 0.9rem;
    overflow-x: auto;
    white-space: pre-wrap;
    height: 100%;
}

@media (max-width: 768px) {
    .extraction-grid {
        grid-template-columns: 1fr;
    }
}
