body {
    font-family: Inter, sans-serif;
}

#messages,
#messages * {
  user-select: text !important;
  -webkit-user-select: text !important;
}

.message-row,
.message-bubble,
.message-text {
  user-select: text !important;
  -webkit-user-select: text !important;
}

.message-bubble {
  cursor: text;
}

.message-text {
  display: inline;
  pointer-events: auto;
}

.widget-side-scroll {
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.widget-side-scroll::-webkit-scrollbar {
  width: 0;
  height: 0;
}

.current-job-card {
  min-height: 86px;
  transition: min-height 0.16s ease, box-shadow 0.16s ease;
}

.current-job-card.is-collapsed {
  min-height: 52px;
}

.current-job-card.is-summary {
  min-height: 118px;
}

.current-job-card.is-full {
  min-height: 154px;
}

#currentJobShell {
  box-shadow: 0 1px 0 rgb(226 232 240 / 0.85);
}

.composer-icon-button,
.voice-control-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
}

.line-clamp-1 {
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.line-clamp-2 {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.voice-control-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.voice-control-button:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}

.voice-control-button.is-listening {
  background: rgb(254 226 226);
  color: rgb(185 28 28);
  box-shadow: 0 0 0 3px rgb(248 113 113 / 0.22);
}

.voice-control-button.is-speaking {
  background: rgb(219 234 254);
  color: rgb(30 64 175);
}

.voice-control-button.is-muted {
  background: rgb(241 245 249);
  color: rgb(100 116 139);
}

.voice-speaking-text {
  background: linear-gradient(90deg, rgb(191 219 254 / 0.55), transparent);
  border-radius: 8px;
  box-decoration-break: clone;
  -webkit-box-decoration-break: clone;
}

.slot-choice-button {
  flex: 1 1 12rem;
  min-width: min(100%, 12rem);
}

.job-notes-panel {
  transition: background-color 180ms ease, box-shadow 180ms ease;
}

.job-notes-panel.desk-monitor-highlight {
  background-color: rgb(239 246 255);
  box-shadow: inset 0 0 0 2px rgb(147 197 253 / 0.85), 0 0 18px rgb(96 165 250 / 0.28);
}

.agent-expanded-header-grid {
  display: grid;
  grid-template-columns: 260px minmax(280px, 1fr) minmax(280px, 380px) 40px;
  align-items: center;
  gap: 18px;
  min-height: 142px;
}

.agent-off-duty-panel {
  min-width: 0;
  max-width: 380px;
  padding-left: 2px;
}

.agent-off-duty-heading {
  margin-bottom: 4px;
  color: rgb(219 234 254 / 0.9);
  font-size: 14px;
  font-weight: 800;
  line-height: 1.1;
  text-transform: uppercase;
}

.agent-off-duty-copy {
  color: rgb(219 234 254 / 0.76);
  font-size: 14px;
  line-height: 1.28;
}

.agent-today-row {
  display: flex;
  align-items: flex-start;
  gap: 7px;
  margin-top: 2px;
}

.agent-today-icon {
  flex: 0 0 18px;
  line-height: 1.2;
  text-align: center;
}

.agent-header-close {
  justify-self: end;
}

.agent-desk-scene {
  position: relative;
  align-self: stretch;
  width: 260px;
  height: auto;
  min-height: 142px;
  overflow: hidden;
  border-top: 0;
  border-right: 1px solid rgb(147 197 253 / 0.65);
  border-bottom: 0;
  border-left: 0;
  border-top-left-radius: 18px;
  background: rgb(30 64 175 / 0.35);
}

.agent-desk-image {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  object-position: 56% 45%;
}

.agent-hotspot-layer,
.agent-scene-effect,
.agent-scene-moment {
  position: absolute;
  inset: 0;
}

.agent-hotspot {
  position: absolute;
  z-index: 4;
  padding: 0;
  border: 1px solid transparent;
  border-radius: 8px;
  background: transparent;
  cursor: pointer;
}

.agent-hotspot:hover,
.agent-hotspot:focus-visible,
.agent-hotspot.is-linked-highlight {
  border-color: rgb(191 219 254 / 0.9);
  background: rgb(255 255 255 / 0.16);
  box-shadow: 0 0 0 2px rgb(37 99 235 / 0.24), inset 0 0 18px rgb(255 255 255 / 0.12);
  outline: none;
}

.agent-hotspot:disabled {
  cursor: default;
}

.agent-linked-highlight {
  box-shadow: inset 0 0 0 2px rgb(96 165 250 / 0.72), 0 0 18px rgb(37 99 235 / 0.18) !important;
  outline: 2px solid rgb(191 219 254 / 0.62);
  outline-offset: 2px;
  transition: box-shadow 160ms ease, outline-color 160ms ease, transform 160ms ease;
}

.agent-hotspot.is-linked-pulse,
.agent-linked-pulse {
  animation: agent-linked-wobble 360ms ease-out;
}

@keyframes agent-linked-wobble {
  0%, 100% {
    transform: translateX(0) rotate(0deg);
  }

  28% {
    transform: translateX(-1px) rotate(-0.6deg);
  }

  58% {
    transform: translateX(1px) rotate(0.6deg);
  }
}

.agent-scene-moment {
  z-index: 7;
  inset: auto 8px 8px 8px;
  padding: 7px 9px;
  border: 1px solid rgb(191 219 254);
  border-radius: 8px;
  background: rgb(255 255 255 / 0.96);
  color: rgb(30 41 59);
  font-size: 11px;
  line-height: 1.3;
  box-shadow: 0 10px 22px rgb(15 23 42 / 0.24);
  opacity: 0;
  transform: translateY(5px);
  transition: opacity 160ms ease, transform 180ms ease;
  pointer-events: none;
}

.agent-scene-moment.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.agent-scene-effect {
  z-index: 3;
  pointer-events: none;
}

.agent-desk-scene.is-typing .agent-scene-effect::before {
  content: "sys> feed retry... ok? no. ok.";
  position: absolute;
  left: 16%;
  top: 36%;
  width: 28%;
  padding: 3px 4px;
  border-radius: 4px;
  background: rgb(15 23 42 / 0.86);
  color: rgb(147 197 253);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 8px;
  line-height: 1.15;
}

.agent-desk-scene.is-phone .agent-desk-image {
  transform: translateX(1px);
}

.agent-desk-scene.is-graham .agent-desk-image {
  filter: saturate(1.08);
}

.agent-desk-scene.is-notebook .agent-scene-effect::after,
.agent-desk-scene.is-cactus .agent-scene-effect::after {
  content: "";
  position: absolute;
  border-radius: 999px;
  background: rgb(250 204 21 / 0.22);
  box-shadow: 0 0 18px rgb(250 204 21 / 0.32);
}

.agent-desk-scene.is-notebook .agent-scene-effect::after {
  left: 31%;
  top: 72%;
  width: 25%;
  height: 18%;
}

.agent-desk-scene.is-cactus .agent-scene-effect::after {
  left: 0;
  top: 42%;
  width: 12%;
  height: 35%;
}

@media (max-width: 1060px) {
  .agent-expanded-header-grid {
    grid-template-columns: 230px minmax(0, 1fr) 40px;
    min-height: 132px;
  }

  .agent-off-duty-panel {
    grid-column: 2 / 3;
    max-width: none;
  }

  .agent-header-close {
    grid-column: 3;
    grid-row: 1;
  }
}

@media (max-width: 820px) {
  .agent-expanded-header-grid {
    grid-template-columns: 205px minmax(0, 1fr) 40px;
    gap: 12px;
    min-height: 118px;
  }

  .agent-desk-scene {
    width: 205px;
    min-height: 118px;
  }
}

.dani-desk-scene {
  position: relative;
  width: 238px;
  height: 72px;
  flex: 0 0 238px;
  margin-left: auto;
  margin-right: 8px;
}

.desk-surface {
  position: absolute;
  left: 4px;
  right: 4px;
  bottom: 7px;
  height: 6px;
  border-radius: 3px;
  background: rgb(30 64 175 / 0.8);
  box-shadow: 0 5px 0 rgb(30 58 138 / 0.55);
}

.desk-monitor {
  position: absolute;
  top: 5px;
  width: 61px;
  height: 37px;
  border: 3px solid rgb(219 234 254);
  border-radius: 5px;
  background: rgb(15 23 42);
  box-shadow: 0 0 0 1px rgb(30 64 175 / 0.65);
  cursor: help;
}

.desk-monitor::after {
  content: "";
  position: absolute;
  left: 25px;
  bottom: -16px;
  width: 7px;
  height: 13px;
  background: rgb(219 234 254);
  box-shadow: -8px 11px 0 1px rgb(219 234 254);
}

.desk-monitor-work {
  left: 4px;
}

.desk-monitor-barry {
  left: 71px;
}

.desk-monitor-line {
  display: block;
  width: 38px;
  height: 3px;
  margin: 8px 0 0 8px;
  border-radius: 2px;
  background: rgb(96 165 250);
}

.desk-monitor-line.short {
  width: 25px;
  margin-top: 5px;
  background: rgb(165 243 252);
}

.desk-monitor-dot {
  display: inline-block;
  width: 4px;
  height: 4px;
  margin: 15px 0 0 5px;
  border-radius: 50%;
  background: rgb(147 197 253);
}

.desk-monitor-dot:first-child {
  margin-left: 16px;
}

.desk-barry-tooltip {
  position: absolute;
  z-index: 20;
  top: 43px;
  left: -44px;
  width: 225px;
  padding: 8px 9px;
  border: 1px solid rgb(191 219 254);
  border-radius: 6px;
  background: white;
  color: rgb(30 41 59);
  font-size: 11px;
  line-height: 1.35;
  box-shadow: 0 8px 24px rgb(15 23 42 / 0.22);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-3px);
  transition: opacity 140ms ease, transform 140ms ease, visibility 140ms ease;
  pointer-events: none;
}

