/* ==========================================================================
   Proud Nerds, Design System
   Kleuren, typografie en componenten gebaseerd op de huisstijl-voorbeeldpagina
   ========================================================================== */

:root {
  /* Kleuren */
  --c-primary:    #221e17;
  --c-darker:     #12100c;
  --c-hover:      #171410;
  --c-gold:       #d0b77c;
  --c-gold-soft:  #e4cf9c;
  --c-cream:      #f8f1df;
  --c-cream-soft: #fffbf0;
  --c-white:      #ffffff;

  --c-text-dark:  #333333;
  --c-text-muted: #767676;
  --c-text-light: #cccccc;

  --c-border:     #e5dfca;
  --c-success:    #3b7a3b;
  --c-warn:       #b87d2c;
  --c-danger:     #a4332b;
  --c-info:       #2d5b8a;

  --c-success-bg: #d7ecdc;
  --c-warn-bg:    #f5e4c4;
  --c-danger-bg:  #f0d4cc;
  --c-info-bg:    #d6e2ef;

  /* Shadows */
  --shadow-card:  0 4px 12px rgba(0,0,0,0.08);
  --shadow-hover: 0 6px 16px rgba(0,0,0,0.12);

  /* Radii */
  --r-card: 4px;
  --r-pill: 50px;

  /* Hoogte van de sticky topbar, voor sticky panelen eronder */
  --topbar-h: 78px;
}

/* Reset */
* { box-sizing: border-box; margin: 0; padding: 0; }
html, body {
  font-family: 'Nunito Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  color: var(--c-text-dark);
  background: var(--c-cream);
  font-size: 14px;
  line-height: 1.5;
}

/* ==========================================================================
   Typografie
   ========================================================================== */

h1, h2, h3, h4, h5, h6 {
  font-family: 'Red Hat Display', 'Nunito Sans', sans-serif;
  color: var(--c-primary);
  font-weight: 700;
  line-height: 1.2;
}
h1 { font-size: 30px; font-weight: 800; letter-spacing: -0.01em; }
h2 { font-size: 20px; font-weight: 800; }
h3 { font-size: 15px; font-weight: 700; }
h4 { font-size: 14px; font-weight: 700; }
h5 { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.04em; }

p { color: var(--c-text-dark); margin-bottom: 12px; }
a { color: var(--c-primary); border-bottom: 1px solid var(--c-gold); text-decoration: none; }
a:hover { color: var(--c-hover); }

strong { color: var(--c-primary); font-weight: 700; }

.eyebrow {
  font-family: 'Red Hat Display', sans-serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--c-gold);
}

.lead {
  font-size: 16px;
  color: var(--c-text-muted);
  font-weight: 600;
  margin-bottom: 20px;
  line-height: 1.55;
}

.txt-gold    { color: var(--c-gold); }
.txt-muted   { color: var(--c-text-muted); }
.txt-success { color: var(--c-success); }
.txt-danger  { color: var(--c-danger); }
.txt-warn    { color: var(--c-warn); }

/* ==========================================================================
   Layout
   ========================================================================== */

.app {
  display: grid;
  grid-template-columns: 260px 1fr;
  min-height: 100vh;
}

/* Sidebar: merk boven, menu in het midden dat meescrollt, uitloggen onderaan vast. */
.sidebar {
  background: var(--c-darker);
  color: var(--c-white);
  padding: 20px 0 0;
  position: sticky;
  top: 0;
  height: 100vh;
  display: flex;
  flex-direction: column;
  min-height: 0;
}
.brand {
  padding: 4px 22px 20px;
  border-bottom: 1px solid rgba(208,183,124,0.2);
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}
.brand-avatar {
  width: 88px;
  height: 88px;
  border-radius: 14px;
  object-fit: cover;
  margin-bottom: 14px;
  border: 2px solid rgba(208,183,124,0.45);
  box-shadow: 0 4px 20px rgba(208,183,124,0.22);
}
.brand-logo {
  font-family: 'Red Hat Display', sans-serif;
  font-weight: 800;
  font-size: 17px;
  color: var(--c-gold);
  letter-spacing: -0.01em;
}
.brand-sub {
  font-family: 'Nunito Sans', sans-serif;
  font-size: 11px;
  color: var(--c-text-light);
  margin-top: 3px;
  font-weight: 600;
}

.nav { flex: 1; min-height: 0; overflow-y: auto; padding: 12px 0; }
.nav-section {
  padding: 14px 22px 6px;
  font-size: 10px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--c-text-light);
  font-weight: 700;
  font-family: 'Red Hat Display', sans-serif;
}
.nav-item {
  display: flex;
  align-items: center;
  gap: 11px;
  width: 100%;
  padding: 9px 22px;
  color: var(--c-text-light);
  text-align: left;
  text-decoration: none;
  border: none;
  background: none;
  font: inherit;
  cursor: pointer;
  font-weight: 600;
  font-size: 13px;
  position: relative;
  transition: background 0.12s, color 0.12s;
}
/* De accentbalk schuift open in plaats van te verschijnen; daarom een ::before en
   geen border-left, die het label 3px zou verschuiven. */
.nav-item::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  width: 3px;
  height: 22px;
  border-radius: 0 3px 3px 0;
  background: var(--c-gold);
  transform: translateY(-50%) scaleY(0);
  transition: transform 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}
.nav-item:hover {
  background: rgba(208,183,124,0.08);
  color: var(--c-white);
}
.nav-item:hover::before { transform: translateY(-50%) scaleY(1); }
.nav-item:hover .nav-icon { color: var(--c-gold-soft); transform: scale(1.12); }
.nav-item.active {
  background: rgba(208,183,124,0.12);
  color: var(--c-gold);
}
.nav-item.active::before { transform: translateY(-50%) scaleY(1); }
.nav-item.active .nav-icon { color: var(--c-gold); }
.nav-icon {
  width: 19px;
  height: 19px;
  flex-shrink: 0;
  color: var(--c-gold);
  opacity: 0.9;
  transition: transform 0.2s cubic-bezier(0.4, 0, 0.2, 1), color 0.2s;
}

/* Voet van de sidebar: wie is ingelogd, en de knop om dat te beëindigen. */
.nav-footer {
  padding: 10px 0 14px;
  border-top: 1px solid rgba(208,183,124,0.2);
}
.nav-gebruiker {
  padding: 4px 22px 8px;
  font-size: 11px;
  font-weight: 600;
  color: var(--c-text-muted);
  word-break: break-all;
}
.nav-item-uitloggen { font-size: 13px; color: var(--c-text-light); }
.nav-footer-lijn { height: 1px; background: rgba(208,183,124,0.2); margin: 8px 22px; }
.nav-footer-tekst {
  display: block;
  padding: 2px 22px;
  font-size: 11px;
  color: var(--c-text-light);
  font-weight: 600;
}

/* Main */
.main { display: flex; flex-direction: column; min-width: 0; }

.topbar {
  background: var(--c-white);
  border-bottom: 1px solid var(--c-border);
  padding: 16px 32px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  position: sticky;
  top: 0;
  z-index: 40;
}
.topbar-title .crumb {
  font-size: 12px;
  color: var(--c-text-muted);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-family: 'Red Hat Display', sans-serif;
  margin-bottom: 2px;
}
.topbar-title h1 { font-size: 22px; margin: 0; }
/* Alleen zichtbaar zodra de sidebar wegschuift; zie de responsive-sectie. */
.topbar-menu {
  display: none;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  flex-shrink: 0;
  margin-right: -12px;
  border: 1px solid var(--c-border);
  border-radius: var(--r-card);
  background: var(--c-white);
  color: var(--c-primary);
  cursor: pointer;
}
.topbar-menu .nav-icon { color: var(--c-primary); opacity: 1; }

