/* ================================================================
   24/7 Chatbot widget
   ================================================================ */
.chatbot-toggle-btn {
  position: fixed; left: 20px; bottom: 20px; z-index: 140;
  width: 58px; height: 58px; border-radius: 50%; background: var(--brand-dark, #1F6B24); color: #fff;
  border: none; box-shadow: 0 8px 24px rgba(0,0,0,0.25); cursor: pointer;
  display: flex; align-items: center; justify-content: center;
}
.chatbot-toggle-btn:hover { background: var(--brand, #3C9F40); }

.chatbot-window {
  display: none; position: fixed; left: 20px; bottom: 90px; z-index: 141;
  width: 340px; max-width: calc(100vw - 40px); height: 480px; max-height: 70vh;
  background: #fff; border-radius: 16px; box-shadow: 0 16px 48px rgba(0,0,0,0.25);
  flex-direction: column; overflow: hidden;
}
.chatbot-window.open { display: flex; }
.chatbot-header {
  background: var(--brand-dark, #1F6B24); color: #fff; padding: 14px 16px;
  display: flex; align-items: center; justify-content: space-between; font-weight: 700; font-size: 14px;
}
.chatbot-header-actions { display: flex; align-items: center; gap: 10px; }
.chatbot-header button { background: none; border: none; color: #fff; font-size: 22px; cursor: pointer; line-height: 1; }
.chatbot-end-btn {
  font-size: 11.5px !important; font-weight: 600; padding: 5px 10px; border-radius: 14px !important;
  border: 1px solid rgba(255,255,255,0.5) !important; line-height: normal !important;
}
.chatbot-end-btn:hover { background: rgba(255,255,255,0.15) !important; }
.chatbot-messages { flex: 1; overflow-y: auto; padding: 14px; display: flex; flex-direction: column; gap: 8px; background: #F7F7F4; }

.chatbot-bubble { max-width: 85%; padding: 9px 13px; border-radius: 14px; font-size: 13.5px; line-height: 1.4; }
.chatbot-bubble-bot { align-self: flex-start; background: #fff; border: 1px solid #E4E4DE; border-bottom-left-radius: 4px; }
.chatbot-bubble-user { align-self: flex-end; background: var(--brand-dark, #1F6B24); color: #fff; border-bottom-right-radius: 4px; }

.chatbot-quick-replies { display: flex; flex-wrap: wrap; gap: 6px; }
.chatbot-quick-reply-btn {
  padding: 7px 12px; border-radius: 16px; border: 1.5px solid var(--brand-dark, #1F6B24); background: #fff;
  color: var(--brand-dark, #1F6B24); font-size: 12.5px; font-weight: 600; cursor: pointer;
}
.chatbot-quick-reply-btn:hover { background: var(--brand-tint, #EAF3DE); }

.chatbot-product-card {
  display: flex; align-items: center; gap: 10px; background: #fff; border: 1px solid #E4E4DE;
  border-radius: 12px; padding: 8px; align-self: flex-start; max-width: 92%;
}
.chatbot-product-thumb { width: 44px; height: 44px; border-radius: 8px; background: var(--brand-tint, #EAF3DE); flex-shrink: 0; overflow: hidden; display: flex; align-items: center; justify-content: center; }
.chatbot-product-thumb img { width: 100%; height: 100%; object-fit: cover; }
.chatbot-product-thumb-placeholder { color: var(--brand-dark, #1F6B24); font-weight: 700; font-size: 13px; }
.chatbot-product-info { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.chatbot-product-info strong { font-size: 12.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.chatbot-product-price { font-size: 12.5px; font-weight: 700; color: var(--brand-dark, #1F6B24); }
.chatbot-product-actions { display: flex; flex-direction: column; gap: 4px; flex-shrink: 0; }
.chatbot-btn-sm {
  font-size: 11px; padding: 5px 9px; border-radius: 8px; border: 1px solid #E4E4DE; background: #fff;
  color: #1B1B18; text-align: center; white-space: nowrap; cursor: pointer; text-decoration: none;
}
.chatbot-btn-sm.chatbot-btn-primary { background: var(--brand-dark, #1F6B24); color: #fff; border-color: var(--brand-dark, #1F6B24); }

.chatbot-input-row { display: flex; border-top: 1px solid #E4E4DE; padding: 8px; gap: 6px; }
.chatbot-input-row input {
  flex: 1; border: 1px solid #E4E4DE; border-radius: 20px; padding: 8px 14px; font-size: 13px; outline: none;
}
.chatbot-input-row button {
  width: 36px; height: 36px; border-radius: 50%; border: none; background: var(--brand-dark, #1F6B24); color: #fff;
  cursor: pointer; display: flex; align-items: center; justify-content: center; flex-shrink: 0;
}

@media (max-width: 480px) {
  .chatbot-window { left: 10px; right: 10px; bottom: 80px; width: auto; }
  .chatbot-toggle-btn { left: 14px; bottom: 78px; width: 52px; height: 52px; }
}