:root {
  --primary-color:transparent ;
  --secondary-color:transparent ;
}
.init-spinner {
  width: 36px;
  height: 36px;
  border: 3px solid rgba(0,0,0,0.1);
  border-top-color: var(--primary-color, #555);
  border-radius: 50%;
  animation: init-spin 0.7s linear infinite;
}
@keyframes init-spin {
  to { transform: rotate(360deg); }
}
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    margin: 0;
    padding: 0;
    width: 100%;
    height: 100%;
    box-sizing: border-box;
    overflow: hidden;
}

/* Ensure chatbot doesn't interfere with host website */
* {
    box-sizing: border-box;
}
.emoji-picker{
    width: 100%;
    max-height: 250px;
}
.input-foot{
    display: flex;
    justify-content: space-between;
}
.input-actions{
    display: flex;
    align-items: center;

}
.bubble p {
    margin: 0;
}
.bubble ul,
.bubble ol {
  list-style-position: inside; 
  padding: 0;
}
/* .bubble li::marker {
  margin: 0;
  padding: 0;
} */
#orderIdInput::-webkit-inner-spin-button,
#orderIdInput::-webkit-outer-spin-button {
  -webkit-appearance: none;
  margin: 0;
}
a{
 color: var(--primary-color) !important;
}
.msg.user a {
  color: #fff !important;
}
/* Widget container styles for seamless integration */
#chatbot-widget {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 60px;
    height: 60px;
    max-width: calc(100vw - 40px);
    max-height: calc(100vh - 40px);
    z-index: 9999;
    border-radius: 50%;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    border: 1px solid #e0e0e0;
    transition: all 0.3s ease;
}

/* Expanded state - responsive dimensions */
#chatbot-widget.expanded {
    width: 400px;
    height: 600px;
    border-radius: 16px;
    box-shadow: 0px 0px 12px 0px rgba(0, 0, 0, 0.15);
}
/* Spinner */
.spinner-email {
  width: 16px;
  height: 16px;
  border: 2px solid #fff;
  border-top: 2px solid transparent;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  display: inline-block;
  margin-left: 8px;
}





/* Medium screens - responsive expanded state */
@media (max-width: 1024px) {
    #chatbot-widget.expanded {
        width: 350px;
        height: 550px;
    }
}

@media (max-width: 900px) {
    #chatbot-widget.expanded {
        width: 320px;
        height: 500px;
    }
}

/* Ensure iframe takes full container space */
#chatbot-widget iframe {
    width: 100% !important;
    height: 100% !important;
    border: none !important;
    border-radius: 16px;
}

