/* EVE Assistant - Clean Implementation */
.faq-assistant {
  position: fixed;
  bottom: 30px;
  right: 30px;
  z-index: 1004;
  font-family: var(--nav-font, 'Poppins', sans-serif);
  width: 380px;
  transition: all 0.3s ease;
}

.faq-header {
  background: var(--accent-color, #1fa2ff);
  color: var(--contrast-color, #ffffff);
  padding: 16px 20px;
  border-radius: 12px 12px 0 0;
  display: flex;
  align-items: center;
  cursor: pointer;
  transition: background 0.3s;
}

.faq-header:hover {
  background: #0d8ce8;
}

.faq-header i {
  margin-right: 8px;
}

.faq-content {
  background: var(--surface-color, #1a1a1a);
  border-radius: 0 0 12px 12px;
  min-height: 350px;
  overflow: hidden;
  transition: all 0.3s ease;
}

.faq-messages {
  padding: 20px;
  min-height: 250px;
  max-height: 70vh;
  overflow-y: auto;
  scrollbar-width: thin;
}

.faq-message {
  margin-bottom: 16px;
}

.bot-message {
  opacity: 0;
  animation: fadeInUp 0.3s ease-out forwards;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.message-content {
  background: var(--background-color, #121212);
  color: var(--default-color, #f1f1f1);
  padding: 12px 16px;
  border-radius: 12px;
  font-size: 14px;
  line-height: 1.7;
  transition: opacity 0.1s ease;
}

.message-content p {
  margin-bottom: 1em;
  line-height: 1.4;
}

.message-content p:last-child {
  margin-bottom: 0;
}

.message-content.typewriter-cursor {
  transition: min-height 0.1s ease;
}

.message-content.typewriter-cursor a {
  pointer-events: none;
  cursor: text;
}

.faq-input-container {
  display: flex;
  padding: 16px 20px;
  border-top: 1px solid rgba(31, 162, 255, 0.2);
  gap: 12px;
  background: var(--surface-color, #1a1a1a);
}

#faq-input {
  flex: 1;
  background: var(--background-color, #121212);
  border: 1px solid rgba(31, 162, 255, 0.3);
  border-radius: 8px;
  padding: 12px 16px;
  color: var(--default-color, #f1f1f1);
  font-size: 14px;
  outline: none;
  transition: all 0.2s ease;
}

#faq-input:focus {
  border-color: var(--accent-color, #1fa2ff);
  box-shadow: 0 0 0 3px rgba(31, 162, 255, 0.1);
}

.faq-send-btn {
  background: var(--accent-color, #1fa2ff);
  border: none;
  border-radius: 8px;
  width: 44px;
  height: 44px;
  color: var(--contrast-color, #ffffff);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
}

.faq-send-btn:hover {
  background: #0d8ce8;
  transform: translateY(-2px);
}

.faq-toggle {
  background: transparent;
  border: none;
  color: var(--contrast-color, #ffffff);
  cursor: pointer;
  padding: 4px;
}

/* States */
.faq-assistant.collapsed {
  width: auto;
}

.faq-assistant.collapsed .faq-content {
  display: none;
}

.faq-assistant.collapsed .faq-header {
  border-radius: 12px;
}

.faq-assistant.expanded .faq-content {
  display: block;
}

/* Clickable Trigger */
.suggested-questions-trigger {
  color: var(--accent-color, #1fa2ff);
  cursor: pointer;
  text-decoration: underline;
  font-weight: 500;
}

.suggested-questions-trigger:hover {
  color: #0d8ce8;
}

/* User Messages */
.user-message {
  display: flex;
  justify-content: flex-end;
}

.user-message .message-content {
  background: var(--accent-color, #1fa2ff);
  color: var(--contrast-color, #ffffff);
  max-width: 80%;
}

/* Question Buttons */
.eve-questions {
  margin: 16px 0 0 0;
  padding: 0;
}

.eve-question {
  display: block;
  width: 100%;
  margin: 8px 0;
  padding: 12px 16px;
  background: rgba(31, 162, 255, 0.1);
  color: var(--default-color, #f1f1f1);
  border: 1px solid rgba(31, 162, 255, 0.3);
  border-radius: 8px;
  cursor: pointer;
  font-size: 14px;
  text-align: left;
  transition: all 0.2s ease;
  font-family: inherit;
}

.eve-question:hover {
  background: rgba(31, 162, 255, 0.2);
  border-color: var(--accent-color, #1fa2ff);
  transform: translateY(-1px);
}

/* Thinking Indicator */
.thinking-indicator {
  display: flex;
  align-items: center;
  gap: 8px;
  font-style: italic;
  opacity: 0.7;
  background: rgba(31, 162, 255, 0.05);
  border-left: 3px solid var(--accent-color, #1fa2ff);
  padding: 12px 16px;
  border-radius: 8px;
}

.thinking-dots {
  display: flex;
  gap: 4px;
}

.thinking-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent-color, #1fa2ff);
  animation: thinking-pulse 1.4s infinite ease-in-out;
}

.thinking-dot:nth-child(1) { animation-delay: -0.32s; }
.thinking-dot:nth-child(2) { animation-delay: -0.16s; }
.thinking-dot:nth-child(3) { animation-delay: 0s; }

@keyframes thinking-pulse {
  0%, 80%, 100% { transform: scale(0.8); opacity: 0.5; }
  40% { transform: scale(1); opacity: 1; }
}

/* Typewriter Cursor */
.typewriter-cursor::after {
  content: '|';
  animation: blink 1s infinite;
}

@keyframes blink {
  0%, 50% { opacity: 1; }
  51%, 100% { opacity: 0; }
}

/* HTML Content Styling */
.message-content a {
  color: var(--accent-color, #1fa2ff);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: all 0.2s ease;
}

.message-content a:hover {
  color: #0d8ce8;
  border-bottom-color: #0d8ce8;
}

.message-content strong {
  color: var(--accent-color, #1fa2ff);
  font-weight: 600;
}

.message-content em {
  color: rgba(241, 241, 241, 0.9);
  font-style: italic;
}

.message-content blockquote {
  margin: 12px 0;
  padding: 8px 12px;
  border-left: 3px solid var(--accent-color, #1fa2ff);
  background: rgba(31, 162, 255, 0.05);
  font-style: italic;
  border-radius: 0 6px 6px 0;
}

/* Certificate Buttons - Simple ChatGPT Style */
.cert-btn {
  display: inline-block;
  margin: 6px 0 8px 0;
  padding: 6px 12px;
  background: rgba(255, 255, 255, 0.1);
  color: rgba(255, 255, 255, 0.8);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 8px;
  cursor: pointer;
  font-size: 12px;
  font-weight: 400;
  text-decoration: none;
  transition: all 0.15s ease;
  font-family: inherit;
  opacity: 0;
  animation: certFadeIn 0.3s ease-out forwards;
}

.cert-btn:nth-of-type(1) { animation-delay: 0.1s; }
.cert-btn:nth-of-type(2) { animation-delay: 0.2s; }
.cert-btn:nth-of-type(3) { animation-delay: 0.3s; }
.cert-btn:nth-of-type(4) { animation-delay: 0.4s; }
.cert-btn:nth-of-type(5) { animation-delay: 0.5s; }
.cert-btn:nth-of-type(6) { animation-delay: 0.6s; }
.cert-btn:nth-of-type(7) { animation-delay: 0.7s; }
.cert-btn:nth-of-type(8) { animation-delay: 0.8s; }
.cert-btn:nth-of-type(9) { animation-delay: 0.9s; }

.cert-btn:hover {
  background: rgba(255, 255, 255, 0.15);
  color: rgba(255, 255, 255, 0.9);
  border-color: rgba(255, 255, 255, 0.3);
  box-shadow: 0 2px 8px rgba(255, 255, 255, 0.1);
}

.cert-btn:active {
  background: rgba(255, 255, 255, 0.08);
  transform: scale(0.98);
}

.cert-list {
  margin: 8px 0;
}

/* Certificate Button Animation */
@keyframes certFadeIn {
  0% {
    opacity: 0;
    transform: translateY(8px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}