/* ═══════════════════════════════════════════════════════════════════
   IDLE HANDS · Brand Guideline microsite  (loads after styles.css)
   Palette spine: Condensed Milk + Idle Coffee (primary), Dark Cocoa +
   Blueberry Pie + Flat White (secondary), Honey/Blush/Light Blue (accents).
   ═══════════════════════════════════════════════════════════════════ */

:root {
  --coffee: #624c43;     /* Idle Coffee  — new primary brown   */
  --flatwhite: #f4f0f3;  /* Flat White   — secondary           */
  --bg-maxw: 1120px;
  --bg-ease: cubic-bezier(0.16, 1, 0.3, 1);
}

/* ── Proportional scaling ────────────────────────────────────────────
   The guideline is sized largely in rem, so the root font-size acts as
   a master zoom dial. Tie it to viewport width: at >=1440px it holds at
   the reference 16px (large desktops look exactly as they do now), and
   below that the whole page scales down as one unit instead of
   reflowing/condensing. This also neutralises most browser-zoom and
   laptop display-scaling differences within the band: a narrower
   effective viewport (zoomed in, or a cheaper laptop) just renders the
   same layout a little smaller, not broken up.
   16 / 1440 * 100 = 1.1111vw is the reference slope.                   */
html { font-size: clamp(10.5px, 1.1111vw, 16px); }
@media (max-width: 760px) {
  /* Phones restructure to a single column anyway; hold a readable floor. */
  html { font-size: clamp(14px, 3.9vw, 16px); }
}

/* reveal baseline: only pre-hide when JS is live (no-js removed in <head>) */
/* the cover is static: no entrance animation, so it never shows a half-built state */
html:not(.no-js) [data-reveal]:not(.bg-cover [data-reveal]) { opacity: 0; transform: translateY(24px); }

.bg { display: block; }
.bg section { position: relative; }

/* shared inner container */
.bg-wrap { max-width: var(--bg-maxw); margin: 0 auto; padding-inline: var(--gutter); }
.bg-wrap--narrow { max-width: 920px; }

/* ── chapter header (number + title) ───────────────────────────────── */
.bg-chap {
  position: relative;
  min-height: 100svh; max-width: var(--bg-maxw); margin: 0 auto; padding: clamp(80px, 12vh, 150px) var(--gutter);
  display: flex; flex-direction: column; justify-content: center; align-items: center; text-align: center;
}
/* Optty-style big outlined chapter number (replaces the small "Chapter NN" eyebrow) */
.bg-chap__big {
  position: absolute; top: 50%; left: 50%; transform: translate(-50%, -53%); z-index: 0; pointer-events: none;
  font-family: var(--sans); font-weight: 600; font-size: clamp(13rem, 34vw, 28rem); line-height: 1; letter-spacing: -0.04em;
  color: color-mix(in srgb, var(--bean) 8%, transparent);
  -webkit-text-stroke: 1.5px color-mix(in srgb, var(--bean) 22%, transparent);
}
.bg-chap > :not(.bg-chap__big) { position: relative; z-index: 1; }
.bg-chap__big ~ .bg-chap__num { display: none; }
.bg-chap__num {
  display: block; font-family: var(--mono); font-size: 0.8rem; font-weight: 500;
  letter-spacing: 0.34em; text-transform: uppercase; color: var(--dusk); margin-bottom: clamp(22px, 3.4vh, 38px);
}
.bg-chap__title {
  font-family: var(--serif); font-weight: 400; line-height: 0.94; letter-spacing: -0.022em;
  font-size: clamp(3rem, 9vw, 7rem);
}
.bg-chap__lead {
  margin: clamp(20px, 3vw, 34px) auto 0; max-width: 30ch; font-family: var(--serif);
  font-size: clamp(1.25rem, 2.4vw, 1.95rem); line-height: 1.28;
  color: color-mix(in srgb, var(--bean) 88%, transparent);
}
.bg-chap__lead--wide { max-width: 48ch; font-size: clamp(1.15rem, 1.9vw, 1.7rem); line-height: 1.34; }

/* centred section heading (e.g. Our Story) */
.bg-secthead { text-align: center; margin-bottom: clamp(26px, 4.5vh, 54px); }
.bg-secthead--left { text-align: left; }
.bg-secthead--left .bg-secthead__s { margin-left: 0; margin-right: auto; }
.bg-secthead--right { text-align: right; }
.bg-secthead--right .bg-secthead__s { margin-left: auto; margin-right: 0; }
.bg-copy--right { max-width: 62ch; margin-left: auto; margin-right: 0; text-align: right; }
.bg-secthead__t { font-family: var(--serif); font-weight: 400; font-size: clamp(2.2rem, 4.6vw, 3.6rem); letter-spacing: -0.02em; line-height: 1; color: var(--bean); }
.bg-secthead__s { font-family: var(--serif); font-size: clamp(1.15rem, 1.9vw, 1.55rem); line-height: 1.3; color: color-mix(in srgb, var(--bean) 64%, transparent); max-width: 36ch; margin: clamp(12px, 2vh, 18px) auto 0; }

