:root {
  --bg: #F7F6F3; --bg2: #EEECEA; --bg3: #E4E2DE;
  --ink: #1A1917; --ink2: #6B6860; --ink3: #9C9A94;
  --accent: #E0522B; --accent-soft: #FBEBE4;
  --blue: #2D5BE3; --blue-soft: #EEF2FD;
  --green: #1E8F62; --green-soft: #E8F5EF;
  --white: #FFFFFF;
  --radius: 16px; --radius-sm: 10px;
  --sans: 'DM Sans', system-ui, sans-serif;
  --serif: 'DM Serif Display', Georgia, serif;
  --max: 1160px;
  --transition: .22s cubic-bezier(.4, 0, .2, 1);
}
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body { font-family: var(--sans); background: var(--bg); color: var(--ink); font-size: 16px; line-height: 1.6; -webkit-font-smoothing: antialiased; }
a { color: inherit; }
img, svg { max-width: 100%; }
.container { max-width: var(--max); margin: 0 auto; padding: 0 2rem; }

/* NAV */
.site-nav { position: sticky; top: 0; z-index: 100; background: rgba(247,246,243,.88); backdrop-filter: blur(16px); border-bottom: 1px solid var(--bg3); }
.nav-inner { max-width: var(--max); margin: 0 auto; padding: 0 2rem; height: 64px; display: flex; align-items: center; justify-content: space-between; }
.logo { white-space: nowrap; font-family: var(--serif); font-size: 23px; text-decoration: none; letter-spacing: -.3px; line-height: 1; }
.logo em { color: var(--accent); font-style: italic; }
.nav-right { display: flex; align-items: center; gap: 2rem; }
.nav-right a:not(.btn-primary) { font-size: 14px; color: var(--ink2); text-decoration: none; transition: color var(--transition); }
.nav-right a:not(.btn-primary):hover, .nav-right a.active { color: var(--ink); }
.btn-primary, .btn-secondary, .btn-ghost {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; font: 500 15px var(--sans); text-decoration: none;
  border-radius: 50px; cursor: pointer; transition: all var(--transition); border: 1px solid transparent; padding: 13px 26px;
}
.btn-primary { background: var(--ink); color: #fff; }
.btn-primary:hover { background: var(--accent); transform: translateY(-1px); }
.btn-secondary { background: none; color: var(--ink2); border-color: var(--bg3); }
.btn-secondary:hover { border-color: var(--ink3); color: var(--ink); }
.btn-ghost { background: var(--white); color: var(--ink); border-color: var(--bg3); padding: 11px 20px; font-size: 14px; }
.btn-ghost:hover { border-color: var(--ink3); }
.nav-right .btn-primary { white-space: nowrap; padding: 9px 20px; font-size: 14px; color: #fff; }

/* HERO */
.hero { padding: 96px 0 84px; overflow: hidden; }
.hero-grid { display: grid; grid-template-columns: 1.02fr 1fr; gap: 3rem; align-items: center; }
.eyebrow { font-size: 12px; font-weight: 500; letter-spacing: .12em; text-transform: uppercase; color: var(--accent); margin-bottom: 1.4rem; }
.hero h1 { font-family: var(--serif); font-weight: 400; font-size: clamp(42px, 5.4vw, 70px); line-height: 1.04; letter-spacing: -.8px; margin-bottom: 1.5rem; }
.hero h1 em { font-style: italic; color: var(--accent); }
.hero-sub { font-size: 18px; font-weight: 300; color: var(--ink2); line-height: 1.65; margin-bottom: 2.4rem; max-width: 470px; }
.hero-cta { display: flex; flex-wrap: wrap; gap: .75rem; }
.hero-note { margin-top: 1.6rem; font-size: 13.5px; color: var(--ink3); }
.hero-visual { position: relative; aspect-ratio: 1 / 1.02; }
.hs { position: absolute; transform-origin: 50% 50%; border-radius: 3px; box-shadow: 0 2px 4px rgba(0,0,0,.05), 0 24px 60px rgba(20,19,15,.16); width: 793.7px; height: 1122.5px; margin: -561.25px 0 0 -396.85px; }
.hs .sheet { box-shadow: none; }
.hs-1 { left: 31%; top: 49%; transform: rotate(-7deg) scale(calc(var(--k) * .62)); }
.hs-2 { left: 72%; top: 46%; transform: rotate(6deg) scale(calc(var(--k) * .62)); }
.hs-3 { left: 52%; top: 55%; transform: rotate(-1.2deg) scale(calc(var(--k) * .66)); z-index: 2; }

/* SECTIONS */
.section { padding: 96px 0; }
.section.white { background: var(--white); }
.section-label { font-size: 12px; font-weight: 500; letter-spacing: .12em; text-transform: uppercase; color: var(--accent); margin-bottom: 1rem; }
.section-title { font-family: var(--serif); font-weight: 400; font-size: clamp(32px, 4vw, 48px); line-height: 1.1; letter-spacing: -.4px; margin-bottom: 1rem; }
.section-sub { font-size: 17px; font-weight: 300; color: var(--ink2); max-width: 540px; line-height: 1.65; }
.section-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 2rem; margin-bottom: 3rem; flex-wrap: wrap; }
.link-arrow { font-size: 15px; font-weight: 500; text-decoration: none; white-space: nowrap; }
.link-arrow:hover { color: var(--accent); }

/* VAKKEN */
.vakken { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; margin-top: 3.5rem; }
.vak-card { background: var(--white); border: 1px solid var(--bg3); border-radius: 20px; padding: 2.2rem; text-decoration: none; transition: all var(--transition); display: flex; flex-direction: column; gap: 1.2rem; }
.section.white .vak-card { background: var(--bg); }
.vak-card:hover { border-color: var(--ink3); transform: translateY(-2px); }
.vak-card h3 { font-family: var(--serif); font-weight: 400; font-size: 32px; letter-spacing: -.3px; line-height: 1.1; }
.vak-card p { color: var(--ink2); font-weight: 300; }
.vak-ico { width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; font-family: var(--serif); font-size: 22px; }
.vak-rekenen .vak-ico { background: var(--blue-soft); color: var(--blue); }
.vak-taal .vak-ico { background: var(--green-soft); color: var(--green); }
.vak-topo .vak-ico { background: #FBF0DD; color: #B26A00; }
.vak-engels .vak-ico { background: #F3E8FA; color: #7A3FA0; }
.vak-wereld .vak-ico { background: #E4F3F6; color: #0E7490; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { font-size: 13px; padding: 5px 12px; border-radius: 99px; background: var(--bg2); color: var(--ink2); }
.vak-card .more { margin-top: auto; font-weight: 500; font-size: 15px; }
/* voorbeeldvlak op de kaarten van spelletjes, energizers en klassentools */
.mini-emoji { height: 150px; border-radius: 14px; display: grid; place-items: center; font-size: 76px; line-height: 1; background: radial-gradient(120% 90% at 50% 0%, #2c2475, #14112e 70%); }
.vak-card:hover .more { color: var(--accent); }

/* KAARTEN (bibliotheek) */
.cards { --k: .3; display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 1.5rem; }
.card { display: flex; flex-direction: column; text-decoration: none; background: var(--white); border: 1px solid var(--bg3); border-radius: var(--radius); overflow: hidden; transition: all var(--transition); }
.card:hover { border-color: var(--ink3); transform: translateY(-3px); box-shadow: 0 14px 34px rgba(20,19,15,.09); }
.thumb { aspect-ratio: 210 / 190; background: var(--bg2); overflow: hidden; position: relative; border-bottom: 1px solid var(--bg3); }
.thumb-inner { position: absolute; left: 50%; top: 14px; width: 793.7px; height: 1122.5px; margin-left: calc(793.7px * var(--k) / -2); transform: scale(var(--k)); transform-origin: 0 0; opacity: 0; transition: opacity .3s; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,.08); }
.thumb-inner.ready { opacity: 1; }
.card { position: relative; }
.fav { position: absolute; top: 10px; right: 10px; z-index: 3; width: 34px; height: 34px; border-radius: 50%; border: 1px solid var(--bg3); background: rgba(255,255,255,.92); color: var(--ink3); display: grid; place-items: center; cursor: pointer; transition: all var(--transition); }
.fav:hover { color: var(--accent); border-color: var(--accent); }
.fav.on { color: var(--accent); }
.btn-ghost svg { vertical-align: -3px; }
.card-body { padding: 1rem 1.15rem 1.2rem; }
.card-title { font-weight: 500; font-size: 15.5px; line-height: 1.35; margin-bottom: .5rem; }
.card-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-size: 12.5px; color: var(--ink3); }
.card-meta .dot { opacity: .6; }
.tag { padding: 2px 9px; border-radius: 99px; font-weight: 500; font-size: 12px; }
.tag-rekenen { background: var(--blue-soft); color: var(--blue); }
.tag-taal { background: var(--green-soft); color: var(--green); }
.tag-topo { background: #FBF0DD; color: #B26A00; }
.tag-engels { background: #F3E8FA; color: #7A3FA0; }
.tag-wereld { background: #E4F3F6; color: #0E7490; }

/* FAQ */
.faq { max-width: 760px; margin-top: 3rem; }
.faq details { border-bottom: 1px solid var(--bg3); padding: 1.2rem 0; }
.faq summary { font-weight: 500; cursor: pointer; list-style: none; display: flex; justify-content: space-between; gap: 1rem; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: '+'; font-size: 22px; line-height: 1; color: var(--ink3); transition: transform var(--transition); }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq p { margin-top: .8rem; color: var(--ink2); font-weight: 300; max-width: 640px; }

/* FOOTER */
.site-foot { border-top: 1px solid var(--bg3); padding: 48px 0; color: var(--ink3); font-size: 14px; }
.foot-inner { display: flex; justify-content: space-between; align-items: center; gap: 1.5rem; flex-wrap: wrap; }
.foot-links { display: flex; flex-wrap: wrap; gap: .6rem 1.6rem; }
.foot-links a { text-decoration: none; }
.foot-links a:hover { color: var(--ink); }

/* BIBLIOTHEEK-pagina */
.page-head { padding-top: 64px; padding-bottom: 28px; }
.page-head h1 { font-family: var(--serif); font-weight: 400; font-size: clamp(36px, 4.6vw, 56px); line-height: 1.05; letter-spacing: -.5px; margin-bottom: .8rem; }
.page-head p { color: var(--ink2); font-weight: 300; font-size: 17px; max-width: 560px; }
.toolbar { background: var(--bg); border-bottom: 1px solid var(--bg3); padding: 14px 0; }
.toolbar-inner { max-width: var(--max); margin: 0 auto; padding: 0 2rem; display: flex; flex-direction: column; gap: 12px; }
.search { position: relative; }
.search input { width: 100%; font: 400 15px var(--sans); padding: 12px 16px 12px 42px; border-radius: 50px; border: 1px solid var(--bg3); background: var(--white); color: var(--ink); outline: none; transition: border-color var(--transition); }
.search input:focus { border-color: var(--ink3); }
.search svg { position: absolute; left: 15px; top: 50%; transform: translateY(-50%); width: 18px; height: 18px; color: var(--ink3); }
.filter-row { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.filter-row .lbl { font-size: 12px; font-weight: 500; letter-spacing: .1em; text-transform: uppercase; color: var(--ink3); min-width: 60px; }
.pill { font: 500 13.5px var(--sans); padding: 6px 14px; border-radius: 99px; border: 1px solid var(--bg3); background: var(--white); color: var(--ink2); cursor: pointer; transition: all var(--transition); }
.pill:hover { border-color: var(--ink3); color: var(--ink); }
.pill.on { background: var(--ink); border-color: var(--ink); color: #fff; }
.results-bar { display: flex; justify-content: space-between; margin: 28px 0 18px; font-size: 14px; color: var(--ink3); }
.empty { text-align: center; padding: 80px 0; color: var(--ink2); }
.library { padding-bottom: 96px; }

/* GENERATOR-pagina */
.gen-layout { display: grid; grid-template-columns: 340px 1fr; min-height: calc(100vh - 64px); }
.panel { background: var(--white); border-right: 1px solid var(--bg3); padding: 28px 24px 40px; position: sticky; top: 64px; height: calc(100vh - 64px); overflow-y: auto; }
.panel h1 { font-family: var(--serif); font-weight: 400; font-size: 26px; line-height: 1.1; margin-bottom: .4rem; }
.panel .desc { font-size: 14px; color: var(--ink2); margin-bottom: 1.4rem; font-weight: 300; }
.field { margin-bottom: 1.1rem; }
.field > label, .field > .lab { display: block; font-size: 12px; font-weight: 500; letter-spacing: .06em; text-transform: uppercase; color: var(--ink3); margin-bottom: 6px; }
.field select, .field textarea { width: 100%; font: 400 15px var(--sans); color: var(--ink); background: var(--bg); border: 1px solid var(--bg3); border-radius: var(--radius-sm); padding: 10px 12px; outline: none; }
.field select:focus, .field textarea:focus { border-color: var(--ink3); }
.field textarea { resize: vertical; min-height: 84px; }
.chipset { display: flex; flex-wrap: wrap; gap: 6px; }
.chipset button { font: 500 14px var(--sans); width: 38px; height: 36px; border-radius: 9px; border: 1px solid var(--bg3); background: var(--bg); color: var(--ink2); cursor: pointer; transition: all var(--transition); }
.chipset button:disabled { opacity: .35; cursor: not-allowed; }
.chipset button.on { background: var(--ink); color: #fff; border-color: var(--ink); }
.divider { height: 1px; background: var(--bg3); margin: 1.4rem 0; }
.actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-bottom: 1rem; }
.actions .btn-primary, .actions .btn-ghost { padding: 12px 10px; font-size: 14.5px; }
.toggle { display: flex; align-items: flex-start; gap: 10px; font-size: 14px; color: var(--ink2); margin-bottom: .7rem; cursor: pointer; }
.toggle input { margin-top: 4px; accent-color: var(--accent); }
.hint { font-size: 12.5px; color: var(--ink3); margin-top: 1rem; line-height: 1.5; }
.stage { padding: 32px 24px 64px; display: flex; flex-direction: column; align-items: center; gap: 32px; background: var(--bg2); overflow-x: hidden; }
.sheet-scale { position: relative; flex: none; }
.sheet-scale .sheet { position: absolute; left: 0; top: 0; transform-origin: 0 0; box-shadow: 0 1px 3px rgba(0,0,0,.08), 0 20px 50px rgba(20,19,15,.12); border-radius: 2px; }
/* vast rechtsonder in beeld, over het voorbeeldblad heen */
.sheet-show { position: fixed; right: 28px; bottom: 28px; z-index: 50; font: 500 15px var(--sans); color: #fff; background: var(--ink); border: 0; border-radius: 99px; padding: 12px 20px; cursor: pointer; box-shadow: 0 4px 14px rgba(20,19,15,.25); transition: background var(--transition), transform var(--transition); }
.sheet-show:hover { background: var(--accent); transform: translateY(-1px); }
.stage-label { font-size: 12px; letter-spacing: .1em; text-transform: uppercase; color: var(--ink3); margin-bottom: -18px; align-self: center; }
.toast { position: fixed; bottom: 24px; left: 50%; transform: translate(-50%, 20px); background: var(--ink); color: #fff; padding: 10px 18px; border-radius: 99px; font-size: 14px; opacity: 0; pointer-events: none; transition: all .25s; z-index: 200; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }
/* volledig scherm (digibord) */
.present { position: fixed; inset: 0; z-index: 300; background: #2a2926; display: flex; flex-direction: column; }
.present[hidden] { display: none; }
.present-stage { flex: 1; min-height: 0; overflow: auto; display: flex; justify-content: center; align-items: flex-start; padding: 24px 24px 80px; }
.present-stage .sheet-scale { position: relative; flex: none; margin: auto; }
.present-stage .sheet { position: absolute; left: 0; top: 0; transform-origin: 0 0; box-shadow: 0 10px 40px rgba(0,0,0,.4); }
.present-bar { position: absolute; left: 50%; bottom: 16px; transform: translateX(-50%); display: flex; align-items: center; gap: 6px; padding: 6px; border-radius: 99px; background: rgba(26,25,23,.82); backdrop-filter: blur(8px); opacity: .35; transition: opacity var(--transition); white-space: nowrap; }
.present-bar:hover, .present-bar:focus-within { opacity: 1; }
.present-bar button { font: 500 14px var(--sans); color: #fff; background: rgba(255,255,255,.1); border: 0; border-radius: 99px; padding: 8px 14px; cursor: pointer; }
.present-bar button:hover { background: rgba(255,255,255,.22); }
.present-bar button[aria-pressed="true"] { background: var(--accent); }
.present-pages { display: flex; align-items: center; gap: 4px; color: #fff; font-size: 14px; }
.present-pages[hidden] { display: none; }
.present-pages span { min-width: 4.5em; text-align: center; }
.present-pages button { padding: 8px 12px; font-size: 18px; line-height: 1; }

@media (max-width: 960px) {
  .hero { padding: 56px 0; }
  .hero-grid { grid-template-columns: 1fr; }
  .hero-visual { max-width: 560px; margin: 0 auto; width: 100%; }
  .vakken { grid-template-columns: 1fr; }
  .gen-layout { grid-template-columns: 1fr; }
  .panel { position: static; height: auto; border-right: none; border-bottom: 1px solid var(--bg3); }
}
@media (max-width: 640px) {
  .container, .nav-inner, .toolbar-inner { padding: 0 1.25rem; }
  .nav-right { gap: 1.1rem; }
  /* smal scherm: logo en knop op de eerste regel, de links eronder */
  .nav-inner { height: auto; flex-wrap: wrap; justify-content: flex-start; gap: 8px 1.1rem; padding-top: 10px; padding-bottom: 10px; }
  .nav-inner::after { content: ""; flex-basis: 100%; order: 2; }
  .nav-right { display: contents; }
  .nav-right a { order: 3; white-space: nowrap; }
  .nav-right a[href="generator.html"] { order: 1; margin-left: auto; }
  .nav-right .active:not(.btn-primary) { font-weight: 500; }
  .nav-right .hide-sm { display: none; }
  .nav-right a:not(.btn-primary) { font-size: 13px; }
  .nav-inner { column-gap: .85rem; }
  .section { padding: 64px 0; }
  .cards { grid-template-columns: repeat(2, 1fr); gap: 1rem; }
  .card-meta .dot, .card-meta span:last-child { display: none; }
  .stage { padding: 20px 8px 48px; }
}

/* toetsenbord */
a:focus-visible, button:focus-visible, select:focus-visible, input:focus-visible, textarea:focus-visible, summary:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } html { scroll-behavior: auto; } }

/* voorpagina: spelletjes, energizers, tools */
.vak-spelletjes .vak-ico { background: #FDE8E8; color: #C81E26; }
.vak-energizers .vak-ico { background: #FFF6D6; color: #9A6B00; }
.vak-tools .vak-ico { background: #E9ECF2; color: #44506A; }
