.lia-widget-button {
  position: fixed;
  right: 24px;
  bottom: 24px;
  width: 64px;
  height: 64px;
  border-radius: 999px;
  border: none;
  background: #232323;
  color: #eae6dd;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.22);
  cursor: pointer;
  z-index: 9999;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: Arial, sans-serif;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.lia-widget-button:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.28);
}

.lia-widget-button-avatar {
  width: 42px;
  height: 42px;
  border-radius: 999px;
  background: #eae6dd;
  color: #232323;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 13px;
}

.lia-widget-panel {
  position: fixed;
  right: 24px;
  bottom: 104px;
  width: 380px;
  max-width: calc(100vw - 32px);
  height: 580px;
  max-height: calc(100vh - 136px);
  background: #ffffff;
  border-radius: 22px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.25);
  overflow: hidden;
  z-index: 9999;
  display: none;
  flex-direction: column;
  font-family: Arial, sans-serif;
  border: 1px solid rgba(35, 35, 35, 0.08);
}

.lia-widget-panel.open {
  display: flex;
}

.lia-widget-header {
  background: #232323;
  color: #eae6dd;
  padding: 18px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.lia-widget-avatar {
  width: 44px;
  height: 44px;
  border-radius: 999px;
  background: #eae6dd;
  color: #232323;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 13px;
  flex-shrink: 0;
}

.lia-widget-title {
  font-size: 16px;
  font-weight: 700;
  margin: 0;
}

.lia-widget-subtitle {
  font-size: 12px;
  opacity: 0.82;
  margin: 2px 0 0 0;
}

.lia-widget-close {
  margin-left: auto;
  border: none;
  background: transparent;
  color: #eae6dd;
  font-size: 24px;
  cursor: pointer;
  line-height: 1;
}

.lia-widget-body {
  flex: 1;
  padding: 16px;
  background: #f7f5f0;
  overflow-y: auto;
}

.lia-message {
  display: flex;
  margin-bottom: 12px;
}

.lia-message.assistant {
  justify-content: flex-start;
}

.lia-message.user {
  justify-content: flex-end;
}

.lia-message-bubble {
  max-width: 82%;
  padding: 11px 13px;
  border-radius: 16px;
  font-size: 14px;
  line-height: 1.4;
  white-space: pre-wrap;
}

.lia-message.assistant .lia-message-bubble {
  background: #ffffff;
  color: #232323;
  border-bottom-left-radius: 4px;
  border: 1px solid rgba(35, 35, 35, 0.08);
}

.lia-message.user .lia-message-bubble {
  background: #232323;
  color: #ffffff;
  border-bottom-right-radius: 4px;
}

.lia-widget-footer {
  padding: 12px;
  background: #ffffff;
  border-top: 1px solid rgba(35, 35, 35, 0.08);
}

.lia-widget-identification-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
  margin-bottom: 8px;
}

.lia-widget-email,
.lia-widget-document {
  width: 100%;
  border: 1px solid rgba(35, 35, 35, 0.18);
  border-radius: 12px;
  padding: 10px 12px;
  font-size: 13px;
  outline: none;
  box-sizing: border-box;
}

.lia-widget-input-row {
  display: flex;
  gap: 8px;
}

.lia-widget-input {
  flex: 1;
  border: 1px solid rgba(35, 35, 35, 0.18);
  border-radius: 14px;
  padding: 11px 12px;
  font-size: 14px;
  outline: none;
}

.lia-widget-send {
  border: none;
  border-radius: 14px;
  padding: 0 16px;
  background: #232323;
  color: #ffffff;
  font-weight: 700;
  cursor: pointer;
}

.lia-widget-send:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.lia-widget-note {
  font-size: 11px;
  color: rgba(35, 35, 35, 0.58);
  margin-top: 8px;
  line-height: 1.35;
}

.lia-typing {
  font-size: 13px;
  color: rgba(35, 35, 35, 0.6);
  padding: 4px 2px;
}

.lia-widget-honeypot {
  position: absolute;
  left: -9999px;
  opacity: 0;
  pointer-events: none;
}

@media (max-width: 480px) {
  .lia-widget-panel {
    right: 12px;
    bottom: 92px;
    width: calc(100vw - 24px);
    height: calc(100vh - 120px);
  }

  .lia-widget-button {
    right: 16px;
    bottom: 16px;
  }
}

.lia-widget-button-avatar-img {
  width: 52px;
  height: 52px;
  border-radius: 999px;
  object-fit: cover;
  display: block;
  border: 2px solid #eae6dd;
}

.lia-widget-avatar-img {
  width: 52px;
  height: 52px;
  border-radius: 999px;
  object-fit: cover;
  display: block;
  flex-shrink: 0;
  border: 2px solid #eae6dd;
}

.lia-quick-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin: 10px 0 16px 0;
}

.lia-quick-action {
  border: 1px solid rgba(35, 35, 35, 0.14);
  background: #ffffff;
  color: #232323;
  border-radius: 14px;
  padding: 10px 10px;
  font-size: 12px;
  line-height: 1.25;
  cursor: pointer;
  text-align: center;
}

.lia-widget-note a {
  color: #232323;
  font-weight: 700;
  text-decoration: underline;
}

.lia-widget-note a:hover {
  opacity: 0.75;
}

.lia-quick-action:hover {
  background: #eae6dd;
}

.lia-quick-action:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none;
}

.lia-widget-message-row {
  display: flex;
  margin-bottom: 12px;
}

.lia-widget-message-row.assistant {
  justify-content: flex-start;
}

.lia-widget-message-row.user {
  justify-content: flex-end;
}

.lia-widget-message-bubble {
  max-width: 82%;
  padding: 14px 16px;
  border-radius: 18px;
  font-size: 15px;
  line-height: 1.35;
  white-space: pre-line;
  word-break: break-word;
}

.lia-widget-message-bubble.assistant {
  background: #ffffff;
  color: #232323;
  border: 1px solid rgba(35, 35, 35, 0.08);
  border-top-left-radius: 6px;
}

.lia-widget-message-bubble.user {
  background: #232323;
  color: #ffffff;
  border-top-right-radius: 6px;
}