/* Works With Your Software: site stylesheet.
   Part 1 is tokens.css from the Style Advisor spec, pasted unchanged.
   Part 2 adds fonts, layout and components per spec.md sections 4 to 7. */
@font-face{font-family:"Source Serif 4";src:url("/fonts/source-serif-4.woff2") format("woff2");font-weight:400 600;font-style:normal;font-display:swap}
@font-face{font-family:"Source Sans 3";src:url("/fonts/source-sans-3.woff2") format("woff2");font-weight:400 600;font-style:normal;font-display:swap}
@font-face{font-family:"IBM Plex Mono";src:url("/fonts/ibm-plex-mono-regular.woff2") format("woff2");font-weight:400;font-style:normal;font-display:swap}

/* Works With Your Software
   Design tokens. Mobile first. Pair with spec.md.
   Self-host the fonts in /fonts (SIL OFL 1.1). Do not call the Google Fonts CDN
   in production. Preload at most two weights per face; with these variable
   files, preload one file per face and use only the weights listed. */

:root {
  /* Colour: three brand colours plus neutrals */
  --color-paper: #f3f0ea;
  --color-ink: #1b1916;
  --color-accent: #0f3f4a;
  --color-accent-hover: #0c333c; /* same hue, darker; a hover state, not a fourth brand colour */
  --color-muted: #4f4b46;        /* secondary text, "Not supported" label */
  --color-rule: #88827c;         /* interactive borders, 3:1 on paper and recessed */
  --color-hairline: #d4cfc6;     /* decorative rules only, never text, never input borders */
  --color-recessed: #ede9e2;     /* sponsor bar, table header, badge fill */
  --color-focus: var(--color-accent);

  /* Measured WCAG 2 contrast ratios (see spec.md) */
  /* ink on paper 15.42:1 */
  /* paper on ink 15.42:1 */
  /* accent on paper 10.09:1 */
  /* paper on accent 10.09:1 */
  /* muted on paper 7.61:1 */
  /* muted on recessed 7.15:1 */
  /* accent-hover on paper 11.88:1 */
  /* rule on paper 3.34:1; rule on recessed 3.14:1 */

  /* Type families and roles
     serif  = Source Serif 4, weights 400 and 600: headlines, wordmark, 01 02 03 index
     sans   = Source Sans 3, weights 400 and 600: body, UI, nav, forms, buttons, tables, badges
     mono   = IBM Plex Mono, weight 400 only: dates checked and counts. Do not preload. */
  --font-serif: "Source Serif 4", "Source Serif Pro", Georgia, "Times New Roman", serif;
  --font-sans: "Source Sans 3", "Source Sans Pro", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --font-mono: "IBM Plex Mono", ui-monospace, "Cascadia Mono", "Segoe UI Mono", Menlo, monospace;

  --font-weight-regular: 400;
  --font-weight-semibold: 600;

  /* Type scale, mobile. Root 16px. Line heights are unitless. */
  --step-eyebrow: 0.75rem;     /* 12px */
  --step-meta: 0.8125rem;      /* 13px, dates and counts */
  --step-small: 0.875rem;      /* 14px */
  --step-body: 1.0625rem;      /* 17px */
  --step-h3: 1.25rem;          /* 20px */
  --step-h2: 1.5rem;           /* 24px */
  --step-h1: 2rem;             /* 32px */
  --step-display: 2.25rem;     /* 36px, home hero only */

  --line-eyebrow: 1.3;
  --line-meta: 1.45;
  --line-small: 1.5;
  --line-body: 1.6;
  --line-h3: 1.3;
  --line-h2: 1.25;
  --line-h1: 1.2;
  --line-display: 1.15;

  --track-eyebrow: 0.18em;
  --measure-prose: 38rem;
  --measure-content: 72rem;

  /* Spacing scale */
  --space-1: 0.25rem;  /* 4 */
  --space-2: 0.5rem;   /* 8 */
  --space-3: 0.75rem;  /* 12 */
  --space-4: 1rem;     /* 16 */
  --space-5: 1.5rem;   /* 24 */
  --space-6: 2rem;     /* 32 */
  --space-7: 3rem;     /* 48 */
  --space-8: 4rem;     /* 64 */
  --space-9: 6rem;     /* 96 */
  --space-10: 8rem;    /* 128 */

  --pad-section: 4rem;
  --pad-page-x: 1.25rem;
  --grid-gutter: 1rem;

  --tap: 2.75rem;      /* 44px minimum */
  --radius: 0;
  --duration: 200ms;
  --easing: ease;
  --header-max: 4.5rem; /* keep header + sponsor bar from eating the fold */

  --bp-sm: 40rem;  /* 640px, tables may become tables */
  --bp-md: 48rem;  /* 768px */
  --bp-lg: 64rem;  /* 1024px */
  --bp-xl: 80rem;  /* 1280px */
}

