/* Refibot Chatbot Styles */
.refibot-container {
  position: fixed;
  bottom: 30px;
  right: 30px;
  z-index: 9999;
  font-family: 'Poppins', sans-serif;
}

.refibot-toggle {
  width: 60px;
  height: 60px;
  background: linear-gradient(135deg, #56ab2f, #a8e063);
  border-radius: 50%;
  display: flex;
  justify-content: center;
  align-items: center;
  color: white;
  font-size: 24px;
  cursor: pointer;
  box-shadow: 0 5px 15px rgba(86, 171, 47, 0.4);
  transition: all 0.3s ease;
  animation: pulse 2s infinite;
}

.refibot-toggle:hover {
  transform: scale(1.1);
  box-shadow: 0 8px 25px rgba(86, 171, 47, 0.6);
}

.refibot-chatbox {
  width: 350px;
  height: 500px;
  background: white;
  border-radius: 15px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
  overflow: hidden;
  display: none;
  transform: translateY(20px);
  opacity: 0;
  transition: all 0.3s ease;
  position: relative;
}

.refibot-chatbox.active {
  display: block;
  transform: translateY(0);
  opacity: 1;
}

.refibot-header {
  background: linear-gradient(135deg, #56ab2f, #a8e063);
  color: white;
  padding: 15px;
  display: flex;
  align-items: center;
  position: relative;
}

.refibot-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  overflow: hidden;
  margin-right: 10px;
  border: 2px solid white;
}

.refibot-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.refibot-info {
  flex: 1;
}

.refibot-info h4 {
  margin: 0;
  font-size: 16px;
  font-weight: 600;
}

.refibot-info p {
  margin: 0;
  font-size: 12px;
  opacity: 0.8;
}

.refibot-actions {
  display: flex;
}

.refibot-actions button {
  background: transparent;
  border: none;
  color: white;
  cursor: pointer;
  font-size: 14px;
  margin-left: 10px;
  transition: all 0.2s ease;
}

.refibot-actions button:hover {
  transform: scale(1.1);
}

.refibot-messages {
  height: calc(100% - 120px);
  padding: 15px;
  overflow-y: auto;
  background: #f9f9f9;
}

.refibot-message {
  max-width: 80%;
  padding: 10px 15px;
  border-radius: 18px;
  margin-bottom: 10px;
  position: relative;
  animation: messageIn 0.3s ease;
}

.refibot-bot {
  background: white;
  color: #333;
  border-top-left-radius: 5px;
  align-self: flex-start;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
  margin-right: auto;
}

.refibot-user {
  background: linear-gradient(135deg, #56ab2f, #a8e063);
  color: white;
  border-top-right-radius: 5px;
  align-self: flex-end;
  margin-left: auto;
}

.typing-indicator {
  display: flex;
  padding: 10px;
}

.typing-indicator span {
  height: 8px;
  width: 8px;
  background: #ccc;
  border-radius: 50%;
  display: inline-block;
  margin: 0 2px;
  animation: typing 1s infinite;
}

.typing-indicator span:nth-child(2) {
  animation-delay: 0.2s;
}

.typing-indicator span:nth-child(3) {
  animation-delay: 0.4s;
}

.refibot-input {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  background: white;
  border-top: 1px solid #eee;
  padding: 10px;
  display: flex;
}

.refibot-text-input {
  flex: 1;
  border: 1px solid #ddd;
  border-radius: 30px;
  padding: 10px 15px;
  outline: none;
  transition: all 0.3s ease;
}

.refibot-text-input:focus {
  border-color: #56ab2f;
  box-shadow: 0 0 0 2px rgba(86, 171, 47, 0.2);
}

.refibot-send {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: linear-gradient(135deg, #56ab2f, #a8e063);
  color: white;
  border: none;
  margin-left: 10px;
  cursor: pointer;
  transition: all 0.3s ease;
}

.refibot-send:hover {
  transform: scale(1.05);
  box-shadow: 0 3px 10px rgba(86, 171, 47, 0.4);
}

/* Animations */
@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(86, 171, 47, 0.7); }
  70% { box-shadow: 0 0 0 15px rgba(86, 171, 47, 0); }
  100% { box-shadow: 0 0 0 0 rgba(86, 171, 47, 0); }
}

@keyframes typing {
  0% { transform: translateY(0); }
  50% { transform: translateY(-5px); }
  100% { transform: translateY(0); }
}

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

/* Responsive */
@media (max-width: 576px) {
  .refibot-container {
    bottom: 15px;
    right: 15px;
  }
  
  .refibot-chatbox {
    width: calc(100vw - 30px);
    height: 70vh;
    right: 15px;
  }
}