/* ─── Pubspec health check ─── */

:root {
  --health-good: oklch(58% 0.15 150);
  --health-warn: oklch(67% 0.15 75);
  --health-bad: var(--destructive);
}

.dark {
  --health-good: oklch(74% 0.14 150);
  --health-warn: oklch(79% 0.14 80);
}

.health-page {
  width: 100%;
  max-width: 64rem;
  margin: 0 auto;
  padding: 2.5rem 1rem 4rem;
}

.health-hero {
  text-align: center;
  max-width: 44rem;
  margin: 0 auto 2rem;
}

.health-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.375rem;
  padding: 0.35rem 0.8rem;
  border: 1px solid color-mix(in oklab, var(--primary) 30%, transparent);
  border-radius: 999px;
  background: color-mix(in oklab, var(--primary) 8%, transparent);
  color: var(--secondary-foreground);
  font-size: 0.8rem;
}

.health-title {
  margin-top: 1rem;
  font-size: clamp(1.9rem, 4vw, 2.75rem);
  font-weight: 700;
  line-height: 1.15;
  letter-spacing: -0.02em;
}

.health-subtitle {
  margin-top: 0.75rem;
  color: var(--muted-foreground);
  font-size: 1rem;
  line-height: 1.65;
}

.health-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(0, 1fr);
  gap: 1rem;
  align-items: start;
}

.health-card {
  border: 1px solid color-mix(in oklab, var(--border) 70%, transparent);
  border-radius: 14px;
  background: color-mix(in oklab, var(--card) 85%, transparent);
  padding: 1.15rem 1.2rem;
}

.health-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}

.health-card-title {
  font-size: 0.95rem;
  font-weight: 600;
}

.health-card-subtitle {
  margin-top: 0.25rem;
  color: var(--muted-foreground);
  font-size: 0.78rem;
  line-height: 1.5;
}

.health-head-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 0.35rem;
}

.health-link-button {
  border: 1px solid transparent;
  border-radius: 7px;
  padding: 0.25rem 0.5rem;
  color: var(--primary);
  font-size: 0.75rem;
  white-space: nowrap;
  transition: background-color 140ms ease, border-color 140ms ease;
}

.health-link-button:hover {
  border-color: color-mix(in oklab, var(--primary) 25%, transparent);
  background: color-mix(in oklab, var(--primary) 7%, transparent);
}

.health-file-input {
  display: none;
}

.health-textarea {
  display: block;
  width: 100%;
  min-height: 15rem;
  margin-top: 0.85rem;
  padding: 0.8rem 0.9rem;
  border: 1px solid color-mix(in oklab, var(--border) 80%, transparent);
  border-radius: 10px;
  background: color-mix(in oklab, var(--secondary) 35%, transparent);
  color: var(--foreground);
  font-family: var(--font-mono);
  font-size: 0.78rem;
  line-height: 1.6;
  resize: vertical;
  outline: none;
}

.health-textarea:focus {
  border-color: color-mix(in oklab, var(--primary) 45%, transparent);
  box-shadow: 0 0 0 3px color-mix(in oklab, var(--primary) 12%, transparent);
}

.health-textarea::placeholder {
  color: color-mix(in oklab, var(--muted-foreground) 65%, transparent);
}

.health-file-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  min-width: 0;
  margin-top: 0.6rem;
  padding: 0.2rem 0.5rem;
  border: 1px solid color-mix(in oklab, var(--primary) 25%, transparent);
  border-radius: 6px;
  background: color-mix(in oklab, var(--primary) 7%, transparent);
  font-size: 0.72rem;
}

.health-file-name {
  max-width: 18rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.health-file-kind {
  padding: 0 0.25rem;
  border-radius: 3px;
  background: color-mix(in oklab, var(--primary) 14%, transparent);
  color: var(--primary);
  font-family: var(--font-mono);
  font-size: 0.58rem;
  letter-spacing: 0.04em;
}

.health-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  margin-top: 0.85rem;
}

.health-primary,
.health-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  height: 2.35rem;
  padding: 0 1rem;
  border-radius: 8px;
  font-size: 0.85rem;
  font-weight: 600;
  transition: opacity 140ms ease, background-color 140ms ease;
}

.health-primary {
  background: var(--primary);
  color: var(--primary-foreground);
}

.health-primary:hover:not([disabled]) {
  opacity: 0.9;
}

.health-primary[disabled] {
  cursor: progress;
  opacity: 0.6;
}

.health-secondary {
  border: 1px solid color-mix(in oklab, var(--border) 80%, transparent);
  color: var(--muted-foreground);
}

.health-secondary:hover {
  background: var(--secondary);
  color: var(--foreground);
}

.health-autofix-input {
  border-color: color-mix(in oklab, var(--primary) 35%, transparent);
  color: var(--primary);
}

.health-autofix-input:hover {
  background: color-mix(in oklab, var(--primary) 6%, transparent);
  color: var(--primary);
}

.health-spinner {
  width: 0.85rem;
  height: 0.85rem;
  border: 2px solid color-mix(in oklab, currentColor 30%, transparent);
  border-top-color: currentColor;
  border-radius: 50%;
  animation: health-spin 0.7s linear infinite;
}

@keyframes health-spin {
  to {
    transform: rotate(360deg);
  }
}

.health-note {
  margin-top: 0.65rem;
  color: color-mix(in oklab, var(--muted-foreground) 80%, transparent);
  font-size: 0.7rem;
  line-height: 1.5;
}

.health-intro {
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
}

.health-checklist {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}

.health-checklist li {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  color: var(--secondary-foreground);
  font-size: 0.8rem;
  line-height: 1.5;
}

.health-checklist li svg {
  flex: 0 0 auto;
  margin-top: 0.18rem;
  color: var(--primary);
}

.health-intro-note {
  margin-top: auto;
  padding-top: 0.75rem;
  border-top: 1px solid color-mix(in oklab, var(--border) 45%, transparent);
  color: var(--muted-foreground);
  font-size: 0.72rem;
  line-height: 1.55;
}

