/* Aurelo interface. Colors and spacing come from the Fluent design tokens so that light/dark matches. */

:root { color-scheme: light dark; }
html, body { height: 100%; margin: 0; font-family: var(--fontFamilyBase); color: var(--colorNeutralForeground1); background: var(--colorNeutralBackground1); }
#app { height: 100%; }
h1, h2, h3 { margin: 0; font-weight: 600; }
button { font-family: inherit; }

.aurelo-chat, .aurelo-transcript, .aurelo-transcript-inner, .aurelo-composer-wrap { min-width: 0; max-width: 100%; box-sizing: border-box; }

.aurelo-brand-name { font-size: 18px; font-weight: 700; letter-spacing: 0.2px; }
.aurelo-newchat { width: 100%; }
.aurelo-conversations { flex: 1; overflow-y: auto; margin: 0 -4px; padding: 0 4px; }
.aurelo-conversations-empty { color: var(--colorNeutralForeground3); font-size: 13px; padding: 12px 8px; }
.aurelo-group-label { font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.4px; color: var(--colorNeutralForeground3); padding: 12px 8px 4px; }
.aurelo-conversation { display: flex; align-items: center; gap: 4px; padding: 6px 6px 6px 10px; border-radius: var(--borderRadiusMedium); cursor: pointer; font-size: 14px; color: var(--colorNeutralForeground2); }
.aurelo-conversation:hover { background: var(--colorNeutralBackground2Hover); color: var(--colorNeutralForeground1); }
.aurelo-conversation.active { background: var(--colorNeutralBackground1); color: var(--colorNeutralForeground1); box-shadow: var(--shadow2); font-weight: 500; }
.aurelo-conversation-title { flex: 1; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.aurelo-conversation-delete { opacity: 0; }
.aurelo-conversation:hover .aurelo-conversation-delete, .aurelo-conversation.active .aurelo-conversation-delete { opacity: 1; }

/* Chat */
/* min-height: 0 lets the flex and grid items shrink below their content; without it the transcript grows to the
   full height of its messages and never scrolls. */
.aurelo-chat { display: flex; flex-direction: column; height: 100%; min-height: 0; }
.aurelo-transcript { flex: 1; min-height: 0; overflow-y: auto; scroll-behavior: smooth; }
.aurelo-transcript-inner { max-width: 880px; margin: 0 auto; padding: 32px 24px 16px; display: flex; flex-direction: column; gap: 20px; }
.aurelo-composer-wrap { padding: 8px 24px 20px; }
.aurelo-startup { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 16px; height: 100%; padding: 40px; text-align: center; }

.aurelo-suggestions { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 200px), 1fr)); gap: 12px; max-width: none; margin: 0; }
.aurelo-suggestion { display: flex; align-items: center; gap: 10px; padding: 14px 16px; text-align: left; font-size: 14px; color: var(--colorNeutralForeground1); background: var(--colorNeutralBackground1); border: 1px solid var(--colorNeutralStroke2); border-radius: var(--borderRadiusLarge); cursor: pointer; transition: box-shadow .15s, border-color .15s; }
.aurelo-suggestion:hover { border-color: var(--colorBrandStroke1); box-shadow: var(--shadow4); }

.aurelo-msg { display: flex; gap: 12px; }
.aurelo-msg-user { justify-content: flex-end; }
.aurelo-bubble { max-width: 75%; background: var(--colorBrandBackground2); color: var(--colorNeutralForeground1); border-radius: 18px 18px 4px 18px; padding: 10px 14px; }
.aurelo-usertext { white-space: pre-wrap; word-break: break-word; font-size: 15px; line-height: 1.5; }
.aurelo-msg-assistant { align-items: flex-start; }
.aurelo-assistant-avatar { flex: none; width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; background: var(--colorBrandBackground2); margin-top: 2px; }
.aurelo-assistant-body { flex: 1; min-width: 0; }
.aurelo-msg-actions { display: flex; align-items: center; gap: 6px; margin-top: 4px; }
.aurelo-copied { font-size: 12px; color: var(--colorNeutralForeground3); }
.aurelo-error { margin-top: 8px; }

.aurelo-typing { display: inline-flex; gap: 4px; padding: 10px 2px; }
.aurelo-typing span { width: 7px; height: 7px; border-radius: 50%; background: var(--colorNeutralForeground3); animation: aurelo-bounce 1.2s infinite; }
.aurelo-typing span:nth-child(2) { animation-delay: .2s; }
.aurelo-typing span:nth-child(3) { animation-delay: .4s; }
@keyframes aurelo-bounce { 0%, 80%, 100% { transform: translateY(0); opacity: .4; } 40% { transform: translateY(-5px); opacity: 1; } }

