* {
  box-sizing: border-box;
  -webkit-user-select: none;
  user-select: none;
}

input,
textarea {
  -webkit-user-select: text;
  user-select: text;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Comic Neue", Arial, sans-serif;
  color: #222;
  background:
    radial-gradient(circle at top left, #fff0a8 0, transparent 32%),
    radial-gradient(circle at top right, #b8f7ff 0, transparent 28%),
    linear-gradient(135deg, #fff7d6, #f3e7ff 45%, #dcfff5);
  min-height: 100vh;
  overflow-x: hidden;
}

.blob {
  position: fixed;
  border-radius: 999px;
  filter: blur(2px);
  opacity: 0.45;
  z-index: -1;
  animation: float 7s ease-in-out infinite;
}

.blob-one {
  width: 230px;
  height: 230px;
  background: #ff4fa3;
  top: 120px;
  left: -80px;
}

.blob-two {
  width: 280px;
  height: 280px;
  background: #4dd7ff;
  right: -120px;
  top: 260px;
  animation-delay: 1s;
}

.blob-three {
  width: 210px;
  height: 210px;
  background: #8cff4d;
  bottom: 80px;
  left: 12%;
  animation-delay: 2s;
}

.topbar {
  width: min(1120px, calc(100% - 32px));
  margin: 22px auto 0;
  padding: 14px 18px;
  border: 4px solid #111;
  border-radius: 26px;
  background: rgba(255, 255, 255, 0.82);
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: 8px 8px 0 #111;
  position: relative;
  top: auto;
  z-index: 10;
  backdrop-filter: blur(12px);
}

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
}

.duck-logo {
  width: 54px;
  height: 54px;
  border: 3px solid #111;
  border-radius: 18px;
  background: #7ee8ff;
  position: relative;
  box-shadow: 3px 3px 0 #111;
  transform: rotate(7deg);
  flex: 0 0 auto;
  overflow: hidden;
  display: grid;
  place-items: center;
  transition: transform 0.15s, box-shadow 0.15s;
  cursor: pointer;
}

.duck-logo:hover {
  transform: translate(3px, 3px) rotate(5deg) scale(1.04);
  box-shadow: 1px 1px 0 #111;
}

.duck-logo img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  display: block;
}

.duck-head {
  width: 30px;
  height: 30px;
  border: 3px solid #111;
  border-radius: 50% 50% 45% 45%;
  background: #ffde59;
  position: absolute;
  right: 7px;
  top: 10px;
}

.duck-beak {
  width: 15px;
  height: 11px;
  border: 3px solid #111;
  border-right: 0;
  border-radius: 999px 0 0 999px;
  background: #ff9f1c;
  position: absolute;
  right: 32px;
  top: 24px;
}

.duck-eye {
  width: 6px;
  height: 6px;
  background: #111;
  border-radius: 50%;
  position: absolute;
  right: 25px;
  top: 20px;
}

.logo strong {
  display: block;
  font-size: 22px;
}

.logo span {
  display: block;
  font-size: 13px;
  color: #666;
}

.topbar-right {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.level-toggle {
  display: grid;
  grid-template-columns: 1fr 1fr;
  align-items: center;
  gap: 0;
  padding: 4px;
  border: 3px solid #111;
  border-radius: 999px;
  background: #ffde59;
  box-shadow: 4px 4px 0 #111;
  transform: rotate(-1deg);
  position: relative;
  overflow: hidden;
}

.level-toggle::before {
  content: "";
  position: absolute;
  top: 4px;
  left: 4px;
  width: calc(50% - 4px);
  height: calc(100% - 8px);
  border-radius: 999px;
  background: #111;
  transition: transform 0.28s cubic-bezier(.2, .9, .2, 1);
  z-index: 1;
}

.level-toggle.havo-selected::before {
  transform: translateX(100%);
}

.level-option {
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: #111;
  padding: 8px 12px;
  font-family: inherit;
  font-size: 15px;
  font-weight: 900;
  cursor: pointer;
  transition: transform 0.15s, color 0.2s;
  position: relative;
  z-index: 1;
}

.level-option:hover {
  transform: translateY(-1px) rotate(1deg);
}

.level-option.active {
  color: white;
}

nav {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

nav a {
  text-decoration: none;
  color: #111;
  font-weight: 800;
  padding: 10px 14px;
  border-radius: 999px;
}

nav a:hover {
  background: #111;
  color: white;
}

main {
  width: min(1120px, calc(100% - 32px));
  margin: 46px auto;
}

.hero {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 34px;
  align-items: center;
  min-height: 560px;
}

.tag {
  display: inline-block;
  margin: 0 0 12px;
  padding: 8px 14px;
  background: #11d6a0;
  border: 3px solid #111;
  border-radius: 999px;
  font-weight: 900;
  box-shadow: 4px 4px 0 #111;
}

h1 {
  margin: 0;
  font-size: clamp(37.5px, 5.95vw, 70px);
  line-height: 0.95;
  letter-spacing: -3px;
}

h2 {
  margin: 0 0 14px;
  font-size: clamp(32px, 5vw, 56px);
  line-height: 1;
  letter-spacing: -2px;
}

.intro,
.section p {
  font-size: 22px;
  line-height: 1.45;
}

.hero-buttons {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
  margin-top: 26px;
}

.button,
.question-form button {
  display: inline-block;
  padding: 16px 22px;
  border: 4px solid #111;
  border-radius: 18px;
  color: #111;
  font-weight: 900;
  text-decoration: none;
  box-shadow: 6px 6px 0 #111;
  transition: transform 0.15s, box-shadow 0.15s;
  font-family: inherit;
  font-size: 18px;
  cursor: pointer;
}

.button:hover,
.question-form button:hover {
  transform: translate(4px, 4px);
  box-shadow: 2px 2px 0 #111;
}

.primary {
  background: #ff4fa3;
  color: white;
}

.secondary {
  background: #ffde59;
}

.hero-card {
  height: 480px;
  border: 5px solid #111;
  border-radius: 40px;
  background:
    linear-gradient(90deg, rgba(255,255,255,0.5) 12px, transparent 12px),
    linear-gradient(rgba(255,255,255,0.5) 12px, transparent 12px),
    #7ee8ff;
  background-size: 48px 48px;
  box-shadow: 12px 12px 0 #111;
  position: relative;
  overflow: visible;
}

.frog-stage {
  position: absolute;
  inset: 0;
  overflow: visible;
}

.frog-clip {
  position: absolute;
  inset: 0;
  overflow: hidden;
  border-radius: 34px;
}

.frog-mascot {
  position: absolute;
  left: 50%;
  bottom: -92px;
  height: 450px;
  width: auto;
  transform: translateX(-50%);
  cursor: pointer;
  filter: drop-shadow(0 16px 0 rgba(0, 0, 0, 0.18));
  animation: frogFloat 3s ease-in-out infinite;
  transition: transform 0.18s ease, filter 0.18s ease;
  z-index: 4;
}

.frog-mascot:hover {
  transform: translateX(-50%) translateY(-10px) scale(1.04) rotate(-2deg);
  filter: drop-shadow(0 22px 0 rgba(0, 0, 0, 0.16));
}

.speech-bubble {
  position: absolute;
  top: -40px;
  right: 28px;
  max-width: 285px;
  padding: 18px 20px;
  border: 5px solid #111;
  border-radius: 28px;
  background: #fff5a8;
  box-shadow: 7px 7px 0 #111;
  font-size: 21px;
  line-height: 1.25;
  z-index: 7;
  opacity: 0;
  transform: translateY(10px) scale(0.94) rotate(2deg);
  transition: opacity 0.18s ease, transform 0.18s ease;
  pointer-events: none;
}

.speech-bubble::after {
  content: "";
  position: absolute;
  left: 72px;
  bottom: -24px;
  width: 34px;
  height: 34px;
  background: #fff5a8;
  border-right: 5px solid #111;
  border-bottom: 5px solid #111;
  transform: rotate(45deg);
  z-index: 0;
}

.speech-bubble.show {
  opacity: 1;
  transform: translateY(0) scale(1) rotate(2deg);
}

.floating-card {
  position: absolute;
  border: 4px solid #111;
  border-radius: 18px;
  padding: 13px 18px;
  font-size: 24px;
  font-weight: 900;
  box-shadow: 5px 5px 0 #111;
  animation: bob 3s ease-in-out infinite;
  transition: transform 0.18s ease, box-shadow 0.18s ease;
  z-index: 2;
  cursor: pointer;
}

.floating-card:hover {
  animation-play-state: paused;
  transform: translate(4px, 4px) rotate(2deg) scale(1.04);
  box-shadow: 2px 2px 0 #111;
}

.card-yellow {
  background: #ffde59;
  top: 52px;
  left: 36px;
}

.card-pink {
  background: #ff4fa3;
  color: white;
  top: 128px;
  right: 32px;
  animation-delay: 0.5s;
}

.card-blue {
  background: #8067ff;
  color: white;
  bottom: 50px;
  left: 42px;
  animation-delay: 1s;
}

.section {
  margin-top: 52px;
  padding: 42px;
  border: 5px solid #111;
  border-radius: 36px;
  background: rgba(255, 255, 255, 0.78);
  box-shadow: 10px 10px 0 #111;
}

.section-title p {
  margin: 0 0 24px;
  color: #8067ff;
  font-size: 28px;
  font-weight: 900;
}

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

.tile {
  min-height: 250px;
  padding: 28px;
  border: 4px solid #111;
  border-radius: 30px;
  box-shadow: 7px 7px 0 #111;
  transition: transform 0.15s, box-shadow 0.15s;
  cursor: pointer;
}

.tile:hover {
  transform: translate(5px, 5px) rotate(-1deg);
  box-shadow: 2px 2px 0 #111;
}

.tile-icon {
  width: 104px;
  height: 104px;
  display: grid;
  place-items: center;
  margin-bottom: 10px;
  transition: transform 0.18s ease;
}

.tile-icon img {
  width: 104px;
  height: 104px;
  object-fit: contain;
  pointer-events: none;
  filter: drop-shadow(4px 4px 0 rgba(0,0,0,0.22));
}

.tile:hover .tile-icon {
  transform: translateY(-4px) rotate(3deg) scale(1.07);
}

.tile h3 {
  margin: 14px 0 8px;
  font-size: 30px;
}

.tile p {
  font-size: 18px;
}

.tile a {
  color: #111;
  font-weight: 900;
}


.book-left {
  align-self: start;
  padding: 4px 0 0;
}

.book-main-display .tile-icon {
  margin-bottom: 8px;
}

.book-main-display h3 {
  margin: 14px 0 8px;
  font-size: 38px;
  line-height: 1;
}

.book-main-display p {
  max-width: 480px;
  font-size: 21px;
}

.purple {
  background: #cbb7ff;
}

.green {
  background: #9cffc8;
}

.orange {
  background: #ffb55a;
}

.split {
  display: grid;
  grid-template-columns: 1fr 380px;
  gap: 32px;
  align-items: start;
  background: #fff3aa;
}

.clickable-book-section {
  cursor: pointer;
  transition: transform 0.15s, box-shadow 0.15s;
}

.clickable-book-section:hover {
  transform: translate(5px, 5px) rotate(-1deg);
  box-shadow: 5px 5px 0 #111;
}

.clickable-book-section:hover .book-main-display .tile-icon {
  transform: translateY(-4px) rotate(3deg) scale(1.07);
}

.clickable-book-section:hover .book-main-display h3,
.clickable-book-section:hover .book-main-display p {
  transform: translateY(-3px);
}

.book-main-display h3,
.book-main-display p {
  transition: transform 0.18s ease;
}

.book-stack {
  height: 300px;
  position: relative;
}

.book {
  position: absolute;
  width: 250px;
  height: 72px;
  border: 4px solid #111;
  border-radius: 18px;
  display: grid;
  place-items: center;
  font-size: 25px;
  font-weight: 900;
  box-shadow: 5px 5px 0 #111;
  transition: transform 0.15s, box-shadow 0.15s;
  cursor: pointer;
}

.book:hover {
  box-shadow: 2px 2px 0 #111;
}

.book.one {
  background: #ff4fa3;
  color: white;
  top: 0;
  right: 95px;
  transform: rotate(5deg);
}

.book.one:hover {
  transform: translate(4px, 4px) rotate(3deg);
}

.book.two {
  background: #7ee8ff;
  top: 76px;
  right: 18px;
  transform: rotate(-6deg);
}

.book.two:hover {
  transform: translate(4px, 4px) rotate(-2deg);
}

.book.three {
  background: #11d6a0;
  top: 152px;
  right: 100px;
  transform: rotate(5deg);
}

.book.three:hover {
  transform: translate(4px, 4px) rotate(2deg);
}

.book.four {
  background: #ffde59;
  top: 228px;
  right: 34px;
  transform: rotate(-7deg);
}

.book.four:hover {
  transform: translate(4px, 4px) rotate(-3deg);
}

.question-box {
  background: #cbb7ff;
}

.question-heading {
  display: flex;
  align-items: baseline;
  gap: 18px;
  flex-wrap: wrap;
  margin-bottom: 18px;
}

.question-heading h2 {
  margin: 0;
}

.question-heading p {
  margin: 0;
  font-size: 24px;
  font-weight: 900;
}

.login-note {
  font-size: 18px !important;
  line-height: 1.2 !important;
  font-weight: 900;
  color: #60447d;
}

.login-note-static {
  display: block;
  margin: -10px 0 16px;
  font-size: 16px !important;
}

#submitLoginNote {
  display: none;
}

#submitLoginNote.show {
  display: inline-block;
}

.question-submit-row {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
  margin-top: 8px;
}

.question-form {
  margin-top: 28px;
  display: grid;
  gap: 14px;
  max-width: 620px;
}

.question-form label {
  font-size: 18px;
  font-weight: 900;
}

.question-form input,
.question-form textarea {
  width: 100%;
  padding: 16px 18px;
  border: 4px solid #111;
  border-radius: 18px;
  background: #fff;
  color: #111;
  font-family: inherit;
  font-size: 20px;
  outline: none;
  box-shadow: 5px 5px 0 #ffde59;
}

.question-form input:focus,
.question-form textarea:focus {
  box-shadow: 5px 5px 0 #11d6a0;
}

.question-form button {
  width: fit-content;
  margin-top: 0;
  background: #ff4fa3;
  color: white;
}

footer {
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto 40px;
  padding: 20px;
  color: #333;
  display: flex;
  justify-content: space-between;
  gap: 20px;
}

footer p {
  margin: 0;
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-24px); }
}

