/* ============================================================
   Breukdeel — kennisbank-artikelen (prototype-stylesheet)
   Tokens uit het Breukdeel Design System (v2.1).
   Serif: Source Serif 4 (display) · Sans: Public Sans (body)
   ============================================================ */

/* Zelfgehoste merkfonts (zelfde woff2's als de app) — geen CDN-call, identiek op elke pagina. */
@font-face {
  font-family: "Public Sans";
  src: url("/assets/fonts/public-sans.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Source Serif 4";
  src: url("/assets/fonts/source-serif-4.woff2") format("woff2");
  font-weight: 200 900;
  font-style: normal;
  font-display: swap;
}

:root {
  --paper: #F7F5F0;
  --surface: #FFFFFF;
  --ink: #22302A;
  --ink-2: #5A6660;
  --ink-3: #667069;
  --line: #E4E0D6;
  --line-strong: #CFC9BB;

  --green-900: #16362E;
  --green-800: #1D4A3E;
  --green-700: #245C4C;
  --green-600: #2E6B58;
  --green-100: #E3EDE8;
  --green-50:  #F0F5F2;

  --fluor: #FF5F1F;
  --fluor-hover: #E85312;

  --warn: #9A6A1B;
  --warn-bg: #F5EBD8;
  --miss: #A8442F;
  --miss-bg: #F6E4DE;

  --font-display: "Source Serif 4", Georgia, "Times New Roman", serif;
  --font-body: "Public Sans", -apple-system, "Segoe UI", sans-serif;

  --shadow-card: 0 1px 2px rgba(34, 48, 42, .06), 0 4px 16px rgba(34, 48, 42, .05);

  --measure: 660px;
  --page-max: 1080px;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

::selection { background: var(--green-100); }

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

/* ---------- Siteheader ---------- */

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 32px;
  border-bottom: 1px solid var(--line);
  background: var(--paper);
}

.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; }
.brand:hover { color: inherit; }

/* Beeldmerk: gestapelde breuk b/d met fluor-streep */
.brand-mark {
  display: inline-grid;
  grid-template-columns: 1fr 1fr;
  grid-template-rows: 1fr 1fr;
  position: relative;
  line-height: 1;
  font-family: var(--font-display);
  font-weight: 700;
  width: 34px;
  height: 34px;
  color: var(--green-800);
}
.brand-mark .b { font-size: 20px; grid-area: 1 / 1; align-self: start; justify-self: start; }
.brand-mark .slash {
  position: absolute; left: 50%; top: 50%;
  width: 32px; height: 2.5px;
  background: var(--fluor); border-radius: 99px;
  transform: translate(-50%, -50%) rotate(-32deg);
}
.brand-mark .d { font-size: 20px; grid-area: 2 / 2; align-self: end; justify-self: end; transform: translate(-7px, -4.5px); }

.brand-word { font-family: var(--font-display); font-size: 22px; font-weight: 600; color: var(--green-800); }
.brand-payoff { font-size: 13px; color: var(--ink-3); align-self: baseline; margin-top: 8px; }

.site-nav { display: flex; align-items: center; gap: 28px; }
.site-nav a {
  font-size: 14px;
  font-weight: 500;
  color: var(--ink-2);
  text-decoration: none;
  padding: 6px 0 8px;
  position: relative;
}
.site-nav a:hover { color: var(--ink); }
.site-nav a.is-active { color: var(--green-800); font-weight: 600; }
/* logo-streep als micro-motief: actieve navigatie */
.site-nav a.is-active::after {
  content: "";
  position: absolute; left: 0; right: 0; bottom: 0;
  height: 2.5px; border-radius: 99px;
  background: var(--fluor);
}
.site-nav .nav-cta {
  border: 1.5px solid var(--green-700);
  color: var(--green-700);
  border-radius: 10px;
  padding: 8px 16px;
  font-weight: 600;
  transition: background .15s ease, color .15s ease;
}
.site-nav .nav-cta:hover { background: var(--green-50); color: var(--green-800); }
.site-nav .nav-cta.is-active::after { display: none; }

