/* Chat widget - Smart Assistant (image-style) */
#agb-chat-fab {
  position: fixed;
  bottom: 24px;
  right: 24px;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: linear-gradient(135deg, #1b5e20 0%, #2e7d32 50%, #43a047 100%);
  color: #fff;
  border: none;
  box-shadow: 0 4px 16px rgba(46, 125, 50, 0.45);
  cursor: pointer;
  z-index: 9998;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s, box-shadow 0.2s;
  overflow: hidden;
  animation: agb-fab-pulse 2.5s ease-in-out infinite;
}
#agb-chat-fab:hover {
  transform: scale(1.08);
  box-shadow: 0 6px 24px rgba(46, 125, 50, 0.55);
  animation: none;
}
.agb-fab-icon-wrap {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #fff;
  animation: agb-fab-icon-bounce 2s ease-in-out infinite;
}
#agb-chat-fab img.agb-fab-favicon {
  width: 28px;
  height: 28px;
  object-fit: contain;
}
#agb-chat-fab:hover .agb-fab-icon-wrap {
  animation: none;
}
@keyframes agb-fab-pulse {
  0%, 100% { box-shadow: 0 4px 16px rgba(46, 125, 50, 0.45); }
  50% { box-shadow: 0 4px 24px rgba(46, 125, 50, 0.7), 0 0 0 8px rgba(46, 125, 50, 0.15); }
}
@keyframes agb-fab-icon-bounce {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.1); }
}

#agb-chat-box {
  position: fixed;
  bottom: 90px;
  right: 24px;
  width: 380px;
  max-width: calc(100vw - 48px);
  height: 540px;
  max-height: calc(100vh - 120px);
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 12px 48px rgba(0,0,0,0.15);
  z-index: 9999;
  display: none;
  flex-direction: column;
  overflow: hidden;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}
#agb-chat-box.agb-chat-open {
  display: flex;
}

/* Green gradient header - image style */
.agb-chat-header {
  background: linear-gradient(90deg, #1b5e20 0%, #2e7d32 40%, #388e3c 70%, #43a047 100%);
  color: #fff;
  padding: 16px 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-shrink: 0;
}
.agb-chat-brand {
  display: flex;
  align-items: center;
  gap: 12px;
}
.agb-chat-logo {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #c62828;
  font-size: 1.15rem;
  box-shadow: 0 2px 6px rgba(0,0,0,0.12);
}
.agb-chat-brand-text h4 {
  margin: 0;
  font-size: 1.1rem;
  font-weight: 700;
  color: #fff;
  letter-spacing: 0.02em;
}
.agb-chat-brand-text span {
  font-size: 0.82rem;
  color: rgba(255,255,255,0.95);
  display: block;
  margin-top: 2px;
}
.agb-chat-close {
  background: rgba(255,255,255,0.15);
  border: none;
  color: #fff;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  transition: background 0.2s;
}
.agb-chat-close:hover {
  background: rgba(255,255,255,0.25);
}

.agb-chat-body {
  flex: 1;
  overflow-y: auto;
  padding: 18px;
  background: #f5f5f5;
}
.agb-chat-bubble {
  background: #e8e8e8;
  color: #333;
  padding: 14px 16px;
  border-radius: 12px;
  font-size: 0.92rem;
  line-height: 1.5;
  margin-bottom: 16px;
  max-width: 95%;
}
.agb-chat-bubble.agb-greeting {
  background: #e8e8e8;
  color: #333;
}
.agb-chat-quick-replies {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 14px;
}
/* Light grey rounded buttons - image style */
.agb-chat-quick-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  background: #e8e8e8;
  border: 1px solid #e0e0e0;
  border-radius: 10px;
  font-size: 0.85rem;
  font-weight: 500;
  color: #333;
  cursor: pointer;
  text-align: left;
  transition: background 0.2s, border-color 0.2s, box-shadow 0.2s;
}
.agb-chat-quick-btn:hover {
  background: #fff;
  border-color: #2e7d32;
  box-shadow: 0 2px 8px rgba(46, 125, 50, 0.15);
  color: #1b5e20;
}
.agb-chat-quick-btn i {
  font-size: 1rem;
  color: #2e7d32;
  flex-shrink: 0;
}
.agb-chat-quick-btn:hover i {
  color: #1b5e20;
}

