/* Homepage chapters (1 Dec 2026), switched on only with ?chapters=1 (assets/chapters.js; ?chapters=0 switches it off): a full-screen cover for "To stay" and
   "The setting", and a thin number rail (01 to 04) at the left edge. The page below each cover is the existing section, unchanged. */
.ch-cover, .ch-rail { display: none; }
html.chapters .ch-cover { display: flex; align-items: flex-end; position: relative; min-height: 62svh; overflow: hidden; background: #14110e; color: #fff; scroll-margin-top: -80px; }
.ch-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.ch-shade { position: absolute; inset: 0; background: linear-gradient(to bottom, rgba(14, 11, 9, 0.58), rgba(14, 11, 9, 0) 30%), linear-gradient(to top, rgba(14, 11, 9, 0.9), rgba(14, 11, 9, 0.62) 38%, rgba(14, 11, 9, 0.08) 68%, rgba(14, 11, 9, 0.12)); }
.ch-txt { position: relative; width: 100%; box-sizing: border-box; padding: 110px 70px 30px 38px; text-shadow: 0 1px 10px rgba(0, 0, 0, 0.45); }
.ch-txt > * { max-width: 480px; }
html.chapters #ch2 { min-height: 78svh; }
html.chapters #ch5 { min-height: 56svh; }
/* these two photos have a bright window in the middle: the text sits on a darker foot */
#ch2 .ch-shade, #ch5 .ch-shade { background: linear-gradient(to bottom, rgba(14, 11, 9, 0.5), rgba(14, 11, 9, 0) 28%), linear-gradient(to top, rgba(14, 11, 9, 0.94) 0%, rgba(14, 11, 9, 0.8) 42%, rgba(14, 11, 9, 0.08) 58%); }
.ch-n { margin: 0; color: #fff; font-family: var(--font); font-size: 10px; font-weight: var(--w-med); letter-spacing: 0.22em; text-transform: uppercase; opacity: 0.9; }
.ch-h { margin: 10px 0 12px; font-family: var(--font); font-size: 28px; font-weight: 200; line-height: 1.12; color: #fff; text-wrap: balance; }
.ch-p { margin: 0 0 16px; font-family: var(--font); font-size: 13px; font-weight: var(--w-reg, 400); line-height: 1.6; color: #fff; opacity: 0.92; }
.ch-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.ch-chips a {
  display: inline-flex; align-items: center; min-height: 44px; padding: 0 16px; border-radius: 999px; text-decoration: none; white-space: nowrap;
  background: var(--glass-photo-tint); border: 1px solid var(--glass-photo-edge); color: var(--glass-photo-ink);
  -webkit-backdrop-filter: blur(var(--glass-blur)) saturate(1.4); backdrop-filter: blur(var(--glass-blur)) saturate(1.4);
  font-family: var(--font); font-size: 10px; font-weight: var(--w-med); letter-spacing: 0.16em; text-transform: uppercase;
}
.ch-chips a:hover { background: var(--glass-photo-edge); }
.ch-chips a:focus-visible, .ch-rail a:focus-visible { outline: 2px solid var(--sage-lt); outline-offset: 3px; }
.ch-facts { display: flex; flex-wrap: wrap; gap: 8px 18px; margin: 4px 0 0; padding: 0; list-style: none; }
.ch-facts li { font-family: var(--font); font-size: 11px; font-weight: var(--w-reg, 400); letter-spacing: 0.04em; }
.ch-facts b { display: block; font-size: 21px; font-weight: 200; line-height: 1.1; letter-spacing: -0.01em; }

.ch-go { margin: 16px 0 0; }
.ch-go a { color: #fff; text-decoration: none; font-family: var(--font); font-size: 10px; font-weight: var(--w-med); letter-spacing: 0.2em; text-transform: uppercase; opacity: 0.85; }

/* over a cover the header loses its glass bar: the name, the menu button and the rest go white on the photo, and the bar returns when the cover is left */
html.chapters.ch-head-clear .nav.scrolled { background: transparent; -webkit-backdrop-filter: none; backdrop-filter: none; box-shadow: none; border-bottom-color: transparent; }
html.chapters.ch-head-clear nav#nav .nav-logo-img { filter: drop-shadow(0 0 5px rgba(37, 31, 28, 0.55)); opacity: 1; }   /* the logo is cream: the same as at the top of the page */
html.chapters.ch-head-clear nav#nav .ham { filter: brightness(0) invert(1); }
html.chapters.ch-head-clear nav#nav .lang-btn { color: #fff; }
html.chapters .nav, html.chapters .nav .nav-logo-img, html.chapters .nav .ham { transition: background-color 300ms ease, filter 300ms ease, box-shadow 300ms ease, border-color 300ms ease; }

/* a cover starts its slow zoom and lets its text rise when it is first seen (assets/chapters.js adds is-seen); with reduced motion nothing moves */
@media (prefers-reduced-motion: no-preference) {
  html.chapters .ch-cover .ch-txt { opacity: 0; transform: translateY(16px); transition: opacity 700ms ease 350ms, transform 700ms cubic-bezier(0.2, 0.7, 0.2, 1) 350ms; }
  html.chapters .ch-cover.is-seen .ch-txt { opacity: 1; transform: none; }
  html.chapters .ch-cover .ch-bg { transform: scale(1); }
  html.chapters .ch-cover.is-seen .ch-bg { transform: scale(1.08) translate(-1%, -0.6%); transition: transform 9s ease-out; will-change: transform; }
}

/* the window picture of the stay section is the cover now */
html.chapters #stay .stay-lead { display: none; }

/* the details below a cover keep their text for readers and search engines, but not the heading the cover already shows */
html.chapters #stay .sec-head .kicker, html.chapters #stay .sec-head h2, html.chapters #stay .sec-head .sec-sub,
html.chapters #setting .prose .kicker, html.chapters #setting .prose h2,
html.chapters #book .kicker, html.chapters #book h2, html.chapters #book .book-incentive {
  position: absolute; width: 1px; height: 1px; margin: -1px; padding: 0; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; border: 0;
}

/* the rail: white with a soft shadow over a photo, ink over the pale page (the script switches the class) */
html.chapters .ch-rail { display: flex; flex-direction: column; position: fixed; left: 2px; top: 50%; transform: translateY(-50%); z-index: 90; gap: 2px; color: #fff; transition: opacity 250ms ease, color 250ms ease; }
html.chapters .ch-rail.on-photo a { text-shadow: 0 1px 8px rgba(0, 0, 0, 0.6); }
html.chapters .ch-rail.on-light { color: var(--ink); }
html.chapters .ch-rail.is-off, html.chapters body.drawer-locked .ch-rail { opacity: 0; pointer-events: none; }
.ch-rail a { display: block; padding: 7px 5px; font-family: var(--font); font-size: 10px; font-weight: var(--w-med); letter-spacing: 0.12em; color: inherit; text-decoration: none; opacity: 0.55; line-height: 1; }
.ch-rail a.on { opacity: 1; }
.ch-rail a.on::after { content: ""; display: block; width: 12px; height: 1px; background: currentColor; margin-top: 4px; }
@media (min-width: 900px) {
  html.chapters .ch-cover { min-height: 72svh; }
  html.chapters #ch2 { min-height: 80svh; }
  html.chapters #ch5 { min-height: 60svh; }
  .ch-txt { padding: 140px 70px 56px 86px; }
  html.chapters .ch-rail { left: 22px; }
  .ch-shade, #ch2 .ch-shade, #ch5 .ch-shade { background: linear-gradient(to right, rgba(14, 11, 9, 0.8), rgba(14, 11, 9, 0.05) 62%); }
}
@media (prefers-reduced-motion: reduce) { html.chapters .ch-rail { transition: none; } }

/* soft edges: 110 px strips above and below each cover; the colours (--ch-a, --ch-b) are the neighbouring sections' backgrounds, set by assets/chapters.js */
/* "Verblijven" in the dock jumps to #stay: the cards start right under the 80 px scroll padding, which is less than the phone header (99 px), so the first card's badge sat behind it; 40 px more lands the cards clear of the header */
@media (max-width: 768px) { #stay { scroll-margin-top: 40px; } }
/* cover 2 melts into the page above and below (owner's choice D, 2 Dec 2026): a 200 px cosine gradient in the neighbouring sections' colours over the cover's dark top and foot; the text starts below the top gradient and ends above the bottom one, so it stays readable */
html.chapters #ch2::before, html.chapters #ch2::after { content: ""; position: absolute; left: 0; right: 0; height: 200px; z-index: 1; pointer-events: none; }
html.chapters #ch2::before { top: 0; background: linear-gradient(to bottom, color-mix(in srgb, var(--ch-a) 100.0%, transparent) 0.0%, color-mix(in srgb, var(--ch-a) 98.3%, transparent) 8.3%, color-mix(in srgb, var(--ch-a) 93.3%, transparent) 16.7%, color-mix(in srgb, var(--ch-a) 85.4%, transparent) 25.0%, color-mix(in srgb, var(--ch-a) 75.0%, transparent) 33.3%, color-mix(in srgb, var(--ch-a) 62.9%, transparent) 41.7%, color-mix(in srgb, var(--ch-a) 50.0%, transparent) 50.0%, color-mix(in srgb, var(--ch-a) 37.1%, transparent) 58.3%, color-mix(in srgb, var(--ch-a) 25.0%, transparent) 66.7%, color-mix(in srgb, var(--ch-a) 14.6%, transparent) 75.0%, color-mix(in srgb, var(--ch-a) 6.7%, transparent) 83.3%, color-mix(in srgb, var(--ch-a) 1.7%, transparent) 91.7%, color-mix(in srgb, var(--ch-a) 0.0%, transparent) 100.0%); }
html.chapters #ch2::after { bottom: 0; background: linear-gradient(to top, color-mix(in srgb, var(--ch-b) 100.0%, transparent) 0.0%, color-mix(in srgb, var(--ch-b) 98.3%, transparent) 8.3%, color-mix(in srgb, var(--ch-b) 93.3%, transparent) 16.7%, color-mix(in srgb, var(--ch-b) 85.4%, transparent) 25.0%, color-mix(in srgb, var(--ch-b) 75.0%, transparent) 33.3%, color-mix(in srgb, var(--ch-b) 62.9%, transparent) 41.7%, color-mix(in srgb, var(--ch-b) 50.0%, transparent) 50.0%, color-mix(in srgb, var(--ch-b) 37.1%, transparent) 58.3%, color-mix(in srgb, var(--ch-b) 25.0%, transparent) 66.7%, color-mix(in srgb, var(--ch-b) 14.6%, transparent) 75.0%, color-mix(in srgb, var(--ch-b) 6.7%, transparent) 83.3%, color-mix(in srgb, var(--ch-b) 1.7%, transparent) 91.7%, color-mix(in srgb, var(--ch-b) 0.0%, transparent) 100.0%); }
html.chapters #ch2 .ch-txt { padding-top: 200px; padding-bottom: 160px; }
