/* =============================================================================
   akk.nl — site.css
   Stichting AKK (Agro Keten Kennis) — archief 1994–2008

   Concept: "de leeszaal" — a calm, scholarly reading room for chain knowledge.
   Paper-white surfaces, deep green ink, one thin yellow rule as the brand's
   signature. Serif headings (Source Serif 4) for authority, a humanist sans
   (Source Sans 3) with tabular figures for dense record lists.

   Table of contents
   0. Fonts
   1. Tokens (custom properties)
   2. Reset & base
   3. Typography
   4. Layout primitives (.container, .grid, .stack, .cluster)
   5. Header, navigation, site search
   6. Footer
   7. Buttons & links
   8. Forms (fields, selects, checkboxes)
   9. Small components: badge, tag, chip, code, mark, kbd
  10. Page header, breadcrumb, lede
  11. Home: hero search, stats, entry cards, contact
  12. Database pages: filters, toolbar, result list, pagination
  13. Detail page: section nav, definition list, knowledge entries, publications
  14. Ketenkennis overview
  15. Global search results
  16. Prose (legacy 2007 HTML)
  17. Notices, empty states, 404
  18. Utilities
  19. Motion & print
   ========================================================================== */


/* ---------------------------------------------------------------------------
   0. Fonts (self-hosted, latin subset, OFL — see fonts/LICENSE-*.txt)
   Source Sans 3 upright is a variable font: one file serves 400 and 600.
   -------------------------------------------------------------------------- */
@font-face {
  font-family: "Source Sans 3";
  font-style: normal;
  font-weight: 200 900;
  font-display: swap;
  src: url("../fonts/source-sans-3-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Source Sans 3";
  font-style: italic;
  font-weight: 200 900;
  font-display: swap;
  src: url("../fonts/source-sans-3-italic-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "Source Serif 4";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("../fonts/source-serif-4-600-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}


/* ---------------------------------------------------------------------------
   1. Tokens
   Contrast (on --c-paper #FAFAF7): ink 14.3:1 · ink-muted 6.1:1 · green-700 5.8:1
   White on green-900: 12.3:1 · yellow on green-900: 8.5:1 (header focus ring)
   -------------------------------------------------------------------------- */
:root {
  /* colour */
  --c-green-900: #1E3814;   /* header band, footer, wordmark */
  --c-green-800: #2F5420;   /* hover/active text, strong borders */
  --c-green-700: #3F6E27;   /* links, headings, primary buttons (AA on paper) */
  --c-green-500: #5A943C;   /* brand green: decoration, large text, mark */
  --c-green-300: #A9CB92;   /* subtle lines on dark */
  --c-green-100: #E6EFDD;   /* tinted surfaces */
  --c-green-50:  #F3F7EE;   /* hover rows, chips */
  --c-yellow:     #FFCC00;  /* the signature rule, active nav, mark border */
  --c-yellow-100: #FFF0B3;  /* <mark> highlight */
  --c-ink:        #1F2A1C;
  --c-ink-muted:  #5A6256;
  --c-paper:      #FAFAF7;  /* page background */
  --c-surface:    #FFFFFF;  /* cards, inputs */
  --c-line:       #DDE2D8;
  --c-line-strong:#B9C2B2;
  --c-danger:     #9B2C2C;

  /* type */
  --ff-sans: "Source Sans 3", "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --ff-serif: "Source Serif 4", Georgia, "Times New Roman", serif;
  --ff-mono: ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;

  --fs-xs: 0.8125rem;   /* 13px */
  --fs-sm: 0.9375rem;   /* 15px */
  --fs-base: 1.0625rem; /* 17px */
  --fs-md: 1.1875rem;   /* 19px */
  --fs-lg: clamp(1.25rem, 1.05rem + 0.8vw, 1.5rem);
  --fs-xl: clamp(1.5rem, 1.2rem + 1.2vw, 1.875rem);
  --fs-2xl: clamp(1.875rem, 1.4rem + 2vw, 2.625rem);
  --fs-display: clamp(2.25rem, 1.5rem + 3vw, 3.5rem);

  --lh-tight: 1.2;
  --lh-snug: 1.35;
  --lh-base: 1.55;

  /* space (4px base) */
  --sp-1: 0.25rem;
  --sp-2: 0.5rem;
  --sp-3: 0.75rem;
  --sp-4: 1rem;
  --sp-5: 1.5rem;
  --sp-6: 2rem;
  --sp-7: 3rem;
  --sp-8: 4rem;

  /* shape & layout */
  --radius-sm: 3px;
  --radius: 6px;
  --radius-lg: 10px;
  --container: 72rem;      /* 1152px */
  --measure: 42rem;        /* comfortable reading width */
  --gutter: clamp(1rem, 4vw, 2rem);
  --tap: 2.75rem;          /* 44px minimum target */

  --shadow-sm: 0 1px 2px rgba(31, 42, 28, 0.06), 0 1px 1px rgba(31, 42, 28, 0.04);
  --focus: 0 0 0 2px var(--c-paper), 0 0 0 4px var(--c-green-700);
}


/* ---------------------------------------------------------------------------
   2. Reset & base
   -------------------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }

html {
  font-size: 100%;
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: var(--sp-6);
}

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background: var(--c-paper);
  color: var(--c-ink);
  font-family: var(--ff-sans);
  font-size: var(--fs-base);
  line-height: var(--lh-base);
  font-variant-numeric: tabular-nums; /* numbers align in record lists */
  -webkit-font-smoothing: antialiased;
}

main { flex: 1 0 auto; }

img, svg { display: block; max-width: 100%; height: auto; }

a {
  color: var(--c-green-700);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.14em;
}
a:hover { color: var(--c-green-800); text-decoration-thickness: 2px; }

:focus-visible {
  outline: none;
  box-shadow: var(--focus);
  border-radius: var(--radius-sm);
}

hr { border: 0; border-top: 1px solid var(--c-line); margin: var(--sp-6) 0; }

table { border-collapse: collapse; width: 100%; }

button, input, select, textarea { font: inherit; color: inherit; }

::selection { background: var(--c-yellow-100); color: var(--c-ink); }


/* ---------------------------------------------------------------------------
   3. Typography
   -------------------------------------------------------------------------- */
h1, h2, h3, h4 {
  margin: 0 0 var(--sp-3);
  color: var(--c-green-900);
  line-height: var(--lh-tight);
  text-wrap: balance;
  overflow-wrap: break-word;
}
h1 { font: 600 var(--fs-2xl)/var(--lh-tight) var(--ff-serif); letter-spacing: -0.01em; }
h2 { font: 600 var(--fs-xl)/var(--lh-tight) var(--ff-serif); }
h3 { font: 600 var(--fs-md)/var(--lh-snug) var(--ff-sans); }
h4 { font: 600 var(--fs-base)/var(--lh-snug) var(--ff-sans); }

p, ul, ol, dl { margin: 0 0 var(--sp-4); }

small, .text-sm { font-size: var(--fs-sm); }
.text-xs { font-size: var(--fs-xs); }
.text-muted { color: var(--c-ink-muted); }

.lede {
  font-size: var(--fs-md);
  line-height: var(--lh-snug);
  color: var(--c-ink);
  max-width: var(--measure);
}

.overline {
  display: block;
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--c-ink-muted);
  margin-bottom: var(--sp-2);
}