.content {
  padding: 32px 48px;
  flex: 1;
  max-width: 1080px;
}
.content section { margin-bottom: 56px; scroll-margin-top: 80px; }

/* ==========================================================================
   Cards
   ========================================================================== */

.card {
  background: var(--c-white);
  border-radius: var(--r-card);
  padding: 22px 24px;
  box-shadow: var(--shadow-card);
  border: 1px solid var(--c-border);
}
.card + .card { margin-top: 16px; }

.grid { display: grid; gap: 16px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }

.step-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: 14px;
  margin: 20px 0 8px;
}
.step-card {
  background: var(--c-white);
  border: 1px solid var(--c-border);
  border-top: 3px solid var(--c-gold);
  border-radius: var(--r-card);
  padding: 18px 20px;
  text-decoration: none;
  color: inherit;
  display: block;
  transition: all 0.15s;
}
.step-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-hover);
  border-color: var(--c-gold);
  border-top-color: var(--c-gold);
}
.step-card .num {
  font-family: 'Red Hat Display', sans-serif;
  font-size: 11px;
  font-weight: 800;
  color: var(--c-gold);
  text-transform: uppercase;
  letter-spacing: 0.12em;
}
.step-card .label {
  font-family: 'Red Hat Display', sans-serif;
  font-size: 15px;
  font-weight: 800;
  margin-top: 4px;
  color: var(--c-primary);
}
.step-card .desc {
  font-size: 12.5px;
  color: var(--c-text-muted);
  margin-top: 6px;
  font-weight: 600;
}

/* ==========================================================================
   Step headers
   ========================================================================== */

.step-header {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 12px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--c-border);
}
.step-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: var(--c-primary);
  color: var(--c-gold);
  border-radius: 50%;
  font-weight: 800;
  font-size: 16px;
  font-family: 'Red Hat Display', sans-serif;
  flex-shrink: 0;
}
.step-header h2 { margin: 0; }
.step-header .step-sub {
  font-size: 12px;
  color: var(--c-text-muted);
  font-weight: 600;
  margin-top: 2px;
}

h2 { margin: 32px 0 12px; }
h3 { margin: 22px 0 10px; }
h4 { margin: 14px 0 8px; }

/* Geen dubbele witruimte boven eerste heading in een blok */
.card > h2:first-child,
.card > h3:first-child,
.card > h4:first-child,
[data-tab-panel] > h2:first-child,
[data-tab-panel] > h3:first-child { margin-top: 0; }

/* ==========================================================================
   Callouts (anno-stijl)
   ========================================================================== */

.callout {
  padding: 12px 16px;
  border-left: 3px solid var(--c-gold);
  border-radius: 0 var(--r-card) var(--r-card) 0;
  background: var(--c-cream-soft);
  margin: 16px 0;
  font-size: 13px;
  color: var(--c-text-dark);
}
.callout p:last-child { margin-bottom: 0; }
.callout > strong:first-child {
  display: block;
  margin-bottom: 4px;
  color: var(--c-primary);
  font-family: 'Red Hat Display', sans-serif;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.callout.info    { border-color: var(--c-info);    background: #eef3f9; }
.callout.warning { border-color: var(--c-warn);    background: #fcf4e1; }
.callout.danger  { border-color: var(--c-danger);  background: #fbeae6; }
.callout.success { border-color: var(--c-success); background: #e8f3e8; }

/* ==========================================================================
   Code
   ========================================================================== */

pre {
  background: var(--c-darker);
  color: #e4d8bd;
  padding: 16px 18px;
  border-radius: var(--r-card);
  overflow-x: auto;
  font-size: 13px;
  line-height: 1.55;
  margin: 14px 0;
  border-left: 3px solid var(--c-gold);
}
code {
  font-family: 'SF Mono', Monaco, Consolas, 'Liberation Mono', monospace;
}
p code, li code, td code, h3 code {
  background: var(--c-cream);
  color: var(--c-primary);
  padding: 2px 7px;
  border-radius: 3px;
  font-size: 12.5px;
  border: 1px solid var(--c-border);
  font-weight: 700;
}
pre code { background: transparent; border: none; padding: 0; color: inherit; font-weight: 400; }

/* ==========================================================================
   Tables
   ========================================================================== */

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  background: var(--c-white);
  border-radius: var(--r-card);
  overflow: hidden;
  margin: 14px 0;
  border: 1px solid var(--c-border);
}
th, td {
  padding: 10px 14px;
  text-align: left;
  border-bottom: 1px solid var(--c-border);
}
th {
  font-family: 'Red Hat Display', sans-serif;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--c-text-muted);
  font-weight: 700;
  background: var(--c-cream);
}
tr:last-child td { border-bottom: none; }

/* ==========================================================================
   Lists
   ========================================================================== */

ul, ol { padding-left: 22px; margin-bottom: 12px; color: var(--c-text-dark); }
li { margin-bottom: 6px; }

.checklist { list-style: none; padding: 0; }
.checklist li {
  padding: 10px 0 10px 32px;
  position: relative;
  color: var(--c-text-dark);
  border-bottom: 1px solid var(--c-border);
  font-size: 13.5px;
}
.checklist li:last-child { border-bottom: none; }
.checklist li::before {
  content: "";
  position: absolute;
  left: 0; top: 12px;
  width: 18px; height: 18px;
  border: 2px solid var(--c-gold);
  border-radius: 3px;
  background: var(--c-white);
}

/* ==========================================================================
   Chips / badges / pills
   ========================================================================== */

.chip {
  display: inline-block;
  padding: 2px 8px;
  border-radius: var(--r-pill);
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.04em;
  font-family: 'Red Hat Display', sans-serif;
  text-transform: uppercase;
  white-space: nowrap;
}
.chip.ok      { background: var(--c-success-bg); color: var(--c-success); }
.chip.warn    { background: var(--c-warn-bg);    color: var(--c-warn); }
.chip.bad     { background: var(--c-danger-bg); color: var(--c-danger); }
.chip.info    { background: var(--c-info-bg);   color: var(--c-info); }
.chip.dark    { background: var(--c-primary);   color: var(--c-gold); }
.chip.neutral { background: var(--c-cream);     color: var(--c-text-muted); }

/* ==========================================================================
   Buttons
   ========================================================================== */

.btn-cta {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 18px;
  background: var(--c-primary);
  color: var(--c-gold);
  border: none;
  border-radius: var(--r-pill);
  font-weight: 700;
  font-family: 'Red Hat Display', sans-serif;
  font-size: 12px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.15s;
}
.btn-cta:hover {
  background: var(--c-hover);
  color: var(--c-gold);
  transform: translateY(-1px);
}

/* ==========================================================================
   Footer
   ========================================================================== */

.footer {
  margin-top: 56px;
  padding-top: 20px;
  border-top: 1px solid var(--c-border);
  font-size: 11px;
  color: var(--c-text-muted);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-family: 'Red Hat Display', sans-serif;
}

/* ==========================================================================
   Prev / Next navigatie
   ========================================================================== */

.prev-next {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-top: 48px;
  padding-top: 24px;
  border-top: 1px solid var(--c-border);
}
.prev-next .pn-prev { text-align: left; }
.prev-next .pn-next { text-align: right; }
.prev-next a {
  display: inline-flex;
  flex-direction: column;
  gap: 2px;
  padding: 12px 18px;
  background: var(--c-white);
  border: 1px solid var(--c-border);
  border-radius: var(--r-card);
  text-decoration: none;
  transition: all 0.15s;
  min-width: 220px;
}
.prev-next a:hover {
  border-color: var(--c-gold);
  box-shadow: var(--shadow-card);
}
.prev-next .pn-dir {
  font-family: 'Red Hat Display', sans-serif;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--c-gold);
}
.prev-next .pn-label {
  font-family: 'Red Hat Display', sans-serif;
  font-size: 14px;
  font-weight: 700;
  color: var(--c-primary);
}

/* ==========================================================================
   TABS, voor pagina's met veel informatie
   ========================================================================== */

.tabs-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 2px;
  border-bottom: 2px solid var(--c-border);
  margin: 24px 0 28px;
}
.tabs-nav button {
  padding: 12px 20px;
  background: transparent;
  border: none;
  border-bottom: 3px solid transparent;
  margin-bottom: -2px;
  font-family: 'Red Hat Display', sans-serif;
  font-weight: 700;
  font-size: 12px;
  color: var(--c-text-muted);
  cursor: pointer;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  transition: all 0.15s;
}
.tabs-nav button:hover { color: var(--c-primary); background: var(--c-cream-soft); }
.tabs-nav button.active {
  color: var(--c-primary);
  border-bottom-color: var(--c-gold);
  background: var(--c-cream-soft);
}
[data-tab-panel] { display: none; }
[data-tab-panel].active { display: block; animation: tabFade 0.2s ease-out; }
@keyframes tabFade { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: translateY(0); } }

