/* ---------------------------------------------------------- */
/*                  Dramatically Different Design                  */
/* ---------------------------------------------------------- */

@import url('https://fonts.googleapis.com/css2?family=Open+Sans:ital,wght@0,300;0,400;0,500;0,600;0,700;1,400;1,600&display=swap');

*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  /* Ana Renk Değişkenleri - Logo Tonlarına Uygun */
  --color-background: #f5f3f7;
  --color-text: #2d1b36;
  --color-primary: #8b5a9f;
  --color-primary-rgb: 139, 90, 159;
  --color-primary-hover: #7a4d8c;
  --color-accent-bg: #f0ebf2;
  --color-accent-border: #d4bfdd;
  --color-white: #ffffff;
  --color-gray-text: #6b4c7a;
  --color-success: #7b9f35;
  --color-success-rgb: 123, 159, 53;
  --color-error: #cc4f72;
  --color-error-rgb: 204, 79, 114;

  /* Gölge Renkleri */
  --color-shadow: rgba(45, 27, 54, 0.12);
  --shadow-sm: 0 1px 3px var(--color-shadow);
  --shadow-md: 0 4px 8px var(--color-shadow);
  --shadow-lg: 0 8px 16px var(--color-shadow);
  --shadow-xl: 0 12px 24px var(--color-shadow);

  /* Diğer değişkenler aynı kalır */
  --rounded-sm: 4px;
  --rounded-md: 8px;
  --rounded-lg: 12px;
  --rounded-xl: 16px;
  --transition-fast: 150ms ease;
  --transition-normal: 250ms ease;

  background-color: var(--color-background);
  color: var(--color-text);
  transition: background-color 0.3s ease, color 0.3s ease;
}


/* ---------------------------------------------------------- */
/*                          Layout                            */
/* ---------------------------------------------------------- */

.container {
  display: flex;
  height: 100vh;
  width: 100%;
  margin: 0 auto;
  background-color: var(--color-background);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
}

/* Left Panel */
.left-panel {
  flex: 0 0 300px;
  min-width: 250px;
  max-width: 350px;
  padding: 1.5rem;
  background-color: var(--color-white);
  border-right: 1px solid var(--color-accent-border);
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-md);
  z-index: 2;
}

.left-panel .panel-header {
  margin-bottom: 1.5rem;
  padding-bottom: 0.75rem;
  border-bottom: 2px solid var(--color-primary);
}

.left-panel .panel-header h3 {
  color: var(--color-primary);
  font-size: 1.25rem;
  font-weight: 600;
  letter-spacing: 0.5px;
}