.health-summary-card {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.health-summary-head {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.health-score {
  display: flex;
  flex: 0 0 auto;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 4.6rem;
  height: 4.6rem;
  border: 3px solid var(--border);
  border-radius: 50%;
  background: color-mix(in oklab, var(--card) 80%, transparent);
}

.health-score.is-good {
  border-color: var(--health-good);
  color: var(--health-good);
}

.health-score.is-ok {
  border-color: var(--health-warn);
  color: var(--health-warn);
}

.health-score.is-bad {
  border-color: var(--health-bad);
  color: var(--health-bad);
}

.health-score-value {
  font-size: 1.5rem;
  font-weight: 700;
  line-height: 1;
}

.health-score-label {
  margin-top: 0.2rem;
  color: var(--muted-foreground);
  font-size: 0.58rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.health-manifest {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  min-width: 0;
}

.health-manifest-name {
  overflow: hidden;
  font-family: var(--font-mono);
  font-size: 0.9rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.health-manifest-meta {
  color: var(--muted-foreground);
  font-family: var(--font-mono);
  font-size: 0.68rem;
}

.health-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.health-stat {
  display: flex;
  flex: 1 1 4.2rem;
  flex-direction: column;
  gap: 0.1rem;
  padding: 0.5rem 0.6rem;
  border: 1px solid color-mix(in oklab, var(--border) 60%, transparent);
  border-radius: 8px;
  background: color-mix(in oklab, var(--secondary) 25%, transparent);
}

.health-stat-value {
  font-size: 1.05rem;
  font-weight: 650;
  line-height: 1.1;
}

.health-stat-label {
  color: var(--muted-foreground);
  font-size: 0.62rem;
  white-space: nowrap;
}

.health-stat.is-warn .health-stat-value {
  color: var(--health-warn);
}

.health-stat.is-bad .health-stat-value {
  color: var(--health-bad);
}

.health-stat.is-good .health-stat-value {
  color: var(--health-good);
}

.health-error {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  margin-top: 0.75rem;
  padding: 0.7rem 0.85rem;
  border: 1px solid color-mix(in oklab, var(--destructive) 35%, transparent);
  border-radius: 9px;
  background: color-mix(in oklab, var(--destructive) 8%, transparent);
  color: var(--destructive);
  font-size: 0.8rem;
  line-height: 1.5;
}

.health-section {
  margin-top: 1.6rem;
}

.health-section-head {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.6rem;
}

.health-section-title {
  font-size: 1.05rem;
  font-weight: 650;
}

.health-count {
  min-width: 1.4rem;
  padding: 0 0.4rem;
  border-radius: 999px;
  background: color-mix(in oklab, var(--primary) 10%, transparent);
  color: var(--primary);
  font-family: var(--font-mono);
  font-size: 0.68rem;
  line-height: 1.4rem;
  text-align: center;
}

.health-rows {
  overflow: hidden;
  border: 1px solid color-mix(in oklab, var(--border) 65%, transparent);
  border-radius: 11px;
  background: color-mix(in oklab, var(--card) 70%, transparent);
}

.health-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.7rem 0.9rem;
  border-top: 1px solid color-mix(in oklab, var(--border) 40%, transparent);
}

.health-row:first-child {
  border-top: 0;
}

.health-row:hover {
  background: color-mix(in oklab, var(--secondary) 35%, transparent);
}

.health-row-main {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  min-width: 0;
}

.health-pkg-line {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem;
}

.health-pkg {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  color: var(--foreground);
  font-family: var(--font-mono);
  font-size: 0.82rem;
  font-weight: 500;
  overflow-wrap: anywhere;
}

.health-pkg:hover {
  color: var(--primary);
}

.health-pkg svg {
  color: var(--muted-foreground);
}

.health-tag {
  padding: 0.05rem 0.35rem;
  border-radius: 4px;
  background: var(--secondary);
  color: var(--muted-foreground);
  font-size: 0.6rem;
}

.health-version-line {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem;
  color: var(--muted-foreground);
  font-size: 0.72rem;
}

.health-mono {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  overflow-wrap: anywhere;
}

.health-latest {
  color: var(--foreground);
}

.health-arrow {
  color: color-mix(in oklab, var(--muted-foreground) 60%, transparent);
}

.health-behind {
  padding: 0.05rem 0.35rem;
  border-radius: 4px;
  background: color-mix(in oklab, var(--health-warn) 12%, transparent);
  color: var(--health-warn);
  font-size: 0.6rem;
}

.health-row-actions {
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 0.45rem;
}

.health-copy {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  height: 1.55rem;
  padding: 0 0.45rem;
  border: 1px solid color-mix(in oklab, var(--border) 75%, transparent);
  border-radius: 6px;
  color: var(--muted-foreground);
  font-family: var(--font-mono);
  font-size: 0.66rem;
  white-space: nowrap;
  transition: color 120ms ease, border-color 120ms ease, background-color 120ms ease;
}

.health-copy:hover {
  border-color: color-mix(in oklab, var(--primary) 30%, transparent);
  background: color-mix(in oklab, var(--primary) 5%, transparent);
  color: var(--primary);
}

.health-copy.is-copied {
  border-color: color-mix(in oklab, var(--health-good) 35%, transparent);
  color: var(--health-good);
}

.health-status {
  padding: 0.12rem 0.45rem;
  border-radius: 999px;
  background: var(--secondary);
  color: var(--muted-foreground);
  font-size: 0.62rem;
  white-space: nowrap;
}

.health-status.is-good {
  background: color-mix(in oklab, var(--health-good) 12%, transparent);
  color: var(--health-good);
}

.health-status.is-warn {
  background: color-mix(in oklab, var(--health-warn) 12%, transparent);
  color: var(--health-warn);
}

.health-status.is-bad {
  background: color-mix(in oklab, var(--health-bad) 12%, transparent);
  color: var(--health-bad);
}

.health-status.is-info {
  background: color-mix(in oklab, var(--primary) 9%, transparent);
  color: var(--primary);
}

.health-empty {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  padding: 0.75rem 0.9rem;
  border: 1px dashed color-mix(in oklab, var(--border) 70%, transparent);
  border-radius: 10px;
  color: var(--muted-foreground);
  font-size: 0.8rem;
}

.health-empty svg {
  color: var(--health-good);
}

.health-row-deprecated {
  align-items: flex-start;
}

.health-row-text {
  color: var(--secondary-foreground);
  font-size: 0.76rem;
  line-height: 1.55;
}

.health-alt-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-top: 0.15rem;
}

.health-alt-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.15rem 0.45rem;
  border: 1px solid color-mix(in oklab, var(--primary) 22%, transparent);
  border-radius: 999px;
  background: color-mix(in oklab, var(--primary) 5%, transparent);
  font-family: var(--font-mono);
  font-size: 0.66rem;
}

.health-alt-chip-version {
  color: var(--muted-foreground);
  font-size: 0.6rem;
}

.health-alt-groups {
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
}

.health-alt-group {
  border: 1px solid color-mix(in oklab, var(--border) 65%, transparent);
  border-radius: 11px;
  background: color-mix(in oklab, var(--card) 70%, transparent);
  padding: 0.75rem 0.85rem;
}

.health-alt-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.health-alt-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(12rem, 1fr));
  gap: 0.5rem;
  margin-top: 0.55rem;
}

.health-alt-card {
  padding: 0.55rem 0.65rem;
  border: 1px solid color-mix(in oklab, var(--border) 55%, transparent);
  border-radius: 8px;
  background: color-mix(in oklab, var(--secondary) 22%, transparent);
}