/* ==========================================================================
   Info pair (key-value blokjes voor projectgegevens)
   ========================================================================== */

.info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 14px;
  margin: 20px 0 24px;
}
.info-pair {
  background: var(--c-white);
  border: 1px solid var(--c-border);
  border-radius: var(--r-card);
  padding: 14px 16px;
}
.info-pair .k {
  font-family: 'Red Hat Display', sans-serif;
  font-size: 10px;
  font-weight: 800;
  color: var(--c-gold);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 4px;
}
.info-pair .v {
  font-weight: 700;
  color: var(--c-primary);
  font-size: 14px;
}

/* MoSCoW helper */
.moscow-card {
  background: var(--c-white);
  border: 1px solid var(--c-border);
  border-radius: var(--r-card);
  padding: 16px 18px;
  margin-bottom: 10px;
  border-left: 4px solid var(--c-gold);
}
.moscow-card.must    { border-left-color: var(--c-success); }
.moscow-card.should  { border-left-color: var(--c-info); }
.moscow-card.could   { border-left-color: var(--c-warn); }
.moscow-card.wont    { border-left-color: var(--c-text-muted); }
.moscow-card h4 { margin-bottom: 6px; font-size: 15px; display: flex; align-items: center; gap: 8px; }
.sp {
  margin-left: auto;
  flex-shrink: 0;
  font-size: 11px;
  font-weight: 800;
  color: var(--c-text-muted);
  background: var(--c-cream);
  border: 1px solid var(--c-border);
  border-radius: var(--r-pill);
  padding: 2px 9px;
  white-space: nowrap;
  font-family: 'Red Hat Display', sans-serif;
  letter-spacing: 0.03em;
}
.moscow-card p { font-size: 13px; margin-bottom: 0; color: var(--c-text-muted); }

/* ==========================================================================
   Accordion (harmonica), MoSCoW cards uitklap
   ========================================================================== */

details.moscow-card {
  padding: 0;
  overflow: hidden;
}
details.moscow-card > summary {
  list-style: none;
  padding: 16px 18px;
  padding-right: 44px;
  cursor: pointer;
  position: relative;
  user-select: none;
}
details.moscow-card > summary::-webkit-details-marker { display: none; }
details.moscow-card > summary::after {
  content: "›";
  position: absolute;
  right: 16px;
  top: 50%;
  transform: translateY(-50%) rotate(0deg);
  font-size: 20px;
  font-weight: 700;
  color: var(--c-text-muted);
  transition: transform 0.2s ease;
  line-height: 1;
}
details.moscow-card[open] > summary::after {
  transform: translateY(-50%) rotate(90deg);
}
details.moscow-card > summary h4 { margin-bottom: 4px; }
details.moscow-card > summary .summary-text {
  font-size: 13px;
  color: var(--c-text-muted);
  margin-bottom: 0;
}
details.moscow-card[open] > summary {
  border-bottom: 1px solid var(--c-border);
}

.accordion-body {
  padding: 16px 18px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
@media (max-width: 800px) {
  .accordion-body { grid-template-columns: 1fr; }
}

.accordion-section {
  background: var(--c-cream);
  border-radius: var(--r-card);
  padding: 12px 14px;
}
.accordion-section h5 {
  font-size: 10px;
  letter-spacing: 0.1em;
  color: var(--c-gold);
  margin-bottom: 7px;
}
.accordion-section p,
.accordion-section ul {
  font-size: 12.5px;
  color: var(--c-text-dark);
  margin-bottom: 0;
  line-height: 1.6;
}
.accordion-section ul { padding-left: 18px; }
.accordion-section li { margin-bottom: 4px; }
.accordion-section p:not(:last-child) { margin-bottom: 8px; }

/* ==========================================================================
   Responsive
   ========================================================================== */

@media (max-width: 960px) {
  .app { grid-template-columns: 1fr; }
  /* De sidebar schuift over de inhoud in plaats van erboven te staan: met het merk en
     zestien menu-items zou je anders eerst een schermlengte menu voorbij scrollen. */
  .sidebar {
    position: fixed;
    top: 0;
    bottom: 0;
    left: -260px;
    width: 260px;
    z-index: 60;
    transition: left 0.25s ease;
  }
  .sidebar.open { left: 0; box-shadow: 0 0 40px rgba(0,0,0,0.4); }
  .topbar-menu { display: inline-flex; }
  .content { padding: 24px 20px; }
  .grid-3, .grid-2 { grid-template-columns: 1fr; }
}

/* ==========================================================================
   INFOPANEEL, schuift van rechts in
   ========================================================================== */

.info-link {
  border-bottom: 1px dotted var(--c-gold);
  cursor: pointer;
  color: var(--c-primary);
  font-weight: 700;
}
.info-link::after {
  content: "i";
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 14px; height: 14px;
  margin-left: 4px;
  border-radius: 50%;
  background: var(--c-gold);
  color: var(--c-darker);
  font-family: 'Red Hat Display', sans-serif;
  font-size: 9px;
  font-weight: 800;
  vertical-align: 2px;
}
.info-link:hover { color: var(--c-hover); background: var(--c-cream-soft); }

.info-source { display: none; }

.drawer-overlay {
  position: fixed;
  inset: 0;
  background: rgba(18,16,12,0.35);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.22s ease;
  z-index: 90;
}
.drawer-overlay.open { opacity: 1; pointer-events: auto; }

.drawer {
  position: fixed;
  top: 0; right: 0;
  height: 100vh;
  width: 460px;
  max-width: 92vw;
  background: var(--c-cream-soft);
  border-left: 3px solid var(--c-gold);
  box-shadow: -8px 0 24px rgba(0,0,0,0.14);
  transform: translateX(100%);
  transition: transform 0.26s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 100;
  display: flex;
  flex-direction: column;
}
.drawer.open { transform: translateX(0); }

.drawer-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 24px 14px;
  border-bottom: 1px solid var(--c-border);
  background: var(--c-white);
}
.drawer-head .eyebrow { margin-bottom: 3px; }
.drawer-head h3 { margin: 0; font-size: 17px; }
.drawer-close {
  background: transparent;
  border: 1px solid var(--c-border);
  border-radius: 50%;
  width: 28px; height: 28px;
  flex-shrink: 0;
  cursor: pointer;
  font-size: 15px;
  line-height: 1;
  color: var(--c-text-muted);
  transition: all 0.15s;
}
.drawer-close:hover { background: var(--c-primary); color: var(--c-gold); border-color: var(--c-primary); }