.loader {
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.dot {
    width: 6px;
    height: 6px;
    background: #999;
    border-radius: 50%;
    animation: bounce 1.2s infinite;
}

.dot:nth-child(2) {
    animation-delay: 0.2s;
}

/* Generic centered loader container (for history screen, etc.) */
.center-loader {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 200px;
    padding: 16px;
}

/* Text + loader row */
.loader-row {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    color: #666;
}

/* Circle spinner variant */
.spinner {
    width: 24px;
    height: 24px;
    border: 3px solid #e6e6e6;
    border-top-color: var(--primary-color);
    border-radius: 50%;
    animation: spin 0.9s linear infinite;
}
.clarification-options {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin: 4px 0 8px;
    max-width: 300px;
}
.clarify-btn {
    background: var(--primary-color);
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    color: white;
    padding: 10px 14px;
    border-radius: 8px;
    border: none;
    text-align: left;
    line-height: 1.4;
    transition: all 0.2s ease;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
}
.clarify-btn:hover {
    opacity: 0.9;
    transform: translateY(-1px);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
}
.clarify-btn:disabled {
    cursor: not-allowed;
    opacity: 0.45;
    transform: none;
    box-shadow: none;
}
/* .clarify-btn--cancel {
    background: transparent;
    color: #888;
    border: 1px solid #d0d0d0;
    box-shadow: none;
}
.clarify-btn--cancel:hover {
    background: #f5f5f5;
    color: #555;
    border-color: #bbb;
    box-shadow: none;
    transform: none;
} */


@keyframes spin {
    to { transform: rotate(360deg); }
}


.dot:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes bounce {

    0%,
    80%,
    100% {
        transform: scale(0.6);
        opacity: 0.6;
    }

    40% {
        transform: scale(1);
        opacity: 1;
    }
}

.chat-widget-btn {
    position: fixed;
    bottom: 10px;
    right: 10px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: var(--secondary-color);
    color: white;
    font-size: 22px;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
    z-index: 1000;
    transition: all 0.3s ease;
}

.chat-widget-btn:hover {
    transform: scale(1.05);
    /* box-shadow: 0 6px 12px rgba(0, 0, 0, 0.4); */
}

.chat-widget-btn .chat-icon,
.chat-widget-btn .close-icon {
    display: inline-flex;
    transition: all 0.3s ease;
    position: absolute;
}

.chat-widget-btn .close-icon {
    font-size: 20px;
    font-weight: bold;
}

.chat-widget-btn.open {
    transform: rotate(180deg);
}

.chat-container {
    position: fixed;
    top: 8px;
    bottom: 8px;
    left: 8px;
    width: 408px;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0px 0px 12px 0px rgba(0, 0, 0, 0.15);
    display: none;
    flex-direction: column;
    overflow: hidden;
    z-index: 1000;
    animation: slideUp 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    border: 1px solid #e0e0e0;
}
.retry-container {
  display: flex;
  justify-content: flex-start;
  margin: 8px 0;
  padding: 0 12px;
}

.retry-btn {
  background-color: var(--primary-color);
  color: white;
  border: none;
  padding: 6px 8px;
  border-radius: 6px;
  cursor: pointer;
  font-size: 14px;
  transition: all 0.3s ease;
}

.retry-btn:hover {
    transform: scale(1.05);

}



@keyframes slideUp {
    from {
        transform: translateY(30px) scale(0.95);
        opacity: 0;
    }

    to {
        transform: translateY(0) scale(1);
        opacity: 1;
    }
}

.chat-header,.history-header {
    background: var(--primary-color);
    color: #fff;
    padding: 16px;
    font-size: 16px;
    font-weight: 600;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Left-align layout for main chat header */
#chat-header {
    justify-content: flex-start;
    position: relative;
    padding-right: 40px;
}

.close-chat-btn {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #fff;
    cursor: pointer;
    padding: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    opacity: 0.85;
    flex-shrink: 0;
    line-height: 0;
}
.close-chat-btn:hover {
    opacity: 1;
    background: rgba(255, 255, 255, 0.18);
}


#chat-header > span {
    margin-left: 4px;
}

/* Centered header layout (email + menu screens) */
#chat-header.header-centered {
    justify-content: center;
}

#chat-header.header-centered .header-left,
#chat-header.header-centered .header-actions {
    display: none;
}

#chat-header.header-centered > span {
    margin-left: 0;
    text-align: center;
}

.header-actions {
    display: flex;
    gap: 8px;
    align-items: center;
    margin-left: auto;
}

.subheader {
    padding: 12px 16px;
    background: #f8f9ff;
    border-bottom: 1px solid #e0e6ff;
    min-height: 32px;
    display: flex;
    gap: 8px;
    align-items: center;
    flex-wrap: wrap;
    justify-content: space-between;
}

.filter-tags {
    display: flex;
    gap: 8px;
    align-items: center;
    flex-wrap: wrap;
}

