/* ────────────────────────────────────────────────────────────
   home.css — overzichtsscherm (tegels + panelen) van aididactiek.be
   2e druk. Kleurcode: roze = boek, geel = apps & aanbod (+ 1e druk),
   zwart-wit = basis. Lettertype: Inter, zoals in het boek.
   ────────────────────────────────────────────────────────────*/

@font-face {
  font-family: 'Inter';
  src: url('/fonts/inter-latin-opsz-normal.woff2') format('woff2');
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

:root {
  --ink: #000;
  --paper: #fff;
  --roze: #f5d6e6;      /* kaft 2e druk */
  --geel: #fff001;      /* kaft 1e druk */
  --grijs: #595959;
  --rule: 2px;
  --header-h: 84px;
  --footer-h: 52px;
  --font: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
  --ease: cubic-bezier(.2, .7, .2, 1);
}

* { box-sizing: border-box; margin: 0; padding: 0; }

html { -webkit-text-size-adjust: 100%; }

body.home {
  font-family: var(--font);
  font-size: 1rem;
  line-height: 1.55;
  color: var(--ink);
  background: var(--paper);
  font-optical-sizing: auto;
  overflow-x: hidden;
}

img, video { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }

:focus-visible { outline: 3px solid var(--ink); outline-offset: 2px; }

.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}

/* ── Knoppen ── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  min-height: 44px; padding: .6rem 1.1rem;
  border: var(--rule) solid var(--ink);
  font-weight: 700; font-size: .9375rem; line-height: 1.2;
  text-decoration: none; cursor: pointer;
  background: var(--paper); color: var(--ink);
  transition: background-color .15s, color .15s;
}
.btn-ink { background: var(--ink); color: var(--paper); }
.btn-ink:hover { background: var(--paper); color: var(--ink); }
.btn-roze { background: var(--roze); }
.btn-roze:hover { background: var(--ink); color: var(--paper); }
.btn-geel { background: var(--geel); }
.btn-geel:hover { background: var(--ink); color: var(--paper); }
.btn-line:hover { background: var(--ink); color: var(--paper); }

/* ── Kop: woordmerk zoals op de kaft ── */
.top {
  height: var(--header-h);
  display: flex; align-items: center; gap: 2rem;
  padding: 0 clamp(1rem, 2.2vw, 2rem);
  border-bottom: var(--rule) solid var(--ink);
  background: var(--paper);
  position: relative; z-index: 60;
}

.wordmark {
  display: inline-grid; text-decoration: none; color: var(--ink);
  line-height: 1; flex-shrink: 0;
}
.wm-hand {
  font-size: 2.6rem; font-weight: 900; letter-spacing: -0.055em;
  line-height: .86;
}
.wm-row {
  display: flex; justify-content: space-between; align-items: baseline;
  gap: .75rem; margin-top: .3rem;
}
.wm-author { font-size: .72rem; font-weight: 400; letter-spacing: 0; white-space: nowrap; }
.wm-ai { font-size: 1.12rem; font-weight: 800; letter-spacing: -0.03em; white-space: nowrap; }

.top-nav { display: flex; gap: .25rem; margin-left: auto; }
.top-nav a {
  position: relative;
  padding: .55rem .7rem; text-decoration: none;
  font-weight: 600; font-size: .9375rem;
}
.top-nav a::after {
  content: ''; position: absolute; left: .7rem; right: .7rem; bottom: .2rem;
  height: 6px; background: transparent;
}
.top-nav a:hover::after { background: var(--ink); height: 2px; }
.top-nav a[data-theme="roze"][aria-current="true"]::after { background: var(--roze); height: 6px; }
.top-nav a[data-theme="geel"][aria-current="true"]::after { background: var(--geel); height: 6px; }
.top-nav a[data-theme="zw"][aria-current="true"]::after { background: var(--ink); height: 6px; }
.top .btn { flex-shrink: 0; }

/* ── Overzicht: tegels ── */
.board {
  display: grid;
  gap: var(--rule);
  background: var(--ink);        /* de 2px-lijnen tussen de tegels */
  grid-template-columns: 1fr;
}

.tile {
  position: relative;
  background: var(--paper);
  padding: 1.25rem 1.4rem 1.4rem;
  display: flex; flex-direction: column; gap: .9rem;
  min-width: 0;
  transition: background-color .18s;
}
.tile.roze:hover { background: var(--roze); }
.tile.geel:hover { background: var(--geel); }
.tile.zw:hover { background: var(--ink); color: var(--paper); }