/* Markdown */
.aurelo-markdown { font-size: 15px; line-height: 1.6; word-break: break-word; }
.aurelo-markdown > :first-child { margin-top: 0; }
.aurelo-markdown > :last-child { margin-bottom: 0; }
.aurelo-markdown p { margin: 0 0 10px; }
.aurelo-markdown h1, .aurelo-markdown h2, .aurelo-markdown h3 { margin: 18px 0 8px; }
.aurelo-markdown h1 { font-size: 20px; } .aurelo-markdown h2 { font-size: 18px; } .aurelo-markdown h3 { font-size: 16px; }
.aurelo-markdown ul, .aurelo-markdown ol { margin: 0 0 10px; padding-left: 24px; }
.aurelo-markdown li { margin: 2px 0; }
.aurelo-markdown blockquote { margin: 0 0 10px; padding: 2px 12px; border-left: 3px solid var(--colorBrandStroke1); color: var(--colorNeutralForeground2); }
.aurelo-markdown table { border-collapse: collapse; margin: 0 0 12px; font-size: 14px; }
.aurelo-markdown th, .aurelo-markdown td { border: 1px solid var(--colorNeutralStroke2); padding: 6px 10px; text-align: left; }
.aurelo-markdown th { background: var(--colorNeutralBackground3); }
.aurelo-markdown code { font-family: var(--fontFamilyMonospace); font-size: 13.5px; background: var(--colorNeutralBackground3); padding: 1px 5px; border-radius: 4px; }
.aurelo-markdown pre { position: relative; margin: 0 0 12px; padding: 36px 14px 12px; background: var(--colorNeutralBackground3); border: 1px solid var(--colorNeutralStroke2); border-radius: var(--borderRadiusLarge); overflow-x: auto; }
.aurelo-markdown pre code { background: none; padding: 0; font-size: 13px; }
.aurelo-code-header { position: absolute; top: 0; left: 0; right: 0; display: flex; justify-content: space-between; align-items: center; padding: 4px 8px 4px 14px; font-size: 12px; color: var(--colorNeutralForeground3); border-bottom: 1px solid var(--colorNeutralStroke2); }
.aurelo-code-copy { border: none; background: transparent; color: var(--colorBrandForeground1); font-size: 12px; cursor: pointer; padding: 4px 8px; border-radius: 4px; }
.aurelo-code-copy:hover { background: var(--colorNeutralBackground1Hover); }
.aurelo-markdown a { color: var(--colorBrandForeground1); }