.desk-monitor-barry:hover .desk-barry-tooltip,
.desk-monitor-barry:focus-visible .desk-barry-tooltip {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.desk-dani {
  position: absolute;
  left: 145px;
  bottom: 13px;
  width: 36px;
  height: 51px;
}

.desk-dani-head {
  position: absolute;
  left: 8px;
  top: 0;
  width: 20px;
  height: 22px;
  border-radius: 50% 50% 45% 45%;
  background: rgb(254 215 170);
  box-shadow: inset 0 6px 0 rgb(120 53 15);
}

.desk-dani-body {
  position: absolute;
  left: 3px;
  bottom: 0;
  width: 30px;
  height: 30px;
  border-radius: 14px 14px 4px 4px;
  background: rgb(219 234 254);
}

.desk-cactus {
  position: absolute;
  right: 4px;
  bottom: 10px;
  width: 38px;
  height: 51px;
  padding: 0;
  border: 0;
  background: transparent;
  cursor: pointer;
  transform-origin: 50% 90%;
}

.desk-cactus:hover {
  animation: cactus-wiggle 480ms ease-in-out;
}

.desk-cactus-body,
.desk-cactus-arm {
  position: absolute;
  background: rgb(74 222 128);
  border: 2px solid rgb(22 101 52);
}

.desk-cactus-body {
  left: 15px;
  top: 10px;
  width: 10px;
  height: 29px;
  border-radius: 8px 8px 3px 3px;
}

.desk-cactus-arm {
  top: 21px;
  width: 10px;
  height: 8px;
  border-radius: 5px;
}

.desk-cactus-arm.left {
  left: 8px;
  border-right: 0;
}

.desk-cactus-arm.right {
  right: 7px;
  border-left: 0;
}

.desk-cactus-pot {
  position: absolute;
  left: 10px;
  bottom: 0;
  width: 20px;
  height: 13px;
  border-radius: 2px 2px 6px 6px;
  background: rgb(251 146 60);
  box-shadow: inset 0 3px 0 rgb(194 65 12);
}

.desk-cactus-flower {
  position: absolute;
  z-index: 2;
  left: 14px;
  top: 2px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: rgb(244 114 182);
  box-shadow: 6px 0 0 rgb(251 113 133), -6px 0 0 rgb(251 113 133), 0 6px 0 rgb(251 113 133), 0 -6px 0 rgb(251 113 133);
  opacity: 0;
  transform: scale(0);
  transition: opacity 180ms ease, transform 220ms ease;
}

.desk-cactus.has-flower .desk-cactus-flower {
  opacity: 1;
  transform: scale(0.55);
}

@keyframes cactus-wiggle {
  0%, 100% { transform: rotate(0); }
  25% { transform: rotate(-5deg); }
  55% { transform: rotate(5deg); }
  80% { transform: rotate(-2deg); }
}

@media (prefers-reduced-motion: reduce) {
  .desk-cactus:hover {
    animation: none;
  }

  .job-notes-panel,
  .desk-cactus-flower,
  .desk-barry-tooltip,
  .agent-scene-moment,
  .agent-linked-highlight {
    transition: none;
  }

  .agent-hotspot.is-linked-pulse,
  .agent-linked-pulse {
    animation: none;
  }

  .agent-desk-scene.is-phone .agent-desk-image {
    transform: none;
  }
}


#chatPanel {

  transition:
    width 0.25s ease,
    height 0.25s ease,
    opacity 0.25s ease;
}

#chatPanel.collapsed {

  width: 340px !important;
  height: 88px !important;
  overflow: hidden;
}


/* make mobile fullscreen */
@media (max-width: 768px) {

  html,
  body {

    height: 100%;
  }

  #chatPanel {

    position: fixed;
    inset: 0;
    width: 100vw;
    height: 100vh;
    border-radius: 0 !important;
    display: flex;
    flex-direction: column;
  }

  #messages {

    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
  }

  /* minimized launcher becomes full-width mobile dock */
  #chatLauncher {  

    bottom: 12px !important;
    right: 12px !important;
    left: 12px !important;
    justify-content: center;
  }
}