.num { font-variant-numeric: tabular-nums; }


/* ---------------------------------------------------------------------------
   4. Layout primitives
   -------------------------------------------------------------------------- */
.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: var(--gutter);
}
.container--narrow { max-width: 52rem; }

.section { padding-block: var(--sp-6); }
.section + .section { border-top: 1px solid var(--c-line); }

.stack > * + * { margin-top: var(--sp-4); }
.stack--lg > * + * { margin-top: var(--sp-6); }

.cluster { display: flex; flex-wrap: wrap; gap: var(--sp-2) var(--sp-3); align-items: center; }

.grid { display: grid; gap: var(--sp-5); }
.grid--2 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 18rem), 1fr)); }
.grid--3 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 15rem), 1fr)); }
.grid--4 { grid-template-columns: repeat(auto-fit, minmax(min(100%, 11rem), 1fr)); }

/* Two-column archive layout: sticky filter rail + results */
.layout-sidebar {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--sp-6);
  align-items: start;
}
@media (min-width: 56rem) {
  .layout-sidebar { grid-template-columns: 17rem minmax(0, 1fr); }
  .layout-sidebar > aside { position: sticky; top: var(--sp-4); }
}

/* Detail page: content + narrow meta rail */
.layout-detail {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: var(--sp-6);
  align-items: start;
}
@media (min-width: 60rem) {
  .layout-detail { grid-template-columns: minmax(0, 1fr) 16rem; }
  .layout-detail > aside { position: sticky; top: var(--sp-4); }
}


/* ---------------------------------------------------------------------------
   5. Header, navigation, site search
   -------------------------------------------------------------------------- */
.skip-link {
  position: absolute;
  left: var(--sp-4);
  top: -100%;
  z-index: 100;
  padding: var(--sp-2) var(--sp-4);
  background: var(--c-yellow);
  color: var(--c-ink);
  font-weight: 600;
  border-radius: 0 0 var(--radius) var(--radius);
}
.skip-link:focus { top: 0; box-shadow: var(--focus); }

.site-header {
  background: var(--c-green-900);
  color: #fff;
  border-bottom: 4px solid var(--c-yellow);   /* the signature rule */
}
.site-header a { color: #fff; text-decoration: none; }
.site-header :focus-visible { box-shadow: 0 0 0 2px var(--c-green-900), 0 0 0 4px var(--c-yellow); }

.site-header__inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--sp-3) var(--sp-5);
  min-height: 4.5rem;
  padding-block: var(--sp-3);
}

/* brand */
.brand {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-3);
  min-height: var(--tap);
  margin-right: auto;
}
.brand__mark { width: 2.25rem; height: 2.25rem; flex: none; }
.brand__name {
  font: 600 1.5rem/1 var(--ff-serif);
  letter-spacing: 0.04em;
}
.brand__tagline {
  display: block;
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--c-green-300);
  margin-top: 0.2rem;
  white-space: nowrap;
}

/* navigation */
.nav-toggle {
  display: none;              /* only shown when JS is available (html.js) */
  align-items: center;
  gap: var(--sp-2);
  min-height: var(--tap);
  min-width: var(--tap);
  padding: 0 var(--sp-3);
  background: transparent;
  color: #fff;
  border: 1px solid var(--c-green-300);
  border-radius: var(--radius);
  cursor: pointer;
}
.nav-toggle svg { width: 1.25rem; height: 1.25rem; }
.nav-toggle[aria-expanded="true"] { background: var(--c-green-800); }

.site-nav { flex: 1 1 100%; order: 3; }
.site-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-1) var(--sp-2);
}
.site-nav a {
  display: inline-flex;
  align-items: center;
  min-height: var(--tap);
  padding: 0 var(--sp-3);
  border-radius: var(--radius);
  font-weight: 600;
  font-size: var(--fs-sm);
  border-bottom: 3px solid transparent;
  white-space: nowrap;
}
.site-nav a:hover { background: var(--c-green-800); }
.site-nav a[aria-current="page"] { border-bottom-color: var(--c-yellow); }

/* collapsed state, JS only, narrow viewports */
@media (max-width: 63.99rem) {
  html.js .nav-toggle { display: inline-flex; }
  html.js .site-nav[hidden] { display: none; }
}

