/* La bulle d'une conversation avec Aurore AI (public/js/auroreAiBubble.js) : le Markdown de l'assistant et les cartes de la recherche de fichiers.
   Pas de bordure visible : un fond et une ombre légère. La bulle de l'assistant est sur --color-bg ; les cartes sont sur --color-surface. */

/* ── Le Markdown de l'assistant, dans un volet étroit : serré, jamais plus grand que le texte de la bulle ── */
.ai-md > :first-child { margin-top: 0; }
.ai-md > :last-child { margin-bottom: 0; }
.ai-md p, .ai-md ul, .ai-md ol, .ai-md blockquote, .ai-md pre { margin: 0 0 .5em; }
.ai-md ul, .ai-md ol { padding-left: 1.3em; }
.ai-md li + li { margin-top: .15em; }
.ai-md h1, .ai-md h2, .ai-md h3, .ai-md h4, .ai-md h5, .ai-md h6 { margin: .6em 0 .3em; font-size: 1em; font-weight: 700; line-height: 1.3; }
.ai-md blockquote { padding-left: .8em; color: var(--color-text-secondary, #86868b); box-shadow: inset 2px 0 0 var(--color-border, #d2d2d7); }
.ai-md code { padding: 1px 5px; border-radius: 5px; background: var(--color-surface, #fff); font-size: .92em; }
.ai-md pre { padding: 8px 10px; border-radius: 10px; background: var(--color-surface, #fff); overflow-x: auto; }
.ai-md pre code { padding: 0; background: none; }
.ai-md a { color: var(--color-primary, #007aff); text-decoration: underline; text-underline-offset: 2px; }
.ai-md hr { height: 1px; margin: .7em 0; border: 0; background: var(--color-border, #d2d2d7); opacity: .6; }

/* ── Les cartes de la recherche de fichiers ── */
.ai-find { margin-top: 8px; display: flex; flex-direction: column; gap: 6px; }
.ai-find-query { font-size: 12px; color: var(--color-text-secondary, #86868b); overflow-wrap: anywhere; }
.ai-find-state { font-size: 13px; color: var(--color-text-secondary, #86868b); }
.ai-find-list { display: flex; flex-direction: column; gap: 4px; }
.ai-find-card {
    display: flex; align-items: center; gap: 10px; width: 100%; padding: 6px 8px; border: 0; border-radius: 12px;
    background: var(--color-surface, #fff); color: var(--color-text, #1d1d1f); font: inherit; text-align: left; cursor: pointer;
    box-shadow: 0 1px 2px rgba(0, 0, 0, .06);
}
.ai-find-card:hover { background: var(--color-surface-hover, #fafafa); }
.ai-find-card:focus-visible { outline: 2px solid var(--color-primary, #007aff); outline-offset: 1px; }
.ai-find-thumb {
    flex: 0 0 40px; width: 40px; height: 40px; border-radius: 8px; overflow: hidden; display: flex; align-items: center; justify-content: center;
    background: var(--color-bg, #f5f5f7); color: var(--color-text-secondary, #86868b); font-size: 11px; font-weight: 700;
}
.ai-find-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ai-find-body { display: flex; flex-direction: column; min-width: 0; }
.ai-find-name { font-size: 13.5px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ai-find-meta { font-size: 11.5px; color: var(--color-text-secondary, #86868b); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ai-find-snippet { font-size: 12px; line-height: 1.35; color: var(--color-text, #1d1d1f); display: -webkit-box; -webkit-line-clamp: 2; line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; overflow-wrap: anywhere; }
.ai-find-storage { display: flex; flex-direction: column; gap: 6px; padding: 8px 10px; border-radius: 12px; background: var(--color-surface, #fff); box-shadow: 0 1px 2px rgba(0, 0, 0, .06); }
.ai-find-gauge { height: 8px; border-radius: 999px; overflow: hidden; background: var(--color-bg, #f5f5f7); }
.ai-find-gauge-bar { height: 100%; border-radius: 999px; background: var(--color-primary, #007aff); }
.ai-find-retry {
    align-self: flex-start; padding: 6px 12px; border: 0; border-radius: 999px; background: var(--color-surface, #fff); color: var(--color-primary, #007aff);
    font: inherit; font-size: 13px; font-weight: 600; cursor: pointer; box-shadow: 0 1px 2px rgba(0, 0, 0, .06);
}
.ai-find-retry:hover { background: var(--color-surface-hover, #fafafa); }
.ai-find-retry:focus-visible { outline: 2px solid var(--color-primary, #007aff); outline-offset: 1px; }