.drawer-body {
  padding: 20px 24px 40px;
  overflow-y: auto;
  flex: 1;
  font-size: 13px;
}
.drawer-body h4 { font-size: 13px; margin: 16px 0 6px; }
.drawer-body h4:first-child { margin-top: 0; }
.drawer-body p, .drawer-body li { font-size: 13px; }
.drawer-body table { font-size: 12px; }

/* ==========================================================================
   TIJDLIJN
   ========================================================================== */

.timeline { position: relative; margin: 24px 0 8px; padding-left: 26px; }
.timeline::before {
  content: "";
  position: absolute;
  left: 6px; top: 6px; bottom: 6px;
  width: 2px;
  background: var(--c-border);
}
.tl-item { position: relative; padding: 0 0 22px 0; }
.tl-item::before {
  content: "";
  position: absolute;
  left: -25px; top: 4px;
  width: 12px; height: 12px;
  border-radius: 50%;
  background: var(--c-white);
  border: 2px solid var(--c-gold);
}
.tl-item.done::before   { background: var(--c-success); border-color: var(--c-success); }
.tl-item.active::before { background: var(--c-gold); box-shadow: 0 0 0 4px rgba(208,183,124,0.25); }
.tl-date {
  font-family: 'Red Hat Display', sans-serif;
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--c-gold);
}
.tl-title {
  font-family: 'Red Hat Display', sans-serif;
  font-weight: 800;
  font-size: 14.5px;
  color: var(--c-primary);
  margin-top: 1px;
}
.tl-desc { font-size: 12.5px; color: var(--c-text-muted); margin-top: 3px; font-weight: 600; }

/* ==========================================================================
   VOORTGANG
   ========================================================================== */

.progress {
  height: 8px;
  background: var(--c-border);
  border-radius: var(--r-pill);
  overflow: hidden;
  margin: 8px 0 4px;
}
.progress > span {
  display: block;
  height: 100%;
  background: var(--c-gold);
  border-radius: var(--r-pill);
}
/* auto-fit i.p.v. auto-fill: geen lege kolommen op brede schermen */
.kpi-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 14px; margin: 20px 0 24px; }
.kpi {
  background: var(--c-white);
  border: 1px solid var(--c-border);
  border-top: 3px solid var(--c-gold);
  border-radius: var(--r-card);
  padding: 14px 16px;
}
.kpi .n {
  font-family: 'Red Hat Display', sans-serif;
  font-size: 26px;
  font-weight: 800;
  color: var(--c-primary);
  line-height: 1.1;
}
.kpi .l {
  font-size: 11px;
  font-weight: 700;
  color: var(--c-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-top: 3px;
  font-family: 'Red Hat Display', sans-serif;
}

td .chip { vertical-align: 1px; }
.nowrap { white-space: nowrap; }

/* ==========================================================================
   BEHEER: toolbar, formulier, modal
   ========================================================================== */

.toolbar {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin: 16px 0 20px;
}
.toolbar .spacer { flex: 1; }
.toolbar input[type="search"],
.toolbar select {
  padding: 8px 12px;
  border: 1px solid var(--c-border);
  border-radius: var(--r-card);
  font-family: inherit;
  font-size: 13px;
  background: var(--c-white);
  color: var(--c-text-dark);
}
.toolbar input[type="search"] { min-width: 220px; }

.btn-ghost {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  background: var(--c-white);
  color: var(--c-primary);
  border: 1px solid var(--c-border);
  border-radius: var(--r-pill);
  font-family: 'Red Hat Display', sans-serif;
  font-weight: 700;
  font-size: 12px;
  cursor: pointer;
  transition: all 0.15s;
}
.btn-ghost:hover { border-color: var(--c-gold); background: var(--c-cream-soft); }
.btn-ghost.danger { color: var(--c-danger); }
.btn-ghost.danger:hover { background: var(--c-danger-bg); border-color: var(--c-danger); }

.chip.concept     { background: var(--c-cream);     color: var(--c-text-muted); }
.chip.in_review   { background: var(--c-warn-bg);   color: var(--c-warn); }
.chip.vastgesteld { background: var(--c-success-bg);color: var(--c-success); }

.clause-tag {
  display: inline-block;
  padding: 1px 7px;
  margin: 1px 2px;
  border-radius: 3px;
  background: var(--c-cream);
  border: 1px solid var(--c-border);
  font-size: 11px;
  font-weight: 700;
  font-family: 'Red Hat Display', sans-serif;
  color: var(--c-primary);
}

.table-empty {
  padding: 28px;
  text-align: center;
  color: var(--c-text-muted);
  background: var(--c-white);
  border: 1px dashed var(--c-border);
  border-radius: var(--r-card);
  font-weight: 600;
}

.row-actions { display: flex; gap: 6px; justify-content: flex-end; }
.icon-btn {
  border: 1px solid var(--c-border);
  background: var(--c-white);
  border-radius: 4px;
  width: 30px; height: 28px;
  cursor: pointer;
  font-size: 13px;
  color: var(--c-text-muted);
  transition: all 0.12s;
}
.icon-btn:hover { border-color: var(--c-gold); color: var(--c-primary); }
.icon-btn.danger:hover { border-color: var(--c-danger); color: var(--c-danger); }

/* Modal */
.modal-overlay {
  position: fixed; inset: 0;
  background: rgba(18,16,12,0.45);
  display: none;
  align-items: flex-start;
  justify-content: center;
  padding: 40px 20px;
  overflow-y: auto;
  z-index: 200;
}
.modal-overlay.open { display: flex; }
.modal {
  background: var(--c-cream-soft);
  border-radius: var(--r-card);
  border-top: 3px solid var(--c-gold);
  width: 720px; max-width: 100%;
  box-shadow: var(--shadow-hover);
}
.modal-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px 24px;
  background: var(--c-white);
  border-bottom: 1px solid var(--c-border);
}
.modal-head h2 { margin: 0; }
.modal-body { padding: 20px 24px; }
.modal-foot {
  display: flex; gap: 10px; justify-content: flex-end;
  padding: 16px 24px;
  border-top: 1px solid var(--c-border);
  background: var(--c-white);
}

.field { margin-bottom: 16px; }
.field > label {
  display: block;
  font-family: 'Red Hat Display', sans-serif;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--c-gold);
  margin-bottom: 6px;
}
.field input[type="text"],
.field select,
.field textarea {
  width: 100%;
  padding: 9px 12px;
  border: 1px solid var(--c-border);
  border-radius: var(--r-card);
  font-family: inherit;
  font-size: 13px;
  background: var(--c-white);
  color: var(--c-text-dark);
}
.field textarea { min-height: 180px; resize: vertical; font-family: 'SF Mono', Monaco, Consolas, monospace; line-height: 1.5; }
.field-row { display: grid; grid-template-columns: 1fr 140px 120px; gap: 12px; }
@media (max-width: 620px) { .field-row { grid-template-columns: 1fr; } }