/* header search */
.site-search {
  display: flex;
  align-items: stretch;
  flex: 1 1 14rem;
  max-width: 22rem;
  min-width: 0;
  order: 2;
}
.site-search input {
  flex: 1 1 auto;
  width: 6rem; /* small basis; flex-grow fills the space, so the form can shrink next to the menu */
  min-width: 0;
  min-height: var(--tap);
  padding: 0 var(--sp-3);
  border: 1px solid var(--c-green-300);
  border-right: 0;
  border-radius: var(--radius) 0 0 var(--radius);
  background: var(--c-green-800);
  color: #fff;
}
.site-search input::placeholder { color: var(--c-green-300); }
.site-search button {
  min-width: var(--tap);
  min-height: var(--tap);
  padding: 0 var(--sp-3);
  border: 1px solid var(--c-green-300);
  border-radius: 0 var(--radius) var(--radius) 0;
  background: var(--c-green-800);
  color: #fff;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.site-search button:hover { background: var(--c-green-700); }
.site-search svg { width: 1.25rem; height: 1.25rem; }

@media (min-width: 64rem) {
  .site-header__inner { flex-wrap: nowrap; }
  .site-nav { flex: 0 1 auto; order: 1; }
  .site-nav ul { gap: 0; flex-wrap: nowrap; }
  .site-nav a { padding-inline: var(--sp-2); }
  .site-search { order: 2; flex: 0 1 15rem; margin-left: auto; }
  .brand { margin-right: 0; }
}


/* ---------------------------------------------------------------------------
   6. Footer
   -------------------------------------------------------------------------- */
.site-footer {
  margin-top: var(--sp-8);
  background: var(--c-green-900);
  color: var(--c-green-100);
  font-size: var(--fs-sm);
  border-top: 4px solid var(--c-yellow);
}
.site-footer a { color: #fff; }
.site-footer a:hover { color: var(--c-yellow); }
.site-footer__inner {
  display: grid;
  gap: var(--sp-6);
  padding-block: var(--sp-7) var(--sp-6);
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 14rem), 1fr));
}
.site-footer h2 {
  color: #fff;
  font: 600 var(--fs-base)/1.3 var(--ff-sans);
  margin-bottom: var(--sp-3);
}
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin-bottom: var(--sp-2); }
.site-footer__meta {
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  padding-block: var(--sp-4);
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-2) var(--sp-5);
  color: var(--c-green-300);
  font-size: var(--fs-xs);
}


/* ---------------------------------------------------------------------------
   7. Buttons & links
   -------------------------------------------------------------------------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--sp-2);
  min-height: var(--tap);
  padding: 0.5rem 1rem;
  border: 1px solid var(--c-green-700);
  border-radius: var(--radius);
  background: var(--c-surface);
  color: var(--c-green-700);
  font-weight: 600;
  font-size: var(--fs-sm);
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  white-space: nowrap;
}
.btn:hover { background: var(--c-green-50); color: var(--c-green-800); text-decoration: none; }
.btn svg { width: 1.125rem; height: 1.125rem; flex: none; }

.btn--primary { background: var(--c-green-700); color: #fff; }
.btn--primary:hover { background: var(--c-green-800); color: #fff; }

.btn--quiet { border-color: transparent; background: transparent; }
.btn--quiet:hover { background: var(--c-green-50); }

.btn--sm { min-height: 2.25rem; padding: 0.25rem 0.75rem; font-size: var(--fs-xs); }

/* download button: label + file meta */
.btn--download { text-align: left; white-space: normal; }
.btn--download .btn__meta {
  font-weight: 400;
  color: var(--c-ink-muted);
  font-size: var(--fs-xs);
}
.btn--download:hover .btn__meta { color: inherit; }
.btn--primary .btn__meta { color: rgba(255, 255, 255, 0.85); }

.btn-group { display: flex; flex-wrap: wrap; gap: var(--sp-2); }
.btn-group--center { justify-content: center; }

/* arrow link ("Bekijk alle projecten →") */
.link-more {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-1);
  min-height: var(--tap);
  font-weight: 600;
  text-decoration: none;
}
.link-more:hover { text-decoration: underline; }
.link-more::after { content: "→"; }


/* ---------------------------------------------------------------------------
   8. Forms
   -------------------------------------------------------------------------- */
.field { margin-bottom: var(--sp-4); }
.field > label, .field > .field__label, legend {
  display: block;
  font-weight: 600;
  font-size: var(--fs-sm);
  margin-bottom: var(--sp-1);
  color: var(--c-ink);
}
.field__hint { display: block; font-size: var(--fs-xs); color: var(--c-ink-muted); margin-top: var(--sp-1); }

.input, .select, .textarea {
  display: block;
  width: 100%;
  min-height: var(--tap);
  padding: 0.5rem 0.75rem;
  border: 1px solid var(--c-line-strong);
  border-radius: var(--radius);
  background: var(--c-surface);
  color: var(--c-ink);
}
.input:hover, .select:hover { border-color: var(--c-green-500); }
.input:focus-visible, .select:focus-visible, .textarea:focus-visible {
  border-color: var(--c-green-700);
  box-shadow: var(--focus);
}
.select {
  appearance: none;
  padding-right: 2.25rem;
  background-image: url("../img/chevron.svg");
  background-repeat: no-repeat;
  background-position: right 0.75rem center;
}
.select[multiple] { background-image: none; padding-right: 0.75rem; }

fieldset { border: 0; padding: 0; margin: 0 0 var(--sp-4); min-width: 0; }

.checkbox, .radio {
  display: flex;
  align-items: flex-start;
  gap: var(--sp-2);
  min-height: 2rem;
  padding-block: 0.25rem;
  font-size: var(--fs-sm);
  cursor: pointer;
}
.checkbox input, .radio input {
  flex: none;
  width: 1.125rem;
  height: 1.125rem;
  margin: 0.2rem 0 0;
  accent-color: var(--c-green-700);
}
.checkbox .count { margin-left: auto; color: var(--c-ink-muted); font-size: var(--fs-xs); }

/* inline form row (search + button) */
.form-row { display: flex; gap: var(--sp-2); flex-wrap: wrap; }
.form-row > .input { flex: 1 1 12rem; }


/* ---------------------------------------------------------------------------
   9. Small components
   -------------------------------------------------------------------------- */