/* Twee vaste kleurvlakken, zoals de vierkanten op de twee kaften */
.tile.vlak-roze, .tile.vlak-roze:hover { background: var(--roze); }
.tile.vlak-geel, .tile.vlak-geel:hover { background: var(--geel); }
.tile.vlak-roze:hover .tile-title, .tile.vlak-geel:hover .tile-title { text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 4px; }

.tile-title { font-size: 1.25rem; font-weight: 800; letter-spacing: -0.015em; line-height: 1.2; }
.tile-link {
  display: inline-flex; align-items: center; gap: .6rem;
  text-decoration: none; color: inherit;
}
.tile-link::after { content: ''; position: absolute; inset: 0; z-index: 1; }
.tile-link:focus-visible { outline: none; }
.tile-link:focus-visible::after { outline: 3px solid currentColor; outline-offset: -7px; }

.sq {
  width: 15px; height: 15px; flex-shrink: 0;
  border: var(--rule) solid var(--ink);
}
.roze .sq { background: var(--roze); }
.geel .sq { background: var(--geel); }
.zw .sq { background: var(--ink); }
.tile.zw:hover .sq { border-color: var(--paper); }

/* Links binnen een tegel liggen boven de tegel-link */
.tile a:not(.tile-link), .tile button { position: relative; z-index: 2; }

.num {
  font-variant-numeric: tabular-nums; font-weight: 700;
  display: inline-block; min-width: 2.2em;
}

/* Tegel: boek */
.covers {
  display: flex; align-items: flex-end; gap: 0;
  padding: 0 12px 12px 0;
}
.cover { position: relative; }
.cover img { width: 100%; height: auto; border: var(--rule) solid var(--ink); background: var(--paper); }
.cover-2e { width: 62%; z-index: 2; box-shadow: 12px 12px 0 var(--roze); }
.cover-1e { width: 42%; margin-left: -9%; z-index: 1; box-shadow: 9px 9px 0 var(--geel); }
.vlak-roze .cover-2e { box-shadow: 12px 12px 0 var(--paper); }
.vlak-roze .btn-roze { background: var(--paper); }
.vlak-roze .btn-roze:hover { background: var(--ink); }
.cover-1e figcaption {
  position: absolute; left: 10%; top: calc(100% + 14px);
  font-size: .78rem; line-height: 1.3; color: var(--grijs); white-space: nowrap;
}

.boek-meta { display: grid; gap: .55rem; }
.boek-druk { font-size: 1.5rem; font-weight: 800; letter-spacing: -0.02em; line-height: 1.15; }
.boek-pitch { font-size: .9375rem; max-width: 40ch; }
.boek-specs { font-size: .9375rem; font-weight: 600; }
.actions { display: flex; flex-wrap: wrap; gap: .6rem; margin-top: .25rem; }

/* Tegel: nieuw */
.mini-list { list-style: none; display: grid; gap: .1rem; }
.mini-list a {
  display: flex; gap: .4rem; padding: .28rem 0;
  text-decoration: none; font-size: .9375rem; line-height: 1.35;
  border-bottom: 1px solid rgba(0,0,0,.18);
}
.mini-list a:hover { text-decoration: underline; text-underline-offset: 3px; }
.tile-note { font-size: .875rem; color: var(--grijs); margin-top: auto; }
.tile.roze:hover .tile-note, .tile.geel:hover .tile-note { color: var(--ink); }

/* Tegel: inhoud */
.chapters-mini { list-style: none; display: grid; gap: 0; counter-reset: none; }
.chapters-mini a {
  display: flex; gap: .4rem; padding: .22rem 0;
  text-decoration: none; font-size: .9375rem; line-height: 1.35;
}
.chapters-mini .num { min-width: 1.5em; }
.chapters-mini a:hover { text-decoration: underline; text-underline-offset: 3px; }

/* Tegel: apps */
.apps-body { display: grid; grid-template-columns: 1fr; gap: .9rem; align-items: start; min-height: 0; }
.films { display: flex; gap: .7rem; align-items: flex-end; }
.film-thumb {
  position: relative; display: block; text-decoration: none; color: var(--paper);
  border: var(--rule) solid var(--ink); background: var(--ink);
}
.film-thumb img { width: 100%; height: auto; opacity: .92; }
.film-thumb .play {
  position: absolute; left: 8px; bottom: 8px;
  display: inline-flex; align-items: center; gap: .4rem;
  background: var(--geel); color: var(--ink);
  font-size: .78rem; font-weight: 700; padding: .25rem .5rem .25rem .4rem;
  border: var(--rule) solid var(--ink);
}
.play-icon { width: 0; height: 0; border-left: 9px solid currentColor; border-top: 6px solid transparent; border-bottom: 6px solid transparent; }
.film-laia { width: 250px; }
.film-octovoc { width: 112px; }
.film-thumb:hover img { opacity: 1; }
.film-thumb:hover .play { background: var(--paper); }

