:root {
  color-scheme: light;
  --ink: #171714;
  --muted: #68675f;
  --line: #d8d5ca;
  --paper: #f5f2e9;
  --panel: #fffdf7;
  --accent: #315c45;
  --danger: #9c2f23;
}

* {
  box-sizing: border-box;
}

html {
  background: var(--paper);
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  margin: 0;
  color: var(--ink);
  background:
    linear-gradient(90deg, transparent 49.9%, rgb(23 23 20 / 4%) 50%, transparent 50.1%),
    var(--paper);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.5;
}

a {
  color: inherit;
  text-underline-offset: 0.2em;
}

a:focus-visible,
input:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 3px;
}

.skip-link {
  position: fixed;
  z-index: 10;
  top: 0.75rem;
  left: 0.75rem;
  padding: 0.65rem 0.9rem;
  color: var(--panel);
  background: var(--ink);
  transform: translateY(-180%);
}

.skip-link:focus {
  transform: translateY(0);
}

.site-header,
main,
footer {
  width: min(1180px, calc(100% - 2.5rem));
  margin-inline: auto;
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 5.5rem;
  border-bottom: 1px solid var(--line);
}

.wordmark {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.6rem;
  font-weight: 700;
  text-decoration: none;
}

nav {
  display: flex;
  gap: clamp(1rem, 4vw, 2.5rem);
  font-size: 0.9rem;
}

nav a {
  text-decoration: none;
}

nav a:hover {
  text-decoration: underline;
}

main {
  padding-block: clamp(3rem, 8vw, 7rem);
}

.hero {
  max-width: 780px;
  margin-bottom: 3rem;
}

.eyebrow {
  margin: 0 0 1rem;
  color: var(--accent);
  font-size: 0.75rem;
  font-weight: 750;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  max-width: 12ch;
  margin-bottom: 1.25rem;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(3rem, 9vw, 7.5rem);
  font-weight: 500;
  letter-spacing: -0.055em;
  line-height: 0.92;
}

h2 {
  font-size: clamp(1.5rem, 3vw, 2.25rem);
  letter-spacing: -0.03em;
}

.intro {
  max-width: 62ch;
  color: var(--muted);
  font-size: clamp(1rem, 2vw, 1.2rem);
}

.bench-workbench-entry {
  max-width: 62ch;
  margin-top: 2rem;
  padding: clamp(1.25rem, 3vw, 2rem);
  border: 1px solid var(--line);
  background: var(--panel);
}

.bench-workbench-entry h2 { margin-bottom: 0.6rem; }
.bench-workbench-entry p:not(.eyebrow) { color: var(--muted); }
.bench-workbench-entry a {
  display: inline-block;
  margin-top: 0.35rem;
  padding: 0.8rem 1.1rem;
  color: #fff;
  background: var(--accent);
  font-weight: 700;
  text-decoration: none;
}
.bench-workbench-entry a:hover { background: #254836; }
.bench-workbench-entry small { display: block; margin-top: 0.8rem; color: var(--muted); }

.status {
  margin-bottom: 2rem;
  padding: 1rem 1.25rem;
  border: 1px solid var(--line);
  background: var(--panel);
}

.status-error {
  color: var(--danger);
  border-color: currentColor;
}

[hidden] {
  display: none !important;
}

main > section + section {
  margin-top: clamp(4rem, 9vw, 7rem);
}

.summary-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1px;
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--line);
}

.summary-card {
  min-height: 12rem;
  padding: clamp(1.25rem, 3vw, 2rem);
  background: var(--panel);
}

.summary-label,
.summary-note,
.section-heading p {
  color: var(--muted);
  font-size: 0.85rem;
}

.summary-value {
  display: block;
  margin-block: 1.1rem;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(2rem, 5vw, 3.75rem);
  font-weight: 500;
  line-height: 1;
}

.section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 2rem;
  margin-bottom: 1.5rem;
}

.section-heading h2,
.section-heading p {
  margin-bottom: 0;
}

.table-wrap {
  overflow-x: auto;
  border-block: 1px solid var(--ink);
}

table {
  width: 100%;
  min-width: 760px;
  border-collapse: collapse;
  font-variant-numeric: tabular-nums;
}

th,
td {
  padding: 1rem;
  border-bottom: 1px solid var(--line);
  text-align: right;
  white-space: nowrap;
}

th {
  color: var(--muted);
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

th:nth-child(2),
th:nth-child(3),
td:nth-child(2),
td:nth-child(3) {
  text-align: left;
}

td:nth-child(2) {
  font-weight: 700;
}

tbody tr:hover {
  background: var(--panel);
}

.repository-heading {
  align-items: flex-end;
}

.search-field {
  display: grid;
  min-width: min(100%, 22rem);
  gap: 0.4rem;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 700;
}

.search-field input {
  width: 100%;
  padding: 0.8rem 0;
  border: 0;
  border-bottom: 1px solid var(--ink);
  border-radius: 0;
  color: var(--ink);
  background: transparent;
  font: inherit;
  font-size: 1rem;
}

.repository-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border-top: 1px solid var(--ink);
}

.repository-card {
  display: flex;
  min-height: 18rem;
  padding: 1.5rem;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  flex-direction: column;
}

.repository-card:nth-child(3n) {
  border-right: 0;
}

.repository-card h3 {
  margin-bottom: 1rem;
  font-size: 1.25rem;
  overflow-wrap: anywhere;
}

.repository-description {
  color: var(--muted);
}

.repository-meta {
  display: grid;
  margin: auto 0 0;
  gap: 0.6rem;
  font-size: 0.8rem;
}

.repository-meta div {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding-top: 0.6rem;
  border-top: 1px solid var(--line);
}

.repository-meta dt {
  color: var(--muted);
}

.repository-meta dd {
  margin: 0;
  text-align: right;
}

.empty-state {
  grid-column: 1 / -1;
  padding: 3rem 1.5rem;
  color: var(--muted);
}

footer {
  padding-block: 2rem;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.8rem;
}

@media (max-width: 800px) {
  .summary-grid,
  .repository-grid {
    grid-template-columns: 1fr 1fr;
  }

  .repository-card:nth-child(3n) {
    border-right: 1px solid var(--line);
  }

  .repository-card:nth-child(2n) {
    border-right: 0;
  }
}

@media (max-width: 560px) {
  .site-header {
    align-items: flex-start;
    padding-block: 1.25rem;
    flex-direction: column;
    gap: 1rem;
  }

  main {
    padding-top: 3.5rem;
  }

  .summary-grid,
  .repository-grid {
    grid-template-columns: 1fr;
  }

  .repository-card,
  .repository-card:nth-child(2n),
  .repository-card:nth-child(3n) {
    min-height: 15rem;
    border-right: 0;
  }

  .section-heading {
    align-items: stretch;
    flex-direction: column;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}
