.punk-root {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 1200;
  font-family: Lato, Arial, sans-serif;
}

.punk-launcher {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 0;
  border-radius: 999px;
  min-height: 48px;
  padding: 0 16px 0 12px;
  background: linear-gradient(135deg, #ff2a33, #e60910);
  color: #fff;
  font-family: Montserrat, Arial, sans-serif;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  cursor: pointer;
  box-shadow: 0 14px 34px rgba(230, 9, 16, 0.35);
}

.punk-launcher-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 0 0 4px rgba(255, 255, 255, 0.22);
}

.punk-panel {
  position: absolute;
  right: 0;
  bottom: 58px;
  width: min(380px, calc(100vw - 24px));
  height: min(560px, calc(100vh - 110px));
  display: flex;
  flex-direction: column;
  background: #fff;
  border: 1px solid #e7e1d8;
  border-radius: 18px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.18);
  overflow: hidden;
}

/* display:flex above would otherwise override the hidden attribute */
.punk-panel[hidden] {
  display: none !important;
}

.punk-panel-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  padding: 14px 14px 12px;
  background: #111;
  color: #fff;
}

.punk-panel-head strong {
  display: block;
  font-family: Montserrat, Arial, sans-serif;
  font-size: 14px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.punk-panel-head span {
  display: block;
  font-size: 12px;
  color: #cfcfcf;
  margin-top: 2px;
}

.punk-close {
  border: 0;
  background: transparent;
  color: #fff;
  font-size: 24px;
  line-height: 1;
  cursor: pointer;
}

.punk-thread {
  flex: 1;
  overflow-y: auto;
  padding: 14px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  background: #f7f4f0;
}

.punk-msg {
  display: flex;
}

.punk-msg-user {
  justify-content: flex-end;
}

.punk-bubble {
  max-width: 88%;
  padding: 10px 12px;
  border-radius: 14px;
  background: #fff;
  border: 1px solid #ebe4db;
  color: #111;
  font-size: 13px;
  line-height: 1.45;
  white-space: pre-wrap;
}

.punk-msg-user .punk-bubble {
  background: #111;
  color: #fff;
  border-color: #111;
}

.punk-links {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}

.punk-links a {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 5px 10px;
  background: #111;
  color: #fff !important;
  font-size: 11px;
  font-weight: 700;
  text-decoration: none;
}

.punk-quick {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 0 12px 10px;
  background: #f7f4f0;
}

.punk-quick button {
  border: 1px solid #ddd4c8;
  background: #fff;
  border-radius: 999px;
  padding: 6px 10px;
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
}

.punk-form {
  display: grid;
  grid-template-columns: 1fr;
  gap: 8px;
  padding: 10px 12px;
  border-top: 1px solid #ebe4db;
  background: #fff;
}

.punk-form textarea {
  width: 100%;
  border: 1px solid #ddd4c8;
  border-radius: 12px;
  padding: 10px;
  resize: none;
  font: inherit;
  font-size: 13px;
}

.punk-form-actions {
  display: flex;
  justify-content: space-between;
  gap: 8px;
}

.punk-minimize {
  border: 1px solid #ddd4c8;
  border-radius: 12px;
  background: #fff;
  color: #444;
  font-family: Montserrat, Arial, sans-serif;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 0 12px;
  min-height: 40px;
  cursor: pointer;
}

.punk-send {
  border: 0;
  border-radius: 12px;
  background: #e60910;
  color: #fff;
  font-family: Montserrat, Arial, sans-serif;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  padding: 0 14px;
  min-height: 40px;
  cursor: pointer;
}

.punk-send:disabled {
  opacity: 0.55;
  cursor: wait;
}

.punk-panel-foot {
  display: flex;
  justify-content: space-between;
  gap: 10px;
  padding: 8px 12px 12px;
  background: #fff;
  border-top: 1px solid #f0ebe4;
}

.punk-panel-foot a {
  font-size: 12px;
  font-weight: 700;
  color: #111;
}

.punk-sr {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
}

@media (max-width: 520px) {
  .punk-root {
    right: 12px;
    bottom: 12px;
  }

  .punk-launcher-label {
    display: none;
  }

  .punk-launcher {
    width: 52px;
    padding: 0;
    justify-content: center;
  }

  .punk-panel {
    position: fixed;
    right: 12px;
    left: 12px;
    width: auto;
    bottom: 72px;
  }
}