.apps-mini { list-style: none; display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 0 1.1rem; }
.apps-mini a {
  display: block; padding: .3rem 0; text-decoration: none;
  font-size: .9375rem; line-height: 1.35;
  border-bottom: 1px solid rgba(0,0,0,.18);
}
.apps-mini b { font-weight: 800; display: block; }
.apps-mini span { color: var(--grijs); }
.tile.geel:hover .apps-mini span { color: var(--ink); }
.apps-mini a:hover b { text-decoration: underline; text-underline-offset: 3px; }

/* Tegel: aanbod */
.themes-mini { list-style: none; display: grid; gap: .15rem; }
.themes-mini a {
  display: block; text-decoration: none; padding: .25rem 0;
  font-weight: 700; font-size: 1rem; line-height: 1.3;
}
.themes-mini a small { display: block; font-weight: 400; font-size: .8125rem; }
.themes-mini a:hover { text-decoration: underline; text-underline-offset: 3px; }
.formats-mini { font-size: .875rem; line-height: 1.4; }
.infosessie-mini {
  margin-top: auto;
  border: var(--rule) solid var(--ink); background: var(--paper);
  padding: .7rem .8rem; display: grid; gap: .5rem;
  font-size: .875rem; line-height: 1.35;
}
.infosessie-mini .btn { justify-self: start; min-height: 38px; padding: .45rem .9rem; font-size: .875rem; }

/* Tegel: Jelle */
.jelle-photo { width: 100%; max-width: 220px; aspect-ratio: 3 / 4; object-fit: cover; border: var(--rule) solid var(--ink); }
.tile.zw:hover .jelle-photo { border-color: var(--paper); }
.jelle-role { font-size: .9375rem; line-height: 1.35; }

/* ── Voettekst ── */
.foot {
  border-top: var(--rule) solid var(--ink);
  min-height: var(--footer-h);
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
  gap: .4rem 1.5rem;
  padding: .7rem clamp(1rem, 2.2vw, 2rem);
  font-size: .8125rem;
}
.foot nav { display: flex; flex-wrap: wrap; gap: .3rem 1.1rem; }
.foot a { text-decoration: none; font-weight: 600; }
.foot a:hover { text-decoration: underline; text-underline-offset: 3px; }