.filter-tag {
    background: linear-gradient(135deg, #667eea20 0%, #764ba220 100%);
    border: 2px solid #667eea40;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 16px;
    font-weight: 500;
    color: var(--primary-color);
    display: inline-flex;
    align-items: center;
    gap: 6px;
    position: relative;
}

.filter-tag .close-icon {
    background: rgba(255, 71, 84, 0.2);
    color: var(--primary-color);
    border: none;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 16px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    font-weight: bold;
}

.filter-tag .close-icon:hover {
    background: rgba(255, 71, 84, 0.4);
    transform: scale(1.1);
}

.back-btn {
    background: rgba(255, 71, 84, 0.1);
    color: var(--primary-color);
    border: 1px solid rgba(255, 71, 84, 0.3);
    padding: 2px 5px;
    border-radius: 15px;
    cursor: pointer;
    font-size: 12px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.back-btn:hover {
    background: rgba(255, 71, 84, 0.2);
    transform: scale(1.05);
}

.restart-btn {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.3);
    padding: 4px 10px;
    border-radius: 15px;
    cursor: pointer;
    font-size: 12px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.restart-btn:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: scale(1.05);
}

#chat {
    flex: 1;
    min-height: 0;
    padding: 16px;
    overflow-y: auto;
    background: #fafbff;
}

.msg {
     margin: 12px 0;
    display: flex;
    align-items: flex-end;
    gap: 8px;
}

.msg.user {
    justify-content: flex-end;
}

.msg.bot {
    justify-content: flex-start;
}

.bubble {
    max-width: 75%;
    padding: 12px 16px;
    border-radius: 18px;
    font-size: 16px;
    line-height: 1.4;
    word-wrap: break-word;
    position: relative;
}

.user .bubble {
    background: var(--primary-color);
    color: white;
    border-bottom-right-radius: 6px;
    box-shadow: 0 2px 10px rgba(102, 126, 234, 0.3);
}

.bot .bubble {
    background: #ffffff;
    color: #333;
    border-bottom-left-radius: 6px;
    border: 1px solid #e0e6ff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.welcome-container {
    text-align: center;
    padding: 20px;
    background: linear-gradient(135deg, #f8f9ff 0%, #ffffff 100%);
    border-radius: 12px;
    margin: 8px 0;
    border: 1px solid #e0e6ff;
}

.welcome-icon {
    width: 48px;
    height: 48px;
    background: var(--primary-color);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px;
    font-size: 24px;
    color: white;
}

.welcome-title {
    font-size: 18px;
    font-weight: 600;
    color: #333;
    margin-bottom: 8px;
}

.welcome-text {
    font-size: 16px;
    color: #666;
    line-height: 1.5;
    margin-bottom: 20px;
}

.email-container {
    text-align: center;
    padding: 20px;
    background: linear-gradient(135deg, #f8f9ff 0%, #ffffff 100%);
    border-radius: 12px;
    margin: 8px 0;
    border: 1px solid #e0e6ff;
    width: 100%;
}

.email-input {
    padding: 12px;
    width: 100%;
    max-width: 300px;
    border: 1px solid #e0e6ff;
    border-radius: 8px;
    font-size: 16px;
    margin-bottom: 16px;
}
.email-input {
  outline: none; 
}
.email-input:focus-visible,
.email-input:focus {
  outline: 1px solid var(--primary-color);
}
.email-submit-btn {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: auto;
    width: 100px;
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 25px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.email-submit-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
}
.email-submit-btn:disabled{
    opacity: 0.8;
}
#track-order-btn{
    width: 138px;
}
.returning-user-card {
    background: linear-gradient(135deg, #f0f8ff 0%, #e6f3ff 100%);
    border: 2px solid #b3d9ff;
    border-radius: 12px;
    padding: 16px;
    margin: 16px 0;
    text-align: center;
}

.returning-user-path {
    background: white;
    padding: 8px 12px;
    border-radius: 8px;
    font-weight: 500;
    color: #333;
    margin: 8px 0;
    font-size: 16px;
}

.continue-btn,
.start-over-btn {
    border: none;
    padding: 10px 20px;
    border-radius: 25px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 500;
    margin: 4px;
    transition: all 0.3s ease;
}

.continue-btn {
    background: var(--primary-color);
    color: white;
    box-shadow: 0 3px 12px rgba(102, 126, 234, 0.3);
}

.continue-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
}

.start-over-btn {
    background: white;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
}

.start-over-btn:hover {
    background: #f8f9ff;
    transform: translateY(-1px);
}

.get-started-btn {
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 25px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 600;
    margin-top: 8px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.get-started-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
}

.category-buttons {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 12px;
    margin-top: 12px;
}

.category-btn {
    border: none;
    padding: 12px 16px;
    border-radius: 12px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 500;
    transition: all 0.3s ease;
    text-align: center;
    background: #fd1d1d;
    color: white;
}

.category-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.services-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-top: 12px;
}