/* status badge — neutral by design: the foundation has stopped, so
   "Lopend" vs "Afgerond" is historical information, not a signal. */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4em;
  padding: 0.1em 0.6em;
  border: 1px solid var(--c-line-strong);
  border-radius: 999px;
  background: var(--c-surface);
  color: var(--c-ink-muted);
  font-size: var(--fs-xs);
  font-weight: 600;
  line-height: 1.5;
  white-space: nowrap;
}
.badge::before {
  content: "";
  width: 0.5em;
  height: 0.5em;
  border-radius: 50%;
  background: var(--c-line-strong);
}
.badge[data-status="afgerond"]::before,
.badge[data-status="afgesloten"]::before { background: var(--c-green-500); }
.badge[data-status="lopend"]::before { background: var(--c-yellow); }

/* sector / programme tag */
.tag {
  display: inline-block;
  padding: 0.05em 0.55em;
  border-radius: var(--radius-sm);
  background: var(--c-green-50);
  border: 1px solid var(--c-green-100);
  color: var(--c-green-800);
  font-size: var(--fs-xs);
  font-weight: 600;
  line-height: 1.6;
  text-decoration: none;
  white-space: nowrap;
}
a.tag:hover { background: var(--c-green-100); }
.tag-list { display: flex; flex-wrap: wrap; gap: var(--sp-1); list-style: none; margin: 0; padding: 0; }

/* record number / field code: tabular, slightly condensed */
.code {
  font-family: var(--ff-sans);
  font-variant-numeric: tabular-nums;
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--c-ink-muted);
  white-space: nowrap;
}
a.code--box { text-decoration: none; }
a.code--box:hover { background: var(--c-green-300); }
.code--box {
  display: inline-block;
  min-width: 2.75rem;
  text-align: center;
  padding: 0.05em 0.4em;
  border-radius: var(--radius-sm);
  background: var(--c-green-100);
  color: var(--c-green-900);
}

/* search term highlight */
mark {
  background: var(--c-yellow-100);
  color: var(--c-ink);
  padding: 0 0.1em;
  border-radius: 2px;
  box-shadow: inset 0 -2px 0 var(--c-yellow);
}

/* type label used in mixed search results */
.type-label {
  display: inline-block;
  font-size: var(--fs-xs);
  font-weight: 600;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--c-ink-muted);
}

/* file meta e.g. "PDF, 3,1 MB" */
.file-meta { color: var(--c-ink-muted); font-size: var(--fs-xs); white-space: nowrap; }

/* count pill */
.count {
  font-variant-numeric: tabular-nums;
  color: var(--c-ink-muted);
}


/* ---------------------------------------------------------------------------
   10. Page header, breadcrumb
   -------------------------------------------------------------------------- */
.page-header {
  padding-block: var(--sp-6) var(--sp-5);
  border-bottom: 1px solid var(--c-line);
  margin-bottom: var(--sp-6);
}
.page-header h1 { margin-bottom: var(--sp-2); }
.page-header .lede { margin-top: var(--sp-3); margin-bottom: 0; }
.page-header--plain { border-bottom: 0; margin-bottom: var(--sp-4); }

.breadcrumb {
  font-size: var(--fs-sm);
  margin: 0 0 var(--sp-3);
}
.breadcrumb ol { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: var(--sp-1); }
.breadcrumb li + li::before { content: "/"; color: var(--c-line-strong); margin-right: var(--sp-1); }
.breadcrumb a { color: var(--c-ink-muted); display: inline-block; padding-block: 0.3rem; }
.breadcrumb a:hover { color: var(--c-green-800); }
.breadcrumb [aria-current] { color: var(--c-ink-muted); }

/* project title line: number above the serif title */
.record-title .code { display: block; margin-bottom: var(--sp-1); font-size: var(--fs-sm); }
.record-title__meta { display: flex; flex-wrap: wrap; gap: var(--sp-2) var(--sp-3); align-items: center; margin-top: var(--sp-3); }


/* ---------------------------------------------------------------------------
   11. Home
   -------------------------------------------------------------------------- */
.hero {
  padding-block: var(--sp-7) var(--sp-6);
  background:
    linear-gradient(180deg, var(--c-surface) 0%, var(--c-paper) 100%);
  border-bottom: 1px solid var(--c-line);
}
.hero__inner { max-width: 52rem; }
.hero h1 { font-size: var(--fs-display); margin-bottom: var(--sp-4); }
.hero .lede { margin-bottom: var(--sp-5); max-width: 40rem; }

.search-box { display: flex; max-width: 40rem; }
.search-box label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.search-box input {
  flex: 1 1 auto;
  min-width: 0;
  min-height: 3.25rem;
  padding: 0 var(--sp-4);
  border: 2px solid var(--c-green-700);
  border-right: 0;
  border-radius: var(--radius) 0 0 var(--radius);
  background: var(--c-surface);
  font-size: var(--fs-md);
}
.search-box input:focus-visible { box-shadow: var(--focus); }
.search-box button {
  flex: none;
  min-width: 3.25rem;
  padding: 0 var(--sp-5);
  border: 2px solid var(--c-green-700);
  border-radius: 0 var(--radius) var(--radius) 0;
  background: var(--c-green-700);
  color: #fff;
  font-weight: 600;
  font-size: var(--fs-base);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
}
.search-box button:hover { background: var(--c-green-800); }
.search-box svg { width: 1.25rem; height: 1.25rem; }
.search-box__hint { margin-top: var(--sp-2); font-size: var(--fs-sm); color: var(--c-ink-muted); }
.search-box__hint a { color: inherit; }