.health-alt-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.health-alt-desc {
  margin-top: 0.25rem;
  color: var(--muted-foreground);
  font-size: 0.7rem;
  line-height: 1.45;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.health-alt-meta {
  display: flex;
  align-items: center;
  gap: 0.3rem;
  margin-top: 0.35rem;
  color: var(--muted-foreground);
  font-size: 0.62rem;
}

.health-dot {
  width: 2px;
  height: 2px;
  border-radius: 50%;
  background: currentColor;
}

.health-muted {
  color: var(--muted-foreground);
}

.health-risks {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.health-risk {
  display: flex;
  gap: 0.55rem;
  padding: 0.6rem 0.75rem;
  border: 1px solid color-mix(in oklab, var(--border) 60%, transparent);
  border-radius: 9px;
  background: color-mix(in oklab, var(--card) 70%, transparent);
}

.health-risk-dot {
  flex: 0 0 auto;
  width: 0.4rem;
  height: 0.4rem;
  margin-top: 0.35rem;
  border-radius: 50%;
  background: var(--muted-foreground);
}

.health-risk.is-bad .health-risk-dot {
  background: var(--health-bad);
}

.health-risk.is-warn .health-risk-dot {
  background: var(--health-warn);
}

.health-risk.is-info .health-risk-dot {
  background: var(--primary);
}

.health-risk-body {
  min-width: 0;
}

.health-risk-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem;
}

.health-severity {
  color: var(--muted-foreground);
  font-size: 0.6rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.health-suggestions {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.health-suggestion {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  padding: 0.6rem 0.75rem;
  border: 1px solid color-mix(in oklab, var(--border) 60%, transparent);
  border-radius: 9px;
  background: color-mix(in oklab, var(--card) 70%, transparent);
}

.health-priority {
  flex: 0 0 auto;
  min-width: 2rem;
  padding: 0.1rem 0.35rem;
  border-radius: 4px;
  background: var(--secondary);
  color: var(--muted-foreground);
  font-size: 0.6rem;
  text-align: center;
}

.health-priority.is-bad {
  background: color-mix(in oklab, var(--health-bad) 12%, transparent);
  color: var(--health-bad);
}

.health-priority.is-warn {
  background: color-mix(in oklab, var(--health-warn) 12%, transparent);
  color: var(--health-warn);
}

.health-priority.is-info {
  background: color-mix(in oklab, var(--primary) 9%, transparent);
  color: var(--primary);
}

.health-suggestion-body {
  min-width: 0;
}

.health-target {
  display: inline-block;
  margin-top: 0.35rem;
  padding: 0.2rem 0.45rem;
  border: 1px solid color-mix(in oklab, var(--border) 65%, transparent);
  border-radius: 5px;
  background: color-mix(in oklab, var(--secondary) 40%, transparent);
  color: var(--foreground);
  font-family: var(--font-mono);
  font-size: 0.7rem;
  overflow-wrap: anywhere;
}

.health-footnote {
  margin-top: 1.5rem;
  color: var(--muted-foreground);
  font-size: 0.7rem;
  line-height: 1.5;
  text-align: center;
}

.health-resolve-tag {
  padding: 0.02rem 0.28rem;
  border-radius: 3px;
  background: color-mix(in oklab, var(--health-good) 12%, transparent);
  color: var(--health-good);
  font-size: 0.58rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.health-resolved {
  color: var(--foreground);
}

/* ─── Health report inside the chat ─── */

.msg-attachment {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 3px 8px;
  border: 1px solid color-mix(in oklab, var(--border) 60%, transparent);
  border-radius: 999px;
  background: var(--secondary);
  color: var(--muted-foreground);
}

.msg-file-kind {
  padding: 1px 4px;
  border-radius: 3px;
  background: color-mix(in oklab, var(--primary) 12%, transparent);
  color: var(--primary);
  font-family: var(--font-mono);
  font-size: 9px;
  letter-spacing: 0.04em;
}

.msg-file-name {
  font-family: var(--font-mono);
  font-size: 11px;
}

.health-report {
  display: flex;
  flex-direction: column;
}

/* ─── Health result page ─── */

.health-result-hero {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  margin-bottom: 1.5rem;
}

.health-result-back {
  align-self: flex-start;
  color: var(--muted-foreground);
  font-size: 0.76rem;
  transition: color 140ms ease;
}

.health-result-back:hover {
  color: var(--primary);
}

.health-result-loading {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 1rem 1.1rem;
  color: var(--muted-foreground);
  font-size: 0.84rem;
}

/* ─── Dependency resolution ─── */

.health-resolution {
  padding: 0.85rem 0.95rem;
  border: 1px solid color-mix(in oklab, var(--border) 70%, transparent);
  border-radius: 12px;
  background: color-mix(in oklab, var(--card) 75%, transparent);
}

.health-resolution.is-good {
  border-color: color-mix(in oklab, var(--health-good) 35%, transparent);
  background: color-mix(in oklab, var(--health-good) 5%, transparent);
}

.health-resolution.is-bad {
  border-color: color-mix(in oklab, var(--health-bad) 35%, transparent);
  background: color-mix(in oklab, var(--health-bad) 5%, transparent);
}

.health-resolution.is-warn {
  border-color: color-mix(in oklab, var(--health-warn) 35%, transparent);
  background: color-mix(in oklab, var(--health-warn) 5%, transparent);
}

.health-resolution-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
}

.health-resolution-title {
  font-size: 0.9rem;
  font-weight: 650;
}

.health-solver {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
  margin-top: 0.3rem;
}

.health-solver-badge {
  padding: 0.08rem 0.4rem;
  border: 1px solid color-mix(in oklab, var(--border) 65%, transparent);
  border-radius: 999px;
  color: var(--muted-foreground);
  font-family: var(--font-mono);
  font-size: 0.6rem;
}

.health-resolution-time {
  flex: 0 0 auto;
  color: var(--muted-foreground);
  font-family: var(--font-mono);
  font-size: 0.64rem;
}

.health-solve-counts {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-top: 0.7rem;
}

.health-solve-count {
  display: inline-flex;
  align-items: baseline;
  gap: 0.3rem;
  padding: 0.22rem 0.5rem;
  border-radius: 7px;
  background: color-mix(in oklab, var(--secondary) 35%, transparent);
}

.health-solve-count-value {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  font-weight: 600;
}

.health-solve-count-label {
  color: var(--muted-foreground);
  font-size: 0.62rem;
}

.health-selected-list {
  max-height: 15rem;
  margin-top: 0.55rem;
  overflow-y: auto;
  border-top: 1px solid color-mix(in oklab, var(--border) 40%, transparent);
}

.health-selected-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.28rem 0;
  border-bottom: 1px solid color-mix(in oklab, var(--border) 25%, transparent);
}

.health-selected-row:last-child {
  border-bottom: 0;
}

.health-selected-name {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  min-width: 0;
}

.health-kind {
  padding: 0.02rem 0.3rem;
  border-radius: 3px;
  background: var(--secondary);
  color: var(--muted-foreground);
  font-size: 0.55rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.health-kind.is-info {
  background: color-mix(in oklab, var(--primary) 9%, transparent);
  color: var(--primary);
}

.health-kind.is-warn {
  background: color-mix(in oklab, var(--health-warn) 12%, transparent);
  color: var(--health-warn);
}

.health-conflict-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
  margin-top: 0.6rem;
}

.health-conflict-chip {
  padding: 0.12rem 0.4rem;
  border: 1px solid color-mix(in oklab, var(--health-bad) 25%, transparent);
  border-radius: 5px;
  background: color-mix(in oklab, var(--health-bad) 6%, transparent);
  color: var(--health-bad);
  font-family: var(--font-mono);
  font-size: 0.62rem;
  overflow-wrap: anywhere;
}

.health-conflict-log {
  max-height: 16rem;
  margin-top: 0.6rem;
  padding: 0.65rem 0.75rem;
  overflow: auto;
  border: 1px solid color-mix(in oklab, var(--border) 55%, transparent);
  border-radius: 8px;
  background: color-mix(in oklab, var(--secondary) 30%, transparent);
  color: var(--secondary-foreground);
  font-family: var(--font-mono);
  font-size: 0.68rem;
  line-height: 1.55;
  white-space: pre-wrap;
}

.health-resolution-label {
  margin-top: 0.65rem;
  color: var(--muted-foreground);
  font-size: 0.64rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.health-fixes {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  margin-top: 0.4rem;
}

.health-fix {
  padding: 0.5rem 0.6rem;
  border: 1px solid color-mix(in oklab, var(--border) 55%, transparent);
  border-radius: 8px;
  background: color-mix(in oklab, var(--card) 60%, transparent);
}

.health-fix-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.4rem;
}

.health-fix-action {
  font-family: var(--font-mono);
  font-size: 0.72rem;
}

.health-resolution-note {
  margin-top: 0.55rem;
  color: var(--secondary-foreground);
  font-size: 0.76rem;
  line-height: 1.55;
}

.health-skipped {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem;
  margin-top: 0.6rem;
}

.health-skip-chip {
  padding: 0.1rem 0.38rem;
  border-radius: 4px;
  background: var(--secondary);
  color: var(--muted-foreground);
  font-size: 0.62rem;
}

.health-fix-cta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.6rem;
  margin-top: 0.8rem;
}

.health-autofix {
  min-height: 2.2rem;
  padding: 0 0.9rem;
  font-size: 0.8rem;
}

.health-autofix-note {
  color: var(--muted-foreground);
  font-size: 0.68rem;
  line-height: 1.45;
}

.health-fix-result {
  padding: 0.85rem 0.95rem;
  border: 1px solid color-mix(in oklab, var(--border) 70%, transparent);
  border-radius: 12px;
  background: color-mix(in oklab, var(--card) 75%, transparent);
}

.health-fix-result.is-good {
  border-color: color-mix(in oklab, var(--health-good) 35%, transparent);
  background: color-mix(in oklab, var(--health-good) 5%, transparent);
}

.health-fix-result.is-warn {
  border-color: color-mix(in oklab, var(--health-warn) 35%, transparent);
  background: color-mix(in oklab, var(--health-warn) 5%, transparent);
}

.health-fix-result.is-info {
  border-color: color-mix(in oklab, var(--primary) 25%, transparent);
  background: color-mix(in oklab, var(--primary) 4%, transparent);
}

.health-applied-list {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  margin-top: 0.5rem;
}

.health-applied-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.4rem;
  padding: 0.28rem 0.45rem;
  border-radius: 6px;
  background: color-mix(in oklab, var(--secondary) 30%, transparent);
}

.health-applied-name {
  font-family: var(--font-mono);
  font-size: 0.76rem;
}

.health-applied-change {
  color: var(--muted-foreground);
  font-family: var(--font-mono);
  font-size: 0.7rem;
}

.health-fix-pubspec {
  max-height: 18rem;
  margin-top: 0.6rem;
  padding: 0.7rem 0.8rem;
  overflow: auto;
  border: 1px solid color-mix(in oklab, var(--border) 55%, transparent);
  border-radius: 8px;
  background: color-mix(in oklab, var(--secondary) 30%, transparent);
  color: var(--secondary-foreground);
  font-family: var(--font-mono);
  font-size: 0.7rem;
  line-height: 1.55;
  white-space: pre;
}

.health-fix-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem;
  margin-top: 0.6rem;
}

.health-fix-download {
  display: inline-flex;
  align-items: center;
  height: 1.8rem;
  padding: 0 0.6rem;
  border: 1px solid color-mix(in oklab, var(--border) 70%, transparent);
  border-radius: 7px;
  color: var(--muted-foreground);
  font-size: 0.72rem;
  transition: color 120ms ease, border-color 120ms ease, background-color 120ms ease;
}

.health-fix-download:hover {
  border-color: color-mix(in oklab, var(--primary) 30%, transparent);
  background: color-mix(in oklab, var(--primary) 5%, transparent);
  color: var(--primary);
}

.health-fix-verified {
  margin-top: 0.45rem;
  color: var(--health-good);
  font-size: 0.7rem;
}

.health-fix-error {
  margin-top: 0.75rem;
}

@media (max-width: 52rem) {
  .health-layout {
    grid-template-columns: 1fr;
  }

  .health-summary-card {
    order: -1;
  }
}

@media (max-width: 36rem) {
  .health-page {
    padding: 1.5rem 0.85rem 3rem;
  }

  .health-card-head {
    flex-direction: column;
  }

  .health-head-actions {
    justify-content: flex-start;
  }

  .health-row {
    align-items: flex-start;
    flex-direction: column;
    gap: 0.5rem;
  }

  .health-row-actions {
    width: 100%;
    justify-content: flex-start;
  }

  .health-stats {
    gap: 0.35rem;
  }

  .health-stat {
    flex-basis: 4.8rem;
  }
}

/* ─── Pubspec analysis dashboard ─── */

.an-page {
  position: relative;
  width: 100%;
  max-width: 86rem;
  margin: 0 auto;
  padding: 1.75rem 1rem 4rem;
}

.an-page::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 24rem;
  pointer-events: none;
  background:
    radial-gradient(ellipse 55% 60% at 22% 0%, color-mix(in oklab, var(--primary) 9%, transparent), transparent 70%),
    radial-gradient(ellipse 40% 50% at 82% 0%, color-mix(in oklab, var(--primary) 5%, transparent), transparent 70%);
}

.an-page > * {
  position: relative;
}

.an-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.25rem;
}

.an-head-main {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.45rem;
  min-width: 0;
}

.an-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.28rem 0.7rem;
  border: 1px solid color-mix(in oklab, var(--primary) 28%, transparent);
  border-radius: 999px;
  background: color-mix(in oklab, var(--primary) 8%, transparent);
  color: color-mix(in oklab, var(--primary) 72%, var(--foreground));
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.an-title {
  font-size: clamp(1.65rem, 3.4vw, 2.4rem);
  font-weight: 700;
  line-height: 1.1;
  letter-spacing: -0.03em;
  background: linear-gradient(100deg, var(--foreground) 20%, color-mix(in oklab, var(--primary) 72%, var(--foreground)));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.an-subtitle {
  max-width: 46rem;
  color: var(--muted-foreground);
  font-size: 0.9rem;
  line-height: 1.6;
}

.an-head-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-end;
  gap: 0.45rem;
}

/* Buttons */

