/*
 * LogoZentrum Parla
 * Visuell identisch zur freigegebenen Lindlar-Testversion,
 * für WordPress vollständig auf das Widget gescoped.
 */

#logozentrum-parla-widget,
#logozentrum-parla-widget * {
  box-sizing: border-box;
}

#logozentrum-parla-widget {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 999999;
  font-family: system-ui, -apple-system, Arial, sans-serif;
  font-size: 16px;
  line-height: 1.4;
  color: #222222;
}

#logozentrum-parla-widget .lp-toggle {
  position: relative;
  width: 290px;
  height: 50px;
  padding: 0 18px;
  margin: 0 40px 0 0;
  border: 1px solid #E5E5E5;
  border-radius: 10px;
  background: #FFFFFF;
  color: #222222;
  cursor: pointer;
  box-shadow: 0 6px 22px rgba(0,0,0,0.12);
  display: flex;
  align-items: center;
  justify-content: flex-start;
  overflow: visible;
  appearance: none;
  -webkit-appearance: none;
  text-transform: none;
  letter-spacing: normal;
  line-height: 1.2;
  transition:
    border-color 0.2s ease,
    box-shadow 0.2s ease,
    transform 0.2s ease;
}

#logozentrum-parla-widget .lp-toggle:hover,
#logozentrum-parla-widget .lp-toggle:focus-visible {
  border-color: #C1121F;
  box-shadow: 0 8px 26px rgba(0,0,0,0.16);
  transform: translateY(-2px);
  outline: none;
}

#logozentrum-parla-widget .lp-toggle-text {
  font-size: 18px;
  font-weight: 400;
  line-height: 1.2;
  white-space: nowrap;
}

#logozentrum-parla-widget .lp-toggle-parla {
  position: absolute;
  right: -22px;
  bottom: -8px;
  width: 112px;
  height: auto;
  max-width: none;
  display: block;
  pointer-events: none;
  border: 0;
  box-shadow: none;
}

#logozentrum-parla-widget .lp-window {
  width: 480px;
  height: 620px;
  max-width: calc(100vw - 40px);
  max-height: calc(100vh - 40px);
  background: #FFFFFF;
  border-radius: 18px;
  box-shadow: 0 12px 40px rgba(0,0,0,0.22);
  overflow: hidden;
  display: none;
  flex-direction: column;
  margin: 0 0 14px 0;
}

#logozentrum-parla-widget .lp-window.open {
  display: flex;
}

#logozentrum-parla-widget .lp-chat-header {
  background: #FFFFFF;
  color: #222222;
  padding: 14px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid #C1121F;
  flex: 0 0 auto;
}

#logozentrum-parla-widget .lp-chat-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

#logozentrum-parla-widget .lp-chat-logo {
  width: 28px;
  height: 28px;
  max-width: none;
  object-fit: contain;
  display: block;
  border: 0;
  box-shadow: none;
}

#logozentrum-parla-widget .lp-chat-title {
  font-size: 18px;
  font-weight: 600;
  line-height: 1.2;
  margin: 0;
  padding: 0;
  color: #222222;
}

#logozentrum-parla-widget .lp-chat-close {
  background: transparent;
  color: #666666;
  border: none;
  border-radius: 8px;
  font-size: 24px;
  font-weight: 400;
  line-height: 1;
  padding: 0;
  width: 32px;
  height: 32px;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  display: flex;
  align-items: center;
  justify-content: center;
  text-transform: none;
  letter-spacing: normal;
  box-shadow: none;
}

#logozentrum-parla-widget .lp-chat-close:hover,
#logozentrum-parla-widget .lp-chat-close:focus-visible {
  background: #F3F3F3;
  color: #222222;
  outline: none;
}

#logozentrum-parla-widget .lp-chat {
  flex: 1 1 auto;
  min-height: 0;
  overflow-y: auto;
  padding: 15px;
  background: #F7F7F8;
}

#logozentrum-parla-widget .lp-msg {
  margin: 0 0 14px 0;
  padding: 0;
  line-height: 1.4;
  font-size: 16px;
}

#logozentrum-parla-widget .lp-msg.user {
  text-align: right;
}

#logozentrum-parla-widget .lp-msg.user > span {
  background: #6E6E6E;
  color: #FFFFFF;
  padding: 8px 12px;
  border-radius: 12px;
  display: inline-block;
  max-width: 80%;
  text-align: left;
}

#logozentrum-parla-widget .lp-msg.bot > span {
  background: #EDEDED;
  color: #2d2d2d;
  padding: 8px 12px;
  border-radius: 12px;
  display: inline-block;
  max-width: 80%;
  text-align: left;
}

#logozentrum-parla-widget .lp-msg > span {
  overflow-wrap: anywhere;
  word-break: break-word;
}

#logozentrum-parla-widget .lp-msg a {
  color: inherit;
  text-decoration: underline;
}

#logozentrum-parla-widget .lp-input {
  display: flex;
  gap: 10px;
  padding: 15px;
  border-top: 1px solid #e5e7eb;
  background: #FFFFFF;
  flex: 0 0 auto;
}

#logozentrum-parla-widget .lp-message {
  flex: 1 1 auto;
  min-width: 0;
  min-height: 54px;
  margin: 0;
  padding: 10px;
  border-radius: 8px;
  border: 1px solid #CCCCCC;
  background: #FFFFFF;
  color: #222222;
  resize: none;
  font: inherit;
  line-height: 1.4;
  outline: none;
  box-shadow: none;
  appearance: none;
  -webkit-appearance: none;
}

#logozentrum-parla-widget .lp-message:focus {
  outline: none;
  border: 1px solid #C1121F;
  box-shadow: 0 0 0 2px rgba(193,18,31,0.12);
}

#logozentrum-parla-widget .lp-message::placeholder {
  color: #777777;
  opacity: 1;
}

#logozentrum-parla-widget .lp-send {
  align-self: stretch;
  padding: 10px 16px;
  margin: 0;
  border: none;
  border-radius: 8px;
  background: #6E6E6E;
  color: #FFFFFF;
  cursor: pointer;
  font: inherit;
  font-weight: 400;
  line-height: 1.2;
  appearance: none;
  -webkit-appearance: none;
  text-transform: none;
  letter-spacing: normal;
  box-shadow: none;
}

#logozentrum-parla-widget .lp-send:hover,
#logozentrum-parla-widget .lp-send:focus-visible {
  background: #C1121F;
  color: #FFFFFF;
  outline: none;
}

#logozentrum-parla-widget .lp-chat-note {
  padding: 0 15px 10px;
  font-size: 11px;
  line-height: 1.3;
  color: #888888;
  text-align: center;
  background: #FFFFFF;
  flex: 0 0 auto;
}

@media (max-width: 640px) {
  #logozentrum-parla-widget {
    right: 12px;
    left: 12px;
    bottom: 12px;
  }

  #logozentrum-parla-widget .lp-window {
    width: auto;
    max-width: none;
    height: 78vh;
    max-height: calc(100vh - 24px);
    margin-bottom: 10px;
    border-radius: 16px;
  }

  #logozentrum-parla-widget .lp-toggle {
    margin-left: auto;
  }
}