/* archive statistics */
.stats {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 9rem), 1fr));
  gap: var(--sp-4);
}
.stats li {
  padding: var(--sp-4) var(--sp-5);
  border-left: 3px solid var(--c-green-500);
  background: var(--c-surface);
  border-radius: 0 var(--radius) var(--radius) 0;
}
.stat__value {
  display: block;
  font: 600 var(--fs-xl)/1.1 var(--ff-serif);
  color: var(--c-green-900);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
.stat__label { display: block; color: var(--c-ink-muted); font-size: var(--fs-sm); margin-top: var(--sp-1); }

/* entry cards */
.card {
  display: flex;
  flex-direction: column;
  gap: var(--sp-2);
  padding: var(--sp-5);
  background: var(--c-surface);
  border: 1px solid var(--c-line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  position: relative;
}
.card:hover { border-color: var(--c-green-500); }
.card h2, .card h3 { margin: 0; font: 600 1.25rem/1.25 var(--ff-serif); hyphens: auto; }
.card h2 a, .card h3 a { text-decoration: none; color: var(--c-green-900); }
.card h2 a::after, .card h3 a::after { content: ""; position: absolute; inset: 0; }   /* whole card clickable */
.card h2 a:hover, .card h3 a:hover { text-decoration: underline; }
.card p { margin: 0; color: var(--c-ink-muted); font-size: var(--fs-sm); }
.card__count { margin-top: auto; padding-top: var(--sp-2); font-size: var(--fs-sm); color: var(--c-green-700); font-weight: 600; }

/* contact block */
.contact {
  display: grid;
  gap: var(--sp-5);
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 16rem), 1fr));
  padding: var(--sp-5);
  background: var(--c-green-50);
  border: 1px solid var(--c-green-100);
  border-radius: var(--radius-lg);
}
.contact h2 { font: 600 var(--fs-lg)/1.25 var(--ff-serif); }
.contact dl { margin: 0; }
.contact dt { font-weight: 600; }
.contact dd { margin: 0 0 var(--sp-3); color: var(--c-ink-muted); }


/* ---------------------------------------------------------------------------
   12. Database pages: filters, toolbar, result list, pagination
   -------------------------------------------------------------------------- */
/* Filters live in <details> so they collapse on small screens without JS.
   site.js closes them on narrow viewports; CSS hides the summary on wide. */
.filters {
  background: var(--c-surface);
  border: 1px solid var(--c-line);
  border-radius: var(--radius-lg);
}
.filters > summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-2);
  min-height: var(--tap);
  padding: var(--sp-2) var(--sp-4);
  font-weight: 600;
  cursor: pointer;
  list-style: none;
}
.filters > summary::-webkit-details-marker { display: none; }
.filters > summary::after {
  content: "";
  width: 0.6em; height: 0.6em;
  border-right: 2px solid var(--c-green-700);
  border-bottom: 2px solid var(--c-green-700);
  transform: rotate(45deg);
  transition: transform 150ms;
}
.filters[open] > summary::after { transform: rotate(-135deg); }
.filters__body { padding: var(--sp-4); border-top: 1px solid var(--c-line); }
.filters h2 { font: 600 var(--fs-base)/1.3 var(--ff-sans); margin: var(--sp-4) 0 var(--sp-2); }
.filters .field { margin-bottom: var(--sp-3); }
.filters__actions { display: flex; flex-wrap: wrap; gap: var(--sp-2); margin-top: var(--sp-4); }
.filters__actions .btn { flex: 1 1 auto; }

@media (min-width: 56rem) {
  .filters > summary { pointer-events: none; }
  .filters > summary::after { display: none; }
  .filters:not([open]) > summary ~ * { display: block; }  /* always show on wide screens */
}

/* results toolbar: count + sort */
.results-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-2) var(--sp-4);
  padding-bottom: var(--sp-3);
  border-bottom: 2px solid var(--c-green-900);
  margin-bottom: var(--sp-2);
}
.results-toolbar h2, .results-toolbar p { margin: 0; font: 600 var(--fs-base)/1.3 var(--ff-sans); }
.results-toolbar .sort { display: flex; align-items: center; gap: var(--sp-2); font-size: var(--fs-sm); }
.results-toolbar .sort .select { width: auto; min-height: 2.25rem; padding-block: 0.25rem; }

/* active filter chips (each is a link that removes the filter) */
.active-filters { display: flex; flex-wrap: wrap; align-items: center; gap: var(--sp-2); margin: var(--sp-3) 0 var(--sp-4); }
.active-filters__label { font-size: var(--fs-sm); color: var(--c-ink-muted); }
.chip {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-2);
  min-height: 2.25rem;
  padding: 0 var(--sp-2) 0 var(--sp-3);
  border-radius: 999px;
  background: var(--c-green-100);
  color: var(--c-green-900);
  font-size: var(--fs-sm);
  text-decoration: none;
}
.chip b { font-weight: 600; }
.chip__remove {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.5rem; height: 1.5rem;
  border-radius: 50%;
  background: var(--c-surface);
  color: var(--c-green-800);
  font-weight: 600;
  line-height: 1;
}
.chip:hover { background: var(--c-green-300); }
.chip:hover .chip__remove { background: var(--c-green-900); color: #fff; }
.active-filters .link-clear { font-size: var(--fs-sm); margin-left: var(--sp-2); }

/* result rows */
.result-list { list-style: none; margin: 0; padding: 0; }
.result {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--sp-1) var(--sp-4);
  padding: var(--sp-4) var(--sp-2);
  border-bottom: 1px solid var(--c-line);
  position: relative;
}
.result:hover { background: var(--c-surface); }
.result__num { font-size: var(--fs-sm); }
.result__title {
  margin: 0;
  font: 600 var(--fs-md)/1.3 var(--ff-sans);
}
.result__title a { color: var(--c-green-900); text-decoration: none; }
.result__title a::after { content: ""; position: absolute; inset: 0; }
.result__title a:hover { text-decoration: underline; color: var(--c-green-700); }
.result__meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--sp-1) var(--sp-3);
  font-size: var(--fs-sm);
  color: var(--c-ink-muted);
  margin: 0;
}
.result__meta .tag-list { display: inline-flex; }
.result__meta .tag, .result__meta .badge, .result__meta a { position: relative; z-index: 1; }
.result__summary { margin: var(--sp-1) 0 0; font-size: var(--fs-sm); color: var(--c-ink); }
.result__aside { font-size: var(--fs-sm); color: var(--c-ink-muted); }

