/*
 * Tailwind v4 does not scan package sources in node_modules unless the
 * consuming app opts in. Import this stylesheet from a Dispatch app's global
 * CSS so Tailwind includes the utilities used by packaged Dispatch routes and
 * components.
 */
@source "../components/**/*.{js,mjs,ts,tsx}";
@source "../hooks/**/*.{js,mjs,ts,tsx}";
@source "../routes/**/*.{js,mjs,ts,tsx}";
@source "../../../core/src/client/chat-first/**/*.{ts,tsx}";

/* Keep Dispatch data visualizations aligned with Analytics' blue chart accent. */
:root {
  --dispatch-brand-blue: 200 97% 39%;
}

.dark {
  --dispatch-brand-blue: 197 100% 50%;
}

.dispatch-chat-first-chats .an-chat-history-rail__new-chat {
  display: none;
}

.dispatch-chat-first-notice {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  border-bottom: 1px solid hsl(var(--border));
  background: hsl(var(--muted) / 0.35);
  padding: 0.5rem 0.75rem;
  color: hsl(var(--muted-foreground));
  font-size: 0.75rem;
}

.dispatch-chat-first-notice button {
  flex: none;
  color: hsl(var(--foreground));
  font-weight: 600;
}

body:has(.fixed.bottom-3.left-3) [data-dispatch-sidebar-footer] {
  /* The fixed environment badge only needs this space when it is rendered. */
  padding-bottom: 2.5rem;
}

@media (max-width: 767px) {
  .dispatch-chat-first-surface {
    position: relative;
  }
}

.dispatch-chat-panel [data-agent-empty-state="centered"] {
  justify-content: center;
  padding-bottom: clamp(4rem, 12vh, 8rem);
}

.dispatch-chat-intro {
  display: none;
}

.dispatch-chat-panel [data-agent-empty-state="centered"] .dispatch-chat-intro {
  display: grid;
  width: 100%;
  max-width: min(750px, 90%);
  gap: 0.5rem;
  margin: 0 auto 1rem;
  text-align: center;
}

.dispatch-chat-intro h1 {
  margin: 0;
  color: hsl(var(--foreground));
  font-size: 2.5rem;
  font-weight: 600;
  letter-spacing: 0;
  line-height: 1.12;
}

.dispatch-chat-intro p {
  margin: 0;
  color: hsl(var(--muted-foreground));
  font-size: 0.9375rem;
  line-height: 1.5;
}

.dispatch-chat-panel [data-agent-empty-state="centered"] .agent-chat-scroll {
  flex: 0 0 auto;
  min-height: 0;
  overflow: visible;
}

.dispatch-chat-panel [data-agent-empty-state="centered"] .agent-composer-area {
  width: 100%;
  max-width: min(750px, 100%);
  padding: 0;
}

.dispatch-chat-panel [data-agent-empty-state="centered"] .agent-composer-root {
  min-height: 7.875rem;
  border-color: hsl(var(--border));
  border-radius: 1rem;
  background: hsl(var(--card));
  box-shadow: none;
}

.dark
  .dispatch-chat-panel
  [data-agent-empty-state="centered"]
  .agent-composer-root {
  box-shadow: none;
}

.dispatch-chat-panel
  [data-agent-empty-state="centered"]
  .agent-composer-prosemirror {
  min-height: 5.0625rem;
  font-size: 1rem;
  line-height: 1.625rem;
}

@media (max-width: 767px) {
  .dispatch-chat-panel [data-agent-empty-state="centered"] {
    padding: 1rem;
    padding-bottom: 5rem;
  }

  .dispatch-chat-panel
    [data-agent-empty-state="centered"]
    .dispatch-chat-intro {
    width: 100%;
    margin-bottom: 0.875rem;
  }

  .dispatch-chat-intro h1 {
    font-size: 1.75rem;
  }

  .dispatch-chat-panel
    [data-agent-empty-state="centered"]
    .agent-composer-area {
    width: 100%;
  }

  .dispatch-chat-panel
    [data-agent-empty-state="centered"]
    .agent-composer-root {
    min-height: 6.75rem;
  }
}