/* ---------- Paginaraster: artikel + zijspoor ---------- */

.shell {
  max-width: var(--page-max);
  margin: 0 auto;
  padding: 0 32px;
  display: grid;
  grid-template-columns: minmax(0, var(--measure)) 248px;
  gap: 72px;
  justify-content: center;
  align-items: start;
}

.shell--single {
  grid-template-columns: minmax(0, var(--measure));
  gap: 0;
}

.article { max-width: var(--measure); padding: 56px 0 64px; animation: bdFade .4s ease-out; }

@keyframes bdFade { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

/* ---------- Artikelkop ---------- */

.kicker {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--green-700);
  margin: 0 0 18px;
}
/* logo-streep als micro-motief: rubriekmarkering */
.kicker::before {
  content: "";
  width: 18px; height: 2.5px;
  border-radius: 99px;
  background: var(--fluor);
  transform: rotate(-32deg);
}
.kicker .sep { color: var(--line-strong); font-weight: 400; letter-spacing: 0; }
.kicker .sub { color: var(--ink-3); font-weight: 500; }

h1 {
  font-family: var(--font-display);
  font-size: 40px;
  font-weight: 600;
  line-height: 1.14;
  letter-spacing: -.01em;
  margin: 0 0 20px;
  text-wrap: balance;
}

.standfirst {
  font-size: 19px;
  line-height: 1.55;
  color: var(--ink-2);
  margin: 0 0 22px;
}

.article-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 10px;
  align-items: baseline;
  font-size: 14px;
  color: var(--ink-3);
  padding-bottom: 28px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 40px;
}
.article-meta .dot { color: var(--line-strong); }

/* ---------- Lopende tekst ---------- */

.article h2 {
  font-family: var(--font-display);
  font-size: 26px;
  font-weight: 600;
  line-height: 1.25;
  letter-spacing: -.005em;
  margin: 52px 0 14px;
  scroll-margin-top: 24px;
}
.article h3 {
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 600;
  line-height: 1.3;
  margin: 36px 0 10px;
}
.article p { margin: 0 0 18px; }
.article ul, .article ol { margin: 0 0 18px; padding-left: 24px; }
.article li { margin-bottom: 8px; }
.article li::marker { color: var(--green-700); font-weight: 600; }
.article strong { font-weight: 600; color: var(--ink); }

/* ---------- Tabellen ---------- */

.table-wrap {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: var(--shadow-card);
  margin: 26px 0 30px;
  overflow-x: auto;
}
table { border-collapse: collapse; width: 100%; font-size: 15px; line-height: 1.5; }
caption {
  caption-side: top;
  text-align: left;
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 600;
  color: var(--ink);
  padding: 18px 22px 0;
}
th {
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--ink-3);
  text-align: left;
  padding: 16px 22px 10px;
  border-bottom: 1px solid var(--line);
  white-space: nowrap;
}
td {
  padding: 13px 22px;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
  color: var(--ink-2);
}
td:first-child { color: var(--ink); font-weight: 500; }
tr:last-child td { border-bottom: none; }
td.num {
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--green-700);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}
td .pakket {
  display: inline-block;
  font-size: 13px;
  font-weight: 400;
  color: var(--ink-3);
  margin-top: 2px;
}
.table-note { font-size: 13px; color: var(--ink-3); margin: -18px 0 30px; }

/* ---------- Signaalblokken ---------- */

.note {
  background: var(--green-50);
  border-left: 3px solid var(--green-700);
  border-radius: 0 10px 10px 0;
  padding: 16px 20px;
  margin: 26px 0;
  font-size: 15.5px;
}
.note p { margin: 0; }
.note p + p { margin-top: 10px; }
.note .note-label {
  display: block;
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--green-700);
  margin-bottom: 6px;
}
.note--warn { background: var(--warn-bg); border-left-color: var(--warn); }
.note--warn .note-label { color: var(--warn); }

/* Kader met fluor-signaalstreep: voor actualiteit/wetgeving die opvalt zonder te schreeuwen */
.note--fluor {
  background: var(--surface);
  border: 1px solid var(--line);
  border-left: 3px solid var(--fluor);
  border-radius: 0 12px 12px 0;
  box-shadow: var(--shadow-card);
  padding: 18px 22px;
}