@media (min-width: 48rem) {
  :root {
    --step-body: 1.125rem;   /* 18px */
    --step-h3: 1.375rem;     /* 22px */
    --step-h2: 2rem;         /* 32px */
    --step-h1: 2.75rem;      /* 44px */
    --step-display: 3rem;    /* 48px */
    --pad-section: 6rem;
    --pad-page-x: 2rem;
    --grid-gutter: 1.5rem;
  }
}

@media (min-width: 64rem) {
  :root {
    --pad-page-x: 3rem;
  }
}

/* Global typography defaults */
html {
  font-family: var(--font-sans);
  font-weight: var(--font-weight-regular);
  font-size: 100%;
  color: var(--color-ink);
  background: var(--color-paper);
  line-height: var(--line-body);
  font-synthesis: none;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

body {
  font-size: var(--step-body);
  max-width: none;
  margin: 0;
}

h1, h2, h3 {
  font-family: var(--font-serif);
  font-weight: var(--font-weight-semibold);
  font-optical-sizing: auto;
  text-wrap: balance;
}

h1 { font-size: var(--step-h1); line-height: var(--line-h1); }
h2 { font-size: var(--step-h2); line-height: var(--line-h2); }
h3 { font-size: var(--step-h3); line-height: var(--line-h3); }

.display {
  font-family: var(--font-serif);
  font-weight: var(--font-weight-semibold);
  font-size: var(--step-display);
  line-height: var(--line-display);
  font-optical-sizing: auto;
}

.eyebrow {
  font-family: var(--font-sans);
  font-weight: var(--font-weight-semibold);
  font-size: var(--step-eyebrow);
  line-height: var(--line-eyebrow);
  letter-spacing: var(--track-eyebrow);
  text-transform: uppercase;
  font-variant-caps: all-small-caps;
}

.meta, time, .count {
  font-family: var(--font-mono);
  font-size: var(--step-meta);
  line-height: var(--line-meta);
  font-weight: var(--font-weight-regular);
  font-variant-numeric: tabular-nums;
}

p, li {
  max-width: var(--measure-prose);
}

/* Links and focus. Accent is reserved for links and the primary button. */
a {
  color: var(--color-accent);
  text-decoration: underline;
  text-underline-offset: 0.15em;
  text-decoration-thickness: 1px;
}

a:hover {
  color: var(--color-accent-hover);
  text-decoration-thickness: 2px;
}

nav a {
  color: var(--color-ink);
  text-decoration: none;
}

nav a:hover,
nav a[aria-current="page"] {
  text-decoration: underline;
  text-decoration-thickness: 1px;
  color: var(--color-ink);
}

:focus-visible {
  outline: 2px solid var(--color-focus);
  outline-offset: 2px;
}

/* Motion */
@media (prefers-reduced-motion: no-preference) {
  a, button, input, select, textarea, .sponsor-bar {
    transition: color var(--duration) var(--easing),
                background-color var(--duration) var(--easing),
                border-color var(--duration) var(--easing),
                text-decoration-thickness var(--duration) var(--easing),
                opacity var(--duration) var(--easing);
  }
}

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

/* Buttons */
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: var(--tap);
  padding: 0 var(--space-5);
  font-family: var(--font-sans);
  font-size: var(--step-body);
  font-weight: var(--font-weight-semibold);
  line-height: 1;
  text-decoration: none;
  border: 1px solid transparent;
  border-radius: var(--radius);
  cursor: pointer;
  color: var(--color-paper);
  background: var(--color-accent);
}