@keyframes bob {
  0%, 100% { transform: translateY(0) rotate(-3deg); }
  50% { transform: translateY(-14px) rotate(3deg); }
}

@keyframes frogFloat {
  0%, 100% { margin-bottom: 0; }
  50% { margin-bottom: 13px; }
}

@media (max-width: 850px) {
  .topbar,
  footer {
    align-items: flex-start;
    flex-direction: column;
  }

  .hero,
  .split,
  .grid {
    grid-template-columns: 1fr;
  }

  .hero {
    min-height: 0;
  }

  .hero-card {
    height: 420px;
  }

  .section {
    padding: 26px;
  }

  .topbar-right {
    justify-content: flex-start;
  }

  nav {
    justify-content: flex-start;
  }

  .book-stack {
    height: 340px;
  }

  .book {
    width: min(250px, calc(100% - 24px));
    height: 72px;
    right: auto !important;
    left: 12px;
  }

  .book.one {
    top: 0;
  }

  .book.two {
    top: 84px;
  }

  .book.three {
    top: 168px;
  }

  .book.four {
    top: 252px;
  }
}


@media (max-width: 850px) {
  .frog-mascot {
    height: 480px;
    width: auto;
    bottom: -120px;
  }

  .speech-bubble {
    top: -40px;
    right: 18px;
    max-width: 245px;
    font-size: 18px;
  }
}


.question-content {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 340px;
  gap: 32px;
  align-items: stretch;
}

.question-left {
  min-width: 0;
}

.question-frog-card {
  position: relative;
  min-height: 420px;
  overflow: visible;
}

.question-frog {
  position: absolute;
  left: 50%;
  bottom: 0px;
  height: 450px;
  width: auto;
  max-width: none;
  transform: translateX(-50%);
  filter: drop-shadow(0 13px 0 rgba(0,0,0,0.18));
  animation: frogFloat 3.2s ease-in-out infinite;
  transition: transform 0.18s ease, filter 0.18s ease;
  cursor: pointer;
}

.question-frog:hover {
  transform: translateX(-50%) translateY(-8px) scale(1.04) rotate(2deg);
  filter: drop-shadow(0 18px 0 rgba(0,0,0,0.16));
}

.question-speech-bubble {
  position: absolute;
  top: -90px;
  left: 10px;
  max-width: 255px;
  padding: 16px 18px;
  border: 5px solid #111;
  border-radius: 28px 28px 12px 28px;
  background: #fff5a8;
  box-shadow: 6px 6px 0 #111;
  font-size: 24px;
  line-height: 1.15;
  font-weight: 900;
  z-index: 5;
  opacity: 0;
  transform: translateY(10px) scale(0.94) rotate(-2deg);
  transition: opacity 0.18s ease, transform 0.18s ease;
  pointer-events: none;
}

.question-speech-bubble::after {
  content: "";
  position: absolute;
  right: 78px;
  bottom: -21px;
  width: 28px;
  height: 28px;
  background: #fff5a8;
  border-right: 5px solid #111;
  border-bottom: 5px solid #111;
  transform: rotate(45deg);
  z-index: 0;
}

.question-speech-bubble.show {
  opacity: 1;
  transform: translateY(0) scale(1) rotate(-2deg);
}

@media (max-width: 850px) {
  .question-content {
    grid-template-columns: 1fr;
  }

  .question-frog-card {
    min-height: 320px;
  }

  .question-frog {
    height: 280px;
    width: auto;
    bottom: -80px;
  }
}


/* Final tuning: flatter overlapping book bars + stronger big boeken press */
.book {
  font-size: 25px;
}

.book.one {
  color: #111;
  top: 0px;
  right: 92px;
  transform: rotate(3deg);
}

.book.one:hover {
  transform: translate(4px, 4px) rotate(3deg);
}

.book.two {
  top: 56px;
  right: 32px;
  transform: rotate(-2deg);
}

.book.two:hover {
  transform: translate(4px, 4px) rotate(-2deg);
}

.book.three {
  top: 112px;
  right: 88px;
  transform: rotate(2deg);
}

.book.three:hover {
  transform: translate(4px, 4px) rotate(2deg);
}

.book.four {
  top: 168px;
  right: 44px;
  transform: rotate(-3deg);
}

.book.four:hover {
  transform: translate(4px, 4px) rotate(-3deg);
}

.split:hover,
.books-section-button:hover,
.book-section-button:hover {
  transform: translate(7px, 7px) rotate(-1deg);
  box-shadow: 3px 3px 0 #111;
}


/* Final book-bar spacing: less overlap, more horizontal separation */
.book.one {
  top: 0px;
  right: 112px;
  transform: rotate(3deg);
}

.book.one:hover {
  transform: translate(4px, 4px) rotate(3deg);
}

.book.two {
  top: 66px;
  right: 24px;
  transform: rotate(-2deg);
}

.book.two:hover {
  transform: translate(4px, 4px) rotate(-2deg);
}

.book.three {
  top: 132px;
  right: 104px;
  transform: rotate(2deg);
}

.book.three:hover {
  transform: translate(4px, 4px) rotate(2deg);
}

.book.four {
  top: 198px;
  right: 36px;
  transform: rotate(-3deg);
}

.book.four:hover {
  transform: translate(4px, 4px) rotate(-3deg);
}

.book-stack {
  height: 285px;
}


/* Irregular book-bar stack: no same-line alignment, mixed horizontal spacing */
.book.one {
  top: 0px;
  right: 104px;
  transform: rotate(4deg);
}

.book.one:hover {
  transform: translate(4px, 4px) rotate(4deg);
}

.book.two {
  top: 66px;
  right: 34px;
  transform: rotate(-2deg);
}

.book.two:hover {
  transform: translate(4px, 4px) rotate(-2deg);
}

.book.three {
  top: 136px;
  right: 78px;
  transform: rotate(2deg);
}

.book.three:hover {
  transform: translate(4px, 4px) rotate(2deg);
}

.book.four {
  top: 202px;
  right: 42px;
  transform: rotate(-3deg);
}

.book.four:hover {
  transform: translate(4px, 4px) rotate(-3deg);
}

.book-stack {
  height: 292px;
}


/* Final requested tweak: smaller bar text + Antwoorden further left */
.book {
  font-size: 21px;
}

.book.three {
  right: 126px;
}

.book.three:hover {
  transform: translate(4px, 4px) rotate(2deg);
}


/* Resize bars to better fit 21px text */
.book {
  width: 232px;
  height: 66px;
  font-size: 21px;
}

.book-stack {
  height: 262px;
}

.book.one { top: 0px; }
.book.two { top: 58px; }
.book.three { top: 118px; }
.book.four { top: 178px; }


/* More playful angles with less overlap */
.book-stack {
  height: 286px;
}

.book.one {
  top: 0px;
  right: 106px;
  transform: rotate(6deg);
}

.book.one:hover {
  transform: translate(4px, 4px) rotate(6deg);
}

.book.two {
  top: 66px;
  right: 30px;
  transform: rotate(-4deg);
}

.book.two:hover {
  transform: translate(4px, 4px) rotate(-4deg);
}

.book.three {
  top: 134px;
  right: 126px;
  transform: rotate(4deg);
}

.book.three:hover {
  transform: translate(4px, 4px) rotate(4deg);
}

.book.four {
  top: 202px;
  right: 40px;
  transform: rotate(-5deg);
}

.book.four:hover {
  transform: translate(4px, 4px) rotate(-5deg);
}


/* Book bars: more stacked, less separated */
.book-stack {
  height: 266px;
}

.book.one {
  top: 0px;
  right: 96px;
  transform: rotate(4.5deg);
}

.book.one:hover {
  transform: translate(4px, 4px) rotate(4.5deg);
}

.book.two {
  top: 58px;
  right: 30px;
  transform: rotate(-3deg);
}

.book.two:hover {
  transform: translate(4px, 4px) rotate(-3deg);
}

.book.three {
  top: 116px;
  right: 122px;
  transform: rotate(3deg);
}

.book.three:hover {
  transform: translate(4px, 4px) rotate(3deg);
}

.book.four {
  top: 174px;
  right: 42px;
  transform: rotate(-4deg);
}

.book.four:hover {
  transform: translate(4px, 4px) rotate(-4deg);
}


/* Final boeken section behavior: yellow box stays still, only inside reacts */
.clickable-book-section:hover,
.split:hover,
.books-section-button:hover,
.book-section-button:hover {
  transform: none !important;
  box-shadow: 10px 10px 0 #111 !important;
}

.clickable-book-section .book-main-display .tile-icon {
  transition: transform 0.18s ease;
}

.clickable-book-section:hover .book-main-display .tile-icon {
  transform: translateY(-4px) rotate(3deg) scale(1.07);
}

.clickable-book-section:hover .book-main-display h3,
.clickable-book-section:hover .book-main-display p {
  transform: translateY(-3px);
}

/* Final book bars: closer, neater, less angled */
.book {
  width: 232px;
  height: 66px;
  font-size: 21px;
}

.book-stack {
  height: 260px;
}

.book.one {
  color: #111;
  top: 0px;
  right: 88px;
  transform: rotate(2deg);
}

.book.one:hover {
  transform: translate(4px, 4px) rotate(2deg);
}

.book.two {
  top: 58px;
  right: 52px;
  transform: rotate(-1.5deg);
}

.book.two:hover {
  transform: translate(4px, 4px) rotate(-1.5deg);
}

.book.three {
  top: 116px;
  right: 104px;
  transform: rotate(1.5deg);
}

.book.three:hover {
  transform: translate(4px, 4px) rotate(1.5deg);
}

.book.four {
  top: 174px;
  right: 60px;
  transform: rotate(-2deg);
}

.book.four:hover {
  transform: translate(4px, 4px) rotate(-2deg);
}


/* Let the book bars react when hovering the whole yellow boeken section.
   Direct .book:hover behavior stays unchanged below/above this. */
.split:hover .book.one,
.clickable-book-section:hover .book.one,
.books-section-button:hover .book.one,
.book-section-button:hover .book.one {
  transform: translateY(-3px) rotate(2deg);
}

.split:hover .book.two,
.clickable-book-section:hover .book.two,
.books-section-button:hover .book.two,
.book-section-button:hover .book.two {
  transform: translateY(-2px) rotate(-1.5deg);
}

.split:hover .book.three,
.clickable-book-section:hover .book.three,
.books-section-button:hover .book.three,
.book-section-button:hover .book.three {
  transform: translateY(-3px) rotate(1.5deg);
}

.split:hover .book.four,
.clickable-book-section:hover .book.four,
.books-section-button:hover .book.four,
.book-section-button:hover .book.four {
  transform: translateY(-2px) rotate(-2deg);
}

/* Keep individual bar hover press-in stronger than the yellow-section hover. */
.book.one:hover {
  transform: translate(4px, 4px) rotate(2deg);
}

.book.two:hover {
  transform: translate(4px, 4px) rotate(-1.5deg);
}

.book.three:hover {
  transform: translate(4px, 4px) rotate(1.5deg);
}

.book.four:hover {
  transform: translate(4px, 4px) rotate(-2deg);
}


/* Bars subtly pop to the front when hovering the yellow boeken section */
.split:hover .book.one,
.clickable-book-section:hover .book.one {
  transform: translateY(-4px) scale(1.03) rotate(2deg);
  z-index: 8;
}