.an-btn,
.an-link-btn,
.an-icon-btn,
.an-nav-btn,
.an-chip-btn,
.an-pkg-link,
.an-alt-chip,
.an-copy,
.an-mini-row {
  font-family: inherit;
}

.an-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  height: 2.3rem;
  padding: 0 0.95rem;
  border: 1px solid transparent;
  border-radius: 9px;
  font-size: 0.8rem;
  font-weight: 600;
  line-height: 1;
  white-space: nowrap;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 140ms ease, border-color 140ms ease, opacity 140ms ease,
    box-shadow 140ms ease, transform 140ms ease;
}

.an-btn:active:not([disabled]) {
  transform: translateY(1px);
}

.an-btn[disabled] {
  opacity: 0.6;
  cursor: default;
}

.an-btn-primary {
  background: var(--primary);
  color: var(--primary-foreground);
  box-shadow: 0 4px 14px color-mix(in oklab, var(--primary) 24%, transparent);
}

.an-btn-primary:hover:not([disabled]) {
  opacity: 0.92;
  box-shadow: 0 6px 18px color-mix(in oklab, var(--primary) 30%, transparent);
}

.an-btn-outline {
  border-color: color-mix(in oklab, var(--border) 80%, transparent);
  background: color-mix(in oklab, var(--card) 70%, transparent);
  color: var(--foreground);
}

.an-btn-outline:hover {
  border-color: color-mix(in oklab, var(--primary) 35%, transparent);
  background: color-mix(in oklab, var(--secondary) 55%, transparent);
}

.an-btn-ghost {
  background: transparent;
  color: var(--muted-foreground);
}

.an-btn-ghost:hover {
  background: color-mix(in oklab, var(--secondary) 60%, transparent);
  color: var(--foreground);
}

.an-btn-sm {
  height: 1.95rem;
  padding: 0 0.7rem;
  border-radius: 8px;
  font-size: 0.72rem;
}

.an-link-btn {
  border: 1px solid transparent;
  border-radius: 7px;
  padding: 0.24rem 0.5rem;
  color: color-mix(in oklab, var(--primary) 80%, var(--foreground));
  background: transparent;
  font-size: 0.72rem;
  font-weight: 500;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color 140ms ease, border-color 140ms ease;
}

.an-link-btn:hover {
  border-color: color-mix(in oklab, var(--primary) 22%, transparent);
  background: color-mix(in oklab, var(--primary) 7%, transparent);
}

.an-icon-btn {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  width: 1.85rem;
  height: 1.85rem;
  border: 1px solid transparent;
  border-radius: 8px;
  background: transparent;
  color: var(--muted-foreground);
  cursor: pointer;
  transition: background-color 140ms ease, color 140ms ease, border-color 140ms ease;
}

.an-icon-btn:hover {
  border-color: color-mix(in oklab, var(--border) 60%, transparent);
  background: color-mix(in oklab, var(--secondary) 55%, transparent);
  color: var(--foreground);
}

/* Setup */

.an-setup {
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
}

.an-intro-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr);
  gap: 1rem;
  align-items: start;
}

.an-panel,
.an-card {
  border: 1px solid color-mix(in oklab, var(--border) 68%, transparent);
  border-radius: 14px;
  background: color-mix(in oklab, var(--card) 78%, transparent);
  backdrop-filter: blur(10px);
}

.an-panel {
  padding: 1.2rem 1.25rem;
}

.an-card {
  padding: 1.05rem 1.1rem;
  min-width: 0;
}

.an-panel-head,
.an-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
}

.an-panel-title,
.an-card-title {
  font-size: 0.96rem;
  font-weight: 650;
  letter-spacing: -0.01em;
}

.an-panel-sub,
.an-card-sub {
  margin-top: 0.2rem;
  color: var(--muted-foreground);
  font-size: 0.74rem;
  line-height: 1.5;
}

.an-card-head {
  margin-bottom: 0.6rem;
}

.an-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.45rem;
  height: 1.25rem;
  padding: 0 0.4rem;
  border-radius: 999px;
  background: color-mix(in oklab, var(--secondary) 70%, transparent);
  color: var(--secondary-foreground);
  font-family: var(--font-mono);
  font-size: 0.64rem;
}

.an-editor .an-panel-head {
  margin-bottom: 0.75rem;
}

.an-file-input {
  display: none;
}

.an-textarea {
  display: block;
  width: 100%;
  min-height: 17rem;
  padding: 0.85rem 0.95rem;
  border: 1px solid color-mix(in oklab, var(--border) 80%, transparent);
  border-radius: 10px;
  background: color-mix(in oklab, var(--secondary) 30%, transparent);
  color: var(--foreground);
  font-family: var(--font-mono);
  font-size: 0.78rem;
  line-height: 1.65;
  resize: vertical;
  outline: none;
  transition: border-color 140ms ease, box-shadow 140ms ease;
}

.an-textarea:focus {
  border-color: color-mix(in oklab, var(--primary) 45%, transparent);
  box-shadow: 0 0 0 3px color-mix(in oklab, var(--primary) 12%, transparent);
}

.an-textarea::placeholder {
  color: color-mix(in oklab, var(--muted-foreground) 60%, transparent);
}

.an-file-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  min-width: 0;
  margin-top: 0.55rem;
  padding: 0.2rem 0.5rem;
  border: 1px solid color-mix(in oklab, var(--primary) 25%, transparent);
  border-radius: 6px;
  background: color-mix(in oklab, var(--primary) 7%, transparent);
  font-size: 0.7rem;
}

.an-file-name {
  max-width: 20rem;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.an-file-kind {
  padding: 0 0.25rem;
  border-radius: 3px;
  background: color-mix(in oklab, var(--primary) 14%, transparent);
  color: var(--primary);
  font-family: var(--font-mono);
  font-size: 0.56rem;
  letter-spacing: 0.04em;
}

.an-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem;
  margin-top: 0.8rem;
}

.an-note {
  margin-top: 0.6rem;
  color: color-mix(in oklab, var(--muted-foreground) 85%, transparent);
  font-size: 0.7rem;
  line-height: 1.55;
}

.an-checklist {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
  margin-top: 0.85rem;
  padding: 0;
  list-style: none;
}

.an-checklist li {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  color: var(--secondary-foreground);
  font-size: 0.78rem;
  line-height: 1.5;
}

.an-checklist li svg {
  flex: 0 0 auto;
  margin-top: 0.12rem;
  color: var(--health-good);
}

.an-source-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-top: 1rem;
  padding-top: 0.9rem;
  border-top: 1px solid color-mix(in oklab, var(--border) 45%, transparent);
}

.an-source-chip {
  padding: 0.12rem 0.45rem;
  border: 1px solid color-mix(in oklab, var(--border) 70%, transparent);
  border-radius: 999px;
  color: var(--muted-foreground);
  font-family: var(--font-mono);
  font-size: 0.6rem;
}

.an-alert {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  padding: 0.65rem 0.8rem;
  border: 1px solid color-mix(in oklab, var(--health-bad) 35%, transparent);
  border-radius: 10px;
  background: color-mix(in oklab, var(--health-bad) 6%, transparent);
  color: var(--health-bad);
  font-size: 0.78rem;
  line-height: 1.5;
}

.an-alert svg {
  flex: 0 0 auto;
  margin-top: 0.1rem;
}

.an-spinner {
  width: 0.85rem;
  height: 0.85rem;
  border: 2px solid color-mix(in oklab, currentColor 30%, transparent);
  border-top-color: currentColor;
  border-radius: 50%;
  animation: an-spin 0.7s linear infinite;
}

@keyframes an-spin {
  to {
    transform: rotate(360deg);
  }
}

/* Dashboard shell */

.an-shell {
  display: grid;
  grid-template-columns: 14.5rem minmax(0, 1fr);
  gap: 1rem;
  align-items: start;
}

.an-rail {
  position: sticky;
  top: 4.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  align-self: start;
  padding: 0.85rem;
  border: 1px solid color-mix(in oklab, var(--border) 68%, transparent);
  border-radius: 14px;
  background: color-mix(in oklab, var(--card) 78%, transparent);
  backdrop-filter: blur(10px);
}

.an-project {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  padding: 0.7rem 0.75rem;
  border: 1px solid color-mix(in oklab, var(--border) 55%, transparent);
  border-radius: 10px;
  background: color-mix(in oklab, var(--secondary) 35%, transparent);
}

.an-project-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.4rem;
  margin-bottom: 0.2rem;
}

.an-project-label {
  color: var(--muted-foreground);
  font-size: 0.64rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.an-score-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.8rem;
  height: 1.35rem;
  padding: 0 0.35rem;
  border-radius: 6px;
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 600;
}

.an-score-pill.is-good {
  background: color-mix(in oklab, var(--health-good) 14%, transparent);
  color: var(--health-good);
}

.an-score-pill.is-warn {
  background: color-mix(in oklab, var(--health-warn) 16%, transparent);
  color: var(--health-warn);
}

.an-score-pill.is-bad {
  background: color-mix(in oklab, var(--health-bad) 14%, transparent);
  color: var(--health-bad);
}

