@font-face {
  font-family: "Caprasimo";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/berean/assets/fonts/caprasimo-400.ttf") format("truetype");
}

@font-face {
  font-family: "Figtree";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/berean/assets/fonts/figtree-400.ttf") format("truetype");
}

@font-face {
  font-family: "Figtree";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("/berean/assets/fonts/figtree-600.ttf") format("truetype");
}

@font-face {
  font-family: "Figtree";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("/berean/assets/fonts/figtree-700.ttf") format("truetype");
}

:root {
  --color-bg: #f5ead8;
  --color-text: #201e1d;
  --color-accent: #c67139;
  --color-accent-100: #fff2eb;
  --color-accent-600: #b2622d;
  --color-accent-700: #8c491a;
  --color-accent-2: #7a8a5e;
  --color-accent-2-100: #f0fae1;
  --color-accent-2-800: #3d472b;
  --color-neutral-100: #f9f4ed;
  --color-neutral-200: #eee7db;
  --color-neutral-300: #dcd3c4;
  --color-neutral-700: #645c50;
  --font-heading: "Caprasimo", system-ui, sans-serif;
  --font-body: "Figtree", system-ui, sans-serif;
  --shadow-sm: 0 1px 2px color-mix(in srgb, #2e2b25 14%, transparent);
  --shadow-md: 0 3px 10px color-mix(in srgb, #2e2b25 16%, transparent);
  --shadow-lg: 0 12px 32px color-mix(in srgb, #2e2b25 22%, transparent);
}

html.br-dark-page {
  color-scheme: dark;
  background: #231c15;
}

html.br-dark-page body { background: #231c15; }

*, *::before, *::after { box-sizing: border-box; }

html, body, #app { width: 100%; height: 100%; margin: 0; }

body {
  overflow: hidden;
  background: var(--color-bg);
  color: var(--color-text);
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.55;
  font-weight: 400;
}

button, input, textarea { font: inherit; }
button { color: inherit; }
button:focus-visible, input:focus-visible, textarea:focus-visible, a:focus-visible, summary:focus-visible {
  outline: 2px solid var(--acc);
  outline-offset: 2px;
}

button, a { -webkit-tap-highlight-color: transparent; }
.br-flex-spacer { flex: 1; }
.br-scroll { scrollbar-width: thin; scrollbar-color: var(--line) transparent; }
.br-scroll::-webkit-scrollbar { width: 10px; }
.br-scroll::-webkit-scrollbar-thumb { background: var(--line); border: 3px solid transparent; border-radius: 99px; background-clip: content-box; }
.br-scroll::-webkit-scrollbar-track { background: transparent; }

@keyframes br-dot { 0%, 80%, 100% { opacity: .25; transform: translateY(0); } 40% { opacity: 1; transform: translateY(-3px); } }
@keyframes br-pop { from { opacity: 0; transform: translateY(6px) scale(.97); } to { opacity: 1; transform: none; } }
@keyframes br-rise { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
@keyframes br-bob { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-4px); } }
@keyframes br-pulse { 0%, 100% { opacity: .6; } 50% { opacity: 1; } }
@keyframes br-app-in { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
@keyframes br-spin { to { transform: rotate(360deg); } }
@keyframes br-theme-old-soften {
  from { opacity: 1; }
  40% { opacity: .97; }
  to { opacity: .82; }
}

html::view-transition-group(root) { animation: none; }
html::view-transition-image-pair(root) { isolation: auto; }
html::view-transition-old(root),
html::view-transition-new(root) {
  display: block;
  animation: none;
  mix-blend-mode: normal;
}
html::view-transition-old(root) {
  z-index: 1;
  animation: br-theme-old-soften .68s cubic-bezier(.45, 0, .55, 1) both;
}
html::view-transition-new(root) {
  z-index: 2;
  will-change: clip-path;
}

.br-root {
  --bg: var(--color-bg);
  --sf: var(--color-neutral-100);
  --sf2: var(--color-neutral-200);
  --line: var(--color-neutral-300);
  --tx: var(--color-text);
  --tx2: var(--color-neutral-700);
  --acc: var(--color-accent);
  --acc-strong: var(--color-accent-600);
  --acc-soft: var(--color-accent-100);
  --acc-deep: var(--color-accent-700);
  --sage: var(--color-accent-2);
  --sage-soft: var(--color-accent-2-100);
  --sage-deep: var(--color-accent-2-800);
  --on-acc: #fff7ec;
  position: fixed;
  inset: 0;
  display: flex;
  overflow: hidden;
  background: var(--bg);
  color: var(--tx);
  font-family: var(--font-body);
  transition: background .35s;
}

.br-root.dk {
  --bg: #231c15;
  --sf: #2d251c;
  --sf2: #382e23;
  --line: #483b2c;
  --tx: #f3e8d5;
  --tx2: #bfae94;
  --acc: #d98d55;
  --acc-strong: #e39d67;
  --acc-soft: #3b2c1e;
  --acc-deep: #efc9a4;
  --sage: #93a375;
  --sage-soft: #2c3122;
  --sage-deep: #cbd6b0;
  --on-acc: #231c15;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, .3);
  --shadow-md: 0 4px 14px rgba(0, 0, 0, .35);
  --shadow-lg: 0 10px 30px rgba(0, 0, 0, .4);
}

.br-root.is-intro > .br-sidebar,
.br-root.is-intro > .br-main { opacity: 0; }
.br-root.is-entering > .br-sidebar,
.br-root.is-entering > .br-main { animation: br-app-in .72s cubic-bezier(.4, 0, .2, 1) both; }

.br-snail-image { display: block; object-fit: contain; }
.br-root.dk .br-snail-image { filter: brightness(1.35) saturate(.75); }

.br-icon-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  flex: 0 0 auto;
  padding: 0;
  border: 0;
  border-radius: 12px;
  background: transparent;
  color: var(--tx2);
  cursor: pointer;
}

.br-icon-button:hover { background: var(--sf2); color: var(--tx); }

.br-sidebar {
  width: 288px;
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border-right: 1.5px solid var(--line);
  background: var(--bg);
  transition: width .28s cubic-bezier(.4, 0, .2, 1), transform .28s cubic-bezier(.4, 0, .2, 1);
  z-index: 20;
}

.br-sidebar.is-collapsed { width: 74px; }
.br-sidebar.is-collapsed .br-sidebar-label,
.br-sidebar.is-collapsed .br-brand { display: none; }
.br-sidebar.is-collapsed .br-conversation-nav { visibility: hidden; opacity: 0; pointer-events: none; transition: opacity .12s ease, visibility 0s linear .12s; }
.br-sidebar.is-collapsed .br-primary-nav { padding-inline: 16px; }
.br-sidebar.is-collapsed .br-sidebar-action { width: 42px; height: 42px; justify-content: center; padding: 0; }
.br-sidebar.is-collapsed .br-account { border-top: 0; justify-content: center; padding-inline: 12px; }

.br-sidebar-top { display: flex; align-items: center; gap: 8px; padding: 14px 16px 6px; }
.br-brand { display: flex; align-items: center; gap: 9px; min-width: 0; }
.br-brand span { font-family: var(--font-heading); font-size: 19px; letter-spacing: .5px; white-space: nowrap; }
.br-primary-nav { display: grid; gap: 2px; padding: 10px 16px 5px; }
.br-sidebar-action {
  width: 100%;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 9px 10px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: var(--tx);
  font-size: 14px;
  font-weight: 500;
  text-align: left;
  white-space: nowrap;
  cursor: pointer;
}
.br-sidebar-action > svg { flex: 0 0 auto; color: var(--tx2); }
.br-sidebar-action:hover, .br-sidebar-action.is-active { background: var(--sf2); }
.br-sidebar-action.is-active { color: var(--acc-deep); }

.br-conversation-nav { flex: 1; min-height: 0; overflow-y: auto; padding: 4px 16px 10px; opacity: 1; transition: opacity .16s ease .1s, visibility 0s linear 0s; }
.br-conversation-group { margin-top: 14px; }
.br-group-label { margin: 0; padding: 0 12px 6px; color: var(--tx2); font: 700 11.5px/1.5 var(--font-body); letter-spacing: 1.2px; }
.br-conversation-button {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  padding: 9px 68px 9px 12px;
  overflow: hidden;
  border: 0;
  border-radius: 12px;
  background: transparent;
  color: var(--tx);
  font-size: 13.8px;
  text-align: left;
  text-overflow: ellipsis;
  white-space: nowrap;
  cursor: pointer;
}
.br-conversation-row { position: relative; }
.br-conversation-title { min-width: 0; flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.br-conversation-unread { position: absolute; top: calc(50% - 3.5px); right: 17px; z-index: 1; width: 7px; height: 7px; border-radius: 50%; background: var(--acc); pointer-events: none; transition: opacity .1s ease; }
.br-conversation-live { position: absolute; top: calc(50% - 8px); right: 9px; width: 16px; height: 16px; display: block; overflow: hidden; border: 0; border-radius: 50%; background: conic-gradient(var(--sage-deep) 0 70%, color-mix(in srgb, var(--tx2) 24%, transparent) 70% 100%); color: transparent; font-size: 0; pointer-events: none; -webkit-mask: radial-gradient(farthest-side, transparent calc(100% - 2px), #000 0); mask: radial-gradient(farthest-side, transparent calc(100% - 2px), #000 0); animation: br-spin 2.2s linear infinite; }
.br-conversation-pin, .br-conversation-archive { position: absolute; top: 50%; z-index: 2; width: 27px; height: 27px; display: grid; place-items: center; padding: 0; border: 0; border-radius: 0; background: transparent; color: var(--tx2); opacity: 0; transform: translateY(-50%) scale(.88); cursor: pointer; transition: opacity .14s ease, transform .18s ease, color .14s ease; }
.br-conversation-pin { right: 35px; }
.br-conversation-archive { right: 7px; }
.br-conversation-row:hover .br-conversation-pin, .br-conversation-row:hover .br-conversation-archive:not(:disabled), .br-conversation-pin:focus-visible, .br-conversation-archive:focus-visible { opacity: 1; transform: translateY(-50%) scale(1); }
.br-conversation-row:hover .br-conversation-unread { opacity: 0; }
.br-conversation-pin[aria-pressed="true"] { color: var(--acc-deep); }
.br-conversation-pin[aria-pressed="true"] svg { fill: currentColor; }
.br-conversation-pin:hover,
.br-conversation-archive:hover { color: var(--acc-deep); }
.br-conversation-pin:disabled,
.br-conversation-archive:disabled { display: none; }
.br-conversation-button:disabled { cursor: default; }
.br-conversation-button:hover { background: var(--sf2); }
.br-conversation-button.is-active { background: var(--sf2); color: var(--tx); font-weight: 600; box-shadow: none; }
.br-conversation-menu-layer { position: fixed; inset: 0; z-index: 85; }
.br-conversation-menu { position: fixed; width: 224px; padding: 7px; border: 1px solid color-mix(in srgb, var(--line) 82%, transparent); border-radius: 17px; background: color-mix(in srgb, var(--sf) 96%, transparent); box-shadow: var(--shadow-lg); backdrop-filter: blur(14px); animation: br-pop .14s ease both; }
.br-conversation-menu-item { width: 100%; min-height: 42px; display: grid; grid-template-columns: 22px minmax(0, 1fr) auto; align-items: center; gap: 10px; padding: 8px 10px; border: 0; border-radius: 11px; background: transparent; color: var(--tx); text-align: left; cursor: pointer; }
.br-conversation-menu-item:hover, .br-conversation-menu-item:focus-visible { background: var(--sf2); }
.br-conversation-menu-item:focus-visible { outline: 0; }
.br-conversation-menu-item > svg { color: var(--tx2); }
.br-conversation-menu-item.is-archive { color: var(--acc-deep); }
.br-conversation-menu-item.is-archive > svg { color: currentColor; }
.br-conversation-menu-item:disabled { color: var(--tx2); cursor: not-allowed; opacity: .45; }
.br-conversation-menu-label { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.br-conversation-menu-item kbd { color: var(--tx2); font: 500 12px/1 var(--font-body); }
.br-conversation-menu-separator { height: 1px; margin: 5px 9px; background: var(--line); }
.br-conversation-rename-layer { position: fixed; inset: 0; z-index: 86; display: grid; place-items: center; padding: 16px; }
.br-conversation-rename-backdrop { position: absolute; inset: 0; background: color-mix(in srgb, var(--tx) 18%, transparent); backdrop-filter: blur(2px); }
.br-conversation-rename-dialog { position: relative; width: min(410px, calc(100vw - 32px)); padding: 22px; border: 1px solid var(--line); border-radius: 20px; background: var(--sf); box-shadow: var(--shadow-lg); animation: br-pop .18s ease both; }
.br-conversation-rename-dialog h2 { margin: 0 0 16px; font-family: var(--font-heading); font-size: 19px; font-weight: 400; }
.br-conversation-rename-form { display: grid; gap: 10px; }
.br-conversation-rename-input { width: 100%; height: 42px; padding: 0 12px; border: 1.5px solid var(--line); border-radius: 11px; outline: 0; background: var(--bg); color: var(--tx); }
.br-conversation-rename-input:focus { border-color: var(--acc); box-shadow: 0 0 0 3px color-mix(in srgb, var(--acc) 14%, transparent); }
.br-conversation-rename-error { color: var(--acc-deep); font-size: 12px; }
.br-conversation-rename-actions { display: flex; justify-content: flex-end; gap: 8px; margin-top: 4px; }
.br-conversation-rename-cancel, .br-conversation-rename-save { min-width: 72px; height: 36px; padding: 0 14px; border-radius: 10px; cursor: pointer; }
.br-conversation-rename-cancel { border: 1px solid var(--line); background: transparent; color: var(--tx); }
.br-conversation-rename-save { border: 0; background: var(--acc); color: var(--on-acc); }
.br-conversation-rename-cancel:disabled, .br-conversation-rename-save:disabled { cursor: not-allowed; opacity: .5; }
.br-sidebar-status { display: flex; flex-direction: column; align-items: flex-start; gap: 10px; margin: 24px 12px; color: var(--tx2); font-size: 13px; }
.br-sidebar-error { color: var(--acc-deep); }
.br-text-button { display: inline-flex; align-items: center; gap: 6px; padding: 4px 0; border: 0; background: transparent; color: inherit; cursor: pointer; }
.br-truncated { margin: 16px 12px; color: var(--tx2); font-size: 11.5px; }

.br-account { display: flex; align-items: center; gap: 10px; padding: 12px 16px; border-top: 1.5px solid var(--line); }
.br-avatar { width: 34px; height: 34px; flex: 0 0 auto; display: grid; place-items: center; border-radius: 50%; background: var(--sage-soft); color: var(--sage-deep); font-size: 14px; font-weight: 700; }
.br-account-copy { min-width: 0; }
.br-account-name { overflow: hidden; font-size: 13.5px; font-weight: 600; text-overflow: ellipsis; white-space: nowrap; }
.br-account-role { color: var(--tx2); font-size: 11.5px; }

.br-main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.br-header { height: 54px; flex: 0 0 auto; display: flex; align-items: center; gap: 10px; padding: 0 18px; }
.br-header-title { flex: 1; min-width: 0; overflow: hidden; color: var(--tx2); font-size: 14px; text-overflow: ellipsis; white-space: nowrap; }

.br-all-chats { flex: 1; min-height: 0; display: flex; flex-direction: column; width: min(1040px, 100%); margin: 0 auto; padding: 34px 34px 0; }
.br-all-chats-head { display: flex; align-items: flex-end; gap: 12px; padding: 0 2px 22px; }
.br-all-chats-head > div:first-child { min-width: 0; flex: 1; }
.br-all-chats h1 { margin: 0; font: 600 30px/1.2 var(--font-display); letter-spacing: -.02em; }
.br-all-chats p { margin: 6px 0 0; color: var(--tx2); font-size: 12px; }
.br-all-search { width: min(260px, 32vw); height: 38px; display: flex; align-items: center; gap: 8px; padding: 0 11px; border: 1px solid var(--line); border-radius: 11px; background: var(--sf2); color: var(--tx2); }
.br-all-search input { min-width: 0; flex: 1; border: 0; outline: 0; background: transparent; color: var(--tx); font: inherit; }
.br-all-new { height: 38px; display: inline-flex; align-items: center; gap: 7px; padding: 0 14px; border: 0; border-radius: 11px; background: var(--tx); color: var(--bg); font-weight: 600; cursor: pointer; }
.br-all-list { flex: 1; min-height: 0; overflow-y: auto; border-top: 1px solid var(--line); }
.br-all-row { width: 100%; min-height: 66px; display: flex; align-items: center; gap: 12px; padding: 12px 10px; border: 0; border-bottom: 1px solid var(--line); background: transparent; color: var(--tx); text-align: left; cursor: pointer; }
.br-all-row:hover { background: var(--sf2); }
.br-all-row > svg { flex: 0 0 auto; color: var(--tx2); }
.br-all-row-title { min-width: 0; flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.br-all-unread, .br-search-unread { width: 7px; height: 7px; flex: 0 0 auto; border-radius: 50%; background: var(--acc); }
.br-all-row time { flex: 0 0 auto; color: var(--tx2); font-size: 12px; }
.br-all-pinned { display: inline-flex; align-items: center; gap: 4px; color: var(--acc-deep); font-size: 11px; }
.br-all-empty { padding: 40px 10px; color: var(--tx2); text-align: center; }
.br-all-empty.is-error { color: var(--acc-deep); }
.br-focus-chip, .br-warning-chip, .br-effort-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border-radius: 999px;
  background: var(--sage-soft);
  color: var(--sage-deep);
  font-size: 11.5px;
  font-weight: 700;
  padding: 4px 10px;
}
.br-focus-chip { max-width: 300px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.br-mobile-menu { display: none; }
.br-workspace { flex: 1; min-height: 0; display: flex; flex-direction: column; }

.br-hero-block { display: contents; }
.br-hero-spacer { flex: 5 1 0; min-height: 34px; }
.br-hero-center { display: flex; flex-direction: column; align-items: center; gap: 10px; padding: 0 24px; margin-bottom: 26px; }
.br-hero-center > svg { color: var(--acc-deep); animation: br-bob 4.5s ease-in-out infinite; }
.br-hero-center h1 { max-width: 850px; margin: 0; color: var(--tx); font-family: var(--font-heading); font-size: clamp(26px, 3.4vw, 36px); font-weight: 400; line-height: 1.3; letter-spacing: .3px; text-align: center; text-wrap: pretty; }
.br-hero-bottom { flex: 7 1 0; min-height: 80px; }

.br-timeline-shell { position: relative; flex: 1; min-height: 0; }
.br-timeline { height: 100%; min-height: 0; overflow-y: auto; overflow-anchor: none; }
.br-timeline-content { width: min(760px, 100%); min-height: 100%; margin: 0 auto; padding: 26px 24px 10px; }
.br-history-layer { position: absolute; inset: 0; z-index: 18; pointer-events: none; }
.br-history-rail { position: absolute; top: 50%; left: 12px; display: flex; flex-direction: column; align-items: flex-start; gap: 0; padding: 10px 8px; opacity: .5; transform: translateY(-50%); transition: opacity .18s ease; pointer-events: auto; }
.br-history-rail:hover, .br-history-rail:focus-within { opacity: 1; }
.br-history-bar { width: 28px; height: 14px; display: flex; align-items: center; padding: 0; border: 0; background: transparent; cursor: pointer; }
.br-history-bar:focus-visible { outline: 0; }
.br-history-bar::before { content: ""; width: 11px; height: 2px; border-radius: 99px; background: color-mix(in srgb, var(--acc) 58%, transparent); transform-origin: left center; transition: width .2s cubic-bezier(.2, .8, .2, 1), height .2s cubic-bezier(.2, .8, .2, 1), background .18s ease; }
.br-history-bar.is-current::before { width: 11px; background: var(--acc-deep); }
.br-history-rail:hover .br-history-bar::before,
.br-history-rail:focus-within .br-history-bar::before { background: color-mix(in srgb, var(--acc) 58%, transparent); }
.br-history-rail:hover .br-history-bar:hover::before,
.br-history-rail:focus-within .br-history-bar:focus-visible::before { width: 28px; height: 4px; background: var(--acc-deep); }
.br-history-bar:has(+ .br-history-bar:hover)::before,
.br-history-bar:hover + .br-history-bar::before,
.br-history-bar:has(+ .br-history-bar:focus-visible)::before,
.br-history-bar:focus-visible + .br-history-bar::before { width: 21px; height: 3px; }
.br-history-bar:has(+ .br-history-bar + .br-history-bar:hover)::before,
.br-history-bar:hover + .br-history-bar + .br-history-bar::before,
.br-history-bar:has(+ .br-history-bar + .br-history-bar:focus-visible)::before,
.br-history-bar:focus-visible + .br-history-bar + .br-history-bar::before { width: 16px; }
.br-history-tooltip { position: absolute; z-index: 1; width: min(320px, calc(100% - 76px)); padding: 10px 12px 11px; border: 1px solid var(--line); border-radius: 12px; background: var(--sf); color: var(--tx); box-shadow: var(--shadow-md); font-size: 12.5px; line-height: 1.45; overflow-wrap: anywhere; word-break: break-word; pointer-events: none; }
.br-history-tooltip[hidden] { display: none; }
.br-history-tooltip-title { overflow: hidden; font-size: 13.5px; font-weight: 600; line-height: 1.5; text-overflow: ellipsis; white-space: nowrap; }
.br-history-tooltip-meta { margin-top: 3px; color: var(--tx2); }
.br-history-tooltip-preview { display: grid; grid-template-columns: 16px minmax(0, 1fr); margin-top: 8px; color: var(--tx2); }
.br-history-tooltip-bullet { text-align: center; }
.br-history-tooltip-preview-text { display: -webkit-box; overflow: hidden; -webkit-box-orient: vertical; -webkit-line-clamp: 2; }
.br-history-tooltip-source { display: flex; align-items: center; gap: 7px; margin-top: 7px; color: var(--tx2); }
.br-history-tooltip-source svg { flex: 0 0 auto; }
.br-user-message { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; margin-bottom: 26px; animation: br-rise .35s ease both; }
.br-user-bubble { max-width: 78%; padding: 11px 16px; border-radius: 18px 18px 6px 18px; background: var(--acc-soft); color: var(--tx); font-size: 15px; line-height: 1.65; white-space: pre-wrap; }
.br-copy-button { display: flex; align-items: center; gap: 5px; padding: 3px 8px; border: 0; border-radius: 8px; background: transparent; color: var(--tx2); font-size: 12px; opacity: 0; cursor: pointer; transition: opacity .18s, background .18s; }
.br-user-message:hover .br-copy-button, .br-copy-button:focus-visible, .br-copy-button.is-visible { opacity: 1; }
.br-copy-button:hover { background: var(--sf2); color: var(--tx); }

.br-assistant-message { display: flex; align-items: flex-start; gap: 12px; margin-bottom: 26px; animation: br-rise .35s ease both; }
.br-assistant-avatar { width: 30px; height: 30px; flex: 0 0 auto; display: grid; place-items: center; margin-top: 2px; border-radius: 50%; background: var(--sage-soft); color: var(--sage-deep); }
.br-assistant-avatar.is-thinking { animation: br-bob 1.6s ease-in-out infinite; }
.br-assistant-body { min-width: 0; flex: 1; }
.br-answer { color: var(--tx); font-size: 15.2px; line-height: 1.8; text-wrap: pretty; }
.br-answer p { margin: 0 0 1em; white-space: pre-line; }
.br-answer p:last-child { margin-bottom: 0; }
.br-answer-heading { margin: 1.35em 0 .55em; color: var(--tx); font-family: var(--font-heading); font-size: 18px; font-weight: 400; line-height: 1.35; }
.br-answer-list { margin: .55em 0 1em; padding-left: 1.4em; }
.br-answer-list li { margin: .25em 0; }
.br-answer a { color: var(--acc-deep); text-underline-offset: 3px; }
.br-inline-code { padding: 2px 5px; border-radius: 6px; background: var(--sf2); font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: .9em; }
.br-code-block { overflow-x: auto; padding: 13px 15px; border-radius: 14px; background: var(--sf2); font-size: 13px; line-height: 1.6; }
.br-answer-quote { margin: .75em 0 1.2em; padding: .15em 0 .15em 1em; border-left: 3px solid var(--acc); color: var(--tx2); }
.br-answer-quote p { margin: 0; }
.br-answer-table-wrap { max-width: 100%; margin: .7em 0 1.2em; overflow-x: auto; }
.br-answer-table { width: 100%; min-width: 600px; border-collapse: collapse; font-size: .94em; line-height: 1.55; }
.br-answer-table th, .br-answer-table td { padding: .55em .7em; border: 1px solid var(--line); vertical-align: top; }
.br-answer-table th { background: var(--sf2); font-weight: 600; }
.br-inline-citation { display: inline-block; min-width: 0; height: auto; margin: 0 .08em; padding: 0 .12em; border: 0; border-bottom: 1px solid transparent; border-radius: 0; background: transparent; color: var(--acc-deep); font-family: ui-serif, "Songti SC", "Noto Serif CJK SC", STSong, SimSun, Georgia, serif; font-size: .72em; font-weight: 600; line-height: 1; vertical-align: super; white-space: nowrap; cursor: pointer; }
.br-inline-citation-locator { color: color-mix(in srgb, var(--acc-deep) 70%, var(--tx2)); font-size: .92em; font-weight: 400; letter-spacing: .015em; }
.br-inline-citation:hover { border-bottom-color: currentColor; }
.br-warning-chip { margin-top: 10px; background: var(--acc-soft); color: var(--acc-deep); }
.br-degraded-note { display: flex; align-items: center; gap: 7px; margin-top: 10px; color: var(--tx2); font-size: 12.5px; }
.br-answer-meta { display: flex; align-items: center; gap: 8px; margin-top: 10px; min-height: 25px; }

.br-citations { margin-top: 24px; padding: 0; border-radius: 0; background: transparent; }
.br-citations-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 18px; margin-bottom: 8px; padding: 0 12px; }
.br-citations-title { margin: 0; color: var(--tx2); font: 600 12px/1.5 ui-serif, "Songti SC", "Noto Serif CJK SC", STSong, SimSun, Georgia, serif; letter-spacing: .12em; }
.br-citation-switch { display: inline-flex; align-items: center; gap: 14px; border-bottom: 1px solid color-mix(in srgb, var(--line) 74%, transparent); }
.br-citation-switch button { margin-bottom: -1px; padding: 2px 0 5px; border: 0; border-bottom: 1px solid transparent; border-radius: 0; background: transparent; color: var(--tx2); font: 500 11px/1.25 ui-serif, Georgia, "Times New Roman", serif; letter-spacing: .02em; cursor: pointer; }
.br-citation-switch button.is-active { border-bottom-color: var(--tx); background: transparent; color: var(--tx); box-shadow: none; }
.br-citations-list { width: 100%; padding: 5px 12px 7px; border-top: 1px solid color-mix(in srgb, var(--line) 65%, transparent); border-bottom: 1px solid color-mix(in srgb, var(--line) 65%, transparent); }
.br-citation-row { width: 100%; display: grid; grid-template-columns: 1.35em minmax(0, 1fr); align-items: start; gap: .45em; padding: 7px 8px; border: 0; border-radius: 2px; background: transparent; color: var(--tx); font: 400 13.7px/1.72 ui-serif, "Songti SC", "Noto Serif CJK SC", STSong, SimSun, Georgia, serif; text-align: left; cursor: pointer; }
.br-citation-row:hover, .br-bibliography-row:hover { background: color-mix(in srgb, var(--tx) 4%, transparent); color: var(--tx); }
.br-citation-number { width: auto; height: auto; display: block; margin: .18em 0 0; padding: 0; border: 0; border-radius: 0; background: transparent; color: var(--tx2); font: 600 9.5px/1 ui-serif, Georgia, "Times New Roman", serif; text-align: right; }
.br-citation-copy { min-width: 0; display: block; }
.br-bibliography-row { width: 100%; padding: 8px 8px 8px calc(8px + 1.75em); border: 0; background: transparent; color: var(--tx); font: 400 13.7px/1.75 ui-serif, "Songti SC", "Noto Serif CJK SC", STSong, SimSun, Georgia, serif; text-align: left; text-indent: -1.75em; cursor: pointer; }
.br-bibliography-row + .br-bibliography-row { border-top: 1px solid color-mix(in srgb, var(--line) 48%, transparent); }
.br-bibliography-row:hover { color: var(--acc-deep); }

.br-clarify-card { padding: 13px 16px; border: 1.5px dashed var(--sage); border-radius: 14px; background: color-mix(in srgb, var(--sage-soft) 58%, transparent); }
.br-card-kicker { margin-bottom: 5px; color: var(--sage-deep); font-size: 11.5px; font-weight: 700; letter-spacing: 1.2px; text-transform: uppercase; }
.br-clarify-question { font-size: 15.2px; line-height: 1.7; }
.br-card-note { margin-top: 5px; color: var(--tx2); font-size: 12.8px; line-height: 1.55; }
.br-no-answer-card { display: flex; align-items: flex-start; gap: 11px; padding: 14px 16px; border: 1.5px solid var(--line); border-radius: 16px; background: var(--sf); }
.br-no-answer-card > svg { flex: 0 0 auto; margin-top: 2px; color: var(--sage-deep); }
.br-no-answer-title { font-size: 14px; font-weight: 700; }

.br-compact-card { margin: 0 auto 26px; color: var(--tx2); font-size: 12.8px; animation: br-rise .35s ease both; }
.br-compact-card summary { width: fit-content; display: flex; align-items: center; gap: 8px; margin: 0 auto; padding: 7px 16px; border: 1.5px dashed var(--line); border-radius: 999px; cursor: pointer; list-style: none; }
.br-compact-card summary::-webkit-details-marker { display: none; }
.br-compact-summary { margin: 10px auto 0; padding: 12px 14px; border-radius: 14px; background: var(--sf2); color: var(--tx2); font-size: 13px; line-height: 1.65; white-space: pre-wrap; }

.br-dots { display: flex; align-items: center; gap: 4px; }
.br-dots i { width: 5px; height: 5px; border-radius: 50%; background: var(--tx2); animation: br-dot 1.2s infinite; }
.br-dots i:nth-child(2) { animation-delay: .18s; }
.br-dots i:nth-child(3) { animation-delay: .36s; }
.br-process { margin: 0 0 18px; color: var(--tx); }
.br-process-summary { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 0 0 12px; border-bottom: 1px solid var(--line); cursor: pointer; list-style: none; }
.br-process-summary::-webkit-details-marker { display: none; }
.br-process-summary-copy { min-width: 0; display: flex; flex-direction: column; gap: 5px; }
.br-process-summary-copy strong { overflow: hidden; font-size: 13.5px; font-weight: 600; line-height: 1.45; text-overflow: ellipsis; white-space: nowrap; }
.br-process-elapsed { color: var(--tx2); font-size: 13px; font-variant-numeric: tabular-nums; }
.br-process-chevron { flex: 0 0 auto; color: var(--tx2); transition: transform .2s ease; }
.br-process[open] .br-process-chevron { transform: rotate(180deg); }
.br-process.is-complete { margin-bottom: 16px; }
.br-process.is-complete .br-process-summary { padding: 7px 0; border-bottom: 0; }
.br-process.is-complete .br-process-summary-copy { display: block; }
.br-process.is-complete .br-process-summary-copy strong { color: var(--tx2); font-size: 12.8px; font-weight: 500; }
.br-process.is-complete[open] .br-process-stream { gap: 14px; padding-top: 14px; }
.br-process.is-complete[open] .br-process-prose { color: var(--tx2); font-size: 13px; line-height: 1.7; }
.br-process.is-running:not(.is-answering) > .br-process-summary { display: none; }
.br-process.is-running:not(.is-answering) > .br-process-stream { padding-top: 0; }
.br-process.is-complete[open] .br-activity { color: var(--tx2); font-size: 11.8px; opacity: .88; }
.br-process.is-complete[open] .br-process-totals { font-size: 11px; }
.br-process-stream { display: flex; flex-direction: column; gap: 16px; padding: 18px 0 6px; }
.br-process-prose { color: var(--tx); font-size: 14.2px; line-height: 1.75; overflow-wrap: anywhere; white-space: pre-wrap; }
.br-activity { min-width: 0; color: var(--tx2); font-size: 12.6px; line-height: 1.55; }
.br-activity-summary { display: flex; align-items: baseline; gap: 8px; min-width: 0; list-style: none; }
summary.br-activity-summary { cursor: pointer; }
.br-activity-summary::-webkit-details-marker { display: none; }
.br-activity-mark { width: 17px; flex: 0 0 17px; align-self: center; display: grid; place-items: center; color: var(--tx2); }
.br-activity-mark svg { display: block; opacity: .82; }
.br-activity-title { min-width: 0; color: var(--tx2); font-weight: 520; overflow-wrap: anywhere; }
.br-activity-title.is-shimmer { color: transparent; background: linear-gradient(100deg, color-mix(in srgb, var(--tx2) 62%, transparent) 15%, var(--tx) 44%, color-mix(in srgb, var(--tx2) 62%, transparent) 73%); background-size: 230% 100%; background-clip: text; -webkit-background-clip: text; animation: br-activity-shimmer 1.65s linear infinite; }
.br-activity-progress, .br-activity-elapsed, .br-activity-total { flex: 0 0 auto; color: var(--tx2); font-size: 11.5px; font-variant-numeric: tabular-nums; }
.br-activity-progress:empty, .br-activity-total:empty { display: none; }
.br-activity-total { margin-left: auto; padding-left: 12px; }
.br-activity-chevron { flex: 0 0 auto; align-self: center; transition: transform .18s ease; }
.br-activity[open] > .br-activity-summary .br-activity-chevron { transform: rotate(180deg); }
.br-activity.state-done .br-activity-mark, .br-activity.state-partial .br-activity-mark { color: var(--sage-deep); }
.br-activity.state-failed .br-activity-mark, .br-activity.state-failed .br-activity-title { color: var(--acc-deep); }
.br-activity-details { display: flex; flex-direction: column; gap: 9px; margin: 10px 0 0 25px; padding-left: 10px; border-left: 1px solid color-mix(in srgb, var(--line) 72%, transparent); }
.br-activity-detail { display: grid; grid-template-columns: 16px minmax(0, 1fr); column-gap: 7px; min-width: 0; color: var(--tx2); }
.br-activity-detail-mark { grid-column: 1; grid-row: 1 / span 2; padding-top: .16em; }
.br-activity-detail-mark svg { display: block; opacity: .75; }
.br-activity-detail-task { grid-column: 2; min-width: 0; overflow-wrap: anywhere; }
.br-activity-detail-result { grid-column: 2; min-width: 0; color: color-mix(in srgb, var(--tx2) 84%, transparent); font-size: 11.7px; overflow-wrap: anywhere; }
.br-activity-detail-result:empty { display: none; }
.br-activity-detail.state-failed { color: var(--acc-deep); }
.br-process-empty { color: var(--tx2); font-size: 13px; }
.br-process-totals { margin-top: 3px; padding-top: 11px; border-top: 1px dashed var(--line); color: var(--tx2); font-size: 11.5px; font-variant-numeric: tabular-nums; }
@keyframes br-activity-shimmer { from { background-position: 130% 0; } to { background-position: -130% 0; } }
.br-answer-preview { padding-top: 2px; white-space: pre-wrap; overflow-anchor: none; }
.br-answer-rule { margin: 1.35em 0; border: 0; border-top: 1px solid var(--line); }
.br-run-error { display: flex; align-items: center; gap: 11px; margin: 0 0 26px 42px; padding: 12px 14px; border: 1.5px solid var(--line); border-radius: 15px; background: var(--sf); }
.br-run-error > svg { flex: 0 0 auto; color: var(--acc-deep); }
.br-run-error-copy { min-width: 0; flex: 1; display: flex; flex-direction: column; gap: 2px; }
.br-run-error-copy span { color: var(--tx2); font-size: 12.8px; }
.br-secondary-button { display: inline-flex; align-items: center; gap: 6px; padding: 7px 11px; border: 1.5px solid var(--line); border-radius: 999px; background: transparent; font-size: 12.5px; cursor: pointer; }
.br-secondary-button:hover { background: var(--sf2); }
.br-loading-card { display: flex; align-items: center; justify-content: center; gap: 10px; min-height: 240px; color: var(--tx2); }

.br-composer-section { width: min(760px, 100%); flex: 0 0 auto; position: relative; margin: 0 auto; padding: 0 20px; }
.br-composer { padding: 14px 16px 10px; border: 1.5px solid var(--line); border-radius: 24px; background: var(--sf); box-shadow: var(--shadow-md); }
.br-textarea { width: 100%; max-height: 180px; display: block; overflow-y: auto; resize: none; border: 0; outline: 0; background: transparent; color: var(--tx); font-size: 15px; line-height: 1.6; }
.br-textarea:focus-visible { outline: none; }
.br-textarea::placeholder { color: color-mix(in srgb, var(--tx2) 78%, transparent); }
.br-composer-controls { display: flex; align-items: center; gap: 6px; margin-top: 8px; }
.br-context-meter { --context-color: #43a56b; --context-angle: 0deg; width: 16px; height: 16px; flex: 0 0 auto; align-self: center; position: relative; display: block; margin-inline: 0; border-radius: 50%; background: conic-gradient(var(--context-color) 0 var(--context-angle), color-mix(in srgb, var(--line) 76%, transparent) var(--context-angle) 360deg); outline: none; }
.br-context-meter::before { content: ""; position: absolute; inset: 3px; border-radius: inherit; background: var(--sf); }
.br-context-meter::after { content: attr(data-tooltip); position: absolute; left: 50%; bottom: calc(100% + 7px); z-index: 3; width: max-content; padding: 4px 7px; border-radius: 6px; background: var(--tx); color: var(--bg); box-shadow: var(--shadow-sm); font-size: 10.5px; font-variant-numeric: tabular-nums; line-height: 1; white-space: nowrap; opacity: 0; visibility: hidden; transform: translate(-50%, 3px); transition: opacity .14s ease, transform .14s ease, visibility .14s; pointer-events: none; }
.br-context-meter:hover::after, .br-context-meter:focus-visible::after { opacity: 1; visibility: visible; transform: translate(-50%, 0); }
.br-context-meter:focus-visible { box-shadow: 0 0 0 2px color-mix(in srgb, var(--context-color) 36%, transparent); }
.br-context-meter.is-green { --context-color: #43a56b; }
.br-context-meter.is-cyan { --context-color: #22a6a8; }
.br-context-meter.is-yellow { --context-color: #cfaa2f; }
.br-context-meter.is-orange { --context-color: #dc7b32; }
.br-context-meter.is-red { --context-color: #d84e45; }
.br-effort-button { display: flex; align-items: center; gap: 5px; padding: 4px 8px; border: 1.5px solid var(--line); border-radius: 999px; background: transparent; color: var(--tx2); font-size: 11.5px; font-weight: 600; cursor: pointer; }
.br-effort-button:hover { background: var(--sf2); color: var(--tx); }
.br-effort-button:disabled { opacity: .6; cursor: default; }
.br-send-button { width: 32px; height: 32px; display: grid; place-items: center; padding: 0; border: 0; border-radius: 50%; background: var(--acc); color: var(--on-acc); cursor: pointer; transition: opacity .2s, background .2s; }
.br-send-button:hover { background: var(--acc-strong); }
.br-send-button:disabled { opacity: .4; cursor: default; }
.br-stop-button { border: 1.5px solid var(--line); background: var(--sf2); color: var(--tx); }
.br-stop-button:hover { background: var(--line); }

.br-effort-picker, .br-slash-panel { position: absolute; bottom: calc(100% + 10px); z-index: 41; border: 1.5px solid var(--line); border-radius: 18px; background: var(--sf); box-shadow: var(--shadow-lg); animation: br-pop .22s cubic-bezier(.2, .8, .3, 1) both; }
.br-effort-picker { right: 20px; width: min(350px, calc(100% - 40px)); padding: 14px 18px 12px; }
.br-effort-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 14px; }
.br-effort-title { display: flex; align-items: baseline; gap: 8px; }
.br-effort-title strong { font-family: var(--font-heading); font-size: 15px; font-weight: 400; }
.br-effort-title span { color: var(--tx2); font-size: 12px; }
.br-auto-toggle { display: inline-flex; align-items: center; gap: 7px; padding: 3px 0 3px 6px; border: 0; background: transparent; color: var(--tx2); cursor: pointer; }
.br-auto-label { font-size: 11.5px; font-weight: 650; transition: color .18s ease; }
.br-auto-track { width: 31px; height: 19px; display: flex; align-items: center; padding: 2px; border: 1px solid var(--line); border-radius: 999px; background: var(--sf2); transition: border-color .2s ease, background .2s ease, box-shadow .2s ease; }
.br-auto-thumb { width: 13px; height: 13px; border: 1px solid color-mix(in srgb, var(--tx2) 45%, var(--line)); border-radius: 50%; background: var(--sf); box-shadow: var(--shadow-sm); transform: translateX(0); transition: transform .2s cubic-bezier(.2, .8, .3, 1), border-color .2s ease, background .2s ease; }
.br-auto-toggle.is-on { color: var(--acc-deep); }
.br-auto-toggle.is-on .br-auto-track { border-color: color-mix(in srgb, var(--acc) 68%, var(--line)); background: color-mix(in srgb, var(--acc) 34%, var(--sf)); }
.br-auto-toggle.is-on .br-auto-thumb { border-color: var(--acc); background: var(--acc); transform: translateX(12px); }
.br-auto-toggle:focus-visible { outline: 2px solid color-mix(in srgb, var(--acc) 55%, transparent); outline-offset: 2px; border-radius: 999px; }
.br-effort-manual { transition: opacity .18s ease; }
.br-range { width: 100%; height: 6px; display: block; appearance: none; border-radius: 99px; background: var(--sf2); cursor: pointer; }
.br-range::-webkit-slider-thumb { width: 20px; height: 20px; appearance: none; border: 3px solid var(--on-acc); border-radius: 50%; background: var(--acc); box-shadow: var(--shadow-sm); cursor: pointer; }
.br-range::-moz-range-thumb { width: 14px; height: 14px; border: 3px solid var(--on-acc); border-radius: 50%; background: var(--acc); box-shadow: var(--shadow-sm); cursor: pointer; }
.br-effort-manual.is-auto .br-range { background: color-mix(in srgb, var(--line) 70%, var(--sf2)); }
.br-effort-manual.is-auto .br-range::-webkit-slider-thumb { border-color: color-mix(in srgb, var(--tx2) 55%, var(--line)); background: var(--sf); box-shadow: none; }
.br-effort-manual.is-auto .br-range::-moz-range-thumb { border-color: color-mix(in srgb, var(--tx2) 55%, var(--line)); background: var(--sf); box-shadow: none; }
.br-effort-labels { display: flex; margin-top: 8px; }
.br-effort-labels button { flex: 1; padding: 3px 0; border: 0; background: transparent; color: var(--tx2); font-size: 11.6px; font-weight: 600; cursor: pointer; transition: color .16s ease; }
.br-effort-labels button.is-active { color: var(--acc-deep); }
.br-effort-description { min-height: 34px; margin-top: 10px; color: var(--tx2); font-size: 12.6px; line-height: 1.55; }
.br-effort-cache-note { margin-top: 8px; padding-top: 9px; border-top: 1px solid color-mix(in srgb, var(--line) 72%, transparent); color: var(--tx2); font-size: 11.5px; line-height: 1.55; animation: br-rise .18s ease both; }
.br-slash-panel { left: 20px; width: min(410px, calc(100% - 40px)); padding: 8px; }
.br-slash-list { max-height: min(286px, 42vh); overflow-y: auto; }
.br-slash-command { width: 100%; display: flex; align-items: baseline; gap: 10px; padding: 10px 13px; border: 0; border-radius: 12px; background: transparent; text-align: left; cursor: pointer; }
.br-slash-command:hover, .br-slash-command.is-active { background: var(--sf2); }
.br-slash-command:focus-visible { outline: 2px solid color-mix(in srgb, var(--acc) 55%, transparent); outline-offset: -2px; }
.br-slash-command strong { flex: 0 0 auto; color: var(--acc-deep); font-size: 13.8px; }
.br-slash-command span { min-width: 0; color: var(--tx2); font-size: 12.6px; }
.br-slash-empty { padding: 13px; color: var(--tx2); font-size: 12.6px; }
.br-slash-help { padding: 7px 13px 4px; color: var(--tx2); font-size: 11.5px; }
.br-compact-wait { min-height: 74px; display: flex; align-items: center; gap: 13px; margin-bottom: 18px; padding: 13px 15px; border: 1px solid color-mix(in srgb, var(--acc) 28%, var(--line)); border-radius: 17px; background: color-mix(in srgb, var(--acc-soft) 48%, var(--sf)); }
.br-compact-orbit { width: 38px; height: 38px; flex: 0 0 auto; position: relative; display: block; border: 1px solid color-mix(in srgb, var(--acc) 34%, transparent); border-radius: 50%; animation: br-spin 2.4s linear infinite; }
.br-compact-orbit i { position: absolute; width: 7px; height: 7px; border-radius: 50%; background: var(--acc); box-shadow: 0 0 0 3px color-mix(in srgb, var(--acc) 14%, transparent); }
.br-compact-orbit i:nth-child(1) { top: -3px; left: 15px; }
.br-compact-orbit i:nth-child(2) { right: 0; bottom: 3px; transform: scale(.72); }
.br-compact-orbit i:nth-child(3) { bottom: 1px; left: 2px; transform: scale(.48); }
.br-compact-wait-copy { min-width: 0; flex: 1; display: flex; flex-direction: column; gap: 3px; }
.br-compact-wait-copy strong { font-size: 13.5px; font-weight: 650; }
.br-compact-wait-copy span, .br-compact-wait-elapsed { color: var(--tx2); font-size: 11.8px; line-height: 1.45; }
.br-compact-wait-elapsed { flex: 0 0 auto; font-variant-numeric: tabular-nums; }
.br-toast { position: absolute; bottom: calc(100% + 12px); left: 0; right: 0; z-index: 42; width: fit-content; max-width: calc(100% - 40px); margin: 0 auto; padding: 8px 18px; overflow: hidden; border-radius: 999px; background: var(--tx); color: var(--bg); box-shadow: var(--shadow-md); font-size: 13px; text-overflow: ellipsis; white-space: nowrap; animation: br-pop .2s ease both; }
.br-suggestions { max-width: 720px; display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin: 0 auto; padding: 18px 24px 0; }
.br-suggestion { padding: 9px 16px; border: 1.5px solid var(--line); border-radius: 999px; background: var(--sf); color: var(--tx); font-size: 13.5px; cursor: pointer; }
.br-suggestion:hover { border-color: var(--tx2); background: var(--sf2); }
.br-disclaimer { flex: 0 0 auto; padding: 9px 16px 12px; color: var(--tx2); font-size: 11.8px; text-align: center; }

.br-modal-layer, .br-auth-layer { position: fixed; inset: 0; z-index: 80; display: grid; place-items: start center; }
.br-modal-backdrop, .br-auth-backdrop { position: absolute; inset: 0; background: rgba(32, 30, 29, .42); }
.br-search-modal { position: relative; width: min(580px, 92vw); max-height: 70vh; margin-top: 13vh; overflow: hidden; border: 1.5px solid var(--line); border-radius: 22px; background: var(--sf); box-shadow: var(--shadow-lg); animation: br-pop .22s cubic-bezier(.2, .8, .3, 1) both; }
.br-search-head { display: flex; align-items: center; gap: 12px; padding: 15px 20px; border-bottom: 1.5px solid var(--line); color: var(--tx2); }
.br-search-input { min-width: 0; flex: 1; border: 0; outline: 0; background: transparent; color: var(--tx); font-size: 15px; }
.br-search-results { max-height: 52vh; overflow-y: auto; padding: 8px; }
.br-search-result { width: 100%; display: flex; align-items: center; gap: 11px; padding: 11px 13px; border: 0; border-radius: 14px; background: transparent; color: var(--tx); text-align: left; cursor: pointer; }
.br-search-result:hover { background: var(--sf2); }
.br-search-result > svg { flex: 0 0 auto; color: var(--tx2); }
.br-search-result-title { min-width: 0; flex: 1; overflow: hidden; font-size: 14px; text-overflow: ellipsis; white-space: nowrap; }
.br-search-result-group { flex: 0 0 auto; color: var(--tx2); font-size: 12px; }
.br-search-empty { padding: 20px; color: var(--tx2); font-size: 13px; text-align: center; }

.br-citation-layer { place-items: center; padding: 24px; }
.br-citation-layer .br-modal-backdrop { background: color-mix(in srgb, var(--tx) 28%, transparent); backdrop-filter: blur(3px); }
.br-citation-dialog { position: relative; width: min(560px, calc(100vw - 32px)); max-height: min(84vh, 760px); overflow-y: auto; padding: 27px 30px 24px; border: 1px solid color-mix(in srgb, var(--line) 82%, transparent); border-radius: 12px; background: color-mix(in srgb, var(--sf) 90%, var(--bg)); box-shadow: 0 18px 54px color-mix(in srgb, var(--tx) 22%, transparent); animation: br-pop .18s cubic-bezier(.2, .8, .3, 1) both; }
.br-citation-dialog-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; }
.br-citation-dialog-kicker { margin-bottom: 5px; color: var(--tx2); font: 600 11.5px/1.4 ui-serif, "Songti SC", "Noto Serif CJK SC", STSong, SimSun, Georgia, serif; letter-spacing: .14em; }
.br-citation-dialog h2 { margin: 0; font: 500 23px/1.35 ui-serif, "Songti SC", "Noto Serif CJK SC", STSong, SimSun, Georgia, serif; letter-spacing: .01em; }
.br-citation-close { width: 30px; height: 30px; flex: 0 0 auto; margin: -3px -4px 0 0; border-radius: 50%; color: var(--tx2); }
.br-citation-close:hover { background: color-mix(in srgb, var(--tx) 5%, transparent); color: var(--tx); }
.br-citation-dialog-meta { display: grid; grid-template-columns: max-content minmax(0, 1fr); gap: 0 16px; margin: 19px 0 0; padding: 10px 0; border-top: 1px solid color-mix(in srgb, var(--line) 72%, transparent); border-bottom: 1px solid color-mix(in srgb, var(--line) 72%, transparent); color: var(--tx); font: 400 13.5px/1.55 ui-serif, "Songti SC", "Noto Serif CJK SC", STSong, SimSun, Georgia, serif; }
.br-citation-dialog-meta dt, .br-citation-dialog-meta dd { padding: 4px 0; }
.br-citation-dialog-meta dt { color: var(--tx2); font-size: 11.5px; font-weight: 500; letter-spacing: .08em; }
.br-citation-dialog-meta dd { min-width: 0; margin: 0; overflow-wrap: anywhere; }
.br-citation-heading-path { margin-top: 15px; color: var(--tx2); font: 400 11.5px/1.5 ui-serif, "Songti SC", "Noto Serif CJK SC", STSong, SimSun, Georgia, serif; }
.br-evidence-section { margin-top: 17px; }
.br-evidence-label { margin-bottom: 7px; color: var(--tx2); font: 600 11.5px/1.4 ui-serif, "Songti SC", "Noto Serif CJK SC", STSong, SimSun, Georgia, serif; letter-spacing: .12em; }
.br-evidence-excerpt { max-height: 200px; margin: 0; padding: 13px 12px 13px 17px; overflow-y: auto; border-left: 2px solid color-mix(in srgb, var(--tx2) 55%, transparent); border-radius: 0; background: transparent; color: var(--tx); font: 400 14px/1.78 ui-serif, "Songti SC", "Noto Serif CJK SC", STSong, SimSun, Georgia, serif; scrollbar-width: thin; white-space: pre-wrap; }
.br-citation-fallback { margin-top: 17px; padding: 12px 0; border-top: 1px solid color-mix(in srgb, var(--line) 62%, transparent); border-bottom: 1px solid color-mix(in srgb, var(--line) 62%, transparent); border-radius: 0; background: transparent; color: var(--tx2); font: 400 13px/1.65 ui-serif, "Songti SC", "Noto Serif CJK SC", STSong, SimSun, Georgia, serif; }
.br-citation-actions { display: flex; justify-content: flex-end; margin-top: 20px; }
.br-primary-link { display: inline-flex; align-items: center; gap: 7px; padding: 7px 10px; border: 1px solid color-mix(in srgb, var(--acc) 70%, transparent); border-radius: 4px; background: transparent; color: var(--acc-deep); font: 600 12.5px/1.4 ui-serif, "Songti SC", "Noto Serif CJK SC", STSong, SimSun, Georgia, serif; text-decoration: none; }
.br-primary-link:hover { background: color-mix(in srgb, var(--acc-soft) 54%, transparent); }

.br-auth-layer { z-index: 90; place-items: center; }
.br-auth-backdrop { background: color-mix(in srgb, var(--bg) 84%, rgba(32, 30, 29, .35)); backdrop-filter: blur(8px); }
.br-auth-card { position: relative; width: min(410px, calc(100vw - 32px)); display: flex; flex-direction: column; align-items: center; padding: 26px; border: 1.5px solid var(--line); border-radius: 24px; background: var(--sf); box-shadow: var(--shadow-lg); animation: br-pop .22s ease both; }
.br-auth-card h2 { margin: 10px 0 4px; font-family: var(--font-heading); font-size: 24px; font-weight: 400; }
.br-auth-card p { margin: 0 0 18px; color: var(--tx2); font-size: 13px; text-align: center; }
.br-auth-input { width: 100%; padding: 10px 14px; border: 1.5px solid var(--line); border-radius: 999px; outline: 0; background: var(--bg); color: var(--tx); }
.br-auth-input:focus { border-color: var(--acc); }
.br-auth-error { width: 100%; margin-top: 8px; color: var(--acc-deep); font-size: 12.5px; text-align: left; }
.br-auth-submit { width: 100%; margin-top: 14px; padding: 10px 14px; border: 0; border-radius: 999px; background: var(--acc); color: var(--on-acc); font-weight: 600; cursor: pointer; }
.br-auth-submit:hover { background: var(--acc-strong); }
.br-auth-submit:disabled { opacity: .5; cursor: default; }

.br-intro { position: fixed; inset: 0; z-index: 100; display: flex; flex-direction: column; align-items: center; justify-content: center; background: var(--bg); transition: opacity .7s cubic-bezier(.4, 0, .2, 1), transform .7s cubic-bezier(.4, 0, .2, 1); }
.br-intro.is-leaving { opacity: 0; transform: translateY(-26px) scale(.985); pointer-events: none; }
.br-intro-stage { width: min(860px, 86vw); }
.br-intro-stage svg { width: 100%; height: auto; display: block; }
.br-intro-skip { position: absolute; bottom: 34px; padding: 8px 20px; border: 1.5px solid var(--line); border-radius: 999px; background: transparent; color: var(--tx2); font-size: 13px; cursor: pointer; }
.br-intro-skip:hover { background: var(--sf2); color: var(--tx); }

@media (max-width: 900px) {
  .br-focus-chip { max-width: 180px; }
  .br-timeline-content { padding-inline: 20px; }
}

@media (max-width: 760px) {
  .br-sidebar { position: fixed; inset: 0 auto 0 0; width: min(288px, 86vw); box-shadow: 12px 0 30px rgba(32, 30, 29, .16); }
  .br-sidebar.is-collapsed { width: min(288px, 86vw); transform: translateX(-102%); }
  .br-sidebar.is-collapsed .br-sidebar-label,
  .br-sidebar.is-collapsed .br-brand,
  .br-sidebar.is-collapsed .br-conversation-nav { display: initial; }
  .br-sidebar.is-collapsed .br-conversation-nav { display: block; visibility: visible; opacity: 1; pointer-events: auto; }
  .br-sidebar.is-collapsed .br-primary-nav { padding-inline: 16px; }
  .br-sidebar.is-collapsed .br-sidebar-action { width: 100%; height: auto; justify-content: flex-start; padding: 9px 10px; }
  .br-sidebar.is-collapsed .br-account { border-top: 1.5px solid var(--line); justify-content: flex-start; padding-inline: 16px; }
  .br-mobile-menu { display: inline-flex; }
  .br-header { padding-inline: 10px; }
  .br-focus-chip { display: none; }
  .br-hero-spacer { min-height: 28px; }
  .br-hero-center { margin-bottom: 18px; }
  .br-hero-center h1 { font-size: clamp(24px, 7vw, 30px); }
  .br-hero-bottom { min-height: 45px; }
  .br-composer-section { padding-inline: 12px; }
  .br-composer { padding: 12px 13px 9px; border-radius: 21px; }
  .br-suggestions { gap: 8px; padding: 14px 14px 0; }
  .br-suggestion { padding: 8px 12px; font-size: 12.6px; }
  .br-timeline-content { padding: 18px 14px 8px; }
  .br-history-layer { display: none; }
  .br-user-bubble { max-width: 88%; }
  .br-citations { padding-inline: 0; }
  .br-effort-chip { display: none; }
  .br-run-error { margin-left: 0; }
  .br-disclaimer { padding-bottom: max(10px, env(safe-area-inset-bottom)); }
}

@media (max-width: 430px) {
  .br-brand span { font-size: 18px; }
  .br-header-title { font-size: 13px; }
  .br-hero-center > svg { width: 48px; height: 48px; }
  .br-effort-button { padding-inline: 8px; }
  .br-compact-wait { align-items: flex-start; flex-wrap: wrap; }
  .br-compact-wait-elapsed { margin-left: 51px; margin-top: -18px; }
  .br-search-modal { margin-top: 8vh; }
  .br-all-chats { padding: 24px 18px 0; }
  .br-all-chats-head { align-items: stretch; flex-wrap: wrap; }
  .br-all-chats-head > div:first-child { flex-basis: 100%; }
  .br-all-search { width: auto; flex: 1; }
  .br-citations-head { align-items: flex-start; flex-direction: column; }
  .br-citation-layer { padding: 12px; }
  .br-citation-dialog { width: calc(100vw - 24px); padding: 22px 20px 19px; }
  .br-citation-dialog h2 { font-size: 20px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}