.clause-picker {
  max-height: 220px;
  overflow-y: auto;
  border: 1px solid var(--c-border);
  border-radius: var(--r-card);
  background: var(--c-white);
  padding: 10px 12px;
}
.clause-picker .cp-group {
  font-family: 'Red Hat Display', sans-serif;
  font-size: 10px; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--c-gold); font-weight: 800;
  margin: 10px 0 6px;
}
.clause-picker .cp-group:first-child { margin-top: 0; }
.clause-picker label {
  display: inline-flex; align-items: baseline; gap: 6px;
  width: 100%;
  padding: 3px 0;
  font-size: 12.5px;
  cursor: pointer;
}
.clause-picker label:hover { color: var(--c-primary); }
.clause-picker .cp-code { font-weight: 800; font-family: 'Red Hat Display', sans-serif; min-width: 52px; }

.file-box {
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
  padding: 12px 14px;
  background: var(--c-white);
  border: 1px solid var(--c-border);
  border-radius: var(--r-card);
  font-size: 13px;
}
.file-box .fname { font-weight: 700; color: var(--c-primary); }

/* ==========================================================================
   REGISTER: volle breedte, lijst links + detailpaneel rechts
   ========================================================================== */

/* Pagina's die de volle schermbreedte mogen gebruiken */
.content--full { max-width: none; }

/* Blokken die niet oneindig mogen meerekken op een ultrabreed scherm:
   tegels en de dekkingstabellen blijven leesbaar, de lijst mag wel breed. */
.content--full .kpi-grid { max-width: 1240px; }
.content--full .coverage { max-width: 1100px; }

.register-split {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  align-items: start;
}

/* Vanaf een breed venster: lijst en detail naast elkaar, elk de helft */
@media (min-width: 1360px) {
  .register-split {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  }
  .detail-pane {
    position: sticky;
    top: calc(var(--topbar-h) + 16px);
    max-height: calc(100vh - var(--topbar-h) - 40px);
    overflow-y: auto;
    overscroll-behavior: contain;
  }
}

/* Smal venster: detail boven de lijst zodra er iets is geselecteerd */
@media (max-width: 1359px) {
  .detail-pane { order: -1; }
}

.register-list { min-width: 0; }

/* Klikbare rijen */
.doc-row { cursor: pointer; transition: background 0.12s; }
.doc-row:hover { background: var(--c-cream-soft); }
.doc-row.selected {
  background: var(--c-cream);
  box-shadow: inset 3px 0 0 var(--c-gold);
}
.doc-row.selected td:first-child strong { color: var(--c-primary); }
.doc-row .title-cell { font-weight: 700; color: var(--c-primary); }
.doc-row .sub-cell {
  font-size: 11px;
  color: var(--c-text-muted);
  font-weight: 600;
  margin-top: 2px;
}

/* Detailpaneel */
.detail-card {
  background: var(--c-white);
  border: 1px solid var(--c-border);
  border-top: 3px solid var(--c-gold);
  border-radius: var(--r-card);
  box-shadow: var(--shadow-card);
}
.detail-head {
  padding: 18px 22px 16px;
  border-bottom: 1px solid var(--c-border);
  background: var(--c-cream-soft);
  position: sticky;
  top: 0;
  z-index: 2;
}
.detail-head h2 { margin: 4px 0 0; font-size: 19px; line-height: 1.25; padding-right: 8px; }
.detail-head .chips { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 10px; }

/* Acties rechtsboven: altijd bereikbaar, ongeacht het actieve tabblad */
.detail-head-actions {
  float: right;
  display: flex;
  gap: 6px;
  margin-left: 12px;
}
.detail-head-actions .icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  border-radius: 50%;
  width: 28px; height: 28px;
  border-bottom: 1px solid var(--c-border);
}

/* Tabbladen in het detailpaneel, compacter dan de paginabrede variant */
.detail-tabs {
  display: flex;
  gap: 2px;
  margin: 14px -22px -16px;
  padding: 0 22px;
  border-bottom: 2px solid var(--c-border);
  overflow-x: auto;
}
.detail-tabs button {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 13px;
  background: transparent;
  border: none;
  border-bottom: 3px solid transparent;
  margin-bottom: -2px;
  font-family: 'Red Hat Display', sans-serif;
  font-weight: 700;
  font-size: 11.5px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--c-text-muted);
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.15s;
}
.detail-tabs button:hover { color: var(--c-primary); }
.detail-tabs button.active {
  color: var(--c-primary);
  border-bottom-color: var(--c-gold);
  background: var(--c-white);
}
.tab-badge {
  background: var(--c-cream);
  border: 1px solid var(--c-border);
  color: var(--c-text-muted);
  border-radius: var(--r-pill);
  padding: 0 6px;
  font-size: 10px;
  font-weight: 800;
  line-height: 15px;
}
.detail-tabs button.active .tab-badge { background: var(--c-cream); color: var(--c-primary); }
.tab-badge.warn { background: var(--c-warn-bg); color: var(--c-warn); border-color: var(--c-warn-bg); }

.detail-body { padding: 20px 22px 26px; }
.detail-body > .md-body > *:first-child { margin-top: 0; }

/* Samenvatting boven de openstaande punten */
.open-summary {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 12px;
  margin-bottom: 18px;
}
.open-summary > div {
  background: var(--c-cream-soft);
  border: 1px solid var(--c-border);
  border-left: 3px solid var(--c-warn);
  border-radius: var(--r-card);
  padding: 12px 14px;
}
.open-summary .n {
  display: block;
  font-family: 'Red Hat Display', sans-serif;
  font-size: 24px; font-weight: 800;
  color: var(--c-primary); line-height: 1.1;
}
.open-summary .l {
  display: block;
  font-size: 11px; font-weight: 700;
  color: var(--c-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-top: 2px;
}

.detail-section { margin-bottom: 22px; }
.detail-section:last-child { margin-bottom: 0; }
.detail-section > h5 {
  font-size: 10px;
  letter-spacing: 0.1em;
  color: var(--c-gold);
  margin-bottom: 8px;
  padding-bottom: 5px;
  border-bottom: 1px solid var(--c-border);
}

.detail-meta {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 10px;
}
.detail-meta .k {
  font-family: 'Red Hat Display', sans-serif;
  font-size: 9.5px; font-weight: 800;
  letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--c-text-muted);
}
.detail-meta .v { font-weight: 700; color: var(--c-primary); font-size: 13px; margin-top: 1px; }

.detail-actions { display: flex; gap: 8px; flex-wrap: wrap; }

/* Norm-eisen in het detailpaneel */
.clause-line {
  display: flex;
  gap: 10px;
  align-items: baseline;
  padding: 6px 6px 6px 0;
  border-bottom: 1px dotted var(--c-border);
  font-size: 12.5px;
  cursor: pointer;
  border-radius: 3px;
}
.clause-line:hover { background: var(--c-cream-soft); }
.clause-line:last-child { border-bottom: none; }
.clause-line .cl-meta {
  margin-left: auto;
  flex-shrink: 0;
  font-size: 10px;
  font-weight: 800;
  font-family: 'Red Hat Display', sans-serif;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--c-text-muted);
  white-space: nowrap;
}
.clause-line .cl-meta.solo { color: var(--c-warn); }
.clause-line .cl-code {
  font-family: 'Red Hat Display', sans-serif;
  font-weight: 800;
  color: var(--c-primary);
  min-width: 56px;
  flex-shrink: 0;
}
.clause-line .cl-title { color: var(--c-text-dark); }
.clause-group {
  font-family: 'Red Hat Display', sans-serif;
  font-size: 9.5px; font-weight: 800;
  letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--c-text-muted);
  margin: 12px 0 4px;
}
.clause-group:first-child { margin-top: 0; }