.documents-container {
  flex-grow: 1;
  overflow-y: auto;
  padding-right: 0.5rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.status-message {
  color: var(--color-gray-text);
  font-size: 0.9rem;
  text-align: center;
  padding: 2rem 0;
  font-style: italic;
}

/* Document cards */
.document {
  margin-bottom: 0.5rem;
  padding: 1.25rem;
  background-color: var(--color-white);
  border-radius: var(--rounded-lg);
  border-left: 4px solid var(--color-primary);
  box-shadow: var(--shadow-sm);
  transition: all var(--transition-normal);
}

.document:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

.document h4 {
  color: var(--color-primary);
  font-size: 1rem;
  margin-bottom: 0.75rem;
  font-weight: 600;
}

.document p {
  color: var(--color-gray-text);
  font-size: 0.95rem;
  line-height: 1.6;
  margin-bottom: 0.75rem;
}

.expand-button {
  background-color: var(--color-accent-bg);
  color: var(--color-primary);
  border: none;
  border-radius: var(--rounded-md);
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.expand-button:hover {
  background-color: var(--color-primary);
  color: var(--color-white);
}

/* Middle Panel */
.middle-panel {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-width: 400px;
  background-color: var(--color-background);
  overflow: hidden;
  position: relative;
  z-index: 1;
}

.chat-history {
  flex-grow: 1;
  padding: 2rem;
  overflow-y: auto;
  background-image: radial-gradient(circle at center, rgba(var(--color-primary-rgb), 0.03) 0%, transparent 70%);
}

/* Chat input */
.chat-input-container {
  padding: 1.5rem;
  background-color: var(--color-white);
  position: sticky;
  bottom: 0;
  z-index: 100;
  box-shadow: 0 -4px 12px rgba(9, 30, 66, 0.05);
}

.chat-input-wrapper {
  display: flex;
  gap: 1rem;
  align-items: flex-end;
  background-color: var(--color-white);
  border-radius: var(--rounded-xl);
  box-shadow: var(--shadow-md);
  transition: all var(--transition-normal);
  border: 1px solid var(--color-accent-border);
  overflow: hidden;
}

.chat-input {
  flex-grow: 1;
  padding: 1.25rem;
  border: none;
  resize: none;
  font-family: inherit;
  font-size: 1rem;
  line-height: 1.5;
  min-height: 60px;
  background-color: var(--color-white);
  color: var(--color-text);
}

/* Send Button Alignment Fix */
.chat-input-wrapper {
  display: flex;
  align-items: stretch;
  /* Make all children stretch to the same height */
  height: 60px;
  /* Consistent fixed height */
  overflow: hidden;
}

.chat-input {
  flex-grow: 1;
  height: 100%;
  /* Full height of parent */
  padding: 1rem 1.25rem;
}

.send-button {
  height: 100%;
  /* Full height of parent */
  padding: 0 1.5rem;
  /* Horizontal padding only */
  display: flex;
  align-items: center;
  justify-content: center;
}

.chat-input:focus {
  outline: none;
}

.send-button {
  padding: 1rem 1.5rem;
  background-color: var(--color-primary);
  color: var(--color-white);
  border: none;
  cursor: pointer;
  font-weight: 500;
  transition: all var(--transition-fast);
  height: 100%;
  font-size: 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.send-button:hover {
  background-color: var(--color-primary-hover);
}

/* Right Panel */
.right-panel {
  flex: 0 0 300px;
  min-width: 250px;
  max-width: 300px;
  padding: 1.5rem;
  background-color: var(--color-white);
  border-left: 1px solid var(--color-accent-border);
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-md);
  z-index: 2;
}

.logo-container {
  text-align: center;
  margin: 1.5rem auto;
  width: 80%;
  max-width: 220px;
  /* background: transparent; */
  padding: 0;
}

.logo-container img {
  width: 100%;
  max-width: 120px;
  height: auto;
  /* filter: drop-shadow(0 4px 6px rgba(0, 0, 0, 0.1));
  transition: transform var(--transition-normal); */
}

/* .logo-container img:hover {
  transform: scale(1.05) rotate(5deg);
} */

/* Right panel links and buttons */
.right-panel a,
.right-panel #clearMemoryButton {
  display: block;
  padding: 0.75rem 1rem;
  background-color: var(--color-accent-bg);
  color: var(--color-primary);
  text-decoration: none;
  border-radius: var(--rounded-md);
  font-weight: 500;
  text-align: center;
  margin-bottom: 1rem;
  transition: all var(--transition-fast);
  border: none;
  width: 100%;
  font-family: inherit;
  font-size: 1rem;
  cursor: pointer;
}

.right-panel a:hover,
.right-panel #clearMemoryButton:hover {
  background-color: var(--color-primary);
  color: var(--color-white);
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
}

/* Message Styling */
.message {
  margin-bottom: 1.5rem;
  font-size: 1rem;
  line-height: 1.6;
  max-width: 85%;
  display: flex;
  align-items: flex-start;
  gap: 1rem;
}

.message-icon {
  flex-shrink: 0;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background-color: var(--color-primary);
  color: var(--color-white);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  font-size: 1.2em;
  margin-top: 0.25rem;
  box-shadow: var(--shadow-md);
}

.message-content {
  flex: 1;
  padding: 1.25rem;
  border-radius: var(--rounded-lg);
  box-shadow: var(--shadow-md);
}