.split:hover .book.two,
.clickable-book-section:hover .book.two {
  transform: translateY(-2px) scale(1.02) rotate(-1.5deg);
  z-index: 9;
}

.split:hover .book.three,
.clickable-book-section:hover .book.three {
  transform: translateY(-5px) scale(1.04) rotate(1.5deg);
  z-index: 10;
}

.split:hover .book.four,
.clickable-book-section:hover .book.four {
  transform: translateY(-3px) scale(1.025) rotate(-2deg);
  z-index: 7;
}


/* Keep Videos above Antwoorden during yellow-section hover */
.split:hover .book.three,
.clickable-book-section:hover .book.three {
  z-index: 8;
}

.split:hover .book.four,
.clickable-book-section:hover .book.four {
  z-index: 10;
}


/* Permanent default stacking order matching hover state */
.book.one {
  z-index: 8;
}

.book.two {
  z-index: 9;
}

.book.three {
  z-index: 8;
}

.book.four {
  z-index: 10;
}


/* Final orderly z-order */
.book.one {
  z-index: 7;
}

.book.two {
  z-index: 8;
}

.book.three {
  z-index: 9;
}

.book.four {
  z-index: 10;
}

.split:hover .book.one,
.clickable-book-section:hover .book.one {
  z-index: 7;
}

.split:hover .book.two,
.clickable-book-section:hover .book.two {
  z-index: 8;
}

.split:hover .book.three,
.clickable-book-section:hover .book.three {
  z-index: 9;
}

.split:hover .book.four,
.clickable-book-section:hover .book.four {
  z-index: 10;
}


/* Equalize Uitwerkingen growth */
.split:hover .book.two,
.clickable-book-section:hover .book.two {
  transform: translateY(-2px) scale(1.035) rotate(-1.5deg);
}

/* Real press-in effect on direct hover */
.book.one:hover {
  transform: translate(5px, 5px) scale(1.035) rotate(2deg);
}

.book.two:hover {
  transform: translate(5px, 5px) scale(1.035) rotate(-1.5deg);
}

.book.three:hover {
  transform: translate(5px, 5px) scale(1.035) rotate(1.5deg);
}

.book.four:hover {
  transform: translate(5px, 5px) scale(1.035) rotate(-2deg);
}


/* Real press-in behavior for the floating hero cards: 7x8, breuken, grafieken */
.floating-card:hover {
  animation-play-state: paused;
  transform: translate(5px, 5px) rotate(0deg) scale(1.02) !important;
  box-shadow: 1px 1px 0 #111 !important;
}

/* Real press-in behavior for the four book bars */
.book:hover {
  box-shadow: 1px 1px 0 #111 !important;
}

.book.one:hover {
  transform: translate(5px, 5px) scale(1.02) rotate(2deg) !important;
}

.book.two:hover {
  transform: translate(5px, 5px) scale(1.02) rotate(-1.5deg) !important;
}

.book.three:hover {
  transform: translate(5px, 5px) scale(1.02) rotate(1.5deg) !important;
}

.book.four:hover {
  transform: translate(5px, 5px) scale(1.02) rotate(-2deg) !important;
}


/* Keep floating cards bobbing while hovering instead of snapping to fixed position */
.floating-card:hover {
  animation-play-state: running !important;
  transform: scale(1.02) !important;
  box-shadow: 1px 1px 0 #111 !important;
}


/* Proper floating-card press effect */
.floating-card {
  overflow: visible;
}

.floating-card-inner {
  transition: transform 0.15s, box-shadow 0.15s;
}

.floating-card:hover .floating-card-inner {
  transform: translate(5px, 5px) scale(1.02);
}


/* Correct floating-card press: whole button moves from its current bobbing position */
.floating-card {
  --press-x: 0px;
  --press-y: 0px;
}

.floating-card:hover {
  --press-x: 5px;
  --press-y: 5px;
  box-shadow: 1px 1px 0 #111 !important;
  animation-play-state: running !important;
  transform: none !important;
}

@keyframes bob {
  0%, 100% {
    transform: translate(var(--press-x), var(--press-y)) rotate(-3deg);
  }

  50% {
    transform: translate(var(--press-x), calc(var(--press-y) - 14px)) rotate(3deg);
  }
}

/* Disable the failed inner-wrapper version if it still exists in cache/CSS order */
.floating-card-inner,
.floating-card:hover .floating-card-inner {
  transform: none !important;
}


/* Keep sticky topbar above all page content, including popping book bars */
.topbar {
  z-index: 1000 !important;
}

main,
.section,
.split,
.book-stack {
  position: relative;
}

main,
.section,
.split {
  z-index: 1;
}


[data-open-calculator] {
  cursor: pointer;
}


/* In-page calculator overlay */
.calculator-overlay {
  position: fixed;
  inset: 0;
  z-index: 999999;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 28px;
}

.calculator-overlay.show {
  display: flex;
}

.calculator-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.38);
  backdrop-filter: blur(3px);
}

.calculator-panel {
  position: relative;
  width: 338px;
  height: min(704px, calc(100vh - 48px));
  border: 5px solid #111;
  border-radius: 30px;
  background: #dff7ff;
  box-shadow: 12px 12px 0 #111;
  overflow: hidden;
  transform: rotate(-1deg);
  animation: calcPop 0.16s ease-out;
}

.calculator-close {
  position: absolute;
  top: 8px;
  right: 8px;
  z-index: 2;
  width: 38px;
  height: 38px;
  border: 4px solid #111;
  border-radius: 14px;
  background: #ff4fa3;
  color: white;
  font-family: inherit;
  font-size: 28px;
  font-weight: 900;
  line-height: 26px;
  cursor: pointer;
  box-shadow: 4px 4px 0 #111;
  transition: transform 0.15s, box-shadow 0.15s;
}

.calculator-close:hover {
  transform: translate(3px, 3px);
  box-shadow: 1px 1px 0 #111;
}

.calculator-frame {
  width: 100%;
  height: 100%;
  border: 0;
  display: block;
  background: #dff7ff;
}

@keyframes calcPop {
  from {
    opacity: 0;
    transform: translateY(14px) scale(0.96) rotate(-1deg);
  }

  to {
    opacity: 1;
    transform: translateY(0) scale(1) rotate(-1deg);
  }
}

@media (max-width: 460px) {
  .calculator-overlay {
    padding: 10px;
  }

  .calculator-panel {
    width: min(338px, calc(100vw - 20px));
    height: min(704px, calc(100vh - 20px));
  }
}


/* Floating calculator widget: page remains interactive */
.calculator-overlay {
  position: fixed !important;
  inset: auto 24px 24px auto !important;
  z-index: 999999 !important;
  display: none !important;
  width: 338px !important;
  height: 704px !important;
  padding: 0 !important;
  pointer-events: none !important;
  align-items: unset !important;
  justify-content: unset !important;
}

.calculator-overlay.show {
  display: block !important;
}

.calculator-backdrop {
  display: none !important;
}

.calculator-panel {
  position: relative !important;
  width: 338px !important;
  height: 704px !important;
  border: 5px solid #111 !important;
  border-radius: 48px !important;
  background: #dff7ff !important;
  box-shadow: 12px 12px 0 #111 !important;
  overflow: hidden !important;
  transform: rotate(-1deg) !important;
  pointer-events: auto !important;
  animation: calcPop 0.16s ease-out !important;
}

.calculator-close {
  position: absolute !important;
  top: 8px !important;
  right: 8px !important;
  z-index: 2 !important;
}

.calculator-frame {
  width: 100% !important;
  height: 100% !important;
  border: 0 !important;
  display: block !important;
  background: transparent !important;
}

@media (max-width: 460px) {
  .calculator-overlay {
    right: 10px !important;
    bottom: 10px !important;
    width: min(338px, calc(100vw - 20px)) !important;
    height: min(704px, calc(100vh - 20px)) !important;
  }

  .calculator-panel {
    width: 100% !important;
    height: 100% !important;
  }
}


/* Final calculator floating overlay fix */
.calculator-overlay {
  position: fixed !important;
  right: 24px !important;
  bottom: 24px !important;
  left: auto !important;
  top: auto !important;
  z-index: 999999 !important;
  display: none !important;
  width: 338px !important;
  height: 704px !important;
  padding: 0 !important;
  pointer-events: none !important;
  align-items: unset !important;
  justify-content: unset !important;
}

.calculator-overlay.show {
  display: block !important;
}

.calculator-panel {
  pointer-events: auto !important;
}

.calculator-frame {
  pointer-events: auto !important;
}

.calculator-panel,
.calculator-overlay {
  width: 316px !important;
  height: 653px !important;
}
.calculator-panel {
  position: relative;
  overflow: visible;
}

.calculator-close {
  position: absolute;
  top: -90px;
  right: -90px;
  z-index: 10;
}
.calculator-close {
  top: -11px !important;
  right: -11px !important;
}

/* Final calculator close-button overflow fix */
.calculator-panel {
  overflow: visible !important;
}

.calculator-close {
  position: absolute !important;
  top: 0 !important;
  right: 0 !important;
  transform: translate(40%, -40%) !important;
  z-index: 999999 !important;
}

.calculator-frame {
  border-radius: 42px;
  overflow: hidden;
}

.calculator-close:hover {
  transform: translate(calc(40% + 3px), calc(-40% + 3px)) !important;
  box-shadow: 1px 1px 0 #111 !important;
}

/* Draggable calculator */
.calculator-panel {
  cursor: default;
}

.calculator-drag-layer {
  position: absolute;
  inset: 0;
  z-index: 50;
  pointer-events: none;
}

.calculator-drag-zone {
  position: absolute;
  pointer-events: auto;
  cursor: grab;
  touch-action: none;
}

.calculator-drag-zone:active {
  cursor: grabbing;
}

/* Top display/body area above the keys */
.calculator-drag-zone.drag-top {
  left: 0;
  top: 0;
  width: 100%;
  height: 235px;
}

/* Outer plastic sides, away from the clickable key area */
.calculator-drag-zone.drag-left {
  left: 0;
  top: 235px;
  width: 18px;
  height: calc(100% - 235px);
}

.calculator-drag-zone.drag-right {
  right: 0;
  top: 235px;
  width: 18px;
  height: calc(100% - 235px);
}

/* Horizontal non-button spaces between key rows */
.calculator-drag-zone.drag-gap-1 {
  left: 18px;
  top: 252px;
  width: calc(100% - 36px);
  height: 14px;
}

.calculator-drag-zone.drag-gap-2 {
  left: 18px;
  top: 300px;
  width: calc(100% - 36px);
  height: 14px;
}

.calculator-drag-zone.drag-gap-3 {
  left: 18px;
  top: 620px;
  width: calc(100% - 36px);
  height: 24px;
}

.calculator-close {
  z-index: 100 !important;
}



/* v4 drag movement fix */
.calculator-overlay {
  will-change: left, top;
}


/* v16 Electron calculator embed sizing */
.calculator-panel,
.calculator-overlay {
  width: 316px !important;
  height: 653px !important;
}

.calculator-frame {
  background: transparent !important;
}

/* v19 calculator iframe sizing */
.calculator-panel,
.calculator-overlay {
  width: 316px !important;
  height: 653px !important;
}
.calculator-frame {
  background: transparent !important;
}

/* v21 stable calculator */


/* Boeken page */
.logo-link {
  color: #111;
  text-decoration: none;
}

.nav-active {
  background: #111;
  color: white !important;
}

.boeken-main {
  margin-top: 34px;
}

.boeken-compact-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 26px;
  align-items: center;
  min-height: 0;
  padding: 28px 34px;
  background: #fff3aa;
}

.boeken-mini-label {
  display: inline-block;
  margin: 0 0 10px !important;
  padding: 7px 13px;
  border: 3px solid #111;
  border-radius: 999px;
  background: #11d6a0;
  box-shadow: 4px 4px 0 #111;
  color: #111 !important;
  font-size: 18px !important;
  font-weight: 900;
  line-height: 1 !important;
}

.boeken-compact-hero h1 {
  font-size: clamp(34px, 5vw, 58px);
  max-width: 650px;
}

.boeken-compact-hero .intro {
  max-width: 680px;
  margin-bottom: 0;
}

.boeken-kikker-card {
  position: relative;
  min-height: 220px;
}

.boeken-kikker {
  position: absolute;
  right: 8px;
  bottom: -34px;
  height: 235px;
  width: auto;
  filter: drop-shadow(0 10px 0 rgba(0,0,0,0.18));
  animation: frogFloat 3s ease-in-out infinite;
}

.boeken-speech {
  position: absolute;
  top: -6px;
  left: -8px;
  z-index: 2;
  width: 235px;
  padding: 14px 16px;
  border: 4px solid #111;
  border-radius: 22px;
  background: #fff;
  box-shadow: 5px 5px 0 #111;
  font-size: 18px;
  line-height: 1.2;
  transform: rotate(-2deg);
}

