/* Developed island: woodland entry, school collection and reserved machinery. */
:root { --study-line:#eeeede; --study-ink:var(--text); --wash-strength:.72; }
:root[data-theme="light"] { --study-line:var(--line); --wash-strength:.62; }
.scene { --island-width:min(82%,1120px,calc((100svh - 220px)*1.67669)); --island-top:calc(50% + 32px); position:relative; isolation:isolate; margin:0; min-height:440px; height:calc(100svh - 96px); overflow:hidden; }
.overview-scene { position:absolute; inset:0; transform-origin:0 0; transition:transform 1050ms cubic-bezier(.65,0,.2,1),opacity 500ms 180ms; }
.arrival-title { position:absolute; top:3%; left:6%; color:var(--study-ink); font:400 clamp(28px,3.5vw,48px)/1.1 var(--font-display,'Archivo Black',sans-serif); z-index:3; }
.arrival-colour { position:absolute; width:var(--island-width); aspect-ratio:669/399; left:50%; top:var(--island-top); transform:translate(-50%,-50%); pointer-events:none; }
.wash { position:absolute; opacity:var(--wash-strength); pointer-events:none; max-width:none; }
/* The original clear paint is local to the island, with open space around it. */
/* Separate, level washes follow the island's coordinates rather than the viewport. */
.wash-violet { width:21.674%; height:21.303%; left:11.211%; top:16.291%; transform:none; }
.wash-coral { width:25%; height:30%; left:67%; top:53%; filter:hue-rotate(86deg); }
.wash-teal { width:30%; height:29%; left:10%; top:10%; transform:scaleX(-1); filter:hue-rotate(-112deg); }
.wash-gold { width:34%; height:28%; left:48%; top:12%; filter:hue-rotate(153deg); }
.island { position:absolute; z-index:1; width:var(--island-width); left:50%; top:var(--island-top); transform:translate(-50%,-50%); aspect-ratio:669/399; transition:transform 850ms cubic-bezier(.2,.8,.2,1),opacity 500ms; pointer-events:none; }
.island .hero-artwork,.island .hero-sheen-layer { position:absolute; inset:0; width:100%; height:100%; display:block; transform:none; aspect-ratio:669/399; }
.island .hero-artwork { background:transparent; -webkit-mask:none; mask:none; object-fit:contain; filter:url(#study-artwork-contrast) brightness(0) invert(1); opacity:.92; }
:root[data-theme="light"] .island .hero-artwork { filter:url(#study-artwork-contrast) brightness(0); opacity:.78; }
.region-name { position:absolute; z-index:3; font:600 20px/1.3 var(--font-heading,Archivo,sans-serif); text-decoration:none; }
.scene .island .spellquest { position:absolute; z-index:2; left:11.211%; top:16.291%; width:21.674%; height:21.303%; padding:0; border:0; background:transparent; pointer-events:auto; cursor:pointer; }
.region-name span { margin-left:10px; font-size:16px; }
.collection-portal { --home-width:24; --home-height:22; --home-left:72; --home-top:3; position:absolute; z-index:1; width:calc(var(--home-width)*1%); height:calc(var(--home-height)*1%); left:calc(var(--home-left)*1%); top:calc(var(--home-top)*1%); pointer-events:none; transition:opacity 650ms; }
.portal-wash { position:absolute; inset:-35% -15%; background:url('assets/playground/paint-study.png') center/100% 100% no-repeat; filter:hue-rotate(-65deg); opacity:.72; transition:opacity 850ms ease; }
.portal-line { position:absolute; inset:0; display:block; width:100%; height:100%; color:var(--study-line); opacity:.9; }
.cloud-entry { position:absolute; z-index:4; left:72%; top:3%; width:24%; height:29%; padding:0; display:flex; align-items:flex-end; justify-content:center; background:transparent; border:0; color:var(--study-ink); font:600 20px var(--font-heading,Archivo,sans-serif); }
.collection-heading { position:absolute; z-index:5; left:7%; width:86%; text-align:center; color:var(--study-ink); top:4%; opacity:0; visibility:hidden; transition:opacity 400ms; }
.collection-heading h2 { font:400 32px/1.2 var(--font-display,'Archivo Black',sans-serif); margin-top:8px; }
.return-control { border:0; background:transparent; padding:8px 0; min-height:44px; text-decoration:underline; text-underline-offset:5px; font-size:14px; }
.app-region { position:absolute; z-index:2; width:32%; height:34%; top:36%; left:16%; background:transparent; border:0; opacity:0; visibility:hidden; transition:opacity 550ms; }
.app-region::before { content:''; position:absolute; inset:0; background:url('assets/playground/paint-study.png') center/100% 100% no-repeat; filter:hue-rotate(-114deg); transform:none; opacity:.85; transition:transform 240ms ease,opacity 240ms ease; }
.app-region span { position:relative; color:var(--study-ink); font:600 24px var(--font-heading,Archivo,sans-serif); }
.app-region.round span { color:var(--study-ink); }
.app-region.round { left:53%; top:36%; }
.app-region.round::before { background-image:url('assets/playground/paint-study.png'); filter:hue-rotate(-35deg); transform:none; }
.scene:not([data-scene="island"]) .overview-scene { opacity:0; transform:translate(var(--camera-x,0px),var(--camera-y,0px)) scale(var(--camera-zoom,1)); }
.scene:not([data-scene="island"]) .arrival-title,.scene:not([data-scene="island"]) .spellquest,.scene:not([data-scene="island"]) .cloud-entry { opacity:0; visibility:hidden; pointer-events:none; }
.scene:not([data-scene="island"]) .collection-portal { width:var(--inside-width,154%); height:var(--inside-height,140%); left:var(--inside-left,-27%); top:var(--inside-top,-22%); }
.scene[data-scene="collection"] .collection-heading,.scene[data-scene="collection"] .app-region { opacity:1; visibility:visible; }
.scene[data-scene="collection"][data-travelling="true"] .collection-heading,
.scene[data-scene="collection"][data-travelling="true"] .app-region,
.scene[data-departing="true"] .collection-heading,
.scene[data-departing="true"] .app-region { opacity:0; visibility:hidden; }
.scene[data-departing="true"] .collection-heading,.scene[data-departing="true"] .app-region { visibility:visible; transition:opacity 180ms; }
.scene[data-travelling="true"] { pointer-events:none; }
.scene:not([data-scene="island"]) .portal-wash { opacity:.18; }

@media(max-width:760px) {
  .scene { --island-width:min(96%,calc((100svh - 190px)*1.67669)); --island-top:calc(50% + 32px); height:calc(100svh - 78px); min-height:300px; }
  .arrival-title { top:4%; left:6%; font-size:31px; }
  .collection-portal { --home-width:58; --home-height:22; --home-left:40; --home-top:14; }
  .cloud-entry { width:58%; height:27%; left:40%; top:14%; padding-bottom:3%; font-size:18px; }
  .collection-heading { left:7%; top:3%; }
  .collection-heading h2 { font-size:28px; }
  .app-region { width:70%; height:27%; left:6%; top:23%; }
  .app-region.round { left:24%; top:58%; }
  .app-region span { font-size:22px; }
}

.scene .region-name { border:0; background:transparent; cursor:pointer; }
.scene .family-return { display:inline-flex; }
.scene .collection-portal { pointer-events:none; }
.scene .cloud-entry { transition:opacity 220ms ease; }
.scene[data-travelling="true"] .cloud-entry { opacity:0; visibility:hidden; }
.scene .app-region .visited-label { position:relative; display:block; margin-top:8px; color:var(--study-ink); font-size:12px; }
.scene .app-region.is-visited::before { opacity:.62; }
.scene:has(.island.is-visited) .wash-violet { opacity:.55; }
:root[data-placeholders="off"] .arrival-colour .wash:not(.wash-violet):not(.wash-busy) { opacity:0; }
.scene .region-name .visited-label { margin-top:5px; }
.scene .region-name:focus-visible,.scene .cloud-entry:focus-visible,.scene .app-region:focus-visible,.scene .return-control:focus-visible { outline:2px solid var(--focus); outline-offset:5px; }
.lesson-project { --lesson-wash: url("assets/playground/paint-study.png"); --lesson-wash-hue:-114deg; }
.lesson-project[data-project="round-it-up"] { --lesson-wash:url("assets/playground/paint-study.png"); --lesson-wash-hue:-35deg; }
.lesson-project .project-body::before { filter:hue-rotate(var(--lesson-wash-hue)); }
:root[data-morphing="boss-battle"] #reveal-paint { filter:hue-rotate(-114deg); }
:root[data-morphing="round-it-up"] #reveal-paint { filter:hue-rotate(-35deg); }
@media(prefers-reduced-motion:reduce) { .scene *,.scene *::before,.scene *::after { animation:none!important; transition:none!important; } }

/* Keep the original paint visible after SpellQuest's expansion settles. */
.project-view[data-project="spellquest"] { isolation:isolate; }
.project-view[data-project="spellquest"]::before { content:""; position:fixed; z-index:-1; top:var(--project-top,96px); inset-inline:0; bottom:0; background:url("assets/playground/paint-study.png") center/cover no-repeat; opacity:.14; pointer-events:none; }
:root[data-theme="light"] .project-view[data-project="spellquest"]::before { opacity:.17; }
.lesson-project { --lesson-wash-opacity:.2; }
:root[data-theme="light"] .lesson-project { --lesson-wash-opacity:.18; }
:root[data-morphing="spellquest"] .wash-violet { opacity:0; transition:none; }
.scene[data-scene="island"][aria-busy="false"] .overview-scene:has(#spellquest-entry:hover) .wash-violet,
.scene[data-scene="island"][aria-busy="false"] .overview-scene:has(#spellquest-entry:focus-visible) .wash-violet { transform:scale(1.08); opacity:calc(var(--wash-strength) + .18); }
.scene .wash-violet { transition:transform 240ms ease,opacity 240ms ease; }
.scene[data-scene="island"][aria-busy="false"]:has(#family-entry:hover) .portal-wash,
.scene[data-scene="island"][aria-busy="false"]:has(#family-entry:focus-visible) .portal-wash { transform:scale(1.045); opacity:.9; }
.scene .portal-wash { transition:transform 240ms ease,opacity 400ms ease; }
.scene[data-scene="collection"][aria-busy="false"] .app-region:hover::before,
.scene[data-scene="collection"][aria-busy="false"] .app-region:focus-visible::before { transform:translateY(-3px) scale(1.045); opacity:1; }
.scene .island .spellquest:focus-visible { outline:2px solid var(--focus); outline-offset:5px; }

.spellquest-project .project-body { width:min(100% - 48px,1120px); padding-top:20px; }
.spellquest-project .project-back { margin-bottom:12px; }
.spellquest-project .project-heading h1 { font-size:clamp(2rem,4vw,3rem); margin-bottom:14px; }
.spellquest-intro { font-size:16px; line-height:1.5; max-width:65ch; }
.spellquest-play-controls { display:flex; justify-content:flex-end; padding:12px 0; font-size:14px; }
#spellquest-player { width:100%; aspect-ratio:4/3; overflow:hidden; border-radius:16px; background:#132b22; }
#spellquest-player iframe { display:block; width:100%; height:100%; border:0; }
.spellquest-prototype-note { font-size:13px; color:var(--soft-text); margin-top:20px; }
@media(max-width:760px) {
  .spellquest-project .project-body { width:calc(100% - 32px); }
  #spellquest-player { aspect-ratio:3/4; border-radius:11px; }
}

/* Shared approved linework, with the Playground school portal retained. */
.island .hero-artwork.island-developed,
:root[data-theme="light"] .island .hero-artwork.island-developed { filter:none; color:var(--study-line); opacity:.92; }
/* Use the shared dark-mode opacity for the island and its school. */
:root[data-theme="dark"] .island .hero-artwork.island-developed { opacity:var(--island-dark-opacity); }
:root[data-theme="dark"] .scene[data-scene="island"] .school-portal-line { opacity:calc(var(--island-dark-opacity) * .36); }
/* Match the homepage line colour and opacity in light mode. */
:root[data-theme="light"] .island .hero-artwork.island-developed { opacity:.75; }
:root[data-theme="light"] .scene[data-scene="island"] .school-portal-line { opacity:calc(.75 * .36); }
.island-developed .developed-trace,.island-developed .evidence-machine { fill:none; stroke:currentColor; stroke-width:1.05; stroke-linecap:round; stroke-linejoin:round; }
.island-developed .evidence-machine .solid { fill:var(--bg); }
.island-developed .evidence-machine .interpretation-line { stroke-dasharray:4 3; }
.island-developed .evidence-machine path { vector-effect:non-scaling-stroke; }
.island .hero-sheen-layer { -webkit-mask:url("assets/playground/developed-sheen-mask.svg") center/100% 100% no-repeat; mask:url("assets/playground/developed-sheen-mask.svg") center/100% 100% no-repeat; }
:root[data-placeholders="off"] .island-developed .evidence-machine { opacity:0; }
.scene .school-entry { left:calc(var(--school-home-left,50)*1%); top:calc(var(--school-home-top,24)*1%); width:calc(var(--school-home-width,10)*1%); height:calc(var(--school-home-height,14)*1%); min-width:44px; min-height:44px; padding:0; }
.scene:not([data-school-ready="true"]) .collection-portal,.scene:not([data-school-ready="true"]) .school-entry { visibility:hidden; }
.school-portal-line .proposed-school { fill:none; stroke-width:1.05; }
.school-portal-line path { vector-effect:non-scaling-stroke; }
.school-portal-line .school-detail { transition:opacity 650ms ease; }
.scene:not([data-scene="island"]) .school-portal-line .school-detail { opacity:0; }
.scene:not([data-scene="island"]) .school-portal-line { opacity:.2; }
.school-portal-line { transition:opacity 850ms ease; }
.collection-portal .portal-wash { inset:-20% -12%; }
.lesson-project,.lesson-project[data-project="boss-battle"] { --project-cloud-line:url("assets/playground/school-linework.svg"); }

/* Optional process exploration retains the independently hosted game. */
.spellquest-play-controls { justify-content:space-between; align-items:center; gap:16px; flex-wrap:wrap; padding:0 0 4px; }
.spellquest-thinking { margin-top:32px; padding-top:20px; scroll-margin-top:20px; }
.spellquest-thinking-heading { display:flex; justify-content:space-between; align-items:center; gap:24px; }
.spellquest-thinking h2 { font:600 clamp(26px,3vw,36px)/1.2 var(--font-heading); }
.spellquest-research-context { max-width:70ch; margin-top:12px; font-size:15px; line-height:1.6; }
.spellquest-moment-picker { display:flex; flex-wrap:wrap; column-gap:28px; row-gap:4px; margin:24px 0 32px; }
.spellquest-moment-picker button { font-size:16px; color:var(--soft-text); text-decoration:none; }
.spellquest-moment-picker button[aria-pressed="true"] { color:var(--text); text-decoration:underline; text-decoration-color:var(--accent); text-decoration-thickness:2px; text-underline-offset:8px; }
.spellquest-moment { display:grid; grid-template-columns:minmax(0,.8fr) minmax(0,1.2fr); align-items:center; gap:42px; min-height:340px; }
.spellquest-moment[hidden] { display:none; }
.spellquest-moment h3 { font:600 clamp(24px,2.5vw,30px)/1.25 var(--font-heading); margin-bottom:18px; }
.spellquest-purpose p { font-size:15px; line-height:1.65; margin-bottom:16px; }
.spellquest-purpose .spellquest-design-question { color:var(--soft-text); font-size:13px; }
.spellquest-moment figure { margin:0; }
.spellquest-moment img { display:block; width:100%; height:auto; }
.spellquest-moment figcaption,.spellquest-strands > p { margin-top:12px; font-size:13px; line-height:1.5; color:var(--soft-text); }
.spellquest-strands { position:relative; isolation:isolate; padding:24px 4px; }
.spellquest-strands::before { content:""; position:absolute; z-index:-1; inset:-12% -6%; background:url('assets/playground/paint-study.png') center/100% 100% no-repeat; opacity:.13; pointer-events:none; }
.spellquest-strands dl { margin:0; }
.spellquest-strands dl > div { margin-bottom:26px; }
.spellquest-strands dt { font:600 14px/1.4 var(--font-heading); margin-bottom:10px; }
.spellquest-strands dd { display:flex; justify-content:space-between; gap:12px; margin:0; font-size:15px; line-height:1.5; }
.spellquest-strands dd span { flex:1; }
.spellquest-strands h4 { font:600 18px/1.4 var(--font-heading); }
.spellquest-earlier-flow { margin:22px 0 0; padding-left:24px; }
.spellquest-earlier-flow li { padding:0 0 18px 8px; font-size:18px; }
.spellquest-process-status { max-width:85ch; margin-top:32px; font-size:13px; line-height:1.5; color:var(--soft-text); }
@media(max-width:760px) {
 .spellquest-thinking-heading { align-items:flex-start; gap:16px; }
 .spellquest-thinking-heading .text-control { flex-shrink:0; font-size:13px; }
 .spellquest-moment-picker { column-gap:20px; margin:20px 0 28px; }
 .spellquest-moment-picker button { font-size:14px; }
 .spellquest-moment { grid-template-columns:minmax(0,1fr); gap:20px; min-height:0; }
 .spellquest-moment figure { grid-row:1; }
 .spellquest-strands { padding:16px 0; }
 .spellquest-strands dd { font-size:13px; gap:8px; }
 .spellquest-thinking { margin-top:24px; }
}

/* Approved busy-board entrance: the island's upper-right doors and panels. */
.wash-busy { left:74%; top:18%; width:16%; height:20%; filter:hue-rotate(86deg); transition:transform 240ms ease,opacity 240ms ease; }
.scene .island .busy-board-entry { position:absolute; z-index:2; left:74%; top:18%; width:16%; height:20%; min-width:44px; min-height:44px; padding:0; border:0; background:transparent; pointer-events:auto; cursor:pointer; }
.scene .island .busy-board-entry:focus-visible { outline:2px solid var(--focus); outline-offset:5px; }
.scene:not([data-scene="island"]) .busy-board-entry { visibility:hidden; pointer-events:none; }
.scene[data-scene="island"][aria-busy="false"] .overview-scene:has(#busy-board-entry:hover) .wash-busy,
.scene[data-scene="island"][aria-busy="false"] .overview-scene:has(#busy-board-entry:focus-visible) .wash-busy { transform:scale(1.08); opacity:.9; }
.scene:has(#busy-board-entry.is-visited) .wash-busy { opacity:.55; }
:root[data-morphing="busy-board"] .wash-busy { opacity:0; transition:none; }
:root[data-morphing="busy-board"] #reveal-paint { filter:hue-rotate(86deg); }
.project-view[data-project="busy-board"] { isolation:isolate; }
.project-view[data-project="busy-board"]::before { content:"";position:fixed;z-index:-1;top:var(--project-top,96px);inset-inline:0;bottom:0;background:url('assets/playground/paint-study.png') center/cover no-repeat;filter:hue-rotate(86deg);opacity:.14;pointer-events:none; }
.busy-board-project .project-body { width:min(100% - 48px,1120px); padding-top:20px; }
.busy-board-project .project-back { margin-bottom:12px; }
.busy-board-project .project-heading h1 { font-size:clamp(2rem,4vw,3rem);margin-bottom:14px; }
.busy-board-intro { font-size:16px;line-height:1.5;max-width:70ch; }
.busy-board-play-controls { display:flex;justify-content:space-between;align-items:center;gap:16px;flex-wrap:wrap;padding:0 0 4px;font-size:14px; }
.busy-board-paper { width:min(100%,500px);height:clamp(340px,calc(100svh - var(--project-top) - 200px),660px);margin:auto;background:#f3f3f1; }
#busy-board-player,#busy-board-player iframe { display:block;width:100%;height:100%;border:0; }
#busy-board-loading { font-size:14px; }
.busy-board-notes { margin-top:40px;padding-top:15px;scroll-margin-top:20px; }
.busy-board-notes-heading { display:flex;justify-content:space-between;align-items:center;gap:20px; }
.busy-board-notes h2 { font:600 clamp(26px,3vw,36px)/1.25 var(--font-heading); }
.busy-board-reflection { display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);align-items:center;gap:60px;margin-top:30px; }
.busy-board-reflection figure { position:relative;width:min(100%,400px);margin:0 auto; }
.busy-board-reflection img { display:block;width:100%;height:auto; }
.busy-board-reflection svg { position:absolute;inset:0;width:100%;height:100%;fill:none;stroke:#823d22;stroke-width:2;stroke-linecap:round;stroke-dasharray:1 6;pointer-events:none; }
.busy-board-reflection marker path { stroke-dasharray:none; }
.busy-board-reflection h3 { font:600 clamp(22px,2.5vw,28px)/1.3 var(--font-heading);margin:24px 0 14px; }
.busy-board-reflection p { font-size:16px;line-height:1.65;max-width:45ch; }
.busy-board-reflection .busy-board-status { font-size:13px;color:var(--soft-text);margin-top:24px; }
@media(max-width:760px) { .busy-board-project .project-body{width:calc(100% - 32px)}.busy-board-paper{width:100%;height:clamp(380px,calc(100svh - var(--project-top) - 210px),660px)}.busy-board-reflection{grid-template-columns:1fr;gap:12px}.busy-board-notes-heading{align-items:flex-start}.busy-board-notes-heading .text-control{flex-shrink:0;font-size:13px} }
/* A portrait board gets the available screen height, beside its context. */
@media(min-width:761px){
 .busy-board-project .project-body{display:grid;grid-template-columns:minmax(220px,.7fr) minmax(0,1.3fr);column-gap:36px;padding-top:16px}
 .busy-board-project .project-heading{grid-column:1;grid-row:1;align-self:start}
 .busy-board-project #busy-board-content{display:contents}
 .busy-board-project .busy-board-intro{grid-column:1;grid-row:1;align-self:start;margin-top:150px}
 .busy-board-project .busy-board-play-controls{grid-column:1;grid-row:1;align-self:start;flex-direction:column;align-items:flex-start;margin-top:252px;gap:12px}
 .busy-board-project .busy-board-paper{grid-column:2;grid-row:1;width:min(100%,540px);height:calc(100svh - var(--project-top) - 32px)}
 .busy-board-project #busy-board-loading{grid-column:2;grid-row:1;z-index:1;align-self:start}
 .busy-board-project .busy-board-notes{grid-column:1/-1;grid-row:2}
}
#busy-board-content[hidden]{display:none!important}
@media(max-width:760px){.busy-board-paper{height:clamp(380px,calc(100svh - var(--project-top) - 230px),660px)}}
:root[data-project="busy-board"]{--project-surface:var(--bg)}

/* Research tools occupy the approved machinery location. */
.wash-research{left:24%;top:54%;width:34%;height:33%;filter:hue-rotate(-114deg);transition:transform 240ms ease,opacity 240ms ease}
:root[data-placeholders="off"] .arrival-colour .wash-research{opacity:var(--wash-strength)}
.scene .island .research-entry{position:absolute;z-index:2;left:24%;top:54%;width:34%;height:33%;min-width:44px;min-height:44px;padding:0;border:0;background:transparent;pointer-events:auto;cursor:pointer}
.scene .research-entry:focus-visible{outline:2px solid var(--focus);outline-offset:5px}
.scene:not([data-scene="island"]) .research-entry{visibility:hidden;pointer-events:none}
.scene[data-scene="island"][aria-busy="false"]:has(#research-tools-entry:hover) .wash-research,
.scene[data-scene="island"][aria-busy="false"]:has(#research-tools-entry:focus-visible) .wash-research{transform:scale(1.045);opacity:.9}
.scene:has(#research-tools-entry.is-visited) .wash-research{opacity:.55}
:root[data-morphing="research-tools"] .wash-research{opacity:0;transition:none}
:root[data-morphing="research-tools"] #reveal-paint,:root[data-morphing="field-notes"] #reveal-paint{filter:hue-rotate(-114deg)}
:root[data-project="research-tools"],:root[data-project="field-notes"]{--project-surface:var(--bg)}
#research-tools-content[hidden],#field-notes-content[hidden]{display:none!important}
.research-project .project-body,.field-notes-project .project-body{width:min(100% - 48px,1120px);padding-top:20px}
.research-project .project-heading h1,.field-notes-project .project-heading h1{font-size:clamp(32px,4vw,48px);margin:10px 0 18px}
.research-project .project-body{position:relative;isolation:isolate;min-height:calc(100svh - var(--project-top) - 24px)}
.research-machinery-echo{position:absolute;z-index:-1;inset:90px 0 0;width:100%;height:70%;fill:none;stroke:var(--text);stroke-width:1;stroke-linecap:round;stroke-linejoin:round;opacity:.13;pointer-events:none}
.research-machinery-echo .solid{fill:var(--bg)}
.research-machinery-echo .interpretation-line{stroke-dasharray:4 3}
.research-intro{font-size:16px;line-height:1.6;max-width:65ch}
.research-options{display:flex;justify-content:space-around;align-items:center;gap:40px;min-height:340px;margin:30px 0}
.research-stain{position:relative;isolation:isolate;display:flex;flex-direction:column;justify-content:center;align-items:center;gap:12px;width:42%;min-height:210px;padding:20px;border:0;background:transparent;text-align:center;color:var(--text)}
.research-stain::before{content:"";position:absolute;z-index:-1;inset:0;background:url('assets/playground/paint-study.png') center/100% 100% no-repeat;filter:hue-rotate(-114deg);opacity:.65;transition:transform 240ms ease,opacity 240ms ease}
.research-stain strong{font:600 28px/1.3 var(--font-heading)}
.research-stain span{font-size:16px;line-height:1.5}
.research-stain small{font-size:13px}
button.research-stain:hover::before,button.research-stain:focus-visible::before{transform:scale(1.045);opacity:.9}
.testing-stain::before{filter:hue-rotate(-65deg);opacity:.4}
.field-notes-intro{font-size:16px;line-height:1.6;max-width:65ch;margin-bottom:24px}
.field-notes-layout{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,360px) minmax(0,1fr);gap:36px;align-items:center;position:relative}
.field-notes-phone{height:clamp(450px,calc(100svh - var(--project-top) - 200px),650px);border:2px solid #6e7774;border-radius:30px;padding:10px;background:#171d1b;overflow:hidden}
#field-notes-player,#field-notes-player iframe{display:block;width:100%;height:100%;border:0;border-radius:20px;background:#fafaf9}
.field-notes-callout h2{font:600 clamp(24px,2.4vw,30px)/1.25 var(--font-heading);margin:0 0 18px}
.field-notes-callout p{font-size:16px;line-height:1.65;max-width:32ch}
.field-notes-callout svg{display:block;width:100%;height:80px;fill:none;stroke:var(--focus);stroke-width:2;stroke-dasharray:1 6;stroke-linecap:round;pointer-events:none}
.field-notes-callout .text-control{font-size:15px;margin:10px 0 12px}
.field-notes-later{align-self:end;padding-bottom:16px}
.field-notes-hint,.field-notes-callout .field-notes-hint{font-size:13px;line-height:1.6;color:var(--soft-text)}
.field-notes-export{margin:50px 0 20px;scroll-margin-top:24px}
.field-notes-export h2{font:600 clamp(26px,3vw,36px)/1.25 var(--font-heading);max-width:28ch;margin-bottom:20px}
.field-notes-export>p{font-size:15px;line-height:1.6;max-width:70ch}
.field-notes-export dl{display:grid;grid-template-columns:1fr 1fr;gap:60px;margin:28px 0}
.field-notes-export dt{font-weight:700;font-size:16px;margin-bottom:14px}
.field-notes-export dd{margin:0;font-size:18px;line-height:1.6;max-width:40ch;overflow-wrap:anywhere}
.field-notes-export-actions{display:flex;flex-wrap:wrap;gap:24px;margin-top:20px}
.field-notes-export-actions button{font-size:14px}
@media(max-width:760px){
 .research-project .project-body,.field-notes-project .project-body{width:calc(100% - 32px)}
 .research-options{flex-direction:column;gap:24px;margin:24px 0;min-height:0}
 .research-stain{width:min(100%,350px);min-height:175px}
 .research-stain strong{font-size:26px}
 .field-notes-layout{grid-template-columns:1fr;gap:28px}
 .field-notes-phone{grid-row:1;width:min(100%,360px);justify-self:center;height:clamp(460px,calc(100svh - var(--project-top) - 190px),650px)}
 .field-notes-callout svg{display:none}
 .field-notes-callout p{max-width:65ch}
 .field-notes-later{padding-bottom:0}
 .field-notes-export dl{grid-template-columns:1fr;gap:28px}
}
/* Keep the portrait logger in the first desktop viewport, with notes beside it. */
@media(min-width:761px){
 .field-notes-project .project-body{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,320px) minmax(0,1fr);column-gap:40px;padding-top:16px}
 .field-notes-project .project-heading{grid-column:1;grid-row:1;align-self:start}
 .field-notes-project .project-back{margin-bottom:12px}
 .field-notes-project #field-notes-content,.field-notes-project .field-notes-layout{display:contents}
 .field-notes-intro{grid-column:1;grid-row:1;align-self:start;margin-top:150px}
 .field-notes-phone{grid-column:2;grid-row:1;height:calc(100svh - var(--project-top) - 32px);min-height:0}
 .field-notes-callout{grid-column:1;grid-row:1;align-self:start;margin-top:255px}
 .field-notes-callout h2{font-size:26px}
 .field-notes-callout svg{height:60px}
 .field-notes-later{grid-column:3;margin-top:0;align-self:center;padding-bottom:0}
 .field-notes-export{grid-column:1/-1;grid-row:2}
}
@media(max-width:760px){
 .field-notes-project .project-back{margin-bottom:12px}
 .field-notes-project .field-notes-phone{width:min(100%,320px);height:calc(100svh - var(--project-top) - 250px);min-height:400px}
}

.field-notes-project{isolation:isolate}
.field-notes-project::before{content:"";position:fixed;z-index:-1;top:var(--project-top,96px);inset-inline:0;bottom:0;background:url("assets/playground/paint-study.png") center/cover no-repeat;filter:hue-rotate(-114deg);opacity:.08;pointer-events:none}

/* A task, an activity and its evidence share the machinery setting. */
:root[data-project="testing-journeys"]{--project-surface:var(--bg)}
:root[data-morphing="testing-journeys"] #reveal-paint{filter:hue-rotate(-65deg)}
#testing-journeys-content[hidden]{display:none!important}
.testing-project{isolation:isolate}
.testing-project::before{content:"";position:fixed;z-index:-1;top:var(--project-top,96px);inset-inline:0;bottom:0;background:url('assets/playground/paint-study.png') center/cover no-repeat;filter:hue-rotate(-65deg);opacity:.09;pointer-events:none}
.testing-project .project-body{width:min(100% - 48px,1120px);padding-top:16px}
.testing-project .project-back{margin-bottom:12px}
.testing-project .project-heading h1{font-size:clamp(32px,4vw,48px);margin:10px 0 14px}
.testing-intro{font-size:16px;line-height:1.6;max-width:70ch}
.testing-controls{display:flex;justify-content:space-between;align-items:center;gap:24px;margin:12px 0}
.testing-contexts,.testing-playback{display:flex;flex-wrap:wrap;column-gap:22px;align-items:center}
.testing-controls button{font-size:14px;min-height:44px}
.testing-contexts [aria-pressed="true"]{text-decoration-color:var(--focus);text-decoration-thickness:2px;font-weight:700}
.testing-contexts [aria-pressed="false"]{text-decoration:none}
.testing-controls button:disabled{opacity:.5;cursor:default;text-decoration:none}
.testing-stages ol{display:flex;flex-wrap:wrap;column-gap:28px;row-gap:4px;list-style:none;padding:0;margin:0 0 24px}
.testing-stages button{min-height:44px;border:0;background:transparent;font:600 15px/1.4 var(--font-heading);color:var(--soft-text);padding:8px 0;text-decoration:underline;text-decoration-color:transparent;text-underline-offset:7px}
.testing-stages [aria-current="step"]{color:var(--text);text-decoration-color:var(--focus);text-decoration-thickness:2px}
.testing-workbench{display:grid;grid-template-columns:minmax(0,.8fr) minmax(0,1.4fr) minmax(0,.9fr);gap:38px;align-items:start;min-height:320px}
.testing-workbench h2{font:600 clamp(24px,2.5vw,30px)/1.25 var(--font-heading);margin:0 0 18px}
.testing-workbench p{font-size:15px;line-height:1.65;max-width:42ch}
.testing-task figure{margin:24px 0 0}
.testing-task img{width:100%;height:auto;display:block}
.testing-task figcaption{font-size:12px;line-height:1.5;margin-top:10px;color:var(--soft-text)}
.testing-task a{display:inline-block;min-height:44px;font-size:14px;line-height:1.6;margin-top:22px}
.testing-stage{padding:24px;background:#f6f5ed;color:#1a2927;min-height:310px}
.testing-stage h2{font-size:28px;max-width:20ch}
.testing-stage h3{font:600 24px/1.3 var(--font-heading);margin:0 0 12px}
.testing-stage p{margin:0 0 18px}
.testing-stage .testing-large-prompt{font-size:24px;line-height:1.45;margin:24px 0}
.testing-task-route{display:flex;align-items:center;gap:10px;margin:24px 0;font-size:16px;line-height:1.5}
.testing-task-route svg{width:70px;flex-shrink:0;fill:none;stroke:#226052;stroke-width:2;stroke-linecap:round;stroke-dasharray:1 5}
.testing-annotation{padding-top:28px}
.testing-annotation>svg{display:block;width:100%;height:70px;overflow:visible;fill:none;stroke:var(--focus);stroke-width:2;stroke-dasharray:1 6;stroke-linecap:round;margin-bottom:20px;pointer-events:none}
.testing-annotation .testing-reflection{font-size:13px;color:var(--soft-text);margin-top:22px}
.testing-stage .testing-small{font-size:12px;line-height:1.6;color:#435550;margin:16px 0 0}
.testing-range-label{display:block;font-size:15px;font-weight:600;line-height:1.5;margin:24px 0 16px}
.testing-numberline input{width:100%;min-height:44px;accent-color:#226052;cursor:ew-resize}
.testing-numberline>div{display:flex;justify-content:space-between;font-size:12px;font-variant-numeric:tabular-nums}
.testing-answer-options{display:flex;gap:16px;margin-top:20px}
.testing-answer-options button{flex:1;min-height:44px;border:1px solid #647a73;background:transparent;border-radius:6px;color:inherit;font:600 16px var(--font-heading);cursor:pointer}
.testing-answer-options button:disabled{opacity:.45;cursor:default}
.testing-answer-options [aria-pressed="true"]{background:#226052;color:#fff}
.testing-stage :focus-visible{outline:2px solid #226052;outline-offset:4px}
.testing-stage ::selection{background:#beddd2;color:#142a23}
.testing-example-response{margin:24px 0}
.testing-example-response span{display:block;font-size:13px;margin-bottom:12px}
.testing-example-response strong{font-size:24px;line-height:1.4}
.testing-reader{margin:0}
.testing-reader>div,.testing-proposal dl>div{margin:0 0 20px}
.testing-reader dt,.testing-proposal dt{font-weight:600;font-size:13px;line-height:1.5;margin-bottom:7px}
.testing-reader dd,.testing-proposal dd{font-size:17px;line-height:1.5;margin:0}
.testing-stage summary{min-height:44px;padding:12px 0;cursor:pointer;text-underline-offset:5px}
.testing-stage details p{margin:12px 0;font-size:14px}
.testing-stage code{font-size:13px;white-space:normal;overflow-wrap:anywhere}
.testing-stage-status{font-size:13px;line-height:1.5;margin:22px 0 12px;color:var(--soft-text)}
.testing-demo-note{font-size:12px;line-height:1.6;max-width:90ch;color:var(--soft-text);margin-bottom:24px}
.testing-stain::before{opacity:.65}
@media(max-width:760px){
 .testing-project .project-body{width:calc(100% - 32px)}
 .testing-controls{display:block;margin:12px 0 16px}
 .testing-playback{margin-top:6px}
 .testing-stages ol{column-gap:20px;row-gap:0;margin-bottom:20px}
 .testing-stages li{width:calc(50% - 10px)}
 .testing-stages button{font-size:14px;text-align:left}
 .testing-workbench{grid-template-columns:1fr;gap:26px}
 .testing-task{grid-row:2}
 .testing-stage{grid-row:1;padding:20px;min-height:0}
 .testing-task figure{width:min(100%,320px)}
 .testing-annotation{padding-top:0}
 .testing-annotation>svg{display:none}
 .testing-stage-status{margin-top:24px}
}
@media(min-width:761px){
 .testing-project .project-body{display:grid;grid-template-columns:minmax(0,1fr) minmax(0,1fr);column-gap:40px}
 .testing-project .project-heading{grid-column:1;grid-row:1}
 .testing-project #testing-journeys-content{display:contents}
 .testing-intro{grid-column:2;grid-row:1;align-self:center}
 .testing-controls{grid-column:1/-1;grid-row:2;margin:0 0 8px}
 .testing-stages{grid-column:1/-1;grid-row:3}
 .testing-workbench{grid-column:1/-1;grid-row:4}
 .testing-stage-status,.testing-demo-note{grid-column:1/-1}
 .testing-annotation{padding-top:0}
 .testing-annotation>svg{height:50px;margin-bottom:16px}
}

/* One annotated SpellQuest encounter; research remains optional depth. */
.spellquest-moment.spellquest-annotated{display:block;min-height:0}
.spellquest-moment.spellquest-annotated[hidden]{display:none}
.spellquest-annotation-scene{position:relative;display:grid;grid-template-columns:minmax(140px,1fr) minmax(0,640px) minmax(140px,1fr);grid-template-rows:1fr 1fr;gap:12px 24px;align-items:center}
.spellquest-annotation-scene figure{grid-column:2;grid-row:1/3;margin:0}
.spellquest-annotation-scene figure img{display:block;width:100%;height:auto}
.spellquest-annotation-scene figcaption{font-size:12px;line-height:1.5;color:var(--soft-text);margin-top:10px}
.spellquest-callout{position:relative;z-index:1;max-width:24ch;padding:8px 0}
.spellquest-callout strong{display:block;font:600 22px/1.3 var(--font-heading);margin-bottom:14px}
.spellquest-callout strong span{display:inline-block;font-size:13px;font-weight:400;vertical-align:middle;margin-right:6px;color:var(--focus)}
.spellquest-callout p{font-size:15px;line-height:1.6;margin:0}
.callout-context{grid-column:1;grid-row:1;align-self:end}
.callout-audio{grid-column:3;grid-row:1;align-self:end}
.callout-explore{grid-column:3;grid-row:2;align-self:start;margin-top:20px}
.spellquest-callout-arrows{position:absolute;inset:0;width:100%;height:100%;overflow:visible;pointer-events:none;fill:none;stroke:#9f75ad;stroke-width:1.7;stroke-linecap:round;stroke-dasharray:1 6}
.spellquest-callout-arrows marker path{stroke-dasharray:none}
.spellquest-mobile-keys{display:none}
.spellquest-research-detail{margin:24px 0 12px;max-width:70ch;font-size:15px;line-height:1.65}
.spellquest-research-detail summary{min-height:44px;padding:10px 0;cursor:pointer;text-decoration:underline;text-underline-offset:5px}
.spellquest-research-detail p{margin:14px 0}
.field-notes-readiness{font-size:14px;line-height:1.6;max-width:40ch}
.field-notes-readiness p{margin:8px 0}
.field-notes-readiness button{font-size:14px}
#field-notes-review:disabled,#field-notes-preview:disabled{opacity:.5;cursor:default;text-decoration:none}
@media(min-width:761px){.field-notes-readiness{grid-column:3;grid-row:1;align-self:start;z-index:2;margin-top:6px}}
@media(max-width:760px){
 .spellquest-annotation-scene{grid-template-columns:1fr;grid-template-rows:auto;gap:20px}
 .spellquest-annotation-scene figure{grid-column:1;grid-row:1}
 .spellquest-callout{grid-column:1;grid-row:auto;max-width:55ch;padding:0;margin:0}
 .spellquest-callout strong{font-size:22px;margin-bottom:8px}
 .spellquest-mobile-keys{display:block;fill:#714881;stroke:none;font:700 13px var(--font-heading);text-anchor:middle}
 .spellquest-research-detail{margin-top:24px}
}

/* Full-window play stays available alongside the embedded experience and notes. */
.full-size-link{display:inline-flex;align-items:center;justify-content:center;gap:8px;min-height:44px;padding:8px 12px;border:1px solid currentColor;border-radius:6px;font:600 14px/1.4 var(--font-heading);color:var(--text);text-decoration:none;white-space:nowrap}
.full-size-link small{font-size:12px;font-weight:400}
.full-size-link:hover{text-decoration:underline;text-underline-offset:4px}
.full-size-link:focus-visible{outline:2px solid var(--focus);outline-offset:4px}
.spellquest-return-actions{display:flex;align-items:center;flex-wrap:wrap;gap:16px}
.spellquest-return-actions .text-control{min-height:44px}
@media(max-width:760px){.spellquest-thinking-heading{flex-direction:column;align-items:flex-start;gap:10px}.spellquest-return-actions{gap:12px}}