@media (min-width: 40rem) {
  .result { grid-template-columns: 6.5rem minmax(0, 1fr) auto; align-items: baseline; }
  .result__num { grid-row: 1 / span 3; }
  .result__title { grid-column: 2; }
  .result__meta, .result__summary { grid-column: 2; }
  .result__aside { grid-column: 3; grid-row: 1; text-align: right; }
}

/* publication rows reuse .result with an icon column */
.result--pub { grid-template-columns: 1fr; }
@media (min-width: 40rem) {
  .result--pub { grid-template-columns: 2.5rem minmax(0, 1fr) auto; }
  .result--pub .result__icon { grid-row: 1 / span 3; }
}
.result--pub .result__meta span + span::before { content: "·"; margin-right: var(--sp-2); color: var(--c-line-strong); }
.result__icon { width: 2rem; height: 2rem; color: var(--c-green-500); }
.result__icon svg { width: 100%; height: 100%; }

/* pagination */
.pagination { margin-top: var(--sp-6); }
.pagination ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: var(--sp-1);
  align-items: center;
  justify-content: center;
}
.pagination a, .pagination span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: var(--tap);
  min-height: var(--tap);
  padding: 0 var(--sp-3);
  border-radius: var(--radius);
  text-decoration: none;
  font-weight: 600;
  font-size: var(--fs-sm);
}
.pagination a:hover { background: var(--c-green-50); }
.pagination [aria-current="page"] { background: var(--c-green-900); color: #fff; }
.pagination .pagination__gap { color: var(--c-ink-muted); min-width: auto; }
.pagination__summary { text-align: center; font-size: var(--fs-sm); color: var(--c-ink-muted); margin-top: var(--sp-2); }


/* ---------------------------------------------------------------------------
   13. Detail page
   -------------------------------------------------------------------------- */
/* in-page section navigation in the rail */
.section-nav { font-size: var(--fs-sm); }
.section-nav h2 { font: 600 var(--fs-xs)/1.3 var(--ff-sans); letter-spacing: 0.08em; text-transform: uppercase; color: var(--c-ink-muted); margin-bottom: var(--sp-2); }
.section-nav ul { list-style: none; margin: 0; padding: 0; border-left: 2px solid var(--c-line); }
.section-nav a {
  display: flex;
  justify-content: space-between;
  gap: var(--sp-2);
  padding: 0.5rem var(--sp-3);
  margin-left: -2px;
  border-left: 2px solid transparent;
  color: var(--c-ink);
  text-decoration: none;
  min-height: 2.5rem;
}
.section-nav a:hover { border-left-color: var(--c-green-500); color: var(--c-green-800); }
.section-nav .count { font-size: var(--fs-xs); }

/* definition list in two columns: Kenmerken */
.dl {
  display: grid;
  grid-template-columns: max-content minmax(0, 1fr);
  gap: var(--sp-2) var(--sp-5);
  margin: 0;
  font-size: var(--fs-sm);
}
.dl dt { font-weight: 600; color: var(--c-ink-muted); }
.dl dd { margin: 0; }
.dl--boxed {
  padding: var(--sp-4) var(--sp-5);
  background: var(--c-surface);
  border: 1px solid var(--c-line);
  border-radius: var(--radius-lg);
}
@media (max-width: 28rem) {
  .dl { grid-template-columns: 1fr; gap: 0; }
  .dl dt { margin-top: var(--sp-3); }
  .dl dt:first-child { margin-top: 0; }
}

/* detail sections */
.detail-section { padding-block: var(--sp-5); border-top: 1px solid var(--c-line); }
.detail-section:first-of-type { border-top: 0; padding-top: 0; }
.detail-section > h2 { display: flex; align-items: baseline; gap: var(--sp-2); }
.detail-section > h2 .count { font: 400 var(--fs-sm)/1 var(--ff-sans); }

/* plain-text description: paragraphs; "- " lines become .text-list */
.description { max-width: var(--measure); }
.description p { margin-bottom: var(--sp-3); }
.text-list { padding-left: 1.25rem; }
.text-list li { margin-bottom: var(--sp-1); }

/* knowledge entries (ketenkennis) on a project */
.kk-list { list-style: none; margin: 0; padding: 0; }
.kk-item {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: var(--sp-1) var(--sp-3);
  padding: var(--sp-3) 0;
  border-top: 1px solid var(--c-line);
}
.kk-item:first-child { border-top: 0; padding-top: 0; }
.kk-item .code--box { grid-row: 1 / span 2; align-self: start; margin-top: 0.15em; }
.kk-item__title { margin: 0; font-weight: 600; }
.kk-item__title .badge { margin-left: var(--sp-2); font-weight: 400; }
.kk-item__text { margin: 0; font-size: var(--fs-sm); color: var(--c-ink); }

/* publication card (project detail + publications list detail) */
.pub-list { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--sp-4); }
.pub {
  padding: var(--sp-4) var(--sp-5);
  background: var(--c-surface);
  border: 1px solid var(--c-line);
  border-left: 3px solid var(--c-green-500);
  border-radius: var(--radius);
}
.pub h3 { margin: 0 0 var(--sp-1); font: 600 var(--fs-md)/1.3 var(--ff-serif); }
.pub__subtitle { margin: 0 0 var(--sp-2); color: var(--c-ink); }
.pub__meta {
  margin: 0 0 var(--sp-3);
  font-size: var(--fs-sm);
  color: var(--c-ink-muted);
}
.pub__meta span + span::before { content: "·"; margin: 0 0.5em; color: var(--c-line-strong); }
.pub .btn-group { margin-top: var(--sp-2); }

/* related records in the rail: code above title */
.related-list { list-style: none; margin: 0; padding: 0; }
.related-list li { border-top: 1px solid var(--c-line); }
.related-list li:first-child { border-top: 0; }
.related-list a {
  display: block;
  padding: var(--sp-2) 0;
  color: var(--c-ink);
  text-decoration: none;
  font-size: var(--fs-sm);
  line-height: var(--lh-snug);
}
.related-list a:hover { color: var(--c-green-800); text-decoration: underline; }
.related-list .code { display: block; font-size: var(--fs-xs); margin-bottom: 0.1rem; }

