/* Ethique Sante — Styles personnalises */

/* Typographie */
body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

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

#chat-messages > div {
    animation: fadeIn 0.2s ease-out;
}

/* Scrollbar personnalisee */
#chat-messages::-webkit-scrollbar {
    width: 6px;
}

#chat-messages::-webkit-scrollbar-track {
    background: transparent;
}

#chat-messages::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 3px;
}

#chat-messages::-webkit-scrollbar-thumb:hover {
    background: #94a3b8;
}

/* Textarea focus */
textarea:focus {
    outline: none;
}

/* Note ethique : rendu markdown */
.note-content h2 {
    font-size: 1.25rem;
    font-weight: 700;
    color: #1a365d;
    border-bottom: 2px solid #e2e8f0;
    padding-bottom: 0.5rem;
}

.note-content h3 {
    font-size: 1.1rem;
    font-weight: 600;
    color: #2d5086;
}

.note-content blockquote {
    border-left: 3px solid #2f855a;
    padding-left: 1rem;
    margin: 1rem 0;
    color: #4a5568;
    font-style: italic;
}

.note-content code {
    background: #f7fafc;
    padding: 0.125rem 0.375rem;
    border-radius: 0.25rem;
    font-size: 0.875rem;
}

.note-content ul {
    list-style-type: disc;
}

.note-content ol {
    list-style-type: decimal;
}

/* Chat : prose dans les bulles */
.msg-content p {
    margin-bottom: 0.5rem;
}

.msg-content p:last-child {
    margin-bottom: 0;
}

.msg-content ul, .msg-content ol {
    padding-left: 1.25rem;
    margin-bottom: 0.5rem;
}

.msg-content li {
    margin-bottom: 0.125rem;
}

.msg-content h2, .msg-content h3 {
    font-weight: 600;
    margin-top: 0.75rem;
    margin-bottom: 0.375rem;
    color: #1a365d;
}

.msg-content h2 {
    font-size: 1rem;
}

.msg-content h3 {
    font-size: 0.9375rem;
}

.msg-content blockquote {
    border-left: 2px solid #2f855a;
    padding-left: 0.75rem;
    color: #4a5568;
    font-style: italic;
    margin: 0.5rem 0;
}

/* Print */
@media print {
    .note-content {
        font-size: 11pt;
        line-height: 1.6;
    }

    .note-content h2 {
        font-size: 14pt;
        page-break-after: avoid;
    }

    .note-content h3 {
        font-size: 12pt;
        page-break-after: avoid;
    }

    body {
        color: #000;
    }
}

/* Spinner pour le bouton de generation */
.animate-spin {
    animation: spin 1s linear infinite;
    display: inline-block;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* Line clamp pour les sources */
.line-clamp-3 {
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