/* Our Mission — statement over a frosted bean watermark */
.bg-mission {
  position: relative; max-width: var(--bg-maxw); margin: clamp(48px, 9vh, 110px) auto 0;
  padding: clamp(72px, 15vh, 170px) var(--gutter); display: grid; place-items: center; text-align: center; overflow: hidden;
}
.bg-mission__bean {
  position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); z-index: 0; pointer-events: none;
  width: clamp(340px, 44vw, 620px); height: auto; opacity: 0.2; filter: blur(7px) saturate(0.85);
  /* Fade the bean to transparent before it reaches the box edge, so the
     section's overflow:hidden can never produce a hard cut-off line,
     however short the box gets when the page is zoomed or narrow. */
  -webkit-mask: radial-gradient(closest-side, #000 52%, transparent 90%);
          mask: radial-gradient(closest-side, #000 52%, transparent 90%);
}
.bg-mission__inner { position: relative; z-index: 1; max-width: 48ch; }
.bg-mission__label { font-family: var(--serif); font-weight: 400; font-size: clamp(1.8rem, 3.6vw, 3.1rem); letter-spacing: -0.01em; line-height: 1; color: var(--bean); margin-bottom: clamp(18px, 3vh, 36px); }
.bg-mission__statement { font-family: var(--sans); font-weight: 500; font-size: clamp(1.2rem, 2.2vw, 1.85rem); line-height: 1.38; letter-spacing: -0.005em; color: color-mix(in srgb, var(--bean) 90%, transparent); }
.bg-rule { height: 1px; background: var(--hair); max-width: var(--bg-maxw); margin: 0 auto; }

/* Running footer (Optty-style): brand label + page-number pill, fixed on every screen */
.bg-foot {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 40; pointer-events: none;
  display: flex; justify-content: flex-end; align-items: center;
  padding: clamp(11px, 1.5vh, 17px) clamp(20px, 4vw, 52px);
}
.bg-foot__brand { font-family: var(--mono); font-size: 0.6rem; letter-spacing: 0.2em; text-transform: uppercase; color: color-mix(in srgb, var(--bean) 48%, transparent); }
.bg-foot__pg {
  display: inline-flex; align-items: baseline; gap: 0.4em;
  font-family: var(--sans); font-weight: 500; font-size: clamp(0.8rem, 0.95vw, 0.95rem); letter-spacing: 0.02em; color: var(--bean);
  font-variant-numeric: tabular-nums;
}
.bg-foot__pg b { font-weight: 500; }
.bg-foot__pg span { color: var(--muted); }
.bg-foot__pg span:not(:empty)::before { content: "/ "; }
@media (max-width: 700px) { .bg-foot__brand { display: none; } }

/* ════════ INTRODUCTION — full-page opener (PDF style) ════════ */
.bg-intro {
  min-height: 100svh; max-width: var(--bg-maxw); margin: 0 auto;
  display: flex; flex-direction: column; justify-content: center; align-items: center; text-align: center;
  padding: clamp(80px, 12vh, 150px) var(--gutter);
}
.bg-intro__num { font-family: var(--mono); font-size: 0.74rem; letter-spacing: 0.24em; text-transform: uppercase; color: var(--dusk); margin-bottom: clamp(16px, 2.2vh, 26px); }
.bg-intro__title { font-family: var(--serif); font-weight: 400; font-size: clamp(2.6rem, 6.5vw, 5.4rem); line-height: 0.96; letter-spacing: -0.025em; margin-bottom: clamp(30px, 5vh, 60px); }
.bg-intro__statement {
  font-family: var(--serif); font-weight: 400; font-size: clamp(1.55rem, 2.9vw, 2.5rem);
  line-height: 1.26; letter-spacing: -0.01em; color: color-mix(in srgb, var(--bean) 86%, transparent); max-width: 28ch;
}

/* body copy blocks */
.bg-copy { max-width: 74ch; margin-inline: auto; }
.bg-copy p { color: color-mix(in srgb, var(--bean) 82%, transparent); margin-bottom: 1.1em; font-size: clamp(1rem, 1.15vw, 1.12rem); line-height: 1.62; }
.bg-copy p:last-child { margin-bottom: 0; }
.bg-eyebrow {
  font-family: var(--sans); font-size: 0.72rem; font-weight: 600; letter-spacing: 0.22em;
  text-transform: uppercase; color: var(--dusk); margin-bottom: 14px;
}
.bg-sub { font-family: var(--serif); font-weight: 400; font-size: clamp(1.5rem, 3vw, 2.3rem); line-height: 1.06; letter-spacing: -0.015em; margin-bottom: 18px; }

/* page chrome (rail-logo, chapter nav, footer, scrollbar) is hidden on the cover so the
   colophon owns the right edge, then fades in once the cover is scrolled off — Contents
   follows immediately, so the nav loses nothing by waiting */
html:not(.no-js) .rail-logo,
html:not(.no-js) .bg-nav,
html:not(.no-js) .bg-nav--white,
html:not(.no-js) .bg-foot,
html:not(.no-js) .scrollbar { opacity: 0; pointer-events: none; transition: opacity 0.55s var(--bg-ease); }
html:not(.no-js) body.past-cover .rail-logo,
html:not(.no-js) body.past-cover .bg-nav,
html:not(.no-js) body.past-cover .bg-nav--white,
html:not(.no-js) body.past-cover .bg-foot,
html:not(.no-js) body.past-cover .scrollbar { opacity: 1; }
html:not(.no-js) body.past-cover .rail-logo,
html:not(.no-js) body.past-cover .bg-nav,
html:not(.no-js) body.past-cover .bg-foot,
html:not(.no-js) body.past-cover .scrollbar { pointer-events: auto; }

/* ════════ COVER / HERO — full-bleed editorial ════════ */
.bg-cover {
  position: relative; min-height: 100svh; width: 100%; margin: 0;
  color: var(--bean);
  display: flex; flex-direction: column;
  padding: clamp(22px, 3.4vh, 42px) clamp(26px, 5vw, 80px);
}
.bg-cover__bar {
  display: flex; justify-content: space-between; align-items: center; gap: clamp(16px, 3vw, 44px); flex-wrap: wrap;
  font-family: var(--serif); font-weight: 400; font-size: clamp(0.85rem, 1.05vw, 1.05rem);
  letter-spacing: 0.01em; text-transform: none;
  color: var(--muted);
}
/* The Seasons has no numerals, so figures fall back to Inter */
.bg-cover__bar .bg-cnum { font-family: var(--sans); font-size: 0.88em; letter-spacing: 0.01em; }
.bg-cover__bar--top { padding-bottom: clamp(13px, 2vh, 22px); border-bottom: 1px solid var(--hair); }
.bg-cover__bar--bottom { padding-top: clamp(13px, 2vh, 22px); border-top: 1px solid var(--hair); }
.bg-cover__main { flex: 1; display: flex; flex-direction: column; justify-content: center; align-items: flex-start; }
/* lede (wordmark + title) is bottom-anchored to the same line as the bean, so the title's
   bottom and the bean's bottom share a baseline (see .bg-cover__mark). */
.bg-cover__lede {
  position: absolute; left: clamp(26px, 5vw, 80px); bottom: clamp(146px, 18.5vh, 208px);
  display: flex; flex-direction: column; align-items: flex-start; gap: clamp(20px, 3.2vh, 44px);
}
.bg-cover__wordmark { width: clamp(150px, 16vw, 270px); height: auto; display: block; }
.bg-cover__title {
  font-family: var(--serif); font-weight: 400; color: var(--coffee); margin: 0;
  font-size: clamp(3.6rem, 13.5vw, 14rem); line-height: 0.84; letter-spacing: -0.03em;
}
.bg-cover__title span { display: block; overflow: hidden; padding: 0.08em 0.06em 0.02em 0; margin: -0.08em -0.06em -0.02em 0; }
.bg-cover__title span > span { display: inline-block; will-change: transform; }
.bg-scrollcue, .bg-cover__edition { color: var(--muted); }
/* ── the mark: the coffee-bean symbol sits low on the right; its brand-fact caption is
   pulled out of the unit and pinned to the bottom-right corner (.bg-cover__facts), just
   above the bottom bar's divider. Kept to the right of the title's reach so they never meet. ── */
.bg-cover__mark {
  position: absolute; right: clamp(26px, 5vw, 80px); bottom: clamp(182px, 23vh, 250px);
  pointer-events: none;
}
.bg-cover__bean { width: clamp(190px, 24vw, 360px); height: auto; display: block; }
/* caption: lower-right corner, sitting in the cover's flex flow just above the bottom bar */
.bg-cover__facts {
  list-style: none; margin: 0 0 clamp(12px, 2vh, 20px); align-self: flex-end;
  padding: clamp(11px, 1.7vh, 16px) 0 0; display: flex; flex-direction: column;
  gap: 6px; align-items: flex-end; text-align: right; border-top: 1px solid var(--hair); min-width: clamp(150px, 17vw, 210px);
}
/* same voice as the cover bars: The Seasons, sentence case, muted */
.bg-cover__facts li {
  font-family: var(--serif); font-size: clamp(0.85rem, 1.05vw, 1.05rem); letter-spacing: 0.01em; line-height: 1.3;
  color: var(--muted);
}
.bg-cover__facts .bg-cnum { font-family: var(--sans); font-size: 0.88em; }

@media (max-width: 640px) { .bg-cover__bar { gap: 10px 24px; } }

/* ════════ CONTENTS ════════ */
.bg-contents {
  min-height: 100svh; display: flex; flex-direction: column; justify-content: safe center;
  padding-block: clamp(48px, 8vh, 96px);
  border-top: 1px solid var(--hair); border-bottom: 1px solid var(--hair);
}
.bg-contents .bg-wrap { max-width: min(1400px, 94vw); width: 100%; }

/* ════════ DESIGN APPROACH — condensed full-brown page (fits one screen) ════════ */
/* default (and animation-off) state: cream background + dark text. The morph scrubs
   this toward Idle Coffee + light when the section is fully on screen. */
.bg-da {
  background: var(--linen); color: var(--bean);
  display: grid; grid-template-columns: 0.82fr 1.18fr; align-items: center;
  height: clamp(600px, 100svh, 1080px); /* encompasses the whole screen */
}
/* the picture is a rounded, inset card (brown, with the morph multiplied over it) */
.bg-da__media {
  position: relative; overflow: hidden; background: var(--coffee);
  align-self: center; justify-self: center;
  height: 84%; aspect-ratio: 576 / 1024;
  margin-inline: clamp(20px, 3vw, 52px);
  border-radius: clamp(12px, 1.3vw, 22px);
}
.bg-da__media img { width: 100%; height: 100%; object-fit: cover; object-position: center; mix-blend-mode: multiply; filter: brightness(0.98) contrast(1.05); }
.bg-da__body {
  display: flex; flex-direction: column; justify-content: center;
  padding: clamp(40px, 5vw, 96px) var(--gutter) clamp(40px, 5vw, 96px) clamp(34px, 4vw, 76px);
}
/* all text uses currentColor (or a mix of it) so it morphs with the section colour */
.bg-da__eyebrow { font-family: var(--mono); font-size: 0.74rem; letter-spacing: 0.28em; text-transform: uppercase; color: color-mix(in srgb, currentColor 55%, transparent); margin-bottom: clamp(20px, 2.4vw, 30px); }
.bg-da__title { font-family: var(--serif); font-weight: 400; font-size: clamp(2.5rem, 4.6vw, 4.2rem); line-height: 0.98; letter-spacing: -0.025em; margin-bottom: clamp(24px, 2.8vw, 38px); color: currentColor; }
.bg-da__copy p { color: color-mix(in srgb, currentColor 84%, transparent); font-size: clamp(1.02rem, 1.2vw, 1.22rem); line-height: 1.62; max-width: 44ch; margin-bottom: 1.1em; }
.bg-da__copy p:last-child { margin-bottom: 0; }
.bg-da__values {
  list-style: none; display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(20px, 2.4vw, 44px);
  margin-top: clamp(34px, 4.4vw, 64px); padding-top: clamp(24px, 3vw, 40px);
  border-top: 1px solid color-mix(in srgb, currentColor 22%, transparent);
}
.bg-da__values li { min-width: 0; }
.bg-da__vk { display: block; font-family: var(--serif); font-size: clamp(1.2rem, 1.5vw, 1.5rem); line-height: 1.05; color: currentColor; margin-bottom: clamp(7px, 0.9vw, 11px); }
.bg-da__values p { font-size: clamp(0.86rem, 1vw, 0.98rem); line-height: 1.45; color: color-mix(in srgb, currentColor 64%, transparent); }

/* ════════ VALUES / PILLARS (3-up) ════════ */
.bg-cols {
  max-width: var(--bg-maxw); margin: clamp(34px, 5vh, 56px) auto 0; padding-inline: var(--gutter);
  display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(24px, 4vw, 56px);
}
.bg-pillar { padding-top: 22px; border-top: 2px solid var(--dusk); }
.bg-pillar__k { font-family: var(--mono); font-size: 0.7rem; letter-spacing: 0.2em; color: var(--muted); margin-bottom: 12px; }
.bg-pillar h4 { font-family: var(--serif); font-weight: 400; font-size: clamp(1.5rem, 2.6vw, 2.1rem); margin-bottom: 12px; letter-spacing: -0.01em; }
.bg-pillar p { font-size: 0.95rem; color: color-mix(in srgb, var(--bean) 78%, transparent); max-width: 34ch; }
.bg-band .bg-pillar { border-top-color: var(--lightblue); }
.bg-band .bg-pillar p { color: color-mix(in srgb, var(--flatwhite) 76%, transparent); }
.bg-band .bg-pillar__k { color: color-mix(in srgb, var(--flatwhite) 60%, transparent); }

/* ════════ MISSION QUOTE ════════ */
.bg-quote {
  max-width: 940px; margin: clamp(34px, 5vh, 60px) auto 0; padding: clamp(34px, 5vw, 60px);
  border: 1px solid var(--hair); border-radius: 6px; background: color-mix(in srgb, var(--flatwhite) 60%, transparent);
  text-align: center;
}
.bg-quote p { font-family: var(--serif); font-weight: 400; font-size: clamp(1.5rem, 3.4vw, 2.6rem); line-height: 1.16; letter-spacing: -0.015em; color: var(--bean); }
.bg-quote cite { display: block; margin-top: 22px; font-family: var(--mono); font-size: 0.72rem; font-style: normal; letter-spacing: 0.2em; text-transform: uppercase; color: var(--dusk); }

/* full-bleed Idle Coffee mission band (also the demo for the nav colour flip) */
.bg-quoteband { background: var(--coffee); margin-top: clamp(40px, 6vh, 72px); padding: clamp(56px, 10vh, 120px) var(--gutter); }
.bg-quote--dark { background: none; border: 0; margin: 0 auto; padding: 0; }
.bg-quote--dark p { color: var(--flatwhite); }
.bg-quote--dark cite { color: var(--honey); }

/* ════════ Mission & Vision — label + statement editorial pair ════════ */
.bg-mv { max-width: var(--bg-maxw); margin: clamp(40px, 6vh, 80px) auto 0; padding-inline: var(--gutter); }
.bg-mv__row {
  display: grid; grid-template-columns: minmax(190px, 0.3fr) 1fr; gap: clamp(20px, 4vw, 70px);
  padding: clamp(34px, 5vh, 62px) 0; border-top: 1px solid var(--hair);
}
.bg-mv__row:last-child { border-bottom: 1px solid var(--hair); }
.bg-mv__label {
  font-family: var(--serif); font-weight: 400; font-size: clamp(1.4rem, 2.2vw, 1.95rem); letter-spacing: -0.01em;
  line-height: 1.04; color: var(--bean); padding-top: 0.12em;
}
.bg-mv__statement {
  font-family: var(--serif); font-weight: 400; font-size: clamp(1.55rem, 3vw, 2.5rem);
  line-height: 1.14; letter-spacing: -0.015em; color: var(--bean); max-width: 24ch;
}
.bg-mv__row--vision .bg-mv__statement { max-width: 16ch; margin-bottom: clamp(18px, 2.2vw, 26px); }
.bg-mv__body { font-size: 1rem; line-height: 1.62; color: color-mix(in srgb, var(--bean) 80%, transparent); max-width: 60ch; }
@media (max-width: 720px) {
  .bg-mv__row { grid-template-columns: 1fr; gap: 14px; }
  .bg-mv__statement, .bg-mv__row--vision .bg-mv__statement { max-width: none; }
}

/* ════════ FULL-BLEED FIGURE ════════ */
.bg-figure { margin: clamp(40px, 7vh, 96px) 0 0; overflow: hidden; }
.bg-figure img { width: 100%; height: clamp(280px, 56vh, 620px); object-fit: cover; display: block; }
.bg-figure figcaption {
  max-width: var(--bg-maxw); margin: 16px auto 0; padding-inline: var(--gutter);
  font-family: var(--mono); font-size: 0.72rem; letter-spacing: 0.04em; color: var(--muted);
}

/* ════════ LOGO TILES ════════ */
.bg-logos {
  max-width: var(--bg-maxw); margin: clamp(34px, 5vh, 56px) auto 0; padding-inline: var(--gutter);
  display: grid; grid-template-columns: 1.4fr 1fr; gap: clamp(16px, 2vw, 24px);
}
.bg-tile {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px;
  aspect-ratio: 16 / 9; border: 1px solid var(--hair); border-radius: 6px; background: var(--flatwhite);
}
.bg-tile--dark { background: var(--bean); }
.bg-tile--coffee { background: var(--coffee); }
.bg-tile--blue { background: var(--dusk); }
.bg-tile img { width: clamp(120px, 26%, 230px); height: auto; }
.bg-tile--mark img { width: clamp(76px, 13%, 116px); }
.bg-tile__cap { font-family: var(--mono); font-size: 0.64rem; letter-spacing: 0.18em; text-transform: uppercase; color: var(--muted); }
.bg-tile--dark .bg-tile__cap, .bg-tile--coffee .bg-tile__cap, .bg-tile--blue .bg-tile__cap { color: color-mix(in srgb, var(--flatwhite) 55%, transparent); }

/* Our Logomark — animated morph + copy */
.bg-logomark {
  max-width: var(--bg-maxw); margin: clamp(40px, 6vh, 80px) auto 0; padding-inline: var(--gutter);
  display: grid; grid-template-columns: auto 1fr; gap: clamp(30px, 5vw, 76px); align-items: center;
}
.bg-morph { flex: none; display: grid; place-items: center; }
.bg-morph img { width: clamp(120px, 15vw, 200px); height: auto; display: block; }
@media (max-width: 680px) { .bg-logomark { grid-template-columns: 1fr; gap: 26px; justify-items: start; } }

/* Logo slides — full-page PDF-style: split header + main + (steps) */
.bg-iconov {
  max-width: var(--bg-maxw); margin-inline: auto; padding-inline: var(--gutter);
  min-height: 100svh; display: flex; flex-direction: column; padding-block: clamp(50px, 7vh, 92px);
}
.bg-iconov__head {
  display: grid; grid-template-columns: 1fr 1fr; gap: clamp(28px, 5vw, 80px); align-items: start;
  padding-bottom: clamp(20px, 3vh, 32px); border-bottom: 1px solid var(--hair);
}
.bg-iconov__title { font-family: var(--serif); font-weight: 400; font-size: clamp(1.7rem, 3.1vw, 2.7rem); line-height: 1.03; letter-spacing: -0.02em; margin-top: 10px; }
.bg-iconov__desc { font-size: 0.97rem; line-height: 1.62; color: color-mix(in srgb, var(--bean) 80%, transparent); max-width: 52ch; }
.bg-iconov__main {
  flex: 1; display: grid; grid-template-columns: 1fr 1fr; gap: clamp(30px, 5vw, 70px); align-items: center;
  padding-block: clamp(30px, 5vh, 60px);
}

/* Primary wordmark slide — big mark + the four recommended colourways (wide) */
.bg-pwm { max-width: min(1500px, 94vw); }
.bg-pwm .bg-iconov__head { align-items: center; }
.bg-pwm .bg-iconov__title { font-size: clamp(2.4rem, 4.8vw, 4.4rem); line-height: 1; margin-top: 0; }
.bg-pwm .bg-iconov__desc { font-size: clamp(1rem, 1.25vw, 1.2rem); line-height: 1.6; max-width: 58ch; }
.bg-pwm__main {
  flex: 1; display: grid; grid-template-columns: 1fr 1fr; gap: clamp(36px, 5vw, 84px); align-items: center;
  padding-block: clamp(30px, 5vh, 64px);
}
.bg-pwm__hero { display: grid; place-items: center; }
.bg-pwm__hero img { width: clamp(240px, 33vw, 540px); height: auto; }
.bg-pwm__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0; border: 1px solid var(--hair); border-radius: 8px; overflow: hidden; }
.bg-pwm__swatch { aspect-ratio: 16 / 10; display: grid; place-items: center; }
.bg-pwm__swatch img { width: 60%; height: auto; }
@media (max-width: 760px) { .bg-pwm__main { grid-template-columns: 1fr; gap: clamp(28px, 6vw, 40px); } }
.bg-iconov__left { display: flex; flex-direction: column; justify-content: space-between; gap: clamp(28px, 4vh, 48px); }
.bg-iconov__logo { flex: 1; display: grid; place-items: center; }
.bg-iconov__logo img { width: clamp(150px, 17vw, 250px); height: auto; }
/* clean logo mark + a quiet caption beneath it */
.bg-iconov__cap {
  text-align: center; font-family: var(--mono); font-size: 0.66rem; font-weight: 500;
  letter-spacing: 0.18em; text-transform: uppercase; color: var(--muted);
}
.bg-iconov__cap span { color: var(--blush); margin: 0 0.55em; }
/* full-width hand-drawn construction sequence on graph paper, framed as an artifact */
.bg-process { margin: clamp(40px, 7vh, 84px) 0 0; display: flex; flex-direction: column; align-items: center; }
.bg-process__img {
  width: 100%; max-width: 920px; height: auto; display: block;
  border: 1px solid var(--hair); border-radius: 6px;
  box-shadow: 0 24px 60px -34px color-mix(in srgb, var(--bean) 50%, transparent);
}
.bg-iconov__grid { margin: 0; display: grid; place-items: center; }
.bg-iconov__grid img { width: 100%; max-width: 520px; height: auto; display: block; mix-blend-mode: multiply; }
.bg-iconov__steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: clamp(10px, 1.4vw, 18px); }
.bg-step { margin: 0; display: flex; flex-direction: column; align-items: center; gap: 11px; text-align: center; }
.bg-step__ic { width: clamp(50px, 4.8vw, 68px); aspect-ratio: 1; border-radius: 50%; display: grid; place-items: center; background: var(--flatwhite); border: 1px solid var(--hair); overflow: hidden; }
.bg-step__ic img { width: 60%; height: 60%; object-fit: contain; }
.bg-step__ic--mark img { width: 62%; height: 62%; }
.bg-step figcaption { font-family: var(--mono); font-size: 0.64rem; letter-spacing: 0.07em; text-transform: uppercase; color: var(--muted); line-height: 1.3; }
@media (max-width: 760px) {
  .bg-iconov__head { grid-template-columns: 1fr; gap: 14px; align-items: start; }
  .bg-iconov__main { grid-template-columns: 1fr; gap: clamp(28px, 6vw, 40px); }
  .bg-iconov__left { gap: 32px; }
}

