/* Clipping HQ: eigen palet voor de clipping. Warm zwart, gebroken wit, saffraan alleen op data en de ene actie.
   Raster: zijbalk 224px, canvas met 28px rand; blokken in een raster met een tussenruimte van 16px. */
:root {
  --ground: #0c0b09;
  --surface: #14130f;
  --raised: #1c1a15;
  --active: #26231c;
  --border: #2a2720;
  --rule: #201e19;
  --control: #4a4538;
  --text: #f3efe6;
  --muted: #bdb5a5;
  --faint: #9a9282;
  --accent: #f0b429;
  --accent-ink: #0c0b09;
  --positive: #8fd19e;
  --pill-positive-bg: #17261b;
  --negative: #ff8a75;
  --pill-negative-bg: #2e1915;
  --pill-wait-bg: #2a2212;
  --pill-wait-ink: #f3cf7a;
  --gap: 16px;
  --pad: 28px;
  --radius: 8px;
  --font: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}
* { box-sizing: border-box; }
html { background: var(--ground); color: var(--text); font: 14px/20px var(--font); -webkit-text-size-adjust: 100%; }
body { margin: 0; min-height: 100vh; }
a { color: var(--text); text-decoration: none; }
a:hover { color: var(--accent); }
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 4px; }
h1 { font-size: 24px; line-height: 30px; font-weight: 650; margin: 0; letter-spacing: -0.01em; }
h2 { font-size: 15px; line-height: 20px; font-weight: 600; margin: 0; }
h3 { font-size: 13px; line-height: 18px; font-weight: 600; margin: 18px 0 8px; color: var(--muted); }
.num, td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; }
.grijs { color: var(--muted); }
.klein { font-size: 12px; }
.slecht { color: var(--negative); }
.goed { color: var(--positive); }
.leeg { color: var(--faint); }
.eenheid { color: var(--muted); font-size: 12px; }
.vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.voor { white-space: pre-wrap; }

/* schil */
.schil { display: grid; grid-template-columns: 224px minmax(0, 1fr); min-height: 100vh; }
.zij { position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column; padding: 20px 12px; }
.product { display: flex; align-items: center; gap: 10px; font-weight: 650; font-size: 15px; padding: 4px 10px 20px; }
.product:hover { color: var(--text); }
.zij nav { display: flex; flex-direction: column; gap: 2px; }
.zij nav a { display: block; padding: 7px 10px; border-radius: 6px; color: var(--muted); }
.zij nav a:hover { color: var(--text); background: var(--surface); }
.zij nav a.actief { color: var(--text); background: var(--active); }
.wie { margin-top: auto; padding: 12px 10px 0; border-top: 1px solid var(--rule); display: grid; gap: 4px; color: var(--muted); font-size: 12px; }
.wie span:first-child { color: var(--text); font-size: 13px; }
.ro { color: var(--faint); }
.tekstknop { background: none; border: 0; padding: 0; color: var(--muted); font: inherit; cursor: pointer; text-align: left; }
.tekstknop:hover { color: var(--accent); }
.canvas { padding: 24px var(--pad) 40px; min-width: 0; border-left: 1px solid var(--rule); }
.onder { display: block; color: var(--faint); font-size: 12px; line-height: 16px; }
.titelrij { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; margin-bottom: 20px; }
.sub { margin: 6px 0 0; color: var(--muted); }
.sub a { color: var(--muted); text-decoration: underline; text-decoration-color: var(--control); }
.voet { margin-top: 32px; color: var(--faint); font-size: 12px; }