.an-project-name {
  overflow: hidden;
  color: var(--foreground);
  font-family: var(--font-mono);
  font-size: 0.84rem;
  font-weight: 600;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.an-project-meta {
  overflow: hidden;
  color: var(--muted-foreground);
  font-family: var(--font-mono);
  font-size: 0.63rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.an-nav {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
}

.an-nav-btn {
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.55rem;
  width: 100%;
  padding: 0.5rem 0.55rem;
  border: 1px solid transparent;
  border-radius: 8px;
  background: transparent;
  color: var(--muted-foreground);
  font-size: 0.78rem;
  font-weight: 500;
  text-align: left;
  cursor: pointer;
  transition: background-color 140ms ease, color 140ms ease, border-color 140ms ease;
}

.an-nav-btn:hover {
  background: color-mix(in oklab, var(--secondary) 55%, transparent);
  color: var(--foreground);
}

.an-nav-btn.is-active {
  border-color: color-mix(in oklab, var(--primary) 20%, transparent);
  background: color-mix(in oklab, var(--primary) 10%, transparent);
  color: var(--foreground);
  font-weight: 600;
}

.an-nav-btn.is-active::before {
  content: "";
  position: absolute;
  left: -0.85rem;
  top: 20%;
  bottom: 20%;
  width: 2px;
  border-radius: 2px;
  background: var(--primary);
}

.an-nav-icon {
  display: inline-flex;
  flex: 0 0 auto;
  color: color-mix(in oklab, var(--muted-foreground) 85%, transparent);
}

.an-nav-btn.is-active .an-nav-icon {
  color: var(--primary);
}

.an-nav-label {
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.an-nav-count {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  min-width: 1.25rem;
  height: 1.1rem;
  padding: 0 0.3rem;
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 0.6rem;
}

.an-nav-count.is-neutral {
  background: color-mix(in oklab, var(--secondary) 80%, transparent);
  color: var(--muted-foreground);
}

.an-nav-count.is-warn {
  background: color-mix(in oklab, var(--health-warn) 16%, transparent);
  color: var(--health-warn);
}

.an-nav-count.is-bad {
  background: color-mix(in oklab, var(--health-bad) 14%, transparent);
  color: var(--health-bad);
}

.an-nav-count.is-info {
  background: color-mix(in oklab, var(--primary) 12%, transparent);
  color: var(--primary);
}

.an-rail-foot {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  padding-top: 0.7rem;
  border-top: 1px solid color-mix(in oklab, var(--border) 55%, transparent);
}

.an-rail-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  color: var(--muted-foreground);
  font-size: 0.64rem;
}

.an-rail-value {
  overflow: hidden;
  color: var(--foreground);
  font-family: var(--font-mono);
  text-align: right;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.an-main {
  min-width: 0;
}

.an-tab {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

/* KPIs */

.an-kpis {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.75rem;
}

.an-kpi {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  min-width: 0;
  padding: 0.9rem 0.95rem;
  border: 1px solid color-mix(in oklab, var(--border) 68%, transparent);
  border-radius: 12px;
  background: color-mix(in oklab, var(--card) 78%, transparent);
  backdrop-filter: blur(10px);
}

.an-kpi-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.an-kpi-label {
  overflow: hidden;
  color: var(--muted-foreground);
  font-size: 0.72rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.an-kpi-icon {
  display: inline-flex;
  flex: 0 0 auto;
  color: var(--muted-foreground);
}

.an-kpi-value {
  font-family: var(--font-mono);
  font-size: 1.65rem;
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: -0.03em;
}

.an-kpi-meta {
  overflow: hidden;
  color: var(--muted-foreground);
  font-size: 0.67rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.an-kpi.is-info .an-kpi-icon,
.an-kpi.is-info .an-kpi-value {
  color: var(--primary);
}

.an-kpi.is-good .an-kpi-icon,
.an-kpi.is-good .an-kpi-value {
  color: var(--health-good);
}

.an-kpi.is-warn .an-kpi-icon,
.an-kpi.is-warn .an-kpi-value {
  color: var(--health-warn);
}

.an-kpi.is-bad .an-kpi-icon,
.an-kpi.is-bad .an-kpi-value {
  color: var(--health-bad);
}

/* Overview */

.an-overview-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr);
  gap: 0.85rem;
  align-items: start;
}

.an-col {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  min-width: 0;
}

.an-suggestions {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.an-suggestion {
  display: flex;
  align-items: flex-start;
  gap: 0.55rem;
  padding: 0.55rem 0.6rem;
  border: 1px solid color-mix(in oklab, var(--border) 45%, transparent);
  border-radius: 9px;
  background: color-mix(in oklab, var(--secondary) 22%, transparent);
}

.an-priority {
  flex: 0 0 auto;
  padding: 0.1rem 0.4rem;
  border-radius: 5px;
  font-size: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.02em;
}

.an-priority.is-bad {
  background: color-mix(in oklab, var(--health-bad) 13%, transparent);
  color: var(--health-bad);
}

.an-priority.is-warn {
  background: color-mix(in oklab, var(--health-warn) 16%, transparent);
  color: var(--health-warn);
}

.an-priority.is-info {
  background: color-mix(in oklab, var(--primary) 11%, transparent);
  color: var(--primary);
}

.an-suggestion-body {
  flex: 1 1 auto;
  min-width: 0;
}

.an-row-text {
  color: var(--secondary-foreground);
  font-size: 0.76rem;
  line-height: 1.5;
  overflow-wrap: anywhere;
}

.an-muted {
  color: var(--muted-foreground) !important;
}

.an-code {
  display: inline-block;
  max-width: 100%;
  margin-top: 0.3rem;
  padding: 0.1rem 0.35rem;
  overflow: hidden;
  border-radius: 4px;
  background: color-mix(in oklab, var(--primary) 8%, transparent);
  color: color-mix(in oklab, var(--primary) 78%, var(--foreground));
  font-family: var(--font-mono);
  font-size: 0.66rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.an-mini-list {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
}

.an-mini-row {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  width: 100%;
  padding: 0.38rem 0.3rem;
  border: 0;
  border-radius: 6px;
  background: transparent;
  text-align: left;
  cursor: pointer;
  transition: background-color 140ms ease;
}

.an-mini-row:hover {
  background: color-mix(in oklab, var(--secondary) 45%, transparent);
}

.an-mini-name {
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  color: var(--foreground);
  font-family: var(--font-mono);
  font-size: 0.7rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.an-mini-version {
  flex: 0 0 auto;
  color: var(--muted-foreground);
  font-family: var(--font-mono);
  font-size: 0.62rem;
}

.an-mini-version.is-latest {
  color: var(--foreground);
}

.an-mini-arrow {
  flex: 0 0 auto;
  color: var(--muted-foreground);
}

.an-license-list {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}

.an-license-row {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.an-license-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.an-license-name {
  overflow: hidden;
  color: var(--foreground);
  font-family: var(--font-mono);
  font-size: 0.7rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.an-license-count {
  flex: 0 0 auto;
  color: var(--muted-foreground);
  font-family: var(--font-mono);
  font-size: 0.63rem;
}

.an-bar {
  height: 4px;
  overflow: hidden;
  border-radius: 999px;
  background: color-mix(in oklab, var(--secondary) 75%, transparent);
}

.an-bar-fill {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, color-mix(in oklab, var(--primary) 70%, transparent), var(--primary));
}

/* Banner */

.an-banner {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.7rem 0.8rem;
  border: 1px solid color-mix(in oklab, var(--health-bad) 32%, transparent);
  border-radius: 11px;
  background: color-mix(in oklab, var(--health-bad) 6%, transparent);
}

.an-banner > svg {
  flex: 0 0 auto;
  color: var(--health-bad);
}

.an-banner-body {
  flex: 1 1 auto;
  min-width: 0;
}

.an-banner-title {
  color: var(--health-bad);
  font-size: 0.78rem;
  font-weight: 650;
}

.an-banner-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
  margin-top: 0.3rem;
}

.an-banner-chip {
  max-width: 100%;
  overflow: hidden;
  padding: 0.08rem 0.35rem;
  border-radius: 4px;
  background: color-mix(in oklab, var(--health-bad) 9%, transparent);
  color: color-mix(in oklab, var(--health-bad) 82%, var(--foreground));
  font-family: var(--font-mono);
  font-size: 0.6rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* Dependencies */

.an-deps-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 20.5rem;
  gap: 0.85rem;
  align-items: start;
}

.an-table-card {
  padding: 0;
  overflow: hidden;
}

.an-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.55rem;
  padding: 0.75rem 0.8rem;
  border-bottom: 1px solid color-mix(in oklab, var(--border) 55%, transparent);
}

.an-search {
  display: flex;
  flex: 1 1 12rem;
  align-items: center;
  gap: 0.4rem;
  max-width: 19rem;
  height: 2rem;
  padding: 0 0.55rem;
  border: 1px solid color-mix(in oklab, var(--border) 80%, transparent);
  border-radius: 8px;
  background: color-mix(in oklab, var(--secondary) 30%, transparent);
  color: var(--muted-foreground);
  transition: border-color 140ms ease, box-shadow 140ms ease;
}

.an-search:focus-within {
  border-color: color-mix(in oklab, var(--primary) 45%, transparent);
  box-shadow: 0 0 0 3px color-mix(in oklab, var(--primary) 11%, transparent);
}

.an-search svg {
  flex: 0 0 auto;
}

.an-search-input {
  flex: 1 1 auto;
  min-width: 0;
  border: 0;
  outline: none;
  background: transparent;
  color: var(--foreground);
  font-family: inherit;
  font-size: 0.76rem;
}

.an-search-input::placeholder {
  color: color-mix(in oklab, var(--muted-foreground) 70%, transparent);
}

.an-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
}

.an-chip-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.28rem 0.5rem;
  border: 1px solid transparent;
  border-radius: 7px;
  background: color-mix(in oklab, var(--secondary) 45%, transparent);
  color: var(--muted-foreground);
  font-size: 0.66rem;
  font-weight: 500;
  cursor: pointer;
  transition: background-color 140ms ease, color 140ms ease, border-color 140ms ease;
}

.an-chip-btn:hover {
  background: color-mix(in oklab, var(--secondary) 75%, transparent);
  color: var(--foreground);
}

.an-chip-btn.is-active {
  border-color: color-mix(in oklab, var(--primary) 25%, transparent);
  background: color-mix(in oklab, var(--primary) 12%, transparent);
  color: var(--primary);
}

.an-chip-count {
  font-family: var(--font-mono);
  font-size: 0.58rem;
  opacity: 0.75;
}

.an-table-wrap {
  max-height: 33rem;
  overflow: auto;
}

.an-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  text-align: left;
}

.an-table thead th {
  position: sticky;
  top: 0;
  z-index: 1;
  padding: 0.5rem 0.55rem;
  border-bottom: 1px solid color-mix(in oklab, var(--border) 65%, transparent);
  background: color-mix(in oklab, var(--card) 96%, transparent);
  color: var(--muted-foreground);
  font-size: 0.6rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  white-space: nowrap;
}

.an-row {
  cursor: pointer;
  transition: background-color 120ms ease;
}

.an-row td {
  padding: 0.5rem 0.55rem;
  border-bottom: 1px solid color-mix(in oklab, var(--border) 32%, transparent);
  vertical-align: middle;
}

.an-row:last-child td {
  border-bottom: 0;
}

.an-row:hover {
  background: color-mix(in oklab, var(--secondary) 40%, transparent);
}

.an-row.is-selected {
  background: color-mix(in oklab, var(--primary) 8%, transparent);
  box-shadow: inset 2px 0 0 var(--primary);
}

.an-pkg-name {
  overflow: hidden;
  color: var(--foreground);
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 600;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.an-pkg-meta {
  overflow: hidden;
  color: var(--muted-foreground);
  font-size: 0.58rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.an-mono {
  font-family: var(--font-mono);
  font-size: 0.67rem;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.an-mono.is-good {
  color: var(--health-good);
}

.an-mono.is-warn {
  color: var(--health-warn);
}

.an-mono.is-bad {
  color: var(--health-bad);
}

.an-status {
  display: inline-flex;
  align-items: center;
  gap: 0.2rem;
  max-width: 100%;
  padding: 0.08rem 0.38rem;
  border-radius: 5px;
  font-size: 0.58rem;
  font-weight: 600;
  white-space: nowrap;
}

.an-status.is-good {
  background: color-mix(in oklab, var(--health-good) 13%, transparent);
  color: var(--health-good);
}

.an-status.is-warn {
  background: color-mix(in oklab, var(--health-warn) 15%, transparent);
  color: var(--health-warn);
}

.an-status.is-bad {
  background: color-mix(in oklab, var(--health-bad) 12%, transparent);
  color: var(--health-bad);
}

.an-status.is-info {
  background: color-mix(in oklab, var(--primary) 11%, transparent);
  color: var(--primary);
}

.an-table-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.4rem;
  padding: 0.5rem 0.8rem;
  border-top: 1px solid color-mix(in oklab, var(--border) 55%, transparent);
  color: var(--muted-foreground);
  font-size: 0.64rem;
}

.an-table-hint {
  opacity: 0.75;
}

.an-empty {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  padding: 1.2rem 0.8rem;
  color: var(--muted-foreground);
  font-size: 0.74rem;
  text-align: center;
}

.an-empty svg {
  flex: 0 0 auto;
  color: var(--health-good);
}

/* Inspector */

.an-inspector {
  position: sticky;
  top: 4.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
  max-height: calc(100vh - 5.5rem);
  padding: 1rem;
  overflow-y: auto;
  border: 1px solid color-mix(in oklab, var(--border) 68%, transparent);
  border-radius: 14px;
  background: color-mix(in oklab, var(--card) 80%, transparent);
  backdrop-filter: blur(10px);
}

.an-inspector-empty {
  align-items: stretch;
  justify-content: center;
  min-height: 12rem;
}

.an-inspector-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.5rem;
  padding-bottom: 0.6rem;
  border-bottom: 1px solid color-mix(in oklab, var(--border) 55%, transparent);
}

.an-inspector-title {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.45rem;
  min-width: 0;
}

.an-inspector-title h2 {
  overflow: hidden;
  font-family: var(--font-mono);
  font-size: 0.94rem;
  font-weight: 650;
  letter-spacing: -0.02em;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.an-inspector-desc {
  color: var(--muted-foreground);
  font-size: 0.72rem;
  line-height: 1.55;
}

.an-metrics {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.3rem;
  padding: 0.55rem;
  border: 1px solid color-mix(in oklab, var(--border) 55%, transparent);
  border-radius: 9px;
  background: color-mix(in oklab, var(--secondary) 32%, transparent);
}

.an-metric {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  min-width: 0;
}

.an-metric-label {
  color: var(--muted-foreground);
  font-size: 0.58rem;
}

.an-metric-value {
  overflow: hidden;
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 600;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.an-metric-value.is-good {
  color: var(--health-good);
}

.an-detail-rows {
  display: flex;
  flex-direction: column;
}

.an-detail-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.6rem;
  padding: 0.34rem 0;
  border-bottom: 1px solid color-mix(in oklab, var(--border) 32%, transparent);
}

.an-detail-row:last-child {
  border-bottom: 0;
}

.an-detail-label {
  flex: 0 0 auto;
  color: var(--muted-foreground);
  font-size: 0.67rem;
}

.an-detail-value {
  min-width: 0;
  overflow: hidden;
  color: var(--foreground);
  font-family: var(--font-mono);
  font-size: 0.66rem;
  text-align: right;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.an-detail-value.is-highlight {
  color: var(--primary);
}

.an-inspector-block {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}

.an-block-label {
  color: var(--muted-foreground);
  font-size: 0.62rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.an-diff {
  padding: 0.5rem 0.6rem;
  border: 1px solid color-mix(in oklab, var(--border) 55%, transparent);
  border-radius: 8px;
  background: color-mix(in oklab, var(--secondary) 28%, transparent);
  font-family: var(--font-mono);
  font-size: 0.66rem;
  line-height: 1.6;
  overflow-wrap: anywhere;
}

.an-diff .is-old {
  color: var(--health-bad);
}

.an-diff .is-new {
  color: var(--health-good);
}

.an-risk-list {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.an-risk {
  display: flex;
  align-items: flex-start;
  gap: 0.4rem;
  padding: 0.45rem 0.5rem;
  border: 1px solid color-mix(in oklab, var(--border) 45%, transparent);
  border-radius: 8px;
  background: color-mix(in oklab, var(--secondary) 22%, transparent);
}

.an-risk-dot {
  flex: 0 0 auto;
  width: 0.4rem;
  height: 0.4rem;
  margin-top: 0.28rem;
  border-radius: 50%;
  background: var(--muted-foreground);
}

.an-risk.is-bad .an-risk-dot {
  background: var(--health-bad);
}

.an-risk.is-warn .an-risk-dot {
  background: var(--health-warn);
}

.an-risk.is-info .an-risk-dot {
  background: var(--primary);
}

.an-risk-body {
  flex: 1 1 auto;
  min-width: 0;
}

.an-risk-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem;
  margin-bottom: 0.1rem;
}

.an-severity {
  font-size: 0.56rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  opacity: 0.8;
}

.an-risk.is-bad .an-severity {
  color: var(--health-bad);
}

.an-risk.is-warn .an-severity {
  color: var(--health-warn);
}

.an-risk.is-info .an-severity {
  color: var(--primary);
}

.an-inspector-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  padding-top: 0.2rem;
}

.an-copy {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.2rem 0.45rem;
  border: 1px solid color-mix(in oklab, var(--primary) 22%, transparent);
  border-radius: 6px;
  background: color-mix(in oklab, var(--primary) 7%, transparent);
  color: var(--primary);
  font-size: 0.64rem;
  font-weight: 500;
  cursor: pointer;
  transition: background-color 140ms ease;
}

.an-copy:hover {
  background: color-mix(in oklab, var(--primary) 12%, transparent);
}

.an-pkg-link {
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--foreground);
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 600;
  text-decoration: none;
  overflow-wrap: anywhere;
  cursor: pointer;
  transition: color 140ms ease;
}

.an-pkg-link:hover {
  color: var(--primary);
}

/* Resolution */

.an-resolution {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.an-resolution.is-good {
  border-color: color-mix(in oklab, var(--health-good) 32%, transparent);
  background: color-mix(in oklab, var(--health-good) 4%, transparent);
}

.an-resolution.is-bad {
  border-color: color-mix(in oklab, var(--health-bad) 32%, transparent);
  background: color-mix(in oklab, var(--health-bad) 4%, transparent);
}

.an-resolution.is-warn {
  border-color: color-mix(in oklab, var(--health-warn) 32%, transparent);
  background: color-mix(in oklab, var(--health-warn) 4%, transparent);
}

.an-resolution-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.75rem;
}

.an-solver-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
  margin-top: 0.4rem;
}

.an-solver-badge {
  padding: 0.08rem 0.42rem;
  border: 1px solid color-mix(in oklab, var(--border) 65%, transparent);
  border-radius: 999px;
  color: var(--muted-foreground);
  font-family: var(--font-mono);
  font-size: 0.58rem;
}

.an-solve-counts {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.an-solve-count {
  display: inline-flex;
  align-items: baseline;
  gap: 0.3rem;
  padding: 0.2rem 0.5rem;
  border-radius: 7px;
  background: color-mix(in oklab, var(--secondary) 45%, transparent);
}

.an-solve-value {
  font-family: var(--font-mono);
  font-size: 0.82rem;
  font-weight: 600;
}

.an-solve-label {
  color: var(--muted-foreground);
  font-size: 0.6rem;
}

.an-conflict-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
}

.an-conflict-chip {
  max-width: 100%;
  padding: 0.12rem 0.4rem;
  overflow-wrap: anywhere;
  border: 1px solid color-mix(in oklab, var(--health-bad) 25%, transparent);
  border-radius: 5px;
  background: color-mix(in oklab, var(--health-bad) 6%, transparent);
  color: var(--health-bad);
  font-family: var(--font-mono);
  font-size: 0.6rem;
}

.an-log,
.an-pubspec-preview {
  max-height: 15rem;
  margin: 0;
  padding: 0.65rem 0.75rem;
  overflow: auto;
  border: 1px solid color-mix(in oklab, var(--border) 55%, transparent);
  border-radius: 8px;
  background: color-mix(in oklab, var(--secondary) 30%, transparent);
  color: var(--secondary-foreground);
  font-family: var(--font-mono);
  font-size: 0.66rem;
  line-height: 1.55;
  white-space: pre-wrap;
}

.an-pubspec-preview {
  max-height: 20rem;
}

.an-fixes {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.an-fix {
  padding: 0.5rem 0.55rem;
  border: 1px solid color-mix(in oklab, var(--border) 45%, transparent);
  border-radius: 8px;
  background: color-mix(in oklab, var(--secondary) 22%, transparent);
}

.an-fix-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.5rem;
}

.an-skipped {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.35rem;
}

.an-skip-chip {
  padding: 0.1rem 0.35rem;
  border-radius: 4px;
  background: color-mix(in oklab, var(--secondary) 55%, transparent);
  color: var(--muted-foreground);
  font-family: var(--font-mono);
  font-size: 0.58rem;
}

.an-selected-list {
  max-height: 20rem;
  overflow-y: auto;
}

.an-selected-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.32rem 0.1rem;
  border-bottom: 1px solid color-mix(in oklab, var(--border) 28%, transparent);
}

.an-selected-row:last-child {
  border-bottom: 0;
}

.an-selected-name {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  min-width: 0;
}

.an-kind {
  padding: 0.02rem 0.28rem;
  border-radius: 3px;
  background: color-mix(in oklab, var(--secondary) 75%, transparent);
  color: var(--muted-foreground);
  font-size: 0.5rem;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

.an-kind.is-info {
  background: color-mix(in oklab, var(--primary) 10%, transparent);
  color: var(--primary);
}

.an-kind.is-warn {
  background: color-mix(in oklab, var(--health-warn) 12%, transparent);
  color: var(--health-warn);
}

.an-fix-result.is-good {
  border-color: color-mix(in oklab, var(--health-good) 32%, transparent);
}

.an-fix-result.is-warn {
  border-color: color-mix(in oklab, var(--health-warn) 32%, transparent);
}

.an-applied-list {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  margin-bottom: 0.55rem;
}

.an-applied-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.2rem 0;
  border-bottom: 1px solid color-mix(in oklab, var(--border) 28%, transparent);
  font-size: 0.66rem;
}

.an-applied-row:last-child {
  border-bottom: 0;
}

/* Audit */

.an-audit-strip {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 0.55rem;
}

.an-audit-stat {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
  padding: 0.6rem 0.65rem;
  border: 1px solid color-mix(in oklab, var(--border) 55%, transparent);
  border-radius: 10px;
  background: color-mix(in oklab, var(--card) 72%, transparent);
}

.an-audit-value {
  font-family: var(--font-mono);
  font-size: 1.1rem;
  font-weight: 600;
  line-height: 1.15;
}

.an-audit-label {
  overflow: hidden;
  color: var(--muted-foreground);
  font-size: 0.6rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.an-audit-stat.is-bad .an-audit-value {
  color: var(--health-bad);
}

.an-audit-stat.is-warn .an-audit-value {
  color: var(--health-warn);
}

.an-audit-stat.is-info .an-audit-value {
  color: var(--primary);
}

.an-audit-stat.is-good .an-audit-value {
  color: var(--health-good);
}

.an-audit-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr);
  gap: 0.85rem;
  align-items: start;
}

.an-deprecated-list,
.an-alt-groups {
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}

.an-deprecated-row {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.5rem 0.55rem;
  border: 1px solid color-mix(in oklab, var(--health-bad) 20%, transparent);
  border-radius: 8px;
  background: color-mix(in oklab, var(--health-bad) 4%, transparent);
}

.an-deprecated-main {
  min-width: 0;
}

.an-alt-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
  margin-top: 0.35rem;
}

.an-alt-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.08rem 0.35rem;
  border: 1px solid color-mix(in oklab, var(--primary) 20%, transparent);
  border-radius: 4px;
  background: color-mix(in oklab, var(--primary) 6%, transparent);
  color: var(--primary);
  font-family: var(--font-mono);
  font-size: 0.58rem;
  text-decoration: none;
  cursor: pointer;
}

