/* ============================================
   Lumina Dental — AI Concierge Chatbot
   Mint / ice / ocean palette
   ============================================ */

#gcw-chat-bubble {
  position: fixed;
  bottom: 20px;
  right: 20px;
  background: linear-gradient(145deg, #0B2B33, #0E3A40);
  color: #F4FBFA;
  width: 62px;
  height: 62px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
  cursor: pointer;
  box-shadow: 0 10px 32px rgba(7, 26, 34, 0.35), 0 0 0 1px rgba(126, 221, 211, 0.35);
  z-index: 10000;
  overflow: hidden;
  white-space: nowrap;
  transition: width 0.5s ease, border-radius 0.5s ease, padding 0.5s ease, background 0.3s ease, box-shadow 0.3s ease;
  border: 1px solid rgba(126, 221, 211, 0.45);
}

#gcw-chat-bubble .gcw-bubble-icon {
  font-size: 26px;
  flex-shrink: 0;
  line-height: 1;
  display: flex;
  color: #7EDDD3;
}

#gcw-chat-bubble .gcw-bubble-text {
  max-width: 0;
  overflow: hidden;
  margin-left: 0;
  font-family: 'Sora', system-ui, sans-serif;
  font-size: 12.5px;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  white-space: nowrap;
  color: #F4FBFA !important;
  transition: max-width 0.6s ease 0.1s, margin-left 0.5s ease 0.1s;
}

#gcw-chat-bubble:hover,
#gcw-chat-bubble.show-text {
  width: 248px;
  border-radius: 32px;
  padding: 0 18px;
  justify-content: flex-start;
  background: linear-gradient(145deg, #0B2B33, #0E8F8A);
  box-shadow: 0 12px 36px rgba(14, 143, 138, 0.35), 0 0 24px rgba(126, 221, 211, 0.2);
}

#gcw-chat-bubble:hover .gcw-bubble-text,
#gcw-chat-bubble.show-text .gcw-bubble-text {
  max-width: 200px;
  margin-left: 12px;
}

#gcw-chat-container {
  position: fixed;
  bottom: 92px;
  right: 20px;
  width: 380px;
  height: 620px;
  background: linear-gradient(165deg, #F4FBFA 0%, #EAF7F5 55%, #D8F0ED 100%);
  border-radius: 24px;
  box-shadow: 0 20px 55px rgba(7, 26, 34, 0.28);
  display: flex;
  flex-direction: column;
  z-index: 10000;
  overflow: hidden;
  transition: all 0.3s;
  border: 1px solid rgba(126, 221, 211, 0.4);
  font-family: 'Sora', system-ui, sans-serif;
}

@media (max-height: 700px) {
  #gcw-chat-container {
    height: 90vh;
  }
}

.gcw-hidden {
  display: none !important;
}

#gcw-chat-header {
  background: linear-gradient(135deg, #071A22, #0B2B33);
  color: #F4FBFA;
  padding: 18px 20px;
  text-align: center;
  font-family: 'Fraunces', Georgia, serif;
  font-weight: 500;
  font-size: 1.15rem;
  letter-spacing: 0.03em;
  position: relative;
  border-bottom: 1px solid rgba(126, 221, 211, 0.3);
}

#gcw-chat-header::after {
  content: 'Your patient care concierge';
  display: block;
  font-family: 'Sora', system-ui, sans-serif;
  font-size: 0.62rem;
  font-weight: 400;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(126, 221, 211, 0.9);
  margin-top: 4px;
}

#gcw-close {
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(126, 221, 211, 0.15);
  color: #7EDDD3;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  cursor: pointer;
  transition: transform 0.2s, background 0.2s;
  border: 1px solid rgba(126, 221, 211, 0.35);
  line-height: 1;
}

#gcw-close:hover {
  transform: translateY(-50%) scale(1.08);
  background: rgba(126, 221, 211, 0.3);
}

#gcw-chat-messages {
  flex: 1;
  padding: 14px;
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
  touch-action: pan-y;
}

.gcw-message {
  margin: 10px 6px;
  padding: 12px 16px;
  border-radius: 18px;
  max-width: 84%;
  width: fit-content;
  word-wrap: break-word;
  font-size: 13.5px;
  line-height: 1.55;
  animation: gcwFadeIn 0.45s forwards;
}

.gcw-message.user {
  background: #0B2B33;
  color: #F4FBFA;
  margin-left: auto;
  border-bottom-right-radius: 6px;
}

.gcw-message.bot {
  background: #FFFFFF;
  color: #0B2B33;
  border: 1px solid rgba(11, 43, 51, 0.06);
  box-shadow: 0 4px 14px rgba(7, 26, 34, 0.05);
  border-bottom-left-radius: 6px;
}

.gcw-message img {
  max-width: 200px;
  border-radius: 12px;
  margin: 8px 0;
  display: block;
}

#gcw-suggestions {
  display: flex;
  gap: 8px;
  padding: 10px 14px 4px;
  overflow-x: auto;
  white-space: nowrap;
  scrollbar-width: none;
}

#gcw-suggestions::-webkit-scrollbar {
  display: none;
}

.gcw-suggestion {
  background: rgba(126, 221, 211, 0.2);
  color: #0B2B33;
  border: 1px solid rgba(43, 179, 168, 0.35);
  padding: 8px 14px;
  border-radius: 30px;
  cursor: pointer;
  font-size: 12.5px;
  font-family: inherit;
  flex-shrink: 0;
  transition: all 0.2s;
}