/* clearspace note */
.bg-note { max-width: 62ch; margin: clamp(28px, 4vh, 44px) auto 0; padding-inline: var(--gutter); }
.bg-note p { font-size: 0.95rem; color: color-mix(in srgb, var(--bean) 78%, transparent); }

/* ════════ MISUSE GRID ════════ */
.bg-misuse__title {
  font-family: var(--serif); font-weight: 400; font-size: clamp(2.2rem, 4.6vw, 3.6rem);
  line-height: 1; letter-spacing: -0.02em; color: var(--bean); margin-bottom: clamp(8px, 1.2vw, 14px);
}
.bg-misuse__sub {
  font-family: var(--serif); font-weight: 400; font-size: clamp(1.25rem, 2.2vw, 1.7rem);
  line-height: 1.2; letter-spacing: -0.01em; color: color-mix(in srgb, var(--bean) 70%, transparent);
}
.bg-misuse {
  max-width: var(--bg-maxw); margin: clamp(28px, 4vh, 46px) auto clamp(20px, 3vh, 44px); padding-inline: var(--gutter);
  display: grid; grid-template-columns: repeat(2, 1fr); gap: clamp(20px, 2.6vw, 40px) clamp(16px, 2vw, 28px);
}
.bg-misuse__hint { margin-top: 8px; font-size: 0.82rem; letter-spacing: 0.01em; color: var(--dusk); }
.bg-dont { margin: 0; cursor: pointer; }
.bg-dont__stage {
  position: relative; aspect-ratio: 16 / 6; display: flex; align-items: center; justify-content: center;
  border: 1px solid var(--hair); border-radius: 6px; background: var(--flatwhite); overflow: hidden;
  transition: background-color 0.55s var(--bg-ease), border-color 0.3s var(--bg-ease);
}
.bg-dont__stage img { width: 50%; height: auto; position: relative; z-index: 1; transition: transform 0.6s var(--bg-ease), filter 0.6s var(--bg-ease); }
.bg-dont__stage::after {
  content: "\00d7"; position: absolute; top: 10px; right: 12px; width: 22px; height: 22px;
  display: grid; place-items: center; border-radius: 50%; background: var(--blush);
  color: var(--bean); font-size: 0.85rem; line-height: 1; z-index: 3;
  transition: background-color 0.4s var(--bg-ease);
}
.bg-dont__cap { margin-top: 12px; text-align: center; font-size: 0.82rem; letter-spacing: 0.01em; color: color-mix(in srgb, var(--bean) 60%, transparent); }
.bg-dont:hover .bg-dont__stage { border-color: var(--dusk); }
.bg-dont:active .bg-dont__stage { transform: scale(0.99); }
/* the don't treatments */
.dont-rotate img  { transform: rotate(-9deg); }
.dont-stretch img { transform: scaleX(1.5); }
.dont-squash img  { transform: scaleY(1.7); }
.dont-skew img    { transform: skewX(-14deg); }
.dont-shadow img  { filter: drop-shadow(5px 7px 5px rgba(25, 20, 18, 0.45)); }
.dont-busy::before {
  content: ""; position: absolute; inset: 0; z-index: 0;
  background-image: repeating-linear-gradient(45deg, var(--honey) 0 14px, var(--blush) 14px 28px, var(--lightblue) 28px 42px);
  transition: opacity 0.55s var(--bg-ease);
}
.dont-lowcontrast { background: var(--coffee); }
/* corrected state: tap a tile to fix it */
.bg-dont.is-fixed .bg-dont__stage img { transform: none; filter: none; }
.bg-dont.is-fixed .dont-offpalette img,
.bg-dont.is-fixed .dont-busy img { filter: brightness(0); }
.bg-dont.is-fixed .dont-busy::before { opacity: 0; }
.bg-dont.is-fixed .dont-lowcontrast { background: var(--flatwhite); }
.bg-dont.is-fixed .bg-dont__stage::after { content: "\2713"; background: var(--lightblue); }
@media (prefers-reduced-motion: reduce) {
  .bg-dont__stage, .bg-dont__stage img, .dont-busy::before { transition: none; }
}

