/* Enhanced Chat Widget Styles */
.chat-widget {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 1000;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
  }
  
  .chat-button {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background-color: #ff9a07;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    transition: transform 0.2s;
  }
  
  .chat-button:hover {
    transform: scale(1.1);
  }
  
  .chat-button i {
    font-size: 24px;
    color: white;
  }
  
  .chat-container {
    position: fixed;
    bottom: 90px;
    right: 20px;
    width: 350px;
    height: 500px;
    background: white;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
    display: none;
    flex-direction: column;
    overflow: hidden;
    transition: all 0.3s ease;
  }
  
  .chat-container.active {
    display: flex;
    animation: slideIn 0.3s ease;
  }
  
  @keyframes slideIn {
    from {
      opacity: 0;
      transform: translateY(20px);
    }
    to {
      opacity: 1;
      transform: translateY(0);
    }
  }
  
  .chat-header {
    background: #ff9a07;
    color: white;
    padding: 15px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
  }
  
  .chat-header h3 {
    margin: 0;
    font-size: 16px;
    font-weight: 600;
  }
  
  .close-chat {
    background: none;
    border: none;
    color: white;
    cursor: pointer;
    font-size: 20px;
    padding: 0;
    transition: transform 0.2s;
  }
  
  .close-chat:hover {
    transform: scale(1.1);
  }
  
  .chat-messages {
    flex: 1;
    padding: 15px;
    overflow-y: auto;
    background: #f8f9fa;
  }
  
  .message {
    margin-bottom: 15px;
    max-width: 80%;
    animation: messageIn 0.3s ease;
  }
  
  @keyframes messageIn {
    from {
      opacity: 0;
      transform: translateY(10px);
    }
    to {
      opacity: 1;
      transform: translateY(0);
    }
  }
  
  .user-message {
    margin-left: auto;
    background: #ff9a07;
    color: white;
    padding: 10px 15px;
    border-radius: 15px 15px 0 15px;
  }
  
  .bot-message {
    background: white;
    color: #333;
    padding: 10px 15px;
    border-radius: 15px 15px 15px 0;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  }
  
  .chat-input {
    padding: 15px;
    border-top: 1px solid #eee;
    display: flex;
    gap: 10px;
    background: white;
  }
  
  .chat-input input {
    flex: 1;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 20px;
    outline: none;
    font-size: 14px;
    transition: border-color 0.2s;
  }
  
  .chat-input input:focus {
    border-color: #ff9a07;
  }
  
  .send-button {
    background: #ff9a07;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.2s;
  }
  
  .send-button:hover {
    background: #FFD54F;
  }
  
  .typing-indicator {
    display: none;
    padding: 10px 15px;
    background: white;
    border-radius: 15px;
    margin-bottom: 15px;
    width: fit-content;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  }
  
  .typing-indicator.active {
    display: flex;
    align-items: center;
    gap: 5px;
  }
  
  .dot {
    width: 6px;
    height: 6px;
    background: #666;
    border-radius: 50%;
    animation: typing 1s infinite;
  }
  
  .dot:nth-child(2) {
    animation-delay: 0.2s;
  }
  
  .dot:nth-child(3) {
    animation-delay: 0.4s;
  }
  
  @keyframes typing {
    0%, 100% {
      transform: translateY(0);
    }
    50% {
      transform: translateY(-5px);
    }
  }
  
  /* Dark theme support */
  body.dark-theme .chat-container {
    background: #1e1e1e;
    color: #f5f5f5;
  }
  
  body.dark-theme .chat-messages {
    background: #2d2d2d;
  }
  
  body.dark-theme .bot-message {
    background: #333;
    color: #f5f5f5;
  }
  
  body.dark-theme .chat-input {
    background: #1e1e1e;
    border-top-color: #333;
  }
  
  body.dark-theme .chat-input input {
    background: #333;
    border-color: #444;
    color: #f5f5f5;
  }
  
  /* Mobile responsiveness */
  @media (max-width: 480px) {
    .chat-container {
      width: 100%;
      height: 100%;
      bottom: 0;
      right: 0;
      border-radius: 0;
    }
  
    .chat-button {
      width: 50px;
      height: 50px;
    }
  
    .chat-button i {
      font-size: 20px;
    }
  }

  /* chat.css में निम्न स्टाइल्स जोड़ें/संशोधित करें */

.bot-message {
    white-space: pre-line; /* नई लाइन्स को प्रदर्शित करे */
    word-wrap: break-word; /* लंबे टेक्स्ट को रैप करे */
    max-width: 85%;
    line-height: 1.5;
    padding: 12px 15px;
    margin-right: 15px;
    background: #fff;
    border: 1px solid #eee;
}

.user-message {
    white-space: pre-wrap;
    max-width: 75%;
    line-height: 1.5;
    padding: 12px 15px;
    margin-left: auto;
    background: #FFC107;
    color: white;
}

.chat-messages {
    padding: 20px;
    font-size: 14px;
}

/* मोबाइल व्यू के लिए ऑप्टिमाइजेशन */
@media (max-width: 480px) {
    .bot-message, .user-message {
        max-width: 90%;
        font-size: 13px;
        padding: 10px 12px;
    }
    
    .chat-messages {
        padding: 15px;
    }
}

/* बेहतर टाइपिंग इंडिकेटर */
.typing-indicator {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(2px);
    padding: 8px 12px;
    border-radius: 20px;
}

.dot {
    width: 7px;
    height: 7px;
    background: #666;
    animation: typing 1.2s infinite ease-in-out;
}

/* स्क्रॉलबार स्टाइलिंग */
.chat-messages::-webkit-scrollbar {
    width: 6px;
}

.chat-messages::-webkit-scrollbar-track {
    background: #f1f1f1;
}

.chat-messages::-webkit-scrollbar-thumb {
    background: #FFC107;
    border-radius: 4px;
}