.an-alt-chip-version {
  opacity: 0.65;
}

.an-alt-group {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  padding-bottom: 0.55rem;
  border-bottom: 1px solid color-mix(in oklab, var(--border) 40%, transparent);
}

.an-alt-group:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}

.an-alt-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.an-alt-list {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}

.an-alt-card {
  padding: 0.45rem 0.5rem;
  border: 1px solid color-mix(in oklab, var(--border) 42%, transparent);
  border-radius: 7px;
  background: color-mix(in oklab, var(--secondary) 22%, transparent);
}

.an-alt-card-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
}

.an-alt-desc {
  margin-top: 0.2rem;
  color: var(--muted-foreground);
  font-size: 0.66rem;
  line-height: 1.45;
}

.an-alt-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.3rem;
  margin-top: 0.2rem;
  color: var(--muted-foreground);
  font-size: 0.58rem;
}

.an-dot {
  width: 2px;
  height: 2px;
  border-radius: 50%;
  background: currentColor;
  opacity: 0.6;
}

/* Responsive */

@media (max-width: 1180px) {
  .an-shell {
    grid-template-columns: 12.5rem minmax(0, 1fr);
  }

  .an-deps-grid {
    grid-template-columns: minmax(0, 1fr) 18rem;
  }
}

@media (max-width: 1024px) {
  .an-kpis {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .an-overview-grid,
  .an-audit-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .an-deps-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .an-inspector {
    position: static;
    max-height: none;
  }
}

@media (max-width: 880px) {
  .an-shell {
    grid-template-columns: minmax(0, 1fr);
  }

  .an-rail {
    position: static;
  }

  .an-nav {
    flex-direction: row;
    flex-wrap: wrap;
  }

  .an-nav-btn {
    flex: 1 1 8rem;
  }

  .an-nav-btn.is-active::before {
    left: 10%;
    right: 10%;
    top: auto;
    bottom: -0.05rem;
    width: auto;
    height: 2px;
  }

  .an-rail-foot {
    flex-direction: row;
    justify-content: space-between;
    gap: 0.75rem;
  }

  .an-intro-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .an-audit-strip {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .an-page {
    padding: 1.15rem 0.75rem 3rem;
  }

  .an-head {
    align-items: flex-start;
  }

  .an-head-actions {
    justify-content: flex-start;
  }

  .an-kpis {
    grid-template-columns: minmax(0, 1fr);
  }

  .an-audit-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .an-toolbar {
    align-items: stretch;
  }

  .an-search {
    max-width: none;
  }

  .an-table {
    min-width: 36rem;
  }

  .an-table-wrap {
    max-height: 26rem;
  }

  .an-table-foot {
    font-size: 0.6rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .an-spinner {
    animation-duration: 2s;
  }

  .an-btn,
  .an-nav-btn,
  .an-row,
  .an-chip-btn,
  .an-icon-btn {
    transition: none;
  }
}

/* ─── Embedded pubspec analysis (assistant block) ─── */

.an-dashboard {
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
  margin-top: 0.35rem;
}

.an-topbar {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.65rem;
  padding: 0.7rem 0.8rem;
  border: 1px solid color-mix(in oklab, var(--border) 62%, transparent);
  border-radius: 12px;
  background: color-mix(in oklab, var(--card) 66%, transparent);
}

.an-topbar-main {
  flex: 1 1 15rem;
  min-width: 0;
}

.an-topbar-title {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  min-width: 0;
}

.an-topbar-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  color: color-mix(in oklab, var(--primary) 80%, var(--foreground));
  font-size: 0.6rem;
  font-weight: 650;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.an-topbar-name {
  overflow: hidden;
  font-family: var(--font-mono);
  font-size: 1rem;
  font-weight: 650;
  letter-spacing: -0.02em;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.an-topbar-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.3rem;
  margin-top: 0.35rem;
}

.an-meta-chip {
  padding: 0.08rem 0.42rem;
  border: 1px solid color-mix(in oklab, var(--border) 55%, transparent);
  border-radius: 999px;
  background: color-mix(in oklab, var(--secondary) 35%, transparent);
  color: var(--muted-foreground);
  font-family: var(--font-mono);
  font-size: 0.57rem;
  white-space: nowrap;
}

.an-topbar-side {
  display: flex;
  align-items: center;
  align-self: center;
  gap: 0.5rem;
}

.an-health-score {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-width: 3.1rem;
  gap: 0.05rem;
  padding: 0.2rem 0.55rem;
  border-radius: 8px;
  background: color-mix(in oklab, var(--secondary) 35%, transparent);
  text-align: center;
}

.an-health-score-value {
  font-family: var(--font-mono);
  font-size: 1.2rem;
  font-weight: 650;
  line-height: 1.05;
}

.an-health-score-label {
  color: var(--muted-foreground);
  font-size: 0.54rem;
  white-space: nowrap;
}

.an-health-score.is-good .an-health-score-value {
  color: var(--health-good);
}

.an-health-score.is-warn .an-health-score-value {
  color: var(--health-warn);
}

.an-health-score.is-bad .an-health-score-value {
  color: var(--health-bad);
}

.an-export-btn {
  flex: 0 0 auto;
}

.an-tools {
  display: flex;
  gap: 0.3rem;
  overflow-x: auto;
  padding-bottom: 0.1rem;
  scrollbar-width: thin;
}

.an-tool {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 0.35rem;
  padding: 0.42rem 0.6rem;
  border: 1px solid transparent;
  border-radius: 8px;
  background: color-mix(in oklab, var(--secondary) 30%, transparent);
  color: var(--muted-foreground);
  font-size: 0.71rem;
  font-weight: 500;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color 140ms ease, color 140ms ease, border-color 140ms ease;
}

.an-tool:hover {
  background: color-mix(in oklab, var(--secondary) 60%, transparent);
  color: var(--foreground);
}

.an-tool.is-active {
  border-color: color-mix(in oklab, var(--primary) 26%, transparent);
  background: color-mix(in oklab, var(--primary) 11%, transparent);
  color: var(--primary);
  font-weight: 600;
}

.an-tool-icon {
  display: inline-flex;
  flex: 0 0 auto;
}

.an-tool-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.15rem;
  height: 1rem;
  padding: 0 0.28rem;
  border-radius: 999px;
  font-family: var(--font-mono);
  font-size: 0.56rem;
  font-weight: 500;
}

.an-tool-count.is-neutral {
  background: color-mix(in oklab, var(--secondary) 80%, transparent);
  color: var(--muted-foreground);
}

.an-tool-count.is-warn {
  background: color-mix(in oklab, var(--health-warn) 16%, transparent);
  color: var(--health-warn);
}

.an-tool-count.is-bad {
  background: color-mix(in oklab, var(--health-bad) 14%, transparent);
  color: var(--health-bad);
}

.an-tool-body {
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
}

.an-dashboard .an-kpis {
  grid-template-columns: repeat(auto-fit, minmax(8.5rem, 1fr));
}

.an-dashboard .an-overview-grid,
.an-dashboard .an-audit-grid {
  grid-template-columns: minmax(0, 1fr);
}

.an-dashboard .an-audit-strip {
  grid-template-columns: repeat(auto-fit, minmax(5.2rem, 1fr));
}

.an-dashboard .an-table-wrap {
  max-height: 24rem;
}

.an-dashboard .an-table {
  min-width: 31rem;
}

.an-inspector-inline {
  position: static;
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
  max-height: none;
  padding: 0.9rem;
  overflow: visible;
}

.an-inspector-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
  gap: 0.65rem;
  align-items: start;
}

.an-detail-hint {
  padding: 0;
}

@media (max-width: 720px) {
  .an-topbar-name {
    font-size: 0.92rem;
  }

  .an-dashboard .an-table {
    min-width: 34rem;
  }
}

/* ─── Dependency topology ─────────────────────────────────────────────── */

.an-view-switch {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  margin-left: auto;
  padding: 2px;
  border: 1px solid color-mix(in oklab, var(--border) 65%, transparent);
  border-radius: 9px;
  background: color-mix(in oklab, var(--secondary) 35%, transparent);
}

.an-view-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.28rem;
  padding: 0.3rem 0.5rem;
  border: 0;
  border-radius: 7px;
  background: transparent;
  color: var(--muted-foreground);
  font-size: 0.66rem;
  font-weight: 500;
  cursor: pointer;
  transition: background-color 140ms ease, color 140ms ease;
}

