/* ============================================
   Hawaii Guide - Booking Chat Page Styles
   /book - Full-page AI travel planner
   ============================================ */

/* Page Layout */
#booking-chat-page {
  padding: 0;
  margin: 0 auto;
  max-width: 100%;
}

#booking-chat-page > .column {
  padding: 0;
}

.booking-chat-container {
  display: flex;
  flex-direction: column;
  height: calc(100vh - 90px);
  max-width: 860px;
  margin: 0 auto;
  background: #fff;
  position: relative;
}

/* Header */
.booking-header {
  background: linear-gradient(135deg, #059669 0%, #047857 100%);
  padding: 0;
  flex-shrink: 0;
}

.booking-header-inner {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px 24px;
  max-width: 860px;
  margin: 0 auto;
}

.booking-header-avatar {
  position: relative;
  flex-shrink: 0;
}

.booking-header-avatar img {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  border: 3px solid rgba(255,255,255,0.3);
  object-fit: cover;
}

.booking-status-dot {
  position: absolute;
  bottom: 2px;
  right: 2px;
  width: 14px;
  height: 14px;
  background: #86efac;
  border: 3px solid #047857;
  border-radius: 50%;
  animation: booking-blink 2s infinite;
}

@keyframes booking-blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.6; }
}

.booking-header-text {
  color: #fff;
}

.booking-header-text h1 {
  margin: 0;
  font-size: 22px;
  font-weight: 700;
  color: #fff;
  line-height: 1.2;
}

.booking-header-text p {
  margin: 4px 0 0;
  font-size: 14px;
  opacity: 0.9;
  color: rgba(255,255,255,0.9);
}

