/* La Ola Dulce ChatBot widget — autocontenido, sin dependencias externas */
#lod-chat-btn {
  position: fixed;
  bottom: 96px; right: 20px;
  width: 60px; height: 60px;
  background: #ff2f96;
  color: #fff;
  border: 0;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer;
  z-index: 9998;
  box-shadow: 0 8px 24px rgba(255,47,150,0.35), 0 4px 12px rgba(0,0,0,0.2);
  transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
  padding: 0;
}
#lod-chat-btn:hover { transform: translateY(-3px) scale(1.08); box-shadow: 0 14px 32px rgba(255,47,150,0.45), 0 8px 20px rgba(0,0,0,0.25); background: #d81c7c; }
#lod-chat-btn svg { width: 30px; height: 30px; fill: #fff; }
@media (max-width:768px) { #lod-chat-btn { width: 52px; height: 52px; bottom: 148px; right: 16px; } #lod-chat-btn svg { width: 26px; height: 26px; } }

#lod-chat-panel {
  position: fixed;
  bottom: 164px; right: 20px;
  width: min(380px, calc(100vw - 32px));
  height: min(560px, calc(100vh - 200px));
  background: #fff;
  border-radius: 1.1rem;
  box-shadow: 0 20px 60px rgba(140,40,90,0.25), 0 4px 16px rgba(0,0,0,0.12);
  z-index: 9998;
  display: none;
  flex-direction: column;
  overflow: hidden;
  font-family: 'Segoe UI', Arial, Helvetica, sans-serif;
}
#lod-chat-panel.open { display: flex; }
@media (max-width:768px) {
  #lod-chat-panel {
    bottom: 208px; right: 16px;
    width: calc(100vw - 32px);
    height: min(440px, 60vh);
    height: min(440px, 60dvh);
  }
}

.lod-chat-header {
  background: #3a1526;
  color: #fff;
  padding: 0.9rem 1rem;
  display: flex; align-items: center; gap: 0.65rem;
  flex-shrink: 0;
}
.lod-chat-header-avatar { width: 34px; height: 34px; border-radius: 50%; background: #ff2f96; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.lod-chat-header-avatar svg { width: 20px; height: 20px; fill: #fff; }
.lod-chat-header-text { flex: 1; min-width: 0; }
.lod-chat-header-text strong { display: block; font-size: 0.95rem; font-weight: 700; }
.lod-chat-header-text span { display: block; font-size: 0.75rem; color: rgba(255,255,255,0.7); }
.lod-chat-close { background: none; border: 0; color: #fff; font-size: 1.4rem; line-height: 1; cursor: pointer; padding: 0.25rem 0.4rem; opacity: 0.8; }
.lod-chat-close:hover { opacity: 1; }

.lod-chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 1rem;
  display: flex; flex-direction: column; gap: 0.65rem;
  background: #fdf1f5;
}
.lod-chat-msg { max-width: 85%; padding: 0.6rem 0.85rem; border-radius: 0.75rem; font-size: 0.88rem; line-height: 1.45; }
.lod-chat-msg.bot { align-self: flex-start; background: #fff; color: #3a1526; border: 1px solid #f1d3e0; border-bottom-left-radius: 0.2rem; }
.lod-chat-msg.user { align-self: flex-end; background: #3a1526; color: #fff; border-bottom-right-radius: 0.2rem; }
.lod-chat-msg a { color: #d81c7c; font-weight: 700; }
.lod-chat-msg.user a { color: #fff; text-decoration: underline; }

.lod-chat-chips { display: flex; flex-wrap: wrap; gap: 0.4rem; align-self: flex-start; max-width: 100%; }
.lod-chat-chip { background: #fff; border: 1px solid #f1d3e0; color: #3a1526; font-size: 0.8rem; padding: 0.4rem 0.7rem; border-radius: 999px; cursor: pointer; text-align: left; text-decoration: none; display: inline-block; }
.lod-chat-chip:hover { border-color: #ff2f96; color: #d81c7c; }

.lod-chat-results { align-self: stretch; display: flex; flex-direction: column; gap: 0.5rem; }
.lod-chat-result {
  display: grid; grid-template-columns: 1fr auto; column-gap: 0.5rem; row-gap: 0.15rem;
  background: #fff; border: 1px solid #f1d3e0; border-radius: 0.75rem; padding: 0.65rem 0.85rem;
  text-decoration: none; color: inherit;
}
.lod-chat-result:hover { border-color: #ff2f96; }
.lod-chat-result__cat { grid-column: 1 / -1; font-size: 0.68rem; font-weight: 700; color: #8f4a63; text-transform: uppercase; letter-spacing: 0.4px; }
.lod-chat-result__name { font-size: 0.88rem; color: #3a1526; }
.lod-chat-result__price { font-size: 0.8rem; font-weight: 800; color: #d81c7c; white-space: nowrap; }
.lod-chat-result__link { grid-column: 1 / -1; font-size: 0.76rem; font-weight: 700; color: #d81c7c; margin-top: 0.1rem; }

.lod-chat-inputbar { flex-shrink: 0; display: flex; gap: 0.5rem; padding: 0.75rem; border-top: 1px solid #f1d3e0; background: #fff; }
.lod-chat-inputbar input { flex: 1; font-size: 0.88rem; padding: 0.55rem 0.75rem; border: 1px solid #f1d3e0; border-radius: 999px; font-family: inherit; }
.lod-chat-inputbar input:focus { outline: 2px solid #ff2f96; outline-offset: 1px; }
.lod-chat-send { background: #3a1526; color: #fff; border: 0; border-radius: 50%; width: 40px; height: 40px; flex-shrink: 0; display: flex; align-items: center; justify-content: center; cursor: pointer; }
.lod-chat-send:hover { background: #5c3648; }
.lod-chat-send svg { width: 18px; height: 18px; fill: #fff; }