/* User message */
.user-message {
  flex-direction: row-reverse;
  margin-left: auto;
  width: fit-content;
}

.user-message .message-content {
  background-color: var(--color-primary);
  color: var(--color-white);
  border-top-right-radius: 0;
}

.user-message .message-icon {
  background-color: var(--color-accent-bg);
  color: var(--color-primary);
}

/* Bot message */
.bot-message {
  margin-right: auto;
}

.bot-message .message-content {
  background-color: var(--color-white);
  color: var(--color-text);
  border-top-left-radius: 0;
}

.bot-message .message-content h1,
.bot-message .message-content h2,
.bot-message .message-content h3 {
  margin: 1rem 0 0.5rem;
  color: var(--color-primary);
  font-weight: 600;
}

.bot-message .message-content p {
  margin: 0.5rem 0;
  line-height: 1.6;
}

.bot-message .message-content strong {
  font-weight: 600;
  color: var(--color-primary);
}

.bot-message .message-content ol,
.bot-message .message-content ul {
  margin: 0.75rem 0;
  padding-left: 1.75rem;
}

.bot-message .message-content li {
  margin: 0.5rem 0;
  line-height: 1.6;
}

.bot-message .message-content code {
  background-color: #f5f7f9;
  padding: 0.125rem 0.375rem;
  border-radius: var(--rounded-sm);
  font-family: 'Courier New', monospace;
  font-size: 0.9em;
  color: #333;
}

.bot-message .message-content pre {
  background-color: #252b37;
  color: #e3e8f1;
  padding: 1.25rem;
  border-radius: var(--rounded-md);
  overflow-x: auto;
  margin: 0.75rem 0;
}

.bot-message .message-content pre code {
  background-color: transparent;
  padding: 0;
  color: inherit;
}

/* Thinking message */
.thinking-message {
  color: var(--color-gray-text);
  margin-right: auto;
  font-style: italic;
  position: relative;
}

.thinking-message em:after {
  content: '';
  animation: ellipsis 1.5s infinite;
}

@keyframes ellipsis {
  0% {
    content: '';
  }

  25% {
    content: '.';
  }

  50% {
    content: '..';
  }

  75% {
    content: '...';
  }

  100% {
    content: '';
  }
}

/* Feedback Container */
.feedback-container {
  padding: 1.5rem;
  background-color: var(--color-accent-bg);
  border-radius: var(--rounded-lg);
  margin-top: 1.5rem;
  box-shadow: var(--shadow-sm);
}

.feedback-container h3 {
  color: var(--color-primary);
  margin-bottom: 1.25rem;
  font-size: 1.1rem;
  font-weight: 600;
  text-align: center;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--color-primary);
}

.feedback-item {
  margin-bottom: 1.25rem;
}

.feedback-item label {
  display: block;
  color: var(--color-text);
  font-size: 0.95rem;
  margin-bottom: 0.75rem;
  font-weight: 500;
}

.button-group {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  justify-content: center;
}

.feedback-btn {
  background-color: var(--color-white);
  color: var(--color-text);
  border: 1px solid var(--color-accent-border);
  border-radius: var(--rounded-md);
  padding: 0.5rem 0.75rem;
  font-size: 0.85rem;
  cursor: pointer;
  transition: all var(--transition-fast);
  min-width: 40px;
  text-align: center;
}

.feedback-btn:hover {
  border-color: var(--color-primary);
  color: var(--color-primary);
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
}

.feedback-btn.selected {
  background-color: var(--color-primary);
  color: var(--color-white);
  border-color: var(--color-primary);
  box-shadow: var(--shadow-md);
}

.feedback-comment {
  width: 100%;
  min-height: 80px;
  padding: 0.75rem;
  font-family: inherit;
  border: 1px solid var(--color-accent-border);
  border-radius: var(--rounded-md);
  font-size: 0.95rem;
  line-height: 1.5;
  resize: vertical;
  margin-bottom: 0.5rem;
  background-color: var(--color-white);
  color: var(--color-text);
  transition: all var(--transition-fast);
}