/* ── Panelen (zonder JS: gewone secties onder het overzicht) ── */
.panel { border-top: var(--rule) solid var(--ink); background: var(--paper); }
.panel-head {
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  padding: 1.1rem clamp(1.1rem, 2.5vw, 2rem);
  border-bottom: var(--rule) solid var(--ink);
}
.panel.roze .panel-head { background: var(--roze); }
.panel.geel .panel-head { background: var(--geel); }
.panel.zw .panel-head { background: var(--ink); color: var(--paper); }
.panel-head h2 { font-size: clamp(1.6rem, 2.6vw, 2.15rem); font-weight: 800; letter-spacing: -0.03em; line-height: 1.1; }
.panel-head h2:focus { outline: none; }
.panel-close {
  display: none; align-items: center; gap: .55rem;
  min-height: 44px; padding: .5rem .9rem;
  background: transparent; border: var(--rule) solid currentColor; cursor: pointer;
  font-weight: 700; font-size: .9375rem;
}
.panel-close:hover { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.panel.zw .panel-close:hover { background: var(--paper); color: var(--ink); border-color: var(--paper); }
.x { font-size: 1.35rem; line-height: 1; font-weight: 400; }

.panel-body { padding: clamp(1.25rem, 3vw, 2.25rem) clamp(1.1rem, 2.5vw, 2rem) 4rem; }
.panel-body > * + * { margin-top: 1.5rem; }
.panel-body h3 { font-size: 1.5rem; font-weight: 800; letter-spacing: -0.02em; line-height: 1.2; }
.panel-body h4 { font-size: 1.125rem; font-weight: 800; line-height: 1.25; }
.panel-body p, .panel-body li { max-width: 68ch; }
.lead { font-size: 1.125rem; line-height: 1.55; }
.muted { color: var(--grijs); }
.small { font-size: .875rem; }
.panel-body a:not(.btn) { text-underline-offset: 3px; }
.panel-body ul.plain { list-style: none; }
.inline-actions { display: flex; flex-wrap: wrap; gap: .6rem; }

.boxed { border: var(--rule) solid var(--ink); padding: 1rem 1.15rem; }
.boxed.fill-roze { background: var(--roze); }
.boxed.fill-geel { background: var(--geel); }
.boxed > * + * { margin-top: .5rem; }

/* Paneel: boek */
.boek-panel { display: grid; grid-template-columns: minmax(220px, 340px) 1fr; gap: clamp(1.5rem, 3vw, 2.75rem); align-items: start; }
.boek-panel .covers { padding: 0 14px 40px 0; }
.boek-panel .cover-2e { width: 72%; }
.boek-panel .cover-1e { width: 46%; margin-left: -6%; }
.boek-text > * + * { margin-top: 1rem; }
.flap-quote { font-size: 1.25rem; font-weight: 800; letter-spacing: -0.015em; line-height: 1.3; max-width: 34ch; }
.specs { display: grid; grid-template-columns: max-content 1fr; gap: .35rem 1.25rem; font-size: .9375rem; }
.specs dt { font-weight: 700; }

/* Paneel: nieuw */
.nieuw-list { list-style: none; display: grid; gap: 0; border-top: var(--rule) solid var(--ink); }
.nieuw-list li { max-width: none; border-bottom: var(--rule) solid var(--ink); }
.nieuw-list a {
  display: grid; grid-template-columns: 4.2rem 1fr auto; gap: 1rem; align-items: baseline;
  padding: .9rem .25rem; text-decoration: none;
}
.nieuw-list a:hover { background: var(--roze); }
.nieuw-list .n { font-weight: 800; font-variant-numeric: tabular-nums; }
.nieuw-list strong { display: block; font-size: 1.0625rem; }
.nieuw-list .d { display: block; font-size: .9375rem; color: var(--grijs); margin-top: .15rem; max-width: 62ch; }
.nieuw-list .p { font-size: .875rem; font-weight: 600; white-space: nowrap; }

/* Paneel: inhoud */
.chapter-nav {
  position: sticky; top: 0; z-index: 3;
  display: flex; flex-wrap: wrap; gap: .4rem;
  background: var(--paper); padding: .75rem 0; margin-top: 0;
  border-bottom: var(--rule) solid var(--ink);
}
.chapter-nav a {
  min-width: 44px; min-height: 40px; display: inline-flex; align-items: center; justify-content: center;
  border: var(--rule) solid var(--ink); text-decoration: none; font-weight: 800;
  font-variant-numeric: tabular-nums; padding: 0 .6rem;
}
.chapter-nav a:hover, .chapter-nav a[aria-current="true"] { background: var(--roze); }

#inhoud .panel-body { padding-top: 0; }
#inhoud .panel-body > .lead { padding-top: clamp(1.25rem, 3vw, 2.25rem); }
.chapter { scroll-margin-top: var(--chapnav-h, 4.5rem); padding-top: 1.25rem; }
.chapter + .chapter { margin-top: 3rem; }
.chapter-head { display: grid; grid-template-columns: auto 1fr; gap: .25rem 1.25rem; align-items: end; margin-bottom: 1rem; }
.chapter-num {
  font-size: 4.5rem; font-weight: 900; line-height: .8; letter-spacing: -0.06em;
  color: var(--roze); -webkit-text-stroke: 2px var(--ink);
  grid-row: span 2;
}
.chapter-kicker { font-size: .875rem; color: var(--grijs); }
.chapter-head h3 { font-size: 1.6rem; }
.ch-link { text-decoration: none; }
.ch-link:hover { text-decoration: underline; text-decoration-thickness: 2px; }
.chapter-intro { font-size: 1.0625rem; margin-bottom: 1.1rem; }

.sections { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--rule); background: var(--ink); border: var(--rule) solid var(--ink); }
.sec {
  display: flex; flex-direction: column; gap: .35rem;
  background: var(--paper); padding: 1rem 1.1rem 1.1rem;
  text-decoration: none; color: var(--ink);
}
.sec:hover { background: var(--roze); }
.sec:last-child:nth-child(odd) { grid-column: 1 / -1; }
.sec-top { display: flex; align-items: baseline; gap: .6rem; font-size: .875rem; }
.sec-top .num { min-width: 0; }
.sec-page { margin-left: auto; color: var(--grijs); font-weight: 600; white-space: nowrap; }
.sec:hover .sec-page { color: var(--ink); }
.sec h4 { font-size: 1.0625rem; }
.sec p { font-size: .9375rem; line-height: 1.5; }
.badge {
  display: inline-block; font-size: .75rem; font-weight: 700; line-height: 1;
  padding: .25rem .4rem; border: 1.5px solid var(--ink); background: var(--roze);
}
.sec:hover .badge { background: var(--paper); }
.extras { display: flex; flex-wrap: wrap; gap: .5rem 1.5rem; font-size: .9375rem; }

