
/* Chat button */
.chat-button {
      background-color: #4f46e5;
      color: white;
      padding: 12px;
      border-radius: 9999px;
      border: none;
      cursor: pointer;
      position: fixed;
      bottom: 20px;
      right: 20px;
      box-shadow: 0 4px 8px rgba(0,0,0,0.2);
      transition: background-color 0.3s ease;
  }

  .chat-button:hover {
      background-color: #3730a3;
  }

  /* Chat container */
  .chat-container {
      position: fixed;
      bottom: 80px;
      right: 20px;
      width: 360px;
      max-height: 500px;
      background-color: #ffffff;
      border-radius: 16px;
      box-shadow: 0 8px 16px rgba(0,0,0,0.2);
      overflow: hidden;
      display: flex;
      flex-direction: column;
      font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  }

  /* Chat header */
  .chat-header {
      background-color: #4f46e5;
      color: white;
      padding: 16px;
      font-size: 18px;
      font-weight: bold;
      align-items: center;
      justify-content: space-between;
  }

  .close-button {
      background: transparent;
      border: none;
      cursor: pointer;
      color: white;
  }

  /* Chat form inputs */
  .form-input {
      width: 100%;
      margin: 0 auto;
      padding: 10px;
      border: 1px solid #ccc;
      border-radius: 8px;
      font-size: 14px;
  }

  /* Submit button */
  .submit-button {
      margin: 10px auto;
      display: block;
      background-color: #4f46e5;
      color: white;
      border: none;
      padding: 10px 20px;
      border-radius: 8px;
      cursor: pointer;
      font-weight: 600;
  }

  .submit-button:hover {
      background-color: #3730a3;
  }

  /* Message area */
  .chat-area {
      padding: 16px;
      overflow-y: auto;
      flex: 1;
  }

  /* Message wrapper */
  .message-wrapper {
      display: flex;
      align-items: flex-start;
      margin-bottom: 16px;
  }
  

  .profile-picture {
      margin-right: 10px;
  }

  .message-content {
      background-color: #f3f4f6;
      padding: 10px 14px;
      border-radius: 12px;
      max-width: 75%;
  }

  .message-content .name {
      font-weight: bold;
      font-size: 14px;
      margin-bottom: 4px;
  }

  .message-content .message {
      font-size: 14px;
  }

  /* Typing area */
  .chat-typing-area-wrapper {
      border-top: 1px solid #e5e7eb;
      padding: 12px;
      background-color: #f9fafb;
  }

  .chat-input {
      width: calc(100% - 50px);
      padding: 10px;
      border-radius: 8px;
      border: 1px solid #ccc;
      font-size: 14px;
      margin-right: 8px;
  }

  .send-button {
      background-color: #4f46e5;
      border: none;
      padding: 10px;
      border-radius: 8px;
      color: white;
      cursor: pointer;
  }

  .send-button:hover {
      background-color: #3730a3;
  }

  .chat-header {
      display: flex;
      align-items: center;
      justify-content: space-between;
      background-color: #4f46e5;
      color: white;
      padding: 14px 16px;
      font-size: 16px;
      font-weight: bold;
      border-top-left-radius: 16px;
      border-top-right-radius: 16px;
  }

  .header-title h3 {
      margin: 0;
      font-size: 16px;
  }

  .header-close button {
      background: transparent;
      border: none;
      padding: 0;
      cursor: pointer;
      display: flex;
      align-items: center;
      justify-content: center;
      color: white;
  }


  /* Merchant message - aligns right */
  .message-wrapper.reverse {
      flex-direction: row-reverse;
  }

  /* Merchant message bubble */
  .message-wrapper.reverse .message {
      background-color: #00ff9526;
      color: #159b44;
      margin-left: auto;
      border-radius: 16px 0 16px 16px;
  }

  /* Profile pic adjustment for reverse */
  .message-wrapper.reverse .profile-picture {
      margin-right: 0;
      margin-left: 12px;
      background: #00ff9526;
      color: #4cc794;
      border-radius: 50%;
  }

  /* Name right-aligned in reverse */
  .message-wrapper.reverse .name {
      text-align: right;
  }

  .message-time {
        display: flex;
        align-items: center;
        font-size: 12px;
        color: #6b7280;
        margin-top: 6px;
        gap: 4px;
    }

    .message-time svg {
        height: 14px;
        width: 14px;
        color: #4ade80;
    }
    .avatar-list {
      display: flex;
      flex-wrap: wrap;
      gap: 15px;
    }

    .avatar-item {
      display: flex;
      flex-direction: column;
      align-items: center;
      cursor: pointer;
    }

    .avatar {
      width: 60px;
      height: 60px;
      border-radius: 50%;
      background-size: cover;
      background-position: center;
      border: 2px solid transparent;
      transition: 0.3s ease;
    }

    .avatar.selected {
      border-color: #007bff;
      box-shadow: 0 0 5px #007bff;
    }

    .avatar-name {
      margin-top: 5px;
      font-size: 14px;
      font-weight: 500;
    }