.feedback-comment:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 2px rgba(var(--color-primary-rgb), 0.2);
}

.save-feedback-button {
  width: 100%;
  padding: 0.875rem;
  background-color: var(--color-primary);
  color: var(--color-white);
  border: none;
  border-radius: var(--rounded-md);
  cursor: pointer;
  font-size: 0.95rem;
  font-weight: 500;
  transition: all var(--transition-fast);
  margin-top: 0.5rem;
}

.save-feedback-button:hover {
  background-color: var(--color-primary-hover);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.feedback-status {
  font-size: 0.85rem;
  margin-top: 0.75rem;
  text-align: center;
  opacity: 0;
  transition: opacity var(--transition-normal);
  border-radius: var(--rounded-sm);
  padding: 0.5rem;
}

.feedback-status.success {
  color: var(--color-success);
  opacity: 1;
  background-color: rgba(var(--color-success-rgb), 0.1);
}

.feedback-status.error {
  color: var(--color-error);
  opacity: 1;
  background-color: rgba(var(--color-error-rgb), 0.1);
}

/* Form related styles */
.form-container {
  padding: 1.25rem;
  margin: 0.75rem 0;
  border-radius: var(--rounded-md);
  background-color: var(--color-accent-bg);
  border: 1px solid var(--color-accent-border);
}

.form-title {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 0.75rem;
  color: var(--color-primary);
}

.form-download-container {
  background-color: var(--color-white);
  border-radius: var(--rounded-md);
  padding: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  box-shadow: var(--shadow-sm);
}

.form-preview {
  color: var(--color-gray-text);
  font-size: 0.9rem;
  padding: 0.75rem;
  background-color: var(--color-accent-bg);
  border-radius: var(--rounded-sm);
}

.download-form-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1rem;
  background-color: var(--color-primary);
  color: var(--color-white);
  border: none;
  border-radius: var(--rounded-md);
  cursor: pointer;
  font-size: 0.9rem;
  font-weight: 500;
  transition: all var(--transition-fast);
  text-decoration: none;
  box-shadow: var(--shadow-sm);
}

.download-form-btn:hover {
  background-color: var(--color-primary-hover);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.download-icon {
  width: 1.25rem;
  height: 1.25rem;
}

/* Dark Mode Theme */
body.dark-mode {
  --color-background: #1a0f1f;
  --color-text: #e8dfe9;
  --color-primary: #a66bb8;
  --color-primary-rgb: 166, 107, 184;
  --color-primary-hover: #b879c7;
  --color-accent-bg: #2a1f2d;
  --color-accent-border: #453750;
  --color-white: #2a1f2d;
  --color-gray-text: #b294bd;
  --color-shadow: rgba(0, 0, 0, 0.4);
}

body.dark-mode .message-content {
  background-color: #2a3042;
}

body.dark-mode .bot-message .message-content {
  background-color: #2d3748;
  color: #e2e8f0;
}

body.dark-mode .user-message .message-content {
  background-color: #2b4380;
}

body.dark-mode .chat-input,
body.dark-mode .feedback-comment {
  background-color: #2d3748;
  color: #e2e8f0;
}

body.dark-mode .chat-input-wrapper {
  background-color: #2d3748;
  border-color: #4a5568;
}

body.dark-mode .document,
body.dark-mode .form-download-container {
  background-color: #2d3748;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.2);
}

body.dark-mode .bot-message .message-content code {
  background-color: #1a202c;
  color: #e2e8f0;
}

/* Mode Toggle Button */
.mode-toggle-container {
  margin-top: auto;
  padding: 1.5rem 0;
  text-align: center;
}

.mode-toggle-button {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  border: none;
  cursor: pointer;
  background-color: var(--color-accent-bg);
  box-shadow: var(--shadow-md);
  transition: all var(--transition-normal);
  display: flex;
  align-items: center;
  justify-content: center;
}

.mode-toggle-button:hover {
  transform: scale(1.1) rotate(15deg);
}

.toggle-icon {
  font-size: 1.5rem;
  transition: transform var(--transition-normal);
}

/* Custom scrollbar */
::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: var(--color-accent-bg);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb {
  background: var(--color-primary);
  border-radius: 4px;
  transition: background 0.2s ease;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--color-primary-hover);
}

