/* RepoTempo · research dashboard · Impeccable product register
   Quiet surfaces, meaningful charts, familiar navigation, Chinese-first reading. */
*,
:before,
:after {
  box-sizing: border-box;
}
html {
  min-width: 0;
  overflow-x: clip;
  font-family: var(--font-body);
  font-size: 14px;
  line-height: 1.55;
  color: var(--ink);
  background: var(--bg);
  scroll-padding-top: 88px;
}
body {
  margin: 0;
  overflow-x: clip;
}
a {
  color: var(--accent-ink);
  text-decoration: none;
}
a:hover {
  color: var(--accent-hover);
}
button,
input,
select,
textarea {
  font: inherit;
  color: inherit;
}
button,
select,
summary {
  cursor: pointer;
}
button,
input,
select,
textarea {
  border-radius: var(--radius-control);
}
button:disabled,
input:disabled,
select:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  background: var(--surface-strong);
}
a,
button,
input,
select,
summary {
  touch-action: manipulation;
}
:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
}
a:active,
summary:active {
  opacity: 0.8;
}
button:active {
  transform: translateY(1px);
}
h1,
h2,
h3,
h4 {
  margin: 0;
  color: var(--ink-strong);
  min-width: 0;
  overflow-wrap: anywhere;
  text-wrap: balance;
}
h1 {
  font-size: 28px;
  line-height: 1.25;
  font-weight: 720;
  letter-spacing: -0.025em;
}
h2 {
  font-size: 17px;
  line-height: 1.4;
  font-weight: 680;
  letter-spacing: -0.015em;
}
h3 {
  font-size: 15px;
  font-weight: 650;
}
p {
  margin: 0;
  text-wrap: pretty;
  overflow-wrap: anywhere;
}
svg {
  display: inline-block;
  vertical-align: middle;
}
a > svg,
button > svg,
.text-link > svg {
  width: 17px;
  height: 17px;
  flex-shrink: 0;
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
.skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 60;
  background: var(--ink-strong);
  color: var(--surface);
  padding: 12px 16px;
  transform: translateY(-180%);
}
.skip-link:focus {
  transform: translateY(0);
}
.app-sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  width: 216px;
  padding: 32px 18px 20px;
  display: flex;
  flex-direction: column;
  background: var(--sidebar-bg);
  color: var(--sidebar-text);
  z-index: 30;
}
.brand {
  display: flex;
  gap: 12px;
  align-items: center;
  color: var(--sidebar-strong);
  font-size: 17px;
  line-height: 1.1;
  font-weight: 740;
  letter-spacing: -0.02em;
  margin-bottom: 48px;
}
.brand:hover {
  color: var(--sidebar-strong);
}
.brand-mark {
  display: grid;
  place-items: center;
  width: 35px;
  height: 35px;
  color: var(--sidebar-accent);
}
.brand-mark svg {
  width: 34px;
  height: 34px;
}
.brand-light {
  font-weight: 450;
}
.brand small {
  display: block;
  font-size: 10px;
  line-height: 1.35;
  font-weight: 400;
  letter-spacing: 0.03em;
  color: var(--sidebar-text);
  margin-top: 8px;
}
.sidebar-label {
  font-size: 10px;
  font-weight: 650;
  letter-spacing: 0.08em;
  color: var(--sidebar-muted);
  padding: 0 12px;
  margin-bottom: 12px;
}
.primary-nav {
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.nav-link {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 44px;
  padding: 10px 12px;
  border-radius: 7px;
  color: var(--sidebar-text);
  font-size: 13px;
  line-height: 1;
  font-weight: 500;
  white-space: nowrap;
}
.nav-link svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}
.nav-link:hover {
  background: var(--sidebar-hover);
  color: var(--sidebar-strong);
}
.nav-link.is-active {
  background: var(--sidebar-selected);
  color: var(--sidebar-accent);
  font-weight: 650;
}
.sidebar-bottom {
  margin-top: auto;
  padding-top: 32px;
}
.sidebar-bottom p {
  font-size: 10px;
  color: var(--sidebar-muted);
  padding: 20px 12px 8px;
}
.sidebar-source {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 12px;
  color: var(--sidebar-text);
  font-size: 11px;
}
.sidebar-source:hover {
  color: var(--sidebar-strong);
}
.app-main {
  margin-left: 216px;
  min-width: 0;
}
.app-header {
  height: 64px;
  padding: 0 36px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  border-bottom: var(--rule);
  background: var(--surface);
}
.header-context {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 12px;
  color: var(--muted);
  min-width: 0;
}
.header-right {
  display: flex;
  align-items: center;
  gap: 8px;
}
.mobile-history {
  display: none;
  color: var(--muted);
  min-width: 32px;
  min-height: 32px;
  align-items: center;
  justify-content: center;
}
@media (max-width: 800px) {
  .mobile-history {
    display: inline-flex;
  }
}
.header-context > span:last-child {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 440px;
  color: var(--ink);
}
.status-dot {
  width: 6px;
  height: 6px;
  border-radius: 100%;
  background: var(--accent);
  flex-shrink: 0;
}
.header-slash {
  margin: 0 4px;
  color: var(--faint);
}
.language-switch {
  display: flex;
  gap: 4px;
  flex-shrink: 0;
}
.language-switch a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  min-height: 32px;
  font-size: 11px;
  border-radius: 5px;
  color: var(--muted);
}
.language-switch a[aria-current] {
  background: var(--surface-strong);
  color: var(--ink-strong);
  font-weight: 650;
}
.page-shell {
  width: min(100%, 1580px);
  min-width: 0;
  margin: auto;
  padding: 36px 36px 48px;
  min-height: calc(100vh - 130px);
}
.page-heading {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 24px;
  margin-bottom: 28px;
}
.page-heading-copy {
  min-width: 0;
}
.page-heading-copy > p {
  margin-top: 10px;
  color: var(--muted);
  font-size: 13px;
  max-width: 75ch;
}
.page-heading-tools {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-shrink: 0;
}
.as-of {
  font-size: 11px;
  color: var(--muted);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.button {
  display: inline-flex;
  gap: 7px;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  min-width: 0;
  border: 1px solid transparent;
  border-radius: 6px;
  padding: 8px 14px;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.2;
  text-decoration: none;
  white-space: nowrap;
  transition:
    background-color 140ms var(--ease-out),
    color 140ms var(--ease-out);
}
.button-primary {
  background: var(--accent);
  color: var(--color-on-accent);
  border-color: var(--accent);
}
.button-primary:hover {
  background: var(--accent-hover);
  border-color: var(--accent-hover);
  color: var(--color-on-accent);
}
.button-secondary {
  background: var(--surface);
  border-color: var(--border-strong);
  color: var(--ink);
}
.button-secondary:hover {
  background: var(--surface-strong);
  color: var(--ink-strong);
}
.text-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
}
.notice {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px 16px;
  margin: 0 0 24px;
  border: 1px solid var(--color-warning-rule);
  border-radius: 7px;
  background: var(--warning-soft);
  color: var(--ink);
  font-size: 12px;
}
.notice > svg {
  width: 17px;
  height: 17px;
  flex-shrink: 0;
  margin-top: 2px;
  color: var(--warning);
}
.notice p {
  max-width: 100ch;
}
.notice a {
  text-decoration: underline;
}
.notice-symbol {
  font-weight: 750;
}
.dashboard-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 20px;
}
.period-switch {
  display: inline-flex;
  align-items: center;
  gap: 3px;
  padding: 4px;
  background: var(--surface-strong);
  border-radius: 7px;
}
.period-option {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 30px;
  padding: 5px 14px;
  border-radius: 4px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 500;
  white-space: nowrap;
}
.period-option:hover {
  background: var(--surface);
  color: var(--ink);
}
.period-option.is-active {
  background: var(--surface);
  color: var(--ink-strong);
  font-weight: 650;
  box-shadow: 0 1px 3px var(--color-shadow);
}
.date-form {
  display: flex;
  align-items: center;
  gap: 8px;
}
input:not([type="checkbox"]):not([type="hidden"]),
select,
textarea {
  background: var(--surface);
  border: 1px solid var(--border-strong);
  min-height: 38px;
  padding: 8px 12px;
  max-width: 100%;
}
input::placeholder,
textarea::placeholder {
  color: var(--faint);
  opacity: 1;
}
input:hover,
select:hover,
textarea:hover {
  border-color: var(--muted);
}
input:focus,
select:focus,
textarea:focus {
  border-color: var(--accent);
}
input[type="checkbox"] {
  accent-color: var(--accent);
  width: 16px;
  height: 16px;
}
.date-form input {
  font-size: 12px;
}
.category-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-bottom: 28px;
}
.category-tab {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 5px 11px;
  border-radius: 5px;
  border: 1px solid transparent;
  color: var(--muted);
  font-size: 11px;
  white-space: nowrap;
}
.category-tab:hover {
  background: var(--surface-strong);
  color: var(--ink);
}
.category-tab.is-active {
  background: var(--accent-soft);
  color: var(--accent-ink);
  border-color: var(--color-accent-rule);
  font-weight: 650;
}
.surface {
  background: var(--surface);
  border: var(--rule);
  border-radius: 10px;
  min-width: 0;
  overflow: hidden;
}
.surface-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 24px 12px;
}
.surface-heading p {
  font-size: 11px;
  color: var(--muted);
  margin-top: 5px;
}
.chart-frame {
  position: relative;
  height: 274px;
  padding: 20px 45px 28px;
  background: var(--surface);
}
.line-chart {
  display: block;
  width: 100%;
  height: 218px;
  overflow: visible;
}
.chart-line {
  fill: none;
  stroke: var(--accent);
  stroke-width: 2.5;
  stroke-linejoin: round;
  stroke-linecap: round;
  vector-effect: non-scaling-stroke;
}
.chart-grid {
  stroke: var(--border);
  stroke-width: 1;
  stroke-dasharray: 3 5;
  vector-effect: non-scaling-stroke;
}
.chart-dot {
  fill: var(--surface);
  stroke: var(--accent);
  stroke-width: 2;
  vector-effect: non-scaling-stroke;
}
.chart-dot:hover {
  fill: var(--accent);
}
.chart-y-label,
.chart-x-label {
  position: absolute;
  font-family: var(--font-data);
  font-size: 10px;
  color: var(--muted);
}
.chart-y-label {
  left: 16px;
}
.chart-y-top {
  top: 20px;
}
.chart-y-bottom {
  bottom: 47px;
}
.chart-x-label {
  bottom: 8px;
}
.chart-x-start {
  left: 45px;
}
.chart-x-end {
  right: 45px;
}
.chart-details {
  border-top: var(--rule);
  font-size: 11px;
  color: var(--muted);
}
.chart-details summary {
  padding: 12px 24px;
  min-height: 38px;
}
.chart-details > p {
  padding: 0 24px 16px;
  max-width: 75ch;
}
.chart-details .table-scroll {
  margin: 0 24px 20px;
}
.section-heading {
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 16px;
  margin: 0 0 20px;
}
.section-heading p {
  font-size: 12px;
  color: var(--muted);
  max-width: 75ch;
  margin-top: 6px;
}
.repo-name {
  color: var(--ink-strong);
  font-weight: 620;
  font-size: 13px;
  overflow-wrap: anywhere;
  line-height: 1.5;
}
.repo-name:hover {
  color: var(--accent-ink);
  text-decoration: underline;
  text-underline-offset: 3px;
}
.method-note {
  margin-top: 20px;
  font-size: 11px;
  color: var(--muted);
}