.agb-chat-footer-wrap {
  flex-shrink: 0;
  background: #fff;
  border-top: 1px solid #e0e0e0;
  padding: 14px 16px 12px;
}
.agb-chat-footer {
  display: flex;
  gap: 10px;
  align-items: center;
}
.agb-chat-input {
  flex: 1;
  padding: 12px 18px;
  border: 1px solid #e0e0e0;
  border-radius: 24px;
  font-size: 0.9rem;
  outline: none;
  transition: border-color 0.2s;
  background: #f5f5f5;
}
.agb-chat-input::placeholder {
  color: #757575;
}
.agb-chat-input:focus {
  border-color: #2e7d32;
  background: #fff;
}
/* Green send button - paper plane - image style */
.agb-chat-send {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: linear-gradient(135deg, #2e7d32 0%, #43a047 100%);
  color: #fff;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.05rem;
  transition: background 0.2s, transform 0.2s;
  box-shadow: 0 2px 8px rgba(46, 125, 50, 0.35);
}
.agb-chat-send:hover {
  background: linear-gradient(135deg, #1b5e20 0%, #2e7d32 100%);
  transform: scale(1.05);
  box-shadow: 0 4px 12px rgba(46, 125, 50, 0.4);
}
.agb-chat-disclaimer {
  margin: 8px 0 0 0;
  font-size: 0.7rem;
  color: #757575;
  line-height: 1.3;
}

/* Booking flow - step by step */
.agb-booking-flow {
  margin-top: 0;
}
.agb-booking-step {
  margin-bottom: 12px;
}
.agb-select-wrap {
  margin-bottom: 10px;
}
.agb-select-wrap .select2-container {
  width: 100% !important;
}
.agb-select-wrap .select2-container .select2-selection--single {
  height: 42px;
  padding: 6px 12px;
  border: 1px solid #dee2e6;
  border-radius: 8px;
  font-size: 0.9rem;
}
.agb-select-wrap .select2-container--default .select2-selection--single .select2-selection__rendered {
  line-height: 28px;
}
.agb-select-wrap .select2-container--default .select2-selection--single .select2-selection__arrow {
  height: 40px;
}
.agb-select,
.agb-input {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid #dee2e6;
  border-radius: 8px;
  font-size: 0.9rem;
  margin-bottom: 10px;
  background: #fff;
  outline: none;
}
.agb-select:focus,
.agb-input:focus {
  border-color: #0d6efd;
}
.agb-field {
  margin-bottom: 10px;
}
.agb-field label {
  display: block;
  font-size: 0.85rem;
  color: #555;
  margin-bottom: 4px;
}
.agb-date-wrap {
  cursor: pointer;
  padding: 4px 0;
  border-radius: 8px;
  transition: background 0.2s;
}
.agb-date-wrap:hover {
  background: rgba(46, 125, 50, 0.06);
}
.agb-trip-type {
  display: flex;
  gap: 12px;
  margin-bottom: 12px;
}
.agb-radio-wrap {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.9rem;
  cursor: pointer;
}
.agb-radio-wrap input {
  margin: 0;
}
.agb-step-actions {
  display: flex;
  gap: 8px;
  margin-top: 12px;
  flex-wrap: wrap;
}
.agb-btn-primary,
.agb-btn-secondary {
  padding: 8px 14px;
  border-radius: 8px;
  font-size: 0.85rem;
  cursor: pointer;
  border: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.agb-btn-primary {
  background: linear-gradient(135deg, #2e7d32 0%, #43a047 100%);
  color: #fff;
}
.agb-btn-primary:hover {
  background: linear-gradient(135deg, #1b5e20 0%, #2e7d32 100%);
}
.agb-btn-secondary {
  background: #e9ecef;
  color: #333;
}
.agb-btn-secondary:hover {
  background: #dee2e6;
}
.agb-summary {
  background: #fff;
  border: 1px solid #dee2e6;
  border-radius: 8px;
  padding: 12px;
  font-size: 0.85rem;
  margin-bottom: 10px;
}
.agb-summary p {
  margin: 0 0 6px 0;
}
.agb-summary p:last-child {
  margin-bottom: 0;
}
.agb-btn-whatsapp {
  background: #25d366 !important;
}
.agb-btn-whatsapp:hover {
  background: #20bd5a !important;
}

@media (max-width: 480px) {
  #agb-chat-box {
    width: calc(100vw - 32px);
    right: 16px;
    bottom: 80px;
    height: 70vh;
  }
  #agb-chat-fab {
    right: 16px;
    bottom: 16px;
  }
}
