/* School manual (/scholen/handleiding/). On screen one continuous page inside the site layout; printed (and as the
   PDF made by documentation/handleiding-scholen/pdf.mjs) one <section class="page"> per A4 page. Every rule is
   scoped to .manual, so it wins over Bootstrap and tkl-style.css. */
.manual {
  --orange: #fe5501;
  --navy: #0b1f44;
  --blue: #7fa6c8;
  --blue-dark: #4f7ea8;
  --blue-light: #e9f1f8;
  --green: #2e9d4f;
  --text: #1f2a37;
  --muted: #5b6776;
  font-family: 'Inter', 'Helvetica Neue', Arial, sans-serif; color: var(--text); line-height: 1.45;
  -webkit-print-color-adjust: exact; print-color-adjust: exact;
}
.manual * { box-sizing: border-box; }

.manual .page { position: relative; background: #fff; }

/* Band at the top of each printed page */
.manual .band { display: flex; align-items: center; gap: 5mm; margin: 0 -17mm 7mm; padding: 5mm 17mm; background: var(--blue); color: #fff; }
.manual .band img { width: 15mm; height: 15mm; border-radius: 3mm; }
.manual .band b { display: block; font-size: 15pt; font-weight: 700; }
.manual .band span { font-size: 11pt; }

.manual h1, .manual h2, .manual h3, .manual h4 { line-height: 1.2; padding: 0; }
.manual h2 { color: var(--navy); font-size: 19pt; font-weight: 800; margin: 0 0 3mm; letter-spacing: -0.01em; }
.manual h3 { color: var(--blue-dark); font-size: 12pt; font-weight: 700; margin: 5mm 0 1.5mm; }
.manual h4 { margin: 0 0 1.5mm; color: var(--navy); font-size: 11pt; font-weight: 700; }
.manual p { margin: 0 0 2.2mm; line-height: 1.45; }
.manual ul, .manual ol { margin: 0 0 2.5mm; padding-left: 5.5mm; }
.manual li { margin-bottom: 1.1mm; }
.manual .lead { font-size: 1.08em; font-weight: 400; color: var(--muted); margin-bottom: 4mm; }
.manual .small { font-size: 0.83em; color: var(--muted); }
.manual a:not(.btn) { color: var(--blue-dark); text-decoration: underline; text-underline-offset: 0.15em; }

/* Words as they appear on screen */
.manual .ui { font-weight: 600; color: var(--navy); background: var(--blue-light); padding: 0 1.2mm; border-radius: 1mm; white-space: nowrap; }
.manual td.ui { white-space: normal; background: none; padding: 1.5mm 3mm 1.5mm 0; }

.manual .two { display: grid; grid-template-columns: 1fr 1fr; gap: 6mm; align-items: start; margin-bottom: 2mm; }

.manual img { max-width: 100%; }
.manual img.shot { width: 100%; border: 0.3mm solid #cfd6df; border-radius: 2mm; box-shadow: 0 1mm 3mm rgba(11, 31, 68, 0.12); display: block; }
.manual img.shot.wide { margin: 1mm 0 3mm; max-height: 78mm; object-fit: cover; object-position: top left; }

.manual .panel { background: var(--blue-light); border-radius: 3mm; padding: 4mm; }
.manual .panel img.shot { margin-top: 2mm; max-height: 48mm; object-fit: cover; object-position: top left; }

.manual .tip { margin-top: 4mm; padding: 3mm 4mm; border-left: 1.5mm solid var(--orange); background: #fff4ee; border-radius: 0 2mm 2mm 0; }
.manual .tip b:first-child { display: block; color: var(--orange); margin-bottom: 0.8mm; }
.manual .tip.privacy { border-color: var(--green); background: #eef8f1; }
.manual .tip.privacy b:first-child { color: var(--green); }
.manual .tip.warn { border-color: #d4a017; background: #fdf7e3; }
.manual .tip.warn b:first-child { color: #9a7400; }
.manual ul.compact { margin: 1mm 0 0; }

.manual table.def { width: 100%; border-collapse: collapse; margin: 1mm 0 2mm; }
.manual table.def td { padding: 1.6mm 3mm 1.6mm 0; border-bottom: 0.25mm solid #e3e8ee; vertical-align: top; }
.manual table.def td:first-child { width: 37%; }

.manual .pill { display: inline-block; font-size: 0.83em; font-weight: 600; padding: 0.4mm 2.5mm; border-radius: 10mm; white-space: nowrap; }
.manual .pill.green { background: #d7f0de; color: #17652f; }
.manual .pill.yellow { background: #fbefc4; color: #7a5b00; }
.manual .pill.blue { background: #d4e3fb; color: #1f4f9c; }
.manual .pill.lightblue { background: #d9f2f8; color: #1a6b80; }
.manual .pill.grey { background: #eceff3; color: #4b5563; }

/* Cover */
.manual .cover { background: linear-gradient(180deg, var(--blue) 0 58%, #fff 58%); }
.manual .cover-top { color: #fff; }
.manual .cover-logo { width: 34mm; height: 34mm; border-radius: 6mm; box-shadow: 0 2mm 6mm rgba(0, 0, 0, 0.15); }
.manual .cover h1 { color: #fff; font-size: 34pt; font-weight: 800; margin: 8mm 0 1mm; letter-spacing: -0.02em; }
.manual .cover-sub { font-size: 18pt; font-weight: 600; margin: 0 0 4mm; }
.manual .cover-for { font-size: 11.5pt; max-width: 140mm; opacity: 0.95; }
.manual .cover-shots { display: grid; grid-template-columns: 1fr 1fr; gap: 6mm; margin-top: 12mm; }
.manual .cover-shots img { width: 100%; border-radius: 3mm; box-shadow: 0 2mm 6mm rgba(0, 0, 0, 0.18); border: 1.5mm solid #fff; }
.manual .cover-url { color: var(--muted); margin-top: 6mm; }

/* Table of contents; the PDF adds the page numbers */
.manual ol.toc { list-style: none; padding: 0; counter-reset: toc; margin: 4mm 0 6mm; }
.manual ol.toc li { counter-increment: toc; display: flex; align-items: baseline; gap: 2mm; padding: 1.35mm 0; border-bottom: 0.25mm dotted #c3ccd6; font-size: 11pt; margin: 0; }
.manual ol.toc li::before { content: counter(toc); width: 8mm; flex: none; color: var(--orange); font-weight: 700; }
.manual ol.toc li a { flex: 1; color: inherit; text-decoration: none; }

/* Quick start */
.manual ol.bigsteps { list-style: none; padding: 0; counter-reset: s; margin: 2mm 0 5mm; }
.manual ol.bigsteps li { counter-increment: s; position: relative; padding: 2.5mm 0 2.5mm 15mm; margin-bottom: 2mm; min-height: 12mm; }
.manual ol.bigsteps li::before { content: counter(s); position: absolute; left: 0; top: 1.5mm; width: 10mm; height: 10mm; border-radius: 50%; background: var(--orange); color: #fff; font-weight: 800; font-size: 13pt; display: flex; align-items: center; justify-content: center; }
.manual ol.bigsteps li b { display: block; color: var(--navy); font-size: 1.08em; }
.manual ol.bigsteps li i { color: var(--muted); }

.manual .checklist { background: var(--blue-light); border-radius: 3mm; padding: 4mm 5mm; margin-top: 4mm; }
.manual .checklist b { color: var(--navy); }
.manual .checklist ul { list-style: none; padding: 0; margin: 2mm 0 0; }
.manual .checklist li { padding-left: 7mm; position: relative; }
.manual .checklist li::before { content: ''; position: absolute; left: 0; top: 0.6mm; width: 3.6mm; height: 3.6mm; border: 0.5mm solid var(--blue-dark); border-radius: 0.8mm; background: #fff; }

/* Four steps */
.manual .steps4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 3mm; margin: 2mm 0 3mm; }
.manual .steps4 > div { background: var(--blue-light); border-radius: 3mm; padding: 3mm; font-size: 0.88em; }
.manual .steps4 span { display: inline-flex; width: 7mm; height: 7mm; border-radius: 50%; background: var(--navy); color: #fff; font-weight: 700; align-items: center; justify-content: center; margin-bottom: 1.5mm; }
.manual .steps4 b { display: block; color: var(--navy); font-size: 1.1em; margin-bottom: 1mm; }

/* App games */
.manual .games { display: grid; grid-template-columns: repeat(3, 1fr); gap: 4mm; margin: 2mm 0 3mm; }
.manual .games figure { margin: 0; }
.manual .games img { width: 100%; border-radius: 2mm; border: 0.3mm solid #cfd6df; }
.manual .games figcaption { font-size: 0.86em; margin-top: 1.2mm; line-height: 1.35; }
.manual .games figcaption b { display: block; color: var(--navy); font-size: 1.16em; }

/* FAQ */
.manual dl.faq { margin: 2mm 0; }
.manual dl.faq dt { font-weight: 700; color: var(--navy); margin-top: 3mm; }
.manual dl.faq dd { margin: 0.8mm 0 0; }
.manual .contact { margin-top: 6mm; background: var(--blue); color: #fff; border-radius: 3mm; padding: 5mm 6mm; }
.manual .contact h3 { color: #fff; margin-top: 0; }
.manual .contact .small { color: #eef4fa; }
.manual .contact a:not(.btn) { color: #fff; }

/* Footer with page number, printed only */
.manual .foot { position: absolute; left: 17mm; right: 17mm; bottom: 8mm; display: flex; justify-content: space-between; font-size: 8pt; color: var(--muted); border-top: 0.25mm solid #e3e8ee; padding-top: 2mm; }
.manual .foot::before { content: 'Talen leren met Emma · Handleiding voor scholen en organisaties'; }
.manual .foot::after { content: counter(page); font-weight: 700; color: var(--navy); }

/* ---------- Screen: one continuous page ---------- */
@media screen {
  .manual { max-width: 880px; margin: 0 auto; padding: 24px 0 48px; font-size: 12pt; }
  .manual .page { padding: 36px 40px; margin-bottom: 24px; border-radius: 12px; box-shadow: 0 1px 4px rgba(11, 31, 68, 0.08); scroll-margin-top: 90px; }
  .manual .band, .manual .foot { display: none; }
  .manual .cover { background: var(--blue); }
  .manual .cover h1 { margin-top: 20px; }
  .manual .cover-bottom { margin-top: 28px; }
  .manual .cover-bottom, .manual .cover-url { color: #fff; }
  .manual .cover .btn { margin-top: 8px !important; }
  .manual .cover-shots { margin-top: 28px; }
  .manual h2 { font-size: 22pt; }
  .manual h3 { font-size: 14pt; }

  @media (max-width: 767px) {
    .manual { padding-top: 8px; }
    .manual .page { padding: 24px 16px; border-radius: 0; margin-left: -12px; margin-right: -12px; }
    .manual .two, .manual .cover-shots { grid-template-columns: 1fr; }
    .manual .steps4, .manual .games { grid-template-columns: 1fr 1fr; }
    .manual .ui { white-space: normal; }
    .manual table.def td:first-child { width: 40%; }
    .manual .cover h1 { font-size: 24pt; }
    .manual .cover-sub { font-size: 14pt; }
  }
}

/* ---------- Print and PDF: A4 pages ---------- */
@media print {
  @page { size: A4; margin: 0; }
  body { background: #fff !important; font-size: 10.2pt !important; }
  body > header, body > footer, .navbar-spacer, nav.fixed-top, .breadcrumb, .crisp-client, .screen-only { display: none !important; }
  #content { max-width: none !important; padding: 0 !important; margin: 0 !important; }
  .manual { font-size: 10.2pt; counter-reset: page; }
  .manual .page { counter-increment: page; width: 210mm; height: 297mm; overflow: hidden; margin: 0; padding: 0 17mm 18mm; break-after: page; }
  .manual .cover { padding-top: 22mm; }
  .manual .cover-bottom { position: absolute; left: 17mm; right: 17mm; bottom: 22mm; font-size: 11pt; }
  .manual a:not(.btn) { color: inherit; text-decoration: none; }
}
