.boss-support-launcher {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 9999;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 54px;
  padding: 8px 18px 8px 8px;
  border: 1px solid rgba(37, 99, 235, .24);
  border-radius: 999px;
  background: #fff;
  color: #0f172a;
  box-shadow: 0 18px 45px rgba(15, 23, 42, .22);
  font: 700 14px/1.2 Inter, system-ui, sans-serif;
  cursor: pointer;
}

.boss-support-launcher:hover,
.boss-support-launcher:focus-visible {
  border-color: #2563eb;
  transform: translateY(-1px);
}

.boss-support-launcher.panel-open { display: none; }

.boss-support-launcher-icon,
.boss-support-avatar {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  flex: 0 0 auto;
  border-radius: 12px;
  background: linear-gradient(145deg, #2563eb, #0ea5e9);
  color: #fff;
  font-weight: 900;
  box-shadow: 0 8px 20px rgba(37, 99, 235, .22);
}

.boss-support-panel {
  position: fixed;
  right: 24px;
  bottom: 24px;
  z-index: 10000;
  display: none;
  grid-template-rows: auto auto minmax(180px, 1fr) auto auto auto;
  width: min(410px, calc(100vw - 32px));
  height: min(620px, calc(100vh - 48px));
  overflow: hidden;
  border: 1px solid #dbe3ef;
  border-radius: 22px;
  background: #fff;
  color: #0f172a;
  box-shadow: 0 28px 80px rgba(15, 23, 42, .28);
  font-family: Inter, system-ui, sans-serif;
}

.boss-support-panel.open { display: grid; }

.boss-support-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 16px 13px;
  border-bottom: 1px solid #e5eaf1;
}

.boss-support-identity,
.boss-support-header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.boss-support-identity > div { display: grid; gap: 2px; }
.boss-support-identity strong { font-size: 15px; letter-spacing: .01em; }
.boss-support-identity small { color: #64748b; font-size: 11px; }
.boss-support-avatar { width: 36px; height: 36px; border-radius: 11px; }

.boss-support-icon-button {
  width: 34px;
  height: 34px;
  padding: 0;
  border: 1px solid #dbe3ef;
  border-radius: 10px;
  background: #f8fafc;
  color: #334155;
  font-size: 19px;
  cursor: pointer;
}

.boss-support-notice {
  margin: 0;
  padding: 9px 16px;
  border-bottom: 1px solid #e5eaf1;
  background: #eff6ff;
  color: #475569;
  font-size: 11px;
  line-height: 1.4;
}

.boss-support-messages {
  overflow-y: auto;
  padding: 16px;
  background: #f8fafc;
  scrollbar-width: thin;
}

.boss-support-message {
  display: grid;
  justify-items: start;
  margin: 0 0 14px;
}

.boss-support-message.user { justify-items: end; }
.boss-support-message-label { margin: 0 5px 4px; color: #64748b; font-size: 10px; }

.boss-support-message p {
  max-width: 88%;
  margin: 0;
  padding: 11px 13px;
  border: 1px solid #dbe3ef;
  border-radius: 15px 15px 15px 4px;
  background: #fff;
  color: #1e293b;
  font-size: 13px;
  line-height: 1.5;
  white-space: pre-wrap;
}

.boss-support-message.user p {
  border-color: #2563eb;
  border-radius: 15px 15px 4px 15px;
  background: #2563eb;
  color: #fff;
}

.boss-support-pending { color: #64748b !important; font-style: italic; }

.boss-support-suggestions {
  display: flex;
  gap: 7px;
  overflow-x: auto;
  padding: 10px 12px 8px;
  border-top: 1px solid #e5eaf1;
  background: #fff;
}

.boss-support-chip {
  flex: 0 0 auto;
  max-width: 240px;
  padding: 7px 10px;
  border: 1px solid #bfdbfe;
  border-radius: 999px;
  background: #eff6ff;
  color: #1d4ed8;
  font-size: 11px;
  cursor: pointer;
}

.boss-support-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 8px;
  padding: 10px 12px 12px;
  background: #fff;
}

.boss-support-contact {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 8px 12px 0;
  border-top: 1px solid #e5eaf1;
  background: #fff;
  font-size: 11px;
}

.boss-support-contact a { color: #1d4ed8; font-weight: 800; text-decoration: none; }
.boss-support-contact a:hover { text-decoration: underline; }
.boss-support-contact small { color: #64748b; font-size: 9px; text-align: right; }

.boss-support-input {
  width: 100%;
  min-height: 46px;
  max-height: 110px;
  resize: vertical;
  padding: 11px 12px;
  border: 1px solid #cbd5e1;
  border-radius: 12px;
  background: #fff;
  color: #0f172a;
  font: 13px/1.4 Inter, system-ui, sans-serif;
}

.boss-support-input:focus { outline: 2px solid rgba(37, 99, 235, .2); border-color: #2563eb; }

.boss-support-send {
  align-self: stretch;
  padding: 0 16px;
  border: 0;
  border-radius: 12px;
  background: #2563eb;
  color: #fff;
  font-weight: 800;
  cursor: pointer;
}

.boss-support-send:disabled { opacity: .55; cursor: wait; }

@media (max-width: 560px) {
  .boss-support-launcher { right: 14px; bottom: 14px; }
  .boss-support-panel {
    right: 8px;
    bottom: 8px;
    width: calc(100vw - 16px);
    height: min(680px, calc(100vh - 16px));
    border-radius: 18px;
  }
}