.service-btn {
    background: white;
    color: var(--primary-color);
    border: 2px solid #e0e6ff;
    padding: 12px 16px;
    border-radius: 12px;
    cursor: pointer;
    font-size: 16px;
    font-weight: 500;
    transition: all 0.3s ease;
    text-align: center;
}

.service-btn:hover {
    background: #f8f9ff;
    border-color: var(--primary-color);
    transform: translateY(-1px);
}

.navigation-message {
    background: linear-gradient(135deg, #fff8e1 0%, #ffecb3 100%);
    border: 2px solid #ffc107;
    border-radius: 12px;
    padding: 12px;
    margin: 12px 0;
    text-align: center;
    font-size: 14px;
    color: #f57c00;
}

.navigation-buttons-inline {
    display: flex;
    gap: 8px;
    justify-content: center;
    margin-top: 8px;
}

.nav-btn {
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 6px 12px;
    border-radius: 15px;
    cursor: pointer;
    font-size: 12px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.nav-btn.secondary {
    background: white;
    color: var(--primary-color);
    border: 1px solid var(--primary-color);
}

.nav-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

#cancel-flow-bar {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 6px 14px 4px;
  border-top: 1px solid #f0e8e8;
  background: #fdfafa;
}

#cancel-flow-bar button {
  background: none;
  border: 1px solid #e0b0b0;
  color: #b05050;
  font-size: 12px;
  font-weight: 500;
  padding: 5px 16px;
  border-radius: 20px;
  cursor: pointer;
  letter-spacing: 0.01em;
  transition: border-color 0.15s ease, color 0.15s ease, background 0.15s ease;
  line-height: 1.5;
}

#cancel-flow-bar button:hover {
  border-color: #c06060;
  color: #8b2020;
  background: #fff0f0;
}

.chat-input {
    margin: 12px;
    padding:8px;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    background: white;
}

.chat-input textarea {
     width: 100%;
     border: none;
      border-radius: 8px;
      font-size: 16px;
      font-family: inherit;
      resize: none;
      max-height: 200px;
      overflow-y: auto;
      line-height: 1.5;
      background: transparent;
    }

    .chat-input textarea:focus {
      outline: none;
    
    }

    .chat-input textarea::placeholder {
      color: #999;
    }

    .chat-input textarea:disabled {
      cursor: not-allowed;
    }

    /* Send button positioned inside textarea */
    #sendBtn  {
     
      width: 40px;
      height: 40px;
      background: var(--primary-color);
      color: white;
      border: none;
      border-radius: 8px;
      cursor: pointer;
      display: flex;
      align-items: center;
      justify-content: center;
      font-size: 18px;
      transition: all 0.3s ease;
      padding: 0;
      box-shadow: 0 2px 8px rgba(255, 71, 84, 0.2);
    }

   #sendBtn:hover:not(:disabled) {
      background: var(--primary-color);
      transform: scale(1.05);
      box-shadow: 0 3px 12px rgba(255, 71, 84, 0.3);
    }

   #sendBtn:disabled {
      background: #ccc;
      cursor: not-allowed;
      opacity: 0.5;
      box-shadow: none;
    }

   #sendBtn:active:not(:disabled) {
      transform: scale(0.95);
    }

    /* Arrow icon for send button */
   #sendBtn::before {
      content: '>';
      display: block;
      font-size: 20px;
      font-weight: bolder;
    }
    .emoji-svg{
        width: 18px;
        height: 18px;
        display: block;
    }
    .emoji-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 6px;
    line-height: 0;
    height: fit-content;
    border-radius: 50%;

    color: rgb(143 154 172);
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    padding: 0;
    font-size: 18px;
    background: none;
    }
    .emoji-btn.active {
        background: var(--primary-color);      
        color: #fff;          
    }
    .mic-btn{
       height: 22px;
        color: rgb(143 154 172);
        border: none;
        background: none;
        cursor: pointer;
        transition: transform 0.2s ease;
    }
     
    /* .mic-btn.listening {
        color: var(--primary-color);  
        animation: micPulse 1.2s infinite;
    } */
    .mic-wrapper {
  display: flex;
  align-items: center;
  gap: 10px;
}
/* mic css start */
/* Recording UI Container */
.recording-ui {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 14px;
  background: white;
  border-radius: 50px;
  box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
  gap: 16px;
  width: 100%;
  margin: 0 auto;
}