/* A short comparison summary, followed directly by the projects to read. */
.dashboard-scope {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px 20px;
  margin-bottom: 18px;
  color: var(--muted);
  font-size: 12px;
}
.dashboard-scope p span {
  display: block;
  margin-top: 4px;
  font-variant-numeric: tabular-nums;
}
.dashboard-scope .text-link {
  font-size: 12px;
}
.dashboard-leaderboards {
  display: grid;
  grid-template-columns: minmax(0, 1.8fr) minmax(260px, 1fr);
  align-items: start;
  gap: 24px;
}
.leaderboard .surface-heading {
  padding: 20px 24px 16px;
  border-bottom: var(--rule);
}
.leaderboard h2 {
  font-size: 16px;
  line-height: 1.4;
}
.leaderboard .surface-heading p {
  font-size: 11px;
  max-width: 48ch;
}
.board-more {
  display: inline-grid;
  place-items: center;
  min-width: 32px;
  min-height: 32px;
  flex-shrink: 0;
  color: var(--muted);
  border-radius: 4px;
}
.board-more:hover {
  background: var(--surface-strong);
  color: var(--ink);
}
.leaderboard-list {
  list-style: none;
  margin: 0;
  padding: 0 24px;
}
.leaderboard-list li {
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr) auto;
  align-items: start;
  gap: 12px;
  padding: 18px 0;
  border-bottom: var(--rule);
}
.leaderboard-list li:last-child {
  border-bottom: 0;
}
.leader-rank {
  padding-top: 3px;
  color: var(--faint);
  font-size: 12px;
  font-variant-numeric: tabular-nums;
}
.leader-identity {
  min-width: 0;
}
.leaderboard .repo-name {
  display: block;
  font-size: 13px;
  overflow-wrap: anywhere;
}
.leader-description {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
  margin-top: 5px;
  font-size: 12px;
  line-height: 1.6;
  color: var(--muted);
}
.leader-metadata {
  margin-top: 6px;
  font-size: 11px;
  color: var(--muted);
}
.leader-bar {
  display: block;
  width: 100%;
  max-width: 320px;
  height: 3px;
  margin-top: 9px;
  fill: var(--color-accent-rule);
}
.leader-value {
  text-align: right;
  font-variant-numeric: tabular-nums;
}
.leader-value strong {
  font-size: 14px;
  line-height: 1.5;
}
.leader-value small {
  display: block;
  margin-top: 5px;
  font-size: 11px;
  color: var(--muted);
  white-space: nowrap;
}
.leaderboard-secondary .leaderboard-list {
  padding-inline: 18px;
}
.leaderboard-secondary .leaderboard-list li {
  grid-template-columns: 16px minmax(0, 1fr);
  gap: 7px;
}
.leaderboard-secondary .leader-value {
  grid-column: 2;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: baseline;
  gap: 5px 12px;
}
.leaderboard-secondary .leader-value small {
  margin: 0;
}
.board-empty {
  padding: 28px 24px;
  font-size: 12px;
  color: var(--muted);
}
.board-empty span {
  display: block;
  margin-top: 8px;
}
@media (max-width: 1050px) {
  .dashboard-leaderboards {
    grid-template-columns: minmax(0, 1fr);
  }
}
@media (max-width: 540px) {
  .leaderboard .surface-heading,
  .leaderboard-list {
    padding-inline: 16px;
  }
  .leaderboard-list li {
    grid-template-columns: 18px minmax(0, 1fr);
    gap: 8px;
  }
  .leader-value {
    grid-column: 2;
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 8px;
  }
  .leader-value small {
    margin: 0;
  }
}
.method-note summary {
  padding: 8px 0;
}
.method-note p {
  max-width: 80ch;
  margin: 4px 0 8px;
}
.metric-positive,
.metric-negative,
.metric-neutral,
.metric-value,
.metric-delta {
  font-variant-numeric: tabular-nums;
}
.metric-positive {
  color: var(--success);
  font-weight: 620;
}
.metric-negative,
.value-danger {
  color: var(--danger);
  font-weight: 620;
}
.metric-neutral {
  color: var(--muted);
}
.metric-value {
  font-weight: 650;
  color: var(--ink-strong);
}
.metric-delta {
  color: var(--accent-ink);
  font-weight: 620;
}
.muted,
.empty-inline {
  color: var(--muted);
}
.repo-cell {
  min-width: 230px;
}
.repository-identity-line {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.new-badge,
.tag {
  display: inline-flex;
  align-items: center;
  border-radius: 4px;
  min-height: 23px;
  font-size: 10px;
  font-weight: 550;
  line-height: 1.4;
  padding: 3px 7px;
  background: var(--surface-strong);
  color: var(--muted);
  white-space: nowrap;
}
.new-badge {
  color: var(--accent-ink);
  background: var(--accent-soft);
}
.tag:hover {
  background: var(--accent-soft);
  color: var(--accent-ink);
}
.tag-muted {
  color: var(--faint);
}
.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}
.repository-description,
.cell-description {
  font-size: 11px;
  color: var(--muted);
  line-height: 1.6;
  margin-top: 6px;
  max-width: 62ch;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.cell-secondary {
  display: block;
  margin-top: 5px;
  font-size: 10px;
  color: var(--muted);
  font-weight: 400;
}
.table-scroll {
  max-width: 100%;
  overflow-x: auto;
}
.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
}
.data-table th {
  background: var(--surface-strong);
  color: var(--muted);
  font-size: 10px;
  font-weight: 550;
  text-align: left;
  padding: 12px 16px;
  border-bottom: var(--rule);
  white-space: nowrap;
}
.data-table td {
  padding: 16px;
  border-bottom: var(--rule);
  vertical-align: middle;
}
.data-table tbody tr:last-child td {
  border-bottom: 0;
}
.data-table tbody tr:hover {
  background: var(--color-hover);
}
.data-table .numeric {
  text-align: right;
  white-space: nowrap;
}
.repository-trend-table {
  min-width: 880px;
}
.repository-trend-table .repo-cell {
  width: 35%;
  max-width: 480px;
}
.repository-trend-table small {
  display: block;
}
.rank-transition {
  display: inline-flex;
  gap: 5px;
  align-items: center;
  color: var(--muted);
  font-size: 11px;
}
.rank-transition strong {
  color: var(--ink-strong);
}
.repository-record-list {
  display: none;
}
.library-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 20px;
}
.library-views {
  display: flex;
  gap: 20px;
}
.library-views a {
  font-size: 13px;
  color: var(--muted);
  padding: 8px 0;
  border-bottom: 2px solid transparent;
}
.library-views a.is-active {
  color: var(--ink-strong);
  border-bottom-color: var(--accent);
  font-weight: 650;
}
.library-add {
  min-height: 36px;
  padding: 7px 12px;
  font-size: 12px;
}
.library-search {
  display: flex;
  align-items: center;
  gap: 8px;
}
.library-search input {
  width: 250px;
  font-size: 12px;
}
.library-filters {
  display: flex;
  flex-wrap: wrap;
  align-items: end;
  gap: 12px;
  padding: 16px 20px;
  border-bottom: var(--rule);
}
.library-filters .field {
  flex: 1 1 140px;
}
.library-filters .field-search {
  flex: 2 1 200px;
}
.library-filters .filter-actions {
  display: flex;
  align-items: center;
  gap: 16px;
}
.new-project-filter {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 40px;
  font-size: 12px;
  white-space: nowrap;
  cursor: pointer;
}
.new-project-filter input {
  width: 16px;
  height: 16px;
  min-height: 0;
  margin: 0;
  accent-color: var(--accent);
}
.new-project-note {
  padding: 12px 20px 0;
  color: var(--muted);
  font-size: 12px;
}
.field label {
  display: block;
  font-size: 11px;
  font-weight: 600;
  color: var(--muted);
  margin-bottom: 6px;
}
.field input,
.field select,
.field textarea {
  width: 100%;
}
.field-hint {
  font-size: 11px;
  color: var(--muted);
  margin-top: 6px;
  line-height: 1.6;
}
.library-count {
  font-size: 11px;
  color: var(--muted);
  padding: 14px 20px;
  border-bottom: var(--rule);
  display: flex;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
}
.library-count .period-switch {
  background: transparent;
  padding: 0;
}
.library-count .period-option {
  min-height: 28px;
  padding: 4px 9px;
  font-size: 10px;
}
.cursor-pagination,
.pagination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-top: 20px;
  color: var(--muted);
  font-size: 11px;
}
.cursor-pagination > div,
.pagination > div {
  display: flex;
  gap: 8px;
}
.breadcrumb {
  margin-bottom: 14px;
  font-size: 11px;
}
.breadcrumb-link {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--muted);
}
.entity-title-repository {
  font-size: 27px;
  letter-spacing: -0.025em;
}
.entity-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
}
.entity-description {
  font-size: 14px;
  line-height: 1.8;
  max-width: 75ch;
  color: var(--ink);
}
.entity-header {
  margin-bottom: 28px;
}
.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 23px;
  border-radius: 4px;
  padding: 3px 7px;
  font-size: 10px;
  white-space: nowrap;
}
.status-badge > span {
  width: 5px;
  height: 5px;
  border-radius: 100%;
  background: currentColor;
}
.status-success {
  background: var(--success-soft);
  color: var(--success);
}
.status-warning {
  background: var(--warning-soft);
  color: var(--warning);
}
.status-danger {
  background: var(--danger-soft);
  color: var(--danger);
}
.status-info {
  background: var(--info-soft);
  color: var(--info);
}
.status-neutral {
  background: var(--surface-strong);
  color: var(--muted);
}
.repository-analysis {
  padding: 24px;
  background: var(--surface);
  border: var(--rule);
  border-radius: 10px;
  margin: 24px 0;
}
.analysis-summary {
  font-size: 15px;
  line-height: 1.9;
  max-width: 75ch;
  color: var(--ink-strong);
}
.analysis-columns {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 32px;
  margin-top: 24px;
}
.analysis-columns h3 {
  font-size: 13px;
  margin-bottom: 10px;
}
.analysis-columns ul {
  margin: 0;
  padding-left: 16px;
  font-size: 12px;
  line-height: 1.85;
}
.analysis-columns li + li {
  margin-top: 8px;
}
.analysis-provenance {
  font-size: 10px;
  color: var(--muted);
  margin-top: 20px;
}
.analysis-notes {
  margin-top: 20px;
  padding-top: 14px;
  border-top: var(--rule);
  font-size: 12px;
}
.analysis-notes p {
  margin: 12px 0;
  line-height: 1.8;
  max-width: 75ch;
  white-space: pre-wrap;
}
.analysis-pending span {
  display: block;
  font-size: 10px;
  color: var(--muted);
  margin-bottom: 8px;
}
.readme-link {
  margin-top: 16px;
}
.analysis-pending .watch-note {
  font-size: 12px;
  color: var(--muted);
  margin-top: 12px;
}
.analysis-pending p {
  font-size: 14px;
  line-height: 1.8;
  max-width: 75ch;
}
.metric-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  background: var(--surface);
  border: var(--rule);
  border-radius: 8px;
  margin: 0;
}
.metric-strip > div {
  padding: 18px 20px;
  border-right: var(--rule);
  min-width: 0;
}
.metric-strip > div:last-child {
  border-right: 0;
}
.metric-strip dt {
  font-size: 11px;
  color: var(--muted);
  font-weight: 500;
}
.metric-strip dd {
  font-size: 22px;
  font-weight: 630;
  color: var(--ink-strong);
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.025em;
  margin: 8px 0 0;
  line-height: 1.4;
}
.metric-strip dd small {
  display: block;
  font-size: 10px;
  font-weight: 400;
  letter-spacing: 0;
  color: var(--muted);
  margin-top: 4px;
}
.metric-strip .date-value {
  font-size: 16px;
}
.topic-metrics {
  grid-template-columns: repeat(6, minmax(0, 1fr));
  margin-top: 24px;
}
.evidence-grid,
.split-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 28px;
  margin-top: 28px;
}
.evidence-grid {
  padding: 24px;
  border: var(--rule);
  border-radius: 8px;
  background: var(--surface);
}
.definition-list {
  margin: 0;
}
.definition-list > div {
  display: grid;
  grid-template-columns: minmax(100px, 0.6fr) minmax(0, 1fr);
  gap: 16px;
  padding: 10px 0;
  border-bottom: var(--rule);
  font-size: 11px;
}
.definition-list dt {
  color: var(--muted);
}
.definition-list dd {
  margin: 0;
  overflow-wrap: anywhere;
}
.plain-list {
  margin: 0;
  padding-left: 18px;
  font-size: 12px;
  line-height: 1.8;
}
.plain-list li {
  overflow-wrap: anywhere;
}
.empty-inline {
  font-size: 12px;
  padding: 12px 0;
}
.chart-panel {
  border: var(--rule);
  border-radius: 10px;
  background: var(--surface);
  margin-top: 28px;
  overflow: hidden;
}
.chart-panel > .section-heading {
  padding: 20px 24px 0;
}
.supporting-chart .chart-frame {
  height: 220px;
}
.supporting-chart .line-chart {
  height: 164px;
}
.compact-table {
  min-width: 0;
}
.mono-value,
.mono-list {
  font-family: var(--font-data);
  font-size: 11px;
}
.empty-state {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  min-height: 220px;
  text-align: center;
  padding: 32px;
  border: var(--rule);
  border-radius: 8px;
  background: var(--surface);
}
.empty-state p {
  max-width: 60ch;
  font-size: 12px;
  color: var(--muted);
  margin-top: 10px;
}
.empty-state .button {
  margin-top: 20px;
}
.topic-coverage-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 20px 24px;
  background: var(--surface);
  border: var(--rule);
  border-radius: 8px;
  margin-bottom: 28px;
}
.topic-coverage-summary p {
  font-size: 11px;
  color: var(--muted);
  max-width: 65ch;
  margin-top: 6px;
}
.topic-coverage-summary dl {
  display: grid;
  grid-template-columns: repeat(4, minmax(70px, 1fr));
  gap: 24px;
  margin: 0;
}
.topic-coverage-summary dt {
  font-size: 10px;
  color: var(--muted);
  white-space: nowrap;
}
.topic-coverage-summary dd {
  font-size: 20px;
  font-weight: 650;
  letter-spacing: -0.02em;
  margin: 6px 0 0;
  font-variant-numeric: tabular-nums;
}
.topic-ranking-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 18px;
}
.topic-ranking-header p {
  font-size: 12px;
  color: var(--muted);
  max-width: 75ch;
  margin-top: 6px;
}
.topic-ranking-list {
  list-style: none;
  margin: 0;
  padding: 0 24px;
  border: var(--rule);
  border-radius: 8px;
  background: var(--surface);
}
.topic-ranking-list li {
  display: grid;
  grid-template-columns: 22px minmax(150px, 0.7fr) minmax(60px, auto) minmax(
      0,
      1fr
    );
  gap: 20px;
  align-items: center;
  padding: 18px 0;
  border-bottom: var(--rule);
}
.topic-ranking-list li:last-child {
  border: 0;
}
.topic-rank-number {
  font-size: 11px;
  color: var(--faint);
}
.topic-name {
  font-size: 13px;
  font-weight: 650;
  color: var(--ink-strong);
}
.topic-rank-identity p {
  font-size: 10px;
  color: var(--muted);
  margin-top: 4px;
}
.topic-rank-delta {
  font-size: 12px;
  color: var(--accent-ink);
  text-align: right;
  font-variant-numeric: tabular-nums;
}
.topic-rank-bar {
  width: 100%;
  height: 8px;
}
.topic-rank-positive {
  fill: var(--accent);
}
.topic-rank-negative {
  fill: var(--danger);
}
.topic-rank-zero {
  fill: var(--muted);
}
.topic-rank-baseline {
  stroke: var(--border-strong);
}
.page-drilldown {
  margin-top: 32px;
}
.topic-table {
  min-width: 840px;
}
.page-drilldown > .table-scroll {
  background: var(--surface);
  border: var(--rule);
  border-radius: 8px;
}
.leader-toggle {
  font-size: 12px;
  color: var(--muted);
}
.leader-toggle label {
  display: flex;
  align-items: center;
  gap: 8px;
}
.parent-link,
.filter-note {
  font-size: 12px;
  color: var(--muted);
  margin-top: 12px;
}
.detail-sections {
  margin-top: 28px;
}
.detail-sections > section {
  background: var(--surface);
  border: var(--rule);
  padding: 20px;
  border-radius: 8px;
  min-width: 0;
}
.detail-sections .data-table td {
  padding: 12px 8px;
}
.page-summary {
  margin-bottom: 28px;
}
.run-list {
  background: var(--surface);
  border: var(--rule);
  border-radius: 8px;
  padding: 0 20px;
}
.run-row {
  padding: 18px 0;
  border-bottom: var(--rule);
}
.run-row:last-child {
  border: 0;
}
.run-row-main {
  display: grid;
  grid-template-columns: 80px minmax(100px, 0.8fr) minmax(240px, 1.2fr) 170px;
  align-items: center;
  gap: 16px;
}
.run-identity h3 {
  font-size: 12px;
}
.run-identity p {
  font-size: 9px;
  color: var(--muted);
  margin-top: 4px;
  overflow-wrap: anywhere;
}
.run-counts {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  margin: 0;
}
.run-counts dt {
  font-size: 10px;
  color: var(--muted);
}
.run-counts dd {
  font-size: 13px;
  font-weight: 650;
  margin: 4px 0 0;
}
.run-time {
  font-size: 10px;
  color: var(--muted);
  text-align: right;
}
.run-time span {
  display: block;
  margin-top: 4px;
}
.run-details {
  margin-top: 12px;
  background: var(--surface-strong);
  border-radius: 5px;
}
.run-details summary {
  font-size: 11px;
  padding: 10px 12px;
  color: var(--muted);
}
.run-detail-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
  padding: 12px 16px;
}
.run-detail-grid h4 {
  font-size: 12px;
  margin-bottom: 8px;
}
.run-detail-grid p {
  font-size: 11px;
}
.error-summary {
  color: var(--danger);
}
.error-page {
  text-align: center;
  max-width: 620px;
  margin: 48px auto;
  padding: 40px;
}
.error-page p {
  margin: 16px 0 24px;
  color: var(--muted);
}
.error-code {
  font-size: 24px;
  color: var(--accent);
  font-weight: 650;
}
.app-footer {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 36px 24px;
  color: var(--muted);
  font-size: 10px;
  border-top: var(--rule);
}
.category-catalog {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}
.category-card {
  padding: 24px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}