.boeken-speech::after {
  content: "";
  position: absolute;
  right: 52px;
  bottom: -18px;
  width: 24px;
  height: 24px;
  background: #fff;
  border-right: 4px solid #111;
  border-bottom: 4px solid #111;
  transform: rotate(45deg);
}

.boeken-page-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  gap: 24px;
  margin-top: 30px;
}

.boeken-panel {
  border: 5px solid #111;
  border-radius: 34px;
  background: rgba(255,255,255,0.82);
  box-shadow: 10px 10px 0 #111;
  padding: 26px;
}

.boeken-panel-header {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: baseline;
  margin-bottom: 18px;
}

.boeken-panel-header h2 {
  margin: 0;
  font-size: 42px;
}

.boeken-panel-header span {
  font-size: 18px;
  font-weight: 900;
  color: #8067ff;
  white-space: nowrap;
}

.deel-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}

.deel-card {
  border: 4px solid #111;
  border-radius: 28px;
  padding: 20px;
  box-shadow: 6px 6px 0 #111;
}

.deel-one {
  background: #cbb7ff;
}

.deel-two {
  background: #9cffc8;
}

.deel-card h3 {
  margin: 0 0 4px;
  font-size: 32px;
}

.deel-card p {
  margin: 0 0 14px;
  font-size: 18px;
  font-weight: 900;
}