/* small key/value rail on detail pages */
.rail-block { padding: var(--sp-4); background: var(--c-surface); border: 1px solid var(--c-line); border-radius: var(--radius-lg); }
.rail-block + .rail-block, .toc + .rail-block { margin-top: var(--sp-4); }
.rail-block h2 { font: 600 var(--fs-xs)/1.3 var(--ff-sans); letter-spacing: 0.08em; text-transform: uppercase; color: var(--c-ink-muted); margin-bottom: var(--sp-2); }
.rail-block .dl { grid-template-columns: 1fr; gap: 0; }
.rail-block .dl dt { margin-top: var(--sp-2); font-size: var(--fs-xs); }
.rail-block .dl dt:first-child { margin-top: 0; }


/* ---------------------------------------------------------------------------
   14. Ketenkennis overview (5 areas → fields → counts)
   -------------------------------------------------------------------------- */
.area-list { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--sp-5); }
.area {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--sp-3) var(--sp-6);
  padding: var(--sp-5);
  background: var(--c-surface);
  border: 1px solid var(--c-line);
  border-radius: var(--radius-lg);
}
@media (min-width: 48rem) { .area { grid-template-columns: 18rem minmax(0, 1fr); } }
.area__head { display: flex; gap: var(--sp-3); align-items: flex-start; }
.area__number {
  flex: none;
  width: 2.5rem; height: 2.5rem;
  display: inline-flex; align-items: center; justify-content: center;
  border-radius: var(--radius);
  background: var(--c-green-900);
  color: var(--c-yellow);
  font: 600 var(--fs-md)/1 var(--ff-serif);
}
.area__head h2 { margin: 0 0 var(--sp-1); font-size: var(--fs-lg); }
.area__head p { margin: 0; font-size: var(--fs-sm); color: var(--c-ink-muted); }
.area__total { font-size: var(--fs-sm); color: var(--c-green-700); font-weight: 600; margin-top: var(--sp-2); display: inline-block; }

.field-list { list-style: none; margin: 0; padding: 0; }
.field-list li { border-top: 1px solid var(--c-line); }
.field-list li:first-child { border-top: 0; }
.field-list a {
  display: grid;
  grid-template-columns: 2.75rem minmax(0, 1fr) auto;
  gap: var(--sp-3);
  align-items: center;
  min-height: var(--tap);
  padding: var(--sp-2) var(--sp-2);
  margin-inline: calc(var(--sp-2) * -1);
  border-radius: var(--radius);
  color: var(--c-ink);
  text-decoration: none;
}
.field-list a:hover { background: var(--c-green-50); color: var(--c-green-800); }
.field-list .count { font-size: var(--fs-sm); }


/* ---------------------------------------------------------------------------
   15. Global search results (mixed types)
   -------------------------------------------------------------------------- */
.search-tabs { display: flex; flex-wrap: wrap; gap: var(--sp-1); list-style: none; margin: 0 0 var(--sp-5); padding: 0; border-bottom: 1px solid var(--c-line); }
.search-tabs a {
  display: inline-flex; align-items: center; gap: var(--sp-2);
  min-height: var(--tap);
  padding: 0 var(--sp-3);
  margin-bottom: -1px;
  border-bottom: 3px solid transparent;
  color: var(--c-ink-muted);
  font-weight: 600;
  font-size: var(--fs-sm);
  text-decoration: none;
}
.search-tabs a:hover { color: var(--c-green-800); }
.search-tabs a[aria-current="page"] { color: var(--c-green-900); border-bottom-color: var(--c-yellow); }
.search-tabs .count { font-weight: 400; }

.hit-list { list-style: none; margin: 0; padding: 0; }
.hit {
  padding: var(--sp-4) 0;
  border-bottom: 1px solid var(--c-line);
  max-width: 48rem;
}
.hit__head { display: flex; flex-wrap: wrap; align-items: center; gap: var(--sp-2) var(--sp-3); margin-bottom: var(--sp-1); }
.hit__title { margin: 0; font: 600 var(--fs-md)/1.3 var(--ff-sans); }
.hit__title a { color: var(--c-green-700); }
.hit__snippet { margin: var(--sp-1) 0; font-size: var(--fs-sm); }
.hit__snippet--doc {
  padding: var(--sp-2) var(--sp-3);
  border-left: 3px solid var(--c-line-strong);
  background: var(--c-surface);
  color: var(--c-ink);
  font-size: var(--fs-sm);
}
.hit__source { margin: var(--sp-1) 0 0; font-size: var(--fs-xs); color: var(--c-ink-muted); }


/* ---------------------------------------------------------------------------
   16. Prose — legacy 2007 HTML (tables, lists, images, nested headings)
   Rules are deliberately defensive: unknown markup must still read well.
   -------------------------------------------------------------------------- */
.prose {
  max-width: var(--measure);
  min-width: 0;
  overflow-wrap: anywhere;
}
.prose > * + * { margin-top: var(--sp-4); }
.prose h1, .prose h2, .prose h3, .prose h4 { margin-top: var(--sp-6); margin-bottom: var(--sp-2); }
.prose h1 { font-size: var(--fs-xl); }      /* a legacy inner h1 is demoted visually */
.prose h2 { font-size: var(--fs-lg); }
.prose h3 { font-size: var(--fs-md); }
.prose > :first-child { margin-top: 0; }
.prose p { margin: 0; }
.prose p:empty { display: none; }
.prose ul, .prose ol { padding-left: 1.5rem; margin: 0; }
.prose li { margin-bottom: var(--sp-1); }
.prose li > ul, .prose li > ol { margin-top: var(--sp-1); }
.prose strong, .prose b { font-weight: 600; }
.prose blockquote { margin: 0; padding: var(--sp-2) var(--sp-4); border-left: 3px solid var(--c-green-500); color: var(--c-ink-muted); }
.prose img { height: auto; max-width: 100%; border-radius: var(--radius); }
.prose img[align="left"], .prose img[style*="float: left"], .prose img[style*="float:left"] { float: left; margin: 0 var(--sp-4) var(--sp-3) 0; }
.prose img[align="right"], .prose img[style*="float: right"], .prose img[style*="float:right"] { float: right; margin: 0 0 var(--sp-3) var(--sp-4); }
.prose::after { content: ""; display: table; clear: both; }
.prose hr { margin: var(--sp-5) 0; }
.prose a[href$=".pdf"]::after, .prose a[href$=".PDF"]::after { content: " (PDF)"; font-size: var(--fs-xs); color: var(--c-ink-muted); }