/* Paneel: apps */
.app { display: grid; grid-template-columns: minmax(200px, 360px) 1fr; gap: clamp(1.25rem, 3vw, 2.25rem); align-items: start; scroll-margin-top: 1rem; }
.app + .app { margin-top: 0; padding-top: 2.25rem; margin-top: 2.25rem; border-top: var(--rule) solid var(--ink); }
.app-media video, .app-media .app-logo { width: 100%; border: var(--rule) solid var(--ink); background: var(--ink); }
.app-media.portrait { max-width: 270px; }
.app-media figcaption { font-size: .8125rem; color: var(--grijs); margin-top: .4rem; }
.app-logo {
  aspect-ratio: 16 / 9; display: flex; align-items: center; justify-content: center;
  color: var(--paper); font-family: Georgia, 'Times New Roman', serif; font-size: 2.1rem; letter-spacing: .02em;
}
.app-logo.caps { text-transform: uppercase; letter-spacing: .12em; font-size: 1.7rem; }
.app-text > * + * { margin-top: .8rem; }
.app-text h3 { font-size: 1.75rem; }
.tagline { font-size: 1.125rem; font-weight: 700; line-height: 1.35; }
.app-facts { list-style: none; display: grid; gap: .3rem; }
.app-facts li { padding-left: 1.2rem; position: relative; }
.app-facts li::before { content: ''; position: absolute; left: 0; top: .6em; width: 8px; height: 8px; background: var(--geel); border: 1.5px solid var(--ink); }
.code { font-weight: 800; letter-spacing: .06em; background: var(--paper); padding: 0 .3rem; border: 1.5px solid var(--ink); }

/* Paneel: aanbod */
.aanbod-intro { display: grid; grid-template-columns: 1fr auto; gap: 2rem; align-items: end; }
.figure-teach { width: 170px; height: auto; margin-bottom: -2.3rem; pointer-events: none; transform: scaleX(-1); }
.themes { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--rule); background: var(--ink); border: var(--rule) solid var(--ink); }
.theme { background: var(--paper); padding: 1.2rem 1.25rem 1.35rem; scroll-margin-top: 1rem; }
.theme > * + * { margin-top: .65rem; }
.theme h3 { font-size: 1.35rem; }
.theme .sub { font-weight: 700; font-size: .9375rem; line-height: 1.35; }
.tam { display: grid; gap: .55rem; }
.tam div { display: grid; grid-template-columns: 2.1rem 1fr; gap: .6rem; align-items: start; }
.tam dt {
  width: 2.1rem; height: 2.1rem; display: flex; align-items: center; justify-content: center;
  background: var(--geel); border: var(--rule) solid var(--ink); font-weight: 900; font-size: 1.1rem;
}
.tam dd { font-size: .9375rem; line-height: 1.45; }
.tam dd b { display: block; }
.book-ref { font-size: .875rem; color: var(--grijs); }

.formats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; }
.format { border-top: 6px solid var(--geel); padding-top: .7rem; }
.format h4 { font-size: 1.125rem; }
.format .dur { font-size: 1.6rem; font-weight: 900; letter-spacing: -0.03em; line-height: 1.15; margin: .15rem 0 .3rem; }
.format p { font-size: .9375rem; }

.meta-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem 2rem; }
.meta-grid h4 { margin-bottom: .25rem; }

.infosessies { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; scroll-margin-top: 1rem; }
.infosessies .boxed h4 { font-size: 1.2rem; }