.category-card-heading {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.category-card-heading .topic-name {
  font-size: 16px;
}
.category-card-heading > span {
  font-size: 11px;
  color: var(--muted);
  white-space: nowrap;
}
.category-card > p {
  color: var(--muted);
  font-size: 12px;
  line-height: 1.8;
  margin: 12px 0 16px;
  max-width: 65ch;
}
.category-card .tag-list {
  margin-bottom: 18px;
}
.category-card > .text-link {
  margin-top: auto;
  padding-top: 6px;
}
.category-growth-details {
  margin-top: 24px;
}
.category-growth-details > summary {
  font-size: 12px;
  color: var(--muted);
  padding: 14px 0;
  border-top: var(--rule);
}
@media (max-width: 700px) {
  .category-catalog {
    grid-template-columns: 1fr;
  }
  .category-card {
    padding: 20px;
  }
}
.watch-panel {
  max-width: 760px;
  margin: 0 auto;
  padding: 28px;
  background: var(--surface);
  border: var(--rule);
  border-radius: 10px;
}
.watch-form {
  display: flex;
  flex-direction: column;
  gap: 22px;
}
.watch-form input:not([type="checkbox"]),
.watch-form select,
.watch-form textarea {
  min-height: 44px;
  font-size: 14px;
}
.watch-form textarea {
  min-height: 96px;
  resize: vertical;
}
.form-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  border-top: var(--rule);
  padding-top: 22px;
}
.watch-expectation {
  margin: 24px auto 0;
  max-width: 760px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.8;
}
.watch-expectation ul {
  padding-left: 20px;
}
.field-error {
  color: var(--danger);
  font-size: 12px;
}
@media (min-width: 1800px) {
  .page-shell {
    padding-top: 44px;
  }
}
@media (max-width: 1280px) {
  .app-sidebar {
    width: 190px;
    padding-inline: 14px;
  }
  .app-main {
    margin-left: 190px;
  }
  .app-header,
  .app-footer {
    padding-inline: 26px;
  }
  .page-shell {
    padding: 28px 26px 40px;
  }
  .page-heading-tools {
    flex-direction: column-reverse;
    align-items: flex-end;
    gap: 8px;
  }
  .run-row-main {
    grid-template-columns: 70px minmax(100px, 1fr) minmax(230px, 1.3fr);
  }
  .run-time {
    grid-column: 2/-1;
    text-align: left;
  }
  .topic-metrics {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
  .topic-metrics > div:nth-child(3) {
    border-right: 0;
  }
  .topic-metrics > div:nth-child(n + 4) {
    border-top: var(--rule);
  }
}
@media (max-width: 1000px) {
  .app-sidebar {
    width: 172px;
    padding: 24px 12px 16px;
  }
  .app-main {
    margin-left: 172px;
  }
  .brand {
    font-size: 15px;
    gap: 7px;
  }
  .brand-mark {
    width: 29px;
  }
  .brand-mark svg {
    width: 29px;
  }
  .brand small {
    font-size: 9px;
  }
  .nav-link {
    padding-inline: 10px;
    font-size: 12px;
    gap: 9px;
  }
  .page-shell {
    padding: 26px 22px 36px;
  }
  .app-header,
  .app-footer {
    padding-inline: 22px;
  }
  .header-context > span:last-child {
    max-width: 230px;
  }
  h1 {
    font-size: 25px;
  }
  .surface-heading {
    padding: 18px;
  }
  .surface-heading h2 {
    font-size: 15px;
  }
  .chart-frame {
    padding-inline: 38px;
  }
  .chart-y-label {
    left: 10px;
  }
  .chart-x-start {
    left: 38px;
  }
  .chart-x-end {
    right: 38px;
  }
  .topic-coverage-summary {
    align-items: flex-start;
    flex-direction: column;
  }
  .topic-coverage-summary dl {
    width: 100%;
  }
  .topic-ranking-list li {
    grid-template-columns: 18px minmax(130px, 1fr) auto;
    gap: 12px;
  }
  .topic-rank-bar {
    grid-column: 2/-1;
  }
  .library-toolbar {
    flex-wrap: wrap;
  }
  .library-search {
    flex: 1;
  }
  .library-search input {
    width: 100%;
  }
}
@media (max-width: 800px) {
  .app-sidebar {
    position: relative;
    width: 100%;
    padding: 14px 18px 0;
    display: block;
  }
  .brand {
    margin: 0 0 16px;
    font-size: 16px;
  }
  .brand small,
  .sidebar-label,
  .sidebar-bottom {
    display: none;
  }
  .primary-nav {
    flex-direction: row;
    gap: 4px;
    justify-content: flex-start;
  }
  .nav-link {
    min-height: 44px;
    font-size: 12px;
    padding: 10px 12px;
    border-radius: 5px 5px 0 0;
  }
  .nav-link svg {
    width: 16px;
    height: 16px;
  }
  .app-main {
    margin-left: 0;
  }
  .app-header {
    height: 48px;
    padding-inline: 20px;
  }
  .header-context {
    font-size: 11px;
  }
  .page-shell {
    padding: 24px 20px 36px;
  }
  .page-heading {
    gap: 16px;
    margin-bottom: 24px;
  }
  .page-heading-tools {
    align-items: flex-end;
  }
  .page-heading-copy > p {
    font-size: 12px;
  }
  .repository-table-scroll {
    display: none;
  }
  .repository-record-list {
    display: block;
    list-style: none;
    margin: 0;
    padding: 0 20px;
  }
  .repository-record-list > li {
    padding: 20px 0;
    border-bottom: var(--rule);
  }
  .repository-record-list > li:last-child {
    border: 0;
  }
  .repository-mobile-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 14px;
  }
  .repository-mobile-header > div {
    min-width: 0;
  }
  .repository-mobile-metrics {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
    margin: 16px 0 0;
  }
  .repository-mobile-metrics dt {
    color: var(--muted);
    font-size: 10px;
  }
  .repository-mobile-metrics dd {
    margin: 5px 0 0;
    font-size: 12px;
  }
  .repository-mobile-wide {
    grid-column: 1/-1;
  }
  .library-count {
    flex-wrap: wrap;
  }
  .evidence-grid,
  .split-layout {
    grid-template-columns: 1fr;
  }
  .run-row-main {
    grid-template-columns: 70px minmax(0, 1fr);
  }
  .run-counts {
    grid-column: 1/-1;
  }
  .run-time {
    grid-column: 1/-1;
  }
  .run-detail-grid {
    grid-template-columns: 1fr;
  }
  .entity-title-repository {
    font-size: 25px;
  }
  .app-footer {
    padding-inline: 20px;
  }
}
@media (max-width: 560px) {
  html {
    font-size: 14px;
  }
  .app-sidebar {
    padding: 14px 12px 0;
  }
  .primary-nav {
    gap: 0;
  }
  .nav-link {
    gap: 6px;
    font-size: 11px;
    padding-inline: 9px;
  }
  .nav-link svg {
    width: 14px;
  }
  .app-header {
    padding-inline: 16px;
  }
  .header-context {
    gap: 8px;
  }
  .header-context > span:last-child {
    max-width: 135px;
  }
  .header-slash {
    display: none;
  }
  .page-shell {
    padding: 24px 16px 32px;
  }
  .page-heading {
    display: block;
    margin-bottom: 24px;
  }
  h1 {
    font-size: 24px;
  }
  .page-heading-tools {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    margin-top: 18px;
  }
  .page-heading-tools .button {
    min-height: 40px;
  }
  .dashboard-toolbar {
    align-items: flex-start;
    gap: 12px;
    flex-direction: column;
  }
  .date-form {
    width: 100%;
  }
  .date-form input {
    flex: 1;
    min-width: 0;
  }
  .period-switch {
    width: 100%;
    justify-content: space-between;
  }
  .period-option {
    flex: 1;
    min-height: 34px;
    padding-inline: 10px;
  }
  .category-tabs {
    gap: 5px;
    margin-bottom: 20px;
  }
  .category-tab {
    font-size: 10px;
    padding: 5px 9px;
  }
  .surface-heading {
    padding: 18px;
  }
  .chart-frame {
    height: 245px;
    padding: 18px 30px 28px;
  }
  .line-chart {
    height: 195px;
  }
  .chart-y-label {
    font-size: 9px;
    left: 8px;
  }
  .chart-x-start {
    left: 30px;
  }
  .chart-x-end {
    right: 30px;
  }
  .chart-details summary {
    padding: 12px 18px;
  }
  .section-heading {
    align-items: flex-start;
    gap: 12px;
  }
  .section-heading .text-link {
    font-size: 11px;
  }
  .library-toolbar {
    gap: 16px;
  }
  .library-views {
    gap: 20px;
  }
  .library-search {
    width: 100%;
    flex-basis: 100%;
  }
  .library-filters {
    padding: 16px;
    gap: 14px;
  }
  .library-filters .field {
    flex-basis: calc(50% - 14px);
  }
  .library-filters .field-search {
    flex-basis: 100%;
  }
  .library-filters input,
  .library-filters select {
    font-size: 14px;
  }
  .library-filters .filter-actions {
    flex-basis: 100%;
    justify-content: space-between;
  }
  .library-filters .filter-actions .button {
    min-width: 80px;
  }
  .library-count {
    padding: 14px 16px;
  }
  .repository-record-list {
    padding: 0 16px;
  }
  .repository-mobile-metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .cursor-pagination,
  .pagination {
    flex-direction: column;
    align-items: stretch;
  }
  .cursor-pagination > div,
  .pagination > div {
    justify-content: space-between;
  }
  .metric-strip {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
  .metric-strip > div {
    padding: 16px;
  }
  .metric-strip > div:nth-child(even) {
    border-right: 0;
  }
  .metric-strip > div:nth-child(n + 3) {
    border-top: var(--rule);
  }
  .metric-strip dd {
    font-size: 20px;
  }
  .repository-analysis {
    padding: 20px;
  }
  .analysis-summary {
    font-size: 14px;
  }
  .analysis-columns {
    grid-template-columns: 1fr;
    gap: 20px;
  }
  .topic-coverage-summary {
    padding: 20px;
    gap: 20px;
  }
  .topic-coverage-summary dl {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
  }
  .topic-ranking-header {
    align-items: stretch;
    flex-direction: column;
  }
  .topic-ranking-list {
    padding-inline: 16px;
  }
  .topic-ranking-list li {
    grid-template-columns: 16px minmax(0, 1fr) auto;
    gap: 10px;
  }
  .topic-rank-identity p {
    font-size: 9px;
  }
  .topic-name {
    font-size: 12px;
  }
  .app-footer {
    flex-direction: column;
    gap: 6px;
    padding-inline: 16px;
  }
  .evidence-grid {
    padding: 20px;
  }
  .watch-panel {
    padding: 20px;
  }
  .watch-form input:not([type="checkbox"]),
  .watch-form select,
  .watch-form textarea {
    font-size: 16px;
  }
  .form-actions {
    flex-direction: column;
    align-items: stretch;
  }
  .form-actions .button {
    min-height: 44px;
  }
  .error-page {
    margin: 24px 0;
    padding: 24px 0;
  }
}
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
  button:active {
    transform: none;
  }
}
@media print {
  .app-sidebar,
  .app-header,
  .category-tabs,
  .button,
  .library-filters {
    display: none !important;
  }
  .app-main {
    margin: 0;
  }
  .page-shell {
    padding: 0;
  }
  .surface {
    break-inside: avoid;
  }
  .app-footer {
    padding: 12px 0;
  }
  .table-scroll {
    overflow: visible;
  }
  .repository-table-scroll {
    display: block;
  }
  .repository-record-list {
    display: none;
  }
}
