:root {
  --bg-000: 0 0% 100%;
  --bg-100: 0 0% 100%;
  --bg-200: 0 0% 96.4%;
  --bg-300: 0 0% 93.8%;
  --text-000: 0 0% 7%;
  --text-100: 0 0% 7%;
  --text-300: 0 0% 32%;
  --text-400: 43 3% 47%;
  --accent-main-000: 211 100% 45%;
  --accent-main-200: 211 100% 45%;
  --text-500: 0 0% 54%;
  --border-200: 30 3.3% 11.8%;
  --border-300: 30 3.3% 11.8%;
  --always-black: 0 0% 0%;
  --color-bg-000: hsl(var(--bg-000));
  --color-bg-100: hsl(var(--bg-100));
  --color-bg-200: hsl(var(--bg-200));
  --color-bg-300: hsl(var(--bg-300));
  --color-text-000: hsl(var(--text-000));
  --color-text-100: hsl(var(--text-100));
  --color-text-300: hsl(var(--text-300));
  --color-text-400: hsl(var(--text-400));
  --color-text-500: hsl(var(--text-500));
  --color-accent: hsl(var(--accent-main-000));
  --color-border-200: hsl(var(--border-200) / 0.1);
  --color-border-300: hsl(var(--border-300) / 0.15);
  --shadow-soft: 0 4px 20px 0 hsl(var(--always-black) / 0.04);
  --font-serif: Georgia, "Times New Roman", serif;
  --app-font-scale: 1;
  color: var(--color-text-100);
  background: var(--color-bg-100);
  font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: calc(14px * var(--app-font-scale));
}

* { box-sizing: border-box; }

html,
body {
  width: 100%;
  height: 100%;
}

body {
  margin: 0;
  min-width: 320px;
  overflow: hidden;
  background: var(--color-bg-100);
}

button,
textarea,
input { font: inherit; }

button {
  border: 0;
  border-radius: 999px;
  background: var(--color-text-100);
  color: var(--color-bg-000);
  padding: 8px 13px;
  cursor: pointer;
  font-weight: 650;
}

button.secondary {
  border: 1px solid var(--color-border-300);
  background: var(--color-bg-000);
  color: var(--color-text-100);
}

button.small {
  padding: 5px 9px;
  font-size: 12px;
}

button:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}

.app-shell {
  position: relative;
  display: flex;
  flex-direction: column;
  height: 100vh;
  overflow: clip;
  background: var(--color-bg-100);
}

.app-header {
  order: 0;
  display: grid;
  flex: 0 0 auto;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 6px;
  min-height: 44px;
  padding: 8px calc(48px + env(safe-area-inset-right, 0px)) 7px 16px;
  background: var(--color-bg-100);
}

.brand,
.header-actions {
  display: flex;
  align-items: center;
  gap: 6px;
  min-width: 0;
}

.brand {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 8px;
}

.header-actions {
  flex: 0 0 auto;
  justify-content: flex-end;
  overflow: visible;
}

.brand h1 {
  margin: 0;
  overflow: hidden;
  color: var(--color-text-100);
  font-size: 15px;
  font-weight: 400;
  letter-spacing: -0.01em;
  line-height: 1.2;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.brand h1.running {
  font-weight: 400;
}

.status {
  display: none;
  align-items: center;
  max-width: 180px;
  height: auto;
  overflow: hidden;
  border: 0.5px solid transparent;
  border-radius: 999px;
  background: transparent;
  color: var(--color-text-300);
  padding: 0;
  font-size: 13px;
  font-weight: 550;
  line-height: 1.25;
  opacity: 1;
  text-overflow: ellipsis;
  transition: color 0.15s, background-color 0.15s, border-color 0.15s;
  white-space: nowrap;
}

.status.error { display: inline-flex; }

.status:not(:empty):hover,
.status:focus-visible {
  color: var(--color-text-100);
}

.status.running {
  color: var(--color-text-100);
  font-weight: 650;
}

.status.error {
  max-width: 92px;
  border-color: hsl(4 72% 70% / 0.45);
  background: hsl(4 90% 97%);
  color: hsl(4 65% 42%);
  padding: 0 7px;
  opacity: 1;
}

.icon-button,
.composer-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  flex: 0 0 28px;
  border: 1px solid transparent;
  border-radius: 8px;
  background: transparent;
  color: var(--color-text-300);
  padding: 0;
  font-size: 15px;
  font-weight: 700;
}

.icon-button svg,
.composer-icon svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
  pointer-events: none;
}

.icon-button[aria-label="New chat"] {
  color: var(--color-text-100);
}

.icon-button[aria-label="New chat"] svg {
  width: 17px;
  height: 17px;
}

.icon-button:hover,
.composer-icon:hover {
  border-color: var(--color-border-300);
  background: var(--color-bg-200);
}

.banner,
.todos,
.permission-card,
.elicitation-card {
  margin: 8px 10px 0;
  border: 1px solid var(--color-border-300);
  border-radius: 14px;
  background: var(--color-bg-000);
  padding: 12px;
  box-shadow: var(--shadow-soft);
}

.banner {
  order: 1;
  flex: 0 0 auto;
  display: grid;
  gap: 6px;
  border-width: 0.5px;
  border-color: var(--color-border-200);
  background: var(--color-bg-200);
  color: var(--color-text-300);
  padding: 8px 12px;
  font-size: 12px;
  line-height: 1.35;
  white-space: normal;
}

.banner.error,
.banner.warning {
  border-color: hsl(4 72% 70% / 0.35);
  background: hsl(4 72% 96%);
  color: hsl(4 65% 32%);
}

.banner-row {
  display: flex;
  align-items: flex-start;
  gap: 8px;
}

.banner-icon {
  display: inline-flex;
  width: 16px;
  height: 16px;
  flex: 0 0 16px;
  align-items: center;
  justify-content: center;
  margin-top: 1px;
  color: currentColor;
  font-size: 13px;
  font-weight: 700;
  line-height: 1;
}