.an-view-btn:hover {
  color: var(--foreground);
}

.an-view-btn.is-active {
  background: color-mix(in oklab, var(--primary) 13%, transparent);
  color: var(--primary);
}

.an-graph {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.an-graph-notice {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.55rem 0.8rem;
  border-bottom: 1px solid color-mix(in oklab, #f59e0b 24%, transparent);
  background: color-mix(in oklab, #f59e0b 8%, transparent);
  color: color-mix(in oklab, var(--foreground) 82%, transparent);
  font-size: 0.69rem;
}

.an-graph-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  padding: 0.55rem 0.8rem;
  border-bottom: 1px solid color-mix(in oklab, var(--border) 55%, transparent);
}

.an-graph-depth {
  display: flex;
  align-items: center;
  gap: 0.22rem;
}

.an-graph-depth-label {
  margin-right: 0.15rem;
  color: var(--muted-foreground);
  font-size: 0.63rem;
}

.an-graph-bar-spacer {
  flex: 1 1 auto;
}

.an-graph-hint {
  color: color-mix(in oklab, var(--muted-foreground) 78%, transparent);
  font-size: 0.62rem;
}

.an-graph-zoom {
  display: flex;
  align-items: center;
  gap: 0.22rem;
}

.an-graph-fit {
  padding: 0.28rem 0.55rem;
}

.an-graph-canvas {
  position: relative;
  height: 34rem;
  overflow: hidden;
  background-color: color-mix(in oklab, var(--secondary) 12%, transparent);
  background-image: radial-gradient(
    color-mix(in oklab, var(--border) 55%, transparent) 1px,
    transparent 1px
  );
  background-size: 18px 18px;
  touch-action: none;
  user-select: none;
}

.an-graph-tip {
  position: absolute;
  z-index: 5;
  max-width: 15rem;
  padding: 0.3rem 0.45rem;
  border: 1px solid color-mix(in oklab, var(--border) 70%, transparent);
  border-radius: 6px;
  background: color-mix(in oklab, var(--card) 96%, transparent);
  color: var(--foreground);
  font-family: var(--font-mono);
  font-size: 0.62rem;
  line-height: 1.35;
  pointer-events: none;
  box-shadow: 0 4px 12px color-mix(in oklab, #000 12%, transparent);
}

.an-graph-foot {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  padding: 0.55rem 0.8rem;
  border-top: 1px solid color-mix(in oklab, var(--border) 55%, transparent);
  color: var(--muted-foreground);
  font-size: 0.63rem;
}

.an-graph-legend {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.55rem;
}

.an-graph-legend-item {
  display: inline-flex;
  align-items: center;
  gap: 0.28rem;
}

.an-graph-dot {
  width: 0.42rem;
  height: 0.42rem;
  border-radius: 999px;
  background: var(--muted-foreground);
}

.an-graph-dot.is-direct {
  background: var(--primary);
}

.an-graph-dot.is-dev {
  background: #8b5cf6;
}

.an-graph-dot.is-transitive {
  background: color-mix(in oklab, var(--muted-foreground) 65%, transparent);
}

.an-graph-dot.is-external {
  background: #64748b;
}

.an-graph-focus {
  display: flex;
  flex-direction: column;
  gap: 0.38rem;
  padding: 0.7rem 0.8rem;
  border-top: 1px solid color-mix(in oklab, var(--border) 55%, transparent);
  background: color-mix(in oklab, var(--secondary) 28%, transparent);
}

.an-graph-focus-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.4rem;
}

.an-graph-focus-name {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  font-weight: 600;
}

.an-graph-role,
.an-graph-focus-version {
  padding: 0.1rem 0.4rem;
  border-radius: 999px;
  background: color-mix(in oklab, var(--secondary) 75%, transparent);
  color: var(--muted-foreground);
  font-size: 0.58rem;
}

.an-graph-focus-meta {
  color: var(--muted-foreground);
  font-size: 0.67rem;
}

.an-graph-focus-link {
  display: inline-flex;
  align-items: center;
  gap: 0.28rem;
  color: var(--primary);
  font-size: 0.67rem;
  text-decoration: none;
}

.an-graph-focus-link:hover {
  text-decoration: underline;
}

@media (max-width: 720px) {
  .an-graph-hint {
    display: none;
  }

  .an-graph-canvas {
    height: 22rem;
  }

  .an-view-switch {
    margin-left: 0;
  }
}

.an-graph-empty {
  padding: 2rem 1rem;
  color: var(--muted-foreground);
  font-size: 0.72rem;
  text-align: center;
}