/* ════════ colour palette (formatted swatch board) ════════ */
.bg-palette { max-width: min(1480px, 94vw); margin: clamp(30px, 5vh, 60px) auto 0; padding-inline: var(--gutter); }
.bg-palette__head { display: flex; align-items: center; gap: 18px; margin: clamp(34px, 5vh, 60px) 0 clamp(20px, 3vh, 30px); }
.bg-palette__head:first-child { margin-top: 0; }
.bg-palette__k { font-family: var(--serif); font-weight: 400; font-size: clamp(1.3rem, 2vw, 1.8rem); letter-spacing: -0.01em; color: var(--bean); white-space: nowrap; }
.bg-palette__line { flex: 1; height: 1px; background: var(--hair); }
/* all three groups share a 3-column grid so the circles line up in columns (primary fills the first two) */
.bg-palette__primary,
.bg-palette__row { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(22px, 3vw, 48px); justify-items: center; }
/* interactive colour circles: round chip + name + hex/RGB tag, "Read more" on hover, click opens the modal */
.bg-swatch {
  display: flex; flex-direction: column; align-items: center; gap: clamp(14px, 1.4vw, 22px);
  background: none; border: 0; padding: 0; margin: 0; text-align: center; cursor: pointer; color: var(--bean); font: inherit;
}
.bg-swatch__chip {
  position: relative; width: clamp(150px, 17vw, 232px); aspect-ratio: 1 / 1; border-radius: 50%; overflow: hidden;
  box-shadow: 0 16px 38px -24px color-mix(in srgb, var(--c, var(--bean)) 48%, transparent);
}
.bg-swatch__chip[data-light] { box-shadow: inset 0 0 0 1px var(--hair), 0 16px 34px -26px rgba(25, 20, 18, 0.28); }
/* GSAP drives a gentle transform-only lift on hover (see brand.js); the chip keeps its true colour.
   "Read more" sits inside the circle in a contrasting colour (no darkening scrim) and fades + scales in,
   riding along with the chip's lift. */