/* Settings page styles */
.settings-container {
  flex: 1;
  padding: 2.5rem;
  background-color: var(--color-background);
  overflow-y: auto;
}

.settings-container h2 {
  font-size: 1.75rem;
  font-weight: 700;
  color: var(--color-primary);
  margin-bottom: 2rem;
  padding-bottom: 0.75rem;
  border-bottom: 3px solid var(--color-primary);
  display: inline-block;
}

.settings-form {
  display: flex;
  flex-direction: column;
  gap: 2rem;
  max-width: 800px;
  background-color: var(--color-white);
  padding: 2rem;
  border-radius: var(--rounded-lg);
  box-shadow: var(--shadow-lg);
}

.settings-form label {
  font-weight: 500;
  display: block;
  margin-bottom: 0.75rem;
  color: var(--color-primary);
  font-size: 1rem;
}

.settings-form input,
.settings-form textarea,
.settings-form select {
  padding: 0.875rem 1.25rem;
  border: 2px solid var(--color-accent-border);
  border-radius: var(--rounded-md);
  font-size: 1rem;
  background-color: var(--color-accent-bg);
  color: var(--color-text);
  transition: all var(--transition-fast);
  box-shadow: var(--shadow-sm);
}

.settings-form input:focus,
.settings-form textarea:focus,
.settings-form select:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 3px rgba(var(--color-primary-rgb), 0.2);
}

.settings-form input[type="number"] {
  width: 150px;
}

.settings-form textarea {
  min-height: 180px;
  resize: vertical;
  line-height: 1.5;
}

.settings-form select {
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
  background-repeat: no-repeat;
  background-position: right 1rem center;
  background-size: 1em;
  padding-right: 3rem;
  width: 100%;
  max-width: 400px;
}

.model-select,
#ollama_model_name {
  width: 100%;
  max-width: 400px;
}

