.ai-analyst-container {
  position: fixed;
  top: 80px; /* adjust based on your header */
  right: 0;
  height: calc(100% - 200px);
  width: 0;
  transition: width 0.3s ease-in-out;
  z-index: 100;
}

.ai-analyst-container.open {
  width: 420px;
}

.ai-toggle-btn {
  // position: absolute;
  // right: 5px;
  cursor: pointer;
}

.ai-panel {
  height: 100%;
  background: #fff;
  border-left: 1px solid #ddd;
  display: flex;
  flex-direction: column;
  padding: 15px;
  border-radius: 8px;
}

.ai-header {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  padding: 12px;
  // background: var(--action-primary-default);
  // color: #fff;
  font-weight: bold;
}

.ai-chat-window {
  flex: 1;
  padding: 12px;
  overflow-y: auto;
  // background: #f9f9f9;
}

.chat-message {
  margin-bottom: 10px;
  max-width: 80%;
}

.chat-message.user {
  text-align: right;
  margin-left: auto;
}

.chat-message.ai {
  text-align: left;
  margin-right: auto;
}

.message-text {
  display: inline-block;
  padding: 8px 12px;
  border-radius: 12px;
  background: #e0e0e0;
  font-size: 14px;
}

.chat-message.user .message-text {
  background: var(--action-primary-default);
  color: #fff;
}

.ai-input {
  display: flex;
  padding: 8px;
  border-top: 1px solid #ddd;
  background: #fff;
}
.ai-input input {
  flex: 1;
  border: none;
  outline: none;
  padding: 8px;
}

// .insights-section {
//   // background: #f5f5f5;
//   // padding: 12px;
//   // border-bottom: 1px solid #ccc;
// }

.insights-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.insights-content {
  margin: 5px 0px 5px 0px;
  font-size: 14px;
  color: #444;
  background: #f1fcf8;
  border-radius: 5px;
  padding: 10px 12px 10px 12px;
}

.collapsed-insights {
  text-align: center;
  padding: 8px;
}

.chat-section {
  flex-grow: 1;
  overflow-y: auto;
  // padding: 10px;
}

.messages {
  flex: 1;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.ai-chart-img {
  width: 100%;
  max-width: 1000px;   
  height: auto;
  margin-top: 14px;
  border-radius: 8px;
  image-rendering: auto;
}