/* tables: legacy layout tables become readable data tables; wide ones scroll */
.prose table {
  display: block;
  overflow-x: auto;
  width: 100%;
  max-width: 100%;
  font-size: var(--fs-sm);
  border: 1px solid var(--c-line);
  border-radius: var(--radius);
  background: var(--c-surface);
}
.prose table[width], .prose table[style*="width"] { width: 100% !important; }
.prose th, .prose td {
  padding: var(--sp-2) var(--sp-3);
  border-bottom: 1px solid var(--c-line);
  vertical-align: top;
  text-align: left;
  min-width: 8rem;
}
.prose th, .prose td[bgcolor], .prose tr:first-child th { background: var(--c-green-50); font-weight: 600; }
.prose tr:last-child td { border-bottom: 0; }
.prose td p { margin: 0; }
.prose td ul { margin: 0; }
.prose caption { caption-side: top; text-align: left; font-weight: 600; padding: var(--sp-2) var(--sp-3); }
/* legacy inline presentational attributes */
.prose [align="center"] { text-align: center; }
.prose [align="right"] { text-align: right; }
.prose font { font: inherit; color: inherit; }
.prose center { text-align: left; }
.prose u { text-decoration: none; }
.prose br + br { display: none; }   /* collapse double line breaks */

/* side-by-side pages: prose + rail */
.layout-page { display: grid; grid-template-columns: minmax(0, 1fr); gap: var(--sp-6); align-items: start; }
@media (min-width: 60rem) { .layout-page { grid-template-columns: minmax(0, 1fr) 16rem; } }

/* table of contents for long pages */
.toc { padding: var(--sp-4); background: var(--c-surface); border: 1px solid var(--c-line); border-radius: var(--radius-lg); font-size: var(--fs-sm); }
.toc h2 { font: 600 var(--fs-xs)/1.3 var(--ff-sans); letter-spacing: 0.08em; text-transform: uppercase; color: var(--c-ink-muted); margin-bottom: var(--sp-2); }
.toc ol { margin: 0; padding-left: 1.25rem; }
.toc li { margin-bottom: var(--sp-1); }


/* ---------------------------------------------------------------------------
   17. Notices, empty states, 404
   -------------------------------------------------------------------------- */
.notice {
  display: flex;
  gap: var(--sp-3);
  padding: var(--sp-3) var(--sp-4);
  background: var(--c-green-50);
  border: 1px solid var(--c-green-100);
  border-left: 3px solid var(--c-green-500);
  border-radius: var(--radius);
  font-size: var(--fs-sm);
}
.notice--archive { background: var(--c-surface); border-left-color: var(--c-yellow); }
.notice p { margin: 0; }
.notice svg { width: 1.25rem; height: 1.25rem; flex: none; color: var(--c-green-700); margin-top: 0.15em; }

.empty-state {
  padding: var(--sp-7) var(--sp-5);
  text-align: center;
  background: var(--c-surface);
  border: 1px dashed var(--c-line-strong);
  border-radius: var(--radius-lg);
}
.empty-state h2 { font-size: var(--fs-lg); }
.empty-state p { color: var(--c-ink-muted); max-width: 32rem; margin-inline: auto; }

.error-page { padding-block: var(--sp-8); max-width: 40rem; }
.error-page .overline { color: var(--c-green-700); }
.error-page h1 { font-size: var(--fs-display); }


/* ---------------------------------------------------------------------------
   18. Utilities
   -------------------------------------------------------------------------- */
.vh {  /* visually hidden, still read by assistive tech */
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}
.flow > * + * { margin-top: var(--sp-3); }
.mt-0 { margin-top: 0 !important; }
.mb-0 { margin-bottom: 0 !important; }
.mt-6 { margin-top: var(--sp-6); }
.align-right { text-align: right; }
.nowrap { white-space: nowrap; }
.icon { width: 1em; height: 1em; vertical-align: -0.125em; }


/* ---------------------------------------------------------------------------
   19. Motion & print
   -------------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
}

@media print {
  .site-header, .site-footer, .site-search, .filters, .pagination, .skip-link, .nav-toggle, .section-nav, .btn { display: none !important; }
  body { background: #fff; color: #000; font-size: 11pt; }
  a { color: inherit; text-decoration: none; }
  .layout-detail, .layout-sidebar, .layout-page { display: block; }
  .result, .pub, .hit { break-inside: avoid; }
}

/* ==========================================================================
   20. DAFK player (Ruffle): 4:3 stage, letterboxed, full width up to the container
   ========================================================================== */
.dafk-player {
  position: relative;
  /* the movie is 4:3; keep the whole stage on screen */
  width: min(100%, calc((100vh - 6rem) * 4 / 3));
  margin-inline: auto;
  aspect-ratio: 4 / 3;
  background: var(--c-green-900);
  border-radius: var(--radius-lg);
  overflow: hidden;
  display: grid;
  place-items: center;
}
.dafk-player__fallback { max-width: 34rem; padding: var(--sp-5); color: #fff; text-align: center; }
.dafk-player__fallback a { color: var(--c-yellow); }
.dafk-player__failed { display: none; margin-top: var(--sp-3); }
.dafk-player.is-failed + .dafk-player__failed { display: block; }