.button:hover {
  background: var(--color-accent-hover);
  color: var(--color-paper);
}

.button-secondary {
  color: var(--color-ink);
  background: transparent;
  border-color: var(--color-ink);
}

.button-secondary:hover {
  background: var(--color-recessed);
  color: var(--color-ink);
}

/* Forms */
label {
  display: block;
  font-weight: var(--font-weight-semibold);
  margin-bottom: var(--space-2);
}

input[type="text"],
input[type="email"],
input[type="search"],
input[type="url"],
select,
textarea {
  width: 100%;
  min-height: var(--tap);
  padding: var(--space-3) var(--space-4);
  font: inherit;
  color: var(--color-ink);
  background: var(--color-paper);
  border: 1px solid var(--color-rule);
  border-radius: var(--radius);
}

textarea {
  min-height: 8rem;
  line-height: var(--line-body);
}

input:user-invalid,
select:user-invalid,
textarea:user-invalid,
[aria-invalid="true"] {
  border-width: 2px;
  border-color: var(--color-ink);
}

.field-error {
  color: var(--color-ink);
  font-size: var(--step-small);
  margin-top: var(--space-2);
}

/* Ordered editorial index: keep a real <ol> */
ol.index {
  list-style: none;
  margin: 0;
  padding: 0;
  counter-reset: index;
}

ol.index > li {
  counter-increment: index;
  padding-left: 3.5rem;
  position: relative;
  margin-bottom: var(--space-5);
  max-width: var(--measure-prose);
}

ol.index > li::before {
  content: counter(index, decimal-leading-zero);
  position: absolute;
  left: 0;
  top: 0;
  font-family: var(--font-serif);
  font-weight: var(--font-weight-semibold);
  font-variant-numeric: tabular-nums;
  color: var(--color-ink);
  font-size: var(--step-h3);
  line-height: var(--line-h3);
}

/* ===== Part 2: layout and components ===== */
*,*::before,*::after{box-sizing:border-box}
html{-webkit-text-size-adjust:100%}
h1,h2,h3{margin:0 0 var(--space-4);color:var(--color-ink)}
p{margin:0 0 var(--space-4)}
ul,ol{margin:0 0 var(--space-4)}
img{max-width:100%;height:auto;display:block}
.visually-hidden{position:absolute!important;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}
.skip{position:absolute;left:-9999px;top:0;background:var(--color-paper);padding:var(--space-3) var(--space-4);z-index:10}
.skip:focus{left:var(--space-2);top:var(--space-2)}
.muted{color:var(--color-muted)}
.small{font-size:var(--step-small);line-height:var(--line-small)}
.deck{font-family:var(--font-serif);font-weight:var(--font-weight-regular);font-optical-sizing:auto}
[hidden]{display:none!important}

/* shell and grid: 4 / 8 / 12 columns */
.shell{max-width:var(--measure-content);margin:0 auto;padding-left:var(--pad-page-x);padding-right:var(--pad-page-x)}
.section{padding-top:var(--pad-section);padding-bottom:0}
.section:last-child{padding-bottom:var(--pad-section)}
.section-tight{padding-top:var(--space-7)}
.prose{max-width:var(--measure-prose)}
.grid-12{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:var(--grid-gutter)}
@media (min-width:48rem){.grid-12{grid-template-columns:repeat(8,minmax(0,1fr))}}
@media (min-width:64rem){.grid-12{grid-template-columns:repeat(12,minmax(0,1fr))}}