/* raster en blokken */
.raster { display: grid; gap: var(--gap); margin-bottom: var(--gap); align-items: start; }
.raster.twee { grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); }
.raster.twee.gelijk { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
.kolom { display: grid; gap: var(--gap); }
.blok { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px 18px; margin-bottom: var(--gap); min-width: 0; }
.raster > .blok, .kolom > .blok { margin-bottom: 0; }
.blokkop { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; margin-bottom: 12px; }
.blokrechts { color: var(--muted); font-size: 12px; }
.blokrechts a { color: var(--muted); }
.blokrechts a:hover { color: var(--accent); }
.leegzin { margin: 4px 0; padding: 10px 12px; border: 1px dashed var(--border); border-radius: 6px; color: var(--muted); }
.foutzin { margin: 4px 0 12px; padding: 10px 12px; border-radius: 6px; background: var(--pill-negative-bg); color: var(--negative); }
.melding { padding: 10px 12px; border-radius: 6px; background: var(--pill-wait-bg); color: var(--pill-wait-ink); }

/* KPI strook: een container, gedeeld door lijnen */
.kpis { display: grid; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); margin-bottom: var(--gap); }
.blok .kpis { border: 0; background: none; margin: 0 -18px; }
.kpis.drie { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.kpis.vier { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.kpis.vijf { grid-template-columns: repeat(5, minmax(0, 1fr)); }
.kpis.zes { grid-template-columns: repeat(6, minmax(0, 1fr)); }
.kpis > div { padding: 12px 18px; display: grid; gap: 4px; border-left: 1px solid var(--rule); min-width: 0; }
.kpis > div:first-child { border-left: 0; }
.kpis .label { color: var(--muted); font-size: 12px; }
.kpis .waarde { font-size: 24px; line-height: 30px; font-weight: 500; font-variant-numeric: tabular-nums; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* tabellen */
.tabelbak { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
th { text-align: left; font-weight: 400; color: var(--muted); font-size: 12px; padding: 8px 10px; white-space: nowrap; border-bottom: 1px solid var(--border); }
th a { color: var(--muted); }
th a:hover { color: var(--text); }
th[aria-sort] a { color: var(--text); }
.pijl { color: var(--accent); }
td { padding: 9px 10px; border-bottom: 1px solid var(--rule); white-space: nowrap; vertical-align: top; }
td.breed, th.breed { white-space: normal; min-width: 220px; }
td.breed { overflow-wrap: anywhere; }
td a { color: var(--text); }
td a:hover { color: var(--accent); }
tr:last-child td { border-bottom: 0; }
tbody tr:hover td { background: var(--raised); }
.leegrij { color: var(--muted); text-align: left; white-space: normal; }
td.sterk { color: var(--accent); font-weight: 600; }
.matrix th[scope=row] { color: var(--text); font-size: 14px; padding: 10px 10px 10px 0; white-space: normal; }
.matrix td { padding: 10px; vertical-align: middle; }
.rijuitleg { display: block; color: var(--faint); font-size: 12px; line-height: 16px; }
.groot { font-size: 20px; font-weight: 600; }
.paginas { display: flex; gap: 16px; justify-content: flex-end; padding: 10px 2px 0; color: var(--muted); font-size: 12px; }
.paginas a { color: var(--text); }

/* pillen */
.pil { display: inline-block; padding: 1px 8px; border-radius: 999px; font-size: 12px; line-height: 18px; background: var(--raised); color: var(--muted); white-space: nowrap; }
.pil.goed { background: var(--pill-positive-bg); color: var(--positive); }
.pil.slecht { background: var(--pill-negative-bg); color: var(--negative); }
.pil.wacht { background: var(--pill-wait-bg); color: var(--pill-wait-ink); }

/* filters */
.filters { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 10px 14px; margin: 0 0 14px; }
.filters label { display: grid; gap: 4px; color: var(--muted); font-size: 12px; }
select, input { height: 34px; background: var(--surface); color: var(--text); border: 1px solid var(--control); border-radius: 6px; padding: 0 10px; font: 14px var(--font); min-width: 0; }
select { padding-right: 6px; max-width: 260px; }
.knop { height: 34px; display: inline-flex; align-items: center; justify-content: center; padding: 0 16px; border-radius: 6px; border: 0; background: var(--accent); color: var(--accent-ink); font: 600 14px var(--font); cursor: pointer; }
.knop:hover { color: var(--accent-ink); filter: brightness(1.08); }
.knop.vol { width: 100%; height: 40px; }
.tekstlink { color: var(--muted); height: 34px; display: inline-flex; align-items: center; }

/* postbord: 15 kanalen maal 4 plekken */
.bordkop { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; flex-wrap: wrap; margin-bottom: 10px; }
.bordkop .groot { font-size: 30px; line-height: 36px; font-weight: 600; color: var(--accent); }
.legenda { display: flex; align-items: center; gap: 6px; color: var(--muted); font-size: 12px; flex-wrap: wrap; }
.legenda .stip { margin-left: 8px; }
.postbord { list-style: none; margin: 0; padding: 0; }
.postbord li { display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr) auto 44px; align-items: center; gap: 12px; padding: 7px 0; border-bottom: 1px solid var(--rule); }
.postbord li:last-child { border-bottom: 0; }
.kanaalnaam { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.niche { color: var(--muted); font-size: 12px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.stippen { display: flex; gap: 6px; }
.telling { color: var(--muted); }
.stip { display: inline-block; width: 14px; height: 14px; border-radius: 3px; border: 1.5px solid var(--control); background: transparent; flex: none; }
.stip.klaar { background: var(--accent); border-color: var(--accent); }
.stip.gepland { border-color: var(--accent); }
.stip.mis { background: var(--negative); border-color: var(--negative); }
.stip.over { background: var(--control); }
.stip.open { border-style: dashed; }

/* lijsten */
.lijst { list-style: none; margin: 0; padding: 0; }
.lijst li { display: grid; grid-template-columns: 96px 120px minmax(0, 1fr); gap: 12px; padding: 8px 0; border-bottom: 1px solid var(--rule); align-items: baseline; }
.lijst li:last-child { border-bottom: 0; }
.lijst.runs li { grid-template-columns: minmax(0, 1fr) auto 96px; }
.lijst.twee li { grid-template-columns: 160px minmax(0, 1fr); }
.facetten.compact { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 28px; }
.facetten.compact td.breed, .facetten.compact th.breed { min-width: 140px; }
.tijdje { color: var(--muted); font-size: 12px; font-variant-numeric: tabular-nums; }
.bron { color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* sleutel waarde */
.kv { display: grid; grid-template-columns: minmax(110px, 180px) minmax(0, 1fr); gap: 0; margin: 0; }
.kv dt { color: var(--muted); padding: 7px 12px 7px 0; border-bottom: 1px solid var(--rule); }
.kv dd { margin: 0; padding: 7px 0; border-bottom: 1px solid var(--rule); overflow-wrap: anywhere; }
details summary { cursor: pointer; color: var(--muted); margin-top: 12px; }

/* grafieken */
.grafiek svg { width: 100%; height: auto; display: block; }
.grafiek .as { fill: var(--faint); font-size: 11px; font-family: var(--font); }
.leeggrafiek svg { height: 40px; }

/* facetten */
.facet { margin-bottom: 18px; }
.facet h3 { color: var(--text); font-size: 14px; margin: 18px 0 6px; }
.staaf { display: block; height: 3px; margin-top: 6px; background: transparent; max-width: 320px; }
.staaf .vul { display: block; height: 3px; background: var(--muted); border-radius: 2px; width: 0; }
tr:first-child .staaf .vul { background: var(--accent); }
.w1{width:5%}.w2{width:10%}.w3{width:15%}.w4{width:20%}.w5{width:25%}.w6{width:30%}.w7{width:35%}.w8{width:40%}.w9{width:45%}.w10{width:50%}
.w11{width:55%}.w12{width:60%}.w13{width:65%}.w14{width:70%}.w15{width:75%}.w16{width:80%}.w17{width:85%}.w18{width:90%}.w19{width:95%}.w20{width:100%}

/* inloggen en instellen */
.kaal { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 24px; }
.inlogkaart { width: 100%; max-width: 380px; background: var(--surface); border: 1px solid var(--border); border-radius: 12px; padding: 28px; }
.inlogkaart.breed { max-width: 440px; }
.inlogkaart h1 { margin: 14px 0 6px; font-size: 22px; }
.inlogkaart form { display: grid; gap: 14px; margin-top: 18px; }
.inlogkaart label { display: grid; gap: 6px; color: var(--muted); font-size: 13px; }
.inlogkaart input { height: 40px; width: 100%; }
.qr { background: #f3efe6; border-radius: 8px; padding: 8px; width: max-content; margin: 16px auto 8px; }
.qr svg { display: block; }
.sleutel { text-align: center; font-variant-numeric: tabular-nums; letter-spacing: 0.08em; color: var(--muted); word-break: break-all; }

/* tablet en telefoon */
@media (max-width: 1100px) {
  .schil { grid-template-columns: minmax(0, 1fr); }
  .zij { position: sticky; top: 0; z-index: 5; height: auto; flex-direction: row; align-items: center; gap: 8px; padding: 8px 12px; background: var(--ground); border-right: 0; border-bottom: 1px solid var(--rule); }
  .product { padding: 4px 8px 4px 0; flex: none; }
  .product span { display: none; }
  .zij nav { flex-direction: row; overflow-x: auto; flex: 1; scrollbar-width: none; }
  .zij nav a { white-space: nowrap; padding: 8px 10px; }
  .wie { margin: 0; padding: 0; border: 0; display: flex; flex: none; }
  .wie span { display: none; }
  .canvas { border-left: 0; }
  .raster.twee, .raster.twee.gelijk, .facetten.compact { grid-template-columns: minmax(0, 1fr); }
  .kpis.vijf, .kpis.zes { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .kpis.vijf > div:nth-child(4), .kpis.zes > div:nth-child(4) { border-left: 0; }
  .kpis.vijf > div:nth-child(n+4), .kpis.zes > div:nth-child(n+4) { border-top: 1px solid var(--rule); }
}
@media (max-width: 640px) {
  :root { --pad: 16px; }
  .titelrij { flex-direction: column; align-items: flex-start; }
  h1 { font-size: 21px; line-height: 26px; }
  .kpis.drie, .kpis.vier, .kpis.vijf, .kpis.zes { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .kpis > div { border-left: 0; border-top: 1px solid var(--rule); }
  .kpis > div:nth-child(-n+2) { border-top: 0; }
  .kpis > div:nth-child(even) { border-left: 1px solid var(--rule); }
  .kpis.drie > div:last-child, .kpis.vijf > div:last-child { grid-column: 1 / -1; border-left: 0; }
  .kpis .waarde { font-size: 20px; }
  .matrix .eenheid, .matrix .rijuitleg { display: none; }
  .matrix th[scope=row] { font-size: 13px; }
  .matrix td { padding: 10px 6px; }
  .groot { font-size: 17px; }
  .postbord li { grid-template-columns: minmax(0, 1fr) auto 36px; }
  .postbord .niche { display: none; }
  .lijst li, .lijst.twee li { grid-template-columns: minmax(0, 1fr); gap: 2px; }
  .lijst.runs li { grid-template-columns: minmax(0, 1fr) auto; }
  .lijst.runs .tijdje { grid-column: 1 / -1; }
  .kv { grid-template-columns: minmax(0, 1fr); }
  .kv dt { border-bottom: 0; padding-bottom: 0; }
  .filters label { flex: 1 1 140px; }
  .filters select, .filters input { width: 100%; max-width: none; }
  .blok { padding: 14px; }
  .blok .kpis { margin: 0 -14px; }
}
