.siclife-chat {
  --siclife-chat-green: #005132;
  --siclife-chat-green-light: #087348;
  --siclife-chat-yellow: #fdf21c;
  --siclife-chat-shadow: 0 18px 48px rgba(0, 44, 27, 0.24);
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 2147482998;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 12px;
  font-family: "Inter", "Montserrat", "Segoe UI", sans-serif;
  pointer-events: none;
}

.siclife-chat__launcher,
.siclife-chat__teaser {
  pointer-events: auto;
}

.siclife-chat__launcher {
  position: relative;
  display: flex;
  align-items: center;
  min-height: 64px;
  padding: 7px 8px 7px 20px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 999px;
  color: #fff;
  background: linear-gradient(135deg, var(--siclife-chat-green-light), var(--siclife-chat-green));
  box-shadow: var(--siclife-chat-shadow);
  cursor: pointer;
  opacity: 0;
  transform: translateY(12px);
  transition: transform 180ms ease, box-shadow 180ms ease, opacity 220ms ease;
}

.siclife-chat--ready .siclife-chat__launcher {
  opacity: 1;
  transform: translateY(0);
}

.siclife-chat--open .siclife-chat__teaser {
  opacity: 0;
  pointer-events: none;
  visibility: hidden;
}

.siclife-chat__launcher:hover {
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 22px 52px rgba(0, 44, 27, 0.3);
}

.siclife-chat__launcher:focus-visible,
.siclife-chat__teaser-close:focus-visible {
  outline: 3px solid var(--siclife-chat-yellow);
  outline-offset: 3px;
}

.siclife-chat__presence {
  position: absolute;
  top: 8px;
  right: 8px;
  z-index: 2;
  width: 13px;
  height: 13px;
  border: 2px solid #fff;
  border-radius: 50%;
  background: #29d36b;
}

.siclife-chat__presence::after {
  position: absolute;
  inset: -4px;
  border: 1px solid #29d36b;
  border-radius: inherit;
  content: "";
  animation: siclife-chat-pulse 2.2s ease-out infinite;
}

.siclife-chat[data-chat-status="away"] .siclife-chat__presence {
  background: #f2b544;
}

.siclife-chat[data-chat-status="away"] .siclife-chat__presence::after,
.siclife-chat[data-chat-status="offline"] .siclife-chat__presence::after {
  display: none;
}

.siclife-chat[data-chat-status="offline"] .siclife-chat__presence {
  background: #a7b0aa;
}

.siclife-chat__label {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  min-width: 126px;
  margin-right: 12px;
  text-align: left;
}

.siclife-chat__label-main {
  font-family: "Montserrat", sans-serif;
  font-size: 0.92rem;
  font-weight: 700;
  line-height: 1.2;
}

.siclife-chat__status {
  margin-top: 3px;
  color: rgba(255, 255, 255, 0.78);
  font-size: 0.7rem;
  font-weight: 500;
  line-height: 1.2;
}

.siclife-chat__icon {
  display: grid;
  flex: 0 0 50px;
  width: 50px;
  height: 50px;
  place-items: center;
  border-radius: 50%;
  color: var(--siclife-chat-green);
  background: var(--siclife-chat-yellow);
}

.siclife-chat__icon svg {
  grid-area: 1 / 1;
  width: 26px;
  height: 26px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 1.8;
  transition: opacity 160ms ease, transform 180ms ease;
}

.siclife-chat__icon-chat path:last-child {
  stroke-width: 2.8;
}

.siclife-chat__icon-close {
  opacity: 0;
  transform: rotate(-45deg) scale(0.7);
}

.siclife-chat--open .siclife-chat__icon-chat {
  opacity: 0;
  transform: rotate(45deg) scale(0.7);
}

.siclife-chat--open .siclife-chat__icon-close {
  opacity: 1;
  transform: rotate(0) scale(1);
}

.siclife-chat__teaser {
  position: relative;
  width: min(300px, calc(100vw - 32px));
  padding: 18px 44px 18px 20px;
  border: 1px solid rgba(0, 81, 50, 0.1);
  border-radius: 18px 18px 4px 18px;
  background: #fff;
  box-shadow: 0 16px 42px rgba(0, 44, 27, 0.18);
  cursor: pointer;
  opacity: 0;
  transform: translateY(8px) scale(0.97);
  transform-origin: bottom right;
  visibility: hidden;
  transition: opacity 180ms ease, transform 220ms ease, visibility 180ms;
}

.siclife-chat--show-teaser .siclife-chat__teaser {
  opacity: 1;
  transform: translateY(0) scale(1);
  visibility: visible;
}

.siclife-chat__teaser::after {
  position: absolute;
  right: 22px;
  bottom: -7px;
  width: 14px;
  height: 14px;
  background: #fff;
  content: "";
  transform: rotate(45deg);
}

.siclife-chat__teaser strong,
.siclife-chat__teaser-copy,
.siclife-chat__eyebrow {
  display: block;
}

.siclife-chat__eyebrow {
  margin-bottom: 5px;
  color: var(--siclife-chat-green-light);
  font-family: "Montserrat", sans-serif;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.siclife-chat__teaser strong {
  color: #26332c;
  font-family: "Montserrat", sans-serif;
  font-size: 1rem;
  line-height: 1.25;
}

.siclife-chat__teaser-copy {
  margin-top: 6px;
  color: #5c6961;
  font-size: 0.82rem;
  line-height: 1.45;
}

.siclife-chat__teaser-close {
  position: absolute;
  top: 11px;
  right: 11px;
  z-index: 1;
  display: grid;
  width: 30px;
  height: 30px;
  padding: 0;
  place-items: center;
  border: 0;
  border-radius: 50%;
  color: #647169;
  background: #f0f5f2;
  cursor: pointer;
}

.siclife-chat__teaser-close:hover {
  color: var(--siclife-chat-green);
  background: #e2eee7;
}

.siclife-chat__teaser-close svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-width: 2;
}

@keyframes siclife-chat-pulse {
  0% {
    opacity: 0.8;
    transform: scale(0.7);
  }
  75%,
  100% {
    opacity: 0;
    transform: scale(1.55);
  }
}

@media (max-width: 767.98px) {
  .siclife-chat {
    right: 16px;
    bottom: max(16px, env(safe-area-inset-bottom));
  }

  .siclife-chat__launcher {
    min-height: 58px;
    padding: 4px;
  }

  .siclife-chat__label {
    display: none;
  }

  .siclife-chat__icon {
    flex-basis: 50px;
  }

  .siclife-chat__presence {
    top: 3px;
    right: 3px;
  }

  .siclife-chat__teaser {
    width: min(280px, calc(100vw - 32px));
  }
}

@media (prefers-reduced-motion: reduce) {
  .siclife-chat__launcher,
  .siclife-chat__teaser,
  .siclife-chat__icon svg {
    transition: none;
  }

  .siclife-chat__presence::after {
    animation: none;
  }
}

@media print {
  .siclife-chat {
    display: none !important;
  }
}
