#bo170-launcher {
  position: fixed; right: 22px; bottom: 20px; z-index: 9000;
  border: 0; border-radius: 28px; padding: 13px 17px;
  background: #17664d; color: white; font-size: 17px;
  box-shadow: 0 3px 18px #0003; cursor: pointer;
}
#bo170-badge {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 19px; height: 19px; border-radius: 12px;
  background: #d93025; color: white; font-size: 11px; font-weight: 700;
}
#bo170-badge[hidden] { display: none; }
#bo170-window {
  position: fixed; right: 22px; bottom: 78px; z-index: 9001;
  width: 350px; height: min(520px, calc(100dvh - 110px));
  display: flex; flex-direction: column; overflow: hidden;
  background: #fff; color: #24342f; border: 1px solid #d7e0db;
  border-radius: 15px; box-shadow: 0 5px 28px #0003;
  font-size: 14px;
}
#bo170-window[hidden] { display: none; }
#bo170-header {
  flex: 0 0 auto; min-height: 48px; padding: 8px 12px;
  display: flex; align-items: center; justify-content: space-between;
  gap: 8px; background: #17664d; color: white;
}
.bo170-head-actions { display: flex; gap: 6px; }
.bo170-head-actions button {
  border: 0; border-radius: 50%; width: 29px; height: 29px;
  background: #ffffff24; color: white; font-size: 20px; cursor: pointer;
}
#bo170-content { flex: 1; min-height: 0; overflow-y: auto; padding: 12px; }
#bo170-window.bo170-minimized { height: auto; }
#bo170-window.bo170-minimized #bo170-content { display: none; }
.bo170-list { display: flex; flex-direction: column; }
.bo170-contact {
  width: 100%; display: flex; align-items: center; gap: 10px;
  padding: 11px 5px; border: 0; border-bottom: 1px solid #e6ece8;
  background: white; color: inherit; text-align: left; cursor: pointer;
}
.bo170-contact:hover { background: #f0f6f2; }
.bo170-avatar {
  flex: 0 0 38px; height: 38px; display: grid; place-items: center;
  border-radius: 50%; background: #e2eee7; color: #17664d; font-weight: 700;
}
.bo170-contact-copy { min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.bo170-contact-copy strong { overflow-wrap: anywhere; }
.bo170-contact-copy small, .bo170-muted { color: #63736b; }
.bo170-unread { margin-left: auto; border-radius: 15px; padding: 3px 7px; background: #17664d; color: white; }
.bo170-back, .bo170-secondary {
  border: 0; border-radius: 8px; padding: 7px 10px; cursor: pointer;
  background: #e7efe9; color: #17664d;
}
.bo170-messages {
  display: flex; flex-direction: column; gap: 9px;
  overflow-y: auto; max-height: 310px; padding: 10px 0;
}
.bo170-message {
  align-self: flex-start; max-width: 86%; overflow-wrap: anywhere;
  padding: 9px 11px; border-radius: 13px; background: #eef0ef;
}
.bo170-message.mine { align-self: flex-end; background: #dceee5; }
.bo170-message p { margin: 0 0 5px; white-space: normal; }
.bo170-message small { color: #63736b; font-size: 10px; }
#bo170-reply, #bo170-compose { display: flex; flex-direction: column; gap: 8px; }
#bo170-reply textarea, #bo170-compose textarea {
  width: 100%; box-sizing: border-box; resize: vertical; min-height: 58px;
  border: 1px solid #d2ddd6; border-radius: 10px; padding: 10px;
  font: inherit; color: inherit;
}
#bo170-reply button[type=submit], #bo170-compose button[type=submit] {
  align-self: flex-end; border: 0; border-radius: 9px; padding: 9px 15px;
  background: #17664d; color: white; cursor: pointer;
}
#bo170-reply button:disabled, #bo170-compose button:disabled { opacity: .55; }
.bo170-tools { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-top: 12px; }
.bo170-tools a { color: #17664d; }
.bo170-error { color: #b42318; overflow-wrap: anywhere; }
.bo170-toast {
  position: fixed; right: 22px; bottom: 78px; z-index: 9002;
  border: 1px solid #d7e0db; border-radius: 12px; padding: 12px 15px;
  background: white; color: #17664d; box-shadow: 0 3px 18px #0003; cursor: pointer;
}
@media (max-width: 480px) {
  #bo170-window {
    right: 8px; bottom: 70px; width: calc(100vw - 16px);
    height: min(70dvh, 560px);
  }
  #bo170-launcher { right: 12px; bottom: 12px; }
  .bo170-toast { right: 8px; bottom: 70px; max-width: calc(100vw - 32px); }
}