/* Input */
.aurelo-composer { max-width: 880px; margin: 0 auto; background: var(--colorNeutralBackground1); border: 1px solid var(--colorNeutralStroke1); border-radius: 20px; box-shadow: var(--shadow8); padding: 10px 12px 8px; transition: border-color .15s, box-shadow .15s; }
.aurelo-composer:focus-within { border-color: var(--colorBrandStroke1); box-shadow: var(--shadow16); }
.aurelo-composer.dragging { border-color: var(--colorBrandStroke1); background: var(--colorBrandBackground2); }
.aurelo-textarea { width: 100%; box-sizing: border-box; resize: none; border: none; outline: none; background: transparent; color: inherit; font: inherit; font-size: 15px; line-height: 1.5; padding: 6px 6px 4px; max-height: 240px; }
.aurelo-composer-bar { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.aurelo-composer-left, .aurelo-composer-right { display: flex; align-items: center; gap: 4px; }
.aurelo-hint { font-size: 12px; color: var(--colorNeutralForeground4); margin-right: 8px; }
.aurelo-uploading { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; color: var(--colorNeutralForeground3); margin-left: 6px; }
.aurelo-upload-error { font-size: 12px; color: var(--colorPaletteRedForeground1); margin-left: 6px; }
@media (max-width: 640px) { .aurelo-hint { display: none; } .aurelo-bubble { max-width: 90%; } .aurelo-transcript-inner, .aurelo-composer-wrap { padding-left: 12px; padding-right: 12px; } }

.aurelo-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 8px; }
.aurelo-chip { display: inline-flex; align-items: center; gap: 6px; max-width: 260px; padding: 4px 8px 4px 8px; font-size: 13px; background: var(--colorNeutralBackground3); border: 1px solid var(--colorNeutralStroke2); border-radius: 999px; }
.aurelo-chip-name { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.aurelo-chip-thumb { width: 20px; height: 20px; object-fit: cover; border-radius: 4px; }
.aurelo-chip-remove { border: none; background: transparent; color: var(--colorNeutralForeground3); cursor: pointer; font-size: 16px; line-height: 1; padding: 0 2px; }
.aurelo-chip-remove:hover { color: var(--colorNeutralForeground1); }


/* Administration */
/* Administration: the page uses the full width. A section list on the left jumps to the areas (AI, Microsoft 365,
   sources); each area is a card with a description on the left and the fields on the right, like the account page. */
.aurelo-admin, .aurelo-settings { height: 100%; overflow-y: auto; padding: 24px 28px 48px; box-sizing: border-box; display: flex; flex-direction: column; gap: 20px; }
.aurelo-page-body { display: grid; grid-template-columns: 200px minmax(0, 1fr); gap: 24px; align-items: start; }
.aurelo-page-nav { position: sticky; top: 0; display: flex; flex-direction: column; gap: 2px; }
.aurelo-page-nav-item { display: flex; align-items: center; gap: 10px; padding: 8px 12px; font: inherit; font-size: 14px; color: var(--colorNeutralForeground2); text-align: left; background: transparent; border: none; border-radius: var(--borderRadiusMedium); cursor: pointer; }
.aurelo-page-nav-item:hover { background: var(--colorNeutralBackground1Hover); color: var(--colorNeutralForeground1); }
.aurelo-page-nav-item:focus-visible { outline: 2px solid var(--colorStrokeFocus2); outline-offset: 2px; }
.aurelo-page-sections { display: flex; flex-direction: column; gap: 20px; min-width: 0; }
.aurelo-section-anchor { scroll-margin-top: 8px; min-width: 0; }
.aurelo-section { display: grid; grid-template-columns: minmax(200px, 260px) minmax(0, 1fr); gap: 24px; padding: 24px; box-sizing: border-box; }
.aurelo-section-wide { grid-template-columns: minmax(0, 1fr); gap: 18px; }
.aurelo-section-aside { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.aurelo-section-icon { display: inline-grid; place-items: center; width: 40px; height: 40px; margin-bottom: 4px; border-radius: var(--borderRadiusLarge); background: var(--colorBrandBackground2); color: var(--colorBrandForeground1); }
.aurelo-section-body { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.aurelo-section-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
/* One source of a knowledge pool: schedule, state of the latest run and its actions, set apart by a hairline. */
.aurelo-pool-source { display: flex; flex-direction: column; gap: 8px; margin: 12px 0; padding-top: 12px; border-top: 1px solid var(--colorNeutralStroke2); }
.aurelo-addmenu { position: relative; min-width: 0; }
.aurelo-addmenu-trigger { width: 100%; justify-content: flex-start; }
.aurelo-addmenu-backdrop { position: fixed; inset: 0; z-index: 1000; }
.aurelo-addmenu-popup { position: fixed; z-index: 1001; display: flex; flex-direction: column; gap: 2px; max-height: 60vh; overflow-y: auto; padding: 6px; box-sizing: border-box; background: var(--colorNeutralBackground1); border: 1px solid var(--colorNeutralStroke2); border-radius: var(--borderRadiusLarge); box-shadow: var(--shadow16); }
.aurelo-addmenu-item { display: flex; align-items: center; gap: 10px; width: 100%; padding: 6px 8px; font: inherit; color: var(--colorNeutralForeground1); text-align: left; background: transparent; border: none; border-radius: var(--borderRadiusMedium); cursor: pointer; box-sizing: border-box; }
.aurelo-addmenu-item:hover, .aurelo-addmenu-item:focus-visible { background: var(--colorNeutralBackground1Hover); outline: none; }
.aurelo-addmenu-text { display: flex; flex-direction: column; min-width: 0; }
.aurelo-addmenu-name { font-size: 14px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.aurelo-admin-header, .aurelo-page-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.aurelo-admin-title, .aurelo-page-title { font-size: 26px; font-weight: 700; margin-bottom: 4px; }
.aurelo-admin-actions { display: flex; gap: 8px; }
/* Save bar at the bottom left of the administration: sticky in the scrolling page, so it stays in reach everywhere. */
.aurelo-savebar { position: sticky; bottom: 0; z-index: 20; align-self: flex-start; display: flex; align-items: center; gap: 10px; max-width: min(960px, 100%); margin-top: -8px; padding: 8px 10px; box-sizing: border-box; background: var(--colorNeutralBackground1); border: 1px solid var(--colorNeutralStroke2); border-radius: 12px; box-shadow: var(--shadow16); }
.aurelo-savebar-message { display: flex; align-items: center; gap: 6px; min-width: 0; font-size: 13px; color: var(--colorNeutralForeground2); }
.aurelo-savebar-text { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* Help page: the facts of this installation, then the general text. */
.aurelo-help { display: flex; flex-direction: column; gap: 20px; max-width: 860px; }
.aurelo-help-facts { padding: 16px 20px; border-left: 4px solid var(--colorBrandStroke1); }
.aurelo-help-facts ul { margin: 8px 0 0; padding-left: 20px; display: flex; flex-direction: column; gap: 4px; }
.aurelo-help-text h2 { font-size: 18px; margin: 24px 0 8px; }
.aurelo-suggestion-row { display: flex; flex-direction: column; gap: 8px; padding: 12px; border: 1px solid var(--colorNeutralStroke2); border-radius: var(--borderRadiusLarge); background: var(--colorNeutralBackground2); }
.aurelo-subtitle { font-size: 15px; margin-top: 6px; }
.aurelo-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); gap: 12px 20px; align-items: end; }
.aurelo-row { display: flex; align-items: center; gap: 8px; }
.aurelo-template { display: flex; flex-direction: column; gap: 6px; padding: 10px 12px; border: 1px solid var(--colorNeutralStroke2); border-radius: var(--borderRadiusLarge); }

/* Notices for problems: understandable text instead of technical details, always with an option to act */
.aurelo-problem { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; height: 100%; max-width: 520px; margin: 0 auto; padding: 40px 24px; text-align: center; box-sizing: border-box; }
.aurelo-problem-icon { color: var(--colorBrandForeground1); margin-bottom: 6px; }
.aurelo-problem-title { font-size: 22px; font-weight: 700; letter-spacing: -0.2px; }
.aurelo-problem-text { margin: 0; font-size: 15px; line-height: 1.5; color: var(--colorNeutralForeground2); }
.aurelo-problem-status { display: inline-flex; align-items: center; gap: 8px; min-height: 24px; font-size: 13px; color: var(--colorNeutralForeground3); }
.aurelo-problem-address { font-size: 13px; color: var(--colorNeutralForeground3); } .aurelo-problem-address span { font-family: var(--fontFamilyMonospace, monospace); user-select: all; }
.aurelo-problem-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-top: 6px; }
.aurelo-fatal { height: 100vh; }
.aurelo-toasts { position: absolute; top: 12px; right: 16px; left: 16px; z-index: 800; display: flex; flex-direction: column; gap: 8px; max-width: 520px; margin-left: auto; }
.aurelo-empty-answer { font-size: 14px; font-style: italic; color: var(--colorNeutralForeground3); padding: 6px 0; }

/* Document sources: list on the left, form on the right; stacked on narrow screens */
.aurelo-muted { font-size: 12px; color: var(--colorNeutralForeground3); }
.aurelo-sources { display: grid; grid-template-columns: minmax(200px, 260px) minmax(0, 1fr); gap: 20px; align-items: start; }
@media (max-width: 760px) { .aurelo-sources { grid-template-columns: minmax(0, 1fr); } }
.aurelo-source-list { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.aurelo-source-item { display: flex; align-items: center; gap: 10px; width: 100%; padding: 8px 10px; text-align: left; font: inherit; color: var(--colorNeutralForeground1); background: transparent; border: 1px solid transparent; border-radius: var(--borderRadiusLarge); cursor: pointer; box-sizing: border-box; }
.aurelo-source-item:hover { background: var(--colorNeutralBackground1Hover); }
.aurelo-source-item.active { background: var(--colorNeutralBackground1); border-color: var(--colorBrandStroke1); box-shadow: var(--shadow2); }
.aurelo-source-item:focus-visible { outline: 2px solid var(--colorStrokeFocus2); outline-offset: 2px; }
.aurelo-source-item-text { display: flex; flex-direction: column; min-width: 0; }
.aurelo-source-item-name { font-size: 14px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.aurelo-source-editor { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.aurelo-editor-footer { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; padding-top: 12px; border-top: 1px solid var(--colorNeutralStroke2); }
.aurelo-arrow { color: var(--colorNeutralForeground3); }
.aurelo-row > .fluent-text-input, .aurelo-row > * { min-width: 0; }
@media (max-width: 1000px) {
    .aurelo-page-body { grid-template-columns: minmax(0, 1fr); }
    .aurelo-page-nav { position: static; flex-direction: row; flex-wrap: wrap; }
}
@media (max-width: 760px) { .aurelo-section { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 640px) { .aurelo-row { flex-wrap: wrap; } .aurelo-row > span.aurelo-arrow { display: none; } .aurelo-admin { padding: 20px 14px 40px; } .aurelo-section { padding: 16px; } }

/* Home page: document search in the center, AI questions below */
.aurelo-welcome { max-width: 880px; margin: 0 auto; padding: 28px 0 8px; display: flex; flex-direction: column; gap: 14px; }
.aurelo-welcome-title { font-size: 28px; font-weight: 700; letter-spacing: -0.3px; }
.aurelo-welcome-sub { margin: 0 0 6px; color: var(--colorNeutralForeground3); font-size: 15px; }
.aurelo-home-ai { display: flex; flex-direction: column; gap: 10px; margin-top: 12px; padding-top: 16px; border-top: 1px solid var(--colorNeutralStroke2); }
.aurelo-home-ai-label { display: flex; align-items: center; gap: 8px; font-size: 14px; font-weight: 600; color: var(--colorNeutralForeground2); }

/* Search field: same look as the chat input, colors only via tokens */
.aurelo-search-box { display: flex; align-items: center; gap: 10px; padding: 6px 6px 6px 16px; background: var(--colorNeutralBackground1); color: var(--colorNeutralForeground1); border: 1px solid var(--colorNeutralStroke1); border-radius: 20px; box-shadow: var(--shadow8); transition: border-color .15s, box-shadow .15s; }
.aurelo-search-box:focus-within { border-color: var(--colorBrandStroke1); box-shadow: var(--shadow16); }
.aurelo-search-icon { color: var(--colorNeutralForeground3); flex: none; }
.aurelo-search-input { flex: 1; min-width: 0; border: none; outline: none; background: transparent; color: inherit; font: inherit; font-size: 15px; padding: 8px 0; }
.aurelo-search-input::placeholder { color: var(--colorNeutralForeground4); }

/* Sources as selection cards */

/* Color per source kind (palette tokens, light and dark) */
.aurelo-kind-elo { --kind-bg: var(--colorPaletteBlueBackground2); --kind-fg: var(--colorPaletteBlueForeground2); }
.aurelo-kind-mks { --kind-bg: var(--colorPaletteGreenBackground2); --kind-fg: var(--colorPaletteGreenForeground2); }
.aurelo-kind-sql { --kind-bg: var(--colorPalettePurpleBackground2); --kind-fg: var(--colorPalettePurpleForeground2); }
.aurelo-kind-m365 { --kind-bg: var(--colorPaletteTealBackground2); --kind-fg: var(--colorPaletteTealForeground2); }
.aurelo-kind-datev { --kind-bg: var(--colorPaletteMarigoldBackground2); --kind-fg: var(--colorPaletteMarigoldForeground2); }
.aurelo-kind-fileshare { --kind-bg: var(--colorPaletteTealBackground2); --kind-fg: var(--colorPaletteTealForeground2); }
.aurelo-kind-tile { flex: none; display: inline-grid; place-items: center; width: 36px; height: 36px; border-radius: var(--borderRadiusMedium); background: var(--kind-bg); color: var(--kind-fg); }
.aurelo-kind-tile.small { width: 32px; height: 32px; }
.aurelo-kind-dot { flex: none; width: 10px; height: 10px; border-radius: 50%; background: var(--kind-fg); }
.aurelo-chip { display: inline-block; max-width: 100%; box-sizing: border-box; padding: 1px 8px; border-radius: 999px; font-size: 12px; font-weight: 600; background: var(--kind-bg); color: var(--kind-fg); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; vertical-align: middle; }

/* Hit list */
.aurelo-results { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.aurelo-results-count { font-size: 13px; color: var(--colorNeutralForeground3); }
.aurelo-empty { padding: 16px; text-align: center; color: var(--colorNeutralForeground3); font-size: 14px; }
.aurelo-hit { display: flex; align-items: center; gap: 12px; padding: 10px 12px; min-width: 0; background: var(--colorNeutralBackground1); border: 1px solid var(--colorNeutralStroke2); border-radius: var(--borderRadiusLarge); }
.aurelo-hit:hover { border-color: var(--colorNeutralStroke1Hover); }
.aurelo-hit-text { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.aurelo-hit-title { font-weight: 600; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.aurelo-hit-meta { display: flex; align-items: center; gap: 8px; min-width: 0; font-size: 12px; color: var(--colorNeutralForeground3); }
.aurelo-hit-meta .aurelo-chip { flex: 0 1 auto; min-width: 0; }
.aurelo-hit-location { min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }



@media (max-width: 640px) {
    .aurelo-search-box { padding-left: 12px; }
    .aurelo-hit { flex-wrap: wrap; }
    .aurelo-welcome-title { font-size: 22px; }
}

/* Autofill would otherwise light up the fields; the colors stay in the design. */
.aurelo-search-input:-webkit-autofill, .aurelo-textarea:-webkit-autofill {
    -webkit-box-shadow: 0 0 0 1000px var(--colorNeutralBackground1) inset;
    -webkit-text-fill-color: var(--colorNeutralForeground1);
}

/* Top bar: brand, main navigation, global search, account */
.aurelo-shell { display: flex; flex-direction: column; height: 100%; min-width: 0; }
/* The bar carries the brand navy of plenticon.com in light and dark mode. Fluent tokens are overridden inside it, so
   icon buttons and the avatar stay readable on the dark background. */
.aurelo-topbar { --aurelo-navy: #1d2545; --aurelo-sky: #a1c6e3;
    --colorNeutralForeground1: #ffffff; --colorNeutralForeground2: rgba(255, 255, 255, .78); --colorNeutralForeground4: rgba(255, 255, 255, .6);
    --colorNeutralForeground1Hover: #ffffff; --colorNeutralForeground2Hover: #ffffff; --colorNeutralForeground2Pressed: #ffffff;
    --colorSubtleBackgroundHover: rgba(255, 255, 255, .12); --colorSubtleBackgroundPressed: rgba(255, 255, 255, .18);
    display: flex; align-items: center; gap: 16px; height: 52px; flex: none; padding: 0 14px; box-sizing: border-box;
    background: var(--aurelo-navy); color: #ffffff; border-bottom: 3px solid var(--aurelo-sky); }
.aurelo-brand { display: flex; align-items: center; gap: 10px; color: inherit; text-decoration: none; flex: none; }
.aurelo-brand-logo { display: block; border-radius: 6px; box-shadow: 0 0 0 1px rgba(255, 255, 255, .35); }
.aurelo-tabs { display: flex; gap: 2px; flex: none; }
.aurelo-tab { padding: 6px 12px; font-size: 14px; color: rgba(255, 255, 255, .78); text-decoration: none; border-radius: var(--borderRadiusMedium); white-space: nowrap; }
.aurelo-tab:hover { background: rgba(255, 255, 255, .1); color: #ffffff; }
.aurelo-tab.active { background: rgba(255, 255, 255, .14); color: #ffffff; font-weight: 600; box-shadow: inset 0 -2px 0 var(--aurelo-sky); }
.aurelo-tab:focus-visible, .aurelo-avatar-button:focus-visible, .aurelo-filter-chip:focus-visible, .aurelo-segment:focus-visible, .aurelo-tile:focus-visible, .aurelo-home-row:focus-visible { outline: 2px solid var(--colorStrokeFocus2); outline-offset: 2px; }
.aurelo-global { flex: 1; max-width: 480px; min-width: 0; margin: 0 auto; display: flex; align-items: center; gap: 8px; height: 34px; padding: 0 12px; box-sizing: border-box; background: rgba(255, 255, 255, .1); color: #ffffff; border: 1px solid rgba(255, 255, 255, .25); border-radius: 999px; transition: border-color .15s, background .15s; }
.aurelo-global:focus-within { border-color: var(--aurelo-sky); background: rgba(255, 255, 255, .16); }
.aurelo-global-input { flex: 1; min-width: 0; border: none; outline: none; background: transparent; color: inherit; font: inherit; font-size: 14px; }
.aurelo-global-input::placeholder { color: var(--colorNeutralForeground4); }
.aurelo-topbar-end { display: flex; align-items: center; gap: 6px; flex: none; }
.aurelo-avatar-button { display: inline-flex; padding: 0; border: none; background: transparent; border-radius: 50%; cursor: pointer; }

/* Content below the top bar */
.aurelo-content { position: relative; flex: 1; min-height: 0; min-width: 0; overflow: hidden; }

/* Chat with history on the left */
.aurelo-chat-layout { display: grid; grid-template-columns: var(--aurelo-history-width, 260px) 6px minmax(0, 1fr); height: 100%; min-height: 0; }
.aurelo-history { display: flex; flex-direction: column; gap: 12px; min-height: 0; padding: 14px 10px; box-sizing: border-box; background: var(--colorNeutralBackground2); border-right: 1px solid var(--colorNeutralStroke2); }
.aurelo-history .aurelo-conversations { flex: 1; min-height: 0; }

/* Home page */
.aurelo-home { height: 100%; overflow-y: auto; box-sizing: border-box; padding: 28px 24px 48px; }
.aurelo-home-inner { max-width: 920px; margin: 0 auto; display: flex; flex-direction: column; gap: 20px; }
.aurelo-home-search { margin-top: 6px; }
.aurelo-home-ask { border-color: var(--colorBrandStroke1); }
.aurelo-home-model { margin: 8px 0 0 18px; }
.aurelo-tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr)); gap: 12px; }
.aurelo-tile { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; padding: 18px; text-align: left; font: inherit; color: var(--colorNeutralForeground1); background: var(--colorNeutralBackground1); border: 1px solid var(--colorNeutralStroke2); border-radius: var(--borderRadiusLarge); cursor: pointer; transition: border-color .15s, box-shadow .15s; }
.aurelo-tile:hover { border-color: var(--colorBrandStroke1); box-shadow: var(--shadow4); }
.aurelo-tile-title { font-size: 15px; font-weight: 600; }
.aurelo-home-columns { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 320px), 1fr)); gap: 24px; }
.aurelo-section-title { font-size: 14px; font-weight: 600; margin: 0 0 8px; }
.aurelo-home-list { display: flex; flex-direction: column; gap: 2px; }
.aurelo-home-row { display: flex; align-items: center; gap: 10px; min-width: 0; padding: 9px 10px; font: inherit; color: var(--colorNeutralForeground1); text-align: left; background: transparent; border: none; border-radius: var(--borderRadiusMedium); }
button.aurelo-home-row { cursor: pointer; }
button.aurelo-home-row:hover { background: var(--colorNeutralBackground1Hover); }
.aurelo-home-row-title { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* Documents: filters | hits | preview */
.aurelo-docs { display: grid; grid-template-columns: var(--aurelo-filter-width, 220px) 6px minmax(300px, 1fr) 6px var(--aurelo-preview-width, minmax(360px, 1.15fr)); height: 100%; min-height: 0; overflow: hidden; }
.aurelo-docs-filters { display: flex; flex-direction: column; gap: 18px; min-height: 0; overflow-y: auto; padding: 18px 14px; box-sizing: border-box; background: var(--colorNeutralBackground2); border-right: 1px solid var(--colorNeutralStroke2); }
.aurelo-filter-group { display: flex; flex-direction: column; align-items: flex-start; gap: 6px; min-width: 0; }
.aurelo-filter-group .aurelo-group-label { padding-top: 0; }
.aurelo-filter-chip { display: inline-flex; align-items: center; gap: 8px; max-width: 100%; padding: 5px 10px; font: inherit; font-size: 13px; color: var(--colorNeutralForeground1); background: var(--colorNeutralBackground1); border: 1px solid var(--colorNeutralStroke2); border-radius: 999px; cursor: pointer; }
.aurelo-filter-chip:hover:not(:disabled) { border-color: var(--colorNeutralStroke1Hover); }
.aurelo-filter-chip.on { color: var(--colorBrandForeground1); background: var(--colorBrandBackground2); border-color: var(--colorBrandStroke1); }
.aurelo-filter-chip-text { min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.aurelo-docs-results { display: flex; flex-direction: column; gap: 12px; min-width: 0; min-height: 0; overflow-y: auto; padding: 18px; box-sizing: border-box; border-right: 1px solid var(--colorNeutralStroke2); }
/* Message bars wrap long text (for example the source error list) and keep their full height. A fixed height
   and clipping cut the text off in narrow columns. Shared for all pages. The layout (icon left, text, dismiss
   right) comes from the component's own grid, so display must not be overridden here: a block display stacks
   the icon and the dismiss button above and below the text. */
fluent-message-bar { flex: none; min-width: 0; max-width: 100%; box-sizing: border-box; overflow: visible; white-space: normal; overflow-wrap: anywhere; }
.aurelo-docs-preview { display: flex; flex-direction: column; min-width: 0; min-height: 0; padding: 18px; box-sizing: border-box; background: var(--colorNeutralBackground2); }
.aurelo-hit-button { width: 100%; font: inherit; color: var(--colorNeutralForeground1); text-align: left; cursor: pointer; box-sizing: border-box; }
.aurelo-hit-button:hover { border-color: var(--colorNeutralStroke1Hover); }
.aurelo-hit-button.selected { border-color: var(--colorBrandStroke1); box-shadow: 0 0 0 1px var(--colorBrandStroke1) inset; }

/* Preview */
.aurelo-preview { display: flex; flex-direction: column; gap: 14px; height: 100%; min-height: 0; }
.aurelo-preview-empty { display: grid; flex: 1; place-items: center; padding: 40px; text-align: center; color: var(--colorNeutralForeground3); }
.aurelo-preview-head { display: flex; align-items: center; gap: 12px; min-width: 0; }
.aurelo-preview-title-block { display: flex; flex-direction: column; min-width: 0; }
.aurelo-preview-title { font-size: 16px; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.aurelo-preview-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.aurelo-preview-body { flex: 1; min-height: 240px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; overflow: hidden; padding: 12px; box-sizing: border-box; background: var(--colorNeutralBackground1); border: 1px solid var(--colorNeutralStroke2); border-radius: var(--borderRadiusLarge); }
.aurelo-preview-body .aurelo-empty { padding: 0; }
.aurelo-preview-frame { width: 100%; height: 100%; min-height: 400px; border: none; background: #fff; }
.aurelo-preview-image { max-width: 100%; max-height: 100%; object-fit: contain; }
/* E-mail: header as label/value grid above the body; the body fills the rest of the preview. */
.aurelo-mail { flex: 1; min-height: 0; width: 100%; display: flex; flex-direction: column; gap: 10px; }
.aurelo-mail-head { display: grid; grid-template-columns: max-content 1fr; gap: 4px 14px; margin: 0; padding: 4px 6px 10px; border-bottom: 1px solid var(--colorNeutralStroke2); font-size: 13px; }
.aurelo-mail-head dt { color: var(--colorNeutralForeground3); }
.aurelo-mail-head dd { margin: 0; min-width: 0; overflow-wrap: anywhere; color: var(--colorNeutralForeground1); }
.aurelo-mail-subject { font-weight: 600; }
.aurelo-mail-frame { flex: 1; min-height: 300px; border-radius: var(--borderRadiusMedium); }
.aurelo-mail .aurelo-preview-text { font-family: inherit; }
/* Attachments of an e-mail as chips that open the attachment in the preview. */
.aurelo-mail-attachments { display: flex; flex-wrap: wrap; gap: 6px; }
.aurelo-mail-attachment { display: inline-flex; align-items: center; gap: 6px; max-width: 100%; padding: 3px 10px; font: inherit; font-size: 12px; color: var(--colorNeutralForeground1); background: var(--colorNeutralBackground2); border: 1px solid var(--colorNeutralStroke2); border-radius: var(--borderRadiusCircular); cursor: pointer; }
.aurelo-mail-attachment span:first-of-type { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.aurelo-mail-attachment:hover, .aurelo-mail-attachment:focus-visible { background: var(--colorNeutralBackground2Hover); border-color: var(--colorNeutralStroke1Hover); outline: none; }
/* Bar above an opened attachment: back to the e-mail, its name, download. */
.aurelo-preview-attachment-bar { display: flex; align-items: center; gap: 8px; min-width: 0; }
.aurelo-preview-attachment-name { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-weight: 600; }
.aurelo-preview-switch { align-self: flex-start; }
.aurelo-preview-text { flex: 1; min-height: 0; width: 100%; box-sizing: border-box; margin: 0; padding: 12px 14px; overflow: auto; font-family: var(--fontFamilyMonospace); font-size: 13px; line-height: 1.5; white-space: pre-wrap; word-break: break-word; color: var(--colorNeutralForeground1); }

/* Source selection as dropdown, in the filter column */
.aurelo-filter-group-wide { width: 100%; }
.aurelo-filter-group-wide .fluent-select { width: 100%; }
.aurelo-source-chips { display: flex; flex-wrap: wrap; gap: 6px; }

/* Settings */
/* Account and settings page: same layout as the administration page (section list, cards with a description on the
   left and the settings on the right). */
.aurelo-setting-value { font-size: 14px; color: var(--colorNeutralForeground2); text-align: right; overflow-wrap: anywhere; }
.aurelo-setting-row { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px 16px; min-width: 0; }
.aurelo-setting-list { display: flex; flex-direction: column; gap: 12px; }
.aurelo-setting-list .aurelo-setting-row { padding-bottom: 12px; border-bottom: 1px solid var(--colorNeutralStroke2); }
.aurelo-setting-list .aurelo-setting-row:last-child { padding-bottom: 0; border-bottom: none; }
.aurelo-setting-text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.aurelo-setting-label { font-size: 14px; font-weight: 600; overflow-wrap: anywhere; }
.aurelo-setting-account { display: flex; align-items: center; gap: 12px; min-width: 0; }
.aurelo-segmented { display: inline-flex; flex: none; border: 1px solid var(--colorNeutralStroke1); border-radius: var(--borderRadiusMedium); overflow: hidden; }
.aurelo-segment { padding: 6px 14px; font: inherit; font-size: 14px; color: var(--colorNeutralForeground1); background: var(--colorNeutralBackground1); border: none; cursor: pointer; }
.aurelo-segment:hover { background: var(--colorNeutralBackground1Hover); }
.aurelo-segment + .aurelo-segment { border-left: 1px solid var(--colorNeutralStroke2); }
.aurelo-segment.on { color: var(--colorBrandForeground1); background: var(--colorBrandBackground2); font-weight: 600; }
.aurelo-status-ok { font-size: 13px; color: var(--colorPaletteGreenForeground1); }
.aurelo-status-warn { font-size: 13px; color: var(--colorPaletteMarigoldForeground1); }
.aurelo-mono { font-family: var(--fontFamilyMonospace); font-size: 13px; user-select: all; overflow-wrap: anywhere; }

@media (max-width: 1100px) {
    .aurelo-docs { grid-template-columns: var(--aurelo-filter-width, 200px) 6px minmax(280px, 1fr) 6px var(--aurelo-preview-width, minmax(300px, 1fr)); }
}
@media (max-width: 900px) {
    .aurelo-docs { grid-template-columns: minmax(0, 1fr); overflow-y: auto; }
    .aurelo-docs-filters, .aurelo-docs-results { border-right: none; overflow-y: visible; }
    .aurelo-splitter { display: none; }
    .aurelo-docs-preview { min-height: 460px; }
    .aurelo-chat-layout { grid-template-columns: minmax(0, 1fr); }
    .aurelo-history { display: none; }
}
@media (max-width: 640px) {
    .aurelo-global { display: none; }
    .aurelo-tab { padding: 6px 8px; }
    .aurelo-brand-name { display: none; }
    .aurelo-home, .aurelo-settings { padding: 20px 14px 40px; }
}

/* Drag handle between hit list and preview */
.aurelo-splitter { position: relative; cursor: col-resize; touch-action: none; background: var(--colorNeutralStroke2); transition: background .15s; }
.aurelo-splitter::after { content: ""; position: absolute; top: 0; bottom: 0; left: -4px; right: -4px; }
.aurelo-splitter:hover, .aurelo-splitter.dragging { background: var(--colorBrandStroke1); }
.aurelo-source-column { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.aurelo-section-avatar { width: 48px; height: 48px; font-size: 18px; }

/* Sources under an answer, and the document preview that opens over the chat. */
.aurelo-sources { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-top: 8px; }
.aurelo-sources-label { font-size: 12px; color: var(--colorNeutralForeground3); }
.aurelo-source-reasons { display: flex; flex-direction: column; gap: 10px; margin-top: 8px; }
.aurelo-source-reason { display: flex; flex-direction: column; gap: 4px; padding: 10px 12px; border: 1px solid var(--colorNeutralStroke2); border-radius: var(--borderRadiusLarge); background: var(--colorNeutralBackground2); }
.aurelo-source-reason blockquote { margin: 4px 0 0; padding-left: 10px; border-left: 3px solid var(--colorBrandStroke1); font-size: 13px; color: var(--colorNeutralForeground2); white-space: pre-wrap; overflow-wrap: anywhere; max-height: 200px; overflow: auto; }
.aurelo-protocol { margin-top: 6px; }

/* Search protocol (admins) and the insight into a knowledge pool. */
.aurelo-retrieval { display: flex; flex-direction: column; gap: 8px; margin-top: 8px; }
.aurelo-retrieval-item { display: flex; flex-direction: column; gap: 4px; padding: 8px 12px; border: 1px solid var(--colorNeutralStroke2); border-radius: var(--borderRadiusLarge); background: var(--colorNeutralBackground1); }
.aurelo-retrieval-item.used { border-color: var(--colorBrandStroke1); }
.aurelo-retrieval-item.dim { opacity: .65; }
.aurelo-retrieval-head { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; min-width: 0; }
.aurelo-retrieval-head strong { overflow-wrap: anywhere; }
.aurelo-retrieval-metrics { display: flex; flex-wrap: wrap; gap: 4px 16px; font-size: 12px; color: var(--colorNeutralForeground3); overflow-wrap: anywhere; }
.aurelo-retrieval-passage summary { font-size: 12px; color: var(--colorBrandForeground1); cursor: pointer; }
.aurelo-retrieval-passage pre { margin: 6px 0 0; padding: 8px; font: inherit; font-size: 13px; white-space: pre-wrap; overflow-wrap: anywhere; max-height: 260px; overflow: auto; background: var(--colorNeutralBackground2); border-radius: var(--borderRadiusMedium); }
.aurelo-badge { display: inline-block; padding: 1px 8px; font-size: 11px; line-height: 18px; border-radius: 9px; color: var(--colorBrandForeground1); background: var(--colorBrandBackground2); }
.aurelo-badge-strong { color: var(--colorNeutralForegroundOnBrand); background: var(--colorBrandBackground); }
.aurelo-badge-muted { color: var(--colorNeutralForeground3); background: var(--colorNeutralBackground3); }
.aurelo-badge-warn { color: var(--colorPaletteDarkOrangeForeground1); background: var(--colorPaletteDarkOrangeBackground1); }
.aurelo-pool-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.aurelo-insights { display: flex; flex-direction: column; gap: 10px; margin: 12px 0; padding: 12px; border: 1px solid var(--colorNeutralStroke2); border-radius: var(--borderRadiusLarge); background: var(--colorNeutralBackground2); }
.aurelo-insights-row { display: flex; flex-direction: column; gap: 2px; padding: 6px 0; border-bottom: 1px solid var(--colorNeutralStroke3); min-width: 0; overflow-wrap: anywhere; }
.aurelo-insights-detail { display: flex; flex-direction: column; gap: 6px; margin-top: 6px; padding-left: 12px; border-left: 3px solid var(--colorBrandStroke1); font-size: 13px; }
.aurelo-link-button { padding: 0; font: inherit; font-weight: 600; text-align: left; color: var(--colorBrandForegroundLink); background: none; border: none; cursor: pointer; overflow-wrap: anywhere; }
.aurelo-link-button:hover { text-decoration: underline; }
.aurelo-link-button:focus-visible { outline: 2px solid var(--colorStrokeFocus2); outline-offset: 2px; }
.aurelo-preview-overlay { position: fixed; top: 0; right: 0; bottom: 0; width: min(640px, 60vw); z-index: 1000; display: flex; flex-direction: column; background: var(--colorNeutralBackground1); box-shadow: var(--shadow16); }
.aurelo-preview-bar { display: flex; justify-content: flex-end; padding: 8px; }