/* Messages Area */
.booking-messages {
  flex: 1;
  overflow-y: auto;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  background: linear-gradient(180deg, #f0fdf4 0%, #fff 40%);
}

.booking-messages::-webkit-scrollbar {
  width: 6px;
}
.booking-messages::-webkit-scrollbar-track {
  background: transparent;
}
.booking-messages::-webkit-scrollbar-thumb {
  background: #d1d5db;
  border-radius: 3px;
}

/* Welcome Screen */
.booking-welcome {
  text-align: center;
  padding: 40px 20px 20px;
  max-width: 600px;
  margin: 0 auto;
}

.booking-welcome-icon img {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  border: 3px solid #059669;
  margin-bottom: 16px;
}

.booking-welcome h2 {
  margin: 0 0 12px;
  font-size: 24px;
  color: #1f2937;
  font-weight: 700;
}

.booking-welcome p {
  margin: 0 0 28px;
  color: #6b7280;
  font-size: 15px;
  line-height: 1.6;
}

/* Category Buttons */
.booking-categories {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  max-width: 520px;
  margin: 0 auto;
}

.booking-cat-btn {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 16px 12px;
  background: #fff;
  border: 2px solid #e5e7eb;
  border-radius: 16px;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: inherit;
}

.booking-cat-btn:hover {
  border-color: #059669;
  background: #f0fdf4;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(5, 150, 105, 0.15);
}

.booking-cat-icon {
  width: 44px;
  height: 44px;
  background: #f0fdf4;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #059669;
  transition: all 0.2s ease;
}

.booking-cat-btn:hover .booking-cat-icon {
  background: #059669;
  color: #fff;
}

.booking-cat-label {
  font-size: 13px;
  font-weight: 600;
  color: #374151;
}

/* Chat Messages */
.booking-msg {
  max-width: 80%;
  animation: booking-fade-in 0.3s ease;
}

@keyframes booking-fade-in {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

.booking-msg.bot {
  align-self: flex-start;
}

.booking-msg.user {
  align-self: flex-end;
}

.booking-msg-bubble {
  padding: 16px 20px;
  border-radius: 20px;
  font-size: 15px;
  line-height: 1.6;
}

.booking-msg.bot .booking-msg-bubble {
  background: #fff;
  color: #1f2937;
  border: 1px solid #e5e7eb;
  border-bottom-left-radius: 6px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.booking-msg.user .booking-msg-bubble {
  background: linear-gradient(135deg, #059669 0%, #047857 100%);
  color: #fff;
  border-bottom-right-radius: 6px;
}

/* Recommendation Cards */
.booking-recs {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 14px;
}

.booking-rec-card {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 14px;
  text-decoration: none;
  color: #1f2937;
  transition: all 0.2s ease;
}

.booking-rec-card:hover {
  border-color: #059669;
  box-shadow: 0 4px 12px rgba(5, 150, 105, 0.12);
  text-decoration: none;
  color: #1f2937;
}

.booking-rec-icon {
  width: 44px;
  height: 44px;
  background: #f0fdf4;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  flex-shrink: 0;
}

.booking-rec-info {
  flex: 1;
  min-width: 0;
}

.booking-rec-name {
  font-weight: 600;
  font-size: 14px;
  margin-bottom: 2px;
}

.booking-rec-desc {
  font-size: 13px;
  color: #6b7280;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.booking-rec-arrow {
  color: #059669;
  font-size: 20px;
  flex-shrink: 0;
}

/* Suggested Action Buttons */
.booking-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.booking-action-btn {
  padding: 8px 16px;
  background: #f0fdf4;
  border: 1px solid #10b981;
  border-radius: 20px;
  color: #047857;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
  font-family: inherit;
}

.booking-action-btn:hover {
  background: #059669;
  color: #fff;
  border-color: #059669;
}

/* Typing Indicator */
.booking-typing {
  display: flex;
  gap: 5px;
  padding: 16px 20px;
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 20px;
  border-bottom-left-radius: 6px;
  width: fit-content;
  box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.booking-typing span {
  width: 8px;
  height: 8px;
  background: #059669;
  border-radius: 50%;
  animation: booking-bounce 1.4s infinite;
}

.booking-typing span:nth-child(2) { animation-delay: 0.2s; }
.booking-typing span:nth-child(3) { animation-delay: 0.4s; }

@keyframes booking-bounce {
  0%, 60%, 100% { transform: translateY(0); }
  30% { transform: translateY(-8px); }
}

/* Input Area */
.booking-input-area {
  padding: 16px 24px 12px;
  background: #fff;
  border-top: 1px solid #e5e7eb;
  flex-shrink: 0;
}

.booking-input-wrapper {
  display: flex;
  align-items: flex-end;
  gap: 12px;
  background: #f9fafb;
  border: 2px solid #e5e7eb;
  border-radius: 24px;
  padding: 6px 6px 6px 18px;
  transition: border-color 0.2s ease;
}

.booking-input-wrapper:focus-within {
  border-color: #059669;
  background: #fff;
}

.booking-input {
  flex: 1;
  border: none;
  background: transparent;
  font-size: 15px;
  font-family: inherit;
  resize: none;
  outline: none;
  max-height: 120px;
  min-height: 24px;
  padding: 10px 0;
  line-height: 1.4;
  color: #1f2937;
  box-sizing: border-box;
}

.booking-input::placeholder {
  color: #9ca3af;
}

.booking-send-btn {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: linear-gradient(135deg, #059669 0%, #047857 100%);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

.booking-send-btn:hover:not(:disabled) {
  transform: scale(1.05);
  box-shadow: 0 4px 12px rgba(5, 150, 105, 0.3);
}

.booking-send-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.booking-send-btn svg {
  fill: white;
}

.booking-disclaimer {
  text-align: center;
  font-size: 12px;
  color: #9ca3af;
  margin: 8px 0 0;
}

.booking-disclaimer a {
  color: #6b7280;
  text-decoration: underline;
}

/* Markdown in bot messages */
.booking-msg.bot .booking-msg-bubble a {
  color: #059669;
  text-decoration: underline;
}

.booking-msg.bot .booking-msg-bubble strong {
  font-weight: 600;
}

.booking-msg.bot .booking-msg-bubble ul,
.booking-msg.bot .booking-msg-bubble ol {
  margin: 8px 0;
  padding-left: 20px;
}

.booking-msg.bot .booking-msg-bubble li {
  margin-bottom: 4px;
}

/* Mobile Responsive */
@media (max-width: 767px) {
  .booking-chat-container {
    height: calc(100vh - 60px);
  }

  .booking-header-inner {
    padding: 16px;
  }

  .booking-header-avatar img {
    width: 44px;
    height: 44px;
  }

  .booking-header-text h1 {
    font-size: 18px;
  }

  .booking-header-text p {
    font-size: 12px;
  }

  .booking-messages {
    padding: 16px;
  }

  .booking-welcome {
    padding: 20px 10px 10px;
  }

  .booking-welcome h2 {
    font-size: 20px;
  }

  .booking-categories {
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
  }

  .booking-msg {
    max-width: 90%;
  }

  .booking-input-area {
    padding: 12px 16px 8px;
  }

  .booking-rec-desc {
    white-space: normal;
  }
}

@media (max-width: 480px) {
  .booking-categories {
    grid-template-columns: repeat(2, 1fr);
  }

  .booking-cat-btn {
    padding: 12px 8px;
  }

  .booking-cat-label {
    font-size: 12px;
  }
}

/* Hide progress bar on booking chat page */
.booking-chat-page .progress-container,
.booking-chat-page .goUS-header.is-sticky .progress-container {
  display: none !important;
  visibility: hidden !important;
}

/* Override Foundation/site textarea styles (textarea default: 200px, main textarea: 45px) */
.booking-chat-page main textarea.booking-input,
textarea.booking-input {
  height: auto !important;
  min-height: 24px !important;
  max-height: 120px !important;
  margin: 0 !important;
  margin-bottom: 0 !important;
  padding: 10px 0 !important;
  background: transparent !important;
  background-color: transparent !important;
  border: none !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  -webkit-box-shadow: none !important;
  color: #1f2937 !important;
  display: block;
}

/* Hide site footer on this page for cleaner chat experience */
#booking-chat-page ~ .social-bar,
.booking-chat-page .social-bar {
  display: none;
}