.detail-empty {
  padding: 60px 30px;
  text-align: center;
  color: var(--c-text-muted);
  font-weight: 600;
  background: var(--c-white);
  border: 1px dashed var(--c-border);
  border-radius: var(--r-card);
}
.detail-empty .big { font-size: 30px; color: var(--c-border); display: block; margin-bottom: 10px; }

/* ==========================================================================
   Gerenderde markdown in het detailpaneel
   ========================================================================== */

.md-body { font-size: 13.5px; line-height: 1.6; }
.md-body > *:first-child { margin-top: 0; }
.md-body h1 { font-size: 19px; margin: 22px 0 10px; }
.md-body h2 {
  font-size: 16px;
  margin: 24px 0 10px;
  padding-bottom: 5px;
  border-bottom: 1px solid var(--c-border);
}
.md-body h3 { font-size: 14px; margin: 18px 0 7px; }
.md-body h4 { font-size: 13px; margin: 14px 0 6px; }
.md-body p { margin-bottom: 11px; }
.md-body ul, .md-body ol { margin-bottom: 11px; padding-left: 20px; }
.md-body li { margin-bottom: 4px; }
.md-body table { font-size: 12px; margin: 12px 0; }
.md-body th, .md-body td { padding: 7px 10px; vertical-align: top; }
.md-body hr {
  border: none;
  border-top: 1px solid var(--c-border);
  margin: 20px 0;
}
.md-body blockquote {
  border-left: 3px solid var(--c-gold);
  background: var(--c-cream-soft);
  padding: 10px 14px;
  margin: 14px 0;
  border-radius: 0 var(--r-card) var(--r-card) 0;
}
.md-body blockquote p:last-child { margin-bottom: 0; }
.md-body code {
  background: var(--c-cream);
  color: var(--c-primary);
  padding: 1px 5px;
  border-radius: 3px;
  font-size: 11.5px;
  border: 1px solid var(--c-border);
  font-weight: 700;
}
/* "(in te vullen)" valt op als openstaand veld */
.md-body em { color: var(--c-warn); font-style: normal; font-weight: 700; }

/* ==========================================================================
   Openstaande punten: actiekaarten, deadline-groepen en de kruistabel
   ========================================================================== */

.anker-groep { margin-bottom: 26px; }
.anker-groep > h5 {
  font-family: 'Red Hat Display', sans-serif;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--c-primary);
  padding-bottom: 6px;
  margin-bottom: 12px;
  border-bottom: 2px solid var(--c-gold);
}

.actie {
  background: var(--c-white);
  border: 1px solid var(--c-border);
  border-left: 3px solid var(--c-text-muted);
  border-radius: var(--r-card);
  padding: 14px 16px;
  margin-bottom: 12px;
}
.actie.status-gereed   { border-left-color: var(--c-success); opacity: 0.62; }
.actie.status-bezig    { border-left-color: var(--c-info); }
.actie.status-vervallen{ border-left-color: var(--c-border); opacity: 0.45; }
.actie.status-open     { border-left-color: var(--c-warn); }
.actie.status-geparkeerd { border-left-color: var(--c-info); background: var(--c-cream-soft); opacity: 0.72; }
.actie.status-geparkeerd .actie-niveaus { display: none; }

.actie-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.actie-head h4 {
  font-family: 'Red Hat Display', sans-serif;
  font-size: 15px;
  font-weight: 700;
  color: var(--c-primary);
  line-height: 1.35;
  margin: 2px 0 0;
}
.actie-herkomst {
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--c-text-muted);
}

.chip.risico-hoog   { background: var(--c-danger-bg);  color: var(--c-danger); }
.chip.risico-midden { background: var(--c-warn-bg);    color: var(--c-warn); }
.chip.risico-laag   { background: var(--c-cream);      color: var(--c-text-muted); }

.actie-chips { display: flex; flex-wrap: wrap; gap: 5px; margin: 10px 0 12px; }
.actie-chips .chip { background: var(--c-info-bg); color: var(--c-info); }

.actie-niveaus { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
@media (max-width: 900px) { .actie-niveaus { grid-template-columns: 1fr; } }
.niveau {
  background: var(--c-cream-soft);
  border: 1px solid var(--c-border);
  border-radius: var(--r-card);
  padding: 10px 12px;
}
.niveau-min  { border-top: 3px solid var(--c-danger); }
.niveau-norm { border-top: 3px solid var(--c-success); }
.niveau h6 {
  font-family: 'Red Hat Display', sans-serif;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--c-text-muted);
  margin-bottom: 5px;
}
.niveau p { font-size: 12.5px; line-height: 1.55; color: var(--c-text-dark); margin: 0; }

.actie-beheer {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px dashed var(--c-border);
}
.actie-beheer label.wide { grid-column: 1 / -1; }
.actie-beheer label {
  display: block;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--c-text-muted);
  font-family: 'Red Hat Display', sans-serif;
}
.actie-beheer input,
.actie-beheer select,
.actie-beheer textarea {
  display: block;
  width: 100%;
  margin-top: 4px;
  padding: 6px 9px;
  border: 1px solid var(--c-border);
  border-radius: var(--r-card);
  font-family: inherit;
  font-size: 12.5px;
  font-weight: 600;
  text-transform: none;
  letter-spacing: 0;
  color: var(--c-text-dark);
  background: var(--c-white);
}
.actie-beheer input:focus,
.actie-beheer select:focus,
.actie-beheer textarea:focus { outline: none; border-color: var(--c-gold); }
.actie-beheer textarea {
  min-height: 68px;
  line-height: 1.5;
  resize: vertical;
  font-family: inherit;
}
@media (max-width: 700px) { .actie-beheer { grid-template-columns: 1fr; } }

/* Kruistabel oorzaak x interventie */
.matrix-wrap { margin: 8px 0 30px; }
.matrix-wrap h3 { font-size: 17px; margin-bottom: 2px; }
.matrix {
  width: 100%;
  border-collapse: collapse;
  margin-top: 12px;
  background: var(--c-white);
  border: 1px solid var(--c-border);
}
.matrix th, .matrix td {
  border: 1px solid var(--c-border);
  padding: 7px 10px;
  text-align: center;
  font-size: 12.5px;
}
.matrix tr > th:first-child { text-align: left; white-space: nowrap; }
.matrix th {
  font-family: 'Red Hat Display', sans-serif;
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--c-primary);
  background: var(--c-cream-soft);
}
.matrix td.leeg { color: var(--c-border); }
.matrix td.totaal { font-weight: 800; background: var(--c-cream-soft); font-family: 'Red Hat Display', sans-serif; }
.matrix-cel {
  border: none;
  background: none;
  font-family: 'Red Hat Display', sans-serif;
  font-size: 14px;
  font-weight: 800;
  color: var(--c-primary);
  cursor: pointer;
  padding: 2px 8px;
  border-radius: var(--r-pill);
}
.matrix-cel:hover { background: var(--c-gold); }

.chip.grond-norm_eis    { background: var(--c-primary);   color: var(--c-gold); }
.chip.grond-wettelijk   { background: var(--c-danger-bg); color: var(--c-danger); }
.chip.grond-afspraak    { background: var(--c-info-bg);   color: var(--c-info); }
.chip.grond-eigen_keuze { background: var(--c-cream);     color: var(--c-text-muted); border: 1px dashed var(--c-border); }
.actie-chips .chip[class*="grond-"] { background: inherit; }

/* Werkvoorraad: leesbare regellengte, ook op een ultrawide scherm */
.content--wide { max-width: 1280px; }

/* ==========================================================================
   Dragers: bundels die meerdere punten in een keer afsluiten
   ========================================================================== */