.bg-swatch__copy {
  position: absolute; inset: 0; display: grid; place-items: center; pointer-events: none;
  font-family: var(--mono); font-size: clamp(0.58rem, 0.7vw, 0.66rem); letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--tc, var(--linen));
  opacity: 0; transform: scale(0.9); transition: opacity 0.5s var(--bg-ease), transform 0.5s var(--bg-ease);
}
.bg-swatch:hover .bg-swatch__copy, .bg-swatch:focus-visible .bg-swatch__copy { opacity: 1; transform: scale(1); }
.bg-swatch:focus-visible { outline: none; }
.bg-swatch:focus-visible .bg-swatch__chip { outline: 2px solid var(--c, var(--dusk)); outline-offset: 4px; }
.bg-swatch__name { font-family: var(--serif); font-weight: 400; font-size: clamp(1.1rem, 1.5vw, 1.5rem); line-height: 1; color: var(--bean); }
.bg-swatch__spec { font-family: var(--mono); font-size: clamp(0.64rem, 0.82vw, 0.76rem); letter-spacing: 0.02em; color: var(--muted); }
@media (max-width: 820px) { .bg-palette__primary, .bg-palette__row { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 480px) { .bg-palette__primary, .bg-palette__row { grid-template-columns: 1fr; } }
@media (prefers-reduced-motion: reduce) { .bg-swatch__chip { transition: none; } }

/* ════════ brand personality: statement + spectrum ════════ */
.bg-personality {
  max-width: var(--bg-maxw); margin: clamp(34px, 5vh, 62px) auto 0; padding-inline: var(--gutter);
  display: grid; grid-template-columns: 0.82fr 1.18fr; gap: clamp(36px, 5vw, 86px); align-items: center;
}
.bg-personality__quote {
  font-family: var(--serif); font-weight: 400; font-size: clamp(1.55rem, 2.7vw, 2.5rem);
  line-height: 1.2; letter-spacing: -0.015em; color: var(--bean);
}
.bg-personality__sub {
  margin-top: clamp(16px, 2.4vh, 26px); font-size: clamp(1rem, 1.2vw, 1.14rem); line-height: 1.5;
  color: color-mix(in srgb, var(--bean) 62%, transparent); max-width: 34ch;
}
.bg-spectrum { display: flex; flex-direction: column; gap: clamp(13px, 2vh, 22px); }
.bg-spectrum__row {
  display: grid; grid-template-columns: clamp(118px, 15vw, 162px) 1fr clamp(76px, 9vw, 104px);
  align-items: center; gap: clamp(12px, 1.4vw, 22px);
}
.bg-spectrum__l, .bg-spectrum__r { font-family: var(--sans); font-weight: 500; font-size: clamp(0.82rem, 1vw, 0.95rem); letter-spacing: 0.01em; color: var(--bean); }
.bg-spectrum__r { color: color-mix(in srgb, var(--bean) 58%, transparent); }
.bg-spectrum__track { position: relative; height: 1px; background: color-mix(in srgb, var(--bean) 24%, transparent); }
.bg-spectrum__track::before, .bg-spectrum__track::after {
  content: ""; position: absolute; top: 50%; width: 7px; height: 7px; border-radius: 50%;
  border: 1px solid color-mix(in srgb, var(--bean) 42%, transparent); background: var(--linen);
}
.bg-spectrum__track::before { left: 0; transform: translate(-50%, -50%); }
.bg-spectrum__track::after  { right: 0; transform: translate(50%, -50%); }
.bg-spectrum__dot {
  position: absolute; top: 50%; left: var(--p); width: 14px; height: 14px; border-radius: 50%;
  background: var(--dusk); transform: translate(-50%, -50%);
}
@media (max-width: 860px) { .bg-personality { grid-template-columns: 1fr; gap: clamp(28px, 5vh, 48px); } }
@media (max-width: 540px) {
  .bg-spectrum__row { grid-template-columns: 1fr auto; gap: 4px 12px; }
  .bg-spectrum__track { grid-column: 1 / -1; margin-top: 6px; }
}

/* ════════ contents: a 3 x 2 table. intro cell, then one cell per chapter:
   outlined number, chapter title, ruled list of sub-sections. Every cell shares the
   same top edge (number and title sit on one line across the row), hairlines
   between columns and rows, no arrows, no footnote. ════════ */
.bg-toc-grid { display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--bean); }
.bg-toc-cell {
  display: flex; flex-direction: column; min-width: 0; min-height: clamp(300px, 38vh, 380px);
  padding: clamp(24px, 3.4vh, 40px) clamp(22px, 2.4vw, 44px) clamp(28px, 3.4vh, 44px);
  border-left: 1px solid var(--hair); border-bottom: 1px solid var(--hair);
}
.bg-toc-cell:nth-child(3n+1) { border-left: 0; padding-left: 0; }
.bg-toc-cell:nth-child(3n)   { padding-right: 0; }

/* intro cell: title on the shared top line, lead below */
.bg-toc-intro { gap: clamp(16px, 2.4vh, 26px); }
.bg-contents__title { font-family: var(--serif); font-weight: 400; font-size: clamp(2.6rem, 4.4vw, 4rem); line-height: 0.9; letter-spacing: -0.025em; margin: 0; }
.bg-toc-intro__lead { font-size: clamp(0.92rem, 1vw, 1.02rem); line-height: 1.55; color: color-mix(in srgb, var(--bean) 66%, transparent); max-width: 30ch; }

/* chapter cell */
.bg-toc-col { gap: clamp(18px, 2.6vh, 30px); }
.bg-toc-col__main { display: flex; flex-direction: column; gap: clamp(12px, 1.6vh, 18px); }
.bg-toc__n {
  display: block; font-family: var(--sans); font-weight: 600; font-size: clamp(2.6rem, 4vw, 4rem); line-height: 0.9; letter-spacing: -0.04em;
  color: transparent; -webkit-text-stroke: 1.5px color-mix(in srgb, var(--bean) 46%, transparent);
  transition: color 0.4s var(--bg-ease), -webkit-text-stroke-color 0.4s var(--bg-ease);
}
.bg-toc-col:hover .bg-toc__n { color: var(--dusk); -webkit-text-stroke-color: var(--dusk); }
.bg-toc__t {
  display: inline-block; font-family: var(--serif); font-weight: 400;
  font-size: clamp(1.5rem, 2.1vw, 2.1rem); letter-spacing: -0.015em; line-height: 1;
  color: var(--bean); transition: color 0.35s var(--bg-ease);
}
.bg-toc__t:hover { color: var(--dusk); }
.bg-toc__list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.bg-toc__list li { border-top: 1px solid var(--hair); }
.bg-toc__sub {
  display: block; padding: clamp(8px, 1.1vh, 12px) 0;
  font-family: var(--sans); font-size: clamp(0.86rem, 0.98vw, 0.98rem); letter-spacing: 0.005em;
  color: color-mix(in srgb, var(--bean) 76%, transparent); transition: color 0.3s var(--bg-ease);
}
.bg-toc__sub:hover { color: var(--dusk); }
.bg-toc__sub:focus-visible, .bg-toc__t:focus-visible { outline: 2px solid var(--dusk); outline-offset: 2px; border-radius: 2px; }
@media (max-width: 980px) {
  .bg-toc-grid { grid-template-columns: 1fr; }
  .bg-toc-cell, .bg-toc-cell:nth-child(3n+1) { border-left: 0; padding-inline: 0; min-height: 0; padding-block: clamp(26px, 4.5vh, 40px); }
}

/* ════════ sixth page: just the number, nothing in the background ════════ */
.bg-endpage { min-height: 100svh; display: grid; place-items: center; padding: clamp(40px, 8vh, 90px) var(--gutter); }
.bg-endpage__num {
  font-family: var(--sans); font-weight: 600; font-size: clamp(10rem, 30vw, 26rem); line-height: 1; letter-spacing: -0.04em;
  color: color-mix(in srgb, var(--bean) 8%, transparent);
  -webkit-text-stroke: 1.5px color-mix(in srgb, var(--bean) 22%, transparent);
}

/* ════════ COLOUR — copy left, interactive wheel right ════════ */
.bg-colourintro {
  max-width: var(--bg-maxw); margin: clamp(28px, 4vh, 56px) auto 0; padding-inline: var(--gutter);
  display: grid; grid-template-columns: 1fr auto; gap: clamp(34px, 6vw, 90px); align-items: center;
}
.bg-colourintro__copy { max-width: 48ch; }
.bg-colourintro__lead { font-family: var(--serif); font-weight: 400; font-size: clamp(1.5rem, 2.7vw, 2.3rem); line-height: 1.12; letter-spacing: -0.015em; color: var(--bean); margin-bottom: clamp(16px, 2vw, 24px); }
.bg-colourintro__copy > p:not(.bg-colourintro__lead) { color: color-mix(in srgb, var(--bean) 82%, transparent); font-size: 1rem; line-height: 1.6; }

.bg-wheel { position: relative; width: clamp(230px, 26vw, 330px); aspect-ratio: 1; justify-self: center; filter: drop-shadow(0 26px 46px rgba(25, 20, 18, 0.2)); }
.bg-wheel__svg { position: absolute; inset: 0; width: 100%; height: 100%; display: block; overflow: visible; will-change: transform; }
.bg-wheel__wedge { cursor: pointer; stroke: rgba(25, 20, 18, 0.09); stroke-width: 0.5; transition: filter 0.25s var(--bg-ease); }
.bg-wheel__wedge:hover { filter: brightness(1.06); }
.bg-wheel__wedge:focus-visible { outline: none; filter: brightness(1.1); }
/* eyedropper chip: a little colour square that pops at the click, then the panel opens */
/* wheel hover hint: a "Read more" pill that follows the cursor (no change to the wheel itself) */
.cwtip {
  position: fixed; z-index: 1100; transform: translate(-50%, calc(-100% - 14px)); pointer-events: none;
  background: var(--bean); color: var(--linen); font-family: var(--mono); font-size: 0.64rem; letter-spacing: 0.05em; text-transform: uppercase;
  padding: 6px 10px; border-radius: 7px; white-space: nowrap; opacity: 0; transition: opacity 0.18s var(--bg-ease);
}
.cwtip.is-on { opacity: 1; }
.bg-wheel__hub { position: absolute; inset: 0; display: grid; place-items: center; pointer-events: none; z-index: 2; }
.bg-wheel__hub img { width: 22%; height: auto; }
@media (max-width: 880px) {
  .bg-colourintro { grid-template-columns: 1fr; gap: clamp(30px, 6vw, 46px); justify-items: center; }
  .bg-colourintro__copy { max-width: 52ch; }
}