.recording-ui.hidden {
  display: none;
}

/* Cancel Button (X) */
.cancel-recording-btn {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: none;
  background: #f3f4f6;
  color: #6b7280;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: all 0.2s;
}

.cancel-recording-btn:hover {
  background: #e5e7eb;
  color: #374151;
}

.cancel-recording-btn:active {
  transform: scale(0.95);
}

/* Waveform */
.recording-waveform {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 3px;
  flex: 1;
  height: 36px;
}

.recording-waveform span {
  width: 3px;
  height: 4px;
  background: #9ca3af;
  border-radius: 2px;
  transition: height 0.1s ease;
}

/* Animated bars when active */
@keyframes wave {
  0%, 100% { height: 4px; }
  50% { height: 20px; }
}

.listening .recording-waveform span {
  background: var(--primary-color);
  animation: wave 1s ease-in-out infinite;
}

.listening .recording-waveform span:nth-child(1) { animation-delay: 0s; }
.listening .recording-waveform span:nth-child(2) { animation-delay: 0.1s; }
.listening .recording-waveform span:nth-child(3) { animation-delay: 0.2s; }
.listening .recording-waveform span:nth-child(4) { animation-delay: 0.3s; }
.listening .recording-waveform span:nth-child(5) { animation-delay: 0.4s; }
.listening .recording-waveform span:nth-child(6) { animation-delay: 0.5s; }
.listening .recording-waveform span:nth-child(7) { animation-delay: 0.4s; }
.listening .recording-waveform span:nth-child(8) { animation-delay: 0.3s; }
.listening .recording-waveform span:nth-child(9) { animation-delay: 0.2s; }
.listening .recording-waveform span:nth-child(10) { animation-delay: 0.1s; }

/* Stop/Send Button */
.stop-recording-btn {
  width: 36x;
  height: 36px;
  border-radius: 50%;
  border: none;
  background: var(--primary-color);
  color: white;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: all 0.2s;
}

.stop-recording-btn:hover {
  transform: scale(1.05);
}

.stop-recording-btn:active {
  transform: scale(0.95);
}

/* mic css end */

.hidden {
  display: none;
}

@keyframes micPulse {
  0% {
    transform: scale(1);
    opacity: 1;
  }
  50% {
    transform: scale(1.15);
    opacity: 0.6;
  }
  100% {
    transform: scale(1);
    opacity: 1;
  }
}
.clear-btn {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    border: none;
    font-size: 14px;
    padding: 6px 12px;
    border-radius: 15px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 500;
}

.clear-btn:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: scale(1.05);
}

.disabled-btn {
    opacity: 0.5;
    pointer-events: none;
    cursor: not-allowed;
}

.progress-dots {
    display: flex;
    justify-content: center;
    gap: 6px;
    padding: 12px;
    background: #f8f9ff;
}

