.ai-support-widget-root {
  position: fixed;
  right: 16px;
  bottom: 16px;
  z-index: 1200;
  font-family: "Montserrat", "Lato", sans-serif;
}

.ai-support-toggle {
  border: 0;
  border-radius: 999px;
  background: linear-gradient(135deg, #f4ae57, #f07e3b);
  color: #0f1f2f;
  font-weight: 800;
  font-size: 0.85rem;
  padding: 10px 14px;
  cursor: pointer;
  box-shadow: 0 8px 30px rgba(11, 21, 36, 0.35);
}

.ai-support-panel {
  width: min(360px, calc(100vw - 24px));
  max-height: min(72vh, 620px);
  display: grid;
  grid-template-rows: auto 1fr auto;
  background: #102033;
  color: #f4f7ff;
  border: 1px solid rgba(244, 174, 87, 0.3);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 16px 48px rgba(0, 0, 0, 0.42);
  margin-top: 10px;
}

.ai-support-panel[hidden] {
  display: none;
}

.ai-support-head {
  padding: 12px 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  justify-content: space-between;
  gap: 10px;
  align-items: flex-start;
}

.ai-support-title {
  margin: 0;
  font-size: 0.95rem;
  font-weight: 800;
}

.ai-support-subtitle {
  margin: 4px 0 0;
  color: rgba(232, 239, 255, 0.78);
  font-size: 0.75rem;
}

.ai-support-close {
  border: 0;
  background: transparent;
  color: rgba(232, 239, 255, 0.92);
  font-size: 0.85rem;
  cursor: pointer;
}

.ai-support-log {
  padding: 12px;
  overflow-y: auto;
  display: grid;
  gap: 8px;
  background: linear-gradient(180deg, rgba(13, 26, 42, 0.98), rgba(9, 17, 28, 0.98));
}

.ai-support-msg {
  border-radius: 12px;
  padding: 8px 10px;
  line-height: 1.35;
  font-size: 0.82rem;
  white-space: pre-wrap;
}

.ai-support-msg.user {
  background: rgba(244, 174, 87, 0.2);
  justify-self: end;
}

.ai-support-msg.bot {
  background: rgba(255, 255, 255, 0.08);
}

.ai-support-actions {
  margin-top: 6px;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.ai-support-action {
  border: 1px solid rgba(244, 174, 87, 0.35);
  color: #f4e2cd;
  background: rgba(244, 174, 87, 0.08);
  padding: 5px 8px;
  border-radius: 8px;
  font-size: 0.72rem;
  text-decoration: none;
}

.ai-support-form {
  padding: 10px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
  background: #0e1d30;
}

.ai-support-input {
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.04);
  color: #f4f7ff;
  min-height: 40px;
  max-height: 120px;
  resize: vertical;
  padding: 9px 10px;
  font-size: 0.82rem;
}

.ai-support-send {
  border: 0;
  border-radius: 10px;
  background: #f4ae57;
  color: #102033;
  font-weight: 800;
  padding: 0 12px;
  cursor: pointer;
}

.ai-support-send:disabled {
  opacity: 0.5;
  cursor: default;
}

@media (max-width: 700px) {
  .ai-support-widget-root {
    right: 10px;
    bottom: 10px;
    left: 10px;
  }

  .ai-support-panel {
    width: 100%;
  }
}
