/* Story page group v3 (12 Nov 2026): about, method, testimonials, beyond-the-syllabus.
   Loaded after site-v3.css. Colours are the --ib-* tokens only. Prefix st-. Pairs with assets/js/story-v3.js.
   Gates: html.sv3-m (set in the head: motion allowed) for entrances, html.st-on (set by story-v3.js: motion allowed and
   the script is running) for every dimmed, hidden or pinned state. Without JavaScript, or with reduced motion, every
   page is complete: all copy at full strength, every figure drawn, the testimonials in their grid. */

:root { --st-in: cubic-bezier(.23, 1, .32, 1); --st-move: cubic-bezier(.77, 0, .175, 1); }

/* ======================================================================================================
   ABOUT: the flight path
   ====================================================================================================== */
.st-flight { position: relative; isolation: isolate; overflow-x: clip;
  background: radial-gradient(ellipse at top right, color-mix(in srgb, var(--ib-accent) 9%, transparent), transparent 50%), var(--ib-bg); }
.st-flight > .ib-page-hero { background: none; position: relative; z-index: 1; }
.st-flight > .ib-section { position: relative; z-index: 1; }
.st-trail { position: absolute; left: 0; top: 0; width: 100%; height: 100%; z-index: 0; pointer-events: none; overflow: visible; }
.st-line { fill: none; stroke-linecap: round; stroke-linejoin: round; vector-effect: non-scaling-stroke; }
.st-line-ghost { stroke: var(--ib-line-strong); stroke-width: 1.4; stroke-dasharray: 2 9; opacity: .8; }
.st-line-main { stroke: var(--ib-accent); stroke-width: 2.4; }
.st-head { fill: var(--ib-accent); }
.st-halo { fill: var(--ib-accent); opacity: .22; transform-box: fill-box; transform-origin: center; }
.st-node { fill: var(--ib-bg); stroke: var(--ib-line-strong); stroke-width: 1.6; }
.st-node.is-lit { fill: var(--ib-accent); stroke: var(--ib-accent); }
.st-far ellipse { fill: none; stroke: var(--ib-ink); stroke-opacity: .1; stroke-width: 1; stroke-dasharray: 3 7; vector-effect: non-scaling-stroke; }
.st-far { transform: translate(calc(var(--st-px, 0) * -34px), calc(var(--st-py, 0) * -22px)); transition: transform .8s var(--st-in); }

/* The four facts of the opening stand on a rising line, each one a waypoint. */
.st-facts { max-width: 44rem; }
.st-fact { display: block; }
.st-fact.ib-badge { display: inline-flex; }
@media (min-width: 900px) {
  .st-about .ib-page-hero h1 { max-width: 48.75rem; }
  .st-about .st-facts { max-width: none; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1.6rem; align-items: start; margin-top: .4rem; }
  .st-about .st-facts .st-fact { font-size: 1rem; line-height: 1.55; }
}
@media (max-width: 899.98px) { .st-about .st-facts .st-fact { padding-left: 1.1rem; margin-top: .5rem; } }
html.st-on .st-fact:not(.st-end) { transition: filter .7s ease, scale .7s var(--st-in); transform-origin: left center; }
html.st-on .st-fact:not(.is-lit):not(.st-end) { filter: opacity(.3); scale: .985; }

/* Portrait: three planes. Back plane (rings), middle plane (an offset sheet), then the photograph. */
.st-portrait { position: relative; }
.st-depth { position: relative; max-width: 22.5rem; }
.st-depth img { position: relative; z-index: 2; transform: translate3d(calc(var(--st-px, 0) * 7px), calc(var(--st-py, 0) * 5px + var(--st-sy, 0) * 8px), 0); transition: transform .6s var(--st-in); }
.st-plane { position: absolute; inset: 0; z-index: 1; border-radius: var(--ib-radius); background: color-mix(in srgb, var(--ib-accent) 13%, var(--ib-bg-deep)); border: 1px solid var(--ib-line);
  transform: translate3d(calc(14px + var(--st-px, 0) * 17px), calc(14px + var(--st-py, 0) * 12px + var(--st-sy, 0) * -6px), 0); transition: transform .7s var(--st-in); }