.progress-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #ddd;
    transition: all 0.3s ease;
}

.progress-dot.active {
    background: var(--primary-color);
    transform: scale(1.2);
}

#chat::-webkit-scrollbar {
    width: 6px;
}

#chat::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 3px;
}

#chat::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 3px;
}



/* New styles for history button and screen */
.history-btn {
  background: #ffffff33;
  border: none;
  color: #fff;
  padding: 6px 12px;
  border-radius: 8px;
  cursor: pointer;
}

.history-btn:hover {
  background: #ffffff66;
}

#historyScreen {
  display: none;
  flex-direction: column;
  height: 100%;
  background: #f9f9f9;
  border-radius: 12px;
}



.back-btn {
  background: none;
  border: none;
  color: #fff;
  padding: 4px;
  border-radius: 6px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s ease;
}

.back-btn:hover {
  background: rgba(255, 255, 255, 0.2);
}

.history-list {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  padding: 12px;
}

.session-item {
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 8px;
  padding: 12px;
  margin-bottom: 8px;
  cursor: pointer;
  transition: background 0.2s;
}

.session-item:hover {
  background: #f0f8ff;
}

.session-name {
  font-weight: 600;
  color: #333;
}

.session-date {
  font-size: 12px;
  color: #666;
}

/* Mobile responsiveness */
@media (max-width: 768px) {
    #chatbot-widget {
        width: 55px;
        height: 55px;
        right: 15px;
        bottom: 15px;
        max-width: calc(100vw - 40px);
        max-height: calc(100vh - 40px);
    }
    
    /* When expanded on mobile */
    /* #chatbot-widget.expanded {
        width: calc(100vw - 40px);
        height: calc(100vh - 40px);
        right: 20px;
        left: 20px;
        bottom: 20px;
        top: 20px;
        border-radius: 16px;
        max-width: none;
        max-height: none;
    }
     */
    
    .category-buttons,
    .services-container {
        grid-template-columns: 1fr;
    }
    
    .bubble {
        max-width: 85%;
    }
    
   
    
    .chat-input textarea {
        /* padding: 10px 45px 10px 12px; */
        font-size: 16px;
    }
    
   #sendBtn {
        right: 18px;
        bottom: 18px;
        width: 36px;
        height: 36px;
        font-size: 16px;
    }
}

@media (max-width: 480px) {
    #chatbot-widget {
        width: 50px;
        height: 50px;
        right: 10px;
        bottom: 10px;
        max-width: calc(100vw - 20px);
        max-height: calc(100vh - 20px);
    }
    
    /* When expanded on small mobile */
    /* #chatbot-widget.expanded {
        width: calc(100vw - 20px);
        height: calc(100vh - 20px);
        right: 10px;
        left: 10px;
        bottom: 10px;
        top: 10px;
        border-radius: 16px;
        max-width: none;
        max-height: none;
    } */
    
        
    .bubble {
        max-width: 90%;
        padding: 10px 14px;
        font-size: 15px;
    }
    
    .chat-header {
        padding: 12px;
        font-size: 15px;
    }
        
    .chat-input textarea {
        font-size: 16px;
    }
    
   #sendBtn {
        right: 15px;
        bottom: 15px;
        width: 32px;
        height: 32px;
        font-size: 14px;
    }
}
/* Menu Options Container */
.menu-options {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 20px;
  width: 100%;
}

/* Menu Option Buttons */
.menu-option-btn {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 20px;
  background:var(--primary-color);
  color: white;
  border: none;
  border-radius: 12px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 4px 12px rgba(0, 123, 255, 0.2);
  width: 100%;
  text-align: left;
}

.menu-option-btn:hover {
  /* transform: translateY(-2px); */
  box-shadow: 0 6px 16px rgba(0, 123, 255, 0.3);
  /* background: linear-gradient(135deg, #0056b3 0%, var(--primary-color, #007bff) 100%); */
}


