/* Generic assistant window. No vendor chrome. Quiet tokens. */
.ask-window {
  display: flex;
  flex-direction: column;
  width: 100%;
  max-width: 760px;
  min-height: 468px;
  margin: 0;
  text-align: left;
  background: var(--white);
  border: 1px solid var(--hairline);
  border-radius: var(--radius-panel);
  box-shadow: var(--shadow-soft);
  overflow: hidden;
}
.ask-window__bar {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  border-bottom: 1px solid var(--hairline);
  background: var(--surface);
}
.ask-window__dots {
  display: flex;
  gap: 6px;
}
.ask-window__dots i {
  display: block;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #d0cecc;
}
.ask-window__name {
  font-size: 13px;
  font-weight: 600;
  color: var(--ink);
}
.ask-window__chip {
  margin-left: auto;
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--amber-wash);
  color: var(--amber-deep);
  font-size: 12px;
  font-weight: 600;
}
.ask-window__body {
  display: grid;
  grid-template-columns: 168px 1fr;
  flex: 1;
  min-height: 0;
}
.ask-window__rail {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 12px 10px;
  background: var(--surface);
  border-right: 1px solid var(--hairline);
  font-size: 13px;
  color: var(--body);
}
.ask-window__rail-new {
  padding: 8px 10px;
  margin-bottom: 8px;
  border: 1px solid var(--hairline);
  border-radius: 10px;
  background: var(--white);
  color: var(--ink);
  font-weight: 500;
}
.ask-window__rail-item {
  padding: 8px 10px;
  border-radius: 10px;
}
.ask-window__rail-item.is-current {
  background: var(--white);
  color: var(--ink);
  font-weight: 500;
}
.ask-window__thread {
  display: flex;
  flex-direction: column;
  min-height: 0;
  padding: 20px;
  gap: 16px;
}
.ask-window__msgs {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-height: 0;
}
.ask-msg {
  max-width: 78%;
  padding: 12px 16px;
  border-radius: 16px;
  font-size: 15px;
  line-height: 1.5;
}
.ask-msg--user {
  align-self: flex-end;
  background: var(--ink);
  color: var(--white);
  border-bottom-right-radius: 6px;
}
.ask-msg--bot {
  align-self: flex-start;
  background: var(--surface);
  color: var(--ink);
  border-bottom-left-radius: 6px;
}
.ask-msg--bot p { margin: 0 0 10px; }
.ask-msg--bot p:last-child { margin-bottom: 0; }
.ask-msg--bot strong {
  font-weight: 600;
}
.ask-msg--load {
  display: inline-flex;
  align-items: center;
  width: fit-content;
  max-width: none;
  padding: 14px 16px;
}
.ask-msg__dots {
  display: flex;
  gap: 5px;
}
.ask-msg__dots i {
  display: block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--muted);
}
.ask-window__composer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex: none;
  margin: 0;
  padding: 10px 12px 10px 16px;
  border: 1px solid var(--hairline);
  border-radius: 22px;
  font-size: 14px;
}
.ask-window__field {
  flex: 1;
  min-width: 0;
  line-height: 1.4;
}
.ask-window__hint { color: var(--muted); }
.ask-window__typed { color: var(--ink); }
.ask-window__caret {
  display: inline-block;
  width: 1.5px;
  height: 0.95em;
  margin-left: 1px;
  background: var(--ink);
  vertical-align: -0.1em;
}
.ask-window__caret[hidden] { display: none; }
.ask-window__send {
  flex: none;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--ink);
  color: var(--white);
  display: grid;
  place-items: center;
}
.ask-window__send svg {
  width: 14px;
  height: 14px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

@media (max-width: 900px) {
  .ask-window__body { grid-template-columns: 1fr; }
  .ask-window__rail { display: none; }
  .ask-window__thread { min-height: 0; }
}

@media (prefers-reduced-motion: no-preference) {
  .ask-window {
    transition: box-shadow 140ms ease;
  }
  .ask-window__send.is-sending { animation: ask-send-pulse 360ms ease; }
  .ask-window__caret { animation: ask-caret 1s steps(1) infinite; }
  .ask-msg__dots i { animation: ask-dot 1.05s ease-in-out infinite; }
  .ask-msg__dots i:nth-child(2) { animation-delay: 0.15s; }
  .ask-msg__dots i:nth-child(3) { animation-delay: 0.3s; }
}
@keyframes ask-send-pulse {
  0% { transform: scale(1); }
  32% { transform: scale(0.86); }
  100% { transform: scale(1); }
}
@keyframes ask-caret {
  50% { opacity: 0; }
}
@keyframes ask-dot {
  0%, 80%, 100% { opacity: 0.28; transform: translateY(0); }
  40% { opacity: 1; transform: translateY(-3px); }
}
