/* Single dark catalog theme. No external fonts, no CDNs. */
:root {
  --bg: #0e1116;
  --bg2: #151a22;
  --card: #1a212c;
  --line: #262f3d;
  --text: #d7dee8;
  --muted: #8b98a9;
  --accent: #5b8cff;
  --accent2: #8ab4ff;
  --ok: #4cc38a;
}
* { box-sizing: border-box; }
html { color-scheme: dark; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.6 system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
  /* Sticky footer: short pages (about, 404) pin the footer to the bottom. */
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}
/* Sticky footer: short pages (about, 404) pin the footer to the bottom.
   width:100% keeps .wrap at its max-width — auto margins alone would turn
   the flex item fit-content and shrink the whole page column. */
main.wrap { flex: 1 0 auto; width: 100%; padding-top: 30px; padding-bottom: 56px; min-height: 62vh; }
::selection { background: rgba(91, 140, 255, .35); }
a { color: var(--accent2); text-decoration: none; }
a:hover { text-decoration: underline; }
a:focus-visible, .btn:focus-visible, .chip:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: 4px;
}
.wrap { max-width: 1080px; margin: 0 auto; padding: 0 20px; }
h1 { font-size: 1.85rem; line-height: 1.25; margin: 8px 0 6px; letter-spacing: -0.01em; }
h2 { font-size: 1.25rem; margin: 38px 0 14px; color: var(--heading, #fff); letter-spacing: -0.01em; }
p { margin: 10px 0; }
.lead { color: var(--muted); font-size: 1.05rem; max-width: 72ch; }
.byline { color: var(--muted); margin-top: 0; }
.crumbs { color: var(--muted); font-size: .85rem; margin-bottom: 12px; }
.crumbs a, .byline a { text-decoration: underline; text-underline-offset: 2px; text-decoration-color: rgba(138, 180, 255, .55); }
.crumbs a:hover, .byline a:hover { text-decoration-color: currentColor; }
.crumbs span { color: var(--text); }

/* header */
.site-head { border-bottom: 1px solid var(--line); background: var(--bg2); position: sticky; top: 0; z-index: 5; box-shadow: 0 1px 12px rgba(0, 0, 0, .35); }
.head-in { display: flex; align-items: center; justify-content: space-between; height: 56px; gap: 12px; }
.brand { font-weight: 700; color: var(--heading, #fff); font-size: 1.05rem; white-space: nowrap; }
.site-head nav { display: flex; gap: 18px; }
.site-head nav a { color: var(--muted); font-size: .92rem; white-space: nowrap; }
.site-head nav a:hover { color: var(--heading, #fff); text-decoration: none; }

/* footer */
.site-foot { border-top: 1px solid var(--line); background: var(--bg2); color: var(--muted); font-size: .88rem; }
.site-foot .wrap { display: flex; justify-content: space-between; align-items: center; padding-top: 18px; padding-bottom: 18px; gap: 12px; flex-wrap: wrap; }
.site-foot nav { display: flex; gap: 16px; flex-wrap: wrap; }

/* stats + tiles */
.statrow { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 14px; margin: 24px 0; }
.stat { background: var(--card); border: 1px solid var(--line); border-radius: 10px; padding: 14px 16px; }
.stat b { display: block; font-size: 1.6rem; line-height: 1.2; color: var(--heading, #fff); }
.stat span { color: var(--muted); font-size: .85rem; }
.tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 14px; margin: 16px 0; }
.tile { background: var(--card); border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px; color: var(--text); display: flex; flex-direction: column; gap: 3px; transition: border-color .15s ease, transform .15s ease; }
.tile:hover { border-color: var(--accent); text-decoration: none; transform: translateY(-1px); }
.tile b { color: var(--heading, #fff); }
.tile span { color: var(--muted); font-size: .85rem; }

/* cards */
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 14px; margin: 16px 0; }
.card { background: var(--card); border: 1px solid var(--line); border-radius: 10px; padding: 14px 16px; color: var(--text); display: flex; flex-direction: column; gap: 7px; position: relative; transition: border-color .15s ease, transform .15s ease, box-shadow .15s ease; }
.card:hover { border-color: var(--accent); text-decoration: none; transform: translateY(-2px); box-shadow: 0 6px 18px rgba(0, 0, 0, .3); }
.card-top { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.card-name { font-weight: 650; color: var(--heading, #fff); text-decoration: none; }
/* Stretched link: the title anchor covers the whole card as a click target.
   Chips stay clickable above it via their own stacking context. */
.card-name::after { content: ""; position: absolute; inset: 0; z-index: 0; }
.card-name:hover { text-decoration: none; }
.card:focus-within { border-color: var(--accent); }
.card-ver { color: var(--muted); font-size: .78rem; white-space: nowrap; }
.card-short { color: var(--muted); font-size: .9rem; }
.card-meta { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin-top: auto; }
.card-meta .dev { color: var(--muted); font-size: .78rem; margin-left: auto; }
.chip { position: relative; z-index: 1; background: var(--chip, #223052); border-radius: 20px; padding: 2px 10px; font-size: .74rem; color: var(--accent2); }
.chip:hover { background: var(--chip-hover, #2b3d6b); text-decoration: none; }

/* entity photo: a small thumbnail floated into the top of the page, credit
   line muted under it (attribution, not a featured image) */
.entity-photo { float: right; margin: 4px 0 14px 24px; max-width: 320px; }
.entity-photo img { display: block; max-width: 100%; height: auto; border: 1px solid var(--line); border-radius: 10px; }
.entity-photo figcaption { color: var(--muted); font-size: .78rem; margin-top: 5px; line-height: 1.45; }

/* table */
.glance { border-collapse: collapse; width: 100%; max-width: 640px; margin: 8px 0; font-size: .95rem; }
.glance th, .glance td { text-align: left; padding: 9px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
.glance th { color: var(--muted); font-weight: 500; white-space: nowrap; width: 120px; }

/* buttons + cta */
/* #3d6fe0 keeps white button text at 4.6:1; the lighter --accent (3.2:1) stays for borders and focus rings */
.btn { display: inline-block; background: var(--btn, #3d6fe0); color: #fff; font-weight: 650; padding: 11px 22px; border-radius: 9px; box-shadow: 0 2px 10px rgba(91, 140, 255, .25); transition: background .15s ease, transform .15s ease; }
.btn:hover { background: var(--accent2); color: var(--btn-text, #0b1020); text-decoration: none; transform: translateY(-1px); }
.cta-row { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; margin: 18px 0; }
.cta-note { color: var(--muted); font-size: .88rem; }
.more { font-weight: 600; }

/* facet links above a listing: the same list narrowed by one more dimension */
.facets { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 8px 32px; margin: 18px 0 2px; }
.facet h2 { font-size: .78rem; margin: 0 0 2px; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; font-weight: 600; }
.facet p { margin: 0; font-size: .9rem; line-height: 1.9; }
.facet a { text-decoration: none; }
.facet a:hover { text-decoration: underline; }
.facet .n { color: var(--muted); font-size: .8rem; }

/* cross links under an entity's table: the lists this entry is part of */
.related { color: var(--muted); font-size: .92rem; margin: 14px 0 0; line-height: 1.9; }
.related b { color: var(--text); font-weight: 600; }

/* faq: every answer is on the page as text; nothing is folded away */
.faq { border: 1px solid var(--line); border-radius: 9px; background: var(--card); margin: 10px 0; padding: 4px 16px 1px; }
.faq h3 { font-size: 1rem; line-height: 1.4; margin: 10px 0 2px; font-weight: 600; color: var(--heading, #fff); }
.faq p { color: var(--muted); margin: 0 0 12px; }

/* lists */
.bestlist li, .devlist li { margin: 7px 0; }
.bestlist span, .devlist span { color: var(--muted); }
.ltr { border-bottom: 1px solid var(--line); padding-bottom: 4px; }
@media (min-width: 800px) {
  .devlist { columns: 2; column-gap: 40px; }
}
@media (min-width: 1200px) {
  .devlist { columns: 3; }
}

/* pager */
.pager { display: flex; gap: 8px; margin: 26px 0 8px; flex-wrap: wrap; }
.pg { border: 1px solid var(--line); background: var(--card); border-radius: 8px; padding: 7px 13px; color: var(--text); font-size: .9rem; }
.pg:hover { border-color: var(--accent); text-decoration: none; }
.pg.cur { background: var(--accent); color: #fff; border-color: var(--accent); }

/* spotlight landing (config home_layout: "spotlight") — the only layout here
   with its own accent: a violet hero band, pill rows and described category
   cards. Other pages of the same site keep the blue theme. */
.hero { background: linear-gradient(135deg, #181231, #131a26 55%); border: 1px solid #2c2450; border-radius: 16px; padding: 30px 28px 24px; margin: 6px 0 30px; }
.hero h1 { font-size: 2.2rem; margin: 0 0 8px; }
.hero .lead { max-width: 68ch; }
.hero-facts { color: var(--muted); font-size: .92rem; letter-spacing: .01em; margin: 14px 0 4px; }
.pillrow { display: flex; align-items: baseline; flex-wrap: wrap; gap: 8px; margin: 12px 0; }
.pill-label { color: var(--muted); font-size: .9rem; }
.pill { display: inline-block; background: var(--card); border: 1px solid var(--line); border-radius: 20px; padding: 4px 14px; font-size: .85rem; color: var(--text); transition: border-color .15s ease, color .15s ease; }
.pill:hover { border-color: var(--pill-hover-border, #9d7bff); color: var(--heading, #fff); text-decoration: none; }
.ccards { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 14px; margin: 16px 0; }
.ccard { background: var(--card); border: 1px solid var(--line); border-radius: 12px; padding: 16px; display: flex; flex-direction: column; gap: 6px; color: var(--text); transition: border-color .15s ease, transform .15s ease; }
.ccard:hover { border-color: #9d7bff; text-decoration: none; transform: translateY(-1px); }
.ccard b { color: var(--heading, #fff); font-size: 1.02rem; }
.cc-n { color: #b39aff; font-size: .76rem; text-transform: uppercase; letter-spacing: .06em; }
.cc-b { color: var(--muted); font-size: .9rem; line-height: 1.5; }
.uplist { list-style: none; margin: 12px 0; padding: 0; }
.uplist li { display: flex; align-items: baseline; gap: 10px; padding: 9px 2px; border-bottom: 1px solid var(--line); }
.uplist a { font-weight: 600; }
.up-dev { color: var(--muted); font-size: .85rem; margin-left: auto; text-align: right; }
.up-year { color: var(--muted); font-size: .8rem; white-space: nowrap; }
@media (min-width: 900px) {
  .uplist { columns: 2; column-gap: 44px; }
  .uplist li { break-inside: avoid; }
}
@media (max-width: 640px) {
  .hero { padding: 22px 18px 18px; border-radius: 12px; }
  .hero h1 { font-size: 1.6rem; }
}

@media (max-width: 640px) {
  h1 { font-size: 1.45rem; }
  h2 { font-size: 1.15rem; margin-top: 30px; }
  .head-in { gap: 10px; }
  .brand { font-size: .95rem; }
  .site-head nav { gap: 12px; }
  .site-head nav a { font-size: .85rem; }
  .glance th { width: auto; }
  .stat b { font-size: 1.4rem; }
  /* a floated 320px thumbnail leaves no room for text next to it */
  .entity-photo { float: none; margin: 14px 0 4px; }
}