/* ---------- Checklist (af te vinken stukken) ---------- */

.checklist { list-style: none; padding: 0; margin: 26px 0 30px; }
.checklist li {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 14px 18px 14px 54px;
  margin: 0 0 10px;
  font-size: 15.5px;
}
.checklist li::before {
  content: "";
  position: absolute;
  left: 18px;
  top: 17px;
  width: 18px;
  height: 18px;
  border: 1.5px solid var(--line-strong);
  border-radius: 5px;
  background: #FFFFFF;
}

/* ---------- Stappenplan ---------- */

.steps { list-style: none; padding: 0; margin: 26px 0 30px; counter-reset: stap; }
.steps li {
  counter-increment: stap;
  position: relative;
  padding: 0 0 22px 56px;
  margin: 0;
}
.steps li::before {
  content: counter(stap);
  position: absolute; left: 0; top: -2px;
  width: 36px; height: 36px;
  border-radius: 50%;
  background: var(--surface);
  border: 1px solid var(--line);
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 600;
  color: var(--green-700);
  display: flex; align-items: center; justify-content: center;
}
/* verbindingslijn tussen de stappen */
.steps li:not(:last-child)::after {
  content: "";
  position: absolute; left: 17.5px; top: 38px; bottom: 2px;
  width: 1px; background: var(--line);
}
.steps li strong { display: inline; }

/* ---------- Sjabloonblokken (documentweergave) ---------- */

.doc {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: var(--shadow-card);
  padding: 30px 34px;
  margin: 26px 0 30px;
  position: relative;
  font-size: 15.5px;
}
.doc::before {
  content: "";
  position: absolute; top: 0; left: 34px; right: 34px;
  height: 3px; border-radius: 0 0 99px 99px;
  background: var(--green-100);
}
.doc-badge {
  display: inline-block;
  background: var(--green-100);
  color: var(--green-800);
  font-size: 12.5px;
  font-weight: 600;
  padding: 3px 12px;
  border-radius: 999px;
  margin-bottom: 14px;
}
.doc h4 {
  font-family: var(--font-display);
  font-size: 18px;
  font-weight: 600;
  margin: 0 0 4px;
}
.doc .doc-sub { font-size: 13.5px; color: var(--ink-3); margin: 0 0 18px; }
.doc ol { padding-left: 22px; margin: 0; }
.doc ol li { margin-bottom: 9px; }
.doc ol li::marker { font-family: var(--font-display); color: var(--green-700); font-weight: 600; }
.doc .veld { color: var(--green-700); font-style: italic; }
.doc table { font-size: 14px; width: 100%; table-layout: fixed; }
.doc th { padding: 10px 12px 8px; white-space: normal; font-size: 11px; letter-spacing: .03em; vertical-align: bottom; overflow-wrap: break-word; hyphens: auto; }
.doc td { padding: 12px; height: 40px; }
.doc .sig-line { border-bottom: 1px solid var(--line-strong); display: inline-block; min-width: 180px; }
.doc blockquote { margin: 0; font-family: var(--font-display); font-size: 16px; line-height: 1.7; color: var(--ink); }

/* ---------- Partnerblok (Breukdeel neemt over) ---------- */

.partner {
  background: var(--green-50);
  border: 1px solid var(--green-100);
  border-radius: 14px;
  padding: 28px 32px;
  margin: 32px 0;
}
.partner .partner-label {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--green-700);
  margin: 0 0 12px;
}
.partner .partner-label::before {
  content: "";
  width: 18px; height: 2.5px;
  border-radius: 99px;
  background: var(--fluor);
  transform: rotate(-32deg);
}
.partner h3 {
  font-family: var(--font-display);
  font-size: 21px;
  font-weight: 600;
  margin: 0 0 10px;
  color: var(--green-900);
}
.partner p { font-size: 15.5px; color: var(--ink); margin: 0 0 14px; }
.partner ul { list-style: none; padding: 0; margin: 0 0 18px; }
.partner ul li {
  position: relative;
  padding: 0 0 8px 30px;
  font-size: 15.5px;
}
.partner ul li::before {
  content: "✓";
  position: absolute; left: 0; top: 0;
  width: 20px; height: 20px;
  border-radius: 50%;
  background: var(--green-100);
  color: var(--green-600);
  font-size: 12px;
  font-weight: 700;
  display: flex; align-items: center; justify-content: center;
}
.partner .partner-note { font-size: 13px; color: var(--ink-2); margin: 14px 0 0; }

