/* ExquisVin Concierge - brand-aligned chat widget
   Palette: cream #F8F3E9, burgundy #48101c, gold #CBAE74
   Type: Cormorant Garamond (serif), Inter (sans)
   Class prefix: ev- to avoid conflicts with host site.
*/

.ev-concierge, .ev-concierge * {
  box-sizing: border-box;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

.ev-concierge {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 9999;
  font-family: 'Inter', system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  color: #2b1013;
}

/* Trigger button */
.ev-trigger {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 22px;
  background: #48101c;
  color: #F8F3E9;
  border: 1px solid #48101c;
  border-radius: 999px;
  font-family: 'Cormorant Garamond', 'Playfair Display', Georgia, serif;
  font-size: 17px;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  cursor: pointer;
  box-shadow: 0 10px 30px rgba(72, 16, 28, 0.28);
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.ev-trigger:hover {
  background: #2b0a12;
  box-shadow: 0 14px 34px rgba(72, 16, 28, 0.36);
  transform: translateY(-1px);
}

.ev-trigger-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #CBAE74;
  display: inline-block;
}

.ev-concierge.ev-open .ev-trigger { display: none; }

/* Panel */
.ev-panel {
  display: none;
  flex-direction: column;
  width: 380px;
  height: 560px;
  max-height: calc(100vh - 40px);
  background: #F8F3E9;
  border: 1px solid rgba(72, 16, 28, 0.15);
  border-radius: 14px;
  box-shadow: 0 24px 60px rgba(20, 5, 8, 0.35);
  overflow: hidden;
}

.ev-concierge.ev-open .ev-panel { display: flex; }

/* Header */
.ev-header {
  padding: 18px 20px 14px;
  background: #48101c;
  color: #F8F3E9;
  border-bottom: 1px solid rgba(203, 174, 116, 0.35);
  position: relative;
}

.ev-header-title {
  font-family: 'Cormorant Garamond', 'Playfair Display', Georgia, serif;
  font-size: 20px;
  font-weight: 500;
  letter-spacing: 0.04em;
  line-height: 1.2;
  margin: 0;
}

.ev-header-sub {
  font-size: 11px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: #CBAE74;
  margin-top: 4px;
}

.ev-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 32px;
  height: 32px;
  border: none;
  background: transparent;
  color: #F8F3E9;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  border-radius: 50%;
  transition: background 0.15s ease;
}

.ev-close:hover { background: rgba(248, 243, 233, 0.12); }

/* Body */
.ev-body {
  flex: 1;
  overflow-y: auto;
  padding: 16px 18px 8px;
  background: #F8F3E9;
}

.ev-body::-webkit-scrollbar { width: 6px; }
.ev-body::-webkit-scrollbar-thumb { background: rgba(72, 16, 28, 0.25); border-radius: 3px; }

/* Messages */
.ev-msg {
  max-width: 88%;
  padding: 11px 14px;
  border-radius: 12px;
  font-size: 14px;
  line-height: 1.55;
  margin-bottom: 10px;
  word-wrap: break-word;
}

.ev-msg-bot {
  background: #FFFFFF;
  border: 1px solid rgba(72, 16, 28, 0.10);
  color: #2b1013;
  border-top-left-radius: 4px;
}

.ev-msg-user {
  background: #48101c;
  color: #F8F3E9;
  margin-left: auto;
  border-top-right-radius: 4px;
}

/* Chips (suggestions + related) */
.ev-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 4px 0 12px;
}

.ev-chips-label {
  width: 100%;
  font-size: 10px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: #7a5a1e;
  margin-bottom: 2px;
}

.ev-chip {
  padding: 7px 12px;
  border: 1px solid rgba(203, 174, 116, 0.6);
  background: transparent;
  color: #48101c;
  border-radius: 999px;
  font-size: 12.5px;
  cursor: pointer;
  font-family: inherit;
  transition: background 0.15s ease, border-color 0.15s ease;
}

.ev-chip:hover {
  background: rgba(203, 174, 116, 0.16);
  border-color: #CBAE74;
}

/* Input */
.ev-input-row {
  display: flex;
  gap: 8px;
  padding: 12px 14px 14px;
  border-top: 1px solid rgba(72, 16, 28, 0.12);
  background: #F8F3E9;
}

.ev-input {
  flex: 1;
  padding: 11px 14px;
  border: 1px solid rgba(72, 16, 28, 0.2);
  border-radius: 999px;
  background: #FFFFFF;
  font-family: inherit;
  font-size: 14px;
  color: #2b1013;
  outline: none;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.ev-input:focus {
  border-color: #CBAE74;
  box-shadow: 0 0 0 3px rgba(203, 174, 116, 0.18);
}

.ev-send {
  width: 44px;
  height: 44px;
  padding: 0;
  border: none;
  background: transparent;
  color: inherit;
  border-radius: 0;
  font-size: 26px;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: transform 0.15s ease, opacity 0.15s ease;
  flex-shrink: 0;
  opacity: 0.9;
}

.ev-send:hover { transform: scale(1.12); opacity: 1; }
.ev-send:disabled { opacity: 0.4; cursor: not-allowed; transform: none; }
.ev-send-icon { font-size: 26px; line-height: 1; }

/* Footer */
.ev-footer {
  padding: 8px 14px 12px;
  font-size: 10.5px;
  color: rgba(43, 16, 19, 0.6);
  text-align: center;
  background: #F8F3E9;
  line-height: 1.4;
}

/* Typing indicator */
.ev-typing {
  display: inline-flex;
  gap: 4px;
  padding: 4px 2px;
}
.ev-typing span {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #CBAE74;
  opacity: 0.4;
  animation: ev-blink 1.2s infinite;
}
.ev-typing span:nth-child(2) { animation-delay: 0.2s; }
.ev-typing span:nth-child(3) { animation-delay: 0.4s; }

@keyframes ev-blink {
  0%, 60%, 100% { opacity: 0.3; transform: translateY(0); }
  30% { opacity: 1; transform: translateY(-2px); }
}

/* Mobile: compact trigger, full-screen panel when open */
@media (max-width: 520px) {
  .ev-concierge {
    bottom: 14px;
    right: 14px;
    left: auto;
  }
  .ev-trigger {
    padding: 10px 16px;
    font-size: 13px;
    letter-spacing: 0.08em;
    gap: 7px;
    box-shadow: 0 8px 22px rgba(72, 16, 28, 0.32);
  }
  .ev-trigger-dot { width: 6px; height: 6px; }
  .ev-concierge.ev-open .ev-panel {
    position: fixed;
    inset: 0;
    width: 100vw;
    height: 100vh;
    max-height: 100vh;
    border-radius: 0;
    border: none;
  }
}