.st-ring { position: absolute; z-index: 0; inset: -10% -13% -4% -13%; border-radius: 50%; border: 1px dashed color-mix(in srgb, var(--ib-accent) 60%, transparent);
  transform: translate3d(calc(var(--st-px, 0) * -26px), calc(var(--st-py, 0) * -16px + var(--st-sy, 0) * -26px), 0) rotate(-16deg); transition: transform .9s var(--st-in); }
.st-ring2 { inset: 8% -24% 10% -24%; border-color: var(--ib-line-strong); border-style: solid; opacity: .8;
  transform: translate3d(calc(var(--st-px, 0) * -44px), calc(var(--st-py, 0) * -26px + var(--st-sy, 0) * -42px), 0) rotate(11deg); }
.st-ring { transition: transform .9s var(--st-in), opacity .8s ease; }
html.st-on .st-portrait:not(.is-lit) .st-ring { opacity: .25; }
html.st-on .st-portrait:not(.is-lit) .st-plane { opacity: .35; }
.st-portrait figcaption { position: relative; z-index: 2; }

/* Why space: the four lines of a class step in */
.st-steps li { position: relative; padding-left: 1.2rem; }
.st-steps li::before { content: ""; position: absolute; left: 0; top: .78em; width: .5rem; height: .5rem; border-radius: 50%; background: var(--ib-accent); scale: 1; transition: scale .5s var(--st-in); }
html.st-on .st-steps li { transition: filter .6s ease, translate .6s var(--st-in); }
html.st-on .st-steps li:not(.is-lit) { filter: opacity(.28); translate: .6rem 0; }
html.st-on .st-steps li:not(.is-lit)::before { scale: .4; }

/* ======================================================================================================
   METHOD: a pinned heading column, six principles stepping past
   ====================================================================================================== */
.st-m-grid { display: grid; gap: 2.4rem; }
html.sv3-m:not(.sv3-chrome) body.st-method .ib-page-hero > .ib-container > .st-m-head,
html.sv3-m:not(.sv3-chrome) body.st-method .ib-page-hero > .ib-container > .st-m-list { animation: none; }
.st-m-head .ib-eyebrow { display: block; }
html.sv3-m .st-m-head .ib-mth-lede { animation: sv3-up .7s var(--st-in) .12s backwards; }
html.sv3-m .st-m-head .ib-eyebrow { animation: sv3-up .6s var(--st-in) .02s backwards; }
.st-method .ib-page-hero h1 { font-size: clamp(2.3rem, 9vw, 2.9rem); }
.st-idx { display: flex; flex-wrap: wrap; gap: .3rem 1.1rem; margin-top: 2rem; position: relative; padding-bottom: .9rem; cursor: pointer; }
.st-idx span { font-size: clamp(1.7rem, 2.6vw, 2.3rem); font-weight: 800; letter-spacing: -.03em; line-height: 1; color: var(--ib-ink); font-variant-numeric: tabular-nums; transition: opacity .5s ease, translate .5s var(--st-in), color .3s ease; }
html.sv3-m .st-idx span { animation: st-num .75s var(--st-in) calc(.12s + var(--i, 0) * .07s) backwards; }
html.st-on .st-idx span { opacity: .22; }
html.st-on .st-idx span.is-past { opacity: .5; }
html.st-on .st-idx span.is-on { opacity: 1; translate: 0 -.18rem; color: var(--ib-accent); }
.st-idx::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 2px; background: var(--ib-accent); transform: scaleX(var(--st-p, 1)); transform-origin: left; transition: transform .7s var(--st-move); }
@keyframes st-num { from { opacity: 0; translate: 0 6px; } to { opacity: 1; translate: 0 0; } }