.drager {
  background: var(--c-white);
  border: 1px solid var(--c-border);
  border-left: 4px solid var(--c-gold);
  border-radius: var(--r-card);
  padding: 18px 20px;
  margin-bottom: 16px;
}
.drager.status-gereed { border-left-color: var(--c-success); opacity: 0.72; }
.drager.status-bezig  { border-left-color: var(--c-info); }

.drager-head { display: flex; gap: 16px; align-items: flex-start; }
.drager-code {
  font-family: 'Red Hat Display', sans-serif;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.06em;
  color: var(--c-white);
  background: var(--c-primary);
  border-radius: var(--r-card);
  padding: 5px 9px;
  flex: 0 0 auto;
}
.drager-titel { flex: 1; min-width: 0; }
.drager-titel h3 { font-size: 17px; line-height: 1.35; margin: 0 0 8px; }
.drager-chips { display: flex; flex-wrap: wrap; gap: 5px; }

.drager-cijfers { display: flex; gap: 18px; flex: 0 0 auto; text-align: right; }
.drager-cijfers .n {
  display: block;
  font-family: 'Red Hat Display', sans-serif;
  font-size: 26px; font-weight: 800;
  color: var(--c-primary); line-height: 1;
}
.drager-cijfers .l {
  display: block;
  font-size: 10px; font-weight: 700;
  color: var(--c-text-muted);
  text-transform: uppercase; letter-spacing: 0.05em;
  margin-top: 3px;
}

.drager-toelichting { margin: 14px 0 4px; max-width: 78ch; }
.drager-toelichting p { font-size: 13px; line-height: 1.65; margin: 0 0 9px; color: var(--c-text-dark); }
.drager-toelichting p:last-child { margin-bottom: 0; }

.drager-voet {
  display: flex; align-items: flex-end; justify-content: space-between;
  gap: 16px; flex-wrap: wrap;
  margin-top: 14px; padding-top: 14px;
  border-top: 1px dashed var(--c-border);
}
.drager-voet label {
  font-size: 10px; font-weight: 800;
  letter-spacing: 0.06em; text-transform: uppercase;
  color: var(--c-text-muted);
  font-family: 'Red Hat Display', sans-serif;
}
.drager-voet input {
  display: block; margin-top: 4px;
  padding: 6px 9px; min-width: 200px;
  border: 1px solid var(--c-border); border-radius: var(--r-card);
  font-family: inherit; font-size: 12.5px; font-weight: 600;
  text-transform: none; letter-spacing: 0;
  color: var(--c-text-dark); background: var(--c-white);
}
.drager-voet input:focus { outline: none; border-color: var(--c-gold); }
.drager-acties { display: flex; align-items: center; gap: 8px; }
.btn-cta[disabled] { opacity: 0.4; cursor: not-allowed; }

.drager-bewijs {
  margin-top: 12px; padding: 10px 12px;
  background: var(--c-success-bg); border-radius: var(--r-card);
  font-size: 12.5px; line-height: 1.55; white-space: pre-line;
}
.drager-punten { margin-top: 14px; }
.drager-punten table { font-size: 12.5px; }

/* ==========================================================================
   NORMTEKST: inhoudsopgave links, normtekst rechts
   ========================================================================== */

.norm-split {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  align-items: start;
}
@media (min-width: 1100px) {
  .norm-split { grid-template-columns: 260px minmax(0, 1fr); }
  .norm-toc {
    position: sticky;
    top: calc(var(--topbar-h) + 16px);
    max-height: calc(100vh - var(--topbar-h) - 40px);
    overflow-y: auto;
    overscroll-behavior: contain;
  }
}
/* Op een breed scherm mag de inhoudsopgave meer ruimte hebben. */
@media (min-width: 1600px) {
  .norm-split { gap: 32px; grid-template-columns: 320px minmax(0, 1fr); }
}

/* Inhoudsopgave */
.norm-toc {
  background: var(--c-white);
  border: 1px solid var(--c-border);
  border-radius: var(--r-card);
  padding: 12px 6px 14px;
}
.toc-kop {
  font-family: 'Red Hat Display', sans-serif;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--c-gold);
  padding: 2px 12px 10px;
}
.toc-leeg { padding: 10px 12px; font-size: 12.5px; color: var(--c-text-muted); font-weight: 600; }
.toc-rij { display: flex; align-items: flex-start; }
.toc-rij.verborgen { display: none; }
.toc-klap {
  flex: none;
  width: 20px; height: 24px;
  margin-top: 2px;
  background: none; border: none;
  color: var(--c-text-muted);
  font-family: 'Red Hat Display', sans-serif;
  font-size: 13px; font-weight: 700;
  cursor: pointer;
  border-radius: 3px;
}
.toc-klap:hover { color: var(--c-primary); background: var(--c-cream); }
.toc-klap.leeg { cursor: default; }
.toc-link {
  display: flex;
  gap: 7px;
  align-items: baseline;
  flex: 1;
  min-width: 0;
  padding: 4px 10px 4px 2px;
  border-bottom: none;
  border-left: 2px solid transparent;
  font-size: 12.5px;
  line-height: 1.35;
  font-weight: 600;
  color: var(--c-text-dark);
}
.toc-link:hover { background: var(--c-cream-soft); color: var(--c-primary); }
.toc-link.actief {
  background: var(--c-cream);
  border-left-color: var(--c-gold);
  color: var(--c-primary);
  font-weight: 700;
}
.toc-nr {
  flex: none;
  font-family: 'Red Hat Display', sans-serif;
  font-weight: 700;
  font-size: 11.5px;
  color: var(--c-text-muted);
  min-width: 34px;
}
.toc-link.actief .toc-nr { color: var(--c-primary); }
.toc-titel { min-width: 0; }
.toc-telling {
  flex: none;
  margin-left: auto;
  padding: 0 6px;
  border-radius: var(--r-pill);
  background: var(--c-cream);
  font-size: 10.5px;
  font-weight: 700;
  color: var(--c-text-muted);
}
.norm-toc .niveau1 .toc-link, .norm-toc .toc-link.niveau1 { padding-left: 14px; font-weight: 600; }
.norm-toc .niveau2 .toc-link, .norm-toc .toc-link.niveau2 { padding-left: 28px; font-size: 12px; color: var(--c-text-muted); }
.norm-toc .niveau3 .toc-link, .norm-toc .toc-link.niveau3 { padding-left: 42px; font-size: 12px; color: var(--c-text-muted); }
.norm-toc .niveau0 .toc-link, .norm-toc .toc-link.niveau0 {
  font-family: 'Red Hat Display', sans-serif;
  font-weight: 700;
  font-size: 13px;
  color: var(--c-primary);
}

/* De tekst zelf */
.norm-body {
  background: var(--c-white);
  border: 1px solid var(--c-border);
  border-radius: var(--r-card);
  padding: 28px 34px;
  max-width: 900px;
  font-size: 14px;
  line-height: 1.62;
}
.norm-sectie { scroll-margin-top: calc(var(--topbar-h) + 16px); }
.norm-sectie.verborgen { display: none; }
.norm-sectie.d0 { margin-top: 40px; padding-top: 8px; border-top: 2px solid var(--c-border); }
.norm-sectie.d0:first-child { margin-top: 0; border-top: none; }
.norm-sectie.d1 { margin-top: 26px; }
.norm-sectie.d2, .norm-sectie.d3 { margin-top: 20px; }