.chapter-list {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.chapter-check {
  min-height: 70px;
  border: 3px solid #111;
  border-radius: 18px;
  background: white;
  box-shadow: 4px 4px 0 #111;
  font-family: inherit;
  color: #111;
  cursor: pointer;
  transition: transform 0.15s, box-shadow 0.15s, background 0.15s;
}

.chapter-check:hover {
  transform: translate(3px, 3px);
  box-shadow: 1px 1px 0 #111;
}

.chapter-check span {
  display: block;
  font-size: 24px;
  font-weight: 900;
}

.chapter-check small {
  display: block;
  font-size: 13px;
  font-weight: 900;
  opacity: 0.72;
}

.chapter-check.done {
  background: #9fe870;
}

.chapter-check.done::before {
  content: "✓";
  display: inline-block;
  margin-right: 4px;
  font-size: 22px;
  font-weight: 900;
}

.resources-panel {
  background: #7ee8ff;
}

.small-header {
  display: block;
  margin-bottom: 14px;
}

.small-header h2 {
  font-size: 38px;
  margin-bottom: 2px;
}

.small-header span {
  white-space: normal;
}

.resource-buttons {
  display: grid;
  gap: 12px;
}

.resource-button {
  display: block;
  padding: 14px 16px;
  border: 4px solid #111;
  border-radius: 20px;
  box-shadow: 5px 5px 0 #111;
  color: #111;
  text-decoration: none;
  transition: transform 0.15s, box-shadow 0.15s;
}

.resource-button:hover {
  transform: translate(4px, 4px);
  box-shadow: 1px 1px 0 #111;
}

.resource-button span {
  display: block;
  font-size: 24px;
  font-weight: 900;
}

.resource-button small {
  display: block;
  font-size: 15px;
  font-weight: 900;
}

.resource-button.pink { background: #ff4fa3; color: white; }
.resource-button.blue { background: #8067ff; color: #111; }
.resource-button.green-r { background: #11d6a0; }
.resource-button.yellow-r { background: #ffde59; }

.progress-box {
  margin-top: 18px;
  padding: 16px;
  border: 4px solid #111;
  border-radius: 22px;
  background: white;
  box-shadow: 5px 5px 0 #111;
}

.progress-top {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: center;
  font-size: 20px;
}

.progress-track {
  height: 22px;
  margin: 12px 0;
  border: 3px solid #111;
  border-radius: 999px;
  background: #eee;
  overflow: hidden;
}

#progressFill {
  width: 0%;
  height: 100%;
  background: #11d6a0;
  transition: width 0.18s ease;
}

#resetProgressButton {
  width: 100%;
  border: 3px solid #111;
  border-radius: 15px;
  background: #fff3aa;
  box-shadow: 3px 3px 0 #111;
  padding: 9px 10px;
  font-family: inherit;
  font-size: 16px;
  font-weight: 900;
  cursor: pointer;
}

#resetProgressButton:hover {
  transform: translate(2px, 2px);
  box-shadow: 1px 1px 0 #111;
}

@media (max-width: 900px) {
  .boeken-compact-hero,
  .boeken-page-grid,
  .deel-grid {
    grid-template-columns: 1fr;
  }

  .boeken-kikker-card {
    min-height: 190px;
  }

  .boeken-kikker {
    height: 210px;
    right: 20px;
  }

  .boeken-panel-header {
    display: block;
  }
}

@media (max-width: 520px) {
  .chapter-list {
    grid-template-columns: repeat(2, 1fr);
  }

  .boeken-panel,
  .boeken-compact-hero {
    padding: 22px;
  }
}

/* v53 boeken page requested layout */
.boeken-compact-hero {
  grid-template-columns: minmax(0, 1fr) 210px;
  padding: 24px 34px;
}

.boeken-compact-hero h1 {
  font-size: clamp(32px, 4.2vw, 50px);
}

.boeken-hero-image {
  width: 190px;
  max-width: 100%;
  justify-self: end;
  filter: drop-shadow(7px 7px 0 rgba(0,0,0,0.25));
  transform: rotate(3deg);
}

.boeken-page-grid {
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 22px;
  margin-top: 24px;
}

.boeken-panel {
  padding: 22px;
}

.boeken-panel-header {
  margin-bottom: 14px;
}

.deel-grid {
  grid-template-columns: 1fr;
  gap: 16px;
}

.deel-card {
  padding: 18px;
}

.deel-card h3 {
  margin: 0 0 14px;
  font-size: 34px;
}

.deel-card p {
  display: none;
}

.chapter-list {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 11px;
}

.chapter-check {
  position: relative;
  min-height: 74px;
  padding: 12px 48px 12px 14px;
  text-align: left;
}

.chapter-check span {
  font-size: 21px;
  line-height: 1.05;
}

.chapter-check small {
  display: none;
}

.check-circle {
  position: absolute;
  top: 50%;
  right: 13px;
  width: 26px;
  height: 26px;
  border: 3px solid #111;
  border-radius: 50%;
  background: #fff;
  transform: translateY(-50%);
  box-shadow: 2px 2px 0 #111;
}

.chapter-check.done {
  background: #9fe870;
}

.chapter-check.done::before {
  display: none;
}

.chapter-check.done .check-circle {
  background: #11d6a0;
}

.chapter-check.done .check-circle::after {
  content: "✓";
  position: absolute;
  left: 4px;
  top: -6px;
  font-size: 27px;
  font-weight: 900;
  color: #111;
}

.resources-panel {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.resource-buttons {
  gap: 10px;
}

.resource-button {
  padding: 14px 16px;
}

.resource-button span {
  font-size: 23px;
}

.resource-button small {
  display: block;
  margin-top: 2px;
  font-size: 13px;
  line-height: 1.1;
  font-weight: 800;
}

.side-kikker-box {
  position: relative;
  min-height: 172px;
  border: 4px solid #111;
  border-radius: 24px;
  background: #fff3aa;
  box-shadow: 5px 5px 0 #111;
  overflow: hidden;
}

.side-speech {
  top: 12px;
  left: 12px;
  width: 205px;
  padding: 12px 13px;
  font-size: 16px;
  box-shadow: 4px 4px 0 #111;
}

.side-speech::after {
  right: 38px;
}

.side-kikker {
  position: absolute;
  right: -10px;
  bottom: -26px;
  height: 118px;
  width: auto;
  filter: drop-shadow(0 7px 0 rgba(0,0,0,0.18));
}

.progress-box {
  margin-top: 0;
}

@media (max-width: 900px) {
  .boeken-compact-hero,
  .boeken-page-grid {
    grid-template-columns: 1fr;
  }

  .boeken-hero-image {
    justify-self: start;
    width: 170px;
  }
}

@media (max-width: 620px) {
  .chapter-list {
    grid-template-columns: 1fr;
  }
}

/* v54 boeken page: vertical deel labels, icon afvinken, hover speech */
.deel-card {
  display: grid;
  grid-template-columns: 70px minmax(0, 1fr);
  align-items: stretch;
  gap: 16px;
  padding: 16px 18px;
}

.deel-card h3 {
  writing-mode: vertical-rl;
  transform: rotate(180deg);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0;
  min-height: 178px;
  border: 4px solid #111;
  border-radius: 20px;
  background: rgba(255,255,255,0.72);
  box-shadow: 4px 4px 0 #111;
  font-size: 34px;
  line-height: 1;
  text-align: center;
}

.chapter-list {
  align-self: center;
}

.chapter-card {
  position: relative;
  min-height: 74px;
  padding: 12px 52px 12px 14px;
  border: 3px solid #111;
  border-radius: 18px;
  background: white;
  box-shadow: 4px 4px 0 #111;
  color: #111;
  cursor: pointer;
  transition: transform 0.15s, box-shadow 0.15s, background 0.15s;
}

.chapter-card:hover {
  transform: translate(3px, 3px);
  box-shadow: 1px 1px 0 #111;
}

.chapter-card span {
  display: block;
  font-size: 21px;
  line-height: 1.05;
  font-weight: 900;
}

.chapter-card.done {
  background: #9fe870;
}

.chapter-check {
  position: absolute;
  top: 50%;
  right: 12px;
  width: 32px;
  height: 32px;
  min-height: 0;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: transparent url("https://cdn.meneercengiz.nl/images/checkmark.png") center / 100% 100% no-repeat;
  box-shadow: 3px 3px 0 rgba(0,0,0,0.28);
  transform: translateY(-50%);
  cursor: pointer;
  transition: transform 0.15s, box-shadow 0.15s, filter 0.15s;
}

.chapter-check:hover {
  transform: translate(2px, calc(-50% + 2px));
  box-shadow: 1px 1px 0 rgba(0,0,0,0.32);
  filter: brightness(1.03);
}

.chapter-check.done {
  background: transparent url("https://cdn.meneercengiz.nl/images/checkmark.png") center / 100% 100% no-repeat;
}

.chapter-check.done::before,
.chapter-check.done::after,
.chapter-check.done .check-circle,
.chapter-check .check-circle {
  display: none !important;
  content: none !important;
}

.side-kikker-box {
  min-height: 190px;
  overflow: visible;
}

.side-kikker {
  right: 8px;
  bottom: -24px;
  height: 165px;
  z-index: 1;
}

.side-speech {
  top: -58px;
  left: 8px;
  width: 232px;
  padding: 13px 14px;
  font-size: 17px;
  opacity: 0;
  pointer-events: none;
  transform: translateY(8px) rotate(-2deg) scale(0.96);
  transition: opacity 0.16s, transform 0.16s;
}

.side-kikker-box:hover .side-speech,
.side-kikker-box:focus-within .side-speech {
  opacity: 1;
  transform: translateY(0) rotate(-2deg) scale(1);
}

@media (max-width: 620px) {
  .deel-card {
    grid-template-columns: 56px minmax(0, 1fr);
    gap: 12px;
  }

  .deel-card h3 {
    min-height: 420px;
    font-size: 28px;
  }
}

/* v55 boeken page refinements */
.boeken-panel-header.small-header {
  margin-bottom: 8px;
}

.deel-card {
  grid-template-columns: 56px minmax(0, 1fr);
  gap: 14px;
  align-items: center;
}

.deel-card h3 {
  border: 0;
  background: transparent;
  box-shadow: none;
  border-radius: 0;
  min-height: 150px;
  padding: 0;
  color: #111;
  font-size: 34px;
  cursor: default;
  pointer-events: none;
}

.chapter-list {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.chapter-card {
  min-height: 58px;
  padding: 10px 46px 10px 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.chapter-card span {
  display: block;
  font-size: 20px;
  line-height: 1.05;
}

.chapter-check {
  width: 30px;
  height: 30px;
  min-width: 30px;
  min-height: 30px;
  padding: 0;
  background: transparent url("https://cdn.meneercengiz.nl/images/checkmark.png") center / 100% 100% no-repeat;
  opacity: 0.25;
  box-shadow: 3px 3px 0 rgba(0,0,0,0.24);
}

.chapter-check.done {
  background: transparent url("https://cdn.meneercengiz.nl/images/checkmark.png") center / 100% 100% no-repeat;
  opacity: 1;
}

.chapter-check:hover {
  opacity: 0.55;
}

.chapter-check.done:hover {
  opacity: 1;
}

.resources-panel {
  gap: 10px;
}

.side-kikker-box {
  min-height: 218px;
  overflow: visible;
  background: #fff3aa;
}

.side-kikker {
  height: 190px;
  right: 0;
  bottom: -26px;
  z-index: 2;
}

.boeken-speech.side-speech {
  position: absolute;
  top: -34px;
  left: 10px;
  width: 250px;
  max-width: 285px;
  padding: 18px 20px;
  border: 5px solid #111;
  border-radius: 28px;
  background: #fff5a8;
  box-shadow: 7px 7px 0 #111;
  font-size: 18px;
  line-height: 1.25;
  z-index: 5;
  opacity: 0;
  transform: translateY(10px) scale(0.94) rotate(2deg);
  transition: opacity 0.18s ease, transform 0.18s ease;
  pointer-events: none;
}

.boeken-speech.side-speech::after {
  content: "";
  position: absolute;
  left: 72px;
  right: auto;
  bottom: -24px;
  width: 34px;
  height: 34px;
  background: #fff5a8;
  border-right: 5px solid #111;
  border-bottom: 5px solid #111;
  transform: rotate(45deg);
  z-index: 0;
}

.side-kikker-box:hover .side-speech,
.side-kikker-box:focus-within .side-speech {
  opacity: 1;
  transform: translateY(0) scale(1) rotate(2deg);
}

@media (max-width: 620px) {
  .chapter-list {
    grid-template-columns: 1fr;
  }

  .deel-card h3 {
    min-height: 320px;
  }
}

/* v68 boeken page: surfer clipped only by yellow hero box */
.boeken-compact-hero {
  position: relative;
  overflow: hidden;
  --frog-anchor-right: 182px;
  --frog-bottom: -3px;
  --surfer-hidden-drop: 100px;
  --frog-scale: 0.35;
}

.boeken-hero-text,
.boeken-hero-visual {
  position: relative;
  z-index: 3;
}

.boeken-hero-visual {
  position: relative;
  align-self: stretch;
  min-height: 174px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  overflow: visible;
}

.boeken-hero-visual .boeken-hero-image {
  position: relative;
  z-index: 3;
}

.boeken-surfer-clip {
  position: absolute;
  inset: 0;
  overflow: hidden;
  z-index: 2;
  pointer-events: none;
}

.boeken-peek-frog {
  position: absolute;
  right: var(--frog-anchor-right);
  bottom: var(--frog-bottom);
  width: 1px;
  height: 1px;
  z-index: 4;
  pointer-events: auto;
  cursor: pointer;
  overflow: visible;
}

.peek-frog-image {
  position: absolute;
  max-width: none;
  max-height: none;
  width: auto;
  height: auto;
  transform-origin: bottom center;
  filter: drop-shadow(0 4px 0 rgba(0,0,0,0.18));
  user-select: none;
  -webkit-user-drag: none;
  pointer-events: none;
}

.peek-frog-surfer {
  right: var(--frog-anchor-right);
  bottom: var(--frog-bottom);
  z-index: 2;
  transform: translateX(50%) translateY(var(--surfer-hidden-drop)) scale(var(--frog-scale));
  transition: transform 720ms cubic-bezier(.2,.85,.18,1);
  will-change: transform;
}

.peek-frog-hands {
  left: 50%;
  bottom: 0;
  z-index: 4;
  transform: translateX(-50%) scale(var(--frog-scale));
}

.boeken-peek-frog:hover ~ .peek-frog-surfer,
.boeken-compact-hero:hover .peek-frog-surfer,
.boeken-compact-hero:focus-within .peek-frog-surfer {
  transform: translateX(50%) translateY(0) scale(var(--frog-scale));
}

@media (max-width: 760px) {
  .boeken-compact-hero {
    --frog-anchor-right: 88px;
    --frog-bottom: -34px;
    --surfer-hidden-drop: 204px;
  }

  .boeken-hero-visual {
    min-height: 150px;
  }
}

@media (max-width: 520px) {
  .boeken-compact-hero {
    --frog-anchor-right: 72px;
  }
}


/* v69: surfer clips inside yellow box; hands can overflow above the border; boeken.png removed */
.boeken-compact-hero {
  overflow: visible;
  --frog-bottom: -12px;
}

.boeken-surfer-clip {
  inset: 0;
  overflow: hidden;
  z-index: 2;
}

.boeken-peek-frog {
  z-index: 8;
  overflow: visible;
}

.peek-frog-hands {
  z-index: 8;
}

.boeken-hero-visual,
.boeken-hero-image {
  display: none !important;
}


/* v74: boeken peek speech bubble is positioned independently and only appears on hover */
.boeken-peek-speech {
  position: absolute;
  right: 0px;
  bottom: calc(var(--frog-bottom) + 198px);
  max-width: 285px;
  padding: 18px 20px;
  border: 5px solid #111;
  border-radius: 28px;
  background: #fff5a8;
  color: #111;
  box-shadow: 7px 7px 0 #111;
  font-size: 21px;
  font-weight: 400;
  line-height: 1.25;
  z-index: 20;
  transform: translate(-100px, 10px) rotate(2deg) scale(0.9);
  transform-origin: right bottom;
  opacity: 0;
  pointer-events: none;
  overflow: visible;
  transition: opacity 160ms ease, transform 160ms ease;
  isolation: isolate;
}

.boeken-compact-hero:hover .boeken-peek-speech,
.boeken-compact-hero:focus-within .boeken-peek-speech {
  opacity: 1;
  transform: translate(-100px, 0) rotate(2deg) scale(0.9);
}

.boeken-peek-speech::after {
  content: "";
  position: absolute;
  right: 72px;
  bottom: -24px;
  width: 34px;
  height: 34px;
  background: #fff5a8;
  border-right: 5px solid #111;
  border-bottom: 5px solid #111;
  transform: rotate(45deg);
  z-index: 1;
}

.boeken-peek-speech strong {
  font-weight: 900;
}

@media (max-width: 760px) {
  .boeken-peek-speech {
    right: -26px;
    bottom: calc(var(--frog-bottom) + 132px);
    max-width: 245px;
    font-size: 17px;
    padding: 14px 16px;
  }
}


/* v78: restore hoofdstukken title, use checkmark image inside chapter circles */
.hoofdstukken-title {
  margin-bottom: 12px;
}

.hoofdstukken-title h2 {
  margin: 0;
}

.chapter-check {
  background-image: url("https://cdn.meneercengiz.nl/images/checkmark.png") !important;
  background-position: center !important;
  background-size: 115% 115% !important;
  background-repeat: no-repeat !important;
}

.progress-top {
  justify-content: center;
}


/* v79: keep speech text above the triangle tail */
.boeken-peek-speech-text {
  position: relative;
  z-index: 2;
}


/* v80: resource text and hoofdstukken inline note */
.resource-button,
.resource-button.blue,
.resource-button.green-r,
.resource-button.yellow-r {
  color: #111 !important;
}

.hoofdstukken-title {
  display: flex;
  align-items: baseline;
  gap: 12px;
  flex-wrap: wrap;
}

.hoofdstukken-title span {
  font-size: 15px;
  font-weight: 800;
  color: rgba(17,17,17,0.62);
  line-height: 1.1;
}

/* v81: hoofdstuk 1 reader page */
.reader-main {
  margin-top: 34px;
}

.reader-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 280px;
  gap: 24px;
  align-items: center;
  padding: 28px 34px;
  background: #fff3aa;
  overflow: visible;
}

.reader-back-link {
  display: inline-block;
  margin-bottom: 12px;
  color: #111;
  font-size: 18px;
  font-weight: 900;
  text-decoration: none;
}

.reader-back-link:hover {
  text-decoration: underline;
}

.reader-hero h1 {
  margin: 0 0 10px;
  font-size: clamp(34px, 5vw, 58px);
  line-height: 0.95;
}

.reader-frog-card {
  position: relative;
  min-height: 210px;
}

.reader-frog {
  position: absolute;
  right: 0;
  bottom: -22px;
  height: 205px;
  width: auto;
  filter: drop-shadow(0 8px 0 rgba(0,0,0,0.18));
  transform: rotate(3deg);
}

.reader-speech {
  position: absolute;
  top: -8px;
  left: -10px;
  z-index: 2;
  width: 245px;
  padding: 14px 16px;
  border: 5px solid #111;
  border-radius: 26px;
  background: #fff;
  box-shadow: 6px 6px 0 #111;
  font-size: 18px;
  font-weight: 900;
  line-height: 1.12;
  transform: rotate(-2deg);
}

.reader-speech::after {
  content: "";
  position: absolute;
  right: 52px;
  bottom: -20px;
  width: 28px;
  height: 28px;
  background: #fff;
  border-right: 5px solid #111;
  border-bottom: 5px solid #111;
  transform: rotate(45deg);
}

.reader-layout {
  width: min(1120px, calc(100% - 32px));
  margin: 28px auto 0;
  display: grid;
  grid-template-columns: 310px minmax(0, 1fr);
  gap: 24px;
  align-items: start;
}

.reader-sidebar {
  position: sticky;
  top: 128px;
  display: grid;
  gap: 16px;
}

.reader-side-panel,
.pdf-card,
.reader-resource-card {
  border: 5px solid #111;
  border-radius: 30px;
  background: rgba(255,255,255,0.86);
  box-shadow: 8px 8px 0 #111;
}

.reader-side-panel {
  padding: 18px;
}

.reader-mode-panel {
  background: #7ee8ff;
}

.reader-mode-panel strong,
.reader-mode-panel span {
  display: block;
  font-size: 20px;
  font-weight: 900;
}

.reader-mode-panel span {
  margin-top: 3px;
  font-size: 16px;
}

.reader-side-panel h2 {
  margin: 0 0 12px;
  font-size: 30px;
  line-height: 1;
}

.reader-quick-grid,
.paragraph-list {
  display: grid;
  gap: 10px;
}

.reader-jump-button,
.paragraph-list button,
.reader-resource-card button,
.reader-resource-card a,
.pdf-toolbar a {
  border: 4px solid #111;
  border-radius: 18px;
  background: #fff;
  color: #111;
  box-shadow: 4px 4px 0 #111;
  font-family: inherit;
  font-size: 18px;
  font-weight: 900;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.15s, box-shadow 0.15s;
}

.reader-jump-button,
.paragraph-list button,
.reader-resource-card button,
.reader-resource-card a {
  padding: 12px 14px;
}

.reader-jump-button:hover,
.paragraph-list button:hover,
.reader-resource-card button:hover,
.reader-resource-card a:hover,
.pdf-toolbar a:hover {
  transform: translate(3px, 3px);
  box-shadow: 1px 1px 0 #111;
}

.reader-jump-button.purple,
.reader-resource-card.purple { background: #cbb7ff; }
.reader-jump-button.green,
.reader-resource-card.green { background: #9cffc8; }
.reader-jump-button.yellow,
.reader-resource-card.yellow { background: #ffde59; }

.paragraph-list button {
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr);
  gap: 8px;
  align-items: center;
  text-align: left;
}

.paragraph-list button span {
  display: inline-grid;
  place-items: center;
  width: 42px;
  height: 34px;
  border: 3px solid #111;
  border-radius: 12px;
  background: #ffde59;
  font-size: 17px;
}

.paragraph-list button.active {
  background: #9fe870;
}

.reader-content {
  min-width: 0;
  display: grid;
  gap: 24px;
}

.pdf-card {
  overflow: hidden;
  background: #dff7ff;
}

.pdf-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 16px;
  border-bottom: 5px solid #111;
  background: #fff;
}

.pdf-toolbar strong,
.pdf-toolbar span {
  display: block;
  font-weight: 900;
}

.pdf-toolbar strong {
  font-size: 22px;
}

.pdf-toolbar span {
  font-size: 14px;
  opacity: 0.68;
}

.pdf-toolbar a {
  display: inline-block;
  padding: 8px 12px;
  background: #ff4fa3;
  color: white;
  white-space: nowrap;
}

.book-frame {
  display: block;
  width: 100%;
  height: min(760px, calc(100vh - 210px));
  min-height: 520px;
  border: 0;
  background: white;
}

.pdf-missing-note {
  padding: 10px 16px 14px;
  border-top: 4px solid #111;
  background: #fff3aa;
  font-size: 15px;
  font-weight: 900;
}

.reader-resource-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  scroll-margin-top: 130px;
}

.reader-resource-card {
  padding: 20px;
}

.reader-resource-card h2 {
  margin: 0 0 8px;
  font-size: 31px;
  line-height: 1;
}

.reader-resource-card p {
  margin: 0 0 14px;
  font-size: 17px;
  font-weight: 900;
  line-height: 1.2;
}

.reader-resource-card button,
.reader-resource-card a {
  display: inline-block;
  background: white;
}

#antwoorden,
#videos,
#uitwerkingen {
  scroll-margin-top: 130px;
}

@media (max-width: 920px) {
  .reader-hero,
  .reader-layout,
  .reader-resource-grid {
    grid-template-columns: 1fr;
  }

  .reader-sidebar {
    position: static;
  }

  .reader-frog-card {
    display: none;
  }
}

@media (max-width: 560px) {
  .reader-hero,
  .reader-side-panel,
  .reader-resource-card {
    padding: 18px;
  }

  .book-frame {
    height: 560px;
    min-height: 460px;
  }

  .pdf-toolbar {
    align-items: flex-start;
    flex-direction: column;
  }
}

/* v82: clean chapter reader with rendered PDF pages */
.reader-main-compact {
  width: min(1320px, calc(100% - 32px));
  margin: 30px auto 0;
}

.reader-layout-wide {
  width: 100%;
  margin: 0;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 24px;
}

.reader-resource-side {
  position: sticky;
  top: 126px;
  display: grid;
  gap: 16px;
}

.reader-back-small {
  margin: 0;
  padding: 12px 14px;
  border: 4px solid #111;
  border-radius: 18px;
  background: #fff;
  box-shadow: 5px 5px 0 #111;
  font-size: 17px;
}

.reader-pdf-card {
  background: #e7e0ef;
  overflow: visible;
}

.reader-toolbar-clean {
  position: sticky;
  top: 0;
  z-index: 20;
  overflow: visible;
  border-radius: 25px 25px 0 0;
}

.reader-toolbar-clean strong {
  font-size: clamp(18px, 2.2vw, 28px);
  line-height: 1.05;
}

.reader-toolbar-clean span {
  margin-top: 4px;
  font-size: 16px;
  opacity: 0.72;
}

.reader-dropdown-wrap {
  position: relative;
  flex: 0 0 auto;
}

.reader-jump-toggle {
  border: 4px solid #111;
  border-radius: 18px;
  background: #ffde59;
  color: #111;
  box-shadow: 4px 4px 0 #111;
  padding: 10px 14px;
  font-family: inherit;
  font-size: 18px;
  font-weight: 900;
  cursor: pointer;
  transition: transform 0.15s, box-shadow 0.15s;
}

.reader-jump-toggle:hover {
  transform: translate(3px, 3px);
  box-shadow: 1px 1px 0 #111;
}

.reader-jump-menu {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  z-index: 50;
  display: none;
  width: 310px;
  padding: 10px;
  border: 4px solid #111;
  border-radius: 20px;
  background: #fff;
  box-shadow: 6px 6px 0 #111;
}

.reader-jump-menu.show {
  display: grid;
  gap: 8px;
}

.reader-jump-menu button {
  width: 100%;
  border: 3px solid #111;
  border-radius: 14px;
  background: #f4ecff;
  color: #111;
  padding: 10px 12px;
  font-family: inherit;
  font-size: 16px;
  font-weight: 900;
  text-align: left;
  cursor: pointer;
}

.reader-jump-menu button:hover,
.reader-jump-menu button.active {
  background: #9cffc8;
}

.pdf-pages {
  display: grid;
  gap: 18px;
  padding: 18px;
  background: #cfc3df;
}

.pdf-loading {
  padding: 36px 22px;
  border: 4px solid #111;
  border-radius: 22px;
  background: #fff;
  box-shadow: 5px 5px 0 #111;
  font-size: 22px;
  font-weight: 900;
  text-align: center;
}

.pdf-error {
  background: #fff3aa;
}

.pdf-page-wrap {
  scroll-margin-top: 92px;
  display: grid;
  gap: 8px;
  justify-items: center;
}

.pdf-page-label {
  justify-self: start;
  padding: 6px 10px;
  border: 3px solid #111;
  border-radius: 999px;
  background: #fff;
  box-shadow: 3px 3px 0 #111;
  font-size: 14px;
  font-weight: 900;
}

.pdf-page-canvas {
  display: block;
  max-width: 100%;
  height: auto;
  border: 4px solid #111;
  border-radius: 12px;
  background: white;
  box-shadow: 7px 7px 0 rgba(17, 17, 17, 0.9);
}

.reader-resource-panel-right {
  display: grid;
  gap: 12px;
  background: #fff3aa;
}

.reader-resource-panel-right p {
  margin: -2px 0 2px;
  font-size: 16px;
  font-weight: 900;
  line-height: 1.2;
}

.reader-resource-panel-right .reader-jump-button {
  width: 100%;
  text-align: left;
}

@media (max-width: 980px) {
  .reader-layout-wide {
    grid-template-columns: 1fr;
  }

  .reader-resource-side {
    position: static;
    order: -1;
  }

  .reader-toolbar-clean {
    top: 0;
  }
}

@media (max-width: 560px) {
  .reader-main-compact {
    width: min(100% - 18px, 1320px);
  }

  .reader-toolbar-clean {
    flex-direction: column;
    align-items: stretch;
  }

  .reader-dropdown-wrap,
  .reader-jump-toggle {
    width: 100%;
  }

  .reader-jump-menu {
    left: 0;
    right: auto;
    width: min(310px, calc(100vw - 54px));
  }

  .pdf-pages {
    padding: 10px;
  }
}


/* v83: tighter embedded reader */
.reader-page-body {
  overflow: hidden;
}

.reader-main-compact {
  width: min(1160px, calc(100% - 28px));
  margin: 20px auto 0;
}

.reader-layout-wide {
  grid-template-columns: minmax(0, 800px) 300px;
  gap: 18px;
  align-items: start;
  justify-content: center;
}

.reader-resource-side {
  top: 104px;
  max-height: calc(100vh - 124px);
  overflow: hidden;
}

.reader-pdf-card {
  overflow: hidden;
  padding: 0;
}

.reader-toolbar-clean {
  position: relative;
  top: auto;
  z-index: 2;
  min-height: 0;
  padding: 14px 18px;
  border-radius: 25px 25px 0 0;
}

.reader-toolbar-clean strong {
  font-size: clamp(22px, 2.4vw, 31px);
}

.pdf-pages {
  display: block;
  height: calc(100vh - 214px);
  min-height: 420px;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 0;
  background: #fff;
}

.pdf-page-wrap {
  display: block;
  scroll-margin-top: 0;
  margin: 0;
  padding: 0;
  line-height: 0;
  background: #fff;
}

.pdf-page-label {
  display: none;
}

.pdf-page-canvas {
  display: block;
  width: 100% !important;
  max-width: 100%;
  height: auto !important;
  margin: 0 auto;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  background: white;
}

.pdf-missing-note {
  display: none;
}

.reader-resource-panel-right {
  gap: 10px;
  max-height: calc(100vh - 188px);
  overflow: hidden;
}

.reader-resource-panel-right h2 {
  margin-bottom: 2px;
}

.reader-resource-panel-right p {
  display: none;
}

.reader-side-jump-list {
  display: grid;
  gap: 8px;
  max-height: 280px;
  overflow-y: auto;
  padding-right: 4px;
  margin-top: 4px;
}

.reader-side-jump-list button {
  width: 100%;
  border: 3px solid #111;
  border-radius: 14px;
  background: #f4ecff;
  color: #111;
  padding: 10px 12px;
  font-family: inherit;
  font-size: 15px;
  font-weight: 900;
  text-align: left;
  cursor: pointer;
}

.reader-side-jump-list button:hover,
.reader-side-jump-list button.active {
  background: #9cffc8;
}

@media (max-width: 980px) {
  .reader-page-body {
    overflow: auto;
  }

  .reader-layout-wide {
    grid-template-columns: 1fr;
  }

  .reader-resource-side,
  .reader-resource-panel-right {
    max-height: none;
    overflow: visible;
  }

  .reader-resource-side {
    order: -1;
  }

  .pdf-pages {
    height: 72vh;
  }
}

/* v84: fixed reader scroll, sharper pages, separate jump panels */
.reader-main-compact {
  width: min(1240px, calc(100% - 24px));
  margin: 12px auto 0;
}

.reader-layout-wide {
  grid-template-columns: minmax(0, 900px) 310px;
  gap: 16px;
}

.reader-resource-side {
  top: 92px;
  gap: 14px;
  max-height: calc(100vh - 104px);
}

.reader-pdf-card {
  max-height: calc(100vh - 112px);
}

.reader-toolbar-clean {
  padding: 10px 16px;
  min-height: 54px;
}

.reader-toolbar-clean strong {
  font-size: clamp(24px, 2.3vw, 34px);
}

.pdf-pages {
  height: calc(100vh - 166px);
  min-height: 560px;
  overflow-y: auto;
  overflow-x: hidden;
  scroll-behavior: smooth;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  scrollbar-color: #825ead #e7e0ef;
}

.pdf-pages::-webkit-scrollbar,
.reader-side-jump-list::-webkit-scrollbar {
  width: 14px;
}

.pdf-pages::-webkit-scrollbar-track,
.reader-side-jump-list::-webkit-scrollbar-track {
  background: #e7e0ef;
  border-left: 3px solid #111;
}

.pdf-pages::-webkit-scrollbar-thumb,
.reader-side-jump-list::-webkit-scrollbar-thumb {
  background: #825ead;
  border: 3px solid #111;
  border-radius: 999px;
}

.pdf-pages::-webkit-scrollbar-thumb:hover,
.reader-side-jump-list::-webkit-scrollbar-thumb:hover {
  background: #6d4d96;
}

.pdf-page-wrap {
  scroll-margin-top: 0;
}

.pdf-page-canvas {
  image-rendering: auto;
}

.reader-resource-panel-right,
.reader-paragraph-panel {
  padding: 16px;
}

.reader-resource-panel-right {
  max-height: none;
  background: #fff3aa;
}

.reader-paragraph-panel {
  background: #fff;
}

.reader-resource-panel-right h2,
.reader-paragraph-panel h2 {
  margin: 0 0 8px;
  font-size: 25px;
  line-height: 1;
}

.reader-side-jump-list {
  max-height: 310px;
  overflow-y: auto;
  overflow-x: hidden;
  padding-right: 8px;
  scrollbar-width: thin;
  scrollbar-color: #825ead #e7e0ef;
}

.reader-side-jump-list button {
  border-radius: 16px;
  padding: 11px 12px;
  font-size: 15px;
}

@media (max-width: 980px) {
  .reader-main-compact {
    margin-top: 12px;
  }

  .reader-layout-wide {
    grid-template-columns: 1fr;
  }

  .reader-pdf-card {
    max-height: none;
  }

  .pdf-pages {
    height: 76vh;
    min-height: 520px;
  }

  .reader-side-jump-list {
    max-height: 260px;
  }
}

/* v86: taller reader, matched sidebar height, page-only fullscreen overlay */
.reader-page-body {
  overflow-x: hidden;
  overflow-y: auto;
}

.reader-main-compact {
  width: min(1280px, calc(100% - 44px));
  margin: 46px auto 42px;
}

.reader-layout-wide {
  grid-template-columns: minmax(0, 920px) 330px;
  gap: 30px;
  align-items: stretch;
}

.reader-content {
  min-height: 0;
}

.reader-resource-side {
  position: sticky;
  top: 112px;
  height: calc(88vh + 72px);
  min-height: 835px;
  max-height: 1020px;
  overflow: hidden;
  gap: 18px;
  display: flex;
  flex-direction: column;
}

.reader-back-small {
  flex: 0 0 auto;
}

.reader-pdf-card {
  max-height: none;
  overflow: hidden;
  border-radius: 28px;
  height: calc(88vh + 72px);
  min-height: 835px;
  max-height: 1020px;
  display: flex;
  flex-direction: column;
}

.reader-toolbar-clean {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  padding: 16px 18px;
  min-height: 72px;
  flex: 0 0 72px;
}

.reader-toolbar-clean strong {
  line-height: 1;
}

.reader-fullscreen-button {
  width: 42px;
  height: 42px;
  border: 3px solid #111;
  border-radius: 14px;
  background: #ffde59;
  color: #111;
  box-shadow: 3px 3px 0 #111;
  font-family: inherit;
  font-size: 24px;
  font-weight: 1000;
  line-height: 1;
  display: grid;
  place-items: center;
  cursor: pointer;
  flex: 0 0 auto;
}

.reader-fullscreen-button:hover {
  transform: translate(-1px, -1px);
  box-shadow: 4px 4px 0 #111;
}

.pdf-pages {
  flex: 1 1 auto;
  height: auto;
  min-height: 0;
  max-height: none;
  overflow-y: auto;
  overflow-x: hidden;
  overscroll-behavior: contain;
  touch-action: pan-y;
  background: #fff;
  padding: 0;
  scroll-snap-type: y proximity;
  scroll-padding-top: 0;
}

.pdf-page-wrap {
  margin: 0;
  padding: 0 0 5px;
  border: 0;
  box-shadow: none;
  background: linear-gradient(to bottom, #fff calc(100% - 5px), #111 calc(100% - 5px), #111 calc(100% - 2px), #e7e0ef calc(100% - 2px));
  scroll-snap-align: start;
}

.pdf-page-canvas {
  display: block;
  width: 100% !important;
  max-width: 100%;
  height: auto !important;
  margin: 0 auto;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  image-rendering: auto;
}

.reader-side-panel {
  border-radius: 24px;
  box-shadow: 6px 6px 0 #111;
}

.reader-resource-panel-right,
.reader-paragraph-panel {
  padding: 18px;
}

.reader-resource-panel-right {
  flex: 0 0 auto;
}

.reader-paragraph-panel {
  flex: 1 1 auto;
  min-height: 0;
  display: flex;
  flex-direction: column;
  background: linear-gradient(180deg, rgba(255, 222, 89, .92), rgba(231, 224, 239, .96));
}

.reader-paragraph-panel h2 {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: fit-content;
  padding: 8px 14px;
  margin-bottom: 12px;
  border: 3px solid #111;
  border-radius: 999px;
  background: #fff;
  box-shadow: 3px 3px 0 #111;
}

.reader-side-jump-list {
  flex: 1 1 auto;
  max-height: none;
  min-height: 0;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 4px 10px 4px 2px;
  display: grid;
  gap: 10px;
}

.reader-side-jump-list button {
  text-align: left;
  padding: 13px 14px;
  border-radius: 18px;
  background: #fff;
  box-shadow: 3px 3px 0 #111;
}

.reader-side-jump-list button::before {
  content: "↳";
  margin-right: 8px;
  font-weight: 1000;
  color: #825ead;
}

.reader-side-jump-list button:hover,
.reader-side-jump-list button.active {
  background: #cbb7ff;
  transform: translate(-1px, -1px);
  box-shadow: 4px 4px 0 #111;
}

.pdf-pages,
.reader-side-jump-list {
  scrollbar-width: thin;
  scrollbar-color: #825ead #e7e0ef;
}

.pdf-pages::-webkit-scrollbar,
.reader-side-jump-list::-webkit-scrollbar {
  width: 14px;
}

.pdf-pages::-webkit-scrollbar-track,
.reader-side-jump-list::-webkit-scrollbar-track {
  background: #e7e0ef;
  border-left: 3px solid #111;
}

.pdf-pages::-webkit-scrollbar-thumb,
.reader-side-jump-list::-webkit-scrollbar-thumb {
  background: #825ead;
  border: 3px solid #111;
  border-radius: 999px;
  min-height: 54px;
}

.pdf-pages::-webkit-scrollbar-thumb:hover,
.reader-side-jump-list::-webkit-scrollbar-thumb:hover {
  background: #6d4d96;
}

.reader-vertical-full .pdf-pages {
  position: fixed;
  top: 0;
  bottom: 0;
  left: var(--reader-full-left);
  width: var(--reader-full-width);
  height: 100vh;
  z-index: 10000;
  background: #fff;
  box-shadow: 0 0 0 4px #111;
  border-radius: 0;
}

.reader-vertical-full .reader-fullscreen-button {
  background: #ff9db8;
}

@media (max-width: 980px) {
  .reader-main-compact {
    width: min(100% - 24px, 760px);
    margin-top: 28px;
  }

  .reader-layout-wide {
    grid-template-columns: 1fr;
    gap: 22px;
  }

  .reader-resource-side {
    position: static;
    order: -1;
    height: auto;
    min-height: 0;
    max-height: none;
    overflow: visible;
  }

  .reader-pdf-card {
    height: 88vh;
    min-height: 680px;
    max-height: none;
  }

  .reader-side-jump-list {
    max-height: 320px;
  }

  .reader-vertical-full .pdf-pages {
    left: 0;
    width: 100vw;
  }
}

/* v87: sidebar order + flatter jump panel + pressed buttons + fullscreen fix */
.reader-resource-side {
  gap: 18px;
}

.reader-paragraph-panel {
  order: 1;
  flex: 1 1 auto;
  background: #fff3aa;
}

.reader-resource-panel-right {
  order: 2;
  flex: 0 0 auto;
  background: #e7e0ef;
}

.reader-paragraph-panel h2 {
  display: block;
  width: auto;
  padding: 0;
  margin: 0 0 14px;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.reader-side-jump-list button::before {
  content: none;
}

.reader-fullscreen-button,
.reader-jump-button,
.reader-side-jump-list button,
.reader-back-small {
  transition: transform 0.12s ease, box-shadow 0.12s ease, background 0.12s ease;
}

.reader-fullscreen-button:hover,
.reader-jump-button:hover,
.reader-side-jump-list button:hover,
.reader-back-small:hover {
  transform: translate(3px, 3px);
  box-shadow: 1px 1px 0 #111;
}

.reader-fullscreen-button:active,
.reader-jump-button:active,
.reader-side-jump-list button:active,
.reader-back-small:active {
  transform: translate(5px, 5px);
  box-shadow: 0 0 0 #111;
}

.reader-side-jump-list button:hover,
.reader-side-jump-list button.active {
  background: #cbb7ff;
}

.reader-vertical-full .pdf-pages {
  z-index: 999999 !important;
  top: 0 !important;
  bottom: 0 !important;
  height: 100vh !important;
  background: #fff !important;
  isolation: isolate;
}

.reader-vertical-full .pdf-page-wrap,
.reader-vertical-full .pdf-page-canvas {
  background-color: #fff !important;
}

/* v88: true fullscreen stacking + softer Of ga naar buttons */
.reader-vertical-full .topbar {
  z-index: 1 !important;
  pointer-events: none;
}

.reader-vertical-full .reader-pdf-card,
.reader-vertical-full .reader-content,
.reader-vertical-full .reader-layout-wide,
.reader-vertical-full .reader-main-compact {
  overflow: visible !important;
  z-index: auto !important;
}

.reader-vertical-full .pdf-pages {
  position: fixed !important;
  top: 0 !important;
  bottom: 0 !important;
  left: var(--reader-full-left) !important;
  width: var(--reader-full-width) !important;
  height: 100vh !important;
  z-index: 2147483000 !important;
  background: #fff !important;
  box-shadow: 0 0 0 4px #111 !important;
  border-radius: 0 !important;
  transform: translateZ(0);
}

.reader-resource-panel-right .reader-jump-button {
  box-shadow: 4px 4px 0 #111;
  transform: translate(0, 0);
}

.reader-resource-panel-right .reader-jump-button:hover {
  transform: translate(2px, 2px);
  box-shadow: 2px 2px 0 #111;
  filter: brightness(0.98);
}

.reader-resource-panel-right .reader-jump-button:active {
  transform: translate(4px, 4px);
  box-shadow: 0 0 0 #111;
}


/* v89: WebP image reader + centered buttons + paragraph checkmarks */
button,
a.button-like,
.reader-jump-button,
.reader-side-jump-list button,
.reader-back-small,
.level-option,
.chapter-card {
  text-align: center;
}

.reader-side-jump-list button,
.reader-jump-button,
.reader-back-small,
.reader-fullscreen-button,
.level-option {
  display: flex;
  align-items: center;
  justify-content: center;
}

.reader-side-jump-list button {
  position: relative;
  min-height: 54px;
  padding: 12px 54px 12px 18px;
  background: #fff;
  color: #111;
  font-weight: 950;
  line-height: 1.1;
}

.reader-side-jump-list button::after {
  content: "";
  position: absolute;
  right: 13px;
  top: 50%;
  width: 28px;
  height: 28px;
  transform: translateY(-50%);
  background: transparent url("https://cdn.meneercengiz.nl/images/checkmark.png") center / 100% 100% no-repeat;
  filter: drop-shadow(2px 2px 0 rgba(0,0,0,.22));
  pointer-events: none;
}

.reader-side-jump-list button.active {
  background: #9fe870;
}

.pdf-page-canvas {
  display: none;
}

.pdf-page-image {
  display: block;
  width: 100%;
  height: auto;
  margin: 0 auto;
  border: 0;
  border-radius: 0;
  box-shadow: none;
  background: #fff;
}

.image-page-wrap {
  line-height: 0;
}

.reader-vertical-full .pdf-pages {
  z-index: 2147483000 !important;
}

.reader-vertical-full .topbar {
  z-index: 1 !important;
  pointer-events: none !important;
}

/* v90: image reader starts at page-000 + paragraph cards use chapter checkmarks exactly */
.reader-side-jump-list.paragraph-list {
  display: grid;
  gap: 10px;
}

.reader-side-jump-list.paragraph-list button::after {
  display: none !important;
  content: none !important;
}

.paragraph-card {
  position: relative;
  min-height: 58px;
  padding: 12px 56px 12px 16px;
  border: 3px solid #111;
  border-radius: 18px;
  background: #fff;
  box-shadow: 4px 4px 0 #111;
  color: #111;
  cursor: pointer;
  transition: transform 0.15s, box-shadow 0.15s, background 0.15s;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.paragraph-card:hover {
  transform: translate(3px, 3px);
  box-shadow: 1px 1px 0 #111;
}

.paragraph-card span {
  display: block;
  font-size: 18px;
  line-height: 1.05;
  font-weight: 900;
}

.paragraph-card.active {
  background: #efe7ff;
}

.paragraph-card.done {
  background: #9fe870;
}

.paragraph-check.chapter-check {
  position: absolute !important;
  top: 50% !important;
  right: 12px !important;
  width: 30px !important;
  height: 30px !important;
  min-width: 30px !important;
  min-height: 30px !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 50% !important;
  background: transparent url("https://cdn.meneercengiz.nl/images/checkmark.png") center / 100% 100% no-repeat !important;
  opacity: 0.25;
  box-shadow: 3px 3px 0 rgba(0,0,0,0.24) !important;
  transform: translateY(-50%) !important;
  cursor: pointer;
  transition: transform 0.15s, box-shadow 0.15s, filter 0.15s, opacity 0.15s;
}

.paragraph-check.chapter-check.done {
  background: transparent url("https://cdn.meneercengiz.nl/images/checkmark.png") center / 100% 100% no-repeat !important;
  opacity: 1;
}

.paragraph-check.chapter-check:hover {
  transform: translate(2px, calc(-50% + 2px)) !important;
  box-shadow: 1px 1px 0 rgba(0,0,0,0.32) !important;
  filter: brightness(1.03);
  opacity: 0.55;
}

.paragraph-check.chapter-check.done:hover {
  opacity: 1;
}

/* v91: load all WebP pages and make paragraph checks use the exact boeken-page checkmark behavior */
.paragraph-check.chapter-check {
  width: 30px !important;
  height: 30px !important;
  min-width: 30px !important;
  min-height: 30px !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent url("https://cdn.meneercengiz.nl/images/checkmark.png") center / 100% 100% no-repeat !important;
  opacity: 0.25 !important;
  box-shadow: 3px 3px 0 rgba(0,0,0,0.24) !important;
}

.paragraph-check.chapter-check.done {
  background: transparent url("https://cdn.meneercengiz.nl/images/checkmark.png") center / 100% 100% no-repeat !important;
  opacity: 1 !important;
}

.paragraph-check.chapter-check:hover {
  opacity: 0.55 !important;
  filter: none !important;
}

.paragraph-check.chapter-check.done:hover {
  opacity: 1 !important;
}


/* v92: static topbar + content width aligned to topbar */
.topbar {
  position: relative !important;
  top: auto !important;
}

main,
.reader-main,
.reader-main-compact,
.boeken-main {
  width: min(1120px, calc(100% - 32px)) !important;
}

.reader-main-compact {
  margin-left: auto !important;
  margin-right: auto !important;
}

.reader-layout-wide {
  grid-template-columns: minmax(0, 780px) 308px !important;
  justify-content: center;
}

.reader-pdf-card,
.reader-resource-side {
  height: calc(88vh + 72px);
}

@media (max-width: 980px) {
  .reader-main-compact,
  .reader-main,
  .boeken-main,
  main {
    width: min(100% - 24px, 760px) !important;
  }

  .reader-layout-wide {
    grid-template-columns: 1fr !important;
  }
}

/* v93: paragraph labels, circular checks, no page snapping */
.pdf-pages,
.reader-pdf-pages,
#pdfPages {
  scroll-snap-type: none !important;
  scroll-padding-top: 0 !important;
}

.pdf-page-wrap,
.image-page-wrap {
  scroll-snap-align: none !important;
}

.paragraph-card {
  justify-content: center !important;
  text-align: center !important;
}

.paragraph-card span {
  width: 100%;
  text-align: center !important;
}

.paragraph-check.chapter-check {
  width: 32px !important;
  height: 32px !important;
  min-width: 32px !important;
  min-height: 32px !important;
  padding: 0 !important;
  border: 3px solid #111 !important;
  border-radius: 50% !important;
  background-color: #fff !important;
  background-image: url("https://cdn.meneercengiz.nl/images/checkmark.png") !important;
  background-position: center !important;
  background-size: 115% 115% !important;
  background-repeat: no-repeat !important;
  opacity: 1 !important;
  box-shadow: 2px 2px 0 #111 !important;
  overflow: hidden !important;
}

.paragraph-check.chapter-check:not(.done) {
  filter: grayscale(1) opacity(0.32) !important;
}

.paragraph-check.chapter-check.done {
  background-color: #fff !important;
  background-image: url("https://cdn.meneercengiz.nl/images/checkmark.png") !important;
  opacity: 1 !important;
  filter: none !important;
}

.paragraph-check.chapter-check:hover {
  transform: translate(2px, calc(-50% + 2px)) !important;
  box-shadow: 0 0 0 #111 !important;
  opacity: 1 !important;
}

/* v94: paragraph checkmarks use the exact boeken-page chapter-check styling */
.paragraph-card {
  position: relative !important;
  padding-right: 58px !important;
}

.paragraph-check.chapter-check {
  position: absolute !important;
  top: 50% !important;
  right: 12px !important;
  width: 32px !important;
  height: 32px !important;
  min-width: 0 !important;
  min-height: 0 !important;
  padding: 0 !important;
  border: 0 !important;
  border-radius: 50% !important;
  background-color: transparent !important;
  background-image: url("https://cdn.meneercengiz.nl/images/checkmark.png") !important;
  background-position: center !important;
  background-size: 115% 115% !important;
  background-repeat: no-repeat !important;
  box-shadow: 3px 3px 0 rgba(0,0,0,0.28) !important;
  transform: translateY(-50%) !important;
  cursor: pointer !important;
  transition: transform 0.15s, box-shadow 0.15s, filter 0.15s !important;
  opacity: 1 !important;
  overflow: visible !important;
  filter: none !important;
}

.paragraph-check.chapter-check:hover,
.paragraph-check.chapter-check.done:hover {
  transform: translate(2px, calc(-50% + 2px)) !important;
  box-shadow: 1px 1px 0 rgba(0,0,0,0.32) !important;
  filter: brightness(1.03) !important;
}

.paragraph-check.chapter-check.done,
.paragraph-check.chapter-check:not(.done) {
  background-color: transparent !important;
  background-image: url("https://cdn.meneercengiz.nl/images/checkmark.png") !important;
  background-position: center !important;
  background-size: 115% 115% !important;
  background-repeat: no-repeat !important;
  filter: none !important;
  opacity: 1 !important;
}

.paragraph-check.chapter-check.done::before,
.paragraph-check.chapter-check.done::after,
.paragraph-check.chapter-check::before,
.paragraph-check.chapter-check::after,
.paragraph-check.chapter-check .check-circle {
  display: none !important;
  content: none !important;
}

/* v97: reader clipping, fullscreen hit testing, paragraph offsets, calculator persistence */
.reader-layout-wide,
.reader-resource-side,
.reader-side-panel {
  overflow: visible !important;
}

.reader-resource-side {
  padding-right: 10px !important;
  margin-right: -10px !important;
}

.reader-paragraph-panel,
.reader-resource-panel-right,
.reader-back-small {
  transform: translateZ(0);
}

.paragraph-check.chapter-check:not(.done) {
  opacity: 0.25 !important;
  filter: none !important;
}

.paragraph-check.chapter-check:not(.done):hover {
  opacity: 0.55 !important;
}

.paragraph-check.chapter-check.done {
  opacity: 1 !important;
}

.reader-vertical-full .topbar {
  z-index: 1000 !important;
  pointer-events: auto !important;
}

.reader-vertical-full .pdf-pages {
  z-index: 2147483000 !important;
}

.reader-vertical-full .reader-fullscreen-button {
  position: relative;
  z-index: 2147483001 !important;
}


/* v98: CDN assets, smoother page navigation, fullscreen click-through, and reader offset fixes */
@view-transition {
  navigation: auto;
}

::view-transition-old(root),
::view-transition-new(root) {
  animation-duration: 0.16s;
}

.reader-vertical-full .pdf-pages {
  pointer-events: auto !important;
}

.reader-vertical-full .topbar {
  pointer-events: auto !important;
}

.paragraph-check.chapter-check:not(.done) {
  opacity: 0.25 !important;
}

.paragraph-check.chapter-check:not(.done):hover {
  opacity: 0.55 !important;
}

/* v99: reader reset-friendly scrollbars */
.pdf-pages,
.reader-side-jump-list {
  scrollbar-width: thin;
  scrollbar-color: #825ead transparent;
}

.pdf-pages::-webkit-scrollbar,
.reader-side-jump-list::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

.pdf-pages::-webkit-scrollbar-button,
.reader-side-jump-list::-webkit-scrollbar-button {
  display: none;
  width: 0;
  height: 0;
}

.pdf-pages::-webkit-scrollbar-track,
.reader-side-jump-list::-webkit-scrollbar-track {
  background: transparent;
  border: 0;
}

.pdf-pages::-webkit-scrollbar-thumb,
.reader-side-jump-list::-webkit-scrollbar-thumb {
  background: #825ead;
  border: 0;
  border-radius: 0;
  min-height: 44px;
}

.pdf-pages::-webkit-scrollbar-thumb:hover,
.reader-side-jump-list::-webkit-scrollbar-thumb:hover {
  background: #6d4d96;
}

.pdf-pages::-webkit-scrollbar-corner,
.reader-side-jump-list::-webkit-scrollbar-corner {
  background: transparent;
}


/* v100: prevent font flash, true thin scrollbars, and smoother normal navigation */
html.fonts-loading body {
  opacity: 0;
}

body {
  opacity: 1;
  transition: opacity 0.08s linear;
}

::view-transition-old(root),
::view-transition-new(root) {
  animation: none !important;
}

.pdf-pages,
.reader-side-jump-list {
  scrollbar-width: thin !important;
  scrollbar-color: #825ead transparent !important;
}

.pdf-pages::-webkit-scrollbar,
.reader-side-jump-list::-webkit-scrollbar {
  width: 10px !important;
  height: 10px !important;
  background: transparent !important;
}

.pdf-pages::-webkit-scrollbar-button,
.pdf-pages::-webkit-scrollbar-button:single-button,
.pdf-pages::-webkit-scrollbar-button:vertical:start:decrement,
.pdf-pages::-webkit-scrollbar-button:vertical:end:increment,
.reader-side-jump-list::-webkit-scrollbar-button,
.reader-side-jump-list::-webkit-scrollbar-button:single-button,
.reader-side-jump-list::-webkit-scrollbar-button:vertical:start:decrement,
.reader-side-jump-list::-webkit-scrollbar-button:vertical:end:increment {
  width: 0 !important;
  height: 0 !important;
  display: none !important;
  background: transparent !important;
  border: 0 !important;
}

.pdf-pages::-webkit-scrollbar-track,
.reader-side-jump-list::-webkit-scrollbar-track {
  background: linear-gradient(to right, transparent 0 4px, #e7e0ef 4px 6px, transparent 6px 10px) !important;
  border: 0 !important;
  border-radius: 0 !important;
  box-shadow: none !important;
}

.pdf-pages::-webkit-scrollbar-track-piece,
.reader-side-jump-list::-webkit-scrollbar-track-piece {
  background: linear-gradient(to right, transparent 0 4px, #e7e0ef 4px 6px, transparent 6px 10px) !important;
  border: 0 !important;
}

.pdf-pages::-webkit-scrollbar-thumb,
.reader-side-jump-list::-webkit-scrollbar-thumb {
  background: #825ead !important;
  border: 0 !important;
  border-radius: 999px !important;
  min-height: 54px !important;
  box-shadow: none !important;
}

.pdf-pages::-webkit-scrollbar-thumb:hover,
.reader-side-jump-list::-webkit-scrollbar-thumb:hover {
  background: #6d4d96 !important;
}

.pdf-pages::-webkit-scrollbar-corner,
.reader-side-jump-list::-webkit-scrollbar-corner {
  background: transparent !important;
}

.image-page-wrap {
  background: #fff;
  min-height: min(86vh, 1050px);
}

.image-page-wrap.image-loaded {
  min-height: 0;
}

/* v101: stable image heights, one-click paragraph jumps, and cleaner HAVO list */
.pdf-pages,
.reader-pdf-pages,
#pdfPages {
  scroll-snap-type: none !important;
  scroll-behavior: auto;
}

.pdf-page-wrap,
.image-page-wrap {
  position: relative !important;
  width: 100% !important;
  aspect-ratio: 0.7071 / 1 !important;
  min-height: 0 !important;
  height: auto !important;
  margin: 0 !important;
  padding: 0 0 6px 0 !important;
  box-sizing: content-box !important;
  background: #fff !important;
  scroll-snap-align: none !important;
}

.pdf-page-wrap::after,
.image-page-wrap::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: 1px;
  height: 3px;
  background: #111;
  opacity: 0.18;
  pointer-events: none;
}

.pdf-page-image {
  width: 100% !important;
  height: 100% !important;
  object-fit: contain !important;
  display: block !important;
  background: #fff !important;
}

.image-page-wrap.image-loaded {
  min-height: 0 !important;
}

.paragraph-card[hidden] {
  display: none !important;
}

.paragraph-card span {
  display: -webkit-box !important;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  max-height: 2.25em;
  line-height: 1.12 !important;
}


/* v102: keep first-click paragraph accuracy but restore visible smooth scrolling */
.pdf-pages,
.reader-pdf-pages,
#pdfPages {
  scroll-behavior: smooth !important;
}

/* v103: keep removed chapter slots invisible without resizing the chapter grids */
.chapter-card.chapter-placeholder {
  visibility: hidden !important;
  pointer-events: none !important;
}

.chapter-card.chapter-placeholder .chapter-check {
  pointer-events: none !important;
}


/* v89: chapter cards have a fixed two-line height and clamp long names */
.chapter-card {
  min-height: 78px;
  height: 78px;
  box-sizing: border-box;
}

.chapter-card span {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.08;
  max-height: 2.16em;
}

.chapter-card.chapter-placeholder {
  height: 78px;
}


/* v90: left-align numbered chapter and paragraph cards while keeping checkmarks fixed */
.chapter-card {
  justify-content: flex-start !important;
  text-align: left !important;
}

.chapter-card span {
  width: 100% !important;
  text-align: left !important;
}

.paragraph-card {
  justify-content: flex-start !important;
  text-align: left !important;
}

.paragraph-card span {
  width: 100% !important;
  text-align: left !important;
}

/* v88: reader resource links can be anchors and should look exactly like the reader buttons */
.reader-jump-button.reader-resource-link {
  display: block;
}

/* Uitwerkingen overview: related to Boeken, but clearly secondary */
.book-stack .book {
  color: #111;
  text-decoration: none;
}

.uitwerkingen-overview-body .nav-active {
  background: #111;
  color: white !important;
}

.uitwerkingen-main {
  margin-top: 28px;
}

.uitwerkingen-compact-hero {
  grid-template-columns: minmax(0, 1fr) auto;
  background: #dce8ff;
  padding-top: 24px;
  padding-bottom: 24px;
}

.uitwerkingen-compact-hero h1 {
  max-width: 760px;
  font-size: clamp(30px, 4.2vw, 48px);
}

.uitwerkingen-mini-label {
  background: #8067ff;
  color: white !important;
}

.uitwerkingen-secondary-link {
  align-self: center;
  display: inline-block;
  padding: 12px 16px;
  border: 4px solid #111;
  border-radius: 18px;
  background: white;
  box-shadow: 5px 5px 0 #111;
  color: #111;
  font-size: 17px;
  font-weight: 900;
  text-decoration: none;
  white-space: nowrap;
}

.uitwerkingen-secondary-link:hover {
  transform: translate(4px, 4px);
  box-shadow: 1px 1px 0 #111;
}

.uitwerkingen-page-grid {
  grid-template-columns: minmax(0, 1fr) 300px;
}

.uitwerkingen-chapters-panel {
  background: rgba(255,255,255,0.9);
}

.uitwerkingen-chapters-panel .boeken-panel-header h2 {
  font-size: 38px;
}

.uitwerkingen-deel-one {
  background: #d8ccff;
}

.uitwerkingen-deel-two {
  background: #c8f4ff;
}

.uitwerkingen-side-panel {
  background: #fff3aa;
}

.resource-button.purple-r {
  background: #cbb7ff;
}

/* Uitwerkingen reader: same reader system, different accent */
.uitwerkingen-page-body .reader-pdf-card {
  border-color: #111;
  background: #f7f9ff;
}

.uitwerkingen-page-body .pdf-toolbar {
  background: #8067ff;
  color: white;
}

.uitwerkingen-page-body .reader-side-panel {
  background: #dce8ff;
}

.uitwerkingen-page-body .reader-paragraph-panel h2::after {
  content: "";
}

.uitwerkingen-page-body .paragraph-card.active,
.uitwerkingen-page-body .paragraph-card:hover {
  background: #fff3aa;
}

.uitwerkingen-page-body .pdf-missing-note {
  background: #dce8ff;
  font-size: 14px;
}

@media (max-width: 920px) {
  .uitwerkingen-compact-hero,
  .uitwerkingen-page-grid {
    grid-template-columns: 1fr;
  }

  .uitwerkingen-secondary-link {
    justify-self: start;
  }
}