.st-m-list.ib-prin { display: block; margin-top: 0; counter-reset: stn; }
.st-m-list .ib-prin__item { counter-increment: stn; position: relative; display: grid; grid-template-columns: 1fr; gap: .3rem 1.6rem; align-content: center;
  border: 0; border-top: 1px solid var(--ib-line); border-radius: 0; background: none; padding: 1.7rem 0 1.9rem; }
.st-m-list .ib-prin__item::after { display: none; }
.st-m-list .ib-prin__item::before { content: counter(stn, decimal-leading-zero) / ""; display: block; font-size: clamp(4.2rem, 17vw, 5.6rem); font-weight: 800; letter-spacing: -.05em; line-height: .82; color: var(--ib-accent);
  font-variant-numeric: tabular-nums; transition: opacity .5s ease, translate .6s var(--st-in); opacity: var(--st-n, 1); margin-bottom: .6rem; }
html.sv3-m .st-m-list .ib-prin__item::before { animation: st-num .8s var(--st-in) calc(.2s + var(--n, 0) * .06s) backwards; }
.st-m-list .ib-prin__item:nth-child(1) { --n: 0; } .st-m-list .ib-prin__item:nth-child(2) { --n: 1; } .st-m-list .ib-prin__item:nth-child(3) { --n: 2; }
.st-m-list .ib-prin__item:nth-child(4) { --n: 3; } .st-m-list .ib-prin__item:nth-child(5) { --n: 4; } .st-m-list .ib-prin__item:nth-child(6) { --n: 5; }
.st-m-list .ib-prin__item .ib-prin__h { font-size: 1.28rem; margin: .15rem 0 .35rem; }
.st-m-list .ib-prin__item > * { transition: opacity .55s ease; }
html.st-on .st-m-list .ib-prin__item { --st-n: .12; }
html.st-on .st-m-list .ib-prin__item > * { opacity: .24; }
html.st-on .st-m-list .ib-prin__item[data-st="past"] { --st-n: .34; }
html.st-on .st-m-list .ib-prin__item[data-st="past"] > * { opacity: .55; }
html.st-on .st-m-list .ib-prin__item[data-st="on"] { --st-n: 1; }
html.st-on .st-m-list .ib-prin__item[data-st="on"] > * { opacity: 1; }
html.st-on .st-m-list .ib-prin__item[data-st="on"]::before { translate: .3rem 0; }
html.sv3-m:not(.sv3-chrome) .st-m-list .ib-prin__item.sv3-tilt, html.sv3-m:not(.sv3-chrome) .st-m-list .ib-prin__item.sv3-tilt:hover { transform: none; box-shadow: none; }
.st-method .ib-page-hero { padding-bottom: 3rem; }
@media (min-width: 900px) {
  .st-m-grid { grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 4rem; align-items: start; }
  .st-m-head { position: sticky; top: calc(var(--sv3-nav-h, 4.25rem) + 1.6rem); align-self: start; }
  .st-method .ib-page-hero h1 { font-size: clamp(2.4rem, 3.7vw, 3.4rem); }
  .st-m-list .ib-prin__item { grid-template-columns: minmax(7.5rem, 10rem) 1fr; min-height: min(58vh, 28rem); padding: 2.2rem 0; align-items: center; }
  .st-m-list .ib-prin__item::before { font-size: clamp(5.6rem, 9.5vw, 9rem); grid-row: 1 / span 4; align-self: center; margin: 0; }
  .st-m-list .ib-prin__item > * { grid-column: 2; }
  .st-m-list .ib-prin__item .ib-prin__h { font-size: 1.5rem; }
  .st-method .ib-page-hero { padding-bottom: 5rem; }
}

/* ======================================================================================================
   TESTIMONIALS: H1 by line, a fanned stack that spreads into the grid
   ====================================================================================================== */