/* ════════ Colour detail modal ════════ */
.cmodal { position: fixed; inset: 0; z-index: 1000; display: grid; place-items: center; padding: clamp(16px, 4vw, 40px); opacity: 0; pointer-events: none; transition: opacity 0.3s var(--bg-ease); }
.cmodal.is-open { opacity: 1; pointer-events: auto; }
.cmodal__backdrop { position: absolute; inset: 0; background: color-mix(in srgb, var(--bean) 42%, transparent); backdrop-filter: blur(7px); -webkit-backdrop-filter: blur(7px); }
.cmodal__card {
  position: relative; width: min(560px, 100%); max-height: 88vh; overflow-y: auto;
  overscroll-behavior: contain; scrollbar-width: none; -ms-overflow-style: none;
  background: var(--linen); border-radius: 10px; padding: clamp(26px, 4vw, 42px);
  box-shadow: 0 40px 90px -30px rgba(25, 20, 18, 0.55);
  transform: scale(0.96); opacity: 0; transition: transform 0.32s var(--bg-ease), opacity 0.32s var(--bg-ease);
}
.cmodal__card::-webkit-scrollbar { width: 0; height: 0; display: none; }
.cmodal.is-open .cmodal__card { transform: scale(1); opacity: 1; }
.cmodal__close { position: absolute; top: 14px; right: 16px; width: 34px; height: 34px; border-radius: 50%; border: 1px solid var(--hair); background: var(--linen); color: var(--bean); font-size: 1.2rem; line-height: 1; cursor: pointer; display: grid; place-items: center; transition: background 0.2s var(--bg-ease), transform 0.15s var(--bg-ease); }
.cmodal__close:hover { background: color-mix(in srgb, var(--bean) 8%, transparent); }
.cmodal__close:active { transform: scale(0.92); }
.cmodal__head { display: flex; gap: 18px; align-items: center; margin-bottom: 6px; padding-right: 30px; }
.cmodal__chip { width: clamp(58px, 12vw, 82px); height: clamp(58px, 12vw, 82px); border-radius: 8px; flex: none; border: 1px solid var(--hair); }
.cmodal__role { font-family: var(--mono); font-size: 0.64rem; letter-spacing: 0.2em; text-transform: uppercase; color: var(--dusk); margin-bottom: 5px; }
.cmodal__name { font-family: var(--serif); font-weight: 400; font-size: clamp(1.6rem, 3vw, 2.1rem); line-height: 1; margin-bottom: 9px; }
.cmodal__codes { font-family: var(--mono); font-size: 0.7rem; color: var(--muted); line-height: 1.7; }
.cmodal__codes b { color: var(--bean); font-weight: 500; }
.cmodal__copy { cursor: pointer; color: var(--bean); border-bottom: 1px dotted color-mix(in srgb, var(--bean) 40%, transparent); }
.cmodal__copy.is-copied { color: var(--dusk); }
.cmodal__sec { border-top: 1px solid var(--hair); padding-top: 15px; margin-top: 18px; }
.cmodal__sec h4 { font-family: var(--mono); font-size: 0.64rem; letter-spacing: 0.18em; text-transform: uppercase; color: var(--dusk); margin-bottom: 8px; }
.cmodal__sec p { font-size: 0.92rem; line-height: 1.55; color: color-mix(in srgb, var(--bean) 82%, transparent); }
.cmodal__shades { display: grid; grid-template-columns: repeat(5, 1fr); gap: 6px; margin-top: 2px; }
.cmodal__shades span { height: 46px; border-radius: 5px; border: 1px solid var(--hair); }
.cmodal__conv { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 2px; }
.cmodal__cv { background: color-mix(in srgb, var(--bean) 5%, transparent); border-radius: 7px; padding: 10px 12px; }
.cmodal__cvk { display: block; font-family: var(--mono); font-size: 0.56rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); margin-bottom: 5px; }
.cmodal__cvv { display: block; font-family: var(--mono); font-size: 0.76rem; color: var(--bean); white-space: nowrap; }
@media (max-width: 440px) { .cmodal__conv { grid-template-columns: repeat(2, 1fr); } }
body.cmodal-open { overflow: hidden; }

/* ════════ Pantone reference (under pairings) ════════ */
.bg-pantones { max-width: min(1480px, 94vw); margin: clamp(52px, 8vh, 100px) auto 0; padding-inline: var(--gutter); }
#ch-01, #ch-02, #ch-03 { padding-bottom: clamp(64px, 11vh, 130px); }

/* ════════ applying colour: approximate-use donut ════════ */
.bg-coluse {
  max-width: min(1480px, 94vw); margin: clamp(40px, 6vh, 80px) auto 0; padding-inline: var(--gutter);
  display: grid; grid-template-columns: 1fr 1fr; gap: clamp(34px, 6vw, 96px); align-items: center;
}
.bg-coluse__title { font-family: var(--serif); font-weight: 400; font-size: clamp(2rem, 4vw, 3.2rem); line-height: 1; letter-spacing: -0.02em; color: var(--bean); margin-bottom: clamp(20px, 3vh, 32px); }
.bg-coluse__text p { font-size: clamp(0.98rem, 1.15vw, 1.12rem); line-height: 1.66; color: color-mix(in srgb, var(--bean) 80%, transparent); max-width: 46ch; margin-bottom: 1.1em; }
.bg-coluse__text p:last-child { margin-bottom: 0; }
.bg-coluse__chart { display: flex; flex-direction: column; align-items: center; gap: clamp(22px, 3vh, 34px); }
.bg-coluse__k { margin: 0; font-family: var(--serif); font-weight: 400; font-size: clamp(1.3rem, 1.9vw, 1.7rem); letter-spacing: -0.01em; line-height: 1; color: var(--bean); }
.bg-coluse__top { width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 14px; flex-wrap: wrap; }
.bg-coluse__toggle { position: relative; isolation: isolate; display: inline-grid; grid-template-columns: 1fr 1fr; padding: 3px; border: 1px solid var(--hair); border-radius: 999px; }
/* the blue pill that slides + stretches (GSAP) between the two buttons */
.bg-coluse__thumb { position: absolute; top: 3px; left: 3px; border-radius: 999px; background: var(--dusk); z-index: 0; will-change: transform; }
.bg-coluse__tg { position: relative; z-index: 1; width: 100%; border: 0; background: none; cursor: pointer; text-align: center; white-space: nowrap; font-family: var(--sans); font-weight: 500; font-size: 0.76rem; letter-spacing: 0.01em; color: color-mix(in srgb, var(--bean) 58%, transparent); padding: 7px 18px; border-radius: 999px; transition: color 0.5s var(--bg-ease); }
.bg-coluse__tg.is-active { color: var(--linen); }
.bg-coluse__tg:focus-visible { outline: 2px solid var(--dusk); outline-offset: 2px; }
/* no-JS fallback: keep a solid active pill when the sliding thumb isn't present */
.bg-coluse__toggle:not(:has(.bg-coluse__thumb)) .bg-coluse__tg.is-active { background: var(--dusk); }
.bg-coluse__donut { width: clamp(210px, 26vw, 320px); height: auto; display: block; }
.bg-coluse__ring { transform: rotate(-90deg); transform-origin: 50% 50%; }
.bg-coluse__frame { fill: none; stroke: var(--hair); }
/* legend laid out as a compact grid (≈3 rows) so it fills the width instead of one tall column */
.bg-coluse__legend { width: 100%; display: grid; grid-template-columns: repeat(3, 1fr); column-gap: clamp(20px, 2.6vw, 46px); row-gap: clamp(10px, 1.3vw, 16px); margin-top: clamp(14px, 2.2vh, 28px); }
.bg-coluse__legrow { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: clamp(8px, 1.1vw, 14px); min-width: 0; padding-bottom: clamp(8px, 1.1vw, 14px); border-bottom: 1px solid var(--hair); }
@media (max-width: 640px) { .bg-coluse__legend { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 400px) { .bg-coluse__legend { grid-template-columns: 1fr; } }
.bg-coluse__legrow .nm { display: flex; align-items: center; gap: 9px; min-width: 0; white-space: nowrap; font-family: var(--sans); font-weight: 500; font-size: clamp(0.78rem, 0.92vw, 0.9rem); color: var(--bean); }
/* single percentage column; the number itself counts to the new value on toggle */
.bg-coluse__pct { font-family: var(--mono); font-size: clamp(0.74rem, 0.88vw, 0.84rem); color: var(--bean); text-align: right; min-width: 3.5ch; font-variant-numeric: tabular-nums; }
.bg-coluse__dot { width: 12px; height: 12px; border-radius: 50%; flex: none; box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--bean) 14%, transparent); transition: transform 0.3s var(--bg-ease); }
/* legend names open the colour modal. Emphasise on hover WITHOUT going blue (sensitive in a colour
   section): grow the colour dot and underline the name. */
