.editorial-library .library-intro { margin-bottom: 28px; }
.editorial-library .library-filters :is(legend, .library-audience) {
  color: var(--editorial-ink);
  font-size: .875rem;
  font-weight: 650;
}
.editorial-library .library-filters fieldset {
  margin: 16px 0;
  padding: 0;
  border: 0;
}
.editorial-library .library-filters legend { margin-bottom: 5px; }
.editorial-library .library-filters nav { margin-block: 6px 0; }
.editorial-library .library-filters {
  max-height: calc(100vh - 110px);
  overflow-y: auto;
}
.editorial-library .library-filters :is(button, select),
.editorial-library .library-quick button {
  color: var(--editorial-ink);
  font: inherit;
  font-size: .8125rem;
}
.editorial-library .library-filters :is([data-material], [data-knowledge-topic]),
.editorial-library .library-quick button {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.editorial-library .library-filters [data-material] {
  width: 100%;
  min-height: 40px;
  padding: 7px 10px;
  border: 1px solid transparent;
  border-radius: 9px;
  background: transparent;
  cursor: pointer;
}
.editorial-library .library-filters [data-material]:is(:hover, [aria-pressed="true"]) {
  border-color: var(--editorial-line);
  background: var(--editorial-tint);
}
.editorial-library .library-audience { display: grid; gap: 7px; }
.editorial-library .library-audience select,
.editorial-library .library-reset {
  width: 100%;
  min-height: 44px;
  padding: 7px;
  border: 1px solid var(--editorial-line);
  border-radius: 9px;
  background: #fff;
  cursor: pointer;
}
.editorial-library .library-reset { margin-top: 14px; }
.editorial-library .library-count { font-variant-numeric: tabular-nums; font-size: .75rem; }
.editorial-library .library-quick {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-block: 12px 18px;
}
.editorial-library .library-quick button {
  min-height: 42px;
  padding: 7px 11px;
  border: 1px solid var(--editorial-line);
  border-radius: 10px;
  background: #fff;
  font-weight: 650;
  cursor: pointer;
}
.editorial-library .library-quick button[aria-pressed="true"] {
  border-color: var(--editorial-leaf);
  background: var(--editorial-leaf);
  color: #fff;
}
.editorial-library [data-theme] { --theme-text: #244736; --theme-bg: #eef5ed; --theme-line: #cfe0d0; }
.editorial-library [data-theme="acute-ggz"] { --theme-text: #8f3f26; --theme-bg: #faf1ec; --theme-line: #e8cfc3; }
.editorial-library [data-theme="trauma-context"] { --theme-text: #22485e; --theme-bg: #eef4f7; --theme-line: #c8dce6; }
.editorial-library [data-theme="middelen-medicatie"] { --theme-text: #6e4b12; --theme-bg: #faf4e6; --theme-line: #e6d5ad; }
.editorial-library [data-theme="ggz-perspectief"] { --theme-text: #493963; --theme-bg: #f3eff8; --theme-line: #d9cfe6; }
.editorial-library .library-entrances {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin-block: 0 18px;
}
.editorial-library .library-entrances button {
  min-height: 80px;
  padding: 12px;
  color: var(--theme-text);
  background: var(--theme-bg);
  border: 1px solid var(--theme-line);
  border-radius: 14px;
  font-family: inherit;
  font-size: .875rem;
  font-weight: 700;
  text-align: left;
  cursor: pointer;
}
.editorial-library .library-entrances small {
  display: block;
  margin-top: 4px;
  color: var(--editorial-muted);
  font-size: .75rem;
  font-weight: 500;
}
.editorial-library .library-entrances[hidden],
.editorial-library .library-quick[hidden] { display: none; }
.editorial-library .knowledge-status { margin: 12px 0 0; color: var(--editorial-ink); font-weight: 700; }
.editorial-library .library-card {
  display: flex;
  flex-direction: column;
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--theme-line);
  border-radius: 16px;
  background: #fff;
  scroll-margin-top: 100px;
}
.editorial-library .library-card:hover { border-color: var(--theme-text); }
.editorial-library .library-card-body { flex: 1; display: flex; flex-direction: column; gap: 10px; padding: 18px; }
.editorial-library .library-card-meta,
.editorial-library .library-card-footer {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 8px;
}
.editorial-library .library-tag,
.editorial-library .library-save {
  padding: 5px 9px;
  color: var(--theme-text);
  border: 1px solid var(--theme-line);
  border-radius: 8px;
  background: var(--theme-bg);
  font-size: .75rem;
  font-weight: 650;
  line-height: 1.4;
}
.editorial-library .library-save { min-height: 44px; cursor: pointer; }
.editorial-library .library-save[aria-pressed="true"] { background: var(--theme-text); color: white; }
.editorial-library .library-card-title { margin: 0; font-size: 1.2rem; line-height: 1.35; }
.editorial-library .library-card-title a { color: #171717; text-decoration: none; }
.editorial-library .library-card-title a:hover { text-decoration: underline; }
.editorial-library .library-description { margin: 0; color: var(--editorial-muted); font-size: .9rem; line-height: 1.55; }
.editorial-library .library-card-footer {
  margin-top: auto;
  padding-top: 8px;
  border-top: 1px solid var(--theme-line);
  color: var(--editorial-muted);
  font-size: .8125rem;
}
.editorial-library .library-open { display: inline-flex; align-items: center; min-height: 44px; color: var(--theme-text); font-weight: 700; }
.editorial-library [data-view="list"] .library-card { flex-direction: row; }
@media (max-width: 950px) {
  .editorial-library .library-entrances { grid-template-columns: 1fr; }
  .editorial-library .library-entrances button { min-height: 52px; }
}
@media (max-width: 767px) {
  .editorial-library .library-filters { max-height: none; }
}
.editorial-library .library-intro :is(h1, p) {
  animation: none;
  opacity: 1;
  transform: none;
}
.editorial-library .library-topic-nav button::before {
  content: "";
  flex: 0 0 8px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--theme-text);
}
.editorial-library .library-topic-nav .library-count { margin-left: auto; }

/* Layout and spacing of the library reference. */
.knowledge-library-page > main > .editorial-library {
  max-width: 1280px;
  padding-inline: clamp(16px, 2vw, 28px);
}
.editorial-library .library-layout { gap: 24px; }
.editorial-library .library-intro { margin-bottom: 32px; }
.editorial-library .library-intro > p:not(.library-overview) {
  max-width: 45rem;
  font-size: 1.0625rem;
  line-height: 1.6;
}
.editorial-library .library-intro .library-overview {
  margin: 18px 0 0;
  font-size: .8125rem;
  line-height: 1.6;
}
.editorial-library .library-overview strong { color: var(--editorial-ink); font-size: 1rem; }
.editorial-library .library-overview span { margin-inline: 9px; }
.editorial-library .library-filters { padding: 14px 16px 20px; }
.editorial-library .library-filters summary { margin-bottom: 12px; letter-spacing: -.025em; }
.editorial-library .library-filters fieldset { margin-block: 24px 0; }
.editorial-library .library-filters legend,
.editorial-library .library-topic-nav .library-topic-label {
  display: block;
  margin-bottom: 7px;
  color: #53615a;
  font-size: .75rem;
  font-weight: 650;
  letter-spacing: .035em;
  text-transform: uppercase;
}
.editorial-library .library-topic-nav button::before { margin-right: 2px; }
.editorial-library [data-theme] { --theme-accent: #476b58; }
.editorial-library [data-theme="acute-ggz"] { --theme-accent: #b85a3a; }
.editorial-library [data-theme="trauma-context"] { --theme-accent: #3a6f8f; }
.editorial-library [data-theme="middelen-medicatie"] { --theme-accent: #a6751e; }
.editorial-library [data-theme="ggz-perspectief"] { --theme-accent: #6d5791; }
.editorial-library .library-topic-nav button::before { background: var(--theme-accent); }
.editorial-library .library-filters :is([data-material], [data-library-audience], [data-knowledge-topic]) {
  min-height: 38px;
  padding-inline: 10px;
  border-radius: 12px;
  color: #53615a;
  text-align: left;
}
.editorial-library .library-filters :is([data-material], [data-library-audience])[aria-pressed="true"],
.editorial-library .library-topic-nav button[aria-pressed="true"] {
  color: #244736;
  background: #eaf2ea;
  border-color: transparent;
  font-weight: 650;
}
.editorial-library .library-audience [data-library-audience] {
  display: flex;
  align-items: center;
  gap: 9px;
  width: 100%;
  border: 0;
  background: transparent;
  cursor: pointer;
}
.editorial-library .library-audience [data-library-audience]::before {
  content: "";
  flex: 0 0 8px;
  height: 8px;
  border-radius: 50%;
  background: #a8c4b2;
}
.editorial-library .library-audience [aria-pressed="true"]::before { background: #476b58; }
.editorial-library .library-filters .library-count { margin-left: auto; }
.editorial-library .library-reset {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  margin-top: 24px;
  background: var(--editorial-paper);
  font-weight: 650;
}
.editorial-library :is(.library-filters, .library-quick, .library-view-options, .library-card) svg {
  width: 15px;
  height: 15px;
  flex: none;
}
.editorial-library .knowledge-search-row { min-height: 50px; border-radius: 16px; background: #fff; box-shadow: none; }
.editorial-library .library-result-controls { margin-block: 18px; }
.editorial-library .library-result-controls .knowledge-status { margin: 0; font-size: .9375rem; }
.editorial-library .library-result-controls select { min-height: 38px; }
.editorial-library .library-quick { margin: 0 0 22px; }
.editorial-library .library-quick button { min-height: 38px; padding: 7px 13px; border-radius: 12px; }
.editorial-library .library-entrances { margin-bottom: 16px; gap: 12px; }
.editorial-library .library-entrances button { min-height: 96px; padding: 14px 16px; }
.editorial-library .library-entrances strong { display: block; }
.editorial-library .library-entrances strong::after { content: "→"; float: right; color: var(--theme-accent); }
.editorial-library .library-entrances small { font-size: .8125rem; line-height: 1.55; }
.editorial-library .library-results-options {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 16px;
}
.editorial-library .library-results-options[hidden] { display: none; }
.editorial-library .library-results-options p { margin: 0; color: #53615a; font-size: .8125rem; }
.editorial-library .library-view-options {
  padding: 3px;
  gap: 2px;
  border: 1px solid var(--editorial-line);
  border-radius: 13px;
  background: #fff;
}
.editorial-library .library-view-options button {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 34px;
  padding: 5px 9px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: #53615a;
  font: inherit;
  font-size: .8125rem;
  cursor: pointer;
}
.editorial-library .library-view-options button[aria-pressed="true"] { color: #244736; background: #eaf2ea; font-weight: 650; }
.editorial-library .knowledge-results { gap: 20px; }
.editorial-library .library-card { border-color: var(--editorial-line); }
.editorial-library .library-card::before { content: ""; height: 3px; background: var(--theme-accent); }
.editorial-library .library-card:hover { box-shadow: 0 5px 12px rgb(23 33 29 / 10%); }
.editorial-library .library-card-body { padding: clamp(16px, 2vw, 24px); gap: 12px; }
.editorial-library .library-card-labels { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; }
.editorial-library .library-tag,
.editorial-library .library-card-type,
.editorial-library .library-read {
  padding: 0;
  border: 0;
  background: transparent;
  font-size: .8125rem;
  line-height: 1.5;
}
.editorial-library .library-tag::before {
  content: "";
  display: inline-block;
  width: 8px;
  height: 8px;
  margin-right: 6px;
  border-radius: 50%;
  background: var(--theme-accent);
}
.editorial-library .library-card-type { color: #53615a; }
.editorial-library .library-card-type::before { content: "·"; margin-right: 6px; color: #77857e; }
.editorial-library .library-read { flex-basis: 100%; display: flex; align-items: center; gap: 4px; color: var(--theme-text); }
.editorial-library .library-save {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 34px;
  border-color: var(--editorial-line);
  background: #fff;
  color: #53615a;
}
.editorial-library .library-save[aria-pressed="true"] { background: #deeee3; border-color: #8fb19a; color: #244736; }
.editorial-library .library-card-title { font-size: clamp(1.0625rem, 1.75vw, 1.3125rem); letter-spacing: -.025em; }
.editorial-library .library-description { font-size: .9375rem; line-height: 1.6; }
.editorial-library .library-card-footer { padding-top: 8px; }
.editorial-library .library-open { min-height: 34px; text-decoration: none; }
.editorial-library .library-open:hover { text-decoration: underline; }
.editorial-library [data-view="list"] .library-card::before { width: 3px; height: auto; flex: none; }
@media (min-width: 768px) {
  .editorial-library .library-filters summary { list-style: none; cursor: default; }
  .editorial-library .library-filters summary::-webkit-details-marker { display: none; }
}
.editorial-library .library-filters { max-height: none; overflow: visible; }
.editorial-library .library-sidebar { position: static; }
.editorial-library .library-entrances strong svg {
  width: 16px;
  height: 16px;
  margin-right: 6px;
  vertical-align: -3px;
}
.editorial-library .library-dossier {
  gap: 6px;
  padding: 5px 10px;
  border-radius: 8px;
  background: var(--theme-text);
  color: #fff;
}
.editorial-library .library-dossier:is(:hover, :focus-visible) { color: #fff; }
@media (min-width: 768px) and (min-height: 1040px) {
  .editorial-library .library-sidebar { position: sticky; }
}

.editorial-library .library-layout { row-gap: 12px; }
.editorial-library .library-layout > .knowledge-search { min-width: 0; margin: 0; }
.editorial-library .library-filters:not([open]) { padding-bottom: 8px; }
.editorial-library .library-filters:not([open]) > summary { margin-bottom: 0; }
@media (min-width: 768px) {
  .editorial-library .library-layout > .knowledge-search { grid-column: 2; grid-row: 1; }
  .editorial-library .library-layout > .library-sidebar { grid-column: 1; grid-row: 1 / span 2; }
  .editorial-library .library-layout > .library-content { grid-column: 2; grid-row: 2; }
}