/* ---------- Downloadblok ---------- */

.download {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 12px;
  box-shadow: var(--shadow-card);
  padding: 22px 26px;
  margin: 26px 0 30px;
}
.download .dl-text { flex: 1; min-width: 220px; }
.download .dl-title { font-family: var(--font-display); font-size: 17px; font-weight: 600; margin: 0 0 2px; }
.download .dl-sub { font-size: 13.5px; color: var(--ink-3); margin: 0; }
.download .dl-actions { display: flex; gap: 10px; flex-wrap: wrap; }
.btn-secondary {
  display: inline-block;
  border: 1.5px solid var(--green-700);
  color: var(--green-700);
  background: var(--surface);
  border-radius: 10px;
  padding: 10px 18px;
  font-size: 14.5px;
  font-weight: 600;
  text-decoration: none;
  transition: background .15s ease, color .15s ease;
}
.btn-secondary:hover { background: var(--green-50); color: var(--green-800); }

/* ---------- CTA-blok (check) ---------- */

.cta {
  background: var(--green-800);
  border-radius: 14px;
  padding: 38px 36px;
  margin: 56px 0 0;
  color: #C9D9D2;
}
.cta .cta-fracties {
  font-family: var(--font-display);
  font-size: 15px;
  letter-spacing: .06em;
  color: #6E8F83;
  margin: 0 0 14px;
}
.cta h2 {
  font-family: var(--font-display);
  font-size: 27px;
  font-weight: 600;
  line-height: 1.2;
  color: #FFFFFF;
  margin: 0 0 10px;
}
.cta p { font-size: 16px; margin: 0 0 24px; max-width: 480px; }
.cta .cta-meta { font-size: 13.5px; color: #9DB5AB; margin: 14px 0 0; }
.btn-fluor {
  display: inline-block;
  background: var(--fluor);
  color: #FFFFFF;
  border: none;
  border-radius: 10px;
  padding: 14px 28px;
  font-size: 16px;
  font-weight: 600;
  text-decoration: none;
  transition: background .15s ease;
}
.btn-fluor:hover { background: var(--fluor-hover); color: #FFFFFF; }

/* ---------- Bronnen en redactionele controle ---------- */

.sources {
  margin-top: 56px;
  padding: 28px 30px;
  background: var(--green-50);
  border: 1px solid #D6E2DB;
  border-radius: 12px;
}
.sources .sources-kicker {
  margin: 0 0 6px;
  color: var(--green-700);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.article .sources h2 {
  margin: 0 0 10px;
  font-size: 23px;
}
.sources p,
.sources li {
  font-size: 14.5px;
  line-height: 1.55;
}
.sources p { color: var(--ink-2); }
.sources ul { margin: 14px 0 12px; }
.sources li { margin-bottom: 7px; }
.sources .sources-note {
  margin: 14px 0 0;
  padding-top: 13px;
  border-top: 1px solid #D6E2DB;
  font-size: 13px;
  color: var(--ink-3);
}

/* ---------- Artikelvoet ---------- */

.article-footer {
  margin-top: 40px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
  font-size: 13.5px;
  color: var(--ink-3);
}
.article-footer p { margin: 0 0 6px; }

/* ---------- Zijspoor ---------- */

.rail {
  position: sticky;
  top: 40px;
  padding: 64px 0 64px;
  font-size: 14px;
}
.rail-block { margin-bottom: 36px; }
.rail-title {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin: 0 0 12px;
}
.rail nav a {
  display: block;
  color: var(--ink-2);
  text-decoration: none;
  padding: 5px 0 5px 14px;
  border-left: 2px solid var(--line);
  line-height: 1.45;
  transition: color .15s ease, border-color .15s ease;
}
.rail nav a:hover { color: var(--green-800); border-left-color: var(--green-600); }
.rail .rail-links a {
  display: block;
  color: var(--green-700);
  padding: 5px 0;
  text-decoration: none;
  line-height: 1.45;
}
.rail .rail-links a:hover { color: var(--green-800); text-decoration: underline; text-underline-offset: 3px; }

/* ---------- Rail-promo (zwevend, verdwijnt bij het partnerblok) ---------- */

.rail-promo {
  background: var(--green-50);
  border: 1px solid var(--green-100);
  border-radius: 12px;
  padding: 18px 18px 16px;
  font-size: 13.5px;
  line-height: 1.5;
  transition: opacity .3s ease, transform .3s ease;
}
.rail-promo.is-hidden {
  opacity: 0;
  transform: translateY(8px);
  pointer-events: none;
}
.rail-promo .promo-title {
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 600;
  line-height: 1.3;
  color: var(--green-900);
  margin: 0 0 4px;
}
.rail-promo .promo-sub {
  font-size: 12.5px;
  color: var(--ink-2);
  margin: 0 0 12px;
}
.rail-promo ul { list-style: none; padding: 0; margin: 0 0 14px; }
.rail-promo ul li {
  position: relative;
  padding: 0 0 7px 24px;
  color: var(--ink);
}
.rail-promo ul li::before {
  content: "✓";
  position: absolute; left: 0; top: 1px;
  width: 16px; height: 16px;
  border-radius: 50%;
  background: var(--green-100);
  color: var(--green-600);
  font-size: 10px;
  font-weight: 700;
  display: flex; align-items: center; justify-content: center;
}
.rail-promo a {
  font-weight: 600;
  color: var(--green-700);
}

/* ---------- Sitevoet ---------- */

.site-footer {
  border-top: 1px solid var(--line);
  margin-top: 48px;
  padding: 32px;
}
.site-footer .inner {
  max-width: var(--page-max);
  margin: 0 auto;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  font-size: 13px;
  color: var(--ink-3);
}
.site-footer a { color: var(--ink-2); }

/* ---------- Responsief ---------- */

@media (max-width: 980px) {
  .shell { grid-template-columns: minmax(0, var(--measure)); gap: 0; }
  .rail { display: none; }
  .site-header { padding: 16px 20px; }
  .brand-payoff { display: none; }
  .shell { padding: 0 20px; }
}

@media (max-width: 640px) {
  h1 { font-size: 31px; }
  .standfirst { font-size: 17.5px; }
  .article h2 { font-size: 23px; }
  .site-nav { gap: 12px; }
  .site-nav a:not(.nav-cta) { font-size: 13.5px; }
  .site-nav .nav-cta { font-size: 12.5px; padding: 6px 10px; white-space: nowrap; }
  .brand-word { font-size: 20px; }
  .doc { padding: 22px 20px; }
  .sources { padding: 24px 20px; }
  .cta { padding: 30px 24px; }
}

@media (max-width: 480px) {
  .brand-word { display: none; }
  .site-header { padding: 14px 16px; }
}

/* Auditfixes 6-8 (impeccable): skip-link voor toetsenbordgebruikers. */
.skip-link { position:absolute; left:-9999px; top:0; z-index:100; padding:10px 16px; background:var(--green-700); color:#fff; border-radius:0 0 10px 0; font-weight:600; text-decoration:none; }
.skip-link:focus { left:0; }

/* Auditfixes 6-8: kliklinks naar >=24px doelhoogte zonder visuele verschuiving (WCAG 2.5.8). */
.case-link a, .case h3 a, .footer-links a, .bd-footer a, .site-footer a, .site-nav a, nav a { display:inline-flex; align-items:center; min-height:24px; }

/* Auditfixes 6-8: zelfde bewegingsregel als de homepage. */
@media (prefers-reduced-motion: reduce) {
  * { animation:none !important; transition:none !important; }
}