.menu-icon {
  font-size: 24px;
  flex-shrink: 0;
}

.menu-text {
  flex: 1;
}

/* Track Order Container */
.track-order-container {
  text-align: center;
  padding: 20px;
}

.track-order-container .welcome-icon {
  font-size: 48px;
  margin-bottom: 16px;
}

.track-order-container .welcome-title {
  font-size: 20px;
  font-weight: 600;
  margin-bottom: 8px;
  color: #333;
}

.track-order-container .welcome-text {
  font-size: 14px;
  color: #666;
  margin-bottom: 20px;
}

/* Back Button Styling */
.new-chat-btn {
  /* display: none; */
  background: rgba(255, 255, 255, 0.2);
  color: white;
  border: 1px solid rgba(255, 255, 255, 0.3);
  padding: 8px 16px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
}

.new-chat-btn:hover {
  background: rgba(255, 255, 255, 0.3);
  border-color: rgba(255, 255, 255, 0.5);
}

.new-chat-btn:active {
  transform: scale(0.98);
}

/* track order table css start */
.track-wrapper{
  /* border: 1px solid red; */
  padding: 16px;
}
.track-contain {
  width: 100%;
  max-width: 500px;
  margin: 0 auto;
  background: white;
  border-radius: 12px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  overflow: hidden;
}

.table-wrapper {
  overflow-x: auto;
  overflow-y: visible;
}

.table-wrapper::-webkit-scrollbar {
  height: 6px;
}

.table-wrapper::-webkit-scrollbar-track {
  background: #f1f1f1;
}

.table-wrapper::-webkit-scrollbar-thumb {
  background: #888;
  border-radius: 3px;
}

.table-wrapper::-webkit-scrollbar-thumb:hover {
  background: #555;
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
  /* min-width: 480px; */
}

thead {
  background: white;
  position: sticky;
  top: 0;
  z-index: 10;
}

th {
  padding: 12px 8px;
  text-align: center;
  font-weight: 600;
  color: #333;
  /* border-bottom: 2px solid #f0f0f0; */
  position: relative;
}

.track-dot {
  width: 6px;
  height: 6px;
  background: #ec4899;
  border-radius: 50%;
  margin: 0 auto 6px;
}

td {
  padding: 10px 8px;
  text-align: center;
  /* border-bottom: 1px solid #f0f0f0; */
  color: #666;
}

tbody tr:hover {
  background: #fafafa;
}

tbody tr:last-child td {
  border-bottom: none;
}

.target-cell {
  font-size: 11px;
  word-break: break-all;
}

.status {
  display: inline-block;
  padding: 3px 8px;
  border-radius: 12px;
  font-size: 11px;
  font-weight: 500;
}
#track-error{
    color: #333;
    padding: 16px 16px;
    border-radius: 18px;
    line-height: 1.4;
    word-wrap: break-word;
    max-width: 85%;
    margin: auto;
}

.avatar {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  object-fit: cover;
  margin-right: 4px;
  vertical-align: middle;
  border: 2px solid rgba(255, 255, 255, 0.25);
}

/* .status.processing {
  background: #e0e7ff;
  color: #4f46e5;
}

.status.completed {
  background: #d1fae5;
  color: #059669;
}

.status.failed {
  background: #fee2e2;
  color: #dc2626;
} */
/* track order table css ends */


/* Responsive Design */
@media (max-width: 480px) {
  .menu-option-btn {
    padding: 14px 16px;
    font-size: 15px;
  }
  
  .menu-icon {
    font-size: 20px;
  }
}
@media (max-width: 490px) {
 .chat-container{
    width: calc(100vw - 20px);
    left: 10px;
    top: 10px;
    bottom: 70px;
 }
 .emoji-picker{
    max-height: 200px;
 }


}
@media (max-width: 290px) {
 .chat-container{
    top: 10px;
    bottom: 70px;
 }
 .welcome-text{
    display: none;
 }

}