.settings-form button[type="submit"] {
  padding: 1rem 2rem;
  background-color: var(--color-primary);
  color: var(--color-white);
  border: none;
  border-radius: var(--rounded-md);
  cursor: pointer;
  font-size: 1rem;
  font-weight: 600;
  transition: all var(--transition-fast);
  align-self: flex-start;
  margin-top: 1rem;
  box-shadow: var(--shadow-md);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.settings-form button[type="submit"]:hover {
  background-color: var(--color-primary-hover);
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
}

.status-message {
  margin-top: 1.5rem;
  padding: 1rem 1.5rem;
  border-radius: var(--rounded-md);
  text-align: center;
  opacity: 0;
  transition: opacity var(--transition-normal);
  font-size: 1rem;
  box-shadow: var(--shadow-sm);
}

.status-message.success {
  color: #fff;
  opacity: 1;
  background-color: var(--color-success);
}

.status-message.error {
  color: #fff;
  opacity: 1;
  background-color: var(--color-error);
}

.navigation-buttons {
  display: flex;
  gap: 1rem;
  margin-bottom: 2rem;
}

.navigation-buttons a {
  display: inline-block;
  padding: 0.75rem 1.5rem;
  background-color: var(--color-white);
  color: var(--color-primary);
  text-decoration: none;
  border-radius: var(--rounded-md);
  transition: all var(--transition-fast);
  font-weight: 600;
  box-shadow: var(--shadow-sm);
}

.navigation-buttons a:hover {
  background-color: var(--color-primary);
  color: var(--color-white);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

/* Responsive adjustments */
@media (max-width: 1200px) {

  .right-panel,
  .left-panel {
    flex: 0 0 250px;
    min-width: 220px;
    max-width: 250px;
  }
}

@media (max-width: 992px) {

  .right-panel,
  .left-panel {
    flex: 0 0 220px;
    min-width: 200px;
    max-width: 220px;
    padding: 1rem;
  }

  .middle-panel {
    min-width: 300px;
  }

  .message {
    max-width: 95%;
  }
}

@media (max-width: 768px) {
  .container {
    flex-direction: column;
  }

  .left-panel,
  .middle-panel,
  .right-panel,
  .settings-container {
    flex: none;
    width: 100%;
    max-width: 100%;
    min-width: 100%;
    border: none;
  }

  .left-panel {
    max-height: 300px;
    order: 1;
    border-bottom: 1px solid var(--color-accent-border);
  }

  .middle-panel {
    order: 2;
    flex: 1;
  }

  .right-panel {
    order: 3;
    border-top: 1px solid var(--color-accent-border);
  }

  .chat-history {
    max-height: calc(100vh - 600px);
    min-height: 300px;
  }
}

@keyframes thinkingDots {

  0%,
  20% {
    content: '.';
  }

  40% {
    content: '..';
  }

  60%,
  80% {
    content: '...';
  }

  100% {
    content: '';
  }
}

.thinking-container {
  display: flex;
  align-items: center;
  gap: 8px;
}

.thinking-text {
  position: relative;
  font-style: italic;
  color: var(--color-gray-text);
}

.thinking-text::after {
  content: '';
  position: absolute;
  display: inline-block;
  animation: thinkingDots 1.5s infinite;
}

/* Simple dot indicator */
.thinking-dots {
  color: var(--color-gray-text);
  letter-spacing: 1px;
}

/* Add these styles to your styles.css file */
.stop-button-container {
  position: absolute;
  bottom: 1.5rem;
  left: 1.5rem;
  z-index: 101;
}

.stop-button {
  width: 30px;
  height: 30px;
  background-color: #333232;
  color: var(--color-white);
  border: none;
  cursor: pointer;
  font-weight: 700;
  font-size: 1.5rem;
  transition: all var(--transition-fast);
  display: none;
  /* Will be toggled via JavaScript */
  border-radius: 0;
  box-shadow: var(--shadow-md);
  padding: 0;
  line-height: 1;
}

.stop-button:hover {
  background-color: #1b1918;
}

/* Keep the send button style without modifications */
.send-button {
  padding: 1rem 1.5rem;
  background-color: var(--color-primary);
  color: var(--color-white);
  border: none;
  cursor: pointer;
  font-weight: 500;
  transition: all var(--transition-fast);
  height: 100%;
  font-size: 1rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* Keep original chat-input-container styles but add position relative */
.chat-input-container {
  padding: 1.5rem;
  background-color: var(--color-white);
  position: sticky;
  bottom: 0;
  z-index: 100;
  box-shadow: 0 -4px 12px rgba(9, 30, 66, 0.05);
  position: relative;
}

.bot-icon-image {
  width: 100%;
  /* Fill the parent container */
  height: 100%;
  /* Fill the parent container */
  object-fit: cover;
  /* Cover the area while maintaining aspect ratio */
  border-radius: 50%;
  /* Make the image circular */
}


/* Updated CSS for a more refined stop button */

/* Updated button container style */
.buttons-container {
  display: flex;
  height: 100%;
  border-left: 1px solid var(--color-accent-border);
}

/* Improved stop button style */
.stop-button {
  height: 100%;
  width: 48px;
  background-color: var(--color-white);
  color: #6b7280;
  border: none;
  cursor: pointer;
  transition: all var(--transition-fast);
  display: none;
  padding: 0;
  line-height: 1;
  border-right: 1px solid var(--color-accent-border);
}

/* Stop icon with cleaner design */
.stop-button .stop-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 16px;
  height: 16px;
  border-radius: 2px;
  background-color: currentColor;
}

.stop-button:hover {
  background-color: #f3f4f6;
  color: #ef4444;
}

.stop-button:active {
  background-color: #f9fafb;
}

/* Send button with matching style */
.send-button {
  padding: 0 1.5rem;
  background-color: var(--color-primary);
  color: var(--color-white);
  border: none;
  cursor: pointer;
  font-weight: 500;
  transition: all var(--transition-fast);
  height: 100%;
  font-size: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  min-width: 100px;
}

.send-button:hover {
  background-color: var(--color-primary-hover);
}

/* Make sure input wrapper has proper rounded corners */
.chat-input-wrapper {
  display: flex;
  align-items: stretch;
  height: 60px;
  overflow: hidden;
  background-color: var(--color-white);
  border-radius: var(--rounded-xl);
  box-shadow: var(--shadow-md);
  transition: all var(--transition-normal);
  border: 1px solid var(--color-accent-border);
}

/* Dark mode adjustments */
body.dark-mode .stop-button {
  background-color: var(--color-white);
  color: #9ca3af;
  border-right-color: var(--color-accent-border);
}

body.dark-mode .stop-button:hover {
  background-color: #374151;
  color: #f87171;
}

/* Session styles */
.new-session-button {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0.5rem 1rem;
  background-color: var(--color-primary);
  color: var(--color-white);
  border: none;
  border-radius: var(--rounded-md);
  cursor: pointer;
  font-size: 0.875rem;
  font-weight: 500;
  transition: all var(--transition-fast);
  margin-top: 0.5rem;
}

.new-session-button:hover {
  background-color: var(--color-primary-hover);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.plus-icon {
  font-size: 1.1rem;
  font-weight: bold;
}

.panel-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
  padding-bottom: 0.75rem;
  border-bottom: 2px solid var(--color-primary);
}

.sessions-container {
  flex-grow: 1;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.session-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem;
  background-color: var(--color-white);
  border-radius: var(--rounded-md);
  border-left: 4px solid var(--color-accent-border);
  box-shadow: var(--shadow-sm);
  transition: all var(--transition-normal);
  cursor: pointer;
}

.session-item.active {
  border-left-color: var(--color-primary);
  background-color: var(--color-accent-bg);
}

.session-item:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.session-info {
  flex: 1;
}

.session-title {
  font-weight: 600;
  color: var(--color-text);
  margin-bottom: 0.25rem;
  max-width: 190px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.session-date {
  font-size: 0.75rem;
  color: var(--color-gray-text);
}

.session-actions {
  display: flex;
  gap: 0.5rem;
}

.session-rename-btn,
.session-delete-btn {
  background: none;
  border: none;
  font-size: 1rem;
  cursor: pointer;
  color: var(--color-gray-text);
  transition: all var(--transition-fast);
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
}

.session-rename-btn:hover {
  color: var(--color-primary);
  background-color: rgba(var(--color-primary-rgb), 0.1);
}

.session-delete-btn:hover {
  color: var(--color-error);
  background-color: rgba(var(--color-error-rgb), 0.1);
}

.rename-input {
  width: 100%;
  padding: 0.5rem;
  border: 1px solid var(--color-accent-border);
  border-radius: var(--rounded-sm);
  font-size: 0.875rem;
}

.rename-input:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 2px rgba(var(--color-primary-rgb), 0.2);
}

.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  color: var(--color-gray-text);
  text-align: center;
}

.empty-state-icon {
  font-size: 2rem;
  margin-bottom: 1rem;
  color: var(--color-accent-border);
}

.empty-state-text {
  margin-bottom: 1rem;
}

/* Dark mode adjustments */
body.dark-mode .session-item {
  background-color: var(--color-white);
}

body.dark-mode .session-item.active {
  background-color: rgba(var(--color-primary-rgb), 0.2);
}

/* Add this to the @media (max-width: 768px) section */
@media (max-width: 768px) {
  .sessions-container {
    max-height: 250px;
  }
}