.norm-kop { display: flex; align-items: baseline; gap: 10px; margin-bottom: 10px; }
.norm-sectie.d0 > .norm-kop { font-size: 21px; }
.norm-nr { color: var(--c-gold); font-weight: 800; }
.norm-anker {
  margin-left: 4px;
  border-bottom: none;
  color: var(--c-border);
  font-size: 13px;
  font-weight: 700;
  opacity: 0;
  transition: opacity 0.12s;
}
.norm-kop:hover .norm-anker { opacity: 1; }
.norm-anker:hover { color: var(--c-gold); }

.norm-body p { margin-bottom: 11px; }
/* De norm zet zijn eigen streepje voor een opsomming; dat blijft staan. */
.norm-streep, .norm-punt {
  padding-left: 22px;
  text-indent: -22px;
  margin-bottom: 7px;
}
.norm-streep.in1, .norm-punt.in1 { margin-left: 22px; }
.norm-streep.in2, .norm-punt.in2 { margin-left: 44px; }
.norm-noot {
  font-size: 13px;
  color: var(--c-text-muted);
  background: var(--c-cream-soft);
  border-left: 2px solid var(--c-border);
  padding: 7px 12px;
  margin-bottom: 11px;
}
.norm-voetnoot {
  font-size: 12px;
  color: var(--c-text-muted);
  border-top: 1px solid var(--c-border);
  padding-top: 6px;
}
.norm-term { margin: 18px 0 4px; display: flex; align-items: baseline; gap: 9px; }
.norm-term-nr {
  font-family: 'Red Hat Display', sans-serif;
  font-size: 11px;
  font-weight: 700;
  color: var(--c-white);
  background: var(--c-primary);
  border-radius: 3px;
  padding: 1px 6px;
}
.norm-tabel { overflow-x: auto; }
.norm-tabel td.norm-code {
  white-space: nowrap;
  font-family: 'Red Hat Display', sans-serif;
  font-weight: 700;
  color: var(--c-primary);
}
.norm-tabel tr:target td { background: var(--c-cream); }

/* Onderkant van een gedrukte pagina: als merkteken in de tekst en als dun lijntje
   tussen twee blokken. Handig als je een citaat met paginanummer moet aanwijzen. */
.norm-blz {
  display: inline-block;
  margin: 0 3px;
  padding: 0 4px;
  border-radius: 3px;
  background: var(--c-cream);
  color: var(--c-text-muted);
  font-family: 'Red Hat Display', sans-serif;
  font-size: 10px;
  font-weight: 700;
  vertical-align: 1px;
}
.norm-blz-rule {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 14px 0;
  color: var(--c-text-muted);
}
.norm-blz-rule::before, .norm-blz-rule::after {
  content: '';
  flex: 1;
  border-top: 1px dashed var(--c-border);
}
.norm-blz-rule span {
  font-family: 'Red Hat Display', sans-serif;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.06em;
}
.norm-body mark { background: var(--c-warn-bg); color: var(--c-primary); border-radius: 2px; }

/* Verwijzing van een normelement naar de normtekst (pagina Normtekst) */
.detail-verwijzing { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 10px; }
.detail-verwijzing a {
  font-family: 'Red Hat Display', sans-serif;
  font-size: 12px;
  font-weight: 700;
  color: var(--c-primary);
  border-bottom: 1px solid var(--c-gold);
}
.detail-verwijzing a:hover { color: var(--c-gold); }

/* Normelement-verwijzing in de grondslag-chip van een punt */
.chip a { color: inherit; border-bottom: 1px solid currentColor; }
.chip a:hover { color: inherit; opacity: 0.75; }

/* Normtekst binnen het detailpaneel van Norm-dekking */
.detail-body .norm-sectie.d0,
.detail-body .norm-sectie.d1 { margin-top: 0; padding-top: 0; border-top: none; }
.detail-body .norm-sectie + .norm-sectie { margin-top: 18px; }
.detail-body .norm-anker { opacity: 1; color: var(--c-gold); }
.norm-tussenkop {
  margin: 22px 0 10px;
  padding-top: 12px;
  border-top: 1px solid var(--c-border);
  color: var(--c-text-muted);
}

/* Terugverwijzing vanaf de normtekst naar ons eigen dossier */
.norm-dossier {
  margin-left: 10px;
  padding: 1px 8px;
  border-radius: var(--r-pill);
  border-bottom: none;
  background: var(--c-cream);
  font-family: 'Red Hat Display', sans-serif;
  font-size: 10.5px;
  font-weight: 700;
  white-space: nowrap;
  color: var(--c-text-muted);
}
.norm-dossier:hover { background: var(--c-gold); color: var(--c-primary); }
.norm-tabel td.norm-code .norm-dossier { margin-left: 0; display: inline-block; margin-top: 4px; }


/* ============================================================================
   Inloggen: login.html, verify.html en unauthorized.html. Die pagina's staan los
   van de sidebar-layout, dus één gecentreerde kaart met de voetregel eronder.
   ============================================================================ */

.auth-scherm {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: var(--c-cream);
}

.auth-kaart {
  width: 100%;
  max-width: 420px;
  background: var(--c-white);
  border: 1px solid var(--c-border);
  border-radius: 14px;
  padding: 36px 32px 30px;
  box-shadow: var(--shadow-card);
  text-align: center;
}

.auth-kaart h1 { margin: 6px 0 4px; font-size: 26px; }
.auth-kaart .lead { font-size: 14px; margin-bottom: 24px; }
.auth-kaart label { display: block; text-align: left; font-size: 13px; font-weight: 700; margin-bottom: 6px; }
.auth-kaart input[type="email"] {
  width: 100%;
  padding: 11px 12px;
  margin-bottom: 12px;
  border: 1px solid var(--c-border);
  border-radius: 8px;
  font: inherit;
}
.auth-kaart input[type="email"]:focus { outline: 2px solid var(--c-gold); outline-offset: 1px; }

/* Dezelfde vorm als het merk in de sidebar: een afgeronde vierhoek, geen cirkel. */
.auth-avatar {
  border-radius: 14px;
  object-fit: cover;
  margin-bottom: 14px;
  border: 2px solid rgba(208,183,124,0.45);
  box-shadow: 0 4px 20px rgba(208,183,124,0.22);
}
/* min-height houdt de twee knoppen op de kaart even hoog; het Microsoft-logo maakt zijn
   knop anders 4px hoger dan de knop met alleen tekst. */
.auth-breed {
  display: flex;
  width: 100%;
  min-height: 38px;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
}

.auth-scheiding {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 20px 0 18px;
  color: var(--c-text-muted);
  font-size: 12px;
  font-weight: 600;
}
.auth-scheiding::before, .auth-scheiding::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--c-border);
}

/* Inloggen met Microsoft: dezelfde maten als .btn-cta, maar met een rand in plaats van
   een vulling — het logo moet leesbaar blijven en dit is de tweede keuze op de kaart. */
.auth-microsoft {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  padding: 9px 18px;
  background: var(--c-white);
  color: var(--c-primary);
  border: 1px solid var(--c-border);
  border-radius: var(--r-pill);
  font-family: 'Red Hat Display', sans-serif;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  text-decoration: none;
  transition: background 0.15s, border-color 0.15s;
}
.auth-microsoft:hover { background: var(--c-cream-soft); border-color: var(--c-gold); }

.auth-melding { min-height: 20px; margin-top: 14px; font-size: 13px; color: var(--c-text-muted); }
.auth-melding.ok  { color: var(--c-success); }
.auth-melding.fout { color: var(--c-danger); }

.auth-voet {
  margin-top: 20px;
  font-size: 11px;
  font-weight: 600;
  color: var(--c-text-muted);
  text-align: center;
}
