.maya-launcher-row {
  position: fixed;
  right: var(--wa-offset, 24px);
  bottom: calc(var(--wa-offset, 24px) + var(--wa-size, 52px) + 14px);
  z-index: 44;
  display: flex;
  align-items: center;
  gap: 10px;
}
.maya-launcher {
  flex-shrink: 0;
  width: var(--wa-size, 52px);
  height: var(--wa-size, 52px);
  border-radius: 50%;
  background: var(--espresso);
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 8px 18px rgba(57, 31, 6, 0.22);
  padding: 0;
}
.maya-launcher svg {
  width: 60%;
  height: 60%;
  display: block;
}
.maya-launcher[hidden] {
  display: none;
}

.maya-ask-pill {
  flex-shrink: 1;
  min-width: 0;
  background: var(--espresso);
  color: var(--cream);
  font-family: "IBM Plex Sans", sans-serif;
  font-size: 13.5px;
  font-weight: 500;
  padding: 9px 16px;
  border-radius: 20px;
  box-shadow: 0 6px 16px rgba(57, 31, 6, 0.22);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  position: relative;
}
.maya-ask-pill::after {
  content: "";
  position: absolute;
  right: -5px;
  top: 50%;
  transform: translateY(-50%);
  width: 10px;
  height: 10px;
  background: var(--espresso);
  clip-path: polygon(0 0, 0 100%, 100% 50%);
}
.maya-ask-pill[hidden] {
  display: none;
}

.maya-panel {
  position: fixed;
  right: var(--wa-offset, 24px);
  bottom: calc(
    var(--wa-offset, 24px) + var(--wa-size, 52px) + 14px + var(--wa-size, 52px) + 14px
  );
  z-index: 46;
  width: 300px;
  max-height: min(70vh, 480px);
  background: var(--white);
  border: 1px solid var(--hairline);
  border-radius: var(--radius);
  box-shadow: 0 14px 34px rgba(57, 31, 6, 0.22);
  display: none;
  flex-direction: column;
  overflow: hidden;
}
.maya-panel.is-visible {
  display: flex;
}
.maya-panel.is-animating-in {
  animation: maya-fade-scale-in 0.18s ease forwards;
}
.maya-panel.is-animating-out {
  animation: maya-fade-scale-in 0.15s ease reverse forwards;
}
@keyframes maya-fade-scale-in {
  from {
    opacity: 0;
    transform: scale(0.96) translateY(8px);
  }
  to {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}
@media (prefers-reduced-motion: reduce) {
  .maya-panel.is-animating-in,
  .maya-panel.is-animating-out {
    animation-name: maya-fade-in;
  }
  @keyframes maya-fade-in {
    from {
      opacity: 0;
    }
    to {
      opacity: 1;
    }
  }
}

.maya-header {
  flex-shrink: 0;
  background: var(--espresso);
  color: var(--cream);
  padding: 14px 14px 14px 16px;
  display: flex;
  align-items: center;
  gap: 12px;
}
.maya-header svg {
  width: 36px;
  height: 36px;
  flex-shrink: 0;
  display: block;
}
.maya-header-who {
  flex: 1;
  min-width: 0;
}
.maya-header-name {
  font-family: "Space Grotesk", sans-serif;
  font-weight: 700;
  font-size: 15px;
  line-height: 1.2;
}
.maya-header-role {
  font-family: "IBM Plex Mono", monospace;
  font-size: 10.5px;
  letter-spacing: 0.06em;
  color: rgba(250, 246, 238, 0.65);
  margin-top: 2px;
}
.maya-close {
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: transparent;
  border: none;
  color: var(--cream);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  padding: 0;
}
.maya-close svg {
  width: 16px;
  height: 16px;
}
.maya-close:hover {
  background: rgba(250, 246, 238, 0.12);
}

.maya-body {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
  padding: 16px;
}
.maya-bubble {
  background: #f1ead8;
  color: var(--espresso);
  font-size: 13.5px;
  line-height: 1.55;
  padding: 11px 13px;
  border-radius: 10px 10px 10px 3px;
  max-width: 92%;
  margin-bottom: 14px;
  white-space: pre-line;
  overflow-wrap: break-word;
  word-break: break-word;
}
.maya-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.maya-chip {
  font-family: "IBM Plex Sans", sans-serif;
  font-size: 12.5px;
  font-weight: 500;
  color: var(--espresso);
  background: var(--white);
  border: 1.3px solid var(--sand);
  border-radius: 20px;
  padding: 7px 13px;
  cursor: pointer;
  text-align: left;
}
.maya-chip:hover {
  background: var(--cream);
  border-color: var(--sand-on-light, var(--sand));
}

.maya-escalate {
  flex-shrink: 0;
  border-top: 1px solid var(--hairline);
  padding: 13px 16px;
  display: flex;
  align-items: center;
  gap: 9px;
}
.maya-escalate svg {
  width: 20px;
  height: 20px;
  fill: #25d366;
  flex-shrink: 0;
  display: block;
}
.maya-escalate-text {
  font-size: 12.5px;
  color: var(--text-muted, rgba(57, 31, 6, 0.7));
  text-decoration: none;
}
.maya-escalate-text strong {
  color: var(--espresso);
  font-weight: 600;
}
.maya-escalate a.maya-escalate-text:hover strong {
  text-decoration: underline;
}

@media (max-width: 480px) {
  .maya-panel {
    right: 16px;
    left: 16px;
    bottom: 0;
    width: calc(100vw - 32px);
    max-height: 70vh;
    border-radius: var(--radius) var(--radius) 0 0;
  }
}