/* header */
.site-header{background:var(--color-paper);border-bottom:1px solid var(--color-hairline)}
.site-header .shell{display:flex;align-items:center;justify-content:space-between;gap:var(--space-4);min-height:var(--header-max);padding-top:var(--space-2);padding-bottom:var(--space-2);flex-wrap:wrap}
.site-name{font-family:var(--font-serif);font-weight:var(--font-weight-semibold);font-optical-sizing:auto;font-size:1.25rem;line-height:1;color:var(--color-ink);text-decoration:none;display:inline-block;padding:var(--space-1) 0}
.site-name span{display:block}
.site-name:hover{color:var(--color-ink);text-decoration:none}
.menu-button{display:none}
.js .menu-button{display:inline-flex;align-items:center}
.menu-button{min-height:var(--tap);min-width:var(--tap);padding:0 var(--space-4);font:inherit;font-weight:var(--font-weight-semibold);color:var(--color-ink);background:transparent;border:1px solid var(--color-ink);border-radius:var(--radius);cursor:pointer}
.site-nav{width:100%}
.js .site-nav{display:none}
.js .site-nav.open{display:block}
.filters-toggle{display:none}
.js .filters-toggle{display:inline-flex}
.js .filter-panel{display:none}
.js .filter-panel.open{display:flex}
.site-nav ul{list-style:none;margin:0;padding:0 0 var(--space-3);display:flex;flex-direction:column}
.site-nav li{max-width:none}
.site-nav a{display:flex;align-items:center;min-height:var(--tap)}
.site-nav a.text-link{color:var(--color-accent);text-decoration:underline;text-underline-offset:.15em}
@media (min-width:48rem){
  .js .menu-button{display:none}
  .site-nav,.js .site-nav{width:auto;display:block}
  .site-nav ul{flex-direction:row;gap:var(--space-5);padding:0}
}

/* sponsor bar: slim strip under the header, scrolls away */
.sponsor-bar{background:var(--color-recessed);border-bottom:1px solid var(--color-hairline);color:var(--color-ink)}
.sponsor-bar .shell{display:flex;align-items:center;gap:var(--space-3);max-height:48px;min-height:var(--tap)}
.sponsor-bar .eyebrow{flex:none;color:var(--color-ink)}
.sponsor-bar .sponsor-text{flex:1 1 auto;min-width:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;font-size:var(--step-small);line-height:var(--line-small)}
.sponsor-close{flex:none;min-height:var(--tap);min-width:var(--tap);background:transparent;border:0;border-radius:var(--radius);font:inherit;font-size:var(--step-small);font-weight:var(--font-weight-semibold);color:var(--color-ink);cursor:pointer}
.sponsor-close .when-wide{display:none}
@media (min-width:48rem){.sponsor-bar .shell{max-height:44px}.sponsor-close .when-wide{display:inline}.sponsor-close .when-narrow{display:none}}

/* hero */
.hero{padding-top:var(--space-7);padding-bottom:0}
@media (min-width:48rem){.hero{padding-top:var(--space-9)}}
@media (min-width:64rem){.hero{padding-top:var(--space-10)}}
.hero .display{max-width:22ch;margin:0 0 var(--space-4)}
.hero p{max-width:var(--measure-prose)}
.page-head{padding-top:var(--space-6)}
@media (min-width:48rem){.page-head{padding-top:var(--space-7)}}
.page-head h1{max-width:24ch}
.crumbs{font-size:var(--step-small);color:var(--color-muted);margin-bottom:var(--space-3)}
.crumbs a{color:var(--color-muted)}

/* search and filters */
.search-form{max-width:var(--measure-prose);margin-top:var(--space-5)}
.search-row{display:flex;gap:var(--space-2)}
.search-row input{flex:1 1 auto;min-width:0}
.filters-toggle{margin-top:var(--space-4)}
.filters{border:0;margin:var(--space-4) 0 0;padding:0}
.filter-panel{display:flex;flex-direction:column;gap:var(--space-4);margin-top:var(--space-4)}
@media (min-width:48rem){.js .filters-toggle{display:none}.filter-panel,.js .filter-panel{display:flex;flex-direction:row;flex-wrap:wrap;align-items:flex-end;gap:var(--space-5)}}
.filter-panel select{width:auto;min-width:14rem}
fieldset{border:0;margin:0;padding:0;min-width:0}
legend{font-weight:var(--font-weight-semibold);padding:0;margin-bottom:var(--space-2)}
.choice-row{display:flex;flex-wrap:wrap;gap:0 var(--space-4)}
.choice{display:inline-flex;align-items:center;gap:var(--space-2);min-height:var(--tap);font-weight:var(--font-weight-regular);margin:0;cursor:pointer}
.choice input{width:1.125rem;height:1.125rem;margin:0;accent-color:var(--color-ink)}
.clear-link{display:inline-flex;align-items:center;min-height:var(--tap)}
.result-summary{margin:var(--space-5) 0 var(--space-4);color:var(--color-muted);font-size:var(--step-small)}