.banner-text {
  min-width: 0;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.banner-compacted {
  display: grid;
  grid-template-columns: minmax(12px, 1fr) auto minmax(12px, 1fr);
  align-items: center;
  gap: 12px;
  margin: 3px 0;
  color: var(--color-text-400);
  font-size: 12px;
  line-height: 1;
}

.banner-compacted span {
  height: 1px;
  background: var(--color-border-300);
}

.banner-compacted strong {
  font-size: 12px;
  font-weight: 400;
  white-space: nowrap;
}

.empty-state {
  order: 2;
  display: flex;
  flex: 1 1 auto;
  align-items: center;
  justify-content: center;
  min-height: 0;
  padding: 22px 14px;
  text-align: center;
}

.empty-state-content {
  display: grid;
  justify-items: center;
  gap: 20px;
  width: min(460px, 100%);
  animation: empty-state-enter 0.18s ease-out;
}

.empty-title {
  margin: 0;
  color: var(--color-text-100);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 18px;
  font-weight: 500;
  line-height: 1.35;
  text-wrap: pretty;
}

.permission-card h2,
.elicitation-card h2,
.history-popover h2,
.settings-overlay h2 {
  margin: 0;
  color: var(--color-text-100);
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.25;
}

.starter-prompts {
  display: flex;
  max-width: 100%;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.starter-prompt {
  min-height: 32px;
  border: 0.5px solid var(--color-border-300);
  background: hsl(var(--bg-000) / 0.35);
  color: var(--color-text-300);
  padding: 6px 12px;
  font-size: 12px;
  font-weight: 500;
  white-space: nowrap;
  transition: transform 0.3s, background-color 0.2s, color 0.2s, border-color 0.2s;
}

.starter-prompt:hover,
.starter-prompt:focus-visible {
  border-color: hsl(var(--border-300) / 0.22);
  background: hsl(var(--bg-000) / 0.5);
  color: var(--color-text-100);
  outline: none;
}

.starter-prompt:active { transform: scale(0.985); }

.todos {
  order: 8;
  display: grid;
  flex: 0 0 auto;
  gap: 0;
  margin: 0 20px 6px;
  overflow: hidden;
  border-width: 0.5px;
  border-color: var(--color-border-200);
  border-radius: 14px;
  background: var(--color-bg-200);
  padding: 0;
  box-shadow: 0 3px 16px hsl(var(--always-black) / 0.035);
  animation: todos-enter 0.2s cubic-bezier(0.2, 0.9, 0.35, 1);
}

.todos-header {
  display: grid;
  width: 100%;
  min-height: 34px;
  grid-template-columns: minmax(0, 1fr) auto 22px;
  align-items: center;
  gap: 6px;
  border: 0;
  border-radius: 14px;
  background: transparent;
  color: var(--color-text-100);
  padding: 7px 8px 7px 11px;
  text-align: left;
  font-size: 12px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

.todos-header:hover,
.todos-header:focus-visible {
  color: var(--color-text-000);
  outline: none;
}

.todos-progress {
  color: var(--color-text-300);
  font-size: 11px;
  font-weight: 550;
}

.todos-heading {
  display: inline-flex;
  min-width: 0;
  align-items: center;
  gap: 7px;
}

.todos-title {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.todos-icon {
  position: relative;
  width: 13px;
  height: 13px;
  flex: 0 0 13px;
}

.todos-icon::before,
.todos-icon::after {
  content: "";
  position: absolute;
  left: 2px;
  width: 9px;
  height: 1px;
  border-radius: 999px;
  background: currentColor;
  box-shadow: 0 4px 0 currentColor, 0 8px 0 currentColor;
  opacity: 0.72;
}

.todos-icon::after {
  left: 0;
  width: 1px;
  box-shadow: 0 4px 0 currentColor, 0 8px 0 currentColor;
}

.todos-chevron {
  display: inline-flex;
  width: 22px;
  height: 22px;
  align-items: center;
  justify-content: center;
  border-radius: 7px;
  color: var(--color-text-300);
  font-size: 14px;
  line-height: 1;
  transform: rotate(0deg);
  transition: transform 0.2s ease-out, color 0.15s, background-color 0.15s;
}

.todos-header[aria-expanded="true"] .todos-chevron { transform: rotate(180deg); }
.todos-header:hover .todos-chevron,
.todos-header:focus-visible .todos-chevron {
  background: hsl(var(--always-black) / 0.045);
  color: var(--color-text-100);
}

.todos ol {
  display: grid;
  gap: 0;
  margin: 0;
  border-top: 0.5px solid var(--color-border-200);
  padding: 4px 11px 10px;
  list-style: none;
  overflow: hidden;
}

.todo {
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  align-items: center;
  gap: 9px;
  padding-top: 8px;
  color: var(--color-text-200, var(--color-text-300));
  font-size: 12px;
}

.todo-label {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.todo-marker {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--color-text-400);
  box-shadow: inset 0 0 0 1px hsl(var(--always-black) / 0.18);
  font-size: 10px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

.todo.in_progress { color: var(--color-text-100); }
.todo.in_progress .todo-marker { box-shadow: inset 0 0 0 1.5px var(--color-text-300); color: var(--color-text-100); }
.todo.in_progress.is-running .todo-marker::before {
  content: "";
  position: absolute;
  inset: -2px;
  border: 1.5px solid hsl(var(--accent-main-200) / 0.35);
  border-top-color: hsl(var(--accent-main-200));
  border-radius: inherit;
  animation: todo-spin 0.9s linear infinite;
}
.todo.completed { color: hsl(var(--text-500)); }
.todo.completed .todo-label { text-decoration: line-through; }
.todo.completed .todo-marker { background: hsl(var(--accent-main-200)); color: var(--color-bg-100); }

.transcript {
  order: 2;
  display: flex;
  flex: 1 1 auto;
  flex-direction: column;
  gap: 0;
  min-height: 0;
  overflow: auto;
  padding: 12px 20px 12px;
}

.scroll-bottom {
  position: absolute;
  right: 50%;
  bottom: 94px;
  z-index: 8;
  width: 32px;
  height: 32px;
  transform: translateX(50%);
  border: 0.5px solid var(--color-border-300);
  background: var(--color-bg-000);
  color: var(--color-text-300);
  padding: 0;
  font-size: 0;
  box-shadow: var(--shadow-soft);
  transition: background-color 0.15s, color 0.15s, transform 0.15s;
}

.scroll-bottom:hover,
.scroll-bottom:focus-visible {
  background: var(--color-bg-200);
  color: var(--color-text-100);
  outline: none;
}

.scroll-bottom:active { transform: translateX(50%) scale(0.96); }

.scroll-bottom::before {
  content: "↓";
  font-size: 16px;
  line-height: 1;
}

.message {
  display: flex;
  width: 100%;
  margin-bottom: 10px;
  color: var(--color-text-100);
}

.message.user {
  flex-direction: column;
  align-items: flex-end;
  gap: 8px;
}

.message.user .body {
  max-width: 82%;
  border-radius: 11px;
  background: hsl(var(--always-black) / 0.045);
  color: var(--color-text-000);
  padding: 10px 14px;
  font-size: 13px;
  line-height: 1.45;
  white-space: pre-wrap;
  word-break: break-word;
  box-shadow: 0 4px 24px 0 hsl(var(--always-black) / 0.02);
}

.message.assistant,
.message.error {
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-start;
}

.message.assistant .body,
.message.error .body {
  width: 100%;
  min-width: 0;
  color: var(--color-text-000);
  font-size: 13px;
  line-height: 1.58;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.message.assistant .body > :first-child { margin-top: 0; }

.message.assistant p {
  margin: 0 0 11px;
  text-wrap: pretty;
}

.message.assistant p:last-child,
.message.assistant .assistant-list:last-child,
.message.assistant .assistant-code-block:last-child,
.message.assistant .assistant-blockquote:last-child,
.message.assistant .assistant-table-wrap:last-child {
  margin-bottom: 0;
}

.assistant-actions {
  display: flex;
  width: auto;
  max-width: 100%;
  align-self: flex-start;
  align-items: center;
  gap: 4px;
  margin-top: 10px;
  padding-left: 1px;
  color: var(--color-text-400);
}

.assistant-action {
  display: inline-grid;
  width: 24px;
  height: 24px;
  place-items: center;
  border: 0;
  border-radius: 999px;
  background: transparent !important;
  color: var(--color-text-400) !important;
  padding: 0;
  box-shadow: none;
  cursor: pointer;
  font-weight: 400;
  line-height: 1;
  transition: color 0.15s, background-color 0.15s;
  appearance: none;
}

.assistant-action:hover,
.assistant-action:focus-visible {
  background: hsl(var(--always-black) / 0.045);
  color: var(--color-text-100);
  outline: none;
}

.assistant-action svg {
  width: 15px;
  height: 15px;
  display: block;
  overflow: visible;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.assistant-action svg path {
  fill: none !important;
  stroke: currentColor !important;
}

.assistant-actions[data-copied="true"] .assistant-action:first-child {
  color: var(--color-accent) !important;
}

.assistant-heading {
  margin: 0 0 8px;
  color: var(--color-text-100);
  font-family: var(--font-serif);
  font-size: 16px;
  font-weight: 500;
  line-height: 1.3;
  letter-spacing: -0.01em;
}

h1.assistant-heading { font-size: 18px; }

.assistant-list {
  margin: 0 0 12px;
  padding-left: 20px;
}

.assistant-list li {
  margin: 0 0 4px;
  padding-left: 2px;
}

.assistant-list li:last-child { margin-bottom: 0; }

.assistant-inline-code {
  border-radius: 4px;
  background: var(--color-bg-200);
  padding: 2px 4px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.92em;
  line-height: 1;
}

.assistant-code-block {
  margin: 0 0 12px;
  border-radius: 8px;
  background: var(--color-bg-200);
  padding: 12px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 12px;
  line-height: 1.45;
  white-space: pre-wrap;
  overflow-x: auto;
}

.assistant-table-wrap {
  margin: 16px 0;
  overflow: hidden;
  border: 0.5px solid var(--color-border-300);
  border-radius: 8px;
  background: var(--color-bg-000);
}

.assistant-table-wrap { overflow-x: auto; }

.assistant-table {
  width: 100%;
  min-width: 500px;
  border-collapse: collapse;
  font-size: 13px;
}

.assistant-table thead {
  border-bottom: 0.5px solid var(--color-border-300);
  background: var(--color-bg-100);
}

.assistant-table tr {
  border-top: 0.5px solid var(--color-border-300);
}

.assistant-table tr:first-child { border-top: 0; }

.assistant-table th,
.assistant-table td {
  min-width: 100px;
  max-width: 340px;
  border-right: 0.5px solid var(--color-border-300);
  padding: 10px 12px;
  text-align: left;
  vertical-align: top;
}

.assistant-table th:last-child,
.assistant-table td:last-child { border-right: 0; }

.assistant-table th {
  color: var(--color-text-300);
  font-weight: 600;
  white-space: nowrap;
}

.assistant-blockquote {
  margin: 0 0 12px;
  border-left: 4px solid var(--color-border-300);
  color: var(--color-text-300);
  padding-left: 12px;
  font-style: italic;
}

.message.assistant a {
  border: 0;
  background: transparent;
  color: var(--color-accent);
  padding: 0;
  text-decoration: underline;
  cursor: pointer;
}

.message.thinking {
  margin: 8px 0;
}

.message.thinking .body {
  width: 100%;
  color: var(--color-text-400);
  font-size: 12px;
  line-height: 1.45;
}

.thinking-block {
  min-width: 0;
  padding-bottom: 4px;
}

.thinking-title {
  display: flex;
  height: 2.625rem;
  align-items: center;
  color: var(--color-text-400);
  font-size: 12px;
  line-height: 1.35;
}

.thinking-content {
  position: relative;
  min-width: 0;
  max-height: 88px;
  overflow: hidden;
  color: var(--color-text-300);
  font-size: 12px;
  line-height: 1.45;
  transition: max-height 0.3s ease-out;
}

.thinking-content[data-expanded="true"] {
  max-height: 9999px;
}

.thinking-text {
  white-space: pre-wrap;
}

.thinking-fade {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  height: 40px;
  background: linear-gradient(to top, var(--color-bg-100), transparent);
  pointer-events: none;
}

.thinking-content[data-expanded="true"] .thinking-fade {
  display: none;
}

.thinking-toggle {
  margin-top: 4px;
  border: 0;
  background: transparent;
  color: var(--color-accent);
  padding: 0;
  font-size: 11px;
  line-height: 1.35;
  cursor: pointer;
}

.thinking-toggle:hover {
  text-decoration: underline;
}

.message.error .body { color: hsl(4 65% 42%); }
.message.tool { margin: 8px 0; }

.timeline-group {
  display: grid;
  gap: 0;
  min-width: 0;
  margin: 6px 0 8px;
  overflow: visible;
  padding-top: 4px;
  animation: timeline-fade-in 0.3s ease-in;
}

.timeline-details-toggle {
  display: inline-flex;
  max-width: 100%;
  align-items: center;
  gap: 6px;
  justify-self: start;
  border: 0;
  background: transparent;
  color: var(--color-text-400);
  padding: 2px 0 4px;
  text-align: left;
  font-size: 12px;
  line-height: 1.35;
  cursor: pointer;
  transition: color 0.3s ease-in;
}

.timeline-details-toggle:hover { color: var(--color-text-200); }

.timeline-details-toggle:disabled {
  color: var(--color-text-300);
  cursor: default;
}

.timeline-details-toggle:disabled .timeline-chevron { display: none; }

.timeline-activity-log {
  display: grid;
  gap: 12px;
  margin: 4px 0 8px;
  color: var(--color-text-400);
  font-size: 13.5px;
  line-height: 1.55;
}

.timeline-activity-line {
  min-width: 0;
  max-width: 100%;
  overflow: visible;
  overflow-wrap: anywhere;
  word-break: break-word;
  white-space: normal;
}

.timeline-details-toggle-text {
  min-width: 0;
  overflow: visible;
  overflow-wrap: anywhere;
  white-space: normal;
}

.timeline-chevron,
.tool-chevron {
  display: inline-flex;
  flex: 0 0 auto;
  color: var(--color-text-400);
  font-size: 13px;
  line-height: 1;
  transform: rotate(0deg);
  transition: transform 0.2s ease-out;
}

.timeline-details-toggle[aria-expanded="true"] .timeline-chevron,
.tool-header[aria-expanded="true"] .tool-chevron {
  transform: rotate(90deg);
}

.timeline-items {
  display: none;
  min-width: 0;
  overflow: visible;
  padding-left: 1px;
}

.timeline-items[data-expanded="true"] { display: block; }

.timeline-items-inner {
  min-width: 0;
  min-height: 0;
  overflow: visible;
}

.timeline-item {
  display: flex;
  min-height: 2.7rem;
  gap: 8px;
}

.timeline-active-line {
  display: inline-flex;
  min-width: 0;
  max-width: 100%;
  align-items: center;
  gap: 10px;
  margin: 10px 0 8px;
  color: var(--color-text-300);
  font-size: 13.5px;
  line-height: 1.45;
}

.timeline-active-spark {
  position: relative;
  display: inline-flex;
  width: 18px;
  height: 18px;
  flex: 0 0 18px;
  align-items: center;
  justify-content: center;
  border: 1.5px solid hsl(216 93% 78%);
  border-top-color: hsl(216 93% 58%);
  border-radius: 999px;
  animation: spin 0.9s linear infinite;
}

.timeline-active-spark::after {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: hsl(216 93% 66%);
}

.timeline-active-text {
  min-width: 0;
  overflow-wrap: anywhere;
  white-space: normal;
}

.timeline-rail {
  position: relative;
  display: flex;
  flex: 0 0 16px;
  justify-content: center;
}

.timeline-rail::before,
.timeline-rail::after {
  content: "";
  position: absolute;
  width: 1px;
  background: hsl(var(--always-black) / 0.15);
  transition: background-color 0.3s ease-in, opacity 0.3s ease-in;
}

.timeline-rail::before { top: 0; bottom: calc((2.7rem - 8px) / 2 + 4px); }
.timeline-rail::after { top: calc((2.7rem - 8px) / 2 + 12px); bottom: 0; }
.timeline-item[data-first="true"] .timeline-rail::before { display: none; }
.timeline-item[data-last="true"] .timeline-rail::after { display: none; }
.timeline-item[data-active="true"] .timeline-rail::before,
.timeline-item[data-active="true"] .timeline-rail::after {
  background: hsl(var(--accent-main-000) / 0.35);
}

.timeline-icon {
  z-index: 1;
  display: inline-flex;
  width: 16px;
  height: 24px;
  align-items: center;
  justify-content: center;
  align-self: flex-start;
  color: var(--color-text-400);
  font-size: 10px;
  font-weight: 700;
  transition: color 0.3s ease-in, transform 0.3s ease-in;
}

.timeline-icon::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: hsl(var(--always-black) / 0.15);
  transition: background-color 0.3s ease-in, box-shadow 0.3s ease-in, transform 0.3s ease-in;
}

.timeline-icon.complete::before,
.timeline-icon.error::before,
.timeline-icon.rejected::before {
  display: none;
}

.timeline-icon.pending::before,
.timeline-icon.running::before {
  background: var(--color-accent);
  box-shadow: 0 0 0 4px hsl(var(--accent-main-000) / 0.12);
}

.timeline-icon.running::before { transform: scale(1.08); }

.timeline-icon.error,
.timeline-icon.rejected { color: hsl(4 65% 42%); }

.timeline-icon.recovered { color: var(--color-text-400); }

.running-status {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 16px 0;
  color: var(--color-text-100);
  font-size: 13px;
}

.running-spark {
  position: relative;
  display: inline-flex;
  width: 32px;
  height: 32px;
  flex: 0 0 32px;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  color: var(--color-accent);
}

.running-spark::before,
.running-spark::after {
  content: "";
  position: absolute;
  border-radius: 999px;
}

.running-spark::before {
  width: 8px;
  height: 8px;
  background: var(--color-accent);
  box-shadow: 0 0 0 4px hsl(var(--accent-main-000) / 0.12);
  animation: pulse 1.2s ease-in-out infinite;
}

.running-spark::after {
  width: 18px;
  height: 18px;
  border: 1px solid hsl(var(--accent-main-000) / 0.55);
  border-top-color: transparent;
  animation: spin 1.1s linear infinite;
}

.running-status-text {
  min-width: 0;
  color: var(--color-text-300);
  font-size: 13px;
  line-height: 32px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.web-result-card,
.web-fetch-card {
  margin: 8px 0;
  overflow: hidden;
  border: 0.5px solid var(--color-border-200);
  border-radius: 10px;
  background: var(--color-bg-000);
}

.web-result-card.in-timeline,
.web-fetch-card.in-timeline {
  margin: 0;
}

.web-result-toggle {
  display: flex;
  width: 100%;
  min-height: 34px;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  border: 0;
  background: var(--color-bg-100);
  color: var(--color-text-300);
  padding: 8px 16px;
  text-align: left;
  cursor: pointer;
  transition: background-color 0.15s, color 0.15s;
}

.web-result-toggle:hover { background: var(--color-bg-200); }

.web-result-title-group {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 8px;
}

.web-result-search-icon {
  display: inline-flex;
  width: 16px;
  height: 16px;
  flex: 0 0 16px;
  align-items: center;
  justify-content: center;
  color: var(--color-text-300);
  font-size: 13px;
  line-height: 1;
}

.web-result-title {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 13px;
  line-height: 1.25;
}

.web-result-chevron {
  color: var(--color-text-400);
  font-size: 15px;
  line-height: 1;
  transform: rotate(-90deg);
  transition: transform 0.2s ease-out;
}

.web-result-toggle[aria-expanded="true"] .web-result-chevron { transform: rotate(0deg); }

.web-result-list {
  border-top: 0.5px solid var(--color-border-200);
  background: var(--color-bg-000);
}

.web-result-row,
.web-fetch-card {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  color: var(--color-text-100);
  text-decoration: none;
}

.web-result-row {
  padding: 12px 16px;
  border-bottom: 0.5px solid var(--color-border-200);
  background: transparent;
  transition: background-color 0.15s;
}

.web-result-row:last-child { border-bottom: 0; }
.web-result-row:hover { background: var(--color-bg-100); }

.web-result-icon,
.web-fetch-icon {
  display: inline-flex;
  width: 16px;
  height: 16px;
  flex: 0 0 16px;
  align-items: center;
  justify-content: center;
  margin-top: 2px;
  color: var(--color-text-400);
  font-size: 12px;
}

.web-result-row > span:last-child,
.web-fetch-text {
  display: grid;
  min-width: 0;
  gap: 3px;
}

.web-result-row span span,
.web-fetch-text span {
  overflow: hidden;
  color: var(--color-text-100);
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 13px;
  line-height: 1.25;
}

.web-result-row small,
.web-fetch-text small {
  overflow: hidden;
  color: var(--color-text-400);
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 11px;
}

.web-fetch-card {
  min-height: 34px;
  padding: 8px 16px;
  background: var(--color-bg-100);
  transition: background-color 0.15s;
}

.web-fetch-card:not(.error):hover { background: var(--color-bg-200); }

.web-fetch-card.error .web-fetch-icon,
.web-fetch-card.error .web-fetch-text span { color: hsl(4 65% 42%); }

.tool-card {
  display: grid;
  min-width: 0;
  max-width: 100%;
  min-height: 2.2rem;
  overflow: hidden;
  border: 0.5px solid var(--color-border-300);
  border-radius: 8px;
  background: transparent;
  color: var(--color-text-300);
  font-size: 13px;
}

.tool-card.in-timeline {
  width: 100%;
  border: 0;
  border-radius: 0;
  overflow: visible;
}

.tool-header {
  display: grid;
  width: 100%;
  min-height: 2.45rem;
  align-items: center;
  justify-content: flex-start;
  grid-template-columns: auto minmax(0, 1fr) auto auto;
  gap: 7px;
  border: 0;
  background: transparent;
  color: var(--color-text-300);
  padding: 5px 10px;
  text-align: left;
  cursor: pointer;
  transition: color 0.2s, background-color 0.2s;
}

.tool-header:hover {
  color: var(--color-text-000);
  background: hsl(var(--always-black) / 0.015);
}

.tool-card.in-timeline .tool-header {
  grid-template-columns: minmax(0, 1fr) auto auto;
  padding: 3px 0 5px;
  min-width: 0;
}

.tool-card.in-timeline .tool-title,
.tool-card.in-timeline .tool-result-preview {
  overflow: visible;
  text-overflow: clip;
  white-space: normal;
  overflow-wrap: anywhere;
}

.tool-status-icon {
  display: inline-flex;
  width: 18px;
  height: 18px;
  flex: 0 0 18px;
  align-items: center;
  justify-content: center;
  color: var(--color-text-400);
  font-size: 12px;
  line-height: 1;
}

.tool-status-icon::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: currentColor;
  opacity: 0.6;
}

.tool-status-icon.running::before {
  border: 1px solid var(--color-text-400);
  border-top-color: transparent;
  background: transparent;
  opacity: 1;
  animation: spin 0.9s linear infinite;
}

.tool-status-icon.complete,
.tool-status-icon.error { font-size: 13px; }

.tool-status-icon.complete::before,
.tool-status-icon.error::before { content: none; }

.tool-status-icon.complete { color: var(--color-text-400); }
.tool-status-icon.error { color: hsl(4 65% 42%); }

.tool-text {
  display: grid;
  min-width: 0;
  gap: 2px;
}

.tool-title {
  min-width: 0;
  overflow: hidden;
  color: var(--color-text-300);
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 12.5px;
  font-weight: 550;
  line-height: 1.32;
}

.tool-title.error { color: hsl(4 65% 42%); }
.tool-title.recovered { color: var(--color-text-400); }

.tool-result-preview {
  min-width: 0;
  overflow: hidden;
  color: var(--color-text-400);
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 11.5px;
  font-weight: 400;
  line-height: 1.35;
}

.tool-result-preview.error {
  color: hsl(4 60% 42%);
}

.tool-name-chip {
  flex: 0 1 auto;
  min-width: 0;
  overflow: hidden;
  border: 0.5px solid var(--color-border-300);
  border-radius: 999px;
  background: hsl(var(--bg-100) / 0.55);
  color: var(--color-text-400);
  padding: 1px 6px;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1.35;
}

.tool-header:hover .tool-name-chip {
  border-color: var(--color-border-200);
  color: var(--color-text-300);
}

.tool-meta {
  overflow: hidden;
  max-width: 76px;
  color: var(--color-text-400);
  font-size: 11px;
  font-variant-numeric: tabular-nums;
  opacity: 0.72;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.tool-meta:empty,
.tool-meta[hidden] { display: none; }

.tool-details-panel {
  display: grid;
  overflow: hidden;
  grid-template-rows: 0fr;
  transition: grid-template-rows 0.3s ease-in-out;
}

.tool-details-panel[data-expanded="true"] { grid-template-rows: 1fr; }

.tool-details-inner {
  min-height: 0;
  overflow: hidden;
  padding: 0 10px 10px;
}

.tool-details-panel[data-expanded="false"] .tool-details-inner {
  padding: 0;
}

.tool-details-panel pre {
  max-height: 300px;
  margin: 0;
  overflow: auto;
  border: 0.5px solid var(--color-border-300);
  border-radius: 8px;
  background: transparent;
  padding: 12px;
  color: var(--color-text-300);
  font-size: 11px;
  line-height: 1.45;
}

.tool-card.in-timeline .tool-details-inner { padding: 0 0 12px; }
.tool-card.in-timeline .tool-details-panel[data-expanded="false"] .tool-details-inner { padding: 0; }

.tool-summary-details {
  display: grid;
  gap: 7px;
  min-width: 0;
  border-left: 1px solid var(--color-border-300);
  margin: 2px 0 4px;
  padding-left: 10px;
  color: var(--color-text-400);
  font-size: 12.5px;
  line-height: 1.45;
}

.tool-summary-row {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr);
  gap: 8px;
  min-width: 0;
}

.tool-summary-key {
  color: var(--color-text-500);
  font-size: 11.5px;
}

.tool-summary-value {
  min-width: 0;
  overflow-wrap: anywhere;
  white-space: normal;
}

.tool-raw-details {
  margin-top: 10px;
  color: var(--color-text-400);
}

.tool-raw-details summary {
  cursor: pointer;
  font-size: 11.5px;
}

.tool-raw-details pre {
  margin-top: 6px;
}

.message-details summary {
  cursor: pointer;
  color: var(--color-text-400);
  font-weight: 600;
}

.sources-card {
  margin-top: 6px;
  overflow: hidden;
  border: 0.5px solid var(--color-border-300);
  border-radius: 8px;
  background: hsl(var(--bg-100) / 0.45);
}

.sources-card summary {
  padding: 6px 8px;
  color: var(--color-text-400);
  font-size: 12px;
  font-weight: 500;
  line-height: 1.35;
  transition: background-color 0.15s, color 0.15s;
}

.sources-card summary:hover {
  background: var(--color-bg-200);
  color: var(--color-text-100);
}

.sources-card pre {
  margin: 0;
  border-top: 0.5px solid var(--color-border-300);
  border-radius: 0;
  background: transparent;
  color: var(--color-text-300);
  font-size: 11px;
}

pre {
  max-height: 220px;
  overflow: auto;
  border-radius: 10px;
  background: var(--color-bg-200);
  color: var(--color-text-100);
  padding: 8px;
  white-space: pre-wrap;
}

.history-popover {
  position: absolute;
  top: 42px;
  right: 8px;
  z-index: 20;
  display: grid;
  width: 18rem;
  max-height: min(520px, calc(100vh - 120px));
  overflow-y: auto;
  border: 0.5px solid var(--color-border-200);
  border-radius: 16px;
  background: hsl(var(--bg-000) / 0.98);
  padding: 6px;
  color: var(--color-text-300);
  box-shadow: 0 4px 18px 0 hsl(var(--always-black) / 0.08);
  backdrop-filter: blur(12px);
  animation: popover-enter 0.16s ease-out;
}

.settings-overlay {
  position: absolute;
  inset: 0;
  z-index: 30;
  display: flex;
  flex-direction: column;
  overflow: auto;
  background: var(--color-bg-100);
  animation: settings-slide-in 0.2s cubic-bezier(0.25, 0.1, 0.25, 1);
}

.panel-header,
.settings-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.settings-header {
  justify-content: flex-start;
  gap: 8px;
  padding: 24px 24px 0;
}

.settings-header .icon-button {
  width: 28px;
  height: 28px;
  margin-left: -4px;
  border-radius: 8px;
  padding: 4px;
  color: var(--color-text-300);
  font-size: 20px;
  line-height: 1;
  transition: background-color 0.15s, color 0.15s;
}

.settings-header .icon-button:hover {
  background: var(--color-bg-200);
  color: var(--color-text-100);
}

.settings-header h2 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 22px;
  font-weight: 600;
  letter-spacing: -0.02em;
}

.settings-section {
  display: flex;
  flex-direction: column;
  gap: 30px;
  padding: 30px 24px 24px;
}

.settings-group {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.settings-group-emphasis {
  gap: 14px;
  padding: 16px 16px 14px;
  border-top: 1px solid var(--color-border-300);
  border-bottom: 1px solid var(--color-border-200);
  background: var(--color-bg-100);
  box-shadow: inset 0 1px 0 hsl(var(--always-white) / 0.72);
}

.settings-group-emphasis .settings-field {
  gap: 10px;
}

.panel-actions,
.history-actions,
.permission-actions,
.elicitation-actions,
.actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
}

.history-popover-header,
.history-popover-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 5px 6px 8px;
}

.history-popover-header strong {
  color: var(--color-text-100);
  font-size: 13px;
  font-weight: 650;
}

.history-popover-footer {
  min-height: 33px;
  border-top: 0.5px solid var(--color-border-200);
  padding: 6px 6px 2px;
}

.history-popover-spacer { display: block; min-height: 24px; }

.history-new,
.history-delete-all {
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: var(--color-text-400);
  padding: 4px 6px;
  font-size: 12px;
  transition: background-color 0.15s, color 0.15s;
}

.history-new:hover,
.history-delete-all:hover {
  background: var(--color-bg-200);
  color: var(--color-text-100);
}

.history-delete-all { color: hsl(4 65% 42%); }

.history-list {
  display: grid;
  gap: 2px;
  color: var(--color-text-400);
  font-size: 13px;
}

.history-empty {
  padding: 20px 8px;
  color: var(--color-text-500);
  font-size: 13px;
  line-height: 1.35;
  text-align: center;
}

.history-item {
  position: relative;
  display: flex;
  align-items: center;
  gap: 8px;
  border-radius: 8px;
  color: var(--color-text-300);
  transition: background-color 0.15s, color 0.15s, transform 0.12s;
}

.history-item:hover,
.history-item:focus-within {
  background: var(--color-bg-200);
  color: var(--color-text-000);
}

.history-item:active { transform: scale(0.995); }

.history-load {
  display: flex;
  flex: 1;
  min-width: 0;
  min-height: 34px;
  align-items: center;
  gap: 8px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: inherit;
  padding: 7px 8px;
  text-align: left;
}

.history-title {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  color: inherit;
  font-size: 13px;
  font-weight: 400;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.history-time {
  flex-shrink: 0;
  color: var(--color-text-400);
  font-size: 12px;
}

.history-delete {
  position: absolute;
  right: 4px;
  display: inline-flex;
  width: 24px;
  height: 24px;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: var(--color-text-400);
  padding: 0;
  opacity: 0;
  transition: opacity 0.15s, background-color 0.15s, color 0.15s;
}

.history-item:hover .history-delete,
.history-delete:focus { opacity: 1; }

.history-delete:hover,
.history-delete.active {
  background: var(--color-bg-300);
  color: hsl(4 65% 42%);
}

.history-delete.active {
  opacity: 1;
  filter: brightness(0.92);
}

.history-confirm-overlay,
.chat-confirm-overlay {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: flex;
  align-items: center;
  justify-content: center;
  background: hsl(var(--always-black) / 0.38);
  padding: 16px;
  backdrop-filter: blur(2px);
  animation: overlay-fade-in 0.16s ease-out;
}

.history-confirm-dialog,
.chat-confirm-dialog {
  width: min(100%, 26rem);
  border: 0.5px solid var(--color-border-300);
  border-radius: 16px;
  background: var(--color-bg-000);
  padding: 20px;
  box-shadow: 0 8px 30px hsl(var(--always-black) / 0.12);
  animation: dialog-enter 0.18s ease-out;
}

.history-confirm-dialog:focus,
.chat-confirm-dialog:focus { outline: none; }

.history-confirm-dialog h3,
.chat-confirm-dialog h3 {
  margin: 0 0 8px;
  color: var(--color-text-100);
  font-family: var(--font-serif);
  font-size: 18px;
  font-weight: 500;
  line-height: 1.3;
}

.history-confirm-dialog p,
.chat-confirm-dialog p {
  margin: 0 0 18px;
  color: var(--color-text-400);
  font-size: 13px;
  line-height: 1.45;
}

.history-confirm-actions,
.chat-confirm-actions {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
}

.history-confirm-delete,
.chat-confirm-continue {
  min-height: 30px;
  border-radius: 8px;
  background: hsl(4 65% 42%);
  color: var(--color-bg-000);
  padding: 6px 12px;
  font-size: 12px;
  font-weight: 600;
  transition: filter 0.15s, transform 0.15s;
}

.chat-confirm-continue { background: var(--color-text-100); }

.history-confirm-delete:hover,
.chat-confirm-continue:hover { filter: brightness(0.92); }

.history-confirm-delete:active,
.chat-confirm-continue:active { transform: scale(0.98); }

.chat-confirm-cancel.active,
.history-confirm-cancel.active {
  background: var(--color-bg-300);
  color: var(--color-text-100);
}

.chat-confirm-continue.active,
.history-confirm-delete.active {
  filter: brightness(0.88);
}

.setting-toggle,
.text-size-control,
.settings-field {
  display: grid;
  gap: 8px;
  border: 0;
  border-radius: 0;
  background: transparent;
  padding: 0;
}

.setting-toggle,
.text-size-control {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
  gap: 16px;
  min-height: 28px;
}

.setting-toggle > span,
.text-size-control > span,
.settings-field > span {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.setting-toggle strong,
.text-size-control strong,
.settings-field > span {
  color: var(--color-text-000);
  font-size: 14px;
  font-weight: 600;
  line-height: 1.25;
}

.setting-toggle small,
.text-size-control small,
.settings-field small {
  color: var(--color-text-400);
  font-size: 12px;
  font-weight: 400;
  line-height: 1.3;
}

.settings-field textarea {
  min-height: 124px;
  border: 0.5px solid var(--color-border-300);
  border-radius: 10px;
  background: var(--color-bg-000);
  color: var(--color-text-100);
  padding: 10px 12px;
  margin-top: 5px;
  font-size: 14px;
  line-height: 1.45;
  transition: border-color 0.15s, box-shadow 0.15s, background-color 0.15s;
}

.settings-field textarea::placeholder {
  color: var(--color-text-400);
  opacity: 0.75;
}

.settings-field textarea:focus {
  border-color: hsl(var(--accent-main-000) / 0.45);
  box-shadow: 0 0 0 3px hsl(var(--accent-main-000) / 0.08);
  outline: none;
}

.settings-tabs {
  display: inline-flex;
  gap: 6px;
  align-self: start;
  padding: 3px;
  border: 0.5px solid var(--color-border-300);
  border-radius: 10px;
  background: var(--color-bg-100);
}

.settings-tab {
  min-width: 72px;
  min-height: 30px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--color-text-400);
  padding: 6px 12px;
  font-size: 13px;
  font-weight: 500;
  transition: background-color 0.15s, color 0.15s;
}

.settings-tab[data-active="true"] {
  background: var(--color-bg-000);
  color: var(--color-text-100);
  box-shadow: 0 1px 2px hsl(var(--always-black) / 0.06);
}

.settings-input-group {
  display: grid;
  gap: 5px;
}

.settings-input-group strong {
  color: var(--color-text-000);
  font-size: 13px;
  font-weight: 600;
}

.settings-input-group small {
  color: var(--color-text-400);
  font-size: 12px;
  line-height: 1.3;
}

.settings-input {
  min-height: 38px;
  border: 0.5px solid var(--color-border-300);
  border-radius: 10px;
  background: var(--color-bg-000);
  color: var(--color-text-100);
  padding: 0 12px;
  font-size: 14px;
  transition: border-color 0.15s, box-shadow 0.15s, background-color 0.15s;
}

.settings-input::placeholder {
  color: var(--color-text-400);
  opacity: 0.75;
}

.settings-input:focus {
  border-color: hsl(var(--accent-main-000) / 0.45);
  box-shadow: 0 0 0 3px hsl(var(--accent-main-000) / 0.08);
  outline: none;
}

.settings-save {
  justify-self: start;
  min-height: 29px;
  border-width: 0.5px;
  border-radius: 7px;
  margin-top: 1px;
  padding: 5px 11px;
  font-size: 12px;
  font-weight: 600;
  transition: background-color 0.15s, border-color 0.15s, color 0.15s;
}

.settings-save:hover,
.settings-save:focus-visible {
  background: var(--color-bg-200);
  outline: none;
}

.settings-delete-history {
  min-height: 29px;
  border-width: 0.5px;
  border-radius: 7px;
  padding: 5px 11px;
  color: hsl(4 65% 42%);
  font-size: 12px;
  font-weight: 600;
  transition: background-color 0.15s, border-color 0.15s, filter 0.15s;
}

.settings-delete-history:hover,
.settings-delete-history:focus-visible {
  background: var(--color-bg-200);
  outline: none;
}

.text-size-stepper {
  display: inline-flex;
  align-items: center;
  overflow: hidden;
  border: 0.5px solid var(--color-border-300);
  border-radius: 6px;
  background: var(--color-bg-000);
}

.text-size-button {
  display: inline-flex;
  width: 28px;
  height: 28px;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: 0;
  background: transparent;
  color: var(--color-text-100);
  padding: 0;
  font-size: 15px;
  font-weight: 600;
  transition: background-color 0.15s;
}

.text-size-button:hover:not(:disabled),
.text-size-button:focus-visible {
  background: var(--color-bg-200);
  outline: none;
}

.text-size-value {
  min-width: 44px;
  color: var(--color-text-100);
  padding: 0 8px;
  font-size: 12px;
  font-weight: 600;
  line-height: 28px;
  text-align: center;
  font-variant-numeric: tabular-nums;
}

.setting-switch {
  appearance: none;
  width: 36px;
  height: 20px;
  flex: 0 0 auto;
  border: 0;
  border-radius: 999px;
  background: var(--color-border-300);
  cursor: pointer;
  transition: background-color 0.2s;
}

.setting-switch::before {
  content: "";
  display: block;
  width: 16px;
  height: 16px;
  margin: 2px;
  border-radius: 999px;
  background: var(--color-bg-000);
  box-shadow: 0 1px 3px hsl(var(--always-black) / 0.2);
  transition: transform 0.2s;
}

.setting-switch:checked {
  background: hsl(var(--accent-main-000));
}

.setting-switch:focus-visible {
  outline: 2px solid hsl(var(--accent-main-000) / 0.32);
  outline-offset: 2px;
}

.setting-switch:checked::before { transform: translateX(16px); }
.setting-switch:disabled { cursor: not-allowed; opacity: 0.45; }

@keyframes popover-enter {
  from { opacity: 0; transform: translateY(-4px) scale(0.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes empty-state-enter {
  from { opacity: 0; transform: translateY(4px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes settings-slide-in {
  from { opacity: 0; transform: translateX(40px); }
  to { opacity: 1; transform: translateX(0); }
}

@keyframes overlay-fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes dialog-enter {
  from { opacity: 0; transform: translateY(6px) scale(0.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes permission-slide-up {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes todos-enter {
  from { opacity: 0; transform: translateY(4px); }
  to { opacity: 1; transform: translateY(0); }
}

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

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

@keyframes pulse {
  0%, 100% { transform: scale(0.95); opacity: 0.72; }
  50% { transform: scale(1.08); opacity: 1; }
}

@keyframes elicitation-slide-in {
  from { opacity: 0; transform: translateX(12px); }
  to { opacity: 1; transform: translateX(0); }
}

@keyframes timeline-fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes notice-enter {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}

.update-notice {
  order: 9;
  z-index: 19;
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin: 0 10px 6px;
  border: 0.5px solid var(--color-border-200);
  border-radius: 13px;
  background: hsl(var(--bg-000) / 0.96);
  color: var(--color-text-300);
  padding: 8px 10px 8px 12px;
  font-size: 12px;
  line-height: 1.3;
  box-shadow: 0 5px 24px hsl(var(--always-black) / 0.06);
  animation: notice-enter 0.18s ease-out;
}

.update-notice span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.update-notice-action {
  min-height: 24px;
  flex: 0 0 auto;
  border: 0.5px solid var(--color-border-300);
  background: var(--color-bg-000);
  color: var(--color-text-100);
  padding: 3px 9px;
  font-size: 12px;
  font-weight: 600;
}

.update-notice-action:hover,
.update-notice-action:focus-visible {
  background: var(--color-bg-200);
  outline: none;
}

.composer {
  order: 10;
  position: relative;
  z-index: 20;
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  gap: 0;
  margin: 0 8px 8px;
  border: 0.5px solid var(--color-border-300);
  border-radius: 18px;
  background: var(--color-bg-000);
  padding: 0;
  box-shadow: 0 5px 26px 0 hsl(var(--always-black) / 0.05);
  transition: border-color 0.15s, box-shadow 0.15s, background-color 0.15s;
}

.composer::after {
  position: absolute;
  inset: 6px;
  z-index: 5;
  display: grid;
  place-items: center;
  border: 1px dashed hsl(var(--accent-main-000) / 0.38);
  border-radius: 12px;
  background: hsl(var(--bg-000) / 0.88);
  color: var(--color-text-300);
  content: "Drop files to attach";
  font-size: 12px;
  font-weight: 500;
  opacity: 0;
  pointer-events: none;
  transform: scale(0.985);
  transition: opacity 0.15s ease-out, transform 0.15s ease-out;
}

.composer[data-drop-active="true"] {
  border-color: hsl(var(--accent-main-000) / 0.38);
  background: hsl(var(--bg-000) / 0.96);
  box-shadow: 0 4px 24px 0 hsl(var(--always-black) / 0.07);
}

.composer[data-drop-active="true"]::after {
  opacity: 1;
  transform: scale(1);
}

.composer:focus-within {
  border-color: hsl(var(--accent-main-000) / 0.28);
  background: hsl(var(--bg-000) / 0.99);
  box-shadow: 0 4px 20px 0 hsl(var(--always-black) / 0.05), 0 0 0 1px hsl(var(--accent-main-000) / 0.08);
}

.composer:focus-within textarea::placeholder {
  color: var(--color-text-300);
}

textarea {
  width: 100%;
  min-height: 36px;
  max-height: 50vh;
  overflow-y: auto;
  scrollbar-width: none;
  resize: none;
  border: 0;
  background: transparent;
  color: var(--color-text-100);
  padding: 14px 14px 4px;
  font-size: 13px;
  line-height: 1.45;
}

textarea::-webkit-scrollbar { display: none; }

textarea:focus { outline: none; }
textarea::placeholder { color: var(--color-text-400); }

.actions {
  min-height: 36px;
  align-items: center;
  justify-content: space-between;
  padding: 0 10px 9px;
  gap: 8px;
}

.actions > :first-child { margin-right: 0; }
.actions > :not(:first-child) { margin-left: 2px; }

.actions::before {
  order: 1;
  display: inline-flex;
  max-width: min(46vw, 180px);
  min-height: 26px;
  align-items: center;
  overflow: hidden;
  border: 0.5px solid var(--color-border-200);
  border-radius: 999px;
  background: var(--color-bg-100);
  color: var(--color-text-300);
  padding: 4px 9px;
  content: "Excel";
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 12px;
  font-weight: 550;
  line-height: 1;
  margin-right: auto;
}

.composer .composer-icon {
  order: 2;
  width: 29px;
  height: 29px;
  border-radius: 999px;
  transition: background-color 0.15s, color 0.15s, opacity 0.15s, transform 0.12s;
}

.composer .composer-icon:active:not(:disabled) { transform: scale(0.96); }

.composer #attach {
  order: 0;
}

.composer-icon.send {
  background: var(--color-text-100);
  color: var(--color-bg-000);
  box-shadow: 0 1px 2px hsl(var(--always-black) / 0.08);
}

.composer-icon.send:hover:not(:disabled) { opacity: 0.9; }

.attachments,
.queued-messages {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  padding: 14px 14px 0;
}

.attachments:not([hidden]) {
  padding-bottom: 2px;
}

.queued-messages { justify-content: flex-end; }

.attachments:not([hidden]) + .queued-messages,
.queued-messages:not([hidden]) {
  padding-top: 6px;
}

.attachment-chip {
  display: inline-flex;
  max-width: 100%;
  min-height: 31px;
  align-items: center;
  gap: 7px;
  border: 0.5px solid var(--color-border-300);
  border-radius: 10px;
  background: var(--color-bg-100);
  color: var(--color-text-300);
  padding: 4px 6px 4px 5px;
  font-size: 12px;
}

.attachment-icon {
  display: inline-flex;
  width: 22px;
  height: 22px;
  flex: 0 0 22px;
  align-items: center;
  justify-content: center;
  border-radius: 7px;
  background: var(--color-bg-300);
  color: var(--color-text-300);
  font-size: 12px;
}

.attachment-label {
  display: grid;
  min-width: 0;
  gap: 1px;
}

.attachment-label strong {
  overflow: hidden;
  max-width: 180px;
  color: var(--color-text-100);
  font-size: 12px;
  font-weight: 500;
  line-height: 1.1;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.attachment-label small {
  color: var(--color-text-400);
  font-size: 11px;
  line-height: 1;
}

.attachment-chip button {
  display: inline-flex;
  width: 20px;
  height: 20px;
  align-items: center;
  justify-content: center;
  flex: 0 0 20px;
  border: 0;
  background: transparent;
  color: var(--color-text-400);
  padding: 0;
  opacity: 0.75;
}

.attachment-chip button:hover {
  background: var(--color-bg-200);
  color: var(--color-text-000);
  opacity: 1;
}

.queued-message {
  display: flex;
  min-height: 38px;
  width: 100%;
  max-width: 85%;
  align-items: flex-start;
  align-self: flex-end;
  gap: 2px;
  border-radius: 12px;
  background: var(--color-bg-300);
  color: var(--color-text-000);
  box-shadow: 0 4px 24px 0 hsl(var(--always-black) / 0.02);
  font-size: 14px;
  line-height: 1.35;
}

.queued-edit {
  min-width: 0;
  flex: 1 1 auto;
  border: 0;
  border-radius: 12px;
  background: transparent;
  color: inherit;
  padding: 11px 8px 11px 20px;
  text-align: left;
  font-size: inherit;
  font-weight: 400;
  line-height: inherit;
}

.queued-edit:hover { background: transparent; }

.queued-edit > span {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.queued-remove {
  display: inline-flex;
  width: 24px;
  height: 24px;
  align-items: center;
  justify-content: center;
  flex: 0 0 24px;
  margin: 7px 6px 0 0;
  border: 0;
  background: transparent;
  color: var(--color-text-400);
  padding: 0;
  font-size: 14px;
  font-weight: 500;
}

.queued-remove:hover {
  background: hsl(var(--always-black) / 0.04);
  color: var(--color-text-000);
}

.commands,
.plus-menu {
  position: absolute;
  bottom: calc(100% + 8px);
  z-index: 50;
  display: grid;
  gap: 2px;
  max-height: 280px;
  overflow: auto;
  border: 0.5px solid var(--color-border-200);
  background: var(--color-bg-000);
  padding: 6px;
  color: var(--color-text-300);
  box-shadow: 0 2px 8px 0 hsl(var(--always-black) / 0.08);
  isolation: isolate;
  animation: popover-enter 0.14s ease-out;
}

.commands {
  right: 0;
  left: 0;
  border-radius: 16px;
}

.plus-menu {
  right: auto;
  left: 0;
  width: max-content;
  min-width: 208px;
  max-width: min(320px, calc(100vw - 16px));
  border-radius: 16px;
}

.commands[hidden],
[hidden] { display: none !important; }

.command-item,
.plus-menu-item {
  display: grid;
  align-items: center;
  min-height: 32px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--color-text-300);
  padding: 6px 8px;
  text-align: left;
  cursor: pointer;
  transition: background-color 0.15s, color 0.15s, opacity 0.15s;
}

.command-item {
  grid-template-columns: minmax(0, 1fr);
  gap: 0;
  width: 100%;
}

.plus-menu-item {
  grid-template-columns: 20px minmax(0, 1fr) 16px;
  gap: 12px;
  width: 100%;
}

.menu-label {
  display: grid;
  min-width: 0;
  gap: 1px;
}
.menu-icon {
  display: inline-flex;
  width: 20px;
  height: 20px;
  align-items: center;
  justify-content: center;
  color: var(--color-text-300);
  text-align: center;
}

.menu-trailing {
  justify-self: end;
  color: var(--color-text-400);
  font-size: 16px;
  line-height: 1;
}

.command-item:hover,
.command-item:focus,
.command-item[data-selected="true"],
.plus-menu-item:hover,
.plus-menu-item:focus {
  background: var(--color-bg-200);
  outline: none;
}

.command-item[data-selected="true"] { background: var(--color-bg-200); }

.command-content {
  display: flex;
  min-width: 0;
  flex-direction: column;
  overflow: hidden;
}

.command-content strong,
.plus-menu-item strong {
  overflow: hidden;
  color: var(--color-text-100);
  font-size: 14px;
  font-weight: 400;
  line-height: 1.3;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.command-content small,
.menu-label small {
  overflow: hidden;
  color: var(--color-text-400);
  font-size: 12px;
  line-height: 1.25;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.menu-label small[hidden] { display: none; }
.plus-menu-item:disabled { opacity: 0.45; cursor: default; }
.plus-menu-item:disabled .menu-trailing { opacity: 0.6; }
.plus-menu-item:disabled:hover { background: transparent; }

.permission,
.elicitation {
  order: 7;
  flex: 0 0 auto;
  z-index: 10;
}

.permission-card {
  position: relative;
  z-index: 25;
  display: grid;
  gap: 0;
  max-height: min(52vh, 360px);
  margin: 8px 12px 8px;
  overflow: auto;
  border: 0.5px solid var(--color-border-300);
  border-radius: 14px;
  background: hsl(var(--bg-000) / 0.98);
  padding: 0;
  box-shadow: 0 4px 14px hsl(var(--always-black) / 0.12);
  backdrop-filter: blur(10px);
  animation: permission-slide-up 0.18s ease-out;
}

.permission-header {
  display: flex;
  align-items: center;
  gap: 8px;
  border-bottom: 0.5px solid var(--color-border-300);
  padding: 10px 16px;
}

.permission-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  color: var(--color-text-100);
  font-size: 14px;
  font-weight: 700;
}

.permission-header h2 {
  margin: 0;
  color: var(--color-text-100);
  font-size: 14px;
  font-weight: 400;
  line-height: 1.4;
}

.permission-summary {
  margin: 16px 16px 0;
  padding: 0;
  color: var(--color-text-100);
  font-size: 14px;
  font-weight: 650;
  line-height: 1.35;
}

.permission-details {
  margin: 8px 16px 0;
  color: var(--color-text-400);
  font-size: 12px;
}

.permission-details summary {
  cursor: pointer;
  transition: color 0.15s;
}

.permission-details summary:hover { color: var(--color-text-100); }

.permission-details pre {
  max-height: 120px;
  overflow: auto;
  border: 0.5px solid var(--color-border-300);
  border-radius: 8px;
  background: transparent;
  padding: 10px;
  font-size: 11px;
  line-height: 1.45;
}

.permission-input-summary {
  display: grid;
  gap: 7px;
  margin-top: 8px;
  border-left: 1px solid var(--color-border-300);
  padding-left: 10px;
  color: var(--color-text-300);
  line-height: 1.45;
}

.permission-input-row {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr);
  gap: 8px;
}

.permission-input-key {
  color: var(--color-text-500);
  font-size: 11px;
}

.permission-input-value {
  min-width: 0;
  overflow-wrap: anywhere;
  white-space: normal;
}

.permission-raw-details {
  margin-top: 10px;
}

.permission-raw-details pre {
  margin-top: 6px;
}

.permission-security-warning,
.permission-warning-card {
  margin: 8px 12px 0;
  border-radius: 8px;
  background: var(--color-bg-200);
  padding: 10px 12px;
  color: var(--color-text-300);
}

.permission-security-warning,
.permission-warning-header {
  display: flex;
  align-items: center;
  gap: 6px;
}

.permission-security-warning {
  align-items: flex-start;
  border: 0.5px solid hsl(4 60% 45% / 0.28);
  background: hsl(4 62% 44% / 0.12);
  color: hsl(4 48% 34%);
}

.permission-security-content {
  display: flex;
  min-width: 0;
  flex: 1;
  flex-direction: column;
  gap: 8px;
}

.permission-security-warning p {
  margin: 0;
  white-space: pre-wrap;
  font-size: 13px;
  line-height: 1.35;
}

.permission-security-link {
  display: inline-flex;
  align-self: flex-start;
  align-items: center;
  border: 0.5px solid hsl(4 60% 45% / 0.28);
  border-radius: 6px;
  color: currentColor;
  padding: 4px 8px;
  font-size: 11px;
  font-weight: 600;
  line-height: 1;
  text-decoration: none;
  transition: background-color 0.15s;
}

.permission-security-link:hover,
.permission-security-link:focus-visible {
  background: hsl(4 60% 45% / 0.08);
  outline: none;
}

.permission-warning-card.high {
  border: 0.5px solid hsl(4 60% 45% / 0.28);
  background: hsl(4 62% 44% / 0.12);
  color: hsl(4 48% 34%);
}

.permission-warning-header {
  font-size: 12px;
  font-weight: 700;
  line-height: 1.25;
}

.permission-warning-icon {
  display: inline-flex;
  width: 16px;
  height: 16px;
  flex: 0 0 16px;
  align-items: center;
  justify-content: center;
  color: currentColor;
  font-size: 12px;
  font-weight: 700;
}

.permission-warning-list {
  display: flex;
  max-height: 128px;
  flex-direction: column;
  gap: 2px;
  overflow-y: auto;
  margin-top: 4px;
  margin-left: 22px;
  color: var(--color-text-300);
  font-size: 12px;
  line-height: 1.35;
}

.permission-warning-card.high .permission-warning-list,
.permission-security-warning .permission-warning-list { color: currentColor; }

.permission-warning-list span {
  white-space: pre-wrap;
}

.permission-warning-more {
  align-self: flex-start;
  border: 0;
  background: transparent;
  color: var(--color-text-500);
  padding: 1px 0 0;
  font: inherit;
  font-size: 11px;
  text-align: left;
  transition: color 0.15s;
}

.permission-warning-more:hover,
.permission-warning-more:focus-visible {
  color: var(--color-text-300);
  outline: none;
}

.permission-actions {
  display: grid;
  gap: 5px;
  margin-top: 10px;
  margin-bottom: 2px;
  padding: 10px 12px;
}

.permission-action {
  display: flex;
  width: 100%;
  min-height: 32px;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  border: 0.5px solid var(--color-border-200);
  border-radius: 8px;
  background: transparent;
  color: var(--color-text-100);
  padding: 3px 14px;
  font-size: 13px;
  font-weight: 500;
  line-height: 1.35;
  transition: background-color 0.15s, border-color 0.15s, color 0.15s;
}

.permission-action > span {
  min-width: 0;
  overflow: hidden;
  text-align: left;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.permission-action:hover,
.permission-action:focus-visible {
  background: var(--color-bg-100);
  outline: none;
}
.permission-action.active {
  border-color: hsl(var(--border-300) / 0.25);
  background: var(--color-bg-300);
  color: var(--color-text-100);
}
.permission-action.primary {
  border-color: hsl(var(--border-300) / 0.08);
  background: var(--color-bg-200);
  color: var(--color-text-000);
}
.permission-action.primary:hover,
.permission-action.primary:focus-visible,
.permission-action.primary.active { background: var(--color-bg-300); }
.permission-action.primary.active { border-color: hsl(var(--border-300) / 0.25); }

.permission-shortcut {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 4px;
  pointer-events: none;
}

.permission-action kbd {
  display: inline-flex;
  min-width: 20px;
  height: 20px;
  align-items: center;
  justify-content: center;
  border-radius: 4px;
  background: var(--color-bg-300);
  color: var(--color-text-400);
  padding: 0 4px;
  font-family: inherit;
  font-size: 11px;
  font-weight: 500;
  line-height: 1;
}

.permission-footnote {
  margin: -4px 13px 11px;
  padding: 0 1px;
  color: var(--color-text-500);
  font-size: 10px;
  line-height: 1.35;
}

.permission-card p,
.elicitation-question p { margin: 0; }

.elicitation-card {
  position: fixed;
  right: 8px;
  bottom: calc(var(--composer-safe-inset, 96px) + env(safe-area-inset-bottom, 0px));
  left: 8px;
  z-index: 1000;
  display: grid;
  max-height: min(70vh, calc(100vh - 128px));
  grid-template-rows: auto minmax(0, 1fr) auto;
  gap: 0;
  margin: 0;
  overflow: hidden;
  border: 0.5px solid var(--color-border-300);
  border-radius: 20px;
  background: hsl(var(--bg-000) / 0.97);
  padding: 12px 0 0;
  box-shadow: 0 -0.25rem 1.35rem hsl(var(--always-black) / 0.08);
  backdrop-filter: blur(12px);
}

.elicitation-title-row {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 12px 4px 20px;
}

.elicitation-title-row h2 {
  flex: 1;
  margin: 0;
  color: var(--color-text-100);
  font-size: 14px;
  font-weight: 500;
  line-height: 1.35;
}

.elicitation-minimize {
  width: 20px;
  height: 20px;
  flex-shrink: 0;
  border: 0;
  background: transparent;
  color: hsl(var(--text-500));
  padding: 0;
  font-size: 14px;
  transition: color 0.15s;
}

.elicitation-minimize:hover,
.elicitation-minimize:focus-visible {
  background: transparent;
  color: hsl(var(--text-200));
  outline: none;
}

.elicitation-body {
  display: grid;
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-color: hsl(var(--text-500) / 0.35) transparent;
  scrollbar-width: thin;
  gap: 0;
  padding: 6px;
  box-shadow: inset 0 10px 10px -12px hsl(var(--always-black) / 0.22), inset 0 -10px 10px -12px hsl(var(--always-black) / 0.22);
}

.elicitation-body::-webkit-scrollbar { width: 8px; }

.elicitation-body::-webkit-scrollbar-track { background: transparent; }

.elicitation-body::-webkit-scrollbar-thumb {
  border: 2px solid transparent;
  border-radius: 999px;
  background: hsl(var(--text-500) / 0.32);
  background-clip: content-box;
}

.elicitation-question {
  display: flex;
  flex-direction: column;
  gap: 4px;
  margin-bottom: 0;
}

.elicitation-header {
  padding: 0 14px 4px;
  color: var(--color-text-400);
  font-size: 11px;
  font-weight: 500;
}

.elicitation-options {
  display: grid;
  gap: 0;
}

.elicitation-divider {
  height: 0.5px;
  margin: 0 12px;
  background: var(--color-border-300);
  transition: opacity 0.15s;
}

.elicitation-divider.hidden {
  opacity: 0;
}

.elicitation-option,
.elicitation-custom {
  display: flex;
  min-height: 44px;
  flex-direction: row;
  align-items: center;
  gap: 12px;
  border: 0;
  border-radius: 16px;
  background: transparent;
  color: var(--color-text-300);
  padding: 0 12px;
  text-align: left;
  transition: transform 0.1s, background-color 0.15s, color 0.15s;
}

.elicitation-option:hover,
.elicitation-option:focus,
.elicitation-option.active,
.elicitation-custom:hover,
.elicitation-custom:focus,
.elicitation-custom:focus-within,
.elicitation-custom.active {
  background: var(--color-bg-200);
  color: var(--color-text-000);
  outline: none;
}

.elicitation-option:active,
.elicitation-custom:active { transform: scale(0.99); }

.elicitation-option-indicator {
  display: inline-flex;
  width: 24px;
  height: 24px;
  flex: 0 0 24px;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  background: var(--color-bg-300);
  color: var(--color-text-500);
  font-size: 12px;
}

.elicitation-option-copy {
  display: grid;
  min-width: 0;
  gap: 1px;
}

.elicitation-option strong {
  min-width: 0;
  overflow: hidden;
  color: inherit;
  font-size: 14px;
  font-weight: 400;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.elicitation-option-copy > span {
  overflow: hidden;
  color: var(--color-text-400);
  font-size: 11px;
  line-height: 1.25;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.elicitation-option-trailing {
  margin-left: auto;
  color: hsl(var(--text-100) / 0.5);
  font-size: 14px;
}

.elicitation-option.selected,
.elicitation-custom.has-value {
  background: var(--color-bg-200);
  color: var(--color-text-000);
}

.elicitation-option.selected .elicitation-option-indicator,
.elicitation-option:hover .elicitation-option-indicator,
.elicitation-option:focus .elicitation-option-indicator,
.elicitation-option.active .elicitation-option-indicator,
.elicitation-custom:hover .elicitation-option-indicator,
.elicitation-custom:focus .elicitation-option-indicator,
.elicitation-custom:focus-within .elicitation-option-indicator,
.elicitation-custom.active .elicitation-option-indicator,
.elicitation-custom.has-value .elicitation-option-indicator {
  background: var(--color-bg-300);
  color: var(--color-text-100);
}

.elicitation-custom-input {
  min-width: 0;
  flex: 1;
  border: 0;
  background: transparent;
  color: var(--color-text-100);
  padding: 0;
  font-size: 14px;
  outline: none;
}

.elicitation-custom-input::placeholder {
  color: var(--color-text-500);
  opacity: 0.6;
}

.elicitation-custom-submit {
  display: inline-flex;
  width: 32px;
  height: 32px;
  align-items: center;
  justify-content: center;
  flex: 0 0 32px;
  border-radius: 8px;
  background: var(--color-text-100);
  color: var(--color-bg-000);
  padding: 0;
  opacity: 0;
  transition: opacity 0.15s, background-color 0.15s, filter 0.15s;
}

.elicitation-custom.has-value .elicitation-custom-submit,
.elicitation-custom:focus-within .elicitation-custom-submit { opacity: 1; }

.elicitation-custom-submit:hover { filter: opacity(0.9); }

.elicitation-custom-submit:focus-visible {
  outline: none;
  filter: opacity(0.9);
}

.elicitation-actions {
  min-height: 50px;
  flex: 0 0 50px;
  align-items: center;
  justify-content: flex-end;
  border-top: 0.5px solid var(--color-border-300);
  padding: 0 18px 1px 24px;
}

.elicitation-selected-count {
  margin-right: auto;
  color: var(--color-text-500);
  font-size: 14px;
}

.elicitation-skip {
  height: 28px;
  border: 0;
  border-radius: 8px;
  background: var(--color-bg-200);
  color: var(--color-text-300);
  padding: 0 12px;
  font-size: 12px;
  transition: background-color 0.15s, color 0.15s;
}

.elicitation-skip:hover,
.elicitation-skip:focus-visible {
  background: var(--color-bg-300);
  outline: none;
}

.elicitation-next {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  padding: 0;
  font-size: 14px;
  line-height: 1;
}
