/* Human Practices story page: chapters, conversation cards, session cards, figures, map chips and the map's frame.
   Loaded after site.css, only on pages that carry the Encounter Map. Same type (Baloo 2 + Nunito Sans), same colours,
   nothing under 15px. The Encounter Map's own styles are in encounter-map/map.css (generated by build.mjs). */

.article-story{counter-reset:chapter}

/* ── headings ─────────────────────────────────────────────────────── */
.article-story .article-section h3{margin:2.3em 0 .55em;font-size:clamp(1.55rem,2.5vw,2.05rem);letter-spacing:-.005em;text-wrap:balance}
.article-story .chapter-head+h3,.article-story .map-row+h3,.article-story .story-part>h2+p+h3{margin-top:1.3em}
.article-story .article-section code{font-family:var(--font-text);font-weight:700;font-size:.94em;padding:.08em .5em;border-radius:8px;background:var(--accent-soft);color:var(--ink);white-space:nowrap}
.article-story .article-section strong{color:var(--ink)}
.article-story .article-section a{font-weight:700}

/* A chapter opens with a large spectrum numeral, its title, a subtitle and a one-line epigraph. */
.chapter-head{margin-bottom:clamp(18px,2.6vw,30px)}
.chapter-head.no-num::before{content:none;counter-increment:none;display:none}
.chapter-head::before{counter-increment:chapter;content:counter(chapter,decimal-leading-zero);display:block;margin:0 0 .12em -.04em;font:800 clamp(3.6rem,8vw,6.2rem)/.9 var(--font-display);background:var(--spectrum);-webkit-background-clip:text;background-clip:text;color:transparent}
.chapter-head h2{margin-bottom:12px}
.article-section .chapter-sub{margin:0 0 6px;font:700 clamp(1.25rem,2vw,1.6rem)/1.25 var(--font-display);color:var(--accent);max-width:none}
.article-section .chapter-epi{margin:0;font-size:1.1875rem;font-style:italic;color:var(--muted);max-width:40em}
.article-section.chapter{padding-top:clamp(48px,6vw,88px)}