.gcw-suggestion:hover {
  transform: scale(1.04);
  background: rgba(126, 221, 211, 0.35);
}

.gcw-suggestion:active {
  transform: scale(0.96);
}

.gcw-calendly-btn,
.gcw-consult-btn {
  background: #0B2B33;
  color: #F4FBFA;
  border: none;
  padding: 11px 18px;
  border-radius: 30px;
  cursor: pointer;
  font-size: 12.5px;
  font-family: inherit;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin: 5px 15px;
  align-self: flex-start;
  transition: all 0.2s;
  border: 1px solid rgba(126, 221, 211, 0.5);
}

.gcw-calendly-btn:hover,
.gcw-consult-btn:hover {
  transform: scale(1.04);
  background: #0E8F8A;
}

.gcw-calendly-btn:active,
.gcw-consult-btn:active {
  transform: scale(0.96);
}

.gcw-learn-more-btn {
  background: transparent;
  color: #0E8F8A;
  border: 1px solid rgba(14, 143, 138, 0.4);
  padding: 10px 16px;
  border-radius: 30px;
  cursor: pointer;
  font-size: 13px;
  font-family: inherit;
  margin: 5px 15px;
  align-self: flex-start;
  transition: all 0.2s;
}

.gcw-learn-more-btn:hover {
  transform: scale(1.04);
  background: rgba(126, 221, 211, 0.15);
  border-color: #0E8F8A;
}

.gcw-learn-more-btn:active {
  transform: scale(0.96);
}

#gcw-chat-input-area {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 10px;
  padding-top: 4px;
  border-top: 1px solid rgba(11, 43, 51, 0.06);
}

.gcw-input-wrapper {
  position: relative;
  flex: 1;
  background: #FFFFFF;
  border: 1px solid rgba(11, 43, 51, 0.1);
  border-radius: 30px;
  height: 40px;
  display: flex;
  align-items: center;
  box-shadow: 0 2px 8px rgba(7, 26, 34, 0.04);
}

#gcw-user-input {
  width: 100%;
  height: 100%;
  padding: 0 80px 0 16px;
  background: transparent;
  color: #0B2B33;
  border: none;
  font-size: 13px;
  font-family: inherit;
  outline: none;
  line-height: 40px;
  box-sizing: border-box;
  cursor: text;
}

#gcw-user-input::placeholder {
  color: rgba(11, 43, 51, 0.4);
  font-size: 13px;
}

#gcw-attach-btn,
#gcw-voice-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: transparent;
  border: none;
  color: rgba(11, 43, 51, 0.5);
  cursor: pointer;
  padding: 0;
  width: 20px;
  height: 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color 0.3s ease;
}

#gcw-attach-btn svg,
#gcw-voice-btn svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

#gcw-attach-btn {
  right: 46px;
}

#gcw-voice-btn {
  right: 14px;
}

#gcw-attach-btn:hover,
#gcw-voice-btn:hover {
  color: #0E8F8A;
}

#gcw-voice-btn.recording {
  color: #E07A7A;
}

#gcw-voice-btn.recording svg {
  animation: gcwPulse 1.5s infinite;
}

#gcw-send-btn {
  background: #0B2B33;
  color: #7EDDD3;
  border: none;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s;
  flex-shrink: 0;
  border: 1px solid rgba(126, 221, 211, 0.4);
}

#gcw-send-btn:hover {
  transform: scale(1.08);
  background: #0E8F8A;
  color: #F4FBFA;
}

#gcw-send-btn:active {
  transform: scale(0.92);
}

#gcw-pending-preview {
  display: none;
  padding: 0 15px 8px;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: flex-start;
}

#gcw-pending-preview.visible {
  display: flex;
}

.gcw-preview-item {
  position: relative;
}

.gcw-preview-item img {
  max-width: 70px;
  border-radius: 12px;
  display: block;
  border: 1px solid rgba(11, 43, 51, 0.08);
}

.gcw-preview-item button {
  position: absolute;
  top: -6px;
  right: -6px;
  background: #0B2B33;
  color: #F4FBFA;
  border: none;
  border-radius: 50%;
  width: 22px;
  height: 22px;
  font-size: 14px;
  line-height: 1;
  cursor: pointer;
}

@keyframes gcwFadeIn {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes gcwPulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.15); }
  100% { transform: scale(1); }
}

@media (max-width: 768px) {
  #gcw-chat-container {
    width: calc(100vw - 40px) !important;
    height: 78vh !important;
    max-height: 78vh !important;
    bottom: 90px !important;
    left: 50% !important;
    transform: translateX(-50%) !important;
    border-radius: 22px !important;
  }

  #gcw-close {
    width: 44px;
    height: 44px;
    font-size: 26px;
  }

  body.gcw-chat-mobile-open {
    overflow: hidden;
  }

  .gcw-input-wrapper {
    height: 44px;
  }

  #gcw-user-input {
    font-size: 16px !important;
    line-height: 44px !important;
    padding: 0 80px 0 16px !important;
  }

  #gcw-user-input::placeholder {
    font-size: 16px !important;
    opacity: 0.75;
  }

  #gcw-user-input:focus {
    outline: none;
  }
}

/* Custom cursor site: allow normal pointer on chat */
#gcw-chat-bubble,
#gcw-chat-container,
#gcw-chat-container button,
#gcw-chat-container input {
  cursor: pointer;
}

#gcw-user-input {
  cursor: text;
}