.st-h1 .st-hl { display: block; }
@keyframes st-line { from { opacity: 0; translate: 0 6px; } to { opacity: 1; translate: 0 0; } }
html.sv3-m .st-h1 .st-hl { animation: st-line .62s var(--st-in) backwards; }
html.sv3-m .st-h1 .st-hl:nth-child(2) { animation-delay: .2s; }
.st-q { position: relative; }
html.sv3-m:not(.sv3-chrome) .st-q .ib-quote, html.sv3-m:not(.sv3-chrome) .st-q .ib-quote.ib-reveal { opacity: 1; translate: none; scale: 1; transition: box-shadow .4s ease, border-color .4s ease; }
html.sv3-m:not(.sv3-chrome) .st-q .ib-quote.sv3-tilt:hover { transform: none; }
html.st-q-on .st-q .ib-quote { will-change: transform; box-shadow: 0 1px 1px color-mix(in srgb, var(--ib-ink) 5%, transparent), 0 14px 30px -14px color-mix(in srgb, var(--ib-ink) 30%, transparent); transform-origin: 50% 60%; }
html.st-q-on .st-q .ib-quote.is-held { box-shadow: 0 2px 2px color-mix(in srgb, var(--ib-ink) 6%, transparent), 0 34px 54px -20px color-mix(in srgb, var(--ib-ink) 42%, transparent); border-color: var(--ib-accent); }

/* ======================================================================================================
   BEYOND THE SYLLABUS: the last page of the textbook, and what runs past it
   ====================================================================================================== */
.st-bys .ib-page-hero { overflow-x: clip; }
.st-b-grid { display: grid; gap: 2rem; align-items: center; }
html.sv3-m:not(.sv3-chrome) body.st-bys .ib-page-hero > .ib-container > .st-b-copy,
html.sv3-m:not(.sv3-chrome) body.st-bys .ib-page-hero > .ib-container > .st-book { animation: none; }
html.sv3-m .st-b-copy .ib-eyebrow { display: block; animation: sv3-up .6s var(--st-in) .02s backwards; }
html.sv3-m .st-b-copy .ib-bys-lede { animation: sv3-up .7s var(--st-in) .12s backwards; }
.st-book { position: relative; width: 100%; max-width: 35rem; aspect-ratio: 560 / 520; justify-self: center; --st-px: 0; --st-py: 0; }
.st-sheet { position: absolute; left: 0; top: 0; width: 57.1429%; height: 100%; transform-origin: 0% 50%; transform: translate3d(calc(var(--st-px, 0) * 8px), calc(var(--st-py, 0) * 6px), 0); transition: transform .7s var(--st-in); }
html.sv3-m .st-sheet { animation: st-turn 1.05s var(--st-in) backwards; }
@keyframes st-turn { from { transform: perspective(1200px) rotateY(-74deg) scale(.9); } to { transform: perspective(1200px) rotateY(0) scale(1); } }
.st-sheet-svg, .st-open { display: block; position: absolute; left: 0; top: 0; width: 100%; height: 100%; overflow: visible; }
.st-open { transform: translate3d(calc(var(--st-px, 0) * 20px), calc(var(--st-py, 0) * 14px), 0); transition: transform .9s var(--st-in); }
.b-page { fill: var(--ib-card-bg, var(--ib-bg-soft)); stroke: var(--ib-line-strong); stroke-width: 1; }
.b-cover { fill: var(--ib-ink); opacity: .86; }
.b-edge { fill: var(--ib-bg-deep); stroke: var(--ib-line-strong); stroke-width: 1; }
.b-rules path { stroke: var(--ib-line); stroke-width: 1; fill: none; }
.b-margin { stroke: color-mix(in srgb, var(--ib-accent) 45%, transparent); stroke-width: 1; fill: none; }
.st-book text { font-family: var(--ib-font-sans); font-style: italic; font-weight: 500; font-size: 22px; letter-spacing: .01em; }
.b-work .w, .w-in { fill: var(--ib-ink); }
.w-out { fill: var(--ib-accent); }
.b-orb { fill: none; stroke: var(--ib-line-strong); stroke-width: 1.2; stroke-dasharray: 4 6; }
.b-focus { fill: var(--ib-ink-muted); }
.b-body { fill: var(--ib-accent); }
.b-run { fill: none; stroke: var(--ib-accent); stroke-width: 2; stroke-linecap: round; stroke-dasharray: 3 11; }
.b-pen { fill: var(--ib-accent); opacity: 0; }
html.sv3-m .b-run { animation: st-march 1.6s linear infinite; }
@keyframes st-march { to { stroke-dashoffset: -28; } }
html.sv3-m:not(.st-b-ready) .st-book .b-pen { opacity: 0; }

