/* Chat modal specific styles (scoped via .chat-modal-root) */

.chat-modal-root {
  /* prevent iOS overscroll glow */
  overscroll-behavior: contain;
}

/* Safe area helpers */
.chat-safe-bottom {
  padding-bottom: calc(env(safe-area-inset-bottom, 0px) + 16px);
}

/* Scrollbar (messages + session list) */
.chat-scrollbar {
  scrollbar-width: none; /* Firefox */
  -ms-overflow-style: none; /* IE/Edge legacy */
}

.chat-scrollbar::-webkit-scrollbar {
  width: 0;
  height: 0;
}

/* Markdown rendering inside messages */
.chat-markdown a {
  color: rgba(34, 211, 238, 0.92);
  text-decoration: underline;
  text-underline-offset: 3px;
}

.chat-markdown a:active {
  opacity: 0.9;
}

.chat-markdown code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New",
    monospace;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.08);
  padding: 0.1rem 0.4rem;
  border-radius: 0.5rem;
  font-size: 0.9em;
}

.chat-markdown img {
  margin-top: 10px;
  max-width: 100%;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 0 12px 34px rgba(0, 0, 0, 0.45);
}

/* Utility: single-line truncation */
.chat-ellipsis {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
