﻿.rr-faq-chat {
  max-width: 980px;
  margin: 40px auto;
  padding: 24px;
  background: #f5f7fb;
  border-radius: 24px;
  font-size: 18px;
}

.rr-faq-chat-message {
  display: flex;
  gap: 16px;
  margin-bottom: 20px;
  align-items: flex-start;
}

.rr-faq-chat-message img {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  object-fit: cover;
  flex: 0 0 48px;
}

.rr-faq-chat-message > div {
  background: #fff;
  padding: 18px 22px;
  border-radius: 18px;
  box-shadow: 0 6px 18px rgba(16, 35, 63, 0.08);
}

.rr-faq-chat-message-user {
  justify-content: flex-end;
}

.rr-faq-chat-message-user > div {
  background: #0054b8;
  color: #fff;
}

.rr-faq-chat-options {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 16px;
}

.rr-faq-chat-options button,
.rr-faq-chat-skip,
.rr-faq-chat-reset {
  border: none;
  background: #0054b8;
  color: #fff;
  padding: 10px 16px;
  border-radius: 10px;
  font-weight: 700;
  cursor: pointer;
}

.rr-faq-chat-skip {
  background: #dbe3ef;
  color: #1f2a3d;
  margin-top: 14px;
}

.rr-faq-chat-results {
  margin-top: 32px;
}

.rr-faq-chat-result-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
}

.rr-faq-chat-result-card {
  background: #fff;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 8px 22px rgba(16, 35, 63, 0.08);
}

.rr-faq-chat-result-card a {
  color: inherit;
  text-decoration: none;
  display: block;
}

.rr-faq-chat-result-image img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  display: block;
}

.rr-faq-chat-result-body {
  padding: 18px;
}

.rr-faq-chat-result-body h3 {
  color: #c9001f;
  margin: 0 0 10px;
  font-size: 20px;
}

.rr-faq-chat-result-body p {
  font-size: 15px;
  line-height: 1.5;
}

.rr-faq-chat-result-body span {
  color: #c9001f;
  font-weight: 700;
}

.rr-faq-chat-message-bot > img {
  max-width: 72px !important;
  max-height: 72px !important;
}

.rr-faq-chat {
  max-width: 1080px;
  margin: 40px auto;
  padding: 32px;
  background: #f4f7fb;
  border-radius: 28px;
  font-size: 18px;
}

.rr-faq-chat-message {
  display: flex;
  gap: 14px;
  margin-bottom: 24px;
  align-items: flex-start;
}

.rr-faq-chat-message-bot img {
  width: 54px;
  height: 54px;
  border-radius: 50%;
  object-fit: cover;
  flex: 0 0 54px;
}

.rr-faq-chat-bubble,
.rr-faq-chat-message > div {
  position: relative;
  background: #fff;
  padding: 22px 26px;
  border-radius: 18px;
  box-shadow: 0 8px 24px rgba(16, 35, 63, 0.08);
  max-width: 760px;
}

.rr-faq-chat-message-bot .rr-faq-chat-bubble::before,
.rr-faq-chat-message-bot > div::before {
  content: "";
  position: absolute;
  left: -10px;
  top: 22px;
  width: 0;
  height: 0;
  border-top: 10px solid transparent;
  border-bottom: 10px solid transparent;
  border-right: 12px solid #fff;
}

.rr-faq-chat-message-user {
  justify-content: flex-end;
}

.rr-faq-chat-message-user .rr-faq-chat-bubble,
.rr-faq-chat-message-user > div {
  background: #d9ebff;
  color: #17365d;
  border-radius: 18px;
  max-width: 520px;
  font-weight: 600;
}

.rr-faq-chat-message-user .rr-faq-chat-bubble::after,
.rr-faq-chat-message-user > div::after {
  content: "";
  position: absolute;
  right: -10px;
  top: 22px;
  width: 0;
  height: 0;
  border-top: 10px solid transparent;
  border-bottom: 10px solid transparent;
  border-left: 12px solid #d9ebff;
}

.rr-faq-chat-options {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 18px;
}

.rr-faq-chat-options button {
  border: 1px solid #d6dce8;
  background: #fff;
  color: #1f2a3d;
  padding: 10px 16px;
  border-radius: 8px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.15s ease;
}

.rr-faq-chat-options button.is-selected {
  background: #0054b8;
  border-color: #0054b8;
  color: #fff;
}

.rr-faq-chat-options button.is-selected::before {
  content: "✓ ";
  font-weight: 800;
}

.rr-faq-chat-step-actions {
  display: flex;
  justify-content: flex-end;
  margin-top: 18px;
}

.rr-faq-chat-next,
.rr-faq-chat-reset {
  border: none;
  background: #0054b8;
  color: #fff;
  padding: 10px 18px;
  border-radius: 8px;
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 6px 16px rgba(0, 84, 184, 0.24);
}

.rr-faq-chat-step[hidden],
.rr-faq-chat-results[hidden] {
  display: none !important;
}

.rr-faq-chat-step {
  animation: rrFaqFadeIn 0.28s ease both;
}

.rr-faq-chat-typing {
  display: flex;
  gap: 6px;
  margin-top: 10px;
}

.rr-faq-chat-typing span {
  width: 8px;
  height: 8px;
  background: #0054b8;
  border-radius: 50%;
  animation: rrFaqTyping 1s infinite ease-in-out;
}

.rr-faq-chat-typing span:nth-child(2) {
  animation-delay: 0.15s;
}

.rr-faq-chat-typing span:nth-child(3) {
  animation-delay: 0.3s;
}

@keyframes rrFaqTyping {
  0%,
  80%,
  100% {
    opacity: 0.3;
    transform: translateY(0);
  }
  40% {
    opacity: 1;
    transform: translateY(-4px);
  }
}

@keyframes rrFaqFadeIn {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
