@font-face {
  font-family: "InterVariable";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("https://rsms.me/inter/font-files/InterVariable.woff2?v=4.1") format("woff2");
}

:root {
  --ink: #202124;
  --muted: #5f6368;
  --quiet: #85898e;
  --line: #d9dcdf;
  --line-soft: #eceef0;
  --surface: #ffffff;
  --wash: #f5f6f6;
  --focus: #2d6094;
  color: var(--ink);
  background: var(--wash);
  font-family: "InterVariable", Inter, ui-sans-serif, system-ui, sans-serif;
  font-synthesis: none;
  color-scheme: light;
}

* { box-sizing: border-box; }
html { min-width: 320px; min-height: 100%; scroll-behavior: smooth; }
body {
  min-width: 320px;
  min-height: 100vh;
  margin: 0;
  display: flex;
  flex-direction: column;
  color: var(--ink);
  background: var(--wash);
  font-size: 15px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  font-feature-settings: "cv02", "cv03", "cv04", "cv11";
}
a { color: inherit; }
.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;
}

.site-header {
  height: 58px;
  flex: 0 0 auto;
  position: sticky;
  top: 0;
  z-index: 20;
  border-bottom: 1px solid var(--line);
  background: rgba(255,255,255,.96);
  box-shadow: 0 1px 0 rgba(32,33,36,.02);
  backdrop-filter: blur(10px);
}
.header-inner {
  width: min(1040px, calc(100% - 40px));
  height: 100%;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
}
.brand {
  width: 158px;
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
}
.brand img { width: 100%; height: auto; display: block; }
nav { height: 100%; display: flex; align-items: center; gap: 24px; }
nav a {
  height: 100%;
  padding-top: 1px;
  display: inline-flex;
  align-items: center;
  border-bottom: 2px solid transparent;
  color: var(--muted);
  font-size: 13px;
  font-weight: 520;
  text-decoration: none;
}
nav a:hover { color: var(--ink); }
nav .nav-link--current { border-bottom-color: var(--ink); color: var(--ink); }
nav .nav-link--accent { color: #8f3f31; font-weight: 640; }
nav .nav-link--accent:hover { color: #6f2d22; }

@media (max-width: 900px) {
  nav { gap: 16px; }
  nav .nav-visibility--desktop { display: none; }
}

nav a:focus-visible,
.brand:focus-visible,
.tool-card:focus-visible,
.directory-search input:focus-visible,
.directory-search button:focus-visible,
.clear-search:focus-visible,
.page-nav:focus-visible,
.page-number:focus-visible {
  outline: 3px solid rgba(45,96,148,.2);
  outline-offset: 2px;
}

.site-main {
  width: min(1040px, calc(100% - 40px));
  margin: 0 auto;
  padding: 40px 0 72px;
}
.intro {
  max-width: 850px;
  padding-bottom: 34px;
}
.intro h1 {
  margin: 0;
  font-size: clamp(30px, 3vw, 36px);
  font-weight: 635;
  letter-spacing: -.034em;
  line-height: 1.12;
  text-wrap: balance;
}
.intro-copy {
  margin: 7px 0 0;
  color: #44484c;
  font-size: 15px;
  font-weight: 520;
}
.about-copy {
  max-width: 780px;
  margin: 13px 0 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.6;
  text-wrap: pretty;
}

.directory { border-top: 1px solid #d3d6d8; }
.directory-toolbar {
  min-height: 70px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
}
.section-heading {
  display: flex;
  align-items: baseline;
  gap: 10px;
  white-space: nowrap;
}
.section-heading h2 {
  margin: 0;
  font-size: 16px;
  font-weight: 640;
  letter-spacing: -.015em;
}
.tool-count { color: var(--quiet); font-size: 12px; }
.directory-search {
  width: min(440px, 100%);
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
}
.directory-search input {
  min-width: 0;
  height: 36px;
  padding: 7px 10px;
  border: 1px solid var(--line);
  border-right: 0;
  border-radius: 3px 0 0 3px;
  outline: 0;
  color: var(--ink);
  background: #ffffff;
  font: inherit;
  font-size: 13px;
}
.directory-search input::placeholder { color: #92969a; }
.directory-search input:focus {
  border-color: var(--focus);
  box-shadow: inset 0 0 0 1px var(--focus), 0 0 0 3px rgba(45,96,148,.08);
}
.directory-search button,
.clear-search {
  min-height: 36px;
  padding: 7px 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 0;
  font-size: 12px;
  font-weight: 620;
}
.directory-search button {
  border: 1px solid var(--ink);
  border-radius: 0 3px 3px 0;
  color: white;
  background: var(--ink);
  cursor: pointer;
}
.directory-search button:hover { background: #35373a; }
.clear-search {
  border: 1px solid var(--line);
  border-right: 0;
  color: var(--muted);
  background: var(--wash);
  text-decoration: none;
}
.clear-search:hover { color: var(--ink); background: #f0f1f1; }

.tool-grid { display: grid; gap: 7px; }
.tool-card {
  min-height: 46px;
  padding: 8px 12px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 190px 80px;
  column-gap: 18px;
  align-items: center;
  border: 1px solid #d1d4d7;
  border-radius: 3px;
  color: var(--ink);
  background: var(--surface);
  box-shadow: 0 1px 2px rgba(32,33,36,.025);
  text-decoration: none;
  transition: border-color .14s ease, background-color .14s ease, box-shadow .14s ease;
}
.tool-card:hover {
  border-color: #a8adb1;
  background: #ffffff;
  box-shadow: 0 2px 7px rgba(32,33,36,.065);
}
.tool-primary {
  min-width: 0;
  display: flex;
  align-items: baseline;
  gap: 6px;
  white-space: nowrap;
}
.tool-name {
  font-size: 15px;
  font-weight: 660;
  letter-spacing: -.012em;
  flex: 0 0 auto;
}
.tool-separator { color: #9a9ea2; font-size: 12px; flex: 0 0 auto; }
.tool-description {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
  white-space: nowrap;
}
.tool-creators {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  color: var(--quiet);
  font-size: 11px;
  white-space: nowrap;
}
.tool-creators small {
  font-size: inherit;
  font-weight: 520;
}
.tool-creators strong {
  color: #44484c;
  font-size: inherit;
  font-weight: 600;
}
.tool-meta { min-width: 0; display: flex; justify-content: flex-end; }
.health-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #5d6267;
  font-size: 11px;
  font-weight: 600;
}
.health-badge i { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.health-badge--active { color: #267251; }
.health-badge--inactive { color: #777c80; }
.health-badge--faulty { color: #a23e49; }

.empty-state {
  padding: 30px 14px;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  color: var(--muted);
}
.empty-state strong,
.empty-state span { display: block; }
.empty-state strong { color: var(--ink); font-size: 13px; font-weight: 640; }
.empty-state span { margin-top: 4px; font-size: 13px; }

.pagination {
  margin-top: 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}
.page-numbers { display: flex; align-items: center; justify-content: center; gap: 2px; }
.page-nav,
.page-number,
.page-ellipsis {
  min-width: 32px;
  min-height: 32px;
  padding: 6px 8px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 2px;
  color: var(--muted);
  font-size: 12px;
  font-weight: 580;
  text-decoration: none;
}
.page-nav { min-width: 68px; border: 1px solid var(--line); }
.page-nav:hover,
.page-number:hover { color: var(--ink); background: var(--wash); }
.page-number.is-current { color: white; background: var(--ink); }
.page-nav.is-disabled { color: #adb0b2; }
.page-ellipsis { min-width: 22px; padding-inline: 3px; color: var(--quiet); }

.site-footer {
  margin-top: auto;
  border-top: 1px solid var(--line);
  color: var(--quiet);
  background: rgba(255,255,255,.78);
}
.footer-inner {
  width: min(1040px, calc(100% - 40px));
  min-height: 58px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  font-size: 11px;
}
.footer-inner > span:first-child { flex: 0 0 auto; white-space: nowrap; }
.footer-inner > span:last-child { text-align: right; }

@media (max-width: 850px) and (min-width: 561px) {
  .tool-card {
    grid-template-columns: minmax(0, 1fr) 145px 72px;
    column-gap: 14px;
  }
}

@media (max-width: 760px) {
  .header-inner,
  .site-main,
  .footer-inner { width: min(100% - 28px, 1040px); }
  .site-main { padding-top: 32px; }
  .intro { padding-bottom: 27px; }
}

@media (max-width: 560px) {
  nav .nav-visibility--tablet { display: none; }
  .directory-toolbar { padding: 14px 0; align-items: stretch; flex-direction: column; gap: 12px; }
  .directory-search { width: 100%; }
  .tool-card {
    min-height: 0;
    padding: 10px 11px;
    grid-template-columns: minmax(0, 1fr) auto;
    column-gap: 16px;
    row-gap: 5px;
  }
  .tool-primary { grid-column: 1; grid-row: 1; }
  .tool-creators { grid-column: 1; grid-row: 2; }
  .tool-meta { grid-column: 2; grid-row: 1 / span 2; justify-items: end; }
}

@media (max-width: 440px) {
  .site-header { height: 54px; }
  .brand { width: 145px; }
  nav { gap: 16px; }
  .site-main { padding-top: 28px; padding-bottom: 48px; }
  .intro h1 { font-size: 28px; }
  .about-copy { font-size: 13px; }
  .tool-primary { flex-wrap: wrap; row-gap: 2px; white-space: normal; }
  .tool-description { flex-basis: 100%; white-space: normal; }
  .page-numbers { display: none; }
  .footer-inner { min-height: 66px; align-items: flex-start; justify-content: center; flex-direction: column; gap: 2px; }
  .footer-inner > span:last-child { text-align: left; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; }
}