/* status badges: text label plus a shape, no accent, no traffic lights */
.badge{display:inline-flex;align-items:center;gap:.4em;background:var(--color-recessed);color:var(--color-ink);font-family:var(--font-sans);font-weight:var(--font-weight-semibold);font-size:.875rem;line-height:1.3;padding:.2em .55em;white-space:nowrap;border-radius:0}
.badge.none{color:var(--color-muted)}
.shape{display:inline-block;width:.5em;height:.5em;flex:none}
.shape.live{background:var(--color-ink);border-radius:50%}
.shape.custom{border:1.5px solid var(--color-ink)}
.shape.none{border:1.5px solid var(--color-muted);border-radius:50%}
.key{list-style:none;padding:0;margin:var(--space-4) 0 var(--space-2)}
.key li{margin-bottom:var(--space-2);max-width:var(--measure-prose);font-size:var(--step-small);line-height:var(--line-small)}
.key li .badge{margin-right:var(--space-2)}
@media (min-width:64rem){.key{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:var(--grid-gutter)}.key li{margin:0}}

/* software tiles: typographic, no logos */
.tiles{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:var(--grid-gutter);margin-top:var(--space-5)}
@media (min-width:48rem){.tiles{grid-template-columns:repeat(3,minmax(0,1fr))}}
@media (min-width:64rem){.tiles{grid-template-columns:repeat(4,minmax(0,1fr))}}
.tile{display:flex;flex-direction:column;gap:var(--space-2);border:1px solid var(--color-rule);background:var(--color-paper);padding:var(--space-5);text-decoration:none;color:var(--color-ink);min-height:var(--tap)}
.tile:hover{border-color:var(--color-ink);color:var(--color-ink)}
.tile:hover .tile-name{text-decoration:underline;text-decoration-thickness:1px;text-underline-offset:.15em}
.tile-name{font-family:var(--font-serif);font-weight:var(--font-weight-semibold);font-optical-sizing:auto;font-size:var(--step-h3);line-height:var(--line-h3);margin:0}
.tile-desc{font-size:var(--step-small);line-height:var(--line-small);color:var(--color-muted);margin:0}
.vendor-tiles .tile-name{font-size:var(--step-body)}

