/* Identical fixed rows reserve space before the first agent response arrives. */
.agent-status-pill,
.demo-agent-status {
  box-sizing: border-box;
  display: grid;
  grid-template-columns: 8px minmax(0, 1fr) 28px;
  align-items: center;
  gap: 10px;
  width: 340px;
  min-width: 0;
  max-width: 100%;
  height: 80px;
  min-height: 80px;
  max-height: 80px;
  padding: 10px 12px;
  border: 1px solid #e5e9f0;
  border-radius: 12px;
  background: linear-gradient(145deg, #fff, #fcfdff);
  box-shadow: 0 2px 5px rgba(16,24,40,.02), 0 8px 20px rgba(16,24,40,.035);
}
.demo-agent-status { width: 244px; grid-template-columns: 8px minmax(0, 1fr); }
.agent-status-pill .agent-status-pill__dot,
.demo-agent-status .signals-live-dot { width: 8px; height: 8px; border-radius: 50%; background: #a5afbd; box-shadow: 0 0 0 5px rgba(47,166,119,.09); }
.agent-status-pill .agent-status-pill__copy,
.demo-agent-status .signals-status-copy {
  display: grid;
  grid-template-rows: 18px 14px 20px;
  gap: 2px;
  width: auto;
  min-width: 0;
  line-height: 1.3;
}
.agent-status-pill .agent-status-pill__copy > strong,
.demo-agent-status .signals-status-copy > strong {
  font-size: 13px;
  font-weight: 700;
  line-height: 18px;
  letter-spacing: -.15px;
}
.agent-status-pill .agent-status-pill__copy small,
.demo-agent-status .signals-status-copy small {
  margin: 0;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  font-size: 10px;
  line-height: 14px;
  font-weight: 500;
  font-variant-numeric: tabular-nums;
  color: #7b8495;
}
#agent-version-status {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  gap: 7px;
  height: 20px;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  font-size: 10px;
  line-height: 16px;
  color: #7b8495;
  font-variant-numeric: tabular-nums;
}
#agent-running-version { color: #475467; font-weight: 600; }
#agent-latest-version { padding-left: 7px; border-left: 1px solid #e4e7ec; }
#agent-running-version, #agent-latest-version { overflow: hidden; text-overflow: ellipsis; }
#agent-update-link {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  height: 20px;
  min-height: 20px;
  margin: 0;
  padding: 0 6px;
  border: 0;
  border-radius: 5px;
  background: #eef2ff;
  color: #4258a8;
  font-size: 10px;
  font-weight: 600;
  text-decoration: none;
}
#agent-update-link:hover { background: #e2e9ff; color: #2e458e; }
/* Reserve the action slot without exposing an inactive control. */
#agent-update-link[hidden] { display: inline-flex !important; visibility: hidden; pointer-events: none; }
.agent-status-pill .agent-status-controls { margin: 0; }
.agent-status-pill .agent-status-control-button {
  width: 28px;
  min-width: 28px;
  height: 28px;
  padding: 0;
  border: 1px solid #edf0f4;
  border-radius: 8px;
  background: #f4f6f9;
  color: #525b69;
  font-size: 11px;
}
.agent-status-pill .agent-status-control-button:hover { background: #e9edf3; color: #273346; }
@media (max-width: 600px) {
  .agent-status-pill, .demo-agent-status { max-width: 100%; }
}

.agent-status-pill[data-agent-sync-state="connected"] .agent-status-pill__dot { background: #2fa677; }