/* ── a key question and a key statement ───────────────────────────── */
.article-section .ask{margin:1.9em 0;max-width:44em;padding:22px 28px 22px 32px;border-radius:var(--radius-sm);background:var(--accent-soft);border-left:6px solid var(--green)}
.article-section .ask p{margin:0;max-width:none;font:700 clamp(1.2rem,1.9vw,1.45rem)/1.4 var(--font-display);color:var(--ink)}
.article-section .say{position:relative;margin:2.1em 0;padding:clamp(26px,3.6vw,44px);max-width:50em;border-radius:var(--radius);background:linear-gradient(120deg,#0B2A40,#0E3A52 58%,#0A3E9E);overflow:hidden}
.article-section .say p{margin:0;padding-right:40px;max-width:30em;font:700 clamp(1.3rem,2.3vw,1.8rem)/1.38 var(--font-display);color:#fff}
.say::after{content:"";position:absolute;right:26px;top:26px;width:14px;height:14px;border-radius:50%;background:var(--amber);box-shadow:0 0 0 7px rgba(248,166,33,.25)}

/* ── idea chips, journey, numbered questions, checklist ───────────── */
.article-section .idea-tags{display:flex;flex-wrap:wrap;gap:10px;margin:1.5em 0;max-width:none}
.article-section .idea-tags li{padding:9px 20px 9px 38px;border-radius:999px;background:var(--surface);border:1px solid var(--line);font-weight:700;color:var(--ink)}
.article-section .idea-tags li::before{left:16px;top:50%;width:12px;height:12px;translate:0 -50%}
.article-section .idea-tags li:nth-child(3n+2)::before{background:var(--teal)}
.article-section .idea-tags li:nth-child(3n)::before{background:var(--blue)}


.article-section .q-steps{counter-reset:q;display:grid;gap:12px;margin:1.6em 0;padding:0;list-style:none;max-width:46em}
.article-section .q-steps li{counter-increment:q;position:relative;padding:18px 24px 18px 80px;border-radius:var(--radius-sm);background:var(--surface);border:1px solid var(--line);font:700 1.2rem/1.4 var(--font-display);color:var(--ink)}
.article-section .q-steps li::before{content:counter(q);left:20px;top:50%;translate:0 -50%;width:42px;height:42px;display:grid;place-items:center;border-radius:50%;background:var(--spectrum);color:#fff;font:800 1.2rem/1 var(--font-display)}

.article-section .journey{counter-reset:step;display:grid;gap:0;margin:1.7em 0;padding:0;list-style:none;max-width:46em}
.article-section .journey li{counter-increment:step;position:relative;display:block;margin:0;padding:3px 0 18px 50px;border:0;border-radius:0;background:none;box-shadow:none}
.article-section .journey li::before{content:counter(step);position:absolute;left:0;top:0;translate:none;width:34px;height:34px;display:grid;place-items:center;border-radius:50%;background:var(--spectrum);color:#fff;font:800 1.05rem/1 var(--font-display)}
.article-section .journey li:not(:last-child)::after{content:"";position:absolute;left:16px;top:40px;bottom:4px;width:2px;border-radius:2px;background:linear-gradient(180deg,var(--teal),var(--line))}
.article-section .journey li:last-child{padding-bottom:0}
.journey strong{font:700 1.15rem/1.4 var(--font-display);color:var(--ink)}
.journey strong::after{content:" \2014\00a0";font-weight:400;color:var(--muted)}
.journey span{line-height:1.6}
.article-section .checks{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,250px),1fr));gap:12px;margin:1.6em 0;padding:0;list-style:none;max-width:none}
.article-section .checks li{padding:6px 0 6px 40px;border:0;border-radius:0;background:none;box-shadow:none;font-weight:600;color:var(--ink)}
.article-section .checks li::before{left:0;top:50%;translate:0 -50%;width:26px;height:26px}
.article-section .checks li::after{content:"";position:absolute;left:10px;top:calc(50% - 7px);width:6px;height:12px;border:solid #fff;border-width:0 3px 3px 0;transform:rotate(45deg)}

/* ── cards: three layers, who helped with what ────────────────────── */
.article-section .layers{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,260px),1fr));gap:18px 30px;margin:1.7em 0;max-width:none}
.layer{padding:2px 0 2px 18px;border:0;border-left:3px solid var(--teal);border-radius:0;background:none}
.layer h4{display:flex;align-items:center;gap:10px;margin:0 0 6px;font:700 1.18rem/1.25 var(--font-display);color:var(--ink)}
.layer h4 span{flex:none;display:grid;place-items:center;width:34px;height:34px;border-radius:50%;background:var(--spectrum);color:#fff;font:800 1.1rem/1 var(--font-display)}
.article-section .layer p{margin:0;max-width:none}
.layers-plain .layer{border-left-color:var(--green)}
.layers-plain .layer:nth-child(2){border-left-color:var(--teal)}
.layers-plain .layer:nth-child(3){border-left-color:var(--blue)}
/* 2 x 2 grids with a colour per card (SWOT) */
.article-section .layers-2{grid-template-columns:repeat(2,minmax(0,1fr));gap:20px;align-items:stretch}
@media (max-width:720px){.article-section .layers-2{grid-template-columns:1fr}}
.article-section .layers-3{grid-template-columns:repeat(3,minmax(0,1fr));gap:18px 22px;align-items:stretch}
@media (max-width:860px){.article-section .layers-3{grid-template-columns:1fr}}
.article-section .layers-2 .layer{--tone:var(--teal);padding:18px 20px 18px 22px;border-left:5px solid var(--tone);border-radius:0 var(--radius-sm,14px) var(--radius-sm,14px) 0;background:color-mix(in srgb,var(--tone) 11%,transparent)}
.article-section .layers-2 .layer h4{margin:0 0 4px}
.layers-2 .layer.tone-s{--tone:var(--green)}
.layers-2 .layer.tone-w{--tone:var(--amber)}
.layers-2 .layer.tone-o{--tone:var(--blue)}
.layers-2 .layer.tone-t{--tone:#e5645a}
.layer .badge{flex:none;display:grid;place-items:center;min-width:38px;height:38px;padding:0 11px;border-radius:19px;background:var(--tone,var(--teal));color:#0b1f33;font:800 1.15rem/1 var(--font-display);letter-spacing:.03em}
.layer.tone-o .badge{color:#fff}
.article-section .layer ol{margin:10px 0 0;padding:0 0 0 1.35em;display:grid;gap:8px;list-style:decimal;max-width:none}
.article-section .layer ol li{padding:0 0 0 2px;background:none;border:0;border-radius:0;line-height:1.5}
.article-section .layer ol li::before{content:none}
.layer ol li::marker{color:var(--tone,var(--teal));font-weight:800}
.fig.fig-paper img{background:#fff}


.article-section .who{display:grid;gap:10px;margin:1.7em 0;padding:0;list-style:none;max-width:none}
.article-section .who li{display:grid;grid-template-columns:minmax(0,17em) minmax(0,1fr);gap:4px 28px;align-items:baseline;padding:18px 26px;border-radius:var(--radius-sm);background:var(--surface);border:1px solid var(--line)}
.article-section .who li::before{display:none}
.who strong{font:700 1.2rem/1.3 var(--font-display);color:var(--ink)}
.who span::before{content:"→ ";color:var(--accent);font-weight:700}

/* ── figures ──────────────────────────────────────────────────────── */
.article-story .fig{margin:2.1em 0}
.fig img{display:block;width:100%;height:auto;border-radius:var(--radius);background:var(--surface-2);border:1px solid var(--line)}
.fig figcaption{margin-top:12px;max-width:50em;color:var(--muted);font-size:1rem;line-height:1.55}
/* pictures with small print keep a minimum width and scroll sideways on a phone (story-blocks.mjs, `scroll`) */
.fig-scroll{overflow-x:auto;-webkit-overflow-scrolling:touch;border-radius:var(--radius)}
.fig-scroll img{width:100%;max-width:none;min-width:var(--min,0)}
:root[data-theme=dark] .fig-scroll img{filter:brightness(.9)}   /* charts and forms have a white page: soften them on the dark theme */
.fig-medium{max-width:780px}
.fig-small{max-width:340px}
.gallery{display:grid;gap:16px;margin:2.1em 0}
.article-story .gallery .fig{margin:0}
.gallery-3{grid-template-columns:repeat(3,minmax(0,1fr))}
.gallery-3 img{aspect-ratio:4/3;object-fit:cover}
.gallery-pair{grid-template-columns:repeat(2,minmax(0,1fr))}
.gallery-pair img{border:1px solid var(--line)}
.gallery-cards{grid-template-columns:repeat(3,minmax(0,1fr));align-items:start}
.gallery-cards img{border:1px solid var(--line);border-radius:8px}
/* `layout: 'row'`: photos side by side at one height, each as wide as its own shape asks (nothing cropped) */
.gallery-row{display:flex;gap:16px;align-items:flex-start}
.gallery-row .fig{flex:var(--ar,1) 1 0;min-width:0}
/* `side: true`: on a wide screen the photo sits beside the text that follows it, instead of on a row of its own */
@media (min-width:901px){
  .article-story .fig-side{float:right;clear:right;width:min(44%,420px);margin:.4em 0 1.4em 32px}
  .article-story .fig-side ~ :is(.ask,.qwrap,.journey,.layers,.gallery,.callout,.table-scroll,.stats,h3,figure:not(.fig-side),.embed){clear:both}
  .article-story :has(> .fig-side)::after{content:"";display:block;clear:both}
}

/* ── a conversation: the interviews and replies ───────────────────── */
.article-section .encounter{position:relative;margin:2.4em 0;padding:clamp(26px,3.6vw,44px) clamp(22px,3.6vw,44px) clamp(24px,3.2vw,38px);border-radius:var(--radius);background:var(--surface);border:1px solid var(--line);box-shadow:var(--shadow)}
.encounter::before{content:"";position:absolute;left:0;top:34px;bottom:34px;width:6px;border-radius:0 6px 6px 0;background:var(--spectrum)}
.encounter header{margin-bottom:16px}
.when{display:flex;flex-wrap:wrap;align-items:center;gap:8px 10px;margin:0 0 10px}
.article-section .when{margin:0 0 10px;max-width:none}
.when time,.when span{display:inline-block;padding:3px 14px;border-radius:999px;background:var(--accent-soft);color:var(--ink);font-weight:700;font-size:1rem;line-height:1.5}
.when time::before{content:"";display:inline-block;width:9px;height:9px;margin-right:9px;border-radius:50%;background:var(--amber)}
.when span{background:transparent;border:1px solid var(--line);color:var(--muted)}
.article-story .encounter h3{margin:0;font-size:clamp(1.5rem,2.5vw,2.1rem)}
.article-section .enc-body p{max-width:44em}
.article-section .enc-body .say{margin:1.4em 0 .4em}
.encounter .map-row{margin:1.7em 0 0;padding-top:18px;border-top:1px dashed var(--line)}

/* ── education session cards ──────────────────────────────────────── */
.sessions{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,300px),1fr));gap:18px;margin:2.1em 0}
.session{display:flex;flex-direction:column;gap:12px;padding:26px 26px 22px;border-radius:var(--radius);background:var(--surface);border:1px solid var(--line)}
.session h4{margin:0;font:700 1.4rem/1.2 var(--font-display);color:var(--ink)}
.session dl{display:grid;gap:16px;margin:4px 0 0}
.session dt{margin:0 0 2px;font:700 1.0625rem/1.3 var(--font-display);color:var(--accent)}
.session dd{margin:0;line-height:1.6}
.article-section .session .map-row{margin:auto 0 0;padding-top:16px;border-top:1px dashed var(--line)}

/* ── the question → insight → change table ────────────────────────── */
.changes{margin:2.1em 0}
.changes tbody th{min-width:11.5em;background:transparent;white-space:normal;font:700 1.125rem/1.35 var(--font-display);color:var(--ink);vertical-align:top}
.changes td{vertical-align:top;line-height:1.55}
.changes .changes-map{min-width:11em}
.changes .changes-map .map-chip{margin:0 6px 8px 0}
.changes tbody tr:nth-child(even){background:color-mix(in srgb,var(--surface-2) 45%,transparent)}
@media (max-width:900px){
  .changes table,.changes tbody,.changes tr,.changes td,.changes tbody th{display:block}
  .changes thead{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0)}
  .changes tr{padding:18px 0;border-bottom:1px solid var(--line)}
  .changes tr:last-child{border-bottom:0}
  .changes tbody th,.changes td{padding:6px 20px;border:0}
  .changes td::before{content:attr(data-label);display:block;margin-bottom:2px;font-weight:700;font-size:1rem;color:var(--accent)}
  .changes td.changes-map{padding-top:10px}
  .changes td.changes-map:empty{display:none}
}

/* ── map chips: every one finds a moment on the Encounter Map ─────── */
.map-row{display:flex;flex-wrap:wrap;align-items:center;gap:8px 10px}
.article-section .map-row,.story-map .map-row{margin:0 0 1.7em;max-width:none}
.map-row>span{margin-right:2px;color:var(--muted);font-weight:700}
.map-chip{--lc:#5E7FA0;display:inline-flex;align-items:center;gap:8px;padding:5px 15px 5px 12px;border-radius:999px;border:1.5px solid color-mix(in srgb,var(--lc) 52%,var(--line));background:color-mix(in srgb,var(--lc) 9%,var(--surface));color:var(--ink);font-size:1rem;font-weight:700;line-height:1.35;text-decoration:none;transition:background .2s,border-color .2s,transform .2s}
.map-chip i{flex:none;width:10px;height:10px;border-radius:50%;background:var(--lc)}
.map-chip[data-type=chg] i{width:9px;height:9px;border-radius:2px;rotate:45deg}
.map-chip:hover{background:color-mix(in srgb,var(--lc) 20%,var(--surface));border-color:var(--lc);transform:translateY(-1px)}
.map-chip[data-lane=field]{--lc:#5E7FA0}
.map-chip[data-lane=expert]{--lc:#0755D9}
.map-chip[data-lane=exchange]{--lc:#00ABB6}
.map-chip[data-lane=edu]{--lc:#17B471}
.map-chip[data-lane=collab]{--lc:#EF4565}
.map-chip[data-lane=turn]{--lc:#F8A621}
:root[data-theme=dark] .map-chip[data-lane=field]{--lc:#8FB0CF}
:root[data-theme=dark] .map-chip[data-lane=expert]{--lc:#4C8DFF}
:root[data-theme=dark] .map-chip[data-lane=exchange]{--lc:#19C3CE}
:root[data-theme=dark] .map-chip[data-lane=edu]{--lc:#2FDC92}
:root[data-theme=dark] .map-chip[data-lane=collab]{--lc:#FF6B88}
:root[data-theme=dark] .map-chip[data-lane=turn]{--lc:#F8B53A}

/* ── the Encounter Map, placed near the top of the page ───────────── */
.story-map{padding:clamp(40px,5vw,72px) 0;border-top:1px solid var(--line)}
.story-map h2{font-size:clamp(2.1rem,3.6vw,3.25rem);margin-bottom:22px;letter-spacing:-.01em}
.story-map p{margin:0 0 1.1em;max-width:46em}
.map-frame{--hpm-h:clamp(580px,calc(100vh - 110px),820px);margin:1.8em 0 2em;border-radius:var(--radius);border:1px solid var(--line);box-shadow:var(--shadow);overflow:hidden;background:var(--surface)}
.map-frame .hpm{border-radius:0}
/* the page's own light/dark switch (header) also drives the map, so the map's own theme button steps aside */
.map-frame .hpm [data-act=theme],.map-frame .hpm [data-act=lang]{display:none}
html:not(.js) .map-frame .hpm{display:none}
.story-map .map-fallback{margin:0;padding:28px}

/* ── cards for the interactive tools (Atlas, Chemotaxis game) ──────── */
.toolcards{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,300px),1fr));gap:18px;margin:2em 0}
.toolcard{display:flex;flex-direction:column;align-items:flex-start;gap:10px;padding:28px 28px 26px;border-radius:var(--radius);background:var(--surface);border:1px solid var(--line);border-top:5px solid var(--teal)}
.toolcard:nth-child(2){border-top-color:var(--green)}
.article-section .toolcard h3{margin:0;font-size:clamp(1.45rem,2.2vw,1.8rem)}
.toolcard-kicker{margin:0;color:var(--accent);font-weight:700}
.article-section .toolcard p{margin:0;max-width:none}
.article-section .toolcard .toolcard-tags{display:flex;flex-wrap:wrap;gap:8px;margin-top:2px}
.toolcard-tags span{padding:3px 12px;border-radius:999px;border:1px solid var(--line);color:var(--muted);font-size:1rem;font-weight:600}
.toolcard-link{margin-top:auto;display:inline-flex;align-items:center;gap:8px;padding:12px 24px;border-radius:999px;background:var(--green);color:var(--navy);font-weight:800;text-decoration:none;transition:background .2s,transform .2s}
.toolcard-link::after{content:"→"}
.toolcard-link:hover{background:var(--mint);transform:translateY(-2px)}
.toolcard-kicker+h3{margin-top:-2px}

/* ── closing line ─────────────────────────────────────────────────── */
.finale{position:relative;margin:clamp(40px,6vw,76px) 0 0;padding:clamp(48px,8vw,104px) clamp(24px,5vw,64px);border-radius:var(--radius);text-align:center;background:linear-gradient(135deg,#0B2A40,#0E3A52 55%,#0A3E9E);overflow:hidden}
.finale::before{content:"";display:block;width:16px;height:16px;margin:0 auto 26px;border-radius:50%;background:var(--amber);box-shadow:0 0 0 9px rgba(248,166,33,.25)}
.article-section .finale-line{margin:0 auto;max-width:14em;font:800 clamp(2.2rem,5.4vw,4.2rem)/1.04 var(--font-display);text-wrap:balance;background:linear-gradient(100deg,#7EF0C4,#4FD3E0 55%,#8FB8FF);-webkit-background-clip:text;background-clip:text;color:transparent}
.article-section .finale-sub{margin:20px auto 0;max-width:none;font-size:clamp(1.15rem,1.8vw,1.4rem);font-style:italic;color:rgba(255,255,255,.88)}

@media (max-width:900px){
  .gallery-3{grid-template-columns:minmax(0,1fr)}
  .gallery-3 img{aspect-ratio:3/2}
  .gallery-pair{grid-template-columns:minmax(0,1fr)}
  .gallery-row{flex-direction:column}
  .gallery-cards{grid-template-columns:repeat(2,minmax(0,1fr))}
  .article-section .who li{grid-template-columns:minmax(0,1fr)}
}
@media (max-width:640px){
  .article-section .encounter{padding:24px 20px}
  .encounter::before{top:24px;bottom:24px}
  .map-frame{--hpm-h:clamp(560px,calc(100vh - 90px),760px);margin-inline:calc(var(--gutter) * -.5)}
}
@media print{.map-frame{display:none}}

/* ── emphasis: highlighter, a larger opening line, boxed notes, numbers ───────────── */
/* Not on .article-story itself: containment there would scope the chapter counter and restart the numbering. */
.qwrap{container:story/inline-size}
.article-story mark{background:linear-gradient(transparent 58%,color-mix(in srgb,var(--amber) 42%,transparent) 58%);color:inherit;padding:0 .12em;border-radius:3px;-webkit-box-decoration-break:clone;box-decoration-break:clone}
.article-section .lead-p{margin:0 0 1.1em;max-width:34em;font:600 clamp(1.3rem,2.1vw,1.6rem)/1.45 var(--font-text);color:var(--ink)}

.article-section .callout{--tone:var(--ocean);position:relative;display:grid;grid-template-columns:30px minmax(0,1fr);gap:16px;margin:2em 0;max-width:46em;padding:18px 24px 18px 22px;border-radius:var(--radius-sm);border:0;background:color-mix(in srgb,var(--tone) 8%,var(--surface));overflow:hidden}
.callout::before{content:"";position:absolute;inset:0 auto 0 0;width:5px;background:var(--tone)}
.article-section .callout-signal{--tone:var(--amber)}
.article-section .callout-tip{--tone:var(--jade)}
.callout-icon{width:30px;height:30px;margin-top:2px;border-radius:50%;background:var(--tone);position:relative}
.callout-icon::after{content:"";position:absolute;inset:-5px;border-radius:50%;border:2px solid var(--tone);opacity:.5}
.callout-signal .callout-icon::after{animation:callout-ping 2.6s ease-out infinite}
@keyframes callout-ping{from{transform:scale(.7);opacity:.7}to{transform:scale(1.5);opacity:0}}
.article-section .callout p{margin:0;max-width:none}
.article-section .callout .callout-title{margin:0 0 4px;font:700 1.2rem/1.3 var(--font-display);color:var(--ink)}

.article-section .stats{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,170px),1fr));gap:18px 26px;margin:2em 0;max-width:none}
.stat{display:flex;flex-direction:column-reverse;justify-content:flex-end;padding:2px 0 2px 16px;border-left:3px solid var(--teal)}
.stat dd{margin:0;font:800 clamp(2.6rem,5vw,3.6rem)/1 var(--font-display);background:var(--spectrum);-webkit-background-clip:text;background-clip:text;color:transparent}
.stat dd small{font-size:.38em;font-weight:700}
.stat dt{margin-top:8px;color:var(--muted);line-height:1.45}

/* split: one whole, in parts */
.split{margin:2em 0;padding:20px 24px;border-radius:var(--radius);background:var(--surface);border:1px solid var(--line)}
.split-title{margin:0 0 12px;font:700 1.15rem/1.3 var(--font-display);color:var(--ink)}
.split-bar{display:flex;gap:3px;height:44px;border-radius:12px;overflow:hidden}
.split-bar i{display:grid;place-items:center;min-width:2.2em;font:800 1.1rem/1 var(--font-display);font-style:normal;color:#fff}
.split-0{--c:#9aa7b4}.split-1{--c:var(--teal)}.split-2{--c:#e8893a}.split-3{--c:#7a5cc4}
.split-bar i{background:var(--c)}
.split-key{display:flex;flex-wrap:wrap;gap:8px 22px;margin:14px 0 0;padding:0;list-style:none;color:var(--muted)}
.article-section .split-key li{display:flex;align-items:baseline;gap:6px;margin:0;padding:0;border:0;border-radius:0;background:none;box-shadow:none}
.article-section .split-key li::before{position:static;inset:auto;transform:none;content:"";flex:none;width:12px;height:12px;border-radius:3px;background:var(--c);align-self:center}
.split-key strong{color:var(--ink)}
.split figcaption,.hbars figcaption{margin-top:10px;color:var(--muted)}
.hbars{margin:2em 0;padding:20px 24px;border-radius:var(--radius);background:var(--surface);border:1px solid var(--line)}
.hbars ul{display:grid;gap:10px;margin:0;padding:0;list-style:none}
.article-section .hbars li{display:grid;grid-template-columns:minmax(0,15em) minmax(0,1fr) 2.2em;align-items:center;gap:12px;margin:0;padding:0;border:0;background:none;box-shadow:none}
.article-section .hbars li::before{content:none}
.hb-name{line-height:1.35}
.hb-track{height:16px;border-radius:8px;background:var(--line)}
.hb-track i{display:block;height:100%;border-radius:8px;background:var(--teal)}
.hb-n{font:800 1.1rem/1 var(--font-display);color:var(--ink);text-align:right}
/* pairs: two arms, several measures, each on its own scale */
.pairs{margin:2em 0;padding:20px 24px;border-radius:var(--radius);background:var(--surface);border:1px solid var(--line)}
.pairs-key{display:flex;flex-wrap:wrap;gap:8px 22px;margin:0 0 14px;color:var(--muted)}
.pairs-key span{display:flex;align-items:center;gap:6px}
.pairs-key span::before{content:"";width:12px;height:12px;border-radius:3px;background:var(--c)}
.pair-a{--c:var(--teal)}.pair-b{--c:#9aa7b4}
.pairs-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(15em,1fr));gap:18px 28px}
.pair-name{margin:0 0 6px;font-weight:700;line-height:1.35;color:var(--ink)}
.pair-x{margin-left:4px;padding:1px 8px;border-radius:999px;background:var(--teal);color:#fff;font:800 1rem/1.4 var(--font-display)}
.pair-row{display:grid;grid-template-columns:minmax(0,1fr) 4.6em;align-items:center;gap:10px;margin-top:5px}
.pair-track{height:16px;border-radius:8px;background:var(--line)}
.pair-track i{display:block;height:100%;border-radius:8px;background:var(--c)}
.pair-row strong{font:800 1.05rem/1 var(--font-display);color:var(--ink);text-align:right}
.pairs figcaption{margin-top:12px;color:var(--muted)}
@media (max-width:640px){.article-section .hbars li{grid-template-columns:minmax(0,1fr) 2.2em;gap:4px 12px}.hb-name{grid-column:1/-1}}

/* "What it changed": the point of each conversation, in one line */
.article-section .enc-changed{display:grid;gap:4px;margin:1.7em 0 0;max-width:none;padding:16px 22px;border-radius:var(--radius-sm);background:color-mix(in srgb,var(--amber) 12%,var(--surface));border:1px solid color-mix(in srgb,var(--amber) 38%,var(--line))}
.enc-changed strong{font:700 1.0625rem/1.3 var(--font-display);color:var(--ink)}
.enc-changed strong::before{content:"→ ";color:var(--accent)}
.enc-changed span{line-height:1.55}

.page-chip{display:inline-flex;align-items:center;gap:7px;padding:5px 14px;border-radius:999px;border:1.5px dashed color-mix(in srgb,var(--accent) 45%,var(--line));color:var(--ink);font-size:1rem;font-weight:700;line-height:1.35;text-decoration:none;transition:background .2s,border-color .2s}
.page-chip::after{content:"→";color:var(--accent)}
.page-chip:hover{border-color:var(--accent);background:var(--accent-soft)}
.changes .changes-map .page-chip{margin:0 6px 8px 0}
.go-row{display:flex;flex-wrap:wrap;gap:10px;margin:1.4em 0}

/* ── dated sessions as a timeline ─────────────────────────────────── */
.article-section .sessions{position:relative;display:grid;grid-template-columns:minmax(0,1fr);gap:22px;margin:2.1em 0 2.1em 8px;padding:0 0 0 30px;list-style:none;max-width:none;border-left:2px dashed color-mix(in srgb,var(--teal) 50%,var(--line))}
.article-section .sessions>li{position:relative;display:block;padding:24px 26px 22px;border-radius:var(--radius);background:var(--surface);border:1px solid var(--line)}
.article-section .sessions>li::before{content:"";left:-41px;top:32px;width:16px;height:16px;border-radius:50%;background:var(--surface);border:3px solid var(--teal)}
.article-section .sessions>li:last-child::before{background:var(--amber);border-color:var(--amber);box-shadow:0 0 0 6px rgba(248,166,33,.25)}
.sessions h4{margin:6px 0 14px}
.session dl{grid-template-columns:repeat(auto-fit,minmax(min(100%,260px),1fr));gap:18px 28px}

@media (max-width:760px){.fig-scroll+figcaption::after{content:" Swipe the picture sideways to see all of it.";color:var(--accent);font-weight:600}}
@media (max-width:640px){
  .article-section .sessions{margin-left:3px;padding-left:20px}
  .article-section .sessions>li{padding:20px 18px 18px}
  .article-section .sessions>li::before{left:-31px;top:26px}
}

/* ── the flow of steps adapts to the width of the page column, not the window ─────── */

/* ── a tool shown in place (iframe): the Atlas, the chemotaxis game ─────────────────── */
.embed{margin:2.1em 0}
.embed-frame{height:var(--h,640px);max-height:88vh;border-radius:var(--radius);overflow:hidden;border:1px solid var(--line);background:var(--surface-2);box-shadow:var(--shadow)}
.embed-frame iframe{display:block;width:100%;height:100%;border:0;background:#fff}
.embed figcaption{margin-top:12px;max-width:50em;color:var(--muted);font-size:1rem;line-height:1.55}
.embed-open{font-weight:700;white-space:nowrap}
@media (max-width:640px){.embed-frame{max-height:80vh;border-radius:var(--radius-sm)}}
@media print{.embed-frame{display:none}}

/* ── folds: running text behind a question (compact pages) ──────────────────────────────────────────── */
.article-section .fold{margin:1.8em 0;border:1px solid var(--line);border-radius:var(--radius-sm);background:var(--surface)}
.fold>summary{cursor:pointer;padding:16px 22px;font:700 1.15rem/1.35 var(--font-display);color:var(--ink);list-style:none;display:flex;align-items:center;gap:12px}
.fold>summary::-webkit-details-marker{display:none}
/* the arrow: a circle with a chevron that points right when closed and turns down when open; a small "Open" / "Close" pill says what a click does */
.fold-cue{position:relative;display:grid;place-items:center;flex:none;width:30px;height:30px;border-radius:50%;background:var(--spectrum);transition:transform .25s ease}
.fold-cue::before{content:"";width:9px;height:9px;border-right:3px solid #fff;border-bottom:3px solid #fff;transform:translateX(-2px) rotate(-45deg);transition:transform .28s cubic-bezier(.2,.7,.2,1)}
.fold[open]>summary .fold-cue::before{transform:translateY(-2px) rotate(45deg)}
.fold>summary::after{content:"Open";content:"Open" / "";flex:none;margin-left:auto;padding:6px 14px;border-radius:999px;background:var(--accent-soft);color:var(--accent);font:700 .9375rem/1 var(--font-text);transition:background-color .2s ease}
.fold[open]>summary::after{content:"Close";content:"Close" / ""}
.fold>summary:hover::after{background:color-mix(in srgb,var(--accent) 20%,transparent)}
.fold>summary:hover .fold-cue{transform:scale(1.1)}
.fold:not(.enc-fold)>summary:hover{background:color-mix(in srgb,var(--accent-soft) 55%,transparent);border-radius:var(--radius-sm)}
.fold:not(.enc-fold)[open]>summary:hover{border-bottom-left-radius:0;border-bottom-right-radius:0}
.enc-fold>summary .fold-cue{width:26px;height:26px}
/* a closed fold that has just come into view nudges its arrow a few times, then rests */
@keyframes foldNudge{0%,55%,100%{transform:translateX(-2px) rotate(-45deg)}28%{transform:translateX(3px) rotate(-45deg)}}
@keyframes foldRing{0%{box-shadow:0 0 0 0 color-mix(in srgb,var(--teal) 60%,transparent)}75%,100%{box-shadow:0 0 0 13px transparent}}
@media (prefers-reduced-motion:no-preference){
  .fold.is-in:not([open])>summary .fold-cue{animation:foldRing 1.7s ease-out .9s 3}
  .fold.is-in:not([open])>summary .fold-cue::before{animation:foldNudge 1.7s ease-in-out .9s 3}
}
@media (prefers-reduced-motion:reduce){.fold-cue,.fold-cue::before,.fold>summary::after{transition:none}}
@media (max-width:520px){.fold>summary::after{display:none}.fold>summary{padding:14px 16px;gap:10px}}
@media print{.fold>summary::after,.fold-cue{display:none}}
.fold-body{padding:0 clamp(16px,2.4vw,28px) 20px}
.fold-body>:first-child{margin-top:.4em}
@media print{.fold:not([open])>.fold-body{display:block}.fold::details-content,.enc-fold::details-content{content-visibility:visible!important;display:block!important;height:auto!important}}
.article-section .fold-text{margin:1.1em 0 1.7em;border-color:color-mix(in srgb,var(--teal) 28%,var(--line))}
.fold-text>summary{padding:14px 20px;font-size:1.1rem}
.fold-text[open]{background:var(--bg)}
.fold-text .fold-body{padding-bottom:12px}
.fold-text .fold-body>p{max-width:44em}
.article-section .enc-fold{margin:.3em 0 0;border:0;border-top:1px dashed var(--line);border-radius:0;background:none}
.enc-fold>summary{padding:14px 0 6px;font-size:1.0625rem}
.enc-fold .fold-body{padding:0 0 4px}
.fold>summary:hover{color:var(--accent)}
.fold[open]>summary{border-radius:var(--radius-sm) var(--radius-sm) 0 0}
.fold>summary:focus-visible{outline:3px solid var(--teal);outline-offset:2px;border-radius:var(--radius-sm)}
.fold-switch{display:flex;flex-wrap:wrap;align-items:center;justify-content:flex-end;gap:8px 16px;margin:0 0 1.2em;font-size:1rem;color:var(--muted)}
.fold-switch[hidden]{display:none}
.fold-switch button{padding:8px 18px;border:2px solid var(--accent);border-radius:999px;background:transparent;color:var(--accent);font:700 1rem/1.2 var(--font-text);cursor:pointer}
.fold-switch button:hover,.fold-switch button[aria-pressed=true]{background:var(--accent-soft)}
@media print{.fold-switch{display:none}}

/* ── sheets: a page laid out like the worksheets of a spreadsheet ───── */
html.has-sheets{--sheet-h:64px;scroll-padding-top:calc(var(--header-h) + var(--sheet-h) + 16px)}
.sheet-bar{position:sticky;top:var(--header-h);z-index:40;padding-top:12px;background:var(--bg);box-shadow:0 1px 0 var(--line)}
.sheet-rail{position:relative;width:min(var(--page),100% - var(--gutter)*2);margin-inline:auto}
.sheet-bar .sheet-tabs{padding-inline:2px}
.sheet-bar.is-scrollable .sheet-tabs{cursor:grab}
.sheet-tabs.is-dragging{cursor:grabbing;scroll-snap-type:none;user-select:none}
.sheet-tabs.is-dragging .sheet-tab{pointer-events:none}
.sheet-arrow{position:absolute;bottom:0;z-index:2;display:none;place-items:center;width:38px;height:48px;padding:0 0 4px;border:0;background:var(--bg);color:var(--ink);font:800 1.7rem/1 var(--font-display);cursor:pointer}
.sheet-arrow:hover{color:var(--accent)}
.sheet-prev{left:0;box-shadow:14px 0 14px -6px var(--bg)}
.sheet-next{right:0;box-shadow:-14px 0 14px -6px var(--bg)}
.sheet-bar.can-left .sheet-prev,.sheet-bar.can-right .sheet-next{display:grid}
@media (pointer:coarse){.sheet-arrow{display:none!important}}
.sheet-tabs{display:flex;align-items:flex-end;gap:6px;overflow-x:auto;scrollbar-width:none;-webkit-overflow-scrolling:touch;scroll-snap-type:x proximity;padding:0 2px}
.sheet-tabs::-webkit-scrollbar{display:none}
.article-story .article-section a.sheet-tab,.sheet-tab{flex:none;scroll-snap-align:center;display:inline-flex;align-items:baseline;gap:10px;min-height:48px;padding:12px 22px 11px;border:1px solid var(--line);border-bottom:0;border-radius:14px 14px 0 0;background:var(--surface-2);color:var(--muted);font:700 1.0625rem/1.2 var(--font-display);text-decoration:none;white-space:nowrap;transition:background .2s,color .2s}
.sheet-tab small{font:600 .9375rem/1.2 var(--font-text);color:var(--muted);opacity:.9}
.sheet-tab:hover{color:var(--ink);background:var(--accent-soft)}
.sheet-tab[aria-selected=true]{position:relative;background:var(--bg);color:var(--ink);box-shadow:inset 0 4px 0 var(--green);margin-bottom:-1px;padding-bottom:12px}
.sheet-tab:focus-visible{outline:3px solid var(--teal);outline-offset:-3px}
.sheet-panel{counter-reset:chapter;padding-top:clamp(8px,2vw,24px)}
.sheet-panel[hidden]{display:none}
.sheet-panel:focus{outline:none}
@media (max-width:640px){.sheet-tab{padding:11px 16px 10px}}
@media print{.sheet-bar{display:none}.sheet-panel[hidden]{display:block!important}.sheet-step{display:none}}
/* Reading marks (sheets.js): a dot on a part that has not been read, a note above the links to the next pages that says what is
   left, and smaller links to the neighbouring pages so that they do not pull the reader away from the parts still unread. */
.sheet-tab[data-unread]{position:relative}
.sheet-tab[data-unread]::after{content:"";position:absolute;top:8px;right:8px;width:10px;height:10px;border-radius:50%;background:var(--accent);box-shadow:0 0 0 2px var(--bg)}
.sheet-end{height:1px}
.sheet-step{display:grid;grid-template-columns:1fr 1fr;gap:14px;margin-top:clamp(36px,4vw,56px)}
.sheet-step a{display:block;padding:16px 22px;border:1px solid var(--accent);border-radius:var(--radius-sm);background:var(--accent-soft);color:var(--muted);text-decoration:none;transition:transform .25s,box-shadow .25s}
.sheet-step a[hidden]{display:none}
.sheet-step .next{grid-column:2;text-align:right}
.sheet-step span{display:block;font-weight:600;font-size:1rem}
.sheet-step strong{display:block;margin-top:2px;font-family:var(--font-display);font-size:1.1875rem;line-height:1.15;color:var(--ink)}
.sheet-step a:hover{transform:translateY(-3px);box-shadow:var(--shadow)}
.sheet-step a:focus-visible{outline:3px solid var(--teal);outline-offset:2px}
@media (max-width:640px){.sheet-step{grid-template-columns:1fr}.sheet-step .next{grid-column:1;text-align:left}}
html.has-sheets .page-pagination{gap:14px;margin-top:14px}
html.has-sheets .page-pagination a{padding:16px 22px;border-radius:var(--radius-sm)}
html.has-sheets .page-pagination span{font-size:1rem}
html.has-sheets .page-pagination strong{margin-top:2px;font-size:1.1875rem}
.changes .enc-when{display:inline-block;margin-bottom:6px;font:700 1rem/1.3 var(--font-text);color:var(--muted)}
.changes td p{margin:0 0 .5em}
.enc-leads{margin:0;padding:0;list-style:none;display:grid;gap:8px}
.enc-leads li{line-height:1.5}
.enc-leads .map-chip{margin-right:6px}

/* Encounter by encounter: a short timeline (date, encounter, the changes it led to) */
.enc-timeline{list-style:none;margin:24px 0 0;padding:0 0 0 22px;border-left:2px solid var(--line,rgba(0,0,0,.12))}
.enc-timeline li{position:relative;display:grid;grid-template-columns:7.5em minmax(0,1fr);gap:6px 14px;align-items:start;padding:12px 0}
.enc-timeline li::before{content:"";position:absolute;left:-29px;top:20px;width:12px;height:12px;border-radius:50%;background:var(--teal,#2a9d8f)}
.enc-timeline .enc-when{font-weight:700;padding-top:6px}
.enc-tl-from,.enc-tl-to{display:flex;flex-wrap:wrap;gap:6px;align-items:center}
.enc-tl-to{grid-column:2}
.enc-tl-arrow{font-size:1.125rem;opacity:.6;margin-right:2px}
@media (max-width:640px){.enc-timeline li{grid-template-columns:1fr}.enc-tl-to{grid-column:1}}
/* Mascots (site.css .fig-mascot) float beside the text; boxed blocks and headings start below them. */
.article-story .fig-mascot ~ :is(.qwrap,.journey,.layers,.gallery,.callout,.table-scroll,.stats,h3,figure,.embed){clear:both}
.article-story :has(> .fig-mascot)::after{content:"";display:block;clear:both}
/* A question box next to a mascot narrows to sit beside it, so there is no gap and no overlap. */
.article-story .fig-mascot ~ :is(.ask,.qwrap){display:flow-root;clear:none}

/* ── Stakeholder map (block `stakeholders`, tools/stakeholder-block.mjs; behaviour in stakeholders.js) ── */
.skm{margin:1.6em 0 2em}
.skm .ring-r1{--ring:var(--green)}
.skm .ring-r2{--ring:var(--teal)}
.skm .ring-r3{--ring:var(--blue)}
.skm .ring-r4{--ring:var(--muted)}
.skm ul{list-style:none;display:block;max-width:none;margin:0;padding:0}
.skm ul li{position:static;margin:0;padding:0;border:0;border-radius:0;background:none;color:inherit}
.skm ul li::before{display:none}
.skm-square{position:relative;width:min(100%,680px);aspect-ratio:1;margin:0 auto}
.skm-rings{position:absolute;inset:0;width:100%;height:100%;overflow:visible}
.skm-rings circle{fill:none;stroke:var(--ring);stroke-width:.35;opacity:.6}
.skm-rings .ring-r1{fill:color-mix(in srgb,var(--green) 6%,transparent)}
.skm-rings .ring-r4{stroke-dasharray:1.2 1.2}
.skm-core{position:absolute;left:50%;top:50%;transform:translate(-50%,-50%);width:17%;aspect-ratio:1;margin:0;border-radius:50%;display:flex;flex-direction:column;align-items:center;justify-content:center;text-align:center;background:var(--spectrum);color:#fff;box-shadow:var(--shadow)}
.skm-core strong{font-family:"Baloo 2",system-ui,sans-serif;font-size:clamp(17px,2.4vw,22px);line-height:1.1}
.skm-core span{display:none}
.skm .skm-node{position:absolute;left:var(--x);top:var(--y);transform:translate(-50%,-50%);width:23%}
.skm-g{display:flex;flex-direction:column;align-items:center;gap:5px;padding:8px 10px;border-radius:var(--radius-sm);background:var(--surface);border:2px solid var(--ring);color:var(--ink);text-decoration:none;text-align:center;font-size:15px;font-weight:700;line-height:1.2;box-shadow:var(--shadow);transition:opacity .2s,transform .2s,background .2s,box-shadow .2s}
.skm-g:hover,.skm-g:focus-visible{transform:translateY(-2px)}
.skm-g[aria-current="true"]{background:color-mix(in srgb,var(--ring) 18%,var(--surface))}
.skm-g.lit{box-shadow:0 0 0 4px color-mix(in srgb,var(--ring) 35%,transparent),var(--shadow)}
.skm-marks{display:flex;flex-wrap:wrap;justify-content:center;gap:4px}
.skm-open{font-size:15px;font-weight:600;color:var(--muted);font-style:italic}
.mk{display:inline-block;width:12px;height:12px;border-radius:50%;flex:none;box-sizing:border-box}
.mk-is{background:var(--green)}
.mk-raised{border:2.5px solid var(--amber)}
.mk-asked{border:2px dashed var(--muted)}
.skm-key{display:flex;flex-wrap:wrap;justify-content:center;gap:10px 32px;margin:18px 0 6px}
.skm-key ul{display:flex;flex-wrap:wrap;gap:6px 18px}
.skm-key li{display:flex;align-items:center;gap:8px;font-size:15px;color:var(--text)}
.skm-key-rings i{width:22px;height:0;border-top:3px solid var(--ring)}
.skm-key-rings .ring-r4 i{border-top-style:dashed}
.skm-people{margin:22px 0 0}
.skm-people-title{margin:0 0 8px;font-weight:700;color:var(--ink)}
.skm-people ul{display:flex;flex-wrap:wrap;gap:8px}
.skm-p{display:inline-block;padding:5px 14px;border-radius:999px;border:1.5px solid var(--line);background:var(--surface);color:var(--ink);font-size:15px;text-decoration:none;transition:opacity .2s,background .2s,border-color .2s}
.skm-p.skm-p-asked{border-style:dashed;color:var(--muted)}
.skm-p[aria-current="true"]{background:var(--accent-soft);border-color:var(--accent)}
.skm .skm-p.lit.how-is{border-color:var(--green);background:color-mix(in srgb,var(--green) 14%,var(--surface))}
.skm .skm-p.lit.how-raised{border-color:var(--amber);background:color-mix(in srgb,var(--amber) 14%,var(--surface))}
.skm .skm-p.lit.how-asked{border-color:var(--muted);border-style:dashed}
/* With script, the selection lights up what is linked to it and lets the rest fade. */
.skm[data-mode] :is(.skm-g,.skm-p):not(.lit):not([aria-current="true"]){opacity:.55}
.skm-panels{margin-top:20px}
.skm-panel{margin:0 0 16px;padding:clamp(20px,3vw,32px);border-radius:var(--radius);background:var(--surface);border:1px solid var(--line);box-shadow:var(--shadow)}
.skm-panel[hidden]{display:none}
.skm .skm-panel h3{margin:.25em 0 .3em}
.skm .skm-panel h4{margin:1.1em 0 .4em;font-size:16px}
.skm-kicker{margin:0;font-size:15px;font-weight:700;color:var(--ring,var(--muted));text-transform:uppercase;letter-spacing:.04em}
.skm-q{margin:1em 0;padding:12px 16px;border-left:4px solid var(--accent);border-radius:0 var(--radius-sm) var(--radius-sm) 0;background:var(--accent-soft);font-style:italic}
.skm .skm-cares{list-style:disc;padding-left:1.3em}
.skm .skm-cares li{margin:0 0 4px}
.skm .skm-chain{list-style:none;display:flex;flex-wrap:wrap;align-items:center;gap:6px 26px;margin:1em 0;padding:0}
.skm .skm-chain li{position:relative;margin:0;padding:4px 12px;border-radius:999px;background:var(--surface-2);font-size:15px}
.skm-chain li::before{display:none}
.skm-chain li:not(:last-child)::after{content:"→";position:absolute;right:-20px;top:50%;transform:translateY(-50%);color:var(--muted)}
.skm .skm-who li{display:flex;flex-wrap:wrap;align-items:center;gap:4px 10px;margin:0 0 6px}
.skm-who span{color:var(--muted);font-size:15px}
.skm-none{color:var(--muted);font-style:italic}
.skm-more{margin:1.2em 0 0;font-weight:700}
/* Narrow screens: the rings give way to the groups listed ring by ring. */
@media (max-width:719px){
  .skm-square{aspect-ratio:auto;width:100%}
  .skm-rings{display:none}
  .skm-core{position:static;transform:none;width:auto;aspect-ratio:auto;border-radius:var(--radius-sm);padding:10px 16px;margin:0 0 12px}
  .skm-core span{display:block;font-size:15px}
  .skm .skm-nodes{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:8px}
  .skm .skm-node{position:static;transform:none;width:auto}
  .skm-g{height:100%;box-sizing:border-box}
}
@media print{.skm-panel[hidden]{display:block}}

/* Plain lists inside a method (protocol steps): numbers or small dots, no cards. */
.article-section .plain-list{margin:.8em 0 1.2em;max-width:46em}
.article-section .plain-list ul,.article-section .plain-list ol{margin:.35em 0;padding:0 0 0 1.5em;display:block;max-width:none}
.article-section .plain-list ul{list-style:disc}
.article-section .plain-list ol{list-style:decimal}
.article-section .plain-list li{position:static;padding:0;margin:.35em 0;background:none;border:0;border-radius:0;box-shadow:none}
.article-section .plain-list li::before{content:none}
.article-section .plain-list li>ul,.article-section .plain-list li>ol{margin:.3em 0 .5em}
.article-section .plain-list li::marker{color:var(--teal)}

/* ── Picture book (block `book`, tools/story-blocks.mjs; page turning in book.js) ── */
.book{max-width:560px;margin:2em auto}
.book-bar{display:flex;flex-wrap:wrap;align-items:center;justify-content:space-between;gap:8px 16px;margin-bottom:10px}
.book-langs{display:inline-flex;padding:4px;border-radius:999px;background:var(--surface-2);border:1px solid var(--line)}
.book-langs button{border:0;background:none;padding:6px 16px;border-radius:999px;font:inherit;font-size:15px;font-weight:700;color:var(--muted);cursor:pointer}
.book-langs button[aria-pressed="true"]{background:var(--surface);color:var(--ink);box-shadow:var(--shadow)}
.book-count{margin:0;font-size:15px;color:var(--muted)}
.book-view{position:relative}
.article-section .book-strip{display:flex;gap:0;max-width:none;margin:0;padding:0;list-style:none;overflow-x:auto;scroll-snap-type:x mandatory;overscroll-behavior-x:contain;border-radius:var(--radius-sm);box-shadow:var(--shadow);background:var(--surface)}
.article-section .book-strip li{flex:0 0 100%;margin:0;padding:0;border:0;border-radius:0;background:none;scroll-snap-align:start}
.article-section .book-strip li::before{display:none}
.book-strip img{display:block;width:100%;height:auto}
.article-section .book-strip[hidden]{display:none}
.book-strip+.book-strip{margin-top:16px}
.book-turn,.book-langs{display:none}
.book-js .book-langs{display:inline-flex}
.book-js .book-turn{display:grid;place-items:center;position:absolute;top:50%;transform:translateY(-50%);width:48px;height:48px;border-radius:50%;border:1px solid var(--line);background:var(--surface);color:var(--ink);font-size:30px;line-height:1;box-shadow:var(--shadow);cursor:pointer;z-index:1}
.book-js .book-turn:disabled{opacity:.35;cursor:default}
.book-js .book-strip{scrollbar-width:none}
.book-js .book-strip::-webkit-scrollbar{display:none}
.book-js .book-strip+.book-strip{margin-top:0}
.book-prev{left:-64px}
.book-next{right:-64px}
@media (max-width:760px){.book-prev{left:8px}.book-next{right:8px}.book-js .book-turn{width:44px;height:44px;background:color-mix(in srgb,var(--surface) 85%,transparent)}}
.book figcaption{margin-top:12px}
@media print{.book-strip{overflow:visible;flex-direction:column}.book-turn,.book-bar{display:none}}
.fold-body h4{margin:1.6em 0 .5em;font-size:1.25rem;color:var(--ink)}
.fold-body h5{margin:1.4em 0 .4em;font:800 1.1rem/1.35 var(--font-display);color:var(--ink)}
.fold-body h6{margin:1.2em 0 .3em;font:800 1rem/1.4 var(--font-display);color:var(--teal-deep,var(--ink))}

/* The design–build–test–learn loop: a ring per round, a dot per cycle, a letter on each step heading (Engineering page) */
.round,.cycle,.loopkey,h4.step{--s-d:var(--green);--s-b:var(--ocean);--s-t:var(--amber);--s-l:#9B7BE0}
.loop-ring{flex:none;display:block}
.loop-ring path{fill:none;stroke:currentColor;stroke-width:5;stroke-linecap:round}
.loop-ring .head{fill:currentColor;stroke-width:1.5;stroke-linejoin:round}
.loop-ring .s-d,.step-dots .s-d{color:var(--s-d)}
.loop-ring .s-b,.step-dots .s-b{color:var(--s-b)}
.loop-ring .s-t,.step-dots .s-t{color:var(--s-t)}
.loop-ring .s-l,.step-dots .s-l{color:var(--s-l)}
.loop-ring .off{color:var(--line);opacity:.9}
.step-chip{flex:none;display:inline-grid;place-items:center;width:30px;height:30px;border-radius:50%;font:800 .9375rem/1 var(--font-display);color:#06202c}
.article-story h4.step{display:flex;align-items:center;gap:10px;color:var(--ink)}
h4.s-d .step-chip{background:var(--s-d)}h4.s-b .step-chip{background:var(--s-b);color:#fff}h4.s-t .step-chip{background:var(--s-t)}h4.s-l .step-chip{background:var(--s-l);color:#fff}
.step-dots{flex:none;display:inline-flex;gap:4px}
.step-dots i{width:12px;height:12px;border-radius:4px;background:currentColor}
.step-dots .off{background:transparent;box-shadow:inset 0 0 0 2px var(--line)}

/* a round: ring + code + title + the question + one pill per cycle, all visible while it is closed */
.article .fold.round{margin:1.1em 0;border-color:color-mix(in srgb,var(--teal) 30%,var(--line))}
.round>summary{align-items:center;gap:14px;padding:16px 22px}
.round-head{display:grid;gap:3px;min-width:0;flex:1}
.round-code{font:800 .9375rem/1 var(--font-display);letter-spacing:.08em;color:var(--accent)}
.round-title{font:700 1.3rem/1.25 var(--font-display);color:var(--ink)}
.round-q{font:400 1.0625rem/1.45 var(--font-text);color:var(--muted)}
.round-chain{display:flex;flex-wrap:wrap;align-items:center;gap:0;margin-top:6px}
.round-chain i{position:relative;box-sizing:border-box;min-width:32px;height:32px;padding:0 6px;display:inline-grid;place-items:center;border-radius:999px;background:var(--accent-soft);color:var(--accent);font:700 .9375rem/1 var(--font-text);font-style:normal}
.round-chain i+i{margin-left:14px}
.round-chain i+i::before{content:"";position:absolute;left:-12px;top:50%;width:10px;height:2px;border-radius:1px;background:var(--line)}
.round-chain i.next{background:transparent;box-shadow:inset 0 0 0 2px var(--accent);border-radius:999px}
.round-nav{list-style:none;display:flex;flex-wrap:wrap;gap:8px 6px;margin:.6em 0 1.2em;padding:0}
.round-nav li{display:flex;align-items:center;gap:6px;margin:0;padding:0;border:0;background:none;box-shadow:none;border-radius:0}
.round-nav li:not(:last-child)::after{content:"→";color:var(--muted)}
.round-nav li::before{content:none}
.round-nav a{display:inline-flex;gap:8px;align-items:baseline;padding:6px 14px;border-radius:999px;background:var(--accent-soft);color:var(--ink);font:600 1rem/1.35 var(--font-text);text-decoration:none}
.round-nav a:hover{background:color-mix(in srgb,var(--accent) 22%,transparent)}
.round-nav b{color:var(--accent)}

/* a cycle inside a round */
.article .fold.cycle{margin:.9em 0;background:var(--bg);border-color:var(--line)}
.cycle[open]{background:var(--surface)}
.cycle>summary{gap:12px;padding:12px 18px;font-size:1.1rem}
.cycle-no{flex:none;min-width:2.6em;font:800 1rem/1 var(--font-display);color:var(--accent)}
.cycle-title{flex:1;min-width:0}
@media (max-width:640px){.cycle-no{min-width:0}.cycle>summary{gap:10px}.round>summary{padding:14px 14px}.round-ring svg{width:44px;height:44px}.step-dots{display:none}.round-title{font-size:1.15rem}}

/* the key to the loop on the Overview tab */
.loopkey{display:flex;align-items:center;gap:clamp(18px,3vw,36px);margin:1.6em 0;padding:clamp(16px,2.4vw,26px);border:1px solid var(--line);border-radius:var(--radius-sm);background:var(--surface)}
.loopkey ol{list-style:none;margin:0;padding:0;display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:12px 22px;flex:1}
.loopkey li{display:flex;gap:12px;align-items:flex-start;margin:0;padding:0;border:0;background:none;box-shadow:none;border-radius:0;color:var(--text);font-size:1.0625rem;line-height:1.5}
.loopkey li::before{content:none}
.loopkey li strong{color:var(--ink);display:block}
.loopkey .step-chip{margin-top:2px;color:#06202c}
.loopkey .s-d .step-chip{background:var(--s-d)}.loopkey .s-b .step-chip{background:var(--s-b);color:#fff}.loopkey .s-t .step-chip{background:var(--s-t)}.loopkey .s-l .step-chip{background:var(--s-l);color:#fff}
@media (max-width:640px){.loopkey{flex-direction:column;align-items:flex-start}}
@media print{.round-chain,.round-nav{break-inside:avoid}}

/* an index of DBTL rounds told on other pages (Engineering: Dry lab, Human Practices) */
.dbtl-index{display:grid;gap:16px;margin:1.2em 0}
.dbtl-card{--s-d:var(--green);--s-b:var(--ocean);--s-t:var(--amber);--s-l:#9B7BE0;padding:clamp(16px,2.2vw,24px);border:1px solid color-mix(in srgb,var(--teal) 30%,var(--line));border-radius:var(--radius-sm);background:var(--surface);scroll-margin-top:90px}
.dbtl-card>header{display:flex;align-items:center;gap:14px;margin-bottom:12px}
.dbtl-steps{list-style:none;margin:0 0 10px;padding:0;display:grid;grid-template-columns:repeat(auto-fit,minmax(230px,1fr));gap:10px 22px}
.dbtl-steps li{display:flex;gap:12px;align-items:flex-start;margin:0;padding:0;border:0;background:none;box-shadow:none;border-radius:0;color:var(--text);font-size:1.0625rem;line-height:1.5}
.dbtl-steps li::before{content:none}
.dbtl-steps strong{color:var(--ink);display:block}
.dbtl-steps .step-chip{margin-top:2px}
.dbtl-steps .s-d .step-chip{background:var(--s-d)}.dbtl-steps .s-b .step-chip{background:var(--s-b);color:#fff}.dbtl-steps .s-t .step-chip{background:var(--s-t)}.dbtl-steps .s-l .step-chip{background:var(--s-l);color:#fff}
.dbtl-steps .off .step-chip{background:transparent;color:var(--muted);box-shadow:inset 0 0 0 2px var(--line)}
.dbtl-steps .off em{color:var(--muted)}
.dbtl-links{display:flex;flex-wrap:wrap;gap:6px 8px;margin:.4em 0 0}
.dbtl-links a{display:inline-flex;padding:6px 14px;border-radius:999px;background:var(--accent-soft);color:var(--ink);font:600 1rem/1.35 var(--font-text);text-decoration:none}
.dbtl-links a:hover{background:color-mix(in srgb,var(--accent) 22%,transparent)}
@media (max-width:640px){.dbtl-card>header{align-items:flex-start}.dbtl-card .round-ring svg{width:44px;height:44px}}