/* connection table: cards below 40rem, table from 40rem */
.conn{width:100%;border-collapse:collapse;margin-top:var(--space-4);display:block}
.conn tbody{display:block}
.conn caption{text-align:left;font-size:var(--step-small);color:var(--color-muted);padding-bottom:var(--space-3)}
.conn thead{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0,0,0,0)}
.conn tr{display:block;border-top:1px solid var(--color-hairline);padding:var(--space-4) 0}
.conn tbody tr:last-child{border-bottom:1px solid var(--color-hairline)}
.conn td{display:block;padding:var(--space-1) 0;max-width:var(--measure-prose)}
.conn td.lead{display:flex;flex-wrap:wrap;align-items:center;gap:var(--space-2) var(--space-3);padding-bottom:var(--space-2)}
.conn td.status-cell{display:none}
.conn .lead .badge-inline{display:inline-flex}
.conn td[data-label]::before{content:attr(data-label);display:block;font-weight:var(--font-weight-semibold);font-size:var(--step-eyebrow);line-height:var(--line-eyebrow);letter-spacing:var(--track-eyebrow);text-transform:uppercase;color:var(--color-muted);margin-bottom:2px}
.conn .name{font-weight:var(--font-weight-semibold)}
.conn .note{display:block;font-size:var(--step-small);line-height:var(--line-small);color:var(--color-muted);margin-top:var(--space-1)}
@media (min-width:40rem){
  .conn{display:table}
  .conn tbody{display:table-row-group}
  .conn thead{position:static;width:auto;height:auto;overflow:visible;clip:auto;display:table-header-group}
  .conn tr{display:table-row;padding:0;border:0}
  .conn th{text-align:left;background:var(--color-recessed);color:var(--color-ink);font-weight:var(--font-weight-semibold);font-size:var(--step-small);padding:var(--space-3);vertical-align:bottom}
  .conn td{display:table-cell;padding:var(--space-3);border-bottom:1px solid var(--color-hairline);vertical-align:top;max-width:none;font-size:var(--step-small);line-height:var(--line-small)}
  .conn td.lead{display:table-cell}
  .conn td.status-cell{display:table-cell}
  .conn .lead .badge-inline{display:none}
  .conn td[data-label]::before{display:none}
  .conn tbody tr:hover{background:rgba(237,233,226,.5)}
  .conn tbody tr:last-child{border:0}
}

/* boxes */
.sponsored-slot{border:1px solid var(--color-rule);padding:var(--space-4) var(--space-5);margin-top:var(--space-5);max-width:var(--measure-prose)}
.sponsored-slot .eyebrow{display:block;margin-bottom:var(--space-2)}
.sponsored-slot p{margin:0}
.recessed{background:var(--color-recessed);padding:var(--space-5)}
.rule-top{border-top:1px solid var(--color-hairline)}
.plain-list{padding-left:1.1em}
.plain-list li{margin-bottom:var(--space-2)}
.recent{list-style:none;padding:0;margin:var(--space-5) 0 0}
.recent li{border-top:1px solid var(--color-hairline);padding:var(--space-3) 0;max-width:none;display:flex;flex-wrap:wrap;gap:var(--space-1) var(--space-3);align-items:baseline}
.recent li:last-child{border-bottom:1px solid var(--color-hairline)}

/* forms */
.form{max-width:var(--measure-prose)}
.field{margin-bottom:var(--space-5)}
.help{font-size:var(--step-small);line-height:var(--line-small);color:var(--color-muted);margin:var(--space-1) 0 var(--space-2)}
.field-error{display:block}
.form-status{margin-top:var(--space-4);font-size:var(--step-body);max-width:var(--measure-prose)}
.privacy{font-size:var(--step-small);color:var(--color-muted);margin-top:var(--space-3)}
.inline-form .row{display:flex;flex-wrap:wrap;gap:var(--space-2)}
.inline-form input[type=email]{flex:1 1 16rem;width:auto}
.hp{position:absolute;left:-9999px;width:1px;height:1px;overflow:hidden}
.button[aria-disabled="true"],.button:disabled{background:var(--color-recessed);color:var(--color-muted);border-color:var(--color-rule);pointer-events:none}
.checks{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:0 var(--space-4)}
@media (min-width:48rem){.checks{grid-template-columns:repeat(3,minmax(0,1fr))}}

/* footer */
.site-footer{border-top:1px solid var(--color-hairline);margin-top:var(--pad-section);padding:var(--space-7) 0}
.site-footer .footer-name{font-family:var(--font-serif);font-weight:var(--font-weight-semibold);font-optical-sizing:auto;font-size:var(--step-h3);line-height:1;margin:0 0 var(--space-4)}
.site-footer ul{list-style:none;padding:0;margin:0 0 var(--space-4);display:flex;flex-wrap:wrap;gap:0 var(--space-5)}
.site-footer li a{display:inline-flex;align-items:center;min-height:var(--tap)}
.site-footer p{font-size:var(--step-small);color:var(--color-muted)}
.conn time{white-space:nowrap}
@media (min-width:40rem){.conn td.lead{min-width:9rem}.conn td.status-cell{white-space:nowrap}}