/* Formulier */
.req-form { border: var(--rule) solid var(--ink); padding: clamp(1rem, 2.5vw, 1.75rem); scroll-margin-top: 1rem; }
.req-form > * + * { margin-top: 1.1rem; }
.req-form h3 { font-size: 1.6rem; }
.req-form fieldset { border: 0; display: grid; gap: .5rem; }
.req-form [hidden] { display: none !important; }
.req-form legend { font-weight: 800; margin-bottom: .5rem; font-size: 1rem; }
.choices { display: flex; flex-wrap: wrap; gap: .5rem; }
.choice { position: relative; }
.choice input { position: absolute; opacity: 0; inset: 0; cursor: pointer; }
.choice span {
  display: inline-flex; align-items: center; min-height: 42px; padding: .45rem .85rem;
  border: var(--rule) solid var(--ink); font-weight: 600; font-size: .9375rem; background: var(--paper);
}
.choice input:checked + span { background: var(--geel); box-shadow: inset 0 0 0 1px var(--ink); font-weight: 800; }
.choice input:focus-visible + span { outline: 3px solid var(--ink); outline-offset: 2px; }
.choice:hover span { background: #fffbb3; }
.fields { display: grid; grid-template-columns: 1fr 1fr; gap: .9rem 1.1rem; }
.field { display: grid; gap: .3rem; }
.field.full { grid-column: 1 / -1; }
.field label { font-weight: 700; font-size: .9375rem; }
.field input, .field textarea {
  width: 100%; min-height: 44px; padding: .55rem .7rem;
  border: var(--rule) solid var(--ink); background: var(--paper); border-radius: 0;
}
.field textarea { min-height: 110px; resize: vertical; }
.field input:focus, .field textarea:focus { outline: 3px solid var(--geel); outline-offset: 0; box-shadow: 0 0 0 5px var(--ink); }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-status { font-weight: 700; padding: .8rem 1rem; border: var(--rule) solid var(--ink); }
.form-status[hidden] { display: none; }
.form-status.ok { background: var(--geel); }
.form-status.err { background: var(--paper); border-style: dashed; }
.form-foot { display: flex; flex-wrap: wrap; gap: 1rem; align-items: center; }
.form-foot p { font-size: .8125rem; color: var(--grijs); max-width: 60ch; }

/* Paneel: Jelle */
.jelle-panel { display: grid; grid-template-columns: minmax(180px, 280px) 1fr; gap: clamp(1.25rem, 3vw, 2.5rem); align-items: start; }
.jelle-panel img { width: 100%; border: var(--rule) solid var(--ink); }
.jelle-panel .txt > * + * { margin-top: 1rem; }
.link-list { list-style: none; display: grid; gap: .35rem; }
.link-list a { font-weight: 700; }

/* ── Met JS: panelen als schuifpaneel boven het overzicht ── */
.js .panel {
  position: fixed; top: var(--header-h); right: 0; bottom: 0;
  width: min(1040px, calc(100vw - 9rem));
  border-top: 0; border-left: var(--rule) solid var(--ink);
  display: flex; flex-direction: column;
  z-index: 50;
  transform: translateX(102%);
  visibility: hidden;
  transition: transform .32s var(--ease), visibility 0s linear .32s;
}
.js .panel.is-open {
  transform: none; visibility: visible;
  transition: transform .32s var(--ease), visibility 0s;
}
.js .panel-head { flex-shrink: 0; }
.js .panel-close { display: inline-flex; }
.js .panel-body { flex: 1; overflow-y: auto; overscroll-behavior: contain; }

.backdrop {
  position: fixed; inset: var(--header-h) 0 0 0; z-index: 40;
  background: rgba(0, 0, 0, .32);
  opacity: 0; visibility: hidden;
  transition: opacity .25s, visibility 0s linear .25s;
}
.backdrop.is-open { opacity: 1; visibility: visible; transition: opacity .25s, visibility 0s; }

.toast {
  position: fixed; left: 50%; bottom: 1.25rem; transform: translateX(-50%);
  z-index: 200; max-width: min(92vw, 560px);
  background: var(--ink); color: var(--paper);
  padding: .8rem 1.1rem; font-size: .9375rem; font-weight: 600;
  border: var(--rule) solid var(--paper); box-shadow: 0 0 0 var(--rule) var(--ink);
}
.toast[hidden] { display: none; }

/* ── Desktop: alles op één scherm ── */
@media (min-width: 1100px) and (min-height: 540px) {
  .board {
    height: calc(100vh - var(--header-h) - var(--footer-h));
    height: calc(100svh - var(--header-h) - var(--footer-h));
    grid-template-columns: 1.32fr 1fr 1.08fr .74fr;
    grid-template-rows: minmax(0, 1fr) minmax(0, 1fr);
    grid-template-areas:
      "boek nieuw apps apps"
      "boek inhoud aanbod jelle";
  }
  .t-boek { grid-area: boek; container-type: size; }
  .t-nieuw { grid-area: nieuw; }
  .t-inhoud { grid-area: inhoud; }
  .t-apps { grid-area: apps; container-type: size; }
  .t-aanbod { grid-area: aanbod; }
  .t-jelle { grid-area: jelle; container-type: size; }
  /* Vangnet: past iets toch niet, dan scrolt de tegel in plaats van inhoud weg te knippen */
  .tile { overflow: auto; scrollbar-width: thin; }

  /* Covers schalen mee met de tegel (hoogte én breedte) */
  .t-boek .covers { flex: 0 0 auto; margin-block: auto; padding-bottom: 46px; align-items: flex-end; }
  .t-boek .cover-2e { width: min(66cqw, calc((100cqh - 21rem) * .709)); }
  .t-boek .cover-1e { width: min(44cqw, calc((100cqh - 21rem) * .48)); margin-left: -12%; }

  .t-apps .film-laia { width: min(300px, 44cqw, calc((100cqh - 13rem) * 1.777)); }
  .t-apps .film-octovoc { width: min(136px, 20cqw, calc((100cqh - 13rem) * .8)); }
  .t-aanbod { gap: .7rem; }

  .t-jelle .jelle-photo { width: auto; height: min(62cqh, 100cqw * 1.2); max-width: 100%; }

  .t-nieuw .mini-list a, .t-inhoud .chapters-mini a { padding-block: clamp(.12rem, .5vh, .3rem); }
  .foot { height: var(--footer-h); min-height: 0; padding-block: 0; overflow: hidden; }
}

/* Smallere desktops (1100 tot 1280 breed) */
@media (min-width: 1100px) and (max-width: 1279.98px) and (min-height: 540px) {
  .board { grid-template-columns: 1.12fr 1fr 1.1fr .66fr; }
  .mini-list a, .chapters-mini a, .apps-mini a { font-size: .875rem; }
  .tile-title { font-size: 1.1rem; }
  .tile-note { display: none; }
  .top-nav a { padding-inline: .5rem; font-size: .875rem; }
}

/* Lagere desktopschermen (de meeste laptops: 610 tot 860 px hoog) */
@media (min-width: 1100px) and (min-height: 540px) and (max-height: 960px) {
  :root { --header-h: 74px; --footer-h: 44px; }
  .tile { padding: 1rem 1.2rem 1.1rem; gap: .6rem; }
  .wm-hand { font-size: 2.25rem; }
  .boek-druk { font-size: 1.3rem; }
  .boek-pitch, .t-boek .boek-specs { font-size: .875rem; }
  .mini-list a, .chapters-mini a, .apps-mini a { font-size: .875rem; }
  .t-nieuw .mini-list a { padding-block: .16rem; }
  .t-inhoud .chapters-mini a { padding-block: .06rem; }
  .apps-mini a { padding-block: .2rem; }
  .themes-mini a { font-size: .9375rem; padding-block: .1rem; }
  .t-jelle .jelle-photo { height: min(56cqh, 100cqw * 1.2); }
  .t-boek .cover-2e { width: min(66cqw, calc((100cqh - 17rem) * .709)); }
  .t-boek .cover-1e { width: min(44cqw, calc((100cqh - 17rem) * .48)); }
}

/* Laptops tot 860 px hoog: minder bijtekst in de tegels */
@media (min-width: 1100px) and (min-height: 540px) and (max-height: 860px) {
  .apps-mini span { display: none; }
  .t-apps .film-laia { width: min(260px, 44cqw, calc((100cqh - 8.5rem) * 1.777)); }
  .t-apps .film-octovoc { width: min(120px, 20cqw, calc((100cqh - 8.5rem) * .8)); }
  .tile-note { display: none; }
  .formats-mini { display: none; }
}

/* Heel lage schermen (bv. laptop met zoom op 150%) */
@media (min-width: 1100px) and (min-height: 540px) and (max-height: 700px) {
  :root { --header-h: 64px; --footer-h: 38px; }
  .top { gap: 1.25rem; }
  .wm-hand { font-size: 1.9rem; }
  .wm-ai { font-size: .95rem; }
  .wm-author { font-size: .6rem; }
  .top-nav a { font-size: .875rem; padding: .4rem .55rem; }
  .top .btn, .actions .btn { min-height: 38px; padding: .4rem .8rem; font-size: .875rem; }
  .tile { padding: .75rem 1rem .85rem; gap: .45rem; }
  .tile-title { font-size: 1.05rem; }
  .sq { width: 12px; height: 12px; }
  .boek-pitch { display: none; }
  .boek-druk { font-size: 1.15rem; }
  .boek-meta { gap: .35rem; }
  .mini-list a, .chapters-mini a, .apps-mini a { font-size: .8125rem; }
  .t-nieuw .mini-list a, .t-inhoud .chapters-mini a, .apps-mini a { padding-block: .04rem; }
  .themes-mini a { font-size: .875rem; padding-block: .05rem; }
  .themes-mini small { display: none; }
  .infosessie-mini { padding: .5rem .6rem; gap: .35rem; font-size: .8125rem; }
  .infosessie-mini .btn { min-height: 32px; padding: .3rem .7rem; font-size: .8125rem; }
  .jelle-role { font-size: .8125rem; }
  .t-jelle .jelle-photo { height: min(50cqh, 100cqw * 1.2); }
  .t-apps .film-laia { width: min(240px, 44cqw, calc((100cqh - 6.5rem) * 1.777)); }
  .t-apps .film-octovoc { width: min(110px, 20cqw, calc((100cqh - 6.5rem) * .8)); }
  .foot { padding-block: .35rem; font-size: .75rem; }
  .t-boek .cover-2e { width: min(66cqw, calc((100cqh - 13.5rem) * .709)); }
  .t-boek .cover-1e { width: min(44cqw, calc((100cqh - 13.5rem) * .48)); }
}

/* Extreem lage schermen */
@media (min-width: 1100px) and (min-height: 540px) and (max-height: 620px) {
  .tile { padding-block: .6rem .7rem; gap: .35rem; }
  .infosessie-mini { grid-template-columns: 1fr auto; align-items: center; padding: .4rem .5rem; }
  .infosessie-mini .extra { display: none; }
  .t-jelle .jelle-photo { height: min(46cqh, 100cqw * 1.2); }
}

/* Smalle én lage desktops */
@media (min-width: 1100px) and (max-width: 1279.98px) and (min-height: 540px) and (max-height: 960px) {
  .t-jelle .jelle-photo { height: min(48cqh, 100cqw * 1.2); }
}

/* ── Tablet ── */
@media (min-width: 700px) and (max-width: 1099.98px), (min-width: 1100px) and (max-height: 539.98px) {
  .board {
    grid-template-columns: 1fr 1fr;
    grid-template-areas:
      "boek boek"
      "nieuw inhoud"
      "apps apps"
      "aanbod jelle";
  }
  .t-boek { grid-area: boek; display: grid; grid-template-columns: 1fr 1fr; align-items: end; gap: 1.5rem; }
  .t-boek .tile-title { grid-column: 1 / -1; }
  .t-nieuw { grid-area: nieuw; }
  .t-inhoud { grid-area: inhoud; }
  .t-apps { grid-area: apps; }
  .t-aanbod { grid-area: aanbod; }
  .t-jelle { grid-area: jelle; }
  .t-boek .covers { padding-bottom: 46px; }
  .top-nav a { padding: .5rem .45rem; font-size: .875rem; }
}

@media (max-width: 1099.98px) {
  .js .panel { width: min(100vw - 3rem, 900px); }
}

@media (max-width: 860px) {
  .top-nav { display: none; }
  .top { justify-content: space-between; }
}

/* ── Telefoon ── */
@media (max-width: 699.98px) {
  :root { --header-h: 70px; }
  .wm-hand { font-size: 2.05rem; }
  .wm-ai { font-size: .95rem; }
  .wm-author { font-size: .62rem; }
  .top .btn { min-height: 40px; padding: .45rem .7rem; font-size: .8125rem; }
  .board { grid-template-columns: 1fr; }
  .t-boek .covers { padding-bottom: 46px; max-width: 420px; }
  .apps-body { grid-template-columns: 1fr; }
  .film-laia { width: 64%; }
  .film-octovoc { width: 29%; }
  .jelle-photo { max-width: 180px; }

  .js .panel { top: 0; width: 100vw; border-left: 0; z-index: 70; }
  .backdrop { display: none; }
  .panel-head { position: sticky; top: 0; }
  .boek-panel, .app, .jelle-panel, .aanbod-intro { grid-template-columns: 1fr; }
  .boek-panel .covers { max-width: 380px; }
  .figure-teach { display: none; }
  .sections, .themes, .formats, .meta-grid, .infosessies, .fields { grid-template-columns: 1fr; }
  .nieuw-list a { grid-template-columns: 3.2rem 1fr; }
  .nieuw-list .p { grid-column: 2; }
  .specs { grid-template-columns: 1fr; gap: 0; }
  .specs dd { margin-bottom: .45rem; }
  .chapter-num { font-size: 3.4rem; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: 0s !important; animation-duration: 0s !important; scroll-behavior: auto !important; }
}

/* Alleen in de preview */
.preview-bar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 300;
  background: var(--ink); color: var(--paper); text-align: center;
  font-size: .8125rem; padding: .35rem 1rem; font-weight: 600;
}