.bg-coluse__legrow button.nm { background: none; border: 0; padding: 0; cursor: pointer; text-align: left; color: var(--bean); }
.bg-coluse__legrow button.nm:hover { text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }
.bg-coluse__legrow button.nm:hover .bg-coluse__dot { transform: scale(1.35); }
.bg-coluse__legrow button.nm:focus-visible { outline: 2px solid var(--bean); outline-offset: 3px; border-radius: 3px; }
@media (max-width: 820px) { .bg-coluse { grid-template-columns: 1fr; gap: clamp(30px, 6vh, 52px); } }
.bg-pantone-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: clamp(14px, 2vw, 26px); margin-top: clamp(16px, 2.4vw, 26px); }
.bg-pcard {
  background: #fff; border-radius: 3px; overflow: hidden; margin: 0;
  box-shadow: 0 16px 34px -20px rgba(25, 20, 18, 0.45);
  padding: clamp(9px, 0.9vw, 13px) clamp(9px, 0.9vw, 13px) 0; display: flex; flex-direction: column;
}
.bg-pcard__chip { aspect-ratio: 1 / 1.04; border-radius: 1px; }
.bg-pcard__label { padding: clamp(11px, 1.1vw, 15px) 3px clamp(13px, 1.3vw, 17px); }
.bg-pcard__brand { display: block; font-family: var(--sans); font-weight: 800; font-size: clamp(0.92rem, 1.25vw, 1.15rem); letter-spacing: -0.02em; line-height: 1; color: #111; }
.bg-pcard__brand sup { font-size: 0.46em; top: -0.7em; }
.bg-pcard__code { display: block; margin-top: 8px; font-family: var(--sans); font-weight: 600; font-size: 0.7rem; letter-spacing: 0.01em; color: #111; }
.bg-pcard__name { display: block; margin-top: 1px; font-family: var(--sans); font-weight: 500; font-size: 0.7rem; color: #111; }
@media (max-width: 880px) { .bg-pantone-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 440px) { .bg-pantone-grid { grid-template-columns: 1fr; } }
@media (prefers-reduced-motion: reduce) { .cmodal__card { transform: none; transition: opacity 0.2s; } }

/* pairings */
.bg-pairs { max-width: min(1480px, 94vw); margin: clamp(16px, 2vw, 24px) auto 0; padding-inline: var(--gutter); display: grid; grid-template-columns: repeat(4, 1fr); gap: clamp(12px, 1.6vw, 18px); }
.bg-pair { aspect-ratio: 1 / 1; border-radius: 6px; display: flex; align-items: flex-end; padding: 16px; font-family: var(--serif); font-size: 0.98rem; line-height: 1.2; }

/* ════════ TYPOGRAPHY SPECIMENS ════════ */
.bg-type { max-width: min(1480px, 94vw); margin: clamp(30px, 4vh, 52px) auto 0; padding-inline: var(--gutter); display: grid; grid-template-columns: 1fr; gap: clamp(48px, 7vh, 96px); }
.bg-spec { display: grid; grid-template-columns: 1.3fr 1fr; gap: clamp(26px, 4vw, 60px); align-items: start; border-top: 1px solid var(--hair); padding-top: clamp(24px, 3vh, 40px); }
.bg-spec__glyph { font-family: var(--serif); font-weight: 400; font-size: clamp(4rem, 13vw, 9rem); line-height: 0.82; letter-spacing: -0.02em; }
.bg-spec--sans .bg-spec__glyph { font-family: var(--sans); font-weight: 500; letter-spacing: -0.03em; }
.bg-spec__sample { font-family: var(--serif); font-weight: 400; font-size: clamp(1.6rem, 3.4vw, 2.8rem); line-height: 1.04; letter-spacing: -0.01em; margin: 18px 0 0; }
.bg-spec--sans .bg-spec__sample { font-family: var(--sans); font-weight: 300; font-size: clamp(1.4rem, 2.8vw, 2.2rem); }
.bg-spec__name {
  display: flex; align-items: baseline; gap: 0.5em; flex-wrap: wrap; margin-bottom: clamp(16px, 2vh, 24px);
  font-family: var(--serif); font-weight: 400; font-size: clamp(1.9rem, 3.2vw, 2.8rem); letter-spacing: -0.015em; line-height: 1; color: var(--bean);
}
.bg-spec__list { list-style: none; }
.bg-spec__list li { display: grid; grid-template-columns: auto 1fr; gap: 6px 14px; padding: 12px 0; border-top: 1px solid var(--hair); font-size: 0.9rem; }
.bg-spec__list li:first-child { border-top: 0; }
.bg-spec__list b { font-weight: 600; }
.bg-spec__list span { font-family: var(--mono); font-size: 0.74rem; color: var(--muted); text-align: right; }
.bg-spec__copy { font-size: 0.92rem; color: color-mix(in srgb, var(--bean) 78%, transparent); margin-top: 18px; max-width: 40ch; }

/* typographic hierarchy: live example + Sizing + Notes, ruled rows like a spec sheet */
.bg-typescale { margin-top: clamp(20px, 3vh, 40px); }
.bg-typescale__head { display: grid; grid-template-columns: 1.25fr 1fr 1.3fr; gap: clamp(16px, 2.4vw, 40px); align-items: end; padding-bottom: clamp(10px, 1.4vh, 16px); border-bottom: 1px solid var(--bean); }
.bg-typescale__title { font-family: var(--serif); font-weight: 400; font-size: clamp(1.8rem, 2.9vw, 2.5rem); white-space: nowrap; line-height: 1; letter-spacing: -0.015em; color: var(--bean); }
.bg-typescale__colk { font-family: var(--serif); font-weight: 400; font-size: clamp(1.3rem, 2vw, 1.75rem); letter-spacing: -0.01em; line-height: 1; color: var(--bean); }
.bg-typescale__row { display: grid; grid-template-columns: 1.25fr 1fr 1.3fr; gap: clamp(16px, 2.4vw, 40px); align-items: start; padding: clamp(22px, 3.4vh, 40px) 0; border-bottom: 1px solid var(--hair); }
.bg-typescale__eg { margin: 0; color: var(--bean); }
.bg-typescale__spec { display: flex; flex-direction: column; gap: 5px; font-family: var(--sans); font-size: clamp(0.78rem, 0.95vw, 0.9rem); color: color-mix(in srgb, var(--bean) 76%, transparent); }
.bg-typescale__spec span:first-child { color: var(--bean); font-weight: 500; }
.bg-typescale__note { margin: 0; font-size: clamp(0.82rem, 1vw, 0.94rem); line-height: 1.55; color: color-mix(in srgb, var(--bean) 72%, transparent); max-width: 42ch; }
@media (max-width: 760px) {
  .bg-typescale__head { grid-template-columns: 1fr; }
  .bg-typescale__head .bg-typescale__colk { display: none; }
  .bg-typescale__row { grid-template-columns: 1fr; gap: clamp(8px, 1.4vh, 14px); }
}

/* ════════ BRAND ASSETS (pattern / illustration) ════════ */
.bg-pattern {
  max-width: var(--bg-maxw); margin: clamp(28px, 4vh, 48px) auto 0; padding-inline: var(--gutter);
}
.bg-pattern__strip {
  height: clamp(140px, 22vw, 240px); border-radius: 6px; background-color: var(--coffee);
  background-image: url("logos/symbol-white.svg"); background-size: clamp(46px, 6vw, 78px);
  background-repeat: space; opacity: 0.96;
}

/* ════════ BRAND IN ACTION — editorial gallery (true aspect ratios) ════════
   Each figure carries its image's exact ratio inline (e.g. aspect-ratio:1400/907),
   so object-fit:cover fills the frame with zero cropping — nothing is cut off.
   Two columns make every shot large; .ga-feature breaks to full width for the
   big, page-filling moments (gift card, tote, the pour). Portraits are paired by
   matching ratio so each row's two frames sit at the same height. */
.bg-gallery { max-width: none; margin: clamp(56px, 9vh, 110px) auto 0; }
.bg-gallery.visit-bento {
  display: grid; grid-template-columns: 1fr 1fr; align-items: start;
  gap: clamp(12px, 1.4vw, 22px); padding-inline: clamp(16px, 2.4vw, 40px);
}
.bg-gallery figure { margin: 0; aspect-ratio: 4 / 5; border-radius: 4px; cursor: zoom-in; }
.bg-gallery figure:hover img { transform: none; }
.bg-gallery figure:focus-visible { outline: 2px solid var(--dusk); outline-offset: 3px; }
body.cursor-hide, body.cursor-hide * { cursor: auto !important; }
.bg-gallery.visit-bento ~ .cursor-tag, .cursor-tag { display: none !important; }
.bg-gallery .ga-feature { grid-column: 1 / -1; }
/* this gallery's lightbox has no caption, so centre the image in the viewport instead of bottom-aligning it */
.lightbox.is-open { grid-template-rows: 1fr; grid-template-areas: "stage"; }
.lightbox__stage { align-items: center; }

/* closing / sign-off — a quiet full-screen end card on the cream canvas: the mark,
   a thank you, the line. Bookends the cover (which opens on the same bean mark). */
.bg-close {
  min-height: 88svh; max-width: var(--bg-maxw); margin: 0 auto;
  padding: clamp(70px, 13vh, 150px) var(--gutter);
  display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center;
  border-top: 1px solid var(--hair);
}
.bg-close__mark { width: clamp(74px, 9vw, 128px); height: auto; margin-bottom: clamp(26px, 4.6vh, 52px); }
.bg-close__thanks {
  font-family: var(--serif); font-weight: 400; font-size: clamp(3rem, 9vw, 7rem);
  line-height: 0.9; letter-spacing: -0.03em; color: var(--bean); margin: 0;
}
.bg-close__line {
  font-family: var(--serif); font-size: clamp(1.15rem, 2vw, 1.6rem); line-height: 1.3;
  color: color-mix(in srgb, var(--bean) 58%, transparent); max-width: 28ch;
  margin: clamp(18px, 3.2vh, 32px) auto 0;
}

/* small serif heading for the spacing section */
.bg-spacehead {
  font-family: var(--serif); font-weight: 400; font-size: clamp(1.6rem, 2.8vw, 2.3rem);
  line-height: 1; letter-spacing: -0.015em; color: var(--bean); text-align: center;
  margin: clamp(44px, 7vh, 88px) auto 0;
}
.bg-spacehead + .bg-note { margin-top: clamp(10px, 1.6vh, 18px); }
.bg-spacehead + .bg-note p { text-align: center; }

/* minimum-size examples */
.bg-minsize { max-width: 760px; margin: clamp(26px, 4vh, 44px) auto 0; padding-inline: var(--gutter); display: grid; grid-template-columns: 1fr 1fr; gap: clamp(18px, 2.6vw, 36px); }
.bg-minsize__item { margin: 0; }
.bg-minsize__art { min-height: clamp(110px, 15vh, 168px); display: flex; align-items: center; justify-content: center; padding: clamp(20px, 3vw, 34px); border: 1px solid var(--hair); border-radius: 6px; background: var(--flatwhite); }
.bg-minsize__art img { display: block; height: auto; }
.bg-minsize figcaption { margin-top: 12px; text-align: center; font-family: var(--mono); font-size: clamp(0.68rem, 0.85vw, 0.76rem); letter-spacing: 0.02em; color: var(--muted); }
@media (max-width: 560px) { .bg-minsize { grid-template-columns: 1fr; } }
/* minimum size as a section: text left, small example boxes right */
.bg-minsize-sec { max-width: min(1480px, 94vw); margin: clamp(18px, 2.6vh, 32px) auto 0; padding-inline: var(--gutter); display: grid; grid-template-columns: 1fr 1fr; gap: clamp(30px, 5vw, 80px); align-items: center; }
.bg-minsize-sec__title { font-family: var(--serif); font-weight: 400; font-size: clamp(1.6rem, 2.8vw, 2.3rem); line-height: 1; letter-spacing: -0.015em; color: var(--bean); margin-bottom: clamp(14px, 2vh, 22px); }
.bg-minsize-sec__text p { font-size: clamp(0.95rem, 1.1vw, 1.08rem); line-height: 1.6; color: color-mix(in srgb, var(--bean) 80%, transparent); max-width: 44ch; }
.bg-minsize-sec .bg-minsize { max-width: none; margin: 0; padding: 0; gap: clamp(14px, 1.8vw, 24px); }
.bg-minsize-sec .bg-minsize__art { min-height: clamp(86px, 11vh, 120px); padding: clamp(16px, 2vw, 24px); }
@media (max-width: 760px) { .bg-minsize-sec { grid-template-columns: 1fr; gap: clamp(24px, 4vh, 40px); } }

/* ════════ clearspace diagram (official spacing sheets, H = clearspace unit) — side by side ════════ */
.bg-clearspace {
  margin: clamp(48px, 7vh, 92px) auto 0; width: min(1120px, 96%);
  display: grid; grid-template-columns: 1.5fr 1fr; gap: clamp(20px, 3.4vw, 56px); align-items: center;
}
/* line-art on a cream-flooded canvas: no card, the sheet's own frame self-defines it */
.bg-clearspace__panel img { display: block; width: 100%; height: auto; }
.bg-clearspace__panel--hori { width: 100%; }
.bg-clearspace__panel--vert { width: 100%; }
.bg-clearspace__cap {
  grid-column: 1 / -1; margin: clamp(10px, 2vh, 22px) auto 0; max-width: 48ch;
  font-size: 0.84rem; line-height: 1.5; color: var(--muted); text-align: center;
}
@media (max-width: 720px) {
  .bg-clearspace { grid-template-columns: 1fr; gap: clamp(20px, 4vh, 40px); }
  .bg-clearspace__panel--vert { width: min(420px, 70%); margin-inline: auto; }
}
.bg-clearspace__x { color: var(--dusk); font-family: var(--mono); font-weight: 700; font-size: 1.3em; line-height: 1; }

/* ════════ chapter nav rail (desktop): number then label, one weight, one size ════════ */
.bg-nav {
  position: fixed; top: 50%; left: clamp(30px, 3.2vw, 56px); right: auto; transform: translateY(-50%);
  z-index: 60; display: flex; flex-direction: column; gap: 2px;
  padding: 10px 14px 10px 12px; margin-left: -12px; border-radius: 8px;
  background: transparent; transition: background-color 0.4s var(--bg-ease);
}
.bg-nav a {
  display: flex; align-items: baseline; gap: 10px; padding: 6px 0;
  font-family: var(--sans); font-weight: 500; font-size: 0.74rem; letter-spacing: 0.01em; line-height: 1;
  color: var(--muted); transition: color 0.35s var(--bg-ease);
}
.bg-nav a .n { order: -1; font-variant-numeric: tabular-nums; color: inherit; opacity: 0.7; width: 1.7em; transition: opacity 0.35s var(--bg-ease); }
.bg-nav a:hover { color: var(--bean); }
.bg-nav a:hover .n { opacity: 1; }
.bg-nav a.is-active { color: var(--dusk); }
.bg-nav a.is-active .n { opacity: 1; }
@media (max-width: 1023px) { .bg-nav { display: none; } }

/* over the mockups, the rail logo and chapter nav sit on a soft cream backing so they
   read on any photo (brand.js toggles .is-over-photo when they overlap a gallery figure) */
.rail-logo { padding: 8px 12px; margin: -8px -12px; border-radius: 8px; background: transparent; transition: background-color 0.4s var(--bg-ease); }
.rail-logo.is-over-photo, .bg-nav.is-over-photo {
  background: color-mix(in srgb, var(--linen) 90%, transparent);
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
}

/* progress fill: full-height element scaled on the compositor (transform only) for a smooth,
   eased glide. brand.js drives scaleY; overrides the shared height-based fill from styles.css. */
.scrollbar__fill { height: 100%; transform-origin: top center; transform: scaleY(0); will-change: transform; }

/* flat-white duplicate, revealed by JS clip-path only where it sits over a dark
   section. Unselected items go Flat White, the active item goes Honey. */
.bg-nav--white { z-index: 61; pointer-events: none; clip-path: inset(50% 0 50% 0); }
.bg-nav--white a { color: var(--flatwhite); }
.bg-nav--white a .n { opacity: 0.85; }
.bg-nav--white a.is-active { color: var(--honey); }
.bg-nav--white a.is-active .n { opacity: 1; }

/* rail-logo flips to white over a dark section */
.rail-logo__color, .rail-logo .rail-logo__white { transition: opacity 0.35s var(--bg-ease); }
.rail-logo.is-dark .rail-logo__color { opacity: 0; }
.rail-logo.is-dark .rail-logo__white { opacity: 1; }

/* ════════ responsive ════════ */
@media (max-width: 880px) {
  /* cover: drop the lede + mark back into flow, left-aligned and stacked */
  .bg-cover__main { gap: clamp(30px, 6vh, 52px); }
  .bg-cover__lede { position: static; bottom: auto; gap: clamp(16px, 3vh, 30px); }
  .bg-cover__wordmark { width: clamp(140px, 34vw, 220px); }
  .bg-cover__mark { position: static; transform: none; align-items: flex-start; gap: clamp(12px, 2vh, 18px); margin-top: clamp(6px, 2vh, 18px); }
  .bg-cover__bean { width: clamp(132px, 30vw, 200px); }
  .bg-cover__facts { align-self: flex-start; align-items: flex-start; text-align: left; }
  .bg-da { grid-template-columns: 1fr; height: auto; }
  .bg-da__media { aspect-ratio: 3 / 4; height: auto; max-height: 60vh; margin: clamp(20px, 5vw, 34px) auto; }
  .bg-da__values { grid-template-columns: repeat(3, 1fr); gap: 14px; }
  .bg-cols { grid-template-columns: 1fr; gap: 28px; }
  .bg-logos { grid-template-columns: 1fr; }
  .bg-misuse { grid-template-columns: repeat(2, 1fr); }
  .bg-sw3 { grid-template-columns: repeat(2, 1fr); }
  .bg-pairs { grid-template-columns: repeat(2, 1fr); }
  .bg-spec { grid-template-columns: 1fr; gap: 22px; }
  .bg-gallery.visit-bento { grid-template-columns: 1fr; gap: clamp(16px, 4vw, 26px); }
}
@media (max-width: 520px) {
  .bg-sw3, .bg-sw2 { grid-template-columns: 1fr; }
  .bg-misuse { grid-template-columns: 1fr; }
}

/* ════════ reduced motion ════════ */
@media (prefers-reduced-motion: reduce) {
  html:not(.no-js) [data-reveal] { opacity: 1; transform: none; }
}
