:root {
  --primary-color: #9b30ff;
  --primary-hover: #7d1fd1;
  --background-dark: #0d0d0d;
  --background-card: #1a1a1a;
  --background-light: #f9f9f9;
  --text-color: #fff;
  --text-muted: #ccc;
  --border-color: #ccc;
  --secondary-bg: #333;
  --secondary-hover: #444;
  --footer-bg: #111;
}

body {
  margin: 0;
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  background-color: var(--background-dark);
  color: var(--text-color);
}

header {
  display: flex;
  justify-content: center;
  align-items: center;
  background-color: #fff;
  padding: 1rem 0;
}

.logo-header {
  height: 30px;
  text-align: center;
}

.main-content {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 2rem;
  min-height: calc(95vh - 160px);
}

.card {
  background-color: var(--background-card);
  border-radius: 16px;
  padding: 2rem;
  max-width: 350px;
  width: 100%;
  text-align: center;
  box-shadow: 0 0 20px rgba(0, 0, 0, 0.5);
  animation: fadeInUp 0.8s ease-out;
}

.logo-card {
  height: 80px;
  margin-bottom: 1.5rem;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.logo-card:hover {
  transform: scale(1.1);
  filter: brightness(1.1);
}

.card h1 {
  font-size: 1.8rem;
  margin-bottom: 1rem;
}

.card p {
  color: var(--text-muted);
  margin-bottom: 2rem;
}

.buttons {
  display: flex;
  justify-content: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.btn {
  text-decoration: none;
  padding: 1rem 2rem;
  border-radius: 8px;
  font-weight: bold;
  transition: transform 0.2s ease, background-color 0.3s ease;
}

.btn:hover {
  transform: scale(1.03);
}

.primary {
  background-color: var(--primary-color);
  color: var(--text-color);
}

.primary:hover {
  background-color: var(--primary-hover);
}

.secondary {
  background-color: var(--secondary-bg);
  color: var(--text-color);
  border: 1px solid #555;
}

.secondary:hover {
  background-color: var(--secondary-hover);
}

.chat-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1rem;
}

.back-button {
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: #333;
  transition: color 0.3s ease;
}

.back-button:hover {
  color: #000;
}

.chat-messages {
  display: flex;
  flex-direction: column;
  height: 300px;
  overflow-y: auto;
  border: 1px solid var(--border-color);
  padding: 10px;
  border-radius: 10px;
  background-color: var(--background-light);
  margin-bottom: 1rem;
  color: black;
}

.chat-input {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin-top: 1rem;
}

.chat-input input {
  flex: 1;
  padding: 0.7rem;
  border-radius: 8px;
  border: 1px solid var(--border-color);
}

.send-button {
  background-color: var(--primary-color);
  color: var(--text-color);
  border: none;
  padding: 0.7rem 1.2rem;
  border-radius: 8px;
  cursor: pointer;
  transition: background-color 0.3s;
}

.send-button:hover {
  background-color: var(--primary-hover);
}

.footer {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  background-color: var(--footer-bg);
  color: var(--text-muted);
  text-align: center;
  padding: 1rem;
  font-size: 0.9rem;
  z-index: 100;
  animation: fadeInUp 1.2s ease-out;
}

.footer a {
  color: var(--text-color);
  margin: 0 0.5rem;
  text-decoration: none;
  font-size: 1.5rem;
  transition: color 0.3s;
}

.footer a:hover {
  color: var(--primary-hover);
}

.social-icon i {
  transition: transform 0.3s;
}

.social-icon i:hover {
  transform: scale(1.2);
}

.quick-questions {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-bottom: 1rem;
  justify-content: center;
}

.quick-questions button {
  background-color: var(--secondary-bg);
  color: var(--text-color);
  border: none;
  border-radius: 8px;
  padding: 0.5rem 1rem;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.quick-questions button:hover {
  background-color: var(--secondary-hover);
}

#digitando::after {
  content: "⠀";
  display: inline-block;
  animation: pontinhos 1s infinite steps(3);
}

@keyframes pontinhos {
  0% { content: "."; }
  33% { content: ".."; }
  66% { content: "..."; }
}

.user-message {
  align-self: flex-end;
  background-color: #dcdcdc;
  color: #000;
  padding: 0.6rem;
  border-radius: 12px;
  max-width: 80%;
  margin: 0.5rem 0;
  text-align: left;
}

.bot-message {
  align-self: flex-start;
  display: flex;
  align-items: center;
  gap: 10px;
  background-color: #e9e9e9;
  color: #000;
  padding: 0.6rem;
  border-radius: 25px;
  max-width: 95%;
  margin: 0.5rem 0;
}

.bot-icon {
  width: 30px;
  height: 30px;
  border-radius: 50%;
}

.animated {
  animation: fadeInChat 0.5s ease-out;
}

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

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

.quick-questions button:hover,
.sugestao:hover {
  background-color: var(--secondary-hover);
}

.sugestao {
  cursor: pointer;
  background-color: #f1f1f1;
  border-radius: 12px;
  margin: 6px 0;
  padding: 8px 12px;
  font-size: 0.9rem;
  max-width: 80%;
  display: flex;
  align-items: center;
  gap: 8px;
  animation: slideFadeIn 0.4s ease forwards;
  opacity: 0;
  transform: translateY(10px);
}

@keyframes slideFadeIn {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 768px) {
  .card {
    max-width: 90%;
    padding: 1.5rem;
  }

  .buttons {
    flex-direction: column;
    gap: 0.5rem;
  }

  .btn {
    width: 90%;
    padding: 1rem;
  }

  .footer {
    font-size: 0.8rem;
    padding: 1rem 0.5rem;
  }

  .footer a {
    font-size: 1.2rem;
  }

  header {
    padding: 0.8rem 0;
  }

  .logo-header {
    height: 24px;
  }
}
