/* Standalone scroll chapter: native sticky remains independent of GSAP/WebGPU. */
.scan-story{position:relative;background:#0b0d23;color:#edf3ff;border-bottom:1px solid #ffffff12}
.scan-sticky{position:relative;padding:96px max(5vw,24px) 28px;max-width:1600px;margin:auto}
.scan-heading{position:relative;z-index:2}.scan-eyebrow{font-size:10px;letter-spacing:.19em;color:#a4c9f6}.scan-heading h2{font-size:clamp(38px,4.2vw,68px);line-height:1.03;letter-spacing:-.05em;font-weight:500;margin:20px 0 12px}.scan-heading em{font-style:normal;color:#a4c9f6}.scan-heading>p{font-size:15px;color:#aab2ca;margin:0}
.scan-layout{display:grid;grid-template-columns:1.35fr 1fr;gap:7%;align-items:center;margin-top:12px}.scan-stage{height:clamp(360px,49vh,600px);position:relative;isolation:isolate;background:radial-gradient(ellipse at 50% 50%,#585fb725,transparent 65%)}.scan-anatomy,.scan-poster{position:absolute;inset:0;width:100%;height:100%;object-fit:contain}.scan-anatomy{opacity:0;transition:opacity .3s}.scan-stage.is-rendered .scan-anatomy{opacity:1}.scan-stage.is-rendered .scan-poster{visibility:hidden}.scan-orbit{position:absolute;width:74%;height:65%;left:13%;top:18%;border:1px solid #a4c9f61a;border-radius:50%;transform:rotate(-26deg)}.scan-orbit:after{content:'';position:absolute;inset:20%;border:1px solid #a4c9f60d;border-radius:50%}.scan-stage-top,.scan-stage-bottom{position:absolute;left:0;right:0;display:flex;justify-content:space-between;gap:12px;font-size:9px;letter-spacing:.12em;color:#a4c9f680;z-index:2}.scan-stage-top{top:8px}.scan-stage-bottom{bottom:8px;font-size:8px}.scan-view{color:#eb9c7f}.scan-steps{list-style:none;margin:0;padding:0}.scan-steps li{border-top:1px solid #ffffff20;padding:0 0 20px}.scan-steps button{display:flex;align-items:center;gap:24px;width:100%;text-align:left;font:inherit;font-size:14px;color:#8c97b5;background:transparent;border:0;padding:18px 0;cursor:pointer}.scan-steps button span{font-size:10px;color:#a4c9f6;font-variant-numeric:tabular-nums}.scan-steps button:focus-visible{outline:2px solid #eb9c7f;outline-offset:5px}.scan-steps .is-active button{color:#fff}.scan-step-body h3{font-size:clamp(26px,2.8vw,43px);line-height:1.1;letter-spacing:-.035em;font-weight:500;margin:5px 0 16px}.scan-step-body p{font-size:15px;line-height:1.65;color:#aab2ca;max-width:355px;margin:0 0 14px}.scan-disclaimer{font-size:10px;line-height:1.6;color:#919bb8;max-width:365px;margin:16px 0 0}.scan-progress{height:1px;background:#ffffff16;margin-top:24px}.scan-progress span{display:block;width:100%;height:100%;background:linear-gradient(90deg,#a4c9f6,#eb9c7f);transform:scaleX(var(--scan-progress,0));transform-origin:left}
@media(prefers-reduced-motion:no-preference){.scan-story.is-enhanced{height:320svh}.is-enhanced .scan-sticky{position:sticky;top:0;min-height:100svh;display:flex;flex-direction:column;justify-content:center;padding-top:85px}.is-enhanced .scan-step-body{display:grid;grid-template-rows:0fr;opacity:0;overflow:hidden;height:0}.is-enhanced .is-active .scan-step-body{display:block;height:auto;opacity:1}.is-enhanced .scan-steps li{padding-bottom:0}.is-enhanced .scan-steps .is-active{padding-bottom:20px}}
@media(max-width:700px){.scan-sticky{padding:80px 22px 30px}.scan-heading h2{font-size:37px;margin:12px 0 9px}.scan-heading>p{font-size:12px}.scan-eyebrow{font-size:8px}.scan-layout{grid-template-columns:1fr;gap:10px;margin-top:12px}.scan-stage{height:32svh;min-height:210px;max-height:310px}.scan-stage-top,.scan-stage-bottom{font-size:7px}.scan-step-body h3{font-size:27px;margin:0 0 9px}.scan-step-body h3 br{display:none}.scan-step-body p{font-size:12px;line-height:1.55;max-width:100%;margin-bottom:8px}.scan-steps button{padding:12px 0;font-size:12px;gap:16px}.scan-disclaimer{font-size:8px;margin-top:10px;max-width:100%}.scan-progress{margin-top:15px}.scan-steps li{padding-bottom:12px}.is-enhanced .scan-sticky{padding-top:72px;padding-bottom:18px}.is-enhanced .scan-steps .is-active{padding-bottom:10px}}
@media(max-height:700px) and (min-width:701px){.scan-heading h2{font-size:38px}.scan-sticky{padding-top:75px!important}.scan-stage{height:43svh}.scan-step-body h3{font-size:29px}.scan-step-body p{font-size:13px}.scan-steps button{padding:12px 0}}
@media(prefers-reduced-motion:reduce){.scan-anatomy{transition:none}}
/* hidden on body creates a separate scroll container and breaks native sticky. */
body{overflow-x:clip}
@media(max-width:700px) and (max-height:740px) and (prefers-reduced-motion:no-preference){.is-enhanced .scan-sticky{padding-top:95px;padding-bottom:12px}.scan-heading h2{font-size:29px;margin:8px 0}.scan-heading>p{font-size:10px}.scan-layout{margin-top:5px;gap:4px}.scan-stage{height:27svh;min-height:155px}.scan-step-body h3{font-size:23px}.scan-step-body p{font-size:11px}.scan-steps button{padding:9px 0}.scan-disclaimer{font-size:7px;margin-top:7px}.scan-progress{margin-top:9px}}
/* Immersive edition: the illustration fills the viewport; copy floats above it. */
@media(min-width:701px) and (prefers-reduced-motion:no-preference){
.is-enhanced .scan-sticky{max-width:none;isolation:isolate;overflow:clip;justify-content:flex-start;padding-top:145px}
.is-enhanced .scan-heading{max-width:440px;pointer-events:none}
.is-enhanced .scan-heading h2{font-size:clamp(40px,4.1vw,68px)}
.is-enhanced .scan-layout{display:contents}
.is-enhanced .scan-stage{position:absolute;inset:0;height:100%;width:100%;z-index:-1;background:radial-gradient(ellipse at 56% 48%,#39458132,transparent 58%)}
.is-enhanced .scan-stage:after{content:'';position:absolute;inset:0;pointer-events:none;background:linear-gradient(90deg,#0b0d23b8 0%,transparent 35%,transparent 62%,#0b0d2360 100%)}
.is-enhanced .scan-stage-top{top:120px;left:49%;right:5%}.is-enhanced .scan-stage-bottom{bottom:65px;left:5%;right:5%}
.is-enhanced .scan-orbit{width:50%;height:73%;left:31%;top:16%;border-color:#a4c9f618}
.is-enhanced .scan-copy{position:absolute;right:5%;bottom:15%;width:clamp(260px,25vw,390px);padding:25px;background:linear-gradient(135deg,#0b0d23df,#0b0d23a8);border:1px solid #a4c9f61a;border-radius:18px;backdrop-filter:blur(12px)}
.is-enhanced .scan-step-body h3{font-size:clamp(27px,2.5vw,39px)}.is-enhanced .scan-step-body p{font-size:13px}
.is-enhanced .scan-disclaimer{font-size:9px}
.is-enhanced .scan-progress{position:absolute;left:5%;right:5%;bottom:35px;margin:0}
}
@media(min-width:701px) and (max-height:740px) and (prefers-reduced-motion:no-preference){.is-enhanced .scan-sticky{padding-top:125px!important}.is-enhanced .scan-heading h2{font-size:38px}.is-enhanced .scan-copy{bottom:12%;padding:18px;width:290px}.is-enhanced .scan-stage-top{top:110px}.is-enhanced .scan-step-body h3{font-size:26px}.is-enhanced .scan-steps button{padding:10px 0}}
/* Keep UI independent of the continuously rendered canvas. No live backdrop sampling. */
html{scrollbar-gutter:stable}
body.scan-active .nav{background:rgba(11,13,35,.62);backdrop-filter:blur(14px) saturate(1.2);-webkit-backdrop-filter:blur(14px) saturate(1.2);transition:background .25s}
.scan-story .scan-copy{backdrop-filter:none;-webkit-backdrop-filter:none;background:#0d1129;contain:paint}

.scan-progress{height:2px}
.scan-progress span{width:0;transform:none}
@media(min-width:701px) and (prefers-reduced-motion:no-preference){
.is-enhanced .scan-stage{z-index:0;pointer-events:none}
.is-enhanced .scan-heading{z-index:2}
.is-enhanced .scan-copy{z-index:3;background:linear-gradient(135deg,#0c1027,#10152d)}
.is-enhanced .scan-progress{z-index:4}
}
.scan-progress{background:#252b46;isolation:isolate}

/* Three chapters share one fixed reading area. Only the content crossfades. */
@media(prefers-reduced-motion:no-preference){
.is-enhanced .scan-steps{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));column-gap:12px;row-gap:25px}
.is-enhanced .scan-steps li,.is-enhanced .scan-steps .is-active{display:contents;padding:0;border:0}
.is-enhanced .scan-steps button{grid-row:1;min-width:0;display:flex;flex-direction:column;align-items:flex-start;justify-content:flex-start;gap:8px;height:100%;padding:0 0 14px;border-bottom:2px solid #28304d;font-size:11px;line-height:1.4;transition:color .22s,border-color .22s}
.is-enhanced .scan-steps li:nth-child(1) button{grid-column:1}.is-enhanced .scan-steps li:nth-child(2) button{grid-column:2}.is-enhanced .scan-steps li:nth-child(3) button{grid-column:3}
.is-enhanced .scan-steps .is-active button{border-color:#eb9c7f;color:#fff}
.is-enhanced .scan-steps .scan-step-body,.is-enhanced .scan-steps .is-active .scan-step-body{grid-area:2/1/3/4;display:block;height:auto;overflow:visible;min-width:0;opacity:0;visibility:hidden;pointer-events:none;transform:translateY(10px);transition:opacity .24s ease,transform .32s cubic-bezier(.22,1,.36,1),visibility 0s linear .32s}
.is-enhanced .scan-steps .is-active .scan-step-body{opacity:1;visibility:visible;pointer-events:auto;transform:translateY(0);transition:opacity .28s ease,transform .32s cubic-bezier(.22,1,.36,1),visibility 0s}
.is-enhanced .scan-disclaimer{margin-top:24px}
}
@media(max-width:700px) and (prefers-reduced-motion:no-preference){
.is-enhanced .scan-steps{row-gap:16px;column-gap:14px}
.is-enhanced .scan-steps button{font-size:10px;padding-bottom:10px;gap:5px}
.is-enhanced .scan-disclaimer{margin-top:15px}
}
@media(prefers-reduced-motion:reduce){
.scan-story .scan-step-body{display:block;height:auto;opacity:1;visibility:visible;transform:none;transition:none}
}

/* The left-hand title follows the selected chapter; paragraph stays in the control panel. */
.scan-title-stack{display:none}
@media(prefers-reduced-motion:no-preference){
.is-enhanced .scan-title-fallback{display:none}
.is-enhanced .scan-title-stack{display:grid}
.is-enhanced .scan-title-frame{grid-area:1/1;opacity:0;visibility:hidden;transform:translateY(12px);transition:opacity .24s,transform .34s cubic-bezier(.22,1,.36,1),visibility 0s linear .34s}
.is-enhanced .scan-title-frame>span,.is-enhanced .scan-title-frame>em{display:block}
.is-enhanced .scan-title-frame.is-active{opacity:1;visibility:visible;transform:none;transition:opacity .28s,transform .34s cubic-bezier(.22,1,.36,1),visibility 0s}
.is-enhanced .scan-step-body h3{display:none}
}
@media(min-width:701px) and (prefers-reduced-motion:no-preference){.is-enhanced .scan-heading{max-width:clamp(340px,30vw,500px)}}

/* Requested glass on the reading panel; existing stable frame and layer order stay. */
.scan-story.is-enhanced .scan-copy{background:linear-gradient(135deg,rgba(17,22,49,.76),rgba(21,27,54,.60));backdrop-filter:blur(14px) saturate(1.15);-webkit-backdrop-filter:blur(14px) saturate(1.15);border-color:#c7dcff30}
@media(min-width:701px) and (prefers-reduced-motion:no-preference){
.is-enhanced .scan-heading{margin-top:clamp(35px,7vh,80px)}
}
/* Larger reading sizes in the lower-right panel. */
.scan-story.is-enhanced .scan-step-body p{font-size:16px;line-height:1.65}
.scan-story.is-enhanced .scan-steps button{font-size:13px}
.scan-story.is-enhanced .scan-disclaimer{font-size:11px;line-height:1.6}
@media(max-width:700px){.scan-story.is-enhanced .scan-step-body p{font-size:14px;line-height:1.6}.scan-story.is-enhanced .scan-steps button{font-size:12px}.scan-story.is-enhanced .scan-disclaimer{font-size:10px}}
@media(max-width:700px) and (max-height:740px){.is-enhanced .scan-sticky{padding-top:95px;padding-bottom:12px;justify-content:flex-start}.scan-story.is-enhanced .scan-stage{height:24svh;min-height:145px}.scan-story.is-enhanced .scan-step-body p{font-size:13px;line-height:1.5}.scan-story.is-enhanced .scan-disclaimer{font-size:9px;line-height:1.45}.scan-story.is-enhanced .scan-steps{row-gap:12px}.scan-story.is-enhanced .scan-disclaimer{margin-top:12px}}

/* Mobile uses the same immersive chapter instead of a small boxed canvas. */
@media(max-width:700px) and (prefers-reduced-motion:no-preference){
.scan-story.is-enhanced .scan-sticky{height:100svh;min-height:0;max-width:none;padding:112px 22px 24px;justify-content:flex-start;isolation:isolate;overflow:clip}
.scan-story.is-enhanced .scan-heading{z-index:2;pointer-events:none}
.scan-story.is-enhanced .scan-heading h2{font-size:clamp(28px,7.6vw,36px);margin:10px 0 8px;max-width:350px}
.scan-story.is-enhanced .scan-heading>p{font-size:12px;max-width:310px;line-height:1.5}
.scan-story.is-enhanced .scan-layout{display:contents}
.scan-story.is-enhanced .scan-stage{position:absolute;inset:0;width:100%;height:100%;min-height:0;max-height:none;z-index:0;pointer-events:none}
.scan-story.is-enhanced .scan-stage::after{content:'';position:absolute;inset:0;background:linear-gradient(180deg,#0b0d23e8 0%,#0b0d23b0 25%,transparent 46%,transparent 66%,#0b0d2350 100%)}
.scan-story.is-enhanced .scan-stage-top,.scan-story.is-enhanced .scan-stage-bottom,.scan-story.is-enhanced .scan-orbit{display:none}
.scan-story.is-enhanced .scan-copy{position:absolute;left:18px;right:18px;bottom:38px;z-index:3;padding:16px;border:1px solid #c7dcff30;border-radius:18px}
.scan-story.is-enhanced .scan-steps{row-gap:12px;column-gap:10px}
.scan-story.is-enhanced .scan-steps button{font-size:12px;min-height:53px;gap:5px;padding-bottom:10px}
.scan-story.is-enhanced .scan-step-body p{font-size:14px;line-height:1.5;margin:0}
.scan-story.is-enhanced .scan-disclaimer{font-size:9px;line-height:1.45;margin-top:14px}
.scan-story.is-enhanced .scan-progress{position:absolute;left:22px;right:22px;bottom:20px;margin:0;z-index:4}
}
@media(max-width:700px) and (max-height:740px) and (prefers-reduced-motion:no-preference){
.scan-story.is-enhanced .scan-sticky{padding-top:103px}
.scan-story.is-enhanced .scan-heading h2{font-size:27px;margin:8px 0}
.scan-story.is-enhanced .scan-heading>p{font-size:11px}
.scan-story.is-enhanced .scan-copy{bottom:30px;padding:13px}
.scan-story.is-enhanced .scan-step-body p{font-size:13px}
.scan-story.is-enhanced .scan-disclaimer{font-size:8px;margin-top:10px}
.scan-story.is-enhanced .scan-progress{bottom:14px}
}

/* Stable loading surface: never expose the old coarse SVG or an incomplete GL frame. */
.scan-stage .scan-poster{object-fit:cover;object-position:60% 50%;visibility:visible}
.scan-loading{display:none;position:absolute;left:60%;top:47%;transform:translate(-50%,-50%);z-index:1;align-items:center;gap:10px;font-size:11px;letter-spacing:.03em;color:#c6d9f0;white-space:nowrap;pointer-events:none}
.scan-loading-mark{display:grid;place-items:center;width:34px;height:34px;border:1px solid #a4c9f640;border-radius:50%;color:#eb9c7f;font-size:10px}
.js .scan-stage:is([data-state="pending"],[data-state="loading"]) .scan-loading{display:flex}
.js .scan-stage:is([data-state="pending"],[data-state="loading"]) .scan-poster{visibility:hidden;opacity:0}
.scan-stage:not([data-state="ready"]) .scan-anatomy{opacity:0!important;visibility:hidden}
.scan-stage[data-state="ready"] .scan-anatomy{opacity:1;visibility:visible;transition:opacity .45s ease}
.scan-stage[data-state="ready"] .scan-poster{visibility:hidden;opacity:0}
.scan-stage:is([data-state="static"],[data-state="fallback"]) .scan-poster{opacity:1;visibility:visible}
.scan-stage[data-state="fallback"] .scan-loading{display:flex;top:auto;bottom:84px;left:50%;padding:8px 12px;background:#0b0d23c9;border-radius:999px;font-size:10px}
.scan-stage[data-state="fallback"] .scan-loading-mark{display:none}
@media(max-width:700px){.scan-loading{left:50%;top:43%}.scan-stage[data-state="fallback"] .scan-loading{bottom:auto;top:39%}.scan-stage .scan-poster{object-position:62% 50%}}
@media(prefers-reduced-motion:reduce){.scan-stage .scan-anatomy{transition:none!important}.scan-stage .scan-loading{display:none!important}.scan-stage .scan-poster{opacity:1!important;visibility:visible!important}}

.scan-continue {
  display: inline-flex;
  align-items: center;
  gap: .6em;
  min-height: 44px;
  padding: 0 14px;
  margin-top: 12px;
  width: fit-content;
  border: 1px solid #a4c9f680;
  border-radius: 24px;
  background: #10152d;
  color: #fff;
  font-size: 14px;
  text-decoration: none;
}
.scan-continue span { font-size: 20px; }
.scan-continue:focus-visible { outline: 2px solid white; outline-offset: 2px; }
.scan-story.is-enhanced .scan-continue {
  position: absolute;
  left: 5%;
  bottom: 42px;
  z-index: 5;
}
.scan-story.is-enhanced .scan-stage-bottom { bottom: 98px; }
@media (max-width: 700px) {
  .scan-story.is-enhanced .scan-continue { left: 18px; bottom: 22px; }
  .scan-story.is-enhanced .scan-copy { bottom: 74px; }
}