.ib-bys { position: relative; }
html.st-on .ib-bys::before { content: ""; position: absolute; left: -60vw; right: -60vw; top: -1.3rem; height: 2px; background: linear-gradient(90deg, transparent, var(--ib-accent) 18%, var(--ib-accent) 82%, transparent);
  transform: scaleX(var(--st-bp, 0)); transform-origin: 50% 50%; pointer-events: none; }
.st-bys .ib-section { overflow-x: clip; }
html.st-on .ib-bys__c { transition: opacity .7s ease var(--st-d, 0s), translate .9s var(--st-in) var(--st-d, 0s); }
html.st-on .ib-bys__c:not(.is-in) { opacity: 0; translate: 0 1.4rem; }
html.st-on .ib-bys__l li { transition: opacity .5s ease var(--st-ld, 0s), translate .6s var(--st-in) var(--st-ld, 0s); }
html.st-on .ib-bys__c:not(.is-in) .ib-bys__l li { opacity: 0; translate: -.8rem 0; }
.ib-bys-hon { position: relative; }
.ib-bys-hon::before { transition: transform .5s var(--st-in); }
html.st-on .ib-bys-hon { border-left-color: transparent; }
html.st-on .ib-bys-hon::before { content: ""; position: absolute; left: -3px; top: 0; bottom: 0; width: 3px; background: var(--ib-gold, #B58A3A); transform: scaleY(var(--st-hp, 0)); transform-origin: top; }
@media (min-width: 900px) { .st-b-grid { grid-template-columns: minmax(0, 1.02fr) minmax(0, 1fr); gap: 3rem; } .st-bys .st-book { justify-self: end; } }
@media (max-width: 899.98px) { .st-book { max-width: 24rem; } }

/* ======================================================================================================
   Reduced motion and no JS: nothing is dimmed, hidden or pinned so that copy is lost.
   ====================================================================================================== */
@media (prefers-reduced-motion: reduce) {
  .st-sheet, .st-idx span, .st-m-list .ib-prin__item::before, .st-h1 .st-hl, .b-run { animation: none !important; }
  .st-m-head { position: static; }
}
@media print { .st-trail { display: none; } }

/* ======================================================================================================
   HEROES (story-hero-v3.js): a canvas object in a night scene, an instrument panel, a drag
   ====================================================================================================== */
.ib-page-hero.st-live { position: relative; overflow-x: clip; }
.ib-page-hero.st-live > .st-cv { position: absolute; left: 0; top: 0; z-index: 0; pointer-events: none; display: block; }
.ib-page-hero.st-live > .ib-container { position: relative; z-index: 1; }
.ib-page-hero.is-drag { cursor: grabbing; -webkit-user-select: none; user-select: none; }
html.st-hero-on .ib-page-hero.st-live .st-zone { cursor: grab; }
.st-zone { position: relative; border-radius: 1.1rem; min-height: 15rem; }
.st-fb { display: block; width: 100%; height: 100%; border-radius: inherit; }
html.st-hero-on .st-fb { display: none; }
.st-panel { position: absolute; z-index: 3; left: .9rem; bottom: .9rem; min-width: 11.5rem; padding: .7rem .85rem .75rem; border-radius: .8rem; pointer-events: none;
  background: color-mix(in srgb, var(--ib-emphasis-bg, #20201E) 72%, transparent); border: 1px solid color-mix(in srgb, var(--ib-emphasis-text, #F5F1EB) 16%, transparent);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); color: var(--ib-emphasis-text, #F5F1EB); font-variant-numeric: tabular-nums; }
.st-panel__t { font-size: .62rem; font-weight: 800; letter-spacing: .16em; text-transform: uppercase; color: var(--ib-gold); margin-bottom: .4rem; }
.st-row { display: grid; grid-template-columns: 1fr auto 2.6rem; align-items: baseline; gap: .5rem; padding: .12rem 0; font-size: .74rem; }
.st-row__l { color: color-mix(in srgb, var(--ib-emphasis-text, #F5F1EB) 70%, transparent); }
.st-row__v { font-size: 1.02rem; font-weight: 700; text-align: right; min-width: 3.6rem; }
.st-row__u { font-size: .66rem; color: color-mix(in srgb, var(--ib-emphasis-text, #F5F1EB) 55%, transparent); }
.st-hint { position: absolute; z-index: 3; right: .9rem; bottom: .8rem; font-size: .68rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: color-mix(in srgb, var(--ib-emphasis-text, #F5F1EB) 70%, transparent); pointer-events: none; }
.st-hint::before { content: ""; display: inline-block; width: .45rem; height: .45rem; border-radius: 50%; background: var(--ib-gold); margin-right: .45rem; vertical-align: .05rem; }
html.sv3-m .st-panel { animation: st-num .8s var(--st-in) .25s backwards; }

.st-zone-about { height: clamp(15rem, 28vw, 21rem); margin: 1.6rem 0 1.2rem; }
.st-zone-about .st-panel { left: auto; right: .9rem; bottom: .9rem; }
.st-zone-about .st-hint { left: .9rem; right: auto; top: .8rem; bottom: auto; }
.st-zone-bys .st-panel { left: auto; right: .9rem; bottom: .9rem; }
.st-zone-bys .st-hint { left: .9rem; right: auto; bottom: .8rem; }
.st-about .ib-page-hero { padding-bottom: 2.2rem; }
.st-m-right { min-width: 0; }
.st-zone-method { height: clamp(30rem, 74vh, 40rem); margin-bottom: 1.4rem; }
.st-zone-method .st-panel { left: .8rem; bottom: .8rem; }
.st-zone-method .st-hint { right: .9rem; bottom: .8rem; }
.st-zone-testi { height: 22rem; margin-top: 1.4rem; }
.st-zone-bys { height: clamp(22rem, 36vw, 32rem); width: 100%; }
.st-bys .st-b-copy { align-self: center; }
@media (min-width: 900px) {
  .st-testi .ib-page-hero > .ib-container { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); column-gap: 3rem; align-items: center; }
  .st-testi .ib-page-hero .ib-eyebrow, .st-testi .ib-page-hero h1, .st-testi .ib-page-hero p { grid-column: 1; }
  .st-testi .st-zone-testi { grid-column: 2; grid-row: 1 / span 3; height: 30rem; margin: 0; }
  .st-testi .ib-page-hero { padding-bottom: 3rem; }
  .st-testi .ib-page-hero h1 { max-width: none !important; font-size: clamp(2.2rem, 3.7vw, 3.3rem); }
}
@media (max-width: 899.98px) {
  .st-zone-about { height: 15rem; }
  .st-zone-method { height: 27rem; }
  .st-zone-bys { height: 20rem; }
  .st-panel { min-width: 9.6rem; padding: .5rem .6rem .55rem; left: .5rem; bottom: .5rem; }
  .st-row { font-size: .64rem; grid-template-columns: 1fr auto; } .st-row__v { font-size: .86rem; min-width: 2.4rem; } .st-row__u { display: none; }
  .st-panel { min-width: 0; width: 8.6rem; }
  .st-panel .st-row:nth-child(n+5) { display: none; }
  .st-zone-testi { height: 24rem; }
  .st-zone-about { height: 19rem; }
  .st-zone-about .st-panel, .st-zone-bys .st-panel { left: auto; right: .5rem; bottom: .5rem; }
}
